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).

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);