Elixir disassembly ================== Elixir was written by Richard Williams, John Llewellyn and Chris Hyde, and was published by Superior Software for the BBC Micro in 1987. It is a platform puzzle game in which the player must help a shrunken chemist collect pills. The following disassembly was created by reverse engineering binary images, without access to any source code. It is nevertheless reasonably complete, allowing the technical approaches used to be understood. The author of this disassembly imposes no additional copyright restrictions beyond those already present on the game itself. It is provided for educational purposes only, and it is hoped that the original authors will accept it in the good faith it was intended - as a tribute to their skills. Technical notes =============== The introduction and the game share code, and use data from the loader. Interesting pokes ================= &44dd = &a9 infinite lives &3d8f = &ad fall without freefalling &432a = &a9 player is always fast Loader disassembly ================== ; TITLE ; ffff1100 ffff3080 1f8C ; unrelocated_font_data_zero # &1100 - &11ff is a copy of &2b00 - &2bff in INTRO &1100 3c 62 4e 52 4c 60 3c 00 ; &40 ("@") &1108 18 24 24 5c 44 82 c6 00 ; &41 ("A") &1110 38 44 42 7c 42 42 3c 00 ; &42 ("B") &1118 1c 22 40 40 40 42 3c 00 ; &43 ("C") &1120 38 44 42 42 42 44 38 00 ; &44 ("D") &1128 1c 22 40 78 40 42 3c 00 ; &45 ("E") &1130 3c 42 40 78 40 40 e0 00 ; &46 ("F") &1138 1c 22 40 4c 42 42 3c 00 ; &47 ("G") &1140 26 42 42 5e 62 42 64 00 ; &48 ("H") &1148 38 10 10 10 10 10 28 00 ; &49 ("I") &1150 38 46 04 04 04 44 38 00 ; &4a ("J") &1158 c6 44 48 70 48 44 e6 00 ; &4b ("K") &1160 70 20 20 20 20 22 7c 00 ; &4c ("L") &1168 34 4a 49 49 49 41 23 00 ; &4d ("M") &1170 22 52 52 4a 4a 4a 64 00 ; &4e ("N") &1178 38 44 42 42 42 66 3c 00 ; &4f ("O") &1180 5c 22 22 22 3c 20 70 00 ; &50 ("P") &1188 18 24 42 42 4a 4c 32 00 ; &51 ("Q") &1190 7c 22 22 3c 28 24 66 00 ; &52 ("R") &1198 1c 22 20 1c 02 46 3c 00 ; &53 ("S") &11a0 fe 92 10 10 10 10 10 00 ; &54 ("T") &11a8 62 22 42 42 42 46 3a 00 ; &55 ("U") &11b0 c6 42 42 22 24 28 10 00 ; &56 ("V") &11b8 c6 82 92 92 92 94 68 00 ; &57 ("W") &11c0 42 42 24 18 18 24 66 00 ; &58 ("X") &11c8 42 42 44 38 10 10 38 00 ; &59 ("Y") &11d0 3e 42 04 08 10 22 7c 00 ; &5a ("Z") &11d8 38 60 40 40 40 60 38 00 ; &5b ("[") &11e0 10 10 10 92 54 38 10 00 ; &5c ("\", actually down arrow) &11e8 38 0c 04 04 04 0c 38 00 ; &5d ("]") &11f0 10 38 54 92 10 10 10 00 ; &5e ("^", actually up arrow) &11f8 f5 95 85 87 85 95 f5 00 ; &5f ("_") # &1200 - &1aff is moved to &0400 - &0cff at &1c09 ; font_data_two # Characters &80 - &9f are used for Elixir logo &0400 03 0f 1f 3f 3f 7e 7c fc ; &80 &0408 f0 fd ff fe 0e 06 03 03 ; &81 &0410 00 80 00 00 63 7f 3e 3e ; &82 &0418 00 00 00 00 01 07 0c 00 ; &83 &0420 00 03 0f 7f f0 80 00 00 ; &84 &0428 3c ff ff c3 00 00 00 00 ; &85 &0430 00 80 fc ff 07 00 00 00 ; &86 &0438 00 00 00 80 c0 70 1c 00 ; &87 &0440 fc fe ff ff ff fe fc f8 ; &88 &0448 00 38 f0 e0 e0 f0 38 00 ; &89 &0450 3c 1c 1c 1c 1c 1c 1c 1c ; &8a &0458 1c 3e 3e 3e 0c 01 63 3e ; &8b &0460 38 f0 b8 1c 1e 0f 07 07 ; &8c &0468 0e 07 0f 3d 78 f0 e0 c0 ; &8d &0470 38 7c 7c 3c 18 c2 7e 7c ; &8e &0478 00 c0 e4 7e 7f 77 73 61 ; &8f &0480 f8 f8 7c 7e 3f 3f 1f 0f ; &90 &0488 01 03 0e 3e fe ff f9 f0 ; &91 &0490 1c 3c 3c 3c 3e 7e 67 43 ; &92 &0498 3c 3c 3c 3c 3c 7e 7e c7 ; &93 &04a0 07 07 0e 1e 1c 78 78 3c ; &94 &04a8 c0 e0 f0 70 78 3e 1e 38 ; &95 &04b0 7c 78 78 78 78 fc fc 8e ; &96 &04b8 71 70 78 78 78 fc fe 07 ; &97 &04c0 60 38 0f 03 00 00 00 00 ; &98 &04c8 00 00 00 c0 fc 3f 03 00 ; &99 &04d0 00 00 00 00 00 e3 ff 3c ; &9a &04d8 00 00 00 00 0f ff f0 00 ; &9b &04e0 00 00 00 1f ff f0 00 00 ; &9c &04e8 00 00 3f ff c0 00 00 00 ; &9d &04f0 03 ff f8 00 00 00 e3 3f ; &9e &04f8 f0 fc 1e 0e 1e 3c f8 e0 ; &9f ; font_data_one &0500 1c 22 20 78 20 22 5c 00 ; &60 ("`") &0508 00 00 32 4c 44 24 1e 00 ; &61 ("a") &0510 20 40 4c 72 42 44 3c 00 ; &62 ("b") &0518 00 00 1c 62 40 42 3c 00 ; &63 ("c") &0520 04 02 32 4e 42 22 3c 00 ; &64 ("d") &0528 00 00 1c 62 7c 40 3c 00 ; &65 ("e") &0530 00 2c 32 20 7e 20 20 20 ; &66 ("f") &0538 00 3e 44 44 3a 02 44 38 ; &67 ("g") &0540 40 40 5c 62 42 44 4e 00 ; &68 ("h") &0548 00 18 00 08 08 08 10 00 ; &69 ("i") &0550 08 44 3e 04 04 44 38 00 ; &6a ("j") &0558 40 40 4c 58 70 58 4e 00 ; &6b ("k") &0560 00 10 08 08 08 08 04 00 ; &6c ("l") &0568 00 40 3c 2a 2a 2a 62 00 ; &6d ("m") &0570 00 00 1c 62 42 44 4e 00 ; &6e ("n") &0578 00 00 38 44 42 66 3c 00 ; &6f ("o") &0580 00 00 5c 22 22 7c 40 40 ; &70 ("p") &0588 00 18 24 42 5a 4c 36 00 ; &71 ("q") &0590 00 20 1c 12 20 20 30 00 ; &72 ("r") &0598 00 00 1c 22 18 46 3c 00 ; &73 ("s") &05a0 00 10 62 3c 20 22 1c 00 ; &74 ("t") &05a8 00 00 62 22 42 46 3a 00 ; &75 ("u") &05b0 00 00 66 22 12 14 08 00 ; &76 ("v") &05b8 00 c0 82 92 92 92 6c 00 ; &77 ("w") &05c0 00 00 66 18 18 24 66 00 ; &78 ("x") &05c8 00 00 72 22 1e 02 44 38 ; &79 ("y") &05d0 00 00 3e 48 10 22 7c 00 ; &7a ("z") &05d8 f0 e0 c0 f8 80 fc e0 f8 ; &7b ("{", actually left border) &05e0 00 00 00 60 f3 ff ff ff ; &7c ("|", actually bottom border) &05e8 ff ff e7 23 03 02 00 00 ; &7d ("}", actually top border) &05f0 1f 0f 1f 07 01 09 05 0f ; &7e ("~", actually right border) &05f8 f5 95 85 f7 15 95 f5 00 ; &7f (unused copy of &5f, "_") ; circularsaurus_sprite_zero &0600 33 66 66 00 47 9f 9f 00 8f bf 1f 00 af af 6e 00 &0610 67 8f 4c 00 23 0f aa 00 11 0f 5f 00 77 0f 1f 00 &0620 8f 4c 2e 00 8f 0f 4c 00 67 0f 2e 00 11 0f 2e 00 &0630 33 4f 9f 00 47 5f 9f 00 47 df 2e 00 33 22 cc 00 ; circularsaurus_sprite_one &0640 33 11 88 00 47 ab 5d 00 47 6f ab 88 33 2f 4f 88 &0650 11 0f 1f 00 00 8f 1f 00 33 8f 3f 00 47 8f 0f 88 &0660 47 1d 07 88 33 0f 3f 00 00 8f 2e 00 33 0f 1f 00 &0670 57 2f 1f 00 47 6f cf 88 23 cf 8f 88 11 33 77 00 ; circularsaurus_sprite_two &0680 00 66 66 00 00 9f 9f 00 11 3f 2e 88 00 9f 3f 4c &0690 11 cf 0f 4c 23 4f 0f 4c 11 0f 1f 88 00 8f 1f 00 &06a0 00 46 47 88 00 47 0f 4c 00 8f 1f 4c 11 0f 1f 88 &06b0 23 6f cf 88 11 4f 8f 88 00 cf 9f 00 00 33 66 00 ; circularsaurus_sprite_three &06c0 00 11 99 88 00 ef 6f 4c 11 2f 4f 88 11 1f 0f 88 &06d0 00 cf 0f cc 00 47 0f 2e 00 47 0f 2e 00 ab 0f cc &06e0 11 6f 01 88 11 0f 0f 4c 11 0f 0f 2e 00 af 0f ae &06f0 00 67 6f ae 00 47 4f ae 00 47 df ae 00 33 22 44 ; circularsaurus_mask_zero &0700 cc 99 99 ff 88 00 00 ff 00 00 00 ff 00 00 11 ff &0710 88 00 33 ff cc 00 55 ff ee 00 00 ff 88 00 00 ff &0720 00 33 11 ff 00 00 33 ff 88 00 11 ff ee 00 11 ff &0730 cc 00 00 ff 88 00 00 ff 88 00 11 ff cc dd 33 ff ; circularsaurus_mask_one &0740 cc ee 77 ff 88 44 22 ff 88 00 44 77 cc 00 00 77 &0750 ee 00 00 ff ff 00 00 ff cc 00 00 ff 88 00 00 77 &0760 88 22 88 77 cc 00 00 ff ff 00 11 ff cc 00 00 ff &0770 88 00 00 ff 88 00 00 77 cc 00 00 77 ee cc 88 ff ; circularsaurus_mask_two &0780 ff 99 99 ff ff 00 00 ff ee 00 11 77 ff 00 00 33 &0790 ee 00 00 33 cc 00 00 33 ee 00 00 77 ff 00 00 ff &07a0 ff 99 88 77 ff 88 00 33 ff 00 00 33 ee 00 00 77 &07b0 cc 00 00 77 ee 00 00 77 ff 00 00 ff ff cc 99 ff ; circularsaurus_mask_three &07c0 ff ee 66 77 ff 00 00 33 ee 00 00 77 ee 00 00 77 &07d0 ff 00 00 33 ff 88 00 11 ff 88 00 11 ff 44 00 33 &07e0 ee 00 ee 77 ee 00 00 33 ee 00 00 11 ff 00 00 11 &07f0 ff 88 00 11 ff 88 00 11 ff 88 00 11 ff cc dd bb ; os_sound_workspace &0800 ff 00 00 00 00 00 00 00 c0 c0 c0 c0 04 04 04 04 &0810 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0820 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0830 00 00 00 00 00 00 00 00 ff 00 00 00 00 f0 00 0e &0840 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0850 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0860 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0870 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ; labels_table ; addr h w &0880 80 26 0a 04 ; &2680 = acid_label_sprite # &18 : ACID &0884 a0 26 0a 05 ; &26a0 = spirit_label_sprite # &19 : SPIRIT &0888 cc 26 0a 03 ; &26cc = oil_label_sprite # &1a : OIL &088c e4 26 0a 05 ; &26e4 = agar_label_sprite # &1b : AGAR &0890 0c 27 12 08 ; &270c = vanishing_cream_label_sprite # &1c : VANISHING CREAM &0894 93 27 12 04 ; &2793 = iron_pills_label_sprite # &1d : IRON PILLS &0898 b8 0c 08 06 ; &0cb8 = degum_label_sprite # &1e : DEGUM &089c e0 27 08 04 ; &27e0 = soap_label_sprite # &1f : SOAP ; game_colour_string &08a0 13 02 05 00 00 00 ; set colour 2 to magenta (colour is modified) ; game_screen_initialisation_string &08a6 16 05 ; change to MODE 5 &08a8 17 00 0a 20 00 00 00 00 00 00 ; disable cursor ; game_colours_initialisation_string &08b2 13 00 07 00 00 00 ; set colour 0 to white &08b8 13 03 00 00 00 00 ; set colour 3 to black ; unused &08be 00 &08bf 0d ; os_envelope_storage &08c0 00 00 00 00 00 00 00 14 00 00 b0 7e 00 00 00 00 ; 1 # Player walking, drip hitting something &08d0 01 01 02 03 12 16 16 08 fa 00 ff 5a 00 00 00 00 ; 2 # Player jumping &08e0 01 00 00 00 00 00 00 7e ff 00 ff 7e 3f 00 00 00 ; 3 # Player hitting floor, popping balloon, flashbulb or lipstick missiles firing &08f0 01 ff fe fc 02 02 02 50 f0 00 f0 50 12 00 00 00 ; 4 # Player climbing &0900 08 01 fe 01 01 02 01 7e 00 00 82 7e 7e 00 00 00 ; 5 # Collecting yellow pill &0910 00 f0 30 10 03 01 03 7e ff 00 ff 7e 3f 00 00 00 ; 6 # Collecting blue pill, circularsaurus in introduction, initialising missiles &0920 00 10 12 14 01 02 01 08 f4 00 f4 7e 17 00 00 00 ; 7 # Collecting magenta pill, vanishing cream &0930 00 ff fd fb 01 01 01 7e 00 00 82 7e 7e 00 00 00 ; 8 # Collecting cyan pill &0940 80 ff ff ff 03 03 03 20 fb 00 fe 7e 3f 00 00 00 ; 9 # Collecting green pill &0950 80 00 30 00 0b 01 11 73 02 00 ff 73 7e 00 00 00 ; 10 # Collecting red pill, collecting object &0960 80 00 fd 01 01 01 06 5c 22 00 fd 5c 7e 00 00 00 ; 11 # Bouncing iron pill &0970 82 01 01 ff 2f 25 58 01 05 00 fa 0e 76 00 00 00 ; 12 # Spirit &0980 82 01 01 01 77 06 7c 22 02 00 fe 65 7e 00 00 00 ; 13 # Completion &0990 01 00 d8 00 11 01 11 78 01 00 fd 78 7e 00 00 00 ; 14 # Completion &09a0 01 00 fb 00 06 01 06 49 06 00 fe 32 36 00 00 00 ; 15 # Running water ; unused &09b0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ; delay_count &09bf 00 ; inventory_string_addresses &09c0 9f 24 ; &249f = antidote_to_green_pills_string # &00 (OBJECT_ANTIDOTE_TO_GREEN_PILLS) &09c2 00 00 ; &0000 # &01 &09c4 e8 0c ; &0ce8 = a_strong_magnet_string # &02 (OBJECT_STRONG_MAGNET) &09c6 d9 24 ; &24d9 = the_magic_bean_string # &03 (OBJECT_MAGIC_BEAN) &09c8 e9 24 ; &24e9 = an_acid_proof_plaster_string # &04 (OBJECT_ACID_PROOF_PLASTER) &09ca 4c 56 ; &564c = the_spirit_stopper_string # &05 (OBJECT_SPIRIT_STOPPER) &09cc 00 00 ; &0000 # &06 &09ce 00 00 ; &0000 # &07 &09d0 ba 24 ; &24ba = a_sharp_pin_string # &08 (OBJECT_SHARP_PIN) &09d2 00 00 ; &0000 # &09 &09d4 00 00 ; &0000 # &0a &09d6 00 00 ; &0000 # &0b (OBJECT_GAS_TAP) &09d8 00 00 ; &0000 # &0c &09da 00 00 ; &0000 # &0d &09dc 00 00 ; &0000 # &0e &09de 00 00 ; &0000 # &0f &09e0 c6 24 ; &24c6 = a_length_of_thread_string # &10 (OBJECT_LENGTH_OF_THREAD) &09e2 00 00 ; &0000 # &11 &09e4 00 00 ; &0000 # &12 &09e6 00 00 ; &0000 # &13 &09e8 d0 25 ; &25d0 = chewing_gum_string # &14 &09ea dc 25 ; &25dc = an_eye_shield_string # &15 (OBJECT_EYE_SHIELD) &09ec 00 00 ; &0000 # &16 &09ee 00 00 ; &0000 # &17 &09f0 ec 28 ; &28ec = a_covering_of_oil_string # &18 (OBJECT_COVERING_OF_OIL) &09f2 00 00 ; &0000 # &19 ; unused &09f4 00 00 ; &0000 # &1a &09f6 00 00 ; &0000 # &1b &09f8 00 00 ; &0000 # &1c &09fa 00 00 ; &0000 # &1d &09fc 00 00 ; &0000 # &1e &09fe 00 00 ; &0000 # &1f ; shape_data_addresses &0a00 00 20 ; shape &00 : &2000 &0a02 1f 20 ; shape &01 : &201f &0a04 2a 20 ; shape &02 : &202a &0a06 38 20 ; shape &03 : &2038 &0a08 48 20 ; shape &04 : &2048 &0a0a 57 20 ; shape &05 : &2057 &0a0c 60 20 ; shape &06 : &2060 &0a0e 6c 20 ; shape &07 : &206c &0a10 74 20 ; shape &08 : &2074 &0a12 8f 20 ; shape &09 : &208f &0a14 9d 20 ; shape &0a : &209d &0a16 a7 20 ; shape &0b : &20a7 &0a18 ab 20 ; shape &0c : &20ab &0a1a c1 20 ; shape &0d : &20c1 &0a1c d3 20 ; shape &0e : &20d3 &0a1e df 20 ; shape &0f : &20df &0a20 e8 20 ; shape &10 : &20e8 &0a22 01 21 ; shape &11 : &2101 &0a24 08 21 ; shape &12 : &2108 &0a26 14 21 ; shape &13 : &2114 &0a28 23 21 ; shape &14 : &2123 &0a2a 2a 21 ; shape &15 : &212a &0a2c 36 21 ; shape &16 : &2136 &0a2e 47 21 ; shape &17 : &2147 &0a30 50 21 ; shape &18 : &2150 &0a32 5a 21 ; shape &19 : &215a &0a34 60 21 ; shape &1a : &2160 &0a36 6a 21 ; shape &1b : &216a &0a38 71 21 ; shape &1c : &2171 &0a3a 7f 21 ; shape &1d : &217f &0a3c 8d 21 ; shape &1e : &218d &0a3e 9b 21 ; shape &1f : &219b &0a40 a0 21 ; shape &20 : &21a0 &0a42 b1 21 ; shape &21 : &21b1 &0a44 b7 21 ; shape &22 : &21b7 &0a46 c9 21 ; shape &23 : &21c9 &0a48 d6 21 ; shape &24 : &21d6 &0a4a da 21 ; shape &25 : &21da &0a4c df 21 ; shape &26 : &21df &0a4e e2 21 ; shape &27 : &21e2 &0a50 e8 21 ; shape &28 : &21e8 &0a52 fe 21 ; shape &29 : &21fe &0a54 08 22 ; shape &2a : &2208 &0a56 14 22 ; shape &2b : &2214 &0a58 20 22 ; shape &2c : &2220 &0a5a 2a 22 ; shape &2d : &222a &0a5c 34 22 ; shape &2e : &2234 &0a5e 39 22 ; shape &2f : &2239 &0a60 3d 22 ; shape &30 : &223d &0a62 46 22 ; shape &31 : &2246 &0a64 4c 22 ; shape &32 : &224c &0a66 62 22 ; shape &33 : &2262 &0a68 6e 22 ; shape &34 : &226e &0a6a 78 22 ; shape &35 : &2278 &0a6c 85 22 ; shape &36 : &2285 &0a6e 97 22 ; shape &37 : &2297 &0a70 aa 22 ; shape &38 : &22aa &0a72 b5 22 ; shape &39 : &22b5 &0a74 bd 22 ; shape &3a : &22bd &0a76 d5 22 ; shape &3b : &22d5 &0a78 ed 22 ; shape &3c : &22ed &0a7a fa 22 ; shape &3d : &22fa &0a7c f8 0c ; shape &3e : &0cf8 &0a7e fa 14 ; shape &3f : &14fa ; room_data_addresses &0a80 a0 45 ; room &00 : &45a0 &0a82 f4 45 ; room &01 : &45f4 &0a84 39 46 ; room &02 : &4639 &0a86 9c 46 ; room &03 : &469c &0a88 fd 46 ; room &04 : &46fd &0a8a 5f 47 ; room &05 : &475f &0a8c c1 47 ; room &06 : &47c1 &0a8e fd 47 ; room &07 : &47fd &0a90 69 48 ; room &08 : &4869 &0a92 b9 48 ; room &09 : &48b9 &0a94 1c 49 ; room &0a : &491c &0a96 89 49 ; room &0b : &4989 &0a98 e4 49 ; room &0c : &49e4 &0a9a 3f 4a ; room &0d : &4a3f &0a9c a1 4a ; room &0e : &4aa1 &0a9e dd 4a ; room &0f : &4add &0aa0 2f 4b ; room &10 : &4b2f &0aa2 92 4b ; room &11 : &4b92 &0aa4 ff 4b ; room &12 : &4bff &0aa6 5e 4c ; room &13 : &4c5e &0aa8 d8 4c ; room &14 : &4cd8 &0aaa 1b 4d ; room &15 : &4d1b &0aac 5c 4d ; room &16 : &4d5c &0aae aa 4d ; room &17 : &4daa &0ab0 fd 4d ; room &18 : &4dfd &0ab2 80 4e ; room &19 : &4e80 &0ab4 e4 4e ; room &1a : &4ee4 &0ab6 49 4f ; room &1b : &4f49 &0ab8 a1 4f ; room &1c : &4fa1 &0aba ff 4f ; room &1d : &4fff &0abc 74 50 ; room &1e : &5074 &0abe d9 50 ; room &1f : &50d9 &0ac0 2b 51 ; room &20 : &512b &0ac2 85 51 ; room &21 : &5185 &0ac4 f1 51 ; room &22 : &51f1 &0ac6 56 52 ; room &23 : &5256 &0ac8 99 52 ; room &24 : &5299 &0aca dc 52 ; room &25 : &52dc &0acc 2a 53 ; room &26 : &532a &0ace 99 53 ; room &27 : &5399 ; room_edge_edge_data_addresses_low &0ad0 00 ; room edge &00 : &5500 &0ad1 09 ; room edge &01 : &5509 &0ad2 12 ; room edge &02 : &5512 &0ad3 1f ; room edge &03 : &551f &0ad4 28 ; room edge &04 : &5528 &0ad5 2d ; room edge &05 : &552d &0ad6 32 ; room edge &06 : &5532 &0ad7 37 ; room edge &07 : &5537 &0ad8 3c ; room edge &08 : &553c &0ad9 44 ; room edge &09 : &5544 &0ada 4d ; room edge &0a : &554d &0adb 56 ; room edge &0b : &5556 &0adc 5f ; room edge &0c : &555f &0add 69 ; room edge &0d : &5569 &0ade 72 ; room edge &0e : &5572 &0adf 75 ; room edge &0f : &5575 &0ae0 7a ; room edge &10 : &557a &0ae1 89 ; room edge &11 : &5589 &0ae2 98 ; room edge &12 : &5598 &0ae3 a1 ; room edge &13 : &55a1 &0ae4 aa ; room edge &14 : &55aa &0ae5 af ; room edge &55 : &55af &0ae6 b8 ; room edge &16 : &55b8 &0ae7 bb ; room edge &17 : &55bb &0ae8 be ; room edge &18 : &55be &0ae9 c5 ; room edge &19 : &55c5 &0aea ce ; room edge &1a : &55ce &0aeb db ; room edge &1b : &55db &0aec e8 ; room edge &1c : &55e8 &0aed ed ; room edge &1d : &55ed &0aee f6 ; room edge &1e : &55f6 &0aef 00 ; room edge &1f : &5600 &0af0 03 ; room edge &20 : &5603 &0af1 0c ; room edge &21 : &560c &0af2 15 ; room edge &22 : &5615 &0af3 18 ; room edge &23 : &5618 &0af4 23 ; room edge &24 : &5623 &0af5 2f ; room edge &25 : &562f &0af6 38 ; room edge &26 : &5638 &0af7 3b ; room edge &27 : &563b &0af8 42 ; room edge &28 : &5642 &0af9 15 ; room edge &29 : &5615 &0afa 12 ; room edge &2a : &5612 &0afb 15 ; room edge &2b : &5615 &0afc 15 ; room edge &2c : &5615 &0afd 38 ; room edge &2d : &5638 ; unused &0afe 00 00 ; unused &0b00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0b10 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0b20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0b30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0b40 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0b50 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0b60 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &0b70 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ; group_offsets &0b80 00 00 &0b82 40 01 &0b84 80 02 &0b86 c0 03 &0b88 00 05 &0b8a 40 06 &0b8c 80 07 &0b8e c0 08 &0b90 00 0a &0b92 40 0b &0b94 80 0c &0b96 c0 0d &0b98 00 0f &0b9a 40 10 &0b9c 80 11 &0b9e c0 12 &0ba0 00 14 &0ba2 40 15 &0ba4 80 16 &0ba6 c0 17 &0ba8 00 19 &0baa 40 1a &0bac 80 1b &0bae c0 1c &0bb0 00 1e &0bb2 40 1f &0bb4 80 20 &0bb6 c0 21 &0bb8 00 23 &0bba 40 24 &0bbc 80 25 &0bbe c0 26 ; completion_room_data &0bc0 7b c1 dc ; shape at x:&41, y:&dc, type &3b &0bc3 7c d9 8e ; shape at x:&59, y:&8e, type &3c &0bc6 7c da 8f ; shape at x:&5a, y:&8f, type &3c &0bc9 7c a9 8e ; shape at x:&29, y:&8e, type &3c &0bcc 7c a8 8f ; shape at x:&28, y:&8f, type &3c &0bcf 1b 50 ; fill at y:&50, pattern &b &0bd1 6f c1 6e ; shape at x:&41, y:&6e, type &2f &0bd4 1b 6c ; fill at y:&6c, pattern &b &0bd6 1b 23 ; fill at y:&23, pattern &b &0bd8 6f 11 ; shape at x:&11, type &2f &0bda 1b 6c ; fill at y:&6c, pattern &b &0bdc 1b 5a ; fill at y:&5a, pattern &b &0bde 6f 71 ; shape at x:&71, type &2f &0be0 1b 6c ; fill at y:&6c, pattern &b &0be2 1b 5a ; fill at y:&5a, pattern &b &0be4 7d c1 90 ; shape at x:&41, y:&90, type &3d &0be7 15 78 ; fill at y:&78, pattern &5 &0be9 7e c1 be ; shape at x:&41, y:&be, type &3e &0bec 8d ; string, length &0d &0bed 1f 07 1d ; TAB(&07, &1d) &0be0 74 68 61 6e 6b 73 21 ; "thanks!" &0bf7 1f 06 1e ; TAB(&06, &1e) &0bfa 03 ; use common update routine &0bfb 00 ; end of room data ; unused &0bfc 00 00 00 00 ; player_starting_positions ; y x &0c00 63 30 ; room &00 &0c02 91 5a ; room &01 &0c04 61 2a ; room &02 &0c06 23 08 ; room &03 &0c08 c7 40 ; room &04 &0c0a a9 7e ; room &05 &0c0c b5 84 ; room &06 &0c0e c9 91 ; room &07 &0c10 0d 66 ; room &08 &0c12 29 58 ; room &09 &0c14 0d 7a ; room &0a &0c16 bf 35 ; room &0b &0c18 39 2c ; room &0c &0c1a c5 07 ; room &0d &0c1c a9 0f ; room &0e &0c1e 99 6f ; room &0f &0c20 a7 82 ; room &10 &0c22 11 8a ; room &11 &0c24 35 70 ; room &12 &0c26 bd 5c ; room &13 &0c28 8b 3c ; room &14 &0c2a 8b 1c ; room &15 &0c2c c1 17 ; room &16 &0c2e 13 05 ; room &17 &0c30 a9 64 ; room &18 &0c32 19 67 ; room &19 &0c34 c7 82 ; room &1a &0c36 8f 4a ; room &1b &0c38 b1 5e ; room &1c &0c3a b9 80 ; room &1d &0c3c b1 6e ; room &1e &0c3e a3 79 ; room &1f &0c40 99 6e ; room &20 &0c42 c9 8a ; room &21 &0c44 c9 73 ; room &22 &0c46 c9 7c ; room &23 &0c48 c9 36 ; room &24 &0c4a 61 0b ; room &25 &0c4c a9 16 ; room &26 &0c4e 9d 24 ; room &27 ; room_flags # Values are overwritten &0c50 2a 2a 2a 2a 2a 2a 2a 2a ; "******** # &0c50 - &0c97 are all &ff in PIAS version &0c58 2a 20 20 54 6f 20 20 2a ; "* To * &0c60 2a 53 48 41 52 4f 4e 2a ; "*SHARON* &0c68 2a 20 77 69 74 68 20 2a ; " with * &0c70 2a 20 61 6c 6c 20 20 2a ; "* all * ; objects_collected # Values are overwritten &0c78 2a 20 20 6d 79 20 20 2a ; "* my * &0c80 2a 20 6c 6f 76 65 20 2a ; "* love * &0c88 2a 20 43 48 52 49 53 2a ; "* CHRIS* &0c90 2a 2a 2a 2a 2a 2a 2a 2a ; "******** ; fill_patterns &0c98 fa f5 ; 3232 2323 &0c9a af 5f ; 3131 1212 &0c9c a5 5a ; 2121 1212 &0c9e 55 aa ; 0303 3030 &0ca0 a0 50 ; 2020 0202 &0ca2 0a 05 ; 1010 0101 &0ca4 50 ff ; 0202 3333 &0ca6 05 ff ; 0101 3333 &0ca8 50 00 ; 0202 0000 &0caa 05 00 ; 0101 0000 &0cac f0 f0 ; 2222 2222 &0cae ff ff ; 3333 3333 &0cb0 0f 0f ; 1111 1111 &0cb2 af 5a ; 3131 1212 &0cb4 a0 5f ; 2020 1313 &0cb6 5a a0 ; 1212 2020 ; degum_label_sprite # Object type &1e &0cb8 88 00 00 00 00 00 b8 00 20 00 00 00 a8 b0 40 50 &0cc8 60 80 a8 a0 40 50 50 40 a8 b0 50 50 50 40 a8 a0 &0cd8 50 50 50 40 b8 30 20 20 50 40 88 00 00 00 00 00 ; a_strong_magnet_string &0ce8 61 20 73 74 72 6f 6e 67 20 6d 61 67 6e 65 74 00 ; "a strong magnet" ; shape_3e_data &0cf8 d0 a2 c8 00 ; unused &0cfc 00 00 00 00 ; font_data_three &1b00 00 0f 19 1c 0f 03 19 0f ; &a0 &1b08 00 00 a2 22 22 a2 b6 1c ; &a1 &1b10 00 00 f3 8a 9b f2 82 c3 ; &a2 &1b18 00 00 de 51 13 1e 52 db ; &a3 &1b20 00 00 4e 5b 51 51 5b 4e ; &a4 &1b28 00 00 78 44 4c 78 48 6c ; &a5 &1b30 00 0f 19 1c 0f 03 19 0f ; &a6 &1b38 00 00 9c 36 22 a2 b6 1c ; &a7 &1b40 00 00 fb 8a 80 f0 80 81 ; &a8 &1b48 00 00 ec a8 89 8d 8f c6 ; &a9 &1b50 00 00 67 2d 28 68 ef c8 ; &aa &1b58 00 00 3c a2 a6 bc a4 b6 ; &ab &1b60 00 00 f8 88 e0 80 88 f8 ; &ac &1b68 00 1f 19 10 19 1f 18 18 ; &ad &1b70 00 00 bc a2 a6 3c 24 36 ; &ae &1b78 00 00 f9 8a e1 80 8a f9 ; &af &1b80 00 00 cf 28 8e c8 28 cf ; &b0 &1b88 00 00 a2 b2 2a 2a a6 a2 ; &b1 &1b90 00 00 f9 aa 21 20 22 71 ; &b2 &1b98 00 00 c0 2c 8c c0 2c cc ; &b3 ; title_entry_point &1ba0 a9 c8 LDA #&c8 ; Read/Write BREAK/ESCAPE effect &1ba2 a2 03 LDX #&03 ; Clear memory on next RESET &1ba4 20 f4 ff JSR &fff4 ; OSBYTE &1ba7 a9 0f LDA #&0f # Use OS font for characters &20 - &7f &1ba9 8d 67 03 STA &0367 ; os_font_flag &1bac a9 12 LDA #&12 ; &1200 = unrelocated_font_data_two &1bae 8d 6b 03 STA &036b ; os_font_locations + 3 &1bb1 a9 1b LDA #&1b ; &1b00 = font_data_three &1bb3 8d 6c 03 STA &036c ; os_font_locations + 4 &1bb6 ae 30 fe LDX &fe30 ; Paged ROM latch &1bb9 a9 80 LDA #&80 # Use ANDY RAM for &8000 - &8fff if Master &1bbb 8d 30 fe STA &fe30 ; Paged ROM latch &1bbe a0 00 LDY #&00 ; copy_to_andy_loop &1bc0 b9 00 11 LDA &1100,Y ; unrelocated_font_data_zero # Copy &1100 - &11ff to &8a00 - &8aff &1bc3 99 00 8a STA &8a00,Y &1bc6 b9 00 13 LDA &1300,Y ; unrelocated_font_data_one # Copy &1300 - &13ff to &8b00 - &8bff &1bc9 99 00 8b STA &8b00,Y &1bcc b9 00 12 LDA &1200,Y ; unrelocated_font_data_two # Copy &1200 - &12ff to &8c00 - &8cff &1bcf 99 00 8c STA &8c00,Y &1bd2 b9 00 1b LDA &1b00,Y ; font_data_three # Copy &1b00 - &1bff to &8d00 - &8dff &1bd5 99 00 8d STA &8d00,Y &1bd8 c8 INY &1bd9 d0 e5 BNE &1bc0 ; copy_to_andy_loop &1bdb 8e 30 fe STX &fe30 ; Paged ROM latch &1bde a2 00 LDX #&00 &1be0 a0 4e LDY #&4e ; write_initialise_screen_loop &1be2 bd 31 1c LDA &1c31,X ; initialise_screen_text &1be5 20 ee ff JSR &ffee ; OSWRCH &1be8 e8 INX &1be9 88 DEY &1bea d0 f6 BNE &1be2 ; write_initialise_screen_loop &1bec a2 14 LDX #&14 ; copy_loading_screen_loop # Move &1c7f - &307e to &6200 - &75ff &1bee b9 7f 1c LDA &1c7f,Y ; loading_screen_data # actually LDA loading_screen_source_address,Y &1bf1 99 00 62 STA &6200,Y # actually STA loading_screen_target_address,Y &1bf4 c8 INY &1bf5 d0 f7 BNE &1bee ; copy_loading_screen_loop &1bf7 ee f0 1b INC &1bf0 ; loading_screen_source_address_high &1bfa ee f3 1b INC &1bf3 ; loading_screen_target_address_high &1bfd ca DEX &1bfe d0 ee BNE &1bee ; copy_loading_screen_loop &1c00 a9 0f LDA #&0f &1c02 20 f4 ff JSR &fff4 ; OSBYTE &1c05 a2 09 LDX #&09 &1c07 a0 00 LDY #&00 ; move_1200_to_1aff_loop # Move &1200 - &1aff to &0400 - &0cff &1c09 b9 00 12 LDA &1200,Y # actually LDA source_address,Y &1c0c 99 00 04 STA &0400,Y # actually STA target_address,Y &1c0f c8 INY &1c10 d0 f7 BNE &1c09 ; move_1200_to_1aff_loop &1c12 ee 0b 1c INC &1c0b ; source_address_high &1c15 ee 0e 1c INC &1c0e ; target_address_high &1c18 ca DEX &1c19 d0 ee BNE &1c09 ; move_1200_to_1aff_loop ; delay_loop &1c1b 88 DEY &1c1c ea NOP &1c1d ea NOP &1c1e d0 fb BNE &1c1b ; delay_loop &1c20 ca DEX &1c21 d0 f8 BNE &1c1b ; delay_loop &1c23 a2 2a LDX #&2a ; &1c2a = run_intro_string &1c25 a0 1c LDY #&1c &1c27 4c f7 ff JMP &fff7 ; OSCLI # *RUN Intro ; run_intro_string &1c2a 2f 49 6e 74 72 6f 0d ; "/Intro" ; initialise_screen_text &1c31 16 05 ; MODE 5 &1c33 11 81 ; COLOUR 129 &1c35 0c ; clear screen &1c36 0a ; move cursor down one line &1c37 a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 aa ab ac ad ae af ; plot "SUPERIOR SOFTWARE PRESENTS:" &1c47 b0 b1 b2 b3 &1c4b 1c 06 08 0d 03 ; define text window x:(&06, &0d), y:(&03, &08) &1c50 80 81 82 83 84 85 86 87 88 89 8a 8b 8c 8d 8e 8f ; plot "Elixir" &1c60 90 91 92 93 94 95 96 97 98 99 9a 9b 9c 9d 9e 9f &1c70 1c 01 1d 12 19 ; define text window x:(&01, &12), y:(&19, &1d) &1c75 17 01 00 00 00 00 00 00 00 00 ; disable cursor ; loading_screen_data &1c7f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1c8f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1c9f 1c 2c 1c 2c 0f 0f 0f 0f 50 a0 50 a0 7d 7a 7d 7a &1caf 41 a1 41 a1 87 8f 87 8f 0f 0f 0f 0f 0f 0f 0f 0f &1cbf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1ccf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1cdf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1cef 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1cff 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1d0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1d1f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1d2f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1d3f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1d4f 0f 0f 0f 0f 0f 0f 0f 0f 0f 1e 1e 1e 1e 1e 1e 1e &1d5f 0f 87 87 87 c3 83 c3 83 0f 0f 1e 2d 1e 2f 1f 2f &1d6f 0f 0f 0f 87 0f 0f 07 0f 0f 0f 0f 0f 0f 0f 0f 7a &1d7f 0f 0f 0f 1e 1f 1e 3d 3e 0f 0f 0f cb c7 a9 c1 a9 &1d8f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f cf cf cf &1d9f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1daf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1dbf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1dcf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 2f 2f &1ddf 0f 0f 0f 0f 0f 0f 0f 0f 7d 7a 7d 7a 7d 7a f5 fa &1def 87 0f 87 8f 87 8f f7 eb 0f 0f 0f 0f 0f 0f 4f 0f &1dff 0f 0f 0f 0f 0f 0f 8f 8f 0f 0f 0f 0f 0f 0f 0f 0f &1e0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1e1f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1e2f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1e3f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1e4f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0e 0e 0e &1e5f 0f 0f 0f 0f 0f 00 0f 0f 0f 0f 0f 0f 0f 00 0f 0e &1e6f 0f 0f 0f 0f 0f 00 0f 0f 0f 0f 0f 0f 0f 01 0d 0d &1e7f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1e8f 0f 0f 0f 0f 0f 0c 0d 0c 3c 3c 3c 3d 3d 71 78 78 &1e9f 43 cb cf cf cf ec c1 a1 1f 2f 5f 2f 5f 27 5f 2f &1eaf 07 0f 07 0b 07 08 0f 8f 7c 6a 5c 68 5c 62 7c 2e &1ebf 3d 3e 3d 3e 3d 32 3d 1e c1 a9 c1 a9 c1 a8 c3 cb &1ecf 1f 1f 3f 7f 7f 77 3f 0f ab 99 dd cc ee ff ff 0f &1edf 0f 0f 0f 8f 8f 88 0f 0f 0f 0f 0f 0f 0f 01 0e 0f &1eef 0f 0f 0f 0f 0f 0f 0f 07 0f 0f 0f 0f 0f 0f 0f 0f &1eff 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 1e 2d &1f0f 0f 0f 0f 0f 0f 0f 58 a4 1f 1f 0f 0f 0f 0f 0f 87 &1f1f 0f 1f bf bf 9f 8f ff bf f5 fe f7 ff 7f ff ff ff &1f2f df df fd ef ff df ff bf 0f 4f 8f 0f 0f af 0f 8f &1f3f 8f 8f 8f 8f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 1f 1f &1f4f 0f 0f 1e 2d 7e ed de ad 0f e5 7e ff 7b b5 5b a5 &1f5f 0f 0f 8f 8f cb cf cf a7 0f 0f 0f 0f 0f 0f 0f 0f &1f6f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1f7f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1f8f 0f 0f 0f 0f 0f 0f 0f 0f 0e 0e 0e 0e 0e 0e 0e 0e &1f9f 0f 0e 0e 0c 1d 3b 3b 3b 00 77 ee ee ee ff ff ff &1faf 03 89 cd aa aa aa 33 77 0d 0d 0d 0d 0d 05 05 05 &1fbf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &1fcf 0c 0c 0e 0e 0f 0f 0f 0f 3c 00 05 02 05 00 0f 0f &1fdf c3 00 05 0a 05 00 0f 0f 0f 00 05 0a 05 00 0f 0f &1fef 0f 00 05 0a 05 00 0f ff 0f 00 05 0a 05 00 0f 8f &1fff 0f 00 05 0a 05 00 0f 0f 0f 00 05 0a 05 00 0f 0f &200f 0f 00 05 0a 05 00 0f 0f 0f 00 05 0a 05 00 0f 09 &201f 0f 00 05 0a 05 00 0f 0f 0f 00 05 0a 05 00 0f 0f &202f 0b 01 05 09 05 01 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &203f 0f 0f 0f 0f 0f 0f 0f 0f 5a 2d 5a 2d 1e 2d 1e 2d &204f 58 a4 58 a4 58 a0 58 a0 17 87 17 87 0f 0f 1f 0f &205f 1f af 5f cf 5f 2f 4f af df ff 3f ef ff ff 7f 0f &206f df ef cf df af ef 1f af 6f af 8f af 4f 8f 1f 8f &207f 4f 4f 4f 8f 0f 4f 8f 0f 1f 3d 1f 3d 3f 3f 3f 3d &208f de ed fe ef de a5 da ad 5a a5 5a a4 1a 80 5a a5 &209f 6f e7 6f 07 6f 27 6b a7 0f 0f 0f 0f 0f 0f 0f 0f &20af 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &20bf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &20cf 0f 0f 0f 0f 0f 0f 0f 0f 0e 0e 0e 0e 0e 0e 0e 0e &20df 3b 3b 77 44 77 3b 3b 3b ff ff ee ee ee ff ff ff &20ef 77 77 77 cc ff 77 77 bb 05 05 89 89 89 05 05 05 &20ff 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &210f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 1f 0f 1f 2f &211f 01 01 01 af 4f ae 4f ae 0f 0f 0f 0f 0f 0f 0f 0f &212f 7f 7f 7f 6e 7f 6e 7f ee 0f 0f 0f 0f 0f 0f 0f 8f &213f 0f 0f 0f 0f 0f 0f 0f 0f 69 69 69 69 69 e0 f0 c0 &214f 0f 0f 0f 0f 0f 0f 0f 0f 6f 09 09 00 00 00 00 11 &215f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &216f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &217f 0f 0f 0f 0f 0f 0f 0f 0f 1e 78 78 78 78 78 78 78 &218f 58 e0 d1 e0 d1 e0 d1 e0 0f 8f 07 8f 07 8f 07 8f &219f 1f 1f 3f 0f 0f 0f 0f 0f 5f ef 1f 0f 0f 4f 4f 0f &21af 9f 2f 0f 6f 2f 0f 0f 0f 0f 7f 0f 0f 0f 0f 0f 0f &21bf 0f 0f 0f 0f 0f 0f 0f 0f 3f 3d 0e 0e 0e 0e 0e 0f &21cf 5a 25 42 00 0a a1 12 25 5a 01 ee ab 98 20 5a a5 &21df 6f 03 cd 45 45 03 03 a1 0f 0f 0f 0f 0f 0f 0f 0f &21ef 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &21ff 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &220f 0f 0f 0f 0f 0f 0f 0f 0f 0e 0e 0e 0e 0e 0e 0e 0e &221f 3b 3b 1d 1d 0c 0e 0f 0f ff ff ff ee ee ee 77 08 &222f ff ff ee ee cc cd 89 03 05 05 05 0d 0d 0d 0d 0d &223f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &224f 0f 0f 0f 0c 0c 0c 0c 0e 1f 2f 1f 23 1f 2f 17 00 &225f 4f ae 4f ae 4f ae 4f 00 07 1f 17 19 37 3f 17 00 &226f ff ff ff ff ff ff ff 00 8f cf 47 88 ab ef 47 00 &227f 1e 0e 1e 10 1e 1e 0f 00 80 80 00 80 90 e0 f0 00 &228f 87 07 07 80 07 87 0f 00 77 77 66 00 00 09 0f 00 &229f 0f 2d 3d 31 3d 2d 0f 00 0f 2d ed ed ed 3f 1f 00 &22af 0f 0f 0f 0f 0f 0f 07 03 0f 0f 0f 0f 0f 0f 0f 0f &22bf 0f 0f 0f 0f 0f 0f 1e 1e 78 78 78 78 78 f0 f0 f0 &22cf d1 a2 d1 a2 d1 a2 d1 a2 07 8f 07 8f 07 8f 43 cb &22df 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &22ef 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &22ff 0f 0f 0f 0f 0f 0f 0f 0f 1e 0f 1e 0f 0f 0f 0f 0f &230f 5a 81 1a a1 5a a5 5a 25 48 a5 5a 80 18 a0 5a a5 &231f 03 a5 4b 03 4b 87 0f 82 0f 0f 0f 0f 0f 0f 0f 0f &232f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &233f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0e 1d 3b 91 &234f 0f 0f 0f 03 8b 8b 8b 45 0e 0e 0e 0f 0f 0f 0f 0f &235f 0f 0f 00 0f 0f 0f 0f 0f 0f 0f 00 0f 0f 0f 0f 0f &236f 0f 0f 00 0f 0f 0f 0f 0f 0d 0d 01 0f 0f 0f 0f 0f &237f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &238f 0e 0e 0f 0f 0f 0f 0f 0f 05 02 05 00 0f 0f 0f 0f &239f 05 0a 05 00 0f 0f 0f 0f 05 0a 05 00 0f 0f 0f 0f &23af 05 0a 05 00 0f 0f 0f 0f 05 0a 05 00 0f 6f 4d ee &23bf 05 0a 05 00 0f 2e 3f 6e 05 0a 05 00 0f 0f 0f 8f &23cf 05 0a 05 00 0f 0f 0f 0f 05 0a 05 00 0f 0f 0f 0f &23df 05 0a 05 00 0f 0f 0f 0f 05 0a 05 00 1f 1f 1f 1f &23ef 03 0b 03 03 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &23ff 3c 78 78 f0 f0 f0 f1 e2 f0 f0 f0 f0 f0 b8 30 30 &240f d1 e0 d1 e0 f0 e0 f0 f0 61 b8 74 ba 54 ba 55 a2 &241f 0f 0f 0f 0f 87 c3 c3 c3 0f 0f 0f 0f 0f 0f 0f 0f &242f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &243f 0f 0f 0f 0e 0e 1d 1d 19 0e 08 22 66 ee ee ee ee &244f 12 cc cc dd dd 99 88 dd 5a 84 80 ac 24 60 42 8e &245f 22 33 bb 33 55 dd dd ee 07 01 cd cc ff ff ff ff &246f 0f 0f 0f 07 03 8b cd ee 0f 0f 0f 0f 0f 0f 0f 0f &247f 0f 0f 0f 0f 0f 0f 08 77 95 0e 0e 0e 0f 2d de ed &248f 89 89 cc 24 42 11 33 33 0f 03 0b 83 04 24 42 cc &249f 0f 0f 0f 0f 0f 0f 0f 07 0f 0f 0f 0f 0f 0f 0f 0f &24af 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &24bf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &24cf 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &24df 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &24ef 0f 0f 0f 0f 0f 0f 0f 0f 4d 6f 09 6f 4d 6f 4d 6f &24ff 3f 2e 0c 2e 3f 2e 3f 2e 0f 0f 0f 0f 0f 0f 0f 0f &250f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &251f 0f 0f 0f 0f 0f 0f 0f 0f 1f 1f 1f 0f 0f 0f 0f 0f &252f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &253f e6 e6 c4 c4 c4 c4 c4 f0 70 70 70 f0 f0 f0 f0 f0 &254f f0 f0 f0 f0 f0 f0 f0 f0 d1 00 11 c0 11 80 91 80 &255f 43 e9 61 aa 44 aa 44 bb 0f 0f 0f 00 0a 0b 00 02 &256f 0f 0f 0f 00 09 07 0a 02 0f 0f 0f 00 06 0c 0e 00 &257f 3b 3b 33 77 77 77 ff ff ee ee ff ff ff ff ff ff &258f cc ee 66 66 aa aa bb bb ac ec fc ed cf 47 56 76 &259f ee 66 66 22 66 aa 11 bb ff ff ff ff ff ff 77 77 &25af ee cc ff ee ff ff ff ff 00 77 77 bb 77 bb ff ff &25bf ff ff ff ff ff ff ff ff de ed dc cd dc cd ee aa &25cf 11 11 19 91 19 b0 38 38 dd 88 ff ff ff f6 f0 f0 &25df 8b cd 00 cd cd c0 c0 83 0f 0f 00 09 0e 0f 09 09 &25ef 0f 0f 00 03 00 07 07 0d 0f 0f 00 0f 0b 00 00 05 &25ff 0f 0f 00 0a 09 08 0f 0f 0f 0f 00 05 00 03 04 09 &260f 0f 0f 00 07 0d 04 0a 02 0f 0f 00 0c 0e 05 0d 07 &261f 0f 0f 00 0e 0f 06 08 02 0f 0f 00 06 06 0d 02 1d &262f 0f 0f 00 05 0e ff 77 bb 4d 6f 44 07 0c ff 55 bb &263f 3f 2e 33 03 0a ff 55 ff 0f 0f 00 07 0f ff 55 bb &264f 0f 0f 00 0e 09 ee ff ff 0f 0f 00 0f 03 0e 03 02 &265f 0f 0f 00 0d 09 06 0a 08 0f 0f 00 0f 01 0c 0a 07 &266f 0f 0f 00 0d 0c 09 01 01 0f 0f 00 0f 0a 0a 09 00 &267f f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 &268f f0 f0 f0 f0 f0 f0 f0 f0 c0 c0 e0 f0 f0 f0 f0 f0 &269f 74 ba 54 b2 50 b0 d0 b0 07 00 06 86 80 82 84 80 &26af 04 01 0b 08 07 00 00 01 19 1d 15 19 3b 3b 3b 33 &26bf ff ff ff ff ff ff ff ff dd cc ee ee dd cc 99 aa &26cf bb 55 ee 66 ff ff ff ff ba ba ab ba 33 bb bb bb &26df 91 19 5d 80 c4 c0 84 2e 77 77 77 ff ff ee ff ff &26ef ff ff ff bb aa 22 33 00 ff ff ff ee dd aa 66 47 &26ff 55 aa 77 aa 01 07 0f 0f 44 03 00 09 09 02 09 0e &270f 38 38 38 38 1c 02 0f 08 f0 f0 f0 e0 c1 01 0a 0b &271f 83 05 06 09 0f 06 07 00 0b 07 0b 01 01 0c 07 02 &272f 0f 0b 0f 0c 00 09 00 02 0d 06 0e 09 02 0a 04 01 &273f 07 0c 0e 08 07 08 0d 08 0b 01 03 03 0d 0c 09 05 &274f 0f 0b 00 08 0d 0f 05 01 02 04 0f 0b 06 0c 0b 00 &275f 0c 00 04 01 04 04 05 01 13 11 1b 2e 37 2a 37 6e &276f 55 aa 55 aa 55 aa 55 aa 55 bb 55 aa 55 aa 55 aa &277f dd ff 55 aa 55 bb 55 aa ff aa dd ee 77 aa 55 aa &278f dd ff 55 bb dd bb 55 bb 0f 88 8f 8d 88 8e cd cd &279f 06 07 0e 09 01 08 00 0d 0a 00 06 00 0a 04 07 0a &27af 06 07 04 09 01 03 05 0a 02 08 0b 02 0d 0f 0b 00 &27bf f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 &27cf f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 f0 &27df c0 f2 f0 a2 55 a2 54 b2 80 86 80 80 80 f2 f5 fa &27ef 09 0d 00 00 00 fa f5 fa 3b 3b 33 33 33 bb b3 d9 &27ff ee ff ee ee ff ff ff ff 99 22 11 99 99 22 cc aa &280f ff ff ff ff ff ff ff ff dd dd dd dd dd dd dd dd &281f 48 e2 c0 86 86 2c 78 f0 ee ee ee 66 66 66 77 77 &282f 01 09 00 00 00 f0 70 70 04 06 00 00 00 f0 f0 f0 &283f 04 08 00 00 00 e1 f0 e3 00 8e 08 88 08 f8 78 f8 &284f 00 07 00 00 00 f0 f0 f0 05 0a 00 00 00 e0 e0 e0 &285f 07 00 00 00 00 a0 50 80 0f 0b 00 00 00 a0 50 00 &286f 0d 0d 00 00 00 a0 50 00 09 02 00 00 00 a0 50 00 &287f 00 00 00 00 00 a0 50 00 05 09 00 00 00 a0 50 00 &288f 06 0d 00 00 00 a0 50 00 08 02 00 00 00 a0 50 00 &289f 0c 0b 00 00 00 b2 31 b2 77 0a 00 00 00 fa f5 fa &28af ff 06 00 00 00 fa f5 fa ff 0c 00 00 00 fa f5 fa &28bf ff 06 00 00 00 fa f5 fa ff 0b 00 00 00 fa f5 fa &28cf ff 0a 00 00 00 fa f5 fa ce 04 00 00 00 fa f5 fa &28df 09 03 00 00 00 fa f5 fa 08 0b 00 00 00 fa f5 fa &28ef 00 0e 00 00 00 fa f5 fa 04 01 00 00 00 88 80 88 &28ff f0 f0 f0 f0 54 ee dd 2a f0 f0 f0 f0 f0 f0 54 aa &290f f0 f0 f0 f0 f0 f0 55 aa f0 e0 f0 e0 d1 e0 45 8a &291f 54 ba 54 f8 41 8a 05 0a 00 8f 00 0a 05 0a 05 0a &292f 00 0f 00 0a 04 08 01 0a 11 1d 15 15 04 00 00 07 &293f ff ff 77 bb ff bb 55 2a dd aa ff ee ff ee ff ff &294f 77 77 77 77 33 bb cc aa dd ee ee ee ee ee ee ee &295f f8 e9 cb 8e f9 e8 ff 66 77 77 77 77 77 77 77 77 &296f 00 70 b8 b8 b8 b8 b8 b8 00 f0 f0 f0 f0 f0 f0 f0 &297f 57 27 57 27 53 63 53 63 08 f0 f0 f0 f0 f8 7c bc &298f 00 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 &299f 13 a3 13 a3 13 a3 13 a3 5f af 5f af 5f af 5f af &29af 5f af 5f af 5f af 5f af 5f af 5f 88 00 af 5f af &29bf 5f af 5f 00 00 af 5f af 5f af 5f 23 13 af 5f af &29cf 5f af 5f af 5f af 5f af 4e ae 4e ae 4e ae 4e ae &29df 31 b2 31 b2 31 b2 31 b2 00 07 07 07 07 07 07 07 &29ef 00 0f 0f 0f 0f 0c 0e 0f 00 0f 0f 0f 0f 00 00 0f &29ff 00 0f 0f 0f 0f 00 01 0f 00 0f 0f 0f 0f 0f 0f 0f &2a0f 31 3a 39 3a 39 3a 39 3a 80 8b 83 8b 83 8b 83 8b &2a1f 00 0f 0f 0f 0f 0f 0f 0f 00 0f 0f 0f 0f 0f 0f 0f &2a2f 11 1c 1d 1c 1d 1c 1d 1c 80 88 80 88 80 88 80 88 &2a3f 05 0a 00 00 00 00 00 00 05 0a 00 00 00 00 00 00 &2a4f 05 0a 00 00 00 00 00 00 05 0a 00 00 00 00 00 00 &2a5f 0d 0a 00 00 00 00 00 00 04 08 05 02 05 02 05 02 &2a6f 05 0a 05 0a 05 0a 05 0a 07 07 07 00 75 72 75 72 &2a7f 3b 19 0c 00 e4 ea f5 d9 77 ff 77 bb 77 33 33 88 &2a8f ce ec ce a8 9a 00 77 77 ff ff ff 77 77 77 00 cc &2a9f 77 77 05 88 cd cc cd cc 77 22 33 33 33 3b 33 3b &2aaf b8 b8 30 b8 30 b8 30 b8 f0 f0 f0 f0 f0 f0 f0 f0 &2abf 53 63 53 27 57 27 57 37 7c bc de be de be de be &2acf e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 e0 &2adf 13 80 50 a0 50 a0 00 a3 5f 00 50 a0 50 a0 00 af &2aef 5f 00 50 a0 50 a0 00 af 5f 00 50 a0 50 a0 00 af &2aff 5f 00 50 a0 50 a0 00 af 5f 00 50 a0 50 a0 00 af &2b0f 5f 00 50 a0 50 a0 00 af 4e 00 50 a0 50 a0 00 ae &2b1f 31 b2 31 b2 31 b2 31 b2 07 07 07 00 f5 fa f5 fa &2b2f 0f 0f 0f 00 f5 fa f5 fa 0f 0f 0f 00 f5 fa f5 fa &2b3f 0f 0f 0f 00 f5 fa f5 fa 0f 0f 0f 00 f5 fa f5 fa &2b4f 39 3a 39 32 f5 fa f5 fa 83 8b 83 8b 83 8b 83 8b &2b5f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &2b6f 1d 1c 1d 1c 1d 1c 1d 1c 80 88 80 88 80 88 80 88 &2b7f 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &2b8f 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &2b9f 00 00 00 00 00 00 00 00 05 02 05 02 05 02 05 02 &2baf 05 0a 04 08 05 0b 04 08 00 07 0f 0f 0f 0f 00 00 &2bbf 11 1d 1d 1d 3b 3b 00 11 cc ee ff ee ee ee 00 bb &2bcf 77 77 77 77 ff ff 00 88 dd dd dd dd dd dd 00 00 &2bdf cc ee ee cc cd cc 00 00 15 19 15 19 15 19 00 00 &2bef 30 98 54 98 fe aa 00 00 f0 f0 f0 f0 f0 f0 00 00 &2bff 57 37 53 71 71 63 00 33 de be 5e bc fc bc 00 cc &2c0f e0 e0 e0 e0 e0 e0 00 00 e0 e0 e0 e0 e0 e0 00 00 &2c1f 13 a3 13 a3 13 a3 00 00 5f af 5f af 5f af 00 00 &2c2f 5f af 5f af 5f af 00 01 5f af 00 00 3b 88 33 08 &2c3f 5f af 00 ff ff dd 77 00 5f af 13 cd ee cc 22 88 &2c4f 5f af 5f af 5f 00 00 0f 4e ae 4e ae 4e 00 00 0f &2c5f 31 b2 31 b2 31 32 00 0f 00 07 07 07 07 07 00 0b &2c6f 00 0f 0f 0f 0f 0c 00 0f 00 0f 0f 0f 0f 00 00 0f &2c7f 00 0f 0f 0f 0f 00 00 0d 00 0f 0f 0f 0f 0f 00 0a &2c8f 31 3a 39 3a 39 3a 31 3a 83 8b 83 8b 83 8b 83 8b &2c9f 0f 07 07 03 03 03 03 03 0f 0f 0f 0f 0f 0f 0f 0f &2caf 1d 1c 1d 1c 1d 1c 1d 1c 80 88 80 88 80 88 80 88 &2cbf 00 00 00 00 00 00 0f 0f 00 00 00 00 00 00 75 72 &2ccf 00 00 00 00 00 00 f5 fa 00 00 00 00 00 00 c4 88 &2cdf 00 00 00 00 00 00 07 02 04 00 03 02 04 05 0e 00 &2cef 06 03 04 00 00 0e 01 08 09 0f 0f 03 04 0e 0f 00 &2cff 15 28 3a 3a 33 32 3e 36 55 bb 11 f0 ff ee f3 e2 &2d0f 88 c5 f7 ff 55 df 55 ff 0b 07 00 04 0b 0f 0d 02 &2d1f 0b 03 00 0c 08 04 01 00 0e 07 0b 00 00 07 01 03 &2d2f 04 09 01 02 0e 03 04 06 0f 0f 06 03 04 00 0b 0f &2d3f 3b 08 1d 1d 1d 1d 15 1d cd 01 8b 12 9a 12 89 00 &2d4f 0f 0b 06 03 94 94 04 07 0f 07 09 00 00 00 0e 07 &2d5f 0f 0e 04 06 09 00 0a 0b 0f 05 0f 05 01 00 00 0a &2d6f 0b 0f 0a 0b 01 09 01 05 08 19 2a 33 2a 3b 2a 10 &2d7f ff ff 99 ff 33 ee 00 f0 aa aa aa aa aa aa 22 80 &2d8f 0f 0d 0e 0a 0a 0c 04 07 01 0e 08 08 00 20 14 0f &2d9f 0f 3f 37 37 15 a0 50 b3 0e 6f 6f 4d 67 a0 72 6f &2daf 07 3f 37 37 3f a0 50 3f 6f 4d 4d 4d 6f a0 50 6f &2dbf 0d 0c cf ce 47 a0 50 ad 03 08 0b 0c 03 86 02 08 &2dcf 1d 14 08 06 01 01 03 09 83 8b 83 8b 03 03 03 0b &2ddf 03 07 07 07 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f 0f &2def 1d 1c 1d 1c 1d 1c 1d 1c 80 88 80 88 80 88 80 88 &2dff 0f 0f 0f 0f 0f 0f 0f 0f 64 62 64 62 64 62 64 62 &2e0f 00 0f 0f 0e 0e 0c 0c 09 01 09 03 04 03 03 0c 08 &2e1f 0c 08 04 0c 0e 09 03 0e 02 0b 01 01 00 08 02 0d &2e2f 0d 0a 0e 00 08 0e 04 0e 00 00 02 08 02 04 04 01 &2e3f 33 3b 37 3f 19 11 0c 06 fb e2 f7 ff ff ff 00 0c &2e4f 66 ee 47 8d 02 89 09 08 06 01 00 02 09 0f 01 02 &2e5f 02 04 07 0d 05 07 0f 2e 04 03 09 03 07 1f cc 00 &2e6f 0e 0b 0c 0d 66 00 00 00 0a 05 08 05 77 00 00 00 &2e7f 15 1d 15 1d 99 00 33 11 8a 02 8b 02 8b 01 45 88 &2e8f 08 00 60 00 0c 0c 0f 01 0d 01 0f 00 0f 0e 07 08 &2e9f 01 00 04 01 0c 0f 0e 02 08 0b 02 0f 08 0c 0d 0e &2eaf 01 02 01 21 38 70 78 70 18 28 38 b0 b0 b0 d0 c0 &2ebf f0 70 80 f0 f0 f0 f0 00 80 20 a0 a0 e0 e0 c1 01 &2ecf 00 0f 0a 0d 06 0e 0f 0e 00 02 08 03 0f 0b 12 28 &2edf 73 a1 12 a5 16 a1 50 a0 4d 4d 4d 4d 6f 6f 50 a0 &2eef 3f 2e 2c 2e 2c 2e 50 a0 6f 49 69 69 69 69 50 a0 &2eff 49 a8 49 a8 49 a9 50 a0 07 08 07 0f 0e 01 06 81 &2f0f 09 03 0e 0b 0b 0d 01 04 0b 09 01 09 0e 00 08 0b &2f1f 0f 0f 0f 0f 0f 0f 07 07 0f 0f 0f 0f 0f 0f 0f 0f &2f2f 1d 1c 1d 1c 1d 1c 1d 0f 80 88 80 88 80 88 80 0f &2f3f 0f 0f 0f 0f 0f 0f 0f 0f 64 62 64 62 64 62 64 40 &2f4f 0b 00 01 06 06 0c 00 00 00 0d 0c 08 01 02 00 00 &2f5f 00 01 05 00 09 06 00 00 09 03 02 06 0e 01 00 00 &2f6f 07 06 0e 0f 0d 0e 00 00 0d 0a 00 0d 08 00 00 00 &2f7f 03 0f 0e 00 08 02 00 00 01 08 04 0c 00 00 00 00 &2f8f 0a 0a 04 0c 0b 02 00 00 08 07 0b 1f 26 0c 00 00 &2f9f 4c 88 00 03 03 07 00 00 00 01 0f 0b 0e 07 00 00 &2faf 0d 09 0f 0b 09 00 00 00 1d 1d 1d 0c 0f 04 00 00 &2fbf ee ff ff 77 00 03 00 00 55 aa dd ee 00 0b 00 00 &2fcf 00 89 03 03 0f 0f 00 00 00 0b 0b 09 08 0c 00 00 &2fdf 08 0d 00 08 00 0c 00 00 08 00 04 0d 05 0f 00 00 &2fef 10 00 09 02 04 01 00 00 e0 0b 0b 03 04 02 00 00 &2fff 00 0f 0f 01 01 00 00 00 03 09 04 05 0d 0b 00 00 &300f 0e 0c 00 0a 0a 09 00 00 07 00 0f 0b 04 03 00 00 &301f 50 00 05 0b 0b 02 00 00 50 06 0f 05 0a 0c 00 00 &302f 50 03 02 00 00 0b 00 00 50 04 01 0a 0d 00 00 00 &303f 50 04 0b 01 03 00 00 00 09 08 0d 0d 0d 00 00 00 &304f 0c 00 0f 0f 04 00 00 00 0c 07 05 04 04 00 00 00 &305f 0b 0b 01 0d 01 01 01 01 0f 0f 0f 1e 2d 2d 5a c3 &306f 0f 0f 0f c3 a5 a5 5a 78 0f 0f 0f 4b 0f b4 4b f0 ; unused &307f 00 ; entry_point &3080 a9 90 LDA #&90 ; Set TV offset and interlacing &3082 a2 00 LDX #&00 &3084 a0 01 LDY #&01 ; enable interlacing # *TV 0,1 &3086 20 f4 ff JSR &fff4 ; OSBYTE &3089 4c a0 1b JMP &1ba0 ; title_entry_point Game disassembly ================ ; INTRO ; ffff0e00 ffff31bc 4a00 ; player_right_one_sprite &0e00 00 00 00 00 cc 00 11 ee 00 11 ff 00 33 ff 00 33 &0e10 11 00 22 ff 88 22 09 88 22 19 00 22 13 00 11 22 &0e20 00 11 cc 00 11 22 00 11 22 00 22 11 00 22 11 00 &0e30 22 11 00 44 00 88 44 00 88 44 88 88 44 88 88 44 &0e40 44 88 44 00 88 44 00 88 33 0c 88 22 ee 88 22 00 &0e50 88 22 00 88 22 00 88 22 00 88 22 00 88 33 ff 00 &0e60 11 3b 00 11 27 88 11 2a 88 23 67 88 46 4e 88 67 &0e70 cd 88 77 33 00 33 bb cc 11 bb cc ; player_right_one_mask &0e7b ff ff ff ff 33 ff ee 11 ff ee 00 ff cc 00 ff cc &0e8b 00 ff cc 00 77 cc 00 77 cc 00 ff cc 00 ff ee 11 &0e9b ff ee 33 ff ee 11 ff ee 11 ff cc 00 ff cc 00 ff &0eab cc 00 ff 88 00 77 88 00 77 88 00 77 88 00 77 88 &0ebb 00 77 88 00 77 88 00 77 cc 00 77 cc 00 77 cc 00 &0ecb 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 ff &0edb ee 00 ff ee 00 77 ee 00 77 cc 00 77 88 00 77 88 &0eeb 00 77 88 cc ff cc 44 33 ee 44 33 ; sound_0ef6 # Player falling ; chan vol pitch dur &0ef6 11 00 fb ff fe 00 04 00 ; unused &0efe 00 00 ; player_right_two_sprite &0f00 00 66 00 00 ff 00 00 ff 88 11 ff 88 11 88 88 11 &0f10 77 cc 11 04 4c 11 04 88 11 01 88 00 99 00 00 ee &0f20 00 00 99 00 00 99 00 11 00 88 11 00 88 11 00 88 &0f30 22 00 44 22 00 44 22 44 44 22 44 44 22 22 44 22 &0f40 00 44 22 00 44 11 8e 44 11 77 44 11 00 44 11 00 &0f50 44 11 00 44 11 00 44 11 00 44 11 ff 88 00 9d 00 &0f60 00 46 88 00 45 88 00 8a 88 00 9d 00 00 9b 00 00 &0f70 9d 00 00 ee 00 00 ff 88 00 77 88 ; player_right_two_mask &0f7b ff 99 ff ff 00 ff ff 00 77 ee 00 77 ee 00 77 ee &0f8b 00 33 ee 00 33 ee 00 77 ee 00 77 ff 00 ff ff 11 &0f9b ff ff 00 ff ff 00 ff ee 00 77 ee 00 77 ee 00 77 &0fab cc 00 33 cc 00 33 cc 00 33 cc 00 33 cc 00 33 cc &0fbb 00 33 cc 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 &0fcb 33 ee 00 33 ee 00 33 ee 00 33 ee 00 77 ff 00 ff &0fdb ff 88 77 ff 88 77 ff 00 77 ff 00 ff ff 00 ff ff &0feb 00 ff ff 11 ff ff 00 77 ff 88 77 ; sound_0ff6 # Player climbing ; chan vol pitch dur &0ff6 11 00 04 00 ba 00 01 00 ; unused &0ffe 00 00 ; player_right_three_sprite &1000 00 33 00 00 77 88 00 77 cc 00 ff cc 00 cc 44 00 &1010 bb ee 00 8a 26 00 8a 44 00 88 4c 00 44 88 00 77 &1020 00 00 44 88 00 44 88 00 88 44 00 88 44 00 88 44 &1030 11 00 22 11 00 22 11 22 22 11 22 22 11 11 22 11 &1040 00 22 11 00 22 00 cf 22 00 bb aa 00 88 22 00 88 &1050 22 00 88 22 00 88 22 00 88 22 00 ff cc 00 46 88 &1060 00 23 44 00 22 4c 00 45 44 00 46 88 00 45 88 00 &1070 46 88 00 77 00 00 77 cc 00 33 cc ; player_right_three_mask &107b ff cc ff ff 88 77 ff 88 33 ff 00 33 ff 00 33 ff &108b 00 11 ff 00 11 ff 00 33 ff 00 33 ff 88 77 ff 88 &109b ff ff 88 77 ff 88 77 ff 00 33 ff 00 33 ff 00 33 &10ab ee 00 11 ee 00 11 ee 00 11 ee 00 11 ee 00 11 ee &10bb 00 11 ee 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 &10cb 11 ff 00 11 ff 00 11 ff 00 11 ff 00 33 ff 88 77 &10db ff cc 33 ff cc 33 ff 88 33 ff 88 77 ff 88 77 ff &10eb 88 77 ff 88 ff ff 88 33 ff cc 33 ; sound_10f6 # Freefalling player hitting floor, popping balloon ; chan vol pitch dur &10f6 00 00 03 00 06 00 05 00 ; unused &10fe 3d 30 ; player_right_four_sprite &1100 00 00 00 11 88 00 33 cc 00 33 ee 00 77 ee 00 66 &1110 22 00 55 ff 00 45 13 00 45 22 00 44 26 00 22 44 &1120 00 33 88 00 22 44 00 22 44 00 44 22 00 44 22 00 &1130 44 22 00 88 11 00 88 11 00 99 11 00 99 11 00 88 &1140 99 00 88 11 00 88 11 00 67 19 00 55 dd 00 44 11 &1150 00 44 11 00 44 11 00 44 11 00 44 11 00 77 ee 00 &1160 11 26 00 11 1b 00 22 9d 00 45 9b 00 66 9d 00 67 &1170 9b 00 33 77 00 33 77 88 11 ff 88 ; player_right_four_mask &117b ff ff ff ee 77 ff cc 33 ff cc 11 ff 88 11 ff 88 &118b 11 ff 88 00 ff 88 00 ff 88 11 ff 88 11 ff cc 33 &119b ff cc 77 ff cc 33 ff cc 33 ff 88 11 ff 88 11 ff &11ab 88 11 ff 00 00 ff 00 00 ff 00 00 ff 00 00 ff 00 &11bb 00 ff 00 00 ff 00 00 ff 88 00 ff 88 00 ff 88 00 &11cb ff 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 11 ff &11db ee 11 ff ee 00 ff cc 00 ff 88 00 ff 88 00 ff 88 &11eb 00 ff cc 88 ff cc 88 77 ee 00 77 ; unused &11f6 4f ae 00 47 df ae 00 33 22 44 ; player_right_five_sprite &1200 00 00 00 00 cc 00 11 ee 00 11 ff 00 33 ff 00 33 &1210 11 00 22 ff 88 22 09 88 22 19 00 22 13 00 11 22 &1220 00 11 cc 00 11 22 00 11 22 00 22 11 00 22 11 00 &1230 22 11 00 44 00 88 44 00 88 44 88 88 44 88 88 44 &1240 44 88 44 00 88 44 00 88 33 0c 88 22 ee 88 22 00 &1250 88 22 00 88 22 00 88 22 00 88 22 00 88 33 ff 00 &1260 00 9b 00 00 8d 88 11 46 88 22 4d 88 33 46 88 33 &1270 4d 88 11 bb 88 11 bb cc 00 ff cc ; player_right_five_mask &127b ff ff ff ff 33 ff ee 11 ff ee 00 ff cc 00 ff cc &128b 00 ff cc 00 77 cc 00 77 cc 00 ff cc 00 ff ee 11 &129b ff ee 33 ff ee 11 ff ee 11 ff cc 00 ff cc 00 ff &12ab cc 00 ff 88 00 77 88 00 77 88 00 77 88 00 77 88 &12bb 00 77 88 00 77 88 00 77 cc 00 77 cc 00 77 cc 00 &12cb 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 ff &12db ff 00 ff ff 00 77 ee 00 77 cc 00 77 cc 00 77 cc &12eb 00 77 ee 44 77 ee 44 33 ff 00 33 ; unused &12f6 00 11 ff 88 00 11 ff cc dd bb ; player_right_six_sprite &1300 00 66 00 00 ff 00 00 ff 88 11 ff 88 11 88 88 11 &1310 77 cc 11 04 4c 11 04 88 11 01 88 00 99 00 00 ee &1320 00 00 99 00 00 99 00 11 00 88 11 00 88 11 00 88 &1330 22 00 44 22 00 44 22 44 44 22 44 44 22 22 44 22 &1340 00 44 22 00 44 11 8e 44 11 77 44 11 00 44 11 00 &1350 44 11 00 44 11 00 44 11 00 44 11 ff 88 00 9d 4c &1360 00 9b 44 00 9d 4c 00 9b 88 11 9d 00 11 9b 00 11 &1370 9d 00 00 ee 00 00 ff 00 00 ff 00 ; player_right_six_mask &137b ff 99 ff ff 00 ff ff 00 77 ee 00 77 ee 00 77 ee &138b 00 33 ee 00 33 ee 00 77 ee 00 77 ff 00 ff ff 11 &139b ff ff 00 ff ff 00 ff ee 00 77 ee 00 77 ee 00 77 &13ab cc 00 33 cc 00 33 cc 00 33 cc 00 33 cc 00 33 cc &13bb 00 33 cc 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 &13cb 33 ee 00 33 ee 00 33 ee 00 33 ee 00 77 ff 00 33 &13db ff 00 33 ff 00 33 ff 00 77 ee 00 ff ee 00 ff ee &13eb 00 ff ff 11 ff ff 00 ff ff 00 ff ; unused &13f6 11 00 01 00 00 00 01 00 00 00 ; player_right_seven_sprite &1400 00 33 00 00 77 88 00 77 cc 00 ff cc 00 cc 44 00 &1410 bb ee 00 8a 26 00 8a 44 00 88 4c 00 44 88 00 77 &1420 00 00 44 88 00 44 88 00 88 44 00 88 44 00 88 44 &1430 11 00 22 11 00 22 11 22 22 11 22 22 11 11 22 11 &1440 00 22 11 00 22 00 cf 22 00 bb aa 00 88 22 00 88 &1450 22 00 88 22 00 88 22 00 88 22 00 ff cc 00 46 ae &1460 00 45 aa 00 46 ae 00 45 cc 00 ce 88 00 cd 88 00 &1470 ce 88 00 77 00 00 77 88 00 77 88 ; player_right_seven_mask &147b ff cc ff ff 88 77 ff 88 33 ff 00 33 ff 00 33 ff &148b 00 11 ff 00 11 ff 00 33 ff 00 33 ff 88 77 ff 88 &149b ff ff 88 77 ff 88 77 ff 00 33 ff 00 33 ff 00 33 &14ab ee 00 11 ee 00 11 ee 00 11 ee 00 11 ee 00 11 ee &14bb 00 11 ee 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 &14cb 11 ff 00 11 ff 00 11 ff 00 11 ff 00 33 ff 88 11 &14db ff 88 11 ff 88 11 ff 88 33 ff 00 77 ff 00 77 ff &14eb 00 77 ff 88 ff ff 88 77 ff 88 77 ; unused &14f6 11 00 fb ff ; shape_3f_data &14fa 10 12 02 92 91 00 ; player_left_zero_sprite &1500 11 88 00 33 cc 00 77 cc 00 77 ee 00 44 66 00 ff &1510 aa 00 8c 2a 00 44 2a 00 46 22 00 22 44 00 11 cc &1520 00 22 44 00 22 44 00 44 22 00 44 22 00 44 22 00 &1530 aa 22 00 aa aa 00 aa aa 00 aa aa 00 cc aa 00 cc &1540 aa 00 dd 22 00 dd 22 00 dd 22 00 dd 22 00 ff 22 &1550 00 9f 22 00 ee 22 00 88 22 00 77 ee 00 ae 4c 00 &1560 ab 44 00 ae 4c 00 67 44 00 22 6e 00 23 66 00 22 &1570 6e 00 11 cc 00 33 cc 00 33 cc 00 ; player_left_zero_mask &157b ee 77 ff cc 33 ff 88 33 ff 88 11 ff 88 11 ff 00 &158b 11 ff 00 11 ff 88 11 ff 88 11 ff cc 33 ff ee 33 &159b ff cc 33 ff cc 33 ff 88 11 ff 88 11 ff 88 11 ff &15ab 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 &15bb 11 ff 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 11 &15cb ff 00 11 ff 00 11 ff 00 11 ff 88 11 ff 00 33 ff &15db 00 33 ff 00 33 ff 88 33 ff cc 11 ff cc 11 ff cc &15eb 11 ff ee 33 ff cc 33 ff cc 33 ff ; sound_15f6 # Player jumping ; chan vol pitch dur &15f6 11 00 02 00 64 00 04 00 ; unused &15f8 20 26 ; player_left_one_sprite &1600 00 cc 00 11 ee 00 33 ee 00 33 ff 00 22 33 00 77 &1610 dd 00 46 15 00 22 15 00 23 11 00 11 22 00 00 ee &1620 00 11 22 00 11 22 00 22 11 00 22 11 00 22 11 00 &1630 55 11 00 55 55 00 55 55 00 55 55 00 66 55 00 66 &1640 55 00 66 99 00 66 99 00 66 99 00 66 99 00 77 99 &1650 00 47 99 00 77 11 00 44 11 00 33 ff 00 57 26 00 &1660 55 2a 00 57 26 00 33 2a 00 11 37 00 11 3b 00 11 &1670 37 00 00 ee 00 11 ee 00 11 ee 00 ; player_left_one_mask &167b ff 33 ff ee 11 ff cc 11 ff cc 00 ff cc 00 ff 88 &168b 00 ff 88 00 ff cc 00 ff cc 00 ff ee 11 ff ff 11 &169b ff ee 11 ff ee 11 ff cc 00 ff cc 00 ff cc 00 ff &16ab 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 &16bb 00 ff 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 00 &16cb ff 88 00 ff 88 00 ff 88 00 ff cc 00 ff 88 11 ff &16db 88 11 ff 88 11 ff cc 11 ff ee 00 ff ee 00 ff ee &16eb 00 ff ff 11 ff ee 11 ff ee 11 ff ; sound_16f6 # Player hitting floor ; chan vol pitch dur &16f6 00 00 f4 ff 02 00 01 00 ; unused &16fe 30 c7 ; player_left_two_sprite &1700 00 00 00 00 66 00 00 ff 00 11 ff 00 11 ff 88 11 &1710 11 88 33 ee 88 23 02 88 11 02 88 11 08 88 00 99 &1720 00 00 77 00 00 99 00 00 99 00 11 00 88 11 00 88 &1730 11 00 88 22 aa 88 22 aa 88 22 aa 88 22 aa 88 22 &1740 aa 88 22 aa 88 22 aa 88 22 aa 88 22 aa 88 22 aa &1750 88 22 ee 88 22 2e 88 22 cc 88 22 00 88 11 ff 88 &1760 11 2a 00 23 26 00 22 5d 00 23 46 88 22 5d 88 23 &1770 57 88 11 bb 00 77 bb 00 77 ee 00 ; player_left_two_mask &177b ff ff ff ff 99 ff ff 00 ff ee 00 ff ee 00 77 ee &178b 00 77 cc 00 77 cc 00 77 ee 00 77 ee 00 77 ff 00 &179b ff ff 88 ff ff 00 ff ff 00 ff ee 00 77 ee 00 77 &17ab ee 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc &17bb 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 &17cb 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 ee 00 77 &17db ee 11 ff cc 11 ff cc 00 ff cc 00 77 cc 00 77 cc &17eb 00 77 ee 44 ff 88 44 ff 88 11 ff ; sound_17f6 # Player falling ; chan vol pitch dur &17f6 10 00 fd ff 07 00 03 00 &17fe e6 75 ; player_left_three_sprite &1800 00 00 00 00 33 00 00 77 88 00 ff 88 00 ff cc 00 &1810 88 cc 11 ff 44 11 09 44 00 89 44 00 8c 44 00 44 &1820 88 00 33 88 00 44 88 00 44 88 00 88 44 00 88 44 &1830 00 88 44 11 55 44 11 55 44 11 55 44 11 55 44 11 &1840 55 44 11 55 44 11 55 44 11 55 44 11 55 44 11 55 &1850 44 11 77 44 11 17 44 11 66 44 11 00 44 00 ff cc &1860 00 9d 00 11 1b 00 11 26 88 11 2b 44 11 26 cc 11 &1870 2b cc 00 dd 88 33 dd 88 33 ff 00 ; player_left_three_mask &187b ff ff ff ff cc ff ff 88 77 ff 00 77 ff 00 33 ff &188b 00 33 ee 00 33 ee 00 33 ff 00 33 ff 00 33 ff 88 &189b 77 ff cc 77 ff 88 77 ff 88 77 ff 00 33 ff 00 33 &18ab ff 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ee &18bb 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 &18cb 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ff 00 33 &18db ff 00 ff ee 00 ff ee 00 77 ee 00 33 ee 00 33 ee &18eb 00 33 ff 22 77 cc 22 77 cc 00 ff ; sound_18f6 # Collecting red pill ; chan vol pitch dur &18f6 02 00 0a 00 96 00 05 00 ; unused &18fe 00 00 ; player_left_four_sprite &1900 11 88 00 33 cc 00 77 cc 00 77 ee 00 44 66 00 ff &1910 aa 00 8c 2a 00 44 2a 00 46 22 00 22 44 00 11 cc &1920 00 22 44 00 22 44 00 44 22 00 44 22 00 44 22 00 &1930 88 aa 00 aa aa 00 aa aa 00 aa aa 00 aa 66 00 aa &1940 66 00 99 66 00 99 66 00 99 66 00 99 66 00 99 ee &1950 00 89 6e 00 99 aa 00 88 22 00 77 ee 00 22 4c 00 &1960 45 88 00 46 88 00 45 44 00 22 4c 00 23 44 00 11 &1970 cc 00 11 cc 00 77 cc 00 77 88 00 ; player_left_four_mask &197b ee 77 ff cc 33 ff 88 33 ff 88 11 ff 88 11 ff 00 &198b 11 ff 00 11 ff 88 11 ff 88 11 ff cc 33 ff ee 33 &199b ff cc 33 ff cc 33 ff 88 11 ff 88 11 ff 88 11 ff &19ab 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 &19bb 11 ff 00 11 ff 00 11 ff 00 11 ff 00 11 ff 00 11 &19cb ff 00 11 ff 00 11 ff 00 11 ff 88 11 ff cc 33 ff &19db 88 77 ff 88 77 ff 88 33 ff cc 33 ff cc 33 ff ee &19eb 33 ff ee 33 ff 88 33 ff 88 77 ff ; unused # &19f6 - &19ff is a copy of &17f6 - &17ff &19f6 10 00 fd ff 07 00 03 00 e6 75 ; player_left_five_sprite &1a00 00 cc 00 11 ee 00 33 ee 00 33 ff 00 22 33 00 77 &1a10 dd 00 46 15 00 22 15 00 23 11 00 11 22 00 00 ee &1a20 00 11 22 00 11 22 00 22 11 00 22 11 00 22 11 00 &1a30 44 55 00 55 55 00 55 55 00 55 55 00 55 33 00 55 &1a40 33 00 44 bb 00 44 bb 00 44 bb 00 44 bb 00 44 ff &1a50 00 44 3f 00 44 dd 00 44 11 00 33 ff 00 11 26 00 &1a60 22 4c 00 23 44 00 22 2a 00 11 26 00 11 2a 00 11 &1a70 26 00 00 ee 00 33 ee 00 33 cc 00 ; player_left_five_mask &1a7b ff 33 ff ee 11 ff cc 11 ff cc 00 ff cc 00 ff 88 &1a8b 00 ff 88 00 ff cc 00 ff cc 00 ff ee 11 ff ff 11 &1a9b ff ee 11 ff ee 11 ff cc 00 ff cc 00 ff cc 00 ff &1aab 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 &1abb 00 ff 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 00 &1acb ff 88 00 ff 88 00 ff 88 00 ff cc 00 ff ee 11 ff &1adb cc 33 ff cc 33 ff cc 11 ff ee 11 ff ee 11 ff ff &1aeb 11 ff ff 11 ff cc 11 ff cc 33 ff ; unused # &1af6 - &1aff is a copy of &18f6 - &18ff &1af6 02 00 0a 00 96 00 05 00 00 00 ; player_left_six_sprite &1b00 00 00 00 00 66 00 00 ff 00 11 ff 00 11 ff 88 11 &1b10 11 88 33 ee 88 23 02 88 11 02 88 11 08 88 00 99 &1b20 00 00 77 00 00 99 00 00 99 00 11 00 88 11 00 88 &1b30 11 00 88 22 aa 88 22 aa 88 22 aa 88 22 aa 88 22 &1b40 aa 88 22 aa 88 22 aa 88 22 aa 88 22 aa 88 22 aa &1b50 88 22 ee 88 22 2e 88 22 cc 88 22 00 88 11 ff 88 &1b60 11 9b 00 23 9d 00 22 9b 00 23 cd 88 22 4e 4c 23 &1b70 67 cc 11 99 cc 77 bb 88 77 bb 00 ; player_left_six_mask &1b7b ff ff ff ff 99 ff ff 00 ff ee 00 ff ee 00 77 ee &1b8b 00 77 cc 00 77 cc 00 77 ee 00 77 ee 00 77 ff 00 &1b9b ff ff 88 ff ff 00 ff ff 00 ff ee 00 77 ee 00 77 &1bab ee 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc &1bbb 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 &1bcb 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 ee 00 77 &1bdb ee 00 ff cc 00 ff cc 00 ff cc 00 77 cc 00 33 cc &1beb 00 33 ee 66 33 88 44 77 88 44 ff ; unused &1bf6 00 00 00 00 00 01 00 00 00 00 ; player_left_seven_sprite &1c00 00 00 00 00 33 00 00 77 88 00 ff 88 00 ff cc 00 &1c10 88 cc 11 ff 44 11 09 44 00 89 44 00 8c 44 00 44 &1c20 88 00 33 88 00 44 88 00 44 88 00 88 44 00 88 44 &1c30 00 88 44 11 55 44 11 55 44 11 55 44 11 55 44 11 &1c40 55 44 11 55 44 11 55 44 11 55 44 11 55 44 11 55 &1c50 44 11 77 44 11 17 44 11 66 44 11 00 44 00 ff cc &1c60 00 cd 88 11 4e 88 11 45 88 11 6e 4c 11 27 26 11 ; unused &1c70 3b 6e 00 cc ee 33 dd cc 33 dd 88 ; player_left_seven_mask &1c7b ff ff ff ff cc ff ff 88 77 ff 00 77 ff 00 33 ff &1c8b 00 33 ee 00 33 ee 00 33 ff 00 33 ff 00 33 ff 88 &1c9b 77 ff cc 77 ff 88 77 ff 88 77 ff 00 33 ff 00 33 &1cab ff 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ee &1cbb 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 &1ccb 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ff 00 33 &1cdb ff 00 77 ee 00 77 ee 00 77 ee 00 33 ee 00 11 ee &1ceb 00 11 ff 33 11 cc 22 33 cc 22 77 ; unused &1cf6 03 00 00 00 00 00 00 00 00 f6 ; player_standing_sprite &1d00 00 77 00 00 ff 88 11 ff cc 11 88 cc 11 55 44 11 &1d10 aa cc 11 8a cc 11 55 44 11 00 44 11 02 44 00 88 &1d20 88 11 dd cc 33 22 66 44 88 99 44 55 11 44 55 11 &1d30 44 22 11 44 22 11 55 00 99 44 88 11 44 00 11 22 &1d40 00 11 33 00 11 44 08 11 55 88 dd 44 00 11 44 00 &1d50 13 44 00 13 44 22 22 44 22 22 77 df ee 11 05 44 &1d60 11 2a 4c 11 27 44 11 2a 4c 11 27 44 11 2a 4c 11 &1d70 27 44 11 dd cc 33 dd ee 33 88 ee ; player_standing_mask &1d7b ff 88 ff ff 00 77 ee 00 33 ee 00 33 ee 00 33 ee &1d8b 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ff 00 &1d9b 77 ee 00 33 cc 00 11 88 00 00 88 00 00 88 00 00 &1dab 88 00 00 88 00 00 88 00 00 88 00 00 88 00 00 cc &1dbb 00 00 cc 00 00 88 00 00 88 00 00 88 00 00 88 00 &1dcb 00 88 00 00 88 00 11 88 00 11 88 00 11 ee 00 33 &1ddb ee 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ee &1deb 00 33 ee 22 33 cc 22 11 cc 77 11 ; clock_block_for_writing &1df6 00 00 00 00 00 ; unused &1dfb 01 00 00 00 00 ; player_falling_sprite &1e00 22 00 00 57 55 66 57 ff 9f 57 ff df 46 ff bb 77 &1e10 88 dd 55 55 55 55 aa dd 55 8a dd 55 55 55 55 00 &1e20 55 55 07 55 55 88 99 44 dd 99 44 aa 99 44 55 11 &1e30 44 22 11 22 22 22 22 00 aa 22 00 22 22 00 22 22 &1e40 22 22 22 22 22 22 00 22 22 00 22 33 88 ee 22 00 &1e50 22 22 22 22 22 22 22 22 55 22 33 8a ee 11 05 44 &1e60 22 0a 2a 23 77 26 46 88 9b 45 88 9d 22 5d 2a 23 &1e70 dd ae 11 dd cc 11 88 cc 33 00 66 ; player_falling_mask &1e7b dd ff ff 88 aa 99 88 00 00 88 00 00 99 00 44 88 &1e8b 00 00 88 00 00 88 00 00 88 00 00 88 00 00 88 00 &1e9b 00 88 00 00 88 00 00 88 00 00 88 00 00 88 00 00 &1eab 88 00 00 cc 00 11 cc 00 11 cc 00 11 cc 00 11 cc &1ebb 00 11 cc 00 11 cc 00 11 cc 00 11 cc 00 11 cc 00 &1ecb 11 cc 00 11 cc 00 11 cc 00 11 cc 00 11 ee 00 33 &1edb cc 00 11 cc 00 11 88 77 00 88 77 00 cc 22 11 cc &1eeb 22 11 ee 22 33 ee 77 33 cc ff 99 ; clock_block_for_reading &1ef6 03 00 00 00 00 ; unused &1efb 00 00 00 00 f6 ; dead_player_sprite &1f00 00 00 00 00 00 00 00 00 00 77 00 00 00 00 00 88 &1f10 88 00 33 00 11 00 44 00 77 88 22 00 44 66 ff 88 &1f20 44 44 44 ee dd 88 88 44 66 ee ef 55 00 44 57 6e &1f30 67 55 11 00 45 66 cc 66 66 ff 46 6e ee 44 00 23 &1f40 45 ee af cc 00 23 ff 66 55 33 ff ff 22 22 ; unused &1f4e 39 00 ; red_pill_sprite &1f50 33 00 47 88 47 88 8f 4c 8f 4c 8f 4c cf cc 47 88 &1f60 33 00 ; unused &1f62 00 00 ee 00 33 ff 88 77 cc 00 33 99 00 77 88 00 &1f72 33 11 00 77 00 00 11 11 00 ; dead_player_mask &1f7b ff ff ff ff ff ff ff ff ff 88 ff ff ff ff ff 00 &1f8b 77 ff cc ff ee 00 33 ff 88 77 cc 00 33 99 00 77 &1f9b 88 00 33 11 00 77 00 00 11 11 00 22 00 00 00 11 &1fab 88 22 00 00 00 11 00 00 00 00 00 11 00 00 00 00 &1fbb 00 11 00 00 00 00 00 99 aa cc 00 00 dd dd ; unused &1fc9 00 00 48 b1 7a a8 a5 ; other_pill_sprite &1fd0 33 00 74 88 74 88 f8 c4 f8 c4 f8 c4 fc cc 74 88 &1fe0 33 00 ; sound_1fe2 # Collecting yellow pill ; chan vol pitch dur &1fe2 02 00 05 00 0a 00 40 00 ; sound_1fea # Collecting blue pill ; chan vol pitch dur &1fea 02 00 06 00 78 00 03 00 ; sound_1ff2 # Collecting cyan pill ; chan vol pitch dur &1ff2 02 00 08 00 50 00 06 00 ; unused &1ffa 03 4c d5 76 53 b5 ; shape_data ; shape_00_data &2000 c0 c2 c4 c6 a4 a8 04 28 24 46 44 24 14 0e 0e 50 &2010 d0 03 94 92 14 92 94 04 22 24 14 16 18 10 00 ; shape_01_data &201f e0 a4 a8 08 24 2b 2b 0c 94 50 00 ; shape_02_data &202a f0 92 0c 0c 0c 0c 24 70 e0 24 05 12 20 00 ; shape_03_data &2038 f0 e0 92 0f 0f 08 24 24 70 50 e0 c0 05 12 70 00 ; shape_04_data &2048 f0 e0 92 0e 0e 28 48 28 1c 04 50 d0 0f 50 00 ; shape_05_data &2057 d0 92 0c 0c 70 f0 09 70 00 ; shape_06_data &2060 f0 a0 92 0e 70 30 f0 a0 07 70 20 00 ; shape_07_data &206c f0 f0 e0 0d 70 70 70 00 ; shape_08_data &2074 22 01 91 11 0c 15 9c 11 91 25 0a a4 10 99 13 93 &2084 11 91 1a 99 09 91 11 01 22 f0 00 ; shape_09_data &208f f0 a0 a2 07 26 0f a6 06 22 20 70 f0 26 00 ; shape_0a_data &209d e0 91 1d 1d 1d 40 b0 0f 30 00 ; shape_0b_data &20a7 c0 09 40 00 ; shape_0c_data &20ab f0 c0 91 0f 0f 0a 14 13 12 11 32 11 40 c0 9c 50 &20bb f0 90 05 70 10 00 ; shape_0d_data &20c1 f0 0f 0e 11 60 c0 02 40 d0 08 11 40 b0 05 12 11 &20d1 10 00 ; shape_0e_data &20d3 f0 91 0f 0f 11 20 70 f0 0a 11 40 00 ; shape_0f_data &20df 02 11 91 0f 02 11 91 0f 00 ; shape_10_data &20e8 90 02 11 91 0f 0f 03 11 91 0f 0f 04 11 91 02 90 &20f8 01 30 01 b0 11 20 01 90 00 ; shape_11_data &2101 f0 f0 0d 70 70 10 00 ; shape_12_data &2108 60 21 23 12 13 01 93 92 a3 a1 f0 00 ; shape_13_data &2114 f0 c0 92 0c 0b 11 70 60 f0 d0 91 0a 70 60 00 ; shape_14_data &2123 01 11 91 0d 11 91 00 ; shape_15_data &212a d0 91 03 60 e0 06 60 e0 02 11 60 00 ; shape_16_data &2136 70 70 50 03 11 f0 f0 e0 70 70 60 0f d6 90 f0 f0 &2146 00 ; shape_17_data &2147 d0 91 03 60 c0 0d 12 50 00 ; shape_18_data &2150 91 01 11 91 0f 01 11 91 02 00 ; shape_19_data &215a e0 0f 0f 0f 60 00 ; shape_1a_data &2160 e0 91 0f 11 60 b0 0f 01 30 00 ; shape_1b_data &216a f0 22 0f 02 a2 70 00 ; shape_1c_data &2171 a0 c2 c4 c7 a6 aa 04 2a 26 47 44 42 20 00 ; shape_1d_data &217f f0 f0 f0 91 0f 0f 0f 0f 07 11 70 70 70 00 ; shape_1e_data &218d f0 91 0f 05 a2 01 70 30 f0 b0 05 70 30 00 ; shape_1f_data &219b b0 91 11 30 00 ; shape_20_data &21a0 90 91 0f 08 11 02 91 0e 0f 0f 0f 0f 0f 0f 11 10 &21b0 00 ; shape_21_data &21b1 b0 91 0b 11 30 00 ; shape_22_data &21b7 f0 f0 a1 a2 92 0f 08 22 70 70 30 f0 f0 0c 11 70 &21c7 60 00 ; shape_23_data &21c9 e0 2f 2f 02 91 92 93 03 13 12 22 10 00 ; shape_24_data &21d6 20 2d c0 00 ; shape_25_data &21da 30 17 18 d0 00 ; shape_26_data &21df 7e fe 00 ; shape_27_data &21e2 10 12 02 93 91 00 ; shape_28_data &21e8 02 11 91 0f 0f 05 11 91 0f 0f 11 91 0f 0b 11 91 &21f8 0f 11 91 0e 0f 00 ; shape_29_data &21fe 60 03 e0 40 06 c0 60 03 e0 00 ; shape_2a_data &2208 40 05 96 9d 15 29 03 d0 30 0a b0 00 ; shape_2b_data &2214 30 23 0d a3 b0 20 09 a0 40 03 c0 00 ; shape_2c_data &2220 70 40 35 0d a2 a0 03 f0 c0 00 ; shape_2d_data &222a 30 23 0d 09 93 c0 30 07 b0 00 ; shape_2e_data &2234 40 0f 0a c0 00 ; shape_2f_data &2239 70 05 f0 00 ; shape_30_data &223d 70 70 70 09 f0 f0 f0 f0 00 ; shape_31_data &2246 60 0b ac 91 a0 00 ; shape_32_data &224c 70 21 11 12 14 0f 0f 05 96 94 92 a2 b1 c0 50 91 &225c 92 08 11 91 b0 00 ; shape_33_data &2262 70 70 50 09 91 f0 d0 92 94 06 c0 00 ; shape_34_data &226e 30 0f 0f 0f b0 30 12 0c c0 00 ; shape_35_data &2278 40 3f 05 bf c0 20 02 12 21 10 03 e0 00 ; shape_36_data &2285 d0 02 91 92 93 03 13 12 22 06 40 b0 03 90 04 38 &2295 10 00 ; shape_37_data &2297 b0 b2 b4 b6 94 98 05 18 14 36 48 14 14 05 30 b0 &22a7 07 a0 00 ; shape_38_data &22aa 10 11 13 12 11 01 91 92 91 a0 00 ; shape_39_data &22b5 f0 f0 d0 7e 7e 24 20 00 ; shape_3a_data &22bd f0 f0 b0 92 0f 0f 70 70 40 f0 f0 c0 0f 0f 24 22 &22cd 21 10 22 12 0f 05 a2 00 ; shape_3b_data &22d5 f0 f8 f6 f6 f6 f6 f6 be 0f 0f 0f 0f 0f 0f 0f 7e &22e5 76 76 72 72 70 70 70 00 ; shape_3c_data &22ed f0 d0 a2 a6 98 0f 0f 18 26 22 70 50 00 ; shape_3d_data &22fa 40 34 0f 0f f0 00 ; status_screen_text &2300 1c 02 1e 27 18 ; define text window x:(&02, &27), y:(&18, &1e) &2305 66 30 3a 20 70 61 75 73 65 20 6f 6e 2e 20 20 20 ; "f0: pause on. f2: sound on." &2315 20 20 66 32 3a 20 73 6f 75 6e 64 20 6f 6e 2e &2324 0a 0d &2326 0a 0d &2328 66 31 3a 20 70 61 75 73 65 20 6f 66 66 2e 20 20 ; "f1: pause off. f3: sound off" &2338 20 20 66 33 3a 20 73 6f 75 6e 64 20 6f 66 66 2e &2348 0a 0d &234a 0a 0d &234c 72 65 74 75 72 6e 3a 20 67 6f 20 74 6f 20 63 75 ; "return: go to current position. " &235c 72 72 65 6e 74 20 70 6f 73 69 74 69 6f 6e 2e 20 &236c 20 20 20 20 &2370 0a 0d &2372 0a 0d &2374 65 73 63 61 70 65 3a 20 73 74 61 72 74 20 61 20 ; "escape: start a new game. " &2384 6e 65 77 20 67 61 6d 65 2e 20 20 20 20 20 &2392 19 04 2c 00 20 00 ; MOVE &002c, &0020 &2398 19 05 2c 00 10 01 ; DRAW &002c, &0110 &239e 19 05 cc 04 10 01 ; DRAW &04cc, &0110 &23a4 19 05 cc 04 20 00 ; DRAW &04cc, &0020 &23aa 1c 02 16 26 07 ; define text window x:(&02, &26), y:(&07, &16) &23af 73 63 6f 72 65 3a ; "score:" &23b5 0a 0d &23b7 0a &23b8 6c 69 76 65 73 3a 20 30 ; "lives: 0" &23c0 0a 0d &23c2 0a &23c3 69 6e 76 65 6e 74 6f 72 79 3a ; "inventory:" &23cd 0a 0d &23cf 1f 07 00 ; TAB(&07, &00) ; game_over_string &23d2 1a ; restore default windows &23d3 1f 0f 0c ; TAB(&0f, &0c) &23d6 67 61 6d 65 20 6f 76 65 72 2e ; "game over &23e0 1f 0e 0e ; TAB(&0e, &0e) &23e3 73 63 6f 72 65 3a 20 ; "score: &23ea 1f 0d 10 ; TAB(&0d, &10) &23ed 70 72 65 73 73 20 61 6e 79 20 6b 65 79 2e ; "press any key. &23fb 1f 15 0e ; TAB(&15, &0e) &23fe 00 ; end of string ; unused &23ff 00 ; unused &2400 1c 05 19 22 17 ; define text window x:(&05, &22), y:(&17, &19) &2405 0c ; CLS &2406 0a &2407 1c 05 10 0e 0c ; define text window x:(&05, &0e), y:(&0c, &10) &2408 11 82 ; COLOUR 128 + 2 &240e 11 03 ; COLOUR 3 &2410 0c ; CLS &2411 0a &2412 0a &2413 20 6c 69 76 65 73 3a 20 ; " lives: " &241b 00 ; unused &241c 69 6e 2c 20 6f 72 ; "in, or" ; unused &2422 1c 0b 15 26 0c ; define text window x:(&0b, &26), y:(&0c, &15) &2427 0c ; CLS &2428 20 6c 6f 73 74 2e ; " lost." &242e 0a &242f 0a &2430 0a &2431 0a &2432 20 53 6f 72 72 79 20 21 ; " Sorry !" &243a 00 ; unused &243b 00 00 00 ; unused &243e 64 69 65 64 20 6f 66 20 61 20 73 75 62 7a 65 72 ; "died of a subzero score!" &244e 6f 20 73 63 6f 72 65 21 ; unused &2456 1c 05 1a 22 17 ; define text window x:(&05, &22), y:(&17, &1a) &245b 11 81 ; COLOUR 128 + 1 &245d 0c ; CLS &245e 11 00 ; COLOUR 0 &2460 0a &2461 20 41 20 6e 65 77 20 6c 69 66 65 20 77 69 6c 6c ; " A new life will cost you" &2471 20 63 6f 73 74 20 79 6f 75 &247a 1f 02 02 ; TAB(&02, &02) &247d 44 6f 20 79 6f 75 20 77 69 73 68 20 74 6f 20 62 ; "Do you wish to buy? (Y/N)" &248d 75 79 3f 20 28 59 2f 4e 29 &2496 1a ; restore default windows &2497 1f 1f 18 ; TAB(&1f, &18) ; inventory_text_window_string &249a 1c 0d 16 26 0b ; define text window x:(&0d, &26), y:(&0b, &16) ; antidote_to_green_pills_string &249f 61 6e 74 69 64 6f 74 65 20 74 6f 20 67 72 65 65 ; "antidote to green pills" &24af 6e 20 70 69 6c 6c 73 00 ; unused &24b7 00 00 00 ; a_sharp_pin_string &24ba 61 20 73 68 61 72 70 20 70 69 6e 00 ; "a sharp pin" ; a_length_of_thread_string &24c6 61 20 6c 65 6e 67 74 68 20 6f 66 20 74 68 72 65 ; "a length of thread" &24d6 61 64 00 ; the_magic_bean_string &24d9 74 68 65 20 6d 61 67 69 63 20 62 65 61 6e 00 ; "the magic bean" ; unused &24e8 00 ; an_acid_proof_plaster_string &24e9 61 6e 20 61 63 69 64 20 70 72 6f 6f 66 20 70 6c ; "an acid proof plaster" &24f9 61 73 74 65 72 00 ; unused &24ff 00 ; object_sprites # &00 - &07 are 2 x 8 bytes ( 8 x 8 pixels) # &08 - &0f are 1 x 16 bytes ( 4 x 16 pixels) # &10 - &17 are 3 x 5 bytes (12 x 5 pixels) ; object_sprite_00 # Antidote to green pills &2500 00 00 00 00 77 ee f8 15 f8 1b f8 15 f8 1b 77 ee ; object_sprite_01 # Clock button &2510 00 00 33 ff 23 1f 23 1f 23 1f 23 1f 23 1f 3f ff ; object_sprite_02 # Strong magnet &2520 11 cc 23 2e 47 1f 47 9f 57 57 57 57 55 55 22 22 ; object_sprite_03 # Magic bean &2530 00 00 00 00 00 00 11 cc 32 e2 74 79 65 bd 33 66 ; object_sprite_04 # Acid proof plaster &2540 00 00 77 ee 9d 9b ab 5d af 5f ab 5d 9d 9b 77 ee ; object_sprite_05 # Spirit stopper &2550 ff ff 8f 1f ff ff 22 4c 23 44 22 4c 23 44 11 88 ; object_sprite_06 # Chewing gum used as water tank stopper &2560 66 ee bd 5b af df af 9f eb b7 9f 5f de bd ff ee ; object_sprite_07 # Unplot magic bean &2570 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ; object_sprite_08 # Sharp pin &2580 77 72 22 22 22 22 22 22 22 22 22 22 22 22 22 20 ; object_sprite_09 # Gas tap off &2590 ff f9 f9 f9 fa fa fa fa fa fa fa fa fa fa fa fc ; object_sprite_0a # Balloon string &25a0 66 60 f9 f9 ff 22 22 22 44 44 44 22 22 22 44 44 ; object_sprite_0b # Water frame one &25b0 d9 ea ea b9 f9 55 75 f9 d9 b9 ea ea d9 b9 75 75 ; object_sprite_0c # Water frame two &25c0 75 d9 ea ea b9 f9 f9 d9 b9 75 75 d9 ea aa f9 75 ; chewing_gum_string &25d0 63 68 65 77 69 6e 67 20 67 75 6d 00 ; "chewing gum ; an_eye_shield_string &25dc 61 6e 20 65 79 65 20 73 68 69 65 6c 64 00 ; "an eye shield" ; unused &25ea 00 00 00 00 00 00 ; object_sprite_0f # Beanstalk body &25f0 f9 75 75 75 75 75 f9 75 f9 ea ea ea 00 00 00 08 ; object_sprite_10 # Length of thread &2600 33 dd ee 44 33 11 ff ff ff 88 66 33 77 dd ee 00d ; object_sprite_11 # Gas tap on &2610 ff ff ff f8 f0 f0 f8 f0 f0 77 ff f8 00 00 77 00 ; object_sprite_12 # Pin on magnet &2620 d5 55 00 f8 f0 e0 ff ff ee 88 00 00 00 00 00 06 ; object_sprite_13 # Unplot gas tap off &2630 00 00 11 00 00 22 00 00 22 00 00 22 00 00 22 06 ; object_sprite_14 # Chewing gum &2640 ff ff ff da f0 79 e9 0f b5 da f0 79 ff ff ff 43 ; object_sprite_15 # Eye shield &2650 30 33 cc 40 f4 e2 90 75 f9 60 22 75 00 00 33 11 ; object_sprite_16 # (unused) &2660 0e f1 11 0f 71 00 00 00 11 88 22 23 4c 75 23 62 ; object_sprite_17 # (unused) &2670 b9 11 2a f9 11 3d e2 00 8f c4 00 00 00 00 00 22 ; acid_label_sprite # Object type &18, uses &2680 - &26a7 &2680 00 00 00 00 00 00 00 00 02 02 05 08 05 05 05 04 &2690 05 04 05 04 07 04 05 04 05 05 05 04 05 02 05 08 ; spirit_label_sprite # Object type &19, uses &26a0 - &26d1 &26a0 00 00 00 00 00 00 00 00 00 00 06 0c 0b 02 0e 04 &26b0 0a 0a 0a 04 04 0a 0a 0a 04 02 0c 0b 02 04 02 08 &26c0 0a 0a 04 06 08 0a 0a 04 00 00 00 00 ; oil_label_sprite # Object type &1a, uses &26cc - &26e9 &26cc 00 00 00 00 00 00 01 00 00 02 0a 08 02 0a 08 02 &26dc 0a 08 02 0a 08 01 02 0c ; agar_label_sprite # Object type &1b, uses &26e4 - &2715 &26e4 00 00 00 00 00 00 00 00 00 00 01 01 08 09 08 02 &26f4 0a 01 05 04 02 0a 01 05 04 03 0a 0d 0d 08 02 0a &2704 05 05 04 02 09 09 05 04 ; vanishing_cream_label_sprite # Object type &1c, uses &270c - &279b &270c 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &271c 05 02 02 05 0a 0a 04 04 05 05 05 05 02 0a 0a 0a &272c 05 05 05 05 02 0a 0a 08 05 07 05 04 0b 0a 0a 0a &273c 05 05 05 04 0a 0a 0a 0a 02 05 05 05 0a 0a 0a 06 &274c 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 &275c 00 02 02 06 04 05 00 00 00 05 05 04 0a 0a 08 00 &276c 00 04 05 04 0a 0a 08 00 00 04 06 06 0e 0a 08 00 &277c 00 05 05 04 0a 0a 08 00 00 02 05 06 0a 0a 08 00 &278c 00 00 00 00 00 00 00 ; iron_pills_label_sprite # Object type &1d &2793 00 00 00 00 00 00 00 00 00 08 09 02 05 05 05 0a &27a3 05 05 05 0e 05 09 05 0e 05 05 05 06 05 04 09 02 &27b3 00 00 00 00 00 00 00 00 06 05 02 06 05 05 02 04 &27c3 05 05 02 04 06 05 02 02 04 05 02 02 04 05 0b 06 &27d3 00 00 00 00 00 00 00 00 ; unused &27db 00 00 00 00 00 ; soap_label_sprite # Object type &1f &27e0 00 00 00 00 06 04 04 0c 04 0a 0a 0a 04 0a 0a 0a &27f0 02 0a 0e 0c 02 0a 0a 08 06 04 0a 08 00 00 00 00 ; iron_pill_sprite_zero &2800 22 00 75 00 f8 88 f8 88 f8 88 75 00 22 00 ; iron_pill_mask_zero &280e dd ff 88 ff 00 77 00 77 00 77 88 ff dd ff ; iron_pill_sprite_one &281c 11 00 23 88 47 4c 47 4c 47 4c 23 88 11 00 ; iron_pill_mask_one &282a ee ff cc 77 88 33 88 33 88 33 cc 77 ee ff ; iron_pill_sprite_two &2838 00 88 11 c4 32 e2 32 e2 32 e2 11 c4 00 88 ; iron_pill_mask_two &2846 ff 77 ee 33 cc 11 cc 11 cc 11 ee 33 ff 77 ; iron_pill_sprite_three &2854 00 44 00 ae 11 1f 11 1f 11 1f 00 ae 00 44 ; iron_pill_mask_two &2862 ff 33 ff 11 ee 00 ee 00 ee 00 ff 11 ff 33 ; lipstick_missile_sprite &2870 11 00 22 88 22 88 74 c4 54 c4 54 c4 54 c4 54 c4 &2880 d8 e2 b8 e2 b8 e2 b8 e2 b8 e2 b8 e2 ad a6 ad a6 &2890 ad a6 ad a6 ; lipstick_missile_mask &2894 ee ff cc 77 cc 77 88 33 88 33 88 33 88 33 88 33 &28a4 00 11 00 11 00 11 00 11 00 11 00 11 00 11 00 11 &28b4 00 11 00 11 ; drip_sprite &28b8 11 00 11 00 11 00 23 88 32 88 56 c4 9c e2 9c e2 &28c8 8e e2 47 44 47 4c 23 88 11 00 ; drip_mask &28d2 ee ff ee ff ee ff cc 77 cc 77 88 33 00 11 00 11 &28e2 00 11 88 33 88 33 cc 77 ee ff ; a_covering_of_oil_string &28ec 61 20 63 6f 76 65 72 69 6e 67 20 6f 66 20 6f 69 ; "a covering of oil" &28fc 6c 00 ; unused &28fe 00 73 ; player_sprite_climbing_zero &2900 00 11 88 00 23 4c 00 ef 4c 11 ff aa 33 ff aa 33 &2910 ff aa 33 ff aa 33 ff aa 33 ff aa 33 ff aa 11 ff &2920 aa 00 ee aa 77 11 22 88 ee 22 88 00 44 88 00 44 &2930 88 00 44 44 00 44 44 00 44 44 00 44 44 00 44 44 &2940 00 44 44 00 44 44 00 44 44 00 44 44 00 44 44 44 &2950 44 44 44 44 44 44 cc 44 55 88 77 aa 88 23 05 88 &2960 22 2a 88 23 45 88 22 4e 88 23 77 88 22 7f 88 23 &2970 77 00 33 cc 00 33 cc 00 11 cc 00 ; player_mask_climbing_zero &297b ff ee 77 ff cc 33 ff 00 33 ee 00 11 cc 00 11 cc &298b 00 11 cc 00 11 cc 00 11 cc 00 11 cc 00 11 ee 00 &299b 11 ff 00 11 88 00 11 00 00 11 00 00 33 00 00 33 &29ab 00 00 33 88 00 33 88 00 33 88 00 33 88 00 33 88 &29bb 00 33 88 00 33 88 00 33 88 00 33 88 00 33 88 00 &29cb 33 88 00 33 88 00 33 88 00 77 88 00 77 cc 00 77 &29db cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc 00 77 cc &29eb 00 ff cc 33 ff cc 33 ff ee 33 ff ; sound_29f6 # Collecting magenta pill, vanishing cream ; chan vol pitch dur &29f6 02 00 07 00 b2 00 0c 00 ; unused &29fe a5 79 ; player_sprite_climbing_one &2a00 11 88 00 23 4c 00 23 7f 00 55 ff 88 55 ff cc 55 &2a10 ff cc 55 ff cc 55 ff cc 55 ff cc 55 ff cc 55 ff &2a20 88 55 77 00 44 88 ee 44 77 11 22 00 11 22 00 11 &2a30 22 00 11 22 00 22 22 00 22 22 00 22 22 00 22 22 &2a40 00 22 22 00 22 22 00 22 22 00 22 22 00 22 22 22 &2a50 22 22 22 22 33 22 22 11 aa 22 11 55 ee 11 0a 4c &2a60 11 45 44 11 2a 4c 11 27 44 11 ee 4c 11 ef 44 00 &2a70 ee 4c 00 33 cc 00 33 cc 00 33 88 ; player_mask_climbing_one &2a7b ee 77 ff cc 33 ff cc 00 ff 88 00 77 88 00 33 88 &2a8b 00 33 88 00 33 88 00 33 88 00 33 88 00 33 88 00 &2a9b 77 88 00 ff 88 00 11 88 00 00 cc 00 00 cc 00 00 &2aab cc 00 00 cc 00 11 cc 00 11 cc 00 11 cc 00 11 cc &2abb 00 11 cc 00 11 cc 00 11 cc 00 11 cc 00 11 cc 00 &2acb 11 cc 00 11 cc 00 11 ee 00 11 ee 00 11 ee 00 33 &2adb ee 00 33 ee 00 33 ee 00 33 ee 00 33 ee 00 33 ff &2aeb 00 33 ff cc 33 ff cc 33 ff cc 77 ; sound_2af6 # Collecting green pill ; chan vol pitch dur &2af6 02 00 09 00 0c 00 02 00 ; unused &2afe 75 a5 ; font_data_zero # &2b00 - &347f is overwritten in game &2b00 3c 62 4e 52 4c 60 3c 00 ; &40 ("@") &2b08 18 24 24 5c 44 82 c6 00 ; &41 ("A") &2b10 38 44 42 7c 42 42 3c 00 ; &42 ("B") &2b18 1c 22 40 40 40 42 3c 00 ; &43 ("C") &2b20 38 44 42 42 42 44 38 00 ; &44 ("D") &2b28 1c 22 40 78 40 42 3c 00 ; &45 ("E") &2b30 3c 42 40 78 40 40 e0 00 ; &46 ("F") &2b38 1c 22 40 4c 42 42 3c 00 ; &47 ("G") &2b40 26 42 42 5e 62 42 64 00 ; &48 ("H") &2b48 38 10 10 10 10 10 28 00 ; &49 ("I") &2b50 38 46 04 04 04 44 38 00 ; &4a ("J") &2b58 c6 44 48 70 48 44 e6 00 ; &4b ("K") &2b60 70 20 20 20 20 22 7c 00 ; &4c ("L") &2b68 34 4a 49 49 49 41 23 00 ; &4d ("M") &2b70 22 52 52 4a 4a 4a 64 00 ; &4e ("N") &2b78 38 44 42 42 42 66 3c 00 ; &4f ("O") &2b80 5c 22 22 22 3c 20 70 00 ; &50 ("P") &2b88 18 24 42 42 4a 4c 32 00 ; &51 ("Q") &2b90 7c 22 22 3c 28 24 66 00 ; &52 ("R") &2b98 1c 22 20 1c 02 46 3c 00 ; &53 ("S") &2ba0 fe 92 10 10 10 10 10 00 ; &54 ("T") &2ba8 62 22 42 42 42 46 3a 00 ; &55 ("U") &2bb0 c6 42 42 22 24 28 10 00 ; &56 ("V") &2bb8 c6 82 92 92 92 94 68 00 ; &57 ("W") &2bc0 42 42 24 18 18 24 66 00 ; &58 ("X") &2bc8 42 42 44 38 10 10 38 00 ; &59 ("Y") &2bd0 3e 42 04 08 10 22 7c 00 ; &5a ("Z") &2bd8 38 60 40 40 40 60 38 00 ; &5b ("[") &2be0 10 10 10 92 54 38 10 00 ; &5c ("\", actually down arrow) &2be8 38 0c 04 04 04 0c 38 00 ; &5d ("]") &2bf0 10 38 54 92 10 10 10 00 ; &5e ("^", actually up arrow) &2bf8 f5 95 85 87 85 95 f5 00 ; &5f ("_") ; null_function &2c00 60 RTS ; introduction_room_00_data &2c01 78 dd f3 ; shape at x:&5d, y:&f3, type &38 &2c04 14 73 ; fill at y:&73, pattern &4 &2c06 47 40 ; shape at x:&40, type &07 &2c08 11 f0 ; fill at y:&f0, pattern &1 &2c0a 47 7a ; shape at x:&7a, type &07 &2c0c 11 f0 ; fill at y:&f0, pattern &1 &2c0e 6f 5d ; shape at x:&5d, type &2f &2c10 6f dd ef ; shape at x:&5d, y:&ef, type &2f &2c13 13 f2 ; fill at y:&f2, pattern &3 &2c15 13 ee ; fill at y:&ee, pattern &3 &2c17 59 dd e7 ; shape at x:&5d, y:&e7, type &19 &2c1a 6e dd d9 ; shape at x:&5d, y:&d9, type &2e &2c1d 12 d2 ; fill at y:&d2, pattern &2 &2c1f 93 ; string, length &13 &2c20 1a ; restore default windows &2c21 1f 0a 0e ; TAB(&0a, &0e) &2c24 43 48 45 4d 49 53 54 ; "CHEMIST" &2c2b 1c 00 0b 13 01 ; define text window x:(&00, &13), y:(&01, &0b) &2c30 1f 00 05 ; TAB(&00, &05) &2c33 79 c1 e1 ; shape at x:&41, y:&e1, type &39 &2c36 79 f9 e1 ; shape at x:&79, y:&e1, type &39 &2c39 7a bf dc ; shape at x:&3f, y:&dc, type &3a &2c3c 1c d6 ; fill at y:&d6, pattern &c &2c3e 7a f7 dc ; shape at x:&77, y:&dc, type &3a &2c41 1a d6 ; fill at y:&d6, pattern &a &2c43 00 ; end of data ; unused &2c44 00 ; introduction_room_03_data &2c45 08 e6 00 49 ; platform at x:&00, y:&e6, length &49 &2c49 08 e6 49 47 ; platform at x:&49, y:&e6, length &47 &2c4d 86 ; string, length &06 &2c4e 13 02 04 00 00 00 ; set colour 2 to blue &2c54 53 14 ; shape at x:&14, type &13 &2c56 12 dc ; fill at y:&dc, pattern &2 &2c58 47 41 ; shape at x:&41, type &07 &2c5a 10 e1 ; fill at y:&e1, pattern &0 &2c5c 62 72 ; shape at x:&72, type &22 &2c5e 1f dc ; fill at y:&dc, pattern &f &2c60 51 c5 d7 ; shape at x:&45, y:&d7, type &11 &2c63 14 d2 ; fill at y:&d2, pattern &4 &2c65 02 00 2c 0b ; use custom update routine &2c00 (null_function) &2c69 04 10 c0 80 40 00 c0 80 40 00 d6 0f ; room variables &0f &d6 &00 &40 &80 &c0 &00 &40 &80 &c0 &10 &04 &2c75 00 ; end of data ; key_words &2c76 43 41 50 53 ; "CAPS" &2c7a 3c 2d 20 20 ; "<- " &2c7e 53 48 4c 4b ; "SHLK" &2c82 2d 3e 20 20 ; "-> " &2c86 44 45 4c 2e ; "DEL." &2c8a 43 4f 50 59 ; "COPY" &2c8e 54 41 42 20 ; "TAB " &2c92 5e 20 20 20 ; "^ " &2c96 5c 20 20 20 ; "\ " ; key_characters &2c9a 3c ; < &2c9b 3e ; > &2c9c 3f ; ? &2c9d 2a ; * &2c9e 2b ; + &2c9f 40 ; @ &2ca0 41 ; A &2ca1 42 ; B &2ca2 43 ; C &2ca3 44 ; D &2ca4 45 ; E &2ca5 46 ; F &2ca6 47 ; G &2ca7 48 ; H &2ca8 49 ; I &2ca9 4a ; J &2caa 4b ; K &2cab 4c ; L &2cac 4d ; M &2cad 4e ; N &2cae 4f ; O &2caf 50 ; P &2cb0 51 ; Q &2cb1 52 ; R &2cb2 53 ; S &2cb3 54 ; T &2cb4 55 ; U &2cb5 56 ; V &2cb6 57 ; W &2cb7 58 ; X &2cb8 59 ; Y &2cb9 5a ; Z &2cba 5b ; [ &2cbb 5d ; ] &2cbc 60 ; ` ; key_codes &2cbd e6 ; , &2cbe e7 ; . &2cbf e8 ; / &2cc0 c8 ; ' &2cc1 d7 ; ; &2cc2 c7 ; \ &2cc3 c1 ; A &2cc4 e4 ; B &2cc5 d2 ; C &2cc6 b2 ; D &2cc7 a2 ; E &2cc8 c3 ; F &2cc9 d3 ; G &2cca d4 ; H &2ccb a5 ; I &2ccc c5 ; J &2ccd c6 ; K &2cce d6 ; L &2ccf e5 ; M &2cd0 d5 ; N &2cd1 b6 ; O &2cd2 b7 ; P &2cd3 90 ; Q &2cd4 b3 ; R &2cd5 d1 ; S &2cd6 a3 ; T &2cd7 b5 ; U &2cd8 e3 ; V &2cd9 a1 ; W &2cda c2 ; X &2cdb c4 ; Y &2cdc e1 ; Z &2cdd b8 ; { &2cde d8 ; } &2cdf a8 ; ` &2ce0 c0 ; CAPS-LOCK &2ce1 99 ; LEFT &2ce2 d0 ; SHIFT-LOCK &2ce3 f9 ; RIGHT &2ce4 d9 ; DELETE &2ce5 e9 ; COPY &2ce6 e0 ; TAB &2ce7 b9 ; UP &2ce8 a9 ; DOWN ; tab_for_define_key_string &2ce9 1f 0e 06 ; TAB(&0e, &06) &2cec 2e 2e 2e 20 ; "... " ; key_selection_string &2cf0 4b 65 79 20 53 65 6c 65 63 74 69 6f 6e ; "Key Selection" &2cfd 1c 08 16 26 0d ; define text window x:(&08, &26), y:(&0d, &16) ; current_keys_string &2d02 54 68 65 20 43 75 72 72 65 6e 74 20 4b 65 79 73 ; "The Current Keys: &2d12 3a &2d13 00 00 00 &2d16 1c 0b 14 17 0d ; define text window x:(&0b, &17), y:(&0d, &14) ; left_string &2d1b 4c 65 66 74 ; "Left" &2d1f 0a &2d20 0a 0d ; right_string &2d22 52 69 67 68 74 ; "Right" &2d27 0a &2d28 0a 0d ; jump_climb_string &2d2a 4a 75 6d 70 2f 43 6c 69 6d 62 ; "Jump/Climb" &2d34 0a &2d35 0a 0d ; climb_down_string &2d37 43 6c 69 6d 62 20 44 6f 77 6e ; "Climb Down" &2d41 1c 17 14 19 0d ; define text window x:(&17, &19), y:(&0d, &14) &2d46 2e 2e 2e ; "..." &2d49 0a &2d4a 2e 2e 2e ; "..." &2d4d 0a &2d4e 2e 2e 2e ; "..." &2d51 0a &2d52 2e 2e 2e ; "..." ; clear_title_screen_keys_string &2d55 1c 05 1d 22 17 ; define text window x:(&05, &22), y:(&17, &1d) &2d5a 11 81 ; COLOUR 128 + 1 &2d5c 11 00 ; COLOUR 0 &2d5e 0c ; CLS &2d5f 0a &2d60 09 09 &2d62 4b 20 2e 2e 2e 20 74 6f 20 73 65 6c 65 63 74 20 ; "K ... to select new keys" &2d72 6e 65 77 20 6b 65 79 73 &2d7a 1f 02 03 ; TAB(&02, &03) &2d7d 49 20 2e 2e 2e 20 66 6f 72 20 74 68 65 20 69 6e ; "I ... for the introduction" &2d8d 74 72 6f 64 75 63 74 69 6f 6e &2d97 1f 02 05 ; TAB(&02, &05) &2d9a 41 6e 79 20 6f 74 68 65 72 20 6b 65 79 20 73 74 ; "Any other key starts game " &2daa 61 72 74 73 20 67 61 6d 65 20 &2db4 11 80 ; COLOUR 128 &2db6 11 01 ; COLOUR 1 &2db8 1c 1b 15 1e 0d ; define text window x:(&1b, &1e), y:(&0d, &15) ; define_keys_text_window_string &2dbd 1c 0b 18 27 0a ; define text window x:(&0b, &27), y:(&0a, &18) ; introduction_text &2dc2 1c 00 0c 13 01 ; define text window x:(&00, &13), y:(&01, &0c) &2dc7 19 04 00 00 2c 00 ; MOVE &0000, &002c &2dcd 19 05 fa 04 2c 00 ; DRAW &04fa, &002c &2dd3 00 00 00 &2dd6 20 20 4f 6e 63 65 20 75 70 6f 6e 20 61 20 74 69 : " Once upon a time, " &2de6 6d 65 2c 20 &2dea 69 6e 20 61 20 64 6f 77 64 79 20 63 68 65 6d 69 : "in a dowdy chemist's &2dfa 73 74 27 73 &2dfe 73 68 6f 70 2c 20 74 68 65 72 65 20 6c 69 76 65 : "shop, there lived a " &2e0e 64 20 61 20 &2e12 6c 6f 6e 65 6c 79 20 6f 6c 64 20 63 68 65 6d 69 : "lonely old chemist, " &2e22 73 74 2c 20 &2e26 6e 61 6d 65 64 20 43 79 72 69 6c 2e 20 20 20 20 : "named Cyril. " &2e36 20 20 20 20 &2e3a 20 20 49 66 20 79 6f 75 20 77 65 72 65 20 74 6f : " If you were to go " &2e4a 20 67 6f 20 &2e4e 69 6e 73 69 64 65 20 68 69 73 20 73 68 6f 70 2c : "inside his shop, " &2e5e 20 20 20 20 &2e62 1c 00 1f 13 0c ; define text window x:(&00, &13), y:(&0c, &1f) &2e67 0c ; CLS &2e68 1c 00 0c 13 01 ; define text window x:(&00, &13), y:(&01, &0c) &2e6d 1f 00 09 ; TAB(&00, &09) &2e70 00 00 00 00 00 00 &2e76 79 6f 75 20 77 6f 75 6c 64 20 73 65 65 20 6d 61 : "you would see many " &2e86 6e 79 20 20 &2e8a 73 68 65 6c 76 65 73 20 6c 61 64 65 6e 20 77 69 : "shelves laden with " &2e9a 74 68 20 20 &2e9e 62 6f 74 74 6c 65 73 2c 20 62 6f 78 65 73 2c 20 : "bottles, boxes, " &2eae 20 20 20 20 &2eb2 70 69 6c 6c 73 20 61 6e 64 20 70 6f 74 69 6f 6e : "pills and potions. " &2ec2 73 2e 20 20 &2ec6 20 20 44 69 73 61 73 74 65 72 20 73 74 72 75 63 : " Disaster struck " &2ed6 6b 20 20 20 &2eda 6f 6e 65 20 6e 69 67 68 74 20 77 68 65 6e 20 70 : "one night when poor " &2eea 6f 6f 72 20 &2eee 6f 6c 64 20 43 79 72 69 6c 20 63 61 72 65 6c 65 : "old Cyril carelessly" &2efe 73 73 6c 79 &2f02 73 77 61 6c 6c 6f 77 65 64 20 61 20 70 6f 77 65 : "swallowed a powerful" &2f12 72 66 75 6c &2f16 72 65 64 75 63 69 6e 67 20 61 67 65 6e 74 2e 20 : "reducing agent. " &2f26 20 20 20 20 &2f2a 20 20 50 6c 65 61 73 65 20 68 65 6c 70 20 6f 75 : " Please help our " &2f3a 72 20 20 20 &2f3e 73 68 72 75 6e 6b 65 6e 20 63 68 65 6d 69 73 74 : "shrunken chemist to " &2f4e 20 74 6f 20 &2f52 72 65 63 6f 76 65 72 20 62 79 20 20 20 20 20 20 : "recover by " &2f62 20 20 20 20 &2f66 63 6f 6c 6c 65 63 74 69 6e 67 20 68 69 73 20 70 : "collecting his pills" &2f76 69 6c 6c 73 &2f7a 61 6e 64 20 72 65 61 63 68 69 6e 67 20 74 68 65 : "and reaching the &2f8a 20 20 20 20 &2f8e 6d 61 67 69 63 20 65 6c 69 78 69 72 2e 20 20 20 : "magic elixir. " &2f9e 20 20 &2fa0 11 01 ; COLOUR 1 &2fa2 1c 00 1f 13 0f ; define text window x:(&00, &13), y:(&0f, &1f) &2fa7 0c ; CLS &2fa8 42 45 57 41 52 45 21 ; "BEWARE!" &2faf 0a 0d &2fb1 11 03 ; COLOUR 3 &2fb3 00 00 00 &2fb6 4c 69 74 74 6c 65 20 70 65 6f 70 6c 65 20 63 61 : "Little people can " &2fc6 6e 20 20 20 &2fca 68 61 76 65 20 62 69 67 20 70 72 6f 62 6c 65 6d : "have big problems! " &2fda 73 21 20 20 ; sound_2fde # Circularsaurus in introduction ; chan vol pitch dur &2fde 00 00 06 00 60 00 5a 00 ; introduction_shape_38_data &2fe6 f0 f0 f0 f0 f0 f0 f0 0f 0f 0f 0f 0f 0f 0f 0e 70 &2ff6 70 70 70 70 70 70 f0 f0 f0 f0 f0 f0 f0 0f 03 70 &3006 70 70 70 70 70 70 00 ; introduction_shape_39_data &300d f0 f0 c0 0f 0f 0f 0f 14 24 44 63 41 20 00 ; introduction_shape_3a_data &301b c0 a2 a4 94 05 14 24 22 24 0c 91 11 40 c0 02 91 &302b 01 3e 00 ; introduction_shape_3b_data &302e 10 00 ; unused &3030 f0 00 40 00 ; unused # Source code fragment corresponding to &22fe - &2300 &3034 39 36 2c 33 2c 32 ; "96,3,2" ; introduction_shape_addresses &303a e6 2f ; &2fe6 = introduction_shape_38_data &303c 0d 30 ; &300d = introduction_shape_39_data &303e 1b 30 ; &301b = introduction_shape_3a_data &303f 2e 30 ; &302e = introduction_shape_3b_data ; game_shape_addresses &3042 aa 22 ; &22aa = shape_38_data &3044 b5 22 ; &22b5 = shape_39_data &3046 bd 22 ; &22bd = shape_3a_data &3048 d5 22 ; &22d5 = shape_3b_data ; keys_as_text &304a 5a ; "Z" &304b 20 20 20 ; " " &304e 58 ; "X" &304f 20 20 20 ; " " &3052 2a ; "*" &3053 20 20 20 ; " " &3056 3f ; "?" &3057 20 20 20 ; " " ; start_introduction &305a a9 ff LDA #&ff &305c 85 00 STA &00 ; direction_velocities &305e a9 01 LDA #&01 &3060 85 01 STA &01 ; direction_velocities + 1 &3062 a2 07 LDX #&07 ; copy_introduction_shape_addresses_loop &3064 bd 3a 30 LDA &303a,X ; introduction_shape_addresses &3067 9d 70 0a STA &0a70,X ; shape_data + &70 &306a ca DEX &306b 10 f7 BPL &3064 ; copy_introduction_shape_addresses_loop &306d a9 c8 LDA #&c8 ; Read/Write BREAK/ESCAPE effect &306f a2 02 LDX #&02 ; Memory cleared on next reset, Escape disabled &3071 a0 00 LDY #&00 &3073 20 f4 ff JSR &fff4 ; OSBYTE &3076 20 1d 41 JSR &411d ; initialise_game &3079 a9 a6 LDA #&a6 ; &08a6 = game_screen_initialisation_string &307b a0 08 LDY #&08 &307d a2 18 LDX #&18 &307f 20 4b 39 JSR &394b ; write_string &3082 a9 04 LDA #&04 &3084 85 62 STA &62 ; game_speed &3086 a9 02 LDA #&02 &3088 85 90 STA &90 ; player_x &308a a9 cb LDA #&cb &308c 85 91 STA &91 ; player_y &308e a9 0d LDA #&0d ; PLAYER_SPRITE_RIGHT &3090 85 94 STA &94 ; player_sprite &3092 a9 c2 LDA #&c2 ; &2dc2 = introduction_text &3094 85 7c STA &7c ; intro_text_address_low &3096 a9 2d LDA #&2d &3098 85 7d STA &7d ; intro_text_address_high &309a 20 80 31 JSR &3180 ; write_three_lines_of_introduction_text &309d a9 0f LDA #&0f &309f 85 8c STA &8c ; plot_x_origin &30a1 a9 01 LDA #&01 ; &2c01 = introduction_room_00_data # Draw shop &30a3 a0 2c LDY #&2c &30a5 20 55 37 JSR &3755 ; plot_room_data_from_AY &30a8 20 80 31 JSR &3180 ; write_three_lines_of_introduction_text &30ab 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting ; cyril_walks_towards_shop_loop &30ae a5 90 LDA &90 ; player_x &30b0 c9 5a CMP #&5a &30b2 b0 0a BCS &30be ; cyril_jumps_into_shop_door &30b4 20 b0 31 JSR &31b0 ; wait_for_clock_and_check_for_escape &30b7 a2 00 LDX #&00 &30b9 20 f1 3d JSR &3df1 ; start_player_walking_right &30bc f0 f0 BEQ &30ae ; cyril_walks_towards_shop_loop ; cyril_jumps_into_shop_door &30be a2 00 LDX #&00 &30c0 20 08 3e JSR &3e08 ; start_player_jumping_right ; cyril_jumps_into_shop_door_loop &30c3 20 e2 43 JSR &43e2 ; wait_for_clock &30c6 20 89 3d JSR &3d89 ; apply_player_velocities &30c9 a5 4e LDA &4e ; jump_or_fall_timer &30cb d0 f6 BNE &30c3 ; cyril_jumps_into_shop_door_loop &30cd 20 44 33 JSR &3344 ; set_player_standing_in_introduction &30d0 a9 02 LDA #&02 &30d2 20 82 31 JSR &3182 ; write_A_lines_of_introduction_text &30d5 20 41 3c JSR &3c41 ; unplot_player &30d8 20 13 42 JSR &4213 ; longer_delay &30db 20 80 31 JSR &3180 ; write_three_lines_of_introduction_text &30de a9 d3 LDA #&d3 ; &54d3 = introduction_room_01_data &30e0 a0 54 LDY #&54 &30e2 20 55 37 JSR &3755 ; plot_room_data_from_AY # Draw platforms &30e5 20 13 42 JSR &4213 ; longer_delay &30e8 a9 02 LDA #&02 &30ea 20 82 31 JSR &3182 ; write_A_lines_of_introduction_text &30ed a9 e0 LDA #&e0 ; &54e0 = introduction_room_02_data &30ef a0 54 LDY #&54 &30f1 20 55 37 JSR &3755 ; plot_room_data_from_AY # Draw objects &30f4 20 52 33 JSR &3352 ; double_longer_delay &30f7 20 52 33 JSR &3352 ; double_longer_delay &30fa a9 05 LDA #&05 &30fc 20 82 31 JSR &3182 ; write_A_lines_of_introduction_text &30ff a9 93 LDA #&93 &3101 85 90 STA &90 ; player_x &3103 a9 97 LDA #&97 &3105 85 91 STA &91 ; player_y &3107 a9 15 LDA #&15 &3109 85 94 STA &94 ; player_sprite &310b 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting &310e c6 90 DEC &90 ; player_x ; cyril_walks_on_platform_loop &3110 20 b0 31 JSR &31b0 ; wait_for_clock_and_check_for_escape &3113 a2 00 LDX #&00 &3115 20 f5 3d JSR &3df5 ; start_player_walking_left &3118 a5 90 LDA &90 ; player_x &311a c9 6a CMP #&6a &311c b0 f2 BCS &3110 ; cyril_walks_on_platform_loop &311e a9 ff LDA #&ff &3120 85 4e STA &4e ; jump_or_fall_timer ; cyril_falls_from_platform_loop &3122 20 e2 43 JSR &43e2 ; wait_for_clock &3125 20 89 3d JSR &3d89 ; apply_player_velocities &3128 a5 4e LDA &4e ; jump_or_fall_timer &312a d0 f6 BNE &3122 ; cyril_falls_from_platform_loop ; cyril_walks_on_jar_platform_loop &312c 20 b0 31 JSR &31b0 ; wait_for_clock_and_check_for_escape &312f a2 00 LDX #&00 &3131 20 f5 3d JSR &3df5 ; start_player_walking_left &3134 a5 90 LDA &90 ; player_x &3136 c9 52 CMP #&52 &3138 b0 f2 BCS &312c ; cyril_walks_on_jar_platform_loop &313a a9 ff LDA #&ff &313c 85 4e STA &4e ; apply_player_velocities ; cyril_falls_from_jar_loop &313e 20 b0 31 JSR &31b0 ; wait_for_clock_and_check_for_escape &3141 20 89 3d JSR &3d89 ; apply_player_velocities &3144 a5 4e LDA &4e ; jump_or_fall_timer &3146 d0 f6 BNE &313e ; cyril_falls_from_jar_loop &3148 20 44 33 JSR &3344 ; set_player_standing_in_introduction &314b a9 09 LDA #&09 &314d 20 82 31 JSR &3182 ; write_A_lines_of_introduction_text &3150 a9 04 LDA #&04 &3152 85 62 STA &62 ; game_speed &3154 a9 45 LDA #&45 ; &2c45 = introduction_room_03_data &3156 a0 2c LDY #&2c &3158 20 55 37 JSR &3755 ; plot_room_data_from_AY # Draw platform and objects for circularsaurus &315b a2 de LDX #&de ; &2fde = sound_2fde &315d a0 2f LDY #&2f &315f 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for circularsaurus in introduction &3162 a0 06 LDY #&06 ; &0600 = circularsaurus_sprite_zero &3164 8c d2 41 STY &41d2 ; enemy_sprite_address_high &3167 c8 INY ; 7 ; &0700 = circularsaurus_mask_zero &3168 8c cf 41 STY &41cf ; enemy_mask_address_high &316b 20 a2 41 JSR &41a2 ; plot_enemy ; animate_circularsaurus_loop &316e 20 b0 31 JSR &31b0 ; wait_for_clock_and_check_for_escape &3171 e6 52 INC &52 ; enemy_x &3173 20 d2 43 JSR &43d2 ; wait_for_vsync &3176 20 6c 41 JSR &416c ; replot_enemy &3179 a5 52 LDA &52 ; enemy_x &317b c9 94 CMP #&94 &317d 90 ef BCC &316e ; animate_circularsaurus_loop ; leave &317f 60 RTS ; write_three_lines_of_introduction_text &3180 a9 03 LDA #&03 ; write_A_lines_of_introduction_text &3182 85 7a STA &7a ; count ; write_lines_of_introduction_text_loop &3184 20 8c 31 JSR &318c ; write_line_of_introduction_text &3187 c6 7a DEC &7a ; count &3189 d0 f9 BNE &3184 ; write_lines_of_introduction_text_loop &318b 60 RTS ; write_line_of_introduction_text &318c a2 14 LDX #&14 &318e a0 00 LDY #&00 ; write_line_of_introduction_text_loop &3190 b1 7c LDA (&7c),Y ; intro_text-address &3192 20 ee ff JSR &ffee ; OSWRCH &3195 c8 INY &3196 ca DEX &3197 d0 f7 BNE &3190 ; write_line_of_introduction_text_loop &3199 20 13 42 JSR &4213 ; longer_delay &319c a9 0a LDA #&0a ; move cursor down a line &319e 20 ee ff JSR &ffee ; OSWRCH &31a1 20 b3 31 JSR &31b3 ; check_for_escape &31a4 a5 7c LDA &7c ; intro_text_address_low &31a6 18 CLC &31a7 69 14 ADC #&14 &31a9 85 7c STA &7c ; intro_text_address_low &31ab 90 d2 BCC &317f ; leave &31ad e6 7d INC &7d ; intro_text_address_high &31af 60 RTS ; wait_for_clock_and_check_for_escape &31b0 20 e2 43 JSR &43e2 ; wait_for_clock ; check_for_escape &31b3 a5 ff LDA &ff ; os_escape_flag &31b5 10 c8 BPL &317f ; leave &31b7 a9 7c LDA #&7c ; Clear ESCAPE condition &31b9 20 f4 ff JSR &fff4 ; OSBYTE ; intro_entry_point &31bc 20 4f 32 JSR &324f ; swap_nmi_handler_page_with_buffer ; title_screen &31bf a2 ff LDX #&ff &31c1 9a TXS &31c2 a2 03 LDX #&03 ; Enable ESCAPE, clear memory on BREAK &31c4 a0 00 LDY #&00 &31c6 a9 c8 LDA #&c8 ; Read/Write BREAK/ESCAPE effect &31c8 20 f4 ff JSR &fff4 ; OSBYTE &31cb a9 38 LDA #&38 # Use user defined characters &31cd 8d 67 03 STA &0367 ; os_font_flag # for &40 - &5f, &60 - &7f and &80 - &9f &31d0 a9 2b LDA #&2b ; &2b00 = font_data_zero &31d2 8d 69 03 STA &0369 ; os_font_locations + 1 &31d5 a2 05 LDX #&05 ; &0500 = font_data_one &31d7 8e 6a 03 STX &036a ; os_font_locations + 2 &31da ca DEX ; &0400 = font_data_two &31db 8e 6b 03 STX &036b ; os_font_locations + 3 ; title_screen_without_initialisation &31de 20 62 32 JSR &3262 ; write_current_keys &31e1 a9 a6 LDA #&a6 ; &ffa6 = os_null_vector_handler &31e3 cd 24 02 CMP &0224 ; net_vector_low &31e6 f0 06 BEQ &31ee ; skip_resetting_net_vector &31e8 8d 24 02 STA &0224 ; net_vector_low # Bug: doesn't reset net_vector_high &31eb a9 01 LDA #&01 &31ed 2c a9 02 BIT &02a9 ; skip_resetting_net_vector #31ee LDA #&02 # Longer on title screen if no reset &31f0 85 04 STA &04 ; timer_low &31f2 85 05 STA &05 ; timer_high &31f4 a9 04 LDA #&04 &31f6 85 62 STA &62 ; game_speed ; title_screen_loop &31f8 20 e2 43 JSR &43e2 ; wait_for_clock &31fb e6 04 INC &04 ; timer_low &31fd d0 0a BNE &3209 ; check_for_title_screen_keys &31ff c6 05 DEC &05 ; timer_high &3201 d0 06 BNE &3209 ; check_for_title_screen_keys ; to_start_introduction &3203 20 5a 30 JSR &305a ; start_introduction &3206 4c bf 31 JMP &31bf ; title_screen ; check_for_title_screen_keys &3209 a5 ec LDA &ec ; os_most_recently_pressed_key &320b f0 eb BEQ &31f8 ; title_screen_loop &320d 09 80 ORA #&80 &320f c9 a5 CMP #&a5 ; I &3211 f0 f0 BEQ &3203 ; to_start_introduction &3213 c9 c6 CMP #&c6 ; K &3215 f0 72 BEQ &3289 ; define_keys ; prepare_to_run_game &3217 a2 07 LDX #&07 ; copy_game_shape_addresses_loop &3219 bd 42 30 LDA &3042,X ; game_shape_addresses &321c 9d 70 0a STA &0a70,X ; shape_data + &70 &321f ca DEX &3220 10 f7 BPL &3219 ; copy_game_shape_addresses_loop &3222 a2 03 LDX #&03 ; copy_keys_loop &3224 bd 58 33 LDA &3358,X ; intro_keys &3227 95 20 STA &20,X ; keys &3229 ca DEX &322a 10 f8 BPL &3224 ; copy_keys_loop &322c a2 0b LDX #&0b &322e a9 55 LDA #&55 ; &2d55 = clear_title_screen_keys_string &3230 a0 2d LDY #&2d &3232 20 4b 39 JSR &394b ; write_string ; wait_for_no_keys_pressed &3235 a5 ec LDA &ec ; os_most_recently_pressed_key &3237 d0 fc BNE &3235 ; wait_for_no_keys_pressed &3239 a9 0f LDA #&0f # Use OS font for characters &20 - &7f &323b 8d 67 03 STA &0367 ; os_font_flag &323e 20 4f 32 JSR &324f ; swap_nmi_handler_page_with_buffer &3241 a0 32 LDY #&32 ; relocate_run_game_loop &3243 b9 5c 33 LDA &335c,Y ; unrelocated_run_game &3246 99 00 01 STA &0100,Y ; run_game &3249 88 DEY &324a 10 f7 BPL &3243 ; relocate_run_game_loop &324c 4c 00 01 JMP &0100 ; run_game ; swap_nmi_handler_page_with_buffer &324f a0 00 LDY #&00 ; swap_nmi_handler_page_with_buffer_loop &3251 b9 7b 33 LDA &337b,Y ; initial_player_right_zero_sprite &3254 be 00 0d LDX &0d00,Y ; nmi_page &3257 99 00 0d STA &0d00,Y ; player_right_zero_sprite &325a 8a TXA &325b 99 7b 33 STA &337b,Y ; nmi_page_buffer &325e c8 INY &325f d0 f0 BNE &3251 ; swap_nmi_handler_page_with_buffer_loop &3261 60 RTS ; write_current_keys &3262 20 38 33 JSR &3338 ; initialise_define_keys_screen &3265 a2 bb LDX #&bb &3267 a9 02 LDA #&02 ; &2d02 = current_keys_string &3269 a0 2d LDY #&2d &326b 20 4b 39 JSR &394b ; write_string &326e a0 10 LDY #&10 &3270 a2 00 LDX #&00 ; write_current_keys_loop &3272 bd 4a 30 LDA &304a,X ; keys_as_text &3275 20 ee ff JSR &ffee ; OSWRCH &3278 e8 INX &3279 88 DEY &327a f0 0c BEQ &3288 ; leave &327c 98 TYA &327d 29 03 AND #&03 &327f d0 f1 BNE &3272 ; write_current_keys_loop &3281 a9 0a LDA #&0a ; move cursor down a line &3283 20 ee ff JSR &ffee ; OSWRCH &3286 d0 ea BNE &3272 ; write_current_keys_loop ; leave &3288 60 RTS ; define_keys &3289 20 38 33 JSR &3338 ; initialise_define_keys_screen &328c a2 12 LDX #&12 &328e a9 f0 LDA #&f0 ; &2cf0 = key_selection_string &3290 a0 2c LDY #&2c &3292 20 4b 39 JSR &394b ; write_string &3295 a2 03 LDX #&03 &3297 a9 00 LDA #&00 &3299 85 85 STA &85 ; offset ; wipe_intro_keys_loop &329b 9d 58 33 STA &3358,X ; intro_keys &329e ca DEX &329f 10 fa BPL &329b ; wipe_intro_keys_loop &32a1 a2 0f LDX #&0f &32a3 a9 20 LDA #&20 ; " " ; wipe_keys_as_text_loop &32a5 9d 4a 30 STA &304a,X ; keys_as_text &32a8 ca DEX &32a9 10 fa BPL &32a5 ; wipe_keys_as_text_loop &32ab a2 04 LDX #&04 &32ad a9 1b LDA #&1b ; &2d1b = left_string &32af a0 2d LDY #&2d &32b1 20 d2 32 JSR &32d2 ; define_key &32b4 a2 05 LDX #&05 &32b6 a9 22 LDA #&22 ; &2d22 = right_string &32b8 a0 2d LDY #&2d &32ba 20 d2 32 JSR &32d2 ; define_key &32bd a2 0a LDX #&0a &32bf a9 2a LDA #&2a ; &2d2a = jump_climb_string &32c1 a0 2d LDY #&2d &32c3 20 d2 32 JSR &32d2 ; define_key &32c6 a2 0a LDX #&0a &32c8 a9 37 LDA #&37 ; &2d37 = climb_down_string &32ca a0 2d LDY #&2d &32cc 20 d2 32 JSR &32d2 ; define_key &32cf 4c de 31 JMP &31de ; title_screen_without_initialisation ; define_key &32d2 20 4b 39 JSR &394b ; write_string &32d5 a9 86 LDA #&86 ; Get text cursor position &32d7 20 f4 ff JSR &fff4 ; OSBYTE &32da 8c eb 2c STY &2ceb ; tab_for_define_key_string + 2 &32dd a2 07 LDX #&07 &32df a9 e9 LDA #&e9 ; &2ce9 = tab_for_define_key_string &32e1 a0 2c LDY #&2c &32e3 20 4b 39 JSR &394b ; write_string ; wait_for_key &32e6 a5 ec LDA &ec ; os_most_recently_pressed_key &32e8 f0 fc BEQ &32e6 ; wait_for_key &32ea 09 80 ORA #&80 &32ec a0 2b LDY #&2b ; check_for_key_loop &32ee d9 bd 2c CMP &2cbd,Y ; key_codes &32f1 f0 05 BEQ &32f8 ; found_key &32f3 88 DEY &32f4 10 f8 BPL &32ee ; check_for_key_loop &32f6 30 ee BMI &32e6 ; wait_for_key # Always branches ; found_key &32f8 a6 85 LDX &85 ; offset ; check_for_clash_loop &32fa dd 58 33 CMP &3358,X ; intro_keys &32fd f0 e7 BEQ &32e6 ; wait_for_key &32ff ca DEX &3300 10 f8 BPL &32fa ; check_for_clash_loop &3302 a6 85 LDX &85 ; offset &3304 9d 58 33 STA &3358,X ; intro_keys &3307 e6 85 INC &85 ; offset &3309 8a TXA &330a 0a ASL A &330b 0a ASL A &330c aa TAX &330d c0 23 CPY #&23 &330f b0 0f BCS &3320 ; is_word &3311 b9 9a 2c LDA &2c9a,Y ; key_characters &3314 9d 4a 30 STA &304a,X ; keys_as_text &3317 20 ee ff JSR &ffee ; OSWRCH ; leave_after_writing_two_newlines &331a 20 e7 ff JSR &ffe7 ; OSNEWL &331d 4c e7 ff JMP &ffe7 ; OSNEWL ; is_word &3320 98 TYA &3321 e9 23 SBC #&23 &3323 0a ASL A &3324 0a ASL A &3325 a8 TAY ; copy_key_word_loop &3326 b9 76 2c LDA &2c76,Y ; key_words &3329 9d 4a 30 STA &304a,X ; keys_as_text &332c 20 ee ff JSR &ffee ; OSWRCH &332f e8 INX &3330 c8 INY &3331 98 TYA &3332 29 03 AND #&03 &3334 d0 f0 BNE &3326 ; copy_key_word_loop &3336 f0 e2 BEQ &331a ; leave_after_writing_two_newlines # Always branches ; initialise_define_keys_screen &3338 20 62 40 JSR &4062 ; initialise_mode_4_screen_with_logo &333b a9 bd LDA #&bd ; &2dbd = define_keys_text_window_string &333d a0 2d LDY #&2d &333f a2 05 LDX #&05 &3341 4c 4b 39 JMP &394b ; write_string ; set_player_standing_in_introduction &3344 20 13 42 JSR &4213 ; longer_delay &3347 a9 1d LDA #&1d ; PLAYER_SPRITE_STANDING &3349 85 94 STA &94 ; player_sprite &334b a9 00 LDA #&00 &334d 85 95 STA &95 ; player_x_velocity &334f 4c 58 3e JMP &3e58 ; finish_updating_player_after_floor_check ; double_longer_delay &3352 20 13 42 JSR &4213 ; longer_delay &3355 4c 13 42 JMP &4213 ; longer_delay ; intro_keys &3358 e1 ; Z &3359 c2 ; X &335a c8 ; ' &335b e8 ; / # &335c - &337a is moved to &0100 - &011e at &324e ; run_game &0100 a2 0e LDX #&0e ; &010e = load_elixir_command &0102 a0 01 LDY #&01 &0104 20 f7 ff JSR &fff7 ; OSCLI &0107 a2 1a LDX #&1a ; &011a = run_d00_command &0109 a0 01 LDY #&01 &010b 4c f7 ff JMP &fff7 ; OSCLI ; load_elixir_command &010e 4c 4f 41 44 20 45 6c 69 78 69 72 0d ; "LOAD Elixir ; run_d00_command &011a 2f 44 30 30 0d ; "/D00" # &337b - &347a is copied to &0d00 - &0dff at &3251 for the introduction ; initial_player_right_zero_sprite ; nmi_page_buffer ; unrelocated_player_right_zero_sprite &337b 00 00 00 11 88 00 33 cc 00 33 ee 00 77 ee 00 66 # &337b - &347a is a copy of &0d00 - &0dff &338b 22 00 55 ff 00 45 13 00 45 22 00 44 26 00 22 44 &339b 00 33 88 00 22 44 00 22 44 00 44 22 00 44 22 00 &33ab 44 22 00 88 11 00 88 11 00 99 11 00 99 11 00 88 &33bb 99 00 88 11 00 88 11 00 67 19 00 55 dd 00 44 11 &33cb 00 44 11 00 44 11 00 44 11 00 44 11 00 77 ee 00 &33db 23 66 00 22 5f 00 23 55 00 46 df 00 8d 9d 00 df &33eb 9b 00 ee 66 00 77 77 88 33 77 88 ; unrelocated_player_right_zero_mask &33f6 ff ff ff ee 77 ff cc 33 ff cc 11 ff 88 11 ff 88 &3406 11 ff 88 00 ff 88 00 ff 88 11 ff 88 11 ff cc 33 &3416 ff cc 77 ff cc 33 ff cc 33 ff 88 11 ff 88 11 ff &3426 88 11 ff 00 00 ff 00 00 ff 00 00 ff 00 00 ff 00 &3436 00 ff 00 00 ff 00 00 ff 88 00 ff 88 00 ff 88 00 &3446 ff 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 11 ff &3456 cc 11 ff cc 00 ff cc 00 ff 88 00 ff 00 00 ff 00 &3466 00 ff 11 99 ff 88 88 77 cc 88 77 ; unrelocated_sound_0df6 ; chan vol pitch dur &3471 11 00 01 00 00 00 01 00 ; unused &3479 00 00 # &347b - &57ff is shared by introduction and game # Continuation of plot_beanstalk_leaves &347b 69 09 ADC #&09 &347d 8d 52 54 STA &5452 ; beanstalk_leaves_graphics_data + 2 (shape y) &3480 e9 02 SBC #&02 &3482 8d 54 54 STA &5454 ; beanstalk_leaves_graphics_data + 4 (fill y) &3485 a5 3f LDA &3f ; beanstalk_height_to_plot &3487 29 01 AND #&01 &3489 f0 03 BEQ &348e ; set_leaf_x &348b a9 bc LDA #&bc # Left leaf &348d 2c a9 c8 BIT &c8a9 ; set_leaf_x # LDA #&c8 # Right leaf &3490 8d 51 54 STA &5451 ; beanstalk_leaves_graphics_data + 1 (shape x) &3493 a9 50 LDA #&50 ; &5450 = beanstalk_leaves_graphics_data &3495 a0 54 LDY #&54 &3497 4c 55 37 JMP &3755 ; plot_room_data_from_AY ; update_top_of_beanstalk # Room &24 &349a a5 65 LDA &65 ; replot_update # Negative if replotting room &349c f0 11 BEQ &34af ; to_finished_updating_room &349e ae 97 0c LDX &0c97 ; beanstalk_height_in_upper_room &34a1 30 02 BMI &34a5 ; initialise_upper_room_beanstalk &34a3 d0 05 BNE &34aa ; plot_top_of_beanstalk ; initialise_upper_room_beanstalk &34a5 a2 01 LDX #&01 &34a7 8e 97 0c STX &0c97 ; beanstalk_height_in_upper_room ; plot_top_of_beanstalk &34aa a9 00 LDA #&00 &34ac 20 4c 34 JSR &344c ; plot_beanstalk ; to_finished_updating_room &34af 4c 3a 30 JMP &303a ; finished_updating_room ; update_soap # Room &27 &34b2 a4 91 LDY &91 ; player_y &34b4 c0 9d CPY #&9d &34b6 b0 f7 BCS &34af ; to_finished_updating_room &34b8 c0 7f CPY #&7f &34ba 90 f3 BCC &34af ; to_finished_updating_room # Are the player's feet in the soap? &34bc a6 90 LDX &90 ; player_x &34be e0 77 CPX #&77 &34c0 90 ed BCC &34af ; to_finished_updating_room &34c2 ad 90 0c LDA &0c90 ; objects_collected + &18 (OBJECT_COVERING_OF_OIL) &34c5 d0 06 BNE &34cd ; not_covered_with_oil &34c7 20 3b 44 JSR &443b ; play_chime # Play chime to indicate oil has been removed &34ca ce 90 0c DEC &0c90 ; objects_collected + &18 (OBJECT_COVERING_OF_OIL) ; not_covered_with_oil &34cd a5 90 LDA &90 ; player_x &34cf c9 78 CMP #&78 &34d1 b0 dc BCS &34af ; to_finished_updating_room &34d3 e6 90 INC &90 ; player_x # Stop player moving out of soap bottle &34d5 d0 d8 BNE &34af ; to_finished_updating_room # Always branches ; update_elixir # Room &22 &34d7 ad 93 0c LDA &0c93 ; beanstalk_has_been_planted &34da d0 29 BNE &3505 ; check_if_player_is_on_slope # Zero if bean has been planted &34dc a5 7a LDA &7a ; score &34de c9 28 CMP #&28 ; 40 # Has the player collected all forty red pills? &34e0 90 23 BCC &3505 ; check_if_player_is_on_slope &34e2 a5 65 LDA &65 ; replot_update # Negative if replotting room &34e4 d0 04 BNE &34ea ; plot_elixir &34e6 a5 7b LDA &7b ; elixir_plotted # Zero if elixir bottle has been plotted &34e8 f0 09 BEQ &34f3 ; skip_plotting_elixir ; plot_elixir &34ea a9 08 LDA #&08 ; &5408 = elixir_graphics_data &34ec a0 54 LDY #&54 &34ee 20 55 37 JSR &3755 ; plot_room_data_from_AY # Plot elixir bottle &34f1 85 7b STA &7b ; elixir_plotted # Set to zero to indicate elixir bottle plotted ; skip_plotting_elixir &34f3 20 4b 35 JSR &354b ; update_elixir_label &34f6 a5 91 LDA &91 ; player_y &34f8 c9 1e CMP #&1e &34fa b0 09 BCS &3505 ; check_if_player_is_on_slope &34fc a5 90 LDA &90 ; player_x &34fe c9 30 CMP #&30 &3500 b0 03 BCS &3505 ; check_if_player_is_on_slope # Is the player touching the elixir bottle? &3502 4c a4 3f JMP &3fa4 ; completion_screen # If so, the game has been completed! ; check_if_player_is_on_slope &3505 a5 90 LDA &90 ; player_x &3507 c9 40 CMP #&40 &3509 b0 06 BCS &3511 ; to_finished_updating_room &350b c9 04 CMP #&04 &350d b0 05 BCS &3514 ; consider_slipping_on_slope &350f e6 90 INC &90 ; player_x # Stop player moving left into darkroom ; to_finished_updating_room &3511 4c 3a 30 JMP &303a ; finished_updating_room ; consider_slipping_on_slope &3514 ae 90 0c LDX &0c90 ; objects_collected + &18 (OBJECT_COVERING_OF_OIL) &3517 d0 f8 BNE &3511 ; to_finished_updating_room # Zero if player has covering of oil &3519 a4 91 LDY &91 ; player_y &351b c0 ab CPY #&ab &351d 90 f2 BCC &3511 ; to_finished_updating_room &351f c0 c9 CPY #&c9 &3521 b0 ee BCS &3511 ; to_finished_updating_room &3523 c9 2b CMP #&2b &3525 90 14 BCC &353b ; consider_slipping_left ; consider_slipping_right &3527 a5 4e LDA &4e ; jump_or_fall_timer &3529 d0 e6 BNE &3511 ; to_finished_updating_room &352b e6 90 INC &90 ; player_x # Move player right &352d a2 01 LDX #&01 &352f a9 15 LDA #&15 ; PLAYER_SPRITE_LEFT # Keep player facing left ; slip_on_slope &3531 85 94 STA &94 ; player_sprite &3533 86 95 STX &95 ; player_x_velocity &3535 a9 ff LDA #&ff # Move player down slope &3537 85 4e STA &4e ; jump_or_fall_timer &3539 d0 d6 BNE &3511 ; to_finished_updating_room # Always branches ; consider_slipping_left &353b c9 17 CMP #&17 &353d 90 d2 BCC &3511 ; to_finished_updating_room &353f a5 4e LDA &4e ; jump_or_fall_timer &3541 d0 ce BNE &3511 ; to_finished_updating_room &3543 c6 90 DEC &90 ; player_x # Move player left &3545 a2 ff LDX #&ff &3547 a9 0d LDA #&0d ; PLAYER_SPRITE_RIGHT # Keep player facing right &3549 d0 e6 BNE &3531 ; skip_on_slope # Always branches ; update_elixir_label &354b ad 95 0c LDA &0c95 ; beanstalk_timer_lower &354e 29 07 AND #&07 &3550 f0 15 BEQ &3567 ; plot_elixir_label &3552 c9 04 CMP #&04 &3554 f0 01 BEQ &3557 ; unplot_elixir_label &3556 60 RTS ; unplot_elixir_label &3557 a9 0c LDA #&0c &3559 85 57 STA &57 ; area_width &355b a9 08 LDA #&08 &355d 85 56 STA &56 ; area_height &355f 0a ASL A &3560 85 55 STA &55 ; area_y &3562 85 54 STA &54 ; area_x &3564 4c 37 2f JMP &2f37 ; unplot_area_of_screen ; plot_elixir_label &3567 a2 0e LDX #&0e ; &540e = elixir_label_string &3569 a0 54 LDY #&54 &356b 4c 4b 40 JMP &404b ; write_null_terminated_string ; update_flashbulbs # Rooms &02, &05, &12, &1e and &25 &356e a5 65 LDA &65 ; replot_update # Negative if replotting room &3570 f0 1f BEQ &3591 ; skip_initialising_flashbulbs &3572 a9 53 LDA #&53 ; &53e4 = flashbulb_sprite, &53e2 = flashbulb_mask &3574 8d cf 41 STA &41cf ; enemy_mask_address_high &3577 8d d2 41 STA &41d2 ; enemy_sprite_address_high &357a a5 64 LDA &64 ; room_initialised # Zero if room is being initialised &357c d0 0d BNE &358b ; to_plot_enemy &357e a5 90 LDA &90 ; player_x &3580 29 fc AND #&fc &3582 38 SEC &3583 e9 0c SBC #&0c &3585 b0 02 BCS &3589 ; set_enemy_x # Branch if player at right of room &3587 a9 98 LDA #&98 # Set flashbulb at right of room if entering from left ; set_enemy_x &3589 85 52 STA &52 ; enemy_x # Set flashbulb already moving if entering from right ; to_plot_enemy &358b 20 a2 41 JSR &41a2 ; plot_enemy # Plot flashbulb when replotting room ; to_finished_updating_room &358e 4c 3a 30 JMP &303a ; finished_updating_room ; skip_initialising_flashbulbs &3591 a5 52 LDA &52 ; enemy_x &3593 c9 98 CMP #&98 &3595 d0 11 BNE &35a8 ; move_flashbulb &3597 c6 59 DEC &59 ; flashbulb_cooldown &3599 d0 f3 BNE &358e ; to_finished_updating_room &359b a5 5a LDA &5a ; flashbulb_maximum_cooldown &359d 85 59 STA &59 ; flashbulb_cooldown &359f a2 48 LDX #&48 ; &5448 = sound_5448 &35a1 a0 54 LDY #&54 &35a3 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for firing flashbulb &35a6 a5 52 LDA &52 ; enemy_x ; move_flashbulb &35a8 38 SEC &35a9 e9 04 SBC #&04 # Move flashbulb left &35ab b0 08 BCS &35b5 ; not_next_flashbulb # Has the flashbulb reached the left edge of the screen? &35ad a5 53 LDA &53 ; enemy_y &35af 65 56 ADC &56 ; flashbulb_spacing &35b1 85 53 STA &53 ; enemy_y &35b3 a9 98 LDA #&98 # Position next flashbulb at right edge of screen &35b5 85 52 STA &52 ; enemy_x ; not_next_flashbulb &35b7 20 6c 41 JSR &416c ; replot_enemy ; check_for_collision_with_flashbulb &35ba a5 91 LDA &91 ; player_y &35bc 38 SEC &35bd e5 53 SBC &53 ; enemy_y &35bf 90 06 BCC &35c7 ; check_y_max &35c1 c9 07 CMP #&07 &35c3 90 08 BCC &35cd ; check_x_min &35c5 b0 c7 BCS &358e ; to_finished_updating_room # Always branches ; check_y_max &35c7 49 ff EOR #&ff &35c9 c9 29 CMP #&29 &35cb b0 c1 BCS &358e ; to_finished_updating_room ; check_x_min &35cd a5 90 LDA &90 ; player_x &35cf 38 SEC &35d0 e5 52 SBC &52 ; enemy_x &35d2 90 06 BCC &35da ; check_x_max &35d4 c9 08 CMP #&08 &35d6 b0 b6 BCS &358e ; to_finished_updating_room &35d8 90 06 BCC &35e0 ; flashbulb_hit_player # Always branches ; check_x_max &35da 49 ff EOR #&ff &35dc c9 0b CMP #&0b &35de b0 ae BCS &358e ; to_finished_updating_room ; flashbulb_hit_player &35e0 ad 8d 0c LDA &0c8d ; objects_collected + &15 (OBJECT_EYE_SHIELD) &35e3 d0 0b BNE &35f0 ; flashbulb_killed_player # Zero if player is carrying unspent eyeshield &35e5 a5 03 LDA &03 ; eye_shield_uses_remaining &35e7 f0 04 BEQ &35ed ; lose_eye_shield &35e9 c6 03 DEC &03 ; eye_shield_uses_remaining &35eb 10 06 BPL &35f3 ; skip_killing_player ; lose_eye_shield # Set to one to indicate eyeshield is spent &35ed ee 8d 0c INC &0c8d ; objects_collected + &15 (OBJECT_EYE_SHIELD) ; flashbulb_killed_player &35f0 20 2c 42 JSR &422c ; start_player_freefalling ; skip_killing_player &35f3 a2 00 LDX #&00 ; &5400 = sound_5400 &35f5 a0 54 LDY #&54 &35f7 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for flashbulb hitting player &35fa a9 00 LDA #&00 &35fc 85 52 STA &52 ; enemy_x &35fe a9 03 LDA #&03 # Set all colours to white &3600 8d 42 54 STA &5442 ; flashbulb_colour_graphics_data + 2 &3603 a9 07 LDA #&07 ; W &3605 8d 43 54 STA &5443 ; flashbulb_colour_graphics_data + 3 &3608 a9 40 LDA #&40 ; &5440 = flashbulb_colour_graphics_data &360a 85 70 STA &70 ; room_data_address_low &360c a9 54 LDA #&54 &360e 85 71 STA &71 ; room_data_address_high ; set_all_colours_to_white_loop &3610 20 59 37 JSR &3759 ; plot_room_data_from_address &3613 ce 42 54 DEC &5442 ; flashbulb_colour_graphics_data + 2 &3616 d0 f8 BNE &3610 ; set_all_colours_to_white_loop &3618 a9 0a LDA #&0a &361a 85 85 STA &85 ; count ; delay_loop &361c 20 e2 43 JSR &43e2 ; wait_for_clock &361f c6 85 DEC &85 ; count &3621 d0 f9 BNE &361c ; delay_loop &3623 a9 03 LDA #&03 # Restore colours &3625 8d 42 54 STA &5442 ; flashbulb_colour_graphics_data + 2 &3628 a9 00 LDA #&00 ; K &362a 8d 43 54 STA &5443 ; flashbulb_colour_graphics_data + 3 &362d 20 59 37 JSR &3759 ; plot_room_data_from_address &3630 ce 42 54 DEC &5442 ; flashbulb_colour_graphics_data + 2 &3633 ad a2 08 LDA &08a2 ; game_colour_string + 2 &3636 8d 43 54 STA &5443 ; flashbulb_colour_graphics_data + 3 &3639 20 59 37 JSR &3759 ; plot_room_data_from_address &363c a9 01 LDA #&01 ; R &363e 8d 42 54 STA &5442 ; flashbulb_colour_graphics_data + 2 &3641 8d 43 54 STA &5443 ; flashbulb_colour_graphics_data + 3 &3644 20 59 37 JSR &3759 ; plot_room_data_from_address &3647 4c 3a 30 JMP &303a ; finished_updating_room ; plot_object &364a 84 81 STY &81 ; y ; plot_object_using_y &364c 20 99 3c JSR &3c99 ; calculate_screen_address_from_X_and_y &364f a2 00 LDX #&00 ; plot_object_row_loop &3651 a0 00 LDY #&00 &3653 a5 8e LDA &8e ; object_width &3655 85 8f STA &8f ; columns_remaining ; plot_object_column_loop &3657 bd 00 10 LDA &1000,X # actually LDA object_sprite_address,X &365a 91 78 STA (&78),Y ; screen_address &365c e8 INX &365d c6 8f DEC &8f ; columns_remaining &365f f0 06 BEQ &3667 ; consider_plotting_next_row &3661 98 TYA &3662 69 08 ADC #&08 # Move right four pixels &3664 a8 TAY &3665 90 f0 BCC &3657 ; plot_object_column_loop ; consider_plotting_next_row &3667 c6 8d DEC &8d ; rows_remaining &3669 f0 0f BEQ &367a ; leave &366b e6 81 INC &81 ; y &366d e6 78 INC &78 ; screen_address_low &366f a5 78 LDA &78 ; screen_address_low &3671 29 07 AND #&07 &3673 d0 dc BNE &3651 ; plot_object_row_loop &3675 20 a4 3c JSR &3ca4 ; recalculate_screen_address_using_y &3678 90 d7 BCC &3651 ; plot_object_row_loop # Always branches ; leave &367a 60 RTS ; fill_area &367b 85 83 STA &83 ; fill_type &367d 86 80 STX &80 ; x &367f 84 82 STY &82 ; fill_y &3681 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &3684 20 a4 36 JSR &36a4 ; fill_line &3687 a4 81 LDY &81 ; y &3689 84 82 STY &82 ; fill_y ; fill_area_down_loop &368b e6 81 INC &81 ; y &368d 20 a4 3c JSR &3ca4 ; recalculate_screen_address_using_y &3690 20 a4 36 JSR &36a4 ; fill_line &3693 10 f6 BPL &368b ; fill_area_down_loop &3695 a4 82 LDY &82 ; fill_y &3697 84 81 STY &81 ; y ; fill_area_up_loop &3699 c6 81 DEC &81 ; y &369b 20 a4 3c JSR &3ca4 ; recalculate_screen_address_using_y &369e 20 a4 36 JSR &36a4 ; fill_line &36a1 10 f6 BPL &3699 ; fill_area_up_loop &36a3 60 RTS ; fill_line &36a4 a5 81 LDA &81 ; y &36a6 29 01 AND #&01 &36a8 18 CLC &36a9 65 83 ADC &83 ; fill_type &36ab 85 84 STA &84 ; fill_pattern_offset &36ad a0 00 LDY #&00 &36af 84 85 STY &85 ; screen_offset &36b1 b1 78 LDA (&78),Y ; screen_address &36b3 f0 2e BEQ &36e3 ; fill_long_line ; fill_short_line &36b5 aa TAX &36b6 29 66 AND #&66 ; 0330 &36b8 f0 03 BEQ &36bd ; fill_middle_of_short_line &36ba a9 ff LDA #&ff # Leave with negative to indicate nothing was filled &36bc 60 RTS ; fill_middle_of_short_line &36bd 8a TXA &36be c9 99 CMP #&99 ; 3003 &36c0 f0 0c BEQ &36ce ; fill_two_pixels_in_short_line &36c2 c9 88 CMP #&88 ; 3000 &36c4 d0 1d BNE &36e3 ; fill_long_line &36c6 a2 77 LDX #&77 ; 0333 &36c8 20 d6 36 JSR &36d6 ; fill_part_of_byte &36cb a9 00 LDA #&00 # Leave with positive to indicate something was filled &36cd 60 RTS ; fill_two_pixels_in_short_line &36ce a2 66 LDX #&66 ; 0330 &36d0 20 d6 36 JSR &36d6 ; fill_part_of_byte &36d3 a9 00 LDA #&00 # Leave with positive to indicate something was filled &36d5 60 RTS ; fill_part_of_byte &36d6 a4 84 LDY &84 ; fill_pattern_offset &36d8 8a TXA &36d9 39 98 0c AND &0c98,Y ; fill_patterns &36dc a4 85 LDY &85 ; screen_offset &36de 11 78 ORA (&78),Y ; screen_address &36e0 91 78 STA (&78),Y ; screen_address &36e2 60 RTS ; fill_long_line ; find_left_of_line_loop &36e3 38 SEC &36e4 a5 78 LDA &78 ; screen_address_low &36e6 e9 08 SBC #&08 # Move left four pixels &36e8 85 78 STA &78 ; screen_address_low &36ea b0 02 BCS &36ee ; skip_page &36ec c6 79 DEC &79 ; screen_address_high ; skip_page &36ee a0 00 LDY #&00 &36f0 b1 78 LDA (&78),Y ; screen_address &36f2 f0 ef BEQ &36e3 ; find_left_of_line_loop &36f4 30 0f BMI &3705 ; fill_three_pixels_at_left_of_line &36f6 0a ASL A &36f7 30 09 BMI &3702 ; fill_two_pixels_at_left_of_line &36f9 0a ASL A &36fa 30 02 BMI &36fe ; fill_one_pixel_at_left_of_line &36fc 10 0c BPL &370a ; skip_filling_pixels_at_left_of_line # Always branches ; fill_one_pixel_at_left_of_line &36fe a2 11 LDX #&11 ; 0003 &3700 d0 05 BNE &3707 ; fill_left_pixels ; fill_two_pixels_at_left_of_line &3702 a2 33 LDX #&33 ; 0033 &3704 2c a2 77 BIT &77a2 ; fill_three_pixels_at_left_of_line #3705 LDX #&77 ; 0333 ; fill_left_pixels &3707 20 d6 36 JSR &36d6 ; fill_part_of_byte ; skip_filling_pixels_at_left_of_line &370a a4 84 LDY &84 ; fill_pattern_offset &370c b9 98 0c LDA &0c98,Y ; fill_patterns &370f aa TAX &3710 a0 08 LDY #&08 &3712 18 CLC ; fill_middle_of_line_loop &3713 91 78 STA (&78),Y ; screen_address &3715 98 TYA &3716 69 08 ADC #&08 # Move right four pixels &3718 a8 TAY &3719 b1 78 LDA (&78),Y ; screen_address &371b d0 03 BNE &3720 ; found_right_of_line &371d 8a TXA &371e d0 f3 BNE &3713 ; fill_middle_of_line_loop ; found_right_of_line &3720 10 03 BPL &3725 ; fill_pixels_at_right_of_line &3722 a9 00 LDA #&00 # Leave with positive to indicate something was filled &3724 60 RTS ; fill_pixels_at_right_of_line &3725 0a ASL A &3726 30 0b BMI &3733 ; fill_one_pixel_at_right_of_line &3728 0a ASL A &3729 30 04 BMI &372f ; fill_two_pixels_at_right_of_line ; fill_three_pixels_at_right_of_line &372b a2 ee LDX #&ee ; 3330 &372d d0 06 BNE &3735 ; fill_right_pixels ; fill_two_pixels_at_right_of_line &372f a2 cc LDX #&cc ; 3300 &3731 d0 02 BNE &3735 ; fill_right_pixels ; fill_one_pixel_at_right_of_line &3733 a2 88 LDX #&88 ; 3000 ; fill_right_pixels &3735 84 85 STY &85 ; screen_offset &3737 20 d6 36 JSR &36d6 ; fill_part_of_byte &373a a9 00 LDA #&00 # Leave with positive to indicate something was filled &373c 60 RTS ; add_object_or_label_to_room # 001 ..... add object or label &373d c8 INY &373e b1 70 LDA (&70),Y ; room_data_address # Get byte of data for object x position &3740 18 CLC &3741 65 8c ADC &8c ; plot_x_origin &3743 85 89 STA &89 ; plot_x &3745 c8 INY &3746 b1 70 LDA (&70),Y ; room_data_address # Get byte of data for object y position &3748 85 81 STA &81 ; y &374a 98 TYA &374b 48 PHA ; room_data_offset &374c 8a TXA # X is first byte &374d 29 1f AND #&1f # ... 18421 object or label type &374f 20 d2 38 JSR &38d2 ; consider_adding_object &3752 4c 72 37 JMP &3772 ; consider_next_byte_of_room_data ; plot_room_data_from_AY &3755 85 70 STA &70 ; room_data_address_low &3757 84 71 STY &71 ; room_data_address_high ; plot_room_data_from_address &3759 a0 00 LDY #&00 &375b 84 66 STY &66 ; object_x # Set to zero to indicate no object in room &375d f0 16 BEQ &3775 ; consider_byte_of_room_data # Always branches ; add_fill_to_room # 0001 .... fill area &375f 8a TXA &3760 29 0f AND #&0f # .... 8421 fill pattern &3762 0a ASL A &3763 85 85 STA &85 ; fill_pattern &3765 a6 89 LDX &89 ; plot_x # Use last plot x for fill x &3767 c8 INY &3768 98 TYA &3769 48 PHA ; room_data_offset &376a b1 70 LDA (&70),Y ; room_data_address # Get byte of room data for fill y &376c a8 TAY &376d a5 85 LDA &85 ; fill_pattern ; to_fill_area &376f 20 7b 36 JSR &367b ; fill_area ; consider_next_byte_of_room_data &3772 68 PLA ; room_data_offset &3773 a8 TAY &3774 c8 INY ; consider_byte_of_room_data &3775 b1 70 LDA (&70),Y ; room_data_address &3777 f0 18 BEQ &3791 ; leave # Zero indicates end of data &3779 30 1d BMI &3798 ; add_string_to_room # 1....... write string &377b aa TAX &377c 0a ASL A &377d 30 22 BMI &37a1 ; add_shape_to_room # 01...... draw shape &377f 0a ASL A &3780 30 bb BMI &373d ; add_object_or_label_to_room # 001..... add object or label &3782 0a ASL A &3783 30 da BMI &375f ; add_fill_to_room # 0001.... fill area &3785 0a ASL A &3786 10 03 BPL &378b ; not_platform &3788 4c 76 38 JMP &3876 ; add_platform_to_room # 00001... draws platform ; not_platform &378b 0a ASL A &378c 30 04 BMI &3792 ; to_add_pill_to_room # 000001.. adds pill &378e 0a ASL A &378f 30 04 BMI &3795 ; to_set_room_update_routine # 0000001. sets room update routine ; leave &3791 60 RTS ; to_add_pill_to_room &3792 4c 5b 39 JMP &395b ; add_pill_to_room ; to_set_room_update_routine &3795 4c 6b 3a JMP &3a6b ; set_room_update_routine ; add_string_to_room # 1 ....... write string &3798 29 7f AND #&7f # . 4218421 length of string &379a aa TAX &379b c8 INY &379c 20 51 39 JSR &3951 ; write_string_loop # Write string of length X &379f f0 d4 BEQ &3775 ; consider_next_byte_of_room_data # Always branches ; add_shape_to_room # 01 ...... plots shape &37a1 8a TXA &37a2 29 3f AND #&3f # .. 218421 shape type &37a4 0a ASL A &37a5 aa TAX &37a6 bd 00 0a LDA &0a00,X ; shape_data_addresses &37a9 85 72 STA &72 ; shape_data_address_low &37ab bd 01 0a LDA &0a01,X ; shape_data_addresses + 1 &37ae 85 73 STA &73 ; shape_data_address_high &37b0 c8 INY &37b1 b1 70 LDA (&70),Y ; room_data_address # Get byte of data for x position &37b3 30 0f BMI &37c4 ; get_y_from_data ; use_previous_y &37b5 18 CLC &37b6 65 8c ADC &8c ; plot_x_origin &37b8 85 89 STA &89 ; plot_x &37ba a5 8a LDA &8a ; plot_y &37bc 29 01 AND #&01 &37be f0 12 BEQ &37d2 ; draw_shape_at_position &37c0 e6 8a INC &8a ; plot_y &37c2 d0 0e BNE &37d2 ; draw_shape_at_position # Always branches ; get_y_from_data &37c4 29 7f AND #&7f &37c6 18 CLC &37c7 65 8c ADC &8c ; plot_x_origin &37c9 85 89 STA &89 ; plot_x &37cb c8 INY &37cc b1 70 LDA (&70),Y ; room_data_address # Get byte of data for y position &37ce 49 ff EOR #&ff &37d0 85 8a STA &8a ; plot_y ; draw_shape_at_position &37d2 98 TYA &37d3 48 PHA ; room_data_offset &37d4 20 3c 38 JSR &383c ; move_to_absolute_position # Move to start of shape &37d7 a9 00 LDA #&00 &37d9 85 85 STA &85 ; half &37db 20 eb 37 JSR &37eb ; draw_half_of_shape &37de 20 3c 38 JSR &383c ; move_to_absolute_position &37e1 a9 80 LDA #&80 &37e3 85 85 STA &85 ; half &37e5 20 eb 37 JSR &37eb ; draw_half_of_shape &37e8 4c 72 37 JMP &3772 ; consider_next_byte_of_room_data ; draw_half_of_shape &37eb a0 00 LDY #&00 ; draw_half_of_shape_loop &37ed b1 72 LDA (&72),Y ; shape_data_address # Get a byte of shape data &37ef d0 01 BNE &37f2 ; not_end_of_shape # Zero indicates end of shape data &37f1 60 RTS ; not_end_of_shape &37f2 aa TAX &37f3 29 f0 AND #&f0 # Top nibble specifies x delta &37f5 f0 05 BEQ &37fc ; set_x_delta_low &37f7 45 85 EOR &85 ; half &37f9 30 09 BMI &3804 ; invert_x_delta &37fb 4a LSR A ; set_x_delta_low &37fc 85 86 STA &86 ; x_delta_low &37fe a9 00 LDA #&00 &3800 85 87 STA &87 ; x_delta_high &3802 f0 0e BEQ &3812 ; calculate_y_delta # Always branches ; invert_x_delta &3804 4a LSR A &3805 29 bf AND #&bf &3807 49 ff EOR #&ff &3809 18 CLC &380a 69 01 ADC #&01 &380c 85 86 STA &86 ; x_delta_low &380e a9 ff LDA #&ff &3810 85 87 STA &87 ; x_delta_high ; calculate_y_delta &3812 8a TXA &3813 29 0f AND #&0f # Bottom nibble specifies y delta &3815 0a ASL A &3816 0a ASL A &3817 85 88 STA &88 ; y_delta_low &3819 20 1f 38 JSR &381f ; draw_line &381c c8 INY &381d d0 ce BNE &37ed ; draw_half_of_shape_loop # Always branches ; draw_line &381f a9 01 LDA #&01 ; draw relative &3821 20 6c 38 JSR &386c ; start_plot_command &3824 a5 86 LDA &86 ; x_delta_low &3826 20 ee ff JSR &ffee ; OSWRCH &3829 a5 87 LDA &87 ; x_delta_high &382b 20 ee ff JSR &ffee ; OSWRCH &382e a5 88 LDA &88 ; y_delta_low &3830 20 ee ff JSR &ffee ; OSWRCH &3833 a9 00 LDA #&00 &3835 6c 0e 02 JMP (&020e) ; oswrch_vector ; draw_to_absolute_position &3838 a9 05 LDA #&05 ; draw absolute &383a d0 02 BNE &383e ; draw_or_move_to_absolute_position # Always branches ; move_to_absolute_position &383c a9 04 LDA #&04 ; move absolute ; draw_or_move_to_absolute_position &383e 20 6c 38 JSR &386c ; start_plot_command &3841 a9 00 LDA #&00 &3843 85 87 STA &87 ; x_high &3845 a5 89 LDA &89 ; plot_x &3847 0a ASL A &3848 26 87 ROL &87 ; x_high &384a 0a ASL A &384b 26 87 ROL &87 ; x_high &384d 0a ASL A &384e 26 87 ROL &87 ; x_high &3850 20 ee ff JSR &ffee ; OSWRCH &3853 a5 87 LDA &87 ; x_high &3855 20 ee ff JSR &ffee ; OSWRCH &3858 a9 00 LDA #&00 &385a 85 87 STA &87 ; y_high &385c a5 8a LDA &8a ; plot_y &385e 0a ASL A &385f 26 87 ROL &87 ; y_high &3861 0a ASL A &3862 26 87 ROL &87 ; y_high &3864 20 ee ff JSR &ffee ; OSWRCH &3867 a5 87 LDA &87 ; y_high &3869 6c 0e 02 JMP (&020e) ; oswrch_vector ; start_plot_command &386c 48 PHA ; plot type &386d a9 19 LDA #&19 ; plot &386f 20 ee ff JSR &ffee ; OSWRCH &3872 68 PLA ; plot type &3873 6c 0e 02 JMP (&020e) ; oswrch_vector ; add_platform_to_room # 00001 ... draws platform &3876 c8 INY &3877 b1 70 LDA (&70),Y ; room_data_address # Get byte of data for platform y position &3879 49 ff EOR #&ff &387b 85 8a STA &8a ; plot_y &387d 85 85 STA &85 ; platform_y &387f 8a TXA # X is initial byte &3880 29 01 AND #&01 &3882 f0 0e BEQ &3892 ; is_variable_length_platform # ..... ..0 variable length platform ; is_short_platform # ..... ..1 short platform &3884 a5 8c LDA &8c ; plot_x_origin &3886 85 89 STA &89 ; plot_x &3888 aa TAX &3889 20 3c 38 JSR &383c ; move_to_absolute_position &388c 8a TXA # X is initial byte &388d 18 CLC &388e 69 0f ADC #&0f &3890 d0 12 BNE &38a4 ; draw_platform # Always branches ; is_variable_length_platform &3892 c8 INY &3893 b1 70 LDA (&70),Y ; room_data_address # Get byte of data for platform x position &3895 18 CLC &3896 65 8c ADC &8c ; plot_x_origin &3898 85 89 STA &89 ; plot_x &389a aa TAX &389b 20 3c 38 JSR &383c ; move_to_absolute_position &389e c8 INY &389f b1 70 LDA (&70),Y ; room_data_address # Get byte of data for length &38a1 18 CLC &38a2 65 89 ADC &89 ; plot_x ; draw_platform &38a4 85 89 STA &89 ; plot_x &38a6 20 38 38 JSR &3838 ; draw_to_absolute_position # Draw top edge of platform &38a9 a5 85 LDA &85 ; platform_y &38ab 38 SEC &38ac e9 0b SBC #&0b &38ae 85 8a STA &8a ; plot_y &38b0 20 38 38 JSR &3838 ; draw_to_absolute_position # Draw right edge of platform &38b3 86 89 STX &89 ; plot_x &38b5 20 38 38 JSR &3838 ; draw_to_absolute_position # Drop bottom edge of platform &38b8 a5 85 LDA &85 ; platform_y &38ba 85 8a STA &8a ; plot_y &38bc 20 38 38 JSR &3838 ; draw_to_absolute_position # Draw left edge of platform &38bf 98 TYA &38c0 48 PHA ; room_data_offset &38c1 a5 85 LDA &85 ; platform_y &38c3 49 ff EOR #&ff &38c5 69 05 ADC #&05 &38c7 a8 TAY &38c8 8a TXA &38c9 18 CLC &38ca 69 0a ADC #&0a &38cc aa TAX &38cd a9 06 LDA #&06 ; K/W checkerboard &38cf 4c 6f 37 JMP &376f ; to_fill_area # Fill platform ; consider_adding_object &38d2 c9 18 CMP #&18 &38d4 b0 4e BCS &3924 ; plot_label &38d6 aa TAX &38d7 a4 8b LDY &8b ; player_room &38d9 b9 50 0c LDA &0c50,Y ; room_flags &38dc 29 40 AND #&40 ; ROOM_FLAG_OBJECT # Flag cleared when object collected &38de d0 01 BNE &38e1 ; room_has_object &38e0 60 RTS ; room_has_object &38e1 8a TXA &38e2 85 6a STA &6a ; object_type &38e4 0a ASL A &38e5 0a ASL A &38e6 0a ASL A &38e7 0a ASL A &38e8 8d 58 36 STA &3658 ; object_sprite_address_low &38eb a9 25 LDA #&25 ; &2500 = object_sprites &38ed 69 00 ADC #&00 &38ef 8d 59 36 STA &3659 ; object_sprite_address_high &38f2 8a TXA &38f3 4a LSR A &38f4 4a LSR A &38f5 4a LSR A &38f6 a8 TAY &38f7 b9 45 39 LDA &3945,Y ; object_heights &38fa 85 8d STA &8d ; rows_remaining &38fc 18 CLC &38fd 65 81 ADC &81 ; y &38ff e9 29 SBC #&29 &3901 85 68 STA &68 ; object_y_max &3903 a5 8d LDA &8d ; rows_remaining &3905 0a ASL A &3906 65 8d ADC &8d ; rows_remaining &3908 85 69 STA &69 ; object_buffer_y &390a b9 48 39 LDA &3948,Y ; object_widths &390d 85 8e STA &8e ; object_width &390f c9 02 CMP #&02 &3911 a5 89 LDA &89 ; plot_x &3913 aa TAX &3914 b0 02 BCS &3918 ; not_wide &3916 e9 04 SBC #&04 ; not_wide &3918 29 fc AND #&fc &391a 85 66 STA &66 ; object_x &391c a4 81 LDY &81 ; y &391e c8 INY &391f 84 67 STY &67 ; object_y_min &3921 4c 4c 36 JMP &364c ; plot_object_using_y ; plot_label &3924 8a TXA &3925 29 07 AND #&07 &3927 0a ASL A &3928 0a ASL A &3929 a8 TAY &392a b9 80 08 LDA &0880,Y ; labels_table &392d 8d 58 36 STA &3658 ; object_sprite_address_low &3930 b9 81 08 LDA &0881,Y ; labels_table + 1 &3933 8d 59 36 STA &3659 ; object_sprite_address_high &3936 b9 82 08 LDA &0882,Y ; labels_table + 2 &3939 85 8d STA &8d ; rows_remaining &393b b9 83 08 LDA &0883,Y ; labels_table + 3 &393e 85 8e STA &8e ; object_width &3940 a6 89 LDX &89 ; plot_x &3942 4c 4c 36 JMP &364c ; plot_object_using_y ; object_heights &3945 08 10 05 ; object_widths &3948 02 01 03 ; write_string &394b 85 70 STA &70 ; string_address_low &394d 84 71 STY &71 ; string_address_high &394f a0 00 LDY #&00 ; write_string_loop &3951 b1 70 LDA (&70),Y ; string_address, room_data_address &3953 20 ee ff JSR &ffee ; OSWRCH &3956 c8 INY &3957 ca DEX &3958 d0 f7 BNE &3951 ; write_string_loop &395a 60 RTS ; add_pill_to_room # 000001 .. adds pill &395b 85 85 STA &85 ; shifted_byte # ...... 21 pill type: 0 red, 2 other &395d c8 INY &395e b1 70 LDA (&70),Y ; room_data_address # Get byte for pill x position &3960 85 80 STA &80 ; x &3962 c8 INY &3963 98 TYA &3964 48 PHA ; room_data_offset &3965 b1 70 LDA (&70),Y ; room_data_address # Get byte for pill y position &3967 a8 TAY &3968 a9 1f LDA #&1f &396a 8d 59 36 STA &3659 ; object_sprite_address_high &396d a6 8b LDX &8b ; player_room &396f bd 50 0c LDA &0c50,X ; room_flags &3972 24 85 BIT &85 ; shifted_byte # Original byte has been shifted .....421 -> 421..... &3974 50 19 BVC &398f ; not_other_pill # V is clear if pill type is zero, i.e. red pill &3976 29 10 AND #&10 ; ROOM_FLAG_OTHER_PILL &3978 f0 12 BEQ &398c ; not_other_pill &397a a9 d0 LDA #&d0 ; &1fd0 = other_pill_sprite ; set_object_sprite_address_low &397c 8d 58 36 STA &3658 ; object_sprite_address_low &397f a9 09 LDA #&09 &3981 85 8d STA &8d ; rows_remaining &3983 a9 02 LDA #&02 &3985 85 8e STA &8e ; object_width &3987 a6 80 LDX &80 ; x &3989 20 4a 36 JSR &364a ; plot_object # Plot pill ; to_consider_next_byte_of_room_data &398c 4c 72 37 JMP &3772 ; consider_next_byte_of_room_data ; not_other_pill &398f 29 20 AND #&20 ; ROOM_FLAG_RED_PILL &3991 f0 f9 BEQ &398c ; to_consider_next_byte_of_room_data &3993 a9 50 LDA #&50 ; &1f50 = red_pill_sprite &3995 d0 e5 BNE &397c ; set_object_sprite_address_low # Always branches ; plot_room &3997 a9 1a LDA #&1a ; restore default windows &3999 20 ee ff JSR &ffee ; OSWRCH &399c 20 e9 40 JSR &40e9 ; clear_screen &399f a9 00 LDA #&00 &39a1 85 8c STA &8c ; plot_x_origin &39a3 a6 8b LDX &8b ; player_room &39a5 20 1f 42 JSR &421f ; plot_room_edge # Plot left edge of room (&00 - &27) &39a8 a9 90 LDA #&90 &39aa 85 8c STA &8c ; plot_x_origin &39ac a6 8b LDX &8b ; player_room &39ae 8a TXA &39af 29 07 AND #&07 &39b1 c9 07 CMP #&07 &39b3 d0 08 BNE &39bd ; not_rightmost_room &39b5 8a TXA &39b6 4a LSR A &39b7 4a LSR A &39b8 4a LSR A &39b9 18 CLC &39ba 69 28 ADC #&28 &39bc aa TAX ; not_rightmost_room &39bd e8 INX &39be 20 1f 42 JSR &421f ; plot_room_edge # Plot right edge of room (&01 - &27 or &29 - &2d) &39c1 a5 8b LDA &8b ; player_room &39c3 0a ASL A &39c4 aa TAX &39c5 a9 0f LDA #&0f &39c7 85 8c STA &8c ; plot_x_origin &39c9 bd 80 0a LDA &0a80,X ; room_data_addresses &39cc bc 81 0a LDY &0a81,X ; room_data_addresses + 1 &39cf 4c 55 37 JMP &3755 ; plot_room_data_from_AY # Plot middle of room ; initialise_room &39d2 a9 a6 LDA #&a6 ; &08a6 = game_screen_initialisation_string &39d4 a0 08 LDY #&08 &39d6 a2 18 LDX #&18 &39d8 20 4b 39 JSR &394b ; write_string ; initialise_room_without_changing_mode &39db a5 8b LDA &8b ; player_room &39dd 4a LSR A &39de 4a LSR A &39df 4a LSR A &39e0 18 CLC &39e1 69 02 ADC #&02 &39e3 8d a2 08 STA &08a2 ; game_colour_string + 2 &39e6 a9 a0 LDA #&a0 ; &08a0 &39e8 a0 08 LDY #&08 &39ea a2 06 LDX #&06 &39ec 20 4b 39 JSR &394b ; write_string &39ef 4c 97 39 JMP &3997 ; plot_room ; check_for_collecting_pill &39f2 a2 5d LDX #&5d ; check_for_collecting_pill_row_loop &39f4 bd 3c 01 LDA &013c,X ; player_buffer + &1c &39f7 c9 33 CMP #&33 ; 0033 &39f9 f0 06 BEQ &3a01 ; check_for_pill_in_row ; consider_next_row &39fb ca DEX &39fc ca DEX &39fd ca DEX &39fe d0 f4 BNE &39f4 ; check_for_collecting_pill_row_loop &3a00 60 RTS ; check_for_pill_in_row &3a01 bd 3d 01 LDA &013d,X ; player_buffer + &1d &3a04 d0 f5 BNE &39fb ; consider_next_row &3a06 bd 24 01 LDA &0124,X ; player_buffer + &04 &3a09 c9 33 CMP #&33 ; 0033 &3a0b d0 ee BNE &39fb ; consider_next_row &3a0d bd 25 01 LDA &0125,X ; player_buffer + &05 &3a10 d0 e9 BNE &39fb ; consider_next_row &3a12 8a TXA &3a13 48 PHA ; buffer offset &3a14 bd 27 01 LDA &0127,X ; player_buffer + &07 &3a17 c9 50 CMP #&50 ; 0202 &3a19 90 06 BCC &3a21 ; is_red_pill &3a1b a9 10 LDA #&10 ; ROOM_FLAG_OTHER_PILL &3a1d a0 ff LDY #&ff # Negative to indicate other pill &3a1f d0 04 BNE &3a25 ; collect_and_remove_pill ; is_red_pill &3a21 a9 20 LDA #&20 ; ROOM_FLAG_RED_PILL &3a23 a0 00 LDY #&00 # Positive to indicate red pill ; collect_and_remove_pill &3a25 20 50 44 JSR &4450 ; collect_pill &3a28 68 PLA ; buffer offset &3a29 18 CLC &3a2a 69 18 ADC #&18 &3a2c aa TAX &3a2d a9 00 LDA #&00 &3a2f a0 09 LDY #&09 ; remove_pill_from_player_buffer_loop &3a31 9d 24 01 STA &0124,X ; player_buffer + &04 &3a34 9d 25 01 STA &0125,X ; player_buffer + &05 &3a37 ca DEX &3a38 ca DEX &3a39 ca DEX &3a3a 88 DEY &3a3b d0 f4 BNE &3a31 ; remove_pill_from_player_buffer_loop &3a3d 60 RTS ; use_room_specific_update_routine # 0000001 0 uses room specific update routine &3a3e a9 ff LDA #&ff &3a40 85 65 STA &65 ; replot_update # Set to negative to indicate room being replotted &3a42 a5 64 LDA &64 ; room_initialised # Zero if room is being initialised &3a44 d0 19 BNE &3a5f ; skip_initialising_room &3a46 c8 INY &3a47 b1 70 LDA (&70),Y ; room_data_address # Get two bytes of data for update routine address &3a49 85 74 STA &74 ; update_room_address_low &3a4b c8 INY &3a4c b1 70 LDA (&70),Y ; room_data_address &3a4e 85 75 STA &75 ; update_room_address_high &3a50 c8 INY &3a51 b1 70 LDA (&70),Y ; room_data_address # Get byte of data for number of room variables &3a53 aa TAX ; set_room_variables_loop &3a54 c8 INY &3a55 b1 70 LDA (&70),Y ; room_data_address # Get byte of data for each room variable &3a57 95 52 STA &52,X ; room_variables # Room variables are stored in reverse order &3a59 ca DEX &3a5a 10 f8 BPL &3a54 ; set_room_variables_loop ; to_update_room &3a5c 6c 74 00 JMP (&0074) ; update_room_address ; skip_initialising_room &3a5f c8 INY # Skip two bytes of data for update routine address &3a60 c8 INY &3a61 c8 INY &3a62 b1 70 LDA (&70),Y ; room_data_address # Get byte of data for number of room variables &3a64 aa TAX ; skip_room_variables_loop &3a65 c8 INY # Skip byte of data for each room variable &3a66 ca DEX &3a67 10 fc BPL &3a65 ; skip_room_variables_loop &3a69 30 f1 BMI &3a5c ; to_update_room # Always branches ; set_room_update_routine &3a6b 8a TXA # X is initial byte &3a6c 29 01 AND #&01 &3a6e f0 ce BEQ &3a3e ; use_room_specific_update_routine ; use_common_update_routine &3a70 a9 3a LDA #&3a ; &303a = finished_updating_room # 0000001 1 uses common update routine &3a72 85 74 STA &74 ; update_room_address_low &3a74 a9 30 LDA #&30 &3a76 85 75 STA &75 ; update_room_address_high &3a78 a9 00 LDA #&00 &3a7a 85 65 STA &65 ; replot_update # Set to positive to indicate room not being replotted ; leave &3a7c 60 RTS ; is_standing_or_climbing &3a7d f0 fd BEQ &3a7c ; leave # Leave if player is standing &3a7f c9 29 CMP #&29 ; PLAYER_SPRITE_CLIMBING &3a81 b0 4a BCS &3acd ; is_climbing ; is_falling &3a83 ad fa 0e LDA &0efa ; sound_0ef6 + 4 (pitch) &3a86 f0 f4 BEQ &3a7c ; leave &3a88 e9 02 SBC #&02 &3a8a 8d fa 0e STA &0efa ; sound_0ef6 + 4 (pitch) &3a8d a0 0e LDY #&0e ; &0ef6 = sound_0ef6 &3a8f 20 c6 3a JSR &3ac6 ; play_sound # Play variable sound for falling &3a92 a0 17 LDY #&17 ; &17f6 = sound_17f6 &3a94 4c c6 3a JMP &3ac6 ; play_sound # Play fixed sound for falling ; replot_player_standing &3a97 a9 1d LDA #&1d ; PLAYER_SPRITE_STANDING &3a99 85 94 STA &94 ; player_sprite &3a9b d0 03 BNE &3aa0 ; replot_player_without_unplotting # Always branches ; replot_player &3a9d 20 41 3c JSR &3c41 ; unplot_player ; replot_player_without_unplotting &3aa0 20 17 3b JSR &3b17 ; plot_player &3aa3 a9 0a LDA #&0a &3aa5 85 44 STA &44 ; player_idle_cooldown &3aa7 a5 94 LDA &94 ; player_sprite &3aa9 c9 1d CMP #&1d ; PLAYER_SPRITE_STANDING &3aab b0 d0 BCS &3a7d ; is_standing_or_climbing ; is_walking &3aad a5 4e LDA &4e ; jump_or_fall_timer &3aaf d0 cb BNE &3a7c ; leave &3ab1 a5 90 LDA &90 ; player_x &3ab3 aa TAX &3ab4 45 97 EOR &97 ; player_x_for_sound &3ab6 c9 04 CMP #&04 &3ab8 90 c2 BCC &3a7c ; leave &3aba 86 97 STX &97 ; player_x_for_sound &3abc ad fa 0d LDA &0dfa ; sound_0df6 + 4 (pitch) &3abf 49 04 EOR #&04 &3ac1 8d fa 0d STA &0dfa ; sound_0df6 + 4 (pitch) &3ac4 a0 0d LDY #&0d ; &0df6 = sound_0df6 # Play sound for walking ; play_sound &3ac6 a2 f6 LDX #&f6 ; play_sound_from_XY &3ac8 a9 07 LDA #&07 ; Generate a sound &3aca 6c 0c 02 JMP (&020c) ; osword_vector ; is_climbing &3acd a5 4e LDA &4e ; jump_or_fall_timer &3acf c9 ff CMP #&ff &3ad1 d0 a9 BNE &3a7c ; leave &3ad3 a5 91 LDA &91 ; player_y &3ad5 49 ff EOR #&ff &3ad7 8d fa 0f STA &0ffa ; sound_0ff6 + 4 (pitch) &3ada a0 0f LDY #&0f ; sound_0ff6 &3adc 4c c6 3a JMP &3ac6 ; play_sound # Play sound for climbing ; consider_replotting_player &3adf a5 9d LDA &9d ; player_clipping # Non-zero if player is clipped at top or bottom &3ae1 05 9e ORA &9e ; player_needs_full_replot # Non-zero if player needs full replot &3ae3 d0 b8 BNE &3a9d ; replot_player &3ae5 a5 9c LDA &9c ; previous_player_sprite_height &3ae7 c9 29 CMP #&29 &3ae9 d0 b2 BNE &3a9d ; replot_player &3aeb a5 91 LDA &91 ; player_y &3aed 45 93 EOR &93 ; previous_player_y &3aef d0 ac BNE &3a9d ; replot_player &3af1 a5 90 LDA &90 ; player_x &3af3 45 92 EOR &92 ; previous_player_x &3af5 f0 07 BEQ &3afe ; check_if_player_is_idle &3af7 c9 04 CMP #&04 &3af9 b0 a2 BCS &3a9d ; replot_player ; to_plot_player_using_buffer &3afb 4c ca 3b JMP &3bca ; plot_player_using_buffer ; check_if_player_is_idle &3afe a5 00 LDA &00 ; direction_velocities # Zero if at left edge of game, &ff otherwise &3b00 25 01 AND &01 ; direction_velocities + 1 # Zero if at right edge of game, &01 otherwise &3b02 d0 04 BNE &3b08 ; not_at_edge # Branches if player not at horizontal edge of game &3b04 a5 ec LDA &ec ; os_most_recently_pressed_key &3b06 d0 08 BNE &3b10 ; not_idle ; not_at_edge &3b08 c6 44 DEC &44 ; player_idle_cooldown &3b0a d0 ef BNE &3afb ; to_plot_player_using_buffer &3b0c a9 1d LDA #&1d ; PLAYER_SPRITE_STANDING &3b0e 85 94 STA &94 ; player_sprite ; not_idle &3b10 a9 0a LDA #&0a &3b12 85 44 STA &44 ; player_idle_cooldown &3b14 4c ca 3b JMP &3bca ; plot_player_using_buffer ; plot_player &3b17 a5 9e LDA &9e ; player_needs_full_replot # Zero if using buffer &3b19 f0 1d BEQ &3b38 ; skip_clipping_at_top &3b1b a5 91 LDA &91 ; player_y &3b1d 48 PHA ; unclipped_player_y &3b1e 10 18 BPL &3b38 ; skip_clipping_at_top &3b20 a9 00 LDA #&00 &3b22 38 SEC &3b23 e5 91 SBC &91 ; player_y &3b25 85 91 STA &91 ; player_y &3b27 0a ASL A &3b28 18 CLC &3b29 65 91 ADC &91 ; player_y &3b2b 85 9a STA &9a ; player_buffer_offset &3b2d a9 29 LDA #&29 &3b2f 38 SEC &3b30 e5 91 SBC &91 ; player_y &3b32 85 98 STA &98 ; player_sprite_height &3b34 a9 00 LDA #&00 &3b36 85 91 STA &91 ; player_y ; skip_clipping_at_top &3b38 a6 90 LDX &90 ; player_x &3b3a 86 92 STX &92 ; previous_player_x &3b3c a4 91 LDY &91 ; player_y &3b3e 84 93 STY &93 ; previous_player_y &3b40 a5 94 LDA &94 ; player_sprite &3b42 c9 1d CMP #&1d ; PLAYER_SPRITE_STANDING &3b44 b0 07 BCS &3b4d ; set_sprite_and_mask_addresses &3b46 85 84 STA &84 ; sprite_base_high &3b48 8a TXA &3b49 29 07 AND #&07 &3b4b 65 84 ADC &84 ; sprite_base_high ; set_sprite_and_mask_addresses &3b4d 8d 78 3b STA &3b78 ; player_sprite_address_one_high &3b50 8d 88 3b STA &3b88 ; player_sprite_address_two_high &3b53 8d 98 3b STA &3b98 ; player_sprite_address_three_high &3b56 8d 75 3b STA &3b75 ; player_mask_address_one_high &3b59 8d 85 3b STA &3b85 ; player_mask_address_two_high &3b5c 8d 95 3b STA &3b95 ; player_mask_address_three_high &3b5f a5 98 LDA &98 ; player_sprite_height &3b61 85 9c STA &9c ; previous_player_sprite_height &3b63 85 8d STA &8d ; rows_remaining &3b65 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &3b68 a6 9a LDX &9a ; player_buffer_offset &3b6a 86 9b STX &9b ; previous_player_buffer_offset ; plot_player_row_loop &3b6c a0 00 LDY #&00 &3b6e b1 78 LDA (&78),Y ; screen_address &3b70 9d 20 01 STA &0120,X ; player_buffer &3b73 3d 7b 10 AND &107b,X # actually AND player_mask_address_one,X &3b76 1d 00 10 ORA &1000,X # actually ORA player_sprite_address_one,X &3b79 91 78 STA (&78),Y ; screen_address &3b7b e8 INX &3b7c a0 08 LDY #&08 &3b7e b1 78 LDA (&78),Y ; screen_address &3b80 9d 20 01 STA &0120,X ; player_buffer &3b83 3d 7b 10 AND &107b,X # actually AND player_mask_address_two,X &3b86 1d 00 10 ORA &1000,X # actually ORA player_sprite_address_two,X &3b89 91 78 STA (&78),Y ; screen_address &3b8b e8 INX &3b8c a0 10 LDY #&10 &3b8e b1 78 LDA (&78),Y ; screen_address &3b90 9d 20 01 STA &0120,X ; player_buffer &3b93 3d 7b 10 AND &107b,X # actually AND player_mask_address_three,X &3b96 1d 00 10 ORA &1000,X # actually ORA player_sprite_address_three,X &3b99 91 78 STA (&78),Y ; screen_address &3b9b e8 INX &3b9c c6 8d DEC &8d ; rows_remaining &3b9e f0 18 BEQ &3bb8 ; finished_plotting_player &3ba0 e6 78 INC &78 ; screen_address_low &3ba2 a5 78 LDA &78 ; screen_address_low &3ba4 29 07 AND #&07 &3ba6 d0 c4 BNE &3b6c ; plot_player_row_loop &3ba8 c6 78 DEC &78 ; screen_address_low &3baa a5 78 LDA &78 ; screen_address_low &3bac 69 39 ADC #&39 &3bae 85 78 STA &78 ; screen_address_low &3bb0 a5 79 LDA &79 ; screen_address_high &3bb2 69 01 ADC #&01 &3bb4 85 79 STA &79 ; screen_address_high &3bb6 90 b4 BCC &3b6c ; plot_player_column_loop # Always branches ; finished_plotting_player &3bb8 a5 9e LDA &9e ; player_needs_full_replot # Zero if using buffer &3bba f0 0d BEQ &3bc9 ; leave &3bbc 68 PLA ; unclipped_player_y &3bbd 85 91 STA &91 ; player_y &3bbf a9 00 LDA #&00 &3bc1 85 9e STA &9e ; player_needs_full_replot # Set to zero to indicate player does not need full replot &3bc3 85 9a STA &9a ; player_buffer_offset &3bc5 a9 29 LDA #&29 &3bc7 85 98 STA &98 ; player_sprite_height ; leave &3bc9 60 RTS ; plot_player_using_buffer &3bca 20 d2 43 JSR &43d2 ; wait_for_vsync &3bcd a6 90 LDX &90 ; player_x &3bcf 86 92 STX &92 ; previous_player_x &3bd1 a4 91 LDY &91 ; player_y &3bd3 a5 94 LDA &94 ; player_sprite &3bd5 c9 1d CMP #&1d ; PLAYER_SPRITE_STANDING &3bd7 b0 07 BCS &3be0 ; set_sprite_and_mask_addresses &3bd9 85 84 STA &84 ; sprite_base_high &3bdb 8a TXA &3bdc 29 07 AND #&07 &3bde 65 84 ADC &84 ; sprite_base_high ; set_sprite_and_mask_addresses &3be0 8d 05 3c STA &3c05 ; player_sprite_address_one_high &3be3 8d 13 3c STA &3c13 ; player_sprite_address_one_high &3be6 8d 21 3c STA &3c21 ; player_sprite_address_one_high &3be9 8d 02 3c STA &3c02 ; player_mask_address_one_high &3bec 8d 10 3c STA &3c10 ; player_mask_address_one_high &3bef 8d 1e 3c STA &3c1e ; player_mask_address_one_high &3bf2 a5 98 LDA &98 ; player_sprite_height &3bf4 85 8d STA &8d ; rows_remaining &3bf6 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &3bf9 a2 00 LDX #&00 ; plot_player_using_buffer_row_loop &3bfb a0 00 LDY #&00 &3bfd bd 20 01 LDA &0120,X ; player_buffer &3c00 3d 7b 10 AND &107b,X # actually AND player_mask_address_one,X &3c03 1d 00 10 ORA &1000,X # actually ORA player_sprite_address_one,X &3c06 91 78 STA (&78),Y ; screen_address &3c08 e8 INX &3c09 a0 08 LDY #&08 &3c0b bd 20 01 LDA &0120,X ; player_buffer &3c0e 3d 7b 10 AND &107b,X # actually AND player_mask_address_two,X &3c11 1d 00 10 ORA &1000,X # actually ORA player_sprite_address_two,X &3c14 91 78 STA (&78),Y ; screen_address &3c16 e8 INX &3c17 a0 10 LDY #&10 &3c19 bd 20 01 LDA &0120,X ; player_buffer &3c1c 3d 7b 10 AND &107b,X # actually AND player_mask_address_three,X &3c1f 1d 00 10 ORA &1000,X # actually ORA player_sprite_address_three,X &3c22 91 78 STA (&78),Y ; screen_address &3c24 e8 INX &3c25 c6 8d DEC &8d ; rows_remaining &3c27 f0 a0 BEQ &3bc9 ; leave &3c29 e6 78 INC &78 ; screen_address_low &3c2b a5 78 LDA &78 ; screen_address_low &3c2d 29 07 AND #&07 &3c2f d0 ca BNE &3bfb ; plot_player_using_buffer_row_loop &3c31 c6 78 DEC &78 ; screen_address_low &3c33 a5 78 LDA &78 ; screen_address_low &3c35 69 39 ADC #&39 &3c37 85 78 STA &78 ; screen_address_low &3c39 a5 79 LDA &79 ; screen_address_high &3c3b 69 01 ADC #&01 &3c3d 85 79 STA &79 ; screen_address_high &3c3f 90 ba BCC &3bfb ; plot_player_using_buffer_row_loop # Always branches ; unplot_player &3c41 20 d2 43 JSR &43d2 ; wait_for_vsync &3c44 a5 9c LDA &9c ; previous_player_sprite_height &3c46 85 8d STA &8d ; rows_remaining &3c48 a4 93 LDY &93 ; previous_player_y &3c4a c0 38 CPY #&38 &3c4c b0 0e BCS &3c5c ; skip_unplotting_delay &3c4e a2 02 LDX #&02 ; delay_unplotting_loop &3c50 06 78 ASL &78 ; screen_address_low # &78 is recalculated at &3c97; this loop merely &3c52 06 78 ASL &78 ; screen_address_low # delays unplotting until after the raster beam &3c54 ce bf 09 DEC &09bf ; delay_count &3c57 d0 f7 BNE &3c50 ; delay_unplotting_loop &3c59 ca DEX &3c5a 10 f4 BPL &3c50 ; delay_unplotting_loop ; skip_unplotting_delay &3c5c a6 92 LDX &92 ; previous_player_x &3c5e 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &3c61 a6 9b LDX &9b ; previous_player_buffer_offset ; unplot_player_row_loop &3c63 a0 00 LDY #&00 &3c65 bd 20 01 LDA &0120,X ; player_buffer &3c68 91 78 STA (&78),Y ; screen_address &3c6a a0 08 LDY #&08 &3c6c bd 21 01 LDA &0121,X ; player_buffer + 1 &3c6f 91 78 STA (&78),Y ; screen_address &3c71 a0 10 LDY #&10 &3c73 bd 22 01 LDA &0122,X ; player_buffer + 2 &3c76 91 78 STA (&78),Y ; screen_address &3c78 c6 8d DEC &8d ; rows_remaining &3c7a f0 41 BEQ &3cbd ; leave &3c7c e8 INX &3c7d e8 INX &3c7e e8 INX &3c7f e6 78 INC &78 ; screen_address_low &3c81 a5 78 LDA &78 ; screen_address_low &3c83 29 07 AND #&07 &3c85 d0 dc BNE &3c63 ; unplot_player_row_loop &3c87 c6 78 DEC &78 ; screen_address_low &3c89 a5 78 LDA &78 ; screen_address_low &3c8b 69 39 ADC #&39 &3c8d 85 78 STA &78 ; screen_address_low &3c8f a5 79 LDA &79 ; screen_address_high &3c91 69 01 ADC #&01 &3c93 85 79 STA &79 ; screen_address_high &3c95 d0 cc BNE &3c63 ; unplot_player_row_loop # Always branches ; calculate_screen_address_from_X_Y &3c97 84 81 STY &81 ; y ; calculate_screen_address_from_X_and_y &3c99 8a TXA &3c9a 29 fc AND #&fc &3c9c 0a ASL A &3c9d 85 76 STA &76 ; screen_offset_low &3c9f a9 2c LDA #&2c &3ca1 2a ROL A &3ca2 85 77 STA &77 ; screen_offset_high ; recalculate_screen_address_using_y &3ca4 a5 81 LDA &81 ; y &3ca6 29 f8 AND #&f8 &3ca8 4a LSR A &3ca9 4a LSR A &3caa a8 TAY &3cab a5 81 LDA &81 ; y &3cad 29 07 AND #&07 &3caf 19 80 0b ORA &0b80,Y ; group_offsets &3cb2 65 76 ADC &76 ; offset_low &3cb4 85 78 STA &78 ; screen_address_low &3cb6 b9 81 0b LDA &0b81,Y ; group_offsets + 1 &3cb9 65 77 ADC &77 ; offset_high &3cbb 85 79 STA &79 ; screen_address_high ; leave &3cbd 60 RTS ; reduce_clipping_at_top_of_player_sprite &3cbe a9 ff LDA #&ff &3cc0 85 91 STA &91 ; player_y &3cc2 e6 98 INC &98 ; player_sprite_height # Add two rows to player sprite &3cc4 e6 98 INC &98 ; player_sprite_height &3cc6 a5 9a LDA &9a ; player_buffer_offset &3cc8 38 SEC &3cc9 e9 06 SBC #&06 # Reduce clipping of player sprite at top &3ccb 85 9a STA &9a ; player_buffer_offset &3ccd c6 9d DEC &9d ; player_clipping # Positive non-zero if player sprite is still clipped at top &3ccf a5 90 LDA &90 ; player_x &3cd1 c9 03 CMP #&03 # Keep player from changing rooms horizontally too &3cd3 b0 05 BCS &3cda ; check_right_edge &3cd5 e6 90 INC &90 ; player_x ; to_apply_player_velocities &3cd7 4c 89 3d JMP &3d89 ; apply_player_velocities ; check_right_edge &3cda c9 93 CMP #&93 &3cdc 90 f9 BCC &3cd7 ; to_apply_player_velocities &3cde c6 90 DEC &90 ; player_x # Keep player from changing rooms horizontally too &3ce0 d0 f5 BNE &3cd7 ; to_apply_player_velocities # Always branches ; reduce_clipping_at_bottom_of_player_sprite &3ce2 e6 9d INC &9d ; player_clipping # Negative if player sprite is still clipped at bottom &3ce4 f0 04 BEQ &3cea ; to_continue_climbing_up &3ce6 e6 98 INC &98 ; player_sprite_height # Add two rows to bottom of player sprite &3ce8 e6 98 INC &98 ; player_sprite_height ; to_continue_climbing_up &3cea 4c 39 3e JMP &3e39 ; continue_climbing_up ; move_down_a_room &3ced a9 78 LDA #&78 ; &28 * 3 # Player sprite is clipped at top &3cef 85 9a STA &9a ; player_buffer_offset &3cf1 a9 f8 LDA #&f8 # Move down a room &3cf3 a2 14 LDX #&14 # Positive to indicate player sprite is clipped at top &3cf5 a0 01 LDY #&01 # Player starts at top of room &3cf7 84 98 STY &98 ; player_sprite_height &3cf9 d0 0a BNE &3d05 ; move_up_or_down_a_room # Always branches ; move_up_a_room &3cfb a9 09 LDA #&09 &3cfd 85 98 STA &98 ; player_sprite_height &3cff a9 08 LDA #&08 # Move up a room &3d01 a2 ef LDX #&ef # Negative to indicate player sprite is clipped at bottom &3d03 a0 f7 LDY #&f7 # Player starts at bottom of room ; move_up_or_down_a_room &3d05 86 9d STX &9d ; player_clipping ; add_to_player_room &3d07 18 CLC &3d08 65 8b ADC &8b ; player_room &3d0a 85 8b STA &8b ; player_room &3d0c 84 91 STY &91 ; player_y &3d0e 20 db 39 JSR &39db ; initialise_room_without_changing_mode &3d11 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting &3d14 4c 5d 3e JMP &3e5d ; finish_updating_player ; at_left_edge_of_room &3d17 c9 00 CMP #&00 # Is the player in the leftmost room? &3d19 d0 06 BNE &3d21 ; move_left_a_room &3d1b 85 00 STA &00 ; direction_velocities # Set to zero to stop player moving left &3d1d 85 95 STA &95 ; player_x_velocity &3d1f f0 3b BEQ &3d5c ; consider_moving_up_or_down_a_room # Always branches ; move_left_a_room &3d21 c6 8b DEC &8b ; player_room # If not, move left a room &3d23 a9 93 LDA #&93 &3d25 d0 0e BNE &3d35 ; set_player_x # Always branches ; at_right_edge_of_room &3d27 49 07 EOR #&07 &3d29 d0 06 BNE &3d31 ; move_right_a_room # Is the player in the rightmost room? &3d2b 85 01 STA &01 ; direction_velocities + 1 # Set to zero to stop player moving right &3d2d 85 95 STA &95 ; player_x_velocity &3d2f f0 2b BEQ &3d5c ; consider_moving_up_or_down_a_room # Always branches ; move_right_a_room &3d31 e6 8b INC &8b ; player_room # If not, move right a room &3d33 a9 02 LDA #&02 ; set_player_x &3d35 85 90 STA &90 ; player_x &3d37 20 97 39 JSR &3997 ; plot_room &3d3a 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting ; update_player &3d3d a5 9d LDA &9d ; player_clipping # Zero if player is not climbing or falling into room &3d3f f0 05 BEQ &3d46 ; skip_reducing_clipping &3d41 30 9f BMI &3ce2 ; reduce_clipping_at_bottom_of_player_sprite &3d43 4c be 3c JMP &3cbe ; reduce_clipping_at_top_of_player_sprite ; skip_reducing_clipping &3d46 a5 8b LDA &8b ; player_room &3d48 29 07 AND #&07 &3d4a a6 90 LDX &90 ; player_x &3d4c e0 02 CPX #&02 &3d4e 90 c7 BCC &3d17 ; at_left_edge_of_room &3d50 a0 ff LDY #&ff &3d52 84 00 STY &00 ; direction_velocities # Set to &ff to allow player to move left &3d54 e0 94 CPX #&94 &3d56 b0 cf BCS &3d27 ; at_right_edge_of_room &3d58 a0 01 LDY #&01 &3d5a 84 01 STY &01 ; direction_velocities + 1 # Set to &00 to allow player to move right ; consider_moving_up_or_down_a_room &3d5c a5 91 LDA &91 ; player_y &3d5e c9 d9 CMP #&d9 &3d60 90 0c BCC &3d6e ; not_changing_room &3d62 c9 db CMP #&db &3d64 90 87 BCC &3ced ; move_down_a_room &3d66 a5 94 LDA &94 ; player_sprite &3d68 c9 29 CMP #&29 ; PLAYER_SPRITE_CLIMBING &3d6a b0 8f BCS &3cfb ; move_up_a_room &3d6c 85 9e STA &9e ; player_needs_full_replot # Set to non-zero to indicate player needs full replot ; not_changing_room &3d6e a5 39 LDA &39 ; freefall_velocity &3d70 f0 03 BEQ &3d75 ; not_falling &3d72 4c 69 42 JMP &4269 ; update_freefalling_player ; not_falling &3d75 a5 4e LDA &4e ; jump_or_fall_timer &3d77 f0 40 BEQ &3db9 ; check_player_input &3d79 a5 ec LDA &ec ; os_most_recently_pressed_key &3d7b c5 22 CMP &22 ; key_up &3d7d d0 03 BNE &3d82 ; not_climbing_up &3d7f 4c 39 3e JMP &3e39 ; continue_climbing_up ; not_climbing_up &3d82 c5 23 CMP &23 ; key_down &3d84 d0 03 BNE &3d89 ; apply_player_velocities &3d86 4c 2d 3e JMP &3e2d ; continue_climbing_down ; apply_player_velocities &3d89 a5 4e LDA &4e ; jump_or_fall_timer &3d8b c9 d2 CMP #&d2 ; FREEFALL_START &3d8d d0 03 BNE &3d92 ; skip_starting_freefall &3d8f 20 2c 42 JSR &422c ; start_player_freefalling ; skip_starting_freefall &3d92 c6 4e DEC &4e ; jump_or_fall_timer &3d94 d0 06 BNE &3d9c ; not_top_of_jump &3d96 a9 02 LDA #&02 &3d98 85 96 STA &96 ; player_y_velocity # Set player falling &3d9a c6 4e DEC &4e ; jump_or_fall_timer ; not_top_of_jump &3d9c a5 96 LDA &96 ; player_y_velocity &3d9e 18 CLC &3d9f 65 91 ADC &91 ; player_y &3da1 85 91 STA &91 ; player_y &3da3 c9 ff CMP #&ff &3da5 d0 02 BNE &3da9 ; not_starting_to_clip_top &3da7 85 9e STA &9e ; player_needs_full_replot # Set to non-zero to indicate player needs full replot ; not_starting_to_clip_top &3da9 a5 95 LDA &95 ; player_x_velocity &3dab 18 CLC &3dac 65 90 ADC &90 ; player_x &3dae 85 90 STA &90 ; player_x &3db0 a5 4e LDA &4e ; jump_or_fall_timer &3db2 c9 0c CMP #&0c # Is the player falling? If so, check for floor &3db4 b0 38 BCS &3dee ; to_finish_updating_player_after_floor_check &3db6 4c 5d 3e JMP &3e5d ; finish_updating_player ; check_player_input &3db9 a2 00 LDX #&00 &3dbb 86 95 STX &95 ; player_x_velocity &3dbd a5 ed LDA &ed ; os_first_pressed_key &3dbf c5 22 CMP &22 ; key_up &3dc1 f0 07 BEQ &3dca ; consider_jumping &3dc3 e8 INX &3dc4 a5 ec LDA &ec ; os_most_recently_pressed_key &3dc6 c5 22 CMP &22 ; key_up &3dc8 d0 0e BNE &3dd8 ; up_not_pressed ; consider_jumping &3dca b5 ec LDA &ec,X ; os_most_recently_pressed_key &3dcc f0 36 BEQ &3e04 ; start_player_jumping_up &3dce a2 00 LDX #&00 &3dd0 c5 20 CMP &20 ; key_left &3dd2 f0 38 BEQ &3e0c ; start_player_jumping_left &3dd4 c5 21 CMP &21 ; key_right &3dd6 f0 30 BEQ &3e08 ; start_player_jumping_right ; up_not_pressed &3dd8 a5 ec LDA &ec ; os_most_recently_pressed_key &3dda d0 04 BNE &3de0 ; consider_key &3ddc a5 ed LDA &ed ; os_first_pressed_key &3dde f0 0e BEQ &3dee ; to_finish_updating_player_after_floor_check ; consider_key &3de0 a2 00 LDX #&00 &3de2 c5 20 CMP &20 ; key_left &3de4 f0 0f BEQ &3df5 ; start_player_walking_left &3de6 c5 21 CMP &21 ; key_right &3de8 f0 07 BEQ &3df1 ; start_player_walking_right &3dea c5 23 CMP &23 ; key_down &3dec f0 36 BEQ &3e24 ; start_player_climbing_down ; to_finish_updating_player_after_floor_check &3dee 4c 58 3e JMP &3e58 ; finish_updating_player_after_floor_check ; start_player_walking_right &3df1 e8 INX &3df2 a0 0d LDY #&0d ; PLAYER_SPRITE_RIGHT &3df4 2c a0 15 BIT &15a0 ; start_player_walking_left #3df5 LDY #&15 ; PLAYER_SPRITE_LEFT &3df7 84 94 STY &94 ; player_sprite &3df9 b5 00 LDA &00,X ; direction_velocities &3dfb 85 95 STA &95 ; player_x_velocity &3dfd 18 CLC &3dfe 65 90 ADC &90 ; player_x &3e00 85 90 STA &90 ; player_x &3e02 d0 54 BNE &3e58 ; finish_updating_player_after_floor_check # Always branches ; start_player_jumping_up &3e04 a0 1d LDY #&1d ; PLAYER_SPRITE_STANDING &3e06 d0 0a BNE &3e12 ; start_player_jumping # Always branches ; start_player_jumping_right &3e08 a0 0d LDY #&0d ; PLAYER_SPRITE_RIGHT &3e0a e8 INX &3e0b 2c a0 15 BIT &15a0 ; start_player_jumping_left #3e0c LDY #&15 ; PLAYER_SPRITE_LEFT &3e0e b5 00 LDA &00,X ; direction_velocities &3e10 85 95 STA &95 ; player_x_velocity ; start_player_jumping &3e12 84 94 STY &94 ; player_sprite &3e14 a9 0a LDA #&0a &3e16 85 4e STA &4e ; jump_or_fall_timer &3e18 a9 fe LDA #&fe &3e1a 85 96 STA &96 ; player_y_velocity &3e1c a0 15 LDY #&15 ; &15f6 = sound_15f6 &3e1e 20 c6 3a JSR &3ac6 ; play_sound # Play sound for jumping &3e21 a9 00 LDA #&00 &3e23 60 RTS ; start_player_climbing_down &3e24 20 25 3f JSR &3f25 ; check_if_player_can_climb # Returns non-zero if player can climb &3e27 f0 34 BEQ &3e5d ; finish_updating_player &3e29 a9 02 LDA #&02 &3e2b d0 13 BNE &3e40 ; set_climbing_direction # Always branches ; continue_climbing_down &3e2d 20 25 3f JSR &3f25 ; check_if_player_can_climb # Returns non-zero if player can climb &3e30 f0 04 BEQ &3e36 ; to_apply_player_velocities &3e32 a9 02 LDA #&02 &3e34 d0 0a BNE &3e40 ; set_climbing_direction # Always branches ; to_apply_player_velocities &3e36 4c 89 3d JMP &3d89 ; apply_player_velocities ; continue_climbing_up &3e39 20 25 3f JSR &3f25 ; check_if_player_can_climb # Returns non-zero if player can climb &3e3c f0 f8 BEQ &3e36 ; to_apply_player_velocities &3e3e a9 fe LDA #&fe ; set_climbing_direction &3e40 85 96 STA &96 ; player_y_velocity &3e42 18 CLC &3e43 65 91 ADC &91 ; player_y &3e45 85 91 STA &91 ; player_y &3e47 29 04 AND #&04 &3e49 4a LSR A &3e4a 4a LSR A &3e4b 69 29 ADC #&29 ; PLAYER_SPRITE_CLIMBING &3e4d 85 94 STA &94 ; player_sprite &3e4f a2 00 LDX #&00 &3e51 86 95 STX &95 ; player_x_velocity &3e53 ca DEX ; &ff &3e54 86 4e STX &4e ; jump_or_fall_timer &3e56 d0 05 BNE &3e5d ; finish_updating_player # Always branches ; finish_updating_player_after_floor_check &3e58 20 66 3e JSR &3e66 ; check_if_player_killed_by_hitting_floor # Returns zero if player killed by hitting floor &3e5b f0 6d BEQ &3eca ; freefalling_player_hit_floor ; finish_updating_player &3e5d 20 f2 39 JSR &39f2 ; check_for_collecting_pill &3e60 20 df 3a JSR &3adf ; consider_replotting_player &3e63 a9 00 LDA #&00 # Leave with zero to indicate player not killed &3e65 60 RTS ; check_if_player_killed_by_hitting_floor &3e66 a5 91 LDA &91 ; player_y &3e68 18 CLC &3e69 69 29 ADC #&29 # Consider the row beneath the player &3e6b a6 90 LDX &90 ; player_x &3e6d a8 TAY &3e6e 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y ; check_left_of_feet &3e71 a0 08 LDY #&08 # Consider left of feet &3e73 b1 78 LDA (&78),Y ; screen_address &3e75 aa TAX &3e76 29 ee AND #&ee ; 3330 &3e78 c9 ee CMP #&ee ; 3330 &3e7a f0 38 BEQ &3eb4 ; is_floor &3e7c 8a TXA &3e7d 29 77 AND #&77 ; 0333 &3e7f c9 77 CMP #&77 ; 0333 &3e81 f0 31 BEQ &3eb4 ; is_floor &3e83 8a TXA &3e84 29 cc AND #&cc ; 3300 &3e86 c9 cc CMP #&cc ; 3300 &3e88 d0 0c BNE &3e96 ; check_right_of_feet &3e8a a0 00 LDY #&00 # Consider far left of feet &3e8c b1 78 LDA (&78),Y ; screen_address &3e8e 29 11 AND #&11 ; 0003 &3e90 c9 11 CMP #&11 ; 0003 &3e92 f0 20 BEQ &3eb4 ; is_floor &3e94 d0 11 BNE &3ea7 ; start_or_continue_fall # Always branches ; check_right_of_feet &3e96 8a TXA &3e97 29 33 AND #&33 ; 0033 &3e99 c9 33 CMP #&33 ; 0033 &3e9b d0 0a BNE &3ea7 ; start_or_continue_fall &3e9d a0 10 LDY #&10 # Consider right of feet &3e9f b1 78 LDA (&78),Y ; screen_address &3ea1 29 88 AND #&88 ; 3000 &3ea3 c9 88 CMP #&88 ; 3000 &3ea5 f0 0d BEQ &3eb4 ; is_floor ; start_or_continue_fall &3ea7 a9 02 LDA #&02 &3ea9 85 96 STA &96 ; player_y_velocity &3eab a5 4e LDA &4e ; jump_or_fall_timer &3ead 30 04 BMI &3eb3 ; leave &3eaf a9 ff LDA #&ff &3eb1 85 4e STA &4e ; jump_or_fall_timer # Start player falling ; leave &3eb3 60 RTS ; is_floor &3eb4 a5 94 LDA &94 ; player_sprite &3eb6 c9 1e CMP #&1e ; PLAYER_SPRITE_FALLING # If the player was in freefall, &3eb8 f0 f9 BEQ &3eb3 ; leave # Leave with zero to indicate player killed &3eba a5 4e LDA &4e ; jump_or_fall_timer &3ebc f0 05 BEQ &3ec3 ; skip_sound # If the player wasn't previously supported, &3ebe a0 16 LDY #&16 ; &16f6 = sound_16f6 &3ec0 20 c6 3a JSR &3ac6 ; play_sound # Play sound for player hitting floor ; skip_sound &3ec3 a9 00 LDA #&00 &3ec5 85 4e STA &4e ; jump_or_fall_timer &3ec7 a9 ff LDA #&ff # Leave with non-zero to indicate player not killed &3ec9 60 RTS ; freefalling_player_hit_floor &3eca a0 10 LDY #&10 ; &10f6 = sound_10f6 &3ecc 20 c6 3a JSR &3ac6 ; play_sound # Play sound for freefalling player hitting floor &3ecf a9 00 LDA #&00 &3ed1 8d fa 0e STA &0efa ; sound_0ef6 + 4 (pitch) &3ed4 20 41 3c JSR &3c41 ; unplot_player &3ed7 a5 90 LDA &90 ; player_x ; keep_dead_player_on_screen_loop &3ed9 38 SEC &3eda e9 04 SBC #&04 &3edc b0 02 BCS &3ee0 ; skip_floor &3ede a9 00 LDA #&00 ; skip_floor &3ee0 c9 8c CMP #&8c &3ee2 b0 f5 BCS &3ed9 ; keep_dead_player_on_screen_loop &3ee4 aa TAX &3ee5 a5 91 LDA &91 ; player_y &3ee7 18 CLC &3ee8 69 1c ADC #&1c # Offset position for dead player &3eea a8 TAY &3eeb 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &3eee a9 0d LDA #&0d &3ef0 85 8d STA &8d ; rows_remaining &3ef2 a2 00 LDX #&00 ; plot_dead_player_row_loop &3ef4 a0 00 LDY #&00 &3ef6 a9 06 LDA #&06 &3ef8 85 8f STA &8f ; columns_remaining ; plot_dead_player_column_loop &3efa b1 78 LDA (&78),Y ; screen_address &3efc 3d 7b 1f AND &1f7b,X ; dead_player_mask &3eff 1d 00 1f ORA &1f00,X ; dead_player_sprite &3f02 91 78 STA (&78),Y ; screen_address &3f04 e8 INX &3f05 98 TYA &3f06 69 08 ADC #&08 # Move right four pixels &3f08 a8 TAY &3f09 c6 8f DEC &8f ; columns_remaining &3f0b d0 ed BNE &3efa ; plot_dead_player_column_loop &3f0d e6 81 INC &81 ; y &3f0f e6 78 INC &78 ; screen_address_low &3f11 a5 78 LDA &78 ; screen_address_low &3f13 29 07 AND #&07 &3f15 d0 03 BNE &3f1a ; skip_group &3f17 20 a4 3c JSR &3ca4 ; recalculate_screen_address_using_y ; skip_group &3f1a c6 8d DEC &8d ; rows_remaining &3f1c d0 d6 BNE &3ef4 ; plot_dead_player_row_loop &3f1e a9 00 LDA #&00 &3f20 85 39 STA &39 ; freefall_velocity &3f22 a9 ff LDA #&ff # Leave with non-zero to indicate player was killed &3f24 60 RTS ; check_if_player_can_climb &3f25 a2 72 LDX #&72 ; check_if_player_can_climb_loop &3f27 bd 21 01 LDA &0121,X ; player_buffer + 1 &3f2a 29 88 AND #&88 ; 3000 &3f2c f0 06 BEQ &3f34 ; check_row ; consider_checking_next_row &3f2e ca DEX &3f2f ca DEX &3f30 ca DEX &3f31 d0 f4 BNE &3f27 ; check_if_player_can_climb_loop &3f33 60 RTS ; check_row &3f34 bd 27 01 LDA &0127,X ; player_buffer + 1 + 3 * 2 &3f37 29 88 AND #&88 ; 3000 &3f39 c9 88 CMP #&88 ; 3000 &3f3b d0 f1 BNE &3f2e ; consider_checking_next_row &3f3d bd 24 01 LDA &0124,X ; player_buffer + 1 + 3 * 1 &3f40 29 88 AND #&88 ; 3000 &3f42 c9 88 CMP #&88 ; 3000 &3f44 d0 e8 BNE &3f2e ; consider_checking_next_row &3f46 ca DEX &3f47 ca DEX &3f48 ca DEX &3f49 f0 0a BEQ &3f55 ; leave # Leave with zero to indicate player can't climb &3f4b bd 21 01 LDA &0121,X ; player_buffer + 1 + 3 * 1 &3f4e 29 88 AND #&88 ; 3000 &3f50 c9 88 CMP #&88 ; 3000 &3f52 d0 da BNE &3f2e ; consider_checking_next_row &3f54 8a TXA # Leave with non-zero to indicate player can climb ; leave &3f55 60 RTS ; write_status &3f56 a9 ff LDA #&ff &3f58 85 64 STA &64 ; room_initialised # Set to non-zero to indicate room already initialised &3f5a a5 38 LDA &38 ; lives &3f5c 09 30 ORA #&30 ; "0" &3f5e 8d bf 23 STA &23bf ; status_screen_text + &bf &3f61 a0 00 LDY #&00 ; write_status_screen_text_loop &3f63 b9 00 23 LDA &2300,Y ; status_screen_text &3f66 20 ee ff JSR &ffee ; OSWRCH &3f69 c8 INY &3f6a c0 d2 CPY #&d2 &3f6c d0 f5 BNE &3f63 ; write_status_screen_text_loop &3f6e 20 74 3f JSR &3f74 ; write_score &3f71 4c fb 44 JMP &44fb ; write_inventory ; write_score &3f74 a5 7a LDA &7a ; score ; write_number &3f76 f0 27 BEQ &3f9f ; write_zero &3f78 4a LSR A &3f79 f0 1a BEQ &3f95 ; skip_division &3f7b 08 PHP ; score mod 2 &3f7c a2 ff LDX #&ff &3f7e 38 SEC ; division_loop &3f7f e8 INX &3f80 e9 0a SBC #&0a &3f82 b0 fb BCS &3f7f ; division_loop &3f84 48 PHA ; hundreds &3f85 8a TXA &3f86 f0 05 BEQ &3f8d ; skip_leading_zero &3f88 09 30 ORA #&30 ; "0" &3f8a 20 ee ff JSR &ffee ; OSWRCH # Write thousands ; skip_leading_zero &3f8d 68 PLA ; hundreds &3f8e 18 CLC &3f8f 69 3a ADC #&3a ; "9" + 1 &3f91 20 ee ff JSR &ffee ; OSWRCH # Write hundreds &3f94 28 PLP ; score mod 2 ; skip_division &3f95 90 03 BCC &3f9a ; write_double_zero ; write_fifty &3f97 a9 35 LDA #&35 ; "5" # Write 50 &3f99 2c a9 30 BIT &30a9 ; write_double_zero #3f9a LDA #&30 ; "0" # or 00 &3f9c 20 ee ff JSR &ffee ; OSWRCH ; write_zero &3f9f a9 30 LDA #&30 ; "0" &3fa1 6c 0e 02 JMP (&020e) ; oswrch_vector ; completion_screen &3fa4 a9 88 LDA #&88 &3fa6 85 52 STA &52 ; completion_sound_address_low ; play_completion_sounds_loop &3fa8 a6 52 LDX &52 ; completion_sound_address_low &3faa a0 54 LDY #&54 ; &5488 = completion_sounds &3fac 20 c8 3a JSR &3ac8 ; play_sound_from_XY &3faf a5 52 LDA &52 ; completion_sound_address_low &3fb1 18 CLC &3fb2 69 08 ADC #&08 &3fb4 85 52 STA &52 ; completion_sound_address_low &3fb6 c9 99 CMP #&99 &3fb8 90 ee BCC &3fa8 ; play_completion_sounds_loop &3fba a2 05 LDX #&05 &3fbc a9 09 LDA #&09 ; Set first colour duration &3fbe 20 f4 ff JSR &fff4 ; OSBYTE &3fc1 a9 0a LDA #&0a ; Set second colour duration &3fc3 20 f4 ff JSR &fff4 ; OSBYTE &3fc6 a9 a0 LDA #&a0 ; &54a0 = completion_colour_string &3fc8 a0 54 LDY #&54 &3fca a2 06 LDX #&06 &3fcc 20 4b 39 JSR &394b ; write_string &3fcf 20 41 3c JSR &3c41 ; unplot_player &3fd2 a9 48 LDA #&48 &3fd4 85 90 STA &90 ; player_x &3fd6 a9 60 LDA #&60 &3fd8 85 91 STA &91 ; player_y &3fda 20 97 3a JSR &3a97 ; replot_player_standing ; animation_completion_zoom_loop &3fdd a0 00 LDY #&00 &3fdf 84 8b STY &8b ; player_room &3fe1 a2 21 LDX #&21 ; write_zoom_rectangle_loop &3fe3 b9 66 54 LDA &5466,Y ; zoom_rectangle_string &3fe6 20 ee ff JSR &ffee ; OSWRCH &3fe9 c8 INY &3fea ca DEX &3feb d0 f6 BNE &3fe3 ; write_zoom_rectangle_loop &3fed 20 a4 42 JSR &42a4 ; adjust_zoom_rectangle_origin &3ff0 20 ba 42 JSR &42ba ; adjust_zoom_rectangle_size &3ff3 ce 68 54 DEC &5468 ; zoom_rectangle_string + 2 &3ff6 10 e5 BPL &3fdd ; animation_completion_zoom_loop &3ff8 a9 c0 LDA #&c0 ; &0bc0 = completion_room_data &3ffa 8d 80 0a STA &0a80 ; room_data_addresses &3ffd a9 0b LDA #&0b &3fff 8d 81 0a STA &0a81 ; room_data_addresses + 1 &4002 20 d2 39 JSR &39d2 ; initialise_room # Plot completion screen &4005 a5 75 LDA &75 ; update_room_address_high &4007 20 76 3f JSR &3f76 ; write_number # Write first half of completion code &400a a5 86 LDA &86 ; x_delta_low &400c 09 01 ORA #&01 &400e 20 76 3f JSR &3f76 ; write_number # Write second half of completion code ; infinite_loop &4011 4c 11 40 JMP &4011 ; infinite_loop ; status_screen &4014 20 62 40 JSR &4062 ; initialise_mode_4_screen_with_logo &4017 20 56 3f JSR &3f56 ; write_status ; status_screen_loop &401a 20 34 40 JSR &4034 ; check_for_sound_keys &401d a5 ec LDA &ec ; os_most_recently_pressed_key &401f c9 f0 CMP #&f0 ; ESCAPE &4021 f0 25 BEQ &4048 ; to_new_game &4023 c9 c9 CMP #&c9 ; ENTER &4025 d0 f3 BNE &401a ; status_screen_loop ; initialise_then_update_room &4027 20 d2 39 JSR &39d2 ; initialise_room &402a a9 00 LDA #&00 &402c 85 64 STA &64 ; room_initialised # Set to zero to indicate room being initialised &402e 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting &4031 4c 6d 43 JMP &436d ; consider_game_keys ; check_for_sound_keys &4034 c9 f3 CMP #&f3 ; f3 &4036 f0 07 BEQ &403f ; disable_sound &4038 c9 f2 CMP #&f2 ; f2 &403a d0 1f BNE &405b ; leave ; enable_sound &403c a2 00 LDX #&00 &403e 2c a2 ff BIT &ffa2 ; disable_sound #403f LDX #&ff &4041 a0 00 LDY #&00 &4043 a9 d2 LDA #&d2 ; Read/Write sound suppression flag &4045 6c 0a 02 JMP (&020a) ; osbyte_vector ; to_new_game &4048 4c f9 42 JMP &42f9 ; new_game ; write_null_terminated_string &404b 84 37 STY &37 ; string_address_high &404d 86 36 STX &36 ; string_address_low &404f a0 00 LDY #&00 ; write_null_terminated_string_loop &4051 b1 36 LDA (&36),Y ; string_address &4053 f0 06 BEQ &405b ; leave &4055 20 ee ff JSR &ffee ; OSWRCH &4058 c8 INY &4059 d0 f6 BNE &4051 ; write_null_terminated_string_loop ; leave &405b 60 RTS ; intro_text_window_string &405c 1c 10 08 17 02 ; define text window x:(&10, &17), y:(&02, &08) &4061 00 ; end of string ; initialise_mode_4_screen_with_logo &4062 20 95 40 JSR &4095 ; ; initialise_mode_4_screen &4065 a2 5c LDX #&5c ; &405c = intro_text_window_string &4067 a0 40 LDY #&40 &4069 20 4b 40 JSR &404b ; write_null_terminated_string &406c a2 80 LDX #&80 ; write_logo_loop &406e 8a TXA &406f 20 ee ff JSR &ffee ; OSWRCH &4072 e8 INX &4073 e0 a0 CPX #&a0 &4075 d0 f7 BNE &406e ; write_logo_loop &4077 a9 1a LDA #&1a ; restore default windows &4079 6c 0e 02 JMP (&020e) ; oswrch_vector ; initialise_mode_4_screen_text &407c 16 04 ; change to MODE 4 &407e 13 00 07 00 00 00 ; set colour 0 to white &4084 13 01 01 00 00 00 ; set colour 1 to red &408a 17 01 00 00 00 00 00 00 00 00 ; disable cursor &4094 0a ; move cursor down a line ; initialise_mode_4_screen &4095 a9 7c LDA #&7c ; &407c = initialise_mode_4_screen_text &4097 a0 40 LDY #&40 &4099 a2 19 LDX #&19 &409b 20 4b 39 JSR &394b ; write_string &409e a0 7b LDY #&7b &40a0 20 be 40 JSR &40be ; write_vertical_edge # Plot left border &40a3 a0 7c LDY #&7c &40a5 20 d5 40 JSR &40d5 ; write_horizontal_edge # Plot bottom border &40a8 a9 1e LDA #&1e ; move cursor to top left &40aa 20 ee ff JSR &ffee ; OSWRCH &40ad a9 0b LDA #&0b ; move cursor up one line &40af 20 ee ff JSR &ffee ; OSWRCH &40b2 a0 7d LDY #&7d &40b4 20 d5 40 JSR &40d5 ; write_horizontal_edge # Plot top border &40b7 a9 0a LDA #&0a ; move cursor down one line &40b9 20 cd 40 JSR &40cd ; write_character_without_moving_cursor &40bc a0 7e LDY #&7e # Plot right border ; write_vertical_edge &40be a2 1e LDX #&1e ; write_vertical_edge_loop &40c0 98 TYA &40c1 20 cd 40 JSR &40cd ; write_character_without_moving_cursor &40c4 a9 0a LDA #&0a &40c6 20 ee ff JSR &ffee ; OSWRCH &40c9 ca DEX &40ca d0 f4 BNE &40c0 ; write_vertical_edge_loop &40cc 60 RTS ; write_character_without_moving_cursor &40cd 20 ee ff JSR &ffee ; OSWRCH &40d0 a9 08 LDA #&08 ; backspace &40d2 6c 0e 02 JMP (&020e) ; oswrch_vector ; write_horizontal_edge &40d5 20 e1 40 JSR &40e1 ; write_corner &40d8 a2 26 LDX #&26 &40da 98 TYA ; write_horizontal_edge_loop &40db 20 ee ff JSR &ffee ; OSWRCH &40de ca DEX &40df d0 fa BNE &40db ; write_row_of_characters_loop ; write_corner &40e1 a9 20 LDA #&20 ; " " &40e3 6c 0e 02 JMP (&020e) ; oswrch_vector ; unused &40e6 20 fb 44 JSR &44fb ; write_inventory ; clear_screen &40e9 a9 0c LDA #&0c ; CLS &40eb 6c 0e 02 JMP (&020e) ; oswrch_vector ; update_beanstalk &40ee ad 93 0c LDA &0c93 ; beanstalk_has_been_planted # Zero if bean has been planted &40f1 d0 29 BNE &411c ; leave &40f3 ce 95 0c DEC &0c95 ; beanstalk_timer_lower &40f6 d0 24 BNE &411c ; leave &40f8 ce 96 0c DEC &0c96 ; beanstalk_timer_high &40fb d0 1f BNE &411c ; leave &40fd a9 05 LDA #&05 &40ff 8d 96 0c STA &0c96 ; beanstalk_timer_high &4102 ee 94 0c INC &0c94 ; beanstalk_height_in_lower_room &4105 ae 94 0c LDX &0c94 ; beanstalk_height_in_lower_room &4108 e0 0a CPX #&0a &410a d0 10 BNE &411c ; leave &410c ce 94 0c DEC &0c94 ; beanstalk_height_in_lower_room &410f ee 97 0c INC &0c97 ; beanstalk_height_in_upper_room &4112 ae 97 0c LDX &0c97 ; beanstalk_height_in_upper_room &4115 e0 0f CPX #&0f &4117 d0 03 BNE &411c ; leave &4119 ce 97 0c DEC &0c97 ; beanstalk_height_in_upper_room &411c 60 RTS ; initialise_game &411d a0 02 LDY #&02 &411f 84 62 STY &62 ; game_speed &4121 84 61 STY &61 ; player_speed &4123 84 60 STY &60 ; player_movement_cooldown &4125 c8 INY ; 3 &4126 84 03 STY &03 ; eye_shield_uses_remaining &4128 84 38 STY &38 ; lives &412a a9 29 LDA #&29 &412c 85 98 STA &98 ; player_sprite_height &412e a9 3e LDA #&3e # Set length of top platform in room &05 &4130 8d a0 47 STA &47a0 ; room_05_data + &41 # Unnecessary code, although &47a0 = &44 in PIAS version &4133 a2 47 LDX #&47 &4135 a9 ff LDA #&ff &4137 85 7b STA &7b ; elixir_plotted # Set to non-zero to indicate elixir bottle not plotted ; initialise_room_flags_and_objects_collected_loop &4139 9d 50 0c STA &0c50,X ; room_flags # Also initialises objects_collected &413c ca DEX &413d 10 fa BPL &4139 ; initialise_room_flags_and_objects_collected_loop &413f a9 00 LDA #&00 &4141 85 63 STA &63 ; pill_colour &4143 85 9a STA &9a ; player_buffer_offset # Set to zero to indicate player sprite not clipped &4145 85 9d STA &9d ; player_clipping # Set to zero to indicate player sprite not clipped &4147 85 9e STA &9e ; player_needs_full_replot # Set to zero to indicate full replot not needed &4149 85 4e STA &4e ; jump_or_fall_timer &414b 85 7a STA &7a ; score &414d 85 64 STA &64 ; room_initialised # Set to zero to indicate room being initialised &414f 85 6b STA &6b ; player_room_for_speed &4151 85 39 STA &39 ; freefall_velocity &4153 85 02 STA &02 ; player_is_in_freefall # Set to zero to indicate not in freefall &4155 a9 0c LDA #&0c &4157 85 3a STA &3a ; freefall_acceleration_cooldown &4159 ad a0 02 LDA &02a0 ; os_countdown_timer + 4 &415c 85 40 STA &40 ; rnd_state &415e ad 96 02 LDA &0296 ; os_system_clock_one + 4 &4161 85 42 STA &42 ; rnd_state + 2 &4163 60 RTS ; unused &4164 10 06 1e 1a 17 15 0d 00 ; replot_enemy &416c a4 51 LDY &51 ; sprite_y &416e a6 50 LDX &50 ; sprite_x &4170 a5 5c LDA &5c ; sprite_height &4172 85 8d STA &8d ; rows_remaining &4174 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &4177 a2 00 LDX #&00 ; unplot_enemy_row_loop &4179 a0 00 LDY #&00 &417b a5 5d LDA &5d ; sprite_width &417d 85 8f STA &8f ; columns_remaining ; unplot_enemy_column_loop &417f bd 00 0b LDA &0b00,X ; enemy_buffer &4182 91 78 STA (&78),Y ; screen_address &4184 e8 INX &4185 c6 8f DEC &8f ; columns_remaining &4187 f0 06 BEQ &418f ; consider_unplotting_next_row &4189 98 TYA &418a 69 08 ADC #&08 # Move right four pixels &418c a8 TAY &418d 90 f0 BCC &417f ; unplot_enemy_loop # Always branches ; consider_unplotting_next_row &418f c6 8d DEC &8d ; rows_remaining &4191 f0 0f BEQ &41a2 ; plot_enemy &4193 e6 81 INC &81 ; y &4195 e6 78 INC &78 ; screen_address_low &4197 a5 78 LDA &78 ; screen_address_low &4199 29 07 AND #&07 &419b d0 dc BNE &4179 ; unplot_enemy_row_loop &419d 20 a4 3c JSR &3ca4 ; recalculate_screen_address_using_y &41a0 90 d7 BCC &4179 ; unplot_enemy_row_loop # Always branches ; plot_enemy &41a2 a4 53 LDY &53 ; enemy_y &41a4 84 51 STY &51 ; sprite_y &41a6 a5 52 LDA &52 ; enemy_x &41a8 29 03 AND #&03 &41aa aa TAX &41ab b5 54 LDA &54,X ; enemy_mask_addresses &41ad 8d ce 41 STA &41ce ; enemy_mask_address_low &41b0 b5 58 LDA &58,X ; enemy_sprite_addresses &41b2 8d d1 41 STA &41d1 ; enemy_sprite_address_low &41b5 a6 52 LDX &52 ; enemy_x &41b7 86 50 STX &50 ; sprite_x &41b9 a5 5c LDA &5c ; sprite_height &41bb 85 8d STA &8d ; rows_remaining &41bd 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &41c0 a2 00 LDX #&00 ; plot_enemy_row_loop &41c2 a0 00 LDY #&00 &41c4 a5 5d LDA &5d ; sprite_width &41c6 85 8f STA &8f ; columns_remaining ; plot_enemy_column_loop &41c8 b1 78 LDA (&78),Y ; screen_address &41ca 9d 00 0b STA &0b00,X ; enemy_buffer &41cd 3d 00 10 AND &1000,X # actually AND enemy_mask_address,X &41d0 1d 00 10 ORA &1000,X # actually ORA enemy_sprite_address,X &41d3 91 78 STA (&78),Y ; screen_address &41d5 e8 INX &41d6 c6 8f DEC &8f ; columns_remaining &41d8 f0 06 BEQ &41e0 ; consider_plotting_next_row &41da 98 TYA &41db 69 08 ADC #&08 # Move right four pixels &41dd a8 TAY &41de 90 e8 BCC &41c8 ; plot_enemy_column_loop ; consider_plotting_next_row &41e0 c6 8d DEC &8d ; rows_remaining &41e2 f0 3a BEQ &421e ; leave &41e4 e6 81 INC &81 ; y &41e6 e6 78 INC &78 ; screen_address_low &41e8 a5 78 LDA &78 ; screen_address_low &41ea 29 07 AND #&07 &41ec d0 d4 BNE &41c2 ; plot_enemy_row_loop &41ee 20 a4 3c JSR &3ca4 ; recalculate_screen_address_using_y &41f1 90 cf BCC &41c2 ; plot_enemy_row_loop # Always branches ; initialise_player &41f3 a9 1a LDA #&1a # Player starts in room &1a &41f5 85 8b STA &8b ; player_room &41f7 20 00 42 JSR &4200 ; initialise_player_in_room &41fa 20 d2 43 JSR &43d2 ; wait_for_vsync &41fd 4c ec 43 JMP &43ec ; write_clock ; initialise_player_in_room &4200 a9 1d LDA #&1d ; PLAYER_SPRITE_STANDING &4202 85 94 STA &94 ; player_sprite &4204 a5 8b LDA &8b ; player_room &4206 0a ASL A &4207 a8 TAY &4208 b9 00 0c LDA &0c00,Y ; player_starting_positions &420b 85 91 STA &91 ; player_y &420d b9 01 0c LDA &0c01,Y ; player_starting_positions + 1 &4210 85 90 STA &90 ; player_x &4212 60 RTS ; longer_delay &4213 a9 14 LDA #&14 ; longer_delay_for_A &4215 85 85 STA &85 ; count ; longer_delay_loop &4217 20 e2 43 JSR &43e2 ; wait_for_clock &421a c6 85 DEC &85 ; count &421c d0 f9 BNE &4217 ; longer_delay_loop ; leave &421e 60 RTS ; plot_room_edge &421f a9 55 LDA #&55 ; &5500 = room_edge_data &4221 e0 1f CPX #&1f &4223 69 00 ADC #&00 &4225 a8 TAY &4226 bd d0 0a LDA &0ad0,X ; room_edge_edge_data_addresses_low &4229 4c 55 37 JMP &3755 ; plot_room_data_from_AY ; start_player_freefalling &422c a9 1e LDA #&1e ; PLAYER_SPRITE_FALLING &422e 85 94 STA &94 ; player_sprite &4230 a9 04 LDA #&04 &4232 85 39 STA &39 ; freefall_velocity &4234 a5 91 LDA &91 ; player_y # &4234 - &4263 is unnecessary code &4236 18 CLC &4237 69 29 ADC #&29 &4239 85 85 STA &85 ; check_y &423b a5 90 LDA &90 ; player_x &423d 69 04 ADC #&04 &423f 85 8c STA &8c ; plot_x_origin ; find_freefall_initial_y_loop &4241 a6 8c LDX &8c ; plot_x_origin &4243 a4 85 LDY &85 ; check_y &4245 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &4248 a0 00 LDY #&00 &424a b1 78 LDA (&78),Y ; screen_address &424c c9 ff CMP #&ff ; 3333 &424e f0 0d BEQ &425d ; found_freefall_initial_y &4250 a5 85 LDA &85 ; check_y &4252 18 CLC &4253 69 02 ADC #&02 &4255 85 85 STA &85 ; check_y &4257 90 e8 BCC &4241 ; find_freefall_initial_y_loop &4259 a9 00 LDA #&00 &425b 85 85 STA &85 ; check_y ; found_freefall_initial_y &425d a5 85 LDA &85 ; check_y &425f 38 SEC &4260 e9 29 SBC #&29 &4262 85 3b STA &3b ; freefall_initial_y # Unused variable &4264 a9 00 LDA #&00 &4266 85 95 STA &95 ; player_x_velocity &4268 60 RTS ; update_freefalling_player &4269 c6 3a DEC &3a ; freefall_acceleration_cooldown &426b d0 0a BNE &4277 ; skip_acceleration &426d a9 08 LDA #&08 &426f 85 39 STA &39 ; freefall_velocity &4271 85 02 STA &02 ; player_is_in_freefall # Set to non-zero to start freefall &4273 a9 0a LDA #&0a &4275 85 3a STA &3a ; freefall_acceleration_cooldown ; skip_acceleration &4277 a5 91 LDA &91 ; player_y &4279 18 CLC &427a 65 39 ADC &39 ; freefall_velocity &427c 85 91 STA &91 ; player_y &427e c9 d2 CMP #&d2 ; FREEFALL_START &4280 90 16 BCC &4298 ; to_finish_updating_player ; freefalling_into_new_room &4282 a5 8b LDA &8b ; player_room &4284 29 f8 AND #&f8 &4286 f0 13 BEQ &429b ; is_bottom_room &4288 a9 b2 LDA #&b2 ; &08b2 = game_colours_initialisation_string &428a a0 08 LDY #&08 &428c a2 06 LDX #&06 &428e 20 4b 39 JSR &394b ; write_string &4291 a9 f8 LDA #&f8 # Move down a room &4293 a0 02 LDY #&02 &4295 4c 07 3d JMP &3d07 ; add_to_player_room ; to_finish_updating_player &4298 4c 5d 3e JMP &3e5d ; finish_updating_player ; is_bottom_room &429b 85 02 STA &02 ; player_is_in_freefall # Set to zero to indicate not in freefall &429d a9 ce LDA #&ce &429f 85 91 STA &91 ; player_y &42a1 4c ca 3e JMP &3eca ; freefalling_player_hit_floor ; adjust_zoom_rectangle_origin &42a4 a2 02 LDX #&02 &42a6 20 ab 42 JSR &42ab ; adjust_zoom_rectangle_origin_coordinate &42a9 a2 04 LDX #&04 ; adjust_zoom_rectangle_origin_coordinate &42ab bd 69 54 LDA &5469,X ; zoom_rectangle_string + 3 &42ae 38 SEC &42af e9 08 SBC #&08 &42b1 9d 69 54 STA &5469,X ; zoom_rectangle_string + 3 &42b4 b0 03 BCS &42b9 ; leave &42b6 de 6a 54 DEC &546a,X ; zoom_rectangle_string + 4 ; leave &42b9 60 RTS ; adjust_zoom_rectangle_size &42ba a2 0a LDX #&0a &42bc 20 c1 42 JSR &42c1 ; adjust_zoom_rectangle_size_coordinates &42bf a2 0e LDX #&0e ; adjust_zoom_rectangle_size_coordinates &42c1 bd 69 54 LDA &5469,X ; zoom_rectangle_string + 3 &42c4 18 CLC &42c5 69 10 ADC #&10 &42c7 9d 69 54 STA &5469,X ; zoom_rectangle_string + 3 &42ca 90 03 BCC &42cf ; skip_overflow &42cc fe 6a 54 INC &546a,X ; zoom_rectangle_string + 4 ; skip_overflow &42cf bd 75 54 LDA &5475,X ; zoom_rectangle_string + 15 &42d2 38 SEC &42d3 e9 10 SBC #&10 &42d5 9d 75 54 STA &5475,X ; zoom_rectangle_string + 15 &42d8 b0 df BCS &42b9 ; leave &42da de 76 54 DEC &5476,X ; zoom_rectangle_string + 16 &42dd 60 RTS ; game_entry_point &42de a9 18 LDA #&18 # Use user defined characters &42e0 8d 67 03 STA &0367 ; os_font_flag # for &60 - &7f and &80 - &9f &42e3 a9 53 LDA #&53 &42e5 85 4a STA &4a ; rnd_seed &42e7 a9 b5 LDA #&b5 &42e9 85 4b STA &4b ; rnd_seed + 1 &42eb a9 76 LDA #&76 &42ed 85 4c STA &4c ; rnd_seed + 2 &42ef ad 92 02 LDA &0292 ; os_system_clock_one &42f2 85 43 STA &43 ; rnd_state + 3 &42f4 ad 98 02 LDA &0298 ; os_system_clock_two + 1 &42f7 85 41 STA &41 ; rnd_state + 1 ; new_game &42f9 a2 ff LDX #&ff &42fb 9a TXS &42fc 20 1d 41 JSR &411d ; initialise_game &42ff 20 f3 41 JSR &41f3 ; initialise_player &4302 20 d2 39 JSR &39d2 ; initialise_room &4305 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting ; main_game_loop &4308 a2 ff LDX #&ff &430a 9a TXS &430b 20 ee 40 JSR &40ee ; update_beanstalk &430e a5 ec LDA &ec ; os_most_recently_pressed_key &4310 c9 a0 CMP #&a0 ; f0 &4312 d0 03 BNE &4317 ; f0_not_pressed &4314 20 34 45 JSR &4534 ; wait_for_f1 ; f0_not_pressed &4317 20 34 40 JSR &4034 ; check_for_sound_keys &431a a5 02 LDA &02 ; player_is_in_freefall # Non-zero if in freefall &431c f0 04 BEQ &4322 ; skip_setting_freefall_velocity &431e a9 08 LDA #&08 &4320 85 39 STA &39 ; freefall_velocity ; skip_setting_freefall_velocity &4322 20 e2 43 JSR &43e2 ; wait_for_clock &4325 20 fb 43 JSR &43fb ; consider_collecting_object &4328 c6 60 DEC &60 ; player_movement_cooldown &432a d0 41 BNE &436d ; consider_game_keys &432c a5 61 LDA &61 ; player_speed &432e 85 60 STA &60 ; player_movement_cooldown &4330 20 3d 3d JSR &3d3d ; update_player # Returns non-zero if player died &4333 d0 48 BNE &437d ; new_life_after_delay &4335 a5 63 LDA &63 ; pill_colour &4337 f0 05 BEQ &433e ; no_pill_active &4339 30 42 BMI &437d ; new_life_after_delay # Unnecessary code; never branches &433b 4c 95 44 JMP &4495 ; apply_pill_effect ; no_pill_active &433e a5 6b LDA &6b ; player_room_for_speed # Non-zero if speed affected &4340 f0 2b BEQ &436d ; consider_game_keys &4342 30 12 BMI &4356 ; is_slow &4344 a5 8b LDA &8b ; player_room &4346 29 f8 AND #&f8 &4348 c5 6b CMP &6b ; player_room_for_speed &434a f0 21 BEQ &436d ; consider_game_keys ; reset_player_speed # Reset speed when player changes room vertically &434c a9 00 LDA #&00 &434e 85 6b STA &6b ; player_room_for_speed &4350 a9 02 LDA #&02 &4352 85 61 STA &61 ; player_speed &4354 d0 17 BNE &436d ; consider_game_keys # Always branches ; is_slow &4356 a5 8b LDA &8b ; player_room &4358 29 f8 AND #&f8 &435a 09 80 ORA #&80 # Top bit set if under influence of magenta pill &435c c5 6b CMP &6b ; player_room_for_speed &435e d0 ec BNE &434c ; reset_player_speed &4360 c6 61 DEC &61 ; player_speed &4362 d0 09 BNE &436d ; consider_game_keys &4364 20 b1 43 JSR &43b1 ; rnd # Set random speed &4367 29 03 AND #&03 &4369 aa TAX &436a e8 INX &436b 86 61 STX &61 ; player_speed ; consider_game_keys &436d a5 ec LDA &ec ; os_most_recently_pressed_key &436f c9 f0 CMP #&f0 ; ESCAPE &4371 f0 86 BEQ &42f9 ; new_game &4373 c9 c9 CMP #&c9 ; ENTER &4375 d0 03 BNE &437a ; to_update_room &4377 4c 14 40 JMP &4014 ; status_screen ; to_update_room &437a 6c 74 00 JMP (&0074) ; update_room_address # Continues at &303a ; new_life_after_delay &437d a9 41 LDA #&41 &437f 20 15 42 JSR &4215 ; longer_delay_for_A &4382 a9 fe LDA #&fe &4384 8d fa 0e STA &0efa ; sound_0ef6 + 4 (pitch) &4387 4c dd 44 JMP &44dd ; new_life ; clock_coordinates &438a 84 b4 db e8 db b4 84 5a 31 20 31 5a 84 b4 db ; play_clock_sound &4399 a0 54 LDY #&54 ; &5456 = sound_5456 &439b a2 56 LDX #&56 &439d 4c c8 3a JMP &3ac8 ; play_sound_from_XY ; unused_delay # Unused code &43a0 a2 01 LDX #&01 ; unused_delay_loop &43a2 ce bf 09 DEC &09bf ; delay_count &43a5 ee bf 09 INC &09bf ; delay_count &43a8 ce bf 09 DEC &09bf ; delay_count &43ab d0 f5 BNE &43a2 ; unused_delay_loop &43ad ca DEX &43ae 10 f2 BPL &43a2 ; unused_delay_loop &43b0 60 RTS ; rnd &43b1 a0 08 LDY #&08 ; shuffle_rnd_state_loop &43b3 18 CLC &43b4 a5 43 LDA &43 ; rnd_state + 3 &43b6 10 0c BPL &43c4 ; skip_seed &43b8 a2 02 LDX #&02 ; add_seed_loop &43ba b5 40 LDA &40,X ; rnd_state &43bc 55 4a EOR &4a,X ; rnd_seed &43be 95 40 STA &40,X ; rnd_state &43c0 ca DEX &43c1 10 f7 BPL &43ba ; add_seed_loop &43c3 38 SEC ; skip_seed &43c4 26 40 ROL &40 ; rnd_state &43c6 26 41 ROL &41 ; rnd_state + 1 &43c8 26 42 ROL &42 ; rnd_state + 2 &43ca 26 43 ROL &43 ; rnd_state + 3 &43cc 88 DEY &43cd d0 e4 BNE &43b3 ; shuffle_rnd_state_loop &43cf a5 43 LDA &43 ; rnd_state + 3 &43d1 60 RTS ; wait_for_vsync &43d2 a9 02 LDA #&02 # Disable v-sync interrupts &43d4 8d 4e fe STA &fe4e ; System VIA interrupt enable register ; wait_for_vsync_loop &43d7 2c 4d fe BIT &fe4d ; System VIA interrupt flag register &43da f0 fb BEQ &43d7 ; wait_for_vsync_loop &43dc a9 82 LDA #&82 # Enable v-sync interrupts &43de 8d 4e fe STA &fe4e ; System VIA interrupt enable register ; leave &43e1 60 RTS ; wait_for_clock &43e2 20 f2 43 JSR &43f2 ; read_clock &43e5 ad f6 1e LDA &1ef6 ; clock_block_for_reading &43e8 c5 62 CMP &62 ; game_speed &43ea 90 f6 BCC &43e2 ; wait_for_clock ; write_clock &43ec a9 02 LDA #&02 ; Write system clock &43ee a0 1d LDY #&1d ; &1df6 = clock_block_for_writing &43f0 d0 04 BNE &43f6 ; read_or_write_clock # Always branches ; read_clock &43f2 a9 01 LDA #&01 ; Read system clock &43f4 a0 1e LDY #&1e ; &1ef6 = clock_block_for_reading ; read_or_write_clock &43f6 a2 f6 LDX #&f6 &43f8 6c 0c 02 JMP (&020c) ; osword_vector ; consider_collecting_object &43fb a5 66 LDA &66 ; object_x # Zero if no object in room &43fd f0 e2 BEQ &43e1 ; leave &43ff a5 90 LDA &90 ; player_x &4401 29 fc AND #&fc &4403 c5 66 CMP &66 ; object_x &4405 d0 da BNE &43e1 ; leave &4407 a5 91 LDA &91 ; player_y &4409 c5 67 CMP &67 ; object_y_min &440b b0 d4 BCS &43e1 ; leave &440d c5 68 CMP &68 ; object_y_max &440f 90 d0 BCC &43e1 ; leave &4411 c6 67 DEC &67 ; object_y_min &4413 a5 67 LDA &67 ; object_y_min &4415 e5 91 SBC &91 ; player_y &4417 85 67 STA &67 ; y_offset &4419 0a ASL A &441a 65 67 ADC &67 ; y_offset &441c aa TAX &441d a4 69 LDY &69 ; object_buffer_y &441f a9 00 LDA #&00 &4421 85 66 STA &66 ; object_x # Set to zero to indicate no object in room ; remove_object_from_buffer &4423 9d 20 01 STA &0120,X ; player_buffer &4426 e8 INX &4427 88 DEY &4428 d0 f9 BNE &4423 ; remove_object_from_buffer &442a a4 8b LDY &8b ; player_room &442c b9 50 0c LDA &0c50,Y ; room_flags &442f 29 bf AND #&bf ; !ROOM_FLAG_OBJECT &4431 99 50 0c STA &0c50,Y ; room_flags &4434 a4 6a LDY &6a ; object_type &4436 a9 00 LDA #&00 &4438 99 78 0c STA &0c78,Y ; objects_collected # Set to zero to indicate object has been collected ; play_chime &443b a2 42 LDX #&42 ; &4442 = sound_4442 &443d a0 44 LDY #&44 &443f 4c c8 3a JMP &3ac8 ; play_sound_from_XY # Play sound for collecting object ; sound_4442 # Collecting object ; chan vol pitch dur &4442 02 00 0a 00 50 00 03 00 ; not_red &444a ad 71 03 LDA &0371 ; os_palette + 1 &444d 85 63 STA &63 ; pill_colour &444f 60 RTS ; collect_pill &4450 a6 8b LDX &8b ; player_room &4452 5d 50 0c EOR &0c50,X ; room_flags &4455 9d 50 0c STA &0c50,X ; room_flags &4458 98 TYA &4459 30 ef BMI &444a ; not_red ; is_red &445b e6 7a INC &7a ; score &445d a0 18 LDY #&18 ; &18f6 = sound_18f6 &445f 4c c6 3a JMP &3ac6 ; play_sound # Play sound for collecting red pill ; stop_clock &4462 ad 61 0c LDA &0c61 ; room_flags + &11 &4465 29 7f AND #&7f ; !ROOM_FLAG_SPECIAL # Clear top bit to indicate clock has been stopped &4467 8d 61 0c STA &0c61 ; room_flags + &11 &446a a5 55 LDA &55 ; clock_position &446c 85 4d STA &4d ; fixed_clock_position &446e a2 01 LDX #&01 # Use object type &01 (clock button) &4470 a9 2c LDA #&2c &4472 85 89 STA &89 ; plot_x &4474 a9 36 LDA #&36 &4476 85 81 STA &81 ; y &4478 20 e1 38 JSR &38e1 ; room_has_object # Plot depressed clock button &447b a9 ef LDA #&ef ; 3332 &447d 8d 1c 61 STA &611c ; screen_memory + &180 * 6 + 8 * 3 + 4 # Plot bottom left of depressed clock button &4480 60 RTS ; is_blue_pill # Blue pill speeds up player &4481 c6 61 DEC &61 ; player_speed &4483 a2 ea LDX #&ea ; &1fea = sound_1fea # Play sound for collecting blue pill ; affect_player_speed &4485 a5 8b LDA &8b ; player_room &4487 29 f8 AND #&f8 &4489 85 6b STA &6b ; player_room_for_speed # Top bit clear to indicate fast &448b a0 1f LDY #&1f &448d d0 23 BNE &44b2 ; play_sound_for_pill # Always branches ; is_cyan_pill # Cyan pill slows down player &448f e6 61 INC &61 ; player_speed &4491 a2 f2 LDX #&f2 ; &1ff2 = sound_1ff2 # Play sound for collecting cyan pill &4493 d0 f0 BNE &4485 ; affect_player_speed ; apply_pill_effect &4495 c9 03 CMP #&03 ; Y &4497 90 31 BCC &44ca ; is_green_pill &4499 f0 08 BEQ &44a3 ; is_yellow_pill &449b c9 05 CMP #&05 ; M &449d 90 e2 BCC &4481 ; is_blue_pill &449f f0 1b BEQ &44bc ; is_magenta_pill &44a1 b0 ec BCS &448f ; is_cyan_pill # Always branches ; is_yellow_pill # Yellow pill kills player &44a3 a9 50 LDA #&50 &44a5 85 60 STA &60 ; player_movement_cooldown &44a7 a9 1e LDA #&1e ; PLAYER_SPRITE_FALLING &44a9 85 94 STA &94 ; player_sprite &44ab 20 ca 3b JSR &3bca ; plot_player_using_buffer &44ae a0 1f LDY #&1f ; &1fe2 = sound_1fe2 # Play sound for collecting yellow pill &44b0 a2 e2 LDX #&e2 ; play_sound_for_pill &44b2 20 c8 3a JSR &3ac8 ; play_sound_from_XY &44b5 a9 00 LDA #&00 &44b7 85 63 STA &63 ; pill_colour &44b9 4c 6d 43 JMP &436d ; consider_game_keys ; is_magenta_pill # Magenta pill slows down player variably &44bc a5 8b LDA &8b ; player_room &44be 09 80 ORA #&80 # Set top bit to indicate variable slowness &44c0 29 f8 AND #&f8 &44c2 85 6b STA &6b ; player_room_for_speed &44c4 a0 29 LDY #&29 ; &29f6 = sound_29f6 # Play sound for collecting magenta pill ; to_play_sound_for_pill &44c6 a2 f6 LDX #&f6 &44c8 d0 e8 BNE &44b2 ; play_sound_for_pill # Always branches ; is_green_pill # Green pill causes player to fall &44ca ad 78 0c LDA &0c78 ; objects_collected + &00 (OBJECT_ANTIDOTE_TO_GREEN_PILLS) &44cd f0 0a BEQ &44d9 ; skip_falling_because_of_pill # Zero if player has collected antidote &44cf a5 91 LDA &91 ; player_y &44d1 c9 c8 CMP #&c8 &44d3 b0 04 BCS &44d9 ; skip_falling_because_of_pill &44d5 69 02 ADC #&02 &44d7 85 91 STA &91 ; player_y ; skip_falling_because_of_pill &44d9 a0 2a LDY #&2a ; &2af6 = sound_2af6 # Play sound for collecting green pill &44db d0 e9 BNE &44c6 ; to_play_sound_for_pill # Always branches ; new_life &44dd c6 38 DEC &38 ; lives &44df f0 06 BEQ &44e7 ; game_over_screen ; new_room &44e1 20 00 42 JSR &4200 ; initialise_player_in_room &44e4 4c 27 40 JMP &4027 ; initialise_then_update_room ; game_over_screen &44e7 20 62 40 JSR &4062 ; initialise_mode_4_screen &44ea a2 d2 LDX #&d2 ; &23d2 = game_over_string &44ec a0 23 LDY #&23 &44ee 20 4b 40 JSR &404b ; write_null_terminated_string &44f1 20 74 3f JSR &3f74 ; write_score ; wait_for_keypress &44f4 a5 ec LDA &ec ; os_most_recently_pressed_key &44f6 f0 fc BEQ &44f4 ; wait_for_keypress &44f8 4c f9 42 JMP &42f9 ; new_game ; write_inventory &44fb a9 9a LDA #&9a ; &249a = inventory_text_window_string &44fd a0 24 LDY #&24 &44ff a2 05 LDX #&05 &4501 20 4b 39 JSR &394b ; write_string &4504 a0 19 LDY #&19 &4506 84 85 STY &85 ; item &4508 a0 00 LDY #&00 &450a 84 30 STY &30 ; item_count ; write_inventory_loop &450c a4 85 LDY &85 ; item &450e b9 78 0c LDA &0c78,Y ; objects_collected # Zero if item has been collected &4511 d0 12 BNE &4525 ; consider_next_item &4513 e6 30 INC &30 ; item_count &4515 98 TYA &4516 0a ASL A &4517 a8 TAY &4518 be c0 09 LDX &09c0,Y ; inventory_string_addresses &451b b9 c1 09 LDA &09c1,Y ; inventory_string_addresses + 1 &451e a8 TAY &451f 20 4b 40 JSR &404b ; write_null_terminated_string &4522 20 e7 ff JSR &ffe7 ; OSNEWL ; consider_next_item &4525 c6 85 DEC &85 ; item &4527 10 e3 BPL &450c ; write_inventory_loop &4529 a4 30 LDY &30 ; item_count &452b d0 0d BNE &453a ; leave &452d a2 c0 LDX #&c0 ; &54c0 = empty_string &452f a0 54 LDY #&54 &4531 4c 4b 40 JMP &404b ; write_null_terminated_string ; wait_for_f1 &4534 a5 ec LDA &ec ; os_most_recently_pressed_key &4536 c9 f1 CMP #&f1 ; f1 &4538 d0 fa BNE &4534 ; wait_for_f1 ; leave &453a 60 RTS ; replot_enemy_and_reset_freefall &453b 20 6c 41 JSR &416c ; replot_enemy &453e a9 00 LDA #&00 &4540 85 39 STA &39 ; freefall_velocity &4542 85 02 STA &02 ; player_is_in_freefall # Set to zero to indicate not in freefall &4544 60 RTS ; unused &4545 00 &4546 8e 3d 58 00 00 &454b 55 65 72 74 00 ; "Uert" &4550 8e 3d a4 00 00 &4555 99 6d 63 64 61 74 61 00 ; "mcdata" &455d 00 8e a8 00 00 &4562 6f 65 6f 75 74 32 35 00 ; "oeout25" &456a 00 8e d4 00 00 &456f b0 65 6f 75 74 38 00 ; "eout8" &4576 00 8e 48 00 00 &457b d6 65 6f 64 38 00 ; "eod8" &4581 00 8e 88 00 00 &4586 8f 65 38 00 ; "e8" &458a 00 8e 10 00 00 &458f 14 66 32 35 00 ; "f25" &4594 00 8e 10 00 00 &4599 e4 65 72 38 ; "er8" &459d 00 8e 3f ; room_data ; room_00_data &45a0 08 f4 00 81 ; platform at x:&00, y:&f4, length &81 &45a4 56 18 ; shape at x:&18, type &16 &45a6 19 e8 ; fill at y:&e8, pattern &9 &45a8 52 44 ; shape at x:&44, type &12 &45aa 1a f0 ; fill at y:&f0, pattern &a &45ac 4a 74 ; shape at x:&74, type &0a &45ae 1f f0 ; fill at y:&f0, pattern &f &45b0 50 be 42 ; shape at x:&3e, y:&42, type &10 &45b3 08 bc 00 6d ; platform at x:&00, y:&bc, length &6d &45b7 4c 5e ; shape at x:&5e, type &0c &45b9 1e b4 ; fill at y:&b4, pattern &e &45bb 44 3e ; shape at x:&3e, type &04 &45bd 10 a6 ; fill at y:&a6, pattern &0 &45bf 1d 70 ; fill at y:&70, pattern &d &45c1 59 24 ; shape at x:&24, type &19 &45c3 11 a6 ; fill at y:&a6, pattern &1 &45c5 44 0d ; shape at x:&0d, type &04 &45c7 12 aa ; fill at y:&aa, pattern &2 &45c9 1d 70 ; fill at y:&70, pattern &d &45cb 45 a3 8d ; shape at x:&23, y:&8d, type &05 &45ce 14 82 ; fill at y:&82, pattern &4 &45d0 1d 70 ; fill at y:&70, pattern &d &45d2 61 e2 73 ; shape at x:&62, y:&73, type &21 &45d5 15 70 ; fill at y:&70, pattern &5 &45d7 08 60 6e 13 ; platform at x:&6e, y:&60, length &13 &45db 61 7d ; shape at x:&7d, type &21 &45dd 15 5c ; fill at y:&5c, pattern &5 &45df 13 fa ; fill at y:&fa, pattern &3 &45e1 04 24 d1 ; red pill at x:&24, y:&d1 &45e4 06 80 57 ; other pill at x:&80, y:&57 &45e7 23 0c 5e ; object at x:&0c, y:&5e, type &03 &45ea 08 3e 04 20 ; platform at x:&04, y:&3e, length &20 &45ee 46 16 ; shape at x:&16, type &06 &45f0 18 3a ; fill at y:&3a, pattern &8 &45f2 03 ; use common update routine &45f3 00 ; end of data ; room_01_data &45f4 08 f4 00 81 ; platform at x:&00, y:&f4, length &81 &45f8 42 09 ; shape at x:&09, type &02 &45fa 16 f0 ; fill at y:&f0, pattern &6 &45fc 40 2f ; shape at x:&2f, type &00 &45fe 1a c8 ; fill at y:&c8, pattern &a &4600 4a 50 ; shape at x:&50, type &0a &4602 1c f0 ; fill at y:&f0, pattern &c &4604 44 6c ; shape at x:&6c, type &04 &4606 1e f0 ; fill at y:&f0, pattern &e &4608 51 ec 9d ; shape at x:&6c, y:&9d, type &11 &460b 15 99 ; fill at y:&99, pattern &5 &460d 55 e4 8f ; shape at x:&64, y:&8f, type &15 &4610 19 87 ; fill at y:&87, pattern &9 &4612 08 60 00 28 ; platform at x:&00, y:&60, length &28 &4616 42 0c ; shape at x:&0c, type &02 &4618 11 5a ; fill at y:&5a, pattern &1 &461a 65 1f ; shape at x:&1f, type &25 &461c 11 5a ; fill at y:&5a, pattern &1 &461e 04 18 15 ; red pill at x:&18, y:&15 &4621 69 f9 90 ; shape at x:&79, y:&90, type &29 &4624 1a 89 ; fill at y:&89, pattern &a &4626 4f fd ac ; shape at x:&7d, y:&ac, type &0f &4629 13 fa ; fill at y:&fa, pattern &3 &462b 08 4a 4c 34 ; platform at x:&4c, y:&4a, length &34 &462f 41 59 ; shape at x:&59, type &01 &4631 14 46 ; fill at y:&46, pattern &4 &4633 41 73 ; shape at x:&73, type &01 &4635 18 46 ; fill at y:&46, pattern &8 &4637 03 ; use common update routine &4638 00 ; end of data ; room_02_data &4639 08 f4 00 40 ; platform at x:&00, y:&f4, length &40 &463d 08 f4 40 41 ; platform at x:&40, y:&f4, length &41 &4641 6c 11 ; shape at x:&11, type &2c &4643 10 f0 ; fill at y:&f0, pattern &0 &4645 55 28 ; shape at x:&28, type &15 &4647 15 ed ; fill at y:&ed, pattern &5 &4649 6b 38 ; shape at x:&38, type &2b &464b 1e f0 ; fill at y:&f0, pattern &e &464d 43 6f ; shape at x:&6f, type &03 &464f 1f ed ; fill at y:&ed, pattern &f &4651 53 4f ; shape at x:&4f, type &13 &4653 17 ed ; fill at y:&ed, pattern &7 &4655 18 d2 ; fill at y:&d2, pattern &8 &4657 4f c1 1d ; shape at x:&41, y:&1d, type &0f &465a 08 8c 11 64 ; platform at x:&11, y:&8c, length &64 &465e 4c 3e ; shape at x:&3e, type &0c &4660 12 6e ; fill at y:&6e, pattern &2 &4662 4c 1c ; shape at x:&1c, type &0c &4664 14 88 ; fill at y:&88, pattern &4 &4666 61 54 ; shape at x:&54, type &21 &4668 1a 8a ; fill at y:&8a, pattern &a &466a 5e 6e ; shape at x:&6e, type &1e &466c 16 87 ; fill at y:&87, pattern &6 &466e 61 d5 7d ; shape at x:&55, y:&7d, type &21 &4671 18 7a ; fill at y:&7a, pattern &8 &4673 4b b8 43 ; shape at x:&38, y:&43, type &0b &4676 1a 40 ; fill at y:&40, pattern &a &4678 69 f4 6e ; shape at x:&74, y:&6e, type &29 &467b 1d 69 ; fill at y:&69, pattern &d &467d 08 38 56 28 ; platform at x:&56, y:&38, length &28 &4681 46 6a ; shape at x:&6a, type &06 &4683 19 32 ; fill at y:&32, pattern &9 &4685 04 78 b3 ; red pill at x:&78, y:&b3 &4688 24 1c 3c ; object at x:&1c, y:&3c, type &04 &468b 02 6e 35 0b ; use custom update routine &356e (update_flashbulbs) &468f 02 07 00 28 28 e4 00 40 00 f2 18 98 ; room variables &98 &18 &f2 &00 &40 &00 &e4 &28 &28 &00 &07 &02 &469b 00 ; end of data ; room_03_data &469c 08 f4 00 41 ; platform at x:&00, y:&f4, length &41 &46a0 08 f4 41 40 ; platform at x:&41, y:&f4, length &40 &46a4 62 64 ; shape at x:&64, type &22 &46a6 10 f0 ; fill at y:&f0, pattern &0 &46a8 15 cc ; fill at y:&cc, pattern &5 &46aa 6e 10 ; shape at x:&10, type &2e &46ac 11 f0 ; fill at y:&f0, pattern &1 &46ae 6e 1c ; shape at x:&1c, type &2e &46b0 12 f0 ; fill at y:&f0, pattern &2 &46b2 6e 28 ; shape at x:&28, type &2e &46b4 1c f0 ; fill at y:&f0, pattern &c &46b6 6e 34 ; shape at x:&34, type &2e &46b8 15 f0 ; fill at y:&f0, pattern &5 &46ba 6e 40 ; shape at x:&40, type &2e &46bc 19 f0 ; fill at y:&f0, pattern &9 &46be 08 38 1c 58 ; platform at x:&1c, y:&38, length &58 &46c2 52 36 ; shape at x:&36, type &12 &46c4 19 32 ; fill at y:&32, pattern &9 &46c6 46 58 ; shape at x:&58, type &06 &46c8 11 32 ; fill at y:&32, pattern &1 &46ca 08 7a 22 3f ; platform at x:&22, y:&7a, length &3f &46ce 6a 27 ; shape at x:&27, type &2a &46d0 1a 78 ; fill at y:&78, pattern &a &46d2 6d 37 ; shape at x:&37, type &2d &46d4 10 78 ; fill at y:&78, pattern &0 &46d6 5b 46 ; shape at x:&46, type &1b &46d8 1e 78 ; fill at y:&78, pattern &e &46da 55 58 ; shape at x:&58, type &15 &46dc 15 74 ; fill at y:&74, pattern &5 &46de 08 a4 02 22 ; platform at x:&02, y:&a4, length &22 &46e2 4c 0e ; shape at x:&0e, type &0c &46e4 18 96 ; fill at y:&96, pattern &8 &46e6 04 30 9b ; red pill at x:&30, y:&9b &46e9 06 80 2f ; other pill at x:&80, y:&2f &46ec 02 13 2c 0b ; use custom update routine &2c13 (update_lipstick_missiles) &46f0 02 12 00 00 00 70 00 01 ff 94 c8 4c ; room variables &4c &c8 &94 &ff &01 &00 &70 &00 &00 &00 &12 &02 &46fc 00 ; end of data ; room_04_data &46fd 08 60 72 0e ; platform at x:&72, y:&60, length &0e &4701 6e 78 ; shape at x:&78, type &2e &4703 15 5a ; fill at y:&5a, pattern &5 &4705 08 f4 00 41 ; platform at x:&00, y:&f4, length &41 &4709 08 f4 41 40 ; platform at x:&41, y:&f4, length &40 &470d 52 1b ; shape at x:&1b, type &12 &470f 14 f0 ; fill at y:&f0, pattern &4 &4711 43 4e ; shape at x:&4e, type &03 &4713 18 f0 ; fill at y:&f0, pattern &8 &4715 5e 76 ; shape at x:&76, type &1e &4717 1f d8 ; fill at y:&d8, pattern &f &4719 6f 65 ; shape at x:&65, type &2f &471b 1a f1 ; fill at y:&f1, pattern &a &471d 65 77 ; shape at x:&77, type &25 &471f 1c f0 ; fill at y:&f0, pattern &c &4721 6a e3 ed ; shape at x:&63, y:&ed, type &2a &4724 12 e6 ; fill at y:&e6, pattern &2 &4726 60 ef d5 ; shape at x:&6f, y:&d5, type &20 &4729 18 96 ; fill at y:&96, pattern &8 &472b 18 c8 ; fill at y:&c8, pattern &8 &472d 5f f5 d2 ; shape at x:&75, y:&d2, type &1f &4730 5f f5 ce ; shape at x:&75, y:&ce, type &1f &4733 5f f5 ca ; shape at x:&75, y:&ca, type &1f &4736 5f f5 c6 ; shape at x:&75, y:&c6, type &1f &4739 5f f5 c2 ; shape at x:&75, y:&c2, type &1f &473c 08 68 26 1e ; platform at x:&26, y:&68, length &1e &4740 4e 2e ; shape at x:&2e, type &0e &4742 10 64 ; fill at y:&64, pattern &0 &4744 6a 3f ; shape at x:&3f, type &2a &4746 11 64 ; fill at y:&64, pattern &1 &4748 09 38 ; short platform at y:&38 &474a 57 09 ; shape at x:&09, type &17 &474c 19 32 ; fill at y:&32, pattern &9 &474e 08 bc 02 2e ; platform at x:&02, y:&bc, length &2e &4752 40 1b ; shape at x:&1b, type &00 &4754 1c b4 ; fill at y:&b4, pattern &c &4756 40 4f ; shape at x:&4f, type &00 &4758 1a b4 ; fill at y:&b4, pattern &a &475a 04 3c b3 ; red pill at x:&3c, y:&b3 &475d 03 ; use common update routine &475e 00 ; end of data ; room_05_data &475f 08 f4 00 41 ; platform at x:&00, y:&f4, length &41 &4763 08 f4 41 40 ; platform at x:&41, y:&f4, length &40 &4767 62 18 ; shape at x:&18, type &22 &4769 1e f0 ; fill at y:&f0, pattern &e &476b 53 3a ; shape at x:&3a, type &13 &476d 1a f0 ; fill at y:&f0, pattern &a &476f 18 d0 ; fill at y:&d0, pattern &8 &4771 47 5f ; shape at x:&5f, type &07 &4773 1f f0 ; fill at y:&f0, pattern &f &4775 47 e5 e5 ; shape at x:&65, y:&e5, type &07 &4778 12 e0 ; fill at y:&e0, pattern &2 &477a 51 de d7 ; shape at x:&5e, y:&d7, type &11 &477d 19 d5 ; fill at y:&d5, pattern &9 &477f 6f 90 c7 ; shape at x:&10, y:&c7, type &2f &4782 1c c4 ; fill at y:&c4, pattern &c &4784 41 bb cd ; shape at x:&3b, y:&cd, type &01 &4787 1d c8 ; fill at y:&c8, pattern &d &4789 08 88 55 2c ; platform at x:&55, y:&88, length &2c &478d 4a 63 ; shape at x:&63, type &0a &478f 14 82 ; fill at y:&82, pattern &4 &4791 6f 76 ; shape at x:&76, type &2f &4793 1c 85 ; fill at y:&85, pattern &c &4795 25 6e 7a ; object at x:&6e, y:&7a, type &05 &4798 09 3e ; short platform at y:&3e &479a 68 95 93 ; shape at x:&15, y:&93, type &28 &479d 08 3e 1b 3e ; platform at x:&1b, y:&3e, length &3e &47a1 6d 30 ; shape at x:&30, type &2d &47a3 18 3c ; fill at y:&3c, pattern &8 &47a5 74 3e ; shape at x:&3e, type &34 &47a7 14 3c ; fill at y:&3c, pattern &4 &47a9 5b 4f ; shape at x:&4f, type &1b &47ab 17 3c ; fill at y:&3c, pattern &7 &47ad 04 73 47 ; red pill at x:&73, y:&47 &47b0 02 6e 35 0b ; use custom update routine &356e (update_flashbulbs) &47b4 02 07 00 50 50 e4 00 80 00 f2 6c 98 ; room variables &98 &6c &f2 &00 &80 &00 &e4 &50 &50 &00 &07 &02 &47c0 00 ; end of data ; room_06_data &47c1 08 f4 00 81 ; platform at x:&00, y:&f4, length &81 &47c5 77 5e ; shape at x:&5e, type &37 &47c7 10 f0 ; fill at y:&f0, pattern &0 &47c9 42 3b ; shape at x:&3b, type &02 &47cb 15 f0 ; fill at y:&f0, pattern &5 &47cd 44 1c ; shape at x:&1c, type &04 &47cf 1c e6 ; fill at y:&e6, pattern &c &47d1 57 79 ; shape at x:&79, type &17 &47d3 1a ea ; fill at y:&ea, pattern &a &47d5 1b f2 ; fill at y:&f2, pattern &b &47d7 08 78 3c 45 ; platform at x:&3c, y:&78, length &45 &47db 61 7d ; shape at x:&7d, type &21 &47dd 18 74 ; fill at y:&74, pattern &8 &47df 13 f8 ; fill at y:&f8, pattern &3 &47e1 76 63 ; shape at x:&63, type &36 &47e3 12 74 ; fill at y:&74, pattern &2 &47e5 55 48 ; shape at x:&48, type &15 &47e7 19 70 ; fill at y:&70, pattern &9 &47e9 08 44 0a 3c ; platform at x:&0a, y:&44, length &3c &47ed 56 1e ; shape at x:&1e, type &16 &47ef 1d 3c ; fill at y:&3c, pattern &d &47f1 6d 40 ; shape at x:&40, type &2d &47f3 18 40 ; fill at y:&40, pattern &8 &47f5 04 49 a9 ; red pill at x:&49, y:&a9 &47f8 06 60 6f ; other pill at x:&60, y:&6f &47fb 03 ; use common update routine &47fc 00 ; end of data ; room_07_data &47fd 08 f4 00 81 ; platform at x:&00, y:&f4, length &81 &4801 47 1d ; shape at x:&1d, type &07 &4803 1e f0 ; fill at y:&f0, pattern &e &4805 64 53 ; shape at x:&53, type &24 &4807 1c f0 ; fill at y:&f0, pattern &c &4809 45 63 ; shape at x:&63, type &05 &480b 1e f0 ; fill at y:&f0, pattern &e &480d 15 d2 ; fill at y:&d2, pattern &5 &480f 4e 76 ; shape at x:&76, type &0e &4811 17 f0 ; fill at y:&f0, pattern &7 &4813 70 c4 e5 ; shape at x:&44, y:&e5, type &30 &4816 1a e1 ; fill at y:&e1, pattern &a &4818 6b f6 c7 ; shape at x:&76, y:&c7, type &2b &481b 14 c0 ; fill at y:&c0, pattern &4 &481d 08 9a 2a 5a ; platform at x:&2a, y:&9a, length &5a &4821 4b 7e ; shape at x:&7e, type &0b &4823 15 96 ; fill at y:&96, pattern &5 &4825 13 f7 ; fill at y:&f7, pattern &3 &4827 5b 34 ; shape at x:&34, type &1b &4829 16 96 ; fill at y:&96, pattern &6 &482b 61 42 ; shape at x:&42, type &21 &482d 11 96 ; fill at y:&96, pattern &1 &482f 46 56 ; shape at x:&56, type &06 &4831 1f 96 ; fill at y:&96, pattern &f &4833 65 6b ; shape at x:&6b, type &25 &4835 1c 96 ; fill at y:&96, pattern &c &4837 4b 92 e5 ; shape at x:&12, y:&e5, type &0b &483a 14 e1 ; fill at y:&e1, pattern &4 &483c 4b a4 e5 ; shape at x:&24, y:&e5, type &0b &483f 14 e1 ; fill at y:&e1, pattern &4 &4841 44 9a db ; shape at x:&1a, y:&db, type &04 &4844 1d c8 ; fill at y:&c8, pattern &d &4846 09 78 ; short platform at y:&78 &4848 6a 07 ; shape at x:&07, type &2a &484a 1c 75 ; fill at y:&75, pattern &c &484c 04 8d 87 ; red pill at x:&8d, y:&87 &484f 06 65 79 ; other pill at x:&65, y:&79 &4852 08 40 14 64 ; platform at x:&14, y:&40, length &64 &4856 6c 2d ; shape at x:&2d, type &2c &4858 19 37 ; fill at y:&37, pattern &9 &485a 6c 54 ; shape at x:&54, type &2c &485c 18 37 ; fill at y:&37, pattern &8 &485e 58 86 0a ; shape at x:&06, y:&0a, type &18 &4861 58 f6 18 ; shape at x:&76, y:&18, type &18 &4864 35 16 81 ; object at x:&16, y:&81, type &15 &4867 03 ; use common update routine &4868 00 ; end of data ; room_08_data &4869 08 38 09 5c ; platform at x:&09, y:&38, length &5c &486d 62 28 ; shape at x:&28, type &22 &486f 1f 32 ; fill at y:&32, pattern &f &4871 18 18 ; fill at y:&18, pattern &8 &4873 5e 4c ; shape at x:&4c, type &1e &4875 1e 32 ; fill at y:&32, pattern &e &4877 66 89 22 ; shape at x:&09, y:&22, type &26 &487a 67 89 17 ; shape at x:&09, y:&17, type &27 &487d 08 be 3e 37 ; platform at x:&3e, y:&be, length &37 &4881 42 49 ; shape at x:&49, type &02 &4883 17 b4 ; fill at y:&b4, pattern &7 &4885 40 6e ; shape at x:&6e, type &00 &4887 12 b4 ; fill at y:&b4, pattern &2 &4889 04 64 b5 ; red pill at x:&64, y:&b5 &488c 08 f0 00 3d ; platform at x:&00, y:&f0, length &3d &4890 53 00 ; shape at x:&00, type &13 &4892 1d ee ; fill at y:&ee, pattern &d &4894 14 d0 ; fill at y:&d0, pattern &4 &4896 57 14 ; shape at x:&14, type &17 &4898 11 ee ; fill at y:&ee, pattern &1 &489a 10 e4 ; fill at y:&e4, pattern &0 &489c 65 23 ; shape at x:&23, type &25 &489e 1c ec ; fill at y:&ec, pattern &c &48a0 6a 2f ; shape at x:&2f, type &2a &48a2 1a e6 ; fill at y:&e6, pattern &a &48a4 65 a3 df ; shape at x:&23, y:&df, type &25 &48a7 1c dc ; fill at y:&dc, pattern &c &48a9 69 bb f0 ; shape at x:&3b, y:&f0, type &29 &48ac 14 ef ; fill at y:&ef, pattern &4 &48ae 14 e6 ; fill at y:&e6, pattern &4 &48b0 58 be ff ; shape at x:&3e, y:&ff, type &18 &48b3 02 92 2f 00 ; use custom update routine &2f92 (update_thread) &48b7 01 ; room variables &01 &48b8 00 ; end of data ; room_09_data &48b9 08 54 00 81 ; platform at x:&00, y:&54, length &81 &48bd 65 07 ; shape at x:&07, type &25 &48bf 1c 50 ; fill at y:&50, pattern &c &48c1 56 23 ; shape at x:&23, type &16 &48c3 1a 48 ; fill at y:&48, pattern &a &48c5 12 52 ; fill at y:&52, pattern &2 &48c7 5b 41 ; shape at x:&41, type &1b &48c9 1d 50 ; fill at y:&50, pattern &d &48cb 52 5a ; shape at x:&5a, type &12 &48cd 18 50 ; fill at y:&50, pattern &8 &48cf 45 70 ; shape at x:&70, type &05 &48d1 11 50 ; fill at y:&50, pattern &1 &48d3 4b dd 3f ; shape at x:&5d, y:&3f, type &0b &48d6 15 3c ; fill at y:&3c, pattern &5 &48d8 08 f0 28 59 ; platform at x:&28, y:&f0, length &59 &48dc 5a 30 ; shape at x:&30, type &1a &48de 12 ec ; fill at y:&ec, pattern &2 &48e0 6a 3f ; shape at x:&3f, type &2a &48e2 1c ec ; fill at y:&ec, pattern &c &48e4 15 c6 ; fill at y:&c6, pattern &5 &48e6 61 7d ; shape at x:&7d, type &21 &48e8 10 ec ; fill at y:&ec, pattern &0 &48ea 13 58 ; fill at y:&58, pattern &3 &48ec 4a 4d ; shape at x:&4d, type &0a &48ee 1d ee ; fill at y:&ee, pattern &d &48f0 43 65 ; shape at x:&65, type &03 &48f2 17 ec ; fill at y:&ec, pattern &7 &48f4 15 bc ; fill at y:&bc, pattern &5 &48f6 64 e7 b7 ; shape at x:&67, y:&b7, type &24 &48f9 1c b4 ; fill at y:&b4, pattern &c &48fb 04 1c 67 ; red pill at x:&1c, y:&67 &48fe 08 e2 08 1b ; platform at x:&08, y:&e2, length &1b &4902 55 1f ; shape at x:&1f, type &15 &4904 14 da ; fill at y:&da, pattern &4 &4906 6b 10 ; shape at x:&10, type &2b &4908 10 de ; fill at y:&de, pattern &0 &490a 08 9c 00 5c ; platform at x:&00, y:&9c, length &5c &490e 4e 10 ; shape at x:&10, type &0e &4910 19 96 ; fill at y:&96, pattern &9 &4912 47 31 ; shape at x:&31, type &07 &4914 11 96 ; fill at y:&96, pattern &1 &4916 02 86 2b 00 ; use custom update routine &2b86 (update_iron_pills_left) &491a 32 ; room variables &32 &491b 00 ; end of data ; room_0a_data &491c 08 f0 00 41 ; platform at x:&00, y:&f0, length &41 &4920 08 f0 48 39 ; platform at x:&48, y:&f0, length &39 &4924 46 0a ; shape at x:&0a, type &06 &4926 19 ec ; fill at y:&ec, pattern &9 &4928 17 de ; fill at y:&de, pattern &7 &492a 55 64 ; shape at x:&64, type &15 &492c 10 e8 ; fill at y:&e8, pattern &0 &492e 42 76 ; shape at x:&76, type &02 &4930 1e e6 ; fill at y:&e6, pattern &e &4932 6c c8 f0 ; shape at x:&48, y:&f0, type &2c &4935 1a ea ; fill at y:&ea, pattern &a &4937 3d 42 dc ; object at x:&42, y:&dc, type &1d &493a 54 c1 fe ; shape at x:&41, y:&fe, type &14 &493d 08 32 01 50 ; platform at x:&01, y:&32, length &50 &4941 4e 12 ; shape at x:&12, type &0e &4943 19 2d ; fill at y:&2d, pattern &9 &4945 16 09 ; fill at y:&09, pattern &6 &4947 4e 26 ; shape at x:&26, type &0e &4949 18 2d ; fill at y:&2d, pattern &8 &494b 16 09 ; fill at y:&09, pattern &6 &494d 4d 43 ; shape at x:&43, type &0d &494f 1f 2d ; fill at y:&2d, pattern &f &4951 16 09 ; fill at y:&09, pattern &6 &4953 08 64 69 18 ; platform at x:&69, y:&64, length &18 &4957 5e 6f ; shape at x:&6f, type &1e &4959 1c 5f ; fill at y:&5f, pattern &c &495b 51 ee 45 ; shape at x:&6e, y:&45, type &11 &495e 14 41 ; fill at y:&41, pattern &4 &4960 50 e6 8d ; shape at x:&66, y:&8d, type &10 &4963 08 c8 18 1c ; platform at x:&18, y:&c8, length &1c &4967 59 28 ; shape at x:&28, type &19 &4969 11 c3 ; fill at y:&c3, pattern &1 &496b 6a a7 99 ; shape at x:&27, y:&99, type &2a &496e 1a 96 ; fill at y:&96, pattern &a &4970 10 6c ; fill at y:&6c, pattern &0 &4972 04 40 bf ; red pill at x:&40, y:&bf &4975 06 76 d9 ; other pill at x:&76, y:&d9 &4978 02 00 2b 0b ; use custom update routine &2b00 (update_iron_pills_right) &497c 02 07 54 38 1c 00 62 46 2a 0e dc 4a ; room variables &4a &dc &0e &2a &46 &62 &00 &1c &38 &54 &07 &02 &4988 00 ; end of data ; room_0b_data &4989 61 a6 c1 ; shape at x:&26, y:&c1, type &21 &498c 12 be ; fill at y:&be, pattern &2 &498e 08 f0 00 81 ; platform at x:&00, y:&f0, length &81 &4992 71 61 ; shape at x:&61, type &31 &4994 4b 4f ; shape at x:&4f, type &0b &4996 1b ec ; fill at y:&ec, pattern &b &4998 65 3f ; shape at x:&3f, type &25 &499a 1c ec ; fill at y:&ec, pattern &c &499c 59 26 ; shape at x:&26, type &19 &499e 10 e6 ; fill at y:&e6, pattern &0 &49a0 6d 33 ; shape at x:&33, type &2d &49a2 11 e6 ; fill at y:&e6, pattern &1 &49a4 5d 16 ; shape at x:&16, type &1d &49a6 18 e6 ; fill at y:&e6, pattern &8 &49a8 64 bf df ; shape at x:&3f, y:&df, type &24 &49ab 1c dc ; fill at y:&dc, pattern &c &49ad 55 a9 a9 ; shape at x:&29, y:&a9, type &15 &49b0 15 a2 ; fill at y:&a2, pattern &5 &49b2 67 e1 d6 ; shape at x:&61, y:&d6, type &27 &49b5 1a df ; fill at y:&df, pattern &a &49b7 70 fb e3 ; shape at x:&7b, y:&e3, type &30 &49ba 1c e1 ; fill at y:&e1, pattern &c &49bc 08 64 00 81 ; platform at x:&00, y:&64, length &81 &49c0 42 10 ; shape at x:&10, type &02 &49c2 16 61 ; fill at y:&61, pattern &6 &49c4 44 2f ; shape at x:&2f, type &04 &49c6 1e 61 ; fill at y:&61, pattern &e &49c8 42 4c ; shape at x:&4c, type &02 &49ca 1d 61 ; fill at y:&61, pattern &d &49cc 5e 64 ; shape at x:&64, type &1e &49ce 19 61 ; fill at y:&61, pattern &9 &49d0 4b 7d ; shape at x:&7d, type &0b &49d2 14 62 ; fill at y:&62, pattern &4 &49d4 13 67 ; fill at y:&67, pattern &3 &49d6 13 f3 ; fill at y:&f3, pattern &3 &49d8 04 18 a1 ; red pill at x:&18, y:&a1 &49db 31 56 d0 ; object at x:&56, y:&d0, type &11 &49de 02 3a 2d 00 ; use custom update routine &2d3a (update_gas_tap) &49e2 01 ; room variables &01 &49e3 00 ; end of data ; room_0c_data &49e4 08 f0 00 69 ; platform at x:&00, y:&f0, length &69 &49e8 73 49 ; shape at x:&49, type &33 &49ea 12 ec ; fill at y:&ec, pattern &2 &49ec 08 f4 70 11 ; platform at x:&70, y:&f4, length &11 &49f0 69 f4 f4 ; shape at x:&74, y:&f4, type &29 &49f3 1a ee ; fill at y:&ee, pattern &a &49f5 6e c9 e2 ; shape at x:&49, y:&e2, type &2e &49f8 14 ce ; fill at y:&ce, pattern &4 &49fa 74 c9 c9 ; shape at x:&49, y:&c9, type &34 &49fd 70 86 e3 ; shape at x:&06, y:&e3, type &30 &4a00 1c de ; fill at y:&de, pattern &c &4a02 70 b0 e3 ; shape at x:&30, y:&e3, type &30 &4a05 1c de ; fill at y:&de, pattern &c &4a07 08 64 00 37 ; platform at x:&00, y:&64, length &37 &4a0b 51 14 ; shape at x:&14, type &11 &4a0d 16 60 ; fill at y:&60, pattern &6 &4a0f 42 2e ; shape at x:&2e, type &02 &4a11 18 5a ; fill at y:&5a, pattern &8 &4a13 08 82 55 28 ; platform at x:&55, y:&82, length &28 &4a17 6f 6e ; shape at x:&6e, type &2f &4a19 1c 80 ; fill at y:&80, pattern &c &4a1b 6b 5e ; shape at x:&5e, type &2b &4a1d 1f 7e ; fill at y:&7e, pattern &f &4a1f 6d ed 7b ; shape at x:&6d, y:&7b, type &2d &4a22 1a 78 ; fill at y:&78, pattern &a &4a24 08 be 0e 24 ; platform at x:&0e, y:&be, length &24 &4a28 5e 28 ; shape at x:&28, type &1e &4a2a 19 b4 ; fill at y:&b4, pattern &9 &4a2c 4a 14 ; shape at x:&14, type &0a &4a2e 1d b4 ; fill at y:&b4, pattern &d &4a30 04 3c 97 ; red pill at x:&3c, y:&97 &4a33 06 1a 4d ; other pill at x:&1a, y:&4d &4a36 50 e0 28 ; shape at x:&60, y:&28, type &10 &4a39 02 31 2e 00 ; use custom update routine &2e31 (update_flame) &4a3d 60 ; room variables &60 &4a3e 00 ; end of data ; room_0d_data &4a3f 08 f4 00 54 ; platform at x:&00, y:&f4, length &54 &4a43 42 35 ; shape at x:&35, type &02 &4a45 12 f0 ; fill at y:&f0, pattern &2 &4a47 4c 50 ; shape at x:&50, type &0c &4a49 10 f0 ; fill at y:&f0, pattern &0 &4a4b 12 ad ; fill at y:&ad, pattern &2 &4a4d 47 15 ; shape at x:&15, type &07 &4a4f 19 f0 ; fill at y:&f0, pattern &9 &4a51 5b 90 e5 ; shape at x:&10, y:&e5, type &1b &4a54 14 df ; fill at y:&df, pattern &4 &4a56 75 21 ; shape at x:&21, type &35 &4a58 1a dc ; fill at y:&dc, pattern &a &4a5a 6f b5 b1 ; shape at x:&35, y:&b1, type &2f &4a5d 14 ae ; fill at y:&ae, pattern &4 &4a5f 08 5a 08 6c ; platform at x:&08, y:&5a, length &6c &4a63 42 1e ; shape at x:&1e, type &02 &4a65 18 57 ; fill at y:&57, pattern &8 &4a67 42 34 ; shape at x:&34, type &02 &4a69 1e 57 ; fill at y:&57, pattern &e &4a6b 51 50 ; shape at x:&50, type &11 &4a6d 19 56 ; fill at y:&56, pattern &9 &4a6f 41 d2 4b ; shape at x:&52, y:&4b, type &01 &4a72 12 46 ; fill at y:&46, pattern &2 &4a74 3a 50 32 ; object at x:&50, y:&32, type &1a &4a77 4f 95 fd ; shape at x:&15, y:&fd, type &0f &4a7a 08 a0 5b 26 ; platform at x:&5b, y:&a0, length &26 &4a7e 45 7f ; shape at x:&7f, type &05 &4a80 1f 8c ; fill at y:&8c, pattern &f &4a82 6b 67 ; shape at x:&67, type &2b &4a84 1d 9d ; fill at y:&9d, pattern &d &4a86 61 73 ; shape at x:&73, type &21 &4a88 1b 9d ; fill at y:&9d, pattern &b &4a8a 04 44 a3 ; red pill at x:&44, y:&a3 &4a8d 68 f1 49 ; shape at x:&71, y:&49, type &28 &4a90 02 cf 2e 0b ; use custom update routine &2ecf (update_dripping_oil) &4a94 02 0d 00 00 00 b8 00 00 00 d2 a0 60 ; room variables &60 &a0 &d2 &00 &00 &00 &b8 &00 &00 &00 &0d &02 &4aa0 00 ; end of data ; room_0e_data &4aa1 08 a0 06 30 ; platform at x:&06, y:&a0, length &30 &4aa5 7a 18 ; shape at x:&18, type &3a &4aa7 10 8c ; fill at y:&8c, pattern &0 &4aa9 61 32 ; shape at x:&32, type &21 &4aab 14 9d ; fill at y:&9d, pattern &4 &4aad 7d 98 4f ; shape at x:&18, y:&4f, type &3d &4ab0 15 46 ; fill at y:&46, pattern &5 &4ab2 08 cc 3c 36 ; platform at x:&3c, y:&cc, length &36 &4ab6 43 4b ; shape at x:&4b, type &03 &4ab8 1a c5 ; fill at y:&c5, pattern &a &4aba 6a 67 ; shape at x:&67, type &2a &4abc 1d c8 ; fill at y:&c8, pattern &d &4abe 08 40 64 18 ; platform at x:&64, y:&40, length &18 &4ac2 57 6e ; shape at x:&6e, type &17 &4ac4 14 36 ; fill at y:&36, pattern &4 &4ac6 34 6c 27 ; object at x:&6c, y:&27, type &14 &4ac9 08 e2 00 3a ; platform at x:&00, y:&e2, length &3a &4acd 52 2c ; shape at x:&2c, type &12 &4acf 12 dc ; fill at y:&dc, pattern &2 &4ad1 51 0f ; shape at x:&0f, type &11 &4ad3 19 dc ; fill at y:&dc, pattern &9 &4ad5 04 76 8f ; red pill at x:&76, y:&8f &4ad8 06 20 cb ; other pill at x:&20, y:&cb &4adb 03 ; use common update routine &4adc 00 ; end of data ; room_0f_data &4add 08 ca 07 28 ; platform at x:&07, y:&ca, length &28 &4ae1 47 16 ; shape at x:&16, type &07 &4ae3 14 c3 ; fill at y:&c3, pattern &4 &4ae5 59 86 bb ; shape at x:&06, y:&bb, type &19 &4ae8 19 aa ; fill at y:&aa, pattern &9 &4aea 08 c4 5d 14 ; platform at x:&5d, y:&c4, length &14 &4aee 08 c4 7c 14 ; platform at x:&7c, y:&c4, length &14 &4af2 70 78 ; shape at x:&78, type &30 &4af4 1d c1 ; fill at y:&c1, pattern &d &4af6 6e f6 b9 ; shape at x:&76, y:&b9, type &2e &4af9 18 aa ; fill at y:&aa, pattern &8 &4afb 6d 68 ; shape at x:&68, type &2d &4afd 1a b4 ; fill at y:&b4, pattern &a &4aff 50 86 ff ; shape at x:&06, y:&ff, type &10 &4b02 50 f6 ff ; shape at x:&76, y:&ff, type &10 &4b05 08 88 68 21 ; platform at x:&68, y:&88, length &21 &4b09 4b 78 ; shape at x:&78, type &0b &4b0b 12 84 ; fill at y:&84, pattern &2 &4b0d 4b 7f ; shape at x:&7f, type &0b &4b0f 1c 84 ; fill at y:&84, pattern &c &4b11 75 6c ; shape at x:&6c, type &35 &4b13 1f 84 ; fill at y:&84, pattern &f &4b15 61 fc 7d ; shape at x:&7c, y:&7d, type &21 &4b18 15 78 ; fill at y:&78, pattern &5 &4b1a 04 28 b3 ; red pill at x:&28, y:&b3 &4b1d 08 4e 00 64 ; platform at x:&00, y:&4e, length &64 &4b21 41 0f ; shape at x:&0f, type &01 &4b23 11 46 ; fill at y:&46, pattern &1 &4b25 41 2b ; shape at x:&2b, type &01 &4b27 10 46 ; fill at y:&46, pattern &0 &4b29 41 47 ; shape at x:&47, type &01 &4b2b 17 46 ; fill at y:&46, pattern &7 &4b2d 03 ; use common update routine &4b2e 00 ; end of data ; room_10_data &4b2f 08 ea 02 49 ; platform at x:&02, y:&ea, length &49 &4b33 43 13 ; shape at x:&13, type &03 &4b35 18 e6 ; fill at y:&e6, pattern &8 &4b37 45 2f ; shape at x:&2f, type &05 &4b39 1c e6 ; fill at y:&e6, pattern &c &4b3b 10 c8 ; fill at y:&c8, pattern &0 &4b3d 5a 45 ; shape at x:&45, type &1a &4b3f 12 e6 ; fill at y:&e6, pattern &2 &4b41 08 d2 56 29 ; platform at x:&56, y:&d2, length &29 &4b45 4c 74 ; shape at x:&74, type &0c &4b47 1a cd ; fill at y:&cd, pattern &a &4b49 4e 5d ; shape at x:&5d, type &0e &4b4b 14 ce ; fill at y:&ce, pattern &4 &4b4d 57 dd a5 ; shape at x:&5d, y:&a5, type &17 &4b50 11 a3 ; fill at y:&a3, pattern &1 &4b52 15 9d ; fill at y:&9d, pattern &5 &4b54 86 ; string, length &06 &4b55 19 45 60 00 34 01 ; DRAW &0060, &0134 &4b5b 08 6a 00 29 ; platform at x:&00, y:&6a, length &29 &4b5f 5e 01 ; shape at x:&01, type &1e &4b61 1e 64 ; fill at y:&64, pattern &e &4b63 55 1a ; shape at x:&1a, type &15 &4b65 11 64 ; fill at y:&64, pattern &1 &4b67 55 99 5b ; shape at x:&19, y:&5b, type &15 &4b6a 11 56 ; fill at y:&56, pattern &1 &4b6c 58 82 18 ; shape at x:&02, y:&18, type &18 &4b6f 38 70 ae ; object at x:&70, y:&ae, type &18 &4b72 28 5d 82 ; object at x:&5d, y:&82, type &08 &4b75 08 3c 4b 36 ; platform at x:&4b, y:&3c, length &36 &4b79 08 3c 3d 0c ; platform at x:&3d, y:&3c, length &0c &4b7d 5e 5e ; shape at x:&5e, type &1e &4b7f 1c 39 ; fill at y:&39, pattern &c &4b81 46 75 ; shape at x:&75, type &06 &4b83 17 29 ; fill at y:&29, pattern &7 &4b85 59 ca 3c ; shape at x:&4a, y:&3c, type &19 &4b88 19 2f ; fill at y:&2f, pattern &9 &4b8a 50 ca 7b ; shape at x:&4a, y:&7b, type &10 &4b8d 04 24 a9 ; red pill at x:&24, y:&a9 &4b90 03 ; use common update routine &4b91 00 ; end of data ; room_11_data &4b92 08 e6 04 5c ; platform at x:&04, y:&e6, length &5c &4b96 56 1f ; shape at x:&1f, type &16 &4b98 1a e3 ; fill at y:&e3, pattern &a &4b9a 19 de ; fill at y:&de, pattern &9 &4b9c 4d 5a ; shape at x:&5a, type &0d &4b9e 15 e1 ; fill at y:&e1, pattern &5 &4ba0 18 c2 ; fill at y:&c2, pattern &8 &4ba2 51 43 ; shape at x:&43, type &11 &4ba4 12 e3 ; fill at y:&e3, pattern &2 &4ba6 46 bf d7 ; shape at x:&3f, y:&d7, type &06 &4ba9 11 d1 ; fill at y:&d1, pattern &1 &4bab 08 b0 62 1f ; platform at x:&62, y:&b0, length &1f &4baf 53 72 ; shape at x:&72, type &13 &4bb1 17 aa ; fill at y:&aa, pattern &7 &4bb3 04 82 81 ; red pill at x:&82, y:&81 &4bb6 06 4d b7 ; other pill at x:&4d, y:&b7 &4bb9 21 20 35 ; object at x:&20, y:&35, type &01 &4bbc 5d a1 81 ; shape at x:&21, y:&81, type &1d &4bbf 1c 7d ; fill at y:&7d, pattern &c &4bc1 5c a1 7d ; shape at x:&21, y:&7d, type &1c &4bc4 08 3c 00 0b ; platform at x:&00, y:&3c, length &0b &4bc8 08 3c 37 4a ; platform at x:&37, y:&3c, length &4a &4bcc 4a 51 ; shape at x:&51, type &0a &4bce 1d 39 ; fill at y:&39, pattern &d &4bd0 4a 61 ; shape at x:&61, type &0a &4bd2 1e 39 ; fill at y:&39, pattern &e &4bd4 4a 71 ; shape at x:&71, type &0a &4bd6 16 39 ; fill at y:&39, pattern &6 &4bd8 5a 07 ; shape at x:&07, type &1a &4bda 14 39 ; fill at y:&39, pattern &4 &4bdc 13 41 ; fill at y:&41, pattern &3 &4bde 4e 3b ; shape at x:&3b, type &0e &4be0 1f 39 ; fill at y:&39, pattern &f &4be2 83 ; string, length &03 &4be3 12 00 81 ; GCOL 0, 128 + 1 &4be6 08 6e 3c 24 ; platform at x:&3c, y:&6e, length &24 &4bea 46 48 ; shape at x:&48, type &06 &4bec 17 5a ; fill at y:&5a, pattern &7 &4bee 4b 59 ; shape at x:&59, type &0b &4bf0 10 6b ; fill at y:&6b, pattern &0 &4bf2 08 8e 00 1d ; platform at x:&00, y:&8e, length &1d &4bf6 02 d2 2f 03 ; use custom update routine &2fd2 (update_clock) &4bfa 0b 01 e4 80 ; room variables &80 &e4 &01 &0b &4bfe 00 ; end of data ; room_12_data &4bff 08 d2 0a 50 ; platform at x:&0a, y:&d2, length &50 &4c03 4b 17 ; shape at x:&17, type &0b &4c05 11 ce ; fill at y:&ce, pattern &1 &4c07 52 2a ; shape at x:&2a, type &12 &4c09 15 ce ; fill at y:&ce, pattern &5 &4c0b 53 4b ; shape at x:&4b, type &13 &4c0d 1c ce ; fill at y:&ce, pattern &c &4c0f 14 af ; fill at y:&af, pattern &4 &4c11 08 60 00 3b ; platform at x:&00, y:&60, length &3b &4c15 08 60 43 28 ; platform at x:&43, y:&60, length &28 &4c19 4e 23 ; shape at x:&23, type &0e &4c1b 1d 5d ; fill at y:&5d, pattern &d &4c1d 14 3e ; fill at y:&3e, pattern &4 &4c1f 45 0f ; shape at x:&0f, type &05 &4c21 1a 5d ; fill at y:&5d, pattern &a &4c23 4e 58 ; shape at x:&58, type &0e &4c25 1e 5d ; fill at y:&5d, pattern &e &4c27 14 3e ; fill at y:&3e, pattern &4 &4c29 49 bf 60 ; shape at x:&3f, y:&60, type &09 &4c2c 48 bf 97 ; shape at x:&3f, y:&97, type &08 &4c2f 08 38 6c 15 ; platform at x:&6c, y:&38, length &15 &4c33 08 94 02 1e ; platform at x:&02, y:&94, length &1e &4c37 4b 18 ; shape at x:&18, type &0b &4c39 11 91 ; fill at y:&91, pattern &1 &4c3b 04 2a 81 ; red pill at x:&2a, y:&81 &4c3e 08 a0 67 15 ; platform at x:&67, y:&a0, length &15 &4c42 4f fd ba ; shape at x:&7d, y:&ba, type &0f &4c45 5b f8 a0 ; shape at x:&78, y:&a0, type &1b &4c48 17 9c ; fill at y:&9c, pattern &7 &4c4a 20 74 83 ; object at x:&74, y:&83, type &00 &4c4d 02 6e 35 0b ; use custom update routine &356e (update_flashbulbs) &4c51 02 07 00 28 28 e4 00 40 00 f2 60 98 ; room variables &98 &60 &f2 &00 &40 &00 &e4 &28 &28 &00 &07 &02 &4c5d 00 ; end of data ; room_13_data &4c5e 08 e8 00 5a ; platform at x:&00, y:&e8, length &5a &4c62 72 45 ; shape at x:&45, type &32 &4c64 12 dc ; fill at y:&dc, pattern &2 &4c66 59 26 ; shape at x:&26, type &19 &4c68 10 e6 ; fill at y:&e6, pattern &0 &4c6a 6f 16 ; shape at x:&16, type &2f &4c6c 11 e6 ; fill at y:&e6, pattern &1 &4c6e 6b 08 ; shape at x:&08, type &2b &4c70 1c e6 ; fill at y:&e6, pattern &c &4c72 6e 33 ; shape at x:&33, type &2e &4c74 1a e6 ; fill at y:&e6, pattern &a &4c76 6d 96 e1 ; shape at x:&16, y:&e1, type &2d &4c79 14 dc ; fill at y:&dc, pattern &4 &4c7b 4b b3 cd ; shape at x:&33, y:&cd, type &0b &4c7e 15 c8 ; fill at y:&c8, pattern &5 &4c80 6e b3 c5 ; shape at x:&33, y:&c5, type &2e &4c83 1a be ; fill at y:&be, pattern &a &4c85 09 38 ; short platform at y:&38 &4c87 04 18 2f ; red pill at x:&18, y:&2f &4c8a 08 40 3c 45 ; platform at x:&3c, y:&40, length &45 &4c8e 62 52 ; shape at x:&52, type &22 &4c90 18 3c ; fill at y:&3c, pattern &8 &4c92 08 94 50 28 ; platform at x:&50, y:&94, length &28 &4c96 4e 5a ; shape at x:&5a, type &0e &4c98 1d 8c ; fill at y:&8c, pattern &d &4c9a 6e e9 94 ; shape at x:&69, y:&94, type &2e &4c9d 19 8c ; fill at y:&8c, pattern &9 &4c9f 65 db 67 ; shape at x:&5b, y:&67, type &25 &4ca2 1c 64 ; fill at y:&64, pattern &c &4ca4 4b d9 57 ; shape at x:&59, y:&57, type &0b &4ca7 14 55 ; fill at y:&55, pattern &4 &4ca9 6e e9 7b ; shape at x:&69, y:&7b, type &2e &4cac 19 73 ; fill at y:&73, pattern &9 &4cae 5f f1 90 ; shape at x:&71, y:&90, type &1f &4cb1 5f f1 8c ; shape at x:&71, y:&8c, type &1f &4cb4 5f f1 88 ; shape at x:&71, y:&88, type &1f &4cb7 5f f1 84 ; shape at x:&71, y:&84, type &1f &4cba 5f f1 80 ; shape at x:&71, y:&80, type &1f &4cbd 5f f1 7c ; shape at x:&71, y:&7c, type &1f &4cc0 5f f1 78 ; shape at x:&71, y:&78, type &1f &4cc3 5f f1 74 ; shape at x:&71, y:&74, type &1f &4cc6 5f f1 70 ; shape at x:&71, y:&70, type &1f &4cc9 5f f1 6c ; shape at x:&71, y:&6c, type &1f &4ccc 5f f1 68 ; shape at x:&71, y:&68, type &1f &4ccf 3e 3c c6 ; object at x:&3c, y:&c6, type &1e &4cd2 02 9c 2d 00 ; use custom update routine &2d9c (update_degum) &4cd6 01 ; room variables &01 &4cd7 00 ; end of data ; room_14_data &4cd8 08 50 08 4f ; platform at x:&08, y:&50, length &4f &4cdc 46 16 ; shape at x:&16, type &06 &4cde 14 4c ; fill at y:&4c, pattern &4 &4ce0 6d 3b ; shape at x:&3b, type &2d &4ce2 1d 4c ; fill at y:&4c, pattern &d &4ce4 57 2c ; shape at x:&2c, type &17 &4ce6 11 4c ; fill at y:&4c, pattern &1 &4ce8 10 46 ; fill at y:&46, pattern &0 &4cea 08 50 5e 23 ; platform at x:&5e, y:&50, length &23 &4cee 6e 79 ; shape at x:&79, type &2e &4cf0 1e 4c ; fill at y:&4c, pattern &e &4cf2 08 ba 1e 54 ; platform at x:&1e, y:&ba, length &54 &4cf6 43 44 ; shape at x:&44, type &03 &4cf8 12 b4 ; fill at y:&b4, pattern &2 &4cfa 15 89 ; fill at y:&89, pattern &5 &4cfc 41 27 ; shape at x:&27, type &01 &4cfe 1f b4 ; fill at y:&b4, pattern &f &4d00 59 60 ; shape at x:&60, type &19 &4d02 18 b4 ; fill at y:&b4, pattern &8 &4d04 50 e0 ff ; shape at x:&60, y:&ff, type &10 &4d07 09 e6 ; short platform at y:&e6 &4d09 6a 07 ; shape at x:&07, type &2a &4d0b 10 e2 ; fill at y:&e2, pattern &0 &4d0d 04 4c 79 ; red pill at x:&4c, y:&79 &4d10 02 7b 2e 05 ; use custom update routine &2e7b (update_balloon) &4d14 0a 46 0a 54 01 01 ; room variables &01 &01 &54 &0a &46 &0a &4d1a 00 ; end of data ; room_15_data &4d1b 68 f1 ff ; shape at x:&71, y:&ff, type &28 &4d1e 68 f1 6c ; shape at x:&71, y:&6c, type &28 &4d21 08 ec 00 2a ; platform at x:&00, y:&ec, length &2a &4d25 5e 20 ; shape at x:&20, type &1e &4d27 10 ea ; fill at y:&ea, pattern &0 &4d29 64 07 ; shape at x:&07, type &24 &4d2b 1c ea ; fill at y:&ea, pattern &c &4d2d 22 20 c6 ; object at x:&20, y:&c6, type &02 &4d30 08 b6 00 6a ; platform at x:&00, y:&b6, length &6a &4d34 76 57 ; shape at x:&57, type &36 &4d36 1a b4 ; fill at y:&b4, pattern &a &4d38 14 9a ; fill at y:&9a, pattern &4 &4d3a 46 3e ; shape at x:&3e, type &06 &4d3c 12 b4 ; fill at y:&b4, pattern &2 &4d3e 4a 25 ; shape at x:&25, type &0a &4d40 11 b4 ; fill at y:&b4, pattern &1 &4d42 76 0b ; shape at x:&0b, type &36 &4d44 1e b4 ; fill at y:&b4, pattern &e &4d46 14 9a ; fill at y:&9a, pattern &4 &4d48 08 50 00 30 ; platform at x:&00, y:&50, length &30 &4d4c 4e 0b ; shape at x:&0b, type &0e &4d4e 18 4e ; fill at y:&4e, pattern &8 &4d50 4e 1f ; shape at x:&1f, type &0e &4d52 19 4e ; fill at y:&4e, pattern &9 &4d54 04 36 75 ; red pill at x:&36, y:&75 &4d57 06 3c 47 ; other pill at x:&3c, y:&47 &4d5a 03 ; use common update routine &4d5b 00 ; end of data ; room_16_data &4d5c 08 ec 00 37 ; platform at x:&00, y:&ec, length &37 &4d60 5e 31 ; shape at x:&31, type &1e &4d62 10 e6 ; fill at y:&e6, pattern &0 &4d64 5a 15 ; shape at x:&15, type &1a &4d66 1c e6 ; fill at y:&e6, pattern &c &4d68 4b 23 ; shape at x:&23, type &0b &4d6a 13 e8 ; fill at y:&e8, pattern &3 &4d6c 6e 04 ; shape at x:&04, type &2e &4d6e 11 dc ; fill at y:&dc, pattern &1 &4d70 74 84 d1 ; shape at x:&04, y:&d1, type &34 &4d73 13 9f ; fill at y:&9f, pattern &3 &4d75 04 43 c5 ; red pill at x:&43, y:&c5 &4d78 06 37 c5 ; other pill at x:&37, y:&c5 &4d7b 08 4e 14 50 ; platform at x:&14, y:&4e, length &50 &4d7f 6f 1a ; shape at x:&1a, type &2f &4d81 15 4b ; fill at y:&4b, pattern &5 &4d83 6b 2d ; shape at x:&2d, type &2b &4d85 1a 48 ; fill at y:&48, pattern &a &4d87 65 4b ; shape at x:&4b, type &25 &4d89 1c 48 ; fill at y:&48, pattern &c &4d8b 5b 5a ; shape at x:&5a, type &1b &4d8d 16 48 ; fill at y:&48, pattern &6 &4d8f 58 c2 18 ; shape at x:&42, y:&18, type &18 &4d92 08 3e 6d 14 ; platform at x:&6d, y:&3e, length &14 &4d96 45 77 ; shape at x:&77, type &05 &4d98 18 3a ; fill at y:&3a, pattern &8 &4d9a 1d 1c ; fill at y:&1c, pattern &d &4d9c 08 ce 54 2d ; platform at x:&54, y:&ce, length &2d &4da0 72 5f ; shape at x:&5f, type &32 &4da2 12 c8 ; fill at y:&c8, pattern &2 &4da4 4a 79 ; shape at x:&79, type &0a &4da6 1a c8 ; fill at y:&c8, pattern &a &4da8 03 ; use common update routine &4da9 00 ; end of data ; room_17_data &4daa 08 42 16 61 ; platform at x:&16, y:&42, length &61 &4dae 5e 42 ; shape at x:&42, type &1e &4db0 12 3c ; fill at y:&3c, pattern &2 &4db2 4d 5f ; shape at x:&5f, type &0d &4db4 1a 3c ; fill at y:&3c, pattern &a &4db6 11 1b ; fill at y:&1b, pattern &1 &4db8 4b 17 ; shape at x:&17, type &0b &4dba 1f 3f ; fill at y:&3f, pattern &f &4dbc 4b 21 ; shape at x:&21, type &0b &4dbe 1f 3f ; fill at y:&3f, pattern &f &4dc0 4b 9a 37 ; shape at x:&1a, y:&37, type &0b &4dc3 1f 34 ; fill at y:&34, pattern &f &4dc5 69 f5 42 ; shape at x:&75, y:&42, type &29 &4dc8 1c 3b ; fill at y:&3b, pattern &c &4dca 68 f9 cb ; shape at x:&79, y:&cb, type &28 &4dcd 08 8e 0c 32 ; platform at x:&0c, y:&8e, length &32 &4dd1 6d 19 ; shape at x:&19, type &2d &4dd3 19 8a ; fill at y:&8a, pattern &9 &4dd5 6d 30 ; shape at x:&30, type &2d &4dd7 19 8a ; fill at y:&8a, pattern &9 &4dd9 47 a8 69 ; shape at x:&28, y:&69, type &07 &4ddc 18 64 ; fill at y:&64, pattern &8 &4dde 08 da 32 44 ; platform at x:&32, y:&da, length &44 &4de2 44 46 ; shape at x:&46, type &04 &4de4 14 c8 ; fill at y:&c8, pattern &4 &4de6 46 61 ; shape at x:&61, type &06 &4de8 1e d7 ; fill at y:&d7, pattern &e &4dea 41 e1 c1 ; shape at x:&61, y:&c1, type &01 &4ded 15 be ; fill at y:&be, pattern &5 &4def 04 98 eb ; red pill at x:&98, y:&eb &4df2 06 3d 39 ; other pill at x:&3d, y:&39 &4df5 22 31 00 ; object at x:&31, y:&00, type &02 &4df8 02 46 30 00 ; use custom update routine &3046 (update_pin) &4dfc 00 ; room variables &00 ; room_18_data &4dfd 08 ea 03 2e ; platform at x:&03, y:&ea, length &2e &4e01 08 ea 3c 45 ; platform at x:&3c, y:&ea, length &45 &4e05 52 0b ; shape at x:&0b, type &12 &4e07 1a e6 ; fill at y:&e6, pattern &a &4e09 57 20 ; shape at x:&20, type &17 &4e0b 11 e2 ; fill at y:&e2, pattern &1 &4e0d 56 3e ; shape at x:&3e, type &16 &4e0f 18 e0 ; fill at y:&e0, pattern &8 &4e11 1a e8 ; fill at y:&e8, pattern &a &4e13 5b 5d ; shape at x:&5d, type &1b &4e15 1f e6 ; fill at y:&e6, pattern &f &4e17 60 73 ; shape at x:&73, type &20 &4e19 19 e6 ; fill at y:&e6, pattern &9 &4e1b 19 be ; fill at y:&be, pattern &9 &4e1d 5f ed e6 ; shape at x:&6d, y:&e6, type &1f &4e20 5f ed e2 ; shape at x:&6d, y:&e2, type &1f &4e23 5f ed de ; shape at x:&6d, y:&de, type &1f &4e26 5f ed da ; shape at x:&6d, y:&da, type &1f &4e29 5f ed d6 ; shape at x:&6d, y:&d6, type &1f &4e2c 58 82 ff ; shape at x:&02, y:&ff, type &18 &4e2f 4d ba cf ; shape at x:&3a, y:&cf, type &0d &4e32 1e c8 ; fill at y:&c8, pattern &e &4e34 13 ad ; fill at y:&ad, pattern &3 &4e36 08 ac 04 29 ; platform at x:&04, y:&ac, length &29 &4e3a 45 28 ; shape at x:&28, type &05 &4e3c 1c aa ; fill at y:&aa, pattern &c &4e3e 16 8c ; fill at y:&8c, pattern &6 &4e40 4a 17 ; shape at x:&17, type &0a &4e42 1c aa ; fill at y:&aa, pattern &c &4e44 61 0a ; shape at x:&0a, type &21 &4e46 19 aa ; fill at y:&aa, pattern &9 &4e48 61 a4 87 ; shape at x:&24, y:&87, type &21 &4e4b 19 85 ; fill at y:&85, pattern &9 &4e4d 04 18 95 ; red pill at x:&18, y:&95 &4e50 08 90 3c 35 ; platform at x:&3c, y:&90, length &35 &4e54 62 5c ; shape at x:&5c, type &22 &4e56 1d 8c ; fill at y:&8c, pattern &d &4e58 15 6e ; fill at y:&6e, pattern &5 &4e5a 3c 50 77 ; object at x:&50, y:&77, type &1c &4e5d 4b 41 ; shape at x:&41, type &0b &4e5f 11 8c ; fill at y:&8c, pattern &1 &4e61 4b c3 85 ; shape at x:&43, y:&85, type &0b &4e64 11 82 ; fill at y:&82, pattern &1 &4e66 08 66 03 44 ; platform at x:&03, y:&66, length &44 &4e6a 44 14 ; shape at x:&14, type &04 &4e6c 1d 64 ; fill at y:&64, pattern &d &4e6e 44 34 ; shape at x:&34, type &04 &4e70 14 64 ; fill at y:&64, pattern &4 &4e72 5d fb 44 ; shape at x:&7b, y:&44, type &1d &4e75 02 f9 2e 05 ; use custom update routine &2ef9 (update_vanishing_cream) &4e79 0a 2c 64 58 00 50 ; room variables &50 &00 &58 &64 &2c &0a &4e7f 00 ; end of data ; room_19_data &4e80 09 ea ; short platform at y:&ea &4e82 5a 09 ; shape at x:&09, type &1a &4e84 14 e6 ; fill at y:&e6, pattern &4 &4e86 08 d8 18 69 ; platform at x:&18, y:&d8, length &69 &4e8a 42 50 ; shape at x:&50, type &02 &4e8c 1d c8 ; fill at y:&c8, pattern &d &4e8e 42 3e ; shape at x:&3e, type &02 &4e90 1a c8 ; fill at y:&c8, pattern &a &4e92 4a 28 ; shape at x:&28, type &0a &4e94 10 c8 ; fill at y:&c8, pattern &0 &4e96 51 6e ; shape at x:&6e, type &11 &4e98 1e d2 ; fill at y:&d2, pattern &e &4e9a 9e ; string, length &1e &4e9b 19 04 00 00 ee 02 ; MOVE &0000, &02ee &4ea1 19 05 00 04 ee 02 ; DRAW &0400, &02ee &4ea7 19 05 00 04 fc 03 ; DRAW &0400, &03fc &4ead 1f 02 05 ; TAB(&02, &05) &4eb0 44 41 52 4b 20 52 4f 4f 4d ; "DARK ROOM" &4eb9 08 66 00 40 ; platform at x:&00, y:&66, length &40 &4ebd 46 14 ; shape at x:&14, type &06 &4ebf 16 52 ; fill at y:&52, pattern &6 &4ec1 12 63 ; fill at y:&63, pattern &2 &4ec3 55 28 ; shape at x:&28, type &15 &4ec5 15 5d ; fill at y:&5d, pattern &5 &4ec7 65 37 ; shape at x:&37, type &25 &4ec9 1c 64 ; fill at y:&64, pattern &c &4ecb 08 92 5e 23 ; platform at x:&5e, y:&92, length &23 &4ecf 41 72 ; shape at x:&72, type &01 &4ed1 18 8c ; fill at y:&8c, pattern &8 &4ed3 63 db 3a ; shape at x:&5b, y:&3a, type &23 &4ed6 11 32 ; fill at y:&32, pattern &1 &4ed8 04 36 97 ; red pill at x:&36, y:&97 &4edb 06 6c 89 ; other pill at x:&6c, y:&89 &4ede 02 75 2f 00 ; use custom update routine &2f75 (update_darkroom_entrance) &4ee2 00 ; room variables &00 &4ee3 00 ; end of data ; room_1a_data &4ee4 08 d8 00 62 ; platform at x:&00, y:&d8, length &62 &4ee8 45 08 ; shape at x:&08, type &05 &4eea 15 b9 ; fill at y:&b9, pattern &5 &4eec 4e 1a ; shape at x:&1a, type &0e &4eee 12 d2 ; fill at y:&d2, pattern &2 &4ef0 4d 2e ; shape at x:&2e, type &0d &4ef2 1c d2 ; fill at y:&d2, pattern &c &4ef4 13 b4 ; fill at y:&b4, pattern &3 &4ef6 62 4c ; shape at x:&4c, type &22 &4ef8 1d d2 ; fill at y:&d2, pattern &d &4efa 1e b2 ; fill at y:&b2, pattern &e &4efc 08 a4 5e 23 ; platform at x:&5e, y:&a4, length &23 &4f00 46 68 ; shape at x:&68, type &06 &4f02 1a a0 ; fill at y:&a0, pattern &a &4f04 11 90 ; fill at y:&90, pattern &1 &4f06 64 7b ; shape at x:&7b, type &24 &4f08 12 a0 ; fill at y:&a0, pattern &2 &4f0a 08 84 0b 4d ; platform at x:&0b, y:&84, length &4d &4f0e 43 49 ; shape at x:&49, type &03 &4f10 14 82 ; fill at y:&82, pattern &4 &4f12 10 50 ; fill at y:&50, pattern &0 &4f14 65 0f ; shape at x:&0f, type &25 &4f16 12 82 ; fill at y:&82, pattern &2 &4f18 5e 20 ; shape at x:&20, type &1e &4f1a 10 82 ; fill at y:&82, pattern &0 &4f1c 4a 33 ; shape at x:&33, type &0a &4f1e 1a 82 ; fill at y:&82, pattern &a &4f20 64 8f 73 ; shape at x:&0f, y:&73, type &24 &4f23 12 6e ; fill at y:&6e, pattern &2 &4f25 64 8f 65 ; shape at x:&0f, y:&65, type &24 &4f28 12 61 ; fill at y:&61, pattern &2 &4f2a 5a a4 65 ; shape at x:&24, y:&65, type &1a &4f2d 19 62 ; fill at y:&62, pattern &9 &4f2f 04 58 43 ; red pill at x:&58, y:&43 &4f32 08 36 2c 55 ; platform at x:&2c, y:&36, length &55 &4f36 56 5a ; shape at x:&5a, type &16 &4f38 11 34 ; fill at y:&34, pattern &1 &4f3a 15 2e ; fill at y:&2e, pattern &5 &4f3c 30 64 87 ; object at x:&64, y:&87, type &10 &4f3f 08 f2 66 1b ; platform at x:&66, y:&f2, length &1b &4f43 61 6c ; shape at x:&6c, type &21 &4f45 10 f0 ; fill at y:&f0, pattern &0 &4f47 03 ; use common update routine &4f48 00 ; end of data ; room_1b_data &4f49 09 f2 ; short platform at y:&f2 &4f4b 09 36 ; short platform at y:&36 &4f4d 08 4c 38 41 ; platform at x:&38, y:&4c, length &41 &4f51 4c 54 ; shape at x:&54, type &0c &4f53 1a 46 ; fill at y:&46, pattern &a &4f55 69 f5 4c ; shape at x:&75, y:&4c, type &29 &4f58 14 46 ; fill at y:&46, pattern &4 &4f5a 92 ; string, length &12 &4f5b 19 04 0c 03 d0 02 ; MOVE &030c, &02d0 &4f61 19 05 10 03 0c 03 ; DRAW &0310, &030c &4f67 19 05 48 03 7a 03 ; DRAW &0348, &037a &4f6d 38 50 26 ; object at x:&50, y:&26, type &18 &4f70 08 ba 0c 68 ; platform at x:&0c, y:&ba, length &68 &4f74 42 1e ; shape at x:&1e, type &02 &4f76 19 b4 ; fill at y:&b4, pattern &9 &4f78 6a 33 ; shape at x:&33, type &2a &4f7a 12 b4 ; fill at y:&b4, pattern &2 &4f7c 52 54 ; shape at x:&54, type &12 &4f7e 10 b4 ; fill at y:&b4, pattern &0 &4f80 4b 6e ; shape at x:&6e, type &0b &4f82 11 b4 ; fill at y:&b4, pattern &1 &4f84 4f f9 68 ; shape at x:&79, y:&68, type &0f &4f87 4f f9 8c ; shape at x:&79, y:&8c, type &0f &4f8a 04 4c 43 ; red pill at x:&4c, y:&43 &4f8d 06 18 2d ; other pill at x:&18, y:&2d &4f90 02 b9 2d 0b ; use custom update routine &2db9 (update_dripping_acid) &4f94 02 0d 00 00 00 b8 00 00 00 d2 a0 60 ; room variables &60 &a0 &d2 &00 &00 &00 &b8 &00 &00 &00 &0d &02 &4fa0 00 ; end of data ; room_1c_data &4fa1 08 3a 00 36 ; platform at x:&00, y:&3a, length &36 &4fa5 08 3a 4f 32 ; platform at x:&4f, y:&3a, length &32 &4fa9 5a 0a ; shape at x:&0a, type &1a &4fab 1a 32 ; fill at y:&32, pattern &a &4fad 5a 1c ; shape at x:&1c, type &1a &4faf 10 32 ; fill at y:&32, pattern &0 &4fb1 45 30 ; shape at x:&30, type &05 &4fb3 1f 32 ; fill at y:&32, pattern &f &4fb5 11 1c ; fill at y:&1c, pattern &1 &4fb7 52 60 ; shape at x:&60, type &12 &4fb9 19 32 ; fill at y:&32, pattern &9 &4fbb 6a 77 ; shape at x:&77, type &2a &4fbd 1a 32 ; fill at y:&32, pattern &a &4fbf 8c ; string, length &0c &4fc0 19 04 28 02 14 03 ; MOVE &0228, &0314 &4fc6 19 05 28 03 14 03 ; DRAW &0328, &0314 &4fcc 08 dc 04 74 ; platform at x:&04, y:&dc, length &74 &4fd0 5d 3e ; shape at x:&3e, type &1d &4fd2 18 d8 ; fill at y:&d8, pattern &8 &4fd4 5e 1a ; shape at x:&1a, type &1e &4fd6 14 d8 ; fill at y:&d8, pattern &4 &4fd8 72 6a ; shape at x:&6a, type &32 &4fda 15 d8 ; fill at y:&d8, pattern &5 &4fdc 64 07 ; shape at x:&07, type &24 &4fde 1c d8 ; fill at y:&d8, pattern &c &4fe0 64 87 cd ; shape at x:&07, y:&cd, type &24 &4fe3 1c c8 ; fill at y:&c8, pattern &c &4fe5 6c c2 95 ; shape at x:&42, y:&95, type &2c &4fe8 12 8c ; fill at y:&8c, pattern &2 &4fea 3b 3c 85 ; object at x:&3c, y:&85, type &1b &4fed 04 38 8d ; red pill at x:&38, y:&8d &4ff0 08 a0 00 14 ; platform at x:&00, y:&a0, length &14 &4ff4 4a 09 ; shape at x:&09, type &0a &4ff6 1e 96 ; fill at y:&96, pattern &e &4ff8 02 b6 33 01 ; use custom update routine &33b6 (update_agar) &4ffc 4e c8 ; room variables &c8 &4e &4ffe 00 ; end of data ; room_1d_data &4fff 5b f6 87 ; shape at x:&76, y:&87, type &1b &5002 18 82 ; fill at y:&82, pattern &8 &5004 6b f5 71 ; shape at x:&75, y:&71, type &2b &5007 1c 6e ; fill at y:&6e, pattern &c &5009 08 8e 5e 24 ; platform at x:&5e, y:&8e, length &24 &500d 5a 67 ; shape at x:&67, type &1a &500f 11 8c ; fill at y:&8c, pattern &1 &5011 6f 7a ; shape at x:&7a, type &2f &5013 15 8c ; fill at y:&8c, pattern &5 &5015 08 f2 00 64 ; platform at x:&00, y:&f2, length &64 &5019 4c 30 ; shape at x:&30, type &0c &501b 1f f0 ; fill at y:&f0, pattern &f &501d 4c 13 ; shape at x:&13, type &0c &501f 16 f0 ; fill at y:&f0, pattern &6 &5021 77 4e ; shape at x:&4e, type &37 &5023 12 f0 ; fill at y:&f0, pattern &2 &5025 39 48 d1 ; object at x:&48, y:&d1, type &19 &5028 69 8f aa ; shape at x:&0f, y:&aa, type &29 &502b 14 a5 ; fill at y:&a5, pattern &4 &502d 6f f9 e9 ; shape at x:&79, y:&e9, type &2f &5030 1a e6 ; fill at y:&e6, pattern &a &5032 61 f9 e3 ; shape at x:&79, y:&e3, type &21 &5035 14 e2 ; fill at y:&e2, pattern &4 &5037 06 89 cd ; other pill at x:&89, y:&cd &503a 68 f1 ff ; shape at x:&71, y:&ff, type &28 &503d 08 3a 00 76 ; platform at x:&00, y:&3a, length &76 &5041 46 23 ; shape at x:&23, type &06 &5043 17 37 ; fill at y:&37, pattern &7 &5045 46 57 ; shape at x:&57, type &06 &5047 1d 37 ; fill at y:&37, pattern &d &5049 70 be 21 ; shape at x:&3e, y:&21, type &30 &504c 15 1e ; fill at y:&1e, pattern &5 &504e 08 90 08 38 ; platform at x:&08, y:&90, length &38 &5052 75 14 ; shape at x:&14, type &35 &5054 1a 8c ; fill at y:&8c, pattern &a &5056 6d 26 ; shape at x:&26, type &2d &5058 19 8c ; fill at y:&8c, pattern &9 &505a 76 37 ; shape at x:&37, type &36 &505c 10 8c ; fill at y:&8c, pattern &0 &505e 1b 6e ; fill at y:&6e, pattern &b &5060 04 31 63 ; red pill at x:&31, y:&63 &5063 02 e9 31 0b ; use custom update routine &31e9 (update_spirit) &5067 03 25 00 00 00 00 70 70 70 70 8b 5a ; room variables &5a &8b &70 &70 &70 &70 &00 &00 &00 &00 &25 &03 &5073 00 ; end of data ; room_1e_data &5074 08 e4 00 3e ; platform at x:&00, y:&e4, length &3e &5078 5e 32 ; shape at x:&32, type &1e &507a 10 dc ; fill at y:&dc, pattern &0 &507c 42 1b ; shape at x:&1b, type &02 &507e 1d dc ; fill at y:&dc, pattern &d &5080 70 c5 c5 ; shape at x:&45, y:&c5, type &30 &5083 1a c1 ; fill at y:&c1, pattern &a &5085 5d c2 bb ; shape at x:&42, y:&bb, type &1d &5088 14 b4 ; fill at y:&b4, pattern &4 &508a 50 c2 ff ; shape at x:&42, y:&ff, type &10 &508d 08 dc 54 2d ; platform at x:&54, y:&dc, length &2d &5091 5b 5b ; shape at x:&5b, type &1b &5093 16 d7 ; fill at y:&d7, pattern &6 &5095 6e 69 ; shape at x:&69, type &2e &5097 18 d7 ; fill at y:&d7, pattern &8 &5099 75 78 ; shape at x:&78, type &35 &509b 11 d7 ; fill at y:&d7, pattern &1 &509d 57 f5 af ; shape at x:&75, y:&af, type &17 &50a0 1c a8 ; fill at y:&a8, pattern &c &50a2 6e e6 c1 ; shape at x:&66, y:&c1, type &2e &50a5 15 b9 ; fill at y:&b9, pattern &5 &50a7 6e e9 a7 ; shape at x:&69, y:&a7, type &2e &50aa 19 a0 ; fill at y:&a0, pattern &9 &50ac 08 80 5e 1e ; platform at x:&5e, y:&80, length &1e &50b0 6b 64 ; shape at x:&64, type &2b &50b2 1f 7c ; fill at y:&7c, pattern &f &50b4 45 76 ; shape at x:&76, type &05 &50b6 1a 78 ; fill at y:&78, pattern &a &50b8 65 e3 5f ; shape at x:&63, y:&5f, type &25 &50bb 1c 5a ; fill at y:&5a, pattern &c &50bd 72 b8 75 ; shape at x:&38, y:&75, type &32 &50c0 12 6e ; fill at y:&6e, pattern &2 &50c2 04 2a 99 ; red pill at x:&2a, y:&99 &50c5 4f ed 20 ; shape at x:&6d, y:&20, type &0f &50c8 02 6e 35 0b ; use custom update routine &356e (update_flashbulbs) &50cc 02 07 00 50 50 e4 00 80 00 f2 36 98 ; room variables &98 &36 &f2 &00 &80 &00 &e4 &50 &50 &00 &07 &02 &50d8 00 ; end of data ; room_1f_data &50d9 08 60 10 28 ; platform at x:&10, y:&60, length &28 &50dd 4e 33 ; shape at x:&33, type &0e &50df 19 5a ; fill at y:&5a, pattern &9 &50e1 5e 20 ; shape at x:&20, type &1e &50e3 12 5a ; fill at y:&5a, pattern &2 &50e5 08 dc 00 76 ; platform at x:&00, y:&dc, length &76 &50e9 55 6e ; shape at x:&6e, type &15 &50eb 1b d3 ; fill at y:&d3, pattern &b &50ed 5a 5a ; shape at x:&5a, type &1a &50ef 1e d4 ; fill at y:&d4, pattern &e &50f1 46 42 ; shape at x:&42, type &06 &50f3 15 d4 ; fill at y:&d4, pattern &5 &50f5 45 2c ; shape at x:&2c, type &05 &50f7 17 d4 ; fill at y:&d4, pattern &7 &50f9 53 12 ; shape at x:&12, type &13 &50fb 11 d4 ; fill at y:&d4, pattern &1 &50fd 4b a8 b7 ; shape at x:&28, y:&b7, type &0b &5100 14 b4 ; fill at y:&b4, pattern &4 &5102 08 a2 32 54 ; platform at x:&32, y:&a2, length &54 &5106 42 48 ; shape at x:&48, type &02 &5108 10 9c ; fill at y:&9c, pattern &0 &510a 76 67 ; shape at x:&67, type &36 &510c 14 9c ; fill at y:&9c, pattern &4 &510e 6a 77 ; shape at x:&77, type &2a &5110 1c 9e ; fill at y:&9e, pattern &c &5112 65 57 ; shape at x:&57, type &25 &5114 11 a0 ; fill at y:&a0, pattern &1 &5116 65 d7 91 ; shape at x:&57, y:&91, type &25 &5119 11 8c ; fill at y:&8c, pattern &1 &511b 08 40 46 28 ; platform at x:&46, y:&40, length &28 &511f 6c 5a ; shape at x:&5a, type &2c &5121 1f 3c ; fill at y:&3c, pattern &f &5123 04 86 65 ; red pill at x:&86, y:&65 &5126 06 94 eb ; other pill at x:&94, y:&eb &5129 03 ; use common update routine &512a 00 ; end of data ; room_20_data &512b 8c ; string, length &0c &512c 13 00 01 00 00 00 ; set colour 0 to red &5132 13 02 01 00 00 00 ; set colour 2 to red &5138 08 f4 00 81 ; platform at x:&00, y:&f4, length &81 &513c 6e 7d ; shape at x:&7d, type &2e &513e 17 f0 ; fill at y:&f0, pattern &7 &5140 13 f6 ; fill at y:&f6, pattern &3 &5142 70 54 ; shape at x:&54, type &30 &5144 17 f0 ; fill at y:&f0, pattern &7 &5146 51 26 ; shape at x:&26, type &11 &5148 08 c4 14 6d ; platform at x:&14, y:&c4, length &6d &514c 76 77 ; shape at x:&77, type &36 &514e 1e be ; fill at y:&be, pattern &e &5150 46 62 ; shape at x:&62, type &06 &5152 11 be ; fill at y:&be, pattern &1 &5154 64 4f ; shape at x:&4f, type &24 &5156 4e 1e ; shape at x:&1e, type &0e &5158 72 3b ; shape at x:&3b, type &32 &515a 1e be ; fill at y:&be, pattern &e &515c 69 e6 ac ; shape at x:&66, y:&ac, type &29 &515f 08 44 14 5a ; platform at x:&14, y:&44, length &5a &5163 4d 28 ; shape at x:&28, type &0d &5165 1e 20 ; fill at y:&20, pattern &e &5167 4d 60 ; shape at x:&60, type &0d &5169 1e 20 ; fill at y:&20, pattern &e &516b 53 44 ; shape at x:&44, type &13 &516d 11 3c ; fill at y:&3c, pattern &1 &516f 04 0f b5 ; red pill at x:&0f, y:&b5 &5172 02 49 33 0d ; use custom update routine &3349 (update_darkroom_left) &5176 92 ff 04 10 c0 80 40 00 c0 80 40 00 b4 00 ; room variables &00 &b4 &00 &40 &80 &c0 &00 &40 &80 &c0 &10 &04 &ff &92 &5184 00 ; end of data ; room_21_data &5185 98 ; string, length &18 &5186 13 00 01 00 00 00 ; set colour 0 to red &518c 13 02 01 00 00 00 ; set colour 2 to red &5192 19 04 de 04 00 00 ; MOVE &04de, &0000 &5198 19 05 de 04 ff 03 ; DRAW &04de, &03ff &519e 08 f4 00 81 ; platform at x:&00, y:&f4, length &81 &51a2 6d 18 ; shape at x:&18, type &2d &51a4 16 f0 ; fill at y:&f0, pattern &6 &51a6 61 50 ; shape at x:&50, type &21 &51a8 1e f0 ; fill at y:&f0, pattern &e &51aa 4b 36 ; shape at x:&36, type &0b &51ac 6b 28 ; shape at x:&28, type &2b &51ae 61 66 ; shape at x:&66, type &21 &51b0 63 ff ea ; shape at x:&7f, y:&ea, type &23 &51b3 10 e6 ; fill at y:&e6, pattern &0 &51b5 13 fa ; fill at y:&fa, pattern &3 &51b7 09 c4 ; short platform at y:&c4 &51b9 08 8a 04 5a ; platform at x:&04, y:&8a, length &5a &51bd 43 52 ; shape at x:&52, type &03 &51bf 11 82 ; fill at y:&82, pattern &1 &51c1 6a 3c ; shape at x:&3c, type &2a &51c3 5e 2a ; shape at x:&2a, type &1e &51c5 17 82 ; fill at y:&82, pattern &7 &51c7 55 09 ; shape at x:&09, type &15 &51c9 5b 17 ; shape at x:&17, type &1b &51cb 4b d4 51 ; shape at x:&54, y:&51, type &0b &51ce 08 3a 00 78 ; platform at x:&00, y:&3a, length &78 &51d2 6c 14 ; shape at x:&14, type &2c &51d4 11 32 ; fill at y:&32, pattern &1 &51d6 6c 3c ; shape at x:&3c, type &2c &51d8 6c 64 ; shape at x:&64, type &2c &51da 1e 32 ; fill at y:&32, pattern &e &51dc 04 6c 19 ; red pill at x:&6c, y:&19 &51df 02 e6 32 0c ; use custom update routine &32e6 (update_darkroom_right) &51e3 01 04 10 c0 80 40 00 c0 80 40 00 b4 15 ; room variables &15 &b4 &00 &40 &80 &c0 &00 &40 &80 &c0 &10 &04 &01 &51f0 00 ; end of data ; room_22_data &51f1 8c ; string, length &0c &51f2 19 04 22 00 2c 00 ; MOVE &0022, &002c &51f8 19 05 22 00 fe 03 ; DRAW &0022, &03fe &51fe 08 f4 00 68 ; platform at x:&00, y:&f4, length &68 &5202 08 f4 73 0e ; platform at x:&73, y:&f4, length &0e &5206 4d 54 ; shape at x:&54, type &0d &5208 15 f0 ; fill at y:&f0, pattern &5 &520a 11 d0 ; fill at y:&d0, pattern &1 &520c 57 79 ; shape at x:&79, type &17 &520e 12 e9 ; fill at y:&e9, pattern &2 &5210 6a 03 ; shape at x:&03, type &2a &5212 19 f0 ; fill at y:&f0, pattern &9 &5214 79 1e ; shape at x:&1e, type &39 &5216 79 1f ; shape at x:&1f, type &39 &5218 79 20 ; shape at x:&20, type &39 &521a 1a f0 ; fill at y:&f0, pattern &a &521c 79 21 ; shape at x:&21, type &39 &521e 4b a0 d3 ; shape at x:&20, y:&d3, type &0b &5221 51 96 c9 ; shape at x:&16, y:&c9, type &11 &5224 19 c6 ; fill at y:&c6, pattern &9 &5226 64 8f bb ; shape at x:&0f, y:&bb, type &24 &5229 1c b9 ; fill at y:&b9, pattern &c &522b 64 8f ad ; shape at x:&0f, y:&ad, type &24 &522e 1c ab ; fill at y:&ab, pattern &c &5230 08 92 1a 67 ; platform at x:&1a, y:&92, length &67 &5234 53 28 ; shape at x:&28, type &13 &5236 14 8c ; fill at y:&8c, pattern &4 &5238 44 6d ; shape at x:&6d, type &04 &523a 1d 8c ; fill at y:&8c, pattern &d &523c 4c 4e ; shape at x:&4e, type &0c &523e 11 8c ; fill at y:&8c, pattern &1 &5240 55 c9 49 ; shape at x:&49, y:&49, type &15 &5243 1c 42 ; fill at y:&42, pattern &c &5245 08 46 00 35 ; platform at x:&00, y:&46, length &35 &5249 83 ; string, length &03 &524a 00 00 00 ; (null) &524d 04 54 33 ; red pill at x:&54, y:&33 &5250 02 d7 34 00 ; use custom update routine &34d7 (update_elixir) &5254 00 ; room variables &00 &5255 00 ; end of data ; room_23_data &5256 08 f4 40 41 ; platform at x:&40, y:&f4, length &41 &525a 70 66 ; shape at x:&66, type &30 &525c 16 f0 ; fill at y:&f0, pattern &6 &525e 4a 46 ; shape at x:&46, type &0a &5260 10 f0 ; fill at y:&f0, pattern &0 &5262 6c ec e9 ; shape at x:&6c, y:&e9, type &2c &5265 18 e6 ; fill at y:&e6, pattern &8 &5267 75 55 ; shape at x:&55, type &35 &5269 15 dc ; fill at y:&dc, pattern &5 &526b 08 98 50 31 ; platform at x:&50, y:&98, length &31 &526f 42 75 ; shape at x:&75, type &02 &5271 1e 96 ; fill at y:&96, pattern &e &5273 51 5a ; shape at x:&5a, type &11 &5275 14 96 ; fill at y:&96, pattern &4 &5277 51 dc 89 ; shape at x:&5c, y:&89, type &11 &527a 12 84 ; fill at y:&84, pattern &2 &527c 04 82 4d ; red pill at x:&82, y:&4d &527f 08 f4 00 1b ; platform at x:&00, y:&f4, length &1b &5283 09 92 ; short platform at y:&92 &5285 6b 0a ; shape at x:&0a, type &2b &5287 11 8b ; fill at y:&8b, pattern &1 &5289 08 3a 00 19 ; platform at x:&00, y:&3a, length &19 &528d 69 97 3a ; shape at x:&17, y:&3a, type &29 &5290 14 39 ; fill at y:&39, pattern &4 &5292 14 30 ; fill at y:&30, pattern &4 &5294 58 9a 4a ; shape at x:&1a, y:&4a, type &18 &5297 03 ; use common update routine &5298 00 ; end of data ; room_24_data &5299 08 f4 00 33 ; platform at x:&00, y:&f4, length &33 &529d 56 18 ; shape at x:&18, type &16 &529f 14 eb ; fill at y:&eb, pattern &4 &52a1 57 8e d9 ; shape at x:&0e, y:&d9, type &17 &52a4 19 ce ; fill at y:&ce, pattern &9 &52a6 61 9c d9 ; shape at x:&1c, y:&d9, type &21 &52a9 1a d7 ; fill at y:&d7, pattern &a &52ab 08 e6 50 26 ; platform at x:&50, y:&e6, length &26 &52af 46 68 ; shape at x:&68, type &06 &52b1 1f e2 ; fill at y:&e2, pattern &f &52b3 08 98 00 2f ; platform at x:&00, y:&98, length &2f &52b7 40 19 ; shape at x:&19, type &00 &52b9 1a 94 ; fill at y:&94, pattern &a &52bb 08 98 52 2f ; platform at x:&52, y:&98, length &2f &52bf 4b 58 ; shape at x:&58, type &0b &52c1 11 96 ; fill at y:&96, pattern &1 &52c3 6b 67 ; shape at x:&67, type &2b &52c5 19 96 ; fill at y:&96, pattern &9 &52c7 6d 77 ; shape at x:&77, type &2d &52c9 10 96 ; fill at y:&96, pattern &0 &52cb 08 3c 4c 28 ; platform at x:&4c, y:&3c, length &28 &52cf 5b 66 ; shape at x:&66, type &1b &52d1 12 36 ; fill at y:&36, pattern &2 &52d3 04 74 1d ; red pill at x:&74, y:&1d &52d6 02 9a 34 00 ; use custom update routine &349a (update_top_of_beanstalk) &52da 50 ; room variables &50 &52db 00 ; end of data ; room_25_data &52dc 08 f4 00 50 ; platform at x:&00, y:&f4, length &50 &52e0 45 46 ; shape at x:&46, type &05 &52e2 14 f0 ; fill at y:&f0, pattern &4 &52e4 5d 20 ; shape at x:&20, type &1d &52e6 17 f0 ; fill at y:&f0, pattern &7 &52e8 44 a3 ad ; shape at x:&23, y:&ad, type &04 &52eb 1a aa ; fill at y:&aa, pattern &a &52ed 04 1e a5 ; red pill at x:&1e, y:&a5 &52f0 08 98 00 13 ; platform at x:&00, y:&98, length &13 &52f4 6a 0b ; shape at x:&0b, type &2a &52f6 1d 96 ; fill at y:&96, pattern &d &52f8 6f 8c 63 ; shape at x:&0c, y:&63, type &2f &52fb 1c 61 ; fill at y:&61, pattern &c &52fd 08 4a 2e 26 ; platform at x:&2e, y:&4a, length &26 &5301 53 41 ; shape at x:&41, type &13 &5303 12 46 ; fill at y:&46, pattern &2 &5305 08 aa 49 2d ; platform at x:&49, y:&aa, length &2d &5309 4c 6b ; shape at x:&6b, type &0c &530b 1f a0 ; fill at y:&a0, pattern &f &530d 5b 51 ; shape at x:&51, type &1b &530f 15 a0 ; fill at y:&a0, pattern &5 &5311 65 d7 93 ; shape at x:&57, y:&93, type &25 &5314 11 8c ; fill at y:&8c, pattern &1 &5316 06 58 8b ; other pill at x:&58, y:&8b &5319 02 6e 35 0b ; use custom update routine &356e (update_flashbulbs) &531d 02 07 00 3c 3c e4 00 80 00 f2 58 98 room variables &98 &58 &f2 &00 &80 &00 &e4 &3c &3c &00 &07 &02 &5329 00 ; end of data ; room_26_data &532a 54 ed fe ; shape at x:&6d, y:&fe, type &14 &532d 08 f0 6d 14 ; platform at x:&6d, y:&f0, length &14 &5331 4b 72 ; shape at x:&72, type &0b &5333 1f ec ; fill at y:&ec, pattern &f &5335 08 b2 42 22 ; platform at x:&42, y:&b2, length &22 &5339 98 ; string, length &18 &533a 19 04 7c 02 28 03 ; MOVE &027c, &0328 &5340 19 05 7c 02 38 01 ; DRAW &027c, &0138 &5346 19 05 00 04 38 01 ; DRAW &0400, &0138 &534c 19 05 00 04 28 03 ; DRAW &0400, &0328 &5352 08 d4 06 2e ; platform at x:&06, y:&d4, length &2e &5356 6b 1c ; shape at x:&1c, type &2b &5358 1d d0 ; fill at y:&d0, pattern &d &535a 4b 29 ; shape at x:&29, type &0b &535c 10 d0 ; fill at y:&d0, pattern &0 &535e 08 a6 13 1b ; platform at x:&13, y:&a6, length &1b &5362 64 27 ; shape at x:&27, type &24 &5364 1c a0 ; fill at y:&a0, pattern &c &5366 6d 18 ; shape at x:&18, type &2d &5368 10 a0 ; fill at y:&a0, pattern &0 &536a 64 a7 97 ; shape at x:&27, y:&97, type &24 &536d 1c 94 ; fill at y:&94, pattern &c &536f 08 74 03 24 ; platform at x:&03, y:&74, length &24 &5373 55 22 ; shape at x:&22, type &15 &5375 11 6e ; fill at y:&6e, pattern &1 &5377 75 08 ; shape at x:&08, type &35 &5379 1a 6e ; fill at y:&6e, pattern &a &537b 6e 16 ; shape at x:&16, type &2e &537d 15 6e ; fill at y:&6e, pattern &5 &537f 08 3a 06 2c ; platform at x:&06, y:&3a, length &2c &5383 51 24 ; shape at x:&24, type &11 &5385 1e 34 ; fill at y:&34, pattern &e &5387 06 38 c1 ; other pill at x:&38, y:&c1 &538a 04 30 5d ; red pill at x:&30, y:&5d &538d 02 94 30 06 ; use custom update routine &3094 (update_water_tank) &5391 14 0c 0c 2a 50 00 00 ; room variables &00 &00 &50 &2a &0c &0c &14 &5398 00 ; end of data ; room_27_data &5399 09 f0 ; short platform at y:&f0 &539b 57 09 ; shape at x:&09, type &17 &539d 10 e6 ; fill at y:&e6, pattern &0 &539f 08 c4 68 19 ; platform at x:&68, y:&c4, length &19 &53a3 7a 7b ; shape at x:&7b, type &3a &53a5 3f 78 c6 ; object at x:&78, y:&c6, type &1f &53a8 08 4a 7b 12 ; platform at x:&7b, y:&4a, length &12 &53ac 08 4a 18 61 ; platform at x:&18, y:&4a, length &61 &53b0 4b 22 ; shape at x:&22, type &0b &53b2 14 47 ; fill at y:&47, pattern &4 &53b4 5e 3c ; shape at x:&3c, type &1e &53b6 1f 46 ; fill at y:&46, pattern &f &53b8 5e 5e ; shape at x:&5e, type &1e &53ba 1e 46 ; fill at y:&46, pattern &e &53bc 59 fa 4a ; shape at x:&7a, y:&4a, type &19 &53bf 15 46 ; fill at y:&46, pattern &5 &53c1 50 fa 89 ; shape at x:&7a, y:&89, type &10 &53c4 08 96 00 15 ; platform at x:&00, y:&96, length &15 &53c8 42 0d ; shape at x:&0d, type &02 &53ca 19 8c ; fill at y:&8c, pattern &9 &53cc 08 c8 10 20 ; platform at x:&10, y:&c8, length &20 &53d0 41 22 ; shape at x:&22, type &01 &53d2 11 be ; fill at y:&be, pattern &1 &53d4 04 49 23 ; red pill at x:&49, y:&23 &53d7 06 30 37 ; other pill at x:&30, y:&37 &53da 02 b2 34 00 ; use custom update routine &34b2 (update_soap) &53de 00 ; room variables &00 &53df 00 ; end of data ; end of data ; unused &53e0 ff ; unused &35e1 31 35 2c ; "15," ; flashbulb_sprite &53e4 77 ee f8 e2 98 f3 8c 22 cb 3f f8 e2 77 ee ; flashbulb_mask &53f2 88 11 00 11 00 00 00 11 00 00 00 11 88 11 ; sound_5400 # Flashbulb hitting player ; chan vol pitch dur &5400 00 00 f1 ff 04 00 02 00 ; elixir_graphics_data &5408 76 98 46 ; shape at x:&18, y:&46, type &36 &540b 1c 40 ; fill at y:&40, pattern &c &540d 00 ; end of data ; elixir_label_string &540e 1f 02 02 ; TAB(&02, &02) &5411 45 6c 69 78 69 72 ; "Elixir" &5417 00 ; end of string ; plot_clock_hand_string &5418 19 04 84 01 84 02 ; MOVE &0184, &0284 &541e 19 05 ff 01 ff 02 ; DRAW &01ff, &02ff, coordinates overwritten ; sound_5424 # Initialising lipstick missiles ; chan vol pitch dur &5424 02 00 06 00 0a 00 02 00 ; sound_542c # Drip hitting something ; chan vol pitch dur &542c 00 00 01 00 05 00 01 00 ; unplot_clock_hand_string &5434 19 04 84 01 84 02 ; MOVE &0184, &0284 &543a 19 07 ff 01 ff 02 ; DRAW &01ff, &02ff in background colour, coordinates overwritten ; flashbulb_colour_graphics_data &5440 86 ; string, length &06 &5441 13 01 01 00 00 00 ; set colour 1 to red (values modified) &5447 00 ; end of data ; sound_5448 # Flashbulb or lipstick missile firing ; chan vol pitch dur &5448 00 00 03 00 14 00 05 00 ; beanstalk_leaves_graphics_data &5450 78 00 00 ; shape at x:&00 (modified), y:&00 (modified) type &38 &5453 1d ff ; fill at y:&ff (modified), pattern &d &5455 00 ; end of graphics data ; sound_5456 # Clock tick ; chan vol pitch dur &5456 00 00 f3 ff 05 00 01 00 ; unused &545e f4 e8 dc d0 01 03 05 07 ; zoom_rectangle_string # Values are modified &5466 12 00 2b ; GCOL 0, &2b &5469 19 04 3c 02 d6 01 ; MOVE &023c, &01d6 &546f 19 01 00 00 ae 00 ; DRAW +&0000, &00ae &5475 19 01 6c 00 00 00 ; DRAW +&006c, &0000 &547b 19 01 00 00 52 ff ; DRAW +&0000, &ff52 &5481 19 01 9c ff 00 00 ; DRAW +&ff9c, &0000 &5487 21 ; completion_sounds ; chan vol pitch dur &5488 01 00 0d 00 03 00 3c 00 &5490 00 00 0d 00 03 00 3c 00 &5498 02 00 0e 00 0a 00 46 00 ; completion_colour_string &54a0 13 00 0e 00 00 00 ; set colour 0 to flashing cyan/red ; unused &54a6 47 72 6f 77 69 6e 67 ; "Growing" ; unused &54ad 0a 08 08 08 08 29 68 0c dc 33 2c be 54 01 41 48 &54bd 0d 57 0d ; empty_string &54c0 65 6d 70 74 79 00 ; "empty" ; unused &54c5 47 2e 00 ; "G." &54c9 20 61 74 2e 2e ; " at.." &54ce 0d &54cf 3f 20 5f ; "? _" &54d2 08 ; introduction_room_01_data &54d3 08 f0 00 64 ; platform at x:&00, y:&f0, length &64 &54d7 08 c0 60 30 ; platform at x:&60, y:&c0, length &30 &54db 08 94 04 3c ; platform at x:&04, y:&94, length &3c &54df 00 ; end of data ; introduction_room_02_data &54e0 46 14 ; shape at x:&14, type &06 &54e2 10 90 ; fill at y:&90, pattern &0 &54e4 57 36 ; shape at x:&36, type &17 &54e6 14 8e ; fill at y:&8e, pattern &4 &54e8 1b 92 ; fill at y:&92, pattern &b &54ea 76 b0 ef ; shape at x:&30, y:&ef, type &36 &54ed 12 ec ; fill at y:&ec, pattern &2 &54ef 4e 12 ; shape at x:&12, type &0e &54f1 19 ec ; fill at y:&ec, pattern &9 &54f3 5e 52 ; shape at x:&52, type &1e &54f5 11 ec ; fill at y:&ec, pattern &1 &54f7 41 f8 bf ; shape at x:&78, y:&bf, type &01 &54fa 1e bd ; fill at y:&bd, pattern &e &54fc 00 ; end of data ; unused &54fd 2c 31 33 ; ",13" ; room_edge_data ; room_edge_00_data &5500 09 5c ; short platform at y:&5c &5502 55 08 ; shape at x:&08, type &15 &5504 1c 54 ; fill at y:&54, pattern &c &5506 09 f4 ; short platform at y:&f4 &5508 00 ; end of data ; room_edge_01_data &5509 09 60 ; short platform at y:&60 &550b 6b 08 ; shape at x:&08, type &2b &550d 10 5a ; fill at y:&5a, pattern &0 &550f 09 f4 ; short platform at y:&f4 &5511 00 ; end of data ; room_edge_02_data &5512 09 7c ; short platform at y:&7c &5514 6d 07 ; shape at x:&07, type &2d &5516 1c 78 ; fill at y:&78, pattern &c &5518 09 f4 ; short platform at y:&f4 &551a 57 07 ; shape at x:&07, type &17 &551c 11 ec ; fill at y:&ec, pattern &1 &551e 00 ; end of data ; room_edge_03_data &551f 09 f4 ; short platform at y:&f4 &5521 09 54 ; short platform at y:&54 &5523 64 06 ; shape at x:&06, type &24 &5525 11 4c ; fill at y:&4c, pattern &1 &5527 00 ; end of data ; room_edge_04_data &5528 09 f4 ; short platform at y:&f4 &552a 09 38 ; short platform at y:&38 &552c 00 ; end of data ; room_edge_05_data &552d 09 f4 ; short platform at y:&f4 &552f 09 4c ; short platform at y:&4c &5531 00 ; end of data ; room_edge_06_data &5532 09 f4 ; short platform at y:&f4 &5534 09 88 ; short platform at y:&88 &5536 00 ; end of data ; room_edge_07_data &5537 09 f4 ; short platform at y:&f4 &5539 09 78 ; short platform at y:&78 &553b 00 ; end of data ; room_edge_08_data &553c 09 3c ; short platform at y:&3c &553e 54 88 0a ; shape at x:&08, y:&0a, type &14 &5541 09 f0 ; short platform at y:&f0 &5543 00 ; end of data ; room_edge_09_data &5544 09 54 ; short platform at y:&54 &5546 65 06 ; shape at x:&06, type &25 &5548 1c 50 ; fill at y:&50, pattern &c &554a 09 f2 ; short platform at y:&f2 &554c 00 ; end of data ; room_edge_0a_data &554d 09 54 ; short platform at y:&54 &554f 57 07 ; shape at x:&07, type &17 &5551 14 4b ; fill at y:&4b, pattern &4 &5553 09 f0 ; short platform at y:&f0 &5555 00 ; end of data ; room_edge_0b_data &5556 09 64 ; short platform at y:&64 &5558 6b 07 ; shape at x:&07, type &2b &555a 12 5a ; fill at y:&5a, pattern &2 &555c 09 f0 ; short platform at y:&f0 &555e 00 ; end of data ; room_edge_0c_data &555f 09 f0 ; short platform at y:&f0 &5561 61 87 f0 ; shape at x:&07, y:&f0, type &21 &5564 15 ee ; fill at y:&ee, pattern &5 &5566 09 64 ; short platform at y:&64 &5568 00 ; end of data ; room_edge_0d_data &5569 09 f4 ; short platform at y:&f4 &556b 09 60 ; short platform at y:&60 &556d 6e 07 ; shape at x:&07, type &2e &556f 17 5a ; fill at y:&5a, pattern &7 &5571 00 ; end of data ; room_edge_0e_data &5572 09 a0 ; short platform at y:&a0 &5574 00 ; end of data ; room_edge_0f_data &5575 09 e0 ; short platform at y:&e0 &5577 09 4e ; short platform at y:&4e &5579 00 ; end of data ; room_edge_10_data &557a 09 b4 ; short platform at y:&b4 &557c 5b 07 ; shape at x:&07, type &1b &557e 16 b0 ; fill at y:&b0, pattern &6 &5580 4f 88 d8 ; shape at x:&08, y:&d8, type &0f &5583 4f 88 fe ; shape at x:&08, y:&fe, type &0f &5586 09 6a ; short platform at y:&6a &5588 00 ; end of data ; room_edge_11_data &5589 09 f4 ; short platform at y:&f4 &558b 5b 08 ; shape at x:&08, type &1b &558d 1e f0 ; fill at y:&f0, pattern &e &558f 09 8e ; short platform at y:&8e &5591 4b 06 ; shape at x:&06, type &0b &5593 10 8c ; fill at y:&8c, pattern &0 &5595 09 3c ; short platform at y:&3c &5597 00 ; end of data ; room_edge_12_data &5598 09 b0 ; short platform at y:&b0 &559a 57 08 ; shape at x:&08, type &17 &559c 12 aa ; fill at y:&aa, pattern &2 &559e 09 3c ; short platform at y:&3c &55a0 00 ; end of data ; room_edge_13_data &55a1 09 e8 ; short platform at y:&e8 &55a3 09 38 ; short platform at y:&38 &55a5 65 06 ; shape at x:&06, type &25 &55a7 1c 32 ; fill at y:&32, pattern &c &55a9 00 ; end of data ; room_edge_14_data &55aa 09 40 ; short platform at y:&40 &55ac 09 e6 ; short platform at y:&e6 &55ae 00 ; end of data ; room_edge_15_data &55af 09 ec ; short platform at y:&ec &55b1 65 06 ; shape at x:&06, type &25 &55b3 1c e6 ; fill at y:&e6, pattern &c &55b5 09 50 ; short platform at y:&50 &55b7 00 ; end of data ; room_edge_16_data &55b8 09 ec ; short platform at y:&ec &55ba 00 ; end of data ; room_edge_17_data &55bb 09 3e ; short platform at y:&3e &55bd 00 ; end of data ; room_edge_18_data &55be 09 c8 ; short platform at y:&c8 &55c0 55 08 ; shape at x:&08, type &15 &55c2 14 c0 ; fill at y:&c0, pattern &4 &55c4 00 ; end of data ; room_edge_19_data &55c5 09 ea ; short platform at y:&ea &55c7 61 05 ; shape at x:&05, type &21 &55c9 19 e6 ; fill at y:&e6, pattern &9 &55cb 09 66 ; short platform at y:&66 &55cd 00 ; end of data ; room_edge_1a_data &55ce 09 d8 ; short platform at y:&d8 &55d0 5b 07 ; shape at x:&07, type &1b &55d2 16 d2 ; fill at y:&d2, pattern &6 &55d4 09 92 ; short platform at y:&92 &55d6 59 07 ; shape at x:&07, type &19 &55d8 1f 8c ; fill at y:&8c, pattern &f &55da 00 ; end of data ; room_edge_1b_data &55db 09 f2 ; short platform at y:&f2 &55dd 6d 07 ; shape at x:&07, type &2d &55df 18 f0 ; fill at y:&f0, pattern &8 &55e1 09 a4 ; short platform at y:&a4 &55e3 09 36 ; short platform at y:&36 &55e5 61 08 ; shape at x:&08, type &21 &55e7 00 ; end of data ; room_edge_1c_data &55e8 09 ea ; short platform at y:&ea &55ea 09 3a ; short platform at y:&3a &55ec 00 ; end of data ; room_edge_1d_data &55ed 09 f2 ; short platform at y:&f2 &55ef 55 06 ; shape at x:&06, type &15 &55f1 1c ec ; fill at y:&ec, pattern &c &55f3 09 3a ; short platform at y:&3a &55f5 00 ; end of data ; room_edge_1e_data &55f6 09 48 ; short platform at y:&48 &55f8 4b 05 ; shape at x:&05, type &0b &55fa 14 46 ; fill at y:&46, pattern &4 &55fc 09 e4 ; short platform at y:&e4 &55fe 00 ; end of data ; unused &55ff 00 ; room_edge_1f_data &5600 09 dc ; short platform at y:&dc &5602 00 ; end of data ; room_edge_20_data &5603 09 f4 ; short platform at y:&f4 &5605 09 68 ; short platform at y:&68 &5607 74 09 ; shape at x:&09, type &34 &5609 09 be ; short platform at y:&be &560b 00 ; end of data ; room_edge_21_data &560c 09 f4 ; short platform at y:&f4 &560e 09 c4 ; short platform at y:&c4 &5610 75 08 ; shape at x:&08, type &35 ; room_edge_2a_data &5612 09 3a ; short platform at y:&3a &5614 00 ; end of data ; room_edge_22_data ; room_edge_29_data ; room_edge_2b_data ; room_edge_2c_data &5615 09 f4 ; short platform at y:&f4 &5617 00 ; end of data ; room_edge_23_data &5618 09 f4 ; short platform at y:&f4 &561a 09 92 ; short platform at y:&92 &561c 61 07 ; shape at x:&07, type &21 &561e 1e 8f ; fill at y:&8f, pattern &e &5620 09 3a ; short platform at y:&3a &5622 00 ; end of data ; room_edge_24_data &5623 09 f4 ; short platform at y:&f4 &5625 6f 07 ; shape at x:&07, type &2f &5627 5a 87 ef ; shape at x:&07, y:&ef, type &1a &562a 1c ee ; fill at y:&ee, pattern &c &562c 09 98 ; short platform at y:&98 &562e 00 ; end of data ; room_edge_25_data &562f 09 f4 ; short platform at y:&f4 &5631 09 98 ; short platform at y:&98 &5633 59 07 ; shape at x:&07, type &19 &5635 18 95 ; fill at y:&95, pattern &8 &5637 00 ; end of data ; room_edge_26_data ; room_edge_2d_data &5638 09 c4 ; short platform at y:&c4 &563a 00 ; end of data ; room_edge_27_data &563b 09 f0 ; short platform at y:&f0 &563d 09 52 ; short platform at y:&52 &563f 09 96 ; short platform at y:&96 &5641 00 ; end of data ; room_edge_28_data &5642 09 c4 ; short platform at y:&c4 &5644 00 ; end of data ; unused &5645 ff ; unused &5646 0d 01 00 00 00 00 ; the_spirit_stopper_string &564c 74 68 65 20 73 70 69 72 69 74 20 73 74 6f 70 70 ; "the spirit stopper" &565c 65 72 00 ; unused &565f 00 ; flame_one_sprite &5660 00 60 00 c0 10 c0 10 c0 10 c0 30 e0 30 60 30 60 &5670 20 60 30 60 30 60 70 60 70 20 70 60 70 60 70 60 &5680 60 60 60 70 70 70 30 70 30 70 30 70 30 30 30 30 &5690 30 70 30 70 30 70 30 60 30 20 70 60 60 60 70 70 &56a0 70 f0 70 78 61 3c 61 3c 43 1e 43 9e 17 cf 17 cf ; flame_two_sprite &56b0 40 00 60 00 70 00 70 00 f0 00 f0 00 f0 80 70 80 &56c0 70 80 70 80 70 c0 70 c0 60 c0 40 e0 60 60 60 60 &56d0 c0 60 c0 e0 c0 e0 c0 c0 c0 c0 c0 c0 c0 c0 c0 c0 &56e0 d0 c0 d0 c0 f0 c0 f0 e0 f0 e0 f0 e0 70 e0 70 e0 &56f0 70 e0 70 78 61 3c 61 3c 43 1e 43 9e 17 cf 17 cf ; spirit_sprite &5700 00 ee 00 11 11 00 22 00 88 22 00 88 44 00 44 44 &5710 00 44 44 00 44 88 aa 22 88 aa 22 88 00 22 88 00 &5720 22 88 44 22 88 ee 22 88 aa 22 44 00 44 44 00 44 &5730 44 00 44 44 00 44 22 00 22 11 00 22 11 00 11 00 &5740 88 11 00 44 11 00 44 22 00 88 22 00 88 44 11 00 &5750 44 11 00 88 11 11 00 00 99 00 00 44 88 00 22 44 &5760 00 22 44 00 44 88 00 55 00 00 22 00 00 22 00 00 ; spirit_mask &5770 ff 11 ff ee ee ff dd ff 77 dd ff 77 bb ff bb bb &5780 ff bb bb ff bb 77 55 dd 77 55 dd 77 ff dd 77 ff &5790 dd 77 bb dd 77 11 dd 77 55 dd bb ff bb bb ff bb &57a0 bb ff bb bb ff bb dd ff dd ee ff dd ee ff ee ff &57b0 77 ee ff bb ee ff bb dd ff 77 dd ff 77 bb ee ff &57c0 bb ee ff 77 ee ee ff ff 66 ff ff bb 77 ff dd bb &57d0 ff dd bb ff bb 77 ff aa ff ff dd ff ff dd ff 00 ; unused &57e0 77 ee 00 77 ee 00 77 ff 00 77 ff 00 77 ff 22 00 &57f0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 53 ; elixir ; ffff2b00 ffff2b00 0870 # ffff2b00 ffff2b00 0980 in PIAS version ; update_iron_pills_right # Room &0a &2b00 a5 65 LDA &65 ; replot_update # Negative if replotting room &2b02 f0 0b BEQ &2b0f ; consider_moving_iron_pill &2b04 a9 28 LDA #&28 ; &2800 = iron_pill_sprite_zero &2b06 8d d2 41 STA &41d2 ; enemy_sprite_address_high &2b09 8d cf 41 STA &41cf ; enemy_mask_address_high &2b0c 4c 8b 35 JMP &358b ; to_plot_enemy ; consider_moving_iron_pill &2b0f ac 7a 0c LDY &0c7a ; objects_collected + &02 (OBJECT_STRONG_MAGNET) &2b12 c0 01 CPY #&01 # One if magnet has already affected pills &2b14 f0 55 BEQ &2b6b ; to_finished_updating_room &2b16 a5 91 LDA &91 ; player_y &2b18 c9 6c CMP #&6c &2b1a 90 11 BCC &2b2d ; update_active_iron_pill &2b1c c9 e6 CMP #&e6 &2b1e 90 13 BCC &2b33 ; update_iron_pill &2b20 a5 9d LDA &9d ; player_clipping # Zero if player is not climbing or falling into room &2b22 f0 09 BEQ &2b2d ; update_active_iron_pill &2b24 98 TYA &2b25 d0 06 BNE &2b2d ; update_active_iron_pill &2b27 20 3b 44 JSR &443b ; play_chime &2b2a ee 7a 0c INC &0c7a ; objects_collected + &02 (OBJECT_STRONG_MAGNET) # Set to one to indicate magnet has been used ; update_active_iron_pill &2b2d a5 52 LDA &52 ; enemy_x &2b2f c9 4a CMP #&4a &2b31 f0 38 BEQ &2b6b ; to_finished_updating_room ; update_iron_pill &2b33 20 f3 2b JSR &2bf3 ; check_for_iron_pill_collision # Returns negative if iron pill collided with player &2b36 30 28 BMI &2b60 ; iron_pill_killed_player &2b38 a5 52 LDA &52 ; enemy_x &2b3a c9 4e CMP #&4e &2b3c 90 0b BCC &2b49 ; move_iron_pill_left &2b3e c9 99 CMP #&99 &2b40 b0 12 BCS &2b54 ; new_iron_pill_moving_left ; move_iron_pill_right &2b42 20 6e 2b JSR &2b6e ; bounce_iron_pill &2b45 e6 52 INC &52 ; enemy_x &2b47 d0 22 BNE &2b6b ; to_finished_updating_room # Always branches ; move_iron_pill_left &2b49 a5 52 LDA &52 ; enemy_x &2b4b f0 0d BEQ &2b5a ; new_iron_pill_moving_right &2b4d 20 6e 2b JSR &2b6e ; bounce_iron_pill &2b50 c6 52 DEC &52 ; enemy_x &2b52 10 17 BPL &2b6b ; to_finished_updating_room ; new_iron_pill_moving_left &2b54 a9 49 LDA #&49 &2b56 85 52 STA &52 ; enemy_x &2b58 d0 11 BNE &2b6b ; to_finished_updating_room ; new_iron_pill_moving_right &2b5a a9 56 LDA #&56 &2b5c 85 52 STA &52 ; enemy_x &2b5e d0 0b BNE &2b6b ; to_finished_updating_room ; iron_pill_killed_player &2b60 20 3b 45 JSR &453b ; replot_enemy_and_reset_freefall &2b63 a9 d2 LDA #&d2 ; FREEFALL_START &2b65 85 4e STA &4e ; jump_or_fall_timer # Kill player (touching iron pill) &2b67 a9 c5 LDA #&c5 &2b69 85 91 STA &91 ; player_y ; to_finished_updating_room &2b6b 4c 3a 30 JMP &303a ; finished_updating_room ; bounce_iron_pill &2b6e a5 52 LDA &52 ; enemy_x &2b70 29 0f AND #&0f &2b72 aa TAX &2b73 bd db 2b LDA &2bdb,X ; iron_pill_y_table &2b76 85 53 STA &53 ; enemy_y &2b78 c9 e9 CMP #&e9 &2b7a d0 07 BNE &2b83 ; skip_sound &2b7c a0 2b LDY #&2b ; &2beb = sound_2beb &2b7e a2 eb LDX #&eb &2b80 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for bouncing iron pill ; skip_sound &2b83 4c 6c 41 JMP &416c ; replot_enemy ; update_iron_pills_left # Room &09 &2b86 a5 65 LDA &65 ; replot_update # Negative if replotting room &2b88 f0 22 BEQ &2bac ; consider_moving_iron_pill_in_left_room &2b8a a5 52 LDA &52 ; enemy_x &2b8c f0 1a BEQ &2ba8 ; remove_iron_pill &2b8e c9 32 CMP #&32 &2b90 d0 1a BNE &2bac ; consider_moving_iron_pill_in_left_room &2b92 a5 90 LDA &90 ; player_x &2b94 c9 8c CMP #&8c &2b96 90 10 BCC &2ba8 ; remove_iron_pill &2b98 a5 91 LDA &91 ; player_y &2b9a 10 0c BPL &2ba8 ; remove_iron_pill &2b9c 20 b1 43 JSR &43b1 ; rnd &2b9f 29 1f AND #&1f &2ba1 69 b4 ADC #&b4 ; set_enemy_x &2ba3 85 52 STA &52 ; enemy_x ; to_finished_updating_room &2ba5 4c 3a 30 JMP &303a ; finished_updating_room ; remove_iron_pill &2ba8 a9 00 LDA #&00 &2baa f0 f7 BEQ &2ba3 ; set_enemy_x # Always branches ; consider_moving_iron_pill_in_left_room &2bac ad 7a 0c LDA &0c7a ; objects_collected + &02 (OBJECT_STRONG_MAGNET) &2baf c9 01 CMP #&01 # One if magnet has been used &2bb1 f0 f2 BEQ &2ba5 ; to_finished_updating_room &2bb3 a5 52 LDA &52 ; enemy_x &2bb5 f0 ee BEQ &2ba5 ; to_finished_updating_room &2bb7 c9 99 CMP #&99 &2bb9 90 05 BCC &2bc0 ; move_visible_iron_pill &2bbb d0 1a BNE &2bd7 ; move_iron_pill_left_in_left_room &2bbd 20 a2 41 JSR &41a2 ; plot_enemy ; move_visible_iron_pill &2bc0 20 f3 2b JSR &2bf3 ; check_for_iron_pill_collision # Returns negative if iron pill collided with player &2bc3 30 9b BMI &2b60 ; iron_pill_killed_player &2bc5 c6 52 DEC &52 ; enemy_x &2bc7 a5 52 LDA &52 ; enemy_x &2bc9 c9 3a CMP #&3a &2bcb b0 04 BCS &2bd1 ; skip_resetting_pill &2bcd a9 98 LDA #&98 &2bcf 85 52 STA &52 ; enemy_x ; skip_resetting_pill &2bd1 20 6e 2b JSR &2b6e ; bounce_iron_pill &2bd4 4c 3a 30 JMP &303a ; finished_updating_room ; move_iron_pill_left_in_left_room &2bd7 c6 52 DEC &52 ; enemy_x &2bd9 d0 ca BNE &2ba5 ; to_finished_updating_room # Always branches ; iron_pill_y_table &2bdb e9 e8 e6 e2 dc d8 d6 d5 d5 d6 d8 dc e2 e6 e8 e9 ; sound_2beb # Bouncing iron pill ; chan vol pitch dur &2beb 02 00 0b 00 b4 00 01 00 ; check_for_iron_pill_collision &2bf3 a5 53 LDA &53 ; enemy_y &2bf5 38 SEC &2bf6 e5 91 SBC &91 ; player_y &2bf8 c9 29 CMP #&29 &2bfa b0 14 BCS &2c10 ; leave_with_zero &2bfc a5 90 LDA &90 ; player_x &2bfe 38 SEC &2bff e5 52 SBC &52 ; enemy_x &2c01 90 07 BCC &2c0a ; check_x_max &2c03 c9 07 CMP #&07 &2c05 b0 09 BCS &2c10 ; leave_with_zero ; leave_with_negative &2c07 a9 ff LDA #&ff # Leave with negative to indicate collision with player &2c09 60 RTS ; check_x_max &2c0a 49 ff EOR #&ff &2c0c c9 0a CMP #&0a &2c0e 90 f7 BCC &2c07 ; leave_with_negative ; leave_with_zero &2c10 a9 00 LDA #&00 # Leave with positive to indicate no collision &2c12 60 RTS ; update_lipstick_missiles # Room &03 &2c13 a5 65 LDA &65 ; replot_update # Negative if replotting room &2c15 f0 55 BEQ &2c6c ; consider_firing_or_moving_lipstick_missile &2c17 a5 53 LDA &53 ; enemy_y &2c19 c9 c8 CMP #&c8 &2c1b d0 1c BNE &2c39 ; skip_initialising_lipstick_missiles &2c1d a9 28 LDA #&28 ; &2870 = lipstick_missile_sprite, &2894 = lipstick_missile_mask &2c1f 8d d2 41 STA &41d2 ; enemy_sprite_address_high &2c22 8d cf 41 STA &41cf ; enemy_mask_address_high ; initialise_lipstick_missiles &2c25 a2 24 LDX #&24 ; &5424 = sound_5424 &2c27 a0 54 LDY #&54 &2c29 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for initialising lipstick missiles &2c2c a9 c8 LDA #&c8 &2c2e 85 53 STA &53 ; enemy_y &2c30 a2 04 LDX #&04 &2c32 a9 ff LDA #&ff ; initialise_lipstick_missiles_loop &2c34 95 45 STA &45,X ; lipstick_missiles_state # Set to negative to indicate missile present &2c36 ca DEX &2c37 10 fb BPL &2c34 ; initialise_lipstick_missiles_loop ; skip_initialising_lipstick_missiles &2c39 a5 53 LDA &53 ; enemy_y &2c3b 48 PHA ; enemy_y &2c3c a5 52 LDA &52 ; enemy_x &2c3e 48 PHA ; enemy_x &2c3f a9 c8 LDA #&c8 &2c41 85 53 STA &53 ; enemy_y &2c43 a9 4c LDA #&4c &2c45 85 52 STA &52 ; enemy_x &2c47 a2 05 LDX #&05 &2c49 86 5e STX &5e ; missile ; plot_lipstick_missiles_loop &2c4b c6 5e DEC &5e ; missile &2c4d 30 12 BMI &2c61 ; finished_plotting_missiles &2c4f a6 5e LDX &5e ; missile &2c51 b5 45 LDA &45,X ; lipstick_missiles_state &2c53 10 03 BPL &2c58 ; skip_plotting_missile &2c55 20 a2 41 JSR &41a2 ; plot_enemy ; skip_plotting_missile &2c58 a5 52 LDA &52 ; enemy_x &2c5a 38 SEC &2c5b e9 0c SBC #&0c &2c5d 85 52 STA &52 ; enemy_x &2c5f d0 ea BNE &2c4b ; plot_lipstick_missiles_loop # Always branches ; finished_plotting_missiles &2c61 68 PLA ; enemy_x &2c62 85 52 STA &52 ; enemy_x &2c64 85 50 STA &50 ; sprite_x &2c66 68 PLA ; enemy_y &2c67 85 53 STA &53 ; enemy_y ; to_finished_updating_room &2c69 4c 3a 30 JMP &303a ; finished_updating_room ; consider_firing_or_moving_lipstick_missile &2c6c a5 55 LDA &55 ; missile_active # Zero if missile is active &2c6e f0 30 BEQ &2ca0 ; move_lipstick_missile &2c70 a5 91 LDA &91 ; player_y &2c72 30 f5 BMI &2c69 ; finished_updating_room &2c74 a5 94 LDA &94 ; player_sprite &2c76 c9 1e CMP #&1e ; PLAYER_SPRITE_FALLING &2c78 f0 ef BEQ &2c69 ; finished_updating_room &2c7a 20 b1 43 JSR &43b1 ; rnd &2c7d 29 7f AND #&7f &2c7f c9 05 CMP #&05 # 1 in 128 chance of launched any given missile &2c81 b0 e6 BCS &2c69 ; finished_updating_room &2c83 aa TAX &2c84 b5 45 LDA &45,X ; lipstick_missiles_state # Zero if missile is not present &2c86 f0 e1 BEQ &2c69 ; finished_updating_room &2c88 a9 00 LDA #&00 &2c8a 95 45 STA &45,X ; lipstick_missiles_state # Set to zero to indicate missile not present &2c8c 85 55 STA &55 ; missile_active # Set to zero to indicate missile is active &2c8e a9 10 LDA #&10 &2c90 18 CLC ; calculate_missile_x_loop &2c91 69 0c ADC #&0c &2c93 ca DEX &2c94 10 fb BPL &2c91 ; calculate_missile_x_loop &2c96 85 52 STA &52 ; enemy_x &2c98 85 50 STA &50 ; sprite_x &2c9a a9 c8 LDA #&c8 &2c9c 85 51 STA &51 ; sprite_y &2c9e 30 c9 BMI &2c69 ; finished_updating_room # Always branches ; move_lipstick_missile &2ca0 a5 53 LDA &53 ; enemy_y &2ca2 c9 c8 CMP #&c8 &2ca4 d0 07 BNE &2cad ; skip_playing_sound &2ca6 a2 48 LDX #&48 ; &5448 = sound_5448 &2ca8 a0 54 LDY #&54 &2caa 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for firing missile ; skip_playing_sound &2cad a5 53 LDA &53 ; enemy_y &2caf 38 SEC &2cb0 e9 04 SBC #&04 &2cb2 85 53 STA &53 ; enemy_y &2cb4 90 3c BCC &2cf2 ; remove_missile_at_top_of_screen &2cb6 20 6c 41 JSR &416c ; replot_enemy &2cb9 a5 91 LDA &91 ; player_y &2cbb 38 SEC &2cbc e5 53 SBC &53 ; enemy_y &2cbe 90 06 BCC &2cc6 ; check_y_max &2cc0 c9 12 CMP #&12 &2cc2 90 08 BCC &2ccc ; check_x_min &2cc4 b0 a3 BCS &2c69 ; finished_updating_room # Always branches ; check_y_max &2cc6 49 ff EOR #&ff &2cc8 c9 29 CMP #&29 &2cca b0 9d BCS &2c69 ; finished_updating_room ; check_x_min &2ccc a5 90 LDA &90 ; player_x &2cce 38 SEC &2ccf e5 52 SBC &52 ; enemy_x &2cd1 90 06 BCC &2cd9 ; check_x_max &2cd3 c9 06 CMP #&06 &2cd5 b0 92 BCS &2c69 ; finished_updating_room &2cd7 90 06 BCC &2cdf ; missile_hit_player # Always branches ; check_x_max &2cd9 49 ff EOR #&ff &2cdb c9 0a CMP #&0a &2cdd b0 8a BCS &2c69 ; finished_updating_room ; missile_hit_player &2cdf a5 52 LDA &52 ; enemy_x &2ce1 85 90 STA &90 ; player_x &2ce3 a5 53 LDA &53 ; enemy_y &2ce5 09 01 ORA #&01 &2ce7 85 91 STA &91 ; player_y &2ce9 a9 d2 LDA #&d2 ; FREEFALL_START &2ceb 85 4e STA &4e ; jump_or_fall_timer # Kill player (touching lipstick missile) &2ced c6 55 DEC &55 ; missile_active ; to_finished_updating_room &2cef 4c 69 2c JMP &2c69 ; finished_updating_room ; remove_missile_at_top_of_screen &2cf2 20 12 2d JSR &2d12 ; unplot_missile &2cf5 a9 c8 LDA #&c8 &2cf7 85 53 STA &53 ; enemy_y &2cf9 c6 55 DEC &55 ; missile_active # Set to non-zero to indicate no missile active &2cfb a2 04 LDX #&04 &2cfd a9 00 LDA #&00 ; check_for_remaining_missiles_loop &2cff 15 45 ORA &45,X ; lipstick_missiles_state &2d01 ca DEX &2d02 10 fb BPL &2cff ; check_for_remaining_missiles_loop &2d04 a8 TAY &2d05 d0 e8 BNE &2cef ; finished_updating_room &2d07 4c 25 2c JMP &2c25 ; initialise_lipstick_missiles ; sound_2d0a # Unused ; chan vol pitch dur &2d0a 00 00 f1 ff 04 00 06 00 ; unplot_missile &2d12 a9 18 LDA #&18 &2d14 85 57 STA &57 ; missile_y ; unplot_missile_group_loop &2d16 a5 57 LDA &57 ; missile_y &2d18 38 SEC &2d19 e9 08 SBC #&08 &2d1b b0 01 BCS &2d1e ; unplot_missile_group &2d1d 60 RTS ; unplot_missile_group &2d1e 85 57 STA &57 ; missile_y &2d20 85 81 STA &81 ; y &2d22 a6 52 LDX &52 ; enemy_x &2d24 20 99 3c JSR &3c99 ; calculate_screen_address_from_X_and_y &2d27 a9 00 LDA #&00 &2d29 a2 08 LDX #&08 ; unplot_missile_row_loop &2d2b a0 00 LDY #&00 &2d2d 91 78 STA (&78),Y ; screen_address &2d2f a0 08 LDY #&08 &2d31 91 78 STA (&78),Y ; screen_address &2d33 e6 78 INC &78 ; screen_address_low &2d35 ca DEX &2d36 f0 de BEQ &2d16 ; unplot_missile_group_loop &2d38 d0 f1 BNE &2d2b ; unplot_missile_row_loop # Always branches ; update_gas_tap # Room &0b &2d3a a5 65 LDA &65 ; replot_update # Negative if replotting room &2d3c f0 33 BEQ &2d71 ; check_tap_state &2d3e a9 00 LDA #&00 &2d40 85 66 STA &66 ; object_x &2d42 85 57 STA &57 ; tap_state # Set to zero to indicate tap not turned &2d44 ad 5b 0c LDA &0c5b ; room_flags + &0b &2d47 29 40 AND #&40 ; ROOM_FLAG_OBJECT # &40 clear if gas tap has been turned &2d49 f0 03 BEQ &2d4e ; extinguish_gas ; to_finished_updating_room &2d4b 4c 3a 30 JMP &303a ; finished_updating_room ; extinguish_gas &2d4e ad 5b 0c LDA &0c5b ; room_flags + &0b &2d51 09 40 ORA #&40 ; ROOM_FLAG_OBJECT # Unnecessary code &2d53 8d 5b 0c STA &0c5b ; room_flags + &0b &2d56 a9 95 LDA #&95 ; &2d95 = gas_tap_graphics_data &2d58 a0 2d LDY #&2d &2d5a 20 55 37 JSR &3755 ; plot_room_data_from_AY # Plot turned tap &2d5d a0 00 LDY #&00 &2d5f 84 66 STY &66 ; object_x &2d61 88 DEY ; &ff &2d62 84 57 STY &57 ; tap_state # Set to negative to indicate tap turned &2d64 8c 83 0c STY &0c83 ; objects_collected + &0b (OBJECT_GAS_TAP) # Unnecessary code &2d67 ad 5b 0c LDA &0c5b ; room_flags + &0b &2d6a 29 bf AND #&bf ; !ROOM_FLAG_OBJECT # Clear &40 to indicate gas tap has been turned &2d6c 8d 5b 0c STA &0c5b ; room_flags + &0b &2d6f d0 da BNE &2d4b ; to_finished_updating_room # Always branches ; check_tap_state &2d71 a5 57 LDA &57 ; tap_state # Negative if tap already turned &2d73 30 d6 BMI &2d4b ; to_finished_updating_room # If so, don't check for player touching tap &2d75 f0 04 BEQ &2d7b ; check_if_player_touching_tap # Always branches &2d77 c6 57 DEC &57 ; tap_state # Unnecessary code; would allow for tap to require &2d79 f0 d3 BEQ &2d4e ; extinguish_gas # multiple touches from player to turn off ; check_if_player_touching_tap &2d7b a5 91 LDA &91 ; player_y &2d7d c9 a7 CMP #&a7 &2d7f d0 ca BNE &2d4b ; to_finished_updating_room &2d81 a5 90 LDA &90 ; player_x &2d83 c9 60 CMP #&60 &2d85 90 c4 BCC &2d4b ; to_finished_updating_room &2d87 c9 6c CMP #&6c &2d89 b0 c0 BCS &2d4b ; to_finished_updating_room &2d8b a5 4e LDA &4e ; jump_or_fall_timer &2d8d d0 bc BNE &2d4b ; to_finished_updating_room &2d8f 20 3b 44 JSR &443b ; play_chime &2d92 4c 4e 2d JMP &2d4e ; extinguish_gas ; gas_tap_graphics_data &2d95 33 56 d0 ; object at x:&56, y:&d0, type &13 &2d98 29 5e d4 ; object at x:&5e, y:&d4, type &09 &2d9b 00 ; end of data ; update_degum # Room &13 &2d9c a5 91 LDA &91 ; player_y &2d9e c9 77 CMP #&77 &2da0 d0 14 BNE &2db6 ; player_not_touching_degum &2da2 a5 90 LDA &90 ; player_x &2da4 c9 4c CMP #&4c &2da6 90 0e BCC &2db6 ; player_not_touching_degum &2da8 c9 54 CMP #&54 &2daa b0 0a BCS &2db6 ; player_not_touching_degum &2dac ad 7c 0c LDA &0c7c ; objects_collected + &04 (OBJECT_ACID_PROOF_PLASTER) &2daf d0 05 BNE &2db6 ; player_not_touching_degum &2db1 a9 01 LDA #&01 # Set to one to indicate plaster removed &2db3 8d 7c 0c STA &0c7c ; objects_collected + &04 (OBJECT_ACID_PROOF_PLASTER) ; player_not_touching_degum &2db6 4c 3a 30 JMP &303a ; finished_updating_room ; update_dripping_acid # Room &1b &2db9 a5 65 LDA &65 ; replot_update # Negative if replotting room &2dbb f0 0f BEQ &2dcc ; skip_initialising_acid &2dbd a9 28 LDA #&28 ; &28b8 = drip_sprite, &28d2 = drip_mask &2dbf 8d d2 41 STA &41d2 ; enemy_sprite_address_high &2dc2 8d cf 41 STA &41cf ; enemy_mask_address_high &2dc5 20 a2 41 JSR &41a2 ; plot_enemy &2dc8 a9 00 LDA #&00 &2dca 85 57 STA &57 ; drip_state ; skip_initialising_acid &2dcc 20 e3 2d JSR &2de3 ; move_drip_down_and_check_for_collision_with_player &2dcf a5 57 LDA &57 ; drip_state # Negative if drip hit player &2dd1 10 0d BPL &2de0 ; to_finished_updating_room &2dd3 ad 7c 0c LDA &0c7c ; objects_collected + &04 (OBJECT_ACID_PROOF_PLASTER) &2dd6 f0 08 BEQ &2de0 ; to_finished_updating_room # Zero if player is carrying acid proof plaster &2dd8 a9 8f LDA #&8f &2dda 85 91 STA &91 ; player_y &2ddc a9 d2 LDA #&d2 ; FREEFALL_START &2dde 85 4e STA &4e ; jump_or_fall_timer # Kill player (touching acid) ; to_finished_updating_room &2de0 4c 3a 30 JMP &303a ; finished_updating_room ; move_drip_down_and_check_for_collision_with_player &2de3 a5 53 LDA &53 ; enemy_y &2de5 c9 a0 CMP #&a0 &2de7 90 11 BCC &2dfa ; not_at_floor &2de9 a9 01 LDA #&01 # Will become zero to indicate drip didn't hit player &2deb 85 57 STA &57 ; drip_state ; drip_hit_floor_or_player &2ded c6 57 DEC &57 ; drip_state # Set to negative if drip hit player &2def a0 54 LDY #&54 ; &542c = sound_542c &2df1 a2 2c LDX #&2c &2df3 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for drip hitting something &2df6 a9 37 LDA #&37 &2df8 85 53 STA &53 ; enemy_y ; not_at_floor &2dfa e6 53 INC &53 ; enemy_y # Move drip down &2dfc e6 53 INC &53 ; enemy_y &2dfe e6 53 INC &53 ; enemy_y ; check_drip_x_min &2e00 a5 90 LDA &90 ; player_x &2e02 38 SEC &2e03 e5 52 SBC &52 ; enemy_x &2e05 90 12 BCC &2e19 ; check_drip_x_max &2e07 c9 0a CMP #&0a &2e09 b0 0b BCS &2e16 ; to_replot_enemy ; check_drip_y_min &2e0b a5 91 LDA &91 ; player_y &2e0d 38 SEC &2e0e e5 53 SBC &53 ; enemy_y &2e10 90 0f BCC &2e21 ; check_drip_y_max &2e12 c9 0f CMP #&0f &2e14 90 d7 BCC &2ded ; drip_hit_floor_or_player ; to_replot_enemy &2e16 4c 6c 41 JMP &416c ; replot_enemy ; check_drip_x_max &2e19 49 ff EOR #&ff &2e1b c9 0b CMP #&0b &2e1d b0 f7 BCS &2e16 ; to_replot_enemy &2e1f 90 ea BCC &2e0b ; check_drip_y_min # Always branches ; check_drip_y_max &2e21 49 ff EOR #&ff &2e23 c9 29 CMP #&29 &2e25 b0 ef BCS &2e16 ; to_replot_enemy &2e27 c6 57 DEC &57 ; drip_state # Will become negative to indicate drip hit player &2e29 a5 91 LDA &91 ; player_y &2e2b 69 28 ADC #&28 &2e2d 85 53 STA &53 ; enemy_y &2e2f d0 b2 BNE &2de3 ; move_drip_down_and_check_for_collision_with_player # Always branches ; update_flame # Room &0c &2e31 ad 5b 0c LDA &0c5b ; room_flags + &0b &2e34 29 40 AND #&40 ; ROOM_FLAG_OBJECT &2e36 f0 1f BEQ &2e57 ; to_finished_updating_room &2e38 a5 91 LDA &91 ; player_y &2e3a c9 3c CMP #&3c &2e3c 90 12 BCC &2e50 ; player_not_touching_flame &2e3e c9 8c CMP #&8c &2e40 b0 0e BCS &2e50 ; player_not_touching_flame &2e42 a5 90 LDA &90 ; player_x &2e44 c9 4d CMP #&4d &2e46 90 08 BCC &2e50 ; player_not_touching_flame &2e48 c9 5b CMP #&5b &2e4a b0 04 BCS &2e50 ; player_not_touching_flame &2e4c a9 d2 LDA #&d2 ; FREEFALL_START &2e4e 85 4e STA &4e ; jump_or_fall_timer # Kill player (touching flame) ; player_not_touching_flame &2e50 20 b1 43 JSR &43b1 ; rnd &2e53 29 03 AND #&03 &2e55 f0 03 BEQ &2e5a ; replot_flame ; to_finished_updating_room &2e57 4c 3a 30 JMP &303a ; finished_updating_room ; replot_flame &2e5a a5 52 LDA &52 ; flame_sprite_address_low &2e5c 49 d0 EOR #&d0 &2e5e 85 52 STA &52 ; flame_sprite_address_low &2e60 8d 58 36 STA &3658 ; object_sprite_address_low &2e63 a9 56 LDA #&56 ; &5660 = flame_one_sprite, &56b0 = flame_two_sprite &2e65 8d 59 36 STA &3659 ; object_sprite_address_high &2e68 a9 28 LDA #&28 &2e6a 85 8d STA &8d ; rows_remaining &2e6c a9 02 LDA #&02 &2e6e 85 8e STA &8e ; object_width &2e70 a2 54 LDX #&54 &2e72 a9 66 LDA #&66 &2e74 85 81 STA &81 ; y &2e76 20 4c 36 JSR &364c ; plot_object_using_y # Plot flame &2e79 f0 dc BEQ &2e57 ; to_finished_updating_room # Always branches ; update_balloon # Room &14 &2e7b a5 65 LDA &65 ; replot_update # Negative if replotting room &2e7d f0 0e BEQ &2e8d ; consider_popping_balloon &2e7f ad 64 0c LDA &0c64 ; room_flags + &14 &2e82 29 40 AND #&40 ; ROOM_FLAG_OBJECT &2e84 f0 46 BEQ &2ecc ; to_finished_updating_room &2e86 a9 f0 LDA #&f0 ; &2ef0 = balloon_graphics_data &2e88 a0 2e LDY #&2e &2e8a 4c fe 31 JMP &31fe ; to_plot_room_data_from_AY # Plot balloon ; consider_popping_balloon &2e8d ad 64 0c LDA &0c64 ; room_flags + &14 &2e90 29 40 AND #&40 ; ROOM_FLAG_OBJECT &2e92 f0 38 BEQ &2ecc ; to_finished_updating_room &2e94 ad 80 0c LDA &0c80 ; objects_collected + &08 (OBJECT_SHARP_PIN) &2e97 30 33 BMI &2ecc ; to_finished_updating_room &2e99 a5 91 LDA &91 ; player_y &2e9b c9 28 CMP #&28 &2e9d b0 2d BCS &2ecc ; to_finished_updating_room &2e9f a5 90 LDA &90 ; player_x &2ea1 c9 4b CMP #&4b &2ea3 90 27 BCC &2ecc ; to_finished_updating_room &2ea5 c9 7d CMP #&7d &2ea7 b0 23 BCS &2ecc ; to_finished_updating_room &2ea9 a0 10 LDY #&10 ; &10f6 = sound_10f6 &2eab 20 c6 3a JSR &3ac6 ; play_sound # Play sound for popping balloon &2eae 20 37 2f JSR &2f37 ; unplot_area_of_screen # Unplot balloon &2eb1 a9 01 LDA #&01 &2eb3 85 57 STA &57 ; area_width &2eb5 a9 11 LDA #&11 &2eb7 85 56 STA &56 ; area_height &2eb9 a9 50 LDA #&50 &2ebb 85 55 STA &55 ; area_y &2ebd a9 68 LDA #&68 &2ebf 85 54 STA &54 ; area_x &2ec1 20 37 2f JSR &2f37 ; unplot_area_of_screen # Unplot balloon knot &2ec4 ad 64 0c LDA &0c64 ; room_flags + &14 &2ec7 29 bf AND #&bf ; !ROOM_FLAG_OBJECT &2ec9 8d 64 0c STA &0c64 ; room_flags + &14 ; to_finished_updating_room &2ecc 4c 3a 30 JMP &303a ; finished_updating_room ; update_dripping_oil # Room &0d &2ecf a5 65 LDA &65 ; replot_update # Negative if replotting room &2ed1 f0 0f BEQ &2ee2 ; skip_initialising_oil &2ed3 a9 28 LDA #&28 ; &28b8 = drip_sprite, &28d2 = drip_mask &2ed5 8d d2 41 STA &41d2 ; enemy_sprite_address_high &2ed8 8d cf 41 STA &41cf ; enemy_mask_address_high &2edb 20 a2 41 JSR &41a2 ; plot_enemy &2ede a9 00 LDA #&00 &2ee0 85 57 STA &57 ; drip_state ; skip_initialising_oil &2ee2 20 e3 2d JSR &2de3 ; move_drip_down_and_check_for_collision_with_player &2ee5 a5 57 LDA &57 ; drip_state # Negative if drip hit player &2ee7 10 e3 BPL &2ecc ; to_finished_updating_room &2ee9 a9 00 LDA #&00 &2eeb 8d 90 0c STA &0c90 ; objects_collected + &18 (OBJECT_COVERING_OF_OIL) &2eee f0 dc BEQ &2ecc ; to_finished_updating_room # Always branches ; balloon_graphics_data &2ef0 5c da 50 ; shape at x:&5a, y:&50, type &1c &2ef3 1a 46 ; fill at y:&46, pattern &a &2ef5 2a 5c 51 ; object at x:&5c, y:&51, type &0a &2ef8 00 ; end of data ; update_vanishing_cream # Room &17 &2ef9 a5 91 LDA &91 ; player_y &2efb c9 92 CMP #&92 &2efd b0 0e BCS &2f0d ; consider_updating_vanishing_cream &2eff c9 3c CMP #&3c &2f01 90 0a BCC &2f0d ; consider_updating_vanishing_cream &2f03 a5 90 LDA &90 ; player_x &2f05 c9 4b CMP #&4b &2f07 90 04 BCC &2f0d ; consider_updating_vanishing_cream &2f09 c9 82 CMP #&82 &2f0b 90 1d BCC &2f2a ; to_finished_updating_room # Don't update vanishing cream in player in area ; consider_updating_vanishing_cream &2f0d c6 52 DEC &52 ; vanishing_cream_cooldown &2f0f d0 19 BNE &2f2a ; to_finished_updating_room &2f11 20 b1 43 JSR &43b1 ; rnd &2f14 09 20 ORA #&20 &2f16 85 52 STA &52 ; vanishing_cream_cooldown &2f18 a5 53 LDA &53 ; vanishing_cream_state # Positive if vanishing cream present &2f1a 30 11 BMI &2f2d ; plot_vanishing_cream &2f1c 20 37 2f JSR &2f37 ; unplot_area_of_screen ; toggle_vanishing_cream &2f1f a5 53 LDA &53 ; vanishing_cream_state &2f21 49 ff EOR #&ff # Toggle presence &2f23 85 53 STA &53 ; vanishing_cream_state &2f25 a0 29 LDY #&29 ; &29f6 = sound_29f6 &2f27 20 c6 3a JSR &3ac6 ; play_sound # Play sound for vanishing cream ; to_finished_updating_room &2f2a 4c 3a 30 JMP &303a ; finished_updating_room ; plot_vanishing_cream &2f2d a9 6a LDA #&6a ; &2f6a = vanishing_cream_graphics_data &2f2f a0 2f LDY #&2f &2f31 20 55 37 JSR &3755 ; plot_room_data_from_AY &2f34 4c 1f 2f JMP &2f1f ; toggle_vanishing_cream ; unplot_area_of_screen &2f37 a6 54 LDX &54 ; area_x &2f39 a4 55 LDY &55 ; area_y &2f3b 20 97 3c JSR &3c97 ; calculate_screen_address_from_X_Y &2f3e a5 56 LDA &56 ; area_height &2f40 85 8d STA &8d ; rows_remaining ; unplot_area_of_screen_row_loop &2f42 a0 00 LDY #&00 &2f44 a5 57 LDA &57 ; area_width &2f46 85 8f STA &8f ; columns_remaining ; unplot_area_of_screen_column_loop &2f48 a9 00 LDA #&00 &2f4a 91 78 STA (&78),Y ; screen_address &2f4c c6 8f DEC &8f ; columns_remaining &2f4e f0 06 BEQ &2f56 ; consider_unplotting_next_row &2f50 98 TYA &2f51 69 08 ADC #&08 # Move right four pixels &2f53 a8 TAY &2f54 90 f2 BCC &2f48 ; unplot_area_of_screen_column_loop # Always branches ; consider_unplotting_next_row &2f56 c6 8d DEC &8d ; rows_remaining &2f58 f0 0f BEQ &2f69 ; leave &2f5a e6 81 INC &81 ; y &2f5c e6 78 INC &78 ; screen_address_low &2f5e a5 78 LDA &78 ; screen_address_low &2f60 29 07 AND #&07 &2f62 d0 de BNE &2f42 ; unplot_area_of_screen_row_loop &2f64 20 a4 3c JSR &3ca4 ; recalculate_screen_address_using_y &2f67 90 d9 BCC &2f42 ; unplot_area_of_screen_row_loop ; leave &2f69 60 RTS ; vanishing_cream_graphics_data &2f6a 62 dc 8f ; shape at x:&5c, y:&8f, type &22 &2f6d 1d 8c ; fill at y:&8c, pattern &d &2f6f 15 6e ; fill at y:&6e, pattern &5 &2f71 3c 50 77 ; object at x:&50, y:&77, type &1c &2f74 00 ; end of data ; update_darkroom_entrance # Room &19 &2f75 a5 91 LDA &91 ; player_y &2f77 c9 11 CMP #&11 &2f79 d0 49 BNE &2fc4 ; to_finished_updating_room &2f7b a5 90 LDA &90 ; player_x &2f7d 29 fc AND #&fc &2f7f c9 64 CMP #&64 # Is the player at the keyhole? &2f81 d0 41 BNE &2fc4 ; to_finished_updating_room &2f83 ad 90 0c LDA &0c90 ; objects_collected + &18 (OBJECT_COVERING_OF_OIL) &2f86 d0 3c BNE &2fc4 ; to_finished_updating_room # Zero if player has covering of oil &2f88 20 3b 44 JSR &443b ; play_chime &2f8b a9 21 LDA #&21 &2f8d 85 8b STA &8b ; player_room # Move player into darkroom &2f8f 4c e1 44 JMP &44e1 ; new_room ; update_thread # Room &08 &2f92 a5 65 LDA &65 ; replot_update # Negative if replotting room &2f94 10 0c BPL &2fa2 ; check_if_adding_thread &2f96 ad 88 0c LDA &0c88 ; objects_collected + &10 (OBJECT_LENGTH_OF_THREAD) &2f99 30 07 BMI &2fa2 ; check_if_adding_thread &2f9b f0 05 BEQ &2fa2 ; check_if_adding_thread # One if thread has been hung &2f9d 20 c7 2f JSR &2fc7 ; plot_thread &2fa0 f0 22 BEQ &2fc4 ; to_finished_updating_room # Always branches ; check_if_adding_thread &2fa2 a5 90 LDA &90 ; player_x &2fa4 c9 14 CMP #&14 &2fa6 d0 1c BNE &2fc4 ; to_finished_updating_room &2fa8 a5 91 LDA &91 ; player_y &2faa c9 10 CMP #&10 &2fac b0 16 BCS &2fc4 ; to_finished_updating_room &2fae ad 88 0c LDA &0c88 ; objects_collected + &10 (OBJECT_LENGTH_OF_THREAD) &2fb1 d0 11 BNE &2fc4 ; to_finished_updating_room # Zero if player is carrying thread &2fb3 20 3b 44 JSR &443b ; play_chime &2fb6 20 41 3c JSR &3c41 ; unplot_player &2fb9 20 c7 2f JSR &2fc7 ; plot_thread &2fbc 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting &2fbf a9 01 LDA #&01 # Set to one to indicate thread has been hung &2fc1 8d 88 0c STA &0c88 ; objects_collected + &10 (OBJECT_LENGTH_OF_THREAD) ; to_finished_updating_room &2fc4 4c 3a 30 JMP &303a ; finished_updating_room ; plot_thread &2fc7 a9 ce LDA #&ce ; &2fce = thread_graphics_data &2fc9 a0 2f LDY #&2f &2fcb 4c 55 37 JMP &3755 ; plot_room_data_from_AY ; thread_graphics_data &2fce 68 89 aa ; shape at x:&09, y:&aa, type &28 &2fd1 00 ; end of data ; update_clock # Room &11 &2fd2 a9 00 LDA #&00 &2fd4 85 66 STA &66 ; object_x &2fd6 ad 61 0c LDA &0c61 ; room_flags + &11 # Top bit clear if clock has been stopped &2fd9 30 08 BMI &2fe3 ; check_if_stopping_clock &2fdb a5 65 LDA &65 ; replot_update # Negative if replotting room &2fdd f0 5b BEQ &303a ; finished_updating_room &2fdf a6 4d LDX &4d ; fixed_clock_position &2fe1 10 3e BPL &3021 ; plot_clock_hand ; check_if_stopping_clock &2fe3 a5 90 LDA &90 ; player_x &2fe5 29 fc AND #&fc &2fe7 c9 2c CMP #&2c &2fe9 d0 0d BNE &2ff8 ; not_stopping_clock &2feb a5 91 LDA &91 ; player_y &2fed c9 0d CMP #&0d &2fef d0 07 BNE &2ff8 ; not_stopping_clock &2ff1 a5 4e LDA &4e ; jump_or_fall_timer &2ff3 d0 03 BNE &2ff8 ; not_stopping_clock &2ff5 20 62 44 JSR &4462 ; stop_clock ; not_stopping_clock &2ff8 c6 54 DEC &54 ; clock_cooldown &2ffa d0 3e BNE &303a ; finished_updating_room &2ffc a9 19 LDA #&19 &2ffe 85 54 STA &54 ; clock_cooldown &3000 a5 52 LDA &52 ; clock_hand_x &3002 8d 3c 54 STA &543c ; unplot_clock_hand_string + 8 &3005 a5 53 LDA &53 ; clock_hand_y &3007 8d 3e 54 STA &543e ; unplot_clock_hand_string + 10 &300a a9 34 LDA #&34 ; &5434 = unplot_clock_hand_string &300c a0 54 LDY #&54 &300e a2 0c LDX #&0c &3010 20 4b 39 JSR &394b ; write_string &3013 20 99 43 JSR &4399 ; play_clock_sound &3016 a6 55 LDX &55 ; clock_position &3018 e8 INX &3019 e0 0c CPX #&0c &301b 90 02 BCC &301f ; skip_wraparound &301d a2 00 LDX #&00 ; skip_wraparound &301f 86 55 STX &55 ; clock_position ; plot_clock_hand &3021 bd 8a 43 LDA &438a,X ; clock_coordinates &3024 8d 20 54 STA &5420 ; plot_clock_hand_string + 8 &3027 85 52 STA &52 ; clock_hand_x &3029 bd 8d 43 LDA &438d,X ; clock_coordinates + 3 &302c 8d 22 54 STA &5422 ; plot_clock_hand_string + 10 &302f 85 53 STA &53 ; clock_hand_y &3031 a9 18 LDA #&18 ; &5418 = plot_clock_hand_string &3033 a0 54 LDY #&54 &3035 a2 0c LDX #&0c &3037 20 4b 39 JSR &394b ; write_string ; finished_updating_room &303a a5 65 LDA &65 ; replot_update # Negative if replotting room &303c f0 05 BEQ &3043 ; to_main_game_loop &303e a9 00 LDA #&00 &3040 85 65 STA &65 ; replot_update # Set to positive to indicate room not being replotted &3042 60 RTS ; to_main_game_loop &3043 4c 08 43 JMP &4308 ; main_game_loop ; update_pin # Room &17 &3046 a5 65 LDA &65 ; replot_update # Negative if replotting room &3048 f0 0b BEQ &3055 ; consider_attracting_pin &304a ad 67 0c LDA &0c67 ; room_flags + &17 # Top bit clear if pin has been attracted to magnet &304d 30 03 BMI &3052 ; to_finished_updating_room &304f 20 89 30 JSR &3089 ; plot_pin_on_magnet ; to_finished_updating_room &3052 4c 3a 30 JMP &303a ; finished_updating_room ; consider_attracting_pin &3055 ad 67 0c LDA &0c67 ; room_flags + &17 # Top bit clear if pin has been attracted to magnet &3058 10 f8 BPL &3052 ; to_finished_updating_room &305a a5 91 LDA &91 ; player_y &305c c9 14 CMP #&14 &305e b0 f2 BCS &3052 ; to_finished_updating_room &3060 a5 90 LDA &90 ; player_x &3062 c9 37 CMP #&37 &3064 90 ec BCC &3052 ; to_finished_updating_room &3066 c9 45 CMP #&45 &3068 b0 e8 BCS &3052 ; to_finished_updating_room &306a ad 80 0c LDA &0c80 ; objects_collected + &08 (OBJECT_SHARP_PIN) &306d d0 e3 BNE &3052 ; to_finished_updating_room &306f ee 80 0c INC &0c80 ; objects_collected + &08 (OBJECT_SHARP_PIN) &3072 ad 67 0c LDA &0c67 ; room_flags + &17 &3075 29 7f AND #&7f ; !ROOM_FLAG_SPECIAL # Clear top bit to indicate pin has been attracted to magnet &3077 8d 67 0c STA &0c67 ; room_flags + &17 &307a 20 3b 44 JSR &443b ; play_chime &307d 20 41 3c JSR &3c41 ; unplot_player &3080 20 89 30 JSR &3089 ; plot_pin_on_magnet &3083 20 a0 3a JSR &3aa0 ; replot_player_without_unplotting &3086 4c 3a 30 JMP &303a ; finished_updating_room ; plot_pin_on_magnet &3089 a9 90 LDA #&90 ; &3090 = pin_on_magnet_graphics_data &308b a0 30 LDY #&30 &308d 4c 55 37 JMP &3755 ; plot_room_data_from_AY ; pin_on_magnet_graphics_data &3090 32 32 07 ; object at x:&32, y:&07, type &12 &3093 00 ; end of data ; update_water_tank # Room &26 &3094 a5 65 LDA &65 ; replot_update # Negative if replotting room &3096 f0 26 BEQ &30be ; skip_plotting &3098 ad 92 0c LDA &0c92 ; water_tank_state &309b c9 ff CMP #&ff &309d d0 06 BNE &30a5 ; set_water_tank_lid_y &309f a5 64 LDA &64 ; room_initialised # Zero if room is being initialised &30a1 d0 05 BNE &30a8 ; skip_initialising_water_tank &30a3 a9 37 LDA #&37 ; set_water_tank_lid_y &30a5 8d 48 31 STA &3148 ; water_tank_lid_graphics_data + 2 ; skip_initialising_water_tank &30a8 20 77 31 JSR &3177 ; move_water_tank_lid &30ab a9 40 LDA #&40 ; &3140 = water_tank_water_and_hole_graphics_data &30ad a0 31 LDY #&31 &30af 20 55 37 JSR &3755 ; plot_room_data_from_AY &30b2 ad 76 0c LDA &0c76 ; room_data + &26 &30b5 10 7a BPL &3131 ; plot_water_tank_stopper &30b7 20 50 31 JSR &3150 ; plot_stream_of_water &30ba b0 24 BCS &30e0 ; to_finished_updating_room &30bc 90 73 BCC &3131 ; plot_water_tank_stopper # Always branches ; skip_plotting &30be ad 76 0c LDA &0c76 ; room_data + &26 # Top bit clear if water tank has been stopped &30c1 10 1d BPL &30e0 ; to_finished_updating_room &30c3 c6 58 DEC &58 ; water_tank_cooldown &30c5 10 1c BPL &30e3 ; check_if_player_is_stopping_water &30c7 a9 14 LDA #&14 &30c9 85 58 STA &58 ; water_tank_cooldown &30cb 20 a0 31 JSR &31a0 ; check_if_player_is_supporting_lid # Returns negative if player is supporting lid &30ce 30 10 BMI &30e0 ; to_finished_updating_room &30d0 ad 48 31 LDA &3148 ; water_tank_lid_graphics_data + 2 &30d3 c9 ad CMP #&ad # Otherwise, if the tank isn't empty, &30d5 f0 2f BEQ &3106 ; stop_water_because_of_empty_tank &30d7 18 CLC &30d8 69 02 ADC #&02 # Move the lid down &30da 8d 48 31 STA &3148 ; water_tank_lid_graphics_data + 2 &30dd 20 77 31 JSR &3177 ; move_water_tank_lid ; to_finished_updating_room &30e0 4c 3a 30 JMP &303a ; finished_updating_room ; check_if_player_is_stopping_water &30e3 a5 90 LDA &90 ; player_x &30e5 c9 78 CMP #&78 &30e7 90 18 BCC &3101 ; not_stopping_water &30e9 c9 7d CMP #&7d &30eb b0 14 BCS &3101 ; not_stopping_water &30ed a5 91 LDA &91 ; player_y &30ef c9 b1 CMP #&b1 &30f1 d0 0e BNE &3101 ; not_stopping_water &30f3 a0 04 LDY #&04 ; OBJECT_ACID_PROOF_PLASTER &30f5 b9 78 0c LDA &0c78,Y ; objects_collected &30f8 f0 12 BEQ &310c ; stop_water_with_object &30fa a0 14 LDY #&14 ; OBJECT_CHEWING_GUM &30fc b9 78 0c LDA &0c78,Y ; objects_collected &30ff f0 0b BEQ &310c ; stop_water_with_object ; not_stopping_water &3101 20 50 31 JSR &3150 ; plot_stream_of_water &3104 b0 da BCS &30e0 ; to_finished_updating_room # Always branches ; stop_water_because_of_empty_tank &3106 20 8d 31 JSR &318d ; unplot_stream_of_water &3109 4c 3a 30 JMP &303a ; finished_updating_room ; stop_water_with_object &310c a9 01 LDA #&01 &310e 99 78 0c STA &0c78,Y ; objects_collected &3111 c0 04 CPY #&04 ; OBJECT_ACID_PROOF_PLASTER &3113 d0 03 BNE &3118 ; set_stopper_object &3115 a9 24 LDA #&24 # Use object type &04 &3117 2c a9 26 BIT &26a9 ; set_stopper_object #3118 LDA #&26 # Use obejct type &06 &311a 8d 4c 31 STA &314c ; water_tank_stopper_graphics_data &311d 20 3b 44 JSR &443b ; play_chime &3120 ad 76 0c LDA &0c76 ; room_data + &26 &3123 29 7f AND #&7f ; !ROOM_FLAG_SPECIAL # Clear top bit to indicate water tank has been stopped &3125 8d 76 0c STA &0c76 ; room_data + &26 &3128 ad 48 31 LDA &3148 ; water_tank_lid_graphics_data + 2 (shape y) &312b 8d 92 0c STA &0c92 ; water_tank_state &312e 20 8d 31 JSR &318d ; unplot_stream_of_water ; plot_water_tank_stopper &3131 a9 00 LDA #&00 &3133 85 66 STA &66 ; object_x &3135 a9 4c LDA #&4c ; &314c = water_tank_stopper_graphics_data &3137 a0 31 LDY #&31 &3139 4c fe 31 JMP &31fe ; to_plot_room_data_from_AY ; stream_of_water_graphics_data &313c 2b 68 b0 ; object at x:&68, y:&b0, type &0b &313f 00 ; end of data ; water_tank_water_and_hole_graphics_data &3140 14 b0 ; fill at y:&b0, pattern &4 &3142 7f e7 b1 ; shape at x:&67, y:&b1, type &3f &3145 00 ; end of data ; water_tank_lid_graphics_data &3146 70 d9 37 ; shape at x:&59, y:&37, type &30 &3149 12 36 ; fill at y:&36, pattern &2 &314b 00 ; end of data ; water_tank_stopper_graphics_data &314c 24 68 aa ; object at x:&68, y:&aa, type &04 &314f 00 ; end of data ; plot_stream_of_water &3150 ad 48 31 LDA &3148 ; water_tank_lid_graphics_data + 2 (shape y) &3153 c9 ad CMP #&ad &3155 f0 1f BEQ &3176 ; leave &3157 20 c4 31 JSR &31c4 ; play_sound_for_water &315a ad 3c 31 LDA &313c ; stream_of_water_graphics_data &315d 49 07 EOR #&07 &315f 8d 3c 31 STA &313c ; stream_of_water_graphics_data &3162 a9 b0 LDA #&b0 ; plot_stream_of_water_loop &3164 8d 3e 31 STA &313e ; stream_of_water_graphics_data + 2 (shape y) &3167 a9 3c LDA #&3c ; &313c = stream_of_water_graphics_data &3169 a0 31 LDY #&31 &316b 20 55 37 JSR &3755 ; plot_room_data_from_AY &316e ad 3e 31 LDA &313e ; stream_of_water_graphics_data + 2 (shape y) &3171 18 CLC &3172 69 10 ADC #&10 &3174 90 ee BCC &3164 ; plot_stream_of_water_loop ; leave &3176 60 RTS ; move_water_tank_lid &3177 ad 48 31 LDA &3148 ; water_tank_lid_graphics_data + 2 (shape y) &317a e9 02 SBC #&02 &317c 8d 4a 31 STA &314a ; water_tank_lid_graphics_data + 4 (fill y) &317f e9 08 SBC #&08 &3181 85 55 STA &55 ; lid_y &3183 20 37 2f JSR &2f37 ; unplot_area_of_screen &3186 a9 46 LDA #&46 ; &3146 = water_tank_lid_graphics_data &3188 a0 31 LDY #&31 &318a 4c 55 37 JMP &3755 ; plot_room_data_from_AY ; unplot_stream_of_water &318d a9 b2 LDA #&b2 &318f 85 55 STA &55 ; area_y &3191 a9 74 LDA #&74 &3193 85 54 STA &54 ; area_x &3195 a9 4e LDA #&4e &3197 85 56 STA &56 ; area_height &3199 a9 01 LDA #&01 &319b 85 57 STA &57 ; area_width &319d 4c 37 2f JMP &2f37 ; unplot_area_of_screen ; check_if_player_is_supporting_lid &31a0 a5 91 LDA &91 ; player_y &31a2 38 SEC &31a3 e5 55 SBC &55 ; lid_y &31a5 90 07 BCC &31ae ; check_y_max &31a7 c9 0e CMP #&0e &31a9 90 09 BCC &31b4 ; check_x_min ; leave_with_zero &31ab a9 00 LDA #&00 # Leave with positive to indicate player not supporting lid &31ad 60 RTS ; check_y_max &31ae 49 ff EOR #&ff &31b0 c9 25 CMP #&25 &31b2 b0 f7 BCS &31ab ; leave_with_zero ; check_x_min &31b4 a5 90 LDA &90 ; player_x &31b6 38 SEC &31b7 e9 7c SBC #&7c &31b9 b0 f0 BCS &31ab ; leave_with_zero ; check_x_max &31bb 49 ff EOR #&ff &31bd c9 36 CMP #&36 &31bf b0 ea BCS &31ab ; leave_with_zero &31c1 a9 ff LDA #&ff # Leave with negative to indicate player supporting lid &31c3 60 RTS ; play_sound_for_water &31c4 a2 f9 LDX #&f9 ; &fff9 = Sound output buffer 2 &31c6 a0 ff LDY #&ff &31c8 a9 80 LDA #&80 ; Read buffer status &31ca 20 f4 ff JSR &fff4 ; OSBYTE &31cd 8a TXA &31ce f0 a6 BEQ &3176 ; leave &31d0 20 b1 43 JSR &43b1 ; rnd &31d3 29 07 AND #&07 &31d5 69 d2 ADC #&d2 &31d7 8d e5 31 STA &31e5 ; sound_31e1 + 4 (pitch) &31da a2 e1 LDX #&e1 ; &31e1 = sound_31e1 &31dc a0 31 LDY #&31 &31de 4c c8 3a JMP &3ac8 ; play_sound_from_XY # Play sound for running water ; sound_31e1 # Running water ; chan vol pitch dur &31e1 02 00 0f 00 d2 00 02 00 ; update_spirit # Room &1d &31e9 a5 65 LDA &65 ; replot_update # Negative if replotting room &31eb f0 39 BEQ &3226 ; consider_moving_spirit &31ed a9 57 LDA #&57 ; &5700 = spirit_sprite, &5770 = spirit_mask &31ef 8d d2 41 STA &41d2 ; enemy_sprite_address_high &31f2 8d cf 41 STA &41cf ; enemy_mask_address_high &31f5 ad 6d 0c LDA &0c6d ; room_flags + &1d # Top bit clear if spirit bottle has been stopped &31f8 30 0a BMI &3204 ; initialise_spirit ; plot_spirit_stopper &31fa a9 de LDA #&de ; &32de = spirit_stopper_graphics_data &31fc a0 32 LDY #&32 ; to_plot_room_data_from_AY &31fe 20 55 37 JSR &3755 ; plot_room_data_from_AY ; to_finished_updating_room &3201 4c 3a 30 JMP &303a ; finished_updating_room ; initialise_spirit &3204 a5 53 LDA &53 ; enemy_y &3206 c9 8b CMP #&8b &3208 d0 f7 BNE &3201 ; to_finished_updating_room &320a a9 06 LDA #&06 &320c a4 91 LDY &91 ; player_y &320e c0 78 CPY #&78 &3210 90 02 BCC &3214 ; set_spirit_cooldown &3212 a9 7e LDA #&7e ; set_spirit_cooldown &3214 85 5e STA &5e ; spirit_cooldown &3216 85 5f STA &5f ; spirit_state # Set to non-zero to indicate spirit isn't visible &3218 a9 28 LDA #&28 ; play_spirit_sound &321a 8d da 32 STA &32da ; sound_32d6 + 4 (pitch) &321d a2 d6 LDX #&d6 ; &32d6 = sound_32d6 &321f a0 32 LDY #&32 &3221 20 c8 3a JSR &3ac8 ; play_sound_from_XY # Play sound for spirit &3224 d0 db BNE &3201 ; to_finished_updating_room # Always branches ; consider_moving_spirit &3226 ad 6d 0c LDA &0c6d ; room_flags + &1d # Top bit clear if spirit bottle has been stopped &3229 10 d6 BPL &3201 ; to_finished_updating_room &322b c6 5e DEC &5e ; spirit_cooldown &322d 30 1a BMI &3249 ; consider_playing_spirit_sound &322f f0 03 BEQ &3234 ; consider_making_spirit_visible &3231 4c b0 32 JMP &32b0 ; check_for_player_stopping_spirit ; consider_making_spirit_visible &3234 a5 5f LDA &5f ; spirit_state &3236 f0 0a BEQ &3242 ; is_visible &3238 85 5e STA &5e ; spirit_cooldown &323a a9 00 LDA #&00 &323c 85 5f STA &5f ; spirit_state # Set to zero to indicate spirit is visible &323e a9 40 LDA #&40 &3240 d0 d8 BNE &321a ; play_spirit_sound # Always branches ; is_visible &3242 20 a2 41 JSR &41a2 ; plot_enemy &3245 a9 50 LDA #&50 &3247 d0 d1 BNE &321a ; play_spirit_sound # Always branches ; consider_playing_spirit_sound &3249 a5 5e LDA &5e ; spirit_cooldown &324b c9 96 CMP #&96 &324d d0 0b BNE &325a ; skip_sound &324f a9 ff LDA #&ff &3251 85 5e STA &5e ; spirit_cooldown &3253 20 b1 43 JSR &43b1 ; rnd &3256 29 5f AND #&5f &3258 10 c0 BPL &321a ; play_spirit_sound # Always branches ; skip_sound &325a 20 b1 43 JSR &43b1 ; rnd &325d a6 53 LDX &53 ; enemy_y # Is the spirit below the player? &325f e4 91 CPX &91 ; player_y &3261 b0 3d BCS &32a0 ; move_spirit_generally_up ; move_spirit_generally_down &3263 c9 32 CMP #&32 # 40 in 128 chance to move down &3265 90 3d BCC &32a4 ; move_spirit_up ; move_spirit_down &3267 a5 53 LDA &53 ; enemy_y &3269 c9 d8 CMP #&d8 &326b b0 02 BCS &326f ; check_for_spirit_touching_player &326d e6 53 INC &53 ; enemy_y ; check_for_spirit_touching_player &326f a5 91 LDA &91 ; player_y &3271 38 SEC &3272 e5 53 SBC &53 ; enemy_y &3274 90 06 BCC &327c ; check_y_max &3276 c9 25 CMP #&25 &3278 90 08 BCC &3282 ; check_x_min &327a b0 1e BCS &329a ; not_touching_player # Always branches ; check_y_max &327c 49 ff EOR #&ff &327e c9 29 CMP #&29 &3280 b0 18 BCS &329a ; not_touching_player ; check_x_min &3282 a5 90 LDA &90 ; player_x &3284 38 SEC &3285 e5 52 SBC &52 ; enemy_x &3287 90 06 BCC &328f ; check_x_max &3289 c9 0a CMP #&0a &328b b0 0d BCS &329a ; not_touching_player &328d 90 06 BCC &3295 ; spirit_is_touching_player # Always branches ; check_x_max &328f 49 ff EOR #&ff &3291 c9 0a CMP #&0a &3293 b0 05 BCS &329a ; not_touching_player ; spirit_is_touching_player &3295 20 2c 42 JSR &422c ; start_player_freefalling &3298 f0 03 BEQ &329d ; to_finished_updating_room # Always branches ; not_touching_player &329a 20 6c 41 JSR &416c ; replot_enemy ; to_finished_updating_room &329d 4c 3a 30 JMP &303a ; finished_updating_room ; move_spirit_generally_up &32a0 c9 50 CMP #&50 # 80 in 128 chance to move up &32a2 90 c3 BCC &3267 ; move_spirit_down ; move_spirit_up &32a4 a5 53 LDA &53 ; enemy_y &32a6 c9 03 CMP #&03 &32a8 90 c5 BCC &326f ; check_for_spirit_touching_player &32aa c6 53 DEC &53 ; enemy_y &32ac c6 53 DEC &53 ; enemy_y &32ae d0 bf BNE &326f ; check_for_spirit_touching_player ; check_for_player_stopping_spirit &32b0 ad 7d 0c LDA &0c7d ; objects_collected + &05 (OBJECT_SPIRIT_STOPPER) &32b3 30 e8 BMI &329d ; to_finished_updating_room # Zero if spirit stopper has been collected &32b5 a5 91 LDA &91 ; player_y &32b7 c9 75 CMP #&75 &32b9 d0 e2 BNE &329d ; to_finished_updating_room &32bb a5 90 LDA &90 ; player_x &32bd c9 55 CMP #&55 &32bf 90 dc BCC &329d ; to_finished_updating_room &32c1 c9 61 CMP #&61 &32c3 b0 d8 BCS &329d ; to_finished_updating_room &32c5 ee 7d 0c INC &0c7d ; objects_collected + &05 (OBJECT_SPIRIT_STOPPER) &32c8 ad 6d 0c LDA &0c6d ; room_flags + &1d &32cb 29 7f AND #&7f ; !ROOM_FLAG_SPECIAL # Clear top bit to indicate spirit bottle has been stopped &32cd 8d 6d 0c STA &0c6d ; room_flags + &1d &32d0 20 3b 44 JSR &443b ; play_chime &32d3 4c fa 31 JMP &31fa ; plot_spirit_stopper ; sound_32d6 # Spirit ; chan vol pitch dur &32d6 02 00 0c 00 50 00 2d 00 ; spirit_stopper_graphics_data &32de 6f ce a5 ; shape at x:&4e, y:&a5, type &2f &32e1 1c a3 ; fill at y:&a3, pattern &c &32e3 15 a8 ; fill at y:&a8, pattern &5 &32e5 00 ; end of data ; update_darkroom_right # Room &21 &32e6 a5 65 LDA &65 ; replot_update # Negative if replotting room &32e8 f0 0c BEQ &32f6 ; consider_moving_circularsaurus &32ea a0 06 LDY #&06 ; &0600 = circularsaurus_sprite_zero &32ec 8c d2 41 STY &41d2 ; enemy_sprite_address_high &32ef c8 INY ; &0700 = circularsaurus_mask_zero &32f0 8c cf 41 STY &41cf ; enemy_mask_address_high &32f3 4c 8b 35 JMP &358b ; to_plot_enemy ; consider_moving_circularsaurus &32f6 a5 53 LDA &53 ; enemy_y &32f8 c9 b5 CMP #&b5 &32fa b0 06 BCS &3302 ; move_circularsaurus &32fc a5 90 LDA &90 ; player_x &32fe c9 7d CMP #&7d &3300 b0 24 BCS &3326 ; check_if_player_at_right_edge_or_keyhole ; move_circularsaurus &3302 a5 53 LDA &53 ; enemy_y &3304 c9 e4 CMP #&e4 &3306 b0 04 BCS &330c ; skip_fall &3308 e6 53 INC &53 ; enemy_y # Circularsaurus falls off platform &330a e6 53 INC &53 ; enemy_y ; skip_fall &330c a5 5e LDA &5e ; circularsaurus_direction &330e 18 CLC &330f 65 52 ADC &52 ; enemy_x &3311 85 52 STA &52 ; enemy_x &3313 c9 8a CMP #&8a &3315 b0 04 BCS &331b ; toggle_direction &3317 c9 02 CMP #&02 &3319 b0 06 BCS &3321 ; skip_toggling_direction ; toggle_direction &331b a5 5e LDA &5e ; circularsaurus_direction &331d 49 fe EOR #&fe &331f 85 5e STA &5e ; circularsaurus_direction ; skip_toggling_direction &3321 20 89 33 JSR &3389 ; check_for_circularsaurus_touching_player # Returns negative if circularsaurus touching player &3324 30 1d BMI &3343 ; circularsaurus_touched_player ; check_if_player_at_right_edge_or_keyhole &3326 a5 90 LDA &90 ; player_x &3328 c9 93 CMP #&93 &332a 90 02 BCC &332e ; not_at_right_edge &332c c6 90 DEC &90 ; player_x ; not_at_right_edge &332e c9 8c CMP #&8c # Is the player at the keyhole? &3330 b0 14 BCS &3346 ; to_finished_updating_room &3332 c9 88 CMP #&88 &3334 90 10 BCC &3346 ; to_finished_updating_room &3336 a5 91 LDA &91 ; player_y &3338 c9 c1 CMP #&c1 &333a d0 0a BNE &3346 ; to_finished_updating_room &333c a9 19 LDA #&19 &333e 85 8b STA &8b ; player_room # Move player out of darkroom &3340 4c e1 44 JMP &44e1 ; new_room ; circularsaurus_touched_player &3343 20 2c 42 JSR &422c ; start_player_freefalling # Kill player (touching circularsaurus) ; to_finished_updating_room &3346 4c 3a 30 JMP &303a ; finished_updating_room ; update_darkroom_left # Room &20 &3349 a5 65 LDA &65 ; replot_update # Negative if replotting room &334b f0 07 BEQ &3354 ; consider_appearing_or_moving_circularsaurus_in_left_room &334d a5 52 LDA &52 ; enemy_x &334f f0 f5 BEQ &3346 ; to_finished_updating_room &3351 4c 8b 35 JMP &358b ; to_plot_enemy ; consider_appearing_or_moving_circularsaurus_in_left_room &3354 a5 52 LDA &52 ; enemy_x &3356 d0 06 BNE &335e ; consider_moving_circularsaurus_in_left_room &3358 a5 90 LDA &90 ; player_x &335a c9 69 CMP #&69 &335c b0 e8 BCS &3346 ; to_finished_updating_room ; consider_moving_circularsaurus_in_left_room &335e a5 52 LDA &52 ; enemy_x &3360 d0 07 BNE &3369 ; move_circularsaurus_in_left_room &3362 a9 92 LDA #&92 &3364 85 52 STA &52 ; enemy_x &3366 4c 8b 35 JMP &358b ; to_plot_enemy ; move_circularsaurus_in_left_room &3369 a5 5e LDA &5e ; circularsaurus_direction &336b 18 CLC &336c 65 52 ADC &52 ; enemy_x &336e 85 52 STA &52 ; enemy_x # &3370 - &347b is missing from original version, present in PIAS version &3370 c5 5f CMP &5f ; circularsaurus_x_limit &3372 b0 04 BCS &3378 ; toggle_direction_in_left_room &3374 c9 24 CMP #&24 &3376 b0 0a BCS &3382 ; skip_toggling_direction_in_left_room ; toggle_direction_in_left_room &3378 a5 5e LDA &5e ; circularsaurus_direction &337a 49 fe EOR #&fe &337c 85 5e STA &5e ; circularsaurus_direction &337e a9 64 LDA #&64 &3380 85 5f STA &5f ; circularsaurus_x_limit ; skip_toggling_direction_in_left_room &3382 20 89 33 JSR &3389 ; check_for_circularsaurus_touching_player # Returns negative if circularsaurus touching player &3385 30 bc BMI &3343 ; circularsaurus_touched_player &3387 10 bd BPL &3346 ; to_finished_updating_room # Always branches ; check_for_circularsaurus_touching_player &3389 a5 91 LDA &91 ; player_y &338b 38 SEC &338c e5 53 SBC &53 ; enemy_y &338e 90 0a BCC &339a ; check_y_max &3390 c9 12 CMP #&12 &3392 90 0c BCC &33a0 ; check_x_min ; leave_with_zero &3394 20 6c 41 JSR &416c ; replot_enemy &3397 a9 00 LDA #&00 # Leave with positive to indicate not touching player &3399 60 RTS ; check_y_max &339a 49 ff EOR #&ff &339c c9 29 CMP #&29 &339e b0 f4 BCS &3394 ; leave_with_zero ; check_x_min &33a0 a5 90 LDA &90 ; player_x &33a2 38 SEC &33a3 e5 52 SBC &52 ; enemy_x &33a5 90 07 BCC &33ae ; check_x_max &33a7 c9 0f CMP #&0f &33a9 b0 e9 BCS &3394 ; leave_with_zero ; leave_with_negative &33ab a9 ff LDA #&ff # Leave with negative to indicate touching player &33ad 60 RTS ; check_x_max &33ae 49 ff EOR #&ff &33b0 c9 0b CMP #&0b &33b2 b0 e0 BCS &3394 ; leave_with_zero &33b4 90 f5 BCC &33ab ; leave_with_negative # Always branches ; update_agar # Room &1c &33b6 a5 65 LDA &65 ; replot_update # Negative if replotting room &33b8 f0 27 BEQ &33e1 ; consider_dropping_bean &33ba ad 93 0c LDA &0c93 ; beanstalk_has_been_planted # Negative if bean has not been dropped &33bd 30 1f BMI &33de ; to_finished_updating_room &33bf a9 00 LDA #&00 &33c1 8d 6a 61 STA &616a ; screen_memory + &180 * 6 + 8 * 14 + 2 # Remove part of line platform above agar &33c4 ae 94 0c LDX &0c94 ; beanstalk_height_in_lower_room &33c7 a9 7e LDA #&7e &33c9 20 4c 34 JSR &344c ; plot_beanstalk &33cc ad 94 0c LDA &0c94 ; beanstalk_height_in_lower_room &33cf c9 09 CMP #&09 &33d1 d0 0b BNE &33de ; to_finished_updating_room &33d3 a9 06 LDA #&06 &33d5 85 8d STA &8d ; rows_remaining &33d7 a2 50 LDX #&50 &33d9 a0 00 LDY #&00 &33db 20 4a 36 JSR &364a ; plot_object # Plot top of beanstalk exiting lower room ; to_finished_updating_room &33de 4c 3a 30 JMP &303a ; finished_updating_room ; consider_dropping_bean &33e1 ad 93 0c LDA &0c93 ; beanstalk_has_been_planted # Negative if bean has not been dropped &33e4 10 2e BPL &3414 ; bean_already_dropped ; check_for_player_dropping_bean_in_agar &33e6 a5 91 LDA &91 ; player_y &33e8 c9 11 CMP #&11 # Is the player over the agar? &33ea d0 f2 BNE &33de ; to_finished_updating_room &33ec a5 90 LDA &90 ; player_x &33ee c9 4b CMP #&4b &33f0 d0 ec BNE &33de ; to_finished_updating_room &33f2 ad 7b 0c LDA &0c7b ; objects_collected + &03 (OBJECT_MAGIC_BEAN) &33f5 d0 e7 BNE &33de ; to_finished_updating_room # Zero if bean has been collected ; drop_bean_in_agar &33f7 20 3b 44 JSR &443b ; play_chime &33fa ee 94 0c INC &0c94 ; beanstalk_height_in_lower_room &33fd a9 04 LDA #&04 &33ff 8d 96 0c STA &0c96 ; beanstalk_timer_high &3402 a9 ff LDA #&ff &3404 8d 7b 0c STA &0c7b ; objects_collected + &03 (OBJECT_MAGIC_BEAN) &3407 a9 01 LDA #&01 &3409 8d 93 0c STA &0c93 ; beanstalk_has_been_planted # Set to one to indicate bean is dropping &340c a9 3c LDA #&3c &340e 85 53 STA &53 ; enemy_y &3410 a9 4c LDA #&4c &3412 85 52 STA &52 ; enemy_x ; bean_already_dropped &3414 f0 c8 BEQ &33de ; to_finished_updating_room ; update_falling_bean &3416 a5 53 LDA &53 ; enemy_y &3418 c9 78 CMP #&78 &341a b0 1f BCS &343b ; bean_hits_agar &341c 85 81 STA &81 ; y &341e a9 30 LDA #&30 ; &2530 = object_sprite_03 # Magic bean ; plot_bean &3420 8d 58 36 STA &3658 ; object_sprite_address_low &3423 a9 25 LDA #&25 &3425 8d 59 36 STA &3659 ; object_sprite_address_high &3428 a6 52 LDX &52 ; enemy_x &342a a9 02 LDA #&02 &342c 85 8e STA &8e ; object_width &342e a9 08 LDA #&08 &3430 85 8d STA &8d ; rows_remaining &3432 20 4c 36 JSR &364c ; plot_object_using_y &3435 e6 53 INC &53 ; enemy_y # Bean falls &3437 e6 53 INC &53 ; enemy_y &3439 d0 a3 BNE &33de ; to_finished_updating_room # Always branches ; bean_hits_agar &343b a9 00 LDA #&00 &343d 8d 93 0c STA &0c93 ; beanstalk_has_been_planted # Set to zero to indicate bean has been dropped &3440 c6 53 DEC &53 ; enemy_y # Undo last fall &3442 c6 53 DEC &53 ; enemy_y &3444 a5 53 LDA &53 ; enemy_y &3446 85 81 STA &81 ; y &3448 a9 70 LDA #&70 ; &2570 = object_sprite_07 # Unplot bean &344a d0 d4 BNE &3420 ; plot_bean # Always branches ; plot_beanstalk &344c 86 3f STX &3f ; beanstalk_height_to_plot &344e 85 53 STA &53 ; enemy_y &3450 a9 f0 LDA #&f0 ; &25f0 = object_sprite_0f # Beanstalk body &3452 8d 58 36 STA &3658 ; object_sprite_address_low &3455 a9 25 LDA #&25 &3457 8d 59 36 STA &3659 ; object_sprite_address_high &345a a9 01 LDA #&01 &345c 85 8e STA &8e ; object_width ; plot_beanstalk_loop &345e a9 0c LDA #&0c &3460 85 8d STA &8d ; rows_remaining &3462 a2 50 LDX #&50 &3464 a5 53 LDA &53 ; enemy_y &3466 38 SEC &3467 e9 0c SBC #&0c &3469 85 53 STA &53 ; enemy_y &346b 85 81 STA &81 ; y &346d 20 4c 36 JSR &364c ; plot_object_using_y &3470 20 78 34 JSR &3478 ; plot_beanstalk_leaves &3473 c6 3f DEC &3f ; beanstalk_height_to_plot &3475 10 e7 BPL &345e ; plot_beanstalk_loop &3477 60 RTS ; plot_beanstalk_leaves &3478 a5 53 LDA &53 ; enemy_y &347a 18 CLC &347d 8d 52 54 STA &5452 ; beanstalk_leaves_graphics_data + 2 (shape y) ; D00 ; ffff0d00 ffff42de 0100 ; player_right_zero_sprite &0d00 00 00 00 11 88 00 33 cc 00 33 ee 00 77 ee 00 66 &0d10 22 00 55 ff 00 45 13 00 45 22 00 44 26 00 22 44 &0d20 00 33 88 00 22 44 00 22 44 00 44 22 00 44 22 00 &0d30 44 22 00 88 11 00 88 11 00 99 11 00 99 11 00 88 &0d40 99 00 88 11 00 88 11 00 67 19 00 55 dd 00 44 11 &0d50 00 44 11 00 44 11 00 44 11 00 44 11 00 77 ee 00 &0d60 23 66 00 22 5f 00 23 55 00 46 df 00 8d 9d 00 df &0d70 9b 00 ee 66 00 77 77 88 33 77 88 ; player_right_zero_mask &0d7b ff ff ff ee 77 ff cc 33 ff cc 11 ff 88 11 ff 88 &0d8b 11 ff 88 00 ff 88 00 ff 88 11 ff 88 11 ff cc 33 &0d9b ff cc 77 ff cc 33 ff cc 33 ff 88 11 ff 88 11 ff &0dab 88 11 ff 00 00 ff 00 00 ff 00 00 ff 00 00 ff 00 &0dbb 00 ff 00 00 ff 00 00 ff 88 00 ff 88 00 ff 88 00 &0dcb ff 88 00 ff 88 00 ff 88 00 ff 88 00 ff 88 11 ff &0ddb cc 11 ff cc 00 ff cc 00 ff 88 00 ff 00 00 ff 00 &0deb 00 ff 11 99 ff 88 88 77 cc 88 77 ; sound_0df6 # Player walking ; chan vol pitch dur &0df6 11 00 01 00 00 00 01 00 ; unused &0dfe 00 00