Skip to content

Save Settings

lickx edited this page Oct 2, 2018 · 14 revisions

OpenSim is plagued by loss of script state. This can happen in various situations:

  • Local grid sim crossing between 2 different script engines (like XEngine vs YEngine)
  • Local grid sim crossing on the same script engine (occasionaly.. hard to reproduce consistently)
  • Teleport or sim crossing on another grid after the initial hypergrid teleport to the 1st sim
  • Relogging into a different sim on the local grid

What is script state? It means amongst other things the contents of any variables, and the state the state-machine is in.

One way to store data would be storing info in prim metadata; for example some strings can be stored (object name, desc), some keys (texture, sculptmap), some floats, some ints but space is very tight and we'd need a whole bunch of prims as 'prim harddisk'. If you're interested in this idea see this interesting implementation called PrimDrive.

To make recovering from script state loss easier, we made it so settings can not only be printed, but also saved to the .settings card. Do note that by design, the .settings card was never intended for the purpose of storing all kinds of stuff but we have no other easy recourse.

On a default OpenSim configuration, saving notecards will only work if you are the region owner or a region manager. To enable this functionality for any user visiting the region, look into "config-include/osslEnable.ini" for:

Allow_osMakeNotecard = ${OSSL|osslParcelO}ESTATE_MANAGER,ESTATE_OWNER

or

Allow_osMakeNotecard = ${XEngine|osslParcelO}ESTATE_MANAGER,ESTATE_OWNER

Change this line to read:

Allow_osMakeNotecard = true

Should this not be possible (ie. grid policy), then your only recourse is the method they use in SL:

  • Have the device unlocked or rez it on the ground
  • Press "Print" in the Settings dialog to get a printout of your settings in local chat
  • Type <prefix>show storage to make the storage prim appear
  • Open the .settings notecard within the storage prim, or create a new one if needed
  • Copy & paste the printed settings from local chat into the .settings notecard and save
  • Hide the storage prim again with <prefix>hide storage
Clone this wiki locally