Things to consider before making the jump to Flash AS3

It's a long title, and it has been too long since I wrote a blog article. The fact is I have been so busy (thankfully, given the economic climate). A couple of recent projects have caused me to lock horns once again with Flash, with the creation of a number of small projects for various Clients with varying degrees of complexity. Until relatively recently, I have been doing all my programming in Flash in AS2. I can be described as someone who hates to be 'missing out', so for the latest wave of stuff, I went full into AS3. What followed was so traumatic that I had to write something to warn other travellers considering the same path. The theory The theory of AS3 is wonderful. I should point out that now I have got to grips with it, I believe it is wonderful too. One can understand how AS2 has 'grown' out of the Flash timeline and the objects that have idiosyncratically grown out of the system. AS3 is nothing short of radical; a complete break from AS2's ways. It is a truly (if stubborn) OOE language with proper classes, methods, properties, handlers and all. AS3 does not accept 'sloppy' type casting and does not favour the 'unplanned' project as even the most simple objective will run into scope issues. Everything has to be thought out properly, from the start. False sense of security When one chooses the 'Actionscript 3.0' tag when creating a new project, one thinks that all is well. The library, stage, frames etc all look the same as ever. The fact is that much of what one gets used to in AS2 simply is not allowed any more. The biggest shock is that 'buttons' are nearly useless suddently (apparently). They cannot have code in them. What was a relatively straightforward 'play' button instead of the normal on(release) { play(); }, There have to be creations of functions, event listeners, assignments, and code on the main timeline. This apparent 'over complexity' is apparent on every level. Nothing it seems is straight forward. Google becomes your greatest friend. Searching for things like 'access root movieclip currentframe AS3' become commonplace searches!

What's it for?

I DID however say that I thought it was wonderful; and I do! Although AS3 for ultra simple flash movies like banners and applets is very definitely overkill, for anything more advanced it is a godsend. Flash had this awful habit of making you do the strangest things. I have returned to many a project after a break to add something or change something, and spent at least half an hour trying to figure out how I made it work in the first place. This is because the code in AS2 is splattered all over the timeline and movies, sub movies, sub sub movies etc. It is it's simplicity and 'slackness' that is it's downfall. I.e. you might have a timer movie on the main timeline that is triggered from a sub sub movie which then reads something from XML and populates a button somewhere completely different. It's very hard to see at a glance how things work. AS3 by comparison does not allow such trickery, and the code on the main timeline invariably becomes more bulky an detailed which means the 'workings' of a project are obvious. Furthermore, the ability to associate external classes with the stage or objects and pass variables through 'proper' channels may be a swine to make work, but it gives you a very robust and clear structure. (I recently completed a project with a customised video player class - thanks to Macromedia for excellent demo material)

Who's it for

It's only after making the jump that I now realise that AS3 is only supported by Flash player 9+. This has meant that a number of users cannot currently play the files without upgrading their flash players. For Joe Public, that is a big ask. When a browser pops up a window saying 'upgrade' they tend to click on 'cancel' without reading it, then complain because they can't see the movie! I cannot see this situation resolving itself for at least another 12-24months (2010-2011).

Conclusion

So, you want my advice... Get into CS3. It's good for your skillset and will give you more robust and manageable projects.

However,

For the moment, keep using AS2 too, as it will produce movies that play on all the computers out there wihthout the users or ability to be upgraded to a later Flash player version.

Content

Active Domains

Active Domains are unique SEO optimising technology that delivers results through a network of optimised mini-sites to promote your business to specific groups.

Content

Web Optimisation

ginzola offer first class web optimisation services aimed at improving your organic site ranking. Our services can be tailored to meet many specific business objectives.

Content

Email Marketing

Email Marketing (mailshots) provide a valuable communication tool for your business. Ginzola provide a professional email distribution service that delivers.