Give the laser its own voice, and let a body sound like its size

The laser was playing boom() — the BOMB — so the showiest weapon in the game
sounded like the least showy one. zap() is its own: a highpassed crack, two
detuned saws diving through a resonant lowpass, weight underneath so it lands on
a phone speaker, and a triangle that rings after the plane has gone. The dive is
the whole reading; a rising sweep is a charge-up and this thing never charges.

And the NORMAL hit — ball meeting a body without killing it — was borrowing
pock(), the racket thock. That is a bright, dry, stationary-band click: exactly
right for gut on felt and exactly wrong for felt on a torso, which is why hitting
a zombie sounded like hitting a wall. thud() falls instead of sitting still,
which is where the wetness comes from, with one quiet bright tick just behind the
slap: something gave. The machine keeps its pock — it is furniture and it rings.

Both thud() and splat() now take a size, zombieH/1.8, so 1 is a shambler, 1.5 a
brute and 2.04 a chapter-4 boss. Everything pitches down and lengthens with it.
Measured through a patched AudioParam rather than assumed: the body thump under a
hit runs 150 Hz on a shambler, 100 on a brute, 59 on the boss.

splat() got the same treatment while I was in there — a resonant band collapsing
down the spectrum instead of a plain lowpass, plus a second brighter burst a beat
later. One clean hit is a thud; a thud followed by spatter is a body.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
wuwiandClaude Opus 5 committed 2026-08-03 23:23:47 +02:00
1 parent 0c12157702
commit 5a4c6e4359
4 files changed
+126 -23

No files matched your search

+7
View File
@@ -1180,6 +1180,13 @@ this on any new pose with a raised prop.
index, never a search — which is why the laser looked fine while the other four did not.
Note also that spending re-indexes the rack (`spendSlot` splices), so a slot number goes stale the
moment any tin empties. Look weapons up by ID, not by a slot you cached a frame ago.
- **Every sound in audio.js swallows its own errors** (`try { ... } catch (e) {}`), so a clean
console proves NOTHING about whether one played. To verify a sound really built its graph, count
nodes — patch `AudioContext.prototype.createBufferSource` / `createOscillator` /
`createBiquadFilter` and diff around the event. To verify a PARAMETER reached the synthesis, patch
`AudioParam.prototype.setValueAtTime` and look for the frequencies you expect (that is how the
size scaling on `thud`/`splat` was checked: 150 Hz body thump on a shambler, 100 on a brute,
59 on a chapter-4 boss).
- **A test that walks the game forward will quietly kill the player.** Three separate diagnostic runs
above returned nonsense (`stillCarried: true`, no laser fired at all) purely because `G.mode` had
become `'eaten'` several steps earlier and every gameplay entry point bails on that. When a probe