Beispiel #1
0
 public Animation(Animation animation)
 {
     Frames = animation.Frames;
     FrameWidth = Frames[0].Width;
     FrameHeight = Frames[0].Height;
     FramesPerSecond = DefaultFramesPerSecond;
     Reset();
 }
Beispiel #2
0
        /// <summary>
        /// Clones the current animation
        /// </summary>
        /// <returns>clone of the animation</returns>
        public virtual object Clone()
        {
            var animationClone = new Animation(this);

            animationClone.FrameWidth = FrameWidth;
            animationClone.FrameHeight = FrameHeight;
            animationClone.Reset();

            return animationClone;
        }