Game for Master System

1.25 Feb (20KB)

Discuss this

There is a forum topic for Donkey

Old Versions

file namesize (bytes)
total 2 files40K 20K 20K



I decided to make a game similar to DONKEY.BAS. This allowed me to have a scrolling background, to play with the color palette, to use sprites, etc. I even hit a few limitations, such as the maximum number of simultaneous sprites on a line, which forced some changes to the game logic and layout. Exactly what I hoped: There were a few obstacles, but nothing too difficult.

Conclusion: I have a complete game with 3 modes, some music, a demo mode and scores saved in the cartridge flash. I also think that my version is more fun than the original, but feel free to disagree. But what matters most is that I can distribute it freely, since it is my own game.


The original (DONKEY.BAS) is a PC game played with a keyboard using the SPACE key to switch lane. Initially I did the equivalent using SMS button 1.

But later, when I added the 3-lane mode, this was no longer appropriate: Which lane should the car move to? So I switched to using the D-Pad.

After playing and testing the game many times, the game started to feel too slow. So I converted Button 1 into an accelerator. Pressing it temporarily doubles the speed. So in the final version, the buttons are:

D-Pad left/right: Switch between lanes Button 1: Speed boost

The game supports the Sega HPD-200 "Paddle Control" and my homemade paddle. When playing with a Paddle, the car position can be finely controlled by rotating the knob. The car is not longer always centered on a lane. This gave me the idea of creating a "laneless" mode, where even the obstacles are no longer centered on lanes.

The car instantly reacts to any rotation of the paddle knob. Playing the game with a Paddle and a CRT without lag is a pleasure, and it the game even feels easier! A paddle is the controller of choice for this game!


The first level reproduces the color theme from the original, DONKEY.BAS. But as soon as the second level, the SMS color capabilities are better used. The color them changes a few times during the game. In the night theme, I use the horizontal interrupt to darken the color palette mid-frame, to make it look the car headlights (hmm.. or rather, lights mounted on the rear part of the roof) are lighting up the way. (Yeah... not so good, but I really wanted to do something with the horizontal interrupt and that's what I came up with).

The game is coded to use the Flash memory (if detected) or normal battery-backed SRAM to save scores, as well as the availability of the two extra modes to unlock. For instance, scoring above 100 unlocks the 3-lane mode. In this new mode, the game is also faster right from the start. Beating level 16 unlocks the laneless mode, where the car and the obstacles can be anywhere instead of being lane-centered. Playing this with a controller is quite a challenge. A Paddle is almost required here!


This game is inspired by (or is a remake of) DONKEY.BAS which came with the first MS-DOS versions. It appears that Bill Gates himself was one of the programmers!

My aim was not to create a perfectly identical game, and in fact, I did not even replay DONKEY.BAS before coding my SMS game. My "design document" was a screenshot, the game description on Wikipedia, and my memory of playing it about 25 years ago.

In my version, instead of only moving up the car when obstacle is avoided, I also increase the speed and add more simultaneous obstacles to avoid (up to 3 at a time in some areas).

In an attempt to make the game more interesting, I also added new concepts such as such as the 3-lane and laneless modes. Of course, with the SMS graphics hardware, making the game more colorful and smooth-scrolling was easy.


Making this SMS game relatively easy, thanks to the existence of many tools without which I would have had a lot more work to do!

devkitSMS (SMSlib et PSGlib): png2tile (PNG to SMS graphics conversion): DefleMask tracker: sdcc (Small Device C Compiler), a C compiler supporting the Z80:

A big thanks to the authors of the above!


See also Donkey-GG.

Return to top