bjrs
A blackjack game engine with optional no_std support.
Features
- Full round flow: betting, player actions, insurance, dealer play, showdown
- Configurable rules via
GameOptions - Deterministic RNG seeded at game creation
stdby default,no_std + allocsupported (enablealloc)
Usage
use ;
let options = default;
let game = new;
let player_id = game.join;
game.start_betting;
game.bet.unwrap;
game.deal.unwrap;
// Player actions, dealer play, and showdown omitted here.
See examples/cli_blackjack.rs for a complete playable CLI example.
no_std
By default this crate uses std. To opt into no_std:
[]
= { = "0.1", = false, = ["alloc"] }
License
Licensed under either of:
- Apache License, Version 2.0
- MIT license