how to change color of dublicate object ?

i duplicate an object when i want to change its color from shader options it also change the color of original object… what should i do?

3diy

You can:

  1. Duplicate the material, change the color in the new material, apply the new material to the clone.
  2. Change the color in script. This will cause the material to be cloned at runtime. It will revert to the original color when the game is stopped.
  3. If you use a shader that supports vertex color and a 3D authoring program, you can supply the color as part of vertex information. You could also change the vertex colors in script.

Though it is uncommon to use, I mention #3 (vertex colors) because #1 and #2 result in new materials and therefore more drawcalls.