// Oleg Petruny proprietary.

#pragma once

#include "CoreMinimal.h"
#include "UObject/Object.h"

#include "WidgetsManager.generated.h"

enum class EActivatorType : uint8;

UCLASS(Blueprintable)
class UWidgetsManager : public UObject
{
    GENERATED_BODY()

public:
    void Init();

    void HideOverlayWidgets();
    void ShowOverlayWidgets();
    void UpdateOverlayWidgetsOwner();

    void ShowInteractionHints(const class UInteractableModificator* modificator);
    void HideInteractionHints(const EActivatorType type);

protected:
    UPROPERTY(EditDefaultsOnly)
    TArray<TSubclassOf<class UUserWidget>> permaOverlayWidgets; // never hidden
    TArray<TWeakObjectPtr<class UUserWidget>> permaOverlayWidgetsInstances;

    UPROPERTY(EditDefaultsOnly)
    TArray<TSubclassOf<class UUserWidget>> overlayWidgets; // hidden in pause
    TArray<TWeakObjectPtr<class UUserWidget>> overlayWidgetsInstances;

    UPROPERTY(EditDefaultsOnly)
    TSubclassOf<class UInteractableHintWidgetManager> interactableHintWidgetManagerClass;
    class UInteractableHintWidgetManager* interactableHintWidgetManager;
};
