ue-actors-and-components

Build and compose Unreal Engine gameplay objects from Actors and Components in C++.

55|5|Updated Mar 26, 2026
One-click install
npx skills add https://github.com/kevinpbuckley/unreal-engine-skills --skill ue-actors-and-components-kevinpbuckley
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ue-actors-and-components
Source: https://github.com/kevinpbuckley/unreal-engine-skills/tree/main/skills/core/ue-actors-and-components
Command: npx skills add https://github.com/kevinpbuckley/unreal-engine-skills --skill ue-actors-and-components-kevinpbuckley

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Writing correct Unreal C++ gameplay objects requires knowing the AActor lifecycle order, the component type hierarchy, and the rules for spawning, attachment, and registration — mistakes like putting gameplay logic in the constructor or forgetting RegisterComponent cause silent, hard-to-debug failures. ## Core Features & Use Cases - Lifecycle guidance: Covers the full AActor sequence (constructor, PostInitializeComponents, BeginPlay, Tick, EndPlay) and the three creation paths (load, PIE, spawn), with verified UE 5.8 source citations. - Component composition: Explains UActorComponent vs USceneComponent vs UPrimitiveComponent, root component selection, attachment rules, sockets, and mobility. - Spawning and runtime components: Details SpawnActor variants, FActorSpawnParameters, deferred spawn, collision handling, and runtime component registration. - Use Case: You need to create a pickup actor with a sphere trigger and mesh, bind an overlap event, and spawn it at runtime with pre-configured damage values — the skill provides the exact class structure, delegate signature, and deferred-spawn pattern. ## Quick Start Use the ue-actors-and-components skill to create a new AActor subclass with a collision root component and an attached static mesh that binds an overlap event in BeginPlay.

Frequently Asked Questions about ue-actors-and-components

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create an Actor with components in Unreal C++?

Subclass AActor, declare component pointers as UPROPERTY TObjectPtr members, and create them in the constructor with CreateDefaultSubobject. Set one USceneComponent as the root with SetRootComponent and attach others with SetupAttachment.

How do I spawn an actor at runtime in Unreal Engine?

Call GetWorld()->SpawnActor with a TSubclassOf class, transform, and FActorSpawnParameters. Use SpawnActorDeferred plus FinishSpawning when the actor needs properties set before BeginPlay runs.

What is the difference between UActorComponent, USceneComponent, and UPrimitiveComponent?

UActorComponent is pure behavior with no transform. USceneComponent adds a transform and attachment support. UPrimitiveComponent adds rendering and collision, creating both render and physics state by default.

Why is my overlap event not firing in Unreal Engine?

The handler must be a UFUNCTION with the exact delegate signature, bound via AddDynamic. Both components also need collision enabled, SetGenerateOverlapEvents(true), and overlapping collision responses.

Why does my runtime-created component not render or tick?

Components created with NewObject during play must call RegisterComponent to associate with the world. Without registration the component will not update, render, or collide.

Should gameplay logic go in the constructor or BeginPlay?

Put gameplay logic in BeginPlay. The constructor also runs on the Class Default Object and in the editor with no world, so spawning, timers, and delegate binding there fail or behave unpredictably.