• 🏆 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!

MultiAtack

Status
Not open for further replies.
Level 4
Joined
Jan 19, 2015
Messages
61
I want to know if theres a way to do a unit atack multiple enemies and atack while moving, i want to do a tower that shot cannonballs and arrows and a kodo beast that shot 2 arrows while moving.
 
Level 25
Joined
Jul 10, 2006
Messages
3,315
You need to use 2 units.

The first unit has no attack.
The second unit has an attack, barrage (to give multishot), Locust (to make it unclickable), Invulnerable, and no model.

You'll need a few triggers to handle this:

1. When the kodo is trained, you create the attacker unit and link them together using either a unit indexer or a hashtable.

2. Make a looping trigger that moves the attacker unit to the position of the kodo using the custom script SetUnitX/SetUnitY.

3. When the kodo dies, kill its associated attacker unit.
 
Status
Not open for further replies.
Top