Shadows After building to EXE

Hi everyone,
Finished the Zombie Tutorial Survival shooter today.
Everything looks fine and exported to an EXE file . No problems.

Noticed one glitch though. The shadows for the enemies do not seem to be casting. Anyone have any ideas how to fix this.?
The only shadowing they have appears to be from the tips of their ears.
I am using unity 5

Have included an image below.

On the Unity toolbar, go to Window → Lighting. Then open the Lightmapping tab and make sure “Continuous Baking” is unchecked. See if that works.

Thnaks for the reply.
This is one of the first things i had to switch off due to Shadow errors causing the scene to look really dark.

Would it make any difference if i rebake the scene as the last time i baked was before the enemies were placed in the level?
Or is my understanding of baking well off? :slight_smile:

Wouldn’t hurt to try. Although baking is typically done for static objects. The problem lies somewhere else. This only happens on the .exe - but works fine in the editor?

Yeah exactly. its very strange :slight_smile:

Sounds like a mix of quality settings removing shadows and some part of the upgrade process. First step - switch on continuous and let the scene bake. If its too dark then try tweaking the ambient settings in the Lighting panel or try increasing the intensity of the directional lights slightly til it looks how you want it to. But check Edit > Project Settings > Quality to ensure you’re building to a setting that includes shadows on lights.

Hi,

Attempted your suggestions and they didnt change the outcome :frowning:

Just to check my build quality settings are set to Fantastic with Shadows as follows :

Shadows - Hard and soft
Res - High
Projection - Stable Fit
Distance 130
Cascades None.

As i said its strange because the player shadows work fine.

Any other ideas?

  1. Go to Project\Materials\ and see ZombunnyMaterial.

  2. Change Shader to ‘Legacy Shaders/Bumped Specular’ from ‘custom/Rim Lit Bumped Specular’ at Inspector tab.
    (I just found that PlayerMaterial shader was legacy shaders/bumped specular.)

  3. Do it same at ZombearMaterial and HellephantMaterial.

  4. Done.

2 Likes

That might be a good solution. The “custom rim lit bumped spec” is based on the legacy bumped spec. You could also try using the standard shader, and see how well that works out.

The custom shader I wrote in 4.6 isn’t compatible with the many changes to rendering and shadows introduced since 5.0 launched, so Elaha and Adam are on the money with what’s causing the lack of shadow-casting. Good catch! Hopefully we can get a 5.0 version out soon so people stop hitting weird little backwards-compatibility issues like this…

1 Like