Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/GameFramework > API/Runtime/Engine/GameFramework/AActor > API/Runtime/Engine/GameFramework/AActor/GetActorClassDefaultComponentByN-
References
| Module | Engine |
| Header | /Engine/Source/Runtime/Engine/Classes/GameFramework/Actor.h |
| Include | #include "GameFramework/Actor.h" |
| Source | /Engine/Source/Runtime/Engine/Private/Actor.cpp |
static const UActorComponent * GetActorClassDefaultComponentByName
(
const TSubclassOf < AActor > & InActorClass,
const TSubclassOf < UActorComponent > & InComponentClass,
FName InComponentName
)
Remarks
Get the component of ActorClass's CDO that matches the given object name. Will consider all components, including the ones added via the BP editor (which AActor.GetComponents fails to do for CDOs).
Parameters
| Name | Description |
|---|---|
| InActorClass | Class of AActor for which we will search all components. |
| InComponentClass | Only consider components of this type. |
| OutComponents | this is where the found components will end up. Note that the preexisting contents of OutComponents will get overridden. |