[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M79BVPTK509FVESTCQYAYZVT":3,"skill-same:01M79BVPTK509FVESTCQYAYZVT":48},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":29,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":32,"updatedAt":33,"install":34,"resources":47},"01M79BVPTK509FVESTCQYAYZVT","unreal-engine-cpp-blueprints",null,"Production guidance for Unreal Engine C++ and Blueprints hybrid architecture, UObject memory management, Unreal Smart Pointers, Gameplay Ability System (GAS), Subsystems, Task Graph multithreading, and performance optimization.","hamzabellouch\u002Fagent-skills","hamzabellouch","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F237856042?v=4","01M79BRYW7XAMK3YDWQEMTWGWS","Hamza Bellouch","01M79BRYWXQV3JK2TGVTX8GN2A",8,"MIT","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FArt\u002FGame_Art_and_3D_Interactive\u002Funreal-engine-cpp-blueprints\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: unreal-engine-cpp-blueprints\ndescription: Production guidance for Unreal Engine C++ and Blueprints hybrid architecture, UObject memory management, Unreal Smart Pointers, Gameplay Ability System (GAS), Subsystems, Task Graph multithreading, and performance optimization.\n---\n\n# Unreal Engine C++ & Blueprints Architecture\n\nThis skill guide provides production-grade architectural patterns, memory management protocols, C++\u002FBlueprint boundary rules, frame budget optimization techniques, and multi-threading patterns for Unreal Engine applications.\n\n---\n\n## 1. C++ vs. Blueprint Architectural Boundaries\n\n### 1.1 Division of Responsibilities\nTo maintain performance and maintainability in large scale AAA codebases, follow strict layer isolation:\n\n```\n+-------------------------------------------------------------------+\n|                        Blueprint Layer                            |\n|  - Visual Tweaking & Cosmetic Properties (Materials, FX, Audio)   |\n|  - UI Widget Event Hooks (UMG Data Bindings)                      |\n|  - Level-Specific Scripting & Animation Blueprint Blending        |\n+-------------------------------------------------------------------+\n                                  ^\n                                  | Exposes UPROPERTY \u002F UFUNCTION\n                                  v\n+-------------------------------------------------------------------+\n|                           C++ Engine Layer                        |\n|  - Math & Heavy Computations (Spatial Queries, Pathing, Physics)  |\n|  - Core Data Structures & Base Classes (ACharacter, UActorComponent)|\n|  - Networking & RPC Serialization (Replication Logic)             |\n|  - Subsystems, GAS AttributeSets, and Task Graph Multithreading   |\n+-------------------------------------------------------------------+\n```\n\n### 1.2 Subsystem Architecture\nUnreal Engine Subsystems (`UGameInstanceSubsystem`, `UWorldSubsystem`, `ULocalPlayerSubsystem`) provide managed singletons tied automatically to object lifecycles without manual instance creation or teardown.\n\n### 1.3 Gameplay Ability System (GAS) Setup\nKeep GAS core logic strictly in C++:\n* **`UAbilitySystemComponent`**: Attach via base C++ classes (`ACharacter`).\n* **`UAttributeSet`**: Define all attributes, clamping logic (`PreAttributeChange`, `PostGameplayEffectExecute`), and network replication macros in C++.\n* **`UGameplayAbility`**: Implement complex execution calculations in C++; subclass in Blueprints only for montage timing and FX triggers.\n\n---\n\n## 2. Memory Management & Garbage Collection\n\n### 2.1 UObject Ownership & `UPROPERTY()` GC Sweeps\nUnreal Engine uses a reflection-driven Garbage Collection system. Any `UObject` raw pointer **must** be tracked by the GC framework, otherwise it risks premature collection or dangling pointer crashes.\n\n```cpp\n\u002F\u002F CRITICAL: Prevent GC sweep of instantiated UObject\nUPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = \"Inventory\")\nTObjectPtr\u003CUInventoryItemAsset> CachedItem;\n```\n\n### 2.2 Unreal Smart Pointers vs UObject Weak References\n\n| Pointer Type | Target Object Type | Use Case | GC Tracked? |\n| :--- | :--- | :--- | :--- |\n| `TObjectPtr\u003CT>` | `UObject` subclasses | Standard member variables in headers. | Yes (`UPROPERTY`) |\n| `TWeakObjectPtr\u003CT>` | `UObject` subclasses | Non-owning reference to UObjects (prevents circular retention). | No (GC-safe query) |\n| `TSharedPtr\u003CT>` | Non-`UObject` C++ structs | Engine-agnostic C++ data structures. | Ref-counted |\n| `TSharedRef\u003CT>` | Non-`UObject` C++ structs | Non-nullable shared pointer reference. | Ref-counted |\n| `TUniquePtr\u003CT>` | Non-`UObject` C++ structs | Exclusive ownership raw C++ memory management. | Manual \u002F Scope |\n\n### 2.3 Container Allocation Strategy & Slack Management\nUnreal's `TArray\u003CT>` dynamically reallocates memory upon expansion. Avoid heap fragmentation during execution loops:\n\n```cpp\n\u002F\u002F Reserve slack before populating large arrays\nTArray\u003CFVector> PathNodes;\nPathNodes.Reserve(1000); \u002F\u002F Allocates memory block upfront\n\n\u002F\u002F Fast clear without freeing allocated memory block for frame reuse\nPathNodes.Reset(); \u002F\u002F Keeps memory slack intact\n\u002F\u002F PathNodes.Empty(); \u002F\u002F WRONG: Frees memory block to heap!\n```\n\n---\n\n## 3. Frame Budget & Multithreading\n\n### 3.1 Tick Management & Optimization Rules\nBy default, `AActor::Tick` is enabled, causing high overhead across thousands of actors.\n\n1. **Disable Unnecessary Ticks**: Set `PrimaryActorTick.bCanEverTick = false;` in constructor.\n2. **Tick Interval**: For non-critical logic, set `PrimaryActorTick.TickInterval = 0.1f;` (10Hz instead of frame-rate).\n3. **Tick Groups**: Assign tick dependency groups (`TG_PrePhysics`, `TG_DuringPhysics`, `TG_PostPhysics`) to ensure data availability without frame stalls.\n\n### 3.2 Threading with Task Graph & ParallelFor\nFor heavy compute tasks (e.g., procedural mesh generation, pathing algorithms), offload work from the Game Thread:\n\n```cpp\n\u002F\u002F Multi-threaded loop execution across CPU worker threads\nParallelFor(1000, [](int32 Index)\n{\n    \u002F\u002F Thread-safe math operations on non-UObject data arrays\n    ProcessRaycastPoint(Index);\n});\n```\n\n---\n\n## 4. Production Code Examples\n\n### 4.1 Production UGameInstanceSubsystem with Async Soft Loading\nA production manager tracking game state and asynchronously loading data assets using soft object references (`TSoftObjectPtr`):\n\n#### `InventorySubsystem.h`\n```cpp\n#pragma once\n\n#include \"CoreMinimal.h\"\n#include \"Subsystems\u002FGameInstanceSubsystem.h\"\n#include \"Engine\u002FStreamableManager.h\"\n#include \"InventorySubsystem.generated.h\"\n\nDECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FOnItemLoadedDelegate, UPrimaryDataAsset*, LoadedAsset);\n\nUCLASS()\nclass GAMEENGINE_API UInventorySubsystem : public UGameInstanceSubsystem\n{\n    GENERATED_BODY()\n\npublic:\n    virtual void Initialize(FSubsystemCollectionBase& Collection) override;\n    virtual void Deinitialize() override;\n\n    UFUNCTION(BlueprintCallable, Category = \"Inventory\")\n    void RequestAsyncAssetLoad(TSoftObjectPtr\u003CUPrimaryDataAsset> AssetToLoad);\n\n    UPROPERTY(BlueprintAssignable, Category = \"Inventory\")\n    FOnItemLoadedDelegate OnItemLoaded;\n\nprivate:\n    void OnAssetLoadComplete(TSoftObjectPtr\u003CUPrimaryDataAsset> LoadedSoftPtr);\n\n    FStreamableManager StreamableManager;\n};\n```\n\n#### `InventorySubsystem.cpp`\n```cpp\n#include \"InventorySubsystem.h\"\n#include \"Engine\u002FAssetManager.h\"\n\nvoid UInventorySubsystem::Initialize(FSubsystemCollectionBase& Collection)\n{\n    Super::Initialize(Collection);\n}\n\nvoid UInventorySubsystem::Deinitialize()\n{\n    Super::Deinitialize();\n}\n\nvoid UInventorySubsystem::RequestAsyncAssetLoad(TSoftObjectPtr\u003CUPrimaryDataAsset> AssetToLoad)\n{\n    if (AssetToLoad.IsNull())\n    {\n        return;\n    }\n\n    if (AssetToLoad.IsValid())\n    {\n        \u002F\u002F Already in memory\n        OnItemLoaded.Broadcast(AssetToLoad.Get());\n        return;\n    }\n\n    \u002F\u002F Initiate async streamable load\n    FSoftObjectPath AssetPath = AssetToLoad.ToSoftObjectPath();\n    StreamableManager.RequestAsyncLoad(\n        AssetPath,\n        FStreamableDelegate::CreateUObject(this, &UInventorySubsystem::OnAssetLoadComplete, AssetToLoad)\n    );\n}\n\nvoid UInventorySubsystem::OnAssetLoadComplete(TSoftObjectPtr\u003CUPrimaryDataAsset> LoadedSoftPtr)\n{\n    if (LoadedSoftPtr.IsValid())\n    {\n        OnItemLoaded.Broadcast(LoadedSoftPtr.Get());\n    }\n}\n```\n\n### 4.2 Thread-Safe C++ Task Graph Execution\nScheduling background jobs using `FFunctionGraphTask`:\n\n```cpp\n#include \"Async\u002FTaskGraphInterfaces.h\"\n\nvoid AGameSpatialGrid::ComputeGridAsync()\n{\n    \u002F\u002F Capture data by value\u002Fshared ptr for thread safety\n    TSharedPtr\u003CTArray\u003CFVector>, ESPMode::ThreadSafe> InputData = MakeShared\u003CTArray\u003CFVector>, ESPMode::ThreadSafe>();\n    InputData->Reserve(5000);\n\n    FFunctionGraphTask::CreateAndDispatchWhenReady([InputData]()\n    {\n        \u002F\u002F Executed on Background Worker Thread\n        for (int32 i = 0; i \u003C 5000; ++i)\n        {\n            InputData->Add(FVector(i * 10.0f, i * 20.0f, 0.0f));\n        }\n\n        \u002F\u002F Return back to Game Thread for application to UObjects\n        FFunctionGraphTask::CreateAndDispatchWhenReady([InputData]()\n        {\n            \u002F\u002F Executed back on Main Game Thread\n            GEngine->AddOnScreenDebugMessage(-1, 5.f, FColor::Green, \n                FString::Printf(TEXT(\"Async Compute Complete: %d elements\"), InputData->Num()));\n        }, TStatId(), nullptr, ENamedThreads::GameThread);\n\n    }, TStatId(), nullptr, ENamedThreads::AnyBackgroundThreadNormalTask);\n}\n```\n\n### 4.3 Robust C++ Base Class with Blueprint Native Events\n\n```cpp\n#pragma once\n\n#include \"CoreMinimal.h\"\n#include \"GameFramework\u002FActor.h\"\n#include \"InteractableInterface.h\"\n#include \"BaseInteractable.generated.h\"\n\nUCLASS(Abstract, Blueprintable)\nclass GAMEENGINE_API ABaseInteractable : public AActor, public IInteractableInterface\n{\n    GENERATED_BODY()\n    \npublic:\t\n    ABaseInteractable();\n\n    \u002F\u002F BlueprintNativeEvent provides C++ default implementation with Blueprint override capability\n    UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = \"Interaction\")\n    bool ExecuteInteraction(APawn* InteractingPawn);\n    virtual bool ExecuteInteraction_Implementation(APawn* InteractingPawn);\n\nprotected:\n    UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = \"Interaction\")\n    FText InteractionPrompt;\n};\n```\n\n---\n\n## 5. Anti-Patterns & Critical Pitfalls\n\n### ❌ Anti-Pattern 1: Un-Reflected UObject Raw Pointers\n```cpp\n\u002F\u002F WRONG: Missing UPROPERTY() causes Garbage Collector to delete object mid-gameplay\nclass AMyCharacter : public ACharacter\n{\n    UEnemyManager* EnemyManager; \u002F\u002F Raw un-tracked pointer! DANGER!\n};\n\n\u002F\u002F RIGHT: Always wrap with UPROPERTY() or TWeakObjectPtr\nclass AMyCharacter : public ACharacter\n{\n    UPROPERTY()\n    TObjectPtr\u003CUEnemyManager> EnemyManager;\n};\n```\n\n### ❌ Anti-Pattern 2: Hard Object References in Class Headers\n```cpp\n\u002F\u002F WRONG: Hard asset references cause full dependency trees to load synchronously into memory\nUPROPERTY(EditAnywhere)\nUTexture2D* HeavyBossTexture; \u002F\u002F Synchronously loaded on parent load!\n\n\u002F\u002F RIGHT: Use TSoftObjectPtr for lazy\u002Fasync loading\nUPROPERTY(EditAnywhere)\nTSoftObjectPtr\u003CUTexture2D> HeavyBossTexture;\n```\n\n### ❌ Anti-Pattern 3: Heavy Logic inside Blueprint Tick\nPlacing raycasts, string operations, or `GetAllActorsOfClass` in Blueprint `Event Tick` will ruin frame performance. Migrate heavy logic to C++ async tasks, custom timers (`FTimerManager`), or event-driven delegates.\n---\n","# Unreal Engine C++ & Blueprints Architecture\n\nThis skill guide provides production-grade architectural patterns, memory management protocols, C++\u002FBlueprint boundary rules, frame budget optimization techniques, and multi-threading patterns for Unreal Engine applications.\n\n---\n\n## 1. C++ vs. Blueprint Architectural Boundaries\n\n### 1.1 Division of Responsibilities\nTo maintain performance and maintainability in large scale AAA codebases, follow strict layer isolation:\n\n```\n+-------------------------------------------------------------------+\n|                        Blueprint Layer                            |\n|  - Visual Tweaking & Cosmetic Properties (Materials, FX, Audio)   |\n|  - UI Widget Event Hooks (UMG Data Bindings)                      |\n|  - Level-Specific Scripting & Animation Blueprint Blending        |\n+-------------------------------------------------------------------+\n                                  ^\n                                  | Exposes UPROPERTY \u002F UFUNCTION\n                                  v\n+-------------------------------------------------------------------+\n|                           C++ Engine Layer                        |\n|  - Math & Heavy Computations (Spatial Queries, Pathing, Physics)  |\n|  - Core Data Structures & Base Classes (ACharacter, UActorComponent)|\n|  - Networking & RPC Serialization (Replication Logic)             |\n|  - Subsystems, GAS AttributeSets, and Task Graph Multithreading   |\n+-------------------------------------------------------------------+\n```\n\n### 1.2 Subsystem Architecture\nUnreal Engine Subsystems (`UGameInstanceSubsystem`, `UWorldSubsystem`, `ULocalPlayerSubsystem`) provide managed singletons tied automatically to object lifecycles without manual instance creation or teardown.\n\n### 1.3 Gameplay Ability System (GAS) Setup\nKeep GAS core logic strictly in C++:\n* **`UAbilitySystemComponent`**: Attach via base C++ classes (`ACharacter`).\n* **`UAttributeSet`**: Define all attributes, clamping logic (`PreAttributeChange`, `PostGameplayEffectExecute`), and network replication macros in C++.\n* **`UGameplayAbility`**: Implement complex execution calculations in C++; subclass in Blueprints only for montage timing and FX triggers.\n\n---\n\n## 2. Memory Management & Garbage Collection\n\n### 2.1 UObject Ownership & `UPROPERTY()` GC Sweeps\nUnreal Engine uses a reflection-driven Garbage Collection system. Any `UObject` raw pointer **must** be tracked by the GC framework, otherwise it risks premature collection or dangling pointer crashes.\n\n```cpp\n\u002F\u002F CRITICAL: Prevent GC sweep of instantiated UObject\nUPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = \"Inventory\")\nTObjectPtr\u003CUInventoryItemAsset> CachedItem;\n```\n\n### 2.2 Unreal Smart Pointers vs UObject Weak References\n\n| Pointer Type | Target Object Type | Use Case | GC Tracked? |\n| :--- | :--- | :--- | :--- |\n| `TObjectPtr\u003CT>` | `UObject` subclasses | Standard member variables in headers. | Yes (`UPROPERTY`) |\n| `TWeakObjectPtr\u003CT>` | `UObject` subclasses | Non-owning reference to UObjects (prevents circular retention). | No (GC-safe query) |\n| `TSharedPtr\u003CT>` | Non-`UObject` C++ structs | Engine-agnostic C++ data structures. | Ref-counted |\n| `TSharedRef\u003CT>` | Non-`UObject` C++ structs | Non-nullable shared pointer reference. | Ref-counted |\n| `TUniquePtr\u003CT>` | Non-`UObject` C++ structs | Exclusive ownership raw C++ memory management. | Manual \u002F Scope |\n\n### 2.3 Container Allocation Strategy & Slack Management\nUnreal's `TArray\u003CT>` dynamically reallocates memory upon expansion. Avoid heap fragmentation during execution loops:\n\n```cpp\n\u002F\u002F Reserve slack before populating large arrays\nTArray\u003CFVector> PathNodes;\nPathNodes.Reserve(1000); \u002F\u002F Allocates memory block upfront\n\n\u002F\u002F Fast clear without freeing allocated memory block for frame reuse\nPathNodes.Reset(); \u002F\u002F Keeps memory slack intact\n\u002F\u002F PathNodes.Empty(); \u002F\u002F WRONG: Frees memory block to heap!\n```\n\n---\n\n## 3. Frame Budget & Multithreading\n\n### 3.1 Tick Management & Optimization Rules\nBy default, `AActor::Tick` is enabled, causing high overhead across thousands of actors.\n\n1. **Disable Unnecessary Ticks**: Set `PrimaryActorTick.bCanEverTick = false;` in constructor.\n2. **Tick Interval**: For non-critical logic, set `PrimaryActorTick.TickInterval = 0.1f;` (10Hz instead of frame-rate).\n3. **Tick Groups**: Assign tick dependency groups (`TG_PrePhysics`, `TG_DuringPhysics`, `TG_PostPhysics`) to ensure data availability without frame stalls.\n\n### 3.2 Threading with Task Graph & ParallelFor\nFor heavy compute tasks (e.g., procedural mesh generation, pathing algorithms), offload work from the Game Thread:\n\n```cpp\n\u002F\u002F Multi-threaded loop execution across CPU worker threads\nParallelFor(1000, [](int32 Index)\n{\n    \u002F\u002F Thread-safe math operations on non-UObject data arrays\n    ProcessRaycastPoint(Index);\n});\n```\n\n---\n\n## 4. Production Code Examples\n\n### 4.1 Production UGameInstanceSubsystem with Async Soft Loading\nA production manager tracking game state and asynchronously loading data assets using soft object references (`TSoftObjectPtr`):\n\n#### `InventorySubsystem.h`\n```cpp\n#pragma once\n\n#include \"CoreMinimal.h\"\n#include \"Subsystems\u002FGameInstanceSubsystem.h\"\n#include \"Engine\u002FStreamableManager.h\"\n#include \"InventorySubsystem.generated.h\"\n\nDECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FOnItemLoadedDelegate, UPrimaryDataAsset*, LoadedAsset);\n\nUCLASS()\nclass GAMEENGINE_API UInventorySubsystem : public UGameInstanceSubsystem\n{\n    GENERATED_BODY()\n\npublic:\n    virtual void Initialize(FSubsystemCollectionBase& Collection) override;\n    virtual void Deinitialize() override;\n\n    UFUNCTION(BlueprintCallable, Category = \"Inventory\")\n    void RequestAsyncAssetLoad(TSoftObjectPtr\u003CUPrimaryDataAsset> AssetToLoad);\n\n    UPROPERTY(BlueprintAssignable, Category = \"Inventory\")\n    FOnItemLoadedDelegate OnItemLoaded;\n\nprivate:\n    void OnAssetLoadComplete(TSoftObjectPtr\u003CUPrimaryDataAsset> LoadedSoftPtr);\n\n    FStreamableManager StreamableManager;\n};\n```\n\n#### `InventorySubsystem.cpp`\n```cpp\n#include \"InventorySubsystem.h\"\n#include \"Engine\u002FAssetManager.h\"\n\nvoid UInventorySubsystem::Initialize(FSubsystemCollectionBase& Collection)\n{\n    Super::Initialize(Collection);\n}\n\nvoid UInventorySubsystem::Deinitialize()\n{\n    Super::Deinitialize();\n}\n\nvoid UInventorySubsystem::RequestAsyncAssetLoad(TSoftObjectPtr\u003CUPrimaryDataAsset> AssetToLoad)\n{\n    if (AssetToLoad.IsNull())\n    {\n        return;\n    }\n\n    if (AssetToLoad.IsValid())\n    {\n        \u002F\u002F Already in memory\n        OnItemLoaded.Broadcast(AssetToLoad.Get());\n        return;\n    }\n\n    \u002F\u002F Initiate async streamable load\n    FSoftObjectPath AssetPath = AssetToLoad.ToSoftObjectPath();\n    StreamableManager.RequestAsyncLoad(\n        AssetPath,\n        FStreamableDelegate::CreateUObject(this, &UInventorySubsystem::OnAssetLoadComplete, AssetToLoad)\n    );\n}\n\nvoid UInventorySubsystem::OnAssetLoadComplete(TSoftObjectPtr\u003CUPrimaryDataAsset> LoadedSoftPtr)\n{\n    if (LoadedSoftPtr.IsValid())\n    {\n        OnItemLoaded.Broadcast(LoadedSoftPtr.Get());\n    }\n}\n```\n\n### 4.2 Thread-Safe C++ Task Graph Execution\nScheduling background jobs using `FFunctionGraphTask`:\n\n```cpp\n#include \"Async\u002FTaskGraphInterfaces.h\"\n\nvoid AGameSpatialGrid::ComputeGridAsync()\n{\n    \u002F\u002F Capture data by value\u002Fshared ptr for thread safety\n    TSharedPtr\u003CTArray\u003CFVector>, ESPMode::ThreadSafe> InputData = MakeShared\u003CTArray\u003CFVector>, ESPMode::ThreadSafe>();\n    InputData->Reserve(5000);\n\n    FFunctionGraphTask::CreateAndDispatchWhenReady([InputData]()\n    {\n        \u002F\u002F Executed on Background Worker Thread\n        for (int32 i = 0; i \u003C 5000; ++i)\n        {\n            InputData->Add(FVector(i * 10.0f, i * 20.0f, 0.0f));\n        }\n\n        \u002F\u002F Return back to Game Thread for application to UObjects\n        FFunctionGraphTask::CreateAndDispatchWhenReady([InputData]()\n        {\n            \u002F\u002F Executed back on Main Game Thread\n            GEngine->AddOnScreenDebugMessage(-1, 5.f, FColor::Green, \n                FString::Printf(TEXT(\"Async Compute Complete: %d elements\"), InputData->Num()));\n        }, TStatId(), nullptr, ENamedThreads::GameThread);\n\n    }, TStatId(), nullptr, ENamedThreads::AnyBackgroundThreadNormalTask);\n}\n```\n\n### 4.3 Robust C++ Base Class with Blueprint Native Events\n\n```cpp\n#pragma once\n\n#include \"CoreMinimal.h\"\n#include \"GameFramework\u002FActor.h\"\n#include \"InteractableInterface.h\"\n#include \"BaseInteractable.generated.h\"\n\nUCLASS(Abstract, Blueprintable)\nclass GAMEENGINE_API ABaseInteractable : public AActor, public IInteractableInterface\n{\n    GENERATED_BODY()\n    \npublic:\t\n    ABaseInteractable();\n\n    \u002F\u002F BlueprintNativeEvent provides C++ default implementation with Blueprint override capability\n    UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category = \"Interaction\")\n    bool ExecuteInteraction(APawn* InteractingPawn);\n    virtual bool ExecuteInteraction_Implementation(APawn* InteractingPawn);\n\nprotected:\n    UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = \"Interaction\")\n    FText InteractionPrompt;\n};\n```\n\n---\n\n## 5. Anti-Patterns & Critical Pitfalls\n\n### ❌ Anti-Pattern 1: Un-Reflected UObject Raw Pointers\n```cpp\n\u002F\u002F WRONG: Missing UPROPERTY() causes Garbage Collector to delete object mid-gameplay\nclass AMyCharacter : public ACharacter\n{\n    UEnemyManager* EnemyManager; \u002F\u002F Raw un-tracked pointer! DANGER!\n};\n\n\u002F\u002F RIGHT: Always wrap with UPROPERTY() or TWeakObjectPtr\nclass AMyCharacter : public ACharacter\n{\n    UPROPERTY()\n    TObjectPtr\u003CUEnemyManager> EnemyManager;\n};\n```\n\n### ❌ Anti-Pattern 2: Hard Object References in Class Headers\n```cpp\n\u002F\u002F WRONG: Hard asset references cause full dependency trees to load synchronously into memory\nUPROPERTY(EditAnywhere)\nUTexture2D* HeavyBossTexture; \u002F\u002F Synchronously loaded on parent load!\n\n\u002F\u002F RIGHT: Use TSoftObjectPtr for lazy\u002Fasync loading\nUPROPERTY(EditAnywhere)\nTSoftObjectPtr\u003CUTexture2D> HeavyBossTexture;\n```\n\n### ❌ Anti-Pattern 3: Heavy Logic inside Blueprint Tick\nPlacing raycasts, string operations, or `GetAllActorsOfClass` in Blueprint `Event Tick` will ruin frame performance. Migrate heavy logic to C++ async tasks, custom timers (`FTimerManager`), or event-driven delegates.\n---\n",{"name":5,"description":7},"main","e905af21e5f1e1c3ca605e9656c3a7930360a84e","Art\u002FGame_Art_and_3D_Interactive\u002Funreal-engine-cpp-blueprints",1,"https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills","https:\u002F\u002Fhamzabellouch.github.io\u002F","https:\u002F\u002Fgithub.com\u002Fhamzabellouch","hamzabellouch.github.io","CEO & Founder of @tknoglobal | Researcher in Technology & Applied Sciences.","2026-10-17 03:20:19",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":46},[36,39,42],{"tool":37,"command":38},"npx","npx skills add hamzabellouch\u002Fagent-skills --skill unreal-engine-cpp-blueprints",{"tool":40,"command":41},"bunx","bunx skills add hamzabellouch\u002Fagent-skills --skill unreal-engine-cpp-blueprints",{"tool":43,"command":44},"pnpm","pnpm dlx skills add hamzabellouch\u002Fagent-skills --skill unreal-engine-cpp-blueprints","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FArt\u002FGame_Art_and_3D_Interactive\u002Funreal-engine-cpp-blueprints\u002FSKILL.md",true,[],[49,56,63,70,77,84],{"skillNo":50,"name":51,"nameZh":6,"description":52,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":53,"categories":54,"keywords":55,"publishedAt":19},"01M79FHH2H815A9TAP6WNKH4Q8","security-audit","Comprehensive security guidance, source code audit, vulnerability assessment, and penetration test review for codebases, APIs, microservices, CLI tools, libraries, and LLM-backed applications. Triggers on requests to audit a codebase, conduct security reviews, find vulnerabilities or flaws, pen-test source code, or when the user asks in Arabic (فحص أمني، تدقيق الكود أمنياً، مراجعة الثغرات، فحص أمان المشروع). Supports Guidance mode (focused review) and Full Audit mode (deterministic 6-phase harness).","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FSecurity_Audit_and_Code_Review\u002Fsecurity-audit\u002FSKILL.md",[],[],{"skillNo":57,"name":58,"nameZh":6,"description":59,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":60,"categories":61,"keywords":62,"publishedAt":19},"01M79FHBGXVBY6VQ1X7ETAZMF1","malware-analysis-reversing","Production malware analysis workflows, reverse engineering methodologies, isolated sandbox triage, static\u002Fdynamic binary analysis, memory forensics, and YARA detection rule authoring.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FOffensive_Security_and_Pentesting\u002Fmalware-analysis-reversing\u002FSKILL.md",[],[],{"skillNo":64,"name":65,"nameZh":6,"description":66,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":67,"categories":68,"keywords":69,"publishedAt":19},"01M79FH6EACDR801TZCE4R8SAC","application-security-pentesting","Production Application Security (AppSec) standards, OWASP Top 10 vulnerability remediation, SAST\u002FDAST pipeline integration, secure code review, threat modeling, and defensive security posture.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FOffensive_Security_and_Pentesting\u002Fapplication-security-pentesting\u002FSKILL.md",[],[],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":74,"categories":75,"keywords":76,"publishedAt":19},"01M79FH0VKVT44FK923K520ZQA","oauth2-oidc-security-flows","Implement enterprise OAuth 2.1 and OpenID Connect (OIDC) authorization code flow with Proof Key for Code Exchange (PKCE), state and nonce verification, refresh token rotation, token revocation, and centralized IdP federation (Keycloak, Auth0, Okta). Trigger when building secure authentication, single sign-on (SSO), or third-party delegated authorization.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FIdentity_and_Access_Management_IAM\u002Foauth2-oidc-security-flows\u002FSKILL.md",[],[],{"skillNo":78,"name":79,"nameZh":6,"description":80,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":81,"categories":82,"keywords":83,"publishedAt":19},"01M79FGVVB3R4T88XXD8FRSV5B","jwt-session-management-hardening","Harden JWT-based authentication and session lifecycles using asymmetric signing (RS256\u002FEdDSA), JWKS rotation, strict claims validation, Redis-backed sliding window sessions, revocation lists, and secure HttpOnly cookie storage. Trigger when implementing token validation, session revocation, or hardening API authentication.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FIdentity_and_Access_Management_IAM\u002Fjwt-session-management-hardening\u002FSKILL.md",[],[],{"skillNo":85,"name":86,"nameZh":6,"description":87,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":88,"categories":89,"keywords":90,"publishedAt":19},"01M79FGNCPZ85CVEY0B3NE4H3B","soc2-compliance-automation","Best practices for implementing SOC 2 Type II compliance controls, continuous evidence collection, infrastructure policy-as-code, and automated security monitoring. Use when automating Trust Services Criteria (Security, Availability, Confidentiality, Processing Integrity, Privacy), audit logging, IAM least privilege, or CI\u002FCD security gates.","https:\u002F\u002Fgithub.com\u002Fhamzabellouch\u002Fagent-skills\u002Fblob\u002Fmain\u002FSecurity\u002FGovernance_Compliance_and_Legal_Tech\u002Fsoc2-compliance-automation\u002FSKILL.md",[],[]]