Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I put a table inside another table?

Asked by
hajka3 0
4 years ago

I have MULTIPLE scripts, each of them has a table. I need to make it so these tables are the values of another table, which is located in another script. How do I do that? Thank you!

1 answer

Log in to vote
0
Answered by 4 years ago

multiple ways to do that. you can do

MotherTable = {}
MotherTable.Child = {}


or,

MotherTable[1] = {}

you can also do,

MotherTable = {}
local c = {}
MotherTable.Child = c
Ad

Answer this question