// © 2025 Naked People Team. All Rights Reserved. #pragma once #include "CoreMinimal.h" #include "GameFramework/SaveGame.h" #include "NakedDesire/Global/Constants.h" #include "ItemSaveRecord.h" #include "GlobalSaveGameData.generated.h" class UClothingItemInstance; UCLASS() class NAKEDDESIRE_API UGlobalSaveGameData : public USaveGame { GENERATED_BODY() public: static UGlobalSaveGameData* CreateNewSaveGame(); static UGlobalSaveGameData* LoadGame(const FString& SlotName = DefaultSaveSlotName); static bool SaveGame(UGlobalSaveGameData* SaveGameData, const FString& SlotName = DefaultSaveSlotName); UPROPERTY(SaveGame) bool HaveSeenTutorial = false; UPROPERTY(SaveGame) float Money = 0; FItemSaveRecord AddWardrobeItem(const UClothingItemInstance* ItemInstance); bool UpdateWardrobeItem(UClothingItemInstance* ItemInstance); bool RemoveWardrobeItem(UClothingItemInstance* ItemInstance); TArray GetWardrobeItems() const { return WardrobeItems; } FItemSaveRecord AddEquippedItem(const UClothingItemInstance* ItemInstance); bool UpdateEquippedItem(UClothingItemInstance* ItemInstance); bool RemoveEquippedItem(UClothingItemInstance* ItemInstance); TArray GetEquippedItems() const { return EquippedItems; } FItemSaveRecord AddWorldItem(const UClothingItemInstance* ItemInstance, FTransform Transform); bool UpdateWorldItem(UClothingItemInstance* ItemInstance, FTransform Transform); bool RemoveWorldItem(UClothingItemInstance* ItemInstance); TArray GetWorldItems() const { return WorldItems; } UPROPERTY(SaveGame) int32 DaysPassed = 0; UPROPERTY(SaveGame) float HourOfDay = 0.0f; private: UPROPERTY(SaveGame) TArray WardrobeItems; UPROPERTY(SaveGame) TArray EquippedItems; UPROPERTY(SaveGame) TArray WorldItems; };