[SOLVED] (HUMP) 'Gamestate.switch' changes the references of the tables passed in parameters
Posted: Wed Nov 09, 2022 6:00 pm
I noticed that when I passed tables as a parameter with Gamestate.switch(to, ...) the reference of this table was no longer the same, which caused me errors in a larger project where I put an instantiated class as a parameter and where its previously initialized values ended up on nil.
Here is an example to download that I did quickly to illustrate the problem, you have to see in the console for the references.
Here is an example to download that I did quickly to illustrate the problem, you have to see in the console for the references.