How to create an application using the hosted photon server?

Options

Hi!

I am new on the Photon Server Hosting. I was able to follow the steps here https://doc.photonengine.com/en-us/server/current/getting-started/photon-server-in-5min#ip_address_config. Now I want to connect a client on the server that I am hosting on other computer, but on the same network. What should I do?


Tks

Answers

  • chvetsov
    Options

    Hi, @PedroLazari

    Client related questions please ask in corresponding section.

    what server sdk are you using?

    best,

    ilya

  • Hi, @chvetsov

    Sorry, I am trying to set up the self-hosted server of photon on my pc (PC 1) and run a game on another pc (PC 2) communicating with PC 1. I didn't know in what thread post my question.

    So, I am using the server SDK version v5.0.12.24499.

    I saw a lot of people using the "PhotonNetwork.ConnectToMaster(masterServerAddress, port, appID)" function. However, how do I know what is my masterServerAddress? Is it the one that comes on the Nameserver.json file as "IpAddress"?

    Also, the AppID is the one that we use for REALTIME? And the port is any port on my PC that has to be open for UDP?

    Again, sorry for the number of questions... I am really lost here

    Thanks for the support!

  • chvetsov
    Options

    hi, @PedroLazari

    If you are using self hosted version that you need different setup for PUN to connect. you do not have to provide appId. You have to use name server address to connect, not master server address. As pointed in another thread you have to set correct IP of your master in Nameserver.json

    also you have to open deploy/LoadBalancing/GameServer/bin/GameServer.xml.config and fix PublicIPAddress to IP of machine that you are using to host/run your GameServer

    take a look here to understand better how to setup our client for self hosted: Setup And Connect | Photon Engine

    best,

    ilya