Shadow, sky sphere and lighting actor.

When I was making a custom sky sphere blueprint, I created a mask to simulate clouds and linked the sun to the directional light actor, and here goes the problem.

When the sun is positioned behind the clouds, I wanted the sun to cast shadow of the clouds, or simply dim the sun light intensity based on the transparency of the cloud. Wouldn’t it be performance expensive if I use another sky sphere mesh and apply the cloud material as translucent and casts shadow? Or any idea about the possibility at all?

Also, Is it possible to color the shadow like this image below?


Hi -

You could achieve what you are looking for in Blueprint. It would require taking the panning clouds texture setup and moving it into a Material Function which can then be called from the Sky Sphere’s base material and the same function could be referenced in a light function that is applied to the directional light. You would also have to make sure that the Sun’s vector information is applied evenly to both the base and lighting function.

I might also take a look at the Shooter Game Template in the examples. You may want to (especially if you want to get the colored shadows) use a large sized particle system which generates only a very small amount of particles and make sure they cast shadows. This would give you probably the best of both worlds as far as only a moderate performance hit and the look you are after.

Hope that helps, if you want me to explain more please let me know -


Hi ,

Thank you for replying.

Light function, that’s a good point. What would happen if I have multiple sets of cloud textures panning at different speed? And what if also there will be additional particle system based cloud effect in the scene?

I’ve tried it with several smoke particles, did some setting change, but I wasn’t able to make the shadow colored. Is there any specific settings I need to turn on and off?

Hi -

No there is currently no way to set up colored shadows like in your image in the Engine except through a light function. So if you want to have the colored shadows it would have to be built into the light function or by layering light functions across your world.

  • Ketchum

Thanks, will give it a try!

Translucent shadows only work on small objects like in your second image. They are also constrained to greyscale for performance reasons. (sadly)

I think the best thing for your scene is a light function on the directional light like said. I’m not sure how to make it match up with the actual position of the light and the clouds in the skybox. It’s like a projection of a hemisphere onto the world problem.

Thank you for point it out. There gotta be a way somewhere, I’ll keep trying.