Jet-Set Willy ST Room Format
Version 1.0: 18 December 2005
by John Elliott
Disclaimer: I do not guarantee this information to be correct. This is my best guess at what is going on inside JSW ST, after wandering around inside it with a disassembler.
Atari JSW is a very close replica of Spectrum JSW, coded in C based on a disassembled version of the original JSW48. It is distributed as a .PRG file, the contents of which are:
|Offset in file||Load address, hex||Load address, decimal||Details|
|0x0000||-||-||PRG file header. Format seems to be similar to
CP/M-86 CMD; perhaps the same as CP/M-68k CMD.
60 1A -- Magic? 00 00 63 A2 -- Code len? 00 00 68 86 -- Data len? 00 00 06 62 -- BSS len? 00 00 00 ...
|0x001C||0x0000||0||Atari code segment. This contains some constants which a game editor would need to change, including the count of items.|
|0x63BE||0x63A2||25506||Atari data segment starts here.|
|0x640D||0x63F1||25585||"Items collected 000 Time 00:00 m" message, followed by various strings of digits.|
|0x64EC||0x64D0||25808||"Press ENTER to start" message / scrolling message. For some reason, this is broken up into segments of irregular length in reverse order; each section is terminated by a zero byte. An editor program changing the message would have to break it up into portions of the exact same size when storing, because the game code makes separate references to each section.|
|0x66DA||0x66BE||26302||Title screen music.|
|0x673E||0x6722||26402||Unknown, but contains the following messages:|
"Please enter room number: __ "
"jetset: Sorry - must use a colour monitor\n"
"jetset: malloc failure!\n"
|0x6854||0x6838||26680||Spectrum font; there seems to be a transcription error in the } character.|
|0x6B54||0x6B38||27448||Conveyor animation table|
|0x6B64||0x6B48||27464||The stripe patterns for the title screen.|
|0x6B84||0x6B68||27496||The items table: 83 entries. Unlike in Spectrum JSW, the two halves of the table are interleaved; first byte gives item position low 8 bits, second gives room number and item position high bit.|
|0x6C2A||0x6C0E||27662||Rope movement table|
|0x6D2A||0x6D0E||27918||Guardian table, in standard JSW format.|
|0xB12A||0xB10E||45326||Blank; probably corresponds to rooms 62 and 63.|
|0xB32A||0xB30E||45838||Sprites. The mapping to Spectrum sprite pages is
hardcoded in the guardian drawing code:
|0xC96A||0xC94E||51534||6 long words giving sprite addresses
for special sprites:
|0xC982||0xC966||51558||Unknown. Possibly we're getting into the C runtime library by this stage.|
|0xCB3C||0xCB20||52000||This is definitely in the C runtime; it's the array of character characteristics used by <ctype.h> functions.|
In order to lift the limits on the number of sprites and/or items, so that arbitrary JSW48 games could be converted to ST format, it would be necessary to make the data segment bigger. Not being familiar with the Atari PRG format, I don't know if this is possible without major patching of the existing code.John Elliott 18-12-2005.