#pragma once

#include "CoreMinimal.h"
#include "GameFramework/Actor.h"
#include "ChatHistory.h"
#include "ChatManager.generated.h"

class UDBDGameInstance;

UCLASS(Blueprintable)
class DEADBYDAYLIGHT_API AChatManager : public AActor
{
	GENERATED_BODY()

private:
	UPROPERTY(EditInstanceOnly, BlueprintReadWrite, Transient, meta=(AllowPrivateAccess=true))
	UDBDGameInstance* _gameInstance;

	UPROPERTY(EditAnywhere, BlueprintReadWrite, Replicated, meta=(AllowPrivateAccess=true))
	FChatHistory _chatHistory;

private:
	UFUNCTION(BlueprintCallable, NetMulticast, Reliable)
	void Multicast_DisplayMessage(const FString& chatIdentifier, int32 playerIndex, const FString& mirrorsId, const FString& msg);

public:
	virtual void GetLifetimeReplicatedProps(TArray<FLifetimeProperty>& OutLifetimeProps) const override;

public:
	AChatManager();
};

FORCEINLINE uint32 GetTypeHash(const AChatManager) { return 0; }
