diff options
author | Jesusaves <cpntb1@ymail.com> | 2019-06-18 14:13:41 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2019-06-18 14:13:41 -0300 |
commit | 14439b05bd6f1606839a63e023420cedb086f805 (patch) | |
tree | b42eed52d037644d2fd09474e437a874acf11f78 /npc | |
parent | 268c4eb59d9422a8f0fc3f5a7c2f06c9fc483c2c (diff) | |
download | serverdata-14439b05bd6f1606839a63e023420cedb086f805.tar.gz serverdata-14439b05bd6f1606839a63e023420cedb086f805.tar.bz2 serverdata-14439b05bd6f1606839a63e023420cedb086f805.tar.xz serverdata-14439b05bd6f1606839a63e023420cedb086f805.zip |
Grenades now doesn't work on BOSS monsters.
It's more fair this way.
Diffstat (limited to 'npc')
-rw-r--r-- | npc/items/grenade.txt | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/npc/items/grenade.txt b/npc/items/grenade.txt index 5768b66cd..c9379bbff 100644 --- a/npc/items/grenade.txt +++ b/npc/items/grenade.txt @@ -4,7 +4,6 @@ // Description: // Grenades workaround -// Main loop - TODO: Should not affect boss // grenade(range, damage - in 0.01%, flag) - defaults to 3x3 square, with 5% damage. // If flag is set, damage will be deemed to be absolute values. function script grenade { @@ -18,13 +17,14 @@ function script grenade { .@dm=max(1, .@hp*(10000-.@d)/10000); if (getarg(2, false)) .@dm=max(1, .@hp-.@d); - //debugmes "Hitting monster (%d hp) for %d damage", .@hp, .@dm; - setunitdata(.@mbs[.@i], UDT_HP, .@dm); - specialeffect(FX_ATTACK, AREA, .@mbs[.@i]); + if (!(getunitdata(.@mbs[.@i], UDT_MODE) & 32)) { // 32 = MD_BOSS + //debugmes "Hitting monster (%d hp) for %d damage", .@hp, .@dm; + setunitdata(.@mbs[.@i], UDT_HP, .@dm); + specialeffect(FX_ATTACK, AREA, .@mbs[.@i]); + } } return; } -// TODO: Should not affect boss // smoke_grenade(range, time) - defaults to 3x3 square, stun for 500ms. function script smoke_grenade { |