- Joined
- Feb 18, 2016
- Messages
- 96
Hello
I was trying to make an ability that should work this way
The hero generates a Custom unit above his position and make the custom move to the position of the nearest hero
The Custom unit will explode when it arrives to the saved position causing AOE damage but it will not follow the enemy if he moves
Every time the Custom unit dies the trigger should generate another that will follow the same commands until it reaches a specific limit
These are the triggers i have made for this spell but it does not work at all
Any help?
This trigger is the one who spawns the initial unit and sets the variables where the real 3 is the amount of units remaining to generate and the real 2 is a detection range that periodically updates to detect the nearest hero
This trigger search for a hero nearest hero increasing the real[3] each time it does not find any
Being the real[3] used as an area it detects the closest hero to the point
This trigger kills the unit until it reaches the point
I was trying to make an ability that should work this way
The hero generates a Custom unit above his position and make the custom move to the position of the nearest hero
The Custom unit will explode when it arrives to the saved position causing AOE damage but it will not follow the enemy if he moves
Every time the Custom unit dies the trigger should generate another that will follow the same commands until it reaches a specific limit
These are the triggers i have made for this spell but it does not work at all
Any help?
This trigger is the one who spawns the initial unit and sets the variables where the real 3 is the amount of units remaining to generate and the real 2 is a detection range that periodically updates to detect the nearest hero
-
CAST
-
Events
-
Unit - A unit Starts the effect of an ability
-
-
Conditions
-
(Ability being cast) Equal to SPELL
-
-
Actions
-
Set RATREAL[1] = 2.00
-
Set RATREAL[2] = 110.00
-
Set RATREAL[3] = 10.00
-
Trigger - Run Spawns <gen> (checking conditions)
-
Game - Display to (All players) the text: CAST
-
-
-
Spawns
-
Events
-
Conditions
-
Actions
-
Game - Display to (All players) the text: SPAWN
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
RATREAL[3] Less than or equal to 0.00
-
-
Then - Actions
-
Trigger - Turn off (This trigger)
-
-
Else - Actions
-
Set RPoint = (Position of Aatrox)
-
Set APOINTTEMP = (Position of (Dying unit))
-
Unit - Create 1 CUSTOM for (Owner of Hero) at APOINTTEMP facing Default building facing degrees
-
Set Summoned = (Last created unit)
-
Custom script: call RemoveLocation (udg_APOINTTEMP)
-
Set RATREAL[3] = (RATREAL[3] - 1.00)
-
Game - Display to (All players) the text: MOVE
-
Trigger - Turn on Detect heroes <gen>
-
-
-
-
-
Regenerate
-
Events
-
Unit - A unit Dies
-
-
Conditions
-
(Unit-type of (Dying unit)) Equal to Summoned
-
-
Actions
-
Set APOINTTEMP = (Position of (Dying unit))
-
Custom script: set bj_wantDestroyGroup = true
-
Unit Group - Pick every unit in (Units within 200.00 of APOINTTEMP) and do (Actions)
-
Loop - Actions
-
Unit - Cause Hero to damage (Picked unit), dealing damage of attack type Normal and damage type Normal
-
-
-
Custom script: call RemoveLocation (udg_APOINTTEMP)
-
Trigger - Run Spawns <gen> (checking conditions)
-
Game - Display to (All players) the text: DEAD
-
Set RATREAL[3] = (RATREAL[3] - 1.00)
-
-
This trigger search for a hero nearest hero increasing the real[3] each time it does not find any
Being the real[3] used as an area it detects the closest hero to the point
-
Detect heroes
-
Events
-
Time - Every 0.03 seconds of game time
-
-
Conditions
-
Actions
-
Set RPoint = (Position of Hero)
-
Custom script: set bj_wantDestroyGroup = true
-
Unit Group - Pick every unit in (Units within RATREAL[2] of APOINTTEMP) and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Picked unit) is A Hero) Equal to False
-
-
Then - Actions
-
Set RATREAL[2] = (RATREAL[2] + 100.00)
-
-
Else - Actions
-
Set APOINTTEMP = (Position of (Picked unit))
-
Unit - Order (Summoned) to Move To APOINTTEMP
-
Custom script: call RemoveLocation (udg_APOINTTEMP)
-
Set RATREAL[2] = 110.00
-
Trigger - Turn off (This trigger)
-
-
-
-
-
Custom script: call RemoveLocation (udg_RPoint)
-
-
This trigger kills the unit until it reaches the point
-
stop
-
Events
-
Unit - A unit Is issued an order with no target
-
-
Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Ordered unit) Equal to Summoned
-
(Issued order) Equal to (Order(stop))
-
-
Then - Actions
-
Unit - Kill Summoned
-
-
Else - Actions
-
-
-