Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Two directional lights for different effects. Can this be achieved in Unity?

Discussion in 'General Graphics' started by Sibylline-Siren, Apr 4, 2020.

  1. Sibylline-Siren

    Sibylline-Siren

    Joined:
    Jul 8, 2012
    Posts:
    21

    https://i.imgur.com/qcEEzn4.jpg
    Let's ignore the fact that the game pictured above uses sprites for a second.
    As it can be seen in the screenshot, there are two light sources represented: one in front of the "camera", that impacts on the water and is reflected to the player as shines through the waves. Unit's also project a shadow to the left, meaning there's a supposed lightsource to the right. It's not realistic, but it looks good: you get shadows and shining water.
    Trying to recreate this in 3d in an Univesal RP project, and I''m having trouble. One one directional light seems to be operative at a time. I either get the shadows, or the water reflections. I guess it's because as this says there can only be 1 main light: https://docs.unity3d.com/Packages/c...l/universalrp-builtin-feature-comparison.html
    Does that mean I'm out of luck?
     
  2. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    11,891
    You can use layers to add two lights to the water, but have most of the scene exclude one light. Or fake it with a cubemap.