NubNub : From Concept to Game


If you have a Pandora and follow the repo news actively you must have noticed that _wb_ (of Pandora Microbes fame) has recently released his new game called Pandora NubNub! A very simple game at its core, but nonetheless very enjoyable and challenging at the same time, with Compo4All support to spice it up. Let’s have a deeper look at this and how it first came to be.

In NubNub, as the game suggests, you control some kind of wired thing with the two analog nubs from the Pandora, each one indicating the direction of each extremity. Your goal is to grow, and to do that you must absorb the yellow or green balls appearing on the screen while avoiding the balls marked with a death sign. It couldn’t be more simple, really. You didn’t get it? You need a video.


But it’s very well done and plays perfectly. As you grow you tend to have more “gravity” power, therefore attracting the yellow balls even more without moving… but you tend to take more space on screen, making you more prone to touching the evil death balls. _wb_’s early concept idea apparently originated from Super Geometry Dust.

When I first saw Super Geometry Dust, I immediately liked the fact that it makes good use of both nubs. There are not that many other games that use both nubs. So I wanted to make something specifically for two nubs. My original idea was to make a kind of space shooter with two ships that could optionally link together with a rope/chain between them. I was experimenting with this idea and started coding the game mechanics, using simple circle shapes as stubs for the space ship graphics. At some point I decided to just keep the simple graphics and I never started coding the shooting stuff because it seemed to be fun enough already without having to shoot anything.

If you wonder how long it takes to write a game like that, well…

Yes, it was written completely on the Pandora, using the Pandora keyboard and the Pandora screen. I started coding at the end of April, during a one-week holiday (most of my time on that holiday was spent reading a few books on the beach, but in the evenings I couldn’t resist writing some code). The basic game was finished in that week. In the next few weeks I polished the game and added things like music, sound effects, the menu, and so on. This was done mostly on the train on my daily commute to and from work.

While we guys waste our time everyday in transportation, _wb_ makes games. That’s life. Learn how to program instead of sending messages to your fake Facebook friends, dammit!

NubNub is a great game. But it’s hard to describe like that.

It doesn’t look very impressive, the concept is dead simple, yet it’s addictive. Honestly, there are several factors that make you come back.

One is… getting the highest score. As I mentioned, it supports the Compo4all protocol, therefore all Pandora owners playing this game while online can compete at the same time for the high score and see their ranking right after playing (check the Tournament Hub launcher, by the way, if you haven’t yet!). If it wasn’t for that, I would not have played NubNub more than a couple of times, but when you bring competition in, it’s a different story altogether. _wb_ holds the best score so far, and he told me he did NOT cheat to get it, which I find hard to believe, but I’ll trust him on that. He just had more time to practice!

The second thing that makes me come back is… the music. Basically _wb_ had the excellent idea to just fish out mods from the glorious Amiga past, and you end with excellent tunes from the demo scene, matching perfectly with the game visuals and atmosphere. That’s what I call excellence in execution. I liked the music in Microbes too, but somehow they didn’t really match well with the game. Here, it’s just perfect.

The mods are all by Jester of Sanity, the famous Amiga demo group. I found the mods on the mod archive. The level 1-9 music is “Stardust memories” from the “World of Commodore 1992” demo. Other tracks include “Elysium” (from the 1991 demo with the same name),  “Molecule’s revenge”, “Wirehead”, “Dazzler”, “The nukha bopper”, “Cyberride”, and several more. The menu background music is “Crack the eggshell!” from the 1993 Sanity demo “BoggleDop”.

Not only the soundtrack is great, but for me it’s Nostalgia all over again since I lived through that time and saw “World of Commodore 1992” when it came out, and I was a big fan of Sanity ever since. Here’s a youtube video for you guys who missed it. (I highly recommend you also check Arte, their last ECS demo on Amiga 500 – “So just straight off the tricycle”. A miraculous demo with a very memorable soundtrack).


Now, back to the development of the game. We’ll probably come back in more tutorials down the road on how to best use the Pandora for game creation, but you can guess that an efficient language is required to reach this kind of FPS on screen.

I used C++ and SDL. Adding music and sound effects is really easy with SDL_mixer. I also reused some code from Microbes, so that saved some time. I took advantage of notaz’ SDL and in particular his NEON blitters and his NEON speedups to SDL_gfx. The game is not very demanding because of the simple graphics, but you still have to take care not to do stuff in a stupid way. For example, I take care to not re-render text in each frame (I cache the text surfaces until the text changes. E.g. the score counter is not rendered in each frame, but only in those frames where your score actually changes). Also there is some very unoptimized code in SDL_gfx, so I changed some of that. There is still room for further improvement (e.g. better cache behavior), but I’m probably not going to bother with that if it’s not needed. I didn’t have to compromise anything.

By the way, I was wondering how to play mod music files on Pandora, and whether a specific library was needed, but _wb_ was kind enough to point out that SLD_mixer already takes care of mod support internally. That’s cool, and if you ever make games for the Pandora I strongly suggest you pick up mods from the demo scene instead of making crappy music on your own (if you have no skills at that).

So far the game has been pretty stable and while the first version caused a couple of crashes in-game on my Pandora, the new releases fixed everything as far as I know. But _wb_ is careful and does not pretend it cannot crash anymore, so if you ever get a crash, don’t stay silent and sulk, but report it !

If you get a crash, the best thing to do is report it in the release thread or in a private message to me. I need the /tmp/pndrun_nubnub.out (make sure you make a copy of that file before you start the game again), and if you have a non-standard setup (e.g. not the most recent firmware), it helps to tell me about it.

So, that’s about it for this time. There’s nothing much new to say at this point, except that you better train at this game if you want to beat my own score ! (I managed to get 900 000+ and obviously I have a method to reach that kind of score, and I’m not telling!). You may expect a new game from _wb_ next time he has time on the train I guess. But not so soon:

Not plans at the moment. But I’m open to suggestions! I’m mostly interested in simple yet original games, with the focus on gameplay and not on graphics.

So, don’t hesitate to contact _wb_ if you have great new ideas that he may be interested to work on. You never know, he may be receptive and willing to consider them.


Leave a Reply

1 Comment threads
0 Thread replies
Most reacted comment
Hottest comment thread
1 Comment authors
Sebastián Castro Recent comment authors
newest oldest most voted
Notify of
Sebastián Castro

This is very addictive stuff. Congratulations to _wb_ for the great design.

Although I could say that the graphics need more work, I just love them how they are, because they remind me the original Tron and many games of that era I didn’t grew up with just because we were poorer than now.

(May I suggest something? Just because this is a Pandora dedicated blog… To put the links to the embedded YouTube videos right before or after them, so that we don’t need to switch to “fat-@$$” Firefox to watch them)