mirror of
https://github.com/nzp-team/fteqw.git
synced 2024-11-29 23:22:01 +00:00
fix to master cvars, don't crash when worldmodel doesn't get loaded for the client, misc fixes
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2296 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
116faaf0c9
commit
31eaf52ce9
4 changed files with 7 additions and 12 deletions
|
@ -605,11 +605,6 @@ void Model_NextDownload (void)
|
|||
|
||||
CL_AllowIndependantSendCmd(false); //stop it now, the indep stuff *could* require model tracing.
|
||||
|
||||
|
||||
// if (cl.worldmodel->type != mod_brush && cl.worldmodel->type != mod_heightmap)
|
||||
// Host_EndGame("Worldmodel must be a bsp of some sort\n");
|
||||
|
||||
|
||||
Hunk_Check (); // make sure nothing is hurt
|
||||
|
||||
cl.sendprespawn = true;
|
||||
|
@ -696,7 +691,7 @@ int CL_LoadModels(int stage)
|
|||
if (atstage())
|
||||
{
|
||||
cl.worldmodel = cl.model_precache[1];
|
||||
if (!cl.worldmodel)
|
||||
if (!cl.worldmodel || cl.worldmodel->type == mod_dummy)
|
||||
Host_EndGame("Worldmodel wasn't sent\n");
|
||||
|
||||
R_CheckSky();
|
||||
|
@ -713,7 +708,7 @@ int CL_LoadModels(int stage)
|
|||
if (atstage())
|
||||
{
|
||||
loadmodel = cl.worldmodel;
|
||||
if (!loadmodel)
|
||||
if (!loadmodel || loadmodel->type == mod_dummy)
|
||||
Host_EndGame("No worldmodel was loaded\n");
|
||||
|
||||
if (R_PreNewMap)
|
||||
|
@ -724,7 +719,7 @@ int CL_LoadModels(int stage)
|
|||
if (atstage())
|
||||
{
|
||||
loadmodel = cl.worldmodel;
|
||||
if (!loadmodel)
|
||||
if (!loadmodel || loadmodel->type == mod_dummy)
|
||||
Host_EndGame("No worldmodel was loaded\n");
|
||||
Mod_NowLoadExternal();
|
||||
|
||||
|
@ -736,7 +731,7 @@ int CL_LoadModels(int stage)
|
|||
if (atstage())
|
||||
{
|
||||
loadmodel = cl.worldmodel;
|
||||
if (!loadmodel)
|
||||
if (!loadmodel || loadmodel->type == mod_dummy)
|
||||
Host_EndGame("No worldmodel was loaded\n");
|
||||
R_NewMap ();
|
||||
|
||||
|
|
|
@ -454,7 +454,7 @@ void SV_Map_f (void)
|
|||
return;
|
||||
}
|
||||
|
||||
strcpy (level, Cmd_Argv(1));
|
||||
Q_strncpyz (level, Cmd_Argv(1), sizeof(level));
|
||||
startspot = ((Cmd_Argc() == 2)?NULL:Cmd_Argv(2));
|
||||
|
||||
waschangelevel = !strcmp(Cmd_Argv(0), "changelevel");
|
||||
|
|
|
@ -3258,7 +3258,7 @@ void SV_Masterlist_Callback(struct cvar_s *var, char *oldvalue)
|
|||
if (!sv_masterlist[i].cv.name)
|
||||
return;
|
||||
|
||||
if (*var->string)
|
||||
if (!*var->string)
|
||||
{
|
||||
sv_masterlist[i].adr.port = 0;
|
||||
return;
|
||||
|
|
|
@ -67,7 +67,7 @@ qbyte Trans(qbyte p, qbyte p2)
|
|||
|
||||
qbyte AddBlend(qbyte p, qbyte p2)
|
||||
{
|
||||
int x, y;
|
||||
unsigned int x, y;
|
||||
|
||||
x = (srctable[p] + dsttable[p2]);
|
||||
y = x & 0x40100400; // overflow bits
|
||||
|
|
Loading…
Reference in a new issue