LootLocker Unreal SDK 10.4.0
Game backend SDK for Unreal Engine
Loading...
Searching...
No Matches
LootLockerBalanceRequestHandler.h
Go to the documentation of this file.
1// Copyright (c) 2021 LootLocker
2
3#pragma once
4
5
6#include "CoreMinimal.h"
10#include "LootLockerBalanceRequestHandler.generated.h"
11
12//==================================================
13// Data Type Definitions
14//==================================================
15
16
19UENUM(BlueprintType, Category = "LootLocker")
24{
25 character = 0,
26 player = 1,
27};
29
33USTRUCT(BlueprintType, Category="LootLocker")
35{
36 GENERATED_BODY()
40 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
41 FString Amount = "";
45 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
50 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
51 FString Wallet_id = "";
55 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
56 FString Created_at = "";
57};
58
62USTRUCT(BlueprintType, Category = "LootLocker")
64{
65 GENERATED_BODY()
69 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
70 FString Currency_id = "";
74 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
75 FString Currency_name = "";
79 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
80 FString Currency_code = "";
84 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
85 FString Factor = "";
89 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
90 FString Created_at = "";
94 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
95 FString Expires_at = "";
96};
97
98//==================================================
99// Request Definitions
100//==================================================
101
105USTRUCT(BlueprintType, Category="LootLocker")
107{
108 GENERATED_BODY()
112 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
113 FString Holder_id = "";
117 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
118 FString Holder_type = "";
122 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
123 FString Id = "";
124};
125
129USTRUCT(BlueprintType, Category="LootLocker")
131{
132 GENERATED_BODY()
136 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
137 FString Amount = "";
141 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
142 FString Currency_id = "";
145 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
146 FString Wallet_id = "";
147};
148
152USTRUCT(BlueprintType, Category="LootLocker")
154{
155 GENERATED_BODY()
159 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
160 FString Amount = "";
164 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
165 FString Currency_id = "";
168 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
169 FString Wallet_id = "";
170};
171
172
173//==================================================
174// Response Definitions
175//==================================================
176
180USTRUCT(BlueprintType, Category="LootLocker")
182{
183 GENERATED_BODY()
187 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
188 TArray<FLootLockerBalance> Balances;
189};
190
194USTRUCT(BlueprintType, Category="LootLocker")
196{
197 GENERATED_BODY()
201 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
202 FString Holder_id = "";
206 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
207 FString Id = "";
211 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
216 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
218};
219
223USTRUCT(BlueprintType, Category = "LootLocker")
225{
226 GENERATED_BODY()
230 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
231 FString Amount = "";
235 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
240 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
241 FString Wallet_id = "";
245 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
246 FString Created_at = "";
247};
248
252USTRUCT(BlueprintType, Category = "LootLocker")
254{
255 GENERATED_BODY()
259 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
260 FString Amount = "";
264 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
269 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
270 FString Wallet_id = "";
274 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
275 FString Created_at = "";
276};
277
281USTRUCT(BlueprintType, Category="LootLocker")
283{
284 GENERATED_BODY()
288 UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "LootLocker")
289 FString Wallet_id = "";
290};
291//==================================================
292// Delegate Definitions
293//==================================================
296
316
317
318//==================================================
319// API Class Definition
320//==================================================
321
323UCLASS()
324class LOOTLOCKERSDK_API ULootLockerBalanceRequestHandler : public UObject
325{
326 GENERATED_BODY()
327public:
329
330 static FString ListBalancesInWallet(const FLootLockerPlayerData& PlayerData, const FString& WalletID, const FLootLockerListBalancesForWalletResponseDelegate& OnComplete);
331 static FString GetWalletByWalletID(const FLootLockerPlayerData& PlayerData, const FString& WalletID, const FLootLockerGetWalletResponseDelegate& OnComplete);
332 static FString GetWalletByHolderID(const FLootLockerPlayerData& PlayerData, const FString& HolderULID, const ELootLockerWalletHolderTypes& HolderType, const FLootLockerGetWalletResponseDelegate& OnComplete);
333 static FString CreditBalanceToWallet(const FLootLockerPlayerData& PlayerData, const FString& WalletID, const FString& CurrencyID, const FString& Amount, const FLootLockerCreditWalletResponseDelegate& OnComplete);
334 static FString DebitBalanceToWallet(const FLootLockerPlayerData& PlayerData, const FString& WalletID, const FString& CurrencyID, const FString& Amount, const FLootLockerDebitWalletResponseDelegate& OnComplete);
335private:
336 static FString CreateWallet(const FLootLockerPlayerData& PlayerData, const FString& HolderULID, const ELootLockerWalletHolderTypes& HolderType, const FLootLockerCreateWalletResponseDelegate& OnComplete);
337};
Definition LootLockerBalanceRequestHandler.h:325
static FString GetWalletByWalletID(const FLootLockerPlayerData &PlayerData, const FString &WalletID, const FLootLockerGetWalletResponseDelegate &OnComplete)
static FString ListBalancesInWallet(const FLootLockerPlayerData &PlayerData, const FString &WalletID, const FLootLockerListBalancesForWalletResponseDelegate &OnComplete)
ULootLockerBalanceRequestHandler()
Definition LootLockerBalanceRequestHandler.h:328
static FString GetWalletByHolderID(const FLootLockerPlayerData &PlayerData, const FString &HolderULID, const ELootLockerWalletHolderTypes &HolderType, const FLootLockerGetWalletResponseDelegate &OnComplete)
static FString CreditBalanceToWallet(const FLootLockerPlayerData &PlayerData, const FString &WalletID, const FString &CurrencyID, const FString &Amount, const FLootLockerCreditWalletResponseDelegate &OnComplete)
static FString DebitBalanceToWallet(const FLootLockerPlayerData &PlayerData, const FString &WalletID, const FString &CurrencyID, const FString &Amount, const FLootLockerDebitWalletResponseDelegate &OnComplete)
ELootLockerWalletHolderTypes
Possible wallet holder types.
Definition LootLockerBalanceRequestHandler.h:24
void(* FLootLockerCreateWalletResponseDelegate)(FLootLockerCreateWalletResponse)
C++ response delegate for creating a wallet.
Definition LootLockerBalanceRequestHandler.h:315
void(* FLootLockerGetWalletResponseDelegate)(FLootLockerGetWalletResponse)
C++ response delegate for getting a wallet.
Definition LootLockerBalanceRequestHandler.h:303
void(* FLootLockerListBalancesForWalletResponseDelegate)(FLootLockerListBalancesForWalletResponse)
C++ response delegate for listing balances in a wallet.
Definition LootLockerBalanceRequestHandler.h:299
void(* FLootLockerCreditWalletResponseDelegate)(FLootLockerCreditWalletResponse)
C++ response delegate for crediting currency to a wallet.
Definition LootLockerBalanceRequestHandler.h:307
void(* FLootLockerDebitWalletResponseDelegate)(FLootLockerDebitWalletResponse)
C++ response delegate for debiting currency from a wallet.
Definition LootLockerBalanceRequestHandler.h:311
Describes a currency balance modifier with a scaling factor, currency reference, and optional expirat...
Definition LootLockerBalanceRequestHandler.h:64
Represents a currency balance in a wallet, including the amount, currency details,...
Definition LootLockerBalanceRequestHandler.h:35
Request to create a wallet for a specified holder, identified by ULID and holder type.
Definition LootLockerBalanceRequestHandler.h:107
Response containing the unique identifier of the newly created wallet.
Definition LootLockerBalanceRequestHandler.h:283
Request to credit a specified amount of a given currency to a wallet.
Definition LootLockerBalanceRequestHandler.h:131
Response containing the resulting balance entry after crediting currency to a wallet.
Definition LootLockerBalanceRequestHandler.h:225
Details about a particular currency.
Definition LootLockerCurrencyRequestHandler.h:20
Request to debit a specified amount of a given currency from a wallet.
Definition LootLockerBalanceRequestHandler.h:154
Response containing the resulting balance entry after debiting currency from a wallet.
Definition LootLockerBalanceRequestHandler.h:254
Response containing a wallet's holder identifier, holder type, and active balance modifiers.
Definition LootLockerBalanceRequestHandler.h:196
Response containing the list of currency balances held in a specific wallet.
Definition LootLockerBalanceRequestHandler.h:182
Definition LootLockerPlayerData.h:12
Base response struct — every SDK callback receives a struct that derives from this.
Definition LootLockerResponse.h:19