sbox-issues icon indicating copy to clipboard operation
sbox-issues copied to clipboard

[Terrain] Nav mesh has artifacts & nav agents can't move

Open AnthonyPython opened this issue 1 year ago • 4 comments

Describe the bug

Terrain's can generate navmesh with height but there is artifacts caused by it and nav agents absolutely refuse to use it despite a new navmesh is made.

To Reproduce

create a new terrain import a height map nav mesh will generate look at navmesh place a nav agent down

Expected behavior

Terrain nav mesh should not have artifacts and nav agents should be-able to navigate with said navmesh

Media/Files

image

Additional context

No response

AnthonyPython avatar Aug 16 '24 04:08 AnthonyPython

Is there any relation to this issue when it comes to NavAgent movement? https://github.com/Facepunch/sbox-issues/issues/5878

Do they refuse to move, or can you not make valid paths/get valid points, so they can't move due to not having a path?

MD485 avatar Aug 16 '24 04:08 MD485

Is there any relation to this issue when it comes to NavAgent movement? #5878

Do they refuse to move, or can you not make valid paths/get valid points, so they can't move due to not having a path?

I just tested it and it is indeed related to no valid paths so they can't move. I never get any points for a path.

AnthonyPython avatar Aug 16 '24 04:08 AnthonyPython

Update I was able to get a couple points at least one time, but the nav agent still fails, despite simple path returning a couple of points am not sure what exactly is going on but it appears nav agents are broken with terrain navmesh in general.

AnthonyPython avatar Aug 16 '24 06:08 AnthonyPython

More info it seems this is more of a general problem with navmesh generation on large meshes I got the same result using a large .vmap and it also created these artifacts, and it seems the navmesh having these artifacts is causing problems for nav agents. image

navmesh_problem.zip

AnthonyPython avatar Aug 17 '24 08:08 AnthonyPython

Should be fixed. Tested the provided .vmap, the navmesh is now correctly generated. It should also work for terrain. Let us know if the issue persists.

lolleko avatar Nov 13 '24 20:11 lolleko