From ad1ce014469acd56caab6c74d04474e029952193 Mon Sep 17 00:00:00 2001 From: oy Date: Thu, 3 Jun 2010 01:39:28 +0800 Subject: fixed shotbug (#80) --- src/game/client/components/controls.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/game/client/components/controls.cpp b/src/game/client/components/controls.cpp index 0b4918b2..7b3f4716 100644 --- a/src/game/client/components/controls.cpp +++ b/src/game/client/components/controls.cpp @@ -19,7 +19,10 @@ void CControls::OnReset() { m_LastData.m_Direction = 0; m_LastData.m_Hook = 0; - m_LastData.m_Fire = 0; + // simulate releasing the fire button + if((m_LastData.m_Fire&1) != 0) + m_LastData.m_Fire++; + m_LastData.m_Fire &= INPUT_STATE_MASK; m_LastData.m_Jump = 0; m_InputData = m_LastData; -- cgit 1.4.1