Replication through game sessions

When testing in the editor, you can adjust the Play settings to use a dedicated server. Both client A and client B will then be treated the same. No idea how to construct an actual server, though.

You can force your events to be executed only on the server (or only client-side) by flagging the event with the corresponding UFUNCTION property (in C++) or by ticking the corresponding box in the event properties (Blueprint). Note that this only works for events, so these methods can’t have any return values.