Player class
void drawCard(Deck* deck,int cardAmt)
Public function.
Draws cardAmt cards from Deck deck.
int value()
Public function.
Returns the total value of a player's hand
It also takes care of handling whether or not an Ace should be 1 or 11.
int handSize()
Public function.
Returns the number of cards in a player hand.
void draw(BITMAP* buf,int x,int y,bool facedown)
Public function.
Draws the player's hand by
calling the Card::draw(BITMAP*,int,int,bool) method for each.
It also displays the player's hand's value.
std::vector<int> getHand()
Public function.
Returns the Player's hand.
void clear()
Public function.
Clears the Player's hand, which also reduces the
hand's value to null.
Resets the Player's standing value.
bool isStanding()
Public function.
Returns the player's standing status.
void stand()
Public function.
Sets the player's standing status to true.
Player()
Default constructor. No explicit function.
~Player()
Default destructor. No explicit function.
Stephen Cole - Pitt Community College - December 2006
|
|