2.2.7 DN_DPNID

The DPNID is a unique identifier created by a DirectPlay host and server for each player and group included in a game session. A DPNID value is created for a player or group at the time when that player or group is added to the game session. The DPNID for each player and group in the game session MUST be unique. The value 0x0 is an invalid value for a DPNID.

The DPNID for a player or group is generated in several steps, at the time when the player or group is added to the game session.

  1. The index of the entry in the name table that was used to create the player or group is stored in the lowest 20 bits of the DPNID. For example, when the index of the entry within the name table is 5, the index is stored as follows:

    0xNNN00005

  2. Along with the index, the version of the name table that existed when the entry was created is also stored. For example, when the name table version is 10 (0x0A), the index is stored as follows:

    0x00A00005

  3. This value is then XOR'd with the first 32 bits of the game session instance GUID to obfuscate. For example, if the instance GUID begins with 0xA1B2C3D4, the DPNID 0x00A00005 value would be XOR'd with 0xA1B2C3D4 to obfuscate as follows:

    0xA112C3D1

It is important to point out that the DirectPlay host will use the DPNID of a player or group to determine the location for this entry in the name table.