DND#1 on a Commodore PET

Just over a year back there was a contest announced on the Shroud of the Avatar site to port Richard Garriott’s first DND game to web browsers. The story is provided in the link but in brief this was the first in a series of unreleased DND games written by Garriott, the final one of which would become Akalabeth and start the Ultima series.

While the code doesn’t exactly mask the fact that this is the high school project of a teenager, the historical significance can’t be denied. I’ve been meaning to have a look at the game for a while and somehow never got around to it. That was until my latest addition to the man cave arrived:-

Commodore Pet

Looking every inch the stereotype of a 70’s computer, the Commodore PET was the first computer I ever used more years ago than I care to admit to. My Dad brought one home from work when I was 5 or 6 and it’s fair to say I was hooked from the start. This was long enough ago that just being able to control things on a screen at all impressed the hell out of most people. It occurs to me that his employer must have been a whole lot more trusting back then to let him borrow it as one of these would have cost near half his years salary as a university lecturer at the time. The PET was still half the price of the Apple II though which does beg the question quite how Richard Garriott was able to afford his half of the price tag as a school kid. At any rate, in the case of my 2001 series model, that 6 months salary would have bought 32K of RAM, a 1 Mhz 6502 processor and a 9 inch 40×25 character based green screen display.

The PET first came out in 1977, the same year as DND#1 and it struck me that in the absence of a PDP-11 it was the perfect platform to port the game on to for an authentic 70’s gaming experience. Also since Commodore BASIC is extremely similar to the one used on the PDP-11 there should be minimal work involved. I took a lazier option still and started from an Applesoft BASIC port by Aaron Lanterman. Both Apple and Commodore BASIC were based on Microsoft BASIC making them almost entirely compatible and limiting the amount of work I had to do.

The changes I made were:-

  • Convert everything to lower case. Despite the PET only having uppercase it needs all the BASIC commands to be lowercase when pasting the code into the WinVICE emulator.
  • Remove most of the spaces from the code. Other than the one after the line number and those in strings, Commodore BASIC ignores spaces and since memory is in extremely short supply they needed to go.
  • Shrunk all the arrays. These all appeared to be unnecessarily large and caused out of memory errors in their original sizes.
  • Hardcoded a dungeon into the code. The original game allowed the user to pick 1 of 6 dungeons which were then loaded from a file. This wasn’t an option for me so I pinched the first dungeon from the winning javascript port at http://www.kirith.com/DND1/pure-js/ and load the data into the dungeon array. You get this dungeon no matter what number you pick.

With all that done, I shoved it on an emulator, saved to a virtual cassette file, converted this to a wav and played it into my PET via one of those headphone -> cassette adaptors that people used to use in car stereos.

DND#1 - 1DND1 - 2 DND#1 - 3

6 and a half minutes of loading later, DND#1 was ready to go. Surprisingly all of this works and the game is indeed playable on the PET, or at least just about playable. The code that is run between player moves, controlling monsters and the like is more than the PET wants to cope with and the game runs at about 1 move a minute. I expect this may not be all that dissimilar to the experience on the PDP-11 and the experience is still less drawn out that playing that Ultima 1 board game. I’m sure this could be optimised but I haven’t looked at that part of the code yet. I kind of prefer to leave it as it is.

Aside from the speed of the game, I could do with putting back a few spaces into the code here and there and there is no saving but I decided it was good enough for my purposes and tried my hand at a few games.The actual game involves moving around a 26×26 dungeon finding gold, falling into pits, searching for secret doors, fighting monsters – most of the usual tropes of dungeon crawling RPG’s back before they became tropes. The map is only partially shown when the player chooses to look and the graphics are simply numbers in a grid with 4 representing a door, 5 a monster, 1 a wall etc.. I kept it simple with a fighter character and combat just involved swinging my sword and hoping to hit. In hindsight a bow and arrow might not have been a bad idea.

My games proved to be quite short (or would have if the thing ran quicker) with my usual end coming when I’d fallen down more pits than my supply of rope and spikes would allow me to climb out of. There isn’t any winning target in the game as such. Gold could be seen as a score of sorts but the player is left to find their own goals.

DND1 is very basic and not all that playable but has to be worth a glance at least for anyone interested in the pre-Ultima dark ages of early video games. It’s not hard to see how this evolved into Akalabeth – convert it to 3D and they really wouldn’t be all that much different. As for playing it on the PET, it’s certainly an oldschool experience if nothing else. A bit of optimisation to get the speed up really wouldn’t hurt – I might take another look at it some time. Any of the modern ports would probably be preferable but for anyone wanting to try this out the code is here, the tape file is here, and the wav file for loading on real hardware is here. These should also work on later 8 bit Commodore machines (VIC-20,C64,C128) since they were all built on the same framework.

The game isn’t all that user friendly. If you do play it, don’t ask for instructions or it kicks you out, make sure your player name is shavs and enter 16 (or any higher number) once you have bought enough equipment at the start to go into the game proper.

Ultima Patcher 1.61

I wasn’t expecting to do another release so soon but GOG recently split all their bundled games into individual downloads which broke MT-32 emulation support. Version 1.61 fixes this + will look for the games in the new default installation locations. It can be downloaded here.

This new version isn’t entirely backwards compatible so I’ve left 1.60 on the downloads page for anyone who wants it.

Ultima Patcher 1.60

I’ve done another small update to the Ultima Patcher and added in the Ultima 4 Party Fix to the Ultima 5 menu of the patcher. This is a small DOS utility used to fix errors when transferring your Ultima 4 party over to Ultima 5. If Ultima 5 reports data errors when transferring, click the “Run Transfer Fix” button on the Ultima 5 screen, select A when asked for a drive letter and your party should then import correctly. This shouldn’t be required in most cases as far as I know but this error does still occur for some people.

The new version can be downloaded here.

ScummVM Hacks 1.7.0

After not updating it for over a year, I’ve put some of my week off work into porting over my “improved” version of ScummVM to the latest release 1.7.0 and have done builds for Windows, Android, Pandora and PSP. Testing all the engines thoroughly is far beyond the amount of time I can dedicate to this but it should be stable enough. All the versions are available from here.

This version of ScummVM was originally developed before MT-32 emulators became usable with a mind to putting the MT-32 and Sound Canvas soundtracks into the games by recording them from the original hardware and playing them back during the game. These days, it’s not so much use on Windows since MT-32 emulation is near perfect and as such I’m not actively developing it. It still offers a big improvement to sound quality on less powerful hardware though and I’d definitely recommend it for Android/Pandora/PSP users who want something better than Adlib audio. It’s not pretty but the source code is available to download for anyone who wants to try this on other devices.

Ultima Underworld – PS1

As I write this, the Underworld Ascendant kickstarter is about to go into its last 3 days and hopefully a late rush towards some more of those stretch goals. I’m obviously excited to a see a sequel to a game that I’ve frequently described as my favourite of all time and it really deserves a bit more cash than it’s brought in so far. If you agree, please head over and pledge a few dollars towards the cause.

I thought I should do something Underworldy and decided to have a look at the PS1 port of the game that was released back in 1997.

20150302_094526

Despite being critically acclaimed, Underworld wasn’t a game that received many ports and the only one released outside of Asia was a Windows Mobile release for Pocket PC’s of all things. A Sega CD version was announced at one point but it never made it to release. This means I’m stuck playing in a foreign language on the PS1 which is why I’ve never played it prior to this.

20150302_082341 20150302_082421 20150302_082437 20150302_082448 20150302_082506 20150302_082546 20150302_082728 20150302_082730 20150302_082806

The introduction is now in FMV with newly drawn art and voicing. This is a shot for shot reproduction of the original and I really quite liked it. The acting sounds far more convincing in Japanese than it ever did in English but I’m hardly the person to judge when I don’t understand a word of it. I really like the way this has been handled but I may have been less impressed if I was coming to this as a new player – you could do a whole lot more with FMV after all.

20150302_085016

I struggle my way through character generation with Google translate not having an easy time picking up characters off the screen. All the usual options are there including an easy mode which I select under the circumstances. There are some new portraits for the Avatar, many of which look a little effeminate if you ask me. My first thought was that I’d chosen the wrong gender until I spotted a moustache on one of them.

20150302_085740 20150302_085857

Having struggled through character generation, I immediately set out to save my game so I don’t have to go through it all again. There appears to be only one slot available which could be a handicap if so. My main concern would be the speed of saving which must clock in at 30 seconds plus. You definitely wouldn’t want to overuse this feature and I expect saving and loading would be potentially tiresome later in the game.

The abyss is instantly familiar at least and most importantly full screen. The PC original had an extremely small viewing window due to the hardware limitations of the time. Flash forward 5 years and the PS1 has basic 3D acceleration to take advantage of and it certainly improves things. I’d be lying if I said that the most has been made of the hardware. The same textures have been used as far as I can see and it’s not a whole lot better looking. The PS1 wasn’t exactly a 3D powerhouse but it could do more than this – this may be a prime reason why this port never made it out of Japan.

20150302_085918

The interface is reasonably straightforward, especially considering I’m working without a manual I can understand. There are no analog controls so instead the d-pad is used with buttons to run and jump. The inventory is node based and I found it quick enough to move items around once I got the hang of it. Whilst in first person mode, holding down one of the shoulder buttons brings up a pointer allowing items to be examined or picked up. A big time saver introduced in the PS1 port is automatic key use which should save players from a lot of fumbling around in their inventory.

Considering how much the original was designed for mouse use, UW’s controls made quite a smooth transition to console. I expect the average modern gamer would have less grief on the PS1 than trying to cope with the odd mouse control system used on the PC.

20150302_090312 20150302_090439 20150302_090535

The biggest difference to the environment is that all the sprite models of the original game have been replaced by all-new 3D ones. Some of the original UW sprites were pretty appalling (e.g. the bat that looked to be about a dozen pixels) but these were much improved in the sequel. Time hasn’t been entirely kind to most 3D modelling of the mid 90’s and these new models do look basic and cartoonish. They don’t move around the world smoothly either and give the impression of being pre-rendered in which case I’d far rather they had skipped the 3D modelling part and just redrawn everything the old-fashioned way. Most of them don’t look too bad – the giant rats are kind of cute, looking more like giant mice. The rotworm is possibly the worst and looks more like something left behind by one of the giant rats.

20150302_090459

The conversation system isn’t something I explored at any length for obvious reasons. The character portraits are tweaked but other than that I would guess that the conversations have been faithfully reproduced as there didn’t appear to be any reduction in options.

20150302_090930 20150302_091651 20150302_091924 20150302_094127 20150302_092922

I set out to explore the first level in full and have to say that I liked what I saw of the game. It moves fluidly and everything is exactly as I would expect it to be. In fact I didn’t spot any aspect of the game that played differently to the PC. The audio has been redone sympathetically on more modern synths with some digitized samples added in. With the full screen graphics, it arguably enhances the atmosphere of the original.

Combat still has the three varieties of swing except these are each mapped to different buttons when the weapon is drawn. I soon found myself using the familiar hit and run tactics and the different control scheme was proving no handicap. In fact, I think it was an improvement over mouse and keyboard.

20150302_094144 20150302_094147 20150302_094151 20150302_094153

I got as far as half way through the second level where I succumbed to a headless while trying to figure out how to fly up and down. I never did figure this out but assume it must be possible. This did mean I got to see an all new FMV where the player regenerates thanks to the silver sapling back on level 1.

I had a great time re-exploring the familiar locations in this new format. I’d heard quite negative opinions on this port prior to trying it but what I’ve seen played fine as far as I’m concerned. I’d be surprised if there was a better first person RPG on the system – this is still every inch Ultima Underworld after all. It’s so faithful a port, you could argue it’s more one for fans of the original game – while the graphics and audio have been given a gentle facelift it may have been technically underwhelming at the time. The open gameplay and foreboding atmosphere is still there though and I would dearly like to have seen an English language release of this.

I’m probably going to press on a little further before I give in but doubt I will make it too much further. There are enough quests requiring conversation that I expect to come to a grinding halt with the language barrier sooner or later. In the meanwhile, there is a full speedrun on Youtube courtesy of dandandan5 which I’ll link to below:-