From 390f499ffe9689356263175c0f79ab4324341ef1 Mon Sep 17 00:00:00 2001 From: nullifiedcat Date: Sat, 15 Jul 2017 16:38:10 +0300 Subject: [PATCH] fix crash when changing thirdperson settings in menu --- src/globals.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/globals.cpp b/src/globals.cpp index f9505348..4900541c 100644 --- a/src/globals.cpp +++ b/src/globals.cpp @@ -14,7 +14,7 @@ int g_AppID = 0; void ThirdpersonCallback(IConVar* var, const char* pOldValue, float flOldValue) { if (force_thirdperson.convar_parent && !force_thirdperson) { - if (g_pLocalPlayer && g_pLocalPlayer->entity) + if (g_pLocalPlayer && CE_GOOD(g_pLocalPlayer->entity)) CE_INT(g_pLocalPlayer->entity, netvar.nForceTauntCam) = 0; } }