about summary refs log tree commit diff
path: root/src/game
diff options
context:
space:
mode:
Diffstat (limited to 'src/game')
-rw-r--r--src/game/client/components/controls.cpp5
-rw-r--r--src/game/client/components/controls.h1
-rw-r--r--src/game/client/gameclient.cpp5
-rw-r--r--src/game/client/gameclient.h1
4 files changed, 12 insertions, 0 deletions
diff --git a/src/game/client/components/controls.cpp b/src/game/client/components/controls.cpp
index 1dd74af2..f7da46b6 100644
--- a/src/game/client/components/controls.cpp
+++ b/src/game/client/components/controls.cpp
@@ -32,6 +32,11 @@ void CControls::OnReset()
 	m_InputDirectionRight = 0;
 }
 
+void CControls::OnRelease()
+{
+	OnReset();
+}
+
 void CControls::OnPlayerDeath()
 {
 	m_LastData.m_WantedWeapon = m_InputData.m_WantedWeapon = 0;
diff --git a/src/game/client/components/controls.h b/src/game/client/components/controls.h
index 38b3c8ba..a50318f5 100644
--- a/src/game/client/components/controls.h
+++ b/src/game/client/components/controls.h
@@ -19,6 +19,7 @@ public:
 	CControls();
 	
 	virtual void OnReset();
+	virtual void OnRelease();
 	virtual void OnRender();
 	virtual void OnMessage(int MsgType, void *pRawMsg);
 	virtual bool OnMouseMove(float x, float y);
diff --git a/src/game/client/gameclient.cpp b/src/game/client/gameclient.cpp
index 9a05cc88..e37eebea 100644
--- a/src/game/client/gameclient.cpp
+++ b/src/game/client/gameclient.cpp
@@ -971,6 +971,11 @@ void CGameClient::OnPredict()
 	m_PredictedTick = Client()->PredGameTick();
 }
 
+void CGameClient::OnActivateEditor()
+{
+	OnRelease();
+}
+
 void CGameClient::CClientData::UpdateRenderInfo()
 {
 	m_RenderInfo = m_SkinInfo;
diff --git a/src/game/client/gameclient.h b/src/game/client/gameclient.h
index 99e64028..1e5c4856 100644
--- a/src/game/client/gameclient.h
+++ b/src/game/client/gameclient.h
@@ -176,6 +176,7 @@ public:
 	virtual void OnMessage(int MsgId, CUnpacker *pUnpacker);
 	virtual void OnNewSnapshot();
 	virtual void OnPredict();
+	virtual void OnActivateEditor();
 	virtual int OnSnapInput(int *pData);
 	virtual void OnShutdown();
 	virtual void OnEnterGame();