Added priority tie-breaking when inserting entries to priority queue;
Added the ability to check if a new node is already in the closed or the open list(removing an inadequate entry if needed)