Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

looping more than one sound

Draxamus Eros
Registered User
Join date: 19 Nov 2006
Posts: 31
10-20-2007 02:12
Can someone tell me how to LOOP more than one sound. Or does anyone have a script that does this?

Edit: Sorry, I wasn't entirely clear. I don't want to the sounds play at the same time; I want them to play one right after the other.
Tiarnalalon Sismondi
Registered User
Join date: 1 Jun 2006
Posts: 402
10-20-2007 05:13
A prim can only emit one sound at a time. llTriggerSound causes the sound to be emitted by the Location of the prim, and not the prim itself.

So to answer your question, to loop more than one sound, you'd need different prims with different scripts for each sound you wanted to loop.
Draxamus Eros
Registered User
Join date: 19 Nov 2006
Posts: 31
10-20-2007 10:56
Sorry, I wasn't entirely clear. I don't want to the sounds play at the same time; I want them to play one right after the other.
Malachi Petunia
Gentle Miscreant
Join date: 21 Sep 2003
Posts: 3,414
10-20-2007 11:43
llSetSoundQueing(TRUE) is what you want, but all my prior tests show that it has no effect at all.

From: the more complete wiki at lslwiki.net
Sets whether successive calls to llPlaySound, llLoopSound, etc., (attached sounds) interrupt the playing sound. The default for objects is FALSE. Setting queue to TRUE will make the sound wait until the current playing sound reaches its end. The queue is one level deep (i.e., only one sound will queue up at a time).

Note: State transitions disable sound queueing. So the queue is set to TRUE, and then the state changes, sound queueing will be disabled.
Furthermore, since your script has no way of knowing whether a sound has been completed, you can't really avoid overflowing the queue even if everything works as intended.

Perhaps your experience will be different; I haven't tested this in a while.
Vlad Bjornson
Virtual Gardener
Join date: 11 Nov 2005
Posts: 650
10-20-2007 11:47
Try this script, Psyke's Music script. Made to play a song file that has been chopped up into 10 second clips...

/15/67/10576/1.html
_____________________
I heart shiny ! http://www.shiny-life.com
Okiphia Rayna
DemonEye Benefactor
Join date: 22 Sep 2007
Posts: 2,103
10-20-2007 12:12
From: Draxamus Eros
Sorry, I wasn't entirely clear. I don't want to the sounds play at the same time; I want them to play one right after the other.

Could just combine them all into one file, too. Make a simpler and (I'm assuming) less laggy script, and should do exactly what you want it to... if you have the sounds on hard drive that is (Or full perms? never worked with sounds so dunno if they can be downloaded to hd)
Malachi Petunia
Gentle Miscreant
Join date: 21 Sep 2003
Posts: 3,414
10-20-2007 12:34
From: someone
Try this script, Psyke's Music script. Made to play a song file that has been chopped up into 10 second clips...
Those scripts would mostly work in the era it was written. Since then SL has substantially decreased the priority at which the server sends sound clips to you.

Back then you could expect that a 9.9 second sound would be heard by the client in about 9.9 seconds. Now that same sound clip can take anywhere between 10 seconds and never for the client to hear.

Experiment with it if you'd like, but don't be surprised if it doesn't work as advertised. And even if it sounds great to you, it may be horrible for other players.

Good luck.