NiagaraShaderModule.cpp Can not invoke OnRequestDefaultDataInterface. Delegate was never set

Hello

We’ve started implementing Niagara particle FX into our game. After building the game and launching we get the following error message:

Assertion failed: OnRequestDefaultDataInterface.IsBound() [File:D:/Build/++UE4+Licensee/Sync/Engine/Plugins/FX/Niagara/Source/NiagaraShader/Private/NiagaraShaderModule.cpp] [Line: 55]
Can not invoke OnRequestDefaultDataInterface. Delegate was never set.

We’re completely stumped by this! We have tried enabling a bounding box and changing sim target to CPU in the emitter properties and still nothing. Would anyone be able to help?

we managed to fix it. There was one emitter that managed to slip through the net which wasn’t a CPU sim with fixed bounds.

Seems like Niagara GPU particles are still a bit buggy in Unreal 4.24.3. Changing every emitter and Particle System in your project to CPU with fixed bounds should solve the issue.

If you’re a developer, try to run a game in debug mode, and after assert fail check the functions call stack.
I had an UDevelopersSettings child class that has reference to the actor class that uses Niagara, and attempt to construct a Niagara object in CDO failing because Niagara as engine module doesn’t load yet.

Was at a loss on this problem in Unreal 4.26.2 after switching several of our more intensive VFX over to GPU. Switching everything back to CPU with fixed bounds resolved our issue, after that we went about enabling GPU Sim on each VFX to see if we could get any of them on the GPU. Only a small subset of VFX would run without fatal error.

Thanks for the solution!

How did you manage to solve the issue then?

Just in case it might help anyone else. For some reason this was caused by the gamemode trying to load the player pawn by default.
I’ve just uncommented these lines in my gamemode.cpp and that fixed it for me.