- avoid calling the node builder to triangulate degenerate sectors.

This tends to crash.
This commit is contained in:
Christoph Oelckers 2021-08-14 09:48:05 +02:00
parent 9680674dec
commit 5d3f7947bf

View file

@ -463,9 +463,9 @@ bool SectorGeometry::MakeVertices2(unsigned int secnum, int plane, const FVector
nexti:;
}
if (lines.Size() == 0)
if (lines.Size() < 4)
{
// nothing to generate.
// nothing to generate. If line count is < 4 this sector is degenerate and should not be processed further.
auto& entry = data[secnum].planes[plane];
entry.vertices.Clear();
entry.texcoords.Clear();