
Sandfall
A falling-sand world on the GPU, with a shareable gallery.
How it's built
- Integer Margolus automaton, no write conflicts
- WebGL2 shader with a bit-identical CPU twin
- Same world hash in Node, worker and GPU
- A creation is its stroke log: replays and remixes
- Public gallery on Pages Functions and D1
- Live chart, synthesised sound, WebM time-lapse
Pour sand, water, oil, lava, acid, ice, gunpowder and fire into a 512 by 512 world and watch fifteen elements react. The rules are an integer cellular automaton on 2 by 2 Margolus blocks, written once and run as a WebGL2 fragment shader with a bit-identical TypeScript twin in a Web Worker. A test proves Node, the worker and the GPU produce the same world hash, so every creation is just its stroke log: undo, share links, replays and a public remix gallery all follow from that.