Popular Posts

Wednesday, February 23, 2011

Mel Scripting: What is a scriptJob?

When I started mel scripting, I read a ton of forums that talked about how scriptjobs helped... but they never really explained how they worked. When i first tried to use a scriptjob... I crashed Maya. After some experimenting and reading up on details, i finally figured out how they work.

Tuesday, February 22, 2011

Mel Script Example: Keyword Search

For my first post, I though I'd show you how to do something I though was cool, a keyword search feature.




Basic Mel: Variables

Defining Variables

Knowing how to define variables is the first thing you should learn if you want to start Mel Scripting. It is very basic, but after awhile this becomes second nature. Here is an example of how you would define one:

string $variableName = "Toast";

(variable type)  $(variable name) = (value);

The variable type always comes first, followed by the variable name.
The variable name must always come after a dollar sign ($). This lets Maya know the name of the variable.
Finally the value is what that variable equals.
You must end each equation in maya with a semi-colon (;). This tells Maya that this is the end of that equation.