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

If i use a local script, will it be accessible to all players?

Asked by 8 years ago

If i make a local script into starter pack or starter gui, then does the script apply to all players?

1 answer

Log in to vote
0
Answered by 8 years ago

Yes, sort of.

StarterGui And StarterPack Clones everything and moves it to players when they join. This is termed as Replication.

So the script won't affect anything, only its copies.

With FE on, LocalScripts only cause Local Changes. This is great for things like user input, or making local changes to workspace.

You can make the copy's of the script not apply to all players by simply adding an if statement, like this,

--LocalScript
local plr = game.Players.LocalPlayer

if plr.Name == "wfvj014" then

    ---Code

end

The code you add would only apply to me.

That's all.

Good Luck!

0
Thank you!!!! lil_broskey 0 — 8y
0
Could you accept my answer please? It helps a lot. User#11440 120 — 8y
0
<3 User#11440 120 — 8y
Ad

Answer this question