]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/client/hud/panel/centerprint.qc
Merge branch 'DefaultUser/gametype_votescreen' into 'master'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / hud / panel / centerprint.qc
index 118f9bde6cba50b6ac60343908c9a1d6585396df..5b80690101b089e0e2cd15df07d40aa05bb9356a 100644 (file)
@@ -1,6 +1,6 @@
 #include "centerprint.qh"
 
-#include <client/scoreboard.qh>
+#include "scoreboard.qh"
 
 // CenterPrint (#16)
 
@@ -153,14 +153,7 @@ void HUD_CenterPrint ()
                }
        }
 
-       // this panel fades only when the menu does
-       float hud_fade_alpha_save = 0;
-       if(scoreboard_fade_alpha)
-       {
-               hud_fade_alpha_save = hud_fade_alpha;
-               hud_fade_alpha = 1 - autocvar__menu_alpha;
-       }
-       HUD_Panel_UpdateCvars();
+       HUD_Panel_LoadCvars();
 
        if ( HUD_Radar_Clickable() )
        {
@@ -170,17 +163,13 @@ void HUD_CenterPrint ()
                panel_pos = eY * hud_panel_radar_bottom + eX * 0.5 * (vid_conwidth - panel_size_x);
                panel_size_y = min(panel_size_y, vid_conheight - hud_panel_radar_bottom);
        }
-       else if(scoreboard_fade_alpha)
+       else if(!autocvar__hud_configure && scoreboard_fade_alpha)
        {
-               hud_fade_alpha = hud_fade_alpha_save;
-
                // move the panel below the scoreboard
                if (scoreboard_bottom >= 0.96 * vid_conheight)
                        return;
                vector target_pos;
-
                target_pos = eY * scoreboard_bottom + eX * 0.5 * (vid_conwidth - panel_size.x);
-
                if(target_pos.y > panel_pos.y)
                {
                        panel_pos = panel_pos + (target_pos - panel_pos) * sqrt(scoreboard_fade_alpha);
@@ -192,7 +181,7 @@ void HUD_CenterPrint ()
                HUD_Scale_Enable();
        else
                HUD_Scale_Disable();
-       HUD_Panel_DrawBg(1);
+       HUD_Panel_DrawBg();
 
        if (!centerprint_showing)
                return;