From: Lyberta Date: Thu, 1 Jun 2017 12:08:21 +0000 (+0300) Subject: Call PlayerDamaged even if damage is 0. Very useful in instagib. X-Git-Tag: xonotic-v0.8.5~2745^2 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=ac54bdc9f4821ef0658d1b1ca94abde4eeae113c;p=xonotic%2Fxonotic-data.pk3dir.git Call PlayerDamaged even if damage is 0. Very useful in instagib. --- diff --git a/qcsrc/server/player.qc b/qcsrc/server/player.qc index faa3c8101..5aae35599 100644 --- a/qcsrc/server/player.qc +++ b/qcsrc/server/player.qc @@ -506,10 +506,8 @@ void PlayerDamage(entity this, entity inflictor, entity attacker, float damage, { WeaponStats_LogDamage(awep.m_id, abot, this.(weaponentity).m_weapon.m_id, vbot, dh + da); } - if (damage) - { - MUTATOR_CALLHOOK(PlayerDamaged, attacker, this, dh, da, hitloc, deathtype, damage); - } + + MUTATOR_CALLHOOK(PlayerDamaged, attacker, this, dh, da, hitloc, deathtype, damage); if (this.health < 1) {