Exemple #1
0
        public void CreateSemi()
        {
            SortTeamsPoints();
            if (RankingTeam.Count >= 4)
            {
                Match match = new Match()
                {
                    TeamA       = RankingTeam[0],
                    TeamB       = RankingTeam[1],
                    RefereeList = RefereeList,
                    GameTypes   = GameTypes,
                    MatchRanks  = MatchRanks.Semifinal
                };
                MatchPlanned.Add(match);

                match = new Match()
                {
                    TeamA       = RankingTeam[2],
                    TeamB       = RankingTeam[3],
                    RefereeList = RefereeList,
                    GameTypes   = GameTypes,
                    MatchRanks  = MatchRanks.Semifinal
                };
                MatchPlanned.Add(match);
                WasSemiCreated = true;
            }
        }
Exemple #2
0
        public void CreateGroupStage()
        {
            if (TeamList.Count >= 2)
            {
                int   i = 0;
                int   j;
                Match match;
                foreach (var teamA in TeamList.List)
                {
                    j = 0;
                    foreach (var teamB in TeamList.List)
                    {
                        if (j > i)
                        {
                            match = new Match()
                            {
                                TeamA       = teamA,
                                TeamB       = teamB,
                                RefereeList = RefereeList,
                                GameTypes   = GameTypes,
                                MatchRanks  = MatchRanks.GroupStage
                            };

                            MatchPlanned.Add(match);
                        }
                        j++;
                    }
                    i++;
                }
                WasGroupStageCreated = true;
            }
        }
Exemple #3
0
 public void CreateFinal()
 {
     SortTeamsPoints();
     if (RankingTeam.Count >= 2)
     {
         FinalA = RankingTeam[0];
         FinalB = RankingTeam[1];
         Match match = new Match()
         {
             TeamA       = FinalA,
             TeamB       = FinalB,
             RefereeList = RefereeList,
             GameTypes   = GameTypes,
             MatchRanks  = MatchRanks.Final
         };
         MatchPlanned.Add(match);
         WasFinalCreated = true;
     }
 }