Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. The 2023.1 beta is now available for testing. To find out what's new, have a look at our 2023.1 feature highlights.
    Dismiss Notice

Question Problem with additional 2D lights

Discussion in '2D Experimental Preview' started by pigwejq, Nov 20, 2020.

  1. pigwejq

    pigwejq

    Joined:
    Dec 15, 2018
    Posts:
    5
    Hi
    I didn't know there was experimental 2D subforum, and I post my problem here: https://forum.unity.com/threads/problem-with-2d-lights-on-urp.1009249/ (to mods: please remove if needed)

    I have a problem with 2D Lights with 2D Renderer. I have about 7 sorting layers in the game. I created a flashlight that has PointLight 2D on 3 of them. Some objects started to behave strangely when they are lit. They get a shadow that wasn't on them before because they were illuminated by GlobalLight 2D. It looks as if the GlobalLight is not affecting the object illuminated with extra light any more.

    (The illuminated area of the object, where the light falls is darker than it was before.)

    Is it a bug or I use the lights wrongly?
     
  2. pigwejq

    pigwejq

    Joined:
    Dec 15, 2018
    Posts:
    5
    I found a solution. Objects without light were illuminated despite its absence (my mistake, I did not notice that not all layers are marked in Global Light), when illuminated by a flashlight they started to behave properly, so they darkened.