Author Topic: TNServerInstance.Start creates multiple servers?  (Read 2528 times)

Dennis59

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 18
    • View Profile
TNServerInstance.Start creates multiple servers?
« on: April 02, 2013, 07:24:55 PM »
I created a lobby server on port 5129 using TNServer.exe running on the same computer that the game will run on.  After creating a new server using
  1. TNServerInstance.Start (5127, 5128, "myServer",
  2.                         TNServerInstance.Type.Udp, Tools.ResolveEndPoint("127.0.0.1", 5129));
  3.  
the new server shows up as being added.  A few seconds later another one shows up, then another, and so on.  When exiting the game one server is removed.  TNServerInstance.Start is only running once and nothing was evident in the code for TNServer.exe to explain this.

Anyone have any ideas what is going on here?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: TNServerInstance.Start creates multiple servers?
« Reply #1 on: April 02, 2013, 10:26:20 PM »
UDP lobby receives server updates every few seconds. It's not a new server, it's an update on the status of an existing server. Are you saying your server list keeps growing? Any steps to reproduce that, because that's not how it works with the built-in examples.

Dennis59

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 18
    • View Profile
Re: TNServerInstance.Start creates multiple servers?
« Reply #2 on: April 03, 2013, 07:31:30 PM »
ArenMook, in the debugger I looked at how the list of servers was changing and found that after adding one server it remains at one server even though the console suggested additional servers were being added.  As you suggest these must be updates and the number of servers is not actually increasing.  It isn't entirely clear how the code is working yet but I am judging this based on the size of list in TNServerList.cs and mList in TNUdpLobbyServer.cs.  Both stay at 1. 

Thanks for your guidance here.