Fix a regression in non-ramp sector (no step down) functionality.

Seems to be a regression in internal too. Requires more analysis on behaviour in the 2.2 engine, but essential for maintaining compatibility in 2.1 (such as with Opulence wobbly carpet).
This commit is contained in:
toaster 2022-08-12 22:13:45 +01:00
parent cf882f4a30
commit c09f5c0425

View file

@ -2766,7 +2766,11 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
return false; // mobj must lower itself to fit
}
}
else if (maxstep > 0) // Step down
else if (maxstep > 0 && !(
thing->player && (
P_PlayerTouchingSectorSpecial(thing->player, 1, 14)
|| GETSECSPECIAL(R_PointInSubsector(x, y)->sector->special, 1) == 14)
)) // Step down
{
// If the floor difference is MAXSTEPMOVE or less, and the sector isn't Section1:14, ALWAYS
// step down! Formerly required a Section1:13 sector for the full MAXSTEPMOVE, but no more.