February 24, 2012

How to put twenty clowns in a Volkswagen

Context: here.
public class You {
      private static Volkswagen vw;

      private static final class Popo extends Clown {
            private static int clowns = 0;
            private boolean unpacked = false;

            public Popo() { clowns++; }

            public int hashCode() {
                  if (!unpacked && clowns < 20) {
                        unpacked = true;
                        vw.add(new Popo());
                  return super.hashCode();

      public static void main(String args[]) {
            vw = new Volkswagen();
            vw.add(new Popo());
Yes, I know, this can be made shorter. Don't really care. :-)

February 22, 2012


Maybe you saw it, maybe you didn't, but this last week-end the Humble Bundle Mojam took place. (I'm sorry, I would have said something before the week-end, but I only found out myself on Sunday. Yeah, I'm tuned in to all the cool happenings on the interweb, I am...) In short: you could watch Mojang create a brand new game in only sixty hours. Something like a Ludum Dare, but then done by a whole team and with the proceeds going to charity. Apparantly you could even vote on the theme which, naturally, turned out as a steam-punk Egyptian themed multiplayer shooter.

I didn't get to watch much of the creation itself, but you can check out a previous post of mine on Notch taping his Ludum Dares to get an idea of the process. The difference that a bigger team brings ? Better art and multiplayer goodness, I would say.

Best of all, if you donated something, you not only get to download and play the game, you also got a copy of the final source code! Now that's a big bonus to a software geek like myself. I have only looked at it briefly, but the structure seems very similar to what I have seen Notch code in his Ludum Dares. In particular they are still juggling all the pixels themselves; no real hardware acceleration is used. It's basically writing to a back buffer and then blitting it to screen. Easy. (Right?) :-)

February 20, 2012


The Julia programming language seems really interesting. Julia has a combination of cool features: multimethods, coroutines, macros, meta-programming, generics, distributed computing (with cloud-computing in mind), etc.

She can even call Fortran code. What ever was wrong with Cobol as a target ? :-)

February 06, 2012

Make install: Rasp's game

Rasp is working on a 2D isometric roguelike using Slick, a Java 2D game library. And he's blogging about it. It's still in the early stages, but the graphics look good. His approach to lighting, with colour blending, makes for some nice screenshots. And he shows you how it's done.

Go check it out. And if you know of other programmer blogs please let me know!

February 05, 2012

Being a geek dad...

Is watching my two-and-a-half year old daughter using an iPad like she's never done anything else in her life. Now, to be clear, I didn't buy the iPad for her. I originally bought it for my wife. But it's my daughter who seems to get the most out of it. And it's not just simple games either (Toca Boca games are superb by the way); she starts up and changes apps like it's the most natural thing to do.

My own first encounters with technology were goofing around on an Apple II clone, getting it to print something to the screen. Followed by a Game Boy (the original one) when I was ten or so. My little girl has exponentially more power under her fingertips, and she uses it without thinking twice about it. To me that's just amazing. It shows not only how far computers have come in power, but also in accessability.

It also makes me wonder what she could be doing in another year's time...