Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
This map contains plenty of triggers and I'm pretty good with coding
hello, is there any ability that gives +HP and + Dmg for certain amount of time?
the point is I want to do something like this, a hero uses an item on a unit and that unit has the aura that increases +hp and + dmg for 20 seconds
Boost Cast

Events


Unit - A unit Starts the effect of an ability

Conditions


(Ability being cast) Equal to Boost


((Target unit of ability being cast) has buff Boost ) Equal to False

Actions


Unit - Add Boost Damage Bonus to (Target unit of ability being cast)


Unit - Add Boost Life Bonus to (Target unit of ability being cast)


Unit Group - Add (Target unit of ability being cast) to Boost_BuffedUnits


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



If - Conditions




(Number of units in Boost_BuffedUnits) Equal to 1



Then - Actions




Trigger - Turn on Boost Unit Group <gen>



Else - Actions
Boost Unit Group

Events


Time - Every 0.50 seconds of game time

Conditions

Actions


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



Loop - Actions




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





If - Conditions






((Picked unit) has buff Boost ) Equal to True





Then - Actions





Else - Actions






Unit Group - Remove (Picked unit) from Boost_BuffedUnits






Unit - Remove Boost Life Bonus from (Picked unit)






Unit - Remove Boost Damage Bonus from (Picked unit)


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



If - Conditions




(Number of units in Boost_BuffedUnits) Equal to 0



Then - Actions




Trigger - Turn off (This trigger)



Else - Actions
well, thx, I understand thisbut it won't lag since it's checking a condition each 0.5 sec?
@edit
well licheus I did everything you give me and I have a problem, when I buff my unit, my unit doesn't receive + hp and + dmg, although it has the buff. Do you know what may be the problem?
@EDIT x2 - ok it worksI had wrong condition in one trigger, it works now, thx mate
really good idea. Now I will know how to implement buffs
thx
Avatar does what you want on a unit by unit basis but may also make them spell immune (not intended).
