Closed geopimik closed 7 months ago
I now calculate distance to the goal based on the last waypoint on global path instead of the user placed goal point. (commit 7241322)
Ok.
just an additional comment:
You create a new variable, last_waypoint, but you could use the same goal_point. You need to update the goal_point coordinates as you updated them in the case of last_waypoint. Then, you wouldn't need additional variables. There is no point in keeping the goal_point value as user input because it is not used anywhere. So after preparing the path, we could just update it with new coordinates (using the last waypoint from the path)
Found another issue with your solution. There is a simple fix for it! Currently you just forget to do something in your code!
Situation like this: