- adapt ClearAllInput to new globalized code.

This commit is contained in:
Christoph Oelckers 2020-09-10 23:35:42 +02:00
parent af7ad28ad6
commit 38cc094ac3
2 changed files with 1 additions and 2 deletions

View file

@ -126,6 +126,7 @@ void InputState::ClearAllInput()
ActionsToSend = 0;
WeaponToSend = 0;
dpad_lock = 0;
lastCheck = 0;
buttonMap.ResetButtonStates(); // this is important. If all input is cleared, the buttons must be cleared as well.
gi->clearlocalinputstate(); // also clear game local input state.
}

View file

@ -43,7 +43,6 @@ BEGIN_DUKE_NS
// State timer counters.
static int turnheldtime;
static int lastcontroltime;
static double lastCheck;
static InputPacket loc; // input accumulation buffer.
//---------------------------------------------------------------------------
@ -1068,7 +1067,6 @@ void GameInterface::clearlocalinputstate()
loc = {};
turnheldtime = 0;
lastcontroltime = 0;
lastCheck = 0;
}