Errata

Learning ActionScript 3.0

Errata for Learning ActionScript 3.0

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released. If the error was corrected in a later version or reprint the date of the correction will be displayed in the column titled "Date Corrected".

The following errata were submitted by our customers and approved as valid errors by the author or editor.

Color key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted By Date submitted Date corrected
Printed
Page xviii
Line 9

Interativity

should be

Interactivity

Note from the Author or Editor:
Corrected in later printing.

Anonymous   
Printed
Page 4
line 9

chllenge
should be
challenge

Anonymous   
Printed
Page 9.1
9.1. Bitmap Caching (error only on Safari)

(NOTE: I'm using O'Reilly's Safari to read this book, so I don't know the exact page number.)

In Chapter 9, section 9.1 Bitmap Caching, the setMask property in the example below doesn't compile in Flash CS3 (I get a "this property doesn't exist" compile-time error):

mask.cacheAsBitmap = true;
maskee.cacheAsBitmap = true;
maskee.setMask(mask);

The correct way to set a mask is:
maskee.mask = mask;

Where .mask is the correct property.

Note from the Author or Editor:
Corrected in a later printing.

Anonymous   
PDF
Page 25
2nd paragraph

Double right parenthesis before semicolon
var celDeg:Number = farToCel(68));

Note from the Author or Editor:
Corrected in later printing.

Bernardo Vasquez  Jun 12, 2009 
Printed
Page 33
figure 3-1 , second example

box.scaleX=50;
box.scaleY=50;

should it reflect the new syntax format?

box.scaleX=.5;
box.scaleY=.5;

Note from the Author or Editor:
Corrected in later printing.

Anonymous   
Printed
Page 42
sidebar - fig 3-4

Note from the Author or Editor:
Corrected in later printing.

Anonymous  Jul 21, 2008 
Printed
Page 42
(Safari only) sidebar - fig 3-4

"...t mouse over..." should be "...the mouse over..." or just "...mouse over..."

Anonymous   
Printed
Page 45
last sentence

Note from the Author or Editor:
Will be corrected in a future printing.

Anonymous  Jun 08, 2008 
Printed
Page 51
4th para, 1st sentence

Note from the Author or Editor:
Corrected in later printing.

Anonymous  Jul 22, 2008 
Printed
Page 51
(Safari only) 4th para, 1st sentence

"...a shape is a display objects, as are..." should be "...a shape is a display object, as are..."

Anonymous   
Printed
Page 55
top

code in section that reads:

function showChildren(dispObj:DisplayObject):void {
for (var i:int = 0; i < dispObj.numChildren; i++) {
var obj:DisplayObject = dispObj.getChildAt(i);
if(obj is DisplayObjectContainer) {
trace(obj.name, obj);
showChildren(obj);
} else {
trace(obj);
}
}
}

showChildren(stage);

This code does not work in Flash CS3 and causes Compiler Error

Note from the Author or Editor:
Corrected in later printing. Because this function is recursive, the data type of the argument should be "*", or untyped. This will allow both DisplayObject and DisplayObjectContainer to be accepted by the argument.

Anonymous   
Printed
Page 64
4.3. Managing Object Names, Positions, and Data Types

In subsection 4.3.1. Finding Children by Position and by Name, a couple of the examples include the variable name do. For instance:

var do:DisplayObject = getChildAt(0);

do is a reserved ActionScript keyword, and if you try to execute this example, you'll get the following error:

"Syntax error, expecting identifer before do"

Use another variable name instead, such as do1 or do2.

Note from the Author or Editor:
Corrected in later printing.

Anonymous   
Printed
Page 66
3rd paragraph

It says that in the paragraph to look at the

Note from the Author or Editor:
Corrected in a later edition. The file name appeared incorrectly in the text, but correctly in the image caption. It is called z-sorting.fla. A new file will be created and added to the source archives.

Anonymous  Oct 12, 2008 
Printed
Page 69
5th paragraph

paragraph reads

Note from the Author or Editor:
Corrected in later printing.

Anonymous  Jul 28, 2008 
Printed
Page 69
example code line 7

for (var 1:uint = 0; 1, btnNum; 1++) {
should be:
for (var i:uint = 0; i < btnNum; i++) {

Anonymous   
Printed
Page 69
2nd text paragraph, middle of page

The text reads:

Note from the Author or Editor:
Corrected in a later printing. The line
btn.name = "button" + i;
was omitted. There is no prior AS2 version of this book. This was just an omission that occurred during production. The line numbers are correctly referenced in the current edition, but a duplicate submission confirms that this was caused due to the omission of the above line.

Anonymous  May 17, 2009 
Printed
Page 113
line 19 of code

var menuBtn:MenuButtonMain = new MenuButtonMain(navData[i]);
should be:
var menuBtn:MenuButtonMain = new MenuButtonMain(_navData[i]);

Anonymous   
Printed
Page 127
under the code listed for the "Friction" project

On page 127 (Ch. 7) under the code listed for the "Friction" project, there are two typos in the code.

In lines 10 and 14-15 the handle being used for friction coefficient switches between the two sets of
code. In line 10 it is listed as "frCooef" and in lines 14-15 it is listed as "frCoeff"

Note from the Author or Editor:
Corrected in later edition. Misspelling "frCooef" corrected to "frCoeff"

Anonymous   
Printed
Page 132
Fourth Line down

Hi,
Just wanted to let you know that on page 132 of Learning Actionscript 3.0 on the fourth line down the word animations is spelled

Note from the Author or Editor:
Will be corrected in future printing.

Anonymous  Sep 03, 2008 
Printed
Page 143
at the top of the page, the first line of the code example

on page 143.

at the top of the page, the first line of the code example is:

var descriptiveSpriteName:Sprite() = new Sprite()

I don't think there's supposed to be parenthesis after the data type.

Note from the Author or Editor:
Will be corrected in a future printing.

Anonymous  Sep 08, 2008 
Printed
Page 227
First code listing under "Playing Sounds"

var channel:SoundChannel; should read
var channel:SoundChannel = new SoundChannel;
as is shown in the note at the right hand side.

Note from the Author or Editor:
Will be corrected in a future printing.

Anonymous  Oct 16, 2008