Change all color materials from a model

Okey , first this is my script:

shadow.material.color = color2;
shadow2.material.color = color2;
shadow3.material.color = color2;
shadow4.material.color = color2;
shadow5.material.color = color2; 

It works , but the face and the other side of the model , didn’t change.
I add a image for explain [3452-sin+título.png|3452]

I suppose that model has several materials attatched. You will have to use Renderer.materials to acess them all:

// C#
Renderer rendererToEdit; // The renderer you wish to edit materials on
foreach (Material mat in rendererToEdit.materials) {
    mat.color =;

var rendererToEdit : Renderer; // The renderer you wish to edit materials on
for(var mat : Material in rendererToEdit.materials) {
    mat.color =;