APawn::TakeDamage

Apply damage to this actor.

Windows
MacOS
Linux

Override Hierarchy

AActor::TakeDamage()

APawn::TakeDamage()

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Classes/GameFramework/Pawn.h

Include

#include "GameFramework/Pawn.h"

Source

/Engine/Source/Runtime/Engine/Private/Pawn.cpp

Syntax

virtual float TakeDamage
(
    float DamageAmount,
    struct FDamageEvent const & DamageEvent,
    AController * EventInstigator,
    AActor * DamageCauser
)

Remarks

Apply damage to this actor.

Returns

The amount of damage actually applied.

Parameters

Parameter

Description

DamageAmount

How much damage to apply

DamageEvent

Data package that fully describes the damage received.

EventInstigator

The Controller responsible for the damage.

DamageCauser

The Actor that directly caused the damage (e.g. the projectile that exploded, the rock that landed on you)

See Also

Select Skin
Light
Dark

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback