Okay i dont know if its very clear in the image but the navmesh breaks here.
when i place the npc after the split it works fine. how do i join the mesh back together??
Also, its only on this specific part, and its full of cracks. its like every 5 studs or so
The Navigation Mesh doesn’t need to be everywhere, that would be very very costly for performance. It seems like it’s trying to generate in a line from the start to the end with a certain radius, and then failing because the hallway diversions are too long.
Roblox’s NavMesh generation is limited to a 32-stud radius around the pathfinding agent’s position by default. This means if you try to pathfind to or from a location far away from the agent, the NavMesh won’t generate in those distant areas. it’s done for performance reasons.
Placing a bunch of dummy parts around your map each 32 studs from eachother and calculating the NavMesh at their position is a temporary solution:
local dummy = script.Parent
local preloadPath = game.PathfindingService:CreatePath()
preloadPath:ComputeAsync(dummy.Position, dummy.Position)
-- Wait a short time for navmesh to generate
task.wait(1)
dummy:Destroy()