<?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"
	>

<channel>
	<title>Potential Blog</title>
	<atom:link href="http://www.potentialgames.com/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.potentialgames.com/blog</link>
	<description>Notes of a Potential Independent Game Developer</description>
	<pubDate>Thu, 09 Oct 2008 19:25:50 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
	<language>en</language>
			<item>
		<title>Login Security: Password Hashing Techniques</title>
		<link>http://www.potentialgames.com/blog/2008/10/09/login-security-password-hashing-techniques/</link>
		<comments>http://www.potentialgames.com/blog/2008/10/09/login-security-password-hashing-techniques/#comments</comments>
		<pubDate>Thu, 09 Oct 2008 19:25:50 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Developer's Cave]]></category>

		<category><![CDATA[cryptography]]></category>

		<category><![CDATA[programming]]></category>

		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=203</guid>
		<description><![CDATA[In support of Cyber Security Awareness Month, this article is written as a tutorial on basic login security, including techniques to defend against potential vulnerabilities. I encourage anyone with a software security background to comment on this article. Although I have some years of software security experience, peer review is essential for building secure systems.
TIP: [...]]]></description>
			<content:encoded><![CDATA[<p>In support of <em>Cyber Security Awareness Month</em>, this article is written as a tutorial on basic login security, including techniques to defend against potential vulnerabilities. I encourage anyone with a software security background to comment on this article. Although I have some years of software security experience, peer review is essential for building secure systems.</p>
<blockquote><p><strong>TIP:</strong> Any and all security techniques (including these) should be considered experimental until thoroughly reviewed by the security community.</p></blockquote>
<p><span id="more-203"></span></p>
<p>The most common form of <em>login</em> (gaining access to a system) involves transmitting a username-password pair (the user&#8217;s <em>credentials</em>) to a server for <em>authentication</em> (confidence in the user&#8217;s identity) and <em>authorization</em> (right to access said system). This article describes techniques used by the Potential RPG platform to improve login security, but the approach can be applied to any similar system.</p>
<p>The first step to improving login security is to avoid exposing a user&#8217;s <em>plaintext</em> password. The common approach is to <a href="http://en.wikipedia.org/wiki/Secure_hash_function"><em>hash</em></a> the password, sending the resulting hash value to the server in place of the <em>plaintext</em> password. The server compares this hash value against the hash value stored in the player&#8217;s account. Thus, the hash value of the <em>plaintext</em> password (along with the username) becomes the user&#8217;s <em>authenticator</em>. The <em>plaintext</em> password is never stored or transmitted. The hashed <em>authenticator</em> can even be stored on the client to allow automatic login.</p>
<blockquote><p><strong>TIP:</strong> Legacy software (and many Web-based applications) send the user&#8217;s <em>plaintext</em> password over the network. No modern software has any excuse for ever transmitting or storing a user&#8217;s <em>plaintext</em> password.</p></blockquote>
<p>This basic form of hashing conceals the <em>plaintext</em> password, but has several weaknesses. Suppose you use the same password for several sites (<code>TIP: Don't.</code>). Even though your <em>plaintext</em> password has not been revealed, the hashed <em>authenticator</em> still grants access to your account on any system using the same hash function. Similarly, different users with the same password will have the same hashed <em>authenticator</em>. Since many systems use the (legacy) MD5 hash function, a simple hash is not sufficient to protect your credentials.</p>
<blockquote><p><strong>TIP:</strong> Don&#8217;t use the MD5 hash function. Minimally, use <a href="http://en.wikipedia.org/wiki/SHA_hash_functions">SHA-256</a>. Consider going one step further and use the <em>double-hashing</em> technique defined in <a href="http://www.schneier.com/book-practical.html"><u>Practical Cryptography</u> (Ferguson and Schneier, 2003)</a>.</p></blockquote>
<p>The Potential RPG platform protects your password by mixing in additional information when hashing. Specifically, your password, username, and a system-unique value are hashed together to form your login <em>authenticator</em>. By incorporating these values, each authenticator becomes specific to this game and the user. The authenticators cannot be used on other systems, even if the user has the same password. Users with the same password will not have the same authenticator.</p>
<p>As an added bonus, the above technique defends against <em>dictionary attacks</em>. The purpose of a dictionary attack is to reveal the <em>plaintext</em> password of a hashed <em>authenticator</em>. Dictionary attacks against basic hashing work by pre-computing a <em>dictionary</em> of hash values for all possible passwords. If your hashed <em>authenticator</em> is in the dictionary, your <em>plaintext</em> password is easily revealed. A single dictionary can be used to expose the passwords of many users, for any system using basic password hashing with the same hash function.</p>
<p>By mixing in a system-unique value and username with each password, a dictionary would have to be computed for each system and for <em>each user</em>. This essentially renders a pure dictionary attack more expensive than would be worthwhile.</p>
<blockquote><p><strong>TIP:</strong> Making an attack more <em>expensive</em> increases overall security.</p></blockquote>
<p>Consider a more valuable target: The server&#8217;s database of user authenticators. Before storing any authenticators or authenticating any logins, have the server perform another round of hashing. The one-way nature of secure hash functions effectively devalues the authenticator database, because those values cannot be used to log in.</p>
<blockquote><p><strong>TIP:</strong> <em>Devaluing</em> a target increases overall security.</p></blockquote>
<p>Unfortunately, all this password hardening still does not secure the login process itself. If an authenticator is stolen from a client&#8217;s cache, or in transit to the server (during login), that authenticator can be used to log in as the user. This is an example of a <em>replay attack</em> (the login information is copied by an adversary and resent later). The password hashing techniques described are still a valuable component of the security system, providing <em>defense in depth</em>, but another layer of security must be added to further protect the login process.</p>
<p>Several strategies can be used to protect and conceal data in transit, but this article only covers password hashing.  Besides, this is only Cyber Security <em>Awareness</em> Month. This month, I only need to make you <em>aware</em> of security issues. Later, we can discuss how to defend against further security vulnerabilities.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/10/09/login-security-password-hashing-techniques/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Static: The Dark Side of Design</title>
		<link>http://www.potentialgames.com/blog/2008/10/03/static-the-dark-side-of-design/</link>
		<comments>http://www.potentialgames.com/blog/2008/10/03/static-the-dark-side-of-design/#comments</comments>
		<pubDate>Fri, 03 Oct 2008 13:42:41 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Developer's Cave]]></category>

		<category><![CDATA[design patterns]]></category>

		<category><![CDATA[Java]]></category>

		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=184</guid>
		<description><![CDATA[Students of software must be taught early the benefits of object oriented design, lest they succumb to the dark side of static programming. When designing a software component, the temptation can be to write globally accessible public static methods in lieu of instantiable objects. Even experienced developers must remain diligent to avoid being turned to [...]]]></description>
			<content:encoded><![CDATA[<p>Students of software must be taught early the benefits of object oriented design, lest they succumb to the dark side of <em>static</em> programming. When designing a software component, the temptation can be to write globally accessible <code>public static</code> methods in lieu of instantiable objects. Even experienced developers must remain diligent to avoid being turned to this quicker, more seductive, approach. <span id="more-184"></span></p>
<p>The <code>static</code> keyword (in Java) is an important language feature, but can be easily abused, leading to several problems.</p>
<p>One problem is <em>static cling</em> syndrome: Static methods beget static methods. Once you start coding with global access methods, other parts of the system tend toward static access. Eventually, the design degenerates into unmaintainable spaghetti code.</p>
<p>Another drawback is initialization. A static system that requires an initialization method to be called is error prone. Consider Java&#8217;s class loading system, which may trigger static method calls just by accessing a class.</p>
<p>Purely static code may also break other software features, such as modular component design. The static API can be called from any object in any module at any time with no access control or coordination. In some cases, this type of global access is desirable. For example, a fully instance-based (non-static) logging system would require passing the logging object throughout the code, permeating every class with its presence.</p>
<p>If your code has given in to the dark side of static design, do not despair; there may still be some good left in it, and you may be able to save the design before it destroys itself. Attempt to reform the design by rewriting it with instance-based objects. This is your <em>library</em> implementation. If global access is needed (as with the logging example), follow the <em>singleton</em> pattern and provide static access to a single instance of the system.</p>
<p>Do not underestimate the power of an object design. Even though it still involves global static access, the singleton provides several benefits. For one, you can eliminate <em>static cling</em> by implementing helper classes as objects. Premature access problems are eliminated (or at least exposed), since there is no singleton instance to call until proper initialization is performed. The singleton pattern tempers the dark side, and is the tool of a more civilized design.</p>
<p>You might tell yourself that <em>you&#8217;re not afraid</em> of the dangers of a static design. Once you are faced with debugging an evil static system, only to find that your adversary is your very own code staring back at you, you will be; you will be&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/10/03/static-the-dark-side-of-design/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Serialized Data Survivability</title>
		<link>http://www.potentialgames.com/blog/2008/09/26/serialized-data-survivability/</link>
		<comments>http://www.potentialgames.com/blog/2008/09/26/serialized-data-survivability/#comments</comments>
		<pubDate>Fri, 26 Sep 2008 16:48:34 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Developer's Cave]]></category>

		<category><![CDATA[Potential RPG]]></category>

		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=170</guid>
		<description><![CDATA[Serialized object data is inherently fragile. A change in one class effectively renders any serialized data that includes the class (even deep within the object graph) unusable. This article describes how I have (potentially) addressed this problem in my MMORPG platform. 
First, consider the cases in which data serialization (a.k.a. marshalling and unmarshalling bytes) are [...]]]></description>
			<content:encoded><![CDATA[<p>Serialized object data is inherently fragile. A change in one class effectively renders any serialized data that includes the class (even deep within the object graph) unusable. This article describes how I have (potentially) addressed this problem in my MMORPG platform. <span id="more-170"></span></p>
<p>First, consider the cases in which data serialization (a.k.a. marshalling and unmarshalling bytes) are used on this project. I am serializing objects for client-server network transport, client data cache, and server persistent storage. Without any special care, any class changes could/would break compatibility with old versions of the data. This situation is evident to any Alpha Playtester, as I usually wipe out the database after major updates.</p>
<p>Notice that client-side cache data can be (and is) expunged if any data structure has become incompatible. Also, since I&#8217;m using Java Web Start (at least provisionally), I can assume all users are running the latest version of the client software. Therefore, transport compatibility is not a big concern. Nonetheless, other projects may support clients of varying versions. Although I&#8217;m not explicitly dealing with this scenario, the technique described below could be used to support <a href="http://en.wikipedia.org/wiki/Forward_compatibility"><em>forward compatibility</em></a>. </p>
<p>For the server, serialized data must survive code changes.</p>
<p>The standard advice is to avoid the problem; either maintain yet another external data format, or never change your objects. Since the former is undesirable, and the latter impossible, I&#8217;ve attempted to come up with a more robust approach.</p>
<p>Although Potential RPG is (so far) <em>100% Pure Java</em>, I am <strong>not</strong> using Java&#8217;s built-in Serialization mechanism. Java Serialization is designed (rather elegantly, actually) for convenience at the expense of robustness. Even for core Java classes, the documentation explicitly warns that serialized data is likely to break between Java versions. Using Java&#8217;s <code>Externalizable</code> interface is an option, but this still binds the developer to Java&#8217;s Serialization mechanics.</p>
<p>The approach I&#8217;ve developed is an object <em>packing/unpacking</em> system, in which each <em>serializable</em> class has an accompanying byte-handling <code>Packer</code> helper class. This is functionally equivalent to a class-based Externalizable system (but with a cleaner API, IMHO).</p>
<p>The problem of <em>survivability</em> remains. The <strong>one-byte solution</strong> is to insert a <em>packing schema version</em> byte before each object&#8217;s data. This version is given to the unpacking method when unmarshalling the bytes. The unpacking method can include logic to (a) skip defunct fields and/or (b) set default values for missing fields. This technique provides backward compatibility. (Adapting to future versions is more complex, so I&#8217;ll ignore that on this project&#8230;)</p>
<p>Under this design, maintaining backward data compatibility for a class is a matter of augmenting the <em>unpacking</em> routine. Notice that the <em>packing</em> routine always produces an updated serialized data structure. Therefore, it is possible to write a routine that upgrades the database in one pass; or, the server can be left to lazily update objects as it encounters them.</p>
<p>For Playtesters, the next Alpha release will impose a mandatory database reset. After that, if I am diligent in my code, the test world should survive future updates.</p>
<p>Further reading: <a href="http://www.macchiato.com/columns/Durable4.html">Durable Java: Serialization</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/09/26/serialized-data-survivability/feed/</wfw:commentRss>
		</item>
		<item>
		<title>RPG Alpha5 (and then some)</title>
		<link>http://www.potentialgames.com/blog/2008/09/16/alpha5-and-then-some/</link>
		<comments>http://www.potentialgames.com/blog/2008/09/16/alpha5-and-then-some/#comments</comments>
		<pubDate>Wed, 17 Sep 2008 03:05:39 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Potential RPG]]></category>

		<category><![CDATA[RPG Alpha]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=165</guid>
		<description><![CDATA[Alpha5 (v0.5.0) was released earlier today&#8230; and then v0.5.0.1 to fix some issues that were found almost immediately by the intrepid playtesters. Alpha playtesters should see this forum topic to learn why&#8230;
I expect everyone to be walking around at Level 16 with Double Battleaxes and Expert Regeneration skill by tomorrow.
&#8230; That gives you one hour [...]]]></description>
			<content:encoded><![CDATA[<p>Alpha5 (v0.5.0) was released earlier today&#8230; and then v0.5.0.1 to fix some issues that were found almost immediately by the intrepid playtesters. <a href="http://www.potentialgames.com/forums/viewtopic.php?f=5&#038;t=94">Alpha playtesters should see this forum topic</a> to learn why&#8230;<br />
<blockquote>I expect everyone to be walking around at Level 16 with Double Battleaxes and Expert Regeneration skill by tomorrow.</p></blockquote>
<p>&#8230; That gives you one hour until tomorrow. Have at it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/09/16/alpha5-and-then-some/feed/</wfw:commentRss>
		</item>
		<item>
		<title>RPG Alpha (v0.4.2)</title>
		<link>http://www.potentialgames.com/blog/2008/09/12/rpg-alpha-v042/</link>
		<comments>http://www.potentialgames.com/blog/2008/09/12/rpg-alpha-v042/#comments</comments>
		<pubDate>Sat, 13 Sep 2008 00:11:19 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Potential RPG]]></category>

		<category><![CDATA[RPG Alpha]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=161</guid>
		<description><![CDATA[I haven&#8217;t stopped typing since last Friday&#8217;s incremental release, so here&#8217;s another for-the-sake-of-Friday update, which includes two dozen fixes and enhancements. Alpha playtesters can read this forum entry for the details.
]]></description>
			<content:encoded><![CDATA[<p>I haven&#8217;t stopped typing since last Friday&#8217;s incremental release, so here&#8217;s another for-the-sake-of-Friday update, which includes two dozen fixes and enhancements. <a href="http://www.potentialgames.com/forums/viewtopic.php?f=5&#038;t=93">Alpha playtesters can read this forum entry for the details.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/09/12/rpg-alpha-v042/feed/</wfw:commentRss>
		</item>
		<item>
		<title>RPG Alpha Update (v0.4.1)</title>
		<link>http://www.potentialgames.com/blog/2008/09/05/rpg-alpha-update-v041/</link>
		<comments>http://www.potentialgames.com/blog/2008/09/05/rpg-alpha-update-v041/#comments</comments>
		<pubDate>Fri, 05 Sep 2008 18:28:47 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Potential RPG]]></category>

		<category><![CDATA[RPG Alpha]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=158</guid>
		<description><![CDATA[For RPG Alpha Playtesters, I&#8217;ve released an incremental update (v0.4.1). Why? Mostly because it&#8217;s Friday. Also, I&#8217;ve tampered with (er, improved) a lot of code since the last release. See this forum topic for details (and comments on future releases).
]]></description>
			<content:encoded><![CDATA[<p>For RPG Alpha Playtesters, I&#8217;ve released an incremental update (v0.4.1). Why? Mostly because it&#8217;s Friday. Also, I&#8217;ve tampered with (er, <em>improved</em>) a lot of code since the last release. <a href="http://www.potentialgames.com/forums/viewtopic.php?f=5&#038;t=92">See this forum topic for details (and comments on future releases).</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/09/05/rpg-alpha-update-v041/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Concealed Controller Pattern</title>
		<link>http://www.potentialgames.com/blog/2008/08/27/concealed-controller-pattern/</link>
		<comments>http://www.potentialgames.com/blog/2008/08/27/concealed-controller-pattern/#comments</comments>
		<pubDate>Wed, 27 Aug 2008 11:48:27 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Developer's Cave]]></category>

		<category><![CDATA[design patterns]]></category>

		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=131</guid>
		<description><![CDATA[This article describes an interesting design pattern that I utilized in my Potential RPG code. The following describes the pattern in general and how I&#8217;ve used it in my code. Has anyone seen this pattern in the wild? Does it have any other common forms or names? 
Background: I have a class (let&#8217;s call it [...]]]></description>
			<content:encoded><![CDATA[<p>This article describes an interesting design pattern that I utilized in my Potential RPG code. The following describes the pattern in general and how I&#8217;ve used it in my code. Has anyone seen this pattern in the wild? Does it have any other common forms or names? <span id="more-131"></span></p>
<p><strong>Background:</strong> I have a class (let&#8217;s call it Subordinate) that has special control methods, which should <em>only</em> be called by a Master class. (Subordinate also has methods for public use.) Consequently, I originally implemented the Subordinate in the same (client-side) package as the Master, using package-protected control methods. Unfortunately, this binds the Subordinate, and everything that needs it, to client-packaged libraries.</p>
<p><strong>Simple Solution:</strong> The simple solution is to repackage the Subordinate into its own (non-client-specific) package. Unfortunately, the control methods must become public for the Master (still bound to client-specific logic) to access. The API would have to document, <em>&#8220;Please do not call the control methods, unless you&#8217;re supposed to.&#8221;</em></p>
<p><strong>The Goal:</strong> My goal is to provide a Subordinate that can only be controlled by the Master. One approach is to create a Subordinate interface, and keep its implementation hidden. However, there is no desire to allow any other implementation of the Subordinate (it is best kept final).</p>
<p><strong>Concealed Controller:</strong> The crux of this pattern is a Subordinate helper class, called Controller. Controller has access to the (once again) package-protected control methods of the Subordinate. The Controller exposes public access to the control methods. In addition, the only way to obtain a Subordinate is to construct a Controller (which constructs the Subordinate instance internally). </p>
<p><strong>Integration:</strong> To use a Subordinate, the Master constructs a Controller and exposes the contained Subordinate publicly (but conceals the Controller for itself). The only access to the Subordinate&#8217;s control methods is via the Controller, which is concealed by the Master.</p>
<p><strong>Pseudocode:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="java java" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">package</span> <span style="color: #006699;">library</span>;
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">final</span> <span style="color: #000000; font-weight: bold;">class</span> Subordinate
<span style="color: #009900;">&#123;</span>
    Subordinate<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #009900;">&#125;</span>
    <span style="color: #000066; font-weight: bold;">void</span> control<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> ... <span style="color: #009900;">&#125;</span>
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> action<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> ... <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">package</span> <span style="color: #006699;">library</span>;
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">final</span> <span style="color: #000000; font-weight: bold;">class</span> Controller
<span style="color: #009900;">&#123;</span>
    <span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000000; font-weight: bold;">final</span> Subordinate sub <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Subordinate<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>;
    <span style="color: #000000; font-weight: bold;">public</span> Controller<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #009900;">&#125;</span>
    <span style="color: #000000; font-weight: bold;">public</span> Subordinate get<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #000000; font-weight: bold;">return</span> sub; <span style="color: #009900;">&#125;</span>
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> control<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> sub.<span style="color: #006633;">control</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>; <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">package</span> <span style="color: #006699;">client</span>;
<span style="color: #000000; font-weight: bold;">final</span> <span style="color: #000000; font-weight: bold;">class</span> Master
<span style="color: #009900;">&#123;</span>
    <span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000000; font-weight: bold;">final</span> Controller control <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> Controller<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>;
    Master<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> activateWhenClientIsReady<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>; <span style="color: #009900;">&#125;</span>
    <span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000066; font-weight: bold;">void</span> activate<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> control.<span style="color: #006633;">control</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>; <span style="color: #009900;">&#125;</span>
    <span style="color: #000000; font-weight: bold;">public</span> Subordinate get<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #000000; font-weight: bold;">return</span> control.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>; <span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p><strong>Potential RPG:</strong> In my code, the <em>subordinate</em> is a PlayerCharacter class, with <code>activate()</code> and <code>deactivate()</code> <em>control</em> methods, only to be used by the client-side CharacterAgent (<em>master</em>). Many GUI classes integrate with PlayerCharacter, which provides access to the in-world character being controlled by the player. Following this pattern, the CharacterAgent constructs and conceals the Activator (<em>controller</em>), shielding access to the control methods (thus preventing the chaos that would certainly ensue).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/08/27/concealed-controller-pattern/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Potential RPG Alpha4 (v0.4)</title>
		<link>http://www.potentialgames.com/blog/2008/08/25/potential-rpg-alpha4-v04/</link>
		<comments>http://www.potentialgames.com/blog/2008/08/25/potential-rpg-alpha4-v04/#comments</comments>
		<pubDate>Tue, 26 Aug 2008 00:38:56 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Potential RPG]]></category>

		<category><![CDATA[RPG Alpha]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=128</guid>
		<description><![CDATA[All the tasking for Alpha4 is complete (&#8230; or brushed under the rug of a later release). Alpha Playtesters are invited to read the details, then try it out.
]]></description>
			<content:encoded><![CDATA[<p>All the tasking for Alpha4 is complete (&#8230; or brushed under the rug of a later release). Alpha Playtesters are invited to <a href="http://www.potentialgames.com/forums/viewtopic.php?f=5&#038;t=90&#038;p=376#p376">read the details</a>, then try it out.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/08/25/potential-rpg-alpha4-v04/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Incremental Alpha Update (v0.3.2)</title>
		<link>http://www.potentialgames.com/blog/2008/08/22/incremental-alpha-update-v032/</link>
		<comments>http://www.potentialgames.com/blog/2008/08/22/incremental-alpha-update-v032/#comments</comments>
		<pubDate>Fri, 22 Aug 2008 16:40:53 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Potential RPG]]></category>

		<category><![CDATA[RPG Alpha]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=124</guid>
		<description><![CDATA[For Alpha playtesters, I&#8217;ve posted an incremental release (on the roadmap to Alpha4) with some important enhancements to island building. See this playtesting forum topic for details.
]]></description>
			<content:encoded><![CDATA[<p>For Alpha playtesters, I&#8217;ve posted an incremental release (on the <a href="http://www.potentialgames.com/tasks/index.php?do=roadmap&#038;project=2">roadmap</a> to Alpha4) with some important enhancements to island building. <a href="http://www.potentialgames.com/forums/viewtopic.php?f=5&#038;t=90&#038;p=375#p375">See this playtesting forum topic for details.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/08/22/incremental-alpha-update-v032/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Player-Created Island Adventures</title>
		<link>http://www.potentialgames.com/blog/2008/08/18/player-created-island-adventures/</link>
		<comments>http://www.potentialgames.com/blog/2008/08/18/player-created-island-adventures/#comments</comments>
		<pubDate>Mon, 18 Aug 2008 14:23:36 +0000</pubDate>
		<dc:creator>neb</dc:creator>
		
		<category><![CDATA[Potential RPG]]></category>

		<category><![CDATA[RPG Alpha]]></category>

		<guid isPermaLink="false">http://www.potentialgames.com/blog/?p=115</guid>
		<description><![CDATA[I&#8217;ve been coding furiously since &#8230; well, since 2005. Over the past week, I&#8217;ve implemented the steepest spike in the project&#8217;s SLOC History.
Posted this morning, Alpha3 v0.3.1 is an incremental release on the roadmap to Alpha4, introducing Player-Created Islands. There are some known issues and limitations, but basic functionality is testable. (This is the secret [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been coding furiously since &#8230; well, since 2005. Over the past week, I&#8217;ve implemented the steepest spike in the project&#8217;s <a href="http://www.potentialgames.com/rpg/#sloc">SLOC History</a>.</p>
<p>Posted this morning, Alpha3 v0.3.1 is an incremental release on the <a href="http://www.potentialgames.com/tasks/index.php?do=roadmap&#038;project=2">roadmap</a> to Alpha4, introducing <strong><em>Player-Created Islands</em></strong>. There are some <a href="http://www.potentialgames.com/tasks/index.php?do=index&#038;tasks=&#038;project=2&#038;due=17">known issues</a> and limitations, but basic functionality is testable. (This is the <a href="http://www.potentialgames.com/blog/2008/08/08/rpg-alpha-playtesting/"><em>secret alpha bonus feature</em></a> mentioned earlier.)</p>
<p><strong>Disclaimer:</strong> I&#8217;m not promising how this feature will manifest itself in the final game design, but I&#8217;m very excited about the potential.</p>
<p><a href="http://www.potentialgames.com/forums/viewtopic.php?f=5&#038;t=90">Alpha playtesters should see this forum topic for details on testing the new feature.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.potentialgames.com/blog/2008/08/18/player-created-island-adventures/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
