Director 8.5 Lingo Reference
Appendix I: Lingo Reference
Whenever you have a large, complex programming language such as Lingo, it is useful to have an alphabetical reference. Every Director 8.5 owner already has one in the form of the Lingo Dictionary book that comes with the program, or the Lingo Dictionary in the online help.This appendix is meant to be a complement to the official documents. In many cases I have simpler entries for quick reference, and in some cases I have more detailed entries. I also tried to do a better job of categorizing and cross-referencing than the official manuals.
Here is a description of what each entry contains:
TopicWhich part of Director the keyword relates to. This is truly a "topic," not a "type." For instance, the systemDate is shown relating to the topic "Date & Time" rather than as a "system property."
TypeCommand, function, property, and so on.
DescriptionA short sentence or paragraph to give you an idea of what the keyword is and how to use it.
Syntax SampleA segment of Lingo code that shows the keyword in use. Sometimes it's a complete example, and other times it's a code snippet. The purpose is to quickly relay to the readers how the syntax works. Sometimes I use an ... to show a space where you can insert other code into the example. Other times, I use the put command to show the syntax in use in the Message window.
See AlsoReferences to other keywords.
See Chapter/AppendixIf the keyword is specifically discussed in a chapter, that chapter is listed here. I also refer to chapters that deal with similar keywords or the same topic, even if that specific keyword does not appear in that chapter.
This list also contains some undocumented keywords. Keep in mind that these are unsupported by Macromedia, which means they could disappear in an updated version very easily, and might not work in some situations.
# Symbols Special Character
Used as the first character of any symbol. Symbols are commonly used as properties in lists. They are also used by Lingo to identify properties of sprites and members. Also used as an optional character in front of hexadecimal color values in the rgb function.
addProp myList, #mySymbol, 7 if member(7).type = #vectorShape then... sprite(7).color = rgb("#FFFFFF")
See Also: symbol, rgb
& Strings Special Character
Concatenates two strings.
myString = "abc"&"def" myString = stringOne&stringTwo
See Also: &&, after, before, into
See Chapter/Appendix: 16
&& Strings Special Character
Concatenates two strings and places a space between them.
myString = "abc"&&"def" myString = wordOne&&wordTwo
See Also: &, after, before, into
See Chapter/Appendix: 16
( ) Logic Special Character
Used to set order of precedence in operations. Also used to surround parameters with objects or function calls.
(5+6)*6 sprite(7).member = member("my member") addTwoNumbers(a,b)
* Math Operator
Multiplies two numbers. When given a number and list, each item in the list will be multiplied by that number. When given two lists, each item in the first list will be multiplied by the corresponding item in the second list. When given two 3D vectors, this will return the dot product of the two vectors. If you multiply a 3D transform by a 3D vector, you will get a new vector that is the original vector with the changes specified in the transform. If you multiply a number by a vector, you will get a new vector with the appropriate change in magnitude.
n = 4*5 n = a*b
See Also: +, -, /
See Chapter/Appendix: 13
+ Math Operator
Adds two numbers. When given a number and a list, the number will be added to each item in the list. When given two lists, each item in the list will added to its corresponding item in the second list. When given two vectors, this will add the components of the vectors.
n = 4+5 n = a+b
See Also: *, -, /
See Chapter/Appendix: 13
, Misc Special Character
Used to separate items in various Lingo syntax such as function calls, handler definitions, global and property statements, lists, and so on.
n = addTwoNumbers(a,b) m = member(memberNumber,castLibNumber) list = [1,2,3,4]
- Math Operator
Subtracts two numbers. When given a number and a list, the subtraction will be performed using the number and each item of the list, and a new list returned. If given two lists, then a new list will be returned with the subtraction performed on each corresponding item. If given two 3D vectors, then this will subtract the components of the vectors.
n = 4-5 n = a-b
See Also: +, *, /
See Chapter/Appendix: 13
. Misc Special Character
Used in syntax that refers to the properties of an object. Also used as a decimal point in numbers.
n = text.length m = member(1).type p = sprite(7).loc n = 4.5
.. Strings Special Character
Used to refer to a consecutive run of items in chunk expressions.
t = myText.word[3..7] t = myText.char[1..80] t = myText.item[4..6]
See Also: char, word, line, item
See Chapter/Appendix: 16
/ Math Operator
Divides two numbers. If given two lists, then each item in the first list will be divided by the corresponding item in the second list and a new list returned. If given a number and list, then the division will be performed using the number and each item in the list and a new list will be returned. If given a 3D vector and a number, this will divide each of the components of the vector by the number and return a new vector. You cannot divide two vectors.
n = 4/5 n = a/b
See Also: +, -, *
See Chapter/Appendix: 13
: Misc Special Character
Used in property lists to separate the property name from its value. Used in case statements.
list = [#a: 1, #b: 2]
See Also: [], case
< Logic Operator
Less than operator.
If 4 < 5 then... if a < b then...
See Also: <=, >, =, <>
See Chapter/Appendix: 13
<= Logic Operator
Less than or equal to operator.
If 4 <= 5 then... if a <= b then...
See Also: <, =, >, <>
See Chapter/Appendix: 13
<> Logic Operator
Not equal operator.
If 4 <> 5 then... if a <> b then...
See Also: =, <, <=, >, >=
See Chapter/Appendix: 13
= Logic Operator
Equals operator.
If 4 = 5 then... if a = b then...
See Also: <>, <, <=, >, >=
See Chapter/Appendix: 13
> Logic Operator
Greater than operator.
If 4 > 5 then... if a > b then...
See Also: <, >=, =, <>
See Chapter/Appendix: 13
>= Logic Operator
Greater than or equal to operator.
If 4 >= 5 then... if a >= b then...
See Also: >, <, =, <>
See Chapter/Appendix: 13
[ ] List Special Character
Used to surround a list declaration or to refer to an item in a list.
[4,5,6], [#a: 1, #b: 2], text.char[1], myList[5]
See Also: :
See Chapter/Appendix: 13
\ Misc Special Character
Used to continue a command on the next line.
if member("myMember").text = "test" then go to frame 1
See Also: ¬
See Chapter/Appendix: 12
¬ Misc Special Character
Used to continue a command on the next line. Obsolete. Use \ instead.
See Also: \
abbr, abbrev, abbreviated Date & Time Modifier
Modifies the date and time properties to return shorter versions.
put the date "3/7/00" put the long date "Tuesday, March 7, 2000" put the abbr date "Tue, Mar 7, 2000"
See Also: date, time
See Chapter/Appendix: 21
abor Programming Command
Exits the handler and also terminates the handler that called the current one, and so on back to the original event handler, exiting that as well.
on myHandler param if gMyGlobal = #idle then abort ... end
See Also: exit, exit repeat, halt
abs Math Function
Returns the absolute value of a number. Has the effect of removing the negative sign from negative numbers.
put abs(-7) 7
See Chapter/Appendix: 13
activateApplication Movie, MIAW Event Handler
Handler gets called when the projector or Director is brought from the background to the foreground. You need to set your preferences to "Animate in Background" while in Director. This is useful when you make a projector and need to check system properties after the user has switched applications and has come back to your projector.
on activateApplication alert "Welcome back!" end
See Also: deactivateApplication, activateWindow
activateWindow MIAW Event Handler
Called when a window is made active by first appearing, or by a user action such as clicking on the window.
on activateWindow go to frame "Window Init" end
See Also: deactivateWindow, openWindow, closeWindow
See Chapter/Appendix: 24
active3DRenderer 3D, Misc Property
Returns the sytem 3D rendering engine currently being used to display 3D members. In Shockwave, users can right+Click the movie and change this on the fly. Possible values are #openGL, #directX7_0, #directX5_2, and #software. The #software value means that the user is not using 3D drivers at all. You can always get this value, but you can only attempt to set it if no 3D sprite is on the Stage at the moment.
on startMovie if the active3Drenderer = #software then alert "You may want to install DirectX or OpenGL before viewing this movie." end if end
See Also: renderDeviceList, getRendererServices
See Chapter/Appendix: 39
activeCastLib Score Recording Property
The number of the most recently accessed cast library. Useful for building authoring tools that need to perform an action based on the author's member selection.
put the activeCastLib 1
See Also: castLib, selectedMembers
See Chapter/Appendix: 26
activeWindow MIAW Property
The active window object. Returns (the stage) if it is the Stage.
forget(the activeWindow)
See Also: open, activateWindow, activeWindow, close, forget, frontWindow, moveWindow
See Chapter/Appendix: 24
actor OOP Function
Undocumented Lingo. It seems that the value of actor(1) returns the memory location of the next object to be added to the actorList. Unconfirmed.
put actor(1) <actor 1 a96fce4>
See Also: actorList, new
See Chapter/Appendix: 26
actorList OOP Property
A special list of child objects to which you can make additions. Each object in the list receives a "stepFrame" message each frame.
myChild = new(script "myParent") add the actorList, myChild
See Also: new, actor
See Chapter/Appendix: 24
add List Command
Adds an item to a linear list. If the list has been sorted with the sort command, the item is added in the proper location. Otherwise, it is added at the end of the list.
list = [1,2,3] put list [1, 2, 3] add list, 4 put list [1, 2, 3, 4] list.add(5) put list [1, 2, 3, 4, 5]
See Also: append, addProp, deleteAt, setAt, sort
See Chapter/Appendix: 13
add See textureLayer
addAtList Command
Adds an item to a linear list at a specific location.
list = [1,2,3] put list [1, 2, 3] addAt list, 2, 99 put list [1, 99, 2, 3] list.addAt(4,999) put list [1, 99, 2, 999, 3]
See Also: add, append, addProp, deleteAt
See Chapter/Appendix: 23
addBackdrop 3D, Cameras Command
Adds a 2D bitmap graphic as a background to a 3D sprite when viewed through that camera. You can add more than one backdrop to a camera view. The first parameter should be a texture reference, the second parameter a location, and the third parameter a rotation.
myTexture = member("my3Dmember").newTexture("My Texture",#fromCaqstMemmber,member("my texture bitmap")) member("my3Dmember").camera[1].addBackdrop(myTexture,point(100,0),90)
See Also: newTexture, removeBackdrop, backdrop, insertBackdrop, overlay
addCamera 3D, Cameras Command
Takes a camera that exists inside a 3D member and adds it to the list of cameras associated with that sprite. If you give this command a second parameter, then the camera will be inserted into the list of cameras at that position.
sprite(1).addCamera(sprite(1).member.camera("myCamera"))
See Also: newCamera, deleteCamera, cameraCount
addChild 3D, Grouping Command
This command will attach a model or other object to another model or other object. From then on, when the "parent" object moves, the child will too.
You can add an optional second parameter to this command. If you use #preserveWorld, then the model remains in the same place as it is attached to its parent. If you use #preserveParent, then the world coordinates of the model are changed taking the new parent as the center of the world for that model.
sprite(1).member.model("parent model").addChild(sprite(1).member.model("child model"))
See Also: parent, child
See Chapter/Appendix: 39
addModifier 3D, Models Command
This will add a modifier to a model. Modifiers can be used for collision detection, ink effects, mesh deform or animation.
sprite(1).member.model("my model").addModifier(#meshDeform)
See Also: bonesPlayer, collision, inker, keyFramePlayer, lod, meshDeform, sds, toon, removeModifier
See Chapter/Appendix: 39
addOverlay 3D, Cameras Command
This command takes a texture and creates a layer that floats above the 3D image when viewed through that camera. This can be used to create a 2D layers meant to be in front of the 3D view, like the bars between window panes in a cockpit.
sprite(1).camera.addOverlay(sprite(1).member.texture("my texture"))
See Also: removeOverlay, addBackdrop
See Chapter/Appendix: 39
addProp List Command
Adds a property name and a value to a property list. If the list has been sorted, the property is added at the proper location.
list = [#a: 1, #b: 2, #c: 3] put list [#a: 1, #b: 2, #c: 3] addProp list, #d, 4 put list [#a: 1, #b: 2, #c: 3, #d: 4] list.addProp(#e,5) put list [#a: 1, #b: 2, #c: 3, #d: 4, #e: 5]
See Also: add, deleteProp, getProp, getAProp, setProp, setAProp, sort
See Chapter/Appendix: 13
addToWorld 3D, Models Command
Models can be removed and added back to the 3D world. This is different than removing or adding a model to the 3D member. Models can be in the 3D member, but not be present in the member's world for display. You can use the removeFromWorld command to remove a model and speed up the member, and then use the addToWorld command to make it appear again.
sprite(1).member.model("my model").addToWorld()
See Also: removeFromWorld
addVertex Vector Command
Inserts a vertex point into a vector shape member. After the vertex number and the vertex point, you can optionally add two lists that have the x and y position of the curve handles.
addVertex(member ("myVector"), 5, point(50,50)) member("myVector").addVertex(5,point(50,50)) member("myVector").addVertex(5,point(50,50),[5,5],[10,10])
See Also: deleteVertex, moveVertex, vertexList, newCurve
See Chapter/Appendix: 20
after Strings Expression
Enables you to use the put command to append one string onto another.
myString = "Hello" put "." after myString put myString "Hello."
See Also: put, before, into
See Chapter/Appendix: 13
alert Misc, Debug Command
Brings up a dialog box that shows a string of text and an OK button. Movie stops while the box is present.
alert "Danger!"
See Chapter/Appendix:
20, 24
alertHook Debug Event Handler, Property
Enables you to set a script member as the one that handles error messages when they occur. Also the name of the event handler that must be in that script to receive the error messages.
When the on alertHook handler is called, it should return a value. A value of -1 halts the movie with no dialog box in Director and shows a stop/continue dialog box in projectors. A value of 0 presents an error message, halts the movie in Director, and shows a stop/continue dialog box in projectors. A value of 1 halts the movie and brings up the debug window if in Director but continues the movie in projectors. A value of 2 brings up the script window in Director but quits projectors. In practice, I have never been able to get a value of 1 to actually bring up the debug window. Instead, it brings up the script window.
Warning: When you use the alertHook, it also captures alert commands, so you cannot use them normally. However, alert commands inside the on alertHook handler work as expected.
on startMovie the alertHook = script("Error Handler") end on alertHook me, err, msg alert "Error:"&&msg return 1 end
See Chapter/Appendix: 33
alignment Text, Field Property
Text or field member property that determines text alignment. Possible values for a field are "left", "right", and "center", while the possible values for a text member are #left, #right, #center, and #full.
member("myText").alignment = #center
See Also: text, lineHeight, font, fontSize, fontStyle, fi XEdLineSpace
See Chapter/Appendix: 16
allowCustomCaching Playback Property
For future use.
allowGraphicMenu Playback Property
If this is set to FALSE, Shockwave context menus will be text-only. If TRUE, the default, Shockwave may use graphics in the context menu.
on prepareMovie the allowGraphicMenu = FALSE end
allowSaveLocal Playback Property
If set to FALSE, the user should not be able to save the movie through context menus in Shockwave. Although this property exists, it is questionable whether it will ever be used to override the HTML tag properties that allow and disallow saving. Better to use those to be safe.
on prepareMovie the allowSaveLocal = FALSE end
See Chapter/Appendix: 36
allowTransportControl Playback Property
For future use.
allowVolumeControl Playback Property
When set to FALSE, disables volume controls in Shockwave.
on prepareMovie the allowVolumeControl = FALSE end
allowZooming Playback Property
When set to FALSE, your movie cannot be stretched in Shockwave or in ShockMachine.
on prepareMovie the allowZooming = FALSE end
alphaThreshold Bitmap Property
A value from 0 to 255 that tells Director when to detect a click on a bitmap according to the value in the Alpha channel. A 0 makes all pi XEls detect hits, where a 255 makes only opaque pi XEls detect hits.
member("my32bitimage").alphaThreshold = 128
See Also: useAlpha
ambient 3D, Shader Property
The ambient property of a shader determines how ambient lights reflect off of the surface.
sprite(1).member.shader("my shader").ambient = rgb("FF0000")
See Also: diffuse, specular, ambientColor
See Chapter/Appendix: 39
ambientColor 3D, Light Property
This is the color and intensity of the ambient light in the 3D member. The ambient light appears to come from all directions and shine on all objects evenly.
sprite(1).member.ambientColor = rgb("CCCCCC")
See Also: directionalColor
ancestor OOP Property
Defines an ancestor to a parent script. All instances of that parent have the handlers of its ancestor made available for use.
the ancestor of me = new(script "myAncestor")
See Also: new, me
See Chapter/Appendix: 23
and Logic Operator
Returns TRUE if both expressions are TRUE; returns FALSE otherwise.
if (a = 1) and (b = 2) then...
See Also: or, not
See Chapter/Appendix: 13
angle 3D, Particle System Property
This emitter property will determine how far away from the direction of emission that a particle might shoot out from. The default value of 180 degrees means that the particle could come from any direction. A value of 90 degrees would mean that the particle would come out of only one hemisphere, while a value of 0 would mean that all particles would be emitted from exactly the same direction.
sprite(1).member.modelResource("my particle system").emitter.angle = 90
See Also: emitter, direction
See Chapter/Appendix: 39
angleBetween 3D, Math Function
Returns the angle in degrees between two vectors.
v1 = vector(25,0,0) v2 = vector(0,25,0) put v1.angleBetween(v2) 90.0000
animationEnabled 3D, Animation Property
If set to FALSE, then any animation in the 3D member will be disabled.
member("my 3D member").animationEnabled = FALSEantiAlias Text, Vector, Flash Property
Determines whether a text, Flash, or vector member is drawn to the screen with anti-aliasing to smooth edges. Can be used as a sprite property for Vector Shape sprites.
member("myVector").antiAlias = TRUE
See Also: Quality
See Chapter/Appendix: 20
append List Command
Adds a value to a linear list. Adds the value to the end, even if the list has been sorted.
list = [1,2,3] put list [1, 2, 3] append list, 4 put list [1, 2, 3, 4] list.append(5) put list [1, 2, 3, 4, 5]
See Also: add
See Chapter/Appendix: 13
applicationPath System Property
Returns the full path to the Director application or the projector. The returned path ends with a path delimiter, either a colon (:) on the Mac or a slash (\) in Windows.
put the applicationPath "Powerbook HD:Director 8:"
See Also: moviePath, movie, fileName
appMinimize System Command
This command minimizes the projector. On the Mac, it moves the application to the background.
on mouseUp appMinimize end
See Also: activateApplication
atan Math Function
Returns the arctangent of a number in radians.
put atan(3.0/6.0) 0.4636
See Also: sin, cos, tan
attenuation 3D, Lights Property
A property of 3D point and spot lights. This oddly-formatted property determines how fast the light fades as it gets further from the source. The vector format is used not as a vector, but the three values define the constant, linear or quadratic amount of fading. Use one value and set the others to 0. If using linear or quadratic, then set the value to something very small, like .00001.
sprite(1).member.light("my light").attenuation = vector(1,0,0)
See Also: color
auto 3D, LOD Property
When set to TRUE, the level of detail in a model will automatically change to reflect processor speed. This requires that targetFrameRate is set to TRUE. If not, the LOD will be determined by the distance of the model from the camera.
sprite(1).member.model("my model").lod.auto = TRUE
See Also: bias, lod
autoBlend 3D, Animation, Bones Property
When turned on, this allows 3D member animations to blend from one animation to another. Can be used with the keyframePlayer or bonesPlayer.
sprite(1).member.model("my model").keyframePlayer.autoblend = TRUE
See Also: blendFactor, blendTime, keyframePlayer
autoCameraPosition 3D, Text Property
When turned on, the camera in a 3D text member will adjust itself to show all of the text.
sprite(1).member.autoCameraPosition = TRUE
See Also: displayMode
autoMask Cursor Property
Determines whether the white pi XEls in an animated cursor are transparent.
member("cursor").autoMask = TRUE
See Also: cursor
autoTab Text, Field Property
Determines whether users can press the Tab key in an editable field or text member and automatically move the insertion point to the next field or text member.
member("text").autoTab = TRUE
See Also: keyboardFocusSprite
See Chapter/Appendix: 16
axisAngle 3D, Math Function
Returns the axis, as a vector, and the amount of rotation of a 3D transform. This is just another way of representing a transform that could be useful in mathematical calculations. This gives you more control over a rotation, whereas the rotate command will always perform a rotation first on the x, then on the y and then on the z axis. This allows you to define an arbitrary axis to rotate around.
back 3D, Primitives Property
Whether the back side of a 3D box primitive is present or not.
sprite(1).member.modelResource("my box resource").back = FALSE
See Also: front, left, right, top, bottom, topCap, bottomCap, newModelResource
backcolor Sprite, Text, Field Property
Old syntax enabling you to specify the background color of a sprite, or the background color of a text or field member. The color number must be between 0 and 255 and correspond to the movie's palette. Use bgColor instead.
sprite(1).backcolor = 35
See Also: bgColor, color
See Chapter/Appendix: 18
backdrop 3D, Camera Property
Refers to one of the backdrops applied to a camera. A backdrop appears as a 2D image behind the 3D world. It remains steady as the camera might swing around to show other parts of the world.
sprite(1).camera.backdrop[1].source = myTexture
See Also: loc, source, scale, rotation, regPoint, blend, count, overlay
BACKSPACE Strings Constant
The equivalent of the character generated by the Delete key on the Mac and the Backspace key in Windows. It is also numtoChar(8).
on keyDown if the key = BACKSPACE then beep() dontpassevent end if end
See Chapter/Appendix: 16
beep Misc, Sound Command
Creates a number of system beeps. The sound depends on the user's system settings. If a number is included, that is the number of beeps created; otherwise, just one beep is performed.
on mouseUp beep(3) end
See Chapter/Appendix: 17
beepOn Misc, Sound Property
If set to TRUE, a beep occurs when the user tries to click where there is no active sprite. Default is FALSE. An active sprite is one that has a script attached to it.
on startMovie the beepOn = TRUE end
before Strings Expression
Enables you to use the put command to place a string at the beginning of another string.
myString = "Hello!" put "Well, " before myString put myString "Well, Hello!"
See Also: put, after, into
See Chapter/Appendix: 13, 16
beginRecording Score Recording Command
Signifies the start of a Score-recording session.
beginRecording sprite(7).loc = 100 updateFrame endRecording
See Also: endRecording, updateFrame
See Chapter/Appendix: 26
beginSprite Behaviors Event Handler
This handler is e XEcuted immediately before the sprite first appears.
on beginSprite me pMyProperty = 1 sprite(me.spriteNum).ink = 36 end
See Also: endSprite, prepareFrame
See Chapter/Appendix: 14
bevelDepth 3D, Text Property
The amount of beveling on the chacters in a 3D text member. The bevelType of the member must be #miter or #round.
member("my 3D text").bevelDepth = 7
See Also: bevelType, extrude3D
bevelType 3D, Text Property
The type of beveling to use on a 3D text member. The options are #none, #miter or #round.
member("my 3D text").bevelType = #miter
See Also: bevelDepth, extrude3D
bgColor Sprite, Text, Field, Vector, Movie, Color Property
Enables you to specify the background color of a sprite, or the background color of a text, field, or vector shape member. You can set it to an rgb structure or a paletteIndex. You can also set the bgColor of the Stage.
sprite(1).bgColor = rgb(255,0,0) (the stage).bgColor = rgb("FF0000")
See Also: rgb, paletteIndex, color
See Chapter/Appendix: 18
bias 3D, LOD Property
This is the percentage of polygons that must stay in a model when the lod.auto property is set to TRUE.
sprite(1).member.model("my model").lod.bias = 50
See Also: auto, lod
birth OOP Command
Old syntax for creating an object from a parent script. Use new instead.
See Also: new
See Chapter/Appendix: 23
bitAnd Math Function
Takes two numbers and performs a logical AND on the bits and returns the result.
a = 5 5=0101 b = 4 4=0100 put bitAnd(a,b) 4
See Also: bitOr, bitXor, bitNot
bitmapSizes Font Property
Returns a list of bitmap sizes included with a font cast member.
put member("myFont").bitmapSizes [9, 10, 12, 14, 18, 24]
See Also: recordFont, characterSet, originalFont
See Chapter/Appendix: 16
bitNot Math Function
Takes two numbers and performs a logical NOT on the bits and returns the result. Numbers are 32-bit, so the operation reverses all 32 bits and often returns a negative number as a result.
a = 1 put bitNot(a) -2
See Also: bitOr, bitXor, bitAnd
bitOr Math Function
Takes two numbers and performs a logical OR on the bits and returns the result.
a = 5 5=0101 b = 6 6=0110 put bitOr(a,b) 7
See Also: bitAnd, bitXor, bitNot
bitRate Shockwave Audio Property
Returns the bitrate, in Kbps, of a streaming sound. Returns 0 when not streaming.
if member("mySWA").bitRate > 16 then...
See Also: bitsPerSample
bitsPerSample Shockwave Audio Property
Returns the original bit depth of the sound. Works only while streaming. Typical values are 8 and 16.
if member("mySWA").bitsPerSample then...
See Also: bitRate
bitXor Math Function
Takes two numbers and performs a logical "exclusive or" on the bits and returns the result.
a = 5 5=0101 b = 6 6=0110 put bitXOr(a,b) 3
See Also: bitOr, bitAnd, bitNot
blend Sprite Property
A value of 0 to 100 determines how much the sprite's pi XEls should blend with the ones behind it. Works with many inks, particularly the Blend ink.
sprite(7).blend = 50
See Also: ink, blendLevel
See Chapter/Appendix: 18
blend 3D, Shader Property
The blend percentage for a 3D shader. The transparent property of the shader must be turned on. This also works for overlays and backdrops.
sprite(1).member.shader("my shader").blend = 50
See Also: transparent
blendLevel Sprite Property
A value of 0 to 255 determines how much the sprite's pi XEls should blend with the ones behind it. Same as blend but with a different scale.
sprite(7).blendLevel = 128
See Also: ink, blend
See Chapter/Appendix: 18
blue Color Property
Extracts the blue property from an rgb color object.
myColor = rgb("336699") put myColor rgb( 51, 102, 153 ) put myColor.blue 153
See Also: green, red, color, rgb
See Chapter/Appendix: 18
blendConstant,
blendConstantList 3D, Shader Property
The blendConstantList contains eight values that determine how up to eight textures blend together to create the shader. Using blendConstant will affect only the first layer.
sprite(1).member.model("my model").blendConstantList[2] = 50
See Also: blendSource, blendFunction
blendFactor 3D, Animation, Bones Property
If you wish to blend bones player animation in a non-linear manner, set autoblend to FALSE and use the blendFactor property of the bones player to determine how much the current animation acts like the previous, rather than the current, animation. This can be used with either the keyframesPlayer or the bonesPlayer objects.
sprite(1).member.model("my model").keyframePlayer.blendFactor = 50
See Also: autoblend, keyframePlayer
blendFunction, blendFunctionList 3D, Shader Property
A shader can have up to eight different textures that blend with each other. The belndFunctionList defines what type of blending to use on each of these texture layers. Possible values are #multiply, #add, #replace, and #blend.
sprite(1).member.shader("my shader").blendFunctionList[2] = #add
See Also: blendConstant, blendSource
blendRange 3D, Particle System Property
The amount of opacity that a particle starts its life with (blendRange.start) and ends its life with (blendRange.end).
sprite(1).member.model("my particles").blendRange.start = 100 sprite(1).member.model("my particles").blendRange.end = 0
See Also: colorRange, emitter
blendSource, blendSourceList 3D, Shader Property
A shader can have up to eight textures that blend together. The blendSourceList defines whether any of these texture use the alpha channel information to further define the blend. The possible values for each item in this list are #alpha or #constant. If #constant, then the blendConstantList is used to define a uniform blend over the entire texture.
sprite(1).member.shader("my shader").blendSourceList[2] = #alpha
See Also: blendFunction, blendConstant
blendTime 3D, Animation, Bones Property
The time between motions in the play list of bones player animation. This can be used with either the keyframesPlayer or the bonesPlayer objects.
sprite(1).member.model("my model").keyframePlayer.blendTime = 500
See Also: autoBlend, blendFactor
bone 3D, Bones Object
Refers to a bone embedded into a model when it was made with a 3D program.
See Also: bonesPlayer
bonesPlayer 3D, Bones Object
Provides access to various bits of information about the bones embedded into a model when it was created in a 3D program. You cannot create a bonesPlayer modifier in Lingo. It must be added by a third-party 3D program.
x = sprite(1).member.model("my model").bonesPlayer.currentTime
See Also: autoBlend, blendTime, blendFactor, bone, currentLoopState, currentTime, lockTransition, playing, playlist, positionReset, rootLock, rotationReset
border Field Property
The size of the black line around a field member.
member("myField").border = 1
See Also: margin, boxType, boxDropShadow, dropShadow
See Chapter/Appendix: 16
bottom Sprite, Misc Property
The bottom vertical position of the sprite. Corresponds to the bottom of the rect of a sprite. Also a property of rect objects.
put sprite(1).rect rect(102, 143, 277, 233) put sprite(1).bottom 233 put sprite(1).rect.bottom 233
See Also: top, left, right, height, rect
See Chapter/Appendix: 18
bottom 3D, Primitives Property
Whether the bottom side of a 3D box primitive is present or not.
sprite(1).member.modelResource("my box resource").bottom = FALSE
See Also: back, front, left, right, top, topCap, bottomCap, newModelResource
bottomCap 3D, Primitives Property
Whether the bottom side of a 3D cylinder primitive is present or not.
sprite(1).member.modelResource("my cylinder resource").bottomCap = FALSE
See Also: back, front, left, right, top, bottom, topCap, newModelResource
bottomRadius 3D, Primitives Property
The radius of the bottom circle in a cylinder primitive.
sprite(1).member.modelResource("my cylinder resource").bottomRadius = 10
See Also: topRadius, radius
bottomSpacing Text Property
A number indicating any extra spacing after a paragraph in a text member. Also works with negative values.
member("myText").line[2].bottomSpacing = 12
See Also: topSpacing, fi XEdLineSpace
See Chapter/Appendix: 16
boundary 3D, Inker Property
Whether or not a line is drawn at the edges of a model. Can also be used with the toon modifier.
sprite(1).member.model("my model").inker.boundary = TRUE
See Also: lineColor, lineOffset, silhouettes, creases, inker, toon
boundingSphere 3D, Math Function
Returns a list with the center of an object, a vector, and the radius of the object, a number value. This will give you an idea of how much space an object takes up and what other objects it may touch. You can also use it with groups.
s = sprite(1).member.model("my model").boundingSphere
boxDropShadow Field Property
The offset of the black drop shadow around a field member. Values from 0 to 255.
member("myField").boxDropShadow = 1
See Also: margin, boxType, border, dropShadow
See Chapter/Appendix: 16
boxType Text, Field Property
The type of text box used for text members and fields. Possible values are #adjust, #fi XEd, #scroll, and #limit. #adjust adjusts the bottom of the member to make sure all text is visible. #scroll shows a system scrollbar to the right side of the text. #limit limits editable text input to the size of the member.
member("myText").boxType = #fi XEd
See Also: editable, rect
See Chapter/Appendix: 16
breakLoop Sound Command
Tells a sound in a sound channel to play out the rest of its looping sequence and then continue with the rest of the sound. It works only when the sound playing has loopStartTime and loopEndTime set and the loop is in the process of occurring.
sound(1).breakLoop()
See Also: loopStartTime, loopEndTime, loopCount, loopRemaining
See Chapter/Appendix: 17
brightness 3D, Shader Property
The amount of white in a #newsprint or #engraver shader.
sprite(1).member.model("my model").shader.brightness = 10
See Also: newShader, engraver, newsprint
broadcastProps Flash, Vector Property
Determines whether changes made to a Flash or vector shape member are immediately shown in the sprites present on the Stage, or whether they are used the next time a sprite appears using that member.
member("myVector").broadcastProps = FALSE
See Chapter/Appendix: 20
browserName Network Command, Property, Function
As a command, enables you to set the default browser used by gotoNetPage. As a function, enables you to get the name of the default browser. In an alternate form, enables you to decide whether the browser launches automatically with the gotoNetPage command.
put browserName() "Powerbook HD:Netscape Communicator Folder:Netscape Communicator" browserName(#enabled, TRUE) browserName myNewBrowserPath
See Also: gotoNetPage
See Chapter/Appendix: 22
bufferSize Flash Property
Determines how many bytes of a linked Flash movie can be loaded into memory at any one time. Works only when the preload property of the member is FALSE. Default is 32,768. Setting it higher results in slower loading, but might improve performance.
member("myFlash").bufferSize = 64000
See Also: preload
See Chapter/Appendix: 20
build 3D, Mesh Command
This command completes the construction of a mesh model resource. To create a mesh model resource, you must first determine the vertex list, the color list, and the faces. Then, you must determine the normals of each face. Then you can use the build command to assemble the mesh.
See Also: generateNormals, newMesh, face, colorList
buttonsEnabled Flash Property
Determines whether the buttons in a Flash sprite are enabled.
sprite(7).buttonsEnabled = FALSE
See Also: actionsEnabled
See Chapter/Appendix: 20
buttonStyle System Property
If 0, users can click button members and roll over other members to highlight them. If FALSE, only the button first clicked is highlighted. Setting this to 1 means that on mouseUp handlers will not be called when the user clicked down on another space and then clicked up on the button.
the buttonStyle = 1
See Also: checkBoxAccess, checkBoxType, buttonType
buttonType Button Property
The type of button for a button member. Values can be #pushButton, #checkBox, or #radioButton.
member("myButton").buttonType = #checkBox
See Also: checkBoxAccess, checkBoxType, buttonStyle
bytesStreamed 3D, Streaming Function
Returns the number of bytes of a 3D member that have arrived
if sprite(1).member.bytesStreamed > sprite(1).member.streamsize then...
See Also: streamSize, state
call OOP Command
Can call a handler in a parent script instance or a sprite behavior instance. Can use a single instance or a list of instances. In the second case, no error message is sent when the handler does not exist. You can also send parameters. You can even use a variable as a reference to the handler.
call(#myHandler, myScriptInstance, param1) call(#myHandler, [myScript1,myScript2], param1,param2)
See Also: callAncestor, sendSprite, sendAllSprites
See Chapter/Appendix: 23
callAncestor OOP Command
Same as call, but sends the message or messages directly to an object's ancestor(s).
See Also: call
See Chapter/Appendix: 23
callFrame Flash Command
This command will tell the Flash movie in a sprite to run the ActionScript code placed on the specified frame. It is similar to the Flash 4 call command.
sprite(1).callFrame(7)
See Also: tellTarget
See Chapter/Appendix: 20
camera 3D, Camera Object
Refers to a camera object in a member, or the single camera being used by a sprite.
sprite(1).camera = sprite(1).member.camera("my camera")
See Also: cameraCount, cameraPosition, cameraRotation, addCamera, deleteCamera
cameraCount 3D, Camera Function
Returns the number of cameras in the member used by the sprite.
See Also: camera, addCamera, deleteCamera
cameraPosition 3D, Camera Property
A shortcut to get and set the location of the default camera.
sprite(1).member.cameraPosition = vector(0,0,0)
See Also: camera, cameraRotation
cameraRotation 3D, Camera Property
A shortcut to get and set the orientation of the default camera.
sprite(1).member.cameraRotation = vector(90,0,0)
See Also: camera, cameraLocation
cancelIdleLoad Memory Command
Cancels loading of members with a specific tag number.
cancelIdleLoad(1)
See Also: idleLoadTag
See Chapter/Appendix: 34
case Programming Structure
Starts a case statement. Is followed by a test value and then of. Following lines list possible values, followed by a colon. Can use an otherwise statement to deal with all other possible values. The whole structure must end with an end case.
case a of 1: beep 2: beep go to frame 1 3,4: halt otherwise: go to frame 7 end case
See Also: if
See Chapter/Appendix: 13
castLib Casts Object
Defines a cast object. Can accept a name or number.
put castLib(2) (castLib 2) put castLib(2).name "Database"
See Also: castLibNum
castLibNum Member, Sprite Property
Returns the cast library number of the member or the member used by the sprite. You can set the sprite to use the member in the same position in a different cast library.
put member(1).castLibNum 1 sprite(7).castLibNum = 2
See Also: memberNum, member
castLibs Casts Function
When used as the number of castLibs, it returns the number of cast libraries.
put the number of castlibs 2
See Also: castLibNum
castMemberList Cursor Property
The list of members used by an animated cursor.
put member("myCursor").castMemberList
See Also: cursor
See Chapter/Appendix: 21
center Digital Video Property
A value of TRUE centers the video when the crop property is also TRUE.
member("myVideo").center = TRUE
See Also: crop
centerRegPoint Vector, Flash, Bitmap Property
When set to TRUE, the registration point is automatically centered when the sprite is resized.
member("myVector").centerRegPoint = FALSE
See Also: regPoint, originMode, originPoint
See Chapter/Appendix: 20
centerStage Movie Property
When TRUE, the Stage is centered on the monitor when the movie is opened.
on prepareMovie the centerStage = TRUE end
See Also: fixStageSize
changeArea Transition Property
With this property you can set a transition member to affect either the whole Stage or just the changed area.
member("myTransition").changeArea = TRUE
See Also: transitionType, chunkSize
channelCount Sound Property
Returns the number of channels in a sound. Typical values are 1 and 2, with 2 usually meaning a stereo sound.
put member("mySound").channelCount
See Chapter/Appendix: 17
char Strings Expression
Used to specify a single character or range of characters in a string chunk.
myString = "Hello World." put myString.char[7] "W" put myString.char[4..8] "lo Wo"
See Also: word, line, item, chars
See Chapter/Appendix: 16
characterSet Font Property
This property returns a string that specifies the characters included with a font member. You can specify the characters when creating a font member.
put member("myFont").characterSet "1234567890.- "
See Also: recordFont, bitmapSizes, originalFont
See Chapter/Appendix: 16
charPosToLoc Text, Field Function
Returns the point location of a character in a text or field member. It is relative to the upper-left corner of the member.
put charPosToLoc(member("myText"),7) point(36, 9)
See Also: locToCharPos, locVToLinePos, linePosToLocV, mouseChar
See Chapter/Appendix: 16
chars Strings Function
Returns a range of characters in a string. Obsolete. Use char instead.
put chars("Hello World",4,8) "lo Wo"
See Also: char
See Chapter/Appendix: 16
charSpacing Text Property
Specifies additional or less spacing between characters in a text member. For instance, a value of 1 would be an additional point between characters.
put member("myText").char[5..9].charSpacing 0 member("myText").char[5..9].charSpacing = 5
See Also: fi XEdLineSpace
See Chapter/Appendix: 16
charToNum Strings Function
Converts a character to its ASCII character value.
put charToNum("A") 65
See Also: numToChar, integer, value
See Chapter/Appendix: 16
checkBoxAccess Button Property
A system property. When set to 0, users can check and uncheck check bo XEs and radio buttons. When set to 1, users can only check them. When set to 2, users can't do either.
the checkBoxAccess = 0
See Also: checkBoxType, hilite
See Chapter/Appendix: 15
checkBoxType Button Property
A system property. Enables you to determine what a checked check box looks like. 0 puts an "X" inside it, 1 puts a small black box inside it, and 2 fills the box completely.
the checkBoxType = 1
See Also: checkBoxAccess, hilite
See Chapter/Appendix: 15
checkMark Menu Property
A menu item property. It enables you to check and uncheck a single menu item.
the checkMark of menuitem 1 of menu 1 = TRUE
See Also: menuitem, installMenu
See Chapter/Appendix: 21
child 3D, Grouping Function
A way to refer to a model that is the child of another model.
sprite(1).member.model("my model").child[1].rotate(90,0,0)
See Also: addChild, parent
chunkSize Transition Property
Determines the smoothness of a transition member. Values are 1 to 128, with 1 being the smoothest, but slowest.
member("myTransition").chunkSize = 4
See Also: transitionType, changeArea, puppetTransition
clearAtRender 3D, Camera Property
If you set this property to FALSE, then models in the 3D world will leave trails as objects move or change.
sprite(1).camera.colorBuffer.clearAtRender = FALSE
See Also: colorBuffer, clearValue
clearValue 3D, Camera Property
If clearAtRender is set to TRUE, then this is the color used to clear the screen before each redraw. The default is black.
sprite(1).camera.colorBuffer.clearValue = rgb("FFFFFF")
See Also: colorBuffer, clearAtRender
clearCache Network Command
Clears Director's or a projector's network cache. This does not affect a browser's cache when used in Shockwave.
clearCache
See Also: cacheDocVerify, cacheSize
clearError Flash Command
Resets the error state of a streaming Flash movie.
clearError(member("myFlash"))
See Also: state, getError
clearFrame Score Recording Command
Clears all the sprites from the current frame during Score recording.
clearFrame
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
clearGlobals System Command
Sets the value of all globals to VOID.
clearGlobals
See Also: global, showGlobals
clickLoc Mouse Property
Returns a point with the location of the last mouse click. Works only from the object clicked, such as a sprite or frame, and inside an on mouseUp or on mouseDown handler.
on mouseUp me if (the clickLoc).locH < sprite(me.spriteNum).locH then means that the user clicked to the left of the registration point end if end
See Also: mouseLoc, clickOn
clickMode Flash Property
When set to #boundingBox, clicks and rollovers are detected anywhere in a Flash sprite's rectangle. When set to #object, clicks and rollovers are detected when over a filled portion of the sprite. When set to #opaque, the behavior is like #object if the sprite's ink is Background Transparent and is like #boundingBox otherwise.
member("myFlash").clickMode = #object
See Chapter/Appendix: 20
clickOn Mouse Property
Returns the number of the sprite that was last clicked. Returns a 0 if no sprite was clicked. Sprites must have some behavior applied to them, if even just a comment in an empty script, to effect a change to the clickOn when clicked.
if the clickOn = 7 then go to frame "other" end if
See Also: clickLoc, rollover
clone 3D, Models Command
Creates an identical copy of a model in the same place. It shares the model resource, shaders, and textures with the original model.
sprite(1).member.model("my model").clone("my new model")
See Also: cloneDeep, cloneModelFromCastMember
cloneDeep 3D, Models Command
Creates a copy of a model, like the clone command, but also makes a copy of the model resources used and any children of the model.
sprite(1).member.model("my model").cloneDeep("my new model")
See Also: clone, cloneModelFromCastMember
cloneModelFromCastmember 3D, Models Command
Makes a copy of a model from another member inside the current member. Same as cloneDeep.
sprite(1).member.cloneModelFromCastmember("my new model", "my old model", member("old model member"))
See Also: clone, loadFile
cloneMotionFromCastmember 3D, Animation Command
Makes a copy of a motion from another cast member.
sprite(1).member.cloneMotionFromCastmember("my new motion", "my old motion", member("old model member"))
close MIAW Command
Hides a MIAW. The MIAW is still there; you need to use forget to really get rid of it.
on mouseUp close window ("myWindow") end
See Also: open, forget
See Chapter/Appendix: 24
closed Vector Property
TRUE makes the vector shape closed, and fills it with a solid color or a gradient.
member("myVector").closed = TRUE
See Chapter/Appendix: 20
closeWindow MIAW Event Handler
Called when the movie is running as a MIAW and the window is closed.
on closeWindow forget(the activeWindow) end
See Also: openWindow, activateWindow
See Chapter/Appendix: 24
closeXLib Xtras Command
Disposes of an Xtra that has been loaded into memory.
closeXlib "FileIO"
See Also: openXLib
See Chapter/Appendix: 25
collision 3D, Collision Detection Modifier
When you add the collision detection modifier to a model, handlers will be called in the event that another object with a collision modifier collides with this model. The #collideAny and #collideWith events must be run through registerForEvent before they are able to be recognized.
See Also: registerForEvent, addModifier
See Chapter/Appendix: 39
collisionData 3D, Collision Detection Special
Although collisionData is listed as an entry in Director 8.5's documentation, there is no such thing. They use it to define the one paramater returned to a handler set to handle collision callbacks by registerForEvent or registerScript. In fact, you could call this paramater anything you want, like "myCollisionInformation" for instance.
Whatever you call the parameter, you can get four sub-properties of this unusual object. The modelA and modelB properties are references to the two models involved in the collision. The pointOfContact is the location of the collision. The collisionNormal is a vector in the direction of the collision.
Oddly enough, you can also use this object to e XEcute two commands: resolveA and resolveB. You can set these to TRUE or FALSE to override the collision resolution settings and stop or not stop either model or both from moving after the collision.
on myCollisionHandler me, myCollisionData put myCollisionData.modelA, myCollisionData.modelB end
See Also: registerForEvent, registerScript, setCollisionCallback
See Chapter/Appendix: 39
collisionNormal See collisionData color
Misc, Sprite, Text, Field, Vector, Color Object
A color object can be either an rgb structure or a paletteIndex structure. You can use the color function to create these objects as well. This keyword is also a property of sprites, 3D lights and fog, and of text, field, and vector shape members.
myColor = color(#rgb,255,255,255) myColor = color(#paletteIndex,35) sprite(7).color = rgb(255,0,0)
See Also: colorType, rgb, paletteIndex, red, green, blue, bgColor, foreColor
See Chapter/Appendix: 18
colorBufferDepth See getRendererServices colorDepth
System
Property
The current color depth of the user's monitor. Usually 8, 16, 24, or 32. You can set this property on a Mac and some Windows machines.
if the colorDepth < 16 then alert "You're still using 8-bit? Get with it!" end if
See Also: switchColorDepth, depth
See Chapter/Appendix: 34
colorList 3D, Mesh Property
You can use this list to set the colors of the faces in a mesh model.
See Also: face, mesh
colorRange.start, colorRange.end 3D, Particle Systems Property
The starting and ending color of a particle.
sprite(1).member.modelResource("my particle system").colorRange.start = rgb("FF0000")
See Also: blendRange, sizeRange, tweenMode
See Chapter/Appendix: 39
colors 3D, Mesh Property
This is a reference to a color used to color in a face of a mesh model.
See Also: face, colorList
colorSteps 3D, Model, Shader Property
This property of a toon model or a painter shader lets you set the number of colors used to draw the model to either 2, 4, 8 or 16.
sprite(1).member.model("my model").toon.colorSteps = 2
See Also: highlightPercentage, shadowPercentage, toon, painter
See Chapter/Appendix: 39
colorType Misc, Color Property
A property of a color structure. Returns #rgb if it's an rgb structure and #paletteIndex if it's a paletteIndex structure. The best part is that you can set this property to convert between them.
mmyColor = rgb(255,0,0) put myColor.colorType #rgb myColor.colorType = #paletteIndex put myColor paletteIndex( 35 )
See Also: color, rgb, paletteIndex
See Chapter/Appendix: 18
commandDown Keyboard Property
Returns TRUE if the user is holding down the key on the Mac or the Ctrl key in Windows.
if the commandDown then...
See Also: controlDown, optionDown, shiftDown, keyPressed
See Chapter/Appendix: 16
comments Member Property
Returns the comments text for the member. This text is entered in the property inspector by the movie creator. It usually is removed when a Shockwave movie is created, but you can choose to include comments in Shockwave movies in the Publish Settings.
if member("myMember").comments contains "alternative" then...
See Also: creationDate, modifiedBy, modifiedDate, name
compressed 3D, Shader Property
When a bitmap member is used as a texture, and the bitmap member is compressed, then the compressed property of the texture is TRUE until the texture is first used, as which point it will be decompressed. If you try to set it to FALSE, then the bitmap will be decompressed immediately. If it is FALSE and then set to TRUE again, the decompressed bitmap will be released from memory until it is needed again.
sprite(1).member.texture("my texture").compressed = FALSE
See Also: texture
constrainH Sprite Function
Takes a sprite number and an integer as parameters. If the number is outside the horizontal boundaries of the sprite, it returns the value of the left or right side. Otherwise, it returns the integer unchanged.
sprite(me.spriteNum).locH = constrainH(7,the mouseH)
See Also: constrainV
constraint Sprite Property
A value of greater than 0 constrains the location of a sprite to the bounding box of another sprite. A value of 0 means no constraint.
sprite(7).constraint = 6
constrainV Sprite Function
Takes a sprite number and an integer as parameters. If the number is outside the vertical boundaries of the sprite, it returns the value of the top or bottom side. Otherwise, it returns the integer unchanged.
sprite(me.spriteNum).locV = constrainV(7,the mouseV)
See Also: constrainV
contains Strings Operator
Determines whether a string is found anywhere inside another.
if myString contains ".com" then...
See Also: =, offset, starts
See Chapter/Appendix: 16
controlDown Keyboard Property
Returns TRUE if the user is holding down the Control key on the Mac or the Ctrl key in Windows.
if the controlDown then...
See Also: commandDown optionDown, shiftDown, keyPressed
See Chapter/Appendix: 16
controller Digital Video Property
Enables you to test for and turn on or off the control strip for a QuickTime video. Does not work with Video for Windows.
member("myVideo").controller = TRUE
See Also: directToStage
See Chapter/Appendix: 19
copyPi XEls Image Command
Enables you to copy a rectangle from one image to a rectangle or quad-defined area in another. The first parameter is the source image, the second is the destination source or rect, the third is the source rect, and the last is a list of properties that modify the copy. The properties you can specify in that list are #color, #bgColor, #ink, #blendLevel, #dither, #useFastQuads, #maskImage, and #maskOffset. These properties modify the copy in the same way they modify a sprite's appearance on the Stage.
myImage.copyPi XEls(myOtherImage,rect(50,50,150,150),rect(0,0,100,100)) myImage.copyPi XEls(myOtherImage,[point(50,50),point(150,50), point(170,150),point(70,150)]) myImage.copyPi XEls(myOtherImage,rect(50,50,150,150),rect(0,0,100,100),[#color: rgb("FF0000"),#ink: 41])
See Also: ink, color, fill, image
See Chapter/Appendix: 18
copyrightInfo Shockwave Audio Property
Returns the copyright information embedded into a Shockwave Audio file. Sound must be preloaded or playing first.
member("myText").text = member("mySWA").copyrightInfo
See Chapter/Appendix: 17
copyToClipBoard Member Command
Copies the media of a member to the computer's clipboard.
copyToClipBoard(member("myText"))
See Also: pasteClipBoardInto
cos Math Function
Returns the cosine of an angle. Angle must be in radians.
put cos(1.0) 0.5403 put cos(pi) -1.0000 put cos(2*pi) 1.0000
See Also: sin, tan, atan, pi
See Chapter/Appendix: 13
count List, Strings, Misc, 3D Property
Returns the number of items in a list. Returns the number of properties in a script object. Returns the number of globals with (the globals), and the number of chunks with strings.
list = [1,2,3,4,5] put list.count 5 myText = "This is a test." put myText.word.count 4
See Also: showGlobals, length
See Chapter/Appendix: 13
cpuHogTicks System Property
Works on the Mac only. Determines how often Director allows the CPU to process other tasks. Default is 20. Set lower to enable the computer to run more smoothly in general, higher to have Director hog the CPU, thereby producing smoother animation.
on startMovie the cpuHogTicks = 40 end
See Chapter/Appendix: 34
creaseAngle 3D, Inker Property
How sensitive inker and toon modifiers are to drawing lines at creases in the model. The range is -1 to 1.
sprite(1).member.model("my model").inker.creaseAngle = .5
See Also: creases, lineColor, lineOffset, useLineOffset
creases 3D, Inker Property
Whether lines are drawn at creases when a model is using the inker or toon modifier.
sprite(1).member.model("my model").inker.creases = TRUE
See Also: creaseAngle, lineColor, lineOffset, useLineOffset
See Chapter/Appendix: 39
createMask Image Function
Makes a gradient image from an image. This can then be used with the #maskImage modifier of the copyPi XEls command.
member("myImage").image.copyPi XEls(member("otherImage").image, rect(0, 0, 100, 100), member("Happy").rect, \ [#maskImage:member("myGradient").image.createMask()])
See Also: copyPi XEls, createMatte
See Chapter/Appendix: 18
createMatte Image Function
Makes a matte image from an image. This matte image can then be used with the #maskImage modifier of the copyPi XEls command. You need to use one parameter with createMattea value between 0 and 256 that determines how much of the Alpha channel to use as the matte.
member("myImage").image.copyPi XEls(member("otherImage").image, rect(0, 0, 100, 100), member("Happy").rect, \ [#maskImage:member("myMatte").image.createMatte(128)])
See Also: copyPi XEls, createMask
See Chapter/Appendix: 18
creationDate Member Property
Returns a date object that shows the creation date of the member.
put member(1).creationDate date( 2000, 1, 22 )
See Also: comments, modifiedDate, modifiedBy
See Chapter/Appendix: 26
crop Bitmap Command
Crops an image to the size of the rectangle specified. If used on a member, behaves like the Director 7 crop command and crops a bitmap member to a new rectangle.
myImage = member("picture").image myImage.crop(rect(50,50,100,100)) member("picture").image = myImage
See Also: image, copyPi XEls, fill, picture
See Chapter/Appendix: 18
crop Digital Video Property
When FALSE, the digital video is scaled to fit the sprite rectangle. When TRUE, the video is presented at 100%, but is cropped by the sprite rectangle.
member("myVideo").crop = TRUE
See Also: center
See Chapter/Appendix: 19
cross, crossProduct 3D, Math Function
Takes two vectors and returns a vector that is perpendicular to them.
myVector = vector(1,0,0).cross(vector(0,1,0)) put myVector vector( 0.0000, 0.0000, 1.0000 )
See Also: crossProduct, perpendicularTo
cuePassed Sound Event Handler
This handler is called when a cue point is passed in a sound. It sends the sound channel number, the number of the cue point, and the name of the cue point into the handler. If used by a frame behavior, you can insert the me parameter as the first parameter.
on cuePassed channelNum, cuePointNum, cuePointName member("lyrics").text = cuePointName end
See Also: cuePointNames, cuePointTimes, isPastCuePoint
See Chapter/Appendix: 17
cuePointNames Sound, Digital Video Property
Returns a list of cue point names in a sound member.
myCues = member("mySound").cuePointNames
See Also: cuePointTimes, cuePassed, isPastCuePoint
See Chapter/Appendix: 17
cuePointTimes Sound, Digital Video Property
Returns a list with the time of each cue point, in milliseconds. Each item corresponds to the same item in the cuePointNames list.
myCueTimes = member("mySound").cuePointTimes
See Also: cuePointNames, cuePassed, isPastCuePoint
See Chapter/Appendix: 17
currentLoopState 3D, Animation Property
Whether the keyframePlayer or the bonesPlayer animation loops.
sprite(1).member.model("my model").keyframePlayer.currentLoopState = TRUE
See Also: loop, play, queue, playList
currentSpriteNum Behaviors Property
Returns the number of the sprite whose script is currently running. Works only in behaviors or cast scripts. It is obsolete and me.spriteNum should be used instead.
sprite(the currentSpriteNum).ink = 36
See Also: spriteNum, me
currentTime Sound, Digital Video, 3D Property
Returns the current time, in milliseconds, of a sound or digital video sprite. This also works for animation in a 3D member.
if sprite(1).currentTime = sprite(1).member.duration then go next
See Also: movieTime, duration
See Chapter/Appendix: 17, 19
cursor Cursor Command
Enables you to use a number, 1-bit bitmap, pair of 1-bit bitmaps, or animated cursor member as a cursor.
cursor(4) cursor([member("myCursor")]) cursor([member("myCursor"), member("myMask")]) cursor(member("myAnimatedCursor"))
See Chapter/Appendix: 21
cursor Sprite Property
Enables you to set a cursor to be used when the cursor is over a sprite. To remove this property, set it to -1.
on beginSprite me sprite(me.spriteNum).cursor = 3 end
See Chapter/Appendix: 21
cursorSize Cursor Property
For animated cursor members, enables you to set the cursor size to 16 or 32.
member("myAnimatedCursor").cursorSize = 32
See Also: cursor
See Chapter/Appendix: 21
curve Vector Property
This property extracts a single continuous line from a vertexList of a vector shape member. It enables you to get and set this line. You can also use the vertexList property, which returns a list of all the continuous lines in a vector shape, separated by #newcurve items.
put member("myVector").curve[1] [[#vertex: point(3.0000, -20.0000)], [#vertex: point(141.0000, -20.0000)],
[#vertex: point(141.0000, 110.0000)], [#vertex: point(3.0000, 110.0000)]]
See Also: vertex, vertexList
See Chapter/Appendix: 20
date System Property
Reads the user's computer clock and returns the date in various formats. You can use "abbr", "long", and "short" as modifiers. The actual result depends on the date settings on the user's computer.
put the date "3/18/00" put the short date "3/18/00" put the long date "Saturday, March 18, 2000" put the abbr date "Sat, Mar 18, 2000"
See Also: abbr, long, short, time, systemDate
See Chapter/Appendix: 21
date Date & Time Object
An object type. Can accept an integer, a string, or three integers initially. Object converts to a series of three integers: year, month, and day.
d = date(20000312) put d date( 2000, 3, 12 ) d = date(2000,3,17) put d.year 2000 put d.day 17
See Also: day, month, year, seconds, systemDate
See Chapter/Appendix: 21
day Date & Time Property
A property of a date object.
d = date(2000,3,17) put d.day 17
See Also: date, month, year, seconds, systemDate
See Chapter/Appendix: 21
deactivateApplication Movie, MIAW Event Handler
Handler gets called when the projector or Director is sent to the background. You need to set your preferences to "Animate in Background" while in Director. This is useful when you make a projector and need to check system properties when the user has switched applications.
on deactivateApplication alert "Goodbye!" end
See Also: activateApplication, activateWindow
deactivateWindow MIAW Event Handler
Called when a window is the active window, but is then deactivated because the user clicks on another window or another window opens.
on deactivateWindow sound(1).play(member("close window sound"))
See Also: activateWindow, openWindow, closeWindow
See Chapter/Appendix: 24
debug 3D, Misc Property
If TRUE, then a bounding sphere and a XEs of a model will be shown. This wil not work in software rendering mode.
sprite(1).member.model("my model").debug = TRUE
See Also: boundingSphere
See Chapter/Appendix: 39
decayMode 3D, Camera Property
Defines how fog density builds. Values can be either #linear, #exponential or #exponential2.
sprite(1).camera.fog.decayMode = #linear
See Also: camera, fog
See Chapter/Appendix: 39
defaultRect Flash, Vector Property
The default size for sprites created using that Flash or vector shape member, or for existing sprites that have not been stretched. Works only when the defaultRectMode is set to #fi XEd. This property automatically changes defaultRectMode to #fi XEd when it is changed.
member("myFlash").defaultRect = rect(0,0,100,100)
See Also: defaultRectMode
See Chapter/Appendix: 20
defaultRectMode Flash, Vector Property
Either #Flash or #fi XEd. The first means that the real size of the member will be used in nonstretched sprites. The second means that the defaultRect property will be used.
member("myFlash").defaultRectMode = #Flash
See Also: defaultRect
See Chapter/Appendix: 20
delay Navigation Command
Place in an on exitFrame or on enterFrame handler to extend the playback time of a frame by a number of ticks.
on exitFrame if pMyProperty = 2 then delay 60 end if end
See Also: ticks
delete Strings Command
Deletes a chunk expression from a string.
delete myString.word[2].char[5]
See Also: char, word, line, item
See Chapter/Appendix: 16
deleteAll List Command
Removes all items from a list.
deleteAll myList
See Also: deleteAt
See Chapter/Appendix: 13
deleteAt List Command
Removes a single item from a linear or property list.
deleteAt(myList,7) myList.deleteAt(7)
See Also: addAt, getAt
See Chapter/Appendix: 13
deleteCamera 3D, Camera Command
Removes a camera from the member.
sprite(1).member.deleteCamera("my camera")
See Also: camera, newCamera
See Chapter/Appendix: 39
deleteFrame Score Recording Command
Removes the current frame and moves all frames after the current frame down one during Score recording.
beginRecording deleteFrame endRecording
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
deleteGroup 3D, Groups Command
Deletes a group from the 3D member. The models in the group are removed from the world, but still exist in the member and may be added back to the world.
sprite(1).member.deleteGroup("my group")
See Also: newGroup
See Chapter/Appendix: 39
deleteLight 3D, Lights Command
Removes the light from the 3D member,
sprite(1).member.deleteLight("my light")See Also: newLight
See Chapter/Appendix: 39
deleteModel 3D, Models Command
Removes a model from the 3D world and from the member.
sprite(1).member.deleteModel("my model")
See Also: deleteModelResource, newModel, removeFromWorld
See Chapter/Appendix: 39
deleteModelResource 3D, Models Command
Deletes a model resource from the member. Models that use the resource lose their geometry so they become invisible.
sprite(1).member.deleteModelResource("my model resource")
See Also: deleteModel, removeFromWorld
See Chapter/Appendix: 39
deleteMotion 3D, Animation Command
Removes a motion from the member.
sprite(1).member.removeMotion("my motion")
See Also: newMotion
deleteOne List Command
Removes the first value in the list that matches the value given to this command.
deleteOne myList, valueToDelete myList.deleteOne(valueToDelete)
See Also: deleteAt, deleteProp
See Chapter/Appendix: 13
deleteProp List Command
Removes the first property in a property list that matches the property given to this command.
deleteProp myList, propToDelete myList.deleteProp(propToDelete)
See Also: deleteAt
See Chapter/Appendix: 13
deleteShader 3D, Shader Command
Removes a shader from the member.
sprite(1).member.deleteShader("my shader")
See Also: newShader, shaderList, deleteTexture
See Chapter/Appendix: 39
deleteTexture 3D, Shader Command
Removes a texture from the member.
sprite(1).member.deleteTexture("my texture")
See Also: deleteShader, newTexture
See Chapter/Appendix: 39
deleteVertex Vector Command
Removes a vertex point from a Vector shape member.
deleteVertex(member("myVector"), 2) member("myVector").deleteVertex(2)
See Also: addVertex, moveVertex, vertexList, curve
See Chapter/Appendix: 20
density 3D, Shader Property
The number of lines or dots used by an engraver or newsprint shader.
sprite(1).member.shader("my shader").density = 20
See Also: newShader
See Chapter/Appendix: 39
depth Bitmap Property
Returns the bit depth of a bitmap member.
if member("myBitmap").depth > 8 then...
See Also: colorDepth
See Chapter/Appendix: 18
depth 3D, Subdivision Surfaces Property
The maximum resolution (depth of recursion) that a model can display when using subdivision surfaces.
sprite(1).member.model("my model").sds.depth = 2
See Also: sds, tension
See Chapter/Appendix: 39
deskTopRectList System Property
Returns a list of rectangles that corresponds to the monitor(s) connected to the computer.
put the desktopRectList [rect(0, 0, 1024, 768)]
See Also: rect, sourceRect, drawRect
See Chapter/Appendix: 21
diffuse 3D, Shader, Lights Property
The color of a shader surface as used by diffuse lighting. Along with ambient, this setting determines the color of a model.
sprite(1).member.shader("my shader").diffuse = rgb("FF0000")
See Also: ambient, diffuseColor, useDiffuseWithTexture, specular
See Chapter/Appendix: 39
diffuseColor 3D, Lights Property
The color blended with the first texture of the first shader in a member.
sprite(1).member.diffuseColor = rgb("FF0000")
See Also: diffuse, useDiffuseWithTexture
See Chapter/Appendix: 39
3D, See Also:
See Chapter/Appendix:
diffuseLightMap 3D, Shader Property
The texture to use for diffuse light mapping in a shader.
sprite(1).member.shader("my shader").diffuseLightMap = sprite(1).member.texture("my texture")
See Also: textureModeList, glossMap, reflectionMap, specularLightMap
digitalVideoTimeScale Digital Video Property
A system property that contains a units-per-second timescale that Director uses to track video. A value of 0 means that Director uses the scale of the currently playing video.
on beginSprite me the digitalVideoTimeScale = 0 end
See Also: movieTime, duration, movieRate
See Chapter/Appendix: 19
digitalVideoType Digital Video Property
Returns #quickTime or #videoForWindows.
put member("myVideo").digitalVideoType #quickTime
See Chapter/Appendix: 19
direction 3D, Particle System Property
The direction in which particles are emitted. The angle must be set to something less than 180 degrees or the direction really doesn't matter.
sprite(1).member.modelResource("my particle system").emitter.direction = vector(0,1,0)
See Also: angle
See Chapter/Appendix: 39
directionalColor 3D, Light Property
The color of the default directional light in a 3D member.
sprite(1).member.directionalColor = rgb("CCCCCC")
See Also: ambientColor, directionalPreset
directionalPreset 3D, Lights Property
The direction of the default directional light in a member. Possible values are: #topLeft, #topRight, #topCenter, #bottomLeft, #bottomRight, #bottomCenter, #middleLeft, #middleRight, #middleCenter, or #none.
sprite(1).member.directionalPreset = #topRight
See Also: directionalColor
directToStage Flash, Vector, Digital Video, Animated GIF, 3DF Property
Whether the member or sprite is drawn directly to the Stage, speeding up playback, but not using sprite inks. Sprites using this appear on top of other sprites, regardless of their ordering in the Score.
member("myVideo").directToStage = TRUE sprite(7).directToStage = TRUE
See Chapter/Appendix: 19, 20
displayFace 3D, Text Property
Which of the three parts of 3D text to show. A complete list would include #font, #back and #tunnel.
sprite(1).member.displayFace = [#front, #tunnel, #back]
See Also: extrude3D, displayMode
See Chapter/Appendix: 4
displayMode 3D, Text Property
For a text member, set this to #Mode3D to display the text as 3D, #ModeNormal is the default.
sprite(1).member.displayMode = #Mode3D
See Also: displayFace, extrude3D
See Chapter/Appendix: 4
distanceTo 3D, Math Function
Returns the distance between two vector points.
v1 = vector(9,14,7) v2 = vector(4,1,-6) put v1.distanceTo(v2) 19.0526
See Also: magnitude
See Chapter/Appendix: 39
distribution 3D, Particle System Property
How particles are emitted over time. The possible values are #linear or #gaussian.
sprite(1).member.modelResource("my particle system").emitter.distribution = #gaussian
See Also: region
See Chapter/Appendix: 39
dither Bitmap Property
If TRUE, a 16-bit or higher bitmap is dithered when shown on an 8-bit screen. This results in a better image, but slower performance.
member("myBitmap").dither = TRUE
See Also: depth
See Chapter/Appendix: 18
do Programming Command
This powerful command takes a string and e XEcutes it as a Lingo command. You can include any Lingo syntax, including calls to your own handlers.
myString = "gMyGlobal = 7 + 2" do myString put gMyGlobal 9
See Also: value
dontPassEvent Programming Command
Made obsolete by stopEvent. Prevents an event, such as a mouseUp, from passing to the next message level. For instance, a behavior can prevent the message from passing to the movie script. This is considered obsolete because messages are never passed on, unless the pass command is used.
See Also: stopEvent, pass
dot, dotProduct 3D, Math Function
Returns a number that is the sum of the products of two vectors. If both vectors have the length of 1, then the result is the cosine of the angle between the vectors.
v1 = vector(1,1,0) v2 = vector(0,1,1) put v1.dot(v2) 1.0000
See Also: getNormalized, crossProduct
doubleClick Mouse Property
Returns a TRUE if the last two mouse clicks were very close together. An odd property, because a true double-click needs to occur on the same object, whereas this property can return TRUE if the two clicks occurred on different sprites.
if the doubleClick then...
See Also: mouseDown, mouseUp
downloadNetThing Network Command
Transfers a file from an Internet location to the local disk. Use netDone to see whether the operation is complete. Does not work in Shockwave for security reasons.
gNetID = downloadNetThing("http://clevermedia.com/images/cmad3.gif", "temp.gif")
See Also: netDone
See Chapter/Appendix: 22
drag 3D, Particle System Property
How much momentum is lost for each step in the particle system movement. This must be set to some value for wind to have any affect.
sprite(1).member.modelResource("my particle system").drag = 50
See Also: wind, gravity
See Chapter/Appendix: 39
draw Image Command
Draws a line, rectangle, or oval in an image object. You need to specify a starting x and y location, an ending x and y location, and an optional set of parameters. These parameters include #lineSize, #color, and #shapeType. The #shapeType can be #line, #oval, #rect, or #roundRect. These are unfilled shapes. Use the fill command to draw filled shapes.
myImage = member("picture").image myImage.fill(10,20,50,60,[#color: rgb("FF0000"), #shapeType: #line, #lineSize: 2])
See Also: image, fill, copyPi XEls, setPi XEl
See Chapter/Appendix: 18
drawRect MIAW Property
Returns the rectangle of a window. You can set this property too, which results in the scaling of bitmaps and some other sprites.
put window("myMIAW").drawRect put (theStage).drawRect
See Also: sourceRect
See Chapter/Appendix: 24
dropShadow Field Property
The offset of the black shadow under text in a field member.
member("myField").dropShadow = 4
See Also: margin, boxType, boxDropShadow, border
See Chapter/Appendix: 16
duplicate Member Command
Creates a copy of a member. It places it in the next available member slot, or in a specific slot if specified.
duplicate member("myMember") duplicate member("myMember"),member("newMember","otherCast")
See Also: new, erase
duplicate List, Image, 3D Function
Returns a new list, identical to the one it is given. This is needed because lists are objects, so setting a variable equal to a list creates only another pointer to the same list, rather than a new list. It will also create a new, duplicate image from an image object. It also works with 3D vectors.
newList = duplicate(myist)
duplicateFrame Score Recording Command
During Score recording, this creates a new frame, identical to the current one, and places it after the current one. It also advances the playback head one frame.
on beginRecording duplicateFrame end
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
duration Transition, Digital Video, Shockwave Audio, 3D Property
The length of the transition (milliseconds), video (ticks), SWA (ticks, only while streaming), or 3D motion.
if sprite(7).movieTime = sprite(7).member.duration then...
See Also: percentPlayed, movieTime, movieRate
See Chapter/Appendix: 19
editable Text, Field, Sprite Property
When TRUE, the text or field member can be edited by the users. If not TRUE as a member property, the member can still be edited if the sprite property is TRUE.
Member("myText"). editable = TRUE sprite(7).editable = TRUE
See Also: autoTab
See Chapter/Appendix: 16
editShortCutsEnabled Text Property
If set to TRUE, this enables users to use standard cut, copy, and paste shortcuts while typing in editable text members. Default is TRUE.
the editShortCutsEnabled = FALSE
See Also: editable
See Chapter/Appendix: 18
elapsedTime Sound Property
Returns the time, in milliseconds, that the sound has been playing. This time includes any looping.
if sound(1).elapsedTime > 60000 then...
See Also: currentTime
See Chapter/Appendix: 17
else Programming Structure
Enables alternative conditions to be set up inside an if statement.
if a = 4 then go to frame "this" else if a = 7 then go to frame "that" else go to frame "other" end if
See Also: if
See Chapter/Appendix: 13
emissive 3D, Sahder Property
This property will add light to the surface used by the shader. The light won't be coming from any source, but the surface will act as if the light is there anyway. This is a good way to brighten a model's surface independent of the lighting in a scene.
sprite(1).member.shader('my shader").emissive = rgb("FF0000")
See Also: shininess
See Chapter/Appendix: 39
emitter 3D, Particle System Object
The emitter keyword must be used to access various particle system properties.
sprite(1).member.modelResource("my particle system").emitter.angle = 5
See Also: angle, numParticles, mode, loop, minSpeed, maxSpeed, region, distribution, path, pathStrength
See Chapter/Appendix: 39
EMPTY Strings Constant
Any empty string with 0 length. Same as "".
if myString = EMPTY then...
See Also: SPACE, VOID, voidP, length
See Chapter/Appendix: 16
emulateMultiButtonMouse Mouse Property
If TRUE, a Control+click on the Mac acts like a right mouse button click on Windows.
the emulateMultiButton Mouse = TRUE
See Also: rightMouseDown, rightMouseUp
enabled Menu Property
A menu item property that allows you to enable or disable a single menu item.
the enabled of menuitem 1 of menu 1 = TRUE
See Also: menuitem, installMenu
See Chapter/Appendix: 21
enabled 3D Property
The enabled property can be used to turn on or off fog, collision detection or subdivision surfaces.
sprite(1).member.model("my model").collision.enabled = FALSE
See Also: collision, fog, sds
See Chapter/Appendix: 39
enableHotSpot QTVR Command
Allows you to enable or disable a hotspot in a QTVR movie.
EnableHotSpot(sprite(7),myHotSpot,TRUE)
end Programming Misc
The line that marks the end of a handler. Also used as end if, end case, and end repeat to mark the end of those structures.
See Also: if, case, repeat
endAngle 3D, Primitives Property
Together with startAngle, this indicates the amount of a sphere or cylinder primitive to draw.
sprite(1).member.modelResource("my sphere resource").endAngle = 180
See Also: startAngle
See Chapter/Appendix: 39
endColor Vector Property
Destination color of a gradient. Has an effect only when the fillMode is set to #gradient.
Member("myVector").endColor = rgb(255,0,0)
See Also: fillMode, fillColor, fillCycles, fillDirection, fillOffset, fillScale, closed
See Chapter/Appendix: 20
endFrame Sprite Property
Returns the last frame of a sprite span.
put sprite(7).endFrame
See Also: startFrame
endRecording Score Recording Command
Used to signify the end of a Score recording session.
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
endSprite Behaviors Event Handler
This event handler is called when the movie moves out of a frame, and on to one that does not contain the sprite.
on endSprite me gScore = 0 end
See Also: beginSprite
endTellTarget Flash Command
This command will end the targeting begun by tellTarget.
See Also: tellTarget
See Chapter/Appendix: 20
endTime Sound Property
The duration of a sound, in milliseconds.
if sound(1).endTime > 60000 then...
See Also: startTime
See Chapter/Appendix: 17
ENTER Strings Constant
Represents the character generated by the Enter key on the numeric keypad.
on keyUp me if the key = ENTER then beep end
See Also: RETURN
See Chapter/Appendix: 16
enterFrame Behaviors Event Handler
This handler is called just after Director draws the current frame, but before any idle time occurs.
on enterFrame me if sprite(me.spriteNum).locH > 640 then... end
See Also: prepareFrame, exitFrame, idle
See Chapter/Appendix: 13
environment System Property
Returns a list containing platform, runMode, colorDepth, and other information.
put the environment [#shockMachine: 0, #shockMachineVersion: "", #platform: "Macintosh,PowerPC",
#runMode: "Author", #colorDepth: 32, #internetConnected: #online, #uiLanguage: "English",
#osLanguage: "English", #productBuildVersion: "178"]
See Also: platform, runMode, colorDepth
See Chapter/Appendix: 21
erase Casts Command
Enables you to remove a member from a Cast.
erase member("myUselessMember")
See Also: duplicate, new, move
error 3D, Subdivision Surfaces Property
The amount of error allowed when rendering the model using subdivision surfaces.
sprite(1).member.model("my model").sds.error = 0
See Also: sds
See Chapter/Appendix: 39
EvalScript Shockwave Event Handler
Receives events sent by the browser from JavaScript or VBScript "EvalScript()" functions. Accepts parameters as well. Can also use a return command to send a value back to the browser when it is done.
on EvalScript myParam if myParam = "Jump Button" then go next end if end
See Also: externalEvent
See Chapter/Appendix: 22
eventPassMode Flash Property
Determines how events such as mouse clicks are passed through a Flash sprite or member to the sprite's behavior. Possible values are #passAlways, #passButton, #passNotButton, and #passNever. The #passButton and #passNotButton buttons refer to when a button in the Flash movie is clicked.
on beginSprite me sprite(me.spriteNum).eventPassMode = #passNever
See Chapter/Appendix: 20
exit Programming Command
Exits the current handler without e XEcuting any more commands. The handler that called the current one, if any, continues.
on myHandler if gMyGlobal > 7 then exit gMyGlobal = gMyGlobal + 1 myOtherHandler(gMyGlobal) end
See Also: abort
exit repeat Programming Command
Ends the current repeat loop immediately, skipping any code left in that instance of the loop and starting with the first line of code after the loop.
repeat while myVar < 7 if myVar = 3 then exit repeat myVar = myOtherHandler(myVar) end repeat
See Also: repeat
See Chapter/Appendix: 13
exitFrame Behaviors Event Handler
This handler is called just before Director leaves the current frame.
on exitFrame me sprite(me.spriteNum).locH = sprite(me.spriteNum).locH + 1 end
See Also: enterFrame, beginSprite, endSprite, idle
See Chapter/Appendix: 13, 14
exitLock Navigation Property
If this system property is set to TRUE, users cannot use the keys such as +Q, Ctrl+Q, +., Ctrl+., or Esc to quit a projector.
the exitLock = TRUE
See Chapter/Appendix: 21
exp Math Function
Returns the natural logarithm base, e, to the power given.
put exp(3) 20.0855
See Also: log
See Chapter/Appendix: 13
externalEvent Shockwave Command
Sends a string to the browser, which it interprets with JavaScript or VBScript.
externalEvent("myJavaScriptFunction()")
See Also: EvalScript
See Chapter/Appendix: 22
externalParamCount Shockwave Function
Returns the number of parameters in the <EMBED> or <OBJECT> tag for a Shockwave movie.
numParams = externalParamCount()
See Also: externalParamName, externalParamValue
See Chapter/Appendix: 22
externalParamName Shockwave Function
Returns the name of a specific parameter from the <EMBED> or <OBJECT> tag in the browser.
paramName = externalParamName(2)
See Also: externalParamName, externalParamCount
See Chapter/Appendix: 22
externalParamValue Shockwave Function
Returns the value of a specific parameter from the <EMBED> or <OBJECT> tag in the browser.
paramName = externalParamValue(2)
See Also: externalParamCount, externalParamValue
See Chapter/Appendix: 22
extractAlpha Image Function
Returns an 8-bit image that corresponds to the Alpha channel of the image specified.
myAlpha = member("myImage").image.extractAlpha()
See Also: setAlpha, useAlpha
See Chapter/Appendix: 18
extrude3D 3D, Text Command
Creates a 3D model resource from a text member and then places it in a 3D member.
my3Dtext = member("my text member"). extrude3D(member("my 3D member")) member("my 3D member").newModel("my 3D text model",my3Dtext)
See Also: displayMode
See Chapter/Appendix: 4, 39
face 3D, Mesh Object
Use the face object to work with properties of an individual face in a mesh object. This can also be used as a list that identifies the vertices in a face in a mesh deform.
sprite(1).member.modelResource("my model resource").face.shader = myShader
See Also: colors, normals, shader, texture, vertices, newMesh, meshDeform
See Chapter/Appendix: 39
fadeIn Sound Command
Silences the sound, and then gradually brings it up to its previous setting over a period of time in milliseconds.
sound(1).play(member("mySound")) sound(1).fadeIn(2000)
See Also: fadeOut, fadeTo
See Chapter/Appendix: 17
fadeOut Sound Command
Gradually lowers a sound to a volume of 0 over a period of time in milliseconds.
sound(1).play(member("mySound")) sound(1).fadeOut(2000)
See Also: fadeIn, fadeTo
See Chapter/Appendix: 17
fadeTo Sound Command
Gradually brings a sound from its current volume to a new one over a period of time in milliseconds. Volume is a number from 0 to 255.
sound(1).fadeTo(128,2000)
See Also: fadeIn, fadeOut
See Chapter/Appendix: 17
FALSE Logic Constant
Logical false. Use in if, repeat, case, or other logic statements. Equivalent to 0.
if myVar = FALSE then...
See Also: if, repeat, case, TRUE
See Chapter/Appendix: 13
far 3D, Camera Property
The distance from the camera where the fog reaches its maximum density.
sprite(1).camera.fog.far = 1000
See Also: near, fog
See Chapter/Appendix: 39
field Field Object
Old syntax that can be used to refer to field members the same way as member in many cases. It really refers to the text of the member, so it cannot be used as a member reference.
if field("myField") = "done" then...
See Also: member
fieldOfView QTVR Property
The current field of view of a QTVR sprite in degrees.
sprite(7).fieldOfView = 60
fieldOfView 3D, Camera Property
The field of view determines how the 3D world is mapped on to the 2D screen. The projection property must be set to #perspective. The default setting is 30. This is similar to using different lenses on a real-life camera.
sprite(1).camera.fieldOfView = 60
See Also: projection
See Chapter/Appendix: 39
fileName Casts, Member, MIAW Property
Refers to the external file path of either a cast library, member, or MIAW. In many cases, can also be an Internet location.
member("myExternalVideo").fileName = "newvideo.mov" castLib("myCast").fileName = "newcast.cst"
See Also: url, importFileInto
fileSaveMode 3D, Misc Property
This is an undocumented property of 3D members. Its default value is #saveOriginal, which means that any Lingo changes to the 3D models in a member will not be saved in the member permanently. However, if you use #saveMarked, then any models that are cloned will also be saved in the member. If you use #saveScene setting, then changes to existing models will be saved, but not new models created. If you use #saveAll, then all changes to the models will be saved.
sprite(1).member.fileSaveMode = #saveAll
fill Image Command
Creates a filled rectangle in an image. The first four parameters are the left, top, right, and bottom sides of the rectangle. The fifth parameter can either be a color, or a short list with #shapeType, #lineSize, #color, and #bgColor. The shape types can be #rect, #oval, #roundRect, or #line. The #bgColor property specifies the color of the line or border, whereas #color specifies the color of the fill.
myImage = member("picture").image myImage.fill(10,10,50,50,rgb("FF0000")) myImage.fill(25,25,35,35,[#shapeType: #oval, #color: rgb("FF0000"), #bgColor: rgb("0000FF"), #lineSize: 2])
See Also: image, draw, copyPi XEls, setPi XEl
See Chapter/Appendix: 18
fillColor Vector Property
The primary fill color for a closed vector shape member. Also the starting color if a gradient is used.
member("myVector").fillColor = rgb(0,0,255)
See Also: endColor, fillMode, fillCycles, fillDirection, fillOffset, fillScale, gradientType, closed
See Chapter/Appendix: 20
fillCycles Vector Property
The number of cycles in a gradient fill of a closed vector shape member.
member("myVector"). fillCycles = 2
See Also: endColor, fillColor, fillMode, fillDirection, fillOffset, fillScale, gradientType, closed
See Chapter/Appendix: 20
fillDirection Vector Property
The number of degrees of rotation of a gradient fill for a closed vector shape member.
member("myVector").fillDirection = 90
See Also: endColor, fillColor, fillMode, fillCycles, fillOffset, fillScale, closed
See Chapter/Appendix: 20
filled Shape Property
Whether the shape member is filled.
member("myOval").filled = TRUE
See Also: pattern, color
See Chapter/Appendix: 20
fillMode Vector Property
The type of fill used by a closed vector shape member. Possible values are #none, #solid, and #gradient.
member("myVector").fillMode = #gradient
See Also: endColor, fillColor, fillDirection, fillCycles, fillOffset, fillScale, gradientType, closed
See Chapter/Appendix: 20
fillOffset Vector Property
The position offset of a fill in a closed vector shape.
member("myVector").fillOffset = point(100,50)
See Also: endColor, fillColor, fillDirection, fillMode, fillCycles, fillScale, gradientType, closed
See Chapter/Appendix: 20
fillScale Vector Property
The scale of a gradient fill for a closed vector shape.
member("myVector").fillScale = 2
See Also: endColor, fillColor, fillDirection, fillMode, fillCycles, fillOffset, gradientType, closed
See Chapter/Appendix: 20
findEmpty Casts Function
When given a cast member, returns the next empty member in that Cast.
nextMemberToUse = findEmpty(member("myBitmap"))
See Also: erase, duplicate, move
findLabel Flash Function
Returns the frame number in a Flash movie that is associated with the label name. Warning: This function does not always work on a sprite the first instant that the sprite appears. You may have trouble trying to use it in an on beginSprite handler.
sprite(7).frame = findLabel(sprite(7),"myLabel")
See Also: frame
See Chapter/Appendix: 20
findPos List Function
Returns the position of a property in a property list, and returns VOID if it isn't in the property list.
put findPos(myList, #myProp) put myList.findPos(#myProp)
See Also: findPosNear
See Chapter/Appendix: 13
findPosNear List Function
Returns the position of a property in a property list, or the value in a linear list. If the item isn't in the list, it returns the closest alphanumeric match. The list must be sorted first with the sort command.
put findPosNear(myList, myVal) put myList.findPosNear(myVal)
See Also: findPos, sort
See Chapter/Appendix: 13
finishIdleLoad Memory Command
Forces idle loading to complete for members with a specific idle load tag.
finishIdleLoad 7
See Also: idleLoadTag
See Chapter/Appendix: 21
firstIndent Text Property
A property of a chunk inside a text member. It provides for a left indent at the start of new lines. Measured in pi XEls.
member("myText").line[1..3].firstIndent = 18
See Also: leftIndent, rightIndent
See Chapter/Appendix: 16
fi XEdLineSpace Text Property
The line height of a specific line or all the lines in a text member. A value of 0 enables the line height to be determined by the font and size.
member("myText").line[1..7].fi XEdLineSpace = 14
See Also: lineHeight
See Chapter/Appendix: 18
fi XEdRate Animated GIF, Flash Property
If the playbackMode property of a member or sprite is set to #fi XEd, this controls the frame rate. Default is 15 frames per second.
member("myGIF").fi XEdRate = 5
See Also: playbackMode
See Chapter/Appendix: 20
fixStageSize Movie Property
If TRUE, the Stage remains the same size when a new movie is loaded, even if that movie uses a different Stage size.
the fixStageSize = TRUE
See Also: centerStage, drawRect
See Chapter/Appendix: 21
flashRect Flash, Vector Property
Returns the original size of a Flash or vector shape member.
put member("myFlash").flashRect
See Also: defaultRect, defaultRectMode, state
See Chapter/Appendix: 20
flashToStage Flash Property
Returns the point on the Stage that matches a point in a Flash sprite.
put flashToStage(sprite(7),point(50,30))
See Also: stageToFlash, hitTest
See Chapter/Appendix: 20
flat 3D, Shader Property
When flat is set to TRUE, then only one color is used per face.
sprite(1).member.shader("my shader").flat = TRUE
See Chapter/Appendix: 39
flipH Sprite Property
If TRUE, the sprite appears flipped horizontally on the Stage.
sprite(7).flipH = TRUE
See Also: flipV
See Chapter/Appendix: 18
flipV Sprite Property
If TRUE, the sprite appears flipped vertically on the Stage.
sprite(7).flipV = TRUE
See Also: flipH
See Chapter/Appendix: 18
float Math Function
Converts an integer or string to a floating point number.
put float(5) 5.0000 put float(".5") 0.5000
See Also: floatPrecision, integer, value
See Chapter/Appendix: 13
floatP Math Function
Tests an expression and returns TRUE if it is a floating point number.
a = 5 put floatP(a) 0 a = 5.0 put floatP(a) 1
See Also: integerP, voidP, float
See Chapter/Appendix: 13
floatPrecision Math Property
This system property determines how many decimal places are to be returned in any floating point number math. Default is 4. Values can go up to 15. A 0 means that all floating point functions will round to an integer. A negative number is the same as a positive one, but all floating point math uses absolute (positive) values.
a = 5.5 put a 5.5000 the floatPrecision = 2 put a 5.50 the floatPrecision = 0 put a 6 the floatPrecision = 8 put a 5.50000000
See Also: float
See Chapter/Appendix: 13
flushInputEvents System, Mouse Command
E XEcuting this command flushes the system of any input events, such as mouse clicks or keyboard presses. This is useful if you have a pause in your program caused by a long transition, loading time, or a long repeat loop. You can then use this command to throw away events that users might have triggered while waiting. Works only in projectors and Shockwave, not in Director.
on getMemberList long repeat loop here list = [] repeat with i = 1 to 100000 add list, member(i,2).name end repeat clear any clicks from impatient user flushInputEvents() return list end
fog 3D, Camera Object
Refers to the fog settings of a camera.
sprite(1).camera.fog.near = 100
See Also: near, far, color, decayMode, enabled
See Chapter/Appendix: 39
font Text, Field, Button Property
The name of the font used by a member, or a chunk in a member.
member("myText").font = "Times" member("myText").char[6..12].font = "Courier"
See Also: fontSize, fontStyle
See Chapter/Appendix: 16
fontList Fonts Function
This undocumented property of a font member will return a list of all of the names of fonts on the computer.
put member("my font member").fontList()
See Also: outlineFontList
fontSize Text, Field, Button Property
The size of the font used by a member, or a chunk in a member.
member("myText").fontSize = 12 member("myText").char[6..12].fontSize = 14
See Also: font, fontStyle
See Chapter/Appendix: 16
fontStyle Text, Field, Button Property
The style(s) used by a member, or a chunk in a member. Field and buttons use a string such as "bold, italic," whereas text members use a list, such as [#bold, #italic].
member("myField").fontStyle = "Bold" member("myText").fontStyle = [#bold]
See Also: font, fontSize
See Chapter/Appendix: 16
forecolor Text, Field, Sprite Property
Can be used to set the color of text in a field or text member to a palette index number. Can also be used to set the forecolor of a sprite. Made mostly obsolete by color.
member("myField").forecolor = 35 sprite(7).forecolor = 215
See Also: color, backcolor
See Chapter/Appendix: 18
forget MIAW, Timeout Command
Removes a MIAW or a timeout object from memory. If a variable refers to it, the forget command won't work until that variable is set to 0.
forget window("myMIAW") timeout("myTimeout").forget()
See Also: close, timeout
See Chapter/Appendix: 24
frame Movie Property
The number of the current frame that is playing.
if the frame = 7 then... go to the frame + 2
See Also: frameLabel, marker, label, go
See Chapter/Appendix: 13
frame Flash Property
The number of the current frame in the Flash movie sprite.
sprite(7).frame = 6
See Also: findLabel, frameCount
See Chapter/Appendix: 20
frameCount Flash Property
Returns the number of frames in a Flash member.
sprite(7).frame = sprite(7).member.frameCount
See Also: frame, findLabel
See Chapter/Appendix: 20
frameLabel Movie, Score Recording Property
Returns the label of the frame that is currently playing. If there is no label on the current frame, it returns a 0. Can be set during Score recording.
if the frameLabel = "Chapter 1" then...
See Also: frame, labelList
See Chapter/Appendix: 13
framePalette Movie, Score Recording Property
Returns the palette member used in the current frame. Can be set during Score recording.
the framePalette = -1
See Also: puppetPalette, beginRecording, endRecording
See Chapter/Appendix: 26
frameRate Flash, Digital Video Property
You can use this to get, but not set, the frame rate of a Flash member. You can set the frame rate of a digital video member from 0 to 255. A value of -1 sets the video to play at a normal rate, and a value of -2 sets the video to play as fast as possible.
if member("myVideo").frameRate = -1 then...
See Also:fi XEdRate, movieRate, movieTime, playbackMode
See Chapter/Appendix: 19, 20
frameReady Shockwave Function
Returns TRUE if a frame or range of frames have been loaded in Shockwave streaming. If no parameters are passed in, it returns TRUE only if all the members used in the Score are ready.
on exitFrame me if frameReady(10,90) then go to the frame + 1 else go to the frame end if end
See Also: mediaReady
See Chapter/Appendix: 22
frameReady Flash Function
Returns TRUE if a Flash sprite's frame has been loaded and is ready to play.
if frameReady(sprite(7),25) then...
See Chapter/Appendix: 20
frameScript Movie, Score Recording Property
Returns the member used in the Frame Script channel of the current frame. Can be set during Score recording. Made somewhat obsolete by setScriptList.
the frameScript = member("myScript")
See Also: scriptInstanceList, setScriptList, beginRecording, endRecording
See Chapter/Appendix: 26
frameSound1 Movie, Score Recording Property
Returns the sound member used in the first sound channel of the current frame. Can be set during Score recording.
the frameSound1 = member("mySound")
See Also: puppetSound
See Chapter/Appendix: 26
frameSound2 Movie, Score Recording Property
Returns the sound member used in the second sound channel of the current frame. Can be set during Score recording.
the frameSound2 = member("mySound")
See Also: puppetSound
See Chapter/Appendix: 26
framesToHMS Misc Function
Takes a number of frames and tempo and returns a string with hours, minutes, and seconds, as in "00:01:30.X." It requires two other parameters: one set to TRUE only when you want to compensate for NTSC video frame timing, and one set to TRUE when the final portion (the X in the example string) is in frames or seconds.
put framesToHMS(2000,15,FALSE,FALSE) " 00:02:13.05 "
See Also: HMStoFrames
frameTempo Movie, Score Recording Property
Returns the tempo used in the current frame. Can be set during Score recording.
the frameTempo = 30
See Also: puppetTempo, beginRecording, endRecording
See Chapter/Appendix: 26
frameTransition Movie, Score Recording Property
Returns the transition member used in the current frame. Can be set during Score recording.
the frameTransition = member("myTransitionMember")
See Also: puppetTransition, beginRecording, endRecording
See Chapter/Appendix: 26
freeBlock System Function
Returns the largest free block of memory available to the movie in bytes.
put freeBlock() 12492960
See Also: freeBytes, memorySize, ramNeeded, size
See Chapter/Appendix: 21
freeBytes System Function
Returns the total number of bytes available to the movie.
put freeBytes() 54048052
See Also: freeBlock, memorySize, ramNeeded, size
See Chapter/Appendix: 21
front 3D, Primitives Property
Whether the front side of a 3D box primitive is present or not.
sprite(1).member.modelResource("my box resource").front = FALSE
See Also: back, left, right, top, bottom, topCap, bottomCap, newModelResource
frontWindow MIAW Property
Returns the frontmost window. If the frontmost window is the Stage, it returns (the stage). If a Director palette is frontmost, it returns VOID.
if the frontWindow = window("myWindow") then...
See Also: activeWindow, moveToFront
See Chapter/Appendix: 24
generateNormals 3D, Mesh Command
This command will create all the normals needed for a mesh object. You could create these yourself using the normalList as well. You can use #smooth or #flat as a parameter.
sprite(1).member.modelResource("my model resource").generateNormals(#smooth)
See Also: normalList, normals, build
See Chapter/Appendix: 39
generateOutlines Fonts Command
This undocumented command will take a font member and a text string and create a list of vertices from the text. You can then apply this list of vertices to a vector member to recreate the text as a vector member. However, this only seems to work with a few letters at a time as the letters created are very large and a vector member has size limits.
myVertexList = member("Arial *").generateOutlines("ABC") member("my vector").vertexList = myVertexList
getaProp List Function
Returns the value of a property in a property list. If the property is not present, it returns VOID.
list = [#a: 4, #b: 6, #c: 9] put getAProp(list,#b) 6 put getAProp(list,#d) <Void>
See Also: getAt, getProp
See Chapter/Appendix: 13
getAt List Function
Returns the value at a specific position in a linear or property list. If the position is beyond the end of the list, it generates an error message.
list = [4,6,9] put getAt(list,2) 6 put list.getAt(2) 6 put list[2] 6
See Also: getProp
See Chapter/Appendix: 13
getBehaviorDescription Behaviors Event Handler
The string returned from this behavior is used in the Behavior Inspector.
on getBehaviorDescription me return "This is my behavior." end
See Also: getBehaviorToolTip
See Chapter/Appendix: 14
getBehaviorTooltip Behaviors Event Handler
Used to generate a ToolTip when the behavior is made part of a library.
on getBehaviorTooltip me return "My Behavior" end
See Also: getBehaviorDescription
See Chapter/Appendix: 14
getBoneID 3D, Bones Function
Returns the number of a named bone in a model resource.
myBoneNumber = sprite(1).member.modelResource("my model resource").getBoneID("my bone")
See Also: bone
getError Shockwave Audio, Flash Function
Returns an error code of a Shockwave audio member. 0 is okay, 1 is a memory error, 2 is a network error, 3 is a playback error, and 99 is another error. For Flash members, it returns symbols: #memory, #fileNotFound, #network, #fileFormat, and #other.
if getError(member("mySWA")) = 0 then...
See Also: getErrorString, clearError, state
See Chapter/Appendix: 17, 20
getErrorString Shockwave Audio Function
Takes a Shockwave audio error code from getError and returns a string that describes the error.
alert getErrorString(mySWAerror)
See Also: getError
See Chapter/Appendix: 17
getFlashProperty Flash Function
Acts like a "getProperty" action command in Flash and returns the property value from the Flash movie. Possible properties are #posX, #posY, #scaleX, #scaleY, #visible, #rotate, #alpha, #name, #width, #height, #target, #url, #dropTarget, #totalFrames, #currentFrame, and #lastframeLoaded. The first parameter is the target name, which you can leave as an empty string if you want to get a property at the global level. The second parameter is the property name.
ballX = sprite(7).getFlashProperty("bouncing ball",#posX)
See Also: setFlashProperty, getVariable
See Chapter/Appendix: 20
getFrameLabel Flash Function
Returns the name of a label in a Flash sprite, given the frame number.
if sprite(7).getFrameLabel(22) = "Section 2" then...
See Also: findLabel, frame
See Chapter/Appendix: 20
getHotSpotRect QTVR Function
Returns the rectangle of a QTVR hotspot on the Stage.
if the mouseLoc = getHotSpot(sprite(7),2) then...
getLast List Function
Returns the last value in a linear or property list.
list = [4,6,9] put getLast(list) 9 put list.getLast() 9
See Also: getAt, getOne, count
See Chapter/Appendix: 13
getLatestNetID Network Function
Returns the network ID number of the most recent network command. This can then be used in functions such as netDone. This is obsolete because network ID numbers are now returned by the functions themselves.
getNetText("http://clevermedia.com") gNetID = getLatestNetID()
See Also: getNetText, postNetText, netAbort, netDone, netError
See Chapter/Appendix: 22
getNetErrorString Network Function
Takes a network error code from netError and returns a short string description.
alert getNetErrorString(myNetError)
See Also: netError
See Chapter/Appendix: 22
getNetText Network Function
Starts retrieving a text file from the Internet. It returns a network ID for the operation.
gNetID = getNetText("http://clevermedia.com")
See Also: netTextResult, netDone
See Chapter/Appendix: 22
getNormalized 3D, Math Function
Takes a vector and returns a vector of length 1 that points in the same direction.
v = vector(5,5,0) put v.getNormalized() vector( 0.7071, 0.7071, 0.0000 )
See Also: normalize
getNthFileNameInFolder Misc Function
When given a valid file path and a number, it returns the filename. If the number is greater than the number of files in the folder, it returns an empty string.
on getAllFiles list = [] i = 1 repeat while TRUE filename = getNthFileNameInFolder(the pathname,i) if filename = "" then exit repeat add list, filename i = i + 1 end repeat return list end
See Also: @
See Chapter/Appendix: 29
getOne List Function
For a linear list, returns the position of the first item that is equal to the given value. For a property list, it returns the property. A 0 is returned if the value is not found.
list = [4,6,9] put getOne(list,6) 2 put list.getOne(6) 2 put list.getOne(8) 0
See Also: getAt, getProp, getPos
See Chapter/Appendix: 13
getPi XEl Image Function
Returns a color that corresponds to the color of the pi XEl at a coordinate in a bitmap image. The first parameter can be a point structure, or you can make the first parameter the horizontal location and the second parameter the vertical location. If a final parameter, #integer, is included, a number is returned instead of a color. This number contains both color and Alpha channel information and can be used in setPi XEl to set another pi XEl to the same color. A 0 is returned if the location is outside the image area.
myImage = member("picture").image myColor = myImage.getPi XEl(point(50,30))
See Also: setPi XEl
See Chapter/Appendix: 18
getPlaylist Sound Function
Returns the list of members queued to play in a sound channel, excluding any sound currently playing. The returned value is a list of property lists, each containing information about the sound member and how it is to be played.
myList = sound(1).getPlayList() if myList[1].member = member("mySound") then...
See Also: setPlayList, queue, play
See Chapter/Appendix: 17
getPos List Function
Like getOne, but returns a position for property lists, not a property.
list = [#a: 7, #b: 9, #c: 14] put getPos(list,9) 2 put list.getPos(9) 2
See Also: getOne, findPos, findPosNear
See Chapter/Appendix: 13
getPref Shockwave Function
Gets a preference file's contents. Preference files are used in Shockwave to store "cookies" of information without creating a security risk. Returns a VOID if that preference file does not exist.
myPref = getPref("clevermediaGame1")
See Also: setPref
See Chapter/Appendix: 22
getProp List Function
Returns the value of a property in a property list. If the property is not present, it generates an error message.
list = [#a: 4, #b: 6, #c: 9] put getProp(list,#b) 6 put list.getProp(#b) 6 put list.b 6 put list[#b] 6
See Also: getAt, getaProp
See Chapter/Appendix: 13
getPropAt List Function
Returns the property at a specific position in a property list.
list = [#a: 6, #b: 19, #c: 22] put getPropAt(list,2) #b put list.getPropAt(2) #b
See Also: getProp, getAProp, getAt
See Chapter/Appendix: 13
getPropertyDescriptionList Behaviors Event Handler
Called when the behavior is dropped on or added to a sprite. The list returned is used to generate the Parameters dialog box.
on getPropertyDescriptionList me list = [:] addProp list, #pMyProp, [#comment: "My Prop", #format: #integer, #default: 7] return list end
See Also: getBehaviorDescription
See Chapter/Appendix: 14
getRendererServices 3D, Misc Function
Returns an object that contains all sorts of information about the computer's video software and the capabilities of the Director 3D engine. See the sample below for a list of all properties in Director 8.5.
put getRendererServices().renderer #openGL put getRendererServices().rendererDeviceList [#openGL, #software] put getRendererServices().textureRenderFormat #rgba5551 put getRendererServices().depthBufferDepth 24 put getRendererServices().colorBufferDepth 32 put getRendererServices().modifiers [#collision, #bonesPlayer, #keyframePlayer, #toon, #lod, #meshDeform, #sds, #inker] put getRendererServices().primitives [#sphere, #box, #cylinder, #plane, #particle]
See Also: active3Drenderer, preferred3Drenderer
See Chapter/Appendix: 39
getStreamStatus Network Function
When given a network ID or URL, this function returns a list with information about the progress of streaming. The list includes #URL, #state, #bytesSoFar, #bytesTotal, and #error.
list = getStreamStatus(gNetID) if list.bytesSoFar > list.bytesTotal/2 then member("status").text = "Half done!" end if
See Also: tellStreamStatus
See Chapter/Appendix: 22
getVariable Flash Function
Returns the value of the variable from a Flash sprite.
myVar = sprite(7).getVariable("myVar")
See Also: getFlashProperty, setVariable
See Chapter/Appendix: 20
getWorldTransform 3D, Models Function
This returns the transform of a model or other object relative to the world center. It differs from just getting the transform because the transform is dependent on the parent if the model happens to be grouped as a child of another model. The getWorldTransform is always relative to the whole 3D scene.
go Navigation Command
Moves the playback head to a new frame or to a frame in another movie. You can use a frame number or label.
go to frame "newFrame" go toframe 7 go to frame "into" of movie "newmovie" go to movie "newMovie"
See Also: go loop, go next, go prev, play
See Chapter/Appendix: 13
go loop Navigation Command
Sends the playback head back to the most recent frame label.
on exitFrame go loop end
See Also: go, go next, go previous, marker
See Chapter/Appendix: 13
go next Navigation Command
Sends the playback head to the next frame with a frame label.
on mouseUp go next end
See Also: go, go loop, go previous, marker
See Chapter/Appendix: 13
go previous Navigation Command
Sends the playback head to the frame with a frame label that is before the current frame label. This usually means sending the playback head back two labels.
on mouseUp go previous end
See Also: go, go loop, go next, marker
See Chapter/Appendix: 13
goToFrame Flash Command
Starts playing a Flash sprite from the frame number or name.
goToFrame(sprite(7),"intro")
See Also: frame
See Chapter/Appendix: 20
gotoNetMovie Shockwave Command
Gets a new movie from the Internet and replaces the current one with it. The first movie continues playing until the second one loads.
gotoNetMovie("http://clevermedia.com/arcade/cleverdots.dcr")
See Also: gotoNetPage, netDone
See Chapter/Appendix: 22
gotoNetPage Shockwave, Network Command
In Shockwave, it loads a new URL in the current browser window or another window or frame. You can also use a second parameter as a browser target. In projectors, it launches the user's browser and loads the URL.
gotoNetPage("http://clevermedia.com") gotoNetPage("http://clevermedia.com","_top")
See Also: netDone, browserName, gotoNetMovie
See Chapter/Appendix: 22
gradientType Vector Property
Either #linear or #radial to specify the type of gradient to use. Vector shape member must be closed and have its fillType set to #gradient.
member("myVector").gradientType = #radial
See Also: endColor, fillColor, fillDirection, fillMode, fillCycles, fillOffset, fillScale, closed
See Chapter/Appendix: 20
gravity 3D, Particle System Property
The amount of gravity to apply to the particles. This is represented as a vector, so it also specifies which direction gravity pulls.
sprite(1).member.modelResource("my particle system").gravity = vector(0,2,0)
See Also: drag, wind
See Chapter/Appendix: 39
green Color Property
Extracts the green property from an rgb color object.
myColor = rgb("336699") put myColor rgb( 51, 102, 153 ) put myColor.green 102
See Also: green, red, color, rgb
See Chapter/Appendix: 18
group 3D, Grouping Object
A group is like a model, but it contains nothing but other models and objects. Once you define a group, you can add models and then move them all by referring to the group instead of the individual models.
sprite(1).member.newGroup("my group") sprite(1).member.group("my group").addChild(sprite(1).member.model("my model"))
See Also: addChild, child, parent, deleteGroup, newGroup
See Chapter/Appendix: 39
halt Navigation Command
In Director, the current handler, all other handlers, and the movie stops. Projectors quit.
on mouseUp halt end
See Also: abort, exit, quit
See Chapter/Appendix: 21
handler Programming Function
This function tells you whether a handler of a certain name exists in a script object.
if script("myScript").handler("test") then...
See Also: handlers, script, new
handlers Programming Function
Returns a list of all the handler names in a script.
put script(1).handlers() [#transfer, #makenames, #myhandler]
See Also:handler, script
height Sprite, Member Property
Returns the height of most members and sprites. Can also be used as a property of rect objects.
if sprite(7).height > 200 then... if myRect.height > 100 then...
See Also: width, rect
See Chapter/Appendix: 18
height 3D, Primitives Property
The height of a box or cylinder primitive. This is also the property of a texture.
sprite(1).member.modelResource("my box").height = 15
See Also: newModelResource, width, length, radius
See Chapter/Appendix: 39
heightVertices 3D, Primitives Property
The number of vertices used to create the side of a box primitive. The more vertices, the more polygons. The more polygons, the better the light detail.
sprite(1).member.modelResource("my box").heightVertices = 8
See Also: widthVertices, lengthVertices
See Chapter/Appendix: 39
highlightPercentage 3D, Shader Property
Used with the toon modifier and the painter shader. This is the percent of available colors used for highlights.
sprite(1).member.shader("my shader").highlightPercentage = 25
See Also: highlightStrength
highlightStrength 3D, Shader Property
How bright to make highlights in the toon modifier or painter shader.
sprite(1).member.shader("my shader").highlightStrength = .5
See Also: highlightStrength
See Chapter/Appendix: 39
hilite Field Command
Enables you to select a chunk portion of a field member.
hilite member("myField").word[5]
See Also: selStart, selEnd
See Chapter/Appendix: 16
hilite Button Property
A radio button or check box property that determines whether the button is checked.
if member("myButton").hilite then...
See Also: checkBoxAccess, checkBoxType
See Chapter/Appendix: 15
hither 3D, Camera Property
The distance from the camera where objects begin to be drawn. Setting this further away makes objects near the camera invisible.
sprite(1).camera.hither = 3
See Also: yon
See Chapter/Appendix: 39
hitTest Vector, Flash Function
Returns either #background, #normal, or #button depending on what the point specified is positioned over.
if hitTest(sprite(7),point(50,25)) then...
See Chapter/Appendix: 20
HMStoFrames Misc Function
Opposite of framesToHMS; takes a string rather than a number and converts it to a number of frames.
put HMStoFrames("00:05:20.05", 15, FALSE, FALSE) 4805
See Also:framesToHMS
hold Flash Command
Stops a Flash sprite.
hold sprite(7)
See Chapter/Appendix: 20
hotSpot Cursor Property
A point that represents the hotspot within an animated cursor.
member("myCursor").hotSpot = point(7,13)
See Also: cursor
See Chapter/Appendix: 21
hotSpotEnterCallback QTVR Property
Set this to the name of the handler to be called when the cursor enters the hotspot of a QTVR movie. The first parameter is me, and the second is the ID of the hotspot.
sprite(7).hotSpotEnterCallBack = "myHotSpotHandler"
See Also: hotSpot ExitCallback, nodeEnterCallback, triggerCallback
hotSpotExitCallback QTVR Property
Set this to the name of the handler to be called when the cursor exits the hotspot of a QTVR movie. The first parameter is me, and the second is the ID of the hotspot.
sprite(7).hotSpotExitCallBack = "myHotSpotHandler"
See Also: hotSpot EnterCallback, nodeExitCallback, triggerCallback
HTML Text Property
The HTML code that corresponds to the text in a text member.
member("myText").html = "<HTML><BODY><P>Hello</P></BODY></HTML>"
See Also: text, rtf
See Chapter/Appendix: 16
hyperlink Text Property
The hyperlink string for a specific chunk in a text member.
member("myText").word[6..7].hyperlink = "myLink"
See Also: hyperlinkClicked, hyperlinkRange, hyperlinkState
See Chapter/Appendix: 16
hyperlinkClicked Text Event Handler
Called when a hyperlink is clicked in the text member.
on hyperlinkClicked me, data, range if data = "link1" then... end
See Also: hyperlink, hyperlinkRange, hyperlinkState
See Chapter/Appendix: 16
hyperlinkRange Text Property
Takes the first character of the chunk and returns the full range of any hyperlink that contains it. Returns a pair of 0s if no hyperlink is there.
put member("myText").char[6].hyperlinkRange [5, 8] put member("myText").char[10].hyperlinkRange [0, 0]
See Also: hyperlinkClicked, hyperlink, hyperlinkState
See Chapter/Appendix: 16
hyperlinks Text Property
Returns a list with all the character ranges for hyperlinks in a text member.
put member("myText").hyperlinks [[5, 8]]
See Also: hyperlinkClicked, hyperlinkRange, hyperlink
See Chapter/Appendix: 16
hyperlinkState Text Property
Given a chunk, it returns #normal, #active, or #visited for the hyperlink that contains it.
if member("myText").char[5].hyperlinkState = #visited then...
See Also: hyperlinkClicked, hyperlink, hyperlinkRange
See Chapter/Appendix: 16
identity 3D, Models Command
Resets a tranform, such as the transform of a model. The position and rotation vectores are set to 0,0,0 and the scale vector is set to 1,1,1.
sprite(1).member.model("my model").transform.identity()
See Also: transform
See Chapter/Appendix: 39
idle Behaviors, System Event Handler
The on idle event handler is called one or more times between the enterFrame and the exitFrame messages.
on idle me if the shiftDown then... end
See Also: idleHandlerPeriod
See Chapter/Appendix: 14
idleHandlerPeriod System Property
The number of ticks between calls to the on idle handler. Default is 1.
the idleHandlerPeriod = 2
See Also: idle
idleLoadDone Memory Function
Given an idle load tag, it returns TRUE if the loading has been completed.
if idleLoadDone(7) then...
See Also: idleLoadTag
See Chapter/Appendix: 21
idleLoadMode Memory Property
Determines how preload commands use idle time to load members. 0 = no idle loading, 1 = only in free time between frames, 2 = during idle events, 3 = as frequently as possible.
the idleLoadMode = 1
See Also: idleHandlerPeriod, idleLoadTag
See Chapter/Appendix: 21
idleLoadPeriod Memory Property
The number of ticks the movie should wait before doing idle loading. Default is 0.
the idleLoadPeriod = 1
See Also: idle idleLoadTag
See Chapter/Appendix: 21
idleLoadTag Memory Property
A system property that gives the members cued for loading an ID number that can be used in functions such as idleLoadDone.
the idleLoadTag = 7
See Also: idleLoadDone
See Chapter/Appendix: 21
idleReadChunkSize Memory Property
The maximum size, in bytes, of data that can be read during an idle period. Default is 32,768.
the idleReadChunkSize = 60000
See Also: idleLoadTag
See Chapter/Appendix: 21
if Programming Structure
Checks a statement to see whether it is TRUE. It e XEcutes line(s) of code if so. The else if and else statements can be used to further modify the statement.
if (a = b) then run these lines else if (c = d) then run these lines else run these lines end if
See Also: case
See Chapter/Appendix: 13
ilk Programming Function
Takes any variable and returns a symbol to describe its type. Possible values include #integer, #float, #list, #proplist, #color, #date, and so on. Can also be used with two parameters as a test.
if ilk(myVariable) = #list then... if ilk(myVariable, #list) then...
See Also: integerP, floatP, stringP, objectP
image Image Property, Function
Refers to the image object inside a bitmap member. It is on this object that you can use image Lingo to alter the member. You can also use it to create a new image with width, height, bit depth, and optional "alphaDepth" and "palette" parameters.
myImage = member("picture").image myImage.setPi XEl(50,50,rgb("FF0000")) myNewImage = image(200,200,32)
See Also: setPi XEl, getPi XEl, draw, fill, copyPi XEls, duplicate
See Chapter/Appendix: 18
imageCompression Bitmap Property
The value of this property describes how it will be compressed when saved in a Shockwave movie. Possible values are #moveSetting, #standard, and #jpeg.
member("picture").imageCompression = #jpeg
See Also: imageQuality, movieImageCompression, movieImageQuality
See Chapter/Appendix: 18
imageEnabled Flash, Vector Property
If set to FALSE, the member or sprite is invisible.
sprite(7).imageEnabled = FALSE
See Chapter/Appendix: 20
imageQuality Bitmap Property
The amount of JPEG compression to be used on the bitmap when it is saved inside a Shockwave movie. This property is used only when imageCompression is set to #jpeg for the member. Valid values are 0 to 100.
member("picture").imageQuality = 80
See Also: imageCompression, movieImageCompression, movieImageQuality
See Chapter/Appendix: 18
immovable 3D, Collision Detection Property
If a model's collision modifier is set to be immovable, then collision detection is faster. However, you should not move the object in the world anymore or collision detection will not work properly.
sprite(1).member.model("my model").collision.immovable = TRUE
See Also: collision
See Chapter/Appendix: 39
importFileInto Member Command
Imports new media from an external file or Internet location into a member.
importFileInto member("myMember"), "newimage.pct"
See Also: downloadNetThing, fileName, preLoadNetThing
in Programming Structure
Refers to an element in a chunk expression. Used with other Lingo. Obsolete now that the count function can be used in dot syntax.
t = "abcdef" put the number of chars in t 6 put t.char.count 6
See Also: number, count
inflate Math Function
Takes a rectangle and a width and height change and returns a new rectangle inflated from the center.
put inflate(rect(10,10,20,20),2,5) rect(8, 5, 22, 25)
See Also: map, offset, union
ink Sprite Property
The ink that is used by the sprite.
sprite(7).ink = 8
See Also: blend, color, bgColor
See Chapter/Appendix: 18, D
inker 3D, Inker Object
By adding the inker modifier to a model, you can set inker properties like silhouettes and creases.
sprite(1).member.model("my model").addModifier(#inker) sprite(1).member.model("my model").inker.creases = TRUE
See Also: addModifier, lineColor, silhouettes, creases, creaseAngle, boundary, lineOffset, useLineOffset
See Chapter/Appendix: 39
inlineImeEnabled Text Property
If TRUE, users can enter multibyte characters, such as those used in non-English language fonts, into text and field members.
the inlineImeEnabled = TRUE
See Also: romanLingo
insertBackdrop 3D, Camera Command
Like addBackdrop, but inserts the backdrop in the list at a specific position.
insertOverlay 3D, Camera Command
Like addOverlay, but the overlay is inserted in the list at a specific position.
insertFrame Score Recording Command
During Score recording, this command duplicates the current frame.
on beginRecording insertFrame endRecording
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
inside Math Function
Returns TRUE if the point is inside the rectangle.
if inside(myPoint,myRect) then...
See Also: intersects
installMenu Menu Command
Takes a field member and uses it to create a system menu bar.
installMenu member("myMenu")
See Also: menuItem
See Chapter/Appendix: 21
integer Math Function
Converts a floating point number or a string to an integer.
put integer(5.3) 5 put integer("5") 5
See Also: float, integerP
See Chapter/Appendix: 13
integerP Math Function
Returns TRUE if the number given is an integer.
myNumber = 5.3 put integerP(myNumber) 0 myNumber = 5 put integerP(myNumber) 1
See Also: floatP, integer
interface Xtras Function
Returns a string describing the Xtra and its use.
put interface(xtra "FileIO")
See Also: showXlib
See Chapter/Appendix: 25
interpolate interpolateTo 3D, Math Function
Takes two transforms and finds a transform in between them according to a percentage provided. For instance, 50 percent would return a transform halfway in between. The interpolate to function will actually change the first transform to the desired result.
transform1.interpolateTo(transform2,50)
intersect Math Function
Takes two rectangles and returns the rectangle intersection. If there is no intersection, a value of rect(0,0,0,0) is returned.
if intersect(myRect1,myRect2) <> rect(0,0,0,0) then...
See Also: inside, intersects
intersects Sprite Function
Determines whether two sprite rectangles overlap. Note the odd syntax.
if sprite 1 intersects 2 then...
See Also: intersect, inside
interval Cursor Property
Specifies the delay in milliseconds between frames of an animated cursor member.
member("myCursor").interval = 1000
See Also: cursor
See Chapter/Appendix: 21
into Programming Structure
Used with a put command to specify the destination of a text chunk.
myText = "Hello World." put "!" into char 12 of myText put myText "Hello World!"
See Also: put, before, after
See Chapter/Appendix: 16
inverse, invert 3D, Math Function
Takes a transform and returns a new transform with both the position and the rotation reversed. The invert function will change the transform to the desired result rather than just return the value.
t1 = transform() t1.position = vector(5,0,0) t2 = t1.inverse() put t2.position vector( -5.0000, 0.0000, 0.0000 )
invertMask Digital Video Property
If a QuickTime movie is using a mask, setting this to TRUE reverses the mask.
member("myQuickTime").invertMask = TRUE
See Also: mask
See Chapter/Appendix: 19
isBusy Sound Function
Returns a TRUE if a sound is playing in the sound channel.
on exitFrame if sound(1).isBusy() then go to the frame end if end
See Also: status
See Chapter/Appendix: 17
isInWorld 3D, Models Function
Will return TRUE if the model or other object is in the world. The object could be present in the member, but not present in the world if it has been removed from the world.
if sprite(1).member.model("my model").isInWorld() then...
See Also: addToWorld, removeFromWorld
isOKToAttach Behaviors Event Handler
When used in a behavior, this handler determines whether the behavior can be attached to sprites in certain situations. After the me parameter, the sprite type and sprite number are passed in as parameters. The handler is called when the behavior is dropped onto the Score. If a FALSE is returned, the sprite is not attached.
on isOKToAttach me, spriteType, spriteNum if spriteType = #bitmap then return TRUE else return FALSE end if end
See Chapter/Appendix: 14
isPastCuePoint Sound Function
Returns TRUE if the cue point (number or name) has been passed. Can use a sprite or sound object. If a cue point name is used, the returned value is the number of cue points that have been passed with that name.
if sound(1).isPastCuePoint("blip") then...
See Chapter/Appendix: 17
isVRMovie Digital Video Property
TRUE if the QuickTime movie is a QTVR movie.
if member("myQuickTime").isVRMovie then...
See Chapter/Appendix: 19
item Strings Expression
Identifies a chunk in a string, as broken up by the itemDelimiter character.
myString = "one, two, three" put myString.item[2] " two"
See Also: itemDelimiter
See Chapter/Appendix: 16
itemDelimiter Strings Property
This system property determines which character is used by the item chunk expression to break up strings. Default is a comma.
the itemDelimiter = ";"
See Also: itemDelimiter
See Chapter/Appendix: 16
kerning Text Property
If TRUE, the text in a text member is automatically spaced when text is changed.
member("myText").kerning = FALSE
See Also: kerningThreshold
See Chapter/Appendix: 16
kerningThreshold Text Property
If kerning is TRUE, this property represents the font size where kerning is to begin. Smaller characters are not adjusted.
member("myText").kerningThreshold = 14
See Also: kerning
See Chapter/Appendix: 16
key Keyboard Property
This system property can be accessed in on keyUp and on keyDown handlers to determine which key has been pressed.
on keyUp if the key = "a" then... end
See Also: keyCode, keyDown, keyUp, keyPressed
See Chapter/Appendix: 16
keyboardFocusSprite Keyboard Property
Used to set focus for keyboard input on a given text sprite.
the keyboardFocusSprite = 3
See Chapter/Appendix: 16
keyCode Keyboard Property
This system property can be accessed in on keyUp and on keyDown handlers and returns a keyboard code that can be used to detect arrow keys and function keys (123 = left, 124 = right, 125 = down, 126 = up).
on keyUp if the keyCode = 123 then... end
See Also: key, keyDown, keyUp, keyPressed
See Chapter/Appendix: 16
keyDown Keyboard Event Handler
This handler is called when the user presses a key on the keyboard. The properties the key and the keyCode can be used inside this handler to determine the key pressed.
on keyDown if the key = "A" then... end
See Also: keyDown, keyUpScript, keyPressed, key, keyCode
See Chapter/Appendix: 16
keyDownScript Keyboard Property
Can be set to the name of a handler or a simple Lingo statement. It is e XEcuted first when the user presses down on a key, before any on keyDown handlers. Set it to an empty string to turn it off.
the keyDownScript = "myKeyHandler"
See Also: keyDown
See Chapter/Appendix: 16
keyframePlayer 3D, Animation Object
This object refers to any motions built into the model by the 3D graphics program that created it.
sprite(1).member.model("my model").keyframePlayer.playing = TRUE
See Also: playing, playlist, currentTime, playRate, rootLock, currentLoopState, blendTime, blendFactor, autoBlend, lockTranslation, positionReset, rotationReset, pause, play, playNext, queue
See Chapter/Appendix: 39
keyPressed Keyboard Function
This function tests a character or keyboard code to determine whether it is currently being pressed. (123 = left, 124 = right, 125 = down, 126 = up)
on exitFrame me if keyPressed("a") then... end
See Also: keyDown, keyUp
See Chapter/Appendix: 16
keyPressed Keyboard Property
Returns the character or key code of the last key pressed.
if the keyPressed = 123 then...
See Also: keyDown, keyUp
See Chapter/Appendix: 16
keyUp Keyboard Event Handler
This handler is called when a user lifts a finger off a key on the keyboard. The properties the key and the keyCode can be used inside it to determine the key pressed.
on keyUp if the key = "A" then... end
See Also: keyDown, keyUpScript, keyPressed, key, keyCode
See Chapter/Appendix: 16
keyUpScript Keyboard Event Handler
Can be set to the name of a handler or to a simple Lingo statement. This handler is e XEcuted when the user lifts up a key, before any on keyUp handlers. Set it to an empty string to turn it off.
the keyUpScript = "myKeyHandler"
See Also: keyUp
See Chapter/Appendix: 16
label Movie Function
Given a frame label, it returns the frame number. If the label does not exist, 0 is returned.
go to frame label("intro")+1
See Also: frameLabel, labelList, marker
labelList Movie Property
Returns a string with each frame label in the Score on a line. Made somewhat obsolete by the markerList property.
put the labelList "one two three "
See Also: markerList, frameLabel, label, marker
last Strings Expression
Modifies a chunk expression. Can be used only with old (not dot) syntax.
myString = "one two three" put the last word of myString "three"
See Also: char, word, item, line
lastChannel Movie Property
The number of channels in the Score, as set in the Movie Properties dialog box.
put the lastChannel 150
See Also: lastFrame
lastClick Timeout, Mouse Property
Returns the number of ticks since the last mouse click.
if the lastClick > 600 then go next end if
See Also: lastEvent, lastKey, lastRoll
See Chapter/Appendix: 21
lastEvent Timeout, Mouse Property
Returns the number of ticks since the last mouse click, rollover, or key press.
if the lastEvent > 600 then go next end if
See Also: lastClick, lastKey, lastRoll
See Chapter/Appendix: 21
lastFrame Movie Property
Returns the number of the last frame in the movie.
put the lastFrame 72
See Also: lastChannel
lastKey Timeout Property
Returns the number of ticks since the last key was pressed.
if the lastKey > 600 then go next end if
See Also: lastEvent, lastClick, lastRoll
See Chapter/Appendix: 21
lastRoll Timeout, Mouse Property
Returns the number of ticks since the mouse was last moved.
if the lastRoll > 600 then go next end if
See Also: lastEvent, lastClick, lastKey
See Chapter/Appendix: 21
left Sprite, Misc Property
Returns the left side location of a sprite. Can also be used as a property of rect objects.
put sprite(1).rect rect(102, 143, 277, 233) put sprite(1).left 102 put sprite(1).rect.left 102
See Also: width, right, top, left, rect
See Chapter/Appendix: 18
left 3D, Primitives Property
Whether the left side of a 3D box primitive is present or not.
sprite(1).member.modelResource("my box resource").left = FALSE
See Also: back, front, right, top, bottom, topCap, bottomCap, newModelResource
leftIndent Text Property
Sets the number of pi XEls for a left indent of a whole text member, or a chunk inside a text member.
member("myText").line[5..6].leftIndent = 18
See Also: rightIndent, firstIndent
See Chapter/Appendix: 16
length Strings Property
Returns the number of characters in a string.
myString = "abcdefgh" put length(myString) 8 put myString.length 8
See Also: count
See Chapter/Appendix: 16
length 3D, Primitives Property
The length of a box or plane primitive.
sprite(1).member.modelResource("my box").length = 7
See Also: height, width
See Chapter/Appendix: 39
lengthVertices 3D, Primitives Property
The number of vertices used to create the side of a box primitive. The more vertices, the more polygons. The more polygons, the better the light detail.
sprite(1).member.modelResource("my box").heightVertices = 8
See Also: widthVertices, heightVertices
See Chapter/Appendix: 39
level 3D, Level of Detail Property
The exact level of detail when the auto property is set to FALSE.
sprite(1).member.model("my model").lod.auto = FALSE sprite(1).member.model("my model").lod.level = 50
See Also: lod, auto
See Chapter/Appendix: 39
lifetime 3D, Particle System Property
The number of milliseconds that a particle exists after it has been emitted.
sprite(1).member.modelResource("my particle system").lifetime = 5000
See Also: emitter, numParticles
See Chapter/Appendix: 39
light 3D, Lights Object
This keyword is used to refer to one of lights used in a 3D world.
sprite(1).member.light("my light").color = rgb("FF0000")
See Also: newLight, deleteLight, color, spotAngle, attenuation, specular, spotDecay, pointAtOrientation, type
See Chapter/Appendix: 39
line Strings Expression
Identifies a chunk in a string, as broken up by the RETURN character.
myString = "abc"&RETURN&"def"&RETURN&"ghi" put myString.line[2] "def"
See Also: paragraph
See Chapter/Appendix: 16
lineColor 3D, Inker Property
The color of the lines when using the inker or toon modifiers.
sprite(1).member.model("my model").inker.lineColor = rgb("FF0000")
See Also: creases, creaseAngle, silhouettes, boundary, lineOffset
See Chapter/Appendix: 39
lineCount Field Property
Gives you the number of visible lines, taking into account word wrapping, of a field.
if member("myField").lineCount
See Also: wordWrap
See Chapter/Appendix: 16
lineDirection Shape Property
Is a 0 if the line shape goes from upper left to lower right, and a 1 if the line shape goes from upper right to lower left.
member("myLine").lineDirection = 1
See Also: lineSize
See Chapter/Appendix: 20
lineHeight Field Function
When given a field member and a line number, returns the line height of that line.
put lineHeight(member("myField"),4)
See Also: fi XEdLineSpace
See Chapter/Appendix: 16
lineHeight Field Property
Enables you to set the line height of an entire text field.
member("myField").lineHeight = 16
See Also: fi XEdLineSpace
See Chapter/Appendix: 16
lineOffset 3D, Inker Property
The distance from the surface where the lines will be drawn when using the inker or toon modifier. The range is from -100 to 100.
sprite(1).member.model("my model").inker.lineOffset = 5
See Also: lineColor, creases, creaseAngle, silhouettes, boundary
See Chapter/Appendix: 39
linePosToLocV Text, Field Function
Determines the vertical location of a line in a text or field member. The location is relative to the top of the member.
put linePosToLocV(member("myText"),7)
See Also: locVtoLinePos, charPosToLoc
See Chapter/Appendix: 16
lineSize Shape Property
Determines the thickness of the border in a shape member.
member("myShape").lineSize = 2 sprite(7).lineSize = 2
See Chapter/Appendix: 16
linkAs Script Command
Enables you to save a script member as a text file. The file is then linked to the member as a linked script.
member("myScript").linkAs()
See Also: linked
linked Flash, Animated GIF, Script Property
Determines whether the member is internal or linked to an external file.
if member("myFlash").linked = TRUE then...
See Also: fileName
See Chapter/Appendix: 20
list List Function
Takes any number of parameters and returns a linear list containing them all.
put list(1,2,3,4,5) [1, 2, 3, 4, 5]
See Also: []
listP List Function
Returns TRUE if the value given is a valid list.
if listP(myVariable) then...
See Also: ilk
loaded Memory Property
Returns TRUE if the member has been loaded into memory.
if member("myMember").loaded then...
See Also: preLoad
See Chapter/Appendix: 21
loadFile 3D, Misc Command
This command will load a Shockwave 3D file (.w3d) into a cast member. The second parameter, with a default of TRUE, determines whether the entire member is overwritten by the contents of the file. If set to FALSE, then the models in the file are added to the member instead. If a third parameter is set to TRUE, then if two models have the same name, the model to be loaded is given a new name so that both models can exist in the member. If this third parameter is FALSE, then models with the same name are overwritten.
sprite(1).member.loadFile("mymodels.w3d",FALSE,FALSE)
See Also: state
See Chapter/Appendix: 39
loc Sprite Property
The location of the sprite on the Stage, as a point.
sprite(1).loc = point(50,20)
See Also: rect, locH, locV
See Chapter/Appendix: 18
loc 3D, Camera Property
The loc property of an overlay or a backdrop indicates where the bitmap is positioned from the upper left corner of the 3D member sprite.
sprite(1).camera.backdrop[1].loc = point(10,10)
See Also: overlay, backdrop, regPoint
See Chapter/Appendix: 39
locH Sprite Property
The horizontal location of the sprite on the Stage.
sprite(1).locH = 50
See Also: rect, loc, locV
See Chapter/Appendix: 18
lockTransition 3D, Bones Property
This property allows you to lock bones movement in one or more directions. Possible values are #x, #y, #z, #xy, #xz, #yz, #all and #none.
sprite(1).member.model("my model").bonesPlayer.lockTranslation = #x
locToCharPos Text, Field Function
Takes a member and a location and returns the character number at that location. It is relative to the upper-left corner of the member.
p = locToCharPos(member("myText"),point(50,0))
See Also: charPosToLoc, locVtoLinePos
See Chapter/Appendix: 16
locV Sprite Property
The vertical location of the sprite on the Stage.
sprite(1).locV = 50
See Also: rect, loc, locH
See Chapter/Appendix: 18
locVToLinePos Text, Field Function
Takes a member and a vertical location and returns the line number at that location. It is relative to the top of the member.
n = locVToLinePos(member("myText"),24)
See Also: linePosToLocV, locToCharPos
See Chapter/Appendix: 16
locZ Sprite Property
Determines the draw order of a sprite. Each sprite starts with a locZ of its own channel number. You can set it to values from about -2 billion to 2 billion. Lower-numbered sprites appear under higher ones. If a tie results, the sprite number determines the draw position.
sprite(7).locZ = 1001
See Chapter/Appendix: 16
lod 3D, Level of Detail Modifier
The lod, or level of detail, modifier allows you to subtract polygons from a model as it is rendered. This will improve performance, but degrade quality. Normally, Director will handle this for you, but if you set the lod.auto to FALSE, you can control the lod.level directly. Alternatively, you can leave the lod.auto at TRUE, but adjust the lod.bias to make Director more aggressive about removing polygons.
sprite(1).member.model("my model").addModifier(#lod) sprite(1).member.mode("my model").lod.auto = FALSE sprite(1).member.mode("my model").lod.level = 20
See Also: auto, bias, level, sds
See Chapter/Appendix: 39
log Math Function
Returns the natural logarithm of a number.
put log(5) 1.6094
See Also: exp, log
See Chapter/Appendix: 13
long Date & Time Modifier
Modifies date or time to return a string in long format.
put the long date "Sunday, March 19, 2000" put the long time "8:34:20 PM"
See Also: date, time
See Chapter/Appendix: 21
loop Navigation Modifier
Refers to the marker on the current frame or the most recent marker.
go loop
See Also: go, next, previous
See Chapter/Appendix: 13
loop Flash, Digital Video, Sound, 3D Property
Determines whether a Flash movie, video, sound, or 3D animation loops back to the beginning when it reaches the end. This property can also be used with 3D particle system emitters to determine whether they loop.
member("mySound").loop = TRUE
See Also: loopBounds
See Chapter/Appendix: 17, 19, 20
loopBounds Digital Video Property
The start time and end time for a loop in a QuickTime video. It is a list of two integers that correspond to time in ticks.
sprite(7).loopBounds = [60,240]
See Also: loop
See Chapter/Appendix: 19
loopCount Sound Property
Enables you to specify the number of times that a queued sound will loop.
sound(1).queue([#member: member("mySound"), #loopCount: 3]) sound(1).play()
See Also: loopStartTime, loopEndTime, breakLoop, loopsRemaining
See Chapter/Appendix: 17
loopEndTime Sound Property
Loops in sounds can be defined by stating the loopStartTime, loopEndTime, and loopCount.
sound(1).play([#member: member("mySound"), #loopStartTime: 1000, #loopEndTime: 4000, #loopCount: 3]) put sound(1).loopEndTime 4000
See Also: loopStartTime, loopCount, breakLoop, loopsRemaining
See Chapter/Appendix: 17
loopsRemaining Sound Property
Loops in sounds can be defined by stating the loopStartTime, loopEndTime, and loopCount. This function returns the number of loops remaining to be heard if the sound is currently looping.
sound(1).play([#member: member("mySound"), #loopStartTime: 1000, #loopEndTime: 4000, #loopCount: 3]) put sound(1).loopsRemaining() 2
See Also: loopEndTime, loopStartTime, loopCount, breakLoop, loopsRemaining
See Chapter/Appendix: 17
loopStartTime Sound Property
Loops in sounds can be defined by stating the loopStartTime, loopEndTime, and loopCount.
sound(1).play([#member: member("mySound"), #loopStartTime: 1000, #loopEndTime: 4000, #loopCount: 3]) put sound(1).loopStartTime 1000
See Also: loopStartTime, loopCount, breakLoop, loopsRemaining
See Chapter/Appendix: 17
machineType System Property
This obsolete system property returns the Macintosh system ID number. For instance, 69 is a PowerMac 8500. For all Windows machines, it returns 256. In almost all cases, it is better to use the platform.
put the machineType 406
See Also: platform
See Chapter/Appendix: 21
magnitude 3D, Math Function
Returns the length of a vector.
v = vector(5,5,0) put v.magnitude 7.0711
See Also: identity, distanceTo
map Math Function
Takes a target rectangle, a source rectangle, and a destination rectangle or point. It returns a new destination rectangle or point that corresponds to the source rectangle mapped to the target rectangle. Used for advanced Lingo positioning.
newRect = map(myTargetRect,mySourceRect,myDestPoint)
See Also: inflate, offset, union
map 3D, Animation Command
Maps one 3D motion onto another.
mapMemberToStage Sprite, Math Function
Takes a sprite and a point in the member and returns the location on the Stage that corresponds to the point in the member. Works even with flipH, flipV, rotation, and skew.
loc = mapMemberToStage(sprite(7),point(50,50))
See Also: mapStageToMember
mapStageToMember Sprite, Math Function
Takes a sprite and a point on the Stage and returns the location in the member that corresponds to the point on the Stage. Works even with flipH, flipV, rotation, and skew.
loc = mapStageToMember(sprite(7),the mouseLoc)
See Also: mapMemberToStage
margin Field Property
The size of the space between the edge of a field and the text in the field.
member("myField").margin = 1
See Also: border, boxType, boxDropShadow, dropShadow
See Chapter/Appendix: 16
marker Movie Function
Returns the frame number of the frame with the current label (0), the preceding label (-1), the next label (1), or any other labeled frame relative to the current frame.
go to frame marker(-2)
See Also: label, labelList, frame
See Chapter/Appendix: 13
markerList Movie Property
Returns a property list with the frame numbers as properties and the frame labels as values.
put the markerList [1: "one", 2: "two", 3: "three"]
mask Digital Video Property
Set this to a 1-bit member to be used as a mask for a QuickTime video. Set to 0 to have no mask.
member("myQuickTime").mask = member("Video Mask")
See Also: invertMask
See Chapter/Appendix: 19
max Math Function
Compares two or more numbers and returns the highest.
put max(4,5) 5 put max(5,3,8,23,3,5,12) 23
See Also: min
maxInteger Math Property
This system property returns the largest integer supported by the computer. Usually a number just over 2 billion.
put the maxInteger 2147483647
maxSpeed 3D, Particle System Property
The maximum speed of a particle emitted from a particle system. The actual speed is a random amount between minSpeed and maxSpeed.
sprite(1).member.modelResource("my particle system").emitter.maxSpeed = 100
See Also: minSpeed, emitter
See Chapter/Appendix: 39
mci Misc Command
Sends a command string to the Windows Media Control Interface. This enables you to send commands to PC cards and hardware. This is obsolete, but still works in some cases. Using Xtras is the recommended option.
mci "play midi1"
me OOP, Behaviors Misc
Special variable name used in parent scripts and behaviors. Enables handlers to be associated with the object to which they belong.
on beginSprite me...
See Also: new, ancestor
See Chapter/Appendix: 14
media Member Property
Represents the contents of a member. For instance, in a bitmap, it represents the image. You can use this property to copy member contents between members.
member("myMember").media = member("other").media
See Also: image, picture, type
See Chapter/Appendix: 18
mediaReady Network, Memory Property
For a linked member, Cast library, or sprite. Returns TRUE if the member has been loaded from the Internet.
if sprite(7).mediaReady then...
See Also: frameReady
See Chapter/Appendix: 22
member Member Object
Defines a member object. The first parameter is the name or number of the member. The optional second parameter is the name or number of a Cast library.
myMember = member("this") myMember = member("thisMember","thatCastLib")
See Also: castLib
See Chapter/Appendix: 13
member Sprite, Sound Property
The member associated with the sprite or sound.
sprite(7).member = member("myMember") if sound(1).member = "mySound" then...
See Also: memberNum,castLibNum
See Chapter/Appendix: 13
member 3D, Texture Property
The bitmap member used for a texture. You can get and set this property. You can even set it to different textures quickly, allowing for animated textures.
myMember = sprite(1).member.texture("my texture").member
See Also: shader, texture, newTexture
See Chapter/Appendix: 39
memberNum Sprite Property
The number of the member associated with the sprite.
sprite(7).memberNum = 12
See Also: memberNum, castLibNum
See Chapter/Appendix: 13
Member members Expression
This plural expression can be used only with number to get the number of members in a cast library.
put the number of members of castLib "mylib" 832
See Also: number
memorySize System Property
The total number of bytes available to the movie.
put the memorySize 201326592
See Also: freeBytes, freeBlock
See Chapter/Appendix: 21
menuItem Menu Property
Enables you to refer to a menu item in a menu that was installed with installMenu. Requires old (not dot) syntax.
set menuItem 4 of menu 1 = "Test"
See Also: installMenu
mesh 3D, Mesh Deform Object
Refers to the mesh of a model that has been given the mesh deform modifier.
n = sprite(1).member.model("my model").meshdeform.mesh.face.count
See Also: colorList, vertexList, normalList, textureCoordinateList, textureLayer, face
See Chapter/Appendix: 39
meshDeform 3D, Mesh Deform Modifier
When you add this modifier to a model, you can then control the invidual vertices and faces of the model.
sprite(1).member.model("my model").addModifier(#meshDeform)
See Also: addModifier, face, mesh
See Chapter/Appendix: 39
milliSeconds Date & Time Property
Returns the time since the computer was started in milliseconds.
put the milliseconds 27910847
See Also: ticks
See Chapter/Appendix: 21
min Math Function
Compares two or more numbers and returns the lowest one.
put main(4,5) 4 put min(5,3,8,32,5,12) 3
See Also: max
minSpeed 3D, Particle System Property
The minumum speed of a particle emitted from a particle system. The actual speed is a random amount between minSpeed and maxSpeed.
sprite(1).member.modelResource("my particle system").emitter.minSpeed = 100
See Also: maxSpeed, emitter
See Chapter/Appendix: 39
missingFonts Text Property
Returns a list of fonts used by a text member that are not available.
if member("myText").missingFonts.count > 0 then...
See Also: substituteFont
mod Math Operator
Takes a number and performs a modulus operation with a second number.
put 6 mod 4 2 put 4 mod 4 0
modal MIAW Property
This window property, when set to TRUE, prevents users from interacting with any other window, including the Stage, until the current window is gone.
window("myDialog").modal = TRUE
See Also: window
See Chapter/Appendix: 24
mode 3D, Particle Property
Particle systems can have a mode of #stream or #burst. The first will create a constant flow of particles while the second will emit all the particles at once.
sprite(1).member.modelResource("my particle system").emitter.mode = #burst
See Also: emitter, numParticles, lifetime
See Chapter/Appendix: 39
mode 3D, Collision Detection Property
When you attach the collision modifier, the default mode is #sphere, which looks for collisions against the bounding sphere of the model. You can also set this to #box to use the bounding box instead. Setting this to #mesh will mean more accurate collision detection, but slower performance.
sprite(1).member.model("my model").collision.mode = #mesh
See Also: collision
See Chapter/Appendix: 39
model 3D, Models Object
The model syntax is used to refer to a model in a 3D member. You can refer to it as a list or as a named object.
sprite(1).member.model[1].transform.position = vector(0,0,0) sprite(1).member.model("my model").transform.position = vector(0,0,0)
See Also: modelResource
See Chapter/Appendix: 39
modelA, modelB See collisionData modelResource 3D, Model
Object
Before creating a model in Lingo from scratch, you must first create a model resource. This defines the geometry of the model. You can create bo XEs, spheres, cylinders and planes. You can also create model resources to represent particle systems.
sprite(1).member.newModelResource("my resource",#sphere) sprite(1).member.modelResource("my resource").radius = 5 sprite(1).member.newModel("my model", sprite(1).member.modelResource("my resource")
See Also: newModelResource, model, newModel
See Chapter/Appendix: 39
modelsUnderRay 3D, Collision Detection Function
This function will return a list of models that are intersected by a ray drawn from one point in the world in a specified direction.
The first parameter is the location of the starting point of the ray. The second parameter is the direction of the ray. The third parameter is the number of models to return. If you do not use this parameter, then you will get a complete list of models that the ray passes through.
A fourth parameter determines how much information to return for each model. A value of #simple will return only model references. A value of #detailed will return a list with #model, #distance, #isectPosition, #isectNormal, #meshID, #faceID, #vertices, and #uvCoord.
This function is fast, so it is a good way to determine collision detection. You can simply cast a ray from the location of your moving object in the direction it is moving to see what objects it will hit and how far away they are at the moment.
modelList = sprite(1).member.modelsUnderRay(vector(50,50,0),vector(1,0,0),3,#detailed)
See Also: modelUnderLoc
See Chapter/Appendix: 39
modelUnderLoc, modelsUnderLoc 3D, Selection Function
The first function will return the first model found at a 2D location on the sprite. The second function will return a list of models found at a 2D location on the sprite. It can be used to determine which model a user has clicked on.
With modelsUnderLoc, the first parameter is the 2D location within the sprite that you are interested in. The second parameter is the number of models to return. If you do not use this parameter, then you will get a complete list of models found at that point.
A third parameter determines how much information to return for each model. A value of #simple will return only model references. A value of #detailed will return a list with #model, #distance, #isectPosition, #isectNormal, #meshID, #faceID, #vertices, and #uvCoord.
m = sprite(1).camera.modelUnderLoc m = sprite(1).camera.modelsUnderLoc(point(160,120),1,#simple)
See Also: modelsUnderRay
See Chapter/Appendix: 39
modified Member Property
Returns TRUE if the member has changed since the file was last saved.
if member("myMember").modified then...
See Also: modifiedBy, modifiedDate
modifiedBy Member Property
Returns the name of the last person to modify the member. This name is taken from the name used to register the copy of Director that made the modification.
put member("myMember").modifiedBy "Gary Rosenzweig"
See Also: modified, modifiedDate
modifiedDate Member Property
Returns the time that the member was last modified.
put member("myMembe").modifiedDate date( 2000, 2, 16 )
See Also: modified, modifiedBy
modifier 3D, Models Function
Returns a list of all of the modifiers that have been assigned to a model. Alternatively, you could use this as a list to get a single modifier.
myMods = sprite(1).member.model("my model").modifier theFirstMode = sprite(1).member.model("my model").modifer[1]
See Also: collision, bonesPlayer, keyframePlayer, toon, inker, lod, sds, meshDeform
See Chapter/Appendix: 39
modifiers See getRendererServices
month Date & Time Property
A property of a date object.
d = date(2000,3,17) put d.month 3
See Also: date, month, year, seconds, systemDate
See Chapter/Appendix: 21
mostRecentCuePoint Sound, Digital Video Property
Returns the name of the most recent cue point that was passed.
if sound(1).mostRecentCuePoint() = "section2" then...
See Also: cuePointNames, isPastCuePoint, cuePassed
motion 3D, Animation Object
Refers to a motion object that was put in the 3D member when it was created in a 3D graphics program. Can also refer to motions create by cloning or mapping other motions.
myMotion = sprite(1).member.motion("my motion")
See Also: duration, map
motionQuality QTVR Property
Enables you to set the motion quality of a QTVR movie. Possible values are #minQuality, #maxQuality, or #normalQuality.
sprite(7).motionQuality = #normalQuality
mouseCast Mouse Property
Obsolete. Returns the number of the member under the cursor on the Stage. Returns a single cast-specific number if not in cast library 1.
if the mouseCast = 7 then...
See Also: mouseMember, rollover
mouseChar Field, Mouse Property
Returns the number of the character in a field that is currently under the cursor.
if the mouseChar > 20 then...
See Also: mouseWord, mouseItem, mouseLine
mouseDown Behaviors, Mouse Event Handler
Responds to events created by the user clicking the mouse on a sprite (behaviors) or the Stage (frames, movie scripts).
on mouseDown me go to frame "myFrame" end
See Also: mouseUp, mouseDownScript
See Chapter/Appendix: 14
mouseDown Mouse Property
Returns TRUE if the mouse button is currently being pressed.
if the mouseDown then...
See Also: mouseStillDown
mouseDownScript Movie, Mouse Property
Enables you to set a handler to be called first when the user clicks.
the mouseDownScript = "myClickHandler"
See Also: mouseDown, mouseUpScript
mouseEnter Behaviors, Mouse Event Handler
Responds to the situation in which the cursor enters the sprite's area.
on mouseEnter me sprite(me.spriteNum).member = member("rollover") end
See Also: mouseLeave, mouseWithin
See Chapter/Appendix: 14
mouseH System, Mouse Property
Returns the horizontal location of the cursor on the Stage.
if the mouseH < 320 then...
See Also: mouseLoc, mouseV, clickLoc
mouseItem Field, Mouse Property
Returns the number of the item in a field that is currently under the cursor.
if the mouseItem = 1 then...
See Also:mouseChar, mouseWord, mouseLine
MouseLeave Behaviors, Mouse Event Handler
Responds to the situation in which the cursor leaves the sprite's area.
on mouseLeave me sprite(me.spriteNum).member = member("normal") end
See Also: mouseEnter, mouseWithin
See Chapter/Appendix: 14
mouseLevel QTVR, Mouse Property
This QTVR sprite property determines how mouse clicks are sent to the QTVR movie. Possible values are #all, #none, #controller (sent only when the control bar is present), and #shared (sent to both QTVR and the movie).
sprite(7).mouseLevel = #shared
mouseLine Field, Mouse Property
Returns the number of the line in a field that is currently under the cursor.
if the mouseLine = 3 then...
See Also: mouseChar, mouseWord, mouseItem
mouseLoc System, Mouse Property
Returns the point location of the cursor on the Stage.
currLoc = the mouseLoc
See Also: mouseH, mouseV, clickLoc
mouseMember System, Mouse Property
Returns the member under the cursor on the Stage.
if the mouseMember = 56 then...
See Also: mouseCast, rollover
mouseOverButton Flash, Mouse Property
Returns TRUE if the cursor is over a button in the Flash movie sprite.
if sprite(7).mouseOverButton then...
See Also: hitTest
See Chapter/Appendix: 20
mouseUp Behaviors, Mouse Event Handler
Responds to events created by the user clicking the mouse, and then lifting up over a sprite (behaviors) or the Stage (frames, movie scripts).
on mouseUp me go to frame "myFrame" end
See Also: mouseDown, mouseUpScript
See Chapter/Appendix: 14
mouseUp Mouse Property
Returns TRUE if the mouse button is not pressed.
if the mouseUp then...
See Also: mouseStillDown
mouseUpOutSide Behaviors, Mouse Event Handler
Responds to events created by the user clicking the mouse down on a sprite, but then lifting up outside the sprite.
on mouseUpOutside me alert "Action cancelled." end
See Also: mouseUp
See Chapter/Appendix: 14
mouseUpScript Movie, Mouse Property
Enables you to set a handler to be called first when the user clicks down and then releases.
the mouseUpScript = "myClickHandler"
See Also: mouseUp, mouseDownScript
mouseV Mouse Property
Returns the vertical location of the cursor on the Stage.
if the mouseV < 240 then...
See Also: mouseH, mouseLoc, clickLoc
mouseWithin Behaviors, Mouse Event Handler
Called once per frame when the cursor is inside the sprite's area.
on mouseWithin me member("Timer").text = the time end
See Also: mouseEnter, mouseLeave, rollover
See Chapter/Appendix: 14
mouseWord Field, Mouse Property
Returns the number of the word in a field that is currently under the cursor.
if the mouseWord = 1 then...
See Also: mouseChar, mouseItem, mouseLine
See Chapter/Appendix: 16
move Member Command
Enables you to move a member from one location in the Cast to another. If no second parameter is used, the member moves to the first vacant spot.
move member("myMember"),member(7,"picture cast")
See Also: erase, duplicate, new
See Chapter/Appendix: 26
moveableSprite Sprite Property
Corresponds to the moveable property of the sprite. When TRUE, users can drag the sprite around on the Stage.
sprite(7).moveableSprite = TRUE
moveToBack MIAW Command
Sends a MIAW behind all other MIAWs.
moveToBack window("myMIAW")
See Also: moveToFront
See Chapter/Appendix: 24
moveToFront MIAW Command
Moves a MIAW in front of all other MIAWs.
moveToFront window("myMIAW")
See Also: moveToBack
See Chapter/Appendix: 24
moveVertex Vector Command
Moves a vertex point by a horizontal and vertical value.
moveVertex(member("myVector"),5,x,y)
See Also: addVertex, deleteVertex, moveVertexHandle, vertexList
See Chapter/Appendix: 20
moveVertexHandle Vector Command
Moves a vertex handle point by a horizontal and vertical value.
moveVertexHandle(member("myVector",5,1,x,y))
See Also: addVertex, deleteVertex, moveVertex, vertexList
See Chapter/Appendix: 20
moveWindow MIAW Event Handler
This event handler is called if the user moves a MIAW.
on moveWindow sound(1).play(member("drag")) end
See Also: activeWindow
See Chapter/Appendix: 24
movie Movie Object
Used to modify a go or play command to refer to a movie.
go to movie "myMovie.dir" go to frame 7 of movie "myMovie.dir"
See Also: movieName
See Chapter/Appendix: 13
movieAboutInfo Movie Property
Corresponds to the "about" text entered in the Movie Properties dialog box.
if the movieAboutInfo contains "new" then...
See Also: movieCopyrightInfo
See Chapter/Appendix: 21
movieCopyrightInfo Movie Property
Corresponds to the copyright text entered in the Movie Properties dialog box.
if the movieCopyrightInfo contains "1999" then...
See Also: movieAboutInfo
movieFileFreeSize Movie Property
The number of bytes that can be saved by using File, Save and Compact.
on stopMovie if the runMode = "Author" then if the movieFileFreeSize > 50000 then alert "Time to Save and Compact!" end if end if end
See Also: movieFileSize
movieFileSize Movie Property
The size of the movie's file.
if the movieFileSize > 100000 then...
See Also: movieFileFreeSize
movieFileVersion Movie Property
Returns the version of Director that was used to last modify the movie.
put the movieFileVersion "800"
See Also: version
movieImageCompression Movie Property
Corresponds to the movie's setting in the Publish Settings dialog box. Can be either #standard or #jpeg.
the movieImageCompression = #jpeg
See Also: imageCompression, imageQuality, movieImageQuality
See Chapter/Appendix: 9
movieImageQuality Movie Property
Corresponds to the setting in the Publish Settings dialog box. Enables you to specify the amount of JPEG compression used when a Shockwave movie is created.
the movieImageQuality = 80
See Also: imageCompression, imageQuality, movieImageCompression
See Chapter/Appendix: 9
movieName Movie Property
Returns the name of the movie file.
put the movieName "mymovie.dir"
See Also: moviePath
moviePath Movie Property
Returns the full pathname of the movie file.
put the moviePath "Powerbook HD:My Projects:"
See Also: movieName
movieRate Digital Video Property
Controls the rate at which a digital video sprite plays. 1 is normal, 0 is still, -1 is backward, 2 is double speed, and so on.
sprite(7).movieRate = 2
See Also: duration, movieTime
See Chapter/Appendix: 19
movieTime Digital Video Property
Enables you to get and set the playback position in a digital video sprite. Measured in ticks.
sprite(7).movieTime = 0
See Also: duration, movieRate
See Chapter/Appendix: 19
movieXtraList Xtras Property
Returns a property list with the name and downloadable package information for all the movie's Xtras. This does not mean that those Xtras are available, but simply that the movie thinks that they are needed.
put the movieXtraList [[#name: "SWA Streaming PPC Xtra"], [#name: "TextXtra PPC"], [#name: "TextAsset PPC"],
[#name: "Font Xtra PPC"], [#name: "Font Asset PPC"], [#name: "Sound Control"]]
See Also: xtraList
See Chapter/Appendix: 25
multiply 3D, Math Function
Takes a transform and applies all of the aspects of a second transform on it.
t1 = transform() t1.rotation = vector(90,0,0) t2 = transform() t2.position = vector(10,10,10) t2.multiply(t1) put t2.position vector( 10.0000, -10.0000, 10.0000 )
See Also: dotProduct, crossProduct
multiSound System Property
Returns TRUE if the computer is capable of playing sound in more than one channel.
if the multiSound then...
See Chapter/Appendix: 17
name Member, Casts, MIAW, Xtras, 3D Property
Returns the name of the member, cast library, window, Xtra object, or 3D object.
memName = member(7).name castName = castLib(2).name 3DmodelName = sprite(1).member.model[1].name winName = myWindow.name
See Also: number
See Chapter/Appendix: 13
name Menu Property
Returns the name of a menu installed with installMenu. Cannot be set. Can get and set menuItems, however. Must use old (not dot) syntax.
the name of menuItem 5 of menu 1 = "Test"
See Also: menuItem, installMenu
See Chapter/Appendix: 21
near 3D, Camera Property
The distance from the camera where the fog starts at its minimum density.
sprite(1).camera.fog.near = 500
See Also: far, fog
See Chapter/Appendix: 39
nearFiltering 3D, Textures Property
Whether or not bilinear filtering is used when a texture needs to be rendered larger than its original bitmap size. The default setting is TRUE, which will smooth the texture.
sprite(1).member.texture("my texture").nearFiltering = FALSE
neighbor 3D, Mesh Deform Function
Returns a list of faces that are touching a face in a mesh deform.
myFaces = sprite(1).member.model("my model").meshDeform.mesh[1].face[1].neighbor
See Also: face, meshDeform
See Chapter/Appendix: 39
netAbort Network Command
Cancels a network operation.
netAbort(gNetID)
See Also: getNetText, postNetText
See Chapter/Appendix: 22
netDone Network Function
Returns TRUE if the network operation is complete.
if netDone(gNetID) then...
See Also: getNetText, postNetText
See Chapter/Appendix: 22
netError Network Function
Returns a 0 for no error, and an error code if there is a problem.
if netError(gNetID) <> 0 then...
See Also: getNetText, postNetText
See Chapter/Appendix: 22
netLastModDate Network Function
After netDone returns TRUE, this function returns the modification date of the item.
modDate = netLastModDate(gNetID)
See Also: getNetText, postNetText
See Chapter/Appendix: 22
netMIME Network Function
After netDone returns TRUE, this function returns the MIME type (file type) of the item.
mime = netMIME(gNetID)
See Also: getNetText, postNetText
See Chapter/Appendix: 22
netPresent Network Property
Returns TRUE if the network Xtras are present in a projector. Does not tell you whether there is a network connection, however.
if the netPresent then...
See Also: the environment
See Chapter/Appendix: 22
netStatus Shockwave Command
Places a string in the message area of Netscape Navigator.
netStatus("Shockwave movie ready.")
See Chapter/Appendix: 22
netTextResult Network Function
After netDone returns TRUE, this function returns the text of the item.
if netDone(gNetID) then myText = netTextResult(gNetID) end if
See Also: getNetText, postNetText
See Chapter/Appendix: 22
netThrottleTicks Network Property
How frequently network operations are given processing time. Default is 15. Higher means less time spent processing network commands.
the netThrottleTicks = 30
See Chapter/Appendix: 22
new Xtras Function
Returns a new instance of an Xtra.
fileObj = new(xtra "FileIO")
See Chapter/Appendix: 25
new Member, Casts Command
Creates a new member at the next empty location in the Cast, or a specific location.
new(#bitmap) new(#text,member(7,2))
See Also: duplicate, erase, move, media
See Chapter/Appendix: 26
new OOP Function
Returns a new instance of a parent script.
myObj = new(script "myParent")
See Also: menuItem, installMenu
See Chapter/Appendix: 23
newCurve Vector Command
Appends a #newCurve property to a vector shape's vertex list. Points added to it thereafter are part of a new curve.
member("myVector").newCurve()
See Also: curve, vertexList
See Chapter/Appendix: 20
newCamera 3D, Camera Command
Creates a new default camera in the member.
myCamera = sprite(1).member.newCamera("my camera")
See Also: addCamera, deleteCamera
See Chapter/Appendix: 39
newGroup 3D, Groups Command
Creates a new empty group in the member.
myGroup = sprite(1).member.newGroup("my group")
See Also: deleteGroup, addChild
See Chapter/Appendix: 39
newLight 3D, Lights Command
Creates a new default light in a member. The second parameter can be either #ambient, #directional, #point or #spot.
myLight = sprite(1).member.newLight("my light",#spot)
See Also: deleteLight, type
See Chapter/Appendix: 39
newMesh 3D, Mesh Command
Creates a new mesh model. The second parameter is the number of faces. The third parameter is the number of vertices. The fourth parameter is the number of normals, the fourth parameter is the number of colors, and the last parameter is the number of texture coordinates.
See Also: face, generateNormals, build
newModel 3D, Models Command
Creates a new model from a model resource.
sprite(1).member.newModel("my model", sprite(1).member.modelResource("my resource"))
See Also: newModelResource, deleteModel
See Chapter/Appendix: 39
newModelResource 3D, Models Command
Creates a new model resource, usually a primitive or a particle system. The first parameter is the name of the resource. The second parameter is the type of resource. The third parameter, used for primitives, can be #back, #front, or #both depending on which sides of the faces should reflect light.
sprite(1).member.newModelResource("my box", #box)
See Also: newModel, deleteModelResource
See Chapter/Appendix: 39
newMotion 3D, Animation Command
Creates a new motion object in a member. You cannot program the motion directly, but you can use map to combine other motions in this new object.
sprite(1).member.newMotion("my motion")
See Also: map, deleteMotion
See Chapter/Appendix: 39
newShader 3D, Shaders Command
Creates a new shader. The second parameter is the type fo shader, usually #standard. It can also be #painter, #engraver, or #newsprint if you desire a special effect.
sprite(1).member.newShader("my shader", #standard)
See Also: deleteShader, shader
See Chapter/Appendix: 39
newTexture 3D, Texture Command
Creates a new texture object in the member. You could apply this texture ot a shader, backdrop or overlay.
The second parameter can be #fromCastmember or #fromImageObject. The third parameter is the member or image reference.
sprite(1).member.newTexture("my texture",#fromCastmember,member("my bitmap"))
See Also: texture, deleteTexture
See Chapter/Appendix: 39
next Navigation Modifier
Refers to the very next labeled frame when used after a go command.
go next
See Also: previous, marker
See Chapter/Appendix: 13
next repeat Programming Command
Ignores the rest of the lines in a repeat loop and proceeds to the next loop iteration.
repeat with i = 1 to 10 if list[i] > 100 then next repeat put list[i] end repeat
See Also: repeat
See Chapter/Appendix: 13
node QTVR Property
The current node being shown by a QTVR sprite.
if sprite(7).node = 1 then...
nodeEnterCallback QTVR Property
Set this to the name of a handler to get called when the QTVR movie switches nodes. The first parameter is me, and the second is the ID of the node.
sprite(7).nodeEnterCallback = "myNodeSwitchHandler"
See Also: HotSpotEnterCallback, nodeExitCallback, triggerCallback
nodeExitCallback QTVR Property
Set this to the name of a handler to be called just before the QTVR movie switches nodes. The first parameter is me, and the second is the ID of the node.
Sprite(7).nodeExitCallback = "myNodeSwitchHandler"
See Also: HotSpotExitCallback, nodeEnterCallback, triggerCallback
nodeType QTVR Property
Returns the type of node that the QTVR sprite is showing. Possible values are #object, #panorama, or #unknown (not a QTVR sprite).
if sprite(7).nodeType = #object then...
See Also: node
normalize 3D, Math Function
Normalizes a vector. This simply means that the vector's magnitude or length is reduced to the length of 1, but the direction of the vector remains the same.
v = vector(5,5,5) v.normalize() put v vector( 0.5774, 0.5774, 0.5774 )
See Also: getNormalized, magnitude
See Chapter/Appendix: 39
normalList 3D, Mesh Property
The list of normals in a mesh model.
myNormals = sprite(1).member.modelResource("my mesh").normalList
See Also: face, meshDeform
See Chapter/Appendix: 39
normals 3D, Mesh Property
This list refers, by number, to the normals in the normalList for a mesh model resource. So a value of 1 in the normals maps the to first value in the normalList.
See Also: normalList
See Chapter/Appendix: 39
not Logic Operator
Reverses the Boolean value of the expression. TRUE becomes FALSE and FALSE becomes TRUE.
If not myCondition then...
See Also: and, or
nothing Programming Command
Performs no action. Useful for filling segments of if statements to make them easier to read, or for placing debugging break points.
if a = 1 then nothing else go to frame "myframe" end if
number Member, Casts, MIAW, Xtras, Strings, Misc Property
Used throughout Lingo to identify the number of various objects such as members or Cast libraries. Can also be used as an alternative to count with old syntax to find the total number of items in string chunks. Can also tell you the number of some objects with syntax, such as "the number of members" or "the number of Xtras". You can use it to tell whether a member exists with "if the number of member("myMember") > 0 then...".
if member("myMember").number < 10 then... if castLib("myCast").number = 1 then... n = the number of words in myString
See Also: name, count
See Chapter/Appendix: 13
numChannels Shockwave Audio Property
Returns the number of channels used by a Shockwave audio member.
if member("mySWA").numChannels = 1 then...
See Also: multiSound
See Chapter/Appendix: 17
numParticles 3D, Particle Systems Property
The number of particles emitted by the particle system.
sprite(1).member.modelResource("my particle system").emitter.numParticles = 5000
See Also: lifetime, emitter, mode, loop
See Chapter/Appendix: 39
numSegments 3D, Primitives Property
The number of segments used to create the body of a cylinder.
sprite(1).member.modelResource("my cylinder").numSegments = 15
See Also: topCap, bottomCap, resolution
See Chapter/Appendix: 39
numToChar Strings Function
Converts an ASCII character value to a string character.
put numtochar(65) "A"
See Also: charToNum
See Chapter/Appendix: 16
obeyScoreRotation Flash Property
If TRUE, the Flash sprite can be rotated on the Stage.
member("myFlash").obeyScoreRotation = TRUE
See Also: rotation
See Chapter/Appendix: 20
objectP Logic Function
Returns TRUE if the value is some sort of object, such as a list, script instance, Xtra instance, or window.
if objectP(myObject) then...
See Also: ilk, symbolP
See Chapter/Appendix: 25
offset Strings Function
Takes two parameters: a search string, and a string to search. If it finds the search string in the second string, it returns the position of the first character. Otherwise, it returns 0.
p = offset("wor","Hello World.")
See Also: contains, starts
See Chapter/Appendix: 16
offset Math Function
Takes a rectangle, a horizontal offset, and a vertical offset, and returns a rectangle moved by the offset.
myNewRect = offset(myRect,x,y)
See Also: rect, inflate, map, union
on Programming Misc
Used before a message name, such as "mouseDown" or "exitFrame", to declare the start of a handler in a script member.
on mouseUp go to frame 1 end
See Chapter/Appendix: 12, 13, 14
open Misc Command
Launches an external application from a projector. Note that this command is far from perfect. If you need a reliable way to open external files, use an Xtra such as the MasterApp Xtra.
open "notepad.e XE " open "mytext.txt" with "notepad.e XE "
See Chapter/Appendix: 21
open MIAW Command
Opens a MIAW with the movie specified in the filename. Also opens a new window, which you must then assign a movie to by setting the window's fileName property.
open window("myMIAW.dir")
See Also: fileName, name, visible
See Chapter/Appendix: 24
openWindow MIAW Event Handler
This event handler is called when the MIAW is first opened.
on openWindow sound(1).play(member("opensound")) end
See Also: closeWindow, activateWindow
See Chapter/Appendix: 24
openXLib Xtras Command
Manually opens an Xtra. Usually, Xtras are automatically included by bundling them with a projector or placing them in an Xtras folder. This command enables you to open Xtra files elsewhere.
openXlib (the moviePath)&"Other Xtras:FileIO"
See Also: closeXlib
See Chapter/Appendix: 25
optionDown Keyboard Property
Returns TRUE if the user is holding down the Option key on the Mac or the Alt key in Windows.
if the optionDown then...
See Also: commandDown, controlDown, shiftDown, keyPressed
See Chapter/Appendix: 16
or Logic Operator
Returns TRUE if either of two expressions is TRUE, and FALSE only if both are FALSE.
if (a = 1) or (b = 2) then...
See Also: and, not
See Chapter/Appendix: 13
organizationName System Property
Returns the company name to which the copy of Director is registered.
if the organizationName = "CleverMedia" then...
See Also: serialNumber, userName
originalFont Font Property
Returns the name of the original font that was used to create the font member.
put member("myFont").originalFont "Courier"
See Also: recordFont
See Chapter/Appendix: 16
originH Flash, Vector Property
Sets the horizontal location of the point in a vector shape, Flash member, or sprite in which rotation and scaling occur.
member("myVector").originH = 45
See Also: originMode, originV
See Chapter/Appendix: 20
originMode Flash, Vector Property
Sets the location in a vector shape, Flash member, or sprite in which rotation and scaling occur. Possible values are #center, #topleft, and #point. The last value relies on originPoint for the location.
member("myVector).originMode = #point
See Also: originPoint, originH, originV
See Chapter/Appendix: 20
originPoint Flash, Vector Property
Sets the location of the point in a vector shape, Flash member, or sprite in which rotation and scaling occur.
member("myVector").originPoint = point(45,34)
See Also: originMode
See Chapter/Appendix: 20
originV Flash, Vector Property
Sets the location of the point in a vector shape, Flash member, or sprite in which rotation and scaling occur.
member("myVector").originV = 34
See Also: originMode, originH
See Chapter/Appendix: 20
orthoHeight 3D, Camera Property
If you set the camera's projection to #othrographic, this property can be used to adjust the amount of the 3D world that appears in the sprite. The default value is 200.
sprite(1).camera.orthoHeight = 300
See Also: projection
See Chapter/Appendix: 39
orthoHeight
otherwise Programming Structure
An optional final portion of a case statement that e XEcutes only when no other case value is matched.
case myVariable of 1: go to frame 1 2: go to frame 7 otherwise: go to frame 9 end case
See Also: case, else
See Chapter/Appendix: 13
outlineFontList Fonts Function
This undocumented property of a font member will return a list of all of the names of outline fonts on the computer.
put member("my font member").outlineFontList()
See Also: fontList
overlay 3D, Camera Property
Refers to one of the overlays applied to a camera. An overlay appears as a 2D image in front the 3D world. It remains steady as the camera might swing around to show other parts of the world.
sprite(1).camera.overlay[1].source = myTexture
See Also: loc, source, scale, rotation, regPoint, blend, count, backdrop
pageHeight Field, Text Property
Returns the height, in pi XEls, of the visible area of a field or text member.
member("myText").scrollTop = member("myText").scrollTop + member("myText").pageHeight
See Also: scrollTop
See Chapter/Appendix: 16
palette Bitmap Property
The palette used by a bitmap member. Negative numbers correspond to built-in palettes and positive numbers correspond to palette members.
if member("myBitmap").palette = - 1 then
See Also: paletteRef
See Chapter/Appendix: 18
paletteIndex Color Object
A color object that is specified by the number in the movie's palette.
c = paletteIndex(35) put c paletteIndex( 35 ) c.colorType = #rgb put c rgb( 255, 0, 0 )
See Also: color, rgb
See Chapter/Appendix: 18
paletteMapping Movie Property
Enables Director to remap a member's palette to the closest colors if its palette is different from the one being used by the Stage.
the paletteMapping = TRUE
paletteRef Bitmap Property
Returns the palette symbol, such as #systemMac, for bitmaps that use built-in palettes, and member references for members that use a custom palette.
put member(2).paletteRef #systemWin
See Also: palette
pan QTVR Property
The current viewing angle of a QTVR sprite, in degrees.
sprite(7).pan = 60
See Also: fieldOfView
pan Sound Property
Enables you to change the stereo balance of a sound. A value of -100 means that the sound comes completely from the left speaker. A value of 100 means the sound comes completely out of the right speaker. A value of 0 is the default.
sound(1).pan = -100
See Also: volume
See Chapter/Appendix: 17
paragraph Strings Expression
Equivalent to line. It enables you to reference a chunk expression broken up by Return characters.
put myString.paragraph[5]
See Also: line
See Chapter/Appendix: 16
param Programming Function
Enables you to get a parameter of a handler by number.
on myHandler if param(1) = #test then... end
See Also: paramCount
paramCount Programming Property
Returns the number of parameters sent to the current handler.
on myHandler if the paramCount < 2 then... end
See Also: param
parent 3D, Grouping Property
Refers to the parent of a 3D object. You can make the object a child of another object by assigning its parent property that value. If you set the parent property to VOID, it is the same as usinf removeFromWorld. You can also set the parent to group("world") to get the same result as using addToWorld.
sprite(1).member.model("my child model").parent = sprite(1).member.model("my parent model")
See Also: addChild, addToWorld, removeFromWOrld, child
See Chapter/Appendix: 39
pass Programming Command
Enables the current event, such as a "mouseDown", to be passed to the next level of the message hierarchy when the current handler is done.
on keyUp me if the key <> RETURN then pass end if end
See Also: stopEvent
pasteClipBoardInto Member Command
Takes the current content of the Clipboard and places it in the member specified.
pasteClipBoardInto member("myMember")
See Also: copyToClipBoard
path 3D, Particle System Property
This is a list of vectors that define a path for particles to follow. How closely they follow the path depends on the pathStrength.
sprite(1).member.modelResource("my particle system").emitter.path = [vector(0,0,0), vector(10,10,0)]
See Also: pathStrength, emitter
See Chapter/Appendix: 39
pathName Flash Property
Specifies the location of the external file where the assets of Flash cast member are stored.
member(myFlashMember).pathName = (the moviePath)&"myFlashMovie.swf"
See Also: moviePath, fileName
See Chapter/Appendix: 20
pathStrength 3D, Particle System Property
This is how closely the particles follow the path defined by the path property. A value of 0 means that the particles will not follow the path at all. The default value is .1, but you can set it up as high as you need to get the effect you want.
sprite(1).member.modelResource("my particle system").pathStrength = .2
See Also: path, emitter
See Chapter/Appendix: 39
pattern Shape Property
The pattern used by the shape. A value of 0 is a solid; other values match positions in the pattern palette of the Tool palette.
member("myOval").pattern = 7
See Also: color, bgColor
See Chapter/Appendix: 20
pause Sound Command
Pauses a sound. The play command resumes the sound from the exact spot at which it was paused.
sound(1).pause()
See Also: sound, play
See Chapter/Appendix: 17
pause Animated GIF Command
Pauses an animated GIF sprite.
pause sprite(7)
See Also: resume, rewind
pause 3D, Animation Command
Pauses a bones player motion or key frame player animation.
sprite(1).member.model("my model").bonesPlayer.pause()
See Also: play
See Chapter/Appendix: 39
pause member Shockwave Audio Command
Pauses a Shockwave audio file.
pause member("mySWA")
See Also: play, stop
See Chapter/Appendix: 17
pausedAtStart Flash, Digital Video Property
Determines whether a video or Flash member starts playing when it appears on the Stage.
member("myVideo").pausedAtStart = FALSE
percentPlayed Shockwave Audio Property
Returns the percentage of a streaming audio sound that has played.
if member("mySWA").percentPlayed > 50 then...
See Also: percentStreamed
See Chapter/Appendix: 17
percentStreamed Shockwave Audio, Flash, 3D Property
Returns the percentage of a streaming audio sound, Flash member or 3D member that has loaded.
if member("mySWA").percentStreamed > 50 then...
See Also: percentPlayed
See Chapter/Appendix: 17
period Timeout Property
The number of milliseconds between events in a timeout object.
timeout("myTimeout").period = 5000
See Also: timeout
See Chapter/Appendix: 21
perpendicularTo 3D, Math Function
Takes the current vector plus another vector and returns a new vector that is perpendicular to both.
v1 = vector(1,0,0) v2 = vector(0,1,0) put v1.perpendicularTo(v2) vector( 0.0000, 0.0000, 1.0000 )
See Also: cross, dot, normalize
See Chapter/Appendix: 39
persistent Timeout Property
If TRUE, the timeout object persists beyond the life of the current movie. Another movie can then be jumped to with a go or play command without destroying the timeout object. The default is FALSE.
timeout("myTimeout").persistent = TRUE
See Also: timeout
See Chapter/Appendix: 21
PI Math Constant
Returns pi as a floating point number. Also works as a function: pi().
put PI 3.1416
See Also: sin, cos, tan, atan
See Chapter/Appendix: 13
picture Bitmap Property
Refers to the image inside a bitmap member.
member("myBitmap").picture = member("otherBitmap").picture
See Also: media, image
See Chapter/Appendix: 18
picture Image Property
The screen image of the Stage or a MIAW. Can be stored in a variable or assigned to a bitmap picture property.
member("myBitmap").picture = (the stage).picture
See Also: image
See Chapter/Appendix: 18
pictureP Image Function
Returns TRUE if the value is a picture.
If pictureP(myPicture) then...
See Also: picture
See Chapter/Appendix: 18
platform System Property
Returns either "Macintosh,PowerPC" or "Windows,32". In a Java applet, it returns "Java" plus the version, browser, and operating system.
if the platform contains "win" then...
See Also: runMode, environment
See Chapter/Appendix: 21
play Navigation Command
Jumps the playback head to a new location. It remembers the current frame, however, and enables the movie to return to it with a play done command.
play frame "myFrame" play frame "myFrame" of movie "myMovie"
See Also: play done, go, gotoNetMovie
See Chapter/Appendix: 13
play Sound Command
Starts a queued sound, or enables you to queue a sound and start it in one shot.
sound(1).queue([#member: member("mySound"), #preloadTime: 7000, #startTime: 0,
#endTime: 9000, #loopStartTime: 3000, #loopEndTime: 7000, #loopCount: 3]) sound(1).play() sound(2).play(member("mySound2"))
See Also: queue, setSoundList
See Chapter/Appendix: 17
play 3D, Animation Command
Unpauses a bones player motion or keyframe player animation. In addition, several parameters can be added that have to do with looping and scaling. In order, they are: looped, startTime, endTime, scale and offset. These are similar to the way that sounds are queued and played.
sprite(1).member.model("my model").bonesPlayer.play()
See Also: pause, queue, playNext, playList, playing
See Chapter/Appendix: 39
play done Navigation Command
After a play command has been used, you can use play done to return to the frame in which the play command was issued. You can stack as many play and play dones as you want.
play done
See Also: play
See Chapter/Appendix: 13
play member Shockwave Audio Command
Starts a Shockwave audio member streaming and playing.
play member("mySWA")
See Also: pause, stop
See Chapter/Appendix: 17
playBackMode Flash, Animated GIF Property
Flash and animated GIF members and sprites can be set to #normal, #lockStep, or #fi XEd. The #lockStep setting ties the tempo to the Director movie tempo. The #fi XEd setting uses the fi XEdRate property.
member("myFlash").playBackMode = #lockStep
See Also: fi XEdRate
See Chapter/Appendix: 20
playing Flash Property
Returns TRUE if the Flash sprite is playing.
if sprite(7).playing then...
See Also: play, frame
See Chapter/Appendix: 20
playing 3D, Animation Property
Returns TRUE if a key frame player or bones player animation is playing.
if sprite(1).member.model("my model").bonesPlayer.playing then...
See Also: play
See Chapter/Appendix: 39
playlist 3D, Animation Property
This property holds a list of all the motions queued for playback in a bones player or key frame player modifier. The list contains property lists with #name, #loop, #startTime, #endTime, and #scale properties of each animation. You can not set the entire list, but must use queue to add new motions.
myList = sprite(1).member.model("my model").bonesPlayer.playlist
See Also: queue, playNext
See Chapter/Appendix: 39
playNext Sound Command
Jumps directly to the next sound in the queue.
sound(1).playNext()
See Also: play, sound
See Chapter/Appendix: 17
playNext 3D, Animation Command
Skips the rest of the currently playing bones player or keyframe player animation and goes to the next in the queue.
sprite(1).member.model("my model").bonesPlayer.playNext()
See Also: queue, play
See Chapter/Appendix: 39
playRate 3D, Animation Property
By using the playRate property of a bones player or keyframe player animation, you can scale up or down the speed of an animation.
sprite(1).member.model("my model").bonesPlayer.playRate = 2.0
See Also: play, queue
See Chapter/Appendix: 39
point Misc Object
An object with a horizontal and vertical position. It has the properties locH and locV.
p = point(50,30) put p point(50, 30) put p.locH 50 if sprite(7).loc = p then...
See Also: rect, loc
See Chapter/Appendix: 13
pointAt 3D, Models Command
This rotates a model so that it points at a point in the 3D world. A second, alternate parameter defines the direction of "up" for the repositioned model. If this is left out, then the y-axis is used as "up".
sprite(1).member.camera(my camera").pointAt(sprite(1).member.model("my model"))
See Also: pointAtOrientation
See Chapter/Appendix: 39
pointAtOrientation 3D, Models Property
This is a list of two vectors that defines what an object considers to be its front direction and its up direction. This is used by the pointAt command.
sprite(1).member.model("my model").pointAtOrientation = [vector(1,0,0), vector(0,-1,0)]
See Also: pointAt
See Chapter/Appendix: 39
pointInHyperLink Text Function
Takes a sprite and a Stage location and returns TRUE if the mouse location is over a hyperlink in that sprite.
put pointInHyperLink(sprite(7),the mouseLoc)
See Also: hyperlink, hyperlinkRange
See Chapter/Appendix: 16
pointOfContact See collisionData pointToChar Text
Function
Takes a sprite and a Stage location and returns the character number to which the point corresponds, or -1 if the point is not over the text.
cnum = pointToChar(sprite(7),the mouseLoc)
See Also: pointToItem, pointToLine, pointToWord
See Chapter/Appendix: 16
pointToItem Text Function
Takes a sprite and a Stage location and returns the item number to which the point corresponds, or -1 if the point is not over the text.
iNum = pointToItem(sprite(7),the mouseLoc)
See Also: itemDelimiter, pointToChar, pointToLine, pointToWord
See Chapter/Appendix: 16
pointToLine Text Function
Takes a sprite and a Stage location and returns the character number to which the point corresponds, or -1 if the point is not over the text.
lnum = pointToLine(sprite(7),the mouseLoc)
See Also: pointToChar, pointToItem, pointToWord
See Chapter/Appendix: 16
pointToParagraph Text Function
Same as pointToLine.
pNum = pointToParagraph(sprite(7),the mouseLoc)
See Also: pointToLine
See Chapter/Appendix: 16
pointToWord Text Function
Takes a sprite and a Stage location and returns the word number to which the point corresponds, or -1 if the point is not over the text.
wNum = pointToWord(sprite(7),the mouseLoc)
See Also: pointToChar, pointToItem, pointToLine
See Chapter/Appendix: 16
position 3D, Models Property
This is one of the properties of a model's transform property. It relays the vector position of the model.
sprite(1).member.model("my model").transform.position = vector(0,0,0)
See Also: transform, rotation, scale
See Chapter/Appendix: 39
positionReset 3D, Animation Property
If TRUE, then the model will return to its starting position when a bones player animation or keyframe animation is complete.
sprite(1).member.model("my model").bonesPlayer.positionReset = TRUE
See Also: currentLoopState
See Chapter/Appendix: 39
posterFrame Flash Property
Determines which frame of a Flash member is the thumbnail image.
member("myFlash").posterFrame = 20
See Chapter/Appendix: 20
postNetText Network Command
This command uses the Internet POST protocol to contact the server and send it information. It accepts a URL and a specially formatted list.
postNetText(myURL,myList)
See Also: getNetText, netDone, netTextResult, netError
See Chapter/Appendix: 22
power Math Function
Returns the base number to the power of the exponent.
put power(6,3) 216.0000
See Also: sqrt
See Chapter/Appendix: 13
preferred3DRenderer 3D, Misc Property
This system property returns either #auto, #openGL, #directX7_0, #directX5_2 or #software. This is the method set by Director or the Shockwave player that the movie will try to use to render 3D members. The user can change this in Shockwave by Right+Clicking on the movie and choosing the preferred renderer from a list.
if the preferred3Drenderer = #software then...
See Also: getRendererServices, renderDeviceList
See Chapter/Appendix: 39
preLoad Memory Command
Begins loading all the members of a frame, range of frames, or all members in the remaining frames.
preLoad preLoad 3,4
See Also: preLoadMember
See Chapter/Appendix: 21
preLoad Flash, Digital Video Property
For video, it determines whether a movie should be preloaded before it starts playing. For Flash members, it determines whether a Flash member must be loaded into RAM before it starts playing.
member("myVideo").preLoad = TRUE
See Also: streamMode
See Chapter/Appendix: 19
preLoadBuffer Shockwave Audio Command
Prestreams the first few seconds of a Shockwave audio member.
preLoadBuffer member("mySWA")
See Also: preLoadTime
See Chapter/Appendix: 21
preLoadEventAbort Memory Property
If this system property is set to TRUE, preloading stops when the user clicks the mouse or presses a key.
the preLoadEventAbort = TRUE
See Also: preLoad, preLoadMember
See Chapter/Appendix: 21
preLoadMember Memory Command
Begins preloading a member, a range of members, or all remaining members.
preLoadMember preLoadMember "myMember"
See Also: preLoad
See Chapter/Appendix: 21
preLoadMode Memory Property
This cast library property can be set to 0 (load when needed), 1 (load Cast before frame 1), or 2 (load Cast after frame 1).
castLib("myCast").preLoadMode = 1
See Chapter/Appendix: 21
preLoadMovie
Memory
Command
Preloads the members used in the first frame of another movie. This smoothes the transition when you use go or play to jump to another movie.
preLoadMovie("myOtherMovie.dir")
See Chapter/Appendix: 21
preLoadNetThing Shockwave Command
Tells the browser to load an item into its cache. This can smooth playback when using gotoNetMovie or linked media.
preLoadNetThing("http://clevermedia.com/sample.dcr/")
See Also: netDone, downloadNetThing
See Chapter/Appendix: 22
preloadRam Digital Video Property
This system property specifies how much memory is available for preloading video. Measured in KB.
the preLoadRAM = 300
See Chapter/Appendix: 19
preLoadTime Shockwave Audio Property
The number of seconds of audio that should be buffered before sound starts playing.
member("mySWA").preLoadTime = 15
See Also: preLoadBuffer, play member
See Chapter/Appendix: 17
preMultiply 3D, Math Command
Performs a multiply on the first transform, before applying any other rotation or repositioning already in the transfom. This means that the rotation will happen before any repositioning.
preRotate, preScale, preTransform 3D, Math Command
Applies one of the operations to a transform before it takes into account the other factors of the transform.
myVector.preRotate(1,0,0)
prepareFrame Behaviors Event Handler
This handler is called just before Director draws the current frame.
on prepareFrame me sprite(me.spriteNum).locV = sprite(me.spriteNum).locV + 1 end
See Also: enterFrame, exitFrame, idle
See Chapter/Appendix: 14
prepareMovie Movie Event Handler
This handler is called just before Director creates behavior instances and draws the first frame.
on prepareMovie gMyGlobal = 42 end
See Also: on startMovie
See Chapter/Appendix: 13
previous Navigation Modifier
Refers to the previously labeled frame when used after a go command. If the current frame is not labeled, the most recent frame before the current one is the current frame label, and the one before that is the previous label that will be used by this command.
go previous
See Also: next, marker
See Chapter/Appendix: 13
primitives See getRendererServices
print, printAsBitmap Flash Command
This command will send the print or printAsBitmap command to the Flash movie in a sprite. If any frames in the Flash movie have been labeled "#p" then they will be printed. If no frames have been labeled "#p", then the whole movie will be printed. You can specify a target movie clip to be printed, and either #bframe or #bmax as the print boundary. #bframe will print each frame to a custom size while #bmax will determine the print boundary after looking at all of the frames.
sprite(1).print("myMovieClip",#bmax)
See Chapter/Appendix: 20
printFrom Misc Command
Enables you to print the Stage. You can specify a range of frames and a percentage (100, 50, or 25).
printFrom firstFrame,lastFrame, percent
productName System Property
Undocumented Lingo. Returns "Director".
put the productName "Director"
See Chapter/Appendix: 21
productVersion System Property
Undocumented Lingo. Returns "8.0".
put the productVersion "8.0"
See Also: version
See Chapter/Appendix: 21
projection 3D, Camera Property
You can set the projection of a camera to #perspective or #orthographic. The latter means that objects that are further from the camera do not appear smaller.
sprite(1).camera.projection = #orthographic
See Also: fieldOfView, orthoHeight, projectionAngle
See Chapter/Appendix: 39
projectionAngle 3D, Camera Property
Same as fieldOfView.
property OOP, Behaviors Command
Defines variables as properties of behaviors or parent scripts. Place in handlers, or outside all handlers in a script to declare it for use in all handlers in that script.
property pMyProperty, pMyOtherProperty
See Also: global
See Chapter/Appendix: 14
proxyServer Network Command
Sets the values for a proxy server to be used in a projector.
proxyServer serverType, ipAddress, portNum
See Chapter/Appendix: 22
ptToHotSpot QTVR Function
Returns the ID of a hotspot at a specified point.
put ptToHotSpot(sprite(7),the mouseLoc)
puppet Sprite Property
Returns TRUE if the sprite is under Lingo control.
sprite(7).puppet = TRUE
See Also: puppetSprite
puppetPalette Movie Command
Gives Lingo control of the Palette channel in the Score and enables it to assign a new palette.
puppetPalette "Rainbow", speed, nFrames
See Also: framePalette
See Chapter/Appendix: 26
puppetSound Sound Command
Takes control of a Sound channel and plays a sound in it. If no Sound channel number is given, it uses the next available Sound channel, but waits for the next frame to begin, or an updateStage command, before it starts.
puppetSound 1, "mySound"
See Also: sound, play, queue, frameSound1, frameSound2
See Chapter/Appendix: 17
puppetSprite Sprite Command
If set to TRUE, the sprite is placed under Lingo control and does not respond to changes in the Score until set to FALSE.
puppetSprite 7, TRUE
See Also: sprite, puppet
puppetTempo Movie Command
Takes control of the Tempo channel and sets it to a speed in frames per second.
puppetTempo 15
See Also: frameTempo
See Chapter/Appendix: 26
puppetTransition Movie Command
Cues up a transition to be used between the current frame and whichever frame is next.
puppetTransition 1, time, chunkSize, changeArea
See Also: frameTransition
purgePriority Member Property
Sets the purge priority of the member to 0 (Never), 1 (Last), 2 (Next), or 3 (Normal).
member("myMember").purgePriority = 1
See Chapter/Appendix: 21
put Misc Command
Places the result of the expression into the Message window. Can also be used with before, after, and into to insert characters into a string.
t = "Hello world" put "." after t put t "Hello world." put "I said, " before t put t "I said, Hello world." put ":" into char 7 of t put t "I said: Hello world."
See Also: after, before, into
See Chapter/Appendix: 16
qtRegisterAccessKey Digital Video Command
Enables you to use the access keys for QuickTime movies.
qtRegisterAccessKey(categoryString,keyString)
See Also: qtUnRegisterAccessKey
See Chapter/Appendix: 19
qtUnRegisterAccessKey Digital Video Command
Enables you to use the access keys for QuickTime movies.
qtUnRegisterAccessKey(categoryString,keyString)
See Also: qtRegisterAccessKey
See Chapter/Appendix: 19
quad Sprite Property
A list containing the four points that correspond to the four corners of a bitmap or text sprite.
sprite(7).quad = [point(0,0),point(20,10),point(20,30),point(0,40)]
See Also: rect, rotation, skew
See Chapter/Appendix: 18
quality Flash Property
Sets the quality for a Flash sprite or member. Possible values are #autoHigh, #autoLow, #high, or #low.
member("myFlash").quality = #high
See Chapter/Appendix: 20
quality 3D, Textures Property
You can set the quality of a texture to #low, #medium or #high. The default is #low. The #medium setting enabled bilinear mapping while the #high setting enabled #trilinear mapping.
sprite(1).member.texture("my texture").quality = #medium
See Also: nearFiltering
See Chapter/Appendix: 39
queue Sound Command
Adds a sound to the queue. This is a list of sounds that will play one by one when triggered by the play command. The following example features a complete sampling of all the optional parameters.
sound(1).queue([#member: member("mySound"), #preloadTime: 7000,
#startTime: 0, #endTime: 9000, #loopStartTime: 3000, #loopEndTime: 7000, #loopCount: 3]) sound(1).play
See Also: play, preloadTime, startTime, endTime, loopStartTime, loopEndTime, loopCount, setPlayList
See Chapter/Appendix: 17
queue 3D, Animation Command
This command adds a bones player motion or a key frame animation to the queue for a model. It uses the same optional parameters at play.
sprite(1).member.model("my model").bonesPlayer.queue("my motion")
See Also: play, playNext, playRate
See Chapter/Appendix: 39
quickTimeVersion Digital Video Function
Returns a number, either 3.0 or higher, or 2.12 if the version is earlier than QuickTime 3.
put quickTimeVersion() 4.0300
See Chapter/Appendix: 19
quit System Command
Exits Director or a projector. Usually better to use halt in most situations.
quit
See Also: shutdown, restart, halt
See Chapter/Appendix: 21
QUOTE Strings Constant
Represents the quote character.
myString = "I said:"&"E&"Hello World.""E put myString "I said: "Hello World.""
See Also: TAB, RETURN, numToChar
See Chapter/Appendix: 16
radius 3D, Primitives Property
This property of a sphere primitive resource determines the size of the primitive.
sprite(1).member.modelResource("my sphere resource").radius = 20
See Also: topRadius, bottomRadius
See Chapter/Appendix: 39
ramNeeded Memory Function
Takes a range of frames and returns the number of bytes of free memory needed to display them.
if ramNeeded(1,10) > the freeBlock then...
See Also: freeBytes, freeBlock, size
See Chapter/Appendix: 21
random Math Function
Returns a random number from 1 to the number given. To get another range or a floating point range, use this command and then add, subtract, or divide the result.
put random(10) 2 put random(10) 8 put random(10) 5
See Also: randomSeed
See Chapter/Appendix: 32
randomSeed Math Property
Specifies the number seed from which the random function operates. Setting it to a constant number produces an identical series of results from identical random functions.
the randomSeed = 42
See Also: random
randomVector 3D, Math Function
This function returns a random vector with a length of 1.
v = randomVector() put v vector( -0.9193, -0.3644, 0.1487 ) put v.magnitude 1.0000
See Also: normalize
See Chapter/Appendix: 39
rateShift Sound Property
This undocumented property enables you to shift the pitch of a sound up or down by semitones. So, a rateShift of 1 shifts the sound of a middle C piano note to C sharp. The duration also changes as a result.
sound(1).queue([#member: member("mySound"), #rateShift: 1]) sounmd(1).play()
See Also: queue, sound, play
See Chapter/Appendix: 30
rawNew OOP Function
Works like the new function to create a new script object from a parent script. However, rawNew does not call the on new handler in the script.
myObject = script("myParent").rawNew()
See Also: new
See Chapter/Appendix: 23
recordFont Font Command
Embeds a font present on the system into a member.
recordFont(member("myFont"),font,face,sizeList,characterString)
See Chapter/Appendix: 18
rect Misc Object
An object with four elements, meant to represent a rectangle. It has four direct properties: left, top, right, and bottom. It also has the indirect properties of width and height.
myRect = rect(10,10,50,50)
See Also: point
See Chapter/Appendix: 18
rect Member, Sprite, MIAW Property
Represents the rectangle of the sprite on the Stage, the member size, or the MIAW location and size. Also has the subproperties of left, top, right, bottom, width, and height.
sprite(7).rect = rect(10,10,50,50)
See Also: point
rect 3D, Camera Property
This property defines the rectangular area of the camera view inside the 3D sprite. Normally, it is exactly the same as the rect of the 3D member, but you can adjust it to only show the view in a portion of the 3D sprite.
sprite(1).camera.rect = rect(0,0,100,100)
See Also: cameraPosition, cameraRotation
See Chapter/Appendix: 39
red Color Property
Extracts the red property from an rgb color object.
myColor = rgb("336699") put myColor rgb( 51, 102, 153 ) put myColor.red 51
See Also: green, red, color, rgb
See Chapter/Appendix: 18
Strings ref
Property
Provides an object that can be used to refer to a chunk in a member.
myRef = member("myText").word[1] myRef.fontSize = 14
See Chapter/Appendix: 16
3D, Shader reflectionMap Property
The texture to use for reflection mapping in a shader.
sprite(1).member.shader("my shader").reflectionMap = sprite(1).member.texture("my texture")
See Also: textureModeList, glossMap, diffuseLightMap, specularLightMap
reflectivity 3D, Shader Property
Controls the shininess of the default shader for the member. The default is 0.
sprite(1).member.shininess = 50
See Also: diffuseColor, specularColor
See Chapter/Appendix: 39
region 3D, Particle System Property
This list of vectors defines the region where the particles eminate from. If it is a single vector, then the particles come from that single point. If it is two vectors, then the particles come from random positions along the line. If it is four vectors, then the particles come from inside the 3D space defined by the four vectors.
sprite(1).member.modelResource("my particle system").emitter.region = [vector(0,0,0)]
See Also: emitter
See Chapter/Appendix: 39
registerForEvent 3D, Collision Detection Command
This command sets the handler that will be called when a collision occurs. It can also be used to notify a handler when animation starts or stops.
The first parameter must be either #collideAny, #collideWith, #animationStarted, #animationEnded or #timeMS.
The second parameter is the name of the handler, represented as a symbol like #myHandler. The third parameters is a reference to a script object, like me when used in a behavior. Use 0 to have the callback contact a movie script handler.
If you are using the #collideWith event, then a fourth parameter is the reference to the model that the collision must take place with.
The #timeMS property will make this command work like a regular Lingo timeout. The fourth, fifth and sixth parameters will then be the beginning time for the first event, the period between subsequent events, and the number of events to generate. For instance, the values of 1000, 500 and 3 will mean that the handler will be called 1000 milliseconds after the command, then at 1,500 and 2,000 milliseconds. If the last parameter is 0, then the event continues to be called indefinitely.
sprite(1).member.registerForEvent(#collideAny,#myCollisionHandler,me) sprite(1).member.registerForEvent(#timeMS,#myTimerHandler,0,1000,500,3)
See Also: registerScript, setCollisionCallback, unregisterAllEvents
See Chapter/Appendix: 39
registerScript 3D, Collision Detection Command
This is the same as registerForEvent except that a specific model is specified, rather than the whole member.
sprite(1).member.model("my model").registerScript(#collideAny,#myCollisionHandler,me)
See Also: registerForEvent, setCollisionCallback
See Chapter/Appendix: 39
regPoint Bitmap, Vector, Flash Property
The point in the member that corresponds to the location point on the Stage. It usually defaults to the center, but can be changed in editing windows and with this property.
member("myBitmap").regPoint = point(0,0)
See Also: centerRegPoint
See Chapter/Appendix: 18
regPoint 3D, Camera Property
You can set the registration point of a camera's backdrop or overlay.
sprite(1).camera.backdrop[1].regpoint = regPoint = point(10,10)
See Also: addBackdrop, addOverlay
See Chapter/Appendix: 39
regPointVertex Vector Property
If a nonzero value is used, that number is used as the vertex point in the vector shape that also represents the registration point.
member("myVector").regPointVertex = 7
See Also: regPoint, centerRegPoint
See Chapter/Appendix: 20
removeBackdrop 3D, Camera Command
Removes a backdrop from the camera.
sprite(1).camera.removeBackdrop(1)
See Also: addBackdrop
See Chapter/Appendix: 39
removeFromWorld 3D, Models Command
Removes a model or other object from the 3D world. The object remains in the member, but it is not visible. You can bring it back by using addToWorld.
sprite(1).member.model("my model").removeFromWorld()
See Also: addToWorld, deleteModel
See Chapter/Appendix: 39
removeLast 3D, Animation Command
Removes the last item from the queue of a bones player motion or keyframe player animation.
sprite(1).member.model("my model").bonesPlayer.removeLast()
See Also: play, queue
See Chapter/Appendix: 39
removeModifier 3D, Modifiers Command
Removes a modifer, such as inker, toon, mesh deform or collision detection, from a model.
sprite(1).member.model("my model").removeModifier(#collision)
See Also: addModifier
See Chapter/Appendix: 39
removeOverlay 3D, Camera Command
Removes an overlayfrom the camera.
sprite(1).camera.removeOverlay(1)
See Also: addOverlay
See Chapter/Appendix: 39
renderer See getRendererServices
rendererDeviceList See getRendererServices
renderFormat 3D, Texture Property
Allows you to set the color depth used to render the texture. The highest quality value is #rgba8888, which equals 8 bits of data for the red, green, blue and alpha channels. You can also use the values #rgba8880, #rgba5650, #rgba5550, #rgba5551, and #rgba4444. Using a lower setting will mean less memory is used for the texture.
sprite(1).member.texture("my texture").renderFormat = #rgba4444
See Also: getRendererServices
See Chapter/Appendix: 39
renderStyle 3D, Shader Property
You can set the shader to render using #wire for wireframe or #point for dots at each vertex. The default, #fill, is normal shading using colors and textures. #wire and #point are sometimes not available with different hardware or 3D drivers.
sprite(1).member.shader("my shader").renderStyle = #wire
See Chapter/Appendix: 39
repeat Programming Structure
Used to create a loop. Needs to use a while to repeat until a condition is FALSE, a with to repeat through a series of numbers, a with...down to to repeat backward, or a with... in to loop through a list of values.
repeat with i = 1 to 10 ... end repeat repeat while x < 6 ... end repeat repeat with i = 10 down to 1 ... end repeat repeat with I in [5,8,3] ... end repeat
See Also: exit repeat, next repeat
See Chapter/Appendix: 13
resetWorld 3D, Misc Command
This command reverts everything in the world to the original values stored in the 3D member. It will reset any changes you have made via Lingo or behaviors. The result is a 3D world that will look just like it would if you quit and restarted Director.
sprite(1).member.resetWorld()
See Also: revertToWorldDefautls
See Chapter/Appendix: 39
resizeWindow MIAW Event Handler
This handler is called when the MIAW is resized by the user.
on resizeWindow sound(1).play(member("resizeSound")) end
See Also: drawRect, sourceRect, moveWindow
See Chapter/Appendix: 24
resolution 3D, Primitives Property
Allows you to adjust the number of polygons used in a sphere or cylinder primitive.
sprite(1).member.modelResource("my sphere resource").resolution = 20
See Also: numSegments
See Chapter/Appendix: 39
resolve 3D, Collision Detection Property
The default value of resolve is TRUE, which means that collisions through the collision modifier will stop the movement of both objects involved. Set this to FALSE to allow the objects to continue instead, although collision reporting will remain active.
sprite(1).member.mode("my model").collision.resolve = FALSE
See Also: addModifier, collision
See Chapter/Appendix: 39
resolveA, resolveB See collisionData
resource 3D, Primitives Property
You can access and even change the model resource used to create a model.
sprite(1).member.model("my model").resource = myModelResource
See Also: newModelResource, newModel
See Chapter/Appendix: 39
restart System Command
On the Mac, this restarts the computer. In Windows, it just quits the projector.
restart
See Also: quit, halt, shutDown
See Chapter/Appendix: 21 result
Programming
restart Property
This system property contains the return value of the last function called.
addTwoNumbers(4,5) put the result 9
See Also: return
resume sprite Animated GIF Command
Resumes a stopped animated GIF.
resume sprite(7)
See Also: pause sprite, rewind sprite
return Programming Command
In a handler, this command exits the handler and returns a value to the command that called it.
return TRUE
See Also: on, result
See Chapter/Appendix: 12, 13
RETURN Strings Constant
Represents the return character. The same as numToChar(13).
myString = "Hello World."&RETURN
See Also: TAB, QUOTE, numToChar
See Chapter/Appendix: 16
revertToWorldDefaults 3D, Misc Command
Reverts the member to its original state. This will get rid of any changes made with Lingo or Behaviors, as well as any changes made through the property inspector.
sprite(1).member.revertToWorldDefaults()
See Also: resetWorld
See Chapter/Appendix: 30
rewind Sound Command
Restarts the current sound. If a list of sounds is queued, the current sound is restarted and the list continues from there.
sound(1).rewind()
See Also: play, queue
See Chapter/Appendix: 17 rewind sprite
Flash, Animated GIF
Command
Rewinds a Flash or animated GIF to its frame 1.
resume sprite(7)
See Also: pause sprite, rewind sprite
See Chapter/Appendix: 20
rgb Color Object
A color object that is specified by a red, green, and blue value. It can also take a string, such as "#FFFFFF" or "FFFFFF" and convert it to the normal format. Its properties can also be accessed with red, green, and blue properties.
myColor = rgb(255,255,255) myColor = rgb("#FFFFFF")
See Also: color, paletteIndex,
See Chapter/Appendix: 18
right Sprite, Misc Property
Returns the right-side location of a sprite. Can also be used as a property of rect objects.
x = sprite(7).right x = myRect.right
See Also: width, left top, bottom, rect
See Chapter/Appendix: 18
right 3D, Primitives Property
Whether the right side of a 3D box primitive is present or not.
sprite(1).member.modelResource("my box resource").right = FALSE
See Also: back, front, right, top, bottom, topCap, bottomCap, newModelResource
rightIndent Text Property
Used to set the number of pi XEls for a right indent for a whole text member, or a chunk inside one.
member("myText").line[5..6].rightIndent = 18
See Also: leftIndent, firstIndent
See Chapter/Appendix: 16
rightMouseDown Behaviors Event Handler
The same as mouseDown, but with the right mouse button in Windows. Can also be used as the rightMouseDown in the same way as the mouseDown.
on rightMouseDown me go to frame "help" end
See Also: mouseDown, emulateMultiButtonMouse
rightMouseUp Behaviors Event Handler
The same as mouseUp, but with the right mouse button in Windows. Can also be used as the rightMouseUp in the same way as the mouseUp.
on rightMouseUp me go to frame "help" end
See Also: mouseUp, emulateMultiButtonMouse
rollOver Mouse Function
When given a sprite number, it returns TRUE if the cursor is in the sprite's area.
if rollover(7) then...
See Also: mouseEnter, mouseLeave, mouseWithin
See Chapter/Appendix: 15
rollOver Mouse Property
Returns the number of the sprite directly under the cursor.
if the rollover = 7 then...
See Also: mouseEnter, mouseLeave, mouseWithin, mouseMember
See Chapter/Appendix: 15
romanLingo System Property
Usually set to FALSE. Needs to be set to TRUE to deal with special character sets, such as some Mac Japanese fonts.
the romanLingo = TRUE
See Also: inlineImeEnabled
rootLock 3D, Animation Property
If TRUE, then the model will not move as a result of a bones player motion or a keyframe player animation. Other actions, such as rotation, will still happen.
sprite(1).member.model("my model").bonesPlayer.rootLock = TRUE
rootNode 3D, Camera Property
This defines which models and other objects are shown by a camera. Typically, a camera's rootNode is group("world"), which means that everything is shown. But if you want to limit the camera to only show certain models, then you can assign another rootNode which means that only objects that are children of that model or group will be visible.
sprite(1).camera.rootNode = sprite(1).member.model("my model")
See Also: addChild
See Chapter/Appendix: 39
rotate 3D, Models Command
This command will rotate a model by a vector containing degrees of rotation. Alternatively, you can supply three parameters: the rotation amounts in all three a XEs. A parameter at the end can be set to #self, #parent, #world or any model or other object to define what the rotation is relative to.
sprite(1).member.model("my model").rotate(vector(90,0,0)) sprite(1).member.model("my model").rotate(90,0,0)
See Also: translate, rotation
See Chapter/Appendix: 39
rotation Sprite Property
Sets the rotation of a sprite, in degrees. Works with bitmaps, vectors, Flash, text, and some other types.
sprite(7).rotation = 60
See Also: skew, rect, quad
See Chapter/Appendix: 18
rotation 3D, Models, Camera, Shader Property
The rotation property of any transform will return the angle that the model or other object is facing. You can set this property as well. The camera backdrop and overlays, as well as the engraver shader, can also use this property to set their angle.
sprite(1).member.model("my model").transform.rotation = vector(0,90,0)
See Also: transform, position
See Chapter/Appendix: 39
rotationReset 3D, Animation Property
If TRUE, then the rotational changes during a bones player motion or keyframe player animation are reset when the animation is done.
sprite(1).member.model("my model").bonesPlayer.rotationReset= TRUE
See Also: positionReset
See Chapter/Appendix: 39
runMode System Property
Returns "Author", "Projector", "BrowserPlugin", or "Java Applet".
put the runMode
See Also: environment, platform
See Chapter/Appendix: 21
runPropertyDialog Behaviors Event Handler
This handler is called when the author adds a behavior to a sprite. If this handler is not there, the Parameters dialog box is presented instead.
on runPropertyDialog me alert "Remember to include all parameters!" end
See Also: getPropertyDescriptionList
See Chapter/Appendix: 14
safePlayer Shockwave Property
When set to TRUE, Director simulates the security restrictions imposed on Shockwave in a browser.
the safePlayer = TRUE
See Chapter/Appendix: 22
sampleCount Sound Property
Returns the number of samples of the sound currently playing.
if sound(1).sampleCount > 22050 then...
See Also: sampleRate, sampleSize
See Chapter/Appendix: 17
sampleRate Sound Property
Returns the sample frequency of the sound currently playing.
if sound(1).sampleRate > 22050 then...
See Also: sampleCount, sampleSize
See Chapter/Appendix: 17
sampleSize Sound Property
Returns the bit depth of the SWA member. Usually 8 or 16.
if sound(1).sampleSize > 8 then...
See Also: sampleCount, sampleRate
See Chapter/Appendix: 17
save castLib Casts Property
Saves the external cast library specified. If a second parameter is used, it saves it to a new file.
save castLib("myCast"), myPath
See Also: saveMovie
savedLocal Movie Event Handler
For future use.
See Also: allowSaveLocal
saveMovie Movie Command
Saves the current movie. If a pathname is specified, it saves the movie to a new file.
saveMovie myNewPath
See Also: save castLib
scale Flash, Vector, Digital Video Property
For Flash or vector shapes, it uses a floating point number. For QuickTime sprites or members, it uses a list with horizontal and vertical scaling numbers.
sprite(7).scale = 1.5 member("myQuickTime").scale = [1.5,1.5]
See Also: scaleMode, originMode
See Chapter/Appendix: 19, 20
scale 3D, Models Property, Command
This is both a property and command for models and other objects. As part of the transform property, you can set the scale of an object. Or, you can issue the scale command to change the scaling of an object.
sprite(1).member.model("my model").transform.scale = vector(1,1,1) sprite(1).member.model("my model").scale(2,2,2)
See Also: translate, rotate, transform, position, rotation
See Chapter/Appendix: 39
scale 3D, Camera Property
You can adjust the scale of a backdrop or overlay.
sprite(1).camera.backdrop[1].scale = .5
See Also: backdrop, overlay
See Chapter/Appendix: 39
scaleMode Flash, Vector Property
Controls how Flash and vector shape members scale. Possible values are #showAll, #noBorder, #exactFit, #noScale, and #autoSize.
member("myFlash").scaleMode = #autoSize
See Also: scale
See Chapter/Appendix: 20
score Movie Property
This property represents the Score itself. It's the same object type as the media property for a film loop member.
member("myFilmLoop").media = the Score
See Also: media
See Chapter/Appendix: 26
scoreColor Score Recording Property
Enables you to specify the color used by a sprite in the Score window. Values range from 0 to 5 and match the color chips in the Score window. Can be used during authoring and Score recording.
sprite(7).scoreColor = 1
See Chapter/Appendix: 26
scoreSelection Score Recording Property
This property returns a list of lists that contains all the sprites selected in the Score window. Channels above Channel 1, such as the Frame Script channel, are represented by numbers -5 to 0.
put the scoreSelection [[1, 1, 1, 1]]
See Also: selection
See Chapter/Appendix: 26
script Menu Property
The script associated with a menu item. You must use old (not dot) syntax to access this script.
set the script of menuItem 4 of menu 2 = "quit"
See Also: installMenu
See Chapter/Appendix: 21
scriptInstanceList Behaviors Property
Returns a list with all the behaviors attached to a sprite. You can use add to add a new behavior. This property is valid only when the movie is running.
add sprite(7).scriptInstanceList, new(script "myBehavior")
See Also: scriptNum, sendSprite, setScriptList, scriptList
scriptList Behaviors Property
Undocumented Lingo. Returns a list with the behaviors attached to a sprite and the parameter values.
put sprite(7).scriptList
See Also: scriptInstanceList, setScriptList
See Chapter/Appendix: 26
scriptNum Score Recording Property
Enables you to set one script to be used by a sprite during Score recording. Made obsolete by the setScriptList command.
sprite(7).scriptNum = 2
See Also: setScriptList, getScriptList
See Chapter/Appendix: 26
scriptsEnabled Linked Movies Property
If FALSE, the linked movie plays just as an animation, without using any of its scripts.
member("myLinkedMovie").scriptsEnabled = FALSE
See Chapter/Appendix: 24
scriptText Script Property
Returns the text of a script member. You can set this too.
myScript = member("myScript").scriptText
scriptType Script Property
Returns the script type, #movie, #score (behavior), or #parent.
if member("myScript").scriptType = #parent then...
scrollByLine Text, Field Command
Scrolls the text or field member up or down by lines. Use negative numbers to scroll up.
scrollByLine(member("myText"),2)
See Also: scrollTop, scrollByPage
See Chapter/Appendix: 16
scrollByPage Text, Field Command
Scrolls the text or field member up or down by pages. Use negative numbers to scroll up.
scrollByPage(member("myText"),2)
See Also: scrollTop, scrollByLine
See Chapter/Appendix: 16
scrollTop Text, Field Property
The number of pi XEls in a text or field member that are above the visible area on the Stage. A setting of 0 resets a scrolling member to the top.
member("myText").scrollTop = 0
See Also: scrollByLine, scrollByPage, pageHeight
See Chapter/Appendix: 16
sds 3D, Subdivision Surfaces Modifier
Once you add this modifier to a model, you can then access and use the subdivision surfaces property. You can use this to bring out more detail in a model.
sprite(1).member.model("my model")addModifier(#sds) sprite(1).member.model("my model").sds.subdivision = #adapative
See Also: enabled, depth, error, subdivision, addModifier, lod
See Chapter/Appendix: 39
searchCurrentFolder System Property
If TRUE, the current folder is searched when Director is looking for files.
the searchCurrentFolder = TRUE
See Also: searchPaths
searchPaths System Property
A list of pathnames that Director uses to look for files such as linked media.
the searchPaths = [the moviePath, the applicationPath, "c:\mystuff\"]
See Also: searchCurrentFolder
seconds Date & Time Property
A property of a date object. When the date object is taken from the systemDate, it returns the number of seconds since the beginning of that day. Also works for the modifiedDate and the creationDate of members.
d = the systemDate put d date( 2000, 3, 22 ) put d.seconds 77475
See Also: day, month, year, date, time
See Chapter/Appendix: 21
selectedText Text Property
Returns a reference to the current selection in a text member.
if member("myText").selectedText = "test" then...
See Also: ref, selection, selStart, selEnd, hilite
See Chapter/Appendix: 16
selection Text, Field Property
For text members, returns a two-item list with the first and last character positions selected. Also, as a system property, returns the text of the current selection in a field member.
put member(674,2).selection [286, 292] put the selection "Some Text"
See Also: selStart, selEnd, hilite
See Chapter/Appendix: 16
selection Casts Property
Returns a list of selected items in a cast library. Useful for making developer tools.
put castLib(2).selection [[672, 673], [675, 675]]
See Chapter/Appendix: 26
selEnd Field Property
This system property returns the position of the last character selected if there is a selection in an editable field.
put the selEnd 6
See Also: selStart, selection, hilite
See Chapter/Appendix: 16
selStart Field Property
This system property returns the position of the first character selected if there is a selection in an editable field.
put the selStart 16
See Also: selEnd, selection, hilite
See Chapter/Appendix: 16
sendAllSprites Behaviors Command
Sends a message to all sprites. This message activates event handlers of the same name in behaviors attached to the sprites.
sendAllSprites(#myHandler,myParam)
See Also: sendSprite
See Chapter/Appendix: 14
sendEvent 3D, Misc Command
You can send events to models that have used the registerForEvent or registerScript commands to be aware of such events. You can make up the name of the event so long as it is the same name as what the models are expecting.
sprite(1).member.registerForEvent(#myEvent,#myEventHandler,0) sprite(1).member.sendEvent(#myEvent)
See Also: registerForEvent, registerScript
See Chapter/Appendix: 39
sendSprite Behaviors Command
Sends a message to a sprite. This message activates event handlers of the same name in behaviors attached to the sprite.
sendXML Flash Handler
This handler is called when the Flash movie uses the "sendXML" ActionScript command. You get the sendXMLstring, window and postdata parameters that are set in the ActionScript code.
on sendXML me, sendXMLstring, window, postdata other code here end
See Chapter/Appendix: 20
Syntax Sample sendSprite(sprite 7,#myHandler, myParam)
See Also: sendAllSprite
See Chapter/Appendix: 14
serialNumber System Property
Returns the serial number of the Director application.
put the serialNumber "WDM800-00000-00000-00000"
See Also: userName
set Programming Command
Old syntax used to set variable values and property values. In Director 8, it isn't required but can still be used.
set myVariable = 7 set sprite(7).loc = point(40,50)
setAlpha Image Command
Sets the Alpha channel of a 32-bit image to either a number or an 8-bit grayscale alpha image object. Using a number between 0 and 255 sets a uniform Alpha channel for the image. The alpha image object enables you to create a more complex Alpha channel, and must be created by using the extractAlpha command.
myImage = member("picture").image myImage.setAlpha(128) myAlpha = member("alpha").extractAlpha() myImage = member("picture").image myImage.setAlpha(myAlpha)
See Also: extractAlpha, useAlpha
See Chapter/Appendix: 18
setaProp List Command
Sets a property value in a property list. If the property does not exist, it creates it instead.
list = [#a: 5, #b: 8, #c: 12] setaProp(list,#a,7) put list [#a: 7, #b: 8, #c: 12] list.setaProp(#b,9) put list [#a: 7, #b: 9, #c: 12] list.setaProp(#d,15) put list [#a: 7, #b: 9, #c: 12, #d: 15]
See Also: setProp, addProp, getaProp, getProp
See Chapter/Appendix: 13
setAt List Command
Sets an item in a list to a new value.
list = [4,7,8,9] setAt(list,2,3) put list [4, 3, 8, 9] list.setAt(3,1) put list [4, 3, 1, 9]
See Also: add, append, getAt
See Chapter/Appendix: 13
setCollisionCallback 3D, Collision Detection Command
This is a shortcut for registerScript. It allows you to quickly set the #collideWith event for that specific model.
sprite(1).member.model("my model").collision.setCollisionCallback(#myCollisionHandler,me)
See Also: registerScript, collision
See Chapter/Appendix: 39
setContents Text Command
This undocumented syntax enables you to replace the text in a text member.
member("myText").setContents(myNewString)
See Also: put into
See Chapter/Appendix: 16
setContentsAfter Text Command
This undocumented syntax enables you to place text after a chunk in a text member.
member("myText").char[2].setContentsAfter(myNewString)
See Also: put after
See Chapter/Appendix: 16
setContentsBefore Text Command
This undocumented syntax enables you to place text before a chunk in a text member.
member("myText").char[2].setContentsBefore(myNewString)
See Also: put before
setFlashProperty Flash Function
Acts like a setProperty action command in Flash and sets the property value from the Flash movie. Possible properties are #posX, #posY, #scaleX, #scaleY, #visible, #rotate, #alpha, #name, #width, #height, #target, #url, #dropTarget, #totalFrames, #currentFrame, and #lastframeLoaded. The first parameter is the target name, which you can leave as an empty string if you want to get a property at the global level. The second parameter is the property name. The third parameter is the new value.
sprite(7).setFlashProperty("bouncing ball",#posX,ballX)
See Also: getFlashProperty
See Chapter/Appendix: 20
setPi XEl Image Command
You can set a pi XEl in an image object to a color.
member("myBitmap").setPi XEl(x,y,rgb("FF0000")) member("myBitmap").setPi XEl(point(x,y),rgb("FF0000"))
See Also: getPi XEl
See Chapter/Appendix: draw, fill, copyPi XEls, getPi XEl, image
setPlayList Sound Command
Enables you to set the entire play list for a sound in one shot.
sound(1).setPlayList([[#member: member("intro")], [#member: member("mySound"),
#preloadTime: 7000, #startTime: 0, #endTime: 9000, #loopStartTime: 3000, #loopEndTime: 7000, #loopCount: 3]])
See Also: queue, play
See Chapter/Appendix: 17
setPref Shockwave Command
Sets a preference file's contents. Preference files are used in Shockwave to store "cookies" of information without creating a security risk.
setPref("clevermediaGame1",myPrefString)
See Also: getPref
See Chapter/Appendix: 22
setProp List Command
Sets a property value in a property list. If the property does not exist, it generates an error message.
list = [#a: 5, #b: 8, #c: 12] setProp(list,#a,7) put list [#a: 7, #b: 8, #c: 12] list.setProp(#b,9) put list [#a: 7, #b: 9, #c: 12]
See Also: setaProp, addProp, getProp
See Chapter/Appendix: 13
setScriptList Score Recording Command
Enables you to set the scripts assigned to a sprite. Must be used during author time, but not inside a Score recording session. Parameters must be encased inside quotation marks for some reason, as shown by the syntax sample.
sprite(1).setScriptList = [[member("myBehavior"), "[#myProp: 1]"]]
See Also: scriptList
See Chapter/Appendix: 26
setTrackEnabled Digital Video Command
Sets whether a video sprite's tracks are enabled.
setTrackEnabled(sprite 7, myTrack,TRUE)
See Also: trackEnabled
See Chapter/Appendix: 19
setVariable Flash Command
Sets a variable inside a Flash sprite.
sprite(7).setVariable("myVar",3)
See Also: getVariable, getFlashProperty
See Chapter/Appendix: 20
shader 3D, Shaders Object
This refers to a shader object in a member. Shaders can be created and then applied to surfaces of models. You can have a shader that reflects light using certain colors, or you can assign a texture to a shader to use a bitmap. Shaders can be #standard, #painter, #engraver, or #newsprint.
myShader = sprite(1).member.newShader("my shader",#standard) sprite(1).member.model("my model").shaderList[1] = myShader
See Also: newShader, texture, shaderList
See Chapter/Appendix: 39
shaderList 3D, Shaders Property
This list refers to the shader objects assigned to various faces in a model. You can use count to find out how many shaders are used by a model. Rather than using shaderList as a list, you can assign a shader to every surface of a model by using shaderList as a regular property.
n = sprite(1).member.model("my model").shaderList.count sprite(1).member.model("my model").shaderList[1] = myShader sprite(1).member.model("my model").shaderList = myShader
See Also: shader
See Chapter/Appendix: 39
shadowPercentage 3D, Shader Property
This defines the percentage of available colors to use for shadows with the toon modifier or painter shader.
sprite(1).member.model("my model").toon.shadowPercentage = 50
See Also: colorSteps, shadowStrength, toon
See Chapter/Appendix: 39
shadowStrength 3D, Shader Property
The brightness of shadows in the toon modifier or painter shader.
sprite(1).member.model("my model").toon.shadowStrength = 2
See Also: shadowPercentage, toon
See Chapter/Appendix: 39
shapeType Shape Property
Enables you to set the shape type to #rect, #roundRect, oval, or #line.
member("myShape").shapeType = #rect
See Also: filled
See Chapter/Appendix: 20
shiftDown Keyboard Property
Returns TRUE if the user is holding down the Shift key.
if the shiftDown then...
See Also: controlDown, optionDown, commandDown, keyPressed
See Chapter/Appendix: 16
shininess 3D, Shader Property
The percentage of a shader surface that shows highlights. The default setting is 30.
sprite(1).member.shader("my shader").shininess = 50
See Chapter/Appendix: 39
silhouettes 3D, Inker Property
Whether or not silhouette lines are drawn when using the toon modifier or inker.
sprite(1).member.model("my model").toon.silhouettes = TRUE
See Also: creases, creaseAngle, lineColor, boundary
See Chapter/Appendix: 39
short Date & Time Modifier
Modifies the date and time properties.
put the short date "3/22/00" put the short time "10:04 PM"
See Also: date, time
See Chapter/Appendix: 21
showGlobals Movie Command
Displays all the global variables and their values in the Message window.
showGlobals
See Also: clearGlobals, showLocals
showLocals Movie Command
When called from inside a handler, this command displays all the local variables and their values in the Message window.
showLocals
See Also: showGlobals
showProps Flash, Vector, Sound Command
Displays a list of the properties in a Flash, vector shape, or sound member in the Message window.
showProps member("myVector")
See Chapter/Appendix: 17, 20
showResFile Xtras Command
Shows the resources in an open Xtra. Works on only the Mac.
showResFile "FileIO"
See Also: openXlib, showXlib
See Chapter/Appendix: 25
showXLib Xtras Command
Displays a list of all open Xtras in the Message window.
showXlib
See Also: openXlib
See Chapter/Appendix: 25
shutDown System Command
On the Mac, this shuts down the computer. In Windows, it quits just the projector.
shutDown
See Also: quit, halt, restart
See Chapter/Appendix: 21
sin Math Function
Returns the sine of an angle. Angle must be in radians.
put sin(pi()/4) 0.7071
See Also: cos, tan, atan, PI
See Chapter/Appendix: 13
size Member Property
Returns the size of the member, in bytes.
if member("myMember").size > the freeBlock then...
See Chapter/Appendix: 21
sizeRange.start, sizeRange.end 3D, Particle Systems Property
You can define the starting and ending size of the particles. The default for each is 1.
sprite(1).member.modelResource("my model resource").sizeRange.start = 5 sprite(1).member.modelResource("my model resource").sizeRange.end = 1
See Also: blendRange, colorRange, numParticles
See Chapter/Appendix: 39
skew Sprite Property
Returns the skew angle of a sprite.
sprite(7).skew = 90
See Also: rotation, quad, flipV, flipH
See Chapter/Appendix: 18
smoothness 3D, Text Property
This property allows you to adjust the number of polygons used to create 3D text. The default is 5, but you can set it as low as 1 or high as 10.
sprite(1).member.smoothness = 3
See Also: extrude3D
See Chapter/Appendix: 39
sort List Command
Sorts a linear list by value, or a property list by property. After the list is sorted, the add and addProp commands insert the new item at the proper location.
list = [6, 5, 1, 9] sort list put list [1, 5, 6, 9] add list, 7 put list [1, 5, 6, 7, 9]
See Also: add, addProp
See Chapter/Appendix: 13
sound Linked Movies, Digital Video, Flash Property
If TRUE, the member's sound is enabled. Otherwise, it is silent.
member("myVideo").sound = FALSE
See Chapter/Appendix: 24, 19, 20
sound Sound Object
Defines a sound object, which corresponds directly to a Sound channel (1 to 8). You can queue sound members into a sound, play the sound, and perform a number of other operations on a playing sound.
sound(1).queue([#member: member("mySound), #loopCount: 3]) sound(1).play()
See Also: queue, play, breakLoop, pause, rewind
See Chapter/Appendix: 19, 20, 24
sound fadeIn Sound Command
Fades in a sound in a channel for a specific number of ticks. Made obsolete by the fadeIn command.
sound fadeIn 1, 60
See Also: fadeIn, fadeOut, fadeTo
See Chapter/Appendix: 17
sound fadeOut Sound Command
Fades out a sound in a channel for a specific number of ticks. Made obsolete by the fadeOut command.
sound fadeOut 1, 60
See Also: fadeIn, fadeOut, fadeTo
See Chapter/Appendix: 17
sound playFile Sound Command
Plays an external sound file in a specific Sound channel. Leave off the second parameter to have it play back in the first available channel.
sound playFile myFile, 1
See Also: sound stop, puppetSound, sound, play
See Chapter/Appendix: 17
sound stop Sound Command
Stops a sound playing in a specific Sound channel.
sound stop 1
See Also: sound playFile, puppetSound
See Chapter/Appendix: 17
soundBusy Sound Function
Tests to see whether a Sound channel is currently playing a sound. Made obsolete by the isBusy property.
if soundBusy(1) then...
See Also: isBusy
See Chapter/Appendix: 17
soundChannel Shockwave Audio Property
Specifies the Sound channel used by the Shockwave audio member. If the value is 0, the first available channel is used.
member("mySWA").soundChannel = 0
See Chapter/Appendix: 17
soundDevice Sound Property
This system property determines which computer driver is used to play and mix sound. In Windows you have a choice: MacroMix, DirectSound, or QT3Mix. Always set this to DirectSound, which mi XEs better, or QT3Mix, which requires QuickTime 3. If the user doesn't have QuickTime or DirectSound, MacroMix is used instead.
if getOne(the soundDeviceList,"DirectSound") then the soundDevice = "DirectSound" end if
See Also: soundDeviceList
See Chapter/Appendix: 17
soundDeviceList Sound Property
Returns a list of all available sound drivers. If a Windows user has DirectX and QuickTime 3, it should return ["MacroMix", "DirectSound", "QT3Mix"].
put the soundDeviceList
See Also: soundDevice
See Chapter/Appendix: 17
soundEnabled Sound Property
This system property can be set to FALSE to mute all sound.
the soundEnabled = FALSE
See Also: volume, soundLevel
See Chapter/Appendix: 17
soundKeepDevice Sound Property
If TRUE, which is the default, the movie keeps control of the computer's sound device to enable smoother playback of sounds. Setting it to FALSE may help some Windows computers play sounds from other applications while the movie is running.
the soundKeepDevice = TRUE
See Also: soundDevice
See Chapter/Appendix: 17
soundLevel Sound Property
This system property can have a range of 0 to 7 and controls the volume for the entire computer. However, in practice, many Windows machines do not respond to this property.
the soundLevel = 5
See Also: volume, soundEnabled
See Chapter/Appendix: 17
soundMixMedia Flash Property
When the Windows-only property is TRUE, Flash member sounds are mi XEd with other movie sounds. This could produce slightly different results than what you hear with Flash alone. If set to FALSE, Flash sound might improve, but you won't be able to play other movie sounds at the same time.
the soundMixMedia = TRUE
See Chapter/Appendix: 20
source 3D, Camera Property
You can set the texture used by a backdrop or overlay.
sprite(1).camera.backdrop[1].source = myTexture
See Also: backdrop, overlay
See Chapter/Appendix: 39
sourceRect MIAW Property
The original Stage rect of a movie. This is the way it's set in the property inspector and is independent of any movement or stretching of the Stage window in the authoring environment. It is where the movie will appear when played in a projector, or when playing as a MIAW.
myRect = (the stage).sourceRect
See Also: drawRect, rect, the stage
See Chapter/Appendix: 21
SPACE Strings Constant
The equivalent to a space character: " " or numToChar(32).
myString = "Hello"&SPACE&"World." put myString "Hello World."
See Also: COMMA, QUOTE, TAB, RETURN
See Chapter/Appendix: 16
specular 3D, Lights Property
Whether or not the light creates highlights on surfaces.
sprite(1).member.light("my light").specular = TRUE
See Also: shininess, specularLightMap
See Chapter/Appendix: 39
specular 3D, Shader Property
The color of the highlight on a shader.
sprite(1).member.shader("my shader").specular = rgb("FF0000")
See Also: shininess, specularColor
See Chapter/Appendix: 39
specularColor 3D, Shader Property
The specular setting for the first shader in a member.
sprite(1).member.specularColor = rgb("FF0000")
See Also: specular
See Chapter/Appendix: 39
specularLightMap 3D, Shader Property
The texture to be used to render the highlights on a shader.
sprite(1).member.shader("my shader").specularLightMap = myTexture
See Also: specular, diffuseLightMap
See Chapter/Appendix: 39
spotAngle 3D, Light Property
The angle of the cone of light coming from a #spot light.
sprite(1).member.light("my light").spotAngle = 15
See Also: newLight, spotDecay
See Chapter/Appendix: 39
spotDecay 3D, Light Property
Whether or not the intensity of a #spot light decreases as the ligh gets further from the light source. The default is FALSE.
sprite(1).member.light("my light").spotDecay = TRUE
See Also: spotAngle, newLight
See Chapter/Appendix: 39
sprite Sprite Object
Defines a sprite object. Sprites can be referenced only by number, but you can then set variables to represent them.
mySprite = sprite(7) mySprite.loc = point(50,60)
See Also: member, spriteNum
spriteNum Behaviors Property
The sprite number to which a behavior is attached.
if me.spriteNum = 7 then...
See Also: sprite, number
See Chapter/Appendix: 15
spriteSpaceToWorldSpace 3D, Misc Function
This function takes a screen location from the upper left corner of the 3D sprite and converts it to a point in 3D space. This point will be on the camera's projection plan.
loc = sprite(1).member.spriteSpaceToWorldSpace(point(100,100))
See Also: worldSpaceToSpriteSpace
See Chapter/Appendix: 39
sqrt Math Function
Returns the square root of a number.
put sqrt(4) 2 put sqrt(4.0) 2.0000
See Also: power, floatPrecision
See Chapter/Appendix: 13
stage Movie Property
Refers to the Stage itself. You can use it with the tell command, or with the image property.
tell the stage to... myRect = (the stage).rect myImage = (the stage).image
See Also: tell, image
See Chapter/Appendix: 18
stageBottom Movie Property
The vertical position of the bottom of the Stage.
y = the stageBottom
See Also: stageLeft, stageRight, stageTop
stageColor Movie Property
The color of the Stage. Use the palette index number. Made obsolete by the use of bgColor on the Stage.
put the stageColor 18 put (the stage).bgColor rgb( 255, 102, 255 )
See Also: bgColor
stageLeft Movie Property
The horizontal position of the left of the Stage.
x = the stageLeft
See Also: stageBottom, stageRight, stageTop
stageRight Movie Property
The horizontal position of the right of the Stage.
x = the stageRight
See Also: stageBottom, stageLeft, stageTop
stageToFlash Flash, Vector Function
Returns the coordinates in a Flash sprite that correspond to a location on the Stage.
myLoc = stageToFlash(sprite 7, the mouseLoc)
See Also: flashToStage
See Chapter/Appendix: 20
stageTop Movie Property
The vertical position of the top of the Stage.
y = the stageTop
See Also: stageBottom, stageLeft, stageRight
startAngle 3D, Primitives Property
Together with endAngle, this indicates the amount of a sphere or cylinder primitive to draw.
sprite(1).member.modelResource("my sphere resource").startAngle = 180
See Also: endAngle
See Chapter/Appendix: 39
startFrame Sprite Property
Returns the first frame of a sprite span.
f = sprite(7).startFrame
See Also: endFrame
startMovie Movie Event Handler
This handler runs just after the first frame of the movie is drawn.
on startMovie gMoveGlobal = 3 end
See Also: prepareMovie, stopMovie
See Chapter/Appendix: 13
starts Strings Function
This function compares two strings and returns TRUE if the second is at the very beginning of the first.
if myString starts myOtherString then...
See Also: contains, offset
See Chapter/Appendix: 16
startTime Digital Video Property
Enables you to set the starting time for a digital video sprite.
sprite(7).startTime = 60
See Also: stopTime
See Chapter/Appendix: 19
startTimer Date & Time Command
Resets the timer system property to 0.
startTimer
See Also: timer
See Chapter/Appendix: 21
state Flash, Shockwave Audio, 3D Property
Returns the state of the Shockwave audio member or Flash member. Values for Shockwave Audio are 0 = streaming stopped, 1 = reloading, 2 = preloading done, 3 = playing, 4 = paused, 5 = done streaming, 9 = error, 10 = insufficient CPU. Values for Flash are 0 = not in memory, 1 = header loading, 2 = header loaded, 3 = media loading, 4 = finished loading, -1 = error. Values for 3D members are 0 = not in memory, 1 = loading begun, 2 = header loaded, 3 = media being loaded, 4 = loading complete, -1 = error.
if member("mySWA").state = 3 then...
See Also: clearError, getError
See Chapter/Appendix: 17, 20
static Flash Property
If set to FALSE, the Flash member redraws only if the sprite moves or changes size. Used only for static Flash members.
member("myFlash").static = TRUE
See Chapter/Appendix: 20
staticQuality QTVR Property
The quality of a panoramic image when it isn't moving. Possible values are #minQuality, #maxQuality, and #normalQuality.
sprite(7).staticQuality = #maxQuality
See Also: motionQuality
See Chapter/Appendix: 20
status Sound Property
Returns a value that tells you the status of a sound object. Values are 0 = idle, 1 = loading, 2 = queued, 3 = playing, and 4 = error.
if sound(1).status = 3 then...
See Also: isBusy, sound
See Chapter/Appendix: 17
stepFrame OOP Event Handler
Any script objects added to the actorList are sent this message once per frame.
on stepFrame me myProperty = myProperty + 1 end
See Also: actorList
See Chapter/Appendix: 23
stillDown Mouse Property
Returns TRUE inside a mouseDown handler if the mouse is still down, and has not been lifted since the mouse down action that called the handler.
on mouseDown me repeat while the StillDown sprite(7).loc = the mouseLoc end repeat end
See Also: mouseDownstop
Flash Command
Stops a Flash sprite from animating.
stop sprite(7)
See Also: hold, rewind, play
See Chapter/Appendix: 20
stop Sound Command
Stops the sound object and advances to the next queued sound, if any. A play command resumes the sound at that next queued sound.
sound(1).stop()
See Also: play, sound, pause, fadeOut
See Chapter/Appendix: 17
stop member Shockwave Audio Command
Stops a Shockwave audio member that is playing.
stop member("mySWA")
See Also: play member, pause member
See Chapter/Appendix: 17
stopEvent Behaviors Command
Prevents the current event message from being sent to another behavior attached to a sprite.
if myCondition then x = 3 stopEvent end if
See Also: pass
stopMovie Movie Event Handler
This handler runs when a movie is stopped or ends.
on stopMovie member("myText").text = "" end
See Also: startMovie, endSprite
See Chapter/Appendix: 13
stopTime Digital Video Property
Enables you to set the end time for a digital video sprite.
sprite(7).stopTime = 60
See Also: startTime
See Chapter/Appendix: 19
stream Flash Command
Streams in a number of bytes of a Flash member.
stream(member("myFlash"),10240)
See Chapter/Appendix: 20
streamMode Flash Property
Enables you to stream flash movies in three different modes: #frame (a little each frame), #idle (during idle time), or #manual (must use the stream command).
member("myFlash").streamMode = #manual
See Also: stream
See Chapter/Appendix: 20
streamName Shockwave Audio Property
The Internet location of a streaming Shockwave audio member.
member("mySWA").streamName = "mysound.swa"
See Also: url, fileName
See Chapter/Appendix: 17
streamSize Flash, 3D Property
The total number of bytes in a streaming Flash member's file.
if member("myFlash").streamSize > 50000 then...
See Also: stream
streamStatus Network Event Handler
Called periodically while a member is streaming and will be sent information about the status of the streaming.
on streamStatus URL, state, bytesSoFar, bytesTotal, error n = integer(100.0*float(bytesSoFar)/float(bytesTotal)) member("status").text = string(n)&"%" end
See Also: getStreamStatus, tellStreamStatus
See Chapter/Appendix: 22
string Strings Function
Takes a value such as a list, number, or object and returns a string.
n = 1 put string(n) "1" n = 45.74 put string(n) "45.7400" l = [1, 2, 3] put string(l) "[1, 2, 3]"
See Also: integer, float, value, numToChar
See Chapter/Appendix: 16
stringP Strings Function
Returns TRUE if the value is a string.
n = 1 put stringP(n) 0 n = "1" put stringP(n) 1
See Also: integerP, floatP, listP
See Chapter/Appendix: 16
strokeColor Vector Property
The color, as an rgb, of the vector shape's line.
member("myVector").strokeColor = rgb(255,0,0)
See Also: strokeColor, fillColor, bgColor
See Chapter/Appendix: 20
strokeWidth Vector Property
The width of the vector shape's line.
member("myVector").strokeWidth = 2
See Also: strokeColor, closed
See Chapter/Appendix: 33
style 3D, Shader Property
This property of a toon modifier and painter shader can be set to #toon, #gradient or #blackAndWhite. The difference between #toon and #gradient is that the later provides smoother transitions between colors.
sprite(1).member.model("my model").toon.style = #gradient
See Also: colorSteps
See Chapter/Appendix: 39
subdivision 3D, Subdivision Surfaces Property
This determines whether the model is uniformly modified by the sds modifier (#uniform) or whether only modifications happen in areas with significant change (#adaptive).
sprite(1).member.model("my model").sds.subdivision = #adaptive
See Also: sds, error, enabled, depth, tension
See Chapter/Appendix: 39
substituteFont Text Command
Replaces one font with another in all occurrences of that font in a text member.
member("text").substituteFont("Courier","Courier New")
See Also: recordFont, missingFonts
See Chapter/Appendix: 16
swing QTVR Command
Moves a QTVR panoramic to a new position.
swing(sprite(7),myPan,myTilt,myFieldOfView,mySpeedToSwing)
See Also: pan
switchColorDepth System Property
If TRUE, the projector attempts to switch the monitor's color depth to match the depth of the movie.
the switchColorDepth = FALSE
See Also: colorDepth
See Chapter/Appendix: 20
symbol Symbols Function
Converts a string to a symbol.
put symbol("hello") #hello
See Also: value, string
symbolP Symbols Function
Returns TRUE if the value is a symbol.
n = "hello" put symbolP(n) 0 n = 7 put symbolP(n) 0 n = #hello put symbolP(n) 1
See Also: ilk, integerP, stringP, voidP, listP
systemDate Date & Time Property
This system property returns the computer's date using the date object format.
put the systemDate date( 2000, 3, 23 )
See Also: date
See Chapter/Appendix: 21
TAB Strings Constant
Equivalent to the tab character, which is numToChar(8).
myString = "This and"&TAB&"That" put myString "This and That"
See Also: RETURN, QUOTE, SPACE, &&
See Chapter/Appendix: 16
tabCount Text Property
Returns the number of tabs in the ruler of a text member. You can specify the exact chunk within the text member if you want.
if member("myText").tabCount > 0 then...
See Also: tabs
See Chapter/Appendix: 16
tabs Text Property
Returns a property list with information about the tab stops in a text member or chunk of a text member.
put member("text").tabs [[#type: #left, #position: 45], [#type: #right, #position: 112],
[#type: #center, #position: 166], [#type: #Decimal, #position: 189]]
See Also: tabCount
See Chapter/Appendix: 16
tan Math Function
Returns the tangent of an angle. Angle must be in radians.
put tan(pi()/4) 1.0000
See Also: cos, sin, atan, pi
See Chapter/Appendix: 13
target Timeout Property
You can use this property to assign a target script object that the timeout uses to look for the handler that it is meant to call.
timeout("myTimeout").target = gMyScriptObject
See Also: timeout, timeoutHandler
See Chapter/Appendix: 21
tell MIAW Command
Sends a message or series of commands to a MIAW or the Stage. Can use to to send a single line of code, or end tell to send many lines.
tell window("myMIAW") to... tell window("myMIAW") go to frame 7 end tell
See Also: the Stage, window
See Chapter/Appendix: 24
tellStreamStatus Network Function
If you use TRUE, streamStatus messages are sent to the on streamStatus handler.
tellStreamStatus(TRUE)
See Also: streamStatus, getStreamStatus
See Chapter/Appendix: 22
tellTarget Flash Command
After issuing a tellTarget command, all communication with the Flash movie will be directed at the movie clip specified. Issue a endTellTarget to refer, once again, to the main timeline in the Flash movie.
sprite(1).tellTarget("\myMovieClip") sprite(1).play() sprite(1).endTellTarget()
See Also: endTellTarget
See Chapter/Appendix: 20
text Text, Field, Button Property
Returns the text in a text-based member as plain text. You can set it, too.
member("myText").text = "Hello World."
See Also: rtf, html
See Chapter/Appendix: 16
texture 3D, Textures Object
The texture object is used to bring a bitmap image into a 3D world. Once you define a texture object, you can apply it to a shader, backdrop or overlay.
myTexture = sprite(1).member.newTexture("my texture",#fromCastMember,member("my bitmap"))
See Also: shader, backdrop, overlay, newTexture, deleteTexture
See Chapter/Appendix: 30
texture 3D, Shader Property
This property of a shader defines which texture, if any, is used by the shader. If the texture is set to VOID, then no texture is used for the shader.
sprite(1).member.shader("my shader").texture = myTexture
See Also: newTexture
See Chapter/Appendix: 39
textureCoordinateList, textureCoordinates 3D, Textures Property
This is a long list of lists that defines how a texture is mapped on to a surface. The textureCoordinates then refers to locations on the surface that map to the texture locations.
textureLayer 3D, Mesh Deform Property
This property allows you to refer to individual texture layers in a mesh deformed model. You can also use the add command to add new texture layers.
n = sprite(1).member.model("my model").meshDeform.textureLayer.count
See Also: meshDeform, add
See Chapter/Appendix: 39
textureMember 3D, Textures Property
This property of a 3D member defines which bitmap will be used for the default texture for the member.
sprite(1).member.textureMember = member("my bitmap")
See Also: textureType
See Chapter/Appendix: 39
textureMode, textureModeList 3D, Textures Property
The textureMode defines how the first texture is mapped on to the surface of a model. The possible values are #none, #wrapPlanar, #wrapCylindrical, #wrapSpherical, #reflection, #diffuseLight, #specularLight. To access other textures assigned to the model, use the textureModeList.
sprite(1).member.model("my model").shader.textureMode = #wrapPlanar
See Chapter/Appendix: 39
textureRenderFormat See getRendererServices
textureRepeat, textureRepeatList 3D, Shader Property
Set this property of a shader to TRUE to have the texture repeat across the surface as necessary instead of scale to the size of the surface. Use the textureRepeatList when there is more than one texture in a shader. Doesn't work in software renderer mode.
sprite(1).member.shader("my shader").textureRepeat = TRUE
See Also: textureTransform
See Chapter/Appendix: 39
textureTransform, textureTransformList 3D, Shader Property
The textureTransform property gives you access to position, orientation and scaling properties of a texture. If a shader has more than one texture, use the textureTransformList to access the transform of each texture.
sprite(1).member.shader("my shader").textureTransform.rotation = vector(90,0,0)
See Also: textureRepeat
See Chapter/Appendix: 39
textureType 3D, Textures Property
This the property of a 3D member that defines the default texture for the member. Possible values are #none, #default or #member. This corresponds to the option you see in the property inspector.
sprite(1).member.textureType = #none
See Also: textureMember
See Chapter/Appendix: 39
the Programming Misc
Used to denote a property.
put the systemDate x = the environment the name of menuItem 7 of menu 3 = "Hey"
then Programming Structure
Checks a statement to see whether it is TRUE. It e XEcutes line(s) of code if so. The else if and else statements can be used to further modify the statement.
if (a = b) then run these lines else if (c = d) then run these lines else run these lines end if
See Also: case
See Chapter/Appendix: 13
thumbnail Member Property
The picture image used as a thumbnail in the Cast window.
member("myMember").thumbnail = myPicture
See Also: picture
ticks Date & Time Property
This system property returns the number of ticks (1/60 of a second) since the computer started.
put the ticks 100452
See Also: milliseconds, timer
See Chapter/Appendix: 21
tilt QTVR Property
The current tilt, in degrees, of a QTVR movie.
sprite(7).tilt = 30
See Also: pan, fieldOfView
time System Property
Reads the user's computer clock and returns the time in various formats. You can use abbr, long, and short as modifiers. The actual result depends on the computer's time settings.
put the time "8:05 PM" put the long time "8:05:13 PM"
See Also: abbr, long, short, date
See Chapter/Appendix: 21 time
Timeout Property
Returns the time, in milliseconds, when the timeout object will trigger next. This corresponds to the system timer the milliseconds.
if timeout("myTimeOut").timer > the milliseconds + 60000 then...
See Also: timeout, period, milliseconds
See Chapter/Appendix: 21
timeout Timeout Event Handler
The handler is called when the mouse or keyboard has not been used by the user for timeOutLength.
on timeout go to frame 1 end
See Also: timeOutLength, timeout
See Chapter/Appendix: 21
timeout Timeout Object
Defines a timeout object. Can be used to create a new one.
newTimeout = timeout("myTimeout")
See Also: forget, new, timeoutList
See Chapter/Appendix: 21
timeoutHandler Timeout Property
The symbol of the handler that is called when a timeout triggers.
timeout("myTimeout").timeoutHandler = #myHandler
See Also: timeout, timeoutLength, timeoutList
See Chapter/Appendix: 21
timeoutKeydown Timeout Property
Determines whether key presses will reset timeOutLapsed.
the timeoutKeyDown = TRUE
See Also: timeoutLapsed, timeoutLength, timeoutMouse, timeoutPlay, timeoutScript
See Chapter/Appendix: 21
timeoutLapsed Timeout Property
The number of ticks that have gone by since the last user action.
if the timeoutLapsed > 600 then...
See Also: timeoutLapsed, timeoutKeyDown, timeoutMouse, timeoutPlay, timeoutScript
See Chapter/Appendix: 21
timeoutLength Timeout Property
The amount of time, in ticks, that the timeoutLapsed must reach to trigger a timeout event.
the timeoutLength = 3*60*60
See Also: timeoutLapsed, timeoutKeyDown, timeoutMouse, timeoutPlay, timeoutScript
See Chapter/Appendix: 21
timeoutList Timeout Property
Returns a list with all the timeout objects.
put (the timeoutList)
See Also: timeout
See Chapter/Appendix: 21
timeoutMouse Timeout Property
Determines whether mouse clicks will reset timeOutLapsed.
the timeoutMouse = TRUE
See Also: timeoutLapsed, timeoutKeyDown, timeoutLength, timeoutPlay, timeoutScript
See Chapter/Appendix: 21
timeoutPlay Timeout Property
Determines whether play commands will reset timeOutLapsed.
the timeoutPlay = TRUE
See Also: timeoutLapsed, timeoutKeyDown, timeoutLength, timeoutMouse, timeoutScript
See Chapter/Appendix: 21
timeoutScript Timeout Property
The alternative handler to on timeout that gets called when a timeout event occurs. Set to EMPTY to have on timeout called.
the timeoutScript = "myTimeoutHandler"
See Also: timeoutLapsed, timeoutKeyDown, timeoutLength, timeoutMouse, timeoutPlay
See Chapter/Appendix: 21
timer Date & Time Property
This system property returns the number of ticks since the computer started or since the last startTimer command.
startTimer put the timer 169
See Also: startTimer, ticks
See Chapter/Appendix: 21
timeScale Digital Video Property
Returns the unit per second measurement of time for a digital video member. A typical value is 600, meaning 1/600 of a second.
if member("myVideo").timeScale < 600 then...
See Also: digitalVideoTimeScale
See Chapter/Appendix: 21
title MIAW Property
Sets the text to appear in the title bar of a MIAW.
window("myMIAW").title = "My MIAW"
See Also: titleVisible, name
See Chapter/Appendix: 24
titleVisible MIAW Property
Set to TRUE if you want the title bar visible for a MIAW. Not all window types support a title bar.
window("myMIAW").titleVisible = TRUE
See Also: title
See Chapter/Appendix: 24
to Programming Expression
Used in old set syntax as a substitute for = and in old chunk statement syntax. Also used in repeat loop statements.
set t to "abcdef" put char 2 to 4 of t "bcd" repeat with i = 1 to 7 ... end repeat
See Also: =, repeat
toon 3D, Modifier Object
This modifier causes the model to be drawn with only a few colors, thus making it look like a cartoon.
sprite(1).member.model("my model").addModifier(#toon)
See Also: style, colorSteps, shadowPercentage, highlightPercentage, shadowStrength, highlightStrength, lineColor, creases, creaseAngle, silhouettes, boundary, lineOffset, useLineOffset, addModifier, inker
See Chapter/Appendix: 39
toon1, toon2 3D, Modifer Object
These undocumented modifiers are related to the toon modifier. The toon modifier behaves as if the inker modifer and the painter shader have been used together. If you use toon1, then it appears as if the inker and the engraver shader are used. toon2 appears like the inker and the newsprint shader have been used. Use these modifiers at your own risk since they are undocumented and unsupported.
top Sprite, Misc Property
The top vertical position of the sprite. Corresponds to the top of the rect of a sprite. Also a property of rect objects.
put sprite(1).rect rect(102, 143, 277, 233) put sprite(1).top 143 put sprite(1).rect.top 143
See Also: bottom, left, right, height, rect
See Chapter/Appendix: 18
bottom 3D, Primitives Property
Whether the top side of a 3D box primitive is present or not.
sprite(1).member.modelResource("my box resource").top = FALSE
See Also: back, front, left, right, bottom, topCap, bottomCap, newModelResource
See Chapter/Appendix: 39
topCap 3D, Primitives Property
Whether the top side of a 3D cylinder primitive is present or not.
sprite(1).member.modelResource("my box resource").topCap = FALSE
See Also: back, front, left, right, top, bottom, topCap, newModelResource
topRadius 3D, Primitives Property
The radius of the bottom circle in a cylinder primitive.
sprite(1).member.modelResource("my cylinder resource").topRadius = 10
See Also: bottomRadius, radius
trace Debug Property
If set to TRUE, trace information is sent to the Message window as Lingo e XEcutes.
the trace = TRUE
See Also: traceLoad, traceLogFile
See Chapter/Appendix: 33
traceLoad Debug Property
Enables information about members to be displayed in the Message window as the members load. Possible values are 0 (no information), 1 (names only), or 2 (names, frame number, movie name, file seek offset).
the traceLoad = 2
See Also: trace, traceLogFile
See Chapter/Appendix: 33
traceLogFile Debug Property
If set to a filename, messages sent to the Message window are also sent to a file. Set to an empty string to close.
the traceLogFile = "trace.txt"
See Also: trace, traceLoad
See Chapter/Appendix: 33
trackCount Digital Video Function
Returns the number of tracks in a video sprite or member.
if trackCount(sprite(7)) > 1 then...
See Also: trackType
See Chapter/Appendix: 19
trackEnabled Digital Video Function
Returns TRUE if the track is enabled.
if trackEnabled(sprite(7),trackNum) then...
See Also: setTrackEnabled
See Chapter/Appendix: 19
trackNextKeyTime, trackPreviousKeyTime Digital Video Function
Returns the time of the next or previous keyframe.
if trackNextKeyTime(sprite(7),trackNum) > 1000 then...
See Also: trackType
See Chapter/Appendix: 19
trackNextSampleTime, trackPreviousSampleTime Digital Video Function
Returns the time of the next or previous piece of data in a track.
if trackNextSampleTime(sprite(7),trackNum) > 1000 then...
See Also: trackType
See Chapter/Appendix: 19
trackStartTime, trackStopTime Digital Video Function
Returns the starting or ending time of a track in a video sprite or member.
if trackStartTime(sprite(7),trackNum) > 1000 then...
See Also: trackType
See Chapter/Appendix: 19
trackText Digital Video Function
Returns a string with the text of a digital video text track.
myText = trackText(sprite(7),trackNum)
See Also: trackType
See Chapter/Appendix: 19
trackType Digital Video Function
Returns the type, whether #video, #sound, #text, or #music, of a video sprite or member track.
if trackType(sprite(7),trackNum) = #music then...
See Also: trackEnabled, trackCount
See Chapter/Appendix: 19
trails Sprite Property
Indicates whether the sprite leaves a trail behind as it is moved around the Stage.
sprite(7).trails = TRUE
See Also: moveableSprite
See Chapter/Appendix: 18
transform 3D, Math, Models Property, Object, Function
The transform of any 3D object represents the position, orientation and scale of the object. You can access the position, rotation and scale properties or apply the translate, rotate or scale commands to a transform. There are also a variety of mathematical functions that work on transforms. If you use transform as a function, you can get a blank transform to use in calculations.
sprite(1).member.model("my model").transform.position = vector(0,0,0)
See Also: position, rotation, scale, translate, rotate, preRotate, preTranslate, preScale, interpolateTo, identity
See Chapter/Appendix: 39transform
transitionType Transition Property
Returns the number of the transition in a member. This number corresponds to the codes for puppetTransition.
member("myTransition").transitionType = 34
See Also: puppetTransition
See Chapter/Appendix: D
translate 3D, Models Command
The translate command will move a model in a world by an amount specified in a vector. Alternatively, you could use three parameters representing the x, y, and z change. You can also apply translate to a transform.
sprite(1).member.model("my model").translate(30,0,0)
See Also: rotate, scale, transform
See Chapter/Appendix: 39
translation Digital Video Property
The location offset of a QuickTime video sprite or member from the center or upper-left corner, depending on the center property.
sprite(7).translation = [x,y]
See Also: center
See Chapter/Appendix: 19
transparent 3D, Shader Property
If set to TRUE, the shader will use any alpha channel in the texture to make the shader semi-transparent.
sprite(1).member.shader("my shader").transparent = TRUE
See Also: blend, blendFactor
See Chapter/Appendix: 39
triggerCallback QTVR Property
You can set this to the name of a handler to have that handler called when the user clicks a hotspot.
sprite(7).triggerCallback = "myTriggerHandler"
trimWhiteSpace Image Command
Removes any white pi XEls from outside the minimum rectangular area of an image.
myImage = member("picture").image myImage.trimWhiteSpace()
See Also: crop
See Chapter/Appendix: 18
TRUE Logic Constant
Logical true. Use in if, repeat, case, or other logic statements. Equivalent to 1.
if myCondition = TRUE then...
See Also: if, repeat, case, FALSE
See Chapter/Appendix: 13
tunnelDepth 3D, Text Property
For 3D text members, this is the distance from the front to the back of the letters. The default is 50, and you can set it as low as 1, or as high as 100.
sprite(1).member.tunnelDepth = 20
See Also: extrude3D
See Chapter/Appendix: 4
tweened Score Recording Property
If FALSE, all frames in a sprite are considered keyframes. This is only for Score recording.
sprite(7).tweened = TRUE
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
tweenMode 3D, Particle System Property
If set to the default #age, particles will move from the colorRange.start to colorRange.end over the course of their lifetime. If you change this to #velocity, then the particles will change color consistently, according to their varying speeds.
sprite(1).member.modelResource("my particle resource").tweenMode = #velocity
See Also: colorRange
See Chapter/Appendix: 39
type Member Property
Returns the type of a member, such as #bitmap or #text. Appendix D, "Tables and Charts," contains a complete list of member types.
if member("myMember").type = #bitmap then...
See Chapter/Appendix: D
type Score Recording Property
Can be used during Score recording to clear a sprite by setting its type to 0.
sprite(7).type = 0
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
type 3D, Light Property
Lights can be of type #ambient, #directional, #point or #spot.
sprite(1).member.light("my light").type = #spot
See Also: newLight, spotAngle, attenuation
See Chapter/Appendix: 39
modelResource 3D, Models Property
A model resource's type can be a primitive type, like #sphere, #box, #cylinder or #plane, or can be a #mesh, #particle, or #extruder. This property can also be read as #fromFile if the model resource was created in an external 3D program.
See Also: newModelResource, newMesh, extrude3D
See Chapter/Appendix: 39
type 3D, Animtation Property
A motion can be of type #bonesPlayer or #keyframePlayer. If its type is #none, then no information exists inside the motion.
See Also: bonesPlayer, keyframePlayer
See Chapter/Appendix: 39
type 3D, Shader Property
A shader can have the type #standard, #newsprint, #painter or #engraver.
See Also: newShader
See Chapter/Appendix: 39
type 3D, Texture Property
Textures can be of type #fromCastmember, #fromImageObject, or #importedFromFile, depending on how it was created.
See Also: newTexture
See Chapter/Appendix: 39
union Math Function
Takes two rectangles and returns the smallest rectangle that contains them both.
newRect = union(rect(0,0,100,100),rect(50,50,150,150))
See Also: map, rect, inflate
unLoad Memory Command
Removes from memory the cast members used in a frame, range of frames, or all frames.
unLoad 5, 9 unLoad
See Also: preLoad, unLoadMember
See Chapter/Appendix: 21
unloadMember Memory Command
Removes a member or range of members from memory.
unLoadMember "myMember"
See Also: preLoadMember, unLoad
See Chapter/Appendix: 21
unloadMovie Memory Command
Removes from memory the members loaded with the preLoadMovie command.
unloadMovie "myNewMovie"
See Also: preLoadMovie
See Chapter/Appendix: 21
unregisterAllEvents 3D, Collision Detection Command
This command will erase all previous registerForEvent calls.
sprite(1).member.unregisterALlEvents()
See Also: registerForEvent
See Chapter/Appendix: 39
update 3D, Models Command
This command will update a model's position even before it is time to render it in the new location. This means that all of its Lingo properties will reflect its next location, not the current one.
sprite(1).member.model("my model").update()
See Chapter/Appendix: 39
updateFrame Score Recording Command
Makes the changes to the current frame permanent, and moves forward one frame to continue Score recording.
beginRecording sprite(7).locH = 100 updateFrame endRecording
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
updateLock Score Recording Property
If this property is set to TRUE, Score recording does not show changes on the Stage as it works.
the updateLock = TRUE
See Also: beginRecording, updateFrame
See Chapter/Appendix: 26
updateMovieEnabled Movie Property
If TRUE, changes made to a movie are automatically saved when another movie is loaded.
the upodateMovieEnabled = TRUE
See Also: saveMovie
See Chapter/Appendix: 26
updateStage Movie Command
Puts any sprite changes into effect immediately, rather than waiting for the next frame to begin.
updateStage
url Shockwave Audio Property
The Internet location of a streaming Shockwave audio file.
member("mySWA").url = "http://clevermedia.com/swasample.swa/"
See Also: pathName, fileName
See Chapter/Appendix: 17
URLEncode Network Function
When given text, this function changes some characters to prepare the text to be sent over the Internet. When given a list, it converts the list to a format that looks like the format used by an HTML post.
myText = "I said: Hello World!" put URLEncode(myText) "I+said%3a+Hello+World!" myList = [#myProp: "Hello World."] put URLEncode(myList) "myProp=Hello+World."
See Also: getNetText, postNetText
See Chapter/Appendix: 22
useAlpha Bitmap, Image Property
If TRUE, 32-bit bitmaps use the Alpha channel information, if available. Also can be used on image objects.
member("myBitmap").useAlpha = TRUE
See Also: setAlpha, extractAlpha
See Chapter/Appendix: 18
useDiffuseWithTexture 3D, Shader Property
This is whether of not the diffuse light is used in conjunction with a texture in the shader.
sprite(1).member.model("my model").useDiffuseWIthTexture = TRUE
See Also: blendFunction, blendConstant
See Chapter/Appendix: 39
useFastQuads Sprite Property
If TRUE, sprites stretched by setting the quad property use a faster method of drawing. The object is not drawn quite correctly for 3D effects, however.
the useFastQuads = TRUE
See Also: quad
useFastQuads Sprite Property
When this system property is set to TRUE, sprites drawn with modified quad properties will use a different engine to draw to the Stage, resulting in less precise, but faster, rendering.
the useFastQuads = TRUE
See Also: quad
See Chapter/Appendix: 18
useHyperTextStyles Text Property
When TRUE, all hyperlinks in the member are blue and underlined. The cursor changes into a finger when over them.
member("myText").useHyperTextStyles = TRUE
See Also: hyperlink, antiAliased
See Chapter/Appendix: 16
userLineOffset 3D, Inker Property
Whether or not the lineOffset of a toon modifier or inker modifier is used.
sprite(1).member.model("my model").toon.useLineOffset = TRUE
See Also: lineOffset
See Chapter/Appendix: 39
userData 3D, Misc Property
This is a property list of data that may have been stored by the 3D graphics program that created the model. Alternatively, you can use addProp to add your own properties. This is just a convenient way to store information about a model but it is not used by Director unless you speficially handle the information somehow.
sprite(1).member.model("my model").userData.addProp(#myProperty,"Info")
userName System Property
Returns the username of the registered user of the Director application.
put the userName "Gary Rosenzweig"
See Also: serialNumber
value Strings, Misc Function
Interprets the string as a Lingo expression and returns its value. The value can even be a list.
myText = "5" put value(myText) 5 myText = "5+3" put value(myText) 8 myText = "[1,2,3]" put value(myText) [1, 2, 3]
See Also: integer, float, string, do
vector 3D, Models, Math Object
A vector is a three-part object that usually contains information relating to the position or orientation of a model or other object. Many of the 3D properties and functions use vectors to carry data. The x, y and z properties of a vector refer to each of the three elements, which are floating-point numbers.
v = vector(5,10,20)
See Also: transform
See Chapter/Appendix: 39
version System Property
A global variable that is always present. It contains the version of Director running or the version of Shockwave or the version of Director that created the projector.
put version "8.0"
See Also: the environment
See Chapter/Appendix: 21
vertex Vector Property
Enables you to refer to an individual vertex point.
member("myVector").vertex[1] = [#vertex: point(10,24)] put member("myVector").vertex.count() 7
See Also: vertexList
See Chapter/Appendix: 20
vertexList Vector Property
Returns, or enables you to set, the entire vertex list for a vector shape member.
member("myVector").vertexList = [[#vertex: point(0,0)], [#vertex: point(10,0)]]
See Also: vertex
See Chapter/Appendix: 20
vertexList 3D, Mesh Property
This is a property of both a mesh deform modifier and the model resource of type #mesh. This list contains all of the vertices in the model. In the case of a #mesh model, the vertices are then assigned to different corners of the model with the vertices property. For a mesh deform modifier, this is simplyh a list of all of the vertices that you can alter and thus alter the model's geometry.
sprite(1).member.model("my model").meshDeform.vertexList[1] = vector(10,0,0)
See Also: vertices, newMesh, face
See Chapter/Appendix: 39
vertices 3D, Mesh Property
A mesh model resource contains both a vertexList and faces. Each face is made up of three vertices. This list will assign each of these vertices, by number, to a corner of a face in the model resource. Corners in other faces can share the same vertex, and many usually will.
sprite(1).member.modelResource("my mesh resource").face[1].vertices = [1,2,3]
See Also: vertexList
See Chapter/Appendix: 39
video Digital Video Property
If set to FALSE, the video for a video member is not displayed. Sound and music are still heard.
member("myVideo").video = TRUE
See Also: sound
See Chapter/Appendix: 19
videoForWindowsPresent Digital Video Property
Returns TRUE if video for Windows is available on the machine.
if the videoForWindowsPresent then...
See Also: quickTimeVersion
See Chapter/Appendix: 19
viewH Flash, Vector Property
Enables you to shift a Flash or vector shape member from its origin.
member("myVector").viewH = 50
See Also: viewV, viewPoint, viewScale
See Chapter/Appendix: 20
viewPoint Flash, Vector Property
Enables you to shift a Flash or vector shape member from its origin.
member("myVector").view = point(50,50)
See Also: viewH, viewV, viewScale
See Chapter/Appendix: 20
viewScale Flash, Vector Property
Sets the scale amount for a Flash or vector shape member. You must not change this value if you are using the #autoSize scaleMode.
member("myVector").viewScale = 2.0
See Also: scaleMode
See Chapter/Appendix: 20
viewV Flash, Vector Property
Enables you to shift a Flash or vector shape member from its origin.
member("myVector").viewV = 50
See Also: viewH, viewPoint, viewScale
See Chapter/Appendix: 20
visible Sprite Property
Hides a sprite, and prevents mouse clicks from reaching it. Other events still occur.
sprite(7).visible = FALSE
See Also: blend
See Chapter/Appendix: 18
visible MIAW Property
Enables you to hide or show a MIAW.
window("myMIAW").visible = FALSE
See Chapter/Appendix: 24
visibility 3D, Models Property
The visibility property of a model can allow you to make the model invisible (#none), only draw the faces facing the camera (#front), draw the surfaces facing away from the camera (#back) or draw all of the surfaces(#both). The default is #front.
sprite(1).member.model("my model").visibility = #none
VOID Programming Constant
Enables you to set a variable to VOID, which is the equivalent of having no value.
myVariable = VOID
(d)See Also: voidP
voidP Programming Function
Returns TRUE if the value provided is VOID (has no value).
if voidP(myVariable) then...
See Also: VOID, objectP
volume Shockwave Audio, Sound, Digital Video Property
Enables you to set the volume of a Shockwave audio member, the volume of a Sound channel, or the volume of a digital video sprite. Possible values are from 0 to 255.
member("mySWA").volume = 255 sound(1).volume = 255 member("myVideo").volume = 255
See Also: soundLevel
See Chapter/Appendix: 17
warpMode QTVR Property
Can be set to #full, #partial, or #none to control QTVR warping.
sprite(7).warpMode = #partial
See Also: fieldOfView
while Programming Structure
Used with a loop. Needs to use a while to repeat until a condition is FALSE.
repeat while x < 6 ... end repeat
See Also: exit repeat, next repeat, with
See Chapter/Appendix: 13
width Sprite, Member Property
Returns the width of most members and sprites. Can also be used as a property of rect objects.
if sprite(7).width > 100 then... w = myRect.width
See Also: height, rect
See Chapter/Appendix: 18
width 3D, Primitives Property
The width of a box or cylinder primitive. This is also the property of a texture.
sprite(1).member.modelResource("my box").width = 15
See Also: newModelResource, height, length, radius
See Chapter/Appendix: 39
widthVertices 3D, Primitives Property
The number of vertices used to create the side of a box primitive. The more vertices, the more polygons. The more polygons, the better the light detail.
sprite(1).member.modelResource("my box").widthVertices = 8
See Also: heightVertices, lengthVertices
See Chapter/Appendix: 39
wind 3D, Particle Systems Property
The wind is a vector that specifies the force and direction of wind applied to each particle. You need to set the drag property to some value other than 0 for it to work.
sprite(1).member.modelResource("my particle system").wind = vector(10,0,0)
See Also: drag, gravity
See Chapter/Appendix: 39
window MIAW Object
Defines a MIAW object.
myMIAW = window("myMIAW")
See Also: open window, close window
See Chapter/Appendix: 24
windowList MIAW Property
This system property returns a list with all the windows present.
put the windowList
See Also: windowPresent
See Chapter/Appendix: 24
windowPresent MIAW Function
Tests a MIAW name to see whether it is present.
if windowPresent("myMIAW") then...
See Also: windowList
See Chapter/Appendix: 24
windowType MIAW Property
Returns a number that corresponds to the window type. See Appendix D for a list.
window("myMIAW").windowType = 1
See Chapter/Appendix: 24, D
with Programming Structure
Used to create a type of repeat loop. Needs to use a with to repeat through a series of numbers, a with...down to to repeat backward, or a with... in to loop through a list of values.
repeat with i = 1 to 10 ... end repeat repeat with i = 10 down to 1 ... end repeat repeat with I in [5,8,3] ... end repeat
See Also: exit repeat, next repeat, while
See Chapter/Appendix: 13
within Sprite Function
Determines whether the second sprite rectangle is totally within the first. Note the odd syntax.
if sprite 1 within 2 then...
See Also: intersects
See Chapter/Appendix: 18
word Strings Expression
Used to specify a single word or range of words in a string chunk. Words are separated by spaces or an invisible character such as a Return.
myText = "The quick brown fox" put myText.word[2] "quick" put myText.word[2..3] "quick brown"
See Also: char line, item, chars
See Chapter/Appendix: 16
wordWrap Field, Text Property
If TRUE, text automatically wraps in a field or text member.
member("myField").wordWrap = TRUE
See Chapter/Appendix: 16
worldPosition 3D, Models Property
This is an alternate way of getting and setting the position of a model. The worldPosition always refers to locations relative to the center of the world, regardless of what groupings have been applied.
sprite(1).member.model("my model").worldPosition = vector(0,0,0)
See Also: transform, position, getWorldTransform
See Chapter/Appendix: 39
worldSpaceToSpriteSpace 3D, MiscFunction
This function takes a world location and converts it to a sprite location relative to the upper left corner of the 3D sprite.
loc = sprite(1).member.worldSpaceToSpriteSpace(vector(0,0,0))
See Also: spriteSpaceToWorldSpace
See Chapter/Appendix: 39
worldTransform 3D, Bones Property
When used with the bones player modifier, this property allows you to get the transform of a bone relative to the world, rather than relative to the model.
wrapTransform, wrapTransformList 3D, Shader Property
This transform object defines how a wrapped texture will map on to a surface.
sprite(1).member.shader("my shader").wrapTransform.rotate(90,0,0)
See Also: textureMode
See Chapter/Appendix: 39
x 3D, Math Property
This is the first element in a vector.
v = vector(10,-50,120) put v.x 10.0000
See Also: vector, y, z
See Chapter/Appendix: 39
xAxis 3D, Math Property
You can use this property to examine a vector representing the x axis of a transform.
t = transform() t.rotate(45,45,45) put t.xAxis vector( 0.5000, 0.5000, -0.7071 )
See Also: yAxis, zAxis, transform
xtra Xtras Object
Enables you to define an Xtra as an object.
fileObj = new(xtra "FileIO")
See Also: new
See Chapter/Appendix: 25
xtraList Xtras Property
Returns a list with all the Xtras present.
put the xtraList
See Also: showXlib, movieXtraList
See Chapter/Appendix: 25
y 3D, Math Property
This is the second element in a vector.
v = vector(10,-50,120) put v.y -50.0000
See Also: vector, x, z
See Chapter/Appendix: 39
yAxis 3D, Math Property
You can use this property to examine a vector representing the y axis of a transform.
t = transform() t.rotate(45,45,45) put t.yAxis vector( -0.1464, 0.8536, 0.5000 )
See Also: xAxis, zAxis, transform
year (d)Topic Date & Time Property
A property of a date object.
d = date(2000,3,17) put d.year 2000
See Also: date, month, day, seconds, systemDate
See Chapter/Appendix: 21
yon 3D, Camera Property
The yon is the distance from the camera where objects are no longer rendered. Set the yon closer to the camera to not draw distant objects.
sprite(1).camera.yon = 100000
See Also: hither, fog
See Chapter/Appendix: 39
z 3D, Math Property
This is the last element in a vector.
v = vector(10,-50,120) put v.x 120.0000
See Also: vector, x, y
See Chapter/Appendix: 39
zAxis 3D, Math Property
You can use this property to examine a vector representing the z axis of a transform.
t = transform() t.rotate(45,45,45) put t.zAxis vector( 0.8536, -0.1464, 0.5000 )
See Also: xAxis, yAxis, transform
zoomBox Misc Command
Creates a zooming effect between the rectangles of two sprites.
zoomBox(7,8)