// Copyright ExByte Studios. Item Interaction Ecosystem. #pragma once #include "CoreMinimal.h" #include "GameFramework/Actor.h" #include "StorageContainerActor.generated.h" class UStaticMeshComponent; class UInteractableComponent; class UInventoryComponent; /** * A lootable world container (chest, crate, fridge, vehicle cargo, corpse) (section 5). * Its inventory is shared-replicated so any nearby player who opens it sees the * contents; transfers go through the validated server path (section 31.2). */ UCLASS() class ITEMWORLD_API AStorageContainerActor : public AActor { GENERATED_BODY() public: AStorageContainerActor(); UFUNCTION(BlueprintPure, Category = "Storage") UInventoryComponent* GetStorageInventory() const { return Storage; } protected: UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "Storage") TObjectPtr Mesh; UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "Storage") TObjectPtr Interactable; UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "Storage") TObjectPtr Storage; };