Advanced Skeleton Specific

From bernie's
Jump to: navigation, search

Save controller colors

//'Rebuild' loses controller colors, run this before to save them and apply churned out code after rebuild
scriptEditorInfo -ch;
proc saveNurbsCurveColors(){
print "\n//--copy paste in script editor----------------------------------------------\n\n\n\n";
for($o in `lsType "nurbsCurve"`){

    if($o != "<done>" && `getAttr ($o+".overrideEnabled")` == 1){
        $c = `getAttr ($o+".overrideColor")`;
        print("setAttr (\""+$o+".overrideEnabled\") 1;\n");
        print("setAttr (\""+$o+".overrideColor\") "+$c+";\n");
    }
}
print "\n//--copy paste in script editor----------------------------------------------\n\n\n\n";
}
evalDeferred("saveNurbsCurveColors");