Add resource node persistence

This commit is contained in:
2026-05-17 17:08:05 -07:00
parent 843340ebdc
commit 5da545e000
13 changed files with 276 additions and 4 deletions
+18
View File
@@ -46,6 +46,21 @@ struct FAgrarianSavedWorldActor
TMap<FName, float> NumberState;
};
USTRUCT(BlueprintType)
struct FAgrarianSavedResourceNode
{
GENERATED_BODY()
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Agrarian|Save")
FName ResourceNodeId = NAME_None;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Agrarian|Save")
int32 RemainingHarvests = 0;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Agrarian|Save")
bool bRespawnsForMvp = false;
};
UCLASS()
class UAgrarianSaveGame : public USaveGame
{
@@ -72,4 +87,7 @@ public:
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Agrarian|Save")
TArray<FAgrarianSavedWorldActor> WorldActors;
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Agrarian|Save")
TArray<FAgrarianSavedResourceNode> ResourceNodes;
};