Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Object which can receive and give sounds (podcasts)

Niko Bromberg
Registered User
Join date: 30 May 2008
Posts: 14
08-14-2008 02:02
Hello again!

I am trying to build an object which when clicked provides 2 options, 1 for an avatar to drop a sound the other for an avatar to receive the sound held by the object. The idea behind this is so that an avatar can drop a podcast into an object for fellow avatars to receive, this could be useful within educational use for SL as lectures for example could be recorded and listened to. Heres what I have at the moment. However while a sound can be dropped into the object, it cannot give the sound. More errors are apparent as the message confirming the sound drop appears before anything being entered. Obviously this needs allot more work with a sub menu displaying the relevant sounds for a avatar to collect. However i appear stuck at this hurdle.

Any help = Many thanks and maxi respect


integer CHANNEL = 42;
list MENU_MAIN = ["Leave Podcast", "Collect Podcast "];
key id;

default
{
state_entry()
{
llListen(CHANNEL, "", "", "";);
id = llDetectedKey(0);
}

touch_start(integer total_number)
{
llDialog(llDetectedKey(0), "What would you like to do?", MENU_MAIN, CHANNEL);
}

listen(integer channel, string name, key id, string message)
{
if (message == "Leave Podcast";)
{
llAllowInventoryDrop(TRUE);
llSay(0, "Please drop your podcast here by dragging it into the box from your inventory.";);
if (CHANGED_ALLOWED_DROP|CHANGED_INVENTORY)
{
llWhisper(0,"Thank you for leaving a podcast";);
}
else if (message == "Collect Podcast";)
{
llGiveInventory(id, "";);
}
}
}
}
Very Keynes
LSL is a Virus
Join date: 6 May 2006
Posts: 484
08-14-2008 02:15
How are you uplading the podcasts to start with?

AFAIK Sound uploads are limited to 10 second clips, you wont get much of a leture in that time. If it is a url pointing to an MP3 file than you may be better just sying the URL, in IM, to the recipient as they will have to manualy paste it into their Parcel Media settings to hear it, which they can only do if they own the land anyway.
Alternativly if they are for individual use you could refer them to a website out side of SL to listen to the podcast and to upload podcasts and just manage the list of URL's in your object useing llHTTPRequest.

Not sure if any of this helps, but it may save you a lot of time if you did not know the limitations on sound in SL.
Niko Bromberg
Registered User
Join date: 30 May 2008
Posts: 14
08-14-2008 02:47
Really? Bummer.

Thanks for letting me know that, would have thrown myself off a cliff if i gave more time to it only to find out later