CHANGE!
CHENGE!
critical fix in maxDist and minor things (typos and such)