mirror of
https://github.com/rehlds/rehlds.git
synced 2024-12-27 23:25:45 +03:00
Merge pull request #304 from In-line/SetCStrikeFlags_on_server_init
SetCStrikeFlags() once on server start
This commit is contained in:
commit
fd8bc60daf
@ -458,8 +458,9 @@ void Cmd_Alias_f(void)
|
||||
return;
|
||||
}
|
||||
|
||||
SetCStrikeFlags(); // TODO: Do this once somewhere at the server start
|
||||
|
||||
#ifndef REHLDS_FIXES
|
||||
SetCStrikeFlags(); // DONE: Do this once somewhere at the server start
|
||||
#endif
|
||||
if ((g_bIsCStrike || g_bIsCZero) &&
|
||||
(!Q_stricmp(s, "cl_autobuy")
|
||||
|| !Q_stricmp(s, "cl_rebuy")
|
||||
|
@ -219,6 +219,10 @@ void Host_InitializeGameDLL(void)
|
||||
SV_CheckBlendingInterface();
|
||||
SV_CheckSaveGameCommentInterface();
|
||||
Cbuf_Execute();
|
||||
|
||||
#ifdef REHLDS_FIXES // DONE: Set cstrike flags on server start
|
||||
SetCStrikeFlags();
|
||||
#endif
|
||||
}
|
||||
|
||||
void Host_Motd_f(void)
|
||||
|
@ -310,8 +310,9 @@ model_t *Mod_LoadModel(model_t *mod, qboolean crash, qboolean trackCRC)
|
||||
{
|
||||
p->firstCRCDone = 1;
|
||||
p->initialCRC = currentCRC;
|
||||
#ifndef REHLDS_FIXES
|
||||
SetCStrikeFlags();
|
||||
|
||||
#endif
|
||||
if (!IsGameSubscribed("czero") && g_bIsCStrike && IsCZPlayerModel(currentCRC, mod->name) && g_pcls.state)
|
||||
{
|
||||
COM_ExplainDisconnection(TRUE, "Cannot continue with altered model %s, disconnecting.", mod->name);
|
||||
|
@ -5746,7 +5746,9 @@ void EXT_FUNC SV_ActivateServer_internal(int runPhysics)
|
||||
msg.cursize = 0;
|
||||
msg.flags = SIZEBUF_CHECK_OVERFLOW;
|
||||
|
||||
#ifndef REHLDS_FIXES
|
||||
SetCStrikeFlags();
|
||||
#endif
|
||||
Cvar_Set("sv_newunit", "0");
|
||||
|
||||
ContinueLoadingProgressBar("Server", 8, 0.0f);
|
||||
@ -8044,4 +8046,4 @@ NOXREF qboolean BIsValveGame(void)
|
||||
return TRUE;
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user