Search Unity

How to set colors intensity HDr

Discussion in 'Scripting' started by kader1081, May 16, 2022.

  1. kader1081

    kader1081

    Joined:
    Oct 16, 2021
    Posts:
    379
    Hi ı have a shader and material that inherited from this ı want to set to intensity.İt is a 2d game.Im using code under here but it is not working.
    Code (CSharp):
    1.   miner_health_bar.GetComponent<SpriteRenderer>().
    2.       material.SetColor("_EmissionColor", color_to_set * 5f);
    3.  
    4. ı tried _EmmisiveColor too
    5. ı tried renderer instead of spriterenderer too