Esempio n. 1
0
        public void Load(ContentManager content)
        {
            coin = content.Load <Texture2D>("coin");
            AnimatedTexture animation = new AnimatedTexture(Vector2.Zero, 0, 1, 1);

            animation.Load(content, "coin", 1, 1);
            animation.Origin = new Vector2(0, 0);
            coinSprite.Add(animation, -coin.Width / 2, -coin.Height / 2);
            coinSprite.Pause();
        }
Esempio n. 2
0
 public void Add(AnimatedTexture animation, int xOffset = 0, int yOffset = 0)
 {
     animations.Add(animation);
     animationOffsets.Add(new Vector2(xOffset, yOffset));
 }