Spent multiple hours trying to find out why a bug existed.
local x = {val = "123", val2 = {x = 0}}
local y = table.clone(x)
print(tostring(x), tostring(y)) --different memory addresses
print(tostring(x.val2), tostring(y.val2)) --despite being cloned, those still have the same address
I feel like very bad things would happen if I didn’t know about this
Yeah I realized I need to do something like this, I just wish they could say it doesn’t clone other tables in the description of the function in Studio, since I haven’t checked the documentation about table.clone but just saw it from autocomplete