In the case of Lua scripting, only a few options are available. One is to have the scripts contain a load/save function that they manage themselves. Another option is to have the lua script register the variables with C++, and let c++ take care of loading and saving this particular variables, this requiring no more then a registerSerialize("variableName") for each variable. These are the only way of doing it I can think of.
-- Extra cheese comes at a cost. Bradley Arsenault.