• 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.

"Unit is going to deal damage" Event?

Status
Not open for further replies.

Tzi

Tzi

Level 4
Joined
Jan 7, 2009
Messages
57
Hi!

Is there any possibility to detect an event before the calculating of damage dealt from unit x to unit y?
E.g. to make an enhanced evasion ability or something like this.

The "unit attacks unit" event is able to detect it, but it's a bit ugly cause it reacts to every right click. So if someone is insane and clicks an enemy (and his mouse) to death it will trigger many times instead of 1 attack^^
 
Level 7
Joined
May 18, 2010
Messages
264
You can do the same trick as Viper is DotA has.
He recieves bonus damage in amount of hp lost by attacked enemy. The more loss, the more damage he gets.

Its triggered by normal Event Unit is attacked, with adding 'bonus damage ability' for short period of time. It's about 0.3 or so, because if you want the attack to deal bonus damage, 0.3 is enought, clicking Stop wo'nt help here, since Viper's attack animation takes about 0.25 sec.

Time dummy ability with short duration, and refer to that one while checking is actions should be fired or not.
For timing abilities I recommend my system (see signature).
 

Tzi

Tzi

Level 4
Joined
Jan 7, 2009
Messages
57
I have in my map all types of bonus damage abilities made. It's quite simple^^

But I want to detect the action before the damage is dealt for avoiding the death of a unit although it would be evade / parry / and so on...

I really won't to give an additional text to the tooltip that tells you that deadly strikes can't proc this ability :p
 
Status
Not open for further replies.
Top