mirror of
https://github.com/fabiangreffrath/woof.git
synced 2025-09-25 05:48:03 -04:00
clean up some demo compatibility code
This commit is contained in:
parent
70f2a0c2d0
commit
b5c63e620a
@ -409,17 +409,18 @@ static boolean P_Move(mobj_t *actor, boolean dropoff) // killough 9/12/98
|
||||
if (P_UseSpecialLine(actor, spechit[numspechit], 0))
|
||||
good |= spechit[numspechit] == blockline ? 1 : 2;
|
||||
|
||||
// [FG] cph - compatibility maze here
|
||||
// [FG] compatibility maze here
|
||||
// Boom v2.01 and orig. Doom return "good"
|
||||
// Boom v2.02 and LxDoom return good && (P_Random(pr_trywalk)&3)
|
||||
// MBF plays even more games
|
||||
|
||||
if (!good || comp[comp_doorstuck])
|
||||
if (demo_version < 202)
|
||||
return good;
|
||||
if (demo_version < 203)
|
||||
return (P_Random(pr_trywalk)&3); /* jff 8/13/98 */
|
||||
else /* finally, MBF code */
|
||||
return ((P_Random(pr_opendoor) >= 230) ^ (good & 1));
|
||||
return good && (compatibility || (P_Random(pr_trywalk)&3)); //jff 8/13/98
|
||||
else
|
||||
return good && (demo_version < 203 || comp[comp_doorstuck] ||
|
||||
(P_Random(pr_opendoor) >= 230) ^ (good & 1));
|
||||
}
|
||||
else
|
||||
actor->flags &= ~MF_INFLOAT;
|
||||
@ -2102,6 +2103,7 @@ void A_Detonate(mobj_t *mo)
|
||||
void A_Mushroom(mobj_t *actor)
|
||||
{
|
||||
int i, j, n = actor->info->damage;
|
||||
|
||||
// Mushroom parameters are part of code pointer's state
|
||||
fixed_t misc1 = actor->state->misc1 ? actor->state->misc1 : FRACUNIT*4;
|
||||
fixed_t misc2 = actor->state->misc2 ? actor->state->misc2 : FRACUNIT/2;
|
||||
|
@ -118,7 +118,7 @@ result_e T_MovePlane
|
||||
// Moving a floor up
|
||||
// jff 02/04/98 keep floor from moving thru ceilings
|
||||
// jff 2/22/98 weaken check to demo_compatibility
|
||||
destheight = (demo_compatibility || comp[comp_floors] ||
|
||||
destheight = (demo_compatibility || (demo_version >= 203 && comp[comp_floors]) ||
|
||||
dest<sector->ceilingheight)? // killough 10/98
|
||||
dest : sector->ceilingheight;
|
||||
if (sector->floorheight + speed > destheight)
|
||||
@ -141,7 +141,7 @@ result_e T_MovePlane
|
||||
flag = P_CheckSector(sector,crush); //jff 3/19/98 use faster chk
|
||||
if (flag == true)
|
||||
{
|
||||
if (demo_compatibility || comp[comp_floors]) // killough 10/98
|
||||
if (demo_compatibility || (demo_version >= 203 && comp[comp_floors])) // killough 10/98
|
||||
if (crush == true) //jff 1/25/98 fix floor crusher
|
||||
return crushed;
|
||||
sector->floorheight = lastpos;
|
||||
@ -821,7 +821,7 @@ int EV_BuildStairs
|
||||
if (tsec->floorpic != texture)
|
||||
continue;
|
||||
|
||||
if (demo_compatibility || demo_version >= 203)
|
||||
if (demo_compatibility || demo_version >= 203 || compatibility)
|
||||
{
|
||||
height += stairsize; // killough 10/98: intentionally left this way
|
||||
}
|
||||
@ -830,7 +830,7 @@ int EV_BuildStairs
|
||||
if (P_SectorActive(floor_special,tsec)) //jff 2/22/98
|
||||
continue;
|
||||
|
||||
if (!demo_compatibility && demo_version < 203)
|
||||
if (!demo_compatibility && demo_version < 203 && !compatibility)
|
||||
{
|
||||
height += stairsize;
|
||||
}
|
||||
|
@ -943,7 +943,7 @@ void P_RemoveSlimeTrails(void) // killough 10/98
|
||||
v->r_y = (fixed_t)((dy2 * y0 + dx2 * y1 + dxy * (x0 - x1)) / s);
|
||||
|
||||
// [FG] override actual vertex coordinates except in compatibility mode
|
||||
if (!demo_compatibility)
|
||||
if (demo_version >= 203)
|
||||
{
|
||||
v->x = v->r_x;
|
||||
v->y = v->r_y;
|
||||
|
Loading…
x
Reference in New Issue
Block a user