Last active
April 23, 2019 01:13
-
-
Save RodGreen/07186edc9fb02d18d32a97def33aec8b to your computer and use it in GitHub Desktop.
Export All Dag Children Maya Mel Script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
proc ExportAllDagChildren() | |
{ | |
$savedSel = ls("-selection", "-l"); | |
select(ls("-l","-fl", "-type", "transform", "-dag", listRelatives("-ad", "-f"))); | |
for( $eachMesh in `ls -selection -l` ) | |
{ | |
$overrided = getAttr ($eachMesh + ".overrideEnabled"); | |
if($overrided != 1) | |
{ | |
continue; | |
} | |
//$overrideSetting = getAttr ($eachMesh + ".overrideDisplayType"); | |
//print($eachMesh + "\n"); | |
select -d $eachMesh; | |
} | |
ExportSelection; | |
select $savedSel; | |
} | |
ExportAllDagChildren(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment