- Joined
- Mar 2, 2013
- Messages
- 127
This is ability create 2 portals, 1 way traveling. Teleports anyone near portal 1 to portal 2. Portal lasts for 10 seconds. When you use the ability the first time, everything works fine. But when you use it again, it creates the portals but doesn't move the units :/ Any ideas?
-
Portal
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to (==) Descorrer
-
Actions
- Set Bara_Unit[2] = (Triggering unit)
- Unit Group - Add Bara_Unit[2] to Bara_Group[1]
- Unit - Create 1 Portal 1 for (Owner of Bara_Unit[2]) at ((Position of Bara_Unit[2]) offset by 100.00 towards Bar_Ang degrees) facing (Facing of Bara_Unit[2]) degrees
- Set Bara_Unit[3] = (Last created unit)
- Set Bar_Point[3] = (Position of Bara_Unit[3])
- Unit - Add a 10.00 second Generic expiration timer to Bara_Unit[3]
- Unit - Create 1 Portal 2 for (Owner of Bara_Unit[2]) at (Target point of ability being cast) facing (Facing of Bara_Unit[2]) degrees
- Set Bara_Unit[4] = (Last created unit)
- Set Bar_Point[4] = (Position of Bara_Unit[4])
- Unit - Add a 10.00 second Generic expiration timer to Bara_Unit[4]
- Set Bara_Real[5] = 50.00
- Trigger - Turn on Portal time <gen>
-
Events
-
Portal time
-
Events
- Time - Every 0.20 seconds of game time
- Conditions
-
Actions
-
Unit Group - Pick every unit in Bara_Group[1] and do (Actions)
-
Loop - Actions
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Bara_Real[5] Less than or equal to (<=) 0.00
-
Then - Actions
- Custom script: call DestroyGroup( udg_Bara_Group[1] )
- Custom script: call RemoveLocation(udg_Bar_Point[3])
- Custom script: call RemoveLocation(udg_Bar_Point[4])
- Trigger - Turn off (This trigger)
-
Else - Actions
- Set Bara_Real[5] = (Bara_Real[5] - 1.00)
-
Unit Group - Pick every unit in (Units within 75.00 of Bar_Point[3] matching (((Unit-type of (Matching unit)) Not equal to (!=) Portal 1) and (((Unit-type of (Matching unit)) Not equal to (!=) Portal 2) and (((Matching unit) belongs to an ally of (Owner of Bara_Unit[2])) Equal to (==) True) and do (Actions)
-
Loop - Actions
- Unit - Move (Picked unit) instantly to Bar_Point[4]
-
Loop - Actions
-
If - Conditions
-
Multiple FunctionsIf (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Loop - Actions
-
Unit Group - Pick every unit in Bara_Group[1] and do (Actions)
-
Events
Last edited: