]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Only show the health bar on turrets (no names) by default
authorMario <zacjardine@y7mail.com>
Sat, 8 Sep 2018 10:14:34 +0000 (20:14 +1000)
committerMario <zacjardine@y7mail.com>
Sat, 8 Sep 2018 10:14:34 +0000 (20:14 +1000)
qcsrc/common/mutators/mutator/waypoints/waypointsprites.qh
qcsrc/common/turrets/cl_turrets.qc

index 9bfa4862befc03fb6e9a7f8d9184787922b89e7c..e2190b66a26a9cef1c0efb477c51d53c7276422c 100644 (file)
@@ -52,6 +52,7 @@ int autocvar_g_waypointsprite_spam;
 float autocvar_g_waypointsprite_timealphaexponent;
 bool autocvar_g_waypointsprite_turrets = true;
 float autocvar_g_waypointsprite_turrets_maxdist = 5000;
+bool autocvar_g_waypointsprite_turrets_text = false;
 bool autocvar_g_waypointsprite_uppercase;
 bool autocvar_g_waypointsprite_text;
 float autocvar_g_waypointsprite_iconsize = 32;
index ac68003a6cde83c1a6b652959af1f349240654e1..6cdda5103955a428443e1194c0711c310d692fe5 100644 (file)
@@ -176,7 +176,10 @@ void turret_draw2d(entity this)
        }
 
        o = drawspritearrow(o, M_PI, rgb, a, SPRITE_ARROW_SCALE * t);
-       o = drawsprite_TextOrIcon(true, o, M_PI, (SPRITE_HEALTHBAR_WIDTH + 2 * SPRITE_HEALTHBAR_BORDER) * t, rgb, a, waypointsprite_fontsize * '1 1 0', txt);
+       if(autocvar_g_waypointsprite_turrets_text)
+       {
+               o = drawsprite_TextOrIcon(true, o, M_PI, (SPRITE_HEALTHBAR_WIDTH + 2 * SPRITE_HEALTHBAR_BORDER) * t, rgb, a, waypointsprite_fontsize * '1 1 0', txt);
+       }
        drawhealthbar(
                        o,
                        0,