From 53aac60713da2b6ffe15129d1599b78f7fdbcc1f Mon Sep 17 00:00:00 2001 From: "i.semenov" Date: Fri, 25 Oct 2024 10:21:22 +0300 Subject: [PATCH] Fixed: tiles cache mesh process with off mesh links --- src/DotRecast.Recast.Toolset/Geom/DemoDtTileCacheMeshProcess.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DotRecast.Recast.Toolset/Geom/DemoDtTileCacheMeshProcess.cs b/src/DotRecast.Recast.Toolset/Geom/DemoDtTileCacheMeshProcess.cs index 87818d1..619a5b0 100644 --- a/src/DotRecast.Recast.Toolset/Geom/DemoDtTileCacheMeshProcess.cs +++ b/src/DotRecast.Recast.Toolset/Geom/DemoDtTileCacheMeshProcess.cs @@ -46,13 +46,13 @@ namespace DotRecast.Recast.Toolset.Geom if (null != _geom) { var offMeshConnections = _geom.GetOffMeshConnections(); + option.offMeshConCount = offMeshConnections.Count; option.offMeshConVerts = new float[option.offMeshConCount * 6]; option.offMeshConRad = new float[option.offMeshConCount]; option.offMeshConDir = new int[option.offMeshConCount]; option.offMeshConAreas = new int[option.offMeshConCount]; option.offMeshConFlags = new int[option.offMeshConCount]; option.offMeshConUserID = new int[option.offMeshConCount]; - option.offMeshConCount = offMeshConnections.Count; for (int i = 0; i < option.offMeshConCount; i++) { RcOffMeshConnection offMeshCon = offMeshConnections[i];