Exemple #1
0
        private void initializeBoard(CheckersGameBoard.eBoardSize i_BoardSize)
        {
            if (!CheckersGameBoard.IsBoardSizeValid((byte)i_BoardSize))
            {
                throw new ArgumentException();
            }

            m_CheckersBoard = new CheckersGameBoard(i_BoardSize);
        }
Exemple #2
0
        // Initializes the game - players and board size
        public void InitializeGameLogic(
            CheckersGameBoard.eBoardSize i_BoardSize,
            string i_Player1Name,
            string i_Player2Name,
            bool i_IsPlayer2Human)
        {
            const bool v_Human = true;

            initializeBoard(i_BoardSize);
            m_Player1        = new PlayerInfo(i_Player1Name, v_Human, ePlayerTag.First);
            m_Player2        = new PlayerInfo(i_Player2Name, i_IsPlayer2Human, ePlayerTag.Second);
            m_CurrPlayerTurn = m_Player1;
            buildPlayersPiecesList();
        }