Emissive material is not casting shadows / Toon shader not working in viewport

Hi everyone! I’m currently making a toon shader in UE4, and I’ve run into an issue.

The shader applied to the face works perfectly fine in the material editor preview window, but it doesn’t work properly in the actual viewport. (To be specific, it’s not generating shadows like it does in the preview photo).

here are the things I’ve already tried to fix it:

  • Checked ‘Bloom’ in the Project Settings

  • Adjusted the Directional Light’s intensity

  • Built the lighting

What I don’t understand the most is why it works flawlessly in the preview window but completely fails in the viewport. I would really appreciate any help on this. Thank you!!!

Hey @Speaking_potato! Welcome to the forums!

Have you tried looking at it with the game running? Also Emissive materials will cast light on geometry, but it doesn’t use lightmaps or real-time shadows ie it isn’t affected by building lighting because it isn’t static. UE4 doesn’t have lumen, either, so you will not see a good deal of light functionality that you might see in a UE5 tutorial or something like that. Another thing is the toon shader might only generate shadows at runtime, what does it look like with the game running?

Let us know! :slight_smile: