Jump to content

The script for the music


AlexandreLois1
 Share

You are about to reply to a thread that has been inactive for 3377 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

 

The script for the music

A few questions
1. How do I run a script to hear the music?
2. How do I transfer audio file in the code that you see in this script? I think need a special program. In what form need music (midi, mp3)?

caramell_dansen_song

1 list music = [
2 "77a160fa-f8ef-3f1f-eb4a-8a6e422552e1",
3 "eed92d3e-404e-99b0-62b6-8a53fe66a661",
4 "36e2c7c4-b72d-34ff-a176-a018e383dc2f",
5 "5aaf5344-ee5e-b439-a533-ccfd38e96ca7",
6 "a45f162e-229e-4c4b-5230-40f3b1331075",
7 "e832ea7f-ba18-6318-f65b-b2aa905de565",
8 "061d2028-3878-ea5e-3de8-e0898f753e63",
9 "4390c4d0-843e-a9b1-8b3d-27389021d198",
10 "76eacfce-094f-2089-7ee1-35ea84cf47b4",
11 "45b2649f-1d2c-5455-ba9d-7ac9e7b1672c",
12 "72226579-eb24-3cbb-3ca8-4317ed4a57d0",
13 "054009aa-6034-9e34-39cb-60f4e8e171e3",
14 "9f38b9ec-fd0b-e51b-69e9-cb2f00e12027",
15 "c930c9d7-9539-86e7-65dd-aeb2789aecc2",
16 "9ec9c129-15f7-ec92-1b28-eaf772e372b5",
17 "53df30f4-33a5-3ae6-9888-d1f560cd9875",
18 "fa63c473-cb93-43cf-e4ce-fcb3d704b37b",
19 "1344cf7f-7d4d-f975-f47f-ea2ac6d1c956"];
20 default
21 {
22 touch_start(integer zomg)
23 {
24 llSay(0, "Playing...");
25 integer lolinteger =0;
26 while(TRUE)
27 {
28 if(llList2String(music, lolinteger) != "")
29 {
30 llPlaySound(llList2String(music, lolinteger),1);
31 llSleep(10);
32 ++lolinteger;
33 }
34 if(llList2String(music, lolinteger) == "")
35 {
36 llResetScript();
37 }
38 }
39 }
40 }

Link to comment
Share on other sites

Save your file in .wav format (16 bit pcm coded mono)

Divide it into pieces that are each exact 10 seconds long.

Upload all of the 10 second files to SL.

Right click on each uploaded file in inventory and get the UUID.

Put the UUID's into the script. (in the right order)

Expect that the transitions are not always smooth.

Link to comment
Share on other sites


Nova Convair wrote:

Save your file in .wav format (16 bit pcm coded mono)

Divide it into pieces that are each exact 10 seconds long.

Upload all of the 10 second files to SL.

Right click on each uploaded file in inventory and get the UUID.

Put the UUID's into the script. (in the right order)

Expect that the transitions are not always smooth.

Back when I was messing with this with a friend we found transitions were smoothest when the files were just under 10 seconds.  We wound up using 9.7 to 9.8 second clips.  Don't know why but could be related to the caching/fetching.

Link to comment
Share on other sites

Save your file in .wav format (16 bit pcm coded mono)

Divide it into pieces that are each exact 10 seconds long.

Upload all of the 10 second files to SL.

Right click on each uploaded file in inventory and get the UUID.

Put the UUID's into the script. (in the right order)

Expect that the transitions are not always smooth.

 

Thank you, I understand, but how to do so, to run this script?

Link to comment
Share on other sites


AlexandreLois1 wrote:

Save your file in .wav format (16 bit pcm coded mono)

Divide it into pieces that are each exact 10 seconds long.

Upload all of the 10 second files to SL.

Right click on each uploaded file in inventory and get the UUID.

Put the UUID's into the script. (in the right order)

Expect that the transitions are not always smooth.

 

Thank you, I
understand, but
how to do so
,
to run this
script?

You do the first three steps in Audacity or whatever you are using as your sound editing program. Then upload each file to SL with Build >> Upload >> Upload Sound, paying L$10 for each file.  Then, get the UUID for each file and put it in your script, as directed.  And hope for the best.

Link to comment
Share on other sites


Rolig Loon wrote:

It can also help to use llSetSoundQueueing.  In the end, though, even your best scripting makes no difference unless your region is lag free.  It doesn't take much to make daisy-chained sound clips mess up.

Except that it looks like SVC-4260 never even got looked at.

Why we are still limited to 10 second clips is a mystery.  We ain't on dial up anymore.  ;)

 

Link to comment
Share on other sites


Perrie Juran wrote:


Rolig Loon wrote:

It can also help to use llSetSoundQueueing.  In the end, though, even your best scripting makes no difference unless your region is lag free.  It doesn't take much to make daisy-chained sound clips mess up.

Except that it looks like
never even got looked at.

Why we are still limited to 10 second clips is a mystery.  We ain't on dial up anymore. 
;)

 

SVC-4260 would be handy, true, but it really isn't necessary since you can simply loop through files, queueing as you go.  The 10 second limit, though, is a mystery.  I suspect that it has more to do with storage size than with upload speed, but both have increased dramatically since Day One, when the limit was established.  It's there, though, so we live with it for now.

Link to comment
Share on other sites


There is some possibility to delete numbers automatically?


It's certainly an easy enough macro to write in most any programming text editor -- not the LSL editor built into the viewer, of course. But it raises the question of where you got this script (which is pretty awful for reasons unrelated to the line numbers). Those line numbers were added by something quite unrelated to Second Life, so the source is pretty suspect.

(Apropos the 10-second limit: It may have arisen for technical reasons, but I've always suspected it might be related to a widespread assumption that a 10 second sample is "fair use" of copyrighted audio and video -- although I don't think that assumption is even valid -- and surely not for trademarked sounds which are (all?) under 10 seconds each.)

Link to comment
Share on other sites

But it raises the question of where you got this script (

 

There simulator associated with second Life. Called Tacos. He used to study the Russian language and belongs to the Pushkin Institute. This is taken from there.

 

Who can write a macro to remove the extra digits for money?

Link to comment
Share on other sites

A text editor - like notepad++ for example - allows block select.

So select the left 2-3 columns and delete - result: no linenumbers.

 

About the 10 seconds limit: Server spaces was maybe an issue then. But now the servers and the space have increaed and the bandwidth costs have decreased dramatically. LL used that to lower their costs alot but they gave nothing to their customers. Things like that happen in a market without competition.

Another point is: if they allow to upload and play mp3 files SL would turn into an illegal exchange platform. Even playing is not allowed. Playing of 10 sec chunks or the way the OP is planning to do isn't allowed too btw. Due to the effort and problems it just will not become widespread. :D

Link to comment
Share on other sites


Qie Niangao wrote:

There is some possibility to delete numbers automatically?


It's certainly an easy enough macro to write in most any programming text editor -- not the LSL editor built into the viewer, of course. But it raises the question of
where you got this script
(which is pretty awful for reasons unrelated to the line numbers). Those line numbers were added by something quite unrelated to Second Life, so the source is pretty suspect.

 

This is a common problem when getting scripts from old libraries such as Phaze Dimensia

If you copy/paste the script it copies all the line numbers as they appear on the page.  Not all of them have been updated to include a "get file" sans the line numbers like you see on Phaze's sight.  Here are two snippets.

Script as displayed copy/pasted:

1

2 rotation rot_xyzq;
3
4 default
5 {
7 {
 
Script from get 'get file.'
 
rotation  rot_xyzq; default{    state_entry()    {

 


Qie Niangao wrote:


(Apropos the 10-second limit: It
may
have arisen for technical reasons, but I've always suspected it might be related to a widespread assumption that a 10 second sample is "fair use" of copyrighted audio and video -- although I don't think that assumption is even valid -- and surely not for
trademarked
sounds which are (all?) under 10 seconds each.)

Copyright allows for including brief samples of a work for the pupose of doing a review.  The length is not written in stone.  I can't find my documentation right now but a 30 second snip was about the longest a Court would allow.  What gets weighed is, "The amount and substantiality of the portion used in relation to the copyrighted work as a whole."   

For other uses, personal or commercial, no length is allowed.

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 3377 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...