From: terencehill Date: Mon, 18 May 2020 21:55:13 +0000 (+0200) Subject: Fix name above dead players not starting to fade out from the current player's alpha... X-Git-Tag: xonotic-v0.8.5~1064 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=dad6065d72f70dc5866384050ece0d36b249bf64;p=xonotic%2Fxonotic-data.pk3dir.git Fix name above dead players not starting to fade out from the current player's alpha (what the FIXME comment I removed was stating is no longer true) --- diff --git a/qcsrc/client/shownames.qc b/qcsrc/client/shownames.qc index 20526d2c3..c2fc8a806 100644 --- a/qcsrc/client/shownames.qc +++ b/qcsrc/client/shownames.qc @@ -119,14 +119,12 @@ void Draw_ShowNames(entity this) this.alpha = min(1, this.alpha + SHOWNAMES_FADESPEED * frametime); } float a = autocvar_hud_shownames_alpha * this.alpha; - // multiply by player alpha if (!this.sameteam || (this.sv_entnum == player_localentnum)) { float f = entcs_GetAlpha(this.sv_entnum - 1); if (f == 0) f = 1; if (f < 0) f = 0; - // FIXME: alpha is negative when dead, breaking death fade - if (!this.csqcmodel_isdead) a *= f; + a *= f; } if (a < ALPHA_MIN_VISIBLE && ISGAMETYPE(CTS)) return; if (vdist(this.origin - view_origin, >=, max_shot_distance)) return;