Skip to main content

SetAccountInfo [Player Network SDK Only]

[Player Network SDK Only] Set account information for custom accounts.

note

To create a custom account, the first step is to call SetAccountInfo to set necessary information. This method does not have a callback.

If you do not call this method first, and use other methods of creating your own account, an error message will be appear on the console.

Supported Platform

Supports Android, iOS, Windows platform.

Function Definition

void SetAccountInfo(string channel, int channelId, string langType, int accountPlatType, string extraJson = "{}");

Input Parameters

ParameterTypeDescription
channelstringChannel of a custom account, which is associated with the platform account, such as CustomAccount or EGame
channelIdintACCOUNT_PLAT_TYPE assigned by Player Network Console
langTypestringLanguage type (RFC 4646), such as "en". It defines the language used to send emails and SMS messages.
For details, see Language Type Definition.
accountPlatTypeintACCOUNT_PLAT_TYPE assigned by Player Network Console
extraJsonintExtended information

Code Sample

UnionAdapterAPI.GetAccountService().SetAccountInfo("Self", 1, "en", 1);