How to get visual studio to debug child UE4Editor.exe

When debugging UE4 in VS, after I select my project, the current instance of the editor spawns another, and then shuts down. How do I get VS to continue debugging the spawned process?

That’s a less-than-ideal solution because the startup of the new process is not contained in the debugger, but if it’s the only one we’ve got I guess we’re stuck with it.

You’ll need to reattach visual studio; Debug > Attach To Process

Head to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options, and make a new key called UE4Editor.exe

In that key, make a new string value called debugger and set it’s value to vsjitdebugger.exe The JIT popup will not contain the already open instance of VS, so you need to attach from inside of VS, and then hit no on the JIT prompt

You can set the full path to your .uproject file on the debugging command line option inside Visual Studio (eg, C:\MyProject\MyProject.uproject). That way the editor will launch and immediately load your project without requiring you to re-attach to it.

You shouldn’t even need to give the full path, just the name of the project, if it’s inside the default Unreal Projects folder.

Nice :slight_smile:

I knew that worked for the paths we use internally, but I wasn’t sure what other paths it was supported for. Handy to know.