qbsp: skip only the face, not brush for degenerate normals
The previous code would possibly leak faces with weird effects if we iterate over the face data e.g. 0 -> map.numfaces. Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
This commit is contained in:
parent
0ff1446df3
commit
a9dd2de5ec
|
|
@ -399,7 +399,7 @@ ParseBrush(mapbrush_t *brush)
|
||||||
CrossProduct(t1, t2, plane->normal);
|
CrossProduct(t1, t2, plane->normal);
|
||||||
if (VectorCompare(plane->normal, vec3_origin)) {
|
if (VectorCompare(plane->normal, vec3_origin)) {
|
||||||
Message(msgWarning, warnNoPlaneNormal, linenum);
|
Message(msgWarning, warnNoPlaneNormal, linenum);
|
||||||
break;
|
continue;
|
||||||
}
|
}
|
||||||
VectorNormalize(plane->normal);
|
VectorNormalize(plane->normal);
|
||||||
plane->dist = DotProduct(t3, plane->normal);
|
plane->dist = DotProduct(t3, plane->normal);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue