A town-building game where your villagers are real AI agents.
AgentEmpire plays like Age of Empires, in the fantasy world of Aurelhaven. The difference: the agents you summon at the Keep are real AI coding agents (Claude Code, Codex, or any other model through pi). They build their homes and workshops, your townsfolk carry their tasks to them, a bell rings when they need your permission, and the town grows on the work you accept.

| Summoning an agent | Answering its request | Reviewing its work |
|---|---|---|
![]() | ![]() | ![]() |
Get the newest version from the Releases page and download the file for your computer:
| Your computer | File |
|---|---|
| Windows 10 or 11 | AgentEmpire-<version>-windows.zip |
| Mac with Apple Silicon (M1 or newer) | AgentEmpire-<version>-macos-arm64.zip |
| Mac with an Intel processor | AgentEmpire-<version>-macos-x64.zip |
| Linux (64-bit) | AgentEmpire-<version>-linux.zip |
Not sure which Mac you have? Open the Apple menu and choose About This Mac: "Chip: Apple M..." means Apple Silicon, "Processor: ... Intel" means Intel.
Windows
macOS
xattr -dr com.apple.quarantine (with the space at the end), drag the
unzipped AgentEmpire folder onto the Terminal window, and press Return.Linux
unzip AgentEmpire-*-linux.zip./AgentEmpire.x86_64 in it.Keep the unzipped folder together: the game needs the townhall, runtime and protocol
folders next to it. There is nothing else to install.
The first start takes a few seconds while the game starts its Town Hall, the part that runs
the agents. You begin with practice agents: a stand-in plays the agents' part through tasks,
approvals and reviews, so you can learn the game while nothing real runs and nothing is spent.
Your towns are kept in your user folder (%APPDATA%\AgentEmpire on Windows,
~/Library/Application Support/AgentEmpire on macOS, ~/.local/share/AgentEmpire on Linux), so
deleting or updating the game folder does not touch them.
claude in a terminal and sign in.codex login.What keeps real agents in check:
The Town Hall keeps running after you close the game, so agents can finish their tasks. To stop it, click the Town Hall chip in the top bar and choose Close the Town Hall.
| Input | Action |
|---|---|
| Left click, drag | Select, box-select (Shift adds) |
| Double-click | Select everything of that type on screen |
| Right click | Move, gather, build, carry a scroll to an agent's home, set a rally point |
| Q W E R T, A S D F G, Z X C V B | The 5 x 3 command card at the bottom right |
| Ctrl+1 to 9, then 1 to 9 | Assign and recall control groups (double tap to centre the camera) |
| . (period) | Next idle townsperson |
| H | Select the Keep |
| Space | Jump to the oldest ringing bell |
| F4 | Mana budget |
| Delete | Cancel the selected construction or the last unit in training |
| Arrow keys, screen edge, middle-drag | Move the camera |
| Mouse wheel | Zoom |
| Ctrl+Left / Right, Alt+middle-drag | Rotate the camera |
| F2, F3 | Toggle night, show frames per second |
| F5, F9 | Save, load an offline town |
| Pause | Pause |
| Esc | Cancel, or close the top window |
You can build the game from this project's files without any programming:
./build.sh in a terminal in the project folder.Packages for every platform at once: node scripts/setup.mjs --all-templates, then
node scripts/package-release.mjs --targets all.
AgentEmpire is an early preview. Tested on Windows 11; every release package is also started automatically on Windows, Linux and macOS (Apple Silicon) before it is published.
| Phase | Scope | State |
|---|---|---|
| 0 | Tools and experiments: the agent programs, git worktrees on Windows, the web version | Done |
| 1 | The Town Hall: tasks, approvals, Mana, the resource ledger and rewards, with practice agents | Done |
| 2 | The town: map, camera, units, gathering, construction, the controls | Done |
| 3 | Agents as villagers: summoning, homes and add-ons, couriers, approvals, review and rewards | Done |
| 4 | Real agents on Claude Code, Codex and pi | Done |
| 5 | Ages and walls, menus and onboarding, sound | In progress. Done: the Town Hall side (practice and real towns, switching and closing the Town Hall, party leads, usage limits), the four town walls with the wall-rise animation, the wanderer, sound and music. Still to come: the menus, the onboarding, and the Age and Quartermaster windows (until then the town stays in its first age) |
Godot client (desktop or web) <-- WebSocket on 127.0.0.1 --> Town Hall (TypeScript, Node 22)
the town: map, units, gathering, agents, tasks, approvals, parties,
construction, HUD Mana, resource ledger, ages, saves
|
Claude Code CLI, Codex CLI (app-server), pi (RPC mode)
|
git worktrees in your work folders
The Town Hall (townhall/) is a small local service that owns everything real: agents,
tasks, approvals, Mana, the resource ledger and saved towns. It runs each agent on an existing
agent program as a child process and sends every permission request to the player. The
client (client/) is the Godot 4.7.2 game; it simulates the town and mirrors the Town
Hall's state.
Running from source, after node scripts/setup.mjs:
client/project.godot in Godot 4.7.2 (in .tools/godot/) and press Play; the game starts
the Town Hall from townhall/ by itself. Add -- --offline to play without it.townhall/ with npm start (AURELHAVEN_PROVIDER=real for
real agents).node scripts/build-game.mjs --web-only, then open the Web client: address
the Town Hall prints.| Path | Contents |
|---|---|
client/ | The Godot project (GDScript): simulation, world, HUD, networking, tests |
townhall/ | The Town Hall (TypeScript, Node 22); see townhall/README.md |
protocol/ | The contract between them: PROTOCOL.md, economy.json (every game constant), pricing.json, generated GDScript |
scripts/ | Setup, build, release packaging, end-to-end and asset scripts |
art_src/ | The Blender pipeline that builds models, characters and icons from the KayKit kits |
docs/ | Architecture, development guide, experiment notes, README images |
.github/workflows/ | The release workflow |
design_handoff_aurelhaven/ | The original design handoff: lore, colours, fonts, the wall animation |
Releases are built by .github/workflows/release.yml: pushing a
tag such as v0.5.0 builds the Windows, Linux and macOS packages, starts each one on its own
system, and publishes them on the Releases page.
Art by Kay Lousberg (KayKit, CC0); sound from Kenney, OpenGameArt.org and Freesound (CC0) plus bells made for the game; fonts under the SIL Open Font License; built with Godot. The full list is in CREDITS.md.
GDScript
60.1%
TypeScript
27.2%
JavaScript
7.2%
Python
3.8%
HTML
1.2%
A town-building game where your villagers are real AI agents.
AgentEmpire plays like Age of Empires, in the fantasy world of Aurelhaven. The difference: the agents you summon at the Keep are real AI coding agents (Claude Code, Codex, or any other model through pi). They build their homes and workshops, your townsfolk carry their tasks to them, a bell rings when they need your permission, and the town grows on the work you accept.

| Summoning an agent | Answering its request | Reviewing its work |
|---|---|---|
![]() | ![]() | ![]() |
Get the newest version from the Releases page and download the file for your computer:
| Your computer | File |
|---|---|
| Windows 10 or 11 | AgentEmpire-<version>-windows.zip |
| Mac with Apple Silicon (M1 or newer) | AgentEmpire-<version>-macos-arm64.zip |
| Mac with an Intel processor | AgentEmpire-<version>-macos-x64.zip |
| Linux (64-bit) | AgentEmpire-<version>-linux.zip |
Not sure which Mac you have? Open the Apple menu and choose About This Mac: "Chip: Apple M..." means Apple Silicon, "Processor: ... Intel" means Intel.
Windows
macOS
xattr -dr com.apple.quarantine (with the space at the end), drag the
unzipped AgentEmpire folder onto the Terminal window, and press Return.Linux
unzip AgentEmpire-*-linux.zip./AgentEmpire.x86_64 in it.Keep the unzipped folder together: the game needs the townhall, runtime and protocol
folders next to it. There is nothing else to install.
The first start takes a few seconds while the game starts its Town Hall, the part that runs
the agents. You begin with practice agents: a stand-in plays the agents' part through tasks,
approvals and reviews, so you can learn the game while nothing real runs and nothing is spent.
Your towns are kept in your user folder (%APPDATA%\AgentEmpire on Windows,
~/Library/Application Support/AgentEmpire on macOS, ~/.local/share/AgentEmpire on Linux), so
deleting or updating the game folder does not touch them.
claude in a terminal and sign in.codex login.What keeps real agents in check:
The Town Hall keeps running after you close the game, so agents can finish their tasks. To stop it, click the Town Hall chip in the top bar and choose Close the Town Hall.
| Input | Action |
|---|---|
| Left click, drag | Select, box-select (Shift adds) |
| Double-click | Select everything of that type on screen |
| Right click | Move, gather, build, carry a scroll to an agent's home, set a rally point |
| Q W E R T, A S D F G, Z X C V B | The 5 x 3 command card at the bottom right |
| Ctrl+1 to 9, then 1 to 9 | Assign and recall control groups (double tap to centre the camera) |
| . (period) | Next idle townsperson |
| H | Select the Keep |
| Space | Jump to the oldest ringing bell |
| F4 | Mana budget |
| Delete | Cancel the selected construction or the last unit in training |
| Arrow keys, screen edge, middle-drag | Move the camera |
| Mouse wheel | Zoom |
| Ctrl+Left / Right, Alt+middle-drag | Rotate the camera |
| F2, F3 | Toggle night, show frames per second |
| F5, F9 | Save, load an offline town |
| Pause | Pause |
| Esc | Cancel, or close the top window |
You can build the game from this project's files without any programming:
./build.sh in a terminal in the project folder.Packages for every platform at once: node scripts/setup.mjs --all-templates, then
node scripts/package-release.mjs --targets all.
AgentEmpire is an early preview. Tested on Windows 11; every release package is also started automatically on Windows, Linux and macOS (Apple Silicon) before it is published.
| Phase | Scope | State |
|---|---|---|
| 0 | Tools and experiments: the agent programs, git worktrees on Windows, the web version | Done |
| 1 | The Town Hall: tasks, approvals, Mana, the resource ledger and rewards, with practice agents | Done |
| 2 | The town: map, camera, units, gathering, construction, the controls | Done |
| 3 | Agents as villagers: summoning, homes and add-ons, couriers, approvals, review and rewards | Done |
| 4 | Real agents on Claude Code, Codex and pi | Done |
| 5 | Ages and walls, menus and onboarding, sound | In progress. Done: the Town Hall side (practice and real towns, switching and closing the Town Hall, party leads, usage limits), the four town walls with the wall-rise animation, the wanderer, sound and music. Still to come: the menus, the onboarding, and the Age and Quartermaster windows (until then the town stays in its first age) |
Godot client (desktop or web) <-- WebSocket on 127.0.0.1 --> Town Hall (TypeScript, Node 22)
the town: map, units, gathering, agents, tasks, approvals, parties,
construction, HUD Mana, resource ledger, ages, saves
|
Claude Code CLI, Codex CLI (app-server), pi (RPC mode)
|
git worktrees in your work folders
The Town Hall (townhall/) is a small local service that owns everything real: agents,
tasks, approvals, Mana, the resource ledger and saved towns. It runs each agent on an existing
agent program as a child process and sends every permission request to the player. The
client (client/) is the Godot 4.7.2 game; it simulates the town and mirrors the Town
Hall's state.
Running from source, after node scripts/setup.mjs:
client/project.godot in Godot 4.7.2 (in .tools/godot/) and press Play; the game starts
the Town Hall from townhall/ by itself. Add -- --offline to play without it.townhall/ with npm start (AURELHAVEN_PROVIDER=real for
real agents).node scripts/build-game.mjs --web-only, then open the Web client: address
the Town Hall prints.| Path | Contents |
|---|---|
client/ | The Godot project (GDScript): simulation, world, HUD, networking, tests |
townhall/ | The Town Hall (TypeScript, Node 22); see townhall/README.md |
protocol/ | The contract between them: PROTOCOL.md, economy.json (every game constant), pricing.json, generated GDScript |
scripts/ | Setup, build, release packaging, end-to-end and asset scripts |
art_src/ | The Blender pipeline that builds models, characters and icons from the KayKit kits |
docs/ | Architecture, development guide, experiment notes, README images |
.github/workflows/ | The release workflow |
design_handoff_aurelhaven/ | The original design handoff: lore, colours, fonts, the wall animation |
Releases are built by .github/workflows/release.yml: pushing a
tag such as v0.5.0 builds the Windows, Linux and macOS packages, starts each one on its own
system, and publishes them on the Releases page.
Art by Kay Lousberg (KayKit, CC0); sound from Kenney, OpenGameArt.org and Freesound (CC0) plus bells made for the game; fonts under the SIL Open Font License; built with Godot. The full list is in CREDITS.md.
GDScript
60.1%
TypeScript
27.2%
JavaScript
7.2%
Python
3.8%
HTML
1.2%