Controlling the 3D World
523
Collision commands
Collision commands allow you to override certain aspects of the default behavior set for models
during collisions. If neither of the models involved in the collision has
resolve
set to
TRUE
,
you can manually resolve the collision using
resolveA(true)
for model A or
resolveB(true)
for model B.
Selecting models
Selecting models (picking) refers to clicking on models in a 3D cast member. Because models are
objects that exist within a 3D cast member and a 3D sprite, they are not normally sensitive to
mouse clicks. Normally it is only the entire sprite that is sensitive to mouse clicks.
You can use Lingo to determine specifically which models have been clicked when a user clicks
within a 3D sprite. In practice, this allows for changing model positions to make it appear that an
action such as a button being pushed or a door being opened has taken place. Picking can be
accomplished using cast member or camera commands.
pointOf
Contact
Get
Vector describing world-space location of collision. Available
only if the collision has been resolved. Occurs if the model’s
collision modifier
resolve
property is
TRUE (1)
or either the
collisionData resolveA()
or
collisionData
resolveB()
method is called.
collision
Normal
Get
Vector indicating direction of collision. Available only if the
collision has been resolved. Occurs if the model’s collision
modifier
resolve
property is
TRUE (1)
or either the
collisionData resolveA()
or
collisionData
resolveB()
method is called.
Command
Description
Returns
collisionData.resolv
eA
(
trueOrFalse
)
Resolves collision for model A.
Nothing
collisionData.resolv
eB
(
trueOrFalse
)
Resolves collision for model B. If the argument is
FALSE
(0)
, the collision won’t be resolved. This overrides the
collision.resolve
property, if any, set for model B.
Nothing
Property
Access
Description
Содержание 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...