- Joined
- May 23, 2018
- Messages
- 13
Can somebody please help me how to increase damage and armor based on a hero's stats whenever Battle Roar is casted?
Only that I don't know how to return an affected units original damage and armor when the buff is gone.
-
War Cry Cast
-

Events
-


Unit - A unit Starts the effect of an ability
-
-

Conditions
-


(Ability being cast) Equal to War Cry
-
-

Actions
-


Set Unit_WC_Caster = (Casting unit)
-


Set Integer_WC_SpellLevel = (Level of War Cry for Unit_WC_Caster)
-


Set Point_WC_Caster = (Position of Unit_WC_Caster)
-


Set Real_WC_Damage = ((Real((Agility of Unit_WC_Caster (Include bonuses)))) x ((2.00 x (Real(Integer_WC_SpellLevel))) - 1.00))
-


Set Real_WC_Armor = ((Real((Agility of Unit_WC_Caster (Include bonuses)))) x (0.10 x (Real(Integer_WC_SpellLevel))))
-


Set UnitGroup_WC_Targets = (Units within 450.00 of Point_WC_Caster)
-


Unit Group - Pick every unit in UnitGroup_WC_Targets and do (Actions)
-



Loop - Actions
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






((Picked unit) is A structure) Equal to False
-






((Picked unit) is alive) Equal to True
-






((Picked unit) belongs to an enemy of (Owner of Unit_WC_Caster)) Equal to False
-
-





Then - Actions
-






Unit - Set Base Damage of (Picked unit) to ((Base Damage of (Picked unit) for weapon index 1) + (Integer(Real_WC_Damage))) for weapon index: 1
-






Unit - Set Armor of (Picked unit) to ((Armor of (Picked unit)) + Real_WC_Armor)
-
-





Else - Actions
-
-
-
-


Custom script: call DestroyGroup (udg_UnitGroup_WC_Targets)
-


Custom script: call RemoveLocation (udg_Point_WC_Caster)
-
-
Only that I don't know how to return an affected units original damage and armor when the buff is gone.
