Exemplo n.º 1
0
        /// <summary>
        /// If needed:
        /// All of the active players are forced to pay some blind
        /// payment to the pot, regardless to the regular blinds.
        /// </summary>
        private void PlaceAntes()
        {
            if (preferences.AntesValue == 0)
            {
                return;
            }

            //first player has to "bet" the ante
            if (CurrentRound.CurrentPlayer.Wallet.AmountOfMoney <= preferences.AntesValue)
            {
                CurrentRound.PlayMove(Round.Move.Allin, preferences.AntesValue);
            }
            else
            {
                CurrentRound.PlayMove(Round.Move.Bet, preferences.AntesValue);
            }

            //other players "call" the ante
            for (int i = 1; i < CurrentRound.ActiveUnfoldedPlayers.Count; i++)
            {
                if (CurrentRound.CurrentPlayer.Wallet.AmountOfMoney <= preferences.AntesValue)
                {
                    CurrentRound.PlayMove(Round.Move.Allin, preferences.AntesValue);
                }
                else
                {
                    CurrentRound.PlayMove(Round.Move.Call, preferences.AntesValue);
                }
            }
        }
Exemplo n.º 2
0
 private void PlaceSmallBlind()
 {
     if (CurrentRound.CurrentPlayer.Wallet.AmountOfMoney < preferences.MinimumBet / 2)
     {
         CurrentRound.PlayMove(Round.Move.Allin, 0);
     }
     else
     {
         CurrentRound.PlayMove(Round.Move.Raise, preferences.MinimumBet / 2);
     }
 }
Exemplo n.º 3
0
 private void PlaceBigBlind()
 {
     if (CurrentRound.CurrentPlayer.Wallet.AmountOfMoney < preferences.MinimumBet)
     {
         CurrentRound.PlayMove(Round.Move.Allin, 0);
     }
     else
     {
         //the raise amount is another small blind
         CurrentRound.PlayMove(Round.Move.Raise, preferences.MinimumBet / 2);
     }
 }