#include <dwc.h>u8 DWC_GetFriendStatusSC(const DWCFriendData *friendData,
u8 *maxEntry,
u8 *numEntry,
char *statusString);| friendData | Pointer to DWCFriendData type friend data. |
| maxEntry | When the other party is the server host during server-client matchmaking, this pointer stores the maximum connectable number of devices that was obtained. Otherwise, 0. |
| numEntry | When the other party is the server host during server-client matchmaking, this pointer stores the current number of connected devices that was obtained. Otherwise, 0. |
| statusString | Pointer to the location where the friend's status string is stored. If NULL is passed, the string is not copied. The maximum length of the string is 255 characters + the NULL terminator. |
| DWC_STATUS_OFFLINE | Offline (Indicates that oneself is offline or that friendship with the other party has not yet been established.) |
| DWC_STATUS_ONLINE | Online (Logged in to a Wi-Fi Connection server.) |
| DWC_STATUS_PLAYING | Currently playing a game as a client (does not depend on matchmaking type) Currently playing a game as a server, after at least one server exchange, when using friend-specified matchmaking or server-client matchmaking Either of the above states indicate that the local host cannot proceed to connection with this other party. (The PLAYING state is not a state that accepts connection.) |
| DWC_STATUS_MATCH_ANYBODY | Currently searching for a connection partner during peer matchmaking with friend unspecified Currently playing a game as a server during peer matchmaking with friend unspecified |
| DWC_STATUS_MATCH_FRIEND | Currently searching for a connection partner during peer matchmaking with friend specified Currently playing a game as a server during peer matchmaking with friend specified |
| DWC_STATUS_MATCH_SC_CL | Currently connecting to a server as a client host during server-client matchmaking Currently connecting to a server as a group ID connection client host |
| DWC_STATUS_MATCH_SC_SV | Currently playing a game as a server host during server-client matchmaking |
This function gets the communication status of the friend specified with friendData. The GameSpy server sends a notification each time the friend's communication status changes. This is saved in the internal cache of the DWC library. Therefore, this function references that status and does not perform any communications.
A player's communication status is made up of the status flag returned as this function's return value and the status string expressed in the statusString argument. The player status is managed on the GameSpy server. In addition to these, server host-specific information is included during server-client matchmaking. Although the status flag and the server host-specific information are automatically set by the DWC library, applications can set the status string using the DWC_SetOwnStatusString function.
Use the DWC_GetFriendStatus function if there is no need to obtain any specific information during server-client matchmaking. Also, for applications where binary data (rather than character strings such as statusString) is set with the DWC_SetOwnStatusData function, get the binary data using the DWC_GetFriendStatusData or DWC_GetFriendStatusDataSC function.
CONFIDENTIAL