UMassRepresentationProcessor::ReleaseActorOrCancelSpawning

Release the actor to the subsystem, will only release it the actor or spawn request matches the template actor

Choose your operating system:

Windows

macOS

Linux

References

Module

MassRepresentation

Header

/Engine/Plugins/Runtime/MassGameplay/Source/MassRepresentation/Public/MassRepresentationProcessor.h

Include

#include "MassRepresentationProcessor.h"

Source

/Engine/Plugins/Runtime/MassGameplay/Source/MassRepresentation/Private/MassRepresentationProcessor.cpp

Syntax

virtual bool ReleaseActorOrCancelSpawning
(
    const FMassEntityHandle MassAgent,
    FDataFragment_Actor & ActorInfo,
    const int16 TemplateActorIndex,
    FMassActorSpawnRequestHandle & SpawnRequestHandle,
    FMassCommandBuffer & CommandBuffer,
    const bool bCancelSpawningOnly
)

Remarks

Release the actor to the subsystem, will only release it the actor or spawn request matches the template actor

Returns

if the actor was release or the spawning was canceled.

Parameters

Parameter

Description

MassAgent

is the handle to the associated mass agent

ActorInfo

is the fragment where we are going to store the actor pointer

TemplateActorIndex

is the index of the type to release

SpawnRequestHandle

(in/out) In: previously requested spawn to cancel if any

CommandBuffer

to queue up anything that is thread sensitive

bCancelSpawningOnly

tell to only cancel the existing spawning request and to not release the associated actor it any.