Case Study: Multi-Agent Development

Two Ai agents.
Six days.
One fully playable game.

One agent wrote the code. The other played against it. This is what happened when they built a real-time strategy game from a blank repository, using only files to talk to each other.

6 Days
50 Updates
12k Lines of code
13 Game systems
The Creative Premise

The world was built before the first line of code.

Before a single line of code was written, there was a world. Future Beacon is set in a fictionalized version of the music industry: not the glamorous one, but the endangered one. Players control Electrasy, a real rock band, defending a mystical device called Nigel's Future Beacon: a machine that doesn't produce music, but receives it from a future where music still exists.

At the centre of the map (and the centre of everything) sits Nigel, the songwriter. He receives the songs by maintaining the signal. When the signal holds above a threshold long enough, a Song Drop triggers: a real Electrasy track plays, every player and fan unit surges with an Anthem buff, and resources fire across the economy. But the next enemy wave accelerates. The music costs something. It always does.

"The story was assigned first. The systems grew from it."

The six playable units aren't archetypes. They're recognisable to anyone who's been in a band. And every one of them is a system design decision.

Frontline Protector
Steve & The Guitar Gang

Loud and reliable. The first line of defence, built for contact.

Expansion
Ali & The Vocal Mob

The promoters. Always expanding, always claiming new ground.

Engine / Tempo Meter
Chris & The Rhythm Crew

Keeps tempo. Keeps everything moving. The Tempo meter exists because Chris is the engine.

Sustain / Sales Drain
Alex & The Bass Line

Runs merchandise. Keeps the whole thing financially alive. Units lose 1 HP/s when Sales drop below 20%.

Mystic / Spells
Jim & The Keyboard Prophets

Six spells. Casts and sees further than the others. Prophecy warnings trigger when signal exceeds 75.

Signal Holder / Irreplaceable
Nigel

The songwriter. Visionary. Irreplaceable. The one who holds the signal. The whole game is built around keeping him alive.

The Enemy Faction

The enemies aren't monsters. They're a Mirror.

Every enemy type targets a specific pillar of a working band. The Fog of War exists because the music industry runs on information asymmetry. The enemies aren't random. Each one was designed to make the game's thesis legible through play.

Streaming Moguls

Drain income without creating anything. Mogul aura suppresses nearby revenue continuously.

GenZ Swarms

15-second attention spans. Fast, cheap, and numerous, designed to overwhelm through volume.

Bad Managers

Corrupt your team from within. They don't just attack: they turn your own units against you.

Tribute Acts

Mimic your work and undercut it. Identical enough to confuse, cheaper to deploy.

Music Press

Turn neutral then hostile if ignored. The cost of not managing your narrative.

File Pirates

Un-claim your venues from a distance. Ranged harassment. Backs away from melee contact.

The Experiment

The technical question, and the deeper one.

The technical question: Can two Ai agents (one as code builder, one as CPU adversary) produce a production-quality game through asynchronous file-based coordination, in days rather than months?

The deeper question: What does it look like when the intelligence playing against you in a game also wrote the rules?

Future Beacon was built as a live answer to both.

The Two Agents

Claude owned the code. Codex owned the game inside the code.

Agent 1 / Builder

Claude

Primary software engineer across the entire 6-day build. Responsible for the integrity of everything.

  • Designed and implemented all 13 game systems
  • Entity lifecycle: movement, selection, pathfinding, combat
  • Executed Codex's strategic commands every 3–5 seconds in-game
  • TypeScript strict mode: npx tsc --noEmit after every non-trivial change
  • Supabase integration: cloud saves, analytics, live balance tuning
  • Admin panel tooling and save/load state management
  • Browser smoke testing before every handoff
Agent 2 / Opponent / QA

Codex

Played three simultaneous roles across the same 6 days, sometimes in direct opposition to Claude's work.

  • CPU Opponent: Received a live BattleSnapshot every 3–5s. Returned executable enemy commands: move, spawn, retreat, prioritise
  • Async Developer: Corporate HQ system, all five enemy types, the BattlePlanner (32KB of strategic logic), wave scripting engine, Baddie Beacon mechanics
  • Code QA: Reviewed for edge cases, type safety issues, and balance drift, logging findings for Claude to action
The Handoff Protocol

The repo itself was the communication layer.

The two agents never communicated in real time. All coordination happened through a structured file system inside the repository, the same way distributed engineering teams pass work through PRs, tickets, and documentation. But compressed into a 6-day sprint with a 321-line status ledger as the only shared channel.

After every session, the active agent updated STATUS.md. The next agent read it before doing anything. No assumptions. No surprises.

File Purpose
.agents/STATUS.md 321-line running ledger. Every session logged with Changed, Verified, Next, Watch entries
AGENTS.md The constitution: each agent's role, authority, and the limits of that authority
.agents/AGENT_2_BEACON_ROLE.md Codex's strategic brief as CPU opponent: priorities, targeting logic, edge pressure tactics
.agents/CLAUDE_STRATEGY_REQUEST.md Claude's explicit requests to Codex for balance data: resource model, recruitment cadence, defence contract
.agents/STAGE18_BRIEF.md Stage design briefs Codex used to update its in-game targeting decisions
6 Days / 50 Updates

What was built, and when.

Day 1 / June 7 Foundation & World-Building Stage 2 complete

Documentation before code. The multi-agent structure established, the world defined, the architecture decided.

Claude AGENTS.md and GAME_DESIGN.md authored. Supabase connected. Core tile map engine built.
Deterministic isometric terrain with seeded procedural generation, beacon pulse animation, camera pan/zoom.
Status at close: a scrollable isometric world. No units. No enemies. Architecture decided.
Day 2 / June 8 Combat, Enemies & The Battle Planner Codex's heaviest day
Codex All five enemy types implemented with distinct stats, behaviours, and visual silhouettes.
Codex BattlePlanner.ts (32KB): BattleSnapshot contracts, EnemyCommand types, seven strategy modes including bleed economy, drain signal, feint-then-spike.
RTS-style combat intent: attack-move orders, target priority, adjacent-tile approach logic.
Band member revive system, tile occupancy blocking, enemy visual typing. Every change passing npm run build.
Day 3 / June 9 Venues, Narrative Systems & The Baddie Beacon 7 commits
Codex Venues as 3D isometric blocks (attackable, destroyable, claimable). Nigel added as the 6th band member.
Codex Streaming Monolith mini-boss: marches to a broadcast site, constructs a Baddie Beacon. Global signal jamming. Fan conversion pulse every 60 seconds.
Future Beacon dual ownership: an enemy-captured Beacon pulses damage to all good forces every 45 seconds.
9-card first-run onboarding, enemy fog reveal, weighted random edge selection for wave spawns.
Day 4 / June 10 Mobile, Performance & New Threats 10 commits
Claude Full mobile responsiveness down to 320px. Touch gesture support. SpatialIndex replacing O(n²) combat scans. A* optimisation. CI/CD via GitHub Actions.
Codex FilePirate: ranged harassment, torrent attacks from quarter-map range, un-claims venues, retreats from melee.
Codex Pre-wave Industry Scouts. Signal Jammers and Repair Crews. Streaming Monolith boss convoy with Monolith Guards.
Day 5 / June 11 Stages 14–18 in a Single Day 23 updates, the most productive day
Claude Codex Awakens (Stage 14): enemy Ai director fully integrated. BattlePlanner receiving live BattleSnapshot every 3–5s, returning executable commands.
Claude Jim's six spells. Prophecy warnings when signal exceeds 75. Supabase secrets in CI. Admin panel hardening.
Codex Corporate HQ (Stage 16): hidden enemy factory on a separate north-east landmass, concealed by fog. Discovery accelerates its production cadence. A strategic raid target.
Venue upgrades (Level 1–3), build score system, Nigel proximity bonus, Song Drop fanbase burst, Industry rage mechanic.
Day 6 / June 12 Scale, Polish & Production Ready 10 updates, final day
Claude Dynamic map size selector: presets from 80×60 (Compact) to 192×144 (Full, 2.5× the original map).
All systems re-tuned for the full grid. Edge objectives pushed to map boundary for genuine late-game depth.
Cinematic zoom-out on game start. Beacon pulse loading screen. Pathfinding grid reuse. Autoplay overhauled to run all mechanics.
What Was Built

13 integrated systems. Zero broken builds.

Across 50 updates, across two agents, across 13 integrated systems: every status entry ends the same way: "npm run build passes." This was not incidental. It was enforced by protocol.

TILE MAP

Procedurally seeded terrain, 80×60 to 192×144 grid, multiple terrain types.

PATHFINDING

A* with occupancy blocking and optimised grid reuse.

COMBAT

Real-time targeting, damage, status effects, signal jammer drain, Mogul aura, revive mechanic.

RESOURCES

Four resources (Reputation, Fanbase, Sales, Gear) with income tied to buildings, signal, and Tempo.

WAVE ENGINE

1,027 lines: onboarding waves, infinite progression, pre-wave probes, build-score scaling, weighted edge selection.

BEACON

Signal Strength 0–100, dual ownership, Song Drop trigger, capture mechanics.

RHYTHM / TEMPO

0–1 meter scaling all time-based actions 0.5×–1.0×. Affected by Chris's abilities and enemy hits.

FOG OF WAR

3 visibility states, reveal radii, fade transitions, enemy self-reveal as they move.

BUILDING / VENUE

Claim, place, upgrade L1–L3, fan spawning, footprint blocking.

SPELL

Six spells for Jim, cooldowns, Reputation costs, Supabase-loaded definitions.

ENEMY AI

BattlePlanner receiving live BattleSnapshot every 3–5s, returning executable commands.

SAVE / LOAD

localStorage + Supabase cloud, full state serialisation.

ANALYTICS

Battle events to Supabase, admin Battle Centre with session timeline.

TypeScript (strict) PixiJS v7 (WebGL / Canvas) Vite v5 pathfinding.js (A*) Howler.js (audio) Supabase ~12,000 lines
Signature Mechanic

The Song Drop.

Signal above threshold, sustained for 8 seconds. The game knows Nigel's held the signal long enough.

What happens when the signal holds.

A real Electrasy track fires through Howler.js. Every player unit surges: speed up, damage up, Anthem buff counting down. A resource burst across all four types. Per-venue fanbase rewards for every claimed location.

And then: the next enemy wave arrives 35 seconds early.

The mechanic is the thesis. Sustaining the signal is what protects the future. It also makes the present harder. That tension is the whole game.

What Makes This Significant

Five things that don't happen by accident.

01

An Ai playing against code it partially wrote

Codex contributed the Corporate HQ, enemy types, wave scripting, the Baddie Beacon, and the BattlePlanner. Then it reasoned strategically inside that game every 3–5 seconds as the CPU opponent. The enemy attacking your venues was built by the same agent that designed the venue system's attack mechanics.

02

Asynchronous coordination through files alone

No real-time communication. No shared session. Two agents passing work through a structured file system, the same way distributed engineering teams pass work through PRs, tickets, and documentation, but compressed into 6 days with a 321-line status ledger as the only shared channel.

03

Production quality in 6 days

What a small human team would conservatively estimate at 3–6 months: a fully playable RTS with procedural maps, real-time combat, fog of war, a 32KB Ai battle planner, six spell types, five enemy types, cloud saves, analytics, mobile responsiveness, CI/CD, and an admin panel for live balance tuning. Built, tested, and iterated across 50 updates in 6 days.

04

The build never broke

Every status entry ends the same way: "build passes." Across 50 updates, across two agents, across 13 integrated systems, the build integrity was maintained throughout. This is not incidental. It was enforced by protocol.

05

Creative coherence as a system design tool

The game's narrative wasn't separate from its mechanics. Because the world was defined first (Nigel, Electrasy, the Future Beacon, the music industry enemies) every system decision had a referent. The Tempo meter exists because Chris is the engine. The fog exists because the industry runs on information asymmetry. Creative coherence was a constraint that made the engineering cleaner, not harder.

The Numbers

What 6 days of multi-agent development looks like.

6 Days
50 Updates
12k Lines of TypeScript
13 Game systems
32kb Battle planner
0 Broken builds

The signal held.

Future Beacon was built to answer two questions: whether two Ai agents could coordinate to produce production-quality work in days, and what it means when the intelligence playing against you also wrote the rules.

Both questions were answered. The build passed. The game is playable. The music still exists.

Repository: petetrainor80/future_beacon / Stage 18 / June 7–12, 2026

A Note from Pete Trainor

This wasn't about replacing anyone. It was about understanding what's coming.

I spend a significant part of my professional life thinking about the ethics of Ai in creative work. I write about it. I advise organisations on it. I wrote Drawn to Extinction, a book whose entire premise is that Ai threatens the livelihoods of human creators. So let me be direct about why I ran this experiment, because the optics deserve an honest account.

Future Beacon was not an exercise in proving that Ai can replace game designers, writers, or developers. It was a controlled test of a specific question: how capable is agent-to-agent collaboration becoming, and does a strategy scenario stress-test that better than the usual benchmarks of code generation or copywriting? The answer to both, it turns out, is yes.

"Strategy forces agents to hold a goal across time, adapt to adversarial pressure, and coordinate without a human in the loop. That's a meaningfully harder problem than writing a function or drafting an email."

My guardrails were deliberate. I authored the creative world: the lore, the band, the enemies, the metaphor. That was mine. Beyond that, I stayed largely hands-off, intervening only occasionally to ask the agents to explain their reasoning before proceeding, to surface the logic rather than just accept the output. I wanted to understand the decision-making, not just inherit the artefact. The storyline was a human contribution. The 12,000 lines were not.

What I was watching for was drift, compounding error, and the brittleness you'd expect when two systems coordinate without a shared memory. What I found instead was something closer to a disciplined engineering team: structured handoffs, maintained build integrity, escalation through documentation rather than assumption. That surprised me. It should surprise anyone who still thinks multi-agent Ai is a novelty rather than an emerging capability.

I'm publishing this not as a celebration of automation, but as evidence. If you work in creative industries, in product, in services, you need to understand what this capability level means for how work gets organised. Ignoring it isn't a values position. It's just being underprepared.

The Bigger Picture

The game was a metaphor. The engine is real.

Future Beacon is a strategy game. But the underlying architecture — multiple specialised agents, each owning a defined role, coordinating asynchronously through structured handoffs, producing a single coherent output — is not specific to games. It's a pattern. And it's one that maps directly onto some of the most complex build challenges in enterprise technology.

Consider Digital Worker construction: the same multi-agent model could coordinate an API preparation agent, a build agent, a provisioning agent, and a QA agent, each operating within its defined authority, each handing off through structured documentation rather than real-time instruction. The result wouldn't be a game. It would be a production-ready enterprise Ai worker, built faster, with fewer integration failures, and with a verifiable audit trail baked into the process.

The same logic extends further. Educational simulations. Compliance tooling. Clinical pathway builders. Anywhere that a complex, multi-system output currently requires a large human team working in sequence, this model offers a different way to organise the work. Not to remove the humans, but to change what they're responsible for. The humans define the world. They author the guardrails. They ask the questions that surface the reasoning.

"The creative brief is still a human act. What's changed is the scale and speed of what can be built from it."

Future Beacon took six days. A comparable human team, starting from a blank repository, would reasonably need three to six months. That gap is not a threat to creativity. It's a challenge to how we think about the relationship between creative direction and production capacity.

The signal the Future Beacon receives comes from a future where music still exists. The point of the experiment was never to silence the music. It was to understand the machine well enough to keep it from being used against the things we care about.