Official ScriptUO EasyUO Scripts > Script Debug

Saving settings?

(1/3) > >>

lob91:
Hey.. been away from scripting for a while, anywho... looking to only be required to do the initial setup once and then be able to always start with those setting presaved (from the first and only setup)

can anyone point me in the right dirrection on what I might use? Thank you.

TrailMyx:
I'm in the process of releasing my new filesystem.   With that you can store/recall variables very easily.  Also with an additional set of routines, you can browse other contents managed by the file system.  I'm calling this my next-generation file system.  NGFS for short.  Sorry Star Trek, no relation.

So perhaps you might give them a try.  I'll probably be releasing something usable in a week or two.

lob91:
looks sweet! What I am looking for should be pretty simple. I just need it to save 25 locations on the screen and save it so I don't have to reset the locations everytime I run the script

TrailMyx:

--- Quote from: lob91 on April 04, 2010, 10:59:45 PM ---looks sweet! What I am looking for should be pretty simple. I just need it to save 25 locations on the screen and save it so I don't have to reset the locations everytime I run the script

--- End quote ---

The file system should be right up your alley then.  You just have to "register" each variable you want to be tracked by the file system, and it does the rest.  Very simple, and almost no work on your part other than the registration.

12TimesOver:
Lob,

In the meantime there is really a couple of ways to do it. The most common is to simply use persistent variables for the information you want to save (* instead of % or !). Each of these will be stored as an entry in the registry which can end up getting pretty cluttered (as you can imagine) especially after years of running scripts without cleaning anything up. THis is why people come up with "File Systems" to begin with. There are a couple of these available including TM's File handling subs as well as the CEO File System at EUO (which stores all of the variables in a single Reg entry.

But you can easily move forward with just using persistents. Usually what I do is try to give them a name that will be easy to identify when browsing the registry. For example, say you have a lumberjack script and you want to save the "Bank" option I would call the var something like *lobLJBank -see what I mean?

There is no way to delete the reg entries with EUO after creating them so try to keep the Persistents only to the necessary ones!

X

Navigation

[0] Message Index

[#] Next page

Go to full version