From db6d2e4d892f262874fc2d14358a543457dd8fa0 Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Mon, 10 Aug 2020 22:04:40 +1000 Subject: [PATCH] - fix `cl_viewbob()` for Blood. Fixes #134. --- source/blood/src/view.cpp | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/source/blood/src/view.cpp b/source/blood/src/view.cpp index 55f8f05d7..aa7305b3c 100644 --- a/source/blood/src/view.cpp +++ b/source/blood/src/view.cpp @@ -835,14 +835,17 @@ void viewDrawScreen(bool sceneonly) q16horiz += fix16_from_int(mulscale30(0x40000000 - Cos(gView->tiltEffect << 2), 30)); if (gViewPos == 0) { - if (cl_viewhbob) + if (cl_viewbob) { - cX -= mulscale30(v74, Sin(fix16_to_int(cA))) >> 4; - cY += mulscale30(v74, Cos(fix16_to_int(cA))) >> 4; - } - if (cl_viewvbob) - { - cZ += v8c; + if (cl_viewhbob) + { + cX -= mulscale30(v74, Sin(fix16_to_int(cA))) >> 4; + cY += mulscale30(v74, Cos(fix16_to_int(cA))) >> 4; + } + if (cl_viewvbob) + { + cZ += v8c; + } } if (cl_slopetilting) {