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

What is the difference between local script and script?

Asked by 6 years ago
Edited 6 years ago

And when do I use them?

0
research plz TheeDeathCaster 2368 — 6y
0
The difference is that a LocalScript is used when you want the client in the game to change something. Scripts are used for telling the server what to do. ReallyUnikatni 68 — 6y

1 answer

Log in to vote
1
Answered by 6 years ago

Local scripts are normally used in starter gui, starterplayer, starter player scripts.. etc... Localscripts can access a player. If localscripts are placed in the players startergui, it can alter what other players see.. Meaning you can make a door opened for a specific person..

Regular scripts can change values, cannot use game.Players.LocalPlayer and can save data which localscripts cannot do! scripts can also change items in the server.. Like, update a timer for every player in the game... Regular scripts come in as much handy as localscripts do...

There are also module scripts... Used to create functions and when called from another script using require(), those functions can be used in other scripts

0
Thanks greatneil80! I've been studying as much as possible about scripting. I've started about 2 months ago and I've not known about this. So, thank you! massivegem45 -12 — 6y
0
You are most certainly welcome :) greatneil80 2647 — 6y
Ad

Answer this question