Search Unity

Third Party Photon Public IP not connected

Discussion in 'Multiplayer' started by Handsome-Wisely, May 26, 2015.

  1. Handsome-Wisely

    Handsome-Wisely

    Joined:
    Mar 20, 2013
    Posts:
    102
    i make a game use photon and write my own server (not use photon cloud) and it run ok in local net(like server ip : 192.168.1.2:5055). but when i use public ip, client can not connect to server. i already use 花生壳 to make port map and i can access my web server use public ip, but photon still can not connected.
    my game is interesting, who can tell me how to configure my photon.
    thanks!
     
  2. Handsome-Wisely

    Handsome-Wisely

    Joined:
    Mar 20, 2013
    Posts:
    102
    port map i meaning Port forwarding
     
  3. tobiass

    tobiass

    Joined:
    Apr 7, 2009
    Posts:
    3,066
    While you can setup Photon to listen just to one port/network, it's usually accepting incoming messages from either net. So there is no setup needed for that.
    You need to setup port forwarding for several ports though. Check the list of the requirements:
    http://doc.exitgames.com/en/onpremise/current/getting-started/requirements

    If you use the LoadBalancing API, you will need to setup the "Game Server Address" to the public ip/port.
    If this doesn't help, please post in our forum in the server section:
    http://forum.exitgames.com/viewforum.php?f=5
     
  4. Handsome-Wisely

    Handsome-Wisely

    Joined:
    Mar 20, 2013
    Posts:
    102
    i read the requirements and make all the ports(list in article) forwa
    i read the requirements and make all the ports(list in article) forwarding. i can even ping my public ip 219.143.151.197 connected but photon still can not connected!
    can you help me more
    thank you
     
  5. Handsome-Wisely

    Handsome-Wisely

    Joined:
    Mar 20, 2013
    Posts:
    102
    i connected successfully!
    haha! thank you!
    use public IP you client must not in the same net.
    i setup photon server in company and visit in my home use public id, connected ok
    visit it in company use local ip, connected ok.
     
  6. tobiass

    tobiass

    Joined:
    Apr 7, 2009
    Posts:
    3,066
    :)
    That's a new one for me. I would have said that even the public IP should be within reach for a client of the same net.
    Glad you found it! Thanks for the update.
     
  7. EricYen

    EricYen

    Joined:
    Jun 6, 2014
    Posts:
    7
    The same problem
    But I do not know how to do it ....
    You can help me?
    I can connect in the same net
     
  8. Handsome-Wisely

    Handsome-Wisely

    Joined:
    Mar 20, 2013
    Posts:
    102
    i think key is
    all these ports

    UDP: 5055, 5056, 5057
    TCP: 4530, 4531, 4532 (TCP based clients)
    TCP: 9090, 9091, 9092 (websocket clients e.g. JS)
    TCP: 4520 for LoadBalancing GameServer to Master
    TCP: 843 for crossdomain requests (Unity3D webplayers and Flash)
    TCP: 943 for crossdomain requests (Silverlight)
    TCP: 8088 for Webpage
    UDP: 40001 listener for counters

    Port forwarding

    PPOE net if server is in you home

    and same net use public ip will failed