peerSetAwayMode
Set the away mode, as it appears in chat.
- void peerSetAwayMode(
- PEER peer,
- const gsi_char * reason );
Routine | Required Header | Distribution |
---|---|---|
peerSetAwayMode | <peer.h> | SDKZIP |
Parameters
- peer
- [in] Initialized peer object.
- reason
- [in] Reason for being away. Set to NULL or "" if not away.
Remarks
The peerSetAwayMode sets the away mode of the local player. If an empty string or NULL, away mode is off. If a valid string, away mode is on. Once on, away mode will stay active until it is turned off, or the connection is disconnected. To check if a player is away, check his flags (with peerGetPlayerFlags()), and check for PEER_FLAG_AWAY. To get the reason, check for that player’s special "away" global key (with peerGetPlayerGlobalKeys()). This function has no effect if peer object is not connected.
Unicode Mappings
Routine | GSI_UNICODE Not Defined | GSI_UNICODE Defined |
---|---|---|
peerSetAwayMode | peerSetAwayModeA | peerSetAwayModeW |
peerSetAwayModeW and peerSetAwayModeA are UNICODE and ANSI mapped versions of peerSetAwayMode. The arguments of peerSetAwayModeA are ANSI strings; those of peerSetAwayModeW are wide-character strings.
Section Reference: Gamespy Peer SDK