nn::friends::CTR::GetFriendScreenName Function

Syntax

Result GetFriendScreenName(
     char16(*) pScreenNameList[SCREEN_NAME_SIZE],
     const FriendKey * pFriendKeyList,
     size_t size = 1,
     bool replaceForeignCharacters = true,
     u8 * pFontRegionList = NULL
);

Arguments

Name Description
out pScreenNameList[SCREEN_NAME_SIZE] Specifies a pointer to a buffer that stores acquired screen names.
in pFriendKeyList Specifies a pointer to a list of friend keys.
in size Specifies the number of buffer elements in the friend key list.
in replaceForeignCharacters When the font region of the friend's screen name is different than one's own, specifies to use "?" in place of non-ASCII characters.
in pFontRegionList Specifies a pointer to a buffer that stores the font region of a friend's screen name. Specify NULL if not needed.

Return Values

Returns the result of the operation.

Value Description
Result::IsSuccess Process succeeded.
ResultInvalidPointer Invalid pointer passed as argument.
ResultTooLarge The value passed as the argument is too large.
ResultNotInitialized The friend presence library is not initialized.
Other Another result may be returned, depending on the internal state of the daemon and other factors.

Description

Gets a list of friend screen names.

By calling this function, you can get the name of a friend's Mii character directly without using the Mii library. Even if you have not yet established a friend relationship with this person and cannot get his or her Mii character, the display name that you have tentatively registered is obtained.

The actual name of a friend's Mii character is obtained even when it is in the blacklist, but the obtained name is replaced with "???" if it contains profanity.

Returns an empty display name in this buffer if there is no friend corresponding to the key passed in the arguments. The function itself will still return success in this case.

Revision History

2011/03/11
Noted that the function will still return success even if an empty display name is returned.
Revised Description.
Added specific examples of return values.
2010/11/10
Initial version.

CONFIDENTIAL