Search Unity

make color brighter

Discussion in 'Scripting' started by Mike4, Sep 22, 2014.

  1. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92
    Hi
    how to get the material color and make it a little brighter?
    Thanks
     
  2. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92
    bump
    mesh using same material as script is to dark...
     
  3. DarkArts-Studios

    DarkArts-Studios

    Joined:
    May 2, 2013
    Posts:
    389
    Can you not simply use Material.color ? Is that what you're looking for?
     
  4. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92
  5. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92
    Why does the material change if I do ctrl+D in the editor and select that?
     
  6. MrPriest

    MrPriest

    Joined:
    Mar 17, 2014
    Posts:
    202
  7. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92
    joseprietoru likes this.
  8. MrPriest

    MrPriest

    Joined:
    Mar 17, 2014
    Posts:
    202
    Is it possible that the darkness is from shadows cast from the ocean on the terrain below it? Try to disable shadows.
     
  9. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92
    There's no shadows setting in the ocean script? But I've unchecked all shadows in my mesh. I also think it's mesh related as I've tried to optimize it in Blender and got completely different black spots in Unity. Added this
    but no change:
    light.shadows = LightShadows.None;
    as dark areas move with my mesh anim it should be something else.
     
  10. MrPriest

    MrPriest

    Joined:
    Mar 17, 2014
    Posts:
    202
    Well the only thing I can think of without going deeper into it, is that there are a couple of layers of water that cause the color to get too dark. I think so since it seems to happen only on waves, isn't that right?
     
  11. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92
    Well could be. The simplest would be to change black to white in script? But changing material color (adding script) destroys the whole ocean look. I haven't managed so far to change the ocean script accordingly.

    Also if I add another material (for ex. watersplash), that looks like a fex pixel to low. (below my mesh in y)
     
  12. MrPriest

    MrPriest

    Joined:
    Mar 17, 2014
    Posts:
    202
    Is the script a freebie? Can I have a look at it?
    I am not at home right now so I can't do anymore than that right now.
     
  13. Mike4

    Mike4

    Joined:
    Oct 24, 2013
    Posts:
    92