Fixed invalid left/right normal errors during level generation (I think). The voronoi cell generation logic ignored zero-length edges, but it was possible for an edge to be so short that the distance from the adjacent edge to the center of the short edge rounded down to zero in GenerateWallShapes.
This commit is contained in:
@@ -183,7 +183,7 @@ namespace Barotrauma
|
||||
|
||||
foreach (GraphEdge ge in graphEdges)
|
||||
{
|
||||
if (ge.point1 == ge.point2) continue;
|
||||
if (Vector2.DistanceSquared(ge.point1, ge.point2) < 0.001f) continue;
|
||||
|
||||
for (int i = 0; i < 2; i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user