]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Allow the client to disable showing waypoints of health and armor when spectating
authorterencehill <piuntn@gmail.com>
Thu, 15 Dec 2011 18:34:37 +0000 (19:34 +0100)
committerterencehill <piuntn@gmail.com>
Thu, 15 Dec 2011 20:33:19 +0000 (21:33 +0100)
defaultXonotic.cfg
qcsrc/client/autocvars.qh
qcsrc/client/waypointsprites.qc

index 1044e8abfa4a745a370c2345346b28320251b1c1..a2f732f5b9fff53a2fef89a8e22a3f787e7c021d 100644 (file)
@@ -1308,6 +1308,7 @@ seta g_waypointsprite_crosshairfadedistance 150 "distance in virtual pixels from
 seta g_waypointsprite_distancefadealpha 1 "alpha multiplier near distance"
 seta g_waypointsprite_distancefadescale 0.7 "scale multiplier near the distance"
 seta g_waypointsprite_distancefadedistancemultiplier 0.5 "distance in map sizes from distance where to stop fading"
+seta g_waypointsprite_items_for_spectators 1 "show waypoints when spectating to indicate that some important items (mega health, large armor) are about to respawn"
 set g_waypointsprite_spam 0 "Debugging feature. Set to 10 and load courtfun in race mode to test."
 alias "g_waypointsprite_personal"      "impulse 30"
 alias "g_waypointsprite_personal_p"    "impulse 31"
index a0908cc392007a420d882e2103cb0dd761681674..28f37d6f035af738432a3ecf043de9d40842e43c 100644 (file)
@@ -145,6 +145,7 @@ float autocvar_g_waypointsprite_edgeoffset_left;
 float autocvar_g_waypointsprite_edgeoffset_right;
 float autocvar_g_waypointsprite_edgeoffset_top;
 float autocvar_g_waypointsprite_fontsize;
+float autocvar_g_waypointsprite_items_for_spectators;
 float autocvar_g_waypointsprite_minalpha;
 float autocvar_g_waypointsprite_minscale;
 float autocvar_g_waypointsprite_normdistance;
index c8cac0df9fd62c21e37eedb50d7688d5f683cf5d..37e3d685b4304a3554718ac15be94a34337e0c57 100644 (file)
@@ -415,6 +415,8 @@ void Draw_WaypointSprite()
        switch(self.rule)
        {
                case SPRITERULE_SPECTATOR:
+                       if(!autocvar_g_waypointsprite_items_for_spectators)
+                               return;
                case SPRITERULE_DEFAULT:
                        if(self.team)
                        {