Example #1
0
 public static string ScoreStringHuman(Score s)
 {
     return Translate.Dict (s.a) + " - " + Translate.Dict (s.b);
 }
Example #2
0
 public static Score AddWithDeuce(Score first, Score second)
 {
     return Add (first, second).Deuce ();
 }
Example #3
0
 public static string ScoreString(Score s)
 {
     return s.a + " - " + s.b;
 }
Example #4
0
 public static List<Score> AddToScores(List<Score> list, Score score)
 {
     list.Add (Add (list.Last (), score));
     return list;
 }
Example #5
0
 public static Score AddWin(Score counter, Score score)
 {
     return (score.a > score.b) ? new Score (counter.a + 1, counter.b) : new Score (counter.a, counter.b + 1);
 }
Example #6
0
 public static Score Add(Score first, Score second)
 {
     return new Score (first.a + second.a, first.b + second.b);
 }
Example #7
0
 public static List<Score> AddToGameScores(List<Score> list, Score score)
 {
     list.Add (AddWithDeuce (list.Last (), score));
     return list;
 }
Example #8
0
 public Score(Score score)
 {
     this.a = score.a;
     this.b = score.b;
 }
Example #9
0
 public static string WinString(Score score)
 {
     return "Winner: Player " + score.Winner ().ToString ().ToUpper () + " with " + score.WinScore ();
 }
Example #10
0
 public bool IsOver(Score score)
 {
     return score.HasMin (7) && score.HasAdvance (2);
 }
Example #11
0
 public string CurrentScoreString(Score s)
 {
     return Score.ScoreString (s);
 }
Example #12
0
 public string CurrentScoreString(Score s)
 {
     return "Game: " + Score.ScoreStringHuman (s);
 }