From 38d5490ae230b844b44996c87a4900ac640450b4 Mon Sep 17 00:00:00 2001 From: havoc Date: Tue, 13 May 2014 22:13:15 +0000 Subject: [PATCH] Changed the collision code used by sv_gameplayfix_nudgeoutofsolid to not consider collision_impactnudge as that is already taken care of by the caller, and the way it was being done would typically reject such collisions anyway. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12076 d7cf8633-e32d-0410-b094-e92efae38249 ::stable-branch::merge=89983a6142ccbec1cfd3690fa55979bbdaf3b8f1 --- collision.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/collision.c b/collision.c index 11e4a865..2c4cec65 100644 --- a/collision.c +++ b/collision.c @@ -649,7 +649,7 @@ void Collision_TraceBrushBrushFloat(trace_t *trace, const colbrushf_t *trace_sta //Con_Printf("%c%i: startdist = %f, enddist = %f, startdist / (startdist - enddist) = %f\n", nplane2 != nplane ? 'b' : 'a', nplane2, startdist, enddist, startdist / (startdist - enddist)); // aside from collisions, this is also used for error correction - if (startdist <= collision_impactnudge.value && nplane < numplanes1 && (startdepth < startdist || startdepth == 1)) + if (startdist <= 0.0f && nplane < numplanes1 && (startdepth < startdist || startdepth == 1)) { startdepth = startdist; VectorCopy(startplane, startdepthnormal); @@ -814,7 +814,7 @@ void Collision_TraceLineBrushFloat(trace_t *trace, const vec3_t linestart, const //Con_Printf("%c%i: startdist = %f, enddist = %f, startdist / (startdist - enddist) = %f\n", nplane2 != nplane ? 'b' : 'a', nplane2, startdist, enddist, startdist / (startdist - enddist)); // aside from collisions, this is also used for error correction - if (startdist < collision_impactnudge.value && (startdepth < startdist || startdepth == 1)) + if (startdist <= 0.0f && (startdepth < startdist || startdepth == 1)) { startdepth = startdist; VectorCopy(startplane, startdepthnormal); -- 2.39.2