| 02-04-2007, 09:34 PM | #1 |
Well, my question is: when you trigger a spell, what KIND of damage/attack do you use to emulate a default game spell (for example Storm Bolt)? I normally use a function like this: JASS:UnitDamageTarget( source, target, true, false, ATTACK_TYPE_NORMAL, DAMAGE_TYPE_UNIVERSAL, WEAPON_TYPE_WHOKNOWS ) I'll explain better: if you use lv. 1 Storm Bolt on a footman, it will deal exactly 100 damage (~70 on a hero), but if you use the previous function the damage dealt will be ~90 (cause a footman has 2 armor). Anyone noticed this? Thanks. |
| 02-04-2007, 11:12 PM | #2 |
its magic or spell for spell damage or use choase damage type for the full effect -Av3n |
| 02-05-2007, 01:49 AM | #3 |
Yes, this function does damage taking in account the target armor type. In order to emulate a damage dealt by a magic attack, the code should be in this way: JASS:call UnitDamageTarget(u, t, 100, true, false, ATTACK_TYPE_MAGIC, DAMAGE_TYPE_MAGIC, WEAPON_TYPE_WHOKNOWS) |
| 02-05-2007, 12:35 PM | #4 | |
Quote:
In my opinion, the only way to emulate a default spell damage (not necessary a ultimate) the damage function should be like this: JASS:call UnitDamageTarget(u, t, 100, true, false, ATTACK_TYPE_NORMAL, DAMAGE_TYPE_UNIVERSAL, WEAPON_TYPE_WHOKNOWS) |
| 02-05-2007, 07:28 PM | #5 |
Hero armor by default takesd less damage from spells you can change that in gamplaye comstantsd -Av3n |
| 02-05-2007, 09:01 PM | #6 |
My question was not: "why do heroes receive less damage from spell"... But, why does my function only works with "UNIVERSAL"? |
| 02-06-2007, 05:48 AM | #7 | |
Quote:
-Av3n |
| 02-10-2007, 03:28 PM | #8 | |
Quote:
|
| 02-10-2007, 08:37 PM | #9 |
Well, I use NORMAL and NORMAL because I want damage to be reduced by armor. That would simulate the damage dealt same way as with a footman attacking. |
| 02-10-2007, 08:50 PM | #10 |
Afaik blizzard once said that NORMAL is the one used by spells... |
