private void btnClear_Click(object sender, RoutedEventArgs e) { board.Clear(); foreach (var item in gameBoardElements) { item.Background = Brushes.Lavender; } }
/// <summary> /// Reset game function. /// Pause the game, clear the plot and the board. /// </summary> public void ResetGame() { Pause(); mw.ClearPlot(); mw.EnableInterface(true); Board.Clear(); Board.BoardStatistics.ResetStatistics(); mw.txtStats.Text = ""; }