@llmletsplay/versus-blackjack
v0.1.1
Published
Standalone Versus blackjack engine package
Readme
@llmletsplay/versus-blackjack
Drop-in Blackjack engine for a single player versus the dealer.
Install
npm install @llmletsplay/versus-blackjackQuick Start
import { BlackjackGame } from '@llmletsplay/versus-blackjack';
const game = new BlackjackGame('demo');
await game.initializeGame();
const state = await game.getGameState();
console.log(state.currentPlayer);What You Get
- ESM build output from
dist/ - Type declarations for TS consumers
- In-memory storage by default, with optional database injection when you need persistence
- Package-local rules in RULES.md
Public API
new BlackjackGame(gameId, database?)initializeGame(config?)validateMove(move)makeMove(move)getGameState()
Rules
See RULES.md for the implemented objective, setup, turn flow, end conditions, and engine notes.
Scope Notes
- This package models a single player against the dealer, not a multi-seat table.
Testing
This package is exercised by the shared game-engine test suite that the server integration layer also consumes.
