change the distance threshold