408
Chapter 12: Methods
Parameters
vertexIndex
Required. Specifies the index position of the vertex to move.
xChange
Required. Specifies the amount to move the vertex horizontally.
yChange
Required. Specifies the amount to move the vertex vertically.
Example
This statement shifts the first vertex point in the vector shape Archie 25 pixels to the right and 10
pixels down from its current position:
-- Lingo syntax
member("Archie").moveVertex(1, 25, 10)
// JavaScript syntax
member("Archie").moveVertex(1, 25, 10);
See also
addVertex()
,
deleteVertex()
,
moveVertexHandle()
,
originMode
,
vertexList
moveVertexHandle()
Usage
-- Lingo syntax
memberObjRef
.moveVertexHandle(
vertexIndex
,
handleIndex
,
xChange
,
yChange
)
// JavaScript syntax
memberObjRef
.moveVertexHandle(
vertexIndex
,
handleIndex
,
xChange
,
yChange
);
Description
Function; moves the vertex handle of a vector shape cast member to another location.
The horizontal and vertical coordinates for the move are relative to the current position of the
vertex handle. The location of the vertex handle is relative to the vertex point it controls.
Changing the location of a control handle affects the shape in the same way as dragging the vertex
in the editor.
Parameters
vertexIndex
Required. Specifies the index position of the vertex that contains the handle
to move.
handleIndex
Required. Specifies the index position of the handle to move.
xChange
Required. Specifies the amount to move the vertex handle horizontally.
yChange
Required. Specifies the amount to move the vertex handle vertically.
Example
This statement shifts the first control handle of the second vertex point in the vector shape Archie
15 pixels to the right and 5 pixels up:
-- Lingo syntax
moveVertexHandle(member("Archie"), 2, 1, 15, -5)
// JavaScript syntax
moveVertexHandle(member("Archie"), 2, 1, 15, -5)
Summary of Contents for DIRECTOR MX 2004-DIRECTOR SCRIPTING
Page 1: ...DIRECTOR MX 2004 Director Scripting Reference...
Page 48: ...48 Chapter 2 Director Scripting Essentials...
Page 100: ...100 Chapter 4 Debugging Scripts in Director...
Page 118: ...118 Chapter 5 Director Core Objects...
Page 594: ...594 Chapter 12 Methods...
Page 684: ...684 Chapter 14 Properties See also DVD...
Page 702: ...702 Chapter 14 Properties See also face vertices vertices flat...
Page 856: ...856 Chapter 14 Properties JavaScript syntax sprite 15 member member 3 4...
Page 1102: ...1102 Chapter 14 Properties...