From 77becb7ac1867f4ec0c314800dd127ca58654dc3 Mon Sep 17 00:00:00 2001 From: Bucky Date: Sat, 16 May 2020 18:51:50 -0600 Subject: [PATCH] fix crash that didn't exist when i pushed this feature --- codemp/game/bg_panimate.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/codemp/game/bg_panimate.c b/codemp/game/bg_panimate.c index 60a7a3d02e..745c776575 100644 --- a/codemp/game/bg_panimate.c +++ b/codemp/game/bg_panimate.c @@ -2694,7 +2694,7 @@ void PM_SetTorsoAnimTimer(int time ) void BG_SaberStartTransAnim( int clientNum, int saberAnimLevel, int weapon, int anim, float *animSpeed, int broken ) { - if (JK2SWINGS(pm->ps)) { + if (pm && JK2SWINGS(pm->ps)) { if (((anim) >= BOTH_T1_BR__R && (anim) <= BOTH_T1_BL_TL) || ((anim) >= BOTH_T2_BR__R && (anim) <= BOTH_T2_BL_TL) || ((anim) >= BOTH_T3_BR__R && (anim) <= BOTH_T3_BL_TL)) @@ -2831,9 +2831,9 @@ void BG_SetAnimFinal(playerState_t *ps, animation_t *animations, ps->torsoTimer /= 1.7; } - if (JK2SWINGS(pm->ps) && editAnimSpeed) + if (JK2SWINGS(ps) && editAnimSpeed) { - pm->ps->torsoTimer /= editAnimSpeed; + ps->torsoTimer /= editAnimSpeed; } } }