Пример #1
0
        private void Timer_Tick(object sender, EventArgs e)
        {
            CounterTimer CT = sender as CounterTimer;

            CT.IncrementTimer();

            Console.WriteLine(CT.GetUITime());
            this.Text = "Mineswooper by Nøls (" + CT.GetUITime() + ")";
        }
Пример #2
0
        private void GameWin()
        {
            timer.Stop();
            Console.WriteLine("All mines flagged. You Win!");
            var YouWinWindow = new GameResultWindow();

            YouWinWindow.GameResultText = "You Win!\r\n" + timer.GetUITime();
            InitializeResetButton(YouWinWindow, true);
            YouWinWindow.ShowDialog(this);
        }