// © 2025 Naked People Team. All Rights Reserved.

#pragma once

#include "CoreMinimal.h"
#include "StructUtils/InstancedStruct.h"
#include "ItemSaveRecord.generated.h"

class UItemDefinition;

/**
 * Type-agnostic save record for any UItemInstance.
 * Per-type mutable state lives in State as an FItemInstanceState subclass
 * (e.g. FClothingInstanceState), so new item types add no fields here.
 */
USTRUCT()
struct NAKEDDESIRE_API FItemSaveRecord
{
	GENERATED_BODY()

	UPROPERTY(SaveGame)
	FGuid InstanceId;

	UPROPERTY(SaveGame)
	TSoftObjectPtr<UItemDefinition> Definition;

	UPROPERTY(SaveGame)
	FInstancedStruct State;

	UPROPERTY(SaveGame)
	FGuid ParentId;

	UPROPERTY(SaveGame)
	FTransform WorldTransform;
};