When playing a small sound file either with playSound() or playBackgroundSound(), there's approximately a one second delay before the sound plays.
SexScripts version: 04-Feb-2020
Platform: Window 10 64-bit
This is a sample script that demonstrates the problem (at least it does on my system):
Code:
setInfos(9, "play-sound-latency", "test", "RustyHammer", "v0.0", 0xFFFFFF, "en", [])
show(null)
setImage(null)
for (;;)
{
final int selection = getSelectedValue(null, ["playSound", "playBackgroundSound"])
if (selection == 0)
playSound("tom.wav")
else
playBackgroundSound("tom.wav")
}
When pressing either button, I experience approximately a one second delay before the sound actually starts playing. The audio file in the example, tom.wav, is 22kb, and is one of the standard audio files that comes with SS.
What I was hoping to do was add a simple click sound when the user has selected an option, but with the delay it detracts from the experience.
Does anyone else experience such a delay? If I open the file from Windows Explorer, the file loads and plays in VLC within 0.1 seconds.