ue-ai-navigation
Use when writing Unreal Engine C++ AI — AI controllers, behavior tree nodes, blackboards, AI perception, navmesh pathfinding, EQS…
Use when writing or debugging AActor and UActorComponent C++: constructor vs BeginPlay, PostInitializeComponents, EndPlay cleanup, SpawnActor/SpawnActorDeferred/FinishSpawning, CreateDefaultSubobject, NewObject + RegisterComponent, SetupAttachment/AttachToComponent, tick groups,
Claude Code
$ npx -y skills add quodsoler/unreal-engine-skills --skill ue-actor-component-architecture --agent claude-code
Codex
$ npx skills add quodsoler/unreal-engine-skills --skill ue-actor-component-architecture -a codex -y
Cursor
$ npx skills add quodsoler/unreal-engine-skills --skill ue-actor-component-architecture -a cursor -y
Gemini CLI
$ npx skills add quodsoler/unreal-engine-skills --skill ue-actor-component-architecture -a gemini-cli -y
GitHub Copilot
$ npx skills add quodsoler/unreal-engine-skills --skill ue-actor-component-architecture -a github-copilot -y
OpenCode
$ npx skills add quodsoler/unreal-engine-skills --skill ue-actor-component-architecture -a opencode -y
Windsurf
$ npx skills add quodsoler/unreal-engine-skills --skill ue-actor-component-architecture -a windsurf -y
name: ue-actor-component-architecture description: "Use when writing or debugging AActor and UActorComponent C++: constructor vs BeginPlay, PostInitializeComponents, EndPlay cleanup, SpawnActor/SpawnActorDeferred/FinishSpawning, CreateDefaultSubobject, NewObject + RegisterComponent, SetupAttachment/AttachToComponent, tick groups, UChildActorComponent, UINTERFACE, actor pooling. Also use when the user mentions 'BeginPlay', 'Tick', 'SpawnActor', 'CreateDefaultSubobject', 'attach a component', 'root component', 'lifecycle', 'PrimaryActorTick', 'FAttachmentTransformRules'. For collision and overlaps, see ue-physics-collision; for GameMode/Pawn/Controller, see ue-gameplay-framework; for replicated actors, see ue-networking-replication." metadata: version: "2.0.0" engine: "5.8"
Target engine: **UE 5.8**. APIs below are verified against the 5.8 headers; older forms are listed under "Deprecated — do not use".
Build actors out of components: lifecycle hooks in the right order, spawning (immediate, deferred, pooled), component creation and attachment, ticking, and C++ interfaces. Everything here is in the `Engine` module (`GameFramework/Actor.h`, `Components/ActorComponent.h`, `Components/SceneComponent.h`, `Engine/World.h`) on top of `CoreUObject`; a game module's Build.cs needs `"Core", "CoreUObject", "Engine"`.
Read `.agents/ue-project-context.md` if it exists (module names, conventions, enabled plugins, GAS/networking setup). Do not stop if it is missing.
Identify the area from the request and the codebase. Ask only when two plausible readings would produce different code.
| Request is about… | Go to | |---|---| | Where code belongs: constructor, PostInitializeComponents, BeginPlay, EndPlay | [Actor Lifecycle](#actor-lifecycle) | | Creating, attaching, activating components | [Component System](#component-system) | | Overriding component hooks (OnRegister, InitializeComponent, TickComponent) | [Component Lifecycle Hooks](#component-lifecycle-hooks) | | SpawnActor, deferred spawn, pooling | [Spawning](#spawning) | | Tick groups, tick interval, prerequisites, tick vs timer | [Ticking](#ticking) | | Cross-actor capability without casting | [Interfaces](#interfaces) | | Splitting a fat actor into components, data-driven loadouts | [Composition Patterns](#composition-patterns) | | Full event order, EEndPlayReason, network and child-actor timing | [references/actor-lifecycle.md](references/actor-lifecycle.md) | | Which built-in component to use, header paths, member APIs | [references/component-types.md](references/component-types.md) |
UObject
└── AActor placeable/spawnable; owns components GameFramework/Actor.h
└── UActorComponent logic only, no transform Components/ActorComponent.h
└── USceneComponent transform + attachment tree Components/SceneComponent.h
└── UPrimitiveComponent rendering + collision + physics Components/PrimitiveComponent.hNever `new`/`delete` an actor or component. Actors: `UWorld::SpawnActor` and `AActor::Destroy(bool bNetForce = false, bool bShouldModifyLevel = true)` (`Actor.h:2327`). Components: `CreateDefaultSubobject`/`NewObject` and `UActorComponent::DestroyComponent(bool bPromoteChildren = false)` (`ActorComponent.h:1328`).
Order from the `AActor` class comment (`Actor.h:243-278`); full table with citations in [references/actor-lifecycle.md](references/actor-lifecycle.md).
AActor::AActor() CDO + every instance. No world. CreateDefaultSubobject, tick config, defaults UObject::PostLoad() level-placed actors only (not spawned) UActorComponent::OnComponentCreated() native components on spawn (not when loaded from a level) AActor::PreRegisterAllComponents() → RegisterComponent() per component → AActor::PostRegisterAllComponents() AActor::PostActorCreated() spawned actors only, before construction scripts UserConstructionScript() → AActor::OnConstruction(const FTransform&) AActor::PreInitializeComponents() gameplay only UActorComponent::Activate() if bAutoActivate UActorComponent::InitializeComponent() if bWantsInitializeComponent, once per session AActor::PostInitializeComponents() components initialized; bind to own components here AActor::BeginPlay() level is ticking; may be delayed for networked or child actors AActor::Tick(float DeltaSeconds) if PrimaryActorTick.bCanEverTick AActor::EndPlay(const EEndPlayReason::Type) base implementation forwards EndPlay to components AActor::Destroyed() explicit Destroy() only; not on level streaming or game end
The constructor runs on the Class Default Object, where `GetWorld()` is `nullptr`. Anything that needs the world or other actors goes in `PostInitializeComponents` (own components) or `BeginPlay` (gameplay).
// MyActor.h
#pragma once
#include "CoreMinimal.h"
#include "GameFramework/Actor.h"
#include "MyActor.generated.h"
class UStaticMeshComponent;
class UMyHealthComponent;
UCLASS()
class MYGAME_API AMyActor : public AActor
{
GENERATED_BODY()
public:
AMyActor();
protected:
virtual void PostInitializeComponents() override;
virtual void BeginPlay() override;
virtual void EndPlay(const EEndPlayReason::Type EndPlayReason) override;
UFUNCTION()
void HandleDeath();
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category="Components")
TObjectPtr<UStaticMeshComponent> MeshComp;
UPROPERTY(VisibleAnywhere, Category="Components")
TObjectPtr<UMyHealthComponent> HealthComp;
};// MyActor.cpp
#include "MyActor.h"
#include "Components/StaticMeshComponent.h"
#include "TimerManager.h"
#include "MyHealthComponent.h"
AMyActor::AMyActor()
{
PrimaryActorTick.bCanEverTick = tA collection of 31 AI agent skills for Unreal Engine C++ development. Built for game developers who want AI coding agents to help write correct, production-quality UE5 C++ code.
Use when writing Unreal Engine C++ AI — AI controllers, behavior tree nodes, blackboards, AI perception, navmesh pathfinding, EQS…
Use when writing or debugging Unreal Engine animation C++: AnimInstance subclasses, thread-safe update, FAnimInstanceProxy,…
Use when offloading work off the game thread, dispatching results back to it, running data-parallel loops, or scheduling timers…
Use when playing, mixing or debugging sound in Unreal Engine — one-shot SFX, looping ambience, music, dialogue or procedural…
Use when exposing C++ to Blueprint or calling Blueprint from C++: UFUNCTION(BlueprintCallable), BlueprintPure,…
Use when writing or debugging UCharacterMovementComponent code: custom movement modes, floor detection, jumping, crouching, root…
Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid…
Design and build AI agents for any domain. Use when users: (1) ask to "create an agent", "build an assistant", or "design an AI…