<?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>*drawlogic &#187; tweener</title>
	<atom:link href="http://drawlogic.com/tag/tweener/feed/" rel="self" type="application/rss+xml" />
	<link>http://drawlogic.com</link>
	<description>interactive and game development technologies for the web - flash, flex, unity3d, silverlight, javascript</description>
	<lastBuildDate>Thu, 22 Dec 2011 21:55:20 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>iTween Tweening and Easing Animation Library for Unity 3D</title>
		<link>http://drawlogic.com/2010/04/11/itween-tweening-and-easing-animation-library-for-unity-3d/</link>
		<comments>http://drawlogic.com/2010/04/11/itween-tweening-and-easing-animation-library-for-unity-3d/#comments</comments>
		<pubDate>Sun, 11 Apr 2010 23:38:46 +0000</pubDate>
		<dc:creator>drawk</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[JAVASCRIPT]]></category>
		<category><![CDATA[PROGRAMMING]]></category>
		<category><![CDATA[TECHNOLOGY]]></category>
		<category><![CDATA[3d]]></category>
		<category><![CDATA[ANIMATION]]></category>
		<category><![CDATA[easing]]></category>
		<category><![CDATA[itween]]></category>
		<category><![CDATA[tweener]]></category>
		<category><![CDATA[tweenlite]]></category>
		<category><![CDATA[unity]]></category>
		<category><![CDATA[unity3d]]></category>

		<guid isPermaLink="false">http://drawlogic.com/?p=772</guid>
		<description><![CDATA[iTween is a tweening kit for Unity that is in the same style as TweenLite, Tweener and others in the tween format that is common for flash tween libraries in Actionscript 3. This library is available in javascript and C# for Unity 3d Projects and is quite fast and solid. iTween is a simple one [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pixelplacement.com/iTween/"><img class="alignright" title="iTween for Unity" src="http://i81.photobucket.com/albums/j223/drawkbox/iTweenLogo.png" alt="" width="349" height="145" /></a><a href="http://www.pixelplacement.com/iTween/" target="_blank">iTween</a> is a tweening kit for Unity that is in the same style as <a href="http://www.greensock.com/tweenlite/" target="_blank">TweenLite</a>, <a href="http://code.google.com/p/tweener/" target="_blank">Tweener</a> and others in the tween format that is common for flash tween libraries in Actionscript 3. This library is available in <a href="http://www.pixelplacement.com/iTween/" target="_blank">javascript </a>and <a href="http://www.insquare.com/itween/" target="_blank">C#</a> for Unity 3d Projects and is quite fast and solid.</p>
<p>iTween is a simple one file drop in for some great scripted animation and easing that is very reminiscent of Flash using Penner equations and common libraries so it is easy to get started. It works for web player, desktop and iPhone Unity (however long that lasts).</p>
<p>Some sample code looks like this:</p>

<div class="wp_syntax"><div class="code"><pre class="csharp" style="font-family:monospace;"><span style="color: #0600FF; font-weight: bold;">private</span> GameObject go<span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">private</span> GameObject cam<span style="color: #008000;">;</span>
&nbsp;
<span style="color: #6666cc; font-weight: bold;">void</span> Awake<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span>
<span style="color: #008000;">&#123;</span>
    go <span style="color: #008000;">=</span> gameObject<span style="color: #008000;">;</span>
    cam <span style="color: #008000;">=</span> Camera<span style="color: #008000;">.</span><span style="color: #0000FF;">main</span><span style="color: #008000;">.</span><span style="color: #0000FF;">gameObject</span><span style="color: #008000;">;</span>
<span style="color: #008000;">&#125;</span>
&nbsp;
<span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">void</span> Start<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span>
<span style="color: #008000;">&#123;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">rotateFrom</span><span style="color: #008000;">&#40;</span>go, 1<span style="color: #008000;">.</span>5f, <span style="color: #FF0000;">0</span>, <span style="color: #0600FF; font-weight: bold;">null</span>, <span style="color: #FF0000;">90</span>, <span style="color: #0600FF; font-weight: bold;">null</span>, iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">EasingType</span><span style="color: #008000;">.</span><span style="color: #0000FF;">easeInExpo</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">moveFrom</span><span style="color: #008000;">&#40;</span>go, 1<span style="color: #008000;">.</span>5f, <span style="color: #FF0000;">0</span>, <span style="color: #0600FF; font-weight: bold;">null</span>, 3<span style="color: #008000;">.</span>5f, <span style="color: #0600FF; font-weight: bold;">null</span>, iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">EasingType</span><span style="color: #008000;">.</span><span style="color: #0000FF;">easeInExpo</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">colorTo</span><span style="color: #008000;">&#40;</span>go, <span style="color: #008000;">.</span>3f, 1<span style="color: #008000;">.</span>5f, <span style="color: #FF0000;">3</span>, <span style="color: #008000;">.</span>5f, 1<span style="color: #008000;">.</span>2f<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">shake</span><span style="color: #008000;">&#40;</span>cam, <span style="color: #008000;">.</span>8f, 1<span style="color: #008000;">.</span>5f, <span style="color: #0600FF; font-weight: bold;">null</span>, <span style="color: #008000;">.</span>3f, <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">scaleTo</span><span style="color: #008000;">&#40;</span>go, <span style="color: #FF0000;">2</span>, 2<span style="color: #008000;">.</span>3f, <span style="color: #0600FF; font-weight: bold;">null</span>, <span style="color: #FF0000;">2</span>, <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">rotateBy</span><span style="color: #008000;">&#40;</span>go, <span style="color: #0600FF; font-weight: bold;">null</span>, 4<span style="color: #008000;">.</span>3f, <span style="color: #008000;">.</span>5f, <span style="color: #0600FF; font-weight: bold;">null</span>, <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">moveTo</span><span style="color: #008000;">&#40;</span>go, <span style="color: #0600FF; font-weight: bold;">null</span>, 4<span style="color: #008000;">.</span>6f, <span style="color: #0600FF; font-weight: bold;">null</span>, 1<span style="color: #008000;">.</span>2f, <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">moveTo</span><span style="color: #008000;">&#40;</span>go, <span style="color: #0600FF; font-weight: bold;">null</span>, 5<span style="color: #008000;">.</span>8f, <span style="color: #0600FF; font-weight: bold;">null</span>, <span style="color: #FF0000;">0</span>, <span style="color: #0600FF; font-weight: bold;">null</span>, iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">EasingType</span><span style="color: #008000;">.</span><span style="color: #0000FF;">easeInExpo</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">shake</span><span style="color: #008000;">&#40;</span>cam, <span style="color: #008000;">.</span>8f, 6<span style="color: #008000;">.</span>8f, <span style="color: #0600FF; font-weight: bold;">null</span>, <span style="color: #008000;">.</span>3f, <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">colorTo</span><span style="color: #008000;">&#40;</span>go, <span style="color: #008000;">.</span>5f, 7<span style="color: #008000;">.</span>6f, <span style="color: #008000;">.</span>165f, <span style="color: #008000;">.</span>498f, <span style="color: #008000;">.</span>729f<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    iTween<span style="color: #008000;">.</span><span style="color: #0000FF;">scaleTo</span><span style="color: #008000;">&#40;</span>go, <span style="color: #0600FF; font-weight: bold;">null</span>, 7<span style="color: #008000;">.</span>6f, <span style="color: #0600FF; font-weight: bold;">null</span>, <span style="color: #FF0000;">1</span>, <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
<span style="color: #008000;">&#125;</span></pre></div></div>

<ul>
<li><a href="http://www.pixelplacement.com/iTween/" target="_blank">Download Javascript iTween</a> by Bob Berkebile (<a href="http://www.pixelplacement.com/" target="_blank">pixelplacement.com</a>)</li>
<li><a href="http://www.insquare.com/itween/" target="_blank">Download C# iTween</a> by Patrick Corkum (<a href="http://www.insquare.com/" target="_blank">insquare.com</a>)</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://drawlogic.com/2010/04/11/itween-tweening-and-easing-animation-library-for-unity-3d/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>AS3 Tween Engines Getting Lighter with GTweeny, ByteTween, TweenLite and TweensyZero</title>
		<link>http://drawlogic.com/2009/02/05/as3-tween-engines-getting-lighter-with-gtweeny-bytetween-tweenlite-and-tweensyzero/</link>
		<comments>http://drawlogic.com/2009/02/05/as3-tween-engines-getting-lighter-with-gtweeny-bytetween-tweenlite-and-tweensyzero/#comments</comments>
		<pubDate>Thu, 05 Feb 2009 08:14:21 +0000</pubDate>
		<dc:creator>drawk</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[ACTIONSCRIPT]]></category>
		<category><![CDATA[ACTIONSCRIPT3]]></category>
		<category><![CDATA[ANIMATION]]></category>
		<category><![CDATA[AS3]]></category>
		<category><![CDATA[DYNAMIC]]></category>
		<category><![CDATA[EFFECTS]]></category>
		<category><![CDATA[FLASH]]></category>
		<category><![CDATA[FLEX]]></category>
		<category><![CDATA[GAMEDEV]]></category>
		<category><![CDATA[GAMES]]></category>
		<category><![CDATA[OPEN SOURCE]]></category>
		<category><![CDATA[PROGRAMMING]]></category>
		<category><![CDATA[TECHNOLOGY]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[bytetween]]></category>
		<category><![CDATA[gtween]]></category>
		<category><![CDATA[gtweeny]]></category>
		<category><![CDATA[transition]]></category>
		<category><![CDATA[tween]]></category>
		<category><![CDATA[tweener]]></category>
		<category><![CDATA[tweenlite]]></category>
		<category><![CDATA[tweenmax]]></category>
		<category><![CDATA[tweensy]]></category>
		<category><![CDATA[tweensyzero]]></category>

		<guid isPermaLink="false">http://drawlogic.com/?p=378</guid>
		<description><![CDATA[Recently two compact tweening engines have been released. Grant Skinner&#8217;s GTweeny and laborat&#8217;s ByteTween. This adds to the two that focus on micro-tween kit sizes in TweenLite and TweensyZero Basically these engines look to be micro and provide pretty nice features while being so small. Micro tweening engines like GTweeny (3k), ByteTween (1.7k), TweenLite (2.7k), [...]]]></description>
			<content:encoded><![CDATA[<p>Recently two compact tweening engines have been released.  Grant Skinner&#8217;s <a href="http://www.gskinner.com/blog/archives/2009/02/gtweeny_lightwe.html" target="_blank">GTweeny</a> and laborat&#8217;s <a href="http://thelaborat.org/?p=118" target="_blank">ByteTween</a>. This adds to the two that focus on micro-tween kit sizes in <a href="http://blog.greensock.com/tweenliteas3/" target="_blank">TweenLite </a>and <a href="http://code.google.com/p/tweensy/wiki/TweensyZero" target="_blank">TweensyZero</a></p>
<p>Basically these engines look to be micro and provide pretty nice features while being so small.  Micro tweening engines like GTweeny (3k), ByteTween (1.7k), TweenLite (2.7k), TweensyZero (2.9k) and Tweener (9k) have varying levels of support of features (Tweener being the most loaded with color and filter support without other kits just init, also TweenLite with a nice configurator to include only what you need).  Micro kits have benefits when used for banners, animated assets (where you have many assets and the per asset savings is worthwhile) and other places you just want really small output.</p>
<h3><a href="http://thelaborat.org/?p=118" target="_blank">Light Transition ByteTween</a></h3>
<p>(1.7k)</p>
<p>This kit has a c# version as well as a small as3 bytetween version.</p>
<blockquote><p>The ByteTween static class eats only 1.7K of compiled clip! With this size it supports:</p>
<ul>
<li>Creation of tweens of any numeric property (not color/uint properties).</li>
<li>Pause,Unpause,Cancel operations based on the tween target and property.</li>
<li>Overlap system that cancel tweens of same property in order to avoid erroneous behavior</li>
<li>Alpha tween with negative alpha support (negative alpha sets the MovieClip visibility to false)</li>
<li>’scale’ tween of both ’scaleX’ and ’scaleY’ properties.</li>
<li>OnComplete callback with any number of parameters</li>
<li>Easy interface for creating new tweens!</li>
</ul>
</blockquote>
<blockquote><p><a href="http://thelab-lighter.googlecode.com/files/light_transition_CS_0.5a.zip.zip">Download light_transition_CS_0.5a.zip.zip (c# version)</a></p></blockquote>
<blockquote><p><a href="http://thelab-lighter.googlecode.com/files/thelab_ByteTween.zip">Download thelab_ByteTween.zip</a></p></blockquote>
<h3><a href="http://blog.greensock.com/tweenliteas3/" target="_blank">TweenLite</a></h3>
<p>(2.7k) base</p>
<ul>
<li><strong><a href="http://blog.greensock.com/tweening-speed-test/">SPEED</a></strong> &#8211; I&#8217;m not aware of any popular tweening engine with a similar feature set that&#8217;s as fast as TweenLite. See the <a href="http://blog.greensock.com/tweening-speed-test/">speed comparisons</a> yourself.</li>
<li><strong>Feature set</strong> &#8211; In addition to tweening ANY numeric property of ANY object, TweenLite can tween filters, hex colors, volume, tint, saturation, contrast, frames, and even do bezier tweening, plus LOTS more. <a onclick="javascript:urchinTracker ('/outbound/article/www.TweenMax.com');" href="http://www.tweenmax.com/">TweenMax</a> extends TweenLite and adds even more capabilities like pause/resume, rounding, event listeners, timeScale, and more. Overwrite management is an important consideration for a tweening engine as well which is another area where the GreenSock tweening platform shines. You have options for AUTO overwriting or you can manually define how each tween will handle overlapping tweens of the same object.</li>
<li><strong>Expandability</strong> &#8211; With its new plugin architecture, you can activate as many (or as few) features as your project requires. Or write your own plugin if you need a feature that&#8217;s unavailable. Minimize bloat, and maximize performance.</li>
<li><strong>Management features</strong> &#8211; <a onclick="javascript:urchinTracker ('/outbound/article/www.TweenGroup.com');" href="http://www.tweengroup.com/">TweenGroup</a> makes it surprisingly simple to create complex sequences and groups of TweenLite/Max tweens that you can pause(), resume(), restart(), or reverse(). You can even tween a TweenGroup&#8217;s &#8220;progress&#8221; property to fastforward or rewind the entire group/sequence.</li>
<li><strong>Ease of use</strong> &#8211; Designers and Developers alike rave about how intuitive the GreenSock tweening platform is.</li>
<li><strong>Updates</strong> &#8211; Frequent updates and feature additions make the GreenSock tweening platform reliable and robust.</li>
<li><strong>AS2 and AS3</strong> &#8211; Most other engines are only developed for AS2 or AS3 but not both.</li>
</ul>
<blockquote><p><a href="http://blog.greensock.com/tweenliteas3/" target="_blank">Download TweenLite</a></p></blockquote>
<h3><a href="http://code.google.com/p/tweensy/wiki/TweensyZero" target="_blank">TweensyZero</a></h3>
<p>(2.9k) base</p>
<blockquote><p><a href="http://code.google.com/p/tweensy/wiki/TweensyZero" target="_blank">Here are some simple steps to help you get started</a> with creating your first animations with <a href="http://code.google.com/p/tweensy/wiki/TweensyZero">TweensyZero</a>. <a href="http://code.google.com/p/tweensy/wiki/TweensyZero">TweensyZero</a> is a light weight version of Tweensy most core features found in Tweensy are available to <a href="http://code.google.com/p/tweensy/wiki/TweensyZero">TweensyZero</a>. Documentation for <a href="http://code.google.com/p/tweensy/wiki/TweensyZero">TweensyZero</a> can be found under the folder &#8216;documentation/zero&#8217; or <a rel="nofollow" href="http://docs.flashdynamix.com/tweensy/zero/">online</a></p></blockquote>
<blockquote><p><a href="http://code.google.com/p/tweensy/downloads/list" target="_blank">Download TweensyZero<br />
</a></p></blockquote>
<h3><a href="http://www.gskinner.com/blog/archives/2009/02/gtweeny_lightwe.html" target="_blank">gTweeny</a></h3>
<p>(3k)</p>
<blockquote><p>gTweeny is <a href="http://www.gskinner.com/blog/archives/2009/02/gtween_beta_5_r.html">gTween</a>&#8216;s lightweight younger sibling. It strips a lot of the secondary features of GTween (proxy, timing modes, etc) in favour of smaller file size. It is currently under 3kb&#8230;</p>
<p><a href="http://www.gskinner.com/libraries/gtween/#download" target="_blank">Download gTweeny</a></p></blockquote>
<p><strong>Here is a list of all open AS3 &#8220;Micro&#8221; Tweening engines &lt; 5k<br />
</strong></p>
<ul class="xoxo blogroll">
<li><a href="http://thelaborat.org/?p=118" target="_blank">ByteTween</a> (1.7k)</li>
<li><a href="http://blog.greensock.com/tweenliteas3">TweenLite</a> (2.7k)</li>
<li><a href="http://code.google.com/p/tweensy/wiki/TweensyZero" target="_blank">TweensyZero </a>(2.9k)</li>
<li><a href="http://www.gskinner.com/libraries/gtween/" target="_blank">gTweeny</a> (3k)<a href="http://blog.greensock.com/tweenliteas3"><br />
</a></li>
</ul>
<p><strong>Here is a list of all open AS3 Tweening engines and base kits</strong></p>
<ul class="xoxo blogroll">
<li><a href="http://www.alex-uhlmann.de/flash/animationpackage/">Animation Package</a></li>
<li><a href="http://www.boostworthy.com/blog/?p=170">AS3 Animation System 2.1</a></li>
<li><a href="http://www.uza.lt/codex/as3-easing/" target="_blank">AS3Easing</a></li>
<li><a href="http://www.goasap.org/">Go</a> (base animation kit &#8211; create your own tween engine)</li>
<li><a href="http://www.gskinner.com/blog/archives/2008/08/gtween_a_new_tw.html" target="_blank">gTween</a><a href="http://www.gskinner.com/blog/archives/2008/08/gtween_a_new_tw.html" target="_blank"><br />
</a></li>
<li><a href="http://code.google.com/p/kitchensynclib/" target="_blank">KitchenSync</a></li>
<li><a href="http://code.google.com/p/twease/" target="_blank">Twease</a></li>
<li><a href="http://code.google.com/p/tweener/">Tweener</a> (9k)</li>
<li><a href="http://code.google.com/p/tweensy/" target="_blank">Tweensy</a></li>
<li><a href="http://blog.greensock.com/tweenliteas3">TweenLite (TweenMax)</a></li>
</ul>
<p>The decision on which to use can be affected be features you want, how it feels (many use the same object syntax so it is dynamic), what performance do they have (all are orders of magnitude faster than the built in tween (flash) or transitions (mx/flex)), which size is ok, author/community support needed (some are more active than others adding features or simplifying and tweaking performance methodically), and many other factors.  There are definitely plenty to choose from.</p>
<p><strong>Speed Tests for many Tween Engines</strong></p>
<ul>
<li><a href="http://blog.greensock.com/tweening-speed-test/" target="_blank">Green Sock Tweening Comparison Tool</a></li>
<li><a href="http://go.mosessupposes.com/?p=5" target="_blank">Moses Benchmarking Tool </a>(relative comparison against SimpleAS3Tween sample)</li>
</ul>
<p>For more on each features see their sites or these previous lists on tweening engines:</p>
<ul>
<li><a title="Permanent Link: Updated: List of Best Animation Packages for AS3" rel="bookmark" href="../2007/06/25/updated-list-of-best-animation-packages-for-as3/">Updated: List of Best Animation Packages for AS3</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://drawlogic.com/2009/02/05/as3-tween-engines-getting-lighter-with-gtweeny-bytetween-tweenlite-and-tweensyzero/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>AS3 SoundManager Class for Flash Updated for Tweener</title>
		<link>http://drawlogic.com/2009/01/16/as3-soundmanager-class-for-flash-updated-for-tweener/</link>
		<comments>http://drawlogic.com/2009/01/16/as3-soundmanager-class-for-flash-updated-for-tweener/#comments</comments>
		<pubDate>Fri, 16 Jan 2009 21:24:14 +0000</pubDate>
		<dc:creator>drawk</dc:creator>
				<category><![CDATA[ACTIONSCRIPT]]></category>
		<category><![CDATA[ACTIONSCRIPT3]]></category>
		<category><![CDATA[ARCHITECT]]></category>
		<category><![CDATA[AS3]]></category>
		<category><![CDATA[AUDIO]]></category>
		<category><![CDATA[DEVELOPMENT]]></category>
		<category><![CDATA[FLASH]]></category>
		<category><![CDATA[FLEX]]></category>
		<category><![CDATA[GAMEDEV]]></category>
		<category><![CDATA[GAMES]]></category>
		<category><![CDATA[OPEN SOURCE]]></category>
		<category><![CDATA[PROGRAMMING]]></category>
		<category><![CDATA[TECHNOLOGY]]></category>
		<category><![CDATA[manager]]></category>
		<category><![CDATA[sound]]></category>
		<category><![CDATA[tweener]]></category>
		<category><![CDATA[tweenlite]]></category>

		<guid isPermaLink="false">http://drawlogic.com/?p=351</guid>
		<description><![CDATA[I use a SoundManager class for games and interactives that require it which I picked up at evolve by Matt Przybylski.  But I sometimes need to use Tweener rather than TweenLite depending on what the project uses already. So here is the class updated with Tweener.  Just grab the latest Tweener to work with this.  [...]]]></description>
			<content:encoded><![CDATA[<p>I use a SoundManager class for games and interactives that require it which I picked up at <a href="http://evolve.reintroducing.com/2008/07/15/news/as3-soundmanager/" target="_blank">evolve </a>by <span class="comment-author">Matt Przybylski</span>.  But I sometimes need to use Tweener rather than TweenLite depending on what the project uses already. So here is the class updated with Tweener.  Just grab the latest <a href="http://code.google.com/p/tweener/" target="_blank">Tweener </a>to work with this.  Sound is one of those things like tweening, it is easier to reuse code if everyone uses common libraries.</p>

<div class="wp_syntax"><div class="code"><pre class="actionscript" style="font-family:monospace;">package game.<span style="color: #006600;">util</span>
<span style="color: #66cc66;">&#123;</span>
	<span style="color: #0066CC;">import</span> caurina.<span style="color: #006600;">transitions</span>.<span style="color: #006600;">properties</span>.<span style="color: #006600;">SoundShortcuts</span>;
	<span style="color: #0066CC;">import</span> flash.<span style="color: #006600;">media</span>.<span style="color: #0066CC;">Sound</span>;
	<span style="color: #0066CC;">import</span> flash.<span style="color: #006600;">media</span>.<span style="color: #006600;">SoundChannel</span>;
	<span style="color: #0066CC;">import</span> flash.<span style="color: #006600;">media</span>.<span style="color: #006600;">SoundLoaderContext</span>;
	<span style="color: #0066CC;">import</span> flash.<span style="color: #006600;">media</span>.<span style="color: #006600;">SoundTransform</span>;
	<span style="color: #0066CC;">import</span> flash.<span style="color: #006600;">net</span>.<span style="color: #006600;">URLRequest</span>;
	<span style="color: #0066CC;">import</span> flash.<span style="color: #006600;">utils</span>.<span style="color: #006600;">Dictionary</span>;
	<span style="color: #0066CC;">import</span> flash.<span style="color: #006600;">utils</span>.<span style="color: #006600;">getQualifiedClassName</span>;
	<span style="color: #0066CC;">import</span> caurina.<span style="color: #006600;">transitions</span>.<span style="color: #66cc66;">*</span>;
	<span style="color: #808080; font-style: italic;">/**
	 * The SoundManager is a singleton that allows you to have various ways to control sounds in your project.
	 *
&nbsp;
	 * The SoundManager can load external or library sounds, pause/mute/stop/control volume for one or more sounds at a time,
	 * fade sounds up or down, and allows additional control to sounds not readily available through the default classes.
	 *
&nbsp;
	 * This class is dependent on TweenLite (http://www.tweenlite.com) to aid in easily fading the volume of the sound.
	 *
	 * @author Matt Przybylski [http://www.reintroducing.com]
	 * @version 1.0
	 *
	 * @author Ryan Christensen (http://drawlogic.com)
	 * @version 1.1 - added Tweener support and removed TweenLite support
	 */</span>
	<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">class</span> SoundManager
	<span style="color: #66cc66;">&#123;</span>
<span style="color: #808080; font-style: italic;">//- PRIVATE &amp;amp; PROTECTED VARIABLES -------------------------------------------------------------------------</span>
		<span style="color: #808080; font-style: italic;">// singleton instance</span>
		<span style="color: #0066CC;">private</span> <span style="color: #0066CC;">static</span> <span style="color: #000000; font-weight: bold;">var</span> _instance:SoundManager;
		<span style="color: #0066CC;">private</span> <span style="color: #0066CC;">static</span> <span style="color: #000000; font-weight: bold;">var</span> _allowInstance:<span style="color: #0066CC;">Boolean</span>;
		<span style="color: #0066CC;">private</span> <span style="color: #000000; font-weight: bold;">var</span> _soundsDict:Dictionary;
		<span style="color: #0066CC;">private</span> <span style="color: #000000; font-weight: bold;">var</span> _sounds:<span style="color: #0066CC;">Array</span>;
<span style="color: #808080; font-style: italic;">//- PUBLIC &amp;amp; INTERNAL VARIABLES ---------------------------------------------------------------------------</span>
<span style="color: #808080; font-style: italic;">//- CONSTRUCTOR -------------------------------------------------------------------------------------------</span>
		<span style="color: #808080; font-style: italic;">// singleton instance of SoundManager</span>
		<span style="color: #0066CC;">public</span> <span style="color: #0066CC;">static</span> <span style="color: #000000; font-weight: bold;">function</span> getInstance<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>:SoundManager
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>SoundManager._instance == <span style="color: #000000; font-weight: bold;">null</span><span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				SoundManager._allowInstance = <span style="color: #000000; font-weight: bold;">true</span>;
				SoundManager._instance = <span style="color: #000000; font-weight: bold;">new</span> SoundManager<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
				SoundManager._allowInstance = <span style="color: #000000; font-weight: bold;">false</span>;
			<span style="color: #66cc66;">&#125;</span>
			<span style="color: #b1b100;">return</span> SoundManager._instance;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> SoundManager<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #0066CC;">this</span>._soundsDict = <span style="color: #000000; font-weight: bold;">new</span> Dictionary<span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">true</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #0066CC;">this</span>._sounds = <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #0066CC;">Array</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">!</span>SoundManager._allowInstance<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #0066CC;">throw</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #0066CC;">Error</span><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">&quot;Error: Use SoundManager.getInstance() instead of the new keyword.&quot;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>
<span style="color: #808080; font-style: italic;">//- PRIVATE &amp;amp; PROTECTED METHODS ---------------------------------------------------------------------------</span>
<span style="color: #808080; font-style: italic;">//- PUBLIC &amp; INTERNAL METHODS -----------------------------------------------------------------------------</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Adds a sound from the library to the sounds dictionary for playing in the future.
		 *
		 * @param $linkageID The class name of the library symbol that was exported for AS
		 * @param $name The string identifier of the sound to be used when calling other methods on the sound
		 *
		 * @return Boolean A boolean value representing if the sound was added successfully
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> addLibrarySound<span style="color: #66cc66;">&#40;</span>$linkageID:<span style="color: #66cc66;">*</span>, $name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Boolean</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span> == $name<span style="color: #66cc66;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #000000; font-weight: bold;">false</span>;
			<span style="color: #66cc66;">&#125;</span>
			<span style="color: #000000; font-weight: bold;">var</span> sndObj:<span style="color: #0066CC;">Object</span> = <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #0066CC;">Object</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #000000; font-weight: bold;">var</span> snd:<span style="color: #0066CC;">Sound</span> = <span style="color: #000000; font-weight: bold;">new</span> $linkageID;
			sndObj.<span style="color: #0066CC;">name</span> = $name;
			sndObj.<span style="color: #0066CC;">sound</span> = snd;
			sndObj.<span style="color: #006600;">channel</span> = <span style="color: #000000; font-weight: bold;">new</span> SoundChannel<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			sndObj.<span style="color: #0066CC;">position</span> = <span style="color: #cc66cc;">0</span>;
			sndObj.<span style="color: #006600;">paused</span> = <span style="color: #000000; font-weight: bold;">true</span>;
			sndObj.<span style="color: #006600;">volume</span> = <span style="color: #cc66cc;">1</span>;
			sndObj.<span style="color: #006600;">startTime</span> = <span style="color: #cc66cc;">0</span>;
			sndObj.<span style="color: #006600;">loops</span> = <span style="color: #cc66cc;">0</span>;
			sndObj.<span style="color: #006600;">pausedByAll</span> = <span style="color: #000000; font-weight: bold;">false</span>;
			<span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span> = sndObj;
			<span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">push</span><span style="color: #66cc66;">&#40;</span>sndObj<span style="color: #66cc66;">&#41;</span>;
			<span style="color: #b1b100;">return</span> <span style="color: #000000; font-weight: bold;">true</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Adds an external sound to the sounds dictionary for playing in the future.
		 *
		 * @param $path A string representing the path where the sound is on the server
		 * @param $name The string identifier of the sound to be used when calling other methods on the sound
		 * @param $buffer The number, in milliseconds, to buffer the sound before you can play it (default: 1000)
		 * @param $checkPolicyFile A boolean that determines whether Flash Player should try to download a cross-domain policy file from the loaded sound's server before beginning to load the sound (default: false)
		 *
		 * @return Boolean A boolean value representing if the sound was added successfully
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> addExternalSound<span style="color: #66cc66;">&#40;</span>$path:<span style="color: #0066CC;">String</span>, $name:<span style="color: #0066CC;">String</span>, $buffer:<span style="color: #0066CC;">Number</span> = <span style="color: #cc66cc;">1000</span>, $checkPolicyFile:<span style="color: #0066CC;">Boolean</span> = <span style="color: #000000; font-weight: bold;">false</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Boolean</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span> == $name<span style="color: #66cc66;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #000000; font-weight: bold;">false</span>;
			<span style="color: #66cc66;">&#125;</span>
			<span style="color: #000000; font-weight: bold;">var</span> sndObj:<span style="color: #0066CC;">Object</span> = <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #0066CC;">Object</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #000000; font-weight: bold;">var</span> snd:<span style="color: #0066CC;">Sound</span> = <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #0066CC;">Sound</span><span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">new</span> URLRequest<span style="color: #66cc66;">&#40;</span>$path<span style="color: #66cc66;">&#41;</span>, <span style="color: #000000; font-weight: bold;">new</span> SoundLoaderContext<span style="color: #66cc66;">&#40;</span>$buffer, $checkPolicyFile<span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span>;
			sndObj.<span style="color: #0066CC;">name</span> = $name;
			sndObj.<span style="color: #0066CC;">sound</span> = snd;
			sndObj.<span style="color: #006600;">channel</span> = <span style="color: #000000; font-weight: bold;">new</span> SoundChannel<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			sndObj.<span style="color: #0066CC;">position</span> = <span style="color: #cc66cc;">0</span>;
			sndObj.<span style="color: #006600;">paused</span> = <span style="color: #000000; font-weight: bold;">true</span>;
			sndObj.<span style="color: #006600;">volume</span> = <span style="color: #cc66cc;">1</span>;
			sndObj.<span style="color: #006600;">startTime</span> = <span style="color: #cc66cc;">0</span>;
			sndObj.<span style="color: #006600;">loops</span> = <span style="color: #cc66cc;">0</span>;
			sndObj.<span style="color: #006600;">pausedByAll</span> = <span style="color: #000000; font-weight: bold;">false</span>;
			<span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span> = sndObj;
			<span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">push</span><span style="color: #66cc66;">&#40;</span>sndObj<span style="color: #66cc66;">&#41;</span>;
			<span style="color: #b1b100;">return</span> <span style="color: #000000; font-weight: bold;">true</span>;
		<span style="color: #66cc66;">&#125;</span>
&nbsp;
&nbsp;
		<span style="color: #808080; font-style: italic;">/**
		 * Removes a sound from the sound dictionary.  After calling this, the sound will not be available until it is re-added.
		 *
		 * @param $name The string identifier of the sound to remove
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> removeSound<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span> == $name<span style="color: #66cc66;">&#41;</span>
				<span style="color: #66cc66;">&#123;</span>
					<span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span> = <span style="color: #000000; font-weight: bold;">null</span>;
					<span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">splice</span><span style="color: #66cc66;">&#40;</span>i, <span style="color: #cc66cc;">1</span><span style="color: #66cc66;">&#41;</span>;
				<span style="color: #66cc66;">&#125;</span>
			<span style="color: #66cc66;">&#125;</span>
			<span style="color: #0066CC;">delete</span> <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Removes all sounds from the sound dictionary.
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> removeAllSounds<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&amp;</span>lt; <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span> = <span style="color: #000000; font-weight: bold;">null</span>;
			<span style="color: #66cc66;">&#125;</span>
			<span style="color: #0066CC;">this</span>._sounds = <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #0066CC;">Array</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #0066CC;">this</span>._soundsDict = <span style="color: #000000; font-weight: bold;">new</span> Dictionary<span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">true</span><span style="color: #66cc66;">&#41;</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Plays or resumes a sound from the sound dictionary with the specified name.
		 *
		 * @param $name The string identifier of the sound to play
		 * @param $volume A number from 0 to 1 representing the volume at which to play the sound (default: 1)
		 * @param $startTime A number (in milliseconds) representing the time to start playing the sound at (default: 0)
		 * @param $loops An integer representing the number of times to loop the sound (default: 0)
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> playSound<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span>, $volume:<span style="color: #0066CC;">Number</span> = <span style="color: #cc66cc;">1</span>, $startTime:<span style="color: #0066CC;">Number</span> = <span style="color: #cc66cc;">0</span>, $loops:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #000000; font-weight: bold;">var</span> snd:<span style="color: #0066CC;">Object</span> = <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>;
			snd.<span style="color: #006600;">volume</span> = $volume;
			snd.<span style="color: #006600;">startTime</span> = $startTime;
			snd.<span style="color: #006600;">loops</span> = $loops;
			<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>snd.<span style="color: #006600;">paused</span><span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				snd.<span style="color: #006600;">channel</span> = snd.<span style="color: #0066CC;">sound</span>.<span style="color: #0066CC;">play</span><span style="color: #66cc66;">&#40;</span>snd.<span style="color: #0066CC;">position</span>, snd.<span style="color: #006600;">loops</span>, <span style="color: #000000; font-weight: bold;">new</span> SoundTransform<span style="color: #66cc66;">&#40;</span>snd.<span style="color: #006600;">volume</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #66cc66;">&#125;</span>
			<span style="color: #b1b100;">else</span>
			<span style="color: #66cc66;">&#123;</span>
				snd.<span style="color: #006600;">channel</span> = snd.<span style="color: #0066CC;">sound</span>.<span style="color: #0066CC;">play</span><span style="color: #66cc66;">&#40;</span>$startTime, snd.<span style="color: #006600;">loops</span>, <span style="color: #000000; font-weight: bold;">new</span> SoundTransform<span style="color: #66cc66;">&#40;</span>snd.<span style="color: #006600;">volume</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #66cc66;">&#125;</span>
			snd.<span style="color: #006600;">paused</span> = <span style="color: #000000; font-weight: bold;">false</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Stops the specified sound.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> stopSound<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #000000; font-weight: bold;">var</span> snd:<span style="color: #0066CC;">Object</span> = <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>;
			snd.<span style="color: #006600;">paused</span> = <span style="color: #000000; font-weight: bold;">true</span>;
			snd.<span style="color: #006600;">channel</span>.<span style="color: #0066CC;">stop</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			snd.<span style="color: #0066CC;">position</span> = snd.<span style="color: #006600;">channel</span>.<span style="color: #0066CC;">position</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Pauses the specified sound.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> pauseSound<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #000000; font-weight: bold;">var</span> snd:<span style="color: #0066CC;">Object</span> = <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>;
			snd.<span style="color: #006600;">paused</span> = <span style="color: #000000; font-weight: bold;">true</span>;
			snd.<span style="color: #0066CC;">position</span> = snd.<span style="color: #006600;">channel</span>.<span style="color: #0066CC;">position</span>;
			snd.<span style="color: #006600;">channel</span>.<span style="color: #0066CC;">stop</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Plays all the sounds that are in the sound dictionary.
		 *
		 * @param $useCurrentlyPlayingOnly A boolean that only plays the sounds which were currently playing before a pauseAllSounds() or stopAllSounds() call (default: false)
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> playAllSounds<span style="color: #66cc66;">&#40;</span>$useCurrentlyPlayingOnly:<span style="color: #0066CC;">Boolean</span> = <span style="color: #000000; font-weight: bold;">false</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #000000; font-weight: bold;">var</span> id:<span style="color: #0066CC;">String</span> = <span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span>;
				<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>$useCurrentlyPlayingOnly<span style="color: #66cc66;">&#41;</span>
				<span style="color: #66cc66;">&#123;</span>
					<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>id<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">pausedByAll</span><span style="color: #66cc66;">&#41;</span>
					<span style="color: #66cc66;">&#123;</span>
						<span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>id<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">pausedByAll</span> = <span style="color: #000000; font-weight: bold;">false</span>;
						<span style="color: #0066CC;">this</span>.<span style="color: #006600;">playSound</span><span style="color: #66cc66;">&#40;</span>id<span style="color: #66cc66;">&#41;</span>;
					<span style="color: #66cc66;">&#125;</span>
				<span style="color: #66cc66;">&#125;</span>
				<span style="color: #b1b100;">else</span>
				<span style="color: #66cc66;">&#123;</span>
					<span style="color: #0066CC;">this</span>.<span style="color: #006600;">playSound</span><span style="color: #66cc66;">&#40;</span>id<span style="color: #66cc66;">&#41;</span>;
				<span style="color: #66cc66;">&#125;</span>
			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Stops all the sounds that are in the sound dictionary.
		 *
		 * @param $useCurrentlyPlayingOnly A boolean that only stops the sounds which are currently playing (default: true)
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> <span style="color: #0066CC;">stopAllSounds</span><span style="color: #66cc66;">&#40;</span>$useCurrentlyPlayingOnly:<span style="color: #0066CC;">Boolean</span> = <span style="color: #000000; font-weight: bold;">true</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #000000; font-weight: bold;">var</span> id:<span style="color: #0066CC;">String</span> = <span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span>;
				<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>$useCurrentlyPlayingOnly<span style="color: #66cc66;">&#41;</span>
				<span style="color: #66cc66;">&#123;</span>
					<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">!</span><span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>id<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">paused</span><span style="color: #66cc66;">&#41;</span>
					<span style="color: #66cc66;">&#123;</span>
						<span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>id<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">pausedByAll</span> = <span style="color: #000000; font-weight: bold;">true</span>;
						<span style="color: #0066CC;">this</span>.<span style="color: #006600;">stopSound</span><span style="color: #66cc66;">&#40;</span>id<span style="color: #66cc66;">&#41;</span>;
					<span style="color: #66cc66;">&#125;</span>
				<span style="color: #66cc66;">&#125;</span>
				<span style="color: #b1b100;">else</span>
				<span style="color: #66cc66;">&#123;</span>
					<span style="color: #0066CC;">this</span>.<span style="color: #006600;">stopSound</span><span style="color: #66cc66;">&#40;</span>id<span style="color: #66cc66;">&#41;</span>;
				<span style="color: #66cc66;">&#125;</span>
			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Pauses all the sounds that are in the sound dictionary.
		 *
		 * @param $useCurrentlyPlayingOnly A boolean that only pauses the sounds which are currently playing (default: true)
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> pauseAllSounds<span style="color: #66cc66;">&#40;</span>$useCurrentlyPlayingOnly:<span style="color: #0066CC;">Boolean</span> = <span style="color: #000000; font-weight: bold;">true</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #000000; font-weight: bold;">var</span> id:<span style="color: #0066CC;">String</span> = <span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span>;
				<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span>$useCurrentlyPlayingOnly<span style="color: #66cc66;">&#41;</span>
				<span style="color: #66cc66;">&#123;</span>
					<span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">!</span><span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>id<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">paused</span><span style="color: #66cc66;">&#41;</span>
					<span style="color: #66cc66;">&#123;</span>
						<span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>id<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">pausedByAll</span> = <span style="color: #000000; font-weight: bold;">true</span>;
						<span style="color: #0066CC;">this</span>.<span style="color: #006600;">pauseSound</span><span style="color: #66cc66;">&#40;</span>id<span style="color: #66cc66;">&#41;</span>;
					<span style="color: #66cc66;">&#125;</span>
				<span style="color: #66cc66;">&#125;</span>
				<span style="color: #b1b100;">else</span>
				<span style="color: #66cc66;">&#123;</span>
					<span style="color: #0066CC;">this</span>.<span style="color: #006600;">pauseSound</span><span style="color: #66cc66;">&#40;</span>id<span style="color: #66cc66;">&#41;</span>;
				<span style="color: #66cc66;">&#125;</span>
			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Fades the sound to the specified volume over the specified amount of time.
		 *
		 * @param $name The string identifier of the sound
		 * @param $targVolume The target volume to fade to, between 0 and 1 (default: 0)
		 * @param $fadeLength The time to fade over, in seconds (default: 1)
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> fadeSound<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span>, $targVolume:<span style="color: #0066CC;">Number</span> = <span style="color: #cc66cc;">0</span>, $fadeLength:<span style="color: #0066CC;">Number</span> = <span style="color: #cc66cc;">1</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #000000; font-weight: bold;">var</span> fadeChannel:SoundChannel = <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">channel</span>;
			SoundShortcuts.<span style="color: #006600;">init</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>;
			Tweener.<span style="color: #006600;">addTween</span><span style="color: #66cc66;">&#40;</span>fadeChannel, <span style="color: #66cc66;">&#123;</span> _sound_volume: $targVolume, <span style="color: #0066CC;">time</span>: $fadeLength, transition:<span style="color: #ff0000;">&quot;linear&quot;</span> <span style="color: #66cc66;">&#125;</span> <span style="color: #66cc66;">&#41;</span>;
			<span style="color: #808080; font-style: italic;">//TweenLite.to(fadeChannel, $fadeLength, {volume: $targVolume});</span>
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Mutes the volume for all sounds in the sound dictionary.
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> muteAllSounds<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #000000; font-weight: bold;">var</span> id:<span style="color: #0066CC;">String</span> = <span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span>;
				<span style="color: #0066CC;">this</span>.<span style="color: #006600;">setSoundVolume</span><span style="color: #66cc66;">&#40;</span>id, <span style="color: #cc66cc;">0</span><span style="color: #66cc66;">&#41;</span>;
			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Resets the volume to their original setting for all sounds in the sound dictionary.
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> unmuteAllSounds<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">for</span> <span style="color: #66cc66;">&#40;</span><span style="color: #000000; font-weight: bold;">var</span> i:<span style="color: #0066CC;">int</span> = <span style="color: #cc66cc;">0</span>; i <span style="color: #66cc66;">&lt;</span> <span style="color: #0066CC;">this</span>._sounds.<span style="color: #0066CC;">length</span>; i++<span style="color: #66cc66;">&#41;</span>
			<span style="color: #66cc66;">&#123;</span>
				<span style="color: #000000; font-weight: bold;">var</span> id:<span style="color: #0066CC;">String</span> = <span style="color: #0066CC;">this</span>._sounds<span style="color: #66cc66;">&#91;</span>i<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">name</span>;
				<span style="color: #000000; font-weight: bold;">var</span> snd:<span style="color: #0066CC;">Object</span> = <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>id<span style="color: #66cc66;">&#93;</span>;
				<span style="color: #000000; font-weight: bold;">var</span> curTransform:SoundTransform = snd.<span style="color: #006600;">channel</span>.<span style="color: #006600;">soundTransform</span>;
				curTransform.<span style="color: #006600;">volume</span> = snd.<span style="color: #006600;">volume</span>;
				snd.<span style="color: #006600;">channel</span>.<span style="color: #006600;">soundTransform</span> = curTransform;
			<span style="color: #66cc66;">&#125;</span>
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Sets the volume of the specified sound.
		 *
		 * @param $name The string identifier of the sound
		 * @param $volume The volume, between 0 and 1, to set the sound to
		 *
		 * @return void
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> setSoundVolume<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span>, $volume:<span style="color: #0066CC;">Number</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">void</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #000000; font-weight: bold;">var</span> snd:<span style="color: #0066CC;">Object</span> = <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>;
			<span style="color: #000000; font-weight: bold;">var</span> curTransform:SoundTransform = snd.<span style="color: #006600;">channel</span>.<span style="color: #006600;">soundTransform</span>;
			curTransform.<span style="color: #006600;">volume</span> = $volume;
			snd.<span style="color: #006600;">channel</span>.<span style="color: #006600;">soundTransform</span> = curTransform;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Gets the volume of the specified sound.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return Number The current volume of the sound
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> getSoundVolume<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Number</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">channel</span>.<span style="color: #006600;">soundTransform</span>.<span style="color: #006600;">volume</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Gets the position of the specified sound.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return Number The current position of the sound, in milliseconds
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> getSoundPosition<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Number</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">channel</span>.<span style="color: #0066CC;">position</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Gets the duration of the specified sound.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return Number The length of the sound, in milliseconds
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> getSoundDuration<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Number</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">sound</span>.<span style="color: #0066CC;">length</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Gets the sound object of the specified sound.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return Sound The sound object
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> getSoundObject<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Sound</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>.<span style="color: #0066CC;">sound</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Identifies if the sound is paused or not.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return Boolean The boolean value of paused or not paused
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> isSoundPaused<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Boolean</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">paused</span>;
		<span style="color: #66cc66;">&#125;</span>
		<span style="color: #808080; font-style: italic;">/**
		 * Identifies if the sound was paused or stopped by calling the stopAllSounds() or pauseAllSounds() methods.
		 *
		 * @param $name The string identifier of the sound
		 *
		 * @return Number The boolean value of pausedByAll or not pausedByAll
		 */</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> isSoundPausedByAll<span style="color: #66cc66;">&#40;</span>$name:<span style="color: #0066CC;">String</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Boolean</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> <span style="color: #0066CC;">this</span>._soundsDict<span style="color: #66cc66;">&#91;</span>$name<span style="color: #66cc66;">&#93;</span>.<span style="color: #006600;">pausedByAll</span>;
		<span style="color: #66cc66;">&#125;</span>
<span style="color: #808080; font-style: italic;">//- EVENT HANDLERS ----------------------------------------------------------------------------------------</span>
<span style="color: #808080; font-style: italic;">//- GETTERS &amp;amp; SETTERS -------------------------------------------------------------------------------------</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> <span style="color: #0066CC;">get</span> sounds<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">Array</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> <span style="color: #0066CC;">this</span>._sounds;
		<span style="color: #66cc66;">&#125;</span>
<span style="color: #808080; font-style: italic;">//- HELPERS -----------------------------------------------------------------------------------------------</span>
		<span style="color: #0066CC;">public</span> <span style="color: #000000; font-weight: bold;">function</span> <span style="color: #0066CC;">toString</span><span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>:<span style="color: #0066CC;">String</span>
		<span style="color: #66cc66;">&#123;</span>
			<span style="color: #b1b100;">return</span> getQualifiedClassName<span style="color: #66cc66;">&#40;</span><span style="color: #0066CC;">this</span><span style="color: #66cc66;">&#41;</span>;
		<span style="color: #66cc66;">&#125;</span>
<span style="color: #808080; font-style: italic;">//- END CLASS ---------------------------------------------------------------------------------------------</span>
	<span style="color: #66cc66;">&#125;</span>
<span style="color: #66cc66;">&#125;</span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://drawlogic.com/2009/01/16/as3-soundmanager-class-for-flash-updated-for-tweener/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>AS3 Nascar Game By mr. doob &#8211; AS3 Flash Library Mashup</title>
		<link>http://drawlogic.com/2008/03/28/as3-nascar-game-by-mr-doob-as3-library-mashup/</link>
		<comments>http://drawlogic.com/2008/03/28/as3-nascar-game-by-mr-doob-as3-library-mashup/#comments</comments>
		<pubDate>Fri, 28 Mar 2008 21:47:48 +0000</pubDate>
		<dc:creator>drawk</dc:creator>
				<category><![CDATA[3d]]></category>
		<category><![CDATA[3D ENGINES]]></category>
		<category><![CDATA[ACTIONSCRIPT]]></category>
		<category><![CDATA[ACTIONSCRIPT3]]></category>
		<category><![CDATA[ANIMATION]]></category>
		<category><![CDATA[ARCHITECT]]></category>
		<category><![CDATA[AS3]]></category>
		<category><![CDATA[BEST OF]]></category>
		<category><![CDATA[EFFECTS]]></category>
		<category><![CDATA[ENGINE]]></category>
		<category><![CDATA[FLASH]]></category>
		<category><![CDATA[FLEX]]></category>
		<category><![CDATA[GAMEDEV]]></category>
		<category><![CDATA[GAMES]]></category>
		<category><![CDATA[MARKET]]></category>
		<category><![CDATA[MARKETING]]></category>
		<category><![CDATA[PAPERVISION]]></category>
		<category><![CDATA[PERFORMANCE]]></category>
		<category><![CDATA[PHYSICS]]></category>
		<category><![CDATA[PROGRAMMING]]></category>
		<category><![CDATA[RENDERING]]></category>
		<category><![CDATA[TECHNOLOGY]]></category>
		<category><![CDATA[box2dflashas3]]></category>
		<category><![CDATA[gameplay]]></category>
		<category><![CDATA[mrdoob]]></category>
		<category><![CDATA[nascar]]></category>
		<category><![CDATA[singularity]]></category>
		<category><![CDATA[tweener]]></category>
		<category><![CDATA[zupko]]></category>

		<guid isPermaLink="false">http://drawk.wordpress.com/?p=177</guid>
		<description><![CDATA[I have been one upped by mr. doob! I did a little nascar like RC pro am like prototype in march &#8217;07 when the pv3d kit showed up on my screen and I was hooked like most suceptible flashers who have longed for 3d in flash! Only my version is like Nintendo64 and his is [...]]]></description>
			<content:encoded><![CDATA[<p>I have been <a href="http://mrdoob.com/blog/post/508/" target="_blank">one upped by mr. doob</a>! I <a href="http://drawlogic.com/2007/04/15/papervision3d-test-nascar-prototype/" target="_blank">did a little nascar like RC pro am like prototype</a> in march &#8217;07 when the pv3d kit showed up on my screen and I was hooked like most suceptible flashers who have longed for 3d in flash! Only my version is like Nintendo64 and his is like xbox360 with updated effects and physics kits and some doob magic. All these are based off of, of course the original race car driver in Papervision and its creator <a href="http://carlosulloa.com/" target="_blank">Carlos Ulloa</a> (Adobe should be paying this man).</p>
<p><b>To the feature! This is a <a href="http://mrdoob.com/blog/post/508/" target="_blank">sweet game by mr. doob</a>, called <a href="http://www.sprintenterprise.com/burnandbrag/54080328140238" target="_blank">burn and brag for Nascar</a>.</b></p>
<p><a href="http://mrdoob.com/blog/post/508/" target="_blank"><img src="http://i81.photobucket.com/albums/j223/drawkbox/mrdoob-downsouth.png" height="356" width="515" /></a></p>
<p>Now I don&#8217;t&#8217; particularly like Nascar all that much but who doesn&#8217;t like to peel out to some fiddlin&#8217;? I mainly do Nascar stuff because it is highly marketable and like the only answer most ad agencies have for getting the southern us markets it seems, that and c-o-u-n-t-r-y mu-si-c (must be said at a slower rate).</p>
<p>But I digress, this is a <b><a href="http://www.sprintenterprise.com/burnandbrag/54080328140238" target="_blank">perfect mix of advertisment, game play, fun and experience</a></b>. It is fast, simple, and playable. Exactly the simplicity and smoothness needed of gameplay and playback.  Great ad work but it also gives something fun to do and best of all it is built in AS3 flash with a plethora of libraries from the flash as3 community.</p>
<p><b>The game platform is emerging fantastically in the AS3 market.</b> mrdoob used these kits to build this:</p>
<ul>
<li><a href="http://box2dflash.sourceforge.net/">box2dflash</a> for the car 2d&gt;3d physics,</li>
<li>a modified version of <a href="http://papervision3d.googlecode.com/svn/trunk/branches/Effects/">papervision3D 2.0 (Effects branch)</a></li>
<li><a href="http://code.google.com/p/tweener/">Tweener</a> for the replay</li>
</ul>
<p>It would be cool to see a post on how he did the replays with tweener &#8211; I imagine just a series of points collected with car state (current position state) and then just play them back with a call back or time delay. You&#8217;d have to capture alot for smooth playback without laggy movements.  I am working on multiplayer games with this same issue for a current project.</p>
<p><a href="http://www.sprintenterprise.com/burnandbrag/54080328140238" target="_blank">Game on!</a> The question is when will this be SOTD or SOTM at thefwa.com?</p>
]]></content:encoded>
			<wfw:commentRss>http://drawlogic.com/2008/03/28/as3-nascar-game-by-mr-doob-as3-library-mashup/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

