- Joined
- Jun 2, 2009
- Messages
- 1,233
Here is the trigger for 1 Computer slot. I have created 10 times for 10 computers without timers. Because if i will create timer and replace it with wait, i have to create 10 timer windows.
Is anybody knows how to make it "better" (less triggers) because if it is possible, i will create new behavior for AI Controlled Heroes and i don't want to create 20 triggers for every behavior. But i will to if we can make it with 1 trigger.
Is anybody knows how to make it "better" (less triggers) because if it is possible, i will create new behavior for AI Controlled Heroes and i don't want to create 20 triggers for every behavior. But i will to if we can make it with 1 trigger.
-
DevilHerodanKacP2
-
Events
-
Unit - A unit Is attacked
-
-
Conditions
-
((Attacking unit) is in ReaperHerolariPlayer) Equal to True
-
(Attacked unit) Equal to zU_AIHero[2]
-
zBool_AIFallBackHERO[2] Equal to False
-
((Attacked unit) is in zUG_RegenDevil) Equal to False
-
((Attacked unit) is in CHANNEL) Equal to False
-
-
Actions
-
Set xINT_TEMP[2] = (Level of (Attacking unit))
-
Set xINT_TEMP2[2] = (Level of (Attacked unit))
-
Set xINT_TEMP3[2] = (xINT_TEMP[2] - xINT_TEMP2[2])
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
xINT_TEMP3[2] Greater than or equal to 3
-
-
Then - Actions
-
Set zBool_AIFallBackHERO[2] = True
-
Set TempPoint = ((Position of (Attacked unit)) offset by 800.00 towards ((Angle from (Position of (Attacking unit)) to (Center of PreviousTarget[2])) - 0.00) degrees)
-
Unit - Order (Attacked unit) to Move To TempPoint
-
Custom script: call RemoveLocation (udg_TempPoint)
-
Wait 4.00 seconds
-
Set zBool_AIFallBackHERO[2] = False
-
Set TempGroup = (Units within 800.00 of (Position of (Attacked unit)) matching (((Matching unit) is in zUG_CreepsDevil) Equal to True))
-
Unit Group - Pick every unit in TempGroup and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Number of units in TempGroup) Greater than or equal to 1
-
-
Then - Actions
-
Unit - Order zU_AIHero[(Player number of (Owner of (Attacked unit)))] to Attack-Move To (Center of NextTarget[2])
-
Custom script: call DestroyGroup (udg_TempGroup)
-
-
Else - Actions
-
Custom script: call DestroyGroup (udg_TempGroup)
-
-
-
-
-
-
Else - Actions
-
-
-