Add helper method to get winning team colour

This commit is contained in:
Dean Herbert 2020-03-06 16:03:34 +09:00
parent 3caffb81e1
commit 129c8fe24f
1 changed files with 2 additions and 0 deletions

View File

@ -90,6 +90,8 @@ public TournamentMatch(TournamentTeam team1 = null, TournamentTeam team2 = null)
[JsonIgnore]
public TournamentTeam Loser => !Completed.Value ? null : Team1Score.Value > Team2Score.Value ? Team2.Value : Team1.Value;
public TeamColour WinnerColour => Winner == Team1.Value ? TeamColour.Red : TeamColour.Blue;
public int PointsToWin => Round.Value?.BestOf.Value / 2 + 1 ?? 0;
/// <summary>