forked from mirror/DotRecast
fix: Support non-tiled dynamic nav meshes (@ppiastucki)
[Upstream] from recast4j - fe071aa - fix: Support non-tiled dynamic nav meshes (#205)
This commit is contained in:
parent
2d0e2f8525
commit
85e2484505
|
@ -14,6 +14,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
|||
- Fix raycast shortcuts ([@Sarofc](https://github.com/Sarofc)) [#72](https://github.com/ikpil/DotRecast/issues/72)
|
||||
- Fix dynamic mesh bounds calculation ([@ppiastucki](https://github.com/ppiastucki)) [#77](https://github.com/ikpil/DotRecast/issues/77)
|
||||
- issuer : [@OhJeongrok](https://github.com/OhJeongrok)
|
||||
- Fix Support non-tiled dynamic nav meshes ([@ppiastucki](https://github.com/ppiastucki))
|
||||
|
||||
### Changed
|
||||
- Changed data structure of 'neis' from List<byte> to byte[] for optimized memory usage and improved access speed in `DtLayerMonotoneRegion`
|
||||
|
|
|
@ -62,8 +62,8 @@ namespace DotRecast.Detour.Dynamic
|
|||
navMeshParams.orig.X = voxelFile.bounds[0];
|
||||
navMeshParams.orig.Y = voxelFile.bounds[1];
|
||||
navMeshParams.orig.Z = voxelFile.bounds[2];
|
||||
navMeshParams.tileWidth = voxelFile.cellSize * voxelFile.tileSizeX;
|
||||
navMeshParams.tileHeight = voxelFile.cellSize * voxelFile.tileSizeZ;
|
||||
navMeshParams.tileWidth = voxelFile.useTiles ? voxelFile.cellSize * voxelFile.tileSizeX : voxelFile.bounds[3] - voxelFile.bounds[0];
|
||||
navMeshParams.tileHeight = voxelFile.useTiles ? voxelFile.cellSize * voxelFile.tileSizeZ: voxelFile.bounds[5] - voxelFile.bounds[2];
|
||||
navMeshParams.maxTiles = voxelFile.tiles.Count;
|
||||
navMeshParams.maxPolys = 0x8000;
|
||||
foreach (var t in voxelFile.tiles)
|
||||
|
|
Loading…
Reference in New Issue