<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Planet Ludum</title>
	<atom:link href="http://www.ludumdare.com/planet/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ludumdare.com/planet</link>
	<description>The Ludum Dare Community outside Ludum Dare</description>
	<lastBuildDate>Fri, 10 Feb 2012 02:38:02 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Testing flash embedding</title>
		<link>http://jemgine.omnisu.com/?p=614</link>
		<comments>http://jemgine.omnisu.com/?p=614#comments</comments>
		<pubDate>Fri, 10 Feb 2012 02:38:02 +0000</pubDate>
		<dc:creator>Bleck</dc:creator>
				<category><![CDATA[Daily Update]]></category>

		<guid isPermaLink="false">http://jemgine.omnisu.com/?p=614</guid>
		<description><![CDATA[Just testing some flash embedding. Ignore the generic platformer. Or.. don't.

	
		var flashvars = {
		};
		var params = {
			menu: "false",
			scale: "noScale",
			allowFullscreen: "true",
			allowScriptAccess: "always",
			bgcolor: "",
			wmode: "dir... <a href="http://jemgine.omnisu.com/?p=614">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Just testing some flash embedding. Ignore the generic platformer. Or.. don't.</p>
<p><script src="http://jemgine.omnisu.com/js/swfobject.js" type="text/javascript"></script><br />
	<script type="text/javascript">
		var flashvars = {
		};
		var params = {
			menu: "false",
			scale: "noScale",
			allowFullscreen: "true",
			allowScriptAccess: "always",
			bgcolor: "",
			wmode: "direct"
		};
		var attributes = {
			id:"Platformer"
		};
		swfobject.embedSWF("http://jemgine.omnisu.com/platformer.swf", "altContent", "320", "240", "10.0.0", "http://jemgine.omnisu.com/expressInstall.swf", flashvars, params, attributes);
	</script></p>
<div id="altContent">
<h1>Platformer</h1>
<p>Alternative content</p>
<p><a href="http://www.adobe.com/go/getflashplayer"><img<br />
			src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif"<br />
			alt="Get Adobe Flash player" /></a></p>
</p></div>
]]></content:encoded>
			<wfw:commentRss>http://jemgine.omnisu.com/?feed=rss2&#038;p=614</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Back To Camp!</title>
		<link>http://hamumu.com/journal.php?entry=1328757528</link>
		<comments>http://hamumu.com/journal.php?entry=1328757528#comments</comments>
		<pubDate>Thu, 09 Feb 2012 11:18:48 +0000</pubDate>
		<dc:creator>jamul@hamumu.com (Mike Hommel)</dc:creator>
		
		<guid isPermaLink="false">http://hamumu.com/journal.php?entry=1328757528</guid>
		<description><![CDATA[
Look at all that action!  There is now a goal (but no way to win or lose).  As you can see, the monsters are stealing the food from the camp and carrying it off.  If they get back to their dimensional portal (the black smudge on the lower left - it lo... <a href="http://hamumu.com/journal.php?entry=1328757528">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<DIV ALIGN=CENTER><IMG SRC="http://hamumu.com/images/dev/campscreen2.png"></DIV><BR>
Look at all that action!  There is now a goal (but no way to win or lose).  As you can see, the monsters are stealing the food from the camp and carrying it off.  If they get back to their dimensional portal (the black smudge on the lower left - it looks a lot more interesting in motion), they zoom away with your food and you are sad.  Lose all 5 food items and you lose the battle.<BR><BR>
Now you can also see an arrow pointing at the selected Beefy.  That's because it means something to select one - You can select one just to check out its health like any tower defense, but the selected enemy also becomes the focus of any tower that's in range to hit it, rather than them automatically aiming at the one closest to the campfire as is normal.  Just to spice it up and make it an important bit of gameplay, I might add an actual damage bonus against the selected enemy (and replace the arrow with a skull to make it <I>serious business</I>).  To be fair, I'm about 80% sure I've seen this feature in a game I've played, so it's not original.  But if I'm wrong, then it is super original!  Wow!<BR><BR>
Anyway, I can't say I was super productive today, but the good news is that Amazinrandi, my dwarf priest (so named because he looks like James Randi), turned 85 today!  Now I have 4 85s, and one more guy within half a level of it.  So yeah, a worthwhile day.  Good thing I also coded something, or I wouldn't have had anything to blog at you!]]></content:encoded>
			<wfw:commentRss>http://www.ludumdare.com/planet/2012/02/09/back-to-camp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Future Is Disorienting</title>
		<link>http://gbgames.com/blog/2012/02/the-future-is-disorienting/</link>
		<comments>http://gbgames.com/blog/2012/02/the-future-is-disorienting/#comments</comments>
		<pubDate>Wed, 08 Feb 2012 10:30:09 +0000</pubDate>
		<dc:creator>GBGames</dc:creator>
				<category><![CDATA[Geek / Technical]]></category>

		<guid isPermaLink="false">http://gbgames.com/blog/?p=1854</guid>
		<description><![CDATA[<p>I just jumped years into the future with both my cell phone and my computer. The future is a mixed bag. </p> <p> The Cell Phone </p> <p>For quite a few years now, I&#8217;ve had a flip-phone and was paying for service out of contract. When people started getting smartphones, I kind of wanted one, <span> . . . &#8594; Read More: <a href="http://gbgames.com/blog/2012/02/the-future-is-disorienting/">The Future Is Disorienting</a></span><p><a href="http://gbgames.com/blog/2012/02/the-future-is-disorienting/">The Future Is Disorienting</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p> <a href="http://gbgames.com/blog/2012/02/the-future-is-disorienting/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I just jumped years into the future with both my cell phone and my computer. The future is a mixed bag. </p>
<p><b> The Cell Phone </b></p>
<p>For quite a few years now, I&#8217;ve had a flip-phone and was paying for service out of contract. When people started getting smartphones, I kind of wanted one, but never enough to justify the cost of a phone or tying myself to a new 2-year contract to get a free one. </p>
<p><a href="http://twitpic.com/8avpz8" title="Share photos on twitter with Twitpic"><img src="http://twitpic.com/show/thumb/8avpz8.jpg" width="150" height="150" alt="Share photos on twitter with Twitpic"/></a></p>
<p>I did the math recently. I found out that for what I pay just for voice, data, and texting would be equivalent to getting a new smartphone with a contract. I&#8217;d even be able to take advantage of the data plan since the one with my flip-phone which became nearly unusable when they stopped supporting some of the already-poorly supported video options. I went with my fiancee&#8217;s Sprint-based provider instead of AT&#038;T, and that referral netted me a discount that made it even cheaper.</p>
<p><a href="http://twitpic.com/8auqqp" title="It&#039;s here! And freezing! on Twitpic"><img src="http://twitpic.com/show/thumb/8auqqp.jpg" width="150" height="150" alt="It&#039;s here! And freezing! on Twitpic"/></a></p>
<p>So now I have an Android, the HTC EVO Shift, and I&#8217;m fairly happy with it. It&#8217;s way more useful than my old phone. </p>
<p>Plus, now I can play the games everyone has been talking about.</p>
<p>Plus plus, I have a device to test my own projects when I start mobile development. </p>
<p>However, I&#8217;m still getting used to figuring out how to hold it since I seem to keep accidentally hitting the search button or some part of the screen. I still hit the volume control on the side too often, and I press the power button as I slide the device into my pocket if I&#8217;m not careful. And as great as having a keyboard is, the phone automatically unlocks when I slide it out, which has accidentally happened in my coat pocket more than once already. While my old phone let me easily look up a name in my phone book since I could type a letter and it would jump to that section of my phone book, this new device seems to think I want to include everyone I&#8217;ve ever emailed, Tweeted, circled on G+, or friended on Facebook when I want to search for someone to call.  </p>
<p>But this is the future, and the benefits are outweighing the negatives. Being able to fit a computer more powerful and integrated than my first desktop into my pocket has so far been pretty amazing.</p>
<p><b> The Computer </b></p>
<p>And speaking of computers, I&#8217;ve mentioned my <a href="http://gbgames.com/blog/2012/01/indie-maintenance-and-disaster-plans/">dying laptop</a> a few weeks ago. My Dell Precision M90 was a fine machine until the video card started failing. I&#8217;ve purchased a replacement: the Precision M6600.</p>
<p><a href="http://twitpic.com/8fars5" title="Share photos on twitter with Twitpic"><img src="http://twitpic.com/show/thumb/8fars5.jpg" width="150" height="150" alt="Share photos on twitter with Twitpic"/></a></p>
<p>I&#8217;m going from:</p>
<ul>
<li> 32-bit 2GHz CoreDuo -> 64-bit 2.2GHz i7 Quad Core </li>
<li> 2GB RAM -> 8GB RAM </li>
<li> NVIDIA Quadro FX 2500M (512MB) -> Quadro 3000M (2GB) </li>
<li> 100GB HD -> 750GB HD </li>
<li> 17&#8243; WUXGA display -> 17.3&#8243; 1920&#215;1080 display </li>
</ul>
<p>That last item unfortunately feels like a downgrade to me. I really liked having a 1920&#215;1200 display. The extra lines of resolution were great for coding work. Unfortunately, it seems that <a href="http://forums.dpreview.com/forums/read.asp?forum=1018&#038;message=38302139&%23038;changemode=1">1920&#215;1200 will no longer be available for most laptops</a>. There&#8217;s no real explanation, either. There&#8217;s merely speculation that the hardware manufacturers will save money, especially since most people probably just want to watch movies on their laptops anyway. </p>
<p>Still, this new laptop came with Windows 7, and while I&#8217;ve used Windows Vista by being the default tech support guy for my family, I hadn&#8217;t really become familiar with anything since Windows XP, which is what my old laptop came with. The new interface is somewhat jarring. When I was running Firefox and had the download window open as well as the main browser, I wanted to minimize it, and so I clicked on the button in the taskbar, like I normally would. Instead of minimizing Firefox, it popped up a the windows as buttons so I could choose which one I wanted. Darn new-fangled tech doing things differently than I expected&#8230;</p>
<p>But no matter! I repartitioned the drive so that Windows gets about 100GB, and I installed Ubuntu 11.10 on the remaining space. And it turns out that Ubuntu is all new and shiny, too. </p>
<p>See, I used Ubuntu 10.04 Long-Term Support (LTS), and I didn&#8217;t want to upgrade to newer versions because I wanted a stable development system to do my work on. </p>
<p>So here I am, jumping two years&#8217; worth of Ubuntu development, and this new Unity interface threw me for a bit until I realized they were trying to make it seem more Mac-like. There&#8217;s a launcher, and the buttons are all big and shiny, and there&#8217;s a Software Center where I can easily click and download apps and even purchase them. There&#8217;s quite a few indie games there, and it seems like it could be a decent marketplace. </p>
<p>But after looking at the entire games collection, I took the time to find the Terminal (more on that later) and typed: &#8220;apt-get install nethack-console&#8221; as fast as I could.</p>
<p>And then I added the Terminal to the launcher. </p>
<p>Seriously, it&#8217;s nice that the UI is 3D-powered and all, but sometimes I don&#8217;t want to mess around with a frickin&#8217; mouse. I LIKED being able to open the system menu at a keypress and see ALL of my installed applications. Now I have to explicitly type to search or click on Dash, then click on &#8220;More Apps&#8221;, and then click some more? On the old system, I could hit Alt+F1 to open the &#8220;Applications&#8221; menu, then use the arrow keys to move to &#8220;Accessories&#8221; > Terminal. Now, I press the Windows key to bring up Dash, and if I know the name of the application, I can type it out right there, but if I don&#8217;t, it&#8217;s faster to click on &#8220;More Apps&#8221;, then go to &#8220;Installed&#8221; and click on &#8220;see all&#8221;, then scroll down until I find it. </p>
<p>I also liked being able to figure out how to open a file within an application by just looking at the screen. Unity has Mac-like context menus that applications share at the top of the screen, which&#8230;ok, whatever. Maybe it&#8217;s great, and I&#8217;ll try it, but why Unity hides the menu until you mouse over it, I don&#8217;t know, but I&#8217;m not the only one <a href="http://www.zdnet.com/blog/perlow/why-ubuntu-1110-fills-me-with-rage/19103">who is unhappy with it</a>. Maybe I just need to get used to it, but there were a couple of times when I opened an application and wondered why the heck I had no way to open a file since the window I was using (seriously, why would I want to shift my eyes all the way to the top of the screen when the application I&#8217;m using is over here?) didn&#8217;t have a File option. </p>
<p>Unity also seems to hate the idea of customization. At least Windows let me move the taskbar around the screen. Why does the launcher have to stay stuck to the left side? Why do my windows have to have the close and minimize buttons to the left like on a Mac when I prefer them on the right? I&#8217;ve yet to find a way to change anything to work the way I want it to work. </p>
<p>I&#8217;m aware that it is possible to replace Unity with Ubuntu Classic UI or KDE, but I&#8217;m going to try to stick things out just to see how most users are expected to run their new Ubuntu-based systems. I actually do like being able to see all running application instances in an Exposé-like way, and there are parts of the UI that feel more intuitive. And Ubuntu 11.10 does seamlessly run 32-bit and 64-bit applications. I ran <a href="http://stopthathero.com/">Stop That Hero!</a> just to see if I had all of my development libraries installed, and I didn&#8217;t even realize that it shouldn&#8217;t have worked on this new 64-bit machine. So that was a pleasant surprise. </p>
<p>But if this is the future of computers, where laptop screens get smaller resolutions instead of larger ones, where the UI is made out of candy and shiny at the expense of being useful for people who know what they are doing, I&#8217;m not sure I&#8217;m happy about it. </p>
<p>I feel like the future is pushing me out of the way to make room for people who just want to watch widescreen movies or use a &#8220;workstation&#8221; as nothing more than a consumer electronics device. </p>
<p>Am I being unreasonable? Am I just disoriented because everything is different in the future? Is it better and I just need to get used to it? </p>
<p><a href="http://gbgames.com/blog/2012/02/the-future-is-disorienting/">The Future Is Disorienting</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p>
]]></content:encoded>
			<wfw:commentRss>http://gbgames.com/blog/2012/02/the-future-is-disorienting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Make Games</title>
		<link>http://hamumu.com/journal.php?entry=1328659150</link>
		<comments>http://hamumu.com/journal.php?entry=1328659150#comments</comments>
		<pubDate>Wed, 08 Feb 2012 07:59:10 +0000</pubDate>
		<dc:creator>jamul@hamumu.com (Mike Hommel)</dc:creator>
		
		<guid isPermaLink="false">http://hamumu.com/journal.php?entry=1328659150</guid>
		<description><![CDATA[Uh oh, over 5 journal comments!  Yes, it is a tower defense game (not reverse!).  I love tower defense!

I got this email yesterday, and I thought I would answer it here, since it's kind of a FAQ of sorts, but a little more broad than that.  The gist o... <a href="http://hamumu.com/journal.php?entry=1328659150">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[Uh oh, over 5 journal comments!  Yes, it is a tower defense game (not reverse!).  I love tower defense!<BR><BR>

I got this email yesterday, and I thought I would answer it here, since it's kind of a FAQ of sorts, but a little more broad than that.  The gist of it was "I want to be a game designer, so can you tell me how to do that, or talk about how you got where you are?"<BR><BR>
The first issue is what it means to be a "game designer".  That's a very specific job in the game industry, and you, yes you, aren't going to get to hold that job unless you work for yourself.  There are actually a lot of different jobs that are called "game designer", but most of them are very menial and, while they're creative, you are creative over only some small part of the game, and it's not what people think of when they say "I'm designing a game".  For example, you might be writing scripts that control how a switch opens a door. It's like programming, but simpler.  Or you might be designing levels, similar to what you do in the Dr. Lunatic editor, except that the basic idea and layout of the level is dictated by a senior designer ("This is the snow level, where you snipe at guys and then have to stealth down to the castle and climb up the side of it").<BR><BR>
What people really want to be is a senior designer (that is not necessarily the title at every company, but it gets the point across).  That's a job that requires lots of experience and proven results to show you're capable of it.  That's the job where you get to come up with the game and dictate how it all comes out while peons crank it out for you.  ...<I>Except</I> it's not.  There is still a whole layer above you that is really in charge.  The company president and/or owner meet with marketing guys and decide what kind of game they want, and they turn to you to make their vague concept into a fleshed out design, which you then turn to programmers and artists to make into an actual game.  Just another cog in the machine, albeit one with a lot of latitude, hopefully.  The boss I worked under at a game company didn't exactly spare the freedom... he liked to be in charge, which meant dictating a lot of details, and I don't think that's rare.  After all, he's the <I>boss</I>, it makes sense that he wants to be in charge!<BR><BR>
So, what you <I>really</I> want (I'm projecting here, but I think it's statistically likely) is to be the <I>company owner</I>.  And how do you get to be one of those?  You either A> work for yourself, or B> be a famous pitcher with millions of dollars and pay for an army of employees out of your pocket (Ooh, I played the <I>Kingdoms of Amalur: Reckoning</I> demo, and it was cool!).  Since you probably are interested in this stuff because it's what you want to spend your time doing, you shouldn't go the baseball route, and you should work for yourself.<BR><BR>
And that's the bottom line.  If you want creative freedom, if you want to make the games that you have ideas for, there's only one realistic path: do it yourself.  <I>But</I> the good news is that this path is easy!  Anybody can do it, you just have to want to do it and put in the effort.  The tools are all freely available, and you've got the spare time, so start making games!  That's what I did, that's what every other indie you've ever heard of did, and that's what you should do.  <B>Just make games.</B><BR><BR>
Now if you want to know how to just make games, that's a much longer discussion that I'm not qualified for.  But I can recommend <A HREF="http://flashgamedojo.com/">Flash Game Dojo</A> as a way to get started in flash games, which is a nice quick-feedback way to go.  You will definitely start out very confused, no matter what tools you start with, but you have to keep hacking at it, making stupid little tiny things, and gradually you'll pick up the good stuff.  Back when I started this, it was at least 150,000 times harder than it is today.  The tools you have today are unbelievably simplified and accessible, not to mention free and surrounded by a community of users who will help you.  Do some googling, you'll be buried in more options to pursue than you have time in your life to try.  Back in my day, we had to use <I>paper books</I> to learn things.  You'll pick this up no problem if it's really so fascinating to you that you want to spend your spare time fiddling with it.]]></content:encoded>
			<wfw:commentRss>http://www.ludumdare.com/planet/2012/02/08/how-to-make-games/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Guessing Game!</title>
		<link>http://hamumu.com/journal.php?entry=1328577626</link>
		<comments>http://hamumu.com/journal.php?entry=1328577626#comments</comments>
		<pubDate>Tue, 07 Feb 2012 09:20:26 +0000</pubDate>
		<dc:creator>jamul@hamumu.com (Mike Hommel)</dc:creator>
		
		<guid isPermaLink="false">http://hamumu.com/journal.php?entry=1328577626</guid>
		<description><![CDATA[
A screenshot of what I'm currently working on.  Your challenge for today is to guess what on earth this game is.  Obviously you can't know what it's called (I actually haven't decided that yet anyway), or what the plot is, but what kind of game is it?... <a href="http://hamumu.com/journal.php?entry=1328577626">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<DIV ALIGN=CENTER><IMG SRC="http://hamumu.com/images/dev/campscreen.png"></DIV><BR>
A screenshot of what I'm currently working on.  Your challenge for today is to guess what on earth this game is.  Obviously you can't know what it's called (I actually haven't decided that yet anyway), or what the plot is, but what kind of game is it?  How does it play?  What is going on there?  Mysterious!!  Actually, this is probably gonna be easy, but let's see what people say.<BR><BR>
In other news, I was reading back through <I>really</I> old journal entries today, and I decided I need to blog more!  So there's a second challenge for you: From now on (at least for the rest of this month, I may forget this rule later, but hey, you can remind me!), <B>if a journal entry gets comments from 5 different people, I will journal again the next day!</B>  I think that's a fun challenge, because it means I get feedback, and it means you get to know what's going on, and it encourages me to do something I should do anyway.  See if you can keep me journaling nonstop for the rest of my life!<BR><BR>
Rule: Those 5 comments have to be present by the middle-ish of the next day.  If you post something akin to "first!" or something otherwise useless or offensive, I will of course delete it like I always do, which means it won't be present!  So post constructively.<BR><BR>
P.S. Witch Game? is still very much on my mind and I'm really looking forward to getting back to it once I finish up the project pictured above.]]></content:encoded>
			<wfw:commentRss>http://www.ludumdare.com/planet/2012/02/07/guessing-game/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>An Online Conference You Can Attend #AltDevConf</title>
		<link>http://gbgames.com/blog/2012/02/an-online-conference-you-can-attend-altdevconf/</link>
		<comments>http://gbgames.com/blog/2012/02/an-online-conference-you-can-attend-altdevconf/#comments</comments>
		<pubDate>Mon, 06 Feb 2012 10:30:40 +0000</pubDate>
		<dc:creator>GBGames</dc:creator>
				<category><![CDATA[game design]]></category>
		<category><![CDATA[Game Development]]></category>
		<category><![CDATA[Geek / Technical]]></category>
		<category><![CDATA[Marketing/Business]]></category>
		<category><![CDATA[Personal Development]]></category>

		<guid isPermaLink="false">http://gbgames.com/blog/?p=1849</guid>
		<description><![CDATA[<p>If you&#8217;re not familiar with AltDevBlogADay, you should be. Each day, a game developer posts on a variety of game development topics. There&#8217;s a huge backlog of content there now, and while the recent redesign has made it difficult to find the category you want (you have to click on a post to see only <span> . . . &#8594; Read More: <a href="http://gbgames.com/blog/2012/02/an-online-conference-you-can-attend-altdevconf/">An Online Conference You Can Attend #AltDevConf</a></span><p><a href="http://gbgames.com/blog/2012/02/an-online-conference-you-can-attend-altdevconf/">An Online Conference You Can Attend #AltDevConf</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p> <a href="http://gbgames.com/blog/2012/02/an-online-conference-you-can-attend-altdevconf/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re not familiar with <a href="http://altdevblogaday.com">AltDevBlogADay</a>, you should be. Each day, a game developer posts on a variety of game development topics. There&#8217;s a huge backlog of content there now, and while the recent redesign has made it difficult to find the category you want (you have to click on a post to see only some of the tags available as of this writing), it&#8217;s great getting regular, up-to-date, state-of-the-art tips and tricks from the people in the trenches. Authors can be mainstream game programmers, indie developers, academics, or anyone who has something valuable to share.</p>
<p><a href="http://gbgames.com/blog/wp-content/uploads/2012/02/altdevconf.jpg"><img src="http://gbgames.com/blog/wp-content/uploads/2012/02/altdevconf.jpg" alt="AltDevConf" title="AltDevConf" width="303" height="163" class="alignnone size-full wp-image-1850" /></a></p>
<p>It seems to be such a successful site that they&#8217;ve decided to host an online conference. <a href="http://altdevconf.org/">AltDevConf</a> will be held on February 11th and 12th (that&#8217;s this coming weekend), featuring three tracks: education, programming, and design &#038; production. </p>
<blockquote><p>Our goal is twofold: To provide free access to a comprehensive selection of game development topics taught by leading industry experts, and to create a space where bright and innovative voices can also be heard. We are able to do this, because as an online conference we are not subject to the same logistic and economic constrains imposed by the traditional conference model.</p></blockquote>
<p>As it doesn&#8217;t look like I&#8217;ll be attending GDC this year (I&#8217;m still hoping to win an All Access Pass with my <a href="https://twitter.com/#!/GBGames/status/160509840450519040">GDC magnets</a>), AltDevConf seems like a high-quality substitute. While it won&#8217;t be the same as rubbing elbows with other indies or meeting cool celebrities in the gaming world, I&#8217;m excited about it.  </p>
<p>Do you plan to attend? Will you be speaking? </p>
<p><a href="http://gbgames.com/blog/2012/02/an-online-conference-you-can-attend-altdevconf/">An Online Conference You Can Attend #AltDevConf</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p>
]]></content:encoded>
			<wfw:commentRss>http://gbgames.com/blog/2012/02/an-online-conference-you-can-attend-altdevconf/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Big Things for TF2 in 2012</title>
		<link>http://entardev.wordpress.com/2012/02/03/big-things-for-tf2-in-2012/</link>
		<comments>http://entardev.wordpress.com/2012/02/03/big-things-for-tf2-in-2012/#comments</comments>
		<pubDate>Fri, 03 Feb 2012 15:43:31 +0000</pubDate>
		<dc:creator>Entar</dc:creator>
				<category><![CDATA[games]]></category>
		<category><![CDATA[Links]]></category>
		<category><![CDATA[Meet the Team]]></category>
		<category><![CDATA[Team Fortress 2]]></category>
		<category><![CDATA[Valve]]></category>

		<guid isPermaLink="false">http://entardev.wordpress.com/?p=1290</guid>
		<description><![CDATA[Woah, woah, hold everything. The team behind Valve&#8217;s online shooter Team Fortress 2 has posted a most interesting update on the TF2 blog, including some fascinating details about their plans for 2012. This includes a secret TF2 project, the new Steam Workshop Blog, and the Second Annual Saxxy Awards. Those are all well and good, but [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=entardev.wordpress.com&#38;blog=1747869&#38;post=1290&#38;subd=entardev&#38;ref=&#38;feed=1" width="1" height="1" /> <a href="http://entardev.wordpress.com/2012/02/03/big-things-for-tf2-in-2012/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Woah, woah, <strong><em>hold everything</em></strong>.</p>
<p>The team behind Valve&#8217;s online shooter Team Fortress 2 has posted a most interesting <a title="TF2012!" href="http://teamfortress.com/post.php?id=7254" >update</a> on the TF2 blog, including some fascinating details about their plans for 2012. This includes a <em>secret</em> TF2 project, the new Steam Workshop Blog, and the Second Annual Saxxy Awards. Those are all well and good, but I think we&#8217;re most interested in the final &#8220;Meet the Team&#8221; short, the ever-forthcoming video documenting the Pyro&#8217;s (maybe?) dark and (probably) storied past. All the speculating fans will finally find answers to some of the questions surrounding the flame-throwing maniac. Is it a woman in the suit? Is she secretly <a title="Fan-made Meet the Pyro Video - YouTube" href="http://www.youtube.com/watch?v=ww-jfygVEE0" >the announcer</a>? Was his or her flamethrower handed down by his or her ancestor GLaDOS from another universe through a inter-dimensional portal opened by none other than Gordon Freeman&#8217;s great uncle? But then, will Valve even reveal any of these details? We&#8217;ll have to wait for the video to find out.</p>
<p>On second thought, with <a title="Valve Time - Valve Developer Community" href="https://developer.valvesoftware.com/wiki/Valve_Time" >Valve time</a> in the mix, who knows when we&#8217;ll see any of this stuff. Oh, well. If you&#8217;ve got predictions about the Pyro or the secret project, or anything else about this post, leave a comment.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/entardev.wordpress.com/1290/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/entardev.wordpress.com/1290/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/entardev.wordpress.com/1290/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/entardev.wordpress.com/1290/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/entardev.wordpress.com/1290/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/entardev.wordpress.com/1290/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/entardev.wordpress.com/1290/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/entardev.wordpress.com/1290/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/entardev.wordpress.com/1290/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/entardev.wordpress.com/1290/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/entardev.wordpress.com/1290/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/entardev.wordpress.com/1290/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/entardev.wordpress.com/1290/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/entardev.wordpress.com/1290/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=entardev.wordpress.com&amp;blog=1747869&amp;post=1290&amp;subd=entardev&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://entardev.wordpress.com/2012/02/03/big-things-for-tf2-in-2012/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://0.gravatar.com/avatar/aecab269b8073a9162d387ea4e4d36bf?s=96&amp;amp;d=identicon&amp;amp;r=G" length="" type="" />
		</item>
		<item>
		<title>How to create and play IVF / VP8 / WebM / libvpx video in OpenGL</title>
		<link>http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/</link>
		<comments>http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/#comments</comments>
		<pubDate>Thu, 02 Feb 2012 23:50:59 +0000</pubDate>
		<dc:creator>philhassey</dc:creator>
				<category><![CDATA[C++]]></category>
		<category><![CDATA[development]]></category>

		<guid isPermaLink="false">http://www.philhassey.com/blog/?p=1014</guid>
		<description><![CDATA[Disclaimer: this tutorial covers how to render IVF / VP8 / libvpx video in an OpenGL libSDL / SDL window. IVF video only includes video, not audio. For game developers, it&#8217;s trivial to play audio via their own audio system. So you&#8217;ll have two files per movie &#8220;movie.ivf&#8221; and &#8220;movie.ogg&#8221; or whatever. As an exercise [...] <a href="http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><em>Disclaimer: this tutorial covers how to render IVF / VP8 / libvpx video in an OpenGL libSDL / SDL window.  IVF video only includes video, not audio.  For game developers, it&#8217;s trivial to play audio via their own audio system.  So you&#8217;ll have two files per movie &#8220;movie.ivf&#8221; and &#8220;movie.ogg&#8221; or whatever.  As an exercise to the reader, you could easily jam both into a single file if you really wanted to.</em></p>
<p><strong>The Problem We&#8217;re Trying To Solve</strong></p>
<p>So you&#8217;re an indie game developer and you want to show a clip of video in your commercial cross-platform (PC/Mac/Linux/other?) game!  Obviously you want a patent-free open source unrestricted license to do it.</p>
<p><strong>Wait, can&#8217;t I go commercial?</strong></p>
<p>Better than that, you could just use the built-in codecs on a platform!  I&#8217;d suggest this if you are targeting a single platform, iPhone / iOS for example.</p>
<p>Otherwise, you&#8217;ll be using <a href="http://www.radgametools.com/bnkmain.htm">Bink</a>, a commercial solution at $8500 / platform.  I emailed about their &#8220;indie licenses&#8221; and never heard back.</p>
<p><strong>The Open Source Options I didn&#8217;t like much</strong></p>
<p>Here&#8217;s what we have for patent free open source codecs .. and their various problems.</p>
<p><a href="http://theora.org/">Xiph Theora</a> &#8211; Probably the best known codec.  To get it working you have to have libogg, libvorbis, and libtheora all built for your target platforms.  To me, that seemed like a lot to ask.  Also, the libtheora API is a MONSTER.  <a href="http://icculus.org/theoraplay/">playtheora</a> is a SDL example (similar to this one) that covers some of that ugliness, so I&#8217;d recommend checking that out if you want to use theora.</p>
<p><a href="http://diracvideo.org/">Dirac / Schroedinger</a> &#8211; the BBC funded codec.  I couldn&#8217;t get this one to build.  It doesn&#8217;t seem to be all that popular.</p>
<p><a href="http://en.wikipedia.org/wiki/Motion_JPEG">Motion Jpeg</a> &#8211; This isn&#8217;t so much of a codec as an idea.  Make your own movie file with a ton of .jpg&#8217;s in it.  I tried this.  The files get really huge really fast.  I wouldn&#8217;t recommend this.</p>
<p><a href="http://www.openjpeg.org/">Motion JPEG 2000</a> &#8211; This implementation was also pretty confusing.  I couldn&#8217;t find where to start.  And, yeah, this isn&#8217;t all that popular either.</p>
<p><strong>libvpx .. why I chose it</strong></p>
<p><a href="http://www.webmproject.org/code/">WebM / libvpx</a> &#8211; Backed by google this is a new contendor on the block.  The thing that sold me was the <a href="http://www.webmproject.org/tools/vp8-sdk/example__simple__decoder.html">sample encoder</a> which was pretty simple.  It also depends on nothing.  Also, building it on OS X and Linux was trivial.  Also they offer a pre-built Windows binary.  Also, they just had their 1.0.0 release a few days ago.</p>
<p>So, yeah, having a supported, up and coming, easy to build codec was key to me.</p>
<p><strong>How to encode for IVF / libvpx</strong></p>
<p>Since it&#8217;s a new codec, not much supports it right now.  I used a fresh build of ffmpeg under linux that I built with this configure command:</p>
<pre>./configure --enable-encoders --enable-libvpx</pre>
<p>Then I was able to use ffmpeg to encode ivf files pretty easily:</p>
<pre>ffmpeg -i Untitled.mov -vcodec libvpx -b 1000k -s 1024x512 movie.ivf</pre>
<p>Note: we&#8217;re not dealing with WebM files.  WebM files are container files that also contain audio.  Again, you&#8217;ll have to store your audio separately, or create your own container file, or figure out what WebM is on your own time.</p>
<p><strong>So .. what&#8217;s the bottom line?  Do we get any code?</strong></p>
<p>Yes!  I created a libSDL player that plays back the video at max speed possible and it converts the YUV data to RGB data and loads it as a texture.  Here are the functions I provide:</p>
<pre>void playvpx_init(Vpxdata *data, const char *_fname) ;</pre>
<p>Just init your Vpxdata with a filename &#8220;movie.ivf&#8221; .. It&#8217;ll try and get libvpx up and running for you.</p>
<pre>bool playvpx_loop(Vpxdata *data) ;</pre>
<p>Call this once per frame to have it decode a frame of video.  It will return false once it has run out of frames.  If you want to mess with the libvpx YUV data yourself, it&#8217;s data->img.  See the playvpx.cpp source or the libvpx example above to see what that structure provides.  It&#8217;s pretty simple.</p>
<pre>int playvpx_get_texture(Vpxdata *data) ;</pre>
<p>Call this once per frame to have it convert the YUV data to RGB and upload the texture to OpenGL.  It will return 0 on failure or a OpenGL texture ID on success.  I convert on your CPU, so it&#8217;s not super fast, but it should work fine on modern computers.  If anyone cares to provide a Shader version of this function, or provide a SIMD / MMX / SSE version .. well, that would be faster!</p>
<pre>void playvpx_deinit(Vpxdata *data) ;</pre>
<p>Call this function when you&#8217;re done to cleanup.</p>
<p><strong>Conclusion and Source Code</strong></p>
<p>Okay, here&#8217;s <a href='http://www.philhassey.com/blog/wp-content/uploads/2012/02/playvpx.zip'>playvpx</a> for you to check out.  It&#8217;s a C-style API, but I&#8217;m sure I use some minor C++ in there.  Probably wouldn&#8217;t be hard to make it C-only if you require C for your project.</p>
<p>Oh, and I include the libvpx binary for Windows, OS X, and Linux.  So you may not have to build it for any platforms!</p>
<p>The code is licensed under the libvpx BSD-style license.  My code here is a gutted version of their sample_decoder.c, so .. that seems to make most sense to me.</p>
<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<div class="d">
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/&amp;title=How+to+create+and+play+IVF+/+VP8+/+WebM+/+libvpx+video+in+OpenGL" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/&amp;title=How+to+create+and+play+IVF+/+VP8+/+WebM+/+libvpx+video+in+OpenGL" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/&amp;title=How+to+create+and+play+IVF+/+VP8+/+WebM+/+libvpx+video+in+OpenGL" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/&amp;title=How+to+create+and+play+IVF+/+VP8+/+WebM+/+libvpx+video+in+OpenGL" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://slashdot.org/bookmark.pl?url=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/&amp;title=How+to+create+and+play+IVF+/+VP8+/+WebM+/+libvpx+video+in+OpenGL" rel="nofollow" title="Add to&nbsp;Slashdot"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/slashdot.png" title="Add to&nbsp;Slashdot" alt="Add to&nbsp;Slashdot" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit.php?url=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/&amp;title=How+to+create+and+play+IVF+/+VP8+/+WebM+/+libvpx+video+in+OpenGL" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+How+to+create+and+play+IVF+/+VP8+/+WebM+/+libvpx+video+in+OpenGL+@+http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://www.philhassey.com/blog/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
]]></content:encoded>
			<wfw:commentRss>http://www.philhassey.com/blog/2012/02/02/how-to-create-and-play-ivf-vp8-webm-libvpx-video-in-opengl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My 2012 Quest: “12 in 12″</title>
		<link>http://www.mcfunkypants.com/2012/quest/</link>
		<comments>http://www.mcfunkypants.com/2012/quest/#comments</comments>
		<pubDate>Thu, 02 Feb 2012 23:27:49 +0000</pubDate>
		<dc:creator>Breakdance McFunkypants</dc:creator>
				<category><![CDATA[12in12]]></category>

		<guid isPermaLink="false">http://www.mcfunkypants.com/?p=986</guid>
		<description><![CDATA[12 months 12 games 12 songs 12 chapters 12 blog posts 1200 pushups 12 steps 12 words The year is twenty twelve, and I&#8217;m setting forth a personal challenge for myself. A way to break beyond my comfort level and &#8230; <a href="http://www.mcfunkypants.com/2012/quest/">Continue reading <span>&#8594;</span></a> <a href="http://www.mcfunkypants.com/2012/quest/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-987" title="12in12" src="http://www.mcfunkypants.com/wp-content/uploads/2012/02/12in12.jpg" alt="" width="512" height="512" /></p>
<p>12 months</p>
<p>12 games</p>
<p>12 songs</p>
<p>12 chapters</p>
<p>12 blog posts</p>
<p>1200 pushups</p>
<p>12 steps</p>
<p>12 words</p>
<p>The year is twenty twelve, and I&#8217;m setting forth a personal challenge for myself. A way to break beyond my comfort level and strive for ultimate productivity. Success is not guaranteed, and I acknowledge that I&#8217;m reaching for the stars, but these are my new year&#8217;s resolutions:</p>
<p>1. To finish twelve (small) games. A few will likely be on mobile platforms, others in html5 and Flash. Pen and paper RPGs or boardgames count too.</p>
<p>2. To compose an entire album worth of new music (12 songs). I&#8217;ve written many songs in the past but it has been a while since I let the musical inspiration drive my daydreams. These songs will be released as (CC) freeware mp3s that will be available for download from my blog as well as several music social networks like soundcloud.</p>
<p>3. To publish at least two books, (twelve or more chapters worth) as ebooks (pdf, mobi, epub) or traditional paper books. The ancient wisdom, &#8220;write about what you know&#8221; will be my mantra, so the books will be about game development. These books will be available on stores like Amazon, Barnes and Noble, the Kindle and iBooks store and others.</p>
<p>4. To actively maintain my blog (www.mcfunkypants.com) even in light of the fact that I get much more response when I post the same content on social networks like Google+. The cloud cannot be relied upon for longevity so my website will be the permanent record. I hope to produce a few game development tutorials, game jam recaps, and other content that fits my areas of expertise.</p>
<p>5. To continue my quest to get into amazing shape. I hope to do at least 1200 pushups this year, though the number is derived from the other twelve-based choices and I hope to in fact do many more than that. I wonder if I can log 4800?</p>
<p>Last year at my yearly checkup my doctor told me that for the first time in my life I was overweight! I was shocked but my beer belly was a testament to the truth I&#8217;d been in denial of.</p>
<p>I&#8217;ve joined the fitness gamification social network www.fitocracy.com and have been using their operant conditioning tools on myself (you earn XP for exercising and slowly &#8220;levelup&#8221; yourself by completing challenges and quests in your workouts).</p>
<p>Great news: though it is only February, I&#8217;ve already gone back to NOT being overweight (I&#8217;ve recently lost 15 pounds by going for daily 3-6km hikes), which in itself was a great motivator to continue being active and eating well. I hope to never again be anything other than my ideal weight. Even more imporantly, getting into the habit of hiking has become psychologically beneficial as well: these moments of fresh air help me clear my head and I often come up with solutions to things I&#8217;d been having trouble coding earlier.</p>
<p>6. To teach my son to walk and talk. My most important quest for this year is to help my little boy learn to take 12 steps without any help (or furniture to hold on to) and to be able to say 12 different words (and understand their meaning).</p>
<p>That&#8217;s it! My quest has been set in stone.</p>
<p>I hope to use the public declaration of all these personal quests to hold myself accountable so that I do not give up on them. This is precisely why I waited until February to make New Year&#8217;s resolutions: those made on January 1st rarely persist.</p>
<p>The goals above are ones I&#8217;m dead serious about achieving: 12 months, 12 games, 12 songs, 12 chapters, 1200 pushups, 12 steps and 12 words.</p>
<p>Wish me luck!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mcfunkypants.com/2012/quest/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My, myself and my God complex</title>
		<link>http://deadaztec.wordpress.com/2012/02/02/my-myself-and-my-god-complex/</link>
		<comments>http://deadaztec.wordpress.com/2012/02/02/my-myself-and-my-god-complex/#comments</comments>
		<pubDate>Thu, 02 Feb 2012 16:39:26 +0000</pubDate>
		<dc:creator>Tenoch</dc:creator>
				<category><![CDATA[sool]]></category>

		<guid isPermaLink="false">http://deadaztec.wordpress.com/?p=222</guid>
		<description><![CDATA[Conditional statements as expressions In my small review of Rust, I noticed one useful thing, that was the fact that the branches of if-else constructs could &#8220;return&#8221; a final value, which made the whole construct an expression, that could be &#8230; <a href="http://deadaztec.wordpress.com/2012/02/02/my-myself-and-my-god-complex/">Continue reading <span>&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=deadaztec.wordpress.com&#38;blog=11275241&#38;post=222&#38;subd=deadaztec&#38;ref=&#38;feed=1" width="1" height="1" /> <a href="http://deadaztec.wordpress.com/2012/02/02/my-myself-and-my-god-complex/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<h2>Conditional statements as expressions</h2>
<p>In my small review of Rust, I noticed one useful thing, that was the fact that the branches of <code>if-else</code> constructs could &#8220;return&#8221; a final value, which made the whole construct an expression, that could be assigned to a variable:</p>
<pre><code>let var = if a == b {
    5
} else {
    6
};
</code></pre>
<p>I wrote it was particularly convenient associated with the fact that variables in Rust cannot be declared without initialization, which made the following Lua idiom impossible:</p>
<pre><code>local var
if a == b then
    var = 5
else
    var = 6
end
</code></pre>
<p>And obviously, it makes for less typing, since there is no need to repeat the <code>var =</code> part.</p>
<p>However, I completely overlooked the fact that it was possible to do exactly the same in Lua, thanks to the lazy boolean operators:</p>
<pre><code>var = a == b and 5 or 6
</code></pre>
<p>And see, it&#8217;s even far more concise. Even if there are many <code>else if</code> branches, it stays fairly short:</p>
<pre><code>var =   cond1 and val1 or
        cond2 and val2 or
        cond3 and val3 or
        defaultval
</code></pre>
<p>Note however that you can have only one expression in the branch, while using Rust&#8217;s proper <code>if</code> thing gives you an actual block of statements, that can be ended in a single return value if you want. But well.</p>
<h2>Lua&#8217;s logic</h2>
<p>Reminder: in Lua, the <code>or</code> operator evaluates its first argument. If it is non-nil or true, it returns it. If it is false or nil, it evaluates the second argument and returns it. Of course, when using booleans, it&#8217;s exactly equivalent to the logical &#8220;or&#8221;. When using other stuff, it keeps the same logic but allows you to keep the values (not simply their boolean truth).</p>
<p>The <code>and</code> operator evaluates its first argument. It it&#8217;s nil or false, it returns this nil or false value. If it&#8217;s non-nil or true, it evaluates the second argument and returns it. Again, that&#8217;s exactly a logical &#8220;and&#8221; with booleans.</p>
<p>Let&#8217;s review the truth tables:</p>
<pre><code>true or true = true
true or false = true
false or true = true
false or false = false
</code></pre>
<p>Therefore:</p>
<pre><code>true or X = true
false or X = X
</code></pre>
<p>Hence the possibility of lazy evaluation. We need to evaluate the right hand side only when the left hand side is false.</p>
<pre><code>true and true = true
true and false = false
false and true = false
false and false = false
</code></pre>
<p>Therfore:</p>
<pre><code>true and X = X
false and X = false
</code></pre>
<p>Can you see the pretty symmetry? The &#8220;and&#8221; and &#8220;or&#8221; are perfect negatives of each other. These fundamental relations hold:</p>
<pre><code>not(A and B) = not(A) or not(B)
not(A or B) = not(A) and not(B)
</code></pre>
<p>And these:</p>
<pre><code>    not(true and X) = not(X)
==&gt; not(true) or not(X) = not(X)
==&gt; false or Y = Y

    not(false and X) = not(false)
==&gt; not(false) or not(X) = true
==&gt; true or Y = true
</code></pre>
<p>Logic is pretty. Math is pretty.</p>
<p>Anyway, some Lua users despise the overuse of <code>and</code> and <code>or</code> for other stuff than booleans, calling them unclear and difficult to read. I happen to like them very much.</p>
<p>The first classic use is the &#8220;default value&#8221;:</p>
<pre><code>give_me(tea or coffee)
</code></pre>
<p>If there&#8217;s tea, I&#8217;d like some. Otherwise, coffee is just fine. When you say &#8220;I&#8217;ll have tea, or coffee&#8221;, you mean that both are OK, but you usually put your first choice first. That&#8217;s what happens in Lua too.</p>
<p>The second classic use is an equivalent of C&#8217;s ternary operator <code>a ? b : c</code>:</p>
<pre><code>foo = cond and yes or no
</code></pre>
<p>If condition <code>cond</code> holds, give me the <code>yes</code>. Else, the <code>no</code>. It&#8217;s more difficult to find real language equivalents using &#8220;and&#8221; and &#8220;or&#8221;, but it quickly becomes a natural idiom in Lua.</p>
<pre><code>take(raining and umbrella or sunhat)
</code></pre>
<p>&#8220;It&#8217;s raining <em>and</em> I take my umbrella, <em>or</em> then just my sun-hat.&#8221; I admit it&#8217;s less clear than the previous example, but once you&#8217;re used to it, it&#8217;s as readable as:</p>
<pre><code>take(if raining then umbrella else sunhat end)
</code></pre>
<p>Or course if you don&#8217;t need a default value (and can deal with nil), you can leave it out, as a third (maybe less common) idiom:</p>
<pre><code>take(raining and umbrella)
</code></pre>
<p>Finally, combine several of these and you get a multiple branch construct:</p>
<pre><code>var =   cond1 and val1 or
        cond2 and val2 or
        defaultval
</code></pre>
<p>I had never done that in Lua, but it&#8217;s completely correct, and I like it. What about in sool? The boolean operators are going to work exactly the same, so it should be OK. The only missing thing is the operator precedence. In Lua, the <code>and</code> is applied before the <code>or</code>, and we have:</p>
<pre><code>( (cond1 and val1) or (cond2 and val2) ) or defaultval
</code></pre>
<p>I recently re-established operator precedence to sool, and for the sake of this beautiful construct, <code>and</code> must have higher precedence. And <code>or</code> must be left-associative, which is what I decided for all operators. </p>
<p>Done.</p>
<h2>Semantic digressions</h2>
<p>Of course, all this supposes the existence of nil. And that makes a pretty sentence:</p>
<blockquote>
<p>We suppose the existence of the nothing.</p>
</blockquote>
<p>Riddle me that one! It&#8217;s easy to name things, but it takes one more neuron to name the absence of things. But even then, if you&#8217;re able to name it, talk about it, manipulate it in thought, isn&#8217;t it already <em>something</em>?</p>
<p>That&#8217;s one possible way to construct mathematics (or, well, at least the natural numbers). The only thing you know how to do it make sets of things. Start with an empty universe. There is nothing in it. Give a name to the set of all things that exist (which is none): the empty set.</p>
<pre><code>∅ = {}
</code></pre>
<p>Then there&#8217;s one thing in your universe: the empty set. You can also call it 0. Consider the set that contains only it. And for fun, call it &#8220;1&#8243;.</p>
<pre><code>1 = {∅}
</code></pre>
<p>And then</p>
<pre><code>2 = 1 ∪ {1} = {0,1} = {∅,{∅}}
3 = 2 ∪ {2} = {0,1,2} = {∅,{∅},{∅,{∅}}}
</code></pre>
<p>The way to go from one set to the next one is called a successor function:</p>
<pre><code>For any set n, S(n) = n ∪ {n}
</code></pre>
<p>And then you conclude, the set N of natural numbers is the smallest set containing 0 and closed by application of S.</p>
<p>And from this, define operations and whatnot, and build yourself a mathematical system. Fun hey? For more info, there&#8217;s always <a href="http://en.wikipedia.org/wiki/Set-theoretic_definition_of_natural_numbers">Wikipedia</a>.</p>
<p>I love cosmogony, the study of the creation of the universe. Can really anything start existing if there was nothing before? And can you define &#8220;nothing&#8221; if there is indeed nothing to compare it too?</p>
<p>In a more fantasy-like setting, I love the power attributed to language and speech as a creation, or &#8220;actuation&#8221; tool, whether it&#8217;s from the Finnish Kalevala, where bards are wise men who engage in duels of words that slash like weapons, or the biblical creation myth that says</p>
<blockquote>
<p>In the beginning was the Word, and the Word was with God, and the Word was God.</p>
</blockquote>
<p>The French versions usually say &#8220;verb&#8221; instead of &#8220;word&#8221;, which implies action and gives it a certain twist. There&#8217;s also the Myst series of games in which writing books with the proper words creates actual worlds that can be visited, or Tolkien&#8217;s universe in which some ancient beings sang the world into existence (if I remember correctly).</p>
<p>In math terms, when there is a one to one bijection between one space and another one which has a similar structure, you can use one <em>as if</em> it actually was the other. If we simplify a bit, that would hold for the space of names and the space of objects or concepts they refer too.</p>
<p>Considering the name equal to the named: that&#8217;s what we often do in programming.</p>
<pre><code>int i = 5;
Object *obj = new Object;
</code></pre>
<p>What&#8217;s <code>i</code>? It&#8217;s an int. No, it&#8217;s a variable that contains an int. One step further (notice the quotes): what&#8217;s &#8220;<code>i</code>&#8220;? It&#8217;s an int. No, it&#8217;s a variable that contains an int. Well, no, it&#8217;s really the name of a variable that contains an int.</p>
<p>And as I wrote before, it&#8217;s even worse with references. When I say <code>obj</code> is an object, I bypass several levels of existence: <code>obj</code> is a variable that contains the address of an object. And with quotes, it would be the name of that.</p>
<p>But mind you, there is exactly the same confusion happening in real languages, the confusion of the name and the named:</p>
<ul>
<li>What is the name of this man?</li>
<li>This man&#8217;s name is John.</li>
</ul>
<p>Now replace &#8220;this man&#8221; by another way to name him, his actual name:</p>
<ul>
<li>What is the name of John?</li>
<li>John&#8217;s name is John.</li>
</ul>
<p>And in that last sentence, &#8220;John&#8221; is both the person and the name. Confused yet?</p>
<p>In a way, we could try to solve the problem by writing it as such:</p>
<ul>
<li>John&#8217;s name is &#8220;John&#8221;.</li>
</ul>
<p>The need to put quotes is equivalent to using the address operator in C. Think about this:</p>
<ul>
<li>The name of John is &#8220;John&#8221;.</li>
<li>The name of &#8220;John&#8221; is&#8230;</li>
</ul>
<p>What&#8217;s the name of the name of John? John&#8217;s name probably doesn&#8217;t have a name, because John is a random guy. But if you take God instead, his name actually has a name: &#8220;tetragrammaton&#8221;.</p>
<p>Indeed, in Hebrew, Yahveh is written in four letters (semitic languages normally omit the vowels): YHWH. Hence, the name of god is &#8220;YHWH&#8221;, and since the name of god has four letters, it is itself called the &#8220;tetragrammaton&#8221; (&#8220;having four letters&#8221;, in Greek).</p>
<p>The quoting mechanism becomes a serious one in a language like LISP, where code and data are written the same. There is a quote operator that prevents the enclosed expression to be evaluated. Now try writing a LISP interpretor in LISP, using quotes and <code>exec</code> calls. Guarantied headache.</p>
<p>One last related issue in programming is naming strings. When I talk about the string &#8220;Hello&#8221;, does it include its double quotes? When I write about the string, should I say <code>Hello</code> or <code>"Hello"</code>? Or did I really mean <code>""Hello""</code>? Is is clearer if I write <code>&lt;"Hello"&gt;</code>? A programming language normally defines clearly how to write literal<br />
strings and how to escape characters in them. But that is also a source of tremendous headaches, bugs, and security holes (PHP, JavaScript, anyone?)</p>
<p>Anyway, back to the creationist power of words. Complex architectures and silent beings live in the virtual world that is the computer&#8217;s memory, follow inflexible laws at the very base of their every behavior, evolve and reshape themselves as the processor ticks and does the bidding of a mighty being that conveyed it through language from outside the universe. I think the analogy is pretty clear.</p>
<p>I suppose all programmers have a little bit of a god complex.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/deadaztec.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/deadaztec.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/deadaztec.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/deadaztec.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/deadaztec.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/deadaztec.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/deadaztec.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/deadaztec.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/deadaztec.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/deadaztec.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/deadaztec.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/deadaztec.wordpress.com/222/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/deadaztec.wordpress.com/222/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/deadaztec.wordpress.com/222/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=deadaztec.wordpress.com&amp;blog=11275241&amp;post=222&amp;subd=deadaztec&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://deadaztec.wordpress.com/2012/02/02/my-myself-and-my-god-complex/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://0.gravatar.com/avatar/cbd739d76d2c709385169e8d70676c3a?s=96&amp;amp;d=identicon&amp;amp;r=X" length="" type="" />
		</item>
		<item>
		<title>Linux Game Publishing CEO Steps Down</title>
		<link>http://gbgames.com/blog/2012/02/linux-game-publishing-ceo-steps-down/</link>
		<comments>http://gbgames.com/blog/2012/02/linux-game-publishing-ceo-steps-down/#comments</comments>
		<pubDate>Thu, 02 Feb 2012 10:30:39 +0000</pubDate>
		<dc:creator>GBGames</dc:creator>
				<category><![CDATA[Linux Game Development]]></category>
		<category><![CDATA[Marketing/Business]]></category>

		<guid isPermaLink="false">http://gbgames.com/blog/?p=1844</guid>
		<description><![CDATA[<p>Yesterday, I woke up to an email saying that Michael Simms is stepping down after 10 years of running Linux Game Publishing and Tux Games.</p> <p>Wow, 10 years! That&#8217;s a lot of enthusiasm and work, and unfortunately it takes its toll:</p> <p>It took me some months to notice what was going on, and even longer <span> . . . &#8594; Read More: <a href="http://gbgames.com/blog/2012/02/linux-game-publishing-ceo-steps-down/">Linux Game Publishing CEO Steps Down</a></span><p><a href="http://gbgames.com/blog/2012/02/linux-game-publishing-ceo-steps-down/">Linux Game Publishing CEO Steps Down</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p> <a href="http://gbgames.com/blog/2012/02/linux-game-publishing-ceo-steps-down/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Yesterday, I woke up to an email saying that <a href="http://blog.linuxgamepublishing.com/2012/01/31/lgp-history-pt-4-the-end-of-the-ride-but-not-the-end-of-the-company/">Michael Simms is stepping down after 10 years of running Linux Game Publishing and Tux Games</a>.</p>
<p>Wow, 10 years! That&#8217;s a lot of enthusiasm and work, and unfortunately it takes its toll:</p>
<blockquote><p>It took me some months to notice what was going on, and even longer to accept that my burnout was going to kill LGP unless I did something about it. The lack of drive slowed down production of new titles, shipping, customer service, everything that I either handled or had a big part in helping with, was all being compromised.</p>
<p>&#8230;</p>
<p>But I didn’t want to let the company die. Of course not, I have invested too much time, money, blood sweat and tears into LGP to just say ‘That is it, bye’. And so I sat down and had a long think about how to save it. </p></blockquote>
<p>Clive Crous will take the reins at LGP and Tux Games. Good luck, Clive, and good luck with your future endeavors, Michael!</p>
<p><a href="http://gbgames.com/blog/2012/02/linux-game-publishing-ceo-steps-down/">Linux Game Publishing CEO Steps Down</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p>
]]></content:encoded>
			<wfw:commentRss>http://gbgames.com/blog/2012/02/linux-game-publishing-ceo-steps-down/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Chaos Python</title>
		<link>http://renesd.blogspot.com/2012/02/chaos-python.html</link>
		<comments>http://renesd.blogspot.com/2012/02/chaos-python.html#comments</comments>
		<pubDate>Thu, 02 Feb 2012 06:16:00 +0000</pubDate>
		<dc:creator>notme</dc:creator>
				<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://www.ludumdare.com/planet/?guid=1083aae9f2e6ca5ae4b5d063e633da38</guid>
		<description><![CDATA[Add this into your functional tests and smoke it.import sys, randomdef chaos_trace(frame, event, arg):     if event == 'line' and random.random() &#60; 0.000001:         raise MemoryError()    return chaos_tracesys.settrace(chaos_trace)You will get some... <a href="http://renesd.blogspot.com/2012/02/chaos-python.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<div dir="ltr" style="text-align: left;" trbidi="on">Add this into your functional tests and smoke it.<br /><pre>import sys, random<br />def chaos_trace(frame, event, arg): <br />    if event == 'line' and random.random() &lt; 0.000001: <br />        raise MemoryError()<br />    return chaos_trace<br />sys.settrace(chaos_trace)<br /></pre>You will get some lovely random failures injected into your code.  A great way to find bugs, and make sure your reasoning is sound in the face of CHAOS!</div><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/10678074-2121919144344623323?l=renesd.blogspot.com' alt='' /></div>]]></content:encoded>
			<wfw:commentRss>http://renesd.blogspot.com/feeds/2121919144344623323/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Global Game Jam 2012 Pictures and More Video</title>
		<link>http://www.garagecoder.com/?p=114</link>
		<comments>http://www.garagecoder.com/?p=114#comments</comments>
		<pubDate>Wed, 01 Feb 2012 20:22:26 +0000</pubDate>
		<dc:creator>BenW</dc:creator>
				<category><![CDATA[game dev]]></category>

		<guid isPermaLink="false">http://www.garagecoder.com/?p=114</guid>
		<description><![CDATA[Here are a couple of crowd shots I took which show just how many people were there.


I think it was fairly obvious that we weren&#8217;t going to win the children&#8217;s choice award.

Finally here is some footage of people playing our game.

 <a href="http://www.garagecoder.com/?p=114">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Here are a couple of crowd shots I took which show just how many people were there.</p>
<p><img class="alignnone" title="Global Game Jam 2012 Photo 1" src="http://images.garagecoder.com/gamejam_2012_1.JPG" alt="Global Game Jam 2012 Photo 1" width="640" /></p>
<p><img class="alignnone" title="Global Game Jam 2012 Photo 3" src="http://images.garagecoder.com/gamejam_2012_3.JPG" alt="Global Game Jam 2012 Photo 3" width="640" /></p>
<p>I think it was fairly obvious that we weren&#8217;t going to win the children&#8217;s choice award.</p>
<p><img class="alignnone" title="Global Game Jam 2012 Photo 2" src="http://images.garagecoder.com/gamejam_2012_2.JPG" alt="Global Game Jam 2012 Photo 2" width="640" /></p>
<p>Finally here is some footage of people playing our game.</p>
<p><iframe width="640" height="360" src="http://www.youtube.com/embed/VOZVfX_AReg" frameborder="0" allowfullscreen></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.garagecoder.com/?feed=rss2&#038;p=114</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Is Asking Customers to Pre-order a Bad Thing?</title>
		<link>http://gbgames.com/blog/2012/02/is-asking-customers-to-pre-order-a-bad-thing/</link>
		<comments>http://gbgames.com/blog/2012/02/is-asking-customers-to-pre-order-a-bad-thing/#comments</comments>
		<pubDate>Wed, 01 Feb 2012 10:30:09 +0000</pubDate>
		<dc:creator>GBGames</dc:creator>
				<category><![CDATA[Game Development]]></category>
		<category><![CDATA[Marketing/Business]]></category>

		<guid isPermaLink="false">http://gbgames.com/blog/?p=1837</guid>
		<description><![CDATA[<p>A month ago, there was a post on Reddit asking what people thought about indie developers asking for money up front. </p> <p>Some people are fine if they get a good quality playable build for pre-ordering, but no one seemed to be happy with the idea of funding basic engine development. It seems the general <span> . . . &#8594; Read More: <a href="http://gbgames.com/blog/2012/02/is-asking-customers-to-pre-order-a-bad-thing/">Is Asking Customers to Pre-order a Bad Thing?</a></span><p><a href="http://gbgames.com/blog/2012/02/is-asking-customers-to-pre-order-a-bad-thing/">Is Asking Customers to Pre-order a Bad Thing?</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p> <a href="http://gbgames.com/blog/2012/02/is-asking-customers-to-pre-order-a-bad-thing/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>A month ago, there was a post on Reddit <a href="http://www.reddit.com/r/IndieGaming/comments/nnuyl/what_do_you_think_of_indie_developers_asking_for/">asking what people thought about indie developers asking for money up front</a>. </p>
<p>Some people are fine if they get a good quality playable build for pre-ordering, but no one seemed to be happy with the idea of funding basic engine development. It seems the general consensus is that people are getting tired of the so-called &#8220;fad&#8221; of funding a game before it is finished with no guarantee that they will see a payoff. </p>
<p><i>Minecraft</i>&#8216;s wild success through pre-orders aside, it&#8217;s not really a new funding tactic at all. Lots of indie developers have tried to ask for money before their games are finished, and some have seen more success than others. </p>
<p>The <a href="http://www.amazon.com/gp/product/1584502142/ref=as_li_qf_sp_asin_tl?ie=UTF8&#038;tag=gb0f-20&%23038;linkCode=as2&%23038;camp=1789&%23038;creative=9325&%23038;creativeASIN=1584502142">Indie Game Development Survival Guide</a><img src="http://www.assoc-amazon.com/e/ir?t=gb0f-20&#038;l=as2&%23038;o=1&%23038;a=1584502142" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /> by David Michael mentions how Samu Games started selling <i>Artifact</i> when it was in the beta testing stage, complete with perks for early customers. And this was in 1999.</p>
<p>Today, sites such as <a href="http://www.kickstarter.com/">KickStarter</a> and <a href="http://8bitfunding.com/">8-bit Funding</a> have enabled a number of high-profile projects to get funding from fans. Of course, a lot of projects don&#8217;t get funded and therefore don&#8217;t become high-profile. </p>
<p>So if you don&#8217;t have a big name to leverage like Notch or Andy Schatz or Derek Yu, are you doomed to obscurity? </p>
<p>No, but obviously an existing name brand helps. Otherwise, success at crowdfunding requires hard work to get your name out there. In other words, marketing. And you have to be able to demonstrate you can deliver the goods.</p>
<p>I started taking pre-orders for <a href="http://stopthathero.com/">Stop That Hero!</a> late last year, and I&#8217;ll admit feeling a bit anxious about it at the time. I didn&#8217;t have the game in a playable state yet, and here I was asking people for money in anticipation of the initial release.</p>
<p>While I didn&#8217;t get many pre-orders, it was definitely a nice feeling to see people actually spending some money on my game. It showed some interest, and it gave me a productivity boost to know I had existing customers to satisfy. </p>
<p>Now, when it comes to how I marketed the <a href="http://www.stopthathero.com/">Stop That Hero!</a> pre-order, I&#8217;m sure I did a lot of things wrong. Perhaps I should have had more videos of game play as I continued work. Maybe I should have been posting more screenshots. I could have chosen to prioritize work on certain features in the hopes that they would excite players more than the features I did work on. And maybe I wasn&#8217;t very assertive with asking for pre-orders in the first place.</p>
<p>At the time, I was struggling to get the alpha build across the finish line, but I kept getting good feedback from playtesters. Since the game was good enough to provide some enjoyment to players, it meant it was good enough to ask for players to pay for that enjoyment.</p>
<p>Now, of course some people weren&#8217;t happy with the idea of paying up front for a game they couldn&#8217;t see. And it&#8217;s hard to blame them. Since many game projects don&#8217;t get finished, it&#8217;s asking a lot to essentially gamble the cost of a pre-order on an unknown. Especially when indie developers don&#8217;t necessarily have the <a href="http://gbgames.com/blog/2012/01/my-offsite-backup-solutions/">offsite backup solutions</a> of larger studios when disaster strikes. See the <a href="http://projectzomboid.com/blog/index.php/2011/10/project-zomboid-burglary-statement/">Project Zomboid burglary</a> for an example. All of their code was gone when someone stole two laptops, so it was a huge setback for the developers who had to rely on outdated backups to continue.</p>
<p>And it didn&#8217;t sit well with some of their customers, judging by the Reddit thread. It seems this experience turned some people off of pre-orders and paying for early builds in general. </p>
<p>All that said, it seems that making pre-orders work requires regular, quality content. Basically, if you stop talking to your customers and prospects, they&#8217;ll stop caring. </p>
<p>But if all you do is talk and never produce anything, no one is going to stick around. Whether you&#8217;re taking pre-orders or pledges, you have to be able to show that you can deliver results.</p>
<p>If you can do both, then pre-orders are worthwhile. Otherwise, you&#8217;re wasting your customers&#8217; time as well as your own. </p>
<p><a href="http://gbgames.com/blog/2012/02/is-asking-customers-to-pre-order-a-bad-thing/">Is Asking Customers to Pre-order a Bad Thing?</a> is a post from: <a href="http://gbgames.com/blog">GBGames - Thoughts on Indie Game Development</a></p>
]]></content:encoded>
			<wfw:commentRss>http://gbgames.com/blog/2012/02/is-asking-customers-to-pre-order-a-bad-thing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Humble Bundle for Android</title>
		<link>https://entardev.wordpress.com/2012/01/31/the-humble-bundle-for-android/</link>
		<comments>https://entardev.wordpress.com/2012/01/31/the-humble-bundle-for-android/#comments</comments>
		<pubDate>Wed, 01 Feb 2012 01:56:25 +0000</pubDate>
		<dc:creator>Entar</dc:creator>
				<category><![CDATA[android]]></category>
		<category><![CDATA[games]]></category>
		<category><![CDATA[Humble Indie Bundle]]></category>
		<category><![CDATA[Links]]></category>

		<guid isPermaLink="false">http://entardev.wordpress.com/?p=1287</guid>
		<description><![CDATA[&#8230; and Linux and Mac and Windows. Once again, the Humble Indie Bundle guys are back with The Humble Bundle for Android. While the title clues us in on the availability of the games, through the bundle, for Android, the bundle also includes versions of the game for Linux, Mac and Windows. The games in [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=entardev.wordpress.com&#38;blog=1747869&#38;post=1287&#38;subd=entardev&#38;ref=&#38;feed=1" width="1" height="1" /> <a href="https://entardev.wordpress.com/2012/01/31/the-humble-bundle-for-android/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>&#8230;<em> and Linux and Mac and Windows.</em></p>
<p>Once again, the Humble Indie Bundle guys are back with <a title="Humble Indie Bundle" href="http://www.humblebundle.com/" >The Humble Bundle for Android</a>. While the title clues us in on the availability of the games, through the bundle, for Android, the bundle also includes versions of the game for Linux, Mac and Windows. The games in the bundle this time around are <em><a title="Mobigame" href="http://www.mobigame.net/" >EDGE</a></em>, <em><a title="Osmos" href="http://www.hemispheregames.com/osmos/" >Osmos</a></em>, <em><a title="Anomaly: Warzone Earth" href="http://www.anomalythegame.com/default.aspx" >Anomaly: Warzone Earth</a></em>, and if you pay more than the running average, the excellent <em><a title="World of Goo" href="http://2dboy.com/games.php" >World of Goo</a></em>. As always, the bundle costs whatever you care to pay for it, is DRM-free, and supports charities (Child&#8217;s Play and Electronic Frontier Foundation).</p>
<p>Let us know what you think of the games and the bundle in the comments!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/entardev.wordpress.com/1287/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/entardev.wordpress.com/1287/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/entardev.wordpress.com/1287/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/entardev.wordpress.com/1287/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/entardev.wordpress.com/1287/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/entardev.wordpress.com/1287/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/entardev.wordpress.com/1287/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/entardev.wordpress.com/1287/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/entardev.wordpress.com/1287/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/entardev.wordpress.com/1287/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/entardev.wordpress.com/1287/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/entardev.wordpress.com/1287/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/entardev.wordpress.com/1287/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/entardev.wordpress.com/1287/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=entardev.wordpress.com&amp;blog=1747869&amp;post=1287&amp;subd=entardev&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>https://entardev.wordpress.com/2012/01/31/the-humble-bundle-for-android/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="https://secure.gravatar.com/avatar/aecab269b8073a9162d387ea4e4d36bf?s=96&amp;amp;d=identicon&amp;amp;r=G" length="" type="" />
		</item>
		<item>
		<title>What Can&#8217;t Indies Do?</title>
		<link>http://hamumu.com/journal.php?entry=1328029013</link>
		<comments>http://hamumu.com/journal.php?entry=1328029013#comments</comments>
		<pubDate>Wed, 01 Feb 2012 00:56:53 +0000</pubDate>
		<dc:creator>jamul@hamumu.com (Mike Hommel)</dc:creator>
		
		<guid isPermaLink="false">http://hamumu.com/journal.php?entry=1328029013</guid>
		<description><![CDATA[Well, a lot, it turns out.  Let me open this discussion with a game review:
Batman: Arkham City
I got this free with my new video card, which is awesome, because I desperately wanted it ever since I played Arkham Asylum. I was going to say who it's by ... <a href="http://hamumu.com/journal.php?entry=1328029013">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[Well, a lot, it turns out.  Let me open this discussion with a game review:<BR><BR>
<B>Batman: Arkham City</B><BR><BR>
I got this free with my new video card, which is awesome, because I desperately wanted it ever since I played <A HREF="http://hamumu.com/journal.php?entry=1318372304">Arkham Asylum</A>. I was going to say who it's by (Rocksteady), but there are layers of publishers and middlemen such that I don't actually know who it's <I>by</I>, which is certainly something indies need not worry about.<BR><BR>
<I>AMAZING</I> game!  I absolutely love it, and I've been playing it obsessively and dangerously for the past week, to the point of ignoring much that I really need to be doing.  I'll make up excuses like "Well, I implemented that.  I deserve a Batman break!"  I've been annoying my wife as I constantly pop up behind the couch and around corners saying, "I'm Batman." (Michael Keaton voice, the most ludicrous of Batmen.  Then again, I never saw Clooney, and I know he had to face Arnie)<BR><BR>
So, if you click on that Arkham Asylum up there, you can see me gushing over that game.  This game is, no question, more of the same.  A <I>lot lot</I> more.  I finished the main story mode several days ago, and since then I've been playing maybe 4 hours a day, and I'm <I>still</I> not done just collecting the hidden riddles and doing the side missions.  I haven't even started New Game Plus mode or any of the Challenge Maps.  I am now riskily going to launch Steam to display my total playtime.  Let's hope I don't start playing.  It says 27 hours played, which is less than I thought.  The game calls my current state 63% complete, though for the sake of my productivity, I won't launch it to verify that.  I think I've got so much to go that it'll be something like 100 hours if I actually try to complete all the challenges.  And fail.  Those fighting challenges are murder later on (in Arkham Asylum, anyway, and I expect the same here).<BR><BR>
So... in short, the story's great (with a fun twist), it's never too hard (except the stupid AR training missions, which are very frustrating), the fighting is awesome (better than before, thanks to the ability to quickfire your gadgets in combat, yanking guys around with your batclaw, electrocuting them, dropping explosives while doing a backflip, etc), the stealth is awesome (better than before, thanks to more new and exciting tools, and enemies with more unique threats to you from thermal goggles to radar jammers).  There is no Killer Croc fight this time, no boss is ever painful to experience, though some are pretty tough.  There's a scene, in the museum, that's almost a parody of the Killer Croc fight, in that it's some of the same stuff, but completely trivialized.  There are hundreds (400 I think?) of Riddler Trophies to collect, and almost every one has a little 'puzzle' involved in getting it.  Usually something quite trivial, but the variety is amazing.  Some test your gliding skills, some are for your brain, some require assorted tools, and some just rely on reflexes and timing.<BR><BR>
There's also Catwoman, which is definitely a little change of pace from Batman.  She has roughly the same abilities (only two very simple gadgets to Batman's 12ish), but she's a lot faster, a lot less capable in terms of travel, and a lot more limited in her stealth abilities.  But she can get to places he can't, and has her own Riddler Trophies to collect.  She also has a tiny bit of story of her own.  Not much for sure, just a few scenes and a (very nasty) boss to fight, but they're fun to do, and you can even level her up a bit.<BR><BR>
If there is a minus to Arkham City, besides the patently unfun AR Training, it lies in being a little too complicated, over what Arkham Asylum did.  I definitely spend a lot more time wondering which gadget to use and looking at the situation instead of playing, and in fights sometimes my brain freezes up just thinking about the sheer number of choices because I can't think of which one applies to the specific moment I'm in.  Then they punch me.  Sometimes I just plain hit the wrong button because there are too many functions to keep track of.  So it's kind of the classic, "If this game has any faults, it's that it's <I>too</I> much fun", only with an actual downside.<BR><BR>
So that's an easy <B>5/5</B> Yerfdogs from me.  It's so great that such an amazing new game series has appeared.  They are rare and precious jewels!<BR><BR>
<B>What Can't Indies Do?</B>
<BR><BR>
Now to my point.  Batman is what indies can't do.  Oh sure, there's the license, which obviously no indie will ever be able to afford, but take that aside.  Indies <I>can't</I> make a game like this.  The gameplay particulars could be copied - an open world in which you zoom around and punch guys or go into stealth situations against them, that is all possible and it's all been done (maybe not in one game though?) - but this implementation is light years beyond what the most dedicated independent developer could accomplish.  A significant part of the thrill in playing this game comes from the things that cost literally millions of dollars and hundreds of man-years of work.<BR><BR>
When you push the punch button as Batman, there are dozens of different things that can happen, and every one of them is an animation that somebody motion captured (or created, I don't know!).  You might just punch the guy, knee him, elbow him, jumpkick, do a flying flip to elbow drop on somebody across the room, grab the guy's face and slam it into a wall, and just on and on through little variations, depending on your proximity to him, how far into a combo you are, what's in the environment around you, and other nearby enemies.  And all of these things have been animated.  I would guess that Batman alone has nearly a thousand animations in this game.  The fact that the "break the enemy's weapon" animation is different for a lead pipe and a baseball bat and a gun (possibly even different for different guns?) and a sword is mind-boggling.  He only bends the pipe, which I would expect to make it still quite useful, but nobody picks it up anymore.<BR><BR>
What blows my mind in terms of animation is one very simple thing I keep noticing: there's a situation in which you can press a button to interrogate somebody (a feature I quite enjoy, much improved over how Arkham Asylum handled the equivalent scenario).  The first few times I did it, there was a basic animation: he picks the guy up by his neck, threatens him, the guy talks and struggles, and then he elbows him unconscious.  I thought that was it, until I interrogated a guy next to a wall, and discovered there's a different animation where he throws him against the wall.  Then there was doing it near a ledge, and he dangled him over the ledge with one hand!  Those <I>may</I> be the only three options, but I don't even know that.  The point is, they could've easily done all this with one simple animation, the basic grab one.  It would work near walls and ledges just fine, since you're still standing on the ground.  But they didn't do that.  They threw in more animations just for the joy of seeing it.  Of course, all these interrogations also draw from a wide variety of random voicework too, different threats and responses.<BR><BR>
And that voicework!  There has to be hours of voicework (very top-notch voice acting too) in this game, from all the random conversations you overhear that hardly ever repeat to the massive amounts of talking between the different heroes and villains both in cutscenes and during gameplay.  It's really something that I don't press a button to skip hearing what the villain has to say to me when I die.  The first five times.<BR><BR>
The art is great too, but whatever.  Anybody can do good art (although I could rattle on about the sheer <I>amount</I> of it, as with everything else.  Tiny TINY details everywhere, that vary so widely from place to place).<BR><BR>
The point is, it's a blockbuster.  Indies can make great games, games that are more fun than the big publishers make.  But they can't make this kind of spectacle.  It's not a matter of time and heart and love and sweat, it's a simple impossibility.  It's the same as in movies, but in movies that's a no-brainer (indies can't afford to blow up a building), while in games I feel like, as the indie bar keeps rising, people think anybody can do anything.  Well, we can't.  Batman is something only a big-money publisher could create, or would.  They could've made just as much money with 1/10 the work.  Batman really doesn't need 20 different kinds of punches, nobody would've complained if the punch button always threw a normal punch.  But thank heavens for the hubris of the big-money fat cats, because without it, Batman would not be the spectacle and wonder that it is.  Those 20 kinds of punches add a subtle thrill to the game that means something, even if it's something minor, nowhere close to worth the 6 months of effort from a team of ten animators that went into it.<BR><BR>
So what's the conclusion?  I suppose it's that I'm glad the big publishers and overhyped AAA games exist, and that they don't comprehend the concept of effort vs. reward.  I like indie experiences, but I also want to see <B>The Matrix</B> sometimes.  Don't worry, big publishers, I will let you continue to exist.  For now.]]></content:encoded>
			<wfw:commentRss>http://www.ludumdare.com/planet/2012/01/31/what-cant-indies-do/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Video from Global Game Jam 2012</title>
		<link>http://www.garagecoder.com/?p=105</link>
		<comments>http://www.garagecoder.com/?p=105#comments</comments>
		<pubDate>Wed, 01 Feb 2012 00:05:57 +0000</pubDate>
		<dc:creator>BenW</dc:creator>
				<category><![CDATA[game dev]]></category>

		<guid isPermaLink="false">http://www.garagecoder.com/?p=105</guid>
		<description><![CDATA[Just throwing up some video I took of the 2012 Global Game Jam at NYU. I caught about 20-30 seconds of most of the games. Sorry if I missed anyone&#8217;s.

 <a href="http://www.garagecoder.com/?p=105">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Just throwing up some video I took of the 2012 Global Game Jam at NYU. I caught about 20-30 seconds of most of the games. Sorry if I missed anyone&#8217;s.</p>
<p><iframe width="640" height="360" src="http://www.youtube.com/embed/Q1ZyRjIEn-M" frameborder="0" allowfullscreen></iframe></p>
]]></content:encoded>
			<wfw:commentRss>http://www.garagecoder.com/?feed=rss2&#038;p=105</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Global Game Jam 2012</title>
		<link>http://allefant.com/global-game-jam-2012/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=global-game-jam-2012</link>
		<comments>http://allefant.com/global-game-jam-2012/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=global-game-jam-2012#comments</comments>
		<pubDate>Tue, 31 Jan 2012 22:24:49 +0000</pubDate>
		<dc:creator>Allefant</dc:creator>
				<category><![CDATA[News]]></category>

		<guid isPermaLink="false">http://allefant.com/?p=602</guid>
		<description><![CDATA[On Friday I travelled to Vienna to attend my sister&#8217;s &#8220;Sponsionsfeier&#8221; (ceremony where she was awarded her Master&#8217;s degree in biomedicine). I had heard of the GGJ earlier from Oncer in #Moosader so looked up the address and went there. &#8230; <a href="http://allefant.com/global-game-jam-2012/">Continue reading <span>&#8594;</span></a> <a href="http://allefant.com/global-game-jam-2012/?utm_source=rss&#38;utm_medium=rss&#38;utm_campaign=global-game-jam-2012">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>On Friday I travelled to Vienna to attend my sister&#8217;s &#8220;Sponsionsfeier&#8221; (ceremony where she was awarded her Master&#8217;s degree in biomedicine). I had heard of the GGJ earlier from Oncer in #Moosader so looked up the address and went there. And decided to register and take part.</p>
<p>I teamed up with someone who wanted to make a 3D snake clone. The result turned out quite interesting I think:</p>
<p><img src="http://globalgamejam.org/sites/default/files/uploads/2012/13764/press.jpg?1328047935" alt="" /></p>
]]></content:encoded>
			<wfw:commentRss>http://allefant.com/global-game-jam-2012/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Some tweaking before the last straight line</title>
		<link>http://deadaztec.wordpress.com/2012/01/30/some-tweaking-before-the-last-straight-line/</link>
		<comments>http://deadaztec.wordpress.com/2012/01/30/some-tweaking-before-the-last-straight-line/#comments</comments>
		<pubDate>Mon, 30 Jan 2012 17:09:53 +0000</pubDate>
		<dc:creator>Tenoch</dc:creator>
				<category><![CDATA[sool]]></category>

		<guid isPermaLink="false">http://deadaztec.wordpress.com/?p=216</guid>
		<description><![CDATA[Class and struct renaming One thing has always bothered me while writing my compiler, it&#8217;s the fact that the words &#8220;class&#8221; and &#8220;struct&#8221; have a very different status, although they are used at the same level. Lemme clarify. A class &#8230; <a href="http://deadaztec.wordpress.com/2012/01/30/some-tweaking-before-the-last-straight-line/">Continue reading <span>&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=deadaztec.wordpress.com&#38;blog=11275241&#38;post=216&#38;subd=deadaztec&#38;ref=&#38;feed=1" width="1" height="1" /> <a href="http://deadaztec.wordpress.com/2012/01/30/some-tweaking-before-the-last-straight-line/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<h2>Class and struct renaming</h2>
<p>One thing has always bothered me while writing my compiler, it&#8217;s the<br />
fact that the words &#8220;class&#8221; and &#8220;struct&#8221; have a very different status,<br />
although they are used at the same level. Lemme clarify.</p>
<p>A class is a model of object. The model is the class, the particular<br />
instance is an object.</p>
<p>A structure is both the model and the instance. I like this not. When I<br />
do:</p>
<pre><code>astruct = MyStruct
</code></pre>
<p>the model <code>MyStruct</code> is called a structure, and the content of that<br />
particular variable <code>astruct</code> is also &#8220;a structure&#8221;. This is very<br />
annoying, because when talking about the models, structures and classes<br />
are very similar. In fact, they are even the same thing in my compiler,<br />
except that one has a &#8220;structure&#8221; flag set. And I never know how to<br />
refer to the set of both. &#8220;Class or structure&#8221;. &#8220;Composite&#8221; usually does<br />
it. But everywhere in my code, I use &#8220;Class&#8221; for both.</p>
<p>Since structures are just &#8220;like classes, but value types&#8221;, saying<br />
&#8220;class&#8221; for just the &#8220;by reference&#8221; classes seems like a bit of language<br />
abuse.</p>
<p>When in the code we use &#8220;class&#8221; to introduce a class definition, and<br />
&#8220;struct&#8221; to introduce a structure definition, we mix up the semantics a<br />
little bit. Where &#8220;class&#8221; is quite clear (&#8220;what follows is a class, ie.<br />
a model for an object&#8221;), &#8220;struct&#8221; is not (&#8220;what follows is a structure,<br />
but not the one you mean, a model for it, but it still kind of is<br />
called a structure anyway&#8221;).</p>
<p>Wiktionary defines class as:</p>
<blockquote>
<p>A group, collection, category or set sharing characteristics or<br />
attributes.</p>
</blockquote>
<p>That applies to both: all structs of a same kind share attributes and<br />
behavior, they form a class, just as much as objects that share<br />
attributes and behaviors form a class.</p>
<p>In sool, an object lives on the heap: it has a unique identity (it&#8217;s<br />
address), not only an internal state. It is an <strong>object</strong> as we mean it<br />
in every day life (a mug, a phone, another phone). A structure on the<br />
other hand has only its internal state, its <strong>value</strong>: where it is in<br />
memory is irrelevant, and two separate structures with the same content<br />
are indistinguishable.</p>
<p>So what about using the word &#8220;class&#8221; for what it means: model,<br />
blueprint, and apply it to both kind of things we have: objects and<br />
values.</p>
<p>Writing source code is writing <em>object classes</em> and <em>value classes</em>. And<br />
since all we do is writing classes, we can omit the word, and put<br />
directly the precision:</p>
<pre><code>object Dog
    text name
end

value Vector
    num x
    num y
end
</code></pre>
<p>The fact that it emphasizes the natural behaviors is really interesting.<br />
Values have no identity, just content, or essence: they can only be<br />
copied around. A Vector is a value just as a number is a value. An<br />
object, on the other hand, is an independent separate entity. You create<br />
it, fill it with data, and it can interact with other objects. The word<br />
&#8220;class&#8221; is polyvalent.</p>
<pre><code>v = Vector(1,2)
d = Dog("Barky")
</code></pre>
<p><code>v</code> is a value of class <code>Vector</code>. It is <em>the</em> vector <code>(1,2)</code>. If another<br />
vector has the value <code>(1,2)</code>, they will be the same vector, just as we<br />
say that 10 and 10 are the same number, or blue and blue are the same<br />
color. On the other hand, <code>d</code> is an object of class <code>Dog</code>. It is <em>a</em><br />
dog, which happens to be named Barky. If another dog was named Barky,<br />
they would still be different dogs. Just like two cars from the same<br />
model, despite being exactly the same when they come out of the factory,<br />
are really two different cars that can evolve in their own ways.</p>
<p>I like this. Not only it makes things clearer, but it brings a<br />
bit of originality. &#8220;struct&#8221; and &#8220;class&#8221; as keywords are so C++.</p>
<h2>Default values for argument</h2>
<p>I was writing a draft of interface for the built-in types, and I noticed<br />
I was already repeating myself a lot. Thanks to method overloading, we<br />
can have different prototypes for the same method. A particular use of<br />
this is when we want to omit some arguments:</p>
<pre><code>method data copy() end
method data copy(blob newsize) end
method data copy(blob newsize, blob val) end

method text gsub(text pattern, text repl) end
method text gsub(text pattern, text repl, blob times) end

method text rep(blob times) end
method text rep(blob times, text sep) end
</code></pre>
<p>That already bothers me. In Lua, where everything is dynamic, you can<br />
pass any number of arguments to any function, and if you don&#8217;t pass<br />
enough, the rest is filled with nil. That way, you can have a sequence<br />
of optional arguments at the end of the argument list, which makes very<br />
nice shortcuts.</p>
<p>The current way to do that in sool is to manually define all prototypes<br />
and do the calls with the default values inside. Thanks to inlining, the<br />
final machine code will probably be the same, but the source code has a<br />
lot more in it.</p>
<p>Lua allows this in a general manner, and uses the nil mechanism to<br />
&#8220;catch&#8221; which arguments were not filled. C++ allows default values for<br />
the arguments at the end of the list as well.</p>
<p>Since now we have a proper &#8220;optional type&#8221; equivalent for each normal<br />
type, we could do something similar.</p>
<pre><code>method data copy(blob? newsize, blob? val) end
method text rep(blob times, text? sep) end
</code></pre>
<p>Consecutive optional typed arguments at the end of the list can be<br />
omitted when writing the call (and will get the nil value):</p>
<pre><code>foo = somedata.copy         -- same as .copy(nil,nil)
foo = somedata.copy(200)    -- same as .copy(200,nil)
foo = somedata.copy(200,2)

megalol = "lol".rep(2)      -- same as "lol".rep(2,nil): "lollol"
megalol = "lol".rep(2,",")  -- "lol,lol"
</code></pre>
<p>Pretty sweet. But here comes the &#8220;however&#8221;.</p>
<p>However, that can result in an ambiguity:</p>
<pre><code>-- method foo(num a)
-- method foo(num a, num? b)

obj.foo(10)     -- is it really foo(10) or foo(10,nil)?
</code></pre>
<p>Are there really cases where you&#8217;d need to be able to define both? Are<br />
there really cases in which an optional-typed argument is not an<br />
optional argument?</p>
<p>Some ambiguities are trickier:</p>
<pre><code>-- method foo(num? lol) end
-- method foo(blob? lol) end

obj.foo()
obj.foo(nil)
</code></pre>
<p>Yikes. What <code>nil</code> is that? A nil num or a nil blob? A poor<br />
implementation would simply pick the first one in the list that matches<br />
the call. That would be random, that would be bad. I mentioned already<br />
that classes may have a built-in selfless <code>nilval</code> method that would be<br />
used only to type an expression:</p>
<pre><code>obj.foo(num:nilval)     -- no more ambiguity
obj.foo(blob:nilval)
</code></pre>
<p>But the less stuff I build in, the happier I am. You can always do:</p>
<pre><code>extend num
    selfless num? nilval()
        return nil
    end
end
</code></pre>
<p>if you really need it.</p>
<p>In any case, trying to solve ambiguities at the call is not completely<br />
awesome. Defining conflicting methods in the first place is a bad idea.<br />
If it&#8217;s possible to pass either a number, or a blob, or nothing, the<br />
safer thing to do is:</p>
<pre><code>method foo() end
method foo(num a) end
method foo(blob a) end
</code></pre>
<p>and be done with it. I have difficulties imagining cases where you&#8217;d<br />
need to make the difference between an absence of number and an absence<br />
of blob. When in doubt, just write them all down.</p>
<p>Unfortunately, that means a bit more work for the analyzer, which will<br />
have to internally generate all prototypes corresponding to missing<br />
arguments:</p>
<pre><code>method foo(num n, num? m, text? t, data? d) end

-- becomes:
foo:num,num?,text?,data?
foo:num,num?,text?
foo:num,num?
foo:num
</code></pre>
<p>And all conflicts can be caught. C++ allows ambiguous interfaces to be<br />
defined, and catches the conflict only at the call. That seems odd,<br />
given that an ambiguous interface will always result in a ambiguous<br />
call, except if all arguments are provided, which would make the whole<br />
default argument thing pretty useless.</p>
<p>If the conflicts are checked at the interface, then every call is non<br />
ambiguous and can be resolved to a single method.</p>
<p>It&#8217;s true, defining optional-typed arguments at the end of the list does<br />
slightly pollute the method namespace, and may unintentionally bring<br />
trouble. But like I wrote earlier, if two methods have the same name,<br />
they really should do the same thing. If this system gives birth to a<br />
conflict, then probably one of the methods does something slightly<br />
different, and needs to be named something else.</p>
<p>Optionals, in any case, should be used wisely. They require a certain<br />
amount of care in handling them.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/deadaztec.wordpress.com/216/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/deadaztec.wordpress.com/216/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/deadaztec.wordpress.com/216/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/deadaztec.wordpress.com/216/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/deadaztec.wordpress.com/216/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/deadaztec.wordpress.com/216/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/deadaztec.wordpress.com/216/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/deadaztec.wordpress.com/216/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/deadaztec.wordpress.com/216/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/deadaztec.wordpress.com/216/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/deadaztec.wordpress.com/216/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/deadaztec.wordpress.com/216/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/deadaztec.wordpress.com/216/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/deadaztec.wordpress.com/216/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=deadaztec.wordpress.com&amp;blog=11275241&amp;post=216&amp;subd=deadaztec&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://deadaztec.wordpress.com/2012/01/30/some-tweaking-before-the-last-straight-line/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://0.gravatar.com/avatar/cbd739d76d2c709385169e8d70676c3a?s=96&amp;amp;d=identicon&amp;amp;r=X" length="" type="" />
		</item>
		<item>
		<title>nil, again :(</title>
		<link>http://deadaztec.wordpress.com/2012/01/30/nil-again/</link>
		<comments>http://deadaztec.wordpress.com/2012/01/30/nil-again/#comments</comments>
		<pubDate>Mon, 30 Jan 2012 17:03:25 +0000</pubDate>
		<dc:creator>Tenoch</dc:creator>
				<category><![CDATA[sool]]></category>

		<guid isPermaLink="false">http://deadaztec.wordpress.com/?p=213</guid>
		<description><![CDATA[What I found most special about Rust is that every variable is always initialized, and no pointer can ever be NULL. In C++ or sool, you allocate an object of a given type, and then fill its members. In Rust, &#8230; <a href="http://deadaztec.wordpress.com/2012/01/30/nil-again/">Continue reading <span>&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=deadaztec.wordpress.com&#38;blog=11275241&#38;post=213&#38;subd=deadaztec&#38;ref=&#38;feed=1" width="1" height="1" /> <a href="http://deadaztec.wordpress.com/2012/01/30/nil-again/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>What I found most special about Rust is that every variable is always<br />
initialized, and no pointer can ever be NULL.</p>
<p>In C++ or sool, you allocate an object of a given type, and then fill<br />
its members. In Rust, the only thing you can do is build an object by<br />
specifying its members, and <em>this</em> determines its type. Then, if you<br />
happened to have named this type earlier and defined methods for it, it<br />
becomes the equivalent of an instance of that class. If you omitted to<br />
give a value to a certain field, the field doesn&#8217;t exist and the record<br />
is of another type, in which you cannot access this particular field.</p>
<p>Of course, in practice, that doesn&#8217;t prevent you to have shortcut<br />
functions that construct the objects by filling in default values, so<br />
it&#8217;s not necessarily less convenient.</p>
<p>What fascinates me is that is suppresses the need for NULL pointer checks<br />
entirely. Remember, when discussing nil, I said it was impossible to do<br />
without because we use it for:</p>
<ul>
<li>variables not yet initialized: in Rust it simply is <em>not</em> possible to<br />
have a variable without initialization</li>
<li>empty a variable (and free its object) before it goes out of scope:<br />
now that I think about it, it&#8217;s garbage collected anyway, so you might<br />
as well wait the end of the block</li>
<li>optional arguments: in Rust you use enum types, like <code>option&lt;T&gt;</code>, and<br />
the <code>alt</code> control statement that branches depending on which subtype is<br />
that particular value. It is very clean, but requires one more control<br />
structure</li>
<li>invalid return values: that is covered by enum types as well</li>
</ul>
<p>This is beautiful. Very logical, very neat and theoretical like a<br />
functional language. Type constructors and type pattern matching. Wow.</p>
<p>Does that mean I want the same in sool? Grumph. No nil-checks sound<br />
<em>really</em> good, implementation-wise. So far in my head, the way to deal<br />
with nil is inserting a test before each method call (and hope for<br />
compiler optimization), or inserting a test on <code>self</code> at the beginning<br />
of each method&#8217;s body. Doable, trivial, but not awesome.</p>
<p>What would the &#8220;all members always initialized&#8221; mean in sool? For<br />
primitive types and struct members, no issue there, I planned on having<br />
default values anyway. The big question is for objects on the heap.</p>
<p>Like I mentioned before (probably when discussing the &#8220;single<br />
ownership&#8221; thing), it&#8217;s OK the pre-allocate sub-objects all the way<br />
down, as long as the whole thing has a tree structure. Obviously, when<br />
there are loops, we&#8217;d have an infinite recursion.</p>
<p>Many pointers are not meant for ownership, but for shortcut reference,<br />
like pointing to parents in a tree, or a network manager that could be<br />
accessed from all over the program. A big program can look like a cloud<br />
of objects, all talking to each other.</p>
<p>Having an automatic allocation in sool would also mean that we force the<br />
distinction between &#8220;owned objects&#8221;, that can be allocated<br />
automatically, and &#8220;simple shortcuts&#8221; to must be pointed at something<br />
existing, at initialization.</p>
<p>Instead of an initializer method in which you can set some fields, and<br />
leave the others be, it would mean that <em>every</em> pointer-like variable<br />
has to be set. Either to a new object, or an existing one. No exception.</p>
<p>What about recursively defined data structures like linked lists or<br />
trees? If we don&#8217;t go all the way of Rust and have enumerated types, we<br />
need new tricks: the last node of a list could point at itself to mean<br />
&#8220;no next one&#8221;.</p>
<p>What about returning nil to mean &#8220;is not in this collection&#8221;? Or &#8220;this<br />
pattern did not match&#8221;? What about object members for which we simply<br />
<em>do not</em> have the info yet? Like in my sool compiler, lots of fields of<br />
the AST nodes are filled in by the analyzer, a lot later than the<br />
creation of the node. Should I, for instance, define a child class that<br />
adds the new fields, and replace the old object by the new one instead<br />
of having lots of members hanging uninitialized so long?</p>
<p>Can members be optional, or only arguments and return values?</p>
<p>Oh, Rust, why do you bring my old questions back? I was never satisfied<br />
by the nil solution I had, but now I&#8217;m afraid to go back to the<br />
&#8220;nullable vs. non-nullable&#8221; type quest.</p>
<h2>Why we really like nil</h2>
<p>Compare</p>
<pre><code>str = "yepee"
if str:find("blah") as where then
    -- use where
end
</code></pre>
<p>to:</p>
<pre><code>std::string str("yepee")
size_t where = std.find("blah")
if(where != std::string::npos) {
    // use where
}
</code></pre>
<p>The principle is exactly the same: if we have a valid result to return,<br />
we return it. If not (and that might happen, we don&#8217;t know), return some<br />
kind of invalid value. What invalid value? -1? <code>std::string::find</code><br />
returns a integer of type <code>size_t</code>, which is unsigned, so it can&#8217;t be<br />
-1. Actually, it <em>is</em> -1 casted to an unsigned, so it becomes the<br />
highest possible integer of the native integer size. So, in this case<br />
the guys who made the STL decided arbitrarily what was the invalid<br />
value. Not only that breaks if you have a veeeeery big string (albeit<br />
unlikely), but also, it&#8217;s so arbitrary that nobody can ever remember,<br />
and the best practice is to compare it to some class member where it is<br />
stored.</p>
<p>Now if you use an std::map, the <code>find</code> method will return an iterator<br />
that points to the result of map::end(). It could be anything else.</p>
<p>In Lua, there is one standard normal way to say &#8220;invalid&#8221;: nil. And nil<br />
happens to evaluate to false in condition statements, which gives very<br />
natural looking idioms. That&#8217;s one of my favorite things in Lua, and I&#8217;m<br />
not ready to give it up.</p>
<p>It works in the other direction as well. In my compiler, when I generate<br />
a diagnostic, I must first give the severity and the message, but then I<br />
can also add a source position, so that the report contains a reminder<br />
of the source code, with the exact position highlighted. &#8220;Would you like<br />
to highlight some source?&#8221; &#8220;Yes&#8221; &#8220;Which one?&#8221; &#8220;Here, have this SourcePos<br />
object&#8221;. Without optional arguments that gives: &#8220;Would you like to<br />
highlight some source?&#8221; &#8220;No thanks&#8221; &#8220;Which one?&#8221; &#8220;Err wut?&#8221;.</p>
<p>Sure, I could have two versions of the method, one with the SourcePos<br />
argument, one without. But then what if I have instead two arguments of<br />
the same type that I would like to be optional? If I make a method with<br />
one less, how do I know which one was omitted?</p>
<p>For sure we can do without optional arguments, but they can also make<br />
life so much easier.</p>
<p>Lastly, I think about the members. Same example, instead of printing<br />
directly a diagnostic, I want to store it in a Diagnostic object, which<br />
will be probably used for statistics and printing later. If I don&#8217;t have<br />
a SourcePos to give, what do I do? Invent an invalid SourcePos that will<br />
not be printed later? That means inventing for each and every kind of<br />
objects a way to mean &#8220;this one is invalid&#8221;. Or we could have a unified<br />
proper mechanism: nil.</p>
<p>Sure, I can think of ways to do without: have the Diagnostic class<br />
contain no SourcePos, and a child class DiagnosticWithSourcePos contain<br />
one, and by magic of dispatching, one would print its source and not the<br />
other. Now suppose I have 10 similar optional members. Should I really<br />
derive 2^10 children classes? I think not.</p>
<p>In my previous example of the Class AST node, in which we add a bunch of<br />
information later, it might be indeed a cleaner design to have a derived<br />
class, because in that case they&#8217;re not really optional, they are just<br />
&#8220;not there yet&#8221;. But once there, they will most likely be <em>all</em> there,<br />
and we can do without nil-checks.</p>
<p>&#8220;Optional&#8221; should really mean optional. Since it does require special<br />
handling, it should be used only when really necessary.</p>
<p>For all the rest (non optional references), we can force initialization.<br />
Period. That&#8217;s a good practice anyway. It will mean that you will have<br />
to gather all the elements before grouping them together in an object.<br />
But once an object is made, it is guarantied to be full.</p>
<p>If you use a custom <code>init</code>, the compiler checks that all members are<br />
initialized. If you use the default <code>init</code> and the <code>with member = val<br />
end</code> construct, the same check goes there. No mercy.</p>
<h2>Syntax</h2>
<p>As I recall, I longly pondered about how to check for presence or<br />
absence of an optional object, and how to cast an optional to a<br />
non-optional.</p>
<p>It&#8217;s not that hard. We can decide that the only way to de-optionalize an<br />
optional is conditional statements:</p>
<ul>
<li>by naming a new local with the <code>as</code> in <code>if</code> and <code>while</code> constructs</li>
<li>by catching the value in a lazy <code>or</code></li>
</ul>
<p>No message can be sent to an optional, it has to be verified first, and<br />
in case it does have a value, this value should be put in a new name.</p>
<pre><code>-- opt is an optional Object

opt.dothing             -- ERROR

if opt as value then    -- value is of type Object
    value.dothing
end

value = opt or Object() -- if opt is non-nil, value gets it,
                        -- otherwise the second branch
</code></pre>
<p>This means the conditional statements can take either:</p>
<ul>
<li>a boolean expression</li>
<li>an optional</li>
</ul>
<p>Nothing else. In case of an optional, the variable in the &#8220;true&#8221; branch<br />
will be casted to a non-optional. Sure, that requires using a new name,<br />
but it makes sense. The fact that you can&#8217;t do anything with an optional<br />
(except casting it into a non optional) mirrors the fact that it would<br />
be unsafe to do so anyway!</p>
<p>nil, or optionals, are also a way to catch errors. And dealing with<br />
errors is important enough that it may require additional typing. For<br />
instance, typecasting may return nil, if the cast (which can serve as a<br />
test as well) failed:</p>
<pre><code>vehicule = Vehicule()
maybe_car = vehicule to Car     -- this returns an optional
if maybe_car as car then
    car.honk
end
</code></pre>
<p>Of course that can advantageously be combined into a single statement:</p>
<pre><code>if vehicle to Car as car then
    -- car is a real Car
else
    -- well, vehicle is not a Car
end
</code></pre>
<p>Same for results that may be nil:</p>
<pre><code>if mytext.match("pattern %w+") as thematch then
    thematch.print
end
</code></pre>
<p>It seems like a lot to type, but in Lua you would <em>have</em> to deal with<br />
nil too anyway, otherwise you risk a runtime error of sending message to<br />
nil:</p>
<pre><code>local thematch = mytext:match("pattern")
thematch:whatever()     -- hey, forgot to deal with the nil case!
                        -- if it didn't match, runtime error!
</code></pre>
<p>The fact that sool forces to use optionals in the <code>if</code> construct and<br />
name a new local for the result is just one step further than Lua where<br />
you don&#8217;t have to, but any good code needs it anyway.</p>
<p>And, well, you don&#8217;t even have to use them right away, you can store<br />
them in a temporary optional. But you will definitely need to rename<br />
them once they&#8217;re casted into a non-optional:</p>
<pre><code>opt1,opt2,opt3 = iReturnThreeOptionals()

if opt1 as a then
    a.yay
end
</code></pre>
<p>Finally, you can use optionals in boolean expressions even if you don&#8217;t<br />
gather their value:</p>
<pre><code>if opt1 and opt2 then
    "haha".print
    -- still can't use the values of opt1 and opt2, even if
    -- logically, we know they're both valid
end
</code></pre>
<p>So, yes, it might make some syntax a wee bit heavier, but in the grand<br />
order of things, it&#8217;s for the greater good. Optionals and nil are<br />
serious matters. In C/C++, dereferencing NULL makes the system shut you<br />
down immediately and without mercy. In Lua, which runs on its own<br />
virtual machine, it&#8217;s caught, but the sentence is the same: immediate<br />
shutdown. And the fact is that since these errors happen at runtime, you<br />
don&#8217;t see them happen until they do, which can depend on input data, and<br />
is therefore more difficult to debug.</p>
<p>If we manage to design a system in which there is no such thing as NULL<br />
pointers, or rather, where the validity is enforced at compile time by<br />
the type system, well, maybe the programming work-flow will get improved.<br />
Be forced to be tidy and organized from the start instead of just<br />
throwing sloppy code and see if it works.</p>
<p>I don&#8217;t know, but it sounds like a good idea.</p>
<h2>Declaration syntax</h2>
<p>The C# syntax of using <code>?</code> seems obvious. A question mark for something<br />
unsure is definitely meaningful, and it&#8217;s one of the few tokens left.<br />
Where to put it is another question:</p>
<pre><code>class Meh
    -- after the type
    num? somenum
    -- after the name
    num somenum?

    -- for return values it doesn't change much
    method text?,blob,blob match(text pattern, blob? start) end
    -- but for arguments it does
    method text?,blob,blob match(text pattern, blob start?) end
end
</code></pre>
<p>One important thing to notice is that it qualifies the variables or the<br />
expressions (which are equivalent internally to temporary variables),<br />
not the values or objects. You can&#8217;t have an allocated object that<br />
contains the information &#8220;I am actually nil&#8221;. The info is in the<br />
variable.</p>
<p>Of course for value types, the distinction is less clear, since the<br />
entire value is contained in the variable itself. But conceptually, the<br />
optional status is part of the variable, not the value.</p>
<p>If also means that you can&#8217;t use optionals as template arguments. Can&#8217;t<br />
have an &#8220;Array of optional numbers&#8221;. And that&#8217;s good, because having a<br />
suffix <code>?</code> in the type declaration would be syntactically annoying. If<br />
you really need containers of optionals, you must box them into a struct<br />
or object. Templates are instantiated using class names, not types.</p>
<p>Attaching the <code>?</code> at the end of the type seems more logical. It mirrors<br />
exactly the type signatures and method signatures (in which the argument<br />
names disappear).</p>
<h2><code>nil</code> keyword</h2>
<p>Finally, we get back the generic and unique keyword <code>nil</code> that works<br />
with every type (provided it&#8217;s optional):</p>
<pre><code>method foo(Object a, Object? b)
    a = nil     -- ERROR, "a" is not optional!
    b = nil     -- fine

    somebool = (b == nil)   -- ERROR, optionals answer to no method!
    somebool = (b is nil)   -- that could be allowed
    somebool = (b is a)     -- that shouldn't hurt either
end
</code></pre>
<p>Since the <code>is</code> operator is meant for testing the references, there is no<br />
dereferencing, only comparison. In theory, the optionals should be<br />
casted back to non-optionals, and only in the success branches could<br />
their value be accessed (and compared). But it still would be safe and<br />
much nicer to replace</p>
<pre><code>method foo(Object obj, Object? opt)
    if opt as obj2 then
        if obj is obj2 then
            -- they are the same
        end
    end
end
</code></pre>
<p>by:</p>
<pre><code>method foo(Object obj, Object? opt)
    if obj is opt then
        -- they are the same
        -- technically, we still can't do anything with opt,
        -- but we know obj is the same, so...
    end
end
</code></pre>
<p>That only implies that the compiler does the glue between the<br />
representation of an optional reference and a real reference. Which<br />
brings us to:</p>
<h2>Implementation</h2>
<p>Soooo, we&#8217;re back to adding a nil value to each variable type. A<br />
consistent and simple way is to stick a boolean to each, and use it to<br />
mark the variable as nil or not.</p>
<p>But of course, we know there are more efficient ways to deal with this.<br />
As long as it&#8217;s hidden in implementation, anything goes. References can<br />
obviously use the address 0 as a nil value. Double precision numbers<br />
have a very big range of unused values (the NaNs), out of which we can<br />
pick one to be nil (we just need to be sure that normal operations won&#8217;t<br />
generate this particular NaN). Booleans are probably going to be bytes,<br />
so plenty of room there. The only sensitive one is the blob (aka opaque,<br />
aka unsigned int), in which every value is normally valid. For this one,<br />
no choice, we have to either reduce its range by one bit (or one value),<br />
or add a boolean to it.</p>
<p>This is mostly detail, except we&#8217;ll have to be careful with it when<br />
writing the foreign function interface. The C API should define clear<br />
functions or macros to produce or compare these values. And as always<br />
with FFI, C functions should be kind enough to return the correct type,<br />
even if there will be built-in dynamic type checking on the sool side:<br />
basically every pointer that comes from C is assumed to be an opaque<br />
blob, and it is dynamically type-casted back to the sool declared type.<br />
You can always fool the system, but that should prevent accidental<br />
mistakes at least.</p>
<h2>Summary</h2>
<ul>
<li>all normal reference types must be initialized during <code>init</code> (either<br />
to a new object, or an existing one). There is no such thing as<br />
assigning <code>nil</code>. That way, we know that all pointers are always<br />
valid, and there is no need for built-int nil-checks.</li>
<li>all variables (and return values) can be declared &#8220;optional&#8221;. In<br />
addition of an actual value/object, we can assign <code>nil</code> to an<br />
optional.</li>
<li>no message can be sent to an optional, ever.</li>
<li>optionals cannot be assigned to non-optionals, ever (explicit<br />
assignment, argument in calls, or return values).</li>
<li>in conditional constructs (if, while, or, and), optionals evaluate<br />
to false if they are nil, and to true if they are not nil. In the<br />
true case, the resulting value can be caught by the <code>as Name</code><br />
construct, or the result of the <code>or</code> operator, and will be of the<br />
equivalent non-optional type.</li>
<li>optionals of reference types can be used with the special <code>is</code><br />
operator, to be compared between them, or with non-optionals, or<br />
with the <code>nil</code> literal.</li>
</ul>
<p>Well, I&#8217;m fairly happy with that new <code>nil</code> system. Hopefully it won&#8217;t<br />
come back to haunt me later.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/deadaztec.wordpress.com/213/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/deadaztec.wordpress.com/213/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/deadaztec.wordpress.com/213/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/deadaztec.wordpress.com/213/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/deadaztec.wordpress.com/213/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/deadaztec.wordpress.com/213/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/deadaztec.wordpress.com/213/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/deadaztec.wordpress.com/213/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/deadaztec.wordpress.com/213/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/deadaztec.wordpress.com/213/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/deadaztec.wordpress.com/213/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/deadaztec.wordpress.com/213/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/deadaztec.wordpress.com/213/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/deadaztec.wordpress.com/213/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=deadaztec.wordpress.com&amp;blog=11275241&amp;post=213&amp;subd=deadaztec&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://deadaztec.wordpress.com/2012/01/30/nil-again/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://0.gravatar.com/avatar/cbd739d76d2c709385169e8d70676c3a?s=96&amp;amp;d=identicon&amp;amp;r=X" length="" type="" />
		</item>
	</channel>
</rss>

