- Joined
- Feb 9, 2009
- Messages
- 1,800
Hello, trying to setup three orbiting units that rotate until the buff applied by the dummy either is dispelled or expired
Problem is that the unit's do not rotate
I'd like to keep the indexing triggers and have it GUI so no hashtables or JASS solutions please!
Here's the triggers:
Problem is that the unit's do not rotate
I'd like to keep the indexing triggers and have it GUI so no hashtables or JASS solutions please!
Here's the triggers:
-
Main Cast
-
Events
-
Unit - A unit Starts the effect of an ability
-
-
Conditions
-
(Ability being cast) Equal to Orbit
-
-
Actions
-
Set tempp1 = (Position of (Triggering unit))
-
Unit - Create 1 Dummy for (Owner of (Triggering unit)) at tempp1 facing Default building facing degrees
-
Unit - Add Buff Spell to (Last created unit)
-
Unit - Order (Last created unit) to Human Priest - Inner Fire (Triggering unit)
-
Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
-
Set Tempkey = (Custom value of (Triggering unit))
-
For each (Integer A) from 1 to 3, do (Actions)
-
Loop - Actions
-
Unit - Kill OrbitUnit[((3 x Tempkey) + ((Integer A) - 1))]
-
Set tempp2 = (tempp1 offset by 50.00 towards (120.00 x (Real((Integer A)))) degrees)
-
Unit - Create 1 Orbit unit for (Owner of (Triggering unit)) at tempp2 facing Default building facing degrees
-
Set OrbitUnit[((3 x Tempkey) + ((Integer A) - 1))] = (Last created unit)
-
Custom script: call RemoveLocation(udg_tempp2)
-
-
-
Custom script: call RemoveLocation(udg_tempp1)
-
-
-
Dummy Cast
-
Events
-
Unit - A unit Starts the effect of an ability
-
-
Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Ability being cast) Equal to Buff Spell
-
-
Then - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Target unit of ability being cast) is in SS_group) Equal to True
-
-
Then - Actions
-
Unit Group - Add (Target unit of ability being cast) to SS_group
-
Trigger - Turn on SS Group <gen>
-
-
Else - Actions
-
-
Custom script: call RemoveLocation(udg_tempp2)
-
Custom script: call RemoveLocation(udg_tempp1)
-
-
Else - Actions
-
-
-
-
SS Group
-
Events
-
Time - Every 0.05 seconds of game time
-
-
Conditions
-
Actions
-
Unit Group - Pick every unit in SS_group and do (Actions)
-
Loop - Actions
-
Set Tempkey = (Custom value of (Picked unit))
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Picked unit) is alive) Equal to True
-
-
Then - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Picked unit) has buff Buff ) Equal to True
-
-
Then - Actions
-
For each (Integer A) from 1 to 3, do (Actions)
-
Loop - Actions
-
Set tempp1 = (Position of (Picked unit))
-
Set tempp3 = (Position of OrbitUnit[((3 x Tempkey) + ((Integer A) - 1))])
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Distance between tempp1 and tempp3) Greater than 50.00
-
-
Then - Actions
-
Set Orbit_Distance[Tempkey] = (Orbit_Distance[Tempkey] + 25.00)
-
Set tempp2 = (tempp1 offset by 120.00 towards ((120.00 x (Real((Integer A)))) + Orbit_Distance[Tempkey]) degrees)
-
Unit - Move OrbitUnit[((3 x Tempkey) + ((Integer A) - 1))] instantly to tempp2, facing (Angle from tempp2 to tempp1) degrees
-
-
Else - Actions
-
Set tempp2 = (tempp1 offset by 25.00 towards (Facing of OrbitUnit[Tempkey]) degrees)
-
Unit - Move OrbitUnit[((3 x Tempkey) + ((Integer A) - 1))] instantly to tempp2, facing (Angle from tempp1 to tempp3) degrees
-
Unit - Make OrbitUnit[((3 x Tempkey) + ((Integer A) - 1))] face tempp1 over 0.00 seconds
-
-
-
Custom script: call RemoveLocation(udg_tempp3)
-
Custom script: call RemoveLocation(udg_tempp2)
-
Custom script: call RemoveLocation(udg_tempp1)
-
-
-
-
Else - Actions
-
For each (Integer A) from 1 to 3, do (Actions)
-
Loop - Actions
-
Unit - Kill OrbitUnit[(((3 x Tempkey) + (Integer A)) - 1)]
-
-
-
Unit Group - Remove (Picked unit) from SS_group
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(SS_group is empty) Equal to True
-
-
Then - Actions
-
Trigger - Turn off SS Group <gen>
-
-
Else - Actions
-
-
-
-
-
Else - Actions
-
For each (Integer A) from 1 to 3, do (Actions)
-
Loop - Actions
-
Unit - Kill OrbitUnit[(((3 x Tempkey) + (Integer A)) - 1)]
-
-
-
Unit Group - Remove (Picked unit) from SS_group
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(SS_group is empty) Equal to True
-
-
Then - Actions
-
Trigger - Turn off SS Group <gen>
-
-
Else - Actions
-
-
-
-
-
-
-