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

Anyone have a good explanation of what a Module Script is?

Asked by
devDave 50
10 years ago

For some reason the Wiki wont load for me, but a simple explanation of what it does and what I can do for it will be very helpful.

1 answer

Log in to vote
1
Answered by 10 years ago

I don't use Module scripts very often, but I do have a basic idea of what it does. Module scripts don't execute immediately whenever the game starts, and will run only once by calling require().

Example:

local mod = require(game.Workspace.Modulescript)
printmod("Test Print")

If you use it locally, it will run only once for a player. Same as with server-side scripts.

Whenever the Wiki starts working for you, here's the direct link to help you further.

If you have any further questions, you can send a message through my ROBLOX inbox.

~Kyo-Chan

Ad

Answer this question