Unity-Technologies/com.unity.multiplayer.samples.bitesize

2DSpaceShooter: Setting Server Port Does Not Set Listen Port Used for Connecting

misterperson opened this issue · 2 comments

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Open two instances of 2DSpaceShooter on one machine
  2. Start a server on port 8000
  3. The host displays that it's on port 8000
  4. Attempt to join as a client on the other instance with port also 8000
  5. This fails after 10 retries.
  6. Attempt to join on the other instance with port 7777
  7. This... works?

Expected behavior
Hosting a game on a different port should use that port for the listen socket.

Environment (please complete the following information):

  • OS: Windows 10 Build 19042
  • Unity Version: 2021.1.10f1
  • MLAPI Version: 0.1.0
  • Bitesize Samples Repository Version/Commit: 3dc3c39

Additional context
For a university project, we need to use a specific port range (which does not include 7777) to be able to open a server to LAN on campus servers. We were attempting to use the bitesize projects to troubleshoot problems, to no avail.

I just checked whether this is still present with our latest changes in #32 and seems it's not the case as I can host and join with the 8000 port fine. So this will be fixed with the next version.

fixed by #32