Hey I have table with keys thad represent the function names when i do this it works
local example = {LocalFunction = true}
for fnName, _ in pairs(example) do
_G[fnName] = function()
print('This works')
end
end
LocalFunction() -- output This Works
But when I want it to be local it doesnt work is there any solution ?
local example = {LocalFunction = true}
for fnName, _ in pairs(example) do
local fnName = function()
print('This works')
end
end
LocalFunction() -- output nil value
Thanks in advance Neo