Why is my client able to make a door move without any server RPC call?

Hello everyone! I need clarification on the way replication works. I setup a simple door actor with replication on and events to open and close it. These events are not RPC’s and yet when the client opens it, the door’s movement replicates to all client and the server.

My question is, shouldn’t the server stop the door from moving since it has authority? I am asking this because in a similar situation with a sprint input on a character, the server does stop the client from sprinting unless a server RPC is called.

Collision/Overlap events happen both on server and on clients, so your code in the first picture is already running on all machines. Do note however that in some edge cases (if you stop at the very edge of the collision box), overlap might trigger for some machines and not for others, due to movement not being perfectly synchronized. If you need the door to be better synced, add an Authority switch at the overlap events so that only the server decides when to open/close it. In that case you’ll have to replicate door movement or state (preferably using variable rather than RPC).

Input events however only happen on the client pressing those inputs, so most of the time you need to replicate actions to server to interact with game world.

1 Like

Thank you for the explanation and the tips!