Catalog
Summary
| Members | Descriptions |
|---|---|
class URH_CatalogItem | class used to define a Catalog Item. |
class URH_CatalogSubsystem | Class used to help track and interact with the catalog to get Items, Vendors, and their data. |
class URH_CatalogBlueprintLibrary | Catalog Blueprint Library with helper methods for API structs. |
struct FRHVendorGetRequest | Vendor Request struct used to encapsulate a request to get a vendors and the callback delegate. |
struct FRH_VendorRequestState | Vendor Request struct used to encapsulate a request to get a vendors and the callback delegate. |
class URH_CatalogItem
class URH_CatalogItem
: public UObject
class used to define a Catalog Item.
Summary
| Members | Descriptions |
|---|---|
public FString ETag | The identifier for the versioning of the item. |
public FRHAPI_Item APIItem | Copy of the underlying Catalog item. |
public inline int32 GetItemId() const | Gets the Item Id. |
public inline ERHAPI_ItemType GetType() const | Gets the Item Type. |
public inline int32 GetRefItemId() const | Gets the Item Id of the referenced item. |
public inline int32 GetAvailabilityFlags() const | Gets item availability flags. |
public inline int32 GetEntitledLootId() const | Gets the entitled loot id. |
public inline int32 GetLevelXpTableId() const | Gets the Xp Table associated with the item. |
public inline int32 GetLevelVendorId() const | Gets the Vendor that grants rewards based on inventory count of the item. |
public inline int32 GetCouponDiscountCurrencyItemId() const | Gets the Item Id of the currency type this can discount. |
public inline float GetCouponDiscountPercentage() const | Gets the precentage of the discount this item applies. |
public inline bool GetCouponConsumeOnUse() const | Gets if it will be consumed when used. |
public inline const FString & GetItemInventoryBucketUseRulesetId() const | Gets the set of rules of what platforms this item is available on. |
public inline const TArray< int32 > & GetCouponDiscountLoot() const | Gets the list of loot ids this coupon can be applied to. |
public inline void InitializeFromCatalogItem(const FRHAPI_Item & CatalogItem,int32 InItemId) | Sets up the fata in the Catalog Item. |
public inline void Clear() | Clears all the data for the item. |
protected int32 ItemId | The Item Id. |
protected ERHAPI_ItemType Type | The Item Type. |
protected int32 RefItemId | The Ref Item Id. |
protected int32 AvailabilityFlags | The Availability Flags. |
protected int32 EntitledLootId | The Entitled Loot Id. |
protected int32 LevelXpTableId | The Associated Xp Table Id. |
protected int32 LevelVendorId | The Associated Loot Table if an Xp Table is used. |
protected int32 CouponDiscountCurrencyItemId | The Item Id this can be used to discount purchases with when used as a coupon. |
protected float CouponDiscountPercentage | The percentage of discount this gives when used as a coupon. |
protected bool CouponConsumeOnUse | If set, then when used as a coupon, remove this from inventory. |
protected FString ItemInventoryBucketUseRuleSetId | The inventory use ruleset this item uses. |
protected TArray< int32 > CouponDiscountLoot | List of Loot Table Items this item can be used as a coupon for. |
Members
public FString ETag
The identifier for the versioning of the item.
public FRHAPI_Item APIItem
Copy of the underlying Catalog item.
public inline int32 GetItemId() const
Gets the Item Id.
public inline ERHAPI_ItemType GetType() const
Gets the Item Type.
public inline int32 GetRefItemId() const
Gets the Item Id of the referenced item.
public inline int32 GetAvailabilityFlags() const
Gets item availability flags.
public inline int32 GetEntitledLootId() const
Gets the entitled loot id.
public inline int32 GetLevelXpTableId() const
Gets the Xp Table associated with the item.
public inline int32 GetLevelVendorId() const
Gets the Vendor that grants rewards based on inventory count of the item.
public inline int32 GetCouponDiscountCurrencyItemId() const
Gets the Item Id of the currency type this can discount.
public inline float GetCouponDiscountPercentage() const
Gets the precentage of the discount this item applies.
public inline bool GetCouponConsumeOnUse() const
Gets if it will be consumed when used.
public inline const FString & GetItemInventoryBucketUseRulesetId() const
Gets the set of rules of what platforms this item is available on.
public inline const TArray< int32 > & GetCouponDiscountLoot() const
Gets the list of loot ids this coupon can be applied to.
public inline void InitializeFromCatalogItem(const FRHAPI_Item & CatalogItem,int32 InItemId)
Sets up the fata in the Catalog Item.
Parameters
-
CatalogItemThe API layer item to initialize from. -
InItemIdThe Item Id.
public inline void Clear()
Clears all the data for the item.
protected int32 ItemId
The Item Id.
protected ERHAPI_ItemType Type
The Item Type.
protected int32 RefItemId
The Ref Item Id.
protected int32 AvailabilityFlags
The Availability Flags.
protected int32 EntitledLootId
The Entitled Loot Id.
protected int32 LevelXpTableId
The Associated Xp Table Id.
protected int32 LevelVendorId
The Associated Loot Table if an Xp Table is used.
protected int32 CouponDiscountCurrencyItemId
The Item Id this can be used to discount purchases with when used as a coupon.
protected float CouponDiscountPercentage
The percentage of discount this gives when used as a coupon.
protected bool CouponConsumeOnUse
If set, then when used as a coupon, remove this from inventory.
protected FString ItemInventoryBucketUseRuleSetId
The inventory use ruleset this item uses.
protected TArray< int32 > CouponDiscountLoot
List of Loot Table Items this item can be used as a coupon for.
class URH_CatalogSubsystem
class URH_CatalogSubsystem
: public URH_GameInstanceSubsystemPlugin
: public FTickableGameObject
Class used to help track and interact with the catalog to get Items, Vendors, and their data.
Summary
| Members | Descriptions |
|---|---|
public FRH_CatalogItemUpdatedDelegate OnCatalogItemAdded | Delegate that fires whenever a catalog item is added to the cashed catalog items. |
public virtual void Initialize() | Initialize the subsystem. |
public virtual void Deinitialize() | Safely tears down the subsystem. |
public void GetCatalogAll(const FRH_CatalogCallBlock & Delegate) | Gets the entire catalog at once. |
public void GetCatalogXpAll(const FRH_CatalogCallBlock & Delegate) | Gets all of the xp tables in the catalog. |
public void GetCatalogItem(int32 ItemId,const FRH_CatalogCallBlock & Delegate) | Gets a specific item from the catalog. |
public void GetCatalogInventoryBucketUseRuleSetsAll(const FRH_CatalogCallBlock & Delegate) | Gets all of the inventory bucket rulesets from the catalog. |
public void GetCatalogPricePointsAll(const FRH_CatalogCallBlock & Delegate) | Gets all of the price points from the catalog. |
public void GetCatalogTimeFramesAll(const FRH_CatalogCallBlock & Delegate) | Gets all of the time frames from the catalog. |
public void GetCatalogVendor(const FRHVendorGetRequest & VendorRequest) | Gets the vendors requested as well as their sub vendors. |
public void GetCatalogVendorsAll(const FRH_CatalogCallBlock & Delegate) | Gets the all catalog vendors. |
public bool GetXpTable(int32 XpTableId,FRHAPI_XpTable & XpTable) const | Gets a cached Xp Table. |
public inline bool GetVendorItemByLootId(int32 LootId,FRHAPI_Loot & LootItem) const | Gets a cached vendor item by its loot id. |
public inline URH_CatalogItem*GetCatalogItemByItemId(int32 ItemId) const | Gets a cached catalog item by its item id. |
public inline bool GetVendorById(int32 VendorId,FRHAPI_Vendor & Vendor) const | Gets a cached vendor by its vendor id. |
public inline bool GetPricePointById(const FGuid & PricePointGuid,FRHAPI_PricePoint & PricePoint) const | Gets a cached price point by its price point guid. |
public inline bool GetPricePointById(int32 TimeFrameId,FRHAPI_TimeFrame & TimeFrame) const | Gets a cached time frame by its Time Frame Id. |
public bool CanRulesetUsePlatformForBucket(const FString & InventoryBucketRulesetId,ERHAPI_InventoryBucket TargetBucket,ERHAPI_InventoryBucket ItemInventoryBucket) const | Checks if the ruleset can use the platform for the bucket. |
public inline const TMap< int32, FRHAPI_Vendor> &GetVendors() const | Gets the cached vendors. |
public inline const TMap< int32, URH_CatalogItem* > &GetCatalogItems() const | Gets the cached catalog items. |
public inline const TMap< int32, FRHAPI_XpTable> &GetXpTables() const | Gets the xp tables. |
public inline const TMap< FString, FRHAPI_InventoryBucketUseRuleSet> &GetInventoryBucketUseRuleSets() const | Gets the cached inventory bucket rule sets. |
public inline const TMap< FGuid, FRHAPI_PricePoint> &GetPricePoints() const | Gets the cached price points. |
public inline const TMap< int32, FRHAPI_TimeFrame> &GetTimeFrames() const | Gets the cached time frames. |
public inline virtual FString GetDefaultCatalogFileExportPath() const | |
public void ExportCatalogToFile(const FString & FilePath,const FRH_GenericSuccessWithErrorBlock & Delegate) const | Retrieve all catalog data and save it to a file. |
public void ImportCatalogFromFile(const FString & FilePath,const FRH_CatalogCallBlock & Delegate) | Retrieve all catalog data from a file and load it into the catalog. |
protected TArray< FRH_VendorRequestState>VendorRequests | Array of active vendor requests that are in flight and not responded ot yet. |
protected TMap< int32, TWeakPtr< FRH_AsyncTaskHelper> >InFlightVendorRequests | Map of all vendor requests that are in flight |
protected TMap< int32, FRHAPI_XpTable>XpTables | Xp Table Id to Xp Table Map. |
protected TMap< int32, FRHAPI_Vendor>CatalogVendors | Vendor Id to Vendor Map. |
protected TMap< int32, URH_CatalogItem* >CatalogItems | Item Id to Catalog Item Map. |
protected TMap< int32, FRHAPI_Loot>CatalogLootItems | Loot Id to Catalog Vendor Item Map. |
protected TMap< int32, FRHAPI_TimeFrame>TimeFrames | Timeframe Id to Timeframe Map. |
protected TMap< FGuid, FRHAPI_PricePoint>CatalogPricePoints | Price Point ID to Price Points. |
protected TMap< FString, FRHAPI_InventoryBucketUseRuleSet>InventoryBucketUseRuleSets | Inventory Bucket to Inventory Bucket Use Ruleset Map. |
protected TOptional< FString > GetCatalogAllETag | ETag of last GetCatalogAll call response. |
protected TOptional< FString > GetCatalogXpAllETag | ETag of last GetCatalogXpAll call response. |
protected TOptional< FString > GetCatalogPricePointsAllETag | ETag of last GetCatalogPricePointsAll call response. |
protected TOptional< FString > GetCatalogVendorsAllETag | ETag of last GetCatalogVendorsAll call response. |
protected TOptional< FString > GetCatalogTimeFramesAllETag | ETag of last GetCatalogTimeFramesAll call response. |
protected TOptional< FString > GetCatalogInventoryBucketUseRuleSetsAllETag | ETag of last GetCatalogInventoryBucketUseRuleSetsAll call response. |
protected TMap< int32, TArray< FRH_CatalogCallBlock > > PendingGetCatalogItemCalls | Array of GetCatalogItemCalls yet to be sent to the API layer. |
protected TMap< int32, TArray< FRH_CatalogCallBlock > > SubmittedGetCatalogItemCalls | Array of GetCatalogItemCalls yet being executed by the API layer at this time. |
protected void GetCatalogVendorSingle(int32 VendorId,const FRH_GenericSuccessWithErrorBlock & Delegate) | Makes an API call for a single vendor Id. |
protected virtual void OnGetCatalogVendorResponseUpdate(const TGetCatalogVendor::Response & Resp,int32 VendorId) | Handles the response to a successful Get Catalog Vendor call, updates local cache. |
protected virtual void OnGetCatalogVendorResponseComplete(bool bSuccess,const FRH_ErrorInfo & ErrorInfo,int32 VendorId,FRH_GenericSuccessWithErrorBlock Delegate) | Handles the response to a Get Catalog Vendor call, handles completion and processing of any followup requests. |
protected virtual void ProcessVendorRequests() | Processes the current vendor request list, kicking off any new requests that are needed, and completing existing requests that are done. |
protected virtual void OnGetCatalogVendorsAllResponse(const TGetCatalogVendorsAll::Response & Resp,const FRH_CatalogCallBlock Delegate) | Handles the response to a Get Catalog Vendor All call. |
protected virtual void OnGetCatalogAllResponse(const TGetCatalogAll::Response & Resp,const FRH_CatalogCallBlock Delegate) | Handles the response to a Get Catalog All call. |
protected virtual void OnGetCatalogXpAllResponse(const TGetCatalogXpAll::Response & Resp,const FRH_CatalogCallBlock Delegate) | Handles the response to a Get Catalog Xp All call. |
protected virtual void OnGetCatalogItemResponse(const TGetCatalogItem::Response & Resp,int32 ItemId) | Handles the response to a Get Catalog Item call. |
protected virtual void OnGetCatalogInventoryBucketUseRuleSetsAllResponse(const TGetCatalogInventoryBucketUseRuleSetsAll::Response & Resp,const FRH_CatalogCallBlock Delegate) | Handles the response to a Get Catalog Inventory Bucked Use Rule Sets All call. |
protected virtual void OnGetCatalogPricePointsAllResponse(const TGetCatalogPricePointsAll::Response & Resp,const FRH_CatalogCallBlock Delegate) | Handles the response to a Get Catalog Price Points All call. |
protected virtual void OnGetCatalogTimeFramesAllResponse(const TGetCatalogTimeFramesAll::Response & Resp,const FRH_CatalogCallBlock Delegate) | Handles the response to a Get Catalog Time Frames All call. |
protected void ParseAllXpTables(const FRHAPI_XpTables & Content) | Parses Xp Tables response into the Xp Table Map. |
protected void ParseAllInventoryBucketUseRuleSets(const FRHAPI_InventoryBucketUseRuleSets & Content) | Parses Inventory Bucket Use Rule Sets response into the Inventory Bucket Use Ruleset Map. |
protected URH_CatalogItem*ParseCatalogItem(const FRHAPI_Item & CatalogItem,int32 ItemId) | Parse a Catalog item into the class for it and stores it in the Catalog Items Map. |
protected virtual void InitPropertiesWithDefaultValues() | Initializes the subsystem with defaults for its cached data. |
protected virtual void Tick(float DeltaTime) | Kick off pending requests to the API layer. |
protected inline virtual bool IsTickable() const | Determine if there are pending requests. |
protected inline virtual TStatId GetStatId() const | Gets the catalog subsystem stat Id. |
typedef TGetCatalogAll | Type Define for Get Catalog calls. |
typedef TGetCatalogXpAll | Type Define for Get Catalog Xp calls. |
typedef TGetCatalogInventoryBucketUseRuleSetsAll | Type Define for Get Catalog Inventory Bucket Use Rule Set calls. |
typedef TGetCatalogPricePointsAll | Type Define for Get Catalog Price Point calls. |
typedef TGetCatalogTimeFramesAll | Type Define for Get Catalog Time Frame calls. |
typedef TGetCatalogVendor | Type Define for Get Catalog Vendor calls. |
typedef TGetCatalogVendorsAll | Type Define for Get Catalog Vendor All calls. |
typedef TGetCatalogItem | Type Define for Get Catalog Item calls. |
Members
public FRH_CatalogItemUpdatedDelegate OnCatalogItemAdded
Delegate that fires whenever a catalog item is added to the cashed catalog items.
public virtual void Initialize()
Initialize the subsystem.
public virtual void Deinitialize()
Safely tears down the subsystem.
public void GetCatalogAll(const FRH_CatalogCallBlock & Delegate)
Gets the entire catalog at once.
Parameters
DelegateCallback when the API call is complete.
public void GetCatalogXpAll(const FRH_CatalogCallBlock & Delegate)
Gets all of the xp tables in the catalog.
Parameters
DelegateCallback when the API call is complete.
public void GetCatalogItem(int32 ItemId,const FRH_CatalogCallBlock & Delegate)
Gets a specific item from the catalog.
Parameters
-
ItemIdThe item id of the item to get. -
DelegateCallback when the API call is complete.
public void GetCatalogInventoryBucketUseRuleSetsAll(const FRH_CatalogCallBlock & Delegate)
Gets all of the inventory bucket rulesets from the catalog.
Parameters
DelegateCallback when the API call is complete.
public void GetCatalogPricePointsAll(const FRH_CatalogCallBlock & Delegate)
Gets all of the price points from the catalog.
Parameters
DelegateCallback when the API call is complete.
public void GetCatalogTimeFramesAll(const FRH_CatalogCallBlock & Delegate)
Gets all of the time frames from the catalog.
Parameters
DelegateCallback when the API call is complete.
public void GetCatalogVendor(const FRHVendorGetRequest & VendorRequest)
Gets the vendors requested as well as their sub vendors.
Parameters
-
VendorRequestThe vendor request data for the call with list of vendors and callback on complete. -
bRecurseSubvendorsWhether to recursively request subvendors, DEPRECATED
public void GetCatalogVendorsAll(const FRH_CatalogCallBlock & Delegate)
Gets the all catalog vendors.
Parameters
DelegateCallback when the API call is complete.
public bool GetXpTable(int32 XpTableId,FRHAPI_XpTable & XpTable) const
Gets a cached Xp Table.
Parameters
-
XpTableIdThe xp table id of the xp table to get. -
XpTableThe xp table to be returned.
Returns
If true, the Xp Table was found.
public inline bool GetVendorItemByLootId(int32 LootId,FRHAPI_Loot & LootItem) const
Gets a cached vendor item by its loot id.
Parameters
-
LootIdThe Loot Id used to look up the vendor item. -
LootItemThe loot item to be returned.
Returns
If true, the loot item was found.
public inline URH_CatalogItem*GetCatalogItemByItemId(int32 ItemId) const
Gets a cached catalog item by its item id.
Parameters
ItemIdThe Item Id used to look up the catalog item.
Returns
The catalog item if found, otherwise nullptr.
public inline bool GetVendorById(int32 VendorId,FRHAPI_Vendor & Vendor) const
Gets a cached vendor by its vendor id.
Parameters
-
VendorIdThe Vendor Id used to look up the vendor. -
VendorThe vendor to be returned.
Returns
If true, the vendor was found.
public inline bool GetPricePointById(const FGuid & PricePointGuid,FRHAPI_PricePoint & PricePoint) const
Gets a cached price point by its price point guid.
Parameters
-
PricePointGuidThe price point guid used to look up the vendor. -
PricePointThe price point to be returned.
Returns
If true, the price point was found.
public inline bool GetPricePointById(int32 TimeFrameId,FRHAPI_TimeFrame & TimeFrame) const
Gets a cached time frame by its Time Frame Id.
Parameters
-
TimeFrameIdThe id used to look up the time frame. -
TimeFrameThe time frame to be returned.
Returns
If true, the time frame was found.
public bool CanRulesetUsePlatformForBucket(const FString & InventoryBucketRulesetId,ERHAPI_InventoryBucket TargetBucket,ERHAPI_InventoryBucket ItemInventoryBucket) const
Checks if the ruleset can use the platform for the bucket.
Parameters
-
InventoryBucketRulesetIdThe ruleset bucket to be used to evaluate the usage. -
TargetBucketThe bucket that should be used to evaluate the usage. -
ItemInventoryBucketThe bucket the item is in that is being evaluated.
Returns
If true, the item can be used for the specified bucket.
public inline const TMap< int32, FRHAPI_Vendor> &GetVendors() const
Gets the cached vendors.
public inline const TMap< int32, URH_CatalogItem* > &GetCatalogItems() const
Gets the cached catalog items.
public inline const TMap< int32, FRHAPI_XpTable> &GetXpTables() const
Gets the xp tables.
public inline const TMap< FString, FRHAPI_InventoryBucketUseRuleSet> &GetInventoryBucketUseRuleSets() const
Gets the cached inventory bucket rule sets.
public inline const TMap< FGuid, FRHAPI_PricePoint> &GetPricePoints() const
Gets the cached price points.
public inline const TMap< int32, FRHAPI_TimeFrame> &GetTimeFrames() const
Gets the cached time frames.
public inline virtual FString GetDefaultCatalogFileExportPath() const
public void ExportCatalogToFile(const FString & FilePath,const FRH_GenericSuccessWithErrorBlock & Delegate) const
Retrieve all catalog data and save it to a file.
Parameters
-
FilePathThe file path to save the catalog data to. -
DelegateCallback when the API call is complete and the file is written.
public void ImportCatalogFromFile(const FString & FilePath,const FRH_CatalogCallBlock & Delegate)
Retrieve all catalog data from a file and load it into the catalog.
Parameters
-
FilePathThe file path to load the catalog data from. -
DelegateCallback when the API call is complete and the file is read.
protected TArray< FRH_VendorRequestState>VendorRequests
Array of active vendor requests that are in flight and not responded ot yet.
protected TMap< int32, TWeakPtr< FRH_AsyncTaskHelper> >InFlightVendorRequests
Map of all vendor requests that are in flight
protected TMap< int32, FRHAPI_XpTable>XpTables
Xp Table Id to Xp Table Map.
protected TMap< int32, FRHAPI_Vendor>CatalogVendors
Vendor Id to Vendor Map.
protected TMap< int32, URH_CatalogItem* >CatalogItems
Item Id to Catalog Item Map.
protected TMap< int32, FRHAPI_Loot>CatalogLootItems
Loot Id to Catalog Vendor Item Map.
protected TMap< int32, FRHAPI_TimeFrame>TimeFrames
Timeframe Id to Timeframe Map.
protected TMap< FGuid, FRHAPI_PricePoint>CatalogPricePoints
Price Point ID to Price Points.
protected TMap< FString, FRHAPI_InventoryBucketUseRuleSet>InventoryBucketUseRuleSets
Inventory Bucket to Inventory Bucket Use Ruleset Map.
protected TOptional< FString > GetCatalogAllETag
ETag of last GetCatalogAll call response.
protected TOptional< FString > GetCatalogXpAllETag
ETag of last GetCatalogXpAll call response.
protected TOptional< FString > GetCatalogPricePointsAllETag
ETag of last GetCatalogPricePointsAll call response.
protected TOptional< FString > GetCatalogVendorsAllETag
ETag of last GetCatalogVendorsAll call response.
protected TOptional< FString > GetCatalogTimeFramesAllETag
ETag of last GetCatalogTimeFramesAll call response.
protected TOptional< FString > GetCatalogInventoryBucketUseRuleSetsAllETag
ETag of last GetCatalogInventoryBucketUseRuleSetsAll call response.
protected TMap< int32, TArray< FRH_CatalogCallBlock > > PendingGetCatalogItemCalls
Array of GetCatalogItemCalls yet to be sent to the API layer.
protected TMap< int32, TArray< FRH_CatalogCallBlock > > SubmittedGetCatalogItemCalls
Array of GetCatalogItemCalls yet being executed by the API layer at this time.
protected void GetCatalogVendorSingle(int32 VendorId,const FRH_GenericSuccessWithErrorBlock & Delegate)
Makes an API call for a single vendor Id.
Parameters
VendorIdThe Vendor to request.
protected virtual void OnGetCatalogVendorResponseUpdate(const TGetCatalogVendor::Response & Resp,int32 VendorId)
Handles the response to a successful Get Catalog Vendor call, updates local cache.
Parameters
-
RespResponse given for the call -
VendorIdThe Vendor Id that was requested.
protected virtual void OnGetCatalogVendorResponseComplete(bool bSuccess,const FRH_ErrorInfo & ErrorInfo,int32 VendorId,FRH_GenericSuccessWithErrorBlock Delegate)
Handles the response to a Get Catalog Vendor call, handles completion and processing of any followup requests.
Parameters
-
bSuccessIf the call was successful. -
ErrorInfoThe error information if the call failed. -
VendorIdThe Vendor Id that was requested. -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void ProcessVendorRequests()
Processes the current vendor request list, kicking off any new requests that are needed, and completing existing requests that are done.
protected virtual void OnGetCatalogVendorsAllResponse(const TGetCatalogVendorsAll::Response & Resp,const FRH_CatalogCallBlock Delegate)
Handles the response to a Get Catalog Vendor All call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnGetCatalogAllResponse(const TGetCatalogAll::Response & Resp,const FRH_CatalogCallBlock Delegate)
Handles the response to a Get Catalog All call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnGetCatalogXpAllResponse(const TGetCatalogXpAll::Response & Resp,const FRH_CatalogCallBlock Delegate)
Handles the response to a Get Catalog Xp All call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnGetCatalogItemResponse(const TGetCatalogItem::Response & Resp,int32 ItemId)
Handles the response to a Get Catalog Item call.
Parameters
-
RespResponse given for the call. -
ItemIdThe Item Id being requested.
protected virtual void OnGetCatalogInventoryBucketUseRuleSetsAllResponse(const TGetCatalogInventoryBucketUseRuleSetsAll::Response & Resp,const FRH_CatalogCallBlock Delegate)
Handles the response to a Get Catalog Inventory Bucked Use Rule Sets All call.
Parameters
-
RespResponse given for the call. -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnGetCatalogPricePointsAllResponse(const TGetCatalogPricePointsAll::Response & Resp,const FRH_CatalogCallBlock Delegate)
Handles the response to a Get Catalog Price Points All call.
Parameters
-
RespResponse given for the call. -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnGetCatalogTimeFramesAllResponse(const TGetCatalogTimeFramesAll::Response & Resp,const FRH_CatalogCallBlock Delegate)
Handles the response to a Get Catalog Time Frames All call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected void ParseAllXpTables(const FRHAPI_XpTables & Content)
Parses Xp Tables response into the Xp Table Map.
Parameters
ContentXp Tables to parse.
protected void ParseAllInventoryBucketUseRuleSets(const FRHAPI_InventoryBucketUseRuleSets & Content)
Parses Inventory Bucket Use Rule Sets response into the Inventory Bucket Use Ruleset Map.
Parameters
ContentInventory Bucket Use Rule Sets to parse.
protected URH_CatalogItem*ParseCatalogItem(const FRHAPI_Item & CatalogItem,int32 ItemId)
Parse a Catalog item into the class for it and stores it in the Catalog Items Map.
Parameters
-
CatalogItemItem to be parsed. -
ItemIdItem Id of the item being parsed.
Returns
The Catalog Item as its class.
protected virtual void InitPropertiesWithDefaultValues()
Initializes the subsystem with defaults for its cached data.
protected virtual void Tick(float DeltaTime)
Kick off pending requests to the API layer.
protected inline virtual bool IsTickable() const
Determine if there are pending requests.
protected inline virtual TStatId GetStatId() const
Gets the catalog subsystem stat Id.
typedef TGetCatalogAll
Type Define for Get Catalog calls.
typedef TGetCatalogXpAll
Type Define for Get Catalog Xp calls.
typedef TGetCatalogInventoryBucketUseRuleSetsAll
Type Define for Get Catalog Inventory Bucket Use Rule Set calls.
typedef TGetCatalogPricePointsAll
Type Define for Get Catalog Price Point calls.
typedef TGetCatalogTimeFramesAll
Type Define for Get Catalog Time Frame calls.
typedef TGetCatalogVendor
Type Define for Get Catalog Vendor calls.
typedef TGetCatalogVendorsAll
Type Define for Get Catalog Vendor All calls.
typedef TGetCatalogItem
Type Define for Get Catalog Item calls.
class URH_CatalogBlueprintLibrary
class URH_CatalogBlueprintLibrary
: public UBlueprintFunctionLibrary
Catalog Blueprint Library with helper methods for API structs.
Summary
| Members | Descriptions |
|---|
Members
struct FRHVendorGetRequest
Vendor Request struct used to encapsulate a request to get a vendors and the callback delegate.
Summary
| Members | Descriptions |
|---|---|
public FRH_CatalogCallBlock Delegate | Delegate callback when all vendors have been fetched. |
public TArray< int32 > VendorIds | Array of outstanding vendor requests to complete this vendor get. |
public bool bRecurseSubvendors | |
public bool bSkipCachedVendors | |
public inline FRHVendorGetRequest() | Default Constructor. |
public inline FRHVendorGetRequest(const TArray< int32 > & InVendorIds) | Constructor with vendor Id List. |
public inline FRHVendorGetRequest(const FRH_CatalogCallBlock & InDelegate,const TArray< int32 > & InVendorIds) | Constructor with vendor Id List and callback delegate. |
Members
public FRH_CatalogCallBlock Delegate
Delegate callback when all vendors have been fetched.
public TArray< int32 > VendorIds
Array of outstanding vendor requests to complete this vendor get.
public bool bRecurseSubvendors
public bool bSkipCachedVendors
public inline FRHVendorGetRequest()
Default Constructor.
public inline FRHVendorGetRequest(const TArray< int32 > & InVendorIds)
Constructor with vendor Id List.
Parameters
InVendorIdsList of vendor Ids to get.
public inline FRHVendorGetRequest(const FRH_CatalogCallBlock & InDelegate,const TArray< int32 > & InVendorIds)
Constructor with vendor Id List and callback delegate.
Parameters
-
InDelegateDelegate to call when vendor fetch completes. -
InVendorIdsList of vendor Ids to get.
struct FRH_VendorRequestState
Vendor Request struct used to encapsulate a request to get a vendors and the callback delegate.
Summary
| Members | Descriptions |
|---|---|
public TWeakObjectPtr< class URH_CatalogSubsystem>Catalog | |
public FRHVendorGetRequest Request | Array of outstanding vendor requests to complete this vendor get. |
public TArray< int32 > VendorsReceived | A list of vendors received since this request was made. |
public inline FRH_VendorRequestState() | Default Constructor. |
public inline FRH_VendorRequestState(class URH_CatalogSubsystem* InCatalog,constFRHVendorGetRequest & InRequest) | Constructor with a request and a subsystem. |
public inline void NotifyVendorReceived(int32 VendorId,const FRHAPI_Vendor & Vendor) | Notify that a vendor has been received. |
public inline bool NotifyVendorFailure(int32 VendorId) | Notify that a vendor has failed to be received. |
public TArray< int32 > GetAllKnownVendorIds() const | Get a list of all currently known vendors associated with this request. |
public TArray< int32 > GetAwaitedVendorIds() const | Get a list of all currently known vendors this request is waiting on. |
public inline bool IsComplete(TArray< int32 > & OutAwaitedVendors) const | Check if all vendors have been received, and fire delegate if so. |
Members
public TWeakObjectPtr< class URH_CatalogSubsystem>Catalog
public FRHVendorGetRequest Request
Array of outstanding vendor requests to complete this vendor get.
public TArray< int32 > VendorsReceived
A list of vendors received since this request was made.
public inline FRH_VendorRequestState()
Default Constructor.
public inline FRH_VendorRequestState(class URH_CatalogSubsystem* InCatalog,constFRHVendorGetRequest & InRequest)
Constructor with a request and a subsystem.
Parameters
-
InCatalogThe Catalog Subsystem to use. -
InRequestThe request to use.
public inline void NotifyVendorReceived(int32 VendorId,const FRHAPI_Vendor & Vendor)
Notify that a vendor has been received.
Parameters
-
VendorIdThe VendorID received -
VendorThe Vendor data received
public inline bool NotifyVendorFailure(int32 VendorId)
Notify that a vendor has failed to be received.
Parameters
VendorIdThe VendorID that failed
Returns
Whether the vendor was awaited and the request should be failed
public TArray< int32 > GetAllKnownVendorIds() const
Get a list of all currently known vendors associated with this request.
public TArray< int32 > GetAwaitedVendorIds() const
Get a list of all currently known vendors this request is waiting on.
public inline bool IsComplete(TArray< int32 > & OutAwaitedVendors) const
Check if all vendors have been received, and fire delegate if so.
Parameters
OutAwaitedVendorsList of vendors that are still awaited
Returns
If all vendors have been received