How can I modify clinents in multiplayer game ?

Message body


I’m a unity 3d newbie and I try to make a board game for my term project. I want this game to be a multiplayer online game (with maximum 6 players). Each player should move his own character when his turn comes. One of the players will connect as authoritative server and the others would be clients. Each client should be able to changes its properties like moving his character, or gaining points and … Besides, all other players should see these changes on their own screens. Where should all these informations about all the client be saved? and how can I modify each client ?

I’m not sure if I could explain what I mean.

I’m waiting for your helps. thanks a lot

Since you have an authoritative server, and it’s turn-based game, you can use the server to send all the clients an RPC (pay special attention to RPCMode)whenever a change occur. There’s no need to waste bandwidth with constant updates through OnSerializeNetworkView(), even at ReliableDeltaCompressed mode.

When a player makes a move, send it via RPC to the server, and send the result from the server via RPC as well, it’s all very simple. Authoritative server means the players cannot change their status themselves, so it should be fairly easy to control synchronizing data.

To display the changes just use plain old GUI (even the GC spikes shouldn’t bother you as it’s a turn-based game).

Good luck! :slight_smile: