From: TimePath Date: Tue, 6 Oct 2015 23:03:28 +0000 (+1100) Subject: Nades: always override dropweapon X-Git-Tag: xonotic-v0.8.2~1863 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=48377912c45d423247c49443f507d29f0229fe32;p=xonotic%2Fxonotic-data.pk3dir.git Nades: always override dropweapon --- diff --git a/qcsrc/server/autocvars.qh b/qcsrc/server/autocvars.qh index 454feedfb..affd9437e 100644 --- a/qcsrc/server/autocvars.qh +++ b/qcsrc/server/autocvars.qh @@ -723,6 +723,7 @@ float autocvar_g_random_gravity_positive; float autocvar_g_random_gravity_negative; float autocvar_g_random_gravity_delay; bool autocvar_g_nades; +bool autocvar_g_nades_override_dropweapon = true; vector autocvar_g_nades_throw_offset; bool autocvar_g_nades_spawn; int autocvar_g_nades_spawn_count; diff --git a/qcsrc/server/mutators/mutator_nades.qc b/qcsrc/server/mutators/mutator_nades.qc index d4cebf9d7..4fdbbd353 100644 --- a/qcsrc/server/mutators/mutator_nades.qc +++ b/qcsrc/server/mutators/mutator_nades.qc @@ -952,7 +952,7 @@ NadeOffhand OFFHAND_NADE; STATIC_INIT(OFFHAND_NADE) { OFFHAND_NADE = NEW(NadeOff MUTATOR_HOOKFUNCTION(nades_CheckThrow) { - if (self.offhand != OFFHAND_NADE || (self.weapons & WEPSET(HOOK))) { + if (self.offhand != OFFHAND_NADE || (self.weapons & WEPSET(HOOK)) || autocvar_g_nades_override_dropweapon) { nades_CheckThrow(); return true; }