Implemented the animation