mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-02-07 08:52:01 +00:00
Fix player Z snap to floor on moving platform ~FF_EXISTS
* Track player's old floorz by mo->floor_sectornum and floor_ffloornum * Track tmfloorz by tmfloorrover, tmfloor_sectornum, tmfloor_rovernum * Ceiling variants of the above
This commit is contained in:
parent
ffde71c656
commit
76d7a54b2b
3 changed files with 108 additions and 9 deletions
100
src/p_map.c
100
src/p_map.c
|
@ -52,6 +52,8 @@ fixed_t tmfloorz, tmceilingz;
|
||||||
static fixed_t tmdropoffz, tmdrpoffceilz; // drop-off floor/ceiling heights
|
static fixed_t tmdropoffz, tmdrpoffceilz; // drop-off floor/ceiling heights
|
||||||
mobj_t *tmfloorthing; // the thing corresponding to tmfloorz or NULL if tmfloorz is from a sector
|
mobj_t *tmfloorthing; // the thing corresponding to tmfloorz or NULL if tmfloorz is from a sector
|
||||||
mobj_t *tmhitthing; // the solid thing you bumped into (for collisions)
|
mobj_t *tmhitthing; // the solid thing you bumped into (for collisions)
|
||||||
|
ffloor_t *tmfloorrover, *tmceilingrover;
|
||||||
|
size_t tmfloor_sectornum, tmfloor_rovernum, tmceiling_sectornum, tmceiling_rovernum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
pslope_t *tmfloorslope, *tmceilingslope;
|
pslope_t *tmfloorslope, *tmceilingslope;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1417,6 +1419,8 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
if (thing->z + thing->height > tmfloorz)
|
if (thing->z + thing->height > tmfloorz)
|
||||||
{
|
{
|
||||||
tmfloorz = thing->z + thing->height;
|
tmfloorz = thing->z + thing->height;
|
||||||
|
tmfloorrover = NULL;
|
||||||
|
tmfloor_sectornum = tmfloor_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = NULL;
|
tmfloorslope = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1437,6 +1441,8 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
tmfloorz = tmceilingz = topz; // block while in air
|
tmfloorz = tmceilingz = topz; // block while in air
|
||||||
|
tmceilingrover = NULL;
|
||||||
|
tmceiling_sectornum = tmceiling_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmceilingslope = NULL;
|
tmceilingslope = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1445,6 +1451,8 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
else if (topz < tmceilingz && tmthing->z <= thing->z+thing->height)
|
else if (topz < tmceilingz && tmthing->z <= thing->z+thing->height)
|
||||||
{
|
{
|
||||||
tmceilingz = topz;
|
tmceilingz = topz;
|
||||||
|
tmceilingrover = NULL;
|
||||||
|
tmceiling_sectornum = tmceiling_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmceilingslope = NULL;
|
tmceilingslope = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1461,6 +1469,8 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
if (thing->z < tmceilingz)
|
if (thing->z < tmceilingz)
|
||||||
{
|
{
|
||||||
tmceilingz = thing->z;
|
tmceilingz = thing->z;
|
||||||
|
tmceilingrover = NULL;
|
||||||
|
tmceiling_sectornum = tmceiling_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmceilingslope = NULL;
|
tmceilingslope = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1481,6 +1491,8 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
tmfloorz = tmceilingz = topz; // block while in air
|
tmfloorz = tmceilingz = topz; // block while in air
|
||||||
|
tmfloorrover = NULL;
|
||||||
|
tmfloor_sectornum = tmfloor_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = NULL;
|
tmfloorslope = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1489,6 +1501,8 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
else if (topz > tmfloorz && tmthing->z+tmthing->height >= thing->z)
|
else if (topz > tmfloorz && tmthing->z+tmthing->height >= thing->z)
|
||||||
{
|
{
|
||||||
tmfloorz = topz;
|
tmfloorz = topz;
|
||||||
|
tmfloorrover = NULL;
|
||||||
|
tmfloor_sectornum = tmfloor_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = NULL;
|
tmfloorslope = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1640,6 +1654,8 @@ static boolean PIT_CheckLine(line_t *ld)
|
||||||
{
|
{
|
||||||
tmceilingz = opentop;
|
tmceilingz = opentop;
|
||||||
ceilingline = ld;
|
ceilingline = ld;
|
||||||
|
tmceilingrover = NULL;
|
||||||
|
tmceiling_sectornum = tmceiling_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmceilingslope = opentopslope;
|
tmceilingslope = opentopslope;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1648,6 +1664,8 @@ static boolean PIT_CheckLine(line_t *ld)
|
||||||
if (openbottom > tmfloorz)
|
if (openbottom > tmfloorz)
|
||||||
{
|
{
|
||||||
tmfloorz = openbottom;
|
tmfloorz = openbottom;
|
||||||
|
tmfloorrover = NULL;
|
||||||
|
tmfloor_sectornum = tmfloor_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = openbottomslope;
|
tmfloorslope = openbottomslope;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1729,6 +1747,10 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
// will adjust them.
|
// will adjust them.
|
||||||
tmfloorz = tmdropoffz = P_GetFloorZ(thing, newsubsec->sector, x, y, NULL); //newsubsec->sector->floorheight;
|
tmfloorz = tmdropoffz = P_GetFloorZ(thing, newsubsec->sector, x, y, NULL); //newsubsec->sector->floorheight;
|
||||||
tmceilingz = P_GetCeilingZ(thing, newsubsec->sector, x, y, NULL); //newsubsec->sector->ceilingheight;
|
tmceilingz = P_GetCeilingZ(thing, newsubsec->sector, x, y, NULL); //newsubsec->sector->ceilingheight;
|
||||||
|
tmfloorrover = NULL;
|
||||||
|
tmfloor_sectornum = tmfloor_rovernum = 0;
|
||||||
|
tmceilingrover = NULL;
|
||||||
|
tmceiling_sectornum = tmceiling_rovernum = 0;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = newsubsec->sector->f_slope;
|
tmfloorslope = newsubsec->sector->f_slope;
|
||||||
tmceilingslope = newsubsec->sector->c_slope;
|
tmceilingslope = newsubsec->sector->c_slope;
|
||||||
|
@ -1738,6 +1760,7 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
if (newsubsec->sector->ffloors)
|
if (newsubsec->sector->ffloors)
|
||||||
{
|
{
|
||||||
ffloor_t *rover;
|
ffloor_t *rover;
|
||||||
|
size_t rovernum = 0;
|
||||||
fixed_t delta1, delta2;
|
fixed_t delta1, delta2;
|
||||||
INT32 thingtop = thing->z + thing->height;
|
INT32 thingtop = thing->z + thing->height;
|
||||||
|
|
||||||
|
@ -1746,7 +1769,10 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
fixed_t topheight, bottomheight;
|
fixed_t topheight, bottomheight;
|
||||||
|
|
||||||
if (!(rover->flags & FF_EXISTS))
|
if (!(rover->flags & FF_EXISTS))
|
||||||
|
{
|
||||||
|
rovernum++;
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
topheight = P_GetFOFTopZ(thing, newsubsec->sector, rover, x, y, NULL);
|
topheight = P_GetFOFTopZ(thing, newsubsec->sector, rover, x, y, NULL);
|
||||||
bottomheight = P_GetFOFBottomZ(thing, newsubsec->sector, rover, x, y, NULL);
|
bottomheight = P_GetFOFBottomZ(thing, newsubsec->sector, rover, x, y, NULL);
|
||||||
|
@ -1772,6 +1798,9 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
{
|
{
|
||||||
if (tmfloorz < topheight - sinklevel) {
|
if (tmfloorz < topheight - sinklevel) {
|
||||||
tmfloorz = topheight - sinklevel;
|
tmfloorz = topheight - sinklevel;
|
||||||
|
tmfloorrover = rover;
|
||||||
|
tmfloor_sectornum = newsubsec->sector - sectors;
|
||||||
|
tmfloor_rovernum = rovernum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = *rover->t_slope;
|
tmfloorslope = *rover->t_slope;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1781,12 +1810,16 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
{
|
{
|
||||||
if (tmceilingz > bottomheight + sinklevel) {
|
if (tmceilingz > bottomheight + sinklevel) {
|
||||||
tmceilingz = bottomheight + sinklevel;
|
tmceilingz = bottomheight + sinklevel;
|
||||||
|
tmceilingrover = rover;
|
||||||
|
tmceiling_sectornum = newsubsec->sector - sectors;
|
||||||
|
tmceiling_rovernum = rovernum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmceilingslope = *rover->b_slope;
|
tmceilingslope = *rover->b_slope;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
rovernum++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1797,7 +1830,10 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
else if (!((rover->flags & FF_BLOCKPLAYER && thing->player)
|
else if (!((rover->flags & FF_BLOCKPLAYER && thing->player)
|
||||||
|| (rover->flags & FF_BLOCKOTHERS && !thing->player)
|
|| (rover->flags & FF_BLOCKOTHERS && !thing->player)
|
||||||
|| rover->flags & FF_QUICKSAND))
|
|| rover->flags & FF_QUICKSAND))
|
||||||
|
{
|
||||||
|
rovernum++;
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
if (rover->flags & FF_QUICKSAND)
|
if (rover->flags & FF_QUICKSAND)
|
||||||
{
|
{
|
||||||
|
@ -1805,12 +1841,16 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
{
|
{
|
||||||
if (tmfloorz < thing->z) {
|
if (tmfloorz < thing->z) {
|
||||||
tmfloorz = thing->z;
|
tmfloorz = thing->z;
|
||||||
|
tmfloorrover = rover;
|
||||||
|
tmfloor_sectornum = newsubsec->sector - sectors;
|
||||||
|
tmfloor_rovernum = rovernum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = NULL;
|
tmfloorslope = NULL;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Quicksand blocks never change heights otherwise.
|
// Quicksand blocks never change heights otherwise.
|
||||||
|
rovernum++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1823,6 +1863,9 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
&& !(rover->flags & FF_REVERSEPLATFORM))
|
&& !(rover->flags & FF_REVERSEPLATFORM))
|
||||||
{
|
{
|
||||||
tmfloorz = tmdropoffz = topheight;
|
tmfloorz = tmdropoffz = topheight;
|
||||||
|
tmfloorrover = rover;
|
||||||
|
tmfloor_sectornum = newsubsec->sector - sectors;
|
||||||
|
tmfloor_rovernum = rovernum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = *rover->t_slope;
|
tmfloorslope = *rover->t_slope;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1832,10 +1875,14 @@ boolean P_CheckPosition(mobj_t *thing, fixed_t x, fixed_t y)
|
||||||
&& !(thing->type == MT_SKIM && (rover->flags & FF_SWIMMABLE)))
|
&& !(thing->type == MT_SKIM && (rover->flags & FF_SWIMMABLE)))
|
||||||
{
|
{
|
||||||
tmceilingz = tmdrpoffceilz = bottomheight;
|
tmceilingz = tmdrpoffceilz = bottomheight;
|
||||||
|
tmceilingrover = rover;
|
||||||
|
tmceiling_sectornum = newsubsec->sector - sectors;
|
||||||
|
tmceiling_rovernum = rovernum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmceilingslope = *rover->b_slope;
|
tmceilingslope = *rover->b_slope;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
rovernum++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2328,6 +2375,12 @@ boolean PIT_PushableMoved(mobj_t *thing)
|
||||||
mobj_t *oldthing = tmthing;
|
mobj_t *oldthing = tmthing;
|
||||||
line_t *oldceilline = ceilingline;
|
line_t *oldceilline = ceilingline;
|
||||||
line_t *oldblockline = blockingline;
|
line_t *oldblockline = blockingline;
|
||||||
|
ffloor_t *oldflrrover = tmfloorrover;
|
||||||
|
ffloor_t *oldceilrover = tmceilingrover;
|
||||||
|
size_t oldflrrover_sectornum = tmfloor_sectornum;
|
||||||
|
size_t oldflrrover_ffloornum = tmfloor_rovernum;
|
||||||
|
size_t oldceilrover_sectornum = tmceiling_sectornum;
|
||||||
|
size_t oldceilrover_ffloornum = tmceiling_rovernum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
pslope_t *oldfslope = tmfloorslope;
|
pslope_t *oldfslope = tmfloorslope;
|
||||||
pslope_t *oldcslope = tmceilingslope;
|
pslope_t *oldcslope = tmceilingslope;
|
||||||
|
@ -2344,6 +2397,12 @@ boolean PIT_PushableMoved(mobj_t *thing)
|
||||||
P_SetTarget(&tmthing, oldthing);
|
P_SetTarget(&tmthing, oldthing);
|
||||||
ceilingline = oldceilline;
|
ceilingline = oldceilline;
|
||||||
blockingline = oldblockline;
|
blockingline = oldblockline;
|
||||||
|
tmfloorrover = oldflrrover;
|
||||||
|
tmceilingrover = oldceilrover;
|
||||||
|
tmfloor_sectornum = oldflrrover_sectornum;
|
||||||
|
tmfloor_rovernum = oldflrrover_ffloornum;
|
||||||
|
tmceiling_sectornum = oldceilrover_sectornum;
|
||||||
|
tmceiling_rovernum = oldceilrover_ffloornum;
|
||||||
#ifdef ESLOPE
|
#ifdef ESLOPE
|
||||||
tmfloorslope = oldfslope;
|
tmfloorslope = oldfslope;
|
||||||
tmceilingslope = oldcslope;
|
tmceilingslope = oldcslope;
|
||||||
|
@ -2663,7 +2722,9 @@ static boolean P_ThingHeightClip(mobj_t *thing)
|
||||||
{
|
{
|
||||||
boolean floormoved;
|
boolean floormoved;
|
||||||
fixed_t oldfloorz = thing->floorz;
|
fixed_t oldfloorz = thing->floorz;
|
||||||
|
size_t oldfloor_sectornum = thing->floor_sectornum, oldfloor_rovernum = thing->floor_rovernum;
|
||||||
boolean onfloor = P_IsObjectOnGround(thing);//(thing->z <= thing->floorz);
|
boolean onfloor = P_IsObjectOnGround(thing);//(thing->z <= thing->floorz);
|
||||||
|
ffloor_t *rover = NULL;
|
||||||
|
|
||||||
if (thing->flags & MF_NOCLIPHEIGHT)
|
if (thing->flags & MF_NOCLIPHEIGHT)
|
||||||
return true;
|
return true;
|
||||||
|
@ -2678,6 +2739,10 @@ static boolean P_ThingHeightClip(mobj_t *thing)
|
||||||
|
|
||||||
thing->floorz = tmfloorz;
|
thing->floorz = tmfloorz;
|
||||||
thing->ceilingz = tmceilingz;
|
thing->ceilingz = tmceilingz;
|
||||||
|
thing->floor_sectornum = tmfloor_sectornum;
|
||||||
|
thing->floor_rovernum = tmfloor_rovernum;
|
||||||
|
thing->ceiling_sectornum = tmceiling_sectornum;
|
||||||
|
thing->ceiling_rovernum = tmceiling_rovernum;
|
||||||
|
|
||||||
// Ugly hack?!?! As long as just ceilingz is the lowest,
|
// Ugly hack?!?! As long as just ceilingz is the lowest,
|
||||||
// you'll still get crushed, right?
|
// you'll still get crushed, right?
|
||||||
|
@ -2686,16 +2751,33 @@ static boolean P_ThingHeightClip(mobj_t *thing)
|
||||||
|
|
||||||
if (onfloor && !(thing->flags & MF_NOGRAVITY) && floormoved)
|
if (onfloor && !(thing->flags & MF_NOGRAVITY) && floormoved)
|
||||||
{
|
{
|
||||||
if (thing->eflags & MFE_VERTICALFLIP)
|
// Find FOF referenced by floorz
|
||||||
thing->pmomz = thing->ceilingz - (thing->z + thing->height);
|
if (oldfloor_sectornum)
|
||||||
else
|
{
|
||||||
thing->pmomz = thing->floorz - thing->z;
|
size_t rovernum = 0;
|
||||||
thing->eflags |= MFE_APPLYPMOMZ;
|
for (rover = sectors[oldfloor_sectornum].ffloors; rover; rover = rover->next)
|
||||||
|
{
|
||||||
|
if (rovernum == oldfloor_rovernum)
|
||||||
|
break;
|
||||||
|
rovernum++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (thing->eflags & MFE_VERTICALFLIP)
|
// Match the Thing's old floorz to an FOF and check for FF_EXISTS
|
||||||
thing->z = thing->ceilingz - thing->height;
|
// If ~FF_EXISTS, don't set mobj Z.
|
||||||
else
|
if (!rover || (rover->flags & FF_EXISTS))
|
||||||
thing->z = thing->floorz;
|
{
|
||||||
|
if (thing->eflags & MFE_VERTICALFLIP)
|
||||||
|
thing->pmomz = thing->ceilingz - (thing->z + thing->height);
|
||||||
|
else
|
||||||
|
thing->pmomz = thing->floorz - thing->z;
|
||||||
|
thing->eflags |= MFE_APPLYPMOMZ;
|
||||||
|
|
||||||
|
if (thing->eflags & MFE_VERTICALFLIP)
|
||||||
|
thing->z = thing->ceilingz - thing->height;
|
||||||
|
else
|
||||||
|
thing->z = thing->floorz;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (!tmfloorthing)
|
else if (!tmfloorthing)
|
||||||
{
|
{
|
||||||
|
|
|
@ -282,6 +282,10 @@ typedef struct mobj_s
|
||||||
// The closest interval over all contacted sectors (or things).
|
// The closest interval over all contacted sectors (or things).
|
||||||
fixed_t floorz; // Nearest floor below.
|
fixed_t floorz; // Nearest floor below.
|
||||||
fixed_t ceilingz; // Nearest ceiling above.
|
fixed_t ceilingz; // Nearest ceiling above.
|
||||||
|
size_t floor_sectornum; // FOF referred by floorz
|
||||||
|
size_t floor_rovernum; // FOF referred by floorz
|
||||||
|
size_t ceiling_sectornum; // FOF referred by ceilingz
|
||||||
|
size_t ceiling_rovernum; // FOF referred by ceilingz
|
||||||
|
|
||||||
// For movement checking.
|
// For movement checking.
|
||||||
fixed_t radius;
|
fixed_t radius;
|
||||||
|
|
|
@ -1192,6 +1192,10 @@ static void SaveMobjThinker(const thinker_t *th, const UINT8 type)
|
||||||
WRITEFIXED(save_p, mobj->z); // Force this so 3dfloor problems don't arise.
|
WRITEFIXED(save_p, mobj->z); // Force this so 3dfloor problems don't arise.
|
||||||
WRITEFIXED(save_p, mobj->floorz);
|
WRITEFIXED(save_p, mobj->floorz);
|
||||||
WRITEFIXED(save_p, mobj->ceilingz);
|
WRITEFIXED(save_p, mobj->ceilingz);
|
||||||
|
WRITEUINT32(save_p, (UINT32)mobj->floor_sectornum);
|
||||||
|
WRITEUINT32(save_p, (UINT32)mobj->floor_rovernum);
|
||||||
|
WRITEUINT32(save_p, (UINT32)mobj->ceiling_sectornum);
|
||||||
|
WRITEUINT32(save_p, (UINT32)mobj->ceiling_rovernum);
|
||||||
|
|
||||||
if (diff & MD_SPAWNPOINT)
|
if (diff & MD_SPAWNPOINT)
|
||||||
{
|
{
|
||||||
|
@ -1989,6 +1993,7 @@ static void LoadMobjThinker(actionf_p1 thinker)
|
||||||
UINT16 diff2;
|
UINT16 diff2;
|
||||||
INT32 i;
|
INT32 i;
|
||||||
fixed_t z, floorz, ceilingz;
|
fixed_t z, floorz, ceilingz;
|
||||||
|
size_t floor_sectornum, floor_rovernum, ceiling_sectornum, ceiling_rovernum;
|
||||||
|
|
||||||
diff = READUINT32(save_p);
|
diff = READUINT32(save_p);
|
||||||
if (diff & MD_MORE)
|
if (diff & MD_MORE)
|
||||||
|
@ -2001,6 +2006,10 @@ static void LoadMobjThinker(actionf_p1 thinker)
|
||||||
z = READFIXED(save_p); // Force this so 3dfloor problems don't arise.
|
z = READFIXED(save_p); // Force this so 3dfloor problems don't arise.
|
||||||
floorz = READFIXED(save_p);
|
floorz = READFIXED(save_p);
|
||||||
ceilingz = READFIXED(save_p);
|
ceilingz = READFIXED(save_p);
|
||||||
|
floor_sectornum = (size_t)READUINT32(save_p);
|
||||||
|
floor_rovernum = (size_t)READUINT32(save_p);
|
||||||
|
ceiling_sectornum = (size_t)READUINT32(save_p);
|
||||||
|
ceiling_rovernum = (size_t)READUINT32(save_p);
|
||||||
|
|
||||||
if (diff & MD_SPAWNPOINT)
|
if (diff & MD_SPAWNPOINT)
|
||||||
{
|
{
|
||||||
|
@ -2026,6 +2035,10 @@ static void LoadMobjThinker(actionf_p1 thinker)
|
||||||
mobj->z = z;
|
mobj->z = z;
|
||||||
mobj->floorz = floorz;
|
mobj->floorz = floorz;
|
||||||
mobj->ceilingz = ceilingz;
|
mobj->ceilingz = ceilingz;
|
||||||
|
mobj->floor_sectornum = floor_sectornum;
|
||||||
|
mobj->floor_rovernum = floor_rovernum;
|
||||||
|
mobj->ceiling_sectornum = ceiling_sectornum;
|
||||||
|
mobj->ceiling_rovernum = ceiling_rovernum;
|
||||||
|
|
||||||
if (diff & MD_TYPE)
|
if (diff & MD_TYPE)
|
||||||
mobj->type = READUINT32(save_p);
|
mobj->type = READUINT32(save_p);
|
||||||
|
|
Loading…
Reference in a new issue