Navigation
API > API/Plugins > API/Plugins/PCG > API/Plugins/PCG/Helpers > API/Plugins/PCG/Helpers/UPCGActorHelpers > API/Plugins/PCG/Helpers/UPCGActorHelpers/SpawnDefaultActor
References
| Module | PCG |
| Header | /Engine/Plugins/PCG/Source/PCG/Public/Helpers/PCGActorHelpers.h |
| Include | #include "Helpers/PCGActorHelpers.h" |
template<typename T, typename>
static AActor * SpawnDefaultActor
(
UWorld * World,
ULevel * Level,
FName BaseName,
const FTransform & Transform,
AActor * Parent
)
Remarks
Spawn a new actor of type T and attach it to the parent (if not null)
Parameters
| Name | Description |
|---|---|
| World | The world |
| Level | The level to spawn into |
| BaseName | Base name for the actor, will have a unique name |
| Transform | The transform for the new actor |
| Parent | Optional parent to attach to. |