2.2.6 DPSP_MSG_HEADER
The DPSP_MSG_HEADER is prepended to all DirectPlay 4 Protocol messages and contains an identifier that describes each message structure.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
size (optional) |
token (optional) |
||||||||||||||||||||||||||||||
SockAddr (16 bytes, optional) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
Signature |
|||||||||||||||||||||||||||||||
Version |
Command Value |
size (20 bits): Indicates the size of the message (in octets). The value is obtained by performing a bitwise AND (&) operation with the token field and 0x000FFFFF. This field is optional and its existence depends on the message type and whether the DirectPlay 4 Reliable Protocol is used; it is present unless the containing message specifies otherwise.
token (12 bits): Describes high-level message characteristics. The value is obtained by performing a bitwise AND (&) operation with the size field and 0xFFF00000. This field is optional and its existence depends on the message type and whether the DirectPlay 4 Reliable Protocol is used; it is present unless the containing message specifies otherwise.
-
Value
Meaning
0xFAB
Indicates that the message was received from a remote DirectPlay machine.
0xCAB
Indicates that the message will be forwarded to all registered servers.
0xBAB
Indicates that the message was received from a DirectPlay server.
SockAddr (16 bytes): 16 bytes of data containing a sockets SOCKADDR_IN (section 2.2.1) structure. If the machine is on the same network as the receiving machine, the Address field of this structure is set to 0.0.0.0. This field is optional and its existence depends on the message type and whether the DirectPlay 4 Reliable Protocol is used; it is present unless the containing message specifies otherwise.
Signature (4 bytes): MUST be set to the value 0x79616c70 (ASCII 'play').
Version (2 bytes): MUST be set to the version number of the protocol. The DirectPlay 4 Core and Service Provider Protocol supports the protocol versions identified in the description of the VersionOrSystemPlayerID field in DPLAYI_SUPERPACKEDPLAYER (section 2.2.3).
Command Value (2 bytes): MUST contain one of the following values.
-
Name
Value
DPSP_MSG_ENUMSESSIONSREPLY
0x0001
DPSP_MSG_ENUMSESSIONS
0x0002
DPSP_MSG_ENUMPLAYERSREPLY
0x0003
DPSP_MSG_ENUMPLAYER
0x0004
DPSP_MSG_REQUESTPLAYERID
0x0005
DPSP_MSG_REQUESTGROUPID
0x0006
DPSP_MSG_REQUESTPLAYERREPLY
0x0007
DPSP_MSG_CREATEPLAYER
0x0008
DPSP_MSG_CREATEGROUP
0x0009
DPSP_MSG_PLAYERMESSAGE
0x000A
DPSP_MSG_DELETEPLAYER
0x000B
DPSP_MSG_DELETEGROUP
0x000C
DPSP_MSG_ADDPLAYERTOGROUP
0x000D
DPSP_MSG_DELETEPLAYERFROMGROUP
0x000E
DPSP_MSG_PLAYERDATACHANGED
0x000F
DPSP_MSG_PLAYERNAMECHANGED
0x0010
DPSP_MSG_GROUPDATACHANGED
0x0011
DPSP_MSG_GROUPNAMECHANGED
0x0012
DPSP_MSG_ADDFORWARDREQUEST
0x0013
DPSP_MSG_PACKET
0x0015
DPSP_MSG_PING
0x0016
DPSP_MSG_PINGREPLY
0x0017
DPSP_MSG_YOUAREDEAD
0x0018
DPSP_MSG_PLAYERWRAPPER
0x0019
DPSP_MSG_SESSIONDESCCHANGED
0x001A
DPSP_MSG_CHALLENGE
0x001C
DPSP_MSG_ACCESSGRANTED
0x001D
DPSP_MSG_LOGONDENIED
0x001E
DPSP_MSG_AUTHERROR
0x001F
DPSP_MSG_NEGOTIATE
0x0020
DPSP_MSG_CHALLENGERESPONSE
0x0021
DPSP_MSG_SIGNED
0x0022
DPSP_MSG_ADDFORWARDREPLY
0x0024
DPSP_MSG_ASK4MULTICAST
0x0025
DPSP_MSG_ASK4MULTICASTGUARANTEED
0x0026
DPSP_MSG_ADDSHORTCUTTOGROUP
0x0027
DPSP_MSG_DELETEGROUPFROMGROUP
0x0028
DPSP_MSG_SUPERENUMPLAYERSREPLY
0x0029
DPSP_MSG_KEYEXCHANGE
0x002B
DPSP_MSG_KEYEXCHANGEREPLY
0x002C
DPSP_MSG_CHAT
0x002D
DPSP_MSG_ADDFORWARD
0x002E
DPSP_MSG_ADDFORWARDACK
0x002F
DPSP_MSG_PACKET2_DATA
0x0030
DPSP_MSG_PACKET2_ACK
0x0031
DPSP_MSG_IAMNAMESERVER
0x0035
DPSP_MSG_VOICE
0x0036
DPSP_MSG_MULTICASTDELIVERY
0x0037
DPSP_MSG_CREATEPLAYERVERIFY
0x0038