Navigation
API > API/Plugins > API/Plugins/InstancedActors > API/Plugins/InstancedActors/UInstancedActorsSubsystem
Description
Removes all instance data for InstanceHandle.
This simply adds this instance to a FreeList which incurs extra cost to process at runtime before instance spawning.
| Name | RemoveActorInstance |
| Type | function |
| Header File | /Engine/Plugins/Runtime/InstancedActors/Source/InstancedActors/Public/InstancedActorsSubsystem.h |
| Include Path | #include "InstancedActorsSubsystem.h" |
| Source | /Engine/Plugins/Runtime/InstancedActors/Source/InstancedActors/Private/InstancedActorsSubsystem.cpp |
UFUNCTION (BlueprintCallable, Category=InstancedActors)
bool RemoveActorInstance
(
const FInstancedActorsInstanceHandle & InstanceHandle,
bool bDestroyManagerIfEmpty
)
Parameters
| Name | Remarks |
|---|---|
| InstanceHandle | Instance to remove |
| bDestroyManagerIfEmpty | If true, and InstanceHandle is the last instance in its manager, destroy the now-empty manager. This implicitly clears the FreeList which is stored per-manager. Any subsequent instance adds will then create a fresh manager. |
See Also
- IA.CompactInstances console command