Files
Cody Larkin 20a1478bdc Added max health and current health to component
take damage function created.
need to decide how damage and health is managed
2025-11-29 16:38:42 -05:00

38 lines
846 B
C++

// Fill out your copyright notice in the Description page of Project Settings.
#include "DDIHealth.h"
// Sets default values for this component's properties
UDDIHealth::UDDIHealth()
{
// Set this component to be initialized when the game starts, and to be ticked every frame. You can turn these features
// off to improve performance if you don't need them.
PrimaryComponentTick.bCanEverTick = true;
MaxHealth = 100;
CurrentHealth = 100;
}
// Called when the game starts
void UDDIHealth::BeginPlay()
{
Super::BeginPlay();
// ...
}
// Called every frame
void UDDIHealth::TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction)
{
Super::TickComponent(DeltaTime, TickType, ThisTickFunction);
// ...
}
// Called to cause damage
void UDDIHealth::TakeDamage(UDamageType* DamageType)
{
}