Пример #1
0
        public GruntRanged(Texture2D atlasTexture) : base(atlasTexture)
        {
            IAnimationAtlasAction RangedLeft  = Factory.CreateAnimAtlasAction(11, 11, true);
            IAnimationAtlasAction RangedRight = Factory.CreateAnimAtlasAction(12, 12, true);

            Actions.Add("RangedLeft", RangedLeft);
            Actions.Add("RangedRight", RangedRight);

            Mover        = new MoverAI(this, true);
            RangedWeapon = new RangedWeaponAI(this, 10, 480, 1000f);
        }
Пример #2
0
        public GruntMelee(Texture2D atlasTexture, List <int> wayPointIndexes) : base(atlasTexture)
        {
            IAnimationAtlasAction MeleeRight = Factory.CreateAnimAtlasAction(23, 25, false);
            IAnimationAtlasAction MeleeLeft  = Factory.CreateAnimAtlasAction(20, 22, false);

            Actions.Add("MeleeRight", MeleeRight);
            Actions.Add("MeleeLeft", MeleeLeft);

            Mover = new MoverAI(this, false, wayPointIndexes);

            List <int> attackFramesRight = new List <int>()
            {
                24
            };
            List <int> attackFramesLeft = new List <int>()
            {
                21
            };

            MeleeWeapon = new MeleeWeaponAI(this, 1, 20, attackFramesRight, attackFramesLeft);
        }