Search Unity

Light2D experimental : light through walls / bulb visible / memory problem

Discussion in '2D Experimental Preview' started by Zelop, Sep 8, 2019.

  1. Zelop


    Jul 28, 2016
    Hello !
    I have 3 problems with the experimental light2D.

    As you can see in the picture, the light pass through the walls. I searched some solutions but all was for the classic light script (not the light2D).
    The second situation is that the bulb is visible in the game (it normally shows only on the editor).

    One last problem (not in the picture) is that sometimes, some of my gameobject disappear from the editor and the game (only the sprite). It seems to be a problem of memory but I just made one level, and it doesn't seem that expensive in memory in my opinion.

    Thank you for your responses :)

    Attached Files:

  2. dquek


    Unity Technologies

    Apr 17, 2018
    Hi there, @Zelop

    "light pass through the walls"
    - Did you try the Shadows feature yet in Universal Render Pipeline v7.1?
    - You will need to add a Shadow caster component on the Wall and make sure your light has shadow intensity.
    Docs here:

    "bulb is visible in the game"
    - Is this in play mode or in Standalone Build?

    "gameobject disappear"
    - Can you check the object Position Z value?

    You could file a bug report with a slice of the repro project through = Unity > Help > Report a Bug...
    This helps us to debug and hopefully ship a fix faster.

    If not you can reply here in the forums with more info.
  3. Baste


    Jan 24, 2013
    You've probably turned on Gizmos in the game view. It's a toggle in the upper right corner of the screen.