Hi guys ! I have now upgraded from 4 to 5.4.2f2… Disaster ! I had to fix all the loadlevel with the scene management… but i have a problem with the directional light ! If i play the scene from unity it’s OK, but if i restart the level, or i start the level from the main menu the direction light becomes more dark and strange… Please help me…
For those in the most recent version of Unity as of this date:
You have to go to Window → Lighting. In that Window, look for the “Debug Settings”. Untick the “Auto Generate” checkbox and hit the “Generate Lighting” button beside it. That should take care of it in the editor.
Relax, it’s pretty simple.
When you select a scene, Unity will automatically bake all the lights and render things. BUT when you open a scene while playing the game in the editor, Unity will NOT bake the lights,render them, fix the effects and all, and this causes everything to stay dark.
This only happens in the editor. If you build your game, you will see that this will not happen. Hope it helped =)
I HAVE FOUND IT! This is a problem with the skybox loading between scenes. To fix it, go to Window>Rendering>Lighting>Environment. There you should see the Source in the Environment Lighting section set to Skybox by default. When I changed this to color(on ALL scenes) it fixed all my problems with lighting. Every project is different, but this worked better than all of the other solutions I have tried.
For anyone that may come across this issue in the future, I fixed it by unchecking Baked Global Illumination and checking Auto Generate under the lighting tab.
I just spent 2 hours trying to figure this one out.
Come on unity. This is super basic.
Here’s an update for what worked for me with Unity 2021.3.12f1.
The previous answers in this thread helped me get to these solutions, so kudos to everyone who wrote answers before me!
Two Methods to avoid scene darkening.
-
Match lighting in your scenes.
-
In Lighting Settings, Click “Generate Lighting” for all your affected scenes.
1) Match lighting in your scenes.
When the lighting was different from one scene to the next, the first scene was always properly lit, but the second was darkened. When I loaded multiple scenes in a sequence, all the scenes that had the exact same lighting setup were all lit as designed, but any scene that had any deviation from the original was darkened. I got rid of the darkening by just having all the lighting in my scenes be *exactly* the same.
2) In Lighting Settings, Click “Generate Lighting” for all your affected scenes.
I added a start screen and end screen, on 2D canvases, and that messed up the lighting consistency across scenes. The following resolved that.
a. Open Lighting Settings: Window > Rendering > Lighting
b. Click “Generate Lighting” at the bottom of that window (any tab). Do this for ALL your scenes that have 3D lighting. I didn’t do it for my 2D start & end screens, as they didn’t have “lighting”. (I did try adding the same lighting to those 2D screens, but that didn’t stop the darkening from happening.)
c. For each scene that you “Generate Lighting” for, a new folder will be created (inside your scenes folder) containing LightingData and ReflectionProbe files.
d. Now that each scene has its own lighting data, Unity won’t try to recreate it for each scene, and everything should be lit as designed.
e. If you want to remove the generated lighting for a particular scene, just delete the created folder associated with that scene. If you change the lighting in a scene, just press Generate Lighting for that scene again, and it will overwrite the old lighting data for it.
I hope these approaches can help some people.
If you want to default ‘Light Setting After Reseting Them’ OR If you create another scene & lighting was not matching to default Scene(SampleScene)
, Then you are in the right place…just read the below description.
1. Select your Directional light
in the Hierarchy
2. Change the Light Mode of the Light
component Baked
to Mixed
3. (Optional) Go to Window
> Rendering
> Lighting Settings
> Lightmapping Settings
(inner tab) Change the following value, and then click on Generate Lighting
Direct Important = 1
Indirect Samples = 500
Environment Smaples = 500
Direct Filter = Advanced
Tested on Unity 2019.1
I tried for hours to get this working. I loaded a scene from a loading screen, along with 2 additive scenes and ENSURED the main scene was set as the active scene, but still it was inheriting the lighting settings from the loading screen. Finally decided to try the generate lighting option which worked, but damn it’d be nice if things actually worked as expected. If I set a specific scene as the active scene, it should just automatically switch the lighting settings for that scene. At least I learned that I have a lot of reading up to do on lighting in Unity.
Mine was solved by simply setting
Window / Rendering / Lighting / Scene / Lighting Settings
with a custom source to anything other than the default None
.
EDIT: Nevermind I have figured this out
I’m having the opposite problem, is there any way to keep the darkened lighting instead of the brighter one? I’d like to use the darker lighting from not fixing it but it then renders the proper-brighter lighting when I build the game.
Thanks, This Worked for me too
Generating light worked for me, but this a problem that should not occur like @ xealgo said