shortened animation, also made it depend on distance