Author Topic: Master server for player listing?  (Read 3478 times)

kebrus

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
Master server for player listing?
« on: March 27, 2014, 06:52:30 AM »
Hi there, i got tasharen networking a few weeks ago when it was on sale. I'm telling this because i actually haven't used it yet and i'm now considering it for the current project. I'm also not very experienced in networking, i know my way around it but i'm struggling in some basic problems

For anyone reading this to understand our current problem i'm working on a very small game where players create their own server and fight in small teams (1vs1, 2vs2 or 3vs3). We got the game running and players are able to join and play. But now we want it to release the game and we kinda stumbled on the server listing problem.

From my understanding there needs to be a master server waiting for new players to create a server so when a player creates one it communicates with the server to get listed on a lobby the game has. The problem is, is it possible to create this with a simple computer on a common internet connection with a router? we are trying to this and failing miserably and we are now considering moving out of unity networking to tasharen. We get weird connection problems using Unity's built in and after trying to create our own we get Nat punch through errors.

To put broadly, what's the simplest way to list games to users so they connect to each other?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Master server for player listing?
« Reply #1 on: March 28, 2014, 01:15:46 AM »
Lobby server needs to be somewhere everyone can access it -- and somewhere persistent. You need to do this in order to have a specific "meeting place" for players.

For Starlink I placed my lobby server on an Amazon EC2 instance. It's free for a year, and since the lobby server uses near no bandwidth it's perfectly suitable for the task at hand.

Players connect to the lobby server, get a list of servers, and whenever they create their own server it automatically registers with the lobby server so that other players can find it later.

rickburgen

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 5
    • View Profile
Re: Master server for player listing?
« Reply #2 on: January 24, 2015, 08:36:48 AM »
I am in a similar situation.

Player one becomes available for battle then searches for an available server meeting the matching making requirements. If none are available, I want to create a new server and register it in the database. When player two becomes available, and gets matched up with player one, I want to to use the registered server that was create when player one became available. How can I do this? Im trying to understand the flow and jargon of TNet.

Thanks!

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Master server for player listing?
« Reply #3 on: January 25, 2015, 01:37:57 AM »
When you are connected to the lobby server you have access to TNLobbyClient.knownServers -- a list of all known servers. Pick one, join it. If no suitable server can be chosen, make a new one.