Chapter 49: Automating with MAXScript


The Max designers went to great lengths to make sure that you are limited only by your imagination in terms of what you can do in Max. They've packed in so many different features and so many different ways to use those features that you could use Max for years and still learn new ways of doing things.

Despite Max's wide range of capabilities, there may come a time when you wish for a new Max feature. With MAXScript, you can actually extend Max to meet your needs, customize it to work the way you want, and even have it do some of the more monotonous tasks for you.

What Is MAXScript?

In this chapter, we look at MAXScript-what it's for and why in the world you would ever want to use it. But before we get into the nitty-gritty details, let's start with a brief overview.

Simply put, MAXScript is a tool that you can use to expand the functionality of Max. You can use it to add new features or to customize how Max behaves, so that it's tailored to your needs and style. You can also use MAXScript as a sort of VCR; it can record your actions so you can play them back later, eliminating repetitive tasks.

You can use MAXScript to "talk" to Max about a scene and tell it what you want to happen, either by having Max watch what you do or by typing in a list of instructions that you want Max to execute.

The beauty of MAXScript lies in its flexibility and simplicity: It is easy to use and was designed from the ground up to be an integral part of Max. But don't let its simplicity fool you; MAXScript as a language is rich enough to let you control just about anything.

In fact, you have already used MAXScript without even knowing it. Some of the buttons and rollouts use bits of MAXScript to carry out your commands. And after you've created a new feature with MAXScript, you can integrate it into Max transparently and use it just as easily as any other Max feature.

MAXScript is a fully functional and very powerful computer language, but you don't have to be a computer programmer or even have any previous programming experience to benefit from MAXScript. In the next few sections, we look at some simple ways to use MAXScript. For now, just think of a script in Max as you would a script in a movie or play-it tells what's going to happen, who's going to do what, and when it's going to happen. With your scene acting as the stage, a script directs Max to put on a performance for you.

One final note before we dive in: MAXScript is so powerful that an entire book could be written about it and every last feature it supports, but that is not the purpose here. This chapter is organized to give you an introduction to the world of MAXScript and to teach you the basic skills you need to get some mileage out of it. What is given here is a foundation that you can build upon according to your own interests and needs.




3ds Max 9 Bible
3ds Max 9 Bible
ISBN: 0470100893
EAN: 2147483647
Year: 2007
Pages: 383

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