Esempio n. 1
0
        /// <summary>
        /// Removes an <see cref="AnimatorBase"/> which acts as a child of this instance.
        /// </summary>
        /// <param name="animator">Child to be removed.</param>
        protected void RemoveChildAnimator(AnimatorBase animator)
        {
            if (animator == null)
                throw new ArgumentNullException("animator");

            if (_childAnimators.Contains(animator))
                _childAnimators.Remove(animator);
        }
Esempio n. 2
0
        /// <summary>
        /// Adds an <see cref="AnimatorBase"/> which acts as a child of this instance.
        /// Thus its <see cref="Intervall"/>, <see cref="StepSize"/>, <see cref="LoopMode"/>
        /// and <see cref="SynchronizationMode"/> will be set accordingly to and synchronized 
        /// with the settings of this instance.
        /// </summary>
        /// <param name="animator">Child to add.</param>
        protected void AddChildAnimator(AnimatorBase animator)
        {
            if (animator == null)
                throw new ArgumentNullException("animator");

            if (!_childAnimators.Contains(animator))
                _childAnimators.Add(animator);

            animator.SetIntervall(this.Intervall, false);
            animator.SetStepSize(this.StepSize, false);
            animator.SetLoopMode(this.LoopMode, false);
            animator.SetSynchronizationMode(this.SynchronizationMode, false);
        }
Esempio n. 3
0
        /// <summary>
        /// Removes an <see cref="AnimatorBase"/> which acts as a child of this instance.
        /// </summary>
        /// <param name="animator">Child to be removed.</param>
        protected void RemoveChildAnimator(AnimatorBase animator)
        {
            if (animator == null)
                throw new ArgumentNullException("animator");

            if (_childAnimators.Contains(animator))
                _childAnimators.Remove(animator);
        }
Esempio n. 4
0
        /// <summary>
        /// Adds an <see cref="AnimatorBase"/> which acts as a child of this instance.
        /// Thus its <see cref="Intervall"/>, <see cref="StepSize"/>, <see cref="LoopMode"/>
        /// and <see cref="SynchronizationMode"/> will be set accordingly to and synchronized 
        /// with the settings of this instance.
        /// </summary>
        /// <param name="animator">Child to add.</param>
        protected void AddChildAnimator(AnimatorBase animator)
        {
            if (animator == null)
                throw new ArgumentNullException("animator");

            if (!_childAnimators.Contains(animator))
                _childAnimators.Add(animator);

            animator.SetIntervall(this.Intervall, false);
            animator.SetStepSize(this.StepSize, false);
            animator.SetLoopMode(this.LoopMode, false);
            animator.SetSynchronizationMode(this.SynchronizationMode, false);
        }