From 1b0208e3e8038a233fa87be16a79e861a0b66030 Mon Sep 17 00:00:00 2001 From: Christopher Schwarz Date: Sat, 3 Oct 2009 12:33:08 +0000 Subject: * (bug 3734) Prevent exploitative use of roll axis by hacked clients (DevHC) --- src/game/bg_pmove.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/game') diff --git a/src/game/bg_pmove.c b/src/game/bg_pmove.c index 9ba34a85..52afe2b2 100644 --- a/src/game/bg_pmove.c +++ b/src/game/bg_pmove.c @@ -3495,7 +3495,10 @@ void PM_UpdateViewAngles( playerState_t *ps, const usercmd_t *cmd ) // circularly clamp the angles with deltas for( i = 0; i < 3; i++ ) { - temp[ i ] = cmd->angles[ i ] + ps->delta_angles[ i ]; + if( i != ROLL ) + temp[ i ] = cmd->angles[ i ] + ps->delta_angles[ i ]; + else // currently, nothing can roll + temp[ i ] = ps->delta_angles[ i ]; if( i == PITCH ) { -- cgit