Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
This question was closed Aug 16, 2014 at 06:28 PM by meat5000 for the following reason:

The question is answered, right answer was accepted

avatar image
0
Question by brandonhotdo · Aug 16, 2014 at 02:19 PM · c#networkingmasterserverip

Port forwarding

So I have been looking around the internet on multiplayer for unity but every thing I watch/read makes me even more confused on how it works! Most games you just port forward a port (usually the game has a default port) and then a player would connect with the host's ip address and port! but how could I get something like that in unity? I have tried setting masterserver.ipaddress to a text field so that the player could assign his ip address to it and a port that he has port forwarded but I get errors! So I was wondering what does the player assign Masterserver.ipaddress to? Does he go to http://www.ipchicken.com/ and use that as his ip and players use that to join his game or does he go into the cmd then type ipconfig and use his ipv4? If this still makes no sense to you, I just want to know how a player could run a server of his ip and people join the server with his ip and port! Most tutorials use the 127.0.0.1 but that means that all servers will have that ip then! So once again summed up, What does the host assign the masterserver.ipaddress to (also where would he find the ip to assign it to) and what ip would people need to join it? So yeah its sort of a lot but thanks for the help! XD

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

  • Sort: 
avatar image
1
Best Answer

Answer by Chris_Dlala · Aug 16, 2014 at 04:49 PM

Hi, I'm not sure if I'm understanding exactly what you are trying to do. The master server is only used to broadcast servers and aid connection between machines (like a matchmaking service). The master server will also need to be run on a server with a public IP so that you can set that IP in your client. You can directly connect to a computer using a public IP on a certain port using Network.Connect (see here) - that is the IP shown on your linked website ipchicken. Warning, the IP shown on these websites will change every time your router/modem connects to your ISP unless you have a static public IP. I hope that helps =D

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image brandonhotdo · Aug 16, 2014 at 05:24 PM 0
Share

cool it works thanks!

avatar image MFKJ · Jan 24, 2017 at 09:21 AM 1
Share

This is not the technological solution for unity. how can i do port forwarding through code. i want to connect different user to my multiplayer

Follow this Question

Answers Answers and Comments

4 People are following this question.

avatar image avatar image avatar image avatar image

Related Questions

Creating servers properly? 0 Answers

Multiple Cars not working 1 Answer

Unity 3d master server not localy. 0 Answers

Distribute terrain in zones 3 Answers

Port not opening? 3 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges