Ejemplo n.º 1
0
 // Increment the score a team when the + button is clicked
 private void IncrementScoreButton_Click(object sender, RoutedEventArgs e)
 {
     if (sender is Button btn)
     {
         string teamName   = btn.Name.Split('_')[0];
         int    teamNumber = DefaultValues.TEAMNAMES.ToList().IndexOf(teamName);
         _gameBrain.IncrementScore(teamNumber);
         UpdateAllWindows();
         AddToScreenLog("INCREMENTED score for " + teamName);
     }
 }