PUN 1.9.6 preview - Delta compression InstantiateSceneObject

Hi all,

With Tobias attending GDC, I'm taking over the following service announcement ;):
We have quite an important PUN update ready, but want to go trough some testing before putting this live.

The major improvement is the new delta compression for PhotonViews configured to "reliable delta compression" (previously there was no delta compression). In a controlled test this saved a lot of traffic for a single client. Since the Photon (cloud) servers forward traffic to all other clients this gain is even better at the server side. I have no idea how this compression works out for real life situations though(!).
If you are curious about how much traffic this saves on your game: You can use the PhotonStatsGui script in 1.9.0 and compare it's values against 1.9.5.

There are no known issues in this version and I don't expect the delta compression to cause any, but again, this is a preview/test version :).

Edit: Updated to 1.9.6

Note: While the reliable delta compression will save a lot of bandwidth, for performance reasons it is sometimes still best to use unreliable. To quote Unity: "In general, you should use Unreliable sending where quick, frequent updates are more important than missed packets. Conversely, when data doesn't change so frequently, you can use reliable delta compression to save bandwidth." http://unity3d.com/support/documentation/Components/net-StateSynchronization.html

Download PUN 1.9.6

New: PhotonNetwork.InstantiateSceneObject to spawn scene based objects that persist even if the current master client drops (usefull for AI etc.)
Workaround: calling LeaveRoom in Disconnect to prevent a rare bug where players get stuck in room while being disconnected.
Improved: offline mode will now also fire OnJoinedRoom after calling CreateRoom
Fixed: No null playerName when using offline mode
Fixed: MC and ID's not set correctly after switching from offline mode to online

New: Delta compression has been added to the observe option of reliable PhotonViews. This greatly reduces the network bandwidth. 
Fixed: OnLeftRoom error.
Fixed: Stats timer didn't reset
Moved: OnPhotonSerializeView and OnPhotonInstantiate to enums.cs (PhotonNetworkingMessages)
Improved: Minor editor optimization


  • Please... let me insert my money into your crevasse ASAP.
  • Updated to 1.9.6
  • Will MovementMotors and PhotonViews work on scene owned objects in this build too? The ability for one player to transform a scene owned object and have it affect all other instances of that object is pretty essential for all but the simplest of games...
  • No, what this adds is runtime spawning of scene based objects. But the workings have not changed: Scene based objects are controllable by the master client only, and MC switching works automatically. So still only 1 player at once.

    I believe you want objects that can be controlled by any player? That would require runtime switching of the PhotonView owner.
  • New: PhotonNetwork.InstantiateSceneObject to spawn scene based objects that persist even if the current master client drops (usefull for AI etc.)

    This is really exciting, thank you!
Sign In or Register to comment.