Search Unity

Third Party Hello World example for Photon Server

Discussion in 'Multiplayer' started by SirZdanius, Mar 1, 2022.

  1. SirZdanius

    SirZdanius

    Joined:
    Oct 13, 2021
    Posts:
    3
    Hi,

    My team is exploring different multiplayer topologies with Photon right now. As part of our investigation, we would like to get the basic dev experience of using Photon Server as the backend.

    We have already tried the Fusion and Realtime examples described in the docs on the website and they work well, but they both automagically connect the demo clients through the Photon Cloud.

    A custom server makes sense with our requirements, and we have managed to run a Photon Server locally. However, there seem to be no docs or examples on how/where to add custom logic to the server, or how to connect a simple client app to it (or even how to modify one of the Fusion or Realtime examples to use a local server).

    Does anyone have any resources (docs or a good tutorial) for creating a Hello World multiplayer game using a local Photon Server?

    Thanks in advance
     
  2. tobiass

    tobiass

    Joined:
    Apr 7, 2009
    Posts:
    3,070
    If you run the Photon Server without modification, clients can use it similar to the Photon Cloud.
    The Server SDK docs explain how to run it. The Server Plugins are a simple way to modify/add logic per room. And there are docs that explain lower level work with the Server. It can be full customized.

    You are right, we are missing some doc to explain how to setup the client. It's easy though: Use LoadBalancingClient.ConnectUsingSettings() and set a Server value in those settings. That is basically it.
    The doc for PUN details some settings.
     
    SirZdanius likes this.
  3. SirZdanius

    SirZdanius

    Joined:
    Oct 13, 2021
    Posts:
    3
    This is a lot of new info!

    I'll get to reading, thanks a bunch :)
     
  4. SirZdanius

    SirZdanius

    Joined:
    Oct 13, 2021
    Posts:
    3
    Your response gave me all the info I needed and allowed me to finish my tasks. Thanks again!
     
    tobiass likes this.