mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2024-11-22 20:51:31 +00:00
maps: fix in load n64jam_doomshakalaka
https://www.moddb.com/games/quake-2/addons/quake-2-re-release-n64-sp-map-jam
This commit is contained in:
parent
b685aa4683
commit
131164748e
7 changed files with 23 additions and 11 deletions
|
@ -54,7 +54,8 @@ CL_AddMuzzleFlash(void)
|
|||
|
||||
if ((i < 1) || (i >= MAX_EDICTS))
|
||||
{
|
||||
Com_Error(ERR_DROP, "CL_AddMuzzleFlash: bad entity");
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, i, MAX_EDICTS);
|
||||
}
|
||||
|
||||
weapon = MSG_ReadByte(&net_message);
|
||||
|
@ -334,14 +335,15 @@ CL_AddMuzzleFlash2(void)
|
|||
|
||||
if ((ent < 1) || (ent >= MAX_EDICTS))
|
||||
{
|
||||
Com_Error(ERR_DROP, "CL_AddMuzzleFlash2: bad entity");
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, ent, MAX_EDICTS);
|
||||
}
|
||||
|
||||
flash_number = MSG_ReadByte(&net_message);
|
||||
|
||||
if (flash_number > 210)
|
||||
{
|
||||
Com_DPrintf("CL_AddMuzzleFlash2: bad offset");
|
||||
Com_DPrintf("%s: bad offset\n", __func__);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -864,7 +864,8 @@ CL_GetEntitySoundOrigin(int ent, vec3_t org)
|
|||
|
||||
if ((ent < 0) || (ent >= MAX_EDICTS))
|
||||
{
|
||||
Com_Error(ERR_DROP, "CL_GetEntitySoundOrigin: bad ent");
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, ent, MAX_EDICTS);
|
||||
}
|
||||
|
||||
old = &cl_entities[ent];
|
||||
|
@ -881,7 +882,8 @@ CL_GetEntitySoundVelocity(int ent, vec3_t vel)
|
|||
|
||||
if ((ent < 0) || (ent >= MAX_EDICTS))
|
||||
{
|
||||
Com_Error(ERR_DROP, "CL_GetEntitySoundVelocity: bad ent");
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, ent, MAX_EDICTS);
|
||||
}
|
||||
|
||||
old = &cl_entities[ent];
|
||||
|
|
|
@ -402,12 +402,13 @@ CL_ParsePacketEntities(frame_t *oldframe, frame_t *newframe)
|
|||
|
||||
if (newnum >= MAX_EDICTS)
|
||||
{
|
||||
Com_Error(ERR_DROP, "CL_ParsePacketEntities: bad number:%i", newnum);
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, newnum, MAX_EDICTS);
|
||||
}
|
||||
|
||||
if (net_message.readcount > net_message.cursize)
|
||||
{
|
||||
Com_Error(ERR_DROP, "CL_ParsePacketEntities: end of message");
|
||||
Com_Error(ERR_DROP, "%s: end of message", __func__);
|
||||
}
|
||||
|
||||
if (!newnum)
|
||||
|
@ -1288,7 +1289,8 @@ CL_ParseStartSoundPacket(void)
|
|||
|
||||
if (ent > MAX_EDICTS)
|
||||
{
|
||||
Com_Error(ERR_DROP, "CL_ParseStartSoundPacket: ent = %i", ent);
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, ent, MAX_EDICTS);
|
||||
}
|
||||
|
||||
channel &= 7;
|
||||
|
|
|
@ -69,7 +69,7 @@ Mod_LoadVisibility(const char *name, dvis_t **vis, int *numvisibility,
|
|||
|
||||
if (!l->filelen)
|
||||
{
|
||||
Com_Printf("%s: Map %s has too small visibility lump",
|
||||
Com_Printf("%s: Map %s has too small visibility lump\n",
|
||||
__func__, name);
|
||||
*vis = NULL;
|
||||
return;
|
||||
|
|
|
@ -171,7 +171,7 @@ typedef unsigned char byte;
|
|||
|
||||
/* per-level limits */
|
||||
#define MAX_CLIENTS 256 /* absolute limit */
|
||||
#define MAX_EDICTS 1024 /* must change protocol to increase more */
|
||||
#define MAX_EDICTS 2048 /* must change protocol to increase more */
|
||||
#define MAX_LIGHTSTYLES 256
|
||||
#define MAX_MODELS 512 /* these are sent over the net as bytes */
|
||||
#define MAX_SOUNDS 512 /* so they cannot be blindly increased */
|
||||
|
|
|
@ -445,7 +445,8 @@ MSG_WriteDeltaEntity(entity_state_t *from,
|
|||
|
||||
if (to->number >= MAX_EDICTS)
|
||||
{
|
||||
Com_Error(ERR_FATAL, "Entity number >= MAX_EDICTS");
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, to->number, MAX_EDICTS);
|
||||
}
|
||||
|
||||
/* send an update */
|
||||
|
|
|
@ -124,6 +124,11 @@ SV_CreateBaseline(void)
|
|||
|
||||
/* take current state as baseline */
|
||||
VectorCopy(svent->s.origin, svent->s.old_origin);
|
||||
if (entnum >= MAX_EDICTS)
|
||||
{
|
||||
Com_Error(ERR_DROP, "%s: bad entity %d >= %d\n",
|
||||
__func__, entnum, MAX_EDICTS);
|
||||
}
|
||||
sv.baselines[entnum] = svent->s;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue