Skip to main content

We use cookies for analytics. Privacy

Back to Work
Gaming & SimulationCase study

SubTerra

Modern Ant Colony Simulation Built with Bevy ECS

Project Focus
RustBevy ECSWebAssemblyWGPURapier Physics
SubTerra
Thousands simultaneous
Entities
60 FPS
Frame Rate
Massively parallel
Systems
Native + WASM
Build
01

Challenge

Classic ant colony simulations are either oversimplified browser toys or academic papers. No modern game captures the depth of SimAnt with today's rendering and simulation capabilities.

02

Solution

Engineered a full ECS-based simulation in Rust using Bevy, where thousands of ants exhibit emergent behavior through pheromone trails, resource gathering, and colony defense. Parallel systems spread the work across multi-core CPUs to keep the simulation running in real time at scale.

03

Results

  • Thousands of simultaneous entities at 60 FPS
  • Emergent colony behavior via pheromone system
  • Parallel ECS systems for maximum CPU utilization
  • WebAssembly build for browser deployment

System Architecture

Data-oriented ECS architecture with parallel system execution and WGPU rendering pipeline

frontend
backend
service
ai
System schedulingRender pipelinePhysics queriesBehavior updateAsset loadingComponent writes
Bevy App
ECS runtime
ECS World
Entities & components
Render Pipeline
WGPU renderer
Physics (Rapier)
Collision & forces
AI Systems
Pheromone & behavior
Asset Loader
Sprites & audio

Data-oriented ECS architecture with parallel system execution and WGPU rendering pipeline

Facing Similar Challenges?

Every business is different, but the problems tend to rhyme. If someone sent you, get in touch and tell us about yours.

A conversation, not a pitch
No obligation
We reply when we can