{
 "schema": 1,
 "platform": "spectrum",
 "game": "lords-of-chaos",
 "part": "engine",
 "build": "",
 "source": "control file",
 "regions": {
  "exclude": [
   [
    0,
    16383,
    "ROM"
   ],
   [
    16384,
    23295,
    "screen RAM"
   ],
   [
    16384,
    23295,
    "the loading screen, which the loader LOC2 loads from the tape and copies to the screen before the program arrives; the program never reads it and draws over it from its first screen (reference/loading-screen.png is a picture of it)"
   ],
   [
    23296,
    24685,
    "the game's variables ($5B00-$5B59), its object table ($5B5A-$5EBF, 145 entries of six bytes) and the creature records ($5EC0-$606D, 86 of five bytes), all written in play from the scenario or a saved game; at the hand-over they still hold the ROM's system variables, the BASIC and the loader LOC2"
   ],
   [
    52697,
    52735,
    "a copy of the 48K ROM's main key table ($0205-$022B), the letter of each key by the number KEY-SCAN gives it, with SYMBOL SHIFT ($0E in the ROM) and ENTER ($0D) made 0: ask_file_name and the number of players read keys through it"
   ],
   [
    53251,
    65535,
    "4 parts: The wizard designer, Scenario 1: The Many Coloured Land, Scenario 2: Slayer's Dungeon and others"
   ]
  ],
  "extra": [],
  "edges": [
   16384,
   32768,
   49152
  ],
  "elsewhere": [
   [
    53251,
    65535,
    "4 parts: The wizard designer, Scenario 1: The Many Coloured Land, Scenario 2: Slayer's Dungeon and others"
   ]
  ]
 },
 "blocks": [
  {
   "start": 24686,
   "end": 24686,
   "type": "Byte"
  },
  {
   "start": 24687,
   "end": 24688,
   "type": "Word"
  },
  {
   "start": 24689,
   "end": 24690,
   "type": "Word"
  },
  {
   "start": 24691,
   "end": 24883,
   "type": "Code"
  },
  {
   "start": 24884,
   "end": 24992,
   "type": "Code"
  },
  {
   "start": 24993,
   "end": 25026,
   "type": "Code"
  },
  {
   "start": 25027,
   "end": 25036,
   "type": "Code"
  },
  {
   "start": 25037,
   "end": 25129,
   "type": "Code"
  },
  {
   "start": 25130,
   "end": 25130,
   "type": "Byte"
  },
  {
   "start": 25131,
   "end": 25152,
   "type": "Code"
  },
  {
   "start": 25153,
   "end": 25158,
   "type": "Word"
  },
  {
   "start": 25159,
   "end": 25179,
   "type": "Code"
  },
  {
   "start": 25180,
   "end": 25205,
   "type": "Code"
  },
  {
   "start": 25206,
   "end": 25242,
   "type": "Code"
  },
  {
   "start": 25243,
   "end": 25396,
   "type": "Code"
  },
  {
   "start": 25397,
   "end": 25415,
   "type": "Code"
  },
  {
   "start": 25416,
   "end": 25450,
   "type": "Code"
  },
  {
   "start": 25451,
   "end": 25485,
   "type": "Code"
  },
  {
   "start": 25486,
   "end": 25520,
   "type": "Code"
  },
  {
   "start": 25521,
   "end": 25555,
   "type": "Code"
  },
  {
   "start": 25556,
   "end": 25577,
   "type": "Code"
  },
  {
   "start": 25578,
   "end": 25676,
   "type": "Code"
  },
  {
   "start": 25677,
   "end": 25699,
   "type": "Code"
  },
  {
   "start": 25700,
   "end": 25716,
   "type": "Code"
  },
  {
   "start": 25717,
   "end": 25756,
   "type": "Code"
  },
  {
   "start": 25757,
   "end": 25899,
   "type": "Code"
  },
  {
   "start": 25900,
   "end": 25917,
   "type": "Code"
  },
  {
   "start": 25918,
   "end": 26008,
   "type": "Code"
  },
  {
   "start": 26009,
   "end": 26243,
   "type": "Code"
  },
  {
   "start": 26244,
   "end": 26273,
   "type": "Code"
  },
  {
   "start": 26274,
   "end": 26309,
   "type": "Code"
  },
  {
   "start": 26310,
   "end": 26313,
   "type": "Code"
  },
  {
   "start": 26314,
   "end": 26316,
   "type": "Code"
  },
  {
   "start": 26317,
   "end": 26432,
   "type": "Code"
  },
  {
   "start": 26433,
   "end": 26437,
   "type": "Code"
  },
  {
   "start": 26438,
   "end": 26440,
   "type": "Code"
  },
  {
   "start": 26441,
   "end": 26530,
   "type": "Code"
  },
  {
   "start": 26531,
   "end": 26534,
   "type": "Code"
  },
  {
   "start": 26535,
   "end": 26671,
   "type": "Code"
  },
  {
   "start": 26672,
   "end": 26699,
   "type": "Code"
  },
  {
   "start": 26700,
   "end": 26721,
   "type": "Code"
  },
  {
   "start": 26722,
   "end": 26875,
   "type": "Code"
  },
  {
   "start": 26876,
   "end": 26883,
   "type": "Code"
  },
  {
   "start": 26884,
   "end": 26910,
   "type": "Code"
  },
  {
   "start": 26911,
   "end": 27148,
   "type": "Code"
  },
  {
   "start": 27149,
   "end": 27190,
   "type": "Code"
  },
  {
   "start": 27191,
   "end": 27265,
   "type": "Code"
  },
  {
   "start": 27266,
   "end": 27301,
   "type": "Code"
  },
  {
   "start": 27302,
   "end": 27440,
   "type": "Code"
  },
  {
   "start": 27441,
   "end": 28045,
   "type": "Code"
  },
  {
   "start": 28046,
   "end": 28089,
   "type": "Word"
  },
  {
   "start": 28090,
   "end": 28097,
   "type": "Code"
  },
  {
   "start": 28098,
   "end": 28186,
   "type": "Code"
  },
  {
   "start": 28187,
   "end": 28240,
   "type": "Code"
  },
  {
   "start": 28241,
   "end": 28299,
   "type": "Code"
  },
  {
   "start": 28300,
   "end": 28322,
   "type": "Code"
  },
  {
   "start": 28323,
   "end": 28356,
   "type": "Code"
  },
  {
   "start": 28357,
   "end": 28578,
   "type": "Code"
  },
  {
   "start": 28579,
   "end": 28610,
   "type": "Code"
  },
  {
   "start": 28611,
   "end": 28643,
   "type": "Code"
  },
  {
   "start": 28644,
   "end": 28656,
   "type": "Code"
  },
  {
   "start": 28657,
   "end": 28684,
   "type": "Code"
  },
  {
   "start": 28685,
   "end": 28777,
   "type": "Code"
  },
  {
   "start": 28778,
   "end": 28969,
   "type": "Code"
  },
  {
   "start": 28970,
   "end": 28971,
   "type": "Byte"
  },
  {
   "start": 28972,
   "end": 29013,
   "type": "Code"
  },
  {
   "start": 29014,
   "end": 29069,
   "type": "Code"
  },
  {
   "start": 29070,
   "end": 29138,
   "type": "Code"
  },
  {
   "start": 29139,
   "end": 29185,
   "type": "Code"
  },
  {
   "start": 29186,
   "end": 29257,
   "type": "Code"
  },
  {
   "start": 29258,
   "end": 29279,
   "type": "Code"
  },
  {
   "start": 29280,
   "end": 29568,
   "type": "Code"
  },
  {
   "start": 29569,
   "end": 29609,
   "type": "Code"
  },
  {
   "start": 29610,
   "end": 29647,
   "type": "Code"
  },
  {
   "start": 29648,
   "end": 29821,
   "type": "Code"
  },
  {
   "start": 29822,
   "end": 29847,
   "type": "Code"
  },
  {
   "start": 29848,
   "end": 29905,
   "type": "Code"
  },
  {
   "start": 29906,
   "end": 29924,
   "type": "Code"
  },
  {
   "start": 29925,
   "end": 30001,
   "type": "Code"
  },
  {
   "start": 30002,
   "end": 30038,
   "type": "Code"
  },
  {
   "start": 30039,
   "end": 30042,
   "type": "Word"
  },
  {
   "start": 30043,
   "end": 30047,
   "type": "Code"
  },
  {
   "start": 30048,
   "end": 30518,
   "type": "Code"
  },
  {
   "start": 30519,
   "end": 30548,
   "type": "Code"
  },
  {
   "start": 30549,
   "end": 30850,
   "type": "Code"
  },
  {
   "start": 30851,
   "end": 30856,
   "type": "Code"
  },
  {
   "start": 30857,
   "end": 30861,
   "type": "Code"
  },
  {
   "start": 30862,
   "end": 30867,
   "type": "Code"
  },
  {
   "start": 30868,
   "end": 30875,
   "type": "Code"
  },
  {
   "start": 30876,
   "end": 30881,
   "type": "Code"
  },
  {
   "start": 30882,
   "end": 30887,
   "type": "Code"
  },
  {
   "start": 30888,
   "end": 30894,
   "type": "Code"
  },
  {
   "start": 30895,
   "end": 30903,
   "type": "Code"
  },
  {
   "start": 30904,
   "end": 30917,
   "type": "Code"
  },
  {
   "start": 30918,
   "end": 30925,
   "type": "Code"
  },
  {
   "start": 30926,
   "end": 30933,
   "type": "Code"
  },
  {
   "start": 30934,
   "end": 30956,
   "type": "Code"
  },
  {
   "start": 30957,
   "end": 30990,
   "type": "Code"
  },
  {
   "start": 30991,
   "end": 31026,
   "type": "Code"
  },
  {
   "start": 31027,
   "end": 31081,
   "type": "Code"
  },
  {
   "start": 31082,
   "end": 31114,
   "type": "Code"
  },
  {
   "start": 31115,
   "end": 31224,
   "type": "Code"
  },
  {
   "start": 31225,
   "end": 31225,
   "type": "Byte"
  },
  {
   "start": 31226,
   "end": 31232,
   "type": "Code"
  },
  {
   "start": 31233,
   "end": 31424,
   "type": "Code"
  },
  {
   "start": 31425,
   "end": 31443,
   "type": "Code"
  },
  {
   "start": 31444,
   "end": 31464,
   "type": "Code"
  },
  {
   "start": 31465,
   "end": 31536,
   "type": "Code"
  },
  {
   "start": 31537,
   "end": 31543,
   "type": "Code"
  },
  {
   "start": 31544,
   "end": 31712,
   "type": "Code"
  },
  {
   "start": 31713,
   "end": 31770,
   "type": "Code"
  },
  {
   "start": 31771,
   "end": 31771,
   "type": "Byte"
  },
  {
   "start": 31772,
   "end": 31960,
   "type": "Code"
  },
  {
   "start": 31961,
   "end": 31999,
   "type": "Code"
  },
  {
   "start": 32000,
   "end": 32090,
   "type": "Code"
  },
  {
   "start": 32091,
   "end": 32163,
   "type": "Code"
  },
  {
   "start": 32164,
   "end": 32188,
   "type": "Code"
  },
  {
   "start": 32189,
   "end": 32420,
   "type": "Code"
  },
  {
   "start": 32421,
   "end": 32520,
   "type": "Code"
  },
  {
   "start": 32521,
   "end": 32663,
   "type": "Code"
  },
  {
   "start": 32664,
   "end": 32870,
   "type": "Code"
  },
  {
   "start": 32871,
   "end": 32907,
   "type": "Code"
  },
  {
   "start": 32908,
   "end": 32919,
   "type": "Code"
  },
  {
   "start": 32920,
   "end": 32927,
   "type": "Word"
  },
  {
   "start": 32928,
   "end": 32958,
   "type": "Code"
  },
  {
   "start": 32959,
   "end": 33133,
   "type": "Code"
  },
  {
   "start": 33134,
   "end": 33235,
   "type": "Code"
  },
  {
   "start": 33236,
   "end": 33281,
   "type": "Code"
  },
  {
   "start": 33282,
   "end": 33329,
   "type": "Code"
  },
  {
   "start": 33330,
   "end": 33381,
   "type": "Code"
  },
  {
   "start": 33382,
   "end": 33388,
   "type": "Code"
  },
  {
   "start": 33389,
   "end": 33441,
   "type": "Code"
  },
  {
   "start": 33442,
   "end": 33494,
   "type": "Code"
  },
  {
   "start": 33495,
   "end": 33529,
   "type": "Code"
  },
  {
   "start": 33530,
   "end": 33547,
   "type": "Word"
  },
  {
   "start": 33548,
   "end": 33567,
   "type": "Code"
  },
  {
   "start": 33568,
   "end": 33601,
   "type": "Code"
  },
  {
   "start": 33602,
   "end": 33701,
   "type": "Code"
  },
  {
   "start": 33702,
   "end": 33754,
   "type": "Code"
  },
  {
   "start": 33755,
   "end": 33762,
   "type": "Code"
  },
  {
   "start": 33763,
   "end": 33845,
   "type": "Code"
  },
  {
   "start": 33846,
   "end": 33892,
   "type": "Code"
  },
  {
   "start": 33893,
   "end": 33997,
   "type": "Code"
  },
  {
   "start": 33998,
   "end": 34004,
   "type": "Byte"
  },
  {
   "start": 34005,
   "end": 34027,
   "type": "Code"
  },
  {
   "start": 34028,
   "end": 34236,
   "type": "Code"
  },
  {
   "start": 34237,
   "end": 34397,
   "type": "Code"
  },
  {
   "start": 34398,
   "end": 34443,
   "type": "Code"
  },
  {
   "start": 34444,
   "end": 34460,
   "type": "Code"
  },
  {
   "start": 34461,
   "end": 34481,
   "type": "Code"
  },
  {
   "start": 34482,
   "end": 34678,
   "type": "Code"
  },
  {
   "start": 34679,
   "end": 34800,
   "type": "Code"
  },
  {
   "start": 34801,
   "end": 34866,
   "type": "Code"
  },
  {
   "start": 34867,
   "end": 34910,
   "type": "Code"
  },
  {
   "start": 34911,
   "end": 34958,
   "type": "Code"
  },
  {
   "start": 34959,
   "end": 34986,
   "type": "Code"
  },
  {
   "start": 34987,
   "end": 35161,
   "type": "Code"
  },
  {
   "start": 35162,
   "end": 35162,
   "type": "Byte"
  },
  {
   "start": 35163,
   "end": 35163,
   "type": "Byte"
  },
  {
   "start": 35164,
   "end": 35260,
   "type": "Code"
  },
  {
   "start": 35261,
   "end": 35273,
   "type": "Code"
  },
  {
   "start": 35274,
   "end": 35283,
   "type": "Code"
  },
  {
   "start": 35284,
   "end": 35305,
   "type": "Code"
  },
  {
   "start": 35306,
   "end": 35342,
   "type": "Code"
  },
  {
   "start": 35343,
   "end": 35343,
   "type": "Byte"
  },
  {
   "start": 35344,
   "end": 35344,
   "type": "Byte"
  },
  {
   "start": 35345,
   "end": 35346,
   "type": "Word"
  },
  {
   "start": 35347,
   "end": 35464,
   "type": "Code"
  },
  {
   "start": 35465,
   "end": 35465,
   "type": "Byte"
  },
  {
   "start": 35466,
   "end": 35552,
   "type": "Code"
  },
  {
   "start": 35553,
   "end": 35760,
   "type": "Code"
  },
  {
   "start": 35761,
   "end": 35776,
   "type": "Code"
  },
  {
   "start": 35777,
   "end": 35819,
   "type": "Code"
  },
  {
   "start": 35820,
   "end": 35851,
   "type": "Code"
  },
  {
   "start": 35852,
   "end": 35937,
   "type": "Code"
  },
  {
   "start": 35938,
   "end": 35945,
   "type": "Code"
  },
  {
   "start": 35946,
   "end": 36046,
   "type": "Code"
  },
  {
   "start": 36047,
   "end": 36062,
   "type": "Code"
  },
  {
   "start": 36063,
   "end": 36089,
   "type": "Code"
  },
  {
   "start": 36090,
   "end": 36252,
   "type": "Code"
  },
  {
   "start": 36253,
   "end": 36306,
   "type": "Code"
  },
  {
   "start": 36307,
   "end": 36432,
   "type": "Code"
  },
  {
   "start": 36433,
   "end": 36489,
   "type": "Code"
  },
  {
   "start": 36490,
   "end": 36566,
   "type": "Code"
  },
  {
   "start": 36567,
   "end": 36751,
   "type": "Code"
  },
  {
   "start": 36752,
   "end": 36769,
   "type": "Code"
  },
  {
   "start": 36770,
   "end": 36781,
   "type": "Code"
  },
  {
   "start": 36782,
   "end": 36796,
   "type": "Code"
  },
  {
   "start": 36797,
   "end": 36842,
   "type": "Code"
  },
  {
   "start": 36843,
   "end": 36986,
   "type": "Code"
  },
  {
   "start": 36987,
   "end": 37031,
   "type": "Code"
  },
  {
   "start": 37032,
   "end": 37097,
   "type": "Code"
  },
  {
   "start": 37098,
   "end": 37155,
   "type": "Code"
  },
  {
   "start": 37156,
   "end": 37178,
   "type": "Code"
  },
  {
   "start": 37179,
   "end": 37200,
   "type": "Code"
  },
  {
   "start": 37201,
   "end": 37321,
   "type": "Code"
  },
  {
   "start": 37322,
   "end": 37338,
   "type": "Code"
  },
  {
   "start": 37339,
   "end": 37352,
   "type": "Code"
  },
  {
   "start": 37353,
   "end": 37366,
   "type": "Code"
  },
  {
   "start": 37367,
   "end": 37377,
   "type": "Code"
  },
  {
   "start": 37378,
   "end": 37473,
   "type": "Code"
  },
  {
   "start": 37474,
   "end": 37494,
   "type": "Code"
  },
  {
   "start": 37495,
   "end": 37502,
   "type": "Word"
  },
  {
   "start": 37503,
   "end": 37512,
   "type": "Code"
  },
  {
   "start": 37513,
   "end": 37522,
   "type": "Code"
  },
  {
   "start": 37523,
   "end": 37532,
   "type": "Code"
  },
  {
   "start": 37533,
   "end": 37630,
   "type": "Code"
  },
  {
   "start": 37631,
   "end": 37652,
   "type": "Code"
  },
  {
   "start": 37653,
   "end": 37665,
   "type": "Code"
  },
  {
   "start": 37666,
   "end": 37683,
   "type": "Code"
  },
  {
   "start": 37684,
   "end": 37697,
   "type": "Word"
  },
  {
   "start": 37698,
   "end": 38044,
   "type": "Code"
  },
  {
   "start": 38045,
   "end": 38070,
   "type": "Code"
  },
  {
   "start": 38071,
   "end": 38094,
   "type": "Code"
  },
  {
   "start": 38095,
   "end": 38106,
   "type": "Code"
  },
  {
   "start": 38107,
   "end": 38159,
   "type": "Code"
  },
  {
   "start": 38160,
   "end": 38192,
   "type": "Code"
  },
  {
   "start": 38193,
   "end": 38584,
   "type": "Byte"
  },
  {
   "start": 38585,
   "end": 38585,
   "type": "Byte"
  },
  {
   "start": 38586,
   "end": 38634,
   "type": "Code"
  },
  {
   "start": 38635,
   "end": 38715,
   "type": "Code"
  },
  {
   "start": 38716,
   "end": 38733,
   "type": "Code"
  },
  {
   "start": 38734,
   "end": 38984,
   "type": "Code"
  },
  {
   "start": 38985,
   "end": 38985,
   "type": "Byte"
  },
  {
   "start": 38986,
   "end": 38999,
   "type": "Code"
  },
  {
   "start": 39000,
   "end": 39082,
   "type": "Code"
  },
  {
   "start": 39083,
   "end": 39139,
   "type": "Code"
  },
  {
   "start": 39140,
   "end": 39203,
   "type": "Code"
  },
  {
   "start": 39204,
   "end": 39222,
   "type": "Code"
  },
  {
   "start": 39223,
   "end": 39242,
   "type": "Code"
  },
  {
   "start": 39243,
   "end": 39280,
   "type": "Code"
  },
  {
   "start": 39281,
   "end": 39294,
   "type": "Code"
  },
  {
   "start": 39295,
   "end": 39313,
   "type": "Code"
  },
  {
   "start": 39314,
   "end": 39436,
   "type": "Code"
  },
  {
   "start": 39437,
   "end": 39492,
   "type": "Code"
  },
  {
   "start": 39493,
   "end": 39493,
   "type": "Byte"
  },
  {
   "start": 39494,
   "end": 39495,
   "type": "Word"
  },
  {
   "start": 39496,
   "end": 39583,
   "type": "Code"
  },
  {
   "start": 39584,
   "end": 39585,
   "type": "Word"
  },
  {
   "start": 39586,
   "end": 39602,
   "type": "Byte"
  },
  {
   "start": 39603,
   "end": 39619,
   "type": "Code"
  },
  {
   "start": 39620,
   "end": 39643,
   "type": "Code"
  },
  {
   "start": 39644,
   "end": 39666,
   "type": "Code"
  },
  {
   "start": 39667,
   "end": 39718,
   "type": "Code"
  },
  {
   "start": 39719,
   "end": 39734,
   "type": "Word"
  },
  {
   "start": 39735,
   "end": 39741,
   "type": "Code"
  },
  {
   "start": 39742,
   "end": 39747,
   "type": "Code"
  },
  {
   "start": 39748,
   "end": 39776,
   "type": "Code"
  },
  {
   "start": 39777,
   "end": 39839,
   "type": "Code"
  },
  {
   "start": 39840,
   "end": 39882,
   "type": "Code"
  },
  {
   "start": 39883,
   "end": 39885,
   "type": "Code"
  },
  {
   "start": 39886,
   "end": 39985,
   "type": "Code"
  },
  {
   "start": 39986,
   "end": 40075,
   "type": "Code"
  },
  {
   "start": 40076,
   "end": 40132,
   "type": "Code"
  },
  {
   "start": 40133,
   "end": 40364,
   "type": "Code"
  },
  {
   "start": 40365,
   "end": 40505,
   "type": "Code"
  },
  {
   "start": 40506,
   "end": 40572,
   "type": "Code"
  },
  {
   "start": 40573,
   "end": 40992,
   "type": "Code"
  },
  {
   "start": 40993,
   "end": 41199,
   "type": "Code"
  },
  {
   "start": 41200,
   "end": 41365,
   "type": "Code"
  },
  {
   "start": 41366,
   "end": 41452,
   "type": "Code"
  },
  {
   "start": 41453,
   "end": 41514,
   "type": "Code"
  },
  {
   "start": 41515,
   "end": 41592,
   "type": "Code"
  },
  {
   "start": 41593,
   "end": 41723,
   "type": "Code"
  },
  {
   "start": 41724,
   "end": 41857,
   "type": "Code"
  },
  {
   "start": 41858,
   "end": 41990,
   "type": "Code"
  },
  {
   "start": 41991,
   "end": 42065,
   "type": "Code"
  },
  {
   "start": 42066,
   "end": 42078,
   "type": "Code"
  },
  {
   "start": 42079,
   "end": 42079,
   "type": "Code"
  },
  {
   "start": 42080,
   "end": 42233,
   "type": "Code"
  },
  {
   "start": 42234,
   "end": 42428,
   "type": "Code"
  },
  {
   "start": 42429,
   "end": 42563,
   "type": "Code"
  },
  {
   "start": 42564,
   "end": 42717,
   "type": "Code"
  },
  {
   "start": 42718,
   "end": 42728,
   "type": "Code"
  },
  {
   "start": 42729,
   "end": 42751,
   "type": "Code"
  },
  {
   "start": 42752,
   "end": 42773,
   "type": "Code"
  },
  {
   "start": 42774,
   "end": 42803,
   "type": "Code"
  },
  {
   "start": 42804,
   "end": 42845,
   "type": "Code"
  },
  {
   "start": 42846,
   "end": 42917,
   "type": "Code"
  },
  {
   "start": 42918,
   "end": 42923,
   "type": "Word"
  },
  {
   "start": 42924,
   "end": 42925,
   "type": "Word"
  },
  {
   "start": 42926,
   "end": 42927,
   "type": "Word"
  },
  {
   "start": 42928,
   "end": 42929,
   "type": "Word"
  },
  {
   "start": 42930,
   "end": 42931,
   "type": "Word"
  },
  {
   "start": 42932,
   "end": 42933,
   "type": "Word"
  },
  {
   "start": 42934,
   "end": 43074,
   "type": "Code"
  },
  {
   "start": 43075,
   "end": 43081,
   "type": "Code"
  },
  {
   "start": 43082,
   "end": 43128,
   "type": "Code"
  },
  {
   "start": 43129,
   "end": 43152,
   "type": "Code"
  },
  {
   "start": 43153,
   "end": 43316,
   "type": "Code"
  },
  {
   "start": 43317,
   "end": 43317,
   "type": "Byte"
  },
  {
   "start": 43318,
   "end": 43339,
   "type": "Code"
  },
  {
   "start": 43340,
   "end": 43612,
   "type": "Code"
  },
  {
   "start": 43613,
   "end": 43617,
   "type": "Code"
  },
  {
   "start": 43618,
   "end": 43622,
   "type": "Code"
  },
  {
   "start": 43623,
   "end": 43650,
   "type": "Code"
  },
  {
   "start": 43651,
   "end": 43678,
   "type": "Code"
  },
  {
   "start": 43679,
   "end": 43684,
   "type": "Code"
  },
  {
   "start": 43685,
   "end": 43731,
   "type": "Code"
  },
  {
   "start": 43732,
   "end": 43757,
   "type": "Code"
  },
  {
   "start": 43758,
   "end": 43789,
   "type": "Code"
  },
  {
   "start": 43790,
   "end": 43862,
   "type": "Code"
  },
  {
   "start": 43863,
   "end": 43890,
   "type": "Code"
  },
  {
   "start": 43891,
   "end": 43903,
   "type": "Code"
  },
  {
   "start": 43904,
   "end": 43931,
   "type": "Code"
  },
  {
   "start": 43932,
   "end": 44019,
   "type": "Code"
  },
  {
   "start": 44020,
   "end": 44030,
   "type": "Code"
  },
  {
   "start": 44031,
   "end": 44114,
   "type": "Code"
  },
  {
   "start": 44115,
   "end": 44143,
   "type": "Code"
  },
  {
   "start": 44144,
   "end": 44166,
   "type": "Code"
  },
  {
   "start": 44167,
   "end": 44175,
   "type": "Code"
  },
  {
   "start": 44176,
   "end": 44184,
   "type": "Code"
  },
  {
   "start": 44185,
   "end": 44197,
   "type": "Code"
  },
  {
   "start": 44198,
   "end": 44232,
   "type": "Code"
  },
  {
   "start": 44233,
   "end": 44316,
   "type": "Code"
  },
  {
   "start": 44317,
   "end": 44365,
   "type": "Code"
  },
  {
   "start": 44366,
   "end": 44369,
   "type": "Word"
  },
  {
   "start": 44370,
   "end": 44380,
   "type": "Byte"
  },
  {
   "start": 44381,
   "end": 44407,
   "type": "Byte"
  },
  {
   "start": 44408,
   "end": 44409,
   "type": "Word"
  },
  {
   "start": 44410,
   "end": 44432,
   "type": "Code"
  },
  {
   "start": 44433,
   "end": 44496,
   "type": "Code"
  },
  {
   "start": 44497,
   "end": 44545,
   "type": "Code"
  },
  {
   "start": 44546,
   "end": 44806,
   "type": "Code"
  },
  {
   "start": 44807,
   "end": 44830,
   "type": "Code"
  },
  {
   "start": 44831,
   "end": 44851,
   "type": "Code"
  },
  {
   "start": 44852,
   "end": 44875,
   "type": "Code"
  },
  {
   "start": 44876,
   "end": 44896,
   "type": "Code"
  },
  {
   "start": 44897,
   "end": 44944,
   "type": "Word"
  },
  {
   "start": 44945,
   "end": 45025,
   "type": "Code"
  },
  {
   "start": 45026,
   "end": 45124,
   "type": "Code"
  },
  {
   "start": 45125,
   "end": 45256,
   "type": "Code"
  },
  {
   "start": 45257,
   "end": 45371,
   "type": "Code"
  },
  {
   "start": 45372,
   "end": 45383,
   "type": "Code"
  },
  {
   "start": 45384,
   "end": 45477,
   "type": "Code"
  },
  {
   "start": 45478,
   "end": 45695,
   "type": "Code"
  },
  {
   "start": 45696,
   "end": 45799,
   "type": "Code"
  },
  {
   "start": 45800,
   "end": 46040,
   "type": "Code"
  },
  {
   "start": 46041,
   "end": 46080,
   "type": "Code"
  },
  {
   "start": 46081,
   "end": 46087,
   "type": "Code"
  },
  {
   "start": 46088,
   "end": 46094,
   "type": "Code"
  },
  {
   "start": 46095,
   "end": 46101,
   "type": "Code"
  },
  {
   "start": 46102,
   "end": 46169,
   "type": "Code"
  },
  {
   "start": 46170,
   "end": 46170,
   "type": "Byte"
  },
  {
   "start": 46171,
   "end": 46171,
   "type": "Byte"
  },
  {
   "start": 46172,
   "end": 46195,
   "type": "Byte"
  },
  {
   "start": 46196,
   "end": 46225,
   "type": "Byte"
  },
  {
   "start": 46226,
   "end": 46227,
   "type": "Word"
  },
  {
   "start": 46228,
   "end": 46236,
   "type": "Byte"
  },
  {
   "start": 46237,
   "end": 46252,
   "type": "Byte"
  },
  {
   "start": 46253,
   "end": 46260,
   "type": "Byte"
  },
  {
   "start": 46261,
   "end": 46269,
   "type": "Byte"
  },
  {
   "start": 46270,
   "end": 46314,
   "type": "Byte"
  },
  {
   "start": 46315,
   "end": 46419,
   "type": "Code"
  },
  {
   "start": 46420,
   "end": 46432,
   "type": "Code"
  },
  {
   "start": 46433,
   "end": 46478,
   "type": "Code"
  },
  {
   "start": 46479,
   "end": 46502,
   "type": "Code"
  },
  {
   "start": 46503,
   "end": 46545,
   "type": "Code"
  },
  {
   "start": 46546,
   "end": 46582,
   "type": "Code"
  },
  {
   "start": 46583,
   "end": 46605,
   "type": "Code"
  },
  {
   "start": 46606,
   "end": 46661,
   "type": "Byte"
  },
  {
   "start": 46662,
   "end": 47685,
   "type": "Byte"
  },
  {
   "start": 47686,
   "end": 48699,
   "type": "Byte"
  },
  {
   "start": 48700,
   "end": 49151,
   "type": "Byte"
  },
  {
   "start": 49152,
   "end": 50175,
   "type": "Byte"
  },
  {
   "start": 50176,
   "end": 50659,
   "type": "Byte"
  },
  {
   "start": 50660,
   "end": 50660,
   "type": "Byte"
  },
  {
   "start": 50661,
   "end": 50664,
   "type": "Code"
  },
  {
   "start": 50665,
   "end": 50705,
   "type": "Code"
  },
  {
   "start": 50706,
   "end": 50712,
   "type": "Code"
  },
  {
   "start": 50713,
   "end": 50726,
   "type": "Code"
  },
  {
   "start": 50727,
   "end": 50741,
   "type": "Code"
  },
  {
   "start": 50742,
   "end": 50742,
   "type": "Byte"
  },
  {
   "start": 50743,
   "end": 50754,
   "type": "ZX"
  },
  {
   "start": 50755,
   "end": 50755,
   "type": "Byte"
  },
  {
   "start": 50756,
   "end": 50764,
   "type": "Code"
  },
  {
   "start": 50765,
   "end": 50767,
   "type": "ZX"
  },
  {
   "start": 50768,
   "end": 50770,
   "type": "ZX"
  },
  {
   "start": 50771,
   "end": 50773,
   "type": "ZX"
  },
  {
   "start": 50774,
   "end": 50785,
   "type": "ZX"
  },
  {
   "start": 50786,
   "end": 50786,
   "type": "Byte"
  },
  {
   "start": 50787,
   "end": 50787,
   "type": "Byte"
  },
  {
   "start": 50788,
   "end": 50788,
   "type": "Byte"
  },
  {
   "start": 50789,
   "end": 50804,
   "type": "Code"
  },
  {
   "start": 50805,
   "end": 50865,
   "type": "Code"
  },
  {
   "start": 50866,
   "end": 50877,
   "type": "ZX"
  },
  {
   "start": 50878,
   "end": 50912,
   "type": "Code"
  },
  {
   "start": 50913,
   "end": 50951,
   "type": "Code"
  },
  {
   "start": 50952,
   "end": 50983,
   "type": "Code"
  },
  {
   "start": 50984,
   "end": 51020,
   "type": "Code"
  },
  {
   "start": 51021,
   "end": 51060,
   "type": "Code"
  },
  {
   "start": 51061,
   "end": 51119,
   "type": "Code"
  },
  {
   "start": 51120,
   "end": 51247,
   "type": "Byte"
  },
  {
   "start": 51248,
   "end": 51248,
   "type": "Byte"
  },
  {
   "start": 51249,
   "end": 51249,
   "type": "Byte"
  },
  {
   "start": 51250,
   "end": 51255,
   "type": "Byte"
  },
  {
   "start": 51256,
   "end": 51256,
   "type": "Byte"
  },
  {
   "start": 51257,
   "end": 51257,
   "type": "Byte"
  },
  {
   "start": 51258,
   "end": 51276,
   "type": "Code"
  },
  {
   "start": 51277,
   "end": 51346,
   "type": "Code"
  },
  {
   "start": 51347,
   "end": 51385,
   "type": "Code"
  },
  {
   "start": 51386,
   "end": 51394,
   "type": "Byte"
  },
  {
   "start": 51395,
   "end": 51427,
   "type": "ZX"
  },
  {
   "start": 51428,
   "end": 51520,
   "type": "Code"
  },
  {
   "start": 51521,
   "end": 51570,
   "type": "Code"
  },
  {
   "start": 51571,
   "end": 51593,
   "type": "Byte"
  },
  {
   "start": 51594,
   "end": 51754,
   "type": "Code"
  },
  {
   "start": 51755,
   "end": 52011,
   "type": "Code"
  },
  {
   "start": 52012,
   "end": 52074,
   "type": "Code"
  },
  {
   "start": 52075,
   "end": 52150,
   "type": "Code"
  },
  {
   "start": 52151,
   "end": 52232,
   "type": "Code"
  },
  {
   "start": 52233,
   "end": 52280,
   "type": "Code"
  },
  {
   "start": 52281,
   "end": 52336,
   "type": "Code"
  },
  {
   "start": 52337,
   "end": 52347,
   "type": "Code"
  },
  {
   "start": 52348,
   "end": 52359,
   "type": "Word"
  },
  {
   "start": 52360,
   "end": 52412,
   "type": "Code"
  },
  {
   "start": 52413,
   "end": 52537,
   "type": "Code"
  },
  {
   "start": 52538,
   "end": 52661,
   "type": "Code"
  },
  {
   "start": 52662,
   "end": 52696,
   "type": "Code"
  },
  {
   "start": 52697,
   "end": 52735,
   "type": "Byte"
  },
  {
   "start": 52736,
   "end": 52822,
   "type": "Byte"
  },
  {
   "start": 52823,
   "end": 52969,
   "type": "Byte"
  },
  {
   "start": 52970,
   "end": 53039,
   "type": "Byte"
  },
  {
   "start": 53040,
   "end": 53109,
   "type": "Byte"
  },
  {
   "start": 53110,
   "end": 53179,
   "type": "Byte"
  },
  {
   "start": 53180,
   "end": 53249,
   "type": "Byte"
  }
 ],
 "symbols": [
  {
   "address": 24686,
   "name": "frame_toggle",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 24687,
   "name": "random_pointer_1",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 24689,
   "name": "random_pointer_2",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 24691,
   "name": "start_game",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 24884,
   "name": "game_turn_loop",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 24993,
   "name": "player_has_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25027,
   "name": "owner_is_player",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25037,
   "name": "human_turn",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25130,
   "name": "control_type",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25131,
   "name": "read_controls",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25153,
   "name": "control_handlers",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25159,
   "name": "read_sinclair",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25180,
   "name": "read_kempston",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25206,
   "name": "read_keyboard",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25243,
   "name": "move_cursor",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25397,
   "name": "restore_cursor",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25416,
   "name": "cursor_up",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25451,
   "name": "cursor_down",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25486,
   "name": "cursor_left",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25521,
   "name": "cursor_right",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25556,
   "name": "clear_screen",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25557,
   "name": "fill_screen",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25578,
   "name": "clear_info_panel",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25677,
   "name": "clear_icon_cell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25700,
   "name": "clear_message_line",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25704,
   "name": "fill_message_line",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25717,
   "name": "blank_message_line",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25757,
   "name": "describe_cursor_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25900,
   "name": "describe_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 25918,
   "name": "fill_icon_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26009,
   "name": "print_square_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26244,
   "name": "print_owner_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26274,
   "name": "find_creature_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26310,
   "name": "find_creatures_any",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26314,
   "name": "find_others_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26317,
   "name": "find_creatures_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26433,
   "name": "list_selected_carries",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26438,
   "name": "list_found_carries",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26441,
   "name": "list_carried",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26531,
   "name": "list_objects_here",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26535,
   "name": "list_objects_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26672,
   "name": "clear_bars",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26679,
   "name": "clear_lower_bars",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26700,
   "name": "draw_menu_frame",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26722,
   "name": "attack_terrain",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26876,
   "name": "terrain_remains",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26884,
   "name": "select_air",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 26911,
   "name": "select_ground",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 27149,
   "name": "update_info_panel",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 27191,
   "name": "cursor_to_step",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 27266,
   "name": "show_message",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 27302,
   "name": "end_move",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 27441,
   "name": "select_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28046,
   "name": "select_actions",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28090,
   "name": "spend_action_points",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28098,
   "name": "can_fly_or_land",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28187,
   "name": "land",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28241,
   "name": "fly",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28300,
   "name": "ratio_divisor",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28323,
   "name": "scale_by_ratio",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28357,
   "name": "choose_from_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28579,
   "name": "draw_choice_bar",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28611,
   "name": "colour_choice_row",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28644,
   "name": "entry_address",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28657,
   "name": "drop",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28685,
   "name": "change",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28778,
   "name": "pick_up",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28970,
   "name": "unused_712A",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 28972,
   "name": "carried_weight",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29014,
   "name": "find_partner",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29070,
   "name": "ride",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29139,
   "name": "rider",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29186,
   "name": "pick_target",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29258,
   "name": "distance_from_selected",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29261,
   "name": "distance",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29280,
   "name": "use",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29292,
   "name": "use_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29569,
   "name": "set_terrain_under",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29610,
   "name": "can_drink",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29648,
   "name": "drink",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29822,
   "name": "can_fill",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29848,
   "name": "fill",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29906,
   "name": "can_eat",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 29925,
   "name": "eat",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30002,
   "name": "end_turn",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30039,
   "name": "end_turn_actions",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30043,
   "name": "end_turn_yes",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30045,
   "name": "end_turn_no",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30048,
   "name": "start_of_turn",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30519,
   "name": "load_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30549,
   "name": "damage_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30851,
   "name": "is_flying",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30857,
   "name": "is_loose",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30862,
   "name": "terrain_under",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30868,
   "name": "entry_position",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30876,
   "name": "read_table_word",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30882,
   "name": "entry_column",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30888,
   "name": "reset_ff86",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30895,
   "name": "value_against_best_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30896,
   "name": "value_against_best",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30904,
   "name": "cursor_on_selected",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30918,
   "name": "carry_limit",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30926,
   "name": "selected_potion",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30934,
   "name": "damage_and_rider",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30957,
   "name": "print_number",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 30991,
   "name": "print_digit",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31027,
   "name": "show_enemy_spotted",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31082,
   "name": "clear_map_things",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31115,
   "name": "show_hit",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31225,
   "name": "skip_hit",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31226,
   "name": "throw_air",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31233,
   "name": "throw_ground",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31272,
   "name": "throw_object",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31425,
   "name": "pick_throw_target",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31444,
   "name": "throw_range",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31465,
   "name": "line_of_sight",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31477,
   "name": "line_between",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31537,
   "name": "fire_air",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31544,
   "name": "fire_ground",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31549,
   "name": "fire_missile",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31684,
   "name": "maybe_set_terrain",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31689,
   "name": "set_square_terrain",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31713,
   "name": "destroy_lost_objects",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31771,
   "name": "big_map_height",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31772,
   "name": "big_map",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 31961,
   "name": "big_map_terrain",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32000,
   "name": "big_map_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32091,
   "name": "big_map_frame",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32164,
   "name": "set_spread_types",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32189,
   "name": "spread_magic",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32421,
   "name": "spread_to_neighbours",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32521,
   "name": "flood_area",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32664,
   "name": "step_effects",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32871,
   "name": "free_entry",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32879,
   "name": "free_entry_after_wizards",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32908,
   "name": "wizard_record",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32909,
   "name": "wizard_record_0",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32920,
   "name": "wizard_records",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32928,
   "name": "spell_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 32959,
   "name": "spell_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33134,
   "name": "print_spell_line",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33236,
   "name": "spell_cost",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33282,
   "name": "print_spell_page",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33330,
   "name": "choose_spell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33382,
   "name": "cast_air",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33389,
   "name": "cast_ground",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33442,
   "name": "pay_for_spell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33495,
   "name": "cast_spell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33530,
   "name": "spell_routines",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33548,
   "name": "free_record",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33568,
   "name": "summon_dragon",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33602,
   "name": "summon_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33702,
   "name": "square_free",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33755,
   "name": "create_creature_any",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33763,
   "name": "create_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33846,
   "name": "summon_display",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33893,
   "name": "brew_potion",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33930,
   "name": "brew_with",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 33998,
   "name": "potion_ingredients",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34005,
   "name": "add_mana",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34028,
   "name": "attack",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34237,
   "name": "strike",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34289,
   "name": "strike_ranged",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34309,
   "name": "strike_hit",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34398,
   "name": "pick_spell_target",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34444,
   "name": "draw_spell_bolt",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34461,
   "name": "area_spell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34482,
   "name": "area_spell_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34679,
   "name": "draw_turn_panel",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34801,
   "name": "enchant",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34867,
   "name": "enchant_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34911,
   "name": "magic_bolt",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34918,
   "name": "magic_bolt_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34959,
   "name": "creature_at_height",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 34987,
   "name": "magic_lightning",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35000,
   "name": "magic_lightning_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35162,
   "name": "subvert_rider",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35163,
   "name": "subvert_resistance",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35164,
   "name": "subversion",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35261,
   "name": "take_over",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35274,
   "name": "magic_resistance",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35284,
   "name": "curse",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35306,
   "name": "pick_creature_target",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35343,
   "name": "attack_radius",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35344,
   "name": "attack_type",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35345,
   "name": "attack_centre",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35347,
   "name": "magic_attack",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35465,
   "name": "magic_eye_on",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35466,
   "name": "magic_eye",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35553,
   "name": "teleport",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35761,
   "name": "jitter_coordinate",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35777,
   "name": "enchantments_wear_off",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35820,
   "name": "magic_shield",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35852,
   "name": "wizard_gone",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35938,
   "name": "entry_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 35946,
   "name": "death_animation_frame",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36047,
   "name": "draw_death_figure",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36063,
   "name": "copy_wizard_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36090,
   "name": "set_up_game",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36253,
   "name": "portal_turn",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36307,
   "name": "game_over",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36433,
   "name": "wait_fire_flashing",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36490,
   "name": "print_victory_points",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36567,
   "name": "cursor_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36752,
   "name": "offer_select_ground",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36770,
   "name": "offer_select_air",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36782,
   "name": "inform",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36797,
   "name": "draw_creature_panel",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36843,
   "name": "make_selected",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36987,
   "name": "centre",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 36990,
   "name": "centre_on",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37032,
   "name": "list_neighbours_of_selected",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37035,
   "name": "list_neighbours",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37098,
   "name": "what_is_under_cursor",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37101,
   "name": "what_is_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37156,
   "name": "terrain_record_here",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37159,
   "name": "terrain_record",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37179,
   "name": "short_wait",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37201,
   "name": "next_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37321,
   "name": "do_nothing",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37322,
   "name": "wait_release",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37339,
   "name": "wait_press",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37353,
   "name": "wait_fire",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37367,
   "name": "add_cursor_option",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37378,
   "name": "run_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37474,
   "name": "highlight_file_option",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37495,
   "name": "file_layouts",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37503,
   "name": "layout_turn_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37513,
   "name": "layout_file_panel",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37523,
   "name": "layout_wizard_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37533,
   "name": "layout_designer",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37543,
   "name": "highlight_menu_option",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37557,
   "name": "highlight_bar",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37631,
   "name": "start_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37653,
   "name": "add_menu_option",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37666,
   "name": "dispatch_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37684,
   "name": "cursor_actions",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 37698,
   "name": "load_figures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38045,
   "name": "object_record_of",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38048,
   "name": "object_record",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38071,
   "name": "divide",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38095,
   "name": "key_repeat_slow",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38107,
   "name": "key_repeat",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38160,
   "name": "delay_2",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38165,
   "name": "delay_20",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38170,
   "name": "delay_255",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38175,
   "name": "delay_8",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38180,
   "name": "delay_50",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38193,
   "name": "game_font",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38585,
   "name": "debug_count",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38586,
   "name": "debug_probe",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38635,
   "name": "computer_turn",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38716,
   "name": "clear_plan",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38734,
   "name": "computer_move_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38985,
   "name": "computer_steps",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 38986,
   "name": "at_target",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39000,
   "name": "computer_maybe_land",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39052,
   "name": "computer_land",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39083,
   "name": "look_at_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39140,
   "name": "computer_load_creature",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39204,
   "name": "computer_combat_figures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39223,
   "name": "weapon_range",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39243,
   "name": "find_in_wizard_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39246,
   "name": "find_in_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39281,
   "name": "waypoint_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39295,
   "name": "route_address",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39314,
   "name": "computer_choose_target",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39437,
   "name": "rank_neighbours",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39493,
   "name": "sort_pass",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39494,
   "name": "sort_entry",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39496,
   "name": "sort_neighbours",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39584,
   "name": "trail_next",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39586,
   "name": "trail",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39603,
   "name": "forget_trail",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39620,
   "name": "on_trail",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39644,
   "name": "remember_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39667,
   "name": "computer_try_steps",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39719,
   "name": "computer_step_actions",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39735,
   "name": "computer_step_done",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39742,
   "name": "computer_step_end",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39748,
   "name": "computer_step_attack",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39777,
   "name": "computer_decide_attack",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39840,
   "name": "computer_step_move",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39883,
   "name": "computer_step_skip",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39886,
   "name": "computer_step_blocked",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 39986,
   "name": "computer_take_object",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 40076,
   "name": "note_enemy",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 40133,
   "name": "computer_shoot",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 40365,
   "name": "computer_find_prey",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 40506,
   "name": "computer_take_off",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 40573,
   "name": "computer_flee",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 40993,
   "name": "computer_seek_object",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41200,
   "name": "computer_pick_up",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41366,
   "name": "computer_drink",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41453,
   "name": "computer_open_chest",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41515,
   "name": "computer_choose_weapon",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41593,
   "name": "computer_choose_vial",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41724,
   "name": "computer_eat",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41858,
   "name": "computer_cast",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 41991,
   "name": "computer_try_spell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42066,
   "name": "scenario_spell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42079,
   "name": "no_scenario_spell",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42080,
   "name": "computer_summon",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42176,
   "name": "computer_spell_done",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42234,
   "name": "add_to_wizard_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42429,
   "name": "computer_deliver",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42564,
   "name": "computer_brew",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42718,
   "name": "carries_type",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42729,
   "name": "lies_here",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42752,
   "name": "release_group",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42774,
   "name": "trip_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42804,
   "name": "random_below_a",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42807,
   "name": "random_below",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42846,
   "name": "draw_block_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42918,
   "name": "block_lines",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42924,
   "name": "block_line",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42926,
   "name": "block_screen",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42928,
   "name": "block_attr",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42930,
   "name": "block_chars",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42932,
   "name": "block_colours",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 42934,
   "name": "draw_block",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43075,
   "name": "draw_thing_at",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43082,
   "name": "thing_graphic",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43129,
   "name": "interrupt",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43153,
   "name": "interrupt_work",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43317,
   "name": "unused_A935",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43318,
   "name": "next_frame",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43340,
   "name": "draw_map",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43613,
   "name": "map_address_window",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43618,
   "name": "map_address_cursor",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43623,
   "name": "map_address_selected",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43626,
   "name": "map_address",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43651,
   "name": "blink_cursor",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43679,
   "name": "redraw_two_pictures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43685,
   "name": "redraw_pictures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43695,
   "name": "flash_icons",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43732,
   "name": "flash_menu_bar",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43758,
   "name": "draw_thing_list",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43790,
   "name": "slide_bars",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43863,
   "name": "print_panel_text",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43891,
   "name": "print_text",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43904,
   "name": "print_text_big",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43909,
   "name": "print_scenario_text",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43932,
   "name": "print_message",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 43997,
   "name": "end_of_word",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44020,
   "name": "find_entry",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44031,
   "name": "text_control",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44115,
   "name": "print_char",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44144,
   "name": "pixel_line_address",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44167,
   "name": "bar_edge",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44176,
   "name": "bar_top",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44185,
   "name": "bar_fill_line",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44198,
   "name": "draw_bar_outlines",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44233,
   "name": "plot",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44317,
   "name": "draw_shape",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44366,
   "name": "shapes",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44370,
   "name": "shape_small",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44381,
   "name": "shape_large",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44408,
   "name": "tail_next",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44410,
   "name": "clear_tail",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44433,
   "name": "missile_step",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44497,
   "name": "wipe_tail",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44546,
   "name": "draw_missile",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44738,
   "name": "draw_hit",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44807,
   "name": "scroll_down",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44831,
   "name": "scroll_up",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44852,
   "name": "scroll_right",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44876,
   "name": "scroll_left",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44897,
   "name": "screen_rows",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 44945,
   "name": "print_char_small",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45026,
   "name": "print_char_big",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45125,
   "name": "line_setup",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45257,
   "name": "line_step_pixels",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45264,
   "name": "line_step",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45372,
   "name": "wrap_coordinate",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45384,
   "name": "update_view",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45478,
   "name": "work_out_sight",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45696,
   "name": "see_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 45800,
   "name": "see_entry",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46041,
   "name": "count_enemy",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46081,
   "name": "unused_trace_20",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46088,
   "name": "unused_trace_40",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46095,
   "name": "trace_line_air",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46102,
   "name": "trace_line_ground",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46107,
   "name": "trace_line",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46170,
   "name": "word_gap",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46171,
   "name": "blink_count",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46172,
   "name": "pictures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46196,
   "name": "list_pictures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46226,
   "name": "flash_next",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46228,
   "name": "flash_colours",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46237,
   "name": "neighbour_steps",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46253,
   "name": "blob_dieback",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46261,
   "name": "fire_dieback",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46270,
   "name": "spell_base_costs",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46315,
   "name": "move_selected",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46420,
   "name": "set_entry_square",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46433,
   "name": "move_carried",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46479,
   "name": "creature_record_of",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46482,
   "name": "creature_record",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46503,
   "name": "type_record_of",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46506,
   "name": "type_record",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46546,
   "name": "keep_figures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46583,
   "name": "set_missile",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46606,
   "name": "missile_styles",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 46662,
   "name": "charset_0",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 47686,
   "name": "charset_0_continued",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 48700,
   "name": "charset_1",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 49152,
   "name": "charset_1_middle",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50176,
   "name": "charset_1_end",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50660,
   "name": "tape_error",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50661,
   "name": "tape_load",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50665,
   "name": "tape_save",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50666,
   "name": "tape_transfer",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50706,
   "name": "call_sa_bytes",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50713,
   "name": "call_ld_bytes",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50727,
   "name": "tape_check",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50742,
   "name": "tape_loading",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50743,
   "name": "file_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50755,
   "name": "file_name_end",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50756,
   "name": "set_extension",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50765,
   "name": "ext_wizard",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50768,
   "name": "ext_saved_game",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50771,
   "name": "ext_scenario",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50774,
   "name": "designer_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50786,
   "name": "menu_choice",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50787,
   "name": "panel_value_1",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50788,
   "name": "panel_value_2",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50789,
   "name": "save_header",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50805,
   "name": "find_file",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50866,
   "name": "found_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50878,
   "name": "save_wizard",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50913,
   "name": "load_wizard",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50952,
   "name": "load_scenario",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 50984,
   "name": "load_designer",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51021,
   "name": "save_game",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51061,
   "name": "load_game",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51120,
   "name": "sounds",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51248,
   "name": "sound_steps",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51249,
   "name": "sound_repeats",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51250,
   "name": "sound_notes",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51256,
   "name": "speaker",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51257,
   "name": "sound_running",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51258,
   "name": "set_sound",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51277,
   "name": "sound_0",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51278,
   "name": "start_sound",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51286,
   "name": "play_sound",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51347,
   "name": "print_tape_status",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51386,
   "name": "tape_messages",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51395,
   "name": "tape_words",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51428,
   "name": "end_of_turn_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51521,
   "name": "random_wizard",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51571,
   "name": "random_wizard_figures",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51594,
   "name": "draw_frame",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 51755,
   "name": "classify_step",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52012,
   "name": "run_file_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52075,
   "name": "draw_file_panel",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52151,
   "name": "list_wizards",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52233,
   "name": "clear_name_lines",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52281,
   "name": "file_panel",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52337,
   "name": "file_action",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52348,
   "name": "file_actions",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52360,
   "name": "load_wizard_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52413,
   "name": "save_wizard_menu",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52538,
   "name": "ask_file_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52662,
   "name": "show_file_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52667,
   "name": "show_name",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52697,
   "name": "key_table",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52736,
   "name": "panel_messages",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52823,
   "name": "panel_words",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 52970,
   "name": "wizard_1",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 53040,
   "name": "wizard_2",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 53110,
   "name": "wizard_3",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 53180,
   "name": "wizard_4",
   "type": "UserDefined",
   "kind": "user"
  },
  {
   "address": 53250,
   "name": "wizard_list_end",
   "type": "UserDefined",
   "kind": "user"
  }
 ],
 "comments": [
  {
   "address": 24686,
   "type": "line",
   "text": "Flips between 0 and 1 on every interrupt; the interrupt handler does its main work when it flips to 0, so on every second frame."
  },
  {
   "address": 24687,
   "type": "line",
   "text": "The first of the two pointers random_below walks through memory, one byte further on each call."
  },
  {
   "address": 24689,
   "type": "line",
   "text": "The second pointer random_below walks through memory."
  },
  {
   "address": 24691,
   "type": "line",
   "text": "PLAY GAME on the scenario's file panel. Returns at once if no scenario is loaded ($D03F is 0). Otherwise moves the stack to $FFF3, clears the screen and, unless the scenario is for one player ($D048 not 0), asks HOW MANY PLAYERS? (message $E2) and reads the keyboard through the ROM's KEY-SCAN ($028E) until a key from 1 to 4 is pressed, which it prints and keeps in $D067. For each of the four wizard records it clears byte 69, makes a wizard at random if the record has no name (byte 1 is 0, $C941), and sets every spell's current level (low four bits of the 45 spell bytes from byte 2) to its full level (high four bits). In a one-player game (one player chosen, or a one-player scenario) the second player is the computer ($D064 is set and the player count becomes 2): a designed first wizard must have a level equal to the scenario's number or the game stops with an error ($CC39), and the scenario's own wizard, the 70 bytes at $D082, becomes wizard 2. Then runs the scenario's first hook ($D01B) and its start-up routine at $FE03, sets up the map's creatures ($8CFA), fills $FE00-$FF00 with $FF for the interrupt table and runs on into the turn loop."
  },
  {
   "address": 24724,
   "type": "line",
   "text": "KEY-SCAN in the ROM: E is the key's code, which the table at $CDD9 turns into a character."
  },
  {
   "address": 24884,
   "type": "line",
   "text": "The game's turn loop, entered at the start and after every game turn. Puts the stack at $FFF3 and the interrupts in mode 2 with I = $FE (the vector table at $FE00), then runs the independent creatures' turn (player 0) and, for each player from 1 to the player count ($D067), that player's turn: a player with no creature left is skipped; player 2 in a game against the computer ($D064) plays through the computer's turn ($96EB); a human player through $61CD. After each turn the screen is cleared and the per-turn upkeep runs ($796A, $7DBD, $7BE1). When every player has had a turn the turn number at $D065 goes up and the end of the game turn is checked ($C8E4)."
  },
  {
   "address": 24993,
   "type": "line",
   "text": "Looks through the 145 entries of the object table at $5B5A for a creature (type $8D or more) whose owner, in its creature record ($B58F), is the current player ($5B11). Returns Z set when it finds one, Z clear when the player has none."
  },
  {
   "address": 25027,
   "type": "line",
   "text": "Compares the owner (low three bits of byte 4) of the creature record at IY with the current player, $5B11: Z set when the creature is the player's."
  },
  {
   "address": 25037,
   "type": "line",
   "text": "A human player's turn. Sets the interrupt's work flags ($D0DF = 3), shows the turn panel ($9151) and the play screen ($684C, message 2), then loops: reads the controls, opens the cursor menu when fire is pressed ($8ED7), moves the cursor ($629B). While the cursor moves the information display is cleared ($63EA, $913B, flag $D0D7); once it stops, the square under the cursor is described again ($649D, $653E, $6599). The loop ends only when a menu option leaves it."
  },
  {
   "address": 25130,
   "type": "line",
   "text": "The controls chosen at SELECT CONTROLS: 0 keyboard, 1 Kempston joystick, 2 Sinclair joystick. An index into control_handlers."
  },
  {
   "address": 25131,
   "type": "line",
   "text": "Reads the chosen controls through the handler control_handlers names for control_type and stores the result in $5B13: five bits, each 0 while pressed (bit 0 fire, 1 up, 2 down, 3 right, 4 left), the top three bits set."
  },
  {
   "address": 25153,
   "type": "line",
   "text": "The three routines read_controls chooses from: keyboard, Kempston joystick, Sinclair joystick."
  },
  {
   "address": 25159,
   "type": "line",
   "text": "The Sinclair joysticks of Interface 2, which read as the keys 6 to 0 and 1 to 5: reads half-rows $EF (6 to 0) and $F7 (1 to 5), reverses the order of the first five bits of the second and combines the two, so that either joystick reads as fire, up, down, right, left in bits 0 to 4, 0 when pressed."
  },
  {
   "address": 25180,
   "type": "line",
   "text": "The Kempston joystick on port $1F (bits right, left, down, up, fire, 1 when pressed): reorders them into the game's bits (fire, up, down, right, left in bits 0 to 4) and inverts them so that 0 means pressed."
  },
  {
   "address": 25206,
   "type": "line",
   "text": "The keyboard: A from half-row $FD, Q from $FB, P and O from $DF and SPACE from $7F, packed as SPACE in bit 0, Q in bit 1, A in bit 2, P in bit 3 and O in bit 4, 0 when pressed."
  },
  {
   "address": 25243,
   "type": "line",
   "text": "Moves the map cursor by the controls in $5B13; does nothing when no direction is pressed. Up and down move it within the window's seven rows ($5B49, 0 to 6) and scroll the window ($5B4B) at an edge; left and right do the same across ($5B4A, $5B4C). The map position ($5B47 row, $5B48 column) is the window's origin plus the offset, wrapping at 36. While a creature is moving ($FF60 not 0) a step to a square $FF60 or more squares from it ($5B45, distance from $724D) is undone. A move that stands is kept in the saved copies ($D0C8, $D0D1, $D0D3), sets $D0D8 and $D0D0, turns the cursor on for six blinks ($D0D0, $B45B) and redraws the map ($A94C); when bit 2 of $D0DF is set the bars slide ($AB0E) and the icons flash ($AAAF) too."
  },
  {
   "address": 25397,
   "type": "line",
   "text": "Puts back the window origin, the offset in the window and the cursor's map position from their saved copies at $D0C8, $D0D1 and $D0D3."
  },
  {
   "address": 25416,
   "type": "line",
   "text": "Moves the cursor a row up: within the window while its row offset is above 0, otherwise scrolls the window up a row, wrapping from row 0 to 35. Sets $D0D8 to say it moved."
  },
  {
   "address": 25451,
   "type": "line",
   "text": "Moves the cursor a row down: within the window up to offset 6, otherwise scrolls the window down a row, wrapping from 35 to 0. Sets $D0D8."
  },
  {
   "address": 25486,
   "type": "line",
   "text": "Moves the cursor a column left: within the window while its column offset is above 0, otherwise scrolls the window left a column, wrapping from column 0 to 35. Sets $D0D8."
  },
  {
   "address": 25521,
   "type": "line",
   "text": "Moves the cursor a column right: within the window up to offset 6, otherwise scrolls the window right, wrapping from 35 to 0. Sets $D0D8."
  },
  {
   "address": 25556,
   "type": "line",
   "text": "Clears the whole screen: every attribute to 0 (black on black) and every pixel byte to 0 (fill_screen with A = 0)."
  },
  {
   "address": 25557,
   "type": "line",
   "text": "Sets every attribute to A and clears every pixel byte. Entered here with a colour by the end of the game and the designer."
  },
  {
   "address": 25578,
   "type": "line",
   "text": "Clears the information display on the right: the pixels of two rows of icon cells at $5877, and, unless the interrupt's bit 2 is set ($D0DF), of the six more rows below; clears the message line ($6464), the eight entries of the icon list at $B45C, colours the two rows of bars at $5816 and $5836 ($42, red on black, bright) and clears the ten icon flags at $D1A4."
  },
  {
   "address": 25677,
   "type": "line",
   "text": "Clears a 3x3 block of attribute cells at HL (so that nothing in it shows) and returns with HL moved on five cells along the row (the three rows take it $60 on and it takes $5B off), to where the next picture's block starts."
  },
  {
   "address": 25700,
   "type": "line",
   "text": "Clears the message line: the attributes of the bottom two character rows ($5AC0-$5AFF) to 0, and $5B42."
  },
  {
   "address": 25704,
   "type": "line",
   "text": "Fills the attributes of the bottom two character rows with A."
  },
  {
   "address": 25717,
   "type": "line",
   "text": "Prints 32 spaces on each of rows 22 and 23 in the ROM's font ($3C00), blanking the message line's pixels."
  },
  {
   "address": 25757,
   "type": "line",
   "text": "Works out what the cursor's square holds, for the information display. Reads the map byte at the cursor ($D0D3): below $50 it is terrain, kept in $5B10 and $5B12. Otherwise lists the objects lying there ($67A7) and, when the byte is a creature ($8C up), finds the creature ($66A2), keeps the terrain under it (byte 3 of its entry) in $5B10, lists what it carries ($6746) and sets the five icon flags at $D1A4: undead (bit 1 of byte 11 of its type), flying (byte 1 of its type, or a flying potion: $A0 in the top bits of byte 3 of its record), mount (bit 0 of byte 11), fatal wound (top three bits of byte 4 of its record) and invisible (bit 3 of byte 4). Returns with IX on the creature's record."
  },
  {
   "address": 25900,
   "type": "line",
   "text": "The second half of describe_cursor_square for a creature already found: lists the objects on its square and what it carries, keeps the terrain under it in $5B10 and sets the five icon flags."
  },
  {
   "address": 25918,
   "type": "line",
   "text": "Fills the information display's icon list at $B45C from describe_cursor_square's results: the terrain, the object in use ($D0D9, hidden when it is an invisible enemy's), the five icon flags (copied to $D1A9) and up to six objects lying on the square, from the list at $D1D4."
  },
  {
   "address": 26009,
   "type": "line",
   "text": "Prints the name of what is on the cursor's square on the message line: message (map byte + 1) at row 22 in white. A tree or bush square ($3A-$49) also gets the creature that lives in it ($6684). For a creature it finds the creature, prints its rider's mark when it carries one, its owner (\"=\" and the type of the owner's wizard, $6684) when it belongs to a wizard and is not a wizard itself, and, when a second creature shares the square and is visible, that one's owner's number and name."
  },
  {
   "address": 26244,
   "type": "line",
   "text": "Prints \"=\" and then message A (a wizard's or creature's name) after the current print position, in green on black, in the ROM's font."
  },
  {
   "address": 26274,
   "type": "line",
   "text": "Finds the creatures standing at row L, column H (find_creatures_at) and returns in IX the one whose type is in $5B12, or else the second, in $FFF9 too, with its index in $5B58."
  },
  {
   "address": 26310,
   "type": "line",
   "text": "find_creatures_at with no creature excluded."
  },
  {
   "address": 26314,
   "type": "line",
   "text": "find_creatures_at excluding the selected creature, $5B4F."
  },
  {
   "address": 26317,
   "type": "line",
   "text": "Finds up to two creatures (type $8C up) at row L, column H whose byte 4 is $FE or $FF (not riding), skipping the entry whose index is A. The first found goes to $D1AF (entry), $D1AE (type), $D1B1 (index), the second to $D1B3, $D1B2, $D1B5; an index of $FF means none."
  },
  {
   "address": 26433,
   "type": "line",
   "text": "list_carried for the selected creature, $5B4F."
  },
  {
   "address": 26438,
   "type": "line",
   "text": "list_carried for the creature in $5B58."
  },
  {
   "address": 26441,
   "type": "line",
   "text": "Lists the objects carried by creature A (entries whose byte 4 is A) as pairs of index and type at $D1C0, with the count in $D0DE; the one in use (bit 7 of byte 3) also goes to $D0DA (index), $D0DB (entry), $D0D9 (type) and $5B59 (its place in the list plus 1)."
  },
  {
   "address": 26531,
   "type": "line",
   "text": "list_objects_at for the selected position, $5B55."
  },
  {
   "address": 26535,
   "type": "line",
   "text": "Lists the objects ($50-$8B) lying on the ground (byte 4 $FF) and shown (bit 7 of byte 1) at row E, column D: pairs of index and type at $D1D4, the count in $D0DD."
  },
  {
   "address": 26606,
   "type": "line",
   "text": "The terrain under the object, in $5B10; the heaviest object found so far (byte 1 of its type record, from $949D) is kept in $5B2C (type), $5B2D (index) and $5B2E (weight). The list stops at ten objects."
  },
  {
   "address": 26672,
   "type": "line",
   "text": "Clears the attributes of the information display's right-hand area, ten cells wide from $5816, for 21 rows (the select menu's area)."
  },
  {
   "address": 26679,
   "type": "line",
   "text": "The same for 14 rows from $58F6."
  },
  {
   "address": 26700,
   "type": "line",
   "text": "Draws the frame of the information display: twelve rows of panel graphic 4 from the game's own message table, from row 7, column 22 down."
  },
  {
   "address": 26722,
   "type": "line",
   "text": "A creature walking into a square it cannot enter attacks the terrain there. Not allowed when the creature is on the ground and carries nothing that allows it ($5B43 is 0 and $7156 finds nothing): ATTACK NOT ALLOWED. Otherwise needs 6 action points and 6 stamina (NOT ENOUGH ACTION POINTS, NOT ENOUGH STAMINA; for the computer player $D181 is set to 1 instead of a message) and takes 6 of each. A random number against the terrain's toughness (byte 1 of its record, $9124; the creature's strength through $A734) decides whether it breaks; a broken square becomes the terrain named by the top two bits of byte 4 of its record ($68FC) and the map is redrawn when the turn is shown ($D066 is 0)."
  },
  {
   "address": 26876,
   "type": "line",
   "text": "The terrain a destroyed square turns into: the top two bits of byte 4 of the terrain record at IY, as a number from 0 to 3."
  },
  {
   "address": 26884,
   "type": "line",
   "text": "SELECT-A on the cursor menu: selects the flying creature at the cursor ($5B35, index $5B37) and goes on into select mode (select_ground's second half)."
  },
  {
   "address": 26911,
   "type": "line",
   "text": "SELECT-G on the cursor menu, and where RIDE and RIDER start select mode again: selects the creature in $5B38 (index $5B3A). Then select mode: the creature's figures are loaded ($9342), its panel and the moves are drawn ($8FBD, make_selected, $907B) and a loop reads the controls and moves the cursor. Fire on one of the eight squares around the creature (the list at $FF0C) tries a step there: $CA2B and the scenario's hook at $D01E decide what the step means ($FF8F): 5 a move (on the game's first turn the select menu opens instead; made by $B4EB, then the scenario's hook at $D021, a sound and step_effects; ENGAGED TO ENEMY when it ends engaged), 4 an attack ($84EC), 0 an attack on the terrain (attack_terrain), 7 nothing, anything else a message from $B4 up. Fire anywhere else opens the select menu ($6B31)."
  },
  {
   "address": 27149,
   "type": "line",
   "text": "While the cursor moves ($D0D8) the information display is cleared once ($63EA, $913B, $D0D7 set); when it stops it is filled again for the square under the cursor and $D0D7 cleared."
  },
  {
   "address": 27191,
   "type": "line",
   "text": "After a step, puts the cursor on the square the creature stepped to: three plus the step's row and column (from the table at $B49D, entry $FF93) from the window's origin, wrapping at 36; redraws the map and clears the message line."
  },
  {
   "address": 27266,
   "type": "line",
   "text": "Shows message A from the scenario's table on the message line in white, double height, sets $5B42, waits for the controls to be let go and pressed ($91CA, $91DB) and clears the line again."
  },
  {
   "address": 27302,
   "type": "line",
   "text": "END MOVE (select menu option 0), also called by the computer player. Puts the selected creature down where it stands: the map square it left gets back what lay there ($FF90), its position, the terrain under it and its action points and stamina come from the copies at $5B30-$5B34, bit 4 of byte 4 of its record is cleared, and a creature it rides on keeps it as rider. When it is not the computer's turn ($D063 is 0) it also leaves select mode, by discarding its caller's return address."
  },
  {
   "address": 27441,
   "type": "line",
   "text": "The select mode menu, opened by fire away from the creature's neighbouring squares: builds the list of options this creature can take now ($9315 adds one, its name printed in the menu) and dispatches the choice through select_actions. Always END MOVE, CENTRE and BIG MAP; RIDE and RIDER for a mount and a rider; CAST-A and CAST-G for a wizard (type below $90); LAND and FLY when it can fly ($D190, $D191); DROP, CHANGE and PICK UP by what it holds and what lies there (8 action points for PICK UP, 4 for the rest); USE, DRINK, FILL and EAT by the object in use ($73AA, $747E, $74D2); THROW, FIRE and READ by bits of its type record; then the scenario's hook at $D02A, which may add options of its own; and CANCEL."
  },
  {
   "address": 28046,
   "type": "line",
   "text": "The routine of each select menu option: 0 END MOVE, 1 CANCEL (a RET), 2 LAND, 3 FLY, 4 CENTRE, 5 DROP, 6 PICK UP, 7 CHANGE, 8 RIDE, 9 RIDER, $0A USE, $0B DRINK, $0C FILL, $0D EAT, $0E THROW-A, $0F THROW-G, $10 FIRE-A, $11 FIRE-G, $12 CAST-A, $13 CAST-G, $14 BIG MAP and $15 READ, which is the scenario's routine at $D02D."
  },
  {
   "address": 28090,
   "type": "line",
   "text": "Takes A from the selected creature's action points (byte 0 of its record, $5B50) and returns what is left in A."
  },
  {
   "address": 28098,
   "type": "line",
   "text": "Decides whether the select menu offers FLY ($D190) or LAND ($D191). Neither when another creature shares the square or the creature is engaged (bit 4 of byte 4 of its record). A flying creature (byte 4 of its entry $FE) may land unless bit 5 of byte 4 of the square's terrain record forbids it. A creature on the ground may take off unless it stands on water ($37) or gooey blob ($42-$49), the terrain has bit 4 of byte 4 set (a roof), its type has no flying action points ($FF59) or it has fewer than 6 action points."
  },
  {
   "address": 28187,
   "type": "line",
   "text": "LAND (select menu option 2): the creature's entry gets $FF (on the ground) in byte 4, as does $5B2F, and its action points are rescaled from flying to ground ones: ground points ($FF5A) times what it has left over what it started with ($D200), rounded. Sets $FF86 to $0302 and $5B29."
  },
  {
   "address": 28241,
   "type": "line",
   "text": "FLY (select menu option 3): byte 4 of the entry and $5B2F become $FE (in the air), taking off costs 6 action points, and what is left is rescaled to flying points ($FF59) the same way as land does. Sets $FF86 to $0204 and $5B29."
  },
  {
   "address": 28300,
   "type": "line",
   "text": "For the rescaling: BC = (A x 32) / B, by repeated subtraction; 0 when B is 0."
  },
  {
   "address": 28323,
   "type": "line",
   "text": "E = (HL x 32) / BC, rounded to the nearest; 0 when BC is 0. With ratio_divisor it gives HL x B / A."
  },
  {
   "address": 28357,
   "type": "line",
   "text": "The object chooser used by CHANGE and PICK UP: prints the list of objects at HL (pairs of index and type, $5B0A of them) down the screen from row 6, each with its name and its weight (byte 1 of its record, unless $FF), keeps the types at $B474, puts the bar on the current choice ($C662) and lets up and down move it, wrapping, until fire is pressed; returns with the choice in $C662 and the interrupts off."
  },
  {
   "address": 28579,
   "type": "line",
   "text": "Prints the bar graphic (the game's panel graphic 6) in colour A round choice B of the list, at the position the table at $B475 gives; nothing for choice 0."
  },
  {
   "address": 28611,
   "type": "line",
   "text": "Colours two attribute rows of 18 cells, from column 6 of character row B x 2, with A."
  },
  {
   "address": 28644,
   "type": "line",
   "text": "HL = the address of entry A of the object table at $5B5A (six bytes each)."
  },
  {
   "address": 28657,
   "type": "line",
   "text": "DROP (select menu option 5): the object in use ($D0DB) is no longer in use or carried (byte 4 $FF, on the ground), $5B57 is cleared, and a sound plays when the turn is shown ($D066 is 0)."
  },
  {
   "address": 28685,
   "type": "line",
   "text": "CHANGE (select menu option 7): lists what the creature carries (NO OBJECT IN USE first), lets the player choose, and marks the chosen object in use (bit 7 of byte 3) with its type in $5B57. Choosing another than before costs 4 action points."
  },
  {
   "address": 28778,
   "type": "line",
   "text": "PICK UP (select menu option 6): lists the objects lying on the square under CANCEL LIMIT= and the weight the creature can still carry (its type's limit, byte 7, less the weight carried, $712C). A chosen object too heavy for it gives TOO HEAVY; one it can take becomes its object in use, carried by it, plays a sound and costs 8 action points. It asks again while the creature has 8 action points left, objects lie there and it carries fewer than ten."
  },
  {
   "address": 28970,
   "type": "line",
   "text": "Two bytes no instruction reads."
  },
  {
   "address": 28972,
   "type": "line",
   "text": "Adds up the weights (byte 1 of each type record) of the objects the selected creature carries, from the list at $D1C0, into $FF51; creatures carried are not counted."
  },
  {
   "address": 29014,
   "type": "line",
   "text": "Looks for another creature on the selected creature's square at the same height ($5B2F against byte 4 of its entry) that rides nothing, since find_others_at skips riders: a mount the selected creature could climb onto, or a rider that has just got off. Returns Z set with its entry in IX and its index in $D1A3 when there is one, Z clear when not."
  },
  {
   "address": 29070,
   "type": "line",
   "text": "RIDE (select menu option 8): the selected creature climbs onto the mount on its square (find_partner's $D1A3): byte 4 of its entry becomes the mount's index and bit 7 of byte 3 (riding) is set, which costs 10 action points unless it is flying ($5B43). The mount takes over the rider's engaged bit (bit 4 of byte 4 of the record) and becomes the selected creature: select mode starts again on it at select_air's second half."
  },
  {
   "address": 29139,
   "type": "line",
   "text": "RIDER (select menu option 9): the rider the selected mount carries ($D0DA) gets off: it takes the mount's height (byte 4) and loses its riding bit, $5B43 takes that height, and select mode starts again on the rider."
  },
  {
   "address": 29186,
   "type": "line",
   "text": "Lets the player choose a target square for an action with range A ($FF60, the most squares from the creature, $5B45): shows the square under the cursor, sets the interrupt's flags to 5 and moves the cursor until fire is pressed. Keeps $FF86 and the object in use, and puts the in-use type back in $D0D9."
  },
  {
   "address": 29258,
   "type": "line",
   "text": "distance from the selected creature's square, $5B55."
  },
  {
   "address": 29261,
   "type": "line",
   "text": "The distance between square HL and square DE (row in the low byte, column in the high) on the wrapping map, in half squares: twice the longer of the row and column differences plus the shorter, so a step along a row or column counts 2 and a diagonal step 3. From line_setup ($B045)."
  },
  {
   "address": 29280,
   "type": "line",
   "text": "USE (select menu option $0A): the player picks a square next to the creature (range 4, pick_target) and use_square acts on it."
  },
  {
   "address": 29292,
   "type": "line",
   "text": "Uses the object in use on the cursor's square: a key on a locked door ($1F-$21) opens it into a closed door (+3) and the key ($7D) is used up; a closed door ($22-$24) opens (+3); an open door ($25-$27) closes (-3) when no object lies in it; a chest key ($7E) on a locked chest ($7A) unlocks it into a closed chest; a closed chest ($7B) opens into an open chest and the objects in it ($7C entries whose byte 4 is the chest's index) fall out ($A716). Everything else goes to the scenario's hook at $D024: USE by a creature in the air ($5B2F = $FE), a square where a creature stands on the ground or two creatures stand, and a door or chest that does not open, close or unlock (a locked one without its key, an open door with an object in it, an open chest). A change of terrain costs 4 action points, redraws the map and plays a sound."
  },
  {
   "address": 29569,
   "type": "line",
   "text": "Writes the terrain in $5B10 into byte 3 of every entry at row E, column D (keeping bit 7), so that what lies or stands there has the new terrain under it, then $A716."
  },
  {
   "address": 29610,
   "type": "line",
   "text": "Z clear when the select menu should offer DRINK: the object in use is a vial ($73-$79), or the creature is on the ground and a potion in a cauldron ($6B-$71) lies on its square."
  },
  {
   "address": 29648,
   "type": "line",
   "text": "DRINK (select menu option $0B): costs 4 action points and plays a sound. A vial in use ($73-$79) becomes an empty vial ($72) and its potion number is $FF26 (1 to 7), its strength from byte 5 of its entry; otherwise the potion in the cauldron on the square is drunk, one gulp off its count (high four bits of byte 5) and the cauldron empty ($67) when none are left. A healing potion (7) restores stamina and constitution to their starting values and clears the fatal wound; any other sets the creature's potion (byte 3 of its record: the potion number in the top three bits, the turns it lasts in the low five, (strength x 3 + 10) / its potion consumption, type byte 9) and an invisibility potion (3) makes it invisible (bit 3 of byte 4); another potion takes invisibility away except from a pixie ($93)."
  },
  {
   "address": 29822,
   "type": "line",
   "text": "Z set when the select menu should offer FILL: the object in use is an empty vial ($72) and a potion in a cauldron ($6B-$71) lies on the square."
  },
  {
   "address": 29848,
   "type": "line",
   "text": "FILL (select menu option $0C): takes a gulp from the cauldron on the square (high four bits of byte 5; the cauldron is empty, $67, when none are left) into the empty vial in use, which becomes the potion's vial (cauldron type + 8) with the potion's strength. Costs 4 action points."
  },
  {
   "address": 29906,
   "type": "line",
   "text": "Z clear when the select menu should offer EAT: the object in use has bit 2 of byte 5 of its record set."
  },
  {
   "address": 29925,
   "type": "line",
   "text": "EAT (select menu option $0D): costs 4 action points and plays a sound. The object in use is used up (type $FF); its byte 2 restores stamina four times over and constitution once, each up to its starting value ($D201, $D202), and for a wizard byte 3 restores mana ($84D5)."
  },
  {
   "address": 30002,
   "type": "line",
   "text": "END TURN on the cursor menu: asks again with a two-option menu (CANCEL, END TURN). END TURN leaves the human turn's loop by discarding three return addresses; CANCEL goes back."
  },
  {
   "address": 30039,
   "type": "line",
   "text": "The two handlers end_turn's menu dispatches to: option 0, CANCEL ($755D), and option 1, END TURN ($755B)."
  },
  {
   "address": 30043,
   "type": "line",
   "text": "END TURN confirmed: drops three return addresses, which leaves the human turn's loop."
  },
  {
   "address": 30045,
   "type": "line",
   "text": "CANCEL: drops the menu's own return address and goes back to the cursor."
  },
  {
   "address": 30048,
   "type": "line",
   "text": "The upkeep at the start of a player's turn (player $5B11, 0 for the independent creatures). For each of the player's creatures: it is shown (bit 7 of byte 1), its potion counts down a turn (byte 3) and an invisibility potion or being a pixie ($93) keeps it invisible; on the ground it takes damage from what it stands on (8 in tangle vine, $37; another player's or the wild fire, $38-$41, by that fire's strength at $D04B; another player's gooey blob, $42-$49, by $D050) plus twice its fatal wound, through damage_and_rider. A survivor gets its action points back ($D200; halved when its stamina is under a sixth of the most, and divided by the number of times its constitution goes into the most, so whole above half, halved at half or below, a third at a third or below; flying first costs stamina, half its action points), and stamina back, a sixth of the most (a half under a speed or super potion), up to the most. It is made the selected creature, put back on the map and its engaged bit cleared, and the scenario's hook at $D027 runs. Then for a wizard's player: mana goes up by a 25th of the starting mana ($84D5), $D054 counts down, and a human player gets PRESS FIRE TO CONTINUE."
  },
  {
   "address": 30519,
   "type": "line",
   "text": "Makes creature A the one being looked at: $5B58 = A, IX and $FFF9 its entry, IY its type record ($B5A7), IX its record ($B58F); lists what it carries and copies its figures to $D1FB on ($9342)."
  },
  {
   "address": 30549,
   "type": "line",
   "text": "Takes A ($FF2D) from the constitution of creature $FF2B. A blow of more than a quarter of the starting constitution adds one to the fatal wound (top three bits of byte 4, at most 7). If the creature dies: its death is shown ($973C), constitution 0, action points $FF; in a game against the computer a dead computer creature is struck from its list ($994B); it leaves the object table (type $FF) and the map (the terrain under it put back), $FF30 is set, and the player who killed it ($5B26 + 1, when not its owner) gets its victory points (byte 10 of its type, halved unless a wizard struck the blow, $5B27) in $D058, up to 255. What it carried falls to the ground; a rider it carried takes the square on the map when the rider is shown (bit 7 of byte 1 of its entry). A dead computer wizard ($8D) zeroes the computer's points ($D059); a dead wizard is handled by $8C0C. Returns with $FF2E the rider's index when the dead creature was flying, $FF otherwise."
  },
  {
   "address": 30851,
   "type": "line",
   "text": "Z set when the entry at IX has $FE in byte 4: a creature in the air."
  },
  {
   "address": 30857,
   "type": "line",
   "text": "Z set when the entry at IX has $FF in byte 4: a creature on the ground or an object no one carries."
  },
  {
   "address": 30862,
   "type": "line",
   "text": "A = the terrain under the entry at IX (byte 3 without bit 7)."
  },
  {
   "address": 30868,
   "type": "line",
   "text": "E = the row and D = the column of the entry at IX."
  },
  {
   "address": 30876,
   "type": "line",
   "text": "HL = the word at HL + DE: an entry of a table of addresses."
  },
  {
   "address": 30882,
   "type": "line",
   "text": "A = the column of the entry at IX (byte 1 without its top two bits)."
  },
  {
   "address": 30888,
   "type": "line",
   "text": "The plain cursor, for looking round: graphic 1 in colour set 0 ($FF86, $FF87)."
  },
  {
   "address": 30895,
   "type": "line",
   "text": "Adds DE to HL and goes on into value_against_best."
  },
  {
   "address": 30896,
   "type": "line",
   "text": "A = the byte at HL without bit 7, compared with the computer's best value so far ($D19D): carry set when it is smaller, Z when equal."
  },
  {
   "address": 30904,
   "type": "line",
   "text": "Z set when the cursor ($D0D3) is on the selected creature's square ($5B55)."
  },
  {
   "address": 30918,
   "type": "line",
   "text": "A = byte 7 of the selected creature's type record ($5B52): the weight it can carry."
  },
  {
   "address": 30926,
   "type": "line",
   "text": "A = byte 3 of the selected creature's record ($5B50): its potion and the turns left."
  },
  {
   "address": 30934,
   "type": "line",
   "text": "damage_creature, and if the creature dies in the air with a rider, the rider too: 255 points of damage."
  },
  {
   "address": 30957,
   "type": "line",
   "text": "Prints A as a decimal number of up to three digits without leading zeros, padded with spaces after it to three columns."
  },
  {
   "address": 30991,
   "type": "line",
   "text": "One digit of print_number: how many times B goes into A, printed unless it is a leading zero; returns the remainder."
  },
  {
   "address": 31027,
   "type": "line",
   "text": "When enemies are in view ($5B40 on the ground, $5B41 in the air) prints ENEMY SPOTTED with the two counts on the message line and returns Z clear; Z set and nothing printed when there are none."
  },
  {
   "address": 31082,
   "type": "line",
   "text": "Takes every entry of the object table off the map: bits 6 and 7 of its byte 1 are cleared (entry_square, $8C62, leaves the column without them; bit 7 is the shown flag the sight code sets) and its map square gets back the terrain under it (byte 3). Run after each player's turn."
  },
  {
   "address": 31115,
   "type": "line",
   "text": "Shows a blow landing on creature $FFF9, unless the turn is hidden ($D066) or $79F9 says to skip it once (it is cleared either way): its map square briefly shows the hit graphic ($4E) with a sound, flickers once for each point of damage ($FF2D, also in $C839) and, if it died ($FF30), shows the death graphic ($4F) with another sound until the interrupt has moved the counter at ($D032) + $18F from $A5 to $A8. The square then gets back what it showed."
  },
  {
   "address": 31225,
   "type": "line",
   "text": "When not 0, show_hit shows nothing the next time it is called; it clears it."
  },
  {
   "address": 31226,
   "type": "line",
   "text": "THROW-A (select menu option $0E): throw at a flying target ($FF31 = $FE)."
  },
  {
   "address": 31233,
   "type": "line",
   "text": "THROW-G (select menu option $0F): throw at a target on the ground ($FF31 = $FF). Picks the square ($7AC1, range by weight and strength); fire on the thrower's own square cancels. A ground throw at impassable terrain (byte 0 of its record $FF) or a square out of sight gives NO LINE OF SIGHT and asks again."
  },
  {
   "address": 31272,
   "type": "line",
   "text": "The object in use flies to the target square ($D0D3): it lies there, shown, no longer carried, with the square's terrain under it; the flight is drawn (projectile 3, $B5F7, and $AE02 when the turn is shown) and the map updated. If its type does damage when thrown (byte 4 of its record, into $FF62) the creature on that square at the target height takes a ranged blow from the thrower ($85F1). Costs 8 action points; a sound when it is a human's turn."
  },
  {
   "address": 31425,
   "type": "line",
   "text": "Shows the moves, waits for the controls to be let go and lets the player pick a square within throwing range ($7AD4); Z set when the cursor is on the thrower."
  },
  {
   "address": 31444,
   "type": "line",
   "text": "How far an object of type A can be thrown: the thrower's strength ($D1FE) times 2 over the object's weight (byte 1 of its record), plus 5, at most 36."
  },
  {
   "address": 31465,
   "type": "line",
   "text": "Whether the selected creature ($5B55, into $FF88) can see the cursor's square ($D0D3, into $FF4D): with a target in the air, or a thrower in the air, the line is traced at once ($B40F); otherwise a creature under a roof (bit 4 of byte 4 of its square's terrain record) or a target square with one fails without the trace (Z clear). Both on the ground: the ground trace ($B416). Z set when the line is clear."
  },
  {
   "address": 31477,
   "type": "line",
   "text": "The same test for the line from square $FF88 to square $FF4D, with the target's height in $FF31."
  },
  {
   "address": 31537,
   "type": "line",
   "text": "FIRE-A (select menu option $10): fire at a flying target."
  },
  {
   "address": 31544,
   "type": "line",
   "text": "FIRE-G (select menu option $11): fire at a target on the ground."
  },
  {
   "address": 31549,
   "type": "line",
   "text": "Dragons ($90-$92) breathe flame (projectile 0); an archer shoots projectile 1 with a bow ($5C) and projectile 2 with anything else (the magic bow). The computer's target is $FF02; a human picks it within range ($FF60), the shooter's own square cancelling and a square out of sight giving NO LINE OF SIGHT. The flight is drawn when the turn is shown and the target takes the hit ($7A7D). Flame ($FF5D) then sets the target square on fire ($38) when a random number is below its terrain's flammability (low four bits of byte 3 of its record), with $5B22 = $14."
  },
  {
   "address": 31684,
   "type": "line",
   "text": "Sets square $FF88 to the terrain in $5B10 when a random number ($A737) is below B; carry set when it did."
  },
  {
   "address": 31689,
   "type": "line",
   "text": "Sets square $FF88's terrain to $5B10: the entries there get it as the terrain under them and the map square shows it unless something stands on it. Returns with carry set."
  },
  {
   "address": 31713,
   "type": "line",
   "text": "Objects lying loose on water ($36), or in fire or magic fire ($38-$41) unless fireproof (bit 3 of byte 5 of their record), are destroyed (type $FF)."
  },
  {
   "address": 31771,
   "type": "line",
   "text": "Which creatures the big map shows where two share a square: $FE the flying one, $FF the one on the ground. Flipped while the map shows."
  },
  {
   "address": 31772,
   "type": "line",
   "text": "BIG MAP on both menus: draws 23 rows of 31 squares of the map, from 8 rows above and 12 columns left of the window, in the scenario's small font ($D009) with each terrain's character and colour from the table at ($D007), objects as character 8 and creatures as 1 (a wizard), 2 (on the ground) or 3 (in the air) in their owner's colour; frames the view and waits about 100 polls for fire, redrawing only the creatures with the other height each time round."
  },
  {
   "address": 31961,
   "type": "line",
   "text": "One square of the big map's terrain: the map byte's character and colour from ($D007), or character 8 in red for an object; nothing for a creature."
  },
  {
   "address": 32000,
   "type": "line",
   "text": "One square of the big map's creatures: the creature there (the shown one, or the one at the height big_map_height asks for) as character 1, 2 or 3 in colour $47 less its owner."
  },
  {
   "address": 32091,
   "type": "line",
   "text": "Draws the big map's frame: two horizontal lines of 56 points and two vertical lines of 54, with the plotting routine at $ACC9."
  },
  {
   "address": 32164,
   "type": "line",
   "text": "Sets the two terrains spread_magic spreads for the current player: $FF07 its magic fire ($38 + 2 x player: the wild fire for player 0) and $FF06 its gooey blob ($40 + 2 x player; none for player 0)."
  },
  {
   "address": 32189,
   "type": "line",
   "text": "Magic fire and gooey blob grow or die back at the start of each player's turn. Every square of the 36 x 36 map holding the player's magic fire ($FF07) or gooey blob ($FF06) spreads to its neighbours ($7EA5) by the player's strength for it ($D04B or $D04F, indexed by player), as the next type up (newly spread, $FF05), then dies back to the terrain at $D049 (indexed by fire or blob) when a random number against the table at $B4B5 (fire) or $B4AD (blob) for that strength is at least a quarter of the neighbours' susceptibility plus $28. A second pass turns every newly spread square into the ordinary type."
  },
  {
   "address": 32421,
   "type": "line",
   "text": "Spreads the terrain $FF05 from square $D0CC to each of its eight neighbours ($90AB) whose terrain's susceptibility (fire: low four bits of byte 3 of its record; blob: high four bits) is at least a random number plus 1, adding the susceptibilities into $FF0A. Sets $5B22 to $46 less three times A, the strength."
  },
  {
   "address": 32521,
   "type": "line",
   "text": "FLOOD and TANGLE VINE over an area: every square within the spell's level plus 3 ($FF0B, by distance) of the target ($FF94) becomes water ($36) or tangle vine ($37, by $5B21) when a random number is below its terrain's resistance to it (the low or high four bits of byte 2 of its record); $5B22 depends on the distance."
  },
  {
   "address": 32664,
   "type": "line",
   "text": "What the square a creature has stepped onto does ($FF91). On water ($36) a creature on the ground that cannot swim (bit 5 of byte 11 of its type) drowns one time in four: $D181 = 2 and 255 points of damage. On the portal ($35) a wizard escapes: it leaves the map, the objects it carries are taken out of play and their values (byte 0 of their records) and the escape bonus ($D045) added to its player's victory points ($D058), which are kept as the final score at $D05C; $8C0C removes the wizard, $D181 = 3, and its caller's caller is returned to."
  },
  {
   "address": 32871,
   "type": "line",
   "text": "Finds a free entry (type $FF) in the object table from the start: Z set with IX on it and its number counted in $5B1F (which the caller clears), Z clear when the table is full."
  },
  {
   "address": 32879,
   "type": "line",
   "text": "The same from entry 4, leaving the four wizards' entries alone."
  },
  {
   "address": 32908,
   "type": "line",
   "text": "HL = the 70-byte record of the wizard of player A (1 to 4), from wizard_records."
  },
  {
   "address": 32909,
   "type": "line",
   "text": "The same for A from 0 to 3."
  },
  {
   "address": 32920,
   "type": "line",
   "text": "The four wizards' records: $CEEA, $CF30, $CF76 and $CFBC."
  },
  {
   "address": 32928,
   "type": "line",
   "text": "The message number of spell A's name: the 25 summon spells (0-$18) are the creatures ($91 up), $19-$1F the seven potions ($6C up), $20 and $21 magic fire and gooey blob ($42, $43), $22 tangle vine ($38) and $23-$2C flood to magic shield ($D3 up)."
  },
  {
   "address": 32959,
   "type": "line",
   "text": "The spell list a wizard casts from: the wizard's name, MANA, COST and LEVEL, its mana ($D0E0 for the player, into $5B2A), and the 45 spells with their costs and levels ($C98A, $8202). The player chooses one ($8232, into $FF3A; $2D is cancel); a spell with a level left needs 8 action points (NOT ENOUGH ACTION POINTS) and its cost in mana (NOT ENOUGH MANA), and the list is offered again until one can be cast or the player cancels."
  },
  {
   "address": 33134,
   "type": "line",
   "text": "One line of the spell list for spell A: its name in white when it can be cast and in red when not, padded to column 21, then its cost and its level, each blank (black) when the level is 0."
  },
  {
   "address": 33236,
   "type": "line",
   "text": "For spell A of the current wizard ($5B04): $FF0B = its level (the low four bits of its byte at record + 2 + A) and $FF39 its cost, the spell's base cost from the table at $B4BE times the level plus one; both 0 for $2D (cancel). Returns HL on the spell's byte."
  },
  {
   "address": 33282,
   "type": "line",
   "text": "Prints nine lines of the spell list, from four before the current choice ($FF3A) to four after, wrapping round the 46 entries (45 spells and the cancel line, $2D), on every second row from row 3."
  },
  {
   "address": 33330,
   "type": "line",
   "text": "Lets up and down move the spell list's choice ($FF3A), wrapping, reprinting the page each time, until fire is pressed."
  },
  {
   "address": 33382,
   "type": "line",
   "text": "CAST-A (select menu option $12): cast at a flying target ($FF31 = $FE)."
  },
  {
   "address": 33389,
   "type": "line",
   "text": "CAST-G (select menu option $13): cast at a target on the ground ($FF31 = $FF). The wizard picks from the spell list; nothing happens without a spell of level 1 or more. The spell is cast (cast_spell); one that is not refused (carry clear) is paid for (pay_for_spell), and after the spells from magic fire to teleport ($20-$2A) the game waits 20 frames and redraws the moves."
  },
  {
   "address": 33442,
   "type": "line",
   "text": "Pays for spell $FF3A: its current level (the low four bits of its byte in the wizard record) goes down by one, its cost comes off the player's mana ($D0E0), 8 action points are spent and the selected creature's figures are kept ($B5D2)."
  },
  {
   "address": 33495,
   "type": "line",
   "text": "Sends spell $FF3A to its routine: 0-2 the dragons, 3-$18 the other summons, $19-$1F the potions, $20-$23 magic fire, gooey blob, tangle vine and flood ($869D), and $24-$2C through spell_routines. Each returns carry set when the spell is refused and not paid for."
  },
  {
   "address": 33530,
   "type": "line",
   "text": "The routines of the spells from enchant to magic shield ($24-$2C), in order."
  },
  {
   "address": 33548,
   "type": "line",
   "text": "Finds a free creature record (byte 0 $FF) among the 86 at $5EC0, five bytes each, which run up to $606D: Z set with C its number and HL on it, Z clear when all are in use."
  },
  {
   "address": 33568,
   "type": "line",
   "text": "A dragon spell. Cast on the ground when the heaviest object on the square ($5B2C, normally the cauldron) is the matching dragon potion ($68 + spell), it summons the dragon as summon_creature does. Over an empty cauldron ($67) with dragon herb ($53) on the square it brews that potion instead ($848A). Anything else refuses the spell. Cast at the air (CAST-A) it returns with carry clear, so the spell is paid for and nothing happens."
  },
  {
   "address": 33602,
   "type": "line",
   "text": "A summon spell (creature type $90 + spell), refused when cast at the air or by a flying wizard. For each level of the spell, while a free record and a free entry remain, up to 40 random squares among the eight around the wizard ($FF0C) are tried for one that is free (square_free); the creature appears there (create_creature), the square showing the summoning sparkle ($4F) on a human's turn."
  },
  {
   "address": 33702,
   "type": "line",
   "text": "Z set when square $5B23 can take a creature on the ground: its terrain is passable (byte 0 of its record not $FF) and no creature stands there, or only a flying one. Leaves the terrain in $5B10."
  },
  {
   "address": 33755,
   "type": "line",
   "text": "create_creature using any entry of the object table."
  },
  {
   "address": 33763,
   "type": "line",
   "text": "Makes a creature of type $5B25 at square $5B23, owned by the current player, in a free entry (from entry 4) and a free record: its entry holds the square, the type, the terrain under it ($5B10), $FF (on the ground) and the record's number; its record gets its type's action points, stamina and constitution (bytes 0, 2 and 3), no potion and the owner, with a pixie ($93) invisible. On the computer's turn it is added to the computer's list ($A4FA)."
  },
  {
   "address": 33846,
   "type": "line",
   "text": "Plays the summoning sound and waits while the interrupt runs the summoning animation (the counter at ($D032) + $18F from $A5 to $A8), with the sound effect at $C856 going."
  },
  {
   "address": 33893,
   "type": "line",
   "text": "A potion spell ($19-$1F): needs an empty cauldron ($67) on the square and, among the objects there, the potion's ingredient from potion_ingredients; refused otherwise."
  },
  {
   "address": 33930,
   "type": "line",
   "text": "Brews potion $FF26 from ingredient C: refuses (carry) if no object of type C lies on the square; otherwise the ingredient is used up and the cauldron becomes the potion, with the spell's level plus 3 gulps in the high four bits of byte 5 and its strength, the level less 1, in the low four. The square shows the sparkle ($4F) on a human's turn."
  },
  {
   "address": 33998,
   "type": "line",
   "text": "The ingredient each potion spell needs, by spell from $19: mistletoe ($54, strength), clover ($57, protection), crystal ($81, invisibility), sulph ($56, speed), fairy wing ($58, flying), ambergris ($55, super) and apple ($7F, healing)."
  },
  {
   "address": 34005,
   "type": "line",
   "text": "Adds A to the current player's mana ($D0E0), up to the wizard's starting mana (byte 0 of its record)."
  },
  {
   "address": 34028,
   "type": "line",
   "text": "A creature attacks the one it walks into ($FF2A). Needs 8 action points and 8 stamina (NOT ENOUGH ACTION POINTS, NOT ENOUGH STAMINA) and spends them. The attacker strikes (strike); if the defender lives and has 4 action points and 4 stamina left it spends them striking back ($5B0C set). If the attacker dies, $B1A6 runs on its square, $FF86 is reset and select mode ends (its caller's return address is dropped, Z clear). Otherwise the attacker is reloaded and its panel redrawn ($B148)."
  },
  {
   "address": 34237,
   "type": "line",
   "text": "One blow from creature $FF2C at creature $FF2B. $5B26 is the attacker's player less 1, $5B27 is set when the attacker is a wizard, $FF62 its combat ($D1FE). An undead attacker (bit 1 of byte 11 of its type) counts as magic ($FF63)."
  },
  {
   "address": 34289,
   "type": "line",
   "text": "Entered here for a thrown or fired blow: a magic weapon in use ($60-$66 but not $63, the magic bow) counts as magic."
  },
  {
   "address": 34309,
   "type": "line",
   "text": "The blow lands on creature $FF2B: on the computer's turn, an attack that is not a return blow makes it visible. The fight is drawn when the turn is shown ($AEC2). An undead defender takes nothing from a blow that is not magic. Damage is a random number below twice the attack strength plus 2, less the defender's defence ($D1FF); above 0 it is dealt (damage_and_rider) and shown (show_hit)."
  },
  {
   "address": 34398,
   "type": "line",
   "text": "Lets the wizard pick a target square within twice the spell's level plus 7 ($FF0B). Carry set when the cursor is left on the wizard (cancelled). The area spells below enchant ($24) need no line of sight; the others give NO LINE OF SIGHT and ask again until the square can be seen."
  },
  {
   "address": 34444,
   "type": "line",
   "text": "Draws the spell's flight from the wizard to the target (projectile 4, $B5F7 and $AE02), keeping the cursor's square."
  },
  {
   "address": 34461,
   "type": "line",
   "text": "Magic fire, gooey blob, tangle vine and flood ($20-$23): refused when cast at the air; otherwise the wizard picks a square, the bolt flies and area_spell_at takes effect."
  },
  {
   "address": 34482,
   "type": "line",
   "text": "An area spell at square HL ($FF94): the square's susceptibility to it comes from its terrain record (magic fire: low four bits of byte 3; gooey blob: high four bits of byte 3; flood: low four bits of byte 2; tangle vine: high four bits of byte 2), and nothing happens where it is 0. Flood and tangle vine cover an area (flood_area). Magic fire and gooey blob set the player's strength for them from the spell's level ($D04B, and the level less 1 at $D04F, both by player), catch on the square when a random number is below its susceptibility and then spread to its neighbours with twice the strength. The map is redrawn when the turn is shown."
  },
  {
   "address": 34679,
   "type": "line",
   "text": "Clears the screen and draws the panel shown before each turn: for player 0 INDEPENDENT CREATURES in a frame; for a wizard WIZARD ... TURN with its name and the turn number ($D065), with PORTAL and the turns it has left ($D042) once the turn has reached $D062; then the victory points ($8E8A)."
  },
  {
   "address": 34801,
   "type": "line",
   "text": "ENCHANT (spell $24): every ordinary weapon ($59-$5F, sword to axe) carried by the target creature, and by its rider, becomes its magic version (type + 7) for the spell's level plus 3 turns (byte 5); cast on the ground it also enchants the weapons lying on the target's square."
  },
  {
   "address": 34867,
   "type": "line",
   "text": "Enchants the weapons in a list of A pairs of index and type at IX."
  },
  {
   "address": 34911,
   "type": "line",
   "text": "MAGIC BOLT (spell $28): the bolt flies (projectile 5) and the creature at the target's height takes a magic blow of strength four times the level plus $19."
  },
  {
   "address": 34918,
   "type": "line",
   "text": "The bolt at the target already in the cursor's square ($D0D3): where the scenarios' spell routines for the computer enter, having chosen the target themselves."
  },
  {
   "address": 34959,
   "type": "line",
   "text": "A = the index of the creature at square HL at the height $FF31 asks for ($FF when there is none), IX its entry."
  },
  {
   "address": 34987,
   "type": "line",
   "text": "MAGIC LIGHTNING (spell $29), refused to the computer when entered here (the scenarios' own routines enter at magic_lightning_at, past the refusal): a square whose terrain has bit 3 of its flags ($D38E) set cannot be the target. The lightning flies (projectile 6) and strikes the target and its eight neighbours ($90AB) with strength four times the level plus $1E: each square's terrain breaks into its remains when a random number below twice the strength reaches its toughness (byte 1 of its record), and a creature at the target height there takes a magic blow. A wizard caught in its own lightning that dies ends its select mode."
  },
  {
   "address": 35000,
   "type": "line",
   "text": "The lightning once the target is picked (by the player, or by a scenario's routine for the computer, which sets the cursor's square and comes in here)."
  },
  {
   "address": 35162,
   "type": "line",
   "text": "Set by subversion when the target carries a rider, who changes sides too."
  },
  {
   "address": 35163,
   "type": "line",
   "text": "The magic resistance subversion must beat: the target's, or its rider's if higher."
  },
  {
   "address": 35164,
   "type": "line",
   "text": "SUBVERSION (spell $25): fails on a wizard. The target's magic resistance (byte 6 of its type), or its rider's if higher (a wizard rider makes it fail), against a random number; success puts the target, and its rider, on the caster's side (low three bits of byte 4 of the record). SPELL FAILS otherwise."
  },
  {
   "address": 35261,
   "type": "line",
   "text": "Gives the creature record at IY to the current player."
  },
  {
   "address": 35274,
   "type": "line",
   "text": "B = the magic resistance of the creature at IX (byte 6 of its type), IY its record."
  },
  {
   "address": 35284,
   "type": "line",
   "text": "CURSE (spell $26): a random number plus 10 against the target's magic resistance; success gives it the worst fatal wound (all three top bits of byte 4). SPELL FAILS otherwise."
  },
  {
   "address": 35306,
   "type": "line",
   "text": "The start of the spells cast at one creature: the target is picked and the bolt drawn; with no creature at the target height the spell is spent and does nothing (its caller is left, carry clear). Sets $5B22 to eight times the level plus $37 and returns the target's index in C, its resistance in B."
  },
  {
   "address": 35343,
   "type": "line",
   "text": "Magic attack's reach: twice the level plus 1."
  },
  {
   "address": 35344,
   "type": "line",
   "text": "The creature type magic attack strikes."
  },
  {
   "address": 35345,
   "type": "line",
   "text": "The square magic attack was cast at."
  },
  {
   "address": 35347,
   "type": "line",
   "text": "MAGIC ATTACK (spell $27): every creature of the target's type within its reach of the target square that fails a magic resistance check is killed (255 points of damage), each shown with the map redrawn."
  },
  {
   "address": 35465,
   "type": "line",
   "text": "Set while magic eye's sight is being worked out, read by the line of sight ($B1A6, $B2F3)."
  },
  {
   "address": 35466,
   "type": "line",
   "text": "MAGIC EYE (spell $2B): the wizard picks a square within three times the level plus 10, and the sight from there, at the target height ($FF31 into $5B2F; on the ground with the terrain flag at $D38E in $FF4B), is worked out as if a creature stood there ($B1A6), which shows what it sees."
  },
  {
   "address": 35553,
   "type": "line",
   "text": "TELEPORT (spell $2A): into the air only under a flying potion. The wizard picks a square within twice the level plus $1E; the further it is beyond twice the level, the more the landing square is moved at random ($8BB1, by $5B22)."
  },
  {
   "address": 35641,
   "type": "line",
   "text": "The landing square must be free at the target height: in the air its terrain must not have bit 3 of byte 4 set, on the ground it must be passable (byte 0 of its record not $FF). Otherwise SPELL FAILS, and the spell is spent."
  },
  {
   "address": 35689,
   "type": "line",
   "text": "The wizard moves: its old square shows what it left ($FF90), it takes the new square, height and terrain, the new square shows it, and its action points are set to 8, which paying for the spell takes back to 0."
  },
  {
   "address": 35761,
   "type": "line",
   "text": "Adds A to the coordinate at HL and takes B away, wrapping within 0 to 35."
  },
  {
   "address": 35777,
   "type": "line",
   "text": "Once a game turn: every magic weapon ($60-$66) counts down byte 5 and turns back into its ordinary weapon (type - 7) when it reaches 0."
  },
  {
   "address": 35820,
   "type": "line",
   "text": "MAGIC SHIELD (spell $2C): sets the wizard's shield ($D054, by wizard) to the level plus 1, which start_of_turn counts down; the wizard's square shows the sparkle on a human's turn."
  },
  {
   "address": 35852,
   "type": "line",
   "text": "A wizard has died or escaped ($FF05 its type): the screen shows its square, the death animation plays (seven frames, $8C6A) with a sound, and the next show_hit is skipped. One more wizard is out of the game ($D069); when all are, or in a game against the computer when the human's wizard ($8C) is gone (the computer's points then become its score, $D05D), the game ends (game_over)."
  },
  {
   "address": 35938,
   "type": "line",
   "text": "HL = the square of the entry at IX: row in L, column in H."
  },
  {
   "address": 35946,
   "type": "line",
   "text": "One frame of the death animation: the figure $FF05 drawn in colour set $FF07 at the eight points round the middle of the map window, in ten steps one character further out ($FF06) each time, with a step of the sound after each."
  },
  {
   "address": 36047,
   "type": "line",
   "text": "Draws frame $FF07 of figure $FF05 at the screen position $D0D5, $D0D6 ($A84A, $A75E)."
  },
  {
   "address": 36063,
   "type": "line",
   "text": "Copies the current player's wizard name (the ten bytes from byte 59 of its record) into the scenario's table of names at ($D03A), eleven bytes a player."
  },
  {
   "address": 36090,
   "type": "line",
   "text": "Sets up a new game: the portal's turn ($D062) is $D040 plus a random number below $D041; $5B22 = $D043. Each player's wizard (type $8C up) is made on a starting square from the scenario's list at $D072 (its own square in a one-player scenario, otherwise a random one not yet taken), with its scenario data copied in and its mana set from its record ($D0E0). The turn number becomes 1. In a game against the computer the records of wizards 3 and 4 are cleared and the computer's wizard (entry 1, type $8D) goes on the computer's list ($A4FA)."
  },
  {
   "address": 36253,
   "type": "line",
   "text": "Once a game turn: on the portal's turn ($D062) the portal ($35) appears on one of the scenario's squares at $D06A chosen at random (into $D060); after it the turns left ($D042) count down, and the game ends when they run out."
  },
  {
   "address": 36307,
   "type": "line",
   "text": "The end of the game: the final scores ($D05C) become the victory points; the wizard with the most is named with THE WINNER IS, or NOBODY WINS when no one scored, the points are listed and the player presses fire. In a game against the computer won by a designed wizard ($CEEB not 0) with a score, the score goes into its record (byte 69) and its level goes up by one. Then back to the file panel ($C92D)."
  },
  {
   "address": 36433,
   "type": "line",
   "text": "Waits for fire, redrawing the frame in colour $FF53 with PRESS FIRE TO CONTINUE between short waits."
  },
  {
   "address": 36490,
   "type": "line",
   "text": "Lists each player's wizard with a row of dots to column 23 and its victory points ($D058), every third row from row 10."
  },
  {
   "address": 36567,
   "type": "line",
   "text": "Fire on the map in a human's turn: the square is described, and the menu offers SELECT-A and SELECT-G for the player's own creatures there (flying and on the ground), NEXT, INFORM when a creature is there, BIG MAP, END TURN and CANCEL; the choice is dispatched through cursor_actions ($9334), then the panels are drawn again."
  },
  {
   "address": 36752,
   "type": "line",
   "text": "Keeps the player's creature on the ground in $5B38 (index $5B3A) and adds SELECT-G to the menu."
  },
  {
   "address": 36770,
   "type": "line",
   "text": "Keeps the player's flying creature in $5B35 (index $5B37) and adds SELECT-A to the menu."
  },
  {
   "address": 36782,
   "type": "line",
   "text": "INFORM on the cursor menu: the creature's figures are loaded and its panel drawn, until the controls are let go and pressed."
  },
  {
   "address": 36797,
   "type": "line",
   "text": "Draws the creature panel in the information display: the frame and panel graphics 1 and 3, clears the bar values at $D1F6, draws the bars ($ACA6) and lets the interrupt's bar routine ($AB0E) run 96 times to grow them."
  },
  {
   "address": 36843,
   "type": "line",
   "text": "Makes the creature being looked at the selected one: its entry ($5B4D), index ($5B4F), record ($5B50), type record ($5B52), type ($5B54), square ($5B55), terrain ($FF91) and object in use ($5B57); its figures are kept ($B5D2); its height in $5B2F ($FF, or $FE flying, with $FF86 $0302 or $0204); $FF90 what its square will show when it moves off (the heaviest object there, or the terrain, or another creature shown there); $5B29 its engaged bit. Draws its panel ($B148) and, when the turn is shown, the enemy count."
  },
  {
   "address": 36924,
   "type": "line",
   "text": "The address $AA6A works out from HL ($0302 or $0204 at this point) is not used."
  },
  {
   "address": 36987,
   "type": "line",
   "text": "CENTRE (select menu option 4): puts the cursor on the selected creature ($5B55)."
  },
  {
   "address": 36990,
   "type": "line",
   "text": "Puts the cursor on square HL and moves the window so that it is in the middle: origin three rows and three columns before it (wrapping), offset 3, 3."
  },
  {
   "address": 37032,
   "type": "line",
   "text": "list_neighbours for the selected creature's square."
  },
  {
   "address": 37035,
   "type": "line",
   "text": "Lists the eight squares around square HL ($FF88) at $FF0C, three bytes each: the row and column (from the steps at $B49D, wrapping at the edges) and $00 or $80 alternately."
  },
  {
   "address": 37098,
   "type": "line",
   "text": "what_is_at for the cursor's square."
  },
  {
   "address": 37101,
   "type": "line",
   "text": "The terrain at square HL: $5B3B is set to its map address and $5B12 to the map byte; a byte below $50 is the terrain itself, otherwise the terrain under the first entry of the object table on the square. If none is there the border turns yellow, a check left in by the authors."
  },
  {
   "address": 37156,
   "type": "line",
   "text": "terrain_record for the terrain in $FF91."
  },
  {
   "address": 37159,
   "type": "line",
   "text": "IY = the record of terrain A: five bytes each at $D208 in the scenario."
  },
  {
   "address": 37179,
   "type": "line",
   "text": "Waits while a control is held: up to 255 polls of the controls, a short delay before each, returning as soon as none is held."
  },
  {
   "address": 37201,
   "type": "line",
   "text": "NEXT on the cursor menu: steps $5B28 round the object table to the player's next creature (at most 145 tries), shows it on its square (a rider is left to its mount), centres the window on it, describes it and draws its panel, then waits for a control."
  },
  {
   "address": 37321,
   "type": "line",
   "text": "The RET that ends next_creature, which the select menu's CANCEL jumps to."
  },
  {
   "address": 37322,
   "type": "line",
   "text": "Waits, reading the controls, until none is pressed; each poll counts $FFF8 on, which the random numbers use."
  },
  {
   "address": 37339,
   "type": "line",
   "text": "Waits until a control is pressed, counting $FFF8 on."
  },
  {
   "address": 37353,
   "type": "line",
   "text": "Waits until fire is pressed, counting $FFF8 on."
  },
  {
   "address": 37367,
   "type": "line",
   "text": "Adds option A to the menu being built, printing its name (message $AE + A)."
  },
  {
   "address": 37378,
   "type": "line",
   "text": "Runs the menu built with add_menu_option: a frame in red on blue sized to the options, the first option highlighted, up and down moving the highlight with wrap until fire is pressed; the choice is left in $C662."
  },
  {
   "address": 37474,
   "type": "line",
   "text": "Highlights the file panel's current line ($C662) in one of four layouts chosen by $5B0B (from file_layouts): each sets where the bar starts ($5B07 its width) and the lines are two rows apart."
  },
  {
   "address": 37495,
   "type": "line",
   "text": "The four layouts highlight_file_option chooses from: where the bar starts (DE, from the attribute file at $5800) and its width ($5B07)."
  },
  {
   "address": 37503,
   "type": "line",
   "text": "Layout 0, the end of turn menu: a bar twelve cells wide from row 8, column 10."
  },
  {
   "address": 37513,
   "type": "line",
   "text": "Layout 1, the file panel's options: fifteen cells wide from column 0."
  },
  {
   "address": 37523,
   "type": "line",
   "text": "Layout 2, the list of wizards: fourteen cells wide from column 17."
  },
  {
   "address": 37533,
   "type": "line",
   "text": "Layout 3, the SELECT CONTROLS menu at start-up (program_start, in the designer's block): seventeen cells wide from column 7."
  },
  {
   "address": 37543,
   "type": "line",
   "text": "Highlights the menu's current line ($C662): the attributes of 8 cells from $5857 on its row swap ink and paper, bright. Called again it puts them back."
  },
  {
   "address": 37557,
   "type": "line",
   "text": "Swaps ink and paper, bright, in a bar $5B07 cells wide on the line of the choice ($C662, two rows apart and two rows high when $5B06 is set), from the attribute address $5800 + DE, one row down."
  },
  {
   "address": 37631,
   "type": "line",
   "text": "Starts building a menu: prints SELECT OPTION, clears the count ($5B0A), sets the list pointer ($FF84) to $D1E8 and the print position to row 3, column 23."
  },
  {
   "address": 37653,
   "type": "line",
   "text": "Adds option A to the menu list at $D1E8 and counts it."
  },
  {
   "address": 37666,
   "type": "line",
   "text": "Jumps to the handler, in the table at HL, of the option chosen in the menu ($D1E8 entry $C662)."
  },
  {
   "address": 37684,
   "type": "line",
   "text": "The cursor menu's handlers by option: SELECT-A, NEXT, INFORM, BIG MAP, END TURN, CANCEL, SELECT-G."
  },
  {
   "address": 37698,
   "type": "line",
   "text": "Works out the figures of the creature at IX (record) and IY (type) into $D1FB on: action points ($D1FB); flying and ground action points ($FF59, $FF5A; a flying potion gives a creature with no wings twice its ground points to fly with, a speed or super potion doubles both) and the most for its height ($D200); stamina and its most ($D1FC, $D201); constitution and its most ($D1FD, $D202); combat (type byte 4, plus 20 under a strength or super potion, plus the weapon in use's byte 2 for a creature that uses weapons, $D203) divided by the number of times constitution goes into its most, a whole number, so cut only at half or below ($D1FE, at least 1); defence (type byte 5, plus 25 under a protection or super potion, $D204) and the best defence of the weapons it carries."
  },
  {
   "address": 37975,
   "type": "line",
   "text": "A wizard under a magic shield ($D054, by wizard) gets four times the shield plus 12 more defence, up to 255. The defence is then divided by the same number as combat, into $D1FF (at least 1). $5B44 is the index of the creature it carries as rider, or $FD."
  },
  {
   "address": 38045,
   "type": "line",
   "text": "object_record for the type of the entry at IX."
  },
  {
   "address": 38048,
   "type": "line",
   "text": "IY = the record of object type A ($50 up): six bytes each from ($D005) in the scenario."
  },
  {
   "address": 38071,
   "type": "line",
   "text": "A = A / B, by repeated subtraction. Dividing by 0 turns the border magenta and returns 0, a check left in by the authors."
  },
  {
   "address": 38095,
   "type": "line",
   "text": "key_repeat with long waits: $DC polls for a held control the first time, $5A after."
  },
  {
   "address": 38107,
   "type": "line",
   "text": "The wait between moves of a menu bar while a control is held: none once it is let go ($5B1E cleared); otherwise $32 polls ($5B09) the first time and $14 ($5B08) after, each a short delay ($9510), ending early when the control is let go."
  },
  {
   "address": 38160,
   "type": "line",
   "text": "A delay of 2 x 255 turns of an empty loop."
  },
  {
   "address": 38165,
   "type": "line",
   "text": "A delay of $14 x 255 turns."
  },
  {
   "address": 38170,
   "type": "line",
   "text": "A delay of 255 x 255 turns."
  },
  {
   "address": 38175,
   "type": "line",
   "text": "A delay of 8 x 255 turns."
  },
  {
   "address": 38180,
   "type": "line",
   "text": "A delay of $32 x 255 turns."
  },
  {
   "address": 38193,
   "type": "line",
   "text": "The game's own character set, eight bytes a character from character 0, which the panels and boxes are built from (the messages at $CE00 through print_panel): a blank, the frame's corners and edges, the icons of the information display and the bars. 49 characters, to $96B8."
  },
  {
   "address": 38585,
   "type": "line",
   "text": "The counter debug_probe prints."
  },
  {
   "address": 38586,
   "type": "line",
   "text": "A routine nothing calls, left in by the authors: it counts debug_count up, prints it at row 21, column 0, just above the message line, in the ROM's font, yellow on red and waits for the controls to be let go and fire pressed, keeping every register. A breakpoint they could drop into any routine with a CALL."
  },
  {
   "address": 38635,
   "type": "line",
   "text": "A turn the computer plays: the independent creatures' (player 0) and, in a game against the computer, player 2's. $D063 (computer moving) and $D066 (turn hidden) are set while every creature the player owns that is not riding is moved in turn ($974E), $D186 counting the entries of the object table."
  },
  {
   "address": 38716,
   "type": "line",
   "text": "Clears the computer's scratch area $D0E4-$D11F to $FF and $D188."
  },
  {
   "address": 38734,
   "type": "line",
   "text": "Plays one computer creature ($D186): loads it ($98E4) and finds its entry in the computer's list ($994E, into $D182; bit 7 of byte 3 into $D1BA), skipping it when bit 6 of that byte is set (an order to wait), unless it noted an enemy when it was loaded ($D188), which clears the bit. Then up to 50 steps ($9849), each deciding what to do: with no partner on its square, the checks for drinking, eating, using, picking up and spells ($A196, $A382, $A0F0, $A279, $A2FC, $A5BD, $A22B, $9E3A); then the fight and move choices ($9CC5, $9E7D, $9DAD, $A021, $9992, $9A0D, $9858, $A1ED, $9AF3), until $D181 says it is done. Fifty steps turn the border red, a check left in. Then END MOVE."
  },
  {
   "address": 38985,
   "type": "line",
   "text": "The steps computer_move_creature has taken with the current creature."
  },
  {
   "address": 38986,
   "type": "line",
   "text": "Z set when the selected creature stands on the computer's target square ($D1B6)."
  },
  {
   "address": 39000,
   "type": "line",
   "text": "Whether the computer's flying creature should land: not when it is on the ground or done ($D198); a flying creature with no target object or move ($D19B, $D18C) that is not a wizard stays up; otherwise, once it has made its step ($D18E), it lands when it may, unless its target is a chest and it can carry nothing more ($D17A)."
  },
  {
   "address": 39052,
   "type": "line",
   "text": "Lands the selected creature if the rules allow it ($6DC2), reloads it and redraws its panel. Z clear when it landed."
  },
  {
   "address": 39083,
   "type": "line",
   "text": "Makes creature A the one being looked at and the selected one: its square goes to $FF88 and the cursor ($D0D3), it is described, its figures loaded and, when shown, its panel drawn, then make_selected."
  },
  {
   "address": 39140,
   "type": "line",
   "text": "Loads the computer's creature $D186 as the selected one and sets its plan figures: $D17B and $D17C the ranged combat and range of the weapon in use (bow 15 and 16, magic bow 30 and 22; a dragon's breath 35 and 12), $D17A the weight it can still carry, $D17F its type's weapon bit and $D180 its USE bit."
  },
  {
   "address": 39204,
   "type": "line",
   "text": "Copies the computer creature's combat and defence ($D1FE, $D1FF) to $D17D and $D17E."
  },
  {
   "address": 39223,
   "type": "line",
   "text": "DE = the range figures of object A: $100F for a bow ($5C), $161E for a magic bow ($63), 0 for anything else."
  },
  {
   "address": 39243,
   "type": "line",
   "text": "Finds creature A in the computer wizard's list at $CF76."
  },
  {
   "address": 39246,
   "type": "line",
   "text": "Finds creature A in a plan list of four-byte entries ending with $FE: the scenario's list at ($D015) for the independent creatures (player 0), otherwise the computer wizard's at $CF76, the record space of wizard 3, which a game against the computer does not use. An entry is the creature, its route, its step along the route and its orders (bit 7: guard the wizard; bit 6: wait where it is until released; bits 0-5: the group that releases it, release_group). Z set and HL on the entry when found; not found turns the border blue, a check left in."
  },
  {
   "address": 39281,
   "type": "line",
   "text": "DE = square A of the scenario's waypoint table at ($D013), two bytes each, row in E. A is not checked against the table's length: a route naming a waypoint past the end gets the bytes that follow the table."
  },
  {
   "address": 39295,
   "type": "line",
   "text": "HL = the first waypoint of route A in the scenario's route list at ($D00F), where each route starts with its length in the low seven bits."
  },
  {
   "address": 39314,
   "type": "line",
   "text": "Picks the square the computer creature heads for ($D1B6). When it carries treasure for the wizard ($D1BC, from computer_deliver) or it guards the wizard (bit 7 of its orders, $D1BA), the computer's wizard (entry 1 of the object table) while it lives: a guard within five squares of it stops there ($D181 = 5). Otherwise, once the portal is open (turn $D065 at or past $D062), the portal ($D060). Otherwise the next waypoint of its route; on reaching one it moves on to the next, back to the first after the last, and forgets the squares it has walked ($9AB3)."
  },
  {
   "address": 39437,
   "type": "line",
   "text": "Lists the eight squares around the creature, adds to each one's third byte its distance from the target ($D1B6) and sorts them nearest first ($9A48). $D18E is set when the nearest is the target itself."
  },
  {
   "address": 39493,
   "type": "line",
   "text": "The number of comparisons in each pass of sort_neighbours, 7, written once; the passes are counted in B."
  },
  {
   "address": 39494,
   "type": "line",
   "text": "The entry sort_neighbours compares."
  },
  {
   "address": 39496,
   "type": "line",
   "text": "Sorts the eight three-byte squares at $FF0C by the low seven bits of their third byte, the smallest first: a bubble sort of seven passes."
  },
  {
   "address": 39584,
   "type": "line",
   "text": "Where remember_square writes next in trail."
  },
  {
   "address": 39586,
   "type": "line",
   "text": "The last eight squares the computer creature has stood on, two bytes each, ending with $FE."
  },
  {
   "address": 39603,
   "type": "line",
   "text": "Empties trail."
  },
  {
   "address": 39620,
   "type": "line",
   "text": "Z set when square $FF8A is on trail."
  },
  {
   "address": 39644,
   "type": "line",
   "text": "Adds the selected creature's square ($5B55) to trail, over the oldest."
  },
  {
   "address": 39667,
   "type": "line",
   "text": "Tries the eight squares around the creature, nearest the target first, until one works. Each is classified ($CA2B: a diagonal step, bit 7 of its third byte, costs half as much again), the scenario may change the class ($D01E), and the class in $FF8F picks the action from computer_step_actions. When none works the creature is done ($D181 = 6)."
  },
  {
   "address": 39719,
   "type": "line",
   "text": "The action for each class of square: 0 cannot enter, 1 too few action points, 2 too little stamina, 3 a partner there, 4 an enemy, 5 free, 6 free but engaged, 7 just dismounted in the air."
  },
  {
   "address": 39735,
   "type": "line",
   "text": "The creature has done what it can: $D181 = 7."
  },
  {
   "address": 39742,
   "type": "line",
   "text": "Ends the creature's move."
  },
  {
   "address": 39748,
   "type": "line",
   "text": "Attacks the enemy on the square if computer_decide_attack agrees, otherwise tries the next square. After it the creature is done if it died ($D181 = 8), or its combat figures are taken again."
  },
  {
   "address": 39777,
   "type": "line",
   "text": "Attacks the enemy at ($FF28) when the creature has eight action points and eight stamina, unless the enemy is undead and the creature is not, when it needs a magic hand weapon ($60-$66) other than the magic bow ($63). Z clear when it attacked ($84EC) and redrew its panel."
  },
  {
   "address": 39840,
   "type": "line",
   "text": "Steps onto the free square unless the creature is engaged or has stood there lately: moves it ($B4EB), applies the square's effects ($7F98), remembers the square, runs the scenario's step hook ($D021), centres the view and redraws the map when the turn is shown."
  },
  {
   "address": 39883,
   "type": "line",
   "text": "Tries the next square."
  },
  {
   "address": 39886,
   "type": "line",
   "text": "A square it cannot enter. With nothing sharing its square, a creature that can USE opens a closed door ($22-$24) for four action points, or a locked one ($1F-$21) when it carries a key ($7D, made the object in use through computer_take_object); not enough action points ends its move ($D181 = 9). Any other terrain it attacks ($6862) when half as much again as its combat reaches the terrain's toughness."
  },
  {
   "address": 39986,
   "type": "line",
   "text": "Makes object type A the computer creature's object in use. Z set when it already is, or when it is carried ($D1C1, the list of what the creature carries) and four action points are paid: the old object loses its in-use bit (bit 7 of byte 3) and the new one gets it. Carry set when there are not four action points; Z clear when it is not carried."
  },
  {
   "address": 40076,
   "type": "line",
   "text": "Adds enemy creature $5B20, seen by the computer, to its list of enemies at $D0E4 (three bytes each: the creature, its combat and its defence, from $7737), at most 20, and sets $D187."
  },
  {
   "address": 40133,
   "type": "line",
   "text": "A computer creature with a ranged weapon or flame breath ($D17C, its range, not 0) shoots at the first enemy on its list that it can harm: one whose defence plus a half is at most twice the ranged combat ($D17B), not riding, within range and in sight. An undead enemy needs the magic bow, or a dragon's flame on flammable ground. Shooting needs eight action points ($D181 = $0A when there are fewer)."
  },
  {
   "address": 40270,
   "type": "line",
   "text": "Shooting needs eight action points. The reach is $0C squares for a dragon's breath, $10 for a bow and $16 for a magic bow ($FF60); the shot goes only when the line of sight is clear and no longer than that ($FF48). It is fired ($7B3D), costs eight action points, and the creature is looked at again; $D18A says it shot."
  },
  {
   "address": 40365,
   "type": "line",
   "text": "Picks the nearest enemy on the computer's list that the creature could hurt as its target ($D1B6, with $D18C set and the enemy's height in $D18D): one whose defence plus a half is at most twice the creature's combat ($D17D), not riding, at the creature's height unless the creature flies, and for a creature that is not undead hunting an undead one, only while it holds a magic weapon from $60 to $67 other than the magic bow. The range takes in the cauldron ($67), which computer_decide_attack does not, so a creature holding a cauldron can chase an undead enemy it will then not attack."
  },
  {
   "address": 40506,
   "type": "line",
   "text": "A computer creature on the ground that can fly ($FF59) takes off whenever the rules allow it ($6DC2): flying costs six action points, and a creature with fewer than six is done ($D181 = $0B)."
  },
  {
   "address": 40573,
   "type": "line",
   "text": "A creature that is not a guard looks for danger: enemies on its list whose combat plus a half is more than twice its defence ($D17E), leaving out those that cannot fly when it can, and for an undead creature those that are neither undead nor holding a magic weapon. Their squares go to the list at $D120 ($D199 of them). With none, $D198 is cleared. Otherwise it flees ($D198 set; its trail is forgotten when the flight begins): to the first square next to it that no enemy on its list can see and that it can enter ($D19A set), or, when every one is seen or blocked, to the neighbour farthest from the dangerous enemies, by the sum of the distances."
  },
  {
   "address": 40993,
   "type": "line",
   "text": "Picks the object worth going for among those the creature has seen ($D189 of them, their entries listed at $D148), if it carries fewer than ten things. Each object type's worth is in the scenario's table at $D3B9 (0: never); its square must be one the creature can stand on. A locked chest needs a chest key carried; chests are for creatures that can USE; a healing potion is for a creature that has lost constitution and the other potions ($6B-$70) for one with no potion working; anything else must not be too heavy to carry ($D17A). The score is the worth divided by the distance plus one, and the best gives the target square ($D1B6) and the object type ($D19B)."
  },
  {
   "address": 41200,
   "type": "line",
   "text": "On the target object's square, with no partner there ($D181 = $0C otherwise): chests and potions are left to computer_open_chest and computer_drink; anything else is picked up and made the object in use, landing first if the creature flies. It costs eight action points ($D181 = $0D when there are fewer). The weight it can still carry ($D17A) goes down by the object's weight. Ends the step."
  },
  {
   "address": 41366,
   "type": "line",
   "text": "Drinks a potion ($6B-$71) lying on the creature's square ($5B2C): the healing potion only when constitution is below its most, the others only when no potion is working. Costs four action points ($D181 = $0E when there are fewer) and lands the creature first if it flies."
  },
  {
   "address": 41453,
   "type": "line",
   "text": "When the next step reaches a target chest: a locked chest is opened with a chest key made the object in use, then USE ($726C) on the square for four action points; not possible ends the move ($D181 = $0F). Ends the step."
  },
  {
   "address": 41515,
   "type": "line",
   "text": "A creature that uses weapons (bit 2 of byte 11 of its type) holds the best weapon it carries, by the scenario's worth table: swords to axes and their magic kinds ($59-$66), but not shields ($5B, $62)."
  },
  {
   "address": 41593,
   "type": "line",
   "text": "Picks a vial ($73-$79) it carries to drink: the healing vial at once when constitution plus a half is below its most; otherwise the one of highest worth."
  },
  {
   "address": 41676,
   "type": "line",
   "text": "A potion already working is kept when the worth of its vial ($D3B9 + $72 + the potion) is at least that of the best vial. Otherwise the vial is made the object in use and drunk ($73D0) for four action points."
  },
  {
   "address": 41724,
   "type": "line",
   "text": "A creature that can carry things eats the best of the food it carries (bit 2 of byte 5 of the object's record): a wizard scores food by twice the mana it gives (byte 3); otherwise food scores by the constitution it gives (byte 2), and only while constitution plus a half is below its most or stamina is down to a quarter of its most. The food is made the object in use and eaten ($74E5) for four action points."
  },
  {
   "address": 41858,
   "type": "line",
   "text": "A computer wizard (types below $90) with eight action points and no partner on its square casts a spell when enemies are in view ($5B40, $5B41) or it still has half its action points. It tries the spells in the order of the scenario's priorities, the 45 bytes at $D3DC, highest first: a tried spell's priority goes up by one, which marks it (priorities are even), and the marks are cleared when every spell has been tried without a cast."
  },
  {
   "address": 41991,
   "type": "line",
   "text": "Tries spell $FF3A: only with a level left and the mana to pay for it ($D0E1, the computer's mana). Summons other than dragons ($03-$18) go to computer_summon; dragons and potions to computer_brew; the other spells ($20 on) to the scenario's routine for them, from the table at ($D019). Then marks the spell tried."
  },
  {
   "address": 42066,
   "type": "line",
   "text": "Jumps to the scenario's routine for spell A ($20 up), from the table at ($D019)."
  },
  {
   "address": 42079,
   "type": "line",
   "text": "A RET: the scenarios' tables of computer spell routines (scenario_spell) name it for the spells the computer's wizard never casts."
  },
  {
   "address": 42080,
   "type": "line",
   "text": "Casts a summon spell when it leaves at least the scenario's reserve of mana ($D046) or enemies are in view, and there are at least as many free squares round the wizard as the spell's level. A flying wizard lands first. Dragons go to summon_dragon, the rest to summon_creature. After a cast the view is centred, the map redrawn when shown, the spell's priority halved, the spell paid for ($82A2) and the panel redrawn; the step ends."
  },
  {
   "address": 42176,
   "type": "line",
   "text": "The end of every spell the computer's wizard casts, where the scenarios' own spell routines jump too: the view is centred, the map redrawn when the turn is shown, the creature loaded again, the spell's priority halved, the spell paid for ($82A2), and the step ends (three return addresses dropped, back into computer_move_creature at $9817)."
  },
  {
   "address": 42234,
   "type": "line",
   "text": "Adds creature $5B1F to the computer wizard's list at $CF76 (35 entries; a full list turns the border yellow, a check left in). Its route is chosen at random among the scenario's $D047 routes until one suits its type (IY), by the route's flags at ($D011): bit 0 needs a flyer, bit 2 a creature that can carry, bits 1, 3, 4 and 5 the type flags 7, 4, 5 and 6 of byte 11, and bit 6 lets a wizard take it. It starts at the waypoint of the route nearest its square ($5B23). It guards the wizard (bit 7 of its orders) when a random number below 100 is under byte 8 of its type."
  },
  {
   "address": 42429,
   "type": "line",
   "text": "A computer creature (not a wizard, not an independent) carrying treasure for the wizard (types whose worth byte at $D3B9 has bit 7 set; the worthiest in $D1BC) throws it to the wizard when the wizard is within throwing range and in sight: the treasure is made the object in use and thrown ($7A28) for eight action points, then the next. Not possible ends its move ($D181 = $10)."
  },
  {
   "address": 42564,
   "type": "line",
   "text": "Brews for a dragon or potion spell when nothing but the cauldron and ingredients lie on the square: a cauldron ($67) carried is dropped there unless one lies there already, and the ingredient (dragon herb $53 for a dragon; for a potion, from potion_ingredients) likewise, each made the object in use first. Needs eight action points ($D181 = $11 otherwise, ending the step). A dragon spell then goes on as computer_summon, a potion spell brews ($8465) and is paid for as a cast."
  },
  {
   "address": 42718,
   "type": "line",
   "text": "Z clear when the selected creature carries an object of type C (the list at $D1C1)."
  },
  {
   "address": 42729,
   "type": "line",
   "text": "Z clear when an object of type C lies on the selected creature's square (the list at $D1D5)."
  },
  {
   "address": 42752,
   "type": "line",
   "text": "Lets the independent creatures of group B move: clears bit 6 of the orders of every entry in the scenario's list at ($D015) whose group (bits 0-5) is B."
  },
  {
   "address": 42774,
   "type": "line",
   "text": "When square E, D (row, column) is one of the scenario's trip squares, three bytes each at ($D017) ending with $FE (row, column, group), releases that group: opening a door or changing the terrain there wakes the creatures waiting behind it."
  },
  {
   "address": 42804,
   "type": "line",
   "text": "random_below with the limit in A."
  },
  {
   "address": 42807,
   "type": "line",
   "text": "A = a random number below $5B22 (from 1 to 255; with a limit of 0 it never returns, since no number is below 0): the refresh register R exclusive-ored with three bytes 256 apart at each of the two pointers that walk through memory ($606F, $6071) and with the byte at $FFF8, drawn again until it is below the limit. R counts the instructions the processor has run, so the result depends on exactly how long everything before it took."
  },
  {
   "address": 42846,
   "type": "line",
   "text": "draw_block for graphic A in colour set B at the map window's character row $D0D5 and column $D0D6: the three screen lines' addresses go to block_lines from the table at $AF61, the first attribute address to block_attr."
  },
  {
   "address": 42918,
   "type": "line",
   "text": "The screen addresses of the three character rows of the block being drawn."
  },
  {
   "address": 42924,
   "type": "line",
   "text": "The entry of block_lines in use."
  },
  {
   "address": 42926,
   "type": "line",
   "text": "The screen address of the character being drawn."
  },
  {
   "address": 42928,
   "type": "line",
   "text": "The attribute address of the character being drawn."
  },
  {
   "address": 42930,
   "type": "line",
   "text": "The next character number of the graphic being drawn."
  },
  {
   "address": 42932,
   "type": "line",
   "text": "The next attribute of the colour set being drawn."
  },
  {
   "address": 42934,
   "type": "line",
   "text": "Draws graphic A, nine characters in three rows of three (from the scenario's table at ($D038), nine character numbers a graphic, the characters from the set at $D03D), in colour set B (nine attributes a set, from ($D036)): one square of the map."
  },
  {
   "address": 43075,
   "type": "line",
   "text": "draw_block_at for thing A: thing_graphic then the drawing."
  },
  {
   "address": 43082,
   "type": "line",
   "text": "A = the graphic and B = the colour set of thing A (a map byte: terrain, object or creature), from its five-byte entry in the scenario's table at ($D032). Byte 0 picks the character set, from the scenario's table of sets at $D07A, when it is not the one in use ($D03C, address in $D03D). Bytes 3 and 4 are its animation: the frames left and the next frame."
  },
  {
   "address": 43129,
   "type": "line",
   "text": "The interrupt routine, every frame through the vector at $FFFF: interrupts off (DI) at its start, then on every second frame the main work ($A891), on every frame the information display's bars slide when bit 4 of $D0DF is set ($AB0E), and EI before RETI."
  },
  {
   "address": 43153,
   "type": "line",
   "text": "The work of every second frame, keeping the drawing state of the main program: every animated thing (170 five-byte entries in ($D032); a count of $FF is not animated) counts down and at 0 takes its next frame ($A936); the cursor blinks ($AA83); the flashing colour $FF53 takes the next value from the list at $B494. Then by the bits of $D0DF: bit 0 redraws the map window, bit 1 the information display's pictures and icons ($AAA5), bit 2 the first two pictures only ($AA9F), bit 3 the menu bar ($AAD4); with $5B42 set the message line flashes. Restoring the state, the instruction at $A914 reads block_colours instead of writing it back, so a block the main program is drawing when the interrupt comes takes the rest of its attributes from wherever the interrupt's own drawing left the pointer."
  },
  {
   "address": 43317,
   "type": "line",
   "text": "A byte nothing reads."
  },
  {
   "address": 43318,
   "type": "line",
   "text": "The thing whose animation count (its address in HL) has run out takes its next frame: graphic, colour set, count and next frame, four bytes from the scenario's frame table at ($D034)."
  },
  {
   "address": 43340,
   "type": "line",
   "text": "Draws the map window, seven squares by seven from the top left square ($D0C8, row and column, wrapping at 36): each square's thing (map byte), looked up as thing_graphic does, the same steps written out again, except the cursor's square while the cursor is on ($D0D0), which shows the cursor (graphic in $FF86, colour set in $FF87, characters from set 0 at $B646). A sound in progress ($C839) gets a step after each row."
  },
  {
   "address": 43613,
   "type": "line",
   "text": "map_address for the map window's top left square, $D0CC."
  },
  {
   "address": 43618,
   "type": "line",
   "text": "map_address for the cursor's square, $D0D3."
  },
  {
   "address": 43623,
   "type": "line",
   "text": "map_address for the selected creature's square, $5B55."
  },
  {
   "address": 43626,
   "type": "line",
   "text": "HL = the address in the map (36 by 36 bytes at ($D030)) of the square at row L, column H."
  },
  {
   "address": 43651,
   "type": "line",
   "text": "Turns the cursor on ($D0D0) for three calls and off for two, counting in $B45B."
  },
  {
   "address": 43679,
   "type": "line",
   "text": "Redraws the first two pictures of the information display (a first of $FF is skipped)."
  },
  {
   "address": 43685,
   "type": "line",
   "text": "Redraws the eight pictures of the information display, from the list at $B45C (thing, row and column each; the first is the terrain), skipping empty ones after the first, then flashes its icons."
  },
  {
   "address": 43695,
   "type": "line",
   "text": "Colours each icon of the information display that is on ($D1A9-$D1AD: undead, flying, mount, fatal wound, invisible) with the flashing colour $FF53."
  },
  {
   "address": 43732,
   "type": "line",
   "text": "Redraws the menu's pictures ($5B0A of them from $B474), colours the bar on the choice ($C662) with the flashing colour and waits about 167,600 T-states (delay_50, 50 x 255 turns of an empty loop), inside the interrupt."
  },
  {
   "address": 43758,
   "type": "line",
   "text": "Draws B things from a list of three bytes each at HL (thing, row, column), skipping one equal to C (C is 0 after the first)."
  },
  {
   "address": 43790,
   "type": "line",
   "text": "Moves each of the information display's five bars one pixel toward its value: the drawn length at $D1F6 on, the value at $D1FB on (at most $5F), filling or clearing one pixel line of the bar ($AC99)."
  },
  {
   "address": 43863,
   "type": "line",
   "text": "Prints message A from the engine's own text ($CE00 messages, $CE57 words) in its own font ($9531), single height."
  },
  {
   "address": 43891,
   "type": "line",
   "text": "Prints message A of the scenario in single height, unless the computer is moving ($D063)."
  },
  {
   "address": 43904,
   "type": "line",
   "text": "Prints message A of the scenario in double height."
  },
  {
   "address": 43909,
   "type": "line",
   "text": "Prints message A from the scenario's tables ($D00B messages, $D00D words) in the ROM's font ($3C00)."
  },
  {
   "address": 43932,
   "type": "line",
   "text": "Prints message A of the tables at ($FFFB) and ($FFFD) from the start of the line ($5B1A). A message is a length byte then word numbers and control codes; a word is a length byte then characters. Codes: $FF a new line (two lines down in double height), $FE a colour (one byte, two in double height), $FD and $FC turn a gap after each word on and off ($B45A; bit 1 prints a space in it), $FB a position (row and column). $FA in a word is skipped."
  },
  {
   "address": 43997,
   "type": "line",
   "text": "After a word: the gap, when $B45A asks for one."
  },
  {
   "address": 44020,
   "type": "line",
   "text": "HL = entry B of the list at HL, whose entries start with their length (entry 1 is the first); B = its length."
  },
  {
   "address": 44031,
   "type": "line",
   "text": "Acts on control code A ($FB-$FF) at HL; B counts the bytes it uses."
  },
  {
   "address": 44115,
   "type": "line",
   "text": "Prints character A at row $5B15, column $5B16, if the column is below 32: single height ($AF91) or double ($AFE2), by bit 3 of $5B14."
  },
  {
   "address": 44144,
   "type": "line",
   "text": "HL = the screen address of pixel line E, character column D."
  },
  {
   "address": 44167,
   "type": "line",
   "text": "Draws one pixel line of a bar's outline (the two side lines) at line E, column D."
  },
  {
   "address": 44176,
   "type": "line",
   "text": "Draws the top of a bar's outline at line E, column D."
  },
  {
   "address": 44185,
   "type": "line",
   "text": "Inverts the inside of one pixel line of a bar at line E, column D."
  },
  {
   "address": 44198,
   "type": "line",
   "text": "Draws the outlines of the five bars, upward from pixel line $97 in columns $16, $18 ... $1E, each as tall as its most value ($D200 on: action points, stamina, constitution, combat, defence), no higher than line $39."
  },
  {
   "address": 44233,
   "type": "line",
   "text": "Plots the pixel at line $FF33, column $FF34: set, cleared or flipped as $FF32 is 0, 1 or 2; when $FF61 is not $FF its character cell takes that attribute."
  },
  {
   "address": 44317,
   "type": "line",
   "text": "Plots shape $FF5D (from shapes) at the map window's pixel $FF5B, $FF5C, every point inside the window (below $A8)."
  },
  {
   "address": 44366,
   "type": "line",
   "text": "The shapes of a flying missile: offsets (line, column) ending with $7F."
  },
  {
   "address": 44370,
   "type": "line",
   "text": "A cross of five pixels."
  },
  {
   "address": 44381,
   "type": "line",
   "text": "A star of thirteen pixels."
  },
  {
   "address": 44408,
   "type": "line",
   "text": "Where missile_step writes in the tail."
  },
  {
   "address": 44410,
   "type": "line",
   "text": "Empties the missile's tail, $FF5F bytes at $FF65 ending with $FE."
  },
  {
   "address": 44433,
   "type": "line",
   "text": "Draws the missile at its new place ($FF3B, $FF3C), keeps that in the tail and wipes it at the oldest place in the tail."
  },
  {
   "address": 44497,
   "type": "line",
   "text": "Wipes the missile's tail place by place, with a sound step each."
  },
  {
   "address": 44546,
   "type": "line",
   "text": "Draws something flying from the selected creature ($5B55) to the cursor's square ($D0D3), a pixel line at a time ($B0C9, after $B045 has set the line up) from the middle of the map window ($53, $53), $FF5E pixels a frame. Leaving the window moves the view seven squares that way and redraws the map. Every 24 pixels the square under it is checked against the target, and on reaching it the tail is wiped and the hit drawn."
  },
  {
   "address": 44738,
   "type": "line",
   "text": "Draws the hit on square E, D: the burst, graphics $53 to $55 of the scenario's graphics table in colour set 0, from character set 1 ($BE3C), at the square's place in the window, with a step of sound 8 after each; then character set 0 ($B646) is put back."
  },
  {
   "address": 44807,
   "type": "line",
   "text": "The missile has left the map window at the bottom: the window moves seven rows down the map (wrapping at 36) and the missile to its top line; $FF64 says the view moved."
  },
  {
   "address": 44831,
   "type": "line",
   "text": "The missile has left the window at the top: the window moves seven rows up and the missile to its bottom line ($A7)."
  },
  {
   "address": 44852,
   "type": "line",
   "text": "The missile has left the window at the right: the window moves seven columns right and the missile to its left edge."
  },
  {
   "address": 44876,
   "type": "line",
   "text": "The missile has left the window at the left: the window moves seven columns left and the missile to its right edge ($A7)."
  },
  {
   "address": 44897,
   "type": "line",
   "text": "The screen address of each of the 24 character rows."
  },
  {
   "address": 44945,
   "type": "line",
   "text": "Prints character A of the font at ($5B0E) at row $5B15, column $5B16 in attribute $5B17: as it is when bit 0 of $5B14 is set (the engine's own font), otherwise in bold (each line ored with itself moved right by a pixel)."
  },
  {
   "address": 45026,
   "type": "line",
   "text": "Prints character A in double height and bold at rows $5B15 and $5B15 + 1, column $5B16: the top half in attribute $5B17, the bottom in $5B18."
  },
  {
   "address": 45125,
   "type": "line",
   "text": "Sets up a line from square $FF3B to square $FF3D on the wrapping map, the shorter way round each axis: the row and column steps ($FF3F, $FF40: 1 or $FF) and differences ($FF43, $FF44); the longer difference in $FF46 with the step along it alone in $FF41 or $FF42, the shorter in $FF45; the running error ($FF47) at half the longer; the length so far ($FF48) at 0."
  },
  {
   "address": 45257,
   "type": "line",
   "text": "line_step on pixel positions in the map window, which do not wrap."
  },
  {
   "address": 45264,
   "type": "line",
   "text": "Moves the point $FF3B, $FF3C one step along the line: a diagonal step when the error runs out (the length $FF48 goes up by 3), otherwise a step along the longer axis (the length goes up by 2). On the map ($FF35 = 0) the row and column wrap from 0 to 35."
  },
  {
   "address": 45372,
   "type": "line",
   "text": "A row or column of $FF becomes 35 ($23) and one of 36 becomes 0."
  },
  {
   "address": 45384,
   "type": "line",
   "text": "After the selected creature has moved or acted: works out what it sees ($B1A6; from under cover, bit 2 of its terrain's flags at $D38E, it sees less, unless it flies), puts it back on the map, reloads the computer's creature if new enemies were noted ($D187), and for a creature that may be engaged ($5B29) sets or clears its engaged bit (bit 4 of byte 4 of its record) as an enemy stands next to it at its height ($5B3F), unless bit 3 of that byte holds it."
  },
  {
   "address": 45478,
   "type": "line",
   "text": "Works out what can be seen from square HL ($FF88) at the selected creature's height. The reach is $13 half squares on the ground and $17 in the air, nine and eleven squares in a straight line, as the manual says. Every entry of the object table loses its seen mark (bit 6 of byte 1); the viewer has it. Every entry on a square within reach (by the distance's rule, in $FF4F) that is not riding is checked by a line traced over the ground ($B416), with the flags of the terrain it stands on ($FF4A, $FF4C), then see_square. Counts the enemies in view on the ground and in the air ($5B40, $5B41) as it goes."
  },
  {
   "address": 45696,
   "type": "line",
   "text": "Decides, for every entry from $5B1F on that stands on square $FF4D and has no seen mark yet, whether it is seen ($B2E8), and shows on the map the creature seen at the viewer's height, or else one at the other height, or else the heaviest object seen there."
  },
  {
   "address": 45800,
   "type": "line",
   "text": "Whether the entry at IX is seen. An invisible creature (bit 3 of byte 4 of its record) that is not the player's is not, unless the magic eye is open ($8A89). At another height than the viewer's, it is not when the viewer is under cover ($FF4B), or a creature on the ground is under cover ($FF4C). On the ground, a creature in the air is seen; otherwise one next to it ($FF4F below 4) or one the line reaches. In the air, a flying creature is seen; an object on terrain that hides from above ($FF4A) is not; otherwise one next to it or one under open sky. A seen entry is marked shown (bit 7 of byte 1): an object goes on the computer's list of objects seen ($D148, up to 24) and the heaviest object on the square ($5B2C, weight in $5B2E) is kept; an enemy creature loses its invisibility, is counted and noted, and so is a rider it carries."
  },
  {
   "address": 46041,
   "type": "line",
   "text": "Counts an enemy in view at height $D18F ($5B40 on the ground, $5B41 in the air), has the computer note it while it moves ($9C8C), and sets $5B3F when it stands next to the viewer at the same height."
  },
  {
   "address": 46081,
   "type": "line",
   "text": "A way into trace_line with flag $20 that nothing calls."
  },
  {
   "address": 46088,
   "type": "line",
   "text": "A way into trace_line with flag $40 that nothing calls."
  },
  {
   "address": 46095,
   "type": "line",
   "text": "trace_line with terrain flag $10, which blocks sight in the air."
  },
  {
   "address": 46102,
   "type": "line",
   "text": "trace_line with terrain flag $01, which blocks sight on the ground."
  },
  {
   "address": 46107,
   "type": "line",
   "text": "Follows the line from square $FF88 to square $FF4D over the map: Z set (and $FF49 0) when no square on the way has the flag $5B2B among its terrain's flags (the table at $D38E); Z clear and $FF49 = 1 when one blocks it."
  },
  {
   "address": 46170,
   "type": "line",
   "text": "The gap after each word of a message: 0 none, 1 a column skipped, with bit 1 a space printed."
  },
  {
   "address": 46171,
   "type": "line",
   "text": "Counts the calls to blink_cursor left before the cursor changes."
  },
  {
   "address": 46172,
   "type": "line",
   "text": "The information display's eight pictures, three bytes each (thing, row, column): the terrain, the creature, then six objects in two columns."
  },
  {
   "address": 46196,
   "type": "line",
   "text": "The pictures beside the ten lines of a list (choose_from_list), three bytes each, in two columns at rows 3, 7, 11, 15 and 19."
  },
  {
   "address": 46226,
   "type": "line",
   "text": "The next colour of flash_colours."
  },
  {
   "address": 46228,
   "type": "line",
   "text": "The attributes the flashing things cycle through, ending with $FF: bright red, magenta, green, cyan, yellow and back."
  },
  {
   "address": 46237,
   "type": "line",
   "text": "The steps to the eight squares around a square, row then column, clockwise from the one above."
  },
  {
   "address": 46253,
   "type": "line",
   "text": "The chance numbers spread_magic uses for gooey blob dying back, by strength."
  },
  {
   "address": 46261,
   "type": "line",
   "text": "The chance numbers spread_magic uses for magic fire dying back, by strength."
  },
  {
   "address": 46270,
   "type": "line",
   "text": "The base mana cost of each of the 45 spells; a cast costs the base times the spell's level plus one."
  },
  {
   "address": 46315,
   "type": "line",
   "text": "Moves the selected creature to square $FF8A: the old square shows again what lay under it ($FF90), the new one's map byte (at $FF8C) is kept and replaced by the creature. Its terrain becomes $FF91; the step's cost ($FF8E) comes off its action points and half of it off its stamina. What it carries, and its rider or mount, move with it; then update_view."
  },
  {
   "address": 46420,
   "type": "line",
   "text": "Puts the entry at IX on square L (row), H (column), keeping the top two bits of byte 1."
  },
  {
   "address": 46433,
   "type": "line",
   "text": "Moves to square HL, with terrain $FF91, every entry that the selected creature ($5B4F) or its rider ($5B44) carries."
  },
  {
   "address": 46479,
   "type": "line",
   "text": "creature_record for the creature number in byte 5 of the entry at IX."
  },
  {
   "address": 46482,
   "type": "line",
   "text": "IY = the record of creature A: five bytes each at $5EC0 (action points, stamina, constitution, potion, flags)."
  },
  {
   "address": 46503,
   "type": "line",
   "text": "type_record for the type in byte 2 of the entry at IX."
  },
  {
   "address": 46506,
   "type": "line",
   "text": "IY = the record of creature type A: for $90 up, twelve bytes each from ($D003) in the scenario; for a wizard ($8C-$8F), the 23 bytes from byte 47 of the player's wizard record."
  },
  {
   "address": 46546,
   "type": "line",
   "text": "Keeps the selected creature's square, terrain, action points and stamina ($5B30-$5B34)."
  },
  {
   "address": 46583,
   "type": "line",
   "text": "Copies missile style A (eight bytes each from missile_styles) into $FF5D on: shape, pixels a frame, tail length, reach, attribute, combat and magic; and plays its sound (the eighth byte)."
  },
  {
   "address": 46606,
   "type": "line",
   "text": "The missile styles: 0 a dragon's flame (reach $0C, combat 35), 1 an arrow (reach $10, combat 15), 2 a magic arrow (reach $16, combat 30, magic), 3 a thrown object, then the spells' bolts."
  },
  {
   "address": 46662,
   "type": "line",
   "text": "Character set 0 of the map's graphics (the scenario's table at $D07A points to it), which also holds the cursor: here its first 128 characters."
  },
  {
   "address": 47686,
   "type": "line",
   "text": "Character set 0 from its character 128 to the end, $BE3B."
  },
  {
   "address": 48700,
   "type": "line",
   "text": "Character set 1 of the map's graphics, 245 characters, with the burst a hit shows ($AEC2): here its first 56 and a half."
  },
  {
   "address": 49152,
   "type": "line",
   "text": "Character set 1 from $C000, the middle of its character 56, to the middle of character 184."
  },
  {
   "address": 50176,
   "type": "line",
   "text": "The rest of character set 1, to its last character, 244, at $C5DC."
  },
  {
   "address": 50660,
   "type": "line",
   "text": "1 when the last load failed or was broken off with SPACE, 0 when it worked. After a save it is always 1: tape_transfer sets it and only a load that works clears it."
  },
  {
   "address": 50661,
   "type": "line",
   "text": "Loads DE bytes with flag byte B into IX from tape through the ROM's LD-BYTES, entered at $0562 with a white border; tape_error says how it went."
  },
  {
   "address": 50665,
   "type": "line",
   "text": "Saves DE bytes from IX with flag byte B through the ROM's SA-BYTES ($04C6)."
  },
  {
   "address": 50666,
   "type": "line",
   "text": "The common part: A is 1 to load, 0 to save."
  },
  {
   "address": 50706,
   "type": "line",
   "text": "Calls SA-BYTES with tape_check as its return."
  },
  {
   "address": 50713,
   "type": "line",
   "text": "Calls LD-BYTES past its own set-up, with tape_check as its return."
  },
  {
   "address": 50727,
   "type": "line",
   "text": "Where the ROM's tape routines return: SPACE held drops the return address of the caller, so the operation is abandoned with tape_error still 1."
  },
  {
   "address": 50742,
   "type": "line",
   "text": "1 while loading, 0 while saving."
  },
  {
   "address": 50743,
   "type": "line",
   "text": "The twelve characters of the file name the player typed, the last three its extension."
  },
  {
   "address": 50755,
   "type": "line",
   "text": "The $FF after the file name."
  },
  {
   "address": 50756,
   "type": "line",
   "text": "Puts the three characters at HL into the file name's extension."
  },
  {
   "address": 50765,
   "type": "line",
   "text": "The extension of a wizard file."
  },
  {
   "address": 50768,
   "type": "line",
   "text": "The extension of a saved game."
  },
  {
   "address": 50771,
   "type": "line",
   "text": "The extension of a scenario."
  },
  {
   "address": 50774,
   "type": "line",
   "text": "The name of the designer's file."
  },
  {
   "address": 50786,
   "type": "line",
   "text": "The option chosen on the last menu."
  },
  {
   "address": 50787,
   "type": "line",
   "text": "A value the file panels keep (used by the panels at $CC45 and by the designer)."
  },
  {
   "address": 50788,
   "type": "line",
   "text": "A second value the file panels keep."
  },
  {
   "address": 50789,
   "type": "line",
   "text": "Saves the file name as the game's own header (twelve bytes, flag $64) and waits."
  },
  {
   "address": 50805,
   "type": "line",
   "text": "Reads the game's headers from tape (twelve bytes, flag $64, into found_name) until one matches the file name, showing each name found at row $16, column $0B with SEARCHING: and LOADING:. Z set when SPACE was held. Only the first character is compared (B is loaded with 12 but nothing counts it down), so the first file whose name starts with the same letter or digit is taken, whatever its extension."
  },
  {
   "address": 50866,
   "type": "line",
   "text": "The name in the last header read from tape."
  },
  {
   "address": 50878,
   "type": "line",
   "text": "SAVE WIZARD: saves the chosen wizard's 70-byte record ($CEA4 + 70 x (choice + 1)) with a header named with the extension WIZ."
  },
  {
   "address": 50913,
   "type": "line",
   "text": "LOAD WIZARD: finds the file and loads 70 bytes into the chosen wizard's record."
  },
  {
   "address": 50952,
   "type": "line",
   "text": "LOAD SCENARIO: asks for the file name, finds the file (extension GAM) and loads $2FFD bytes at $D003. On success the panel starts again ($CC39); on failure it returns."
  },
  {
   "address": 50984,
   "type": "line",
   "text": "LOAD DESIGNER: finds the file DESIGNER. and loads $0E45 bytes at $D3DC, then starts the designer there."
  },
  {
   "address": 51021,
   "type": "line",
   "text": "Saves the game: asks for the file name and saves a header (extension SVG), the object table and the creature records ($0514 bytes from $5B5A) and everything from $CEEA to the top of memory."
  },
  {
   "address": 51061,
   "type": "line",
   "text": "LOAD SAVED GAME: finds the file and loads its two blocks back, then goes into the game's turn loop; a failure goes back to the panel."
  },
  {
   "address": 51120,
   "type": "line",
   "text": "The game's sixteen sounds, eight bytes each: copied to sound_steps by set_sound."
  },
  {
   "address": 51248,
   "type": "line",
   "text": "How many groups of notes the sound plays."
  },
  {
   "address": 51249,
   "type": "line",
   "text": "How many times each group plays its three notes."
  },
  {
   "address": 51250,
   "type": "line",
   "text": "Three pairs of bytes: how much the note's delay changes after each group, then its delay."
  },
  {
   "address": 51256,
   "type": "line",
   "text": "The last byte sent to the speaker (bit 4)."
  },
  {
   "address": 51257,
   "type": "line",
   "text": "Set while a sound is spread over a drawing, which gives it a step now and then ($C856)."
  },
  {
   "address": 51258,
   "type": "line",
   "text": "Makes sound A the one to play: its eight bytes into sound_steps."
  },
  {
   "address": 51277,
   "type": "line",
   "text": "start_sound for sound 0."
  },
  {
   "address": 51278,
   "type": "line",
   "text": "Sets sound A and plays it at once, unless the turn is hidden ($D066)."
  },
  {
   "address": 51286,
   "type": "line",
   "text": "Plays the sound set up in sound_steps: for each group, each note's delay loop then a click of the speaker, repeated, the delays changing between groups."
  },
  {
   "address": 51347,
   "type": "line",
   "text": "Prints SEARCHING:, LOADING: or FILE NAME: (A = 1 to 3) on row $16, in double height, from the little text tables after it."
  },
  {
   "address": 51386,
   "type": "line",
   "text": "The three messages of print_tape_status, one word each."
  },
  {
   "address": 51395,
   "type": "line",
   "text": "The words of print_tape_status."
  },
  {
   "address": 51428,
   "type": "line",
   "text": "The menu at the end of each game turn (the scenario's message $E8): CONTINUE goes back to the turn loop; ABANDON forgets the scenario ($D03F) and goes back to the file panel; SAVE GAME saves it, but in a game against the computer only five times ($D068 counts; the menu comes back after the fifth)."
  },
  {
   "address": 51521,
   "type": "line",
   "text": "Makes a wizard at random in record $5B04 for a player with none: 80 mana, level 0, each of the 45 spells at a random level from 0 to 2, the standard figures and the name WIZARD followed by the player's number."
  },
  {
   "address": 51571,
   "type": "line",
   "text": "The figures of a wizard made at random (twelve bytes, laid out as a creature type) and its name."
  },
  {
   "address": 51594,
   "type": "line",
   "text": "Draws a frame in the game's own font from row $5B00, column $5B01 to row $5B02, column $5B03 (HL and DE): corners, top and bottom edges, sides."
  },
  {
   "address": 51755,
   "type": "line",
   "text": "Classifies a step of the selected creature to square HL into $FF8F, keeping the square ($FF8A), its map address ($FF8C) and terrain ($FF91): 4 an enemy there at the creature's height (3 when the creature has a partner on its square and did not just dismount); otherwise 7 just dismounted in the air; 0 a square it cannot enter; 1 too few action points for the step's cost ($FF8E, half as much again on a diagonal, $FF92); 2 too little stamina (half the cost); 5 free; 6 free but the creature is engaged. The cost is the terrain's (byte 0 of its record; $FF cannot be entered), 4 for a ghost ($A5) or a flying creature, or 4 when the creature's type flags (bits 4-6 of byte 11) match the terrain's (bits 0-2 of byte 4): swimmers in water, for example. In the air a terrain with bit 3 of byte 4 set cannot be entered."
  },
  {
   "address": 52012,
   "type": "line",
   "text": "Runs a file panel's menu: up and down move the bar over the $5B0A options (menu_choice, wrapping round), with the key repeat; fire chooses, with sound 0."
  },
  {
   "address": 52075,
   "type": "line",
   "text": "Draws the scenario's file panel: the title (message $E6) with the number of the scenario loaded ($D03F, or message $E7 for none) in one frame and the four wizards in another."
  },
  {
   "address": 52151,
   "type": "line",
   "text": "Lists the four wizards from row $11 upward, two rows each: a slot whose record has a level (byte 1) shows the name, copied into the scenario's table of names and printed as message $8C + the player, and the level; an empty one shows message $E7."
  },
  {
   "address": 52233,
   "type": "line",
   "text": "Clears two rows of fourteen characters from the start of the line ($5B1A) in attribute A."
  },
  {
   "address": 52281,
   "type": "line",
   "text": "The scenario's file panel, with the interrupts in mode 1 and the stack at $606E: PLAY GAME, LOAD SCENARIO, LOAD DESIGNER, LOAD WIZARD, LOAD SAVED GAME and SAVE WIZARD, each through file_actions; the option chosen is kept in panel_value_1 while it runs."
  },
  {
   "address": 52337,
   "type": "line",
   "text": "Jumps to the routine for file panel option A."
  },
  {
   "address": 52348,
   "type": "line",
   "text": "The routines of the six options of the file panel."
  },
  {
   "address": 52360,
   "type": "line",
   "text": "LOAD WIZARD: chooses one of the four slots (the one last used, panel_value_2, first), asks for the file name and loads it; a failed load leaves the slot empty (byte 1 cleared). The list is drawn again."
  },
  {
   "address": 52413,
   "type": "line",
   "text": "SAVE WIZARD: chooses a slot and, when it holds a wizard, saves it under a name made of the first word of its name, at most seven letters ($FA counts as a space), followed by its level as a digit (10 and up as A, B ...)."
  },
  {
   "address": 52538,
   "type": "line",
   "text": "FILE NAME: reads up to eight characters into file_name through the ROM's KEY-SCAN, using the key table: ENTER ends it, the 0 key rubs out the last character, symbol shift does nothing; each key gives sound 0 and waits until it is let go."
  },
  {
   "address": 52662,
   "type": "line",
   "text": "Prints the eight characters of the file name."
  },
  {
   "address": 52667,
   "type": "line",
   "text": "Prints B characters from DE in double height from the start of the line, in attribute $46 ($FA as a space)."
  },
  {
   "address": 52697,
   "type": "line",
   "text": "The character of each key, by the number the ROM's KEY-SCAN gives it (0 for symbol shift and ENTER; caps shift, 39, is left out)."
  },
  {
   "address": 52736,
   "type": "line",
   "text": "The engine's own six messages, which draw the information display's frame, icons and bars in the game's font."
  },
  {
   "address": 52823,
   "type": "line",
   "text": "The engine's own fourteen words: rows of characters of the game's font, with colours."
  },
  {
   "address": 52970,
   "type": "line",
   "text": "The first wizard's record, seventy bytes: starting mana, level (0: no wizard), the 45 spells (full level in the high four bits, current in the low), the wizard's figures laid out as a creature type (twelve bytes), its name (ten bytes) and its score. On the tape it holds a wizard named ROGUE, with no level, so the slot counts as empty."
  },
  {
   "address": 53040,
   "type": "line",
   "text": "The second wizard's record. On the tape it is empty but for the standard figures and the name JOE BLOGGS."
  },
  {
   "address": 53110,
   "type": "line",
   "text": "The third wizard's record, which is also the computer's list of creatures in a game against the computer (35 entries of four bytes). On the tape it holds the name WOPPER ZAP."
  },
  {
   "address": 53180,
   "type": "line",
   "text": "The fourth wizard's record. On the tape it holds the name TORQUEMADA."
  },
  {
   "address": 53250,
   "type": "line",
   "text": "The $FE that ends the computer's list at $CF76."
  }
 ]
}