Bug: Final path getting shortened outside of Recast graph by Raycast Modifier

Hi, so, I’ve migrated to a new version from I’m not sure which previous one, very old I think (3.X?), to now 5.4.6. I’ve had some significant pains migrating but all seems to be sorted now I guess. But one thing I just can’t figure out how to deal with/prevent, hopefully it will be understandable from the screenshot.

On it, you can see the recast graph structure - there are 2 ‘floors’, one higher one lower, connected by a path around. But my character is trying to traverse through a gap between the two ‘floors’ instead. When on Seeker I enable “detailed gizmos”, I can see the found path was around. But the “draw gizmos” (for the actual path) shows the path in green - which leads outside of the recast graph, which is definitely not desirable.


Here is my Seeker component, nothing interesting on it I think:


And here is my RaycastModifier component, which I just now found out causes the issue. It’s supposed to use graph raycasting, but as shown, the resulting path sadly leaves the graph. If I deactivate it, I get the long ziggyzaggy path around, which is ‘more correct’, but obviously it’s too ziggyzaggy to make sense for proper walking.

I wasn’t having this issue with the old version, while using the same components setup.

Hi there, when you can go ahead and post your agent settings and I’ll take a look :+1:

Hi, thanks for the response. But I am not using agents, I am just querying the seeker for a path, which I then follow in my own movement script. That works fine really, just the found path seems to be broken after the ‘raycast optimization’ in cases similar to the one pictured (a 2-floor ground, where you shouldn’t be able to go directly to the lower plane but can).

I simply ask the seeker for:
seeker.StartPath(startPos, targetPos, OnPathFindingComplete);
not even using any custom ending condition for example.

I’ve at least tried fiddling with the “start point snapping” and “end point snapping” on the Seeker but that didn’t seem to affect it. I’m honestly not even sure what else I could provide in regards to my setup as I really just call StartPath here. Maybe something in the main “AstarPath” settings could be of relevance? idk, the nevigation graph (recast in my case) seems fine.