Zebra0.com

alice introductionObjects

Objects

Shows some of the main categories

In Alice, the gallery shows some of the main classes that you can select from: Biped (walk on 2 legs), Flyer (have wings), Prop (inamiate objects such as trees and buildings), Quadruped (walk on 4 legs), Swimmer (lives in water), and Transport (airplanes, cars, boats, etc.) When you select a class and add it to the scene, you have created an object. In other words an object is an instance of a class.

After selecting one of the main classes you will see pictures of the 3D models in that class. Here are some of the Quadruped class models. Notice that the Dragon, DragonBaby, and Elephant have a number in the top right corner.

If you click on the Elephant you will see the four models:

These 3D models are classes. When you select one of these classes and place it in the scene you are creating an instance of that class. You can create many instances of a class. For instance you might want a whole parade of Elephants.

Every class has a way of creating or constructing a new instance of the class. It also has properties and actions that all instances of the class have.

Classes are arranged in a hierarchy: An African Elephant is an Elephant. An Elephant is a Quadruped. A Quadruped is a class. All Elephants have a trunk, but not all quadrupeds.

In everyday terms, a blueprint of a house has properties such as number of rooms, size of the kitchen and whether there is a fireplace. You can't walk into a blueprint and sit down. It is just a model. If a builder follows the blueprint, he can construct an instance of the house. The same blueprint could be used to construct many houses. Each homeowner could change some of the properties such as the color, or trim on the house.

NEXT: Substitutions for things you can't find