Playing Warhawk (C64)

I’ve been playing Warhawk quite a bit recently whilst testing various recording settings for YouTube, so it’d be churlish of me to not actually talk about the game itself! And it’s another budget shooter that I’ve got some nostalgia for, including a few shockingly vague memories of being at what I believe was a PCW show in London and seeing it running for the first time on Firebird’s stand; trying to play a fast-paced game in the middle of a raucous exhibition hall was never going to work and my arse was duly handed to me, but I was sold and picked up a copy as soon as my local software emporium had it in stock.

The obvious influence is Tehkan’s 1984 classic coin-op Star Force to the point where a couple of escaped preview versions exist (included in the Gamebase 64 archive, one under the development title of Proteus) which have similar end of level guardians; these disappeared for the actual release to be replaced by a final screen on each stage where the player is pelted with enemies which home in on them. Actually, here’s a handy hint for that part of the game whilst I’m here; park the ship over the second digit of the score from the left, hold completely still and just hammer the fire button – you’ll take a few hits doing this depending on how fast the enemies are moving, but it’s safer than trying to dodge, weave and blast.

The pace increases with each stage of the ten included and some of the enemies get more vicious in the process, but there are gaps in the madness since a new wave can’t start until the bullets for the previous one have left the playfield and players can “herd” enemy bullets to maximise that quiet time with a little practice. Because it gets so manic this isn’t a “one hit kills” kind of shooter and there is what at least initially appears to be a generous energy gauge which decreases a little with each hit. There’s also a power-up that starts appearing at level 4 which speeds the ship up a bit, gives it a faster firing rate and removes the need to constantly stab at the fire button, but this enhancement is only temporary and care must be taken to avoid shooting the items.

Warhawk‘s sprites are very nice – the titular craft in particular really looks the part – but, whilst the background graphics are reasonable, they did look somewhat dated even when the game was released in 1986. The Rob Hubbard soundtrack, on the other hand, still holds it’s own well is is certainly worth several listens; that’s best done on the titles page, it gets “remixed” during play since the lead channel constantly drops out to make room for firing and explosion sound effects. It might be an unintentional effect but having just the bassline driving away behind the frantic action works well especially when things really heat up.

Firebird published some very solid budget shooters for the C64 – and a few howlers like Force One, more on that another time perhaps – and this is a great example that starts off sedately but builts to a crescendo by the time the tenth level is conquered to the point where going back to start a new game almost feels like you’re playing in slow motion. And for those players who manage to loop Warhawk there’s always the challenge of playing for score to keep them going, the remaining shield is translated into points at the end of eac h stage and destroying all of the bases will earn an extra bonus.

Workprint – March 2018

So let’s get some workprint business out of the way first; since there are now two people showing an interest in converting Vallation to other platforms I might just have to properly shuffle it to the front burner and get on with building the new levels so they actually have a full game to convert. This process will doubtless involve lots of expletives – all aimed at myself for taking shortcuts or bodging – and possibly some rewriting or at least refactoring of the code because it seems to take far more processing time than I remember.

The RLE-based background compression I was mumbling about in the last update is also implemented and works surprisingly well, in fact there’s a simple but functionally complete game wrapped around it now. It has over 56K of background data in there which has been compressed into a mere 23.1K and takes around six minutes to scroll through at one pixel a frame. My intention is to get the entire game done rather than doing a “development diary” so I know it’s finished when writing the C64CD blog posts.

I’ve done a few more tests as regards grabbing video footage, again using VICE and OBS to this time accidentally record a full ten level playthrough of Warhawk. The results look quite solid, but there’s a bit more fiddling with settings I want to do and I have Vegas Pro courtesy of the Humble Bundle to install and get my head around… so who knows, perhaps I’ll become a rich and famous YouTuber? Well okay, probably just a YouTuber but I’m only doing it for the groupies anyway.

In other news, whilst I was away in Kent I met up with fellow Cosine inmates Darren Nevell , Frank Gasking and Sean Connolly for the twice-yearly internal meeting; that makes things sound all official and stuff, but we basically take up a corner of Starbucks and natter for the best part of a day. After nursing a coffee each for a couple of hours we then piled into Level Up and spent a happy hour or so trying to persuade ourselves not to buy everything in sight! Amongst other things I ended up with a PSU for one of my spare Atari 800XLs, a collection of books which are destined for the racking going into my office once it’s decorated including one about BASIC for the Dragon 32, an unboxed freebie of A64 – a C64 emulator for the Amiga which has a dongle for connecting peripherals – and… well, this thing:

Despite looking like an adolescent Enigma machine it’s actually a joystick interface for the Spectrum where each direction and the fire buttons can be connected to keys so pushing left on the stick is, as far as the computer is concerned, someone holding down the O key. I absolutely adore the bizarre but functional nature of this thing; it’s such a perverse work-around for the problem but at the same time will literally work on anything that doesn’t require actual typing to play. Come to think of it, you could also “type” rude words with the joystick…

Workprint – February 2018

There hasn’t been much time for coding since the start of the new year, apart from spending a while prodding around a little at Vallation, mostly because another member of Cosine is considering a port and I’d forgotten how some of the level data was organised!

Previously I have pondered about coding something under the C64CD label as a practical demonstration of what processes are actually involved when writing a game; as already noted, my first thought is always “let’s do a scrolling shoot ’em up” but the idea of a tile-based version of Co-Axis didn’t really feel right so the project was pushed to the back burner until a recent Facebook post from Karolj Nadj about writing his first Run Length Encoding routine set me thinking; I’ve already got one of those, so could the scrolling background for a game be compressed that way rather than using tiles?

Run length encoding works by tokenising clusters of the same byte, so if there are twelve $64s in a row in the data they’re reduced down to three bytes which are a copy of the byte itself, a flag of some kind to say it’s going to be repeated and the number of times it should repeat; something like the gaps between landscape details on a scrolling background for example can be compressed quite a bit. With that in mind, out came my four year BlitzMax RLE compression code and the messy, self-modifying 6502-flavoured unpacker for a few tests and, after throwing some test data together and adding a couple of loops to convert the incoming map data to columns rather than rows, it seems to be reducing to around a third of its previous length which is sufficient for what I have in mind.

These early trials also found a bug within the RLE compressor code; because the length is a byte and can’t be higher than $FE there’s a sanity check in the code which stops the currently encoding run when it hits that value and forces a new one to start… all very sensible if I hadn’t forgotten to properly finish that first run in the data before moving on. Instead it only wrote the byte and a trigger for the run but no length value, meaning the 6502 end would pick up the next byte and use that instead, completely mangling the data in the process. This went undetected because the only practical use my RLE code had been put to previously was compressing streams of AY register changes for my prototype Apple II Mockingboard music driver where the data there changes too often for the bug to appear.