How To Use the CD MEL Scripts
The purpose of this lesson is to familiarize a new user with installing and executing a typical MEL script that can be found on this CD. There are several ways in which Maya is able to process a script. This lesson will go through 2 options: Placing Scripts into Script Directory and Using the Script Editor.
NOTE: MEL scripts provided on this CD have been tested to ensure they will function when the steps below are followed. Scripts from outside sources may not work with these instructions.
What is a MEL script?
A MEL script is a file that contains Maya Embedded Language commands, procedures, or both. Typically, you use a MEL script to execute a sequence of commands.
You can write a MEL script using a text editor then save the MEL script in a file on disk. MEL scripts use the file extension .mel. You can use scripts over and over for different scenes and in different work sessions. When you execute a MEL script, it does not become part of the scene; you must execute the script each time you want to repeat the action.
Read the contents of the script
Before installing or using any script, it is very important to read the comments and description within the script. This can be accomplished with any text editor.
All scripts on the CD will contain information in the header about the purpose and usage of the script. The usage of the script will typically state whether any variables are required to execute it. Also, when reviewing the header, keep note as to whether the script is a reference to another script. In this case, the referenced script must reside in the script directory as outlined in option 1 below. |