Thursday 15 October 2009

Awakener Update

Armed with the new ability to extract room information, the progress has been faster than I'd expected. The AGS plugin enables me to pull out everything I need, including the mask information for hotspots, walkbehinds, regions and walkable areas.

The first two have slotted nicely into XAGE with a few minor changes. AGS Hotspots convert over as XAGE room objects, albeit ones with a single, invisible anim frame. AGS Walkbehinds convert as XAGE room objects that are unselectable, static objects with a fixed zPosition as the baseline (The zPos has been reinstated - making the The Fourth Wall confirmed that there are some occasions where you just need to override an object's yPos for the drawing order). Also, standard AGS room objects now convert in a straightforward manner.

AGS Regions and walkable areas are trickier. As XAGE uses geometric walkboxes for character movement, there is no easy way to automatically convert one to the other. I may attempt to tackle this algorithmically, but chances are it will turn into an overcomplicated mess. Another solution may be to store the walkable areas as a single mask and overlay this over the room background within the XAGE Editor, in order to aid the user in manually recreating the walkboxes as quickly as possible (taking about ten minutes or so per room, not including testing).

A third option would be to offer a parallel room traversal system that involves a mask (or to drop the geometric walkboxes completely). It would be quite a lot of work and it would make the conversions more complete, however I'm concerned about unwittingly turning XAGE into AGS-lite, or an unofficial port, and thus want to preserve its position as a legitimate, stand-alone engine.

Working on the conversion is now my main priority, so I'm adding new functionality to help recreate the exact look and feel of the original. Such improvements include a new option over how the cursor highlights characters and room objects. Previously everything was wrapped up in a bounding box, similar to how the original SCUMM games operated. Now each item can have a manual or dynamic bounding box, or a per-pixel detection. The latter option is in keeping with AGS.

Besides a few things (fonts, cursor and some GUI stuff), Awakener running in XAGE is now visually a pixel-perfect recreation of the original AGS version:

Awakener Comparison

I should stress the word visually, as there remains a whole lot of work to do on converting the scripts.

EDIT: The script conversion now counts all unhandled lines of AGS code. Now that I've added this metric it's possible to gauge the progress being made at a glance. The number of script errors that occur when converting Awakener currently numbers 294. It is likely to be a few weeks/months before the number starts to get anywhere near zero.

1 comment: