Exemplo n.º 1
0
 public override void UpdatePlayerInfo(CompetitionPlayerInfo player_info, PlayerResults player_results, int place)
 {
     player_info.Points       = player_results.Points;
     player_info.Tag          = (player_results as PlayerSwissResults).GetBK();
     player_info.Place        = place.ToString("D2");
     player_info.CurrentPlace = place;
 }
Exemplo n.º 2
0
        public override int ComparePlayerResults(PlayerResults other)
        {
            if (PlayerId == other.PlayerId)
            {
                return(0);
            }
            int res = other.AvailablePoints.CompareTo(AvailablePoints);

            if (res == 0)
            {
                return((other as PlayerSwingResults).GetMatchCount().CompareTo(GetMatchCount()));
            }
            else
            {
                return(res);
            }
        }
Exemplo n.º 3
0
        public override int ComparePlayerResults(PlayerResults other)
        {
            PlayerRobinResults other_res = other as PlayerRobinResults;

            if (other_res == null)
            {
                throw new Exception("Invalid player Result Comparation");
            }
            if (PlayerId == other_res.PlayerId)
            {
                return(0);
            }
            if (Points == other_res.Points)
            {
                // Продолжаем сравнение по коефициентам Бергера
                return(other_res.GetKB().CompareTo(GetKB()));
            }
            return(other.Points.CompareTo(Points));
        }
Exemplo n.º 4
0
        public override int ComparePlayerResults(PlayerResults other)
        {
            PlayerSwissResults other_swiss_res = other as PlayerSwissResults;

            if (other_swiss_res == null)
            {
                throw new Exception("Invalid player Result Comparation");
            }

            if (PlayerId == other_swiss_res.PlayerId)
            {
                return(0);
            }
            if (AvailablePoints == other_swiss_res.AvailablePoints)
            {
                // Продолжаем сравнение по коефициентам Бухгольца
                return(other_swiss_res.GetBK().CompareTo(GetBK()));
            }
            return(other.AvailablePoints.CompareTo(AvailablePoints));
        }
Exemplo n.º 5
0
 public abstract void UpdatePlayerInfo(CompetitionPlayerInfo player_info, PlayerResults player_results, int place);