예제 #1
0
 public void SmileClick(PictureBox smileObj)
 {
     Minesweeper.Menu f = new Minesweeper.Menu();
     f.Closed += (s, args) => gameForm.Close();
     f.Show();
     gameForm.Hide();
 }
예제 #2
0
        /// <summary>
        /// Allows the game to perform any initialization it needs to before starting to run.
        /// This is where it can query for any required services and load any non-graphic
        /// related content.  Calling base.Initialize will enumerate through any components
        /// and initialize them as well.
        /// </summary>
        protected override void Initialize()
        {
            // First, display a selection of mine dimensions.
            //InitializeMenu();
            InitGraphicsMode(600, 600);

            // dimension, # of mines
            MyGrid = new Grid(10, 7, 40, "Grid");
            MyMenu = new Menu(new Vector2(0, 0), "Menu2");
            Watch = new Stopwatch();
            SecondWatch = new Stopwatch();

            //Watch.Start();

            this.IsMouseVisible = true;

            base.Initialize();
        }