Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice
  2. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  3. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Networking NAT punch through uNet?

Discussion in '5.1 Beta' started by TheOtherMonarch, Apr 27, 2015.

  1. TheOtherMonarch

    TheOtherMonarch

    Joined:
    Jul 28, 2012
    Posts:
    862
    I am assuming that NetworkTransport.Connect does not do NAT punch through and that you need to use relay servers rather than NAT punch through?
     
    LovesSolvingProblems likes this.
  2. Erik-Juhl

    Erik-Juhl

    Unity Technologies

    Joined:
    Jul 11, 2012
    Posts:
    59
    Correct. There are no software solutions that are 100% so for Phase 1 we went with the relay server approach. We are looking into adding a software based solution as a first attempt and then using relay if that fails to connect. But that would not be until a future release. How interesting and important is that to you?
     
  3. TheOtherMonarch

    TheOtherMonarch

    Joined:
    Jul 28, 2012
    Posts:
    862
    I feel that NAT punch through is very important at least on the PC platform. It’s also kind of what PC gamers expect.
     
  4. awrightmgt

    awrightmgt

    Joined:
    Oct 13, 2014
    Posts:
    3
    I agree, this is extremely important as we look at Unity as a possible dev platform for our MP desktop game.
     
    LovesSolvingProblems likes this.
  5. Erik-Juhl

    Erik-Juhl

    Unity Technologies

    Joined:
    Jul 11, 2012
    Posts:
    59
    Are you saying the relay server does not solve the problem of NAT? Or that you prefer a software solution to a hardware solution? If that is true, can you explain why the software solution is more important for you?
     
  6. TheOtherMonarch

    TheOtherMonarch

    Joined:
    Jul 28, 2012
    Posts:
    862
    1: Latency is a worry for me. Not knowing where the relay servers will be located.
    2: Having to rely on unity running relay servers in the future.
    3: Scalability potentially (cost)(punch through would also reduce relay server load)

    Mostly worried about Latency. Unless the servers are spread out well and don’t get overloaded.
     
  7. aabramychev

    aabramychev

    Unity Technologies

    Joined:
    Jul 17, 2012
    Posts:
    574
    We are worrying about this feature. The problem here is mostly internal resources management. Nat punch realization will require additional server - facilitator, and additional dev.ops. management. Smooth connection will require changing connection algorithm (as Nat Punch port finding can require time connection should be establish via relay first and then will switch to direct after ports will be found). So we choose to start with relay as it is absolutely necessary feature + we can reduce potential problems with server farm. After that we will think about nat punch proper implementation

    Make sense?