ue-actor-component-arc…
Use when writing or debugging AActor and UActorComponent C++: constructor vs BeginPlay, PostInitializeComponents, EndPlay…
Use when writing or fixing Unreal Engine UI in C++ — UMG user widgets, Slate widgets, Common UI screens, or MVVM view models. Also use when the user mentions 'UUserWidget', 'NativeConstruct', 'BindWidget', 'CreateWidget', 'AddToViewport', 'ESlateVisibility', 'OnClicked',
Claude Code
$ npx -y skills add quodsoler/unreal-engine-skills --skill ue-ui-umg-slate --agent claude-code
Codex
$ npx skills add quodsoler/unreal-engine-skills --skill ue-ui-umg-slate -a codex -y
Cursor
$ npx skills add quodsoler/unreal-engine-skills --skill ue-ui-umg-slate -a cursor -y
Gemini CLI
$ npx skills add quodsoler/unreal-engine-skills --skill ue-ui-umg-slate -a gemini-cli -y
GitHub Copilot
$ npx skills add quodsoler/unreal-engine-skills --skill ue-ui-umg-slate -a github-copilot -y
OpenCode
$ npx skills add quodsoler/unreal-engine-skills --skill ue-ui-umg-slate -a opencode -y
Windsurf
$ npx skills add quodsoler/unreal-engine-skills --skill ue-ui-umg-slate -a windsurf -y
name: ue-ui-umg-slate description: "Use when writing or fixing Unreal Engine UI in C++ — UMG user widgets, Slate widgets, Common UI screens, or MVVM view models. Also use when the user mentions 'UUserWidget', 'NativeConstruct', 'BindWidget', 'CreateWidget', 'AddToViewport', 'ESlateVisibility', 'OnClicked', 'UListView', 'widget animation', 'SNew', 'SLATE_BEGIN_ARGS', 'SCompoundWidget', 'UCommonActivatableWidget', 'activatable widget stack', 'UCommonButtonBase', 'gamepad focus', 'FUIInputConfig', 'UMVVMViewModelBase', 'FieldNotify', or 'WidgetComponent'. For input modes and Enhanced Input, see ue-input-system; for Slate in editor tooling, see ue-editor-tools." 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".
UMG is the runtime UI framework (`UMG` module, `Engine/Source/Runtime/UMG/Public`) built on Slate (`Slate`, `SlateCore`). Common UI (plugin, production in 5.8) adds cross-platform input routing, activation stacks and platform-aware buttons. Model View Viewmodel (plugin, Beta in 5.8) adds declarative data binding on top of `FieldNotification`.
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 | |---|---| | Widget class, overrides, creation, visibility, GC | [Widget Lifecycle](#widget-lifecycle) | | Wiring designer widgets into C++ (`meta=(BindWidget)`) | [BindWidget](#bindwidget) | | Buttons, text, images, bars, lists | [Widget Interaction](#widget-interaction) | | Playing/stopping UMG animations | [Widget Animation](#widget-animation) | | Mouse cursor, focus, `SetInputMode` | [Input Mode and Focus](#input-mode-and-focus) | | Menus, screen stacks, gamepad, back action | [Common UI](#common-ui) | | Data binding, view models, field notifications | [MVVM](#mvvm) | | UI rendered in the level | [World-Space UI](#world-space-ui) | | Iterating widgets, drag/drop, brushes, geometry | [Widget Tree and Helper Libraries](#widget-tree-and-helper-libraries) | | Custom `SWidget`, `SNew`, `SLATE_BEGIN_ARGS` | [Slate](#slate) |
Per-widget method tables (setters, delegates, enums) live in [references/widget-types.md](references/widget-types.md). Full Common UI plugin setup lives in [references/common-ui-setup.md](references/common-ui-setup.md). A complete custom Slate widget lives in [references/slate-patterns.md](references/slate-patterns.md).
// MyWidget.h
#pragma once
#include "CoreMinimal.h"
#include "Blueprint/UserWidget.h"
#include "MyWidget.generated.h"
class UButton;
UCLASS()
class MYGAME_API UMyWidget : public UUserWidget
{
GENERATED_BODY()
protected:
virtual void NativeOnInitialized() override;
virtual void NativePreConstruct() override;
virtual void NativeConstruct() override;
virtual void NativeDestruct() override;
virtual void NativeTick(const FGeometry& MyGeometry, float InDeltaTime) override;
UPROPERTY(meta=(BindWidget))
TObjectPtr<UButton> PlayButton;
UFUNCTION()
void HandlePlayClicked();
};
// MyWidget.cpp — #include "MyWidget.h" and "Components/Button.h"
void UMyWidget::NativeOnInitialized() { Super::NativeOnInitialized(); }
void UMyWidget::NativePreConstruct() { Super::NativePreConstruct(); }
void UMyWidget::NativeTick(const FGeometry& MyGeometry, float InDeltaTime)
{
Super::NativeTick(MyGeometry, InDeltaTime);
}
void UMyWidget::NativeConstruct()
{
Super::NativeConstruct(); // Runs on every re-add; pair each bind with an unbind in NativeDestruct
PlayButton->OnClicked.AddDynamic(this, &UMyWidget::HandlePlayClicked);
}
void UMyWidget::NativeDestruct()
{
PlayButton->OnClicked.RemoveDynamic(this, &UMyWidget::HandlePlayClicked);
Super::NativeDestruct();
}| Override (verbatim from `Blueprint/UserWidget.h`) | When it runs | |---|---| | `virtual void NativeOnInitialized() override;` | Once per instance, after construction of the widget object | | `virtual void NativePreConstruct() override;` | After the Slate tree is rebuilt, just before `NativeConstruct` (`UserWidget.cpp:1231`); also runs in the Designer | | `virtual void NativeConstruct() override;` | Slate widget added to a parent — bind delegates here | | `virtual void NativeDestruct() override;` | Slate widget removed — unbind here | | `virtual void NativeTick(const FGeometry& MyGeometry, float InDeltaTime) override;` | Per frame while ticking | | `virtual int32 NativePaint(const FPaintArgs& Args, const FGeometry& AllottedGeometry, const FSlateRect& MyCullingRect, FSlateWindowElementList& OutDrawElements, int32 LayerId, const FWidgetStyle& InWidgetStyle, bool bParentEnabled) const override;` | Custom drawing; return the last used layer id | | `virtual FReply NativeOnMouseButtonDown(const FGeometry& InGeometry, const FPointerEvent& InMouseEvent) override;` | Pointer press | | `virtual FReply NativeOnKeyDown(const FGeometry& InGeometry, const FKeyEvent& InKeyEvent) override;` | Key press while focused | | `virtual FReply NativeOnFocusReceived(const FGeometry& InGeometry, const FFocusEvent& InFocusEvent) override;` | This widget gained focus | | `virtual void NativeOnAddedToFocusPath(const FFocusEvent& InFocusEvent) override;` | This widget or a descendant gained focus | | `virtual bool Initialize() override;` | Builds the widget tree; call `Super::Initialize()` and return its result | | `virtual TSharedRef<SWidget> RebuildWidget() override;` | Builds the underlying Slate widget | | `virtual void ReleaseSlateResources(bool bReleaseChildren) override;` | Drop cached `TSharedPtr<SWidget>` members here |
Input handlers return `FReply::Handled()` to consume the event or `FReply::Unhandled()` to let it bubble.
A 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 or debugging AActor and UActorComponent C++: constructor vs BeginPlay, PostInitializeComponents, EndPlay…
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,…
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…