Exemple #1
0
        public void NewGame()
        {
            FormSettings formSettings = new FormSettings();

            formSettings.ShowDialog();

            m_BoardSize = formSettings.BoardSize;
            m_PlayerOne = new Player(formSettings.PlayerOneName);
            m_PlayerTwo = new Player(formSettings.PlayerTwoName, formSettings.IsComputer);

            r_GameHandler.Init(m_PlayerOne, m_PlayerTwo, (byte)m_BoardSize);
            m_Tiles = new Tile[(byte)m_BoardSize, (byte)m_BoardSize];

            if (m_FormGame == null)
            {
                m_FormGame = new FormGame();
                initBoard();
                m_FormGame.ShowDialog();
            }
        }
Exemple #2
0
      private void StartGame_Click(object sender, EventArgs e)
      {
          FormGame f2 = new FormGame();

          f2.ShowDialog();
      }