{"schema":1,"platform":"c64","game":"choplifter","title":"Choplifter","build":"cartridge image, CBM80 header at $8004, cold start $9593","symbols_sha256":"9ed0e00f5227503e57e05ad10d343ee559a7c485f230d349b154cd89d8cf851b","index":[{"a":0,"n":"cpu_ddr","k":"variable","len":1,"c":true},{"a":1,"n":"cpu_port","k":"variable","len":1,"c":true},{"a":2,"n":"msg_showing","k":"variable","len":1,"c":true},{"a":3,"n":"draw_row","k":"variable","len":1,"c":true},{"a":4,"n":"draw_x","k":"variable","len":1,"c":true},{"a":5,"n":"zpa_05","k":"variable","len":1,"c":true},{"a":6,"n":"bmp_ptr","k":"variable","len":1,"c":true},{"a":7,"n":"zpa_07","k":"variable","len":1,"c":true},{"a":8,"n":"draw_col","k":"variable","len":1,"c":true},{"a":9,"n":"draw_bit","k":"variable","len":1,"c":true},{"a":10,"n":"zpa_0A","k":"variable","len":1,"c":true},{"a":11,"n":"zpa_0B","k":"variable","len":1,"c":true},{"a":12,"n":"zpa_0C","k":"variable","len":1,"c":true},{"a":13,"n":"zpa_0D","k":"variable","len":1,"c":true},{"a":14,"n":"zpa_0E","k":"variable","len":1,"c":true},{"a":15,"n":"vic_bank_bit","k":"variable","len":1,"c":true},{"a":16,"n":"shape_w","k":"variable","len":1,"c":true},{"a":17,"n":"shape_h","k":"variable","len":1,"c":true},{"a":18,"n":"zpa_12","k":"variable","len":1,"c":true},{"a":19,"n":"zpa_13","k":"variable","len":1,"c":true},{"a":20,"n":"zpa_14","k":"variable","len":1,"c":true},{"a":21,"n":"zpa_15","k":"variable","len":1,"c":true},{"a":22,"n":"zpa_16","k":"variable","len":1,"c":true},{"a":23,"n":"shape_ptr","k":"variable","len":1,"c":true},{"a":24,"n":"zpa_18","k":"variable","len":1,"c":true},{"a":25,"n":"zpa_19","k":"variable","len":1,"c":true},{"a":26,"n":"zpa_1A","k":"variable","len":1,"c":true},{"a":27,"n":"inline_ret","k":"variable","len":1,"c":true},{"a":28,"n":"zpa_1C","k":"variable","len":1,"c":true},{"a":29,"n":"save_a","k":"variable","len":1,"c":true},{"a":30,"n":"save_x","k":"variable","len":1,"c":true},{"a":31,"n":"save_y","k":"variable","len":1,"c":true},{"a":32,"n":"resume_vec","k":"variable","len":1,"c":true},{"a":33,"n":"zpa_21","k":"variable","len":1,"c":true},{"a":34,"n":"clip_left","k":"variable","len":1,"c":true},{"a":35,"n":"clip_right","k":"variable","len":1,"c":true},{"a":36,"n":"clip_top","k":"variable","len":1,"c":true},{"a":37,"n":"clip_bottom","k":"variable","len":1,"c":true},{"a":38,"n":"zpa_26","k":"variable","len":1,"c":true},{"a":39,"n":"zpa_27","k":"variable","len":1,"c":true},{"a":40,"n":"zpa_28","k":"variable","len":1,"c":true},{"a":41,"n":"zpa_29","k":"variable","len":1,"c":true},{"a":42,"n":"zpa_2A","k":"variable","len":1,"c":true},{"a":43,"n":"slope_run","k":"variable","len":1,"c":true},{"a":44,"n":"slope_step","k":"variable","len":1,"c":true},{"a":45,"n":"zpa_2D","k":"variable","len":1,"c":true},{"a":46,"n":"zpa_2E","k":"variable","len":1,"c":true},{"a":47,"n":"draw_mirror","k":"variable","len":1,"c":true},{"a":48,"n":"zpa_30","k":"variable","len":1,"c":true},{"a":49,"n":"cur_row","k":"variable","len":1,"c":true},{"a":50,"n":"zpa_32","k":"variable","len":1,"c":true},{"a":51,"n":"zpa_33","k":"variable","len":1,"c":true},{"a":52,"n":"arg3_lo","k":"variable","len":1,"c":true},{"a":53,"n":"zpa_35","k":"variable","len":1,"c":true},{"a":54,"n":"zpa_36","k":"variable","len":1,"c":true},{"a":55,"n":"shape_hdr","k":"variable","len":1,"c":true},{"a":56,"n":"zpa_38","k":"variable","len":1,"c":true},{"a":57,"n":"clip_row_hi","k":"variable","len":1,"c":true},{"a":58,"n":"clip_row_lo","k":"variable","len":1,"c":true},{"a":59,"n":"win_org","k":"variable","len":1,"c":true},{"a":60,"n":"zpa_3C","k":"table","len":3,"c":true},{"a":63,"n":"zpa_3F","k":"variable","len":2,"c":true},{"a":65,"n":"zpa_41","k":"variable","len":1,"c":true},{"a":66,"n":"zpa_42","k":"variable","len":1,"c":true},{"a":67,"n":"zpa_43","k":"variable","len":1,"c":true},{"a":68,"n":"zpa_44","k":"variable","len":1,"c":true},{"a":69,"n":"zpa_45","k":"table","len":12,"c":true},{"a":81,"n":"zpa_51","k":"variable","len":1,"c":true},{"a":82,"n":"zpa_52","k":"variable","len":1,"c":true},{"a":83,"n":"zpa_53","k":"variable","len":1,"c":true},{"a":84,"n":"zpa_54","k":"variable","len":1,"c":true},{"a":85,"n":"world_x","k":"variable","len":1,"c":true},{"a":86,"n":"zpa_56","k":"variable","len":1,"c":true},{"a":87,"n":"zpa_57","k":"variable","len":1,"c":true},{"a":88,"n":"ground_row","k":"variable","len":1,"c":true},{"a":89,"n":"heli_facing","k":"variable","len":1,"c":true},{"a":90,"n":"zpa_5A","k":"variable","len":1,"c":true},{"a":91,"n":"stick_x","k":"variable","len":1,"c":true},{"a":92,"n":"stick_y","k":"variable","len":1,"c":true},{"a":93,"n":"rotor_up","k":"variable","len":1,"c":true},{"a":94,"n":"zpa_5E","k":"variable","len":1,"c":true},{"a":95,"n":"zpa_5F","k":"variable","len":1,"c":true},{"a":96,"n":"zpa_60","k":"variable","len":1,"c":true},{"a":97,"n":"zpa_61","k":"variable","len":1,"c":true},{"a":98,"n":"zpa_62","k":"variable","len":1,"c":true},{"a":99,"n":"sortie_end_delay","k":"variable","len":1,"c":true},{"a":100,"n":"fire_latch","k":"variable","len":1,"c":true},{"a":101,"n":"shape_sel","k":"variable","len":1,"c":true},{"a":102,"n":"zpa_66","k":"variable","len":1,"c":true},{"a":103,"n":"draw_wx","k":"variable","len":1,"c":true},{"a":104,"n":"zpa_68","k":"variable","len":1,"c":true},{"a":105,"n":"draw_wy","k":"variable","len":1,"c":true},{"a":106,"n":"ent_x","k":"variable","len":1,"c":true},{"a":107,"n":"zpa_6B","k":"variable","len":1,"c":true},{"a":108,"n":"ent_row","k":"variable","len":1,"c":true},{"a":109,"n":"zpa_6D","k":"variable","len":1,"c":true},{"a":110,"n":"zpa_6E","k":"variable","len":1,"c":true},{"a":111,"n":"zpa_6F","k":"variable","len":1,"c":true},{"a":112,"n":"zpa_70","k":"variable","len":1,"c":true},{"a":113,"n":"ent_kind","k":"variable","len":1,"c":true},{"a":114,"n":"actor_slot","k":"variable","len":1,"c":true},{"a":115,"n":"zpa_73","k":"variable","len":1,"c":true},{"a":116,"n":"free_slot_head","k":"variable","len":1,"c":true},{"a":117,"n":"view_org","k":"variable","len":1,"c":true},{"a":118,"n":"zpa_76","k":"variable","len":1,"c":true},{"a":119,"n":"zpa_77","k":"variable","len":1,"c":true},{"a":120,"n":"zpa_78","k":"variable","len":1,"c":true},{"a":121,"n":"zpa_79","k":"variable","len":1,"c":true},{"a":122,"n":"zpa_7A","k":"variable","len":1,"c":true},{"a":123,"n":"off_x","k":"variable","len":1,"c":true},{"a":124,"n":"zpa_7C","k":"variable","len":1,"c":true},{"a":125,"n":"zpa_7D","k":"variable","len":1,"c":true},{"a":126,"n":"zpa_7E","k":"variable","len":1,"c":true},{"a":127,"n":"zpa_7F","k":"variable","len":1,"c":true},{"a":128,"n":"zpa_80","k":"variable","len":1,"c":true},{"a":129,"n":"zpa_81","k":"variable","len":1,"c":true},{"a":130,"n":"zpa_82","k":"variable","len":1,"c":true},{"a":131,"n":"zpa_83","k":"variable","len":1,"c":true},{"a":132,"n":"zpa_84","k":"variable","len":1,"c":true},{"a":133,"n":"zpa_85","k":"variable","len":1,"c":true},{"a":134,"n":"zpa_86","k":"variable","len":1,"c":true},{"a":135,"n":"zpa_87","k":"variable","len":1,"c":true},{"a":136,"n":"zpa_88","k":"variable","len":1,"c":true},{"a":137,"n":"phase_frames","k":"variable","len":1,"c":true},{"a":138,"n":"turn_request","k":"variable","len":1,"c":true},{"a":139,"n":"zpa_8B","k":"variable","len":1,"c":true},{"a":140,"n":"status_bar_on","k":"variable","len":1,"c":true},{"a":141,"n":"zpa_8D","k":"variable","len":1,"c":true},{"a":142,"n":"a_008E","k":"variable","len":1,"c":true},{"a":143,"n":"zpa_8F","k":"variable","len":1,"c":true},{"a":144,"n":"zpa_90","k":"table","len":3,"c":true},{"a":147,"n":"text_window_tall","k":"variable","len":1,"c":true},{"a":148,"n":"zpa_94","k":"variable","len":1,"c":true},{"a":149,"n":"zpa_95","k":"variable","len":1,"c":true},{"a":150,"n":"zpa_96","k":"variable","len":1,"c":true},{"a":151,"n":"zpa_97","k":"variable","len":1,"c":true},{"a":152,"n":"zpa_98","k":"variable","len":1,"c":true},{"a":153,"n":"list_cur","k":"variable","len":1,"c":true},{"a":154,"n":"zpa_9A","k":"variable","len":1,"c":true},{"a":155,"n":"list_prev","k":"variable","len":1,"c":true},{"a":156,"n":"zpa_9C","k":"variable","len":1,"c":true},{"a":157,"n":"list_cur_len","k":"variable","len":1,"c":true},{"a":158,"n":"zpa_9E","k":"variable","len":1,"c":true},{"a":197,"n":"zpa_C5","k":"variable","len":1,"c":true},{"a":657,"n":"kernal_shift_mode","k":"variable","len":1,"c":true},{"a":788,"n":"irq_vec_lo","k":"variable","len":1,"c":true},{"a":789,"n":"a_0315","k":"table","len":3,"c":true},{"a":792,"n":"nmi_vec_lo","k":"variable","len":1,"c":true},{"a":793,"n":"a_0319","k":"variable","len":1,"c":true},{"a":2560,"n":"bitmap_row_lo","k":"table","len":64,"c":true},{"a":2624,"n":"bitmap_row_lo_40","k":"table","len":64,"c":true},{"a":2688,"n":"bitmap_row_lo_80","k":"table","len":40,"c":true},{"a":2728,"n":"bitmap_row_hi","k":"table","len":64,"c":true},{"a":2792,"n":"bitmap_row_hi_40","k":"table","len":24,"c":true},{"a":2816,"n":"bitmap_row_hi_80","k":"table","len":64,"c":true},{"a":2880,"n":"bitmap_row_hi_end","k":"table","len":16,"c":true},{"a":2896,"n":"a_0B50","k":"variable","len":1,"c":true},{"a":2897,"n":"a_0B51","k":"variable","len":1,"c":true},{"a":2898,"n":"erase_h","k":"variable","len":1,"c":true},{"a":2899,"n":"fire_debounce","k":"variable","len":1,"c":true},{"a":2900,"n":"a_0B54","k":"variable","len":1,"c":true},{"a":2901,"n":"person_index","k":"variable","len":1,"c":true},{"a":2902,"n":"a_0B56","k":"variable","len":1,"c":true},{"a":2903,"n":"a_0B57","k":"variable","len":1,"c":true},{"a":2904,"n":"a_0B58","k":"variable","len":1,"c":true},{"a":2905,"n":"a_0B59","k":"variable","len":1,"c":true},{"a":2906,"n":"a_0B5A","k":"table","len":4,"c":true},{"a":2910,"n":"a_0B5E","k":"variable","len":1,"c":true},{"a":2911,"n":"a_0B5F","k":"variable","len":1,"c":true},{"a":2912,"n":"a_0B60","k":"variable","len":1,"c":true},{"a":2913,"n":"a_0B61","k":"variable","len":1,"c":true},{"a":2914,"n":"a_0B62","k":"variable","len":1,"c":true},{"a":2915,"n":"a_0B63","k":"variable","len":1,"c":true},{"a":2916,"n":"a_0B64","k":"variable","len":1,"c":true},{"a":2917,"n":"a_0B65","k":"variable","len":1,"c":true},{"a":2918,"n":"a_0B66","k":"variable","len":1,"c":true},{"a":2919,"n":"a_0B67","k":"variable","len":1,"c":true},{"a":2920,"n":"a_0B68","k":"variable","len":1,"c":true},{"a":2921,"n":"a_0B69","k":"variable","len":1,"c":true},{"a":2922,"n":"a_0B6A","k":"variable","len":1,"c":true},{"a":2923,"n":"a_0B6B","k":"variable","len":1,"c":true},{"a":2924,"n":"a_0B6C","k":"variable","len":1,"c":true},{"a":2925,"n":"a_0B6D","k":"variable","len":1,"c":true},{"a":2926,"n":"a_0B6E","k":"variable","len":1,"c":true},{"a":2927,"n":"a_0B6F","k":"variable","len":1,"c":true},{"a":2928,"n":"a_0B70","k":"variable","len":1,"c":true},{"a":2929,"n":"a_0B71","k":"variable","len":1,"c":true},{"a":2930,"n":"a_0B72","k":"variable","len":1,"c":true},{"a":2931,"n":"a_0B73","k":"variable","len":1,"c":true},{"a":2932,"n":"actor_type","k":"variable","len":1,"c":true},{"a":2933,"n":"actor_vx","k":"variable","len":1,"c":true},{"a":2934,"n":"actor_vy","k":"variable","len":1,"c":true},{"a":2935,"n":"actor_frame","k":"variable","len":1,"c":true},{"a":2936,"n":"actor_x","k":"variable","len":1,"c":true},{"a":2937,"n":"actor_x_hi","k":"variable","len":1,"c":true},{"a":2938,"n":"actor_alt","k":"variable","len":1,"c":true},{"a":2939,"n":"actor_base_row","k":"variable","len":1,"c":true},{"a":2940,"n":"actor_prev","k":"variable","len":1,"c":true},{"a":2941,"n":"actor_next","k":"table","len":51,"c":true},{"a":2992,"n":"actor_slots_6_11","k":"table","len":60,"c":true},{"a":3052,"n":"actor_slots_12_13","k":"table","len":20,"c":true},{"a":3072,"n":"actor_slots_14_19","k":"table","len":60,"c":true},{"a":3132,"n":"actor_slots_20_25","k":"table","len":50,"c":true},{"a":3182,"n":"actor_slot_25","k":"table","len":10,"c":true},{"a":3232,"n":"person_state","k":"variable","len":1,"c":true},{"a":3233,"n":"person_dir","k":"variable","len":1,"c":true},{"a":3234,"n":"person_x","k":"variable","len":1,"c":true},{"a":3235,"n":"person_x_hi","k":"table","len":61,"c":true},{"a":3296,"n":"engine_on","k":"variable","len":1,"c":true},{"a":3297,"n":"a_0CE1","k":"variable","len":1,"c":true},{"a":3298,"n":"a_0CE2","k":"variable","len":1,"c":true},{"a":3299,"n":"hit_list_len","k":"variable","len":1,"c":true},{"a":3300,"n":"hit_list","k":"variable","len":1,"c":true},{"a":3301,"n":"a_0CE5","k":"variable","len":1,"c":true},{"a":3302,"n":"a_0CE6","k":"variable","len":1,"c":true},{"a":3303,"n":"a_0CE7","k":"variable","len":1,"c":true},{"a":3304,"n":"board_list_len","k":"variable","len":1,"c":true},{"a":3305,"n":"board_list","k":"variable","len":1,"c":true},{"a":3306,"n":"a_0CEA","k":"variable","len":1,"c":true},{"a":3307,"n":"a_0CEB","k":"variable","len":1,"c":true},{"a":3308,"n":"a_0CEC","k":"variable","len":1,"c":true},{"a":3309,"n":"a_0CED","k":"variable","len":1,"c":true},{"a":3310,"n":"hostages_saved","k":"variable","len":1,"c":true},{"a":3311,"n":"hostages_lost","k":"variable","len":1,"c":true},{"a":3312,"n":"a_0CF0","k":"variable","len":1,"c":true},{"a":3313,"n":"a_0CF1","k":"variable","len":1,"c":true},{"a":3314,"n":"a_0CF2","k":"variable","len":1,"c":true},{"a":3315,"n":"shots_in_flight","k":"variable","len":1,"c":true},{"a":3316,"n":"ground_obj_state","k":"table","len":3,"c":true},{"a":3319,"n":"a_0CF7","k":"variable","len":1,"c":true},{"a":3320,"n":"ground_obj_count","k":"table","len":3,"c":true},{"a":3323,"n":"a_0CFB","k":"variable","len":1,"c":true},{"a":3324,"n":"a_0CFC","k":"variable","len":1,"c":true},{"a":3325,"n":"a_0CFD","k":"variable","len":1,"c":true},{"a":3326,"n":"a_0CFE","k":"variable","len":1,"c":true},{"a":3327,"n":"sortie_number","k":"variable","len":1,"c":true},{"a":3328,"n":"a_0D00","k":"variable","len":1,"c":true},{"a":3329,"n":"a_0D01","k":"variable","len":1,"c":true},{"a":3330,"n":"a_0D02","k":"variable","len":1,"c":true},{"a":3331,"n":"draw_list_a","k":"table","len":64,"c":true},{"a":3395,"n":"draw_list_a_16","k":"table","len":64,"c":true},{"a":3459,"n":"draw_list_a_32","k":"table","len":32,"c":true},{"a":3491,"n":"draw_list_b","k":"table","len":64,"c":true},{"a":3555,"n":"draw_list_b_16","k":"table","len":29,"c":true},{"a":3584,"n":"draw_list_b_23","k":"table","len":64,"c":true},{"a":3648,"n":"draw_list_b_end","k":"table","len":3,"c":true},{"a":3652,"n":"erase_hdr","k":"variable","len":1,"c":true},{"a":3653,"n":"a_0E45","k":"variable","len":1,"c":true},{"a":4096,"n":"preshift_keep_0","k":"table","len":256,"c":true},{"a":4352,"n":"preshift_keep_1","k":"table","len":256,"c":true},{"a":4608,"n":"preshift_keep_2","k":"table","len":256,"c":true},{"a":4864,"n":"preshift_keep_3","k":"table","len":256,"c":true},{"a":5120,"n":"preshift_keep_4","k":"table","len":256,"c":true},{"a":5376,"n":"preshift_keep_5","k":"table","len":256,"c":true},{"a":5632,"n":"preshift_keep_6","k":"table","len":256,"c":true},{"a":5888,"n":"preshift_keep_7","k":"table","len":256,"c":true},{"a":6144,"n":"preshift_carry_0","k":"table","len":256,"c":true},{"a":6400,"n":"preshift_carry_1","k":"table","len":256,"c":true},{"a":6656,"n":"preshift_carry_2","k":"table","len":256,"c":true},{"a":6912,"n":"preshift_carry_3","k":"table","len":256,"c":true},{"a":7168,"n":"preshift_carry_4","k":"table","len":256,"c":true},{"a":7424,"n":"preshift_carry_5","k":"table","len":256,"c":true},{"a":7680,"n":"preshift_carry_6","k":"table","len":256,"c":true},{"a":7936,"n":"preshift_carry_7","k":"table","len":256,"c":true},{"a":20480,"n":"charset_at_g","k":"table","len":64,"c":true},{"a":20544,"n":"charset_h_o","k":"table","len":64,"c":true},{"a":20608,"n":"charset_p_w","k":"table","len":64,"c":true},{"a":20672,"n":"charset_x_arrow","k":"table","len":64,"c":true},{"a":20736,"n":"charset_punct1","k":"table","len":64,"c":true},{"a":20800,"n":"charset_punct2","k":"table","len":64,"c":true},{"a":20864,"n":"charset_digits_0_7","k":"table","len":64,"c":true},{"a":20928,"n":"charset_digits_8_9","k":"table","len":64,"c":true},{"a":20992,"n":"charset_rules_a","k":"table","len":64,"c":true},{"a":21056,"n":"charset_corners_a","k":"table","len":64,"c":true},{"a":21120,"n":"charset_misc_a","k":"table","len":64,"c":true},{"a":21184,"n":"charset_misc_b","k":"table","len":64,"c":true},{"a":21248,"n":"charset_blocks_a","k":"table","len":64,"c":true},{"a":21312,"n":"charset_blocks_b","k":"table","len":64,"c":true},{"a":21376,"n":"charset_blocks_c","k":"table","len":64,"c":true},{"a":21440,"n":"charset_blocks_d","k":"table","len":64,"c":true},{"a":21504,"n":"charset_rev_at_g","k":"table","len":64,"c":true},{"a":21568,"n":"charset_rev_h_o","k":"table","len":64,"c":true},{"a":21632,"n":"charset_rev_p_w","k":"table","len":64,"c":true},{"a":21696,"n":"charset_rev_x_arrow","k":"table","len":64,"c":true},{"a":21760,"n":"charset_rev_punct1","k":"table","len":64,"c":true},{"a":21824,"n":"charset_rev_punct2","k":"table","len":64,"c":true},{"a":21888,"n":"charset_rev_digits_0_7","k":"table","len":64,"c":true},{"a":21952,"n":"charset_rev_digits_8_9","k":"table","len":64,"c":true},{"a":22016,"n":"charset_rev_rules_a","k":"table","len":64,"c":true},{"a":22080,"n":"charset_rev_corners_a","k":"table","len":64,"c":true},{"a":22144,"n":"charset_rev_misc_a","k":"table","len":64,"c":true},{"a":22208,"n":"charset_rev_misc_b","k":"table","len":64,"c":true},{"a":22272,"n":"charset_rev_blocks_a","k":"table","len":64,"c":true},{"a":22336,"n":"charset_rev_blocks_b","k":"table","len":64,"c":true},{"a":22400,"n":"charset_rev_blocks_c","k":"table","len":64,"c":true},{"a":22464,"n":"charset_rev_blocks_d","k":"table","len":64,"c":true},{"a":32768,"n":"cbm80_header","k":"table","len":9,"c":true},{"a":32777,"n":"shape_ptr_table","k":"table","len":22,"c":true},{"a":32799,"n":"shape_ptr_heli_front","k":"variable","len":1,"c":true},{"a":32800,"n":"shape_ptr_heli_front_hi","k":"table","len":5,"c":true},{"a":32805,"n":"shape_ptr_heli_side_short","k":"variable","len":1,"c":true},{"a":32806,"n":"shape_ptr_heli_side_short_hi","k":"variable","len":1,"c":true},{"a":32807,"n":"shape_ptr_heli_front_short","k":"variable","len":1,"c":true},{"a":32808,"n":"shape_ptr_heli_front_short_hi","k":"variable","len":1,"c":true},{"a":32809,"n":"shape_ptr_rotor_disc","k":"table","len":6,"c":true},{"a":32815,"n":"shape_ptr_tail_rotor","k":"variable","len":1,"c":true},{"a":32816,"n":"shape_ptr_jet","k":"table","len":43,"c":true},{"a":32859,"n":"shape_ptr_tank_gun","k":"variable","len":1,"c":true},{"a":32860,"n":"shape_ptr_shots","k":"table","len":19,"c":true},{"a":32879,"n":"shape_ptr_blast","k":"variable","len":1,"c":true},{"a":32880,"n":"shape_ptr_blast_hi","k":"table","len":7,"c":true},{"a":32887,"n":"shape_ptr_man_run","k":"variable","len":1,"c":true},{"a":32888,"n":"shape_ptr_man_run_hi","k":"table","len":7,"c":true},{"a":32895,"n":"shape_ptr_man_wave","k":"variable","len":1,"c":true},{"a":32896,"n":"shape_ptr_man_wave_hi","k":"table","len":5,"c":true},{"a":32901,"n":"shape_ptr_man_board","k":"variable","len":1,"c":true},{"a":32902,"n":"shape_ptr_scenery","k":"table","len":11,"c":true},{"a":32913,"n":"shape_ptr_flag","k":"variable","len":1,"c":true},{"a":32914,"n":"shape_ptr_flag_hi","k":"table","len":5,"c":true},{"a":32919,"n":"shape_ptr_hut","k":"variable","len":1,"c":true},{"a":32920,"n":"shape_ptr_hut_hi","k":"table","len":7,"c":true},{"a":32927,"n":"shape_table_pad","k":"variable","len":2,"c":true},{"a":32929,"n":"heli_side_tilt_m5","k":"table","len":64,"c":true},{"a":32993,"n":"heli_side_tilt_m5_rows","k":"table","len":10,"c":true},{"a":33003,"n":"heli_side_tilt_m4","k":"table","len":64,"c":true},{"a":33067,"n":"heli_side_tilt_m4_rows","k":"variable","len":2,"c":true},{"a":33069,"n":"heli_side_tilt_m3","k":"table","len":64,"c":true},{"a":33133,"n":"heli_side_tilt_m3_rows","k":"table","len":13,"c":true},{"a":33146,"n":"heli_side_tilt_m2","k":"table","len":64,"c":true},{"a":33210,"n":"heli_side_tilt_m2_rows","k":"table","len":8,"c":true},{"a":33218,"n":"heli_side_tilt_m1","k":"table","len":64,"c":true},{"a":33282,"n":"heli_side_tilt_m1_rows","k":"table","len":8,"c":true},{"a":33290,"n":"heli_side_tilt_p0","k":"table","len":64,"c":true},{"a":33354,"n":"heli_side_tilt_p0_rows","k":"table","len":3,"c":true},{"a":33357,"n":"heli_side_tilt_p1","k":"table","len":64,"c":true},{"a":33421,"n":"heli_side_tilt_p1_rows","k":"table","len":3,"c":true},{"a":33424,"n":"heli_side_tilt_p2","k":"table","len":64,"c":true},{"a":33488,"n":"heli_side_tilt_p2_rows","k":"table","len":3,"c":true},{"a":33491,"n":"heli_side_tilt_p3","k":"table","len":64,"c":true},{"a":33555,"n":"heli_side_tilt_p3_rows","k":"table","len":8,"c":true},{"a":33563,"n":"heli_side_tilt_p4","k":"table","len":64,"c":true},{"a":33627,"n":"heli_side_tilt_p4_rows","k":"table","len":13,"c":true},{"a":33640,"n":"heli_side_tilt_p5","k":"table","len":64,"c":true},{"a":33704,"n":"heli_side_tilt_p5_rows","k":"table","len":18,"c":true},{"a":33722,"n":"heli_front_0","k":"table","len":28,"c":true},{"a":33750,"n":"heli_front_1","k":"table","len":28,"c":true},{"a":33778,"n":"heli_front_2","k":"table","len":54,"c":true},{"a":33832,"n":"heli_side_short","k":"table","len":62,"c":true},{"a":33894,"n":"heli_front_short","k":"table","len":26,"c":true},{"a":33920,"n":"rotor_disc_short","k":"table","len":5,"c":true},{"a":33925,"n":"rotor_disc_mid","k":"table","len":7,"c":true},{"a":33932,"n":"rotor_disc_long","k":"table","len":7,"c":true},{"a":33939,"n":"tail_rotor_a","k":"table","len":8,"c":true},{"a":33947,"n":"tail_rotor_b","k":"table","len":8,"c":true},{"a":33955,"n":"tail_rotor_flat","k":"table","len":6,"c":true},{"a":33961,"n":"tail_rotor_edge","k":"table","len":9,"c":true},{"a":33970,"n":"jet_cruise","k":"table","len":17,"c":true},{"a":33987,"n":"jet_turn_0","k":"table","len":46,"c":true},{"a":34033,"n":"jet_turn_1","k":"table","len":41,"c":true},{"a":34074,"n":"jet_turn_2","k":"table","len":47,"c":true},{"a":34121,"n":"jet_turn_3","k":"table","len":34,"c":true},{"a":34155,"n":"jet_turn_4","k":"table","len":53,"c":true},{"a":34208,"n":"jet_turn_5","k":"table","len":64,"c":true},{"a":34272,"n":"jet_turn_5_rows","k":"variable","len":2,"c":true},{"a":34274,"n":"jet_turn_6","k":"table","len":64,"c":true},{"a":34338,"n":"jet_turn_6_rows","k":"variable","len":2,"c":true},{"a":34340,"n":"jet_roll_0","k":"table","len":35,"c":true},{"a":34375,"n":"jet_roll_1","k":"table","len":44,"c":true},{"a":34419,"n":"jet_roll_2","k":"table","len":42,"c":true},{"a":34461,"n":"jet_roll_3","k":"table","len":42,"c":true},{"a":34503,"n":"jet_roll_4","k":"table","len":57,"c":true},{"a":34560,"n":"jet_pass_0","k":"table","len":64,"c":true},{"a":34624,"n":"jet_pass_0_rows","k":"table","len":28,"c":true},{"a":34652,"n":"jet_pass_1","k":"table","len":62,"c":true},{"a":34714,"n":"jet_pass_2","k":"table","len":54,"c":true},{"a":34768,"n":"tank_hull","k":"table","len":8,"c":true},{"a":34776,"n":"tank_tracks","k":"table","len":26,"c":true},{"a":34802,"n":"tank_gun_0","k":"table","len":7,"c":true},{"a":34809,"n":"tank_gun_1","k":"table","len":6,"c":true},{"a":34815,"n":"tank_gun_2","k":"table","len":6,"c":true},{"a":34821,"n":"tank_gun_3","k":"table","len":6,"c":true},{"a":34827,"n":"tank_gun_4","k":"table","len":7,"c":true},{"a":34834,"n":"shot_heli","k":"table","len":5,"c":true},{"a":34839,"n":"shot_falling","k":"table","len":5,"c":true},{"a":34844,"n":"missile_jet","k":"table","len":8,"c":true},{"a":34852,"n":"shell_jet","k":"table","len":3,"c":true},{"a":34855,"n":"drone_body","k":"table","len":22,"c":true},{"a":34877,"n":"blast_0","k":"table","len":29,"c":true},{"a":34906,"n":"blast_1","k":"table","len":38,"c":true},{"a":34944,"n":"blast_2","k":"table","len":38,"c":true},{"a":34982,"n":"blast_3","k":"table","len":26,"c":true},{"a":35008,"n":"man_run_0","k":"table","len":24,"c":true},{"a":35032,"n":"man_run_1","k":"table","len":24,"c":true},{"a":35056,"n":"man_run_2","k":"table","len":24,"c":true},{"a":35080,"n":"man_run_3","k":"table","len":24,"c":true},{"a":35104,"n":"man_wave_0","k":"table","len":24,"c":true},{"a":35128,"n":"man_wave_1","k":"table","len":24,"c":true},{"a":35152,"n":"man_wave_2","k":"table","len":24,"c":true},{"a":35176,"n":"man_board_0","k":"table","len":24,"c":true},{"a":35200,"n":"man_board_1","k":"table","len":20,"c":true},{"a":35220,"n":"bg_hill","k":"table","len":22,"c":true},{"a":35242,"n":"base_building","k":"table","len":46,"c":true},{"a":35288,"n":"base_wedge","k":"table","len":12,"c":true},{"a":35300,"n":"flagpole","k":"table","len":14,"c":true},{"a":35314,"n":"flag_a","k":"table","len":18,"c":true},{"a":35332,"n":"flag_b","k":"table","len":18,"c":true},{"a":35350,"n":"parallax_blob","k":"table","len":7,"c":true},{"a":35357,"n":"hut_shut","k":"table","len":46,"c":true},{"a":35403,"n":"hut_open","k":"table","len":46,"c":true},{"a":35449,"n":"hut_plinth","k":"table","len":10,"c":true},{"a":35459,"n":"hut_door_figures","k":"table","len":8,"c":true},{"a":35467,"n":"msg_show","k":"routine","len":60,"c":true},{"a":35485,"n":"b_8A9D","k":"branch","len":1,"c":false},{"a":35512,"n":"b_8AB8","k":"branch","len":1,"c":false},{"a":35527,"n":"msg_hide","k":"routine","len":16,"c":true},{"a":35531,"n":"b_8ACB","k":"branch","len":1,"c":false},{"a":35543,"n":"msg_ptrs","k":"variable","len":1,"c":true},{"a":35544,"n":"msg_ptrs_hi","k":"table","len":9,"c":true},{"a":35553,"n":"msg_first_sortie","k":"table","len":13,"c":true},{"a":35566,"n":"msg_second_sortie","k":"table","len":14,"c":true},{"a":35580,"n":"msg_third_sortie","k":"table","len":13,"c":true},{"a":35593,"n":"msg_the_end","k":"table","len":8,"c":true},{"a":35601,"n":"msg_magnificent","k":"table","len":13,"c":true},{"a":35614,"n":"inline_arg_here","k":"routine","len":26,"c":true},{"a":35637,"n":"b_8B35","k":"branch","len":1,"c":false},{"a":35640,"n":"inline_arg_deref","k":"routine","len":48,"c":true},{"a":35663,"n":"b_8B4F","k":"branch","len":1,"c":false},{"a":35685,"n":"b_8B65","k":"branch","len":1,"c":false},{"a":35688,"n":"inline_set_draw_pos_dead","k":"routine","len":41,"c":true},{"a":35722,"n":"b_8B8A","k":"branch","len":1,"c":false},{"a":35729,"n":"inline_set_draw_pos","k":"routine","len":30,"c":true},{"a":35759,"n":"clip_override_bottom","k":"routine","len":11,"c":true},{"a":35770,"n":"inline_fill_record","k":"routine","len":38,"c":true},{"a":35808,"n":"inline_shape_ptr","k":"routine","len":25,"c":true},{"a":35833,"n":"inline_object_pos","k":"routine","len":30,"c":true},{"a":35863,"n":"inline_window_x","k":"routine","len":25,"c":true},{"a":35888,"n":"shear_from_speed","k":"routine","len":24,"c":true},{"a":35912,"n":"f_8C48","k":"variable","len":1,"c":true},{"a":35913,"n":"shear_table","k":"table","len":21,"c":true},{"a":35934,"n":"fill_rect_pattern","k":"routine","len":130,"c":true},{"a":35966,"n":"b_8C7E","k":"branch","len":1,"c":false},{"a":36024,"n":"b_8CB8","k":"branch","len":1,"c":false},{"a":36036,"n":"b_8CC4","k":"branch","len":1,"c":false},{"a":36048,"n":"b_8CD0","k":"branch","len":1,"c":false},{"a":36057,"n":"b_8CD9","k":"branch","len":1,"c":false},{"a":36064,"n":"draw_layer_reset","k":"routine","len":30,"c":true},{"a":36094,"n":"clip_reset","k":"routine","len":17,"c":true},{"a":36111,"n":"draw_to_bank0","k":"routine","len":7,"c":true},{"a":36118,"n":"flip_draw_buffer","k":"routine","len":9,"c":true},{"a":36127,"n":"show_draw_buffer","k":"routine","len":35,"c":true},{"a":36150,"n":"b_8D36","k":"branch","len":1,"c":false},{"a":36162,"n":"fill_rows","k":"routine","len":59,"c":true},{"a":36173,"n":"b_8D4D","k":"branch","len":1,"c":false},{"a":36191,"n":"j_8D5F","k":"branch","len":1,"c":false},{"a":36214,"n":"b_8D76","k":"branch","len":1,"c":false},{"a":36221,"n":"x_to_right_end","k":"routine","len":27,"c":true},{"a":36248,"n":"bit_mask_for_x","k":"routine","len":48,"c":true},{"a":36263,"n":"b_8DA7","k":"branch","len":1,"c":false},{"a":36279,"n":"j_8DB7","k":"branch","len":1,"c":false},{"a":36286,"n":"j_8DBE","k":"branch","len":1,"c":false},{"a":36293,"n":"b_8DC5","k":"branch","len":1,"c":false},{"a":36296,"n":"split_screen_x","k":"routine","len":43,"c":true},{"a":36304,"n":"j_8DD0","k":"branch","len":1,"c":false},{"a":36339,"n":"apply_clip","k":"routine","len":140,"c":true},{"a":36359,"n":"b_8E07","k":"branch","len":1,"c":false},{"a":36366,"n":"b_8E0E","k":"branch","len":1,"c":false},{"a":36387,"n":"b_8E23","k":"branch","len":1,"c":false},{"a":36429,"n":"b_8E4D","k":"branch","len":1,"c":false},{"a":36479,"n":"setup_blit_row","k":"routine","len":99,"c":true},{"a":36514,"n":"j_8EA2","k":"branch","len":1,"c":false},{"a":36523,"n":"b_8EAB","k":"branch","len":1,"c":false},{"a":36560,"n":"b_8ED0","k":"branch","len":1,"c":false},{"a":36577,"n":"r_8EE1","k":"branch","len":1,"c":false},{"a":36578,"n":"unpack_shape_header","k":"routine","len":33,"c":true},{"a":36611,"n":"clip_object","k":"routine","len":208,"c":true},{"a":36645,"n":"b_8F25","k":"branch","len":1,"c":false},{"a":36661,"n":"b_8F35","k":"branch","len":1,"c":false},{"a":36697,"n":"b_8F59","k":"branch","len":1,"c":false},{"a":36700,"n":"j_8F5C","k":"branch","len":1,"c":false},{"a":36729,"n":"b_8F79","k":"branch","len":1,"c":false},{"a":36759,"n":"j_8F97","k":"branch","len":1,"c":false},{"a":36787,"n":"b_8FB3","k":"branch","len":1,"c":false},{"a":36790,"n":"b_8FB6","k":"branch","len":1,"c":false},{"a":36811,"n":"j_8FCB","k":"branch","len":1,"c":false},{"a":36812,"n":"b_8FCC","k":"branch","len":1,"c":false},{"a":36819,"n":"draw_shape","k":"routine","len":107,"c":true},{"a":36841,"n":"j_8FE9","k":"branch","len":1,"c":false},{"a":36860,"n":"b_8FFC","k":"branch","len":1,"c":false},{"a":36902,"n":"b_9026","k":"branch","len":1,"c":false},{"a":36910,"n":"b_902E","k":"branch","len":1,"c":false},{"a":36919,"n":"b_9037","k":"branch","len":1,"c":false},{"a":36926,"n":"draw_shape_mirrored","k":"routine","len":148,"c":true},{"a":36966,"n":"j_9066","k":"branch","len":1,"c":false},{"a":36979,"n":"j_9073","k":"branch","len":1,"c":false},{"a":36987,"n":"b_907B","k":"branch","len":1,"c":false},{"a":36993,"n":"j_9081","k":"branch","len":1,"c":false},{"a":37023,"n":"b_909F","k":"branch","len":1,"c":false},{"a":37026,"n":"b_90A2","k":"branch","len":1,"c":false},{"a":37031,"n":"b_90A7","k":"branch","len":1,"c":false},{"a":37048,"n":"b_90B8","k":"branch","len":1,"c":false},{"a":37059,"n":"b_90C3","k":"branch","len":1,"c":false},{"a":37074,"n":"draw_sheared_shape","k":"routine","len":13,"c":true},{"a":37087,"n":"draw_sheared_shape_mirrored","k":"routine","len":10,"c":true},{"a":37097,"n":"j_90E9","k":"routine","len":319,"c":true},{"a":37124,"n":"j_9104","k":"branch","len":1,"c":false},{"a":37202,"n":"j_9152","k":"branch","len":1,"c":false},{"a":37214,"n":"b_915E","k":"branch","len":1,"c":false},{"a":37269,"n":"b_9195","k":"branch","len":1,"c":false},{"a":37276,"n":"b_919C","k":"branch","len":1,"c":false},{"a":37283,"n":"b_91A3","k":"branch","len":1,"c":false},{"a":37305,"n":"b_91B9","k":"branch","len":1,"c":false},{"a":37320,"n":"j_91C8","k":"branch","len":1,"c":false},{"a":37335,"n":"b_91D7","k":"branch","len":1,"c":false},{"a":37345,"n":"b_91E1","k":"branch","len":1,"c":false},{"a":37354,"n":"b_91EA","k":"branch","len":1,"c":false},{"a":37364,"n":"b_91F4","k":"branch","len":1,"c":false},{"a":37373,"n":"b_91FD","k":"branch","len":1,"c":false},{"a":37396,"n":"b_9214","k":"branch","len":1,"c":false},{"a":37406,"n":"b_921E","k":"branch","len":1,"c":false},{"a":37409,"n":"b_9221","k":"branch","len":1,"c":false},{"a":37416,"n":"stars_restamp","k":"routine","len":38,"c":true},{"a":37418,"n":"b_922A","k":"branch","len":1,"c":false},{"a":37444,"n":"b_9244","k":"branch","len":1,"c":false},{"a":37446,"n":"b_9246","k":"branch","len":1,"c":false},{"a":37454,"n":"star_bitmap_addr","k":"variable","len":1,"c":true},{"a":37455,"n":"star_bitmap_addr_hi","k":"table","len":47,"c":true},{"a":37502,"n":"heli_body_y_nudge","k":"table","len":55,"c":true},{"a":37557,"n":"rotor_offset_fine","k":"variable","len":1,"c":true},{"a":37558,"n":"rotor_offset_fine_y","k":"table","len":55,"c":true},{"a":37613,"n":"rotor_offset_fine_t1","k":"table","len":56,"c":true},{"a":37669,"n":"rotor_offset_fine_t3","k":"table","len":42,"c":true},{"a":37711,"n":"rotor_offset_base","k":"variable","len":1,"c":true},{"a":37712,"n":"rotor_offset_base_y","k":"table","len":21,"c":true},{"a":37733,"n":"tail_rotor_offset_r","k":"variable","len":1,"c":true},{"a":37734,"n":"tail_rotor_offset_r_y","k":"table","len":21,"c":true},{"a":37755,"n":"tail_rotor_offset_l","k":"variable","len":1,"c":true},{"a":37756,"n":"tail_rotor_offset_l_y","k":"table","len":21,"c":true},{"a":37777,"n":"muzzle_offset","k":"variable","len":1,"c":true},{"a":37778,"n":"muzzle_offset_y","k":"table","len":55,"c":true},{"a":37833,"n":"muzzle_offset_t1","k":"table","len":56,"c":true},{"a":37889,"n":"muzzle_offset_t3","k":"table","len":42,"c":true},{"a":37931,"n":"heli_shot_speed","k":"variable","len":1,"c":true},{"a":37932,"n":"heli_shot_speed_y","k":"table","len":47,"c":true},{"a":37979,"n":"tilt_anchor_x","k":"variable","len":1,"c":true},{"a":37980,"n":"tilt_anchor_x_hi","k":"table","len":21,"c":true},{"a":38001,"n":"tilt_anchor_y","k":"table","len":22,"c":true},{"a":38023,"n":"jet_erase_class","k":"table","len":40,"c":true},{"a":38063,"n":"erase_box_w","k":"variable","len":1,"c":true},{"a":38064,"n":"erase_box_h","k":"table","len":51,"c":true},{"a":38115,"n":"jet_path_cruise","k":"table","len":4,"c":true},{"a":38119,"n":"jet_path_turn_wide","k":"table","len":32,"c":true},{"a":38151,"n":"jet_path_turn_wide_2","k":"table","len":40,"c":true},{"a":38191,"n":"jet_path_turn_tight","k":"table","len":60,"c":true},{"a":38251,"n":"jet_path_run","k":"table","len":40,"c":true},{"a":38291,"n":"cart_cold_start","k":"routine","len":9,"c":true},{"a":38300,"n":"cold_start","k":"routine","len":19,"c":true},{"a":38319,"n":"title_screen","k":"routine","len":12,"c":true},{"a":38331,"n":"attract_loop","k":"routine","len":43,"c":true},{"a":38342,"n":"b_95C6","k":"branch","len":1,"c":false},{"a":38374,"n":"game_start","k":"routine","len":56,"c":true},{"a":38395,"n":"b_95FB","k":"branch","len":1,"c":false},{"a":38430,"n":"sortie_start","k":"routine","len":28,"c":true},{"a":38440,"n":"b_9628","k":"branch","len":1,"c":false},{"a":38458,"n":"sortie_msg_loop","k":"routine","len":44,"c":true},{"a":38481,"n":"b_9651","k":"branch","len":1,"c":false},{"a":38502,"n":"flight_begin","k":"routine","len":9,"c":true},{"a":38511,"n":"flight_frame","k":"routine","len":117,"c":true},{"a":38531,"n":"b_9683","k":"branch","len":1,"c":false},{"a":38542,"n":"b_968E","k":"branch","len":1,"c":false},{"a":38556,"n":"b_969C","k":"branch","len":1,"c":false},{"a":38628,"n":"end_the_end","k":"routine","len":4,"c":true},{"a":38632,"n":"end_magnificent","k":"routine","len":2,"c":true},{"a":38634,"n":"end_msg_show","k":"routine","len":12,"c":true},{"a":38646,"n":"end_msg_loop","k":"routine","len":67,"c":true},{"a":38666,"n":"b_970A","k":"branch","len":1,"c":false},{"a":38713,"n":"redraw_backdrop","k":"routine","len":11,"c":true},{"a":38724,"n":"redraw_backdrop_arg","k":"variable","len":2,"c":true},{"a":38726,"n":"redraw_backdrop_run","k":"routine","len":36,"c":true},{"a":38762,"n":"joy_fire_carry","k":"routine","len":10,"c":true},{"a":38771,"n":"r_9773","k":"branch","len":1,"c":false},{"a":38772,"n":"fire_decode","k":"routine","len":57,"c":true},{"a":38790,"n":"b_9786","k":"branch","len":1,"c":false},{"a":38807,"n":"b_9797","k":"branch","len":1,"c":false},{"a":38810,"n":"j_979A","k":"branch","len":1,"c":false},{"a":38815,"n":"b_979F","k":"branch","len":1,"c":false},{"a":38829,"n":"fire_poll","k":"routine","len":37,"c":true},{"a":38855,"n":"b_97C7","k":"branch","len":1,"c":false},{"a":38859,"n":"r_97CB","k":"branch","len":1,"c":false},{"a":38860,"n":"b_97CC","k":"branch","len":1,"c":false},{"a":38866,"n":"fire_shot_request","k":"routine","len":31,"c":true},{"a":38896,"n":"r_97F0","k":"branch","len":1,"c":false},{"a":38897,"n":"turn_begin","k":"routine","len":74,"c":true},{"a":38930,"n":"b_9812","k":"branch","len":1,"c":false},{"a":38948,"n":"j_9824","k":"branch","len":1,"c":false},{"a":38957,"n":"j_982D","k":"branch","len":1,"c":false},{"a":38964,"n":"b_9834","k":"branch","len":1,"c":false},{"a":38971,"n":"turn_end","k":"routine","len":49,"c":true},{"a":39001,"n":"b_9859","k":"branch","len":1,"c":false},{"a":39006,"n":"b_985E","k":"branch","len":1,"c":false},{"a":39015,"n":"b_9867","k":"branch","len":1,"c":false},{"a":39019,"n":"r_986B","k":"branch","len":1,"c":false},{"a":39020,"n":"turn_step","k":"routine","len":68,"c":true},{"a":39028,"n":"b_9874","k":"branch","len":1,"c":false},{"a":39040,"n":"b_9880","k":"branch","len":1,"c":false},{"a":39045,"n":"b_9885","k":"branch","len":1,"c":false},{"a":39047,"n":"j_9887","k":"branch","len":1,"c":false},{"a":39077,"n":"b_98A5","k":"branch","len":1,"c":false},{"a":39087,"n":"r_98AF","k":"branch","len":1,"c":false},{"a":39088,"n":"facing_target_tbl","k":"table","len":12,"c":true},{"a":39100,"n":"pause_check","k":"routine","len":35,"c":true},{"a":39111,"n":"b_98C7","k":"branch","len":1,"c":false},{"a":39117,"n":"b_98CD","k":"branch","len":1,"c":false},{"a":39123,"n":"b_98D3","k":"branch","len":1,"c":false},{"a":39134,"n":"r_98DE","k":"branch","len":1,"c":false},{"a":39135,"n":"screen_init","k":"routine","len":119,"c":true},{"a":39147,"n":"b_98EB","k":"branch","len":1,"c":false},{"a":39205,"n":"b_9925","k":"branch","len":1,"c":false},{"a":39222,"n":"j_9936","k":"branch","len":1,"c":false},{"a":39238,"n":"b_9946","k":"branch","len":1,"c":false},{"a":39253,"n":"r_9955","k":"branch","len":1,"c":false},{"a":39254,"n":"status_frame_rle","k":"table","len":21,"c":true},{"a":39275,"n":"engine_sound","k":"routine","len":61,"c":true},{"a":39308,"n":"b_998C","k":"branch","len":1,"c":false},{"a":39320,"n":"b_9998","k":"branch","len":1,"c":false},{"a":39326,"n":"r_999E","k":"branch","len":1,"c":false},{"a":39327,"n":"b_999F","k":"branch","len":1,"c":false},{"a":39336,"n":"irq_midwin_open","k":"routine","len":40,"c":true},{"a":39370,"n":"b_99CA","k":"branch","len":1,"c":false},{"a":39376,"n":"irq_midwin_close","k":"routine","len":34,"c":true},{"a":39410,"n":"raster_irq","k":"routine","len":33,"c":true},{"a":39428,"n":"b_9A04","k":"branch","len":1,"c":false},{"a":39443,"n":"irq_top_text","k":"routine","len":86,"c":true},{"a":39490,"n":"b_9A42","k":"branch","len":1,"c":false},{"a":39495,"n":"b_9A47","k":"branch","len":1,"c":false},{"a":39518,"n":"b_9A5E","k":"branch","len":1,"c":false},{"a":39529,"n":"irq_bitmap_on","k":"routine","len":43,"c":true},{"a":39566,"n":"b_9A8E","k":"branch","len":1,"c":false},{"a":39572,"n":"irq_ground","k":"routine","len":13,"c":true},{"a":39585,"n":"irq_exit","k":"routine","len":10,"c":true},{"a":39595,"n":"nmi_rti","k":"routine","len":1,"c":true},{"a":39596,"n":"title_text_draw","k":"routine","len":77,"c":true},{"a":39602,"n":"b_9AB2","k":"branch","len":1,"c":false},{"a":39620,"n":"b_9AC4","k":"branch","len":1,"c":false},{"a":39651,"n":"j_9AE3","k":"branch","len":1,"c":false},{"a":39663,"n":"b_9AEF","k":"branch","len":1,"c":false},{"a":39673,"n":"title_text_table","k":"table","len":20,"c":true},{"a":39693,"n":"title_str_broderbund","k":"table","len":29,"c":true},{"a":39722,"n":"title_str_choplifter","k":"table","len":12,"c":true},{"a":39734,"n":"title_str_dan_gorlin","k":"table","len":11,"c":true},{"a":39745,"n":"title_str_dane_bigham","k":"table","len":12,"c":true},{"a":39757,"n":"title_str_copyright","k":"table","len":9,"c":true},{"a":39766,"n":"title_exit_repaint","k":"routine","len":39,"c":true},{"a":39770,"n":"b_9B5A","k":"branch","len":1,"c":false},{"a":39788,"n":"b_9B6C","k":"branch","len":1,"c":false},{"a":39805,"n":"hostages_update","k":"routine","len":511,"c":true},{"a":39811,"n":"j_9B83","k":"branch","len":1,"c":false},{"a":39819,"n":"b_9B8B","k":"branch","len":1,"c":false},{"a":39845,"n":"b_9BA5","k":"branch","len":1,"c":false},{"a":39856,"n":"b_9BB0","k":"branch","len":1,"c":false},{"a":39885,"n":"b_9BCD","k":"branch","len":1,"c":false},{"a":39899,"n":"b_9BDB","k":"branch","len":1,"c":false},{"a":39912,"n":"b_9BE8","k":"branch","len":1,"c":false},{"a":39941,"n":"b_9C05","k":"branch","len":1,"c":false},{"a":39944,"n":"b_9C08","k":"branch","len":1,"c":false},{"a":39971,"n":"b_9C23","k":"branch","len":1,"c":false},{"a":40002,"n":"b_9C42","k":"branch","len":1,"c":false},{"a":40020,"n":"b_9C54","k":"branch","len":1,"c":false},{"a":40025,"n":"b_9C59","k":"branch","len":1,"c":false},{"a":40033,"n":"b_9C61","k":"branch","len":1,"c":false},{"a":40046,"n":"b_9C6E","k":"branch","len":1,"c":false},{"a":40053,"n":"j_9C75","k":"branch","len":1,"c":false},{"a":40058,"n":"j_9C7A","k":"branch","len":1,"c":false},{"a":40083,"n":"b_9C93","k":"branch","len":1,"c":false},{"a":40094,"n":"b_9C9E","k":"branch","len":1,"c":false},{"a":40097,"n":"j_9CA1","k":"branch","len":1,"c":false},{"a":40135,"n":"b_9CC7","k":"branch","len":1,"c":false},{"a":40160,"n":"b_9CE0","k":"branch","len":1,"c":false},{"a":40163,"n":"b_9CE3","k":"branch","len":1,"c":false},{"a":40166,"n":"b_9CE6","k":"branch","len":1,"c":false},{"a":40179,"n":"b_9CF3","k":"branch","len":1,"c":false},{"a":40203,"n":"b_9D0B","k":"branch","len":1,"c":false},{"a":40216,"n":"j_9D18","k":"branch","len":1,"c":false},{"a":40269,"n":"b_9D4D","k":"branch","len":1,"c":false},{"a":40272,"n":"j_9D50","k":"branch","len":1,"c":false},{"a":40278,"n":"j_9D56","k":"branch","len":1,"c":false},{"a":40292,"n":"b_9D64","k":"branch","len":1,"c":false},{"a":40316,"n":"arg_hostage_wave_shape","k":"variable","len":2,"c":true},{"a":40318,"n":"hostage_draw_waving","k":"routine","len":24,"c":true},{"a":40324,"n":"b_9D84","k":"branch","len":1,"c":false},{"a":40342,"n":"arg_hostage_walk_shape","k":"variable","len":2,"c":true},{"a":40344,"n":"hostage_draw_walking","k":"routine","len":25,"c":true},{"a":40350,"n":"j_9D9E","k":"branch","len":1,"c":false},{"a":40369,"n":"arg_hostage_board_shape","k":"variable","len":2,"c":true},{"a":40371,"n":"hostage_draw_boarding","k":"routine","len":39,"c":true},{"a":40388,"n":"b_9DC4","k":"branch","len":1,"c":false},{"a":40393,"n":"j_9DC9","k":"branch","len":1,"c":false},{"a":40409,"n":"r_9DD9","k":"branch","len":1,"c":false},{"a":40410,"n":"hostage_draw","k":"routine","len":35,"c":true},{"a":40445,"n":"arg_hostage_draw_pos","k":"variable","len":2,"c":true},{"a":40447,"n":"hostage_draw_blit","k":"routine","len":21,"c":true},{"a":40464,"n":"b_9E10","k":"branch","len":1,"c":false},{"a":40467,"n":"r_9E13","k":"branch","len":1,"c":false},{"a":40468,"n":"hostage_killed_by_helicopter","k":"routine","len":14,"c":true},{"a":40482,"n":"hostage_release_tick","k":"routine","len":39,"c":true},{"a":40512,"n":"b_9E40","k":"branch","len":1,"c":false},{"a":40520,"n":"r_9E48","k":"branch","len":1,"c":false},{"a":40521,"n":"barracks_pick","k":"routine","len":60,"c":true},{"a":40546,"n":"b_9E62","k":"branch","len":1,"c":false},{"a":40555,"n":"b_9E6B","k":"branch","len":1,"c":false},{"a":40568,"n":"b_9E78","k":"branch","len":1,"c":false},{"a":40575,"n":"b_9E7F","k":"branch","len":1,"c":false},{"a":40581,"n":"hostage_create","k":"routine","len":141,"c":true},{"a":40584,"n":"j_9E88","k":"branch","len":1,"c":false},{"a":40586,"n":"b_9E8A","k":"branch","len":1,"c":false},{"a":40636,"n":"b_9EBC","k":"branch","len":1,"c":false},{"a":40670,"n":"b_9EDE","k":"branch","len":1,"c":false},{"a":40702,"n":"b_9EFE","k":"branch","len":1,"c":false},{"a":40722,"n":"tank_spawn","k":"routine","len":66,"c":true},{"a":40733,"n":"r_9F1D","k":"branch","len":1,"c":false},{"a":40734,"n":"b_9F1E","k":"branch","len":1,"c":false},{"a":40756,"n":"b_9F34","k":"branch","len":1,"c":false},{"a":40765,"n":"b_9F3D","k":"branch","len":1,"c":false},{"a":40788,"n":"tank_spawn_right","k":"routine","len":82,"c":true},{"a":40804,"n":"j_9F64","k":"branch","len":1,"c":false},{"a":40809,"n":"j_9F69","k":"branch","len":1,"c":false},{"a":40820,"n":"b_9F74","k":"branch","len":1,"c":false},{"a":40834,"n":"b_9F82","k":"branch","len":1,"c":false},{"a":40870,"n":"actor9_spawn","k":"routine","len":90,"c":true},{"a":40897,"n":"b_9FC1","k":"branch","len":1,"c":false},{"a":40926,"n":"b_9FDE","k":"branch","len":1,"c":false},{"a":40934,"n":"b_9FE6","k":"branch","len":1,"c":false},{"a":40939,"n":"j_9FEB","k":"branch","len":1,"c":false},{"a":40956,"n":"b_9FFC","k":"branch","len":1,"c":false},{"a":40960,"n":"actor9_spawn_page_a0","k":"routine","len":64,"c":true},{"a":40965,"n":"b_A005","k":"branch","len":1,"c":false},{"a":40988,"n":"j_A01C","k":"branch","len":1,"c":false},{"a":41008,"n":"j_A030","k":"branch","len":1,"c":false},{"a":41024,"n":"actor9_flag_prob_table","k":"table","len":4,"c":true},{"a":41028,"n":"actor10_spawn","k":"routine","len":119,"c":true},{"a":41039,"n":"r_A04F","k":"branch","len":1,"c":false},{"a":41040,"n":"b_A050","k":"branch","len":1,"c":false},{"a":41091,"n":"b_A083","k":"branch","len":1,"c":false},{"a":41100,"n":"b_A08C","k":"branch","len":1,"c":false},{"a":41118,"n":"j_A09E","k":"branch","len":1,"c":false},{"a":41133,"n":"j_A0AD","k":"branch","len":1,"c":false},{"a":41147,"n":"tank_update","k":"routine","len":12,"c":true},{"a":41159,"n":"arg_tank_hull_pos","k":"variable","len":2,"c":true},{"a":41161,"n":"tank_load_hull_shape","k":"routine","len":3,"c":true},{"a":41164,"n":"arg_shape_tank_hull","k":"variable","len":2,"c":true},{"a":41166,"n":"tank_draw_hull","k":"routine","len":40,"c":true},{"a":41191,"n":"b_A0E7","k":"branch","len":1,"c":false},{"a":41194,"n":"j_A0EA","k":"branch","len":1,"c":false},{"a":41206,"n":"arg_tank_turret_pos","k":"variable","len":2,"c":true},{"a":41208,"n":"tank_load_turret_shape","k":"routine","len":3,"c":true},{"a":41211,"n":"arg_shape_tank_turret","k":"variable","len":2,"c":true},{"a":41213,"n":"tank_draw_turret","k":"routine","len":33,"c":true},{"a":41226,"n":"b_A10A","k":"branch","len":1,"c":false},{"a":41246,"n":"arg_shape_tank_barrel","k":"variable","len":2,"c":true},{"a":41248,"n":"tank_place_barrel","k":"routine","len":16,"c":true},{"a":41264,"n":"arg_tank_barrel_pos","k":"variable","len":2,"c":true},{"a":41266,"n":"tank_draw_barrel_and_think","k":"routine","len":274,"c":true},{"a":41279,"n":"b_A13F","k":"branch","len":1,"c":false},{"a":41329,"n":"b_A171","k":"branch","len":1,"c":false},{"a":41338,"n":"b_A17A","k":"branch","len":1,"c":false},{"a":41345,"n":"b_A181","k":"branch","len":1,"c":false},{"a":41349,"n":"j_A185","k":"branch","len":1,"c":false},{"a":41356,"n":"b_A18C","k":"branch","len":1,"c":false},{"a":41359,"n":"b_A18F","k":"branch","len":1,"c":false},{"a":41377,"n":"b_A1A1","k":"branch","len":1,"c":false},{"a":41414,"n":"b_A1C6","k":"branch","len":1,"c":false},{"a":41426,"n":"b_A1D2","k":"branch","len":1,"c":false},{"a":41448,"n":"b_A1E8","k":"branch","len":1,"c":false},{"a":41454,"n":"b_A1EE","k":"branch","len":1,"c":false},{"a":41471,"n":"b_A1FF","k":"branch","len":1,"c":false},{"a":41477,"n":"b_A205","k":"branch","len":1,"c":false},{"a":41487,"n":"j_A20F","k":"branch","len":1,"c":false},{"a":41514,"n":"b_A22A","k":"branch","len":1,"c":false},{"a":41524,"n":"b_A234","k":"branch","len":1,"c":false},{"a":41531,"n":"b_A23B","k":"branch","len":1,"c":false},{"a":41537,"n":"b_A241","k":"branch","len":1,"c":false},{"a":41540,"n":"tank_barrel_xoff_table","k":"table","len":5,"c":true},{"a":41545,"n":"tank_aim_window_lo","k":"variable","len":1,"c":true},{"a":41546,"n":"tank_aim_window_hi","k":"table","len":5,"c":true},{"a":41551,"n":"tank_drive_on","k":"routine","len":12,"c":true},{"a":41563,"n":"tank_halt","k":"routine","len":8,"c":true},{"a":41571,"n":"tank_drive_away","k":"routine","len":7,"c":true},{"a":41578,"n":"tank_drive_toward","k":"routine","len":7,"c":true},{"a":41585,"n":"tank_step_right","k":"routine","len":58,"c":true},{"a":41605,"n":"b_A285","k":"branch","len":1,"c":false},{"a":41620,"n":"b_A294","k":"branch","len":1,"c":false},{"a":41642,"n":"r_A2AA","k":"branch","len":1,"c":false},{"a":41643,"n":"tank_step_left","k":"routine","len":25,"c":true},{"a":41668,"n":"tank_fire","k":"routine","len":139,"c":true},{"a":41735,"n":"b_A307","k":"branch","len":1,"c":false},{"a":41750,"n":"j_A316","k":"branch","len":1,"c":false},{"a":41807,"n":"shell_launch_xoff_table","k":"table","len":5,"c":true},{"a":41812,"n":"shell_dy_table","k":"table","len":5,"c":true},{"a":41817,"n":"shell_speed_table","k":"table","len":5,"c":true},{"a":41822,"n":"shell_shape_table","k":"table","len":5,"c":true},{"a":41827,"n":"spawn_scheduler","k":"routine","len":79,"c":true},{"a":41836,"n":"b_A36C","k":"branch","len":1,"c":false},{"a":41843,"n":"b_A373","k":"branch","len":1,"c":false},{"a":41876,"n":"b_A394","k":"branch","len":1,"c":false},{"a":41893,"n":"b_A3A5","k":"branch","len":1,"c":false},{"a":41906,"n":"max_tanks_table","k":"table","len":4,"c":true},{"a":41910,"n":"actor9_limit_table","k":"table","len":4,"c":true},{"a":41914,"n":"aboard_counter_inc","k":"routine","len":25,"c":true},{"a":41938,"n":"r_A3D2","k":"branch","len":1,"c":false},{"a":41939,"n":"aboard_counter_dec","k":"routine","len":25,"c":true},{"a":41964,"n":"rescued_counter_inc","k":"routine","len":20,"c":true},{"a":41984,"n":"killed_tally_sfx","k":"routine","len":19,"c":true},{"a":42003,"n":"heli_fly_controls","k":"routine","len":152,"c":true},{"a":42038,"n":"b_A436","k":"branch","len":1,"c":false},{"a":42046,"n":"b_A43E","k":"branch","len":1,"c":false},{"a":42064,"n":"b_A450","k":"branch","len":1,"c":false},{"a":42079,"n":"j_A45F","k":"branch","len":1,"c":false},{"a":42102,"n":"b_A476","k":"branch","len":1,"c":false},{"a":42112,"n":"b_A480","k":"branch","len":1,"c":false},{"a":42120,"n":"b_A488","k":"branch","len":1,"c":false},{"a":42146,"n":"b_A4A2","k":"branch","len":1,"c":false},{"a":42148,"n":"b_A4A4","k":"branch","len":1,"c":false},{"a":42154,"n":"r_A4AA","k":"branch","len":1,"c":false},{"a":42155,"n":"heli_thrust_lo","k":"variable","len":1,"c":true},{"a":42156,"n":"heli_thrust_hi","k":"table","len":11,"c":true},{"a":42167,"n":"climb_rate_table","k":"table","len":16,"c":true},{"a":42183,"n":"heli_update","k":"routine","len":19,"c":true},{"a":42196,"n":"b_A4D4","k":"branch","len":1,"c":false},{"a":42199,"n":"j_A4D7","k":"branch","len":1,"c":false},{"a":42202,"n":"heli_ground_model","k":"routine","len":228,"c":true},{"a":42213,"n":"b_A4E5","k":"branch","len":1,"c":false},{"a":42230,"n":"b_A4F6","k":"branch","len":1,"c":false},{"a":42237,"n":"b_A4FD","k":"branch","len":1,"c":false},{"a":42251,"n":"b_A50B","k":"branch","len":1,"c":false},{"a":42265,"n":"b_A519","k":"branch","len":1,"c":false},{"a":42271,"n":"j_A51F","k":"branch","len":1,"c":false},{"a":42277,"n":"j_A525","k":"branch","len":1,"c":false},{"a":42283,"n":"j_A52B","k":"branch","len":1,"c":false},{"a":42304,"n":"b_A540","k":"branch","len":1,"c":false},{"a":42323,"n":"b_A553","k":"branch","len":1,"c":false},{"a":42326,"n":"b_A556","k":"branch","len":1,"c":false},{"a":42343,"n":"b_A567","k":"branch","len":1,"c":false},{"a":42349,"n":"b_A56D","k":"branch","len":1,"c":false},{"a":42365,"n":"j_A57D","k":"branch","len":1,"c":false},{"a":42378,"n":"j_A58A","k":"branch","len":1,"c":false},{"a":42402,"n":"b_A5A2","k":"branch","len":1,"c":false},{"a":42417,"n":"b_A5B1","k":"branch","len":1,"c":false},{"a":42425,"n":"b_A5B9","k":"branch","len":1,"c":false},{"a":42430,"n":"heli_bounce","k":"routine","len":35,"c":true},{"a":42465,"n":"heli_ground_push","k":"routine","len":50,"c":true},{"a":42501,"n":"b_A605","k":"branch","len":1,"c":false},{"a":42515,"n":"ground_push_lo","k":"variable","len":1,"c":true},{"a":42516,"n":"ground_push_hi","k":"variable","len":1,"c":true},{"a":42517,"n":"heli_air_model","k":"routine","len":189,"c":true},{"a":42552,"n":"b_A638","k":"branch","len":1,"c":false},{"a":42560,"n":"b_A640","k":"branch","len":1,"c":false},{"a":42594,"n":"b_A662","k":"branch","len":1,"c":false},{"a":42602,"n":"b_A66A","k":"branch","len":1,"c":false},{"a":42618,"n":"b_A67A","k":"branch","len":1,"c":false},{"a":42628,"n":"b_A684","k":"branch","len":1,"c":false},{"a":42636,"n":"b_A68C","k":"branch","len":1,"c":false},{"a":42650,"n":"b_A69A","k":"branch","len":1,"c":false},{"a":42683,"n":"b_A6BB","k":"branch","len":1,"c":false},{"a":42697,"n":"b_A6C9","k":"branch","len":1,"c":false},{"a":42706,"n":"clear_cargo_counter","k":"routine","len":19,"c":true},{"a":42725,"n":"add_to_rescue_counter","k":"routine","len":53,"c":true},{"a":42732,"n":"b_A6EC","k":"branch","len":1,"c":false},{"a":42773,"n":"b_A715","k":"branch","len":1,"c":false},{"a":42778,"n":"read_stick_updown","k":"routine","len":35,"c":true},{"a":42794,"n":"b_A72A","k":"branch","len":1,"c":false},{"a":42808,"n":"b_A738","k":"branch","len":1,"c":false},{"a":42813,"n":"climb_index_table","k":"table","len":4,"c":true},{"a":42817,"n":"read_stick_leftright","k":"routine","len":23,"c":true},{"a":42835,"n":"b_A753","k":"branch","len":1,"c":false},{"a":42840,"n":"bank_input_table","k":"table","len":4,"c":true},{"a":42844,"n":"install_irq_and_sound","k":"routine","len":94,"c":true},{"a":42938,"n":"sound_enabled","k":"routine","len":13,"c":true},{"a":42950,"n":"r_A7C6","k":"branch","len":1,"c":false},{"a":42951,"n":"play_sfx","k":"routine","len":15,"c":true},{"a":42965,"n":"r_A7D5","k":"branch","len":1,"c":false},{"a":42966,"n":"heli_after_move","k":"routine","len":159,"c":true},{"a":42972,"n":"b_A7DC","k":"branch","len":1,"c":false},{"a":42979,"n":"b_A7E3","k":"branch","len":1,"c":false},{"a":42989,"n":"b_A7ED","k":"branch","len":1,"c":false},{"a":43003,"n":"b_A7FB","k":"branch","len":1,"c":false},{"a":43013,"n":"b_A805","k":"branch","len":1,"c":false},{"a":43018,"n":"j_A80A","k":"branch","len":1,"c":false},{"a":43051,"n":"b_A82B","k":"branch","len":1,"c":false},{"a":43058,"n":"b_A832","k":"branch","len":1,"c":false},{"a":43065,"n":"b_A839","k":"branch","len":1,"c":false},{"a":43080,"n":"b_A848","k":"branch","len":1,"c":false},{"a":43091,"n":"b_A853","k":"branch","len":1,"c":false},{"a":43108,"n":"j_A864","k":"branch","len":1,"c":false},{"a":43125,"n":"heli_settle_counter","k":"routine","len":67,"c":true},{"a":43167,"n":"r_A89F","k":"branch","len":1,"c":false},{"a":43168,"n":"b_A8A0","k":"branch","len":1,"c":false},{"a":43171,"n":"j_A8A3","k":"branch","len":1,"c":false},{"a":43178,"n":"j_A8AA","k":"branch","len":1,"c":false},{"a":43187,"n":"b_A8B3","k":"branch","len":1,"c":false},{"a":43192,"n":"heli_set_bank","k":"routine","len":123,"c":true},{"a":43213,"n":"b_A8CD","k":"branch","len":1,"c":false},{"a":43264,"n":"b_A900","k":"branch","len":1,"c":false},{"a":43315,"n":"random_byte","k":"routine","len":4,"c":true},{"a":43319,"n":"actor_free","k":"routine","len":26,"c":true},{"a":43345,"n":"actor_alloc","k":"routine","len":10,"c":true},{"a":43355,"n":"actor_link","k":"routine","len":29,"c":true},{"a":43383,"n":"r_A977","k":"branch","len":1,"c":false},{"a":43384,"n":"draw_bcd_counter","k":"routine","len":37,"c":true},{"a":43420,"n":"r_A99C","k":"branch","len":1,"c":false},{"a":43421,"n":"counter_screen_offsets","k":"table","len":3,"c":true},{"a":43424,"n":"shape_dest_from_actor","k":"routine","len":65,"c":true},{"a":43454,"n":"b_A9BE","k":"branch","len":1,"c":false},{"a":43458,"n":"j_A9C2","k":"branch","len":1,"c":false},{"a":43488,"n":"r_A9E0","k":"branch","len":1,"c":false},{"a":43489,"n":"actor_list_init","k":"routine","len":87,"c":true},{"a":43545,"n":"j_AA19","k":"branch","len":1,"c":false},{"a":43559,"n":"b_AA27","k":"branch","len":1,"c":false},{"a":43576,"n":"queue_colour_stripe","k":"routine","len":47,"c":true},{"a":43623,"n":"draw_horizon_hills","k":"routine","len":58,"c":true},{"a":43672,"n":"j_AA98","k":"branch","len":1,"c":false},{"a":43683,"n":"hills_load_shape","k":"routine","len":3,"c":true},{"a":43688,"n":"hills_blit_copy","k":"routine","len":26,"c":true},{"a":43701,"n":"b_AAB5","k":"branch","len":1,"c":false},{"a":43713,"n":"r_AAC1","k":"branch","len":1,"c":false},{"a":43714,"n":"draw_heli_body","k":"routine","len":253,"c":true},{"a":43725,"n":"b_AACD","k":"branch","len":1,"c":false},{"a":43746,"n":"b_AAE2","k":"branch","len":1,"c":false},{"a":43757,"n":"b_AAED","k":"branch","len":1,"c":false},{"a":43774,"n":"j_AAFE","k":"branch","len":1,"c":false},{"a":43789,"n":"b_AB0D","k":"branch","len":1,"c":false},{"a":43800,"n":"b_AB18","k":"branch","len":1,"c":false},{"a":43811,"n":"j_AB23","k":"branch","len":1,"c":false},{"a":43828,"n":"j_AB34","k":"branch","len":1,"c":false},{"a":43845,"n":"b_AB45","k":"branch","len":1,"c":false},{"a":43870,"n":"j_AB5E","k":"branch","len":1,"c":false},{"a":43879,"n":"b_AB67","k":"branch","len":1,"c":false},{"a":43920,"n":"j_AB90","k":"branch","len":1,"c":false},{"a":43967,"n":"heli_blitter_lo","k":"variable","len":1,"c":true},{"a":43968,"n":"heli_blitter_hi","k":"table","len":13,"c":true},{"a":43981,"n":"draw_heli_rotor","k":"routine","len":125,"c":true},{"a":44075,"n":"b_AC2B","k":"branch","len":1,"c":false},{"a":44080,"n":"j_AC30","k":"branch","len":1,"c":false},{"a":44106,"n":"draw_heli_tail_rotor","k":"routine","len":86,"c":true},{"a":44118,"n":"r_AC56","k":"branch","len":1,"c":false},{"a":44119,"n":"b_AC57","k":"branch","len":1,"c":false},{"a":44143,"n":"b_AC6F","k":"branch","len":1,"c":false},{"a":44153,"n":"j_AC79","k":"branch","len":1,"c":false},{"a":44171,"n":"b_AC8B","k":"branch","len":1,"c":false},{"a":44176,"n":"b_AC90","k":"branch","len":1,"c":false},{"a":44194,"n":"tail_rotor_position","k":"routine","len":12,"c":true},{"a":44208,"n":"tail_rotor_blit","k":"routine","len":7,"c":true},{"a":44215,"n":"heli_muzzle_offset","k":"routine","len":38,"c":true},{"a":44253,"n":"mul8x8_unused","k":"routine","len":20,"c":true},{"a":44257,"n":"b_ACE1","k":"branch","len":1,"c":false},{"a":44264,"n":"b_ACE8","k":"branch","len":1,"c":false},{"a":44273,"n":"asr16","k":"routine","len":51,"c":true},{"a":44295,"n":"b_AD07","k":"branch","len":1,"c":false},{"a":44323,"n":"r_AD23","k":"branch","len":1,"c":false},{"a":44324,"n":"shot_velocity_from_heli","k":"routine","len":98,"c":true},{"a":44335,"n":"b_AD2F","k":"branch","len":1,"c":false},{"a":44357,"n":"b_AD45","k":"branch","len":1,"c":false},{"a":44374,"n":"b_AD56","k":"branch","len":1,"c":false},{"a":44383,"n":"b_AD5F","k":"branch","len":1,"c":false},{"a":44408,"n":"b_AD78","k":"branch","len":1,"c":false},{"a":44422,"n":"shot_field3_table","k":"table","len":4,"c":true},{"a":44426,"n":"jet_state_frame_counts","k":"table","len":5,"c":true},{"a":44431,"n":"actor_jet","k":"routine","len":75,"c":true},{"a":44508,"n":"jet_shape_size","k":"routine","len":20,"c":true},{"a":44530,"n":"jet_draw_and_move","k":"routine","len":464,"c":true},{"a":44558,"n":"b_AE0E","k":"branch","len":1,"c":false},{"a":44561,"n":"j_AE11","k":"branch","len":1,"c":false},{"a":44583,"n":"b_AE27","k":"branch","len":1,"c":false},{"a":44616,"n":"b_AE48","k":"branch","len":1,"c":false},{"a":44640,"n":"b_AE60","k":"branch","len":1,"c":false},{"a":44648,"n":"j_AE68","k":"branch","len":1,"c":false},{"a":44674,"n":"b_AE82","k":"branch","len":1,"c":false},{"a":44680,"n":"j_AE88","k":"branch","len":1,"c":false},{"a":44683,"n":"b_AE8B","k":"branch","len":1,"c":false},{"a":44699,"n":"b_AE9B","k":"branch","len":1,"c":false},{"a":44702,"n":"b_AE9E","k":"branch","len":1,"c":false},{"a":44713,"n":"b_AEA9","k":"branch","len":1,"c":false},{"a":44716,"n":"b_AEAC","k":"branch","len":1,"c":false},{"a":44722,"n":"b_AEB2","k":"branch","len":1,"c":false},{"a":44759,"n":"b_AED7","k":"branch","len":1,"c":false},{"a":44770,"n":"b_AEE2","k":"branch","len":1,"c":false},{"a":44791,"n":"b_AEF7","k":"branch","len":1,"c":false},{"a":44800,"n":"b_AF00","k":"branch","len":1,"c":false},{"a":44808,"n":"b_AF08","k":"branch","len":1,"c":false},{"a":44837,"n":"b_AF25","k":"branch","len":1,"c":false},{"a":44840,"n":"b_AF28","k":"branch","len":1,"c":false},{"a":44853,"n":"b_AF35","k":"branch","len":1,"c":false},{"a":44866,"n":"j_AF42","k":"branch","len":1,"c":false},{"a":44879,"n":"j_AF4F","k":"branch","len":1,"c":false},{"a":44897,"n":"b_AF61","k":"branch","len":1,"c":false},{"a":44900,"n":"b_AF64","k":"branch","len":1,"c":false},{"a":44922,"n":"b_AF7A","k":"branch","len":1,"c":false},{"a":44934,"n":"b_AF86","k":"branch","len":1,"c":false},{"a":44937,"n":"j_AF89","k":"branch","len":1,"c":false},{"a":44954,"n":"b_AF9A","k":"branch","len":1,"c":false},{"a":44971,"n":"b_AFAB","k":"branch","len":1,"c":false},{"a":44988,"n":"b_AFBC","k":"branch","len":1,"c":false},{"a":44993,"n":"r_AFC1","k":"branch","len":1,"c":false},{"a":44994,"n":"jet_script_lo","k":"variable","len":1,"c":true},{"a":44995,"n":"jet_script_hi","k":"table","len":9,"c":true},{"a":45004,"n":"jet_shape_base_lo","k":"variable","len":1,"c":true},{"a":45005,"n":"jet_shape_base_hi","k":"table","len":9,"c":true},{"a":45014,"n":"actor_helicopter","k":"routine","len":43,"c":true},{"a":45057,"n":"heli_actor_fire","k":"routine","len":108,"c":true},{"a":45111,"n":"b_B037","k":"branch","len":1,"c":false},{"a":45116,"n":"j_B03C","k":"branch","len":1,"c":false},{"a":45134,"n":"b_B04E","k":"branch","len":1,"c":false},{"a":45141,"n":"b_B055","k":"branch","len":1,"c":false},{"a":45167,"n":"heli_airburst_draw","k":"routine","len":19,"c":true},{"a":45188,"n":"heli_wreck","k":"routine","len":78,"c":true},{"a":45197,"n":"b_B08D","k":"branch","len":1,"c":false},{"a":45262,"n":"j_B0CE","k":"branch","len":1,"c":false},{"a":45266,"n":"count_person_lost","k":"routine","len":52,"c":true},{"a":45313,"n":"b_B101","k":"branch","len":1,"c":false},{"a":45318,"n":"act_explosion","k":"routine","len":26,"c":true},{"a":45346,"n":"act_explosion_pos","k":"routine","len":26,"c":true},{"a":45363,"n":"b_B133","k":"branch","len":1,"c":false},{"a":45374,"n":"act_explosion_blit","k":"routine","len":48,"c":true},{"a":45385,"n":"b_B149","k":"branch","len":1,"c":false},{"a":45398,"n":"b_B156","k":"branch","len":1,"c":false},{"a":45419,"n":"b_B16B","k":"branch","len":1,"c":false},{"a":45422,"n":"act_heli_shot","k":"routine","len":12,"c":true},{"a":45436,"n":"act_heli_shot_shape","k":"routine","len":3,"c":true},{"a":45441,"n":"act_heli_shot_move","k":"routine","len":103,"c":true},{"a":45454,"n":"b_B18E","k":"branch","len":1,"c":false},{"a":45463,"n":"b_B197","k":"branch","len":1,"c":false},{"a":45484,"n":"b_B1AC","k":"branch","len":1,"c":false},{"a":45493,"n":"b_B1B5","k":"branch","len":1,"c":false},{"a":45498,"n":"b_B1BA","k":"branch","len":1,"c":false},{"a":45516,"n":"b_B1CC","k":"branch","len":1,"c":false},{"a":45537,"n":"j_B1E1","k":"branch","len":1,"c":false},{"a":45544,"n":"act_jet_shell","k":"routine","len":11,"c":true},{"a":45557,"n":"act_jet_shell_shape","k":"routine","len":3,"c":true},{"a":45562,"n":"act_jet_shell_move","k":"routine","len":39,"c":true},{"a":45575,"n":"b_B207","k":"branch","len":1,"c":false},{"a":45590,"n":"b_B216","k":"branch","len":1,"c":false},{"a":45601,"n":"act_jet_rocket","k":"routine","len":11,"c":true},{"a":45614,"n":"act_jet_rocket_shape","k":"routine","len":3,"c":true},{"a":45619,"n":"act_jet_rocket_move","k":"routine","len":58,"c":true},{"a":45642,"n":"b_B24A","k":"branch","len":1,"c":false},{"a":45645,"n":"b_B24D","k":"branch","len":1,"c":false},{"a":45666,"n":"b_B262","k":"branch","len":1,"c":false},{"a":45677,"n":"act_shell","k":"routine","len":10,"c":true},{"a":45689,"n":"act_shell_shape","k":"routine","len":3,"c":true},{"a":45694,"n":"act_shell_move","k":"routine","len":44,"c":true},{"a":45707,"n":"b_B28B","k":"branch","len":1,"c":false},{"a":45722,"n":"b_B29A","k":"branch","len":1,"c":false},{"a":45738,"n":"actor_step","k":"routine","len":64,"c":true},{"a":45766,"n":"b_B2C6","k":"branch","len":1,"c":false},{"a":45768,"n":"j_B2C8","k":"branch","len":1,"c":false},{"a":45802,"n":"actor_to_explosion","k":"routine","len":29,"c":true},{"a":45825,"n":"b_B301","k":"branch","len":1,"c":false},{"a":45830,"n":"r_B306","k":"branch","len":1,"c":false},{"a":45831,"n":"actor_dispatch","k":"routine","len":34,"c":true},{"a":45834,"n":"b_B30A","k":"branch","len":1,"c":false},{"a":45865,"n":"actor_dispatch_next","k":"routine","len":5,"c":true},{"a":45870,"n":"actor_handler_lo","k":"variable","len":1,"c":true},{"a":45871,"n":"actor_handler_hi","k":"table","len":21,"c":true},{"a":45892,"n":"shot_hit_test","k":"routine","len":239,"c":true},{"a":45904,"n":"b_B350","k":"branch","len":1,"c":false},{"a":45947,"n":"b_B37B","k":"branch","len":1,"c":false},{"a":45964,"n":"b_B38C","k":"branch","len":1,"c":false},{"a":45991,"n":"b_B3A7","k":"branch","len":1,"c":false},{"a":45997,"n":"b_B3AD","k":"branch","len":1,"c":false},{"a":46027,"n":"b_B3CB","k":"branch","len":1,"c":false},{"a":46038,"n":"b_B3D6","k":"branch","len":1,"c":false},{"a":46049,"n":"b_B3E1","k":"branch","len":1,"c":false},{"a":46060,"n":"b_B3EC","k":"branch","len":1,"c":false},{"a":46085,"n":"b_B405","k":"branch","len":1,"c":false},{"a":46107,"n":"b_B41B","k":"branch","len":1,"c":false},{"a":46114,"n":"b_B422","k":"branch","len":1,"c":false},{"a":46121,"n":"b_B429","k":"branch","len":1,"c":false},{"a":46130,"n":"r_B432","k":"branch","len":1,"c":false},{"a":46131,"n":"rocket_hits_heli","k":"routine","len":65,"c":true},{"a":46148,"n":"b_B444","k":"branch","len":1,"c":false},{"a":46168,"n":"b_B458","k":"branch","len":1,"c":false},{"a":46175,"n":"b_B45F","k":"branch","len":1,"c":false},{"a":46182,"n":"b_B466","k":"branch","len":1,"c":false},{"a":46196,"n":"mine_hits_heli","k":"routine","len":59,"c":true},{"a":46213,"n":"b_B485","k":"branch","len":1,"c":false},{"a":46233,"n":"b_B499","k":"branch","len":1,"c":false},{"a":46240,"n":"b_B4A0","k":"branch","len":1,"c":false},{"a":46247,"n":"b_B4A7","k":"branch","len":1,"c":false},{"a":46255,"n":"ground_burst_effects","k":"routine","len":163,"c":true},{"a":46274,"n":"r_B4C2","k":"branch","len":1,"c":false},{"a":46275,"n":"b_B4C3","k":"branch","len":1,"c":false},{"a":46301,"n":"b_B4DD","k":"branch","len":1,"c":false},{"a":46313,"n":"b_B4E9","k":"branch","len":1,"c":false},{"a":46322,"n":"b_B4F2","k":"branch","len":1,"c":false},{"a":46327,"n":"b_B4F7","k":"branch","len":1,"c":false},{"a":46372,"n":"b_B524","k":"branch","len":1,"c":false},{"a":46380,"n":"b_B52C","k":"branch","len":1,"c":false},{"a":46388,"n":"b_B534","k":"branch","len":1,"c":false},{"a":46393,"n":"b_B539","k":"branch","len":1,"c":false},{"a":46418,"n":"ground_burst_vs_tanks","k":"routine","len":93,"c":true},{"a":46428,"n":"r_B55C","k":"branch","len":1,"c":false},{"a":46429,"n":"b_B55D","k":"branch","len":1,"c":false},{"a":46430,"n":"b_B55E","k":"branch","len":1,"c":false},{"a":46447,"n":"j_B56F","k":"branch","len":1,"c":false},{"a":46451,"n":"b_B573","k":"branch","len":1,"c":false},{"a":46481,"n":"b_B591","k":"branch","len":1,"c":false},{"a":46492,"n":"b_B59C","k":"branch","len":1,"c":false},{"a":46503,"n":"b_B5A7","k":"branch","len":1,"c":false},{"a":46511,"n":"heli_destroyed","k":"routine","len":12,"c":true},{"a":46523,"n":"tank_destroyed","k":"routine","len":17,"c":true},{"a":46540,"n":"tank_list_remove","k":"routine","len":41,"c":true},{"a":46545,"n":"j_B5D1","k":"branch","len":1,"c":false},{"a":46562,"n":"b_B5E2","k":"branch","len":1,"c":false},{"a":46568,"n":"b_B5E8","k":"branch","len":1,"c":false},{"a":46574,"n":"b_B5EE","k":"branch","len":1,"c":false},{"a":46580,"n":"r_B5F4","k":"branch","len":1,"c":false},{"a":46581,"n":"jet_list_remove","k":"routine","len":42,"c":true},{"a":46586,"n":"j_B5FA","k":"branch","len":1,"c":false},{"a":46604,"n":"b_B60C","k":"branch","len":1,"c":false},{"a":46610,"n":"b_B612","k":"branch","len":1,"c":false},{"a":46616,"n":"b_B618","k":"branch","len":1,"c":false},{"a":46622,"n":"r_B61E","k":"branch","len":1,"c":false},{"a":46623,"n":"jet_destroyed","k":"routine","len":17,"c":true},{"a":46640,"n":"mine_destroyed","k":"routine","len":14,"c":true},{"a":46654,"n":"kill_person","k":"routine","len":20,"c":true},{"a":46674,"n":"open_shed","k":"routine","len":19,"c":true},{"a":46692,"n":"r_B664","k":"branch","len":1,"c":false},{"a":46693,"n":"jet_fire_rockets","k":"routine","len":136,"c":true},{"a":46787,"n":"b_B6C3","k":"branch","len":1,"c":false},{"a":46829,"n":"jet_fire_shell","k":"routine","len":80,"c":true},{"a":46889,"n":"b_B729","k":"branch","len":1,"c":false},{"a":46909,"n":"act_air_mine","k":"routine","len":17,"c":true},{"a":46928,"n":"act_air_mine_shape","k":"routine","len":3,"c":true},{"a":46933,"n":"act_air_mine_move","k":"routine","len":181,"c":true},{"a":46956,"n":"b_B76C","k":"branch","len":1,"c":false},{"a":46961,"n":"b_B771","k":"branch","len":1,"c":false},{"a":46988,"n":"b_B78C","k":"branch","len":1,"c":false},{"a":47030,"n":"b_B7B6","k":"branch","len":1,"c":false},{"a":47051,"n":"b_B7CB","k":"branch","len":1,"c":false},{"a":47066,"n":"b_B7DA","k":"branch","len":1,"c":false},{"a":47078,"n":"b_B7E6","k":"branch","len":1,"c":false},{"a":47099,"n":"b_B7FB","k":"branch","len":1,"c":false},{"a":47114,"n":"actor10_move_and_shoot","k":"routine","len":164,"c":true},{"a":47219,"n":"b_B873","k":"branch","len":1,"c":false},{"a":47248,"n":"b_B890","k":"branch","len":1,"c":false},{"a":47264,"n":"b_B8A0","k":"branch","len":1,"c":false},{"a":47278,"n":"draw_sheds","k":"routine","len":58,"c":true},{"a":47290,"n":"b_B8BA","k":"branch","len":1,"c":false},{"a":47314,"n":"j_B8D2","k":"branch","len":1,"c":false},{"a":47338,"n":"shed_pick_body_shape","k":"routine","len":21,"c":true},{"a":47361,"n":"shed_body_draw","k":"routine","len":15,"c":true},{"a":47369,"n":"b_B909","k":"branch","len":1,"c":false},{"a":47378,"n":"shed_ground_shape","k":"routine","len":3,"c":true},{"a":47383,"n":"shed_ground_draw","k":"routine","len":46,"c":true},{"a":47391,"n":"b_B91F","k":"branch","len":1,"c":false},{"a":47426,"n":"b_B942","k":"branch","len":1,"c":false},{"a":47431,"n":"shed_doorway_shape","k":"routine","len":3,"c":true},{"a":47436,"n":"shed_doorway_draw","k":"routine","len":37,"c":true},{"a":47453,"n":"b_B95D","k":"branch","len":1,"c":false},{"a":47456,"n":"j_B960","k":"branch","len":1,"c":false},{"a":47472,"n":"r_B970","k":"branch","len":1,"c":false},{"a":47473,"n":"draw_parallax_scenery","k":"routine","len":172,"c":true},{"a":47489,"n":"b_B981","k":"branch","len":1,"c":false},{"a":47533,"n":"b_B9AD","k":"branch","len":1,"c":false},{"a":47624,"n":"b_BA08","k":"branch","len":1,"c":false},{"a":47647,"n":"parallax_shape","k":"routine","len":3,"c":true},{"a":47652,"n":"parallax_draw_one","k":"routine","len":23,"c":true},{"a":47669,"n":"b_BA35","k":"branch","len":1,"c":false},{"a":47675,"n":"parallax_rows","k":"table","len":4,"c":true},{"a":47679,"n":"draw_home_base","k":"routine","len":38,"c":true},{"a":47689,"n":"b_BA49","k":"branch","len":1,"c":false},{"a":47719,"n":"base_apron_record_load","k":"routine","len":3,"c":true},{"a":47724,"n":"base_apron_fill","k":"routine","len":16,"c":true},{"a":47732,"n":"b_BA74","k":"branch","len":1,"c":false},{"a":47742,"n":"base_wedge_shape","k":"routine","len":3,"c":true},{"a":47747,"n":"base_wedge_left","k":"routine","len":24,"c":true},{"a":47753,"n":"b_BA89","k":"branch","len":1,"c":false},{"a":47773,"n":"base_wedge_right","k":"routine","len":22,"c":true},{"a":47781,"n":"b_BAA5","k":"branch","len":1,"c":false},{"a":47797,"n":"base_bunker_shape","k":"routine","len":3,"c":true},{"a":47802,"n":"base_bunker_left","k":"routine","len":23,"c":true},{"a":47827,"n":"base_bunker_right","k":"routine","len":22,"c":true},{"a":47835,"n":"b_BADB","k":"branch","len":1,"c":false},{"a":47851,"n":"base_flagpole_shape","k":"routine","len":3,"c":true},{"a":47856,"n":"base_flagpole","k":"routine","len":21,"c":true},{"a":47862,"n":"b_BAF6","k":"branch","len":1,"c":false},{"a":47879,"n":"base_flag_pick","k":"routine","len":19,"c":true},{"a":47900,"n":"base_flag_draw","k":"routine","len":9,"c":true},{"a":47908,"n":"r_BB24","k":"branch","len":1,"c":false},{"a":47909,"n":"base_apron_record","k":"table","len":6,"c":true},{"a":47915,"n":"new_game_reset","k":"routine","len":159,"c":true},{"a":47947,"n":"b_BB4B","k":"branch","len":1,"c":false},{"a":48010,"n":"b_BB8A","k":"branch","len":1,"c":false},{"a":48040,"n":"b_BBA8","k":"branch","len":1,"c":false},{"a":48058,"n":"j_BBBA","k":"branch","len":1,"c":false},{"a":48073,"n":"r_BBC9","k":"branch","len":1,"c":false},{"a":48074,"n":"clear_both_bitmaps","k":"routine","len":28,"c":true},{"a":48102,"n":"erase_last_frame","k":"routine","len":166,"c":true},{"a":48131,"n":"b_BC03","k":"branch","len":1,"c":false},{"a":48133,"n":"j_BC05","k":"branch","len":1,"c":false},{"a":48182,"n":"b_BC36","k":"branch","len":1,"c":false},{"a":48189,"n":"b_BC3D","k":"branch","len":1,"c":false},{"a":48218,"n":"b_BC5A","k":"branch","len":1,"c":false},{"a":48252,"n":"b_BC7C","k":"branch","len":1,"c":false},{"a":48270,"n":"erase_rect_paint","k":"routine","len":3,"c":true},{"a":48275,"n":"erase_rect_next","k":"routine","len":15,"c":true},{"a":48278,"n":"b_BC96","k":"branch","len":1,"c":false},{"a":48285,"n":"b_BC9D","k":"branch","len":1,"c":false},{"a":48290,"n":"scroll_camera","k":"routine","len":300,"c":true},{"a":48311,"n":"b_BCB7","k":"branch","len":1,"c":false},{"a":48315,"n":"b_BCBB","k":"branch","len":1,"c":false},{"a":48318,"n":"b_BCBE","k":"branch","len":1,"c":false},{"a":48329,"n":"b_BCC9","k":"branch","len":1,"c":false},{"a":48332,"n":"b_BCCC","k":"branch","len":1,"c":false},{"a":48359,"n":"b_BCE7","k":"branch","len":1,"c":false},{"a":48375,"n":"b_BCF7","k":"branch","len":1,"c":false},{"a":48389,"n":"b_BD05","k":"branch","len":1,"c":false},{"a":48405,"n":"b_BD15","k":"branch","len":1,"c":false},{"a":48408,"n":"j_BD18","k":"branch","len":1,"c":false},{"a":48440,"n":"b_BD38","k":"branch","len":1,"c":false},{"a":48456,"n":"b_BD48","k":"branch","len":1,"c":false},{"a":48469,"n":"j_BD55","k":"branch","len":1,"c":false},{"a":48475,"n":"b_BD5B","k":"branch","len":1,"c":false},{"a":48492,"n":"b_BD6C","k":"branch","len":1,"c":false},{"a":48495,"n":"b_BD6F","k":"branch","len":1,"c":false},{"a":48509,"n":"b_BD7D","k":"branch","len":1,"c":false},{"a":48512,"n":"b_BD80","k":"branch","len":1,"c":false},{"a":48526,"n":"b_BD8E","k":"branch","len":1,"c":false},{"a":48540,"n":"j_BD9C","k":"branch","len":1,"c":false},{"a":48554,"n":"b_BDAA","k":"branch","len":1,"c":false},{"a":48565,"n":"b_BDB5","k":"branch","len":1,"c":false},{"a":48579,"n":"b_BDC3","k":"branch","len":1,"c":false},{"a":48587,"n":"b_BDCB","k":"branch","len":1,"c":false},{"a":48592,"n":"scroll_unchanged","k":"routine","len":1,"c":true},{"a":48593,"n":"scroll_step_size","k":"routine","len":76,"c":true},{"a":48615,"n":"b_BDE7","k":"branch","len":1,"c":false},{"a":48654,"n":"b_BE0E","k":"branch","len":1,"c":false},{"a":48666,"n":"b_BE1A","k":"branch","len":1,"c":false},{"a":48669,"n":"shift_left_signed_unused","k":"table","len":53,"c":true},{"a":48722,"n":"start_sortie_world","k":"routine","len":99,"c":true},{"a":48761,"n":"j_BE79","k":"branch","len":1,"c":false},{"a":48798,"n":"b_BE9E","k":"branch","len":1,"c":false},{"a":48820,"n":"r_BEB4","k":"branch","len":1,"c":false},{"a":48821,"n":"reset_helicopter","k":"routine","len":81,"c":true},{"a":48902,"n":"cold_init","k":"routine","len":249,"c":true},{"a":48909,"n":"b_BF0D","k":"branch","len":1,"c":false},{"a":48955,"n":"b_BF3B","k":"branch","len":1,"c":false},{"a":48957,"n":"b_BF3D","k":"branch","len":1,"c":false},{"a":49003,"n":"b_BF6B","k":"branch","len":1,"c":false},{"a":49017,"n":"b_BF79","k":"branch","len":1,"c":false},{"a":49024,"n":"j_BF80","k":"branch","len":1,"c":false},{"a":49033,"n":"b_BF89","k":"branch","len":1,"c":false},{"a":49082,"n":"b_BFBA","k":"branch","len":1,"c":false},{"a":49131,"n":"b_BFEB","k":"branch","len":1,"c":false}],"records":[{"a":0,"l":"cpu_ddr","c":"6510 data direction register. The game never writes it; the loader leaves the KERNAL's $2F here, which makes bits 0-5 outputs so that the bank bits in $01 work. Listed only because the disassembler mints a symbol for it.","t":"byte","b":[255],"x":[43947,44097]},{"a":1,"l":"cpu_port","c":"6510 processor port. The game runs with $36 here (BASIC ROM out, I/O in, KERNAL in), set by the loader before it jumps to $9593. The only code that touches it is the character-set copy at $BFA2-$BFCF, which clears bit 2 (CHAREN) so the character ROM appears at $D000, copies $D000-$D7FF to $5000-$57FF, and sets bit 2 again.","t":"byte","b":[0],"x":[49058,49062,49099,49103]},{"a":2,"l":"msg_showing","c":"Non-zero while one of the five centred messages ($8A8B) is on screen: $8A97 leaves the message pointer's high byte here and $8AC7 leaves 0 when it wipes the message. The raster handler at $9A85 adds it to $93 and, if the sum is zero, skips the mid-screen text window and sets the next raster interrupt to line $E0 instead of $81. Also cleared at $95EB and by the cold start at $BF08.","t":"byte","b":[0],"x":[35479,35537,38379,39557,48904]},{"a":3,"l":"draw_row","c":"Bitmap row of the first row of the shape being drawn, counted upward from the bottom of the play area (0-167), i.e. an index into the row-address tables at $0A00/$0AA8. $8B91 loads it from the third byte of the caller's parameter block; $8C6A and $8E7A copy it into the working row $31 and $90EF into $0B.","t":"byte","b":[25],"x":[35709,35750,35946,36474,36761,36782,37103]},{"a":4,"l":"draw_x","c":"Low byte of the 16-bit X of the shape being drawn, in bitmap pixels. $8B91 loads $04/$05 from the first two bytes of the caller's parameter block. $8DD0 splits the pair into a byte column ($08) and a bit position ($09); $8C89, $8EB4, $9115 and $9173 add this byte masked with $F8 to a row address to reach the bitmap byte to write.","t":"byte","b":[129],"x":[35699,35740,35977,36229,36235,36248,36269,36271,36296,36304,36310,36332,36532,36650,36690,37112,37116,37141,37235]},{"a":5,"l":"zpa_05","c":"High byte of the 16-bit draw X whose low byte is $04. $8DD8-$8DE0 shifts $05:$04 right three times to produce the byte column in $08, restoring the pair from $12/$13 afterwards; $8C99, $8EC2, $9123 and $9181 add it to the high byte of the row address.","t":"byte","b":[1],"x":[35704,35745,35993,36237,36243,36252,36273,36277,36300,36312,36315,36318,36336,36546,36656,36692,37118,37122,37155,37249]},{"a":6,"l":"bmp_ptr","c":"Pointer to the bitmap byte the blitter is writing. Built at $8C84-$8C9B, $8EAF-$8EC4, $9110-$9125 and $916E-$9183 from the row-address tables plus the byte column, with $0F eored into the high byte to pick the buffer; $9000-$90AD and $915A read-modify-write through it. The same pair doubles as the message-string pointer in $8A90-$8AB8 and as the star address in $9228-$9248.","t":"byte","b":[130],"x":[35472,35496,35507,35512,35975,35982,35984,36026,36178,36193,36198,36203,36530,36537,36539,36877,36879,36906,36908,37006,37010,37033,37037,37139,37146,37148,37210,37212,37233,37240,37242,37424,37448]},{"a":7,"l":"zpa_07","c":"High byte of the bitmap write pointer in $06: a row-table high byte plus $05 with the double-buffer bit from $0F already folded in, so it points into $2000-$3F3F or $6000-$7F3F. Written at $8C9B, $8D59, $8D71, $8EC4, $9125, $9183 and $9237.","t":"byte","b":[124],"x":[35477,35995,36185,36205,36209,36548,37157,37251,37431]},{"a":8,"l":"draw_col","c":"X of the shape being drawn in whole bitmap bytes (draw X >> 3), computed by $8DD0. $8C6F-$8C7C clamps a horizontal bar so that this column plus the width does not run past column 40; $9135 uses it to measure how far a sheared line has moved, and $920F/$921C step it when the pixel mask falls out of its byte.","t":"byte","b":[33],"x":[35951,35962,36016,36321,36896,36949,36956,37163,37173,37182,37391,37404]},{"a":9,"l":"draw_bit","c":"Bit position of the draw X inside its byte. $8DD0 leaves 8 minus (X and 7) here and $8DBE turns that count into a single-bit mask; $9207 and $9214 rotate the mask when a sheared line moves one pixel sideways, carrying into the byte column $08.","t":"byte","b":[1],"x":[36284,36293,36308,36326,36328,36411,36834,36836,36976,37159,37186,37383,37389,37396,37402]},{"a":10,"l":"zpa_0A","c":"Blitter scratch: the shape byte after it has been shifted into position, saved by $8E96 and re-read at $900B, $9028, $908C and $90A7 so the same value can be ored into two adjacent bitmap bytes.","t":"byte","b":[0],"x":[36502,36875,36887,36904,36971,37004,37016,37031]},{"a":11,"l":"zpa_0B","c":"Row counter of the sheared-line drawer at $90E9-$91FA: $90EF copies the starting row from $03, $910C reloads it into $31 at the top of each row and $91F4 decrements it once per shape row.","t":"byte","b":[140],"x":[37105,37132,37364]},{"a":12,"l":"zpa_0C","c":"Blitter column state. In the flat blitter ($8EA0, $9077, $9088) it is the number of shifts still to apply to the current shape byte; in the sheared drawer ($9144-$91BF) it is the single-bit pixel mask, rotated left or right according to bit 7 of $2F and reset to $80 or $01 when it falls out of the byte.","t":"byte","b":[8],"x":[36512,36983,37000,37188,37206,37287,37293,37305,37311]},{"a":13,"l":"zpa_0D","c":"Offset from the row base to the bitmap byte currently being written, used as the index in sta ($06),y. $8E9A clears it, $9011 and $90B8 step it by a row, $913A sets it from the difference between two byte columns, and $91B1/$91C4 move it by eight when the sheared drawer changes byte column.","t":"byte","b":[1],"x":[36506,36860,36881,37048,37050,37178,37208,37295,37300,37313,37318]},{"a":14,"l":"zpa_0E","c":"Width counter of the blitter's inner loop: $8E92 and $9148 load it with the (clipped) shape width from $10 and $9019, $9081 and $91C8 count it down to zero, one pixel per pass.","t":"byte","b":[0],"x":[36498,36852,36889,36993,37192,37320]},{"a":15,"l":"vic_bank_bit","c":"Double-buffer selector: 0 while bank 0 (matrix $0400, bitmap $2000) is the drawing target, $40 while bank 1 (matrix $4400, bitmap $6000) is. $8D0F clears it, $8D16 flips it with eor #$40 and $8D1F writes the matching VIC bank number into $DD00. Every row-address high byte is eored with it ($8C97, $8EC0, $9121, $917F, $9235), which is what puts the two bitmaps exactly $4000 apart.","t":"byte","b":[64],"x":[35991,36070,36114,36119,36123,36136,36183,36544,37153,37247,37429]},{"a":16,"l":"shape_w","c":"Width in bitmap bits of the shape being drawn, read from the shape's first header byte by $8EEE or $8F0D. $8E68 subtracts the left and right clip counts ($22, $23) from it, $8DF3 rounds it up to whole bytes into $2A, and $8E92/$9148 copy it into the inner-loop counter $0E.","t":"byte","b":[27],"x":[35953,35964,36014,36222,36264,36339,36421,36425,36456,36463,36496,36590,36621,36680,36748,36753,36844,37190]},{"a":17,"l":"shape_h","c":"Height in rows of the shape being drawn, read from the shape's second header byte by $8EF3 or $8F12. $8E71 subtracts the top and bottom clip counts ($24, $25); $8CD0, $902E, $90AF and $91EA count it down, one pass per shape row.","t":"byte","b":[11],"x":[36048,36465,36472,36595,36626,36774,36800,36910,37039,37354]},{"a":18,"l":"zpa_12","c":"Low byte of the general 16-bit scratch pair used all over the drawing code: $8DC8 and $8D98 park a copy of the draw X here while $8DD0 destroys the original, $8CAC holds one of the two bytes the horizontal-bar drawer alternates into the bitmap, and $8E0F collects the low half of the product of the row length by the top clip count.","t":"byte","b":[147],"x":[36012,36024,36162,36191,36231,36250,36298,36330,36367,36377,36666,36678,36684,36705,36721,36730,36734,36746,36755]},{"a":19,"l":"zpa_13","c":"High half of the $12/$13 scratch pair: the saved high byte of the draw X ($8DCE, $8D9E), the second of the two bytes the bar drawer alternates ($8CC4), and the high half of the shape-data offset that $8E1F adds to the shape pointer $17/$18.","t":"byte","b":[18],"x":[36007,36036,36239,36254,36302,36334,36372,36383,36672,36674,36711,36713,36736,36740,36742]},{"a":20,"l":"zpa_14","c":"General byte scratch of the drawing and message code: the count of characters still to print in $8AAB-$8AC2, the run length of a horizontal bar in $8D44-$8D4D, and the low byte of the clip-offset multiply at $8E01-$8E39.","t":"byte","b":[14],"x":[35499,35504,35509,35522,36164,36169,36173,36214,36226,36233,36353,36359,36398,36403,36409,36415,36427,37161,37184]},{"a":21,"l":"zpa_15","c":"Row counter of the horizontal-bar drawer ($8D4B, $8D78) and of the tall-shape loop at $9057-$9069; $912B-$9142 also uses it to remember the byte column across a call to $8DC8.","t":"byte","b":[8],"x":[36171,36216,36951,36959,36964,36969,37165,37170,37180]},{"a":22,"l":"zpa_16","c":"The shape byte currently being unpacked, shifted left one bit per pixel by $8EAB and $9152 so that bit 7 is always the next pixel; $91E5 reloads it from the next shape byte every eight pixels and $9150 primes it in the sheared drawer.","t":"byte","b":[86],"x":[36523,36985,37002,37200,37202,37349]},{"a":23,"l":"shape_ptr","c":"Pointer into the shape being drawn, and the inline-argument pointer of the $8B1E/$8B38 convention. $8B2A and $8B53 load it with the caller's return address, or with the word that address points at, so the two bytes after the jsr can be read; afterwards $8EE2 and the blitters walk it through the shape bitmap, $8E1B, $8EDB and $91DB advancing it. $8BDD resumes the caller with jmp ($17).","t":"byte","b":[139],"x":[35626,35631,35667,35697,35702,35707,35712,35716,35726,35738,35743,35748,35779,35784,35789,35793,35805,35817,35822,35842,35847,35852,35872,35877,36005,36010,36375,36379,36440,36444,36482,36508,36554,36560,36564,36571,36580,36588,36593,36598,36602,36862,37052,37198,37339,37347,37358]},{"a":24,"l":"zpa_18","c":"High byte of the shape / inline-argument pointer in $17. Written at $8B2D, $8B58, $8BD7, $8E21, $8E64, $8E8A and $8EE8, and carried into at $8B33, $8EDF and $91DF.","t":"byte","b":[128],"x":[35629,35635,35672,35720,35795,35799,36381,36385,36448,36452,36490,36558,36575,36584,36604,36608,37343,37362]},{"a":25,"l":"zpa_19","c":"Blitter scratch used only by the wide-shape path at $8FF6-$90AB: $8FF6 stores the byte fetched from the shape, $907C rotates it right into carry, and $9090 and $90AB or it into the bitmap byte being assembled. $90A2 shifts it again for the second of the two bytes a shifted shape spans.","t":"byte","b":[106],"x":[36854,36893,36981,36988,37008,37026,37035]},{"a":26,"l":"zpa_1A","c":"Bit counter of the sheared-line drawer, 0 to 7: $914C clears it, $91CC increments it once per pixel and $91D0 tests it against 8, at which point $91DB steps the shape pointer $17/$18 on to the next byte and $91E3 refills $16. Its span also covers $1B when nothing else claims it.","t":"byte","b":[6],"x":[37196,37324,37326,37337]},{"a":27,"l":"inline_ret","c":"Return address of a routine that takes an inline pointer. $8B38 pops the caller's return address into $1B/$1C, reads the two-byte pointer that follows the jsr into $17/$18, steps $1B past it, and hands control back with jmp ($1B) from $8BAC, $8BF6, $8C14 and $8C2D.","t":"byte","b":[186],"x":[35652,35657,35665,35670,35675,35679,35756,35830,35860,35885]},{"a":28,"l":"zpa_1C","c":"High byte of the inline-argument return address in $1B, incremented at $8B4D when the pop carries and at $8B63 when stepping past the inline word.","t":"byte","b":[186],"x":[35655,35661,35683]},{"a":29,"l":"save_a","c":"Saved accumulator. Every routine that must not disturb the caller's registers stores A here on entry ($8B91, $8BBA, $8BE0, $8BF9, $8C17, $8C5E, $8F03, $8FD3, $903E, $90D2) and reloads it just before the rts ($8BA8, $8CD9, $8FCC, $9037, $90CB, $9221).","t":"byte","b":[157],"x":[35688,35722,35729,35752,35770,35801,35808,35826,35833,35856,35863,35881,35934,36057,36611,36812,36819,36919,36926,37067,37074,37087,37409]},{"a":30,"l":"save_x","c":"Saved X register, companion of $1D. Written on entry at $8C32, $8C60, $8F05, $8FD5, $9040 and $90D4 and restored at $8C45, $8CDB, $8FCE, $9039, $90CD and $9223.","t":"byte","b":[255],"x":[35890,35909,35936,36059,36613,36814,36821,36921,36928,37069,37076,37089,37411]},{"a":31,"l":"save_y","c":"Saved Y register, the third of the $1D/$1E/$1F save area. Written on entry to all the inline-argument routines ($8B93, $8BBC, $8BE2, $8BFB, $8C19) and to the shape drawers, and reloaded immediately before they return.","t":"byte","b":[8],"x":[35690,35724,35731,35754,35772,35803,35810,35828,35835,35858,35865,35883,35888,35907,35938,36061,36615,36816,36823,36923,36930,37071,37078,37091,37413]},{"a":32,"l":"resume_vec","c":"Two jobs. In $8B1E and $8B38 it is the resume vector: the caller's return address plus one, jumped through by jmp ($20) at $8B35 and $8B65 once the inline argument has been read. In the horizontal-bar drawer it is a second copy of the bitmap pointer $06/$07 ($8C92, $8C9D) that $8CC6 writes the alternate colour byte through.","t":"byte","b":[231],"x":[35618,35637,35644,35685,35986,36038]},{"a":33,"l":"zpa_21","c":"High byte of the $20/$21 resume vector, written at $8B27 and $8B41, and of the bar drawer's second bitmap pointer, written at $8C9D.","t":"byte","b":[139],"x":[35623,35649,35997]},{"a":34,"l":"clip_left","c":"Pixels clipped off the left edge of the shape being drawn. $8CFE zeroes it before every shape and the clipper at $8F35-$8F4E sets it when the shape starts left of the window. $8E23-$8E39 splits it into a whole-byte offset ($27) and a shift ($26) and $8E6B subtracts it from the width.","t":"byte","b":[0],"x":[35763,36097,36387,36394,36459,36686,36932,36936,37059,37063]},{"a":35,"l":"clip_right","c":"Pixels clipped off the right edge of the shape. Zeroed by $8CFE, set at $8F95, and subtracted from the width together with $22 at $8E6D.","t":"byte","b":[0],"x":[35765,36099,36461,36757,36934,36938,37061,37065]},{"a":36,"l":"clip_top","c":"Rows clipped off the top of the shape. Zeroed by $8CFE, set at $8FAA. $8DFD-$8E21 multiplies it by the bytes-per-row in $2A and adds the product to the shape pointer so drawing starts at the first visible row; $8E74 subtracts it from the height.","t":"byte","b":[0],"x":[35767,36101,36349,36468,36778]},{"a":37,"l":"clip_bottom","c":"Rows clipped off the bottom of the shape. Zeroed by $8CFE, set by $8BAF (which also clears $22-$24) and by $8FC9, and subtracted from the height at $8E76.","t":"byte","b":[0],"x":[35759,36103,36470,36809]},{"a":38,"l":"zpa_26","c":"Eight minus the left-clip remainder ($22 and 7), computed at $8E35. $8E9E-$8EA4 uses it as the number of left shifts applied to the first shape byte of each row so the clipped-off pixels fall out of the byte.","t":"byte","b":[8],"x":[36405,36510]},{"a":39,"l":"zpa_27","c":"Left clip in whole shape bytes ($22 >> 3), computed at $8E28 and added to the shape pointer at $8E5A. $8E43 bumps it by one when the shape has to be nudged a whole byte, and $8EC6 tests it to decide whether a partial byte from before the row start has to be fetched.","t":"byte","b":[0],"x":[36392,36419,36442,36550]},{"a":40,"l":"zpa_28","c":"Running pointer to the start of the shape row being drawn. $8E5E/$8E66 set it from $17/$18 once the clipping offsets are folded in, and $8E7F-$8E8E copies it into $17/$18 and then advances it by one row ($2A bytes) ready for the next pass.","t":"byte","b":[228],"x":[36446,36480,36486]},{"a":41,"l":"zpa_29","c":"High byte of the shape-row pointer in $28, set at $8E66 and carried at $8E8C; $8E88 reloads it into $18 at the top of each row.","t":"byte","b":[137],"x":[36454,36488,36494]},{"a":42,"l":"zpa_2A","c":"Bytes per row of the shape being drawn, ($10 + 7) >> 3, computed at $8DF3-$8DFB. $8E0C uses it as the multiplicand when skipping clipped rows and $8E84 adds it to the row pointer $28/$29 once per row.","t":"byte","b":[2],"x":[36347,36364,36484]},{"a":43,"l":"slope_run","c":"Run length of the slope used by the sheared drawer at $90E9: the number of pixel columns to cover before stepping one bitmap row. $8C30 looks it up, together with $2C, in the eleven-entry table at $8C48 from a slope index of -5..+5; the values are 0, 3, 4, 5, 10 and 13. $9104, $9162 and $91FD reload the counters $30, $32 and $33 from it.","t":"byte","b":[0],"x":[35905,36074,37107,37124,37218,37262,37269,37373]},{"a":44,"l":"slope_step","c":"Row step of the slope used by the sheared drawer: $01 to climb a row, $FF to drop one, $00 for a flat run. Set with $2B by $8C30 from the table at $8C48. $9169 adds it to the working row $31, $9186 to the running total $33, and $9201 eors it with $2F to decide which way the pixel mask moves.","t":"byte","b":[0],"x":[35900,36072,37225,37256,37377]},{"a":45,"l":"zpa_2D","c":"Cleared to zero by $8CE0 along with the rest of the drawing state. No instruction anywhere in $8000-$BFFF reads it; purpose unknown.","t":"byte","b":[0],"x":[36076]},{"a":46,"l":"zpa_2E","c":"Cleared to zero by $8CE0 with the rest of the drawing state. Like $2D it is written once and never read in $8000-$BFFF; purpose unknown.","t":"byte","b":[0],"x":[36078]},{"a":47,"l":"draw_mirror","c":"Direction flag for the drawing code, tested with bit at $8DA0, $91A3 and $9203 and written only at $90DA. When bit 7 is set the shape is laid down right to left: $8DA7 biases the start X by the width and the pixel mask in $0C is rotated the other way.","t":"byte","b":[0],"x":[36256,37082,37095,37283,37379]},{"a":48,"l":"zpa_30","c":"Outer run counter of the sheared drawer: $90F3 loads it from $2B and $91F6 decrements it once per shape row; at zero $91FD reloads it and $9207/$9214 move the pixel mask on by one.","t":"byte","b":[0],"x":[37109,37128,37366,37375]},{"a":49,"l":"cur_row","c":"Bitmap row the drawing code is working on, used as the index into the row-address tables at $0A00/$0AA8. $8C6A and $8E7C load it from $03, $8CD4 walks it down one row per pass of the bar drawer, $910E reloads it from $0B, and $9167-$916B adds the slope step $2C to it.","t":"byte","b":[21],"x":[35948,35966,36001,36052,36476,36525,36914,37043,37134,37223,37227]},{"a":50,"l":"zpa_32","c":"Inner run counter of the sheared drawer, reloaded from $2B at $9104 and $9164 and decremented at $915E for every pixel column; reaching zero triggers the row step.","t":"byte","b":[233],"x":[37126,37214,37220]},{"a":51,"l":"zpa_33","c":"Running row position of the sheared drawer, reloaded from $2B at $9106 and advanced by the slope step $2C at $9186; $918E and $9195/$919C fold it back into range so the shear stays inside the run length.","t":"byte","b":[0],"x":[37130,37254,37258,37271,37278]},{"a":52,"l":"arg3_lo","c":"First byte of the three-byte inline argument fetched by $8BF9 from the block the caller names after the jsr. With $35 it is a 16-bit world X that the clipper at $8F1F-$8F3E compares with the window origin $3B/$3C to work out how much of the shape falls off the left or right edge. Callers pass the address $0067 ($9DFA, $A0C4, $AA9E, $B74B, $B8E5, $BA62), so in practice $34/$35/$36 is a copy of $67/$68/$69.","t":"byte","b":[157],"x":[35844,36639,36646,36664,36723,36732]},{"a":53,"l":"zpa_35","c":"High byte of the 16-bit position in $34, fetched by $8BF9. $8F19 compares it with $3C and $8F2E/$8F3E subtract it when the clipper measures the horizontal overlap.","t":"byte","b":[18],"x":[35849,36631,36652,36670,36715,36738]},{"a":54,"l":"zpa_36","c":"Third byte of the $8BF9 inline argument: the bitmap row the shape is to be drawn at. $8F97-$8FB7 compares it with the clip bounds $39 and $3A to produce the top and bottom clip counts $24 and $25.","t":"byte","b":[34],"x":[35854,36759,36765,36770,36791]},{"a":55,"l":"shape_hdr","c":"Pointer to the shape being drawn. It is the two-byte inline argument of $8BBA (which takes the value itself) and of $8BE0 (which takes the address of the value). $8EE2 copies it into $17/$18 and reads the width and height header bytes through it; $8F0B/$8F10 read the same two bytes directly.","t":"byte","b":[170],"x":[35781,35819,36578,36619,36624]},{"a":56,"l":"zpa_38","c":"High byte of the shape pointer in $37, written by $8BCA and $8BF0 and read at $8EE6.","t":"byte","b":[137],"x":[35786,35824,36582]},{"a":57,"l":"clip_row_hi","c":"Highest bitmap row the drawing code may touch. $8CE0 sets it to $A7 (167), the top row of the 168-row play area, and the vertical clipper at $8F9B-$8FAC subtracts the shape's row from it to get the top clip count $24.","t":"byte","b":[167],"x":[36090,36763,36772,36780]},{"a":58,"l":"clip_row_lo","c":"Lowest bitmap row the drawing code may touch, set to 0 by $8CE0. $8C80 stops the horizontal-bar drawer when the row index falls below it, and $8FBB uses it to work out the bottom clip count $25.","t":"byte","b":[0],"x":[35968,36086,36795]},{"a":59,"l":"win_org","c":"World X of the left edge of the drawing window, the two-byte inline argument of $8C17. Zeroed by $8CE0; the only callers, $9741 and $BDCB, pass the address $0075, so it is normally a copy of the view origin $75/$76. The clipper at $8F21-$8F3C subtracts it from the shape's world X in $34/$35 to get the position relative to the window and the left and right clip counts.","t":"byte","b":[83],"x":[35874,36082,36641,36648,36662,36701]},{"a":60,"l":"zpa_3C","c":"High byte of the drawing-window origin in $3B, set at $8C27 and cleared at $8CF4 and compared with $35 at $8F19. Its span also covers $3D and $3E, which no instruction in $8000-$BFFF touches.","t":"byte","b":[17,0,8],"x":[35879,36084,36633,36654,36668,36707]},{"a":63,"l":"zpa_3F","c":"Cleared to zero by $8CE0 with the rest of the drawing state and never read anywhere in $8000-$BFFF; purpose unknown. Its span also covers $40, which nothing touches.","t":"byte","b":[0,0],"x":[36080]},{"a":65,"l":"zpa_41","c":"Carry byte of the pixel shifter: the bits pushed out of the previous shape byte, which $9003/$9008 or into the next byte before it is written. $8E98 clears it at the start of a row and $8ED9 primes it from the byte before the first visible one when the shape is clipped on the left.","t":"byte","b":[0],"x":[36504,36569,36867,36872,36902]},{"a":66,"l":"zpa_42","c":"Low byte, always zero ($8D09), of the shift-right lookup pointer whose high byte is $43. $9001 reads a shifted byte through it out of the tables the cold start builds at $1000-$17FF.","t":"byte","b":[0],"x":[36105,36865]},{"a":67,"l":"zpa_43","c":"High byte of the shift-right lookup pointer $42/$43. $8E50 sets it to $10 ored with the shift count 0-7, so lda ($42),y yields y >> shift. The eight 256-byte tables at $1000-$17FF are built by the loop at $BF63-$BF98.","t":"byte","b":[23],"x":[36432]},{"a":68,"l":"zpa_44","c":"Low byte, always zero ($8D0B), of the shift-out lookup pointer whose high byte is $45. $8ED7 and $9006 read through it to get the bits a right shift pushes out of a byte.","t":"byte","b":[0],"x":[36107,36567,36870]},{"a":69,"l":"zpa_45","c":"High byte of the shift-out lookup pointer $44/$45. $8E55 sets it to $18 ored with the shift count, so lda ($44),y yields y << (8 - shift), from the eight tables the cold start builds at $1800-$1FFF. Its span also covers $46-$50, which nothing in $8000-$BFFF touches.","t":"byte","b":[31,0,36,0,8,0,0,0],"x":[36437]},{"a":77,"t":"byte","b":[0,0,0,25]},{"a":81,"l":"zpa_51","c":"Zeroed by the per-sortie reset at $BED9. Read and written only by the landscape and scroll code: $A421-$A425, $A43F-$A456 and $A696 add to it, $A52B/$A556/$A640 read it, and $BD18/$BDD1 copy it into $7F as the low half of a 16-bit value handed to the shift routine $ACF1. It behaves as the low byte of a signed 16-bit quantity paired with $52; the quantity itself is not established.","t":"byte","b":[237],"x":[42003,42017,42021,42047,42052,42065,42070,42152,42283,42298,42326,42560,42612,42646,43069,43080,43092,48408,48593,48857]},{"a":82,"l":"zpa_52","c":"High half of the pair that starts at $51, zeroed at $BEDB. As well as the arithmetic at $A427-$A45D it is used as a flag: $9F2D, $9FF5, $A07C, $A49A, $A839, $BCB0, $BCB7, $BD32 and $BD55 all branch on bit 7, and $A527 eors it. $BCAA-$BCB9 combines its sign with the helicopter facing $59 to decide which way the view should scroll. Exact meaning not established.","t":"byte","b":[244],"x":[40739,40749,40939,40949,41074,41084,42007,42023,42027,42054,42059,42072,42077,42128,42138,42148,42279,42287,42302,42330,42343,42564,42614,42648,43065,43073,43084,43100,44376,44716,44770,44827,48304,48311,48412,48434,48469,48597,48859]},{"a":83,"l":"zpa_53","c":"Zeroed at $BEDD. Used only inside the landscape code at $A48E-$A6CD: $A570 and $A580 subtract and add it in a 16-bit sum with $54, and $A5D6, $A60A and $A6CD rewrite it. Exact meaning not established.","t":"byte","b":[0],"x":[42126,42245,42314,42352,42368,42430,42454,42483,42502,42506,42650,42701,48861]},{"a":84,"l":"zpa_54","c":"Zeroed at $BEDF, the companion of $53. $A469/$A488 use it in the same 16-bit sum, $A4F6 and $A5EB test bit 7, and $A5DE/$A610/$A6CF rewrite it. Exact meaning not established.","t":"byte","b":[0],"x":[42089,42120,42122,42230,42237,42304,42358,42374,42434,42462,42475,42479,42508,42512,42654,42703,48863]},{"a":85,"l":"world_x","c":"Low byte of a 16-bit world X that the per-sortie reset $BEE1-$BEE7 sets to $1273 and that $A62B-$A692 and $A901-$A90B move. Everything that owns a world X subtracts this pair from it to get a position relative to it: the people scan ($9BFC, $9C36, $9CB5), the actor code ($A145, $AEB8, $B448, $B489, $B4CB, $B78F) and the scroll code ($BCCD, $BD06, $BD26), which keeps the view origin $75/$76 within $46 to $FA pixels of it.","t":"byte","b":[153],"x":[39932,39990,40117,40653,40766,40789,40971,40994,41101,41119,41285,42539,42543,42554,42574,42578,42594,42604,42628,42638,43023,43265,43269,44728,45016,45090,45203,46152,46217,46283,46991,48333,48360,48390,48422,48867]},{"a":86,"l":"zpa_56","c":"High byte of the 16-bit world X in $55, set to $12 by $BEE7. $A633 and $A63E step it when the low byte wraps and every world-to-view subtraction ($9B8F, $9C01, $9F15, $A047, $B19F, $B44F, $B798) uses it as the high half.","t":"byte","b":[17],"x":[39823,39937,39995,40124,40522,40662,40725,40773,40978,41001,41031,41108,41126,41292,42547,42558,42580,42584,42586,42608,42618,42642,43029,43271,43275,44735,45021,45097,45210,45471,46159,46224,46290,46998,48339,48366,48396,48428,48871]},{"a":87,"l":"zpa_57","c":"Set to 7 by the per-sortie reset at $BEEB. $A6B0-$A6C9 compares and rewrites it, $A915 adds to it, and the actor code reads it at $9FB5, $A154, $AFE3, $B03E and subtracts it at $AE77, $B439, $B47A, $B79F. In the analysed snapshot it always equals the helicopter's +6 field, so it looks like the player's height above the ground, but nothing in the code proves that.","t":"byte","b":[112],"x":[40885,41300,42218,42222,42256,42260,42672,42680,42684,42688,42692,42697,42966,42994,43016,43285,43287,44663,45027,45118,46137,46202,47005,48875]},{"a":88,"l":"ground_row","c":"The row the ground sits on, set to $16 (22) by $BEEF and never changed afterwards. $AA06 gives the helicopter the same value in its +7 field when the actor list is built; $B349 and $B4BB test an actor's +7 against it to ask whether that actor is standing on the ground, $B393 subtracts it, and $B6B0/$B714/$B864 copy it into the +7 field of newly spawned actors.","t":"byte","b":[22],"x":[40436,40901,41067,45034,45123,45244,45727,45897,45971,46183,46267,46768,46868,47204,48879]},{"a":89,"l":"heli_facing","c":"The helicopter's current facing, a small signed number that the per-sortie reset $BEB7 sets to 3. $986C steps it one notch per frame towards a target: +3 or -3 when the joystick is asking for a turn ($8A), otherwise the value the eleven-entry table at $98B0 gives for $5A + 5. $989C and $98A7 make it step past 0 while a turn is being asked for. The shape drawn for the helicopter is chosen from it at $AB5E, $ABE2, $AC4A, $ACCC, $AD26 and $AD6A, and $BCAA uses its sign to pick the scroll direction.","t":"byte","b":[3],"x":[38915,38948,38981,38997,39006,39047,39057,39066,39074,39077,39085,42982,43199,43242,43716,43731,43758,43774,43870,43909,44002,44106,44126,44236,44326,44365,44394,48298,48823]},{"a":90,"l":"zpa_5A","c":"Zeroed by $BEC4. $A628 and $A638 move it by one in step with the world X $55/$56, and $986C indexes the auto-level table at $98B0 with $5A + 5, so it holds a small signed value that tracks the helicopter's horizontal motion; $AB79 and $AC14 pass it to $8C30 as a slope index, and $A92C adds $6D to it. The unit is not established.","t":"byte","b":[0],"x":[39029,42206,42277,42334,42384,42390,42394,42525,42536,42552,42980,43178,43196,43290,43308,43312,43714,43727,43789,43800,43897,43982,44022,44052,44120,44216,44348,44396,48836]},{"a":91,"l":"stick_x","c":"Signed horizontal thrust taken from the joystick by $A741: $05 when the stick is pushed left, $FB (-5) when it is pushed right, 0 otherwise, from the four-entry table at $A758. Forced to 0 while the end-of-sortie delay $63 is running and by $9710 during the end screen. Read at $A42D, $A438 and $A616.","t":"byte","b":[0],"x":[38672,42029,42040,42518,42828,42837,48838]},{"a":92,"l":"stick_y","c":"Vertical thrust taken from the joystick by $A71A: 15 with the stick up, 5 with it down, 10 with it centred and 0 with both pressed, from the table at $A73D. Forced to 2 while $61 or $63 is non-zero and by $970C on the end screen. Read at $A463.","t":"byte","b":[10],"x":[38668,42083,42797,42810,48840]},{"a":93,"l":"rotor_up","c":"Zeroed by $BECA and set at $A7FD and $A80C. It drives the rotor pitch: $997A makes the voice-1 frequency in $0B5E climb towards $C0 while it is non-zero and fall towards $30 while it is zero. The control routines also test it first and refuse to fire ($97D2) or to turn ($97F1) when it is zero, and $9C08, $9C23, $A4CA, $A724, $AFB0, $B055, $B4C3 and $BCA6 branch on it. The exact condition that sets it is outside this range.","t":"byte","b":[1],"x":[38866,38897,39290,39944,39971,42186,42788,43005,43020,44976,45141,46275,48294,48842]},{"a":94,"l":"zpa_5E","c":"Set to 1 by $BEBD and rewritten at $A800, $A8B0 and $A8B5. Read at only two places, $9C93 and $9DBD, both inside the people scan $9B7D, where a zero value makes the person's record be marked dead with $FF. Meaning not established.","t":"byte","b":[0],"x":[40083,40381,43008,43184,43189,48829]},{"a":95,"l":"zpa_5F","c":"Set to 1 by $BEBF and rewritten at $A802 and $A829. Read at $9C27, $9E2D and $9E97 in the people scan and at $BCA2, where a non-zero value makes the scroll code advance the view origin by a fixed 4 pixels instead of tracking the helicopter. Meaning not established.","t":"byte","b":[0],"x":[39975,40493,40599,43010,43049,48290,48831]},{"a":96,"l":"zpa_60","c":"Zeroed by $BECE, written at $A4E7 and $A50D, read at $A4DA, $A7DC, $AB11 and $AB1C. Confined to the landscape and helicopter-drawing code; meaning not established.","t":"byte","b":[0],"x":[42202,42215,42253,42972,43793,43804,48846]},{"a":97,"l":"zpa_61","c":"Zeroed by $BED0 and set at $A8A7 and $B5B1 (the latter when an actor collides). While it is non-zero the fire button and the turn controls are ignored ($97D8, $97F7), the joystick thrusts are overridden ($A72F) and $9BED, $9C97, $A185, $A1AC, $A1C8, $A5C7, $AE9E and $B04E take a different path. It behaves as 'the helicopter is no longer under the player's control', but what clears it again is outside this range.","t":"byte","b":[0],"x":[38870,38901,39917,40087,41349,41388,41416,42439,42799,43058,43175,44702,45134,46513,48848]},{"a":98,"l":"zpa_62","c":"Zeroed by $BECC; $A883 decrements it and $A88B and $A8A0 increment it. Read at $A7BF (where the value 6 suppresses a sound effect), $A82B, $A875, $ABB0, $AC19, $AC79, $AFE5 and $B13E. A small counter in the helicopter code; meaning not established.","t":"byte","b":[0],"x":[42943,43051,43125,43139,43147,43168,43173,43952,44057,44153,45029,45374,48844]},{"a":99,"l":"sortie_end_delay","c":"Zeroed by $BED2 and set at $A87B/$A881. Once non-zero the main loop at $968E adds 3 to it every frame and, when the sum goes negative, abandons the sortie and jumps back to $961E to print the next sortie message. $A733 and $A74E freeze the joystick thrusts $5B and $5C while it runs.","t":"byte","b":[0],"x":[38542,38549,42803,42830,43131,43137,48850]},{"a":100,"l":"fire_latch","c":"Fire-button latch. $97E7 sets it to $FF at the moment the player's shot is created and $B00A rewrites it; $97DA and $B004 test bit 7. It is what stops one press of the button producing more than one shot.","t":"byte","b":[0],"x":[38874,38887,45060,45066,48852]},{"a":101,"l":"shape_sel","c":"Pointer to a shape's header, taken from the shape-pointer table at $8009 (or $8091/$8097/$809B) and stored by $9D72, $AB26, $AB37, $AB4F, $AB6C, $AC36, $AC96, $ADD0, $B063, $B116, $B8F5 and $BB10. $AB92, $ADDE, $B071, $B124 then read the width and height bytes through it, and $8BE0 is usually handed the address $0065 so the drawing code picks the same shape up.","t":"byte","b":[155],"x":[40306,40332,40359,41236,43814,43831,43855,43884,43922,43927,44086,44182,44496,44510,44516,45155,45169,45174,45334,45348,45354,47349,47888]},{"a":102,"l":"zpa_66","c":"High byte of the shape-header pointer in $65, written at $9D77, $9D91, $9DAC, $A119, $AB2B, $AB3C, $AB55, $AB71, $AC3C, $AC9B, $ADD5, $B068, $B11B, $B8FA and $BB15.","t":"byte","b":[132],"x":[40311,40337,40364,41241,43819,43836,43861,43889,44092,44187,44501,45160,45339,47354,47893]},{"a":103,"l":"draw_wx","c":"Low byte of the world X of the shape about to be queued for drawing. $A9A0 fills $67/$68/$69 from an actor's record: the 16-bit world X in +4/+5 minus the signed X offset the caller passes in the X register ($7B), and the row from +6 plus +7 plus the Y offset in the Y register ($7C). $AA3B then subtracts the view origin $75/$76 and appends the result to the display list; $8BF9 is usually handed the address $0067.","t":"byte","b":[157],"x":[40416,40431,40433,43438,43476,43482,43579,43655,47320,47416,47420,47630,47708,47735,47766,47790,47816,47820,47844,47870,47872]},{"a":104,"l":"zpa_68","c":"High byte of the world X in $67. $A9B9/$A9C0 set it with the sign of the X offset $7B taken into account; $9DE7, $AA8D, $B8DF, $BA13 and $BA55 write it directly and $AA41 subtracts $76 from it.","t":"byte","b":[18],"x":[40423,43449,43456,43486,43585,43661,43706,47327,47424,47635,47701]},{"a":105,"l":"draw_wy","c":"Bitmap row of the shape about to be queued, computed at $A9C3-$A9CB as the actor's height above the ground (+6) plus its ground row (+7) plus the caller's Y offset $7C. Also written directly at $9DF8, $AA91, $B8E3, $B90B, $B921, $B935, $BA18, $BA60, $BAA7 and $BADD for scenery that has no actor record.","t":"byte","b":[34],"x":[40440,43467,43592,43665,47331,47371,47393,47413,47640,47712,47783,47837]},{"a":106,"l":"ent_x","c":"Low byte of the view-relative X of the display-list entry being built or replayed. $AA3B-$AA3F computes it as $67 minus the view origin $75; $BC0C reads it back out of the previous frame's list, $BC2C-$BC30 and $BC41-$BC56 clip it against the left edge of the screen, and $8B91 is handed the address $006A so it lands in $04.","t":"byte","b":[1],"x":[43583,43605,48140,48172,48176,48193,48214]},{"a":107,"l":"zpa_6B","c":"High byte of the view-relative X of a display-list entry, computed at $AA41-$AA45 and read back at $BC0F. $BC34 decrements it and $BC3D tests its sign when the entry has to be clipped against the left edge.","t":"byte","b":[1],"x":[43589,43610,48145,48180,48189,48216]},{"a":108,"l":"ent_row","c":"Bitmap row of a display-list entry, computed at $AA48-$AA4C and read back at $BC14. $BC37 adds 14 to it for entries of kind 0, and $BC60-$BC7A clips it against the 168-row play area, trimming the stored height in $0B52 to match.","t":"byte","b":[25],"x":[43596,43615,48150,48183,48187,48224,48250]},{"a":109,"l":"zpa_6D","c":"The most-used scratch byte in the program (101 references), normally paired with $6E. It serves as a working register for the sound code ($95F9, $9930), the raster handler's screen pointer ($9AD5), the landscape and helicopter code ($A5F1-$A61A, $AB7D, $ACBC, $AD32), the actor-list scan ($B3AD, $B573), the display-list clipper ($BC4B-$BC73), the scroll limiter ($BCD1-$BD4D) and the cold start's bit shifter ($BF7B-$BF8B) and block copies ($BFB2-$BFEF). Nothing keeps a value in it across a routine.","t":"byte","b":[0],"x":[38393,38395,38420,39216,39222,39234,39637,39655,41593,41616,42388,42400,42402,42412,42423,42425,42481,42486,42489,42492,42494,42522,42530,43027,43035,43294,43303,43305,43310,43633,43638,43650,43901,43906,43986,43992,43999,44008,44220,44226,44233,44242,44338,44342,44344,44346,44359,44374,44384,44392,44400,44404,44406,44408,44722,44782,44791,44821,45997,46022,46033,46044,46052,46154,46168,46175,46219,46233,46240,46285,46301,46313,46356,46372,46380,46451,46476,46487,46498,46506,47493,47499,48203,48208,48232,48243,48337,48355,48383,48445,48461,48485,48520,48621,49019,49028,49035,49074,49084,49123,49135]},{"a":110,"l":"zpa_6E","c":"High half of the $6D scratch pair, used the same way: the high byte of the copy pointers in $BFB6-$BFC5 and $BFE7, the quotient in the halving at $AA6A-$AA7C, and the high byte of the distance the scroll code measures at $BCD7-$BD5D.","t":"byte","b":[10],"x":[39218,39236,39248,39643,43626,43644,43657,43672,43708,43989,43997,44223,44231,48343,48347,48375,48451,48467,48477,48512,48627,49078,49091,49093,49127,49140]},{"a":111,"l":"zpa_6F","c":"General 16-bit scratch, and an indirect jump vector: $B319-$B326 puts an actor handler's address here and jumps through it. Also the source pointer of the character-ROM copy at $BFA8-$BFBA and of the bitmap clear at $BFD9-$BFED, the table pointer read at $9AE3 and $ADA6-$ADD3, the destination of the shift tables at $BF67-$BF89, and a plain temporary in a dozen other routines.","t":"byte","b":[0],"x":[39054,39062,39623,39651,40008,40040,40119,40135,40179,41771,41781,41846,41856,41876,43428,43469,43725,43823,43840,43846,43865,43891,43918,43931,44335,44413,44441,44454,44460,44465,44470,44482,44494,44499,44730,44753,44757,44766,44815,45849,45862,46008,46027,46038,46092,46107,46114,46462,46481,46492,47162,47212,47512,47521,47527,47533,47608,48747,48770,48807,48809,48999,49033,49066,49082,49115,49133]},{"a":112,"l":"zpa_70","c":"High byte of the $6F pair. $BE71 and $BEAB/$BEAF carry the world X through it while the eight people are seeded, $B99E/$B9AB count down with it, and $BFAE/$BFC1 walk it across the character ROM from $D0 to $D7 while $BFDF/$BFF6 walk it across the bitmap from $20 to $3F.","t":"byte","b":[175],"x":[39629,44446,44487,44737,44808,45854,47518,47531,47537,47615,48753,48775,48811,48815,49008,49070,49089,49119,49142,49144]},{"a":113,"l":"ent_kind","c":"The kind byte of a display-list entry. $AA38 takes it in A and stores it as the first of the four bytes; $BC07/$BC19/$BC27 reads it back when the entry is replayed and uses it to index the offset table at $94AF. $BE75-$BE8E also uses this byte as the counter that seeds the eight people at $0CA0.","t":"byte","b":[19],"x":[43576,43600,48135,48153,48167,48757,48780,48782]},{"a":114,"l":"actor_slot","c":"Byte offset of the actor record currently being worked on, i.e. ten times the slot number. $B30A sets it as $B307 walks the linked list, the allocator $A951 and the unlinker $A937 pass it, and about eighty sites do ldx $72 followed by lda $0B74,x and friends to reach the record fields.","t":"byte","b":[10],"x":[40737,40759,40834,40860,40873,40917,40959,41014,41043,41094,41141,41176,41226,41414,41492,41551,41563,41585,41643,41668,41679,41709,41804,43319,43335,43347,43358,43367,43430,44324,44431,44545,44561,44583,44683,44900,44954,45014,45074,45087,45200,45222,45252,45318,45403,45454,45466,45580,45629,45650,45712,45741,45802,45834,45892,45947,45999,46065,46131,46196,46255,46453,46515,46527,46535,46543,46584,46627,46635,46643,46685,46693,46721,46726,46810,46818,46826,46829,46837,46906,46971,46988,47128,47168,47176,47239,47248]},{"a":115,"l":"zpa_73","c":"Zeroed by $B30F at the top of every pass over the actor list and written once, by $A95B, which records the slot offset of the first actor linked in during that pass ($A971 stops a later link overwriting it). No instruction in $8000-$BFFF reads it; purpose unknown.","t":"byte","b":[0],"x":[43377,43381,45839,45865]},{"a":116,"l":"free_slot_head","c":"Head of the free-slot chain of the actor array: the byte offset of the first unused record, or 0 for none. $AA13 sets it to 20 (slot 2) when the list is built, $A951 pops a record off it when an actor is spawned and $A94E pushes a freed record back on. The chain runs through each record's +9 field.","t":"byte","b":[20],"x":[43337,43342,43345,43352,43539]},{"a":117,"l":"view_org","c":"Low byte of the world X of the left edge of the view. $AA3D and $AA43 subtract $75/$76 from a shape's world X to get its screen X, and the scroll code at $BCBF-$BDC9 advances the pair, clamping it between $02B0 and $11D8. $9739 forces it to $11D8 for the frames drawn between phases, and $9741/$BDCB hand its address to $8C17 so the clipper's window origin $3B/$3C is the same value.","t":"byte","b":[83],"x":[38715,40425,43474,43581,43628,43636,47295,47489,47510,47689,48319,48323,48335,48364,48394,48483,48499,48503,48522,48530,48534,48550,48556,48573,48581,48623]},{"a":118,"l":"zpa_76","c":"High byte of the view origin in $75, set to $11 by $973D. $BCC7, $BD7B and $BD9A step it as the view crosses a 256-pixel boundary, and $B8AF, $B972 and $BA40 compare it with fixed values to decide whether the base, the hangar or the far buildings are close enough to be worth drawing.","t":"byte","b":[17],"x":[38719,43587,43623,43642,47279,47474,47516,47682,48327,48341,48370,48400,48475,48507,48514,48538,48542,48560,48565,48585,48629]},{"a":119,"l":"zpa_77","c":"Written at $9D59, $A461, $A474, $B67C and $B71C and only ever tested with bit ($A481, $B6BA, $B720), so only its top bits matter to the code that reads it: $B6B8 and $B71E use its sign to flip the sign of a newly spawned actor's +1 field. Meaning not established.","t":"byte","b":[0],"x":[40281,40457,42081,42100,42113,46716,46778,46876,46880]},{"a":120,"l":"zpa_78","c":"Low byte of a 16-bit working position. $B66D and $B98D set it, $B690, $BA58, $BA74, $BA92, $BAAA and $BAE0 read it and $B9BF-$BA01 add to it repeatedly. It is the anchor X of the routines that draw the hangar ($B971-$BA3A) and the base ($BA3F-$BB24) and the pair used when an actor splits in two at $B665.","t":"byte","b":[85],"x":[46701,46736,47501,47551,47573,47595,47610,47695,47704,47732,47762,47786,47840]},{"a":121,"l":"zpa_79","c":"High byte of the 16-bit working position in $78, written at $B672 and $B991 and added to at $B9C6, $B9DC, $B9F2 and $BA01.","t":"byte","b":[18],"x":[46706,46744,47505,47558,47580,47602,47617,47699]},{"a":122,"l":"zpa_7A","c":"Written once at $B677 and read twice at $B6A1 and $B6A9, all inside $B665: it holds the +6 field of the actor that is splitting so the two halves can be placed eight rows above and nine rows below it. Purely local.","t":"byte","b":[10],"x":[46711,46753,46761]},{"a":123,"l":"off_x","c":"The signed X offset a caller passes to $A9A0 in the X register: $A9AC subtracts it from the actor's world X and $A9B3 sign-extends it into the high byte, so one actor can queue several shapes at fixed offsets. $BC1D-$BC20 reuses the byte as the width of a display-list entry read from the table at $94AF, and $BC4E-$BC52 trims that width when the entry is clipped on the left.","t":"byte","b":[7],"x":[43424,43436,43443,48160,48206,48210,48260]},{"a":124,"l":"zpa_7C","c":"The signed row offset a caller passes to $A9A0 in the Y register, added to the row at $A9C9. $BC22-$BC25 reuses the byte as the height of a display-list entry, taken from the table at $94B0, and $BC5A copies it into $0B52 for the clip.","t":"byte","b":[23],"x":[43426,43465,48165,48218]},{"a":125,"l":"zpa_7D","c":"Scratch of the scroll code only: $BDEA sets it to the step the view is allowed to move this frame (at least 4, capped at the remaining distance by $BE0E-$BE1A), and $BD75/$BD94 add or subtract it from the view origin $75/$76.","t":"byte","b":[1],"x":[44257,48501,48532,48618,48654,48666]},{"a":126,"l":"zpa_7E","c":"Never referenced by any instruction in $8000-$BFFF. It sits between the scroll scratch $7D and the 16-bit scratch pair $7F/$80 and is left over from the way the zero page is laid out; the game does not use it.","t":"byte","b":[176],"x":[44262]},{"a":127,"l":"zpa_7F","c":"Low byte of a general 16-bit scratch pair used by the landscape, scroll and helicopter code (55 references), and an indirect jump vector at $ABBB. $A56E-$A588, $A5D0-$A5E9 and $A642-$A656 use it as an accumulator, $AA78-$AA8B holds a halved view origin in it, and $BD1A/$BDD3 load it from $51/$52 before calling the shift routine $ACF1.","t":"byte","b":[171],"x":[42005,42019,42285,42296,42328,42350,42354,42366,42370,42386,42432,42448,42468,42504,42562,42576,42652,42663,42686,43082,43098,43116,43232,43246,43250,43258,43267,43640,43653,43737,43748,43767,43963,44265,44279,44285,44297,44305,44309,44317,47535,47547,47569,47591,48410,48424,48426,48441,48457,48595,48606,48625,48638,48644,48660,48664]},{"a":128,"l":"zpa_80","c":"High half of the $7F scratch pair. $AD07 and $AD1B shift it, $A8FE and $AD21 increment it, $BDF9 tests bit 7 to take the absolute value of the pair, and $BE10 tests it for zero when the scroll step is capped.","t":"byte","b":[8],"x":[42009,42025,42289,42300,42332,42356,42360,42372,42376,42436,42456,42473,42510,42566,42582,42656,43086,43106,43108,43240,43252,43256,43262,43273,43646,43659,43741,43752,43772,44270,44273,44287,44293,44295,44311,44315,44321,47539,47556,47578,47600,48414,48430,48432,48447,48463,48599,48631,48633,48646,48652,48656]},{"a":129,"l":"zpa_81","c":"Written at $A14A, $A175, $A194 and $B794, tested with bit at $A17A, $A181, $A263 and $A26A and compared at $A1BD and $A223. At $B794 it is the low byte of the world X of the player minus this actor, so in that routine it is a relative position; the earlier uses at $A10A-$A2C0 are not established.","t":"byte","b":[226],"x":[41290,41333,41338,41345,41360,41364,41395,41405,41431,41497,41507,41571,41578,46996]},{"a":130,"l":"zpa_82","c":"Written at $A151 and $B79B, read at $A15B, $A171, $B7A4 and $B7B6. At $B79B it is the high byte of the world X of the player relative to this actor, and $B7A6-$B7AC uses it to drop an actor that has drifted more than three pages away. The uses in $A151-$A171 are not established.","t":"byte","b":[0],"x":[41297,41307,41329,47003,47012,47030]},{"a":131,"l":"zpa_83","c":"Written at $A159 and $B7A2 and tested with bit at $B7E6. At $B7A2 it is the height of the player relative to this actor, and its sign decides whether the actor's +2 field counts up or down. The use at $A159 is not established.","t":"byte","b":[1],"x":[41305,47010,47078]},{"a":132,"l":"zpa_84","c":"Saved X register around the sound, status-bar and actor calls: $A3BA, $A3D3, $A3EC, $A6D2 and $B0D2 push the pair $84/$85 and $A3CE, $A3E7, $A40E, $A6E0, $A715 and $B101 restore it.","t":"byte","b":[10],"x":[41914,41934,41939,41959,41964,41998,42706,42720,42725,42773,45266,45313]},{"a":133,"l":"zpa_85","c":"Saved Y register, the other half of the $84/$85 register save area; written at $A3BC, $A3D5, $A3EE, $A6D4 and $B0D4 and restored at $A3D0, $A3E9, $A410, $A6E2, $A717 and $B103.","t":"byte","b":[10],"x":[41916,41936,41941,41961,41966,42000,42708,42722,42727,42775,45268,45315]},{"a":134,"l":"zpa_86","c":"Low byte of a 16-bit temporary of the helicopter and shape code: $ABEE, $AC65, $AC72 and $ADAE set it, $AC07 adds to it, $ACA2 loads it into X, and $AE40-$AE51 steps and tests it. $B01D/$B024 reuses it alone when a shot is created.","t":"byte","b":[19],"x":[32848,44014,44039,44133,44146,44194,44462,44608,44612,44614,44620,44625,45085,45092,45099]},{"a":135,"l":"zpa_87","c":"High byte of the $86/$87 temporary ($ABF3, $AC6A, $AC77, $ADB3, $AE2D), and on its own the saved height of the shot being checked against the actor list at $B384-$B39A.","t":"byte","b":[5],"x":[44019,44032,44138,44151,44196,44467,44589,45956,45978]},{"a":136,"l":"zpa_88","c":"Written at $ADB8 and $B555 and read at $AE36 and $B562. At $B555 it holds the +7 field of the actor being tested so the scan at $B55E can reject actors more than ten rows away; the use at $ADB8 is a local temporary of the helicopter drawer.","t":"byte","b":[233],"x":[44472,44598,46421,46434]},{"a":137,"l":"phase_frames","c":"Frame counter within the current phase. The main loop increments it once per drawn frame ($95C6, $9640, $966F, $96FC) and clears it when a phase starts ($9638, $96EF). $9644 ends the sortie message after $2C frames and $9700 ends the closing screen after $50; $A363, $A36C, $B75F, $B951 and $BB07 take its low bit to alternate animation frames.","t":"byte","b":[55],"x":[38342,38456,38464,38466,38511,38639,38652,38654,41827,41836,46943,47441,47879]},{"a":138,"l":"turn_request","c":"The turn the player is asking for this frame: $01 one way, $FF the other, $00 for none. $982F, $9836, $985B, $9864 and $9869 set it from the joystick and the per-sortie reset $BEBB starts it at 1. $986C is the only reader: it turns the request into a one-notch step of the helicopter facing $59.","t":"byte","b":[1],"x":[38959,38966,39003,39012,39017,39020,39070,39081,48827]},{"a":139,"l":"zpa_8B","c":"Remembers the facing the helicopter had when the current turn began: $9826 copies $59 into it and $9814 clears it, and $9851-$9857 compares it with the current facing when the stick is released to decide which way to level off. Zeroed by the per-sortie reset at $BEC2.","t":"byte","b":[0],"x":[38932,38950,38993,48834]},{"a":140,"l":"status_bar_on","c":"Non-zero while the status panel is live. $95AD clears it for the title display, $95F2 sets it to $FF for play and $96F4 clears it again for the closing screen. $A978 and $BB2B refuse to redraw the panel and $A7BB refuses to start a sound effect while it is clear.","t":"byte","b":[255],"x":[38317,38386,38644,42939,43384,47915]},{"a":141,"l":"zpa_8D","c":"Cleared by the panel reset at $BB98 and incremented at $9EBA. $9FD7 uses it as a Y index and $A398/$A3A5 as an X index into the hostage bookkeeping; $B822 compares it with 3 before an actor is allowed to spawn another. It counts something about the hostages the helicopter is carrying, but the exact quantity is not established.","t":"byte","b":[0],"x":[40628,40634,40908,40919,41848,41862,41880,41893,44759,47136,48024]},{"a":142,"l":"a_008E","c":"Loop counter of the two table builders in the cold start. $BF38 sets it to 21, one per character row, while $BF3B-$BF61 fills the bitmap row-address tables at $0A00 and $0AA8; $BF65-$BF94 then reuses it as the shift count 0-7 while the sixteen lookup tables at $1000-$1FFF are built. The code addresses it absolutely, which is why the disassembler names it a_008E.","t":"byte","b":[8],"x":[48952,48990,48997,49003,49010,49022,49042,49044]},{"a":143,"l":"zpa_8F","c":"Low byte of the cold start's output pointer. $BF2C holds the running low byte of the bitmap row addresses while $BF3B-$BF61 fills $0A00/$0AA8, and $BF69/$BF8D then points the pair at $1800+n*256 while the shift-out tables are built. $9AD3/$9AE9 reuse it in the raster handler as a screen write pointer.","t":"byte","b":[74],"x":[39635,39657,48940,48963,48969,48979,49001,49037]},{"a":144,"l":"zpa_90","c":"High byte of the $8F pointer pair. $BF33 starts it at $25 and $BF5B advances it one page per character row (plus the carry out of the $39 added to the low byte), which is how the row addresses step by 320 bytes; $BF77 then points it at page $18+n for the shift-out tables.","t":"byte","b":[70,255,0],"x":[39647,48947,48957,48982,48987,49015]},{"a":147,"l":"text_window_tall","c":"Selects how tall the mid-screen text window is. $BF0A clears it, $9AAC and $9B58 set it to 1. In the raster handler $99C4 tests it to choose the raster line that closes the window, $91 (two text rows) when it is zero and $A9 (four rows) when it is not; $9A88 adds it to $02 to decide whether the window is opened at all.","t":"byte","b":[0],"x":[39364,39560,39598,39768,48906]},{"a":148,"l":"zpa_94","c":"Reload value for the voice-2 retrigger counter $95. $A786 sets it when a sound effect starts and $9A5A copies it back into $95 each time the counter expires; $9985 and $9993 walk it up and down as the note slides.","t":"byte","b":[8],"x":[39301,39315,39514,42886]},{"a":149,"l":"zpa_95","c":"Counts raster frames until voice 2 is retriggered: $9A4C decrements it in the raster handler and at zero $9A50-$9A57 gates voice 2 off and on again before reloading from $94. $966D sets it to $11 for the between-sorties display and $99A5 to $FF when the effect stops.","t":"byte","b":[6],"x":[38509,39333,39500,39516]},{"a":150,"l":"zpa_96","c":"Frames since the fire button last changed state. $9A35 increments it once per frame at raster $1E; $9774-$97C9 compares it with 15 to tell a tap from a hold (a tap fires, a hold does something else) and clears it whenever the button changes.","t":"byte","b":[1],"x":[38795,38812,38820,38841,38857,39477]},{"a":151,"l":"zpa_97","c":"Written at $9934 and $9AF6 and read once, at $9AC2, inside the raster handler's screen-write helper at $9AC2-$9AEB, where it is the count of bytes still to write. Purely local to that routine.","t":"byte","b":[4],"x":[39220,39618,39670]},{"a":152,"l":"zpa_98","c":"Counts frames until voice 3 is gated: $9A37 decrements it each frame and $9A3B/$9A44 write $00 or $11 to $D412 accordingly, which is what gives the rotor its pulse. $A7D0 sets the period and $A7CC reads it back.","t":"byte","b":[0],"x":[39479,39486,42956,42960]},{"a":153,"l":"list_cur","c":"Low byte of the pointer to the display list being filled this frame. $A9E9/$A9ED set the pair to $0D03 at the start of a sortie and $AA52-$AA61 appends four bytes per shape through it. $BBE6-$BBF4 exchanges it with $9B/$9C once per frame, and $BC05-$BC14 then reads the list back to erase what was drawn last frame.","t":"byte","b":[3],"x":[43497,43602,43607,43612,43617,48102,48106,48133,48138,48143,48148]},{"a":154,"l":"zpa_9A","c":"High byte of the current display-list pointer in $99, set to $0D by $A9ED and exchanged with $9C by $BBEE-$BBF2 once per frame.","t":"byte","b":[13],"x":[43501,48110,48114]},{"a":155,"l":"list_prev","c":"Low byte of the pointer to the display list built on the previous frame, $0DA3 at the start of a sortie ($A9F1/$A9F5). $BBE6-$BBF4 exchanges it with $99/$9A every frame so that the list just finished becomes the one $BC05 replays to erase.","t":"byte","b":[163],"x":[43505,48104,48108]},{"a":156,"l":"zpa_9C","c":"High byte of the previous display-list pointer in $9B, set to $0D by $A9F5 and exchanged with $9A at $BBF0-$BBF4.","t":"byte","b":[13],"x":[43509,48112,48116]},{"a":157,"l":"list_cur_len","c":"Number of bytes used in the display list $99/$9A points at, so four times the number of shapes queued. $A9E3 clears it, $AA4E/$AA64 advance it by four per entry, $BC96 compares the replay index with it and $BC9F zeroes it when the replay is finished.","t":"byte","b":[8],"x":[43491,43598,43620,48118,48122,48126,48278,48287]},{"a":158,"l":"zpa_9E","c":"Number of bytes used in the previous frame's display list $9B/$9C. $A9E5 clears it and $BBF8/$BBFC exchanges it with $9D once per frame. Nothing between $9F and $C4 is touched anywhere in $8000-$BFFF.","t":"byte","b":[20],"x":[43493,48120,48124]},{"a":159,"t":"gap","n":38},{"a":197,"l":"zpa_C5","c":"The KERNAL's 'matrix code of the key currently down' ($40 when none), written by the scan routine $FF9F that the raster handler calls at $9A63. The game reads it in one place only: $98BC-$98D7 watches for code $3F, RUN/STOP, and uses it as a pause key - SID volume to 0, wait for the key to be released, wait for it to be pressed and released again, volume back to $0F. Nothing above $C5 is touched.","t":"byte","b":[64],"x":[39100,39111,39117,39123]},{"a":198,"t":"gap","n":459},{"a":657,"l":"kernal_shift_mode","c":"The KERNAL's shift-mode flag. The raster handler writes $80 here at $9A5E, which disables the CBM+SHIFT character-set toggle, immediately before calling the keyboard scan at $FF9F that feeds the RUN/STOP pause check at $98BC. It is the only byte of page 2 the game touches.","t":"byte","b":[128],"x":[39520]},{"a":658,"t":"gap","n":130},{"a":788,"l":"irq_vec_lo","c":"Low byte of the KERNAL IRQ vector. $A7AE-$A7B0 writes $F2 here (and $99 into $0315) as the last step of starting the game, so every raster interrupt enters the game's handler at $99F2. Written nowhere else; the KERNAL's own handler is never reached again.","t":"byte","b":[242],"x":[42928]},{"a":789,"l":"a_0315","c":"High byte of the KERNAL IRQ vector, set to $99 by $A7B3-$A7B5 alongside $0314, giving the raster handler address $99F2.","t":"byte","b":[153,102,254],"x":[42933]},{"a":792,"l":"nmi_vec_lo","c":"Low byte of the KERNAL NMI vector, set to $AB by $98DF-$98E1 during start-up so that pressing RESTORE lands in the game's own handler at $9AAB instead of the KERNAL's. $9AAB is a bare rti, so RESTORE does nothing.","t":"byte","b":[171],"x":[39137]},{"a":793,"l":"a_0319","c":"High byte of the KERNAL NMI vector, set to $9A by $98E4-$98E6 alongside $0318, giving the NMI address $9AAB.","t":"byte","b":[154],"x":[39142]},{"a":794,"t":"gap","n":1766},{"a":2560,"l":"bitmap_row_lo","c":"Low bytes of the bitmap row addresses, 168 entries at $0A00-$0AA7 with the matching high bytes at $0AA8. Entry x is the address of the bitmap row x pixels above the bottom of the screen, so entry 0 is screen pixel row 199 at $3E07 and entry 167 is pixel row 32 at $2500, the first row below the four-row text panel. Built at run time by $BF3B-$BF61, never loaded from the cartridge image. This first 64 bytes covers rows 0-63; the low byte runs 07,06..00 inside a character row and the pattern repeats every 32 entries because four character rows span $500 bytes.","t":"byte","b":[7,6,5,4,3,2,1,0],"x":[35972,36175,36527,37136,37230,48909,48966]},{"a":2568,"t":"byte","b":[199,198,197,196,195,194,193,192]},{"a":2576,"t":"byte","b":[135,134,133,132,131,130,129,128]},{"a":2584,"t":"byte","b":[71,70,69,68,67,66,65,64]},{"a":2592,"t":"byte","b":[7,6,5,4,3,2,1,0]},{"a":2600,"t":"byte","b":[199,198,197,196,195,194,193,192]},{"a":2608,"t":"byte","b":[135,134,133,132,131,130,129,128]},{"a":2616,"t":"byte","b":[71,70,69,68,67,66,65,64]},{"a":2624,"l":"bitmap_row_lo_40","c":"Low bytes of the bitmap row addresses for rows 64-127, the middle third of the table that starts at $0A00. The values repeat the 32-entry cycle 07..00, C7..C0, 87..80, 47..40 because consecutive character rows are 320 ($140) bytes apart, so the low byte advances by $40 per character row.","t":"byte","b":[7,6,5,4,3,2,1,0]},{"a":2632,"t":"byte","b":[199,198,197,196,195,194,193,192]},{"a":2640,"t":"byte","b":[135,134,133,132,131,130,129,128]},{"a":2648,"t":"byte","b":[71,70,69,68,67,66,65,64]},{"a":2656,"t":"byte","b":[7,6,5,4,3,2,1,0]},{"a":2664,"t":"byte","b":[199,198,197,196,195,194,193,192]},{"a":2672,"t":"byte","b":[135,134,133,132,131,130,129,128]},{"a":2680,"t":"byte","b":[71,70,69,68,67,66,65,64]},{"a":2688,"l":"bitmap_row_lo_80","c":"Low bytes of the bitmap row addresses for rows 128-167, the last 40 entries of the table that starts at $0A00. Entry 167 (at $0AA7) is $00, the first byte of character row 4 of the bitmap; the table ends here and the high bytes begin at $0AA8.","t":"byte","b":[7,6,5,4,3,2,1,0]},{"a":2696,"t":"byte","b":[199,198,197,196,195,194,193,192]},{"a":2704,"t":"byte","b":[135,134,133,132,131,130,129,128]},{"a":2712,"t":"byte","b":[71,70,69,68,67,66,65,64]},{"a":2720,"t":"byte","b":[7,6,5,4,3,2,1,0]},{"a":2728,"l":"bitmap_row_hi","c":"High bytes of the bitmap row addresses, 168 entries at $0AA8-$0B4F matching the low bytes at $0A00. Eight consecutive entries share a value because eight pixel rows live inside one character row; the values run $25,$26,$27,$28,$2A... up to $3E, i.e. the address falls by 320 bytes for each character row nearer the top of the screen. The drawing code eors the byte it reads here with $0F, which adds $40 and so selects the bank-1 bitmap at $6000 instead of the bank-0 one at $2000. This first 64 bytes covers rows 0-63 ($3E down to $34).","t":"byte","b":[62,62,62,62,62,62,62,62],"x":[35988,36180,36541,37150,37244,48960]},{"a":2736,"t":"byte","b":[60,60,60,60,60,60,60,60]},{"a":2744,"t":"byte","b":[59,59,59,59,59,59,59,59]},{"a":2752,"t":"byte","b":[58,58,58,58,58,58,58,58]},{"a":2760,"t":"byte","b":[57,57,57,57,57,57,57,57]},{"a":2768,"t":"byte","b":[55,55,55,55,55,55,55,55]},{"a":2776,"t":"byte","b":[54,54,54,54,54,54,54,54]},{"a":2784,"t":"byte","b":[53,53,53,53,53,53,53,53]},{"a":2792,"l":"bitmap_row_hi_40","c":"High bytes of the bitmap row addresses for rows 64-127, the middle of the table that starts at $0AA8. Values $34 down to $2B, one per character row, eight entries each.","t":"byte","b":[52,52,52,52,52,52,52,52]},{"a":2800,"t":"byte","b":[50,50,50,50,50,50,50,50]},{"a":2808,"t":"byte","b":[49,49,49,49,49,49,49,49]},{"a":2816,"l":"bitmap_row_hi_80","c":"High bytes of the bitmap row addresses for rows 128-167 (the table continues to $0B4F), values $30 down to $25. The cold start also uses this address as the second of the five sta $xx00,y in its clear loop at $BF10, which is what zeroes $0B00-$0BFF.","t":"byte","b":[48,48,48,48,48,48,48,48],"x":[48912]},{"a":2824,"t":"byte","b":[47,47,47,47,47,47,47,47]},{"a":2832,"t":"byte","b":[45,45,45,45,45,45,45,45]},{"a":2840,"t":"byte","b":[44,44,44,44,44,44,44,44]},{"a":2848,"t":"byte","b":[43,43,43,43,43,43,43,43]},{"a":2856,"t":"byte","b":[42,42,42,42,42,42,42,42]},{"a":2864,"t":"byte","b":[40,40,40,40,40,40,40,40]},{"a":2872,"t":"byte","b":[39,39,39,39,39,39,39,39]},{"a":2880,"l":"bitmap_row_hi_end","c":"Last sixteen entries of the bitmap row high-byte table: rows 152-167, high bytes $26 and then $25. $0B4F is the last byte of the table; the individual game variables start immediately afterwards at $0B50.","t":"byte","b":[38,38,38,38,38,38,38,38]},{"a":2888,"t":"byte","b":[37,37,37,37,37,37,37,37]},{"a":2896,"l":"a_0B50","c":"Flag of the helicopter handler: $ADF4 and $ADFE write it and $AF7A tests it with bit, so only bit 7 matters to the reader. Set on one path through $ADF2-$AE00 and cleared on the other. Meaning not established.","t":"byte","b":[0],"x":[44532,44542,44922]},{"a":2897,"l":"a_0B51","c":"Byte written by $ADA8 inside the helicopter drawer and read back at $ADC9 and $AE1A, where $AE1A adds it to something before the next shape is placed. A local temporary of $AD8F-$AE20; meaning not established.","t":"byte","b":[0],"x":[44456,44489,44570]},{"a":2898,"l":"erase_h","c":"Height in rows of the rectangle being erased by the display-list replay. $BC5C copies it from $7C (the entry's height, looked up in the table at $94B0) and $BC60-$BC75 trims it where the rectangle would run off the top of the 168-row play area; $BC7C skips the erase when nothing is left, otherwise $BC81 stores it as the second byte of the synthetic shape header at $0E44.","t":"byte","b":[23],"x":[48220,48234,48240,48245,48252]},{"a":2899,"l":"fire_debounce","c":"Fire-button state from the previous poll: $FF when the button was up ($97A1, $97CE) and $00 when a press has been taken ($9788, $97BF). $977B and $97B4 test bit 7, so the button only acts on the transition from up to down, and $96A2/$96AB call the two pollers many times a frame without retriggering.","t":"byte","b":[0],"x":[38779,38792,38817,38836,38849,38862]},{"a":2900,"l":"a_0B54","c":"Latch for the left/right stick: $9800 sets it to $FF when a turn starts and $9842 clears it when the stick comes back to centre, so $97F9 and $983B can tell the start and the end of a turn apart. Read nowhere else.","t":"byte","b":[0],"x":[38905,38912,38971,38978]},{"a":2901,"l":"person_index","c":"Index 0-15 of the person record being processed by the scan at $9B7D. $9B7F clears it, $9DC9 increments it, and $9DCF stops the scan at 16; $9DD3-$9DD5 shifts it left twice to make the byte offset into the four-byte records at $0CA0.","t":"byte","b":[16],"x":[39807,40393,40396]},{"a":2902,"l":"a_0B56","c":"Saves the record offset of the person being processed across the calls at $9C13-$9C4A and $9D30-$9D45 that pick a random number or draw a shape, both of which use X. Restored with ldx immediately afterwards.","t":"byte","b":[0],"x":[39955,39961,40002,40010,40240,40261]},{"a":2903,"l":"a_0B57","c":"Written at $9E68 and $9E85 and read at $9E7F, $9EDE and $9F09, all inside $9E55-$9F0E, the routine that moves a person between the ground and the helicopter. It holds a record offset; the exact role is not established.","t":"byte","b":[0],"x":[40552,40575,40581,40670,40713]},{"a":2904,"l":"a_0B58","c":"Written once at $9E94 and read at $9EC1 and $9EEF, inside the same routine as $0B57. It holds a second record offset so two person records can be updated together. Meaning not established.","t":"byte","b":[0],"x":[40596,40641,40687]},{"a":2905,"l":"a_0B59","c":"Written at $A141 and $A1C3 and tested with bit at $A20F and $A23B, so only its top bits are read. Local to the actor-movement code at $A10A-$A240; meaning not established.","t":"byte","b":[0],"x":[41281,41411,41487,41531]},{"a":2906,"l":"a_0B5A","c":"Written at $A2C6, read at $A2CC as an index and at $A349. It carries an actor slot offset from $A2C6 to the code at $A2CC-$A349 that copies one actor's position into another. The three bytes $0B5B-$0B5D that its span covers are touched by no instruction in $8000-$BFFF.","t":"byte","b":[20,0,0,0],"x":[41670,41676,41801]},{"a":2910,"l":"a_0B5E","c":"Frequency low byte of the rotor sound on SID voice 1. $996B-$999B slides it up by $10 a frame towards $C0 while $5D is non-zero and down by $10 a frame towards $30 while it is zero, writing every new value straight to $D400; $A781 presets it when an effect starts. Voice 1 is gated on only while $0CE0 is non-zero.","t":"byte","b":[192],"x":[39294,39308,39320,42881]},{"a":2911,"l":"a_0B5F","c":"Written once at $A8B8 and read once at $A921, carrying a value from the helicopter update into the routine at $A91A that adds it to the horizontal speed $5A. Meaning not established.","t":"byte","b":[0],"x":[43192,43297]},{"a":2912,"l":"a_0B60","c":"Counts the three passes of the loop at $AA98-$AABE that tests and draws the three background layers: $AA95 sets it to 3 and $AAB5 decrements it, with $AABA/$AABC stepping the position between passes.","t":"byte","b":[0],"x":[43669,43701]},{"a":2913,"l":"a_0B61","c":"Written at $AC25 and $AC2D and read at $AC1D and $AC30 (as an index), inside the helicopter-shape chooser at $AC14-$AC40. It remembers which of two shape slots was used last. Meaning not established.","t":"byte","b":[0],"x":[44061,44069,44077,44080]},{"a":2914,"l":"a_0B62","c":"The same pattern as $0B61 one routine later: written at $AC85 and $AC8D and read at $AC7D and $AC90 as an index, inside $AC79-$ACA0. Meaning not established.","t":"byte","b":[2],"x":[44157,44165,44173,44176]},{"a":2915,"l":"a_0B63","c":"Written at $B2AA and read at $B2E3, where it is subtracted; it carries a value across the routine at $B2AA-$B2E8 that moves an actor by its velocity fields. Meaning not established.","t":"byte","b":[3],"x":[45738,45795]},{"a":2916,"l":"a_0B64","c":"Saves the actor slot offset ($72) across the routines at $B665 and $B6ED that allocate one or two extra actor records: $B667 and $B6EF store it, $B6E7, $B6FC and $B737 put it back into $72 so the caller's actor is current again when they return.","t":"byte","b":[0],"x":[46695,46823,46831,46844,46903]},{"a":2917,"l":"a_0B65","c":"Second saved slot offset used with $0B64 by $B665: $B6D7 stores the first of the two new records while $B6DC links the second into the actor list, and $B6DF gets it back so it can be linked in too.","t":"byte","b":[0],"x":[46807,46815]},{"a":2918,"l":"a_0B66","c":"Saves an actor's +3 field across the call to $B2AA at $B815: $B80D stores it, $B812 zeroes the field so the move routine leaves it alone, and $B81A/$B81D puts it back. Local to the actor handler at $B73D-$B8AB.","t":"byte","b":[0],"x":[47117,47130]},{"a":2919,"l":"a_0B67","c":"Set to 0 at $B73F and to $FF at $B778 depending on whether the actor's shape was actually drawn this frame; $B7DA tests bit 7 and $B82B tests it for zero, so the actor only moves and only spawns while it is visible.","t":"byte","b":[0],"x":[46911,46968,47066,47147]},{"a":2920,"l":"a_0B68","c":"Saves the slot offset of the actor that is spawning while $B845-$B881 fills in and links the new record, and $B884/$B887 restores it into $72 afterwards. $B84F also uses it as the Y index that copies the parent's position into the child.","t":"byte","b":[0],"x":[47170,47183,47236]},{"a":2921,"l":"a_0B69","c":"Counts the four passes of the loop at $B8D2-$B96D that draws the four numbered objects on the ground: $B8BC clears it, $B960 increments it and $B966 stops at 4. $B8EA and $B92B use it to index the per-object state array at $0CF4.","t":"byte","b":[4],"x":[47292,47338,47403,47456,47459]},{"a":2922,"l":"a_0B6A","c":"Low byte of the X position of the first object drawn by $B8D2: $B8C7 derives it from bit 0 of the view origin $75 (so the object lands on an even pixel) with bit 7 set, $B8CA decrements it and $B8D3 reads it back. $B8CF holds the high byte in $0B6B.","t":"byte","b":[128],"x":[47303,47306,47315]},{"a":2923,"l":"a_0B6B","c":"High byte of the position whose low byte is $0B6A, set to 3 by $B8CF and incremented by $B96A once per object, which is what spaces the four ground objects 256 pixels apart.","t":"byte","b":[6],"x":[47311,47322,47466]},{"a":2924,"l":"a_0B6C","c":"First of the four 16-bit X positions at $0B6C-$0B73 that the hangar drawer $B971 computes and then walks with an index at $BA0B/$BA10. $B9ED writes this low byte; the four positions are drawn with the shape at $8095 and the rows in the table at $BA3B.","t":"byte","b":[102],"x":[47597,47627]},{"a":2925,"l":"a_0B6D","c":"High byte of the first hangar position whose low byte is $0B6C, written at $B9F4 and read through the indexed load at $BA10.","t":"byte","b":[17],"x":[47604,47632]},{"a":2926,"l":"a_0B6E","c":"Low byte of the second of the four hangar positions, written at $B9D7 after a call to the shift routine $ACF1 has scaled the distance from the view origin. Read only through the index at $BA0B.","t":"byte","b":[86],"x":[47575]},{"a":2927,"l":"a_0B6F","c":"High byte of the second hangar position, written at $B9DE and read through the index at $BA10.","t":"byte","b":[17],"x":[47582]},{"a":2928,"l":"a_0B70","c":"Low byte of the third of the four hangar positions, written at $B9C1 from the first scaled distance. Read only through the index at $BA0B.","t":"byte","b":[56],"x":[47553]},{"a":2929,"l":"a_0B71","c":"High byte of the third hangar position, written at $B9C8 and read through the index at $BA10.","t":"byte","b":[17],"x":[47560]},{"a":2930,"l":"a_0B72","c":"Low byte of the fourth hangar position, written at $B9FC as the unscaled distance plus the anchor $78/$79, so this is the nearest of the four and the others are parallax-scaled copies of it.","t":"byte","b":[254],"x":[47612]},{"a":2931,"l":"a_0B73","c":"High byte of the fourth hangar position, written at $BA03. It is the last of the individual variables; the actor record array begins at $0B74.","t":"byte","b":[16],"x":[47619]},{"a":2932,"l":"actor_type","c":"Actor record array, 10 bytes per slot, indexed by a byte offset in $72 (0, 10, 20 ... 250), so 26 reachable slots at $0B74-$0C77 inside a 30-record grid that ends at $0C9F. Slot 0 is the list header, not an actor: its +8 is the tail link and its +9 the head link, and $B307 starts every pass with ldx $0B7D. This field, +0, is the actor's type, 0-10, which $B30C-$B32E turns into one of the eleven handler addresses in the table at $B32E; $AA01 gives slot 1 type 0, the player's helicopter, and it is never freed.","t":"byte","b":[0],"x":[40841,40877,41047,41683,43521,45078,45320,45819,45827,45841,46730,46733,46841,47180]},{"a":2933,"l":"actor_vx","c":"Field +1 of an actor record: a signed horizontal velocity or step. $B2B3 adds it to the 16-bit world X in +4/+5 once per pass, $A196/$A1A9 and $B7BA/$B7CB walk it up and down within limits (6 and $FA at $B7C0/$B7D1), and $B6C3 and $B729 give a newly spawned actor $18 or $14 with the sign taken from $77.","t":"byte","b":[0],"x":[40846,40928,40936,41052,41366,41385,41783,44386,44433,44474,44563,44648,44685,44777,44800,44847,44860,44868,44884,44908,44940,44956,44982,44990,45326,45405,45415,45631,45747,45756,45806,46787,46790,46889,47034,47037,47046,47051,47054,47063,47219,47222]},{"a":2934,"l":"actor_vy","c":"Field +2 of an actor record: a signed vertical velocity or step. $B2CF adds it to the height field +6, $A251/$A25F and $B7EA/$B7FB step it between fixed bounds, and the collision paths force it to a fixed value ($B5B5 writes 4, $B64C writes 3, $B65F writes 2) to start an actor falling.","t":"byte","b":[0],"x":[40851,40882,41055,41426,41553,41567,41639,41664,41712,41768,41789,44410,44448,44842,44855,44873,44879,44902,44916,44937,44946,44973,45256,45775,45792,45798,45809,46519,46670,46689,46795,46798,46894,47073,47082,47085,47094,47099,47102,47111,47227]},{"a":2935,"l":"actor_frame","c":"Field +3 of an actor record: an animation or sub-state counter. $A22E and $A238 step it, $B77D increments it and wraps it at 3, $A120/$A1B0/$A216 use it as a Y index when picking a shape, and $AEE4/$AF0A/$AF1D eor with it. Note that the free-list initialiser at $AA19 overruns and leaves $0E in this field of slot 1 before the game starts (see $0B7D).","t":"byte","b":[0],"x":[40782,40798,40967,40990,41058,41228,41248,41392,41494,41518,41528,41703,41773,41795,44418,44547,44603,44772,44810,44829,44963,44968,45456,45785,46713,46801,46804,46873,46897,46973,46976,46985,47114,47122,47133,47142,47230]},{"a":2936,"l":"actor_x","c":"Field +4, the low byte of the actor's 16-bit world X. The whole game works in these coordinates: $A9A9 reads the pair to build a draw position, $B2B0-$B2B6 adds the velocity +1 to it, $B44A and $B578 subtract two actors' X values to measure a distance, and $AEB5/$B093 compare it with the world X in $55/$56.","t":"byte","b":[0],"x":[40770,40793,40975,40998,41105,41123,41178,41287,41590,41621,41626,41646,41651,41687,41692,41718,41721,41736,41739,43433,44617,44622,44725,45018,45094,45207,45225,45228,45744,45750,45912,46002,46005,46086,46089,46149,46214,46280,46350,46394,46456,46459,46698,46738,46741,46847,46850,46993,47186,47189]},{"a":2937,"l":"actor_x_hi","c":"Field +5, the high byte of the actor's 16-bit world X. Written with +4 everywhere a position is set ($9F49, $A016, $A098, $AFDF, $B031, $B09E, $B695, $B708, $B85B) and used as the high half of every distance calculation ($A14E, $A27D, $B583, $B798).","t":"byte","b":[0],"x":[40777,40801,40982,41005,41112,41130,41294,41597,41629,41634,41654,41659,41695,41700,41726,41729,41744,41747,43440,44629,44634,44640,44645,44706,44732,45023,45105,45113,45214,45231,45236,45468,45753,45768,45924,46010,46013,46094,46097,46156,46221,46257,46287,46358,46406,46464,46467,46703,46746,46749,46853,46856,47000,47192,47195]},{"a":2938,"l":"actor_alt","c":"Field +6, the actor's height in bitmap rows above the row named by +7. $A9C3 adds the two together to get the row the shape is drawn on. $B353 treats a value below $0E as touching the ground and $B380 treats $18 or more as clear of it; $B892-$B8A2 kills an actor whose height leaves the range $0A-$9F, and $B2CC-$B2D2 adds the vertical velocity +2 to it.","t":"byte","b":[0],"x":[40806,40897,41063,41302,41751,41756,43459,44586,44591,44660,44674,44680,45031,45120,45241,45498,45525,45582,45592,45652,45668,45714,45724,45772,45778,45812,45904,45935,45949,45980,46071,46074,46134,46199,46708,46757,46765,46860,46865,47007,47152,47198,47201,47250,47266]},{"a":2939,"l":"actor_base_row","c":"Field +7, the bitmap row the actor's height is measured from. Everything standing on the ground gets the ground row $58 (22) here ($AA06, $B6B2, $B716, $B866), and $B349 and $B4BB compare this field with $58 to ask whether an actor is on the ground. $B564 and $B393 subtract two actors' values to see whether they are on the same level.","t":"byte","b":[0],"x":[40826,40836,40905,41071,41605,41760,41765,43462,43526,44595,44600,45036,45125,45246,45484,45495,45516,45729,45782,45788,45894,45968,46187,46264,46418,46436,46770,46773,46870,47206]},{"a":2940,"l":"actor_prev","c":"Field +8, the offset of the previous record in the doubly linked list of live actors. At slot 0 ($0B7C read as an absolute address) it is the list tail. $A937 unlinks a record by writing its predecessor's offset into the successor's +8, and $A95B appends a record by making it the new tail.","t":"byte","b":[10],"x":[43321,43328,43355,43363,43369,43513,43531]},{"a":2941,"l":"actor_next","c":"Field +9, the offset of the next record in the list, 0 for the end. At slot 0 ($0B7D read as an absolute address) it is the list head, which is how $B307 starts its walk. The same field chains the free pool through $74. $A9F9-$AA0E builds the list with slot 1 (the helicopter) as both head and tail, and $AA11-$AA29 then chains the free slots from offset 20 upward - but the loop runs 27 times instead of 23, so the link stored at offset 250 is 4 rather than 0 and the last four stores land at $0B81, $0B8B, $0B95 and $0B9F, the +3 fields of slots 1 to 4. The free chain therefore has 24 usable records (slots 2 to 25) and would return offset 4, which overlaps slots 0 and 1, if more than 24 actors were ever alive at once. This span also covers slots 1 to 5, $0B7E-$0BAF.","t":"byte","b":[10,0,0,0,14,164,17,112],"x":[43324,43332,43339,43349,43360,43374,43516,43534,43552,43561,45831,45836]},{"a":2949,"t":"byte","b":[22,0,0,3,5,252,24,180]},{"a":2957,"t":"byte","b":[4,6,6,10,30,2,1,4]},{"a":2965,"t":"byte","b":[34,151,5,0,22,70,40,2]},{"a":2973,"t":"byte","b":[3,4,0,160,5,0,22,20]},{"a":2981,"t":"byte","b":[50,2,3,2,2,151,5,0]},{"a":2989,"t":"byte","b":[22,20,60]},{"a":2992,"l":"actor_slots_6_11","c":"Actor records for slots 6 to 11, $0BB0-$0BEB, ten bytes each with the fields described at $0B74-$0B7D. Slots 2 upward are the free pool at the start of a sortie, chained through their +9 field from $74, and are handed out by $A951 as shots, explosions, hostages and enemy aircraft are created.","t":"byte","b":[2,3,4,0,156,5,0,22]},{"a":3000,"t":"byte","b":[20,70,2,2,4,0,159,5]},{"a":3008,"t":"byte","b":[0,22,60,80,0,0,0,0]},{"a":3016,"t":"byte","b":[0,0,0,0,0,90,0,0]},{"a":3024,"t":"byte","b":[0,0,0,0,0,0,0,100]},{"a":3032,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3040,"t":"byte","b":[0,110,0,0,0,0,0,0]},{"a":3048,"t":"byte","b":[0,0,0,120]},{"a":3052,"l":"actor_slots_12_13","c":"Actor records for slots 12 and 13, $0BEC-$0BFF. Nothing distinguishes them from the rest of the pool; the split here is only because the cold start's clear loop makes the disassembler mint a symbol at $0C00.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3060,"t":"byte","b":[0,130,0,0,0,0,0,0]},{"a":3068,"t":"byte","b":[0,0,0,140]},{"a":3072,"l":"actor_slots_14_19","c":"Actor records for slots 14 to 19, $0C00-$0C3B. This address is also the third of the five sta $xx00,y in the cold start's clear loop at $BF13, which is what zeroes page $0C before the list is built.","t":"byte","b":[0,0,0,0,0,0,0,0],"x":[48915]},{"a":3080,"t":"byte","b":[0,150,0,0,0,0,0,0]},{"a":3088,"t":"byte","b":[0,0,0,160,0,0,0,0]},{"a":3096,"t":"byte","b":[0,0,0,0,0,170,0,0]},{"a":3104,"t":"byte","b":[0,0,0,0,0,0,0,180]},{"a":3112,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3120,"t":"byte","b":[0,190,0,0,0,0,0,0]},{"a":3128,"t":"byte","b":[0,0,0,200]},{"a":3132,"l":"actor_slots_20_25","c":"Actor records for slots 20 to 25, $0C3C-$0C6D. Slot 25 begins at $0C6E and is the last record the free chain reaches.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3140,"t":"byte","b":[0,210,0,0,0,0,0,0]},{"a":3148,"t":"byte","b":[0,0,0,220,0,0,0,0]},{"a":3156,"t":"byte","b":[0,0,0,0,0,230,0,0]},{"a":3164,"t":"byte","b":[0,0,0,0,0,0,0,240]},{"a":3172,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3180,"t":"byte","b":[0,250]},{"a":3182,"l":"actor_slot_25","c":"Actor record for slot 25, $0C6E-$0C77, the last record a byte index can reach: its offset is 250, so the next would be at 260 and will not fit in the X register. The +9 link here is $04 rather than 0 because of the overrun described at $0B7D. The rest of the 30-record grid, $0C78-$0C9F, is cleared at start-up and never used.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3190,"t":"byte","b":[0,4]},{"a":3192,"t":"gap","n":40},{"a":3232,"l":"person_state","c":"People array, sixteen four-byte records at $0CA0-$0CDF, scanned once per frame by $9B7D with the index in $0B55. This field, +0, is the state: $FF marks a free record ($9B86 skips it, $9BA8, $9DC6, $B640 and $BBC3 set it), otherwise it is a walk phase that $9BDB increments and wraps at 4. $BE52-$BEB1 seeds eight of the sixteen at the start of a sortie with phases 0-3 and X positions spaced about $20-$9E apart from $0750 upward; $BBB5-$BBC6 marks all sixteen free.","t":"byte","b":[1],"x":[39811,39850,39899,39902,39914,40077,40168,40205,40218,40292,40298,40324,40350,40374,40390,40470,40591,40644,40690,46334,46656,48067,48762]},{"a":3233,"l":"person_dir","c":"Field +1 of a people record: the walking direction. $9BB0-$9BD8 reads it and moves the X position two pixels right for $01, two left for $FF, and leaves it alone for 0. Written at $9C5B, $9C70, $9C77, $9CDA, $9CED, $9D06, $9D12, $9EC9, $9EFE and cleared for every record by $BE7F when the sortie starts.","t":"byte","b":[1],"x":[39856,40020,40027,40048,40055,40104,40154,40173,40198,40210,40278,40649,40702,46339,48767]},{"a":3234,"l":"person_x","c":"Field +2, the low byte of a person's 16-bit world X. $9BBE-$9BD3 steps it by two as the person walks, $9BFC, $9C36 and $9CB5 subtract the world X $55/$56 from it to see how far away the helicopter is, and $9DDB uses it to place the shape.","t":"byte","b":[122],"x":[39870,39875,39886,39891,39929,39987,40065,40114,40411,40659,40710,46353,48772]},{"a":3235,"l":"person_x_hi","c":"Field +3, the high byte of a person's world X, and the last field of the record. $9B8C-$9B9E compares it with $56 and retires the person (setting +0 to $FF and decrementing $0CF2) when the difference reaches $12 pages, which is how people that scroll off the world are recycled. This span also covers the remaining fifteen records, $0CA4-$0CDF.","t":"byte","b":[6,2,1,210,6,3,0,44],"x":[39820,39835,39880,39896,39921,39934,39948,39992,40033,40058,40097,40121,40418,40666,40718,46361,48777]},{"a":3243,"t":"byte","b":[8,2,1,6,9,3,1,38]},{"a":3251,"t":"byte","b":[9,1,1,120,9,2,0,204]},{"a":3259,"t":"byte","b":[9,0,1,74,10,255,0,0]},{"a":3267,"t":"byte","b":[0,255,0,0,0,255,0,0]},{"a":3275,"t":"byte","b":[0,255,0,0,0,255,0,0]},{"a":3283,"t":"byte","b":[0,255,0,0,0,255,0,0]},{"a":3291,"t":"byte","b":[0,255,0,0,0]},{"a":3296,"l":"engine_on","c":"Gate for the rotor sound. $9668 sets it to $FF for the playing phase and $95ED, $9635 and $96F1 clear it for the title, the sortie message and the closing screen. $9970 is the only reader: with a zero here $999F silences SID voice 1, otherwise $9975 gates it on and the frequency slide at $997E-$999B runs.","t":"byte","b":[255],"x":[38381,38453,38504,38641,39280]},{"a":3297,"l":"a_0CE1","c":"Set at $A0B2 when the actor whose slot offset is kept in $0CE2 is created, and cleared at $AA2E (sortie start), $B63A, $B7B0 and $B8A5 when it dies. $A38C and $B3EC test it before anything uses $0CE2, so it is the 'the slot in $0CE2 is valid' flag. What kind of actor that slot holds is decided outside this range.","t":"byte","b":[0],"x":[41138,41868,43566,46060,46249,46650,47024,47269]},{"a":3298,"l":"a_0CE2","c":"The actor slot offset that goes with the flag in $0CE1: $A0B7 stores it when the actor is created, $B3F3 uses it as a Y index and $B630 loads it into $72 so $B2EA can destroy that actor. Meaning beyond 'one particular actor the game keeps a handle on' not established.","t":"byte","b":[0],"x":[41143,46067,46640]},{"a":3299,"l":"hit_list_len","c":"Number of entries in the short list of actor slot offsets at $0CE4, 0 to 4. $AA31 clears it at the start of a sortie, $A033-$A03C appends to it, $A39D compares against it, $B386 walks the list backwards from it when a shot is tested against the actors, and $B5F5/$B628 decrement it when an entry is removed.","t":"byte","b":[0],"x":[41011,41020,41885,43569,45958,46581,46632]},{"a":3300,"l":"hit_list","c":"Up to four actor slot offsets, $0CE4-$0CE7, with the count in $0CE3. $A038 writes an entry, $B38C reads them while testing a falling shot against every listed actor, and $B5FA-$B61B removes one by shifting the later entries down. $B61F destroys the actor an entry names and then removes the entry.","t":"byte","b":[0],"x":[41016,45964,46586,46607,46624]},{"a":3301,"l":"a_0CE5","c":"Second entry of the four-slot list that starts at $0CE4: compared at $B5FF and $B604 while an entry is being removed and moved down into $0CE4 by $B60C-$B60F.","t":"byte","b":[0],"x":[46591,46604,46613]},{"a":3302,"l":"a_0CE6","c":"Third entry of the four-slot list that starts at $0CE4, moved down into $0CE5 by $B612-$B615 when an earlier entry is removed.","t":"byte","b":[0],"x":[46596,46610,46619]},{"a":3303,"l":"a_0CE7","c":"Fourth and last entry of the list that starts at $0CE4, read only at $B618 to fill the gap left in $0CE6. Nothing ever writes it directly, so a full list of four can only be built by $A038 indexing with the count in $0CE3.","t":"byte","b":[0],"x":[46616]},{"a":3304,"l":"board_list_len","c":"Number of entries in the second short list of actor slot offsets, the one at $0CE9; 0 to 4. $AA34 clears it at the start of a sortie, $9F9E-$9FA2 appends to it, $B557 walks it backwards, and $B5C4 and $B5CC decrement it when an entry is removed. The scan at $B55E uses the list to find an actor within ten rows and fourteen pixels of the one being tested.","t":"byte","b":[0],"x":[40817,40857,40866,41895,43572,46423,46532,46540]},{"a":3305,"l":"board_list","c":"Up to four actor slot offsets, $0CE9-$0CEC, with the count in $0CE8. $9F77 reads one with a Y index, $B5BC turns an index into a slot offset so $B5C1 can destroy that actor, and $B5D1-$B5F1 removes an entry by shifting the later ones down.","t":"byte","b":[20],"x":[40823,40862,46430,46524,46545,46565]},{"a":3306,"l":"a_0CEA","c":"Second entry of the four-slot list that starts at $0CE9: compared at $B5D6, moved down into $0CE9 at $B5E2-$B5E5 and overwritten from $0CEB at $B5E8-$B5EB when an earlier entry goes.","t":"byte","b":[0],"x":[46550,46562,46571]},{"a":3307,"l":"a_0CEB","c":"Third entry of the list that starts at $0CE9, compared at $B5DB and moved down into $0CEA at $B5E8-$B5EB.","t":"byte","b":[0],"x":[46555,46568,46577]},{"a":3308,"l":"a_0CEC","c":"Fourth and last entry of the list that starts at $0CE9, read only at $B5EE to fill the gap left in $0CEB.","t":"byte","b":[0],"x":[46574]},{"a":3309,"l":"a_0CED","c":"Set to $38 (56) by $BE52 when a sortie's people are seeded, read at $9E31 and decremented at $9EE4. It belongs to the hostage bookkeeping with $0CEE, $0CEF, $0CF0 and $0CF2; 56 plus the 8 records $BE52 seeds on screen is the 64 that $967C and $9687 test for, so it appears to be the reserve of hostages not yet brought into play, but nothing in the code says so outright.","t":"byte","b":[56],"x":[40497,40676,48729]},{"a":3310,"l":"hostages_saved","c":"Cleared by the panel reset at $BB8C and incremented at $9E9B. $9679 compares it with $40 (64) and, when all 64 are accounted for here, jumps to $96E8 which prints message 4, MAGNIFICENT!. $9683-$9687 adds $0CEF to it and, when that total reaches 64, prints message 3, THE END, instead.","t":"byte","b":[0],"x":[38521,40603,48012]},{"a":3311,"l":"hostages_lost","c":"Cleared by $BB8F and incremented at $9E19 and $B643; $A894-$A897 adds to it in bulk. It is the counterpart of $0CEE in the 64-hostage total tested at $9687: when the two together reach 64 with $0CEE short of 64, the game ends with THE END rather than MAGNIFICENT!.","t":"byte","b":[0],"x":[38532,40473,43156,43159,46659,48015]},{"a":3312,"l":"a_0CF0","c":"Set to 8 by $BE52, the number of people seeded on screen at the start of a sortie. $9D20, $9E1C and $B646 decrement it as people leave play and $9EE7 increments it as they arrive; $9E23-$9E36 reads it together with $0CF2 and $0CF1 when the game decides whether to bring another hostage out of the shed.","t":"byte","b":[8],"x":[40224,40476,40486,40502,40679,46662,48724]},{"a":3313,"l":"a_0CF1","c":"Cleared by $BB92, incremented at $9D1D and decremented at $9E9E, and read at $9C2B, $9CD1, $9CFD, $9E40, $A885, $A891 and $A89C. $A885-$A89C moves its value into $0CEF in one go, so it counts hostages that are in the helicopter and are lost if it is destroyed. The exact transitions are decided outside this range.","t":"byte","b":[0],"x":[39979,40145,40189,40221,40512,40606,43141,43153,43164,48018]},{"a":3314,"l":"a_0CF2","c":"Cleared by $BB95, decremented at $9BA5 and $9C88 and incremented at $9EA1, and read once at $9E23. It counts people records that are alive but off the visible part of the world; $9BA5 decrements it at the same moment $9BAA retires a person that has scrolled $12 pages away.","t":"byte","b":[0],"x":[39845,40072,40483,40609,48021]},{"a":3315,"l":"shots_in_flight","c":"Number of the player's shots currently alive, 0 to 5. $BED6 clears it at the start of a sortie, $B00C increments it when a shot is created, and $B1DB, $B1E4, $B375, $B3E6 and $B42C decrement it when one hits something or reaches the ground. $97DE-$97E3 refuses to fire when it has reached 5, which is the on-screen limit.","t":"byte","b":[0],"x":[38878,45068,45531,45540,45941,46054,46124,48854]},{"a":3316,"l":"ground_obj_state","c":"Four bytes, $0CF4-$0CF7, one per numbered object on the ground, all cleared by $BBAA at the start of a sortie. $B65A sets an entry to 1 when its object is hit, $B653 tests it so an object is only hit once, and $B8ED/$B92E read it while $B8D2-$B96D draws the four objects, choosing a damaged shape and adding the extra piece at $809D when the entry is non-zero. $0CF7 is separately set to 1 by $BE63.","t":"byte","b":[0,0,1],"x":[40533,40555,46675,46682,47341,47406,48042]},{"a":3319,"l":"a_0CF7","c":"Fourth byte of the four-entry ground-object hit array that starts at $0CF4. Cleared with the other three by $BBAA at the start of a sortie and then set to 1 on its own by $BE63 when the sortie's people are seeded, so the fourth object starts the sortie already marked.","t":"byte","b":[1],"x":[48739]},{"a":3320,"l":"ground_obj_count","c":"Four bytes, $0CF8-$0CFB, one per ground object, all set to $10 (16) by $BBAF at the start of a sortie. $9E5A and $9E70 read an entry and $9EE1 decrements one; sixteen per object times four objects is the 64 hostages the game counts towards in $0CEE. $0CFB is separately set to 8 by $BE5E.","t":"byte","b":[16,16,16],"x":[40538,40560,40673,48047]},{"a":3323,"l":"a_0CFB","c":"Fourth byte of the four-entry ground-object count array that starts at $0CF8. $BBAF gives all four the value $10 (16) at the start of a sortie and $BE5E then overwrites this one with 8, so the fourth object holds half as many as the other three.","t":"byte","b":[8],"x":[48734]},{"a":3324,"l":"a_0CFC","c":"Cleared by the panel reset at $BB9D, read at $A6EE and $B0D8 and rewritten at $A6F3 and $B0DD, both of which are read-modify-write pairs in the routines that place a sound or a shot. Meaning not established.","t":"byte","b":[0],"x":[42734,42739,45272,45277,48029]},{"a":3325,"l":"a_0CFD","c":"Cleared by $BBA0 and read and rewritten by the pair at $A3F2/$A3F7 only. A single-routine counter in the enemy-aircraft code; meaning not established.","t":"byte","b":[0],"x":[41970,41975,48032]},{"a":3326,"l":"a_0CFE","c":"Cleared by $BBA3 and by $A6D8, and read and rewritten by the pairs at $A3C0/$A3C5 and $A3D9/$A3DE. Like $0CFD it is confined to $A3B0-$A6E0; meaning not established.","t":"byte","b":[0],"x":[41920,41925,41945,41950,42712,48035]},{"a":3327,"l":"sortie_number","c":"Which sortie is being played, 0, 1 or 2. $BB9A clears it when the panel is reset, $964B increments it after each sortie message has been shown, and $961E-$9623 uses it both as the index into the five-message table at $8AD7 (0 FIRST SORTIE, 1 SECOND SORTIE, 2 THIRD SORTIE) and as the test that ends the game: when it reaches 3, $9625 jumps to $96E4 which prints message 3, THE END.","t":"byte","b":[2],"x":[38430,38475,48026]},{"a":3328,"l":"a_0D00","c":"Cleared by $BF02 at the start of a sortie and by the cold start's clear loop at $BF16 (which is what zeroes page $0D). $9D28 sets it, $9EB1 rewrites it and $9EAA tests bit 7, all inside the code that moves a person between the ground and the helicopter. Meaning not established.","t":"byte","b":[0],"x":[40232,40618,40625,48898,48918]},{"a":3329,"l":"a_0D01","c":"Cleared at the top of every frame by $9673 and set at $9D4A; $9D2B tests bit 7. A one-frame flag raised by the people scan and read by the same scan later in the frame. Meaning not established.","t":"byte","b":[0],"x":[38515,40235,40266]},{"a":3330,"l":"a_0D02","c":"Cleared at the top of every frame by $9676 and set at $B0FE; $B0E6 tests bit 7. A one-frame flag raised in the shot-handling code at $B0D2-$B101. Meaning not established.","t":"byte","b":[0],"x":[38518,45286,45310]},{"a":3331,"l":"draw_list_a","c":"First of the two display lists, $0D03-$0DA2, 160 bytes holding up to forty four-byte entries: kind, view-relative X low, X high, bitmap row. $A9E9 points $99/$9A here at the start of a sortie and $AA38 appends an entry for every shape the frame draws. $BBE6 swaps the two list pointers each frame so that the list just built becomes the one $BC05 replays to erase. This first 64 bytes holds entries 0-15.","t":"byte","b":[1,88,0,29,19,1,1,25]},{"a":3339,"t":"byte","b":[20,50,1,34,22,250,255,28]},{"a":3347,"t":"byte","b":[0,70,0,134,0,70,0,134]},{"a":3355,"t":"byte","b":[5,222,0,32,5,218,0,32]},{"a":3363,"t":"byte","b":[5,224,0,30,5,220,0,30]},{"a":3371,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3379,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3387,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3395,"l":"draw_list_a_16","c":"Entries 16 to 31 of the display list that starts at $0D03. Each entry is four bytes and the count of bytes in use is kept in $9D (or $9E once the lists have been swapped), so the list is only ever read as far as it was filled.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3403,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3411,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3419,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3427,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3435,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3443,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3451,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3459,"l":"draw_list_a_32","c":"Entries 32 to 39, the last eight of the display list that starts at $0D03. Nothing checks for overflow: $AA38 adds four to $9D without a limit, so a frame that queued more than forty shapes would run on into the second list at $0DA3.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3467,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3475,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3483,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3491,"l":"draw_list_b","c":"Second of the two display lists, $0DA3-$0E42, the same 160-byte, forty-entry layout as $0D03. $A9F1 points $9B/$9C here at the start of a sortie and $BBE6-$BBF4 exchanges the pair with $99/$9A once per frame, so the two lists alternate between 'being built' and 'being replayed to erase'. This first 64 bytes holds entries 0-15.","t":"byte","b":[1,82,0,29,19,245,0,25]},{"a":3499,"t":"byte","b":[20,62,1,34,22,8,0,28]},{"a":3507,"t":"byte","b":[0,70,0,134,0,70,0,134]},{"a":3515,"t":"byte","b":[5,218,0,32,5,222,0,32]},{"a":3523,"t":"byte","b":[5,216,0,30,0,0,0,0]},{"a":3531,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3539,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3547,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3555,"l":"draw_list_b_16","c":"Entries 16 to 30 of the display list that starts at $0DA3. $BC05-$BC18 walks the list four bytes at a time, rebuilding $71, $6A, $6B and $6C from each entry before erasing the rectangle it describes.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3563,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3571,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3579,"t":"byte","b":[0,0,0,0,0]},{"a":3584,"l":"draw_list_b_23","c":"Entries 23 to 38 of the display list that starts at $0DA3. This address is also the fifth destination in the cold start's clear loop, where $BF19, $BF1C and $BF1F are three identical sta $0E00,y instructions: page $0E is zeroed three times over and no other page is cleared by those three stores.","t":"byte","b":[0,0,0,0,0,0,0,0],"x":[48921,48924,48927]},{"a":3592,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3600,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3608,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3616,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3624,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3632,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3640,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":3648,"l":"draw_list_b_end","c":"Last entry of the display list that starts at $0DA3: bytes $0E40-$0E42 are the X high byte and row of entry 39, and $0E43 is the one byte of the page that belongs to neither list nor to the scratch word at $0E44.","t":"byte","b":[0,0,0]},{"a":3651,"t":"gap","n":1},{"a":3652,"l":"erase_hdr","c":"A two-byte synthetic shape header, width then height, used to erase one display-list entry. $BC84-$BC86 puts the (clipped) width from $7B here and $BC81 the clipped height from $0B52, then $BC89 passes the address $0E44 to $8BBA so the drawing code treats the pair as a shape header, $BC8E loads the position from $6A, and $BC93 calls the solid-rectangle drawer $8C5E. The cold start at $BF26 leaves $FF here.","t":"byte","b":[7],"x":[48262,48934]},{"a":3653,"l":"a_0E45","c":"Height half of the two-byte erase header at $0E44, written by $BC81 from $0B52 and set to $FF by the cold start at $BF29. The bytes above it, $0E46 to $0EFF, are zeroed by $BF06 and read by nothing in $8000-$BFFF.","t":"byte","b":[23],"x":[48257,48937]},{"a":3654,"t":"gap","n":442},{"a":4096,"l":"preshift_keep_0","c":"The blitter's shift-by-0 table: entry y = y, an identity map. $8DF3 selects it by setting zpa_43 to $10 when zpa_09 is 0, i.e. when the shape's screen bit column is a multiple of 8 and the row can be copied straight into the bitmap cells with no shifting at all. Its twin at $1800 is all zeroes for the same reason. This is also why the 4 KB lives here: in VIC bank 0 the VIC sees character ROM at $1000-$1FFF, so the RAM underneath is invisible to the video chip and free for the CPU. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,1,2,3,4,5,6,7]},{"a":4104,"t":"byte","b":[8,9,10,11,12,13,14,15]},{"a":4112,"t":"byte","b":[16,17,18,19,20,21,22,23]},{"a":4120,"t":"byte","b":[24,25,26,27,28,29,30,31]},{"a":4128,"t":"byte","b":[32,33,34,35,36,37,38,39]},{"a":4136,"t":"byte","b":[40,41,42,43,44,45,46,47]},{"a":4144,"t":"byte","b":[48,49,50,51,52,53,54,55]},{"a":4152,"t":"byte","b":[56,57,58,59,60,61,62,63]},{"a":4160,"t":"byte","b":[64,65,66,67,68,69,70,71]},{"a":4168,"t":"byte","b":[72,73,74,75,76,77,78,79]},{"a":4176,"t":"byte","b":[80,81,82,83,84,85,86,87]},{"a":4184,"t":"byte","b":[88,89,90,91,92,93,94,95]},{"a":4192,"t":"byte","b":[96,97,98,99,100,101,102,103]},{"a":4200,"t":"byte","b":[104,105,106,107,108,109,110,111]},{"a":4208,"t":"byte","b":[112,113,114,115,116,117,118,119]},{"a":4216,"t":"byte","b":[120,121,122,123,124,125,126,127]},{"a":4224,"t":"byte","b":[128,129,130,131,132,133,134,135]},{"a":4232,"t":"byte","b":[136,137,138,139,140,141,142,143]},{"a":4240,"t":"byte","b":[144,145,146,147,148,149,150,151]},{"a":4248,"t":"byte","b":[152,153,154,155,156,157,158,159]},{"a":4256,"t":"byte","b":[160,161,162,163,164,165,166,167]},{"a":4264,"t":"byte","b":[168,169,170,171,172,173,174,175]},{"a":4272,"t":"byte","b":[176,177,178,179,180,181,182,183]},{"a":4280,"t":"byte","b":[184,185,186,187,188,189,190,191]},{"a":4288,"t":"byte","b":[192,193,194,195,196,197,198,199]},{"a":4296,"t":"byte","b":[200,201,202,203,204,205,206,207]},{"a":4304,"t":"byte","b":[208,209,210,211,212,213,214,215]},{"a":4312,"t":"byte","b":[216,217,218,219,220,221,222,223]},{"a":4320,"t":"byte","b":[224,225,226,227,228,229,230,231]},{"a":4328,"t":"byte","b":[232,233,234,235,236,237,238,239]},{"a":4336,"t":"byte","b":[240,241,242,243,244,245,246,247]},{"a":4344,"t":"byte","b":[248,249,250,251,252,253,254,255]},{"a":4352,"l":"preshift_keep_1","c":"Shift-by-1: entry y = y >> 1. Read through ($42) by $8FD3 as the part of a shape byte that stays in the current bitmap cell when the shape sits 1 bit right of a cell boundary (zpa_09 = 1, so zpa_43 = $11). Values run 0 to $7F with each result repeated for two consecutive indices, and bit 7 is always clear. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,1,1,2,2,3,3]},{"a":4360,"t":"byte","b":[4,4,5,5,6,6,7,7]},{"a":4368,"t":"byte","b":[8,8,9,9,10,10,11,11]},{"a":4376,"t":"byte","b":[12,12,13,13,14,14,15,15]},{"a":4384,"t":"byte","b":[16,16,17,17,18,18,19,19]},{"a":4392,"t":"byte","b":[20,20,21,21,22,22,23,23]},{"a":4400,"t":"byte","b":[24,24,25,25,26,26,27,27]},{"a":4408,"t":"byte","b":[28,28,29,29,30,30,31,31]},{"a":4416,"t":"byte","b":[32,32,33,33,34,34,35,35]},{"a":4424,"t":"byte","b":[36,36,37,37,38,38,39,39]},{"a":4432,"t":"byte","b":[40,40,41,41,42,42,43,43]},{"a":4440,"t":"byte","b":[44,44,45,45,46,46,47,47]},{"a":4448,"t":"byte","b":[48,48,49,49,50,50,51,51]},{"a":4456,"t":"byte","b":[52,52,53,53,54,54,55,55]},{"a":4464,"t":"byte","b":[56,56,57,57,58,58,59,59]},{"a":4472,"t":"byte","b":[60,60,61,61,62,62,63,63]},{"a":4480,"t":"byte","b":[64,64,65,65,66,66,67,67]},{"a":4488,"t":"byte","b":[68,68,69,69,70,70,71,71]},{"a":4496,"t":"byte","b":[72,72,73,73,74,74,75,75]},{"a":4504,"t":"byte","b":[76,76,77,77,78,78,79,79]},{"a":4512,"t":"byte","b":[80,80,81,81,82,82,83,83]},{"a":4520,"t":"byte","b":[84,84,85,85,86,86,87,87]},{"a":4528,"t":"byte","b":[88,88,89,89,90,90,91,91]},{"a":4536,"t":"byte","b":[92,92,93,93,94,94,95,95]},{"a":4544,"t":"byte","b":[96,96,97,97,98,98,99,99]},{"a":4552,"t":"byte","b":[100,100,101,101,102,102,103,103]},{"a":4560,"t":"byte","b":[104,104,105,105,106,106,107,107]},{"a":4568,"t":"byte","b":[108,108,109,109,110,110,111,111]},{"a":4576,"t":"byte","b":[112,112,113,113,114,114,115,115]},{"a":4584,"t":"byte","b":[116,116,117,117,118,118,119,119]},{"a":4592,"t":"byte","b":[120,120,121,121,122,122,123,123]},{"a":4600,"t":"byte","b":[124,124,125,125,126,126,127,127]},{"a":4608,"l":"preshift_keep_2","c":"Shift-by-2: entry y = y >> 2, values 0 to $3F with each repeated four times. Selected when zpa_09 = 2 (zpa_43 = $12), which for a multicolour bitmap is a whole pixel's offset: the commonest case for an object that moves by pixels rather than by cells. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,0,0,1,1,1,1]},{"a":4616,"t":"byte","b":[2,2,2,2,3,3,3,3]},{"a":4624,"t":"byte","b":[4,4,4,4,5,5,5,5]},{"a":4632,"t":"byte","b":[6,6,6,6,7,7,7,7]},{"a":4640,"t":"byte","b":[8,8,8,8,9,9,9,9]},{"a":4648,"t":"byte","b":[10,10,10,10,11,11,11,11]},{"a":4656,"t":"byte","b":[12,12,12,12,13,13,13,13]},{"a":4664,"t":"byte","b":[14,14,14,14,15,15,15,15]},{"a":4672,"t":"byte","b":[16,16,16,16,17,17,17,17]},{"a":4680,"t":"byte","b":[18,18,18,18,19,19,19,19]},{"a":4688,"t":"byte","b":[20,20,20,20,21,21,21,21]},{"a":4696,"t":"byte","b":[22,22,22,22,23,23,23,23]},{"a":4704,"t":"byte","b":[24,24,24,24,25,25,25,25]},{"a":4712,"t":"byte","b":[26,26,26,26,27,27,27,27]},{"a":4720,"t":"byte","b":[28,28,28,28,29,29,29,29]},{"a":4728,"t":"byte","b":[30,30,30,30,31,31,31,31]},{"a":4736,"t":"byte","b":[32,32,32,32,33,33,33,33]},{"a":4744,"t":"byte","b":[34,34,34,34,35,35,35,35],"x":[32868]},{"a":4752,"t":"byte","b":[36,36,36,36,37,37,37,37]},{"a":4760,"t":"byte","b":[38,38,38,38,39,39,39,39]},{"a":4768,"t":"byte","b":[40,40,40,40,41,41,41,41]},{"a":4776,"t":"byte","b":[42,42,42,42,43,43,43,43]},{"a":4784,"t":"byte","b":[44,44,44,44,45,45,45,45]},{"a":4792,"t":"byte","b":[46,46,46,46,47,47,47,47]},{"a":4800,"t":"byte","b":[48,48,48,48,49,49,49,49]},{"a":4808,"t":"byte","b":[50,50,50,50,51,51,51,51]},{"a":4816,"t":"byte","b":[52,52,52,52,53,53,53,53]},{"a":4824,"t":"byte","b":[54,54,54,54,55,55,55,55]},{"a":4832,"t":"byte","b":[56,56,56,56,57,57,57,57]},{"a":4840,"t":"byte","b":[58,58,58,58,59,59,59,59]},{"a":4848,"t":"byte","b":[60,60,60,60,61,61,61,61]},{"a":4856,"t":"byte","b":[62,62,62,62,63,63,63,63]},{"a":4864,"l":"preshift_keep_3","c":"Shift-by-3: entry y = y >> 3, values 0 to $1F, eight indices per result. Selected when zpa_09 = 3 (zpa_43 = $13). With the twin at $1B00 it lets $8FD3 drop a shape row 3 bits right of a cell boundary with two table reads and an ora per byte. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":4872,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":4880,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":4888,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":4896,"t":"byte","b":[4,4,4,4,4,4,4,4]},{"a":4904,"t":"byte","b":[5,5,5,5,5,5,5,5]},{"a":4912,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":4920,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":4928,"t":"byte","b":[8,8,8,8,8,8,8,8]},{"a":4936,"t":"byte","b":[9,9,9,9,9,9,9,9]},{"a":4944,"t":"byte","b":[10,10,10,10,10,10,10,10]},{"a":4952,"t":"byte","b":[11,11,11,11,11,11,11,11]},{"a":4960,"t":"byte","b":[12,12,12,12,12,12,12,12]},{"a":4968,"t":"byte","b":[13,13,13,13,13,13,13,13]},{"a":4976,"t":"byte","b":[14,14,14,14,14,14,14,14]},{"a":4984,"t":"byte","b":[15,15,15,15,15,15,15,15]},{"a":4992,"t":"byte","b":[16,16,16,16,16,16,16,16]},{"a":5000,"t":"byte","b":[17,17,17,17,17,17,17,17]},{"a":5008,"t":"byte","b":[18,18,18,18,18,18,18,18]},{"a":5016,"t":"byte","b":[19,19,19,19,19,19,19,19]},{"a":5024,"t":"byte","b":[20,20,20,20,20,20,20,20]},{"a":5032,"t":"byte","b":[21,21,21,21,21,21,21,21]},{"a":5040,"t":"byte","b":[22,22,22,22,22,22,22,22]},{"a":5048,"t":"byte","b":[23,23,23,23,23,23,23,23]},{"a":5056,"t":"byte","b":[24,24,24,24,24,24,24,24]},{"a":5064,"t":"byte","b":[25,25,25,25,25,25,25,25]},{"a":5072,"t":"byte","b":[26,26,26,26,26,26,26,26]},{"a":5080,"t":"byte","b":[27,27,27,27,27,27,27,27]},{"a":5088,"t":"byte","b":[28,28,28,28,28,28,28,28]},{"a":5096,"t":"byte","b":[29,29,29,29,29,29,29,29]},{"a":5104,"t":"byte","b":[30,30,30,30,30,30,30,30]},{"a":5112,"t":"byte","b":[31,31,31,31,31,31,31,31]},{"a":5120,"l":"preshift_keep_4","c":"Shift-by-4: entry y = y >> 4, so the table is simply the high nibble of its index, $00 repeated sixteen times, then $01 sixteen times, and so on to $0F. Selected when zpa_09 = 4 (zpa_43 = $14), a half-cell offset. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5128,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5136,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5144,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5152,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5160,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5168,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5176,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5184,"t":"byte","b":[4,4,4,4,4,4,4,4]},{"a":5192,"t":"byte","b":[4,4,4,4,4,4,4,4]},{"a":5200,"t":"byte","b":[5,5,5,5,5,5,5,5]},{"a":5208,"t":"byte","b":[5,5,5,5,5,5,5,5]},{"a":5216,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":5224,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":5232,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":5240,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":5248,"t":"byte","b":[8,8,8,8,8,8,8,8]},{"a":5256,"t":"byte","b":[8,8,8,8,8,8,8,8]},{"a":5264,"t":"byte","b":[9,9,9,9,9,9,9,9]},{"a":5272,"t":"byte","b":[9,9,9,9,9,9,9,9]},{"a":5280,"t":"byte","b":[10,10,10,10,10,10,10,10]},{"a":5288,"t":"byte","b":[10,10,10,10,10,10,10,10]},{"a":5296,"t":"byte","b":[11,11,11,11,11,11,11,11]},{"a":5304,"t":"byte","b":[11,11,11,11,11,11,11,11]},{"a":5312,"t":"byte","b":[12,12,12,12,12,12,12,12]},{"a":5320,"t":"byte","b":[12,12,12,12,12,12,12,12]},{"a":5328,"t":"byte","b":[13,13,13,13,13,13,13,13]},{"a":5336,"t":"byte","b":[13,13,13,13,13,13,13,13]},{"a":5344,"t":"byte","b":[14,14,14,14,14,14,14,14]},{"a":5352,"t":"byte","b":[14,14,14,14,14,14,14,14]},{"a":5360,"t":"byte","b":[15,15,15,15,15,15,15,15]},{"a":5368,"t":"byte","b":[15,15,15,15,15,15,15,15]},{"a":5376,"l":"preshift_keep_5","c":"Shift-by-5: entry y = y >> 5, only eight distinct results 0 to 7, each covering 32 indices. Selected when zpa_09 = 5 (zpa_43 = $15). At this shift most of each source byte has moved on into the next cell, so the companion table at $1D00 carries five of its eight bits. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5384,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5392,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5400,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5408,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5416,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5424,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5432,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5440,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5448,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5456,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5464,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5472,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5480,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5488,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5496,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5504,"t":"byte","b":[4,4,4,4,4,4,4,4]},{"a":5512,"t":"byte","b":[4,4,4,4,4,4,4,4]},{"a":5520,"t":"byte","b":[4,4,4,4,4,4,4,4]},{"a":5528,"t":"byte","b":[4,4,4,4,4,4,4,4]},{"a":5536,"t":"byte","b":[5,5,5,5,5,5,5,5]},{"a":5544,"t":"byte","b":[5,5,5,5,5,5,5,5]},{"a":5552,"t":"byte","b":[5,5,5,5,5,5,5,5]},{"a":5560,"t":"byte","b":[5,5,5,5,5,5,5,5]},{"a":5568,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":5576,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":5584,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":5592,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":5600,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":5608,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":5616,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":5624,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":5632,"l":"preshift_keep_6","c":"Shift-by-6: entry y = y >> 6, four results 0 to 3, each covering 64 indices - it is just the top two bits of the index. Selected when zpa_09 = 6 (zpa_43 = $16). Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5640,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5648,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5656,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5664,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5672,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5680,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5688,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5696,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5704,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5712,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5720,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5728,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5736,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5744,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5752,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":5760,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5768,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5776,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5784,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5792,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5800,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5808,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5816,"t":"byte","b":[2,2,2,2,2,2,2,2]},{"a":5824,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5832,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5840,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5848,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5856,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5864,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5872,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5880,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":5888,"l":"preshift_keep_7","c":"Shift-by-7: entry y = y >> 7, so the whole table is $00 for indices $00-$7F and $01 for $80-$FF - the sign bit of the index and nothing else. Selected when zpa_09 = 7 (zpa_43 = $17), the largest sub-cell offset, where all but one bit of every source byte spills into the next cell via $1F00. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5896,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5904,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5912,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5920,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5928,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5936,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5944,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5952,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5960,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5968,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5976,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5984,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":5992,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6000,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6008,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6016,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6024,"t":"byte","b":[1,1,1,1,1,1,1,1],"x":[32870]},{"a":6032,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6040,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6048,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6056,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6064,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6072,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6080,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6088,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6096,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6104,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6112,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6120,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6128,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6136,"t":"byte","b":[1,1,1,1,1,1,1,1]},{"a":6144,"l":"preshift_carry_0","c":"The overflow half for shift 0: every one of its 256 entries is $00. When a shape sits exactly on a cell boundary nothing spills into the next cell, so $8FD3's running overflow zpa_41 stays zero and the ora that merges it is a no-op. Reached through ($44) with zpa_45 = $18, set by $8DF3 from zpa_09. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6152,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6160,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6168,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6176,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6184,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6192,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6200,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6208,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6216,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6224,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6232,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6240,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6248,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6256,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6264,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6272,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6280,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6288,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6296,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6304,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6312,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6320,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6328,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6336,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6344,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6352,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6360,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6368,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6376,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6384,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6392,"t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":6400,"l":"preshift_carry_1","c":"Overflow half for shift 1: entry y = (y << 7) and $FF, so $00 when bit 0 of the index is clear and $80 when it is set - the single bit that a 1-bit shift pushes out of the byte. $8FD3 keeps it in zpa_41 and ors it into the next cell to the right; $8E7F also reads this half to seed zpa_41 from the byte clipped off the left of the shape. Selected by zpa_45 = $19. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6408,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6416,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6424,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6432,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6440,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6448,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6456,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6464,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6472,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6480,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6488,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6496,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6504,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6512,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6520,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6528,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6536,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6544,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6552,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6560,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6568,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6576,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6584,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6592,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6600,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6608,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6616,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6624,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6632,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6640,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6648,"t":"byte","b":[0,128,0,128,0,128,0,128]},{"a":6656,"l":"preshift_carry_2","c":"Overflow half for shift 2: entry y = (y << 6) and $FF, the index's low two bits lifted to the top, so the table cycles $00, $40, $80, $C0 through all 256 entries. Selected by zpa_45 = $1A. In multicolour terms it carries exactly one pixel into the neighbouring cell. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6664,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6672,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6680,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6688,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6696,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6704,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6712,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6720,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6728,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6736,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6744,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6752,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6760,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6768,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6776,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6784,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6792,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6800,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6808,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6816,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6824,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6832,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6840,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6848,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6856,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6864,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6872,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6880,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6888,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6896,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6904,"t":"byte","b":[0,64,128,192,0,64,128,192]},{"a":6912,"l":"preshift_carry_3","c":"Overflow half for shift 3: entry y = (y << 5) and $FF, the index's low three bits raised to bits 7-5, stepping $00, $20, $40 ... $E0 and repeating every eight entries. Selected by zpa_45 = $1B. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6920,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6928,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6936,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6944,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6952,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6960,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6968,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6976,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6984,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":6992,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7000,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7008,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7016,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7024,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7032,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7040,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7048,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7056,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7064,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7072,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7080,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7088,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7096,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7104,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7112,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7120,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7128,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7136,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7144,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7152,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7160,"t":"byte","b":[0,32,64,96,128,160,192,224]},{"a":7168,"l":"preshift_carry_4","c":"Overflow half for shift 4: entry y = (y << 4) and $FF, i.e. the low nibble of the index moved into the high nibble, so the table counts $00, $10, $20 ... $F0 and repeats every sixteen entries. Selected by zpa_45 = $1C. Half of every source byte crosses the cell boundary at this shift. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7176,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7184,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7192,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7200,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7208,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7216,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7224,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7232,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7240,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7248,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7256,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7264,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7272,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7280,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7288,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7296,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7304,"t":"byte","b":[128,144,160,176,192,208,224,240],"x":[32872]},{"a":7312,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7320,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7328,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7336,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7344,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7352,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7360,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7368,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7376,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7384,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7392,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7400,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7408,"t":"byte","b":[0,16,32,48,64,80,96,112]},{"a":7416,"t":"byte","b":[128,144,160,176,192,208,224,240]},{"a":7424,"l":"preshift_carry_5","c":"Overflow half for shift 5: entry y = (y << 3) and $FF, the low five bits of the index raised to bits 7-3, so the values step by 8 and repeat every 32 entries. Selected by zpa_45 = $1D. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7432,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7440,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7448,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7456,"t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7464,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7472,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7480,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7488,"t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7496,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7504,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7512,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7520,"t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7528,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7536,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7544,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7552,"t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7560,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7568,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7576,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7584,"t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7592,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7600,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7608,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7616,"t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7624,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7632,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7640,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7648,"t":"byte","b":[0,8,16,24,32,40,48,56]},{"a":7656,"t":"byte","b":[64,72,80,88,96,104,112,120]},{"a":7664,"t":"byte","b":[128,136,144,152,160,168,176,184]},{"a":7672,"t":"byte","b":[192,200,208,216,224,232,240,248]},{"a":7680,"l":"preshift_carry_6","c":"Overflow half for shift 6: entry y = (y << 2) and $FF, the low six bits of the index raised by two places, stepping by 4 and repeating every 64 entries. Selected by zpa_45 = $1E. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,4,8,12,16,20,24,28]},{"a":7688,"t":"byte","b":[32,36,40,44,48,52,56,60]},{"a":7696,"t":"byte","b":[64,68,72,76,80,84,88,92]},{"a":7704,"t":"byte","b":[96,100,104,108,112,116,120,124]},{"a":7712,"t":"byte","b":[128,132,136,140,144,148,152,156]},{"a":7720,"t":"byte","b":[160,164,168,172,176,180,184,188]},{"a":7728,"t":"byte","b":[192,196,200,204,208,212,216,220]},{"a":7736,"t":"byte","b":[224,228,232,236,240,244,248,252]},{"a":7744,"t":"byte","b":[0,4,8,12,16,20,24,28]},{"a":7752,"t":"byte","b":[32,36,40,44,48,52,56,60]},{"a":7760,"t":"byte","b":[64,68,72,76,80,84,88,92]},{"a":7768,"t":"byte","b":[96,100,104,108,112,116,120,124]},{"a":7776,"t":"byte","b":[128,132,136,140,144,148,152,156]},{"a":7784,"t":"byte","b":[160,164,168,172,176,180,184,188]},{"a":7792,"t":"byte","b":[192,196,200,204,208,212,216,220]},{"a":7800,"t":"byte","b":[224,228,232,236,240,244,248,252]},{"a":7808,"t":"byte","b":[0,4,8,12,16,20,24,28]},{"a":7816,"t":"byte","b":[32,36,40,44,48,52,56,60]},{"a":7824,"t":"byte","b":[64,68,72,76,80,84,88,92]},{"a":7832,"t":"byte","b":[96,100,104,108,112,116,120,124]},{"a":7840,"t":"byte","b":[128,132,136,140,144,148,152,156]},{"a":7848,"t":"byte","b":[160,164,168,172,176,180,184,188]},{"a":7856,"t":"byte","b":[192,196,200,204,208,212,216,220]},{"a":7864,"t":"byte","b":[224,228,232,236,240,244,248,252]},{"a":7872,"t":"byte","b":[0,4,8,12,16,20,24,28]},{"a":7880,"t":"byte","b":[32,36,40,44,48,52,56,60]},{"a":7888,"t":"byte","b":[64,68,72,76,80,84,88,92]},{"a":7896,"t":"byte","b":[96,100,104,108,112,116,120,124]},{"a":7904,"t":"byte","b":[128,132,136,140,144,148,152,156]},{"a":7912,"t":"byte","b":[160,164,168,172,176,180,184,188]},{"a":7920,"t":"byte","b":[192,196,200,204,208,212,216,220]},{"a":7928,"t":"byte","b":[224,228,232,236,240,244,248,252]},{"a":7936,"l":"preshift_carry_7","c":"Overflow half for shift 7: entry y = (y << 1) and $FF, the index doubled with bit 7 dropped, so every value is even and only the index's top bit fails to cross into the next cell. Selected by zpa_45 = $1F, the largest sub-cell offset the blitter uses. Built at run time by $BF63-$BF98, which walks the shift count 0-7 in $008E, points $6F/$70 at $1000+256*n and $8F/$90 at $1800+256*n, and for every y runs n rounds of lsr a / ror zpa_6D so the byte that stays and the byte that spills fall out of the same shift.","t":"byte","b":[0,2,4,6,8,10,12,14]},{"a":7944,"t":"byte","b":[16,18,20,22,24,26,28,30]},{"a":7952,"t":"byte","b":[32,34,36,38,40,42,44,46]},{"a":7960,"t":"byte","b":[48,50,52,54,56,58,60,62]},{"a":7968,"t":"byte","b":[64,66,68,70,72,74,76,78]},{"a":7976,"t":"byte","b":[80,82,84,86,88,90,92,94]},{"a":7984,"t":"byte","b":[96,98,100,102,104,106,108,110]},{"a":7992,"t":"byte","b":[112,114,116,118,120,122,124,126]},{"a":8000,"t":"byte","b":[128,130,132,134,136,138,140,142]},{"a":8008,"t":"byte","b":[144,146,148,150,152,154,156,158]},{"a":8016,"t":"byte","b":[160,162,164,166,168,170,172,174]},{"a":8024,"t":"byte","b":[176,178,180,182,184,186,188,190]},{"a":8032,"t":"byte","b":[192,194,196,198,200,202,204,206]},{"a":8040,"t":"byte","b":[208,210,212,214,216,218,220,222]},{"a":8048,"t":"byte","b":[224,226,228,230,232,234,236,238]},{"a":8056,"t":"byte","b":[240,242,244,246,248,250,252,254]},{"a":8064,"t":"byte","b":[0,2,4,6,8,10,12,14]},{"a":8072,"t":"byte","b":[16,18,20,22,24,26,28,30]},{"a":8080,"t":"byte","b":[32,34,36,38,40,42,44,46]},{"a":8088,"t":"byte","b":[48,50,52,54,56,58,60,62]},{"a":8096,"t":"byte","b":[64,66,68,70,72,74,76,78]},{"a":8104,"t":"byte","b":[80,82,84,86,88,90,92,94]},{"a":8112,"t":"byte","b":[96,98,100,102,104,106,108,110]},{"a":8120,"t":"byte","b":[112,114,116,118,120,122,124,126]},{"a":8128,"t":"byte","b":[128,130,132,134,136,138,140,142]},{"a":8136,"t":"byte","b":[144,146,148,150,152,154,156,158]},{"a":8144,"t":"byte","b":[160,162,164,166,168,170,172,174]},{"a":8152,"t":"byte","b":[176,178,180,182,184,186,188,190]},{"a":8160,"t":"byte","b":[192,194,196,198,200,202,204,206]},{"a":8168,"t":"byte","b":[208,210,212,214,216,218,220,222]},{"a":8176,"t":"byte","b":[224,226,228,230,232,234,236,238]},{"a":8184,"t":"byte","b":[240,242,244,246,248,250,252,254]},{"a":8192,"t":"gap","n":12288},{"a":20480,"l":"charset_at_g","c":"Character set, 2 KB at $5000-$57FF, eight bytes per glyph. It is a byte-for-byte copy of the LOWER half of the C64 character ROM, $D000-$D7FF, the upper-case and graphics set; the copy is made once at start-up by $BFA8-$BFC9, which clears bit 2 of $01 to bring the ROM into view at $D000 first. The VIC only reads it in bank 1: the raster handler puts $04 in bits 3-1 of $D018 for the text rows, giving a character base of bank + $1000, which is $5000 in bank 1 and the ROM itself in bank 0. This first block is glyphs $00-$07: @ A B C D E F G. Letters are used by the five centred messages ($8AE1 FIRST SORTIE onward) and the title screen strings at $9B0D.","t":"byte","b":[60,102,110,110,96,98,60,0]},{"a":20488,"t":"byte","b":[24,60,102,126,102,102,102,0]},{"a":20496,"t":"byte","b":[124,102,102,124,102,102,124,0]},{"a":20504,"t":"byte","b":[60,102,96,96,96,102,60,0]},{"a":20512,"t":"byte","b":[120,108,102,102,102,108,120,0]},{"a":20520,"t":"byte","b":[126,96,96,120,96,96,126,0]},{"a":20528,"t":"byte","b":[126,96,96,120,96,96,96,0]},{"a":20536,"t":"byte","b":[60,102,96,110,102,102,60,0]},{"a":20544,"l":"charset_h_o","c":"Glyphs $08-$0F of the character set: H I J K L M N O. H, I, L, M, N and O all appear in the title strings CHOPLIFTER!, DAN GORLIN, DANE BIGHAM and in the messages MAGNIFICENT! and THE END that $8A8B prints into the mid-screen text window.","t":"byte","b":[102,102,102,126,102,102,102,0]},{"a":20552,"t":"byte","b":[60,24,24,24,24,24,60,0]},{"a":20560,"t":"byte","b":[30,12,12,12,12,108,56,0]},{"a":20568,"t":"byte","b":[102,108,120,112,120,108,102,0]},{"a":20576,"t":"byte","b":[96,96,96,96,96,96,126,0]},{"a":20584,"t":"byte","b":[99,119,127,107,99,99,99,0]},{"a":20592,"t":"byte","b":[102,118,126,126,110,102,102,0]},{"a":20600,"t":"byte","b":[60,102,102,102,102,102,60,0]},{"a":20608,"l":"charset_p_w","c":"Glyphs $10-$17 of the character set: P Q R S T U V W. P, R, S and T carry the words PRESENTS, FIRST SORTIE, SECOND SORTIE and THIRD SORTIE; the game never displays Q, V or W.","t":"byte","b":[124,102,102,124,96,96,96,0]},{"a":20616,"t":"byte","b":[60,102,102,102,102,60,14,0]},{"a":20624,"t":"byte","b":[124,102,102,124,120,108,102,0]},{"a":20632,"t":"byte","b":[60,102,96,60,6,102,60,0]},{"a":20640,"t":"byte","b":[126,24,24,24,24,24,24,0]},{"a":20648,"t":"byte","b":[102,102,102,102,102,102,60,0]},{"a":20656,"t":"byte","b":[102,102,102,102,102,60,24,0]},{"a":20664,"t":"byte","b":[99,99,99,107,127,119,99,0]},{"a":20672,"l":"charset_x_arrow","c":"Glyphs $18-$1F: X Y Z, then the four symbols that end the first quarter of the set - left bracket, pound sign, right bracket, up arrow - and the left arrow at $1F. None of these seven are used by the game; only X, Y and Z could appear, and no string contains them.","t":"byte","b":[102,102,60,24,60,102,102,0]},{"a":20680,"t":"byte","b":[102,102,102,60,24,24,24,0]},{"a":20688,"t":"byte","b":[126,6,12,24,48,96,126,0]},{"a":20696,"t":"byte","b":[60,48,48,48,48,48,60,0]},{"a":20704,"t":"byte","b":[12,18,48,124,48,98,252,0]},{"a":20712,"t":"byte","b":[60,12,12,12,12,12,60,0]},{"a":20720,"t":"byte","b":[0,24,60,126,24,24,24,24]},{"a":20728,"t":"byte","b":[0,16,48,127,127,48,16,0]},{"a":20736,"l":"charset_punct1","c":"Glyphs $20-$27: space, exclamation mark, double quote, hash, dollar, percent, ampersand, apostrophe. The space at $20 is what $98EB and $9AB2 fill the text rows with, and the exclamation mark at $21 ends CHOPLIFTER! and MAGNIFICENT!. Screen code $26 also appears in the video matrix below the text panel, but there it is a pair of colour nibbles for the multicolour bitmap, not a glyph.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":20744,"t":"byte","b":[24,24,24,24,0,0,24,0]},{"a":20752,"t":"byte","b":[102,102,102,0,0,0,0,0]},{"a":20760,"t":"byte","b":[102,102,255,102,255,102,102,0]},{"a":20768,"t":"byte","b":[24,62,96,60,6,124,24,0]},{"a":20776,"t":"byte","b":[98,102,12,24,48,102,70,0]},{"a":20784,"t":"byte","b":[60,102,60,56,103,102,63,0]},{"a":20792,"t":"byte","b":[6,12,24,0,0,0,0,0]},{"a":20800,"l":"charset_punct2","c":"Glyphs $28-$2F: open and close parentheses, asterisk, plus, comma, minus, full stop, slash. The parentheses are used by the title line (C) 1982 at $9B4D. Screen code $2E, the full stop, fills the whole of the video matrix below the text panel, but as the colour pair red/light blue for the multicolour bitmap rather than as a glyph.","t":"byte","b":[12,24,48,48,48,24,12,0]},{"a":20808,"t":"byte","b":[48,24,12,12,12,24,48,0]},{"a":20816,"t":"byte","b":[0,102,60,255,60,102,0,0]},{"a":20824,"t":"byte","b":[0,24,24,126,24,24,0,0]},{"a":20832,"t":"byte","b":[0,0,0,0,0,24,24,48]},{"a":20840,"t":"byte","b":[0,0,0,126,0,0,0,0]},{"a":20848,"t":"byte","b":[0,0,0,0,0,24,24,0]},{"a":20856,"t":"byte","b":[0,3,6,12,24,48,96,0]},{"a":20864,"l":"charset_digits_0_7","c":"Glyphs $30-$37: the digits 0 to 7. The three two-digit counters in the status panel are drawn straight out of this block - $A982 adds $30 to a nibble and $A985 stores the result into the video matrix at $0450,y and $4450,y - and the year in (C) 1982 uses 1, 8, 9 and 2.","t":"byte","b":[60,102,110,118,102,102,60,0]},{"a":20872,"t":"byte","b":[24,24,56,24,24,24,126,0]},{"a":20880,"t":"byte","b":[60,102,6,12,48,96,126,0]},{"a":20888,"t":"byte","b":[60,102,6,28,6,102,60,0]},{"a":20896,"t":"byte","b":[6,14,30,102,127,6,6,0]},{"a":20904,"t":"byte","b":[126,96,124,6,6,102,60,0]},{"a":20912,"t":"byte","b":[60,102,96,124,102,102,60,0]},{"a":20920,"t":"byte","b":[126,102,12,24,24,24,24,0]},{"a":20928,"l":"charset_digits_8_9","c":"Glyphs $38-$3F: the digits 8 and 9, then colon, semicolon, less-than, equals, greater-than and question mark. Only 8 and 9 are ever displayed; they complete the digit run the status-panel counters draw from.","t":"byte","b":[60,102,102,60,102,102,60,0]},{"a":20936,"t":"byte","b":[60,102,102,62,6,102,60,0]},{"a":20944,"t":"byte","b":[0,0,24,0,0,24,0,0]},{"a":20952,"t":"byte","b":[0,0,24,0,0,24,24,48]},{"a":20960,"t":"byte","b":[14,24,48,96,48,24,14,0]},{"a":20968,"t":"byte","b":[0,0,126,0,126,0,0,0]},{"a":20976,"t":"byte","b":[112,24,12,6,12,24,112,0]},{"a":20984,"t":"byte","b":[60,102,6,12,24,0,24,0]},{"a":20992,"l":"charset_rules_a","c":"Glyphs $40-$47, the first of the box-drawing blocks. $40 and $43 are a horizontal rule on scanlines 3-4, $44 one scanline higher (2-3), $45 higher again (1-2) and $46 one lower (4-5); $42 is a vertical rule on columns 3-4 and $47 one on columns 2-3. $41 is the spade. The status panel uses $44 for the top edge of its frame, $46 for the bottom edge, and $41 as the icon in front of the first counter, written by $BB2F to $0458 and $4458.","t":"byte","b":[0,0,0,255,255,0,0,0]},{"a":21000,"t":"byte","b":[8,28,62,127,127,28,62,0]},{"a":21008,"t":"byte","b":[24,24,24,24,24,24,24,24]},{"a":21016,"t":"byte","b":[0,0,0,255,255,0,0,0]},{"a":21024,"t":"byte","b":[0,0,255,255,0,0,0,0]},{"a":21032,"t":"byte","b":[0,255,255,0,0,0,0,0]},{"a":21040,"t":"byte","b":[0,0,0,0,255,255,0,0]},{"a":21048,"t":"byte","b":[48,48,48,48,48,48,48,48]},{"a":21056,"l":"charset_corners_a","c":"Glyphs $48-$4F: a vertical rule on columns 4-5 ($48), the rounded corners for the top right ($49), bottom left ($4A) and bottom right ($4B) of a box, the square bottom-left corner ($4C), the two diagonals ($4D falling, $4E rising) and the square top-left corner ($4F). The status panel draws $49 at the right end of its top rule and $4A and $4B at the two ends of its bottom rule.","t":"byte","b":[12,12,12,12,12,12,12,12]},{"a":21064,"t":"byte","b":[0,0,0,224,240,56,24,24]},{"a":21072,"t":"byte","b":[24,24,28,15,7,0,0,0]},{"a":21080,"t":"byte","b":[24,24,56,240,224,0,0,0]},{"a":21088,"t":"byte","b":[192,192,192,192,192,192,255,255]},{"a":21096,"t":"byte","b":[192,224,112,56,28,14,7,3]},{"a":21104,"t":"byte","b":[3,7,14,28,56,112,224,192]},{"a":21112,"t":"byte","b":[255,255,192,192,192,192,192,192]},{"a":21120,"l":"charset_misc_a","c":"Glyphs $50-$57: the square top-right corner ($50), a filled disc ($51), a thick bar on scanlines 5-6 ($52), the heart ($53), a vertical rule on columns 1-2 ($54), the rounded top-left corner ($55), a diagonal cross ($56) and a hollow circle ($57). The status panel uses $54 for the left side of its frame, $55 for the top-left corner, and $53 as the icon of the third counter, written by $BB3F to $046E and $446E.","t":"byte","b":[255,255,3,3,3,3,3,3]},{"a":21128,"t":"byte","b":[0,60,126,126,126,126,60,0]},{"a":21136,"t":"byte","b":[0,0,0,0,0,255,255,0]},{"a":21144,"t":"byte","b":[54,127,127,127,62,28,8,0]},{"a":21152,"t":"byte","b":[96,96,96,96,96,96,96,96]},{"a":21160,"t":"byte","b":[0,0,0,7,15,28,24,24]},{"a":21168,"t":"byte","b":[195,231,126,60,60,126,231,195]},{"a":21176,"t":"byte","b":[0,60,126,102,102,126,60,0]},{"a":21184,"l":"charset_misc_b","c":"Glyphs $58-$5F: the club ($58), a vertical rule on columns 5-6 ($59), the diamond ($5A), a full cross ($5B), a staggered vertical dashed line ($5C), a centred vertical rule ($5D), the pi sign ($5E) and a filled corner triangle ($5F). The panel uses $59 for the right side of its frame and $5A as the icon of the second counter, written by $BB37 to $0463 and $4463.","t":"byte","b":[24,24,102,102,24,24,60,0]},{"a":21192,"t":"byte","b":[6,6,6,6,6,6,6,6]},{"a":21200,"t":"byte","b":[8,28,62,127,62,28,8,0]},{"a":21208,"t":"byte","b":[24,24,24,255,255,24,24,24]},{"a":21216,"t":"byte","b":[192,192,48,48,192,192,48,48]},{"a":21224,"t":"byte","b":[24,24,24,24,24,24,24,24]},{"a":21232,"t":"byte","b":[0,0,3,62,118,54,54,0]},{"a":21240,"t":"byte","b":[255,127,63,31,15,7,3,1]},{"a":21248,"l":"charset_blocks_a","c":"Glyphs $60-$67: a blank cell ($60), the left half block ($61), the lower half block ($62), a rule along the very top scanline ($63) and along the very bottom ($64), the left quarter block of two columns ($65), a fine checkerboard ($66) and the right quarter block of two columns ($67). $65 and $67 are the two glyphs the status panel uses in reverse video ($E5 and $E7) to cap the ends of its red bars.","t":"byte","b":[0,0,0,0,0,0,0,0]},{"a":21256,"t":"byte","b":[240,240,240,240,240,240,240,240]},{"a":21264,"t":"byte","b":[0,0,0,0,255,255,255,255]},{"a":21272,"t":"byte","b":[255,0,0,0,0,0,0,0]},{"a":21280,"t":"byte","b":[0,0,0,0,0,0,0,255]},{"a":21288,"t":"byte","b":[192,192,192,192,192,192,192,192]},{"a":21296,"t":"byte","b":[204,204,51,51,204,204,51,51]},{"a":21304,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":21312,"l":"charset_blocks_b","c":"Glyphs $68-$6F: a checkerboard confined to the lower half ($68), a filled triangle in the upper-left corner ($69), the right quarter block ($6A), a left-hand tee ($6B), the lower-right quarter block ($6C) and three more tee and corner pieces ($6D, $6E) ending with a rule two scanlines deep along the bottom ($6F). The game displays none of them.","t":"byte","b":[0,0,0,0,204,204,51,51]},{"a":21320,"t":"byte","b":[255,254,252,248,240,224,192,128]},{"a":21328,"t":"byte","b":[3,3,3,3,3,3,3,3]},{"a":21336,"t":"byte","b":[24,24,24,31,31,24,24,24]},{"a":21344,"t":"byte","b":[0,0,0,0,15,15,15,15]},{"a":21352,"t":"byte","b":[24,24,24,31,31,0,0,0]},{"a":21360,"t":"byte","b":[0,0,0,248,248,24,24,24]},{"a":21368,"t":"byte","b":[0,0,0,0,0,0,255,255]},{"a":21376,"l":"charset_blocks_c","c":"Glyphs $70-$77: a corner piece ($70), an upward tee ($71), a downward tee ($72), a right-hand tee ($73), the two-column left block ($74), the three-column left block ($75), the three-column right block ($76) and a rule two scanlines deep along the top ($77). The game displays none of them.","t":"byte","b":[0,0,0,31,31,24,24,24]},{"a":21384,"t":"byte","b":[24,24,24,255,255,0,0,0]},{"a":21392,"t":"byte","b":[0,0,0,255,255,24,24,24]},{"a":21400,"t":"byte","b":[24,24,24,248,248,24,24,24]},{"a":21408,"t":"byte","b":[192,192,192,192,192,192,192,192]},{"a":21416,"t":"byte","b":[224,224,224,224,224,224,224,224]},{"a":21424,"t":"byte","b":[7,7,7,7,7,7,7,7]},{"a":21432,"t":"byte","b":[255,255,0,0,0,0,0,0]},{"a":21440,"l":"charset_blocks_d","c":"Glyphs $78-$7F, the last of the normal half: three-scanline rules top and bottom ($78, $79), the two-column right block ($7A) and five quarter-block and half-block shapes ($7B-$7F). The game displays none of them; $7F is the last glyph before the reversed copy of the whole set begins at $5400.","t":"byte","b":[255,255,255,0,0,0,0,0]},{"a":21448,"t":"byte","b":[0,0,0,0,0,255,255,255]},{"a":21456,"t":"byte","b":[3,3,3,3,3,3,255,255]},{"a":21464,"t":"byte","b":[0,0,0,0,240,240,240,240]},{"a":21472,"t":"byte","b":[15,15,15,15,0,0,0,0]},{"a":21480,"t":"byte","b":[24,24,24,248,248,0,0,0]},{"a":21488,"t":"byte","b":[240,240,240,240,0,0,0,0]},{"a":21496,"t":"byte","b":[240,240,240,240,15,15,15,15]},{"a":21504,"l":"charset_rev_at_g","c":"Reversed half of the character set, $5400-$57FF, glyphs $80-$FF: every byte here is the ones complement of the byte 2 KB earlier, which is how the C64 ROM stores its reverse-video images. This block is $80-$87, the reversed @ A B C D E F G. Setting bit 7 of a screen code selects these, and the game only ever uses three of them, all in the status panel.","t":"byte","b":[195,153,145,145,159,153,195,255]},{"a":21512,"t":"byte","b":[231,195,153,129,153,153,153,255]},{"a":21520,"t":"byte","b":[131,153,153,131,153,153,131,255]},{"a":21528,"t":"byte","b":[195,153,159,159,159,153,195,255]},{"a":21536,"t":"byte","b":[135,147,153,153,153,147,135,255]},{"a":21544,"t":"byte","b":[129,159,159,135,159,159,129,255]},{"a":21552,"t":"byte","b":[129,159,159,135,159,159,159,255]},{"a":21560,"t":"byte","b":[195,153,159,145,153,153,195,255]},{"a":21568,"l":"charset_rev_h_o","c":"Glyphs $88-$8F: the reversed H I J K L M N O. Nothing in the game writes a screen code in this range; the messages and title strings are all printed in normal video.","t":"byte","b":[153,153,153,129,153,153,153,255]},{"a":21576,"t":"byte","b":[195,231,231,231,231,231,195,255]},{"a":21584,"t":"byte","b":[225,243,243,243,243,147,199,255]},{"a":21592,"t":"byte","b":[153,147,135,143,135,147,153,255]},{"a":21600,"t":"byte","b":[159,159,159,159,159,159,129,255]},{"a":21608,"t":"byte","b":[156,136,128,148,156,156,156,255]},{"a":21616,"t":"byte","b":[153,137,129,129,145,153,153,255]},{"a":21624,"t":"byte","b":[195,153,153,153,153,153,195,255]},{"a":21632,"l":"charset_rev_p_w","c":"Glyphs $90-$97: the reversed P Q R S T U V W, unused by the game.","t":"byte","b":[131,153,153,131,159,159,159,255]},{"a":21640,"t":"byte","b":[195,153,153,153,153,195,241,255]},{"a":21648,"t":"byte","b":[131,153,153,131,135,147,153,255]},{"a":21656,"t":"byte","b":[195,153,159,195,249,153,195,255]},{"a":21664,"t":"byte","b":[129,231,231,231,231,231,231,255]},{"a":21672,"t":"byte","b":[153,153,153,153,153,153,195,255]},{"a":21680,"t":"byte","b":[153,153,153,153,153,195,231,255]},{"a":21688,"t":"byte","b":[156,156,156,148,128,136,156,255]},{"a":21696,"l":"charset_rev_x_arrow","c":"Glyphs $98-$9F: the reversed X Y Z, brackets, pound sign, up arrow and left arrow. Unused.","t":"byte","b":[153,153,195,231,195,153,153,255]},{"a":21704,"t":"byte","b":[153,153,153,195,231,231,231,255]},{"a":21712,"t":"byte","b":[129,249,243,231,207,159,129,255]},{"a":21720,"t":"byte","b":[195,207,207,207,207,207,195,255]},{"a":21728,"t":"byte","b":[243,237,207,131,207,157,3,255]},{"a":21736,"t":"byte","b":[195,243,243,243,243,243,195,255]},{"a":21744,"t":"byte","b":[255,231,195,129,231,231,231,231]},{"a":21752,"t":"byte","b":[255,239,207,128,128,207,239,255]},{"a":21760,"l":"charset_rev_punct1","c":"Glyphs $A0-$A7: the reversed space, exclamation mark, double quote, hash, dollar, percent, ampersand and apostrophe. $A0, the reversed space, is a solid block and is the single most visible glyph in the game: $9B6C-$9B71 fills $0451-$0476 in both video matrices with it and colours those cells red, which is what draws the three long bars of the status panel.","t":"byte","b":[255,255,255,255,255,255,255,255]},{"a":21768,"t":"byte","b":[231,231,231,231,255,255,231,255]},{"a":21776,"t":"byte","b":[153,153,153,255,255,255,255,255]},{"a":21784,"t":"byte","b":[153,153,0,153,0,153,153,255]},{"a":21792,"t":"byte","b":[231,193,159,195,249,131,231,255]},{"a":21800,"t":"byte","b":[157,153,243,231,207,153,185,255]},{"a":21808,"t":"byte","b":[195,153,195,199,152,153,192,255]},{"a":21816,"t":"byte","b":[249,243,231,255,255,255,255,255]},{"a":21824,"l":"charset_rev_punct2","c":"Glyphs $A8-$AF: the reversed parentheses, asterisk, plus, comma, minus, full stop and slash. Unused by the game; the panel bars use $A0 from the previous block.","t":"byte","b":[243,231,207,207,207,231,243,255]},{"a":21832,"t":"byte","b":[207,231,243,243,243,231,207,255]},{"a":21840,"t":"byte","b":[255,153,195,0,195,153,255,255]},{"a":21848,"t":"byte","b":[255,231,231,129,231,231,255,255]},{"a":21856,"t":"byte","b":[255,255,255,255,255,231,231,207]},{"a":21864,"t":"byte","b":[255,255,255,129,255,255,255,255]},{"a":21872,"t":"byte","b":[255,255,255,255,255,231,231,255]},{"a":21880,"t":"byte","b":[255,252,249,243,231,207,159,255]},{"a":21888,"l":"charset_rev_digits_0_7","c":"Glyphs $B0-$B7: the reversed digits 0 to 7. The status-panel counters are drawn in normal video from $5180, so these are never displayed.","t":"byte","b":[195,153,145,137,153,153,195,255]},{"a":21896,"t":"byte","b":[231,231,199,231,231,231,129,255]},{"a":21904,"t":"byte","b":[195,153,249,243,207,159,129,255]},{"a":21912,"t":"byte","b":[195,153,249,227,249,153,195,255]},{"a":21920,"t":"byte","b":[249,241,225,153,128,249,249,255]},{"a":21928,"t":"byte","b":[129,159,131,249,249,153,195,255]},{"a":21936,"t":"byte","b":[195,153,159,131,153,153,195,255]},{"a":21944,"t":"byte","b":[129,153,243,231,231,231,231,255]},{"a":21952,"l":"charset_rev_digits_8_9","c":"Glyphs $B8-$BF: the reversed digits 8 and 9 and the reversed colon, semicolon, less-than, equals, greater-than and question mark. Unused.","t":"byte","b":[195,153,153,195,153,153,195,255]},{"a":21960,"t":"byte","b":[195,153,153,193,249,153,195,255]},{"a":21968,"t":"byte","b":[255,255,231,255,255,231,255,255]},{"a":21976,"t":"byte","b":[255,255,231,255,255,231,231,207]},{"a":21984,"t":"byte","b":[241,231,207,159,207,231,241,255]},{"a":21992,"t":"byte","b":[255,255,129,255,129,255,255,255]},{"a":22000,"t":"byte","b":[143,231,243,249,243,231,143,255]},{"a":22008,"t":"byte","b":[195,153,249,243,231,255,231,255]},{"a":22016,"l":"charset_rev_rules_a","c":"Glyphs $C0-$C7: the reversed images of the horizontal and vertical rules and of the spade. A reversed rule is a solid cell with a thin gap across it; the game draws its panel frame in normal video, so none of these appear.","t":"byte","b":[255,255,255,0,0,255,255,255]},{"a":22024,"t":"byte","b":[247,227,193,128,128,227,193,255]},{"a":22032,"t":"byte","b":[231,231,231,231,231,231,231,231]},{"a":22040,"t":"byte","b":[255,255,255,0,0,255,255,255]},{"a":22048,"t":"byte","b":[255,255,0,0,255,255,255,255]},{"a":22056,"t":"byte","b":[255,0,0,255,255,255,255,255]},{"a":22064,"t":"byte","b":[255,255,255,255,0,0,255,255]},{"a":22072,"t":"byte","b":[207,207,207,207,207,207,207,207]},{"a":22080,"l":"charset_rev_corners_a","c":"Glyphs $C8-$CF: the reversed vertical rule, rounded corners, square corners and diagonals of $48-$4F. Unused by the game.","t":"byte","b":[243,243,243,243,243,243,243,243]},{"a":22088,"t":"byte","b":[255,255,255,31,15,199,231,231]},{"a":22096,"t":"byte","b":[231,231,227,240,248,255,255,255]},{"a":22104,"t":"byte","b":[231,231,199,15,31,255,255,255]},{"a":22112,"t":"byte","b":[63,63,63,63,63,63,0,0]},{"a":22120,"t":"byte","b":[63,31,143,199,227,241,248,252]},{"a":22128,"t":"byte","b":[252,248,241,227,199,143,31,63]},{"a":22136,"t":"byte","b":[0,0,63,63,63,63,63,63]},{"a":22144,"l":"charset_rev_misc_a","c":"Glyphs $D0-$D7: the reversed square corner, disc, thick bar, heart, vertical rule, rounded corner, cross and circle of $50-$57. Unused; the panel's heart icon is the normal-video $53.","t":"byte","b":[0,0,252,252,252,252,252,252]},{"a":22152,"t":"byte","b":[255,195,129,129,129,129,195,255]},{"a":22160,"t":"byte","b":[255,255,255,255,255,0,0,255]},{"a":22168,"t":"byte","b":[201,128,128,128,193,227,247,255]},{"a":22176,"t":"byte","b":[159,159,159,159,159,159,159,159]},{"a":22184,"t":"byte","b":[255,255,255,248,240,227,231,231]},{"a":22192,"t":"byte","b":[60,24,129,195,195,129,24,60]},{"a":22200,"t":"byte","b":[255,195,129,153,153,129,195,255]},{"a":22208,"l":"charset_rev_misc_b","c":"Glyphs $D8-$DF: the reversed club, vertical rules, diamond, cross, dashed line, pi and corner triangle of $58-$5F. Unused; the panel's diamond icon is the normal-video $5A.","t":"byte","b":[231,231,153,153,231,231,195,255]},{"a":22216,"t":"byte","b":[249,249,249,249,249,249,249,249]},{"a":22224,"t":"byte","b":[247,227,193,128,193,227,247,255]},{"a":22232,"t":"byte","b":[231,231,231,0,0,231,231,231]},{"a":22240,"t":"byte","b":[63,63,207,207,63,63,207,207]},{"a":22248,"t":"byte","b":[231,231,231,231,231,231,231,231]},{"a":22256,"t":"byte","b":[255,255,252,193,137,201,201,255]},{"a":22264,"t":"byte","b":[0,128,192,224,240,248,252,254]},{"a":22272,"l":"charset_rev_blocks_a","c":"Glyphs $E0-$E7: the reversed images of $60-$67. Two of them are used: $E5, the reversed two-column left block, is a cell solid except for its two leftmost columns and $BB5F-$BB76 writes it at $0451, $045B, $0466 and $0471 as the left-hand end cap of each red bar; $E7, the reversed two-column right block, is written at $0476 by $BB57 as the right-hand end cap of the last bar.","t":"byte","b":[255,255,255,255,255,255,255,255]},{"a":22280,"t":"byte","b":[15,15,15,15,15,15,15,15]},{"a":22288,"t":"byte","b":[255,255,255,255,0,0,0,0]},{"a":22296,"t":"byte","b":[0,255,255,255,255,255,255,255]},{"a":22304,"t":"byte","b":[255,255,255,255,255,255,255,0]},{"a":22312,"t":"byte","b":[63,63,63,63,63,63,63,63]},{"a":22320,"t":"byte","b":[51,51,204,204,51,51,204,204]},{"a":22328,"t":"byte","b":[252,252,252,252,252,252,252,252]},{"a":22336,"l":"charset_rev_blocks_b","c":"Glyphs $E8-$EF: the reversed checkerboard, triangles, quarter blocks and tee pieces of $68-$6F. Unused by the game.","t":"byte","b":[255,255,255,255,51,51,204,204]},{"a":22344,"t":"byte","b":[0,1,3,7,15,31,63,127]},{"a":22352,"t":"byte","b":[252,252,252,252,252,252,252,252]},{"a":22360,"t":"byte","b":[231,231,231,224,224,231,231,231]},{"a":22368,"t":"byte","b":[255,255,255,255,240,240,240,240]},{"a":22376,"t":"byte","b":[231,231,231,224,224,255,255,255]},{"a":22384,"t":"byte","b":[255,255,255,7,7,231,231,231]},{"a":22392,"t":"byte","b":[255,255,255,255,255,255,0,0]},{"a":22400,"l":"charset_rev_blocks_c","c":"Glyphs $F0-$F7: the reversed tee pieces, quarter blocks and top rule of $70-$77. Unused.","t":"byte","b":[255,255,255,224,224,231,231,231]},{"a":22408,"t":"byte","b":[231,231,231,0,0,255,255,255]},{"a":22416,"t":"byte","b":[255,255,255,0,0,231,231,231]},{"a":22424,"t":"byte","b":[231,231,231,7,7,231,231,231]},{"a":22432,"t":"byte","b":[63,63,63,63,63,63,63,63]},{"a":22440,"t":"byte","b":[31,31,31,31,31,31,31,31]},{"a":22448,"t":"byte","b":[248,248,248,248,248,248,248,248]},{"a":22456,"t":"byte","b":[0,0,255,255,255,255,255,255]},{"a":22464,"l":"charset_rev_blocks_d","c":"Glyphs $F8-$FF, the last eight of the 2 KB copy: the reversed rules and quarter blocks of $78-$7F. Unused. $57FF is the last byte the VIC can fetch as a glyph in bank 1; the bank-1 bitmap starts at $6000.","t":"byte","b":[0,0,0,255,255,255,255,255]},{"a":22472,"t":"byte","b":[255,255,255,255,255,0,0,0]},{"a":22480,"t":"byte","b":[252,252,252,252,252,252,0,0]},{"a":22488,"t":"byte","b":[255,255,255,255,15,15,15,15]},{"a":22496,"t":"byte","b":[240,240,240,240,255,255,255,255]},{"a":22504,"t":"byte","b":[231,231,231,7,7,255,255,255]},{"a":22512,"t":"byte","b":[15,15,15,15,255,255,255,255]},{"a":22520,"t":"byte","b":[15,15,15,15,240,240,240,240]},{"a":22528,"t":"gap","n":10240},{"a":32768,"l":"cbm80_header","c":"Cartridge autostart header, 9 bytes: $8000/$8001 cold start vector and $8002/$8003 warm start vector, both $9593, then the five byte CBM80 signature $C3 $C2 $CD $38 $30 that a real cartridge needs for the KERNAL to autostart it. The disk build never uses it: the loader copies $0900-$48FF up to $8000 and jumps to $959C itself.","t":"byte","b":[147,149,147,149,195,194,205,56]},{"a":32776,"t":"byte","b":[48]},{"a":32777,"l":"shape_ptr_table","c":"Shape pointer table: 75 interleaved lo/hi pointers, $8009+2*n, to the shape bitmaps at $80A1-$8A8A. A shape is width in bitmap bits, height in rows, then ceil(width/8) bytes a row, top row first; the bitmap is multicolour so two bits are one pixel and the on screen width is half the first byte. Entries 0-10 here are the helicopter side view at its eleven tilt steps, read at $AB4C/$AB52 with y=(tilt $5A+5)*2. Every other reader takes a fixed entry as its base, so the table is really a dozen small groups laid end to end.","t":"addr","b":[161,128],"oa":32929,"o":"heli_side_tilt_m5","x":[43852,43858]},{"a":32779,"t":"addr","b":[235,128],"oa":33003,"o":"heli_side_tilt_m4"},{"a":32781,"t":"addr","b":[45,129],"oa":33069,"o":"heli_side_tilt_m3"},{"a":32783,"t":"addr","b":[122,129],"oa":33146,"o":"heli_side_tilt_m2"},{"a":32785,"t":"addr","b":[194,129],"oa":33218,"o":"heli_side_tilt_m1"},{"a":32787,"t":"addr","b":[10,130],"oa":33290,"o":"heli_side_tilt_p0"},{"a":32789,"t":"addr","b":[77,130],"oa":33357,"o":"heli_side_tilt_p1"},{"a":32791,"t":"addr","b":[144,130],"oa":33424,"o":"heli_side_tilt_p2"},{"a":32793,"t":"addr","b":[211,130],"oa":33491,"o":"heli_side_tilt_p3"},{"a":32795,"t":"addr","b":[27,131],"oa":33563,"o":"heli_side_tilt_p4"},{"a":32797,"t":"addr","b":[104,131],"oa":33640,"o":"heli_side_tilt_p5"},{"a":32799,"l":"shape_ptr_heli_front","c":"Entries 11-13: the helicopter turning from head on to three quarter view. $AB69 reads this with y = |facing $59| * 2, and $59 only reaches +/-2 on that path, so entries 11, 12 and 13 are the ones it can pick; the |$59|=3 slot that follows is only reached by the fixed load at $AB34.","t":"byte","b":[186],"x":[43881]},{"a":32800,"l":"shape_ptr_heli_front_hi","c":"Shape pointer table, the high byte of entry 11 followed by entries 12 and 13, the rest of the head on to three quarter turn. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[131,214],"oa":54915,"o":"$D683","x":[43886]},{"a":32802,"t":"addr","b":[131,242],"oa":62083,"o":"$F283"},{"a":32804,"t":"byte","b":[131]},{"a":32805,"l":"shape_ptr_heli_side_short","c":"Entry 14, loaded as a fixed address at $AB34: the one row shorter side view used when the facing $59 is +/-3, the tilt $5A is zero and the half row flag $60 is set.","t":"byte","b":[40],"x":[43828]},{"a":32806,"l":"shape_ptr_heli_side_short_hi","c":"Shape pointer table, the high byte of entry 14, the short side view. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"byte","b":[132],"x":[43833]},{"a":32807,"l":"shape_ptr_heli_front_short","c":"Entry 15, loaded as a fixed address at $AB23: the one row shorter head on view used when the facing $59 is zero, the tilt $5A is zero and the half row flag $60 is set.","t":"byte","b":[102],"x":[43811]},{"a":32808,"l":"shape_ptr_heli_front_short_hi","c":"Shape pointer table, the high byte of entry 15, the short head on view. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"byte","b":[132],"x":[43816]},{"a":32809,"l":"shape_ptr_rotor_disc","c":"Entries 16-18, the three main rotor bars. $AC30 indexes this with $0B61, which holds 4, 2 or 0 and counts down by two before reloading at 4, so the disc cycles widest, middle, shortest. $0B61 is forced back to 4 whenever $62 is non zero.","t":"addr","b":[128,132],"oa":33920,"o":"rotor_disc_short","x":[44083,44089]},{"a":32811,"t":"addr","b":[133,132],"oa":33925,"o":"rotor_disc_mid"},{"a":32813,"t":"addr","b":[140,132],"oa":33932,"o":"rotor_disc_long"},{"a":32815,"l":"shape_ptr_tail_rotor","c":"Entries 19-22, the four tail rotor blades. $AC90 indexes this with $0B62, which holds 6, 4, 2 or 0 and counts down by two before reloading at 6. $AC4A only runs at all when the facing $59 is +/-3, so the tail rotor is drawn in the full side view only.","t":"byte","b":[147],"x":[44179]},{"a":32816,"l":"shape_ptr_jet","c":"Shape pointer table, the high byte of entry 19 then entries 20 to 40: the rest of the tail rotor blades, the jet's sixteen frames 23 to 38 (the four groups start at entries 23, 24, 31 and 36, which is what the pointers at $AFCC name), and the tank's two body shapes 39 and 40. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[132,155],"oa":39812,"o":"$9B84","x":[44184]},{"a":32818,"t":"addr","b":[132,163],"oa":41860,"o":"$A384"},{"a":32820,"t":"addr","b":[132,169],"oa":43396,"o":"$A984"},{"a":32822,"t":"addr","b":[132,178],"oa":45700,"o":"$B284"},{"a":32824,"t":"addr","b":[132,195],"oa":50052,"o":"$C384"},{"a":32826,"t":"addr","b":[132,241],"oa":61828,"o":"$F184"},{"a":32828,"t":"addr","b":[132,26],"oa":6788,"o":"$1A84"},{"a":32830,"t":"addr","b":[133,73],"oa":18821,"o":"$4985"},{"a":32832,"t":"addr","b":[133,107],"oa":27525,"o":"$6B85"},{"a":32834,"t":"addr","b":[133,160],"oa":41093,"o":"$A085"},{"a":32836,"t":"addr","b":[133,226],"oa":57989,"o":"$E285"},{"a":32838,"t":"addr","b":[133,36],"oa":9349,"o":"$2485"},{"a":32840,"t":"addr","b":[134,71],"oa":18310,"o":"$4786"},{"a":32842,"t":"addr","b":[134,115],"oa":29574,"o":"$7386"},{"a":32844,"t":"addr","b":[134,157],"oa":40326,"o":"$9D86"},{"a":32846,"t":"addr","b":[134,199],"oa":51078,"o":"$C786"},{"a":32848,"t":"addr","b":[134,0],"oa":134,"o":"zpa_86"},{"a":32850,"t":"addr","b":[135,92],"oa":23687,"o":"$5C87"},{"a":32852,"t":"addr","b":[135,154],"oa":39559,"o":"$9A87"},{"a":32854,"t":"addr","b":[135,208],"oa":53383,"o":"$D087"},{"a":32856,"t":"addr","b":[135,216],"oa":55431,"o":"$D887"},{"a":32858,"t":"byte","b":[135]},{"a":32859,"l":"shape_ptr_tank_gun","c":"Entries 41-45, the tank gun barrel at five angles. The type 3 handler reads it at $A111 with y = $0B77,x * 2, and pairs each angle with a horizontal offset from $A244 = 11, 7, 1, -1, -5, so the barrel swings from left of the hull to right of it.","t":"byte","b":[242],"x":[41233]},{"a":32860,"l":"shape_ptr_shots","c":"Shape pointer table, the high byte of entry 41 then entries 42 to 50: the rest of the tank gun angles, the four projectile shapes 46 to 49 that actor types 6, 8, 4 and 5 draw, and the type 10 body at entry 50. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[135,249],"oa":63879,"o":"$F987","x":[41238]},{"a":32862,"t":"addr","b":[135,255],"oa":65415,"o":"s_FF87"},{"a":32864,"t":"addr","b":[135,5],"oa":1415,"o":"$0587"},{"a":32866,"t":"addr","b":[136,11],"oa":2952,"o":"$0B88"},{"a":32868,"t":"addr","b":[136,18],"oa":4744,"o":"$1288"},{"a":32870,"t":"addr","b":[136,23],"oa":6024,"o":"$1788"},{"a":32872,"t":"addr","b":[136,28],"oa":7304,"o":"$1C88"},{"a":32874,"t":"addr","b":[136,36],"oa":9352,"o":"$2488"},{"a":32876,"t":"addr","b":[136,39],"oa":10120,"o":"$2788"},{"a":32878,"t":"byte","b":[136]},{"a":32879,"l":"shape_ptr_blast","c":"Entries 51-54, the four explosion frames. The type 1 and type 2 handler at $B106 steps through them with $0B75,x, removing the actor after frame 3; $B055 in the player helicopter chain picks one of the same four at random ($A933 masked with 3).","t":"byte","b":[61],"x":[45152,45331]},{"a":32880,"l":"shape_ptr_blast_hi","c":"Shape pointer table, the high byte of entry 51 then entries 52, 53 and 54, the rest of the four explosion frames. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[136,90],"oa":23176,"o":"$5A88","x":[45157,45336]},{"a":32882,"t":"addr","b":[136,128],"oa":32904,"o":"$8088"},{"a":32884,"t":"addr","b":[136,166],"oa":42632,"o":"$A688"},{"a":32886,"t":"byte","b":[136]},{"a":32887,"l":"shape_ptr_man_run","c":"Entries 55-58, the running hostage. $9D84 reads it with y = $0CA0,x * 2 when the hostage state $0CA1,x is odd ($01 or $FF, the two directions).","t":"byte","b":[192],"x":[40329]},{"a":32888,"l":"shape_ptr_man_run_hi","c":"Shape pointer table, the high byte of entry 55 then entries 56, 57 and 58, the rest of the running hostage. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[136,216],"oa":55432,"o":"$D888","x":[40334]},{"a":32890,"t":"addr","b":[136,240],"oa":61576,"o":"$F088"},{"a":32892,"t":"addr","b":[136,8],"oa":2184,"o":"$0888"},{"a":32894,"t":"byte","b":[137]},{"a":32895,"l":"shape_ptr_man_wave","c":"Entries 59-61, the standing hostage waving. $9D64 reads it when the hostage state $0CA1,x is zero, with the index ((v*2 EOR $FF) AND v) * 2 for v = $0CA0,x, which yields 59, 60, 61, 60 for v = 0..3 so the arm swings out and back.","t":"byte","b":[32],"x":[40303]},{"a":32896,"l":"shape_ptr_man_wave_hi","c":"Shape pointer table, the high byte of entry 59 then entries 60 and 61, the rest of the waving hostage. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[137,56],"oa":14473,"o":"$3889","x":[40308]},{"a":32898,"t":"addr","b":[137,80],"oa":20617,"o":"$5089"},{"a":32900,"t":"byte","b":[137]},{"a":32901,"l":"shape_ptr_man_board","c":"Entries 62-63, the hostage climbing aboard. $9D9E reads it with y = $0CA0,x AND 2, so each pose is held for two steps; the sequence is entered by writing $FE or $02 to $0CA1,x at $9CD8/$9D04 and ends at $9DC4 by marking the slot done with $0CA0,x = $FF.","t":"byte","b":[104],"x":[40356]},{"a":32902,"l":"shape_ptr_scenery","c":"Shape pointer table, the high byte of entry 62 then entries 63 to 67: the second boarding pose, the background hill, the base building, the base wedge and the flagpole. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[137,128],"oa":32905,"o":"$8089","x":[40361]},{"a":32904,"t":"addr","b":[137,148],"oa":38025,"o":"$9489","x":[32882]},{"a":32906,"t":"addr","b":[137,170],"oa":43657,"o":"$AA89"},{"a":32908,"t":"addr","b":[137,216],"oa":55433,"o":"$D889"},{"a":32910,"t":"addr","b":[137,228],"oa":58505,"o":"$E489"},{"a":32912,"t":"byte","b":[137]},{"a":32913,"l":"shape_ptr_flag","c":"Entries 68-69, the two flag frames. $BB07 picks between them on bit 0 of the frame counter $89, so the flag on the base flagpole ripples every other frame.","t":"byte","b":[242],"x":[47885]},{"a":32914,"l":"shape_ptr_flag_hi","c":"Shape pointer table, the high byte of entry 68 then entry 69, the second flag frame, and entry 70, the four times repeated parallax blob. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[137,4],"oa":1161,"o":"$0489","x":[47890]},{"a":32916,"t":"addr","b":[138,22],"oa":5770,"o":"$168A"},{"a":32918,"t":"byte","b":[138]},{"a":32919,"l":"shape_ptr_hut","c":"Entries 71-72, the shed with its doors shut and open. $B8EA reads it with x = $0CF4,n * 2 for each of the four sheds n = 0..3; $B652 sets $0CF4,n to 1 when a shed is opened.","t":"byte","b":[29],"x":[47346]},{"a":32920,"l":"shape_ptr_hut_hi","c":"Shape pointer table, the high byte of entry 71 then entries 72, 73 and 74: the open shed, the shed plinth and the doorway scatter. Pointers are interleaved lo/hi, so an odd address like this is the top half of one entry; the readers that start here all take a fixed base address and index from it.","t":"addr","b":[138,75],"oa":19338,"o":"$4B8A","x":[47351]},{"a":32922,"t":"addr","b":[138,121],"oa":31114,"o":"$798A"},{"a":32924,"t":"addr","b":[138,131],"oa":33674,"o":"$838A"},{"a":32926,"t":"byte","b":[138]},{"a":32927,"l":"shape_table_pad","c":"Two zero bytes between the end of the pointer table at $809E and the first shape bitmap at $80A1. Nothing in $8000-$BFFF refers to them and they are not a valid shape (a zero width, zero height entry); they read as padding, or as an unused 76th table slot left at zero.","t":"byte","b":[0,0]},{"a":32929,"l":"heli_side_tilt_m5","c":"Player helicopter, full side view, 16x18 px, tail end 7 rows above the nose, the steepest nose down attitude in the set. Shape 0 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt -5 to the right and tilt +5 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[32,18,64,0,0,0,224,0],"x":[32777]},{"a":32937,"t":"byte","b":[64,0,224,0,248,0,240,27]},{"a":32945,"t":"byte","b":[248,0,252,31,248,0,127,143]},{"a":32953,"t":"byte","b":[252,0,63,255,255,0,15,255]},{"a":32961,"t":"byte","b":[252,224,3,255,252,24,0,127]},{"a":32969,"t":"byte","b":[248,4,7,111,254,4,7,225]},{"a":32977,"t":"byte","b":[255,130,1,252,255,242,0,63]},{"a":32985,"t":"byte","b":[199,255,0,7,240,254,0,0]},{"a":32993,"l":"heli_side_tilt_m5_rows","c":"Tail of shape 0 (heli_side_tilt_m5): the last 10 bytes of its bitmap, which is 4 bytes a row for 18 rows, so this covers row 15 part way through to row 17. Split off only because the shape is longer than a single span.","t":"byte","b":[254,0,0,0,31,252,0,0]},{"a":33001,"t":"byte","b":[3,224]},{"a":33003,"l":"heli_side_tilt_m4","c":"Player helicopter, full side view, 16x16 px, tail 6 rows above the nose; one row shorter than tilt -5 and the tail boom less hooked. Shape 1 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt -4 to the right and tilt +4 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[32,16,64,0,64,0,224,0],"x":[32779]},{"a":33011,"t":"byte","b":[248,0,224,27,248,0,240,31]},{"a":33019,"t":"byte","b":[248,0,255,15,252,0,127,255]},{"a":33027,"t":"byte","b":[255,128,31,255,252,120,3,255]},{"a":33035,"t":"byte","b":[252,12,0,255,252,4,0,111]},{"a":33043,"t":"byte","b":[255,2,3,224,255,243,3,254]},{"a":33051,"t":"byte","b":[111,255,0,63,224,248,0,3]},{"a":33059,"t":"byte","b":[254,0,0,0,63,254,0,0]},{"a":33067,"l":"heli_side_tilt_m4_rows","c":"Tail of shape 1 (heli_side_tilt_m4): the last 2 bytes of its bitmap, which is 4 bytes a row for 16 rows, so this covers row 15 part way through to row 15. Split off only because the shape is longer than a single span.","t":"byte","b":[3,240]},{"a":33069,"l":"heli_side_tilt_m3","c":"Player helicopter, full side view, 16x15 px, tail 5 rows above the nose; the cabin roof is flat where tilt -4 still slopes. Shape 2 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt -3 to the right and tilt +3 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[33,15,64,0,112,0,0,224],"x":[32781]},{"a":33077,"t":"byte","b":[0,252,0,0,224,27,252,0]},{"a":33085,"t":"byte","b":[0,240,31,254,0,0,127,135]},{"a":33093,"t":"byte","b":[255,192,0,127,255,254,124,0]},{"a":33101,"t":"byte","b":[31,255,254,6,0,3,255,254]},{"a":33109,"t":"byte","b":[2,0,0,127,255,129,0,0]},{"a":33117,"t":"byte","b":[51,255,253,128,3,240,63,255]},{"a":33125,"t":"byte","b":[128,3,255,176,124,0,0,31]},{"a":33133,"l":"heli_side_tilt_m3_rows","c":"Tail of shape 2 (heli_side_tilt_m3): the last 13 bytes of its bitmap, which is 5 bytes a row for 15 rows, so this covers row 12 part way through to row 14. Split off only because the shape is longer than a single span.","t":"byte","b":[252,1,0,0,0,255,231,0]},{"a":33141,"t":"byte","b":[0,0,7,252,0]},{"a":33146,"l":"heli_side_tilt_m2","c":"Player helicopter, full side view, 17x14 px, tail 4 rows above the nose; first frame of the set that is 17 pixels long. Shape 3 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt -2 to the right and tilt +2 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[34,14,0,0,124,0,0,64],"x":[32783]},{"a":33154,"t":"byte","b":[1,252,0,0,224,15,254,0]},{"a":33162,"t":"byte","b":[0,240,15,255,192,0,127,3]},{"a":33170,"t":"byte","b":[254,126,0,127,255,254,3,0]},{"a":33178,"t":"byte","b":[31,255,254,1,0,3,255,255]},{"a":33186,"t":"byte","b":[193,128,0,63,255,255,192,0]},{"a":33194,"t":"byte","b":[25,255,255,192,1,248,24,254]},{"a":33202,"t":"byte","b":[0,1,255,248,0,128,0,15]},{"a":33210,"l":"heli_side_tilt_m2_rows","c":"Tail of shape 3 (heli_side_tilt_m2): the last 8 bytes of its bitmap, which is 5 bytes a row for 14 rows, so this covers row 12 part way through to row 13. Split off only because the shape is longer than a single span.","t":"byte","b":[255,251,128,0,0,3,254,0]},{"a":33218,"l":"heli_side_tilt_m1","c":"Player helicopter, full side view, 17x14 px, tail 4 rows above the nose but the mass sits one row lower than tilt -2. Shape 4 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt -1 to the right and tilt +1 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[35,14,0,0,60,0,0,0],"x":[32785]},{"a":33226,"t":"byte","b":[0,124,0,0,64,1,252,0]},{"a":33234,"t":"byte","b":[0,224,15,255,0,0,240,15]},{"a":33242,"t":"byte","b":[255,255,0,127,131,255,1,128]},{"a":33250,"t":"byte","b":[63,255,255,0,192,31,255,255]},{"a":33258,"t":"byte","b":[128,96,1,255,255,255,224,0]},{"a":33266,"t":"byte","b":[31,255,255,128,0,6,7,254]},{"a":33274,"t":"byte","b":[0,0,255,254,0,96,0,255]},{"a":33282,"l":"heli_side_tilt_m1_rows","c":"Tail of shape 4 (heli_side_tilt_m1): the last 8 bytes of its bitmap, which is 5 bytes a row for 14 rows, so this covers row 12 part way through to row 13. Split off only because the shape is longer than a single span.","t":"byte","b":[255,255,192,0,0,3,255,128]},{"a":33290,"l":"heli_side_tilt_p0","c":"Player helicopter, full side view, 17x13 px, tail 2 rows above the nose, the shape used while the helicopter hovers. Shape 5 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt +0 to the right and tilt +0 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[35,13,0,1,240,0,0,0],"x":[32787]},{"a":33298,"t":"byte","b":[1,240,0,0,0,3,248,0]},{"a":33306,"t":"byte","b":[0,64,15,255,255,0,224,15]},{"a":33314,"t":"byte","b":[255,1,128,240,3,255,0,192]},{"a":33322,"t":"byte","b":[127,255,255,128,96,63,255,255]},{"a":33330,"t":"byte","b":[255,224,31,255,255,255,128,1]},{"a":33338,"t":"byte","b":[255,255,254,0,0,6,6,0]},{"a":33346,"t":"byte","b":[96,0,127,255,255,192,0,127]},{"a":33354,"l":"heli_side_tilt_p0_rows","c":"Tail of shape 5 (heli_side_tilt_p0): the last 3 bytes of its bitmap, which is 5 bytes a row for 13 rows, so this covers row 12 part way through to row 12. Split off only because the shape is longer than a single span.","t":"byte","b":[255,255,128]},{"a":33357,"l":"heli_side_tilt_p1","c":"Player helicopter, full side view, 17x13 px, level: the tail and the nose sit on the same row. Shape 6 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt +1 to the right and tilt -1 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[35,13,0,1,240,0,0,0],"x":[32789]},{"a":33365,"t":"byte","b":[1,248,0,0,0,3,253,255]},{"a":33373,"t":"byte","b":[0,0,15,255,1,128,64,15]},{"a":33381,"t":"byte","b":[255,0,192,224,3,255,128,96]},{"a":33389,"t":"byte","b":[248,127,255,255,224,127,255,255]},{"a":33397,"t":"byte","b":[255,128,63,255,255,254,0,7]},{"a":33405,"t":"byte","b":[255,254,0,96,0,6,6,255]},{"a":33413,"t":"byte","b":[192,0,63,255,255,128,0,63]},{"a":33421,"l":"heli_side_tilt_p1_rows","c":"Tail of shape 6 (heli_side_tilt_p1): the last 3 bytes of its bitmap, which is 5 bytes a row for 13 rows, so this covers row 12 part way through to row 12. Split off only because the shape is longer than a single span.","t":"byte","b":[255,0,0]},{"a":33424,"l":"heli_side_tilt_p2","c":"Player helicopter, full side view, 17x13 px, nose 1 row above the tail, the first nose up frame. Shape 7 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt +2 to the right and tilt -2 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[35,13,0,1,240,0,0,0],"x":[32791]},{"a":33432,"t":"byte","b":[1,248,124,0,0,3,255,227]},{"a":33440,"t":"byte","b":[0,0,15,254,0,192,0,15]},{"a":33448,"t":"byte","b":[255,0,96,64,3,255,143,192]},{"a":33456,"t":"byte","b":[240,63,255,255,128,255,255,255]},{"a":33464,"t":"byte","b":[254,0,127,255,255,0,96,31]},{"a":33472,"t":"byte","b":[255,3,127,192,0,3,127,255]},{"a":33480,"t":"byte","b":[0,0,63,255,0,0,0,63]},{"a":33488,"l":"heli_side_tilt_p2_rows","c":"Tail of shape 7 (heli_side_tilt_p2): the last 3 bytes of its bitmap, which is 5 bytes a row for 13 rows, so this covers row 12 part way through to row 12. Split off only because the shape is longer than a single span.","t":"byte","b":[0,0,0]},{"a":33491,"l":"heli_side_tilt_p3","c":"Player helicopter, full side view, 17x14 px, nose 3 rows above the tail. Shape 8 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt +3 to the right and tilt -3 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[34,14,0,0,64,0,0,0],"x":[32793]},{"a":33499,"t":"byte","b":[3,224,62,0,0,3,255,225]},{"a":33507,"t":"byte","b":[128,0,3,254,0,64,0,15]},{"a":33515,"t":"byte","b":[255,0,192,0,31,255,159,128]},{"a":33523,"t":"byte","b":[64,27,255,255,0,224,15,255]},{"a":33531,"t":"byte","b":[252,64,252,127,255,192,192,127]},{"a":33539,"t":"byte","b":[255,251,31,128,31,255,131,254]},{"a":33547,"t":"byte","b":[0,3,129,255,224,0,0,63]},{"a":33555,"l":"heli_side_tilt_p3_rows","c":"Tail of shape 8 (heli_side_tilt_p3): the last 8 bytes of its bitmap, which is 5 bytes a row for 14 rows, so this covers row 12 part way through to row 13. Split off only because the shape is longer than a single span.","t":"byte","b":[252,0,0,0,31,128,0,0]},{"a":33563,"l":"heli_side_tilt_p4","c":"Player helicopter, full side view, 17x15 px, nose 4 rows above the tail. Shape 9 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt +4 to the right and tilt -4 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[35,15,0,0,192,28,0,0],"x":[32795]},{"a":33571,"t":"byte","b":[7,225,227,128,0,7,254,0]},{"a":33579,"t":"byte","b":[64,0,7,255,0,192,0,15]},{"a":33587,"t":"byte","b":[255,143,128,0,31,255,255,0]},{"a":33595,"t":"byte","b":[0,27,255,254,32,64,7,255]},{"a":33603,"t":"byte","b":[248,96,240,63,255,131,192,127]},{"a":33611,"t":"byte","b":[255,249,191,128,63,255,195,252]},{"a":33619,"t":"byte","b":[0,7,248,255,192,0,0,3]},{"a":33627,"l":"heli_side_tilt_p4_rows","c":"Tail of shape 9 (heli_side_tilt_p4): the last 13 bytes of its bitmap, which is 5 bytes a row for 15 rows, so this covers row 12 part way through to row 14. Split off only because the shape is longer than a single span.","t":"byte","b":[252,0,0,0,31,192,0,0]},{"a":33635,"t":"byte","b":[0,12,0,0,0]},{"a":33640,"l":"heli_side_tilt_p5","c":"Player helicopter, full side view, 17x16 px, nose 5 rows above the tail, the steepest nose up attitude in the set. Shape 10 of the eleven pitch frames 0-10; $AB45 picks it with index $6F+5, and $AAC2 sets $6F to the tilt $5A facing right or -$5A facing left, so this frame is tilt +5 to the right and tilt -5 to the left. One set of frames serves both directions: the whole body is blitted by $8FD3 facing right and by the mirroring $903E facing left, with no shear applied. Reached only when the facing $59 is +/-3. The rotor bar (shapes 16-18) and the tail rotor (shapes 19-22) are stamped on separately.","t":"byte","b":[34,16,0,0,0,56,0,0],"x":[32797]},{"a":33648,"t":"byte","b":[1,193,199,0,0,15,238,0]},{"a":33656,"t":"byte","b":[128,0,7,254,1,128,0,7]},{"a":33664,"t":"byte","b":[255,15,0,0,15,255,254,0]},{"a":33672,"t":"byte","b":[0,31,255,252,64,0,27,255]},{"a":33680,"t":"byte","b":[248,192,0,7,255,195,128,64]},{"a":33688,"t":"byte","b":[31,255,159,128,240,255,241,252]},{"a":33696,"t":"byte","b":[0,127,255,199,224,0,63,252]},{"a":33704,"l":"heli_side_tilt_p5_rows","c":"Tail of shape 10 (heli_side_tilt_p5): the last 18 bytes of its bitmap, which is 5 bytes a row for 16 rows, so this covers row 12 part way through to row 15. Split off only because the shape is longer than a single span.","t":"byte","b":[255,0,0,7,193,248,0,0]},{"a":33712,"t":"byte","b":[0,15,192,0,0,0,6,0]},{"a":33720,"t":"byte","b":[0,0]},{"a":33722,"l":"heli_front_0","c":"Player helicopter head on, 6x13 px: mast, wide canopy and both skids with daylight under the belly. Narrowest of the turn set; $AB69 picks it when the facing $59 is 0, the attitude the helicopter holds while it faces the viewer. Drawn through $90D2 with the shear from $8C30, and with a vertical nudge from the 11x5 table at $927E.","t":"byte","b":[12,13,15,0,15,0,15,0]},{"a":33730,"t":"byte","b":[63,192,96,96,64,32,192,48]},{"a":33738,"t":"byte","b":[255,240,127,224,31,128,112,224]},{"a":33746,"t":"byte","b":[224,112,224,112]},{"a":33750,"l":"heli_front_1","c":"Player helicopter one step off head on, 6x13 px. Same silhouette as shape 11 but the canopy and the skid feet are pushed one column to the left, so the body reads as rotated. $AB69 picks it when the facing $59 is +/-1. This path goes through the shearing blitter $90D2 (or $90DF facing left) with the shear set from the tilt at $AB75 through $8C30, so the drawn outline leans even though the bitmap does not.","t":"byte","b":[12,13,15,0,15,0,15,0]},{"a":33758,"t":"byte","b":[223,192,248,96,112,32,112,16]},{"a":33766,"t":"byte","b":[63,240,63,224,31,128,57,224]},{"a":33774,"t":"byte","b":[240,240,240,240]},{"a":33778,"l":"heli_front_2","c":"Player helicopter at three quarter view, 13x13 px: the tail boom has swung out of the body and reaches seven pixels to the right, and the skids are still under the cabin. $AB69 picks it when the facing $59 is +/-2, the last step before the full side view, and like shape 12 it is drawn through the shearing blitter with the shear taken from the tilt at $AB75.","t":"byte","b":[26,13,0,31,0,0,0,31]},{"a":33786,"t":"byte","b":[0,0,128,63,128,0,96,127]},{"a":33794,"t":"byte","b":[254,0,112,127,131,0,120,63]},{"a":33802,"t":"byte","b":[1,128,63,255,0,192,31,255]},{"a":33810,"t":"byte","b":[255,192,15,255,255,128,3,255]},{"a":33818,"t":"byte","b":[254,0,0,112,118,192,1,255]},{"a":33826,"t":"byte","b":[255,128,1,255,255,0]},{"a":33832,"l":"heli_side_short","c":"Player helicopter, level side view, 17x12 px: the same drawing as shape 5 made one row shorter, and redrawn rather than trimmed. Rows 0-8 are byte for byte shape 5's; row 9 then gains the skid pixels from the row below it ($01 FF FF FE 60 against shape 5's $01 FF FF FE 00), shape 5's row of daylight between the skids ($00 06 06 00 60) is gone, and the last two rows are shape 5's last two. No single row deletion reproduces it. $AB34 loads it from the fixed entry at $8025 when the facing $59 is +/-3, the tilt $5A is zero and the half row flag $60 is set, which is the frame on which the body has been moved down one row at $A50B.","t":"byte","b":[35,12,0,1,240,0,0,0]},{"a":33840,"t":"byte","b":[1,240,0,0,0,3,248,0]},{"a":33848,"t":"byte","b":[0,64,15,255,255,0,224,15]},{"a":33856,"t":"byte","b":[255,1,128,240,3,255,0,192]},{"a":33864,"t":"byte","b":[127,255,255,128,96,63,255,255]},{"a":33872,"t":"byte","b":[255,224,31,255,255,255,128,1]},{"a":33880,"t":"byte","b":[255,255,254,96,0,127,255,255]},{"a":33888,"t":"byte","b":[192,0,127,255,255,128]},{"a":33894,"l":"heli_front_short","c":"Player helicopter head on, 6x12 px: shape 11 one row shorter, with the undercarriage redrawn rather than a row removed. Rows 0-8 match shape 11 exactly, then shape 11's four leg rows $1F 80, $70 E0, $E0 70, $E0 70 become three, $7F E0, $F0 F0, $E0 70, so the skids come out shorter and thicker instead of simply losing a row. $AB23 loads it from the fixed entry at $8027 on the same condition as shape 14, but with the facing $59 at zero.","t":"byte","b":[12,12,15,0,15,0,15,0]},{"a":33902,"t":"byte","b":[63,192,96,96,64,32,192,48]},{"a":33910,"t":"byte","b":[255,240,127,224,127,224,240,240]},{"a":33918,"t":"byte","b":[224,112]},{"a":33920,"l":"rotor_disc_short","c":"Main rotor bar, 11x1 px: one light pixel then a ten pixel bar. Shortest of the three; drawn when $0B61 has counted down to 0. $ABCD places it from the hub offset table $92B5 (indexed by tilt and facing) plus the per tilt correction at $934F, sets the shear from the tilt $5A at $AC16 and blits with $90D2, so the one row bar leans with the hull.","t":"byte","b":[23,1,7,255,254],"x":[32809]},{"a":33925,"l":"rotor_disc_mid","c":"Main rotor bar, 16x1 px, drawn when $0B61 is 2: the middle width of the three step blur, the blade part way through its sweep.","t":"byte","b":[33,1,0,1,255,255,128],"x":[32811]},{"a":33932,"l":"rotor_disc_long","c":"Main rotor bar, 19x1 px of solid colour, the widest of the three and the blade fully broadside. Drawn when $0B61 is 4, which is also the value forced at $AC2B whenever $62 is non zero.","t":"byte","b":[38,1,255,255,255,255,252],"x":[32813]},{"a":33939,"l":"tail_rotor_a","c":"Tail rotor blade, 3x6 px: two lit pixels stepping down to the left from the top right corner. Drawn when $0B62 is 0, the last step of the four frame spin.","t":"byte","b":[7,6,0,4,8,0,32,64]},{"a":33947,"l":"tail_rotor_b","c":"Tail rotor blade, 3x6 px, the mirror of shape 19: pixels stepping down to the right from the top left corner. Drawn when $0B62 is 2.","t":"byte","b":[6,6,0,64,32,0,8,4]},{"a":33955,"l":"tail_rotor_flat","c":"Tail rotor blade seen broadside, 3x4 px: a single three pixel horizontal bar on the bottom row. Drawn when $0B62 is 4.","t":"byte","b":[7,4,0,0,0,238]},{"a":33961,"l":"tail_rotor_edge","c":"Tail rotor blade seen edge on, 2x7 px: a one pixel vertical column with a gap in the middle row, the hub. Drawn when $0B62 is 6, the first step of the spin, from the offsets at $9365 when the helicopter faces right or $937B when it faces left.","t":"byte","b":[4,7,16,16,16,0,16,16]},{"a":33969,"t":"byte","b":[16]},{"a":33970,"l":"jet_cruise","c":"Enemy jet in level cruise, 10x5 px: a short fuselage with the wing bar only five rows deep, the most foreshortened wingspan in the set. The whole of actor type 9 state 0 is this one shape: the step list at $94E3 holds a single record, dx +8 and no vertical movement, so the jet crosses the screen at constant speed. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[21,5,128,0,0,160,2,160]},{"a":33978,"t":"byte","b":[170,170,168,106,250,128,106,128]},{"a":33986,"t":"byte","b":[0]},{"a":33987,"l":"jet_turn_0","c":"Enemy jet part way through a reversal, 12x11 px: fuselage 12 px long with the wing bar 11 rows deep. Frame 0 of the seven shapes 24-30 that actor type 9 uses in state 1; the fuselage shortens to shape 27 and lengthens again while the wingspan grows, which is how the turn through the viewer is drawn. Used by records 0-4 of the 18 step list at $94E7, dx +6 to +7. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[25,11,0,224,0,0,0,160]},{"a":33995,"t":"byte","b":[0,0,0,168,42,0,32,42]},{"a":34003,"t":"byte","b":[130,128,40,170,170,0,170,170]},{"a":34011,"t":"byte","b":[160,0,106,170,0,0,106,10]},{"a":34019,"t":"byte","b":[0,0,40,10,0,0,40,10]},{"a":34027,"t":"byte","b":[0,0,0,7,0,0]},{"a":34033,"l":"jet_turn_1","c":"Enemy jet part way through a reversal, 11x13 px: fuselage shortened to 11 px while the wing bar deepens to 13 rows. Frame 1 of the seven shapes 24-30 that actor type 9 uses in state 1; the fuselage shortens to shape 27 and lengthens again while the wingspan grows, which is how the turn through the viewer is drawn. Used by records 5-8, the fastest part of the manoeuvre at dx +8 to +9. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[23,13,3,128,0,2,128,0]},{"a":34041,"t":"byte","b":[2,160,0,0,160,168,0,170]},{"a":34049,"t":"byte","b":[10,130,170,40,170,170,160,170]},{"a":34057,"t":"byte","b":[170,0,170,168,0,104,40,0]},{"a":34065,"t":"byte","b":[40,40,0,32,40,0,0,28]},{"a":34073,"t":"byte","b":[0]},{"a":34074,"l":"jet_turn_2","c":"Enemy jet part way through a reversal, 8x15 px: fuselage down to 8 px, wing bar 15 rows. Frame 2 of the seven shapes 24-30 that actor type 9 uses in state 1; the fuselage shortens to shape 27 and lengthens again while the wingspan grows, which is how the turn through the viewer is drawn. Used by records 9-11, dx falling +8, +8, +5. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[17,15,3,128,0,2,128,0]},{"a":34082,"t":"byte","b":[2,128,0,2,128,0,2,128]},{"a":34090,"t":"byte","b":[0,34,170,0,42,130,128,42]},{"a":34098,"t":"byte","b":[130,128,170,170,0,42,160,0]},{"a":34106,"t":"byte","b":[32,160,0,32,160,0,0,160]},{"a":34114,"t":"byte","b":[0,0,160,0,0,224,0]},{"a":34121,"l":"jet_turn_3","c":"Enemy jet part way through a reversal, 7x16 px: the narrowest frame in the whole set, a 7 px fuselage with a hole in the middle for the canopy and a 16 row wing bar. Frame 3 of the seven shapes 24-30 that actor type 9 uses in state 1; the fuselage shortens to shape 27 and lengthens again while the wingspan grows, which is how the turn through the viewer is drawn. Used by the single record 12, where dx bottoms out at +2. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[15,16,0,224,0,160,0,160]},{"a":34129,"t":"byte","b":[0,160,8,160,10,160,2,168]},{"a":34137,"t":"byte","b":[42,138,2,138,10,168,8,160]},{"a":34145,"t":"byte","b":[0,160,0,160,0,160,0,160]},{"a":34153,"t":"byte","b":[0,224]},{"a":34155,"l":"jet_turn_4","c":"Enemy jet part way through a reversal, 8x17 px: fuselage back out to 8 px with the deepest wing bar of the group, 17 rows. Frame 4 of the seven shapes 24-30 that actor type 9 uses in state 1; the fuselage shortens to shape 27 and lengthens again while the wingspan grows, which is how the turn through the viewer is drawn. Used by records 13-14, the first backwards steps at dx -4 and -8. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[17,17,0,192,0,0,160,0]},{"a":34163,"t":"byte","b":[0,160,0,0,160,0,0,160]},{"a":34171,"t":"byte","b":[128,0,162,128,0,170,0,10]},{"a":34179,"t":"byte","b":[171,0,42,187,0,170,234,0]},{"a":34187,"t":"byte","b":[42,170,128,0,160,128,0,160]},{"a":34195,"t":"byte","b":[0,0,160,0,0,160,0,0]},{"a":34203,"t":"byte","b":[160,0,0,96,0]},{"a":34208,"l":"jet_turn_5","c":"Enemy jet part way through a reversal, 12x16 px: fuselage 12 px with a 16 row wing bar and light tips top and bottom. Frame 5 of the seven shapes 24-30 that actor type 9 uses in state 1; the fuselage shortens to shape 27 and lengthens again while the wingspan grows, which is how the turn through the viewer is drawn. Used by the single record 15, dx -10. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[25,16,0,31,0,0,0,10]},{"a":34216,"t":"byte","b":[0,0,0,10,0,0,0,10]},{"a":34224,"t":"byte","b":[0,0,0,42,0,128,0,42]},{"a":34232,"t":"byte","b":[2,128,10,170,170,0,42,170]},{"a":34240,"t":"byte","b":[171,0,170,191,171,0,42,170]},{"a":34248,"t":"byte","b":[170,0,0,42,2,128,0,42]},{"a":34256,"t":"byte","b":[0,128,0,42,0,0,0,10]},{"a":34264,"t":"byte","b":[0,0,0,10,0,0,0,31]},{"a":34272,"l":"jet_turn_5_rows","c":"Tail of shape 29 (jet_turn_5): the last 2 bytes of its bitmap, which is 4 bytes a row for 16 rows, so this covers row 15 part way through to row 15. Split off only because the shape is longer than a single span.","t":"byte","b":[0,0]},{"a":34274,"l":"jet_turn_6","c":"Enemy jet part way through a reversal, 15x16 px: fuselage back to 15 px, the widest of the group, with a 16 row wing bar. Frame 6 of the seven shapes 24-30 that actor type 9 uses in state 1; the fuselage shortens to shape 27 and lengthens again while the wingspan grows, which is how the turn through the viewer is drawn. Used by records 16-17, dx -12, the jet now crossing the other way. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[31,16,0,1,240,0,0,0]},{"a":34282,"t":"byte","b":[160,0,0,0,160,0,0,2]},{"a":34290,"t":"byte","b":[160,0,0,2,160,2,0,2]},{"a":34298,"t":"byte","b":[160,10,0,170,170,168,42,170]},{"a":34306,"t":"byte","b":[170,172,170,171,250,172,42,170]},{"a":34314,"t":"byte","b":[170,172,0,170,170,168,0,2]},{"a":34322,"t":"byte","b":[160,10,0,2,160,2,0,0]},{"a":34330,"t":"byte","b":[160,0,0,0,160,0,0,1]},{"a":34338,"l":"jet_turn_6_rows","c":"Tail of shape 30 (jet_turn_6): the last 2 bytes of its bitmap, which is 4 bytes a row for 16 rows, so this covers row 15 part way through to row 15. Split off only because the shape is longer than a single span.","t":"byte","b":[240,0]},{"a":34340,"l":"jet_roll_0","c":"Enemy jet rolling out, 10x11 px: a stubby 10 px fuselage with an 11 row wing bar. Frame 0 of the five shapes 31-35 that actor type 9 uses in state 2, where the wingspan shrinks as the fuselage lengthens. Used by records 0-6 of the 15 step list at $952F, dx decaying +4, +4, +3, +2, +1, +1, +1. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[21,11,0,240,0,0,160,0]},{"a":34348,"t":"byte","b":[128,160,0,160,168,0,42,170]},{"a":34356,"t":"byte","b":[160,106,170,8,42,170,160,160]},{"a":34364,"t":"byte","b":[168,0,128,160,0,0,160,0]},{"a":34372,"t":"byte","b":[0,240,0]},{"a":34375,"l":"jet_roll_1","c":"Enemy jet rolling out, 11x14 px: 11 px fuselage, the deepest wing bar of the group at 14 rows, and a dark spot in the nose. Frame 1 of the five shapes 31-35 that actor type 9 uses in state 2, where the wingspan shrinks as the fuselage lengthens. Used by records 7-11, dx building back up +1, +1, +1, +2, +3. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[23,14,0,240,0,0,160,0]},{"a":34383,"t":"byte","b":[0,160,0,128,168,0,160,168]},{"a":34391,"t":"byte","b":[0,42,170,160,106,170,136,106]},{"a":34399,"t":"byte","b":[170,138,42,170,168,160,168,0]},{"a":34407,"t":"byte","b":[128,168,0,0,160,0,0,160]},{"a":34415,"t":"byte","b":[0,0,240,0]},{"a":34419,"l":"jet_roll_2","c":"Enemy jet rolling out, 14x10 px: a longer 14 px fuselage with the wing bar down to 10 rows. Frame 2 of the five shapes 31-35 that actor type 9 uses in state 2, where the wingspan shrinks as the fuselage lengthens. Used by the single record 12, dx +5. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[29,10,0,60,0,0,128,40]},{"a":34427,"t":"byte","b":[0,0,160,42,0,0,170,170]},{"a":34435,"t":"byte","b":[170,128,170,170,160,160,106,170]},{"a":34443,"t":"byte","b":[170,168,106,170,170,128,160,42]},{"a":34451,"t":"byte","b":[0,0,128,42,0,0,0,62]},{"a":34459,"t":"byte","b":[0,0]},{"a":34461,"l":"jet_roll_3","c":"Enemy jet rolling out, 16x8 px: 16 px long and only 8 rows deep, the flattest frame in the set, with two bands of colour along the body. Frame 3 of the five shapes 31-35 that actor type 9 uses in state 2, where the wingspan shrinks as the fuselage lengthens. Used by the single record 13, dx +8. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[33,8,128,0,0,0,0,160]},{"a":34469,"t":"byte","b":[0,0,0,0,168,0,2,160]},{"a":34477,"t":"byte","b":[0,170,170,168,10,0,170,170]},{"a":34485,"t":"byte","b":[170,170,128,106,175,234,170,0]},{"a":34493,"t":"byte","b":[106,170,170,128,0,106,15,240]},{"a":34501,"t":"byte","b":[0,0]},{"a":34503,"l":"jet_roll_4","c":"Enemy jet rolling out, 17x11 px: the full 17 px fuselage with an 11 row wing bar. Frame 4 of the five shapes 31-35 that actor type 9 uses in state 2, where the wingspan shrinks as the fuselage lengthens. Used by the single record 14, dx +11, the jet back up to speed. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[35,11,0,7,224,0,0,128]},{"a":34511,"t":"byte","b":[2,160,0,0,160,2,168,0]},{"a":34519,"t":"byte","b":[0,170,170,170,168,0,170,170]},{"a":34527,"t":"byte","b":[170,170,128,106,170,170,170,160]},{"a":34535,"t":"byte","b":[106,170,170,170,128,106,175,250]},{"a":34543,"t":"byte","b":[128,0,168,2,160,0,0,160]},{"a":34551,"t":"byte","b":[2,128,0,0,0,7,192,0]},{"a":34559,"t":"byte","b":[0]},{"a":34560,"l":"jet_pass_0","c":"Enemy jet at full speed, 17x18 px: the biggest shape in the whole table: a 17 px fuselage with the wing bar spread across all 18 rows. Frame 0 of the three shapes 36-38 that actor type 9 uses in states 3 and 4, which share the one step list; state 3 is also the state in which $AF5B spawns the pair of type 4 missiles. Used by records 0-4 of the 10 step list at $956B, dx +12. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[35,18,0,7,224,0,0,0]},{"a":34568,"t":"byte","b":[2,128,0,0,0,2,128,0]},{"a":34576,"t":"byte","b":[0,0,2,160,0,0,128,2]},{"a":34584,"t":"byte","b":[160,0,0,160,2,168,0,0]},{"a":34592,"t":"byte","b":[168,2,168,0,0,42,170,170]},{"a":34600,"t":"byte","b":[160,0,106,170,170,170,128,106]},{"a":34608,"t":"byte","b":[170,170,170,160,106,175,250,170]},{"a":34616,"t":"byte","b":[128,42,170,170,160,0,168,2]},{"a":34624,"l":"jet_pass_0_rows","c":"Tail of shape 36 (jet_pass_0): the last 28 bytes of its bitmap, which is 5 bytes a row for 18 rows, so this covers row 12 part way through to row 17. Split off only because the shape is longer than a single span.","t":"byte","b":[168,0,0,160,2,160,0,0]},{"a":34632,"t":"byte","b":[128,2,160,0,0,0,2,128]},{"a":34640,"t":"byte","b":[0,0,0,2,128,0,0,0]},{"a":34648,"t":"byte","b":[7,224,0,0]},{"a":34652,"l":"jet_pass_1","c":"Enemy jet at full speed, 14x15 px: 14 px fuselage and a 15 row wing bar, one step in from shape 36. Frame 1 of the three shapes 36-38 that actor type 9 uses in states 3 and 4, which share the one step list; state 3 is also the state in which $AF5B spawns the pair of type 4 missiles. Used by records 5-8, dx +12 rising to +13. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[29,15,0,124,0,0,0,40]},{"a":34660,"t":"byte","b":[0,0,0,40,0,0,0,42]},{"a":34668,"t":"byte","b":[0,0,128,42,0,0,160,42]},{"a":34676,"t":"byte","b":[128,0,42,170,170,128,106,170]},{"a":34684,"t":"byte","b":[170,160,106,170,170,168,42,191]},{"a":34692,"t":"byte","b":[170,128,160,42,128,0,128,42]},{"a":34700,"t":"byte","b":[0,0,0,40,0,0,0,40]},{"a":34708,"t":"byte","b":[0,0,0,124,0,0]},{"a":34714,"l":"jet_pass_2","c":"Enemy jet at full speed, 13x13 px: 13 px fuselage and a 13 row wing bar, the shallowest of the three. Frame 2 of the three shapes 36-38 that actor type 9 uses in states 3 and 4, which share the one step list; state 3 is also the state in which $AF5B spawns the pair of type 4 missiles. Used by the single record 9, dx +13. Enemy jet, drawn by the actor type 9 handler at $AD8F. The handler takes the shape address from one of the four sub tables named by $AFCC ($8037, $8039, $8047, $8051, all pointers into the shape table), chosen by the actor state $0B75, and the frame number from byte 0 of a four byte step record; $0B76 walks the record list. ","t":"byte","b":[27,13,0,124,0,0,0,40]},{"a":34722,"t":"byte","b":[0,0,0,40,0,0,128,42]},{"a":34730,"t":"byte","b":[0,0,160,42,42,0,42,170]},{"a":34738,"t":"byte","b":[170,128,106,170,170,160,106,175]},{"a":34746,"t":"byte","b":[170,0,42,250,128,0,160,42]},{"a":34754,"t":"byte","b":[0,0,128,42,0,0,0,40]},{"a":34762,"t":"byte","b":[0,0,0,60,0,0]},{"a":34768,"l":"tank_hull","c":"Tank hull, 7x3 px of solid colour, the block that sits on the tracks. The actor type 3 handler at $A0BB draws it second, from the fixed table entry at $8057, offset 7 px left of the actor X and 3 rows above the tracks.","t":"byte","b":[15,3,42,168,170,170,170,170]},{"a":34776,"l":"tank_tracks","c":"Tank body and tracks, 15x6 px: a pale hull with alternating coloured blocks along the top and bottom edges for the track links. The actor type 3 handler at $A0BB draws it first, from the fixed table entry at $8059, offset 15 px left of the actor X, and it is the widest part of the tank.","t":"byte","b":[31,6,55,119,119,112,170,170]},{"a":34784,"t":"byte","b":[170,174,234,170,170,170,170,170]},{"a":34792,"t":"byte","b":[170,174,234,170,170,170,29,221]},{"a":34800,"t":"byte","b":[221,216]},{"a":34802,"l":"tank_gun_0","c":"Tank gun barrel at elevation 0 of 5, 3x5 px: the shallowest left lean, the tip two columns left of the base over five rows. $A111 reads it from the table entry at $805B with y = $0B77,x * 2, and $A123 pairs it with the horizontal offset 11 from $A244, drawn 7 rows above the hull.","t":"byte","b":[7,5,0,160,168,42,10]},{"a":34809,"l":"tank_gun_1","c":"Tank gun barrel at elevation 1 of 5, 3x4 px: a steeper left lean, the same one column shift packed into four rows. $A111 reads it from the table entry at $805B with y = $0B77,x * 2, and $A123 pairs it with the horizontal offset 7 from $A244, drawn 7 rows above the hull.","t":"byte","b":[7,4,160,168,40,42]},{"a":34815,"l":"tank_gun_2","c":"Tank gun barrel at elevation 2 of 5, 1x4 px: dead vertical, a single pixel column four rows tall. $A111 reads it from the table entry at $805B with y = $0B77,x * 2, and $A123 pairs it with the horizontal offset 1 from $A244, drawn 7 rows above the hull.","t":"byte","b":[3,4,160,160,160,160]},{"a":34821,"l":"tank_gun_3","c":"Tank gun barrel at elevation 3 of 5, 3x4 px: a right lean, the tip one column right of the base over four rows. $A111 reads it from the table entry at $805B with y = $0B77,x * 2, and $A123 pairs it with the horizontal offset -1 from $A244, drawn 7 rows above the hull.","t":"byte","b":[7,4,10,42,40,168]},{"a":34827,"l":"tank_gun_4","c":"Tank gun barrel at elevation 4 of 5, 3x5 px: the furthest right lean, the tip two columns right of the base over five rows. $A111 reads it from the table entry at $805B with y = $0B77,x * 2, and $A123 pairs it with the horizontal offset -5 from $A244, drawn 7 rows above the hull.","t":"byte","b":[7,5,0,10,42,168,160]},{"a":34834,"l":"shot_heli","c":"Player helicopter shot, 2x3 px: a bright pixel pair between two dimmer ones. The actor type 6 handler at $B16E draws it from the fixed table entry at $8065, one pixel left and one row above the actor position. Type 6 is created at $B016 in the player's own handler chain, which also increments $0CF3, and the handler decrements $0CF3 again when the shot is removed.","t":"byte","b":[4,3,96,240,96]},{"a":34839,"l":"shot_falling","c":"Small falling shot, 1x3 px: a single column, bright in the middle. The actor type 8 handler at $B26D draws it from the fixed table entry at $8067 at the actor position exactly, and removes the actor as soon as its row $0B7A reaches zero, so this one travels down. Type 8 is created at $A2D3 and at $B84C, each time from another actor's position.","t":"byte","b":[3,3,64,224,64]},{"a":34844,"l":"missile_jet","c":"Jet missile, 5x3 px: a five pixel horizontal bar with a bright block through the middle, a cross on its side. The actor type 4 handler at $B221 draws it from the fixed table entry at $8069, mirrored through $903E when $0B75 is negative so it points the way it flies, and removes it at row $A0 or below row 3. $B665 creates two type 4 actors at once at the jet's position when a type 9 jet is in state 3.","t":"byte","b":[11,3,16,0,215,224,16,0]},{"a":34852,"l":"shell_jet","c":"Small shell, 4x1 px: a single row of four bright pixels. The actor type 5 handler at $B1E8 draws it from the fixed table entry at $806B and removes the actor once its row $0B7A reaches $A0, the top of the play area, so this one travels up. $B6ED creates one type 5 actor from the jet handler whenever the jet is not in state 3.","t":"byte","b":[8,1,255]},{"a":34855,"l":"drone_body","c":"6x10 px rounded body with a solid upper half and three short vertical slots below it. The only shape the actor type 10 handler at $B73D draws, from the fixed table entry at $806D; it alternates $8FD3 and $903E on bit 0 of $89 so the body flips left to right every frame, cycles $0B77 through 0, 1, 2 and feeds $A7C7 with $F0 or $FF. Type 10 is created at $A050, only while the player's world X high byte $56 is within 2 of $11.","t":"byte","b":[13,10,128,8,64,16,37,32]},{"a":34863,"t":"byte","b":[21,64,53,96,85,80,17,16]},{"a":34871,"t":"byte","b":[17,16,85,80,21,64]},{"a":34877,"l":"blast_0","c":"Explosion frame 0 of 4, 10x9 px: a dense speckled cloud, almost solid across the middle rows. The actor type 1 and type 2 handler at $B106 reads it from the table entry at $806F with y = $0B75,x * 2, steps $0B75 on by one each frame and removes the actor when it reaches 4. Type 1 is drawn four rows higher than type 2 ($B12E). $B055 draws one of the four at random, chosen with $A933 masked to 3, in the player helicopter chain.","t":"byte","b":[20,9,1,80,0,13,115,64]},{"a":34885,"t":"byte","b":[23,69,96,81,20,64,117,214]},{"a":34893,"t":"byte","b":[80,145,81,80,77,77,0,20]},{"a":34901,"t":"byte","b":[84,128,1,20,0]},{"a":34906,"l":"blast_1","c":"Explosion frame 1 of 4, 12x12 px: grown to 12x12 with the centre blown out into a ring. The actor type 1 and type 2 handler at $B106 reads it from the table entry at $806F with y = $0B75,x * 2, steps $0B75 on by one each frame and removes the actor when it reaches 4. Type 1 is drawn four rows higher than type 2 ($B12E). $B055 draws one of the four at random, chosen with $A933 masked to 3, in the player helicopter chain.","t":"byte","b":[24,12,3,126,0,7,215,96]},{"a":34914,"t":"byte","b":[60,65,44,49,132,30,241,87]},{"a":34922,"t":"byte","b":[76,100,113,6,196,83,75,64]},{"a":34930,"t":"byte","b":[116,14,96,1,24,55,149,224]},{"a":34938,"t":"byte","b":[14,127,96,0,56,0]},{"a":34944,"l":"blast_2","c":"Explosion frame 2 of 4, 12x12 px: the same 12x12 box but broken up: isolated pixels with wide gaps, the ring gone. The actor type 1 and type 2 handler at $B106 reads it from the table entry at $806F with y = $0B75,x * 2, steps $0B75 on by one each frame and removes the actor when it reaches 4. Type 1 is drawn four rows higher than type 2 ($B12E). $B055 draws one of the four at random, chosen with $A933 masked to 3, in the player helicopter chain.","t":"byte","b":[24,12,1,140,0,1,152,144]},{"a":34952,"t":"byte","b":[16,0,16,96,24,0,0,130]},{"a":34960,"t":"byte","b":[3,12,0,66,193,16,3,65]},{"a":34968,"t":"byte","b":[3,0,96,16,12,0,0,72]},{"a":34976,"t":"byte","b":[6,68,192,1,4,0]},{"a":34982,"l":"blast_3","c":"Explosion frame 3 of 4, 9x8 px: down to a scatter of eleven lit pixels, the last of the smoke. The actor type 1 and type 2 handler at $B106 reads it from the table entry at $806F with y = $0B75,x * 2, steps $0B75 on by one each frame and removes the actor when it reaches 4. Type 1 is drawn four rows higher than type 2 ($B12E). $B055 draws one of the four at random, chosen with $A933 masked to 3, in the player helicopter chain.","t":"byte","b":[19,8,48,134,0,0,0,0]},{"a":34990,"t":"byte","b":[8,8,0,0,0,64,192,64]},{"a":34998,"t":"byte","b":[0,0,0,0,16,1,128,0]},{"a":35006,"t":"byte","b":[192,0]},{"a":35008,"l":"man_run_0","c":"Hostage running, frame 0 of 4, 4x11 px: leaning forward with the near arm out to the left and the legs splayed, the trailing foot two columns right of the body. $9D89 reads it from the table entry at $8077 with y = $0CA0,x * 2, on the path taken when the state $0CA1,x is odd; $01 and $FF are the two directions of travel. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,4,0,14,0,14,0]},{"a":35016,"t":"byte","b":[60,0,78,0,153,128,24,0]},{"a":35024,"t":"byte","b":[28,0,246,0,2,0,2,0]},{"a":35032,"l":"man_run_1","c":"Hostage running, frame 1 of 4, 4x11 px: upright, the legs closed into a single column and the near arm reaching right. $9D89 reads it from the table entry at $8077 with y = $0CA0,x * 2, on the path taken when the state $0CA1,x is odd; $01 and $FF are the two directions of travel. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,8,0,28,0,28,0]},{"a":35040,"t":"byte","b":[24,0,56,0,120,0,54,0]},{"a":35048,"t":"byte","b":[56,0,56,0,120,0,24,0]},{"a":35056,"l":"man_run_2","c":"Hostage running, frame 2 of 4, 4x11 px: upright again but one pixel wider, both arms forward and the legs still closed. $9D89 reads it from the table entry at $8077 with y = $0CA0,x * 2, on the path taken when the state $0CA1,x is odd; $01 and $FF are the two directions of travel. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,8,0,28,0,28,0]},{"a":35064,"t":"byte","b":[24,0,56,0,124,0,123,0]},{"a":35072,"t":"byte","b":[60,0,60,0,120,0,48,0]},{"a":35080,"l":"man_run_3","c":"Hostage running, frame 3 of 4, 4x11 px: the widest stride: the arms thrown across the top three rows and the feet apart at the bottom. $9D89 reads it from the table entry at $8077 with y = $0CA0,x * 2, on the path taken when the state $0CA1,x is odd; $01 and $FF are the two directions of travel. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,4,0,14,0,14,0]},{"a":35088,"t":"byte","b":[252,0,143,128,24,0,24,0]},{"a":35096,"t":"byte","b":[62,0,118,0,226,0,128,0]},{"a":35104,"l":"man_wave_0","c":"Hostage standing and waving, frame 0 of 3, 4x11 px: the arm split to both sides of the head, fully raised. The body and legs of shapes 59, 60 and 61 are identical from row 4 down; only the top four rows differ, so the whole animation is the arm. $9D64 reads it from the table entry at $807F when the state $0CA1,x is zero, and its index arithmetic ((v*2 EOR $FF) AND v)*2 yields 59, 60, 61, 60 for step v = 0 to 3, so the arm swings out and back. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,136,0,220,0,156,0]},{"a":35112,"t":"byte","b":[200,0,126,0,29,0,29,128]},{"a":35120,"t":"byte","b":[28,0,28,0,28,0,54,0]},{"a":35128,"l":"man_wave_1","c":"Hostage standing and waving, frame 1 of 3, 4x11 px: the arm swung to the left of the head. The body and legs of shapes 59, 60 and 61 are identical from row 4 down; only the top four rows differ, so the whole animation is the arm. $9D64 reads it from the table entry at $807F when the state $0CA1,x is zero, and its index arithmetic ((v*2 EOR $FF) AND v)*2 yields 59, 60, 61, 60 for step v = 0 to 3, so the arm swings out and back. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,72,0,124,0,92,0]},{"a":35136,"t":"byte","b":[104,0,62,0,29,0,29,128]},{"a":35144,"t":"byte","b":[28,0,28,0,28,0,54,0]},{"a":35152,"l":"man_wave_2","c":"Hostage standing and waving, frame 2 of 3, 4x11 px: the arm tucked in beside the head, its lowest position. The body and legs of shapes 59, 60 and 61 are identical from row 4 down; only the top four rows differ, so the whole animation is the arm. $9D64 reads it from the table entry at $807F when the state $0CA1,x is zero, and its index arithmetic ((v*2 EOR $FF) AND v)*2 yields 59, 60, 61, 60 for step v = 0 to 3, so the arm swings out and back. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,24,0,28,0,60,0]},{"a":35160,"t":"byte","b":[120,0,62,0,29,0,29,128]},{"a":35168,"t":"byte","b":[28,0,28,0,28,0,54,0]},{"a":35176,"l":"man_board_0","c":"Hostage climbing aboard, first pose, 4x11 px: the whole figure shifted one column right compared with the standing shapes, leaning towards the helicopter with the arm up. $9D9E reads it from the table entry at $8085 with y = $0CA0,x AND 2, so it is held for steps 0 and 1. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,11,2,0,7,0,6,0]},{"a":35184,"t":"byte","b":[15,128,15,128,24,0,30,0]},{"a":35192,"t":"byte","b":[27,0,24,0,24,0,24,0]},{"a":35200,"l":"man_board_1","c":"Hostage climbing aboard, second pose, 4x9 px: two rows shorter and nearly empty, only the head and one shoulder left, the rest of the figure already inside. Held for steps 2 and 3, after which $9DC4 writes $FF to $0CA0,x to retire the slot. The sequence is entered by writing $FE or $02 to $0CA1,x at $9CD8 or $9D04, which happens when the hostage is within about eight pixels of the helicopter and fewer than sixteen are aboard ($0CF1 below $10); $9D18 then bumps $0CF1 and drops $0CF0. Hostages are drawn by $9D56, which walks the sixteen four byte records at $0CA0: $0CA0,x is the animation step, $0CA1,x the state, $0CA2/$0CA3,x the world X. $9DDA places them on the ground at row $58+$0B. ","t":"byte","b":[9,9,0,0,0,0,0,0]},{"a":35208,"t":"byte","b":[1,128,3,128,7,128,7,0]},{"a":35216,"t":"byte","b":[3,128,4,0]},{"a":35220,"l":"bg_hill","c":"Background hill, 18x4 px: two solid rows of ground with a low ridge and two small peaks above them. $AA67 draws it up to three times across the world, stepping the X high byte so the copies are 256 world pixels apart, all at row $1D, and skips the copy while its counter $6E is below 4.","t":"byte","b":[37,4,0,7,3,0,0,3]},{"a":35228,"t":"byte","b":[30,142,167,0,26,170,170,170]},{"a":35236,"t":"byte","b":[160,170,170,170,170,168]},{"a":35242,"l":"base_building","c":"Home base building, 13x11 px: a filled block framed top and bottom, with two dark rectangular openings side by side in the middle. $BA3F draws it twice from the table entry at $808B, at base X + $48 and again 26 pixels further right where the second copy is mirrored by $903E, both at row $22, so the two halves face each other.","t":"byte","b":[27,11,31,255,255,224,127,255]},{"a":35250,"t":"byte","b":[255,224,85,85,85,64,85,85]},{"a":35258,"t":"byte","b":[85,64,95,247,253,0,80,20]},{"a":35266,"t":"byte","b":[5,0,80,20,5,0,95,247]},{"a":35274,"t":"byte","b":[253,0,85,85,85,0,85,85]},{"a":35282,"t":"byte","b":[85,0,127,255,255,224]},{"a":35288,"l":"base_wedge","c":"Base end wedge, 7x5 px: a solid right triangle whose hypotenuse falls from the top left to the bottom right. $BA3F draws it twice from the table entry at $808D at row $19, mirrored at base X - 1 and unmirrored at base X + $7F, which puts one at each end of the base.","t":"byte","b":[15,5,86,0,85,128,85,96]},{"a":35296,"t":"byte","b":[85,88,85,86]},{"a":35300,"l":"flagpole","c":"Flagpole, 1x12 px: a single pixel column twelve rows tall. $BAEE draws it from the table entry at $808F at base X + $71, row $2E, which is above the base building, and the flag is then drawn two pixels to its right.","t":"byte","b":[2,12,192,192,192,192,192,192]},{"a":35308,"t":"byte","b":[192,192,192,192,192,192]},{"a":35314,"l":"flag_a","c":"Flag, 5x8 px, first ripple: the solid block at the top left is two pixels wide on row 0 and the chequer below it starts on an even column. $BB0D reads it from the table entry at $8091 when bit 0 of the frame counter $89 is clear.","t":"byte","b":[11,8,66,32,86,224,87,160]},{"a":35322,"t":"byte","b":[222,224,187,160,238,224,187,160]},{"a":35330,"t":"byte","b":[168,128]},{"a":35332,"l":"flag_b","c":"Flag, 5x8 px, second ripple: the top block is three pixels wide and the chequer is shifted one column against shape 68, which is the whole of the animation. Read from $8091 when bit 0 of $89 is set, so the flag alternates every frame.","t":"byte","b":[11,8,80,128,87,160,86,224]},{"a":35340,"t":"byte","b":[119,160,238,224,187,160,238,224]},{"a":35348,"t":"byte","b":[162,32]},{"a":35350,"l":"parallax_blob","c":"3x5 px solid blob. $B971 draws four copies of it from the table entry at $8095, at rows $1C, $1A, $17 and $10, with X taken from $0B6C, $0B6E, $0B70 and $0B72; those are the distance from the fixed world point $1174 halved three times, twice, once and not at all, so the four copies scroll at an eighth, a quarter, a half and full rate. What the artwork is meant to be is not established; the routine only runs while the view high byte $76 is within one of $11.","t":"byte","b":[7,5,198,124,124,108,108]},{"a":35357,"l":"hut_shut","c":"Shed with its doors shut, 13x11 px: an arched roof over a lower half that is solid apart from a two pixel seam down the middle. $B8F2 reads it from the table entry at $8097 when $0CF4,n is zero, for each of the four sheds n = 0 to 3, at row $24.","t":"byte","b":[27,11,80,63,128,0,80,234]},{"a":35365,"t":"byte","b":[224,0,83,160,184,0,30,160]},{"a":35373,"t":"byte","b":[174,0,58,160,171,128,234,168]},{"a":35381,"t":"byte","b":[170,224,170,160,170,160,170,160]},{"a":35389,"t":"byte","b":[170,160,170,255,170,160,171,187]},{"a":35397,"t":"byte","b":[170,160,174,187,170,160]},{"a":35403,"l":"hut_open","c":"Shed with its doors open, 13x11 px: the same roof as shape 71 for the top five rows, then the lower six rows hollowed out to background so the inside shows through. Read from $8097 when $0CF4,n is 1, which $B652 sets when that shed is opened.","t":"byte","b":[27,11,80,63,128,0,80,234]},{"a":35411,"t":"byte","b":[224,0,83,160,184,0,30,160]},{"a":35419,"t":"byte","b":[174,0,58,160,171,128,234,32]},{"a":35427,"t":"byte","b":[202,224,171,0,26,160,168,0]},{"a":35435,"t":"byte","b":[2,160,174,0,14,160,168,0]},{"a":35443,"t":"byte","b":[2,160,172,0,6,160]},{"a":35449,"l":"hut_plinth","c":"Shed plinth, 13x2 px of solid colour the same width as the shed. $B915 draws it from the table entry at $809B at row $19, directly below each shed, after the shed itself.","t":"byte","b":[27,2,255,255,255,224,255,255]},{"a":35457,"t":"byte","b":[255,224]},{"a":35459,"l":"hut_door_figures","c":"7x3 px scatter of lit pixels drawn inside the open doorway. $B94A draws it from the table entry at $809D six pixels right of the shed and at row $1C, only when $0CF4,n is non zero, and alternates $8FD3 and $903E on bit 0 of $89 so it flickers left to right every frame.","t":"byte","b":[15,3,36,192,52,80,77,84]},{"a":35467,"l":"msg_show","c":"Puts one of the five between-sortie captions on screen. A = caption number 0-4; doubled, it indexes the pointer table at $8AD7 to a length-prefixed screen-code string. Blanks character rows 10 and 11 of both screen matrices (80 bytes of $20 at $0590 and $4590), then copies the string's bytes into row 11 ($05B8/$45B8) starting at column 20 - length/2, so it is centred. Leaves the string's high byte ($8A or $8B) in zpa_02 ($02): the raster handler adds $02 to zpa_93 at $9A85 and, when the sum is non-zero, sets the next raster compare to $81 instead of $E0, which makes $99A8 drop out of bitmap and multicolour mode for character rows 10-11 and show them as text from character base VIC bank + $1000. Called from $9630 with the sortie counter $0CFF (FIRST/SECOND/THIRD SORTIE) and from $96EA with 3 or 4.","t":"code","b":[10],"m":"asl","o":"a","x":[38448,38634]},{"a":35468,"t":"code","b":[170],"m":"tax"},{"a":35469,"t":"code","b":[189,215,138],"m":"lda","oa":35543,"o":"msg_ptrs,x"},{"a":35472,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":35474,"t":"code","b":[189,216,138],"m":"lda","oa":35544,"o":"msg_ptrs_hi,x"},{"a":35477,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":35479,"t":"code","b":[133,2],"m":"sta","oa":2,"o":"msg_showing"},{"a":35481,"t":"code","b":[169,32],"m":"lda","o":"#$20"},{"a":35483,"t":"code","b":[162,79],"m":"ldx","o":"#$4F"},{"a":35485,"l":"b_8A9D","t":"code","b":[157,144,5],"m":"sta","oa":1424,"o":"f_0590,x","x":[35492]},{"a":35488,"t":"code","b":[157,144,69],"m":"sta","oa":17808,"o":"f_4590,x"},{"a":35491,"t":"code","b":[202],"m":"dex"},{"a":35492,"t":"code","b":[16,247],"m":"bpl","oa":35485,"o":"b_8A9D"},{"a":35494,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":35496,"t":"code","b":[177,6],"m":"lda","oa":6,"o":"(bmp_ptr),y"},{"a":35498,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":35499,"t":"code","b":[133,20],"m":"sta","oa":20,"o":"zpa_14"},{"a":35501,"t":"code","b":[169,20],"m":"lda","o":"#$14"},{"a":35503,"t":"code","b":[56],"m":"sec"},{"a":35504,"t":"code","b":[229,20],"m":"sbc","oa":20,"o":"zpa_14"},{"a":35506,"t":"code","b":[170],"m":"tax"},{"a":35507,"t":"code","b":[177,6],"m":"lda","oa":6,"o":"(bmp_ptr),y"},{"a":35509,"t":"code","b":[133,20],"m":"sta","oa":20,"o":"zpa_14"},{"a":35511,"t":"code","b":[200],"m":"iny"},{"a":35512,"l":"b_8AB8","t":"code","b":[177,6],"m":"lda","oa":6,"o":"(bmp_ptr),y","x":[35524]},{"a":35514,"t":"code","b":[157,184,5],"m":"sta","oa":1464,"o":"f_05B8,x"},{"a":35517,"t":"code","b":[157,184,69],"m":"sta","oa":17848,"o":"f_45B8,x"},{"a":35520,"t":"code","b":[200],"m":"iny"},{"a":35521,"t":"code","b":[232],"m":"inx"},{"a":35522,"t":"code","b":[198,20],"m":"dec","oa":20,"o":"zpa_14"},{"a":35524,"t":"code","b":[208,242],"m":"bne","oa":35512,"o":"b_8AB8"},{"a":35526,"t":"code","b":[96],"m":"rts"},{"a":35527,"l":"msg_hide","c":"Takes the between-sortie caption down. Fills character rows 10 and 11 of both screen matrices (80 bytes at $0590 and $4590) with $2E, the value every other cell of the play area carries, which as bitmap colour means bit-pair 01 = red and bit-pair 10 = light blue. Leaves zpa_02 ($02) = 0, so the test at $9A85 fails and the raster handler runs straight from $51 to $E0 without opening the text window; those two rows go back to being ordinary bitmap. Called at $961B, $9648 and $9704.","t":"code","b":[160,79],"m":"ldy","o":"#$4F","x":[38427,38472,38660]},{"a":35529,"t":"code","b":[169,46],"m":"lda","o":"#$2E"},{"a":35531,"l":"b_8ACB","t":"code","b":[153,144,5],"m":"sta","oa":1424,"o":"f_0590,y","x":[35540]},{"a":35534,"t":"code","b":[153,144,69],"m":"sta","oa":17808,"o":"f_4590,y"},{"a":35537,"t":"code","b":[132,2],"m":"sty","oa":2,"o":"msg_showing"},{"a":35539,"t":"code","b":[136],"m":"dey"},{"a":35540,"t":"code","b":[16,245],"m":"bpl","oa":35531,"o":"b_8ACB"},{"a":35542,"t":"code","b":[96],"m":"rts"},{"a":35543,"l":"msg_ptrs","c":"Five pointers, low byte then high byte, to the between-sortie captions. $8A8B doubles the caption number and reads $8AD7,x and $8AD8,x. Entries: $8AE1 FIRST SORTIE, $8AEE SECOND SORTIE, $8AFC THIRD SORTIE, $8B09 THE END, $8B11 MAGNIFICENT!.","t":"byte","b":[225],"x":[35469]},{"a":35544,"l":"msg_ptrs_hi","c":"The second base the caption pointer table is read from. $8A8B doubles the caption number into X and does lda $8AD7,x for the low byte and lda $8AD8,x for the high byte, so this label names the high half of entry 0 and the bytes $8AD8-$8AE0 are the high byte of each pointer interleaved with the low bytes of the next.","t":"addr","b":[138,238],"oa":61066,"o":"$EE8A","x":[35474]},{"a":35546,"t":"addr","b":[138,252],"oa":64650,"o":"$FC8A"},{"a":35548,"t":"addr","b":[138,9],"oa":2442,"o":"$098A"},{"a":35550,"t":"addr","b":[139,17],"oa":4491,"o":"$118B"},{"a":35552,"t":"byte","b":[139]},{"a":35553,"l":"msg_first_sortie","c":"Caption 0. First byte is the length, $0C = 12, followed by 12 screen codes spelling FIRST SORTIE. $8A8B centres it on character row 11. The length byte renders as the screen code for L in a text dump.","t":"byte","b":[12,6,9,18,19,20,32,19]},{"a":35561,"t":"byte","b":[15,18,20,9,5]},{"a":35566,"l":"msg_second_sortie","c":"Caption 1: length byte $0D then 13 screen codes, SECOND SORTIE.","t":"byte","b":[13,19,5,3,15,14,4,32]},{"a":35574,"t":"byte","b":[19,15,18,20,9,5]},{"a":35580,"l":"msg_third_sortie","c":"Caption 2: length byte $0C then 12 screen codes, THIRD SORTIE. Shown for the third and every later sortie, since $9630 passes $0CFF and $961E sends any value of 3 or more down the ending path instead.","t":"byte","b":[12,20,8,9,18,4,32,19]},{"a":35588,"t":"byte","b":[15,18,20,9,5]},{"a":35593,"l":"msg_the_end","c":"Caption 3: length byte $07 then 7 screen codes, THE END. $96E4 selects it when $0CFF has reached 3, or when $0CEE + $0CEF is $40.","t":"byte","b":[7,20,8,5,32,5,14,4]},{"a":35601,"l":"msg_magnificent","c":"Caption 4: length byte $0C then 12 screen codes, MAGNIFICENT!. $96E8 selects it when $0CEE alone has reached $40.","t":"byte","b":[12,13,1,7,14,9,6,9]},{"a":35609,"t":"byte","b":[3,5,14,20,33]},{"a":35614,"l":"inline_arg_here","c":"First half of the inline-parameter convention, used by the wrappers at $8BBA and $8B68. The caller writes jsr wrapper, then two bytes of data, then its next instruction; the wrapper does jsr here. This pops the wrapper's own return address, adds 1 and keeps it in zpa_20/21 ($20/$21) - that is where the wrapper resumes - then pops the caller's return address, adds 1 and keeps it in zpa_17/18 ($17/$18), which now points AT the two inline bytes. jmp ($0020) goes back into the wrapper, which reads the parameter through ($17), steps $17/$18 past it and finishes with jmp ($0017), landing on the caller's next instruction. Both return addresses are off the stack, so the stack stays balanced and nothing rts's. The two bytes after such a jsr are data, not code.","t":"code","b":[24],"m":"clc","x":[35692,35774]},{"a":35615,"t":"code","b":[104],"m":"pla"},{"a":35616,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":35618,"t":"code","b":[133,32],"m":"sta","oa":32,"o":"resume_vec"},{"a":35620,"t":"code","b":[104],"m":"pla"},{"a":35621,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":35623,"t":"code","b":[133,33],"m":"sta","oa":33,"o":"zpa_21"},{"a":35625,"t":"code","b":[104],"m":"pla"},{"a":35626,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":35628,"t":"code","b":[104],"m":"pla"},{"a":35629,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":35631,"t":"code","b":[230,23],"m":"inc","oa":23,"o":"shape_ptr"},{"a":35633,"t":"code","b":[208,2],"m":"bne","oa":35637,"o":"b_8B35"},{"a":35635,"t":"code","b":[230,24],"m":"inc","oa":24,"o":"zpa_18"},{"a":35637,"l":"b_8B35","t":"code","b":[108,32,0],"m":"jmp","oa":32,"o":"(resume_vec)","x":[35633]},{"a":35640,"l":"inline_arg_deref","c":"Same as $8B1E but it dereferences: the inline word is the address of the parameter, not the parameter. Pops the wrapper's resume address into zpa_20/21 ($20/$21) and the caller's into zpa_1B/1C ($1B/$1C), points $1B/$1C at the inline word, loads the word stored there into zpa_17/18 ($17/$18), then advances $1B/$1C by two so it points at the caller's next instruction, and jmp ($0020) resumes the wrapper. So after this call $17/$18 is a pointer to the parameter record and $1B/$1C is where to go back to; the wrappers $8B91, $8BE0, $8BF9 and $8C17 all end with jmp ($001B). Used by every draw call in the game.","t":"code","b":[24],"m":"clc","x":[35733,35812,35837,35867]},{"a":35641,"t":"code","b":[104],"m":"pla"},{"a":35642,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":35644,"t":"code","b":[133,32],"m":"sta","oa":32,"o":"resume_vec"},{"a":35646,"t":"code","b":[104],"m":"pla"},{"a":35647,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":35649,"t":"code","b":[133,33],"m":"sta","oa":33,"o":"zpa_21"},{"a":35651,"t":"code","b":[104],"m":"pla"},{"a":35652,"t":"code","b":[133,27],"m":"sta","oa":27,"o":"inline_ret"},{"a":35654,"t":"code","b":[104],"m":"pla"},{"a":35655,"t":"code","b":[133,28],"m":"sta","oa":28,"o":"zpa_1C"},{"a":35657,"t":"code","b":[230,27],"m":"inc","oa":27,"o":"inline_ret"},{"a":35659,"t":"code","b":[208,2],"m":"bne","oa":35663,"o":"b_8B4F"},{"a":35661,"t":"code","b":[230,28],"m":"inc","oa":28,"o":"zpa_1C"},{"a":35663,"l":"b_8B4F","t":"code","b":[160,0],"m":"ldy","o":"#$00","x":[35659]},{"a":35665,"t":"code","b":[177,27],"m":"lda","oa":27,"o":"(inline_ret),y"},{"a":35667,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":35669,"t":"code","b":[200],"m":"iny"},{"a":35670,"t":"code","b":[177,27],"m":"lda","oa":27,"o":"(inline_ret),y"},{"a":35672,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":35674,"t":"code","b":[24],"m":"clc"},{"a":35675,"t":"code","b":[165,27],"m":"lda","oa":27,"o":"inline_ret"},{"a":35677,"t":"code","b":[105,2],"m":"adc","o":"#$02"},{"a":35679,"t":"code","b":[133,27],"m":"sta","oa":27,"o":"inline_ret"},{"a":35681,"t":"code","b":[144,2],"m":"bcc","oa":35685,"o":"b_8B65"},{"a":35683,"t":"code","b":[230,28],"m":"inc","oa":28,"o":"zpa_1C"},{"a":35685,"l":"b_8B65","t":"code","b":[108,32,0],"m":"jmp","oa":32,"o":"(resume_vec)","x":[35681]},{"a":35688,"l":"inline_set_draw_pos_dead","c":"Unreferenced. Same job as $8B91 - load the destination for a draw straight into zpa_04/05 ($04/$05, the 16-bit screen bit column) and zpa_03 ($03, the bitmap row) - but it takes the three bytes inline after the jsr instead of through a pointer, so it goes via $8B1E rather than $8B38, steps $17/$18 past three bytes and resumes with jmp ($0017). Searching $8000-$BFFF for 20 68 8B and 4C 68 8B finds nothing, so no code reaches it.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a"},{"a":35690,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":35692,"t":"code","b":[32,30,139],"m":"jsr","oa":35614,"o":"inline_arg_here"},{"a":35695,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":35697,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35699,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":35701,"t":"code","b":[200],"m":"iny"},{"a":35702,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35704,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":35706,"t":"code","b":[200],"m":"iny"},{"a":35707,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35709,"t":"code","b":[133,3],"m":"sta","oa":3,"o":"draw_row"},{"a":35711,"t":"code","b":[24],"m":"clc"},{"a":35712,"t":"code","b":[165,23],"m":"lda","oa":23,"o":"shape_ptr"},{"a":35714,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":35716,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":35718,"t":"code","b":[144,2],"m":"bcc","oa":35722,"o":"b_8B8A"},{"a":35720,"t":"code","b":[230,24],"m":"inc","oa":24,"o":"zpa_18"},{"a":35722,"l":"b_8B8A","t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a","x":[35718]},{"a":35724,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":35726,"t":"code","b":[108,23,0],"m":"jmp","oa":23,"o":"(shape_ptr)"},{"a":35729,"l":"inline_set_draw_pos","c":"Loads a draw destination straight from a three-byte record, skipping the clipper at $8F03 entirely. The inline word (fetched by $8B38) is the address of the record; its bytes become zpa_04/05 ($04/$05), the 16-bit screen bit column of the left edge, and zpa_03 ($03), the bitmap row of the top edge. A and Y survive in $1D/$1F. The one caller, $BC8E in the erase pass, points it at $006A, the already-screen-relative position $AA38 recorded when the shape was drawn last frame, and then calls the rectangle filler $8C5E to blank it.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[48270]},{"a":35731,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":35733,"t":"code","b":[32,56,139],"m":"jsr","oa":35640,"o":"inline_arg_deref"},{"a":35736,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":35738,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35740,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":35742,"t":"code","b":[200],"m":"iny"},{"a":35743,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35745,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":35747,"t":"code","b":[200],"m":"iny"},{"a":35748,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35750,"t":"code","b":[133,3],"m":"sta","oa":3,"o":"draw_row"},{"a":35752,"t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a"},{"a":35754,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":35756,"t":"code","b":[108,27,0],"m":"jmp","oa":27,"o":"(inline_ret)"},{"a":35759,"l":"clip_override_bottom","c":"Throws away the clip amounts $8F03 just computed and substitutes one: zpa_25 ($25) = A, the number of rows to drop off the bottom of the shape, with zpa_22, zpa_23 and zpa_24 ($22/$23/$24) all zero so nothing is cut off the left, the right or the top. The single caller, $ABB2, passes zpa_62 ($62) just before drawing the helicopter, so $62 is how many rows of the helicopter shape are suppressed at its bottom edge.","t":"code","b":[133,37],"m":"sta","oa":37,"o":"clip_bottom","x":[43954]},{"a":35761,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":35763,"t":"code","b":[133,34],"m":"sta","oa":34,"o":"clip_left"},{"a":35765,"t":"code","b":[133,35],"m":"sta","oa":35,"o":"clip_right"},{"a":35767,"t":"code","b":[133,36],"m":"sta","oa":36,"o":"clip_top"},{"a":35769,"t":"code","b":[96],"m":"rts"},{"a":35770,"l":"inline_fill_record","c":"Inline-parameter wrapper: jsr $8BBA followed by two data bytes loads those two bytes into zpa_37/38 ($37/$38), the record pointer the drawing routines read, and execution resumes at the third byte after the jsr. Unlike $8BE0 it does not dereference, so the inline word IS the record address. Goes through $8B1E, copies the word, steps zpa_17/18 past it and jmp ($0017). A and Y are preserved through $1D/$1F. Both callers point it at a fill record for $8C5E: $BA67 at the literal record $BB25, $BC89 at the scratch record $0E44 built by the erase pass.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[47719,48265]},{"a":35772,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":35774,"t":"code","b":[32,30,139],"m":"jsr","oa":35614,"o":"inline_arg_here"},{"a":35777,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":35779,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35781,"t":"code","b":[133,55],"m":"sta","oa":55,"o":"shape_hdr"},{"a":35783,"t":"code","b":[200],"m":"iny"},{"a":35784,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35786,"t":"code","b":[133,56],"m":"sta","oa":56,"o":"zpa_38"},{"a":35788,"t":"code","b":[24],"m":"clc"},{"a":35789,"t":"code","b":[165,23],"m":"lda","oa":23,"o":"shape_ptr"},{"a":35791,"t":"code","b":[105,2],"m":"adc","o":"#$02"},{"a":35793,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":35795,"t":"code","b":[165,24],"m":"lda","oa":24,"o":"zpa_18"},{"a":35797,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":35799,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":35801,"t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a"},{"a":35803,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":35805,"t":"code","b":[108,23,0],"m":"jmp","oa":23,"o":"(shape_ptr)"},{"a":35808,"l":"inline_shape_ptr","c":"Inline-parameter wrapper, the one almost every draw uses: jsr $8BE0 followed by the address of a pointer puts the word STORED at that address into zpa_37/38 ($37/$38) and resumes after the two inline bytes. Goes through $8B38. $37/$38 is the shape record that $8EE2 unpacks - width in bitmap bits, height in pixel rows, then ceil(width/8) bytes per row, top row first. Call sites pass an entry of the shape pointer table at $8009, e.g. jsr $8BE0 / .word $8089 selects shape 64. A and Y are preserved. Twenty-six call sites, all in the actor handlers.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[40313,40339,40366,41161,41208,41243,43683,43944,44094,44189,44503,45162,45341,45436,45557,45614,45689,46928,47356,47378,47431,47647,47742,47797,47851,47895]},{"a":35810,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":35812,"t":"code","b":[32,56,139],"m":"jsr","oa":35640,"o":"inline_arg_deref"},{"a":35815,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":35817,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35819,"t":"code","b":[133,55],"m":"sta","oa":55,"o":"shape_hdr"},{"a":35821,"t":"code","b":[200],"m":"iny"},{"a":35822,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35824,"t":"code","b":[133,56],"m":"sta","oa":56,"o":"zpa_38"},{"a":35826,"t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a"},{"a":35828,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":35830,"t":"code","b":[108,27,0],"m":"jmp","oa":27,"o":"(inline_ret)"},{"a":35833,"l":"inline_object_pos","c":"Inline-parameter wrapper: jsr $8BF9 followed by the address of a three-byte record copies those bytes into zpa_34/35 ($34/$35), the object's 16-bit world X measured in bitmap bits, and zpa_36 ($36), its bitmap row. Resumes after the two inline bytes; goes through $8B38; A and Y are preserved. Every call site but one passes .word $0067, the $67/$68/$69 scratch triple the actor handlers fill in, and follows it with $8BE0 for the shape and $8F03 to clip.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[40442,41156,41203,41261,43678,43939,44047,44203,44525,45183,45369,45431,45552,45609,45684,46923,47333,47373,47426,47642,47714,47737,47768,47792,47822,47846,47874]},{"a":35835,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":35837,"t":"code","b":[32,56,139],"m":"jsr","oa":35640,"o":"inline_arg_deref"},{"a":35840,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":35842,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35844,"t":"code","b":[133,52],"m":"sta","oa":52,"o":"arg3_lo"},{"a":35846,"t":"code","b":[200],"m":"iny"},{"a":35847,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35849,"t":"code","b":[133,53],"m":"sta","oa":53,"o":"zpa_35"},{"a":35851,"t":"code","b":[200],"m":"iny"},{"a":35852,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35854,"t":"code","b":[133,54],"m":"sta","oa":54,"o":"zpa_36"},{"a":35856,"t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a"},{"a":35858,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":35860,"t":"code","b":[108,27,0],"m":"jmp","oa":27,"o":"(inline_ret)"},{"a":35863,"l":"inline_window_x","c":"Inline-parameter wrapper: jsr $8C17 followed by the address of a word copies that word into zpa_3B/3C ($3B/$3C), the world X in bitmap bits of the left edge of the 320-bit visible window. $8F03 subtracts it from an object's world X to get the on-screen column, so this is what makes the playfield scroll. Both callers pass .word $0075, i.e. the camera $75/$76: $9741 at sortie start, where the camera is seeded to $11D8, and $BDCB every time the camera has moved, after clamping it to $02B0..$11D8. Read live, $3B/$3C always equals $75/$76.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[38721,48587]},{"a":35865,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":35867,"t":"code","b":[32,56,139],"m":"jsr","oa":35640,"o":"inline_arg_deref"},{"a":35870,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":35872,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35874,"t":"code","b":[133,59],"m":"sta","oa":59,"o":"win_org"},{"a":35876,"t":"code","b":[200],"m":"iny"},{"a":35877,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":35879,"t":"code","b":[133,60],"m":"sta","oa":60,"o":"zpa_3C"},{"a":35881,"t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a"},{"a":35883,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":35885,"t":"code","b":[108,27,0],"m":"jmp","oa":27,"o":"(inline_ret)"},{"a":35888,"l":"shear_from_speed","c":"Turns a signed speed in A, -5 to +5, into the shear the slanted-draw routines at $90D2 and $90DF use. Index (A+5)*2 into the table at $8C48 gives zpa_2C ($2C), the row step ($FF, $00 or $01), and zpa_2B ($2B), how many bitmap-bit columns to walk before taking that step; $9162 reloads $32 from $2B and adds $2C to the row counter $31 each time the count runs out. X and Y are preserved. Called from $AB75 with zpa_6F and from $AC16 with zpa_5A.","t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y","x":[43893,44054]},{"a":35890,"t":"code","b":[134,30],"m":"stx","oa":30,"o":"save_x"},{"a":35892,"t":"code","b":[24],"m":"clc"},{"a":35893,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":35895,"t":"code","b":[10],"m":"asl","o":"a"},{"a":35896,"t":"code","b":[170],"m":"tax"},{"a":35897,"t":"code","b":[189,72,140],"m":"lda","oa":35912,"o":"f_8C48,x"},{"a":35900,"t":"code","b":[133,44],"m":"sta","oa":44,"o":"slope_step"},{"a":35902,"t":"code","b":[189,73,140],"m":"lda","oa":35913,"o":"shear_table,x"},{"a":35905,"t":"code","b":[133,43],"m":"sta","oa":43,"o":"slope_run"},{"a":35907,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":35909,"t":"code","b":[166,30],"m":"ldx","oa":30,"o":"save_x"},{"a":35911,"t":"code","b":[96],"m":"rts"},{"a":35912,"l":"f_8C48","c":"Row step of the first shear-table entry, speed -5: $FF, one row per run. $8C30 reads the step from $8C48,x and the run length from $8C49,x with the same doubled index, so the table is read as step/run pairs.","t":"byte","b":[255],"x":[35897]},{"a":35913,"l":"shear_table","c":"Run lengths of the shear table, and the ten remaining step/run pairs: read as (step, run) from $8C48 they are ($FF,3) ($FF,4) ($FF,5) ($FF,10) ($FF,13) ($00,0) ($01,13) ($01,10) ($01,5) ($01,4) ($01,3) for speeds -5 to +5. The run is the number of bitmap-bit columns between one-row steps, so the faster the speed the steeper the slant, and speed 0 gives no step at all. Only $8C30 reads it.","t":"byte","b":[3,255,4,255,5,255,10,255],"x":[35902]},{"a":35921,"t":"byte","b":[13,0,0,1,13,1,10,1]},{"a":35929,"t":"byte","b":[5,1,4,1,3]},{"a":35934,"l":"fill_rect_pattern","c":"Fills a rectangle of the bitmap with a repeating two-by-two pattern, storing rather than ORing, which is how the game both erases actors and paints solid blocks. $8EE2 unpacks the record at zpa_37/38 ($37/$38): byte 0 is the width in CHARACTER CELLS (not bits, as for shapes), byte 1 the height in pixel rows, then four pattern bytes - the pair used on even rows and the pair used on odd rows, alternated cell by cell along the row according to the parity of the starting column zpa_08. Draws downward from row zpa_03 ($03) at column zpa_04/05 ($04/$05), clamping the width so it never runs past column 40 and stopping if the row counter zpa_31 falls below zpa_3A ($3A). Each row's address is $0A00,x plus (zpa_04 and $F8), high byte ($0AA8,x eor zpa_0F) plus zpa_05. $BC93 calls it with the record at $0E44, whose four pattern bytes are zero, to blank the shape the display list recorded last frame; $BA71 calls it with the record at $BB25, 15 cells by 5 rows of $AA, a solid block of colour 10.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[47729,48275]},{"a":35936,"t":"code","b":[134,30],"m":"stx","oa":30,"o":"save_x"},{"a":35938,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":35940,"t":"code","b":[32,226,142],"m":"jsr","oa":36578,"o":"unpack_shape_header"},{"a":35943,"t":"code","b":[32,200,141],"m":"jsr","oa":36296,"o":"split_screen_x"},{"a":35946,"t":"code","b":[165,3],"m":"lda","oa":3,"o":"draw_row"},{"a":35948,"t":"code","b":[133,49],"m":"sta","oa":49,"o":"cur_row"},{"a":35950,"t":"code","b":[24],"m":"clc"},{"a":35951,"t":"code","b":[165,8],"m":"lda","oa":8,"o":"draw_col"},{"a":35953,"t":"code","b":[101,16],"m":"adc","oa":16,"o":"shape_w"},{"a":35955,"t":"code","b":[201,41],"m":"cmp","o":"#$29"},{"a":35957,"t":"code","b":[144,7],"m":"bcc","oa":35966,"o":"b_8C7E"},{"a":35959,"t":"code","b":[56],"m":"sec"},{"a":35960,"t":"code","b":[169,40],"m":"lda","o":"#$28"},{"a":35962,"t":"code","b":[229,8],"m":"sbc","oa":8,"o":"draw_col"},{"a":35964,"t":"code","b":[133,16],"m":"sta","oa":16,"o":"shape_w"},{"a":35966,"l":"b_8C7E","t":"code","b":[166,49],"m":"ldx","oa":49,"o":"cur_row","x":[35957,36054]},{"a":35968,"t":"code","b":[228,58],"m":"cpx","oa":58,"o":"clip_row_lo"},{"a":35970,"t":"code","b":[144,85],"m":"bcc","oa":36057,"o":"b_8CD9"},{"a":35972,"t":"code","b":[189,0,10],"m":"lda","oa":2560,"o":"bitmap_row_lo,x"},{"a":35975,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":35977,"t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x"},{"a":35979,"t":"code","b":[41,248],"m":"and","o":"#$F8"},{"a":35981,"t":"code","b":[24],"m":"clc"},{"a":35982,"t":"code","b":[101,6],"m":"adc","oa":6,"o":"bmp_ptr"},{"a":35984,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":35986,"t":"code","b":[133,32],"m":"sta","oa":32,"o":"resume_vec"},{"a":35988,"t":"code","b":[189,168,10],"m":"lda","oa":2728,"o":"bitmap_row_hi,x"},{"a":35991,"t":"code","b":[69,15],"m":"eor","oa":15,"o":"vic_bank_bit"},{"a":35993,"t":"code","b":[101,5],"m":"adc","oa":5,"o":"zpa_05"},{"a":35995,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":35997,"t":"code","b":[133,33],"m":"sta","oa":33,"o":"zpa_21"},{"a":35999,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":36001,"t":"code","b":[37,49],"m":"and","oa":49,"o":"cur_row"},{"a":36003,"t":"code","b":[10],"m":"asl","o":"a"},{"a":36004,"t":"code","b":[168],"m":"tay"},{"a":36005,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":36007,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36009,"t":"code","b":[200],"m":"iny"},{"a":36010,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":36012,"t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12"},{"a":36014,"t":"code","b":[166,16],"m":"ldx","oa":16,"o":"shape_w"},{"a":36016,"t":"code","b":[165,8],"m":"lda","oa":8,"o":"draw_col"},{"a":36018,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":36020,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":36022,"t":"code","b":[240,12],"m":"beq","oa":36036,"o":"b_8CC4"},{"a":36024,"l":"b_8CB8","t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12","x":[36046]},{"a":36026,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":36028,"t":"code","b":[152],"m":"tya"},{"a":36029,"t":"code","b":[24],"m":"clc"},{"a":36030,"t":"code","b":[105,8],"m":"adc","o":"#$08"},{"a":36032,"t":"code","b":[168],"m":"tay"},{"a":36033,"t":"code","b":[202],"m":"dex"},{"a":36034,"t":"code","b":[240,12],"m":"beq","oa":36048,"o":"b_8CD0"},{"a":36036,"l":"b_8CC4","t":"code","b":[165,19],"m":"lda","oa":19,"o":"zpa_13","x":[36022]},{"a":36038,"t":"code","b":[145,32],"m":"sta","oa":32,"o":"(resume_vec),y"},{"a":36040,"t":"code","b":[152],"m":"tya"},{"a":36041,"t":"code","b":[24],"m":"clc"},{"a":36042,"t":"code","b":[105,8],"m":"adc","o":"#$08"},{"a":36044,"t":"code","b":[168],"m":"tay"},{"a":36045,"t":"code","b":[202],"m":"dex"},{"a":36046,"t":"code","b":[208,232],"m":"bne","oa":36024,"o":"b_8CB8"},{"a":36048,"l":"b_8CD0","t":"code","b":[198,17],"m":"dec","oa":17,"o":"shape_h","x":[36034]},{"a":36050,"t":"code","b":[240,5],"m":"beq","oa":36057,"o":"b_8CD9"},{"a":36052,"t":"code","b":[198,49],"m":"dec","oa":49,"o":"cur_row"},{"a":36054,"t":"code","b":[76,126,140],"m":"jmp","oa":35966,"o":"b_8C7E"},{"a":36057,"l":"b_8CD9","t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a","x":[35970,36050]},{"a":36059,"t":"code","b":[166,30],"m":"ldx","oa":30,"o":"save_x"},{"a":36061,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":36063,"t":"code","b":[96],"m":"rts"},{"a":36064,"l":"draw_layer_reset","c":"Resets the whole drawing layer between sorties. Calls $8CFE for the clip amounts, then zeroes zpa_0F ($0F, so drawing goes to the bank-0 bitmap at $2000), zpa_2B and zpa_2C (the shear), zpa_2D, zpa_2E, zpa_3F, zpa_3B/3C ($3B/$3C, the window's world X), and zpa_3A ($3A, the lowest bitmap row a shape may occupy), and sets zpa_39 ($39) to $A7 = 167, the highest. A is preserved. The only caller, $BBCA, follows it by clearing both bitmaps with $8D42.","t":"code","b":[72],"m":"pha","x":[48074]},{"a":36065,"t":"code","b":[32,254,140],"m":"jsr","oa":36094,"o":"clip_reset"},{"a":36068,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":36070,"t":"code","b":[133,15],"m":"sta","oa":15,"o":"vic_bank_bit"},{"a":36072,"t":"code","b":[133,44],"m":"sta","oa":44,"o":"slope_step"},{"a":36074,"t":"code","b":[133,43],"m":"sta","oa":43,"o":"slope_run"},{"a":36076,"t":"code","b":[133,45],"m":"sta","oa":45,"o":"zpa_2D"},{"a":36078,"t":"code","b":[133,46],"m":"sta","oa":46,"o":"zpa_2E"},{"a":36080,"t":"code","b":[133,63],"m":"sta","oa":63,"o":"zpa_3F"},{"a":36082,"t":"code","b":[133,59],"m":"sta","oa":59,"o":"win_org"},{"a":36084,"t":"code","b":[133,60],"m":"sta","oa":60,"o":"zpa_3C"},{"a":36086,"t":"code","b":[133,58],"m":"sta","oa":58,"o":"clip_row_lo"},{"a":36088,"t":"code","b":[169,167],"m":"lda","o":"#$A7"},{"a":36090,"t":"code","b":[133,57],"m":"sta","oa":57,"o":"clip_row_hi"},{"a":36092,"t":"code","b":[104],"m":"pla"},{"a":36093,"t":"code","b":[96],"m":"rts"},{"a":36094,"l":"clip_reset","c":"Zeroes the clip amounts and the low bytes of the two shift-table pointers: zpa_22 and zpa_23 ($22/$23, bitmap bits to cut off the left and the right of a shape), zpa_24 and zpa_25 ($24/$25, rows to cut off the top and the bottom), zpa_42 and zpa_44. $8DF3 later sets the high bytes $43 and $45 to $10+shift and $18+shift, so ($42) and ($44) address the 256-byte pre-shift tables at $1000 and $1800. A is preserved. Called at the head of the clipper $8F03 and from $8CE0.","t":"code","b":[72],"m":"pha","x":[36065,36628]},{"a":36095,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":36097,"t":"code","b":[133,34],"m":"sta","oa":34,"o":"clip_left"},{"a":36099,"t":"code","b":[133,35],"m":"sta","oa":35,"o":"clip_right"},{"a":36101,"t":"code","b":[133,36],"m":"sta","oa":36,"o":"clip_top"},{"a":36103,"t":"code","b":[133,37],"m":"sta","oa":37,"o":"clip_bottom"},{"a":36105,"t":"code","b":[133,66],"m":"sta","oa":66,"o":"zpa_42"},{"a":36107,"t":"code","b":[133,68],"m":"sta","oa":68,"o":"zpa_44"},{"a":36109,"t":"code","b":[104],"m":"pla"},{"a":36110,"t":"code","b":[96],"m":"rts"},{"a":36111,"l":"draw_to_bank0","c":"Points the drawing routines at the bank-0 bitmap ($2000) by clearing zpa_0F ($0F), the byte EORed into every row address high byte taken from $0AA8,x. A is preserved. The only caller is $BEF4, which follows it with $8D1F and $8D16 to put that same buffer on screen.","t":"code","b":[72],"m":"pha","x":[48884]},{"a":36112,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":36114,"t":"code","b":[133,15],"m":"sta","oa":15,"o":"vic_bank_bit"},{"a":36116,"t":"code","b":[104],"m":"pla"},{"a":36117,"t":"code","b":[96],"m":"rts"},{"a":36118,"l":"flip_draw_buffer","c":"Flips which of the two bitmaps the drawing routines write to, by toggling bit 6 of zpa_0F ($0F). $0F is EORed into the high byte read from $0AA8,x, so $00 sends every write to the bank-0 bitmap at $2000 and $40 to the bank-1 bitmap at $6000 - the row tables hold bank-0 addresses and bit 6 is the only difference between the two. A is preserved. Always called immediately after $8D1F, which shows the buffer that has just been finished.","t":"code","b":[72],"m":"pha","x":[38368,38496,38619,38707,38741,38759,48086,48098,48887,48893]},{"a":36119,"t":"code","b":[165,15],"m":"lda","oa":15,"o":"vic_bank_bit"},{"a":36121,"t":"code","b":[73,64],"m":"eor","o":"#$40"},{"a":36123,"t":"code","b":[133,15],"m":"sta","oa":15,"o":"vic_bank_bit"},{"a":36125,"t":"code","b":[104],"m":"pla"},{"a":36126,"t":"code","b":[96],"m":"rts"},{"a":36127,"l":"show_draw_buffer","c":"Shows the buffer that zpa_0F ($0F) currently names, by switching the VIC bank. Makes CIA2 port A bits 0-1 outputs, then for $0F = 0 sets both bits (bank 0: matrix $0400, bitmap $2000) and for any other value writes %10 (bank 1: matrix $4400, bitmap $6000); the bank bits are inverted, which is why %11 selects $0000 and %10 selects $4000. A is preserved. Called once per frame from the main loops, always followed by $8D16 so the next frame is drawn into the buffer that is no longer visible.","t":"code","b":[72],"m":"pha","x":[38365,38493,38616,38704,38738,38756,48890]},{"a":36128,"t":"code","b":[173,2,221],"m":"lda","oa":56578,"o":"$DD02"},{"a":36131,"t":"code","b":[9,3],"m":"ora","o":"#$03"},{"a":36133,"t":"code","b":[141,2,221],"m":"sta","oa":56578,"o":"$DD02"},{"a":36136,"t":"code","b":[165,15],"m":"lda","oa":15,"o":"vic_bank_bit"},{"a":36138,"t":"code","b":[208,10],"m":"bne","oa":36150,"o":"b_8D36"},{"a":36140,"t":"code","b":[173,0,221],"m":"lda","oa":56576,"o":"$DD00"},{"a":36143,"t":"code","b":[9,3],"m":"ora","o":"#$03"},{"a":36145,"t":"code","b":[141,0,221],"m":"sta","oa":56576,"o":"$DD00"},{"a":36148,"t":"code","b":[104],"m":"pla"},{"a":36149,"t":"code","b":[96],"m":"rts"},{"a":36150,"l":"b_8D36","t":"code","b":[173,0,221],"m":"lda","oa":56576,"o":"$DD00","x":[36138]},{"a":36153,"t":"code","b":[41,252],"m":"and","o":"#$FC"},{"a":36155,"t":"code","b":[9,2],"m":"ora","o":"#$02"},{"a":36157,"t":"code","b":[141,0,221],"m":"sta","oa":56576,"o":"$DD00"},{"a":36160,"t":"code","b":[104],"m":"pla"},{"a":36161,"t":"code","b":[96],"m":"rts"},{"a":36162,"l":"fill_rows","c":"Fills whole bitmap rows with one byte, all 40 cells across. A = the byte, X = the first pixel row, Y = the last; the count Y+1-X goes into zpa_15 ($15). For each row it takes the address from $0A00,x and ($0AA8,x eor zpa_0F) and stores the byte at the 40 addresses 8 bytes apart that make up that pixel row. The only caller is $BBCA, which runs it twice with A=0, X=0, Y=$A7 either side of a buffer flip, blanking all 168 rows of both bitmaps at the start of a sortie.","t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12","x":[48083,48095]},{"a":36164,"t":"code","b":[134,20],"m":"stx","oa":20,"o":"zpa_14"},{"a":36166,"t":"code","b":[200],"m":"iny"},{"a":36167,"t":"code","b":[152],"m":"tya"},{"a":36168,"t":"code","b":[56],"m":"sec"},{"a":36169,"t":"code","b":[229,20],"m":"sbc","oa":20,"o":"zpa_14"},{"a":36171,"t":"code","b":[133,21],"m":"sta","oa":21,"o":"zpa_15"},{"a":36173,"l":"b_8D4D","t":"code","b":[166,20],"m":"ldx","oa":20,"o":"zpa_14","x":[36218]},{"a":36175,"t":"code","b":[189,0,10],"m":"lda","oa":2560,"o":"bitmap_row_lo,x"},{"a":36178,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":36180,"t":"code","b":[189,168,10],"m":"lda","oa":2728,"o":"bitmap_row_hi,x"},{"a":36183,"t":"code","b":[69,15],"m":"eor","oa":15,"o":"vic_bank_bit"},{"a":36185,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":36187,"t":"code","b":[162,39],"m":"ldx","o":"#$27"},{"a":36189,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":36191,"l":"j_8D5F","t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12","x":[36211]},{"a":36193,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":36195,"t":"code","b":[202],"m":"dex"},{"a":36196,"t":"code","b":[48,16],"m":"bmi","oa":36214,"o":"b_8D76"},{"a":36198,"t":"code","b":[165,6],"m":"lda","oa":6,"o":"bmp_ptr"},{"a":36200,"t":"code","b":[24],"m":"clc"},{"a":36201,"t":"code","b":[105,8],"m":"adc","o":"#$08"},{"a":36203,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":36205,"t":"code","b":[165,7],"m":"lda","oa":7,"o":"zpa_07"},{"a":36207,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":36209,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":36211,"t":"code","b":[76,95,141],"m":"jmp","oa":36191,"o":"j_8D5F"},{"a":36214,"l":"b_8D76","t":"code","b":[230,20],"m":"inc","oa":20,"o":"zpa_14","x":[36196]},{"a":36216,"t":"code","b":[198,21],"m":"dec","oa":21,"o":"zpa_15"},{"a":36218,"t":"code","b":[208,209],"m":"bne","oa":36173,"o":"b_8D4D"},{"a":36220,"t":"code","b":[96],"m":"rts"},{"a":36221,"l":"x_to_right_end","c":"Moves the working X to the far end of the shape, for the mirrored blitter. Saves the current zpa_04/05 in zpa_12/13, adds zpa_10 ($10, the visible width in bitmap bits) minus 1 to zpa_04/05, then falls into $8DD0, which derives zpa_08 ($08, the character column) and zpa_09 ($09) from that advanced value and then restores $04/$05 from $12/$13. So the advance survives only in $08/$09. The one caller, $9059 inside $903E, uses the difference between the old and the new $08 to find the byte offset of the shape's rightmost cell.","t":"code","b":[56],"m":"sec","x":[36953]},{"a":36222,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":36224,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":36226,"t":"code","b":[133,20],"m":"sta","oa":20,"o":"zpa_14"},{"a":36228,"t":"code","b":[24],"m":"clc"},{"a":36229,"t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x"},{"a":36231,"t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12"},{"a":36233,"t":"code","b":[101,20],"m":"adc","oa":20,"o":"zpa_14"},{"a":36235,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":36237,"t":"code","b":[165,5],"m":"lda","oa":5,"o":"zpa_05"},{"a":36239,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36241,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":36243,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":36245,"t":"code","b":[76,208,141],"m":"jmp","oa":36304,"o":"j_8DD0"},{"a":36248,"l":"bit_mask_for_x","c":"Builds the single-bit mask for one end of a shape, for the slanted-draw routines at $90D2 and $90DF which plot one bitmap bit column at a time instead of whole bytes. Saves zpa_04/05 in zpa_12/13; if bit 7 of zpa_2F ($2F) is set - which $90DF does and $90D2 does not - it first adds zpa_10 ($10) minus 1 so the RIGHT end is used. $8DD0 then gives zpa_08 ($08) = column and zpa_09 ($09) = 8 - (X and 7), and this routine replaces $09 with 1 shifted left $09-1 times, i.e. the mask for bit 7-(X and 7). $9156 ORs that mask into the bitmap. Only caller is $90EC.","t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x","x":[37100]},{"a":36250,"t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12"},{"a":36252,"t":"code","b":[165,5],"m":"lda","oa":5,"o":"zpa_05"},{"a":36254,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36256,"t":"code","b":[36,47],"m":"bit","oa":47,"o":"draw_mirror"},{"a":36258,"t":"code","b":[48,3],"m":"bmi","oa":36263,"o":"b_8DA7"},{"a":36260,"t":"code","b":[76,183,141],"m":"jmp","oa":36279,"o":"j_8DB7"},{"a":36263,"l":"b_8DA7","t":"code","b":[56],"m":"sec","x":[36258]},{"a":36264,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":36266,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":36268,"t":"code","b":[24],"m":"clc"},{"a":36269,"t":"code","b":[101,4],"m":"adc","oa":4,"o":"draw_x"},{"a":36271,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":36273,"t":"code","b":[165,5],"m":"lda","oa":5,"o":"zpa_05"},{"a":36275,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":36277,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":36279,"l":"j_8DB7","t":"code","b":[32,208,141],"m":"jsr","oa":36304,"o":"j_8DD0","x":[36260]},{"a":36282,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":36284,"t":"code","b":[166,9],"m":"ldx","oa":9,"o":"draw_bit"},{"a":36286,"l":"j_8DBE","t":"code","b":[202],"m":"dex","x":[36290]},{"a":36287,"t":"code","b":[240,4],"m":"beq","oa":36293,"o":"b_8DC5"},{"a":36289,"t":"code","b":[10],"m":"asl","o":"a"},{"a":36290,"t":"code","b":[76,190,141],"m":"jmp","oa":36286,"o":"j_8DBE"},{"a":36293,"l":"b_8DC5","t":"code","b":[133,9],"m":"sta","oa":9,"o":"draw_bit","x":[36287]},{"a":36295,"t":"code","b":[96],"m":"rts"},{"a":36296,"l":"split_screen_x","c":"Splits a screen bit column into a character column and a sub-cell shift, the arithmetic behind every draw. Entered at $8DC8 it first copies zpa_04/05 ($04/$05) to zpa_12/13; entered at $8DD0 the caller has already arranged what to convert in $04/$05 and what to restore in $12/$13. It then sets zpa_09 ($09) = X and 7, shifts the 16-bit value right three places to get zpa_08 ($08) = X >> 3, the character column 0-39, replaces $09 with 8 - (X and 7), and restores $04/$05. $8DF3 turns $09 into the pre-shift table numbers; $8FD3 first flips it back to X and 7 because it shifts the shape right, while $903E and $8D98 use it as it stands.","t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x","x":[35943,36828,36943,37167]},{"a":36298,"t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12"},{"a":36300,"t":"code","b":[165,5],"m":"lda","oa":5,"o":"zpa_05"},{"a":36302,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36304,"l":"j_8DD0","t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x","x":[36245,36279]},{"a":36306,"t":"code","b":[41,7],"m":"and","o":"#$07"},{"a":36308,"t":"code","b":[133,9],"m":"sta","oa":9,"o":"draw_bit"},{"a":36310,"t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x"},{"a":36312,"t":"code","b":[70,5],"m":"lsr","oa":5,"o":"zpa_05"},{"a":36314,"t":"code","b":[106],"m":"ror","o":"a"},{"a":36315,"t":"code","b":[70,5],"m":"lsr","oa":5,"o":"zpa_05"},{"a":36317,"t":"code","b":[106],"m":"ror","o":"a"},{"a":36318,"t":"code","b":[70,5],"m":"lsr","oa":5,"o":"zpa_05"},{"a":36320,"t":"code","b":[106],"m":"ror","o":"a"},{"a":36321,"t":"code","b":[133,8],"m":"sta","oa":8,"o":"draw_col"},{"a":36323,"t":"code","b":[56],"m":"sec"},{"a":36324,"t":"code","b":[169,8],"m":"lda","o":"#$08"},{"a":36326,"t":"code","b":[229,9],"m":"sbc","oa":9,"o":"draw_bit"},{"a":36328,"t":"code","b":[133,9],"m":"sta","oa":9,"o":"draw_bit"},{"a":36330,"t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12"},{"a":36332,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":36334,"t":"code","b":[165,19],"m":"lda","oa":19,"o":"zpa_13"},{"a":36336,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":36338,"t":"code","b":[96],"m":"rts"},{"a":36339,"l":"apply_clip","c":"Applies the clip amounts to a shape and chooses the pre-shift tables, between $8DC8 and the row loop. zpa_2A ($2A) = (width+7)/8, the bytes each stored row occupies. The zpa_24 ($24) rows cut off the top are skipped by multiplying $24 by $2A with an eight-step shift-and-add and adding the product to the shape data pointer zpa_17/18. Of the zpa_22 ($22) bits cut off the left, $27 = $22/8 whole bytes are added to $17/$18 as well, and zpa_26 ($26) = 8 - ($22 and 7) records the bits left over. The shift pointers' high bytes become $10 + shift (zpa_43) and $18 + shift (zpa_45) where shift is zpa_09, so ($42) reads the table at $1000 + 256*shift, which holds b >> shift, and ($44) the one at $1800 + 256*shift, which holds b << (8-shift): together they slide a whole row right by shift bits a byte at a time. Verified against the snapshot, all eight pairs match exactly. Finally zpa_10 loses $22 and zpa_23, zpa_11 loses $24 and zpa_25, and zpa_31 ($31) is set to zpa_03, the topmost row to draw. The odd case where the shift is 0 but bits were clipped skips one more source byte and rounds the width down to a multiple of 8.","t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w","x":[36838,36946]},{"a":36341,"t":"code","b":[24],"m":"clc"},{"a":36342,"t":"code","b":[105,7],"m":"adc","o":"#$07"},{"a":36344,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36345,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36346,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36347,"t":"code","b":[133,42],"m":"sta","oa":42,"o":"zpa_2A"},{"a":36349,"t":"code","b":[165,36],"m":"lda","oa":36,"o":"clip_top"},{"a":36351,"t":"code","b":[240,34],"m":"beq","oa":36387,"o":"b_8E23"},{"a":36353,"t":"code","b":[133,20],"m":"sta","oa":20,"o":"zpa_14"},{"a":36355,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":36357,"t":"code","b":[162,8],"m":"ldx","o":"#$08"},{"a":36359,"l":"b_8E07","t":"code","b":[70,20],"m":"lsr","oa":20,"o":"zpa_14","x":[36370]},{"a":36361,"t":"code","b":[144,3],"m":"bcc","oa":36366,"o":"b_8E0E"},{"a":36363,"t":"code","b":[24],"m":"clc"},{"a":36364,"t":"code","b":[101,42],"m":"adc","oa":42,"o":"zpa_2A"},{"a":36366,"l":"b_8E0E","t":"code","b":[106],"m":"ror","o":"a","x":[36361]},{"a":36367,"t":"code","b":[102,18],"m":"ror","oa":18,"o":"zpa_12"},{"a":36369,"t":"code","b":[202],"m":"dex"},{"a":36370,"t":"code","b":[208,243],"m":"bne","oa":36359,"o":"b_8E07"},{"a":36372,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36374,"t":"code","b":[24],"m":"clc"},{"a":36375,"t":"code","b":[165,23],"m":"lda","oa":23,"o":"shape_ptr"},{"a":36377,"t":"code","b":[101,18],"m":"adc","oa":18,"o":"zpa_12"},{"a":36379,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":36381,"t":"code","b":[165,24],"m":"lda","oa":24,"o":"zpa_18"},{"a":36383,"t":"code","b":[101,19],"m":"adc","oa":19,"o":"zpa_13"},{"a":36385,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":36387,"l":"b_8E23","t":"code","b":[165,34],"m":"lda","oa":34,"o":"clip_left","x":[36351]},{"a":36389,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36390,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36391,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36392,"t":"code","b":[133,39],"m":"sta","oa":39,"o":"zpa_27"},{"a":36394,"t":"code","b":[165,34],"m":"lda","oa":34,"o":"clip_left"},{"a":36396,"t":"code","b":[41,7],"m":"and","o":"#$07"},{"a":36398,"t":"code","b":[133,20],"m":"sta","oa":20,"o":"zpa_14"},{"a":36400,"t":"code","b":[56],"m":"sec"},{"a":36401,"t":"code","b":[169,8],"m":"lda","o":"#$08"},{"a":36403,"t":"code","b":[229,20],"m":"sbc","oa":20,"o":"zpa_14"},{"a":36405,"t":"code","b":[133,38],"m":"sta","oa":38,"o":"zpa_26"},{"a":36407,"t":"code","b":[41,7],"m":"and","o":"#$07"},{"a":36409,"t":"code","b":[133,20],"m":"sta","oa":20,"o":"zpa_14"},{"a":36411,"t":"code","b":[165,9],"m":"lda","oa":9,"o":"draw_bit"},{"a":36413,"t":"code","b":[208,14],"m":"bne","oa":36429,"o":"b_8E4D"},{"a":36415,"t":"code","b":[165,20],"m":"lda","oa":20,"o":"zpa_14"},{"a":36417,"t":"code","b":[240,10],"m":"beq","oa":36429,"o":"b_8E4D"},{"a":36419,"t":"code","b":[230,39],"m":"inc","oa":39,"o":"zpa_27"},{"a":36421,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":36423,"t":"code","b":[41,248],"m":"and","o":"#$F8"},{"a":36425,"t":"code","b":[133,16],"m":"sta","oa":16,"o":"shape_w"},{"a":36427,"t":"code","b":[165,20],"m":"lda","oa":20,"o":"zpa_14"},{"a":36429,"l":"b_8E4D","t":"code","b":[72],"m":"pha","x":[36413,36417]},{"a":36430,"t":"code","b":[9,16],"m":"ora","o":"#$10"},{"a":36432,"t":"code","b":[133,67],"m":"sta","oa":67,"o":"zpa_43"},{"a":36434,"t":"code","b":[104],"m":"pla"},{"a":36435,"t":"code","b":[9,24],"m":"ora","o":"#$18"},{"a":36437,"t":"code","b":[133,69],"m":"sta","oa":69,"o":"zpa_45"},{"a":36439,"t":"code","b":[24],"m":"clc"},{"a":36440,"t":"code","b":[165,23],"m":"lda","oa":23,"o":"shape_ptr"},{"a":36442,"t":"code","b":[101,39],"m":"adc","oa":39,"o":"zpa_27"},{"a":36444,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":36446,"t":"code","b":[133,40],"m":"sta","oa":40,"o":"zpa_28"},{"a":36448,"t":"code","b":[165,24],"m":"lda","oa":24,"o":"zpa_18"},{"a":36450,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":36452,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":36454,"t":"code","b":[133,41],"m":"sta","oa":41,"o":"zpa_29"},{"a":36456,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":36458,"t":"code","b":[56],"m":"sec"},{"a":36459,"t":"code","b":[229,34],"m":"sbc","oa":34,"o":"clip_left"},{"a":36461,"t":"code","b":[229,35],"m":"sbc","oa":35,"o":"clip_right"},{"a":36463,"t":"code","b":[133,16],"m":"sta","oa":16,"o":"shape_w"},{"a":36465,"t":"code","b":[165,17],"m":"lda","oa":17,"o":"shape_h"},{"a":36467,"t":"code","b":[56],"m":"sec"},{"a":36468,"t":"code","b":[229,36],"m":"sbc","oa":36,"o":"clip_top"},{"a":36470,"t":"code","b":[229,37],"m":"sbc","oa":37,"o":"clip_bottom"},{"a":36472,"t":"code","b":[133,17],"m":"sta","oa":17,"o":"shape_h"},{"a":36474,"t":"code","b":[165,3],"m":"lda","oa":3,"o":"draw_row"},{"a":36476,"t":"code","b":[133,49],"m":"sta","oa":49,"o":"cur_row"},{"a":36478,"t":"code","b":[96],"m":"rts"},{"a":36479,"l":"setup_blit_row","c":"Sets up one row of a blit; both $8FD3 and $903E call it once per row. Copies the running source pointer zpa_28/29 into zpa_17/18 and advances $28/$29 by zpa_2A so the next call reads the next stored row. Clears zpa_0A (the destination byte offset), zpa_41 (the overflow carried from the byte to the left) and zpa_0D (the source byte index), and sets zpa_0E to the visible width zpa_10. Shifts the first source byte left by the sub-cell left clip and leaves it in zpa_16 with zpa_0C = zpa_26, the number of its bits still to come - only the bit-at-a-time mirrored blitter uses those two. Computes the destination address zpa_06/07 = $0A00,x + (zpa_04 and $F8), high byte ($0AA8,x eor zpa_0F) + zpa_05, with x = the current row zpa_31 ($31). If whole bytes were clipped off the left it reads the source byte just before the window and seeds zpa_41 with ($44),that byte, so the pixels that shift in from the clipped byte are not lost.","t":"code","b":[24],"m":"clc","x":[36841,36966]},{"a":36480,"t":"code","b":[165,40],"m":"lda","oa":40,"o":"zpa_28"},{"a":36482,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":36484,"t":"code","b":[101,42],"m":"adc","oa":42,"o":"zpa_2A"},{"a":36486,"t":"code","b":[133,40],"m":"sta","oa":40,"o":"zpa_28"},{"a":36488,"t":"code","b":[165,41],"m":"lda","oa":41,"o":"zpa_29"},{"a":36490,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":36492,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":36494,"t":"code","b":[133,41],"m":"sta","oa":41,"o":"zpa_29"},{"a":36496,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":36498,"t":"code","b":[133,14],"m":"sta","oa":14,"o":"zpa_0E"},{"a":36500,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":36502,"t":"code","b":[132,10],"m":"sty","oa":10,"o":"zpa_0A"},{"a":36504,"t":"code","b":[132,65],"m":"sty","oa":65,"o":"zpa_41"},{"a":36506,"t":"code","b":[132,13],"m":"sty","oa":13,"o":"zpa_0D"},{"a":36508,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":36510,"t":"code","b":[166,38],"m":"ldx","oa":38,"o":"zpa_26"},{"a":36512,"t":"code","b":[134,12],"m":"stx","oa":12,"o":"zpa_0C"},{"a":36514,"l":"j_8EA2","t":"code","b":[224,8],"m":"cpx","o":"#$08","x":[36520]},{"a":36516,"t":"code","b":[240,5],"m":"beq","oa":36523,"o":"b_8EAB"},{"a":36518,"t":"code","b":[10],"m":"asl","o":"a"},{"a":36519,"t":"code","b":[232],"m":"inx"},{"a":36520,"t":"code","b":[76,162,142],"m":"jmp","oa":36514,"o":"j_8EA2"},{"a":36523,"l":"b_8EAB","t":"code","b":[133,22],"m":"sta","oa":22,"o":"zpa_16","x":[36516]},{"a":36525,"t":"code","b":[166,49],"m":"ldx","oa":49,"o":"cur_row"},{"a":36527,"t":"code","b":[189,0,10],"m":"lda","oa":2560,"o":"bitmap_row_lo,x"},{"a":36530,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":36532,"t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x"},{"a":36534,"t":"code","b":[41,248],"m":"and","o":"#$F8"},{"a":36536,"t":"code","b":[24],"m":"clc"},{"a":36537,"t":"code","b":[101,6],"m":"adc","oa":6,"o":"bmp_ptr"},{"a":36539,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":36541,"t":"code","b":[189,168,10],"m":"lda","oa":2728,"o":"bitmap_row_hi,x"},{"a":36544,"t":"code","b":[69,15],"m":"eor","oa":15,"o":"vic_bank_bit"},{"a":36546,"t":"code","b":[101,5],"m":"adc","oa":5,"o":"zpa_05"},{"a":36548,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":36550,"t":"code","b":[165,39],"m":"lda","oa":39,"o":"zpa_27"},{"a":36552,"t":"code","b":[240,23],"m":"beq","oa":36577,"o":"r_8EE1"},{"a":36554,"t":"code","b":[165,23],"m":"lda","oa":23,"o":"shape_ptr"},{"a":36556,"t":"code","b":[208,2],"m":"bne","oa":36560,"o":"b_8ED0"},{"a":36558,"t":"code","b":[198,24],"m":"dec","oa":24,"o":"zpa_18"},{"a":36560,"l":"b_8ED0","t":"code","b":[198,23],"m":"dec","oa":23,"o":"shape_ptr","x":[36556]},{"a":36562,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":36564,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":36566,"t":"code","b":[168],"m":"tay"},{"a":36567,"t":"code","b":[177,68],"m":"lda","oa":68,"o":"(zpa_44),y"},{"a":36569,"t":"code","b":[133,65],"m":"sta","oa":65,"o":"zpa_41"},{"a":36571,"t":"code","b":[230,23],"m":"inc","oa":23,"o":"shape_ptr"},{"a":36573,"t":"code","b":[208,2],"m":"bne","oa":36577,"o":"r_8EE1"},{"a":36575,"t":"code","b":[230,24],"m":"inc","oa":24,"o":"zpa_18"},{"a":36577,"l":"r_8EE1","t":"code","b":[96],"m":"rts","x":[36552,36573]},{"a":36578,"l":"unpack_shape_header","c":"Unpacks the record whose address one of the inline-parameter wrappers has just put in zpa_37/38 ($37/$38). zpa_17/18 ($17/$18) = the record address, zpa_10 ($10) = byte 0 the width, zpa_11 ($11) = byte 1 the height in pixel rows, then $17/$18 is stepped past the two-byte header onto the data. For the 75 shapes at $80A1-$8A8A the width is in bitmap bits, two bits to a multicolour pixel, and each row takes ceil(width/8) bytes with the top row first; for the fill records $8C5E reads ($BB25, $0E44) the width is in character cells and the data is four pattern bytes. Called first by $8C5E, $8FD3, $903E, $90D2 and $90DF.","t":"code","b":[165,55],"m":"lda","oa":55,"o":"shape_hdr","x":[35940,36825,36940,37097]},{"a":36580,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":36582,"t":"code","b":[165,56],"m":"lda","oa":56,"o":"zpa_38"},{"a":36584,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":36586,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":36588,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":36590,"t":"code","b":[133,16],"m":"sta","oa":16,"o":"shape_w"},{"a":36592,"t":"code","b":[200],"m":"iny"},{"a":36593,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":36595,"t":"code","b":[133,17],"m":"sta","oa":17,"o":"shape_h"},{"a":36597,"t":"code","b":[24],"m":"clc"},{"a":36598,"t":"code","b":[165,23],"m":"lda","oa":23,"o":"shape_ptr"},{"a":36600,"t":"code","b":[105,2],"m":"adc","o":"#$02"},{"a":36602,"t":"code","b":[133,23],"m":"sta","oa":23,"o":"shape_ptr"},{"a":36604,"t":"code","b":[165,24],"m":"lda","oa":24,"o":"zpa_18"},{"a":36606,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":36608,"t":"code","b":[133,24],"m":"sta","oa":24,"o":"zpa_18"},{"a":36610,"t":"code","b":[96],"m":"rts"},{"a":36611,"l":"clip_object","c":"The clipper: decides whether an object is on screen, converts its world position to a screen position, and works out how much of its shape to throw away. Reads the width zpa_10 and height zpa_11 through zpa_37/38, clears the clip amounts via $8CFE, then compares the object's world X zpa_34/35 ($34/$35, loaded by $8BF9) against the window's left edge zpa_3B/3C ($3B/$3C) and its right edge $3B/$3C + $0140 - 320 bitmap bits, which is the 160 multicolour pixels of the 40-column screen - and its row zpa_36 ($36) against the row limits zpa_39 ($39, normally $A7 = 167) and zpa_3A ($3A). Outputs zpa_04/05 ($04/$05) the screen bit column of the left edge, zpa_03 ($03) the bitmap row of the top edge, zpa_22 bits cut off the left, zpa_23 bits cut off the right, zpa_24 rows cut off the top, zpa_25 rows cut off the bottom. Carry CLEAR means draw it; carry SET means it is entirely outside the window or the row limits, and every one of the twenty-six call sites branches past the blitter on bcs. A, X and Y are preserved. Note it is only a test and a subtraction: the caller at $ABB2 overwrites its answer with $8BAF.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[40447,41166,41213,41266,43688,43949,44099,44208,44535,45188,45385,45441,45562,45619,45694,46933,47361,47383,47436,47652,47724,47747,47773,47802,47827,47856,47900]},{"a":36613,"t":"code","b":[134,30],"m":"stx","oa":30,"o":"save_x"},{"a":36615,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":36617,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":36619,"t":"code","b":[177,55],"m":"lda","oa":55,"o":"(shape_hdr),y"},{"a":36621,"t":"code","b":[133,16],"m":"sta","oa":16,"o":"shape_w"},{"a":36623,"t":"code","b":[200],"m":"iny"},{"a":36624,"t":"code","b":[177,55],"m":"lda","oa":55,"o":"(shape_hdr),y"},{"a":36626,"t":"code","b":[133,17],"m":"sta","oa":17,"o":"shape_h"},{"a":36628,"t":"code","b":[32,254,140],"m":"jsr","oa":36094,"o":"clip_reset"},{"a":36631,"t":"code","b":[165,53],"m":"lda","oa":53,"o":"zpa_35"},{"a":36633,"t":"code","b":[197,60],"m":"cmp","oa":60,"o":"zpa_3C"},{"a":36635,"t":"code","b":[144,24],"m":"bcc","oa":36661,"o":"b_8F35"},{"a":36637,"t":"code","b":[208,6],"m":"bne","oa":36645,"o":"b_8F25"},{"a":36639,"t":"code","b":[165,52],"m":"lda","oa":52,"o":"arg3_lo"},{"a":36641,"t":"code","b":[197,59],"m":"cmp","oa":59,"o":"win_org"},{"a":36643,"t":"code","b":[144,16],"m":"bcc","oa":36661,"o":"b_8F35"},{"a":36645,"l":"b_8F25","t":"code","b":[56],"m":"sec","x":[36637]},{"a":36646,"t":"code","b":[165,52],"m":"lda","oa":52,"o":"arg3_lo"},{"a":36648,"t":"code","b":[229,59],"m":"sbc","oa":59,"o":"win_org"},{"a":36650,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":36652,"t":"code","b":[165,53],"m":"lda","oa":53,"o":"zpa_35"},{"a":36654,"t":"code","b":[229,60],"m":"sbc","oa":60,"o":"zpa_3C"},{"a":36656,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":36658,"t":"code","b":[76,92,143],"m":"jmp","oa":36700,"o":"j_8F5C"},{"a":36661,"l":"b_8F35","t":"code","b":[56],"m":"sec","x":[36635,36643]},{"a":36662,"t":"code","b":[165,59],"m":"lda","oa":59,"o":"win_org"},{"a":36664,"t":"code","b":[229,52],"m":"sbc","oa":52,"o":"arg3_lo"},{"a":36666,"t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12"},{"a":36668,"t":"code","b":[165,60],"m":"lda","oa":60,"o":"zpa_3C"},{"a":36670,"t":"code","b":[229,53],"m":"sbc","oa":53,"o":"zpa_35"},{"a":36672,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36674,"t":"code","b":[165,19],"m":"lda","oa":19,"o":"zpa_13"},{"a":36676,"t":"code","b":[208,19],"m":"bne","oa":36697,"o":"b_8F59"},{"a":36678,"t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12"},{"a":36680,"t":"code","b":[197,16],"m":"cmp","oa":16,"o":"shape_w"},{"a":36682,"t":"code","b":[176,13],"m":"bcs","oa":36697,"o":"b_8F59"},{"a":36684,"t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12"},{"a":36686,"t":"code","b":[133,34],"m":"sta","oa":34,"o":"clip_left"},{"a":36688,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":36690,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":36692,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":36694,"t":"code","b":[76,151,143],"m":"jmp","oa":36759,"o":"j_8F97"},{"a":36697,"l":"b_8F59","t":"code","b":[56],"m":"sec","x":[36676,36682,36717,36725,36727]},{"a":36698,"t":"code","b":[176,112],"m":"bcs","oa":36812,"o":"b_8FCC"},{"a":36700,"l":"j_8F5C","t":"code","b":[24],"m":"clc","x":[36658]},{"a":36701,"t":"code","b":[165,59],"m":"lda","oa":59,"o":"win_org"},{"a":36703,"t":"code","b":[105,64],"m":"adc","o":"#$40"},{"a":36705,"t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12"},{"a":36707,"t":"code","b":[165,60],"m":"lda","oa":60,"o":"zpa_3C"},{"a":36709,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":36711,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36713,"t":"code","b":[165,19],"m":"lda","oa":19,"o":"zpa_13"},{"a":36715,"t":"code","b":[197,53],"m":"cmp","oa":53,"o":"zpa_35"},{"a":36717,"t":"code","b":[144,234],"m":"bcc","oa":36697,"o":"b_8F59"},{"a":36719,"t":"code","b":[208,8],"m":"bne","oa":36729,"o":"b_8F79"},{"a":36721,"t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12"},{"a":36723,"t":"code","b":[197,52],"m":"cmp","oa":52,"o":"arg3_lo"},{"a":36725,"t":"code","b":[144,226],"m":"bcc","oa":36697,"o":"b_8F59"},{"a":36727,"t":"code","b":[240,224],"m":"beq","oa":36697,"o":"b_8F59"},{"a":36729,"l":"b_8F79","t":"code","b":[56],"m":"sec","x":[36719]},{"a":36730,"t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12"},{"a":36732,"t":"code","b":[229,52],"m":"sbc","oa":52,"o":"arg3_lo"},{"a":36734,"t":"code","b":[133,18],"m":"sta","oa":18,"o":"zpa_12"},{"a":36736,"t":"code","b":[165,19],"m":"lda","oa":19,"o":"zpa_13"},{"a":36738,"t":"code","b":[229,53],"m":"sbc","oa":53,"o":"zpa_35"},{"a":36740,"t":"code","b":[133,19],"m":"sta","oa":19,"o":"zpa_13"},{"a":36742,"t":"code","b":[165,19],"m":"lda","oa":19,"o":"zpa_13"},{"a":36744,"t":"code","b":[208,13],"m":"bne","oa":36759,"o":"j_8F97"},{"a":36746,"t":"code","b":[165,18],"m":"lda","oa":18,"o":"zpa_12"},{"a":36748,"t":"code","b":[197,16],"m":"cmp","oa":16,"o":"shape_w"},{"a":36750,"t":"code","b":[176,7],"m":"bcs","oa":36759,"o":"j_8F97"},{"a":36752,"t":"code","b":[56],"m":"sec"},{"a":36753,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":36755,"t":"code","b":[229,18],"m":"sbc","oa":18,"o":"zpa_12"},{"a":36757,"t":"code","b":[133,35],"m":"sta","oa":35,"o":"clip_right"},{"a":36759,"l":"j_8F97","t":"code","b":[165,54],"m":"lda","oa":54,"o":"zpa_36","x":[36694,36744,36750]},{"a":36761,"t":"code","b":[133,3],"m":"sta","oa":3,"o":"draw_row"},{"a":36763,"t":"code","b":[165,57],"m":"lda","oa":57,"o":"clip_row_hi"},{"a":36765,"t":"code","b":[197,54],"m":"cmp","oa":54,"o":"zpa_36"},{"a":36767,"t":"code","b":[176,21],"m":"bcs","oa":36790,"o":"b_8FB6"},{"a":36769,"t":"code","b":[56],"m":"sec"},{"a":36770,"t":"code","b":[165,54],"m":"lda","oa":54,"o":"zpa_36"},{"a":36772,"t":"code","b":[229,57],"m":"sbc","oa":57,"o":"clip_row_hi"},{"a":36774,"t":"code","b":[197,17],"m":"cmp","oa":17,"o":"shape_h"},{"a":36776,"t":"code","b":[176,9],"m":"bcs","oa":36787,"o":"b_8FB3"},{"a":36778,"t":"code","b":[133,36],"m":"sta","oa":36,"o":"clip_top"},{"a":36780,"t":"code","b":[165,57],"m":"lda","oa":57,"o":"clip_row_hi"},{"a":36782,"t":"code","b":[133,3],"m":"sta","oa":3,"o":"draw_row"},{"a":36784,"t":"code","b":[76,203,143],"m":"jmp","oa":36811,"o":"j_8FCB"},{"a":36787,"l":"b_8FB3","t":"code","b":[56],"m":"sec","x":[36776,36793,36797]},{"a":36788,"t":"code","b":[176,22],"m":"bcs","oa":36812,"o":"b_8FCC"},{"a":36790,"l":"b_8FB6","t":"code","b":[56],"m":"sec","x":[36767]},{"a":36791,"t":"code","b":[165,54],"m":"lda","oa":54,"o":"zpa_36"},{"a":36793,"t":"code","b":[240,248],"m":"beq","oa":36787,"o":"b_8FB3"},{"a":36795,"t":"code","b":[229,58],"m":"sbc","oa":58,"o":"clip_row_lo"},{"a":36797,"t":"code","b":[144,244],"m":"bcc","oa":36787,"o":"b_8FB3"},{"a":36799,"t":"code","b":[56],"m":"sec"},{"a":36800,"t":"code","b":[229,17],"m":"sbc","oa":17,"o":"shape_h"},{"a":36802,"t":"code","b":[176,7],"m":"bcs","oa":36811,"o":"j_8FCB"},{"a":36804,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":36806,"t":"code","b":[24],"m":"clc"},{"a":36807,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":36809,"t":"code","b":[133,37],"m":"sta","oa":37,"o":"clip_bottom"},{"a":36811,"l":"j_8FCB","t":"code","b":[24],"m":"clc","x":[36784,36802]},{"a":36812,"l":"b_8FCC","t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a","x":[36698,36788]},{"a":36814,"t":"code","b":[166,30],"m":"ldx","oa":30,"o":"save_x"},{"a":36816,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":36818,"t":"code","b":[96],"m":"rts"},{"a":36819,"l":"draw_shape","c":"Draws a shape into the bitmap, ORed over whatever is already there, in its stored facing. The sequence at every call site is $8BF9 with the position record, $8BE0 with the shape pointer, $8F03 to clip, bcs to skip, then this. It unpacks the header ($8EE2), splits the screen X ($8DC8) and flips zpa_09 back to X and 7 because the shape is shifted right, then applies the clip and picks the shift tables ($8DF3). For each row, top row first, working DOWN the screen by decrementing zpa_31 ($31) - the row tables number rows upward from the bottom of the play area - $8E7F sets the destination up and then a byte at a time it ORs ($42),byte, the source byte shifted right, with the overflow zpa_41 kept from the byte to its left, ORs the result into the bitmap at ($06),y, and saves ($44),byte as the new overflow. y steps by 8 because neighbouring character cells are 8 bytes apart in a bitmap. After the last byte the trailing overflow is written too, unless the row ended exactly at column 40. A, X and Y are preserved.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[40461,41185,41223,41276,43698,44211,44552,45191,45395,45451,45572,45636,45704,46949,47366,47400,47447,47664,47778,47812,47867,47905]},{"a":36821,"t":"code","b":[134,30],"m":"stx","oa":30,"o":"save_x"},{"a":36823,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":36825,"t":"code","b":[32,226,142],"m":"jsr","oa":36578,"o":"unpack_shape_header"},{"a":36828,"t":"code","b":[32,200,141],"m":"jsr","oa":36296,"o":"split_screen_x"},{"a":36831,"t":"code","b":[169,8],"m":"lda","o":"#$08"},{"a":36833,"t":"code","b":[56],"m":"sec"},{"a":36834,"t":"code","b":[229,9],"m":"sbc","oa":9,"o":"draw_bit"},{"a":36836,"t":"code","b":[133,9],"m":"sta","oa":9,"o":"draw_bit"},{"a":36838,"t":"code","b":[32,243,141],"m":"jsr","oa":36339,"o":"apply_clip"},{"a":36841,"l":"j_8FE9","t":"code","b":[32,127,142],"m":"jsr","oa":36479,"o":"setup_blit_row","x":[36916]},{"a":36844,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":36846,"t":"code","b":[24],"m":"clc"},{"a":36847,"t":"code","b":[105,7],"m":"adc","o":"#$07"},{"a":36849,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36850,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36851,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":36852,"t":"code","b":[133,14],"m":"sta","oa":14,"o":"zpa_0E"},{"a":36854,"t":"code","b":[133,25],"m":"sta","oa":25,"o":"zpa_19"},{"a":36856,"t":"code","b":[240,44],"m":"beq","oa":36902,"o":"b_9026"},{"a":36858,"t":"code","b":[48,42],"m":"bmi","oa":36902,"o":"b_9026"},{"a":36860,"l":"b_8FFC","t":"code","b":[164,13],"m":"ldy","oa":13,"o":"zpa_0D","x":[36891]},{"a":36862,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":36864,"t":"code","b":[168],"m":"tay"},{"a":36865,"t":"code","b":[177,66],"m":"lda","oa":66,"o":"(zpa_42),y"},{"a":36867,"t":"code","b":[5,65],"m":"ora","oa":65,"o":"zpa_41"},{"a":36869,"t":"code","b":[72],"m":"pha"},{"a":36870,"t":"code","b":[177,68],"m":"lda","oa":68,"o":"(zpa_44),y"},{"a":36872,"t":"code","b":[133,65],"m":"sta","oa":65,"o":"zpa_41"},{"a":36874,"t":"code","b":[104],"m":"pla"},{"a":36875,"t":"code","b":[164,10],"m":"ldy","oa":10,"o":"zpa_0A"},{"a":36877,"t":"code","b":[17,6],"m":"ora","oa":6,"o":"(bmp_ptr),y"},{"a":36879,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":36881,"t":"code","b":[230,13],"m":"inc","oa":13,"o":"zpa_0D"},{"a":36883,"t":"code","b":[152],"m":"tya"},{"a":36884,"t":"code","b":[24],"m":"clc"},{"a":36885,"t":"code","b":[105,8],"m":"adc","o":"#$08"},{"a":36887,"t":"code","b":[133,10],"m":"sta","oa":10,"o":"zpa_0A"},{"a":36889,"t":"code","b":[198,14],"m":"dec","oa":14,"o":"zpa_0E"},{"a":36891,"t":"code","b":[208,223],"m":"bne","oa":36860,"o":"b_8FFC"},{"a":36893,"t":"code","b":[165,25],"m":"lda","oa":25,"o":"zpa_19"},{"a":36895,"t":"code","b":[24],"m":"clc"},{"a":36896,"t":"code","b":[101,8],"m":"adc","oa":8,"o":"draw_col"},{"a":36898,"t":"code","b":[201,40],"m":"cmp","o":"#$28"},{"a":36900,"t":"code","b":[240,8],"m":"beq","oa":36910,"o":"b_902E"},{"a":36902,"l":"b_9026","t":"code","b":[165,65],"m":"lda","oa":65,"o":"zpa_41","x":[36856,36858]},{"a":36904,"t":"code","b":[164,10],"m":"ldy","oa":10,"o":"zpa_0A"},{"a":36906,"t":"code","b":[17,6],"m":"ora","oa":6,"o":"(bmp_ptr),y"},{"a":36908,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":36910,"l":"b_902E","t":"code","b":[198,17],"m":"dec","oa":17,"o":"shape_h","x":[36900]},{"a":36912,"t":"code","b":[240,5],"m":"beq","oa":36919,"o":"b_9037"},{"a":36914,"t":"code","b":[198,49],"m":"dec","oa":49,"o":"cur_row"},{"a":36916,"t":"code","b":[76,233,143],"m":"jmp","oa":36841,"o":"j_8FE9"},{"a":36919,"l":"b_9037","t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a","x":[36912]},{"a":36921,"t":"code","b":[166,30],"m":"ldx","oa":30,"o":"save_x"},{"a":36923,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":36925,"t":"code","b":[96],"m":"rts"},{"a":36926,"l":"draw_shape_mirrored","c":"Draws a shape into the bitmap flipped left to right; callers pick between this and $8FD3 on a per-actor direction flag, for instance bit 7 of $0B77,x tested at $AE06 and zpa_77 at $9E0B, which is how one stored helicopter, jet or walking figure serves both headings. It first swaps zpa_22 and zpa_23 so the left and right clips change sides, unpacks and clips exactly as $8FD3 does, then calls $8D7D to find the character cell of the shape's RIGHT-hand end and works leftwards from it, stepping the destination back 8 bytes a cell. It cannot use the byte-wide pre-shift tables, so it walks each row a bit at a time: asl takes the leftmost remaining source bit and ror zpa_19 feeds it into the top of the output byte, which reverses the eight bits; zpa_0C counts the bits left in the current source byte, zpa_0E the bits left in the row, and a part-filled last byte is shifted down with lsr before being ORed in. The reversal is bit-exact, so it also exchanges the two bits inside each multicolour pixel pair and the mirrored copy sits on the opposite pixel-pair parity from the same data drawn by $8FD3. Checked against the live screen for the plateau: shape 66 ($89D8) drawn here at $BA8E produced the bit-reversed rows and the same shape drawn by $8FD3 at $BAA2, 127 bitmap bits further right, produced the plain rows, and the two form the hill's two slopes. A, X and Y are preserved.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[40464,41191,44558,45642,46956,47453,47758,47832]},{"a":36928,"t":"code","b":[134,30],"m":"stx","oa":30,"o":"save_x"},{"a":36930,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":36932,"t":"code","b":[166,34],"m":"ldx","oa":34,"o":"clip_left"},{"a":36934,"t":"code","b":[164,35],"m":"ldy","oa":35,"o":"clip_right"},{"a":36936,"t":"code","b":[132,34],"m":"sty","oa":34,"o":"clip_left"},{"a":36938,"t":"code","b":[134,35],"m":"stx","oa":35,"o":"clip_right"},{"a":36940,"t":"code","b":[32,226,142],"m":"jsr","oa":36578,"o":"unpack_shape_header"},{"a":36943,"t":"code","b":[32,200,141],"m":"jsr","oa":36296,"o":"split_screen_x"},{"a":36946,"t":"code","b":[32,243,141],"m":"jsr","oa":36339,"o":"apply_clip"},{"a":36949,"t":"code","b":[165,8],"m":"lda","oa":8,"o":"draw_col"},{"a":36951,"t":"code","b":[133,21],"m":"sta","oa":21,"o":"zpa_15"},{"a":36953,"t":"code","b":[32,125,141],"m":"jsr","oa":36221,"o":"x_to_right_end"},{"a":36956,"t":"code","b":[165,8],"m":"lda","oa":8,"o":"draw_col"},{"a":36958,"t":"code","b":[56],"m":"sec"},{"a":36959,"t":"code","b":[229,21],"m":"sbc","oa":21,"o":"zpa_15"},{"a":36961,"t":"code","b":[10],"m":"asl","o":"a"},{"a":36962,"t":"code","b":[10],"m":"asl","o":"a"},{"a":36963,"t":"code","b":[10],"m":"asl","o":"a"},{"a":36964,"t":"code","b":[133,21],"m":"sta","oa":21,"o":"zpa_15"},{"a":36966,"l":"j_9066","t":"code","b":[32,127,142],"m":"jsr","oa":36479,"o":"setup_blit_row","x":[37045]},{"a":36969,"t":"code","b":[165,21],"m":"lda","oa":21,"o":"zpa_15"},{"a":36971,"t":"code","b":[133,10],"m":"sta","oa":10,"o":"zpa_0A"},{"a":36973,"t":"code","b":[56],"m":"sec"},{"a":36974,"t":"code","b":[169,9],"m":"lda","o":"#$09"},{"a":36976,"t":"code","b":[229,9],"m":"sbc","oa":9,"o":"draw_bit"},{"a":36978,"t":"code","b":[170],"m":"tax"},{"a":36979,"l":"j_9073","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[37020]},{"a":36981,"t":"code","b":[133,25],"m":"sta","oa":25,"o":"zpa_19"},{"a":36983,"t":"code","b":[164,12],"m":"ldy","oa":12,"o":"zpa_0C"},{"a":36985,"t":"code","b":[165,22],"m":"lda","oa":22,"o":"zpa_16"},{"a":36987,"l":"b_907B","t":"code","b":[10],"m":"asl","o":"a","x":[36998]},{"a":36988,"t":"code","b":[102,25],"m":"ror","oa":25,"o":"zpa_19"},{"a":36990,"t":"code","b":[136],"m":"dey"},{"a":36991,"t":"code","b":[240,55],"m":"beq","oa":37048,"o":"b_90B8"},{"a":36993,"l":"j_9081","t":"code","b":[198,14],"m":"dec","oa":14,"o":"zpa_0E","x":[37056]},{"a":36995,"t":"code","b":[240,26],"m":"beq","oa":37023,"o":"b_909F"},{"a":36997,"t":"code","b":[202],"m":"dex"},{"a":36998,"t":"code","b":[208,243],"m":"bne","oa":36987,"o":"b_907B"},{"a":37000,"t":"code","b":[132,12],"m":"sty","oa":12,"o":"zpa_0C"},{"a":37002,"t":"code","b":[133,22],"m":"sta","oa":22,"o":"zpa_16"},{"a":37004,"t":"code","b":[164,10],"m":"ldy","oa":10,"o":"zpa_0A"},{"a":37006,"t":"code","b":[177,6],"m":"lda","oa":6,"o":"(bmp_ptr),y"},{"a":37008,"t":"code","b":[5,25],"m":"ora","oa":25,"o":"zpa_19"},{"a":37010,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":37012,"t":"code","b":[152],"m":"tya"},{"a":37013,"t":"code","b":[56],"m":"sec"},{"a":37014,"t":"code","b":[233,8],"m":"sbc","o":"#$08"},{"a":37016,"t":"code","b":[133,10],"m":"sta","oa":10,"o":"zpa_0A"},{"a":37018,"t":"code","b":[162,8],"m":"ldx","o":"#$08"},{"a":37020,"t":"code","b":[76,115,144],"m":"jmp","oa":36979,"o":"j_9073"},{"a":37023,"l":"b_909F","t":"code","b":[202],"m":"dex","x":[36995]},{"a":37024,"t":"code","b":[240,5],"m":"beq","oa":37031,"o":"b_90A7"},{"a":37026,"l":"b_90A2","t":"code","b":[70,25],"m":"lsr","oa":25,"o":"zpa_19","x":[37029]},{"a":37028,"t":"code","b":[202],"m":"dex"},{"a":37029,"t":"code","b":[208,251],"m":"bne","oa":37026,"o":"b_90A2"},{"a":37031,"l":"b_90A7","t":"code","b":[164,10],"m":"ldy","oa":10,"o":"zpa_0A","x":[37024]},{"a":37033,"t":"code","b":[177,6],"m":"lda","oa":6,"o":"(bmp_ptr),y"},{"a":37035,"t":"code","b":[5,25],"m":"ora","oa":25,"o":"zpa_19"},{"a":37037,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":37039,"t":"code","b":[198,17],"m":"dec","oa":17,"o":"shape_h"},{"a":37041,"t":"code","b":[240,16],"m":"beq","oa":37059,"o":"b_90C3"},{"a":37043,"t":"code","b":[198,49],"m":"dec","oa":49,"o":"cur_row"},{"a":37045,"t":"code","b":[76,102,144],"m":"jmp","oa":36966,"o":"j_9066"},{"a":37048,"l":"b_90B8","t":"code","b":[230,13],"m":"inc","oa":13,"o":"zpa_0D","x":[36991]},{"a":37050,"t":"code","b":[164,13],"m":"ldy","oa":13,"o":"zpa_0D"},{"a":37052,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":37054,"t":"code","b":[160,8],"m":"ldy","o":"#$08"},{"a":37056,"t":"code","b":[76,129,144],"m":"jmp","oa":36993,"o":"j_9081"},{"a":37059,"l":"b_90C3","t":"code","b":[166,34],"m":"ldx","oa":34,"o":"clip_left","x":[37041]},{"a":37061,"t":"code","b":[164,35],"m":"ldy","oa":35,"o":"clip_right"},{"a":37063,"t":"code","b":[132,34],"m":"sty","oa":34,"o":"clip_left"},{"a":37065,"t":"code","b":[134,35],"m":"stx","oa":35,"o":"clip_right"},{"a":37067,"t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a"},{"a":37069,"t":"code","b":[166,30],"m":"ldx","oa":30,"o":"save_x"},{"a":37071,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":37073,"t":"code","b":[96],"m":"rts"},{"a":37074,"l":"draw_sheared_shape","c":"Draw a shape into the back buffer with a shear, unmirrored entry. Preserves A/X/Y through $1D/$1E/$1F, clears the mirror flag $2F and jumps over the second entry to the shared loop at $90E9. Inputs: $37/$38 the shape pointer (width in bitmap bits, height in rows, then ceil(width/8) bytes per row), $2B/$2C the shear that $8C30 looked up from the helicopter's tilt (step $2C destination rows for every $2B source columns), the destination in $04/$05 and $03 that $8F03 worked out from the position $A9A0 left in $67/$68/$69, and $0F the $40 that picks the buffer being drawn. Callers: $AC46 for the spinning main-rotor bar, and entries 3, 4 and 5 of the draw-routine pointer table at $ABBF for the helicopter body at turn $59 = 0, +1 and +2. Unlike the fast blitters $8FD3 and $903E this one plots one bit at a time, which is what lets it slope.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a","x":[44102]},{"a":37076,"t":"code","b":[134,30],"m":"stx","oa":30,"o":"save_x"},{"a":37078,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":37080,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":37082,"t":"code","b":[133,47],"m":"sta","oa":47,"o":"draw_mirror"},{"a":37084,"t":"code","b":[76,233,144],"m":"jmp","oa":37097,"o":"j_90E9"},{"a":37087,"l":"draw_sheared_shape_mirrored","c":"Mirrored entry of the sheared shape drawer. Identical to $90D2 except that $2F is set to $FF instead of $00, and then it falls into the same loop at $90E9. The flag reverses two things: at $91A3 the multicolour bit mask $0C walks left (asl) instead of right (lsr), and at $9203 the byte column steps the opposite way. Reached only through the pointer table at $ABBF, entries 1 and 2, i.e. the helicopter body when the turn state $59 is -2 or -1.","t":"code","b":[133,29],"m":"sta","oa":29,"o":"save_a"},{"a":37089,"t":"code","b":[134,30],"m":"stx","oa":30,"o":"save_x"},{"a":37091,"t":"code","b":[132,31],"m":"sty","oa":31,"o":"save_y"},{"a":37093,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":37095,"t":"code","b":[133,47],"m":"sta","oa":47,"o":"draw_mirror"},{"a":37097,"l":"j_90E9","c":"The sheared-blit loop shared by $90D2 and $90DF. $8EE2 reads the shape's width into $10 and height into $11 and leaves $17/$18 on the first row of bits; $8D98 applies the mirror flag to the start column and builds the bit mask, $8DC8 the byte column. It then walks the shape one source bit at a time, ORing a single bit mask $0C into ($06),y wherever the source bit is set. Two counters give the slope: $32 counts $2B source columns and then moves the destination down by $2C rows (re-fetching $06/$07 from the row tables $0A00/$0AA8, high byte EORed with $0F), and $30 counts $2B output rows and then steps the byte column in $08/$09, in the direction of $2C EOR $2F. Height counts down in $11; it exits at $9221 restoring A/X/Y from $1D/$1E/$1F.","t":"code","b":[32,226,142],"m":"jsr","oa":36578,"o":"unpack_shape_header","x":[37084]},{"a":37100,"t":"code","b":[32,152,141],"m":"jsr","oa":36248,"o":"bit_mask_for_x"},{"a":37103,"t":"code","b":[165,3],"m":"lda","oa":3,"o":"draw_row"},{"a":37105,"t":"code","b":[133,11],"m":"sta","oa":11,"o":"zpa_0B"},{"a":37107,"t":"code","b":[165,43],"m":"lda","oa":43,"o":"slope_run"},{"a":37109,"t":"code","b":[133,48],"m":"sta","oa":48,"o":"zpa_30"},{"a":37111,"t":"code","b":[56],"m":"sec"},{"a":37112,"t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x"},{"a":37114,"t":"code","b":[233,128],"m":"sbc","o":"#$80"},{"a":37116,"t":"code","b":[133,4],"m":"sta","oa":4,"o":"draw_x"},{"a":37118,"t":"code","b":[165,5],"m":"lda","oa":5,"o":"zpa_05"},{"a":37120,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":37122,"t":"code","b":[133,5],"m":"sta","oa":5,"o":"zpa_05"},{"a":37124,"l":"j_9104","t":"code","b":[165,43],"m":"lda","oa":43,"o":"slope_run","x":[37370,37406]},{"a":37126,"t":"code","b":[133,50],"m":"sta","oa":50,"o":"zpa_32"},{"a":37128,"t":"code","b":[165,48],"m":"lda","oa":48,"o":"zpa_30"},{"a":37130,"t":"code","b":[133,51],"m":"sta","oa":51,"o":"zpa_33"},{"a":37132,"t":"code","b":[166,11],"m":"ldx","oa":11,"o":"zpa_0B"},{"a":37134,"t":"code","b":[134,49],"m":"stx","oa":49,"o":"cur_row"},{"a":37136,"t":"code","b":[189,0,10],"m":"lda","oa":2560,"o":"bitmap_row_lo,x"},{"a":37139,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":37141,"t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x"},{"a":37143,"t":"code","b":[41,248],"m":"and","o":"#$F8"},{"a":37145,"t":"code","b":[24],"m":"clc"},{"a":37146,"t":"code","b":[101,6],"m":"adc","oa":6,"o":"bmp_ptr"},{"a":37148,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":37150,"t":"code","b":[189,168,10],"m":"lda","oa":2728,"o":"bitmap_row_hi,x"},{"a":37153,"t":"code","b":[69,15],"m":"eor","oa":15,"o":"vic_bank_bit"},{"a":37155,"t":"code","b":[101,5],"m":"adc","oa":5,"o":"zpa_05"},{"a":37157,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":37159,"t":"code","b":[165,9],"m":"lda","oa":9,"o":"draw_bit"},{"a":37161,"t":"code","b":[133,20],"m":"sta","oa":20,"o":"zpa_14"},{"a":37163,"t":"code","b":[165,8],"m":"lda","oa":8,"o":"draw_col"},{"a":37165,"t":"code","b":[133,21],"m":"sta","oa":21,"o":"zpa_15"},{"a":37167,"t":"code","b":[32,200,141],"m":"jsr","oa":36296,"o":"split_screen_x"},{"a":37170,"t":"code","b":[165,21],"m":"lda","oa":21,"o":"zpa_15"},{"a":37172,"t":"code","b":[56],"m":"sec"},{"a":37173,"t":"code","b":[229,8],"m":"sbc","oa":8,"o":"draw_col"},{"a":37175,"t":"code","b":[10],"m":"asl","o":"a"},{"a":37176,"t":"code","b":[10],"m":"asl","o":"a"},{"a":37177,"t":"code","b":[10],"m":"asl","o":"a"},{"a":37178,"t":"code","b":[133,13],"m":"sta","oa":13,"o":"zpa_0D"},{"a":37180,"t":"code","b":[165,21],"m":"lda","oa":21,"o":"zpa_15"},{"a":37182,"t":"code","b":[133,8],"m":"sta","oa":8,"o":"draw_col"},{"a":37184,"t":"code","b":[165,20],"m":"lda","oa":20,"o":"zpa_14"},{"a":37186,"t":"code","b":[133,9],"m":"sta","oa":9,"o":"draw_bit"},{"a":37188,"t":"code","b":[133,12],"m":"sta","oa":12,"o":"zpa_0C"},{"a":37190,"t":"code","b":[165,16],"m":"lda","oa":16,"o":"shape_w"},{"a":37192,"t":"code","b":[133,14],"m":"sta","oa":14,"o":"zpa_0E"},{"a":37194,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":37196,"t":"code","b":[132,26],"m":"sty","oa":26,"o":"zpa_1A"},{"a":37198,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":37200,"t":"code","b":[133,22],"m":"sta","oa":22,"o":"zpa_16"},{"a":37202,"l":"j_9152","t":"code","b":[6,22],"m":"asl","oa":22,"o":"zpa_16","x":[37332,37351]},{"a":37204,"t":"code","b":[144,8],"m":"bcc","oa":37214,"o":"b_915E"},{"a":37206,"t":"code","b":[165,12],"m":"lda","oa":12,"o":"zpa_0C"},{"a":37208,"t":"code","b":[164,13],"m":"ldy","oa":13,"o":"zpa_0D"},{"a":37210,"t":"code","b":[17,6],"m":"ora","oa":6,"o":"(bmp_ptr),y"},{"a":37212,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":37214,"l":"b_915E","t":"code","b":[198,50],"m":"dec","oa":50,"o":"zpa_32","x":[37204]},{"a":37216,"t":"code","b":[208,65],"m":"bne","oa":37283,"o":"b_91A3"},{"a":37218,"t":"code","b":[165,43],"m":"lda","oa":43,"o":"slope_run"},{"a":37220,"t":"code","b":[133,50],"m":"sta","oa":50,"o":"zpa_32"},{"a":37222,"t":"code","b":[24],"m":"clc"},{"a":37223,"t":"code","b":[165,49],"m":"lda","oa":49,"o":"cur_row"},{"a":37225,"t":"code","b":[101,44],"m":"adc","oa":44,"o":"slope_step"},{"a":37227,"t":"code","b":[133,49],"m":"sta","oa":49,"o":"cur_row"},{"a":37229,"t":"code","b":[170],"m":"tax"},{"a":37230,"t":"code","b":[189,0,10],"m":"lda","oa":2560,"o":"bitmap_row_lo,x"},{"a":37233,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":37235,"t":"code","b":[165,4],"m":"lda","oa":4,"o":"draw_x"},{"a":37237,"t":"code","b":[41,248],"m":"and","o":"#$F8"},{"a":37239,"t":"code","b":[24],"m":"clc"},{"a":37240,"t":"code","b":[101,6],"m":"adc","oa":6,"o":"bmp_ptr"},{"a":37242,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":37244,"t":"code","b":[189,168,10],"m":"lda","oa":2728,"o":"bitmap_row_hi,x"},{"a":37247,"t":"code","b":[69,15],"m":"eor","oa":15,"o":"vic_bank_bit"},{"a":37249,"t":"code","b":[101,5],"m":"adc","oa":5,"o":"zpa_05"},{"a":37251,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":37253,"t":"code","b":[24],"m":"clc"},{"a":37254,"t":"code","b":[165,51],"m":"lda","oa":51,"o":"zpa_33"},{"a":37256,"t":"code","b":[101,44],"m":"adc","oa":44,"o":"slope_step"},{"a":37258,"t":"code","b":[133,51],"m":"sta","oa":51,"o":"zpa_33"},{"a":37260,"t":"code","b":[240,7],"m":"beq","oa":37269,"o":"b_9195"},{"a":37262,"t":"code","b":[197,43],"m":"cmp","oa":43,"o":"slope_run"},{"a":37264,"t":"code","b":[176,10],"m":"bcs","oa":37276,"o":"b_919C"},{"a":37266,"t":"code","b":[76,163,145],"m":"jmp","oa":37283,"o":"b_91A3"},{"a":37269,"l":"b_9195","t":"code","b":[165,43],"m":"lda","oa":43,"o":"slope_run","x":[37260]},{"a":37271,"t":"code","b":[133,51],"m":"sta","oa":51,"o":"zpa_33"},{"a":37273,"t":"code","b":[76,200,145],"m":"jmp","oa":37320,"o":"j_91C8"},{"a":37276,"l":"b_919C","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[37264]},{"a":37278,"t":"code","b":[133,51],"m":"sta","oa":51,"o":"zpa_33"},{"a":37280,"t":"code","b":[76,200,145],"m":"jmp","oa":37320,"o":"j_91C8"},{"a":37283,"l":"b_91A3","t":"code","b":[36,47],"m":"bit","oa":47,"o":"draw_mirror","x":[37216,37266]},{"a":37285,"t":"code","b":[48,18],"m":"bmi","oa":37305,"o":"b_91B9"},{"a":37287,"t":"code","b":[70,12],"m":"lsr","oa":12,"o":"zpa_0C"},{"a":37289,"t":"code","b":[208,29],"m":"bne","oa":37320,"o":"j_91C8"},{"a":37291,"t":"code","b":[169,128],"m":"lda","o":"#$80"},{"a":37293,"t":"code","b":[133,12],"m":"sta","oa":12,"o":"zpa_0C"},{"a":37295,"t":"code","b":[165,13],"m":"lda","oa":13,"o":"zpa_0D"},{"a":37297,"t":"code","b":[24],"m":"clc"},{"a":37298,"t":"code","b":[105,8],"m":"adc","o":"#$08"},{"a":37300,"t":"code","b":[133,13],"m":"sta","oa":13,"o":"zpa_0D"},{"a":37302,"t":"code","b":[76,200,145],"m":"jmp","oa":37320,"o":"j_91C8"},{"a":37305,"l":"b_91B9","t":"code","b":[6,12],"m":"asl","oa":12,"o":"zpa_0C","x":[37285]},{"a":37307,"t":"code","b":[208,11],"m":"bne","oa":37320,"o":"j_91C8"},{"a":37309,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":37311,"t":"code","b":[133,12],"m":"sta","oa":12,"o":"zpa_0C"},{"a":37313,"t":"code","b":[165,13],"m":"lda","oa":13,"o":"zpa_0D"},{"a":37315,"t":"code","b":[56],"m":"sec"},{"a":37316,"t":"code","b":[233,8],"m":"sbc","o":"#$08"},{"a":37318,"t":"code","b":[133,13],"m":"sta","oa":13,"o":"zpa_0D"},{"a":37320,"l":"j_91C8","t":"code","b":[198,14],"m":"dec","oa":14,"o":"zpa_0E","x":[37273,37280,37289,37302,37307]},{"a":37322,"t":"code","b":[240,30],"m":"beq","oa":37354,"o":"b_91EA"},{"a":37324,"t":"code","b":[230,26],"m":"inc","oa":26,"o":"zpa_1A"},{"a":37326,"t":"code","b":[165,26],"m":"lda","oa":26,"o":"zpa_1A"},{"a":37328,"t":"code","b":[201,8],"m":"cmp","o":"#$08"},{"a":37330,"t":"code","b":[240,3],"m":"beq","oa":37335,"o":"b_91D7"},{"a":37332,"t":"code","b":[76,82,145],"m":"jmp","oa":37202,"o":"j_9152"},{"a":37335,"l":"b_91D7","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[37330]},{"a":37337,"t":"code","b":[133,26],"m":"sta","oa":26,"o":"zpa_1A"},{"a":37339,"t":"code","b":[230,23],"m":"inc","oa":23,"o":"shape_ptr"},{"a":37341,"t":"code","b":[208,2],"m":"bne","oa":37345,"o":"b_91E1"},{"a":37343,"t":"code","b":[230,24],"m":"inc","oa":24,"o":"zpa_18"},{"a":37345,"l":"b_91E1","t":"code","b":[160,0],"m":"ldy","o":"#$00","x":[37341]},{"a":37347,"t":"code","b":[177,23],"m":"lda","oa":23,"o":"(shape_ptr),y"},{"a":37349,"t":"code","b":[133,22],"m":"sta","oa":22,"o":"zpa_16"},{"a":37351,"t":"code","b":[76,82,145],"m":"jmp","oa":37202,"o":"j_9152"},{"a":37354,"l":"b_91EA","t":"code","b":[198,17],"m":"dec","oa":17,"o":"shape_h","x":[37322]},{"a":37356,"t":"code","b":[240,51],"m":"beq","oa":37409,"o":"b_9221"},{"a":37358,"t":"code","b":[230,23],"m":"inc","oa":23,"o":"shape_ptr"},{"a":37360,"t":"code","b":[208,2],"m":"bne","oa":37364,"o":"b_91F4"},{"a":37362,"t":"code","b":[230,24],"m":"inc","oa":24,"o":"zpa_18"},{"a":37364,"l":"b_91F4","t":"code","b":[198,11],"m":"dec","oa":11,"o":"zpa_0B","x":[37360]},{"a":37366,"t":"code","b":[198,48],"m":"dec","oa":48,"o":"zpa_30"},{"a":37368,"t":"code","b":[240,3],"m":"beq","oa":37373,"o":"b_91FD"},{"a":37370,"t":"code","b":[76,4,145],"m":"jmp","oa":37124,"o":"j_9104"},{"a":37373,"l":"b_91FD","t":"code","b":[165,43],"m":"lda","oa":43,"o":"slope_run","x":[37368]},{"a":37375,"t":"code","b":[133,48],"m":"sta","oa":48,"o":"zpa_30"},{"a":37377,"t":"code","b":[165,44],"m":"lda","oa":44,"o":"slope_step"},{"a":37379,"t":"code","b":[69,47],"m":"eor","oa":47,"o":"draw_mirror"},{"a":37381,"t":"code","b":[48,13],"m":"bmi","oa":37396,"o":"b_9214"},{"a":37383,"t":"code","b":[70,9],"m":"lsr","oa":9,"o":"draw_bit"},{"a":37385,"t":"code","b":[208,19],"m":"bne","oa":37406,"o":"b_921E"},{"a":37387,"t":"code","b":[169,128],"m":"lda","o":"#$80"},{"a":37389,"t":"code","b":[133,9],"m":"sta","oa":9,"o":"draw_bit"},{"a":37391,"t":"code","b":[230,8],"m":"inc","oa":8,"o":"draw_col"},{"a":37393,"t":"code","b":[76,30,146],"m":"jmp","oa":37406,"o":"b_921E"},{"a":37396,"l":"b_9214","t":"code","b":[6,9],"m":"asl","oa":9,"o":"draw_bit","x":[37381]},{"a":37398,"t":"code","b":[208,6],"m":"bne","oa":37406,"o":"b_921E"},{"a":37400,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":37402,"t":"code","b":[133,9],"m":"sta","oa":9,"o":"draw_bit"},{"a":37404,"t":"code","b":[198,8],"m":"dec","oa":8,"o":"draw_col"},{"a":37406,"l":"b_921E","t":"code","b":[76,4,145],"m":"jmp","oa":37124,"o":"j_9104","x":[37385,37393,37398]},{"a":37409,"l":"b_9221","t":"code","b":[165,29],"m":"lda","oa":29,"o":"save_a","x":[37356]},{"a":37411,"t":"code","b":[166,30],"m":"ldx","oa":30,"o":"save_x"},{"a":37413,"t":"code","b":[164,31],"m":"ldy","oa":31,"o":"save_y"},{"a":37415,"t":"code","b":[96],"m":"rts"},{"a":37416,"l":"stars_restamp","c":"Re-stamp the 24 stars of the night sky, once per frame. Called from the main loop at $95CE immediately after $BBE6 has replayed the erase queue over the back buffer, and from the same point in each of the other screen loops ($9654, $96AE, $9718, $9749 and more), so the stars survive being rubbed out with everything else. X counts 23 down to 0; for each star it takes the bitmap address from the word table at $924E, EORs the high byte with $0F so it lands in whichever buffer is being drawn, reads CIA1 timer A low ($DC04) and writes $03 when the bottom two bits are zero and $01 otherwise. That sets the low bit pair of the byte, so each star is one multicolour pixel flickering between two pens. Checked live: every one of the 24 addresses holds $01 or $03 in both buffers with $00 around it.","t":"code","b":[162,23],"m":"ldx","o":"#$17","x":[38350,38484,38574,38680,38729,38747]},{"a":37418,"l":"b_922A","t":"code","b":[138],"m":"txa","x":[37451]},{"a":37419,"t":"code","b":[10],"m":"asl","o":"a"},{"a":37420,"t":"code","b":[168],"m":"tay"},{"a":37421,"t":"code","b":[185,78,146],"m":"lda","oa":37454,"o":"star_bitmap_addr,y"},{"a":37424,"t":"code","b":[133,6],"m":"sta","oa":6,"o":"bmp_ptr"},{"a":37426,"t":"code","b":[185,79,146],"m":"lda","oa":37455,"o":"star_bitmap_addr_hi,y"},{"a":37429,"t":"code","b":[69,15],"m":"eor","oa":15,"o":"vic_bank_bit"},{"a":37431,"t":"code","b":[133,7],"m":"sta","oa":7,"o":"zpa_07"},{"a":37433,"t":"code","b":[173,4,220],"m":"lda","oa":56324,"o":"$DC04"},{"a":37436,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":37438,"t":"code","b":[208,4],"m":"bne","oa":37444,"o":"b_9244"},{"a":37440,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":37442,"t":"code","b":[208,2],"m":"bne","oa":37446,"o":"b_9246"},{"a":37444,"l":"b_9244","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[37438]},{"a":37446,"l":"b_9246","t":"code","b":[160,0],"m":"ldy","o":"#$00","x":[37442]},{"a":37448,"t":"code","b":[145,6],"m":"sta","oa":6,"o":"(bmp_ptr),y"},{"a":37450,"t":"code","b":[202],"m":"dex"},{"a":37451,"t":"code","b":[16,221],"m":"bpl","oa":37418,"o":"b_922A"},{"a":37453,"t":"code","b":[96],"m":"rts"},{"a":37454,"l":"star_bitmap_addr","c":"Where the 24 stars live: 16-bit little-endian bitmap addresses, read by $9228 as $924E,y (low) and $924F,y (high) with y = 2 * star. They are bank-0 addresses between $2506 and $3A11, i.e. scattered over character rows 4 to 20 and all 40 columns of the 168-row play bitmap; $9228 flips the high byte with $0F to reach the bank-1 copy at $6000. The positions are fixed for the life of the program - only the colour of each star changes.","t":"word","b":[17],"d":[],"x":[37421]},{"a":37455,"l":"star_bitmap_addr_hi","c":"High-byte half of the star address table; the low half is $924E. The full 24 entries are $3A11 $3103 $2506 $3702 $33C0 $2713 $34EA $2E3E $2541 $347C $27CA $2812 $263B $2983 $2F3C $28DF $354A $2C19 $3878 $2D9A $3575 $28A2 $3911 $363C, ending at $927D.","t":"word","b":[58,3,49,6,37,2,55,192],"d":[826,1585,549,49207],"x":[37426]},{"a":37463,"t":"word","b":[51,19,39,234,52,62,46,65],"d":[4915,59943,15924,16686]},{"a":37471,"t":"word","b":[37,124,52,202,39,18,40,59],"d":[31781,51764,4647,15144]},{"a":37479,"t":"word","b":[38,131,41,60,47,223,40,74],"d":[33574,15401,57135,18984]},{"a":37487,"t":"word","b":[53,25,44,120,56,154,45,117],"d":[6453,30764,39480,29997]},{"a":37495,"t":"word","b":[53,162,40,17,57,60,54],"d":[41525,4392,15417]},{"a":37502,"l":"heli_body_y_nudge","c":"Vertical nudge for the helicopter body shape: 11 rows of 5 bytes, row = tilt $5A + 5 (-5..+5), column = turn $59 + 2, indexed at $AB8B by 5*(tilt+5) + turn + 2. $AB90 adds it to half the shape height to make the Y it hands $A9A0, so it raises or drops the hull by up to 6 rows at full tilt to keep the nose where the artwork expects it. Only turn -2, -1, +1 and +2 reach this code (turn 0 and +-3 are drawn by other paths), so column 2 of every row is dead. Rows, tilt -5 to +5: (-3,0,3,3,6) (-2,0,2,2,4) (-1,0,1,1,3) (0,1,1,1,2) (0,1,1,1,2) (0,0,0,0,0) (2,1,1,1,0) (2,1,1,1,0) (3,1,0,0,-1) (4,2,0,0,-2) (6,3,0,0,-3). Ends at $92B4.","t":"byte","b":[253,0,3,3,6,254,0,2],"x":[43915]},{"a":37510,"t":"byte","b":[2,4,255,0,1,1,3,0]},{"a":37518,"t":"byte","b":[1,1,1,2,0,1,1,1]},{"a":37526,"t":"byte","b":[2,0,0,0,0,0,2,1]},{"a":37534,"t":"byte","b":[1,1,0,2,1,1,1,0]},{"a":37542,"t":"byte","b":[3,1,0,0,255,4,2,0]},{"a":37550,"t":"byte","b":[0,254,6,3,0,0,253]},{"a":37557,"l":"rotor_offset_fine","c":"Fine part of the main rotor's draw offset: 11 rows (helicopter tilt $5A = -5..+5) of 7 signed (dx,dy) pairs (turn $59 = -3..+3), read at $ABEB/$ABF0 with index 14*(tilt+5) + 2*(turn+3). $ABCD adds this pair to the coarse per-tilt pair from $934F and passes the sum to $A9A0 as the X and Y of the rotor, which is then drawn sheared by $90D2 using shapes 16, 17 and 18 cycled by the counter $0B61. dx runs -2..+5, dy +5..+7. This first byte is dx for tilt -5, turn -3.","t":"byte","b":[254],"x":[44011]},{"a":37558,"l":"rotor_offset_fine_y","c":"dy half of the fine rotor offset ($ABF0 reads $92B6,x while $ABEB reads $92B5,x). Rows for tilt -5 to -2, each 7 (dx,dy) pairs for turn -3 to +3: (-2,6)(-1,7)(-1,7)(0,7)(0,7)(0,7)(-2,7) / (-1,6)(-1,6)(-1,6)(0,6)(0,6)(0,6)(-2,7) / (-1,6)(-1,6)(-1,6)(0,6)(0,6)(0,6)(-1,7) / (-1,6)(-1,6)(-1,7)(0,7)(0,7)(0,7)(-1,7).","t":"byte","b":[6,255,7,255,7,0,7,0],"x":[44016]},{"a":37566,"t":"byte","b":[7,0,7,254,7,255,6,255]},{"a":37574,"t":"byte","b":[6,255,6,0,6,0,6,0]},{"a":37582,"t":"byte","b":[6,254,7,255,6,255,6,255]},{"a":37590,"t":"byte","b":[6,0,6,0,6,0,6,255]},{"a":37598,"t":"byte","b":[7,255,6,255,6,255,7,0]},{"a":37606,"t":"byte","b":[7,0,7,0,7,255,7]},{"a":37613,"l":"rotor_offset_fine_t1","c":"Fine rotor offset, tilt -1 to +2 (rows 4 to 7 of the table that starts at $92B5), 7 (dx,dy) pairs per row for turn -3 to +3: (-1,5)(-1,6)(-1,6)(0,6)(0,6)(0,7)(-1,6) / (0,5) seven times, the level-flight row where the rotor needs no sideways correction at all / (2,6)(1,7)(1,6)(1,6)(1,6)(1,6)(1,5) / (4,6)(3,6)(3,6)(2,6)(2,6)(2,6)(2,5).","t":"byte","b":[255,5,255,6,255,6,0,6]},{"a":37621,"t":"byte","b":[0,6,0,7,255,6,0,5]},{"a":37629,"t":"byte","b":[0,5,0,5,0,5,0,5]},{"a":37637,"t":"byte","b":[0,5,0,5,2,6,1,7]},{"a":37645,"t":"byte","b":[1,6,1,6,1,6,1,6]},{"a":37653,"t":"byte","b":[1,5,4,6,3,6,3,6]},{"a":37661,"t":"byte","b":[2,6,2,6,2,6,2,5]},{"a":37669,"l":"rotor_offset_fine_t3","c":"Fine rotor offset, tilt +3 to +5 (rows 8 to 10 of the table that starts at $92B5): (4,6)(4,5)(4,5)(3,5)(3,5)(3,5)(3,5) / (4,6)(4,5)(4,5)(4,5)(4,5)(4,5)(4,5) / (5,6)(3,6)(3,6)(4,5)(4,5)(4,5)(5,5). The table ends at $934E.","t":"byte","b":[4,6,4,5,4,5,3,5]},{"a":37677,"t":"byte","b":[3,5,3,5,3,5,4,6]},{"a":37685,"t":"byte","b":[4,5,4,5,4,5,4,5]},{"a":37693,"t":"byte","b":[4,5,4,5,5,6,3,6]},{"a":37701,"t":"byte","b":[3,6,4,5,4,5,4,5]},{"a":37709,"t":"byte","b":[5,5]},{"a":37711,"l":"rotor_offset_base","c":"Coarse part of the main rotor's draw offset, one signed (dx,dy) pair per helicopter tilt, read at $AC04/$ABFD with index 2*(tilt+5). $ABCD adds it to the fine pair from $92B5 before calling $A9A0, which subtracts dx from the chopper's world X and adds dy to its row - so dx is the distance back from the hull anchor to the left end of the rotor bar. Pairs, tilt -5 to +5: (16,6)(17,5)(18,4)(18,2)(19,2)(19,1)(18,0)(17,0)(17,-2)(16,-3)(14,-4).","t":"byte","b":[16],"x":[44036]},{"a":37712,"l":"rotor_offset_base_y","c":"dy half of the coarse rotor offset ($ABFD reads $9350,x, $AC04 reads $934F,x, 21 bytes to $9364). dy falls steadily from +6 at full nose-up to -4 at full nose-down, which lifts the rotor disc further above the hull the harder the helicopter is pitched forward.","t":"byte","b":[6,17,5,18,4,18,2,19],"x":[44029]},{"a":37720,"t":"byte","b":[2,19,1,18,0,17,0,17]},{"a":37728,"t":"byte","b":[254,16,253,14,252]},{"a":37733,"l":"tail_rotor_offset_r","c":"Tail-rotor draw offset for a helicopter facing right, one signed (dx,dy) pair per tilt, read at $AC62/$AC67 with index 2*(tilt+5). $AC4A draws the tail rotor only when the turn state $59 is +3 or -3, i.e. full side view; +3 uses this table and -3 the mirrored one at $937B. It then stamps the four-frame tail-rotor blur, shapes 19 to 22, cycled by the counter $0B62. Pairs, tilt -5 to +5: (18,11)(18,10)(18,9)(19,8)(19,7)(19,5)(19,4)(19,3)(19,3)(19,2)(19,1).","t":"byte","b":[18],"x":[44130]},{"a":37734,"l":"tail_rotor_offset_r_y","c":"dy half of the right-facing tail-rotor offset ($AC67 reads $9366,x, 21 bytes to $937A). dx barely moves - 18 or 19, and $A9A0 subtracts it, so the tail sits a fixed nineteen bitmap bits behind the hull anchor - while dy sweeps from 11 down to 1 as the nose goes from up to down, swinging the tail boom about the hull.","t":"byte","b":[11,18,10,18,9,19,8,19],"x":[44135]},{"a":37742,"t":"byte","b":[7,19,5,19,4,19,3,19]},{"a":37750,"t":"byte","b":[3,19,2,19,1]},{"a":37755,"l":"tail_rotor_offset_l","c":"Tail-rotor draw offset for a helicopter facing left, chosen at $AC6F when the turn state $59 is -3. Mirror of $9365: one signed (dx,dy) pair per tilt at index 2*(tilt+5), with dx -11 to -13 so that $A9A0's subtraction puts the tail on the other side of the hull, and dy climbing instead of falling. Pairs, tilt -5 to +5: (-12,1)(-13,2)(-12,3)(-13,3)(-13,4)(-13,5)(-13,7)(-12,8)(-12,9)(-11,10)(-11,11).","t":"byte","b":[244],"x":[44143]},{"a":37756,"l":"tail_rotor_offset_l_y","c":"dy half of the left-facing tail-rotor offset ($AC74 reads $937C,x alongside $AC6F's $937B,x, 21 bytes to $9390). Taken with $9365 this is the only place the two side views differ: everything else about the tail rotor, including the shape frames, is shared.","t":"byte","b":[1,243,2,244,3,243,3,243],"x":[44148]},{"a":37764,"t":"byte","b":[4,243,5,243,7,244,8,244]},{"a":37772,"t":"byte","b":[9,245,10,245,11]},{"a":37777,"l":"muzzle_offset","c":"Muzzle offset - where the helicopter's shot is born relative to the hull. 11 rows (tilt $5A = -5..+5) of 7 signed (dx,dy) pairs (turn $59 = -3..+3), read at $ACD5/$ACD8 with index 14*(tilt+5) + 2*(turn+3). $ACB7 returns dx in X and dy in Y; $B019 then sets the new actor's world X to $55/$56 minus dx minus one and its row to $57 plus dy. dx sweeps from about +15 through 0 to about -15 across the seven turn states, which is the chopper's nose swinging from pointing right, through head-on, to pointing left. This byte is dx for tilt -5, turn -3.","t":"byte","b":[14],"x":[44245]},{"a":37778,"l":"muzzle_offset_y","c":"dy half of the muzzle-offset table ($ACD8 reads $9392,y). Rows for tilt -5 to -2, each 7 (dx,dy) pairs for turn -3 to +3: (14,3)(10,2)(4,0)(3,0)(2,-1)(-5,-3)(-11,-5) / (14,2)(10,1)(4,-1)(3,-1)(1,-2)(-6,-4)(-12,-4) / (15,1)(11,1)(4,-1)(2,-2)(0,-2)(-7,-3)(-13,-4) / (15,0)(11,0)(3,-1)(1,-1)(-1,-1)(-8,-2)(-14,-3).","t":"byte","b":[3,10,2,4,0,3,0,2],"x":[44248]},{"a":37786,"t":"byte","b":[255,251,253,245,251,14,2,10]},{"a":37794,"t":"byte","b":[1,4,255,3,255,1,254,250]},{"a":37802,"t":"byte","b":[252,244,252,15,1,11,1,4]},{"a":37810,"t":"byte","b":[255,2,254,0,254,249,253,243]},{"a":37818,"t":"byte","b":[252,15,0,11,0,3,255,1]},{"a":37826,"t":"byte","b":[255,255,255,248,254,242,253]},{"a":37833,"l":"muzzle_offset_t1","c":"Muzzle offset, tilt -1 to +2 (rows 4 to 7 of the table that starts at $9391): (15,-1)(11,-1)(3,-1)(1,-1)(-1,-1)(-9,-2)(-15,-2) / (15,-2)(11,-2)(3,-2)(0,-2)(-2,-2)(-10,-2)(-15,-2) / (15,-2)(11,-2)(3,-1)(0,-1)(-2,-1)(-10,-1)(-15,-1) / (15,-3)(10,-2)(3,-1)(1,-1)(-2,-1)(-11,0)(-15,0). The level-flight row (tilt 0) is the symmetric one: the gun sits two rows above the anchor whichever way the chopper is turned.","t":"byte","b":[15,255,11,255,3,255,1,255]},{"a":37841,"t":"byte","b":[255,255,247,254,241,254,15,254]},{"a":37849,"t":"byte","b":[11,254,3,254,0,254,254,254]},{"a":37857,"t":"byte","b":[246,254,241,254,15,254,11,254]},{"a":37865,"t":"byte","b":[3,255,0,255,254,255,246,255]},{"a":37873,"t":"byte","b":[241,255,15,253,10,254,3,255]},{"a":37881,"t":"byte","b":[1,255,254,255,245,0,241,0]},{"a":37889,"l":"muzzle_offset_t3","c":"Muzzle offset, tilt +3 to +5 (rows 8 to 10 of the table that starts at $9391): (14,-4)(8,-4)(2,-2)(0,-1)(-2,-1)(-10,1)(-14,1) / (13,-4)(8,-4)(1,-2)(-1,-1)(-3,0)(-10,1)(-14,2) / (12,-5)(5,-3)(0,-2)(-1,-1)(-3,0)(-8,2)(-14,3). Ends at $942A.","t":"byte","b":[14,252,8,252,2,254,0,255]},{"a":37897,"t":"byte","b":[254,255,246,1,242,1,13,252]},{"a":37905,"t":"byte","b":[8,252,1,254,255,255,253,0]},{"a":37913,"t":"byte","b":[246,1,242,2,12,251,5,253]},{"a":37921,"t":"byte","b":[0,254,255,255,253,0,248,2]},{"a":37929,"t":"byte","b":[242,3]},{"a":37931,"l":"heli_shot_speed","c":"Speed of a shot the helicopter fires: 4 groups (|turn| = |$59| = 0..3) of 6 signed (vx,vy) pairs (|tilt| = |$5A| = 0..5), read at $AD4A/$AD65 with index 12*|turn| + 2*|tilt|. $AD24 gives vx the sign of $59 and vy the sign of $59 EOR $5A, adds the chopper's own drift $52 to vx, and writes them into the new actor's fields +1 and +2 ($0B75/$0B76); field +3 comes from the four-byte table at $AD86 indexed by |turn|. The size jump is the point: vx is 0 to 2 head-on, 3 to 4, 10 to 12, and 25 to 26 in full side view, so only a side-on shot travels. Groups: |turn|=0 (0,0)(0,0)(1,0)(2,0)(2,0)(2,0); =1 (3,0)(3,0)(3,0)(3,0)(3,1)(4,2); =2 (12,0)(12,0)(12,1)(12,2)(11,2)(10,2); =3 (26,0)(26,2)(26,4)(26,6)(25,8)(25,10).","t":"byte","b":[0],"x":[44362]},{"a":37932,"l":"heli_shot_speed_y","c":"vy half of the shot-speed table ($AD65 reads $942C,y). vy is zero whenever the chopper is level and grows with tilt, up to 10 at full side view and full pitch, so the shot leaves along the line the nose is pointing. 47 bytes to $945A.","t":"byte","b":[0,0,0,1,0,2,0,2],"x":[44389]},{"a":37940,"t":"byte","b":[0,2,0,3,0,3,0,3]},{"a":37948,"t":"byte","b":[0,3,0,3,1,4,2,12]},{"a":37956,"t":"byte","b":[0,12,0,12,1,12,2,11]},{"a":37964,"t":"byte","b":[2,10,2,26,0,26,2,26]},{"a":37972,"t":"byte","b":[4,26,6,25,8,25,10]},{"a":37979,"l":"tilt_anchor_x","c":"Horizontal anchor of the helicopter drawing for each of the eleven tilt frames: 11 signed 16-bit values indexed at $A8DA/$A8E2 by 2*(tilt+5). When $A8B8 moves the tilt it adds $945B[new] - $945B[old] to the world X in $55/$56, so swapping to the next body shape does not make the hull jump sideways. Values, tilt -5 to +5: 6 5 3 2 0 0 -1 -2 -4 -5 -7 - a steady drift of thirteen bitmap bits across the full range of pitch.","t":"word","b":[6],"d":[],"x":[43226,43229]},{"a":37980,"l":"tilt_anchor_x_hi","c":"High-byte half of the per-tilt horizontal anchor; $A8DD and $A8E5 subtract two entries as a 16-bit pair. Every value fits in a byte, so this half is only $00 or $FF (sign extension). 21 bytes to $9470.","t":"word","b":[0,5,0,3,0,2,0,0],"d":[1280,768,512,0],"x":[43234,43237]},{"a":37988,"t":"word","b":[0,0,0,255,255,254,255,252],"d":[0,65280,65279,64767]},{"a":37996,"t":"word","b":[255,251,255,249,255],"d":[64511,63999]},{"a":38001,"l":"tilt_anchor_y","c":"Vertical anchor of the helicopter drawing for each tilt: 11 values stored two bytes apart (the odd bytes are always $00 and are never read), indexed by 2*(tilt+5). It does two jobs. $A8B8 adds $9471[new] - $9471[old] to the altitude $57 when the tilt changes, the vertical twin of $945B. $A7D6 uses it as the skid height: if $57 minus this value goes negative the helicopter has touched down, so $A805 clamps $57 back to it and $A7FB sets the landed flag $5D. Values, tilt -5 to +5: 10 9 9 8 8 7 7 7 7 8 8, i.e. a tilted chopper sits up to three rows higher on its skids than a level one. Confirmed in the running game with the chopper on the ground: $5A (tilt) = 0, $57 = 7, which is exactly the middle entry, and $5D was set. Ends at $9486.","t":"byte","b":[10,0,9,0,9,0,8,0],"x":[42996,43013,43278,43281]},{"a":38009,"t":"byte","b":[8,0,7,0,7,0,7,0]},{"a":38017,"t":"byte","b":[7,0,8,0,8,0]},{"a":38023,"l":"jet_erase_class","c":"Erase-box class for every frame of the jet (actor type 9, handler $AD8F): 5 rows of 8 bytes indexed at $AE21 by 8*mode + frame, where mode is the jet's field +1 ($0B75, 0 to 4) and frame is $0B51, the shape number the flight-path record chose. $AE1F adds 7 before the lookup, so a stored $FF means class 6 - the zero-sized class in $94AF, used for the frames that are never reached. Classes by row: mode 0 (cruise) 7,6,6,6,6,6,6,6; mode 1 (wide turn) 8,8,9,9,9,10,10,6; mode 2 (tight turn) 8,9,10,11,11,6,6,6; modes 3 and 4 11,10,9,9,8,8,6,6. The class goes to $AA38, which queues the box for next frame's erase pass. The sizes grow with the frame number, which is the aircraft getting larger as it swings towards the viewer. Ends at $94AE.","t":"byte","b":[0,255,255,255,255,255,255,255],"x":[44577]},{"a":38031,"t":"byte","b":[1,1,2,2,2,3,3,255]},{"a":38039,"t":"byte","b":[1,2,3,4,4,255,255,255]},{"a":38047,"t":"byte","b":[4,3,2,2,1,1,255,255]},{"a":38055,"t":"byte","b":[4,3,2,2,1,1,255,255]},{"a":38063,"l":"erase_box_w","c":"Size of the erase box for each object class, as (width in bitmap bytes, height in rows) pairs indexed at $BC1D/$BC22 by 2*class. This is the other half of the game's double-buffer scheme: $AA38 pushes a class plus a position onto the queue at ($99) as each object is drawn, and on the next frame $BBE6 swaps the queues and $BC05 walks the old one, handing this pair to the block clear at $8C5E so every moving object is rubbed out of the buffer it was drawn in. Class 0 is the helicopter: 7 bytes (56 bitmap bits, 28 multicolour pixels) by 23 rows, and $BC2B shifts its anchor 22 bits left and 14 rows down to reach the corner. Classes $06, $0C and $12 are 0 by 0, i.e. nothing to erase. This byte is the width of class 0.","t":"byte","b":[7],"x":[48157]},{"a":38064,"l":"erase_box_h","c":"Height half of the erase-box table ($BC22 reads $94B0,x). The 26 classes $00 to $19, in order, as (width,height): (7,23)(6,4)(6,6)(3,3)(2,4)(5,12)(0,0)(4,5)(5,13)(5,17)(6,16)(7,18) (0,0)(2,3)(2,3)(3,3)(2,1)(3,11)(0,0)(22,5)(9,9)(3,12)(2,5)(5,13)(3,2)(3,10), ending at $94E2. The callers of $AA38 pass classes $00 to $05, $0D to $11, $13 to $17 and $19 directly, and $06 to $0B through the jet's table at $9487. Class $13 at 22 bytes wide is much the largest - 176 bitmap bits across.","t":"byte","b":[23,6,4,6,6,3,3,2],"x":[48162]},{"a":38072,"t":"byte","b":[4,5,12,0,0,4,5,5]},{"a":38080,"t":"byte","b":[13,5,17,6,16,7,18,0]},{"a":38088,"t":"byte","b":[0,2,3,2,3,3,3,2]},{"a":38096,"t":"byte","b":[1,3,11,0,0,22,5,9]},{"a":38104,"t":"byte","b":[9,3,12,2,5,5,13,3]},{"a":38112,"t":"byte","b":[2,3,10]},{"a":38115,"l":"jet_path_cruise","c":"Flight path for the jet's cruise mode (field +1 = 0), reached through the pointer table at $AFC2. One 4-byte record: (shape frame, X step, change to actor field +6, change to field +7) = (0, +8, 0, 0). Frame 0 of the shape list at $8037 is shape 23, the small distant aircraft; it crosses 8 bitmap bits a frame at a constant height. The step count table at $AD8A gives mode 0 a count of zero, so the jet stays on this one record until the proximity tests at $AE9E switch it into a turn or $AF42 forces mode 4.","t":"byte","b":[0,8,0,0]},{"a":38119,"l":"jet_path_turn_wide","c":"Flight path for the jet's mode 1, the wide turn: 18 four-byte records walked one per frame by the handler at $AD8F through the pointer at $AFC2+2, with the count 18 coming from $AD8A+1. Each record is (shape frame, X step, change to actor field +6, change to field +7); the frame indexes the shape list at $8039, i.e. shapes 24 to 30, and the X step is given the sign of the jet's facing byte $0B77 before being added to its world X. Records 0 to 7: (0,+6,+1,-1) (0,+6,0,-1) (0,+6,0,-1) (0,+7,0,-2) (0,+7,0,-2) (1,+8,-1,-2) (1,+9,-1,-2) (1,+9,-1,-2). When the path runs out $AF9A flips $0B77, so this is the manoeuvre that reverses the jet's direction of travel.","t":"byte","b":[0,6,1,255,0,6,0,255]},{"a":38127,"t":"byte","b":[0,6,0,255,0,7,0,254]},{"a":38135,"t":"byte","b":[0,7,0,254,1,8,255,254]},{"a":38143,"t":"byte","b":[1,9,255,254,1,9,255,254]},{"a":38151,"l":"jet_path_turn_wide_2","c":"Second half of the jet's wide turn, records 8 to 17 of the path that starts at $94E7: (1,+9,-1,-2) (2,+8,-1,-2) (2,+8,-1,-2) (2,+5,-1,-2) (3,+2,-1,-2) (4,-4,-1,-2) (4,-8,-1,-2) (5,-10,-1,-2) (6,-12,0,-2) (6,-12,-1,0). The X step decelerates from +9 through +2, crosses zero and builds to -12 while the shape frame climbs 1 to 6: the aircraft banking round through its turn frames, stalling at the top of the arc and leaving faster than it came in. Field +6 drops one a step for almost the whole manoeuvre, so it also climbs. Ends at $952E.","t":"byte","b":[1,9,255,254,2,8,255,254]},{"a":38159,"t":"byte","b":[2,8,255,254,2,5,255,254]},{"a":38167,"t":"byte","b":[3,2,255,254,4,252,255,254]},{"a":38175,"t":"byte","b":[4,248,255,254,5,246,255,254]},{"a":38183,"t":"byte","b":[6,244,0,254,6,244,255,0]},{"a":38191,"l":"jet_path_turn_tight","c":"Flight path for the jet's mode 2, the tight turn: 15 four-byte records, pointer at $AFC2+4, count 15 from $AD8A+2, frames indexing the shape list at $8047 (shapes 31 to 35). (0,+4,+1,-1) (0,+4,0,-1) (0,+3,0,-1) (0,+2,0,-2) (0,+1,-1,-2) (0,+1,-1,-2) (0,+1,-1,-3) (1,+1,-1,-3) (1,+1,-1,-3) (1,+1,-1,-3) (1,+2,-1,-3) (1,+3,-1,-3) (2,+5,-1,-3) (3,+8,-1,-1) (4,+11,-1,0). Speed sinks to a single bit a frame for six records and then builds back to +11, and unlike mode 1 the facing byte is not flipped at the end, so the jet comes out going the way it went in. Ends at $956A.","t":"byte","b":[0,4,1,255,0,4,0,255]},{"a":38199,"t":"byte","b":[0,3,0,255,0,2,0,254]},{"a":38207,"t":"byte","b":[0,1,255,254,0,1,255,254]},{"a":38215,"t":"byte","b":[0,1,255,253,1,1,255,253]},{"a":38223,"t":"byte","b":[1,1,255,253,1,1,255,253]},{"a":38231,"t":"byte","b":[1,2,255,253,1,3,255,253]},{"a":38239,"t":"byte","b":[2,5,255,253,3,8,255,255]},{"a":38247,"t":"byte","b":[4,11,255,0]},{"a":38251,"l":"jet_path_run","c":"Flight path shared by the jet's modes 3 and 4 - both pointers, $AFC2+6 and $AFC2+8, hold $956B. 10 four-byte records, count 10, frames indexing the shape list at $8051 (shapes 36 to 38): (0,+12,0,0) five times, then (1,+12,0,+1) (1,+12,0,+1) (1,+12,+1,+1) (1,+13,+1,+2) (2,+13,+2,+2). A flat run at 12 to 13 bitmap bits a frame that starts descending after the fifth step. The two modes differ only in what $AF4F calls on the first step - $B665 for mode 3, $B6ED for mode 4 - and mode 3 is the one chosen when the helicopter is on the ground ($5D set). Ends at $9592, where the cold-start code begins.","t":"byte","b":[0,12,0,0,0,12,0,0]},{"a":38259,"t":"byte","b":[0,12,0,0,0,12,0,0]},{"a":38267,"t":"byte","b":[0,12,0,0,1,12,0,1]},{"a":38275,"t":"byte","b":[1,12,0,1,1,12,1,1]},{"a":38283,"t":"byte","b":[1,13,1,2,2,13,2,2]},{"a":38291,"l":"cart_cold_start","c":"Cartridge cold start: the address in both vectors at $8000 and $8002, entered by the KERNAL's reset the moment it finds the CBM80 signature at $8004, which happens before the KERNAL has initialised anything. So the cartridge does it itself - jsr $FF84 (IOINIT: the CIAs, the VIC and the raster), jsr $FF87 (RAMTAS: zero page, the tape buffer and the top of memory), jsr $E518 (CINT: the editor's screen and keyboard reset) - and then falls straight into $959C. It deliberately skips RESTOR ($FF8A): the game installs its own $0314 and $0318 vectors later. The disk build of the same image jumps to $959C instead, skipping all three, because there it was loaded by a KERNAL that had already made those calls during a normal boot.","t":"code","b":[32,132,255],"m":"jsr","oa":65412,"o":"s_FF84"},{"a":38294,"t":"code","b":[32,135,255],"m":"jsr","oa":65415,"o":"s_FF87"},{"a":38297,"t":"code","b":[32,24,229],"m":"jsr","oa":58648,"o":"s_E518"},{"a":38300,"l":"cold_start","c":"Program entry. The disk loader's copier jumps here after moving $0900-$48FF up to $8000-$BFFF and setting $01 to $36; the cartridge cold-start at $9593 (the address in the CBM80 vector at $8000) also runs its three KERNAL calls and falls straight into it. Sets the machine up once and never returns: $BF06 clears the $0A00-$0EFF variable pages and builds the bitmap row-pointer tables, $98DF installs the NMI vector and paints both text screens and the status-bar frame, $A75C programs the three SID voices and arms the raster interrupt at $99F2, $BBCA blanks both bitmap buffers and $BEB5 puts the helicopter back to its start state. Then $8C = 0, which keeps the SID silent through the gate in $A7BA and the status-bar furniture off the screen until a game starts, and control drops into the title screen at $95AF.","t":"code","b":[32,6,191],"m":"jsr","oa":48902,"o":"cold_init"},{"a":38303,"t":"code","b":[32,223,152],"m":"jsr","oa":39135,"o":"screen_init"},{"a":38306,"t":"code","b":[32,92,167],"m":"jsr","oa":42844,"o":"install_irq_and_sound"},{"a":38309,"t":"code","b":[32,202,187],"m":"jsr","oa":48074,"o":"clear_both_bitmaps"},{"a":38312,"t":"code","b":[32,181,190],"m":"jsr","oa":48821,"o":"reset_helicopter"},{"a":38315,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38317,"t":"code","b":[133,140],"m":"sta","oa":140,"o":"status_bar_on"},{"a":38319,"l":"title_screen","c":"Put the title screen up. Reached from $959C at power-on and from $9707 when a game has finished. $9739 repaints the backdrop into both buffers at the home view over the base, $BB2B resets the new-game state and (only while $8C says a game is running) stamps the status bar's fixed furniture, $BEB5 resets the helicopter, and $9AAC writes the five title lines and opens the five-row text window they need. Falls into the attract loop.","t":"code","b":[32,57,151],"m":"jsr","oa":38713,"o":"redraw_backdrop","x":[38663]},{"a":38322,"t":"code","b":[32,43,187],"m":"jsr","oa":47915,"o":"new_game_reset"},{"a":38325,"t":"code","b":[32,181,190],"m":"jsr","oa":48821,"o":"reset_helicopter"},{"a":38328,"t":"code","b":[32,172,154],"m":"jsr","oa":39596,"o":"title_text_draw"},{"a":38331,"l":"attract_loop","c":"Attract-mode pass, repeated until the player presses fire. $976A returns the trigger in the carry: pressed runs $9B56, which wipes the title text and clears $93 to close the text window, and jumps to $95E6 to start a game. Not pressed counts $89 up and runs the ordinary draw sequence behind the title text - $996B engine sound (silent, since $8C is 0), $BBE6 erase what the last frame drew into this buffer, $9228 stars, $BCA2 move the camera, $AA67 the half-speed line of distant hills, $BA3F the home base, $B307 the actor list, $8D1F show the buffer just finished and $8D16 flip to the other one - so the title screen animates instead of being a still picture.","t":"code","b":[32,106,151],"m":"jsr","oa":38762,"o":"joy_fire_carry","x":[38371]},{"a":38334,"t":"code","b":[144,6],"m":"bcc","oa":38342,"o":"b_95C6"},{"a":38336,"t":"code","b":[32,86,155],"m":"jsr","oa":39766,"o":"title_exit_repaint"},{"a":38339,"t":"code","b":[76,230,149],"m":"jmp","oa":38374,"o":"game_start"},{"a":38342,"l":"b_95C6","t":"code","b":[230,137],"m":"inc","oa":137,"o":"phase_frames","x":[38334]},{"a":38344,"t":"code","b":[32,107,153],"m":"jsr","oa":39275,"o":"engine_sound"},{"a":38347,"t":"code","b":[32,230,187],"m":"jsr","oa":48102,"o":"erase_last_frame"},{"a":38350,"t":"code","b":[32,40,146],"m":"jsr","oa":37416,"o":"stars_restamp"},{"a":38353,"t":"code","b":[32,162,188],"m":"jsr","oa":48290,"o":"scroll_camera"},{"a":38356,"t":"code","b":[32,103,170],"m":"jsr","oa":43623,"o":"draw_horizon_hills"},{"a":38359,"t":"code","b":[32,63,186],"m":"jsr","oa":47679,"o":"draw_home_base"},{"a":38362,"t":"code","b":[32,7,179],"m":"jsr","oa":45831,"o":"actor_dispatch"},{"a":38365,"t":"code","b":[32,31,141],"m":"jsr","oa":36127,"o":"show_draw_buffer"},{"a":38368,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":38371,"t":"code","b":[76,187,149],"m":"jmp","oa":38331,"o":"attract_loop"},{"a":38374,"l":"game_start","c":"Start a new game, entered when fire is pressed on the title screen. Clears $02 so no message window is open and $0CE0 so the engine sound stays off, sets $8C = $FF which opens the SID gate in $A7BA and turns on the status-bar symbols in $BB2B, and repaints the backdrop. Then plays the start fanfare: four times round a loop with $6D = 4..1 it sends $A7C7 the notes $6D*16+$18 ($58, $48, $38, $28), $22 and $30, each two raster frames long on SID voice 3, and $A7C7 waits for each note to finish before starting the next. $BE52 lays out the sortie and $8AC7 clears the message area. Falls into $961E.","t":"code","b":[32,57,151],"m":"jsr","oa":38713,"o":"redraw_backdrop","x":[38339]},{"a":38377,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38379,"t":"code","b":[133,2],"m":"sta","oa":2,"o":"msg_showing"},{"a":38381,"t":"code","b":[141,224,12],"m":"sta","oa":3296,"o":"engine_on"},{"a":38384,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":38386,"t":"code","b":[133,140],"m":"sta","oa":140,"o":"status_bar_on"},{"a":38388,"t":"code","b":[32,43,187],"m":"jsr","oa":47915,"o":"new_game_reset"},{"a":38391,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":38393,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":38395,"l":"b_95FB","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[38422]},{"a":38397,"t":"code","b":[10],"m":"asl","o":"a"},{"a":38398,"t":"code","b":[10],"m":"asl","o":"a"},{"a":38399,"t":"code","b":[10],"m":"asl","o":"a"},{"a":38400,"t":"code","b":[10],"m":"asl","o":"a"},{"a":38401,"t":"code","b":[24],"m":"clc"},{"a":38402,"t":"code","b":[105,24],"m":"adc","o":"#$18"},{"a":38404,"t":"code","b":[170],"m":"tax"},{"a":38405,"t":"code","b":[160,2],"m":"ldy","o":"#$02"},{"a":38407,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":38410,"t":"code","b":[162,34],"m":"ldx","o":"#$22"},{"a":38412,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":38415,"t":"code","b":[162,48],"m":"ldx","o":"#$30"},{"a":38417,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":38420,"t":"code","b":[198,109],"m":"dec","oa":109,"o":"zpa_6D"},{"a":38422,"t":"code","b":[208,227],"m":"bne","oa":38395,"o":"b_95FB"},{"a":38424,"t":"code","b":[32,82,190],"m":"jsr","oa":48722,"o":"start_sortie_world"},{"a":38427,"t":"code","b":[32,199,138],"m":"jsr","oa":35527,"o":"msg_hide"},{"a":38430,"l":"sortie_start","c":"Begin a sortie. $0CFF counts the sorties flown: 0, 1 and 2 select the FIRST/SECOND/THIRD SORTIE strings through $8A8B, and 3 means the game is over, so it jumps to $96E4 to print THE END instead. Otherwise the backdrop is repainted, $8A8B centres the message on row 11 of both text screens and sets $02, which makes the raster handler open a two-row text window over the bitmap at raster lines $81-$91, and $0CE0 and $89 are reset. Falls into the message loop.","t":"code","b":[173,255,12],"m":"lda","oa":3327,"o":"sortie_number","x":[38553]},{"a":38433,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":38435,"t":"code","b":[208,3],"m":"bne","oa":38440,"o":"b_9628"},{"a":38437,"t":"code","b":[76,228,150],"m":"jmp","oa":38628,"o":"end_the_end"},{"a":38440,"l":"b_9628","t":"code","b":[72],"m":"pha","x":[38435]},{"a":38441,"t":"code","b":[32,57,151],"m":"jsr","oa":38713,"o":"redraw_backdrop"},{"a":38444,"t":"code","b":[32,181,190],"m":"jsr","oa":48821,"o":"reset_helicopter"},{"a":38447,"t":"code","b":[104],"m":"pla"},{"a":38448,"t":"code","b":[32,139,138],"m":"jsr","oa":35467,"o":"msg_show"},{"a":38451,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38453,"t":"code","b":[141,224,12],"m":"sta","oa":3296,"o":"engine_on"},{"a":38456,"t":"code","b":[133,137],"m":"sta","oa":137,"o":"phase_frames"},{"a":38458,"l":"sortie_msg_loop","c":"Holds the sortie message on screen for $2C = 44 passes, running the pause check, the engine sound and the backdrop part of the draw sequence ($BBE6, $9228, $AA67, $BA3F) but reading no input. When the count is reached $8AC7 wipes the message, which sets $02 back to 0 and closes the text window, $0CFF counts one sortie up, and control goes to $9666 to fly.","t":"code","b":[32,188,152],"m":"jsr","oa":39100,"o":"pause_check","x":[38499]},{"a":38461,"t":"code","b":[32,107,153],"m":"jsr","oa":39275,"o":"engine_sound"},{"a":38464,"t":"code","b":[230,137],"m":"inc","oa":137,"o":"phase_frames"},{"a":38466,"t":"code","b":[165,137],"m":"lda","oa":137,"o":"phase_frames"},{"a":38468,"t":"code","b":[201,44],"m":"cmp","o":"#$2C"},{"a":38470,"t":"code","b":[144,9],"m":"bcc","oa":38481,"o":"b_9651"},{"a":38472,"t":"code","b":[32,199,138],"m":"jsr","oa":35527,"o":"msg_hide"},{"a":38475,"t":"code","b":[238,255,12],"m":"inc","oa":3327,"o":"sortie_number"},{"a":38478,"t":"code","b":[76,102,150],"m":"jmp","oa":38502,"o":"flight_begin"},{"a":38481,"l":"b_9651","t":"code","b":[32,230,187],"m":"jsr","oa":48102,"o":"erase_last_frame","x":[38470]},{"a":38484,"t":"code","b":[32,40,146],"m":"jsr","oa":37416,"o":"stars_restamp"},{"a":38487,"t":"code","b":[32,103,170],"m":"jsr","oa":43623,"o":"draw_horizon_hills"},{"a":38490,"t":"code","b":[32,63,186],"m":"jsr","oa":47679,"o":"draw_home_base"},{"a":38493,"t":"code","b":[32,31,141],"m":"jsr","oa":36127,"o":"show_draw_buffer"},{"a":38496,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":38499,"t":"code","b":[76,58,150],"m":"jmp","oa":38458,"o":"sortie_msg_loop"},{"a":38502,"l":"flight_begin","c":"Arm the in-flight sound and start flying. $0CE0 = $FF is the gate $996B tests before it touches SID voice 1, and $95 = $11 starts the countdown the raster handler uses at $9A4C to retrigger voice 2, the rotor beat. Falls into the flight loop.","t":"code","b":[162,255],"m":"ldx","o":"#$FF","x":[38478]},{"a":38504,"t":"code","b":[142,224,12],"m":"stx","oa":3296,"o":"engine_on"},{"a":38507,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":38509,"t":"code","b":[133,149],"m":"sta","oa":149,"o":"zpa_95"},{"a":38511,"l":"flight_frame","c":"One pass of the game in flight - the main loop. It is not locked to the frame: measured live at 83 passes per 201 raster frames, about one pass every 2.4 frames. Counts $89, clears the per-pass flags $0D01 and $0D02, then tests the endings: $0CEE = $40 means all 64 hostages are home and jumps to $96E8 (MAGNIFICENT!), $0CEE + $0CEF = $40 means all 64 are accounted for one way or the other and jumps to $96E4 (THE END). $63 is the end-of-sortie timer - 0 while the sortie runs, set to 1 by $A87B when the helicopter is destroyed, then stepped by 3 each pass until it wraps negative about 43 passes later, at which point the sortie ends back at $961E. The pass itself reads the stick ($A71A vertical into $5C, $A741 horizontal into $5B, $9774 the trigger), runs $996B for the engine, then the draw sequence: $BBE6 erase last frame, $9228 stars, $BCA2 move the camera, $AA67 distant hills, $BA3F home base, $B971 parallax scenery, $B8AE the prisoner sheds, $9B7D the people on the ground, $A363 enemy spawning, $986C swing the helicopter's facing, $B307 the actor list, $8D1F show the finished buffer and $8D16 flip. $97AD is slipped in five times between those steps so a trigger tap that starts and ends between the once-a-pass reads is not lost, and $98BC at the end tests the pause key.","t":"code","b":[230,137],"m":"inc","oa":137,"o":"phase_frames","x":[38625]},{"a":38513,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38515,"t":"code","b":[141,1,13],"m":"sta","oa":3329,"o":"a_0D01"},{"a":38518,"t":"code","b":[141,2,13],"m":"sta","oa":3330,"o":"a_0D02"},{"a":38521,"t":"code","b":[173,238,12],"m":"lda","oa":3310,"o":"hostages_saved"},{"a":38524,"t":"code","b":[201,64],"m":"cmp","o":"#$40"},{"a":38526,"t":"code","b":[208,3],"m":"bne","oa":38531,"o":"b_9683"},{"a":38528,"t":"code","b":[76,232,150],"m":"jmp","oa":38632,"o":"end_magnificent"},{"a":38531,"l":"b_9683","t":"code","b":[24],"m":"clc","x":[38526]},{"a":38532,"t":"code","b":[109,239,12],"m":"adc","oa":3311,"o":"hostages_lost"},{"a":38535,"t":"code","b":[201,64],"m":"cmp","o":"#$40"},{"a":38537,"t":"code","b":[208,3],"m":"bne","oa":38542,"o":"b_968E"},{"a":38539,"t":"code","b":[76,228,150],"m":"jmp","oa":38628,"o":"end_the_end"},{"a":38542,"l":"b_968E","t":"code","b":[165,99],"m":"lda","oa":99,"o":"sortie_end_delay","x":[38537]},{"a":38544,"t":"code","b":[240,10],"m":"beq","oa":38556,"o":"b_969C"},{"a":38546,"t":"code","b":[24],"m":"clc"},{"a":38547,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":38549,"t":"code","b":[133,99],"m":"sta","oa":99,"o":"sortie_end_delay"},{"a":38551,"t":"code","b":[16,3],"m":"bpl","oa":38556,"o":"b_969C"},{"a":38553,"t":"code","b":[76,30,150],"m":"jmp","oa":38430,"o":"sortie_start"},{"a":38556,"l":"b_969C","t":"code","b":[32,26,167],"m":"jsr","oa":42778,"o":"read_stick_updown","x":[38544,38551]},{"a":38559,"t":"code","b":[32,65,167],"m":"jsr","oa":42817,"o":"read_stick_leftright"},{"a":38562,"t":"code","b":[32,116,151],"m":"jsr","oa":38772,"o":"fire_decode"},{"a":38565,"t":"code","b":[32,107,153],"m":"jsr","oa":39275,"o":"engine_sound"},{"a":38568,"t":"code","b":[32,230,187],"m":"jsr","oa":48102,"o":"erase_last_frame"},{"a":38571,"t":"code","b":[32,173,151],"m":"jsr","oa":38829,"o":"fire_poll"},{"a":38574,"t":"code","b":[32,40,146],"m":"jsr","oa":37416,"o":"stars_restamp"},{"a":38577,"t":"code","b":[32,173,151],"m":"jsr","oa":38829,"o":"fire_poll"},{"a":38580,"t":"code","b":[32,162,188],"m":"jsr","oa":48290,"o":"scroll_camera"},{"a":38583,"t":"code","b":[32,103,170],"m":"jsr","oa":43623,"o":"draw_horizon_hills"},{"a":38586,"t":"code","b":[32,173,151],"m":"jsr","oa":38829,"o":"fire_poll"},{"a":38589,"t":"code","b":[32,63,186],"m":"jsr","oa":47679,"o":"draw_home_base"},{"a":38592,"t":"code","b":[32,113,185],"m":"jsr","oa":47473,"o":"draw_parallax_scenery"},{"a":38595,"t":"code","b":[32,174,184],"m":"jsr","oa":47278,"o":"draw_sheds"},{"a":38598,"t":"code","b":[32,173,151],"m":"jsr","oa":38829,"o":"fire_poll"},{"a":38601,"t":"code","b":[32,125,155],"m":"jsr","oa":39805,"o":"hostages_update"},{"a":38604,"t":"code","b":[32,99,163],"m":"jsr","oa":41827,"o":"spawn_scheduler"},{"a":38607,"t":"code","b":[32,173,151],"m":"jsr","oa":38829,"o":"fire_poll"},{"a":38610,"t":"code","b":[32,108,152],"m":"jsr","oa":39020,"o":"turn_step"},{"a":38613,"t":"code","b":[32,7,179],"m":"jsr","oa":45831,"o":"actor_dispatch"},{"a":38616,"t":"code","b":[32,31,141],"m":"jsr","oa":36127,"o":"show_draw_buffer"},{"a":38619,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":38622,"t":"code","b":[32,188,152],"m":"jsr","oa":39100,"o":"pause_check"},{"a":38625,"t":"code","b":[76,111,150],"m":"jmp","oa":38511,"o":"flight_frame"},{"a":38628,"l":"end_the_end","c":"THE END. Reached when every one of the 64 hostages is accounted for ($0CEE + $0CEF = $40) or when $0CFF shows the third sortie has been flown. Selects message index 3 and joins $96EA.","t":"code","b":[169,3],"m":"lda","o":"#$03","x":[38437,38539]},{"a":38630,"t":"code","b":[208,2],"m":"bne","oa":38634,"o":"end_msg_show"},{"a":38632,"l":"end_magnificent","c":"MAGNIFICENT! Reached when $0CEE alone reaches $40, i.e. all 64 hostages were rescued and none lost. Selects message index 4 and joins $96EA.","t":"code","b":[169,4],"m":"lda","o":"#$04","x":[38528]},{"a":38634,"l":"end_msg_show","c":"Show the end-of-game message whose index is in A with $8A8B, which opens the two-row text window, then shut the game down: $89 = 0, $0CE0 = 0 and $8C = 0, which closes the SID gate in $A7BA and takes the status-bar symbols off the next repaint. Falls into the closing loop.","t":"code","b":[32,139,138],"m":"jsr","oa":35467,"o":"msg_show","x":[38630]},{"a":38637,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38639,"t":"code","b":[133,137],"m":"sta","oa":137,"o":"phase_frames"},{"a":38641,"t":"code","b":[141,224,12],"m":"sta","oa":3296,"o":"engine_on"},{"a":38644,"t":"code","b":[133,140],"m":"sta","oa":140,"o":"status_bar_on"},{"a":38646,"l":"end_msg_loop","c":"Runs the closing message for $50 = 80 passes with the full draw sequence, so the wreck and the last actors keep moving under it. The joystick is not read: $5C = 2 and $5B = 0 are written by hand each pass, below anything $A71A and $A741 can produce from the stick, so the helicopter sinks and does not drift. When the count is reached $8AC7 wipes the message and control returns to the title screen at $95AF.","t":"code","b":[32,188,152],"m":"jsr","oa":39100,"o":"pause_check","x":[38710]},{"a":38649,"t":"code","b":[32,107,153],"m":"jsr","oa":39275,"o":"engine_sound"},{"a":38652,"t":"code","b":[230,137],"m":"inc","oa":137,"o":"phase_frames"},{"a":38654,"t":"code","b":[165,137],"m":"lda","oa":137,"o":"phase_frames"},{"a":38656,"t":"code","b":[201,80],"m":"cmp","o":"#$50"},{"a":38658,"t":"code","b":[144,6],"m":"bcc","oa":38666,"o":"b_970A"},{"a":38660,"t":"code","b":[32,199,138],"m":"jsr","oa":35527,"o":"msg_hide"},{"a":38663,"t":"code","b":[76,175,149],"m":"jmp","oa":38319,"o":"title_screen"},{"a":38666,"l":"b_970A","t":"code","b":[169,2],"m":"lda","o":"#$02","x":[38658]},{"a":38668,"t":"code","b":[133,92],"m":"sta","oa":92,"o":"stick_y"},{"a":38670,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38672,"t":"code","b":[133,91],"m":"sta","oa":91,"o":"stick_x"},{"a":38674,"t":"code","b":[32,108,152],"m":"jsr","oa":39020,"o":"turn_step"},{"a":38677,"t":"code","b":[32,230,187],"m":"jsr","oa":48102,"o":"erase_last_frame"},{"a":38680,"t":"code","b":[32,40,146],"m":"jsr","oa":37416,"o":"stars_restamp"},{"a":38683,"t":"code","b":[32,162,188],"m":"jsr","oa":48290,"o":"scroll_camera"},{"a":38686,"t":"code","b":[32,103,170],"m":"jsr","oa":43623,"o":"draw_horizon_hills"},{"a":38689,"t":"code","b":[32,63,186],"m":"jsr","oa":47679,"o":"draw_home_base"},{"a":38692,"t":"code","b":[32,113,185],"m":"jsr","oa":47473,"o":"draw_parallax_scenery"},{"a":38695,"t":"code","b":[32,174,184],"m":"jsr","oa":47278,"o":"draw_sheds"},{"a":38698,"t":"code","b":[32,125,155],"m":"jsr","oa":39805,"o":"hostages_update"},{"a":38701,"t":"code","b":[32,7,179],"m":"jsr","oa":45831,"o":"actor_dispatch"},{"a":38704,"t":"code","b":[32,31,141],"m":"jsr","oa":36127,"o":"show_draw_buffer"},{"a":38707,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":38710,"t":"code","b":[76,246,150],"m":"jmp","oa":38646,"o":"end_msg_loop"},{"a":38713,"l":"redraw_backdrop","c":"Repaint the scrolling backdrop into both screen buffers at the home view over the base. Sets the world position $75/$76 to $11D8 and hands the same word to $8C17, an inline-parameter call - the two bytes at $9744 are data, not an instruction - which latches it in $3B/$3C. The redraw itself is at $9746. Called at the start of the title screen, at the start of a game and before each sortie message.","t":"code","b":[169,216],"m":"lda","o":"#$D8","x":[38319,38374,38441]},{"a":38715,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":38717,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":38719,"t":"code","b":[133,118],"m":"sta","oa":118,"o":"zpa_76"},{"a":38721,"t":"code","b":[32,23,140],"m":"jsr","oa":35863,"o":"inline_window_x"},{"a":38724,"l":"redraw_backdrop_arg","c":"The inline parameter of the jsr to $8C17 at $9741: the pointer $0075, so $8C17 loads $3B/$3C with the word at $0075, the world position $9739 has just set to $11D8. These two bytes are data - $8C17 pops the return address, steps over them and resumes at $9746 - and must never be disassembled as an instruction.","t":"word","b":[117,0],"d":[117]},{"a":38726,"l":"redraw_backdrop_run","c":"The redraw half of $9739, after its two inline parameter bytes. Runs the backdrop-only part of the draw sequence twice - $BBE6 erase last frame, $9228 stars, $AA67 distant hills, $BA3F home base, then $8D1F to show the buffer and $8D16 to flip - so that both screen buffers end up holding the new view. The camera, the helicopter and the actor list are deliberately left out.","t":"code","b":[32,230,187],"m":"jsr","oa":48102,"o":"erase_last_frame"},{"a":38729,"t":"code","b":[32,40,146],"m":"jsr","oa":37416,"o":"stars_restamp"},{"a":38732,"t":"code","b":[32,103,170],"m":"jsr","oa":43623,"o":"draw_horizon_hills"},{"a":38735,"t":"code","b":[32,63,186],"m":"jsr","oa":47679,"o":"draw_home_base"},{"a":38738,"t":"code","b":[32,31,141],"m":"jsr","oa":36127,"o":"show_draw_buffer"},{"a":38741,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":38744,"t":"code","b":[32,230,187],"m":"jsr","oa":48102,"o":"erase_last_frame"},{"a":38747,"t":"code","b":[32,40,146],"m":"jsr","oa":37416,"o":"stars_restamp"},{"a":38750,"t":"code","b":[32,103,170],"m":"jsr","oa":43623,"o":"draw_horizon_hills"},{"a":38753,"t":"code","b":[32,63,186],"m":"jsr","oa":47679,"o":"draw_home_base"},{"a":38756,"t":"code","b":[32,31,141],"m":"jsr","oa":36127,"o":"show_draw_buffer"},{"a":38759,"t":"code","b":[76,22,141],"m":"jmp","oa":36118,"o":"flip_draw_buffer"},{"a":38762,"l":"joy_fire_carry","c":"Read the trigger of the joystick in control port 1: $DC01 bit 4, active low. Returns carry set when the button is down, carry clear when it is up, and destroys A. The attract loop at $95BB is the only caller; it uses this to decide when to start a game.","t":"code","b":[173,1,220],"m":"lda","oa":56321,"o":"$DC01","x":[38331]},{"a":38765,"t":"code","b":[41,16],"m":"and","o":"#$10"},{"a":38767,"t":"code","b":[24],"m":"clc"},{"a":38768,"t":"code","b":[208,1],"m":"bne","oa":38771,"o":"r_9773"},{"a":38770,"t":"code","b":[56],"m":"sec"},{"a":38771,"l":"r_9773","t":"code","b":[96],"m":"rts","x":[38768]},{"a":38772,"l":"fire_decode","c":"Decode the trigger once per flight pass, turning it into either a shot or a turn. $0B53 remembers whether the button was down last time and $96 counts raster frames with it down - $96 is incremented by the raster handler at $9A35 and cleared here whenever the button is up, so it is a real frame count and not a pass count. Button up and $0B53 already up: no trigger activity, so $983B settles any turn that was running. Button up with $0B53 set, the release edge: a hold shorter than $0F = 15 raster frames (about 0.3 s) is a tap and fires a shot through $97D2, 15 frames or more is a turn and goes to $97F1. Button down: $0B53 = $FF, and once $96 has reached 15 $97F1 is called on every pass. Verified live: a 0.1 s tap called $97D2 exactly once and $97F1 not at all, while a one-second hold called $97F1 and never $97D2.","t":"code","b":[173,1,220],"m":"lda","oa":56321,"o":"$DC01","x":[38562]},{"a":38775,"t":"code","b":[41,16],"m":"and","o":"#$10"},{"a":38777,"t":"code","b":[240,36],"m":"beq","oa":38815,"o":"b_979F"},{"a":38779,"t":"code","b":[44,83,11],"m":"bit","oa":2899,"o":"fire_debounce"},{"a":38782,"t":"code","b":[48,6],"m":"bmi","oa":38790,"o":"b_9786"},{"a":38784,"t":"code","b":[32,59,152],"m":"jsr","oa":38971,"o":"turn_end"},{"a":38787,"t":"code","b":[76,154,151],"m":"jmp","oa":38810,"o":"j_979A"},{"a":38790,"l":"b_9786","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[38782]},{"a":38792,"t":"code","b":[141,83,11],"m":"sta","oa":2899,"o":"fire_debounce"},{"a":38795,"t":"code","b":[165,150],"m":"lda","oa":150,"o":"zpa_96"},{"a":38797,"t":"code","b":[201,15],"m":"cmp","o":"#$0F"},{"a":38799,"t":"code","b":[144,6],"m":"bcc","oa":38807,"o":"b_9797"},{"a":38801,"t":"code","b":[32,241,151],"m":"jsr","oa":38897,"o":"turn_begin"},{"a":38804,"t":"code","b":[76,154,151],"m":"jmp","oa":38810,"o":"j_979A"},{"a":38807,"l":"b_9797","t":"code","b":[32,210,151],"m":"jsr","oa":38866,"o":"fire_shot_request","x":[38799]},{"a":38810,"l":"j_979A","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[38787,38804]},{"a":38812,"t":"code","b":[133,150],"m":"sta","oa":150,"o":"zpa_96"},{"a":38814,"t":"code","b":[96],"m":"rts"},{"a":38815,"l":"b_979F","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[38777]},{"a":38817,"t":"code","b":[141,83,11],"m":"sta","oa":2899,"o":"fire_debounce"},{"a":38820,"t":"code","b":[165,150],"m":"lda","oa":150,"o":"zpa_96"},{"a":38822,"t":"code","b":[201,15],"m":"cmp","o":"#$0F"},{"a":38824,"t":"code","b":[144,33],"m":"bcc","oa":38859,"o":"r_97CB"},{"a":38826,"t":"code","b":[76,241,151],"m":"jmp","oa":38897,"o":"turn_begin"},{"a":38829,"l":"fire_poll","c":"The same trigger test as $9774, called five more times spread through one flight pass (from $96AB, $96B1, $96BA, $96C6 and $96CF) so that a tap which begins and ends between the once-a-pass reads still fires. It handles the short tap only: on a release edge with $96 below 15 it clears $0B53 and calls $97D2. A release after 15 frames or more is left alone, $0B53 deliberately not cleared, so that $9774 still sees the long hold and treats it as a turn. Keeps $96 at zero for as long as the button is up.","t":"code","b":[173,1,220],"m":"lda","oa":56321,"o":"$DC01","x":[38571,38577,38586,38598,38607]},{"a":38832,"t":"code","b":[41,16],"m":"and","o":"#$10"},{"a":38834,"t":"code","b":[240,24],"m":"beq","oa":38860,"o":"b_97CC"},{"a":38836,"t":"code","b":[44,83,11],"m":"bit","oa":2899,"o":"fire_debounce"},{"a":38839,"t":"code","b":[16,14],"m":"bpl","oa":38855,"o":"b_97C7"},{"a":38841,"t":"code","b":[165,150],"m":"lda","oa":150,"o":"zpa_96"},{"a":38843,"t":"code","b":[201,15],"m":"cmp","o":"#$0F"},{"a":38845,"t":"code","b":[176,12],"m":"bcs","oa":38859,"o":"r_97CB"},{"a":38847,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38849,"t":"code","b":[141,83,11],"m":"sta","oa":2899,"o":"fire_debounce"},{"a":38852,"t":"code","b":[32,210,151],"m":"jsr","oa":38866,"o":"fire_shot_request"},{"a":38855,"l":"b_97C7","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[38839]},{"a":38857,"t":"code","b":[133,150],"m":"sta","oa":150,"o":"zpa_96"},{"a":38859,"l":"r_97CB","t":"code","b":[96],"m":"rts","x":[38824,38845]},{"a":38860,"l":"b_97CC","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[38834]},{"a":38862,"t":"code","b":[141,83,11],"m":"sta","oa":2899,"o":"fire_debounce"},{"a":38865,"t":"code","b":[96],"m":"rts"},{"a":38866,"l":"fire_shot_request","c":"Ask for a shot from the helicopter's gun; called on a short trigger tap. Refuses silently while the helicopter is on the ground ($5D = 0), while $61 marks it crashed, while a request is still pending ($64 bit 7 set) and once $0CF3, the number of the player's own shots still in the air, has reached 5. Otherwise it sets $64 = $FF, which $B004 turns into a new type-6 actor on the next pass while counting $0CF3 up, and fires the report through $A7C7: SID voice 3, frequency high byte $D40F = $3A, two raster frames long. Verified live: one 0.1 s tap took $0CF3 from 0 to 1.","t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up","x":[38807,38852]},{"a":38868,"t":"code","b":[240,26],"m":"beq","oa":38896,"o":"r_97F0"},{"a":38870,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":38872,"t":"code","b":[208,22],"m":"bne","oa":38896,"o":"r_97F0"},{"a":38874,"t":"code","b":[36,100],"m":"bit","oa":100,"o":"fire_latch"},{"a":38876,"t":"code","b":[48,18],"m":"bmi","oa":38896,"o":"r_97F0"},{"a":38878,"t":"code","b":[173,243,12],"m":"lda","oa":3315,"o":"shots_in_flight"},{"a":38881,"t":"code","b":[201,5],"m":"cmp","o":"#$05"},{"a":38883,"t":"code","b":[176,11],"m":"bcs","oa":38896,"o":"r_97F0"},{"a":38885,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":38887,"t":"code","b":[133,100],"m":"sta","oa":100,"o":"fire_latch"},{"a":38889,"t":"code","b":[162,58],"m":"ldx","o":"#$3A"},{"a":38891,"t":"code","b":[160,2],"m":"ldy","o":"#$02"},{"a":38893,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":38896,"l":"r_97F0","t":"code","b":[96],"m":"rts","x":[38868,38872,38876,38883]},{"a":38897,"l":"turn_begin","c":"Start turning the helicopter; called while the trigger has been held for 15 raster frames or more, and once more on its release. Does nothing while the helicopter is on the ground ($5D = 0, so you cannot turn while landed) or crashed ($61), and nothing at all if $0B54 already marks a turn as latched - so the direction is sampled once only, on the frame the hold crosses 15. It records the facing the turn started from in $8B and the facing it is heading for in $8A ($01 or $FF), which $986C then walks $59 towards one step per pass. Which way it goes depends on where the helicopter is pointing. With $59 at 0 or +/-1, near nose-on, the joystick decides: the read at $9816 keeps $DC01 bits 2 and 3 only, so left alone gives 2 and asks for $8A = $FF, while right, no direction at all, or both give $8A = $01. With $59 already at a full facing the stick is ignored entirely and the request is simply the opposite sign, so holding the trigger flips the helicopter to face the other way. Verified live: from $59 = 3, fire+left latched $0B54, set $8B = 3 and $8A = $FF and walked $59 to $FD, and fire with the stick centred did exactly the same; adding left after the hold had already latched changed nothing.","t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up","x":[38801,38826]},{"a":38899,"t":"code","b":[240,70],"m":"beq","oa":38971,"o":"turn_end"},{"a":38901,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":38903,"t":"code","b":[208,66],"m":"bne","oa":38971,"o":"turn_end"},{"a":38905,"t":"code","b":[173,84,11],"m":"lda","oa":2900,"o":"a_0B54"},{"a":38908,"t":"code","b":[208,109],"m":"bne","oa":39019,"o":"r_986B"},{"a":38910,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":38912,"t":"code","b":[141,84,11],"m":"sta","oa":2900,"o":"a_0B54"},{"a":38915,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":38917,"t":"code","b":[240,11],"m":"beq","oa":38930,"o":"b_9812"},{"a":38919,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":38921,"t":"code","b":[240,7],"m":"beq","oa":38930,"o":"b_9812"},{"a":38923,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":38925,"t":"code","b":[240,3],"m":"beq","oa":38930,"o":"b_9812"},{"a":38927,"t":"code","b":[76,36,152],"m":"jmp","oa":38948,"o":"j_9824"},{"a":38930,"l":"b_9812","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[38917,38921,38925]},{"a":38932,"t":"code","b":[133,139],"m":"sta","oa":139,"o":"zpa_8B"},{"a":38934,"s":"reads control port 1 again; after two shifts bits 2 and 3 are left and right, active low: 2 = left only, 1 = right only, 3 = neither, 0 = both","t":"code","b":[173,1,220],"m":"lda","oa":56321,"o":"$DC01"},{"a":38937,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":38938,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":38939,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":38941,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":38943,"t":"code","b":[240,19],"m":"beq","oa":38964,"o":"b_9834"},{"a":38945,"t":"code","b":[76,45,152],"m":"jmp","oa":38957,"o":"j_982D"},{"a":38948,"l":"j_9824","t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing","x":[38927]},{"a":38950,"t":"code","b":[133,139],"m":"sta","oa":139,"o":"zpa_8B"},{"a":38952,"t":"code","b":[48,3],"m":"bmi","oa":38957,"o":"j_982D"},{"a":38954,"t":"code","b":[76,52,152],"m":"jmp","oa":38964,"o":"b_9834"},{"a":38957,"l":"j_982D","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[38945,38952]},{"a":38959,"t":"code","b":[133,138],"m":"sta","oa":138,"o":"turn_request"},{"a":38961,"t":"code","b":[76,107,152],"m":"jmp","oa":39019,"o":"r_986B"},{"a":38964,"l":"b_9834","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[38943,38954]},{"a":38966,"t":"code","b":[133,138],"m":"sta","oa":138,"o":"turn_request"},{"a":38968,"t":"code","b":[76,107,152],"m":"jmp","oa":39019,"o":"r_986B"},{"a":38971,"l":"turn_end","c":"Called on every pass while the trigger is up, to finish a turn. Returns at once if $0B54 shows no turn was latched; otherwise it clears $0B54 and decides what $8A should be from here on. With $59 at 0 or +/-1 the helicopter settles nose-on and $8A = 0, which hands the facing back to the auto-tilt table at $98B0. Otherwise, if the turn began nose-on ($8B = 0) or has already swung past the middle (the signs of $8B and $59 differ), $8A is set to the sign of $59 so the turn runs on to the full facing without the trigger; if it has not yet crossed, $8A = 0 and the facing stops where it is.","t":"code","b":[173,84,11],"m":"lda","oa":2900,"o":"a_0B54","x":[38784,38899,38903]},{"a":38974,"t":"code","b":[240,43],"m":"beq","oa":39019,"o":"r_986B"},{"a":38976,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":38978,"t":"code","b":[141,84,11],"m":"sta","oa":2900,"o":"a_0B54"},{"a":38981,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":38983,"t":"code","b":[240,16],"m":"beq","oa":39001,"o":"b_9859"},{"a":38985,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":38987,"t":"code","b":[240,12],"m":"beq","oa":39001,"o":"b_9859"},{"a":38989,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":38991,"t":"code","b":[240,8],"m":"beq","oa":39001,"o":"b_9859"},{"a":38993,"t":"code","b":[165,139],"m":"lda","oa":139,"o":"zpa_8B"},{"a":38995,"t":"code","b":[240,9],"m":"beq","oa":39006,"o":"b_985E"},{"a":38997,"t":"code","b":[69,89],"m":"eor","oa":89,"o":"heli_facing"},{"a":38999,"t":"code","b":[48,5],"m":"bmi","oa":39006,"o":"b_985E"},{"a":39001,"l":"b_9859","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[38983,38987,38991]},{"a":39003,"t":"code","b":[133,138],"m":"sta","oa":138,"o":"turn_request"},{"a":39005,"t":"code","b":[96],"m":"rts"},{"a":39006,"l":"b_985E","t":"code","b":[36,89],"m":"bit","oa":89,"o":"heli_facing","x":[38995,38999]},{"a":39008,"t":"code","b":[48,5],"m":"bmi","oa":39015,"o":"b_9867"},{"a":39010,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":39012,"t":"code","b":[133,138],"m":"sta","oa":138,"o":"turn_request"},{"a":39014,"t":"code","b":[96],"m":"rts"},{"a":39015,"l":"b_9867","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[39008]},{"a":39017,"t":"code","b":[133,138],"m":"sta","oa":138,"o":"turn_request"},{"a":39019,"l":"r_986B","t":"code","b":[96],"m":"rts","x":[38908,38961,38968,38974]},{"a":39020,"l":"turn_step","c":"Move the helicopter's facing $59 one step per pass towards the facing asked for in $8A: $8A = $01 aims at +3, $8A = $FF at -3, and $8A = 0 takes the target from the table at $98B0 indexed by the horizontal speed $5A + 5, which is nose-on unless the helicopter is at full speed, when it tilts one step into its direction of travel. While a turn is being asked for the step never comes to rest on 0, so the helicopter sweeps through nose-on instead of pausing there. Called once per pass from the flight loop and from the closing loop.","t":"code","b":[165,138],"m":"lda","oa":138,"o":"turn_request","x":[38610,38674]},{"a":39022,"t":"code","b":[240,4],"m":"beq","oa":39028,"o":"b_9874"},{"a":39024,"t":"code","b":[16,14],"m":"bpl","oa":39040,"o":"b_9880"},{"a":39026,"t":"code","b":[48,17],"m":"bmi","oa":39045,"o":"b_9885"},{"a":39028,"l":"b_9874","t":"code","b":[24],"m":"clc","x":[39022]},{"a":39029,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":39031,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":39033,"t":"code","b":[170],"m":"tax"},{"a":39034,"t":"code","b":[189,176,152],"m":"lda","oa":39088,"o":"facing_target_tbl,x"},{"a":39037,"t":"code","b":[76,135,152],"m":"jmp","oa":39047,"o":"j_9887"},{"a":39040,"l":"b_9880","t":"code","b":[169,3],"m":"lda","o":"#$03","x":[39024]},{"a":39042,"t":"code","b":[76,135,152],"m":"jmp","oa":39047,"o":"j_9887"},{"a":39045,"l":"b_9885","t":"code","b":[169,253],"m":"lda","o":"#$FD","x":[39026]},{"a":39047,"l":"j_9887","t":"code","b":[197,89],"m":"cmp","oa":89,"o":"heli_facing","x":[39037,39042]},{"a":39049,"t":"code","b":[240,36],"m":"beq","oa":39087,"o":"r_98AF"},{"a":39051,"t":"code","b":[24],"m":"clc"},{"a":39052,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":39054,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":39056,"t":"code","b":[24],"m":"clc"},{"a":39057,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":39059,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":39061,"t":"code","b":[56],"m":"sec"},{"a":39062,"t":"code","b":[229,111],"m":"sbc","oa":111,"o":"zpa_6F"},{"a":39064,"t":"code","b":[48,11],"m":"bmi","oa":39077,"o":"b_98A5"},{"a":39066,"t":"code","b":[198,89],"m":"dec","oa":89,"o":"heli_facing"},{"a":39068,"t":"code","b":[208,17],"m":"bne","oa":39087,"o":"r_98AF"},{"a":39070,"t":"code","b":[165,138],"m":"lda","oa":138,"o":"turn_request"},{"a":39072,"t":"code","b":[240,13],"m":"beq","oa":39087,"o":"r_98AF"},{"a":39074,"t":"code","b":[198,89],"m":"dec","oa":89,"o":"heli_facing"},{"a":39076,"t":"code","b":[96],"m":"rts"},{"a":39077,"l":"b_98A5","t":"code","b":[230,89],"m":"inc","oa":89,"o":"heli_facing","x":[39064]},{"a":39079,"t":"code","b":[208,6],"m":"bne","oa":39087,"o":"r_98AF"},{"a":39081,"t":"code","b":[165,138],"m":"lda","oa":138,"o":"turn_request"},{"a":39083,"t":"code","b":[240,2],"m":"beq","oa":39087,"o":"r_98AF"},{"a":39085,"t":"code","b":[230,89],"m":"inc","oa":89,"o":"heli_facing"},{"a":39087,"l":"r_98AF","t":"code","b":[96],"m":"rts","x":[39049,39068,39072,39079,39083]},{"a":39088,"l":"facing_target_tbl","c":"Twelve target facings for $986C, indexed by the helicopter's horizontal speed $5A + 5, i.e. $5A from -5 to +6. Read only when no turn is being asked for: 01 01 at the two fastest speeds one way, FF FF at the two fastest the other, 00 for everything in between - the helicopter sits nose-on except at full speed, when it tilts one step into its direction of travel.","t":"byte","b":[1,1,0,0,0,0,0,0],"x":[39034]},{"a":39096,"t":"byte","b":[0,0,255,255]},{"a":39100,"l":"pause_check","c":"The pause key. Called once per pass in the sortie, flight and closing loops. $C5 is the KERNAL's scan code for the key currently held, refreshed fifty times a second by the $FF9F keyboard scan the raster handler runs at $9A63; $3F is RUN/STOP. When RUN/STOP is down it writes $D418 = 0 to silence the SID and then busy-waits three times in a row on $C5: for the key to be let go, for it to be pressed again, and for that second press to be let go. Then $D418 = $0F and the game carries on. Interrupts stay enabled throughout, so the screen split and the keyboard scan keep running while everything else is frozen. Verified live: forcing RUN/STOP stopped the pass counter $89 dead and dropped $D418 to 0, and a second press restored both.","t":"code","b":[165,197],"m":"lda","oa":197,"o":"zpa_C5","x":[38458,38622,38646]},{"a":39102,"t":"code","b":[201,63],"m":"cmp","o":"#$3F"},{"a":39104,"t":"code","b":[208,28],"m":"bne","oa":39134,"o":"r_98DE"},{"a":39106,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":39108,"s":"master volume 0 - the game is paused on RUN/STOP","t":"code","b":[141,24,212],"m":"sta","oa":54296,"o":"$D418"},{"a":39111,"l":"b_98C7","t":"code","b":[165,197],"m":"lda","oa":197,"o":"zpa_C5","x":[39115]},{"a":39113,"t":"code","b":[201,63],"m":"cmp","o":"#$3F"},{"a":39115,"t":"code","b":[240,250],"m":"beq","oa":39111,"o":"b_98C7"},{"a":39117,"l":"b_98CD","t":"code","b":[165,197],"m":"lda","oa":197,"o":"zpa_C5","x":[39121]},{"a":39119,"t":"code","b":[201,63],"m":"cmp","o":"#$3F"},{"a":39121,"t":"code","b":[208,250],"m":"bne","oa":39117,"o":"b_98CD"},{"a":39123,"l":"b_98D3","t":"code","b":[165,197],"m":"lda","oa":197,"o":"zpa_C5","x":[39127]},{"a":39125,"t":"code","b":[201,63],"m":"cmp","o":"#$3F"},{"a":39127,"t":"code","b":[240,250],"m":"beq","oa":39123,"o":"b_98D3"},{"a":39129,"t":"code","b":[169,15],"m":"lda","o":"#$0F"},{"a":39131,"s":"master volume back to 15 - RUN/STOP pressed a second time","t":"code","b":[141,24,212],"m":"sta","oa":54296,"o":"$D418"},{"a":39134,"l":"r_98DE","t":"code","b":[96],"m":"rts","x":[39104]},{"a":39135,"l":"screen_init","c":"One-time display set-up, called once from $959C. Points the NMI vector $0318/$0319 at $9AAB, the bare RTI, so the RESTORE key cannot break into the game. Fills both text screens, $0400-$07FF and $4400-$47FF, with the dot character $2E and the whole of colour RAM $D800-$DBFF with white; the $26 written through $071F,y runs 31 bytes past the end of the screen into $081E, and the store to $471F,y is assembled twice, but neither shows because those screen rows are always covered by the bitmap. Colours the status-bar rows yellow ($07 into $D828-$D851 and $D877-$D8A0, character rows 1 and 3), then runs the count/character list at $9956 to paint the status-bar frame into both screens, and finally zeroes $6D, $6E and $97, the index $9AAC starts its title text table from.","t":"code","b":[169,171],"m":"lda","o":"#$AB","x":[38303]},{"a":39137,"s":"NMI vector -> $9AAB, the bare RTI: RESTORE does nothing","t":"code","b":[141,24,3],"m":"sta","oa":792,"o":"nmi_vec_lo"},{"a":39140,"t":"code","b":[169,154],"m":"lda","o":"#$9A"},{"a":39142,"t":"code","b":[141,25,3],"m":"sta","oa":793,"o":"a_0319"},{"a":39145,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":39147,"l":"b_98EB","t":"code","b":[169,46],"m":"lda","o":"#$2E","x":[39199]},{"a":39149,"t":"code","b":[153,0,4],"m":"sta","oa":1024,"o":"f_0400,y"},{"a":39152,"t":"code","b":[153,0,5],"m":"sta","oa":1280,"o":"f_0500,y"},{"a":39155,"t":"code","b":[153,0,6],"m":"sta","oa":1536,"o":"f_0600,y"},{"a":39158,"t":"code","b":[153,0,7],"m":"sta","oa":1792,"o":"f_0700,y"},{"a":39161,"t":"code","b":[153,0,68],"m":"sta","oa":17408,"o":"f_4400,y"},{"a":39164,"t":"code","b":[153,0,69],"m":"sta","oa":17664,"o":"f_4500,y"},{"a":39167,"t":"code","b":[153,0,70],"m":"sta","oa":17920,"o":"f_4600,y"},{"a":39170,"t":"code","b":[153,0,71],"m":"sta","oa":18176,"o":"f_4700,y"},{"a":39173,"t":"code","b":[169,38],"m":"lda","o":"#$26"},{"a":39175,"t":"code","b":[153,31,7],"m":"sta","oa":1823,"o":"f_071F,y"},{"a":39178,"t":"code","b":[153,31,71],"m":"sta","oa":18207,"o":"f_471F,y"},{"a":39181,"t":"code","b":[153,31,71],"m":"sta","oa":18207,"o":"f_471F,y"},{"a":39184,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":39186,"t":"code","b":[153,0,216],"m":"sta","oa":55296,"o":"f_D800,y"},{"a":39189,"t":"code","b":[153,0,217],"m":"sta","oa":55552,"o":"f_D900,y"},{"a":39192,"t":"code","b":[153,0,218],"m":"sta","oa":55808,"o":"f_DA00,y"},{"a":39195,"t":"code","b":[153,0,219],"m":"sta","oa":56064,"o":"f_DB00,y"},{"a":39198,"t":"code","b":[136],"m":"dey"},{"a":39199,"t":"code","b":[208,202],"m":"bne","oa":39147,"o":"b_98EB"},{"a":39201,"t":"code","b":[169,7],"m":"lda","o":"#$07"},{"a":39203,"t":"code","b":[160,41],"m":"ldy","o":"#$29"},{"a":39205,"l":"b_9925","t":"code","b":[153,40,216],"m":"sta","oa":55336,"o":"f_D828,y","x":[39212]},{"a":39208,"t":"code","b":[153,119,216],"m":"sta","oa":55415,"o":"f_D877,y"},{"a":39211,"t":"code","b":[136],"m":"dey"},{"a":39212,"t":"code","b":[16,247],"m":"bpl","oa":39205,"o":"b_9925"},{"a":39214,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":39216,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":39218,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":39220,"t":"code","b":[133,151],"m":"sta","oa":151,"o":"zpa_97"},{"a":39222,"l":"j_9936","t":"code","b":[166,109],"m":"ldx","oa":109,"o":"zpa_6D","x":[39250]},{"a":39224,"t":"code","b":[188,86,153],"m":"ldy","oa":39254,"o":"status_frame_rle,x"},{"a":39227,"t":"code","b":[240,24],"m":"beq","oa":39253,"o":"r_9955"},{"a":39229,"t":"code","b":[232],"m":"inx"},{"a":39230,"t":"code","b":[189,86,153],"m":"lda","oa":39254,"o":"status_frame_rle,x"},{"a":39233,"t":"code","b":[232],"m":"inx"},{"a":39234,"t":"code","b":[134,109],"m":"stx","oa":109,"o":"zpa_6D"},{"a":39236,"t":"code","b":[166,110],"m":"ldx","oa":110,"o":"zpa_6E"},{"a":39238,"l":"b_9946","t":"code","b":[157,0,4],"m":"sta","oa":1024,"o":"f_0400,x","x":[39246]},{"a":39241,"t":"code","b":[157,0,68],"m":"sta","oa":17408,"o":"f_4400,x"},{"a":39244,"t":"code","b":[232],"m":"inx"},{"a":39245,"t":"code","b":[136],"m":"dey"},{"a":39246,"t":"code","b":[208,246],"m":"bne","oa":39238,"o":"b_9946"},{"a":39248,"t":"code","b":[134,110],"m":"stx","oa":110,"o":"zpa_6E"},{"a":39250,"t":"code","b":[76,54,153],"m":"jmp","oa":39222,"o":"j_9936"},{"a":39253,"l":"r_9955","t":"code","b":[96],"m":"rts","x":[39227]},{"a":39254,"l":"status_frame_rle","c":"The status-bar frame, as a run-length list painted into the first 160 cells of both text screens by $98DF: pairs of count and screen code, ending with a count of 0. Row 0 is 40 spaces; row 1 is $55, 38 of $44, $49; row 2 is $54, 38 spaces, $59; row 3 is $4A, 38 of $46, $4B. In the C64 character ROM those are the four rounded corners and the matching two-pixel edge bars - $44 sits low in its cell and $46 high, so the box closes up neatly two pixel rows above the line where the raster handler hands the screen over to the bitmap. The 38 spaces of row 2 are where $BB2B stamps the spade, diamond and heart counters and where the rescue tallies are printed.","t":"byte","b":[40,32,1,85,38,68,1,73],"x":[39224,39230]},{"a":39262,"t":"byte","b":[1,84,38,32,1,89,1,74]},{"a":39270,"t":"byte","b":[38,70,1,75,0]},{"a":39275,"l":"engine_sound","c":"The helicopter's engine and rotor, run once per pass. $A7BA gates it: nothing happens unless $8C says a game is running and $62 is not 6 (helicopter destroyed), and $0CE0 must be set as well, otherwise voice 1 is silenced with $D404 = 0 and $95 = $FF parks the rotor beat. When it does run, voice 1 is gated on as a pulse ($D404 = $81) and its frequency low byte, kept in $0B5E, is walked $10 at a time between $30 and $C0 and written to $D400 - upwards while $5D says the helicopter is airborne, downwards once it is on the ground - so the engine note climbs as it lifts off and falls as it settles. The same step walks $94 the other way, from $11 down to 8; $94 is the reload for $95, the number of raster frames the raster handler leaves between retriggers of SID voice 2 at $9A4C, so the rotor beat speeds up in step with the engine note. Measured in flight: $0B5E = $C0 with $94 = 8.","t":"code","b":[32,186,167],"m":"jsr","oa":42938,"o":"sound_enabled","x":[38344,38461,38565,38649]},{"a":39278,"t":"code","b":[176,47],"m":"bcs","oa":39327,"o":"b_999F"},{"a":39280,"t":"code","b":[173,224,12],"m":"lda","oa":3296,"o":"engine_on"},{"a":39283,"t":"code","b":[240,42],"m":"beq","oa":39327,"o":"b_999F"},{"a":39285,"t":"code","b":[169,129],"m":"lda","o":"#$81"},{"a":39287,"s":"voice 1 on, pulse waveform, gate set - the engine drone","t":"code","b":[141,4,212],"m":"sta","oa":54276,"o":"$D404"},{"a":39290,"t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up"},{"a":39292,"t":"code","b":[240,14],"m":"beq","oa":39308,"o":"b_998C"},{"a":39294,"t":"code","b":[173,94,11],"m":"lda","oa":2910,"o":"a_0B5E"},{"a":39297,"t":"code","b":[201,192],"m":"cmp","o":"#$C0"},{"a":39299,"t":"code","b":[240,25],"m":"beq","oa":39326,"o":"r_999E"},{"a":39301,"t":"code","b":[198,148],"m":"dec","oa":148,"o":"zpa_94"},{"a":39303,"t":"code","b":[24],"m":"clc"},{"a":39304,"t":"code","b":[105,16],"m":"adc","o":"#$10"},{"a":39306,"t":"code","b":[144,12],"m":"bcc","oa":39320,"o":"b_9998"},{"a":39308,"l":"b_998C","t":"code","b":[173,94,11],"m":"lda","oa":2910,"o":"a_0B5E","x":[39292]},{"a":39311,"t":"code","b":[201,48],"m":"cmp","o":"#$30"},{"a":39313,"t":"code","b":[240,11],"m":"beq","oa":39326,"o":"r_999E"},{"a":39315,"t":"code","b":[230,148],"m":"inc","oa":148,"o":"zpa_94"},{"a":39317,"t":"code","b":[56],"m":"sec"},{"a":39318,"t":"code","b":[233,16],"m":"sbc","o":"#$10"},{"a":39320,"l":"b_9998","t":"code","b":[141,94,11],"m":"sta","oa":2910,"o":"a_0B5E","x":[39306]},{"a":39323,"s":"engine pitch: voice 1 frequency low byte, $30 on the ground rising to $C0 in the air","t":"code","b":[141,0,212],"m":"sta","oa":54272,"o":"$D400"},{"a":39326,"l":"r_999E","t":"code","b":[96],"m":"rts","x":[39299,39313]},{"a":39327,"l":"b_999F","t":"code","b":[162,0],"m":"ldx","o":"#$00","x":[39278,39283]},{"a":39329,"s":"voice 1 gate cleared: engine silent outside a game or after a crash","t":"code","b":[142,4,212],"m":"stx","oa":54276,"o":"$D404"},{"a":39332,"t":"code","b":[202],"m":"dex"},{"a":39333,"t":"code","b":[134,149],"m":"stx","oa":149,"o":"zpa_95"},{"a":39335,"t":"code","b":[96],"m":"rts"},{"a":39336,"l":"irq_midwin_open","c":"Raster handler branch for line $81 (129), the top of the middle text window. Switches the VIC back to single-colour text with the character base at $1000 ($D011 bit 5 clear, $D016 bit 4 clear, $D018 bits 3-1 = %010) so that a message or the title block can be read over the play area. How deep the window goes depends on $93: clear means an in-game message, two character rows, and the next interrupt is set at $91 (145); set means the title block, five rows, next interrupt at $A9 (169). Never runs while a game is quietly in progress - measured 0 hits over two seconds of flight.","t":"code","b":[173,17,208],"m":"lda","oa":53265,"o":"$D011","x":[39415]},{"a":39339,"t":"code","b":[41,223],"m":"and","o":"#$DF"},{"a":39341,"t":"code","b":[141,17,208],"m":"sta","oa":53265,"o":"$D011"},{"a":39344,"t":"code","b":[173,24,208],"m":"lda","oa":53272,"o":"$D018"},{"a":39347,"t":"code","b":[41,241],"m":"and","o":"#$F1"},{"a":39349,"t":"code","b":[9,4],"m":"ora","o":"#$04"},{"a":39351,"t":"code","b":[141,24,208],"m":"sta","oa":53272,"o":"$D018"},{"a":39354,"t":"code","b":[173,22,208],"m":"lda","oa":53270,"o":"$D016"},{"a":39357,"t":"code","b":[41,239],"m":"and","o":"#$EF"},{"a":39359,"t":"code","b":[141,22,208],"m":"sta","oa":53270,"o":"$D016"},{"a":39362,"t":"code","b":[169,145],"m":"lda","o":"#$91"},{"a":39364,"t":"code","b":[164,147],"m":"ldy","oa":147,"o":"text_window_tall"},{"a":39366,"t":"code","b":[240,2],"m":"beq","oa":39370,"o":"b_99CA"},{"a":39368,"t":"code","b":[169,169],"m":"lda","o":"#$A9"},{"a":39370,"l":"b_99CA","t":"code","b":[141,18,208],"m":"sta","oa":53266,"o":"$D012","x":[39366]},{"a":39373,"t":"code","b":[76,161,154],"m":"jmp","oa":39585,"o":"irq_exit"},{"a":39376,"l":"irq_midwin_close","c":"Raster handler branch for lines $91 (145) and $A9 (169), the bottom of the middle text window. Puts the multicolour bitmap back for the rest of the play area - $D018 bits 3-1 = %100 so the bitmap base is $2000 inside the current VIC bank, $D016 bit 4 multicolour on, $D011 bit 5 bitmap on - and sets the next interrupt at $E0.","t":"code","b":[173,24,208],"m":"lda","oa":53272,"o":"$D018","x":[39430,39434]},{"a":39379,"t":"code","b":[41,241],"m":"and","o":"#$F1"},{"a":39381,"t":"code","b":[9,8],"m":"ora","o":"#$08"},{"a":39383,"t":"code","b":[141,24,208],"m":"sta","oa":53272,"o":"$D018"},{"a":39386,"t":"code","b":[173,22,208],"m":"lda","oa":53270,"o":"$D016"},{"a":39389,"t":"code","b":[9,16],"m":"ora","o":"#$10"},{"a":39391,"t":"code","b":[141,22,208],"m":"sta","oa":53270,"o":"$D016"},{"a":39394,"t":"code","b":[173,17,208],"m":"lda","oa":53265,"o":"$D011"},{"a":39397,"t":"code","b":[9,32],"m":"ora","o":"#$20"},{"a":39399,"t":"code","b":[141,17,208],"m":"sta","oa":53265,"o":"$D011"},{"a":39402,"t":"code","b":[169,224],"m":"lda","o":"#$E0"},{"a":39404,"t":"code","b":[141,18,208],"m":"sta","oa":53266,"o":"$D012"},{"a":39407,"t":"code","b":[76,161,154],"m":"jmp","oa":39585,"o":"irq_exit"},{"a":39410,"l":"raster_irq","c":"The raster interrupt handler, installed in $0314/$0315 by $A75C and reached through the KERNAL's $FF48 with A, X and Y already on the stack. It works out what to do from the raster line it reads in $D012 rather than from a stored step number: $1E goes to $9A13, $51 to $9A69, $E0 to $9A94, $81 to $99A8, $91 and $A9 to $99D0, and any other value straight to the acknowledge at $9AA1. Between them those handlers cut the frame into bands - black text at the top for the status bar, multicolour bitmap for the play area, an optional text window in the middle for a message or the title block, and grey below line $E0 for the ground - and carry the game's whole 50 Hz heartbeat: the frame counter for the trigger hold, the two SID voices that are driven by frame counts, and the KERNAL keyboard scan. Measured during play: 304 entries over 102 raster frames, three a frame, with $9A13, $9A69 and $9A94 taking 102 each.","t":"code","b":[172,18,208],"m":"ldy","oa":53266,"o":"$D012"},{"a":39413,"t":"code","b":[192,129],"m":"cpy","o":"#$81"},{"a":39415,"t":"code","b":[240,175],"m":"beq","oa":39336,"o":"irq_midwin_open"},{"a":39417,"t":"code","b":[192,81],"m":"cpy","o":"#$51"},{"a":39419,"t":"code","b":[240,108],"m":"beq","oa":39529,"o":"irq_bitmap_on"},{"a":39421,"t":"code","b":[192,224],"m":"cpy","o":"#$E0"},{"a":39423,"t":"code","b":[208,3],"m":"bne","oa":39428,"o":"b_9A04"},{"a":39425,"t":"code","b":[76,148,154],"m":"jmp","oa":39572,"o":"irq_ground"},{"a":39428,"l":"b_9A04","t":"code","b":[192,169],"m":"cpy","o":"#$A9","x":[39423]},{"a":39430,"t":"code","b":[240,200],"m":"beq","oa":39376,"o":"irq_midwin_close"},{"a":39432,"t":"code","b":[192,145],"m":"cpy","o":"#$91"},{"a":39434,"t":"code","b":[240,196],"m":"beq","oa":39376,"o":"irq_midwin_close"},{"a":39436,"t":"code","b":[192,30],"m":"cpy","o":"#$1E"},{"a":39438,"t":"code","b":[240,3],"m":"beq","oa":39443,"o":"irq_top_text"},{"a":39440,"t":"code","b":[76,161,154],"m":"jmp","oa":39585,"o":"irq_exit"},{"a":39443,"l":"irq_top_text","c":"Raster $1E (line 30), in the top border above the visible screen. Sets up the status bar: single-colour text with the character base at $1000, and border and background both black, which is the night sky the whole play area is drawn on. Then does the per-frame housekeeping the rest of the game depends on. $96 counts raster frames, which is what $9774 and $97AD measure a trigger hold against. $98 counts down the length of the current sound effect and gates SID voice 3 on ($D412 = $11, triangle) while it lasts, off and clamped to 0 when it runs out; $A7C7 is what sets it. $95 counts down the rotor beat and, on reaching zero, retriggers voice 2 by writing $D40B = 0 then $81 and reloads itself from $94. Finally $0291 = $80 locks the character set against the shift/Commodore switch and $FF9F scans the keyboard, which is the only reason $C5 is live for the RUN/STOP pause in $98BC. Next interrupt at $51.","t":"code","b":[173,17,208],"m":"lda","oa":53265,"o":"$D011","x":[39438]},{"a":39446,"t":"code","b":[41,223],"m":"and","o":"#$DF"},{"a":39448,"t":"code","b":[141,17,208],"m":"sta","oa":53265,"o":"$D011"},{"a":39451,"t":"code","b":[173,22,208],"m":"lda","oa":53270,"o":"$D016"},{"a":39454,"t":"code","b":[41,239],"m":"and","o":"#$EF"},{"a":39456,"t":"code","b":[141,22,208],"m":"sta","oa":53270,"o":"$D016"},{"a":39459,"t":"code","b":[173,24,208],"m":"lda","oa":53272,"o":"$D018"},{"a":39462,"t":"code","b":[41,241],"m":"and","o":"#$F1"},{"a":39464,"t":"code","b":[9,4],"m":"ora","o":"#$04"},{"a":39466,"t":"code","b":[141,24,208],"m":"sta","oa":53272,"o":"$D018"},{"a":39469,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":39471,"t":"code","b":[141,32,208],"m":"sta","oa":53280,"o":"$D020"},{"a":39474,"t":"code","b":[141,33,208],"m":"sta","oa":53281,"o":"$D021"},{"a":39477,"s":"the raster frame counter $9774 and $97AD measure a trigger hold against","t":"code","b":[230,150],"m":"inc","oa":150,"o":"zpa_96"},{"a":39479,"t":"code","b":[198,152],"m":"dec","oa":152,"o":"zpa_98"},{"a":39481,"t":"code","b":[16,7],"m":"bpl","oa":39490,"o":"b_9A42"},{"a":39483,"s":"voice 3 gate off: the sound effect started by $A7C7 has run out its $98 frames","t":"code","b":[141,18,212],"m":"sta","oa":54290,"o":"$D412"},{"a":39486,"t":"code","b":[133,152],"m":"sta","oa":152,"o":"zpa_98"},{"a":39488,"t":"code","b":[48,5],"m":"bmi","oa":39495,"o":"b_9A47"},{"a":39490,"l":"b_9A42","t":"code","b":[169,17],"m":"lda","o":"#$11","x":[39481]},{"a":39492,"s":"voice 3 triangle + gate on: a sound effect is still sounding","t":"code","b":[141,18,212],"m":"sta","oa":54290,"o":"$D412"},{"a":39495,"l":"b_9A47","t":"code","b":[169,81],"m":"lda","o":"#$51","x":[39488]},{"a":39497,"t":"code","b":[141,18,208],"m":"sta","oa":53266,"o":"$D012"},{"a":39500,"t":"code","b":[198,149],"m":"dec","oa":149,"o":"zpa_95"},{"a":39502,"t":"code","b":[208,14],"m":"bne","oa":39518,"o":"b_9A5E"},{"a":39504,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":39506,"s":"voice 2 gate off, then on again at $9A57: one beat of the rotor, every $94 raster frames","t":"code","b":[141,11,212],"m":"sta","oa":54283,"o":"$D40B"},{"a":39509,"t":"code","b":[169,129],"m":"lda","o":"#$81"},{"a":39511,"t":"code","b":[141,11,212],"m":"sta","oa":54283,"o":"$D40B"},{"a":39514,"t":"code","b":[165,148],"m":"lda","oa":148,"o":"zpa_94"},{"a":39516,"t":"code","b":[133,149],"m":"sta","oa":149,"o":"zpa_95"},{"a":39518,"l":"b_9A5E","t":"code","b":[169,128],"m":"lda","o":"#$80","x":[39502]},{"a":39520,"t":"code","b":[141,145,2],"m":"sta","oa":657,"o":"kernal_shift_mode"},{"a":39523,"s":"KERNAL SCNKEY: the only thing that keeps $C5 current for the RUN/STOP pause at $98BC","t":"code","b":[32,159,255],"m":"jsr","oa":65439,"o":"s_FF9F"},{"a":39526,"t":"code","b":[76,161,154],"m":"jmp","oa":39585,"o":"irq_exit"},{"a":39529,"l":"irq_bitmap_on","c":"Raster $51 (line 81), a few pixel rows into character row 3 and just below the bottom edge of the status-bar frame. Switches the play area on: multicolour bitmap with the bitmap base at $2000 inside the current VIC bank ($D018 bits 3-1 = %100, $D016 bit 4, $D011 bit 5). The next interrupt is $E0 when the bitmap is to run uninterrupted to the ground, or $81 when either $02 (a sortie or end-of-game message is up - $8A8B sets it, $8AC7 clears it) or $93 (the title block - $9AAC sets it, $9B56 clears it) is non-zero, which opens the middle text window. Confirmed live by forcing each of the two variables: $02 alone gives two character rows of text over the play area, $93 gives five.","t":"code","b":[173,24,208],"m":"lda","oa":53272,"o":"$D018","x":[39419]},{"a":39532,"t":"code","b":[41,241],"m":"and","o":"#$F1"},{"a":39534,"t":"code","b":[9,8],"m":"ora","o":"#$08"},{"a":39536,"t":"code","b":[141,24,208],"m":"sta","oa":53272,"o":"$D018"},{"a":39539,"t":"code","b":[173,22,208],"m":"lda","oa":53270,"o":"$D016"},{"a":39542,"t":"code","b":[9,16],"m":"ora","o":"#$10"},{"a":39544,"t":"code","b":[141,22,208],"m":"sta","oa":53270,"o":"$D016"},{"a":39547,"t":"code","b":[173,17,208],"m":"lda","oa":53265,"o":"$D011"},{"a":39550,"t":"code","b":[9,32],"m":"ora","o":"#$20"},{"a":39552,"t":"code","b":[141,17,208],"m":"sta","oa":53265,"o":"$D011"},{"a":39555,"t":"code","b":[160,224],"m":"ldy","o":"#$E0"},{"a":39557,"t":"code","b":[165,2],"m":"lda","oa":2,"o":"msg_showing"},{"a":39559,"t":"code","b":[24],"m":"clc","x":[32852]},{"a":39560,"t":"code","b":[101,147],"m":"adc","oa":147,"o":"text_window_tall"},{"a":39562,"t":"code","b":[240,2],"m":"beq","oa":39566,"o":"b_9A8E"},{"a":39564,"t":"code","b":[160,129],"m":"ldy","o":"#$81"},{"a":39566,"l":"b_9A8E","t":"code","b":[140,18,208],"m":"sty","oa":53266,"o":"$D012","x":[39562]},{"a":39569,"t":"code","b":[76,161,154],"m":"jmp","oa":39585,"o":"irq_exit"},{"a":39572,"l":"irq_ground","c":"Raster $E0 (line 224). Paints border and background grey ($0C) for the rest of the frame. The bitmap is left switched on, so this is not drawn scenery: the ground the helicopter lands on, and the bottom border under it, are simply the background colour showing through the unset bit pairs of the multicolour bitmap from line 224 down. Sets the next interrupt back at $1E.","t":"code","b":[169,12],"m":"lda","o":"#$0C","x":[39425]},{"a":39574,"t":"code","b":[141,32,208],"m":"sta","oa":53280,"o":"$D020"},{"a":39577,"t":"code","b":[141,33,208],"m":"sta","oa":53281,"o":"$D021"},{"a":39580,"t":"code","b":[169,30],"m":"lda","o":"#$1E"},{"a":39582,"t":"code","b":[141,18,208],"m":"sta","oa":53266,"o":"$D012"},{"a":39585,"l":"irq_exit","c":"The common tail of every branch of the raster handler: acknowledges the VIC raster interrupt with $D019 = 1 and pulls Y, X and A back off the stack, in the order the KERNAL's $FF48 pushed them, before the RTI at $9AAB.","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[39373,39407,39440,39526,39569]},{"a":39587,"t":"code","b":[141,25,208],"m":"sta","oa":53273,"o":"$D019"},{"a":39590,"t":"code","b":[104],"m":"pla"},{"a":39591,"t":"code","b":[168],"m":"tay"},{"a":39592,"t":"code","b":[104],"m":"pla"},{"a":39593,"t":"code","b":[170],"m":"tax"},{"a":39594,"t":"code","b":[104],"m":"pla"},{"a":39595,"l":"nmi_rti","c":"The NMI handler - $98DF points $0318/$0319 here - which is nothing but the RTI that ends the raster handler, shared between the two. The KERNAL's NMI entry at $FE43 jumps through $0318 before it has saved a single register, so landing on an RTI returns to the interrupted instruction with the status register restored and nothing else touched. That is the RESTORE key defence: RESTORE cannot stop the game or drop it back to BASIC. Verified live: six RESTORE presses reached $FE43 six times and the game did not miss a pass.","t":"code","b":[64],"m":"rti"},{"a":39596,"l":"title_text_draw","c":"Draw the title block on the attract screen and open the text window it needs. $93 = 1 tells the raster handler to give five character rows in the middle of the screen to text instead of bitmap (raster $81 to $A9, character rows 10 to 14). Those 200 cells are then cleared to spaces in both screens, $0400-based and $4400-based, and coloured white in colour RAM. It walks the table at $9AF9 from index $97 in four-byte entries - a pointer to a zero-terminated screen-code string, then the screen address to copy it to - and writes each string into both screens, the second by ORing $40 into the destination high byte. It stops after the fifth entry and leaves $97 = 4, so the first call after $98DF draws all five lines and every later call redraws only the last four; BRODERBUND SOFTWARE PRESENTS sits on character row 2, outside the cleared block, and is written once and never disturbed.","t":"code","b":[160,1],"m":"ldy","o":"#$01","x":[38328]},{"a":39598,"s":"$93 = 1: ask the raster handler for a five-row text window instead of two","t":"code","b":[132,147],"m":"sty","oa":147,"o":"text_window_tall"},{"a":39600,"t":"code","b":[160,200],"m":"ldy","o":"#$C8"},{"a":39602,"l":"b_9AB2","t":"code","b":[169,32],"m":"lda","o":"#$20","x":[39616]},{"a":39604,"t":"code","b":[153,143,5],"m":"sta","oa":1423,"o":"f_058F,y"},{"a":39607,"t":"code","b":[153,143,69],"m":"sta","oa":17807,"o":"f_458F,y"},{"a":39610,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":39612,"t":"code","b":[153,143,217],"m":"sta","oa":55695,"o":"f_D98F,y"},{"a":39615,"t":"code","b":[136],"m":"dey"},{"a":39616,"t":"code","b":[208,240],"m":"bne","oa":39602,"o":"b_9AB2"},{"a":39618,"t":"code","b":[166,151],"m":"ldx","oa":151,"o":"zpa_97"},{"a":39620,"l":"b_9AC4","t":"code","b":[189,249,154],"m":"lda","oa":39673,"o":"title_text_table,x","x":[39666]},{"a":39623,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":39625,"t":"code","b":[232],"m":"inx"},{"a":39626,"t":"code","b":[189,249,154],"m":"lda","oa":39673,"o":"title_text_table,x"},{"a":39629,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":39631,"t":"code","b":[232],"m":"inx"},{"a":39632,"t":"code","b":[189,249,154],"m":"lda","oa":39673,"o":"title_text_table,x"},{"a":39635,"t":"code","b":[133,143],"m":"sta","oa":143,"o":"zpa_8F"},{"a":39637,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":39639,"t":"code","b":[232],"m":"inx"},{"a":39640,"t":"code","b":[189,249,154],"m":"lda","oa":39673,"o":"title_text_table,x"},{"a":39643,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":39645,"t":"code","b":[9,64],"m":"ora","o":"#$40"},{"a":39647,"t":"code","b":[133,144],"m":"sta","oa":144,"o":"zpa_90"},{"a":39649,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":39651,"l":"j_9AE3","t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y","x":[39660]},{"a":39653,"t":"code","b":[240,8],"m":"beq","oa":39663,"o":"b_9AEF"},{"a":39655,"t":"code","b":[145,109],"m":"sta","oa":109,"o":"(zpa_6D),y"},{"a":39657,"t":"code","b":[145,143],"m":"sta","oa":143,"o":"(zpa_8F),y"},{"a":39659,"t":"code","b":[200],"m":"iny"},{"a":39660,"t":"code","b":[76,227,154],"m":"jmp","oa":39651,"o":"j_9AE3"},{"a":39663,"l":"b_9AEF","t":"code","b":[232],"m":"inx","x":[39653]},{"a":39664,"t":"code","b":[224,20],"m":"cpx","o":"#$14"},{"a":39666,"t":"code","b":[208,208],"m":"bne","oa":39620,"o":"b_9AC4"},{"a":39668,"t":"code","b":[162,4],"m":"ldx","o":"#$04"},{"a":39670,"t":"code","b":[134,151],"m":"stx","oa":151,"o":"zpa_97"},{"a":39672,"t":"code","b":[96],"m":"rts"},{"a":39673,"l":"title_text_table","c":"Title-screen text table, the only reader is $9AAC. Five entries of four bytes: string address low/high then screen address low/high, all little-endian. $9B0D->$0456, $9B2A->$059F, $9B36->$05FA, $9B41->$0622, $9B4D->$064A. $9AAC walks it from the byte index held in $97 up to 20, copying each zero-terminated screen-code string into BOTH text matrices ($0400 and its $4400 twin), then leaves $97 = 4 so a later call redraws only the last four lines and not the BRODERBUND banner.","t":"addr","b":[13,155],"oa":39693,"o":"title_str_broderbund","x":[39620,39626,39632,39640]},{"a":39675,"t":"addr","b":[86,4],"oa":1110,"o":"a_0456"},{"a":39677,"t":"addr","b":[42,155],"oa":39722,"o":"title_str_choplifter"},{"a":39679,"t":"addr","b":[159,5],"oa":1439,"o":"a_059F"},{"a":39681,"t":"addr","b":[54,155],"oa":39734,"o":"title_str_dan_gorlin"},{"a":39683,"t":"addr","b":[250,5],"oa":1530,"o":"a_05FA"},{"a":39685,"t":"addr","b":[65,155],"oa":39745,"o":"title_str_dane_bigham"},{"a":39687,"t":"addr","b":[34,6],"oa":1570,"o":"a_0622"},{"a":39689,"t":"addr","b":[77,155],"oa":39757,"o":"title_str_copyright"},{"a":39691,"t":"addr","b":[74,6],"oa":1610,"o":"a_064A"},{"a":39693,"l":"title_str_broderbund","c":"Zero-terminated screen codes, 28 characters: BRODERBUND SOFTWARE PRESENTS. Entry 0 of the table at $9AF9 stamps it at screen offset $0456, row 2 column 6, centred in 40 columns.","t":"byte","b":[2,18,48,4,5,18,2,21],"x":[39673]},{"a":39701,"t":"byte","b":[14,4,32,19,15,6,20,23]},{"a":39709,"t":"byte","b":[1,18,5,32,16,18,5,19]},{"a":39717,"t":"byte","b":[5,14,20,19,0]},{"a":39722,"l":"title_str_choplifter","c":"Zero-terminated screen codes, 11 characters: CHOPLIFTER! - the game's own title line. Entry 1 of $9AF9 stamps it at $059F, row 10 column 15, centred.","t":"byte","b":[3,8,15,16,12,9,6,20],"x":[39677]},{"a":39730,"t":"byte","b":[5,18,33,0]},{"a":39734,"l":"title_str_dan_gorlin","c":"Zero-terminated screen codes, 10 characters: DAN GORLIN, the designer credit. Entry 2 of $9AF9 stamps it at $05FA, row 12 column 26.","t":"byte","b":[4,1,14,32,7,15,18,12],"x":[39681]},{"a":39742,"t":"byte","b":[9,14,0]},{"a":39745,"l":"title_str_dane_bigham","c":"Zero-terminated screen codes, 11 characters: DANE BIGHAM, the second credit line. Entry 3 of $9AF9 stamps it at $0622, row 13 column 26, directly under DAN GORLIN.","t":"byte","b":[4,1,14,5,32,2,9,7],"x":[39685]},{"a":39753,"t":"byte","b":[8,1,13,0]},{"a":39757,"l":"title_str_copyright","c":"Zero-terminated screen codes, 8 characters: (C) 1982. Entry 4, the last, of the table at $9AF9; stamped at $064A, row 14 column 26.","t":"byte","b":[40,3,41,32,49,57,56,50],"x":[39689]},{"a":39765,"t":"byte","b":[0]},{"a":39766,"l":"title_exit_repaint","c":"Wipes the title text and lays out the playing screen. Called once, from $95C0, at the moment the attract loop at $95BB sees the fire button and drops out of the demo. Fills $0590-$068F (screen rows 10 to 16) with $2E and the matching colour RAM at $D990 with $01, in both screen buffers: those are the multicolour-bitmap attribute pairs for the sky, and the region covers every row the five title strings occupied. Then fills $0451-$0476 - row 2, columns 1 to 38 - with $A0 (reverse space) and colour $02, which is the red status bar the suit glyphs and the three two-digit counters are later stamped into. Verified live: an execution checkpoint here scored 0 hits across 118 game ticks of play, so despite sitting in the middle of the game's code nothing in the play loop calls it.","t":"code","b":[160,0],"m":"ldy","o":"#$00","x":[38336]},{"a":39768,"t":"code","b":[132,147],"m":"sty","oa":147,"o":"text_window_tall"},{"a":39770,"l":"b_9B5A","t":"code","b":[169,46],"m":"lda","o":"#$2E","x":[39784]},{"a":39772,"t":"code","b":[153,144,5],"m":"sta","oa":1424,"o":"f_0590,y"},{"a":39775,"t":"code","b":[153,144,69],"m":"sta","oa":17808,"o":"f_4590,y"},{"a":39778,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":39780,"t":"code","b":[153,144,217],"m":"sta","oa":55696,"o":"f_D990,y"},{"a":39783,"t":"code","b":[136],"m":"dey"},{"a":39784,"t":"code","b":[208,240],"m":"bne","oa":39770,"o":"b_9B5A"},{"a":39786,"t":"code","b":[160,37],"m":"ldy","o":"#$25"},{"a":39788,"l":"b_9B6C","t":"code","b":[169,160],"m":"lda","o":"#$A0","x":[39802]},{"a":39790,"t":"code","b":[153,81,4],"m":"sta","oa":1105,"o":"f_0451,y"},{"a":39793,"t":"code","b":[153,81,68],"m":"sta","oa":17489,"o":"f_4451,y"},{"a":39796,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":39798,"t":"code","b":[153,81,216],"m":"sta","oa":55377,"o":"f_D851,y"},{"a":39801,"t":"code","b":[136],"m":"dey"},{"a":39802,"t":"code","b":[16,240],"m":"bpl","oa":39788,"o":"b_9B6C"},{"a":39804,"t":"code","b":[96],"m":"rts"},{"a":39805,"l":"hostages_update","c":"Moves, decides for and draws all sixteen hostages. Called once per game tick from $96C9 and $972A (117 hits in 118 ticks, measured with a live checkpoint). Iterates $0B55 = 0..15 over the sixteen four-byte records based at $0CA0: +0 animation phase, bit 7 set means the slot is free; +1 state (0 = standing and waving, $01 = walking right, $FF = walking left, $02/$FE = climbing into the helicopter); +2/+3 world X, little-endian. A walker moves two world units per tick; the phase counts 0..3 and the state is re-decided each time it wraps. A hostage who has walked past $12B5, or whose page is $12 or more, has reached the right-hand end of the map: the slot is freed and $0CF2 (hostages loose around the home base) drops by one. Which way he walks: when $61 is non-zero (the helicopter has been destroyed) he runs away from it; otherwise he walks toward it, but only while the helicopter is on the ground ($5D = 0), not parked on the home pad ($5F = 0) and not already carrying sixteen ($0CF1 < $10); at other times he wanders, the coin flips coming from $DC04 via $A933. Contact is tested only while the helicopter is down and motionless ($5E non-zero) and not wrecked: signed distance -9..+7 from the helicopter means it is standing on him and he is killed ($9E14); exactly +8/+9 on the right or -11/-10 on the left is the doorway and he climbs aboard ($9D18), unless $0CF1 already holds sixteen, in which case he simply stops. Drawing chooses shape-table entries 59,60,61,60 for the waving idle, 55..58 for the walk cycle and 62 then 63 for climbing in, and hands each to $9DDA.","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[38601,38698]},{"a":39807,"t":"code","b":[141,85,11],"m":"sta","oa":2901,"o":"person_index"},{"a":39810,"t":"code","b":[170],"m":"tax"},{"a":39811,"l":"j_9B83","t":"code","b":[189,160,12],"m":"lda","oa":3232,"o":"person_state,x","x":[40406]},{"a":39814,"t":"code","b":[16,3],"m":"bpl","oa":39819,"o":"b_9B8B"},{"a":39816,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":39819,"l":"b_9B8B","t":"code","b":[56],"m":"sec","x":[39814]},{"a":39820,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":39823,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":39825,"t":"code","b":[240,29],"m":"beq","oa":39856,"o":"b_9BB0"},{"a":39827,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":39829,"t":"code","b":[144,25],"m":"bcc","oa":39856,"o":"b_9BB0"},{"a":39831,"t":"code","b":[201,254],"m":"cmp","o":"#$FE"},{"a":39833,"t":"code","b":[176,21],"m":"bcs","oa":39856,"o":"b_9BB0"},{"a":39835,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":39838,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":39840,"t":"code","b":[176,3],"m":"bcs","oa":39845,"o":"b_9BA5"},{"a":39842,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":39845,"l":"b_9BA5","t":"code","b":[206,242,12],"m":"dec","oa":3314,"o":"a_0CF2","x":[39840]},{"a":39848,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":39850,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":39853,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":39856,"l":"b_9BB0","t":"code","b":[189,161,12],"m":"lda","oa":3233,"o":"person_dir,x","x":[39825,39829,39833]},{"a":39859,"t":"code","b":[240,38],"m":"beq","oa":39899,"o":"b_9BDB"},{"a":39861,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":39863,"t":"code","b":[240,20],"m":"beq","oa":39885,"o":"b_9BCD"},{"a":39865,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":39867,"t":"code","b":[208,30],"m":"bne","oa":39899,"o":"b_9BDB"},{"a":39869,"t":"code","b":[24],"m":"clc"},{"a":39870,"t":"code","b":[189,162,12],"m":"lda","oa":3234,"o":"person_x,x"},{"a":39873,"t":"code","b":[105,2],"m":"adc","o":"#$02"},{"a":39875,"t":"code","b":[157,162,12],"m":"sta","oa":3234,"o":"person_x,x"},{"a":39878,"t":"code","b":[144,19],"m":"bcc","oa":39899,"o":"b_9BDB"},{"a":39880,"t":"code","b":[254,163,12],"m":"inc","oa":3235,"o":"person_x_hi,x"},{"a":39883,"t":"code","b":[176,14],"m":"bcs","oa":39899,"o":"b_9BDB"},{"a":39885,"l":"b_9BCD","t":"code","b":[56],"m":"sec","x":[39863]},{"a":39886,"t":"code","b":[189,162,12],"m":"lda","oa":3234,"o":"person_x,x"},{"a":39889,"t":"code","b":[233,2],"m":"sbc","o":"#$02"},{"a":39891,"t":"code","b":[157,162,12],"m":"sta","oa":3234,"o":"person_x,x"},{"a":39894,"t":"code","b":[176,3],"m":"bcs","oa":39899,"o":"b_9BDB"},{"a":39896,"t":"code","b":[222,163,12],"m":"dec","oa":3235,"o":"person_x_hi,x"},{"a":39899,"l":"b_9BDB","t":"code","b":[254,160,12],"m":"inc","oa":3232,"o":"person_state,x","x":[39859,39867,39878,39883,39894]},{"a":39902,"t":"code","b":[189,160,12],"m":"lda","oa":3232,"o":"person_state,x"},{"a":39905,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":39907,"t":"code","b":[176,3],"m":"bcs","oa":39912,"o":"b_9BE8"},{"a":39909,"t":"code","b":[76,122,156],"m":"jmp","oa":40058,"o":"j_9C7A"},{"a":39912,"l":"b_9BE8","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[39907]},{"a":39914,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":39917,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":39919,"t":"code","b":[240,23],"m":"beq","oa":39944,"o":"b_9C08"},{"a":39921,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":39924,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":39926,"t":"code","b":[176,13],"m":"bcs","oa":39941,"o":"b_9C05"},{"a":39928,"t":"code","b":[56],"m":"sec"},{"a":39929,"t":"code","b":[189,162,12],"m":"lda","oa":3234,"o":"person_x,x"},{"a":39932,"t":"code","b":[229,85],"m":"sbc","oa":85,"o":"world_x"},{"a":39934,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":39937,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":39939,"t":"code","b":[48,105],"m":"bmi","oa":40046,"o":"b_9C6E"},{"a":39941,"l":"b_9C05","t":"code","b":[76,117,156],"m":"jmp","oa":40053,"o":"j_9C75","x":[39926]},{"a":39944,"l":"b_9C08","t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up","x":[39919]},{"a":39946,"t":"code","b":[208,23],"m":"bne","oa":39971,"o":"b_9C23"},{"a":39948,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":39951,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":39953,"t":"code","b":[144,16],"m":"bcc","oa":39971,"o":"b_9C23"},{"a":39955,"t":"code","b":[142,86,11],"m":"stx","oa":2902,"o":"a_0B56"},{"a":39958,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":39961,"t":"code","b":[174,86,11],"m":"ldx","oa":2902,"o":"a_0B56"},{"a":39964,"t":"code","b":[41,41],"m":"and","o":"#$29"},{"a":39966,"t":"code","b":[240,57],"m":"beq","oa":40025,"o":"b_9C59"},{"a":39968,"t":"code","b":[76,117,156],"m":"jmp","oa":40053,"o":"j_9C75"},{"a":39971,"l":"b_9C23","t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up","x":[39946,39953]},{"a":39973,"t":"code","b":[208,27],"m":"bne","oa":40002,"o":"b_9C42"},{"a":39975,"t":"code","b":[165,95],"m":"lda","oa":95,"o":"zpa_5F"},{"a":39977,"t":"code","b":[208,23],"m":"bne","oa":40002,"o":"b_9C42"},{"a":39979,"t":"code","b":[173,241,12],"m":"lda","oa":3313,"o":"a_0CF1"},{"a":39982,"t":"code","b":[201,16],"m":"cmp","o":"#$10"},{"a":39984,"t":"code","b":[240,16],"m":"beq","oa":40002,"o":"b_9C42"},{"a":39986,"t":"code","b":[56],"m":"sec"},{"a":39987,"t":"code","b":[189,162,12],"m":"lda","oa":3234,"o":"person_x,x"},{"a":39990,"t":"code","b":[229,85],"m":"sbc","oa":85,"o":"world_x"},{"a":39992,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":39995,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":39997,"t":"code","b":[16,47],"m":"bpl","oa":40046,"o":"b_9C6E"},{"a":39999,"t":"code","b":[76,117,156],"m":"jmp","oa":40053,"o":"j_9C75"},{"a":40002,"l":"b_9C42","t":"code","b":[142,86,11],"m":"stx","oa":2902,"o":"a_0B56","x":[39973,39977,39984]},{"a":40005,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":40008,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":40010,"t":"code","b":[174,86,11],"m":"ldx","oa":2902,"o":"a_0B56"},{"a":40013,"t":"code","b":[41,9],"m":"and","o":"#$09"},{"a":40015,"t":"code","b":[240,3],"m":"beq","oa":40020,"o":"b_9C54"},{"a":40017,"t":"code","b":[76,122,156],"m":"jmp","oa":40058,"o":"j_9C7A"},{"a":40020,"l":"b_9C54","t":"code","b":[189,161,12],"m":"lda","oa":3233,"o":"person_dir,x","x":[40015]},{"a":40023,"t":"code","b":[240,8],"m":"beq","oa":40033,"o":"b_9C61"},{"a":40025,"l":"b_9C59","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[39966]},{"a":40027,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40030,"t":"code","b":[76,122,156],"m":"jmp","oa":40058,"o":"j_9C7A"},{"a":40033,"l":"b_9C61","t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x","x":[40023]},{"a":40036,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":40038,"t":"code","b":[176,13],"m":"bcs","oa":40053,"o":"j_9C75"},{"a":40040,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":40042,"t":"code","b":[41,32],"m":"and","o":"#$20"},{"a":40044,"t":"code","b":[240,7],"m":"beq","oa":40053,"o":"j_9C75"},{"a":40046,"l":"b_9C6E","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[39939,39997]},{"a":40048,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40051,"t":"code","b":[48,5],"m":"bmi","oa":40058,"o":"j_9C7A"},{"a":40053,"l":"j_9C75","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[39941,39968,39999,40038,40044]},{"a":40055,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40058,"l":"j_9C7A","t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x","x":[39909,40017,40030,40051]},{"a":40061,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":40063,"t":"code","b":[208,18],"m":"bne","oa":40083,"o":"b_9C93"},{"a":40065,"t":"code","b":[189,162,12],"m":"lda","oa":3234,"o":"person_x,x"},{"a":40068,"t":"code","b":[201,181],"m":"cmp","o":"#$B5"},{"a":40070,"t":"code","b":[144,11],"m":"bcc","oa":40083,"o":"b_9C93"},{"a":40072,"t":"code","b":[206,242,12],"m":"dec","oa":3314,"o":"a_0CF2"},{"a":40075,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":40077,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40080,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":40083,"l":"b_9C93","t":"code","b":[165,94],"m":"lda","oa":94,"o":"zpa_5E","x":[40063,40070]},{"a":40085,"t":"code","b":[240,7],"m":"beq","oa":40094,"o":"b_9C9E"},{"a":40087,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":40089,"t":"code","b":[208,3],"m":"bne","oa":40094,"o":"b_9C9E"},{"a":40091,"t":"code","b":[76,161,156],"m":"jmp","oa":40097,"o":"j_9CA1"},{"a":40094,"l":"b_9C9E","t":"code","b":[76,86,157],"m":"jmp","oa":40278,"o":"j_9D56","x":[40085,40089,40102,40111]},{"a":40097,"l":"j_9CA1","t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x","x":[40091]},{"a":40100,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":40102,"t":"code","b":[176,246],"m":"bcs","oa":40094,"o":"b_9C9E"},{"a":40104,"t":"code","b":[189,161,12],"m":"lda","oa":3233,"o":"person_dir,x"},{"a":40107,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":40109,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":40111,"t":"code","b":[240,237],"m":"beq","oa":40094,"o":"b_9C9E"},{"a":40113,"t":"code","b":[56],"m":"sec"},{"a":40114,"t":"code","b":[189,162,12],"m":"lda","oa":3234,"o":"person_x,x"},{"a":40117,"t":"code","b":[229,85],"m":"sbc","oa":85,"o":"world_x"},{"a":40119,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":40121,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":40124,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":40126,"t":"code","b":[240,7],"m":"beq","oa":40135,"o":"b_9CC7"},{"a":40128,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":40130,"t":"code","b":[240,47],"m":"beq","oa":40179,"o":"b_9CF3"},{"a":40132,"t":"code","b":[76,86,157],"m":"jmp","oa":40278,"o":"j_9D56"},{"a":40135,"l":"b_9CC7","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[40126]},{"a":40137,"t":"code","b":[201,8],"m":"cmp","o":"#$08"},{"a":40139,"t":"code","b":[144,19],"m":"bcc","oa":40160,"o":"b_9CE0"},{"a":40141,"t":"code","b":[201,10],"m":"cmp","o":"#$0A"},{"a":40143,"t":"code","b":[176,18],"m":"bcs","oa":40163,"o":"b_9CE3"},{"a":40145,"t":"code","b":[173,241,12],"m":"lda","oa":3313,"o":"a_0CF1"},{"a":40148,"t":"code","b":[201,16],"m":"cmp","o":"#$10"},{"a":40150,"t":"code","b":[240,14],"m":"beq","oa":40166,"o":"b_9CE6"},{"a":40152,"t":"code","b":[169,254],"m":"lda","o":"#$FE"},{"a":40154,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40157,"t":"code","b":[76,24,157],"m":"jmp","oa":40216,"o":"j_9D18"},{"a":40160,"l":"b_9CE0","t":"code","b":[76,80,157],"m":"jmp","oa":40272,"o":"j_9D50","x":[40139]},{"a":40163,"l":"b_9CE3","t":"code","b":[76,86,157],"m":"jmp","oa":40278,"o":"j_9D56","x":[40143]},{"a":40166,"l":"b_9CE6","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[40150]},{"a":40168,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40171,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":40173,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40176,"t":"code","b":[76,86,157],"m":"jmp","oa":40278,"o":"j_9D56"},{"a":40179,"l":"b_9CF3","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[40130]},{"a":40181,"t":"code","b":[201,247],"m":"cmp","o":"#$F7"},{"a":40183,"t":"code","b":[176,87],"m":"bcs","oa":40272,"o":"j_9D50"},{"a":40185,"t":"code","b":[201,245],"m":"cmp","o":"#$F5"},{"a":40187,"t":"code","b":[144,89],"m":"bcc","oa":40278,"o":"j_9D56"},{"a":40189,"t":"code","b":[173,241,12],"m":"lda","oa":3313,"o":"a_0CF1"},{"a":40192,"t":"code","b":[201,16],"m":"cmp","o":"#$10"},{"a":40194,"t":"code","b":[240,7],"m":"beq","oa":40203,"o":"b_9D0B"},{"a":40196,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":40198,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40201,"t":"code","b":[208,13],"m":"bne","oa":40216,"o":"j_9D18"},{"a":40203,"l":"b_9D0B","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[40194]},{"a":40205,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40208,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":40210,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40213,"t":"code","b":[76,86,157],"m":"jmp","oa":40278,"o":"j_9D56"},{"a":40216,"l":"j_9D18","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[40157,40201]},{"a":40218,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40221,"t":"code","b":[238,241,12],"m":"inc","oa":3313,"o":"a_0CF1"},{"a":40224,"t":"code","b":[206,240,12],"m":"dec","oa":3312,"o":"a_0CF0"},{"a":40227,"t":"code","b":[32,186,163],"m":"jsr","oa":41914,"o":"aboard_counter_inc"},{"a":40230,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":40232,"t":"code","b":[141,0,13],"m":"sta","oa":3328,"o":"a_0D00"},{"a":40235,"t":"code","b":[44,1,13],"m":"bit","oa":3329,"o":"a_0D01"},{"a":40238,"t":"code","b":[48,29],"m":"bmi","oa":40269,"o":"b_9D4D"},{"a":40240,"t":"code","b":[142,86,11],"m":"stx","oa":2902,"o":"a_0B56"},{"a":40243,"t":"code","b":[162,36],"m":"ldx","o":"#$24"},{"a":40245,"t":"code","b":[160,2],"m":"ldy","o":"#$02"},{"a":40247,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":40250,"t":"code","b":[162,51],"m":"ldx","o":"#$33"},{"a":40252,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":40255,"t":"code","b":[162,72],"m":"ldx","o":"#$48"},{"a":40257,"t":"code","b":[200],"m":"iny"},{"a":40258,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":40261,"t":"code","b":[174,86,11],"m":"ldx","oa":2902,"o":"a_0B56"},{"a":40264,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":40266,"t":"code","b":[141,1,13],"m":"sta","oa":3329,"o":"a_0D01"},{"a":40269,"l":"b_9D4D","t":"code","b":[76,86,157],"m":"jmp","oa":40278,"o":"j_9D56","x":[40238]},{"a":40272,"l":"j_9D50","t":"code","b":[32,20,158],"m":"jsr","oa":40468,"o":"hostage_killed_by_helicopter","x":[40160,40183]},{"a":40275,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":40278,"l":"j_9D56","t":"code","b":[189,161,12],"m":"lda","oa":3233,"o":"person_dir,x","x":[40094,40132,40163,40176,40187,40213,40269]},{"a":40281,"t":"code","b":[133,119],"m":"sta","oa":119,"o":"zpa_77"},{"a":40283,"t":"code","b":[240,7],"m":"beq","oa":40292,"o":"b_9D64"},{"a":40285,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":40287,"t":"code","b":[208,35],"m":"bne","oa":40324,"o":"b_9D84"},{"a":40289,"t":"code","b":[76,158,157],"m":"jmp","oa":40350,"o":"j_9D9E"},{"a":40292,"l":"b_9D64","t":"code","b":[189,160,12],"m":"lda","oa":3232,"o":"person_state,x","x":[40283]},{"a":40295,"t":"code","b":[10],"m":"asl","o":"a"},{"a":40296,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":40298,"t":"code","b":[61,160,12],"m":"and","oa":3232,"o":"person_state,x"},{"a":40301,"t":"code","b":[10],"m":"asl","o":"a"},{"a":40302,"t":"code","b":[168],"m":"tay"},{"a":40303,"t":"code","b":[185,127,128],"m":"lda","oa":32895,"o":"shape_ptr_man_wave,y"},{"a":40306,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":40308,"t":"code","b":[185,128,128],"m":"lda","oa":32896,"o":"shape_ptr_man_wave_hi,y"},{"a":40311,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":40313,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":40316,"l":"arg_hostage_wave_shape","c":"Inline argument of the $8BE0 at $9D79: the pointer $0065. $8BE0 copies the word at zero page $65/$66 into $37/$38, and the four instructions above loaded $65/$66 from shape-table entry 59 + a 0,1,2,1 ping-pong of the animation phase - the standing hostage waving his arms.","t":"word","b":[101,0],"d":[101]},{"a":40318,"l":"hostage_draw_waving","c":"Tail of the waving-hostage case: calls the shape plotter $9DDA with the arm-waving frame already in $37/$38 and rejoins the per-slot loop at $9DC9. The branch target at $9D84 that follows is the walking case: it takes the animation phase 0..3 directly as the frame number and loads shape-table entry 55 + phase into $65/$66 for the $8BE0 below.","t":"code","b":[32,218,157],"m":"jsr","oa":40410,"o":"hostage_draw"},{"a":40321,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":40324,"l":"b_9D84","t":"code","b":[189,160,12],"m":"lda","oa":3232,"o":"person_state,x","x":[40287]},{"a":40327,"t":"code","b":[10],"m":"asl","o":"a"},{"a":40328,"t":"code","b":[168],"m":"tay"},{"a":40329,"t":"code","b":[185,119,128],"m":"lda","oa":32887,"o":"shape_ptr_man_run,y"},{"a":40332,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":40334,"t":"code","b":[185,120,128],"m":"lda","oa":32888,"o":"shape_ptr_man_run_hi,y"},{"a":40337,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":40339,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":40342,"l":"arg_hostage_walk_shape","c":"Inline argument of the $8BE0 at $9D93: the pointer $0065, where the code just put the address of shape-table entry 55 + animation phase, one of the four frames of the hostage's walk cycle.","t":"word","b":[101,0],"d":[101]},{"a":40344,"l":"hostage_draw_walking","c":"Tail of the walking-hostage case: plots the walk frame through $9DDA and rejoins the loop at $9DC9. The branch target at $9D9E that follows handles the two states $02 and $FE, a hostage climbing into the helicopter: bit 1 of the animation phase picks shape-table entry 62 (ducking at the door) or 63 (all but gone) into $65/$66 for the $8BE0 below.","t":"code","b":[32,218,157],"m":"jsr","oa":40410,"o":"hostage_draw"},{"a":40347,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":40350,"l":"j_9D9E","t":"code","b":[189,160,12],"m":"lda","oa":3232,"o":"person_state,x","x":[40289]},{"a":40353,"t":"code","b":[41,2],"m":"and","o":"#$02"},{"a":40355,"t":"code","b":[168],"m":"tay"},{"a":40356,"t":"code","b":[185,133,128],"m":"lda","oa":32901,"o":"shape_ptr_man_board,y"},{"a":40359,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":40361,"t":"code","b":[185,134,128],"m":"lda","oa":32902,"o":"shape_ptr_scenery,y"},{"a":40364,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":40366,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":40369,"l":"arg_hostage_board_shape","c":"Inline argument of the $8BE0 at $9DAE: the pointer $0065, holding the address of shape-table entry 62 or 63, the two frames of a hostage disappearing into the helicopter's door.","t":"word","b":[101,0],"d":[101]},{"a":40371,"l":"hostage_draw_boarding","c":"Tail of the climbing-aboard case and the loop control. Plots the boarding frame through $9DDA, then frees the slot ($0CA0,x = $FF) once the animation phase reaches 3 or the helicopter has stopped sitting still ($5E = 0). $9DC9 advances $0B55, multiplies it by four for the next record and goes back to $9B83 until all sixteen slots have been done.","t":"code","b":[32,218,157],"m":"jsr","oa":40410,"o":"hostage_draw"},{"a":40374,"t":"code","b":[189,160,12],"m":"lda","oa":3232,"o":"person_state,x"},{"a":40377,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":40379,"t":"code","b":[240,7],"m":"beq","oa":40388,"o":"b_9DC4"},{"a":40381,"t":"code","b":[165,94],"m":"lda","oa":94,"o":"zpa_5E"},{"a":40383,"t":"code","b":[240,3],"m":"beq","oa":40388,"o":"b_9DC4"},{"a":40385,"t":"code","b":[76,201,157],"m":"jmp","oa":40393,"o":"j_9DC9"},{"a":40388,"l":"b_9DC4","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[40379,40383]},{"a":40390,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40393,"l":"j_9DC9","t":"code","b":[238,85,11],"m":"inc","oa":2901,"o":"person_index","x":[39816,39842,39853,40080,40275,40321,40347,40385]},{"a":40396,"t":"code","b":[173,85,11],"m":"lda","oa":2901,"o":"person_index"},{"a":40399,"t":"code","b":[201,16],"m":"cmp","o":"#$10"},{"a":40401,"t":"code","b":[240,6],"m":"beq","oa":40409,"o":"r_9DD9"},{"a":40403,"t":"code","b":[10],"m":"asl","o":"a"},{"a":40404,"t":"code","b":[10],"m":"asl","o":"a"},{"a":40405,"t":"code","b":[170],"m":"tax"},{"a":40406,"t":"code","b":[76,131,155],"m":"jmp","oa":39811,"o":"j_9B83"},{"a":40409,"l":"r_9DD9","t":"code","b":[96],"m":"rts","x":[40401]},{"a":40410,"l":"hostage_draw","c":"Plots one hostage. Entered with X = the record offset (4 * slot) and the shape's bitmap address already in $37/$38; $77 holds the hostage's state. Computes the draw position into $67/$68/$69: X is the hostage's world X minus 4, with its low bit forced to agree with the scroll parity in $75 so the four-pixel-wide figure lands on a multicolour pixel boundary, and Y is the ground level $58 plus 11. Hands that to $8BF9 (inline pointer $0067), calls the clipper $8F03 and gives up silently if the hostage is off-screen. Otherwise registers the figure in the per-frame object list through $AA38 with kind code $11 - hostages are the only thing in the game filed under $11 - and blits it with $8FD3 for the right-facing states or $903E, the mirroring plotter, when the state is negative and he is walking left.","t":"code","b":[56],"m":"sec","x":[40318,40344,40371]},{"a":40411,"t":"code","b":[189,162,12],"m":"lda","oa":3234,"o":"person_x,x"},{"a":40414,"t":"code","b":[233,4],"m":"sbc","o":"#$04"},{"a":40416,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":40418,"t":"code","b":[189,163,12],"m":"lda","oa":3235,"o":"person_x_hi,x"},{"a":40421,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":40423,"t":"code","b":[133,104],"m":"sta","oa":104,"o":"zpa_68"},{"a":40425,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":40427,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":40429,"t":"code","b":[73,1],"m":"eor","o":"#$01"},{"a":40431,"t":"code","b":[69,103],"m":"eor","oa":103,"o":"draw_wx"},{"a":40433,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":40435,"t":"code","b":[24],"m":"clc"},{"a":40436,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":40438,"t":"code","b":[105,11],"m":"adc","o":"#$0B"},{"a":40440,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":40442,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":40445,"l":"arg_hostage_draw_pos","c":"Inline argument of the $8BF9 at $9DFA: the pointer $0067. $8BF9 copies the three bytes at zero page $67/$68/$69 into $34/$35/$36, which is the hostage's draw position - world X low, world X high, and Y - as computed by the eight instructions above.","t":"word","b":[103,0],"d":[103]},{"a":40447,"l":"hostage_draw_blit","c":"Rest of $9DDA: clip with $8F03 and return quietly with carry set if the hostage is off-screen; otherwise file him in the frame's object list as kind $11 via $AA38 and jump into the shape plotter, $8FD3 for a right-facing figure, $903E for the mirrored left-facing one.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":40450,"t":"code","b":[176,15],"m":"bcs","oa":40467,"o":"r_9E13"},{"a":40452,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":40454,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":40457,"t":"code","b":[165,119],"m":"lda","oa":119,"o":"zpa_77"},{"a":40459,"t":"code","b":[48,3],"m":"bmi","oa":40464,"o":"b_9E10"},{"a":40461,"t":"code","b":[76,211,143],"m":"jmp","oa":36819,"o":"draw_shape"},{"a":40464,"l":"b_9E10","t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored","x":[40459]},{"a":40467,"l":"r_9E13","t":"code","b":[96],"m":"rts","x":[40450]},{"a":40468,"l":"hostage_killed_by_helicopter","c":"The helicopter has settled on top of a hostage. Called from $9D50, reached when the horizontal distance between a hostage and the helicopter is in -9..+7 while the machine is on the ground and still. Frees the record (X = 4 * slot, $0CA0,x = $FF), adds one to $0CEF, the tally of hostages lost, takes one off $0CF0, the count still walking about in the field, and tail-jumps to $B0D2, which bumps the BCD casualty counter $0CFC, redraws the leftmost status-bar figure and plays the falling three-note sting. $0CEE (delivered) plus $0CEF (lost) reaching $40 is what ends the game at $9683: there are 64 hostages in a run.","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[40272]},{"a":40470,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40473,"t":"code","b":[238,239,12],"m":"inc","oa":3311,"o":"hostages_lost"},{"a":40476,"t":"code","b":[206,240,12],"m":"dec","oa":3312,"o":"a_0CF0"},{"a":40479,"t":"code","b":[76,210,176],"m":"jmp","oa":45266,"o":"count_person_lost"},{"a":40482,"l":"hostage_release_tick","c":"Decides whether a new hostage should appear this tick, and is the only thing that creates one. Called from $A363 on every fourth tick (30 hits per 118 ticks, measured live). Does nothing if $0CF2 + $0CF0 - the hostages loose at the base plus those loose in the field - already comes to sixteen. If the helicopter is parked on the home pad ($5F non-zero) and carrying anybody ($0CF1 > 0), goes to $9E88 to put one down. Otherwise, provided some are still shut in the barracks ($0CED > 0) and fewer than five are already out in the field, goes to $9E49 to let one out of a barracks.","t":"code","b":[24],"m":"clc","x":[41833]},{"a":40483,"t":"code","b":[173,242,12],"m":"lda","oa":3314,"o":"a_0CF2"},{"a":40486,"t":"code","b":[109,240,12],"m":"adc","oa":3312,"o":"a_0CF0"},{"a":40489,"t":"code","b":[201,16],"m":"cmp","o":"#$10"},{"a":40491,"t":"code","b":[240,27],"m":"beq","oa":40520,"o":"r_9E48"},{"a":40493,"t":"code","b":[165,95],"m":"lda","oa":95,"o":"zpa_5F"},{"a":40495,"t":"code","b":[208,15],"m":"bne","oa":40512,"o":"b_9E40"},{"a":40497,"t":"code","b":[173,237,12],"m":"lda","oa":3309,"o":"a_0CED"},{"a":40500,"t":"code","b":[240,18],"m":"beq","oa":40520,"o":"r_9E48"},{"a":40502,"t":"code","b":[173,240,12],"m":"lda","oa":3312,"o":"a_0CF0"},{"a":40505,"t":"code","b":[201,5],"m":"cmp","o":"#$05"},{"a":40507,"t":"code","b":[176,11],"m":"bcs","oa":40520,"o":"r_9E48"},{"a":40509,"t":"code","b":[76,73,158],"m":"jmp","oa":40521,"o":"barracks_pick"},{"a":40512,"l":"b_9E40","t":"code","b":[173,241,12],"m":"lda","oa":3313,"o":"a_0CF1","x":[40495]},{"a":40515,"t":"code","b":[240,3],"m":"beq","oa":40520,"o":"r_9E48"},{"a":40517,"t":"code","b":[76,136,158],"m":"jmp","oa":40584,"o":"j_9E88"},{"a":40520,"l":"r_9E48","t":"code","b":[96],"m":"rts","x":[40491,40500,40507,40515]},{"a":40521,"l":"barracks_pick","c":"Chooses which of the four barracks releases the next hostage and leaves its index 0..3 in $0B57. A barracks is eligible only if its open flag $0CF4+n is non-zero and it still holds somebody, $0CF8+n > 0. First preference is the barracks the helicopter is standing over: the world-X page $56 minus 3, which makes the four barracks the map pages $03, $04, $05 and $06. Failing that it takes a random start from $DC04, masks it to 0..3 and scans all four in a ring, giving up silently if none is eligible. Live, $0CF8-$0CFB held 16, 16, 16 and 8 and $0CED held 56.","t":"code","b":[56],"m":"sec","x":[40509]},{"a":40522,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":40524,"t":"code","b":[233,3],"m":"sbc","o":"#$03"},{"a":40526,"t":"code","b":[48,18],"m":"bmi","oa":40546,"o":"b_9E62"},{"a":40528,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":40530,"t":"code","b":[176,14],"m":"bcs","oa":40546,"o":"b_9E62"},{"a":40532,"t":"code","b":[170],"m":"tax"},{"a":40533,"t":"code","b":[189,244,12],"m":"lda","oa":3316,"o":"ground_obj_state,x"},{"a":40536,"t":"code","b":[240,8],"m":"beq","oa":40546,"o":"b_9E62"},{"a":40538,"t":"code","b":[189,248,12],"m":"lda","oa":3320,"o":"ground_obj_count,x"},{"a":40541,"t":"code","b":[240,3],"m":"beq","oa":40546,"o":"b_9E62"},{"a":40543,"t":"code","b":[76,133,158],"m":"jmp","oa":40581,"o":"hostage_create"},{"a":40546,"l":"b_9E62","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[40526,40530,40536,40541]},{"a":40549,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":40551,"t":"code","b":[170],"m":"tax"},{"a":40552,"t":"code","b":[141,87,11],"m":"sta","oa":2903,"o":"a_0B57"},{"a":40555,"l":"b_9E6B","t":"code","b":[189,244,12],"m":"lda","oa":3316,"o":"ground_obj_state,x","x":[40578]},{"a":40558,"t":"code","b":[240,8],"m":"beq","oa":40568,"o":"b_9E78"},{"a":40560,"t":"code","b":[189,248,12],"m":"lda","oa":3320,"o":"ground_obj_count,x"},{"a":40563,"t":"code","b":[240,3],"m":"beq","oa":40568,"o":"b_9E78"},{"a":40565,"t":"code","b":[76,133,158],"m":"jmp","oa":40581,"o":"hostage_create"},{"a":40568,"l":"b_9E78","t":"code","b":[232],"m":"inx","x":[40558,40563]},{"a":40569,"t":"code","b":[224,4],"m":"cpx","o":"#$04"},{"a":40571,"t":"code","b":[208,2],"m":"bne","oa":40575,"o":"b_9E7F"},{"a":40573,"t":"code","b":[162,0],"m":"ldx","o":"#$00"},{"a":40575,"l":"b_9E7F","t":"code","b":[236,87,11],"m":"cpx","oa":2903,"o":"a_0B57","x":[40571]},{"a":40578,"t":"code","b":[208,231],"m":"bne","oa":40555,"o":"b_9E6B"},{"a":40580,"t":"code","b":[96],"m":"rts"},{"a":40581,"l":"hostage_create","c":"Fills in a hostage record and is reached two ways. It first finds a free slot by scanning the sixteen records at $0CA0 downward for one whose +0 byte is negative, leaving 4 * slot in $0B58. Entered at $9E88 from $9E45 it unloads a passenger at the home base: $0CEE (delivered) up one, $0CF1 (aboard) down one, $0CF2 (loose at the base) up one, $A3D3 takes one off the aboard counter, $A3EC adds one to the rescued counter and plays its jingle, and the first unload after any pickup also advances the difficulty level $8D, to a maximum of 3. The new hostage gets a random animation phase, state $01 (walking right) and a world X of the helicopter's plus 4, forced odd. Entered at $9E85 it lets one out of the barracks chosen by $9E49: $0CF8+n and $0CED down one, $0CF0 up one, a random phase, a random left/right state, and world X (barracks index + 3) * 256 + $8A, i.e. $038A, $048A, $058A or $068A.","t":"code","b":[142,87,11],"m":"stx","oa":2903,"o":"a_0B57","x":[40543,40565]},{"a":40584,"l":"j_9E88","t":"code","b":[160,16],"m":"ldy","o":"#$10","x":[40517]},{"a":40586,"l":"b_9E8A","t":"code","b":[136],"m":"dey","x":[40594]},{"a":40587,"t":"code","b":[152],"m":"tya"},{"a":40588,"t":"code","b":[10],"m":"asl","o":"a"},{"a":40589,"t":"code","b":[10],"m":"asl","o":"a"},{"a":40590,"t":"code","b":[170],"m":"tax"},{"a":40591,"t":"code","b":[189,160,12],"m":"lda","oa":3232,"o":"person_state,x"},{"a":40594,"t":"code","b":[16,246],"m":"bpl","oa":40586,"o":"b_9E8A"},{"a":40596,"t":"code","b":[142,88,11],"m":"stx","oa":2904,"o":"a_0B58"},{"a":40599,"t":"code","b":[165,95],"m":"lda","oa":95,"o":"zpa_5F"},{"a":40601,"t":"code","b":[240,67],"m":"beq","oa":40670,"o":"b_9EDE"},{"a":40603,"t":"code","b":[238,238,12],"m":"inc","oa":3310,"o":"hostages_saved"},{"a":40606,"t":"code","b":[206,241,12],"m":"dec","oa":3313,"o":"a_0CF1"},{"a":40609,"t":"code","b":[238,242,12],"m":"inc","oa":3314,"o":"a_0CF2"},{"a":40612,"t":"code","b":[32,211,163],"m":"jsr","oa":41939,"o":"aboard_counter_dec"},{"a":40615,"t":"code","b":[32,236,163],"m":"jsr","oa":41964,"o":"rescued_counter_inc"},{"a":40618,"t":"code","b":[44,0,13],"m":"bit","oa":3328,"o":"a_0D00"},{"a":40621,"t":"code","b":[16,13],"m":"bpl","oa":40636,"o":"b_9EBC"},{"a":40623,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":40625,"t":"code","b":[141,0,13],"m":"sta","oa":3328,"o":"a_0D00"},{"a":40628,"t":"code","b":[165,141],"m":"lda","oa":141,"o":"zpa_8D"},{"a":40630,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":40632,"t":"code","b":[240,2],"m":"beq","oa":40636,"o":"b_9EBC"},{"a":40634,"t":"code","b":[230,141],"m":"inc","oa":141,"o":"zpa_8D"},{"a":40636,"l":"b_9EBC","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[40621,40632]},{"a":40639,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":40641,"t":"code","b":[174,88,11],"m":"ldx","oa":2904,"o":"a_0B58"},{"a":40644,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40647,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":40649,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":40652,"t":"code","b":[24],"m":"clc"},{"a":40653,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":40655,"t":"code","b":[105,4],"m":"adc","o":"#$04"},{"a":40657,"t":"code","b":[9,1],"m":"ora","o":"#$01"},{"a":40659,"t":"code","b":[157,162,12],"m":"sta","oa":3234,"o":"person_x,x"},{"a":40662,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":40664,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":40666,"t":"code","b":[157,163,12],"m":"sta","oa":3235,"o":"person_x_hi,x"},{"a":40669,"t":"code","b":[96],"m":"rts"},{"a":40670,"l":"b_9EDE","t":"code","b":[174,87,11],"m":"ldx","oa":2903,"o":"a_0B57","x":[40601]},{"a":40673,"t":"code","b":[222,248,12],"m":"dec","oa":3320,"o":"ground_obj_count,x"},{"a":40676,"t":"code","b":[206,237,12],"m":"dec","oa":3309,"o":"a_0CED"},{"a":40679,"t":"code","b":[238,240,12],"m":"inc","oa":3312,"o":"a_0CF0"},{"a":40682,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":40685,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":40687,"t":"code","b":[174,88,11],"m":"ldx","oa":2904,"o":"a_0B58"},{"a":40690,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":40693,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":40696,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":40698,"t":"code","b":[208,2],"m":"bne","oa":40702,"o":"b_9EFE"},{"a":40700,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":40702,"l":"b_9EFE","t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x","x":[40698]},{"a":40705,"t":"code","b":[24],"m":"clc"},{"a":40706,"t":"code","b":[169,128],"m":"lda","o":"#$80"},{"a":40708,"t":"code","b":[105,10],"m":"adc","o":"#$0A"},{"a":40710,"t":"code","b":[157,162,12],"m":"sta","oa":3234,"o":"person_x,x"},{"a":40713,"t":"code","b":[173,87,11],"m":"lda","oa":2903,"o":"a_0B57"},{"a":40716,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":40718,"t":"code","b":[157,163,12],"m":"sta","oa":3235,"o":"person_x_hi,x"},{"a":40721,"t":"code","b":[96],"m":"rts"},{"a":40722,"l":"tank_spawn","c":"Creates one enemy tank, actor type 3, whose per-tick handler is $A0BB. Called only from $A3A5. Refuses if the helicopter is within two pages of the right-hand end of the map ($11 minus $56 must be 2 or more), so no tank is ever born near the home base. Takes a slot from the free list with $A951, then picks a side: if the helicopter's horizontal speed $52 is between $11 and $EE the tank appears on the side the machine is heading for, otherwise a bit of $DC04 decides. The left-hand case at $9F3D sets world X to the helicopter's minus $01B0 and the aim index $0B77 to 4. The right-hand case at $9F54 computes only the low byte, the helicopter's plus $B0, and then stores $00 into the high byte $0B79 instead of $56 plus the carry - see $9F54. Height field $0B7A is 6, the rank $0B7B is a value 5..12 from $DC04 re-rolled until it differs from every live tank's, the type is 3, the fire timer $0B75 is $0A and the drift $0B76 is 0. Finally $A95B links the actor into the display list and the slot is appended to the tank index list $0CE9 with $0CE8 as its count.","t":"code","b":[56],"m":"sec","x":[41903]},{"a":40723,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":40725,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":40727,"t":"code","b":[48,4],"m":"bmi","oa":40733,"o":"r_9F1D"},{"a":40729,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":40731,"t":"code","b":[176,1],"m":"bcs","oa":40734,"o":"b_9F1E"},{"a":40733,"l":"r_9F1D","t":"code","b":[96],"m":"rts","x":[40727]},{"a":40734,"l":"b_9F1E","t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc","x":[40731]},{"a":40737,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":40739,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":40741,"t":"code","b":[201,17],"m":"cmp","o":"#$11"},{"a":40743,"t":"code","b":[144,11],"m":"bcc","oa":40756,"o":"b_9F34"},{"a":40745,"t":"code","b":[201,239],"m":"cmp","o":"#$EF"},{"a":40747,"t":"code","b":[176,7],"m":"bcs","oa":40756,"o":"b_9F34"},{"a":40749,"t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52"},{"a":40751,"t":"code","b":[48,12],"m":"bmi","oa":40765,"o":"b_9F3D"},{"a":40753,"t":"code","b":[76,84,159],"m":"jmp","oa":40788,"o":"tank_spawn_right"},{"a":40756,"l":"b_9F34","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[40743,40747]},{"a":40759,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":40761,"t":"code","b":[41,8],"m":"and","o":"#$08"},{"a":40763,"t":"code","b":[208,23],"m":"bne","oa":40788,"o":"tank_spawn_right"},{"a":40765,"l":"b_9F3D","t":"code","b":[56],"m":"sec","x":[40751]},{"a":40766,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":40768,"t":"code","b":[233,176],"m":"sbc","o":"#$B0"},{"a":40770,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":40773,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":40775,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":40777,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":40780,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":40782,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":40785,"t":"code","b":[76,100,159],"m":"jmp","oa":40804,"o":"j_9F64"},{"a":40788,"l":"tank_spawn_right","c":"The right-hand half of $9F12. It adds $B0 to the helicopter's world-X low byte $55 and stores that in $0B78, but the next two instructions store $00 into both $0B77 (aim index) and $0B79, the world-X HIGH byte. There is no adc $56 here, unlike the mirror-image code at $9F3D and at $A09E and $A0AD in the type-9 and type-10 spawners, which do build a full sixteen-bit helicopter-relative position. The tank is therefore created at world X $00xx, at the far left of the map, rather than $01B0 to the right of the helicopter; $A16B then destroys any tank more than three pages from the helicopter, so such a tank dies on its first update without ever being drawn. Confirmed from the bytes A9 00 9D 77 0B 9D 79 0B and confirmed reached live, 4 times against 5 for the $9F3D branch in one 50-second sample. Whether this is a bug or intended is unknown; the removal at $B5CC is clean, so nothing leaks.","t":"code","b":[24],"m":"clc","x":[40753,40763]},{"a":40789,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":40791,"t":"code","b":[105,176],"m":"adc","o":"#$B0"},{"a":40793,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":40796,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":40798,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":40801,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":40804,"l":"j_9F64","t":"code","b":[169,6],"m":"lda","o":"#$06","x":[40785]},{"a":40806,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":40809,"l":"j_9F69","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[40831]},{"a":40812,"t":"code","b":[41,7],"m":"and","o":"#$07"},{"a":40814,"t":"code","b":[24],"m":"clc"},{"a":40815,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":40817,"t":"code","b":[172,232,12],"m":"ldy","oa":3304,"o":"board_list_len"},{"a":40820,"l":"b_9F74","t":"code","b":[136],"m":"dey","x":[40829]},{"a":40821,"t":"code","b":[48,11],"m":"bmi","oa":40834,"o":"b_9F82"},{"a":40823,"t":"code","b":[190,233,12],"m":"ldx","oa":3305,"o":"board_list,y"},{"a":40826,"t":"code","b":[221,123,11],"m":"cmp","oa":2939,"o":"actor_base_row,x"},{"a":40829,"t":"code","b":[208,245],"m":"bne","oa":40820,"o":"b_9F74"},{"a":40831,"t":"code","b":[76,105,159],"m":"jmp","oa":40809,"o":"j_9F69"},{"a":40834,"l":"b_9F82","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[40821]},{"a":40836,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":40839,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":40841,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":40844,"t":"code","b":[169,10],"m":"lda","o":"#$0A"},{"a":40846,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":40849,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":40851,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":40854,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":40857,"t":"code","b":[174,232,12],"m":"ldx","oa":3304,"o":"board_list_len"},{"a":40860,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":40862,"t":"code","b":[157,233,12],"m":"sta","oa":3305,"o":"board_list,x"},{"a":40865,"t":"code","b":[232],"m":"inx"},{"a":40866,"t":"code","b":[142,232,12],"m":"stx","oa":3304,"o":"board_list_len"},{"a":40869,"t":"code","b":[96],"m":"rts"},{"a":40870,"l":"actor9_spawn","c":"Creates one actor of type 9, whose handler is $AD8F, outside this range; which flying machine type 9 is belongs to that handler's account. Called only from $A3A2. Takes a slot with $A951 and sets type 9, drift $0B76 = 0, height $0B7A = half the helicopter's altitude $57 plus $30 capped at $68, and rank $0B7B = the ground level $58 plus $20 - so it is placed at roughly the helicopter's own height. From difficulty $8D = 2 upward a masked draw from $DC04 against the table at $A040 decides whether $0B75 starts at $80 or 0; below that it is always 0. The side is chosen exactly as in $9F12 - ahead of the helicopter when $52 shows it moving briskly, otherwise at random - and here the position is a full sixteen-bit helicopter's X minus or plus $01B8, with $0B77 set to 0 or $FF to record the facing. $A95B links it and the slot is appended to the index list $0CE4, count $0CE3.","t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc","x":[41890]},{"a":40873,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":40875,"t":"code","b":[169,9],"m":"lda","o":"#$09"},{"a":40877,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":40880,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":40882,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":40885,"t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":40887,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":40888,"t":"code","b":[24],"m":"clc"},{"a":40889,"t":"code","b":[105,48],"m":"adc","o":"#$30"},{"a":40891,"t":"code","b":[201,105],"m":"cmp","o":"#$69"},{"a":40893,"t":"code","b":[144,2],"m":"bcc","oa":40897,"o":"b_9FC1"},{"a":40895,"t":"code","b":[169,104],"m":"lda","o":"#$68"},{"a":40897,"l":"b_9FC1","t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x","x":[40893]},{"a":40900,"t":"code","b":[24],"m":"clc"},{"a":40901,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":40903,"t":"code","b":[105,32],"m":"adc","o":"#$20"},{"a":40905,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":40908,"t":"code","b":[165,141],"m":"lda","oa":141,"o":"zpa_8D"},{"a":40910,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":40912,"t":"code","b":[144,12],"m":"bcc","oa":40926,"o":"b_9FDE"},{"a":40914,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":40917,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":40919,"t":"code","b":[164,141],"m":"ldy","oa":141,"o":"zpa_8D"},{"a":40921,"t":"code","b":[57,64,160],"m":"and","oa":41024,"o":"actor9_flag_prob_table,y"},{"a":40924,"t":"code","b":[240,8],"m":"beq","oa":40934,"o":"b_9FE6"},{"a":40926,"l":"b_9FDE","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[40912]},{"a":40928,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":40931,"t":"code","b":[76,235,159],"m":"jmp","oa":40939,"o":"j_9FEB"},{"a":40934,"l":"b_9FE6","t":"code","b":[169,128],"m":"lda","o":"#$80","x":[40924]},{"a":40936,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":40939,"l":"j_9FEB","t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52","x":[40931]},{"a":40941,"t":"code","b":[201,17],"m":"cmp","o":"#$11"},{"a":40943,"t":"code","b":[144,11],"m":"bcc","oa":40956,"o":"b_9FFC"},{"a":40945,"t":"code","b":[201,239],"m":"cmp","o":"#$EF"},{"a":40947,"t":"code","b":[176,7],"m":"bcs","oa":40956,"o":"b_9FFC"},{"a":40949,"t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52"},{"a":40951,"t":"code","b":[48,12],"m":"bmi","oa":40965,"o":"b_A005"},{"a":40953,"t":"code","b":[76,28,160],"m":"jmp","oa":40988,"o":"j_A01C"},{"a":40956,"l":"b_9FFC","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[40943,40947]},{"a":40959,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":40960,"t":"note","l":"actor9_spawn_page_a0","c":"Not an instruction: $A000 is the operand byte of the ldx $72 at $9FFF, and the label exists only because $A000 is a hard memory-map boundary. The code either side of it is the tail of the type-9 spawner $9FA6, running from $9FFB to $A03F: it inspects the helicopter's horizontal speed $52 and, when that is too small to show which way the machine is heading, takes bit 4 of a $DC04 sample instead, then writes the new actor's world X as the helicopter's minus $01B8 (facing byte $0B77 = 0) or plus $01B8 ($0B77 = $FF), links the actor in with $A95B and appends its slot to the type-9 index list $0CE4 whose count is $0CE3.","note":"inside the item at $9FFF"},{"a":40961,"t":"code","b":[41,16],"m":"and","o":"#$10"},{"a":40963,"t":"code","b":[208,23],"m":"bne","oa":40988,"o":"j_A01C"},{"a":40965,"l":"b_A005","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[40951]},{"a":40967,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":40970,"t":"code","b":[56],"m":"sec"},{"a":40971,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":40973,"t":"code","b":[233,184],"m":"sbc","o":"#$B8"},{"a":40975,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":40978,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":40980,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":40982,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":40985,"t":"code","b":[76,48,160],"m":"jmp","oa":41008,"o":"j_A030"},{"a":40988,"l":"j_A01C","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[40953,40963]},{"a":40990,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":40993,"t":"code","b":[24],"m":"clc"},{"a":40994,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":40996,"t":"code","b":[105,184],"m":"adc","o":"#$B8"},{"a":40998,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":41001,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":41003,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":41005,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":41008,"l":"j_A030","t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link","x":[40985]},{"a":41011,"t":"code","b":[174,227,12],"m":"ldx","oa":3299,"o":"hit_list_len"},{"a":41014,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":41016,"t":"code","b":[157,228,12],"m":"sta","oa":3300,"o":"hit_list,x"},{"a":41019,"t":"code","b":[232],"m":"inx"},{"a":41020,"t":"code","b":[142,227,12],"m":"stx","oa":3299,"o":"hit_list_len"},{"a":41023,"t":"code","b":[96],"m":"rts"},{"a":41024,"l":"actor9_flag_prob_table","c":"Four bytes, $00 $00 $2C $44, indexed by the difficulty level $8D at $9FD9. The spawner ANDs a byte of $DC04 with the entry and starts the new type-9 actor's $0B75 at $80 when the result is zero, at 0 otherwise. $8D 0 and 1 never reach the table at all; $2C has three bits set, so one spawn in eight at $8D = 2, and $44 has two, one in four at $8D = 3.","t":"byte","b":[0,0,44,68],"x":[40921]},{"a":41028,"l":"actor10_spawn","c":"Creates the single actor of type 10, whose handler is $B73D, outside this range. Called only from $A391, and only while $8D is 2 or more and $0CE1 is zero, so at most one exists at a time. Refuses, like $9F12, unless the helicopter is at least two pages from the right-hand end of the map. Sets type $0A, clears $0B75, $0B76 and $0B77, puts the height $0B7A at $70 - well above everything else in the game - and the rank $0B7B at the ground level $58 minus 1. Chooses its side the same way as $9F12 (ahead of the helicopter if $52 says it is moving, otherwise a coin flip on $DC04) and sets a full sixteen-bit world X of the helicopter's minus or plus $01B8. $A95B links it, then $0CE1 is set to 1 as the in-play flag and $0CE2 remembers the slot.","t":"code","b":[56],"m":"sec","x":[41873]},{"a":41029,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":41031,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":41033,"t":"code","b":[48,4],"m":"bmi","oa":41039,"o":"r_A04F"},{"a":41035,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":41037,"t":"code","b":[176,1],"m":"bcs","oa":41040,"o":"b_A050"},{"a":41039,"l":"r_A04F","t":"code","b":[96],"m":"rts","x":[41033]},{"a":41040,"l":"b_A050","t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc","x":[41037]},{"a":41043,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":41045,"t":"code","b":[169,10],"m":"lda","o":"#$0A"},{"a":41047,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":41050,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":41052,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":41055,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":41058,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":41061,"t":"code","b":[169,112],"m":"lda","o":"#$70"},{"a":41063,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":41066,"t":"code","b":[56],"m":"sec"},{"a":41067,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":41069,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":41071,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":41074,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":41076,"t":"code","b":[201,17],"m":"cmp","o":"#$11"},{"a":41078,"t":"code","b":[144,11],"m":"bcc","oa":41091,"o":"b_A083"},{"a":41080,"t":"code","b":[201,239],"m":"cmp","o":"#$EF"},{"a":41082,"t":"code","b":[176,7],"m":"bcs","oa":41091,"o":"b_A083"},{"a":41084,"t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52"},{"a":41086,"t":"code","b":[48,12],"m":"bmi","oa":41100,"o":"b_A08C"},{"a":41088,"t":"code","b":[76,158,160],"m":"jmp","oa":41118,"o":"j_A09E"},{"a":41091,"l":"b_A083","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[41078,41082]},{"a":41094,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":41096,"t":"code","b":[41,16],"m":"and","o":"#$10"},{"a":41098,"t":"code","b":[208,18],"m":"bne","oa":41118,"o":"j_A09E"},{"a":41100,"l":"b_A08C","t":"code","b":[56],"m":"sec","x":[41086]},{"a":41101,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":41103,"t":"code","b":[233,184],"m":"sbc","o":"#$B8"},{"a":41105,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":41108,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":41110,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":41112,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":41115,"t":"code","b":[76,173,160],"m":"jmp","oa":41133,"o":"j_A0AD"},{"a":41118,"l":"j_A09E","t":"code","b":[24],"m":"clc","x":[41088,41098]},{"a":41119,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":41121,"t":"code","b":[105,184],"m":"adc","o":"#$B8"},{"a":41123,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":41126,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":41128,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":41130,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":41133,"l":"j_A0AD","t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link","x":[41115]},{"a":41136,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":41138,"t":"code","b":[141,225,12],"m":"sta","oa":3297,"o":"a_0CE1"},{"a":41141,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":41143,"t":"code","b":[141,226,12],"m":"sta","oa":3298,"o":"a_0CE2"},{"a":41146,"t":"code","b":[96],"m":"rts"},{"a":41147,"l":"tank_update","c":"Per-tick handler for actor type 3, the enemy tank; entry 3 of the dispatch table at $B32E, called from $B307 with X and $72 = the actor's record offset. Draws the tank as three pieces and then decides how it drives, aims and fires. The three pieces are shape-table entry 40, the hull and tracks, at offset (-$0F, +0) and mirrored on alternate values of bit 2 of the world-X low byte so the track pattern crawls as the tank moves; entry 39, the turret, at (-$07, +3); and one of entries 41 to 45, the gun barrel at five elevations, at (-$A244[aim], +7). Each piece is positioned by $A9A0, clipped by $8F03 and filed in the frame's object list by $AA38 under its own kind code, 2 for the hull, 3 for the turret, 4 for the barrel, so the three can be hit separately. Rendering the three shapes and watching one on screen is what identifies the actor: a tracked hull with a swivelling gun. Movement: $81/$82 is the helicopter's world X minus the tank's. More than three pages away and the tank is deleted - $B5CC takes it out of the index list $0CE9 and $A937 returns the slot, the test being on the high byte of the difference being 3 or more in either direction. Within $80 units it counts $0B75 down, and on zero re-rolls the timer to 8 + a random 0..15 and re-decides; further out it drives toward the helicopter or, if the helicopter is wrecked ($61 non-zero), away from it. $0B77, 0 to 4, is the aim index: $A249 and $A24A give the bearing window each index covers, and the tank steps $0B77 one notch toward the window the helicopter actually lies in. When the helicopter is already in the current window, $0B59 is set to $FF and $A2C4 fires a shell.","t":"code","b":[162,15],"m":"ldx","o":"#$0F"},{"a":41149,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":41151,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":41153,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":41156,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":41159,"l":"arg_tank_hull_pos","c":"Inline argument of the $8BF9 at $A0C4: the pointer $0067. $8BF9 copies $67/$68/$69 into $34/$35/$36 - the draw position $A9A0 just computed for the tank's hull, the actor's world X less $0F and its Y with no offset.","t":"word","b":[103,0],"d":[103]},{"a":41161,"l":"tank_load_hull_shape","c":"The jsr $8BE0 that loads the hull's bitmap address, taking its pointer from the inline word below.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":41164,"l":"arg_shape_tank_hull","c":"Inline argument of the $8BE0 at $A0C9: the pointer $8059, which is entry 40 of the shape pointer table at $8009 ((.$8059-$8009)/2 = 40). $8BE0 copies the word there into $37/$38. Shape 40 is 15 bitmap bits by 6 rows, the tank's hull with the dashed track pattern along its top and bottom rows.","t":"word","b":[89,128],"d":[32857]},{"a":41166,"l":"tank_draw_hull","c":"Clips the hull with $8F03; if the tank is off screen the carry comes back set and the code jumps straight to the movement logic at $A13F, skipping all three pieces but still letting the tank drive and shoot. Otherwise files it in the frame's object list as kind 2 via $AA38 and plots it, mirrored or not according to bit 2 of the actor's world-X low byte, which animates the tracks as the tank rolls. Then sets up the turret at offset (-$07, +3) with $A9A0.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":41169,"t":"code","b":[176,108],"m":"bcs","oa":41279,"o":"b_A13F"},{"a":41171,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":41173,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":41176,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":41178,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":41181,"t":"code","b":[41,4],"m":"and","o":"#$04"},{"a":41183,"t":"code","b":[240,6],"m":"beq","oa":41191,"o":"b_A0E7"},{"a":41185,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":41188,"t":"code","b":[76,234,160],"m":"jmp","oa":41194,"o":"j_A0EA"},{"a":41191,"l":"b_A0E7","t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored","x":[41183]},{"a":41194,"l":"j_A0EA","t":"code","b":[162,7],"m":"ldx","o":"#$07","x":[41188]},{"a":41196,"t":"code","b":[160,3],"m":"ldy","o":"#$03"},{"a":41198,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":41200,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":41203,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":41206,"l":"arg_tank_turret_pos","c":"Inline argument of the $8BF9 at $A0F3: the pointer $0067, holding the turret's draw position, the tank's world X less 7 and its Y plus 3, as just computed by $A9A0.","t":"word","b":[103,0],"d":[103]},{"a":41208,"l":"tank_load_turret_shape","c":"The jsr $8BE0 that loads the turret's bitmap address from the inline pointer below.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":41211,"l":"arg_shape_tank_turret","c":"Inline argument of the $8BE0 at $A0F8: the pointer $8057, entry 39 of the shape pointer table at $8009. Shape 39 is 15 bitmap bits by 3 rows, the small block that sits on the hull and carries the gun.","t":"word","b":[87,128],"d":[32855]},{"a":41213,"l":"tank_draw_turret","c":"Clips and plots the turret, filing it in the frame's object list as kind 3 through $AA38; unlike the hull it is never mirrored. Then picks the barrel: the aim index $0B77 (0 to 4) doubled indexes the shape pointer table at entry 41, so entries 41 to 45 are the gun at five elevations, and the address goes into $65/$66 for the $8BE0 that follows.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":41216,"t":"code","b":[176,8],"m":"bcs","oa":41226,"o":"b_A10A"},{"a":41218,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":41220,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":41223,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":41226,"l":"b_A10A","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[41216]},{"a":41228,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":41231,"t":"code","b":[10],"m":"asl","o":"a"},{"a":41232,"t":"code","b":[168],"m":"tay"},{"a":41233,"t":"code","b":[185,91,128],"m":"lda","oa":32859,"o":"shape_ptr_tank_gun,y"},{"a":41236,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":41238,"t":"code","b":[185,92,128],"m":"lda","oa":32860,"o":"shape_ptr_shots,y"},{"a":41241,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":41243,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":41246,"l":"arg_shape_tank_barrel","c":"Inline argument of the $8BE0 at $A11B: the pointer $0065, where the code has just put the address of shape-table entry 41 + the aim index, the gun barrel at the elevation the tank is currently holding.","t":"word","b":[101,0],"d":[101]},{"a":41248,"l":"tank_place_barrel","c":"Positions the gun barrel. The aim index $0B77 indexes $A244 for the horizontal offset ($0B, $07, $01, $FF, $FB, i.e. the muzzle swings from eleven units left of the tank's origin to five units right as the gun comes up) and the vertical offset is a fixed +7, above the turret. $A9A0 turns that into a draw position in $67/$68/$69.","t":"code","b":[188,119,11],"m":"ldy","oa":2935,"o":"actor_frame,x"},{"a":41251,"t":"code","b":[190,68,162],"m":"ldx","oa":41540,"o":"tank_barrel_xoff_table,y"},{"a":41254,"t":"code","b":[160,7],"m":"ldy","o":"#$07"},{"a":41256,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":41258,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":41261,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":41264,"l":"arg_tank_barrel_pos","c":"Inline argument of the $8BF9 at $A12D: the pointer $0067, the gun barrel's draw position as just computed by $A9A0.","t":"word","b":[103,0],"d":[103]},{"a":41266,"l":"tank_draw_barrel_and_think","c":"Clips and plots the gun barrel, filing it as kind 4 in the frame's object list, and then runs the whole of the tank's thinking. $81/$82 becomes the helicopter's world X minus the tank's and $83 the difference in height. A tank more than three pages away is destroyed on the spot ($B5CC then $A937). Inside $80 units the fire timer $0B75 counts down and, at zero, is reloaded with 8 plus a random 0..15 and the aim re-decided: if the helicopter's bearing already falls inside the window the current aim index covers ($A249 and $A24A) the shot flag $0B59 is set and $A2C4 fires. Otherwise the tank drives - toward the helicopter normally, away from it while the wreck burns ($61) - and nudges the aim index one notch toward the right window.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":41269,"t":"code","b":[176,8],"m":"bcs","oa":41279,"o":"b_A13F"},{"a":41271,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":41273,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":41276,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":41279,"l":"b_A13F","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[41169,41269]},{"a":41281,"t":"code","b":[141,89,11],"m":"sta","oa":2905,"o":"a_0B59"},{"a":41284,"t":"code","b":[56],"m":"sec"},{"a":41285,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":41287,"t":"code","b":[253,120,11],"m":"sbc","oa":2936,"o":"actor_x,x"},{"a":41290,"t":"code","b":[133,129],"m":"sta","oa":129,"o":"zpa_81"},{"a":41292,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":41294,"t":"code","b":[253,121,11],"m":"sbc","oa":2937,"o":"actor_x_hi,x"},{"a":41297,"t":"code","b":[133,130],"m":"sta","oa":130,"o":"zpa_82"},{"a":41299,"t":"code","b":[56],"m":"sec"},{"a":41300,"t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":41302,"t":"code","b":[253,122,11],"m":"sbc","oa":2938,"o":"actor_alt,x"},{"a":41305,"t":"code","b":[133,131],"m":"sta","oa":131,"o":"zpa_83"},{"a":41307,"t":"code","b":[165,130],"m":"lda","oa":130,"o":"zpa_82"},{"a":41309,"t":"code","b":[240,27],"m":"beq","oa":41338,"o":"b_A17A"},{"a":41311,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":41313,"t":"code","b":[240,30],"m":"beq","oa":41345,"o":"b_A181"},{"a":41315,"t":"code","b":[201,253],"m":"cmp","o":"#$FD"},{"a":41317,"t":"code","b":[176,10],"m":"bcs","oa":41329,"o":"b_A171"},{"a":41319,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":41321,"t":"code","b":[144,6],"m":"bcc","oa":41329,"o":"b_A171"},{"a":41323,"t":"code","b":[32,204,181],"m":"jsr","oa":46540,"o":"tank_list_remove"},{"a":41326,"t":"code","b":[76,55,169],"m":"jmp","oa":43319,"o":"actor_free"},{"a":41329,"l":"b_A171","t":"code","b":[165,130],"m":"lda","oa":130,"o":"zpa_82","x":[41317,41321]},{"a":41331,"t":"code","b":[73,128],"m":"eor","o":"#$80"},{"a":41333,"t":"code","b":[133,129],"m":"sta","oa":129,"o":"zpa_81"},{"a":41335,"t":"code","b":[76,133,161],"m":"jmp","oa":41349,"o":"j_A185"},{"a":41338,"l":"b_A17A","t":"code","b":[36,129],"m":"bit","oa":129,"o":"zpa_81","x":[41309]},{"a":41340,"t":"code","b":[16,17],"m":"bpl","oa":41359,"o":"b_A18F"},{"a":41342,"t":"code","b":[76,133,161],"m":"jmp","oa":41349,"o":"j_A185"},{"a":41345,"l":"b_A181","t":"code","b":[36,129],"m":"bit","oa":129,"o":"zpa_81","x":[41313]},{"a":41347,"t":"code","b":[48,10],"m":"bmi","oa":41359,"o":"b_A18F"},{"a":41349,"l":"j_A185","t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61","x":[41335,41342]},{"a":41351,"t":"code","b":[208,3],"m":"bne","oa":41356,"o":"b_A18C"},{"a":41353,"t":"code","b":[76,99,162],"m":"jmp","oa":41571,"o":"tank_drive_away"},{"a":41356,"l":"b_A18C","t":"code","b":[76,106,162],"m":"jmp","oa":41578,"o":"tank_drive_toward","x":[41351]},{"a":41359,"l":"b_A18F","t":"code","b":[24],"m":"clc","x":[41340,41347]},{"a":41360,"t":"code","b":[165,129],"m":"lda","oa":129,"o":"zpa_81"},{"a":41362,"t":"code","b":[105,128],"m":"adc","o":"#$80"},{"a":41364,"t":"code","b":[133,129],"m":"sta","oa":129,"o":"zpa_81"},{"a":41366,"t":"code","b":[222,117,11],"m":"dec","oa":2933,"o":"actor_vx,x"},{"a":41369,"t":"code","b":[240,6],"m":"beq","oa":41377,"o":"b_A1A1"},{"a":41371,"t":"code","b":[32,79,162],"m":"jsr","oa":41551,"o":"tank_drive_on"},{"a":41374,"t":"code","b":[76,15,162],"m":"jmp","oa":41487,"o":"j_A20F"},{"a":41377,"l":"b_A1A1","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[41369]},{"a":41380,"t":"code","b":[41,15],"m":"and","o":"#$0F"},{"a":41382,"t":"code","b":[24],"m":"clc"},{"a":41383,"t":"code","b":[105,8],"m":"adc","o":"#$08"},{"a":41385,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":41388,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":41390,"t":"code","b":[208,22],"m":"bne","oa":41414,"o":"b_A1C6"},{"a":41392,"t":"code","b":[188,119,11],"m":"ldy","oa":2935,"o":"actor_frame,x"},{"a":41395,"t":"code","b":[165,129],"m":"lda","oa":129,"o":"zpa_81"},{"a":41397,"t":"code","b":[217,73,162],"m":"cmp","oa":41545,"o":"tank_aim_window_lo,y"},{"a":41400,"t":"code","b":[144,12],"m":"bcc","oa":41414,"o":"b_A1C6"},{"a":41402,"t":"code","b":[185,74,162],"m":"lda","oa":41546,"o":"tank_aim_window_hi,y"},{"a":41405,"t":"code","b":[197,129],"m":"cmp","oa":129,"o":"zpa_81"},{"a":41407,"t":"code","b":[144,5],"m":"bcc","oa":41414,"o":"b_A1C6"},{"a":41409,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":41411,"t":"code","b":[141,89,11],"m":"sta","oa":2905,"o":"a_0B59"},{"a":41414,"l":"b_A1C6","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[41390,41400,41407]},{"a":41416,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":41418,"t":"code","b":[240,6],"m":"beq","oa":41426,"o":"b_A1D2"},{"a":41420,"t":"code","b":[32,106,162],"m":"jsr","oa":41578,"o":"tank_drive_toward"},{"a":41423,"t":"code","b":[76,15,162],"m":"jmp","oa":41487,"o":"j_A20F"},{"a":41426,"l":"b_A1D2","t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x","x":[41418]},{"a":41429,"t":"code","b":[240,23],"m":"beq","oa":41454,"o":"b_A1EE"},{"a":41431,"t":"code","b":[69,129],"m":"eor","oa":129,"o":"zpa_81"},{"a":41433,"t":"code","b":[16,42],"m":"bpl","oa":41477,"o":"b_A205"},{"a":41435,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":41438,"t":"code","b":[41,5],"m":"and","o":"#$05"},{"a":41440,"t":"code","b":[240,6],"m":"beq","oa":41448,"o":"b_A1E8"},{"a":41442,"t":"code","b":[32,99,162],"m":"jsr","oa":41571,"o":"tank_drive_away"},{"a":41445,"t":"code","b":[76,15,162],"m":"jmp","oa":41487,"o":"j_A20F"},{"a":41448,"l":"b_A1E8","t":"code","b":[32,91,162],"m":"jsr","oa":41563,"o":"tank_halt","x":[41440]},{"a":41451,"t":"code","b":[76,15,162],"m":"jmp","oa":41487,"o":"j_A20F"},{"a":41454,"l":"b_A1EE","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[41429]},{"a":41457,"t":"code","b":[41,23],"m":"and","o":"#$17"},{"a":41459,"t":"code","b":[240,10],"m":"beq","oa":41471,"o":"b_A1FF"},{"a":41461,"t":"code","b":[41,16],"m":"and","o":"#$10"},{"a":41463,"t":"code","b":[240,22],"m":"beq","oa":41487,"o":"j_A20F"},{"a":41465,"t":"code","b":[32,99,162],"m":"jsr","oa":41571,"o":"tank_drive_away"},{"a":41468,"t":"code","b":[76,15,162],"m":"jmp","oa":41487,"o":"j_A20F"},{"a":41471,"l":"b_A1FF","t":"code","b":[32,106,162],"m":"jsr","oa":41578,"o":"tank_drive_toward","x":[41459]},{"a":41474,"t":"code","b":[76,15,162],"m":"jmp","oa":41487,"o":"j_A20F"},{"a":41477,"l":"b_A205","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[41433]},{"a":41480,"t":"code","b":[41,16],"m":"and","o":"#$10"},{"a":41482,"t":"code","b":[240,3],"m":"beq","oa":41487,"o":"j_A20F"},{"a":41484,"t":"code","b":[32,91,162],"m":"jsr","oa":41563,"o":"tank_halt"},{"a":41487,"l":"j_A20F","t":"code","b":[44,89,11],"m":"bit","oa":2905,"o":"a_0B59","x":[41374,41423,41445,41451,41463,41468,41474,41482]},{"a":41490,"t":"code","b":[48,39],"m":"bmi","oa":41531,"o":"b_A23B"},{"a":41492,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":41494,"t":"code","b":[188,119,11],"m":"ldy","oa":2935,"o":"actor_frame,x"},{"a":41497,"t":"code","b":[165,129],"m":"lda","oa":129,"o":"zpa_81"},{"a":41499,"t":"code","b":[217,73,162],"m":"cmp","oa":41545,"o":"tank_aim_window_lo,y"},{"a":41502,"t":"code","b":[144,10],"m":"bcc","oa":41514,"o":"b_A22A"},{"a":41504,"t":"code","b":[185,74,162],"m":"lda","oa":41546,"o":"tank_aim_window_hi,y"},{"a":41507,"t":"code","b":[197,129],"m":"cmp","oa":129,"o":"zpa_81"},{"a":41509,"t":"code","b":[144,13],"m":"bcc","oa":41524,"o":"b_A234"},{"a":41511,"t":"code","b":[76,59,162],"m":"jmp","oa":41531,"o":"b_A23B"},{"a":41514,"l":"b_A22A","t":"code","b":[192,0],"m":"cpy","o":"#$00","x":[41502]},{"a":41516,"t":"code","b":[240,13],"m":"beq","oa":41531,"o":"b_A23B"},{"a":41518,"t":"code","b":[222,119,11],"m":"dec","oa":2935,"o":"actor_frame,x"},{"a":41521,"t":"code","b":[76,59,162],"m":"jmp","oa":41531,"o":"b_A23B"},{"a":41524,"l":"b_A234","t":"code","b":[192,4],"m":"cpy","o":"#$04","x":[41509]},{"a":41526,"t":"code","b":[240,3],"m":"beq","oa":41531,"o":"b_A23B"},{"a":41528,"t":"code","b":[254,119,11],"m":"inc","oa":2935,"o":"actor_frame,x"},{"a":41531,"l":"b_A23B","t":"code","b":[44,89,11],"m":"bit","oa":2905,"o":"a_0B59","x":[41490,41511,41516,41521,41526]},{"a":41534,"t":"code","b":[48,1],"m":"bmi","oa":41537,"o":"b_A241"},{"a":41536,"t":"code","b":[96],"m":"rts"},{"a":41537,"l":"b_A241","t":"code","b":[76,196,162],"m":"jmp","oa":41668,"o":"tank_fire","x":[41534]},{"a":41540,"l":"tank_barrel_xoff_table","c":"Five signed bytes, $0B $07 $01 $FF $FB, indexed by a tank's aim index $0B77 at $A123. They are subtracted from the tank's world X by $A9A0 to place the gun barrel, so the muzzle sits eleven units left of the tank's origin at the lowest elevation and five units right at the highest.","t":"byte","b":[11,7,1,255,251],"x":[41251]},{"a":41545,"l":"tank_aim_window_lo","c":"The low end of the bearing window for aim index 0: a single byte $00. Read at $A1B5 and $A21B alongside $A24A; because the two tables overlap by four bytes, index n's window is $A249+n to $A24A+n, i.e. $00-$40, $40-$70, $70-$90, $90-$C0, $C0-$FF.","t":"byte","b":[0],"x":[41397,41499]},{"a":41546,"l":"tank_aim_window_hi","c":"Five bytes, $40 $70 $90 $C0 $FF: the high end of the bearing window for each of the tank's five aim indices, and, offset by one, the low ends for indices 1 to 4. The bearing compared against them is $81, the helicopter's world X minus the tank's, biased by $80 so that $80 means level. The tank fires when the helicopter lies inside the window its gun is already pointing at ($A1B5), and otherwise steps the aim index one notch toward the window it does lie in ($A21B). The windows are unequal so the gun lingers on the middle elevations.","t":"byte","b":[64,112,144,192,255],"x":[41402,41504]},{"a":41551,"l":"tank_drive_on","c":"Keeps a tank rolling the way it was already going, used while its fire timer has not expired. Reads the drift $0B76: zero means it was standing still, so it stays still ($A25B); positive means it was moving right ($A271); negative means left ($A2AB).","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[41371]},{"a":41553,"t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x"},{"a":41556,"t":"code","b":[240,5],"m":"beq","oa":41563,"o":"tank_halt"},{"a":41558,"t":"code","b":[16,25],"m":"bpl","oa":41585,"o":"tank_step_right"},{"a":41560,"t":"code","b":[76,171,162],"m":"jmp","oa":41643,"o":"tank_step_left"},{"a":41563,"l":"tank_halt","c":"Stops a tank where it is by clearing its drift byte $0B76. Called when the tank decides to sit and shoot rather than close on the helicopter.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[41448,41484,41556]},{"a":41565,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":41567,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":41570,"t":"code","b":[96],"m":"rts"},{"a":41571,"l":"tank_drive_away","c":"Drives a tank away from the helicopter: if the bearing $81 says the helicopter is to the right ($81 negative, i.e. past $80) it goes right, otherwise left. Used when the helicopter is wrecked and when a random draw at $A1E2 or $A1F9 tells the tank to back off.","t":"code","b":[36,129],"m":"bit","oa":129,"o":"zpa_81","x":[41353,41442,41465]},{"a":41573,"t":"code","b":[48,10],"m":"bmi","oa":41585,"o":"tank_step_right"},{"a":41575,"t":"code","b":[76,171,162],"m":"jmp","oa":41643,"o":"tank_step_left"},{"a":41578,"l":"tank_drive_toward","c":"Drives a tank toward the helicopter: the mirror of $A263, going right when the bearing $81 says the helicopter is to the right. This is the normal approach behaviour and also what $A1CC uses when the machine has been destroyed.","t":"code","b":[36,129],"m":"bit","oa":129,"o":"zpa_81","x":[41356,41420,41471]},{"a":41580,"t":"code","b":[16,3],"m":"bpl","oa":41585,"o":"tank_step_right"},{"a":41582,"t":"code","b":[76,171,162],"m":"jmp","oa":41643,"o":"tank_step_left"},{"a":41585,"l":"tank_step_right","c":"Moves a tank four world units to the right and records the direction by setting its drift $0B76 to +4. It first refuses to cross the right-hand end of the battlefield: with $6D = $1174 minus the tank's world X, the move is abandoned when $6D has fallen to $C0 minus eight times the tank's rank $0B7B, minus one, and abandoned outright once the tank is already past $1174. Rank is 5 to 12 and unique among live tanks ($9F69), so tanks halt between about 95 and 151 units short of $1174 and each stops at its own distance instead of piling onto the same spot.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[41558,41573,41580]},{"a":41587,"t":"code","b":[56],"m":"sec"},{"a":41588,"t":"code","b":[169,116],"m":"lda","o":"#$74"},{"a":41590,"t":"code","b":[253,120,11],"m":"sbc","oa":2936,"o":"actor_x,x"},{"a":41593,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":41595,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":41597,"t":"code","b":[253,121,11],"m":"sbc","oa":2937,"o":"actor_x_hi,x"},{"a":41600,"t":"code","b":[240,3],"m":"beq","oa":41605,"o":"b_A285"},{"a":41602,"t":"code","b":[16,16],"m":"bpl","oa":41620,"o":"b_A294"},{"a":41604,"t":"code","b":[96],"m":"rts"},{"a":41605,"l":"b_A285","t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x","x":[41600]},{"a":41608,"t":"code","b":[10],"m":"asl","o":"a"},{"a":41609,"t":"code","b":[10],"m":"asl","o":"a"},{"a":41610,"t":"code","b":[10],"m":"asl","o":"a"},{"a":41611,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":41613,"t":"code","b":[24],"m":"clc"},{"a":41614,"t":"code","b":[105,192],"m":"adc","o":"#$C0"},{"a":41616,"t":"code","b":[197,109],"m":"cmp","oa":109,"o":"zpa_6D"},{"a":41618,"t":"code","b":[176,22],"m":"bcs","oa":41642,"o":"r_A2AA"},{"a":41620,"l":"b_A294","t":"code","b":[24],"m":"clc","x":[41602]},{"a":41621,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":41624,"t":"code","b":[105,4],"m":"adc","o":"#$04"},{"a":41626,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":41629,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":41632,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":41634,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":41637,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":41639,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":41642,"l":"r_A2AA","t":"code","b":[96],"m":"rts","x":[41618]},{"a":41643,"l":"tank_step_left","c":"Moves a tank four world units to the left, sixteen-bit, and records the direction by setting its drift $0B76 to $FC (-4). There is no limit on this side: a tank that keeps going left eventually passes three pages from the helicopter and is deleted by the range check at $A16B.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[41560,41575,41582]},{"a":41645,"t":"code","b":[56],"m":"sec"},{"a":41646,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":41649,"t":"code","b":[233,4],"m":"sbc","o":"#$04"},{"a":41651,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":41654,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":41657,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":41659,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":41662,"t":"code","b":[169,252],"m":"lda","o":"#$FC"},{"a":41664,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":41667,"t":"code","b":[96],"m":"rts"},{"a":41668,"l":"tank_fire","c":"Fires a tank shell. Called from $A241 when the aim check has set $0B59. Saves the tank's own slot in $0B5A, takes a fresh slot with $A951 and builds an actor of type 8 (handler $B26D, outside this range) in it: world X = the tank's minus $10, then shifted again by $A34F indexed on the aim index plus the tank's own drift, so a shell from a moving tank inherits its speed and a steeper gun throws the muzzle further forward; height $0B7A = the tank's plus 9 and rank $0B7B = the tank's plus 1, which puts the shell at the muzzle rather than the hull. The velocity comes from three more tables indexed by the same aim index: $A354 gives $0B75 the vertical component $F4, $F9, $00, $07, $0C (-12 to +12) with the tank's drift added, $A359 gives $0B76 a constant 3 and $A35E gives $0B77 the value 2, 3, 4, 3 or 2. $A95B links the shell into the display list and $72 is restored to the tank's own slot before returning, so the handler can carry on.","t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot","x":[41537]},{"a":41670,"t":"code","b":[141,90,11],"m":"sta","oa":2906,"o":"a_0B5A"},{"a":41673,"t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc"},{"a":41676,"t":"code","b":[174,90,11],"m":"ldx","oa":2906,"o":"a_0B5A"},{"a":41679,"t":"code","b":[164,114],"m":"ldy","oa":114,"o":"actor_slot"},{"a":41681,"t":"code","b":[169,8],"m":"lda","o":"#$08"},{"a":41683,"t":"code","b":[153,116,11],"m":"sta","oa":2932,"o":"actor_type,y"},{"a":41686,"t":"code","b":[56],"m":"sec"},{"a":41687,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":41690,"t":"code","b":[233,16],"m":"sbc","o":"#$10"},{"a":41692,"t":"code","b":[153,120,11],"m":"sta","oa":2936,"o":"actor_x,y"},{"a":41695,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":41698,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":41700,"t":"code","b":[153,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,y"},{"a":41703,"t":"code","b":[188,119,11],"m":"ldy","oa":2935,"o":"actor_frame,x"},{"a":41706,"t":"code","b":[185,79,163],"m":"lda","oa":41807,"o":"shell_launch_xoff_table,y"},{"a":41709,"t":"code","b":[164,114],"m":"ldy","oa":114,"o":"actor_slot"},{"a":41711,"t":"code","b":[24],"m":"clc"},{"a":41712,"t":"code","b":[125,118,11],"m":"adc","oa":2934,"o":"actor_vy,x"},{"a":41715,"t":"code","b":[48,18],"m":"bmi","oa":41735,"o":"b_A307"},{"a":41717,"t":"code","b":[24],"m":"clc"},{"a":41718,"t":"code","b":[121,120,11],"m":"adc","oa":2936,"o":"actor_x,y"},{"a":41721,"t":"code","b":[153,120,11],"m":"sta","oa":2936,"o":"actor_x,y"},{"a":41724,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":41726,"t":"code","b":[121,121,11],"m":"adc","oa":2937,"o":"actor_x_hi,y"},{"a":41729,"t":"code","b":[153,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,y"},{"a":41732,"t":"code","b":[76,22,163],"m":"jmp","oa":41750,"o":"j_A316"},{"a":41735,"l":"b_A307","t":"code","b":[24],"m":"clc","x":[41715]},{"a":41736,"t":"code","b":[121,120,11],"m":"adc","oa":2936,"o":"actor_x,y"},{"a":41739,"t":"code","b":[153,120,11],"m":"sta","oa":2936,"o":"actor_x,y"},{"a":41742,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":41744,"t":"code","b":[121,121,11],"m":"adc","oa":2937,"o":"actor_x_hi,y"},{"a":41747,"t":"code","b":[153,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,y"},{"a":41750,"l":"j_A316","t":"code","b":[24],"m":"clc","x":[41732]},{"a":41751,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":41754,"t":"code","b":[105,9],"m":"adc","o":"#$09"},{"a":41756,"t":"code","b":[153,122,11],"m":"sta","oa":2938,"o":"actor_alt,y"},{"a":41759,"t":"code","b":[24],"m":"clc"},{"a":41760,"t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x"},{"a":41763,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":41765,"t":"code","b":[153,123,11],"m":"sta","oa":2939,"o":"actor_base_row,y"},{"a":41768,"t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x"},{"a":41771,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":41773,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":41776,"t":"code","b":[170],"m":"tax"},{"a":41777,"t":"code","b":[24],"m":"clc"},{"a":41778,"t":"code","b":[189,84,163],"m":"lda","oa":41812,"o":"shell_dy_table,x"},{"a":41781,"t":"code","b":[101,111],"m":"adc","oa":111,"o":"zpa_6F"},{"a":41783,"t":"code","b":[153,117,11],"m":"sta","oa":2933,"o":"actor_vx,y"},{"a":41786,"t":"code","b":[189,89,163],"m":"lda","oa":41817,"o":"shell_speed_table,x"},{"a":41789,"t":"code","b":[153,118,11],"m":"sta","oa":2934,"o":"actor_vy,y"},{"a":41792,"t":"code","b":[189,94,163],"m":"lda","oa":41822,"o":"shell_shape_table,x"},{"a":41795,"t":"code","b":[153,119,11],"m":"sta","oa":2935,"o":"actor_frame,y"},{"a":41798,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":41801,"t":"code","b":[173,90,11],"m":"lda","oa":2906,"o":"a_0B5A"},{"a":41804,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":41806,"t":"code","b":[96],"m":"rts"},{"a":41807,"l":"shell_launch_xoff_table","c":"Five bytes, $00 $06 $10 $19 $1F, indexed at $A2EA by the firing tank's aim index. Added to the shell's starting world X (already the tank's minus $10), with the tank's own drift on top, so the shell leaves the muzzle rather than the middle of the hull and the offset grows as the gun comes up.","t":"byte","b":[0,6,16,25,31],"x":[41706]},{"a":41812,"l":"shell_dy_table","c":"Five signed bytes, $F4 $F9 $00 $07 $0C (-12, -7, 0, +7, +12), indexed at $A332 by the firing tank's aim index. The tank's own drift $0B76 is added and the sum becomes the new shell's $0B75, its vertical velocity component. The five values are the elevations that go with shapes 41 to 45.","t":"byte","b":[244,249,0,7,12],"x":[41778]},{"a":41817,"l":"shell_speed_table","c":"Five bytes, all $03, indexed at $A33A by the firing tank's aim index and stored into the shell's $0B76. Every shell leaves at the same horizontal speed of 3 whatever the elevation; the table exists so the launch code can be written once, and the five entries could be given different values without touching the code.","t":"byte","b":[3,3,3,3,3],"x":[41786]},{"a":41822,"l":"shell_shape_table","c":"Five bytes, $02 $03 $04 $03 $02, indexed at $A340 by the firing tank's aim index and stored into the shell's $0B77. Symmetrical about the level gun, so the shell's own handler at $B26D draws or steers a steeply climbing and a steeply falling shell the same way.","t":"byte","b":[2,3,4,3,2],"x":[41792]},{"a":41827,"l":"spawn_scheduler","c":"The game's spawn clock, called once per tick from $96CC (118 hits in 118 ticks, live). Two gates on the tick counter $89. Every fourth tick it calls $9E22, which is what puts hostages out of the barracks and takes them out of the helicopter at the base. Then it returns immediately unless $89 AND $2F is zero, which is true for eight of every 256 ticks, and that slower beat drives the vehicles: a random byte from $DC04 and the difficulty level $8D decide between three outcomes. At $8D >= 2, with the spare bits of the random byte clear and $0CE1 showing no type-10 actor alive, $A044 makes one. Otherwise, if the random byte is positive and the type-9 count $0CE3 has not reached the limit in $A3B6, $9FA6 makes a type-9. Failing both, if the live tank count $0CE8 is below the limit in $A3B2, $9F12 makes a tank. At $8D = 0 only tanks can appear.","t":"code","b":[165,137],"m":"lda","oa":137,"o":"phase_frames","x":[38604]},{"a":41829,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":41831,"t":"code","b":[208,3],"m":"bne","oa":41836,"o":"b_A36C"},{"a":41833,"t":"code","b":[32,34,158],"m":"jsr","oa":40482,"o":"hostage_release_tick"},{"a":41836,"l":"b_A36C","t":"code","b":[165,137],"m":"lda","oa":137,"o":"phase_frames","x":[41831]},{"a":41838,"t":"code","b":[41,47],"m":"and","o":"#$2F"},{"a":41840,"t":"code","b":[240,1],"m":"beq","oa":41843,"o":"b_A373"},{"a":41842,"t":"code","b":[96],"m":"rts"},{"a":41843,"l":"b_A373","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[41840]},{"a":41846,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":41848,"t":"code","b":[165,141],"m":"lda","oa":141,"o":"zpa_8D"},{"a":41850,"t":"code","b":[240,41],"m":"beq","oa":41893,"o":"b_A3A5"},{"a":41852,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":41854,"t":"code","b":[240,20],"m":"beq","oa":41876,"o":"b_A394"},{"a":41856,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":41858,"t":"code","b":[41,40],"m":"and","o":"#$28"},{"a":41860,"t":"code","b":[208,14],"m":"bne","oa":41876,"o":"b_A394","x":[32818]},{"a":41862,"t":"code","b":[165,141],"m":"lda","oa":141,"o":"zpa_8D"},{"a":41864,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":41866,"t":"code","b":[144,8],"m":"bcc","oa":41876,"o":"b_A394"},{"a":41868,"t":"code","b":[173,225,12],"m":"lda","oa":3297,"o":"a_0CE1"},{"a":41871,"t":"code","b":[208,3],"m":"bne","oa":41876,"o":"b_A394"},{"a":41873,"t":"code","b":[76,68,160],"m":"jmp","oa":41028,"o":"actor10_spawn"},{"a":41876,"l":"b_A394","t":"code","b":[36,111],"m":"bit","oa":111,"o":"zpa_6F","x":[41854,41860,41866,41871]},{"a":41878,"t":"code","b":[48,13],"m":"bmi","oa":41893,"o":"b_A3A5"},{"a":41880,"t":"code","b":[166,141],"m":"ldx","oa":141,"o":"zpa_8D"},{"a":41882,"t":"code","b":[189,182,163],"m":"lda","oa":41910,"o":"actor9_limit_table,x"},{"a":41885,"t":"code","b":[205,227,12],"m":"cmp","oa":3299,"o":"hit_list_len"},{"a":41888,"t":"code","b":[240,3],"m":"beq","oa":41893,"o":"b_A3A5"},{"a":41890,"t":"code","b":[76,166,159],"m":"jmp","oa":40870,"o":"actor9_spawn"},{"a":41893,"l":"b_A3A5","t":"code","b":[166,141],"m":"ldx","oa":141,"o":"zpa_8D","x":[41850,41878,41888]},{"a":41895,"t":"code","b":[173,232,12],"m":"lda","oa":3304,"o":"board_list_len"},{"a":41898,"t":"code","b":[221,178,163],"m":"cmp","oa":41906,"o":"max_tanks_table,x"},{"a":41901,"t":"code","b":[176,35],"m":"bcs","oa":41938,"o":"r_A3D2"},{"a":41903,"t":"code","b":[76,18,159],"m":"jmp","oa":40722,"o":"tank_spawn"},{"a":41906,"l":"max_tanks_table","c":"Four bytes, $01 $02 $01 $01, indexed by the difficulty level $8D at $A3AA and compared against $0CE8, the number of tanks currently alive. One tank at a time at difficulty 0, two at 1, and back to one at 2 and 3 - where the aircraft spawned by $9FA6 and $A044 take over the pressure.","t":"byte","b":[1,2,1,1],"x":[41898]},{"a":41910,"l":"actor9_limit_table","c":"Four bytes, $00 $01 $02 $02, indexed by the difficulty level $8D at $A39A and compared against $0CE3, the number of type-9 actors alive. The comparison is an equality test, so the limit is also the count: none at all at difficulty 0, one at 1, two at 2 and 3.","t":"byte","b":[0,1,2,2],"x":[41882]},{"a":41914,"l":"aboard_counter_inc","c":"Adds one, in BCD, to $0CFE, the number of hostages aboard the helicopter shown in the middle field of the status bar, and redraws it by calling $A978 with X = 1, which writes the two digits at screen offsets $0464 and $0465, just after the diamond glyph, in both text matrices. Saves and restores X and Y. Called from $9D18 when a hostage climbs in.","t":"code","b":[134,132],"m":"stx","oa":132,"o":"zpa_84","x":[40227]},{"a":41916,"t":"code","b":[132,133],"m":"sty","oa":133,"o":"zpa_85"},{"a":41918,"t":"code","b":[248],"m":"sed"},{"a":41919,"t":"code","b":[24],"m":"clc"},{"a":41920,"t":"code","b":[173,254,12],"m":"lda","oa":3326,"o":"a_0CFE"},{"a":41923,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":41925,"t":"code","b":[141,254,12],"m":"sta","oa":3326,"o":"a_0CFE"},{"a":41928,"t":"code","b":[216],"m":"cld"},{"a":41929,"t":"code","b":[162,1],"m":"ldx","o":"#$01"},{"a":41931,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":41934,"t":"code","b":[166,132],"m":"ldx","oa":132,"o":"zpa_84"},{"a":41936,"t":"code","b":[164,133],"m":"ldy","oa":133,"o":"zpa_85"},{"a":41938,"l":"r_A3D2","t":"code","b":[96],"m":"rts","x":[41901]},{"a":41939,"l":"aboard_counter_dec","c":"Subtracts one, in BCD, from $0CFE and redraws the middle status-bar field through $A978 with X = 1, the counterpart of $A3BA. Saves and restores X and Y. Called from $9EA4 when a hostage is put down at the home base.","t":"code","b":[134,132],"m":"stx","oa":132,"o":"zpa_84","x":[40612]},{"a":41941,"t":"code","b":[132,133],"m":"sty","oa":133,"o":"zpa_85"},{"a":41943,"t":"code","b":[248],"m":"sed"},{"a":41944,"t":"code","b":[56],"m":"sec"},{"a":41945,"t":"code","b":[173,254,12],"m":"lda","oa":3326,"o":"a_0CFE"},{"a":41948,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":41950,"t":"code","b":[141,254,12],"m":"sta","oa":3326,"o":"a_0CFE"},{"a":41953,"t":"code","b":[216],"m":"cld"},{"a":41954,"t":"code","b":[162,1],"m":"ldx","o":"#$01"},{"a":41956,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":41959,"t":"code","b":[166,132],"m":"ldx","oa":132,"o":"zpa_84"},{"a":41961,"t":"code","b":[164,133],"m":"ldy","oa":133,"o":"zpa_85"},{"a":41963,"t":"code","b":[96],"m":"rts"},{"a":41964,"l":"rescued_counter_inc","c":"Adds one, in BCD, to $0CFD, the tally of hostages safely delivered, and redraws the right-hand status-bar field by calling $A978 with X = 2, which writes the two digits at screen offsets $046F and $0470, just after the heart glyph. Then plays the two-note rising cue through $A7C7 with voice parameters ($2B, 1) and ($40, 2) before restoring X and Y. Called from $9EA7, once per hostage set down at the base. The third, leftmost field of the bar is the casualty counter $0CFC, which $B0D2 owns.","t":"code","b":[134,132],"m":"stx","oa":132,"o":"zpa_84","x":[40615]},{"a":41966,"t":"code","b":[132,133],"m":"sty","oa":133,"o":"zpa_85"},{"a":41968,"t":"code","b":[248],"m":"sed"},{"a":41969,"t":"code","b":[24],"m":"clc"},{"a":41970,"t":"code","b":[173,253,12],"m":"lda","oa":3325,"o":"a_0CFD"},{"a":41973,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":41975,"t":"code","b":[141,253,12],"m":"sta","oa":3325,"o":"a_0CFD"},{"a":41978,"t":"code","b":[216],"m":"cld"},{"a":41979,"t":"code","b":[162,2],"m":"ldx","o":"#$02"},{"a":41981,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":41984,"l":"killed_tally_sfx","c":"Tail of the routine that starts at $A3EC. That routine adds 1 in binary-coded decimal to $0CFD and redraws it as the third (heart) status-bar counter; here it plays two effects through $A7C7 - pitch $2B held one frame, then pitch $40 held two - and restores the caller's X and Y from $84/$85. Its only caller, $9EA7, runs immediately after $9EA4 has called $A3D3 to take one off the second (diamond) counter $0CFE, so the pair moves one unit from the second counter to the third.","t":"code","b":[162,43],"m":"ldx","o":"#$2B"},{"a":41986,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":41988,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":41991,"t":"code","b":[162,64],"m":"ldx","o":"#$40"},{"a":41993,"t":"code","b":[160,2],"m":"ldy","o":"#$02"},{"a":41995,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":41998,"t":"code","b":[166,132],"m":"ldx","oa":132,"o":"zpa_84"},{"a":42000,"t":"code","b":[164,133],"m":"ldy","oa":133,"o":"zpa_85"},{"a":42002,"t":"code","b":[96],"m":"rts"},{"a":42003,"l":"heli_fly_controls","c":"Turns this frame's joystick reading into the helicopter's two velocities; called first thing every frame from $A4C7. The horizontal velocity $51/$52 (signed 16-bit, world units times 256) is dragged by one sixteenth of itself, then the thrust word from $A4AB/$A4AC indexed by 2*|$5B| is subtracted when the stick is left ($5B = +5) and added when it is right ($5B = -5); the result is clamped to exactly +/-$1500 with the low byte zeroed. The vertical velocity $53/$54 is then moved toward the target climb rate $A4B7[$5C]: the gap is halved while it is 2 or more, up to twice, so it closes by a quarter of the distance a frame. $53 is always cleared, so only the high byte of the vertical velocity survives.","t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51","x":[42183]},{"a":42005,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42007,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42009,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42011,"t":"code","b":[160,4],"m":"ldy","o":"#$04"},{"a":42013,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":42016,"t":"code","b":[56],"m":"sec"},{"a":42017,"t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51"},{"a":42019,"t":"code","b":[229,127],"m":"sbc","oa":127,"o":"zpa_7F"},{"a":42021,"t":"code","b":[133,81],"m":"sta","oa":81,"o":"zpa_51"},{"a":42023,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42025,"t":"code","b":[229,128],"m":"sbc","oa":128,"o":"zpa_80"},{"a":42027,"t":"code","b":[133,82],"m":"sta","oa":82,"o":"zpa_52"},{"a":42029,"t":"code","b":[165,91],"m":"lda","oa":91,"o":"stick_x"},{"a":42031,"t":"code","b":[16,5],"m":"bpl","oa":42038,"o":"b_A436"},{"a":42033,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":42035,"t":"code","b":[24],"m":"clc"},{"a":42036,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":42038,"l":"b_A436","t":"code","b":[10],"m":"asl","o":"a","x":[42031]},{"a":42039,"t":"code","b":[168],"m":"tay"},{"a":42040,"t":"code","b":[36,91],"m":"bit","oa":91,"o":"stick_x"},{"a":42042,"t":"code","b":[16,2],"m":"bpl","oa":42046,"o":"b_A43E"},{"a":42044,"t":"code","b":[48,18],"m":"bmi","oa":42064,"o":"b_A450"},{"a":42046,"l":"b_A43E","t":"code","b":[56],"m":"sec","x":[42042]},{"a":42047,"t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51"},{"a":42049,"t":"code","b":[249,171,164],"m":"sbc","oa":42155,"o":"heli_thrust_lo,y"},{"a":42052,"t":"code","b":[133,81],"m":"sta","oa":81,"o":"zpa_51"},{"a":42054,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42056,"t":"code","b":[249,172,164],"m":"sbc","oa":42156,"o":"heli_thrust_hi,y"},{"a":42059,"t":"code","b":[133,82],"m":"sta","oa":82,"o":"zpa_52"},{"a":42061,"t":"code","b":[76,95,164],"m":"jmp","oa":42079,"o":"j_A45F"},{"a":42064,"l":"b_A450","t":"code","b":[24],"m":"clc","x":[42044]},{"a":42065,"t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51"},{"a":42067,"t":"code","b":[121,171,164],"m":"adc","oa":42155,"o":"heli_thrust_lo,y"},{"a":42070,"t":"code","b":[133,81],"m":"sta","oa":81,"o":"zpa_51"},{"a":42072,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42074,"t":"code","b":[121,172,164],"m":"adc","oa":42156,"o":"heli_thrust_hi,y"},{"a":42077,"t":"code","b":[133,82],"m":"sta","oa":82,"o":"zpa_52"},{"a":42079,"l":"j_A45F","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[42061]},{"a":42081,"t":"code","b":[133,119],"m":"sta","oa":119,"o":"zpa_77"},{"a":42083,"t":"code","b":[164,92],"m":"ldy","oa":92,"o":"stick_y"},{"a":42085,"t":"code","b":[56],"m":"sec"},{"a":42086,"t":"code","b":[185,183,164],"m":"lda","oa":42167,"o":"climb_rate_table,y"},{"a":42089,"t":"code","b":[229,84],"m":"sbc","oa":84,"o":"zpa_54"},{"a":42091,"t":"code","b":[16,9],"m":"bpl","oa":42102,"o":"b_A476"},{"a":42093,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":42095,"t":"code","b":[24],"m":"clc"},{"a":42096,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":42098,"t":"code","b":[162,255],"m":"ldx","o":"#$FF"},{"a":42100,"t":"code","b":[134,119],"m":"stx","oa":119,"o":"zpa_77"},{"a":42102,"l":"b_A476","t":"code","b":[201,2],"m":"cmp","o":"#$02","x":[42091]},{"a":42104,"t":"code","b":[144,6],"m":"bcc","oa":42112,"o":"b_A480"},{"a":42106,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":42107,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":42109,"t":"code","b":[144,1],"m":"bcc","oa":42112,"o":"b_A480"},{"a":42111,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":42112,"l":"b_A480","t":"code","b":[24],"m":"clc","x":[42104,42109]},{"a":42113,"t":"code","b":[36,119],"m":"bit","oa":119,"o":"zpa_77"},{"a":42115,"t":"code","b":[16,3],"m":"bpl","oa":42120,"o":"b_A488"},{"a":42117,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":42119,"t":"code","b":[56],"m":"sec"},{"a":42120,"l":"b_A488","t":"code","b":[101,84],"m":"adc","oa":84,"o":"zpa_54","x":[42115]},{"a":42122,"t":"code","b":[133,84],"m":"sta","oa":84,"o":"zpa_54"},{"a":42124,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42126,"t":"code","b":[133,83],"m":"sta","oa":83,"o":"zpa_53"},{"a":42128,"s":"clamp the horizontal velocity to exactly +/-$1500, low byte zeroed","t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42130,"t":"code","b":[201,21],"m":"cmp","o":"#$15"},{"a":42132,"t":"code","b":[144,20],"m":"bcc","oa":42154,"o":"r_A4AA"},{"a":42134,"t":"code","b":[201,235],"m":"cmp","o":"#$EB"},{"a":42136,"t":"code","b":[176,16],"m":"bcs","oa":42154,"o":"r_A4AA"},{"a":42138,"t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52"},{"a":42140,"t":"code","b":[48,4],"m":"bmi","oa":42146,"o":"b_A4A2"},{"a":42142,"t":"code","b":[169,21],"m":"lda","o":"#$15"},{"a":42144,"t":"code","b":[208,2],"m":"bne","oa":42148,"o":"b_A4A4"},{"a":42146,"l":"b_A4A2","t":"code","b":[169,235],"m":"lda","o":"#$EB","x":[42140]},{"a":42148,"l":"b_A4A4","t":"code","b":[133,82],"m":"sta","oa":82,"o":"zpa_52","x":[42144]},{"a":42150,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42152,"t":"code","b":[133,81],"m":"sta","oa":81,"o":"zpa_51"},{"a":42154,"l":"r_A4AA","t":"code","b":[96],"m":"rts","x":[42132,42136]},{"a":42155,"l":"heli_thrust_lo","c":"Low bytes of six 16-bit horizontal thrust values, one per stick deflection 0..5: $0000, $0060, $00B4, $0108, $015C, $01A4. $A413 adds or subtracts entry |$5B| to the helicopter's velocity. Only entry 5 ($01A4 = 420 units per frame) is ever used, because $A741 only ever puts 0 or +/-5 in $5B.","t":"word","b":[0],"d":[],"x":[42049,42067]},{"a":42156,"l":"heli_thrust_hi","c":"High bytes of the same six thrust values; $A413 reads $A4AB,y and $A4AC,y with y = 2*|$5B| as one little-endian word, so the pair at index 5 is $01A4.","t":"word","b":[0,96,0,180,0,8,1,92],"d":[24576,46080,2048,23553],"x":[42056,42074]},{"a":42164,"t":"word","b":[1,164,1],"d":[41985]},{"a":42167,"l":"climb_rate_table","c":"Target vertical velocity (the high byte of $53/$54) indexed by $5C, sixteen signed bytes $F6,$F7..$FF,$00,$01..$04,$06 - that is index minus 10, except index 15 which is +6 rather than +5. Only five indices occur: 0 (both up and down pressed) gives -10, 2 (forced by $A738 once the helicopter has been hit) -8, 5 (stick down, or stick centred in flight) -5, $0A (stick centred on the ground) 0, and $0F (stick up) +6. Read by $A413.","t":"byte","b":[246,247,248,249,250,251,252,253],"x":[42086]},{"a":42175,"t":"byte","b":[254,255,0,1,2,3,4,6]},{"a":42183,"l":"heli_update","c":"One frame of helicopter flight, called from the type-0 actor handler at $B0CE. $A413 turns the stick into the velocities $51/$52 and $53/$54, then one of two models runs: $A615 while $5D says the machine is airborne, $A4DA while it is in contact with the ground. Finishes by tail-calling $A7D6, which re-decides airborne-or-grounded for next frame and handles the base window, the stopped flag and the hit sequence. Verified live: with the helicopter parked only $A4DA is hit, and holding up switches every hit to $A615.","t":"code","b":[32,19,164],"m":"jsr","oa":42003,"o":"heli_fly_controls","x":[45262]},{"a":42186,"t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up"},{"a":42188,"t":"code","b":[208,6],"m":"bne","oa":42196,"o":"b_A4D4"},{"a":42190,"t":"code","b":[32,218,164],"m":"jsr","oa":42202,"o":"heli_ground_model"},{"a":42193,"t":"code","b":[76,215,164],"m":"jmp","oa":42199,"o":"j_A4D7"},{"a":42196,"l":"b_A4D4","t":"code","b":[32,21,166],"m":"jsr","oa":42517,"o":"heli_air_model","x":[42188]},{"a":42199,"l":"j_A4D7","t":"code","b":[76,214,167],"m":"jmp","oa":42966,"o":"heli_after_move","x":[42193]},{"a":42202,"l":"heli_ground_model","c":"The ground-contact flight model, used while $5D is clear. If a hard contact was flagged last frame ($60) it is cleared, the altitude $57 is nudged back up by one and $A5BE bounces the vertical velocity. Otherwise, with the helicopter level ($5A = 0): a descent faster than about -5.4 units a frame sets $60, drops $57 by one and adds the ground push of $A5E1 - the hard landing; a gentler descent simply bounces; anything not descending gets the ground push. Every path except a banked skid halves $51/$52, which is the skid friction. If the vertical velocity has turned positive the machine has lifted off and control passes straight to $A615; otherwise the new bank angle is worked out at $A556 as $5A minus (($51/$52 plus or minus $53/$54) shifted right 9), never allowed past level and clamped to +/-5, and handed to $A8B8.","t":"code","b":[165,96],"m":"lda","oa":96,"o":"zpa_60","x":[42190]},{"a":42204,"t":"code","b":[208,7],"m":"bne","oa":42213,"o":"b_A4E5"},{"a":42206,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":42208,"t":"code","b":[240,20],"m":"beq","oa":42230,"o":"b_A4F6"},{"a":42210,"t":"code","b":[76,37,165],"m":"jmp","oa":42277,"o":"j_A525"},{"a":42213,"l":"b_A4E5","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[42204]},{"a":42215,"t":"code","b":[133,96],"m":"sta","oa":96,"o":"zpa_60"},{"a":42217,"t":"code","b":[24],"m":"clc"},{"a":42218,"t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":42220,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":42222,"s":"hard-contact recovery: altitude back up one","t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57"},{"a":42224,"t":"code","b":[32,190,165],"m":"jsr","oa":42430,"o":"heli_bounce"},{"a":42227,"t":"code","b":[76,43,165],"m":"jmp","oa":42283,"o":"j_A52B"},{"a":42230,"l":"b_A4F6","t":"code","b":[36,84],"m":"bit","oa":84,"o":"zpa_54","x":[42208]},{"a":42232,"t":"code","b":[48,3],"m":"bmi","oa":42237,"o":"b_A4FD"},{"a":42234,"t":"code","b":[76,31,165],"m":"jmp","oa":42271,"o":"j_A51F"},{"a":42237,"l":"b_A4FD","t":"code","b":[165,84],"m":"lda","oa":84,"o":"zpa_54","x":[42232]},{"a":42239,"t":"code","b":[201,251],"m":"cmp","o":"#$FB"},{"a":42241,"t":"code","b":[144,8],"m":"bcc","oa":42251,"o":"b_A50B"},{"a":42243,"t":"code","b":[208,20],"m":"bne","oa":42265,"o":"b_A519"},{"a":42245,"t":"code","b":[165,83],"m":"lda","oa":83,"o":"zpa_53"},{"a":42247,"t":"code","b":[201,160],"m":"cmp","o":"#$A0"},{"a":42249,"t":"code","b":[176,14],"m":"bcs","oa":42265,"o":"b_A519"},{"a":42251,"l":"b_A50B","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[42241]},{"a":42253,"s":"hard contact: flag it, drop the altitude one and add the ground push","t":"code","b":[133,96],"m":"sta","oa":96,"o":"zpa_60"},{"a":42255,"t":"code","b":[56],"m":"sec"},{"a":42256,"t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":42258,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":42260,"t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57"},{"a":42262,"t":"code","b":[76,225,165],"m":"jmp","oa":42465,"o":"heli_ground_push"},{"a":42265,"l":"b_A519","t":"code","b":[32,190,165],"m":"jsr","oa":42430,"o":"heli_bounce","x":[42243,42249]},{"a":42268,"t":"code","b":[76,43,165],"m":"jmp","oa":42283,"o":"j_A52B"},{"a":42271,"l":"j_A51F","t":"code","b":[32,225,165],"m":"jsr","oa":42465,"o":"heli_ground_push","x":[42234]},{"a":42274,"t":"code","b":[76,43,165],"m":"jmp","oa":42283,"o":"j_A52B"},{"a":42277,"l":"j_A525","t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A","x":[42210]},{"a":42279,"t":"code","b":[69,82],"m":"eor","oa":82,"o":"zpa_52"},{"a":42281,"t":"code","b":[16,21],"m":"bpl","oa":42304,"o":"b_A540"},{"a":42283,"l":"j_A52B","t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51","x":[42227,42268,42274]},{"a":42285,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42287,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42289,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42291,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":42293,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":42296,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":42298,"t":"code","b":[133,81],"m":"sta","oa":81,"o":"zpa_51"},{"a":42300,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":42302,"t":"code","b":[133,82],"m":"sta","oa":82,"o":"zpa_52"},{"a":42304,"l":"b_A540","t":"code","b":[165,84],"m":"lda","oa":84,"o":"zpa_54","x":[42281]},{"a":42306,"t":"code","b":[48,18],"m":"bmi","oa":42326,"o":"b_A556"},{"a":42308,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":42310,"t":"code","b":[144,14],"m":"bcc","oa":42326,"o":"b_A556"},{"a":42312,"t":"code","b":[208,9],"m":"bne","oa":42323,"o":"b_A553"},{"a":42314,"t":"code","b":[165,83],"m":"lda","oa":83,"o":"zpa_53"},{"a":42316,"t":"code","b":[201,0],"m":"cmp","o":"#$00"},{"a":42318,"t":"code","b":[176,3],"m":"bcs","oa":42323,"o":"b_A553"},{"a":42320,"t":"code","b":[76,86,165],"m":"jmp","oa":42326,"o":"b_A556"},{"a":42323,"l":"b_A553","t":"code","b":[76,21,166],"m":"jmp","oa":42517,"o":"heli_air_model","x":[42312,42318]},{"a":42326,"l":"b_A556","t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51","x":[42306,42310,42320]},{"a":42328,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42330,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42332,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42334,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":42336,"t":"code","b":[240,5],"m":"beq","oa":42343,"o":"b_A567"},{"a":42338,"t":"code","b":[16,9],"m":"bpl","oa":42349,"o":"b_A56D"},{"a":42340,"t":"code","b":[76,125,165],"m":"jmp","oa":42365,"o":"j_A57D"},{"a":42343,"l":"b_A567","t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52","x":[42336]},{"a":42345,"t":"code","b":[48,2],"m":"bmi","oa":42349,"o":"b_A56D"},{"a":42347,"t":"code","b":[16,16],"m":"bpl","oa":42365,"o":"j_A57D"},{"a":42349,"l":"b_A56D","t":"code","b":[56],"m":"sec","x":[42338,42345]},{"a":42350,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":42352,"t":"code","b":[229,83],"m":"sbc","oa":83,"o":"zpa_53"},{"a":42354,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42356,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":42358,"t":"code","b":[229,84],"m":"sbc","oa":84,"o":"zpa_54"},{"a":42360,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42362,"t":"code","b":[76,138,165],"m":"jmp","oa":42378,"o":"j_A58A"},{"a":42365,"l":"j_A57D","t":"code","b":[24],"m":"clc","x":[42340,42347]},{"a":42366,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":42368,"t":"code","b":[101,83],"m":"adc","oa":83,"o":"zpa_53"},{"a":42370,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42372,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":42374,"t":"code","b":[101,84],"m":"adc","oa":84,"o":"zpa_54"},{"a":42376,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42378,"l":"j_A58A","t":"code","b":[160,9],"m":"ldy","o":"#$09","x":[42362]},{"a":42380,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":42383,"t":"code","b":[56],"m":"sec"},{"a":42384,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":42386,"t":"code","b":[229,127],"m":"sbc","oa":127,"o":"zpa_7F"},{"a":42388,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":42390,"t":"code","b":[69,90],"m":"eor","oa":90,"o":"zpa_5A"},{"a":42392,"t":"code","b":[16,8],"m":"bpl","oa":42402,"o":"b_A5A2"},{"a":42394,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":42396,"t":"code","b":[240,4],"m":"beq","oa":42402,"o":"b_A5A2"},{"a":42398,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42400,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":42402,"l":"b_A5A2","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[42392,42396]},{"a":42404,"t":"code","b":[48,11],"m":"bmi","oa":42417,"o":"b_A5B1"},{"a":42406,"t":"code","b":[201,6],"m":"cmp","o":"#$06"},{"a":42408,"t":"code","b":[144,15],"m":"bcc","oa":42425,"o":"b_A5B9"},{"a":42410,"t":"code","b":[169,5],"m":"lda","o":"#$05"},{"a":42412,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":42414,"t":"code","b":[76,185,165],"m":"jmp","oa":42425,"o":"b_A5B9"},{"a":42417,"l":"b_A5B1","t":"code","b":[201,251],"m":"cmp","o":"#$FB","x":[42404]},{"a":42419,"t":"code","b":[176,4],"m":"bcs","oa":42425,"o":"b_A5B9"},{"a":42421,"t":"code","b":[169,251],"m":"lda","o":"#$FB"},{"a":42423,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":42425,"l":"b_A5B9","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[42408,42414,42419]},{"a":42427,"t":"code","b":[76,184,168],"m":"jmp","oa":43192,"o":"heli_set_bank"},{"a":42430,"l":"heli_bounce","c":"Bounces the helicopter off the ground: shifts the vertical velocity $53/$54 right by 3 + $61 places and negates it, so a normal touchdown keeps an eighth of the impact speed and one after the machine has been hit ($61 set) only a sixteenth. This is what makes the helicopter rock on its skids after a landing.","t":"code","b":[165,83],"m":"lda","oa":83,"o":"zpa_53","x":[42224,42265]},{"a":42432,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42434,"t":"code","b":[165,84],"m":"lda","oa":84,"o":"zpa_54"},{"a":42436,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42438,"t":"code","b":[24],"m":"clc"},{"a":42439,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":42441,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":42443,"t":"code","b":[168],"m":"tay"},{"a":42444,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":42447,"t":"code","b":[24],"m":"clc"},{"a":42448,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":42450,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":42452,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":42454,"t":"code","b":[133,83],"m":"sta","oa":83,"o":"zpa_53"},{"a":42456,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":42458,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":42460,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":42462,"t":"code","b":[133,84],"m":"sta","oa":84,"o":"zpa_54"},{"a":42464,"t":"code","b":[96],"m":"rts"},{"a":42465,"l":"heli_ground_push","c":"Adds the ground's upward push to the vertical velocity $53/$54. The base impulse is the constant $04B0 held at $A613/$A614; while the helicopter is already rising it is shifted right by (($53/$54)*8 >> 8) places, so the push fades out the faster the machine climbs, and while it is descending the full value is used. This is the spring that lifts the helicopter off the ground and then holds it just above it.","t":"code","b":[173,19,166],"m":"lda","oa":42515,"o":"ground_push_lo","x":[42262,42271]},{"a":42468,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42470,"t":"code","b":[173,20,166],"m":"lda","oa":42516,"o":"ground_push_hi"},{"a":42473,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42475,"t":"code","b":[36,84],"m":"bit","oa":84,"o":"zpa_54"},{"a":42477,"t":"code","b":[48,22],"m":"bmi","oa":42501,"o":"b_A605"},{"a":42479,"t":"code","b":[165,84],"m":"lda","oa":84,"o":"zpa_54"},{"a":42481,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":42483,"t":"code","b":[165,83],"m":"lda","oa":83,"o":"zpa_53"},{"a":42485,"t":"code","b":[10],"m":"asl","o":"a"},{"a":42486,"t":"code","b":[38,109],"m":"rol","oa":109,"o":"zpa_6D"},{"a":42488,"t":"code","b":[10],"m":"asl","o":"a"},{"a":42489,"t":"code","b":[38,109],"m":"rol","oa":109,"o":"zpa_6D"},{"a":42491,"t":"code","b":[10],"m":"asl","o":"a"},{"a":42492,"t":"code","b":[38,109],"m":"rol","oa":109,"o":"zpa_6D"},{"a":42494,"t":"code","b":[164,109],"m":"ldy","oa":109,"o":"zpa_6D"},{"a":42496,"t":"code","b":[240,3],"m":"beq","oa":42501,"o":"b_A605"},{"a":42498,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":42501,"l":"b_A605","t":"code","b":[24],"m":"clc","x":[42477,42496]},{"a":42502,"t":"code","b":[165,83],"m":"lda","oa":83,"o":"zpa_53"},{"a":42504,"t":"code","b":[101,127],"m":"adc","oa":127,"o":"zpa_7F"},{"a":42506,"t":"code","b":[133,83],"m":"sta","oa":83,"o":"zpa_53"},{"a":42508,"t":"code","b":[165,84],"m":"lda","oa":84,"o":"zpa_54"},{"a":42510,"t":"code","b":[101,128],"m":"adc","oa":128,"o":"zpa_80"},{"a":42512,"t":"code","b":[133,84],"m":"sta","oa":84,"o":"zpa_54"},{"a":42514,"t":"code","b":[96],"m":"rts"},{"a":42515,"l":"ground_push_lo","c":"Low byte of the constant $04B0 (1200), the base upward impulse $A5E1 loads into $7F/$80 as the helicopter's ground push.","t":"word","b":[176],"d":[],"x":[42465]},{"a":42516,"l":"ground_push_hi","c":"High byte of that same constant $04B0; $A5E1 reads $A613 and $A614 as a little-endian pair.","t":"word","b":[4],"d":[],"x":[42470]},{"a":42517,"l":"heli_air_model","c":"The airborne flight model, used while $5D is set. Steps the bank angle $5A one unit toward the stick position $5B and shifts the world X by one unit in the same direction as it does so. Then adds ($51/$52) shifted right 8 to the world X $55/$56 and clamps it to the playfield - $02D0 at the left edge, $12D0 at the right - zeroing the horizontal velocity at either limit. Finally adds ($53/$54) shifted right 8 to the altitude $57, clamped to 0 below and $70 above, and zeroes the vertical velocity when $57 reaches $70; that is the ceiling, confirmed live by holding up until $57 sticks at $70 with $53/$54 at zero.","t":"code","b":[24],"m":"clc","x":[42196,42323]},{"a":42518,"t":"code","b":[165,91],"m":"lda","oa":91,"o":"stick_x"},{"a":42520,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":42522,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":42524,"t":"code","b":[24],"m":"clc"},{"a":42525,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":42527,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":42529,"t":"code","b":[56],"m":"sec"},{"a":42530,"t":"code","b":[229,109],"m":"sbc","oa":109,"o":"zpa_6D"},{"a":42532,"t":"code","b":[240,26],"m":"beq","oa":42560,"o":"b_A640"},{"a":42534,"t":"code","b":[48,16],"m":"bmi","oa":42552,"o":"b_A638"},{"a":42536,"t":"code","b":[198,90],"m":"dec","oa":90,"o":"zpa_5A"},{"a":42538,"t":"code","b":[56],"m":"sec"},{"a":42539,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":42541,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":42543,"t":"code","b":[133,85],"m":"sta","oa":85,"o":"world_x"},{"a":42545,"t":"code","b":[176,13],"m":"bcs","oa":42560,"o":"b_A640"},{"a":42547,"t":"code","b":[198,86],"m":"dec","oa":86,"o":"zpa_56"},{"a":42549,"t":"code","b":[76,64,166],"m":"jmp","oa":42560,"o":"b_A640"},{"a":42552,"l":"b_A638","t":"code","b":[230,90],"m":"inc","oa":90,"o":"zpa_5A","x":[42534]},{"a":42554,"t":"code","b":[230,85],"m":"inc","oa":85,"o":"world_x"},{"a":42556,"t":"code","b":[208,2],"m":"bne","oa":42560,"o":"b_A640"},{"a":42558,"t":"code","b":[230,86],"m":"inc","oa":86,"o":"zpa_56"},{"a":42560,"l":"b_A640","t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51","x":[42532,42545,42549,42556]},{"a":42562,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42564,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":42566,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42568,"t":"code","b":[160,8],"m":"ldy","o":"#$08"},{"a":42570,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":42573,"t":"code","b":[24],"m":"clc"},{"a":42574,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":42576,"t":"code","b":[101,127],"m":"adc","oa":127,"o":"zpa_7F"},{"a":42578,"t":"code","b":[133,85],"m":"sta","oa":85,"o":"world_x"},{"a":42580,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":42582,"t":"code","b":[101,128],"m":"adc","oa":128,"o":"zpa_80"},{"a":42584,"t":"code","b":[133,86],"m":"sta","oa":86,"o":"zpa_56"},{"a":42586,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":42588,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":42590,"t":"code","b":[240,2],"m":"beq","oa":42594,"o":"b_A662"},{"a":42592,"t":"code","b":[176,24],"m":"bcs","oa":42618,"o":"b_A67A"},{"a":42594,"l":"b_A662","t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x","x":[42590]},{"a":42596,"t":"code","b":[201,208],"m":"cmp","o":"#$D0"},{"a":42598,"t":"code","b":[144,2],"m":"bcc","oa":42602,"o":"b_A66A"},{"a":42600,"t":"code","b":[176,16],"m":"bcs","oa":42618,"o":"b_A67A"},{"a":42602,"l":"b_A66A","t":"code","b":[169,208],"m":"lda","o":"#$D0","x":[42598]},{"a":42604,"t":"code","b":[133,85],"m":"sta","oa":85,"o":"world_x"},{"a":42606,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":42608,"t":"code","b":[133,86],"m":"sta","oa":86,"o":"zpa_56"},{"a":42610,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42612,"t":"code","b":[133,81],"m":"sta","oa":81,"o":"zpa_51"},{"a":42614,"t":"code","b":[133,82],"m":"sta","oa":82,"o":"zpa_52"},{"a":42616,"t":"code","b":[240,32],"m":"beq","oa":42650,"o":"b_A69A"},{"a":42618,"l":"b_A67A","t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56","x":[42592,42600]},{"a":42620,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":42622,"t":"code","b":[240,4],"m":"beq","oa":42628,"o":"b_A684"},{"a":42624,"t":"code","b":[176,10],"m":"bcs","oa":42636,"o":"b_A68C"},{"a":42626,"t":"code","b":[144,22],"m":"bcc","oa":42650,"o":"b_A69A"},{"a":42628,"l":"b_A684","t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x","x":[42622]},{"a":42630,"t":"code","b":[201,208],"m":"cmp","o":"#$D0"},{"a":42632,"t":"code","b":[144,16],"m":"bcc","oa":42650,"o":"b_A69A","x":[32884]},{"a":42634,"t":"code","b":[240,14],"m":"beq","oa":42650,"o":"b_A69A"},{"a":42636,"l":"b_A68C","t":"code","b":[169,208],"m":"lda","o":"#$D0","x":[42624]},{"a":42638,"t":"code","b":[133,85],"m":"sta","oa":85,"o":"world_x"},{"a":42640,"t":"code","b":[169,18],"m":"lda","o":"#$12"},{"a":42642,"t":"code","b":[133,86],"m":"sta","oa":86,"o":"zpa_56"},{"a":42644,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42646,"t":"code","b":[133,81],"m":"sta","oa":81,"o":"zpa_51"},{"a":42648,"t":"code","b":[133,82],"m":"sta","oa":82,"o":"zpa_52"},{"a":42650,"l":"b_A69A","t":"code","b":[165,83],"m":"lda","oa":83,"o":"zpa_53","x":[42616,42626,42632,42634]},{"a":42652,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":42654,"t":"code","b":[165,84],"m":"lda","oa":84,"o":"zpa_54"},{"a":42656,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":42658,"t":"code","b":[160,8],"m":"ldy","o":"#$08"},{"a":42660,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":42663,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":42665,"t":"code","b":[16,16],"m":"bpl","oa":42683,"o":"b_A6BB"},{"a":42667,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":42669,"t":"code","b":[24],"m":"clc"},{"a":42670,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":42672,"t":"code","b":[197,87],"m":"cmp","oa":87,"o":"zpa_57"},{"a":42674,"t":"code","b":[144,7],"m":"bcc","oa":42683,"o":"b_A6BB"},{"a":42676,"t":"code","b":[240,5],"m":"beq","oa":42683,"o":"b_A6BB"},{"a":42678,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42680,"t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57"},{"a":42682,"t":"code","b":[96],"m":"rts"},{"a":42683,"l":"b_A6BB","t":"code","b":[24],"m":"clc","x":[42665,42674,42676]},{"a":42684,"t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":42686,"t":"code","b":[101,127],"m":"adc","oa":127,"o":"zpa_7F"},{"a":42688,"t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57"},{"a":42690,"t":"code","b":[169,112],"m":"lda","o":"#$70"},{"a":42692,"t":"code","b":[197,87],"m":"cmp","oa":87,"o":"zpa_57"},{"a":42694,"t":"code","b":[144,1],"m":"bcc","oa":42697,"o":"b_A6C9"},{"a":42696,"t":"code","b":[96],"m":"rts"},{"a":42697,"l":"b_A6C9","s":"ceiling: altitude pinned at $70 and the vertical velocity killed","t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57","x":[42694]},{"a":42699,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42701,"t":"code","b":[133,83],"m":"sta","oa":83,"o":"zpa_53"},{"a":42703,"t":"code","b":[133,84],"m":"sta","oa":84,"o":"zpa_54"},{"a":42705,"t":"code","b":[96],"m":"rts"},{"a":42706,"l":"clear_cargo_counter","c":"Zeroes $0CFE, the second (diamond) status-bar counter, and redraws it through $A978 with X = 1; preserves the caller's X and Y in $84/$85. Called from $A88D at the end of the helicopter's settle sequence. $0CFE is the counter $A3BA increments and $A3D3 decrements one at a time.","t":"code","b":[134,132],"m":"stx","oa":132,"o":"zpa_84","x":[43149]},{"a":42708,"t":"code","b":[132,133],"m":"sty","oa":133,"o":"zpa_85"},{"a":42710,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":42712,"t":"code","b":[141,254,12],"m":"sta","oa":3326,"o":"a_0CFE"},{"a":42715,"t":"code","b":[162,1],"m":"ldx","o":"#$01"},{"a":42717,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":42720,"t":"code","b":[166,132],"m":"ldx","oa":132,"o":"zpa_84"},{"a":42722,"t":"code","b":[164,133],"m":"ldy","oa":133,"o":"zpa_85"},{"a":42724,"t":"code","b":[96],"m":"rts"},{"a":42725,"l":"add_to_rescue_counter","c":"Adds A, in binary-coded decimal, to $0CFC - the first (spade) status-bar counter - redraws it through $A978 with X = 0, and then plays a four-note rising figure on the effects channel: pitches $18, $2C, $39 and $5B, each held two frames by $A7C7, which busy-waits so they come out as a melody rather than one note. Returns without doing anything at all when A is zero. Preserves the caller's X and Y in $84/$85. Called from exactly one place, $A888, with the value of $0CF1.","t":"code","b":[134,132],"m":"stx","oa":132,"o":"zpa_84","x":[43144]},{"a":42727,"t":"code","b":[132,133],"m":"sty","oa":133,"o":"zpa_85"},{"a":42729,"t":"code","b":[168],"m":"tay"},{"a":42730,"t":"code","b":[240,41],"m":"beq","oa":42773,"o":"b_A715"},{"a":42732,"l":"b_A6EC","t":"code","b":[248],"m":"sed","x":[42744]},{"a":42733,"t":"code","b":[24],"m":"clc"},{"a":42734,"t":"code","b":[173,252,12],"m":"lda","oa":3324,"o":"a_0CFC"},{"a":42737,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":42739,"t":"code","b":[141,252,12],"m":"sta","oa":3324,"o":"a_0CFC"},{"a":42742,"t":"code","b":[216],"m":"cld"},{"a":42743,"t":"code","b":[136],"m":"dey"},{"a":42744,"t":"code","b":[208,242],"m":"bne","oa":42732,"o":"b_A6EC"},{"a":42746,"t":"code","b":[162,0],"m":"ldx","o":"#$00"},{"a":42748,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":42751,"t":"code","b":[162,24],"m":"ldx","o":"#$18"},{"a":42753,"t":"code","b":[160,2],"m":"ldy","o":"#$02"},{"a":42755,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":42758,"t":"code","b":[162,44],"m":"ldx","o":"#$2C"},{"a":42760,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":42763,"t":"code","b":[162,57],"m":"ldx","o":"#$39"},{"a":42765,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":42768,"t":"code","b":[162,91],"m":"ldx","o":"#$5B"},{"a":42770,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":42773,"l":"b_A715","t":"code","b":[166,132],"m":"ldx","oa":132,"o":"zpa_84","x":[42730]},{"a":42775,"t":"code","b":[164,133],"m":"ldy","oa":133,"o":"zpa_85"},{"a":42777,"t":"code","b":[96],"m":"rts"},{"a":42778,"l":"read_stick_updown","c":"Reads the up and down bits of joystick port 1 and leaves a climb-rate index in $5C; called once a frame from $969C. $DC01 masked to two bits gives 3 centred, 2 up, 1 down, 0 both (the lines are active low), and $A73D maps those to $0A, $0F, $05 and $00. Centred while the helicopter is on the ground ($5D clear) is rewritten as 'down', which is how a parked machine is held against the ground. If the helicopter has been hit ($61 or $63 non-zero) the index is overridden with 2, and $A4B7 turns that into a forced descent of -8.","t":"code","b":[173,1,220],"m":"lda","oa":56321,"o":"$DC01","x":[38556]},{"a":42781,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":42783,"t":"code","b":[170],"m":"tax"},{"a":42784,"t":"code","b":[224,3],"m":"cpx","o":"#$03"},{"a":42786,"t":"code","b":[208,6],"m":"bne","oa":42794,"o":"b_A72A"},{"a":42788,"t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up"},{"a":42790,"t":"code","b":[208,2],"m":"bne","oa":42794,"o":"b_A72A"},{"a":42792,"t":"code","b":[162,1],"m":"ldx","o":"#$01"},{"a":42794,"l":"b_A72A","t":"code","b":[189,61,167],"m":"lda","oa":42813,"o":"climb_index_table,x","x":[42786,42790]},{"a":42797,"t":"code","b":[133,92],"m":"sta","oa":92,"o":"stick_y"},{"a":42799,"t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61"},{"a":42801,"t":"code","b":[208,5],"m":"bne","oa":42808,"o":"b_A738"},{"a":42803,"t":"code","b":[165,99],"m":"lda","oa":99,"o":"sortie_end_delay"},{"a":42805,"t":"code","b":[208,1],"m":"bne","oa":42808,"o":"b_A738"},{"a":42807,"t":"code","b":[96],"m":"rts"},{"a":42808,"l":"b_A738","t":"code","b":[169,2],"m":"lda","o":"#$02","x":[42801,42805]},{"a":42810,"t":"code","b":[133,92],"m":"sta","oa":92,"o":"stick_y"},{"a":42812,"t":"code","b":[96],"m":"rts"},{"a":42813,"l":"climb_index_table","c":"The four climb-rate indices $A71A can store in $5C, selected by the low two bits of $DC01: $00 when up and down are pressed together, $05 for down alone, $0F for up alone, $0A for centred. $A4B7 turns the index into a target vertical velocity.","t":"byte","b":[0,5,15,10],"x":[42794]},{"a":42817,"l":"read_stick_leftright","c":"Reads the left and right bits of joystick port 1 ($DC01 shifted right twice and masked) and stores the bank command in $5B through the table at $A758: +5 for left, -5 for right, 0 for centred or both. Forced to 0 once $63 is set, so the player loses lateral control after the helicopter is finished. Called once a frame from $969F. $5B is the target bank angle - $A615 steps $5A toward it and $A413 turns it into horizontal thrust.","t":"code","b":[173,1,220],"m":"lda","oa":56321,"o":"$DC01","x":[38559]},{"a":42820,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":42821,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":42822,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":42824,"t":"code","b":[170],"m":"tax"},{"a":42825,"t":"code","b":[189,88,167],"m":"lda","oa":42840,"o":"bank_input_table,x"},{"a":42828,"t":"code","b":[133,91],"m":"sta","oa":91,"o":"stick_x"},{"a":42830,"t":"code","b":[165,99],"m":"lda","oa":99,"o":"sortie_end_delay"},{"a":42832,"t":"code","b":[208,1],"m":"bne","oa":42835,"o":"b_A753"},{"a":42834,"t":"code","b":[96],"m":"rts"},{"a":42835,"l":"b_A753","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[42832]},{"a":42837,"t":"code","b":[133,91],"m":"sta","oa":91,"o":"stick_x"},{"a":42839,"t":"code","b":[96],"m":"rts"},{"a":42840,"l":"bank_input_table","c":"The four values $A741 can put in $5B, indexed by the left/right bits of $DC01: $00 both pressed, $FB (-5) right, $05 (+5) left, $00 centred.","t":"byte","b":[0,251,5,0],"x":[42825]},{"a":42844,"l":"install_irq_and_sound","c":"Sets the SID up for the engine and installs the raster interrupt; called once from $95A2 before play begins. SID: master volume 15, filter off ($D418 = $0F, and $D417 is never written). Voice 2 gets the frequency register $041A, which sets how fast its noise generator is clocked, and a percussive envelope of attack 4, decay 2, sustain 1, release 0 ($D407, $D408, $D40C, $D40D); the raster handler re-gates it at $9A50 whenever the counter $95 runs out, reloading $95 from $94, which is started here at $11 - so voice 2 is the rotor chop and $94 is its period in frames. Voice 1 gets frequency high byte $01 and sustain 3, release 0 ($D401, $D406); its low byte is the sliding value $0B5E, started here at $30, which $996B walks between $30 and $C0 in steps of $10 - upward while the helicopter is airborne, which also shortens $94 so the chop quickens, and back down on the ground - so voice 1 is a noise rumble sweeping $0130 to $01C0 and $94 falls from $11 toward 8 as the machine climbs (read back live at the ceiling: $0B5E = $C0, $94 = $08). Voice 3 gets sustain 15, release 0 ($D414) and is then left for the sound effects $A7C7 fires. No waveform or gate register is written here: $9977 gates voice 1 with $81 and $9A57 re-gates voice 2 with $81, both of which select noise, while $9A44 gates voice 3 with $11, which selects triangle. Interrupts: both CIA interrupt masks are cleared ($7F to $DC0D and $DD0D, then both registers read to drop anything pending), the VIC raster interrupt is enabled ($01 to $D01A), the raster high bit in $D011 is cleared, the first compare line is set to $1E, $0314/$0315 are pointed at the handler $99F2 and interrupts are let in with cli.","t":"code","b":[169,15],"m":"lda","o":"#$0F","x":[38306]},{"a":42846,"t":"code","b":[141,24,212],"m":"sta","oa":54296,"o":"$D418"},{"a":42849,"t":"code","b":[169,26],"m":"lda","o":"#$1A"},{"a":42851,"t":"code","b":[141,7,212],"m":"sta","oa":54279,"o":"$D407"},{"a":42854,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":42856,"t":"code","b":[141,8,212],"m":"sta","oa":54280,"o":"$D408"},{"a":42859,"t":"code","b":[169,66],"m":"lda","o":"#$42"},{"a":42861,"t":"code","b":[141,12,212],"m":"sta","oa":54284,"o":"$D40C"},{"a":42864,"t":"code","b":[169,16],"m":"lda","o":"#$10"},{"a":42866,"t":"code","b":[141,13,212],"m":"sta","oa":54285,"o":"$D40D"},{"a":42869,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":42871,"t":"code","b":[141,1,212],"m":"sta","oa":54273,"o":"$D401"},{"a":42874,"t":"code","b":[169,48],"m":"lda","o":"#$30"},{"a":42876,"t":"code","b":[141,6,212],"m":"sta","oa":54278,"o":"$D406"},{"a":42879,"t":"code","b":[169,48],"m":"lda","o":"#$30"},{"a":42881,"t":"code","b":[141,94,11],"m":"sta","oa":2910,"o":"a_0B5E"},{"a":42884,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":42886,"t":"code","b":[133,148],"m":"sta","oa":148,"o":"zpa_94"},{"a":42888,"t":"code","b":[169,240],"m":"lda","o":"#$F0"},{"a":42890,"t":"code","b":[141,20,212],"m":"sta","oa":54292,"o":"$D414"},{"a":42893,"t":"code","b":[120],"m":"sei"},{"a":42894,"t":"code","b":[169,127],"m":"lda","o":"#$7F"},{"a":42896,"t":"code","b":[141,13,220],"m":"sta","oa":56333,"o":"$DC0D"},{"a":42899,"t":"code","b":[141,13,221],"m":"sta","oa":56589,"o":"$DD0D"},{"a":42902,"t":"code","b":[173,13,220],"m":"lda","oa":56333,"o":"$DC0D"},{"a":42905,"t":"code","b":[173,13,221],"m":"lda","oa":56589,"o":"$DD0D"},{"a":42908,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":42910,"t":"code","b":[141,26,208],"m":"sta","oa":53274,"o":"$D01A"},{"a":42913,"t":"code","b":[173,17,208],"m":"lda","oa":53265,"o":"$D011"},{"a":42916,"t":"code","b":[41,127],"m":"and","o":"#$7F"},{"a":42918,"t":"code","b":[141,17,208],"m":"sta","oa":53265,"o":"$D011"},{"a":42921,"t":"code","b":[169,30],"m":"lda","o":"#$1E"},{"a":42923,"t":"code","b":[141,18,208],"m":"sta","oa":53266,"o":"$D012"},{"a":42926,"t":"code","b":[169,242],"m":"lda","o":"#$F2"},{"a":42928,"t":"code","b":[141,20,3],"m":"sta","oa":788,"o":"irq_vec_lo"},{"a":42931,"t":"code","b":[169,153],"m":"lda","o":"#$99"},{"a":42933,"t":"code","b":[141,21,3],"m":"sta","oa":789,"o":"a_0315"},{"a":42936,"t":"code","b":[88],"m":"cli"},{"a":42937,"t":"code","b":[96],"m":"rts"},{"a":42938,"l":"sound_enabled","c":"Decides whether a sound may be started: returns carry clear (go ahead) only when bit 7 of $8C is set - the flag $95AD sets when play starts and $96F4 clears - and the helicopter's settle counter $62 is not exactly 6. Carry set means stay silent. Used by $A7C7 before every effect and by the engine-sound update $996B.","t":"code","b":[56],"m":"sec","x":[39275,42951]},{"a":42939,"t":"code","b":[36,140],"m":"bit","oa":140,"o":"status_bar_on"},{"a":42941,"t":"code","b":[16,7],"m":"bpl","oa":42950,"o":"r_A7C6"},{"a":42943,"t":"code","b":[165,98],"m":"lda","oa":98,"o":"zpa_62"},{"a":42945,"t":"code","b":[201,6],"m":"cmp","o":"#$06"},{"a":42947,"t":"code","b":[240,1],"m":"beq","oa":42950,"o":"r_A7C6"},{"a":42949,"t":"code","b":[24],"m":"clc"},{"a":42950,"l":"r_A7C6","t":"code","b":[96],"m":"rts","x":[42941,42947]},{"a":42951,"l":"play_sfx","c":"Starts one sound effect on SID voice 3, which the raster handler gates with $11, a triangle. X is the frequency high byte, written straight to $D40F ($D40E is never written, so the low byte stays 0); Y is the length in frames, latched in $98, which $9A37 counts down before gating the voice off. If an effect is still sounding the routine loops here until $98 reaches zero, so consecutive calls come out as a tune instead of overwriting each other. Returns at once without touching the SID when $A7BA says sound is off. Callers pass the pitch in X: $3A for the gun ($97ED), $2B then $40 for a death ($A400), $18/$2C/$39/$5B for the four-note figure at $A6FF, $78 from the tank code at $B88D.","t":"code","b":[32,186,167],"m":"jsr","oa":42938,"o":"sound_enabled","x":[38407,38412,38417,38893,40247,40252,40258,41988,41995,42755,42760,42765,42770,42958,45295,45300,45305,46963,47245]},{"a":42954,"t":"code","b":[176,9],"m":"bcs","oa":42965,"o":"r_A7D5"},{"a":42956,"t":"code","b":[165,152],"m":"lda","oa":152,"o":"zpa_98"},{"a":42958,"t":"code","b":[208,247],"m":"bne","oa":42951,"o":"play_sfx"},{"a":42960,"t":"code","b":[132,152],"m":"sty","oa":152,"o":"zpa_98"},{"a":42962,"t":"code","b":[142,15,212],"m":"stx","oa":54287,"o":"$D40F"},{"a":42965,"l":"r_A7D5","t":"code","b":[96],"m":"rts","x":[42954]},{"a":42966,"l":"heli_after_move","c":"Runs after the flight model each frame and settles everything that depends on where the helicopter ended up; reached as a tail call from $A4D7. First it compares the altitude $57 with the minimum ground clearance for the current bank angle - $9471 indexed by 2*(signed bank + 5), values 7 to 10, the same table $A8B8 uses as the shape's vertical anchor. Above that the machine is airborne: $5D is set, the 'stopped' and 'over the base' flags $5E and $5F are cleared and the routine returns. At or below it the altitude is clamped up to the minimum, $5D is cleared and the routine goes on. (A negative $57, which only the hard-landing path at $A50B can produce, is treated as airborne too.) Grounded, $5F is set when the world X $55/$56 lies in the base window $1261 to $1293 - the helicopter starts each sortie at $1273, in the middle of it. Then the settle counter: if $62 is already running control goes to $A875; else if $61 is set - the helicopter has been hit or reached - the counter is started at $A8A3 with $61 = $62 = 1; else the horizontal velocity decides, $5E being set at $A8AA when the machine is stopped and level and the counter being started when the speed is still at the clamped maximum of exactly +/-$1500 on touchdown. Flying at full speed in the air never reaches this test, because the airborne branch has already returned.","t":"code","b":[36,87],"m":"bit","oa":87,"o":"zpa_57","x":[42199]},{"a":42968,"t":"code","b":[48,33],"m":"bmi","oa":43003,"o":"b_A7FB"},{"a":42970,"t":"code","b":[16,0],"m":"bpl","oa":42972,"o":"b_A7DC"},{"a":42972,"l":"b_A7DC","t":"code","b":[165,96],"m":"lda","oa":96,"o":"zpa_60","x":[42970]},{"a":42974,"t":"code","b":[240,3],"m":"beq","oa":42979,"o":"b_A7E3"},{"a":42976,"t":"code","b":[76,10,168],"m":"jmp","oa":43018,"o":"j_A80A"},{"a":42979,"l":"b_A7E3","t":"code","b":[24],"m":"clc","x":[42974]},{"a":42980,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":42982,"t":"code","b":[166,89],"m":"ldx","oa":89,"o":"heli_facing"},{"a":42984,"t":"code","b":[16,3],"m":"bpl","oa":42989,"o":"b_A7ED"},{"a":42986,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":42988,"t":"code","b":[56],"m":"sec"},{"a":42989,"l":"b_A7ED","t":"code","b":[105,5],"m":"adc","o":"#$05","x":[42984]},{"a":42991,"t":"code","b":[10],"m":"asl","o":"a"},{"a":42992,"t":"code","b":[170],"m":"tax"},{"a":42993,"t":"code","b":[56],"m":"sec"},{"a":42994,"t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":42996,"t":"code","b":[253,113,148],"m":"sbc","oa":38001,"o":"tilt_anchor_y,x"},{"a":42999,"t":"code","b":[48,12],"m":"bmi","oa":43013,"o":"b_A805"},{"a":43001,"t":"code","b":[240,15],"m":"beq","oa":43018,"o":"j_A80A"},{"a":43003,"l":"b_A7FB","s":"airborne: $5D set, and the 'stopped' and 'over the base' flags dropped","t":"code","b":[162,1],"m":"ldx","o":"#$01","x":[42968]},{"a":43005,"t":"code","b":[134,93],"m":"stx","oa":93,"o":"rotor_up"},{"a":43007,"t":"code","b":[202],"m":"dex"},{"a":43008,"t":"code","b":[134,94],"m":"stx","oa":94,"o":"zpa_5E"},{"a":43010,"t":"code","b":[134,95],"m":"stx","oa":95,"o":"zpa_5F"},{"a":43012,"t":"code","b":[96],"m":"rts"},{"a":43013,"l":"b_A805","t":"code","b":[189,113,148],"m":"lda","oa":38001,"o":"tilt_anchor_y,x","x":[42999]},{"a":43016,"t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57"},{"a":43018,"l":"j_A80A","s":"on the ground: $5D cleared, then the base window test for $5F","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[42976,43001]},{"a":43020,"t":"code","b":[133,93],"m":"sta","oa":93,"o":"rotor_up"},{"a":43022,"t":"code","b":[56],"m":"sec"},{"a":43023,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":43025,"t":"code","b":[233,84],"m":"sbc","o":"#$54"},{"a":43027,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":43029,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":43031,"t":"code","b":[233,18],"m":"sbc","o":"#$12"},{"a":43033,"t":"code","b":[208,16],"m":"bne","oa":43051,"o":"b_A82B"},{"a":43035,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":43037,"t":"code","b":[48,12],"m":"bmi","oa":43051,"o":"b_A82B"},{"a":43039,"t":"code","b":[201,64],"m":"cmp","o":"#$40"},{"a":43041,"t":"code","b":[176,8],"m":"bcs","oa":43051,"o":"b_A82B"},{"a":43043,"t":"code","b":[201,13],"m":"cmp","o":"#$0D"},{"a":43045,"t":"code","b":[144,4],"m":"bcc","oa":43051,"o":"b_A82B"},{"a":43047,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":43049,"t":"code","b":[133,95],"m":"sta","oa":95,"o":"zpa_5F"},{"a":43051,"l":"b_A82B","t":"code","b":[165,98],"m":"lda","oa":98,"o":"zpa_62","x":[43033,43037,43041,43045]},{"a":43053,"t":"code","b":[240,3],"m":"beq","oa":43058,"o":"b_A832"},{"a":43055,"t":"code","b":[76,117,168],"m":"jmp","oa":43125,"o":"heli_settle_counter"},{"a":43058,"l":"b_A832","t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61","x":[43053]},{"a":43060,"t":"code","b":[240,3],"m":"beq","oa":43065,"o":"b_A839"},{"a":43062,"t":"code","b":[76,163,168],"m":"jmp","oa":43171,"o":"j_A8A3"},{"a":43065,"l":"b_A839","t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52","x":[43060]},{"a":43067,"t":"code","b":[48,11],"m":"bmi","oa":43080,"o":"b_A848"},{"a":43069,"t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51"},{"a":43071,"t":"code","b":[208,18],"m":"bne","oa":43091,"o":"b_A853"},{"a":43073,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":43075,"t":"code","b":[208,14],"m":"bne","oa":43091,"o":"b_A853"},{"a":43077,"t":"code","b":[76,170,168],"m":"jmp","oa":43178,"o":"j_A8AA"},{"a":43080,"l":"b_A848","t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51","x":[43067]},{"a":43082,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43084,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":43086,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43088,"t":"code","b":[76,100,168],"m":"jmp","oa":43108,"o":"j_A864"},{"a":43091,"l":"b_A853","t":"code","b":[24],"m":"clc","x":[43071,43075]},{"a":43092,"t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51"},{"a":43094,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43096,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":43098,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43100,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":43102,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43104,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":43106,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43108,"l":"j_A864","t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80","x":[43088]},{"a":43110,"t":"code","b":[201,235],"m":"cmp","o":"#$EB"},{"a":43112,"t":"code","b":[144,57],"m":"bcc","oa":43171,"o":"j_A8A3"},{"a":43114,"t":"code","b":[208,62],"m":"bne","oa":43178,"o":"j_A8AA"},{"a":43116,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":43118,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":43120,"t":"code","b":[144,49],"m":"bcc","oa":43171,"o":"j_A8A3"},{"a":43122,"t":"code","b":[76,170,168],"m":"jmp","oa":43178,"o":"j_A8AA"},{"a":43125,"l":"heli_settle_counter","c":"Runs once a frame while the settle counter $62 is counting from 1 to 6. Below 6 it only increments; meanwhile $AFE5 subtracts $62 from the drawn altitude so the helicopter visibly sinks, $ABB2 hands it to $8BAF, which leaves it in $25 for the blitter, and $AC1B and $AC7B freeze both rotors. On the frame it reaches 6 the payoff fires once, guarded by $63: $63 is set, which takes lateral control away at $A74E, forces a descent at $A733 and starts the roughly 43-frame countdown at $968E that ends the sortie; $0CF1 is added in binary-coded decimal to the spade counter $0CFC by $A6E5, with its four-note figure, and to the running total $0CEF; $0CF1 is then zeroed and the diamond counter $0CFE cleared by $A6D2. $61, the flag that starts all this, is set in two places: $A8A3 just below, and $B5AF, which the collision code reaches when something comes within about twelve world units of the helicopter while it is on the ground.","t":"code","b":[165,98],"m":"lda","oa":98,"o":"zpa_62","x":[43055]},{"a":43127,"t":"code","b":[201,6],"m":"cmp","o":"#$06"},{"a":43129,"t":"code","b":[144,37],"m":"bcc","oa":43168,"o":"b_A8A0"},{"a":43131,"t":"code","b":[165,99],"m":"lda","oa":99,"o":"sortie_end_delay"},{"a":43133,"t":"code","b":[208,32],"m":"bne","oa":43167,"o":"r_A89F"},{"a":43135,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":43137,"t":"code","b":[133,99],"m":"sta","oa":99,"o":"sortie_end_delay"},{"a":43139,"t":"code","b":[198,98],"m":"dec","oa":98,"o":"zpa_62"},{"a":43141,"t":"code","b":[173,241,12],"m":"lda","oa":3313,"o":"a_0CF1"},{"a":43144,"t":"code","b":[32,229,166],"m":"jsr","oa":42725,"o":"add_to_rescue_counter"},{"a":43147,"t":"code","b":[230,98],"m":"inc","oa":98,"o":"zpa_62"},{"a":43149,"t":"code","b":[32,210,166],"m":"jsr","oa":42706,"o":"clear_cargo_counter"},{"a":43152,"t":"code","b":[24],"m":"clc"},{"a":43153,"t":"code","b":[173,241,12],"m":"lda","oa":3313,"o":"a_0CF1"},{"a":43156,"t":"code","b":[109,239,12],"m":"adc","oa":3311,"o":"hostages_lost"},{"a":43159,"t":"code","b":[141,239,12],"m":"sta","oa":3311,"o":"hostages_lost"},{"a":43162,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43164,"t":"code","b":[141,241,12],"m":"sta","oa":3313,"o":"a_0CF1"},{"a":43167,"l":"r_A89F","t":"code","b":[96],"m":"rts","x":[43133]},{"a":43168,"l":"b_A8A0","t":"code","b":[230,98],"m":"inc","oa":98,"o":"zpa_62","x":[43129]},{"a":43170,"t":"code","b":[96],"m":"rts"},{"a":43171,"l":"j_A8A3","s":"start the settle counter: $61 and $62 both to 1 - reached from $A832 when the helicopter has been hit, or on touchdown at exactly full horizontal speed","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[43062,43112,43120]},{"a":43173,"t":"code","b":[133,98],"m":"sta","oa":98,"o":"zpa_62"},{"a":43175,"t":"code","b":[133,97],"m":"sta","oa":97,"o":"zpa_61"},{"a":43177,"t":"code","b":[96],"m":"rts"},{"a":43178,"l":"j_A8AA","s":"$5E = 1 only when the helicopter is stopped and level, which is the condition the rest of the game tests for 'parked'","t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A","x":[43077,43114,43122]},{"a":43180,"t":"code","b":[240,5],"m":"beq","oa":43187,"o":"b_A8B3"},{"a":43182,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43184,"t":"code","b":[133,94],"m":"sta","oa":94,"o":"zpa_5E"},{"a":43186,"t":"code","b":[96],"m":"rts"},{"a":43187,"l":"b_A8B3","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[43180]},{"a":43189,"t":"code","b":[133,94],"m":"sta","oa":94,"o":"zpa_5E"},{"a":43191,"t":"code","b":[96],"m":"rts"},{"a":43192,"l":"heli_set_bank","c":"Applies a new bank angle to the helicopter; entered as a tail call from $A5B9 with the angle in A, and also stores it in $0B5F. The eleven side-view frames (shapes 0 to 10) are not drawn about a common centre, so the world position is corrected as the frame changes: the X anchor table $945B, read as words at 2*(bank+5) and giving +6,+5,+3,+2,0,0,-1,-2,-4,-5,-7 for bank -5 to +5, and the Y anchor table $9471, giving 7 to 10, are each differenced between the new angle and the old one and added to $55/$56 and $57, so the picture does not jump when the frame changes. Both offsets are mirrored when the helicopter faces left. $5A is then set to the new angle.","t":"code","b":[141,95,11],"m":"sta","oa":2911,"o":"a_0B5F","x":[42427]},{"a":43195,"t":"code","b":[170],"m":"tax"},{"a":43196,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":43198,"t":"code","b":[168],"m":"tay"},{"a":43199,"t":"code","b":[36,89],"m":"bit","oa":89,"o":"heli_facing"},{"a":43201,"t":"code","b":[16,10],"m":"bpl","oa":43213,"o":"b_A8CD"},{"a":43203,"t":"code","b":[138],"m":"txa"},{"a":43204,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43206,"t":"code","b":[170],"m":"tax"},{"a":43207,"t":"code","b":[232],"m":"inx"},{"a":43208,"t":"code","b":[152],"m":"tya"},{"a":43209,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43211,"t":"code","b":[168],"m":"tay"},{"a":43212,"t":"code","b":[200],"m":"iny"},{"a":43213,"l":"b_A8CD","t":"code","b":[138],"m":"txa","x":[43201]},{"a":43214,"t":"code","b":[24],"m":"clc"},{"a":43215,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":43217,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43218,"t":"code","b":[170],"m":"tax"},{"a":43219,"t":"code","b":[152],"m":"tya"},{"a":43220,"t":"code","b":[24],"m":"clc"},{"a":43221,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":43223,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43224,"t":"code","b":[168],"m":"tay"},{"a":43225,"t":"code","b":[56],"m":"sec"},{"a":43226,"t":"code","b":[189,91,148],"m":"lda","oa":37979,"o":"tilt_anchor_x,x"},{"a":43229,"t":"code","b":[249,91,148],"m":"sbc","oa":37979,"o":"tilt_anchor_x,y"},{"a":43232,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43234,"t":"code","b":[189,92,148],"m":"lda","oa":37980,"o":"tilt_anchor_x_hi,x"},{"a":43237,"t":"code","b":[249,92,148],"m":"sbc","oa":37980,"o":"tilt_anchor_x_hi,y"},{"a":43240,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43242,"t":"code","b":[36,89],"m":"bit","oa":89,"o":"heli_facing"},{"a":43244,"t":"code","b":[16,18],"m":"bpl","oa":43264,"o":"b_A900"},{"a":43246,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":43248,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43250,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43252,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":43254,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43256,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43258,"t":"code","b":[230,127],"m":"inc","oa":127,"o":"zpa_7F"},{"a":43260,"t":"code","b":[208,2],"m":"bne","oa":43264,"o":"b_A900"},{"a":43262,"t":"code","b":[230,128],"m":"inc","oa":128,"o":"zpa_80"},{"a":43264,"l":"b_A900","t":"code","b":[24],"m":"clc","x":[43244,43260]},{"a":43265,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":43267,"t":"code","b":[101,127],"m":"adc","oa":127,"o":"zpa_7F"},{"a":43269,"t":"code","b":[133,85],"m":"sta","oa":85,"o":"world_x"},{"a":43271,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":43273,"t":"code","b":[101,128],"m":"adc","oa":128,"o":"zpa_80"},{"a":43275,"t":"code","b":[133,86],"m":"sta","oa":86,"o":"zpa_56"},{"a":43277,"t":"code","b":[56],"m":"sec"},{"a":43278,"t":"code","b":[189,113,148],"m":"lda","oa":38001,"o":"tilt_anchor_y,x"},{"a":43281,"t":"code","b":[249,113,148],"m":"sbc","oa":38001,"o":"tilt_anchor_y,y"},{"a":43284,"t":"code","b":[24],"m":"clc"},{"a":43285,"t":"code","b":[101,87],"m":"adc","oa":87,"o":"zpa_57"},{"a":43287,"t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57"},{"a":43289,"t":"code","b":[24],"m":"clc"},{"a":43290,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":43292,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":43294,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":43296,"t":"code","b":[24],"m":"clc"},{"a":43297,"t":"code","b":[173,95,11],"m":"lda","oa":2911,"o":"a_0B5F"},{"a":43300,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":43302,"t":"code","b":[56],"m":"sec"},{"a":43303,"t":"code","b":[229,109],"m":"sbc","oa":109,"o":"zpa_6D"},{"a":43305,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":43307,"t":"code","b":[24],"m":"clc"},{"a":43308,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":43310,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":43312,"t":"code","b":[133,90],"m":"sta","oa":90,"o":"zpa_5A"},{"a":43314,"t":"code","b":[96],"m":"rts"},{"a":43315,"l":"random_byte","c":"Returns a pseudo-random byte in A: the low byte of CIA1's free-running timer A, $DC04. This and the identical read at $9239 are the game's only source of randomness; callers include the hostage placement loop at $BE9E, the tank's decision at $B837 and the wreck shape choice at $B059.","t":"code","b":[173,4,220],"m":"lda","oa":56324,"o":"$DC04","x":[39958,40005,40546,40636,40682,40693,40756,40809,40914,40956,41091,41377,41435,41454,41477,41843,45145,45217,47159,48798]},{"a":43318,"t":"code","b":[96],"m":"rts"},{"a":43319,"l":"actor_free","c":"Takes the actor in $72 off the active list and pushes it onto the free list. $0B7C,x is the backward link and $0B7D,x the forward one: the two neighbours are joined to each other, then the slot's forward link is made to point at the old free-list head $74 and $74 is set to the slot. Called with jsr from every actor that removes itself and from the collision code at $B3E1. Confirmed live: firing six shots produced six $A951 hits and five $A937 hits as the shots expired.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[41326,44930,45419,45537,46049,46121,46503,47027]},{"a":43321,"t":"code","b":[189,124,11],"m":"lda","oa":2940,"o":"actor_prev,x"},{"a":43324,"t":"code","b":[188,125,11],"m":"ldy","oa":2941,"o":"actor_next,x"},{"a":43327,"t":"code","b":[170],"m":"tax"},{"a":43328,"t":"code","b":[153,124,11],"m":"sta","oa":2940,"o":"actor_prev,y"},{"a":43331,"t":"code","b":[152],"m":"tya"},{"a":43332,"t":"code","b":[157,125,11],"m":"sta","oa":2941,"o":"actor_next,x"},{"a":43335,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":43337,"t":"code","b":[165,116],"m":"lda","oa":116,"o":"free_slot_head"},{"a":43339,"t":"code","b":[157,125,11],"m":"sta","oa":2941,"o":"actor_next,x"},{"a":43342,"t":"code","b":[134,116],"m":"stx","oa":116,"o":"free_slot_head"},{"a":43344,"t":"code","b":[96],"m":"rts"},{"a":43345,"l":"actor_alloc","c":"Takes the first slot off the free list: $72 = $74, then $74 = $0B7D of that slot. There is no empty check - the game relies on the 28 spare records $A9E1 chains never running out, and on the caps that limit each actor kind (at most five shots, for instance, enforced at $97E1). The caller then fills in the ten-byte record at $0B74 plus the slot and calls $A95B to put it on the active list.","t":"code","b":[166,116],"m":"ldx","oa":116,"o":"free_slot_head","x":[40734,40870,41040,41673,45071,45197,46718,46723,46834,47173]},{"a":43347,"t":"code","b":[134,114],"m":"stx","oa":114,"o":"actor_slot"},{"a":43349,"t":"code","b":[189,125,11],"m":"lda","oa":2941,"o":"actor_next,x"},{"a":43352,"t":"code","b":[133,116],"m":"sta","oa":116,"o":"free_slot_head"},{"a":43354,"t":"code","b":[96],"m":"rts"},{"a":43355,"l":"actor_link","c":"Appends the slot in $72 to the end of the active actor list. The absolute cell $0B7C holds the index of the current last slot: the new slot becomes its forward link ($0B7D), $0B7C is updated to the new slot, the new slot's backward link is set to the old tail and its forward link to zero. If $73 - the slot $B307 means to visit next - is zero, it is pointed at the new slot, so an actor created part-way through the walk is still run this frame.","t":"code","b":[174,124,11],"m":"ldx","oa":2940,"o":"actor_prev","x":[40854,41008,41133,41798,45131,45259,46812,46820,46900,47233]},{"a":43358,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":43360,"t":"code","b":[157,125,11],"m":"sta","oa":2941,"o":"actor_next,x"},{"a":43363,"t":"code","b":[141,124,11],"m":"sta","oa":2940,"o":"actor_prev"},{"a":43366,"t":"code","b":[138],"m":"txa"},{"a":43367,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":43369,"t":"code","b":[157,124,11],"m":"sta","oa":2940,"o":"actor_prev,x"},{"a":43372,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43374,"t":"code","b":[157,125,11],"m":"sta","oa":2941,"o":"actor_next,x"},{"a":43377,"t":"code","b":[165,115],"m":"lda","oa":115,"o":"zpa_73"},{"a":43379,"t":"code","b":[208,2],"m":"bne","oa":43383,"o":"r_A977"},{"a":43381,"t":"code","b":[134,115],"m":"stx","oa":115,"o":"zpa_73"},{"a":43383,"l":"r_A977","t":"code","b":[96],"m":"rts","x":[43379]},{"a":43384,"l":"draw_bcd_counter","c":"Redraws one two-digit status-bar counter. A holds the packed BCD value and X the counter number 0 to 2; $A99D gives the screen offset of the units digit. Both text matrices are written, $0450,y and $4450,y, because the top bar is double-buffered along with the bitmap, and each nibble is turned into a screen code by adding $30. Does nothing at all while bit 7 of $8C is clear, which is how the bar stays blank outside play.","t":"code","b":[36,140],"m":"bit","oa":140,"o":"status_bar_on","x":[41931,41956,41981,42717,42748,45283,47996,48001,48007]},{"a":43386,"t":"code","b":[16,32],"m":"bpl","oa":43420,"o":"r_A99C"},{"a":43388,"t":"code","b":[188,157,169],"m":"ldy","oa":43421,"o":"counter_screen_offsets,x"},{"a":43391,"t":"code","b":[72],"m":"pha"},{"a":43392,"t":"code","b":[41,15],"m":"and","o":"#$0F"},{"a":43394,"t":"code","b":[24],"m":"clc"},{"a":43395,"t":"code","b":[105,48],"m":"adc","o":"#$30"},{"a":43397,"t":"code","b":[153,80,4],"m":"sta","oa":1104,"o":"f_0450,y"},{"a":43400,"t":"code","b":[153,80,68],"m":"sta","oa":17488,"o":"f_4450,y"},{"a":43403,"t":"code","b":[136],"m":"dey"},{"a":43404,"t":"code","b":[104],"m":"pla"},{"a":43405,"t":"code","b":[41,240],"m":"and","o":"#$F0"},{"a":43407,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43408,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43409,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43410,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43411,"t":"code","b":[24],"m":"clc"},{"a":43412,"t":"code","b":[105,48],"m":"adc","o":"#$30"},{"a":43414,"t":"code","b":[153,80,4],"m":"sta","oa":1104,"o":"f_0450,y"},{"a":43417,"t":"code","b":[153,80,68],"m":"sta","oa":17488,"o":"f_4450,y"},{"a":43420,"l":"r_A99C","t":"code","b":[96],"m":"rts","x":[43386]},{"a":43421,"l":"counter_screen_offsets","c":"Screen offsets, counted from $0450 (text row 2, column 0), of the units digit of the three status-bar counters: $0A for the spade counter $0CFC, $15 for the diamond counter $0CFE and $20 for the heart counter $0CFD. $A978 writes the units digit there and the tens digit one cell to its left; $BB2B stamps the spade, diamond and heart symbols one cell further left again, at $0458, $0463 and $046E.","t":"byte","b":[10,21,32],"x":[43388]},{"a":43424,"l":"shape_dest_from_actor","c":"Works out where a shape is to be drawn for the actor whose slot is in $72, and is the step every shape goes through before $8BF9. X is half the shape's width and Y half its height plus whatever extra vertical offset the caller wants. The destination comes back in $67/$68 - the 16-bit world X of the shape's left edge, the actor's world X $0B78/$0B79 minus X with X sign-extended - and $69, the row, which is the actor's field +6 ($0B7A) plus its field +7 ($0B7B) plus Y and is counted upward from the bottom of the play area, 0 at the bottom and $A7 at the top. A non-zero A asks for multicolour alignment: $67 is stepped on by one when ($67 xor the camera X $75) is odd, so the shape lands on a whole two-bit pixel. The caller then hands $0067 to $8BF9 and the shape pointer to $8BE0 before calling $8F03.","t":"code","b":[134,123],"m":"stx","oa":123,"o":"off_x","x":[41153,41200,41258,43936,44044,44200,44522,45052,45180,45366,45428,45549,45606,45681,46920]},{"a":43426,"t":"code","b":[132,124],"m":"sty","oa":124,"o":"zpa_7C"},{"a":43428,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":43430,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":43432,"t":"code","b":[56],"m":"sec"},{"a":43433,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":43436,"t":"code","b":[229,123],"m":"sbc","oa":123,"o":"off_x"},{"a":43438,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":43440,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":43443,"t":"code","b":[36,123],"m":"bit","oa":123,"o":"off_x"},{"a":43445,"t":"code","b":[48,7],"m":"bmi","oa":43454,"o":"b_A9BE"},{"a":43447,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":43449,"t":"code","b":[133,104],"m":"sta","oa":104,"o":"zpa_68"},{"a":43451,"t":"code","b":[76,194,169],"m":"jmp","oa":43458,"o":"j_A9C2"},{"a":43454,"l":"b_A9BE","t":"code","b":[233,255],"m":"sbc","o":"#$FF","x":[43445]},{"a":43456,"t":"code","b":[133,104],"m":"sta","oa":104,"o":"zpa_68"},{"a":43458,"l":"j_A9C2","t":"code","b":[24],"m":"clc","x":[43451]},{"a":43459,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":43462,"t":"code","b":[125,123,11],"m":"adc","oa":2939,"o":"actor_base_row,x"},{"a":43465,"t":"code","b":[101,124],"m":"adc","oa":124,"o":"zpa_7C"},{"a":43467,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":43469,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":43471,"t":"code","b":[240,15],"m":"beq","oa":43488,"o":"r_A9E0"},{"a":43473,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43474,"t":"code","b":[69,117],"m":"eor","oa":117,"o":"view_org"},{"a":43476,"t":"code","b":[69,103],"m":"eor","oa":103,"o":"draw_wx"},{"a":43478,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":43480,"t":"code","b":[240,6],"m":"beq","oa":43488,"o":"r_A9E0"},{"a":43482,"t":"code","b":[230,103],"m":"inc","oa":103,"o":"draw_wx"},{"a":43484,"t":"code","b":[208,2],"m":"bne","oa":43488,"o":"r_A9E0"},{"a":43486,"t":"code","b":[230,104],"m":"inc","oa":104,"o":"zpa_68"},{"a":43488,"l":"r_A9E0","t":"code","b":[96],"m":"rts","x":[43471,43480,43484]},{"a":43489,"l":"actor_list_init","c":"Builds the actor system from nothing; called from $BEF1 when a sortie starts. Empties both colour-overlay lists ($9D and $9E) and points $99/$9A and $9B/$9C at their buffers $0D03 and $0DA3. Record 0 at $0B74 is a dummy list head: its forward link ($0B7D read as an absolute address) and the tail cell ($0B7C read the same way) are both set to slot 10, which is filled in as the player - type 0, field +7 = $16, both links zero. Slots 20, 30, ... 290 are then chained through their forward links into the free list headed by $74, which gives 28 spare ten-byte records running up to $0C9F. Finally clears $0CE1, $0CE3 and $0CE8, the counts of the three short index lists.","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[48881]},{"a":43491,"t":"code","b":[133,157],"m":"sta","oa":157,"o":"list_cur_len"},{"a":43493,"t":"code","b":[133,158],"m":"sta","oa":158,"o":"zpa_9E"},{"a":43495,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":43497,"t":"code","b":[133,153],"m":"sta","oa":153,"o":"list_cur"},{"a":43499,"t":"code","b":[169,13],"m":"lda","o":"#$0D"},{"a":43501,"t":"code","b":[133,154],"m":"sta","oa":154,"o":"zpa_9A"},{"a":43503,"t":"code","b":[169,163],"m":"lda","o":"#$A3"},{"a":43505,"t":"code","b":[133,155],"m":"sta","oa":155,"o":"list_prev"},{"a":43507,"t":"code","b":[169,13],"m":"lda","o":"#$0D"},{"a":43509,"t":"code","b":[133,156],"m":"sta","oa":156,"o":"zpa_9C"},{"a":43511,"t":"code","b":[162,10],"m":"ldx","o":"#$0A"},{"a":43513,"t":"code","b":[142,124,11],"m":"stx","oa":2940,"o":"actor_prev"},{"a":43516,"t":"code","b":[142,125,11],"m":"stx","oa":2941,"o":"actor_next"},{"a":43519,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43521,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":43524,"t":"code","b":[169,22],"m":"lda","o":"#$16"},{"a":43526,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":43529,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43531,"t":"code","b":[157,124,11],"m":"sta","oa":2940,"o":"actor_prev,x"},{"a":43534,"t":"code","b":[157,125,11],"m":"sta","oa":2941,"o":"actor_next,x"},{"a":43537,"t":"code","b":[162,20],"m":"ldx","o":"#$14"},{"a":43539,"t":"code","b":[134,116],"m":"stx","oa":116,"o":"free_slot_head"},{"a":43541,"t":"code","b":[160,30],"m":"ldy","o":"#$1E"},{"a":43543,"t":"code","b":[136],"m":"dey"},{"a":43544,"t":"code","b":[136],"m":"dey"},{"a":43545,"l":"j_AA19","t":"code","b":[136],"m":"dey","x":[43556]},{"a":43546,"t":"code","b":[240,11],"m":"beq","oa":43559,"o":"b_AA27"},{"a":43548,"t":"code","b":[138],"m":"txa"},{"a":43549,"t":"code","b":[24],"m":"clc"},{"a":43550,"t":"code","b":[105,10],"m":"adc","o":"#$0A"},{"a":43552,"t":"code","b":[157,125,11],"m":"sta","oa":2941,"o":"actor_next,x"},{"a":43555,"t":"code","b":[170],"m":"tax"},{"a":43556,"t":"code","b":[76,25,170],"m":"jmp","oa":43545,"o":"j_AA19"},{"a":43559,"l":"b_AA27","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[43546]},{"a":43561,"t":"code","b":[157,125,11],"m":"sta","oa":2941,"o":"actor_next,x"},{"a":43564,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43566,"t":"code","b":[141,225,12],"m":"sta","oa":3297,"o":"a_0CE1"},{"a":43569,"t":"code","b":[141,227,12],"m":"sta","oa":3299,"o":"hit_list_len"},{"a":43572,"t":"code","b":[141,232,12],"m":"sta","oa":3304,"o":"board_list_len"},{"a":43575,"t":"code","b":[96],"m":"rts"},{"a":43576,"l":"queue_colour_stripe","c":"Appends one record to this frame's colour-overlay list, which $BBE6 and $BC05 replay once the bitmap is finished to paint colour RAM. A is the stripe class, which $BC1D turns into a width and a height through the table at $94AF. Four bytes go to ($99),$9D: the class, then the screen X as a 16-bit value ($67/$68 minus the camera $75/$76), then the row $69; $9D is advanced by four. Every shape that wants colour calls this next to its blit - the helicopter with class 0, the hills with class 1, the jet with class 7 plus $9487[8*state + frame shape].","t":"code","b":[133,113],"m":"sta","oa":113,"o":"ent_kind","x":[40454,41173,41220,41273,43695,44580,45057,45392,45448,45569,45626,45701,46940,47397,47661,47755,47809,47864]},{"a":43578,"t":"code","b":[56],"m":"sec"},{"a":43579,"t":"code","b":[165,103],"m":"lda","oa":103,"o":"draw_wx"},{"a":43581,"t":"code","b":[229,117],"m":"sbc","oa":117,"o":"view_org"},{"a":43583,"t":"code","b":[133,106],"m":"sta","oa":106,"o":"ent_x"},{"a":43585,"t":"code","b":[165,104],"m":"lda","oa":104,"o":"zpa_68"},{"a":43587,"t":"code","b":[229,118],"m":"sbc","oa":118,"o":"zpa_76"},{"a":43589,"t":"code","b":[133,107],"m":"sta","oa":107,"o":"zpa_6B"},{"a":43591,"t":"code","b":[24],"m":"clc"},{"a":43592,"t":"code","b":[165,105],"m":"lda","oa":105,"o":"draw_wy"},{"a":43594,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":43596,"t":"code","b":[133,108],"m":"sta","oa":108,"o":"ent_row"},{"a":43598,"t":"code","b":[164,157],"m":"ldy","oa":157,"o":"list_cur_len"},{"a":43600,"t":"code","b":[165,113],"m":"lda","oa":113,"o":"ent_kind"},{"a":43602,"t":"code","b":[145,153],"m":"sta","oa":153,"o":"(list_cur),y"},{"a":43604,"t":"code","b":[200],"m":"iny"},{"a":43605,"t":"code","b":[165,106],"m":"lda","oa":106,"o":"ent_x"},{"a":43607,"t":"code","b":[145,153],"m":"sta","oa":153,"o":"(list_cur),y"},{"a":43609,"t":"code","b":[200],"m":"iny"},{"a":43610,"t":"code","b":[165,107],"m":"lda","oa":107,"o":"zpa_6B"},{"a":43612,"t":"code","b":[145,153],"m":"sta","oa":153,"o":"(list_cur),y"},{"a":43614,"t":"code","b":[200],"m":"iny"},{"a":43615,"t":"code","b":[165,108],"m":"lda","oa":108,"o":"ent_row"},{"a":43617,"t":"code","b":[145,153],"m":"sta","oa":153,"o":"(list_cur),y"},{"a":43619,"t":"code","b":[200],"m":"iny"},{"a":43620,"t":"code","b":[132,157],"m":"sty","oa":157,"o":"list_cur_len"},{"a":43622,"t":"code","b":[96],"m":"rts"},{"a":43623,"l":"draw_horizon_hills","c":"Draws the distant hills along the horizon; called once a frame from $95D4 and from the two other main loops. The screen X is taken from half the camera position - $75/$76 shifted right one with the low bit forced even - so the hills scroll at half the speed of the ground, which is the game's only parallax. Up to three copies of shape 64 (its pointer is the word at $8089) are laid side by side 256 pixels apart at row $1D, the ground line; a copy is skipped while its high byte $6E is below 4, which keeps the hills out of the left-hand end of the world. Each copy that is drawn queues colour stripe class 1 through $AA38 and blits with $8FD3. $0B60 counts the three copies down. Confirmed live: one hit per frame, in step with $AAC2.","t":"code","b":[165,118],"m":"lda","oa":118,"o":"zpa_76","x":[38356,38487,38583,38686,38732,38750]},{"a":43625,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43626,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":43628,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":43630,"t":"code","b":[106],"m":"ror","o":"a"},{"a":43631,"t":"code","b":[41,254],"m":"and","o":"#$FE"},{"a":43633,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":43635,"t":"code","b":[56],"m":"sec"},{"a":43636,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":43638,"t":"code","b":[229,109],"m":"sbc","oa":109,"o":"zpa_6D"},{"a":43640,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43642,"t":"code","b":[165,118],"m":"lda","oa":118,"o":"zpa_76"},{"a":43644,"t":"code","b":[229,110],"m":"sbc","oa":110,"o":"zpa_6E"},{"a":43646,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43648,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43650,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":43652,"t":"code","b":[24],"m":"clc"},{"a":43653,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":43655,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":43657,"t":"code","b":[165,110],"m":"lda","oa":110,"o":"zpa_6E","x":[32906]},{"a":43659,"t":"code","b":[101,128],"m":"adc","oa":128,"o":"zpa_80"},{"a":43661,"t":"code","b":[133,104],"m":"sta","oa":104,"o":"zpa_68"},{"a":43663,"t":"code","b":[169,29],"m":"lda","o":"#$1D"},{"a":43665,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":43667,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":43669,"t":"code","b":[141,96,11],"m":"sta","oa":2912,"o":"a_0B60"},{"a":43672,"l":"j_AA98","t":"code","b":[165,110],"m":"lda","oa":110,"o":"zpa_6E","x":[43710]},{"a":43674,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":43676,"t":"code","b":[144,23],"m":"bcc","oa":43701,"o":"b_AAB5"},{"a":43678,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":43681,"t":"gap","n":2},{"a":43683,"l":"hills_load_shape","c":"Continuation of $AA67 across the inline word at $AAA1: hands $8BE0 the pointer-table slot $8089, so $37/$38 ends up holding shape 64, the hill silhouette. The two bytes at $AAA6 are that routine's inline argument, not an instruction.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":43686,"t":"gap","n":2},{"a":43688,"l":"hills_blit_copy","c":"Continuation of $AA67 across the inline word at $AAA6: clips this hill copy with $8F03 and, if any of it is on screen, queues colour stripe class 1 through $AA38 and blits with $8FD3. Then steps $68 and $6E on by one, which moves the next copy 256 pixels to the right, and loops until the counter $0B60 has drawn three.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":43691,"t":"code","b":[176,8],"m":"bcs","oa":43701,"o":"b_AAB5"},{"a":43693,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":43695,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":43698,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":43701,"l":"b_AAB5","t":"code","b":[206,96,11],"m":"dec","oa":2912,"o":"a_0B60","x":[43676,43691]},{"a":43704,"t":"code","b":[240,7],"m":"beq","oa":43713,"o":"r_AAC1"},{"a":43706,"t":"code","b":[230,104],"m":"inc","oa":104,"o":"zpa_68"},{"a":43708,"t":"code","b":[230,110],"m":"inc","oa":110,"o":"zpa_6E"},{"a":43710,"t":"code","b":[76,152,170],"m":"jmp","oa":43672,"o":"j_AA98"},{"a":43713,"l":"r_AAC1","t":"code","b":[96],"m":"rts","x":[43704]},{"a":43714,"l":"draw_heli_body","c":"Draws the helicopter body and is the front end of the whole shape-drawing sequence; called from $AFEF. It picks a shape and a blitter from the yaw $59 (-3 full left, 0 head-on, +3 full right), the bank $5A and the hard-contact flag $60. Shape choice goes through the pointer table at $8009, 75 interleaved lo/hi words, read here at $AB4C/$AB52 and at $AB69/$AB6E. Fully side-on and banked uses shapes 0 to 10, indexed by 5 plus the bank signed by the facing, so 5 is the level frame. Fully side-on, level, on the one frame the skids bite ($60 set) uses shape 14 through $8025; head-on and level on that frame uses shape 15 through $8027. Everything else uses shape 11 plus |yaw| - 11, 12 or 13 - and is sheared rather than pre-drawn: $8C30 is called with the signed bank to load the shear slope $2B/$2C from $8C48 (one row every 3 to 13 columns), and $927E, indexed by 5*(bank+5) + yaw + 2, supplies an extra vertical offset in $6F. The blitter goes into $7F/$80: $8FD3 plain when level and facing right, $903E mirrored when level and facing left, otherwise the entry from $ABBF at 2*(yaw+3). Then the standard draw: half the shape's width (byte 0 of the shape, halved, because it is a bit count and the bitmap is multicolour) in X, half its height plus $6F in Y, $A9A0 to turn those into $67/$68/$69 from the player's actor record, $8BF9 with the inline word $0067 to copy that into $34/$35/$36, $8BE0 with the inline word $0065 to copy the shape pointer into $37/$38, $8F03 to clip and set up, $8BAF handed the settle counter $62 (it leaves it in $25 with $22-$24 cleared; what the blitter does with $25 is outside this range), and finally the chosen blitter reached by pushing $ABBD and doing jmp ($7F), which returns to the rts at $ABBE.","t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A","x":[45039]},{"a":43716,"t":"code","b":[36,89],"m":"bit","oa":89,"o":"heli_facing"},{"a":43718,"t":"code","b":[16,5],"m":"bpl","oa":43725,"o":"b_AACD"},{"a":43720,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43722,"t":"code","b":[24],"m":"clc"},{"a":43723,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":43725,"l":"b_AACD","t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F","x":[43718]},{"a":43727,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":43729,"t":"code","b":[208,26],"m":"bne","oa":43757,"o":"b_AAED"},{"a":43731,"t":"code","b":[36,89],"m":"bit","oa":89,"o":"heli_facing"},{"a":43733,"t":"code","b":[48,11],"m":"bmi","oa":43746,"o":"b_AAE2"},{"a":43735,"t":"code","b":[169,211],"m":"lda","o":"#$D3"},{"a":43737,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43739,"t":"code","b":[169,143],"m":"lda","o":"#$8F"},{"a":43741,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43743,"t":"code","b":[76,254,170],"m":"jmp","oa":43774,"o":"j_AAFE"},{"a":43746,"l":"b_AAE2","t":"code","b":[169,62],"m":"lda","o":"#$3E","x":[43733]},{"a":43748,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43750,"t":"code","b":[169,144],"m":"lda","o":"#$90"},{"a":43752,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43754,"t":"code","b":[76,254,170],"m":"jmp","oa":43774,"o":"j_AAFE"},{"a":43757,"l":"b_AAED","t":"code","b":[24],"m":"clc","x":[43729]},{"a":43758,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":43760,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":43762,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43763,"t":"code","b":[168],"m":"tay"},{"a":43764,"t":"code","b":[185,191,171],"m":"lda","oa":43967,"o":"heli_blitter_lo,y"},{"a":43767,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":43769,"t":"code","b":[185,192,171],"m":"lda","oa":43968,"o":"heli_blitter_hi,y"},{"a":43772,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":43774,"l":"j_AAFE","t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing","x":[43743,43754]},{"a":43776,"t":"code","b":[240,11],"m":"beq","oa":43789,"o":"b_AB0D"},{"a":43778,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":43780,"t":"code","b":[240,18],"m":"beq","oa":43800,"o":"b_AB18"},{"a":43782,"t":"code","b":[201,253],"m":"cmp","o":"#$FD"},{"a":43784,"t":"code","b":[240,14],"m":"beq","oa":43800,"o":"b_AB18"},{"a":43786,"t":"code","b":[76,94,171],"m":"jmp","oa":43870,"o":"j_AB5E"},{"a":43789,"l":"b_AB0D","t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A","x":[43776]},{"a":43791,"t":"code","b":[208,77],"m":"bne","oa":43870,"o":"j_AB5E"},{"a":43793,"t":"code","b":[165,96],"m":"lda","oa":96,"o":"zpa_60"},{"a":43795,"t":"code","b":[240,73],"m":"beq","oa":43870,"o":"j_AB5E"},{"a":43797,"t":"code","b":[76,35,171],"m":"jmp","oa":43811,"o":"j_AB23"},{"a":43800,"l":"b_AB18","t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A","x":[43780,43784]},{"a":43802,"t":"code","b":[208,41],"m":"bne","oa":43845,"o":"b_AB45"},{"a":43804,"t":"code","b":[165,96],"m":"lda","oa":96,"o":"zpa_60"},{"a":43806,"t":"code","b":[240,37],"m":"beq","oa":43845,"o":"b_AB45"},{"a":43808,"t":"code","b":[76,52,171],"m":"jmp","oa":43828,"o":"j_AB34"},{"a":43811,"l":"j_AB23","s":"shape 15: head-on, level, on the frame the skids bite","t":"code","b":[173,39,128],"m":"lda","oa":32807,"o":"shape_ptr_heli_front_short","x":[43797]},{"a":43814,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":43816,"t":"code","b":[173,40,128],"m":"lda","oa":32808,"o":"shape_ptr_heli_front_short_hi"},{"a":43819,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":43821,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43823,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":43825,"t":"code","b":[76,144,171],"m":"jmp","oa":43920,"o":"j_AB90"},{"a":43828,"l":"j_AB34","s":"shape 14: full side view, level, on the frame the skids bite","t":"code","b":[173,37,128],"m":"lda","oa":32805,"o":"shape_ptr_heli_side_short","x":[43808]},{"a":43831,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":43833,"t":"code","b":[173,38,128],"m":"lda","oa":32806,"o":"shape_ptr_heli_side_short_hi"},{"a":43836,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":43838,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43840,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":43842,"t":"code","b":[76,144,171],"m":"jmp","oa":43920,"o":"j_AB90"},{"a":43845,"l":"b_AB45","t":"code","b":[24],"m":"clc","x":[43802,43806]},{"a":43846,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":43848,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":43850,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43851,"t":"code","b":[168],"m":"tay"},{"a":43852,"s":"shape index 5 + signed bank: the eleven side-view frames 0..10","t":"code","b":[185,9,128],"m":"lda","oa":32777,"o":"shape_ptr_table,y"},{"a":43855,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":43857,"t":"code","b":[200],"m":"iny"},{"a":43858,"t":"code","b":[185,9,128],"m":"lda","oa":32777,"o":"shape_ptr_table,y"},{"a":43861,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":43863,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43865,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":43867,"t":"code","b":[76,144,171],"m":"jmp","oa":43920,"o":"j_AB90"},{"a":43870,"l":"j_AB5E","t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing","x":[43786,43791,43795]},{"a":43872,"t":"code","b":[16,5],"m":"bpl","oa":43879,"o":"b_AB67"},{"a":43874,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":43876,"t":"code","b":[24],"m":"clc"},{"a":43877,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":43879,"l":"b_AB67","t":"code","b":[10],"m":"asl","o":"a","x":[43872]},{"a":43880,"t":"code","b":[168],"m":"tay"},{"a":43881,"s":"shape index 11 + |yaw|: head-on and the two turning frames, drawn sheared","t":"code","b":[185,31,128],"m":"lda","oa":32799,"o":"shape_ptr_heli_front,y"},{"a":43884,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":43886,"t":"code","b":[185,32,128],"m":"lda","oa":32800,"o":"shape_ptr_heli_front_hi,y"},{"a":43889,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":43891,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":43893,"t":"code","b":[32,48,140],"m":"jsr","oa":35888,"o":"shear_from_speed"},{"a":43896,"t":"code","b":[24],"m":"clc"},{"a":43897,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":43899,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":43901,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":43903,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43904,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43905,"t":"code","b":[24],"m":"clc"},{"a":43906,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":43908,"t":"code","b":[24],"m":"clc"},{"a":43909,"t":"code","b":[101,89],"m":"adc","oa":89,"o":"heli_facing"},{"a":43911,"t":"code","b":[24],"m":"clc"},{"a":43912,"t":"code","b":[105,2],"m":"adc","o":"#$02"},{"a":43914,"t":"code","b":[170],"m":"tax"},{"a":43915,"t":"code","b":[189,126,146],"m":"lda","oa":37502,"o":"heli_body_y_nudge,x"},{"a":43918,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":43920,"l":"j_AB90","t":"code","b":[160,0],"m":"ldy","o":"#$00","x":[43825,43842,43867]},{"a":43922,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":43924,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43925,"t":"code","b":[170],"m":"tax"},{"a":43926,"t":"code","b":[200],"m":"iny"},{"a":43927,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":43929,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":43930,"t":"code","b":[24],"m":"clc"},{"a":43931,"t":"code","b":[101,111],"m":"adc","oa":111,"o":"zpa_6F"},{"a":43933,"t":"code","b":[168],"m":"tay"},{"a":43934,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":43936,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":43939,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":43942,"s":"inline argument: the destination $67/$68/$69 the call to $A9A0 just computed","t":"byte","b":[103],"note":"not a legal opcode"},{"a":43943,"t":"code","b":[0],"m":"brk"},{"a":43944,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":43947,"s":"inline argument: $0065, holding the helicopter body shape chosen above","t":"code","b":[101,0],"m":"adc","oa":0,"o":"cpu_ddr"},{"a":43949,"t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":43952,"t":"code","b":[165,98],"m":"lda","oa":98,"o":"zpa_62"},{"a":43954,"t":"code","b":[32,175,139],"m":"jsr","oa":35759,"o":"clip_override_bottom"},{"a":43957,"t":"code","b":[169,171],"m":"lda","o":"#$AB"},{"a":43959,"t":"code","b":[72],"m":"pha"},{"a":43960,"t":"code","b":[169,189],"m":"lda","o":"#$BD"},{"a":43962,"t":"code","b":[72],"m":"pha"},{"a":43963,"s":"call the blitter chosen in $7F/$80; the pushed $ABBD makes it return to the rts at $ABBE","t":"code","b":[108,127,0],"m":"jmp","oa":127,"o":"(zpa_7F)"},{"a":43966,"t":"code","b":[96],"m":"rts"},{"a":43967,"l":"heli_blitter_lo","c":"Low bytes of the seven blitter entry points $AAC2 chooses between when the helicopter is banked, indexed by 2*($59+3) for yaw -3 to +3: $903E, $90DF, $90DF, $90D2, $90D2, $90D2, $8FD3. $903E draws mirrored and $8FD3 plain; $90D2 and $90DF are the pair that apply the shear $8C30 set up, which is why they serve the turning frames.","t":"word","b":[62],"d":[],"x":[43764]},{"a":43968,"l":"heli_blitter_hi","c":"High bytes of those same seven blitter addresses; $AAF4 and $AAF9 read $ABBF,y and $ABC0,y as one little-endian pointer into $7F/$80.","t":"word","b":[144,223,144,223,144,210,144,210],"d":[57232,57232,53904,53904],"x":[43769]},{"a":43976,"t":"word","b":[144,210,144,211,143],"d":[53904,54160]},{"a":43981,"l":"draw_heli_rotor","c":"Draws the main rotor disc over the helicopter; called from $AFF2. The offset from the body is the sum of two tables: $92B5, indexed by 14*(bank+5) + 2*(yaw+3), gives a small per-facing correction in $86/$87, and $934F/$9350, indexed by 2*(bank+5), gives the base offset - about 16 to the left and 6 up when level. $A9A0 turns that into the destination and $8BF9 with the inline word $0067 stores it; $8C30 is then called with the bank so the disc is sheared exactly as the body is. The phase counter $0B61 steps 4, 2, 0 and wraps, choosing one of shapes 16, 17 and 18 through $8029 + $0B61, and is held at 4 whenever the settle counter $62 is running, so the rotor stops turning as the machine settles. $8BE0 with the inline word $0065 loads the shape, $8F03 clips and $90D2 blits.","t":"code","b":[24],"m":"clc","x":[45042]},{"a":43982,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":43984,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":43986,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":43988,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43989,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":43991,"t":"code","b":[24],"m":"clc"},{"a":43992,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":43994,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43995,"t":"code","b":[10],"m":"asl","o":"a"},{"a":43996,"t":"code","b":[24],"m":"clc"},{"a":43997,"t":"code","b":[101,110],"m":"adc","oa":110,"o":"zpa_6E"},{"a":43999,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":44001,"t":"code","b":[24],"m":"clc"},{"a":44002,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":44004,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":44006,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44007,"t":"code","b":[24],"m":"clc"},{"a":44008,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":44010,"t":"code","b":[170],"m":"tax"},{"a":44011,"t":"code","b":[189,181,146],"m":"lda","oa":37557,"o":"rotor_offset_fine,x"},{"a":44014,"t":"code","b":[133,134],"m":"sta","oa":134,"o":"zpa_86"},{"a":44016,"t":"code","b":[189,182,146],"m":"lda","oa":37558,"o":"rotor_offset_fine_y,x"},{"a":44019,"t":"code","b":[133,135],"m":"sta","oa":135,"o":"zpa_87"},{"a":44021,"t":"code","b":[24],"m":"clc"},{"a":44022,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":44024,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":44026,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44027,"t":"code","b":[170],"m":"tax"},{"a":44028,"t":"code","b":[24],"m":"clc"},{"a":44029,"t":"code","b":[189,80,147],"m":"lda","oa":37712,"o":"rotor_offset_base_y,x"},{"a":44032,"t":"code","b":[101,135],"m":"adc","oa":135,"o":"zpa_87"},{"a":44034,"t":"code","b":[168],"m":"tay"},{"a":44035,"t":"code","b":[24],"m":"clc"},{"a":44036,"t":"code","b":[189,79,147],"m":"lda","oa":37711,"o":"rotor_offset_base,x"},{"a":44039,"t":"code","b":[101,134],"m":"adc","oa":134,"o":"zpa_86"},{"a":44041,"t":"code","b":[170],"m":"tax"},{"a":44042,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":44044,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":44047,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":44050,"s":"inline argument: the destination $67/$68/$69 of the rotor disc","t":"byte","b":[103],"note":"not a legal opcode"},{"a":44051,"t":"code","b":[0],"m":"brk"},{"a":44052,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":44054,"t":"code","b":[32,48,140],"m":"jsr","oa":35888,"o":"shear_from_speed"},{"a":44057,"t":"code","b":[165,98],"m":"lda","oa":98,"o":"zpa_62"},{"a":44059,"t":"code","b":[208,14],"m":"bne","oa":44075,"o":"b_AC2B"},{"a":44061,"t":"code","b":[173,97,11],"m":"lda","oa":2913,"o":"a_0B61"},{"a":44064,"t":"code","b":[240,9],"m":"beq","oa":44075,"o":"b_AC2B"},{"a":44066,"t":"code","b":[56],"m":"sec"},{"a":44067,"t":"code","b":[233,2],"m":"sbc","o":"#$02"},{"a":44069,"t":"code","b":[141,97,11],"m":"sta","oa":2913,"o":"a_0B61"},{"a":44072,"t":"code","b":[76,48,172],"m":"jmp","oa":44080,"o":"j_AC30"},{"a":44075,"l":"b_AC2B","t":"code","b":[169,4],"m":"lda","o":"#$04","x":[44059,44064]},{"a":44077,"t":"code","b":[141,97,11],"m":"sta","oa":2913,"o":"a_0B61"},{"a":44080,"l":"j_AC30","t":"code","b":[174,97,11],"m":"ldx","oa":2913,"o":"a_0B61","x":[44072]},{"a":44083,"s":"rotor blur shapes 16, 17, 18 by phase $0B61","t":"code","b":[189,41,128],"m":"lda","oa":32809,"o":"shape_ptr_rotor_disc,x"},{"a":44086,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":44088,"t":"code","b":[232],"m":"inx"},{"a":44089,"t":"code","b":[189,41,128],"m":"lda","oa":32809,"o":"shape_ptr_rotor_disc,x"},{"a":44092,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":44094,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":44097,"s":"inline argument: $0065, holding the rotor blur shape for phase $0B61","t":"code","b":[101,0],"m":"adc","oa":0,"o":"cpu_ddr"},{"a":44099,"t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":44102,"t":"code","b":[32,210,144],"m":"jsr","oa":37074,"o":"draw_sheared_shape"},{"a":44105,"t":"code","b":[96],"m":"rts"},{"a":44106,"l":"draw_heli_tail_rotor","c":"Draws the tail rotor; called from $AFF5. Returns at once unless the helicopter is fully side-on ($59 = +3 or -3), because the tail only shows in profile. The offset comes from $9365 when facing right - x +18 or +19, y +1 to +11 - or $937B when facing left - x -12 or -13 - indexed by 2*(bank+5), so the tail follows the body's pitch. The phase counter $0B62 steps 6, 4, 2, 0 and wraps, choosing one of shapes 19 to 22 through $802F + $0B62, and like the main rotor is frozen at 6 while the settle counter $62 runs. $8BE0 with the inline word $0065 takes the shape, $A9A0 and $8BF9 with the inline word $0067 the position, then $8F03 clips and $8FD3 blits.","t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing","x":[45045]},{"a":44108,"t":"code","b":[240,8],"m":"beq","oa":44118,"o":"r_AC56"},{"a":44110,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":44112,"t":"code","b":[240,5],"m":"beq","oa":44119,"o":"b_AC57"},{"a":44114,"t":"code","b":[201,253],"m":"cmp","o":"#$FD"},{"a":44116,"t":"code","b":[240,1],"m":"beq","oa":44119,"o":"b_AC57"},{"a":44118,"l":"r_AC56","t":"code","b":[96],"m":"rts","x":[44108]},{"a":44119,"l":"b_AC57","t":"code","b":[24],"m":"clc","x":[44112,44116]},{"a":44120,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":44122,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":44124,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44125,"t":"code","b":[170],"m":"tax"},{"a":44126,"t":"code","b":[36,89],"m":"bit","oa":89,"o":"heli_facing"},{"a":44128,"t":"code","b":[48,13],"m":"bmi","oa":44143,"o":"b_AC6F"},{"a":44130,"t":"code","b":[189,101,147],"m":"lda","oa":37733,"o":"tail_rotor_offset_r,x"},{"a":44133,"t":"code","b":[133,134],"m":"sta","oa":134,"o":"zpa_86"},{"a":44135,"t":"code","b":[189,102,147],"m":"lda","oa":37734,"o":"tail_rotor_offset_r_y,x"},{"a":44138,"t":"code","b":[133,135],"m":"sta","oa":135,"o":"zpa_87"},{"a":44140,"t":"code","b":[76,121,172],"m":"jmp","oa":44153,"o":"j_AC79"},{"a":44143,"l":"b_AC6F","t":"code","b":[189,123,147],"m":"lda","oa":37755,"o":"tail_rotor_offset_l,x","x":[44128]},{"a":44146,"t":"code","b":[133,134],"m":"sta","oa":134,"o":"zpa_86"},{"a":44148,"t":"code","b":[189,124,147],"m":"lda","oa":37756,"o":"tail_rotor_offset_l_y,x"},{"a":44151,"t":"code","b":[133,135],"m":"sta","oa":135,"o":"zpa_87"},{"a":44153,"l":"j_AC79","t":"code","b":[165,98],"m":"lda","oa":98,"o":"zpa_62","x":[44140]},{"a":44155,"t":"code","b":[208,19],"m":"bne","oa":44176,"o":"b_AC90"},{"a":44157,"t":"code","b":[173,98,11],"m":"lda","oa":2914,"o":"a_0B62"},{"a":44160,"t":"code","b":[240,9],"m":"beq","oa":44171,"o":"b_AC8B"},{"a":44162,"t":"code","b":[56],"m":"sec"},{"a":44163,"t":"code","b":[233,2],"m":"sbc","o":"#$02"},{"a":44165,"t":"code","b":[141,98,11],"m":"sta","oa":2914,"o":"a_0B62"},{"a":44168,"t":"code","b":[76,144,172],"m":"jmp","oa":44176,"o":"b_AC90"},{"a":44171,"l":"b_AC8B","t":"code","b":[169,6],"m":"lda","o":"#$06","x":[44160]},{"a":44173,"t":"code","b":[141,98,11],"m":"sta","oa":2914,"o":"a_0B62"},{"a":44176,"l":"b_AC90","t":"code","b":[174,98,11],"m":"ldx","oa":2914,"o":"a_0B62","x":[44155,44168]},{"a":44179,"s":"tail rotor shapes 19..22 by phase $0B62","t":"code","b":[189,47,128],"m":"lda","oa":32815,"o":"shape_ptr_tail_rotor,x"},{"a":44182,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":44184,"t":"code","b":[189,48,128],"m":"lda","oa":32816,"o":"shape_ptr_jet,x"},{"a":44187,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":44189,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":44192,"t":"gap","n":2},{"a":44194,"l":"tail_rotor_position","c":"Continuation of $AC4A across the inline word at $ACA0: puts the tail-rotor offset just read from $9365 or $937B into X and Y and calls $A9A0, which turns it into the destination $67/$68/$69 relative to the player's actor record.","t":"code","b":[166,134],"m":"ldx","oa":134,"o":"zpa_86"},{"a":44196,"t":"code","b":[164,135],"m":"ldy","oa":135,"o":"zpa_87"},{"a":44198,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":44200,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":44203,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":44206,"t":"gap","n":2},{"a":44208,"l":"tail_rotor_blit","c":"Continuation of $AC4A across the inline word at $ACAE: clips the tail rotor with $8F03 and, when it is on screen, blits it plain with $8FD3. No colour stripe is queued for it - the helicopter's single class-0 stripe covers the whole machine.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":44211,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":44214,"t":"code","b":[96],"m":"rts"},{"a":44215,"l":"heli_muzzle_offset","c":"Gives back the position of the helicopter's gun muzzle relative to the machine's own centre: the horizontal offset in X and the vertical one in Y, read as a pair from $9391 at 14*(bank+5) + 2*(yaw+3) - one entry for each of the eleven bank angles crossed with the seven yaw stages. The offsets run from about +14 when head-on to -15 when fully side-on. Called from $B019 the instant a shot is created; confirmed live, hit exactly once per shot fired.","t":"code","b":[24],"m":"clc","x":[45081]},{"a":44216,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":44218,"t":"code","b":[105,5],"m":"adc","o":"#$05"},{"a":44220,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":44222,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44223,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":44225,"t":"code","b":[24],"m":"clc"},{"a":44226,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":44228,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44229,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44230,"t":"code","b":[24],"m":"clc"},{"a":44231,"t":"code","b":[101,110],"m":"adc","oa":110,"o":"zpa_6E"},{"a":44233,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":44235,"t":"code","b":[24],"m":"clc"},{"a":44236,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":44238,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":44240,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44241,"t":"code","b":[24],"m":"clc"},{"a":44242,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":44244,"t":"code","b":[168],"m":"tay"},{"a":44245,"t":"code","b":[190,145,147],"m":"ldx","oa":37777,"o":"muzzle_offset,y"},{"a":44248,"t":"code","b":[185,146,147],"m":"lda","oa":37778,"o":"muzzle_offset_y,y"},{"a":44251,"t":"code","b":[168],"m":"tay"},{"a":44252,"t":"code","b":[96],"m":"rts"},{"a":44253,"l":"mul8x8_unused","c":"An eight-bit shift-and-add multiply: $7D times $7E, product low byte left in $7F and high byte in A and $80, twenty bytes ending in rts. Nothing in $8000-$BFFF refers to it - no cross-reference, and a checkpoint on it was never hit during play - so it is left-over library code that the build kept.","t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":44255,"t":"code","b":[162,8],"m":"ldx","o":"#$08"},{"a":44257,"l":"b_ACE1","t":"code","b":[70,125],"m":"lsr","oa":125,"o":"zpa_7D","x":[44268]},{"a":44259,"t":"code","b":[144,3],"m":"bcc","oa":44264,"o":"b_ACE8"},{"a":44261,"t":"code","b":[24],"m":"clc"},{"a":44262,"t":"code","b":[101,126],"m":"adc","oa":126,"o":"zpa_7E"},{"a":44264,"l":"b_ACE8","t":"code","b":[106],"m":"ror","o":"a","x":[44259]},{"a":44265,"t":"code","b":[102,127],"m":"ror","oa":127,"o":"zpa_7F"},{"a":44267,"t":"code","b":[202],"m":"dex"},{"a":44268,"t":"code","b":[208,243],"m":"bne","oa":44257,"o":"b_ACE1"},{"a":44270,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":44272,"t":"code","b":[96],"m":"rts"},{"a":44273,"l":"asr16","c":"Arithmetic shift right of the signed 16-bit value in $7F/$80 by Y places. The value is made positive on the way in, shifted Y times, and negated again on the way out, so the sign is preserved; Y is never zero at any call site. This is the game's only division, and the flight model leans on it: drag at $A41D with Y = 4, velocity into movement at $A64A and $A6A4 with Y = 8, the skid at $A535 with Y = 1, the bank calculation at $A58C with Y = 9, the camera look-ahead at $BD22 with Y = 5.","t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80","x":[42013,42293,42380,42444,42498,42570,42660,47543,47565,47587,48418,48603]},{"a":44275,"t":"code","b":[72],"m":"pha"},{"a":44276,"t":"code","b":[16,17],"m":"bpl","oa":44295,"o":"b_AD07"},{"a":44278,"t":"code","b":[24],"m":"clc"},{"a":44279,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":44281,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44283,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":44285,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":44287,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":44289,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44291,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":44293,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":44295,"l":"b_AD07","t":"code","b":[70,128],"m":"lsr","oa":128,"o":"zpa_80","x":[44276,44300]},{"a":44297,"t":"code","b":[102,127],"m":"ror","oa":127,"o":"zpa_7F"},{"a":44299,"t":"code","b":[136],"m":"dey"},{"a":44300,"t":"code","b":[208,249],"m":"bne","oa":44295,"o":"b_AD07"},{"a":44302,"t":"code","b":[104],"m":"pla"},{"a":44303,"t":"code","b":[16,18],"m":"bpl","oa":44323,"o":"r_AD23"},{"a":44305,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":44307,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44309,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":44311,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":44313,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44315,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":44317,"t":"code","b":[230,127],"m":"inc","oa":127,"o":"zpa_7F"},{"a":44319,"t":"code","b":[208,2],"m":"bne","oa":44323,"o":"r_AD23"},{"a":44321,"t":"code","b":[230,128],"m":"inc","oa":128,"o":"zpa_80"},{"a":44323,"l":"r_AD23","t":"code","b":[96],"m":"rts","x":[44303,44319]},{"a":44324,"l":"shot_velocity_from_heli","c":"Fills in a new shot's motion fields from the helicopter's attitude; called from $B048 with the new slot in $72. The byte pair at $942B, indexed by 12*|yaw| + 2*|bank|, gives the shot's speed. Field +1 ($0B75) is the horizontal step - negated when the helicopter faces left, then offset by the helicopter's own horizontal speed (the high byte of $51/$52, rounded toward zero) so shots inherit the machine's momentum. Field +2 ($0B76) is the vertical step, negated when yaw and bank have opposite signs. Field +3 ($0B77) comes from $AD86 indexed by |yaw|. Head-on shots barely move sideways at all (0 to 2 a frame) while fully side-on shots cross the screen at 26.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[45128]},{"a":44326,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":44328,"t":"code","b":[16,5],"m":"bpl","oa":44335,"o":"b_AD2F"},{"a":44330,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44332,"t":"code","b":[24],"m":"clc"},{"a":44333,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":44335,"l":"b_AD2F","t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F","x":[44328]},{"a":44337,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44338,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":44340,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44341,"t":"code","b":[24],"m":"clc"},{"a":44342,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":44344,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":44346,"t":"code","b":[6,109],"m":"asl","oa":109,"o":"zpa_6D"},{"a":44348,"t":"code","b":[165,90],"m":"lda","oa":90,"o":"zpa_5A"},{"a":44350,"t":"code","b":[16,5],"m":"bpl","oa":44357,"o":"b_AD45"},{"a":44352,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44354,"t":"code","b":[24],"m":"clc"},{"a":44355,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":44357,"l":"b_AD45","t":"code","b":[10],"m":"asl","o":"a","x":[44350]},{"a":44358,"t":"code","b":[24],"m":"clc"},{"a":44359,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":44361,"t":"code","b":[168],"m":"tay"},{"a":44362,"t":"code","b":[185,43,148],"m":"lda","oa":37931,"o":"heli_shot_speed,y"},{"a":44365,"t":"code","b":[36,89],"m":"bit","oa":89,"o":"heli_facing"},{"a":44367,"t":"code","b":[16,5],"m":"bpl","oa":44374,"o":"b_AD56"},{"a":44369,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44371,"t":"code","b":[24],"m":"clc"},{"a":44372,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":44374,"l":"b_AD56","t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D","x":[44367]},{"a":44376,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":44378,"t":"code","b":[16,3],"m":"bpl","oa":44383,"o":"b_AD5F"},{"a":44380,"t":"code","b":[24],"m":"clc"},{"a":44381,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":44383,"l":"b_AD5F","t":"code","b":[24],"m":"clc","x":[44378]},{"a":44384,"t":"code","b":[101,109],"m":"adc","oa":109,"o":"zpa_6D"},{"a":44386,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":44389,"t":"code","b":[185,44,148],"m":"lda","oa":37932,"o":"heli_shot_speed_y,y"},{"a":44392,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":44394,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":44396,"t":"code","b":[69,90],"m":"eor","oa":90,"o":"zpa_5A"},{"a":44398,"t":"code","b":[16,8],"m":"bpl","oa":44408,"o":"b_AD78"},{"a":44400,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":44402,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44404,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":44406,"t":"code","b":[230,109],"m":"inc","oa":109,"o":"zpa_6D"},{"a":44408,"l":"b_AD78","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[44398]},{"a":44410,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":44413,"t":"code","b":[164,111],"m":"ldy","oa":111,"o":"zpa_6F"},{"a":44415,"t":"code","b":[185,134,173],"m":"lda","oa":44422,"o":"shot_field3_table,y"},{"a":44418,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":44421,"t":"code","b":[96],"m":"rts"},{"a":44422,"l":"shot_field3_table","c":"The value $AD24 puts in a new shot's field +3 ($0B77), indexed by |yaw| 0 to 3: $FE, $FE, $FF, $00 - so the flatter the shot, the closer to zero. The type-6 handler at $B16E is what reads it back.","t":"byte","b":[254,254,255,0],"x":[44415]},{"a":44426,"l":"jet_state_frame_counts","c":"How many animation frames each of the jet's five states lasts, read at $AF6F and $AF8F: state 0 never ends (0), state 1 runs 18 frames, state 2 runs 15, and states 3 and 4 run 10 each. When the jet's field +2 reaches the count for its state, the state is over.","t":"byte","b":[0,18,15,10,10],"x":[44911,44943]},{"a":44431,"l":"actor_jet","c":"Actor handler 9, the enemy jet - entry 9 of the dispatch table at $B32E; the shapes it draws (indices 23, 24, 31 and 36 upward in the $8009 table) render as an aircraft in profile and three-quarter view. Field +1 is the state (0 cruising, 1 and 2 the two attack manoeuvres, 3 and 4 the firing run) and field +2 the frame within it. The state selects an animation script through the pointer table at $AFC2/$AFC3 ($94E3, $94E7, $952F, $956B, $956B) and a shape base through $AFCC/$AFCD ($8037, $8039, $8047, $8051, $8051). Each script entry is four bytes: a shape sub-index kept in $0B51, a horizontal step and two vertical steps; state 0 is a single frame that simply moves the jet 8 units a frame. Drawing uses the standard sequence - $8BE0 with the inline word $0065 for the shape, $A9A0 with A = 1 so the jet is snapped to the multicolour pixel grid, $8BF9 with the inline word $0067 for the destination, $8F03 to clip - then $8FD3 plain or $903E mirrored according to the sign of field +3. $0B50 is set to $FF before the clip and cleared only if the jet was on screen. An on-screen jet also queues a colour stripe of class 7 + $9487[8*state + sub-index]. The script's steps are then applied to fields +6, +7 and +4/+5 (the horizontal one negated when the jet faces left), and in states 1 and 2 field +6 is dragged to within $1E of the helicopter's altitude $57. The state machine last: state 0 begins a manoeuvre when the helicopter is near enough - the reach is $98 + 4*$8D, so it grows with the counter $8D - choosing state 1 or state 2 from whether the helicopter's heading ($52) and the jet's facing (field +3) agree and from how fast the helicopter is moving; it goes straight to state 4, frame 5, if the helicopter has already been hit ($61) or if the jet is past world X $1100. States 1 and 2 count their frames out, flip the facing at the end of state 1, and then become state 3 if the helicopter is airborne or state 4 if it is on the ground. States 3 and 4 fire on their first frame - $B665 creates a pair of type-4 actors eight rows above and nine below the jet, $B6ED a single type-5 - and when their ten frames are up the jet takes itself off both the short list ($B5F5) and the actor list ($A937), but only if it had gone off screen.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":44433,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":44436,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44437,"t":"code","b":[168],"m":"tay"},{"a":44438,"t":"code","b":[185,194,175],"m":"lda","oa":44994,"o":"jet_script_lo,y"},{"a":44441,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":44443,"t":"code","b":[185,195,175],"m":"lda","oa":44995,"o":"jet_script_hi,y"},{"a":44446,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":44448,"t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x"},{"a":44451,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44452,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44453,"t":"code","b":[168],"m":"tay"},{"a":44454,"t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y"},{"a":44456,"t":"code","b":[141,81,11],"m":"sta","oa":2897,"o":"a_0B51"},{"a":44459,"t":"code","b":[200],"m":"iny"},{"a":44460,"t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y"},{"a":44462,"t":"code","b":[133,134],"m":"sta","oa":134,"o":"zpa_86"},{"a":44464,"t":"code","b":[200],"m":"iny"},{"a":44465,"t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y"},{"a":44467,"t":"code","b":[133,135],"m":"sta","oa":135,"o":"zpa_87"},{"a":44469,"t":"code","b":[200],"m":"iny"},{"a":44470,"t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y"},{"a":44472,"t":"code","b":[133,136],"m":"sta","oa":136,"o":"zpa_88"},{"a":44474,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":44477,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44478,"t":"code","b":[168],"m":"tay"},{"a":44479,"t":"code","b":[185,204,175],"m":"lda","oa":45004,"o":"jet_shape_base_lo,y"},{"a":44482,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":44484,"t":"code","b":[185,205,175],"m":"lda","oa":45005,"o":"jet_shape_base_hi,y"},{"a":44487,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":44489,"t":"code","b":[173,81,11],"m":"lda","oa":2897,"o":"a_0B51"},{"a":44492,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44493,"t":"code","b":[168],"m":"tay"},{"a":44494,"t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y"},{"a":44496,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":44498,"t":"code","b":[200],"m":"iny"},{"a":44499,"t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y"},{"a":44501,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":44503,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":44506,"t":"gap","n":2},{"a":44508,"l":"jet_shape_size","c":"Continuation of $AD8F across the inline word at $ADDA: reads the jet shape's first two bytes, the width in bitmap bits and the height in rows, halves each (two bits are one multicolour pixel) into X and Y, and calls $A9A0 with A = 1 so the jet is snapped to the multicolour pixel grid.","t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":44510,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":44512,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":44513,"t":"code","b":[170],"m":"tax"},{"a":44514,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":44516,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":44518,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":44519,"t":"code","b":[168],"m":"tay"},{"a":44520,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":44522,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":44525,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":44528,"t":"gap","n":2},{"a":44530,"l":"jet_draw_and_move","c":"Continuation of the jet handler $AD8F across the inline word at $ADF0, and the bulk of it. Sets $0B50 to $FF, clips with $8F03, and for an on-screen jet clears $0B50, blits plain ($8FD3) or mirrored ($903E) according to the sign of field +3, and queues colour stripe class 7 + $9487[8*state + shape sub-index]. Then applies the animation script's three steps to fields +6, +7 and +4/+5 (the horizontal one negated when the jet faces left); in states 1 and 2 it drags field +6 to within $1E of the helicopter's altitude $57. The rest is the state machine: state 0 decides whether to begin a manoeuvre, states 1 and 2 count their frames out and then pick the firing state from whether the helicopter is airborne, and states 3 and 4 fire on their first frame through $B665 or $B6ED and take the jet off the lists through $B5F5 and $A937 when they end.","t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":44532,"t":"code","b":[141,80,11],"m":"sta","oa":2896,"o":"a_0B50"},{"a":44535,"t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":44538,"t":"code","b":[176,43],"m":"bcs","oa":44583,"o":"b_AE27"},{"a":44540,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":44542,"t":"code","b":[141,80,11],"m":"sta","oa":2896,"o":"a_0B50"},{"a":44545,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":44547,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":44550,"t":"code","b":[48,6],"m":"bmi","oa":44558,"o":"b_AE0E"},{"a":44552,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":44555,"t":"code","b":[76,17,174],"m":"jmp","oa":44561,"o":"j_AE11"},{"a":44558,"l":"b_AE0E","t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored","x":[44550]},{"a":44561,"l":"j_AE11","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[44555]},{"a":44563,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":44566,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44567,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44568,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44569,"t":"code","b":[24],"m":"clc"},{"a":44570,"t":"code","b":[109,81,11],"m":"adc","oa":2897,"o":"a_0B51"},{"a":44573,"t":"code","b":[168],"m":"tay"},{"a":44574,"t":"code","b":[24],"m":"clc"},{"a":44575,"t":"code","b":[169,7],"m":"lda","o":"#$07"},{"a":44577,"s":"colour stripe class 7 + $9487[8*state + sub-index]","t":"code","b":[121,135,148],"m":"adc","oa":38023,"o":"jet_erase_class,y"},{"a":44580,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":44583,"l":"b_AE27","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[44538]},{"a":44585,"t":"code","b":[24],"m":"clc"},{"a":44586,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":44589,"t":"code","b":[101,135],"m":"adc","oa":135,"o":"zpa_87"},{"a":44591,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":44594,"t":"code","b":[24],"m":"clc"},{"a":44595,"t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x"},{"a":44598,"t":"code","b":[101,136],"m":"adc","oa":136,"o":"zpa_88"},{"a":44600,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":44603,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":44606,"t":"code","b":[16,8],"m":"bpl","oa":44616,"o":"b_AE48"},{"a":44608,"t":"code","b":[165,134],"m":"lda","oa":134,"o":"zpa_86"},{"a":44610,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44612,"t":"code","b":[133,134],"m":"sta","oa":134,"o":"zpa_86"},{"a":44614,"t":"code","b":[230,134],"m":"inc","oa":134,"o":"zpa_86"},{"a":44616,"l":"b_AE48","t":"code","b":[24],"m":"clc","x":[44606]},{"a":44617,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":44620,"t":"code","b":[101,134],"m":"adc","oa":134,"o":"zpa_86"},{"a":44622,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":44625,"t":"code","b":[36,134],"m":"bit","oa":134,"o":"zpa_86"},{"a":44627,"t":"code","b":[48,11],"m":"bmi","oa":44640,"o":"b_AE60"},{"a":44629,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":44632,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":44634,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":44637,"t":"code","b":[76,104,174],"m":"jmp","oa":44648,"o":"j_AE68"},{"a":44640,"l":"b_AE60","t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x","x":[44627]},{"a":44643,"t":"code","b":[105,255],"m":"adc","o":"#$FF"},{"a":44645,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":44648,"l":"j_AE68","t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x","x":[44637]},{"a":44651,"t":"code","b":[240,30],"m":"beq","oa":44683,"o":"b_AE8B"},{"a":44653,"t":"code","b":[48,28],"m":"bmi","oa":44683,"o":"b_AE8B"},{"a":44655,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":44657,"t":"code","b":[176,24],"m":"bcs","oa":44683,"o":"b_AE8B"},{"a":44659,"t":"code","b":[56],"m":"sec"},{"a":44660,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":44663,"t":"code","b":[229,87],"m":"sbc","oa":87,"o":"zpa_57"},{"a":44665,"t":"code","b":[48,7],"m":"bmi","oa":44674,"o":"b_AE82"},{"a":44667,"t":"code","b":[201,30],"m":"cmp","o":"#$1E"},{"a":44669,"t":"code","b":[144,12],"m":"bcc","oa":44683,"o":"b_AE8B"},{"a":44671,"t":"code","b":[76,136,174],"m":"jmp","oa":44680,"o":"j_AE88"},{"a":44674,"l":"b_AE82","t":"code","b":[254,122,11],"m":"inc","oa":2938,"o":"actor_alt,x","x":[44665]},{"a":44677,"t":"code","b":[76,139,174],"m":"jmp","oa":44683,"o":"b_AE8B"},{"a":44680,"l":"j_AE88","t":"code","b":[222,122,11],"m":"dec","oa":2938,"o":"actor_alt,x","x":[44671]},{"a":44683,"l":"b_AE8B","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[44651,44653,44657,44669,44677]},{"a":44685,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":44688,"t":"code","b":[240,12],"m":"beq","oa":44702,"o":"b_AE9E"},{"a":44690,"t":"code","b":[48,10],"m":"bmi","oa":44702,"o":"b_AE9E"},{"a":44692,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":44694,"t":"code","b":[176,3],"m":"bcs","oa":44699,"o":"b_AE9B"},{"a":44696,"t":"code","b":[76,137,175],"m":"jmp","oa":44937,"o":"j_AF89"},{"a":44699,"l":"b_AE9B","t":"code","b":[76,79,175],"m":"jmp","oa":44879,"o":"j_AF4F","x":[44694]},{"a":44702,"l":"b_AE9E","t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61","x":[44688,44690]},{"a":44704,"t":"code","b":[208,7],"m":"bne","oa":44713,"o":"b_AEA9"},{"a":44706,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":44709,"t":"code","b":[201,17],"m":"cmp","o":"#$11"},{"a":44711,"t":"code","b":[144,3],"m":"bcc","oa":44716,"o":"b_AEAC"},{"a":44713,"l":"b_AEA9","t":"code","b":[76,66,175],"m":"jmp","oa":44866,"o":"j_AF42","x":[44704]},{"a":44716,"l":"b_AEAC","t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52","x":[44711]},{"a":44718,"t":"code","b":[16,2],"m":"bpl","oa":44722,"o":"b_AEB2"},{"a":44720,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44722,"l":"b_AEB2","t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D","x":[44718]},{"a":44724,"t":"code","b":[56],"m":"sec"},{"a":44725,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":44728,"t":"code","b":[229,85],"m":"sbc","oa":85,"o":"world_x"},{"a":44730,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":44732,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":44735,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":44737,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":44739,"t":"code","b":[240,18],"m":"beq","oa":44759,"o":"b_AED7"},{"a":44741,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":44743,"t":"code","b":[240,25],"m":"beq","oa":44770,"o":"b_AEE2"},{"a":44745,"t":"code","b":[201,254],"m":"cmp","o":"#$FE"},{"a":44747,"t":"code","b":[240,21],"m":"beq","oa":44770,"o":"b_AEE2"},{"a":44749,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":44751,"t":"code","b":[208,113],"m":"bne","oa":44866,"o":"j_AF42"},{"a":44753,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":44755,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44757,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":44759,"l":"b_AED7","t":"code","b":[165,141],"m":"lda","oa":141,"o":"zpa_8D","x":[44739]},{"a":44761,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44762,"t":"code","b":[10],"m":"asl","o":"a"},{"a":44763,"t":"code","b":[24],"m":"clc"},{"a":44764,"t":"code","b":[105,152],"m":"adc","o":"#$98"},{"a":44766,"t":"code","b":[197,111],"m":"cmp","oa":111,"o":"zpa_6F"},{"a":44768,"t":"code","b":[176,30],"m":"bcs","oa":44800,"o":"b_AF00"},{"a":44770,"l":"b_AEE2","t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52","x":[44743,44747]},{"a":44772,"t":"code","b":[93,119,11],"m":"eor","oa":2935,"o":"actor_frame,x"},{"a":44775,"t":"code","b":[16,60],"m":"bpl","oa":44837,"o":"b_AF25"},{"a":44777,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":44780,"t":"code","b":[48,9],"m":"bmi","oa":44791,"o":"b_AEF7"},{"a":44782,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":44784,"t":"code","b":[201,20],"m":"cmp","o":"#$14"},{"a":44786,"t":"code","b":[176,52],"m":"bcs","oa":44840,"o":"b_AF28"},{"a":44788,"t":"code","b":[76,37,175],"m":"jmp","oa":44837,"o":"b_AF25"},{"a":44791,"l":"b_AEF7","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[44780]},{"a":44793,"t":"code","b":[201,15],"m":"cmp","o":"#$0F"},{"a":44795,"t":"code","b":[176,56],"m":"bcs","oa":44853,"o":"b_AF35"},{"a":44797,"t":"code","b":[76,37,175],"m":"jmp","oa":44837,"o":"b_AF25"},{"a":44800,"l":"b_AF00","t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x","x":[44768]},{"a":44803,"t":"code","b":[16,3],"m":"bpl","oa":44808,"o":"b_AF08"},{"a":44805,"t":"code","b":[76,53,175],"m":"jmp","oa":44853,"o":"b_AF35"},{"a":44808,"l":"b_AF08","t":"code","b":[165,112],"m":"lda","oa":112,"o":"zpa_70","x":[44803]},{"a":44810,"t":"code","b":[93,119,11],"m":"eor","oa":2935,"o":"actor_frame,x"},{"a":44813,"t":"code","b":[16,25],"m":"bpl","oa":44840,"o":"b_AF28"},{"a":44815,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":44817,"t":"code","b":[201,64],"m":"cmp","o":"#$40"},{"a":44819,"t":"code","b":[176,16],"m":"bcs","oa":44837,"o":"b_AF25"},{"a":44821,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":44823,"t":"code","b":[201,9],"m":"cmp","o":"#$09"},{"a":44825,"t":"code","b":[144,10],"m":"bcc","oa":44837,"o":"b_AF25"},{"a":44827,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":44829,"t":"code","b":[93,119,11],"m":"eor","oa":2935,"o":"actor_frame,x"},{"a":44832,"t":"code","b":[16,19],"m":"bpl","oa":44853,"o":"b_AF35"},{"a":44834,"t":"code","b":[76,40,175],"m":"jmp","oa":44840,"o":"b_AF28"},{"a":44837,"l":"b_AF25","t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1","x":[44775,44788,44797,44819,44825]},{"a":44840,"l":"b_AF28","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[44786,44813,44834]},{"a":44842,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":44845,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":44847,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":44850,"t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1"},{"a":44853,"l":"b_AF35","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[44795,44805,44832]},{"a":44855,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":44858,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":44860,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":44863,"t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1"},{"a":44866,"l":"j_AF42","t":"code","b":[169,4],"m":"lda","o":"#$04","x":[44713,44751]},{"a":44868,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":44871,"t":"code","b":[169,5],"m":"lda","o":"#$05"},{"a":44873,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":44876,"t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1"},{"a":44879,"l":"j_AF4F","t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x","x":[44699]},{"a":44882,"t":"code","b":[208,16],"m":"bne","oa":44900,"o":"b_AF64"},{"a":44884,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":44887,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":44889,"t":"code","b":[208,6],"m":"bne","oa":44897,"o":"b_AF61"},{"a":44891,"t":"code","b":[32,101,182],"m":"jsr","oa":46693,"o":"jet_fire_rockets"},{"a":44894,"t":"code","b":[76,100,175],"m":"jmp","oa":44900,"o":"b_AF64"},{"a":44897,"l":"b_AF61","t":"code","b":[32,237,182],"m":"jsr","oa":46829,"o":"jet_fire_shell","x":[44889]},{"a":44900,"l":"b_AF64","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[44882,44894]},{"a":44902,"t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x"},{"a":44905,"t":"code","b":[24],"m":"clc"},{"a":44906,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":44908,"t":"code","b":[188,117,11],"m":"ldy","oa":2933,"o":"actor_vx,x"},{"a":44911,"t":"code","b":[217,138,173],"m":"cmp","oa":44426,"o":"jet_state_frame_counts,y"},{"a":44914,"t":"code","b":[240,6],"m":"beq","oa":44922,"o":"b_AF7A"},{"a":44916,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":44919,"t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1"},{"a":44922,"l":"b_AF7A","t":"code","b":[44,80,11],"m":"bit","oa":2896,"o":"a_0B50","x":[44914]},{"a":44925,"t":"code","b":[16,7],"m":"bpl","oa":44934,"o":"b_AF86"},{"a":44927,"t":"code","b":[32,245,181],"m":"jsr","oa":46581,"o":"jet_list_remove"},{"a":44930,"t":"code","b":[32,55,169],"m":"jsr","oa":43319,"o":"actor_free"},{"a":44933,"t":"code","b":[96],"m":"rts"},{"a":44934,"l":"b_AF86","t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1","x":[44925]},{"a":44937,"l":"j_AF89","t":"code","b":[254,118,11],"m":"inc","oa":2934,"o":"actor_vy,x","x":[44696]},{"a":44940,"t":"code","b":[188,117,11],"m":"ldy","oa":2933,"o":"actor_vx,x"},{"a":44943,"t":"code","b":[185,138,173],"m":"lda","oa":44426,"o":"jet_state_frame_counts,y"},{"a":44946,"t":"code","b":[221,118,11],"m":"cmp","oa":2934,"o":"actor_vy,x"},{"a":44949,"t":"code","b":[240,3],"m":"beq","oa":44954,"o":"b_AF9A"},{"a":44951,"t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1"},{"a":44954,"l":"b_AF9A","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[44949]},{"a":44956,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":44959,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":44961,"t":"code","b":[208,8],"m":"bne","oa":44971,"o":"b_AFAB"},{"a":44963,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":44966,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":44968,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":44971,"l":"b_AFAB","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[44961]},{"a":44973,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":44976,"t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up"},{"a":44978,"t":"code","b":[240,8],"m":"beq","oa":44988,"o":"b_AFBC"},{"a":44980,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":44982,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":44985,"t":"code","b":[76,193,175],"m":"jmp","oa":44993,"o":"r_AFC1"},{"a":44988,"l":"b_AFBC","t":"code","b":[169,4],"m":"lda","o":"#$04","x":[44978]},{"a":44990,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":44993,"l":"r_AFC1","t":"code","b":[96],"m":"rts","x":[44837,44850,44863,44876,44919,44934,44951,44985]},{"a":44994,"l":"jet_script_lo","c":"Low bytes of the five animation-script pointers $AD8F uses, one per jet state: $94E3, $94E7, $952F, $956B, $956B (states 3 and 4 share a script). Each script is four bytes a frame - shape sub-index, horizontal step, field +6 step, field +7 step.","t":"word","b":[227],"d":[],"x":[44438]},{"a":44995,"l":"jet_script_hi","c":"High bytes of the same five script pointers; $AD96 and $AD9B read $AFC2,y and $AFC3,y with y = 2*state as one little-endian word into $6F/$70.","t":"word","b":[148,231,148,47,149,107,149,107],"d":[59284,12180,27541,27541],"x":[44443]},{"a":45003,"t":"word","b":[149],"d":[]},{"a":45004,"l":"jet_shape_base_lo","c":"Low bytes of the five shape-base pointers $AD8F uses, one per jet state: $8037, $8039, $8047, $8051, $8051. These are addresses inside the shape pointer table at $8009, so they name shape indices 23 (the cruising jet), 24, 31 and 36; the script's sub-index is added on top.","t":"word","b":[55],"d":[],"x":[44479]},{"a":45005,"l":"jet_shape_base_hi","c":"High bytes of the same five shape-base pointers; $ADBF and $ADC4 read $AFCC,y and $AFCD,y with y = 2*state into $6F/$70, and the sub-index in $0B51 then indexes that as a table of shape pointers.","t":"word","b":[128,57,128,71,128,81,128,81],"d":[14720,18304,20864,20864],"x":[44484]},{"a":45013,"t":"word","b":[128],"d":[]},{"a":45014,"l":"actor_helicopter","c":"Actor handler 0, the player's helicopter - entry 0 of the dispatch table at $B32E. First it copies the flight variables into the actor record so everything that reads actor records sees the machine where it is drawn: world X $55/$56 into fields +4/+5, the altitude $57 minus the settle counter $62 into field +6, and the constant ground base $58 (always $16) into field +7. Then it draws the machine in three pieces - $AAC2 the body, $ABCD the main rotor, $AC4A the tail rotor - and queues a colour stripe of class 0 at the actor's own position ($A9A0 with X and Y both zero, then $AA38 with A = 0); class 0 is the one case $BC29 special-cases, moving it $16 left and $0E up before it is painted. The routine then runs on past $B000, where it handles the fire button, the shot it creates at $B00F, the wreck animation while $61 is set, and finally the flight update $A4C7.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45016,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":45018,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":45021,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":45023,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":45026,"t":"code","b":[56],"m":"sec"},{"a":45027,"s":"drawn altitude = $57 - $62, so the helicopter sinks while it settles","t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":45029,"t":"code","b":[229,98],"m":"sbc","oa":98,"o":"zpa_62"},{"a":45031,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45034,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":45036,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":45039,"t":"code","b":[32,194,170],"m":"jsr","oa":43714,"o":"draw_heli_body"},{"a":45042,"t":"code","b":[32,205,171],"m":"jsr","oa":43981,"o":"draw_heli_rotor"},{"a":45045,"t":"code","b":[32,74,172],"m":"jsr","oa":44106,"o":"draw_heli_tail_rotor"},{"a":45048,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45050,"t":"code","b":[170],"m":"tax"},{"a":45051,"t":"code","b":[168],"m":"tay"},{"a":45052,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":45055,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45057,"l":"heli_actor_fire","c":"Second half of the actor handler for type 0, the player's helicopter, whose entry is $AFD6. $AFD6 copied the live machine's position into the actor record ($55/$56 world X, $57 height, $58 base row), drew it, and queued its dirty rectangle with size code 0 (7x23 cells). Here: if bit 7 of $64 is set, the fire button latched at $97E7, the flag is cleared, the shot is counted in $0CF3, $A951 takes a slot off the free list and it is made actor type 6. $ACB7 looks the muzzle offset up in the table at $9391 by the current aim pair ($59, $5A); that offset plus one is subtracted from the helicopter's world X and its Y part added to the height, the base row is copied from $58, $AD24 sets the shot's velocity and $A95B links it in. Then $B04E: with $61 clear the routine just falls out through $B0CE, otherwise the helicopter has been destroyed and $5D picks the airborne death at $B059 or the burning wreck at $B08D.","t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":45060,"t":"code","b":[36,100],"m":"bit","oa":100,"o":"fire_latch"},{"a":45062,"t":"code","b":[16,70],"m":"bpl","oa":45134,"o":"b_B04E"},{"a":45064,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45066,"t":"code","b":[133,100],"m":"sta","oa":100,"o":"fire_latch"},{"a":45068,"t":"code","b":[238,243,12],"m":"inc","oa":3315,"o":"shots_in_flight"},{"a":45071,"t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc"},{"a":45074,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45076,"t":"code","b":[169,6],"m":"lda","o":"#$06"},{"a":45078,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":45081,"t":"code","b":[32,183,172],"m":"jsr","oa":44215,"o":"heli_muzzle_offset"},{"a":45084,"t":"code","b":[232],"m":"inx"},{"a":45085,"t":"code","b":[134,134],"m":"stx","oa":134,"o":"zpa_86"},{"a":45087,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45089,"t":"code","b":[56],"m":"sec"},{"a":45090,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":45092,"t":"code","b":[229,134],"m":"sbc","oa":134,"o":"zpa_86"},{"a":45094,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":45097,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":45099,"t":"code","b":[36,134],"m":"bit","oa":134,"o":"zpa_86"},{"a":45101,"t":"code","b":[48,8],"m":"bmi","oa":45111,"o":"b_B037"},{"a":45103,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":45105,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":45108,"t":"code","b":[76,60,176],"m":"jmp","oa":45116,"o":"j_B03C"},{"a":45111,"l":"b_B037","t":"code","b":[233,255],"m":"sbc","o":"#$FF","x":[45101]},{"a":45113,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":45116,"l":"j_B03C","t":"code","b":[24],"m":"clc","x":[45108]},{"a":45117,"t":"code","b":[152],"m":"tya"},{"a":45118,"t":"code","b":[101,87],"m":"adc","oa":87,"o":"zpa_57"},{"a":45120,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45123,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":45125,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":45128,"t":"code","b":[32,36,173],"m":"jsr","oa":44324,"o":"shot_velocity_from_heli"},{"a":45131,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":45134,"l":"b_B04E","t":"code","b":[165,97],"m":"lda","oa":97,"o":"zpa_61","x":[45062]},{"a":45136,"t":"code","b":[208,3],"m":"bne","oa":45141,"o":"b_B055"},{"a":45138,"t":"code","b":[76,206,176],"m":"jmp","oa":45262,"o":"j_B0CE"},{"a":45141,"l":"b_B055","t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up","x":[45136]},{"a":45143,"t":"code","b":[240,52],"m":"beq","oa":45197,"o":"b_B08D"},{"a":45145,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":45148,"t":"code","b":[41,3],"m":"and","o":"#$03"},{"a":45150,"t":"code","b":[10],"m":"asl","o":"a"},{"a":45151,"t":"code","b":[170],"m":"tax"},{"a":45152,"t":"code","b":[189,111,128],"m":"lda","oa":32879,"o":"shape_ptr_blast,x"},{"a":45155,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":45157,"t":"code","b":[189,112,128],"m":"lda","oa":32880,"o":"shape_ptr_blast_hi,x"},{"a":45160,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":45162,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":45165,"t":"gap","n":2},{"a":45167,"l":"heli_airburst_draw","c":"Death sequence for a helicopter destroyed while still in the air ($61 set, $5D = 1). $B059 has just picked one of the four explosion-cloud shapes, table entries 51 to 54 read through $806F, using $DC04 as the random source. Its header gives the width and height in bits and rows; half of each goes to $A9A0 so the cloud is centred on the helicopter and its world X rounded to an even bitmap column, and $8BF9 hands the position to the blitter. Continues at $B084.","t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":45169,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":45171,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":45172,"t":"code","b":[170],"m":"tax"},{"a":45173,"t":"code","b":[200],"m":"iny"},{"a":45174,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":45176,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":45177,"t":"code","b":[168],"m":"tay"},{"a":45178,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":45180,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":45183,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":45186,"t":"gap","n":2},{"a":45188,"l":"heli_wreck","c":"Blits the random explosion cloud over the dying helicopter and returns through $B0CE. The carry from $8F03 is deliberately not tested and no $AA38 entry is made, because the helicopter's own dirty rectangle already covers the cloud. The other half of the death sequence is at $B08D, taken when the wreck is on the ground ($5D = 0): once a frame it allocates a slot, puts it eight world units to the left of the helicopter plus a random 0 to 15, at height 0 on base row $58, and $B2EA turns it into a ground burst, so the wreck goes on throwing up explosions. $B0CE then runs the helicopter's own flight model at $A4C7.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":45191,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":45194,"t":"code","b":[76,206,176],"m":"jmp","oa":45262,"o":"j_B0CE"},{"a":45197,"l":"b_B08D","t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc","x":[45143]},{"a":45200,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45202,"t":"code","b":[56],"m":"sec"},{"a":45203,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":45205,"t":"code","b":[233,8],"m":"sbc","o":"#$08"},{"a":45207,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":45210,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":45212,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":45214,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":45217,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":45220,"t":"code","b":[41,15],"m":"and","o":"#$0F"},{"a":45222,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45224,"t":"code","b":[24],"m":"clc"},{"a":45225,"t":"code","b":[125,120,11],"m":"adc","oa":2936,"o":"actor_x,x"},{"a":45228,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":45231,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":45234,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":45236,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":45239,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45241,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45244,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":45246,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":45249,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":45252,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45254,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":45256,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":45259,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":45262,"l":"j_B0CE","t":"code","b":[32,199,164],"m":"jsr","oa":42183,"o":"heli_update","x":[45138,45194]},{"a":45265,"t":"code","b":[96],"m":"rts"},{"a":45266,"l":"count_person_lost","c":"Adds one, in BCD, to the two-digit counter held in $0CFC and repaints it in the first field of the top bar through $A978, which writes screen $045A and $445A. The first call in a frame - $0D02 is zeroed once per frame at $9676 - also plays three falling notes on SID voice 3, $A7C7 with frequency high bytes $60, $54 and $39. Called from $B63E and from the identical code at $9E14, the two places a person in the $0CA0 array is killed. X and Y are saved in $84/$85.","t":"code","b":[134,132],"m":"stx","oa":132,"o":"zpa_84","x":[40479,46665]},{"a":45268,"t":"code","b":[132,133],"m":"sty","oa":133,"o":"zpa_85"},{"a":45270,"t":"code","b":[248],"m":"sed"},{"a":45271,"t":"code","b":[24],"m":"clc"},{"a":45272,"t":"code","b":[173,252,12],"m":"lda","oa":3324,"o":"a_0CFC"},{"a":45275,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":45277,"t":"code","b":[141,252,12],"m":"sta","oa":3324,"o":"a_0CFC"},{"a":45280,"t":"code","b":[216],"m":"cld"},{"a":45281,"t":"code","b":[162,0],"m":"ldx","o":"#$00"},{"a":45283,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":45286,"t":"code","b":[44,2,13],"m":"bit","oa":3330,"o":"a_0D02"},{"a":45289,"t":"code","b":[48,22],"m":"bmi","oa":45313,"o":"b_B101"},{"a":45291,"t":"code","b":[162,96],"m":"ldx","o":"#$60"},{"a":45293,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":45295,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":45298,"t":"code","b":[162,84],"m":"ldx","o":"#$54"},{"a":45300,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":45303,"t":"code","b":[162,57],"m":"ldx","o":"#$39"},{"a":45305,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":45308,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":45310,"t":"code","b":[141,2,13],"m":"sta","oa":3330,"o":"a_0D02"},{"a":45313,"l":"b_B101","t":"code","b":[166,132],"m":"ldx","oa":132,"o":"zpa_84","x":[45289]},{"a":45315,"t":"code","b":[164,133],"m":"ldy","oa":133,"o":"zpa_85"},{"a":45317,"t":"code","b":[96],"m":"rts"},{"a":45318,"l":"act_explosion","c":"Actor handler for types 1 and 2, the explosion cloud: type 1 is a burst in the air, type 2 a burst sitting on the ground, and $B2EA chooses between them from the height. $0B75 is the animation frame 0 to 3 and selects shape table entry 51 + frame through $806F, the four frames of the expanding and dissipating cloud. The type is compared with 2 and the flags pushed across the shape lookup, so that a ground burst gets four extra rows of lift and sits on the ground instead of half inside it. Continues at $B122.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45320,"t":"code","b":[189,116,11],"m":"lda","oa":2932,"o":"actor_type,x"},{"a":45323,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":45325,"t":"code","b":[8],"m":"php"},{"a":45326,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":45329,"t":"code","b":[10],"m":"asl","o":"a"},{"a":45330,"t":"code","b":[168],"m":"tay"},{"a":45331,"t":"code","b":[185,111,128],"m":"lda","oa":32879,"o":"shape_ptr_blast,y"},{"a":45334,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":45336,"t":"code","b":[185,112,128],"m":"lda","oa":32880,"o":"shape_ptr_blast_hi,y"},{"a":45339,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":45341,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":45344,"t":"gap","n":2},{"a":45346,"l":"act_explosion_pos","c":"Reads the chosen cloud's header: half its width in bitmap columns into X and half its height in rows into A, plus the four rows of lift for a ground burst, then $A9A0 with the align flag set turns that into a screen position centred on the actor and rounded to an even bitmap column so the multicolour pixels line up. $8BF9 passes the position on. Continues at $B13E.","t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":45348,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":45350,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":45351,"t":"code","b":[170],"m":"tax"},{"a":45352,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":45354,"t":"code","b":[177,101],"m":"lda","oa":101,"o":"(shape_sel),y"},{"a":45356,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":45357,"t":"code","b":[40],"m":"plp"},{"a":45358,"t":"code","b":[208,3],"m":"bne","oa":45363,"o":"b_B133"},{"a":45360,"t":"code","b":[24],"m":"clc"},{"a":45361,"t":"code","b":[105,4],"m":"adc","o":"#$04"},{"a":45363,"l":"b_B133","t":"code","b":[168],"m":"tay","x":[45358]},{"a":45364,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":45366,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":45369,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":45372,"t":"gap","n":2},{"a":45374,"l":"act_explosion_blit","c":"Drops the SID master volume to 3 at $D418 unless $62 is 6, queues the dirty rectangle with size code 5 (5x12 cells), blits the cloud and puts the volume back to 15. That pair of writes happens once a frame for every explosion on screen and is the only sound this handler makes; the audible result is the click a bare write to the volume register produces, and why it is done from the drawing code rather than from the sound code is not clear. $0B75 is then advanced and on the fourth frame the actor unlinks itself through $A937.","t":"code","b":[165,98],"m":"lda","oa":98,"o":"zpa_62"},{"a":45376,"t":"code","b":[201,6],"m":"cmp","o":"#$06"},{"a":45378,"t":"code","b":[240,5],"m":"beq","oa":45385,"o":"b_B149"},{"a":45380,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":45382,"t":"code","b":[141,24,212],"m":"sta","oa":54296,"o":"$D418"},{"a":45385,"l":"b_B149","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object","x":[45378]},{"a":45388,"t":"code","b":[176,8],"m":"bcs","oa":45398,"o":"b_B156"},{"a":45390,"t":"code","b":[169,5],"m":"lda","o":"#$05"},{"a":45392,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":45395,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":45398,"l":"b_B156","t":"code","b":[169,15],"m":"lda","o":"#$0F","x":[45388]},{"a":45400,"t":"code","b":[141,24,212],"m":"sta","oa":54296,"o":"$D418"},{"a":45403,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45405,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":45408,"t":"code","b":[24],"m":"clc"},{"a":45409,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":45411,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":45413,"t":"code","b":[240,4],"m":"beq","oa":45419,"o":"b_B16B"},{"a":45415,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":45418,"t":"code","b":[96],"m":"rts"},{"a":45419,"l":"b_B16B","t":"code","b":[76,55,169],"m":"jmp","oa":43319,"o":"actor_free","x":[45413]},{"a":45422,"l":"act_heli_shot","c":"Actor handler for type 6, a shot fired by the player's helicopter and created at $B008. Draws shape table entry 46, the two-pixel bullet, one bitmap column left of the actor and one row above it, with dirty-rectangle size code $0E. Continues at $B181.","t":"code","b":[162,1],"m":"ldx","o":"#$01"},{"a":45424,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":45426,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45428,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":45431,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":45434,"t":"gap","n":2},{"a":45436,"l":"act_heli_shot_shape","c":"Inline parameter of the $8BE0 call above: $37/$38 is loaded with the word at $8065, which is entry 46 of the shape table at $8009 and points at the bullet bitmap at $8812.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":45439,"t":"gap","n":2},{"a":45441,"l":"act_heli_shot_move","c":"Moves and retires the player's shot. $B2AA is called with a fall rate of 0 when $0B77 is zero and 2 otherwise. $AD24 set $0B77 from the table at $AD86 indexed by the magnitude of $59, the helicopter's turn position, which runs -3 to +3 with 0 the head-on view; the values are -2, -2, -1, 0, so only a shot fired with the machine fully side on ($59 = +/-3) flies level and keeps its base row. Every other shot loses one or two rows of base row per frame as well as falling, and the moment its $0B7B stops matching $58 the collision test at $B344 rejects it on its first line: that is how shots fired while the helicopter is turned towards the viewer hit nothing. Watching a shot fired head-on in the emulator shows exactly that, $0B77 = $FE with the base row walking down 2 a frame. The shot is discarded if its world X high byte has left the helicopter's by more than one (the compare at $B19F has no preceding sec, so the difference can be one out), its base row is clamped up to 3, and the height then decides: under 4 or wrapped past $E0 it explodes on the ground unless it is already at base row 3, over $90 it is simply thrown away, and in between it goes to $B344 to look for a target. Every exit decrements the in-flight count $0CF3.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":45444,"t":"code","b":[176,8],"m":"bcs","oa":45454,"o":"b_B18E"},{"a":45446,"t":"code","b":[169,14],"m":"lda","o":"#$0E"},{"a":45448,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":45451,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":45454,"l":"b_B18E","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[45444]},{"a":45456,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":45459,"t":"code","b":[240,2],"m":"beq","oa":45463,"o":"b_B197"},{"a":45461,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":45463,"l":"b_B197","t":"code","b":[32,170,178],"m":"jsr","oa":45738,"o":"actor_step","x":[45459]},{"a":45466,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45468,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":45471,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":45473,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":45475,"t":"code","b":[144,7],"m":"bcc","oa":45484,"o":"b_B1AC"},{"a":45477,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":45479,"t":"code","b":[240,3],"m":"beq","oa":45484,"o":"b_B1AC"},{"a":45481,"t":"code","b":[76,225,177],"m":"jmp","oa":45537,"o":"j_B1E1"},{"a":45484,"l":"b_B1AC","t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x","x":[45475,45479]},{"a":45487,"t":"code","b":[48,4],"m":"bmi","oa":45493,"o":"b_B1B5"},{"a":45489,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":45491,"t":"code","b":[176,5],"m":"bcs","oa":45498,"o":"b_B1BA"},{"a":45493,"l":"b_B1B5","t":"code","b":[169,3],"m":"lda","o":"#$03","x":[45487]},{"a":45495,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":45498,"l":"b_B1BA","t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x","x":[45491]},{"a":45501,"t":"code","b":[201,224],"m":"cmp","o":"#$E0"},{"a":45503,"t":"code","b":[176,11],"m":"bcs","oa":45516,"o":"b_B1CC"},{"a":45505,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":45507,"t":"code","b":[144,7],"m":"bcc","oa":45516,"o":"b_B1CC"},{"a":45509,"t":"code","b":[201,144],"m":"cmp","o":"#$90"},{"a":45511,"t":"code","b":[176,24],"m":"bcs","oa":45537,"o":"j_B1E1"},{"a":45513,"t":"code","b":[76,68,179],"m":"jmp","oa":45892,"o":"shot_hit_test"},{"a":45516,"l":"b_B1CC","t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x","x":[45503,45507]},{"a":45519,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":45521,"t":"code","b":[240,14],"m":"beq","oa":45537,"o":"j_B1E1"},{"a":45523,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45525,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45528,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":45531,"t":"code","b":[206,243,12],"m":"dec","oa":3315,"o":"shots_in_flight"},{"a":45534,"t":"code","b":[76,175,180],"m":"jmp","oa":46255,"o":"ground_burst_effects"},{"a":45537,"l":"j_B1E1","t":"code","b":[32,55,169],"m":"jsr","oa":43319,"o":"actor_free","x":[45481,45511,45521]},{"a":45540,"t":"code","b":[206,243,12],"m":"dec","oa":3315,"o":"shots_in_flight"},{"a":45543,"t":"code","b":[96],"m":"rts"},{"a":45544,"l":"act_jet_shell","c":"Actor handler for type 5, the single shell a jet lobs when the helicopter is on the ground; $B6ED creates it. Draws shape table entry 49, a flat four-pixel bar, four bitmap columns left of the actor, with dirty-rectangle size code $10. Continues at $B1FA.","t":"code","b":[162,4],"m":"ldx","o":"#$04"},{"a":45546,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45548,"t":"code","b":[168],"m":"tay"},{"a":45549,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":45552,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":45555,"t":"gap","n":2},{"a":45557,"l":"act_jet_shell_shape","c":"Inline parameter of the $8BE0 call above: $37/$38 is loaded with the word at $806B, entry 49 of the shape table, the flat bar at $8824.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":45560,"t":"gap","n":2},{"a":45562,"l":"act_jet_shell_move","c":"Steps the jet's shell with a fall rate of 4, the heaviest in the game, so it drops steeply. The shell has no collision test of its own; the only thing that happens to it is that its height wraps past $A0, whereupon the height is zeroed, $B2EA turns it into a ground explosion and $B4AF works out what that burst lands on. Since $B4AF only hurts the helicopter when $5D says it is on the ground, this shell can kill only a landed machine, which is exactly the case in which the jet chooses to fire it.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":45565,"t":"code","b":[176,8],"m":"bcs","oa":45575,"o":"b_B207"},{"a":45567,"t":"code","b":[169,16],"m":"lda","o":"#$10"},{"a":45569,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":45572,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":45575,"l":"b_B207","t":"code","b":[169,4],"m":"lda","o":"#$04","x":[45565]},{"a":45577,"t":"code","b":[32,170,178],"m":"jsr","oa":45738,"o":"actor_step"},{"a":45580,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45582,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":45585,"t":"code","b":[201,160],"m":"cmp","o":"#$A0"},{"a":45587,"t":"code","b":[176,1],"m":"bcs","oa":45590,"o":"b_B216"},{"a":45589,"t":"code","b":[96],"m":"rts"},{"a":45590,"l":"b_B216","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[45587]},{"a":45592,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45595,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":45598,"t":"code","b":[76,175,180],"m":"jmp","oa":46255,"o":"ground_burst_effects"},{"a":45601,"l":"act_jet_rocket","c":"Actor handler for type 4, one of the pair of rockets a jet fires head on while the helicopter is airborne; $B665 creates two at a time, one above and one below the aircraft. Draws shape table entry 48, a five-pixel finned round, four bitmap columns left of the actor and one row up, with dirty-rectangle size code $0F, blitted mirrored through $903E when the horizontal velocity $0B75 is negative so the rocket points the way it is going. Continues at $B233.","t":"code","b":[162,4],"m":"ldx","o":"#$04"},{"a":45603,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":45605,"t":"code","b":[168],"m":"tay"},{"a":45606,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":45609,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":45612,"t":"gap","n":2},{"a":45614,"l":"act_jet_rocket_shape","c":"Inline parameter of the $8BE0 call above: $37/$38 is loaded with the word at $8069, entry 48 of the shape table, the finned round at $881C.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":45617,"t":"gap","n":2},{"a":45619,"l":"act_jet_rocket_move","c":"Steps the rocket with a fall rate of 1, so it flies almost flat at its 24 world units a frame, then tests it against the helicopter at $B433 while its height is between 3 and $9F. Outside that band the height is zeroed, $B2EA turns the rocket into a ground explosion and $B4AF decides what the burst hit.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":45622,"t":"code","b":[176,21],"m":"bcs","oa":45645,"o":"b_B24D"},{"a":45624,"t":"code","b":[169,15],"m":"lda","o":"#$0F"},{"a":45626,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":45629,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45631,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":45634,"t":"code","b":[48,6],"m":"bmi","oa":45642,"o":"b_B24A"},{"a":45636,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":45639,"t":"code","b":[76,77,178],"m":"jmp","oa":45645,"o":"b_B24D"},{"a":45642,"l":"b_B24A","t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored","x":[45634]},{"a":45645,"l":"b_B24D","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[45622,45639]},{"a":45647,"t":"code","b":[32,170,178],"m":"jsr","oa":45738,"o":"actor_step"},{"a":45650,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45652,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":45655,"t":"code","b":[201,160],"m":"cmp","o":"#$A0"},{"a":45657,"t":"code","b":[176,7],"m":"bcs","oa":45666,"o":"b_B262"},{"a":45659,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":45661,"t":"code","b":[144,3],"m":"bcc","oa":45666,"o":"b_B262"},{"a":45663,"t":"code","b":[76,51,180],"m":"jmp","oa":46131,"o":"rocket_hits_heli"},{"a":45666,"l":"b_B262","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[45657,45661]},{"a":45668,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45671,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":45674,"t":"code","b":[76,175,180],"m":"jmp","oa":46255,"o":"ground_burst_effects"},{"a":45677,"l":"act_shell","c":"Actor handler for type 8, the arcing shell. Two things fire it: a tank, at $A2C4, which launches it one row above and one base row in front of itself with a velocity triple taken from the tables at $A354, $A359 and $A35E, and the homing mine at $B848, which lets one go straight down. Draws shape table entry 47, a one-pixel vertical dash, on the actor's own position with dirty-rectangle size code $0D. Continues at $B27E.","t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45679,"t":"code","b":[170],"m":"tax"},{"a":45680,"t":"code","b":[168],"m":"tay"},{"a":45681,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":45684,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":45687,"t":"gap","n":2},{"a":45689,"l":"act_shell_shape","c":"Inline parameter of the $8BE0 call above: $37/$38 is loaded with the word at $8067, entry 47 of the shape table, the vertical dash at $8817.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":45692,"t":"gap","n":2},{"a":45694,"l":"act_shell_move","c":"Steps the shell with a fall rate of 3. Because $B2AA also adds $0B77 to the base row every frame, a tank's shell climbs out of the tanks' rows, 5 to 12, towards the helicopter's plane at $58 = 22 as it travels, which is how the game fakes depth. The shell itself tests nothing: when its height reaches zero or goes negative it is snapped to height 0 on base row $58, $B2EA turns it into a ground explosion and $B4AF takes over.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":45697,"t":"code","b":[176,8],"m":"bcs","oa":45707,"o":"b_B28B"},{"a":45699,"t":"code","b":[169,13],"m":"lda","o":"#$0D"},{"a":45701,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":45704,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":45707,"l":"b_B28B","t":"code","b":[169,3],"m":"lda","o":"#$03","x":[45697]},{"a":45709,"t":"code","b":[32,170,178],"m":"jsr","oa":45738,"o":"actor_step"},{"a":45712,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45714,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":45717,"t":"code","b":[240,3],"m":"beq","oa":45722,"o":"b_B29A"},{"a":45719,"t":"code","b":[48,1],"m":"bmi","oa":45722,"o":"b_B29A"},{"a":45721,"t":"code","b":[96],"m":"rts"},{"a":45722,"l":"b_B29A","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[45717,45719]},{"a":45724,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45727,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":45729,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":45732,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":45735,"t":"code","b":[76,175,180],"m":"jmp","oa":46255,"o":"ground_burst_effects"},{"a":45738,"l":"actor_step","c":"One frame of ballistic movement for the actor whose slot is in $72, with the fall rate in A. Adds the signed horizontal velocity $0B75 to the 16-bit world X in $0B78/$0B79, adds the vertical velocity $0B76 to the height $0B7A and the depth step $0B77 to the base row $0B7B - the two vertical fields are kept apart here and added together again by $A9A0 to give the bitmap row - and finally takes A off the vertical velocity so the actor falls. A is parked in $0B63. Heights count upwards from the bottom of the play area, because the row pointer table at $0A00/$0AA8 runs bottom to top.","t":"code","b":[141,99,11],"m":"sta","oa":2915,"o":"a_0B63","x":[45463,45577,45647,45709,47125]},{"a":45741,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":45743,"t":"code","b":[24],"m":"clc"},{"a":45744,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":45747,"t":"code","b":[125,117,11],"m":"adc","oa":2933,"o":"actor_vx,x"},{"a":45750,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":45753,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":45756,"t":"code","b":[188,117,11],"m":"ldy","oa":2933,"o":"actor_vx,x"},{"a":45759,"t":"code","b":[48,5],"m":"bmi","oa":45766,"o":"b_B2C6"},{"a":45761,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":45763,"t":"code","b":[76,200,178],"m":"jmp","oa":45768,"o":"j_B2C8"},{"a":45766,"l":"b_B2C6","t":"code","b":[105,255],"m":"adc","o":"#$FF","x":[45759]},{"a":45768,"l":"j_B2C8","t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x","x":[45763]},{"a":45771,"t":"code","b":[24],"m":"clc"},{"a":45772,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":45775,"t":"code","b":[125,118,11],"m":"adc","oa":2934,"o":"actor_vy,x"},{"a":45778,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45781,"t":"code","b":[24],"m":"clc"},{"a":45782,"t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x"},{"a":45785,"t":"code","b":[125,119,11],"m":"adc","oa":2935,"o":"actor_frame,x"},{"a":45788,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":45791,"t":"code","b":[56],"m":"sec"},{"a":45792,"t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x"},{"a":45795,"t":"code","b":[237,99,11],"m":"sbc","oa":2915,"o":"a_0B63"},{"a":45798,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":45801,"t":"code","b":[96],"m":"rts"},{"a":45802,"l":"actor_to_explosion","c":"Turns the actor in $72 into an explosion in place, keeping its slot, its world X and its links. Clears both velocities $0B75 and $0B76 and sets the type to 1 when the height $0B7A is non-zero, a burst in the air, or to 2 when it is zero, a burst on the ground which $B106 lifts four rows. Every projectile in the game ends this way rather than by unlinking itself.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[45249,45528,45595,45671,45732,45938,46190,46529,46629,46645,47272]},{"a":45804,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45806,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":45809,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":45812,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":45815,"t":"code","b":[240,8],"m":"beq","oa":45825,"o":"b_B301"},{"a":45817,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":45819,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":45822,"t":"code","b":[76,6,179],"m":"jmp","oa":45830,"o":"r_B306"},{"a":45825,"l":"b_B301","t":"code","b":[169,2],"m":"lda","o":"#$02","x":[45815]},{"a":45827,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":45830,"l":"r_B306","t":"code","b":[96],"m":"rts","x":[45822]},{"a":45831,"l":"actor_dispatch","c":"Walks the actor list once and runs a handler for each entry; called from $95DA once a frame and again from $96D5 and $972D. $0B7D read as a plain address is the head slot and $0B7D,x the link to the next; $0B7C,x is the back link that $A937 needs to unlink one. The next slot is copied into $73 before the handler runs so that a handler may destroy its own actor. The type in $0B74,x indexes the split address table at $B32E/$B32F, and $B328 is pushed as the return address before the indirect jump, so every handler just ends in rts and arrives at $B329.","t":"code","b":[174,125,11],"m":"ldx","oa":2941,"o":"actor_next","x":[38362,38613,38701]},{"a":45834,"l":"b_B30A","t":"code","b":[134,114],"m":"stx","oa":114,"o":"actor_slot","x":[45867]},{"a":45836,"t":"code","b":[189,125,11],"m":"lda","oa":2941,"o":"actor_next,x"},{"a":45839,"t":"code","b":[133,115],"m":"sta","oa":115,"o":"zpa_73"},{"a":45841,"t":"code","b":[189,116,11],"m":"lda","oa":2932,"o":"actor_type,x"},{"a":45844,"t":"code","b":[10],"m":"asl","o":"a"},{"a":45845,"t":"code","b":[168],"m":"tay"},{"a":45846,"t":"code","b":[185,46,179],"m":"lda","oa":45870,"o":"actor_handler_lo,y"},{"a":45849,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":45851,"t":"code","b":[185,47,179],"m":"lda","oa":45871,"o":"actor_handler_hi,y"},{"a":45854,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":45856,"t":"code","b":[169,179],"m":"lda","o":"#$B3"},{"a":45858,"t":"code","b":[72],"m":"pha"},{"a":45859,"t":"code","b":[169,40],"m":"lda","o":"#$28"},{"a":45861,"t":"code","b":[72],"m":"pha"},{"a":45862,"t":"code","b":[108,111,0],"m":"jmp","oa":111,"o":"(zpa_6F)"},{"a":45865,"l":"actor_dispatch_next","c":"Where a handler's rts lands, one byte on from the $B328 that $B307 pushed. Picks the next slot out of $73 and loops back to $B30A, or returns when the link is zero and the list is done.","t":"code","b":[166,115],"m":"ldx","oa":115,"o":"zpa_73"},{"a":45867,"t":"code","b":[208,221],"m":"bne","oa":45834,"o":"b_B30A"},{"a":45869,"t":"code","b":[96],"m":"rts"},{"a":45870,"l":"actor_handler_lo","c":"Low bytes of the eleven actor handler addresses, read at $B316 with 2*type in Y. In order: 0 $AFD6 the player's helicopter, 1 and 2 $B106 the explosion in the air and on the ground, 3 $A0BB the tank, 4 $B221 the jet's rocket, 5 $B1E8 the jet's shell, 6 $B16E the helicopter's own shot, 7 $0000, which is never reached because nothing is ever given type 7, 8 $B26D the arcing shell, 9 $AD8F the jet, 10 $B73D the homing mine.","t":"byte","b":[214],"x":[45846]},{"a":45871,"l":"actor_handler_hi","c":"High bytes of the same eleven handler addresses, read at $B31B. The table is interleaved low byte then high byte, so these two symbols are the alternate bytes of $B32E to $B343.","t":"byte","b":[175,6,177,6,177,187,160,33],"x":[45851]},{"a":45879,"t":"byte","b":[178,232,177,110,177,0,0,109]},{"a":45887,"t":"byte","b":[178,143,173,61,183]},{"a":45892,"l":"shot_hit_test","c":"Works out what the player's shot in $72 has hit; reached from $B1C9 while its height is between 4 and $8F. It gives up at once unless the shot is still on the helicopter's own base row $58, which is what makes shots fired into the screen harmless. Below height $0E it tests the four 24-unit boxes at world X $0380, $0480, $0580 and $0680, the sheds, and blows the shot up there. From height $18 up it walks the jets whose slots are listed in $0CE4 with the count in $0CE3: a jet is hit when its base row is within 8 above $58, the heights are within 8 rows and the world X within 19 bitmap columns, and $B3E1 then kills the shot and sends the jet to $B61F. Last, if a homing mine is alive ($0CE1 set, slot in $0CE2), the same test with a box of +/-16 columns and +/-8 rows sends it to $B630.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[45513]},{"a":45894,"t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x"},{"a":45897,"t":"code","b":[197,88],"m":"cmp","oa":88,"o":"ground_row"},{"a":45899,"t":"code","b":[240,3],"m":"beq","oa":45904,"o":"b_B350"},{"a":45901,"t":"code","b":[76,50,180],"m":"jmp","oa":46130,"o":"r_B432"},{"a":45904,"l":"b_B350","t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x","x":[45899]},{"a":45907,"t":"code","b":[201,14],"m":"cmp","o":"#$0E"},{"a":45909,"t":"code","b":[176,36],"m":"bcs","oa":45947,"o":"b_B37B"},{"a":45911,"t":"code","b":[56],"m":"sec"},{"a":45912,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":45915,"t":"code","b":[233,128],"m":"sbc","o":"#$80"},{"a":45917,"t":"code","b":[48,28],"m":"bmi","oa":45947,"o":"b_B37B"},{"a":45919,"t":"code","b":[201,24],"m":"cmp","o":"#$18"},{"a":45921,"t":"code","b":[176,24],"m":"bcs","oa":45947,"o":"b_B37B"},{"a":45923,"t":"code","b":[56],"m":"sec"},{"a":45924,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":45927,"t":"code","b":[233,3],"m":"sbc","o":"#$03"},{"a":45929,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":45931,"t":"code","b":[176,14],"m":"bcs","oa":45947,"o":"b_B37B"},{"a":45933,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":45935,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":45938,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":45941,"t":"code","b":[206,243,12],"m":"dec","oa":3315,"o":"shots_in_flight"},{"a":45944,"t":"code","b":[76,175,180],"m":"jmp","oa":46255,"o":"ground_burst_effects"},{"a":45947,"l":"b_B37B","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[45909,45917,45921,45931]},{"a":45949,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":45952,"t":"code","b":[201,24],"m":"cmp","o":"#$18"},{"a":45954,"t":"code","b":[144,104],"m":"bcc","oa":46060,"o":"b_B3EC"},{"a":45956,"t":"code","b":[133,135],"m":"sta","oa":135,"o":"zpa_87"},{"a":45958,"t":"code","b":[174,227,12],"m":"ldx","oa":3299,"o":"hit_list_len"},{"a":45961,"t":"code","b":[240,97],"m":"beq","oa":46060,"o":"b_B3EC"},{"a":45963,"t":"code","b":[202],"m":"dex"},{"a":45964,"l":"b_B38C","t":"code","b":[188,228,12],"m":"ldy","oa":3300,"o":"hit_list,x","x":[45992]},{"a":45967,"t":"code","b":[56],"m":"sec"},{"a":45968,"t":"code","b":[185,123,11],"m":"lda","oa":2939,"o":"actor_base_row,y"},{"a":45971,"t":"code","b":[229,88],"m":"sbc","oa":88,"o":"ground_row"},{"a":45973,"t":"code","b":[201,8],"m":"cmp","o":"#$08"},{"a":45975,"t":"code","b":[176,14],"m":"bcs","oa":45991,"o":"b_B3A7"},{"a":45977,"t":"code","b":[56],"m":"sec"},{"a":45978,"t":"code","b":[165,135],"m":"lda","oa":135,"o":"zpa_87"},{"a":45980,"t":"code","b":[249,122,11],"m":"sbc","oa":2938,"o":"actor_alt,y"},{"a":45983,"t":"code","b":[201,9],"m":"cmp","o":"#$09"},{"a":45985,"t":"code","b":[144,10],"m":"bcc","oa":45997,"o":"b_B3AD"},{"a":45987,"t":"code","b":[201,248],"m":"cmp","o":"#$F8"},{"a":45989,"t":"code","b":[176,6],"m":"bcs","oa":45997,"o":"b_B3AD"},{"a":45991,"l":"b_B3A7","t":"code","b":[202],"m":"dex","x":[45975,46024,46035,46046]},{"a":45992,"t":"code","b":[16,226],"m":"bpl","oa":45964,"o":"b_B38C"},{"a":45994,"t":"code","b":[76,236,179],"m":"jmp","oa":46060,"o":"b_B3EC"},{"a":45997,"l":"b_B3AD","t":"code","b":[134,109],"m":"stx","oa":109,"o":"zpa_6D","x":[45985,45989]},{"a":45999,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46001,"t":"code","b":[56],"m":"sec"},{"a":46002,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46005,"t":"code","b":[249,120,11],"m":"sbc","oa":2936,"o":"actor_x,y"},{"a":46008,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":46010,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46013,"t":"code","b":[249,121,11],"m":"sbc","oa":2937,"o":"actor_x_hi,y"},{"a":46016,"t":"code","b":[240,9],"m":"beq","oa":46027,"o":"b_B3CB"},{"a":46018,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":46020,"t":"code","b":[240,16],"m":"beq","oa":46038,"o":"b_B3D6"},{"a":46022,"t":"code","b":[166,109],"m":"ldx","oa":109,"o":"zpa_6D"},{"a":46024,"t":"code","b":[76,167,179],"m":"jmp","oa":45991,"o":"b_B3A7"},{"a":46027,"l":"b_B3CB","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[46016]},{"a":46029,"t":"code","b":[201,20],"m":"cmp","o":"#$14"},{"a":46031,"t":"code","b":[144,16],"m":"bcc","oa":46049,"o":"b_B3E1"},{"a":46033,"t":"code","b":[166,109],"m":"ldx","oa":109,"o":"zpa_6D"},{"a":46035,"t":"code","b":[76,167,179],"m":"jmp","oa":45991,"o":"b_B3A7"},{"a":46038,"l":"b_B3D6","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[46020]},{"a":46040,"t":"code","b":[201,237],"m":"cmp","o":"#$ED"},{"a":46042,"t":"code","b":[176,5],"m":"bcs","oa":46049,"o":"b_B3E1"},{"a":46044,"t":"code","b":[166,109],"m":"ldx","oa":109,"o":"zpa_6D"},{"a":46046,"t":"code","b":[76,167,179],"m":"jmp","oa":45991,"o":"b_B3A7"},{"a":46049,"l":"b_B3E1","t":"code","b":[32,55,169],"m":"jsr","oa":43319,"o":"actor_free","x":[46031,46042]},{"a":46052,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":46054,"t":"code","b":[206,243,12],"m":"dec","oa":3315,"o":"shots_in_flight"},{"a":46057,"t":"code","b":[76,31,182],"m":"jmp","oa":46623,"o":"jet_destroyed"},{"a":46060,"l":"b_B3EC","t":"code","b":[173,225,12],"m":"lda","oa":3297,"o":"a_0CE1","x":[45954,45961,45994]},{"a":46063,"t":"code","b":[240,65],"m":"beq","oa":46130,"o":"r_B432"},{"a":46065,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46067,"t":"code","b":[172,226,12],"m":"ldy","oa":3298,"o":"a_0CE2"},{"a":46070,"t":"code","b":[56],"m":"sec"},{"a":46071,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":46074,"t":"code","b":[249,122,11],"m":"sbc","oa":2938,"o":"actor_alt,y"},{"a":46077,"t":"code","b":[201,9],"m":"cmp","o":"#$09"},{"a":46079,"t":"code","b":[144,4],"m":"bcc","oa":46085,"o":"b_B405"},{"a":46081,"t":"code","b":[201,248],"m":"cmp","o":"#$F8"},{"a":46083,"t":"code","b":[144,45],"m":"bcc","oa":46130,"o":"r_B432"},{"a":46085,"l":"b_B405","t":"code","b":[56],"m":"sec","x":[46079]},{"a":46086,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46089,"t":"code","b":[249,120,11],"m":"sbc","oa":2936,"o":"actor_x,y"},{"a":46092,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":46094,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46097,"t":"code","b":[249,121,11],"m":"sbc","oa":2937,"o":"actor_x_hi,y"},{"a":46100,"t":"code","b":[240,5],"m":"beq","oa":46107,"o":"b_B41B"},{"a":46102,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":46104,"t":"code","b":[240,8],"m":"beq","oa":46114,"o":"b_B422"},{"a":46106,"t":"code","b":[96],"m":"rts"},{"a":46107,"l":"b_B41B","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[46100]},{"a":46109,"t":"code","b":[201,17],"m":"cmp","o":"#$11"},{"a":46111,"t":"code","b":[144,8],"m":"bcc","oa":46121,"o":"b_B429"},{"a":46113,"t":"code","b":[96],"m":"rts"},{"a":46114,"l":"b_B422","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[46104]},{"a":46116,"t":"code","b":[201,240],"m":"cmp","o":"#$F0"},{"a":46118,"t":"code","b":[176,1],"m":"bcs","oa":46121,"o":"b_B429"},{"a":46120,"t":"code","b":[96],"m":"rts"},{"a":46121,"l":"b_B429","t":"code","b":[32,55,169],"m":"jsr","oa":43319,"o":"actor_free","x":[46111,46118]},{"a":46124,"t":"code","b":[206,243,12],"m":"dec","oa":3315,"o":"shots_in_flight"},{"a":46127,"t":"code","b":[76,48,182],"m":"jmp","oa":46640,"o":"mine_destroyed"},{"a":46130,"l":"r_B432","t":"code","b":[96],"m":"rts","x":[45901,46063,46083]},{"a":46131,"l":"rocket_hits_heli","c":"Tests a jet's rocket against the helicopter: height within 9 rows of $57 and world X within 10 bitmap columns of $55/$56. On a hit the rocket is dropped to one below the helicopter's base row, $B2EA turns it into an explosion and $B5AF marks the helicopter destroyed. This and the mine at $B474 are the only two ways the machine can be shot down in the air; everything else has to catch it on the ground through $B4AF.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[45663]},{"a":46133,"t":"code","b":[56],"m":"sec"},{"a":46134,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":46137,"t":"code","b":[229,87],"m":"sbc","oa":87,"o":"zpa_57"},{"a":46139,"t":"code","b":[201,10],"m":"cmp","o":"#$0A"},{"a":46141,"t":"code","b":[144,5],"m":"bcc","oa":46148,"o":"b_B444"},{"a":46143,"t":"code","b":[201,247],"m":"cmp","o":"#$F7"},{"a":46145,"t":"code","b":[176,1],"m":"bcs","oa":46148,"o":"b_B444"},{"a":46147,"t":"code","b":[96],"m":"rts"},{"a":46148,"l":"b_B444","t":"code","b":[56],"m":"sec","x":[46141,46145]},{"a":46149,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46152,"t":"code","b":[229,85],"m":"sbc","oa":85,"o":"world_x"},{"a":46154,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":46156,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46159,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":46161,"t":"code","b":[240,5],"m":"beq","oa":46168,"o":"b_B458"},{"a":46163,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":46165,"t":"code","b":[240,8],"m":"beq","oa":46175,"o":"b_B45F"},{"a":46167,"t":"code","b":[96],"m":"rts"},{"a":46168,"l":"b_B458","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46161]},{"a":46170,"t":"code","b":[201,11],"m":"cmp","o":"#$0B"},{"a":46172,"t":"code","b":[144,8],"m":"bcc","oa":46182,"o":"b_B466"},{"a":46174,"t":"code","b":[96],"m":"rts"},{"a":46175,"l":"b_B45F","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46165]},{"a":46177,"t":"code","b":[201,246],"m":"cmp","o":"#$F6"},{"a":46179,"t":"code","b":[176,1],"m":"bcs","oa":46182,"o":"b_B466"},{"a":46181,"t":"code","b":[96],"m":"rts"},{"a":46182,"l":"b_B466","t":"code","b":[56],"m":"sec","x":[46172,46179,46252]},{"a":46183,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":46185,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":46187,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":46190,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":46193,"t":"code","b":[76,175,181],"m":"jmp","oa":46511,"o":"heli_destroyed"},{"a":46196,"l":"mine_hits_heli","c":"Tests the homing mine against the helicopter, a wider box than the rocket's: height within 7 rows of $57 and world X within 18 bitmap columns of $55/$56. A hit first clears $0CE1 so the scheduler may send another mine, then joins the rocket's code at $B466 to explode the mine and destroy the helicopter.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[47261]},{"a":46198,"t":"code","b":[56],"m":"sec"},{"a":46199,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":46202,"t":"code","b":[229,87],"m":"sbc","oa":87,"o":"zpa_57"},{"a":46204,"t":"code","b":[201,8],"m":"cmp","o":"#$08"},{"a":46206,"t":"code","b":[144,5],"m":"bcc","oa":46213,"o":"b_B485"},{"a":46208,"t":"code","b":[201,249],"m":"cmp","o":"#$F9"},{"a":46210,"t":"code","b":[176,1],"m":"bcs","oa":46213,"o":"b_B485"},{"a":46212,"t":"code","b":[96],"m":"rts"},{"a":46213,"l":"b_B485","t":"code","b":[56],"m":"sec","x":[46206,46210]},{"a":46214,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46217,"t":"code","b":[229,85],"m":"sbc","oa":85,"o":"world_x"},{"a":46219,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":46221,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46224,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":46226,"t":"code","b":[240,5],"m":"beq","oa":46233,"o":"b_B499"},{"a":46228,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":46230,"t":"code","b":[240,8],"m":"beq","oa":46240,"o":"b_B4A0"},{"a":46232,"t":"code","b":[96],"m":"rts"},{"a":46233,"l":"b_B499","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46226]},{"a":46235,"t":"code","b":[201,19],"m":"cmp","o":"#$13"},{"a":46237,"t":"code","b":[144,8],"m":"bcc","oa":46247,"o":"b_B4A7"},{"a":46239,"t":"code","b":[96],"m":"rts"},{"a":46240,"l":"b_B4A0","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46230]},{"a":46242,"t":"code","b":[201,238],"m":"cmp","o":"#$EE"},{"a":46244,"t":"code","b":[176,1],"m":"bcs","oa":46247,"o":"b_B4A7"},{"a":46246,"t":"code","b":[96],"m":"rts"},{"a":46247,"l":"b_B4A7","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[46237,46244]},{"a":46249,"t":"code","b":[141,225,12],"m":"sta","oa":3297,"o":"a_0CE1"},{"a":46252,"t":"code","b":[76,102,180],"m":"jmp","oa":46182,"o":"b_B466"},{"a":46255,"l":"ground_burst_effects","c":"Decides what an actor that has just been turned into an explosion landed on. Nothing at all happens once its world X high byte reaches $12, off the end of the map. A burst below the helicopter's plane (base row under $58) goes to $B552 and is tested against the tanks. A burst at or above that plane destroys the helicopter if the helicopter is on the ground ($5D = 0) and within 11 bitmap columns, then walks all sixteen four-byte records of the people array at $0CA0, skipping any already flagged dead in +0 and any whose state in +1 is 2 or $FE, and kills anyone within 10 columns through $B63E. The subtraction at $B50E has no preceding sec, so that horizontal comparison is computed one unit short. Finally, a burst inside one of the 24-unit boxes at world X $0380, $0480 or $0580 goes to $B652 and opens that shed.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[45534,45598,45674,45735,45944,47275]},{"a":46257,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46260,"t":"code","b":[201,18],"m":"cmp","o":"#$12"},{"a":46262,"t":"code","b":[176,10],"m":"bcs","oa":46274,"o":"r_B4C2"},{"a":46264,"t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x"},{"a":46267,"t":"code","b":[197,88],"m":"cmp","oa":88,"o":"ground_row"},{"a":46269,"t":"code","b":[176,4],"m":"bcs","oa":46275,"o":"b_B4C3"},{"a":46271,"t":"code","b":[76,82,181],"m":"jmp","oa":46418,"o":"ground_burst_vs_tanks"},{"a":46274,"l":"r_B4C2","t":"code","b":[96],"m":"rts","x":[46262]},{"a":46275,"l":"b_B4C3","t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up","x":[46269]},{"a":46277,"t":"code","b":[208,43],"m":"bne","oa":46322,"o":"b_B4F2"},{"a":46279,"t":"code","b":[56],"m":"sec"},{"a":46280,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46283,"t":"code","b":[229,85],"m":"sbc","oa":85,"o":"world_x"},{"a":46285,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":46287,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46290,"t":"code","b":[229,86],"m":"sbc","oa":86,"o":"zpa_56"},{"a":46292,"t":"code","b":[240,7],"m":"beq","oa":46301,"o":"b_B4DD"},{"a":46294,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":46296,"t":"code","b":[240,15],"m":"beq","oa":46313,"o":"b_B4E9"},{"a":46298,"t":"code","b":[76,242,180],"m":"jmp","oa":46322,"o":"b_B4F2"},{"a":46301,"l":"b_B4DD","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46292]},{"a":46303,"t":"code","b":[201,12],"m":"cmp","o":"#$0C"},{"a":46305,"t":"code","b":[176,15],"m":"bcs","oa":46322,"o":"b_B4F2"},{"a":46307,"t":"code","b":[32,175,181],"m":"jsr","oa":46511,"o":"heli_destroyed"},{"a":46310,"t":"code","b":[76,242,180],"m":"jmp","oa":46322,"o":"b_B4F2"},{"a":46313,"l":"b_B4E9","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46296]},{"a":46315,"t":"code","b":[201,245],"m":"cmp","o":"#$F5"},{"a":46317,"t":"code","b":[144,3],"m":"bcc","oa":46322,"o":"b_B4F2"},{"a":46319,"t":"code","b":[32,175,181],"m":"jsr","oa":46511,"o":"heli_destroyed"},{"a":46322,"l":"b_B4F2","t":"code","b":[169,16],"m":"lda","o":"#$10","x":[46277,46298,46305,46310,46317]},{"a":46324,"t":"code","b":[10],"m":"asl","o":"a"},{"a":46325,"t":"code","b":[10],"m":"asl","o":"a"},{"a":46326,"t":"code","b":[168],"m":"tay"},{"a":46327,"l":"b_B4F7","t":"code","b":[152],"m":"tya","x":[46337,46344,46348,46370,46378,46386,46391]},{"a":46328,"t":"code","b":[56],"m":"sec"},{"a":46329,"t":"code","b":[233,4],"m":"sbc","o":"#$04"},{"a":46331,"t":"code","b":[48,60],"m":"bmi","oa":46393,"o":"b_B539"},{"a":46333,"t":"code","b":[168],"m":"tay"},{"a":46334,"t":"code","b":[185,160,12],"m":"lda","oa":3232,"o":"person_state,y"},{"a":46337,"t":"code","b":[48,244],"m":"bmi","oa":46327,"o":"b_B4F7"},{"a":46339,"t":"code","b":[185,161,12],"m":"lda","oa":3233,"o":"person_dir,y"},{"a":46342,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":46344,"t":"code","b":[240,237],"m":"beq","oa":46327,"o":"b_B4F7"},{"a":46346,"t":"code","b":[201,254],"m":"cmp","o":"#$FE"},{"a":46348,"t":"code","b":[240,233],"m":"beq","oa":46327,"o":"b_B4F7"},{"a":46350,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46353,"t":"code","b":[249,162,12],"m":"sbc","oa":3234,"o":"person_x,y"},{"a":46356,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":46358,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46361,"t":"code","b":[249,163,12],"m":"sbc","oa":3235,"o":"person_x_hi,y"},{"a":46364,"t":"code","b":[240,6],"m":"beq","oa":46372,"o":"b_B524"},{"a":46366,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":46368,"t":"code","b":[240,10],"m":"beq","oa":46380,"o":"b_B52C"},{"a":46370,"t":"code","b":[208,211],"m":"bne","oa":46327,"o":"b_B4F7"},{"a":46372,"l":"b_B524","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46364]},{"a":46374,"t":"code","b":[201,10],"m":"cmp","o":"#$0A"},{"a":46376,"t":"code","b":[144,10],"m":"bcc","oa":46388,"o":"b_B534"},{"a":46378,"t":"code","b":[208,203],"m":"bne","oa":46327,"o":"b_B4F7"},{"a":46380,"l":"b_B52C","t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D","x":[46368]},{"a":46382,"t":"code","b":[201,246],"m":"cmp","o":"#$F6"},{"a":46384,"t":"code","b":[176,2],"m":"bcs","oa":46388,"o":"b_B534"},{"a":46386,"t":"code","b":[208,195],"m":"bne","oa":46327,"o":"b_B4F7"},{"a":46388,"l":"b_B534","t":"code","b":[32,62,182],"m":"jsr","oa":46654,"o":"kill_person","x":[46376,46384]},{"a":46391,"t":"code","b":[208,190],"m":"bne","oa":46327,"o":"b_B4F7"},{"a":46393,"l":"b_B539","t":"code","b":[56],"m":"sec","x":[46331]},{"a":46394,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46397,"t":"code","b":[233,128],"m":"sbc","o":"#$80"},{"a":46399,"t":"code","b":[48,27],"m":"bmi","oa":46428,"o":"r_B55C"},{"a":46401,"t":"code","b":[201,24],"m":"cmp","o":"#$18"},{"a":46403,"t":"code","b":[176,23],"m":"bcs","oa":46428,"o":"r_B55C"},{"a":46405,"t":"code","b":[56],"m":"sec"},{"a":46406,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46409,"t":"code","b":[233,3],"m":"sbc","o":"#$03"},{"a":46411,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":46413,"t":"code","b":[176,13],"m":"bcs","oa":46428,"o":"r_B55C"},{"a":46415,"t":"code","b":[76,82,182],"m":"jmp","oa":46674,"o":"open_shed"},{"a":46418,"l":"ground_burst_vs_tanks","c":"Tests an explosion that went off below the helicopter's plane against the tanks, whose slots are listed in $0CE9 with the count in $0CE8. A tank counts as hit when its base row is within about ten of the explosion's and its world X within 13 bitmap columns; the explosion then unlinks itself through $A937 and $B5BB destroys the tank.","t":"code","b":[189,123,11],"m":"lda","oa":2939,"o":"actor_base_row,x","x":[46271]},{"a":46421,"t":"code","b":[133,136],"m":"sta","oa":136,"o":"zpa_88"},{"a":46423,"t":"code","b":[174,232,12],"m":"ldx","oa":3304,"o":"board_list_len"},{"a":46426,"t":"code","b":[208,1],"m":"bne","oa":46429,"o":"b_B55D"},{"a":46428,"l":"r_B55C","t":"code","b":[96],"m":"rts","x":[46399,46403,46413]},{"a":46429,"l":"b_B55D","t":"code","b":[202],"m":"dex","x":[46426]},{"a":46430,"l":"b_B55E","t":"code","b":[188,233,12],"m":"ldy","oa":3305,"o":"board_list,x","x":[46448]},{"a":46433,"t":"code","b":[56],"m":"sec"},{"a":46434,"t":"code","b":[165,136],"m":"lda","oa":136,"o":"zpa_88"},{"a":46436,"t":"code","b":[249,123,11],"m":"sbc","oa":2939,"o":"actor_base_row,y"},{"a":46439,"t":"code","b":[201,10],"m":"cmp","o":"#$0A"},{"a":46441,"t":"code","b":[144,8],"m":"bcc","oa":46451,"o":"b_B573"},{"a":46443,"t":"code","b":[201,245],"m":"cmp","o":"#$F5"},{"a":46445,"t":"code","b":[176,4],"m":"bcs","oa":46451,"o":"b_B573"},{"a":46447,"l":"j_B56F","t":"code","b":[202],"m":"dex","x":[46478,46489,46500]},{"a":46448,"t":"code","b":[16,236],"m":"bpl","oa":46430,"o":"b_B55E"},{"a":46450,"t":"code","b":[96],"m":"rts"},{"a":46451,"l":"b_B573","t":"code","b":[134,109],"m":"stx","oa":109,"o":"zpa_6D","x":[46441,46445]},{"a":46453,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46455,"t":"code","b":[56],"m":"sec"},{"a":46456,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46459,"t":"code","b":[249,120,11],"m":"sbc","oa":2936,"o":"actor_x,y"},{"a":46462,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":46464,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46467,"t":"code","b":[249,121,11],"m":"sbc","oa":2937,"o":"actor_x_hi,y"},{"a":46470,"t":"code","b":[240,9],"m":"beq","oa":46481,"o":"b_B591"},{"a":46472,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":46474,"t":"code","b":[240,16],"m":"beq","oa":46492,"o":"b_B59C"},{"a":46476,"t":"code","b":[166,109],"m":"ldx","oa":109,"o":"zpa_6D"},{"a":46478,"t":"code","b":[76,111,181],"m":"jmp","oa":46447,"o":"j_B56F"},{"a":46481,"l":"b_B591","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[46470]},{"a":46483,"t":"code","b":[201,14],"m":"cmp","o":"#$0E"},{"a":46485,"t":"code","b":[144,16],"m":"bcc","oa":46503,"o":"b_B5A7"},{"a":46487,"t":"code","b":[166,109],"m":"ldx","oa":109,"o":"zpa_6D"},{"a":46489,"t":"code","b":[76,111,181],"m":"jmp","oa":46447,"o":"j_B56F"},{"a":46492,"l":"b_B59C","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[46474]},{"a":46494,"t":"code","b":[201,243],"m":"cmp","o":"#$F3"},{"a":46496,"t":"code","b":[176,5],"m":"bcs","oa":46503,"o":"b_B5A7"},{"a":46498,"t":"code","b":[166,109],"m":"ldx","oa":109,"o":"zpa_6D"},{"a":46500,"t":"code","b":[76,111,181],"m":"jmp","oa":46447,"o":"j_B56F"},{"a":46503,"l":"b_B5A7","t":"code","b":[32,55,169],"m":"jsr","oa":43319,"o":"actor_free","x":[46485,46496]},{"a":46506,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":46508,"t":"code","b":[76,187,181],"m":"jmp","oa":46523,"o":"tank_destroyed"},{"a":46511,"l":"heli_destroyed","c":"Marks the player's helicopter as destroyed. Sets $61, which makes the type-0 handler run the death sequence at $B055 from the next frame on, and sets $0B76 of the actor that did the killing to 4. Called from $B471 when a rocket or the mine connects, and from $B4E3 and $B4EF when a ground explosion catches a landed machine.","t":"code","b":[169,1],"m":"lda","o":"#$01","x":[46193,46307,46319]},{"a":46513,"t":"code","b":[133,97],"m":"sta","oa":97,"o":"zpa_61"},{"a":46515,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46517,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":46519,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":46522,"t":"code","b":[96],"m":"rts"},{"a":46523,"l":"tank_destroyed","c":"Destroys the tank whose position in the $0CE9 list is in A: points $72 at the tank's slot, $B2EA turns it into an explosion, the tank count $0CE8 drops by one and the list is compacted by falling into $B5D1. $72 is left pointing at the tank, not at the explosion that killed it.","t":"code","b":[168],"m":"tay","x":[46508]},{"a":46524,"t":"code","b":[185,233,12],"m":"lda","oa":3305,"o":"board_list,y"},{"a":46527,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":46529,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":46532,"t":"code","b":[206,232,12],"m":"dec","oa":3304,"o":"board_list_len"},{"a":46535,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":46537,"t":"code","b":[76,209,181],"m":"jmp","oa":46545,"o":"j_B5D1"},{"a":46540,"l":"tank_list_remove","c":"Takes the slot in $72 out of the four-entry tank list at $0CE9 to $0CEC by shifting the later entries down, and drops the count $0CE8. Called from $A16B when a tank leaves the map, and entered one instruction in, at $B5D1, from $B5BB when one is blown up.","t":"code","b":[206,232,12],"m":"dec","oa":3304,"o":"board_list_len","x":[41323]},{"a":46543,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":46545,"l":"j_B5D1","t":"code","b":[205,233,12],"m":"cmp","oa":3305,"o":"board_list","x":[46537]},{"a":46548,"t":"code","b":[240,12],"m":"beq","oa":46562,"o":"b_B5E2"},{"a":46550,"t":"code","b":[205,234,12],"m":"cmp","oa":3306,"o":"a_0CEA"},{"a":46553,"t":"code","b":[240,13],"m":"beq","oa":46568,"o":"b_B5E8"},{"a":46555,"t":"code","b":[205,235,12],"m":"cmp","oa":3307,"o":"a_0CEB"},{"a":46558,"t":"code","b":[240,14],"m":"beq","oa":46574,"o":"b_B5EE"},{"a":46560,"t":"code","b":[208,18],"m":"bne","oa":46580,"o":"r_B5F4"},{"a":46562,"l":"b_B5E2","t":"code","b":[173,234,12],"m":"lda","oa":3306,"o":"a_0CEA","x":[46548]},{"a":46565,"t":"code","b":[141,233,12],"m":"sta","oa":3305,"o":"board_list"},{"a":46568,"l":"b_B5E8","t":"code","b":[173,235,12],"m":"lda","oa":3307,"o":"a_0CEB","x":[46553]},{"a":46571,"t":"code","b":[141,234,12],"m":"sta","oa":3306,"o":"a_0CEA"},{"a":46574,"l":"b_B5EE","t":"code","b":[173,236,12],"m":"lda","oa":3308,"o":"a_0CEC","x":[46558]},{"a":46577,"t":"code","b":[141,235,12],"m":"sta","oa":3307,"o":"a_0CEB"},{"a":46580,"l":"r_B5F4","t":"code","b":[96],"m":"rts","x":[46560]},{"a":46581,"l":"jet_list_remove","c":"Takes the slot in $72 out of the four-entry jet list at $0CE4 to $0CE7 and drops the count $0CE3. Called from $AF7F when a jet finishes its attack run and leaves, and entered at $B5FA from $B61F when one is shot down. The later entries are shifted down so the order of the surviving jets is kept.","t":"code","b":[206,227,12],"m":"dec","oa":3299,"o":"hit_list_len","x":[44927]},{"a":46584,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":46586,"l":"j_B5FA","t":"code","b":[205,228,12],"m":"cmp","oa":3300,"o":"hit_list","x":[46637]},{"a":46589,"t":"code","b":[240,13],"m":"beq","oa":46604,"o":"b_B60C"},{"a":46591,"t":"code","b":[205,229,12],"m":"cmp","oa":3301,"o":"a_0CE5"},{"a":46594,"t":"code","b":[240,14],"m":"beq","oa":46610,"o":"b_B612"},{"a":46596,"t":"code","b":[205,230,12],"m":"cmp","oa":3302,"o":"a_0CE6"},{"a":46599,"t":"code","b":[240,15],"m":"beq","oa":46616,"o":"b_B618"},{"a":46601,"t":"code","b":[76,30,182],"m":"jmp","oa":46622,"o":"r_B61E"},{"a":46604,"l":"b_B60C","t":"code","b":[173,229,12],"m":"lda","oa":3301,"o":"a_0CE5","x":[46589]},{"a":46607,"t":"code","b":[141,228,12],"m":"sta","oa":3300,"o":"hit_list"},{"a":46610,"l":"b_B612","t":"code","b":[173,230,12],"m":"lda","oa":3302,"o":"a_0CE6","x":[46594]},{"a":46613,"t":"code","b":[141,229,12],"m":"sta","oa":3301,"o":"a_0CE5"},{"a":46616,"l":"b_B618","t":"code","b":[173,231,12],"m":"lda","oa":3303,"o":"a_0CE7","x":[46599]},{"a":46619,"t":"code","b":[141,230,12],"m":"sta","oa":3302,"o":"a_0CE6"},{"a":46622,"l":"r_B61E","t":"code","b":[96],"m":"rts","x":[46601]},{"a":46623,"l":"jet_destroyed","c":"Destroys the jet whose position in the $0CE4 list is in A: points $72 at the jet's slot, $B2EA turns it into an explosion, the jet count $0CE3 drops by one and the list is compacted through $B5FA.","t":"code","b":[168],"m":"tay","x":[46057]},{"a":46624,"t":"code","b":[185,228,12],"m":"lda","oa":3300,"o":"hit_list,y"},{"a":46627,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":46629,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":46632,"t":"code","b":[206,227,12],"m":"dec","oa":3299,"o":"hit_list_len"},{"a":46635,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":46637,"t":"code","b":[76,250,181],"m":"jmp","oa":46586,"o":"j_B5FA"},{"a":46640,"l":"mine_destroyed","c":"Destroys the homing mine. Its slot is in $0CE2, $B2EA turns it into an explosion, and $0CE1 is cleared so the scheduler at $A38C is free to release another one.","t":"code","b":[173,226,12],"m":"lda","oa":3298,"o":"a_0CE2","x":[46127]},{"a":46643,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":46645,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":46648,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":46650,"t":"code","b":[141,225,12],"m":"sta","oa":3297,"o":"a_0CE1"},{"a":46653,"t":"code","b":[96],"m":"rts"},{"a":46654,"l":"kill_person","c":"Kills the person whose record index is in Y: flags $0CA0,y with $FF, counts one more lost in $0CEF and one fewer outside in $0CF0, and scores it through $B0D2. Leaves the killing actor's $0B76 at 3, which is also what makes the caller's loop at $B534 continue. The same three lines appear at $9E14 for the other way a person can die.","t":"code","b":[169,255],"m":"lda","o":"#$FF","x":[46388]},{"a":46656,"t":"code","b":[153,160,12],"m":"sta","oa":3232,"o":"person_state,y"},{"a":46659,"t":"code","b":[238,239,12],"m":"inc","oa":3311,"o":"hostages_lost"},{"a":46662,"t":"code","b":[206,240,12],"m":"dec","oa":3312,"o":"a_0CF0"},{"a":46665,"t":"code","b":[32,210,176],"m":"jsr","oa":45266,"o":"count_person_lost"},{"a":46668,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":46670,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":46673,"t":"code","b":[96],"m":"rts"},{"a":46674,"l":"open_shed","c":"Opens the shed whose index is in A by setting $0CF4,x to 1, which is what lets the release code at $9E49 start sending that shed's people out, and sets the exploding actor's $0B76 to 2. Does nothing if the shed is already open. The box test that reaches here, at $B54B, admits indices 0 to 2 only, while the matching test for a shot at $B369 admits 0 to 3; the fourth shed is opened anyway before play starts, because $BE63 writes 1 into $0CF7, so the difference does not show.","t":"code","b":[170],"m":"tax","x":[46415]},{"a":46675,"t":"code","b":[189,244,12],"m":"lda","oa":3316,"o":"ground_obj_state,x"},{"a":46678,"t":"code","b":[208,12],"m":"bne","oa":46692,"o":"r_B664"},{"a":46680,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":46682,"t":"code","b":[157,244,12],"m":"sta","oa":3316,"o":"ground_obj_state,x"},{"a":46685,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46687,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":46689,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":46692,"l":"r_B664","t":"code","b":[96],"m":"rts","x":[46678]},{"a":46693,"l":"jet_fire_rockets","c":"Fires the jet's pair of rockets. Called from $AF5B when the jet is in state 3, the state it uses while the helicopter is in the air. Allocates two slots, makes both type 4, puts them on the jet's world X eight rows above and nine rows below it, roughly the wingtips of the head-on aircraft, both on the helicopter's base row $58, and gives both 24 world units a frame in the direction bit 7 of the jet's $0B77 is facing. $72 is saved in $0B64 and $0B65 and restored, so the jet's own handler carries on undisturbed.","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[44891]},{"a":46695,"t":"code","b":[142,100,11],"m":"stx","oa":2916,"o":"a_0B64"},{"a":46698,"t":"code","b":[189,120,11],"m":"lda","oa":2936,"o":"actor_x,x"},{"a":46701,"t":"code","b":[133,120],"m":"sta","oa":120,"o":"zpa_78"},{"a":46703,"t":"code","b":[189,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,x"},{"a":46706,"t":"code","b":[133,121],"m":"sta","oa":121,"o":"zpa_79"},{"a":46708,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":46711,"t":"code","b":[133,122],"m":"sta","oa":122,"o":"zpa_7A"},{"a":46713,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":46716,"t":"code","b":[133,119],"m":"sta","oa":119,"o":"zpa_77"},{"a":46718,"t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc"},{"a":46721,"t":"code","b":[164,114],"m":"ldy","oa":114,"o":"actor_slot"},{"a":46723,"t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc"},{"a":46726,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46728,"t":"code","b":[169,4],"m":"lda","o":"#$04"},{"a":46730,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":46733,"t":"code","b":[153,116,11],"m":"sta","oa":2932,"o":"actor_type,y"},{"a":46736,"t":"code","b":[165,120],"m":"lda","oa":120,"o":"zpa_78"},{"a":46738,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":46741,"t":"code","b":[153,120,11],"m":"sta","oa":2936,"o":"actor_x,y"},{"a":46744,"t":"code","b":[165,121],"m":"lda","oa":121,"o":"zpa_79"},{"a":46746,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":46749,"t":"code","b":[153,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,y"},{"a":46752,"t":"code","b":[24],"m":"clc"},{"a":46753,"t":"code","b":[165,122],"m":"lda","oa":122,"o":"zpa_7A"},{"a":46755,"t":"code","b":[105,8],"m":"adc","o":"#$08"},{"a":46757,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":46760,"t":"code","b":[56],"m":"sec"},{"a":46761,"t":"code","b":[165,122],"m":"lda","oa":122,"o":"zpa_7A"},{"a":46763,"t":"code","b":[233,9],"m":"sbc","o":"#$09"},{"a":46765,"t":"code","b":[153,122,11],"m":"sta","oa":2938,"o":"actor_alt,y"},{"a":46768,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":46770,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":46773,"t":"code","b":[153,123,11],"m":"sta","oa":2939,"o":"actor_base_row,y"},{"a":46776,"t":"code","b":[169,24],"m":"lda","o":"#$18"},{"a":46778,"t":"code","b":[36,119],"m":"bit","oa":119,"o":"zpa_77"},{"a":46780,"t":"code","b":[16,5],"m":"bpl","oa":46787,"o":"b_B6C3"},{"a":46782,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":46784,"t":"code","b":[24],"m":"clc"},{"a":46785,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":46787,"l":"b_B6C3","t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x","x":[46780]},{"a":46790,"t":"code","b":[153,117,11],"m":"sta","oa":2933,"o":"actor_vx,y"},{"a":46793,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":46795,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":46798,"t":"code","b":[153,118,11],"m":"sta","oa":2934,"o":"actor_vy,y"},{"a":46801,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":46804,"t":"code","b":[153,119,11],"m":"sta","oa":2935,"o":"actor_frame,y"},{"a":46807,"t":"code","b":[142,101,11],"m":"stx","oa":2917,"o":"a_0B65"},{"a":46810,"t":"code","b":[132,114],"m":"sty","oa":114,"o":"actor_slot"},{"a":46812,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":46815,"t":"code","b":[173,101,11],"m":"lda","oa":2917,"o":"a_0B65"},{"a":46818,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":46820,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":46823,"t":"code","b":[173,100,11],"m":"lda","oa":2916,"o":"a_0B64"},{"a":46826,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":46828,"t":"code","b":[96],"m":"rts"},{"a":46829,"l":"jet_fire_shell","c":"Fires the jet's single shell. Called from $AF61 when the jet is in state 4, the state it uses while the helicopter is on the ground. Allocates one slot, makes it type 5, puts it on the jet's world X one row below it on base row $58, and gives it 20 world units a frame in the direction bit 7 of the jet's $0B77 is facing. $72 is saved in $0B64 and restored.","t":"code","b":[164,114],"m":"ldy","oa":114,"o":"actor_slot","x":[44897]},{"a":46831,"t":"code","b":[140,100,11],"m":"sty","oa":2916,"o":"a_0B64"},{"a":46834,"t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc"},{"a":46837,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46839,"t":"code","b":[169,5],"m":"lda","o":"#$05"},{"a":46841,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":46844,"t":"code","b":[172,100,11],"m":"ldy","oa":2916,"o":"a_0B64"},{"a":46847,"t":"code","b":[185,120,11],"m":"lda","oa":2936,"o":"actor_x,y"},{"a":46850,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":46853,"t":"code","b":[185,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,y"},{"a":46856,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":46859,"t":"code","b":[56],"m":"sec"},{"a":46860,"t":"code","b":[185,122,11],"m":"lda","oa":2938,"o":"actor_alt,y"},{"a":46863,"t":"code","b":[233,1],"m":"sbc","o":"#$01"},{"a":46865,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":46868,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":46870,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":46873,"t":"code","b":[185,119,11],"m":"lda","oa":2935,"o":"actor_frame,y"},{"a":46876,"t":"code","b":[133,119],"m":"sta","oa":119,"o":"zpa_77"},{"a":46878,"t":"code","b":[169,20],"m":"lda","o":"#$14"},{"a":46880,"t":"code","b":[36,119],"m":"bit","oa":119,"o":"zpa_77"},{"a":46882,"t":"code","b":[16,5],"m":"bpl","oa":46889,"o":"b_B729"},{"a":46884,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":46886,"t":"code","b":[24],"m":"clc"},{"a":46887,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":46889,"l":"b_B729","t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x","x":[46882]},{"a":46892,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":46894,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":46897,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":46900,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":46903,"t":"code","b":[173,100,11],"m":"lda","oa":2916,"o":"a_0B64"},{"a":46906,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":46908,"t":"code","b":[96],"m":"rts"},{"a":46909,"l":"act_air_mine","c":"Actor handler for type 10, the single homing enemy the scheduler at $A38C releases from the third sortie onwards ($8D of 2 or more, one at a time, its slot in $0CE2 and its presence in $0CE1). $A044 launches it about 440 world units to one side of the helicopter at height $70. Draws shape table entry 50, a small blocky object ten rows tall, six bitmap columns left and seven rows above the actor position, with dirty-rectangle size code $19; it is blitted plain or mirrored on alternate frames according to bit 0 of the frame counter $89, so it looks as though it is turning, and on each of those frames it sounds one of two pitches on SID voice 3 through $A7C7 ($F0 or $FF), the warble that warns the player. $0B67 is set to $FF when it was actually drawn and $0B77 counts frames 0, 1, 2. Continues at $B755.","t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":46911,"t":"code","b":[141,103,11],"m":"sta","oa":2919,"o":"a_0B67"},{"a":46914,"t":"code","b":[162,6],"m":"ldx","o":"#$06"},{"a":46916,"t":"code","b":[160,7],"m":"ldy","o":"#$07"},{"a":46918,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":46920,"t":"code","b":[32,160,169],"m":"jsr","oa":43424,"o":"shape_dest_from_actor"},{"a":46923,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":46926,"t":"gap","n":2},{"a":46928,"l":"act_air_mine_shape","c":"Inline parameter of the $8BE0 call above: $37/$38 is loaded with the word at $806D, entry 50 of the shape table, the mine bitmap at $8827.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":46931,"t":"gap","n":2},{"a":46933,"l":"act_air_mine_move","c":"Blits the mine and then steers it. It is abandoned, and $0CE1 cleared, as soon as the helicopter's world X high byte is more than two away from its own, which is what stops mines following the player across the whole map. Otherwise it chases: the horizontal velocity $0B75 is moved one unit a frame towards the helicopter and clamped to +/-5, and while the mine is on screen the vertical velocity $0B76 is moved towards the helicopter's height and clamped to +/-1; off screen it stops climbing. $B2AA is then called with no fall rate and with $0B77 held at zero over the call, so the mine neither falls nor drifts out of its plane. On the last sortie ($8D = 3) a mine that is on screen, below height $58, on the frame its 0-2 counter is zero and one time in four on the random byte from $DC04, drops a type-8 shell at its own position with its own horizontal speed plus or minus 10 and sounds a note. Height above $A0 or below $0A ends the mine as a ground explosion through $B2EA and $B4AF; in between, $B474 tests it against the helicopter. The routine runs on past $B7FF and ends at $B80A.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":46936,"t":"code","b":[176,50],"m":"bcs","oa":46988,"o":"b_B78C"},{"a":46938,"t":"code","b":[169,25],"m":"lda","o":"#$19"},{"a":46940,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":46943,"t":"code","b":[165,137],"m":"lda","oa":137,"o":"phase_frames"},{"a":46945,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":46947,"t":"code","b":[208,7],"m":"bne","oa":46956,"o":"b_B76C"},{"a":46949,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":46952,"t":"code","b":[162,240],"m":"ldx","o":"#$F0"},{"a":46954,"t":"code","b":[208,5],"m":"bne","oa":46961,"o":"b_B771"},{"a":46956,"l":"b_B76C","t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored","x":[46947]},{"a":46959,"t":"code","b":[162,255],"m":"ldx","o":"#$FF"},{"a":46961,"l":"b_B771","t":"code","b":[160,1],"m":"ldy","o":"#$01","x":[46954]},{"a":46963,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":46966,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":46968,"t":"code","b":[141,103,11],"m":"sta","oa":2919,"o":"a_0B67"},{"a":46971,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":46973,"t":"code","b":[254,119,11],"m":"inc","oa":2935,"o":"actor_frame,x"},{"a":46976,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":46979,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":46981,"t":"code","b":[144,5],"m":"bcc","oa":46988,"o":"b_B78C"},{"a":46983,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":46985,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":46988,"l":"b_B78C","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[46936,46981]},{"a":46990,"t":"code","b":[56],"m":"sec"},{"a":46991,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":46993,"t":"code","b":[253,120,11],"m":"sbc","oa":2936,"o":"actor_x,x"},{"a":46996,"t":"code","b":[133,129],"m":"sta","oa":129,"o":"zpa_81"},{"a":46998,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":47000,"t":"code","b":[253,121,11],"m":"sbc","oa":2937,"o":"actor_x_hi,x"},{"a":47003,"t":"code","b":[133,130],"m":"sta","oa":130,"o":"zpa_82"},{"a":47005,"t":"code","b":[165,87],"m":"lda","oa":87,"o":"zpa_57"},{"a":47007,"t":"code","b":[253,122,11],"m":"sbc","oa":2938,"o":"actor_alt,x"},{"a":47010,"t":"code","b":[133,131],"m":"sta","oa":131,"o":"zpa_83"},{"a":47012,"t":"code","b":[165,130],"m":"lda","oa":130,"o":"zpa_82"},{"a":47014,"t":"code","b":[201,253],"m":"cmp","o":"#$FD"},{"a":47016,"t":"code","b":[176,12],"m":"bcs","oa":47030,"o":"b_B7B6"},{"a":47018,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":47020,"t":"code","b":[144,8],"m":"bcc","oa":47030,"o":"b_B7B6"},{"a":47022,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":47024,"t":"code","b":[141,225,12],"m":"sta","oa":3297,"o":"a_0CE1"},{"a":47027,"t":"code","b":[76,55,169],"m":"jmp","oa":43319,"o":"actor_free"},{"a":47030,"l":"b_B7B6","t":"code","b":[36,130],"m":"bit","oa":130,"o":"zpa_82","x":[47016,47020]},{"a":47032,"t":"code","b":[48,17],"m":"bmi","oa":47051,"o":"b_B7CB"},{"a":47034,"t":"code","b":[254,117,11],"m":"inc","oa":2933,"o":"actor_vx,x"},{"a":47037,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":47040,"t":"code","b":[201,6],"m":"cmp","o":"#$06"},{"a":47042,"t":"code","b":[208,22],"m":"bne","oa":47066,"o":"b_B7DA"},{"a":47044,"t":"code","b":[169,5],"m":"lda","o":"#$05"},{"a":47046,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":47049,"t":"code","b":[208,15],"m":"bne","oa":47066,"o":"b_B7DA"},{"a":47051,"l":"b_B7CB","t":"code","b":[222,117,11],"m":"dec","oa":2933,"o":"actor_vx,x","x":[47032]},{"a":47054,"t":"code","b":[189,117,11],"m":"lda","oa":2933,"o":"actor_vx,x"},{"a":47057,"t":"code","b":[201,250],"m":"cmp","o":"#$FA"},{"a":47059,"t":"code","b":[208,5],"m":"bne","oa":47066,"o":"b_B7DA"},{"a":47061,"t":"code","b":[169,251],"m":"lda","o":"#$FB"},{"a":47063,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":47066,"l":"b_B7DA","t":"code","b":[44,103,11],"m":"bit","oa":2919,"o":"a_0B67","x":[47042,47049,47059]},{"a":47069,"t":"code","b":[48,7],"m":"bmi","oa":47078,"o":"b_B7E6"},{"a":47071,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":47073,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":47076,"t":"code","b":[240,36],"m":"beq","oa":47114,"o":"actor10_move_and_shoot"},{"a":47078,"l":"b_B7E6","t":"code","b":[36,131],"m":"bit","oa":131,"o":"zpa_83","x":[47069]},{"a":47080,"t":"code","b":[48,17],"m":"bmi","oa":47099,"o":"b_B7FB"},{"a":47082,"t":"code","b":[254,118,11],"m":"inc","oa":2934,"o":"actor_vy,x"},{"a":47085,"t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x"},{"a":47088,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":47090,"t":"code","b":[208,22],"m":"bne","oa":47114,"o":"actor10_move_and_shoot"},{"a":47092,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":47094,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":47097,"t":"code","b":[208,15],"m":"bne","oa":47114,"o":"actor10_move_and_shoot"},{"a":47099,"l":"b_B7FB","t":"code","b":[222,118,11],"m":"dec","oa":2934,"o":"actor_vy,x","x":[47080]},{"a":47102,"t":"code","b":[189,118,11],"m":"lda","oa":2934,"o":"actor_vy,x"},{"a":47105,"t":"code","b":[201,254],"m":"cmp","o":"#$FE"},{"a":47107,"t":"code","b":[208,5],"m":"bne","oa":47114,"o":"actor10_move_and_shoot"},{"a":47109,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":47111,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":47114,"l":"actor10_move_and_shoot","c":"Tail of the actor handler entered at $B73D (type 10 in the $B32E dispatch table; the entry itself is outside this range). Steps the actor with $B2AA while field +3 ($0B77,x) is held aside and the gravity term is zero, so this actor keeps a constant velocity for the frame, then puts field +3 back. It then fires: when the phase byte $8D is 3, field +3 is zero, the 'was drawn this frame' flag $0B67 is set, the actor's height $0B7A,x is below $58 and a fresh CIA1 timer sample from $A933 has bits 3 and 6 both clear (about one frame in four), $A951 takes a slot off the free list and fills it as a type 8 actor at the parent's 16-bit X ($0B78/$0B79) and height ($0B7A), with $0B7B from zero page $58, an X velocity of the parent's plus or minus $0A chosen by bit 7 of the random byte, both velocity fractions cleared, links it into the live list with $A95B and plays a short blip ($A7C7, X=$78, Y=1). Finally, if the actor's height has left the band $0A..$9F it is zeroed, $0CE1 is cleared and $B2EA stops the actor (turning it into type 1 or 2) before continuing at $B4AF; otherwise the handler carries on at $B474.","t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x","x":[47076,47090,47097,47107]},{"a":47117,"t":"code","b":[141,102,11],"m":"sta","oa":2918,"o":"a_0B66"},{"a":47120,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":47122,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":47125,"t":"code","b":[32,170,178],"m":"jsr","oa":45738,"o":"actor_step"},{"a":47128,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":47130,"t":"code","b":[173,102,11],"m":"lda","oa":2918,"o":"a_0B66"},{"a":47133,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":47136,"t":"code","b":[165,141],"m":"lda","oa":141,"o":"zpa_8D"},{"a":47138,"t":"code","b":[201,3],"m":"cmp","o":"#$03"},{"a":47140,"t":"code","b":[208,106],"m":"bne","oa":47248,"o":"b_B890"},{"a":47142,"t":"code","b":[189,119,11],"m":"lda","oa":2935,"o":"actor_frame,x"},{"a":47145,"t":"code","b":[208,101],"m":"bne","oa":47248,"o":"b_B890"},{"a":47147,"t":"code","b":[173,103,11],"m":"lda","oa":2919,"o":"a_0B67"},{"a":47150,"t":"code","b":[240,96],"m":"beq","oa":47248,"o":"b_B890"},{"a":47152,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":47155,"t":"code","b":[201,88],"m":"cmp","o":"#$58"},{"a":47157,"t":"code","b":[176,89],"m":"bcs","oa":47248,"o":"b_B890"},{"a":47159,"t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte"},{"a":47162,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":47164,"t":"code","b":[41,72],"m":"and","o":"#$48"},{"a":47166,"t":"code","b":[208,80],"m":"bne","oa":47248,"o":"b_B890"},{"a":47168,"t":"code","b":[165,114],"m":"lda","oa":114,"o":"actor_slot"},{"a":47170,"t":"code","b":[141,104,11],"m":"sta","oa":2920,"o":"a_0B68"},{"a":47173,"t":"code","b":[32,81,169],"m":"jsr","oa":43345,"o":"actor_alloc"},{"a":47176,"t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot"},{"a":47178,"t":"code","b":[169,8],"m":"lda","o":"#$08"},{"a":47180,"t":"code","b":[157,116,11],"m":"sta","oa":2932,"o":"actor_type,x"},{"a":47183,"t":"code","b":[172,104,11],"m":"ldy","oa":2920,"o":"a_0B68"},{"a":47186,"t":"code","b":[185,120,11],"m":"lda","oa":2936,"o":"actor_x,y"},{"a":47189,"t":"code","b":[157,120,11],"m":"sta","oa":2936,"o":"actor_x,x"},{"a":47192,"t":"code","b":[185,121,11],"m":"lda","oa":2937,"o":"actor_x_hi,y"},{"a":47195,"t":"code","b":[157,121,11],"m":"sta","oa":2937,"o":"actor_x_hi,x"},{"a":47198,"t":"code","b":[185,122,11],"m":"lda","oa":2938,"o":"actor_alt,y"},{"a":47201,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":47204,"t":"code","b":[165,88],"m":"lda","oa":88,"o":"ground_row"},{"a":47206,"t":"code","b":[157,123,11],"m":"sta","oa":2939,"o":"actor_base_row,x"},{"a":47209,"t":"code","b":[24],"m":"clc"},{"a":47210,"t":"code","b":[169,10],"m":"lda","o":"#$0A"},{"a":47212,"t":"code","b":[36,111],"m":"bit","oa":111,"o":"zpa_6F"},{"a":47214,"t":"code","b":[16,3],"m":"bpl","oa":47219,"o":"b_B873"},{"a":47216,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":47218,"t":"code","b":[56],"m":"sec"},{"a":47219,"l":"b_B873","t":"code","b":[121,117,11],"m":"adc","oa":2933,"o":"actor_vx,y","x":[47214]},{"a":47222,"t":"code","b":[157,117,11],"m":"sta","oa":2933,"o":"actor_vx,x"},{"a":47225,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":47227,"t":"code","b":[157,118,11],"m":"sta","oa":2934,"o":"actor_vy,x"},{"a":47230,"t":"code","b":[157,119,11],"m":"sta","oa":2935,"o":"actor_frame,x"},{"a":47233,"t":"code","b":[32,91,169],"m":"jsr","oa":43355,"o":"actor_link"},{"a":47236,"t":"code","b":[173,104,11],"m":"lda","oa":2920,"o":"a_0B68"},{"a":47239,"t":"code","b":[133,114],"m":"sta","oa":114,"o":"actor_slot"},{"a":47241,"t":"code","b":[162,120],"m":"ldx","o":"#$78"},{"a":47243,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":47245,"t":"code","b":[32,199,167],"m":"jsr","oa":42951,"o":"play_sfx"},{"a":47248,"l":"b_B890","t":"code","b":[166,114],"m":"ldx","oa":114,"o":"actor_slot","x":[47140,47145,47150,47157,47166]},{"a":47250,"t":"code","b":[189,122,11],"m":"lda","oa":2938,"o":"actor_alt,x"},{"a":47253,"t":"code","b":[201,160],"m":"cmp","o":"#$A0"},{"a":47255,"t":"code","b":[176,7],"m":"bcs","oa":47264,"o":"b_B8A0"},{"a":47257,"t":"code","b":[201,10],"m":"cmp","o":"#$0A"},{"a":47259,"t":"code","b":[144,3],"m":"bcc","oa":47264,"o":"b_B8A0"},{"a":47261,"t":"code","b":[76,116,180],"m":"jmp","oa":46196,"o":"mine_hits_heli"},{"a":47264,"l":"b_B8A0","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[47255,47259]},{"a":47266,"t":"code","b":[157,122,11],"m":"sta","oa":2938,"o":"actor_alt,x"},{"a":47269,"t":"code","b":[141,225,12],"m":"sta","oa":3297,"o":"a_0CE1"},{"a":47272,"t":"code","b":[32,234,178],"m":"jsr","oa":45802,"o":"actor_to_explosion"},{"a":47275,"t":"code","b":[76,175,180],"m":"jmp","oa":46255,"o":"ground_burst_effects"},{"a":47278,"l":"draw_sheds","c":"Draws the four prisoner sheds, once per frame, from the startup and play loops at $96C3 and $9727. Returns immediately unless the camera high byte $76 is $03..$06, the only stretch of the world the sheds occupy. The sheds stand at fixed world X $037D, $047D, $057D and $067D - 256 units apart, hard coded here, not read from any table - with the low bit of the X taken from the camera's low bit so the multicolour pixel pairs never straddle. $0B69 counts the shed 0..3, $0B6A/$0B6B holds its world X and $0B6B is bumped by one per shed. For each: body at bitmap row $24 (36), ground bar at row $19 (25), and for a shed already blown open a small figure in the doorway six units right at row $1C (28). Reads the per-shed state array $0CF4..$0CF7 (0 = intact, 1 = open) and the shape pointer table at $8009.","t":"code","b":[56],"m":"sec","x":[38595,38695]},{"a":47279,"t":"code","b":[165,118],"m":"lda","oa":118,"o":"zpa_76"},{"a":47281,"t":"code","b":[233,3],"m":"sbc","o":"#$03"},{"a":47283,"t":"code","b":[48,5],"m":"bmi","oa":47290,"o":"b_B8BA"},{"a":47285,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":47287,"t":"code","b":[144,1],"m":"bcc","oa":47290,"o":"b_B8BA"},{"a":47289,"t":"code","b":[96],"m":"rts"},{"a":47290,"l":"b_B8BA","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[47283,47287]},{"a":47292,"t":"code","b":[141,105,11],"m":"sta","oa":2921,"o":"a_0B69"},{"a":47295,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":47297,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":47299,"t":"code","b":[73,1],"m":"eor","o":"#$01"},{"a":47301,"t":"code","b":[73,128],"m":"eor","o":"#$80"},{"a":47303,"t":"code","b":[141,106,11],"m":"sta","oa":2922,"o":"a_0B6A"},{"a":47306,"t":"code","b":[206,106,11],"m":"dec","oa":2922,"o":"a_0B6A"},{"a":47309,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":47311,"t":"code","b":[141,107,11],"m":"sta","oa":2923,"o":"a_0B6B"},{"a":47314,"l":"j_B8D2","t":"code","b":[56],"m":"sec","x":[47469]},{"a":47315,"t":"code","b":[173,106,11],"m":"lda","oa":2922,"o":"a_0B6A"},{"a":47318,"t":"code","b":[233,2],"m":"sbc","o":"#$02"},{"a":47320,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47322,"t":"code","b":[173,107,11],"m":"lda","oa":2923,"o":"a_0B6B"},{"a":47325,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":47327,"t":"code","b":[133,104],"m":"sta","oa":104,"o":"zpa_68"},{"a":47329,"t":"code","b":[169,36],"m":"lda","o":"#$24"},{"a":47331,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47333,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47336,"t":"gap","n":2},{"a":47338,"l":"shed_pick_body_shape","c":"Picks the shed's body shape from its state: $0CF4,x is 0 while the shed is intact and 1 once it has been blown open, and doubles into the interleaved shape pointer table, reaching entry 71 or entry 72 through $8097/$8098. Both are 27 bits by 11 rows. Leaves the chosen pointer in $65/$66 for the $8BE0 that follows.","t":"code","b":[174,105,11],"m":"ldx","oa":2921,"o":"a_0B69"},{"a":47341,"t":"code","b":[189,244,12],"m":"lda","oa":3316,"o":"ground_obj_state,x"},{"a":47344,"t":"code","b":[10],"m":"asl","o":"a"},{"a":47345,"t":"code","b":[170],"m":"tax"},{"a":47346,"t":"code","b":[189,151,128],"m":"lda","oa":32919,"o":"shape_ptr_hut,x"},{"a":47349,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":47351,"t":"code","b":[189,152,128],"m":"lda","oa":32920,"o":"shape_ptr_hut_hi,x"},{"a":47354,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":47356,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47359,"t":"gap","n":2},{"a":47361,"l":"shed_body_draw","c":"Clips the shed body against the scroll window with $8F03 and blits it with $8FD3 when any of it is on screen. Then drops the draw row to $19 (25) and reloads the position triple, ready for the solid bar of ground the shed stands on.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47364,"t":"code","b":[176,3],"m":"bcs","oa":47369,"o":"b_B909"},{"a":47366,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47369,"l":"b_B909","t":"code","b":[169,25],"m":"lda","o":"#$19","x":[47364]},{"a":47371,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47373,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47376,"t":"gap","n":2},{"a":47378,"l":"shed_ground_shape","c":"Loads the pointer to shape 73, the 27-bit by 2-row solid bar of ground a shed stands on, into $37/$38 from the shape table entry at $809B. Three bytes of jsr wedged between two inline word arguments.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47381,"t":"gap","n":2},{"a":47383,"l":"shed_ground_draw","c":"Draws the bar of ground under a shed and books the shed's erase rectangle. If $8F03 reports the bar fully off screen the whole shed is skipped. Otherwise the row goes back to $24 (36) and $AA38 records one rectangle for the next pass of $BBE6 under code $17, whose size comes from $94AF+2*$17: 5 character columns by 13 bitmap rows, enough to cover the body and the bar together. An intact shed ($0CF4,x = 0) is then finished; an open one also gets a figure in the doorway, six units right at row $1C.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47386,"t":"code","b":[144,3],"m":"bcc","oa":47391,"o":"b_B91F"},{"a":47388,"t":"code","b":[76,96,185],"m":"jmp","oa":47456,"o":"j_B960"},{"a":47391,"l":"b_B91F","t":"code","b":[169,36],"m":"lda","o":"#$24","x":[47386]},{"a":47393,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47395,"t":"code","b":[169,23],"m":"lda","o":"#$17"},{"a":47397,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":47400,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47403,"t":"code","b":[174,105,11],"m":"ldx","oa":2921,"o":"a_0B69"},{"a":47406,"t":"code","b":[189,244,12],"m":"lda","oa":3316,"o":"ground_obj_state,x"},{"a":47409,"t":"code","b":[240,45],"m":"beq","oa":47456,"o":"j_B960"},{"a":47411,"t":"code","b":[169,28],"m":"lda","o":"#$1C"},{"a":47413,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47415,"t":"code","b":[24],"m":"clc"},{"a":47416,"t":"code","b":[165,103],"m":"lda","oa":103,"o":"draw_wx"},{"a":47418,"t":"code","b":[105,6],"m":"adc","o":"#$06"},{"a":47420,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47422,"t":"code","b":[144,2],"m":"bcc","oa":47426,"o":"b_B942"},{"a":47424,"t":"code","b":[230,104],"m":"inc","oa":104,"o":"zpa_68"},{"a":47426,"l":"b_B942","t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos","x":[47422]},{"a":47429,"t":"gap","n":2},{"a":47431,"l":"shed_doorway_shape","c":"Loads the pointer to shape 74, the 15-bit by 3-row figure that appears in the doorway of a shed that has been blown open, into $37/$38 from the shape table entry at $809D.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47434,"t":"gap","n":2},{"a":47436,"l":"shed_doorway_draw","c":"Draws the figure in an opened shed's doorway, flipping it left and right every frame: bit 0 of the frame counter $89 chooses between the plain blit $8FD3 and the mirrored blit $903E. Then the loop tail advances $0B69 to the next shed, adds one to the world-X high byte $0B6B so the next shed is 256 units further right, and goes back to $B8D2, stopping after four.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47439,"t":"code","b":[176,15],"m":"bcs","oa":47456,"o":"j_B960"},{"a":47441,"t":"code","b":[165,137],"m":"lda","oa":137,"o":"phase_frames"},{"a":47443,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":47445,"t":"code","b":[208,6],"m":"bne","oa":47453,"o":"b_B95D"},{"a":47447,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47450,"t":"code","b":[76,96,185],"m":"jmp","oa":47456,"o":"j_B960"},{"a":47453,"l":"b_B95D","t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored","x":[47445]},{"a":47456,"l":"j_B960","t":"code","b":[238,105,11],"m":"inc","oa":2921,"o":"a_0B69","x":[47388,47409,47439,47450]},{"a":47459,"t":"code","b":[173,105,11],"m":"lda","oa":2921,"o":"a_0B69"},{"a":47462,"t":"code","b":[201,4],"m":"cmp","o":"#$04"},{"a":47464,"t":"code","b":[240,6],"m":"beq","oa":47472,"o":"r_B970"},{"a":47466,"t":"code","b":[238,107,11],"m":"inc","oa":2923,"o":"a_0B6B"},{"a":47469,"t":"code","b":[76,210,184],"m":"jmp","oa":47314,"o":"j_B8D2"},{"a":47472,"l":"r_B970","t":"code","b":[96],"m":"rts","x":[47464]},{"a":47473,"l":"draw_parallax_scenery","c":"Draws four small scenery objects in front of the home base at four different parallax rates, from the play loops at $96C0 and $9724. Returns unless the camera high byte $76 is $10, $11 or $12. The anchor is world X $1174 (low bit matched to the camera's). It forms E = ($1174 - camera - $8C) rounded down to even, then halves it three times with the signed shift $ACF1 to fill four world X values at $0B6C, $0B6E, $0B70 and $0B72: $1174 + E/8, + E/4, + E/2 and + E. Because $8F03 subtracts the camera again, their screen positions move at 1.125, 1.25, 1.5 and 2 times the camera's rate, so the four fan out as the helicopter flies. Their bitmap rows come from $BA3B: 28, 26, 23 and 16, highest for the slowest, so they read as depth over the ground. All four use shape 70, a 4-pixel by 5-row blob; what the blob is meant to be is not settled by the code.","t":"code","b":[56],"m":"sec","x":[38592,38692]},{"a":47474,"t":"code","b":[165,118],"m":"lda","oa":118,"o":"zpa_76"},{"a":47476,"t":"code","b":[233,17],"m":"sbc","o":"#$11"},{"a":47478,"t":"code","b":[240,9],"m":"beq","oa":47489,"o":"b_B981"},{"a":47480,"t":"code","b":[201,1],"m":"cmp","o":"#$01"},{"a":47482,"t":"code","b":[240,5],"m":"beq","oa":47489,"o":"b_B981"},{"a":47484,"t":"code","b":[201,255],"m":"cmp","o":"#$FF"},{"a":47486,"t":"code","b":[240,1],"m":"beq","oa":47489,"o":"b_B981"},{"a":47488,"t":"code","b":[96],"m":"rts"},{"a":47489,"l":"b_B981","t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org","x":[47478,47482,47486]},{"a":47491,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":47493,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":47495,"t":"code","b":[169,116],"m":"lda","o":"#$74"},{"a":47497,"t":"code","b":[41,254],"m":"and","o":"#$FE"},{"a":47499,"t":"code","b":[5,109],"m":"ora","oa":109,"o":"zpa_6D"},{"a":47501,"t":"code","b":[133,120],"m":"sta","oa":120,"o":"zpa_78"},{"a":47503,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":47505,"t":"code","b":[133,121],"m":"sta","oa":121,"o":"zpa_79"},{"a":47507,"t":"code","b":[56],"m":"sec"},{"a":47508,"t":"code","b":[169,116],"m":"lda","o":"#$74"},{"a":47510,"t":"code","b":[229,117],"m":"sbc","oa":117,"o":"view_org"},{"a":47512,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":47514,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":47516,"t":"code","b":[229,118],"m":"sbc","oa":118,"o":"zpa_76"},{"a":47518,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":47520,"t":"code","b":[56],"m":"sec"},{"a":47521,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":47523,"t":"code","b":[233,140],"m":"sbc","o":"#$8C"},{"a":47525,"t":"code","b":[41,254],"m":"and","o":"#$FE"},{"a":47527,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":47529,"t":"code","b":[176,2],"m":"bcs","oa":47533,"o":"b_B9AD"},{"a":47531,"t":"code","b":[198,112],"m":"dec","oa":112,"o":"zpa_70"},{"a":47533,"l":"b_B9AD","t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F","x":[47529]},{"a":47535,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":47537,"t":"code","b":[165,112],"m":"lda","oa":112,"o":"zpa_70"},{"a":47539,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":47541,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":47543,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":47546,"t":"code","b":[24],"m":"clc"},{"a":47547,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":47549,"t":"code","b":[41,254],"m":"and","o":"#$FE"},{"a":47551,"t":"code","b":[101,120],"m":"adc","oa":120,"o":"zpa_78"},{"a":47553,"t":"code","b":[141,112,11],"m":"sta","oa":2928,"o":"a_0B70"},{"a":47556,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":47558,"t":"code","b":[101,121],"m":"adc","oa":121,"o":"zpa_79"},{"a":47560,"t":"code","b":[141,113,11],"m":"sta","oa":2929,"o":"a_0B71"},{"a":47563,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":47565,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":47568,"t":"code","b":[24],"m":"clc"},{"a":47569,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":47571,"t":"code","b":[41,254],"m":"and","o":"#$FE"},{"a":47573,"t":"code","b":[101,120],"m":"adc","oa":120,"o":"zpa_78"},{"a":47575,"t":"code","b":[141,110,11],"m":"sta","oa":2926,"o":"a_0B6E"},{"a":47578,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":47580,"t":"code","b":[101,121],"m":"adc","oa":121,"o":"zpa_79"},{"a":47582,"t":"code","b":[141,111,11],"m":"sta","oa":2927,"o":"a_0B6F"},{"a":47585,"t":"code","b":[160,1],"m":"ldy","o":"#$01"},{"a":47587,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":47590,"t":"code","b":[24],"m":"clc"},{"a":47591,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":47593,"t":"code","b":[41,254],"m":"and","o":"#$FE"},{"a":47595,"t":"code","b":[101,120],"m":"adc","oa":120,"o":"zpa_78"},{"a":47597,"t":"code","b":[141,108,11],"m":"sta","oa":2924,"o":"a_0B6C"},{"a":47600,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":47602,"t":"code","b":[101,121],"m":"adc","oa":121,"o":"zpa_79"},{"a":47604,"t":"code","b":[141,109,11],"m":"sta","oa":2925,"o":"a_0B6D"},{"a":47607,"t":"code","b":[24],"m":"clc"},{"a":47608,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":47610,"t":"code","b":[101,120],"m":"adc","oa":120,"o":"zpa_78"},{"a":47612,"t":"code","b":[141,114,11],"m":"sta","oa":2930,"o":"a_0B72"},{"a":47615,"t":"code","b":[165,112],"m":"lda","oa":112,"o":"zpa_70"},{"a":47617,"t":"code","b":[101,121],"m":"adc","oa":121,"o":"zpa_79"},{"a":47619,"t":"code","b":[141,115,11],"m":"sta","oa":2931,"o":"a_0B73"},{"a":47622,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":47624,"l":"b_BA08","t":"code","b":[152],"m":"tya","x":[47672]},{"a":47625,"t":"code","b":[10],"m":"asl","o":"a"},{"a":47626,"t":"code","b":[170],"m":"tax"},{"a":47627,"t":"code","b":[189,108,11],"m":"lda","oa":2924,"o":"a_0B6C,x"},{"a":47630,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47632,"t":"code","b":[189,109,11],"m":"lda","oa":2925,"o":"a_0B6D,x"},{"a":47635,"t":"code","b":[133,104],"m":"sta","oa":104,"o":"zpa_68"},{"a":47637,"t":"code","b":[185,59,186],"m":"lda","oa":47675,"o":"parallax_rows,y"},{"a":47640,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47642,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47645,"t":"gap","n":2},{"a":47647,"l":"parallax_shape","c":"Loads the pointer to shape 70, the 4-pixel by 5-row blob used for all four parallax scenery objects, into $37/$38 from the shape table entry at $8095. Reached once per object, four times a frame.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47650,"t":"gap","n":2},{"a":47652,"l":"parallax_draw_one","c":"Draws one parallax object and books its erase rectangle. Y (0..3) selects the object and is saved across the call; $AA38 code $16 gives a 2-column by 5-row rectangle from $94AF. Off-screen objects are skipped without booking anything. Four passes, then rts.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47655,"t":"code","b":[176,12],"m":"bcs","oa":47669,"o":"b_BA35"},{"a":47657,"t":"code","b":[152],"m":"tya"},{"a":47658,"t":"code","b":[72],"m":"pha"},{"a":47659,"t":"code","b":[169,22],"m":"lda","o":"#$16"},{"a":47661,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":47664,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47667,"t":"code","b":[104],"m":"pla"},{"a":47668,"t":"code","b":[168],"m":"tay"},{"a":47669,"l":"b_BA35","t":"code","b":[200],"m":"iny","x":[47655]},{"a":47670,"t":"code","b":[192,4],"m":"cpy","o":"#$04"},{"a":47672,"t":"code","b":[208,206],"m":"bne","oa":47624,"o":"b_BA08"},{"a":47674,"t":"code","b":[96],"m":"rts"},{"a":47675,"l":"parallax_rows","c":"The bitmap row of each of the four parallax scenery objects, slowest first: $1C, $1A, $17, $10 - rows 28, 26, 23 and 16 counting up from the bottom of the play area. Four entries, one byte each, read only at $BA15 with Y = the object index 0..3.","t":"byte","b":[28,26,23,16],"x":[47637]},{"a":47679,"l":"draw_home_base","c":"Draws the home base, the fixed structure at the right-hand end of the world. Called from every draw sequence: $95D7, $965A, $96BD, $9721, $974F and $9761. Returns unless the camera high byte $76 is $11 or $12. The base sits at world X $1254, hard coded here, with the low bit copied from the camera so multicolour pixel pairs stay aligned; $78/$79 holds it. Built from six pieces, bottom to top: a solid apron 15 columns by 5 rows at X+$0F row $19 (from the fill record at $BB25, painted with $8C5E, not the shape blitter); shape 66, an 8 by 5 sloping wedge, mirrored at X-1 and plain at X+$7F so the two face outward $80 units apart; shape 65, a 13 by 11 bunker half, plain at X+$48 and mirrored at X+$62 to make one symmetrical building at row $22 (34); shape 67, the 1-pixel by 12-row flagpole at X+$71 row $2E (46); and the flag, shape 68 or 69 chosen by bit 0 of the frame counter $89 so it waves. Erase rectangles are booked through $AA38 under codes $13, $14 and $15.","t":"code","b":[56],"m":"sec","x":[38359,38490,38589,38689,38735,38753]},{"a":47680,"t":"code","b":[169,18],"m":"lda","o":"#$12"},{"a":47682,"t":"code","b":[229,118],"m":"sbc","oa":118,"o":"zpa_76"},{"a":47684,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":47686,"t":"code","b":[144,1],"m":"bcc","oa":47689,"o":"b_BA49"},{"a":47688,"t":"code","b":[96],"m":"rts"},{"a":47689,"l":"b_BA49","t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org","x":[47686]},{"a":47691,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":47693,"t":"code","b":[73,84],"m":"eor","o":"#$54"},{"a":47695,"t":"code","b":[133,120],"m":"sta","oa":120,"o":"zpa_78"},{"a":47697,"t":"code","b":[169,18],"m":"lda","o":"#$12"},{"a":47699,"t":"code","b":[133,121],"m":"sta","oa":121,"o":"zpa_79"},{"a":47701,"t":"code","b":[133,104],"m":"sta","oa":104,"o":"zpa_68"},{"a":47703,"t":"code","b":[24],"m":"clc"},{"a":47704,"t":"code","b":[165,120],"m":"lda","oa":120,"o":"zpa_78"},{"a":47706,"t":"code","b":[105,15],"m":"adc","o":"#$0F"},{"a":47708,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47710,"t":"code","b":[169,25],"m":"lda","o":"#$19"},{"a":47712,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47714,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47717,"t":"gap","n":2},{"a":47719,"l":"base_apron_record_load","c":"One of only two calls to $8BBA in the whole program, the inline routine that takes a literal 16-bit value rather than a pointer: it leaves $37/$38 holding $BB25 itself, the address of the base apron's fill record.","t":"code","b":[32,186,139],"m":"jsr","oa":35770,"o":"inline_fill_record"},{"a":47722,"t":"gap","n":2},{"a":47724,"l":"base_apron_fill","c":"Paints the base's solid apron with $8C5E when $8F03 says any of it is on screen: 15 character columns by 5 bitmap rows of pattern $AA, i.e. multicolour colour 2 throughout, from the record at $BB25. Then steps the position one unit left of the base anchor for the left-hand wedge.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47727,"t":"code","b":[176,3],"m":"bcs","oa":47732,"o":"b_BA74"},{"a":47729,"t":"code","b":[32,94,140],"m":"jsr","oa":35934,"o":"fill_rect_pattern"},{"a":47732,"l":"b_BA74","t":"code","b":[164,120],"m":"ldy","oa":120,"o":"zpa_78","x":[47727]},{"a":47734,"t":"code","b":[136],"m":"dey"},{"a":47735,"t":"code","b":[132,103],"m":"sty","oa":103,"o":"draw_wx"},{"a":47737,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47740,"t":"gap","n":2},{"a":47742,"l":"base_wedge_shape","c":"Loads the pointer to shape 66, the 8-pixel by 5-row sloping wedge that caps each end of the base, into $37/$38 from the shape table entry at $808D. Both wedges use it, one mirrored.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47745,"t":"gap","n":2},{"a":47747,"l":"base_wedge_left","c":"Draws the left-hand wedge of the base mirrored ($903E) at base X - 1, row $19, after booking erase code $13 - 22 columns by 5 rows, the widest rectangle the game uses, covering the apron and both wedges at once. If the wedge is off screen the rest of the base is abandoned. Then moves the position to base X + $7F for the matching right-hand wedge.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47750,"t":"code","b":[144,1],"m":"bcc","oa":47753,"o":"b_BA89"},{"a":47752,"t":"code","b":[96],"m":"rts"},{"a":47753,"l":"b_BA89","t":"code","b":[169,19],"m":"lda","o":"#$13","x":[47750]},{"a":47755,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":47758,"t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored"},{"a":47761,"t":"code","b":[24],"m":"clc"},{"a":47762,"t":"code","b":[165,120],"m":"lda","oa":120,"o":"zpa_78"},{"a":47764,"t":"code","b":[105,127],"m":"adc","o":"#$7F"},{"a":47766,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47768,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47771,"t":"gap","n":2},{"a":47773,"l":"base_wedge_right","c":"Draws the same wedge shape unmirrored ($8FD3) at base X + $7F, so the two slopes face outward $80 units apart and frame the apron. No erase rectangle of its own: code $13 already covers it. Then sets row $22 (34) and position base X + $48 for the bunker.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47776,"t":"code","b":[176,3],"m":"bcs","oa":47781,"o":"b_BAA5"},{"a":47778,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47781,"l":"b_BAA5","t":"code","b":[169,34],"m":"lda","o":"#$22","x":[47776]},{"a":47783,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47785,"t":"code","b":[24],"m":"clc"},{"a":47786,"t":"code","b":[165,120],"m":"lda","oa":120,"o":"zpa_78"},{"a":47788,"t":"code","b":[105,72],"m":"adc","o":"#$48"},{"a":47790,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47792,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47795,"t":"gap","n":2},{"a":47797,"l":"base_bunker_shape","c":"Loads the pointer to shape 65, the 13-pixel by 11-row bunker half, into $37/$38 from the shape table entry at $808B. Drawn twice, plain and mirrored, to make the whole building.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47800,"t":"gap","n":2},{"a":47802,"l":"base_bunker_left","c":"Books erase code $14 (9 columns by 9 rows) and blits the left half of the bunker at base X + $48, row $22. Then advances the position $1A units for its mirror image.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47805,"t":"code","b":[176,28],"m":"bcs","oa":47835,"o":"b_BADB"},{"a":47807,"t":"code","b":[169,20],"m":"lda","o":"#$14"},{"a":47809,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":47812,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47815,"t":"code","b":[24],"m":"clc"},{"a":47816,"t":"code","b":[165,103],"m":"lda","oa":103,"o":"draw_wx"},{"a":47818,"t":"code","b":[105,26],"m":"adc","o":"#$1A"},{"a":47820,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47822,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47825,"t":"gap","n":2},{"a":47827,"l":"base_bunker_right","c":"Draws the second half of the bunker mirrored ($903E) $1A units right of the first, which is what makes the building symmetrical from one 13-pixel shape. Then sets row $2E (46) and position base X + $71 for the flagpole.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47830,"t":"code","b":[176,3],"m":"bcs","oa":47835,"o":"b_BADB"},{"a":47832,"t":"code","b":[32,62,144],"m":"jsr","oa":36926,"o":"draw_shape_mirrored"},{"a":47835,"l":"b_BADB","t":"code","b":[169,46],"m":"lda","o":"#$2E","x":[47805,47830]},{"a":47837,"t":"code","b":[133,105],"m":"sta","oa":105,"o":"draw_wy"},{"a":47839,"t":"code","b":[24],"m":"clc"},{"a":47840,"t":"code","b":[165,120],"m":"lda","oa":120,"o":"zpa_78"},{"a":47842,"t":"code","b":[105,113],"m":"adc","o":"#$71"},{"a":47844,"t":"code","b":[133,103],"m":"sta","oa":103,"o":"draw_wx"},{"a":47846,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47849,"t":"gap","n":2},{"a":47851,"l":"base_flagpole_shape","c":"Loads the pointer to shape 67, the 1-pixel wide, 12-row flagpole, into $37/$38 from the shape table entry at $808F.","t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47854,"t":"gap","n":2},{"a":47856,"l":"base_flagpole","c":"Books erase code $15 (3 columns by 12 rows, covering pole and flag) and draws the flagpole at base X + $71, row $2E. If the pole is off screen the base is finished. Then moves two units right for the flag itself.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47859,"t":"code","b":[144,1],"m":"bcc","oa":47862,"o":"b_BAF6"},{"a":47861,"t":"code","b":[96],"m":"rts"},{"a":47862,"l":"b_BAF6","t":"code","b":[169,21],"m":"lda","o":"#$15","x":[47859]},{"a":47864,"t":"code","b":[32,56,170],"m":"jsr","oa":43576,"o":"queue_colour_stripe"},{"a":47867,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47870,"t":"code","b":[230,103],"m":"inc","oa":103,"o":"draw_wx"},{"a":47872,"t":"code","b":[230,103],"m":"inc","oa":103,"o":"draw_wx"},{"a":47874,"t":"code","b":[32,249,139],"m":"jsr","oa":35833,"o":"inline_object_pos"},{"a":47877,"t":"gap","n":2},{"a":47879,"l":"base_flag_pick","c":"Chooses the flag's frame from bit 0 of the frame counter $89 and reads its pointer out of $8091/$8092, shape table entries 68 and 69. The flag therefore alternates between two 11-bit by 8-row bitmaps on every frame, which is the only animation on the base.","t":"code","b":[165,137],"m":"lda","oa":137,"o":"phase_frames"},{"a":47881,"t":"code","b":[41,1],"m":"and","o":"#$01"},{"a":47883,"t":"code","b":[10],"m":"asl","o":"a"},{"a":47884,"t":"code","b":[170],"m":"tax"},{"a":47885,"t":"code","b":[189,145,128],"m":"lda","oa":32913,"o":"shape_ptr_flag,x"},{"a":47888,"t":"code","b":[133,101],"m":"sta","oa":101,"o":"shape_sel"},{"a":47890,"t":"code","b":[189,146,128],"m":"lda","oa":32914,"o":"shape_ptr_flag_hi,x"},{"a":47893,"t":"code","b":[133,102],"m":"sta","oa":102,"o":"zpa_66"},{"a":47895,"t":"code","b":[32,224,139],"m":"jsr","oa":35808,"o":"inline_shape_ptr"},{"a":47898,"t":"gap","n":2},{"a":47900,"l":"base_flag_draw","c":"Clips and blits the flag, the last piece of the base, and returns. No erase rectangle: the flagpole's code $15 already covers it.","t":"code","b":[32,3,143],"m":"jsr","oa":36611,"o":"clip_object"},{"a":47903,"t":"code","b":[176,3],"m":"bcs","oa":47908,"o":"r_BB24"},{"a":47905,"t":"code","b":[32,211,143],"m":"jsr","oa":36819,"o":"draw_shape"},{"a":47908,"l":"r_BB24","t":"code","b":[96],"m":"rts","x":[47903]},{"a":47909,"l":"base_apron_record","c":"The fill record for the base's apron, and the only one of its kind in the program: width 15 character columns, height 5 bitmap rows, then the four pattern bytes $AA $AA $AA $AA. $8C5E reads only those four - two for even bitmap rows, two for odd - and repeats them across the rectangle, so the apron comes out solid multicolour colour 2. It is not a shape for $8FD3 and carries no per-row bitmap. $8BBA at $BA67 hands its address to $37/$38.","t":"byte","b":[15,5,170,170,170,170]},{"a":47915,"l":"new_game_reset","c":"Resets everything a new game starts from, called at $95B2 before the attract loop and at $95F4 when a game begins. When bit 7 of $8C is set (the status bar is wanted) it stamps the bar's fixed furniture into text row 2 of both screen matrices, $0400 and $4400: the spade, diamond and heart markers (screen codes $41, $5A, $53) at columns 8, 19 and 30, reverse vertical-bar dividers ($E5) at columns 1, 11, 22 and 33 and a closing one ($E7) at column 38, colours the marker and the two digits after it white in colour RAM ($D858, $D863, $D86E with X = 2..0), and calls $A978 three times with zero to blank the three two-digit counters. Always, it then clears the score and phase words $0CEE, $0CEF, $0CF1, $0CF2, $8D, $0CFF (the sortie number) and $0CFC..$0CFE, sets the four sheds to intact ($0CF4..$0CF7 = 0) with sixteen people inside each ($0CF8..$0CFB = $10, 64 in all), and marks all sixteen slots of the people array at $0CA0 free by writing $FF to the first byte of each 4-byte record.","t":"code","b":[36,140],"m":"bit","oa":140,"o":"status_bar_on","x":[38322,38388]},{"a":47917,"t":"code","b":[16,91],"m":"bpl","oa":48010,"o":"b_BB8A"},{"a":47919,"t":"code","b":[169,65],"m":"lda","o":"#$41"},{"a":47921,"t":"code","b":[141,88,4],"m":"sta","oa":1112,"o":"a_0458"},{"a":47924,"t":"code","b":[141,88,68],"m":"sta","oa":17496,"o":"a_4458"},{"a":47927,"t":"code","b":[169,90],"m":"lda","o":"#$5A"},{"a":47929,"t":"code","b":[141,99,4],"m":"sta","oa":1123,"o":"a_0463"},{"a":47932,"t":"code","b":[141,99,68],"m":"sta","oa":17507,"o":"a_4463"},{"a":47935,"t":"code","b":[169,83],"m":"lda","o":"#$53"},{"a":47937,"t":"code","b":[141,110,4],"m":"sta","oa":1134,"o":"a_046E"},{"a":47940,"t":"code","b":[141,110,68],"m":"sta","oa":17518,"o":"a_446E"},{"a":47943,"t":"code","b":[162,2],"m":"ldx","o":"#$02"},{"a":47945,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":47947,"l":"b_BB4B","t":"code","b":[157,88,216],"m":"sta","oa":55384,"o":"f_D858,x","x":[47957]},{"a":47950,"t":"code","b":[157,99,216],"m":"sta","oa":55395,"o":"f_D863,x"},{"a":47953,"t":"code","b":[157,110,216],"m":"sta","oa":55406,"o":"f_D86E,x"},{"a":47956,"t":"code","b":[202],"m":"dex"},{"a":47957,"t":"code","b":[16,244],"m":"bpl","oa":47947,"o":"b_BB4B"},{"a":47959,"t":"code","b":[169,231],"m":"lda","o":"#$E7"},{"a":47961,"t":"code","b":[141,118,4],"m":"sta","oa":1142,"o":"a_0476"},{"a":47964,"t":"code","b":[141,118,68],"m":"sta","oa":17526,"o":"a_4476"},{"a":47967,"t":"code","b":[169,229],"m":"lda","o":"#$E5"},{"a":47969,"t":"code","b":[141,81,4],"m":"sta","oa":1105,"o":"f_0451"},{"a":47972,"t":"code","b":[141,81,68],"m":"sta","oa":17489,"o":"f_4451"},{"a":47975,"t":"code","b":[141,91,4],"m":"sta","oa":1115,"o":"a_045B"},{"a":47978,"t":"code","b":[141,91,68],"m":"sta","oa":17499,"o":"a_445B"},{"a":47981,"t":"code","b":[141,102,4],"m":"sta","oa":1126,"o":"a_0466"},{"a":47984,"t":"code","b":[141,102,68],"m":"sta","oa":17510,"o":"a_4466"},{"a":47987,"t":"code","b":[141,113,4],"m":"sta","oa":1137,"o":"a_0471"},{"a":47990,"t":"code","b":[141,113,68],"m":"sta","oa":17521,"o":"a_4471"},{"a":47993,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":47995,"t":"code","b":[170],"m":"tax"},{"a":47996,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":47999,"t":"code","b":[138],"m":"txa"},{"a":48000,"t":"code","b":[232],"m":"inx"},{"a":48001,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":48004,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48006,"t":"code","b":[232],"m":"inx"},{"a":48007,"t":"code","b":[32,120,169],"m":"jsr","oa":43384,"o":"draw_bcd_counter"},{"a":48010,"l":"b_BB8A","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[47917]},{"a":48012,"t":"code","b":[141,238,12],"m":"sta","oa":3310,"o":"hostages_saved"},{"a":48015,"t":"code","b":[141,239,12],"m":"sta","oa":3311,"o":"hostages_lost"},{"a":48018,"t":"code","b":[141,241,12],"m":"sta","oa":3313,"o":"a_0CF1"},{"a":48021,"t":"code","b":[141,242,12],"m":"sta","oa":3314,"o":"a_0CF2"},{"a":48024,"t":"code","b":[133,141],"m":"sta","oa":141,"o":"zpa_8D"},{"a":48026,"t":"code","b":[141,255,12],"m":"sta","oa":3327,"o":"sortie_number"},{"a":48029,"t":"code","b":[141,252,12],"m":"sta","oa":3324,"o":"a_0CFC"},{"a":48032,"t":"code","b":[141,253,12],"m":"sta","oa":3325,"o":"a_0CFD"},{"a":48035,"t":"code","b":[141,254,12],"m":"sta","oa":3326,"o":"a_0CFE"},{"a":48038,"t":"code","b":[162,3],"m":"ldx","o":"#$03"},{"a":48040,"l":"b_BBA8","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[48051]},{"a":48042,"t":"code","b":[157,244,12],"m":"sta","oa":3316,"o":"ground_obj_state,x"},{"a":48045,"t":"code","b":[169,16],"m":"lda","o":"#$10"},{"a":48047,"t":"code","b":[157,248,12],"m":"sta","oa":3320,"o":"ground_obj_count,x"},{"a":48050,"t":"code","b":[202],"m":"dex"},{"a":48051,"t":"code","b":[16,243],"m":"bpl","oa":48040,"o":"b_BBA8"},{"a":48053,"t":"code","b":[169,16],"m":"lda","o":"#$10"},{"a":48055,"t":"code","b":[10],"m":"asl","o":"a"},{"a":48056,"t":"code","b":[10],"m":"asl","o":"a"},{"a":48057,"t":"code","b":[170],"m":"tax"},{"a":48058,"l":"j_BBBA","t":"code","b":[138],"m":"txa","x":[48070]},{"a":48059,"t":"code","b":[56],"m":"sec"},{"a":48060,"t":"code","b":[233,4],"m":"sbc","o":"#$04"},{"a":48062,"t":"code","b":[48,9],"m":"bmi","oa":48073,"o":"r_BBC9"},{"a":48064,"t":"code","b":[170],"m":"tax"},{"a":48065,"t":"code","b":[169,255],"m":"lda","o":"#$FF"},{"a":48067,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":48070,"t":"code","b":[76,186,187],"m":"jmp","oa":48058,"o":"j_BBBA"},{"a":48073,"l":"r_BBC9","t":"code","b":[96],"m":"rts","x":[48062]},{"a":48074,"l":"clear_both_bitmaps","c":"Wipes the play area of both bitmap buffers before the first frame, called once at $95A5. $8CE0 resets the clip window to the full 168 rows (bottom row 0 in $3A, top row $A7 in $39) and zeroes the draw state; then, twice, $8D42 fills bitmap rows 0 to $A7 with $00 across all 40 columns and $8D16 flips the buffer select $0F, so both the $2000 and the $6000 bitmap end up blank.","t":"code","b":[32,224,140],"m":"jsr","oa":36064,"o":"draw_layer_reset","x":[38309]},{"a":48077,"t":"code","b":[162,0],"m":"ldx","o":"#$00"},{"a":48079,"t":"code","b":[160,167],"m":"ldy","o":"#$A7"},{"a":48081,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48083,"t":"code","b":[32,66,141],"m":"jsr","oa":36162,"o":"fill_rows"},{"a":48086,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":48089,"t":"code","b":[162,0],"m":"ldx","o":"#$00"},{"a":48091,"t":"code","b":[160,167],"m":"ldy","o":"#$A7"},{"a":48093,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48095,"t":"code","b":[32,66,141],"m":"jsr","oa":36162,"o":"fill_rows"},{"a":48098,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":48101,"t":"code","b":[96],"m":"rts"},{"a":48102,"l":"erase_last_frame","c":"Erases everything the game drew into this video buffer two frames ago, the first thing every draw sequence does ($95CB, $9651, $96A8, $9715, $9746, $9758). The game keeps two dirty-rectangle lists, $0D03 and $0DA3 set up by $A9E1, forty 4-byte records each, addressed through $99/$9A and $9B/$9C with their counts in $9D and $9E; this routine swaps the two pairs so $99 selects the list belonging to the buffer about to be drawn, walks its $9D records and clears the count. Each record, written by $AA38, is (code, screen-relative X low, X high, row). The code doubles into the size table at $94AF to give a width in character columns and a height in bitmap rows; code 0 additionally shifts the rectangle $16 left and $0E up. A rectangle hanging off the left edge has the overhang divided by 8 and taken off its width before X is clamped to 0, and one reaching above row $A7 has the overhang taken off its height before the row is clamped, which is the whole of the clipping.","t":"code","b":[166,153],"m":"ldx","oa":153,"o":"list_cur","x":[38347,38481,38568,38677,38726,38744]},{"a":48104,"t":"code","b":[164,155],"m":"ldy","oa":155,"o":"list_prev"},{"a":48106,"t":"code","b":[132,153],"m":"sty","oa":153,"o":"list_cur"},{"a":48108,"t":"code","b":[134,155],"m":"stx","oa":155,"o":"list_prev"},{"a":48110,"t":"code","b":[166,154],"m":"ldx","oa":154,"o":"zpa_9A"},{"a":48112,"t":"code","b":[164,156],"m":"ldy","oa":156,"o":"zpa_9C"},{"a":48114,"t":"code","b":[132,154],"m":"sty","oa":154,"o":"zpa_9A"},{"a":48116,"t":"code","b":[134,156],"m":"stx","oa":156,"o":"zpa_9C"},{"a":48118,"t":"code","b":[166,157],"m":"ldx","oa":157,"o":"list_cur_len"},{"a":48120,"t":"code","b":[164,158],"m":"ldy","oa":158,"o":"zpa_9E"},{"a":48122,"t":"code","b":[132,157],"m":"sty","oa":157,"o":"list_cur_len"},{"a":48124,"t":"code","b":[134,158],"m":"stx","oa":158,"o":"zpa_9E"},{"a":48126,"t":"code","b":[165,157],"m":"lda","oa":157,"o":"list_cur_len"},{"a":48128,"t":"code","b":[208,1],"m":"bne","oa":48131,"o":"b_BC03"},{"a":48130,"t":"code","b":[96],"m":"rts"},{"a":48131,"l":"b_BC03","t":"code","b":[160,0],"m":"ldy","o":"#$00","x":[48128]},{"a":48133,"l":"j_BC05","t":"code","b":[177,153],"m":"lda","oa":153,"o":"(list_cur),y","x":[48282]},{"a":48135,"t":"code","b":[133,113],"m":"sta","oa":113,"o":"ent_kind"},{"a":48137,"t":"code","b":[200],"m":"iny"},{"a":48138,"t":"code","b":[177,153],"m":"lda","oa":153,"o":"(list_cur),y"},{"a":48140,"t":"code","b":[133,106],"m":"sta","oa":106,"o":"ent_x"},{"a":48142,"t":"code","b":[200],"m":"iny"},{"a":48143,"t":"code","b":[177,153],"m":"lda","oa":153,"o":"(list_cur),y"},{"a":48145,"t":"code","b":[133,107],"m":"sta","oa":107,"o":"zpa_6B"},{"a":48147,"t":"code","b":[200],"m":"iny"},{"a":48148,"t":"code","b":[177,153],"m":"lda","oa":153,"o":"(list_cur),y"},{"a":48150,"t":"code","b":[133,108],"m":"sta","oa":108,"o":"ent_row"},{"a":48152,"t":"code","b":[200],"m":"iny"},{"a":48153,"t":"code","b":[165,113],"m":"lda","oa":113,"o":"ent_kind"},{"a":48155,"t":"code","b":[10],"m":"asl","o":"a"},{"a":48156,"t":"code","b":[170],"m":"tax"},{"a":48157,"t":"code","b":[189,175,148],"m":"lda","oa":38063,"o":"erase_box_w,x"},{"a":48160,"t":"code","b":[133,123],"m":"sta","oa":123,"o":"off_x"},{"a":48162,"t":"code","b":[189,176,148],"m":"lda","oa":38064,"o":"erase_box_h,x"},{"a":48165,"t":"code","b":[133,124],"m":"sta","oa":124,"o":"zpa_7C"},{"a":48167,"t":"code","b":[165,113],"m":"lda","oa":113,"o":"ent_kind"},{"a":48169,"t":"code","b":[208,18],"m":"bne","oa":48189,"o":"b_BC3D"},{"a":48171,"t":"code","b":[56],"m":"sec"},{"a":48172,"t":"code","b":[165,106],"m":"lda","oa":106,"o":"ent_x"},{"a":48174,"t":"code","b":[233,22],"m":"sbc","o":"#$16"},{"a":48176,"t":"code","b":[133,106],"m":"sta","oa":106,"o":"ent_x"},{"a":48178,"t":"code","b":[176,2],"m":"bcs","oa":48182,"o":"b_BC36"},{"a":48180,"t":"code","b":[198,107],"m":"dec","oa":107,"o":"zpa_6B"},{"a":48182,"l":"b_BC36","t":"code","b":[24],"m":"clc","x":[48178]},{"a":48183,"t":"code","b":[165,108],"m":"lda","oa":108,"o":"ent_row"},{"a":48185,"t":"code","b":[105,14],"m":"adc","o":"#$0E"},{"a":48187,"t":"code","b":[133,108],"m":"sta","oa":108,"o":"ent_row"},{"a":48189,"l":"b_BC3D","t":"code","b":[36,107],"m":"bit","oa":107,"o":"zpa_6B","x":[48169]},{"a":48191,"t":"code","b":[16,25],"m":"bpl","oa":48218,"o":"b_BC5A"},{"a":48193,"t":"code","b":[165,106],"m":"lda","oa":106,"o":"ent_x"},{"a":48195,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":48197,"t":"code","b":[24],"m":"clc"},{"a":48198,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":48200,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":48201,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":48202,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":48203,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":48205,"t":"code","b":[56],"m":"sec"},{"a":48206,"t":"code","b":[165,123],"m":"lda","oa":123,"o":"off_x"},{"a":48208,"t":"code","b":[229,109],"m":"sbc","oa":109,"o":"zpa_6D"},{"a":48210,"t":"code","b":[133,123],"m":"sta","oa":123,"o":"off_x"},{"a":48212,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48214,"t":"code","b":[133,106],"m":"sta","oa":106,"o":"ent_x"},{"a":48216,"t":"code","b":[133,107],"m":"sta","oa":107,"o":"zpa_6B"},{"a":48218,"l":"b_BC5A","t":"code","b":[165,124],"m":"lda","oa":124,"o":"zpa_7C","x":[48191]},{"a":48220,"t":"code","b":[141,82,11],"m":"sta","oa":2898,"o":"erase_h"},{"a":48223,"t":"code","b":[56],"m":"sec"},{"a":48224,"t":"code","b":[165,108],"m":"lda","oa":108,"o":"ent_row"},{"a":48226,"t":"code","b":[233,167],"m":"sbc","o":"#$A7"},{"a":48228,"t":"code","b":[144,22],"m":"bcc","oa":48252,"o":"b_BC7C"},{"a":48230,"t":"code","b":[240,20],"m":"beq","oa":48252,"o":"b_BC7C"},{"a":48232,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":48234,"t":"code","b":[205,82,11],"m":"cmp","oa":2898,"o":"erase_h"},{"a":48237,"t":"code","b":[176,39],"m":"bcs","oa":48278,"o":"b_BC96"},{"a":48239,"t":"code","b":[56],"m":"sec"},{"a":48240,"t":"code","b":[173,82,11],"m":"lda","oa":2898,"o":"erase_h"},{"a":48243,"t":"code","b":[229,109],"m":"sbc","oa":109,"o":"zpa_6D"},{"a":48245,"t":"code","b":[141,82,11],"m":"sta","oa":2898,"o":"erase_h"},{"a":48248,"t":"code","b":[169,167],"m":"lda","o":"#$A7"},{"a":48250,"t":"code","b":[133,108],"m":"sta","oa":108,"o":"ent_row"},{"a":48252,"l":"b_BC7C","t":"code","b":[173,82,11],"m":"lda","oa":2898,"o":"erase_h","x":[48228,48230]},{"a":48255,"t":"code","b":[240,21],"m":"beq","oa":48278,"o":"b_BC96"},{"a":48257,"t":"code","b":[141,69,14],"m":"sta","oa":3653,"o":"a_0E45"},{"a":48260,"t":"code","b":[165,123],"m":"lda","oa":123,"o":"off_x"},{"a":48262,"t":"code","b":[141,68,14],"m":"sta","oa":3652,"o":"erase_hdr"},{"a":48265,"t":"code","b":[32,186,139],"m":"jsr","oa":35770,"o":"inline_fill_record"},{"a":48268,"t":"gap","n":2},{"a":48270,"l":"erase_rect_paint","c":"Paints one dirty rectangle out. $8B91 - the fifth inline-parameter routine, alongside $8BBA, $8BE0, $8BF9 and $8C17, and called from nowhere else - takes the three bytes at $006A and puts the screen-relative X in $04/$05 and the row in $03, skipping the clipper entirely. $8C5E then fills width by height from the header at $0E44/$0E45 using the four pattern bytes at $0E46, which are zero, so the rectangle is cleared to background.","t":"code","b":[32,145,139],"m":"jsr","oa":35729,"o":"inline_set_draw_pos"},{"a":48273,"t":"gap","n":2},{"a":48275,"l":"erase_rect_next","c":"Steps to the next dirty-rectangle record, four bytes on, and loops until Y reaches the count $9D; then sets $9D to zero so this frame's $AA38 calls start refilling the same list from the beginning.","t":"code","b":[32,94,140],"m":"jsr","oa":35934,"o":"fill_rect_pattern"},{"a":48278,"l":"b_BC96","t":"code","b":[196,157],"m":"cpy","oa":157,"o":"list_cur_len","x":[48237,48255]},{"a":48280,"t":"code","b":[240,3],"m":"beq","oa":48285,"o":"b_BC9D"},{"a":48282,"t":"code","b":[76,5,188],"m":"jmp","oa":48133,"o":"j_BC05"},{"a":48285,"l":"b_BC9D","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[48280]},{"a":48287,"t":"code","b":[133,157],"m":"sta","oa":157,"o":"list_cur_len"},{"a":48289,"t":"code","b":[96],"m":"rts"},{"a":48290,"l":"scroll_camera","c":"Moves the camera, the 16-bit world X in $75/$76 that every draw routine subtracts through $3B/$3C. Called once per frame at $95D1, $96B4 and $971B. Three cases. While $5F is set (the opening of a sortie) it simply adds 4 a frame and pans right. Otherwise, if the helicopter's facing $59 and the sign of its velocity high byte $52 agree - the pilot is flying the way the machine is pointing - it leads the helicopter at $BD18; if they disagree, or $5D is zero, it snaps at $BCCC: the helicopter's world X $55/$56 must stay between $46 and $FA (70 and 250) units right of the camera, and the camera is moved the minimum needed to restore that. $BD18 instead aims at the helicopter's position plus a thirty-second of its velocity, less $46 when flying left or $FA when flying right, and closes on that target by the step $BDD1 computes. Every path ends at $BD9C, which clamps the camera to $02B0..$11D8 - the edges of the world - and hands it to $8C17 to become the clip origin $3B/$3C.","t":"code","b":[165,95],"m":"lda","oa":95,"o":"zpa_5F","x":[38353,38580,38683]},{"a":48292,"t":"code","b":[208,24],"m":"bne","oa":48318,"o":"b_BCBE"},{"a":48294,"t":"code","b":[165,93],"m":"lda","oa":93,"o":"rotor_up"},{"a":48296,"t":"code","b":[240,34],"m":"beq","oa":48332,"o":"b_BCCC"},{"a":48298,"t":"code","b":[165,89],"m":"lda","oa":89,"o":"heli_facing"},{"a":48300,"t":"code","b":[240,13],"m":"beq","oa":48315,"o":"b_BCBB"},{"a":48302,"t":"code","b":[48,7],"m":"bmi","oa":48311,"o":"b_BCB7"},{"a":48304,"t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52"},{"a":48306,"t":"code","b":[48,24],"m":"bmi","oa":48332,"o":"b_BCCC"},{"a":48308,"t":"code","b":[76,24,189],"m":"jmp","oa":48408,"o":"j_BD18"},{"a":48311,"l":"b_BCB7","t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52","x":[48302]},{"a":48313,"t":"code","b":[16,17],"m":"bpl","oa":48332,"o":"b_BCCC"},{"a":48315,"l":"b_BCBB","t":"code","b":[76,24,189],"m":"jmp","oa":48408,"o":"j_BD18","x":[48300]},{"a":48318,"l":"b_BCBE","t":"code","b":[24],"m":"clc","x":[48292]},{"a":48319,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":48321,"t":"code","b":[105,4],"m":"adc","o":"#$04"},{"a":48323,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":48325,"t":"code","b":[144,2],"m":"bcc","oa":48329,"o":"b_BCC9"},{"a":48327,"t":"code","b":[230,118],"m":"inc","oa":118,"o":"zpa_76"},{"a":48329,"l":"b_BCC9","t":"code","b":[76,156,189],"m":"jmp","oa":48540,"o":"j_BD9C","x":[48325]},{"a":48332,"l":"b_BCCC","t":"code","b":[56],"m":"sec","x":[48296,48306,48313]},{"a":48333,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":48335,"t":"code","b":[229,117],"m":"sbc","oa":117,"o":"view_org"},{"a":48337,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":48339,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":48341,"t":"code","b":[229,118],"m":"sbc","oa":118,"o":"zpa_76"},{"a":48343,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":48345,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48347,"t":"code","b":[197,110],"m":"cmp","oa":110,"o":"zpa_6E"},{"a":48349,"t":"code","b":[144,8],"m":"bcc","oa":48359,"o":"b_BCE7"},{"a":48351,"t":"code","b":[208,22],"m":"bne","oa":48375,"o":"b_BCF7"},{"a":48353,"t":"code","b":[169,250],"m":"lda","o":"#$FA"},{"a":48355,"t":"code","b":[197,109],"m":"cmp","oa":109,"o":"zpa_6D"},{"a":48357,"t":"code","b":[176,16],"m":"bcs","oa":48375,"o":"b_BCF7"},{"a":48359,"l":"b_BCE7","t":"code","b":[56],"m":"sec","x":[48349]},{"a":48360,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":48362,"t":"code","b":[233,250],"m":"sbc","o":"#$FA"},{"a":48364,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":48366,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":48368,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":48370,"t":"code","b":[133,118],"m":"sta","oa":118,"o":"zpa_76"},{"a":48372,"t":"code","b":[76,156,189],"m":"jmp","oa":48540,"o":"j_BD9C"},{"a":48375,"l":"b_BCF7","t":"code","b":[165,110],"m":"lda","oa":110,"o":"zpa_6E","x":[48351,48357]},{"a":48377,"t":"code","b":[201,0],"m":"cmp","o":"#$00"},{"a":48379,"t":"code","b":[144,8],"m":"bcc","oa":48389,"o":"b_BD05"},{"a":48381,"t":"code","b":[208,22],"m":"bne","oa":48405,"o":"b_BD15"},{"a":48383,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":48385,"t":"code","b":[201,70],"m":"cmp","o":"#$46"},{"a":48387,"t":"code","b":[176,16],"m":"bcs","oa":48405,"o":"b_BD15"},{"a":48389,"l":"b_BD05","t":"code","b":[56],"m":"sec","x":[48379]},{"a":48390,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":48392,"t":"code","b":[233,70],"m":"sbc","o":"#$46"},{"a":48394,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":48396,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":48398,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":48400,"t":"code","b":[133,118],"m":"sta","oa":118,"o":"zpa_76"},{"a":48402,"t":"code","b":[76,156,189],"m":"jmp","oa":48540,"o":"j_BD9C"},{"a":48405,"l":"b_BD15","t":"code","b":[76,208,189],"m":"jmp","oa":48592,"o":"scroll_unchanged","x":[48381,48387]},{"a":48408,"l":"j_BD18","t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51","x":[48308,48315]},{"a":48410,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":48412,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":48414,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":48416,"t":"code","b":[160,5],"m":"ldy","o":"#$05"},{"a":48418,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":48421,"t":"code","b":[24],"m":"clc"},{"a":48422,"t":"code","b":[165,85],"m":"lda","oa":85,"o":"world_x"},{"a":48424,"t":"code","b":[101,127],"m":"adc","oa":127,"o":"zpa_7F"},{"a":48426,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":48428,"t":"code","b":[165,86],"m":"lda","oa":86,"o":"zpa_56"},{"a":48430,"t":"code","b":[101,128],"m":"adc","oa":128,"o":"zpa_80"},{"a":48432,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":48434,"t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52"},{"a":48436,"t":"code","b":[48,2],"m":"bmi","oa":48440,"o":"b_BD38"},{"a":48438,"t":"code","b":[16,16],"m":"bpl","oa":48456,"o":"b_BD48"},{"a":48440,"l":"b_BD38","t":"code","b":[56],"m":"sec","x":[48436]},{"a":48441,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":48443,"t":"code","b":[233,70],"m":"sbc","o":"#$46"},{"a":48445,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":48447,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":48449,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":48451,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":48453,"t":"code","b":[76,85,189],"m":"jmp","oa":48469,"o":"j_BD55"},{"a":48456,"l":"b_BD48","t":"code","b":[56],"m":"sec","x":[48438]},{"a":48457,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":48459,"t":"code","b":[233,250],"m":"sbc","o":"#$FA"},{"a":48461,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":48463,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":48465,"t":"code","b":[233,0],"m":"sbc","o":"#$00"},{"a":48467,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":48469,"l":"j_BD55","t":"code","b":[36,82],"m":"bit","oa":82,"o":"zpa_52","x":[48453]},{"a":48471,"t":"code","b":[16,2],"m":"bpl","oa":48475,"o":"b_BD5B"},{"a":48473,"t":"code","b":[48,37],"m":"bmi","oa":48512,"o":"b_BD80"},{"a":48475,"l":"b_BD5B","t":"code","b":[165,118],"m":"lda","oa":118,"o":"zpa_76","x":[48471]},{"a":48477,"t":"code","b":[197,110],"m":"cmp","oa":110,"o":"zpa_6E"},{"a":48479,"t":"code","b":[144,14],"m":"bcc","oa":48495,"o":"b_BD6F"},{"a":48481,"t":"code","b":[208,9],"m":"bne","oa":48492,"o":"b_BD6C"},{"a":48483,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":48485,"t":"code","b":[197,109],"m":"cmp","oa":109,"o":"zpa_6D"},{"a":48487,"t":"code","b":[176,3],"m":"bcs","oa":48492,"o":"b_BD6C"},{"a":48489,"t":"code","b":[76,111,189],"m":"jmp","oa":48495,"o":"b_BD6F"},{"a":48492,"l":"b_BD6C","t":"code","b":[76,208,189],"m":"jmp","oa":48592,"o":"scroll_unchanged","x":[48481,48487]},{"a":48495,"l":"b_BD6F","t":"code","b":[32,209,189],"m":"jsr","oa":48593,"o":"scroll_step_size","x":[48479,48489]},{"a":48498,"t":"code","b":[24],"m":"clc"},{"a":48499,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":48501,"t":"code","b":[101,125],"m":"adc","oa":125,"o":"zpa_7D"},{"a":48503,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":48505,"t":"code","b":[144,2],"m":"bcc","oa":48509,"o":"b_BD7D"},{"a":48507,"t":"code","b":[230,118],"m":"inc","oa":118,"o":"zpa_76"},{"a":48509,"l":"b_BD7D","t":"code","b":[76,156,189],"m":"jmp","oa":48540,"o":"j_BD9C","x":[48505]},{"a":48512,"l":"b_BD80","t":"code","b":[165,110],"m":"lda","oa":110,"o":"zpa_6E","x":[48473]},{"a":48514,"t":"code","b":[197,118],"m":"cmp","oa":118,"o":"zpa_76"},{"a":48516,"t":"code","b":[144,8],"m":"bcc","oa":48526,"o":"b_BD8E"},{"a":48518,"t":"code","b":[208,72],"m":"bne","oa":48592,"o":"scroll_unchanged"},{"a":48520,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":48522,"t":"code","b":[197,117],"m":"cmp","oa":117,"o":"view_org"},{"a":48524,"t":"code","b":[176,66],"m":"bcs","oa":48592,"o":"scroll_unchanged"},{"a":48526,"l":"b_BD8E","t":"code","b":[32,209,189],"m":"jsr","oa":48593,"o":"scroll_step_size","x":[48516]},{"a":48529,"t":"code","b":[56],"m":"sec"},{"a":48530,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":48532,"t":"code","b":[229,125],"m":"sbc","oa":125,"o":"zpa_7D"},{"a":48534,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":48536,"t":"code","b":[176,2],"m":"bcs","oa":48540,"o":"j_BD9C"},{"a":48538,"t":"code","b":[198,118],"m":"dec","oa":118,"o":"zpa_76"},{"a":48540,"l":"j_BD9C","t":"code","b":[169,17],"m":"lda","o":"#$11","x":[48329,48372,48402,48509,48536]},{"a":48542,"t":"code","b":[197,118],"m":"cmp","oa":118,"o":"zpa_76"},{"a":48544,"t":"code","b":[144,8],"m":"bcc","oa":48554,"o":"b_BDAA"},{"a":48546,"t":"code","b":[208,17],"m":"bne","oa":48565,"o":"b_BDB5"},{"a":48548,"t":"code","b":[169,216],"m":"lda","o":"#$D8"},{"a":48550,"t":"code","b":[197,117],"m":"cmp","oa":117,"o":"view_org"},{"a":48552,"t":"code","b":[176,33],"m":"bcs","oa":48587,"o":"b_BDCB"},{"a":48554,"l":"b_BDAA","t":"code","b":[169,216],"m":"lda","o":"#$D8","x":[48544]},{"a":48556,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":48558,"t":"code","b":[169,17],"m":"lda","o":"#$11"},{"a":48560,"t":"code","b":[133,118],"m":"sta","oa":118,"o":"zpa_76"},{"a":48562,"t":"code","b":[76,203,189],"m":"jmp","oa":48587,"o":"b_BDCB"},{"a":48565,"l":"b_BDB5","t":"code","b":[165,118],"m":"lda","oa":118,"o":"zpa_76","x":[48546]},{"a":48567,"t":"code","b":[201,2],"m":"cmp","o":"#$02"},{"a":48569,"t":"code","b":[144,8],"m":"bcc","oa":48579,"o":"b_BDC3"},{"a":48571,"t":"code","b":[208,14],"m":"bne","oa":48587,"o":"b_BDCB"},{"a":48573,"t":"code","b":[165,117],"m":"lda","oa":117,"o":"view_org"},{"a":48575,"t":"code","b":[201,176],"m":"cmp","o":"#$B0"},{"a":48577,"t":"code","b":[176,8],"m":"bcs","oa":48587,"o":"b_BDCB"},{"a":48579,"l":"b_BDC3","t":"code","b":[169,176],"m":"lda","o":"#$B0","x":[48569]},{"a":48581,"t":"code","b":[133,117],"m":"sta","oa":117,"o":"view_org"},{"a":48583,"t":"code","b":[169,2],"m":"lda","o":"#$02"},{"a":48585,"t":"code","b":[133,118],"m":"sta","oa":118,"o":"zpa_76"},{"a":48587,"l":"b_BDCB","t":"code","b":[32,23,140],"m":"jsr","oa":35863,"o":"inline_window_x","x":[48552,48562,48571,48577]},{"a":48590,"t":"gap","n":2},{"a":48592,"l":"scroll_unchanged","c":"Shared exit taken when the camera is already where it should be: nothing is written and $3B/$3C keeps the value it was given last frame.","t":"code","b":[96],"m":"rts","x":[48405,48492,48518,48524]},{"a":48593,"l":"scroll_step_size","c":"Works out how far the camera may travel this frame and leaves it in $7D. The base speed is 4 plus the magnitude of the helicopter's velocity $51/$52 divided by 256 (the signed shift $ACF1 with Y=8, then absolute value), so the view opens up as the machine accelerates. That is then capped at the distance still to go, |target - camera| from $6D/$6E, whenever the high byte of that distance is zero, so the camera never overshoots its mark.","t":"code","b":[165,81],"m":"lda","oa":81,"o":"zpa_51","x":[48495,48526]},{"a":48595,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":48597,"t":"code","b":[165,82],"m":"lda","oa":82,"o":"zpa_52"},{"a":48599,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":48601,"t":"code","b":[160,8],"m":"ldy","o":"#$08"},{"a":48603,"t":"code","b":[32,241,172],"m":"jsr","oa":44273,"o":"asr16"},{"a":48606,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":48608,"t":"code","b":[16,5],"m":"bpl","oa":48615,"o":"b_BDE7"},{"a":48610,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":48612,"t":"code","b":[24],"m":"clc"},{"a":48613,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":48615,"l":"b_BDE7","t":"code","b":[24],"m":"clc","x":[48608]},{"a":48616,"t":"code","b":[105,4],"m":"adc","o":"#$04"},{"a":48618,"t":"code","b":[133,125],"m":"sta","oa":125,"o":"zpa_7D"},{"a":48620,"t":"code","b":[56],"m":"sec"},{"a":48621,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":48623,"t":"code","b":[229,117],"m":"sbc","oa":117,"o":"view_org"},{"a":48625,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":48627,"t":"code","b":[165,110],"m":"lda","oa":110,"o":"zpa_6E"},{"a":48629,"t":"code","b":[229,118],"m":"sbc","oa":118,"o":"zpa_76"},{"a":48631,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":48633,"t":"code","b":[36,128],"m":"bit","oa":128,"o":"zpa_80"},{"a":48635,"t":"code","b":[16,17],"m":"bpl","oa":48654,"o":"b_BE0E"},{"a":48637,"t":"code","b":[24],"m":"clc"},{"a":48638,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":48640,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":48642,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":48644,"t":"code","b":[133,127],"m":"sta","oa":127,"o":"zpa_7F"},{"a":48646,"t":"code","b":[165,128],"m":"lda","oa":128,"o":"zpa_80"},{"a":48648,"t":"code","b":[73,255],"m":"eor","o":"#$FF"},{"a":48650,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":48652,"t":"code","b":[133,128],"m":"sta","oa":128,"o":"zpa_80"},{"a":48654,"l":"b_BE0E","t":"code","b":[165,125],"m":"lda","oa":125,"o":"zpa_7D","x":[48635]},{"a":48656,"t":"code","b":[166,128],"m":"ldx","oa":128,"o":"zpa_80"},{"a":48658,"t":"code","b":[208,6],"m":"bne","oa":48666,"o":"b_BE1A"},{"a":48660,"t":"code","b":[197,127],"m":"cmp","oa":127,"o":"zpa_7F"},{"a":48662,"t":"code","b":[144,2],"m":"bcc","oa":48666,"o":"b_BE1A"},{"a":48664,"t":"code","b":[165,127],"m":"lda","oa":127,"o":"zpa_7F"},{"a":48666,"l":"b_BE1A","t":"code","b":[133,125],"m":"sta","oa":125,"o":"zpa_7D","x":[48658,48662]},{"a":48668,"t":"code","b":[96],"m":"rts"},{"a":48669,"l":"shift_left_signed_unused","c":"53 bytes of 6502 code that nothing in the program references: no instruction anywhere in $8000-$BFFF names any address in $BE1D-$BE51. Read as code it is the exact mirror of the signed right shift at $ACF1 - save the sign of $7F/$80, negate if negative, asl $7F / rol $80 Y times, then negate back - that is, multiply the signed 16-bit value in $7F/$80 by 2 to the power Y. Left typed as data because nothing calls it; it looks like a routine that was written, superseded and never removed.","t":"byte","b":[165,128,72,16,18,165,127,73]},{"a":48677,"t":"byte","b":[255,133,127,165,128,73,255,133]},{"a":48685,"t":"byte","b":[128,230,127,208,2,230,128,6]},{"a":48693,"t":"byte","b":[127,38,128,136,208,249,104,48]},{"a":48701,"t":"byte","b":[1,96,165,127,73,255,133,127]},{"a":48709,"t":"byte","b":[165,128,73,255,133,128,230,127]},{"a":48717,"t":"byte","b":[208,2,230,128,96]},{"a":48722,"l":"start_sortie_world","c":"Sets up the world for a sortie, called once per sortie from $9618. There is no level or world table anywhere: the layout is these constants plus one use of the random source. It puts eight people on the ground ($0CF0 = 8), leaves 56 still indoors ($0CED = $38), and marks the fourth shed as already open with only eight left inside ($0CF7 = 1, $0CFB = 8 - these are element 3 of the shed-state and shed-count arrays that start at $0CF4 and $0CF8, which is why they look like lone variables). It then fills the first eight of the sixteen 4-byte records at $0CA0: field 0 is the walk-animation phase, seeded 0,1,2,3,0,1,2,3 so they do not step in time; field 1 is the walk direction, zero here so everybody starts standing; fields 2 and 3 are the 16-bit world X, starting at $0750 and advanced for each person by $20 plus a CIA1 timer sample masked with $7E ($A933), i.e. an even gap of 32 to 158 units. That spacing is the only thing that differs between one sortie and the next. The records are read and drawn by $9B7D.","t":"code","b":[169,8],"m":"lda","o":"#$08","x":[38424]},{"a":48724,"t":"code","b":[141,240,12],"m":"sta","oa":3312,"o":"a_0CF0"},{"a":48727,"t":"code","b":[169,56],"m":"lda","o":"#$38"},{"a":48729,"t":"code","b":[141,237,12],"m":"sta","oa":3309,"o":"a_0CED"},{"a":48732,"t":"code","b":[169,8],"m":"lda","o":"#$08"},{"a":48734,"t":"code","b":[141,251,12],"m":"sta","oa":3323,"o":"a_0CFB"},{"a":48737,"t":"code","b":[169,1],"m":"lda","o":"#$01"},{"a":48739,"t":"code","b":[141,247,12],"m":"sta","oa":3319,"o":"a_0CF7"},{"a":48742,"t":"code","b":[24],"m":"clc"},{"a":48743,"t":"code","b":[169,128],"m":"lda","o":"#$80"},{"a":48745,"t":"code","b":[105,208],"m":"adc","o":"#$D0"},{"a":48747,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":48749,"t":"code","b":[169,3],"m":"lda","o":"#$03"},{"a":48751,"t":"code","b":[105,3],"m":"adc","o":"#$03"},{"a":48753,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":48755,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48757,"t":"code","b":[133,113],"m":"sta","oa":113,"o":"ent_kind"},{"a":48759,"t":"code","b":[170],"m":"tax"},{"a":48760,"t":"code","b":[168],"m":"tay"},{"a":48761,"l":"j_BE79","t":"code","b":[152],"m":"tya","x":[48817]},{"a":48762,"t":"code","b":[157,160,12],"m":"sta","oa":3232,"o":"person_state,x"},{"a":48765,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48767,"t":"code","b":[157,161,12],"m":"sta","oa":3233,"o":"person_dir,x"},{"a":48770,"t":"code","b":[165,111],"m":"lda","oa":111,"o":"zpa_6F"},{"a":48772,"t":"code","b":[157,162,12],"m":"sta","oa":3234,"o":"person_x,x"},{"a":48775,"t":"code","b":[165,112],"m":"lda","oa":112,"o":"zpa_70"},{"a":48777,"t":"code","b":[157,163,12],"m":"sta","oa":3235,"o":"person_x_hi,x"},{"a":48780,"t":"code","b":[230,113],"m":"inc","oa":113,"o":"ent_kind"},{"a":48782,"t":"code","b":[165,113],"m":"lda","oa":113,"o":"ent_kind"},{"a":48784,"t":"code","b":[201,8],"m":"cmp","o":"#$08"},{"a":48786,"t":"code","b":[240,32],"m":"beq","oa":48820,"o":"r_BEB4"},{"a":48788,"t":"code","b":[10],"m":"asl","o":"a"},{"a":48789,"t":"code","b":[10],"m":"asl","o":"a"},{"a":48790,"t":"code","b":[170],"m":"tax"},{"a":48791,"t":"code","b":[200],"m":"iny"},{"a":48792,"t":"code","b":[192,4],"m":"cpy","o":"#$04"},{"a":48794,"t":"code","b":[208,2],"m":"bne","oa":48798,"o":"b_BE9E"},{"a":48796,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":48798,"l":"b_BE9E","t":"code","b":[32,51,169],"m":"jsr","oa":43315,"o":"random_byte","x":[48794]},{"a":48801,"t":"code","b":[41,126],"m":"and","o":"#$7E"},{"a":48803,"t":"code","b":[24],"m":"clc"},{"a":48804,"t":"code","b":[105,32],"m":"adc","o":"#$20"},{"a":48806,"t":"code","b":[24],"m":"clc"},{"a":48807,"t":"code","b":[101,111],"m":"adc","oa":111,"o":"zpa_6F"},{"a":48809,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":48811,"t":"code","b":[165,112],"m":"lda","oa":112,"o":"zpa_70"},{"a":48813,"t":"code","b":[105,0],"m":"adc","o":"#$00"},{"a":48815,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":48817,"t":"code","b":[76,121,190],"m":"jmp","oa":48761,"o":"j_BE79"},{"a":48820,"l":"r_BEB4","t":"code","b":[96],"m":"rts","x":[48786]},{"a":48821,"l":"reset_helicopter","c":"Puts the helicopter back to its starting state, called at $95A8 on boot, at $95B5 when the attract loop starts and at $962C at the head of every sortie. Sets the facing $59 to 3 and the flags $8A, $5E and $5F to 1, clears $8B, $5A..$5D, $60..$64 and $0CF3, zeroes the 16-bit velocity $51/$52 and $53/$54, and places the machine at world X $1273 ($55/$56), a few units right of the base at $1254, with $57 = 7 and $58 = $16. $5F being set is what makes $BCA2 pan the camera right at 4 units a frame until the sortie proper begins. It then calls $A9E1 to rebuild the actor free list and empty both dirty-rectangle lists, selects buffer 0 with $8D0F, and runs $8D16/$8D1F/$8D16 so the VIC bank in $DD00 and the buffer-select flag $0F agree again. Finally clears $0D00.","t":"code","b":[169,3],"m":"lda","o":"#$03","x":[38312,38325,38444]},{"a":48823,"t":"code","b":[133,89],"m":"sta","oa":89,"o":"heli_facing"},{"a":48825,"t":"code","b":[162,1],"m":"ldx","o":"#$01"},{"a":48827,"t":"code","b":[134,138],"m":"stx","oa":138,"o":"turn_request"},{"a":48829,"t":"code","b":[134,94],"m":"stx","oa":94,"o":"zpa_5E"},{"a":48831,"t":"code","b":[134,95],"m":"stx","oa":95,"o":"zpa_5F"},{"a":48833,"t":"code","b":[202],"m":"dex"},{"a":48834,"t":"code","b":[134,139],"m":"stx","oa":139,"o":"zpa_8B"},{"a":48836,"t":"code","b":[134,90],"m":"stx","oa":90,"o":"zpa_5A"},{"a":48838,"t":"code","b":[134,91],"m":"stx","oa":91,"o":"stick_x"},{"a":48840,"t":"code","b":[134,92],"m":"stx","oa":92,"o":"stick_y"},{"a":48842,"t":"code","b":[134,93],"m":"stx","oa":93,"o":"rotor_up"},{"a":48844,"t":"code","b":[134,98],"m":"stx","oa":98,"o":"zpa_62"},{"a":48846,"t":"code","b":[134,96],"m":"stx","oa":96,"o":"zpa_60"},{"a":48848,"t":"code","b":[134,97],"m":"stx","oa":97,"o":"zpa_61"},{"a":48850,"t":"code","b":[134,99],"m":"stx","oa":99,"o":"sortie_end_delay"},{"a":48852,"t":"code","b":[134,100],"m":"stx","oa":100,"o":"fire_latch"},{"a":48854,"t":"code","b":[142,243,12],"m":"stx","oa":3315,"o":"shots_in_flight"},{"a":48857,"t":"code","b":[134,81],"m":"stx","oa":81,"o":"zpa_51"},{"a":48859,"t":"code","b":[134,82],"m":"stx","oa":82,"o":"zpa_52"},{"a":48861,"t":"code","b":[134,83],"m":"stx","oa":83,"o":"zpa_53"},{"a":48863,"t":"code","b":[134,84],"m":"stx","oa":84,"o":"zpa_54"},{"a":48865,"t":"code","b":[169,115],"m":"lda","o":"#$73"},{"a":48867,"t":"code","b":[133,85],"m":"sta","oa":85,"o":"world_x"},{"a":48869,"t":"code","b":[169,18],"m":"lda","o":"#$12"},{"a":48871,"t":"code","b":[133,86],"m":"sta","oa":86,"o":"zpa_56"},{"a":48873,"t":"code","b":[169,7],"m":"lda","o":"#$07"},{"a":48875,"t":"code","b":[133,87],"m":"sta","oa":87,"o":"zpa_57"},{"a":48877,"t":"code","b":[169,22],"m":"lda","o":"#$16"},{"a":48879,"t":"code","b":[133,88],"m":"sta","oa":88,"o":"ground_row"},{"a":48881,"t":"code","b":[32,225,169],"m":"jsr","oa":43489,"o":"actor_list_init"},{"a":48884,"t":"code","b":[32,15,141],"m":"jsr","oa":36111,"o":"draw_to_bank0"},{"a":48887,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":48890,"t":"code","b":[32,31,141],"m":"jsr","oa":36127,"o":"show_draw_buffer"},{"a":48893,"t":"code","b":[32,22,141],"m":"jsr","oa":36118,"o":"flip_draw_buffer"},{"a":48896,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":48898,"t":"code","b":[141,0,13],"m":"sta","oa":3328,"o":"a_0D00"},{"a":48901,"t":"code","b":[96],"m":"rts"},{"a":48902,"l":"cold_init","c":"Cold initialisation: the very first thing $959C calls, and the routine that builds every lookup table the renderer depends on. Five phases. (1) Clears $0A00-$0EFF - though the store to page $0E is coded three times over and page $0F is never cleared at all - zeroes $02 and $93 and sets the scratch fill header $0E44/$0E45 to $FF. (2) Builds the bitmap row table: $0A00,y low byte and $0AA8,y high byte, 168 entries, starting at $2500 for y = 167 and working down to $3E07 for y = 0, eight rows per character row and $0140 (320) bytes between character rows. So row index 0 is the bottom scanline of the play area and row 167 the top, and the play area begins at character row 4, just under the status bar. The second buffer is reached by exclusive-oring the high byte with $40, which is what $0F holds. (3) Builds the pre-shift tables that let shapes be plotted at any X: for each shift count n = 0..7 and each byte value y, $1000 + n*256 + y holds y >> n and $1800 + n*256 + y holds the bits pushed out of the bottom. That is 4 KB at $1000-$1FFF, RAM the VIC never sees in bank 0 because the character ROM shadows it there. (4) Copies the 2 KB character ROM from $D000 to $5000: CIA1 timer A is stopped first so no jiffy IRQ can fire while I/O is banked out, $01 is taken from $36 to $32 to expose the ROM, 8 pages are copied, $01 is restored and the timer restarted. That copy is why the status bar can use a normal character set in VIC bank 1, where the character base at VIC + $1000 is RAM at $5000. (5) Clears both bitmaps, $2000-$3FFF and $6000-$7FFF.","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[38300]},{"a":48904,"t":"code","b":[133,2],"m":"sta","oa":2,"o":"msg_showing"},{"a":48906,"t":"code","b":[133,147],"m":"sta","oa":147,"o":"text_window_tall"},{"a":48908,"t":"code","b":[168],"m":"tay"},{"a":48909,"l":"b_BF0D","t":"code","b":[153,0,10],"m":"sta","oa":2560,"o":"bitmap_row_lo,y","x":[48931]},{"a":48912,"t":"code","b":[153,0,11],"m":"sta","oa":2816,"o":"bitmap_row_hi_80,y"},{"a":48915,"t":"code","b":[153,0,12],"m":"sta","oa":3072,"o":"actor_slots_14_19,y"},{"a":48918,"t":"code","b":[153,0,13],"m":"sta","oa":3328,"o":"a_0D00,y"},{"a":48921,"s":"page $0E is cleared three times over; page $0F never is","t":"code","b":[153,0,14],"m":"sta","oa":3584,"o":"draw_list_b_23,y"},{"a":48924,"t":"code","b":[153,0,14],"m":"sta","oa":3584,"o":"draw_list_b_23,y"},{"a":48927,"t":"code","b":[153,0,14],"m":"sta","oa":3584,"o":"draw_list_b_23,y"},{"a":48930,"t":"code","b":[200],"m":"iny"},{"a":48931,"t":"code","b":[208,232],"m":"bne","oa":48909,"o":"b_BF0D"},{"a":48933,"t":"code","b":[136],"m":"dey"},{"a":48934,"t":"code","b":[140,68,14],"m":"sty","oa":3652,"o":"erase_hdr"},{"a":48937,"t":"code","b":[140,69,14],"m":"sty","oa":3653,"o":"a_0E45"},{"a":48940,"t":"code","b":[141,143,0],"m":"sta","oa":143,"o":"zpa_8F"},{"a":48943,"s":"168 bitmap rows; index 167 is built first and is the topmost","t":"code","b":[160,167],"m":"ldy","o":"#$A7"},{"a":48945,"s":"$2500, the first byte of the topmost bitmap row: bitmap base $2000 plus four character rows of 320 bytes, which is the status bar's height","t":"code","b":[169,37],"m":"lda","o":"#$25"},{"a":48947,"t":"code","b":[141,144,0],"m":"sta","oa":144,"o":"zpa_90"},{"a":48950,"t":"code","b":[169,21],"m":"lda","o":"#$15"},{"a":48952,"t":"code","b":[141,142,0],"m":"sta","oa":142,"o":"a_008E"},{"a":48955,"l":"b_BF3B","t":"code","b":[162,8],"m":"ldx","o":"#$08","x":[48993]},{"a":48957,"l":"b_BF3D","t":"code","b":[173,144,0],"m":"lda","oa":144,"o":"zpa_90","x":[48974]},{"a":48960,"t":"code","b":[153,168,10],"m":"sta","oa":2728,"o":"bitmap_row_hi,y"},{"a":48963,"t":"code","b":[173,143,0],"m":"lda","oa":143,"o":"zpa_8F"},{"a":48966,"t":"code","b":[153,0,10],"m":"sta","oa":2560,"o":"bitmap_row_lo,y"},{"a":48969,"t":"code","b":[238,143,0],"m":"inc","oa":143,"o":"zpa_8F"},{"a":48972,"t":"code","b":[136],"m":"dey"},{"a":48973,"t":"code","b":[202],"m":"dex"},{"a":48974,"t":"code","b":[208,237],"m":"bne","oa":48957,"o":"b_BF3D"},{"a":48976,"t":"code","b":[24],"m":"clc"},{"a":48977,"t":"code","b":[105,57],"m":"adc","o":"#$39"},{"a":48979,"t":"code","b":[141,143,0],"m":"sta","oa":143,"o":"zpa_8F"},{"a":48982,"t":"code","b":[173,144,0],"m":"lda","oa":144,"o":"zpa_90"},{"a":48985,"t":"code","b":[105,1],"m":"adc","o":"#$01"},{"a":48987,"t":"code","b":[141,144,0],"m":"sta","oa":144,"o":"zpa_90"},{"a":48990,"t":"code","b":[206,142,0],"m":"dec","oa":142,"o":"a_008E"},{"a":48993,"t":"code","b":[208,216],"m":"bne","oa":48955,"o":"b_BF3B"},{"a":48995,"s":"build the eight pre-shift tables at $1000-$17FF and $1800-$1FFF","t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":48997,"t":"code","b":[132,142],"m":"sty","oa":142,"o":"a_008E"},{"a":48999,"t":"code","b":[132,111],"m":"sty","oa":111,"o":"zpa_6F"},{"a":49001,"t":"code","b":[132,143],"m":"sty","oa":143,"o":"zpa_8F"},{"a":49003,"l":"b_BF6B","t":"code","b":[165,142],"m":"lda","oa":142,"o":"a_008E","x":[49048]},{"a":49005,"t":"code","b":[24],"m":"clc"},{"a":49006,"t":"code","b":[105,16],"m":"adc","o":"#$10"},{"a":49008,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":49010,"t":"code","b":[165,142],"m":"lda","oa":142,"o":"a_008E"},{"a":49012,"t":"code","b":[24],"m":"clc"},{"a":49013,"t":"code","b":[105,24],"m":"adc","o":"#$18"},{"a":49015,"t":"code","b":[133,144],"m":"sta","oa":144,"o":"zpa_90"},{"a":49017,"l":"b_BF79","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[49040]},{"a":49019,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":49021,"t":"code","b":[152],"m":"tya"},{"a":49022,"t":"code","b":[166,142],"m":"ldx","oa":142,"o":"a_008E"},{"a":49024,"l":"j_BF80","t":"code","b":[202],"m":"dex","x":[49030]},{"a":49025,"t":"code","b":[48,6],"m":"bmi","oa":49033,"o":"b_BF89"},{"a":49027,"t":"code","b":[74],"m":"lsr","o":"a"},{"a":49028,"t":"code","b":[102,109],"m":"ror","oa":109,"o":"zpa_6D"},{"a":49030,"t":"code","b":[76,128,191],"m":"jmp","oa":49024,"o":"j_BF80"},{"a":49033,"l":"b_BF89","t":"code","b":[145,111],"m":"sta","oa":111,"o":"(zpa_6F),y","x":[49025]},{"a":49035,"t":"code","b":[165,109],"m":"lda","oa":109,"o":"zpa_6D"},{"a":49037,"t":"code","b":[145,143],"m":"sta","oa":143,"o":"(zpa_8F),y"},{"a":49039,"t":"code","b":[200],"m":"iny"},{"a":49040,"t":"code","b":[208,231],"m":"bne","oa":49017,"o":"b_BF79"},{"a":49042,"t":"code","b":[230,142],"m":"inc","oa":142,"o":"a_008E"},{"a":49044,"t":"code","b":[165,142],"m":"lda","oa":142,"o":"a_008E"},{"a":49046,"t":"code","b":[201,8],"m":"cmp","o":"#$08"},{"a":49048,"t":"code","b":[208,209],"m":"bne","oa":49003,"o":"b_BF6B"},{"a":49050,"s":"stop CIA1 timer A: with I/O about to be banked out a jiffy IRQ could not acknowledge itself at $DC0D","t":"code","b":[173,14,220],"m":"lda","oa":56334,"o":"$DC0E"},{"a":49053,"t":"code","b":[41,254],"m":"and","o":"#$FE"},{"a":49055,"t":"code","b":[141,14,220],"m":"sta","oa":56334,"o":"$DC0E"},{"a":49058,"s":"clear CHAREN: $01 goes $36 to $32, character ROM visible at $D000","t":"code","b":[165,1],"m":"lda","oa":1,"o":"cpu_port"},{"a":49060,"t":"code","b":[41,251],"m":"and","o":"#$FB"},{"a":49062,"t":"code","b":[133,1],"m":"sta","oa":1,"o":"cpu_port"},{"a":49064,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":49066,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":49068,"t":"code","b":[169,208],"m":"lda","o":"#$D0"},{"a":49070,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":49072,"s":"destination $5000, the character base the VIC sees at bank 1 + $1000","t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":49074,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":49076,"t":"code","b":[169,80],"m":"lda","o":"#$50"},{"a":49078,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":49080,"t":"code","b":[160,0],"m":"ldy","o":"#$00"},{"a":49082,"l":"b_BFBA","t":"code","b":[177,111],"m":"lda","oa":111,"o":"(zpa_6F),y","x":[49087,49097]},{"a":49084,"t":"code","b":[145,109],"m":"sta","oa":109,"o":"(zpa_6D),y"},{"a":49086,"t":"code","b":[200],"m":"iny"},{"a":49087,"t":"code","b":[208,249],"m":"bne","oa":49082,"o":"b_BFBA"},{"a":49089,"t":"code","b":[230,112],"m":"inc","oa":112,"o":"zpa_70"},{"a":49091,"t":"code","b":[230,110],"m":"inc","oa":110,"o":"zpa_6E"},{"a":49093,"t":"code","b":[165,110],"m":"lda","oa":110,"o":"zpa_6E"},{"a":49095,"s":"stop after 8 pages, $5000-$57FF: the whole 2 KB character ROM","t":"code","b":[201,88],"m":"cmp","o":"#$58"},{"a":49097,"t":"code","b":[144,239],"m":"bcc","oa":49082,"o":"b_BFBA"},{"a":49099,"s":"restore CHAREN, I/O back at $D000","t":"code","b":[165,1],"m":"lda","oa":1,"o":"cpu_port"},{"a":49101,"t":"code","b":[9,4],"m":"ora","o":"#$04"},{"a":49103,"t":"code","b":[133,1],"m":"sta","oa":1,"o":"cpu_port"},{"a":49105,"s":"restart CIA1 timer A","t":"code","b":[173,14,220],"m":"lda","oa":56334,"o":"$DC0E"},{"a":49108,"t":"code","b":[9,1],"m":"ora","o":"#$01"},{"a":49110,"t":"code","b":[141,14,220],"m":"sta","oa":56334,"o":"$DC0E"},{"a":49113,"s":"clear both bitmaps: $2000-$3FFF and $6000-$7FFF, 8 KB each","t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":49115,"t":"code","b":[133,111],"m":"sta","oa":111,"o":"zpa_6F"},{"a":49117,"t":"code","b":[169,32],"m":"lda","o":"#$20"},{"a":49119,"t":"code","b":[133,112],"m":"sta","oa":112,"o":"zpa_70"},{"a":49121,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":49123,"t":"code","b":[133,109],"m":"sta","oa":109,"o":"zpa_6D"},{"a":49125,"t":"code","b":[169,96],"m":"lda","o":"#$60"},{"a":49127,"t":"code","b":[133,110],"m":"sta","oa":110,"o":"zpa_6E"},{"a":49129,"t":"code","b":[169,0],"m":"lda","o":"#$00"},{"a":49131,"l":"b_BFEB","t":"code","b":[169,0],"m":"lda","o":"#$00","x":[49138,49148]},{"a":49133,"t":"code","b":[145,111],"m":"sta","oa":111,"o":"(zpa_6F),y"},{"a":49135,"t":"code","b":[145,109],"m":"sta","oa":109,"o":"(zpa_6D),y"},{"a":49137,"t":"code","b":[200],"m":"iny"},{"a":49138,"t":"code","b":[208,247],"m":"bne","oa":49131,"o":"b_BFEB"},{"a":49140,"t":"code","b":[230,110],"m":"inc","oa":110,"o":"zpa_6E"},{"a":49142,"t":"code","b":[230,112],"m":"inc","oa":112,"o":"zpa_70"},{"a":49144,"t":"code","b":[165,112],"m":"lda","oa":112,"o":"zpa_70"},{"a":49146,"t":"code","b":[201,64],"m":"cmp","o":"#$40"},{"a":49148,"t":"code","b":[208,237],"m":"bne","oa":49131,"o":"b_BFEB"},{"a":49150,"t":"code","b":[96],"m":"rts"},{"a":49151,"t":"gap","n":16385}]}