Isolate Exponential Height Fog to One Light

Hi guys I was wondering if it’s possible to have the exponential height fog visual effect only affect specific lights in a scene. I have a light shaft like so

but I don’t want a directional light to be affected by the fog, and just keep the fog isolated too the light shaft.

Hello, have you tried using the Local Height Fog?

wdym? isn’t the directional light creating the light shafts? and…

yes. you could use a local fog volume. or you can add a volumetric material/shader to pretty much any shape. it will pick up all the lights tho.

A local fog volume did not work for the desired result, in fact local fog is one of the worst designed visual effects I’ve seen so far. After hours of experimenting I figured it out basically what you do is you put it in a blue print like so:

Then what you do is set the cone angles of the spotlight, and for the exponential height fog you copy similar to what’s below:
image

I changed the spotlight colors, and in this scene as you can see the fog elements are not affecting the directional light and just the spotlight. But it’s a very bad solution because the parameters for the exponential height fog are universal all throughout each blueprint.

Unreal engine devs probably overlooked the idea of indoor light shafts/god rays when designing this or just having separate elements. I really hate the solution.

The Ideal way of handling this is to not use directional lights, and just stick with spot lights.

I found an even better solution, shown in the video https://www.youtube.com/watch?v=gywywUgIoXQ (be sure to check the comments)

Then you’ve got to be more specific than what you were.

Glad you figured it out.

Also, God Rays aren’t laser beams. They gradiate outward and expel indirect light. What you want is purely stylistic, not natural, which is fine, but expecting the developers to standardize every stylistic choice is unrealistic.