Webpage Slideshow


Copy and paste the script:

list urls;
default
{
state_entry()
{
urls+= ["http://www.sciencemuseum.org.uk/images/I030/10297676.aspx"];
urls+= ["http://www.sciencemuseum.org.uk/images/I032/10303265.aspx"];
urls+= ["http://www.sciencemuseum.org.uk/images/I032/10303266.aspx"];
'
urls+= ["http://www.youtube.com/profile_videos?user=BenjaKepler" ];
}
touch_start(integer total_number)
{
integer entry;
string webPage;
for(entry = 0;
entry < llGetListLength(urls);
entry++)
{
webPage = llList2String(urls,entry);

llParcelMediaCommandList([PARCEL_MEDIA_COMMAND_URL,
webPage]);
llSleep(5);
}
}
}

Music Streams


Copy and paste the script:

// Title: Music Streams
//
//
integer dialogChannel = 19242; // dialog channel
list stationMenu;
list streams;
string stationURL;

init()
{
llListen(dialogChannel, “”, NULL_KEY, “”); // listen for dialog answers
llSetTouchText(“Music”);
//
stationMenu = [“Radio Nigel”,”Club”,”Demented”,”80s”,”Top 500″];

streams = [“http://stream.radionigel.com:8020/”%5D; // Radio Nigel
streams+= [“http://scfire-chi0l-2.stream.aol.com:80/stream/1065”%5D; // Club
streams+= [“http://64.202.98.102:8000”%5D; // Demented radio
streams+= [“http://scfire-dll-aa01.stream.aol.com:80/stream/1040”%5D; // 80s
streams+= [“http://scfire-dll-aa01.stream.aol.com:80/stream/1074”%5D; // Top 500

}

default
{
state_entry()
{
init();
}

on_rez(integer start_param)
{
init();
}

touch(integer touchCounter)
{
llDialog(llDetectedKey(0), “Click a button to choose a different internet radio station”, stationMenu, dialogChannel); // present dialog on click
}

listen(integer channel, string name, key id, string chosenStation)
{
if(channel == dialogChannel){

integer place;
place = llListFindList(stationMenu,[chosenStation]);
stationURL = llList2String(streams, place);

llSetParcelMusicURL(stationURL);

llSetText(“Now playing ” + chosenStation + “\n” + stationURL,<1,0,0>,1.0);

} // end if

}// end listen

}

Gestures

Copy and paste the script:default
{
state_entry()
{
llListen(42,"",llGetOwner(),"");
}

listen(integer channel,string name,key id,string message)
{
if(message == "open") llSetPrimitiveParams([PRIM_PHANTOM,TRUE]);

if(message == "close") llSetPrimitiveParams([PRIM_PHANTOM,FALSE]);
}
}

A Welcome Mat

Copy and paste the script:-

string previously_Welcomed;
default
{
touch_start(integer total_number)
{
llSetTimerEvent(30);
}
collision(integer numDetected)
{
if(llDetectedName(0) != previously_Welcomed)
{
previously_Welcomed=llDetectedName(0);
llSay(0,"Welcome " + llDetectedName(0));
}
}
timer()
{
previously_Welcomed = "";
}
}

A Night Light

Copy and paste the script:-

float sun_height;
vector sun_position;
default
{
state_entry()
{

}

touch_start(integer total_number)
{
llSetTimerEvent(600.0);
}
timer()
{
sun_position = llGetSunDirection();
sun_height = sun_position.z;

if(sun_height < 0.0)
{
llSetPrimitiveParams([PRIM_FULLBRIGHT,
ALL_SIDES,
TRUE]);
}
else
{
llSetPrimitiveParams([PRIM_FULLBRIGHT,
ALL_SIDES,
FALSE]);
}

}
}

Background Bird Songs

Copy and paste the script:-

// Title: British Birdsongs
// Written: 11/04/2007
// Comments:
//
//
//
string version = "version: 1.00"; // change for each version
list listSongs;
integer counter;
integer songCount;
integer song;

//
// GMT time display in HH:MM format
//
float seconds;
float hours;
float minutes;
integer hh;
integer mm;
integer ss;
string HH;
string MM;

string hhmm()
{
seconds = llGetGMTclock();
hours = (seconds/3600);
hh = (integer)hours;
HH = (string)hh;
if(hh < 10) HH = "0" + HH;

minutes = (hours - (integer)hours) * 60;
mm = (integer)minutes;
MM = (string)mm;

if(mm ";
}
//
zzDisplay(list out) { // output debug info
llOwnerSay(llList2CSV(out));
}

// global initialization function.
//
init()
{
llOwnerSay(hhmm() + version);
llSetObjectDesc(version);
//
listSongs = [];
songCount = llGetInventoryNumber(INVENTORY_SOUND);
for(counter=0;counter < songCount;counter++){
listSongs += llGetInventoryName(INVENTORY_SOUND,counter);
}
llSetTimerEvent(11);
}

default
{
state_entry()
{
init();
}

on_rez(integer start_param)
{
init();
}

timer()
{
song = (integer)llFrand(songCount);
llPlaySound(llList2String(listSongs,song),1.0);

}
}

Avatar Height

Copy and paste the script:
default
{
state_entry()
{

}

touch_start(integer touchCounter)
{
string fullname = llDetectedName(0);
key avatarKey = llDetectedKey(0);

vector size = llGetAgentSize(avatarKey);
float height = size.z;

llSay(0,fullname + " you are " + (string)height + " metres tall");
}
}