updating slider during animation