/// <summary> /// Re-evaluates the win condition /// </summary> private void WinText() { if (CompletedLabel.Text == "Completed :)") { if (!game.IsComplete()) { CompletedLabel.Text = "Not Completed :/"; CompletedLabel.Foreground = Brushes.Red; } } else { if (game.IsComplete()) { CompletedLabel.Text = "Completed :)"; CompletedLabel.Foreground = Brushes.Green; } } }
public MainWindow() { InitializeComponent(); game = new Puzzle(); if (CompletedLabel.Text == "Not Completed :/") { if (game.IsComplete()) { CompletedLabel.Text = "Completed :)"; } } }