Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Can this be done?.....

Mitzpatrick Fitzsimmons
Neurotican Mage
Join date: 20 Sep 2004
Posts: 62
07-23-2005 14:21
Greetings all,

Can this be done?....

I have a Widget that I sell.

I want it to have the ability to give an EXACT COPY of itself to the person that owns it just before it DIES.

I dont want the Widget to be an "endless self-replicating" object... in other words.. the Owner will NEVER be able to get 2 or more Widgets from the one Widget (as it is set to No MOD/ No COPY/ Yes SELL)... but the Owner will not risk LOSING his Purchased Widget when it DIES.

This Widget WILL DIE at some point after the Owner Rezzez it... this is already known (unless the Owner Takes it before it Dies, in which case the Widget will not have Replicated itself...so the Owner still has only 1 Widget in possession).

Any Help is GREATLY APPRECIATED..and if you can show me how to make this possible...you will be my Hero for the Day!
Zapoteth Zaius
Is back
Join date: 14 Feb 2004
Posts: 5,634
07-23-2005 15:55
I'm not a scripter, but it seems that the bit that can't be done is giving out copies and keeping it no copy. As they'd have to be a copiable version inside to give out. I think.. But I may be wrong..
_____________________
I have the right to remain silent. Anything I say will be misquoted and used against me.
---------------
Zapoteth Designs, Temotu (100,50)
---------------
Minsk Oud
Registered User
Join date: 12 Jul 2005
Posts: 85
07-23-2005 17:15
Problem there: when an avatar is offline there is no way to add things to its inventory. Even if you could detect all possible causes of object destruction (simulator crash, for one, is impossible) there is not necessarily a way to get the copy home in time.

This is the general problem of vehicles that can be resold, so I would not count on a solution short of a change to SL.
Champie Jack
Registered User
Join date: 6 Dec 2003
Posts: 1,156
07-23-2005 18:10
ok, before all the doom and gloom scenarios that call for LSL to be radically different, lets get some more info...

How many copies do you suspect the widget will give?
What are the conditions that will call the llDie command?

Also, as far as giving the object to an AV as opposed to just rezzing it, you have a few options. However, you cannot give inventory to an AV who is offline, but there are ways around that problem. In fact I can think of a couple creative ways around that (thanks to the WIKI folks who always offer lots of possibilities). It just depends on how much "back-end" support you want to build into your project.

read this page in the WIKI: llGiveInventory

and IM me if you would like to discuss this further

Champie
_____________________
Velox Severine
Network Slave
Join date: 19 May 2005
Posts: 73
07-24-2005 19:53
You also might have a central server that the Widget llEmails before its death, then gives a copy to the owner from the central server.
_____________________
--BEGIN SIGNATURE STRING--
IkkgY2FtZSwgSSBzYXcsIEkgY29ucXVlcmVkLiIgLS1KdWxpdXMgQ2Flc2Fy
--END SIGNATURE STRING--
Escort DeFarge
Together
Join date: 18 Nov 2004
Posts: 681
07-25-2005 12:14
I am really quite unclear as to how this differs from giving a "no copy" widget in the first place...

/esc
_____________________
http://slurl.com/secondlife/Together
Escort DeFarge
Together
Join date: 18 Nov 2004
Posts: 681
07-25-2005 12:50
Or did you mean this... (with appropriate perms set)...?
CODE
integer count = 0;
float time = 15.0;
default {
state_entry() {
llSetTimerEvent(time);
}

timer() {
if (count++ == FALSE) {
llGiveInventory(llGetOwner(), "ME");
}
llDie();
}

on_rez(integer start_param) {
llSetTimerEvent(time);
}
}
_____________________
http://slurl.com/secondlife/Together