I am getting an error that seems to happen after scenes are transitioned many times and the graphs have been scanned each time. We have a dungeon system that generates random floors, so after it’s generated then the Astar is told to scan. After ~10-15 floors it does this error. Is there anything I should be calling before scanning to clean up a previous scan? Or is this caused by something else? Thanks in advance!
NullReferenceException: Object reference not set to an instance of an object
at AstarPath.m__4 (Pathfinding.GraphNode node) [0x00000] in :0
at Pathfinding.GridGraph.GetNodes (Pathfinding.GraphNodeDelegateCancelable del) [0x00000] in :0
at AstarPath.ScanLoop (.OnScanStatus statusCallback) [0x00000] in :0
at AstarPath.Scan () [0x00000] in :0
Hi
Hm… that looks odd. Are you using the latest version of the project?
Also, would it be possible to get a stacktrace with line numbers?
We updated to the latest AStar today. Unfortunately now we have another error that of course with bad luck happened only in a build:
`IndexOutOfRangeException: Array index is out of range.
at Pathfinding.GridNode.Open (Pathfinding.Path path, Pathfinding.PathNode pathNode, Pathfinding.PathHandler handler) [0x00000] in :0
at Pathfinding.ABPath.CalculateStep (Int64 targetTick) [0x00000] in :0
at AstarPath.CalculatePathsThreaded (System.Object _threadInfo) [0x00000] in :0
UnityEngine.Debug:Internal_LogException(Exception, Object)
UnityEngine.Debug:LogException(Exception)
AstarPath:CalculatePathsThreaded(Object)`
I actually had someone test the other day in the editor to try to get the first issue I sent you to happen again. Of course we could not get it in the editor >.<
Hm… interesting.
Do you think it would be possible for you to zip up your project and share it with me so I could test it? That would help a lot in debugging the issue.
Are you doing any kind of graph updates?