of     1   

C_Sharper
#215928952Thursday, May 04, 2017 8:38 PM GMT

So if I were to return a table within a table, local tab = { Pokemon = {{Name = "MyPokemon",InPC = false} } function getIndex() return tab.Pokemon[1] end local poke = getIndex() poke.InPC = true Would this change update to the original table? Thanks.
HamilcarMago
#215929038Thursday, May 04, 2017 8:40 PM GMT

All you do is return what's inside the table, nothing is changing. Only this line - poke.InPC = true
C_Sharper
#215929203Thursday, May 04, 2017 8:43 PM GMT

Just was concerned if it passed the table by value rather than passing it by index, it seems now it was a stupid question to ask. Tables pass by reference regardless. If the first index of the table were to be a number, that'd be a different story. Thank you.

    of     1