2023-02-20 17:58:32 +00:00
|
|
|
// Fill out your copyright notice in the Description page of Project Settings.
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "CoreMinimal.h"
|
|
|
|
#include "StatusEffect.generated.h"
|
|
|
|
|
|
|
|
/**
|
|
|
|
*
|
|
|
|
*/
|
2023-02-23 03:50:26 +00:00
|
|
|
UCLASS(Abstract, Blueprintable)
|
2023-02-20 17:58:32 +00:00
|
|
|
class THE_TWILIGHT_ABYSS_API UStatusEffect : public UObject
|
|
|
|
{
|
|
|
|
GENERATED_BODY()
|
|
|
|
|
|
|
|
public:
|
2023-02-23 03:05:09 +00:00
|
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
2023-02-20 17:58:32 +00:00
|
|
|
FString Name;
|
2023-02-23 03:05:09 +00:00
|
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
2023-02-20 17:58:32 +00:00
|
|
|
FString Description;
|
2023-02-23 03:05:09 +00:00
|
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
2023-03-02 03:25:00 +00:00
|
|
|
bool IsForCombatOnly = false;
|
|
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
2023-02-23 03:05:09 +00:00
|
|
|
float BaseDuration;
|
|
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
|
|
|
UTexture2D* Icon;
|
2023-02-20 17:58:32 +00:00
|
|
|
|
|
|
|
UFUNCTION()
|
2023-02-25 01:25:32 +00:00
|
|
|
virtual void Invoke(AActor* Character, float TimeOfExpiry);
|
2023-02-23 03:05:09 +00:00
|
|
|
UFUNCTION()
|
|
|
|
virtual void OnExpiry(AActor* Character);
|
2023-02-25 01:25:32 +00:00
|
|
|
|
2023-02-27 17:32:34 +00:00
|
|
|
UFUNCTION()
|
2023-02-28 16:48:30 +00:00
|
|
|
virtual void OnPlayerTurn(AActor* Character, AActor* Enemy);
|
|
|
|
UFUNCTION()
|
|
|
|
virtual void OnEnemyTurn(AActor* Enemy, AActor* Character);
|
2023-02-27 17:32:34 +00:00
|
|
|
|
|
|
|
UFUNCTION()
|
2023-03-02 15:37:36 +00:00
|
|
|
virtual void OnStatusEffectAdd(AActor* Character);
|
|
|
|
|
|
|
|
UFUNCTION()
|
|
|
|
virtual void TickDown(AActor* Character);
|
2023-02-27 17:32:34 +00:00
|
|
|
|
2023-02-25 01:25:32 +00:00
|
|
|
protected:
|
|
|
|
UPROPERTY()
|
|
|
|
FTimerHandle ExpiryTimerHandle;
|
|
|
|
UFUNCTION()
|
|
|
|
void CheckForExpiry(float TimeOfExpiry, AActor* Character);
|
2023-03-02 03:25:00 +00:00
|
|
|
|
|
|
|
FDelegateHandle OnPlayerTurnDelegateHandle;
|
|
|
|
FDelegateHandle OnEnemyTurnDelegateHandle;
|
2023-02-20 17:58:32 +00:00
|
|
|
};
|