Account Center
This document will introduce the details about the LI PASS Account Center.
For a product introduction to the Account Center, you can browse the Account Center Module.
- The Account Center currently supports access on mobile and PC platforms, but does not support standard access on console platforms yet.
- If you require manual service, you can consult on enterprise WeChat Player Network Assistant .
Open Account Center
LI PASS provides a unified Account Center interface that supports the following features:
- Bind LI PASS and third-party login channels
- Modify personal information
- Security Settings
- View agreement terms
- Account deletion (visibility controlled by server-side configuration)
- The account deletion function needs to be manually activated (for specific activation details, please consult fanfanliang(Liang Xiaotong) );
- Starting from LI PASS V1.32.00, the Account Center uses a unified API
OpenAccountCenterWithParams. The oldOpenAccountCenter()interface has been deprecated.
Open Account Center
- Unity
- Unreal Engine
Add an Account Center entry button in an appropriate place in the game, and call the OpenAccountCenterWithParams interface in the button's click event to open the Account Center.
var param = new GNAccountCenterParams();
param.AreaId = 1;
param.ZoneId = 1;
LevelInfinite.OpenAccountCenterWithParams(param);
The old OpenAccountCenter() interface has been deprecated since LI PASS V1.32.00. Please migrate to OpenAccountCenterWithParams.
Add an Account Center entry button in an appropriate place in the game, and call the OpenAccountCenterWithParams interface in the button's click event to open the Account Center.
FINTLAccountCenterParams params = FINTLAccountCenterParams();
params.AreaId = 1;
params.ZoneId = 1;
ULevelInfiniteAPI::OpenAccountCenterWithParams(params);
The old OpenAccountCenter() interface has been deprecated since LI PASS V1.32.00 and will generate compile-time warnings in Unreal Engine.Please migrate to OpenAccountCenterWithParams.
Display the Delete Account Button
To display the account deletion button in the Account Center, add the following configuration in the [INTL Account] node in INTLConfig.ini:
[INTL Account]
SHOW_DELETE_ACCOUNT_BUTTON = 1
Starting from LI PASS V1.32.00, the visibility of the Delete Account button is controlled solely by the server-side configuration SHOW_DELETE_ACCOUNT_BUTTON.The AllowDeletion parameter has been removed from the API.The account center now uses a unified API, regardless of whether the deletion function is enabled.
Callback Handling for Account Center
You may need to pay attention to the opening and closing status of the Account Center, which can be handled using the following code for callback:
- Unity
- Unreal Engine
- When the game calls to open the Account Center, it needs to listen to the
ACCOUNT_CENTER_OPENandACCOUNT_CENTER_CLOSEevents; - Refer to LIEventType event and LI PASS Event Callback Information (LIEventObserver).
Sample Code:
LevelInfinite.AddLIEventObserver(OnLIBaseEventResult);
private void OnLIBaseEventResult(LIBaseEventResult liRet)
{
switch (liRet.lIEventType)
{
case LIEventType.OPEN_ACCOUNT_CENTER:
{
logStr = TEXT("Account center open");
break;
}
case LIEventType.CLOSE_ACCOUNT_CENTER:
{
logStr = TEXT("Account center close");
break;
}
}
}
- When the game calls to open the Account Center, it needs to listen to the
ACCOUNT_CENTER_OPENandACCOUNT_CENTER_CLOSEevents; - See LIEventType Events and LI PASS Event Callback Information (LIEventObserver) for details.
Example code:
LIEventObserver = ULevelInfiniteAPI::GetEventDelegate().AddUObject(this, &USample::OnLIEvent_Callback);
void USample::OnLIEvent_Callback(FLIBaseEvent Event)
{
FString logStr;
switch (Event.EventType) {
case ELIEventType::ACCOUNT_CENTER_OPEN:
{
logStr = TEXT("Account center open");
break;
}
case ELIEventType::ACCOUNT_CENTER_CLOSE:
{
logStr = TEXT("Account center close");
break;
}
}
}
Customize Account Center appearance
The LI PASS Account Center provides a standard UI template for games to quickly integrate and use.LI PASS also supports customizing the appearance of the Account Center to ensure it matches the style of the game.For details on customizing the Account Center Appearance, refer to Customizing the Account Center Appearance
- For detailed integration of custom UI/UX features, please consult the Player Network Assistant.