Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Question Simple way to make normal map only darken texture?

Discussion in 'Shader Graph' started by slushieboy99, Aug 20, 2023.

  1. slushieboy99

    slushieboy99

    Joined:
    Aug 29, 2014
    Posts:
    88
    Hi all,
    I'm looking to create a shader which takes a normal map, but only darkens the texture and does not apply highlights, similar to a shadow map. Is there a simple way to do this? From what I've seen you either need to take a vector lightsource as input (which I'm not interested in as I'd like to have multiple/dynamic light sources) or write a bunch of custom code for lighting.
    I'm using pixel art and essentially want my art to 'pop' with lighting changes, but for this particular texture I'm not interested in highlights. I'm using URP.
    Thanks!
     
  2. BenCloward

    BenCloward

    Unity Technologies

    Joined:
    Jul 15, 2021
    Posts:
    145
    Try setting the graph's workflow mode to Specular and then set the Smoothness to zero and the Specular Color to black. Does that get you what you're looking for?
    upload_2023-8-21_9-28-26.png
     
    slushieboy99 likes this.
  3. slushieboy99

    slushieboy99

    Joined:
    Aug 29, 2014
    Posts:
    88
    This brings me much closer to the effect I'm looking for. Thanks!