ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   Lua/XML Help (https://www.esoui.com/forums/forumdisplay.php?f=175)
-   -   SavedVars (https://www.esoui.com/forums/showthread.php?t=6669)

Rhyono 12/08/16 11:53 AM

SavedVars
 
I'll probably end up needing to post the code when I can, but I can at least describe the problem:

The script is indexing item name data to the SavedVars. It's supposed to put it in a table in a table (which it does), but randomly it'll end up putting some of the table vars in there as indexes with empty data. Such as SavedVars, @Rhyono, Defaults, a few of the data pieces as variable names (e.g. instead of [index] = data, it's [data] = "").

Ayantir 12/08/16 01:21 PM

I saw this long time ago when we were corrupting data because of too large files..

How big is your file ? do you play in 32bits?

You should use 64 bits client and avoid saved vars of more than 32MB and avoid arrays of more 10k entries.

Rhyono 12/08/16 01:27 PM

Quote:

Originally Posted by Ayantir (Post 29098)
avoid arrays of more 10k entries.

We have found the problem! :P

I had been saving it to file for easier load on the client, but I may just return to having it assemble it on demand live rather than saving it in a file.

Ayantir 12/08/16 02:52 PM

data from savedvars use a lot more memory and create loading incredibly much longer than rebuilding from scratch.

If your data don't need to be altered by user, generate it from API calls at startup, or if your data can't be accessed throught API, just provide big arrays of static data.


per example lorebooks addon with ~15k sub entries of static data only use 3MB in memory.

Rhyono 12/08/16 03:55 PM

Ah, good to know. Rebuilding each time is definitely the way to go then. Thanks!


All times are GMT -6. The time now is 12:21 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI