Use Wallets In-Game
Get Player Wallet
Get Player Wallet by Holder ID
string holderUlid; //holderUlid can be found in the start Session calls as response.player_ulid
LootLocker.LootLockerEnums.LootLockerWalletHolderTypes player = LootLocker.LootLockerEnums.LootLockerWalletHolderTypes.player;
LootLockerSDKManager.GetWalletByHolderId(holderUlid, player, (response) =>
{
if(!response.success)
{
//If wallet is not found, it will automatically create one on the holder.
Debug.Log("error: " + response.errorData.message);
Debug.Log("request ID: " + response.errorData.request_id);
return;
}
});
To see what data gets returned, please refer to our Reference Documentation.
Get Character Wallet by Holder ID
string holderUlid; //holderUlid can be found in the start Session calls as response.player_ulid
LootLocker.LootLockerEnums.LootLockerWalletHolderTypes character = LootLocker.LootLockerEnums.LootLockerWalletHolderTypes.character;
LootLockerSDKManager.GetWalletByHolderId(holderUlid, character, (response) =>
{
if(!response.success)
{
//If wallet is not found, it will automatically create one on the holder.
Debug.Log("error: " + response.errorData.message);
Debug.Log("request ID: " + response.errorData.request_id);
return;
}
});
To see what data gets returned, please refer to our Reference Documentation.
Get Wallet by Wallet ID
string WalletID = "";
LootLockerSDKManager.GetWalletByWalletId(walletID, (response) =>
{
if(!response.success)
{
Debug.Log("error: " + response.errorData.message);
Debug.Log("request ID: " + response.errorData.request_id);
return;
}
});
To see what data gets returned, please refer to our Reference Documentation.
Credit / Debit Wallet
Credit Wallet
string WalletID = "";
string currencyID = "";
string amount = "100";
LootLockerSDKManager.CreditBalanceToWallet(walletID, currencyID, amount, (response) =>
{
if(!response.success)
{
Debug.Log("error: " + response.errorData.message);
Debug.Log("request ID: " + response.errorData.request_id);
return;
}
});
To see what data gets returned, please refer to our Reference Documentation.
Debit Wallet
string WalletID = "";
string currencyID = "";
string amount = "100";
LootLockerSDKManager.DebitBalanceToWallet(walletID, currencyID, amount, (response) =>
{
if(!response.success)
{
Debug.Log("error: " + response.errorData.message);
Debug.Log("request ID: " + response.errorData.request_id);
return;
}
});
To see what data gets returned, please refer to our Reference Documentation.
List Balances in Wallet
string walletID = "";
LootLockerSDKManager.ListBalancesInWallet(walletID, (response) =>
{
if(!response.success)
{
Debug.Log("error: " + response.errorData.message);
Debug.Log("request ID: " + response.errorData.request_id);
return;
}
});
To see what data gets returned, please refer to our Reference Documentation.
Last updated