Photon app running off multiple servers
Hi all
Kinda a bit of a cross over questions for multiple sections (sorry if a better forum area would have been better). Currently running an application using PUN and voice on a custom server. Im looking to split the logic across 2 servers so that 1 server handles the voice and 1 server can handle all the behaviour to help reduce load and fail safe the behaviour if the voice/chat server goes down.
Just wondering if anyone has an idea of how to go about modifying the unity voice/pun logic to ping stuff off to different servers as the settings appears to let me only connect to 1 ip.
Any help would be greatly apprichated
Regards
Kinda a bit of a cross over questions for multiple sections (sorry if a better forum area would have been better). Currently running an application using PUN and voice on a custom server. Im looking to split the logic across 2 servers so that 1 server handles the voice and 1 server can handle all the behaviour to help reduce load and fail safe the behaviour if the voice/chat server goes down.
Just wondering if anyone has an idea of how to go about modifying the unity voice/pun logic to ping stuff off to different servers as the settings appears to let me only connect to 1 ip.
Any help would be greatly apprichated
Regards
0
Comments
-
Hi @Reddevildragg,
Thank you for choosing Photon!
For the time being, you can set the voice server address manually/explicitly yourself in code, PhotonVoiceNetwork line 147:public static bool Connect() { if (PhotonNetwork.PhotonServerSettings.HostType == ServerSettings.HostingOption.SelfHosted) { string voiceMasterAddress = yourOwnVoiceServerAddress; // set the voice server address here return instance.client.Connect(voiceMasterAddress, null, null, PhotonNetwork.player.NickName, new LoadBalancing.AuthenticationValues(PhotonNetwork.player.UserId)); }
You can also change Nickname and UserId if you want. We use those from PUN currently.
We will discuss internally if we will add a setting from Unity editor/inspector to set a server address specific to voice only.0 -
Hi @JohnTube
Thanks for getting back, Will have a look into that script and make the changes needed
Thanks0