How to stop light from going through an object on to another object?

Hi,

I have spotlights with a mask, to only cast thin line of light into the scene (see in picture). Every object as well as the light is set to cast and receive shadows but still the light (coming from the right side) hits the wall and shines right through on to the wall behind it where the window is. The wall in front and the wall in the back are separate objects. Is there a way to keep the light blocked by the first wall in realtime? I don’t even need a shadow on the back wall. I just want to keep the light from shining through.

thanks in advance :slight_smile:

Please, turn off all the lights but the right one and upload image so we can see how the wall is not stopping it, because in that image we can’t see the effect.

Can be that there’s a little gap between the two walls and light it’s just passing through? Try to make them closer, maybe even intersecting a little bit.

I got it to work. There was something wrong with my scene. I created a new one, enabled all relevant shadows and switched out the multiple spotlights for just one point light with a mask. Now everything works as intended.