<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Flash Speaks Actionscript &#187; AS2 to AS3</title>
	<atom:link href="http://flashspeaksactionscript.com/tag/as2-to-as3/feed/" rel="self" type="application/rss+xml" />
	<link>http://flashspeaksactionscript.com</link>
	<description>Learn and Speak Actionscript</description>
	<lastBuildDate>Sat, 10 Mar 2012 02:45:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Moving From AS2 to AS3: A Handy List of Resources</title>
		<link>http://flashspeaksactionscript.com/as2-to-as3-handy-list-of-resources/</link>
		<comments>http://flashspeaksactionscript.com/as2-to-as3-handy-list-of-resources/#comments</comments>
		<pubDate>Tue, 28 Sep 2010 15:00:27 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[Book]]></category>
		<category><![CDATA[Featured]]></category>
		<category><![CDATA[roundup]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=4361</guid>
		<description><![CDATA[The shift of developers moving from AS2 to AS3 is possibly entering its last wave.   To accommodate those still making that move from AS2 to AS3, I decided to gather a bunch of resources that will aid in that journey. ]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Fas2-to-as3-handy-list-of-resources%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22Moving%20From%20AS2%20to%20AS3%3A%20A%20Handy%20List%20of%20Resources%20%23AS2%20to%20AS3%20%23Book%20%23Featured%20%23roundup%22%20%7D);"></div>
<p>The shift of developers moving from AS2 to AS3 is possibly entering its last wave.   To accommodate those still making that move from AS2 to AS3, I decided to gather a bunch of resources that will aid in that journey.  If there is any that I might of missed, feel free to share your resource via the comments.</p>
<h2>Books</h2>
<h3><a href="http://www.amazon.com/gp/product/0321555589?ie=UTF8&amp;tag=flashspeakact-20&amp;linkCode=as2&amp;camp=1789&amp;creative=390957&amp;creativeASIN=0321555589">The ActionScript 3.0 Migration Guide: Making the Move from ActionScript 2.0</a><img style="border: none !important; margin: 0px !important;" src="http://www.assoc-amazon.com/e/ir?t=flashspeakact-20&amp;l=as2&amp;o=1&amp;a=0321555589" alt="" width="1" height="1" border="0" /></h3>
<p>The book explains the most important and fundamental changes in ActionScript drawing comparisons between the two languages both visually and contextually. With a comprehensive index and robust table of contents designers and developers will easily be able to locate the old an/or new codes with side-by-side comparisons of how to program both and the explanation of the concepts behind them.</p>
<h3><a href="http://www.amazon.com/gp/product/059652787X?ie=UTF8&amp;tag=flashspeakact-20&amp;linkCode=as2&amp;camp=1789&amp;creative=390957&amp;creativeASIN=059652787X">Learning ActionScript 3.0: A Beginner&#8217;s Guide</a><img style="border: none !important; margin: 0px !important;" src="http://www.assoc-amazon.com/e/ir?t=flashspeakact-20&amp;l=as2&amp;o=1&amp;a=059652787X" alt="" width="1" height="1" border="0" /></h3>
<p>In this book, authors Rich Shupe and Zevan Rosser share the knowledge they&#8217;ve gained from their years as multimedia developers/designers and teachers. Learning ActionScript 3.0 gives you a solid foundation in the language of Flash and demonstrates how you can use it for practical, everyday projects.</p>
<p>Written for those of you new to ActionScript 3.0, the book describes how ActionScript and Flash work, giving you a clear look into essential topics such as logic, event handling, displaying content, migrating legacy projects to ActionScript 3.0, classes, and much more.</p>
<h3><a title="Stepping Into ActionScript" href="http://www.flasheezy.com/ebook" target="_blank">Stepping Into ActionScript3: The Complete Guide for Easy Migration from AS2 to AS3</a></h3>
<p><strong>Stepping into ActionScript 3</strong> is a beginner’s guide to development with ActionScript 3 for the Flash and Flex development environments. In this 38 page ebook you’ll get simple step by step examples with code snippets that you can easily copy and paste. You’ll learn everything you need to know about variables, functions, classes, interfaces, events and the display list.</p>
<h2>Tutorials</h2>
<h3><a title="AS2 to AS3: Button Press" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-button-press/" target="_self">Moving from Flash AS2 to Flash AS3: Button Press</a></h3>
<p>The simple button press is probably one of the most used features for Flash users. With ActionScript 3.0, this has changed quite a bit. This tutorial will directly focus on just that.</p>
<h3><a title="AS2 to AS3: Handling Depths" href="http://flashspeaksactionscript.com/moving-from-as2-to-as3-handling-depths/" target="_self">Moving From AS2 to AS3: Handling Depths</a></h3>
<p>Managing depths in AS2 was pretty annoying and time consuming. You’d spend so much time dedicating depth ranges for MovieClip groups, but in the end the limitations of AS2 really got the last laugh. Who’s laughing now?</p>
<h3><a title="AS2 to AS3: Dynamic Masks" href="http://flashspeaksactionscript.com/moving-from-as2-to-as3-creating-dynamic-masks/" target="_self">Moving From AS2 to AS3: Creating Dynamic Masks</a></h3>
<p>Dynamic mask objects have been key to many Flash project’s success. When it comes to migrating over from AS2 to AS3, you’ll find that things have changed as the method <strong>“setMask()”</strong> in AS2 is now a property called “mask”. This tutorial compares the two solutions and offering an efficient solution to creating dynamic masks using AS3.</p>
<h3><a title="AS2 to AS3: Loading External Sounds" href="http://flashspeaksactionscript.com/loading-external-sounds-using-as3/" target="_self">Loading External Sounds Using AS3</a></h3>
<p>Loading external sound into your Flash projects using AS2 is a fairly easy task.  Using AS3 to load external sounds is just as simple.  I am going to quickly go over how to load an external sound file using AS3 in comparison to AS2 syntax.</p>
<h3><a title="AS2 to AS3: Playing Sounds" href="http://flashspeaksactionscript.com/playing-stopping-and-pausing-sounds-using-as3/" target="_self">Playing, Stopping, and Pausing Sounds Using AS3</a></h3>
<p>When controlling audio, being able to stop or pause then play again might be a good place to start.   In this tutorial, I will be demonstrating how to play, stop, and pause sounds using AS3 once you have the sound loaded into Flash.</p>
<h3><a title="AS2 to AS3: Preloading Content" href="http://flashspeaksactionscript.com/preloading-content-using-as3/" target="_self">Preloading Content Using AS3</a></h3>
<p>Preloading in AS3 is a more streamlined process due to the new &amp; improved event handling structure that AS3 brings to the table. You have more control over what gets preloaded and when it gets preloaded.  In this brief tutorial, I will demonstrate how to preload your Flash assets using AS3.</p>
<h3><a title="AS2 to AS3: Loading XML" href="http://flashspeaksactionscript.com/loading-xml-data-using-as3/" target="_self">Loading XML Data Using AS3</a></h3>
<p>The XML libraries have been completely overhauled in AS3. These new changes provide a much more seamless XML integration that is based on the web standards of E4X. In this example, I will go through and compare loading a XML file using AS2 versus AS3.</p>
<h3><a title="AS2 to AS3: Filtering XML" href="http://flashspeaksactionscript.com/filtering-xml-data-using-as3/" target="_self">Filtering XML Data Using AS3</a></h3>
<p>Filtering data XML data using AS2 has to be one of the most sought out features when dealing with XML-driven Flash projects. Being able to automatically grab certain relevant information without manually searching each and every XML node and/or attribute.  Another new feature in AS3 is the ability to filter and display only the data you are interested in. This tutorial focuses on that specific topic.</p>
<h3><a title="AS2 to AS3: Dynamic Frame Script" href="http://flashspeaksactionscript.com/dynamically-add-script-to-frames-of-a-movieclip-with-as3/" target="_self">Dynamically Add Script to Frames of a MovieClip with AS3</a></h3>
<p>It is always fun when you come across an undocumented feature, especially when it sounds to be extremely useful. One “known” undocumented feature within ActionScript 3.0 is the ability to add ActionScript to frames of a MovieClip via runtime.</p>
<h3><a title="AS2 to AS3: Adjust Frame Rate" href="http://flashspeaksactionscript.com/dynamically-adjust-the-frame-rate-of-a-flash-animation/" target="_self">Dynamically Adjust the Frame Rate of a Flash Animation</a></h3>
<p>New to ActionScript 3.0 is the ability to dynamically change the frame rate of an animation via runtime. By having this ability, you can create a slow motion animation without the exact precisiong in keyframe timing. You can also use this to lower the frame rate for slower machines dynamically.  Let’s see it in action.</p>
<h3><a title="AS2 to AS3: Dynamic MovieClip Creation" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-dynamic-movieclip-creation/" target="_self">Moving From Flash AS2 to Flash AS3: Dynamic MovieClip Creation</a></h3>
<p>Creating a MovieClip dynamically  is a task you will find yourself doing often in ActionScript 3.0.  If you’ve ever tried this is AS2, it required the population of many parameters and a frequent trip to the Flash Help panel.  AS3 introduces much simplified solution to dynamically creating a MovieClip.</p>
<h3><a title="AS2 to AS3: MovieClip Properties" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-movieclip-properties/" target="_self">Moving From Flash AS2 to Flash AS3: MovieClip Properties</a></h3>
<p>The use of MovieClips within Flash development has become second nature to most of us.  As for modifying its properties, it has also become  a part of our everyday Flash routine.  It simply does not require any second thoughts when modifying them.  It’s time for a little change.</p>
<h3><a title="AS2 to AS3: Timeline Controls" href="http://flashspeaksactionscript.com/new-timeline-controls-in-as3/" target="_self">A Glimpse at the New Timeline Controls in AS3</a></h3>
<p>With all the changes that came with ActionScript 3.0, a few new Timeline properties were introduced with the hope that any Flash animator, designer or developer would come to appreciate. The lack of exact control or knowledge of where you area on the Timeline or scene gets a bit irritating when you do not want to stick with static frame numbers.</p>
<h3><a title="AS2 to AS3: Paths" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-paths/" target="_self">Moving from Flash AS2 to Flash AS3: Paths</a></h3>
<p>As a ActionScript 2.0 developer, one of the first hurdles to overcome when first using ActionScript 3.0 was _parent and _root. They’ve respectively changed to parent and root and they don’t entirely work as intended.  Let&#8217;s break it down!</p>
<h3><a title="AS2 to AS3: _root" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-_root/" target="_self">Moving From Flash AS2 to Flash AS3: _root</a></h3>
<p>Before ActionScript 3.0, the _root variable call referred to the timeline of the original host SWF no matter how many SWFs were previously loaded.  I have always saw it as the bail out plan, because no good ever came from _root is AS2.  Since _root can easily be compared to an absolute address, the long term effects will be felt especially as your code becomes more object-oriented.</p>
<h3><a title="AS2 to AS3: getURL" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-geturl/" target="_self">Moving From Flash AS2 to Flash AS3: getURL</a></h3>
<p>The command getURL used to a be very easy way to create an outbound link within Flash. This one line of code code easily fitted perfectly within a button onRelease event. Not so easy anymore.</p>
<h3><a title="AS2 to AS3: Switch Statements" href="http://flashspeaksactionscript.com/conditional-statements/" target="_self">Conditional Statements: Switch Versus If/Else if/Else</a></h3>
<p>You will often need to make a decision in your ActionScript, choosing to do one thing under one situation, and another thing under a different situation. The use of conditionals is a great way to accomplish this and can very well be your most used ActionScript solution.</p>
<h3><a title="AS2 to AS3: Keyboard Interactivity" href="http://flashspeaksactionscript.com/keyboard-interactivity-within-as3/" target="_self">Keyboard Interactivity Within AS3</a></h3>
<p>Keyboard interactivity within the new AS3 environment has changed from its predecessor, AS2. With the changes to the button press in AS3, you’d might expect the Keyboard event calls to receive no easier treatment in how you use them.  Let&#8217;s take a look at the improvements.</p>
<h3><a title="AS2 to AS3: Drag and Drop" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-drag-and-drop/" target="_self">Moving From Flash AS2 to Flash AS3: Drag and Drop</a></h3>
<p>Creating drag and drop functionality in is Actionscript 3.0 quite different than in older versions. While still relatively straightforward, it can still be a little odd to those not really familiar with the new Actionscript 3.0 structure.</p>
<h3><a title="AS2 to AS3: FlashVars" href="http://flashspeaksactionscript.com/moving-from-flash-as2-to-flash-as3-flashvars/" target="_self">Moving From Flash AS2 to Flash AS3: FlashVars</a></h3>
<p>The key difference between AS2 and AS3 is how to retrieve the FlashVars. The FlashVars are no longer available in the _root level of the movie. Instead, you must use the new LoaderInfo class object to access the FlashVars.</p>
<h3><a title="AS2 to AS3: Custom Cursor" href="http://flashspeaksactionscript.com/create-a-custom-cursor-using-as3/" target="_self">Create a Custom Cursor Using AS3</a></h3>
<p>The simplicity of creating a custom cursor within Flash is a task that will surely be used time after time again.  Well, as for creating a custom cursor using AS3, the syntax used is identical as written in AS2.</p>
<h3><a title="Migrating from AS2 to AS3" href="http://www.bigspaceship.com/blog/labs/migrating-from-as2-to-as3/" target="_self">Migrating from AS2 to AS3</a></h3>
<p>A lot of questions are being asked about AS3 people. A lot. You have every reason to be frightened. We were frightened, too. But it&#8217;s okay. AS3 has replaced all of the old annoying quirks with a slew of new ones. There&#8217;s lots more to be frustrated over, and the best part is you don&#8217;t even know what it is yet.  The guys over at Big Spaceship go over some of the key changes when going from AS2 to AS3.</p>
<h3><a title="AS2 to AS3: MovieClip Buttons" href="http://www.8bitrocket.com/2008/1/17/Moving-From-Flash-AS2-To-Flash-AS3-MovieClip-Buttons-In-MovieClip-Classes/" target="_self">Moving From Flash AS2 To Flash AS3: MovieClip Buttons In MovieClip Classes</a></h3>
<p>When using MovieClips as buttons in AS3, there are a few kinks that knowing ahead of time will prevent yourself from going crazy.  This tutorial will walk you through them.</p>
<h3><a title="Introduction to event handling in ActionScript 3.0 " href="http://www.adobe.com/devnet/actionscript/articles/event_handling_as3.html" target="_blank">Introduction to Event Handling in ActionScript 3.0</a></h3>
<p>Event handling in ActionScript has changed significantly over the past few releases of Flash Player. With the introduction of ActionScript 3.0, this trend continues. Using ActionScript 3.0, you have even more control when working with events. This article covers the new features related to event handling in ActionScript 3.0.</p>
<h2>Additional Resources</h2>
<h3><a title="ActionScript 3 Tip of the Day" href="http://www.kirupa.com/forum/showthread.php?t=223798" target="_blank">ActionScript 3.0 Tip of the Day</a></h3>
<p>Senocular&#8217;s popular ActionScript 3.0 tips provide a in depth view on providing AS2 to AS3 conversions of daily ActionScript tasks.  Well worth a look and can potentially save you a lot of early stage headaches.</p>
<h3><a title="Introductory AS3" href="http://gskinner.com/talks/as3workshop/" target="_blank">Introductory AS3</a></h3>
<p><a href="http://gskinner.com/"> Grant Skinner</a> has released an immensely useful slide deck from his Introductory AS3 workshop and is a priceless resource for those late development nights.</p>
<h3><a title="10 Books to Help in Learning AS3" href="http://flashspeaksactionscript.com/10-books-to-help-in-learning-as3/" target="_self">10 Books to Help in Learning AS3</a></h3>
<p>While not all our paths to learning ActionScript 3.0 are the same, the resources that are provided to us are. Some like taking that direct dive into it and learn from their mistakes. Others would prefer to learn through someone else’s following.  Here is a list of the 10 books that may possibly help you learn and/or expand your knowledge of ActionScript 3.0.</p>
<h3><a title="Six Reasons to Use ActionScript 3.0" href="http://flashspeaksactionscript.com/here-are-six-reasons-to-use-actionscript-30/" target="_self">Six Reasons to Use ActionScript 3.0</a></h3>
<p>In this article, <a title="Six Reasons to use ActionScript 3.0" href="http://www.adobe.com/devnet/actionscript/articles/six_reasons_as3.html">Lee Brimelow</a> hopes to dispel some of the misconceptions that have been placed upon ActionScript 3.0 and why he believes you should use ActionScript 3.0 exclusively in your Flash projects.</p>
<h3><a title="ActionScript 3.0: Is It Hard or Not?" href="http://insideria.com/2008/01/actionscript-30-is-it-hard-or.html" target="_blank">ActionScript 3.0: Is It Hard or Not?</a></h3>
<p>In parts of the Flash community, ActionScript 3.0 seems to have gained a reputation for being &#8220;hard&#8221;—particularly among those who have not yet tried the new language. Is the reputation warranted? In this article, Colin Moock expresses his opinions and facts as to why AS3 is not hard at all.</p>
<h3><a title="ActionScript 2.0 to 3.0 Migration Cheatsheets" href="http://www.actionscriptcheatsheet.com/downloads/as3cs_migration.pdf" target="_self">ActionScript 2.0 to 3.0 Migration Cheatsheets</a></h3>
<p>Cheat sheets relating to AS2 to AS3 syntax migrations.</p>
<h3><a title="Top five misperceptions about ActionScript 3 " href="http://www.adobe.com/devnet/actionscript/articles/as3_misperceptions.html" target="_blank">Top five misperceptions about ActionScript 3</a></h3>
<p>ActionScript 3.0 is no more difficult to learn than any other programming or scripting language. If you are familiar with ActionScript 2.0, the language semantics are pretty much the same, although you will need to learn new ways of doing some common tasks.  This article looks to calm those misconceptions.</p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/as2-to-as3-handy-list-of-resources/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ActionScript 1:1 &#8211; Getting Intimate With ActionScript 3.0</title>
		<link>http://flashspeaksactionscript.com/actionscript-11-getting-intimate-with-actionscript-30/</link>
		<comments>http://flashspeaksactionscript.com/actionscript-11-getting-intimate-with-actionscript-30/#comments</comments>
		<pubDate>Wed, 05 Aug 2009 12:00:20 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[AS3]]></category>
		<category><![CDATA[Beginner]]></category>
		<category><![CDATA[Flash CS4]]></category>
		<category><![CDATA[roundup]]></category>
		<category><![CDATA[Videos]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3730</guid>
		<description><![CDATA[Struggling to get our foot off the ground with getting more intimate with ActionScript 3.0?  Doug Winnie has kicked off a series, ActionScript 1:1, which are designed for animators and designers using Flash CS4 who want to take their work to the next level but need some guidance adding custom interactivity using ActionScript 3.0.]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Factionscript-11-getting-intimate-with-actionscript-30%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22ActionScript%201%3A1%20-%20Getting%20Intimate%20With%20ActionScript%203.0%20%23AS2%20to%20AS3%20%23AS3%20%23Beginner%20%23Flash%20CS4%20%23roundup%20%23Videos%22%20%7D);"></div>
<p><strong><em>Struggling to get our foot off the ground with getting more intimate with ActionScript 3.0?</em></strong></p>
<p><a title="1:1 with Doug Winnie" href="http://www.adobe.dougwinnie.com/">Doug Winnie</a> has kicked off a series, <strong>ActionScript 1:1</strong>, which is designed for animators and designers using Flash CS4 who want to take their work to the next level but need some guidance adding custom interactivity using ActionScript 3.0.</p>
<p>These videos are aimed at Flash Designers looking to strengthen their knowledge of ActionScript 3.0.  We all have to start somewhere when learning to use ActionScript 3.0 and this series is great way to get that train moving along.</p>
<p>Below are all the episodes in the series.  You can also find Doug&#8217;s videos as a channel on <a title="Adobe TV" href="http://tv.adobe.com/#vi+f15914v1000">Adobe TV</a> and <a title="iTunes" href="http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewPodcast?i=54734103&amp;id=315640748">iTunes</a>.  Enjoy!</p>
<h2>Welcome to ActionScript 3</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1000"><img class="size-full wp-image-3744 alignnone" title="Welcome to ActionScript 3.0" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/why-actionscript-3.png" alt="Welcome to ActionScript 3.0" width="500" height="280" /></a></p>
<p>Doug Winnie gives an overview of his new series in which you will learn the fundamentals of ActionScript 3.0. Get up and running in Flash Professional using ActionScript 3.0.</p>
<h2>Working with the Actions Panel</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1003"><img class="size-full wp-image-3745 alignnone" title="Working with the ActionScript Panel" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/working-actionscript-panel.png" alt="Working with the ActionScript Panel" width="500" height="280" /></a></p>
<p>Understand how to use the Actions panel and use the trace statement. Doug Winnie walks you through the code to control objects created in Flash.</p>
<h2>Accessing Object Parameters</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1001"><img class="alignnone size-full wp-image-3733" title="Accessing Object Parameters" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/accessing-object-parameters.png" alt="Accessing Object Parameters" width="500" height="280" /></a></p>
<p>Doug Winnie demonstrates how to access properties of an object such as size and location by using instance properties with ActionScript, sending messages to the output console.</p>
<h2>Changing Object Parameters</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1002"><img class="alignnone size-full wp-image-3735" title="Changing Object Parameters" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/changing-object-parameters.png" alt="Changing Object Parameters" width="500" height="280" /></a></p>
<p>In order to manipulate objects, Doug Winnie uses the assignment operator in ActionScript 3.0 to instantaneously overwrite values initially assigned in Flash.</p>
<h2>Exploring Named Library Assets</h2>
<p><img class="alignnone size-full wp-image-3739" title="Exploring Named Library Assets" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/exploring-named-lbrary-assets.png" alt="Exploring Named Library Assets" width="500" height="280" /></p>
<p>Dive deeper with the Library panel and learn more about how to name instances on the stage, and how to use the Linkage panel to name objects in the Library panel.</p>
<h2>Adding Named Objects to the Stage</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1005"><img class="alignnone size-full wp-image-3734" title="Adding Named Objects to the Stage  // Image" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/adding-named-objects-stage.png" alt="Adding Named Objects to the Stage  // Image" width="500" height="280" /></a></p>
<p>In this video, Doug Winnie teaches you how to use ActionScript to dynamically add objects to the stage using code and the DisplayStack.</p>
<h2>Working with Comments</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1004"><img class="alignnone size-full wp-image-3731" title="Working with Comments" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/working-with-comments.png" alt="Working with Comments" width="500" height="280" /></a></p>
<p>You can use comments to document your ActionScript code for other Developers to use. Doug&#8217;s tutorial sums up the benefit of building up good coding practices.</p>
<h2>Fundamentals of Functions</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1007"><img class="alignnone size-full wp-image-3740" title="Fundamentals of Functions" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/fundamentals-of-functions.png" alt="Fundamentals of Functions" width="500" height="280" /></a></p>
<p>Doug Winnie provides an introduction to functions and explains how to efficiently use them in ActionScript by grouping commonly used tasks together as a named function.</p>
<h2>Accepting Values in Functions</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1008"><img class="alignnone size-full wp-image-3732" title="Accepting Values in Functions" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/accepting-values-in-functions.png" alt="Accepting Values in Functions" width="500" height="280" /></a></p>
<p>Doug continues his tutorial on how to efficiently use functions with ActionScript. With functions you can customize their functionality by assigning parameters and values.</p>
<h2>Returning Values from Functions</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1009"><img class="alignnone size-full wp-image-3743" title="Returning Values from Functions" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/returning-values-functions.png" alt="Returning Values from Functions" width="500" height="280" /></a></p>
<p>Doug Winnie wraps up his lesson on functions by explaining how to retrieve results for the output panel with the return statement.</p>
<h2>Mathematical Operators</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1010"><img class="alignnone size-full wp-image-3741" title="Mathematical Operators" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/mathematical-operators.png" alt="Mathematical Operators" width="500" height="280" /></a></p>
<p>Doug Winnie teaches the basics of calculating mathematical operations in ActionScript code, including commonly used shortcuts to save coding time.</p>
<h2>Order of Mathematical Operations</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1011"><img class="alignnone size-full wp-image-3742" title="Order of Mathematical Operations" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/order-mathematical-operators.png" alt="Order of Mathematical Operations" width="500" height="280" /></a></p>
<p>In this video, Doug Winnie reviews how Flash calculates math based on a specific order of operations.</p>
<h2>Events and MouseEvent Handlers</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1012"><img class="alignnone size-full wp-image-3738" title="Events and MouseEvent Handlers" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/events-mouseevents-handlers.png" alt="Events and MouseEvent Handlers" width="500" height="280" /></a></p>
<p>Discover the power of events and how you can quickly and easily build event handlers. In this episode, Doug covers how to use events to build interactivity with the mouse.</p>
<h2>Create a Timer</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1013"><img class="alignnone size-full wp-image-3737" title="Create a Timer" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/create-a-timer.png" alt="Create a Timer" width="500" height="280" /></a></p>
<p>Using your advanced knowledge of ActionScript, Doug Winnie walks you through on how to combine time events with event listeners to create and control time-based events.</p>
<h2>Create a Clock</h2>
<p><a href="http://tv.adobe.com/#vi+f15914v1014"><img class="alignnone size-full wp-image-3736" title="Create a Clock" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/08/create-a-clock.png" alt="Create a Clock" width="500" height="280" /></a></p>
<p>See Doug build a clock in Flash using ActionScript to manipulate objects&#8217; properties and add mouse and timer events. Everything you&#8217;ve learned from his tutorials is combined into one project.</p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/actionscript-11-getting-intimate-with-actionscript-30/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>ActionScript 3 Migration Cookbook</title>
		<link>http://flashspeaksactionscript.com/actionscript-3-migration-cookbook/</link>
		<comments>http://flashspeaksactionscript.com/actionscript-3-migration-cookbook/#comments</comments>
		<pubDate>Mon, 27 Apr 2009 15:00:44 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[freebie]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3503</guid>
		<description><![CDATA[The community's cry for a simple guide that would quickly go over some of the most felt changes from AS2 to AS3 has been heard.  Adobe has recently added a new resource to the ActionScript Center called the <a title="ActionScript 3 migration cookbook" href="http://www.adobe.com/devnet/actionscript/cookbook/" target="_blank">ActionScript 3 Migration Cookbook</a>.]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Factionscript-3-migration-cookbook%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22ActionScript%203%20Migration%20Cookbook%20%23AS2%20to%20AS3%20%23freebie%22%20%7D);"></div>
<p>The community&#8217;s cry for a simple guide that would quickly go over some of the most felt changes from AS2 to AS3 has been heard.  Adobe has recently added a new resource to the ActionScript Center called the <a title="ActionScript 3 migration cookbook" href="http://www.adobe.com/devnet/actionscript/cookbook/" target="_blank">ActionScript 3 Migration Cookbook</a>.</p>
<p>There you will find a quick introduction to migrating to ActionScript 3.0 from ActionScript 2.0.  It is targeted at designers and developers who have some experience scripting content within Adobe Flash CS4 Professional. It does not require an understanding of object-oriented programming.</p>
<p>Along with this resource of common AS2 code into AS3 conversions is a a downloadable PDF version which basically takes this section of the Devent site and dumps it into a portable version. Overall, this is a nice guide that can provide that helping hand during the first stages of the migration over to AS3.</p>
<p><strong>Download the <a href="http://www.adobe.com/devnet/actionscript/articles/as3_migration_cookbook/as3_migration_cookbook.pdf">ActionScript 3 migration cookbook</a></strong></p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/actionscript-3-migration-cookbook/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>10 Books to Help in Learning AS3</title>
		<link>http://flashspeaksactionscript.com/10-books-to-help-in-learning-as3/</link>
		<comments>http://flashspeaksactionscript.com/10-books-to-help-in-learning-as3/#comments</comments>
		<pubDate>Fri, 24 Apr 2009 12:00:54 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[Book]]></category>
		<category><![CDATA[roundup]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3442</guid>
		<description><![CDATA[<p>While not all our paths to learning ActionScript 3.0 are the same, the resources that are provided to us are.   Some like taking that direct dive into it and learn from their mistakes.  Others would prefer to learn through someone else's following.  I have compiled a<strong> list of the 10 books</strong> that may possibly help you learn and/or expand your knowledge of  ActionScript 3.0.</p>
]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252F10-books-to-help-in-learning-as3%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%2210%20Books%20to%20Help%20in%20Learning%20AS3%20%23AS2%20to%20AS3%20%23Book%20%23roundup%22%20%7D);"></div>
<p>While not all our paths to learning ActionScript 3.0 are the same, the resources that are provided to us are. Some like taking that direct dive into it and learn from their mistakes. Others would prefer to learn through someone else&#8217;s following. I have compiled a list of the 10 books that may possibly help you learn and/or expand your knowledge of ActionScript 3.0.<br />
<object id="Player_dd0d3b54-be26-40c0-9a88-3ec36855677c" width="430" height="324" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="data" value="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&amp;MarketPlace=US&amp;ID=V20070822%2FUS%2Fflashspeakact-20%2F8003%2Fdd0d3b54-be26-40c0-9a88-3ec36855677c&amp;Operation=GetDisplayTemplate" /><param name="quality" value="high" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&amp;MarketPlace=US&amp;ID=V20070822%2FUS%2Fflashspeakact-20%2F8003%2Fdd0d3b54-be26-40c0-9a88-3ec36855677c&amp;Operation=GetDisplayTemplate" /><embed id="Player_dd0d3b54-be26-40c0-9a88-3ec36855677c" width="430" height="324" type="application/x-shockwave-flash" src="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&amp;MarketPlace=US&amp;ID=V20070822%2FUS%2Fflashspeakact-20%2F8003%2Fdd0d3b54-be26-40c0-9a88-3ec36855677c&amp;Operation=GetDisplayTemplate" data="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&amp;MarketPlace=US&amp;ID=V20070822%2FUS%2Fflashspeakact-20%2F8003%2Fdd0d3b54-be26-40c0-9a88-3ec36855677c&amp;Operation=GetDisplayTemplate" quality="high" allowscriptaccess="always" /></object></p>
<p><noscript>&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;lt;A HREF=&#8221;http://ws.amazon.com/widgets/q?ServiceVersion=20070822&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;MarketPlace=US&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;ID=V20070822%2FUS%2Fflashspeakact-20%2F8003%2Fdd0d3b54-be26-40c0-9a88-3ec36855677c&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;Operation=NoScript&#8221; mce_HREF=&#8221;http://ws.amazon.com/widgets/q?ServiceVersion=20070822&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;MarketPlace=US&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;ID=V20070822%2FUS%2Fflashspeakact-20%2F8003%2Fdd0d3b54-be26-40c0-9a88-3ec36855677c&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;Operation=NoScript&#8221;&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;gt;Amazon.com Widgets&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;lt;/A&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;amp;gt;</noscript></p>
<h3><a title="Learning ActionScript 3.0" href="http://www.amazon.com/gp/product/059652787X?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=059652787X" target="_blank"><img class="alignleft size-full wp-image-3485" title="Learning ActionScript 3.0" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/learning-actionscript-3.jpg" alt="Learning ActionScript 3.0" width="80" height="97" /></a><a title="Learning ActionScript 3.0" href="http://www.amazon.com/gp/product/059652787X?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=059652787X" target="_blank">Learning ActionScript 3.0: A Beginner&#8217;s Guide</a></h3>
<p>Written for those of you new to ActionScript 3.0, the book describes how ActionScript and Flash work, giving you a clear look into essential topics such as logic, event handling, displaying content, migrating legacy projects to ActionScript 3.0, classes, and much more. You will learn important techniques through hands-on exercises, and then build on those skills as chapters progress.</p>
<h3><a title="Essential ActionScript 3.0" href="http://www.amazon.com/gp/product/0596526946?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596526946" target="_blank"><img class="alignleft size-full wp-image-3482" title="Essential ActionScript 3.0" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/essential-actionscript-3.jpg" alt="Essential ActionScript 3.0" width="80" height="105" /></a><a title="Essential ActionScript 3.0" href="http://www.amazon.com/gp/product/0596526946?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596526946" target="_blank">Essential ActionScript 3.0</a></h3>
<p>ActionScript 3.0 is a huge upgrade to Flash&#8217;s programming language. The enhancements to ActionScript&#8217;s performance, feature set, ease of use, cleanliness, and sophistication are considerable. Essential ActionScript 3.0 focuses on the core language and object-oriented programming, along with the Flash Player API. Essential ActionScript has become the #1 resource for the Flash and ActionScript development community, and the reason is the author, Colin Moock.</p>
<h3><a title="Object-Oriented ActionScript 3.0" href="http://www.amazon.com/gp/product/1590598458?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=1590598458" target="_blank"><img class="alignleft size-full wp-image-3486" title="Object-Oriented ActionScript 3.0" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/object-oriented-actionscript-3.jpg" alt="Object-Oriented ActionScript 3.0" width="80" height="96" /></a><a title="Object-Oriented ActionScript 3.0" href="http://www.amazon.com/gp/product/1590598458?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=1590598458" target="_blank">Object-Oriented ActionScript 3.0</a></h3>
<p>Object-oriented programming (OOP) is something that is usually considered a black art for hardcore programmers, not a topic of conversation for Flash developers. However, when adobe introduced ActionScript 3.0 to the mix, it changed everything. ActionScript 3.0 is much more powerful than previous versions, allowing Flash developers to produce robust object-oriented applications.</p>
<h3><a title="ActionScript 3.0 Design Patterns" href="http://www.amazon.com/gp/product/0596528469?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596528469" target="_blank"><img class="alignleft size-full wp-image-3479" title="ActionScript 3.0 Design Patterns" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/actionscript-3-design-patterns.jpg" alt="ActionScript 3.0 Design Patterns" width="80" height="105" /></a><a title="ActionScript 3.0 Design Patterns" href="http://www.amazon.com/gp/product/0596528469?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596528469" target="_blank">ActionScript 3.0 Design Patterns: Object Oriented Programming Techniques</a></h3>
<p>Now that ActionScript is reengineered from top to bottom as a true object-oriented programming (OOP) language, reusable design patterns are an ideal way to solve common problems in Flash and Flex applications. If you&#8217;re an experienced Flash or Flex developer ready to tackle sophisticated programming techniques with ActionScript 3.0, this hands-on introduction to design patterns is the book you need.</p>
<h3><a title="The ActionScript 3.0 Quick Reference Guide" href="http://www.amazon.com/gp/product/0596517351?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596517351" target="_blank"><img class="alignleft size-full wp-image-3481" title="ActionScript 3.0 Reference Guide" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/actionscript-3-reference-guide.gif" alt="ActionScript 3.0 Reference Guide" width="80" height="120" /></a><a title="The ActionScript 3.0 Quick Reference Guide" href="http://www.amazon.com/gp/product/0596517351?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596517351" target="_blank">The ActionScript 3.0 Quick Reference Guide</a></h3>
<p>This guide is designed specifically to help Flash designers and developers make the leap from ActionScript 2.0 to the new object-oriented ActionScript 3.0 quickly and painlessly. Formatted so you can find any topic easily.  ActionScript 3.0 Quick Reference Guide explains: Object-oriented programming (OOP) concepts, such as packages and classes ActionScript 3.0 features and player enhancements that improve performance.  Workflow differences between ActionScript 2.0 and ActionScript 3.0 including tools, code editing, component sets,etc.</p>
<h3><a title="ActionScript 3.0 Bible" href="http://www.amazon.com/gp/product/0470135603?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0470135603" target="_blank"><img class="alignleft size-full wp-image-3477" title="ActionScript3.0 Bible" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/actionscript-3-bible.jpg" alt="ActionScript3.0 Bible" width="80" height="107" /></a><a title="ActionScript 3.0 Bible" href="http://www.amazon.com/gp/product/0470135603?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0470135603" target="_blank">ActionScript 3.0 Bible</a></h3>
<p>ActionScript has matured into a full-fledged, object-oriented programming language for creating cutting-edge Web applications, and this comprehensive book is just what you need to succeed.  If you want to addinteractivity to Flash, build Flex applications, or work with animation — it&#8217;s all here, and more. Packed with clear instruction, step-by-step tutorials, and advanced techniques, this book is your go-to guide to unlock the power of this amazing language. Learn the basics, apply object-oriented programming, and more.</p>
<h3><a title="The ActionScript 3.0 Migration Guide" href="http://www.amazon.com/gp/product/0321555589?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0321555589" target="_blank"><img class="alignleft size-full wp-image-3480" title="ActionAcript 3.0 Migration Guide" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/actionscript-3-migration-guide.jpg" alt="ActionAcript 3.0 Migration Guide" width="80" height="98" /></a><a title="The ActionScript 3.0 Migration Guide" href="http://www.amazon.com/gp/product/0321555589?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0321555589" target="_blank">The ActionScript 3.0 Migration Guide: Making the Move from ActionScript 2.0</a></h3>
<p>In this essential and timely guide, ActionScript expert Kris Hadlock speaks squarely to the many thousands of ActionScript 2.0 users who need to make the leap right away. The ActionScript Migration Guide covers all of the major changes in ActionScript from version 2 to 3. The book explains the most important and fundamental changes in ActionScript drawing comparisons between the two languages both visually and contextually.</p>
<h3><a title="Foundation ActionScript 3.0" href="http://www.amazon.com/gp/product/1590598156?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=1590598156" target="_blank"><img class="alignleft size-full wp-image-3494" title="Foundation ActionScript 3.0" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/foundation-actionscript-3.jpg" alt="Foundation ActionScript 3.0" width="80" height="96" /></a><a title="Foundation ActionScript 3.0" href="http://www.amazon.com/gp/product/1590598156?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=1590598156" target="_blank">Foundation ActionScript 3.0 with Flash CS3 and Flex</a></h3>
<p>This book covers all the essential techniques from the ground up, allowing you to get up and running quickly and easily. Starting with the fundamentals, youll learn about using ActionScript objects, manipulating sound and video, and harnessing the power of regular expressions and XML.  The book concludes with two case studies to consolidate what you&#8217;ve learned and to introduce some more advanced techniques.</p>
<h3><a title="ActionScript 3.0 Bible" href="http://www.amazon.com/gp/product/0596526954?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596526954" target="_blank"><img class="alignleft size-full wp-image-3491" title="ActionScript 3.0 Cookbook" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/actionscript-3-cookbook1.jpg" alt="ActionScript 3.0 Cookbook" width="80" height="105" /></a><a title="ActionScript 3.0 Cookbook" href="http://www.amazon.com/gp/product/0596526954?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=0596526954" target="_blank">ActionScript 3.0 Cookbook</a></h3>
<p>Each code recipe presents the Problem, Solution, and Discussion of how you can use it in other ways or personalize it for your own needs, and why it works. You can quickly locate the recipe that most closely matches your situation and get the solution without reading the whole book to understand the underlying code.  Solutions progress from short recipes for small problems to more complex scripts for thornier riddles, and the discussions offer a deeper analysis for resolving similar issues in the future.</p>
<h3><a title="Foundation ActionScript 3.0 Animation" href="http://www.amazon.com/gp/product/1590597915?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=1590597915" target="_blank"><img class="alignleft size-full wp-image-3484" title="Foundation ActionScript 3.0 Animation" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/04/foundation-actionscript-3-animation.jpg" alt="Foundation ActionScript 3.0 Animation" width="80" height="96" /></a><a title="Foundation ActionScript 3.0 Animation" href="http://www.amazon.com/gp/product/1590597915?ie=UTF8&amp;tag=flashspeakact-20&amp;link_code=as3&amp;camp=211189&amp;creative=373489&amp;creativeASIN=1590597915" target="_blank">Foundation Actionscript 3.0 Animation: Making Things Move!</a></h3>
<p>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.</p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/10-books-to-help-in-learning-as3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Why ActionScript 3.0?</title>
		<link>http://flashspeaksactionscript.com/why-actionscript-30/</link>
		<comments>http://flashspeaksactionscript.com/why-actionscript-30/#comments</comments>
		<pubDate>Tue, 14 Apr 2009 18:00:14 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[Videos]]></category>
		<category><![CDATA[AS3]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3426</guid>
		<description><![CDATA[With all the recent developments with 3rd party libraries being supported in AS3, I am still shocked to see people still asking the question "Why <span><span>ActionScript</span></span> 3.0?".  I simply do not get it as AS3 presents so many more cons than pros.

It is almost as if <span><span>ActionScript</span></span> 3.0 is the monster in the closet that some people would rather just avoid then confront.   For those who have migrated over, we have found out that it is not the infamous monster in the closet.  Instead, it turned out to be a hanging sweater casting a monstrous shadow.

For those still asking themselves the question of  "Why <span><span>ActionScript</span></span> 3.0?", check out this <span>parody</span> video on the topic.  Cracks me up every time!]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Fwhy-actionscript-30%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22Why%20ActionScript%203.0%3F%20%23AS2%20to%20AS3%20%23AS3%20%23Videos%22%20%7D);"></div>
<p>With all the recent developments with <a title="Adobe Releases the New AS3 Facebook API" href="http://flashspeaksactionscript.com/adobe-releases-the-new-as3-facebook-api/" target="_self">3rd party libraries being supported in AS3</a>, I am still shocked to see people still asking the question &#8220;Why ActionScript 3.0?&#8221;.  I simply do not get it as AS3 presents so many more pros than cons.</p>
<p>It is almost as if ActionScript 3.0 is the monster in the closet that some people would rather just avoid then confront.   For those who have migrated over, we have found out that it is not the infamous monster in the closet.  Instead, it turned out to be a hanging sweater casting a monstrous shadow.</p>
<p>For those still asking themselves the question of  &#8220;Why ActionScript 3.0?&#8221;, check out this parody video on the topic.  Cracks me up every time!</p>
<p><span style="text-align:center; display: block;"><a href="http://flashspeaksactionscript.com/why-actionscript-30/"><img src="http://img.youtube.com/vi/SVm5NW__sxk/2.jpg" alt="" /></a></span></p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/why-actionscript-30/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Moving From AS2 to AS3: Creating Dynamic Masks</title>
		<link>http://flashspeaksactionscript.com/moving-from-as2-to-as3-creating-dynamic-masks/</link>
		<comments>http://flashspeaksactionscript.com/moving-from-as2-to-as3-creating-dynamic-masks/#comments</comments>
		<pubDate>Mon, 30 Mar 2009 18:00:21 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[AS3]]></category>
		<category><![CDATA[Beginner]]></category>
		<category><![CDATA[masking]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3396</guid>
		<description><![CDATA[Dynamic mask objects have been key to many Flash project's success. When it comes to migrating over from AS2 to AS3, you'll find that things have changed as the method "setMask()" in AS2 is now a property called "mask".   In this next edition of the Moving From AS2 to AS3 series, I will be comparing the two solutions and offering an efficient solution to creating dynamic masks using AS3.]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Fmoving-from-as2-to-as3-creating-dynamic-masks%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22Moving%20From%20AS2%20to%20AS3%3A%20Creating%20Dynamic%20Masks%20%23AS2%20to%20AS3%20%23AS3%20%23Beginner%20%23masking%22%20%7D);"></div>
<p>Dynamic mask objects have been key to many Flash project&#8217;s success. When it comes to migrating over from AS2 to AS3, you&#8217;ll find that things have changed as the method &#8220;setMask()&#8221; in AS2 is now a property called &#8220;mask&#8221;. In this next edition of the <a title="Moving From AS2 to AS3: A Handy List of Resources" href="http://flashspeaksactionscript.com/as2-to-as3-handy-list-of-resources/" target="_self">Moving From AS2 to AS3 series</a>, I will be comparing the two solutions and offering an efficient solution to creating dynamic masks using AS3.</p>
<h2>Comparing AS2 to AS3</h2>
<h3>Setting masks dynamically using ActionScript 2.0</h3>
<pre class="brush: as3; title: ; notranslate">myMC.setMask(maskObject);</pre>
<h3>Setting masks dynamically using ActionScript 3.0</h3>
<pre class="brush: as3; title: ; notranslate">myMC.mask = maskObject;</pre>
<p>So as you can see the syntax hasn&#8217;t changed much, however, personally I feel that AS3&#8242;s implementation is a bit more literal making it easier to understand.</p>
<h2>Creating your masking objects as Sprites</h2>
<p>While in ActionScript 2.0 there was no better of a solution than to create your masking object as a MovieClip. With the introduction of the Sprite object in ActionScript 3.0, creating your masking objects as Sprites is a far more efficient solution.</p>
<p>Since a mask object does not require a timeline, using a Sprite instead of a MovieClip simply makes more sense. Below is an example where a Sprite is used in place of a MovieClip:</p>
<pre class="brush: as3; title: ; notranslate">// Create mask
var maskObject:Sprite = new Sprite();
maskObject.graphics.beginFill(0xFF0000);
maskObject.graphics.drawRoundRect(myMC.x, myMC.y, 453, 290, 20);

// Apply mask
myMC.mask = maskObject;</pre>
<h3><a title="Download Example File" href="http://flashspeaksactionscript.com/files/dynamic-masks-as3/dynamic-mask-as3.zip" target="_blank">Download Example File</a></h3>
<p><em>I hope this helps in your migration over into  AS3.  If there is something in particular you want to add or see with the Moving From AS2 to AS3 series, feel free to contact me via the <a title="Contact Us" href="../contact/" target="_self">contact page</a>. </em></p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/moving-from-as2-to-as3-creating-dynamic-masks/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Moving From AS2 to AS3: Handling Depths</title>
		<link>http://flashspeaksactionscript.com/moving-from-as2-to-as3-handling-depths/</link>
		<comments>http://flashspeaksactionscript.com/moving-from-as2-to-as3-handling-depths/#comments</comments>
		<pubDate>Mon, 16 Mar 2009 16:00:25 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[Beginner]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3371</guid>
		<description><![CDATA[Managing depths in AS2 was pretty annoying and time consuming. You'd spend so much time dedicating depth ranges for MovieClip groups, but in the end the limitations of AS2 really got the last laugh. Who's laughing now?]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Fmoving-from-as2-to-as3-handling-depths%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22Moving%20From%20AS2%20to%20AS3%3A%20Handling%20Depths%20%23AS2%20to%20AS3%20%23Beginner%22%20%7D);"></div>
<p>Managing depths in AS2 was pretty annoying and time consuming.  You&#8217;d spend so much time dedicating depth ranges for MovieClip groups, but in the end the limitations of AS2 really got the last laugh.  Who&#8217;s laughing now?</p>
<h2>Improving upon handling depths</h2>
<p>With the introduction of Flash Player 9 and ActionScript 3.0, Adobe created an easy and powerful way to add, remove, and change MovieClips on the screen. It&#8217;s is called the display list.</p>
<h2>Understanding the Display List</h2>
<p>Basically, the role of the display list is to handle managing where your MovieClips are placed in depth when visually adding them to the Flash stage.  To learn more on this topic, the Yahoo Flash Developer  has a thorough introduction article to <a title="Introduction to the Display List" href="http://developer.yahoo.com/flash/articles/display-list.html" target="_blank">understanding the display list</a>.</p>
<h2>What happened to swapDepths and getNextHighestDepth?</h2>
<p>The <strong>swapDepths()</strong> and <strong>getNextHighestDepth()</strong> methods no longer exist in ActionScript 3.0.  Instead you would rely using the <a title="ActionScript 3.0 Language and Components Reference" href="http://help.adobe.com/en_US/AS3LCR/Flash_10.0/flash/display/DisplayObjectContainer.html" target="_blank">DisplayObjectContainer</a> methods associated with a MovieClip added to the display list.</p>
<h2>Swapping depths using AS2</h2>
<pre class="brush: as3; title: ; notranslate">function arrangeBoxes():Void {
    for (var i:Number = 0; i &lt; 3; i++) {
        //Attaching the MC from th library for the duration of the loop
        var box:MovieClip = this.attachMovie(&quot;box&quot;, &quot;box&quot; + i + &quot;_mc&quot;, this.getNextHighestDepth(), {_x: ((i * 80) + 100), _y: 100});
        var boxColor:Color=new Color(box);
        boxColor.setRGB(Math.random() * 0xFFFFFF);
        box.onRollOver = function():Void
        {
        //Focused box will achieve to the next highest depth
        this.swapDepths(this._parent.getNextHighestDepth());
        };
    }
}
arrangeBoxes();</pre>
<p>If you noticed in the AS2 solution, we are basically making the interacted object obtain the next highest depth available on the stage.  Sounds correct and automated but there is nothing really stopping this from reaching a depth of 9999 with only 3 objects on stage.  Basically, this is no where near an efficient solution to depth swapping.</p>
<h2>Swapping depths using AS3</h2>
<pre class="brush: as3; title: ; notranslate">function arrangeBoxes():void {
    //For loop will create and place three boxes onto the stage
    for (var i:int = 0; i &lt; 3; i++) {
        var boxColor:ColorTransform = new ColorTransform();
        boxColor.color = (Math.random() * 0xFFFFFF);
        //Define a new box to be added to the stage
        var box:Box = new Box();
        box.x = ((i * 80) + box.width);
        box.y=100;
        box.transform.colorTransform=boxColor;
        box.buttonMode=true;
        box.addEventListener(MouseEvent.MOUSE_OVER, swapMyDepth);
        this.addChild(box);
    }
}

function swapMyDepth(evt:MouseEvent):void {
	this.setChildIndex(Box(evt.target), (this.numChildren - 1));
}

arrangeBoxes();
</pre>
<p>I am just amazed at how much easier and efficient the swapping depth syntax appears in AS3.  In the case of ActionScript 3.0, this solution literally swaps the depth of targeted objects.  There is no &#8220;false advertising&#8221; of swapping depths.</p>
<p>Overall, there is very little left for the designer/developer to manage when dealing with object depth. One less headache to deal with.  Phewww!</p>
<h3><a title="Download source" href="http://flashspeaksactionscript.com/files/swapping-depths-cs3.zip" target="_blank">Download source</a></h3>
<h2>Feedback:</h2>
<p><em>I</em><em> hope this helps in your migration over into  AS3.  If there is something in particular you want to add or see with the Moving From AS2 to AS3 series, feel free to contact me via the <a title="Contact Us" href="../contact/" target="_self">contact page</a>. </em></p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/moving-from-as2-to-as3-handling-depths/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>The Timeline Is Not Evil!</title>
		<link>http://flashspeaksactionscript.com/the-timeline-is-not-evil/</link>
		<comments>http://flashspeaksactionscript.com/the-timeline-is-not-evil/#comments</comments>
		<pubDate>Tue, 10 Mar 2009 13:00:19 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3326</guid>
		<description><![CDATA[There seems to be this misconception that adding ActionScript in the Timeline will not be supported when using AS3.  <strong>FALSE!!!</strong> If you are migrating over from AS2 to AS3, adding ActionScript in the Timeline is probably the least of your concerns.]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Fthe-timeline-is-not-evil%252F%22%2C%20%22shorturl%22%3A%20%22http%3A%2F%2Fbit.ly%2Fr9lkY4%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22The%20Timeline%20Is%20Not%20Evil%21%20%23AS2%20to%20AS3%22%20%7D);"></div>
<p>There seems to be this misconception that adding ActionScript in the Timeline will not be supported when using AS3. <strong>FALSE!!!</strong> If you are migrating over from AS2 to AS3, adding ActionScript in the Timeline is probably the least of your concerns.</p>
<p>The concept of inserting ActionScript to control or trigger animations has not changed from AS2 to AS3. While inserting all of your ActionScript code throughout the Timeline is not recommended, doing so will not break any functionality.</p>
<p>There are many other <a title="Here are Six Reasons to Use ActionScript 3.0" href="http://flashspeaksactionscript.com/here-are-six-reasons-to-use-actionscript-30/" target="_blank">misconceptions dealing with migrating over from AS2 to AS3</a>. Mike Chambers recently spoke on this topic at <a href="http://www.flashcamp.co.uk/">FlashCamp</a> in London. Unfortunately like most, I was not able to be there. However, Mike has made the slideshow of his presentation available for download. You can see it below.</p>
<p><object width="425" height="375" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="data" value="https://share.acrobat.com/adc/flex/mpt.swf" /><param name="quality" value="high" /><param name="wmode" value="transparent" /><param name="allowFullScreen" value="true" /><param name="flashvars" value="ext=pdf&amp;docId=d305d49f-0ebe-4f2e-8f5b-9608fc2171d0&amp;lang=en_US" /><param name="src" value="https://share.acrobat.com/adc/flex/mpt.swf" /><param name="allowfullscreen" value="true" /><embed width="425" height="375" type="application/x-shockwave-flash" src="https://share.acrobat.com/adc/flex/mpt.swf" data="https://share.acrobat.com/adc/flex/mpt.swf" quality="high" wmode="transparent" allowFullScreen="true" flashvars="ext=pdf&amp;docId=d305d49f-0ebe-4f2e-8f5b-9608fc2171d0&amp;lang=en_US" allowfullscreen="true" /></object></p>
<h2>Feedback:</h2>
<p>If you are currently trying to make that switch from AS2 to AS3, what&#8217;s stopping you?  What&#8217;s keeping you up at night? I would love to hear from you if somthing is keeping you up at night.</p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/the-timeline-is-not-evil/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Playing, Stopping, and Pausing Sounds Using AS3</title>
		<link>http://flashspeaksactionscript.com/playing-stopping-and-pausing-sounds-using-as3/</link>
		<comments>http://flashspeaksactionscript.com/playing-stopping-and-pausing-sounds-using-as3/#comments</comments>
		<pubDate>Mon, 09 Mar 2009 23:00:32 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[Beginner]]></category>
		<category><![CDATA[Sound]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3306</guid>
		<description><![CDATA[<p>In a previous tutorial, I demonstrated a simple solution to loading an external sound file. In that example, the mp3 file that had been loaded begins to play automatically. While this might be fine in some cases, you probably would want more control over the sound being imported. For example, being able to stop or pause then play again might be a good place to start.     In this tutorial, I will be demonstrating how to <strong>play</strong>, <strong>stop</strong>, and <strong>pause sounds</strong> using AS3 once you have the sound loaded into Flash.</p>
]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Fplaying-stopping-and-pausing-sounds-using-as3%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22Playing%2C%20Stopping%2C%20and%20Pausing%20Sounds%20Using%20AS3%20%23AS2%20to%20AS3%20%23Beginner%20%23Sound%22%20%7D);"></div>
<p>In a previous tutorial, I demonstrated a <a title="Loading External Sounds Using AS3" href="http://flashspeaksactionscript.com/loading-external-sounds-using-as3/" target="_self">simple solution to loading an external sound file</a>.  In that example, the mp3 file that had been loaded begins to play automatically.  While this might be fine in some cases, you probably would want more control over the sound being imported.</p>
<p>For example, being able to stop or pause then play again might be a good place to start.    In this tutorial, I will be demonstrating how to <strong>play</strong>, <strong>stop</strong>, and <strong>pause sounds</strong> using AS3 once you have the sound loaded into Flash.</p>
<h2>Playing a sound</h2>
<p>Playing a sound using AS3 is a simple as calling the <strong>play()</strong> method of the defined sound object.  Previously in AS2, you would have called the <strong>start()</strong> method so not much different in this area.</p>
<pre class="brush: as3; title: ; notranslate">soundClip.play();</pre>
<h2>Stopping a sound</h2>
<p>Stopping a sound using AS3 is accomplished by calling the <strong>stop()</strong> method of the defined sound object.  This is exactly the same way you would be able to handle it using AS2.</p>
<pre class="brush: as3; title: ; notranslate">soundClip.stop();</pre>
<h2>Pausing a sound</h2>
<p>This is where pausing a sound using AS3 is quite different from using AS2.  As it stands now, there is no method to automatically pause a sound using AS3.  Instead, you must populate an optional parameter of the <strong>play()</strong> method.</p>
<p>It allows you to play the sound using an offset value that is passed in from a stored variable.  Below is an example of accomplishing this.</p>
<pre class="brush: as3; title: ; notranslate">
//Stores the position of the &quot;playback head&quot;
var pausePosition:Number = sndChannel.position;
sndChannel.stop();

//When ready to resume playback, call this line
sndChannel = soundClip.play(pausePosition);</pre>
<h2>Putting it all together</h2>
<p><a title="Playing, Stopping, and Pausing Sounds" rel="shadowbox;height=150;width=300" href="http://www.flashspeaksactionscript.com/files/play-pause-sound/stop-pause-sound-as3.swf"><img class="alignleft size-full wp-image-3310" style="margin-top: 5px; margin-bottom: 5px;" title="Pause/Play Sound" src="http://flashspeaksactionscript.com/wp-content/uploads/2009/03/pause-play-sound.png" alt="Pause/Play Sound" width="200" height="149" /></a>Now it is time to integrate all three.  I have provided an example that puts all three of these control functionalities into good use.  The example is sessentially a simple music player with toggle functionality.</p>
<h3><a title="Preview source" rel="shadowbox;height=150;width=300" href="http://www.flashspeaksactionscript.com/files/play-pause-sound/stop-pause-sound-as3.swf" target="_blank">Preview example</a></h3>
<p><a title="Download source" href="http://www.flashspeaksactionscript.com/files/play-pause-sound/play-pause-source.zip" target="_blank">Download source</a></p>
<p><strong>Subscribe to the <a title="RSS Feed of Flash Speaks ActionScript" href="../feed/" target="_blank">RSS Feed</a> to stay updated on future tutorials on using sound in AS3. </strong></p>
<p><em>I</em><em> hope this helps in your migration over into  AS3.  If there is something in particular you want to add or see with the Moving From AS2 to AS3 series, feel free to contact me via the <a title="Contact Us" href="../contact/" target="_self">contact page</a>. </em></p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/playing-stopping-and-pausing-sounds-using-as3/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Filtering XML Data Using AS3</title>
		<link>http://flashspeaksactionscript.com/filtering-xml-data-using-as3/</link>
		<comments>http://flashspeaksactionscript.com/filtering-xml-data-using-as3/#comments</comments>
		<pubDate>Tue, 03 Mar 2009 20:00:15 +0000</pubDate>
		<dc:creator>Angel Romero</dc:creator>
				<category><![CDATA[AS2 to AS3]]></category>
		<category><![CDATA[Beginner]]></category>

		<guid isPermaLink="false">http://flashspeaksactionscript.com/?p=3291</guid>
		<description><![CDATA[Filtering data XML data using AS2 has to be one of the most sought out features when dealing XML-driven Flash projects. Being able to automatically grab certain relevant information without manually searching each and every XML node and/or attribute.

What if we were given the ability to create filters that will automatically pull the information needed from XML nodes and/or attributes. But wait we can't do that, right? Right, that is until the birth of ActionScript 3.0.]]></description>
			<content:encoded><![CDATA[<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fflashspeaksactionscript.com%252Ffiltering-xml-data-using-as3%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22Filtering%20XML%20Data%20Using%20AS3%20%23AS2%20to%20AS3%20%23Beginner%22%20%7D);"></div>
<p>Filtering data XML data using AS2 has to be one of the most sought out features when dealing with XML-driven Flash projects. Being able to automatically grab certain relevant information without manually searching each and every XML node and/or attribute.</p>
<p>What if we were given the ability to create filters that will automatically pull the information needed from XML nodes and/or attributes. But wait we can&#8217;t do that, right? Right, that is until the birth of ActionScript 3.0.</p>
<p>Another new feature in AS3 is the ability to<strong> filter and display</strong> only the data you are interested in. With this, you can dynamically filter XML nodes and attributes.</p>
<h3>Filtering XML Node Values</h3>
<p>Let&#8217;s say you wanted to pull all the of the books that were paperback. You can now create a function that scans each XML&#8217;s node or attribute value and returns which node would qualify with the given query. See the example below in which outputs the books in which are paperback.</p>
<p><em>Note: I am using this <a title="book-list.xml" href="http://www.flashspeaksactionscript.com/files/filtering-xml-as3/book-list.xml" target="_blank">XML file</a> in the example.</em></p>
<pre class="brush: as3; title: ; notranslate">
var xmlLoader:URLLoader=new URLLoader  ;
var xmlData:XML=new XML  ;
//Adding an event listener to notify when loading is completed
xmlLoader.addEventListener(Event.COMPLETE,LoadXML);
//Load the XML file
xmlLoader.load(new URLRequest(&quot;book-list.xml&quot;));

function LoadXML(e:Event):void {
	xmlData=new XML(e.target.data);
	ParseBooks(xmlData);
}

function ParseBooks(bookInput:XML):void {
	//Creating an xml list that will store the book info
	var books:XMLList=bookInput.book.children();
	//Creating a xml list that will store the book's ISBN number
	var bookAttributes:XMLList=bookInput.book.attributes();
	//Filter out all of the books with a &quot;Paperback&quot; cover
	var paperBackList:XMLList=bookInput.book.coverType==&quot;Paperback&quot;;
	trace(paperBackList);
}</pre>
<h2>Filtering XML Attributes</h2>
<p>Not only can you filter XML node values but you can do the same to XML Attributes values. In the a previous post , <a title="Loading XML Data Using AS3" href="http://flashspeaksactionscript.com/loading-xml-data-using-as3/" target="_blank">Loading XML Data</a>, I created and included an attribute labeled &#8220;ISBN&#8221; which would be available within each book node. If you wanted to return a list of books that matched a certain value, it would go something like this.</p>
<p><em>Note: I am simply replacing the ParseBooks function from the code above</em></p>
<pre class="brush: as3; title: ; notranslate">
function ParseBooks(bookInput:XML):void {
	//Creating an xml list that will store the book info
	var books:XMLList=bookInput.book.children();
	//Creating a xml list that will store the book's ISBN number
	var bookAttributes:XMLList=bookInput.book.attributes();
	//Filter out the book with a matching ISBN number
	var closeMatchList:XMLList=bookInput.book.@isbn==&quot;978-0596526948&quot;;
	trace(closeMatchList);
}</pre>
<p>As you can see, there isn&#8217;t much of a difference with filtering by XML node values or attribute information. Filtering can provide such a dynamic form of functionality to any Flash project: big or small.</p>
<h3><a title="Download Source" href="http://www.flashspeaksactionscript.com/files/filtering-xml-as3/download-source.zip" target="_blank">Download Source</a></h3>
<p><strong>I&#8217;d love to hear from you.  What do you think of this new functionality when dealing with XML data?</strong></p>
<h2>Feedback:</h2>
<p><em>I</em><em> hope this helps in your migration over into  AS3.  If there is something in particular you want to add or see with the Moving From AS2 to AS3 series, feel free to contact me via the <a title="Contact Us" href="../contact/" target="_self">contact page</a>. </em></p>
<p><em><strong>Subscribe to the <a title="RSS Feed of Flash Speaks ActionScript" href="http://feeds.feedburner.com/flashspeaksactionscript/tmgY" target="_blank">RSS Feed</a> to stay updated on future tutorials on using XML in AS3. </strong></em></p>
]]></content:encoded>
			<wfw:commentRss>http://flashspeaksactionscript.com/filtering-xml-data-using-as3/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced
Object Caching 1394/1465 objects using disk: basic

Served from: flashspeaksactionscript.com @ 2012-05-23 15:14:04 -->
