- Joined
- Aug 31, 2009
- Messages
- 776
So for my custom map, I'm trying to make a unit that essentially acts like a Siege Tank from Starcraft II with automated AI.
When it tries to attack a unit, it is instead given a "Root" order, and suitably transforms into a building version of itself. When no targets are in range, it automatically unroots itself.
The unrooting works perfectly.
The rooting however, does not.
The trigger is very simple, just a typical "Unit is attacked" event, with condition being the unit type check, and the actions are simply:
And of course, I've already checked the obvious problems like the unit not having space to root, or pathing not being buildable etc.
Any ideas how to fix?
When it tries to attack a unit, it is instead given a "Root" order, and suitably transforms into a building version of itself. When no targets are in range, it automatically unroots itself.
The unrooting works perfectly.
The rooting however, does not.
The trigger is very simple, just a typical "Unit is attacked" event, with condition being the unit type check, and the actions are simply:
-
Set point = (Position of (Attacking unit))
-
Unit - Order (Attacking unit) to Night Elf Ancients - Root point
-
Custom script: call RemoveLocation(udg_point)
And of course, I've already checked the obvious problems like the unit not having space to root, or pathing not being buildable etc.
Any ideas how to fix?