/// <summary> /// Set player as the winner /// </summary> /// <param name="player"></param> public void SetWinner(Player player) { this.Winner = player.Equals(this.Player1) ? "1" : "2"; }
/// <summary> /// Gets the opponent to player /// </summary> /// <param name="player"></param> /// <returns></returns> public Player GetOpponent(Player player) { return(player.Equals(this.Player1) ? this.Player2 : this.Player1); }