I don't quite understand the replicated storage

People keep saying that “you should store remote events in replicated storage because it can be viewed by the client and the server”. But what exactly does this mean?

So far, im not understanding anything.

1 Like

It’s a storage where you put things to be accessed from the server and client. RemoteEvents need to be put here because they need to be accessed by the server and client to work.

Read more about RemoteEvents

Read more about ReplicatedStorage

1 Like

That clarifies, but what does it mean for something to be inaccessible to the client? would the client be completely prohibited from that service?

Are you talking about RemoteEvents?

1 Like

So basically, depending on where you put stuff, the client (local scripts basically) or server (server scripts) can access the thing.

If I put a remote event in Server Script Storage, although I can access it with a server script, I can’t access it with a local script.

It doesn’t have to be a remote event, and be anything else like a part.

If you try to put a part in StarterPlayerScripts, the client can access it, but the server is unable to access it and you would simply get an error if you tried accessing it from the server

2 Likes

Pretty much also as @ChickHenEn said but a visual way within studio.

I believe you can still access it

Very easy way is to look in studio with the client to server view.

Server view:

Server has access to these services ReplicatedStorage, ServerScriptService with a script and remove event inside

image

Client view:

Client does not have access to ServerScriptService instances within, only the remove event in replicated storage

image

Hence the stuff in replicated storage

You can also repeat this experiment by trying to access them with a script and local script with game.ServerScriptService.RemoveEvent to verify for yourself and it’s functionality for your game.

3 Likes

Precisely. I just commonly hear the that “objects in Replicated Storage are accessible by the client and server” and I was wondering what exactly it means for something to be accessible by client and server, solved in another post below. Thanks for the help

I think in my opinion the remote event is like a bridge for communication