---
name: unreal-cpp
description: Unreal Engine C++ programming skill for UCLASS macros, reflection system, garbage collection, and engine integration.
allowed-tools: Read, Grep, Write, Bash, Edit, Glob, WebFetch
graph:
  domains: [domain:gaming]
  specializations: [specialization:game-development]
  skillAreas: [skill-area:game-engines, skill-area:gameplay-programming]
  roles: [role:game-developer]
---

# Unreal C++ Skill

C++ programming for Unreal Engine development.

## Overview

This skill provides capabilities for implementing Unreal Engine gameplay and systems using C++, including the reflection system, macros, and engine integration.

## Capabilities

### UCLASS System
- Implement UCLASS macros
- Handle UPROPERTY specifiers
- Create UFUNCTION methods
- Manage USTRUCT types

### Memory Management
- Use smart pointers
- Handle garbage collection
- Manage object lifecycles
- Implement weak references

### Engine Integration
- Create Actor classes
- Implement Components
- Handle Subsystems
- Create Plugins

### Blueprint Exposure
- Expose C++ to Blueprint
- Handle BlueprintCallable
- Implement BlueprintNativeEvent
- Create Blueprint Function Libraries

## Prerequisites

- Unreal Engine 5.0+
- Visual Studio 2022 / Rider
- C++ programming knowledge

## Usage Patterns

### Actor Class

```cpp
UCLASS()
class MYGAME_API AMyCharacter : public ACharacter
{
    GENERATED_BODY()

public:
    AMyCharacter();

    UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Stats")
    float Health = 100.f;

    UFUNCTION(BlueprintCallable, Category = "Combat")
    void TakeDamage(float Damage);

protected:
    virtual void BeginPlay() override;
    virtual void Tick(float DeltaTime) override;
};
```

### Component

```cpp
UCLASS(ClassGroup=(Custom), meta=(BlueprintSpawnableComponent))
class MYGAME_API UHealthComponent : public UActorComponent
{
    GENERATED_BODY()

public:
    UPROPERTY(BlueprintAssignable)
    FOnHealthChanged OnHealthChanged;

    UFUNCTION(BlueprintCallable)
    void ModifyHealth(float Delta);

private:
    UPROPERTY(EditDefaultsOnly)
    float MaxHealth = 100.f;

    float CurrentHealth;
};
```

## Best Practices

1. Use UPROPERTY for GC visibility
2. Forward declare where possible
3. Use interfaces for decoupling
4. Profile with Unreal Insights
5. Follow Unreal coding standards

## References

- [Unreal C++ Documentation](https://docs.unrealengine.com/5.0/en-US/programming-with-cplusplus-in-unreal-engine/)


---
Source attribution: a5c-ai
Original project: https://github.com/a5c-ai/babysitter
License: MIT
License information: https://opensource.org/license/mit
Original upstream instructions; downloaded from Mega AI Hub.

## Upstream license notice

MIT License

Copyright (c) 2026 Gabriel Moreira

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.



# Mega AI Hub resource metadata

Creator / publisher: a5c-ai
Original project: https://github.com/a5c-ai/babysitter
Attribution basis: Upstream repository explicitly recorded in package mirror path

Fields of work: Development & Engineering
Roles: Backend Developer, Frontend Developer, Game Developer
Specialties: Backend
Tools: Unreal Engine, Visual Studio
Country applicability: Country not specified
Classification basis: Source catalog labels
Instruction SHA-256: bddfbf6903345f0e4068ba7b6efe3f3d2441b7e3785462ac12d84b735d423d41
