RenderingLibrary.Graphics.Sprite.AnimationActivity C# (CSharp) Method

AnimationActivity() public method

public AnimationActivity ( double currentTime ) : void
currentTime double
return void
        public void AnimationActivity(double currentTime)
        {
            if (Animate)
            {
                Animation.AnimationActivity(currentTime);

                SourceRectangle = Animation.SourceRectangle;
                Texture = Animation.CurrentTexture;
                FlipHorizontal = Animation.FlipHorizontal;
                FlipVertical = Animation.FlipVertical;

                // Right now we'll just default this to resize the Sprite, but eventually we may want more control over it
                if (SourceRectangle.HasValue)
                {
                    this.Width = SourceRectangle.Value.Width;
                    this.Height = SourceRectangle.Value.Height;
                }
            }
        }