Commander Simulator
Play Magic: The Gathering Commander in your browser, with local AI opponents or friends at a private table.
Choose a ready-to-play precon or import your own supported deck. Build a pod, pick opponent personalities, and play through casting, priority, the stack, combat, and triggered abilities at your own pace. Solo AI runs on your device and needs no model API key or AI subscription.
Play now · Import a deck · Card catalog · Report a bug
Development focus: Solo play against local AI. Commander Live with human players is currently in testing.
Napomena: Multiplayer mod sa živim igračem je trenutno u testnoj fazi. Molim za strpljenje. Kompletna pažnja je posvećena isključivo borbi protiv AI protivnika.
Start playing
- Open Commander Simulator in a current desktop, tablet, or mobile browser. Guest Solo needs no account or installation.
- Choose Play solo, select a deck, and set up one to three AI opponents in Pod.
- Review the settings, keep or mulligan your opening hand, and follow the available actions. Open Guide if this is your first visit.
For friends, choose Play with friends to open Commander Live and invite them to a private two-to-four-player table. Keep the host's game tab open for the whole match. For your own list, open My Library and paste a plain-text deck export under Import your decklist here.
Developers: jump to Run locally. iPhone & iPad: use the browser or build the iOS app project on a Mac.
Explore this guide
What you can play
| Mode | How it works |
|---|
| Solo | Control one seat against one to three local AI opponents. Choose decks, opponent styles, difficulty, and optional Politics rules. No model API or AI subscription is required. |
| Commander Live | Invite friends to a private table of two to four seats; the host can fill empty seats with local AI bots. The host runs the game engine; the room server synchronizes decisions and sends each guest their own view. Keep the host's game tab open. |
| Imported decks | Paste a Commander decklist, check it against the supported catalog, and save it to My Library. Ready lists can be used by you, Solo opponents, and Live players. |
Current catalog
Current runtime inventory, including the 29 October Star Trek preview import. The source comparison remains pinned to 9 October 2026:
| Measure | Available |
|---|
| Built-in precon decks | 180, each with 100 cards |
| Runtime card definitions | 32,273 |
| Definitions eligible for deck import | 32,272 |
| Generic Oracle batches | 266, containing 28,137 definitions |
| Remaining paper/Commander Oracle IDs in the pinned comparison | 0 of 32,115 |
| Dedicated commander videos | 28, across the original 27 decks |
These counts describe the implemented catalog, not every Magic card or every possible rules interaction. Brisela, Voice of Nightmares is a meld result and cannot be imported as a standalone card. Some original precon lists retain cards regardless of banlist status; acceptance by this simulator is not a current tournament-legality check.
Browse the supported-card CSV, remaining-card CSV, and machine-readable summary. The catalog guide explains eligibility, source snapshots, and the limits of certification. Paper availability aggregates all paper printings by Oracle ID; names and face aliases are resolved by the deck importer. A complete pinned comparison does not establish correctness for every rules interaction or cover later cards and legality changes.
Recent additions
-
Star Trek Commander: all four official 100-card precons, 137 new native definitions, local card art and deck guides. These are previews for the 13 November release. Import report
-
1 November desktop targets: while you choose targets on a desktop, the table makes room for the decision panel instead of lying under it. Before, the panel covered the land column of every battlefield in the right half of the table. In a four-player game that meant every land of the two opponents on the right; in a duel, your own lands too. None of them could be clicked as a target. The header above the panel keeps its width, Stack reviews still float over the table, and the table returns to full width when the choice ends. Verification
-
31 October commander blinks: a bot thinking ahead during the end step could resolve a delayed return on its copy of the game and move the real card. That is how Chief Kyle's blinked Commander Spock vanished, with no zone, no return and "On battlefield" in the dock. Simulations now act only on their own copies. Every exile-and-return card in the Spock deck was then tested with the commander as the target: Chief Kyle, Balance of Terror, Temporal Tribulation (also with flashback), The Guardian of Forever and S.S. Botany Bay. The command-zone choice now names each pending return, and bots keep a certain return. The target prompt says what a trigger does and warns when "the next end step" is already the next turn's. Bots no longer blink their own permanents once the end step has begun, when the return is a whole turn away. Kyle picks no target, and Temporal Tribulation and The Guardian of Forever wait. All three still save a permanent from removal on the Stack; the Guardian sacrifices the threatened creature to do it. Bots also never blink a token, which would not come back. Verification
-
31 October phone table: activity notices and toasts float above the prompt instead of covering your life total, touch screens say "tap", the portrait full hand shows two cards per row under a compact commander row, a routine result is a full-width bottom sheet, the target hint is no longer cut off, and the Pod screen lost a stray dark strip. Cards you may play from exile (or a graveyard) now appear as full cards in the phone hand row instead of names, and choosing a spell on the Stack as a target opens the Stack view.
Earlier deck and Oracle imports remain available in the import history.
Accounts are optional. Guests can play immediately and retain imported lists in their current browser. Signing in adds a private Solo checkpoint, synced imported decks and favorites, lifetime statistics, and recent match results. Custom AI skills and saved pod presets remain local to the browser.
180 precon decks and commander video animations
Browse the library in a responsive grid with complete commander card images, both default partners, and 30 decks per page (five or six a row on desktop). The library opens newest first: the latest dated release leads with a New badge, release-year dividers mark the order, and within a year the most recent additions come first. Search by deck, either commander, set, or theme; filter by color, strategy, release year, or favorites, and sort by newest release, name, or recent play. Filters cover the entire library, including older and colorless precons. A compact view is available, and the selected deck and your browsing position stay with you while you explore its guide or build the pod.
The built-in library contains 180 precon decks, each with 100 cards. Choose a deck to open its Deck Spotlight: a commander preview, color identity, strategy, pace and complexity, mana curve, card-type breakdown, key cards, opening-hand advice, and a route through the early, middle, and late game. Tap a commander or key card for a large image and readable rules text; on phones, swipe through the key-card gallery or use its arrows. Section shortcuts take you straight to the cards, game plan, or mana curve, and closing a card returns to your place in the guide. You can keep browsing before committing to a pod.
There are 28 dedicated commander videos across the original 27 decks. Turtle Power has two default partner commanders, Leonardo, the Balance and Michelangelo, the Heart, and each has its own clip. The other 153 precons use original commander art; these imports add no commander videos.
- In Deck Spotlight: the commander video plays as a muted, looping preview alongside the card art and deck guide.
- On battlefield entry: in the Solo arena and Live host view, a supported precon commander receives a short COMMANDER ENTERS video announcement. This happens when the commander reaches the battlefield, so putting a spell on the Stack does not by itself trigger the entrance. The announcement has a Skip button and closes automatically. Remote Live guests use the synchronized card-based view without these entry clips.
- Playback: the MP4 clips are bundled with the game, play muted and inline, and are cosmetic; they do not change mana, priority, card abilities, or the result of a spell. The battlefield announcement uses card art if playback fails or Reduced motion is enabled.
- Imported decks: use ordinary commander card art and a battlefield highlight. They do not inherit a precon's cinematic, even when they use the same commander. Video coverage refers to the predefined decks' default commanders, not every alternate commander in the catalog.
| Built-in deck | Default commander(s) |
|---|
| We Are the Borg | The Borg Queen |
| Federation Fleet | Jean-Luc Picard, Luminary |
| Landing Party | Commander Spock |
| Klingon Fury | Worf, Defiant Commander |
| Multiverse Reforged | Jace, Multiverse Architect |
| Blame Game | Nelly Borca, Impulsive Accuser |
| Evasive Maneuvers | Derevi, Empyrial Tactician |
| Power Hungry | Prossh, Skyraider of Kher |
| Eternal Bargain | Oloro, Ageless Ascetic |
| Mind Seize | Jeleva, Nephalia's Scourge |
| Nature of the Beast | Marath, Will of the Wild |
| Angels: They're Just Like Us but Cooler and with Wings | Gisela, the Broken Blade |
| Enchantress Rubinia | Rubinia Soulsinger |
| Deathdancer Xira | Xira Arien |
| Goblin Storm | Zada, Hedron Grinder |
| Odds and Ends | Yennett, Cryptic Sovereign |
| Hatsune Miku | Trostani, Selesnya's Voice |
| Counterpunch | Ghave, Guru of Spores |
| Mirror Mastery | Riku of Two Reflections |
| Political Puppets | Zedruu the Greathearted |
| Heavenly Inferno | Kaalia of the Vast |
| Devour for Power | The Mimeoplasm |
| Lorehold Spirit | Quintorius, History Chaser |
| Silverquill Influence | Killian, Decisive Mentor |
| Witherbloom Pestilence | Dina, Essence Brewer |
| Peace Offering | Ms. Bumbleflower |
| Miracle Worker | Aminatou, Veil Piercer |
| Jump Scare! | Zimone, Mystery Unraveler |
| Death Toll | Winter, Cynical Opportunist |
| 20 Ways to Win | Go-Shintai of Life's Origin |
| Living Energy | Saheeli, Radiant Creator |
| Eternal Might |
Your first game
- Open the game and choose Play solo, or open Guide for a walkthrough.
- Select a built-in deck or a ready list in My Library. Its deck overview explains the game plan and card composition.
- Continue to Pod. Choose Duel, Trio or Full pod, then set each opponent's deck and play style. Seat previews show the selected commander, or a card back for random choices. Difficulty is beside the roster on desktop and below it on phones; presets and extra table options expand when needed. Review the table before starting.
- Keep or mulligan your opening hand. Use the available action buttons to play lands, cast spells, activate abilities, and pass priority.
- Combat responses + before my turn is the default priority profile: it waits when you have a legal response during combat or the end step immediately before your turn. Empty windows pass automatically; opposing nonland cards still wait for Proceed. Change the profile under MENU → Priority stops; previously selected profiles remain saved. HOLD arms a stop at the next priority window. Click controls remain available alongside optional drag controls.
Decisions and result reviews
After effects: routine searches and smaller changes appear in a compact panel beside the permanent they changed, which is outlined on the table (or on its controller's board when no changed card is visible); phones keep the corner sheet. Short effect notices about a card on the table, such as counters or a granted ability, appear as a callout beside that card. An opponent's spell or ability waiting for your response stays in the decision panel on the right, which outlines its source card (or the caster's board) on the table; Details & stack expands the full explanation. Board wipes, large damage and major shifts receive a central spotlight with prominent artwork and actual impact totals. Both wait for Proceed. Reviews show the source, actual damage and life changes, permanents that left or survived, and stack objects still waiting to resolve. Chaos Warp always shows its revealed card and outcome, including lands and nonpermanent cards that stay on top of the library. Library searches show the cards found and their destinations; a tutor that does not reveal its selection keeps the identity private from opponents. These reviews also work with reduced motion and fast playback.
Manifest / manifest dread: when a face-down creature can be turned face up, its battlefield card shows TURN FACE UP and the main-phase action panel offers a button with the payment cost. Card details explain unavailable payments. A manifested creature card can turn face up for its mana cost whenever you have priority; a noncreature cannot use that payment. This is a special action, so it does not use the Stack or trigger enters-the-battlefield abilities. Local AI evaluates the revealed creature and can use Overgrown Zealot's dedicated mana for this payment.
The arena includes card inspection, searchable zones, a game log, combat assignments, priority settings, and desktop/mobile table views. Judge and Last Resort provide manual actions and emergency state corrections when you need to repair a game; Politics adds optional enforced negotiations.
Selective recaps explain opponents' less obvious results, such as a fetch land's destination, reanimation, blink, or a change of control. Ordinary casts, small token batches, and small life changes continue without an extra recap. Board wipes and other major outcomes get one highlight with the actual result, up to three key changes, and a collapsible full breakdown. Pending triggers remain visible as pending; Proceed resumes play at your pace. Your own routine searches do not interrupt you, and opponents' unrevealed cards stay private.
Dungeons and target selection
Dungeons & routes appears in Deck Spotlight for built-in and imported decks with dungeon or initiative cards. Before playing, browse Lost Mine of Phandelver, Dungeon of the Mad Mage, Tomb of Annihilation, and Undercity, with every room's effect and connected paths. During a venture decision, preview a dungeon or select a highlighted legal next room, then confirm entry. The dungeon button beside a player's life area opens their map, including their current room, visited route, next exits, and completed-dungeon count; Game menu → Dungeons & routes is always available. Maps explain initiative and the entry restriction for Undercity. Progress survives Solo saves and is public in Live, including for opponents. Older saves show the current room and record the route from that point onward.
Target choices show the source card, the full current instruction, and progress such as Target 1 of 2, with earlier choices listed on the next step. When eligible cards are in a graveyard, exile, or the command zone, the decision panel offers a direct Open button. Relevant graveyard/exile controls are marked CHOOSE, and legal cards are highlighted inside the zone. Select a card, then confirm it in the decision panel.
Table views and combat
Solo players and all Live players use the Command Table interface. Table shows the opponents together; Focus gives a selected opponent more room. The decision panel keeps the current action visible, and target/combat choices reveal the relevant players. Live hosts and guests share the same gameplay controls, including HOLD, mana selection, card actions, Stack responses, combat and Last Resort. Each player sees their own hand and chooses their own priority and display preferences. The landing-page Table/Focus preview shows screenshots of the interface; it does not start a game.
Commander dock: your commander has a separate panel to the left of your hand, with a raised card and gold aura while in the command zone. Hover it to bring the card forward and show the large card preview; click or tap it to open its actions. After it leaves, the panel shows its location and keeps its space; partner commanders each have their own card. The Ring remains beside the hand tools. System and in-game Reduced motion turn off the tilt and animated aura.
Confirmed attacks send brief ember trails toward their declared defenders, and declared blocks raise blue guards toward the attackers they meet. Before combat damage, a Combat damage banner frames every fight (attackers ember, blockers blue) and marks each clash; the hits then land one after another, and the table pauses on the marked damage before dying creatures leave. Casting an instant adds a cool pulse toward the Stack and shows the chosen spell's name. These effects describe the declaration, cast or damage that the engine already decided. They leave controls usable and follow both reduced-motion preferences.
Lands · Mana column: tapped copies of the same land share one pile with a count (two Swamps tapped for {B}{B} read as one ×2 stack); untapped lands keep their own cells. Every copy in a pile stays individually clickable, and a pile opens up while one of its lands is a legal or chosen target.
Deck sleeves: every deck at the table has its own card back. The design chosen in Menu → Appearance → Card backs (Obsidian, Astral or Ember) is the frame; the deck's colors tint its stone and its commander (partners side by side) fills the central medallion. Face-down cards, library reveals and face-down card flights show their owner's sleeve, which shows nothing that is not already public. The card back picker previews your sleeve and every seat's. Two copies of one deck get different frames, and random seats in setup keep the plain design.
Desktop combat on the battlefield: select your creatures, then click a defender's portrait, planeswalker, or name in the bottom dock. You can also choose the defender first, use All attack, or drag creatures directly to a defender. To block, select your creature and then an incoming attacker; attacker-first selection and dragging also work. Gold attack lines and blue block lines show desktop assignments. Attack, Block, or No attacks / No blocks confirms the declaration; selecting cards alone never advances combat. Clear resets the draft, and Details opens the full combat overview without losing assignments. The ordinary action dock is compact; stack reviews and target selection open a panel when needed.
Mobile Combat tab: attacks, blocks and attack reviews open automatically in Combat. Choose creatures from the scrollable list and a defender or incoming attacker above it, in either order. Each creature shows its assignment; Inspect opens its details without losing the draft. All attack, Clear, and the confirmation button stay below the list. You can inspect Mine, Table, or Stack and return to Combat with every selection intact. During the rest of combat, the tab shows the declared attacks and blocks. Landscape phones place targets beside the creature list.
Defending creatures in Combat lets you expand each opponent's public creature list before attacking. It shows current power/toughness, tapped state, combat abilities and marked damage, with direct card inspection. Life totals and planeswalker loyalty stay visible during combat. The untapped count describes the board; individual blocking restrictions still apply.
Attack targets show life or planeswalker loyalty, assigned attackers and their combined power. The attack heading totals the draft; blue selected creatures still need a defender, while gold marks assigned attackers. On phones, swipe the defender row to reach additional players or planeswalkers. These power totals describe the chosen creatures, not predicted damage after blockers and other effects.
Phones and tablets
On phones and tablets, the focused opponent follows the active player's turn. Tap another opponent to inspect their board until the next turn. Short screens show one battlefield at a time: Mine opens your board, and an opponent's seat opens theirs. Your turn brings your battlefield back automatically. Dense mobile battlefields scroll horizontally, with lands and mana sources below; landscape phones place the hand beside the board.
The mobile navigation has Mine, Table, Combat, and Stack. View all above your cards still opens a scrollable grid of your entire hand. Sort, inspect and play cards through their usual actions while the current decision stays within reach. Mine returns to your battlefield. In the phone deck library, Filters also opens sorting and the Grid/Compact layout choices.
Music, sound, and motion
Open MENU → Music & sound to choose among three background tracks, adjust music and effects independently, mute playback, or preview an effect. Short cues mark combat, dungeon rooms, counters, and spellcasting; major arrivals, damage, board wipes, and game endings have their own effects. Audio preferences stay in the current browser.
Browsers may require a click or tap before audio starts. Reduced motion is available for presentation, and commander entrances fall back to card art when it is enabled. Sound and cinematics do not change game decisions or card rules.
Automatic and manual mana
The arena's MANA button switches between automatic payment and choosing your mana sources manually. Automatic is the default; the preference is saved in your current browser. The same toggle and source picker are available in Solo and to every Live player. Each Live player's preference is independent; the host validates and applies their selected payment.
| Mode | How payment works |
|---|
| Automatic mana | Choose your spell and its required decisions. The payment solver uses available pool mana, then prioritizes lands, then noncreature artifacts (including Treasure), then creatures. It checks the full payment for colors, restrictions, and activation costs before using a later group. Animated lands and artifacts count as creatures so they can stay available for combat. You do not need to pre-tap each land. |
| Manual mana | When your spell needs additional sources, a Choose mana sources dialog opens with a suggested selection. Choose the exact lands, mana rocks, Treasure, or eligible convoke/improvise sources you want to commit, then confirm. |
Choose sources manually
- Click MANA to enable manual mode, then choose the spell you want to cast.
- Complete any required spell choices, such as X, an alternative payment, or targets.
- In the mana-source dialog, review the displayed cost and the mana already in your pool. Pool mana is spent before the selected permanents are used for the remainder.
- Click source rows to select or deselect them. Tap selected sources ✓ becomes available when that exact selection can pay the cost. The solver still handles valid color allocation and source activation; selecting a permanent does not waive its restrictions or costs.
- Confirm the selection, or choose Use automatic mana this time to let the solver handle this payment without changing your saved manual-mode preference.
For example, to pay {2}{G} while keeping an Island available for interaction, select an untapped Forest and Sol Ring when those sources are legal and sufficient. If the selection cannot pay, adjust it or use the one-payment automatic option. A matching total alone is not enough: colored pips, required colorless mana, source restrictions, and activation requirements still apply.
The source picker is for human spell payments that need additional sources. It does not open when the pool already covers the cost, and the toggle does not add the same picker to every activated-ability payment. Mana creatures, restricted mana sources and utility permanents also expose Mana: … actions in their card details when you have priority and can activate them. For example, Somberwald Sage lets you choose one color and immediately adds three mana that can only pay for creature spells. Summoning sickness, tap costs and spending restrictions still apply in either mana mode. There is no general Undo/Clear-mana button. Floating mana is shown beside the player's information and normally empties when leaving the current step or phase, except where a card preserves it.
Automatic mana is separate from automatic priority passing. It pays for an action you chose; it does not choose your spell, dismiss required decisions, or disable HOLD. Hybrid, two-brid, and Phyrexian symbols can still ask you how to pay when multiple legal options exist—for example Pay {W}, Pay {2}, or Pay 2 life—in either mana mode. Use MENU → Priority stops to configure response windows independently.
Commander bounce and recasting
When an effect returns a commander to its owner's hand, its owner chooses Hand or Command zone. This also applies to mass bounce, including Cyclonic Rift cast for its overload cost. Solo AI prioritizes Hand on Easy, Normal, and Hard so it can cast the commander again without commander tax.
Commander tax adds {2} for each previous cast from the command zone, and applies only when casting from that zone. Casting from hand does not pay or increase that tax, and does not reset the count for future command-zone casts. For example, a commander with a printed cost of three mana and three previous command-zone casts costs three mana from hand or nine from the command zone, before other cost adjustments.
Import your deck
Build or edit your list in a deck builder such as Moxfield, then copy its plain-text export. On the home screen, open My Library, paste the list under Import your decklist here, and press Check decklist. Once validation passes, choose Save to My Library and select the saved deck to continue through Deck → Pod → Review.
The list must contain 100 cards including the commander or legal commander pair, and satisfy the engine's commander, color-identity, singleton, and card-support checks. Unknown, ineligible, or unsupported cards are reported before play; importing text does not implement new cards. The player UI accepts decklist text, not a Moxfield URL.
See the complete import guide for accepted formats, paired commanders, library persistence, Live sharing, and error recovery. Maintainer Oracle batch imports are a separate process described in the catalog guide.
AI archetypes and custom skills
The Commander AI Engine V2 uses deterministic local heuristics and bounded search. It combines a deck's strategic profile with an opponent style, difficulty, legal actions, and the visible multiplayer threat picture. It receives a restricted player view; it does not consult an external model service.
Build a pod with distinct opponents
In Solo → Pod, choose one to three opponents and set each seat's Deck and Play style separately. Bots can pilot a built-in precon or a supported imported list from My Library. The deck supplies the cards and strategic opportunities; the style changes how the bot values those opportunities. Advanced rules → Difficulty selects Easy, Normal, or Hard, changing search effort and decision tolerance without granting extra cards, mana, or access to opponents' hidden hands.
For example, you can give the same deck to an Aggressive and a Defensive opponent to compare how they use it, or mix three different decks and personalities. Random style assigns a built-in personality revealed during play; your installed custom skills do not enter that random pool.
Core archetypes
| Style | What to expect at the table |
|---|
| Aggressive | Builds attackers, applies early pressure, and hunts wounded opponents. Prefers keeping its attackers over making defensive trades. |
| Opportunist | Looks for exposed or weakened players, preserves a useful attack, and avoids unnecessary confrontation with the strongest seat. |
| Defensive | Develops resources, keeps blockers, values protection, and waits for a worthwhile attack. |
| Saboteur | Disrupts other players' plans, redirects pressure, and values political or goad effects when its cards actually provide them. |
| Balanced | Weighs development, combat, safety, and interaction without one of the stronger core tilts. |
Command Zone signature styles
The Command Zone signatures group offers five more detailed personalities inspired by public Commander play. Each has its own development priorities, situational behavior, and preferences for political deals. These are implemented game policies, not exact recreations of real people or an affiliation with The Command Zone. Their portraits and short reactions identify the chosen style; the reactions are game-written flavor text.
| Signature style | Game plan | Political preference |
|---|
| Jimmy — Aggressive Pressure | Develop the commander and supporting board, attack open lanes, then switch from steady pressure to a race or a decisive all-out attack. Protect a promising winning line. | Accept a temporary reprieve when it creates room to apply pressure; preserve the route to its own win. |
| Rachel — Balanced Tablecraft | Build flexible value, read threats across the whole table, keep defensive answers, and recover or finish when the position calls for it. | Address shared threats and make room for development; judge an offer in the context of the whole board. |
| Post Malone — Opportunist Showstopper | Accumulate cards while keeping a low profile, use theft/copy opportunities supplied by the deck, take calculated risks, and turn the setup into a strong finish. | Favor survival deals and useful cooperation against a shared threat while keeping future opportunities open. |
| Olivia — Saboteur Instigator | Probe safe attacks, misdirect pressure, disrupt the public leader, and exploit an opening with a calculated ambush. | Favor precise short deals, pressure the shared threat, and look for ways to weaken opposing cooperation. |
| Josh — Defensive Value | Develop mana and repeatable card advantage, preserve interaction, put shields up under threat, and convert a stronger resource position into a win. | Favor exact, short exchanges and cooperation against a shared threat. |
These preferences rank legal actions available in the current game. An aggressive bot still has survival checks; a theft-focused style cannot steal a permanent without a suitable card; a political style cannot force another player to accept an offer. All five operate within the same agreement rules when Diplomacy & Politics is enabled. They can also be used with Politics off. In Commander Live the host can fill empty seats with local AI bots, which always use the balanced style, so the other opponent styles are Solo features.
Add your own AI skill
- Open Solo → Pod → Upload / manage custom AI skills.
- Download the JSON template, or copy the creation prompt and describe the opponent you want to an assistant of your choice.
- Upload or paste the completed JSON and choose Check skill.
- Review the validated settings and choose Save skill.
- Select the saved entry under Your custom skills for an opponent, then continue to Review.
Skills use the commander-ai-skill/v1 declarative JSON format. They can build on a core or signature style and tune supported preferences for resources, combat, interaction, and card roles. Uploaded JavaScript and free-form instructions are not executed. Saving a skill does not automatically assign it to a bot; the library holds up to 20 skills in the current browser, and JSON export lets you back them up or share them.
Diplomacy & Politics
Diplomacy & Politics adds structured, public agreements to Solo Commander. You can negotiate with bots, receive their offers or counteroffers, and watch bots negotiate with each other. Accepted terms affect the actions a player may voluntarily take, and the table keeps a visible record of proposals and active agreements.
Enable negotiations and make an offer
- Build a Solo pod with at least two AI opponents: negotiations need three or four active players.
- In Pod → Advanced rules, enable Diplomacy & Politics and confirm the setting in Review. It is off by default and is disabled in Commander Live.
- Ordinary negotiations unlock once every active player has started their third turn. Open Deals, the mobile Politics control, or Game Menu → Diplomacy & Politics to see the unlock status, incoming offers, agreements, and recent table negotiations.
- Choose Make offer beside an opponent. Select a concrete request and a concrete promise in return; the composer offers terms that can be measured against the current board.
- Read the response. A bot can accept, decline, or return a counteroffer. A counteroffer is a new proposal requiring your decision, not an automatic acceptance of revised terms.
The normal offer allowance is two proposals per table round, with at most one to the same opponent. Repeating a rejected offer without a meaningful board change is blocked. Ordinary diplomacy ends when only two players remain.
The offer composer provides Combat truce, Hands off, Protect a card, Let it resolve, and Pressure the leader starters when their terms are available on the current board. Adjust the exact promises below, then read the named participants and expiry in the contract preview. The same rules used when sending check whether the proposal is currently allowed; previewing spends no offer allowance and does not predict the bot's answer. Incoming offers and signed agreements receive short visual cues, with both system and in-game Reduced motion respected.
What a deal can promise
| Promise | What it actually covers |
|---|
| Do not attack | The promising player's next combat against the named player. It is not an indefinite alliance. |
| Do not harmfully target a player or their permanents | Voluntary harmful target choices through the promising player's next turn. It does not grant protection from every effect that can affect the board. |
| Leave a named permanent alone | Harmful targeting of that specific permanent through the promising player's next turn. |
| Let a spell resolve | The promising player will not counter or harmfully target that specific object on the Stack. Other players can still respond, and the spell still follows its ordinary resolution rules. |
| Pressure the runaway threat | Make a tactically sound attack on the identified leader during the next combat, if such an attack remains available. An attack that simply loses an attacker to a free block does not count as a useful opportunity. |
A typical exchange is: “Do not attack me in your next combat; in return, I will not harmfully target your named engine through my next turn.” The game evaluates the actual board and the scope of both promises. A harmless-looking promise is not automatically equivalent to a valuable protection clause; a bot can reject an unequal exchange.
Read every negotiation before play continues
Negotiations pause the game for human review, including your outgoing offer's result and bot-to-bot deals. When an offer is addressed to you, choose Accept offer, Accept counteroffer, or Decline. For a completed negotiation or a deal between bots, review the terms and click Proceed. There is no response timer, and bots do not advance the game while that review is pending.
The Politics panel separates Awaiting your decision, Active agreements, and Recent table negotiations. Follow the named players, target, and expiry on each term rather than assuming a deal protects you for the rest of the match. Successful agreements can improve rapport, but the AI still evaluates its own survival and winning chances.
Table deals, Last Stand, and public votes
- Three-player table removal: with four players still alive, three nonleaders can coordinate an answer to the runaway leader's named nonland permanent. One player announces an available removal spell and target; the other two offer short protection in return. The removal player must still pay for and cast the spell. That promise is fulfilled by casting it at the agreed target, so a later counterspell or changed game state can still prevent the removal from succeeding.
- Last Stand: after the ordinary unlock, a player with public danger signals can ask for amnesty through the rescuer's next turn in exchange for a larger commitment: a two-turn pledge not to attack or harmfully target the rescuer or their permanents, or an attack on the runaway threat during each of the next two combats whenever a sound attack exists. Last Stand allows two requests per table round, at most one per opponent, separately from the two ordinary offers. Bots initiate at most one Last Stand across the table per round, approach players with a threatening public board, and check another bot's willingness before presenting the negotiation. Declined deals stay closed until the public board meaningfully changes. A runaway leader cannot use Last Stand. Amnesty restrains future choices; it does not undo attacks already declared or effects already on the stack, and it does not guarantee survival.
- Public vote bargains: supported public voting effects can offer a short promise in return for a specific vote. These contextual campaigns can appear before the ordinary third-round unlock when Politics is enabled. Accepting commits that public vote; declining leaves it free. The campaign also commits its sponsor's vote and can secure at most one other player's ballot. Each ballot counts normally, and the card's printed rule determines the result of a tie, including on Galadriel, Elven-Queen, Sail into the West, and Plea for Power.
Uncommitted AI ballots favor their tactical choice while giving other legal options a chance, including Dominion for Galadriel. The variation follows the game's seed for reproducible decisions. Accepted vote promises remain binding.
How agreements interact with Magic rules
Ordinary agreements are short and specific. There are no permanent alliances, secret-vote bargains, open-ended favors, or promises to concede. The engine rejects conflicting or one-sided commitments, restricts buying protection for a runaway leader, and limits simultaneous combat-immunity agreements. The displayed Reciprocity Check is an estimate of benefit, cost, and promise scope, not a currency or a reward paid to a player.
Accepted terms constrain voluntary attacks and harmful target choices. Mandatory Magic actions can override an impossible promise without blame, and terms expire or become void when their conditions no longer apply. A named-permanent promise ends when that object leaves or changes controller; blinking it creates a new object. Attack pledges end if their target is no longer the runaway threat. A two-combat pledge still covers the second combat if the first has no sound attack.
A no-targeting deal protects the named player and their battlefield permanents. It does not stop a nontargeted board wipe or counterspells aimed at their spells; a Let a spell resolve clause covers the named stack object. Helpful targeting, such as untapping a protected creature, remains available. Politics never grants a sacrifice action: sacrificing requires an actual spell, ability, cost or game rule. The old free-sacrifice tribute option is retired, and unpaid tribute agreements in old saves are voided for both players without a penalty. Politics remains an optional house-rule layer for enforced commitments; printed card mechanics and voting outcomes follow the same rules with it on or off.
Judge and Last Resort recovery
The game includes tools for manual card actions and extensive public-board correction when an effect needs handling or the game reaches the wrong state. Open MENU → Help & recovery in the full arena. Judge provides manual actions through the rules engine; Last Resort pauses the game and lets you set the intended public state directly.
Judge: perform card actions manually
The Judge → Manual card actions menu entry appears for an imported/custom deck or a pending manual card resolution. It is usable during your main decision or that manual resolution. A precon player needing emergency corrections can use Last Resort even when the separate Judge entry is absent.
The Judge toolbox lets you draw a card, deal damage, destroy or exile a target, return a card to hand, add +1/+1 counters, apply a temporary power/toughness adjustment, tap or untap, gain or lose life, add mana, return one of your graveyard cards to the battlefield, and create preset or simple custom creature tokens. Choose an action, enter its amount when prompted, then select the player or card it affects.
For a manual card resolution, the panel shows the card's instructions. Apply the intended effects, then use Done in the resolution controls to continue. Actions such as damage, destruction, life changes, and token creation use the normal engine helpers, so applicable prevention, replacement effects, and triggered abilities can matter. This tool does not make an unsupported decklist pass the import validator.
Last Resort: repair the board and resume
Use MENU → Last Resort → Enable & pause game for a direct correction. The engine pauses at its next safe checkpoint while you use the toolbox. Select EDIT PLAYER for player-level changes, then choose a visible card when a correction needs a target.
| Correction | What you can change in the full toolbox |
|---|
| Life and mana | Set a player's exact life total or the exact amount of one mana color in their pool. |
| Counters and damage | Set a named counter's amount on a permanent, or set its marked damage separately. Marked damage does not reduce printed toughness. |
| Tap state and control | Tap/untap a battlefield card or give control of it to the selected player. |
| Zones | Move an accessible card among battlefield, graveyard, exile, command zone, and its owner's hand. Public-zone browsers help you select the card. |
| Tokens and permanents | Add preset tokens, a simple custom P/T token with a supported keyword, or a known permanent by exact card name to the selected player's battlefield. |
| Battlefield order | Move a card left or right among its controller's battlefield cards. |
For example, if an effect left the wrong life total, a missing token, or a permanent under the wrong controller, pause recovery, set the life total, add the intended token, and correct the controller. Last Resort edits do not fire normal card triggers: they repair the resulting state, so adding a missing token does not automatically replay the triggers that would have accompanied its original creation. Each correction is recorded in the public game log.
Close toolbox · keep paused hides the controls while preserving the recovery pause. When the board is correct, choose Finish recovery & resume. Closing the toolbox alone does not resume the game.
Last Resort is also available in Commander Live. Hosts and guests use the same full arena toolbox for public corrections. Guest requests go to the host for validation and synchronization, and the table sees the resulting log. Corrections wait for acknowledgment before another correction is enabled.
Recovery preserves hidden-information boundaries: it does not reveal opponents' hands, libraries, or face-down identities, and it is not a library editor or a rewind to an earlier turn. It changes the listed game state rather than implementing new card abilities or repairing the underlying source code. If you encounter a reproducible problem, also keep a share-safe debug snapshot for the bug report.
Run locally
Use Git, Node.js 22 or newer, npm, and Python 3. Serve the repository over HTTP; opening index.html directly as a file:// URL is not the supported startup path. The frontend uses native browser ES modules. Local play needs no build; production runs npm run build to stamp the loaded version into diagnostic reports.
Windows PowerShell
git clone https://github.com/tuitamogamer-gpt/mtg-commander-simulator.git
cd mtg-commander-simulator
npm.cmd ci
python -m http.server 8000 --bind 127.0.0.1
Use npm.cmd if PowerShell blocks npm.ps1. The repository's npm run serve invokes python3; on Windows, use the working python command shown above instead of a Windows Store alias. If your Python installation exposes only the launcher, use py -3 -m http.server 8000 --bind 127.0.0.1.
macOS and Linux
git clone https://github.com/tuitamogamer-gpt/mtg-commander-simulator.git
cd mtg-commander-simulator
npm ci
npm run serve
Open http://127.0.0.1:8000/. Keep the terminal running; Ctrl+C stops this foreground server. Run commands from the repository root and repeat npm ci after dependency-lockfile changes.
Choose the right local environment
| Environment | What works | Additional setup |
|---|
| Python static preview | Guest Solo, local AI, deck import, and browser-local preferences | No Redis or API credentials |
| Full web application | Accounts, cloud saves, and Commander Live alongside Solo | Node API routes and Development Redis configuration |
| iOS bundle | Bundled Solo and a separate online view | iOS build instructions; a Mac for Xcode |
Python does not execute api/account.js or api/ws.js. For the full application, configure the Development environment from Deployment, then run vercel dev --listen 3000 (vercel.cmd dev --listen 3000 in Windows PowerShell). Use http://localhost:3000/ for that server.
Built-in deck artwork is bundled locally. Other catalog cards and unresolved alternate prints can use Scryfall image endpoints, with a card-back fallback, so imported decks may need internet access for artwork. npm run sync:card-images is an explicit asset-maintenance command, not a prerequisite for ordinary local play.
How the application works
| Area | Main files | Responsibility |
|---|
| Public entry | index.html, src/public-entry.js, src/modules/landing.js | Landing page, interface preview, and guide; load the heavy game modules when needed. |
| Rules and table | src/modules/engine2.js, src/modules/ui.js, src/modules/main.js | Legal decisions, stack resolution, combat, setup, and game presentation. |
| Command Table | src/modules/command-table.js, src/command-table.css, src/command-landing.css | Table/Focus presentation, player seats, decision panel, and matching landing design. |
| Card data | src/data.js, src/modules/oracle-catalog.js, src/oracle-batches/ |
In Solo, the browser owns the complete rules engine. In Live, the host browser owns it and publishes per-player projections through the room service. This is a trusted-host private-table model: the server validates room roles and decision contracts, but does not independently simulate every game rule or prevent a modified host from cheating.
flowchart LR
Solo["Solo browser: rules and local AI"]
Host["Live host browser: rules and full state"]
Guest["Live guests: individual player views"]
Rooms["Live API /api/ws"]
Accounts["Account API /api/account"]
Redis[("Redis")]
Host <-->|WebSocket| Rooms
Guest <-->|WebSocket| Rooms
Rooms <-->|Native Redis connection| Redis
Solo -->|Optional saves and library sync| Accounts
Accounts <-->|Redis REST| Redis
Accounts are optional in all modes; the Solo arrow highlights private checkpoint storage. Live players can also use account libraries and favorites. The deployment architecture describes these boundaries in more detail.
Vercel and multiplayer
The existing production project serves the static client and the APIs from the same origin. vercel.json defines security/cache headers and a 300-second duration for api/ws.js; the client reconnects its socket when necessary. Keep the original host tab open. A temporary connection drop preserves pending actions and decisions; the host can resume after everyone reconnects. A lost confirmation does not apply the same action twice.
Live room storage needs server-only REDIS_URL, KV_URL, or UPSTASH_REDIS_URL. Accounts use the REST pair KV_REST_API_URL / KV_REST_API_TOKEN, or UPSTASH_REDIS_REST_URL / UPSTASH_REDIS_REST_TOKEN. A Redis TCP URL and Redis REST credentials serve different integrations. Configure both for a deployment that offers Live and accounts.
See Deployment for exact commands, environment variables, custom domains, room expiry, local integration testing, and production checks. Never commit .env files, Redis credentials, cookies, or private room invitations.
iPhone and iPad app
The repository includes a SwiftUI home screen, a Capacitor/WKWebView Solo bundle, and a separate online view for the existing service. The project targets iOS/iPadOS 17+ and requires a Mac with Xcode 26+ for native compilation and installation.
npm ci
npm run ios:sync
npm run ios:test
npm run ios:open
Use npm.cmd for the package commands on Windows. Bundle preparation and JavaScript checks can run there; Xcode and device signing require a Mac. Run npm run ios:sync again after changing game source or assets. npm run ios:package prepares dist/commander-ios-mac.zip, an Xcode source project with the bundled game, not a signed app installer.
Bundled Solo can run offline; unbundled artwork needs a connection. Offline and online storage are separate, and Safari data is not imported automatically. A guest game is not a durable checkpoint. Keep a Live host active in the foreground because iOS can suspend background apps.
See the iOS guide for signing, simulator/device verification, exports, and packaging. The macOS workflow checks an unsigned simulator build; it does not publish to TestFlight or the App Store.
Saves, privacy, and troubleshooting
What is saved
| Data or feature | Guest / local behavior | Signed-in behavior |
|---|
| Imported decks | Stored in this browser and website origin | Owner-bound library synced through the account; up to 40 decks |
| Favorites | Browser-local preferences | Synced through the account |
| Custom AI skills and pod presets | Browser-local; export skill JSON for backup | Remain browser-local |
| Solo Save & Continue | One recovery checkpoint in this browser | One private cloud checkpoint, plus device recovery while a save is pending |
| Match history and lifetime statistics | No account history | Finished Solo wins award 100 points; losses award 25; retries do not count twice |
| Commander Live | Reconnect to a room with the original active host | Same room model; signing in does not add host migration or durable Live resume |
Guest and account deck libraries are separate; signing in does not silently merge them. Clearing site data or changing browser, device, or domain can remove access to local records. Keep original decklist text and exported skill JSON as backups. Read Data and account behavior for storage, retention, and current account limits.
Common problems
| Symptom | What to check |
|---|
npm is blocked in PowerShell | Use npm.cmd for the commands in this guide. |
python3 opens the Windows Store or cannot be found | Use python -m http.server 8000 --bind 127.0.0.1, or the py -3 launcher. |
| Local Solo works but sign-in or Live fails | A Python server serves static files only. Configure the API environment in Deployment. |
| An imported list is rejected | Paste decklist text, then fix the reported size, commander, color-identity, singleton, or unsupported-card errors. A deck-builder URL is not a decklist. |
| Cards show a fallback image | Unbundled artwork needs a network connection. Card-image availability and rules support are separate. |
| Play is waiting | Check the decision panel, Stack review, negotiation, HOLD/priority stop, or recovery pause. Confirm the pending action; use Finish recovery & resume after Last Resort. |
| Live loses its connection | Keep the original host tab active and allow reconnection. Use the visible Resume control when available; a closed or refreshed host cannot be replaced by another player. |
| A saved deck seems missing | Check the account, browser, and website origin. Guest and account libraries are separate. |
| A debug import starts at turn one | Public snapshots reproduce setup. Use Open problem replay for a report with recorded Solo decisions, or Continue for a saved game. |
Report a reproducible bug
Game Menu → Report a problem captures the current Solo checkpoint, recorded choices, and loaded game version. Add a description and download the report; nothing is sent automatically. Include Solo replay attaches all saved cards and choices, including hidden cards. Uncheck it for public diagnostics only. Live reports contain public diagnostics only.
Player Auras such as Curses show Enchants: player name on the battlefield card and in its details. This is the player affected by the Aura; the battlefield heading names its controller. If an effect appears to affect the wrong player, include the affected creatures' names in the problem report.
Open a downloaded Solo report under Setup → Support & Diagnostics → Open problem replay, then choose Start diagnostic replay. It restores the checkpoint and replays recorded decisions without replacing your normal save or updating profile statistics. A different game version can stop replay at a changed decision. A report captures completed decisions; it cannot restore an in-progress JavaScript call or guarantee reproduction of a timing-dependent failure.
The existing Download debug snapshot exports the public mtg-commander-debug/v1 format. Import debug snapshot restores its setup and seed from turn one.
Open an issue with:
- The card/deck names, game mode, browser, and device.
- Steps to reproduce, followed by expected and actual behavior.
- A problem report or screenshot when available; choose whether to include private Solo cards.
Review attachments before posting, especially an opted-in Solo replay. Do not publish room invitations, passwords, session cookies, or server credentials. Judge and Last Resort can help you continue a game after a rules issue; a bug report helps fix its cause.
Verification and release
Start with the syntax and baseline checks after installing dependencies:
npm run check
npm run test:baseline
On Windows PowerShell, substitute npm.cmd for npm in this section.
| Command | Purpose |
|---|
npm run check | Parse the JavaScript source and check syntax. |
npm run test:baseline | Check deck sizes, card definitions, commanders, and the built-in deck inventory. |
npm run test:focused | Run bounded regressions for pending UI decisions, AI simulation isolation, accounts, saves, combat, ninjutsu, and Suspend. |
npm test | Run the Node test suite for rules, AI, imports, accounts, and Live. Includes the long all-deck headless simulation. |
npm run test:ai | Run AI V2 checks and the headless deck simulation. |
npm run test:ai:unit | Run AI V2 unit checks without the all-deck simulation. |
npm run test:ai:games | Run the long all-deck headless simulation independently. |
npm run test:server | Run focused Live server, action replay, room lease, and reconnect tests with local test stores. |
npm run audit | Audit source and built-in deck coverage. |
npm run certify:strict | Run strict executable card certification. |
npm run benchmark:ai | Measure the AI workload. |
npm run ios:test | Check iOS web-package integration. |
The full suite can take substantially longer than focused checks. A stopped run is incomplete, even when earlier checks passed. Certification records project coverage; it does not prove every possible card interaction.
Browser acceptance scripts live in tests/browser. They require Playwright and its browser binaries separately; Playwright is not a project dependency. PLAYWRIGHT_MODULE can point to an installed playwright/index.mjs. The release guide lists the scripts and required gameplay, mobile, privacy, and reconnect scenarios.
node tests/browser/improvement-round.mjs checks a paid creature-type choice, keyboard search, and view recovery at phone and desktop widths. Set BROWSER_EXECUTABLE to an installed Chromium path when needed, ROUND_OUTPUT for screenshots and results, or GAME_URL=https://www.mtgpod.xyz to verify production behavior and compare its loaded application sources with the current checkout.
node tests/browser/decision-callbacks.mjs checks stale callbacks against a real paid Rolling Thunder split and sequential human choices. It supports the same browser/production variables; use DECISION_OUTPUT for receipts and screenshots.
node tests/browser/priority-actions.mjs checks paid reaction controls, retained callbacks, and keyboard input while Help is open. It supports the same browser/production variables; use PRIORITY_OUTPUT for receipts.
The focused account concurrency checks use a local redis-server when available. Set REDIS_SERVER_BINARY to its executable to run the real Redis/Lua checks. The helper uses a private Unix socket with TCP and persistence disabled; unavailable Redis is reported as skipped coverage.
For a public application release, follow PUBLIC_RELEASE.md, including:
npm run check
npm test
npm run audit
npm run certify:strict
npm audit --omit=dev --audit-level=high
git diff --check
Run the relevant browser flows, commit only intended files, and push the source revision. With the existing Git integration, check the automatic deployment for that exact commit before starting a manual deployment. Verify READY, the production alias, and the changed application behavior. An HTTP 200 or an old report does not establish that the current revision passed release checks.
Portable self-host archive
npm run package:public
This generates and integrity-checks dist/commander-simulator-public.zip, including the client, local artwork, source, tests, reports, and server modules. After extraction, use the local setup for guest Solo. Online features still require the configured APIs and Redis services.
Contributing
Use GitHub issues for reproducible bugs or focused feature proposals, and pull requests for changes. Describe the problem, the resulting behavior, and the checks you ran.
- Work on a topic branch and preserve unrelated local changes.
- Follow the existing module structure; use focused regression coverage for rules, AI, or synchronization changes.
- Run the checks relevant to the change and document any incomplete validation. Use the release guide when publishing application behavior.
- Update the appropriate player or developer guide. For card imports, retain source provenance and executable verification, then regenerate the catalog using its pinned source.
Keeping this README current
Use package.json for runnable commands, src/data.js and the baseline checks for the deck inventory, and docs/catalog/summary.json for catalog counts. Keep runtime definitions, deck-import eligibility, and distinct Oracle IDs separate. Date inventory claims and link to the report that supports an addition.
Keep quick-start instructions near the top, use repository-relative links, and put large reference tables in expandable sections. Before publishing, preview headings, links, tables, images, and the architecture diagram on GitHub. The format follows GitHub's README guidance and collapsed-section documentation.
Documentation index
| Guide | Contents |
|---|
| Deck import | Accepted formats, commander pairs, validation, and My Library |
| Card catalog | Supported/remaining cards, provenance, and inventory regeneration |
| AI archetypes | Core styles, signature personalities, and deck plans |
| Custom AI skills | JSON schema, examples, validation, and installation |
| Example custom skill | A concrete skill JSON to inspect and adapt |
| AI engine architecture | Decision pipeline, legal actions, evaluation, and search |
| Deployment | Local APIs, Redis, Vercel, domains, and operational checks |
| Data and accounts | Local/cloud storage, sessions, retention, and recovery limits |
| iOS app | Mac build, signing, offline/online behavior, and device acceptance |
| Public release |
Catalog and import history
These reports describe their dated imports and checks. Use the generated catalog for the current inventory; historical counts should not be added together to calculate present coverage.
Current limits
- Only cards accepted by the catalog and deck validator can be imported. New sets and unsupported mechanics require implementation and verification.
- Live is invite-only, its local AI bots always use the balanced style, and it requires a trusted host whose game tab stays open. There is no public matchmaking, host migration, or durable midgame Live restore.
- Browser-local guest lists, skills, and pod presets do not automatically follow you to another device or domain.
- Account password reset/change, email verification, and self-service account deletion are not implemented. See account behavior for current retention and recovery limits.
- Passing tests covers the documented scenarios; a large imported catalog does not establish exhaustive multiplayer interaction coverage.
AI tools used for this project
- Claude Fable 5.1
- ChatGPT 5.6 Soul
- ChatGPT 6 Astra
Fan project notice
Commander Simulator is unofficial Fan Content permitted under the Wizards Fan Content Policy. Not approved/endorsed by Wizards. Portions of the materials used are property of Wizards of the Coast. ©Wizards of the Coast LLC.