added support for changing the tolerance of the pathfinding method