From: Mario Date: Thu, 9 Jul 2015 02:13:42 +0000 (+1000) Subject: Add a hack to fix jumping prediction with the engine's version of physics, also defau... X-Git-Tag: xonotic-v0.8.1~38^2~3 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=59512cd94fe540bbfe0581094d070627bfc4de36;p=xonotic%2Fxonotic-data.pk3dir.git Add a hack to fix jumping prediction with the engine's version of physics, also default to QC physics --- diff --git a/qcsrc/csqcmodellib/cl_player.qc b/qcsrc/csqcmodellib/cl_player.qc index 12ffe5b2f..436052767 100644 --- a/qcsrc/csqcmodellib/cl_player.qc +++ b/qcsrc/csqcmodellib/cl_player.qc @@ -135,12 +135,23 @@ void CSQCPlayer_SavePrediction() void CSQC_ClientMovement_PlayerMove_Frame(); +void PM_Movement_Move() +{ + runstandardplayerphysics(self); +#ifdef CSQC + self.flags = + ((self.pmove_flags & PMF_DUCKED) ? FL_DUCKED : 0) | + (!(self.pmove_flags & PMF_JUMP_HELD) ? FL_JUMPRELEASED : 0) | + ((self.pmove_flags & PMF_ONGROUND) ? FL_ONGROUND : 0); +#endif +} + void CSQCPlayer_Physics(void) { switch(autocvar_cl_movement) { - case 1: runstandardplayerphysics(self); break; - case 2: CSQC_ClientMovement_PlayerMove_Frame(); break; + case 1: CSQC_ClientMovement_PlayerMove_Frame(); break; + case 2: PM_Movement_Move(); break; } }