This site works best with JavaScript enabled. Please enable JavaScript to get the best experience from this site.
Hello guys. Is there some way to make such event? I mean the event that would trigger when some unit's hp would be equal or lower than in example 20%?
Im not aprogrammer and i have hard time tyring to find some way trough triggers to make such event working :/
thanks in advance regards Muniek
Event - Any Unit Takes Damge
Condition - triggering units current hp < (units max hp / 5 )
Action - Do stuff
make an event to:
any unit takes damage
and than make the condition check the amount of hp the unit has
it would look something like this
Events Unit - Any Unit takes Fatal or Non-Fatal Any damage (from Any effects) Local Variables Conditions ((Triggering unit) Life (Current)) <= (Value 1 / 1.0)
if you need helping putting that in, ill be happy to help
but on the second value, instead of putting a value, you click "functions" then "math" then there are the extra options you need.
Thanks guys. I myself had a lot of simple solution but they were denied by editors limits.
Thanks a lot Molsterr, will try to go that way.
FOUND IT! thanks again!!
edit: but i cant add any other thing in "Value" than solid numbers. :( edit2: ok nvm found it aswell :P
THANKS A LOT I LOVE YOU PEOPLE!
@Azzaaer: Go
To clarify what the OP found in the event someone else comes across this thread:
To make a comparison based off percentage instead of solid numbers you need to use the "Life(Percent)" Preset rather than "Life".
or you can check current hp vs the LifeMax the unit has in the data editor from get catalog field value
Hello guys. Is there some way to make such event? I mean the event that would trigger when some unit's hp would be equal or lower than in example 20%?
Im not aprogrammer and i have hard time tyring to find some way trough triggers to make such event working :/
thanks in advance regards Muniek
Event - Any Unit Takes Damge
Condition - triggering units current hp < (units max hp / 5 )
Action - Do stuff
make an event to:
any unit takes damage
and than make the condition check the amount of hp the unit has
it would look something like this
if you need helping putting that in, ill be happy to help
but on the second value, instead of putting a value, you click "functions" then "math" then there are the extra options you need.
Thanks guys. I myself had a lot of simple solution but they were denied by editors limits.
Thanks a lot Molsterr, will try to go that way.
FOUND IT! thanks again!!
edit: but i cant add any other thing in "Value" than solid numbers. :( edit2: ok nvm found it aswell :P
THANKS A LOT I LOVE YOU PEOPLE!
@Azzaaer: Go
To clarify what the OP found in the event someone else comes across this thread:
To make a comparison based off percentage instead of solid numbers you need to use the "Life(Percent)" Preset rather than "Life".
or you can check current hp vs the LifeMax the unit has in the data editor from get catalog field value