EUCA/ENGINE v1.1.0
 build passing contact ↗

The agent-native
game engine.

An ECS-first engine in Rust where agents build, play, and experiment through one typed API — on a deterministic world they can read, change, fork, and replay exactly.

"The whole game world is a flat, deterministic table the agent reads, edits, and forks." — design principle 01
agent@workstation euca · session #a4f0 live

world snapshot · tick 0000

id name team hp
// no entities yet
seed 0x9c41fa
rules 1 active
forks 0
schema flat · 23 cols
01 · the agent loop

Agents don't click through an editor. They call the engine.

One typed HTTP surface covers every primitive — spawn entities, run physics, define rules, step the simulation, snapshot the world, fork it for what-if reasoning. The same API that plays the game authors it.

▸ buildi.

Build

Spawn entities, set up combat, define rules, orchestrate levels — all through the API. The surface used to play is the surface used to author.

entity createrule addscene save
▸ playii.

Play

Step the world, read exactly what changed, act, repeat. Full state in, action out, exact delta back — a clean observe-act-step loop, not a screen to parse.

sim stepobserveact
▸ experimentiii.

Experiment

Fork the live world, apply an intervention, advance, observe — then drop the fork. The main run is never touched. Reason by counterfactual.

world forkdiffreplay
02 · world as table

Not your object-graph engine.

Unlike Unity or Unreal, Euca doesn't hide the world behind an object graph and a GUI. The whole game world is a flat, deterministic, controllable table.

  • 01
    Read the world directly as plain data.

    Entities, components, fields — the lot. No reflection tricks.

  • 02
    Change the rules mid-game, without a reset.

    "When X happens, do Y" is an entity an agent can inspect, diff, modify.

  • 03
    Fork the world to try a what-if.

    The main run is untouched. The same systems run on the fork — what you see is what would have happened.

  • 04
    Replay any run byte-for-byte.

    One canonical seeded RNG. Same seed + actions → the same world. Every run reproduces.

world.dump() · entities 23 columns · 47 rows
> euca world dump --format jsonl --components Transform,Health,Team,AI

# row 0x01
{ "id": "0x01",
  "Transform": {pos: [-3,1,0], rot: [0,0,0,1]},
  "Health":    {cur: 100, max: 100},
  "Team":      "A",
  "AI":        {tree: "melee", target: "0x02"}
}

# a rule is an entity too
{ "id": "r#7",
  "Rule":      {
    when: "Death(e)",
    do:   "Score(team_of(e), +1); Drop(Coin, pos_of(e))"
  }
}

# 45 more rows omitted
03 · forks & counterfactuals

Try a what-if. Drop the fork. Main untouched.

Deep-copy the world, apply an intervention, advance the simulation, observe. The same physics, combat, AI and rules run on the fork — so what you see is what would have happened.

t0 t30 t60 t90 t120 t150 t180 t210 main · seed 0x9c41fa fork A · heal mage at t120 fork B · disable archer at t150
mainarcher 12 hp · mage 0 hp · ticks 240
fork Aarcher 4 hp · mage 38 hp · win flipped
fork Barcher offline · mage 71 hp · runaway
04 · capability matrix

What an agent can do, day one.

/ ecs01

Build scenes

Cubes, spheres, planes with PBR materials. Ortho and perspective cameras. Transform hierarchies.

/ gameplay02

Game logic

Health, damage, teams, projectiles, trigger zones, AI behaviors — composable ECS components.

/ rules03

Data-driven rules

"When X happens, do Y" — without writing code. Death reactions, timers, health thresholds.

/ forks04

Counterfactuals

Deep-copy the world, run a what-if, compare. The same systems run on the fork. The main run never moves.

/ replay05

Deterministic replay

Same seed + actions reproduce the same run, byte-for-byte. For debugging, replays, experiments you trust.

/ handoff06

Snapshots & handoff

Label a moment, capture team / role / phase summaries with assertion results — structured, not screenshots.

/ identity07

Verifiable agents

Ed25519 identity built in. Every agent that touches the world is verifiably who it says it is.

/ render08

Visual feedback

Screenshots for verification, HUD text and health bars, camera presets — visible in the editor when a human watches.

05 · under the hood

Built for determinism, not convenience.

crates
31
Rust workspace, edition 2024
engine source
121K
lines
tests
1,961
unit + integration
1M entities
2.7 ms
parallel ECS pipeline, M4 Pro
  • runtime
    custom ECS · archetype storage, generational entities, rayon-parallel queries, change detection.
  • math
    SIMD hot path · SSE2 on x86, NEON on Apple Silicon. Vec/Mat/Quat/AABB.
  • render
    wgpu + native Metal · Forward+ PBR, cascaded shadows, MSAA/FXAA, SSAO, SSR, volumetric fog, CPU frustum + per-cascade shadow culling, opt-in bindless materials.
  • physics
    custom · AABB / sphere / capsule, collision layers, raycasting, CCD, scene queries.
  • randomness
    one canonical seeded RNG, engine-wide. Every stochastic event is declared, named, reproducible — the engine knows the dice.
  • scripting
    Embedded Lua (mlua) · hot reload, sandboxing, ECS bridge, event handlers.
  • agent api
    HTTP REST on :3917, 121 endpoints, Ed25519 auth, self-describing manifest via euca discover.
  • platform
    macOS · Linux · zero heavy deps on the critical path.
· launching soon ·

Build a world where agents are first-class.

Whether you ship games where agents are players and authors — or run experiments on a world you can fully control, reproduce, and counterfactually intervene in.