What kind of workflow happening actually? I mean, let’s think about Ram. It’s making its decisions step by step, or it’s find the best way first, and then moving?
If it’s moving step by step; After K, because of L is available to move, it should move to L and then M.
Instructor said that with this priority order, gameobject could go J to C. Is that mean, with that pathfinding method decisions make first and then movements occur? I just need to verify this
Since the goal is to reach the target, the algorithm cannot know after one step which is the “best” path. The “best” path can only be evaluated if there are other paths for comparison. We don’t save any paths, though, and do not compare anything. Also, we didn’t define “best”.
The algorithm “moves” step by step along the branches in the tree, jumps from node to node and stops if it reached the target (here: C).
There is a nice gif on Wikipedia, which visualises why the found path is the shortest: