- Joined
- Jun 1, 2009
- Messages
- 104
Hi!
My goal is to auto-cast a spell under certain conditions. To reduce lags in the case of multiple units I want to check the condition if the spell is ready or not.
But when I try to use the
What I'm doing wrong?
Is there any other resource-saving method to check the ability cooldown?
Ofc. I can simply start a timer for every casting unit, but I hope to avoid this.
My triggers:
Without
My goal is to auto-cast a spell under certain conditions. To reduce lags in the case of multiple units I want to check the condition if the spell is ready or not.
But when I try to use the
- Ability Cooldown Remaining
What I'm doing wrong?
Is there any other resource-saving method to check the ability cooldown?
Ofc. I can simply start a timer for every casting unit, but I hope to avoid this.
My triggers:
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Unit-type of (Attacking unit)) Equal to |cff00ffffWizzard|r
-
Then - Actions
- Set VariableSet AI_TempUnit[0] = (Attacking unit)
- Set VariableSet AI_TempUnit[1] = (Attacked unit)
- Trigger - Run AI Wizzard <gen> (checking conditions)
- Skip remaining actions
- Else - Actions
-
If - Conditions
-
AI Wizzard
- Events
- Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Ability Cooldown Remaining of AI_TempUnit[0] for ability Spell Absorption ..) Less than or equal to 0.00
-
Then - Actions
- Set VariableSet AI_TempPoint = (Position of AI_TempUnit[1])
- Unit - Order AI_TempUnit[0] to Undead Destroyer - Devour Magic AI_TempPoint
- Custom script: call RemoveLocation(udg_AI_TempPoint)
- Else - Actions
-
If - Conditions
- Set VariableSet AI_TempUnit[0] = No unit
- Set VariableSet AI_TempUnit[1] = No unit
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
Without
- (Ability Cooldown Remaining of AI_TempUnit[0] for ability Spell Absorption ..) Less than or equal to 0.00