Search Unity

Question Objects not receiving shadows when using shader

Discussion in 'General Graphics' started by BL4CK0UT1906, Nov 16, 2022.

  1. BL4CK0UT1906

    BL4CK0UT1906

    Joined:
    Apr 15, 2022
    Posts:
    26
    Hi, sorry for my english and also sorry if i'm posting this in the wrong place. I only used Unity Forums to ask about c#, this is my first time ever asking about some other subject :).

    So,first of all, i'm using this shader: https://leakyfingers.itch.io/retro-3d-shader-pack-for-unity

    When i use it as post-processing only, everything works fine.
    When i use it as a shader for a material (for a wall, for example) the material stops receiving shadows. I'll post two pictures below. In my game i *really* need shadows, they're part of the game. How do i make so i'm able to cast shadows with this shader??

    Please, take a look at the pictures. Thank you so much :)
     

    Attached Files:

  2. kdgalla

    kdgalla

    Joined:
    Mar 15, 2013
    Posts:
    4,639
    Is this the built-in renderer? Are you using point light shadows? When I made my own custom shaders, directional light shadows and spot light shadows worked, but my shaders weren't compatible with point light shadows until I added a special keyword. I don't remember what it is off the top of my head but I can look it up when I get home.

    Do shadows work for a directional or spot light?
     
  3. BL4CK0UT1906

    BL4CK0UT1906

    Joined:
    Apr 15, 2022
    Posts:
    26
    Hey,thanks for the answer. Yes, it's the built-in renderer. I've tried with every light settings and it still not worked. I believe it's a setting in the shader but i have no idea how do i change this. I'm mostly a programmer...
    It's a retro shader, and i have seen retro graphics turning off shadows before. I think this may be the case...