From: terencehill Date: Fri, 2 Dec 2016 15:55:48 +0000 (+0100) Subject: Fix hud_shownames_antioverlap not ignoring spectators X-Git-Tag: xonotic-v0.8.2~401 X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=commitdiff_plain;h=a565bc91f697fabe7af6931ef7a37db97edd5ebd;hp=5ddd4f56a56e3dfbd4f21855d9e1e69f69551df0 Fix hud_shownames_antioverlap not ignoring spectators --- diff --git a/qcsrc/client/shownames.qc b/qcsrc/client/shownames.qc index 6a4515ac14..add8992aab 100644 --- a/qcsrc/client/shownames.qc +++ b/qcsrc/client/shownames.qc @@ -55,7 +55,11 @@ void Draw_ShowNames(entity this) if (autocvar_hud_shownames_antioverlap) { // fade tag out if another tag that is closer to you overlaps - LL_EACH(shownames_ent, it != this && entcs_receiver(i), { + entity entcs = NULL; + LL_EACH(shownames_ent, it != this, { + entcs = entcs_receiver(i); + if (!(entcs && entcs.has_sv_origin)) + continue; vector eo = project_3d_to_2d(it.origin); if (eo.z < 0 || eo.x < 0 || eo.y < 0 || eo.x > vid_conwidth || eo.y > vid_conheight) continue; eo.z = 0;