My editor looks like this. I would like to see everything in the scene editor, but when I run the game, I want it to be like it is shown in the picture. I can make a global light (which lights the whole scene editor), then turn it off with a script when I run the game, but that not a great solution. Is there another way to make the scene editor fully lit ? (like before, without using 2d lights)
Okay, let’s try something else. The reason why disabling that tool I mentioned is working for me is because I have a skybox material and a light source added in the Lighting settings. Maybe you could try that. I’m not sure it will work though because all my sprites have normal maps; they can be lit by 3D lights.
Currently having the same issue, although I did come across something that alleviates the problem somewhat.
In your Project Settings > Editor, there’s a field for Prefab Editing Environment. You could set up a scene that only holds a global light, and then apply that as the scene for editing prefabs. This way you can edit those without a hassle, and just have a debug global light in your scene.
I would love to see a more elegant solution though; preferably just the button designated for it working
That’s odd. Does the following flow work for you?
Create a new scene (call it “scn_Prefab” for clarity).
Remove the camera from the scene.
Add a global light to the scene ( Light > 2D > Global Light 2D (Experimental) ).
Go to the project settings and set the Regular Environment field to scn_Prefab.
Open up a prefab that is using LWRP sprites.
The sprites in my prefab are now lit properly.
The only issue I’m facing with this solution is that if I disable anything in the prefab scene, it’s not disabled when editing prefabs. It does not affect the final game, but if you want to edit a prefab without the light enabled, you would have to either remove it from the scene or disable the prefab scene itself again. Nevermind, this works now.
Ah, I’m not using that package, not until it’s out of its “experimental” stage. Thanks for the explanation, people coming here will find it useful.