Hello! I am creating some simple scripts to zero out specific channels of items to help make animating faster and keep me from having to go to the channel box, highlight the attributes I want to zero out and then type zero and hitting enter.
I have one for rotations and translations, but wanted to create one for attributes that aren’t so common place on a rig. So basically I would like to highlight a channel or channels in the channel box and then apply my script which is currently setup in a marking menu.
Any ideas how to make this work? Or if you can think of something even better, I am open to ideas. Programmer I am not so I am completely open to suggestions.
The code I am using to do the zeroing out is this: (found this elsewhere on this site but it was for setting scale to a specific number so I modified it for just zeroing out the rotate values)
string $array[] = ls -sl;
for ($item in $array)
{
setAttr ($item + “.rotate”) 0 0 0;
}
Any help is greatly appreciated!
)