Пример #1
0
 private void NewGame()
 {
     korobeiniki?.Stop();
     timer.Stop();
     model.EndGame();
     PlayingArea.Controls.Clear();
     sizeForm.ShowDialog();
 }
Пример #2
0
        private void Model_GameOver(object sender, EventArgs e)
        {
            timer.Stop();
            korobeiniki?.Stop();
            TimeSpan elapsedTime = DateTime.Now - startTime;

            MessageBox.Show($"Game lasted for {elapsedTime.Minutes} minutes {elapsedTime.Seconds} seconds", "Game Over", MessageBoxButton.OK);
            model.EndGame();
            viewModel.EndGame();
        }
Пример #3
0
 private void EndGame()
 {
     _model.EndGame();
 }