![]() ![]() The easiest way to store these are just as integers with 0, 1, 2, 3 meaning spades, clubs, hearts, diamonds and using numbers 2 â 14 for values 2 through to 11 for jack and 14 for the aces. So I made a âCardâ class with just these attributes. There are only two things we need to know about a card: To give a bit of context, these are my classes: Card (contains rank / suit) CardList (extends ArrayList) Deck, Pile, Hand (extends CardList) Player (contains a Hand, and a CardList indicating the cards the player has played) Game (contains a List, a Deck, a Pile.![]() So the question is how to manage and keep track of them. Now I want to create a GUI around this to make interaction easier. Here are some of the more interesting aspects of coding up the game. I was bored at university one night so coded blackjack in Java. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |