Merge branch 'death-frame-tweak' into 'master'

Race: send player death sprite flying less further away

See merge request KartKrew/Kart!2088
This commit is contained in:
James R. 2024-03-11 09:42:28 +00:00
commit 87bd18b509

View file

@ -1707,7 +1707,7 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, UINT8 damaget
target->flags2 &= ~(MF2_SKULLFLY|MF2_NIGHTSPULL); target->flags2 &= ~(MF2_SKULLFLY|MF2_NIGHTSPULL);
target->health = 0; // This makes it easy to check if something's dead elsewhere. target->health = 0; // This makes it easy to check if something's dead elsewhere.
if (target->type != MT_BATTLEBUMPER) if (target->type != MT_BATTLEBUMPER && target->type != MT_PLAYER)
{ {
target->shadowscale = 0; target->shadowscale = 0;
} }
@ -1931,8 +1931,9 @@ void P_KillMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, UINT8 damaget
} }
} }
P_InstaThrust(target, flingAngle, max(flingSpeed, 14 * target->scale)); boolean battle = (gametyperules & (GTR_BUMPERS | GTR_BOSS)) == GTR_BUMPERS;
P_SetObjectMomZ(target, 20*FRACUNIT, false); P_InstaThrust(target, flingAngle, max(flingSpeed, 6 * target->scale) / (battle ? 1 : 3));
P_SetObjectMomZ(target, battle ? 20*FRACUNIT : 18*FRACUNIT, false);
P_PlayDeathSound(target); P_PlayDeathSound(target);