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/Experimental/PCG/Source/PCG/Public/Helpers/PCGActorHelpers.h |
| Include | #include "Helpers/PCGActorHelpers.h" |
| Source | /Engine/Plugins/Experimental/PCG/Source/PCG/Private/Helpers/PCGActorHelpers.cpp |
static AActor &42; SpawnDefaultActor
&40;
UWorld &42; World,
TSubclassOf< AActor > ActorClass,
FName BaseName,
const FTransform & Transform,
AActor &42; Parent
&41;
Remarks
Spawn a new actor and attach it to the parent (if not null)
Parameters
| Name | Description |
|---|---|
| World | The world |
| ActorClass | Class of the actor to spawn |
| BaseName | Base name for the actor, will have a unique name |
| Transform | The transform for the new actor |
| Parent | Optional parent to attach to. |