コード例 #1
0
ファイル: Game.cs プロジェクト: blackflash/poker2
 public Game(double buyin, int numberOfPlayers, double numberOfHours)
 {
     var blindhelper = new BlindsHelper();
     TimeperblindMS = blindhelper.GetBlindTimeInMS(numberOfHours, numberOfPlayers);
     //var timeinMin = TimeperblindMS / 1000 / 60;
     var prizePools = new Priezepools();
     PrizePool = prizePools.Prizeppols.FirstOrDefault(p => p.minPlayers <= numberOfPlayers && p.maxPlayers >= numberOfPlayers);
     if (PrizePool != null)
     {
         PrizePool.SUM = buyin * numberOfPlayers;
         AvarageStack = PrizePool.SUM / numberOfPlayers;
         Blinds = BlindsHelper.Blinds.Take(BlindsHelper.maxBBindex).ToArray();
         CurrentBlind = Blinds[0];
     }
 }
コード例 #2
0
ファイル: Game.cs プロジェクト: blackflash/poker2
        public Game(double buyin, int numberOfPlayers, double numberOfHours)
        {
            var blindhelper = new BlindsHelper();

            TimeperblindMS = blindhelper.GetBlindTimeInMS(numberOfHours, numberOfPlayers);
            //var timeinMin = TimeperblindMS / 1000 / 60;
            var prizePools = new Priezepools();

            PrizePool = prizePools.Prizeppols.FirstOrDefault(p => p.minPlayers <= numberOfPlayers && p.maxPlayers >= numberOfPlayers);
            if (PrizePool != null)
            {
                PrizePool.SUM = buyin * numberOfPlayers;
                AvarageStack  = PrizePool.SUM / numberOfPlayers;
                Blinds        = BlindsHelper.Blinds.Take(BlindsHelper.maxBBindex).ToArray();
                CurrentBlind  = Blinds[0];
            }
        }