From e3503670d1e4a0a92380361070a358355f6adc7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20Mat=C4=9Bjka?= Date: Tue, 16 Feb 2016 21:04:34 +0100 Subject: [PATCH] SV_StudioSetupBones fix for non-players --- regamedll/dlls/animation.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/regamedll/dlls/animation.cpp b/regamedll/dlls/animation.cpp index 5599975c..59ec78ca 100644 --- a/regamedll/dlls/animation.cpp +++ b/regamedll/dlls/animation.cpp @@ -1215,7 +1215,11 @@ void SV_StudioSetupBones(model_t *pModel, float frame, int sequence, const vec_t VectorCopy(angles, temp_angles); - if (pEdict != NULL) +#ifdef REGAMEDLL_FIXES + if(pEdict != NULL && CBaseEntity::Instance((edict_t*)pEdict)->IsPlayer()) +#else + if(pEdict != NULL) +#endif { temp_angles[1] = UTIL_GetPlayerGaitYaw(ENTINDEX(pEdict));