Added the betterDistance heuristic

It doesn't actually make it any faster