Example #1
0
 /// <summary>
 /// Constructs a new 
 /// </summary>
 public Boss(Vector2 position, string spriteSet, int health, int attack)
 {
     this.Position = position;
     this.Alive = true;
     this.SpecialAnimationDone = true;
     this.AttackOnce = true;
     this.Health = health;
     this.AttackStrength = attack;
     this.movement = 200;
     direction = Enums.FaceDirection.Left;
     movePlayer = new MovePlayer();
     LoadContent(spriteSet);
 }
Example #2
0
        /// <summary>
        /// Constructors a new player.
        /// </summary>
        public LevelPlayer(Vector2 position)
        {
            movePlayer = new MovePlayer();

            #region Moves List
            // Construct the master list of moves.
            moves = new Move[]
            {
                new Move(Enums.MoveState.Punch, Buttons.X),
                new Move(Enums.MoveState.Kick, Buttons.A),
                new Move(Enums.MoveState.SpecialCombo, Buttons.X | Buttons.A),
                new Move(Enums.MoveState.ComboKick, Direction.Down, Direction.DownRight, Direction.Right | Buttons.A),
                new Move(Enums.MoveState.ComboKick, Direction.Down, Direction.DownLeft, Direction.Left | Buttons.A),
                new Move(Enums.MoveState.FirePunch1, Direction.Down, Direction.DownRight, Direction.Right | Buttons.X),
                new Move(Enums.MoveState.FirePunch1, Direction.Down, Direction.DownLeft, Direction.Left | Buttons.X),
                new Move(Enums.MoveState.FinalCombo2,  Buttons.B),
            };
            #endregion

            // Construct a move list which will store its own copy of the moves array.
            moveList = new MoveList(moves);

            // Create an InputManager for player with a sufficiently large buffer.
            inputManager = new GamePlayInput((PlayerIndex)0, moveList.LongestMoveLength);

            Alive = true;
            Lives = 3;
            ComboCount = 3;
            Lv = 1;
            AttackStrength = 3;
            chainMoves.Capacity = 3;
            LoadContent();
            Reset(position);
        }