[FREE] Hardware Breakpoints, a plugin to let you set data breakpoints on any variable (BP or C++)

Hi! I’m Daniel Amthauer, Lead Programmer at ACE Team, which you might know for games like Zeno Clash, Rock of Ages and most recently The Eternal Cylinder.

I’m releasing my HardwareBreakpoints plugin for free. It allows you to easily place data breakpoints on any variable (Blueprint or C++) at runtime.

Binary versions are available for 4.24-4.26, and full source code is available under the Apache 2.0 license.
You can download the binary versions here: https://bitbucket.org/damthauer/ue4-hardwarebreakpointsplugin/downloads/
And the link to the repository is here: Bitbucket

To install the binary version simply unzip it inside your project’s Plugins folder.

Here’s some details about what this plugin can help you do, and how. [HR][/HR]

For those unfamiliar with them, data breakpoints are those that trigger when a variable’s value changes.

This type of breakpoint is usually available only to C++ users, and they can be quite tedious to use; especially if you want to debug a blueprint variable. With this plugin you can place a breakpoint on almost any typical property of an object with a simple Blueprint or C++ function call. Even if it’s inside a Struct or an Array, or both, as can be seen below.

The breakpoints can have conditions (only C++ conditions currently) and they are VERY fast, compared to conditional data breakpoints in Visual Studio. This lets you, for example, find the exact piece of code that turned an object’s velocity, scale, or whatever into a NaN value really quickly, while playing your game pretty much normally. This is the use case that I’ve used the most, to find weird physics and collision bugs, so I’ve exposed that particular sort of conditional breakpoint to Blueprints as “Set NaN Data Breakpoint”.

When any of these breakpoints are triggered, you’ll be prompted whether you want to load the debug symbols (which can be a bit slow). If you accept, once the debug symbols are loaded, you’ll be shown the callstack for what caused your variable’s change. If it’s a blueprint function, you can double click it and it will take you to the exact node that caused it once execution resumes. (If you don’t need this window, e.g. if your project is C++ only, it can be turned off in the plugin’s settings in the Project Settings window).

NOTE: The callstack window requires the **Engine symbols for debugging **option to be installed on your UE4 version. Check the Options in the Epic Games Launcher


If you have the Visual Studio debugger attached, you’ll also be given a chance to inspect the callstack inside the debugger. (This behavior can be turned off in the plugin’s settings in the Project Settings Window)
DISCLAIMER: The reason I’m releasing this for free is that I realized I wouldn’t have time to support a proper commercial release, and it was just sitting there on my Bitbucket. The tool is intended mostly to assist in development, not production, so the code isn’t super clean.

CAVEAT: Since these breakpoints are implemented in hardware, they have a hard limit of 4 available breakpoints, so be sure to check the return value to see if your breakpoint was actually set, and clear your breakpoint as soon as possible afterward if you need to monitor different properties. A breakpoint will automatically be cleared if it’s owning object is destroyed.

CAVEAT 2: These data breakpoints only work on variables that can fit in a hardware register (usually up to 8 bytes). If you place one on a variable that has a larger size (e.g. an entire Vector), it will most likely not work as you might expect.
Thanks for reading!

Let me know what you think about it. Any feature requests or bug reports can be added to the Issues section in the Bitbucket repo here: Log in with Atlassian account