Rewards Configuration
The LI PASS reward interface supports two reward scenarios as outlined in this article: linking rewards and first login rewards. It only determines if the player is eligible for a reward; the exact reward items and reward delivery are managed by other teams. Contact the Player Network representative to set the reward items, enable the reward delivery functions on the server, and configure the in-game announcements for the reward.
LI PASS interface
Linking rewards
The rewards logic has already been implemented in the LI PASS Account Center and there is no need to call any additional APIs. Once the rewards solution has been implemented, proceed directly to acceptance.
First login rewards
To send the first login reward to players, call the SetRewardExtraJson
API followed by the SendBindReward
API after the player has entered the game lobby. The LI PASS reward service automatically checks the player's eligibility and sends the first login reward to the player's in-game mailbox.
The input parameter of the SetRewardExtraJson
API is a JSON string that corresponds with the IDIP protocol. The input parameters for the SendBindReward
API are a string representing the reward event ID and a JSON string that aligns with the IDIP protocol.
It is recommended to validate the JSON syntax when calling the SetRewardExtraJson
API. Proper JSON format will have to be passed, otherwise compatibility errors may occur.
To obtain the string representing the reward event ID, reach out to the Player Network representative.
- Unity
- Unreal Engine
INTLAPI.SetRewardExtraJson("{}");
INTLAPI.SendBindReward("110001", "{}");
UINTLSDKAPI::SetRewardExtraJson("{}");
UINTLSDKAPI::SendBindReward("110001", "{}");
The JSON fomrat is:
{
"area_id":xx, //int type
"role_id":"xx", //string type
"plat_id":×x, //int type
"zone_id":×× //int type
}
Process reward events
- Unity
- Unreal Engine
- Add/Remove AuthBaseResultObserver
- Add/Remove LIEventObserver
Data structures such as AuthResult and LIBaseEventResult contain login information. To get the login information, see AuthResultObserver and LIEventObserver.
Data structures such as AuthResult and LIBaseEventResult contain login information. To get the login information, see AuthResultObserver and LIEventObserver.
Rewards implementation
Confirm your rewards solution, which includes reward items, distribution methods, and in-game announcements. After this, reach out to the Player Network representative to integrate the rewards solution into LI PASS.