Exemplo n.º 1
0
        /// <summary>
        /// Constructor to set up connect four game.
        /// </summary>
        public ConnectFourGame(Player.IPlayer playerOne, Player.IPlayer playerTwo)
        {
            Board = new Board.Board(DefaultBoardColumns, DefaultBoardRows);

            _playerOne = playerOne;
            _playerTwo = playerTwo;

            _playerOneNext = true;
        }
Exemplo n.º 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="BasicCity" /> class.
        /// </summary>
        /// <param name="location">The location.</param>
        /// <param name="map">The map.</param>
        /// <param name="player">The player.</param>
        public BasicCity(Point location, Map map, Player.IPlayer player)
        {
            this.map    = map;
            position    = location;
            this.player = player;
            population  = 1;
            ore         = 0;
            food        = 0;

            inDoorsUnits    = new List <IUnit>();
            controlledCases = new List <Point>();
            controlledCases.Add(position);
        }
Exemplo n.º 3
0
        /// <summary>
        /// Initializes a new instance of the <see cref="BasicCity" /> class.
        /// </summary>
        /// <param name="location">The location.</param>
        /// <param name="map">The map.</param>
        /// <param name="player">The player.</param>
        public BasicCity(Point location, Map map, Player.IPlayer player)
        {
            this.map = map;
            position = location;
            this.player = player;
            population = 1;
            ore = 0;
            food = 0;

            inDoorsUnits = new List<IUnit>();
            controlledCases = new List<Point>();
            controlledCases.Add(position);
        }