Fixed repeatable bounces sending you hog-wild if you went into water shallow enough to only spend a single frame in before hitting the ground.

This commit is contained in:
toasterbabe 2017-03-25 12:42:39 +00:00
parent 0bd093faf7
commit 8d9b616f00
2 changed files with 2 additions and 0 deletions

View file

@ -3302,6 +3302,7 @@ static void P_PlayerZMovement(mobj_t *mo)
if (mo->player->pflags & PF_BOUNCING)
{
P_MobjCheckWater(mo);
mo->momz *= -1;
P_DoAbilityBounce(mo->player, true);
if (mo->player->scoreadd)

View file

@ -4017,6 +4017,7 @@ void P_DoBubbleBounce(player_t *player)
{
player->pflags &= ~(PF_JUMPED|PF_NOJUMPDAMAGE|PF_SHIELDABILITY);
S_StartSound(player->mo, sfx_s3k44);
P_MobjCheckWater(player->mo);
P_DoJump(player, false);
if (player->charflags & SF_NOJUMPSPIN)
P_SetPlayerMobjState(player->mo, S_PLAY_FALL);