I have Lua script, that runs in every frame of simulation (eg. is restarted) and is called from C program.
I need to have some data persistent over time and change them from Lua script. How can I achieve this ? Persistent data are stored in table with certain name, so I can access this table from C application.
How can I store this table after script finish and restore it before it will run again ? Because with run again, values are set back to its default values.
Thank you