<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Awesome Games Factory's Awesome Blog</title>
	
	<link>http://blog.agfgames.com</link>
	<description>We make solely awesome games</description>
	<lastBuildDate>Tue, 24 Apr 2012 17:59:33 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/agfgames" /><feedburner:info uri="agfgames" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Simple Object Orientation in Lua</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/yozS7WsXMpY/</link>
		<comments>http://blog.agfgames.com/2012/04/24/object-orientation-in-lua/#comments</comments>
		<pubDate>Tue, 24 Apr 2012 17:59:33 +0000</pubDate>
		<dc:creator>speeder</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Game Technology]]></category>
		<category><![CDATA[Tutorial]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=267</guid>
		<description><![CDATA[Lua is not object oriented&#8230; But some people like it, and it has some advantages&#8230; I decided to use a simple form of it on my project, it does not support multiple inheritance and many other features, it was made &#8230; <a class="more-link" href="http://blog.agfgames.com/2012/04/24/object-orientation-in-lua/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Lua is not object oriented&#8230; But some people like it, and it has some advantages&#8230;</p>
<p>I decided to use a simple form of it on my project, it does not support multiple inheritance and many other features, it was made to be very, very simple, only to organize the project and advance some form of code reuse.</p>
<p>So, what features I tried to support?</p>
<p>First, very ease of use to create a class<br />
Second, ease to create a instance.<br />
Third, automatic constructor if you do not want to make one.<br />
Fourth, easy &#8220;operator overloading&#8221; support.<br />
Fifth, static variables (I like them).</p>
<p>Some people will tell me now that there are lots of already done implementations of this, that you only need to search the web&#8230; So why make a new one? Well, almost all of the ones I found were too complex for my taste, and mostly for Lua 5.0. Lua 5.1 has a new particular feature, that I really wanted to use to make my class system, a powerful feature.</p>
<p>What we need to use from Lua? Mostly metatables, and the metamethods __index and __call, the second one being available only in Lua 5.1 and onward.</p>
<p>So, how we do it? First, we need to create a new chunk (I suggest you do it creating a file&#8230; I will make later a tutorial on how to make a non-file chunk).</p>
<p>My file is named kidclass.lua (the &#8220;kid&#8221; comes from Kidoteca, the company where I am working now to make children games).</p>
<p>This file will follow my usual style to make &#8220;modules&#8221;, without using the module() function (that got removed in Lua 5.2 and rightfully so&#8230; module() was just plain stupid).</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">local</span> kidclass = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1">&#8211;content will go here</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">return</span> kidclass;</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>Important, remember to make kidclass (or whatever name you want) local, so you do not end polluting the global namespace (ie: _G) and also avoid some accidental name conflicts&#8230;</p>
<p>How you use files made in that style?</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">mymodulename = <span class="kw1">require</span> <span class="st0">&quot;somemodule&quot;</span>; <span class="co1">&#8211;this is the line that matters, the next two is example of how to use mymodulename</span></div>
</li>
<li class="li1">
<div class="de1">mymodulename.someMethod<span class="br0">&#40;</span><span class="br0">&#41;</span>; </div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">local</span> myvar = &nbsp;mymodulename.somevar;</div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
</ol>
</div>
<p>Note that doing just require without assigning its return value to something, would be useless, because back when we created the module, we made it local.</p>
<p>Now, how we achieve the first objective, the ease of use to create a class?</p>
<p>The most easy way would just do: myclass = {};<br />
But that would prevent us from achieving the other features, so we need a function, to the sort that creating a class would be &#8220;myclass = kidclass.new();&#8221;<br />
So we know a kidclass.new, that would at most basic return a {} (this means a empty table), the following could would be the result:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">function</span> kidclass.new<span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw1">local</span> class = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw1">return</span> class;</div>
</li>
<li class="li2">
<div class="de2"><span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>And how we make the second object work now?</p>
<p>I thought that the nicest way to create a instance, would follow the style of C++ (more or less) so &#8220;instance = Object()&#8221; except Lua does not have a way to create a constructor that is named like a Object&#8230; Oh, actually it does have something like that, since 5.1! This is the reason why our code will be different from what you usually see on internet. We will use the might __call.</p>
<p>So, what __call do? __call is a metamethod (a method from a metatable) that is called when you attempt to call a table (ie: you do &#8220;table = {}; table()&#8221;).</p>
<p>__call is a metamethod, this means that we need to use metatable&#8230; I thus define the metatable that contains call on our &#8220;new&#8221; function we already created.</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">function</span> kidclass.new<span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">local</span> class = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">setmetatable</span><span class="br0">&#40;</span>class, kidclass<span class="br0">&#41;</span>; <span class="co1">&#8211;we define kidclass as metatable for class.</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> class;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>Since kidclass is what we defined as metatable for class, we need to create __call on kidclass:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">kidclass.__call = <span class="kw1">function</span> <span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw1">local</span> instance = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw1">return</span> instance;</div>
</li>
<li class="li2">
<div class="de2"><span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>Ok, so what we did for now? We made a way to create a class using a simple method.</p>
<p>Thus doing &#8220;myClass = kidclass.new()&#8221; will create a empty table that has kidclass as metatable.</p>
<p>And we created a way to create a instance.</p>
<p>Thus doing &#8220;myInstance = myClass()&#8221; will make Lua check if myClass has a metatable (it has&#8230; it is kidclass), and then it will check in the metatable (kidclass) if it has a __call. And then it will run the function contained in __call (this is why __call is defined as &#8220;= function()&#8221;)</p>
<p>But what if we want for example to create a Point class, that supports Point(x, y) as constructor? This mean now we need to create a support for constructor&#8230;</p>
<p>We change __call to this:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">kidclass.__call = <span class="kw1">function</span> <span class="br0">&#40;</span>class, &#8230;<span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">local</span> instance = <span class="br0">&#123;</span><span class="br0">&#125;</span>; <span class="co1">&#8211;Remember to make this local, or every time you call a constructor inside another constructor you will destroy the first object</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> class.Constructor <span class="kw1">then</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; class.Constructor<span class="br0">&#40;</span>instance, &#8230;<span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> instance;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">end</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
</ol>
</div>
<p>Alright, now a constructor can be created for our class, following the following format:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">function</span> ourClass.Constructor<span class="br0">&#40;</span>self, randomVars<span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; self.defaultVar = <span class="nu0">123</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; self.anotherVar = randomVars;</div>
</li>
<li class="li2">
<div class="de2"><span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>This actually already works as very simple OOP, so if you want, you can stop here&#8230; But I still want to support operator overloading!</p>
<p>Operator overloading is done in Lua using metamethods too, they are __add for +, __mul for * and so on (look on the Lua manual for all of them, there are also overloading for = and >= and more)</p>
<p>This means we need to add a metatable for the instances, that will look for __add function for example. Since we are making something OOP, the most logical place for __add is the class&#8230;</p>
<p>Thus when we do instanceOfBallC = instanceOfBallA + instanceOfBallB; Lua will look for __add in Ball.</p>
<p>We modify again our __call to that:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">kidclass.__call = <span class="kw1">function</span> <span class="br0">&#40;</span>class, &#8230;<span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">local</span> instance = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> class.Constructor <span class="kw1">then</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; class.Constructor<span class="br0">&#40;</span>instance, &#8230;<span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">setmetatable</span><span class="br0">&#40;</span>instance, class<span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> instance;</div>
</li>
<li class="li2">
<div class="de2"><span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>Static variables we already support, just add them to class (ie: myClass.staticVar = 23) but I think we can add one last cool feature&#8230; We can make our instances read from their class any variable that does not exist, thus creating default variables that are also static variables&#8230; We do that in lua by setting the __index of the table that is missing a variable&#8230; since __index is a metamethod too (we can set it to a table, as a shorthand version of sorts) we need to put it in the metatable.</p>
<p>Thus just before setmetatable(instance, class); line we add class.__index = class, meaning now that any time someone try to read something that does not exist from instance (that has class as metatable) it will read from what the metatable __index pointed (class itself too), thus in practice instances actually inherit from our class.</p>
<p>This is the final version of the code (PLEASE do not just copy paste it&#8230; it is here for studying, I am placing a commercial private code here in a goodwill gesture to educate you, not to you just leech it without understanding it).</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="co1">&#8211; Mauricio Gomes</span></div>
</li>
<li class="li1">
<div class="de1"><span class="co1">&#8211; Kidoteca object oriented system.</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&#8211;[[</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; How to use:</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; To create for example a Dog class, we do:</span></div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; local class = require &quot;kidclass&quot;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; local Dog = class.new(); --If you forget the local here, it will pollute your _G</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; local function realBark(...) --Private function</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; print(...)</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; function Dog.Constructor(self, initialbarks) --This is a optional constructor...</span></div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; self.barks = initialbarks or 0; --This is a variable initialization plus default variable</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; local spots = 76; --This is a private static variable.</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Dog.color = &quot;white&quot;; --This is a public static variable. </span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; function Dog:bark()</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; self.barks = self.barks + 1;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; realBark(&quot;We have &quot; .. self.color .. &quot; color and barked &quot; .. self.barks .. &quot; times&quot;);</span></div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; function Dog.blacken(amount) --static function (or rather, a function that alter static variables )</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; spots = spots + amount;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; print(spots);</span></div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if spots &gt; 100 then</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Dog.color = &quot;black&quot;;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; end</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; end</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return Dog;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; To create a instance of Dog</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; local Dog = require &quot;dog.lua&quot;;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Max = Dog(4);</span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li1">
<div class="de1"><span class="coMULTI">&nbsp; &nbsp; &nbsp; &nbsp; </span></div>
</li>
<li class="li2">
<div class="de2"><span class="coMULTI">--]]</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">local</span> kidclass = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">kidclass.__call = <span class="kw1">function</span> <span class="br0">&#40;</span>class, &#8230;<span class="br0">&#41;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">local</span> instance = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> class.Constructor <span class="kw1">then</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; class.Constructor<span class="br0">&#40;</span>instance, &#8230;<span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; </div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; class.__index = class;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">setmetatable</span><span class="br0">&#40;</span>instance, class<span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> instance;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">end</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2"><span class="kw1">function</span> kidclass.new<span class="br0">&#40;</span><span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">local</span> class = <span class="br0">&#123;</span><span class="br0">&#125;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">setmetatable</span><span class="br0">&#40;</span>class, kidclass<span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> class;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">end</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
<li class="li1">
<div class="de1"><span class="kw1">return</span> kidclass;</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=yozS7WsXMpY:hv2WUUFHra8:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=yozS7WsXMpY:hv2WUUFHra8:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=yozS7WsXMpY:hv2WUUFHra8:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=yozS7WsXMpY:hv2WUUFHra8:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/yozS7WsXMpY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2012/04/24/object-orientation-in-lua/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2012/04/24/object-orientation-in-lua/</feedburner:origLink></item>
		<item>
		<title>We are not dead!</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/NF-vKFUwjXk/</link>
		<comments>http://blog.agfgames.com/2012/04/23/we-are-not-dead/#comments</comments>
		<pubDate>Tue, 24 Apr 2012 02:48:19 +0000</pubDate>
		<dc:creator>speeder</dc:creator>
				<category><![CDATA[Community News]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=264</guid>
		<description><![CDATA[Well, we almost died, but in a miraculous manner, at the nick of time some work showed up&#8230; And even more surprising, using Lua, this means more time without paddlewars, but I will start to post here some Lua stuff &#8230; <a class="more-link" href="http://blog.agfgames.com/2012/04/23/we-are-not-dead/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Well, we almost died, but in a miraculous manner, at the nick of time some work showed up&#8230; And even more surprising, using Lua, this means more time without paddlewars, but I will start to post here some Lua stuff and maybe some other info.</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=NF-vKFUwjXk:Tyjz_Ha87Pk:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=NF-vKFUwjXk:Tyjz_Ha87Pk:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=NF-vKFUwjXk:Tyjz_Ha87Pk:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=NF-vKFUwjXk:Tyjz_Ha87Pk:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/NF-vKFUwjXk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2012/04/23/we-are-not-dead/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2012/04/23/we-are-not-dead/</feedburner:origLink></item>
		<item>
		<title>Long term contract ended</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/S-HascKcALE/</link>
		<comments>http://blog.agfgames.com/2011/11/25/long-term-contract-ended/#comments</comments>
		<pubDate>Fri, 25 Nov 2011 21:58:30 +0000</pubDate>
		<dc:creator>speeder</dc:creator>
				<category><![CDATA[Community News]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=262</guid>
		<description><![CDATA[Today the contract with my biggest client so far ended, I delivered 2 big projects, some libraries and made even a small simple iPhone game one day when bored (sorry, it will not be released, but I can remake it &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/11/25/long-term-contract-ended/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Today the contract with my biggest client so far ended, I delivered 2 big projects, some libraries and made even a small simple iPhone game one day when bored (sorry, it will not be released, but I can remake it later in flash or something to release for general public).</p>
<p>So, what now? First, I need another contract, I will still receive payments for more 2 months, so I have 2 months to find a new contract, thus I will work on that.</p>
<p>Second, now I have boatloats of free time (since I have no other contracts now), this mean: You can hire me, and also, that I will resume working on games, probably NOT Paddle Wars now, I intend to release some smaller complete games first&#8230; To stop leaving behind unfinished games.</p>
<p>And that is it!</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=S-HascKcALE:lWwhBpF2tX0:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=S-HascKcALE:lWwhBpF2tX0:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=S-HascKcALE:lWwhBpF2tX0:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=S-HascKcALE:lWwhBpF2tX0:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/S-HascKcALE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/11/25/long-term-contract-ended/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/11/25/long-term-contract-ended/</feedburner:origLink></item>
		<item>
		<title>Site development</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/5T6QuvIbzZY/</link>
		<comments>http://blog.agfgames.com/2011/05/12/site-development/#comments</comments>
		<pubDate>Thu, 12 May 2011 11:52:25 +0000</pubDate>
		<dc:creator>Law</dc:creator>
				<category><![CDATA[Community News]]></category>
		<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=249</guid>
		<description><![CDATA[Speeder may not have mentioned it here, so I guess I&#8217;ll be the one to tell you all&#8230; I&#8217;ve been working on the new site for Paddle Wars, and it was about the middle of April that it was finally &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/05/12/site-development/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Speeder may not have mentioned it here, so I guess I&#8217;ll be the one to tell you all&#8230;</p>
<p>I&#8217;ve been working on the new site for Paddle Wars, and it was about the middle of April that it was finally opened to the world, after much discussion and decision making with Speeder.</p>
<p>You can view it at <a href="http://paddlewars.agfgames.com">http://paddlewars.agfgames.com</a>.</p>
<p>Of course, I&#8217;m still busily working with Speeder in order to make this site better for everyone that happens to visit. So why not list the changes since that version and the one I&#8217;m currently working on?<br />
<span id="more-249"></span><br />
Changes made since 18th of April 2011 to 12th of May 2011:</p>
<ul>
<li>Added additional button at the front page to download both the Windows and OS X builds of Paddle Wars</li>
<li>Optimised images with crushpng and png indexing to reduce file size dramatically (I&#8217;m not sure about how much&#8230;)</li>
<li>Added additional mirror link for the Windows build of Paddle Wars</li>
<li>Indicated on download page which links are the primary downloads and which ones are mirror sites</li>
<li>Removed extensive change log to only show the latest version, moving it over to a separate page</li>
<li>Corrected positioning of images in the media page, set to relative when it used to be absolute</li>
<li>Changed text and link colours to make them more distinct</li>
<li>The background has been lightened in order to provide contrast between background and content</li>
<li>Fixed incorrect dimensions of one of the images</li>
</ul>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=5T6QuvIbzZY:jeU3AhTLrPE:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=5T6QuvIbzZY:jeU3AhTLrPE:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=5T6QuvIbzZY:jeU3AhTLrPE:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=5T6QuvIbzZY:jeU3AhTLrPE:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/5T6QuvIbzZY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/05/12/site-development/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/05/12/site-development/</feedburner:origLink></item>
		<item>
		<title>We got saved! Sort of…</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/W0b981f_tWU/</link>
		<comments>http://blog.agfgames.com/2011/04/08/we-got-saved-sort-of/#comments</comments>
		<pubDate>Fri, 08 Apr 2011 12:47:38 +0000</pubDate>
		<dc:creator>speeder</dc:creator>
				<category><![CDATA[Community News]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=241</guid>
		<description><![CDATA[Hello Awesome Games Factory fans and guests. I wrote some time ago, we were going bankrupt. The good thing is: AGF got not one, but TWO big clients (one is being handled by me, the other by the non-game person &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/04/08/we-got-saved-sort-of/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hello Awesome Games Factory fans and guests. I wrote some time ago, we <a href="http://blog.agfgames.com/2011/01/31/bankrupcy/">were going bankrupt</a>. The good thing is: AGF got not one, but TWO big clients (one is being handled by me, the other by the non-game person of the company, the one that helped me build the <a href="http://blog.agfgames.com/2011/01/24/campus-party-is-over/">Arcade Cabinet</a>). The bad thing is: Now noone is left to work on the games!</p>
<p>But we actually insist&#8230; Soon I will resume working on Paddle Wars, probably I will release beta 6, and then decide what to do next. Now we have SURPLUS money, this mean that I can hire a web designer to redo the crap site we have (anyone volunteer? Keep in mind that surplus money does not mean we are rich&#8230;)</p>
<p>Also I bought a Dingoo, so maybe I will make Dingoo games. And also I found something else, not related to games, but interesting, but that something else I will talk about it later.</p>
<p>Still want to help us in any way? Send your complaints, suggestions, ideas, questions for self-interview (I only stopped that series because noone send questions!) to agf@agfgames.com</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=W0b981f_tWU:Mwtk3zgABWU:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=W0b981f_tWU:Mwtk3zgABWU:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=W0b981f_tWU:Mwtk3zgABWU:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=W0b981f_tWU:Mwtk3zgABWU:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/W0b981f_tWU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/04/08/we-got-saved-sort-of/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/04/08/we-got-saved-sort-of/</feedburner:origLink></item>
		<item>
		<title>Why Sony is upset with PS3 hackers?</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/0Kt4Mn391NA/</link>
		<comments>http://blog.agfgames.com/2011/02/08/why-sony-is-upset-with-ps3-hackers/#comments</comments>
		<pubDate>Tue, 08 Feb 2011 20:10:39 +0000</pubDate>
		<dc:creator>speeder</dc:creator>
				<category><![CDATA[Business]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=234</guid>
		<description><![CDATA[Most people would just say: &#8220;Piracy!&#8221; But then I say the most people, are wrong. The hackers stated, that their work only enable homebrew, not piracy, and THAT is the dangerous thing to Sony. Lots of people will come with &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/02/08/why-sony-is-upset-with-ps3-hackers/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://blog.agfgames.com/wp-content/uploads/2011/02/random_number.png"><img class="alignright size-full wp-image-236" title="random_number" src="http://blog.agfgames.com/wp-content/uploads/2011/02/random_number.png" alt="" width="400" height="144" /></a><br />
Most people would just say: &#8220;Piracy!&#8221; But then I say the most people, are wrong. The hackers stated, that their work only enable homebrew, not piracy, and THAT is the dangerous thing to Sony.</p>
<p>Lots of people will come with pitchforks in hand, saying that I am defending pirates, those are missing the point completely, I am not talking about them. Others will come with scythes, trying to harvest from me that the problem is that now anyone can cheat on games (and pirate). Those, don&#8217;t realize too what it is at stake for Sony.</p>
<p>In 1983, the market crashed, Atari, the leader in console business, acted like an ass toward their own developers, leading them to quit, and create Activision. Atari sued Activision when they created a Atari game, and lost. Suddenly, hundreds of companies appeared from nothing, like the 2001 internet companies surge, there was in 1983 a game development surge, but the result was disastrous, a huge amount of shovelware, soon when you visited a video-game store, 99% of the games on the display would be utterly crap.</p>
<p>This, coupled with some mistakes from Atari and competitors, caused a market crash, the console game market just died. Nintendo came to rescue us all, enforcing a very strict policy where to make a game for them, you needed to follow very strict guidelines, and had a limit on how many games you could submit every year, meaning that only the best games would get on the system, of course, several crap games showed up, but the ratio was bearable to costumers, if you picked a random cartridge on the store, probably the game was decent enough.</p>
<p>A whole business model came from this, soon all console manufacturers started not only to build gates and guard them, but they also figured they could put toll booths on them, you want make a PS3 game? You have to license some stuff, pay some fees, buy SDKs and debug machines&#8230; Some manufactuers even ask for royalties, meaning that every game sold, give them a little money, but when summed all games sold ever, it means humongous amounts of money. All this, allow the payment of the research and development of those marvelous machines.</p>
<p>So, returning to the present, what happened to PS3? First, hackers started to figure how to use the RSX (PS3 video chip) on Linux, something that was not available, but developers pursued, in attempt to make cool stuff. Suddenly, Sony removed the &#8220;OtherOS&#8221; option. Many people misunderstood, thinking what Sony feared was piracy, but that would make no sense, OtherOS only allows to run another Operating System, a game is NOT a Operating System, to make a pirated game run using OtherOS would be harder than many of the other ways.</p>
<p>The hackers got upset with OtherOS removal, Sony took from them the toys that they bought, it is like if you sold a car, and then popped the tires after the costumer picked it up. Their solution? Put it back. Of course, this started a battle of hackers putting it back, and Sony removing it again. Soon they needed a final and ultimate solution, a way to put OtherOS back permanently.</p>
<p>This proved to be possible, thanks to Sony crap security, when you use cryptography you are supposed to use random numbers, but Sony random number generator is not quite random, allowing the hackers to use simple math and observation skills to figure the key. And then one of them, published that key on internet&#8230;</p>
<p>Like those videogame bosses, where they have a single weak point, and if you hit it, the creature starts to scream, flail, yell and smash random stuff and cause lots of collateral damage, that is what happened, the key, a number, that in many situations would be meaningless, is the key to Sony gate, the gate that have a toll booth, with that key, anyone can create any software they want, and ignore Sony demands for fees, suddenly a great source of income for Sony is in danger.</p>
<p>What Sony fears, is that people will figure that with the key, they can make their own PS3 games, and that what happened in 1983 will repeat on the PS3, as soon as a great homebrew game show up and actually gather sales, a new surge of PS3 development will happen, and soon there will be thousands of PS3 games, completely drowning the market in shovelware, and causing Sony to don&#8217;t see a dime of it.</p>
<p>THIS is why Sony is insanely upset.</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=0Kt4Mn391NA:4vCWZG87yf0:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=0Kt4Mn391NA:4vCWZG87yf0:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=0Kt4Mn391NA:4vCWZG87yf0:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=0Kt4Mn391NA:4vCWZG87yf0:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/0Kt4Mn391NA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/02/08/why-sony-is-upset-with-ps3-hackers/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/02/08/why-sony-is-upset-with-ps3-hackers/</feedburner:origLink></item>
		<item>
		<title>Bankrupcy</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/vIpRvPT2Ibg/</link>
		<comments>http://blog.agfgames.com/2011/01/31/bankrupcy/#comments</comments>
		<pubDate>Mon, 31 Jan 2011 19:18:25 +0000</pubDate>
		<dc:creator>speeder</dc:creator>
				<category><![CDATA[Community News]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=230</guid>
		<description><![CDATA[Hello all usual AGF Games readers, and those that read from Ludumdare Planet we are in trouble. We spent lots of money on the arcade cabinet, that had only partial success, it worked to test the game, and improve it, &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/01/31/bankrupcy/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hello all usual AGF Games readers, and those that read from <a href="http://ludumdare.com/planet/">Ludumdare Planet</a> we are in trouble.</p>
<p>We spent lots of money on the arcade cabinet, that had only partial success, it worked to test the game, and improve it, but it totally failed to attract more attention.</p>
<p>We are now going bankrupt, without a product done, without any other source of income, and no donations, soon we will run out of money.</p>
<p>What will be done is: The game development will stop, and me (Mauricio/Speeder) will see if I can find a normal job (like, selling games in a GameStop).</p>
<p>But that can be prevented: We are accepting <a href="http://www.8bitfunding.com/project_details.php?p_id=69">donations on 8-bit funding</a> and we are looking for contracts (or a normal development job to Maurício).</p>
<p>So, if you need work done, any work that AGF Games can do, please, contact us at agf@agfgames.com and we will see what can be done. You want your own Paddle Wars: Hit The Wall? Well, you can, just hire us.</p>
<p>So, hire us, or donate, and save Paddle Wars.</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=vIpRvPT2Ibg:ThnexS3Lwqk:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=vIpRvPT2Ibg:ThnexS3Lwqk:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=vIpRvPT2Ibg:ThnexS3Lwqk:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=vIpRvPT2Ibg:ThnexS3Lwqk:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/vIpRvPT2Ibg" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/01/31/bankrupcy/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/01/31/bankrupcy/</feedburner:origLink></item>
		<item>
		<title>Forced in…</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/stnscF68qRw/</link>
		<comments>http://blog.agfgames.com/2011/01/27/forced-in/#comments</comments>
		<pubDate>Fri, 28 Jan 2011 02:09:04 +0000</pubDate>
		<dc:creator>Law</dc:creator>
				<category><![CDATA[Self Interview]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=225</guid>
		<description><![CDATA[Well, Speeder nagged me to write this, so I guess there isn&#8217;t a choice. But he didn&#8217;t exactly say what I was supposed to be writing about, so&#8230; Hello people, I&#8217;m Mingamango181, otherwise known as LawAndContradiction. I&#8217;m not known for &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/01/27/forced-in/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Well, Speeder nagged me to write this, so I guess there isn&#8217;t a choice. But he didn&#8217;t exactly say what I was supposed to be writing about, so&#8230;</p>
<p>Hello people, I&#8217;m Mingamango181, otherwise known as LawAndContradiction. I&#8217;m not known for much, but I do like to design and render things. I also do web coding, which is pretty much the only language that I&#8217;m proficient at.</p>
<p>I wasn&#8217;t one for making things entirely from scratch. Rather, I preferred to see if I could make objects or things that were suited for a very specific audience. In 2002 however, I had a strong inclination to learn how web pages were built. Reading through, I learnt how things were made up, and the way that tags worked to make the font like this, or that, and etc. I can&#8217;t remember what my first page looked like, but it probably had the resemblance of those geocities sites, except with much less.</p>
<p>I only started to make use of HTML properly in 2009, reading through the standards and learning about CSS. I was utilising it in one of my assignments on web development. It went rather well, and I am continuing to learn about it.</p>
<p>2010 was one of those years with the most change. I returned to AnyNowhere in February, my previous time just lurking and being trimmed after a while of inactivity. The year would have been pretty bland, if it weren&#8217;t for a certain situation which I couldn&#8217;t handle very well.</p>
<p>It was quite damaging, since nothing of the sort had ever occurred before. I withdrew to the corner, a dark corner. Thank goodness there was someone willing to help during a two week break. I was able to recover from it in time for the next wave of attacks.</p>
<p>I had heard about <em>Paddle Wars: Hit The Wall</em> in a post over at AnyNowhere, quite a while before the incident. I was interested, though then, I found it difficult to find the right words to use in my feedback. The closed Beta gave me a chance, to do more, and I took that opportunity.</p>
<p>Well, this post probably has more meaning than my introduction post at the forums. My own corner of the internet is located <a href="http://contradiction.selb.us">here</a>. I am also using the one hundred and forty character service, which would be named &#8216;@contradicthelaw&#8217;.</p>
<p>I suppose what Speeder wanted me to promote was this: You can donate to the cause at 8-bit funding <a href="http://8bitfunding.com/project_details.php?p_id=69">here</a>. I&#8217;m not sure about why not promoting this <a href="http://indiegogo.com/Paddle-Wars-Hit-The-Wall-for-MacOS-X">older link</a> though&#8230;</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=stnscF68qRw:DkJjtVI7xYc:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=stnscF68qRw:DkJjtVI7xYc:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=stnscF68qRw:DkJjtVI7xYc:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=stnscF68qRw:DkJjtVI7xYc:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/stnscF68qRw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/01/27/forced-in/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/01/27/forced-in/</feedburner:origLink></item>
		<item>
		<title>Campus Party is Over</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/eIhKSODiX2w/</link>
		<comments>http://blog.agfgames.com/2011/01/24/campus-party-is-over/#comments</comments>
		<pubDate>Mon, 24 Jan 2011 16:15:47 +0000</pubDate>
		<dc:creator>speeder</dc:creator>
				<category><![CDATA[Arcade Cabinet]]></category>
		<category><![CDATA[Community News]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=217</guid>
		<description><![CDATA[Hello, I am back! First, I like to say thanks to Mingamango who updated the blog while I was away. Campus Party is over, it was great, and this post is a report to you people know what happened there. &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/01/24/campus-party-is-over/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hello, I am back!</p>
<p>First, I like to say thanks to Mingamango who updated the blog while I was away.</p>
<p><a href="http://blog.agfgames.com/wp-content/uploads/2011/01/19janfliperama.jpg"><img class="alignright size-full wp-image-218" title="19janfliperama" src="http://blog.agfgames.com/wp-content/uploads/2011/01/19janfliperama.jpg" alt="" width="550" height="362" /></a>Campus Party is over, it was great, and this post is a report to you people know what happened there. First thing, the cabinet attracted a lot of attention, this is a photo of before the event even started, where only workers (of all sorts, including media) were present, when the photo was taken (the guy in red is a journalist, the guy with a Paddle Wars t-shirt is me).</p>
<p>Having the game run for several hours non-stop made several bugs pop-up, and for the first time I could watch complete strangers play the game, and note their behavior, see what was wrong, and what was right, what worked, and what did not&#8230;</p>
<p>During the event I did 4 revisions of Beta 5 (which is the version in the cabinet, it is not available to the public, later I will release Beta 6 to everyone).</p>
<p><span style="text-decoration: underline;">So, the changes from Beta 4 to Beta 5:</span></p>
<ul>
<li>Added music to highscore (props to <a href="http://www.braincontrol.org/music.php">Skyrunner</a>)</li>
<li>Fixed some bugs regarding buttons</li>
<li>Added tooltip box on the level set selection screen</li>
<li>Improved the background</li>
<li>Removed the ugly gradient on the HP bar.</li>
<li>Fixed the score font</li>
<li>Fixed the multiplier GUI</li>
<li>Made powercubes more translucent (to make the ball more distinguishable during hectic scenes)</li>
<li>Added a very basic &#8220;attract&#8221; mode (i.e: what happen when you don&#8217;t press a button on the title screen)</li>
<li>added a voice-over on the title-screen</li>
<li>Made an &#8216;arcade&#8217; switch (can be used at home, but I won&#8217;t explain it now)</li>
</ul>
<p>On the first revision I fixed some strings.</p>
<p><span style="text-decoration: underline;">Changes from Beta 5 Rev 1 to Rev 2:</span></p>
<ul>
<li> Fixed the level score counter not starting from 0.</li>
<li> Fixed some rare bugs of variables getting lost.</li>
<li> Fixed that you could &#8220;lose&#8221; after winning.</li>
<li> Made the grid color a bit more faint (so it don&#8217;t get in the way).</li>
<li> Raised the voice volume.</li>
<li> Several improvements on the high-score name screen.</li>
<li> Changed the points bonus when passing the last level.</li>
<li> Fixed the high-score screen showing up when there was no score to save.</li>
<li> Added information version to the title screen</li>
<li> Fixed some bugs (not all unfortunately) on the level 6 when you lose.</li>
<li> Changed the high-score screen to use mono spaced font for numbers (so you don&#8217;t confuse the amount of digits)</li>
</ul>
<p><span style="text-decoration: underline;">Changes in Rev 3: </span></p>
<ul>
<li> Level 3 got reworked, it is now way easier (but still fun), and has new graphics.</li>
<li> Changed some collision boxes on level 6, to make it easier too.</li>
<li> Fixed more bugs related to variables disappearing.</li>
</ul>
<p><span style="text-decoration: underline;">Changes in Rev 4:</span><br />
Fixed the last level collision box, so you don&#8217;t have objects &#8220;passing through&#8221; and going out of the screen forever.</p>
<p>I will take a while before releasing the next version, because I intend to skip Beta 5 entirely, and release Beta 6.</p>
<p>During Campus Party several people showed up, bugs showed up, and I had lots of fun working on the arcade, fixing it, and watching people smiling while playing, one particular guy was really interesting to the point that I borrowed someone else camera to take a photo of him.</p>
<p><a href="http://blog.agfgames.com/wp-content/uploads/2011/01/20janfliperama.jpg"><img class="aligncenter size-large wp-image-220" title="20janfliperama" src="http://blog.agfgames.com/wp-content/uploads/2011/01/20janfliperama-1024x768.jpg" alt="" width="640" height="480" /></a></p>
<p>The person in the photo is a 3 year old boy, he <em>LOVED</em> the game, and when he was playing no-one else would play&#8230; Also he was shorter than the controls, and used a chair, yet with all difficulties he would play over, and over, and over, and over&#8230; And he would only leave to grab popcorn (when he did that, other people would play <img src='http://blog.agfgames.com/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> )</p>
<p>Also I made a competition, anyone that hit first place in the scores (but at least 1 million points) would get a t-shirt. Two guys did it, and won t-shirts <img src='http://blog.agfgames.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' />  (btw: if anyone here make a youtube video of you playing the entire game and hitting more than 2.5 million points, I will send a t-shirt for you too! Keep in mind that after someone manage to do it, I will raise the score needed).</p>
<p>Also, as Mango wrote on his post, I made a twitcam, and we chatted a lot over twitter ^^ Later you people can suggest more twitcam subjects.</p>
<p>Also I got some offers of places to distribute the game. YAY!</p>
<p>So, that is it, follow the twitters (@agfgames and @criadordejogos) and play a bit more.</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=eIhKSODiX2w:i44SnVHblfo:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=eIhKSODiX2w:i44SnVHblfo:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=eIhKSODiX2w:i44SnVHblfo:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=eIhKSODiX2w:i44SnVHblfo:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/eIhKSODiX2w" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/01/24/campus-party-is-over/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/01/24/campus-party-is-over/</feedburner:origLink></item>
		<item>
		<title>Campus Party</title>
		<link>http://feedproxy.google.com/~r/agfgames/~3/Sv5d5IGvDsM/</link>
		<comments>http://blog.agfgames.com/2011/01/21/campus-party/#comments</comments>
		<pubDate>Fri, 21 Jan 2011 22:07:34 +0000</pubDate>
		<dc:creator>Law</dc:creator>
				<category><![CDATA[Arcade Cabinet]]></category>
		<category><![CDATA[Community News]]></category>

		<guid isPermaLink="false">http://blog.agfgames.com/?p=207</guid>
		<description><![CDATA[Speeder is currently away at the 2011 Campus Party. I don&#8217;t know too much about the event itself, but what is known right now is that Paddle Wars: Hit The Wall has its own arcade cabinet, and that it has &#8230; <a class="more-link" href="http://blog.agfgames.com/2011/01/21/campus-party/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Speeder is currently away at the 2011 Campus Party. I don&#8217;t know too much about the event itself, but what is known right now is that <em>Paddle Wars: Hit The Wall</em> has its own arcade cabinet, and that it has gone through several revisions at this event alone. That version will be released once the event has concluded.</p>
<p>Current downloadable version: Beta 4<br />
What&#8217;s in the arcade cabinet: Beta 5 revision 4</p>
<p>I&#8217;m not sure how long this link will last, but the live video of people playing the game (or just passing by) can be found <del><a href="http://twitcam.livestream.com/3kxtu">here</a></del>.</p>
<p><i>Edit: due to an unexpected stream failure, you can access the fixed stream <a href="http://twitcam.livestream.com/3kz05">here</a>.</i></p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/agfgames?a=Sv5d5IGvDsM:G8EU3z-J6io:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/agfgames?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=Sv5d5IGvDsM:G8EU3z-J6io:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/agfgames?i=Sv5d5IGvDsM:G8EU3z-J6io:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/agfgames?a=Sv5d5IGvDsM:G8EU3z-J6io:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/agfgames?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/agfgames/~4/Sv5d5IGvDsM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.agfgames.com/2011/01/21/campus-party/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.agfgames.com/2011/01/21/campus-party/</feedburner:origLink></item>
	</channel>
</rss>

