<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Creating levels through ActionScript</title>
	<atom:link href="http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/</link>
	<description>Flash Platform Geek</description>
	<lastBuildDate>Wed, 04 Jan 2012 21:31:54 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: stef</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-64</link>
		<dc:creator>stef</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-64</guid>
		<description>Weird... that level doesn&#039;t appear in the debugger... &lt;br /&gt;
&lt;br /&gt;
And it can be access from any clip like a real level... &lt;br /&gt;
&lt;br /&gt;
Funny...</description>
		<content:encoded><![CDATA[<p>Weird&#8230; that level doesn&#8217;t appear in the debugger&#8230; </p>
<p>And it can be access from any clip like a real level&#8230; </p>
<p>Funny&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: eokyere</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-65</link>
		<dc:creator>eokyere</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-65</guid>
		<description>omission... [cb]() shd be either &lt;br /&gt;
this[cb]() or eval(cb)()... pretty wierd code... it appears all you are really doing is creating a pointer to _level0... but pretty wierd code</description>
		<content:encoded><![CDATA[<p>omission&#8230; [cb]() shd be either <br />
this[cb]() or eval(cb)()&#8230; pretty wierd code&#8230; it appears all you are really doing is creating a pointer to _level0&#8230; but pretty wierd code</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Peter Elst</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-66</link>
		<dc:creator>Peter Elst</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-66</guid>
		<description>Thanks for that, I&#039;ve just fixed the typo!&lt;br /&gt;
&lt;br /&gt;
It&#039;s not a reference pointer in the sense that all variables and functions from _level0 are copied into the new level but from that point on they function independently.</description>
		<content:encoded><![CDATA[<p>Thanks for that, I&#8217;ve just fixed the typo!</p>
<p>It&#8217;s not a reference pointer in the sense that all variables and functions from _level0 are copied into the new level but from that point on they function independently.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: eokyere</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-67</link>
		<dc:creator>eokyere</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-67</guid>
		<description>yes... i realized that too when i tested it... but it isn&#039;t anything different from loading &quot;foo.swf&quot; into _levelBar, as long as &quot;foo.swf&quot; exists. In this case, u are sure _url (meaning this._url) exists, otherwise why woudl the swf be on in the first place ;P... what is interesting is it is listed as _levelX (_level2 in your case) but a trace of (_levelX._level, again _level2._level in your case) returns _level0... on a more serious note though, i don&#039;t think this is by design... the flash player shouldn&#039;t allow this type of behavior... unless it can be put to some good use? maybe others might have other views on this... and yes, it happens in player 7 too.</description>
		<content:encoded><![CDATA[<p>yes&#8230; i realized that too when i tested it&#8230; but it isn&#8217;t anything different from loading &#8220;foo.swf&#8221; into _levelBar, as long as &#8220;foo.swf&#8221; exists. In this case, u are sure _url (meaning this._url) exists, otherwise why woudl the swf be on in the first place ;P&#8230; what is interesting is it is listed as _levelX (_level2 in your case) but a trace of (_levelX._level, again _level2._level in your case) returns _level0&#8230; on a more serious note though, i don&#8217;t think this is by design&#8230; the flash player shouldn&#8217;t allow this type of behavior&#8230; unless it can be put to some good use? maybe others might have other views on this&#8230; and yes, it happens in player 7 too.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Peter Elst</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-68</link>
		<dc:creator>Peter Elst</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-68</guid>
		<description>True, though it is different than loading any other external SWF into a level because the movieclip assets are not copied in the new level and events do not function.&lt;br /&gt;
&lt;br /&gt;
You are correct in the fact that the newly created level still considers itself to be _level0, if you run _level2.createLevel it gets stuck in an infinite loop.&lt;br /&gt;
&lt;br /&gt;
Another strange thing is that I needed to add the conditional != undefined after the load process, it initially returns undefined but the next iteration of the script returns a pointer to the new level.</description>
		<content:encoded><![CDATA[<p>True, though it is different than loading any other external SWF into a level because the movieclip assets are not copied in the new level and events do not function.</p>
<p>You are correct in the fact that the newly created level still considers itself to be _level0, if you run _level2.createLevel it gets stuck in an infinite loop.</p>
<p>Another strange thing is that I needed to add the conditional != undefined after the load process, it initially returns undefined but the next iteration of the script returns a pointer to the new level.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: eokyere</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-69</link>
		<dc:creator>eokyere</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-69</guid>
		<description>i would think (and i&#039;m only speculating) the assets are not loaded into the new level because initially (or when loading), the movie still points to _level0 as it&#039;s level. If that is the case, then all assets (objects) loaded in the new movie (_level2 as in your example) would just be references to the original assets (objects) already at _level0... that is to say, _level2 is _level0 until _level2 is finally loaded and becomes its own level. I would think that is why it has references to the objects in _level0 and then breaks away on its own... thus objects created on it after it&#039;s loaded are not &#039;back-refrenceable&#039; at _level0 (as _level0.fooObjs)... u get my drift?</description>
		<content:encoded><![CDATA[<p>i would think (and i&#8217;m only speculating) the assets are not loaded into the new level because initially (or when loading), the movie still points to _level0 as it&#8217;s level. If that is the case, then all assets (objects) loaded in the new movie (_level2 as in your example) would just be references to the original assets (objects) already at _level0&#8230; that is to say, _level2 is _level0 until _level2 is finally loaded and becomes its own level. I would think that is why it has references to the objects in _level0 and then breaks away on its own&#8230; thus objects created on it after it&#8217;s loaded are not &#8216;back-refrenceable&#8217; at _level0 (as _level0.fooObjs)&#8230; u get my drift?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: eokyere</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-70</link>
		<dc:creator>eokyere</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-70</guid>
		<description>about the conditional != undefined, that is just how it should be. the first condition... if (loadLevel.getBytesLoaded()&gt;=loadLevel.getBytesTotal())... should decompose to... if (undefined &gt;= undefined)--which is always true-- when loadLevel (_level2) has not started loading... and that would be the situation for a couple of _level0.enterFrames... so that condition is necessary.&lt;br /&gt;
&lt;br /&gt;
btw... nice blog u have here</description>
		<content:encoded><![CDATA[<p>about the conditional != undefined, that is just how it should be. the first condition&#8230; if (loadLevel.getBytesLoaded()>=loadLevel.getBytesTotal())&#8230; should decompose to&#8230; if (undefined >= undefined)&#8211;which is always true&#8211; when loadLevel (_level2) has not started loading&#8230; and that would be the situation for a couple of _level0.enterFrames&#8230; so that condition is necessary.</p>
<p>btw&#8230; nice blog u have here</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Peter Elst</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-71</link>
		<dc:creator>Peter Elst</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-71</guid>
		<description>Some great points there eokyere, I&#039;ll certainly look into those! Love to hear if anyone has any other speculations as to what happens or perhaps even an idea if it could be useful for anything at all :)</description>
		<content:encoded><![CDATA[<p>Some great points there eokyere, I&#8217;ll certainly look into those! Love to hear if anyone has any other speculations as to what happens or perhaps even an idea if it could be useful for anything at all :)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matthias Kannengiesser</title>
		<link>http://www.peterelst.com/blog/2003/11/28/creating-levels-through-actionscript/comment-page-1/#comment-72</link>
		<dc:creator>Matthias Kannengiesser</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">/?p=29#comment-72</guid>
		<description>Hi Peter,&lt;br /&gt;
&lt;br /&gt;
I noticed that nice germ in June. Try this and you will see it even works with onEnterFrame, functions and more.&lt;br /&gt;
&lt;br /&gt;
loadMovie(&quot;nofile&quot;, &quot;_level100&quot;);&lt;br /&gt;
this.onEnterFrame = function() {&lt;br /&gt;
        if (_level100) {&lt;br /&gt;
                (trace(_level100+&quot; </description>
		<content:encoded><![CDATA[<p>Hi Peter,</p>
<p>I noticed that nice germ in June. Try this and you will see it even works with onEnterFrame, functions and more.</p>
<p>loadMovie(&#8220;nofile&#8221;, &#8220;_level100&#8243;);<br />
this.onEnterFrame = function() {<br />
        if (_level100) {<br />
                (trace(_level100+&#8221;</p>
]]></content:encoded>
	</item>
</channel>
</rss>

