- Deck building is extracted from the
Deck
class to theBuildDeck
class:Deck#new
now takes an array of cards instead of a hash of optionsDeck#reset
removed
BinaryDeck
class to convert decks to binary format and back (to save space when storing decks in a database, for example)BuildDeck
class to build decksCard
instances are now safe to use as hash keysCard#eql?
,Card#hash
andCard#==
methods to compare cards and safely use them as hash keysCard#<=>
method to make cards sortableDeck#size
method to get the number of cards in the deckDeck#deal
method to deal cards from the deckDeck#to_binary_s
helper method to convert the deck to a binary stringDeck#from_binary
helper method to convert the binary string to a deckDeck#==
method to compare decks for equality- Lots of documentation
- Steep gem to check type correctness
- It's now possible to initialize a card with a string, e.g.
Card.new('9c')
- All the type declarations are now correct
Initial release!
Card
classDeck
class- Ability to create a decks of various sizes, ranks, and suits
- Ability to shuffle a deck
- Ability to reset a deck