Pathfinding when everyting is shifting in world coordinates

Hi, there. I’m creating an augmented reality app and am looking for a pathfinding solution that can handle a constantly moving ground plane. It is a plane, so from a certain perspective, the problem is exactly the same as if the ground was stationary, except the plane is moving around in world coordinates. The ground plane will often be moving many 10+ a second, as the camera moves and from noise in the computer vision.

Unity’s NavMesh would work if I go through a difficult (for my skillset) and project-complicating refactor to make the camera move while keeping the ground plane fixed.

I’m wondering though, whether this Asset would provide a solution to my specific problem. The 10+ ground plane changes per second rules out “Graph Updates during Runtime”, if my conclusions from skimming are correct.

Would you suggest I use this Asset for this problem? If so, can you point me toward the appropriate functionality?

Thanks!

Hi

The best way is actually to cheat and not move the graph at all.
Instead your movement script would keep track of the relative coordinates it has to the graph and convert to and from that when it needs to follow the path or request a new path. The graph stays at the world origin regardless of how the ground plane moves. (the best approach is of course to refactor your project so that the camera moves instead, but this might be a good compromise).

In the pro version there is an example scene called ‘Moving’ which shows how to configure such a scenario with the RichAI movement script. There is no built in script for the AIPath movement script, but it should be relatively easy to use the exact same approach there.

Aron, thanks so much for your thoughtful reply.

I did end up spending Monday refactoring to keep the ground fixed and move the camera instead. So Unity’s navmesh fills our needs for now, but I might later buy your Asset to get access to fleeing and aimed random paths.