Photon Unity Networking 2: General Documentation

Photon Unity Networking 2

Photon Unity Networking 2  2.12
General Documentation

Table of Contents

Brief overview of Photon, subscriptions, hosting options and how to start.

Photon Unity Networking - First steps

When you import PUN, the "Wizard" window will pop up. If not, find it in the Window menu as "Photon Unity Networking". In the Wizard, either enter your email address to register for the Photon Cloud, enter the AppId of an existing account or skip this step for the time being.

The Wizard creates a configuration in the project, named: PhotonServerSettings.

PUN consists of quite a few files, however most functionality is concentrated into: Photon.Pun.PhotonNetwork. This class contains all functions and variables typically needed. If you ever have custom requirements, you can always modify the source files - this plugin is just an implementation of Photon after all.

To learn how this API works, visit the online documentation for PUN

Photon

Photon Unity Networking (PUN) always connects to a dedicated Photon server, which provides matchmaking, load balancing and in-room communication for players.

Behind the scenes PUN uses more than one server: A "Name Server" acts as point of entry and provides a list of regional "Master Servers". A Master Server keeps track of rooms and provides the Matchmaking, while several "Game Servers" run the actual rooms (matches).

Exit Games Cloud

The Exit Games Cloud provides hosted and load balanced Photon servers for you, fully managed by Exit Games. Free trials are available and subscription costs for commercial use are competitively low.

The Public Cloud service runs a fixed logic, so the clients need to be authoritative.

Clients are separated by “application id” (identifies your game title) and a “game version”. Changing the game version helps separate players with new and old client builds.

Subscriptions bought in Asset Store

If you bought a package with Photon Cloud Subscription in the Asset Store:

  • Register a Photon Cloud Account at this link
  • Create an App and get your AppID from the Dashboard
  • Send a Mail to: [email protected]
  • With:
    • Your Name and Company (if applicable)
    • Invoice/Purchase ID from the Asset Store
    • Photon Cloud AppID

Photon Server SDK

As alternative to the Photon Cloud service, you can run your own server and develop server side logic on top of our "Load Balancing" C# solution. This gives you full control of the server logic.

The Photon Server SDK can be downloaded at this link

Read about how to start the server here.

Online Documentation  -  Dashboard  -  Support Forum Exit Games GmbH