diff --git a/src/naveditor/Editor_TileMesh.cpp b/src/naveditor/Editor_TileMesh.cpp index dd928e9e..e85f801b 100644 --- a/src/naveditor/Editor_TileMesh.cpp +++ b/src/naveditor/Editor_TileMesh.cpp @@ -447,7 +447,9 @@ bool Editor_TileMesh::handleBuild() params.polyGroupCount = 0; params.traversalTableSize = 0; params.traversalTableCount = NavMesh_GetTraversalTableCountForNavMeshType(m_selectedNavMeshType); +#if DT_NAVMESH_SET_VERSION >= 8 params.magicDataCount = 0; +#endif dtStatus status; diff --git a/src/thirdparty/recast/DebugUtils/Source/DetourDebugDraw.cpp b/src/thirdparty/recast/DebugUtils/Source/DetourDebugDraw.cpp index 83d81065..d5d6a10c 100644 --- a/src/thirdparty/recast/DebugUtils/Source/DetourDebugDraw.cpp +++ b/src/thirdparty/recast/DebugUtils/Source/DetourDebugDraw.cpp @@ -202,6 +202,10 @@ static void drawTileCells(duDebugDraw* dd, const dtMeshTile* tile, const float* const dtCell& probe = tile->cells[i]; duDebugDrawCross(dd, probe.pos[0], probe.pos[1], probe.pos[2], 25.f, duRGBA(255,0,0,255), 2, offset); } +#else + rdIgnoreUnused(dd); + rdIgnoreUnused(tile); + rdIgnoreUnused(offset); #endif } diff --git a/src/thirdparty/recast/Detour/Include/DetourNavMesh.h b/src/thirdparty/recast/Detour/Include/DetourNavMesh.h index 88b06271..ad4c332a 100644 --- a/src/thirdparty/recast/Detour/Include/DetourNavMesh.h +++ b/src/thirdparty/recast/Detour/Include/DetourNavMesh.h @@ -24,7 +24,7 @@ // NOTE: these are defines as we need to be able to switch between code that is // dedicated for each version, during compile time. -#define DT_NAVMESH_SET_VERSION 9 // Public versions: 5,7,8,9. +#define DT_NAVMESH_SET_VERSION 8 // Public versions: 5,7,8,9. #define DT_NAVMESH_SET_MAGIC ('M'<<24 | 'S'<<16 | 'E'<<8 | 'T') int dtGetNavMeshVersionForSet(const int setVersion); @@ -395,7 +395,9 @@ struct dtMeshHeader int bvNodeCount; ///< The number of bounding volume nodes. (Zero if bounding volumes are disabled.) int offMeshConCount; ///< The number of off-mesh connections. int offMeshBase; ///< The index of the first polygon which is an off-mesh connection. +#if DT_NAVMESH_SET_VERSION >= 8 int maxCellCount; ///< The number of allocated cells. +#endif float walkableHeight; ///< The height of the agents using the tile. float walkableRadius; ///< The radius of the agents using the tile. diff --git a/src/thirdparty/recast/Detour/Source/DetourNavMesh.cpp b/src/thirdparty/recast/Detour/Source/DetourNavMesh.cpp index c120caa2..f071edfc 100644 --- a/src/thirdparty/recast/Detour/Source/DetourNavMesh.cpp +++ b/src/thirdparty/recast/Detour/Source/DetourNavMesh.cpp @@ -315,7 +315,9 @@ dtStatus dtNavMesh::init(unsigned char* data, const int dataSize, const int tabl params.polyGroupCount = 0; params.traversalTableSize = 0; params.traversalTableCount = tableCount; +#if DT_NAVMESH_SET_VERSION >= 7 params.magicDataCount = 0; +#endif dtStatus status = init(¶ms); if (dtStatusFailed(status))