mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
make FindPlane much pickier about matching planes
This commit is contained in:
parent
415fae8d6b
commit
4c52975584
1 changed files with 5 additions and 0 deletions
|
@ -224,8 +224,13 @@ FindPlane (plane_t *dplane, int *side)
|
|||
|
||||
dp = planes;
|
||||
for (i = 0; i < numbrushplanes; i++, dp++) {
|
||||
vec3_t t;
|
||||
VectorSubtract (dp->normal, pl.normal, t);
|
||||
dot = DotProduct (dp->normal, pl.normal);
|
||||
if (dot > 1.0 - ANGLEEPSILON
|
||||
&& fabs(t[0]) < DISTEPSILON * DISTEPSILON
|
||||
&& fabs(t[1]) < DISTEPSILON * DISTEPSILON
|
||||
&& fabs(t[2]) < DISTEPSILON * DISTEPSILON
|
||||
&& fabs(dp->dist - pl.dist) < DISTEPSILON) { // regular match
|
||||
return i;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue