Skip to main content

Open Account Center (OpenAccountCenterWithParams)

AndroidiOSWindows
Supported in: LI PASS V1.32.00
If you are using Unreal Engine, see OpenAccountCenterWithParams for Unreal Engine SDK.

Open the LI PASS Account Center interface. The Account Center provides features such as binding LI PASS and third-party login channels, modifying personal information, security settings, and viewing agreement terms. The visibility of the Delete Account button is controlled by the server-side configuration SHOW_DELETE_ACCOUNT_BUTTON.

note

The OpenAccountCenterWithParams interface supports Unity starting from LI PASS V1.14 and has been updated to use GNAccountCenterParams since V1.32.

Function Definition

public static void OpenAccountCenterWithParams(GNAccountCenterParams accountCenterParams);

Parameter Description

ParameterTypeDescription
paramsGNAccountCenterParamsParameters required for opening the Account Center

GNAccountCenterParams

Member VariableTypeDescription
AreaIdintRegion ID of the account
ZoneIdintZone ID of the account

Callback Handling

Callback for LI PASS events. The game needs to handle the callback logic.For more information about callback data structures, see LIEventObserver.

The callback LIEventType can be ACCOUNT_CENTER_OPEN and ACCOUNT_CENTER_CLOSE, which are used to open or close the Account Center.

The callback LIEventType can be DELETE_ACCOUNT_SUCCESS, DELETE_ACCOUNT_FAIL, and DELETE_PARAMETERS_MISSING, which are used for account deletion.Users can listen to related events to get the current account deletion status and handle subsequent processes.

Code Example

var param = new GNAccountCenterParams();
param.AreaId = 1;
param.ZoneId = 1;
LevelInfinite.OpenAccountCenterWithParams(param);

UI Example

Image: LI PASS Account Center interface with Delete Account button

The player can enter the Account Deletion H5 page and start the account deletion process by clicking the Delete Account button.Developers can use the SHOW_DELETE_ACCOUNT_BUTTON field in the configuration file to set whether to display this button.