mycelium world
a digital ecosystem — an artistic exploration in creative coding
world rules
Everything you see and hear follows a fixed set of rules. Nothing is random decoration.
🌱 growth
- Colonies grow outward one cell at a time from a random existing cell. Each step can jump 1–4 grid slots depending on biome.
- A colony must reach its bloom threshold (45–100 cells, biome-dependent) before it turns colourful. Before that it appears grey-white.
- When a snake is actively feeding in a colony's territory, that colony stops growing entirely until the snake leaves.
- Two colonies cannot occupy the same grid slot. Growth is blocked where space is already claimed.
- If a snake cuts deeply enough that a section of colony becomes disconnected from the main body, that section dies.
🎨 colour & DNA
- Every colony is born with two seed colours drawn randomly from its biome's palette. These are its genetic identity.
- At bloom, cells alternate between the two seed colours, creating the characteristic two-tone ring pattern.
- After bloom, every new cell blends the two current colours with a small random drift — the palette evolves with each generation. This is colour DNA inheritance.
- Spores carry the parent colony's colour lineage. New colonies born from spores start with inherited hues.
- Eaters absorb the colours they eat. Their body colour is the running average of the last 10 cells consumed — it shifts as they move between colonies.
✨ spores
- Every colony periodically ejects a spore — a drifting cyan pixel that moves with random velocity.
- When a spore's life runs out, it lands and starts a new colony wherever it stops.
- If two spores collide mid-air, they merge instantly into a new colony at their midpoint.
- Spores landing near dust trigger a special sound and often birth colonies with more genetic diversity.
- A ripple ring expands from the landing site when a spore lands near existing cells.
🐛 eaters
- Eaters spawn on colony edges once enough colonies have bloomed. Their frequency depends on biome.
- Each eater claims a feeding zone and grazes within it before migrating to a new area.
- Eaters only eat edge cells — they can't tunnel into the interior of a colony directly.
- Eaters repel each other. Bigger eaters need more personal space and push others away more forcefully.
- Eaters grow through four stages as they eat: worm (black) → colour worm (absorbs colour) → thick worm → frog (two eyes). Each stage eats faster.
- Growth rate is tied to ecosystem richness — more colonies means faster eater development.
- Eaten cells leave dark scars that block new growth for a fixed duration before clearing.
💨 dust
- When a snake severs a colony section, the disconnected cells turn grey and become dust.
- Dust fades over time. If a spore lands near dust before it disappears, a new colony is born from the remains.
- If no spore reaches the dust in time, it vanishes — that energy is lost from the system.
🔊 sound rules
- The master volume rises with total cell count. A near-empty world is nearly silent.
- Three drone layers build progressively: the first is always present, the second fades in once enough colonies bloom, the third once the world is dense.
- The drone chord shifts over time to match the dominant colour hue of the world — orange world hums lower, blue world hums higher.
- Micro events (rustles, tones, clicks, shimmers) fire more frequently as the world fills. A crowded world is sonically busy.
- Every 25–60 seconds a swell rises and recedes. Its peak scales with world complexity.
- Colony bloom → soft triangle chord tuned to the colony's colour.
- Two colonies touching → deep sine chord blending both colony hues.
- Spore ejected → quiet sustained sine from the lower register.
- Two spores colliding → soft three-note chime (C, E, G).
- Spore landing near cells → a soft thud and expanding ripple.
- Spore landing near dust → a rising tone (new life from decay).
- Eater migrating → dominant colour eaten triggers its nature sound: blue = water drop, green = cricket, red = frog croak, yellow = bird trill, magenta = moth flutter, cyan = wind chime.
🌍 biomes
- Earthy — amber and red palette, slow dense growth (rate 0.45), step sizes 1–2, max 4 eaters, deep low drones.
- Aquatic — blue and cyan palette, flowing medium growth (rate 0.65), step sizes 1–3, max 3 eaters, mid-register drones.
- Weather — purple and electric yellow, fast erratic growth (rate 0.80), step sizes 1–4, high drones, frequent spores.
- Volcanic — deep red palette, aggressive growth (rate 0.70), max 10 eaters with fast eat cooldown, very low rumble drones.
- Arctic — pale blue and white, very slow crystalline growth (rate 0.25), single-step only, max 2 eaters, sparse high tones.
why this is a real ecosystem
A digital ecosystem isn't just anything with interacting parts. The term has actual criteria — and this meets them.
emergence
Visual patterns and colony shapes aren't programmed directly. They arise from simple rules interacting. No one designed the specific forms that appear.
interdependence
Colonies compete for grid space. Spore collisions seed new growth. Eaters depend on colonies. Dust feeds the next generation. Each component's behaviour changes the others.
energy flow
Spores carry colour lineage between colonies. Eaters redistribute that energy as scars and dust. Dust becomes substrate for new growth. A genuine nutrient cycle.
self-regulation
Colonies can't grow infinitely — eaters consume them. Eaters can't multiply infinitely — colonies are their food. This feedback loop is the defining feature of an ecosystem.
succession
The world changes in non-random ways. Sparse colonies → dense growth → eater pressure → separation and dust → regrowth from dust. That's ecological succession.
biome differentiation
Five environments — Earthy, Aquatic, Weather, Volcanic, Arctic — each producing genuinely different emergent behaviours. Not visual skins. Different rules, different worlds.
The rules here are aesthetic rather than physically accurate. That's a creative choice, not a flaw.
how the sound grows
The soundscape responds to the world's complexity in real time.
empty
nearly silent — one faint drone, long gaps between sounds
first bloom
second drone fades in — micro events begin to emerge
half full
three drones humming — texture brightening — one event per second
crowded
full volume — high shimmer dominant — rapid forest texture
eaters active
each colour eaten produces a distinct nature sound — water, crickets, wind
about the creator
Sebastian Roa Viera is a designer, artist, and HR professional working at the intersection of human systems and creative technology.
pottery & ceramic art
v60 pour-over experimentation
3d printing & object design
creative coding
HR creative solutions
creative data & analytics
mycelium world is part of an ongoing exploration of how generative systems can model living complexity — not to simulate nature perfectly, but to find where code and biology speak the same language.
open source
This project is open source. The full codebase — simulation, audio engine, renderer, biome system — is available on GitHub. Build your own world.
view on github →