Simple Game Summary

Checked with version: 5.3

-

Difficulty: Intermediate

With this example, we have covered most of the basic concepts and components needed to make a simple Multiplayer Networked game.

We have covered that basic architecture of a project written to use the Multiplayer Networking High Level API (HLAPI). We understand that when using the HLAPI, the Server and all of the Clients are executing the same code from the same scripts on the same GameObjects at the same time. We have discussed how to control the flow of logic when using the HLAPI with checks for the Server, LocalPlayer and Client.

We have covered the RPCs available to the HLAPI; both Commands and ClientRpc’s. We have seen how to work with Commands, which are called on the Client and are executed on the Server; and ClientRpc’s, which are called on the Server, but invoked on the Clients.

We have covered SyncVars and SyncVar hooks. We can keep variables in sync with the [SyncVar] attribute, and call functions when the values change with SyncVar hooks.

We have seen how we can keep the Transforms of our networked GameObjects synchronized with the the NetworkIdentity and the NetworkTransform component.

We have covered many of the built-in components available under Networking in the editor, including the NetworkManager, the NetworkManagerHUD and the NetworkStartPosition. There are more built-in components available under Networking, but these are more specialized, not used as frequently and will be covered in other lessons.

We hope that this lesson has proven to be a good starting point for understanding how to make a Networked Multiplayer project and that this quick overview of the most important aspects of the system have shown how easy it is to create Multiplayer games in Unity.

For more information on Multiplayer Networking, please see the lessons and documentation pages linked below.

Related documentation