Chapter 18: Controlling The 3D World; 3D Lingo Or Javascript Syntax Events - Adobe 65036570 - Director - PC User Manual

User guide
Hide thumbs Also See for 65036570 - Director - PC:
Table of Contents

Advertisement

Chapter 18: Controlling the 3D World

®
®
Adobe
Director
provides powerful methods for overall control of the three-dimensional (3D) world, including
Lingo and JavaScript™ syntax for handling new 3D-generated events, selecting models (picking), vector math opera-
tions, and transforms. In addition, the properties and methods of the Director global
supply common rendering properties for all 3D sprites and cast members. Finally, 3D cast member and sprite
properties and methods allow additional control of their content during playback.
The methods and properties that you see here in tabular form are also available with accompanying syntax, defini-
tions, and examples in the Scripting Reference topics in the Director Help Panel.

3D Lingo or JavaScript syntax events

Event handling lets you use the
occurs within a specific cast member. With the
trigger the handler, the handler name, and the script object that contains the handler. The Lingo or JavaScript syntax
object can be a child script, an instance of a behavior attached to a sprite, or any other script. If the object isn't
specified, the handler is called in the first movie script in which it is found.
Use the following methods to set up event handling:
Method
Description
The event
registerForEvent
(eventName,
#collideAny
handlerName,
scriptInstance,
#collideWith
model)
occurs and implicitly registered when
setCollisionCallback(...)
calling
model.collision.setCollision
Callback
#timeMS
format
(timeMS, handlerName, scriptInstance)
begin, period, repetitions
The
begin
repetitions
nitely.
#animationStarted
motion begins.
#animationEnded
motion ends.
Any user-defined symbol: Registers to receive any user-defined
event sent from a
Unregisters all events.
unregister
AllEvents()_
method to specify a handler to run when a particular event
registerForEvent
registerForEvent
is one of the following:
eventName
: Called when any collision occurs.
: Called when a collision with a specific model
is called. Equivalent to
.
: Sets up a time-based simulation callback using the
registerForEvent
.
and
arguments are in milliseconds. If
period
is set to
, the simulation continues indefi-
0
: Called whenever a keyFrame or bones
: Called whenever a keyFrame or bones
call.
SendEvent
rendererServices
method, you specify the type of event that will
Returns
if the operation
TRUE (1)
succeeds.
if the operation
FALSE (0)
fails.
Nothing.
A script error is generated if
the operation fails.
379
object

Advertisement

Table of Contents
loading

This manual is also suitable for:

Director 11

Table of Contents