How to Combine Lightmaps with Dynamic Lighting for Rooms Separated by Doors in Unity?

I’m working on a project(URP) where I have multiple rooms, each separated by a door that the player can open and close. My goal is to achieve the following lighting behavior:

  1. “When the door is closed”: Each room should have its own lighting with realistic Global Illumination (e.g., one room is well-lit, and the other is dark).
  2. “When the door is opened”: The light from one room should dynamically affect the other room, making the dark room brighter as the door opens.

I’ve already baked lightmaps for both rooms with the doors closed, but I am unsure how to handle the dynamic lighting when the door opens. Specifically:

How can I achieve the effect where the closed room stays dark, but as the door opens, the light “spills” into the other room?

  • Is it possible to blend baked lighting with real-time lighting for such a scenario or any other solution ? How games like Escape from Tarkov handlethis ?

Any advice on how to handle this setup or best practices to combine light maps and dynamic lighting in Unity would be greatly appreciated!

Examples-
1.Door-close, only interior light source is contributing to global illumination


2.Door-Open and light up the room with proper global illumination (Directional Light + Interior light)

You can look into Screen Space Global Illumination. But when inside the room, this will only work if the player is looking at the exterior.

Maybe there’s a way to do it with APV but I’m not sure.

As with many things the ideal solution is use raytracing, but it might not be the right thing depending on your project.

1 Like

I think you can try baking multiple APV lighting scenarios (documentation) and blend between them.

Roadmap page:

1 Like