- Joined
- Mar 17, 2012
- Messages
- 105
I have an ability Shock Charge based on Endurance Aura that adds the buff "Charge Ready" to the unit that has the ability. It is supposed to simulate a knight dealing additional damage upon his first attack in a battle (a charge). I have two triggers:
-
ChargeAttack
-
Events
-
Unit - A unit Is attacked
-
-
Conditions
-
(Unit-type of (Attacking unit)) Equal to Heavy Man-at-arms [Default]
-
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Attacking unit) has buff Charge Ready ) Equal to True
-
-
Then - Actions
-
Unit - Cause (Attacking unit) to damage (Attacked unit), dealing 30.00 damage of attack type Hero and damage type Normal
-
Unit - Remove Shock Charge [Active] from (Attacking unit)
-
Unit - Remove Charge Ready buff from (Attacking unit)
-
-
Else - Actions
-
Do nothing
-
-
-
-
-
ChargeReset
-
Events
-
Time - Every 5.00 seconds of game time
-
-
Conditions
-
Actions
-
Unit Group - Pick every unit in (Units of type Heavy Man-at-arms [Default]) and do (Actions)
-
Loop - Actions
-
Set UNIT_TempUnit[5] = (Picked unit)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(UNIT_TempUnit[5] has buff Charge Ready ) Equal to True
-
-
Then - Actions
-
Do nothing
-
-
Else - Actions
-
Unit Group - Pick every unit in (Units within 1024.00 of (Position of UNIT_TempUnit[5])) and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
And - All (Conditions) are true
-
Conditions
-
(Picked unit) Not equal to UNIT_TempUnit[5]
-
((Picked unit) belongs to an ally of (Owner of UNIT_TempUnit[5])) Not equal to True
-
(Owner of (Picked unit)) Not equal to (Owner of UNIT_TempUnit[5])
-
((Picked unit) belongs to an enemy of (Owner of UNIT_TempUnit[5])) Equal to True
-
-
-
-
Then - Actions
-
Do nothing
-
-
Else - Actions
-
Unit - Add Shock Charge [Active] to UNIT_TempUnit[5]
-
-
-
-
-
-
-
-
-
-