////////////////////////////////////////////////////////////////// // hmLocatorParent v0.1 - script file // Creation Date - 10.11.2008 // //Author: Horacio Mendoza //web: www.horaciomendoza.com //e-mail: hjmendoza@gmail.com // // Description: // Get objects and create nulls with a position contraint // attached to this first. // You can use this to export to after effects with a camera. //*************************************************************** // source and call the script with "hmLocatorParent" //*************************************************************** /////////////////////////////////////////////////////////////////// global proc hmLocatorParent() { string $selection[] = ` ls -sl `; int $counter = 0; for ($i in $selection) { $pos = ` xform -q -ws -t $i `; print $pos; $loc = ` spaceLocator -n ("null_" + $counter)` ; move -a -ws $pos[0] $pos[1] $pos[2]; parentConstraint $i $loc; $counter++; } }