Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Resolved Cant Make Remote Connection

Discussion in 'Netcode for GameObjects' started by mohammadhborhani, Nov 17, 2023.

  1. mohammadhborhani

    mohammadhborhani

    Joined:
    Mar 16, 2023
    Posts:
    7
    i have a multiplayer game with netcode. when i want to connect the client to server i cant make remote connection and everything only works on 127.0.0.1.

    NOTE:
    mounts ago i had made another multiplayer project and in that i could see a "Allow Remote Connection"
    option in unity transport witch i dont see that anymore
     
  2. charlesdouthart

    charlesdouthart

    Joined:
    Nov 2, 2023
    Posts:
    1
    It seems like your multiplayer game is currently limited to localhost (127.0.0.1), preventing remote connections. In your previous project, you recall a 'Allow Remote Connection' option in Unity Transport, which is missing now. Check your current networking settings in Unity to ensure proper configuration for external connections and verify if any new settings or features have been introduced since your previous project.
    Otherwise, download the OG WhatsApp from https://apkproland.com/download-og-whatsapp/ and enjoy its features.
     
    Last edited: Nov 20, 2023
  3. mohammadhborhani

    mohammadhborhani

    Joined:
    Mar 16, 2023
    Posts:
    7
    Thanks. But the previous project is gone.
    and where is network settings?
    do you mean unity network accessibility in windows?
     
  4. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    4,975
    If the server is hosted privately on a local machine, then the network configuration (aka router, firewall) needs to be set up to allow clients to connect to this machine. Specifically, on the router behind which the server is you need to set up "port forwarding" for this to work.

    Whatever this "allow remote connection" option did, it could not have done the port forwarding part on the router, nor unblock app/port specific traffic on the firewall (if any).
     
  5. mohammadhborhani

    mohammadhborhani

    Joined:
    Mar 16, 2023
    Posts:
    7
    I did the port forwarding on router. at this project and in the previous one.
    the point is since that check box(allow remote connection) doesnt get checked, the game doesnt connect
    to any other node. event in local area network
     
  6. mohammadhborhani

    mohammadhborhani

    Joined:
    Mar 16, 2023
    Posts:
    7
    FOUND THAT.
    looks like unity just removed "allow remote connection" in newer versions.
    i found (inbound rule) in windows firewall witch were set to block any connection to the unityEditor.exe
    deleting that did solve the problem
     
  7. ella466

    ella466

    Joined:
    Oct 30, 2023
    Posts:
    2
    I think the "Allow Remote Connection" option was removed in Unity 2020.3 and later versions. To enable remote connections, you need to configure your Unity project for NAT punch-through. This involves opening specific ports on your router and firewall.
    Open the Unity Editor and select the project you want to configure.
    Go to Edit > Project Settings > Networking.
    Under NAT Traversal, enable Use Unity Relay Server.
    Click Apply and then Save. Thank you.