PUN Classic (v1), PUN 2 and Bolt are in maintenance mode. PUN 2 will support Unity 2019 to 2022, but no new features will be added. Of course all your PUN & Bolt projects will continue to work and run with the known performance in the future. For any upcoming or new projects: please switch to Photon Fusion or Quantum.

Known Issues

On this page, we will list known issues with Photon on the various platforms. The focus here is on issues which we can't fix or workaround. In some cases, this means we will simply list broken versions per platform and guide you to other versions.

Contents

Running In Background

On mobile platforms, if the app moves to background it pauses the main message loop which is responsible for keeping the client connected among other things.

Typical causes of this are:

  • Player hits "home button".
  • Phone call received.
  • Video ads.
  • Third party plugin that introduces an overlay view in the app (e.g. Facebook, Google, etc.).

On iOS, applications can not keep a connection, while in background (see Background Execution on the Apple dev pages). It might make sense to Disconnect the client, when the app switches to the background.

On WebGL, it might also make sense to set a PlayerTTL and reconnect to the session when the tab is back in focus. Often, browsers will not run JS and WebAssembly in the background. In some cases, this can be worked aorund by playing audio (even inaudible one) while in the background.

PUN has a background fallback thread that keeps client connected to server where possible.

To keep connection alive, the background thread sends ACKs only to server for a limited time. The default background thread timeout is 60 seconds. You can change it using PhotonNetwork.KeepAliveInBackground. After the background timeout, PUN will disconnect the client gracefully. If the client was joined to a room before moving to background PUN will try -if needed- to reconnect and rejoin the same room as soon as the app is foreground again.

Back To Top
 

PhotonAnimatorView And Triggers

If you use Trigger parameters in animator controllers and want to synchronize them using "PhotonAnimatorView", it's important to consider how this is handled to avoid issues.

  • Due to the nature of the Trigger(s), it is only enabled when the animation event starts and disabled immediately before the next Update()
  • Components on a GameObject are executed in the same order as they are declared
  • Editing the Order of Execution Settings will affect execution order on the GameObject's components

It essential that the "PhotonAnimatorView" component is executed after the code that raises the Trigger(s). So it's safer to put it at the bottom of the stack, or at least below the component(s) that will be responsible for raising the Trigger(s) using Animator.SetTrigger(...).

The "PhotonAnimatorView" Inspector shows the various paramaters current values. A good way to check even before publishing is that the Trigger is properly raised to true when it should. If you don't see it happening, chances are this particular Trigger won't be synchronized over the network.


To Document Top