Multiplayer

Applications built with MAGES™ SDK are multiplayer/network ready, meaning that with a few more actions needed by the developers, multiple users can cooperate and complete these simulations together online [M_1].

In this section we will go through the details that developers need to check to ensure that their application is multiplayer/network ready, as well as a tutorial on how a user can create and/or join multiplayer sessions within a MAGES™ application.

Networking Developer Guidlines

MAGES™ SDK supports Photon networking as the default networking API. Photon SDK is already installed in the MAGES plugin.

First, you need to create an account at Photon.

After successful registration, go to the Photon Dashboard and click the CREATE A NEW APP button.

Photon Create New App Button

Select Photon Realtime from the Photon type dropdown, give a name to your application and click the CREATE button.

Photon Create Application

Navigate back to the main dashboard page and you will see your new RealTime application. You need to copy the App ID.

Photon PUN ID

Note

Click the code next to the App ID to reveal the full key.

Open the Unreal project and in the project’s settings; select the MAGES Settings section on the left and paste the Photon App ID on the Photon App ID field.

Photon PUN ID Login Window

Host Online Session

  1. Once you start the simulation, you will be greeted with two options. Starting the simulation in Single Player, or go to Online Sessions.

    ../../../_images/HostCoop11.png

  2. Select the Online Sessions. There you will be able to create a new session and wait for other to join, or join an existing session that is demonstrated on the Sessions board.

    ../../../_images/HostCoop21.png

  3. To Create a session, select the Create New Session button.

  4. Wait for others to join. If at least one more user has joined, you will be able to start your online session.

    ../../../_images/HostCoop31.png

  5. If you want to go back, select Exit VR to quit.

Join Online Session

  1. Once you start the simulation, you will be greeted with two options. Starting the simulation in Single Player, or go to Online Sessions.

    ../../../_images/HostCoop11.png

  2. Select the Online Sessions. There you will be able to create a new session and wait for other to join, or join an existing session that is demonstrated on the Sessions board.


  1. Select an available session from the Sessions board, and select Join Session. Each available session will demonstrate all connected users.

    ../../../_images/JoinCoop21.png

  2. If you want to go back, select Exit VR to quit.


References

M_1

Kamarianakis, M., Lydatakis, N., & Papagiannakis, G. (2021, September). Never ‘Drop the Ball’in the Operating Room: An Efficient Hand-Based VR HMD Controller Interpolation Algorithm, for Collaborative, Networked Virtual Environments. In Computer Graphics International Conference (pp. 694-704). Springer, Cham.