Basically I want my spell to launch a dummy unit that works like a missile and when it hits the unit gets knockback. The problem is that no dmg is done and it keeps repeating and the dummy unit doesn't go to the enemy unit ( I know this probably the wrong way to trigger a spell to this description)
-
Actions
- Set Caster = (Triggering unit)
- Set Target = (Target unit of ability being cast)
- Set Distance = (400.00 + (100.00 x 1.00))
- Set Angle = (Facing of Caster)
- Set Duration = 2.00
- Set Point_1 = (Position of (Triggering unit))
- Set Unit_1 = (Target unit of ability being cast)
- Unit - Pause (Triggering unit)
- Unit - Pause Unit_1
- Unit - Create 1 Dummy Unit for Player 1 (Red) at Point_1 facing Default building facing degrees
- Unit - Make Unit_2 face (Position of Unit_1) over 0.00 seconds
- Set Unit_2 = (Last created unit)
- Unit - Order Unit_2 to Move To (Rally-Point of Unit_1 as a point)
- Wait 1.00 seconds
- Custom script: call Knockback(udg_Target, udg_Distance, udg_Angle * bj_DEGTORAD, udg_Duration)
- Unit - Cause Unit_2 to damage Unit_2, dealing 100.00 damage of attack type Spells and damage type Normal
- Unit - Remove Unit_2 from the game
- Unit - Unpause Unit_1
- Unit - Unpause (Triggering unit)