/// <summary> /// SafeOnDestroy should be used when there is a risk that the pathfinding is searching through this graph when called /// </summary> public void SafeOnDestroy() { AstarPath.RegisterSafeNodeUpdate(OnDestroy); }