]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - collision.c
Fix a bug in collisions between brushes and brushes when the plane is rotating -...
[xonotic/darkplaces.git] / collision.c
index 827200efa4c8e21c0c1ff4c20193ad3fdbd44403..c9cfc976ebb6760d1c56bcf43fdcf9f143fd4e23 100644 (file)
@@ -646,7 +646,7 @@ void Collision_TraceBrushBrushFloat(trace_t *trace, const colbrushf_t *trace_sta
                        VectorNormalize(endplane);
                }
                startplane[3] = furthestplanedist_float(startplane, other_start->points, othernumpoints);
-               endplane[3] = furthestplanedist_float(startplane, other_end->points, othernumpoints);
+               endplane[3] = furthestplanedist_float(endplane, other_end->points, othernumpoints);
                startdist = nearestplanedist_float(startplane, trace_start->points, tracenumpoints) - startplane[3];
                enddist = nearestplanedist_float(endplane, trace_end->points, tracenumpoints) - endplane[3];
                //Con_Printf("%c%i: startdist = %f, enddist = %f, startdist / (startdist - enddist) = %f\n", nplane2 != nplane ? 'b' : 'a', nplane2, startdist, enddist, startdist / (startdist - enddist));