public MatchResult RunMatch(IBot player1, IBot player2) { var roundResults = new List <RoundResult>(); var roundRunner = new RoundRunner(); RoundResult previoResult = new RoundResult(); for (int i = 0; i < 1000; i++) { previoResult = roundRunner.RunRound(player1, player2, previoResult); roundResults.Add(previoResult); } return(GetMatchResultFromRoundResults(player1, player2, roundResults)); }
public MatchResult RunMatch(BaseBot player1, BaseBot player2) { var roundResults = new List <RoundResult>(); var roundRunner = new RoundRunner(); var matchResult = new MatchResult { Player1 = player1.Competitor, Player2 = player2.Competitor }; RoundResult previousResult = new RoundResult { MatchResult = matchResult }; for (int i = 0; i < 100; i++) { previousResult = roundRunner.RunRound(player1, player2, previousResult, metrics); roundResults.Add(previousResult); } return(GetMatchResultFromRoundResults(matchResult, player1, roundResults)); }