|
Zaplok Riggles
Registered User
Join date: 25 Feb 2008
Posts: 119
|
04-22-2008 08:35
I have a couple of scripts that contain data lists. When I update the code, I really don't want to lose the data in those scripts (which happens when I recompile the script). I've been bouncing around some ideas like having another object listen on a chat channel and have a way for the script to spit out its data. And then, a reverse procedure. That's really the best I could come up with. Anyone else have any ideas on this? I want to stay away from remote data storage via http for now. Thanks! Zaplok Riggles
|
|
Haruki Watanabe
llSLCrash(void);
Join date: 28 Mar 2007
Posts: 434
|
04-22-2008 08:40
I usually have a script that only stores the lists and another one communicating with that script via llMessageLinked. That way, when I have to update the script that processes the data, the list-contents won't be lost.
|
|
Kidd Krasner
Registered User
Join date: 1 Jan 2007
Posts: 1,938
|
04-23-2008 05:58
The well-known Mystitool product uses the backup object method, and it works fine. The advantage in their case is that they just give updated versions of the product to registered users, which is much simpler than trying to install updated scripts into an existing object. It does put the burden on the user to rez the backup object, do the backup, switch to the new version of the tool, and restore the settings from the backup object. It's slower than using linked messages, but linked messages won't work with this distribution model.
Depending on how the data is generated and used, you may even want to have several secondary scripts/objects. One would be for real use, but the others could be for testing purposes. It's faster to just swap scripts in an object than it is, for example, to swap notecards (because reading the updated notecard is slow).
|