Giving an object an alpha transparency

Hello,

I’ve looked through the forums and script reference, and I can’t find a simple example of making an object transparent.

I’ve tried:

renderer.material.color = Color.clear;

// and

renderer.material.color = Color(1.0, 1.0, 1.0, 0.5);

// and

renderer.material.color.a = 0.5;

None of which make the object transparent. What am I doing wrong?

Thanks!

You need to use a shader with transparency. Otherwise alpha does nothing.

–Eric

Thanks for the reply - a shader or a material?

How do I apply a shader with transparency?

A material with a shader that uses transparency.

Transparent/Vertex-Lit, Transparent/Diffuse, etc.

–Eric

Great, thanks!