Added wardrobe
This commit is contained in:
@@ -4,22 +4,45 @@
|
||||
|
||||
#include "CoreMinimal.h"
|
||||
#include "GameFramework/Actor.h"
|
||||
#include "NakedDesire/Interaction/Interactable.h"
|
||||
#include "Wardrobe.generated.h"
|
||||
|
||||
class UBoxComponent;
|
||||
class UWidgetComponent;
|
||||
class UClothingItemInstance;
|
||||
|
||||
// Apartment wardrobe fixture. The stored items live in UInventorySubsystem (the durable store is
|
||||
// UGlobalSaveGameData::WardrobeItems); this actor is just the interaction point and forwards to it.
|
||||
UCLASS(Blueprintable)
|
||||
class NAKEDDESIRE_API AWardrobe : public AActor
|
||||
class NAKEDDESIRE_API AWardrobe : public AActor, public IInteractable
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
|
||||
public:
|
||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Instanced)
|
||||
TArray<TObjectPtr<UClothingItemInstance>> ClothingItems;
|
||||
AWardrobe();
|
||||
|
||||
virtual void Interact_Implementation(ANakedDesireCharacter* Player) override;
|
||||
virtual bool CanInteract_Implementation(ANakedDesireCharacter* Player) const override;
|
||||
virtual FText GetInteractionPrompt_Implementation() const override;
|
||||
virtual void HideInteractionHint_Implementation() override;
|
||||
virtual void ShowInteractionFocusHint_Implementation() override;
|
||||
virtual void ShowInteractionProximityHint_Implementation() override;
|
||||
|
||||
void AddItem(UClothingItemInstance* ClothingItemInstance);
|
||||
void RemoveItem(UClothingItemInstance* ClothingItemInstance) const;
|
||||
void RemoveItem(UClothingItemInstance* ClothingItemInstance);
|
||||
|
||||
protected:
|
||||
virtual void BeginPlay() override;
|
||||
};
|
||||
|
||||
private:
|
||||
void ApplyOutline(bool bEnabled, int32 StencilValue);
|
||||
|
||||
UPROPERTY(EditDefaultsOnly)
|
||||
TObjectPtr<UStaticMeshComponent> MeshComponent;
|
||||
|
||||
UPROPERTY(EditDefaultsOnly)
|
||||
TObjectPtr<UBoxComponent> ColliderComponent;
|
||||
|
||||
UPROPERTY(EditDefaultsOnly)
|
||||
TObjectPtr<UWidgetComponent> InteractionHint;
|
||||
};
|
||||
Reference in New Issue
Block a user