From 285f6e6ca886dc452f2eee3867e0b0254b79ab90 Mon Sep 17 00:00:00 2001 From: TimeServ Date: Tue, 27 Jun 2006 22:35:11 +0000 Subject: [PATCH] match ZQuake's pmove git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2336 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/common/pmove.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/engine/common/pmove.c b/engine/common/pmove.c index 7940830a0..b525c5d60 100644 --- a/engine/common/pmove.c +++ b/engine/common/pmove.c @@ -248,6 +248,7 @@ int PM_StepSlideMove (qboolean in_air) vec3_t original, originalvel, down, up, downvel; float downdist, updist; int blocked; + float stepsize; // try sliding forward both on ground and up 16 pixels // take the move that goes farthest @@ -259,8 +260,6 @@ int PM_StepSlideMove (qboolean in_air) if (!blocked) return blocked; // moved the entire distance -#if 0 - // disable this until I clear this up with Tonik or someone if (in_air) { // don't let us step up unless it's indeed a step we bumped in @@ -283,7 +282,6 @@ int PM_StepSlideMove (qboolean in_air) } else stepsize = pm_stepheight; -#endif VectorCopy (pmove.origin, down); VectorCopy (pmove.velocity, downvel); @@ -293,7 +291,7 @@ int PM_StepSlideMove (qboolean in_air) // move up a stair height VectorCopy (pmove.origin, dest); - dest[2] += pm_stepheight; + dest[2] += stepsize; trace = PM_PlayerTrace (pmove.origin, dest); if (!trace.startsolid && !trace.allsolid) { @@ -304,7 +302,7 @@ int PM_StepSlideMove (qboolean in_air) // press down the stepheight VectorCopy (pmove.origin, dest); - dest[2] -= pm_stepheight; + dest[2] -= stepsize; trace = PM_PlayerTrace (pmove.origin, dest); if (trace.fraction != 1 && trace.plane.normal[2] < MIN_STEP_NORMAL) goto usedown;