Online GG Master Server Monitor
by David Wyand · in Torque Game Engine · 07/07/2002 (9:14 pm) · 7 replies
Greetings!
This weekend, I've been poking around in the Torque network code, specifically that related to the GarageGames' Master Server. After spending a few hours tracing through the code and determining the protocol, I decided to write a little Master Server monitor.
I wrote it as a Perl CGI script, and you may use it from the home page at:
www.gnometech.com
I've also included access to a monitor window that displays the number of currently active SDK Test App and Realm Wars servers.
In general, this monitor could be used when you cannot access the Master Server yourself and would like a second opinion. While I have managed to test the monitor in a mock situation, I won't know for sure that it is working until the Master Server actually goes down, but I do feel quite confident. Anyone care to power it off for a test? :o)
If you'd like to discuss the technical details further, we can move this to the private SDK forums. However, I thought I'd post this here so everyone, including those that downloaded Realm Wars, could give it a try.
- LightWave Dave
This weekend, I've been poking around in the Torque network code, specifically that related to the GarageGames' Master Server. After spending a few hours tracing through the code and determining the protocol, I decided to write a little Master Server monitor.
I wrote it as a Perl CGI script, and you may use it from the home page at:
www.gnometech.com
I've also included access to a monitor window that displays the number of currently active SDK Test App and Realm Wars servers.
In general, this monitor could be used when you cannot access the Master Server yourself and would like a second opinion. While I have managed to test the monitor in a mock situation, I won't know for sure that it is working until the Master Server actually goes down, but I do feel quite confident. Anyone care to power it off for a test? :o)
If you'd like to discuss the technical details further, we can move this to the private SDK forums. However, I thought I'd post this here so everyone, including those that downloaded Realm Wars, could give it a try.
- LightWave Dave
About the author
A long time Associate of the GarageGames' community and author of the Torque 3D Game Development Cookbook. Buy it today from Packt Publishing!
#2
An hour later, it began to report the correct number.
07/08/2002 (3:35 am)
Cool stuff, although at one time it reported 3 servers were running Realm Wars but when I logged in it only had one.An hour later, it began to report the correct number.
#3
Tim:
Well, so far I've only gone through half of what needs to occur to communicate with the Master Server (which, in theory would allow one to start to write their own server). Right now, I am able to find out what game servers are attached to the Master Server, but don't take it any further (ie: what are the names of the games, how many players, etc).
I certainly could write up what I know so far, and perhaps that would help you and others out. At least get people started in the right direction. I'll see what I can put together this week...
Matt:
I'm glad you like it. Now, it certainly is possible that there is a problem with my server monitor. But, I believe I have another reason why you were seeing a larger number of servers being reported by my monitor than were displayed in Realm Wars itself:
When I ask for a list of available game servers from the Master Server, I don't filter them for version, etc. I just count every one of them. In the Realm Wars game itself, there is filtering being done by the Torque Engine to display only those games that are valid to you.
For example, each game server can have a version associated with it. The Realm Wars demo binaries appear to have use a version of 100. Now, if you were run Realm Wars from the Head version, it is set to a version of 1100. Therefore, a player using the RW demo would not be able to see the RW Head server, and vice-versa.
There's also a parameter called minCPU, that in the Head version is set to 100, and seems to cause the filtering out of servers (at least when I run a dedicated server using the Head, I cannot see it when running a Head client). To fix this, I change the minCPU parameter in the Head client to be 0, which will then show all Head servers once again.
Whew. Well, there ya go. So, to sum it up: assuming that my monitor is indeed working as intended, there are times when the number of servers displayed by the monitor will not match the number of servers displayed in a particular version of the RW client.
- LightWave Dave
07/08/2002 (7:58 am)
Greetings!Tim:
Well, so far I've only gone through half of what needs to occur to communicate with the Master Server (which, in theory would allow one to start to write their own server). Right now, I am able to find out what game servers are attached to the Master Server, but don't take it any further (ie: what are the names of the games, how many players, etc).
I certainly could write up what I know so far, and perhaps that would help you and others out. At least get people started in the right direction. I'll see what I can put together this week...
Matt:
I'm glad you like it. Now, it certainly is possible that there is a problem with my server monitor. But, I believe I have another reason why you were seeing a larger number of servers being reported by my monitor than were displayed in Realm Wars itself:
When I ask for a list of available game servers from the Master Server, I don't filter them for version, etc. I just count every one of them. In the Realm Wars game itself, there is filtering being done by the Torque Engine to display only those games that are valid to you.
For example, each game server can have a version associated with it. The Realm Wars demo binaries appear to have use a version of 100. Now, if you were run Realm Wars from the Head version, it is set to a version of 1100. Therefore, a player using the RW demo would not be able to see the RW Head server, and vice-versa.
There's also a parameter called minCPU, that in the Head version is set to 100, and seems to cause the filtering out of servers (at least when I run a dedicated server using the Head, I cannot see it when running a Head client). To fix this, I change the minCPU parameter in the Head client to be 0, which will then show all Head servers once again.
Whew. Well, there ya go. So, to sum it up: assuming that my monitor is indeed working as intended, there are times when the number of servers displayed by the monitor will not match the number of servers displayed in a particular version of the RW client.
- LightWave Dave
#4
There's now an improved version of my GarageGames' Master Server Monitor at www.gnometech.com. If a particular game type has at least one server defined, then you can link to another screen that shows the names of the game servers, and how many players are on each.
I've also included the version number of the server, which will give you an idea of games that are out there that you may not be able to connect to.
- LightWave Dave
07/09/2002 (6:32 pm)
Greetings!There's now an improved version of my GarageGames' Master Server Monitor at www.gnometech.com. If a particular game type has at least one server defined, then you can link to another screen that shows the names of the game servers, and how many players are on each.
I've also included the version number of the server, which will give you an idea of games that are out there that you may not be able to connect to.
- LightWave Dave
#5
I've made yet another change to the GarageGames' Master Server Monitor over at www.gnometech.com. This one based on a couple of requests I've had...
A couple of people have asked that I add their server to the Game Server Type list so that they will be certain that the Master Server is seeing them. These people often have only a single PC, and therefore cannot test this out themselves. While in theory this sounds great, the reality is that if I add their servers to the list, every time anyone uses the monitor the Master Server will be asked for information on their servers. While it's not a lot of traffic, there's no need to add any more than necessary.
So, the solution I've come up with is to add a text input to the server monitor. You enter in your own game type (usually defined in $Server::GameType) and click on the Search button. The Master Server will then be queried for your game type and display all of the game servers that are available (in the same manner as the SDK Test App and Realm Wars).
Probably the biggest advantage is that now anyone can check for their game servers without requiring them to ask me to add them. For example, if you're doing an in-house alpha test, and someone cannot connect to the game server, they can now use the monitor to get a 3rd party point-of-view.
The other side to all this is that if you have a Torque game that is released, or on its final public beta, then I certainly would be willing to add it to the server monitor. Just send in a request. I'm looking forward to doing this for the much-anticipated DoP.
- LightWave Dave
07/11/2002 (3:02 pm)
Greetings!I've made yet another change to the GarageGames' Master Server Monitor over at www.gnometech.com. This one based on a couple of requests I've had...
A couple of people have asked that I add their server to the Game Server Type list so that they will be certain that the Master Server is seeing them. These people often have only a single PC, and therefore cannot test this out themselves. While in theory this sounds great, the reality is that if I add their servers to the list, every time anyone uses the monitor the Master Server will be asked for information on their servers. While it's not a lot of traffic, there's no need to add any more than necessary.
So, the solution I've come up with is to add a text input to the server monitor. You enter in your own game type (usually defined in $Server::GameType) and click on the Search button. The Master Server will then be queried for your game type and display all of the game servers that are available (in the same manner as the SDK Test App and Realm Wars).
Probably the biggest advantage is that now anyone can check for their game servers without requiring them to ask me to add them. For example, if you're doing an in-house alpha test, and someone cannot connect to the game server, they can now use the monitor to get a 3rd party point-of-view.
The other side to all this is that if you have a Torque game that is released, or on its final public beta, then I certainly would be willing to add it to the server monitor. Just send in a request. I'm looking forward to doing this for the much-anticipated DoP.
- LightWave Dave
#6
07/17/2002 (8:50 am)
Thank you for this.
#7
--KallDrexx
07/17/2002 (3:41 pm)
Hey. If you release documentation or at least (in private forums) show where the code is that communicates to the master server, I would love to make a Torque master server.--KallDrexx
Associate Tim Newell
Max Gaming Technologies
-Tim aka Spock