I am using the “moveable graph” concept, using LocalSpaceRichAI and Localspace graph. This works fine when I scan the initial graph.
However, I want to be able to generate the graph out of view of the player, then move the geometry and the graph into view when it has finished loading.
So, I am doing this, from the documentation:
var graph = citygraph;// AstarPath.data.recastGraph; graph.forcedBoundsCenter = cityworldobj.transform.position; var transform = graph.CalculateTransform(); graph.RelocateNodes(transform);
This seems to work fine, I can see that the graph has moved and is in the correct position, the AI also spawn on the graph, and everything seems ok, except that the AI don’t move, and there are no green and blue lines that indicate that a path has been calculated.
I have tried removing/readding the Localspacerich AI graphs, and modifying any settings that I can find, but the AI just won’t move or generate graphs.
This, like I said, works fine when I don’t move the graph.
Is there something else that I need to do after I call Relocate nodes?