Refactor pathfinding into separate class