Mike Downey presented a preview of the next version of Flash (codename Blaze) at Flashforward Austin 2006. New features include the ability to import Photoshop files directly into Flash allowing for precise control over every layer. You can make choices about each layer separately and also edit the imported text fields. There will be support for layer modes, drop shadows, blurs, and more. Flash will also be using the the JPEG compression from the next version of Photoshop.
If you have any ideas for Blaze you should submit them to the Flash 9 wishlist.
Today I have decided to build a simple ActionScript 3.0 horizontal menu based on an array. This is a fairly common practice in Flash development as we are often using data provided from a XML file to dynamically update content within our movies. To simplify this tutorial I am going to use an array that is written within my code instead of parsing it from a XML file.
The following example will demonstrate how to loop through an array and draw a button for each item in that array. Each button will have a label, an up state and an over state. I have read that it is good practice to use the SimbleButton object whenever possible, but I am not going to use the it in this tutorial because I am interested in learning more about addChild(), getChildByName(), currentTarget, mouseChildren and other features of ActionScript 3.0 that could be avoided using the SimpleButton.
Read more…
I was just told that the next release of Flash with be titled Adobe Flash CS3. If you are unfamiliar with CS, it stands for Creative Suite. The current release of Adobe’s Creative Suite is CS2, so I think we can expect a whole bundle of software being released at the same time that may include titles such as Flash CS3, Photoshop CS3, IllHand CS3 (Illustrator + Freehand), InDesign CS3, DreamLive CS3 (Dreamweaver + GoLive), Acrobat Paper CS3 (Acrobat + Flash Paper) and more. This is all just speculation on my part, so don’t take my word for it. I am pretty sure about the Flash CS3 part of it though.
The new Flash CS3 will definitely have enhancements to its importing abilities with Photoshop and Illustrator. From what I have heard, you will be able to access bitmaps and vectors right down to a specific layer within the import window. I am sure copy & paste between programs will function a lot smoother than previously.
Fraser
Well, it appears that in my previous posts about ActionScript 3.0, I am a bit old school. I have been instantiating my code from the first frame of the timeline using the import statement. After opening up a few of the as3_labs_samples_062706 and realizing that there is no code on the timeline, just a disclaimer, I started to scratch my head. I checked the library of the .fla to see if I could see any linkages. Still, I could not find any reference to the external code. The next place I checked was the Publish Settings (Ctrl-Shift+F12) and lo and behold, I found my answer. If you click on the Flash tab, then on the settings… button you will see the new Document class: field. Using this field you can instantiate your code. This is a much cleaner way of doing things. Finally a Flash Developer’s dream come true, no more code on the timeline.
In the previous post, Debugging in AS3 – Part 2 – Objects, I would have preferred to show you how to debug Objects with the ObjectDumper. The ObjectDumper can be imported using import mx.data.binding.Objectdumper. I tried this in ActionScript 3 and it would not work. I soon realized that all of the mx classes that shipped with Flash 9 Public Alpha are still written in ActionScript 2 and it appears that when you are publishing in ActionScript 3 the path to the mx classes is disabled. This means that we will have to wait to use a lot of the great functionality (Tween, ObjectDumper, etc.) that I took for granted in ActionScript 2. I did read somewhere that you can take the mx classes from the Flex SDK. Seeing as how I am still coding my work related projects in AS2 and only learning AS3 to get a head start, I will just wait until, hopefully, the next release.