Category5.Animation.Animation C# (CSharp) 메소드

Animation() 공개 메소드

Constructor to assign values to all fields
public Animation ( Microsoft.Xna.Framework.Graphics.Texture2D aTexture, int fWidth, int fHeight, float animTime ) : System
aTexture Microsoft.Xna.Framework.Graphics.Texture2D
fWidth int
fHeight int
animTime float
리턴 System
        public Animation(Texture2D aTexture, int fWidth, int fHeight, float animTime)
        {
            texture = aTexture;
            frameWidth = fWidth;
            frameHeight = fHeight;
            frameCount = aTexture.Width / fWidth;
            currentFrame = 0;
            color = Color.White;
            timeBetweenFrames = animTime;
        }