<?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; prototype</title>
	<atom:link href="http://drawlogic.com/tag/prototype/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>Box2D based Javascript 2D Physics Engine called Box2DJS</title>
		<link>http://drawlogic.com/2009/02/18/box2d-based-javascript-2d-physics-engine-called-box2djs/</link>
		<comments>http://drawlogic.com/2009/02/18/box2d-based-javascript-2d-physics-engine-called-box2djs/#comments</comments>
		<pubDate>Wed, 18 Feb 2009 20:31:12 +0000</pubDate>
		<dc:creator>drawk</dc:creator>
				<category><![CDATA[ANIMATION]]></category>
		<category><![CDATA[DEVELOPMENT]]></category>
		<category><![CDATA[ENGINE]]></category>
		<category><![CDATA[GAMEDEV]]></category>
		<category><![CDATA[GAMES]]></category>
		<category><![CDATA[JAVASCRIPT]]></category>
		<category><![CDATA[LIBRARIES]]></category>
		<category><![CDATA[OPEN SOURCE]]></category>
		<category><![CDATA[PHYSICS]]></category>
		<category><![CDATA[TECHNOLOGY]]></category>
		<category><![CDATA[2d]]></category>
		<category><![CDATA[AS3]]></category>
		<category><![CDATA[FLASH]]></category>
		<category><![CDATA[prototype]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://drawlogic.com/?p=386</guid>
		<description><![CDATA[Box2D is responsible for inspiring many 2d physics engines including Motor2, Box2DFlashAS3 and others.  Box2D the original toolkit is a solid c++ physics engine that has many great examples and features including real collision. Now it has inspired a pure Javascript version of Box2D called Box2Djs to (using prototype dependency) to implement many of the [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.box2d.org/" target="_blank">Box2D</a> is responsible for inspiring many 2d physics engines including Motor2, Box2DFlashAS3 and others.  Box2D the original toolkit is a solid c++ physics engine that has many great examples and features including real collision.</p>
<p>Now it has<a href="http://box2d-js.sourceforge.net/index2.html" target="_blank"> inspired a pure Javascript version of Box2D called Box2Djs</a> to (using prototype dependency) to implement many of the same demos using the same functionality.  So it appears Box2D if you want to find a baseline standard physics kit for 2D, it now has versions in many languages that might allow you to have 2d physics capabilities across many platforms.</p>
<p><a href="http://box2d-js.sourceforge.net/index2.html" target="_blank"><img class="alignnone" title="box2d js" src="http://i81.photobucket.com/albums/j223/drawkbox/box2djs.png" alt="" width="392" height="230" /></a></p>
<blockquote><p>Box2DJS is a JavaScript port of <a href="http://www.box2d.org/" target="_blank">Box2D Physics Engine</a>. 		To tell the truth, this is converted from <a href="http://box2dflash.sourceforge.net/">Box2DFlashAS3</a>_1.4.3.1 in an automatic manner. 		(The reason why not Box2DFlashAS3_2.0.0 based is simply because I overlooked the renewal.)</p></blockquote>
<h3>Dependencies</h3>
<ul>
<li><a href="http://www.prototypejs.org/">prototype.js</a></li>
<li><a href="http://sourceforge.net/projects/iecanvas">IECanvas</a> (when you use a canvas tag to display the result of your physics simulation)</li>
</ul>
<p><a name="links"></a></p>
<h3>Links</h3>
<ul>
<li><a href="http://sourceforge.net/projects/box2d-js/">Project Page (SF)</a></li>
<li><a href="http://sourceforge.net/project/showfiles.php?group_id=227549">Download Page (SF)</a></li>
<li><a href="http://www.box2d.org/">Box2D</a></li>
<li><a href="http://box2dflash.sourceforge.net/">Box2DFlashAS3</a></li>
<li><a href="http://www.kyucon.com/doc/box2d/">API Doc (Box2DFlashAS3)</a></li>
</ul>
<h3>How to use</h3>
<ol>
<li> <a href="http://sourceforge.net/project/showfiles.php?group_id=227549">Download a zip file</a> and extract it.</li>
<li> Copy js/ and lib/ directories from the extracted directory to your app directory.</li>
<li> Copy script tags in the header part of index.html in the extacted directory to your html file where you want to simulate physics.
<p class="note">Because this library does not have a lazy-loading system now, you should load all classes before starting your simulation. To make things worse, each library has a bit complicated dependency each other so that loading libraries in wrong order may cause a fatal error. To avoid such a trouble, it is strongly recommended to copy the header part of this file or `index.html&#8217; including the downloaded zip file.</p>
</li>
<li> Utilizing Box2D APIs, simulate the newton world as you like.
<p class="note">The Box2DJS APIs are completely same as those of Box2DFlashAS3. Please refer <a href="http://www.kyucon.com/doc/box2d/">information about it</a>.</p>
</li>
</ol>
<p>Also the speed of your javascript engine makes a big difference just like the AS2 AVM1 to the AS3 AVM2 virtual machines.  Chrome is much faster than FF3.</p>
<h3>Video of Box2DJS in Chrome</h3>
<p>

<object width="540" height="450"><param name="movie" value="http://www.youtube.com/v/9mcXNCOpZHQ&hl=en&fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/9mcXNCOpZHQ&hl=en&fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="540" height="450"></embed></object>

</p>
<h3>Video of Box2DJS in FF3</h3>
<p>
<object width="540" height="450"><param name="movie" value="http://www.youtube.com/v/42yegPinLic&hl=en&fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/42yegPinLic&hl=en&fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="540" height="450"></embed></object>

</p>
]]></content:encoded>
			<wfw:commentRss>http://drawlogic.com/2009/02/18/box2d-based-javascript-2d-physics-engine-called-box2djs/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

