Photon Pun Version
Options
Hi, where I can download an old photon version? I mean 1.57, 1.58, 1.59
Regards,
Regards,
0
Comments
-
Why do you need old versions? They may not work properly with current Photon Cloud servers.0
-
Hi @Markus, I want to try with older versions because with the 1.60 Photon version Im getting some weird error, this error:
KeyNotFoundException: The given key was not present in the dictionary.
System.Collections.Generic.Dictionary`2[System.Int32,PlayerDataAutoLobby].get_Item (Int32 key) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:150)
I dont know why, I am currently using the Photon version v1.56 + Unity 5.1.2 and work very good but with the version 1.60 Im getting that. Can you help me @Markus ?
Regards0 -
Hi @vadim, thanks for reply,
this is the full exception:
KeyNotFoundException: The given key was not present in the dictionary.
System.Collections.Generic.Dictionary`2[System.Int32,PlayerDataAutoLobby].get_Item (Int32 key) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:150)
AutoLobby.checkIfPlayersAreReady (Int32 thePlayerList) (at Assets/Multiplayer2DPlatformer/UI/AutoLobby.cs:90)
AutoLobby.Update () (at Assets/Multiplayer2DPlatformer/UI/AutoLobby.cs:75)
And here I attach my full AutoLobby class:
AutoLobby.cs
Regards,
0 -
The error is thrown because 'players' dictionary accessed with non-existing key. You need to check how this dictionary updated on PhotonNetwork.playerList change. Or better do not use storage parallel to PhotonNetwork.playerList but rather keep player's variables in custom properties.
The only breaking change we made in 1.60 is http://forum.photonengine.com/discussion/6426/autojoinlobby-disabled-in-pun-v1-60#latest
We do not provide older PUN versions for download.0 -
Call PhotonNetwork.player.SetCustomProperties(...) on one client and get properties from player.customProperties hashtable on others. Check UtilityScripts/PunTeams.cs scipt for call samples.
To get notifications on properties change, handle OnPhotonCustomRoomPropertiesChanged message.
The question is quite popular in forum. Try search for more info.0