diff --git a/source/exhumed/src/input.cpp b/source/exhumed/src/input.cpp index cf7c8f1e3..510668ba7 100644 --- a/source/exhumed/src/input.cpp +++ b/source/exhumed/src/input.cpp @@ -120,23 +120,21 @@ void PlayerInterruptKeys(bool after) InputPacket tempinput{}; fixed_t input_angle = 0; - if (PlayerList[nLocalPlayer].nHealth == 0) + if (!after) { localInput = {}; + ApplyGlobalInput(localInput, &info); + if (PlayerList[nLocalPlayer].nHealth == 0) localInput.actions &= SB_OPEN; + } + + if (PlayerList[nLocalPlayer].nHealth == 0) + { lPlayerYVel = 0; lPlayerXVel = 0; nPlayerDAng = 0; return; } - if (!after) - { - localInput = {}; - ApplyGlobalInput(localInput, &info); - if (PlayerList[nLocalPlayer].nHealth == 0) localInput.actions &= ~(SB_FIRE | SB_JUMP | SB_CROUCH); - } - - // JBF: Run key behaviour is selectable int const playerRunning = !!(localInput.actions & SB_RUN); int const turnAmount = playerRunning ? 12 : 8; diff --git a/source/exhumed/src/player.cpp b/source/exhumed/src/player.cpp index 6bfe47b13..79932543f 100644 --- a/source/exhumed/src/player.cpp +++ b/source/exhumed/src/player.cpp @@ -1280,6 +1280,10 @@ loc_1AB8E: uint16_t buttons = sPlayerInput[nPlayer].buttons; auto actions = sPlayerInput[nPlayer].actions; + if (actions & SB_OPEN) + { + int a = 0; + } // loc_1AEF5: if (PlayerList[nPlayer].nHealth > 0)