View Full Version : selecting specific types.

02 February 2008, 11:27 PM
I've been having trouble discovering the syntax to select specific type.
such as:

1) select all locators in scene
2) select all objects that being with a certain word such as Left (i assume the use of a wild card is used here)
3) select all locators that do not begin with the word "Left".

thanks for all the help ive been getting on this site. It really has quickened my learning curve!

02 February 2008, 12:49 AM
//Selects all locators in the scene
string $loc[] = `ls -type locator`;
string $parentNode[], $select[];
for ($i=0;$i<size($loc); $i++){
$parentNode = `listRelatives -p $loc[$i]`;
$select[$i] = $parentNode[0];
select -r $select;

//The ls commands can be used to find wildcards
ls -type locator "Left*";

Hope that helps,

02 February 2008, 01:42 AM
meljunky, is there anything you don't know? :) thanks man!

CGTalk Moderation
02 February 2008, 01:42 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.