Closed YannBurrett closed 2 years ago
Just to make sure: does waiting a frame before invoking get_simple_path
result in a proper path?
For some reason github didn't let me know there was areply to this...
It doesn't seem to.
Giving this a bump as this effects me as well.
Can anyone still reproduce this bug in Godot 3.2.3 or any later release?
If yes, please ensure that an up-to-date Minimal Reproduction Project (MRP) is included in this report (a MRP is a zipped Godot project with the minimal elements necessary to reliably trigger the bug). You can upload ZIP files in an issue comment with a drag and drop.
This issue is still valid for both Godot 4.0 and 3.5. The GridMap navmesh is broken in both versions. Some are GridMap bugs while others boil down to used navmesh being wrong for the NavigationMesh properties that control the merge on the NavigationServer.
With #61170 merged it is possible to (re)bake a working navmesh inside the Editor that fits and merges well with grids but the GridMap Node needs even more fixes.
Godot version: 3.1 Stable
OS/device including version: Windows 10 64bit Version 10.0.17763 Build 17763
Mint 19
Issue description: My project involves a gridmap that procedurally generates a level on loading. All tiles have appropriate navmeshes attached (all of which align correctly).
Using get_simple_path() does not take the generated map into account. Instead, it uses whatever was on the level before it was run. That is, if I paint some grids on the map, those will be what Navigation uses for get_simple_path().
This can be reproduced in a number of ways - if I clear() the gridmap before running the procgen script, get_simple_path() returns an empty array.
The expected behaviour would be that the navmeshes are rebaked when the gridmap changes, but there appears to be no function to do this.
Steps to reproduce: