<?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>Robert Muller Design &#187; Physics</title>
	<atom:link href="http://rmd.com.au/archives/category/physics/feed" rel="self" type="application/rss+xml" />
	<link>http://rmd.com.au</link>
	<description></description>
	<lastBuildDate>Tue, 12 Oct 2010 23:47:16 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Easter Egg a Bastard</title>
		<link>http://rmd.com.au/archives/easter-egg-a-bastard</link>
		<comments>http://rmd.com.au/archives/easter-egg-a-bastard#comments</comments>
		<pubDate>Wed, 22 Apr 2009 14:20:23 +0000</pubDate>
		<dc:creator>Rob Muller</dc:creator>
				<category><![CDATA[Flash]]></category>
		<category><![CDATA[My Work]]></category>
		<category><![CDATA[Physics]]></category>
		<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[Democrats]]></category>
		<category><![CDATA[Easter]]></category>
		<category><![CDATA[Euro RSCG]]></category>

		<guid isPermaLink="false">http://rmd.com.au/?p=319</guid>
		<description><![CDATA[A couple of weeks back just prior to the Easter weekend Euro RSCG launched another campaign for the Australian Democrats. Called &#8220;Easter Egg a Bastard&#8221; &#8211; pick a politician&#8217;s website, or enter your own URL and then egg the page. I&#8217;m happy with the way I&#8217;ve seamlessly combined timeline animation with scripted animation. The bunny [...]]]></description>
			<content:encoded><![CDATA[<p>A couple of weeks back just prior to the Easter weekend <a href="http://www.eurorscg.com.au/">Euro RSCG</a> launched another campaign for the Australian Democrats. Called <a href="http://www.bastardwatch.com.au/easteregg/">&#8220;Easter Egg a Bastard&#8221;</a> &#8211; pick a politician&#8217;s website, or enter your own URL and then egg the page.</p>
<p><a href="http://www.bastardwatch.com.au/easteregg/"><img src="/wp-content/uploads/2009/04/easter_egg.jpg" alt="easter_egg" title="easter_egg" width="420" height="267" class="alignnone size-full wp-image-320" /></a></p>
<p>I&#8217;m happy with the way I&#8217;ve seamlessly combined timeline animation with scripted animation. The bunny and egg are controlled using timeline animation right up until the egg hits the slingshot pouch. From then on it&#8217;s all ActionScript.</p>
<p>The timeline animation is triggered from ActionScript using good old gotoAndPlay(), and when each animation finishes, the bunny&#8217;s timeline calls stop() and then broadcasts an event back out to the view class controlling the bunny. The bunny SWF is embedded at compile time which would normally cause any ActionScript to be stripped out, so I used this method of <a href="http://www.adobe.com/cfusion/communityengine/index.cfm?event=showdetails&#038;productId=2&#038;postId=12871">preserving timeline code in embedded assets</a>. Read the comment on that post though &#8211; I also found that waiting one frame often wasn&#8217;t enough. I simply added a check for the existence of loader.content in the enterFrame handler before continuing.</p>
<p>I also love the feel of the slingshot physics &#8211; it took a fair bit of tweaking to get right. The feeling of depth as you pull back on the slingshot is faked. No Z dimension &#8211; the pouch &#038; egg are just scaling based on their Y position. This meant that I didn&#8217;t need to do any converting back and forth between 3D and 2D coordinates to draw the rubber strips. Once the egg leaves the slingshot however, proper 3D takes over and the egg is positioned &#038; scaled based on its Z coordinate. When budget or schedule (or both!) are tight, it&#8217;s essential to keep things simple and not over-engineer.</p>
]]></content:encoded>
			<wfw:commentRss>http://rmd.com.au/archives/easter-egg-a-bastard/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

