posted 08-30- 09:41 PM CT (US)
I read the DinkC file and found a section on how to make looping sounds survive screen changes. It says:
void sound_set_survive(int sound_bank, 1 or 0) If 1, sound will SURVIVE a load_map command. Use this on an already
looping sound to provide 'looping music'.
So on a script I write this:
playsound(57, 22050, 0, 0, 1);
void sound_set_survive(57, 1)
I have no idea what the sound bank is but i know i need to put it in the sound_set_survive command. It says this about the sound bank:
int playsound (int sound_num, min_speed, rand_speed_to_add, int sprite_or_0,
bool repeat?)
this plays a sound. If rand_speed_to_add isn't 0, a random # will be
made from this # and added to the sound. If sprite isn't 0, the sound
will be 3d based on this sprites location. If the sprite is killed
for some reason, the sound will die too. (ie, a fire goes out)
if repeat is not 0, the sound will repeat.
Returns the soundbank used. Use this for special control of the sound.
I have not managed to figure out quite how I 'Return the soundbank used' I thought that by putting the last diget at one in the playsound command it made the soundbank one, but i don't think thats right. I have the fealing that I am looking over something very simple but I have tried everything i can think of with this small bit of information and I'm hoping somebody can clear this all up for me.
Thanks =)