Are there any downsides to putting everything in a LocalScript for a single-player game?

Greetings developers,

I’m wanting to know if there are any downsides to putting all of the code in a LocalScript for a single player game.

1 Like

Yes, there are multiple:

  • Exploitability is the big one I think.
  • No access to server-only services like HTTP service and data stores
  • More code being run and stored on the client can increase memory and CPU usage
  • No access to ServerStorage which could cause an influx of memory usage because you have to use ReplicatedStorage which means stored/not visible instances will be always in memory.

Really, you should only give the client control over things that only are visible to themselves. Even when it’s a single-player game. For example, UIs, client-only physics objects, the character etc…

3 Likes

Yup, It does a lot actually.

That’s how Exploiters actually exploit Client script is on their computer meaning that they can change anything and do what they want and ruin your game…
Second of all the Client’s CPU will increase.

1 Like