Wednesday, 26 August 2015

Made some time at lunch today to work on the new port again.

Added some more structure to the graphics data and commented the basic text display routines, allowing me to decode the font data which I subsequently rendered on the PC. I continued attempting to decode the graphics and managed to render the raw sprite data and had partial success rendering compound objects (made from multiple sprite blocks).

The game font in technicolour glory!
Here is where the format documentation on the net is somewhat lacking (and in some cases, actually not quite right) as I am yet to understand exactly how compound objects are put together. I made some basic assumptions and roughly half the objects look OK. I was hoping to be able to render a game screen in its entirety, but I'll have to defer any further progress on that front until I reverse-engineer the sprite/object rendering code.

What I've seen of the code doesn't bode well for portability to another CPU, however. The Z80 alternate register set, IX & IY, and self-modifying code are all used throughout the game. Preserving colour information is also going to be a task in itself. That said, I may need to take a different approach to my other ports, and rather than attempt a line-by-line translation, perhaps a routine-by-routine translation would be a better approach.

Oh well, if it was easy, every man and his dog would be doing it!

No comments:

Post a Comment