Initclip Directive - MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE Reference

Actionscript 2.0 language reference
Table of Contents

Advertisement

Parameters
-
The filename and optional path for the script to
[path]filename.as:String
filename.as
add to the Actions panel or to the current script; .as is the recommended filename extension.
Example
The following examples show various ways of specifying a path for a file to be included in
your script:
// Note that #include statements do not end with a semicolon (;)
// AS file is in same directory as FLA file or script
// or is in the global Include directory or the First Run/Include directory
#include "init_script.as"
// AS file is in a subdirectory of one of the above directories
// The subdirectory is named "FLA_includes"
#include "FLA_includes/init_script.as"
// AS file is in a subdirectory of the script file directory
// The subdirectory is named "SCRIPT_includes"
#include "SCRIPT_includes/init_script.as"
// AS file is in a directory at the same level as one of the above
directories
// AS file is in a directory at the same level as the directory
// that contains the script file
// The directory is named "ALL_includes"
#include "../ALL_includes/init_script.as"
// AS file is specified by an absolute path in Windows
// Note use of forward slashes, not backslashes
#include "C:/Flash_scripts/init_script.as"
// AS file is specified by an absolute path on Macintosh
#include "Mac HD:Flash_scripts:init_script.as"

#initclip directive

#initclip [order:Number]
Indicates the beginning of a block of initialization actions. When multiple clips are initialized
at the same time, you can use the
parameter to specify which initialization occurs first.
order
Initialization actions are executed when a movie clip symbol is defined. If the movie clip is an
exported symbol, the initialization actions are executed before the actions on Frame 1 of the
SWF file. Otherwise, they are executed immediately before the actions of the frame that
contains the first instance of the associated movie clip symbol.
Initialization actions are executed only once when a SWF file is played. Use them for one-time
initializations, such as class definition and registration.
Compiler Directives
33

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Flash 8

Table of Contents