Can you change the table in a module script from a different script? Like something like this:
local table = require(modulescript)
table = newstuff
Does that change the module's table or the variable?
Can you change the table in a module script from a different script? Like something like this:
local table = require(modulescript)
table = newstuff
Does that change the module's table or the variable?
What you can do is have a variable that changes to newstuff, or whichever module scripts you need. Then use requirement with your variable
moduleName = MyModule
table = require(moduleName)
modulename = SomeOtherModule
table = require(modulename)
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
Pretty sure that would change the variable.