Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

2D Shadow Caster with multiple lights - Shadows don't work correctly?

Discussion in '2D Experimental Preview' started by mariusB1337, Aug 17, 2020.

  1. mariusB1337

    mariusB1337

    Joined:
    Apr 28, 2019
    Posts:
    2
    Unity 2020.1
    URP 8.2.0

    With multiple light sources the shadows from Shadow Caster 2D don't work correctly. See attached image: With both lights turned on, the character shouldn't have this long shadow but the light from the left torch doesn't seem affect its shadow.
     

    Attached Files:

    tratteo likes this.
  2. Ellbell

    Ellbell

    Joined:
    Jun 25, 2019
    Posts:
    5
    I found a solution. Edit ShadowCaster2D.cs at line 121 to always return true. This fixed the issue for me!
     
  3. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    11,500
    It is good that you are trying to help but I would ask that you please stop cross-posting. You have posted this a total of four times now and are necroing old threads too.

    Thanks.