Search Unity

Weird SpotLights In Unity. Passes through objects.

Discussion in 'General Graphics' started by Job_MTalha, Feb 1, 2021.

  1. Job_MTalha

    Job_MTalha

    Joined:
    Jan 14, 2021
    Posts:
    61
    Hi there, I am trying to make a simple 3D mobile game. I am playing around with the spot lights but they dont seem to cast shadows. Directional lights do cast shadows but...

    Take a look at the picture the spot light passes through the fence and hits the cube as it is without casting shadows, what is worse that it goes beyond the cube and casts light on to the fence behind the cube.

    Kindly point me in the right direction what should I Do? I am using URP ( Middle quality settings).
    HDR is off in the URP asset settings.
     

    Attached Files:

  2. Job_MTalha

    Job_MTalha

    Joined:
    Jan 14, 2021
    Posts:
    61
    OMG, It was soo simple. I just had to turn on the cast shadows option in urp asset settings under lighting. tsk tsk.