coding-standards

Write Unreal Engine C++ code conforming to Epic's official coding standard.

1|Updated Sep 6, 2026
One-click install
npx skills add https://github.com/ziyarduc/Baran-bk-game --skill coding-standards-ziyarduc
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: coding-standards
Source: https://github.com/ziyarduc/Baran-bk-game/tree/main/.agents/skills/coding-standards
Command: npx skills add https://github.com/ziyarduc/Baran-bk-game --skill coding-standards-ziyarduc

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Unreal Engine C++ code that ignores Epic's conventions causes UHT compile errors, inconsistent naming across a codebase, and unorganized editor panels. This Skill enforces the official Epic coding standard so every header, class, and member reads like engine code and compiles cleanly through UnrealHeaderTool. ## Core Features & Use Cases - Type Prefix Enforcement: Applies mandatory U/A/F/E/I/T/S prefixes, PascalCase naming, the bBool convention, and enum class style that UHT requires for reflected types. - Header & Include Structure: Standardizes #pragma once, include order with generated.h last, IWYU discipline, forward declarations, and MODULE_API export macros. - Reflection & Modern C++ Rules: Covers UPROPERTY/UFUNCTION specifiers with Category, TObjectPtr for UObject members, const correctness, nullptr/override usage, and TEXT() string literals. - Use Case: When writing a new ABRCharacter class for a Battle Royale project, the Skill ensures the BR prefix, GENERATED_BODY(), correct UCLASS specifiers, and proper include ordering are all applied before compilation. ## Quick Start Review my new Unreal C++ actor class and rewrite it to conform to Epic's coding standard with correct prefixes, includes, and UPROPERTY specifiers.

Frequently Asked Questions about coding-standards

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

FAQPage Schema
How do I name classes and variables in Unreal Engine C++?▼

Unreal C++ uses mandatory type prefixes: U for UObject subclasses, A for actors, F for structs, E for enums, I for interfaces, T for templates, and S for Slate widgets. All identifiers use PascalCase, booleans carry a b prefix like bIsDead, and functions returning bool ask a question like IsAlive().

What is the correct include order for Unreal Engine headers?▼

Headers start with #pragma once, then CoreMinimal.h, then engine or module headers, with the generated.h include always last because UHT requires it. Source files include their matching header first, then implementation dependencies, following Include-What-You-Use discipline.

Why does UnrealHeaderTool fail with type prefix errors?▼

UHT enforces prefix rules for reflected types, so a UObject subclass missing the U prefix or an actor missing the A prefix is a compile error. Other common causes are generated.h not being the last include, missing GENERATED_BODY(), or reflected types declared inside a namespace.

Should I use TObjectPtr or raw pointers for UPROPERTY members?▼

Use TObjectPtr<T> for UPROPERTY members holding UObject-derived pointers in UE5, as it provides access tracking in editor builds and is the modern form. Raw T* pointers still compile and appear in legacy engine code, but new code should prefer TObjectPtr.

When should I use forward declarations instead of includes in Unreal?▼

Forward declare types in headers when you only need a pointer or reference, then include the full header in the .cpp file. This reduces compile times and dependency coupling, following the IWYU pattern used throughout engine headers like ActorComponent.h.