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

[Solved] DamageTarget's nulls

Status
Not open for further replies.
Level 19
Joined
Dec 12, 2010
Messages
2,074
JASS:
call UnitDamageTarget( source, target, damage, true, true, null, null, null)
This causes unit to receive the damage whatever it takes, through any defense. Basically it's direct HP removal, but it does get registered as damage, following it's rules about amplifiers and such.
Did anyone used this? Any backsides on this method comparing to DHR?
 
Last edited by a moderator:
Level 13
Joined
Nov 7, 2014
Messages
571
JASS:
call UnitDamageTarget( source, target, damage, true, true, null, null, null)

constant attacktype ATTACK_TYPE_NORMAL = ConvertAttackType(0)
constant damagetype DAMAGE_TYPE_UNKNOWN = ConvertDamageType(0)

// Jass's null probably== C++'s 0(zero), so

// the above is probably equivalent to:
call UnitDamageTarget( source, target, damage, true, true, ATTACK_TYPE_NORMAL, DAMAGE_TYPE_UNKNOWN, null)

Spell damage (aka ATTACK_TYPE_NORMAL in Jass) (spell damage is what "normal" spells do, I guess...), is reduced by armor type hero/divine and runed bracers.
It gets amplified by the ethereal-ness of the target unit, i.e storm bolt lvl3 (375 damage) + banish = dead fiend (fiend-hp = 550) =)
 
Level 19
Joined
Dec 12, 2010
Messages
2,074
JASS:
call UnitDamageTarget( source, target, damage, true, true, null, null, null)

constant attacktype ATTACK_TYPE_NORMAL = ConvertAttackType(0)
constant damagetype DAMAGE_TYPE_UNKNOWN = ConvertDamageType(0)

// Jass's null probably== C++'s 0(zero), so

// the above is probably equivalent to:
call UnitDamageTarget( source, target, damage, true, true, ATTACK_TYPE_NORMAL, DAMAGE_TYPE_UNKNOWN, null)

Spell damage (aka ATTACK_TYPE_NORMAL in Jass) (spell damage is what "normal" spells do, I guess...), is reduced by armor type hero/divine and runed bracers.
It gets amplified by the ethereal-ness of the target unit, i.e storm bolt lvl3 (375 damage) + banish = dead fiend (fiend-hp = 550) =)

yep, you're right. I had wrong information. This type doesn't penetrate invul either.
/thread
 
Status
Not open for further replies.
Top