コード例 #1
0
        public static void Main()
        {
            //// Create a new FormGame and activate it:
            FormGame SodukoGame = new FormGame();

            SodukoGame.ShowDialog();
        }
コード例 #2
0
        public static void Main()
        {
            FormStart formStart = new FormStart();

            formStart.ShowDialog();
            FormGame gameForm = new FormGame(formStart.NumberOfChances);

            gameForm.ShowDialog();
        }
コード例 #3
0
        /// <summary>
        ///     If the user Click on the login button, the login form appears
        /// </summary>
        private void btnLogin_Click(object sender, EventArgs e)
        {
            using (FormLogin formLogin = new FormLogin())
            {
                formLogin.ShowDialog(this);
                string lblUsername = formLogin.UserEmail;

                /// TODO Call game generator
                /// TODO Generate player's attributes (Pos, inventory and so on)
                /// TODO Call event and item generator

                FormGame frmGame = new FormGame(lblUsername);
                frmGame.ShowDialog();
            }
        }
コード例 #4
0
    public static void RunProgram()
    {
        FormGame  formGame;
        FormLogin formLogin = new FormLogin();
        bool      is2PlayersMode;
        GameBoard gameBoard;

        if (formLogin.ShowDialog() == System.Windows.Forms.DialogResult.OK)
        {
            is2PlayersMode = formLogin.Is2PlayersMode();
            gameBoard      = new GameBoard((int)formLogin.GameBoardSize);
            formGame       = new FormGame(formLogin.UserName1, formLogin.UserName2, formLogin.GameBoardSize, gameBoard, is2PlayersMode);
            formGame.ShowDialog();
        }
    }
コード例 #5
0
        public static void Main()
        {
            FormGame formGame = new FormGame();

            formGame.ShowDialog();
        }