A* Pathfinding Algorithm in Python with Pygame