added timer for animation