This page will explain how the Unity EdgeMultiplay solution works, If you want information about how to add EdgeMultiplay to your Unity project, please check the Configuration section.
EdgeMultiplay is Unity Multiplayer Solution, EdgeMultiplay client uses Websockets & UDP Messages to communicate with a NodeJS Server that uses cluster module for scalability.
to use EdgeMultiplay in Unity you need to have a GameManager & a PlayerManager
You can find a template of both in Assets/Create/EdgeMultiplay
Let's start with the GameManager these are the requirements for your GameManager :
In your GameManager you can start the Connection to the server by using ConnectToEdge()
In your GameManager you can access all of the EdgeMultiplay callbacks, A callback is a function that is to be executed after another function has finished executing
See full list of EdgeMultiplayCallbacks here
Once the player is registered on the server, It is the best time to call CreateRoom() or JoinRoom() or JoinOrCreateRoom()
Once the Game Starts, EdgeManager will spawn players in the specified positions in EdgeManager.SpawnInfo
Players can send GamePlay Events using EdgeManager.BroadcastMessage()
If a player received a message it will be available in OnMessageReceived()
If you want to sync a player position and/or rotation add EdgeMultiplayObserver, Syncing Objects is done using UDP messages.