- wget -O data/maps/stormkeep.waypoints https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.waypoints\r
- wget -O data/maps/stormkeep.waypoints.cache https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.waypoints.cache\r
\r
- - EXPECT=a728d38448ae86459582804aa10320c0\r
+ - EXPECT=458e9e611a757c745da05c85a37e576d\r
- HASH=$(${ENGINE} +timestamps 1 +exec serverbench.cfg\r
| tee /dev/stderr\r
| sed -e 's,^\[[^]]*\] ,,'\r
-Tue May 3 07:23:14 CEST 2022
+Sat May 28 07:23:08 CEST 2022
# Adam Říha, 2021
# Adam Říha, 2021
# fasdasd sdasd <transifexalternativeaccount@yopmail.com>, 2021
-# gamingforyou875 <gamingforyou875@gmail.com>, 2019
-# gamingforyou875 <gamingforyou875@gmail.com>, 2019
+# GamingasCZ <gamingforyou875@gmail.com>, 2019
+# GamingasCZ <gamingforyou875@gmail.com>, 2019
# Jan Kocka <kockahonza@gmail.com>, 2019
# Jiří Vrána <jirkacz199@gmail.com>, 2020-2021
# Martin Taibr <taibr.martin@gmail.com>, 2017
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? "
+"1 : 2;\n"
#: qcsrc/client/announcer.qc:45
msgid "vs"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? "
+"1 : 2;\n"
#: qcsrc/client/announcer.qc:45
msgid "vs"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=2; plural=(n > 1);\n"
+"Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % "
+"1000000 == 0 ? 1 : 2;\n"
#: qcsrc/client/announcer.qc:45
msgid "vs"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? "
+"1 : 2;\n"
#: qcsrc/client/announcer.qc:45
msgid "vs"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=3; plural=(n == 1 ? 0 : n == 2 ? 1 : 2);\n"
+"Plural-Forms: nplurals=6; plural=n == 0 ? 0 : n == 1 ? 1 : (n % 100 == 2 || "
+"n % 100 == 22 || n % 100 == 42 || n % 100 == 62 || n % 100 == 82) || n % "
+"1000 == 0 && (n % 100000 >= 1000 && n % 100000 <= 20000 || n % 100000 == "
+"40000 || n % 100000 == 60000 || n % 100000 == 80000) || n != 0 && n % "
+"1000000 == 100000 ? 2 : (n % 100 == 3 || n % 100 == 23 || n % 100 == 43 || n "
+"% 100 == 63 || n % 100 == 83) ? 3 : n != 1 && (n % 100 == 1 || n % 100 == 21 "
+"|| n % 100 == 41 || n % 100 == 61 || n % 100 == 81) ? 4 : 5;\n"
#: qcsrc/client/announcer.qc:45
msgid "vs"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % "
+"1000000 == 0 ? 1 : 2;\n"
#: qcsrc/client/announcer.qc:45
msgid "vs"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"Plural-Forms: nplurals=2; plural=(n > 1);\n"
+"Plural-Forms: nplurals=3; plural=(n == 0 || n == 1) ? 0 : n != 0 && n % "
+"1000000 == 0 ? 1 : 2;\n"
#: qcsrc/client/announcer.qc:45
msgid "vs"
"^F2^COUNT^BG until weapon change...\n"
"Next weapon: ^F1%s"
msgstr ""
-"^F2^CONTAGEM^BG até a mudança de arma...\n"
+"^F2^COUNT^BG até a mudança de arma...\n"
"Próxima arma: ^F1%s"
#: qcsrc/common/notifications/all.inc:719
# Abdurrahman AKKUŞ <a.rahmanakkus@hotmail.com>, 2019
# Ahmet, 2022
# Ahmet, 2022
-# Big Brother <tanakinci2002@gmail.com>, 2021
+# Tan Siret Akıncı <tanakinci2002@gmail.com>, 2021
# Çağlar Turalı <caglarturali@gmail.com>, 2018
# Demiray Muhterem <mdemiray@msn.com>, 2018
-# Big Brother <tanakinci2002@gmail.com>, 2021
+# Tan Siret Akıncı <tanakinci2002@gmail.com>, 2021
# Gokdeniz.Kucukali, 2021
# Gokdeniz.Kucukali, 2021
# ibra kap <ibrakap@gmail.com>, 2019
-# Big Brother <tanakinci2002@gmail.com>, 2021
+# Tan Siret Akıncı <tanakinci2002@gmail.com>, 2021
msgid ""
msgstr ""
"Project-Id-Version: Xonotic\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-04-17 07:22+0200\n"
"PO-Revision-Date: 2013-09-12 16:53+0000\n"
-"Last-Translator: Big Brother <tanakinci2002@gmail.com>, 2021\n"
+"Last-Translator: Tan Siret Akıncı <tanakinci2002@gmail.com>, 2021\n"
"Language-Team: Turkish (http://www.transifex.com/team-xonotic/xonotic/"
"language/tr/)\n"
"Language: tr\n"
}
bool prev_inround;
+float prev_starttime;
+float prev_roundstarttime;
void Announcer_Countdown(entity this)
{
float starttime = STAT(GAMESTARTTIME);
float countdown = (inround ? roundstarttime - time : starttime - time);
float countdown_rounded = floor(0.5 + countdown);
+ if (starttime != prev_starttime || roundstarttime != prev_roundstarttime || prev_inround != inround)
+ this.skin = 0; // restart centerprint countdown
+
if(countdown <= 0) // countdown has finished, starttime is now
{
Local_Notification(MSG_CENTER, CENTER_COUNTDOWN_BEGIN);
if(inround)
{
if(!prev_inround) Announcer_ClearTitle(); // clear title if we just started the match
- Local_Notification(MSG_CENTER, CENTER_COUNTDOWN_ROUNDSTART, STAT(ROUNDS_PLAYED) + 1, countdown_rounded);
+ if (!this.skin) // first tic
+ Local_Notification(MSG_CENTER, CENTER_COUNTDOWN_ROUNDSTART, STAT(ROUNDS_PLAYED) + 1, countdown_rounded);
Notification annce_num = Announcer_PickNumber(CNT_ROUNDSTART, countdown_rounded);
if(annce_num != NULL)
Local_Notification(MSG_ANNCE, annce_num);
}
else
{
- Local_Notification(MSG_CENTER, CENTER_COUNTDOWN_GAMESTART, countdown_rounded);
+ if (!this.skin) // first tic
+ Local_Notification(MSG_CENTER, CENTER_COUNTDOWN_GAMESTART, countdown_rounded);
Notification annce_num = Announcer_PickNumber(CNT_GAMESTART, countdown_rounded);
if(!roundstarttime && annce_num != NULL) // Don't announce game start in round based modes
Local_Notification(MSG_ANNCE, annce_num);
this.nextthink = (starttime - (countdown - 1));
}
+ // Don't call centerprint countdown in the remaining tics, it will continue automatically.
+ // It's an optimization but also fixes ^COUNT shown in the last tic because of high slowmo values (15+).
+ // Hopefully it fixes ^COUNT occasionally shown in online servers, probably due to lags.
+ this.skin = 1; // recycled field
}
prev_inround = inround;
+ prev_starttime = starttime;
+ prev_roundstarttime = roundstarttime;
}
/**
startTime = roundstarttime;
if(intermission)
{
+ Announcer_ClearTitle();
if(announcer_countdown)
{
centerprint_Kill(ORDINAL(CPID_ROUND));
void Announcer()
{
+ // announcer code sets gametype name as centerprint title
+ if(!gametype)
+ return;
Announcer_Gamestart();
Announcer_Time();
}
if(n > maxclients)
return SHOTTYPE_HITWORLD;
t = entcs_GetTeam(n - 1);
- if(teamplay)
- if(t == myteam)
- return SHOTTYPE_HITTEAM;
+ if(teamplay && t == myteam)
+ return SHOTTYPE_HITTEAM;
if(t == NUM_SPECTATOR)
return SHOTTYPE_HITWORLD;
return SHOTTYPE_HITENEMY;
if (centerprint_title_left != "" && align == 0.5) // Center line at the main word (for duels)
pos.x += (stringwidth(centerprint_title_right, true, fontsize) - stringwidth(centerprint_title_left, true, fontsize)) / 2;
- drawcolorcodedstring(pos, centerprint_title, fontsize, 1, DRAWFLAG_NORMAL);
+ drawcolorcodedstring(pos, centerprint_title, fontsize, panel_fg_alpha, DRAWFLAG_NORMAL);
if (autocvar_hud_panel_centerprint_flip)
pos.y -= cp_fontsize.y * CENTERPRINT_TITLE_SPACING;
else
pos.y += fontsize.y + (hud_fontsize.y * CENTERPRINT_TITLE_SPACING);
- drawfill(pos, vec2(width, 1), '1 1 1', 1, DRAWFLAG_NORMAL);
+ drawfill(pos, vec2(width, 1), '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL);
if (autocvar_hud_panel_centerprint_flip)
pos.y -= cp_fontsize.y * CENTERPRINT_TITLE_SPACING;
// print information about respawn status
float respawn_time = STAT(RESPAWN_TIME);
- if(!intermission)
- if(respawn_time)
+ if(!intermission && respawn_time)
{
if(respawn_time < 0)
{
string msg = MakeConsoleSafe(strreplace("\n", "\\n", welcome_msg));
welcomedialog_args = strcat(welcomedialog_args, " WELCOME \"", msg, "\"");
localcmd("\nmenu_cmd directmenu Welcome ", welcomedialog_args, "\n");
+ if (intermission) // close it after it's been initialized so it can still be opened manually
+ localcmd("\ntogglemenu 0\n");
}
else
centerprint_Add(ORDINAL(CPID_MOTD), strcat(hostname, "\n\n\n", welcome_msg), -1, 0);
Hud_Dynamic_Frame();
if(!intermission)
- if (MUTATOR_CALLHOOK(HUD_Draw_overlay))
{
- drawfill('0 0 0', vec2(vid_conwidth, vid_conheight), M_ARGV(0, vector), autocvar_hud_colorflash_alpha * M_ARGV(1, float), DRAWFLAG_ADDITIVE);
- }
- else if(STAT(FROZEN))
- {
- vector col = '0.25 0.90 1';
- float col_fade = max(0, STAT(REVIVE_PROGRESS) * 2 - 1);
- float alpha_fade = 0.3 + 0.7 * (1 - max(0, STAT(REVIVE_PROGRESS) * 4 - 3));
- if(col_fade)
- col += vec3(col_fade, -col_fade, -col_fade);
- drawfill('0 0 0', vec2(vid_conwidth, vid_conheight), col, autocvar_hud_colorflash_alpha * alpha_fade, DRAWFLAG_ADDITIVE);
+ if (MUTATOR_CALLHOOK(HUD_Draw_overlay))
+ {
+ drawfill('0 0 0', vec2(vid_conwidth, vid_conheight), M_ARGV(0, vector), autocvar_hud_colorflash_alpha * M_ARGV(1, float), DRAWFLAG_ADDITIVE);
+ }
+ else if(STAT(FROZEN))
+ {
+ vector col = '0.25 0.90 1';
+ float col_fade = max(0, STAT(REVIVE_PROGRESS) * 2 - 1);
+ float alpha_fade = 0.3 + 0.7 * (1 - max(0, STAT(REVIVE_PROGRESS) * 4 - 3));
+ if(col_fade)
+ col += vec3(col_fade, -col_fade, -col_fade);
+ drawfill('0 0 0', vec2(vid_conwidth, vid_conheight), col, autocvar_hud_colorflash_alpha * alpha_fade, DRAWFLAG_ADDITIVE);
+ }
}
HUD_Scale_Enable();
if(!intermission)
- if(STAT(NADE_TIMER) && autocvar_cl_nade_timer) // give nade top priority, as it's a matter of life and death
- {
- vector col = '0.25 0.90 1' + vec3(STAT(NADE_TIMER), -STAT(NADE_TIMER), -STAT(NADE_TIMER));
- DrawCircleClippedPic(vec2(0.5 * vid_conwidth, 0.6 * vid_conheight), 0.1 * vid_conheight, "gfx/crosshair_ring", STAT(NADE_TIMER), col, autocvar_hud_colorflash_alpha, DRAWFLAG_ADDITIVE);
- drawstring_aspect(eY * 0.64 * vid_conheight, ((autocvar_cl_nade_timer == 2) ? _("Nade timer") : ""), vec2(vid_conwidth, 0.025 * vid_conheight), '1 1 1', 1, DRAWFLAG_NORMAL);
- }
- else if(STAT(CAPTURE_PROGRESS))
- {
- DrawCircleClippedPic(vec2(0.5 * vid_conwidth, 0.6 * vid_conheight), 0.1 * vid_conheight, "gfx/crosshair_ring", STAT(CAPTURE_PROGRESS), '0.25 0.90 1', autocvar_hud_colorflash_alpha, DRAWFLAG_ADDITIVE);
- drawstring_aspect(eY * 0.64 * vid_conheight, _("Capture progress"), vec2(vid_conwidth, 0.025 * vid_conheight), '1 1 1', 1, DRAWFLAG_NORMAL);
- }
- else if(STAT(REVIVE_PROGRESS))
{
- DrawCircleClippedPic(vec2(0.5 * vid_conwidth, 0.6 * vid_conheight), 0.1 * vid_conheight, "gfx/crosshair_ring", STAT(REVIVE_PROGRESS), '0.25 0.90 1', autocvar_hud_colorflash_alpha, DRAWFLAG_ADDITIVE);
- drawstring_aspect(eY * 0.64 * vid_conheight, _("Revival progress"), vec2(vid_conwidth, 0.025 * vid_conheight), '1 1 1', 1, DRAWFLAG_NORMAL);
+ if(STAT(NADE_TIMER) && autocvar_cl_nade_timer) // give nade top priority, as it's a matter of life and death
+ {
+ vector col = '0.25 0.90 1' + vec3(STAT(NADE_TIMER), -STAT(NADE_TIMER), -STAT(NADE_TIMER));
+ DrawCircleClippedPic(vec2(0.5 * vid_conwidth, 0.6 * vid_conheight), 0.1 * vid_conheight, "gfx/crosshair_ring", STAT(NADE_TIMER), col, autocvar_hud_colorflash_alpha, DRAWFLAG_ADDITIVE);
+ drawstring_aspect(eY * 0.64 * vid_conheight, ((autocvar_cl_nade_timer == 2) ? _("Nade timer") : ""), vec2(vid_conwidth, 0.025 * vid_conheight), '1 1 1', 1, DRAWFLAG_NORMAL);
+ }
+ else if(STAT(CAPTURE_PROGRESS))
+ {
+ DrawCircleClippedPic(vec2(0.5 * vid_conwidth, 0.6 * vid_conheight), 0.1 * vid_conheight, "gfx/crosshair_ring", STAT(CAPTURE_PROGRESS), '0.25 0.90 1', autocvar_hud_colorflash_alpha, DRAWFLAG_ADDITIVE);
+ drawstring_aspect(eY * 0.64 * vid_conheight, _("Capture progress"), vec2(vid_conwidth, 0.025 * vid_conheight), '1 1 1', 1, DRAWFLAG_NORMAL);
+ }
+ else if(STAT(REVIVE_PROGRESS))
+ {
+ DrawCircleClippedPic(vec2(0.5 * vid_conwidth, 0.6 * vid_conheight), 0.1 * vid_conheight, "gfx/crosshair_ring", STAT(REVIVE_PROGRESS), '0.25 0.90 1', autocvar_hud_colorflash_alpha, DRAWFLAG_ADDITIVE);
+ drawstring_aspect(eY * 0.64 * vid_conheight, _("Revival progress"), vec2(vid_conwidth, 0.025 * vid_conheight), '1 1 1', 1, DRAWFLAG_NORMAL);
+ }
}
HUD_Scale_Disable();
if(autocvar_r_letterbox == 0)
+ {
if(autocvar_viewsize < 120)
{
if(!MUTATOR_CALLHOOK(DrawScoreboardAccuracy))
HUD_Main();
HUD_Scale_Disable();
}
+ }
// crosshair goes VERY LAST
UpdateDamage();
TeamScore_AddToTeam(assault_attacker_team, ST_ASSAULT_OBJECTIVES, 666 - TeamScore_AddToTeam(assault_attacker_team, ST_ASSAULT_OBJECTIVES, 0));
- if(ent.cnt == 1 || autocvar_g_campaign) // this was the second round
+ if(ent.cnt == 1 || autocvar_g_campaign) // this was the second round or the only round in campaign
{
status = WINNING_YES;
}
MUTATOR_HOOKFUNCTION(as, ReadyRestart_Deny)
{
// readyrestart not supported (yet)
+ // it's supported only in campaign mode (single round mode), since campaign requires it
+ if (autocvar_g_campaign)
+ return false;
return true;
}
{
FOREACH_CLIENT(true, {
CS(it).killcount = 0;
- if (!INGAME(it) && IS_BOT_CLIENT(it))
- {
- it.team = -1;
- INGAME_STATUS_SET(it, INGAME_STATUS_JOINED);
- }
- if (INGAME(it))
+ if (INGAME(it) || IS_BOT_CLIENT(it))
{
TRANSMUTE(Player, it);
INGAME_STATUS_SET(it, INGAME_STATUS_JOINED);
{
float latency = max(0, CS(p).latency_sum / CS(p).latency_cnt);
if(latency)
- PlayerStats_GameReport_Event_Player(p, PLAYERSTATS_AVGLATENCY, latency);
+ {
+ // if previous average latency exists (player disconnected and reconnected)
+ // make the average of previous and current average latency
+ float prev_latency = PlayerStats_GameReport_Event_Player(p, PLAYERSTATS_AVGLATENCY, 0);
+ float new_latency = !prev_latency ? latency : (prev_latency + latency) / 2;
+ PlayerStats_GameReport_Event_Player(p, PLAYERSTATS_AVGLATENCY, -prev_latency + new_latency);
+ }
}
db_put(PS_GR_OUT_DB, sprintf("%s:_ranked", p.playerstats_id), ftos(CS_CVAR(p).cvar_cl_allow_uidranking));
head = findradius(this.origin, WEP_CVAR(minelayer, proximityradius));
while(head)
{
- if(IS_PLAYER(head) && !IS_DEAD(head) && !STAT(FROZEN, head))
+ if(IS_PLAYER(head) && !IS_DEAD(head) && !STAT(FROZEN, head) && !IS_INDEPENDENT_PLAYER(head))
if(head != this.realowner && DIFF_TEAM(head, this.realowner)) // don't trigger for team mates
if(!this.mine_time)
{
METHOD(XonoticServerCreateTab, fill, void(entity));
METHOD(XonoticServerCreateTab, gameTypeChangeNotify, void(entity));
METHOD(XonoticServerCreateTab, gameTypeSelectNotify, void(entity));
+ ATTRIB(XonoticServerCreateTab, intendedWidth, float, 0.9);
ATTRIB(XonoticServerCreateTab, rows, float, 23);
ATTRIB(XonoticServerCreateTab, columns, float, 6.2); // added extra .2 for center space
#include "tab.qh"
CLASS(XonoticServerListTab, XonoticTab)
METHOD(XonoticServerListTab, fill, void(entity));
+ ATTRIB(XonoticServerListTab, intendedWidth, float, 0.9);
ATTRIB(XonoticServerListTab, rows, float, 23);
ATTRIB(XonoticServerListTab, columns, float, 6.5);
METHOD(XonoticServerInfoTab, fill, void(entity));
ATTRIB(XonoticServerInfoTab, title, string, _("Server Information"));
ATTRIB(XonoticServerInfoTab, color, vector, SKINCOLOR_DIALOG_SERVERINFO);
+ ATTRIB(XonoticServerInfoTab, intendedWidth, float, 0.8);
ATTRIB(XonoticServerInfoTab, rows, float, 17);
ATTRIB(XonoticServerInfoTab, columns, float, 6.2);
METHOD(XonoticServerToSTab, loadToS, void(entity, string));
ATTRIB(XonoticServerToSTab, title, string, _("Terms of Service"));
ATTRIB(XonoticServerToSTab, color, vector, SKINCOLOR_DIALOG_SERVERINFO);
+ ATTRIB(XonoticServerToSTab, intendedWidth, float, 0.8);
ATTRIB(XonoticServerToSTab, rows, float, 17);
ATTRIB(XonoticServerToSTab, columns, float, 6.2);
#include "tab.qh"
CLASS(XonoticMediaTab, XonoticTab)
METHOD(XonoticMediaTab, fill, void(entity));
+ ATTRIB(XonoticMediaTab, intendedWidth, float, 0.9);
ATTRIB(XonoticMediaTab, rows, float, 23);
ATTRIB(XonoticMediaTab, columns, float, 3);
ATTRIB(XonoticMediaTab, name, string, "Media");
#include "tab.qh"
CLASS(XonoticDemoBrowserTab, XonoticTab)
METHOD(XonoticDemoBrowserTab, fill, void(entity));
+ ATTRIB(XonoticDemoBrowserTab, intendedWidth, float, 0.9);
ATTRIB(XonoticDemoBrowserTab, rows, float, 21);
ATTRIB(XonoticDemoBrowserTab, columns, float, 6.5);
ATTRIB(XonoticDemoBrowserTab, name, string, "DemoBrowser");
#include "tab.qh"
CLASS(XonoticMusicPlayerTab, XonoticTab)
METHOD(XonoticMusicPlayerTab, fill, void(entity));
+ ATTRIB(XonoticMusicPlayerTab, intendedWidth, float, 0.9);
ATTRIB(XonoticMusicPlayerTab, rows, float, 21);
ATTRIB(XonoticMusicPlayerTab, columns, float, 6.5);
ATTRIB(XonoticMusicPlayerTab, name, string, "MusicPlayer");
#include "tab.qh"
CLASS(XonoticScreenshotBrowserTab, XonoticTab)
METHOD(XonoticScreenshotBrowserTab, fill, void(entity));
+ ATTRIB(XonoticScreenshotBrowserTab, intendedWidth, float, 1);
ATTRIB(XonoticScreenshotBrowserTab, rows, float, 21);
ATTRIB(XonoticScreenshotBrowserTab, columns, float, 6.5);
ATTRIB(XonoticScreenshotBrowserTab, name, string, "ScreenshotBrowser");
CLASS(XonoticProfileTab, XonoticTab)
METHOD(XonoticProfileTab, fill, void(entity));
METHOD(XonoticProfileTab, draw, void(entity));
+ ATTRIB(XonoticProfileTab, intendedWidth, float, 0.9);
ATTRIB(XonoticProfileTab, rows, float, 23);
ATTRIB(XonoticProfileTab, columns, float, 6.1); // added extra .2 for center space
ATTRIB(XonoticProfileTab, playerNameLabel, entity);
#include "tab.qh"
CLASS(XonoticAudioSettingsTab, XonoticTab)
METHOD(XonoticAudioSettingsTab, fill, void(entity));
+ ATTRIB(XonoticAudioSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticAudioSettingsTab, rows, float, 15.5);
ATTRIB(XonoticAudioSettingsTab, columns, float, 6.2); // added extra .2 for center space
ATTRIB(XonoticAudioSettingsTab, hiddenMenuSoundsSlider, entity);
#include "tab.qh"
CLASS(XonoticEffectsSettingsTab, XonoticTab)
METHOD(XonoticEffectsSettingsTab, fill, void(entity));
+ ATTRIB(XonoticEffectsSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticEffectsSettingsTab, rows, float, 15.5);
ATTRIB(XonoticEffectsSettingsTab, columns, float, 6.2); // added extra .2 for center space
ENDCLASS(XonoticEffectsSettingsTab)
#include "tab.qh"
#include "scrollpanel.qh"
CLASS(XonoticGameSettingsTab, XonoticTab)
+ ATTRIB(XonoticGameSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticGameSettingsTab, rows, float, 15.5);
ATTRIB(XonoticGameSettingsTab, columns, float, 6.5);
ATTRIB(XonoticGameSettingsTab, source, DataSource, NEW(SettingSource));
METHOD(XonoticGameCrosshairSettingsTab, fill, void(entity));
METHOD(XonoticGameCrosshairSettingsTab, showNotify, void(entity));
ATTRIB(XonoticGameCrosshairSettingsTab, title, string, _("Crosshair"));
+ ATTRIB(XonoticGameCrosshairSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticGameCrosshairSettingsTab, rows, float, 15.5);
ATTRIB(XonoticGameCrosshairSettingsTab, columns, float, 6.2);
ENDCLASS(XonoticGameCrosshairSettingsTab)
METHOD(XonoticGameHUDSettingsTab, fill, void(entity));
METHOD(XonoticGameHUDSettingsTab, showNotify, void(entity));
ATTRIB(XonoticGameHUDSettingsTab, title, string, _("HUD"));
+ ATTRIB(XonoticGameHUDSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticGameHUDSettingsTab, rows, float, 15.5);
ATTRIB(XonoticGameHUDSettingsTab, columns, float, 6.2);
ENDCLASS(XonoticGameHUDSettingsTab)
METHOD(XonoticGameMessageSettingsTab, fill, void(entity));
METHOD(XonoticGameMessageSettingsTab, showNotify, void(entity));
ATTRIB(XonoticGameMessageSettingsTab, title, string, _("Messages"));
+ ATTRIB(XonoticGameMessageSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticGameMessageSettingsTab, rows, float, 15.5);
ATTRIB(XonoticGameMessageSettingsTab, columns, float, 6);
ATTRIB(XonoticGameMessageSettingsTab, weaponsList, entity);
METHOD(XonoticGameModelSettingsTab, showNotify, void(entity));
ATTRIB(XonoticGameModelSettingsTab, title, string, _("Models"));
ATTRIB(XonoticGameModelSettingsTab, titleTooltip, string, _("Customize how players and items are displayed in game"));
+ ATTRIB(XonoticGameModelSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticGameModelSettingsTab, rows, float, 15.5);
ATTRIB(XonoticGameModelSettingsTab, columns, float, 5);
ENDCLASS(XonoticGameModelSettingsTab)
METHOD(XonoticGameViewSettingsTab, fill, void(entity));
METHOD(XonoticGameViewSettingsTab, showNotify, void(entity));
ATTRIB(XonoticGameViewSettingsTab, title, string, _("View"));
+ ATTRIB(XonoticGameViewSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticGameViewSettingsTab, rows, float, 15.5);
ATTRIB(XonoticGameViewSettingsTab, columns, float, 6.2);
ENDCLASS(XonoticGameViewSettingsTab)
METHOD(XonoticGameWeaponsSettingsTab, fill, void(entity));
METHOD(XonoticGameWeaponsSettingsTab, showNotify, void(entity));
ATTRIB(XonoticGameWeaponsSettingsTab, title, string, _("Weapons"));
+ ATTRIB(XonoticGameWeaponsSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticGameWeaponsSettingsTab, rows, float, 15.5);
ATTRIB(XonoticGameWeaponsSettingsTab, columns, float, 6);
ATTRIB(XonoticGameWeaponsSettingsTab, weaponsList, entity);
#include "tab.qh"
CLASS(XonoticInputSettingsTab, XonoticTab)
METHOD(XonoticInputSettingsTab, fill, void(entity));
+ ATTRIB(XonoticInputSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticInputSettingsTab, rows, float, 15.5);
ATTRIB(XonoticInputSettingsTab, columns, float, 6.2); // added extra .2 for center space
ATTRIB(XonoticInputSettingsTab, name, string, "inputsettings");
#include "tab.qh"
CLASS(XonoticMiscSettingsTab, XonoticTab)
METHOD(XonoticMiscSettingsTab, fill, void(entity));
+ ATTRIB(XonoticMiscSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticMiscSettingsTab, rows, float, 15.5);
ATTRIB(XonoticMiscSettingsTab, columns, float, 6.2);
ENDCLASS(XonoticMiscSettingsTab)
#include "tab.qh"
CLASS(XonoticUserSettingsTab, XonoticTab)
METHOD(XonoticUserSettingsTab, fill, void(entity));
+ ATTRIB(XonoticUserSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticUserSettingsTab, rows, float, 15.5);
ATTRIB(XonoticUserSettingsTab, columns, float, 6);
ENDCLASS(XonoticUserSettingsTab)
#include "tab.qh"
CLASS(XonoticVideoSettingsTab, XonoticTab)
METHOD(XonoticVideoSettingsTab, fill, void(entity));
+ ATTRIB(XonoticVideoSettingsTab, intendedWidth, float, 0.9);
ATTRIB(XonoticVideoSettingsTab, rows, float, 15.5);
ATTRIB(XonoticVideoSettingsTab, columns, float, 6.2); // added extra .2 for center space
ATTRIB(XonoticVideoSettingsTab, name, string, "videosettings");
void XonoticWelcomeDialog_draw(entity me)
{
SUPER(XonoticWelcomeDialog).draw(me);
+
+ if (!(gamestatus & (GAME_ISSERVER | GAME_CONNECTED)))
+ me.close(me);
+
if(me.serverinfo_MOTD == "" && gamestatus & (GAME_CONNECTED | GAME_ISSERVER))
{
// if serverinfo_MOTD is empty while connected it means we are connected to an old server
else bot_pants = ftos(floor(random() * 15));
if (teamplay && !(autocvar_bot_vs_human && AvailableTeams() == 2))
+ {
this.bot_forced_team = stof(argv(5));
+ if (!Team_IsValidIndex(this.bot_forced_team))
+ this.bot_forced_team = 0;
+ }
else
this.bot_forced_team = 0;
bot_setclientfields(this);
}
- if (teamplay && Team_IsValidIndex(this.bot_forced_team))
- {
- SetPlayerTeam(this, this.bot_forced_team, TEAM_CHANGE_MANUAL);
- }
- else
- {
- this.bot_forced_team = 0;
- TeamBalance_JoinBestTeam(this);
- }
-
havocbot_setupbot(this);
}
// spectators in the scoreboard and never go away. This issue happens at time 2 if map is changed
// with the gotomap command, minplayers is > 1 and human clients join as players very soon
// either intentionally or automatically (sv_spectate 0)
+ // A working workaround for this bug was implemented in commit fbd145044, see entcs_attach
if (time < 2.5)
{
currentbots = -1;
PlayerState_attach(this);
accuracy_resend(this);
+ if (teamplay && this.bot_forced_team)
+ SetPlayerTeam(this, this.bot_forced_team, TEAM_CHANGE_MANUAL);
+
if (this.team < 0)
TeamBalance_JoinBestTeam(this);
/** Called when a client spawns in the server */
void PutClientInServer(entity this)
{
- if (IS_BOT_CLIENT(this)) {
- TRANSMUTE(Player, this);
- } else if (IS_REAL_CLIENT(this)) {
+ if (IS_REAL_CLIENT(this)) {
msg_entity = this;
WriteByte(MSG_ONE, SVC_SETVIEW);
WriteEntity(MSG_ONE, this);
}
}
+ if (IS_BOT_CLIENT(this) && !CS(this).autojoin_checked)
+ {
+ CS(this).autojoin_checked = true;
+ TRANSMUTE(Player, this);
+ PutClientInServer(this);
+ return;
+ }
+
if (this.flags & FL_JUMPRELEASED) {
if (PHYS_INPUT_BUTTON_JUMP(this) && (joinAllowed(this) || time < CS(this).jointime + MIN_SPEC_TIME)) {
this.flags &= ~FL_JUMPRELEASED;
void ReadyRestart(bool forceWarmupEnd)
{
- if (MUTATOR_CALLHOOK(ReadyRestart_Deny) || intermission_running || race_completing) localcmd("restart\n");
+ if (MUTATOR_CALLHOOK(ReadyRestart_Deny) || intermission_running || race_completing)
+ {
+ // NOTE: ReadyRestart support is mandatory in campaign
+ if (autocvar_g_campaign)
+ error("ReadyRestart must be supported in campaign mode!");
+ localcmd("restart\n"); // if ReadyRestart is denied, restart the server
+ }
else localcmd("\nsv_hook_readyrestart\n");
if(forceWarmupEnd || autocvar_g_campaign)
/**/
MUTATOR_HOOKABLE(ChatMessageTo, EV_ChatMessageTo);
-/** return true to just restart the match, for modes that don't support readyrestart */
+/**
+ * return true to restart the server instead of restarting the match, for modes that don't support readyrestart.
+ * NOTE: ReadyRestart support is mandatory in campaign
+ */
MUTATOR_HOOKABLE(ReadyRestart_Deny, EV_NO_ARGS);
/** called when a fusion reactor is validating its target */