diff --git a/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.cpp b/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.cpp index 55112bd..036547b 100644 --- a/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.cpp +++ b/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.cpp @@ -21,12 +21,19 @@ void UStatusEffect::OnExpiry(AActor* Character) StatusSystem->RemoveStatusEffect(this); } +void UStatusEffect::OnPlayerTurn(AActor* Character) +{ + return; +} + +void UStatusEffect::OnEnemyTurn(AActor* Character) +{ + return; +} + void UStatusEffect::CheckForExpiry(const float TimeOfExpiry, AActor* Character) { - if (TimeOfExpiry <= UGameplayStatics::GetRealTimeSeconds(GetWorld())) - { - OnExpiry(Character); - } + if (TimeOfExpiry <= UGameplayStatics::GetRealTimeSeconds(GetWorld())) OnExpiry(Character); UStatusSystem* StatusSystem = Cast(Character->GetComponentByClass(UStatusSystem::StaticClass())); if (StatusSystem->GetActiveStatusEffect(this).StatusIcon == nullptr) return; UTextBlock* StatusText = Cast(StatusSystem->GetActiveStatusEffect(this).StatusIcon->GetWidgetFromName(TEXT("DurationText"))); diff --git a/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.h b/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.h index 11edd65..317bc56 100644 --- a/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.h +++ b/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffect.h @@ -30,6 +30,12 @@ public: UFUNCTION() virtual void OnExpiry(AActor* Character); + UFUNCTION() + virtual void OnPlayerTurn(AActor* Character); + + UFUNCTION() + virtual void OnEnemyTurn(AActor* Character); + protected: UPROPERTY() FTimerHandle ExpiryTimerHandle;