Skip to content

Commit

Permalink
disable parallelism in generatestructuresurfaces to prevent crash for…
Browse files Browse the repository at this point in the history
… now
  • Loading branch information
Modulus32 committed Apr 26, 2024
1 parent 1a2ff61 commit c5d7123
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -224,10 +224,10 @@ public static void PopulateStructureSurfaceBlocks(
public static List<SurfaceTriangle>[] GenerateStructureSurfaceTriangleLists(CollisionGeometry collisionBsp, MeshData meshData)
{
var surfaceTriangleLists = new List<SurfaceTriangle>[collisionBsp.Surfaces.Count];
Parallel.For(0, collisionBsp.Surfaces.Count, surfaceIndex =>
for(var surfaceIndex = 0; surfaceIndex < collisionBsp.Surfaces.Count; surfaceIndex++)
{
surfaceTriangleLists[surfaceIndex] = GenerateSurfaceTrianglesList(collisionBsp, surfaceIndex, meshData);
});
};
return surfaceTriangleLists;
}

Expand Down

0 comments on commit c5d7123

Please sign in to comment.