seta hud_panel_scoreboard_table_highlight "" "enable highlighting for rows and columns in scoreboard tables"
seta hud_panel_scoreboard_table_highlight_alpha "" "highlight alpha of a scoreboard table"
seta hud_panel_scoreboard_table_highlight_alpha_self "" "self highlight alpha of a scoreboard table"
+seta hud_panel_scoreboard_bg_teams_color_team "" "override panel team color in team tables"
seta hud_panel_scoreboard_accuracy_doublerows "" "use two rows instead of one"
seta hud_panel_scoreboard_accuracy_nocolors "" "don't use colors displaying accuracy stats"
seta hud_panel_scoreboard_table_highlight "1"
seta hud_panel_scoreboard_table_highlight_alpha "0.2"
seta hud_panel_scoreboard_table_highlight_alpha_self "0.5"
+seta hud_panel_scoreboard_bg_teams_color_team "0"
seta hud_panel_scoreboard_accuracy_doublerows "0"
seta hud_panel_scoreboard_accuracy_nocolors "0"
seta hud_panel_scoreboard_table_highlight "1"
seta hud_panel_scoreboard_table_highlight_alpha "0.08"
seta hud_panel_scoreboard_table_highlight_alpha_self "0.3"
+seta hud_panel_scoreboard_bg_teams_color_team "0"
seta hud_panel_scoreboard_accuracy_doublerows "1"
seta hud_panel_scoreboard_accuracy_nocolors "0"
seta hud_panel_scoreboard_table_highlight "1"
seta hud_panel_scoreboard_table_highlight_alpha "0.08"
seta hud_panel_scoreboard_table_highlight_alpha_self "0.3"
+seta hud_panel_scoreboard_bg_teams_color_team "0.7"
seta hud_panel_scoreboard_accuracy_doublerows "1"
seta hud_panel_scoreboard_accuracy_nocolors "0"
seta hud_panel_scoreboard_table_highlight "1"
seta hud_panel_scoreboard_table_highlight_alpha "0.08"
seta hud_panel_scoreboard_table_highlight_alpha_self "0.3"
+seta hud_panel_scoreboard_bg_teams_color_team "0.7"
seta hud_panel_scoreboard_accuracy_doublerows "1"
seta hud_panel_scoreboard_accuracy_nocolors "0"
seta hud_panel_scoreboard_table_highlight "1"
seta hud_panel_scoreboard_table_highlight_alpha "0.08"
seta hud_panel_scoreboard_table_highlight_alpha_self "0.3"
+seta hud_panel_scoreboard_bg_teams_color_team "0.7"
seta hud_panel_scoreboard_accuracy_doublerows "1"
seta hud_panel_scoreboard_accuracy_nocolors "0"
seta hud_panel_scoreboard_table_highlight "1"
seta hud_panel_scoreboard_table_highlight_alpha "0.1"
seta hud_panel_scoreboard_table_highlight_alpha_self "0.25"
+seta hud_panel_scoreboard_bg_teams_color_team "0.7"
seta hud_panel_scoreboard_accuracy_doublerows "1"
seta hud_panel_scoreboard_accuracy_nocolors "0"
// Get value for panel_bg_color: if "" fetch default, else use panel_bg_color. Convert pants, shirt or teamcolor into a vector.
#define HUD_Panel_GetColor() MACRO_BEGIN { \
- if ((teamplay) && panel_bg_color_team) { \
+ if ((teamplay) && panel_bg_color_team > 0) { \
if (autocvar__hud_configure && myteam == NUM_SPECTATOR) \
panel_bg_color = '1 0 0' * panel_bg_color_team; \
else \
panel_bg_color = myteamcolors * panel_bg_color_team; \
- } else if (autocvar_hud_configure_teamcolorforced && autocvar__hud_configure && panel_bg_color_team) { \
+ } else if (autocvar_hud_configure_teamcolorforced && autocvar__hud_configure && panel_bg_color_team > 0) { \
panel_bg_color = '1 0 0' * panel_bg_color_team; \
} else { \
if (panel_bg_color_str == "") { \
panel_bg_padding_str = cvar_string(strcat("hud_panel_", panel.panel_name, "_bg_padding")); \
HUD_Panel_GetBg(); \
if (panel.current_panel_bg != "0") { \
- HUD_Panel_GetColorTeam(); \
- HUD_Panel_GetColor(); \
HUD_Panel_GetBgAlpha(); \
HUD_Panel_GetBorder(); \
} \
+ HUD_Panel_GetColorTeam(); \
+ HUD_Panel_GetColor(); \
HUD_Panel_GetFgAlpha(); \
HUD_Panel_GetPadding(); \
panel.current_panel_bg_alpha = panel_bg_alpha; \
bool autocvar_hud_panel_scoreboard_table_highlight = true;
float autocvar_hud_panel_scoreboard_table_highlight_alpha = 0.2;
float autocvar_hud_panel_scoreboard_table_highlight_alpha_self = 0.5;
+float autocvar_hud_panel_scoreboard_bg_teams_color_team = 0;
bool autocvar_hud_panel_scoreboard_accuracy = true;
bool autocvar_hud_panel_scoreboard_accuracy_doublerows = false;
if(teamplay)
{
+ vector panel_bg_color_save = panel_bg_color;
vector team_score_baseoffset = eY * hud_fontsize.y - eX * (panel_bg_border + hud_fontsize.x * 0.5);
for(tm = teams.sort_next; tm; tm = tm.sort_next)
{
drawstring(pos + team_score_baseoffset - eX * stringwidth(str, false, hud_fontsize) + eY * hud_fontsize.y * 1.5, str, hud_fontsize, rgb, panel_fg_alpha, DRAWFLAG_NORMAL);
}
draw_endBoldFont();
-
- panel_bg_color = rgb * panel_bg_color_team;
+ if(autocvar_hud_panel_scoreboard_bg_teams_color_team > 0)
+ panel_bg_color = rgb * autocvar_hud_panel_scoreboard_bg_teams_color_team;
+ else if(panel_bg_color_team > 0)
+ panel_bg_color = rgb * panel_bg_color_team;
+ else
+ panel_bg_color = rgb;
pos = Scoreboard_MakeTable(pos, tm, panel_bg_color, bg_size);
}
- panel_bg_color = Team_ColorRGB(myteam) * panel_bg_color_team;
+ panel_bg_color = panel_bg_color_save;
}
else
{