Files
Claude fb70396d09 Add Kaiser, Crazy 8s and Wizard
Three more card games, engine to screen.

Kaiser: 32-card prairie trick-taking with bidding, the five of hearts
worth five and the three of spades costing three. Bidding is capped at
ten because ten is all a hand can be worth, and a losing score gives the
game a floor — without one a table that keeps bidding and going down
never reaches a result.

Crazy 8s: eights are wild and name the suit in force, which is why the
table states that suit in words rather than leaving it to be read off
the pile. Blocked rounds are scored rather than hanging.

Wizard: the 60-card deck, one more card dealt each round until the pack
runs out, bid your tricks exactly. The shared card model gains WIZARD
and JESTER ranks, so every ordinary deck now builds from Rank.standard
rather than walking the whole enum.

Also fixes a lobby bug this would have hit: hosting seated the
catalogue minimum rather than the table the host had just set up, so a
six-handed game would have been rejected by its own rules engine.

164 engine tests pass locally.
2026-08-06 10:21:23 +00:00

60 lines
2.0 KiB
Markdown

# Crazy 8s — implemented rules
This is the ruleset the engine enforces. Anything marked **toggle** is in the
game setup screen.
## Table
- 2 to 6 players — **toggle**. Everyone plays for themselves.
- One 52-card deck.
- Seven cards each heads-up, five otherwise — **toggle** to fix it at 5, 7 or 9
instead.
- The rest becomes the stock; one card is turned up to start the discard pile.
If that card is an eight, the suit it shows is the one in force.
## Play
On your turn, play one card that matches either
- the **suit in force**, or
- the **rank** of the card on top of the pile.
**Eights are wild.** An eight may be played on anything, and the player names
the suit that is then in force. This is why the suit in force is stated in words
on the table rather than left to be read off the pile — after an eight, the top
card tells you nothing.
If you cannot play:
- **Draw until you can — *toggle*, on by default.** Keep drawing until a
playable card turns up, or until there is nothing left to draw.
- With the toggle off, draw a single card; if it still does not play, the turn
passes.
- When the stock is empty it is rebuilt from the discards, leaving the top card
in place. If there is genuinely nothing to draw and nothing to play, you pass.
If every player passes in turn, the round is blocked and ends with nobody out.
## Scoring
The round ends when a player sheds their last card. Everyone else scores penalty
points for what they were caught holding:
| Card | Penalty |
| --- | --- |
| Eight | 50 |
| Ten, jack, queen, king | 10 |
| Ace | 1 |
| Everything else | Face value |
A blocked round is scored the same way — everyone still holding cards pays for
them.
Lowest total after the last round wins — **toggle** for 1, 3 or 5 rounds.
## What the computer opponent does
It plays the most expensive card it can get rid of, saves its eights until the
endgame or until it has nothing else, and when it does play one it names the
suit it holds most of.