How To Create A Trigger That...

Arash5

New Member
Reaction score
0
H!
I Wanna Create A Trigger That If A Spell Casted The Health Of Caster Decreases Like 20% of Correct Health NOT All Of Health Pls Help Me


Thank,You
 

skyblader

You're living only because it's illegal killing.
Reaction score
159
What is correct health?

Just do something like

Unit begins the effect of an ability

Ability = whatever ability

Set life of triggering unit to 80% of current/max.
 

Arash5

New Member
Reaction score
0
it means that max health is for example 300 but the unit is damaged and its health is 100 i wanna Decreas The 100 To 50 How Can I Do This
 

Ryushi

"I will stand, or I will fall. I will not sit."
Reaction score
59
Like Skyblade333 said, you would want to do something like this:
Trigger:
  • trigger
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to 'Your Ability'
    • Actions
      • Unit - Set life of (Triggering unit) to ((Life of (Triggering unit)) x 0.80)

In the example you just said, 50 is 50% of 100 so if you wanted a 50% decrease instead of a 20% decrease, replace the 0.80 with 0.50.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top