Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local tTable = {
- [1] = {"pbin code", "progName" },
- [2] = {"another pbin code", "another progName"},
- }
- function writeTo( prog )
- local file = fs.open( prog, "w" )
- file.write( textutils.serialize( tTable ) )
- file.close()
- end
- function readIt( prog )
- local file = fs.open( prog, "r" )
- local handler = file.readAll()
- file.close()
- return textutils.unserialize( handler )
- end
- writeTo( "x" )
- local parm = readIt( "x" )
- print(parm[2][1])
- --tTable[#tTable + 1] = {} I know this wont work
- table.insert(tTable[3], "another another pbin code")
- print(tTable[3][1])
- --I need to create a table somehow
Advertisement
Add Comment
Please, Sign In to add comment