From 202c0bc662cde9aea711480c0c1309787615fc83 Mon Sep 17 00:00:00 2001 From: havoc Date: Sun, 30 Mar 2008 10:17:16 +0000 Subject: [PATCH] patch from Blub\0 which adds back the wrapping behavior on pitch when in_pitch_min/max are set to very large values (this basically lets you aim up or down so much that you wrap to the other direction) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8236 d7cf8633-e32d-0410-b094-e92efae38249 --- cl_input.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cl_input.c b/cl_input.c index 711f57e9..c1430ec4 100644 --- a/cl_input.c +++ b/cl_input.c @@ -489,8 +489,11 @@ void CL_AdjustAngles (void) V_StopPitchDrift (); cl.viewangles[YAW] = ANGLEMOD(cl.viewangles[YAW]); + cl.viewangles[PITCH] = ANGLEMOD(cl.viewangles[PITCH]); if (cl.viewangles[YAW] >= 180) cl.viewangles[YAW] -= 360; + if (cl.viewangles[PITCH] >= 180) + cl.viewangles[PITCH] -= 360; cl.viewangles[PITCH] = bound(in_pitch_min.value, cl.viewangles[PITCH], in_pitch_max.value); cl.viewangles[ROLL] = bound(-180, cl.viewangles[ROLL], 180); } -- 2.39.2