From cb93560a4ad177f20c3fc6cd4935591b2fcdf127 Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Tue, 4 Aug 2020 13:02:19 +1000 Subject: [PATCH] - fix regression from e474ebc2b75514459ffeace8a1cfd298b9074512 by which the player could adjust their angle on a camera while `cl_syncinput 0` (default) was set. * Issue doesn't occur with `cl_syncinput 1` because `processinput()` returns when p->newowner >= 0 before `applylook()` is called from within it. * Fixes #96. --- source/games/duke/src/input.cpp | 1 + source/games/duke/src/player.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/source/games/duke/src/input.cpp b/source/games/duke/src/input.cpp index 862566231..2888f201f 100644 --- a/source/games/duke/src/input.cpp +++ b/source/games/duke/src/input.cpp @@ -1168,6 +1168,7 @@ static void FinalizeInput(int playerNum, input_t& input, bool vehicle) loc.fvel = loc.svel = 0; loc.q16avel = loc.q16horz = 0; + input.q16avel = input.q16horz = 0; } else { diff --git a/source/games/duke/src/player.cpp b/source/games/duke/src/player.cpp index f79522083..24c81d855 100644 --- a/source/games/duke/src/player.cpp +++ b/source/games/duke/src/player.cpp @@ -1075,6 +1075,7 @@ bool movementBlocked(int snum) p->hard_landing || p->access_incs > 0 || p->knee_incs > 0 || + p->newowner >= 0 || (blockingweapon() && p->kickback_pic > 1 && p->kickback_pic < weapondelay())); }