Learning ActionScript 3

fawnhobbiesΛογισμικό & κατασκευή λογ/κού

4 Ιουλ 2012 (πριν από 4 χρόνια και 11 μήνες)

322 εμφανίσεις

Learning ActionScript 3.0

The Non
-
Programmer's Guide to ActionScript 3.0

By
Rich Shupe
,
Zevan Rosser

First Edition


December 2007

Pages: 382

Series:
Adobe Developer Library

ISBN 10: 0
-
596
-
52787
-
X | ISBN 13: 9780596527877

http://oreilly.com/catalog/9780596527877/index.html

A

review by Mark Repp


As a technology trainer, I know how difficult it is to teach to all levels of computer
users at the same time. The book entitled
Learning ActionScript 3.
0: a
Beginner’s Guide

from the Adobe Developer Library (and O’Reilly) tries valiantly
to do this. It tries to be all things to all Flash developers. And if you’re planning
to use ActionScript for Adobe Flash CS3, I think this title comes as close to
acco
mplishing this feat as any other book I’ve found.


In this book you will find practically everything you need to know from a Web
Designer’s point of view, as well as for the GUI
-
based Flas
h developers who
want to create

their own mini applications. Flas
h can do this, and this

book will
show you how

with the newest version of the

scripting language, version 3.0.
Although it has “A Beginner’s Guide” as part of its title, it is much more than a
“Getting Started” guide. True, it has an ActionScript overvie
w section to get the
user started, especially if he/she is not familiar with what ActionScript is, and
what it does. The Flash platform is discussed

briefly, and that is exactly what
Flash is now…a platform. This book focuses primarily on developing
Acti
onScript 3.0 applications using Flash’s CS3 environment. So, if you do
not

have Adobe CS3 or Flash CS3 in particular, this book is not for you, or you’d
better quickly go out and get an upgrade, because ActionScript 3 is
completely
different

than any vers
ion of ActionScript you may have used in the past. The
book is presented within a Flash CS3 Professional context. Therefore, it does
not include examples of Flex, Flash Media Server, AIR or any other evolving
Flash platform technologies. However, most r
eaders will not be looking for these
additions.
Instead, they will probably be looking for what this book does best,
which is teach ActionScript programming.
Right away on page 8, there is a
discussion that focuses on Procedural vs. Object
-
oriented Progr
amming (OOP),
and most chapters end with an applied OOP example. This is very helpful.


The 2
nd

Chapter jumps right into
such
Core Language Fundamentals

as
Variables and Data Types, Loops, Arrays, Conditionals, Functions and
distinguishes between Absolu
te vs. Relative Addresses. Al
l of these are very
important in

learning how to use this completely different pr
ogramming language.
And since F
lash is an object
-
oriented language, th
ere is a helpful section in
Chapter 2

that covers Custom Objects. Chapter

6, for exampl
e, is a 27
-
page
look at

OOP (object
-
o
riented programming)
. Examples are given of actual
scripts in every section, demonstrating the use of each element in ActionScript
3.0. The Core Language Fundamentals are clearly laid out, with definitio
ns and
examples of each. There is a nicely
-
organized example of Variable Types that
helped me a lot. Various
“If”

conditionals are given as examples, showing the
painstaking effort that the authors used to get the basics down
pat
for the reader.


Altho
ugh ActionScript is not for the faint of heart, or the average ever
-
day
animator, if you read this book the way it was intended to be read (in the order
that the chapters are laid out), it is better than any ActionScript 3.0 course you
will ever take. Eve
rything is neatly organized.
It covers as many ActionScript
essentials as could possibly be included. Such topics as “Graphics and
Interaction” (part 2 of the book); “Text” (part 3 of the book); “Sound and Video”
(part 4), “Input/Output” (part 5) and “Pr
ogramming Design and Resources”

(part
6). All of it is here, and I think the examples are wonderful.

Not a lot of GUI
screenshots, but there are many scripts that you could use as a jumping
-
off point
or as reference examples.


One question that came to m
ind while I went through the different sections was
“Is this a reference book?”
Well, i
t can be used this way, definitely. However
,
even the authors recommend other

title
s, such as

Essential ActionScript
3.0

by
Colin Moock (O’Reilly) as the ultimate refe
rence book, a
nd for the die
-
hard
AS
3.0 programmer, look at the
ActionScript 3.0 Cookbook

by Lott, Peters and
Schall (also from O’Reilly). What this book is, however, is a combination of both,
and it wo
uld be a great companion for either

of the aforementi
oned titles,
particularl
y if you are an advanced user.


There is also a companion Web site for the book, found at
www.LearningActionScript3.com

which includes supplemental materials and all
of the exerc
ises found in the book itself in
a
downloadable
/printable

form
at
.

Just
click on the “Print This Post” link at the bottom of each Web section.

Additional
exercises are also available on this site, as well as self
-
quizzes, ongoing learning
suggestions and
reader comments. The authors say that additional
community

resources will be added to the site, such as a forum where they will participate. I
find that with today’s computer and application
-
oriented books, this nice Web
a
ddition is essential to making a

book
more
current in a world where computer

books have a very short life.


So, what exactly are you looking for from ActionScript 3.0? Just an update on
how it differs from previous versions like 2.0? How to create text (text fields,
formatting text, tr
iggering ActionScript from HTML and CSS)? All of this is in
Chapter 10, one of my favorite sections in Part 3 of the book.
How about
“Loading Assets” such as sound and video, loading text, display
ing

objects or
even
communicating across virtual machines?

All of this is covered in Part 5 of
the book. XML and E4X
are

also covered in this section. Never completely
understanding XML before, this book helped to clarify for me how it can be used
in Flash and general application. For instance, there is a sec
tion that goes into
the actual structure of XML, making it clearer to the reader. I never understood
white space very well until I saw the table on page 299. Page 302 provides a
section called “Creating an XML Object” with a full
-
page scripted example.


Without going into further technical detail about ActionScript and computer
programming, rest assured that this is the book for you


if you want to dive into
Adobe ActionScript 3.0, and discover what it can do in each of the areas
mentioned. The chapte
r on Video alone (chapter 12
-
part 4) is worth the $39.99
price tag alone. If you’re more of an animator trying to bring out the power of this
environment, look at “Chapter 5: Timeline Control” right away. It has some nice
tips on topics like “Frame Rate”
, “Frame Labels” and “Playhead Movement.” But
what you will definitely find about ActionScript more than anything else is that it is
part of a platform. Flash is no longer
used
just for animation. It is a platform all
its

own, with many

applications

ful
filling various needs both on and off the Web.
Learning ActionScript 3.0

is a perfect place to start

uncovering the power of
Flash CS3, and y
ou will be amazed at how much you will lea
rn in 350 pages
(plus Index). It i
s the discovery of a
solid programmin
g language that is ever
-
changing and
cutting
edge.

This is, overall in my opinion, the very best

book in
which to discover it.