class
MHealthComponent
- Module
- Game
- Header
#include "Game/MHealthComponent.h"- Namespace
Mowo- Reflection
- Reflected by MowoHeaderTool
Properties
| Type | Name | Description |
|---|---|---|
float | maxHealth | Config: a project sets the default max health in DefaultGame.ini's [/Script/Mowo.HealthComponent] without a code change. Default 100.0f. |
bool | startInvulnerable | Default false. |
Constructors
| Signature | Name | Description |
|---|---|---|
MHealthComponent() = default | MHealthComponent |
Public functions
| Returns | Name | Description |
|---|---|---|
void | BeginPlay | |
float | ApplyDamage | Delegating gameplay API. |
float | Heal | |
void | Kill | |
void | Revive | |
bool | IsDead | |
float | GetHealth | |
float | GetHealthPercent | |
float | GetMaxHealth | |
void | SetInvulnerable | |
HealthComponent& | Health |
Function details
MHealthComponent
C++
MHealthComponent() = defaultBeginPlay
C++
void BeginPlay() overrideApplyDamage
C++
float ApplyDamage(float amount, MObject* instigator = nullptr)Delegating gameplay API.
Heal
C++
float Heal(float amount)Kill
C++
void Kill(MObject* instigator = nullptr)Revive
C++
void Revive(float health)IsDead
C++
bool IsDead() constGetHealth
C++
float GetHealth() constGetHealthPercent
C++
float GetHealthPercent() constGetMaxHealth
C++
float GetMaxHealth() constSetInvulnerable
C++
void SetInvulnerable(bool invulnerable)Health
C++
HealthComponent& Health()Generated from Game/MHealthComponent.h via game.json · Nov 5, 2026Version 1.0.0