update Astar implementation