From: divverent Date: Fri, 16 Jul 2010 22:24:35 +0000 (+0000) Subject: Use sin() for the the view going up / down. Now it needs to be arranged in a correct... X-Git-Tag: xonotic-v0.1.0preview~230^2~138 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=84cab4b18ddbe692ecdd3ddb889f16c5c5671886;p=xonotic%2Fdarkplaces.git Use sin() for the the view going up / down. Now it needs to be arranged in a correct way. From: MirceaKitsune git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10340 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/view.c b/view.c index 0cd7b478..ce439163 100644 --- a/view.c +++ b/view.c @@ -729,8 +729,8 @@ void V_CalcRefdef (void) if(cl.ground_hit_speed < cl.ground_hit_target) cl.ground_hit_speed += 0.1; // replace 0.1 with cvar - vieworg[2] += cl.ground_hit_speed; - gunorg[2] += cl.ground_hit_speed; + vieworg[2] += sin(M_PI + M_PI * cl.ground_hit_speed * 0.2); + gunorg[2] += sin(M_PI + M_PI * cl.ground_hit_speed * 0.2); } // End of TEST!!!