• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Homing Missle v1.1

The caster shoot a missile the way he faces. This missile will start homing any enemy unit that comes into a 750 range. If the missile collides with an enemy unit it will explode and deal 50/100/150 damage in a small AOE. The missile can travel up to 4000 units.

v1.1 added some comments. moved some things from HM init to HM loop

Update 31.8.14: Updated Hive description

Keywords:
homing; missle; MUI; hell gate; explode; tank
Contents

Map template (Map)

Reviews
12:17, 29th Dec 2009 TriggerHappy: The coding was fine and all, but in the demo map triggers why did you convert them to Jass without making any modifications?

Moderator

M

Moderator

12:17, 29th Dec 2009
TriggerHappy:

The coding was fine and all, but in the demo map triggers why did you convert them to Jass without making any modifications?
 
Level 17
Joined
Mar 17, 2009
Messages
1,349
Seems well done! Nice idea and creative...
Use comments in the triggers so that you can read it easier when you try to update, and so that we users dont have to fully read it to understand what's going on, but go through the comments. At least use the as dividers.
(look at the spell in my signature and you'll understand what I mean).
 

Rmx

Rmx

Level 19
Joined
Aug 27, 2007
Messages
1,164
Hashtables won't use arrays like indexes and therefore there won't be a possibility to go exceed the max array number.
At that point and the fact it will drasticaly change the look of GUI spells you should know that it is much better than indexing.

And recycling the indexes won't have a chance to exceed the max array number either :O
 
Level 17
Joined
Mar 17, 2009
Messages
1,349
off-topic @ Kingz:
No one here is saying that hashTables shouldn't be used. But I mean, if I don't need the arrays to loop through them, using Indexing is as fine as using hashTables.
What's more, Indexing is slightly faster - so I've heard - but who cares about some picoseconds? :p
And we know how to Index, so it only takes us a minute.
For those who don't, well hashTables are more convenient.
 
Level 14
Joined
Nov 23, 2008
Messages
512
Seems well done! Nice idea and creative...
Use comments in the triggers so that you can read it easier when you try to update, and so that we users dont have to fully read it to understand what's going on, but go through the comments. At least use the as dividers.
(look at the spell in my signature and you'll understand what I mean).

ooop. now i know what i forgott :)

will add it soon
 
Level 5
Joined
Dec 8, 2008
Messages
102
my benchmark tests showed that using indexing is 2x faster than hashtables, but hashtables are 2x better because:
1) you cant reach the max index
2) hundreds of globals will take A LOT of memory and you simply cant remove them, just recycle
 
Level 10
Joined
Apr 4, 2010
Messages
509
This isn't 100%

I find that when I launch multiple missiles, some of them will not detect and/or follow a target, instead they will just keep travelling forward, ignoring any enemies in range. I think it has something to do with the indexing.

I should mention that I modified it so that:
  • the missiles are slower and have increases turning rate.
  • the missiles won't expire when reaching max range. (temporary testing)
  • decreased impact range.
  • the missiles will forget and try to look for a new target, only if the first target was too fast and escapes the pinning range.

I might have modified something to cause this issue, but I doubt it.
I added control over a footman for testing purposes. It will follow the steam tank's right click and will teleport when the steam tank issues a move order.

EDIT: I found the problem.
  • Set HM_TempGroup = (Units within HM_PinningDistance[HM_LoopIndex[3]] of HM_LeakPoint[1] matching ((((Matching unit) is A flying unit) Equal to False) and ((((Matching unit) is Mechanical) Equal to False) and (((((Matching unit) is alive) Equal to True) and (((Matching unit) is
It's suppose to be HM_LeakPoint[0] not [1].
 

Attachments

  • HomingMissle[MYEDIT].w3x
    36.6 KB · Views: 44
Last edited:
Top