feat: RP Data Assets

This commit is contained in:
2024-10-25 14:45:06 +02:00
parent 90ac5dca32
commit bfd977e1e1
6 changed files with 194 additions and 67 deletions

View File

@@ -14,15 +14,27 @@ class REFINEDRDAPI_API URRDABoilerDataAsset : public URRDADataAssetBase
GENERATED_BODY()
public:
/**
* Fuel item that this heater uses
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Turbine", meta=( UIMin = "1", UIMax = "2" ))
int32 mTier = 1;
/**
* Fuel item that this heater uses
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Boiler")
FItemAmount mItem;
FItemAmount mInput;
/**
* What this boiler produces
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Boiler")
FItemAmount mOutputItem;
FItemAmount mOutput;
/**
* Duration for one production
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Boiler")
float mDuration = 6.f;
};

View File

@@ -5,6 +5,7 @@
#include "CoreMinimal.h"
#include "ItemAmount.h"
#include "RRDADataAssetBase.h"
#include "Enums/RRDARPEnums.h"
#include "RRDACoolerDataAsset.generated.h"
@@ -14,9 +15,27 @@ class REFINEDRDAPI_API URRDACoolerDataAsset : public URRDADataAssetBase
GENERATED_BODY()
public:
/**
* What type of heater this is
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Heater")
ERRDACoolerType mType = ERRDACoolerType::Chemical;
/**
* Fuel item that this heater uses
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Cooler")
FItemAmount mItem;
TSubclassOf<UFGItemDescriptor> mItem;
/**
* How much of the item is used
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Cooler")
int32 mAmount = 1000;
/**
* Duration for one production
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Boiler")
float mDuration = 6.f;
};

View File

@@ -19,7 +19,7 @@ public:
* What type of heater this is
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Heater")
ERRDAHeaterType mHeaterType;
ERRDAHeaterType mType = ERRDAHeaterType::Biomass;
/**
* Fuel item that this heater uses
@@ -33,4 +33,10 @@ public:
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Heater")
FItemAmount mOutput;
/**
* Duration for one production
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Heater")
float mDuration = 6.f;
};

View File

@@ -14,6 +14,12 @@ class REFINEDRDAPI_API URRDATurbineDataAsset : public URRDADataAssetBase
GENERATED_BODY()
public:
/**
* Fuel item that this heater uses
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Turbine", meta=( UIMin = "1", UIMax = "2" ))
int32 mTier = 1;
/**
* Fuel item that this heater uses
*/
@@ -26,4 +32,10 @@ public:
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Turbine")
FItemAmount mWasteItem;
/**
* Duration for one production
*/
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Turbine")
float mDuration = 6.f;
};