Merge branch 'no-squish' into 'master'

Add the MF_NOSQUISH flag, disables squash and stretch

See merge request KartKrew/Kart!501
This commit is contained in:
SteelT 2021-12-21 06:20:59 +00:00
commit cf3e92c293
3 changed files with 6 additions and 1 deletions

View file

@ -5806,6 +5806,8 @@ const char *const MOBJFLAG_LIST[] = {
"GRENADEBOUNCE", "GRENADEBOUNCE",
"RUNSPAWNFUNC", "RUNSPAWNFUNC",
"DONTENCOREMAP", "DONTENCOREMAP",
"PICKUPFROMBELOW",
"NOSQUISH",
NULL NULL
}; };

View file

@ -3574,7 +3574,8 @@ static void P_CheckFloatbobPlatforms(mobj_t *mobj)
static void P_SquishThink(mobj_t *mobj) static void P_SquishThink(mobj_t *mobj)
{ {
if (!(mobj->eflags & MFE_SLOPELAUNCHED)) if (!(mobj->flags & MF_NOSQUISH) &&
!(mobj->eflags & MFE_SLOPELAUNCHED))
{ {
K_Squish(mobj); K_Squish(mobj);
} }

View file

@ -159,6 +159,8 @@ typedef enum
MF_DONTENCOREMAP = 1<<28, MF_DONTENCOREMAP = 1<<28,
// Hitbox extends just as far below as above. // Hitbox extends just as far below as above.
MF_PICKUPFROMBELOW = 1<<29, MF_PICKUPFROMBELOW = 1<<29,
// Disable momentum-based squash and stretch.
MF_NOSQUISH = 1<<30,
// free: to and including 1<<31 // free: to and including 1<<31
} mobjflag_t; } mobjflag_t;