Skip to content

Releases: Nydauron/playing-cards

0.1.3

12 Aug 19:13
0.1.3
02ecdfb
Compare
Choose a tag to compare

What's Changed

  • More resilient conversions from strings by @pashadia in #6
  • Adds MSRV to crate metadata (the MSRV of prior releases is also 1.62)
  • Adds Card::is_face_card() and Value::is_face_card() methods
  • Fixes a bug regarding correctly counting the remaining number of cards left when dealing cards when including the muck
  • Various documentation clarifications
  • Applies multiple clippy fixes

New Contributors

Full Changelog: 0.1.2...0.1.3

0.1.2

13 Aug 04:58
6cbfbe4
Compare
Choose a tag to compare

What's Changed

  • Added CardDeckError enum
  • Deprecated CardDeck::get_seed()

Full Changelog: 0.1.1...0.1.2

0.1.1

13 Aug 01:05
f6d95c9
Compare
Choose a tag to compare

What's Changed

Full Changelog: 0.1.0...0.1.1

0.1.0

12 Aug 05:32
228085e
Compare
Choose a tag to compare

Breaking changes

  • Core
    • Removed Card::from_int() in favor for num_trait::FromPrimitive derivations
    • CardDeck
      • CardDeck::new() now takes in an optional seed and creates an unshuffled deck if no seed is provided
      • Removed CardDeck::new_with_seed()
      • CardDeck now uses the Xoshiro256PlusPlus PRNG accompanied with a 256-bit seed
        • Seeds returned by get_seed() will be [u8; 32] instead of u64
      • CardDeck::reshuffle() takes in an optional 256-bit seed
  • Poker
    • Removed Evaluator trait
    • Evaluators are now standalone functions packaged within modules within the poker::evaluators module
    • Changed evaluator functions to return back rank types instead of u64

Features added

  • Core
    • Added Value::get_cactus_kev_prime()
    • Value now derives Hash, Eq, PartialOrd, and Ord
    • Suit now derives Hash and Eq
    • Card can now be serialized and deserialized with serde
    • Added Card::calculate_bit_pattern()
    • CardDeck
      • Added CardDeck::new_custom_deck()
      • Added CardDeck::shuffle()
      • Added CardDeck::strip_cards()
      • Added CardDeck::strip_ranks()
      • Added CardDeck:strip::suits()
  • Poker
    • Evaluators
      • Added 2-to-7 Low
      • Added Badugi
      • Added Dramaha High
      • Added Omaha High
      • Added Omaha Hi-Lo
      • Added EvaluatorErrors
    • Added rank types
      • Added BasicRank
      • Added HighRank
      • Added Low27Rank
      • Added LowA5Rank
      • Added BadugiRank
      • Added DramahaHighRank
      • Added OmahaHiLoRank
    • Added RankResults<T>
    • Added RankStrengthIterator
    • Added IntoRankStrengthIterator trait
    • Added generate_winner_list<T, U>()

Implementation changes

  • Removed Into<char> for Value and Suit in favor of using the From trait
  • CardDeck::deal_cards() and CardDeck::draw_cards() are now more atomic; if there are not enough cards present to deal/draw, then no cards are returned
  • Changed underlying Poker evaluator from 2+2 evaluator to Cactus-Kev Perfect Hash