]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
use the cvar values instead of "1" :P
authorFruitieX <rasse@rasse-lappy.localdomain>
Sun, 15 Aug 2010 18:42:33 +0000 (21:42 +0300)
committerFruitieX <rasse@rasse-lappy.localdomain>
Sun, 15 Aug 2010 18:42:33 +0000 (21:42 +0300)
qcsrc/client/hud.qc

index 73772505acfa04c1052cefba6b850bf670242028..495497f0377eb4e0d08bca7fb9b3c5f1eceaaa2d 100644 (file)
@@ -3742,8 +3742,20 @@ void HUD_VoteWindow(void)
        pos = panel_pos;
        mySize = panel_size;
 
-       panel_fg_alpha = 1;
-       panel_bg_alpha = 1;
+       panel_fg_alpha = autocvar_hud_panel_fg_alpha;
+       panel_bg_alpha_str = autocvar_hud_panel_vote_bg_alpha;
+
+       if(panel_bg_alpha_str == "") {
+               panel_bg_alpha_str = ftos(autocvar_hud_panel_bg_alpha);
+       }
+       panel_bg_alpha = stof(panel_bg_alpha_str);
+       if(autocvar__hud_configure && disable_menu_alphacheck == 2 && highlightedPanel == active_panel) {
+               panel_bg_alpha = (1 - autocvar__menu_alpha) * max(autocvar_hud_configure_bg_minalpha, panel_bg_alpha) + autocvar__menu_alpha * panel_bg_alpha;
+       } else if(autocvar__hud_configure) {
+               panel_bg_alpha = max(autocvar_hud_configure_bg_minalpha, panel_bg_alpha);
+       } if(autocvar__hud_configure && !panel_enabled) {
+               panel_bg_alpha = 0.25;
+       }
 
        string s;
        float a;