From 3600e1b140de92bd733bacb916de6a273d99d172 Mon Sep 17 00:00:00 2001 From: lachwright Date: Sat, 12 Oct 2019 04:41:50 +0800 Subject: [PATCH] Allow rollout rock's splash sound delay reduction to occur above water --- src/p_enemy.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/p_enemy.c b/src/p_enemy.c index f9c82bb60..10251910e 100644 --- a/src/p_enemy.c +++ b/src/p_enemy.c @@ -14237,6 +14237,9 @@ void A_RolloutRock(mobj_t *actor) boolean inwater = actor->eflags & (MFE_TOUCHWATER|MFE_UNDERWATER); actor->friction = FRACUNIT; // turns out riding on solids sucks, so let's just make it easier on ourselves + + if (actor->threshold) + actor->threshold--; if (inwater && !(actor->flags2 & MF2_AMBUSH)) // buoyancy in water (or lava) { @@ -14244,8 +14247,6 @@ void A_RolloutRock(mobj_t *actor) fixed_t prevmomz = actor->momz; actor->momz = FixedMul(actor->momz, locvar2); actor->momz += flip * FixedMul(locvar2, actor->scale); - if (actor->threshold) - actor->threshold--; if (flip*prevmomz < 0 && flip*actor->momz >= 0 && !actor->threshold) { if (actor->eflags & MFE_UNDERWATER)