MACROMEDIA FLASH 8-LEARNING ACTIONSCRIPT 2.0 IN FLASH Manual page 806

Learning actionscript 2.0 in flash
Table of Contents

Advertisement

Functions
are blocks of reusable code that can be passed parameters and can return a value.
For more information, see
Function literals
are unnamed functions that you declare in an expression instead of in a
statement. Function literals are useful when you need to use a function temporarily, or to use
a function in your code where you might use an expression instead.
IDE
refers to an "integrated development environment," which is an application in which a
developer can code, test, and debug applications in an interactive environment. The Flash
authoring tool is sometimes called an IDE.
Identifiers
are names used to indicate a variable, property, object, function, or method. The
first character must be a letter, underscore (
must be a letter, number, underscore, or dollar sign. For example,
a variable.
Instances
are objects that contain all the properties and methods of a particular class. For
example, all arrays are instances of the Array class, so you can use any of the methods or
properties of the Array class with any array instance.
Instance names
are unique names that let you target instances you create, or movie clip and
button instances on the Stage. For example, in the following code, "names" and
"studentName" are instance names for two objects, an array and a string:
var names:Array = new Array();
var studentName:String = new String();
You use the Property inspector to assign instance names to instances on the Stage. For
example, a master symbol in the library could be called
symbol in the SWF file could have the instance names
. The following code sets a variable called
scorePlayer2_mc
instance by using instance names:
this.scorePlayer1_mc.score = 0;
this.scorePlayer2_mc.score = 0;
You can use strict data typing when creating instances so that code hints appear as you type
your code.
Keywords
are reserved words that have special meaning. For example,
to declare local variables. You cannot use a keyword as an identifier. For example,
legal variable name. For a list of keywords, see
reserved words" on page
Literals
represent values that have a particular type, such as numeric literals or string literals.
Literals are not stored in a variable. A literal is a value that appears directly in your code, and is
a constant (unchanging) value within your Flash documents. Also see function literal, and
string literal.
806
Terminology
"About functions and methods" on page
), or dollar sign (
_
139.
). Each subsequent character
$
firstName
and the two instances of that
counter
scorePlayer1_mc
score
"About keywords" on page 138
201.
is the name of
and
inside each movie clip
is a keyword used
var
is not a
var
and
"About

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

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

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flash 8

Table of Contents