This is the testing Godot forums! All forum posts unique to this forum will be deleted! Please use the main forums here for any posts you want to keep. All forum rules still apply.

NavigationMeshInstance tutorial

MagramMagram Posts: 1Member

Hi,
I'm trying to learn how to use NavigationMeshInstance to implement a click-to-move functionnality to my game.
The problem is, whatever I try, it doesn't work as I want it to.

I added to whole project on this post since it's very small.

Here are the issues I'm trying to fix:

1- When the player moves, it sinks in the ground.

2- Movement ignores collision. I know I can fix this one by altering the NavigationMeshInstance so it doesn't go into obstacles, but I don't know how to do that.

3- I am unable to add multiple NavigationMeshInstance to the click-to-move algorithm. In my project, there is a floor, a slope, and a platform but only the floor's NavigationMeshInstance is taken into account.

I tried looking for a tutorial online.
The only thing I found is the navmesh demo on github, which I drew heavy inspiration from to make what I currently have. But it's only a demo, it doesn't explain anything.

I also know I could create all the stuff I need in Blender then import it in Godot, but since I don't know how to use Blender I'd rather learn how to do navigation directly in Godot.

Thanks !

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.