# [Trigger]Why wont this work

Status
Not open for further replies.

#### Freyleyes

Level 17
I have no idea why this won't work :

• Vortex
• Events
• Unit - A unit Starts the effect of an ability
• Conditions
• (Ability being cast) Equal to Thunder Vortex (Far Seer)
• Actions
• Unit Group - Remove all units from Unitgroup_Vortex
• Set Temp_Pos[1] = (Target point of ability being cast)
• For each (Integer A) from 1 to 8, do (Actions)
• Loop - Actions
• Set Temp_Pos[2] = (Temp_Pos[1] offset by 10.00 towards (45.00 x (Real((Integer A)))) degrees)
• Unit - Create 1 Thunder Vortex for (Owner of (Casting unit)) at Temp_Pos[2] facing (45.00 x (Real((Integer A)))) degrees
• Unit - Turn collision for (Last created unit) Off
• Unit - Add a 0.60 second Generic expiration timer to (Last created unit)
• Unit - Set the custom value of (Last created unit) to (Level of (Ability being cast) for (Triggering unit))
and then

• Ability Systems Int 2
• Events
• Time - Every 0.05 seconds of game time
• Conditions
• Actions
• -------- Vortex --------
• Set Temp_Group = (Units of type Thunder Vortex)
• Unit Group - Pick every unit in Temp_Group and do (Actions)
• Loop - Actions
• Set Temp_Pos[1] = (Position of (Picked unit))
• Set Temp_Pos[2] = (Temp_Pos[1] offset by 30.00 towards (Facing of (Picked unit)) degrees)
• Unit - Move (Picked unit) instantly to Temp_Pos[2]
• Set Temp_Unit = (Picked unit)
• Set UnitGroup_Temp = (Units within 150.00 of Temp_Pos[2])
• Unit Group - Pick every unit in Temp_Group and do (Actions)
• Loop - Actions
• If (All Conditions are True) then do (Then Actions) else do (Else Actions)
• If - Conditions
• ((Picked unit) is in Unitgroup_Vortex) Equal to False
• Then - Actions
• Unit - Create 1 Dummy for (Owner of Temp_Unit) at Temp_Pos[2] facing Default building facing degrees
• Unit - Add Purge (Vortex) to (Last created unit)
• If (All Conditions are True) then do (Then Actions) else do (Else Actions)
• If - Conditions
• (Unit-type of (Picked unit)) Equal to Dummy
• Then - Actions
• Else - Actions
• Unit - Order (Last created unit) to Orc Shaman - Purge (Picked unit)
• Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
• Unit Group - Add (Picked unit) to Unitgroup_Vortex
• Else - Actions
• EGUI - Remove Temp_Pos[1]
• EGUI - Remove Temp_Pos[2]
• EGUI - Destroy Temp_Group
The thing that is not working is the purge. None of the units gets purged.

+REP and a good feeling to whom ever helps.

#### Smiddle

Level 8
Natives such as "Casting unit" quickly lose their value. Use triggering unit instead.

It could also be that "Temp_Unit" doesn't refer to any unit at all as far as I can see.

Status
Not open for further replies.

[Trigger] **System Bug Fix**
Replies
3
Views
931
Replies
4
Views
461
Replies
3
Views
7K
Replies
1
Views
542
Replies
4
Views
550