As a Roblox developer, it is impossible to make immersive sounds in a system where the same sound needs to be played in multiple areas simultaneously without flanging producing a loud sweeping noise. Examples of this include trains, aircraft (same sound playing in multiple engines), ambient background sounds, and other long vehicles.
This is because it is currently impossible to play multiple sounds in phase with each other. The existing API only allows sounds to be played sequentially, and multiple sounds cannot be played at the same time. As Lua is single-threaded, it is not possible to get the sounds to play without a delay of several milliseconds, which causes flanging. Parallel Lua is not a viable solution because of the way changing properties is limited inside Actors. Regardless, it would be far too complicated for the average developer.
We propose an addition to the API such as:
SoundGroup:PlaySounds(soundsToPlay)
SoundGroup:StopSounds(soundsToPlay)
If no arguments are provided then it would play/stop all sound in the SoundGroup.
SoundService:PlaySounds(soundsToPlay)
SoundService:PlayLocalSounds(soundsToPlay)
Another solution would be to add a list of attachments where a single sound could play in many locations.
These functions should guarantee that the sounds are always in phase, completely eliminating the unintended noise generated by flanging.
If this issue is addressed, it will allow me and other developers to vastly improve the sound quality in our games and spend more time developing other features such as monetisation.
If not, we will have to sacrifice sound quality and immersion while spending more time to create incomplete workarounds to reduce the effect.
Repro courtesy of @Edo_UK:
A few examples of notable games that suffer from this issue and could benefit from this feature (combined visits: 40 million+):
- Stepford County Railway
Stepford County Railway 🚉 - Roblox - Terminal Railways
Terminal Railways - Roblox
https://twitter.com/_EdoUK/status/1366056103235227651?s=19 (recording of flanging) - Streamlined
Streamlined [ALPHA] - Roblox