From 009508fa8baf3f46667a9801c024d0fa19a5f1d9 Mon Sep 17 00:00:00 2001 From: Marco Hladik Date: Mon, 10 May 2021 12:24:53 +0200 Subject: [PATCH] Update Animation_TimerUpdate to conform with upstream Nuclide. --- src/shared/animations.qc | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/shared/animations.qc b/src/shared/animations.qc index f2e8bfe..01ba26e 100755 --- a/src/shared/animations.qc +++ b/src/shared/animations.qc @@ -36,25 +36,24 @@ void Animation_Print(string sWow) { print(sprintf("[DEBUG] %s", sWow)); #else bprint(PRINT_HIGH, sprintf("SSQC: %s", sWow) ); -#endif +#endif } void -Animation_TimerUpdate(player pl) +Animation_TimerUpdate(player pl, float ftime) { makevectors([0, pl.angles[1], 0]); /* top animation is always just being incremented */ - pl.anim_top_time += input_timelength; - pl.anim_top_delay -= input_timelength; + pl.anim_top_time += ftime; + pl.anim_top_delay -= ftime; /* we may be walking backwards, thus decrement bottom */ if (dotproduct(pl.velocity, v_forward) < 0) { - pl.anim_bottom_time -= input_timelength; + pl.anim_bottom_time -= ftime; } else { - pl.anim_bottom_time += input_timelength; - } -} + pl.anim_bottom_time += ftime; + /* =================