EdgeOfChaos
E
EdgeOfChaos
I'm trying to play a sound. The first time I play it, nothing happens. All following times, it works as expected. Is there some trick to getting it to play the first time correctly?
SoundTools also doesn't work for me, I tried that. It doesn't even play anything.
This is my code for playing a sound:
I'm passing it the path to the sound, and I tried a bunch of different settings with is3D and stopping when out of range; nothing helps.
SoundTools also doesn't work for me, I tried that. It doesn't even play anything.
This is my code for playing a sound:
JASS:
function playSoundAt takes string path, real x, real y returns nothing
local sound s = CreateSound(path, false, true, true, 10, 10, "")
call SetSoundPosition(s, x, y, 0)
call SetSoundVolume(s, 127)
call StartSound(s)
call KillSoundWhenDone(s)
set s = null
endfunction