Master Server Query Protocol: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
No edit summary
Line 1: Line 1:
Send the following UDP query to a master server to get a list of Source host servers.
I have a problem. I searched all over the net without result:(
 
When u open hammer u got 4 screens. 1 in 3D and 3 in 2D. First it was normal but now it looks like this.[[http://users.telenet.be/downloadarea/hammer.jpg]] plz help
==Format==
send reply here or to vancaeneghempieter@hotmail.com
{|
thx
! Type || Field || Value
|-
| [[Byte]] || Message Type || 0x31 - the character "1"
|-
| [[Byte]] || Region Code || See below
|-
| [[String Zero]] || IP:Port || 0.0.0.0:0
|-
| [[String Zero]] || Filter || See below
|}
 
===Region Codes===
The region of the world that you wish to find servers in.
{|
! Byte || Description
|-
| 0x00 || US East coast
|-
| 0x01 || US West coast
|-
| 0x02 || South America
|-
| 0x03 || Europe
|-
| 0x04 || Asia
|-
| 0x05 || Australia
|-
| 0x06 || Middle East
|-
| 0x07 || Africa
|-
| 0xFF || Rest of the world
|}
<!--What's for none? = world-->
 
===IP:Port===
Steam sends "0.0.0.0:0".
 
Does anyone know what this is supposed to be the address of?
 
Changing it doesn't appear to affect the results in anyway.
 
(Should be the first IP address we are interested in.)
 
===Filter===
Allows you to restrict the results to servers running a certain game, map, etc.
 
Send an empty string (0x00) to recieve a list of all types of servers.
 
Insert <code>\</code> in between filter parameters
*<code>\type\d</code>
::Servers running dedicated
*<code>\secure\1</code>
::Servers using anti-cheat technology (VAC)
*<code>\gamedir\[mod]</code>
::Servers running the specified modification (ex. cstrike)
*<code>\map\[map]</code>
::Servers running the specified map (ex. cs_italy)
*<code>\linux\1</code>
::Servers running on a Linux platform
*<code>\empty\1</code>
::Servers that are not empty
*<code>\full\1</code>
::Servers that are not full
*<code>\proxy\1</code>
::Servers that are spectator proxies
 
==Master Servers==
Current master servers are
 
'''Half-Life 1 engine:'''
 
<code>207.173.177.11:27010</code>, <code>69.28.151.162:27010</code> and <code>68.142.72.250:27010</code>.
 
'''Half-Life 2 (Source) engine:'''
 
<code>68.142.72.250:27011</code>, <code>69.28.151.162:27011</code> and <code>207.173.177.11:27011</code>.
 
'''Rag Doll Kung Fu:'''
 
<code>207.173.177.12:27012</code>.
 
If you can, get your application to check the file <code>Steam\config\masterservers.vdf</code> to get the latest list of master servers.
 
==Reply Format==
The reply always starts with <code>FF FF FF FF 66 0A</code>.
 
The format is then a series of these server address blocks:
{|
! Type || Data
|-
| [[Byte]] || First octet of IP address
|-
| [[Byte]] || Second octet of IP address
|-
| [[Byte]] || Third octect of IP address
|-
| [[Byte]] || Fourth octet of IP address
|-
| [[Short]] || Port number - usually 27015 (0x69 0x67)
|}
 
Some of the servers may be unreachable, so query each server directly to find out. Note also that this list is not exhaustive, so if you're looking for a particular type of server make sure that you specify a filter with the query, rather than filtering client side.
 
==See Also==
* [[Source Server Queries]]
[[Category:Programming]][[Category:Technical]]

Revision as of 10:42, 8 February 2006

I have a problem. I searched all over the net without result:( When u open hammer u got 4 screens. 1 in 3D and 3 in 2D. First it was normal but now it looks like this.[[1]] plz help send reply here or to vancaeneghempieter@hotmail.com thx