Instead of hiding waypoints for eliminated players in CA clientside make so that...
authorterencehill <piuntn@gmail.com>
Thu, 1 Dec 2016 18:41:53 +0000 (19:41 +0100)
committerterencehill <piuntn@gmail.com>
Thu, 1 Dec 2016 18:41:53 +0000 (19:41 +0100)
This commit reverts 8923c4865 "CA: fix name tags getting displayed above eliminated players (when they are spectating or observing). It fixes #1813"

qcsrc/client/shownames.qc
qcsrc/common/ent_cs.qc
qcsrc/common/ent_cs.qh

index 76125e6..6a4515a 100644 (file)
@@ -193,8 +193,6 @@ void Draw_ShowNames_All()
                        it.sameteam = false;
                }
                bool dead = entcs_IsDead(i) || entcs_IsSpectating(i);
-               if(gametype == MAPINFO_TYPE_CA)
-                       dead = (dead || entcs_IsEliminated(i));
                if (!it.csqcmodel_isdead) setorigin(it, entcs.origin);
                it.csqcmodel_isdead = dead;
                Draw_ShowNames(it);
index da53f68..71052bd 100644 (file)
@@ -73,6 +73,11 @@ MACRO_END
                entity player = this.owner;
                sf |= BIT(0); // assume private
                do {
+                       if (!(IS_PLAYER(player)))
+                       {
+                               sf &= ENTCS_PUBLICMASK; // no private updates
+                               break;
+                       }
                        if (radar_showennemies) break;
                        if (SAME_TEAM(to, player)) break;
                        if (!(IS_PLAYER(to) || to.caplayer) && time > game_starttime) break;
index ac06dc4..65cdd83 100644 (file)
@@ -69,17 +69,6 @@ REGISTER_NET_TEMP(CLIENT_ENTCS)
        /**
      * @param i zero indexed player
      */
-    .int frags;
-       bool entcs_IsEliminated(int i)
-       {
-               bool unconnected = !playerslots[i].gotscores;
-               entity e = entcs_receiver(i);
-               return unconnected || ((e) ? e.frags : stof(getplayerkeyvalue(i, "frags"))) == FRAGS_LMS_LOSER;
-       }
-
-       /**
-     * @param i zero indexed player
-     */
        int entcs_GetClientColors(int i)
        {
                entity e = entcs_receiver(i);