If you know the current Node (their position) you can get the next nodes position (path_nextnode) and calculate the distance with vec_dist.