StephG
08-04-2010, 11:52 PM
I'm trying to make a tool which allows me to make a list of custom attributes in an attribute holder, and to display only those attributes that are selected in the Curve Editor. I have no problem with conventional transform attributes, but the custom attributes seem to be a completely different animal.
The attribute paths looks like this:
$mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown
It would be too simple if something like this would work:
trackviews.current.setFilter #hierarchy #objects #selectedObjects #modifiedObjects #Attribute_Holder #Custom_Attributes #right_frown
Of course it does not work.
I could possibly use the "selected tracks" option, but I haven't figured out a way to select $mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown as a track through Maxscript. And it doesn't have an ".isSelected" property, but I can make a Selection Set with the selected tracks.
I've tried this:trackviews.current.selectTrack $mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown clearSelection:true
...but I get an "-- Argument count error: selectTrack wanted 2, got 1" error. (also, there's no space between "custom_attributes" and ".right_frown", but for some reason it's adding a space here).
EDIT: and if I try this:trackviews.current.selectTrack $mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown trueI get this FAIL: "-- Unable to convert: 0.0 to type: MaxObject"
Thanks in advance for any clarity that can be offered.
StephG
The attribute paths looks like this:
$mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown
It would be too simple if something like this would work:
trackviews.current.setFilter #hierarchy #objects #selectedObjects #modifiedObjects #Attribute_Holder #Custom_Attributes #right_frown
Of course it does not work.
I could possibly use the "selected tracks" option, but I haven't figured out a way to select $mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown as a track through Maxscript. And it doesn't have an ".isSelected" property, but I can make a Selection Set with the selected tracks.
I've tried this:trackviews.current.selectTrack $mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown clearSelection:true
...but I get an "-- Argument count error: selectTrack wanted 2, got 1" error. (also, there's no space between "custom_attributes" and ".right_frown", but for some reason it's adding a space here).
EDIT: and if I try this:trackviews.current.selectTrack $mouthMain_CTRL.Attribute_Holder.custom_attributes.right_frown trueI get this FAIL: "-- Unable to convert: 0.0 to type: MaxObject"
Thanks in advance for any clarity that can be offered.
StephG
