peerPingCallback

GameSpy SDK

peerPingCallback

Callback when an updated ping for a player was just received.

typedef void (*peerPingCallback)(
PEER peer,
const gsi_char * nick,
int ping,
void * param );
RoutineRequired HeaderDistribution
peerPingCallback<peer.h>SDKZIP

Parameters

peer
[in] Initialized peer object
nick
[in] The player's nickname
ping
[in] The Ping value
param
[in] Pointer to user data. This is optional and will be passed unmodified to the callback function.

Remarks

The peerPingCallback will have the latest ping for a playaer. This is the value of the most recent ping of this player. To get the average ping for this player, use peerGetPlayerPing.

Unicode Mappings

RoutineGSI_UNICODE Not DefinedGSI_UNICODE Defined
peerPingCallbackpeerPingCallbackApeerPingCallbackW

peerPingCallbackW and peerPingCallbackA are UNICODE and ANSI mapped versions of peerPingCallback. The arguments of peerPingCallbackA are ANSI strings; those of peerPingCallbackW are wide-character strings.

Section Reference: Gamespy Peer SDK