From: otta8634 Date: Sat, 21 Dec 2024 06:42:40 +0000 (+0800) Subject: Show Vaporizer damagetext when not playing InstaGib X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=120e9b9cc50d0ac15bad7bac5cf193c8ea48b0be;p=xonotic%2Fxonotic-data.pk3dir.git Show Vaporizer damagetext when not playing InstaGib I didn't even know it did 150 damage... --- diff --git a/qcsrc/common/mutators/mutator/damagetext/sv_damagetext.qc b/qcsrc/common/mutators/mutator/damagetext/sv_damagetext.qc index 7c9043e00..11f10345b 100644 --- a/qcsrc/common/mutators/mutator/damagetext/sv_damagetext.qc +++ b/qcsrc/common/mutators/mutator/damagetext/sv_damagetext.qc @@ -1,5 +1,7 @@ #include "sv_damagetext.qh" +#include + AUTOCVAR(sv_damagetext, int, 2, "<= 0: disabled, >= 1: visible to spectators, >= 2: visible to attacker, >= 3: all players see everyone's damage"); REGISTER_MUTATOR(damagetext, true); @@ -67,7 +69,7 @@ MUTATOR_HOOKFUNCTION(damagetext, PlayerDamaged) { float armor = M_ARGV(3, float); int deathtype = M_ARGV(5, int); float potential_damage = M_ARGV(6, float); - if(DEATH_WEAPONOF(deathtype) == WEP_VAPORIZER) return; + if(autocvar_g_instagib && DEATH_WEAPONOF(deathtype) == WEP_VAPORIZER) return; static entity net_text_prev; static float net_damagetext_prev_time;