nanimator
05-02-2009, 09:32 AM
okay my Mel is very raw and has mosltly been learnt through much hours of reading books and reading other peoples scripts. Currently I'm trying to create a mel script that allows the user to select multiple curves and chage the wireframe color instantly. This problem seems a bit over my head and if anyone can point me in the direction that would be great.
here's the script, its a simple for-in loop. I've checked to see it works just by using a move command (which I have commented out). The problem arises when try to change the overideColor attribute, or any other attribute.
string $selected[] = `ls -sl`;
string $each;
for ($each in $selected)
{
//move 10 0 0 $each;
setAttr $each.overrideEnabled 1;
setAttr $each.overrideColor 11;
}
the error message I get is...
// Error: No attribute was specified. //
If anyone can point out the error of my ways, that would be much appreciated.
thanks
here's the script, its a simple for-in loop. I've checked to see it works just by using a move command (which I have commented out). The problem arises when try to change the overideColor attribute, or any other attribute.
string $selected[] = `ls -sl`;
string $each;
for ($each in $selected)
{
//move 10 0 0 $each;
setAttr $each.overrideEnabled 1;
setAttr $each.overrideColor 11;
}
the error message I get is...
// Error: No attribute was specified. //
If anyone can point out the error of my ways, that would be much appreciated.
thanks
