public void theSnake_GameOver(object sender, GameOverEventArgs e) { this.TheSnake.SnakeTimer.Stop(); this.toolStripStatusLabelRunning.Text = "Game Over"; this.timerGameDuration.Stop(); this.GameOverForm = new FormGameOver(this); this.GameOverForm.ShowDialog(); }
public void CallGameOver() { GameOverEventArgs e = new GameOverEventArgs(this.snakeBody); if (this.GameOver!=null) { this.GameOver(this, e); } }