Small Ring engine update

  • Most images are no longer drawn at wrong coordinates (for example the dialog boxes or some screen elements in the preferences)
  • The first line of images is now being drawn properly (fixing corruption that appeared in some cases)
  • Some 32bpp images are now shown properly (it converts them from 32bpp to 16bpp on the fly until we get full support for 32bpp screen surfaces), but with graphics problems when the game is expecting alpha transparency
  • Image cursors are shown with the correct coordinates/colors (downsampling from 32bpp to 16bpp here too)
  • Highlights now work on menu entries and dialog options
  • AND the decompression problem has been fixed (by a single line change…) !

Ring engine status update (September 2011)

Since the first commit at the end of January 2011, the ring engine has come a long way. Most of the shared engine code for Ring and Faust has been implemented, along with the whole logic for Ring and a sizable chunk of logic for Faust.

The main game view (the 360° view) is not yet implemented, but there is enough display code present to show the game menu in Ring (as well as several submenus). As you can see in the screenshot, there is some image corruption present, due to problems with the image decompression.

And that brings us to the compression algorithms used by the engine: one thing is clear, the original developers loved coming up with new compression types (I’m thinking there was a bet on how many such algorithms they could fit in a single engine). BMP, TGA, WAV (compressed as a whole or streamed), CNM (movies), AQC (360° view data) each use a different variation of the algorithm (with a large amount of duplicated code of course of course, it wouldn’t be fun otherwise!).

And for the next games in the series, they decided to share a single compression format for all images in archives. So in addition to the old compression formats from Ring, Faust introduces a new format, also used for movies…

The new compression code also uses floating point, which makes it quite a bit harder to reverse-engineer. And since most images are inside archives, Faust and the following games are not displaying anything yet.

I’m currently working on implementing the new set of “widgets” used by Pompei and Jerusalem. It includes a dialog selection widget (mostly done) and a hyperlinked encyclopedia (only started reverse-engineering in IDA).