Compile all Blueprints

AnswerHub topic for that request exists since UE4.5. still relevant for many people including me:…lueprints.html

Changing .h (header file) of a C++ class, many times causes errors in all BP children of that class, which are fixed by simply recompiling the BP. doing that manually for 50+ children everytime is a nightmare.

+1! With a growing number of child BPs of an parent C++ class its getting super annoying if you have to change something there.

+1 I want to find all Blueprints that can’t be compiled when I removed a C++ class, especially the class is the parent class of the BP.

Any reason why you can’t just hit the play button? That compiles all blueprints if I remember correctly.

not in this case. the affected broken blueprints are not listed there. instead “play” button targets you to some (possibly not all) problematic blueprints you need to manually find and compile then each one individually.

I “Compile All Blueprints” option has been requested a lot I think. I’d still like to see one (even if it’s just in the menu, and not a button… though it’d sit nicely under that little dropdown arrow next to the compile button :wink: ).

The problem is, I think when hitting the Play button, it tries to be smart and only compile changed blueprints and dependencies, but relying on this is always going to be troublesome. I run into bugs where something doesn’t work after hitting play, but if I go and compile a class manually (usually playercontroller), without changing anything, then it works (probably something to do with circular dependencies, but nearly everyone has those). This is why an option to just force compile all blueprints is needed, for peace of mind, so we don’t have to wonder whether it’s something wrong or just a bug with the compile manager.

This is something I would find useful.

Im not on very firm grounds when it comes to C++ in Unreal, but what came to my mind spontaneously is:
Write a little piece of code that uses the asset registry to find all blueprint assets in the project.
Invoke compilation on them (basically the same what the compile button does)
Then wrap that piece of code in a Blutility or make a menu entry for it.

Or would it be more complicated than that? :wink:


Wait and see if there’s some Compiler-Writers around to step in and educate us, but its definitely trickier than that. Particularly Circular-Dependencies at compiler-level and Code-Flow-Execution dependencies at run-time. So much so, even Epic messes it up sometimes… For example, changes to Interface variables aren’t recognized properly inside a Blueprint… Or there’s an orphaned Spawn-Actor-variable somewhere causing probs. Or just broken BP Plugin code etc. Then, manual recompilation in the correct execution order is required, or manually refreshing nodes etc. Or manually re-saving and recompiling again. Or sometimes the Editor just gets buggy, and in rare cases its necessary to re-load the entire project and start the Editor again.

You see it most when you’ve migrated textures / materials between projects. But that’s also brought over rogue dormant blueprints that now can’t compile but never even get called anyway. However, UE4 thinks they’re needed. BP’s that have Plugin references that aren’t valid anymore produce lots of unreliable errors especially. Its easy to run into this… Just download a few sample projects that use Rama plugins etc. That can break heaps of things at a BP compilation level. However, the code still runs fine. But with compilation errors everywhere, how do you build a system that tells you how much more compilation to do? Its definitely a case of you don’t want to compile everything in the project randomly from Asset-Info. That just can’t end well… :stuck_out_tongue:


But in this case there would be no worry about that. If a click on the compile button of the blueprint solves the problem described, then its just a matter of doing that for all BPs projectwide.
As the OP said, manually clicking on compile for all BPs in question works.
So a batch processing of a compile on all BPs should do the triock. Regardless of dependencies. (The compile button has to deal with them as well).

Or did I miss something (the OP didnt make it seem that compilation order matters)?

Sure I can see that working some of the time… I can also see it breaking and requiring some kind of systematic loop to go back and re-recompile certain BP’s in a specific order. You see this all the time when using Spawn-Actor-From-Class and adding / removing Exposed-Variables. Or when Interface variables are altered etc etc… You can’t just compile things in any order, that doesn’t work reliably. At best its hit and miss… ‘Refreshing nodes’ and recompiling & re-saving seems to be an essential part of the process… At least that’s been my experience up to 4.18. :slight_smile:

Im really curious why that is? Why would the compilation result of a BP deend on the compiled state of other blueprints?
Or is the term “compiled” used rather loosely in the context of BPs…?
I thought the BP compiler would translate a BP graph into a byte code sequence for the BP state machine.So a BP that refers to another one would be compiled with references to the other one.
Indeed a refresh of nodes might be neccessary but that could be done in a first pass if needed.
I’d really like to understand why a C compiler can translate source files independent of their order and then link them, but the BP “compiler” requires already compiled dependant BPs to do its job…?

As of 4.20, there is a CompileAllBlueprints commandlet. Try giving that a shot :slight_smile:

Cloud you give me example command line?

I mean the full command including .exe and path example.


One of our senior found it.
Here the example command.

Replace <AbsolutePath_to_.uproject> with your absolute path to your .uproject.
UE4Editor-Cmd.exe should be in “Epic Game\UE_4.20\Engine\Binaries\Win64”

Is there a reason there is no in-editor way to do this?

As of 4.22.1, CompileAllBlueprints crashes all the time (even in a brand new empty project). I just filed a bug for it so I don’t have a UE-XXX issue number yet. More information here:

The issue is UE-73069. It has already been fixed in github sources and is targeted for 4.22.2.

I made a plugin that could help here:

The plugin lets you refresh all nodes in every blueprint, and it recompiles them all.
To use it, hit Blueprints->Refresh All Blueprint Nodes