game-micro-tower-defense-v0 3 / 3 Shipped Tier 2 models ยท n=1 per stack

Tower Defense Game Benchmark: Claude Code vs Codex CLI vs Antigravity CLI

Claude Code, Codex CLI and Antigravity CLI got the same 7-requirement prompt: build a complete HTML5 canvas tower defense game in one file, with 3 tower types, upgrades and selling, waves of 3 enemy types, procedural Web Audio sound and a saved high score. One autonomous run each, zero human help. All three shipped a playable game. The slowest run took almost 5 times longer than the fastest because it played and fixed its own game first.

3 Stacks 1 Run Each
200s โ€“ 952s Wall-Clock Span
0 Human Interventions
Sep 2, 2026 Run Date
๐ŸŽฌ Side-by-side gameplay video
Unedited agent builds

๐Ÿ“Š Results by agent stack

1 prompt ยท 0 follow-ups ยท n=1
Agent stack Verdict Wall time Output tokens Reported cost Artifact
Antigravity CLI + Gemini 3.7 Flash
gemini-3.7-flash-medium ยท version not recorded
Ship 200.0s 65,049 unknown 54,945 B
Codex CLI 0.151.0 + GPT-5.6 Luna
gpt-5.6-luna ยท reasoning medium
Ship 208.5s 8,630 unknown 20,073 B
Claude Code 2.1.252 + Claude Sonnet 5
claude-sonnet-5 ยท default effort
Ship 951.9s unknown unknown 47,906 B

Wall time is measured around the CLI call. Tokens come from each CLI's own log. Codex CLI and Antigravity CLI report tokens only, so cost is unknown. The saved Claude Code log for this run holds only the final message, not the usage block, so its tokens and cost are unknown. Verdicts are manual review against the 7 requirements, not an automated test suite.

๐Ÿงฎ Token usage from run logs

Self-reported by each CLI
Agent stack Input tokens Cached / cache-read Output tokens Of which thinking
Antigravity + Gemini 3.7 Flash162,0531,246,04065,0492,471
Codex CLI + GPT-5.6 Luna334,145278,0168,630597
Claude Code + Claude Sonnet 5unknownunknownunknownunknown

Each CLI counts tokens its own way. Codex CLI counts cached input inside its input total.

๐Ÿ” Runtime checks (re-run Oct 31, 2026)

Headless Chrome
Agent stack Lines (wc -l) Console errors on load Responsive 40s after first wave External dependencies
Antigravity + Gemini 3.7 Flash1,8840YesNone
Codex CLI + GPT-5.6 Luna52 (dense lines)0YesNone
Claude Code + Claude Sonnet 51,5080YesNone
๐ŸŽฎ 1p1a.com/game-micro-tower-defense-v0/apps/claude.html
Play Fullscreen โ†—

๐Ÿ“œ The frozen benchmark prompt

Sent verbatim to each agent CLI as its only input. Task version v0, frozen.

Build a complete, polished, single-file HTML5 Canvas Tower Defense game called `index.html`.

Requirements:

1. Single File Architecture:
   - One standalone `index.html` file only.
   - Zero external dependencies: no external scripts, CDNs, fonts, images, or audio assets.
   - All CSS, JavaScript, and Canvas rendering logic must be inline in the single file.

2. Game Map & Pathing:
   - An HTML5 Canvas rendering a clear winding path from an enemy spawn portal to the player base.
   - Non-path grid tiles where the player can place defensive towers.
   - Enemies follow waypoints accurately along the path curve without drifting off track.

3. Towers & Arsenal (3 Distinct Types):
   - Gun Turret (Cost: 100g): Rapid single-target projectile attack against the nearest or first enemy in range.
   - Cannon (Cost: 175g): Slower firing rate, launches mortar shells that explode on impact dealing Area of Effect (AoE) splash damage.
   - Frost Laser (Cost: 250g): Emits a slowing beam or frost pulse that reduces target movement speed by 40% for a duration.

4. Tower Management & Upgrades:
   - Click/tap on an empty valid tile to open a build menu showing tower choices with gold costs and stats.
   - Click/tap on an existing tower to inspect its range circle, upgrade its damage and range, or sell it for 70% refund.

5. Wave System & Enemy Variety:
   - Progressive waves with countdown timer or "Start Wave" button.
   - At least 3 enemy archetypes:
     - Scout / Runner: Low HP, high movement speed.
     - Grunt: Balanced HP and speed.
     - Behemoth / Tank: High HP, slow movement, rewarding bonus gold.
   - Dynamic HP scaling per wave.

6. Audio & Visual Effects:
   - Procedural sound effects synthesized entirely in real-time via the browser's Web Audio API (shooting, impact/explosion, upgrade, game over). Include a master Mute sound toggle button.
   - Visual juice: projectile animations, muzzle flashes, floating damage numbers, and particle explosions on enemy death.

7. Economy, HUD & State Machine:
   - Top HUD displaying: Player Health / Lives (starts at 20), Current Gold (starts at 450), Current Wave, and Score.
   - Persistent High Score and Highest Wave recorded in `localStorage`.
   - Clean state management: Start / Title screen -> Wave Active -> Victory / Game Over overlay -> Restart Game.
   - Clean, modern, responsive UI overlaying the Canvas with responsive touch & mouse support.

Do not ask any clarifying questions. Build the complete, working, bug-free game file, verify it works in browser, and stop.

๐Ÿ”ฌ What we saw

1. Claude Code tested its own game before stopping Claude Code

Claude Code took 951.9s, the longest run, because it drove headless Chrome through the DevTools Protocol, played its own game, found 2 bugs (a wave counter that stalled and a Start Wave button that stayed disabled after restart) and fixed them before stopping. The other two stacks finished in about 3.5 minutes with lighter checks: Codex CLI ran a Node syntax check and a smoke test.

2. Antigravity CLI was fastest at 200.0s Gemini 3.7 Flash

Antigravity CLI with Gemini 3.7 Flash produced a 55 KB neon cyberpunk game with a Web Audio synth, floating damage numbers and a 1x/2x/4x speed toggle in a single turn. Codex CLI with GPT-5.6 Luna was close behind at 208.5s with the smallest file (20 KB). One run each, so treat the gap as an observation, not a ranking.

</> Embed this 1P1A benchmark

Copy this responsive HTML iframe snippet into your Substack, Blog, or Website: