• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] Damage Percentual

Status
Not open for further replies.
Level 14
Joined
Nov 17, 2020
Messages
188
I have a little problem, i want to make the attacks of a RANGED unit drain a percentual of the life of the target unit, i used the event "a unit is attacked", but that event starts a bit before the attack begins (for example, Thrall attacks a unit but before shooting the projectile the event triggers), so i was wondering how to enable the trigger when the target is damaged by the RANGED unit.
 

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,877
You can use a Damage Engine like this one: Damage Engine 5.7.1.2

After copying over the System Folder into your map you would create a trigger like this:
  • Events:
  • Game - DamageEvent becomes Equal to 1.00
  • Conditions:
  • IsDamageRanged Equal to True
  • Unit-Type of DamageEventSource Equal to YourUnitType
  • Actions:
  • Set Variable DamageEventAmount = DamageEventAmount + (Life of DamageEventTarget * 0.05)
I go into more details in this thread -> Damage systems obsolete?
 
Level 14
Joined
Nov 17, 2020
Messages
188
You can use a Damage Engine like this one: Damage Engine 5.7.1.2

After copying over the System Folder into your map you would create a trigger like this:
  • Events:
  • Game - DamageEvent becomes Equal to 1.00
  • Conditions:
  • IsDamageRanged Equal to True
  • Unit-Type of DamageEventSource Equal to YourUnitType
  • Actions:
  • Set Variable DamageEventAmount = DamageEventAmount + (Life of DamageEventTarget * 0.05)
I go into more details in this thread -> Damage systems obsolete?
Yoooo thanks a lot, i didn't knew that Damage Engine, it will be very usefull
 
Status
Not open for further replies.
Top