From: Mario Date: Sun, 30 Aug 2015 04:02:29 +0000 (+1000) Subject: Clean up rocketminsta hook X-Git-Tag: xonotic-v0.8.2~1972^2~1 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=0e462918d62248dd5d62753698df6fd8d7594333;p=xonotic%2Fxonotic-data.pk3dir.git Clean up rocketminsta hook --- diff --git a/qcsrc/server/mutators/mutator_rocketminsta.qc b/qcsrc/server/mutators/mutator_rocketminsta.qc index 217d33f1a..6b7f293d1 100644 --- a/qcsrc/server/mutators/mutator_rocketminsta.qc +++ b/qcsrc/server/mutators/mutator_rocketminsta.qc @@ -19,14 +19,12 @@ MUTATOR_HOOKFUNCTION(rm, PlayerDamage_Calculate) } MUTATOR_HOOKFUNCTION(rm, PlayerDies) -{ - if( /*(DEATH_ISWEAPON(frag_deathtype, WEP_VAPORIZER))*/ - (autocvar_g_rm && DEATH_ISWEAPON(frag_deathtype, WEP_DEVASTATOR.m_id)) - || (((autocvar_g_rm && autocvar_g_rm_laser == 1) || autocvar_g_rm_laser == 2) && DEATH_ISWEAPON(frag_deathtype, WEP_ELECTRO.m_id)) - ) - frag_damage = 1000; // always gib if it was a vaporizer death +{ + // we do it this way, so rm can be toggled during the match + if(!autocvar_g_rm) { return false; } - //(get_weaponinfo(WEP_VAPORIZER)).weaponthrowable = 1; // throwing is forbidden by a mutator hook, enabling this for drop on death + if(DEATH_ISWEAPON(frag_deathtype, WEP_DEVASTATOR.m_id) || DEATH_ISWEAPON(frag_deathtype, WEP_ELECTRO.m_id)) + frag_damage = 1000; // always gib if it was a vaporizer death return false; }