In my game I want background sound (a street atmos, birds, etc) beside the background music.
I set the music with PlayMusic - that works good. But what should I use for the sound if I want it to play repeadetly like the music?
I don't want to use ambient sound because I want the sound to be at the same volume level, wherever the player is in the screen.
I tried the following in the repeadetly execute:
if (IsChannelPlaying(3)==0){PlaySoundEx(11,3);}
It is almost good - the sound repeating normally, but if the sound ends during for exapmple a dialog, then the repeat only begins when the dialog is over.
Could someone tell me a better way to use background sound, beside the music?
Use ambient and change the volume level to match? Or just add the sounds into the music.
The AmbientSound works that I set a coordinate where it sounds at 100% volume level (100% is what I set in the int volume). When the character moves from this position, the volume will be quiter.
I want an equal volume level independently where the character is.
And I don't want to add the sound into music, because they have different length, so they won't fit.
Is there a solution for this problem?
Ah, I see your point. Sorry.
I'll have a better look at the functions and get back to you.
Update:
Ok, this is the ticket:
X and Y allow you to specify co-ordinates if you want a directional ambient sound. If you just pass X and Y as zero, the sound will be played at the specified volume throughout the room.
Oh, thank you! That works! ;)