Rules engine status
A Magic: The Gathering rules engine in Rust, written from the Comprehensive Rules (6 November 2026) and aimed at 3 Card Blind. It is the referee for a game: it applies the rules, lists every legal choice at each decision and says who won. It is early: a handful of hand-written cards, enough rules to play real games with them.
There is no app for the engine itself, only a JSON API. The sample games on this site are recorded from it and replayed here for review. The source is on GitHub.
- Sample games
- 12
- Playable cards
- 11 + basic lands
- Engine build
- …
- Last updated
- 25 Nov 2026
What works today
- A full turn: untap, upkeep, draw, main phases, combat, end step and cleanup, with priority passing in succession and the stack.
- Combat: attackers and blockers, damage division among several blockers, deathtouch, flying, reach, menace, vigilance, haste, summoning sickness, goad.
- Mana and spells: lands, mana abilities (including Treasure), creature and other permanent spells, one sorcery (Call to the Void).
- Triggered abilities: enters-the-battlefield and attacks triggers, targets chosen as they go on the stack, ordered by each player.
- Dungeons and the initiative: venture into Lost Mine of Phandelver, Tomb of Annihilation, Dungeon of the Mad Mage and Undercity (all rooms but two), and taking the initiative.
- State-based actions, tokens, +1/+1 counters, the legend rule, and replacement effects (Leyline of the Void).
- 3 Card Blind settings: the whole deck as the opening hand, no loss for drawing from an empty library, public secret choices, a turn limit, and Vintage deck legality.
- Draws: mandatory loops (CR 104.4b) are detected and drawn; an optional loop runs into the turn limit instead.
Not yet
- Activated abilities other than mana abilities, and spells with targets, modes or X.
- First strike and double strike, attack and block costs, planeswalker and battle attacks, and phasing and day/night.
- Damage prevention, lifelink, infect, copies, additional and alternative costs, hybrid and Phyrexian mana.
- Randomness (shuffles, coins, dice). Deferred until it is designed: cards that need it are refused. Undercity's Secret Entrance and Throne of the Dead Three wait on this (#9).
- A solver that picks plays. The engine only referees.
The full rule-by-rule table is docs/coverage.md; every difference between 3 Card Blind and the Comprehensive Rules, and how each is handled, is in docs/three-card-blind.md.
Updates
Newest first. Issue numbers are on GitHub.
-
25 Nov 2026
- Status page. This page replaces the old rules engine web app, which was retired along with its card browser. The engine itself has no UI; look for it here.
- Initiative and Undercity (#9, in part). Taking the initiative, its three triggers, and venturing into Undercity. Two rooms wait on randomness.
- Dungeon of the Mad Mage (#8) and Tomb of Annihilation (#7) join Lost Mine of Phandelver.
- API: games now carry
choice_descriptions, a readable label for each legal choice (#10). The sample games here use it. - 3CB Lab launched at /3cb/ with 12 sample games, each testing one rule, to be stepped through and reviewed.
-
24 Nov 2026
- Engine restarted as API-only. A new Rust engine with no graphical UI, built from the 6 November 2026 Comprehensive Rules. The earlier version, with a game visualizer and card browser, was archived.
- 3 Card Blind preset and a turn limit, with each rule decision written down.
- 3CB opening hand: the whole deck is the hand, the library is empty, no mulligans (#1). Drawing from an empty library no longer loses (#2).
- Vintage deck legality checked when a game is created (#5).
- Dungeons, venture and the initiative first implemented (#6).
- Mandatory loops are draws (#3), and secret choices are made publicly, active player first (#4).