]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/ent_cs.qh
Merge branch 'z411/ca-prevent-observer' into z411/bai-server
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / ent_cs.qh
index 33bde3a6064b8ebcd951547a24d1fec60d9c553e..bd76c6b6b123f7d03044cb0c0898b0cab15f322c 100644 (file)
@@ -1,7 +1,7 @@
 #pragma once
 
 #ifdef CSQC
-#include <client/defs.qh>
+#include <client/csqcmodel_hooks.qh>
 #endif
 
 REGISTER_NET_LINKED(ENT_CLIENT_ENTCS)
@@ -12,15 +12,13 @@ REGISTER_NET_TEMP(CLIENT_ENTCS)
 .bool m_entcs_private;
 
 /** True when origin is available */
-// FIXME: it seems sometimes this is false when observing even though observers should be able to know about all players
-// easily reproducible on heart_v2 or The_Yard with bots - might be because they lack waypoints and bots stand still
-// it has happened in matches with players and no bots but much more rarely
 .bool has_origin;
 
 /** True when a recent server sent origin has been received */
 .bool has_sv_origin;
-.int sv_solid;
 #endif
+.int sv_solid;
+.int activewepid; // z411
 
 #ifdef SVQC
 /*
@@ -47,6 +45,10 @@ REGISTER_NET_TEMP(CLIENT_ENTCS)
 
        void entcs_force_origin(entity player);
 
+       void entcs_update_players(entity player);
+
+       bool radar_showenemies;
+
 #endif
 
 #ifdef CSQC
@@ -131,6 +133,18 @@ REGISTER_NET_TEMP(CLIENT_ENTCS)
                entity e = entcs_receiver(i);
                return ColorTranslateRGB(e ? e.netname : getplayerkeyvalue(i, "name"));
        }
+       
+       int entcs_GetCountryCode(int i)
+       {
+               entity e = entcs_receiver(i);
+               return e.countrycode;
+       }
+       
+       string entcs_GetRank(int i)
+       {
+               entity e = entcs_receiver(i);
+               return e.rank;
+       }
 
     /**
      * @param i zero indexed player