Implement CG_R_LOADWORLD properly.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@6210 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
6ceb76233c
commit
11d385ed77
3 changed files with 9 additions and 7 deletions
|
@ -870,12 +870,14 @@ static qintptr_t CG_SystemCalls(void *offset, quintptr_t mask, qintptr_t fn, con
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CG_R_LOADWORLDMAP: //FTE can't distinguish. :/
|
case CG_R_LOADWORLDMAP:
|
||||||
Con_DPrintf("CG_R_LOADWORLDMAP: not implemented\n");
|
{ //rendering
|
||||||
break; //So long as noone has one collision model with a different rendering one, we'll be fine
|
scenefuncs->NewMap(worldfuncs->LoadModel(VM_POINTER(arg[0]), MLV_SILENTSYNC));
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
case CG_CM_LOADMAP:
|
case CG_CM_LOADMAP:
|
||||||
{
|
{ //collisions
|
||||||
int i;
|
int i;
|
||||||
char *mapname = VM_POINTER(arg[0]);
|
char *mapname = VM_POINTER(arg[0]);
|
||||||
ccs.worldmodel = ccs.model_precache[0] = worldfuncs->LoadModel(mapname, MLV_SILENTSYNC);
|
ccs.worldmodel = ccs.model_precache[0] = worldfuncs->LoadModel(mapname, MLV_SILENTSYNC);
|
||||||
|
|
|
@ -624,14 +624,14 @@ void CLQ3_ParseGameState(sizebuf_t *msg)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
scenefuncs->NewMap(NULL);
|
||||||
|
|
||||||
CG_Restart();
|
CG_Restart();
|
||||||
UI_Restart_f();
|
UI_Restart_f();
|
||||||
|
|
||||||
if (!ccs.worldmodel)
|
if (!ccs.worldmodel)
|
||||||
plugfuncs->EndGame("CGame didn't set a map.\n");
|
plugfuncs->EndGame("CGame didn't set a map.\n");
|
||||||
|
|
||||||
scenefuncs->NewMap (ccs.worldmodel);
|
|
||||||
|
|
||||||
SCR_EndLoadingPlaque();
|
SCR_EndLoadingPlaque();
|
||||||
|
|
||||||
ccs.state = ca_active;
|
ccs.state = ca_active;
|
||||||
|
|
|
@ -3985,7 +3985,7 @@ void Surf_NewMap (model_t *worldmodel)
|
||||||
|
|
||||||
//evil haxx
|
//evil haxx
|
||||||
r_dynamic.ival = r_dynamic.value;
|
r_dynamic.ival = r_dynamic.value;
|
||||||
if (r_dynamic.ival > 0 && cl.worldmodel->fromgame == fg_quake3) //quake3 has no lightmaps, disable r_dynamic
|
if (r_dynamic.ival > 0 && (!cl.worldmodel || cl.worldmodel->fromgame == fg_quake3)) //quake3 has no lightmaps, disable r_dynamic
|
||||||
r_dynamic.ival = 0;
|
r_dynamic.ival = 0;
|
||||||
|
|
||||||
memset (&r_worldentity, 0, sizeof(r_worldentity));
|
memset (&r_worldentity, 0, sizeof(r_worldentity));
|
||||||
|
|
Loading…
Reference in a new issue