Bad, vile and meaningless: Andy Bones and Atlantis from Alan's clob

Indiana Jones and the Fate of the Atlantis

I recently acquired some ADF and HDF files. For the uninitiated, these are Amiga floppy disk and hard disk images, suitable for feeding into emulator such as E-UAE (the Enhanced/Extended/Excentric/Endorphinic Unusable/Unix Amiga Emulator). Despite the confusion over the name, this is solid piece of software with some minor caveats.

First of all, the GUI has no (at version 0.8.27) support for the .HDF format. The theory is that since Linux comes with AFFS support, you are supposed to be able to convert those .ADF/.HDF files to readable filesystems with command like:

mount the-harddisk-file.hdf /mnt/amiga -o loop -t affs

but sadly, at kernel version 2.6, we have lost usable AFFS support. (I have a bug reported against Ubuntu bugzilla, but the bug is most likely in mainline. The oops happens on 2.6.8 too, but I haven't tested further back.)

So, with that avenue out of the way, and with some very interesting games that I wanted to play again (such as Secret of the Monkey Island) I was motivated. First try was with readdisk. However, this tiny C program can only read ADF files, it has hardcoded values for disk image maximum size and root sector position etc. All that which means that it crashes as soon as you give it something larger than 900 kB, and even if you increase the buffer size it won't work because the root sector's not where it looks for it.

I was not in the mood for hacking C. I wrote this instead. My version of readdisk is probably pretty lame, but at least it was able to read some 20 HDF files and pour out its contents on the filesystem without a glitch. As an added bonus it does something readdisk doesn't even dream of: it also handles AmigaOS permissions. (Okay, "handle" is sophisticated word for the crude mapping it does, but at least it marks executable files as executables!)

Hey! Where did the last 48 hours go!?

So I spent the whole weekend staring at the emulator at low resolution. I completed Monkey Island 1, and the Fate of the Atlantis. I tried out bunch of other games too: Worms (Directory's Cut), Monkey Island 2, Frontier, Settlers 1, Virus, Cannon Fodder, and some others I've forgotten by now.

It's a bit painful to run the emulator. Not all games can handle AGA chipset emulation, so sometimes you have to choose OCS or ECS chipset before starting the game. Sometimes you have to switch from Kickstart ROM 3.1 to 2.0 or 1.3. Then there's the CPUs, FPUs, emulation levels and whatnot to choose from.

In general, Amiga is not like the C64. Everybody had the same machine back then, it was 100% monoculture, nearly, until people started having C-128s and C-64C:s. Anyway, it was not like that on Amiga, despite A500 was the most popular computer, A1200, A3000, A4000, and so on weren't unheard of. The AGA chipset was not fully backwards compatible (in Microsoft sense) with the earlier, and the CPUs weren't backwards compatible either, but to a degree. Many performance tricks that Amiga programmers were used to could cause trouble when you were running with CPU that had caches or delayed writes or could outrun the Agnus Blitter.

I think the next step is making some kind of database or packaging correct .uaerc settings with the .ADF files in order to make fiddling with the configs less painful. There's clearly some kind of need for knowledge database that tells the "capabilities" of the game, that handle the whole painful setup out of the way. (Actually .ADF needs a bit of metadata to store this and emulators need to read this data off .ADF. Pity that the file format has no metadata slots of any kind. We'd have to shoehorn this data somewhere on the filesystem itself, possibly at root block or something...)

The emulator is also painful because the floppy loading times are accurate. It's not like ViCE where you can speed the whole machine up some 10-fold and have it load games in seconds instead of minutes. The floppy emulation is slow even after you make the CPU burn like turbocharged A4000. Luckily the harddisk emulation is very fast, in relative terms, so .HDF games are quite enjoyable. For instance, it takes about 2 seconds to fully boot AmigaOS from cold boot with the maximum options. :-)

E-UAE is surprisingly usable. Probably most games can be made to work with some insight with how Amiga was put together (or just plain random shotgun option twiddling). The trouble comes from losing those useful settings and having to rediscover them next time you want to play some of those cool games again. That must be remedied, if Amiga emulation is to reach the plateau where each new day becomes shorter than the one before.