Using the LinkedXForm modifier, Custom Attributes, and Wire Parameters to dilate and contract the pupils.
 

Step 1
You really need to be able to change the size of the pupils if you want that extra bit of emotion for your character. This is used to great effect in anime films. The pupils get really small when someone is in a rage, and really big when someone is sad or feels helpless.

First thing to do is to select the eye and go into sub-object mode and select the vertices surrounding the pupil. I also like to create the eye as a poly object and then set the vertices to be constrained to Edges in the Edit Geometry sub menu. This way the actual shape of the iris won't change as you change the size of the pupil. If this doesn't make any sense to you, don't worry about it. It's not necessary for this to work.

Step 2
Now add a LinkedXForm modifier, but make sure you don't leave sub-object mode.

Step 3
We'll leave the eye for a second and create a Dummy object to link the LinkedXForm modifier to. Make it about the size of the pupil, but it doesn't have be any exact size. Position is extremely important though. You want the center of the Dummy to be centered in the middle of the pupil. Just remember that the pupil is going to scale from the center of the Dummy, so if it's off to the side weird things are going to happen when we're done with this set up.

Step 4
So now go back to the eye, make sure the LinkedXForm modifier is highlighted, click on the Pick Control Object button, and select the Dummy you just created. You'll notice that if you scale the Dummy now that the pupil will grow and contract. This is a good way to test the location of the Dummy before we do all the wiring.

Step 5
We're done with the eye, now we'll add a Custom Attribute (CA) to the helper object controlling the eyes, like we set up in the previous lessons. Use the settings show below and click Add. I went over the parameters in more detail in the last lesson.

Step 6
Right click on the helper object and navigate to the Pupils CA in the sub-menus of the Custom Attributes menu.

Step 7
Without clicking on anything else first, click on the Dummy.

Step 8
And navigate to the Scale property of the Dummy.

Step 9
When the Parameter Wiring window pops up, set the parameters like I have below. Here's an explanation of what's going on:

The Control Direction determines what controls what. And since we want the Pupil spinner to control the scale of the Dummy, and not the other way around, we choose the arrow that points from the helper object to the Dummy.

The expression is in the format [X, Y, Z], and tells Max how to scale the Dummy object based on the input from the spinner. Since we set up our spinner to go from 0 to 1, then the Dummy will be scaled from 0 to twice it's size (1*2=2), which will then drive the pupil itself to go from 0, or disappear, to twice its size.

Step 10
Now go back to Step 1 and repeat for the other eye. And there you have it. You can safely hide the dummies, since you don't need to actually manipulate them directly. Select the helper object and play with the spinner to watch the eyes go all crazy now.

This is the kind of thing that will really set your animation apart from the crowd. It's the little added extras that really make a character come alive. The technique itself is more complicated to set up, but well worth the results.

Click here to go back to the "Eyes" page...