AzureAbyss/Source/the_twilight_abyss/TurnBasedCombatV2/StatusEffects/DamageOverTime.cpp
Emily Taylor c4a668c2e9 Added Merchant Shop assets
Added Merchant shop FBX
2023-03-06 15:31:55 +00:00

18 lines
505 B
C++

// Fill out your copyright notice in the Description page of Project Settings.
#include "DamageOverTime.h"
#include <the_twilight_abyss/TurnBasedCombatV2/TurnBaseCombatV2.h>
void UDamageOverTime::OnEnemyTurn(AActor* Enemy, AActor* Character)
{
ATurnBaseCombatV2* CombatSystem = Cast<ATurnBaseCombatV2>(GetWorld()->GetGameState());
CombatSystem->DamageEnemy(DamagePerTurn, "DOT");
BaseDuration -= 1.0f;
Super::OnEnemyTurn(Enemy, Character);
if (BaseDuration <= 0.0f)
{
OnExpiry(Character);
}
}