更新玩家背包默认使用的配置资源
This commit is contained in:
parent
430b533c7e
commit
6677b285b8
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -6,14 +6,15 @@
|
|||||||
#include "ProjectFish/DataAsset/BagConfigAsset.h"
|
#include "ProjectFish/DataAsset/BagConfigAsset.h"
|
||||||
#include "ProjectFish/DataAsset/BagShapeAsset.h"
|
#include "ProjectFish/DataAsset/BagShapeAsset.h"
|
||||||
|
|
||||||
void UFishingRodConfigSubsystem::CreateFishingRodInventory(class UBagShapeAsset* FishingRodShape, class UBagShapeAsset* PlayerBagShape)
|
void UFishingRodConfigSubsystem::CreateFishingRodInventory(class UBagShapeAsset* FishingRodShape, class UBagConfigAsset* PlayerBagConfig)
|
||||||
{
|
{
|
||||||
//鱼竿的技能配置资源
|
//鱼竿的技能配置资源
|
||||||
fishingRodInventoryConfig = NewObject<UBagConfigAsset>(this);
|
fishingRodInventoryConfig = NewObject<UBagConfigAsset>(this);
|
||||||
fishingRodInventoryConfig->BagShapeAsset = FishingRodShape;
|
fishingRodInventoryConfig->BagShapeAsset = FishingRodShape;
|
||||||
//玩家背包的技能配置资源
|
//玩家背包的技能配置资源
|
||||||
playerInventoryConfig = NewObject<UBagConfigAsset>(this);
|
// playerInventoryConfig = NewObject<UBagConfigAsset>(this);
|
||||||
playerInventoryConfig->BagShapeAsset = PlayerBagShape;
|
// playerInventoryConfig->BagShapeAsset = PlayerBagShape;
|
||||||
|
playerInventoryConfig = DuplicateObject<UBagConfigAsset>(PlayerBagConfig, this);
|
||||||
}
|
}
|
||||||
|
|
||||||
UBagConfigAsset* UFishingRodConfigSubsystem::GetFishingRodInventory()
|
UBagConfigAsset* UFishingRodConfigSubsystem::GetFishingRodInventory()
|
||||||
|
|||||||
@ -17,7 +17,7 @@ class PROJECTFISH_API UFishingRodConfigSubsystem : public UGameInstanceSubsystem
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
UFUNCTION(BlueprintCallable, Category = "PlayerInventorySubsystem")
|
UFUNCTION(BlueprintCallable, Category = "PlayerInventorySubsystem")
|
||||||
void CreateFishingRodInventory(class UBagShapeAsset* FishingRodShape, class UBagShapeAsset* PlayerBagShape);
|
void CreateFishingRodInventory(class UBagShapeAsset* FishingRodShape, class UBagConfigAsset* PlayerBagConfig);
|
||||||
|
|
||||||
UFUNCTION(BlueprintPure, Category = "PlayerInventorySubsystem")
|
UFUNCTION(BlueprintPure, Category = "PlayerInventorySubsystem")
|
||||||
UBagConfigAsset* GetFishingRodInventory();
|
UBagConfigAsset* GetFishingRodInventory();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user