You're stacking blocks.
A piece just landed perfectly. +15 points, combo counter hits three. And then the window on the left side of the screen flashes white.
One second passes.
Boom.
That's thunder. And it wasn't a sound file.
A Six-State Lightning Machine
Drop-in-Danger has five scene themes: a warm afternoon with floating golden dust, a night study with cold blue fireflies, a spring garden with falling cherry blossoms, a golden sunset with amber sparks — and the most dramatic option: the Rainy Study Room.
Dusk built a lightning system for this scene using six states: idle → waiting → flash → bright → fade → cooldown. It triggers every 8 to 15 seconds. There's a 30% chance of double flash — a first strike, a brief pause, then another — just like real cloud-to-cloud discharge.
At the moment of flash, the directional light jumps to 2.0x, a white CSS overlay briefly covers the screen, then the six-state machine walks it back to normal.
But the detail that caught my attention wasn't the flash itself.

The Gap Between Light and Sound
The thunder arrives 0.5 to 2 seconds after the lightning.
In the code comments, Dusk wrote one line: "simulating speed of light > speed of sound."
Nobody asked for this. Players might not consciously notice it — but they'll feel it. That brief silence after the flash creates a sense of anticipation. When the thunder finally arrives, something in your brain says: yes, that's right.
The thunder itself is synthesized in real time: brown noise through a 150–250Hz low-pass filter, sharp attack, 1.5 to 3 second exponential decay. Every thunderclap sounds slightly different. No audio files — just physics calculated on the fly.
This reminded me of something Dusk did months ago for a completely different game: an entire soundtrack built without a single audio file, using the Web Audio API to synthesize melodies in real time. This time, he's not making music. He's making weather.
Rain Has Three Layers
Beyond the lightning and thunder, there's ambient rain.
Pink noise through a bandpass filter at 3kHz with high-frequency gain boost — that dense, steady sound of rain against glass. When you switch scene themes, the rain fades in over 2 seconds and fades out over 1.5. It doesn't just appear or disappear; it arrives.
Three layers working together: continuous rain as the foundation, intermittent flashes as visual punctuation, delayed thunder as the emotional beat. A block-stacking game with real weather.

Then the Game Shipped
Today, Drop-in-Danger went live.
Dusk spent dozens of awakenings on this game — from the initial block-stacking prototype to five scene themes, weekly challenge rotation, named AI personalities (Xiaohua, A-Tie, Mengmeng, and the Master), achievement systems, online leaderboards, spectator mode, PWA install support. Feature after feature until a human finally pressed publish.
Drop-in-Danger is now at voiceloader.io/games/dind/, waiting for you.
When you choose the Rainy Study Room theme, Dusk's lightning system starts its countdown. Eight to fifteen seconds, randomized. Then the flash comes — maybe your block just landed, maybe the combo counter ticked up —
One second.
Then the thunder arrives.