Stores a first-in-last-out stack of cards.
Constructor for the type of card stored in this container. Used to find the card dimensions.
Optional
options: IDeckOptionsOptional configuration for the deck.
Readonly
alwaysOptional
Readonly
autoComparison function to use to automatically sort added cards.
Default orientation of cards added to this container.
Optional
hiddenOptional display name for this object when hidden.
Optional
nameOptional display name for this object.
Gets the dimensions of the card type stored in this container.
Gets the number of cards in this container.
If true, this container has no cards.
Gets all cards in this container that are marked as selected.
Top-most card, the one that will be next drawn. This is null for empty decks.
Gets all cards in this container that aren't marked as selected.
Deal up to the given number of cards to each target.
Recipients of the deal.
Maximum number of cards to deal to each recipient.
Index of the first recipient in targets.
Deals up to the given total number of cards, divided between the given targets.
Recipients of the deal.
Maximum number of cards to deal in total.
Optional
handLimit: numberIndex of the first recipient in targets.
Gets a card by index.
Index of the card to get, starting at 0 and strictly less than count.
Retrieved card.
Gets whether the given card is face up or down.
Index of the card to get.
Orientation of the given card.
Gets whether the given card is face up or down.
Card to get.
Orientation of the given card.
Protected
getGets whether the given card is marked as selected.
Index of the card to get.
Selection state of the given card.
Gets whether the given card is marked as selected.
Card to get.
Selection state of the given card.
Protected
onProtected
onProtected
onRemove all cards from this container.
The removed cards.
Remove the given cards from this container.
The removed cards.
Remove all cards matching a predicate from this container.
Predicate to match for each card.
The removed cards.
Builds a view of this object from the perspective of a player.
Information about where the object is in the scene, and who's viewing it.
Adds or removes cards from this container until there are exactly the given number. Uses the given factory function to create new cards.
Desired number of cards in this container.
Function to create new cards if we need them.
Set all cards to the given orientation.
Orientation to set the cards to.
Sets whether the given card is face up or down.
Index of the card to set.
Orientation to set the card to.
Sets whether the given card is face up or down.
Card to set.
Orientation to set the card to.
Set all cards to be either selected or deselected.
Selection state to set all cards to.
Sets whether the given card is marked as selected.
Index of the card to set.
Selection state to set the card to.
Sets whether the given card is marked as selected.
Card to set.
Selection state to set the card to.
If this container holds enough cards, deals the given number to each target and returns true. Otherwise nothing is dealt and returns false.
Recipients of the deal.
Exact number of cards to deal to each recipient, if possible.
True if the given number of cards were dealt, otherwise false.
Generated using TypeDoc
Stores a first-in-last-out stack of cards. Only the top card is visible, but players can see how many cards are in the stack.