Pitch and volume variation
Stop repeated sounds from sounding robotic.
Hearing the exact same footstep or gunshot 30 times in a row is tiring and obviously fake (the "machine gun effect"). Playing each sound with a slightly random pitch and volume, and rotating between a few recordings, makes repetition sound natural for almost no cost.
Try this: Press Play several times quickly with variation off, then on (V). Sound is quiet and only plays when you press.
Sound only plays when you press Play.
Prompt bit
Works for 2D or 3D in any engine (Unity, Unreal, Godot, web). Paste the short one for a quick fix, or the detailed one when you want it done properly.
Vary repeated sounds: pick a random clip from a pool of 3 to 5, never the same one twice, randomize pitch about ±5% and volume ±10%, and allow at most 4 copies per 0.05 s so swarms cannot distort the mix.
Add a small sound-playing helper that varies repeated sounds (2D or 3D, any engine or Web Audio). Each sound event has a pool of 3 to 5 recorded variations, a base volume and pitch, and random ranges (default pitch ±5%, or ±1 semitone for impacts; volume ±10%, about ±1 dB). On play, pick a random clip that is not the one used last time, apply random pitch and volume, and play it. Limit voices: at most 3 to 4 instances of the same event at once and none closer than 0.05 s apart (skip or steal the oldest), so a swarm of enemies does not stack into distortion. Use larger variation for footsteps and impacts and none for UI and dialogue. Let pitch also rise slightly for combo or coin streaks. Route sounds through mixer groups (SFX, music, voice) with their own volume settings. Expose ranges per event so sound designers can tune them.
Where it's used
- Footsteps: every surface and character
- Combat: sword hits, gunshots and impacts
- Pickups: rising pitch for coin streaks
- Swarms and crowds: voice limits stop distortion
- Ambience: birds, drips and wind one-shots
Common mistakes
Too much pitch variation so sounds become cartoonish, varying UI and dialogue sounds, picking the same clip twice in a row, and no voice limit so 20 enemies hitting at once clip the mix.
Writing this with an AI assistant? See our best AI coding assistants for game developers.
Missing a concept? Request one.



