i have designed a level when i cross a threshold it loads in a new AStarPool object and meshes etc and unloads the old AStarPool and the game continues, when i go back to the first area i get an error....
When i leave the first level i disable all the AI objects and i try and clean them up like this:
Debug.Log(this.gameObject.name + " : script was disabled");
if (path != null) path.Release(this);
path = null;
i get this error after afew seconds of going back onto the 1st AStar terrain:
ArgumentException: You are releasing a path which has not been claimed with this object (A__056 (AstarPath)). Are you releasing the path with the same object twice?
Q1) is it possible to clear the path pool of all paths ?
Q2) i noted that AStarDebugger says Pool Sizes (size/total created) ABPath 1/3. Even after i have moved onto the new AStar - does that mean i am missing a path release or my OnDisable() is not working ?