From: terencehill Date: Thu, 13 Feb 2020 15:43:20 +0000 (+0100) Subject: Reset pressed keys when going observer X-Git-Tag: xonotic-v0.8.5~1145^2~10^2~2 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=58877309948072655c38e78d1d05959cf3452d83;p=xonotic%2Fxonotic-data.pk3dir.git Reset pressed keys when going observer --- diff --git a/qcsrc/server/client.qc b/qcsrc/server/client.qc index 887e00c59..5d536f894 100644 --- a/qcsrc/server/client.qc +++ b/qcsrc/server/client.qc @@ -2720,6 +2720,11 @@ void PlayerPostThink (entity this) } GetPressedKeys(this); } + else if (IS_OBSERVER(this) && STAT(PRESSED_KEYS, this)) + { + CS(this).pressedkeys = 0; + STAT(PRESSED_KEYS, this) = 0; + } if (this.waypointsprite_attachedforcarrier) { float hp = healtharmor_maxdamage(GetResource(this, RES_HEALTH), GetResource(this, RES_ARMOR), autocvar_g_balance_armor_blockpercent, DEATH_WEAPON.m_id).x;