FINALLY GOT AStar WORKING