Use vectors to store offmesh connection data rather than arrays

This commit is contained in:
Graham Pentheny
2025-08-25 12:08:48 -04:00
parent 30d459ca73
commit 8de2dcef5f
6 changed files with 86 additions and 88 deletions

View File

@@ -463,13 +463,13 @@ struct MeshProcess : dtTileCacheMeshProcess
// Pass in off-mesh connections.
if (inputGeometry)
{
params->offMeshConVerts = inputGeometry->offMeshConVerts;
params->offMeshConRad = inputGeometry->offMeshConRads;
params->offMeshConDir = inputGeometry->offMeshConDirs;
params->offMeshConAreas = inputGeometry->offMeshConAreas;
params->offMeshConFlags = inputGeometry->offMeshConFlags;
params->offMeshConUserID = inputGeometry->offMeshConId;
params->offMeshConCount = inputGeometry->offMeshConCount;
params->offMeshConVerts = inputGeometry->offmeshConnVerts.data();
params->offMeshConRad = inputGeometry->offmeshConnRadius.data();
params->offMeshConDir = inputGeometry->offmeshConnBidirectional.data();
params->offMeshConAreas = inputGeometry->offmeshConnArea.data();
params->offMeshConFlags = inputGeometry->offmeshConnFlags.data();
params->offMeshConUserID = inputGeometry->offmeshConnId.data();
params->offMeshConCount = static_cast<int>(inputGeometry->offmeshConnArea.size());
}
}
};