AutoLogin
If you were looking for the method for use with Unity, see AutoLogin for Unity SDK.
-
Check the status of the custom account or LI PASS registered by email, and the version of the legal terms agreed to by this account.
-
Query the player's minor authentication status.
-
Automatically log in to LI PASS. The automatic login is successful, and the player enters the game. If automatic login fails, call OpenLoginPanel to log in manually.
When calling back, if the NeedNotify
field is 1, a prompt needs to pop up to remind the player that the custom account will be upgraded to LI PASS, and the prompt needs to include the legal terms of the game.
After agreeing to the terms and continue, call UpgradeSaccToLI.
After the UpgradeSaccToLI
interface succeeds, the upgrade is completed, and the compliance process continues.
- After calling LevelInfinite.AutoLogin, do not call the old automatic login interface INTLAPI.AutoLogin, otherwise it will automatically log in twice.
- Call AutoLogin after receiving
GN_READY
in theLevelInfinite.Init
callback.
Function definition
UFUNCTION(BlueprintCallable, Category = "LevelInfinite")
static void AutoLogin();
Observers
The callback processing interface is AuthResultObserver.
The callback data structure is AuthResult.
The callback methodID is kLIAutoLoginEnterGame
.
Code sample
ULevelInfiniteAPI::AutoLogin();