mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-31 05:30:48 +00:00
Improved the way GFZ3 Eggman slows down in the air when MF2_SKULLFLYing.
This commit is contained in:
parent
7e8f7a59d1
commit
c786dbda78
1 changed files with 5 additions and 6 deletions
11
src/p_mobj.c
11
src/p_mobj.c
|
@ -4438,12 +4438,11 @@ static void P_Boss1Thinker(mobj_t *mobj)
|
||||||
|
|
||||||
if (mobj->flags2 & MF2_SKULLFLY)
|
if (mobj->flags2 & MF2_SKULLFLY)
|
||||||
{
|
{
|
||||||
if (P_MobjFlip(mobj)*mobj->momz > 0
|
fixed_t dist = (mobj->eflags & MFE_VERTICALFLIP)
|
||||||
&& ((mobj->eflags & MFE_VERTICALFLIP
|
? ((mobj->ceilingz-(2*mobj->height)) - (mobj->z+mobj->height))
|
||||||
&& (mobj->z+mobj->height) < (mobj->ceilingz-(2*mobj->height)))
|
: (mobj->z - (mobj->floorz+(2*mobj->height)));
|
||||||
|| (!(mobj->eflags & MFE_VERTICALFLIP)
|
if (dist > 0 && P_MobjFlip(mobj)*mobj->momz > 0)
|
||||||
&& mobj->z > (mobj->floorz+(2*mobj->height)))))
|
mobj->momz = FixedMul(mobj->momz, FRACUNIT - (dist>>12));
|
||||||
mobj->momz = FixedMul(mobj->momz, 60000);
|
|
||||||
}
|
}
|
||||||
else if (mobj->state != &states[mobj->info->spawnstate] && mobj->health > 0 && mobj->flags & MF_FLOAT)
|
else if (mobj->state != &states[mobj->info->spawnstate] && mobj->health > 0 && mobj->flags & MF_FLOAT)
|
||||||
mobj->momz = FixedMul(mobj->momz,7*FRACUNIT/8);
|
mobj->momz = FixedMul(mobj->momz,7*FRACUNIT/8);
|
||||||
|
|
Loading…
Reference in a new issue