Created
May 16, 2021 09:06
-
-
Save mataha/5b16b4dc9cff9744eb27a7ae6286b70a to your computer and use it in GitHub Desktop.
GunZ locator protocol example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Example locator request and response (International GunZ). | |
Note that some servers would send slightly different responses, e.g. Freestyle | |
GunZ (response from FGunZ would include some additional fields, e.g. server | |
description - I don't know if it's 1.5 source specific). | |
Everything is in little-endian order unless specified. | |
REQUEST | |
0000 64 00 0b 00 73 00 05 00 41 9c 00 d...s...A.. | |
64 00 | |
message ID | |
0064 => 100 (MSGID_RAWCOMMAND in MPacket.h) | |
0b 00 | |
size | |
000b => 11 (11 bytes - correct) | |
73 00 | |
checksum | |
(calculated in MPacket.h: MBuildCheckSum(MPacketHeader*, int)) | |
05 00 | |
payload size | |
0005 => 5 (5 bytes - correct [05 00 41 9c 00]) | |
41 9c | |
command | |
9c41 => 40001 (MC_REQUEST_SERVER_LIST_INFO in MSharedCommandTable.h) | |
00 | |
MUID | |
(basically 0) | |
RESPONSE | |
0000 64 00 26 00 1d 02 20 00 42 9c 00 17 00 00 00 0f d.&... .B....... | |
0010 00 00 00 01 00 00 00 00 00 00 00 70 17 00 00 01 ...........p.... | |
0020 f4 01 02 00 04 01 ...... | |
64 00 | |
message ID | |
0064 => 100 (MSGID_RAWCOMMAND in MPacket.h) | |
26 00 | |
size | |
0026 => 38 (38 bytes - correct) | |
1d 02 | |
checksum | |
(calculated in MPacket.h: MBuildCheckSum(MPacketHeader*, int)) | |
20 00 | |
payload size | |
0020 => 32 (32 bytes - correct [20 00 ... 04 01]) | |
42 9c | |
command | |
9c42 => 40002 (MC_RESPONSE_SERVER_LIST_INFO in MSharedCommandTable.h) | |
00 | |
MUID | |
(basically 0) | |
Blob structure: | |
17 00 00 00 | |
blob structure size | |
00000017 => 23 (23 bytes - correct) | |
Blob data: | |
0f 00 00 00 | |
size of a single blob (OneBlobSize) | |
0000000f => 15 (15 bytes) | |
01 00 00 00 | |
number of blobs (BlobCount) | |
00000001 => 1 (one blob) | |
Blobs (1): | |
00 00 00 00 | |
server IP | |
00000000 => 0.0.0.0 | |
70 17 00 00 | |
server port | |
00001770 => 6000 | |
01 | |
server ID | |
1 - should be self-explanatory | |
f4 01 | |
maximum amount of players | |
01f4 => 500 | |
02 00 | |
current amount of players | |
0002 => 2 | |
04 | |
server type | |
1: debug, 2: match, 3: clan, 4: quest, 5: event, 6: test | |
01 | |
server status | |
0: offline, 1: online |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment