AActor

Actor is the base class for an Object that can be placed or spawned in a level.

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

Engine

Header

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

Include

#include "GameFramework/Actor.h"

Syntax

class AActor : public UObject

Remarks

Actor is the base class for an Object that can be placed or spawned in a level. Actors may contain a collection of ActorComponents, which can be used to control how actors move, how they are rendered, etc. The other main function of an Actor is the replication of properties and function calls across the network during play.

Actor initialization has multiple steps, here's the order of important virtual functions that get called:

  • UObject::PostLoad: For actors statically placed in a level, the normal UObject PostLoad gets called both in the editor and during gameplay. This is not called for newly spawned actors.

  • UActorComponent::OnComponentCreated: When an actor is spawned in the editor or during gameplay, this gets called for any native components. For blueprint-created components, this gets called during construction for that component. This is not called for components loaded from a level.

  • AActor::PreRegisterAllComponents: For statically placed actors and spawned actors that have native root components, this gets called now. For blueprint actors without a native root component, these registration functions get called later during construction.

  • UActorComponent::RegisterComponent: All components are registered in editor and at runtime, this creates their physical/visual representation. These calls may be distributed over multiple frames, but are always after PreRegisterAllComponents. This may also get called later on after an UnregisterComponent call removes it from the world.

  • AActor::PostRegisterAllComponents: Called for all actors both in the editor and in gameplay, this is the last function that is called in all cases.

  • AActor::PostActorCreated: When an actor is created in the editor or during gameplay, this gets called right before construction. This is not called for components loaded from a level.

  • AActor::UserConstructionScript: Called for blueprints that implement a construction script.

  • AActor::OnConstruction: Called at the end of ExecuteConstruction, which calls the blueprint construction script. This is called after all blueprint-created components are fully created and registered. This is only called during gameplay for spawned actors, and may get rerun in the editor when changing blueprints.

  • AActor::PreInitializeComponents: Called before InitializeComponent is called on the actor's components. This is only called during gameplay and in certain editor preview windows.

  • UActorComponent::Activate: This will be called only if the component has bAutoActivate set. It will also got called later on if a component is manually activated.

  • UActorComponent::InitializeComponent: This will be called only if the component has bWantsInitializeComponentSet. This only happens once per gameplay session.

  • AActor::PostInitializeComponents: Called after the actor's components have been initialized, only during gameplay and some editor previews.

  • AActor::BeginPlay: Called when the level starts ticking, only during actual gameplay. This normally happens right after PostInitializeComponents but can be delayed for networked or child actors.

Variables

Name Description

Public variable

TEnumAsByte< EA...

 

AutoReceiveInput

Automatically registers this actor to receive input from a player.

Protected variable

uint8: 1

 

bActorLabelEditable

Is the actor label editable by the user?

Public variable

uint8: 1

 

bActorSeamlessTraveled

Indicates the actor was pulled through a seamless travel.

Protected variable

uint8: 1

 

bAllowReceiveTickEventOnDedicatedServer

If false, the Blueprint ReceiveTick() event will be disabled on dedicated servers.

Public variable

uint8: 1

 

bAllowTickBeforeBeginPlay

Whether we allow this Actor to tick before it receives the BeginPlay event.

Public variable

uint8: 1

 

bAlwaysRelevant

Always relevant for network (overrides bOnlyRelevantToOwner).

Public variable

uint8: 1

 

bBlockInput

If true, all input on the stack below this actor will not be considered

Protected variable

uint8: 1

 

bCanBeInCluster

If true, this actor can be put inside of a GC Cluster to improve Garbage Collection performance

Public variable

uint8: 1

 

bCollideWhenPlacing

This actor collides with the world when placing in the editor, even if RootComponent collision is disabled.

Protected variable

uint8: 1

 

bEditable

Whether the actor can be manipulated by editor operations.

Public variable

uint8: 1

 

bEnableAutoLODGeneration

If true, and if World setting has bEnableHierarchicalLOD equal to true, then it will generate LODActor from groups of clustered Actor

Public variable

uint8: 1

 

bExchangedRoles

Whether we have already exchanged Role/RemoteRole on the client, as when removing then re-adding a streaming level.

Public variable

uint8: 1

 

bFindCameraComponentWhenViewTarget

If true, this actor should search for an owned camera component to view through when used as a view target.

Public variable

uint8: 1

 

bGenerateOverlapEventsDuringLevelStreaming

If true, this actor will generate overlap Begin/End events when spawned as part of level streaming, which includes initial level load.

Public variable

uint8: 1

 

bHiddenEd

Whether this actor is hidden within the editor viewport.

Public variable

uint8: 1

 

bHiddenEdLayer

Whether this actor is hidden by the layer browser.

Public variable

uint8: 1

 

bHiddenEdLevel

Whether this actor is hidden by the level browser.

Public variable

uint8: 1

 

bIgnoresOriginShifting

Whether this actor should not be affected by world origin shifting.

Public variable

uint8: 1

 

bIsEditorOnlyActor

Whether this actor is editor-only.

Public variable

uint8: 1

 

bIsEditorPreviewActor

True if this actor is the preview actor dragged out of the content browser

Protected variable

uint8: 1

 

bListedInSceneOutliner

Whether this actor should be listed in the scene outliner.

Public variable

uint8: 1

 

bLockLocation

If true, prevents the actor from being moved in the editor viewport.

Public variable

TArray< UActorC...

 

BlueprintCreatedComponents

Array of ActorComponents that are created by blueprints and serialized per-instance.

Protected variable

uint8: 1

 

bNetCheckedInitialPhysicsState

Flag indicating we have checked initial simulating physics state to sync networked proxies to the server.

Public variable

uint8: 1

 

bNetLoadOnClient

This actor will be loaded on network clients during map load

Public variable

uint8: 1

 

bNetStartup

If true, this actor was loaded directly from the map, and for networking purposes can be addressed by its full path name

Public variable

uint8: 1

 

bNetTemporary

If true, when the actor is spawned it will be sent to the client but receive no further replication updates from the server afterwards.

Public variable

uint8: 1

 

bNetUseOwnerRelevancy

If actor has valid Owner, call Owner's IsNetRelevantFor and GetNetPriority

Public variable

uint8: 1

 

bOnlyRelevantToOwner

If true, this actor is only relevant to its owner.

Protected variable

uint8: 1

 

bOptimizeBPComponentData

Whether to cook additional data to speed up spawn events at runtime for any Blueprint classes based on this Actor.

Public variable

uint8: 1

 

bRelevantForLevelBounds

If true, this actor's component's bounds will be included in the level's bounding box unless the Actor's class has overridden IsLevelBoundsRelevant

Public variable

uint8: 1

 

bRelevantForNetworkReplays

If true, this actor will be replicated to network replays (default is true)

Public variable

uint8: 1

 

bReplayRewindable

If true, this actor will only be destroyed during scrubbing if the replay is set to a time before the actor existed.

Protected variable

uint8: 1

 

bReplicates

If true, this actor will replicate to remote machines

Public variable

uint8: 1

 

bRunConstructionScriptOnDrag

If true during PostEditMove the construction script will be run every time.

Public variable

TArray< AActor ...

 

Children

Array of all Actors whose Owner is this actor, these are not necessarily spawned by UChildActorComponent

Protected variable

TArray< class A...

 

ControllingMatineeActors

The matinee actors that control this actor.

Public variable

float

 

CreationTime

The time this actor was created, relative to World->GetTimeSeconds().

Public variable

TSharedPtr< FAc...

 

CurrentTransactionAnnotation

Cached pointer to the transaction annotation data from PostEditUndo to be used in the next RerunConstructionScript

Public variable

float

 

CustomTimeDilation

Allow each actor to run at a different time speed.

Public variable

FRenderCommandF...

 

DetachFence

A fence to track when the primitive is detached from the scene in the rendering thread.

Public variable

AActor *

 

GroupActor

The editor-only group this actor is a part of.

Public variable

uint64

 

HiddenEditorViews

Bitflag to represent which views this actor is hidden in, via per-view layer visibility.

Public variable

float

 

InitialLifeSpan

How long this Actor lives before dying, 0=forever.

Public variable

UInputComponent...

 

InputComponent

Component that handles input for this actor, if input is enabled.

Public variable

int32

 

InputPriority

The priority of this input component when pushed in to the stack.

Public variable

TArray< FName >

 

Layers

Layers the actor belongs to.

Public variable

float

 

MinNetUpdateFrequency

Used to determine what rate to throttle down to when replicated properties are changing infrequently

Public variable

float

 

NetCullDistanceSquared

Square of the max distance from the client's viewpoint that this actor is relevant and will be replicated.

Public variable

TEnumAsByte< en...

 

NetDormancy

Dormancy setting for actor to take itself off of the replication list without being destroyed on clients.

Protected variable

FName

 

NetDriverName

Used to specify the net driver to replicate on (NAME_None || NAME_GameNetDriver is the default net driver)

Public variable

float

 

NetPriority

Priority for this actor when checking for replication in a low bandwidth or saturated situation, higher priority means it is more likely to replicate

Public variable

int32

 

NetTag

Internal - used by UNetDriver

Public variable

float

 

NetUpdateFrequency

How often (per second) this actor will be considered for replication, used to determine NetUpdateTime

Public variable

FActorBeginOver...

 

OnActorBeginOverlap

Called when another actor begins to overlap this actor, for example a player walking into a trigger.

Public variable

FActorEndOverla...

 

OnActorEndOverlap

Called when another actor stops overlapping this actor.

Public variable

FActorHitSignat...

 

OnActorHit

Called when this Actor hits (or is hit by) something solid.

Public variable

FActorBeginCurs...

 

OnBeginCursorOver

Called when the mouse cursor is moved over this actor if mouse over events are enabled in the player controller.

Public variable

FActorOnClicked...

 

OnClicked

Called when the left mouse button is clicked while the mouse is over this actor and click events are enabled in the player controller.

Public variable

FActorDestroyed...

 

OnDestroyed

Event triggered when the actor has been explicitly destroyed.

Public variable

FActorEndCursor...

 

OnEndCursorOver

Called when the mouse cursor is moved off this actor if mouse over events are enabled in the player controller.

Public variable

FActorEndPlaySi...

 

OnEndPlay

Event triggered when the actor is being deleted or removed from a level.

Public variable

FActorOnInputTo...

 

OnInputTouchBegin

Called when a touch input is received over this actor when touch events are enabled in the player controller.

Public variable

FActorOnInputTo...

 

OnInputTouchEnd

Called when a touch input is received over this component when touch events are enabled in the player controller.

Public variable

FActorBeginTouc...

 

OnInputTouchEnter

Called when a finger is moved over this actor when touch over events are enabled in the player controller.

Public variable

FActorEndTouchO...

 

OnInputTouchLeave

Called when a finger is moved off this actor when touch over events are enabled in the player controller.

Public variable

FActorOnRelease...

 

OnReleased

Called when the left mouse button is released while the mouse is over this actor and click events are enabled in the player controller.

Public variable

FTakeAnyDamageS...

 

OnTakeAnyDamage

Called when the actor is damaged in any way.

Public variable

FTakePointDamag...

 

OnTakePointDamage

Called when the actor is damaged by point damage.

Public variable

FTakeRadialDama...

 

OnTakeRadialDamage

Called when the actor is damaged by radial damage.

Protected variable

FVector

 

PivotOffset

Local space pivot offset for the actor, only used in the editor

Public variable

FActorTickFunct...

 

PrimaryActorTick

Primary Actor tick function, which calls TickActor().

Protected variable

TArray< UActorC...

 

ReplicatedComponents

Set of replicated components, stored as an array to save space as this is generally not very large

Protected variable

USceneComponent...

 

RootComponent

The component that defines the transform (location, rotation, scale) of this Actor in the world, all other components must be attached to this one somehow

Public variable

ESpawnActorColl...

 

SpawnCollisionHandlingMethod

Controls how to handle spawning this actor in a situation where it's colliding with something else.

Public variable

float

 

SpriteScale

The scale to apply to any billboard components in editor builds (happens in any WITH_EDITOR build, including non-cooked games).

Public variable

TArray< FName >

 

Tags

Array of tags that can be used for grouping and categorizing.

Protected variable

FTimerHandle

 

TimerHandle_LifeSpanExpired

Handle for efficient management of LifeSpanExpired timer

Protected variable

EActorUpdateOve...

 

UpdateOverlapsMethodDuringLevelStreaming

Condition for calling UpdateOverlaps() to initialize overlap state when loaded in during level streaming.

Constructors

Name Description

Public function

AActor()

Default constructor for AActor

Public function

AActor

(
    const FObjectInitializer& ObjectIn...
)

Constructor for AActor that takes an ObjectInitializer for backward compatibility

Functions

Name Description

Public function Const

float

 

ActorGetDistanceToCollision

(
    const FVector& Point,
    ECollisionChannel TraceChannel,
    FVector& ClosestPointOnCollision,
    UPrimitiveComponent** OutP...
)

Returns Distance to closest Body Instance surface.

Public function Const

bool

 

ActorHasTag

(
    FName Tag
)

See if this actor's Tags array contains the supplied name tag

Public function Const

bool

 

ActorLineTraceSingle

(
    FHitResult& OutHit,
    const FVector& Start,
    const FVector& End,
    ECollisionChannel TraceChannel,
    const FCollisionQueryParams& Param...
)

Trace a ray against the Components of this Actor and return the first blocking hit

Public function Const

const FTrans...

 

ActorToWorld()

Get the local-to-world transform of the RootComponent.

Public function

void

 

AddActorLocalOffset

(
    FVector DeltaLocation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the location of this component in its local reference frame.

Public function

void

 

AddActorLocalRotation

(
    const FQuat& DeltaRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the rotation of this component in its local reference frame

Public function

void

 

AddActorLocalRotation

(
    FRotator DeltaRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the rotation of this component in its local reference frame

Public function

void

 

AddActorLocalTransform

(
    const FTransform& NewTransform,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the transform of this component in its local reference frame

Public function

void

 

AddActorWorldOffset

(
    FVector DeltaLocation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the location of this actor in world space.

Public function

void

 

AddActorWorldRotation

(
    FRotator DeltaRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the rotation of this actor in world space.

Public function

void

 

AddActorWorldRotation

(
    const FQuat& DeltaRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the rotation of this actor in world space.

Public function

void

 

AddActorWorldTransform

(
    const FTransform& DeltaTransform,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Adds a delta to the transform of this actor in world space. Scale is unchanged.

Public function

UActorCompon...

 

AddComponent

(
    FName TemplateName,
    bool bManualAttachment,
    const FTransform& RelativeTransfor...,
    const UObject* ComponentTempla...
)

Creates a new component and assigns ownership to the Actor this is called for.

Public function

void

 

AddControllingMatineeActor

(
    AMatineeActor& InMatineeActor
)

Adds a controlling matinee actor for use during matinee playback

Public function

void

 

AddInstanceComponent

(
    UActorComponent* Component
)

Adds a component to the instance components array

Public function

void

 

AddOwnedComponent

(
    UActorComponent* Component
)

Puts a component in to the OwnedComponents array of the Actor.

Public function Static

void

 

AddReferencedObjects

(
    UObject* InThis,
    FReferenceCollector& Collector
)

Public function Virtual

void

 

AddTickPrerequisiteActor

(
    AActor* PrerequisiteActor
)

Make this actor tick after PrerequisiteActor.

Public function Virtual

void

 

AddTickPrerequisiteComponent

(
    UActorComponent* PrerequisiteC...
)

Make this actor tick after PrerequisiteComponent.

Public function Const

bool

 

AllowReceiveTickEventOnDedicatedServer()

Return the value of bAllowReceiveTickEventOnDedicatedServer, indicating whether the Blueprint ReceiveTick() event will occur on dedicated servers.

Public function Virtual

void

 

ApplyWorldOffset

(
    const FVector& InOffset,
    bool bWorldShift
)

Called by owning level to shift an actor location and all relevant data structures by specified delta

Public function

void

 

AttachToActor

(
    AActor* ParentActor,
    const FAttachmentTransformRules& A...,
    FName SocketName
)

Attaches the RootComponent of this Actor to the RootComponent of the supplied actor, optionally at a named socket.

Public function

void

 

AttachToComponent

(
    USceneComponent* Parent,
    const FAttachmentTransformRules& A...,
    FName SocketName
)

Attaches the RootComponent of this Actor to the supplied component, optionally at a named socket.

Public function Virtual

void

 

BecomeViewTarget

(
    APlayerController* PC
)

Called when this actor becomes the given PlayerController's ViewTarget.

Protected function Virtual

void

 

BeginPlay()

Overridable native event for when play begins for this actor.

Public function Virtual

void

 

CalcCamera

(
    float DeltaTime,
    FMinimalViewInfo& OutResult
)

Calculate camera view point, when viewing this actor.

Public function Virtual Const

FBox

 

CalculateComponentsBoundingBoxInLocalSpace

(
    bool bNonColliding,
    bool bIncludeFromChildActors
)

Calculates the actor space bounding box of all components in this Actor.

Public function

void

 

CallPreReplication

(
    UNetDriver* NetDriver
)

Called by the networking system to call PreReplication on this actor and its components using the given NetDriver to find or create RepChangedPropertyTrackers.

Public function Virtual Const

bool

 

CanBeBaseForCharacter

(
    APawn* Pawn
)

Return true if the given Pawn can be "based" on this actor (ie walk on it).

Public function Const

bool

 

CanBeDamaged()

Gets the literal value of bCanBeDamaged.

Public function Virtual Const

bool

 

CanDeleteSelectedActor

(
    FText& OutReason
)

When selected can this actor be deleted?

Public function Const

bool

 

CanEverTick()

Accessor for the value of bCanEverTick

Protected function Const

bool

 

CheckActorComponents()

Checks components for validity, implemented in AActor

Public function

void

 

CheckComponentInstanceName

(
    const FName InName
)

Checks for and resolve any name conflicts prior to instancing a new Blueprint Component.

Public function Virtual

void

 

CheckForDeprecated()

Function that gets called from within Map_Check to allow this actor to check itself for any potential errors and register them with map check dialog.

Public function Virtual

void

 

CheckForErrors()

Function that gets called from within Map_Check to allow this actor to check itself for any potential errors and register them with map check dialog.

Public function Virtual

bool

 

CheckStillInWorld()

This will check to see if the Actor is still in the world.

Public function

void

 

ClearActorLabel()

Advanced - clear the actor label.

Public function

void

 

ClearComponentOverlaps()

Dispatch all EndOverlap for all of the Actor's PrimitiveComponents.

Public function Virtual

void

 

ClearCrossLevelReferences()

Do anything needed to clear out cross level references; Called from ULevel::PreSave

Public function

void

 

ClearInstanceComponents

(
    bool bDestroyComponents
)

Clears the instance components array

Public function

void

 

CopyRemoteRoleFrom

(
    const AActor* CopyFromActor
)

Copies RemoteRole from another Actor and adds this actor to the list of network actors if necessary.

Public function

UActorCompon...

 

CreateComponentFromTemplate

(
    UActorComponent* Template,
    const FName InName
)

Util to create a component based on a template

Public function

UActorCompon...

 

CreateComponentFromTemplateData

(
    const FBlueprintCookedComponentInst...,
    const FName InName
)

Util to create a component based on a template

Public function

void

 

DebugShowComponentHierarchy

(
    const TCHAR* Info,
    bool bShowPosition
)

Debug helper to show the component hierarchy of this actor.

Public function

void

 

DebugShowOneComponentHierarchy

(
    USceneComponent* SceneComp,
    int32& NestLevel,
    bool bShowPosition
)

Debug helper for showing the component hierarchy of one component

Public function

bool

 

Destroy

(
    bool bNetForce,
    bool bShouldModifyLevel
)

Destroy this actor.

Public function

void

 

DestroyConstructedComponents()

Destroys the constructed components.

Public function Virtual

void

 

Destroyed()

Called when this actor is explicitly being destroyed during gameplay or in the editor, not called during level streaming or gameplay ending

Public function Virtual

bool

 

DestroyNetworkActorHandled()

Called by DestroyActor(), gives actors a chance to op out of actor destruction Used by network code to have the net connection timeout/cleanup first

Public function

void

 

DetachAllSceneComponents

(
    USceneComponent* InParentCompo...,
    const FDetachmentTransformRules& D...
)

Detaches all SceneComponents in this Actor from the supplied parent SceneComponent.

Public function

void

 

DetachFromActor

(
    const FDetachmentTransformRules& D...
)

Detaches the RootComponent of this Actor from any SceneComponent it is currently attached to.

Public function

void

 

DisableComponentsSimulatePhysics()

Stop all simulation from all components in this actor

Public function Virtual

void

 

DisableInput

(
    APlayerController* PlayerContr...
)

Removes this actor from the stack of input being handled by a PlayerController.

Public function

void

 

DispatchBeginPlay

(
    bool bFromLevelStreaming
)

Initiate a begin play call on this Actor, will handle calling in the correct order.

Public function

void

 

DispatchBlockingHit

(
    UPrimitiveComponent* MyComp,
    UPrimitiveComponent* OtherComp,
    bool bSelfMoved,
    FHitResult const& Hit
)

Call ReceiveHit, as well as delegates on Actor and Component

Public function Virtual

void

 

DispatchPhysicsCollisionHit

(
    const FRigidBodyCollisionInfo& MyI...,
    const FRigidBodyCollisionInfo& Oth...,
    const FCollisionImpactData& RigidC...
)

Dispatches ReceiveHit virtual and OnComponentHit delegate

Public function Virtual

void

 

DisplayDebug

(
    UCanvas* Canvas,
    const FDebugDisplayInfo& DebugDisp...,
    float& YL,
    float& YPos
)

Draw important Actor variables on canvas.

Public function Const

void

 

DrawDebugComponents

(
    FColor const& BaseColor
)

Debug rendering to visualize the component tree for this actor.

Public function Virtual

void

 

EditorApplyMirror

(
    const FVector& MirrorScale,
    const FVector& PivotLocation
)

Called by MirrorActors to perform a mirroring operation on the actor

Public function Virtual

void

 

EditorApplyRotation

(
    const FRotator& DeltaRotation,
    bool bAltDown,
    bool bShiftDown,
    bool bCtrlDown
)

Called by ApplyDeltaToActor to perform an actor class-specific operation based on widget manipulation.

Public function Virtual

void

 

EditorApplyScale

(
    const FVector& DeltaScale,
    const FVector* PivotLocation,
    bool bAltDown,
    bool bShiftDown,
    bool bCtrlDown
)

Called by ApplyDeltaToActor to perform an actor class-specific operation based on widget manipulation.

Public function Virtual

void

 

EditorApplyTranslation

(
    const FVector& DeltaTranslation,
    bool bAltDown,
    bool bShiftDown,
    bool bCtrlDown
)

Called by ApplyDeltaToActor to perform an actor class-specific operation based on widget manipulation.

Public function Virtual Const

bool

 

EditorCanAttachTo

(
    const AActor* InParent,
    FText& OutReason
)

Returns true if this actor is allowed to be attached to the given actor

Public function Virtual

void

 

EditorKeyPressed

(
    FKey Key,
    EInputEvent Event
)

Called by InputKey when an unhandled key is pressed with a selected actor

Public function Virtual

void

 

EditorReplacedActor

(
    AActor* OldActor
)

Called by ReplaceSelectedActors to allow a new actor to copy properties from an old actor when it is replaced

Public function Virtual

void

 

EnableInput

(
    APlayerController* PlayerContr...
)

Pushes this actor on to the stack of input being handled by a PlayerController.

Protected function Virtual

void

 

EndPlay

(
    const EEndPlayReason::Type EndPlayR...
)

Overridable function called whenever this actor is being removed from a level

Public function Virtual

void

 

EndViewTarget

(
    APlayerController* PC
)

Called when this actor is no longer the given PlayerController's ViewTarget.

Public function

void

 

ExchangeNetRoles

(
    bool bRemoteOwner
)

Swaps Role and RemoteRole if client

Public function

bool

 

ExecuteConstruction

(
    const FTransform& Transform,
    const FRotationConversionCache*...,
    const FComponentInstanceDataCache&...,
    bool bIsDefaultTransform
)

Run any construction script for this Actor. Will call OnConstruction.

Public function Virtual

void

 

FellOutOfWorld

(
    const UDamageType& dmgType
)

Called when the actor falls out of the world 'safely' (below KillZ and such)

Public function Virtual Const

UActorCompon...

 

FindComponentByClass

(
    const TSubclassOf< UActorComponent ...
)

Searches components array and returns first encountered component of the specified class, native version of GetComponentByClass

Public function Const

T *

 

FindComponentByClass()

Templatized version of FindComponentByClass that handles casting for you

Public function Const

const FNetwo...

 

FindNetworkObjectInfo()

Find the FNetworkObjectInfo struct associated with this actor (for the main NetDriver).

Public function

FNetworkObje...

 

FindNetworkObjectInfo()

Find the FNetworkObjectInfo struct associated with this actor (for the main NetDriver).

Public function

FNetworkObje...

 

FindOrAddNetworkObjectInfo()

Find the FNetworkObjectInfo struct associated with this actor (for the main NetDriver).

Public function

void

 

FinishAndRegisterComponent

(
    UActorComponent* Component
)

Helper function to register the specified component, and add it to the serialized components array

Public function

void

 

FinishSpawning

(
    const FTransform& Transform,
    bool bIsDefaultTransform,
    const FComponentInstanceDataCache&...
)

Called to finish the spawning process, generally in the case of deferred spawning

Public function

void

 

FlushNetDormancy()

Forces dormant actor to replicate but doesn't change NetDormancy state (i.e., they will go dormant again if left dormant)

Public function Virtual

void

 

ForceNetRelevant()

Forces this actor to be net relevant if it is not already by default

Public function Virtual

void

 

ForceNetUpdate()

Force actor to be updated to clients/demo net drivers

Public function

void

 

ForcePropertyCompare()

Forces properties on this actor to do a compare for one frame (rather than share shadow state)

Public function Const

void

 

ForEachAttachedActors

(
    TFunctionRef< bool...
)

Call a functor for Actors which are attached directly to a component in this actor.

Public function Const

void

 

ForEachComponent

(
    bool bIncludeFromChildActors,
    Func InFunc
)

Calls the compile-time lambda on each component of the specified type

Public function Const

void

 

ForEachComponent

(
    bool bIncludeFromChildActors,
    Func InFunc
)

Calls the compile-time lambda on each valid component

Public function Virtual

void

 

GatherCurrentMovement()

Fills ReplicatedMovement property

Public function Const

void

 

GetActorBounds

(
    bool bOnlyCollidingComponents,
    FVector& Origin,
    FVector& BoxExtent,
    bool bIncludeFromChildActors
)

Returns the bounding box of all components that make up this Actor (excluding ChildActorComponents).

Public function Const

bool

 

GetActorEnableCollision()

Get current state of collision for the whole actor

Public function Virtual Const

void

 

GetActorEyesViewPoint

(
    FVector& OutLocation,
    FRotator& OutRotation
)

Returns the point of view of the actor.

Public function Const

FVector

 

GetActorForwardVector()

Get the forward (X) vector (length 1.0) from this Actor, in world space.

Public function Const

const FStrin...

 

GetActorLabel()

Returns this actor's current label. Actor labels are only available in development builds.

Public function Const

FVector

 

GetActorLocation()

Returns the location of the RootComponent of this Actor

Public function Const

FQuat

 

GetActorQuat()

Returns the quaternion of the RootComponent of this Actor

Public function Const

FVector

 

GetActorRelativeScale3D()

Return the actor's relative scale 3d

Public function Const

FVector

 

GetActorRightVector()

Get the right (Y) vector (length 1.0) from this Actor, in world space.

Public function Const

FRotator

 

GetActorRotation()

Returns the rotation of the RootComponent of this Actor

Public function Const

FVector

 

GetActorScale()

Returns the scale of the RootComponent of this Actor

Public function Const

FVector

 

GetActorScale3D()

Returns the Actor's world-space scale.

Public function Const

float

 

GetActorTickInterval()

Returns the tick interval of this actor's primary tick function

Public function Const

float

 

GetActorTimeDilation()

Get ActorTimeDilation - this can be used for input control or speed control for slomo.

Public function Const

float

 

GetActorTimeDilation

(
    const UWorld& ActorWorld
)

More efficient version that takes the Actor's current world.

Public function Const

const FTrans...

 

GetActorTransform()

Returns the transform of the RootComponent of this Actor

Public function Const

FVector

 

GetActorUpVector()

Get the up (Z) vector (length 1.0) from this Actor, in world space.

Public function Const

void

 

GetAllChildActors

(
    TArray< AActor* >& ChildActor...,
    bool bIncludeDescendants
)

Returns a list of all actors spawned by our Child Actor Components, including children of children.

Public function Const

void

 

GetAttachedActors

(
    TArray< AActor* >& OutActors,
    bool bResetArray
)

Find all Actors which are attached directly to a component in this actor

Public function Const

const FRepAt...

 

GetAttachmentReplication()

Get read-only access to current AttachmentReplication.

Public function Const

AActor *

 

GetAttachParentActor()

Walk up the attachment chain from RootComponent until we encounter a different actor, and return it.

Public function Const

FName

 

GetAttachParentSocketName()

Walk up the attachment chain from RootComponent until we encounter a different actor, and return the socket name in the component.

Public function Const

bool

 

GetAutoDestroyWhenFinished()

Public function Static

const FName

 

GetCanBeDamagedPropertyName()

Gets the property name for bCanBeDamaged.

Public function Const

UActorCompon...

 

GetComponentByClass

(
    TSubclassOf< UActorComponent > Comp...
)

Searches components array and returns first encountered component of the specified class

Public function Const

void

 

GetComponents

(
    TSubclassOf< UActorComponent > Comp...,
    TArray< UActorComponent*, Allo...,
    bool bIncludeFromChildActors
)

Get all components derived from specified ComponentClass and fill in the OutComponents array with the result.

Public function Const

void

 

GetComponents

(
    TArray< UActorComponent*, Allo...,
    bool bIncludeFromChildActors
)

UActorComponent specialization of GetComponents() to avoid unnecessary casts.

Public function Const

void

 

GetComponents

(
    TArray< T*, AllocatorType >& ...,
    bool bIncludeFromChildActors
)

Get all components derived from class 'T' and fill in the OutComponents array with the result.

Public function Const

const TSet< ...

 

GetComponents()

Get a direct reference to the Components set rather than a copy with the null pointers removed.

Public function Virtual Const

FBox

 

GetComponentsBoundingBox

(
    bool bNonColliding,
    bool bIncludeFromChildActors
)

Returns the world space bounding box of all components in this Actor.

Public function Virtual Const

void

 

GetComponentsBoundingCylinder

(
    float& CollisionRadius,
    float& CollisionHalfHeight,
    bool bNonColliding,
    bool bIncludeFromChildActors
)

Get half-height/radius of a big axis-aligned cylinder around this actors registered colliding components, or all registered components if bNonColliding is false.

Public function Const

TArray< UAct...

 

GetComponentsByInterface

(
    TSubclassOf< UInterface > Interface
)

Gets all the components that implements the given interface.

Public function Const

TArray< UAct...

 

GetComponentsByTag

(
    TSubclassOf< UActorComponent > Comp...,
    FName Tag
)

Gets all the components that inherit from the given class with a given tag.

Public function Virtual Const

ECollisionRe...

 

GetComponentsCollisionResponseToChannel

(
    ECollisionChannel Channel
)

Get Collision Response to the passed in Channel for all components It returns Max of state - i.e. if Component A overlaps, but if Component B blocks, it will return block as response if Component A ignores, but if Component B overlaps, it will return overlap

Public function Virtual Const

FName

 

GetCustomIconName()

Returns a custom brush icon name to use in place of the automatic class icon where actors are represented via 2d icons in the editor (e.g scene outliner and menus)

Public function Static

FString

 

GetDebugName

(
    const AActor* Actor
)

Retrieves actor's name used for logging, or string "NULL" if Actor is null

Public function Virtual Const

USceneCompon...

 

GetDefaultAttachComponent()

Returns this actor's default attachment component for attaching children to

Public function Const

float

 

GetDistanceTo

(
    const AActor* OtherActor
)

Returns the distance from this Actor to OtherActor.

Public function Const

float

 

GetDotProductTo

(
    const AActor* OtherActor
)

Returns the dot product from this Actor to OtherActor.

Public function Const

const FName ...

 

GetFolderPath()

Returns this actor's folder path. Actor folder paths are only available in development builds.

Public function Const

UGameInstanc...

 

GetGameInstance()

Gets the GameInstance that ultimately contains this actor.

Public function Const

T *

 

GetGameInstance()

Gets the GameInstance that ultimately contains this actor cast to the template type.

Public function Const

float

 

GetGameTimeSinceCreation()

The number of seconds (in game time) since this Actor was created, relative to Get Game Time In Seconds.

Public function Static

const FName

 

GetHiddenPropertyName()

Gets the property name for bHidden.

Public function Const

float

 

GetHorizontalDistanceTo

(
    const AActor* OtherActor
)

Returns the distance from this Actor to OtherActor, ignoring Z.

Public function Const

float

 

GetHorizontalDotProductTo

(
    const AActor* OtherActor
)

Returns the dot product from this Actor to OtherActor, ignoring Z.

Public function Virtual Const

FString

 

GetHumanReadableName()

Returns the human readable string representation of an object.

Public function Const

float

 

GetInputAxisKeyValue

(
    const FKey InputAxisKey
)

Gets the value of the input axis key if input is enabled for this actor.

Public function Const

float

 

GetInputAxisValue

(
    const FName InputAxisName
)

Gets the value of the input axis if input is enabled for this actor.

Public function Const

FVector

 

GetInputVectorAxisValue

(
    const FKey InputAxisKey
)

Gets the value of the input axis key if input is enabled for this actor.

Public function Const

const TArray...

 

GetInstanceComponents()

Returns the instance components array

Public function Const

APawn *

 

GetInstigator()

Returns the instigator for this actor, or nullptr if there is none.

Public function Const

T *

 

GetInstigator()

Get the instigator, cast as a specific class.

Public function Const

AController ...

 

GetInstigatorController()

Returns the instigator's controller for this actor, or nullptr if there is none.

Public function Const

T *

 

GetInstigatorController()

Returns the instigator's controller, cast as a specific class.

Public function Static

const FName

 

GetInstigatorPropertyName()

Gets the property name for Instigator.

Public function Const

bool

 

GetIsReplicated()

Returns whether replication is enabled or not.

Public function Virtual Const

float

 

GetLastRenderTime()

Returns the most recent time any of this actor's components were rendered

Public function Const

ULevel *

 

GetLevel()

Return the ULevel that this Actor is part of.

Public function Virtual Const

float

 

GetLifeSpan()

Get the remaining lifespan of this actor. If zero is returned the actor lives forever.

Public function Const

ENetRole

 

GetLocalRole()

Returns how much control the local machine has over this actor.

Public function Virtual Const

UNetConnecti...

 

GetNetConnection()

Get the owning connection used for communicating between client/server

Public function Virtual

bool

 

GetNetDormancy

(
    const FVector& ViewPos,
    const FVector& ViewDir,
    AActor* Viewer,
    AActor* ViewTarget,
    UActorChannel* InChannel,
    float Time,
    bool bLowBandwidth
)

Returns true if the actor should be dormant for a specific net connection.

Public function Const

UNetDriver &...

 

GetNetDriver()

Returns the net driver that this actor is bound to, may be null

Public function Const

FName

 

GetNetDriverName()

Returns name of the net driver associated with this actor (all RPCs will go out via this connection)

Public function Const

ENetMode

 

GetNetMode()

Get the network mode (dedicated server, client, standalone, etc) for this actor.

Public function Virtual Const

const AActor...

 

GetNetOwner()

Return the actor responsible for replication, if any. Typically the player controller

Public function Virtual

UPlayer *...

 

GetNetOwningPlayer()

Return the owning UPlayer (if any) of this actor.

Public function Virtual

float

 

GetNetPriority

(
    const FVector& ViewPos,
    const FVector& ViewDir,
    AActor* Viewer,
    AActor* ViewTarget,
    UActorChannel* InChannel,
    float Time,
    bool bLowBandwidth
)

Function used to prioritize actors when deciding which to replicate

Public function Const

const int32

 

GetNumUncachedStaticLightingInteractions()

Returns NumUncachedStaticLightingInteractions for this actor

Public function Const

void

 

GetOverlappingActors

(
    TArray< AActor* >& Overlappin...,
    TSubclassOf< AActor > ClassFilter
)

Returns list of actors this actor is overlapping (any component overlapping any component).

Public function Const

void

 

GetOverlappingActors

(
    TSet< AActor* >& OverlappingA...,
    TSubclassOf< AActor > ClassFilter
)

Returns set of actors this actor is overlapping (any component overlapping any component).

Public function Const

void

 

GetOverlappingComponents

(
    TSet< UPrimitiveComponent* >&...
)

Returns set of components this actor is overlapping.

Public function Const

void

 

GetOverlappingComponents

(
    TArray< UPrimitiveComponent* >...
)

Returns list of components this actor is overlapping.

Public function Const

AActor *

 

GetOwner()

Get the owner of this Actor, used primarily for network replication.

Public function Const

AActor *

 

GetParentActor()

If this Actor was created by a Child Actor Component returns the Actor that owns that Child Actor Component

Public function Const

UChildActorC...

 

GetParentComponent()

If this Actor was created by a Child Actor Component returns that Child Actor Component

Public function Const

FVector

 

GetPivotOffset()

Gets the local space offset added to the actor's pivot as used by the editor

Public function Const

FVector

 

GetPlacementExtent()

Get the extent used when placing this actor in the editor, used for 'pulling back' hit.

Public function Virtual Const

bool

 

GetReferencedContentObjects

(
    TArray< UObject* >& Objects
)

Used by the "Sync to Content Browser" right-click menu option in the editor.

Public function Const

ENetRole

 

GetRemoteRole()

Returns how much control the remote machine has over this actor.

Public function Virtual

float

 

GetReplayPriority

(
    const FVector& ViewPos,
    const FVector& ViewDir,
    AActor* Viewer,
    AActor* ViewTarget,
    UActorChannel*const InChannel,
    float Time
)

Similar to GetNetPriority, but will only be used for prioritizing actors while recording a replay.

Public function Const

const TArray...

 

GetReplicatedComponents()

Returns a constant reference to the replicated components set

Public function Const

const FRepMo...

 

GetReplicatedMovement()

Gets the literal value of ReplicatedMovement.

Public function

FRepMovement...

 

GetReplicatedMovement_Mutable()

Gets a reference to ReplicatedMovement with the expectation that it will be modified.

Public function Static

const FName

 

GetReplicateMovementPropertyName()

Gets the property name for bReplicateMovement.

Public function Static

const FName

 

GetRolePropertyName()

Gets the property name for Role.

Public function Const

USceneCompon...

 

GetRootComponent()

Returns this actor's root component.

Public function Virtual Const

void

 

GetSimpleCollisionCylinder

(
    float& CollisionRadius,
    float& CollisionHalfHeight
)

Get axis-aligned cylinder around this actor, used for simple collision checks (ie Pawns reaching a destination).

Public function Const

FVector

 

GetSimpleCollisionCylinderExtent()

Returns collision extents vector for this Actor, based on GetSimpleCollisionCylinder().

Public function Const

float

 

GetSimpleCollisionHalfHeight()

Returns the half height of the collision cylinder from GetSimpleCollisionCylinder().

Public function Const

float

 

GetSimpleCollisionRadius()

Returns the radius of the collision cylinder from GetSimpleCollisionCylinder().

Public function Const

float

 

GetSquaredDistanceTo

(
    const AActor* OtherActor
)

Returns the squared distance from this Actor to OtherActor.

Public function Virtual Const

FVector

 

GetTargetLocation

(
    AActor* RequestedBy
)

Returns the optimal location to fire weapons at this actor

Public function Const

bool

 

GetTearOff()

If true, this actor is no longer replicated to new clients, and is "torn off" (becomes a ROLE_Authority) on clients to which it was being replicated.

Public function

bool

 

GetTickableWhenPaused()

Gets whether this actor can tick when paused.

Public function Const

const FTrans...

 

GetTransform()

Get the actor-to-world transform.

Public function Const

EActorUpdate...

 

GetUpdateOverlapsMethodDuringLevelStreaming()

Get the method used to UpdateOverlaps() when loaded via level streaming.

Public function Virtual Const

FVector

 

GetVelocity()

Returns velocity (in cm/s (Unreal Units/second) of the rootcomponent if it is either using physics or has an associated MovementComponent

Public function Const

float

 

GetVerticalDistanceTo

(
    const AActor* OtherActor
)

Returns the distance from this Actor to OtherActor, ignoring XY.

Public function Virtual Const

UWorld *

 

GetWorld()

Getter for the cached world pointer, will return null if the actor is not actually spawned in a level

Public function Const

AWorldSettin...

 

GetWorldSettings()

Returns the WorldSettings for the World the actor is in If you'd like to know what UWorld this placed actor (not dynamic spawned actor) belong to, use GetTypedOuter()

Public function Const

FTimerManage...

 

GetWorldTimerManager()

Get the timer instance from the actors world

Public function Virtual Const

bool

 

HasActiveCameraComponent()

Returns true if the actor contains an active camera component

Public function Virtual Const

bool

 

HasActivePawnControlCameraComponent()

Returns true if the actor contains an active locked to HMD camera component

Public function Const

bool

 

HasActorBegunPlay()

Returns whether an actor has had BeginPlay called on it (and not subsequently had EndPlay called)

Public function Const

bool

 

HasAuthority()

Returns whether this actor has network authority

Public function Const

bool

 

HasDeferredComponentRegistration()

Returns true if Actor has deferred the RegisterAllComponents() call at spawn time (e.g. pending Blueprint SCS execution to set up a scene root component).

Public function Virtual Const

bool

 

HasLocalNetOwner()

Does this actor have a locally controlled owner responsible for replication? (APlayerController typically)

Public function Virtual Const

bool

 

HasNetOwner()

Does this actor have an owner responsible for replication? (APlayerController typically)

Public function

bool

 

HasValidRootComponent()

Returns true if Actor has a registered root component

Public function

bool

 

IncrementalRegisterComponents

(
    int32 NumComponentsToRegister,
    FRegisterComponentContext* Con...
)

Incrementally registers components associated with this actor, used during level streaming

Public function

void

 

InitializeComponents()

Iterate over components array and call InitializeComponent, which happens once per actor

Protected function Virtual

float

 

InternalTakePointDamage

(
    float Damage,
    FPointDamageEvent const& PointDama...,
    AController* EventInstigator,
    AActor* DamageCauser
)

Protected function Virtual

float

 

InternalTakeRadialDamage

(
    float Damage,
    FRadialDamageEvent const& RadialDa...,
    AController* EventInstigator,
    AActor* DamageCauser
)

Public function

void

 

InvalidateLightingCache()

Invalidate lighting cache with default options.

Public function Virtual

void

 

InvalidateLightingCacheDetailed

(
    bool bTranslationOnly
)

Invalidates anything produced by the last lighting build.

Public function Const

bool

 

IsActorBeginningPlay()

Returns whether an actor is in the process of beginning play

Public function Const

bool

 

IsActorBeginningPlayFromLevelStreaming()

Returns whether an actor is beginning play in DispatchBeginPlay() during level streaming (which includes initial level load).

Public function Const

bool

 

IsActorBeingDestroyed()

Returns true if this actor is currently being destroyed, some gameplay events may be unsafe

Public function Const

bool

 

IsActorInitialized()

Returns whether an actor has been initialized for gameplay

Public function Const

bool

 

IsActorLabelEditable()

Returns if this actor's current label is editable.

Public function Const

bool

 

IsActorTickEnabled()

Returns whether this actor has tick enabled or not

Public function Virtual Const

bool

 

IsAttachedTo

(
    const AActor* Other
)

Iterates up the attachment chain to see whether or not this Actor is attached to the given Actor

Public function Virtual Const

bool

 

IsBasedOnActor

(
    const AActor* Other
)

Iterates up the movement base chain to see whether or not this Actor is based on the given Actor, defaults to checking attachment

Public function Const

bool

 

IsChildActor()

Returns whether this Actor was spawned by a child actor component

Public function Virtual Const

bool

 

IsComponentRelevantForNavigation

(
    UActorComponent* Component
)

Check if owned component should be relevant for navigation Allows implementing master switch to disable e.g. collision export in projectiles

Public function Const

bool

 

IsEditable()

Returns true if this actor is allowed to be displayed, selected and manipulated by the editor.

Public function Const

bool

 

IsHidden()

Gets the literal value of bHidden.

Public function Const

bool

 

IsHiddenEd()

Returns true if this actor is hidden in the editor viewports, also checking temporary flags.

Public function Const

bool

 

IsHiddenEdAtStartup()

Returns true if the actor is hidden upon editor startup/by default, false if it is not

Public function Const

bool

 

IsInLevel

(
    const ULevel* TestLevel
)

Returns true if this actor is contained by TestLevel.

Public function Const

bool

 

IsInPersistentLevel

(
    bool bIncludeLevelStreamingPersiste...
)

Returns whether this Actor is in the persistent level, i.e. not a sublevel

Public function Virtual Const

bool

 

IsLevelBoundsRelevant()

Indicates whether this actor should participate in level bounds calculations

Public function Virtual Const

bool

 

IsListedInSceneOutliner()

Returns true if this actor should be shown in the scene outliner

Public function Const

bool

 

IsMatineeControlled()

Returns whether a MatineeActor is currently controlling this Actor

Public function Const

bool

 

IsNetMode

(
    ENetMode Mode
)

Test whether net mode is the given mode.

Public function Virtual Const

bool

 

IsNetRelevantFor

(
    const AActor* RealViewer,
    const AActor* ViewTarget,
    const FVector& SrcLocation
)

Checks to see if this actor is relevant for a specific network connection

Public function Const

bool

 

IsNetStartupActor()

Returns true if this is a replicated actor that was placed in the map

Public function Const

bool

 

IsOverlappingActor

(
    const AActor* Other
)

Check whether any component of this Actor is overlapping any component of another Actor.

Public function Const

bool

 

IsOwnedBy

(
    const AActor* TestOwner
)

See if this actor is owned by TestOwner.

Public function Const

bool

 

IsPendingKillPending()

Returns true if this actor has begun the destruction process.

Public function Virtual Const

bool

 

IsRelevancyOwnerFor

(
    const AActor* ReplicatedActor,
    const AActor* ActorOwner,
    const AActor* ConnectionActor
)

Check if this actor is the owner when doing relevancy checks for actors marked bOnlyRelevantToOwner

Public function Virtual Const

bool

 

IsReplayRelevantFor

(
    const AActor* RealViewer,
    const AActor* ViewTarget,
    const FVector& SrcLocation,
    const float CullDistanceSquared
)

Checks to see if this actor is relevant for a recorded replay

Public function Const

bool

 

IsReplicatingMovement()

Gets the literal value of bReplicateMovement.

Public function Virtual

bool

 

IsReplicationPausedForConnection

(
    const FNetViewer& ConnectionOwnerN...
)

Gives the actor a chance to pause replication to a player represented by the passed in actor - only called on server

Public function Virtual Const

bool

 

IsRootComponentCollisionRegistered()

Returns true if the root component is registered and has collision enabled.

Public function Const

bool

 

IsRootComponentMovable()

See if the root component has Mobility of EComponentMobility::Movable

Public function Const

bool

 

IsRootComponentStatic()

See if the root component has ModifyFrequency of MF_Static

Public function Const

bool

 

IsRootComponentStationary()

See if the root component has Mobility of EComponentMobility::Stationary

Public function Const

bool

 

IsRunningUserConstructionScript()

Returns if this actor is currently running the User Construction Script

Public function Virtual Const

bool

 

IsSelectable()

Returns true if this actor can EVER be selected in a level in the editor.

Public function Const

bool

 

IsTemporarilyHiddenInEditor

(
    bool bIncludeParent
)

Returns whether or not this actor was explicitly hidden in the editor for the duration of the current editor session

Protected function Const

bool

 

IsWithinNetRelevancyDistance

(
    const FVector& SrcLocation
)

Determines whether or not the distance between the given SrcLocation and the Actor's location is within the net relevancy distance.

Public function

void

 

K2_AddActorLocalOffset

(
    FVector DeltaLocation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Adds a delta to the location of this component in its local reference frame.

Public function

void

 

K2_AddActorLocalRotation

(
    FRotator DeltaRotation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Adds a delta to the rotation of this component in its local reference frame

Public function

void

 

K2_AddActorLocalTransform

(
    const FTransform& NewTransform,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Adds a delta to the transform of this component in its local reference frame

Public function

void

 

K2_AddActorWorldOffset

(
    FVector DeltaLocation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Adds a delta to the location of this actor in world space.

Public function

void

 

K2_AddActorWorldRotation

(
    FRotator DeltaRotation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Adds a delta to the rotation of this actor in world space.

Public function

void

 

K2_AddActorWorldTransform

(
    const FTransform& DeltaTransform,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Adds a delta to the transform of this actor in world space. Scale is unchanged.

Public function

void

 

K2_AttachToActor

(
    AActor* ParentActor,
    FName SocketName,
    EAttachmentRule LocationRule,
    EAttachmentRule RotationRule,
    EAttachmentRule ScaleRule,
    bool bWeldSimulatedBodies
)

Attaches the RootComponent of this Actor to the supplied actor, optionally at a named socket.

Public function

void

 

K2_AttachToComponent

(
    USceneComponent* Parent,
    FName SocketName,
    EAttachmentRule LocationRule,
    EAttachmentRule RotationRule,
    EAttachmentRule ScaleRule,
    bool bWeldSimulatedBodies
)

Attaches the RootComponent of this Actor to the supplied component, optionally at a named socket.

Public function Virtual

void

 

K2_DestroyActor()

Destroy the actor

Public function

void

 

K2_DetachFromActor

(
    EDetachmentRule LocationRule,
    EDetachmentRule RotationRule,
    EDetachmentRule ScaleRule
)

Detaches the RootComponent of this Actor from any SceneComponent it is currently attached to.

Public function Const

FVector

 

K2_GetActorLocation()

Returns the location of the RootComponent of this Actor

Public function Const

FRotator

 

K2_GetActorRotation()

Returns rotation of the RootComponent of this Actor.

Public function Const

TArray< UAct...

 

K2_GetComponentsByClass

(
    TSubclassOf< UActorComponent > Comp...
)

Gets all the components that inherit from the given class.

Public function Const

USceneCompon...

 

K2_GetRootComponent()

Returns the RootComponent of this Actor

Public function

void

 

K2_OnBecomeViewTarget

(
    APlayerController* PC
)

Event called when this Actor becomes the view target for the given PlayerController.

Public function

void

 

K2_OnEndViewTarget

(
    APlayerController* PC
)

Event called when this Actor is no longer the view target for the given PlayerController.

Public function

void

 

K2_OnReset()

Event called when this Actor is reset to its initial state - used when restarting level without reloading.

Public function

bool

 

K2_SetActorLocation

(
    FVector NewLocation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Move the Actor to the specified location.

Public function

bool

 

K2_SetActorLocationAndRotation

(
    FVector NewLocation,
    FRotator NewRotation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Move the actor instantly to the specified location and rotation.

Public function

void

 

K2_SetActorRelativeLocation

(
    FVector NewRelativeLocation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Set the actor's RootComponent to the specified relative location.

Public function

void

 

K2_SetActorRelativeRotation

(
    FRotator NewRelativeRotation,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Set the actor's RootComponent to the specified relative rotation

Public function

void

 

K2_SetActorRelativeTransform

(
    const FTransform& NewRelativeTrans...,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Set the actor's RootComponent to the specified relative transform

Public function

bool

 

K2_SetActorRotation

(
    FRotator NewRotation,
    bool bTeleportPhysics
)

Set the Actor's rotation instantly to the specified rotation.

Public function

bool

 

K2_SetActorTransform

(
    const FTransform& NewTransform,
    bool bSweep,
    FHitResult& SweepHitResult,
    bool bTeleport
)

Set the Actors transform to the specified one.

Public function

bool

 

K2_TeleportTo

(
    FVector DestLocation,
    FRotator DestRotation
)

Teleport this actor to a new location.

Public function Virtual

void

 

LifeSpanExpired()

Called when the lifespan of an actor expires (if he has one).

Public function

void

 

MakeNoise

(
    float Loudness,
    APawn* NoiseInstigator,
    FVector NoiseLocation,
    float MaxRange,
    FName Tag
)

Trigger a noise caused by a given Pawn, at a given location.

Public function Static

void

 

MakeNoiseImpl

(
    AActor* NoiseMaker,
    float Loudness,
    APawn* NoiseInstigator,
    const FVector& NoiseLocation,
    float MaxRange,
    FName Tag
)

Default Implementation of MakeNoise

Public function Virtual

void

 

MarkComponentsAsPendingKill()

Called to mark all components as pending kill when the actor is being destroyed

Public function

void

 

MarkComponentsRenderStateDirty()

Flags all component's render state as dirty

Public function Virtual Const

bool

 

NeedsLoadForTargetPlatform

(
    const ITargetPlatform* TargetP...
)

Public function Virtual

void

 

NotifyActorBeginCursorOver()

Event when this actor has the mouse moved over it with the clickable interface.

Public function Virtual

void

 

NotifyActorBeginOverlap

(
    AActor* OtherActor
)

Event when this actor overlaps another actor, for example a player walking into a trigger.

Public function Virtual

void

 

NotifyActorEndCursorOver()

Event when this actor has the mouse moved off of it with the clickable interface.

Public function Virtual

void

 

NotifyActorEndOverlap

(
    AActor* OtherActor
)

Event when an actor no longer overlaps another actor, and they have separated.

Public function Virtual

void

 

NotifyActorOnClicked

(
    FKey ButtonPressed
)

Event when this actor is clicked by the mouse when using the clickable interface.

Public function Virtual

void

 

NotifyActorOnInputTouchBegin

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor is touched when click events are enabled.

Public function Virtual

void

 

NotifyActorOnInputTouchEnd

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor is under the finger when untouched when click events are enabled.

Public function Virtual

void

 

NotifyActorOnInputTouchEnter

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor has a finger moved over it with the clickable interface.

Public function Virtual

void

 

NotifyActorOnInputTouchLeave

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor has a finger moved off of it with the clickable interface.

Public function Virtual

void

 

NotifyActorOnReleased

(
    FKey ButtonReleased
)

Event when this actor is under the mouse when left mouse button is released while using the clickable interface.

Public function Virtual

void

 

NotifyHit

(
    UPrimitiveComponent* MyComp,
    AActor* Other,
    UPrimitiveComponent* OtherComp,
    bool bSelfMoved,
    FVector HitLocation,
    FVector HitNormal,
    FVector NormalImpulse,
    const FHitResult& Hit
)

Event when this actor bumps into a blocking object, or blocks another actor that bumps into it.

Public function Virtual

void

 

OnActorChannelOpen

(
    FInBunch& InBunch,
    UNetConnection* Connection
)

Allows for a specific response from the actor when the actor channel is opened (client side)

Public function Virtual

void

 

OnConstruction

(
    const FTransform& Transform
)

Called when an instance of this class is placed (in editor) or spawned.

Public function Virtual

void

 

OnNetCleanup

(
    UNetConnection* Connection
)

Handles cleaning up the associated Actor when killing the connection

Public function Virtual

void

 

OnRep_AttachmentReplication()

Called on client when updated AttachmentReplication value is received for this actor.

Public function Virtual

void

 

OnRep_Instigator()

Called on clients when Instigator is replicated.

Protected function Virtual

void

 

OnRep_Owner()

Called when owner changes, does nothing by default but can be overridden

Public function Virtual

void

 

OnRep_ReplicatedMovement()

ReplicatedMovement struct replication event

Public function Virtual

void

 

OnRep_ReplicateMovement()

Called on client when updated bReplicateMovement value is received for this actor.

Public function Virtual

void

 

OnReplicationPausedChanged

(
    bool bIsReplicationPaused
)

Called on the client when the replication paused value is changed

Public function Virtual

void

 

OnSerializeNewActor

(
    FOutBunch& OutBunch
)

SerializeNewActor has just been called on the actor before network replication (server side)

Public function Virtual

void

 

OnSubobjectCreatedFromReplication

(
    UObject* NewSubobject
)

Called on the actor when a new subobject is dynamically created via replication

Public function Virtual

void

 

OnSubobjectDestroyFromReplication

(
    UObject* Subobject
)

Called on the actor when a subobject is dynamically destroyed via replication

Public function Virtual

void

 

OutsideWorldBounds()

Called when the Actor is outside the hard limit on world bounds

Public function Const

bool

 

OwnsComponent

(
    UActorComponent* Component
)

Utility function for validating that a component is correctly in its Owner's OwnedComponents array

Public function

void

 

PostActorConstruction()

Called after the actor has run its construction. Responsible for finishing the actor spawn process.

Public function Virtual

void

 

PostActorCreated()

Called when an actor is done spawning into the world (from UWorld::SpawnActor), both in the editor and during gameplay For actors with a root component, the location and rotation will have already been set.

Protected function

void

 

PostCreateBlueprintComponent

(
    UActorComponent* NewActorComp
)

Called after instancing a new Blueprint Component from either a template or cooked data.

Public function Virtual

void

 

PostEditMove

(
    bool bFinished
)

Called after an actor has been moved in the editor

Public function Virtual

void

 

PostInitializeComponents()

Allow actors to initialize themselves on the C++ side after all of their components have been initialized, only called during gameplay

Public function Virtual

void

 

PostNetInit()

Always called immediately after spawning and reading in replicated properties

Public function Virtual

void

 

PostNetReceiveLocationAndRotation()

Update location and rotation from ReplicatedMovement. Not called for simulated physics!

Public function Virtual

void

 

PostNetReceivePhysicState()

Update and smooth simulated physic state, replaces PostNetReceiveLocation() and PostNetReceiveVelocity()

Public function Virtual

void

 

PostNetReceiveRole()

Always called immediately after a new Role is received from the remote.

Public function Virtual

void

 

PostNetReceiveVelocity

(
    const FVector& NewVelocity
)

Update velocity - typically from ReplicatedMovement, not called for simulated physics!

Public function Virtual

void

 

PostRegisterAllComponents()

Called after all the components in the Components array are registered, called both in editor and during gameplay

Public function Virtual

void

 

PostRenderFor

(
    APlayerController* PC,
    UCanvas* Canvas,
    FVector CameraPosition,
    FVector CameraDir
)

Hook to allow actors to render HUD overlays for themselves.

Public function

void

 

PostSpawnInitialize

(
    FTransform const& SpawnTransform,
    AActor* InOwner,
    APawn* InInstigator,
    bool bRemoteOwned,
    bool bNoFail,
    bool bDeferConstruction
)

Called after the actor is spawned in the world. Responsible for setting up actor for play.

Public function Virtual

void

 

PostUnregisterAllComponents()

Called after all currently registered components are cleared

Public function Virtual

void

 

PreInitializeComponents()

Called right before components are initialized, only called during gameplay

Public function Virtual

void

 

PreRegisterAllComponents()

Called before all the components in the Components array are registered, called both in editor and during gameplay

Public function Virtual

void

 

PreReplication

(
    IRepChangedPropertyTracker& Change...
)

Called on the actor right before replication occurs.

Public function Virtual

void

 

PreReplicationForReplay

(
    IRepChangedPropertyTracker& Change...
)

Called on the actor right before replication occurs.

Public function Virtual

void

 

PrestreamTextures

(
    float Seconds,
    bool bEnableStreaming,
    int32 CinematicTextureGroups
)

Calls PrestreamTextures() for all the actor's meshcomponents.

Protected function

void

 

ProcessUserConstructionScript()

Runs UserConstructionScript, delays component registration until it's complete.

Public function

void

 

ReceiveActorBeginCursorOver()

Event when this actor has the mouse moved over it with the clickable interface.

Public function

void

 

ReceiveActorBeginOverlap

(
    AActor* OtherActor
)

Event when this actor overlaps another actor, for example a player walking into a trigger.

Public function

void

 

ReceiveActorEndCursorOver()

Event when this actor has the mouse moved off of it with the clickable interface.

Public function

void

 

ReceiveActorEndOverlap

(
    AActor* OtherActor
)

Event when an actor no longer overlaps another actor, and they have separated.

Public function

void

 

ReceiveActorOnClicked

(
    FKey ButtonPressed
)

Event when this actor is clicked by the mouse when using the clickable interface.

Public function

void

 

ReceiveActorOnInputTouchBegin

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor is touched when click events are enabled.

Public function

void

 

ReceiveActorOnInputTouchEnd

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor is under the finger when untouched when click events are enabled.

Public function

void

 

ReceiveActorOnInputTouchEnter

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor has a finger moved over it with the clickable interface.

Public function

void

 

ReceiveActorOnInputTouchLeave

(
    const ETouchIndex::Type FingerIndex
)

Event when this actor has a finger moved off of it with the clickable interface.

Public function

void

 

ReceiveActorOnReleased

(
    FKey ButtonReleased
)

Event when this actor is under the mouse when left mouse button is released while using the clickable interface.

Public function

void

 

ReceiveAnyDamage

(
    float Damage,
    const UDamageType* DamageType,
    AController* InstigatedBy,
    AActor* DamageCauser
)

Event when this actor takes ANY damage

Protected function

void

 

ReceiveBeginPlay()

Event when play begins for this actor.

Public function

void

 

ReceiveDestroyed()

Called when the actor has been explicitly destroyed.

Protected function

void

 

ReceiveEndPlay

(
    EEndPlayReason::Type EndPlayReason
)

Event to notify blueprints this actor is being deleted or removed from a level.

Public function

void

 

ReceiveHit

(
    UPrimitiveComponent* MyComp,
    AActor* Other,
    UPrimitiveComponent* OtherComp,
    bool bSelfMoved,
    FVector HitLocation,
    FVector HitNormal,
    FVector NormalImpulse,
    const FHitResult& Hit
)

Event when this actor bumps into a blocking object, or blocks another actor that bumps into it.

Public function

void

 

ReceivePointDamage

(
    float Damage,
    const UDamageType* DamageType,
    FVector HitLocation,
    FVector HitNormal,
    UPrimitiveComponent* HitCompon...,
    FName BoneName,
    FVector ShotFromDirection,
    AController* InstigatedBy,
    AActor* DamageCauser,
    const FHitResult& HitInfo
)

Event when this actor takes POINT damage

Public function

void

 

ReceiveRadialDamage

(
    float DamageReceived,
    const UDamageType* DamageType,
    FVector Origin,
    const FHitResult& HitInfo,
    AController* InstigatedBy,
    AActor* DamageCauser
)

Event when this actor takes RADIAL damage

Public function

void

 

ReceiveTick

(
    float DeltaSeconds
)

Event called every frame, if ticking is enabled

Protected function Virtual

void

 

RegisterActorTickFunctions

(
    bool bRegister
)

Virtual call chain to register all tick functions for the actor class hierarchy

Public function

void

 

RegisterAllActorTickFunctions

(
    bool bRegister,
    bool bDoComponents
)

When called, will call the virtual call chain to register all of the tick functions for both the actor and optionally all components Do not override this function or make it virtual

Public function Virtual

void

 

RegisterAllComponents()

Ensure that all the components in the Components array are registered

Public function

void

 

RemoveControllingMatineeActor

(
    AMatineeActor& InMatineeActor
)

Removes a controlling matinee actor

Public function

void

 

RemoveInstanceComponent

(
    UActorComponent* Component
)

Removes a component from the instance components array

Public function

void

 

RemoveOwnedComponent

(
    UActorComponent* Component
)

Removes a component from the OwnedComponents array of the Actor.

Public function Virtual

void

 

RemoveTickPrerequisiteActor

(
    AActor* PrerequisiteActor
)

Remove tick dependency on PrerequisiteActor.

Public function Virtual

void

 

RemoveTickPrerequisiteComponent

(
    UActorComponent* PrerequisiteC...
)

Remove tick dependency on PrerequisiteComponent.

Public function Virtual

bool

 

ReplicateSubobjects

(
    UActorChannel* Channel,
    FOutBunch* Bunch,
    FReplicationFlags* RepFlags
)

Method that allows an actor to replicate subobjects on its actor channel

Public function Virtual

void

 

ReregisterAllComponents()

Will reregister all components on this actor.

Public function Const

bool

 

ReregisterComponentsWhenModified()

Returns true if the component is allowed to re-register its components when modified.

Public function Virtual

void

 

RerunConstructionScripts()

Rerun construction scripts, destroying all autogenerated components; will attempt to preserve the root component location.

Public function Virtual

void

 

Reset()

Reset actor to initial state - used when restarting level without reloading.

Public function

void

 

ResetOwnedComponents()

Force the Actor to clear and rebuild its OwnedComponents array by evaluating all children (recursively) and locating components In general this should not need to be called directly, but can sometimes be necessary as part of undo/redo code paths.

Public function

void

 

ResetPropertiesForConstruction()

Reset private properties to defaults, and all FRandomStream structs in this Actor, so they will start their sequence of random numbers again.

Public function Virtual

void

 

RewindForReplay()

Called on the actor before checkpoint data is applied during a replay.

Public function

void

 

RouteEndPlay

(
    const EEndPlayReason::Type EndPlayR...
)

Non-virtual function to evaluate which portions of the EndPlay process should be dispatched for each actor

Public function

void

 

SeedAllRandomStreams()

Find all FRandomStream structs in this Actor and generate new random seeds for them.

Public function

void

 

SetActorEnableCollision

(
    bool bNewActorEnableCollision
)

Allows enabling/disabling collision for the whole actor

Public function Virtual

void

 

SetActorHiddenInGame

(
    bool bNewHidden
)

Sets the actor to be hidden in the game

Public function

void

 

SetActorLabel

(
    const FString& NewActorLabel,
    bool bMarkDirty
)

Assigns a new label to this actor. Actor labels are only available in development builds.

Public function

bool

 

SetActorLocation

(
    const FVector& NewLocation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Move the actor instantly to the specified location.

Public function

bool

 

SetActorLocationAndRotation

(
    FVector NewLocation,
    const FQuat& NewRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Move the actor instantly to the specified location and rotation.

Public function

bool

 

SetActorLocationAndRotation

(
    FVector NewLocation,
    FRotator NewRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Move the actor instantly to the specified location and rotation.

Public function

void

 

SetActorRelativeLocation

(
    FVector NewRelativeLocation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Set the actor's RootComponent to the specified relative location.

Public function

void

 

SetActorRelativeRotation

(
    const FQuat& NewRelativeRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Set the actor's RootComponent to the specified relative rotation

Public function

void

 

SetActorRelativeRotation

(
    FRotator NewRelativeRotation,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Set the actor's RootComponent to the specified relative rotation

Public function

void

 

SetActorRelativeScale3D

(
    FVector NewRelativeScale
)

Set the actor's RootComponent to the specified relative scale 3d

Public function

void

 

SetActorRelativeTransform

(
    const FTransform& NewRelativeTrans...,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Set the actor's RootComponent to the specified relative transform

Public function

bool

 

SetActorRotation

(
    const FQuat& NewRotation,
    ETeleportType Teleport
)

Set the Actor's rotation instantly to the specified rotation.

Public function

bool

 

SetActorRotation

(
    FRotator NewRotation,
    ETeleportType Teleport
)

Set the Actor's rotation instantly to the specified rotation.

Public function

void

 

SetActorScale3D

(
    FVector NewScale3D
)

Set the Actor's world-space scale.

Public function

void

 

SetActorTickEnabled

(
    bool bEnabled
)

Set this actor's tick functions to be enabled or disabled.

Public function

void

 

SetActorTickInterval

(
    float TickInterval
)

Sets the tick interval of this actor's primary tick function.

Public function

bool

 

SetActorTransform

(
    const FTransform& NewTransform,
    bool bSweep,
    FHitResult* OutSweepHitResult,
    ETeleportType Teleport
)

Set the Actors transform to the specified one.

Public function

void

 

SetAutoDestroyWhenFinished

(
    bool bVal
)

Public function

void

 

SetAutonomousProxy

(
    const bool bInAutonomousProxy,
    const bool bAllowForcePropertyCompa...
)

Sets whether or not this Actor is an autonomous proxy, which is an actor on a network client that is controlled by a user on that client.

Public function

void

 

SetCanBeDamaged

(
    bool bInCanBeDamaged
)

Sets the value of bCanBeDamaged without causing other side effects to this instance.

Public function

void

 

SetFolderPath

(
    const FName& NewFolderPath
)

Assigns a new folder to this actor. Actor folder paths are only available in development builds.

Public function

void

 

SetFolderPath_Recursively

(
    const FName& NewFolderPath
)

Assigns a new folder to this actor and any attached children.

Public function

void

 

SetHidden

(
    const bool bInHidden
)

Sets the value of bHidden without causing other side effects to this instance.

Public function

void

 

SetInstigator

(
    APawn* InInstigator
)

Sets the value of Instigator without causing other side effects to this instance.

Public function Virtual

void

 

SetIsTemporarilyHiddenInEditor

(
    bool bIsHidden
)

Explicitly sets whether or not this actor is hidden in the editor for the duration of the current editor session

Public function Virtual

void

 

SetLifeSpan

(
    float InLifespan
)

Set the lifespan of this actor.

Public function

void

 

SetLODParent

(
    UPrimitiveComponent* InLODPare...,
    float InParentDrawDistance
)

Set LOD Parent component for all of our components, normally associated with an ALODActor.

Public function Static

void

 

SetMakeNoiseDelegate

(
    const FMakeNoiseDelegate& NewDeleg...
)

Modifies the global delegate used for handling MakeNoise

Public function

void

 

SetNetDormancy

(
    ENetDormancy NewDormancy
)

Puts actor in dormant networking state

Public function

void

 

SetNetDriverName

(
    FName NewNetDriverName
)

Set the name of the net driver associated with this actor.

Public function

void

 

SetNetUpdateTime

(
    float NewUpdateTime
)

Updates NetUpdateTime to the new value for future net relevancy checks

Public function Virtual

void

 

SetOwner

(
    AActor* NewOwner
)

Set the owner of this Actor, used primarily for network replication.

Public function

void

 

SetPivotOffset

(
    const FVector& InPivotOffset
)

Sets the local space offset added to the actor's pivot as used by the editor

Protected function

void

 

SetRemoteRoleForBackwardsCompat

(
    const ENetRole InRemoteRole
)

This function should only be used in the constructor of classes that need to set the RemoteRole for backwards compatibility purposes

Public function

void

 

SetReplicatedMovement

(
    const FRepMovement& InReplicatedMo...
)

Sets the value of ReplicatedMovement without causing other side effects to this instance.

Public function Virtual

void

 

SetReplicateMovement

(
    bool bInReplicateMovement
)

Set whether this actor's movement replicates to network clients.

Public function

void

 

SetReplicates

(
    bool bInReplicates
)

Set whether this actor replicates to network clients.

Public function

void

 

SetReplicatingMovement

(
    bool bInReplicateMovement
)

Sets the value of bReplicateMovement without causing other side effects to this instance.

Public function

void

 

SetRole

(
    ENetRole InRole
)

Sets the value of Role without causing other side effects to this instance.

Public function

bool

 

SetRootComponent

(
    USceneComponent* NewRootCompon...
)

Sets root component to be the specified component. NewRootComponent's owner should be this actor.

Public function

void

 

SetTickableWhenPaused

(
    bool bTickableWhenPaused
)

Sets whether this actor can tick when paused.

Public function

void

 

SetTickGroup

(
    ETickingGroup NewTickGroup
)

Sets the ticking group for this actor.

Public function Const

bool

 

ShouldCookOptimizedBPComponentData()

Returns whether or not to cook optimized Blueprint component data for this actor

Public function Virtual

bool

 

ShouldExport()

Called before editor copy, true allow export

Public function Virtual

bool

 

ShouldImport

(
    FString* ActorPropString,
    bool IsMovingLevel
)

Called before editor paste, true allow import

Public function Virtual Const

bool

 

ShouldTickIfViewportsOnly()

If true, actor is ticked even if TickType==LEVELTICK_ViewportsOnly

Public function

void

 

SwapRoles()

Calls this to swap the Role and RemoteRole. Only call this if you know what you're doing!

Protected function

void

 

SyncReplicatedPhysicsSimulation()

Sync IsSimulatingPhysics() with ReplicatedMovement.bRepPhysics

Public function Virtual

float

 

TakeDamage

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

Apply damage to this actor.

Public function Virtual

void

 

TearOff()

Networking - Server - TearOff this actor to stop replication to clients. Will set bTearOff to true.

Public function Virtual

void

 

TeleportSucceeded

(
    bool bIsATest
)

Called from TeleportTo() when teleport succeeds

Public function Virtual

bool

 

TeleportTo

(
    const FVector& DestLocation,
    const FRotator& DestRotation,
    bool bIsATest,
    bool bNoCheck
)

Used for adding actors to levels or teleporting them to a new location.

Public function Virtual

void

 

Tick

(
    float DeltaSeconds
)

Function called every frame on this Actor.

Public function Virtual

void

 

TickActor

(
    float DeltaTime,
    enum ELevelTick TickType,
    FActorTickFunction& ThisTickFuncti...
)

Dispatches the once-per frame Tick() function for this actor

Public function Virtual

void

 

TornOff()

Networking - called on client when actor is torn off (bTearOff==true), meaning it's no longer replicated to clients.

Public function

void

 

UninitializeComponents()

Iterate over components array and call UninitializeComponent, called when the actor is ending play

Public function Virtual

void

 

UnregisterAllComponents

(
    bool bForReregister
)

Unregister all currently registered components

Public function

void

 

UpdateAllReplicatedComponents()

Completely synchronizes the replicated components array so that it contains exactly the number of replicated components currently owned

Public function

void

 

UpdateComponentTransforms()

Update all components transforms

Public function

void

 

UpdateOverlaps

(
    bool bDoNotifies
)

Queries world and updates overlap detection state for this actor.

Public function

void

 

UpdateReplicatedComponent

(
    UActorComponent* Component
)

Called when the replicated state of a component changes to update the Actor's cached ReplicatedComponents array

Public function

void

 

UserConstructionScript()

Construction script, the place to spawn components and do other setup.

Public function Virtual Const

bool

 

UseShortConnectTimeout()

Used by the net connection to determine if a net owning actor should switch to using the shortened timeout value

Public function Const

bool

 

WasRecentlyRendered

(
    float Tolerance
)

Returns true if this actor has been rendered "recently", with a tolerance in seconds to define what "recent" means.

Overridden from UObject

Name Description

Public function Virtual

void

 

BeginDestroy()

Called before destroying the object.

Public function Virtual

bool

 

CallRemoteFunction

(
    UFunction* Function,
    void* Parms,
    FOutParmRec* OutParms,
    FFrame* Stack
)

Call the actor's function remotely

Public function Virtual Const

bool

 

CheckDefaultSubobjectsInternal()

Checks default sub-object assumptions.

Public function Virtual Const

TSharedPtr< ...

 

FactoryTransactionAnnotation

(
    const ETransactionAnnotationCreatio...
)

Public function Virtual

int32

 

GetFunctionCallspace

(
    UFunction* Function,
    FFrame* Stack
)

Return the space this function should be called.

Public function Virtual Const

void

 

GetLifetimeReplicatedProps

(
    TArray< FLifetimeProperty >& OutLi...
)

Returns the properties used for network replication, this needs to be overridden by all actor classes with native replicated properties

Public function Virtual

void

 

GetSubobjectsWithStableNamesForNetworking

(
    TArray< UObject* >& ObjList
)

Returns a list of sub-objects that have stable names for networking

Public function Virtual

EDataValidat...

 

IsDataValid

(
    TArray< FText >& ValidationErrors
)

Returns Valid if this object has data validation rules set up for it and the data for this object is valid.

Public function Virtual Const

bool

 

IsEditorOnly()

Called during saving to determine if the object is forced to be editor only or not

Public function Virtual Const

bool

 

IsNameStableForNetworking()

IsNameStableForNetworking means an object can be referred to its path name (relative to outer) over the network

Public function Virtual

bool

 

IsReadyForFinishDestroy()

Called to check if the object is ready for FinishDestroy.

Public function Virtual Const

bool

 

IsSelectedInEditor()

Test the selection state of a UObject

Public function Virtual Const

bool

 

IsSupportedForNetworking()

IsSupportedForNetworking means an object can be referenced over the network

Public function Virtual

bool

 

Modify

(
    bool bAlwaysMarkDirty
)

Note that the object will be modified.

Public function Virtual

void

 

PostEditChangeProperty

(
    FPropertyChangedEvent& PropertyCha...
)

Called when a property on this object has been modified externally

Public function Virtual

void

 

PostEditImport()

Called after importing property values for this object (paste, duplicate or .t3d import) Allow the object to perform any cleanup for properties which shouldn't be duplicated or are unsupported by the script serialization

Public function Virtual

void

 

PostEditUndo()

Called after applying a transaction to the object.

Public function Virtual

void

 

PostEditUndo

Called after applying a transaction to the object in cases where transaction annotation was provided.

Public function Virtual

void

 

PostInitProperties()

Called after the C++ constructor and after the properties have been initialized, including those loaded from config.

Public function Virtual

void

 

PostLoad()

Do any object-specific cleanup required immediately after loading an object.

Public function Virtual

void

 

PostLoadSubobjects

(
    FObjectInstancingGraph* OuterI...
)

Instances components for objects being loaded from disk, if necessary.

Public function Virtual

void

 

PostNetReceive()

Always called immediately after properties are received from the remote.

Public function Virtual

void

 

PostRename

(
    UObject* OldOuter,
    const FName OldName
)

Called at the end of Rename(), but only if the rename was actually carried out

Public function Virtual

void

 

PostTransacted

(
    const FTransactionObjectEvent& Tra...
)

Called after the object has been transacted in some way.

Public function Virtual

void

 

PreEditChange

(
    FProperty* PropertyAboutToChan...
)

This is called when a property is about to be modified externally

Public function Virtual

void

 

PreEditUndo()

Called before applying a transaction to the object.

Public function Virtual

void

 

PreNetReceive()

Always called immediately before properties are received from the remote.

Public function Virtual

void

 

ProcessEvent

(
    UFunction* Function,
    void* Parms
)

Called by VM to execute a UFunction with a filled in UStruct of parameters

Public function Virtual

bool

 

Rename

(
    const TCHAR* NewName,
    UObject* NewOuter,
    ERenameFlags Flags
)

Rename this object to a unique name, or change its outer.

Public function Virtual

void

 

Serialize

(
    FArchive& Ar
)

Handles reading, writing, and reference collecting using FArchive.

Overridden from UObjectBaseUtility

Name Description

Public function Virtual Const

bool

 

CanBeInCluster()

Called during cluster construction if the object can be added to a cluster

Classes

Name

Description

Public struct

FActorRootComponentReconstructionData

Internal struct used to store information about an actor's components during reconstruction

Public class

FActorTransactionAnnotation

Internal struct to track currently active transactions

Enums

Name

Description

Private enum

EActorBeginPlayState

Enum defining if BeginPlay has started or finished

Constants

Name

Description

BeginPlayCallDepth

bUsePercentageBasedScaling

MakeNoiseDelegate

ProcessEventDelegate

Delegate for globally hooking ProccessEvent calls - used by a non-public testing plugin

Deprecated Functions

Name Description

Public function

void

 

DetachRootComponentFromParent

(
    bool bMaintainWorldPosition
)

Use DetachFromActor() instead

Public function Const

TArray< UAct...

 

GetComponentsByClass

(
    TSubclassOf< UActorComponent > Comp...
)

Use one of the GetComponents implementations as appropriate

Public function

void

 

K2_AttachRootComponentTo

(
    USceneComponent* InParent,
    FName InSocketName,
    EAttachLocation::Type AttachLocatio...,
    bool bWeldSimulatedBodies
)

Use AttachToComponent() instead.

Public function

void

 

K2_AttachRootComponentToActor

(
    AActor* InParentActor,
    FName InSocketName,
    EAttachLocation::Type AttachLocatio...,
    bool bWeldSimulatedBodies
)

Use AttachToActor() instead.

Public function

void

 

K2_DestroyComponent

(
    UActorComponent* Component
)

Use UActorComponent::DestroyComponent() instead

Public function

UMaterialIns...

 

MakeMIDForMaterial

(
    UMaterialInterface* Parent
)

Use UPrimitiveComponent::CreateAndSetMaterialInstanceDynamic() instead.

Public function

void

 

SnapRootComponentTo

(
    AActor* InParentActor,
    FName InSocketName
)

Use AttachToComponent() with EAttachLocation::SnapToTarget option instead

See Also

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss