added code for easing