Connect [MSDK Only]
[MSDK Only] Associates the account with a specified channel, currently only supports Kwai.
Supported Platform
- Unity
- Unreal Engine
Supports
Android, iOS
platform.Supports
Android, iOS
platform.Function Definition
- Unity
- Unreal Engine
void Connect(string channel, string permissions = "", string subChannel = "", string extraJson = "{}");
static void Connect(const std::string &channel, const std::string &permissions = "", const std::string &sub_channel = "", const std::string &extra_json = "{}");
Input Parameters
- Unity
- Unreal Engine
Parameter | Type | Description |
---|---|---|
channel | string | The specified channel to associate Currently only supports Kwai |
permissions | string | The list of authorized permissions Separate the permissions by commas. For example, "user_info,inapp_friends". For more information, see relative channel descriptions. |
subChannel | string | Sub-channel name |
extraJson | string | The extended field. For more information, see relative channel descriptions. |
Parameter | Type | Description |
---|---|---|
channel | std::string | The specified channel to associate Currently only supports Kwai |
permissions | std::string | The list of authorized permissions Separate the permissions by commas. For example, "user_info,inapp_friends". For more information, see relative channel descriptions. |
sub_channel | std::string | Sub-channel name |
extra_json | std::string | The extended field. For more information, see relative channel descriptions. |
Callback Processing
The callback processing API is GUAConnectResultObservers. The callback data structure is GUALoginResult.
- Unity
- Unreal Engine
The callback event is ConnectRetEvents
.
The callback methodID is GUA_ACCOUNT_CONNECT
.
The callback event is OnConnectResultNotify
.
The callback methodID is kMethodIDAccountConnect
.
Code Sample
- Unity
- Unreal Engine
UnionAdapterAPI.GetAccountService().Connect("Kwai");
GUA_NAMESPACE::GUAAccountService::Connect("Kwai");