<?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; XHTML</title>
	<atom:link href="http://drawlogic.com/category/xhtml/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>AS3 Flash, Flex and Unity3D Browser Communication and Scripting with Javascript</title>
		<link>http://drawlogic.com/2008/11/28/as3-flash-flex-and-unity3d-browser-communication-with-javascript/</link>
		<comments>http://drawlogic.com/2008/11/28/as3-flash-flex-and-unity3d-browser-communication-with-javascript/#comments</comments>
		<pubDate>Fri, 28 Nov 2008 08:57:15 +0000</pubDate>
		<dc:creator>drawk</dc:creator>
				<category><![CDATA[ACTIONSCRIPT]]></category>
		<category><![CDATA[ACTIONSCRIPT3]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[APPLICATIONS]]></category>
		<category><![CDATA[AS3]]></category>
		<category><![CDATA[DEVELOPMENT]]></category>
		<category><![CDATA[FLASH]]></category>
		<category><![CDATA[FLEX]]></category>
		<category><![CDATA[GAMEDEV]]></category>
		<category><![CDATA[GAMES]]></category>
		<category><![CDATA[INTERACTIVE]]></category>
		<category><![CDATA[INTERFACE]]></category>
		<category><![CDATA[JAVASCRIPT]]></category>
		<category><![CDATA[LIBRARIES]]></category>
		<category><![CDATA[OPEN SOURCE]]></category>
		<category><![CDATA[PROGRAMMING]]></category>
		<category><![CDATA[SILVERLIGHT]]></category>
		<category><![CDATA[SNIPPETS]]></category>
		<category><![CDATA[TECHNOLOGY]]></category>
		<category><![CDATA[TOOLS]]></category>
		<category><![CDATA[TUTORIAL]]></category>
		<category><![CDATA[unity3d]]></category>
		<category><![CDATA[XHTML]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[communication]]></category>
		<category><![CDATA[externalinterface]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[integrate]]></category>
		<category><![CDATA[page]]></category>
		<category><![CDATA[scripting]]></category>
		<category><![CDATA[unity]]></category>

		<guid isPermaLink="false">http://drawlogic.com/?p=284</guid>
		<description><![CDATA[I am working with lots of content now that is flash and unity3d in game development for the web, and occasionally systems built in flash, javascript or other have to communicate with Unity3D and vice versa.  You can do this from the server side (WWW/WWWForm class or sockets) OR you can also communicate client side [...]]]></description>
			<content:encoded><![CDATA[<p>I am working with lots of content now that is flash and unity3d in game development for the web, and occasionally systems built in flash, javascript or other have to communicate with Unity3D and vice versa.  You can do this from the server side (<a href="http://unity3d.com/support/documentation/ScriptReference/WWW.html" target="_blank">WWW</a>/<a href="http://unity3d.com/support/documentation/ScriptReference/WWWForm.html" target="_blank">WWWForm </a>class or sockets) OR you can also communicate client side for many things such as sending name value pairs or variables into Unity3D, Flash or the javascript in page as needed. There are some great tools like <a title="UnityObject" href="http://www.unifycommunity.com/wiki/index.php?title=UnityObject" target="_blank">UnityObject</a> that is like swfobject (only you have to update it to work with latest browsers) that make this more simple to send in params and messages. The same can be applied to Silverlight. It is pretty simple all in all but having a sample to start with is good with all these technologies.</p>
<p><a href="http://www.paultondeur.com/2008/11/12/unity3d-communication-with-browser-and-flash/" target="_blank">Paul Tondeur threw togetother a little sample</a> that shows how you can integrate Unity3D, Flash and javascript in the page fairly simply with lots of great demos.  It really is just about passing parameters around into the objects from javascript, then within Flash calling ExternalInterface to call external javascript or within Unity3D calling Application.ExternalCall.</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #006600; font-style: italic;">//Flash adding callback for javascript code</span>
ExternalInterface.<span style="color: #660066;">addCallback</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;functionNameInBrowser&quot;</span><span style="color: #339933;">,</span> functionNameInFlash <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #006600; font-style: italic;">//Unity3D calling javascript code</span>
Application.<span style="color: #660066;">ExternalCall</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;javascriptFunction&quot;</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">&quot;Parameter1&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Nothing too tasking but <a href="http://www.paultondeur.com/2008/11/12/unity3d-communication-with-browser-and-flash/" target="_blank">if you want to see samples of this working together from flash, flex, javascript, unity3d</a> then check it out. Zip on over to Paul&#8217;s site to grab the files and more demos and samples. <a title="Download examples" href="http://www.paultondeur.com/files/Unity3DBrowserScripting/Unity3DBrowserScripting.zip">All examples are bundled in one download</a>, which includes all the Unity3D, Flash, Flex, Actionscript and Javascript files.</p>
<p><strong>Here&#8217;s some demos</strong></p>
<ul>
<li><a title="Unity3D Browserchat" href="http://www.paultondeur.com/files/Unity3DBrowserScripting/examples/UnityFlexChat/UnityFlexChat.html" target="_blank">Build a Unity3D &#8220;browserchat&#8221;</a></li>
<li><a title="Clickable Unity3D objects" href="http://www.paultondeur.com/files/Unity3DBrowserScripting/examples/UnityHandleClick/UnityHandleClick.html" target="_blank">Make Unity3D objects clickable and load content in Flash</a></li>
<li><a title="Drag Unity3D objects in Flash" href="http://www.paultondeur.com/files/Unity3DBrowserScripting/examples/DragUnity/DragUnity.html" target="_blank">Drag a rectangle in Flash and drag an cube in Unity3D</a></li>
<li><a title="Advanced Unity3D dragging in Flash" href="http://www.paultondeur.com/files/Unity3DBrowserScripting/examples/DragAdvancedUnity3D/DragAdvancedUnity.html" target="_blank">Add, delete and drag objects from the Flash interface and show this in Unity3D</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://drawlogic.com/2008/11/28/as3-flash-flex-and-unity3d-browser-communication-with-javascript/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>What was SWFObject and UFO is now one SWFfix for Embedding Flash in XHTML/HTML</title>
		<link>http://drawlogic.com/2007/06/04/what-was-swfobject-and-ufo-is-now-one-swffix-for-embedding-flash-in-xhtmlhtml/</link>
		<comments>http://drawlogic.com/2007/06/04/what-was-swfobject-and-ufo-is-now-one-swffix-for-embedding-flash-in-xhtmlhtml/#comments</comments>
		<pubDate>Tue, 05 Jun 2007 03:37:09 +0000</pubDate>
		<dc:creator>drawk</dc:creator>
				<category><![CDATA[ACTIONSCRIPT]]></category>
		<category><![CDATA[ANIMATION]]></category>
		<category><![CDATA[ARCHITECT]]></category>
		<category><![CDATA[FLASH]]></category>
		<category><![CDATA[INTERFACE]]></category>
		<category><![CDATA[JAVASCRIPT]]></category>
		<category><![CDATA[LIBRARIES]]></category>
		<category><![CDATA[STANDARDS]]></category>
		<category><![CDATA[TOOLS]]></category>
		<category><![CDATA[XHTML]]></category>

		<guid isPermaLink="false">http://drawk.wordpress.com/2007/06/04/what-was-swfobject-and-ufo-is-now-one-swffix-for-embedding-flash-in-xhtmlhtml/</guid>
		<description><![CDATA[In case you haven&#8217;t heard the SWFObject creator Geoff Stearns and the UFO creator have teamed up to create a new Flash Embed kit for HTML/XHTML called SWFFix that is more DOM compliant yet works.  Its always been a battle on this front of DOM standards vs Javascript when it comes to Flash embedding. This teamwork to [...]]]></description>
			<content:encoded><![CDATA[<p><a target="_blank" href="http://www.swffix.org/devblog/"><img border="0" align="right" src="http://i81.photobucket.com/albums/j223/drawkbox/swffix.png" alt="Photo Sharing and Video Hosting at Photobucket" /></a>In case you haven&#8217;t heard the <a target="_blank" href="http://blog.deconcept.com/2007/02/28/swfobject-1-5-released/">SWFObject creator Geoff Stearns</a> and the UFO creator have teamed up to create a <a target="_blank" href="http://www.alistapart.com/articles/flashembedcagematch/">new Flash Embed kit for HTML/XHTML called SWFFix</a> that is more DOM compliant yet works.  Its always been a battle on this front of DOM standards vs Javascript when it comes to Flash embedding.</p>
<p>This teamwork to make a common kit will help to consolidate all issues with this and hopefully provide a really solid platform for embedding flash that takes into account all browser and satisfies standards but also works all the time. Making it harder to vote against when it comes time to decide what technology to use.</p>
<p>Of course there have been libraries like <a target="_blank" href="http://www.asual.com/swfaddress/">SWFAddress</a> (for deep linking in flash and back button support easily) that have been built on top of SWFObject that will have to be switched over that have large user bases and following.</p>
<p><a target="_blank" href="http://www.swffix.org/devblog/">Check out SWFfix</a> (of course this project has been very quiet and is not public since Feb 6-7th) hrm.</p>
]]></content:encoded>
			<wfw:commentRss>http://drawlogic.com/2007/06/04/what-was-swfobject-and-ufo-is-now-one-swffix-for-embedding-flash-in-xhtmlhtml/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

