Distortion effect works in preview and viewport, but sometimes not in game

Hi,
I have a very confusing issue.
I have two Distortion effects. One is in Cascade, another is in Niagara.
I took the effect in Cascade from the basic engine content, taking it from a small fire effect. You know, the “hot air” effect above the fire which distorts the image when you look through it :slight_smile:
I use them for giving the impression of “warp” and portals.

In the previews in Cascade and Niagara they work well, they distort whatever is behind them.
I added the Cascade effect to a Blueprint together with a static mesh, and I can see it works nicely.
Then I go to the game, and a weird thing happens:

Untitled

The StaticMesh of the spaceship is distorted, but the StaticMeshes of the engine fires are not.
In the viewport, when previewing the Blueprint, they are all distorted!

The same happens with the Niagara effect.
Here I have a distortion effect (not the same material, I bought this one on the Marketplace) and a shockwave ring. In the Niagara previewer, the shockwave ring is distorted, in the game it is not.

I am very confused on what is going on. Can anyone help out? :smiley:

Hi,
for the record, I’d like to document that I’ve finally found the solution to this issue.
It’s actually thanks to this very old forum post: https://answers.unrealengine.com/questions/73313/refraction-not-working-on-particles-in-lit-mode.html

In the Project Settings, look for “Engine - Rendering”, and uncheck the option “Separate Translucency”.

The issue was given by the fact that the engine was rendering separately the translucency of the various objects. Therefore, solid non-translucent objects would be distorted, while translucent objects would not.
Not it works as intended.

The insane thing however, is that the viewport and particle previews don’t reflect this project setting. This leads the user astray when trying to understand what’s going on.

I’m leaving this solution here for the record, in case someone in the future stumbles on the same issue :slight_smile: