예제 #1
0
        protected override void Initialize()
        {
            Components.Add(new Xin(this));

            // configure player animations and npcs
            // configures animationkeys to spritemaps
            Animation animation = new Animation(3, 64, 64, 0, 0);

            PlayerAnimations.Add(AnimationKey.WalkDown, animation);

            animation = new Animation(3, 64, 64, 0, 64);
            PlayerAnimations.Add(AnimationKey.WalkLeft, animation);

            animation = new Animation(3, 64, 64, 0, 128);
            PlayerAnimations.Add(AnimationKey.WalkRight, animation);

            animation = new Animation(3, 64, 64, 0, 192);
            PlayerAnimations.Add(AnimationKey.WalkUp, animation);

            base.Initialize();
        }