![]() |
Attention | Topic was automatically imported from the old Question2Answer platform. |
![]() |
Asked By | MikeyZman |
Hi All, thanks in advance for any help. How can I troubleshoot the following code where I am getting seemingly valid numbers for closest_end_point and closest_start_point and stone_graph? path returns null for some reason.
the upstream values that lead to closest_start_point , closest_end_point and stone_graph all seem good coming in. and the returns from the print statements (troubleshooting) are:
11 (closest_end_point)
62 (closest_start_point)
[AStar:1213] (stone_graph is generated with an AStar call.
(path return, which is null and blowing up my program…)
anyone got any ideas how I can troubleshoot?
var closest_start_point = stone_graph.get_closest_point(start_position)
var closest_end_point = stone_graph.get_closest_point(end_position)
print (closest_end_point)
print (closest_start_point)
print(stone_graph)
var path = stone_graph.get_point_path(closest_start_point, closest_end_point)
print(path)
Here is where stone_graph is generated in a higher function that calls the code above’s function:
var stone_graph = AStar.new()