![MACROMEDIA DIRECTOR MX 2004-DIRECTOR SCRIPTING Reference Download Page 421](http://html1.mh-extra.com/html/macromedia/director-mx-2004-director-scripting/director-mx-2004-director-scripting_reference_3321720421.webp)
newMember()
421
newLight
Usage
member(
whichCastmember
).newLight(
newLightName
,
#typeIndicator
)
Description
3D command; creates a new light with a specified type, and adds it to the light palette.
Parameters
newLightName
Required. Specifies the name of the new light. The name of the new light must be
unique within the light palette.
typeIndicator
Required. A symbol that specifies the type of the new light. Valid values include
the following:
•
#ambient
is a generalized light in the 3D world.
•
#directional
is a light from a specific direction.
•
#point
is a light source like a light bulb.
•
#spot
is a spotlight effect.
Example
The following statement creates a new light in the cast member named 3D World. It is an
ambient light called "ambient room light".
member("3D World").newLight("ambient room light", #ambient)
newMember()
Usage
-- Lingo syntax
_movie.newMember(
symbol
)
_movie.newMember(
stringMemberType
)
// JavaScript syntax
_movie.newMember(
stringMemberType
);
Description
Movie method; creates a new cast member and allows you to assign individual property values to
child objects.
For new cast members, the
symbol
or
stringMemberType
parameter sets the cast member’s type.
Possible predefined values correspond to the existing cast member types:
#bitmap
,
#field
, and so
on. The
newMember()
method can also create Xtra cast member types, which can be identified by
any name that the author chooses.
It’s also possible to create a new color cursor cast member using the Custom Cursor Xtra. Use
newMember(#cursor)
and set the properties of the resulting cast member to make them available
for use.
After
newMember()
is called, the new cast member is placed in the first empty cast library slot.
Summary of Contents for DIRECTOR MX 2004-DIRECTOR SCRIPTING
Page 1: ...DIRECTOR MX 2004 Director Scripting Reference...
Page 48: ...48 Chapter 2 Director Scripting Essentials...
Page 100: ...100 Chapter 4 Debugging Scripts in Director...
Page 118: ...118 Chapter 5 Director Core Objects...
Page 594: ...594 Chapter 12 Methods...
Page 684: ...684 Chapter 14 Properties See also DVD...
Page 702: ...702 Chapter 14 Properties See also face vertices vertices flat...
Page 856: ...856 Chapter 14 Properties JavaScript syntax sprite 15 member member 3 4...
Page 1102: ...1102 Chapter 14 Properties...