Hi Aron, the above solution worked for the problem I had, unfortunately right now i’m digging in a deep rabbit hole in my project, facing one problem after another so I’m going to explain what I want to accomplish so you can help me better:
In my game the player will be navigating through the ocean from one island to another, so, in each Island there will be animals that will have AI walking on them. Here it is a little screen so you would have a better understanding
There are two cases when I have to update the graph:
Case 1 Docking in a new island:
The player would be navigating, the when he reaches the “Dock” I will calculate the new bounds of the graph, based on the player position etc…
In that moment I can do a trasition, fading the scen to black, there I Update the graph via:
var guo = new GraphUpdateObject(new Bounds(Singleton.Instance.CharacterController.transform.position,bound_island)); guo.updatePhysics = true; AstarPath.active.UpdateGraphs(guo);
The problem I’m having there is that even I’ve updated the bounds of the graph it won’t create new connections out of the previous graph calculated in the previous bound.
Even I have this moment of transition when I can call your function of “Scan” sometimes it will take around 5-10 seconds to recalculate all the new island so is not viable to do it that way.
Case 2 Walking From One Island to another:
The player walks through the bridge I detect is a new island and Update according to the bounds of the new island, the problem here is that I don’t have any kind of trasition to ReScan the whole island. Here I have the same problem, I can Update the graph with the new Bounds, but is not going to add new connections or tiles to the graph.
Here I have some screenshots so you can tell me if I’m doing something wrong.
Maybe is a problem too general, not really related only with the code more about how to create a valid WorkFlow , so maybe if you can give me some ideas.
I have been reading a lot of stuff in the forum but I couldn’t find any solution. We are working on the Pro version and the current version that we are is 3.8.2
Thanks again for the support I hope we find a solution togheter