1
0
Fork 0
forked from fte/fteqw

match ZQuake's pmove

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2336 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
TimeServ 2006-06-27 22:35:11 +00:00
parent 725912224d
commit 285f6e6ca8

View file

@ -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;