Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Renaming with llRemoteLoadScriptPin

Apple Giffen
Registered User
Join date: 18 Jun 2006
Posts: 19
07-03-2006 08:51
I have partially written an auto updater just for me personally, but I am having some problems with scripts names.

I have an update script which get the name of every script inside and sends an email asking for an update, etc etc, that part all work fine, the problem is that I am checking for new versions by the script name...ie "AppleVST-Server 0.5". This means that when the update happens, I am left with 2 scripts of differing versions.

Is there some reliable way to remove the old script after the update...considering i may have up to 10 scripts in an object.

thanks

Apple
Jesse Malthus
OMG HAX!
Join date: 21 Apr 2006
Posts: 649
07-03-2006 11:16
AFAIK, script renaming is not supported (as LL doesn't like us messing with the dataserver), but you could have in the post-script transfer section a call to llRemoveInventory(old_script_name)
Joannah Cramer
Registered User
Join date: 12 Apr 2006
Posts: 1,539
07-03-2006 11:23
From: Apple Giffen
Is there some reliable way to remove the old script after the update...considering i may have up to 10 scripts in an object.

You could overwrite it with new version of script that does only one thing -- removes itself from inventory? ^^;
Adriana Caligari
Registered User
Join date: 21 Apr 2005
Posts: 458
07-03-2006 13:34
The way I do it is to clean up first .


I send a cleaner script which loads itself - deletes all scripts except itself,

Then it requests the new scripts ( via email )

It sits and monitors until all the scripts are there then removes itself.

Or if the scripts do not arrive in a certain time it tries the whole thing again.

If after three tries it still fails it posts an im to the owner saying something has failed contact support etc etc

And it posts an email to a support email teling me object, revision, person, etc.

Not perfect , but so far ( crosses fingers ) I have never received a 3 times failure email
_____________________
Maker of quality Gadgets
Caligari Designs Store
Bitzer Balderdash
Dazed and Confused
Join date: 21 Dec 2005
Posts: 246
07-04-2006 03:16
From: Joannah Cramer
You could overwrite it with new version of script that does only one thing -- removes itself from inventory? ^^;


Sadly, no - ig you try to remote-load a script where one with the same name already exists, it fails.
Joannah Cramer
Registered User
Join date: 12 Apr 2006
Posts: 1,539
07-04-2006 05:30
From: Bitzer Balderdash
Sadly, no - ig you try to remote-load a script where one with the same name already exists, it fails.

Never had it happen in my experience. Wiki seems to be correct here when it states remote uploading script with name that already exists overwrites the present script without as much as a warning o.O;

http://secondlife.com/badgeo/wakka.php?wakka=llRemoteLoadScriptPin
Elanthius Flagstaff
Registered User
Join date: 30 Apr 2006
Posts: 1,534
07-04-2006 06:41
http://secondlife.com/badgeo/wakka.php?wakka=LibrarySelfUpgradingScript
Bitzer Balderdash
Dazed and Confused
Join date: 21 Dec 2005
Posts: 246
07-04-2006 09:15
From: Joannah Cramer
Never had it happen in my experience. Wiki seems to be correct here when it states remote uploading script with name that already exists overwrites the present script without as much as a warning o.O;

http://secondlife.com/badgeo/wakka.php?wakka=llRemoteLoadScriptPin


Great :) that means I had some other stupid error in my code when I tried this....

..... have to go back and play with it again :)