Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Spawning a function/instance in Module results in a Module Error? [SOLVED]

Asked by 3 years ago
Edited by JesseSong 3 years ago

Hey there, I've been off studio for over 4 months, and I believe a new Lua Update was released around that time, and it broke many of my scripts that were mainly Modules, usually I'd set up a function in a module, and call it with a script using:

local Module = require(game.Workspace.TestModule)
spawn(Module.FadeScreen)

And the module would probably contain code like

local TestModule= {}

function TestModule:FadeScreen(config)
    --blah blah
end


return TestModule

Around one month before I left studio for some time it worked, but now I don't know what to do or replace it with.

1 answer

Log in to vote
0
Answered by 3 years ago

Actually I found out it was a beta feature that broke it lol

Ad

Answer this question