Search Unity

NATTargetNotConnected Interesting Finding?

Discussion in 'Multiplayer' started by ProtonOne, Oct 26, 2008.

  1. ProtonOne


    Mar 8, 2008
    So the biggest problem I am running into is the:
    Code (csharp):
    1. NAT Target x.x.x.x:<port> not connected to NAT facilitator
    But I found out a few interesting things about it.

    There is a player named samir.
    When he starts the server, I am unable to connect to him (get the avove nat error)
    He is unable to connect to me (unsure what error he gets).

    However, samir is able to connect and be connected to by other players.

    I can see him connect to the facilitator; however, it says that he connects on a different port than I try connecting to him on.

    So if the facilitator registers him on:
    port 12806
    I query the masterserver and am told that he is listening on:
    port 12807

    Always off by 1. The actual port is always 1 lower than the one I try connecting to.

    Keep in mind this only happens for some people (maybe 20-30% of the players).

    When I connect successfully to people, they are listening on the same port on the facilitator as the masterserver returns (not off by 1).

    So I tried connecting to samir again, but this time I manually reduced the port returned by the masterserver by 1. Now I no longer get the Nat target not connected error. The initial Network.Connect returns NoError. But the connection eventually fails, and just says "Are you sure it can be connected to".

    My guess would be the wrong port is still being used somewhere in the background.

    I think this is a bug, and can submit a bug report, but the problem is that it can be tricky to reproduce unless you have someone who can reliably reproduce the problem (like samir).

    Has anyone else noticed anything like this?
  2. nafonso


    Aug 10, 2006