← Back to the book

Tiny Planet

A walkable, procedurally-generated Cambodian village on a tiny sphere, rendered as a living watercolour

Three.jsTypeScriptWebGLProceduralCambodia

Published: 7/1/2026

Tiny Planet

A walkable, procedurally-generated Cambodian village that fits on a tiny sphere. You stroll a small world as a Khmer villager while the whole place, terrain, houses, plants, animals, and weather, is drawn entirely from code and washed in a watercolour illustration style. There are no model files and no textures: every rooftop, sugar-palm, and rice paddy is generated fresh at load.

A whole world, drawn from code

Nothing here is a downloaded asset. One seeded random-number generator drives all of world generation, so the same village greets you on every load: the towns, the rice paddies, ponds, a lake, the coast, a river, mountains, a plantation, and scattered vegetation are all placed procedurally. Villagers, monks, children, chickens, ducks, butterflies, and dragonflies wander and fly on their own, each a small self-animating actor with its own gait.

Walking on a sphere

The world is a real sphere, so "down" is always toward the centre. The player's orientation lives in a single quaternion: local up is the surface normal, forward is the walk direction, and every model is built to grow up from the ground so it can be dropped onto the curved surface and tilted to stand upright. Hills are genuinely climbable (the ground and camera follow the terrain height), and movement uses a gentle auto-steer: bump a wall head-on and you ease around it rather than snapping, while small rocks are vaulted with a little hop.

A painterly look

Every surface uses a cached painterly material that injects world-space brush-stroke noise into its colour, so the whole scene looks hand-tinted rather than plastic. A final full-screen watercolour pass bleeds and softens the image the way pigment settles into paper. The result reads as a moving illustration, not a video-game render.

Rooted in real Cambodia

The details are deliberately authentic: saffron-robed monks, sugar-palm trees, laterite red earth, krama scarves, stainless-steel cooking pots over a fire, and a Tonlé Sap-like lake. The goal was a place that feels specifically Cambodian, not a generic fantasy village.

Technical notes

Built with Vite, TypeScript, and Three.js, and deployed to Cloudflare Workers as a static, assets-only app with no backend. The world is a fixed set of objects built once, so the per-frame loop just updates the actors and the camera: no per-frame allocation, deterministic output, one seeded RNG behind the entire village.