Fix Elemental stomp's flames while Gravity Boots are active

This commit is contained in:
spherallic 2022-09-11 18:28:17 +02:00
parent 3d29e9770f
commit 5e6185abe2
2 changed files with 3 additions and 2 deletions

View file

@ -1440,7 +1440,7 @@ fixed_t P_GetMobjGravity(mobj_t *mo)
wasflip = (mo->eflags & MFE_VERTICALFLIP) != 0;
if (mo->type != MT_SPINFIRE)
if (mo->type != MT_SPINFIRE) // Prevent fire trails from disappearing in reverse gravity
mo->eflags &= ~MFE_VERTICALFLIP;
if (mo->subsector->sector->ffloors) // Check for 3D floor gravity too.

View file

@ -7690,7 +7690,8 @@ void P_ElementalFire(player_t *player, boolean cropcircle)
flame->fuse = TICRATE*7; // takes about an extra second to hit the ground
flame->destscale = player->mo->scale;
P_SetScale(flame, player->mo->scale);
flame->flags2 = (flame->flags2 & ~MF2_OBJECTFLIP)|(player->mo->flags2 & MF2_OBJECTFLIP);
if (!(player->mo->flags2 & MF2_OBJECTFLIP) != !(player->powers[pw_gravityboots])) // take gravity boots into account
flame->flags2 |= MF2_OBJECTFLIP;
flame->eflags = (flame->eflags & ~MFE_VERTICALFLIP)|(player->mo->eflags & MFE_VERTICALFLIP);
P_InstaThrust(flame, flame->angle, FixedMul(3*FRACUNIT, flame->scale));
P_SetObjectMomZ(flame, 3*FRACUNIT, false);