In case you didn't know, there is an interesting seralizer at lua-users.org, which can serialize almost anything. And by "anything" I mean that it includes very complex objects, like a table with a metatable which has a __index function which refers to a table which in turn has a metatable. Or a table which contains itself, is a key for itself in itself, is the meta of itself and the __index of itself (How's that supposed to work, actually? Crash from infinite recursion?). Unfortunately, CC doesn't have debug library active, so certain features won't work, like upvalues and
cleverly hidden completely sandboxed metatables. But still, this thing is very useful.
1.
Download the code from
http://lua-users.org/wiki/DataDumper and upload it somehow onto your CC computer.
2. In the beginning of your sender program, call
dofile() with the name of the uploaded DataDumper.
3. When you want do dump something into a string, call
DataDumper() with your object as a parameter.
4. DataDumper will return a bunch of text
written in Lua, which, when executed, will create an exact copy of the original object. To execute this string from your receiver program, call
loadstring() with this string, and it will return a function which you then should call. This function will return a copy of your object.