]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Small optimization
authorterencehill <piuntn@gmail.com>
Fri, 19 Aug 2016 16:15:53 +0000 (18:15 +0200)
committerterencehill <piuntn@gmail.com>
Fri, 19 Aug 2016 16:15:53 +0000 (18:15 +0200)
qcsrc/client/hud/hud.qc
qcsrc/client/hud/hud.qh

index 4eac78d0ef6de8abe856b50cef9ba2888d326787..a7898035ecca9c6217c552430d6bda73598445e6 100644 (file)
@@ -365,6 +365,7 @@ void HUD_Panel_Draw(entity panent)
        {
                if (!(panel.panel_configflags & PANEL_CONFIG_MAIN))
                        return;
+               panel_fade_alpha = 1;
                panel.panel_draw();
                return;
        }
index 77ee27d1c12ed4e8e366cd5cd16fc64e46bec4d3..8541b2091688db555135e55bd8a353ce4ebbb104 100644 (file)
@@ -367,8 +367,6 @@ REGISTER_HUD_PANEL(SCOREBOARD,      Scoreboard_Draw,    scoreboard,     PANEL_CO
 // NOTE: in hud_configure mode cvars must be reloaded every frame
 float panel_fade_alpha;
 #define HUD_Panel_LoadCvars() MACRO_BEGIN { \
-       if(autocvar__hud_configure) \
-               panel_fade_alpha = 1; \
        if (panel.update_time <= time) {                                                                                \
                if (autocvar__hud_configure) panel_enabled = cvar(strcat("hud_panel_", panel.panel_name));                  \
                panel_pos = stov(cvar_string(strcat("hud_panel_", panel.panel_name, "_pos")));                              \