Got the distance part to be working