diff --git a/src/shared/pmove_custom.qc b/src/shared/pmove_custom.qc index a6396ec9..af8d148f 100644 --- a/src/shared/pmove_custom.qc +++ b/src/shared/pmove_custom.qc @@ -603,6 +603,7 @@ PMoveCustom_Move(void) self.groundentity = trace_ent; } } +#endif /* this is called for when we want to run the custom QC player physics */ void @@ -617,19 +618,26 @@ PMoveCustom_RunPlayerPhysics(entity target) if (self.maxspeed <= 0) self.maxspeed = 240; +#ifdef CUSTOMPLAYERPHYSICS /* call accelerate before and after the actual move, * with half the move each time. this reduces framerate dependence. * and makes controlling jumps slightly easier */ PMoveCustom_Acceleration(input_timelength / 2, TRUE); PMoveCustom_Move(); PMoveCustom_Acceleration(input_timelength / 2, FALSE); +#else + runstandardplayerphysics(target); +#endif /* NOTE: should clip to network precision here if lower than a float */ self.angles = input_angles; self.angles[0] *= -0.333; +#ifdef CUSTOMPLAYERPHYSICS /* activate any SOLID_TRIGGER entities */ touchtriggers(); +#endif + setorigin(self, self.origin); self = oldself; } @@ -673,5 +681,4 @@ PMoveCustom_RunCrouchPhysics(entity target) target.view_ofs = PHY_VIEWPOS; } PMoveCustom_RunPlayerPhysics(target); -} -#endif +} \ No newline at end of file