Game Development Reference
In-Depth Information
Table 4-1. MovieClip Class Properties
What it represents
Refers to the transparency of an object. You can assign it any value between zero (0)
and 1. Zero means that the object is completely transparent; 1 means that it's com-
pletely opaque. The values in between, such as 0.5, make the object translucent. All
objects start out with a default value of 1.
The height of an object in pixels. If you assign it a value of 100, the object becomes
100 pixels tall. A pixel is an illuminated dot on the screen. One pixel is the smallest
possible size that a graphic can be. However, you can assign a fractional value (a value
with a decimal) if you need to, such as 7.8.
The width of an object in pixels.
nkp]pekj The rotation of the object in degrees. A value from 0 to 180 represents a clockwise
rotation. Values from 0 to - 180 represent a counterclockwise rotation.
The horizontal scale of an object. All objects start out with a o_]haT value of 1. If you
change it to 2, the object will become twice as wide (200%). A value of 0.5 will make
the object 50% narrower. A value of 1.1 will make the object 10% wider.
o_]haT is similar to the se`pd property, except that it deals with percentages of scale
instead of fixed pixels.
Similar to o_]haT, except that it refers to the vertical scale of the object.
Determines whether the display object is visible. The reoe^ha property can take two
values: pnqa or b]hoa. True/false values are known in computer programming termi-
nology as Boolean values. The word Boolean refers to George Boole, the founder of
Boolean algebra, which is the basis of computer mathematics.
The horizontal position of an object on the stage in pixels. The leftmost position of
the stage is 0. If the stage is 550 pixels wide, and you want to position an object in the
center, you'd give the t property a value of 275. To move it to a position 100 pixels
from the right side, you'd give it a value of 450.
The vertical position of an object on the stage. This is also a value in pixels. The very
top of the stage is position 0. As you work your way down, the numbers increase.
This means that if the stage is 400 pixels high, and you want to position an object 100
pixels from the top, you'd give its u property a value of 100. To position it 100 pixels
from the bottom of the stage, you'd give the u property a value of 300.
Search Nedrilad ::

Custom Search