User Guide
The PolyStar example 23
09 Vertex object
09 Edge object
07 Vertex object (shape.vertices array)
08 HalfEdge object
09 Vertex object
09 Edge object
03 ScreenOutline object
04 Screen object (screenOutline.screens array)
05 Parameter object (screen.parameters array)
02 drawingLayer object
03 Path object
04 Contour object
02 Effect object (fl.effects array)
02 Math object
02 outputPanel object
02 Tools object (fl.tools array)
03 ToolObj object (tools.toolObjs array)
02 XMLUI object
The PolyStar example
Included with this documentation is a sample Flash JSAPI script named PolyStar.jsfl. (You can
download the file at www.macromedia.com/go/jsapi_info_en.) This script replicates the PolyStar
tool that can be found in the Flash Tools panel. The PolyStar.jsfl file demonstrates how to build
the PolyStar tool using the JSAPI. It includes detailed comments that describe what the lines of
code are doing. Read this file to gain a better understanding of how the JSAPI can be used.
Flash MX 2004 includes an earlier version of the PolyStar.jsfl script that must be removed in order
to use the updated PolyStar.jsfl file.
To remove the earlier version of the PolyStar.jsfl that was installed with Flash MX 2004:
1.
Select Edit > Customize Tools Panel (Windows) or Flash > Customize Tools Panel
(Macintosh).
2.
In the Customize Tools Panel dialog box, click the Rectangle tool on the left side of the dialog
box.
The Rectangle tool and the PolyStar tool should now be listed in the Current Selection list on
the right side of the dialog box.
3.
Select the PolyStar tool in the Current Selection list.
4.
Click Remove.
5.
Click OK.
6.
Quit Flash.
7.
Remove only the PolyStar.jsfl file from the appropriate Tools folder listed in “Overview of the
Macromedia Flash JavaScript API” on page 17. The PolyStar.xml and PolyStar.png files are
needed by the new PolyStar.jsfl file that you will install later. When you restart Flash, the
PolyStar tool no longer appears in the Customize Tools Panel dialog box.