Beispiel #1
0
 private static IEnumerable<MatchResult> RunRound(RoundParameters parameters)
 {
     var competitionFactory = new CompetitionFactory();
       var competition = competitionFactory.CreateCompetition(parameters.AssemblyFiles, parameters.Teams, parameters.NetworkTeams);
       var allTeamNames = parameters.Teams.Select(t => t.Name).Concat(parameters.NetworkTeams.Select(t => t.Name));
       return competition.PlayRound(allTeamNames);
 }
        private static IEnumerable<MatchResult> RunRound(RoundParameters parameters)
        {
            // preload assemblies for DLR support
            //RockPaperAzure.DlrPreload.LoadFauxBots();

            var competitionFactory = new CompetitionFactory();
            var competition = competitionFactory.CreateCompetition(parameters.AssemblyFiles);
            return competition.PlayRound(parameters.TeamNames);
        }
 public bool Start(RoundParameters parameters)
 {
     if (_currentlyRunning != null)
     {
         _queue.Enqueue(parameters);
         return false;
     }
     _thread = new Thread(Main);
     _currentlyRunning = new Referee(parameters);
     _thread.Start(this);
     return true;
 }
Beispiel #4
0
 public bool Start(RoundParameters parameters)
 {
     if (_currentlyRunning != null)
       {
     _queue.Enqueue(parameters);
     _log.Info("Not starting, already running...");
     return false;
       }
       _thread = new Thread(Main);
       _log.Info("Starting: " + parameters);
       _currentlyRunning = new Referee(parameters);
       _thread.Start(this);
       return true;
 }
Beispiel #5
0
 public Referee(RoundParameters parameters)
 {
     _parameters = parameters;
 }
Beispiel #6
0
 private void Queue(IEnumerable<TeamInfo> localTeams, IEnumerable<TeamInfo> networkTeams)
 {
     var parameters = new RoundParameters(_assemblyFileRepository.FindAllGamesAndPlayers().ToArray(), localTeams, networkTeams);
       _refereeThread.Start(parameters);
 }
Beispiel #7
0
 private static IEnumerable<MatchResult> RunRound(RoundParameters parameters)
 {
     var competitionFactory = new CompetitionFactory();
       var competition = competitionFactory.CreateCompetition(parameters.AssemblyFiles);
       return competition.PlayRound(parameters.TeamNames);
 }
Beispiel #8
0
 private void Queue(string[] teamNames)
 {
     var parameters = new RoundParameters(_assemblyFileRepository.FindAllGamesAndPlayers().ToArray(), teamNames);
       _refereeThread.Start(parameters);
 }