- Full Description
Flash has long been one of the most approachable, user-friendly tools for creating web-based animations, games, and applications. This has contributed to making it one of the most widely used programs for creating interactive web content. With each new version of Flash, ActionScript, its built-in scripting language, has become more powerful and a little more complex, too. ActionScript, now at version 3.0, has significantly matured as a programming language, bringing power and speed only previously dreamed about to Flash-based animation, going far beyond traditionally used keyframes and tweens.
The material inside this book covers everything you need to know to harness the power of ActionScript 3.0. First, all the basics of script-based animation and setting up an ActionScript 3.0 project are covered. An introduction to object-oriented programming follows, with the new syntax, events, and rendering techniques of ActionScript 3.0 explained, giving you the confidence to use the language, whether starting from scratch or moving up from ActionScript 2.0.
The book goes on to provide information on all the relevant trigonometry you will need, before moving on to physics concepts such as acceleration, velocity, easing, springs, collision detection, conservation of momentum, 3D, and forward and inverse kinematics. In no time at all, you'll both understand the concepts of scripted animation and have the ability to create all manner of exciting animations and games.
What youll learn
- All the ActionScript 3.0 (including math and trigonometry functions) and Flash rendering techniques you'll need to start animating with code
- Basic motion principles such as velocity, acceleration, friction, easing, and bouncing
- How to handle user interaction via the keyboard and mouse
- Advanced motion techniques such as springs, coordinate rotation, conservation of momentum, and forward and inverse kinematics
- All the basic 3D concepts you need to do 3D in Flash, from simple perspective to full 3D solids complete with backface culling and dynamic lighting
- Source Code/Downloads
Please Login to submit errata.On page 69:linear vertical motion will not run. All I get is a blank screen with no sprite on the screen. I am using Actionscript 3.0 on a mac with the CS5 version.
On page 74-75:On the circle and elliptical examples: Math.cos should be used for X and Math.sin should be used for Y. But they are printed opposite. This differs from the tutorial and from the summary examples on page 80.
On page 111 and 112:Incorrect number of arguments. Expected no more than zero.
This error is against the middle line of the following code:
var myBitmapData:BitmapData=new BitmapData(100,100,false,0xff0000);
var myBitmap:Bitmap=new Bitmap(myBitmapData);
This same error is against the similar code on page 112:
var bmp:Bitmap=new Bitmap(canvas);
On page 145:Under "Add velocity to position:" movieclip._x += vx;
is from the previous edition (AS2).
It should be: sprite.x += vx;