Author Topic: Has the Gamespy protocol changed?  (Read 1139 times)

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Has the Gamespy protocol changed?
« on: August 14, 2014, 08:35:26 pm »


               
Does anyone know if the Server Status udp service has changed at all in Windows NWN?

"\xFE\xFD\x00\xE9\x49\x04\x05\x14\x01\x0B\x01\x05\x08\x0A\x33\x34\x35\x13\x04\x36\x37\x38\x39\x14\x3A\x3B\x3C\x3D\x00\x00"


This is the UDP datagram I am sending to my nwn server - but no matter what - over the last week or two - the udp connection just gets refused.

I've tried this on 3 different windows machines - and the refused connection is common to all.
Firewalls turned off etc

I see that peoples Server Status signature images are still working - which leads me to suspect maybe the protocol has changed or something?

Anyone able to offer any insight?
               
               

               
            

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #1 on: August 14, 2014, 11:53:41 pm »


               On further analysis - it looks like my nwserver process is not binding to a UDP socket- this is quite strange.

When I download TCPIP Builder - It is able to bind and receive the BNES udp datagrams in the sted of nwserver - since nwserver is running - it shouldnt be able to bind and listen to that port - since it would already be in use.

Anyone ever encounter issues with nwserver.exe not binding to a UDP port?
TCP and connections to the game server are fine.
               
               

               
            

Legacy_leo_x

  • Sr. Member
  • ****
  • Posts: 403
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #2 on: August 15, 2014, 01:14:04 pm »


               

Do you have GameSpy Enabled=0 in your nwnplayer.ini?  I noticed some servers stopped responding while working on neverrun.  I can fish out some C++ code and maybe some notes if you'd like when I get home for the Bioware messages that can replace the Gamespy one.  There might be code for this in C# in the Skywing's master server code.



               
               

               
            

Legacy_krackq

  • Newbie
  • *
  • Posts: 4
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #3 on: August 15, 2014, 07:02:49 pm »


               

I just sorted out this problem on our PW.  We have 9 servers.. some of them started recently showing down exactly how you describe it, though a few were up and everyone could log into all of them.  We have the Gamespy Enabled=1 option turned on in all of the startup scripts.  What I noticed however, was that when I would run a status command at the game server console, all of the servers that showed down had "Public Server 0" in their status while the ones that worked had "Public Server 1" in their status.  This is related to the Gamespy Enabled option.  My guess is that when starting nwnserver, it tries to reach out to gamespy in some way and fails and marks the public server as 0, regardless of the startup setting.  


 


I went into the host file on the server and added the dns entry from this page:


http://www.neverwint...lders_hosts.htm


 


The entry specifically is:


198.23.165.35 nwn.master.gamespy.com # Visavent's gamespy replacement


 


Afterwards I saved the hosts file and restarted the nwnserver.  The public server shows as 1 now on all 9 servers and they are all reporting as up with serverwatch and other various scripts.  More related information can be found here: http://www.neverwint...info/index.htm 


 


Hope that helps!



               
               

               
            

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #4 on: August 15, 2014, 07:23:06 pm »


               Thanks guys- I will investigate whether this fixes it for me tomorrow. (In a bar now)

I was also considering recreating the functionality via c# hooking.

I've managed to hook main loop in nwserver in c#.

I was considering opening my own UDP listener off the main loop thread, and have it respond accordingly to the status request.

If your suggested fixes don't work- I will deffo have a recourse to try.

Thanks again
               
               

               
            

Legacy_leo_x

  • Sr. Member
  • ****
  • Posts: 403
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #5 on: August 15, 2014, 07:47:25 pm »


               


I just sorted out this problem on our PW.  We have 9 servers.. some of them started recently showing down exactly how you describe it, though a few were up and everyone could log into all of them.  We have the Gamespy Enabled=1 option turned on in all of the startup scripts.  What I noticed however, was that when I would run a status command at the game server console, all of the servers that showed down had "Public Server 0" in their status while the ones that worked had "Public Server 1" in their status.  This is related to the Gamespy Enabled option.  My guess is that when starting nwnserver, it tries to reach out to gamespy in some way and fails and marks the public server as 0, regardless of the startup setting.  


 


I went into the host file on the server and added the dns entry from this page:


http://www.neverwint...lders_hosts.htm


 


The entry specifically is:


198.23.165.35 nwn.master.gamespy.com # Visavent's gamespy replacement


 


Afterwards I saved the hosts file and restarted the nwnserver.  The public server shows as 1 now on all 9 servers and they are all reporting as up with serverwatch and other various scripts.  More related information can be found here: http://www.neverwint...info/index.htm 


 


Hope that helps!




 


Thanks for sharing that krackq.  I think there are a lot of people scratching their heads over this.  I'm curious why some of your servers showed and others didn't tho.  The Visavent thing was dead a long time ago, so I wonder if an ip address for google wouldn't work just as well (and be reliable).



               
               

               
            

Legacy_krackq

  • Newbie
  • *
  • Posts: 4
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #6 on: August 15, 2014, 08:20:53 pm »


               

If there's an ip that is definitely more reliable I'd be keen on using that.  I don't know all of the inner workings when the server starts up.



               
               

               
            

Legacy_Empyre65

  • Hero Member
  • *****
  • Posts: 662
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #7 on: August 16, 2014, 01:19:52 am »


               

I may be displaying my ignorance on this issue, but would the loopback IP (127.0.0.1) work?



               
               

               
            

Legacy_leo_x

  • Sr. Member
  • ****
  • Posts: 403
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #8 on: August 16, 2014, 12:10:55 pm »


               


I may be displaying my ignorance on this issue, but would the loopback IP (127.0.0.1) work?




 


I think it probably would.  My guess is that it's just failing to translate the gamespy hostname then giving up.


               
               

               
            

Baaleos

  • Administrator
  • Hero Member
  • *****
  • Posts: 1916
  • Karma: +0/-0
Has the Gamespy protocol changed?
« Reply #9 on: August 16, 2014, 03:43:44 pm »


               Hi guys.
It worked - I set it to 8.8.8.8 which is the google dns ip address.