<?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: Understanding AS3 shared objects</title>
	<atom:link href="http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/</link>
	<description>italian geek and PROgrammer</description>
	<lastBuildDate>Fri, 10 Feb 2012 12:12:29 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
	<item>
		<title>By: diego nunes</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-847483</link>
		<dc:creator>diego nunes</dc:creator>
		<pubDate>Mon, 06 Jun 2011 11:11:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-847483</guid>
		<description>. . I though it would be worth to mention that the &quot;close&quot; method is only appliable to Remote Shared Objects. Since you&#039;re using &quot;getLocal&quot; for a locally stored Shared Object, you really don&#039;t need it.
. . Using &quot;flush&quot;, on the other hand, to explicitly persist the data, would be helpful to avoid any problem if the flash gets force closed.

. Amplexos.</description>
		<content:encoded><![CDATA[<p>. . I though it would be worth to mention that the &#8220;close&#8221; method is only appliable to Remote Shared Objects. Since you&#8217;re using &#8220;getLocal&#8221; for a locally stored Shared Object, you really don&#8217;t need it.<br />
. . Using &#8220;flush&#8221;, on the other hand, to explicitly persist the data, would be helpful to avoid any problem if the flash gets force closed.</p>
<p>. Amplexos.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Criando a estrutura de um jogo em flash – 3ª parte &#171; Tentativa de Programação</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-822844</link>
		<dc:creator>Criando a estrutura de um jogo em flash – 3ª parte &#171; Tentativa de Programação</dc:creator>
		<pubDate>Sat, 30 Apr 2011 04:25:14 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-822844</guid>
		<description>[...] que até onde entendi, funciona +- como cookies de navegação. Tem alguma explicação nesse guia aqui e também tem os meus comentários no código fonte que vou disponibilizar logo abaixo, lá tem [...]</description>
		<content:encoded><![CDATA[<p>[...] que até onde entendi, funciona +- como cookies de navegação. Tem alguma explicação nesse guia aqui e também tem os meus comentários no código fonte que vou disponibilizar logo abaixo, lá tem [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Simon</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-752118</link>
		<dc:creator>Simon</dc:creator>
		<pubDate>Fri, 11 Feb 2011 14:21:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-752118</guid>
		<description>Can someone help me please, I&#039;m struggling with this coding, it&#039;s a simple cookie (LSO) detection system but I can&#039;t get it to run with writing the text below no matter what I try.

// Create Flash Cookie (LSO)
var cookie:SharedObject = SharedObject.getLocal(&quot;SiteLog&quot;); 
// first visit, i.e, cookie hasn&#039;t been set
if (cookie.data.played == undefined) 
{ 
// set cookie to true 
    cookie.data.played = true; 
    cookie.flush(); // write the data
	trace(&quot;Data written, first visit&quot;);
}
else 
{ 
// return visit
	
	trace(&quot;Data acknowleged, return trip to site&quot;);
} 
// clear the Shared Object for testing
 
function clearCookie(evt:MouseEvent):void {
	cookie.clear();
	trace(&quot;Cookie Removed&quot;);
}; 
clearCookie_btn.addEventListener(MouseEvent.CLICK, clearCookie);

- I want to have this come on screen after it&#039;s loaded for the second time :


var txt:TextField = new TextField();
txt.text = &quot;Republic of Code&quot;;
addChild(txt);


Any help would be great.</description>
		<content:encoded><![CDATA[<p>Can someone help me please, I&#8217;m struggling with this coding, it&#8217;s a simple cookie (LSO) detection system but I can&#8217;t get it to run with writing the text below no matter what I try.</p>
<p>// Create Flash Cookie (LSO)<br />
var cookie:SharedObject = SharedObject.getLocal(&#8220;SiteLog&#8221;);<br />
// first visit, i.e, cookie hasn&#8217;t been set<br />
if (cookie.data.played == undefined)<br />
{<br />
// set cookie to true<br />
    cookie.data.played = true;<br />
    cookie.flush(); // write the data<br />
	trace(&#8220;Data written, first visit&#8221;);<br />
}<br />
else<br />
{<br />
// return visit</p>
<p>	trace(&#8220;Data acknowleged, return trip to site&#8221;);<br />
}<br />
// clear the Shared Object for testing</p>
<p>function clearCookie(evt:MouseEvent):void {<br />
	cookie.clear();<br />
	trace(&#8220;Cookie Removed&#8221;);<br />
};<br />
clearCookie_btn.addEventListener(MouseEvent.CLICK, clearCookie);</p>
<p>- I want to have this come on screen after it&#8217;s loaded for the second time :</p>
<p>var txt:TextField = new TextField();<br />
txt.text = &#8220;Republic of Code&#8221;;<br />
addChild(txt);</p>
<p>Any help would be great.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Rennan</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-724886</link>
		<dc:creator>Rennan</dc:creator>
		<pubDate>Tue, 11 Jan 2011 17:40:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-724886</guid>
		<description>I´ve made this class based on your post. It´s simple. But, maybe it help someone. If someone have some idea, please, implement it.

package 
{
	import flash.net.SharedObject;

	public class SavePoint
	{
		private static  var shared:SharedObject = SharedObject.getLocal(&quot;save_point&quot;);

		public function SavePoint ()
		{

		}
		public static function Save (object:Object):void
		{
			if (object!=null)
			{
				shared.data.box = object;
			}
			else
			{
				Erase ();
				trace (&quot;Error - Argument &#039;object&#039; can not receive null values!&quot;);
			}
		}
		public static function Load ():Object
		{
			var obj:Object = shared.data.box;
			return obj;
		}
		public static function Erase ():void
		{
			shared.clear ();

		}
		public static function Update (object:Object):void
		{
			// TODO
		}
	}
}</description>
		<content:encoded><![CDATA[<p>I´ve made this class based on your post. It´s simple. But, maybe it help someone. If someone have some idea, please, implement it.</p>
<p>package<br />
{<br />
	import flash.net.SharedObject;</p>
<p>	public class SavePoint<br />
	{<br />
		private static  var shared:SharedObject = SharedObject.getLocal(&#8220;save_point&#8221;);</p>
<p>		public function SavePoint ()<br />
		{</p>
<p>		}<br />
		public static function Save (object:Object):void<br />
		{<br />
			if (object!=null)<br />
			{<br />
				shared.data.box = object;<br />
			}<br />
			else<br />
			{<br />
				Erase ();<br />
				trace (&#8220;Error &#8211; Argument &#8216;object&#8217; can not receive null values!&#8221;);<br />
			}<br />
		}<br />
		public static function Load ():Object<br />
		{<br />
			var obj:Object = shared.data.box;<br />
			return obj;<br />
		}<br />
		public static function Erase ():void<br />
		{<br />
			shared.clear ();</p>
<p>		}<br />
		public static function Update (object:Object):void<br />
		{<br />
			// TODO<br />
		}<br />
	}<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Code snippets for the future &#171; Jon Reids FMP</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-707454</link>
		<dc:creator>Code snippets for the future &#171; Jon Reids FMP</dc:creator>
		<pubDate>Sun, 19 Dec 2010 17:11:18 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-707454</guid>
		<description>[...] be looking at this post to help me understand shared objects, and handily, adobe have posted up all the chapters of AS3 [...]</description>
		<content:encoded><![CDATA[<p>[...] be looking at this post to help me understand shared objects, and handily, adobe have posted up all the chapters of AS3 [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Complete Flash Sokoban game in less than 2KB - Emanuele Feronato</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-580174</link>
		<dc:creator>Complete Flash Sokoban game in less than 2KB - Emanuele Feronato</dc:creator>
		<pubDate>Wed, 19 May 2010 13:54:15 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-580174</guid>
		<description>[...] 10 levels * Tiles of different color and shape * Shared objects to save the games * Eye-candy effects (being only 2KB!!) to show completed levels and current level [...]</description>
		<content:encoded><![CDATA[<p>[...] 10 levels * Tiles of different color and shape * Shared objects to save the games * Eye-candy effects (being only 2KB!!) to show completed levels and current level [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Broxter</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-537401</link>
		<dc:creator>Broxter</dc:creator>
		<pubDate>Thu, 14 Jan 2010 14:40:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-537401</guid>
		<description>Thanks a lot! Just what I was looking for.</description>
		<content:encoded><![CDATA[<p>Thanks a lot! Just what I was looking for.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Oct 22 Week 04 Make Up Class &#171; Flash For Artists</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-512344</link>
		<dc:creator>Oct 22 Week 04 Make Up Class &#171; Flash For Artists</dc:creator>
		<pubDate>Thu, 22 Oct 2009 19:24:13 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-512344</guid>
		<description>[...] http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/ [...]</description>
		<content:encoded><![CDATA[<p>[...] <a href="http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/" rel="nofollow">http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/</a> [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Flash for Thought &#171; Interactive Design II</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-508908</link>
		<dc:creator>Flash for Thought &#171; Interactive Design II</dc:creator>
		<pubDate>Wed, 14 Oct 2009 03:21:29 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-508908</guid>
		<description>[...] http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/ [...]</description>
		<content:encoded><![CDATA[<p>[...] <a href="http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/" rel="nofollow">http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/</a> [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tutorial: Sharing shared objects between games/applications &#171; the keg&#8217;o'grog blog</title>
		<link>http://www.emanueleferonato.com/2008/12/28/understanding-as3-shared-objects/#comment-458238</link>
		<dc:creator>Tutorial: Sharing shared objects between games/applications &#171; the keg&#8217;o'grog blog</dc:creator>
		<pubDate>Sat, 06 Jun 2009 15:47:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.emanueleferonato.com/?p=804#comment-458238</guid>
		<description>[...] youself familiar with Saving and Loading in Flash by reading this tutorial or this tutorial. Thanks to Michael and Emanuele for this. You should also bookmark their blogs, these guys are [...]</description>
		<content:encoded><![CDATA[<p>[...] youself familiar with Saving and Loading in Flash by reading this tutorial or this tutorial. Thanks to Michael and Emanuele for this. You should also bookmark their blogs, these guys are [...]</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using disk: enhanced
Database Caching 6/11 queries in 0.010 seconds using disk: basic

Served from: www.emanueleferonato.com @ 2012-02-11 04:45:14 -->
