GetPlayerIndex
Gets the gstats reference number for a player.
- int GetPlayerIndex(
- statsgame_t game,
- int pnum );
Routine | Required Header | Distribution |
---|---|---|
GetPlayerIndex | <gstats.h> | SDKZIP |
Return Value
Returns the requested index.
Parameters
- game
- [in] The game for which to retrieve the translated value. If NULL, uses most recently created game.
- pnum
- [in] Your internal player number, as sent to NewPlayer.
Remarks
As players join and leave, their assigned indexes change. Normally this doesn't matter to you, but if you want to do a key name or key value that references a player or team number, such as setting a player's team number, you need to use the translated values.
Section Reference: Gamespy Stats and Tracking SDK