}
}
-void Cmd_HUD_Help(float argc)
+void Cmd_HUD_Help()
{
print(_("You can modify the scoreboard using the ^2scoreboard_columns_set command.\n"));
print(_("^3|---------------------------------------------------------------|\n"));
float missing;
// TODO: re enable with gametype dependant cvars?
- if(argc < 2) // no arguments provided
+ if(argc < 3) // no arguments provided
argc = tokenizebyseparator(strcat("x ", autocvar_scoreboard_columns), " ");
- if(argc < 2)
+ if(argc < 3)
argc = tokenizebyseparator(strcat("x ", HUD_DefaultColumnLayout()), " ");
- if(argc == 2)
+ if(argc == 3)
{
- if(argv(1) == "default")
+ if(argv(2) == "default")
argc = tokenizebyseparator(strcat("x ", HUD_DefaultColumnLayout()), " ");
- else if(argv(1) == "all")
+ else if(argv(2) == "all")
{
string s;
- s = "ping pl color name |";
+ s = "ping pl name |";
for(i = 0; i < MAX_SCORE; ++i)
{
if(i != ps_primary)
case SP_PING:
if not(pl.gotscores)
return "\xEE\x82\x8D\xEE\x82\x8D\xEE\x82\x8D"; // >>> sign
- //str = getplayerkey(pl.sv_entnum, "ping");
+ //str = getplayerkeyvalue(pl.sv_entnum, "ping");
f = pl.ping;
if(f == 0)
return _("N/A");
}
else if(!teamplay)
{
- f = stof(getplayerkey(pl.sv_entnum, "colors"));
+ f = stof(getplayerkeyvalue(pl.sv_entnum, "colors"));
{
hud_field_icon0 = "gfx/scoreboard/playercolor_base";
hud_field_icon1 = "gfx/scoreboard/playercolor_shirt";
if(hud_field_icon0 != "")
{
- sz = drawgetimagesize(hud_field_icon0);
+ sz = draw_getimagesize(hud_field_icon0);
f = sz_x / sz_y;
if(hud_fixscoreboardcolumnwidth_iconlen < f)
hud_fixscoreboardcolumnwidth_iconlen = f;
if(hud_field_icon1 != "")
{
- sz = drawgetimagesize(hud_field_icon1);
+ sz = draw_getimagesize(hud_field_icon1);
f = sz_x / sz_y;
if(hud_fixscoreboardcolumnwidth_iconlen < f)
hud_fixscoreboardcolumnwidth_iconlen = f;
if(hud_field_icon2 != "")
{
- sz = drawgetimagesize(hud_field_icon2);
+ sz = draw_getimagesize(hud_field_icon2);
f = sz_x / sz_y;
if(hud_fixscoreboardcolumnwidth_iconlen < f)
hud_fixscoreboardcolumnwidth_iconlen = f;
{
if(pl.team != tm.team)
continue;
- HUD_PrintScoreboardItem(pos, pl, (pl.sv_entnum == player_localentnum - 1), i);
+ HUD_PrintScoreboardItem(pos, pl, (pl.sv_entnum == player_localnum), i);
pos_y += 1.25 * hud_fontsize_y;
++i;
}
{
if(pl.team == COLOR_SPECTATOR)
continue;
- HUD_PrintScoreboardItem(pos, pl, (pl.sv_entnum == player_localentnum - 1), i);
+ HUD_PrintScoreboardItem(pos, pl, (pl.sv_entnum == player_localnum), i);
pos_y += 1.25 * hud_fontsize_y;
++i;
}
return 1;
else if (intermission == 2)
return 0;
- else if (spectatee_status != -1 && getstati(STAT_HEALTH) <= 0 && autocvar_cl_deathscoreboard && gametype != GAME_CTS)
+ else if (spectatee_status != -1 && getstati(STAT_HEALTH) <= 0 && autocvar_cl_deathscoreboard && gametype != MAPINFO_TYPE_CTS)
return 1;
else if (scoreboard_showscores_force)
return 1;
if (!acc_levels)
rgb = '1 1 1';
- else if (acc_col_x[0] == -1)
+ else if (acc_col[0] == '-1 0 0')
for (i = 0; i < acc_levels; ++i)
acc_col[i] = stov(cvar_string(strcat("accuracy_color", ftos(i))));
for(i = WEP_FIRST; i <= WEP_LAST; ++i)
{
self = get_weaponinfo(i);
- if not(self.weapons)
+ if not(self.weapon)
continue;
if ((i == WEP_NEX && g_minstagib) || i == WEP_PORTO || (i == WEP_MINSTANEX && !g_minstagib) || i == WEP_TUBA) // skip port-o-launch, nex || minstanex and tuba
continue;
continue;
n = grecordholder[i];
p = race_PlaceName(i+1);
- if(grecordholder[i] == GetPlayerName(player_localentnum - 1))
+ if(grecordholder[i] == GetPlayerName(player_localnum))
drawfill(pos, '1 0 0' * sbwidth + '0 1.25 0' * hud_fontsize_y, hl_rgb, scoreboard_highlight_alpha_self, DRAWFLAG_NORMAL);
else if(!mod(i, 2) && scoreboard_highlight)
drawfill(pos, '1 0 0' * sbwidth + '0 1.25 0' * hud_fontsize_y, hl_rgb, scoreboard_highlight_alpha, DRAWFLAG_NORMAL);
pos_y += sb_heading_fontsize_y + hud_fontsize_y * 0.25;
// Draw the scoreboard
- vector bg_size = drawgetimagesize("gfx/scoreboard/scoreboard_bg") * autocvar_scoreboard_bg_scale;
+ vector bg_size = draw_getimagesize("gfx/scoreboard/scoreboard_bg") * autocvar_scoreboard_bg_scale;
if(teamplay)
{
}
}
- if(gametype == GAME_CTS || gametype == GAME_RACE) {
+ if(gametype == MAPINFO_TYPE_CTS || gametype == MAPINFO_TYPE_RACE) {
if(race_speedaward) {
drawcolorcodedstring(pos, sprintf(_("Speed award: %d ^7(%s^7)"), race_speedaward, race_speedaward_holder), hud_fontsize, scoreboard_alpha_fg, DRAWFLAG_NORMAL);
pos_y += 1.25 * hud_fontsize_y;
if(pl.team != COLOR_SPECTATOR)
continue;
pos_y += 1.25 * hud_fontsize_y;
- HUD_PrintScoreboardItem(pos, pl, (pl.sv_entnum == player_localentnum - 1), specs);
+ HUD_PrintScoreboardItem(pos, pl, (pl.sv_entnum == player_localnum), specs);
++specs;
}
tl = getstatf(STAT_TIMELIMIT);
fl = getstatf(STAT_FRAGLIMIT);
ll = getstatf(STAT_LEADLIMIT);
- if(gametype == GAME_LMS)
+ if(gametype == MAPINFO_TYPE_LMS)
{
if(tl > 0)
str = strcat(str, sprintf(_(" for up to ^1%1.0f minutes^7"), tl));