Here are the Worm Warrior sources:

Sunplus MP8000 – This contains a slightly modified version of libgame, and should compile cleanly with the SPMP8k development kit downloaded from the internet. The archive also contains LodePNG and Game STL (gstl). I had to use the Game STL since pushing a value into a std::vector would freeze on the second push. It contains the source for two unused libraries, FastLZ and FastXml. The code can also be compiled for Windows using Visual Studio 2010 Express edition or higher and SDL 1.2.15 extracted into a  SDL-1.2.15 subdirectory.

Game Gadget and MotoMagx – This contains the same stuff as the Sunplus version in addition to the Hekkus Sound System compiled for each platform, using SDL sound. I am unable to distribute the source code to my SDL port, as it is typically distributed by the author. The Game Gadget version can be compiled with either the Game Gadget toolchain under Ubuntu or the Dingux toolchain under Windows. The MotoMagx version can be compiled with the MotoMagx toolchain under Ubuntu or andLinux/coLinux (on Windows).

Didj – This contains the source, minus the Hekkus Sound System, FastLZ, and FastXml sources. The Didj version can be compiled with the Windows Didj toolchain. There are linux toolchains located here (I would link to the blog posts, but the links are wrong).

The Didj version of Worm Warrior is playable. Download it here. Installation instructions are included in the file. This will work correctly on a normal Didj.

Sound isn’t implemented yet, but everything else works fine. I need to see if it would be possible to get Hekkus Sound System running on the Didj,

This is using the SDL_RenderCopy, from a texture, for the display, and Linux input events for input. By specifying the rects to SDL_RenderCopy and SDL_LockTexture I was able to speed things up to a playable level.

A big thanks goes out to Ramblings and Broken Code for the Didj OpenGL demos.

It’s been a challenge to get Worm Warrior running on a normal Didj. The Didj is an excellent platform for retro style games. It offers a 320 x 240 16 bit color screen with NES/GBA style inputs. And, a Didj can often be found cheaply at thrift stores or on EBay. I payed $4 for mine, without a power supply or USB cable, at a local Goodwill thrift store.


I am currently in the process of porting my Worm Warrior game to the Didj:

Worm Warrior screenshot

Worm Warrior for the Game Gadget

Once it’s finished it will run on an unmodified Didj.

I had to change from SDL 1.2 to an early version of SDL 1.3 to get it to start up on the Didj. It was probably linking to a missing SDL library on the Didj, I still have to fix the input and hook up the Hekkus Sound System (HSS). I developed a SDL 1.2 backend for HSS, which I hope will work with 1.3, and that the Didj SDL_Audio is hooked up.

Developing on an unmodified Didj is a bit of a challenge, since there is no serial port to display debug messages. I got around that by creating a log file at /Didj/Data. The log file will survive a reboot; which the Didj does when exiting a program.

Here’s a little code dump from my logging routine:

bool	g_bCreated;
void logString(const char* _szFormat, ...)
    va_list sArgs;
    char szString[256];
    va_start(sArgs, _szFormat);
    vsprintf(szString, _szFormat, sArgs);
    FILE* pHandle = NULL;
    if (false == g_bCreated)
        g_bCreated = true;
        pHandle = fopen("/Didj/Data/Log.txt", "w");
        pHandle = fopen("/Didj/Data/Log.txt", "a");
    if (pHandle != NULL)
        fprintf(pHandle, "%s\n", szString);