Alley Cat Text Format

From ModdingWiki
Jump to navigation Jump to search

Menu and pause text in Alley Cat consists of NUL-terminated byte strings embedded in the executable. The visible title logo and credits artwork are images, rather than text strings.

File format

There is no string-file header or global string count. The normal print routine reads one byte at a time until 0x00, and sends every preceding byte to BIOS INT 10h teletype output using colour 2.

Data type Name Description
BYTE[n] characters Character bytes and BIOS text controls
UINT8 terminator 0x00

The port handles carriage return (0D), line feed (0A), backspace (08) and bell (07; no audible bell is emitted by its BIOS substitute). Printable ASCII can be recovered directly. The viewer's ASCII scanner is only a discovery aid; it is not the game's string decoder.

Menu tables

At each menu-line call, bx is an even byte index held at DS:6D8F:

IBM DS address Read as Meaning
0x6D37 + bx UINT16LE Pointer to NUL-terminated text
0x6D63 + bx + 1 UINT8 Screen row
0x6D8F UINT16LE Current menu-table byte index, incremented by 2 after selecting a line

The column is set to 0 by the caller. Only the second byte of each two-byte row-table slot is used by this routine. Menu code selects particular ranges of entries; there is no stored record count.

Pause strings

IBM DS offset Use
0x6D91 First pause message
0x6DB2 Keyboard-mode continuation message
0x6DD3 Joystick-mode continuation message

Notes

  • For an in-place edit, keep the string and terminator within the original allocation. Moving a string also requires updating its pointers or hard-coded references.
  • The viewer displays runs of at least eight bytes from printable ASCII plus CR/LF, and requires a sequence of at least three letters. It scans the entire file, so short strings can be missed and code or binary data can appear as false matches.
  • The Tandy piecewise address map does not cover the IBM menu-pointer range beginning at 6D37. Do not assume that all menu structures can be translated with that map; the Tandy-specific layout needs separate analysis. Raw string scanning remains available.
  • Text is rendered using the machine's ROM font. The port's substitute font is not an original game asset.

Source code

From re-alleycat, the open-source HTML5 port (revision b003aa63ffbb):

Credits

This file format was reverse engineered by VorticonCmdr. Please credit the original research when using this information in your own project, and include a link back to this wiki.