Skip to main content

Block event and flying object data

Data · Routines · Address index

Flying-object records, step counters, and the tables of throws, launches and party hits. The data page explains how the entries are written.

DS:0x5cff — Half-block steps​

  • Layout: 4 × 4 bytes, indexed by direction and position
  • Role: The next position of a flying object in the low two bits; bit 0x80 means that it enters the next block, which receives a block event. For north, positions 0 and 1 go to 2 and 3 of the next block, positions 2 and 3 to 0 and 1 of the same block (bytes 82 83 00 01 | 01 80 03 82 | 02 03 80 81 | 81 00 83 02): an object advances half a block per step.
  • Used by: On the floor and in the air › Throwing and launching items

DS:0xcc5c — Flying-object records​

DS:0xdf4c — Record gate mask​

DS:0x5a28 — Message scroll counter​

  • Layout: word, 0 in the image
  • Role: Counts the party's moves; every fourth prints a line end in the message window and resets it. The only accesses are at 0x24f58, 0x24f5c and 0x24f71. It lies outside the parts of a saved game (DS:0xe608, 0x6dce, 0x71ca, 0x65fc, 0x65fa, 0xe4c5 and 0x979e; overlay code at file offsets 0x498c5–0x49b32).
  • Used by: Move the party, Loading, failures and the end of the game

DS:0xe5c8 — Step counter​

DS:0xee1e — Steps until the step script​

DS:0x3106 — Target order of a single-target object​

  • Layout: 64 bytes: 4 directions × 4 positions × 4 positions. Directions 0 and 2 hold 4 2 1 3, 4 3 0 2, 4 0 3 1, 4 1 2 0; directions 1 and 3 hold 4 1 2 3, 4 0 3 2, 4 3 0 1, 4 2 1 0.
  • Role: For an object's direction and position, the positions of the block in the order in which the search prefers them: the centre (4), the quarter in line with the flight, the quarter beside the object, the opposite quarter.
  • Used by:

DS:0x2352, DS:0x5530 — Quarter and character tables of a party hit​

DS:0x4714, DS:0x4750 — Throw buttons​

  • Layout: 2 button records at DS:0x4714 and DS:0x4750 (entries 36 and 37 of the main button list); rectangles at DS:0x4732/0x476e, callbacks at DS:0x4744/0x4780, zone at +0x38
  • Role: The left and right halves of the upper view, at (0, 8) and (88, 8), 88 wide and 48 high, calling the throw routine with zones 0 and 1.
  • Used by:

DS:0x5a9d — Scripted launch positions​

  • Layout: 4 × 2 bytes, indexed by direction and side
  • Role: For each direction, the two positions of the half of the block behind the direction of travel: 2 3, 0 2, 1 0, 3 1; the first byte is the left position, the second the right, relative to the direction of travel. Used by SCRIPT_LAUNCH_OBJECT with its direction and offset bytes, for items and magic alike.
  • Used by: Launch an object › Behavior