Dominion.PlayerState.AddBuys C# (CSharp) Method

AddBuys() private method

private AddBuys ( int actionAmount ) : void
actionAmount int
return void
        internal void AddBuys(int actionAmount)
        {
            this.turnCounters.AddBuys(this, actionAmount);
        }

Usage Example

Beispiel #1
0
        public override void DoSpecializedAction(PlayerState currentPlayer, GameState gameState)
        {
            if (currentPlayer.RequestPlayerTrashCardFromHand(gameState, card => card.isTreasure, isOptional:true) != null)
            {
                PlayerActionChoice choice = currentPlayer.RequestPlayerChooseBetween(
                    gameState,
                    acceptableChoice => acceptableChoice == PlayerActionChoice.PlusCard || acceptableChoice == PlayerActionChoice.PlusCoin);

                switch (choice)
                {
                    case PlayerActionChoice.PlusCard:
                    {
                        currentPlayer.DrawAdditionalCardsIntoHand(2);
                        currentPlayer.AddActions(1);
                        break;
                    }
                    case PlayerActionChoice.PlusCoin:
                    {
                        currentPlayer.AddCoins(2);
                        currentPlayer.AddBuys(1);
                        break;
                    }
                    default:
                        throw new Exception();
                }
            }
        }
All Usage Examples Of Dominion.PlayerState::AddBuys
PlayerState