Create Transform and Select By Name

This is a bit of Max Script I have encountered. First how to create a transform node in Max? In Maya, an empty group and a transform node are the same thing. They define the transformation matrix about where to put stuff, and they are not renderable. In Max, I find Dummy, which acts quite like Maya transform. It can be create by Max Script:

dummy name:"some_name"

or with some initial position:

dummy name:"some_name" pos:[3,4,5]

But Dummy is not just a transformation matrix. It also has a box visualization can be directly picked up in the viewport. In fact, most objects in Max has transformation matrix, even a mesh object can be transformed on its own. Objects can be attached to a Dummy. When you move the Dummy, you move everything under it. So it acts like a Group, but a Dummy is not a Group. They show up differently in scene explorer. I still don’t know how to create an empty Group in Max, with or without Max Script:(

So how to select something by name?

bob = getNodeByName "some_name" 
if bob != undefined then 
( 
select bob
)

A strange, and maybe amazing, thing about Max is multiple objects in the same place can have the same name. Means there can be two sphere01 under group01, which is not possible in Maya. I am not sure what is the benefit or trouble about this feature. Better to avoid it anyway.

Advertisements

Leave a comment

Filed under Max Script

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s