About MEL Commands


Most MEL commands follow a similar format. The command name is always entered first; it may be followed by a list of optional flags, which can be applied in any order. Next come the names of the object(s) the command will be applied to, if necessary, and/or the value(s) the command will use. For example, you could use the command sphere -r 3 to create a sphere with a radius of three, or parent sphere1 sphereGroup to parent an object named sphere1 to sphereGroup.

Flags are used to change the effect of the command in specific ways. Each flag has a name, which may be abbreviated to its equivalent short name. This name is always preceded by a dash: -n or -name, for example. The name of each flag is followed by the value for that flag: for example, -name "mySphere". If you execute a command without including some or all of its flags, Maya will use the default values for those flags.

You can find a complete list of MEL commands in the MEL Command Reference included with Maya. You can browse the list alphabetically or by category, or use the filter to find a specific command more quickly. Each command is linked to an entry that describes its effect, the syntax you need to use, and a list of flags, if any.

To View the MEL Command Reference:

  • From the main Help menu or the Script Editor's Help menu, select MEL Command Reference (Figure 17.6).

    Figure 17.6. You can quickly access the MEL Command Reference from the Script Editor's Help menu.


    The MEL Command Reference opens in a new browser window (Figure 17.7).

    Figure 17.7. The MEL Command Reference displays commands alphabetically by default, but you can also browse by category.


To find a specific command in the MEL Command Reference:

  • In the "By substring(s)" field of the MEL Command Reference, enter the name or part of the name of the command.

    The list of commands is automatically filtered to display only the names that match your text (Figure 17.8).

    Figure 17.8. Entering text in the "By substring(s)" field causes the MEL Command Reference to display only the commands that match that text.





Maya 7 for Windows and Macintosh(c) Visual Quickstart Guide
Maya 7 for Windows & Macintosh
ISBN: 0321348990
EAN: 2147483647
Year: 2006
Pages: 185

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net