Package com.shr4pnel.casino.base
Class Player
java.lang.Object
com.shr4pnel.casino.base.Player
- Direct Known Subclasses:
BlackjackPlayer
The base class for all players
- Since:
- 0.1.0
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
hand
-
playerControlled
protected boolean playerControlled -
chips
-
bet
-
-
Constructor Details
-
Player
public Player(boolean playerControlled)
-
-
Method Details
-
getChips
- Returns:
- Amount of chips the player has
-
setChips
-
incrementChips
Add a number to the existing chip count- Parameters:
l- The amount to add, can be negative
-
getBet
- Returns:
- The players current bet
-
incrementBet
- Parameters:
l-
-
add
Add a card to the players hand- Parameters:
card- The card to add
-
add
Add several cards to the players hand- Parameters:
cards- A list of cards
-