So lets say I have a modulescript and I want to iterate through every variable I declared within module.new() from module.new()
what argument to getfenv() would you use?
For example, this is a modulescript in workspace
local module = {}
function module.new()
local asdf = "ASDF"
local num = 1
local char = 'a'
for _, v in pairs(getfenv()) do
print(v);
end
end
module.__index = module
return module
and this is another script in workspace
local test = require(script.Parent.ModuleScript)
test.new()
Yet when it runs, it only prints the name of the ModuleScript
