From 7d5ca901eb81319f2bcf80e06200d4c6bd284fe7 Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Sun, 26 Mar 2023 15:17:28 +1100 Subject: [PATCH] - Exhumed: Clear all input out upon restarting the player. * Stale accumulation from the last round can apply on the next tic. --- source/games/exhumed/src/player.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/games/exhumed/src/player.cpp b/source/games/exhumed/src/player.cpp index 4aa18580e..3c94e02e0 100644 --- a/source/games/exhumed/src/player.cpp +++ b/source/games/exhumed/src/player.cpp @@ -298,6 +298,7 @@ void RestartPlayer(int nPlayer) pPlayer->nAir = 100; pPlayer->pPlayerGrenade = nullptr; pPlayer->dVertPan = 0; + pPlayer->vel.Zero(); pPlayer->nThrust.Zero(); pPlayer->nDestVertPan = pPlayerActor->PrevAngles.Pitch = pPlayerActor->spr.Angles.Pitch = nullAngle; pPlayer->nBreathTimer = 90; @@ -335,6 +336,9 @@ void RestartPlayer(int nPlayer) } BuildRa(nPlayer); + + // clear out all input before finishing here + inputState.ClearAllInput(); } //---------------------------------------------------------------------------