Connectawaittime #5
No files matched your search
+12
-8
@@ -2509,18 +2509,19 @@ static boolean CL_ServerConnectionTicker(const char *tmpsave, tic_t *oldtic, tic
|
||||
}
|
||||
break;
|
||||
case CL_ASKJOIN:
|
||||
if (firstconnectattempttime + NEWTICRATE*300 < I_GetTime() && !server)
|
||||
if (cv_connectawaittime.value && firstconnectattempttime + NEWTICRATE*60*cv_connectawaittime.value < I_GetTime() && !server)
|
||||
{
|
||||
CONS_Printf(M_GetText("5 minute wait time exceeded.\n"));
|
||||
CONS_Printf("%d minute wait time exceeded.\n", cv_connectawaittime.value);
|
||||
CONS_Printf(M_GetText("Network game synchronization aborted.\n"));
|
||||
D_QuitNetGame();
|
||||
CL_Reset();
|
||||
D_StartTitle();
|
||||
M_StartMessage(M_GetText(
|
||||
"5 minute wait time exceeded.\n"
|
||||
M_StartMessage(va(
|
||||
"%d minute wait time exceeded.\n"
|
||||
"You may retry connection.\n"
|
||||
"\n"
|
||||
"Press ESC\n"
|
||||
"Press ESC\n",
|
||||
cv_connectawaittime.value
|
||||
), NULL, MM_NOTHING);
|
||||
return false;
|
||||
}
|
||||
@@ -3883,6 +3884,9 @@ consvar_t cv_noticedownload = {"noticedownload", "Off", CV_SAVE, CV_OnOff, NULL,
|
||||
static CV_PossibleValue_t downloadspeed_cons_t[] = {{1, "MIN"}, {300, "MAX"}, {0, NULL}};
|
||||
consvar_t cv_downloadspeed = {"downloadspeed", "MAX", CV_SAVE, downloadspeed_cons_t, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
static CV_PossibleValue_t connectawaittime_cons_t[] = {{1, "MIN"}, {60, "MAX"}, {0, "Inf"}, {0, NULL}};
|
||||
consvar_t cv_connectawaittime = {"connectawaittime", "5", CV_SAVE, connectawaittime_cons_t, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
static void Got_AddPlayer(UINT8 **p, INT32 playernum);
|
||||
static void Got_RemovePlayer(UINT8 **p, INT32 playernum);
|
||||
|
||||
@@ -5979,9 +5983,9 @@ boolean TryRunTics(tic_t realtics)
|
||||
while (neededtic > gametic)
|
||||
{
|
||||
boolean update_stats = !(paused || P_AutoPause());
|
||||
|
||||
|
||||
DEBFILE(va("============ Running tic %d (local %d)\n", gametic, localgametic));
|
||||
|
||||
|
||||
if (update_stats)
|
||||
PS_START_TIMING(ps_tictime);
|
||||
|
||||
@@ -5989,7 +5993,7 @@ boolean TryRunTics(tic_t realtics)
|
||||
ExtraDataTicker();
|
||||
gametic++;
|
||||
consistancy[gametic%TICQUEUE] = Consistancy();
|
||||
|
||||
|
||||
if (update_stats)
|
||||
{
|
||||
PS_STOP_TIMING(ps_tictime);
|
||||
|
||||
@@ -567,6 +567,8 @@ extern consvar_t
|
||||
#endif
|
||||
cv_netticbuffer, cv_allownewplayer, cv_maxplayers, cv_resynchattempts, cv_blamecfail, cv_maxsend, cv_noticedownload, cv_downloadspeed;
|
||||
|
||||
extern consvar_t cv_connectawaittime;
|
||||
|
||||
extern consvar_t cv_discordinvites;
|
||||
|
||||
// Used in d_net, the only dependence
|
||||
|
||||
@@ -739,6 +739,7 @@ void D_RegisterServerCommands(void)
|
||||
CV_RegisterVar(&cv_maxsend);
|
||||
CV_RegisterVar(&cv_noticedownload);
|
||||
CV_RegisterVar(&cv_downloadspeed);
|
||||
CV_RegisterVar(&cv_connectawaittime);
|
||||
CV_RegisterVar(&cv_httpsource);
|
||||
#ifndef NONET
|
||||
CV_RegisterVar(&cv_allownewplayer);
|
||||
|
||||
+2
-1
@@ -1740,7 +1740,6 @@ static menuitem_t OP_BirdMenu[] =
|
||||
{IT_STRING | IT_SUBMENU, NULL, "Advanced Music Options...", &OP_AdvancedBirdDef, 120},
|
||||
};
|
||||
|
||||
|
||||
static menuitem_t OP_TiltMenu[] =
|
||||
{
|
||||
{IT_STRING | IT_CVAR, NULL, "Camera Tilting", &cv_tilting, 0},
|
||||
@@ -2296,6 +2295,8 @@ menu_t OP_PlayerDistortDef = DEFAULTMENUSTYLE("M_VIDEO", OP_PlayerDistortMenu, &
|
||||
menu_t OP_HudOffsetDef = DEFAULTMENUSTYLE(NULL, OP_HudOffsetMenu, &OP_SaturnDef, 30, 30);
|
||||
//menu_t OP_SaturnCreditsDef = DEFAULTMENUSTYLE(NULL, OP_SaturnCreditsMenu, &OP_SaturnDef, 30, 30);
|
||||
|
||||
menu_t OP_ConnectDef = DEFAULTMENUSTYLE(NULL, OP_ConnectMenu, &OP_MainDef, 30, 30);
|
||||
|
||||
menu_t OP_BirdDef = DEFAULTMENUSTYLE(NULL, OP_BirdMenu, &OP_MainDef, 30, 30);
|
||||
menu_t OP_TiltDef = DEFAULTMENUSTYLE(NULL, OP_TiltMenu, &OP_BirdDef, 30, 60);
|
||||
menu_t OP_AdvancedBirdDef = DEFAULTMENUSTYLE(NULL, OP_AdvancedBirdMenu, &OP_BirdDef, 30, 60);
|
||||
|
||||
Reference in new issue
Block a user