Chapter 20
534
Cast member commands
The following commands allow you to reset cast member properties to original values they had at
the time the cast member was imported into Director:
Sprite properties
You can control most sprite properties using the Property inspector. For more information, see
“Using the Property inspector for 3D” on page 448. Use the following properties to work with
3D sprites in Lingo.:
texture
Member
Get and set
Name of cast member to use as the source for the
default texture when
textureType
is set to
#member
.
No texture
percent
Streamed
Get
Percentage of file that has been downloaded, with
values from
0
to
100
.
None
bytes
Streamed
Get
Integer number of bytes that have been
downloaded, with values from 0 to the size of the
file in bytes.
None
streamSize
Get
Total size of stream to be downloaded, with values
from
0
to the size of the file in bytes.
None
state
Get
Current state of streaming. Values are as follows:
0
: unloaded
1
: headerLoading
2
: headerLoaded
3
: mediaLoading
4
: =mediaLoaded
-1
: error
Once state
3
or
4
has been reached, it’s safe to
execute Lingo that manipulates the 3D world.
Before then, access to particular models may fail
because those model definitions may not have been
downloaded.
Also, the
loadFile()
cast member method fails
except at states
0
or
4
.
None
Command
Description
Returns
resetToWorldDefault()
Resets all cast member properties to the values
stored in the original 3D world
Nothing
resetWorld()
Resets the 3D cast member to the state it was in
when the movie first loaded
Nothing
Property
Access
Description
Default
directTo
Stage
Get and set
TRUE (1)
or
FALSE (0)
specification of
whether rendering occurs directly to the Stage or to
the Director offscreen buffer. If
TRUE (1)
, other
sprites that intersect with this sprite may flicker. If
FALSE (0)
, rendering layers well but speed
declines.
TRUE (1)
:
rendering occurs
directly to the
Stage
backColor
Get and set
Background color in all views.
rgb(0,0,0)
camera
Get and set
Determines which camera this sprite is using.
None
Property
Access
Description
Default
Содержание DIRECTOR MX-USING DIRECTOR MX
Страница 1: ...Using Director MX Macromedia Director MX...
Страница 12: ...Contents 12...
Страница 156: ...Chapter 4 156...
Страница 202: ...Chapter 6 202...
Страница 244: ...Chapter 7 244...
Страница 292: ...Chapter 10 292...
Страница 330: ...Chapter 12 330...
Страница 356: ...Chapter 13 356...
Страница 372: ...Chapter 14 372...
Страница 442: ...Chapter 16 442...
Страница 472: ...Chapter 18 472...
Страница 520: ...Chapter 19 520...
Страница 536: ...Chapter 20 536...
Страница 562: ...Chapter 23 562...
Страница 566: ...Chapter 24 566...
Страница 602: ...Chapter 27 602...