39 lines
849 B
C++
39 lines
849 B
C++
// Fill out your copyright notice in the Description page of Project Settings.
|
|
|
|
#pragma once
|
|
|
|
#include "CoreMinimal.h"
|
|
#include "UObject/NoExportTypes.h"
|
|
#include "StatusEffect.generated.h"
|
|
|
|
/**
|
|
*
|
|
*/
|
|
UCLASS(Abstract, Blueprintable)
|
|
class THE_TWILIGHT_ABYSS_API UStatusEffect : public UObject
|
|
{
|
|
GENERATED_BODY()
|
|
|
|
public:
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
|
FString Name;
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
|
FString Description;
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
|
float BaseDuration;
|
|
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
|
UTexture2D* Icon;
|
|
|
|
UFUNCTION()
|
|
virtual void Invoke(AActor* Character, float TimeOfExpiry);
|
|
|
|
UFUNCTION()
|
|
virtual void OnExpiry(AActor* Character);
|
|
|
|
protected:
|
|
UPROPERTY()
|
|
FTimerHandle ExpiryTimerHandle;
|
|
UFUNCTION()
|
|
void CheckForExpiry(float TimeOfExpiry, AActor* Character);
|
|
};
|