MCPcopy Create free account
hub / github.com/arnaud-jamin/Cog

github.com/arnaud-jamin/Cog @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
5,111 symbols 11,152 edges 353 files 2,223 documented · 43% updated 3mo ago★ 5983 open issues

Browse by type

Functions 4,136 Types & classes 975
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

[!IMPORTANT] The way Cog integrates in your project has changed. If you update Cog, please read the integration guide.

Cog

Cog is a set of debug tools for Unreal Engine built on top of Dear ImGui

Cog

Cog provides: - ImGui windows to inspect and configure various Unreal systems (Core Engine, Enhanced Inputs, Gameplay Abilities, AI) - Window management with persistent configuration and layouts. - C++ and Blueprint functions to log and debug draw within Log Categories. - Control over the server regarding debug draw, logging, spawning, cheats. - NetImgui support to ease the debugging of game server.

General Info: - Cog can be used both in editor and package builds. It is disabled by default on shipping builds. - Press the [F1] key or use the Cog.ToggleInput console command to open the ImGui Main Menu. - Many windows display their contents based on a selected actor. The selector actor can be chosen using the Engine/Selection window or widget. - Widgets such as Stats (FPS, Ping), Time Scale, Actor Selection, Console, can be added in the main menu bar from the Window/Widgets menu.

Cog Windows

Cog comes with the following windows:

Abilities

Displays the gameplay abilities of the selected actor.

Abilities - Click the ability checkbox to force its activation or deactivation. - Right-click an ability to remove it, or open/close the ability separate window. - Use the 'Give Ability' menu to manually give an ability from a list defined in a Data Asset.


Actions

Displays the state of Input Action.

Actions - Can be used to inject inputs to help debugging, as loosing window focus when breaking in the code doesn't affect the state of injected inputs unlike real inputs.

https://github.com/user-attachments/assets/2497900e-d2d9-4af9-abef-44f7f31c2726


Attributes

Displays the gameplay attributes of the selected actor.

Attributes - Attributes can be sorted by name, category or attribute set. - Attributes with the Current value greater than the Base value are displayed in green. - Attributes with the Current value lower than the Base value are displayed in red. - Use the options 'Show Only Modified' to only show the attributes that have modifiers.


Behavior Tree

Displays the behavior tree of the selected actor.

Behavior Tree

Blackboard

Displays the blackboard of the selected actor.

Blackboard


Build Info

Display the build information such as the build version, changelist, date, target, and so on.

image


Cheats

Used to apply cheats to the selected actor.

Cheats - Cheats are replicated to the game server to be executed. - Key modifiers can be used to change which actor should be affected by the cheat: - [CTRL] Apply the cheat to the controlled actor - [ALT] Apply the cheat to the allies of the selected actor - [SHIFT] Apply the cheat to the enemies of the selected actor - Optionally, cheats applied to the local player character are automatically reapplied.

Cheats Settings

  • Cheats can be defined in a Data Asset. Cog provide two default cheat execution (Apply Effect, Activate Ability).
  • Cheat executions can be defined in blueprint.

Cheats Asset


Collisions Tester

Used to test collision queries

Collisions Tester Collisions Tester


Collisions Viewer

Used to inspect collisions in the world

Collisions Viewer - The query can be configured in the options. - It can be used to better understand what object collisions are blocking a raycast.


Command Bindings

Used to configure the command bindings.

Command Bindings - Bindings are used to trigger console commands from a keyboard shortcuts, which are saved in Saved/Config/WindowEditor/Input.ini (in editor).


Console

Used as a replacement of the Unreal console command.

Console - The console exist as a window and a widget (placed in main menu bar). - The console widget can optionally get the keyboard focus when the main menu bar is shown. - Use the Keys Up/Down or Tab/Shift-Tab to navigate in the command list. - The console settings can be changed in the console window menu, or by right-clicking the widget.

Console Settings


Debug Settings

Used to tweak how the debug display is drawn.

Debug Settings


Effects

Displays the gameplay effects of the selected actor.

Effects - Mouse over an effect to see its details such as its modifiers, the gameplay tags it grants, the remaining time, etc.


Gamepad

Display the state of the gamepad

Gamepad - Can be displayed as an overlay - Can be used to inject inputs to help debugging, as loosing window focus when breaking in the code doesn't affect the state of injected inputs unlike real inputs.

https://github.com/user-attachments/assets/56edc823-7130-4cfe-9af9-1c565f7286b9


Inspector

Used to inspect and modify an Object properties

Inspector - Inspect the selected actor by default - Favorites can be added with a custom function defining what happens when the user press the Apply button (typically this can be used to modify and apply the Game User Settings) - Manage a history of inspected objects.


Levels

Can be used to load specific levels

image


Log Categories

Can be used to activate and deactivate log categories

Log Categories - Activating a log category set its verbosity to VeryVerbose. - Deactivating a log category set its verbosity to Warning. - The detailed verbosity of each log category can be shown by using the Option menu. - A client can modify the verbosity of the server. - The log categories are used to filter both the output log and the debug draw.


Metric

Gather various values sent by the selected actor and compute their rate per second. This is typically used to compute the damage dealt or received per second.

Metric - The following code shows how to add a metric:

// Adding a metric
FCogDebugMetric::AddMetric(this, "Damage Dealt", MitigatedDamage, UnmitigatedDamage, false);

Net Emulation

Used to configure the network emulation

Net Emulation


NetImgui

Handle connections to a NetImgui server.

NetImgui

The following image shows the editor running along a dedicated server. The NetImgui server displays the dedicated server imgui windows. This can be used to debug the state of the game server. For example the behavior trees are only available on the game server. image


Notifications

Use to display and configure notifications

Notification

  • Notification can be added by using the following macros: COG_NOTIFY, COG_NOTIFY_WARNING, or COG_NOTIFY_ERROR.
  • Notification settings can be used to adjust the filtering, their location, their size, etc.

Notification Settings


Output Log

Display the output log based on each log categories verbosity.

Output Log - The verbosity of each log category can be configured in the 'Log Categories' window.


Perception

Display the state of the AIPerception component of the selection's Controller.

Perception


Plots

Plots values and events overtime. When applicable, only the values and events of the selected actor are displayed.

Plots - The following code shows how to plot values and events:

    // Plotting a value
    FCogDebug::Plot(this, "Speed", Velocity.Length());

    // Starting an event
    FCogDebug::StartEvent(this, "Effects", GameplayEffectSpec.Def->GetFName(), GameplayEffectSpec.GetDuration() == 0.0f)
                    .AddParam("Name", AbilitySystemComponent->CleanupName(GetNameSafe(GameplayEffectSpec.Def)))
                    .AddParam("Effect Instigator", GetNameSafe(GameplayEffectSpec.GetEffectContext().GetInstigator()))
                    .AddParam("Effect Level", GameplayEffectSpec.GetLevel())
                    .AddParam("Effect Duration", GameplayEffectSpec.GetDuration());

    // Stopping an event
    FCogDebug::StopEvent(this, "Effects", RemovedGameplayEffect.Spec.Def->GetFName());

Pools

Displays attributes of the selected actor as pools.

Pools - The pools can be configured in a data asset.


Scalability

Used to configure the rendering quality.

Scalability


Selection

Used to select an actor either by picking an actor in the world or by selecting an actor in the actor list.

Selection - The actor list can be filtered by actor type (Actor, Character, etc.). - The current selection is used by various debug windows to filter out their content.


Settings

Configure the settings of Cog.

Settings

  • Configure how ImGui behaves
  • Change the visibility and ordering of the widgets appearing in the main menu bar
  • Change the ImGui Font
  • Change Cog Shortcuts
  • Change the DPI Scaling. Use [Ctrl][MouseWheel] to change the DPI.

Skeleton

Display the bone hierarchy and the skeleton debug draw of the selected actor if it has a Skeletal Mesh.

Skeleton - Mouse over a bone to highlight it. - Right-click a bone to access more debug display. - Use the [Ctrl] key to toggle the bone debug draw recursively.


Spawn

Used to spawn new actors in the world. The spawn list can be configured in a Data Asset.

Spawn


Stats

D

Core symbols most depended-on inside this repo

Shape

Method 2,926
Function 1,210
Class 791
Enum 184

Languages

C++99%
C#1%

Modules by API surface

Plugins/Cog/Source/ThirdParty/ImGui/imgui.cpp753 symbols
Plugins/Cog/Source/ThirdParty/ImGui/imgui_internal.h372 symbols
Plugins/Cog/Source/ThirdParty/ImGui/imgui_widgets.cpp293 symbols
Plugins/Cog/Source/ThirdParty/ImGui/imgui.h206 symbols
Plugins/Cog/Source/ThirdParty/ImPlot/implot_internal.h201 symbols
Plugins/Cog/Source/ThirdParty/ImPlot/implot_items.cpp192 symbols
Plugins/Cog/Source/ThirdParty/ImPlot/implot.cpp186 symbols
Plugins/Cog/Source/ThirdParty/ImGui/imgui_draw.cpp177 symbols
Plugins/Cog/Source/ThirdParty/ImGui/imstb_truetype.h151 symbols
Plugins/Cog/Source/ThirdParty/ImGui/imgui_demo.cpp129 symbols
Plugins/Cog/Source/ThirdParty/ImGui/imgui_tables.cpp99 symbols
Plugins/Cog/Source/ThirdParty/ImPlot/implot_demo.cpp93 symbols

For agents

$ claude mcp add Cog \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page