ff5j.asm
everything8215_ff5/notes/ff5j.asm
; ========================================[ main ]========================================

; [ reset ]

C0/0000: 78           SEI 
C0/0001: 18           CLC 
C0/0002: FB           XCE 
C0/0003: C2 10        REP #$10
C0/0005: E2 20        SEP #$20
C0/0007: 9C 0D 42     STZ $420D
C0/000A: 9C 0B 42     STZ $420B
C0/000D: 9C 0C 42     STZ $420C
C0/0010: A9 8F        LDA #$8F
C0/0012: 8D 00 21     STA $2100
C0/0015: A9 00        LDA #$00
C0/0017: 8D 00 42     STA $4200
C0/001A: A9 00        LDA #$00
C0/001C: EB           XBA 
C0/001D: A2 FF 1F     LDX #$1FFF      ; set stack pointer
C0/0020: 9A           TXS 
C0/0021: A9 00        LDA #$00        ; set data bank
C0/0023: 48           PHA 
C0/0024: AB           PLB 
C0/0025: A2 00 0B     LDX #$0B00      ; set dp
C0/0028: DA           PHX 
C0/0029: 2B           PLD 
C0/002A: A2 00 00     LDX #$0000      ; set null
C0/002D: 86 06        STX $06
C0/002F: 22 00 00 C4  JSL $C40000     ; init spc
C0/0033: A9 F1        LDA #$F1        ; cutscene $F1 (title/credits)
C0/0035: 20 C8 44     JSR $44C8       ; show cutscene
C0/0038: 20 69 4E     JSR $4E69       ; init hardware registers
C0/003B: 20 0A 49     JSR $490A       ; reset ram $0000-$1D00
C0/003E: A9 03        LDA #$03        ; menu command $03 (init menu settings)
C0/0040: 8D 34 01     STA $0134
C0/0043: 22 00 A0 C2  JSL $C2A000     ; execute menu command
C0/0047: 20 E3 44     JSR $44E3       ; init map bank
C0/004A: 20 69 4E     JSR $4E69       ; init hardware registers
C0/004D: 20 4A 4E     JSR $4E4A       ; init interrupt jump code
C0/0050: AD 39 01     LDA $0139
C0/0053: F0 28        BEQ $007D       ; branch if there are no saved games
C0/0055: 20 1D 49     JSR $491D       ; reset ram $0B00-$1D00
C0/0058: AD F9 0A     LDA $0AF9
C0/005B: 8D 60 0B     STA $0B60
C0/005E: 4A           LSR 
C0/005F: 8D 5F 0B     STA $0B5F
C0/0062: A9 01        LDA #$01
C0/0064: 85 BD        STA $BD         ; show party sprite
C0/0066: 85 BC        STA $BC         ; enable walking animation
C0/0068: 1A           INC 
C0/0069: 85 B9        STA $B9
C0/006B: AD D8 0A     LDA $0AD8       ; x position
C0/006E: 8D 88 10     STA $1088
C0/0071: AD D9 0A     LDA $0AD9       ; y position
C0/0074: 8D 89 10     STA $1089
C0/0077: 20 5D 54     JSR $545D       ; load map
C0/007A: 4C AD 00     JMP $00AD
C0/007D: 20 FA 48     JSR $48FA       ; init character data (new game)
C0/0080: 20 ED 48     JSR $48ED       ; init event flags
C0/0083: 20 DD 48     JSR $48DD       ; init npc flags
C0/0086: 20 28 45     JSR $4528       ; init character names
C0/0089: 20 0A 45     JSR $450A       ; init vehicles
C0/008C: A9 01        LDA #$01
C0/008E: 85 BD        STA $BD         ; show party sprite
C0/0090: 85 BC        STA $BC         ; enable walking animation
C0/0092: A2 10 00     LDX #$0010      ; event $10 (intro)
C0/0095: 86 CE        STX $CE
C0/0097: A9 01        LDA #$01
C0/0099: 85 57        STA $57
C0/009B: A9 81        LDA #$81
C0/009D: 8D 00 42     STA $4200
C0/00A0: 58           CLI 
C0/00A1: 20 17 A2     JSR $A217       ; execute event
C0/00A4: 64 57        STZ $57
C0/00A6: 64 58        STZ $58
C0/00A8: 64 55        STZ $55
C0/00AA: 4C AD 00     JMP $00AD

; [ map main loop ]

C0/00AD: 20 41 4E     JSR $4E41       ; wait for vblank
C0/00B0: A5 02        LDA $02
C0/00B2: 29 40        AND #$40
C0/00B4: F0 08        BEQ $00BE       ; branch if x button is not down
C0/00B6: A5 53        LDA $53
C0/00B8: F0 07        BEQ $00C1       ; 
C0/00BA: A5 5D        LDA $5D
C0/00BC: F0 03        BEQ $00C1       ; 
C0/00BE: 4C 47 01     JMP $0147
C0/00C1: AD 61 0B     LDA $0B61       ; bg1 x position
C0/00C4: 29 1F        AND #$1F
C0/00C6: D0 7F        BNE $0147       ; branch if partially scrolled
C0/00C8: AD 63 0B     LDA $0B63       ; bg1 y position
C0/00CB: 29 1F        AND #$1F
C0/00CD: D0 78        BNE $0147       ; branch if partially scrolled
C0/00CF: A9 00        LDA #$00
C0/00D1: 8D 35 01     STA $0135
C0/00D4: AD DC 0A     LDA $0ADC
C0/00D7: D0 16        BNE $00EF       ; branch if in a vehicle ???
C0/00D9: AE D6 0A     LDX $0AD6       ; map index
C0/00DC: E0 05 00     CPX #$0005
C0/00DF: 90 09        BCC $00EA       ; branch if not on a world map
C0/00E1: A9 FD        LDA #$FD
C0/00E3: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/00E6: C9 00        CMP #$00
C0/00E8: F0 05        BEQ $00EF
C0/00EA: A9 80        LDA #$80        ; enable tent/cabin/save
C0/00EC: 8D 35 01     STA $0135
C0/00EF: 64 08        STZ $08
C0/00F1: A5 53        LDA $53
C0/00F3: F0 07        BEQ $00FC
C0/00F5: AD 0F 11     LDA $110F       ; enable warp/teleport ???
C0/00F8: 29 03        AND #$03
C0/00FA: 85 08        STA $08
C0/00FC: AD 35 01     LDA $0135
C0/00FF: 05 08        ORA $08
C0/0101: 8D 35 01     STA $0135
C0/0104: A9 00        LDA #$00        ; menu command $00 (main menu)
C0/0106: 8D 34 01     STA $0134
C0/0109: 20 4C 45     JSR $454C       ; open menu
C0/010C: A9 02        LDA #$02
C0/010E: 85 55        STA $55
C0/0110: AD D8 0A     LDA $0AD8
C0/0113: 8D 88 10     STA $1088
C0/0116: AD D9 0A     LDA $0AD9
C0/0119: 8D 89 10     STA $1089
C0/011C: 20 76 54     JSR $5476       ; reload map
C0/011F: AD 39 01     LDA $0139       ; item used in menu
C0/0122: C9 F0        CMP #$F0
C0/0124: D0 05        BNE $012B       ; branch if not tent
C0/0126: A2 22 00     LDX #$0022
C0/0129: 80 10        BRA $013B
C0/012B: C9 F1        CMP #$F1
C0/012D: D0 05        BNE $0134       ; branch if not cabin
C0/012F: A2 24 00     LDX #$0024
C0/0132: 80 07        BRA $013B
C0/0134: C9 3E        CMP #$3E        ; judgment staff ???
C0/0136: D0 06        BNE $013E
C0/0138: A2 32 00     LDX #$0032
C0/013B: 20 6A 04     JSR $046A       ; execute trigger script
C0/013E: 9C AA 16     STZ $16AA
C0/0141: 20 E9 14     JSR $14E9       ; pixelate screen (poison)
C0/0144: 4C AD 00     JMP $00AD
C0/0147: 20 1A 06     JSR $061A       ; check triggers
C0/014A: 20 8B A1     JSR $A18B       ; update timer
C0/014D: A5 58        LDA $58
C0/014F: F0 05        BEQ $0156
C0/0151: 64 58        STZ $58
C0/0153: 4C AD 00     JMP $00AD
C0/0156: A5 6E        LDA $6E
C0/0158: F0 06        BEQ $0160
C0/015A: 20 5A 54     JSR $545A       ; load map
C0/015D: 4C AD 00     JMP $00AD
C0/0160: AE D6 0A     LDX $0AD6       ; map index
C0/0163: E0 05 00     CPX #$0005
C0/0166: 90 03        BCC $016B
C0/0168: 4C 62 02     JMP $0262
C0/016B: 20 3E 07     JSR $073E
C0/016E: A5 58        LDA $58
C0/0170: F0 05        BEQ $0177
C0/0172: 64 58        STZ $58
C0/0174: 4C AD 00     JMP $00AD
C0/0177: A5 61        LDA $61
C0/0179: 29 1F        AND #$1F
C0/017B: D0 7E        BNE $01FB
C0/017D: A5 63        LDA $63
C0/017F: 29 1F        AND #$1F
C0/0181: D0 78        BNE $01FB
C0/0183: AD D6 0A     LDA $0AD6       ; map index
C0/0186: C9 01        CMP #$01
C0/0188: D0 17        BNE $01A1
C0/018A: AD D9 0A     LDA $0AD9
C0/018D: C9 A1        CMP #$A1
C0/018F: D0 10        BNE $01A1
C0/0191: AD D8 0A     LDA $0AD8
C0/0194: C9 9F        CMP #$9F
C0/0196: 90 09        BCC $01A1
C0/0198: C9 A2        CMP #$A2
C0/019A: B0 05        BCS $01A1
C0/019C: A2 12 00     LDX #$0012
C0/019F: 80 4E        BRA $01EF
C0/01A1: AD D6 0A     LDA $0AD6       ; map index
C0/01A4: D0 22        BNE $01C8
C0/01A6: AD DC 0A     LDA $0ADC
C0/01A9: C9 06        CMP #$06
C0/01AB: D0 1B        BNE $01C8
C0/01AD: AD D8 0A     LDA $0AD8
C0/01B0: C9 3D        CMP #$3D
C0/01B2: 90 14        BCC $01C8
C0/01B4: C9 43        CMP #$43
C0/01B6: B0 10        BCS $01C8
C0/01B8: AD D9 0A     LDA $0AD9
C0/01BB: C9 9E        CMP #$9E
C0/01BD: 90 09        BCC $01C8
C0/01BF: C9 A5        CMP #$A5
C0/01C1: B0 05        BCS $01C8
C0/01C3: A2 20 00     LDX #$0020
C0/01C6: 80 27        BRA $01EF
C0/01C8: AD D6 0A     LDA $0AD6       ; map index
C0/01CB: C9 02        CMP #$02
C0/01CD: D0 2C        BNE $01FB
C0/01CF: AD DC 0A     LDA $0ADC
C0/01D2: C9 05        CMP #$05
C0/01D4: 90 25        BCC $01FB
C0/01D6: AD D8 0A     LDA $0AD8
C0/01D9: C9 B6        CMP #$B6
C0/01DB: 90 1E        BCC $01FB
C0/01DD: C9 BA        CMP #$BA
C0/01DF: B0 1A        BCS $01FB
C0/01E1: AD D9 0A     LDA $0AD9
C0/01E4: C9 87        CMP #$87
C0/01E6: 90 13        BCC $01FB
C0/01E8: C9 8B        CMP #$8B
C0/01EA: B0 0F        BCS $01FB
C0/01EC: A2 18 00     LDX #$0018
C0/01EF: 20 6A 04     JSR $046A       ; execute trigger script
C0/01F2: A5 58        LDA $58
C0/01F4: F0 05        BEQ $01FB
C0/01F6: 64 58        STZ $58
C0/01F8: 4C AD 00     JMP $00AD
C0/01FB: 20 11 CB     JSR $CB11
C0/01FE: A5 55        LDA $55
C0/0200: F0 1E        BEQ $0220
C0/0202: A9 FF        LDA #$FF
C0/0204: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/0207: C9 00        CMP #$00
C0/0209: D0 15        BNE $0220
C0/020B: 20 F0 CC     JSR $CCF0       ; random battle
C0/020E: AD D8 0A     LDA $0AD8
C0/0211: 8D 88 10     STA $1088
C0/0214: AD D9 0A     LDA $0AD9
C0/0217: 8D 89 10     STA $1089
C0/021A: 20 76 54     JSR $5476       ; reload map
C0/021D: 4C AD 00     JMP $00AD
C0/0220: 64 55        STZ $55
C0/0222: A5 03        LDA $03
C0/0224: 29 40        AND #$40
C0/0226: F0 1E        BEQ $0246
C0/0228: A9 FB        LDA #$FB
C0/022A: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/022D: C9 00        CMP #$00
C0/022F: F0 15        BEQ $0246
C0/0231: 20 32 66     JSR $6632       ; show mini-map
C0/0234: AD D8 0A     LDA $0AD8
C0/0237: 8D 88 10     STA $1088
C0/023A: AD D9 0A     LDA $0AD9
C0/023D: 8D 89 10     STA $1089
C0/0240: 20 76 54     JSR $5476       ; reload map
C0/0243: 4C AD 00     JMP $00AD
C0/0246: 20 8C 0F     JSR $0F8C
C0/0249: 20 1D 1A     JSR $1A1D
C0/024C: 20 95 4C     JSR $4C95       ; clear sprite data
C0/024F: 20 37 21     JSR $2137
C0/0252: 20 2B 61     JSR $612B
C0/0255: 20 C5 1E     JSR $1EC5
C0/0258: 20 64 1E     JSR $1E64
C0/025B: 20 0A 42     JSR $420A
C0/025E: 4C AD 00     JMP $00AD
C0/0261: 60           RTS 
C0/0262: 20 3D 0D     JSR $0D3D
C0/0265: A5 58        LDA $58
C0/0267: F0 05        BEQ $026E
C0/0269: 64 58        STZ $58
C0/026B: 4C AD 00     JMP $00AD
C0/026E: AD FB 10     LDA $10FB       ; tile properties byte 2
C0/0271: C9 00        CMP #$00
C0/0273: D0 0C        BNE $0281       ; branch if not a map exit
C0/0275: 20 8F 54     JSR $548F       ; load parent map
C0/0278: A2 1C 00     LDX #$001C
C0/027B: 20 6A 04     JSR $046A       ; execute trigger script
C0/027E: 4C AD 00     JMP $00AD
C0/0281: 20 69 CA     JSR $CA69       ; 
C0/0284: A5 55        LDA $55
C0/0286: F0 12        BEQ $029A
C0/0288: A9 FF        LDA #$FF
C0/028A: 20 3C CA     JSR $CA3C       ; get event flag $01FF (disable random battles)
C0/028D: C9 00        CMP #$00
C0/028F: D0 09        BNE $029A
C0/0291: 20 F0 CC     JSR $CCF0       ; random battle
C0/0294: 20 76 54     JSR $5476       ; reload map
C0/0297: 4C AD 00     JMP $00AD
C0/029A: 64 55        STZ $55
C0/029C: 20 AB 32     JSR $32AB       ; update objects
C0/029F: 20 C2 11     JSR $11C2
C0/02A2: A5 6E        LDA $6E
C0/02A4: F0 06        BEQ $02AC
C0/02A6: 20 5A 54     JSR $545A       ; load map
C0/02A9: 4C AD 00     JMP $00AD
C0/02AC: A5 58        LDA $58
C0/02AE: F0 05        BEQ $02B5
C0/02B0: 64 58        STZ $58
C0/02B2: 4C AD 00     JMP $00AD
C0/02B5: 20 E4 1A     JSR $1AE4
C0/02B8: 20 AC 3B     JSR $3BAC
C0/02BB: 20 95 4C     JSR $4C95       ; clear sprite data
C0/02BE: 20 34 48     JSR $4834
C0/02C1: 20 7C 23     JSR $237C       ; update party sprite
C0/02C4: 20 B3 39     JSR $39B3       ; update object sprites
C0/02C7: 20 42 28     JSR $2842
C0/02CA: 20 0A 42     JSR $420A
C0/02CD: 4C AD 00     JMP $00AD

C0/02D0: 60           RTS 

; [ field nmi ]

C0/02D1: 08           PHP 
C0/02D2: C2 20        REP #$20
C0/02D4: 48           PHA 
C0/02D5: DA           PHX 
C0/02D6: 5A           PHY 
C0/02D7: 8B           PHB 
C0/02D8: 0B           PHD 
C0/02D9: A9 00 00     LDA #$0000
C0/02DC: E2 20        SEP #$20
C0/02DE: A2 00 0B     LDX #$0B00
C0/02E1: DA           PHX 
C0/02E2: 2B           PLD 
C0/02E3: A9 00        LDA #$00
C0/02E5: 48           PHA 
C0/02E6: AB           PLB 
C0/02E7: AD 10 42     LDA $4210
C0/02EA: AD 10 42     LDA $4210
C0/02ED: 9C 0B 42     STZ $420B
C0/02F0: 64 40        STZ $40         ; clear irq flag
C0/02F2: A5 47        LDA $47
C0/02F4: 8D 31 21     STA $2131       ; addition/subtraction
C0/02F7: A5 49        LDA $49
C0/02F9: 8D 2D 21     STA $212D       ; subscreen designation
C0/02FC: 20 67 4D     JSR $4D67       ; copy color palettes to ppu
C0/02FF: 20 3E 4D     JSR $4D3E       ; copy sprite data to ppu
C0/0302: 20 7A 4A     JSR $4A7A
C0/0305: 20 53 46     JSR $4653       ; update screen pixelation
C0/0308: 20 FF 49     JSR $49FF       ; update fixed color
C0/030B: A5 A3        LDA $A3
C0/030D: F0 05        BEQ $0314
C0/030F: 64 A3        STZ $A3
C0/0311: 20 D8 40     JSR $40D8       ; copy data to vram
C0/0314: A5 52        LDA $52
C0/0316: F0 03        BEQ $031B
C0/0318: 4C 1F 04     JMP $041F
C0/031B: 20 C0 4B     JSR $4BC0       ; update scrolling registers
C0/031E: A5 53        LDA $53
C0/0320: D0 3E        BNE $0360
C0/0322: 20 7E 63     JSR $637E
C0/0325: 20 95 96     JSR $9695
C0/0328: 20 5F 97     JSR $975F
C0/032B: 20 4C 96     JSR $964C
C0/032E: 20 22 97     JSR $9722
C0/0331: A5 9F        LDA $9F
C0/0333: F0 13        BEQ $0348
C0/0335: 64 9F        STZ $9F
C0/0337: A5 BA        LDA $BA
C0/0339: F0 0D        BEQ $0348
C0/033B: 29 01        AND #$01
C0/033D: D0 06        BNE $0345
C0/033F: 20 BB 64     JSR $64BB
C0/0342: 4C 48 03     JMP $0348
C0/0345: 20 65 64     JSR $6465
C0/0348: A5 A1        LDA $A1
C0/034A: F0 08        BEQ $0354
C0/034C: 64 A1        STZ $A1
C0/034E: 20 1E 1D     JSR $1D1E       ; copy party sprite graphics to vram
C0/0351: 4C 08 04     JMP $0408
C0/0354: A5 A2        LDA $A2
C0/0356: F0 05        BEQ $035D
C0/0358: 64 A2        STZ $A2
C0/035A: 20 14 1E     JSR $1E14
C0/035D: 4C 08 04     JMP $0408
C0/0360: A5 A0        LDA $A0
C0/0362: F0 08        BEQ $036C
C0/0364: 64 A0        STZ $A0
C0/0366: 20 2B 5E     JSR $5E2B       ; copy tile layout to vram ???
C0/0369: 4C 08 04     JMP $0408
C0/036C: A5 A5        LDA $A5
C0/036E: F0 08        BEQ $0378
C0/0370: 64 A5        STZ $A5
C0/0372: 20 A4 8B     JSR $8BA4
C0/0375: 4C 08 04     JMP $0408
C0/0378: A5 A6        LDA $A6
C0/037A: F0 0F        BEQ $038B
C0/037C: 64 A6        STZ $A6
C0/037E: A6 06        LDX $06
C0/0380: 86 71        STX $71
C0/0382: 20 7A 6E     JSR $6E7A
C0/0385: 20 E4 8B     JSR $8BE4
C0/0388: 4C F9 03     JMP $03F9
C0/038B: A5 A7        LDA $A7
C0/038D: F0 03        BEQ $0392
C0/038F: 20 23 8E     JSR $8E23
C0/0392: 20 78 8F     JSR $8F78       ; draw yes/no indicator
C0/0395: A5 9F        LDA $9F
C0/0397: F0 54        BEQ $03ED
C0/0399: 64 9F        STZ $9F
C0/039B: A5 70        LDA $70
C0/039D: 29 01        AND #$01
C0/039F: D0 26        BNE $03C7
C0/03A1: A6 06        LDX $06
C0/03A3: 86 71        STX $71
C0/03A5: 20 F5 6D     JSR $6DF5       ; horizontal scrolling (bg1)
C0/03A8: AD 21 11     LDA $1121
C0/03AB: 29 40        AND #$40
C0/03AD: D0 08        BNE $03B7
C0/03AF: A2 00 10     LDX #$1000
C0/03B2: 86 71        STX $71
C0/03B4: 20 F5 6D     JSR $6DF5       ; horizontal scrolling (bg2)
C0/03B7: AD 21 11     LDA $1121
C0/03BA: 30 08        BMI $03C4
C0/03BC: A2 00 20     LDX #$2000
C0/03BF: 86 71        STX $71
C0/03C1: 20 F5 6D     JSR $6DF5       ; horizontal scrolling (bg3)
C0/03C4: 4C 08 04     JMP $0408
C0/03C7: A6 06        LDX $06
C0/03C9: 86 71        STX $71
C0/03CB: 20 7A 6E     JSR $6E7A       ; vertical scrolling (bg1)
C0/03CE: AD 21 11     LDA $1121
C0/03D1: 29 40        AND #$40
C0/03D3: D0 08        BNE $03DD
C0/03D5: A2 00 10     LDX #$1000
C0/03D8: 86 71        STX $71
C0/03DA: 20 7A 6E     JSR $6E7A       ; vertical scrolling (bg2)
C0/03DD: AD 21 11     LDA $1121
C0/03E0: 30 08        BMI $03EA
C0/03E2: A2 00 20     LDX #$2000
C0/03E5: 86 71        STX $71
C0/03E7: 20 7A 6E     JSR $6E7A       ; vertical scrolling (bg3)
C0/03EA: 4C 08 04     JMP $0408
C0/03ED: A5 A1        LDA $A1
C0/03EF: F0 08        BEQ $03F9
C0/03F1: 64 A1        STZ $A1
C0/03F3: 20 1E 1D     JSR $1D1E       ; copy party sprite graphics to vram
C0/03F6: 4C 08 04     JMP $0408
C0/03F9: A5 A2        LDA $A2
C0/03FB: F0 08        BEQ $0405
C0/03FD: 64 A2        STZ $A2
C0/03FF: 20 14 1E     JSR $1E14
C0/0402: 4C 08 04     JMP $0408
C0/0405: 20 6D 99     JSR $996D       ; copy map animation graphics to vram
C0/0408: 20 8A 5E     JSR $5E8A
C0/040B: 20 3E 5F     JSR $5F3E
C0/040E: A5 5E        LDA $5E         ; hdma enable
C0/0410: 8D 0C 42     STA $420C
C0/0413: 20 00 9A     JSR $9A00
C0/0416: 20 99 97     JSR $9799       ; update palette animation
C0/0419: 20 31 49     JSR $4931
C0/041C: 20 AA 47     JSR $47AA
C0/041F: 20 90 4C     JSR $4C90
C0/0422: 20 8E 4D     JSR $4D8E
C0/0425: EE 4A 09     INC $094A
C0/0428: D0 0D        BNE $0437
C0/042A: EE 4B 09     INC $094B
C0/042D: D0 08        BNE $0437
C0/042F: EE 4C 09     INC $094C
C0/0432: D0 03        BNE $0437
C0/0434: EE 4D 09     INC $094D
C0/0437: E6 3F        INC $3F
C0/0439: E6 3E        INC $3E
C0/043B: E6 51        INC $51         ; set vblank flag
C0/043D: C2 20        REP #$20
C0/043F: 2B           PLD 
C0/0440: AB           PLB 
C0/0441: 7A           PLY 
C0/0442: FA           PLX 
C0/0443: 68           PLA 
C0/0444: 28           PLP 
C0/0445: 40           RTI 

; [ field irq ]

C0/0446: 08           PHP 
C0/0447: C2 20        REP #$20
C0/0449: 48           PHA 
C0/044A: DA           PHX 
C0/044B: 5A           PHY 
C0/044C: 8B           PHB 
C0/044D: 0B           PHD 
C0/044E: A9 00 00     LDA #$0000
C0/0451: E2 20        SEP #$20
C0/0453: A2 00 0B     LDX #$0B00
C0/0456: DA           PHX 
C0/0457: 2B           PLD 
C0/0458: A9 00        LDA #$00
C0/045A: 48           PHA 
C0/045B: AB           PLB 
C0/045C: AD 11 42     LDA $4211       ; clear irq flag
C0/045F: E6 40        INC $40         ; set irq flag
C0/0461: C2 20        REP #$20
C0/0463: 2B           PLD 
C0/0464: AB           PLB 
C0/0465: 7A           PLY 
C0/0466: FA           PLX 
C0/0467: 68           PLA 
C0/0468: 28           PLP 
C0/0469: 40           RTI 

; [ execute trigger script ]

C0/046A: C2 20        REP #$20
C0/046C: BF 80 E0 D8  LDA $D8E080,X   ; pointer to event condition
C0/0470: 85 23        STA $23
C0/0472: BF 82 E0 D8  LDA $D8E082,X
C0/0476: 85 26        STA $26
C0/0478: A5 06        LDA $06
C0/047A: E2 20        SEP #$20
C0/047C: A6 23        LDX $23
C0/047E: BF 80 E0 D8  LDA $D8E080,X

; $FF: execute event
C0/0482: C9 FF        CMP #$FF
C0/0484: D0 03        BNE $0489
C0/0486: 4C FC 05     JMP $05FC

; $FE: if event flag $00xx is set
C0/0489: C9 FE        CMP #$FE
C0/048B: D0 0E        BNE $049B
C0/048D: BF 81 E0 D8  LDA $D8E081,X
C0/0491: 20 2F CA     JSR $CA2F       ; get event flag $00xx
C0/0494: C9 00        CMP #$00
C0/0496: D0 39        BNE $04D1
C0/0498: 4C E5 05     JMP $05E5

; $FD: if event flag $00xx is clear
C0/049B: C9 FD        CMP #$FD
C0/049D: D0 0E        BNE $04AD
C0/049F: BF 81 E0 D8  LDA $D8E081,X
C0/04A3: 20 2F CA     JSR $CA2F       ; get event flag $00xx
C0/04A6: C9 00        CMP #$00
C0/04A8: F0 27        BEQ $04D1
C0/04AA: 4C E5 05     JMP $05E5

; $FC: if event flag $01xx is set
C0/04AD: C9 FC        CMP #$FC
C0/04AF: D0 0E        BNE $04BF
C0/04B1: BF 81 E0 D8  LDA $D8E081,X
C0/04B5: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/04B8: C9 00        CMP #$00
C0/04BA: D0 15        BNE $04D1
C0/04BC: 4C E5 05     JMP $05E5

; $FB: if event flag $01xx is clear
C0/04BF: C9 FB        CMP #$FB
C0/04C1: D0 17        BNE $04DA
C0/04C3: BF 81 E0 D8  LDA $D8E081,X
C0/04C7: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/04CA: C9 00        CMP #$00
C0/04CC: F0 03        BEQ $04D1
C0/04CE: 4C E5 05     JMP $05E5
C0/04D1: A6 23        LDX $23
C0/04D3: E8           INX 
C0/04D4: E8           INX 
C0/04D5: 86 23        STX $23
C0/04D7: 4C 7C 04     JMP $047C

; $FA: compare ram (1-byte)
C0/04DA: C9 FA        CMP #$FA
C0/04DC: D0 3E        BNE $051C
C0/04DE: C2 20        REP #$20
C0/04E0: BF 81 E0 D8  LDA $D8E081,X
C0/04E4: 29 FF 3F     AND #$3FFF
C0/04E7: A8           TAY 
C0/04E8: A5 06        LDA $06
C0/04EA: E2 20        SEP #$20
C0/04EC: BF 82 E0 D8  LDA $D8E082,X
C0/04F0: 29 C0        AND #$C0
C0/04F2: D0 0C        BNE $0500
C0/04F4: B9 00 05     LDA $0500,Y
C0/04F7: DF 83 E0 D8  CMP $D8E083,X
C0/04FB: F0 6B        BEQ $0568
C0/04FD: 4C E5 05     JMP $05E5
C0/0500: C9 40        CMP #$40
C0/0502: D0 0C        BNE $0510
C0/0504: B9 00 05     LDA $0500,Y
C0/0507: DF 83 E0 D8  CMP $D8E083,X
C0/050B: B0 5B        BCS $0568
C0/050D: 4C E5 05     JMP $05E5
C0/0510: B9 00 05     LDA $0500,Y
C0/0513: DF 83 E0 D8  CMP $D8E083,X
C0/0517: 90 4F        BCC $0568
C0/0519: 4C E5 05     JMP $05E5

; $F9: compare ram (2-byte)
C0/051C: C9 F9        CMP #$F9
C0/051E: D0 53        BNE $0573
C0/0520: C2 20        REP #$20
C0/0522: BF 81 E0 D8  LDA $D8E081,X
C0/0526: 29 FF 3F     AND #$3FFF
C0/0529: A8           TAY 
C0/052A: BF 81 E0 D8  LDA $D8E081,X
C0/052E: 29 00 C0     AND #$C000
C0/0531: D0 10        BNE $0543
C0/0533: B9 00 05     LDA $0500,Y
C0/0536: DF 83 E0 D8  CMP $D8E083,X
C0/053A: F0 2C        BEQ $0568
C0/053C: A5 06        LDA $06
C0/053E: E2 20        SEP #$20
C0/0540: 4C E5 05     JMP $05E5
C0/0543: C9 00        CMP #$00
C0/0545: 40           RTI 
C0/0546: D0 10        BNE $0558
C0/0548: B9 00 05     LDA $0500,Y
C0/054B: DF 83 E0 D8  CMP $D8E083,X
C0/054F: B0 17        BCS $0568
C0/0551: A5 06        LDA $06
C0/0553: E2 20        SEP #$20
C0/0555: 4C E5 05     JMP $05E5
C0/0558: B9 00 05     LDA $0500,Y
C0/055B: DF 83 E0 D8  CMP $D8E083,X
C0/055F: 90 07        BCC $0568
C0/0561: A5 06        LDA $06
C0/0563: E2 20        SEP #$20
C0/0565: 4C E5 05     JMP $05E5
C0/0568: A6 23        LDX $23
C0/056A: E8           INX 
C0/056B: E8           INX 
C0/056C: E8           INX 
C0/056D: E8           INX 
C0/056E: 86 23        STX $23
C0/0570: 4C 7C 04     JMP $047C

; $F8: boolean compare ram (1-byte)
C0/0573: C9 F8        CMP #$F8
C0/0575: D0 2A        BNE $05A1
C0/0577: C2 20        REP #$20
C0/0579: BF 81 E0 D8  LDA $D8E081,X
C0/057D: 29 FF 3F     AND #$3FFF
C0/0580: A8           TAY 
C0/0581: A5 06        LDA $06
C0/0583: E2 20        SEP #$20
C0/0585: B9 00 05     LDA $0500,Y
C0/0588: 3F 83 E0 D8  AND $D8E083,X
C0/058C: D0 DA        BNE $0568
C0/058E: 4C E5 05     JMP $05E5
C0/0591: A5 06        LDA $06
C0/0593: E2 20        SEP #$20
C0/0595: A6 23        LDX $23
C0/0597: E8           INX 
C0/0598: E8           INX 
C0/0599: E8           INX 
C0/059A: E8           INX 
C0/059B: E8           INX 
C0/059C: 86 23        STX $23
C0/059E: 4C 7C 04     JMP $047C

; $F7: if facing direction
C0/05A1: C9 F7        CMP #$F7
C0/05A3: D0 0C        BNE $05B1
C0/05A5: BF 81 E0 D8  LDA $D8E081,X
C0/05A9: CD DB 0A     CMP $0ADB       ; facing direction
C0/05AC: D0 37        BNE $05E5
C0/05AE: 4C D1 04     JMP $04D1

; $F6: if button pressed
C0/05B1: C9 F6        CMP #$F6
C0/05B3: D0 16        BNE $05CB
C0/05B5: A5 02        LDA $02
C0/05B7: 29 80        AND #$80
C0/05B9: F0 2A        BEQ $05E5
C0/05BB: AD B8 10     LDA $10B8
C0/05BE: D0 25        BNE $05E5
C0/05C0: EE B8 10     INC $10B8
C0/05C3: A6 23        LDX $23
C0/05C5: E8           INX 
C0/05C6: 86 23        STX $23
C0/05C8: 4C 7C 04     JMP $047C

; $F5: boolean compare ram (2-byte)
C0/05CB: C2 20        REP #$20
C0/05CD: BF 81 E0 D8  LDA $D8E081,X
C0/05D1: 29 FF 3F     AND #$3FFF
C0/05D4: A8           TAY 
C0/05D5: A5 06        LDA $06
C0/05D7: E2 20        SEP #$20
C0/05D9: B9 00 05     LDA $0500,Y
C0/05DC: 3F 83 E0 D8  AND $D8E083,X
C0/05E0: F0 86        BEQ $0568
C0/05E2: 4C E5 05     JMP $05E5
C0/05E5: A6 23        LDX $23
C0/05E7: E8           INX 
C0/05E8: BF 80 E0 D8  LDA $D8E080,X
C0/05EC: C9 FF        CMP #$FF
C0/05EE: D0 F7        BNE $05E7
C0/05F0: E8           INX 
C0/05F1: E8           INX 
C0/05F2: E8           INX 
C0/05F3: 86 23        STX $23
C0/05F5: E4 26        CPX $26
C0/05F7: F0 1E        BEQ $0617
C0/05F9: 4C 7C 04     JMP $047C
C0/05FC: A9 01        LDA #$01
C0/05FE: 85 57        STA $57
C0/0600: 64 BA        STZ $BA
C0/0602: C2 20        REP #$20
C0/0604: A6 23        LDX $23
C0/0606: BF 81 E0 D8  LDA $D8E081,X   ; event index
C0/060A: 85 CE        STA $CE
C0/060C: A5 06        LDA $06
C0/060E: E2 20        SEP #$20
C0/0610: A6 CE        LDX $CE
C0/0612: F0 03        BEQ $0617
C0/0614: 20 17 A2     JSR $A217       ; execute event
C0/0617: 64 57        STZ $57
C0/0619: 60           RTS 

; [ check triggers ]

C0/061A: A5 53        LDA $53
C0/061C: D0 15        BNE $0633
C0/061E: AD DC 0A     LDA $0ADC
C0/0621: F0 10        BEQ $0633
C0/0623: C9 01        CMP #$01
C0/0625: F0 0C        BEQ $0633
C0/0627: C9 05        CMP #$05
C0/0629: F0 08        BEQ $0633
C0/062B: AE D6 0A     LDX $0AD6       ; map index
C0/062E: E0 03 00     CPX #$0003
C0/0631: 90 0C        BCC $063F
C0/0633: A5 61        LDA $61
C0/0635: 29 1F        AND #$1F
C0/0637: D0 06        BNE $063F
C0/0639: A5 63        LDA $63
C0/063B: 29 1F        AND #$1F
C0/063D: F0 01        BEQ $0640
C0/063F: 60           RTS 
C0/0640: 64 5A        STZ $5A
C0/0642: C2 20        REP #$20
C0/0644: AD D6 0A     LDA $0AD6       ; map index
C0/0647: 0A           ASL 
C0/0648: AA           TAX 
C0/0649: BF 02 24 CE  LDA $CE2402,X   ; event triggers
C0/064D: 85 23        STA $23
C0/064F: BF 00 24 CE  LDA $CE2400,X
C0/0653: AA           TAX 
C0/0654: E4 23        CPX $23
C0/0656: F0 29        BEQ $0681
C0/0658: AD D8 0A     LDA $0AD8
C0/065B: DF 00 24 CE  CMP $CE2400,X
C0/065F: F0 09        BEQ $066A
C0/0661: 8A           TXA 
C0/0662: 18           CLC 
C0/0663: 69 04 00     ADC #$0004
C0/0666: AA           TAX 
C0/0667: 4C 54 06     JMP $0654
C0/066A: A5 06        LDA $06
C0/066C: E2 20        SEP #$20
C0/066E: A9 01        LDA #$01
C0/0670: 85 5A        STA $5A
C0/0672: C2 20        REP #$20
C0/0674: BF 02 24 CE  LDA $CE2402,X
C0/0678: 0A           ASL 
C0/0679: AA           TAX 
C0/067A: A5 06        LDA $06
C0/067C: E2 20        SEP #$20
C0/067E: 20 6A 04     JSR $046A       ; execute trigger script
C0/0681: C2 20        REP #$20
C0/0683: AD D6 0A     LDA $0AD6       ; map index
C0/0686: C9 05 00     CMP #$0005
C0/0689: 90 03        BCC $068E
C0/068B: AD D4 0A     LDA $0AD4
C0/068E: 0A           ASL 
C0/068F: AA           TAX 
C0/0690: BF C2 36 CE  LDA $CE36C2,X   ; entrance triggers
C0/0694: 85 23        STA $23
C0/0696: BF C0 36 CE  LDA $CE36C0,X
C0/069A: AA           TAX 
C0/069B: E4 23        CPX $23
C0/069D: D0 03        BNE $06A2
C0/069F: 4C 39 07     JMP $0739
C0/06A2: AD D8 0A     LDA $0AD8
C0/06A5: DF C0 36 CE  CMP $CE36C0,X
C0/06A9: F0 09        BEQ $06B4
C0/06AB: 8A           TXA 
C0/06AC: 18           CLC 
C0/06AD: 69 06 00     ADC #$0006
C0/06B0: AA           TAX 
C0/06B1: 4C 9B 06     JMP $069B
C0/06B4: A5 59        LDA $59
C0/06B6: 29 FF 00     AND #$00FF
C0/06B9: F0 03        BEQ $06BE
C0/06BB: 4C 39 07     JMP $0739
C0/06BE: 9C A0 16     STZ $16A0       ; disable map title
C0/06C1: AD D6 0A     LDA $0AD6       ; map index
C0/06C4: C9 05 00     CMP #$0005
C0/06C7: B0 09        BCS $06D2
C0/06C9: 8D F5 0A     STA $0AF5       ; set parent map
C0/06CC: AD D8 0A     LDA $0AD8
C0/06CF: 8D F7 0A     STA $0AF7       ; set parent map xy position
C0/06D2: BF C2 36 CE  LDA $CE36C2,X
C0/06D6: 29 FF 03     AND #$03FF
C0/06D9: 8D D4 0A     STA $0AD4
C0/06DC: 8D D6 0A     STA $0AD6       ; map index
C0/06DF: C9 05 00     CMP #$0005
C0/06E2: B0 14        BCS $06F8
C0/06E4: A5 06        LDA $06
C0/06E6: E2 20        SEP #$20
C0/06E8: BF C4 36 CE  LDA $CE36C4,X
C0/06EC: 8D 88 10     STA $1088
C0/06EF: BF C5 36 CE  LDA $CE36C5,X
C0/06F3: 8D 89 10     STA $1089
C0/06F6: 80 3F        BRA $0737
C0/06F8: A5 06        LDA $06
C0/06FA: E2 20        SEP #$20
C0/06FC: BF C3 36 CE  LDA $CE36C3,X
C0/0700: 29 08        AND #$08
C0/0702: F0 03        BEQ $0707
C0/0704: EE A0 16     INC $16A0       ; enable map title
C0/0707: BF C3 36 CE  LDA $CE36C3,X
C0/070B: 4A           LSR 
C0/070C: 4A           LSR 
C0/070D: 4A           LSR 
C0/070E: 4A           LSR 
C0/070F: 8D 9E 16     STA $169E
C0/0712: BF C4 36 CE  LDA $CE36C4,X
C0/0716: 29 C0        AND #$C0
C0/0718: 4A           LSR 
C0/0719: 4A           LSR 
C0/071A: 4A           LSR 
C0/071B: 4A           LSR 
C0/071C: 4A           LSR 
C0/071D: 4A           LSR 
C0/071E: 85 B9        STA $B9
C0/0720: 1A           INC 
C0/0721: 85 BA        STA $BA
C0/0723: 85 BF        STA $BF
C0/0725: BF C4 36 CE  LDA $CE36C4,X
C0/0729: 29 3F        AND #$3F
C0/072B: 8D 88 10     STA $1088
C0/072E: BF C5 36 CE  LDA $CE36C5,X
C0/0732: 29 3F        AND #$3F
C0/0734: 8D 89 10     STA $1089
C0/0737: E6 6E        INC $6E
C0/0739: A5 06        LDA $06
C0/073B: E2 20        SEP #$20
C0/073D: 60           RTS 
C0/073E: A5 61        LDA $61
C0/0740: 29 1F        AND #$1F
C0/0742: D0 06        BNE $074A
C0/0744: A5 63        LDA $63
C0/0746: 29 1F        AND #$1F
C0/0748: F0 01        BEQ $074B
C0/074A: 60           RTS 
C0/074B: 20 33 17     JSR $1733       ; update local tile properties (world map)
C0/074E: AD DC 0A     LDA $0ADC
C0/0751: 3A           DEC 
C0/0752: 0A           ASL 
C0/0753: 0A           ASL 
C0/0754: 8D 9C 16     STA $169C
C0/0757: AD DC 0A     LDA $0ADC
C0/075A: F0 03        BEQ $075F
C0/075C: 4C EE 07     JMP $07EE
C0/075F: A4 06        LDY $06
C0/0761: 84 23        STY $23
C0/0763: A4 23        LDY $23
C0/0765: B9 DE 0A     LDA $0ADE,Y
C0/0768: 30 75        BMI $07DF
C0/076A: B9 DD 0A     LDA $0ADD,Y
C0/076D: 29 E0        AND #$E0
C0/076F: 4A           LSR 
C0/0770: 4A           LSR 
C0/0771: 4A           LSR 
C0/0772: 4A           LSR 
C0/0773: 4A           LSR 
C0/0774: CD D6 0A     CMP $0AD6       ; map index
C0/0777: D0 66        BNE $07DF
C0/0779: B9 DF 0A     LDA $0ADF,Y
C0/077C: CD D8 0A     CMP $0AD8
C0/077F: D0 5E        BNE $07DF
C0/0781: B9 E0 0A     LDA $0AE0,Y
C0/0784: CD D9 0A     CMP $0AD9
C0/0787: D0 56        BNE $07DF
C0/0789: B9 DD 0A     LDA $0ADD,Y
C0/078C: 29 1C        AND #$1C
C0/078E: C9 10        CMP #$10
C0/0790: F0 12        BEQ $07A4
C0/0792: C9 14        CMP #$14
C0/0794: F0 0E        BEQ $07A4
C0/0796: A5 02        LDA $02
C0/0798: 29 80        AND #$80
C0/079A: F0 51        BEQ $07ED
C0/079C: AD B8 10     LDA $10B8
C0/079F: D0 4C        BNE $07ED
C0/07A1: EE B8 10     INC $10B8
C0/07A4: 8C 9C 16     STY $169C
C0/07A7: 98           TYA 
C0/07A8: 4A           LSR 
C0/07A9: 4A           LSR 
C0/07AA: 1A           INC 
C0/07AB: 8D DC 0A     STA $0ADC
C0/07AE: A9 80        LDA #$80
C0/07B0: 99 DE 0A     STA $0ADE,Y
C0/07B3: B9 DD 0A     LDA $0ADD,Y
C0/07B6: 29 1C        AND #$1C
C0/07B8: 4A           LSR 
C0/07B9: 4A           LSR 
C0/07BA: AA           TAX 
C0/07BB: BF B3 08 C0  LDA $C008B3,X
C0/07BF: 85 C0        STA $C0
C0/07C1: A9 03        LDA #$03
C0/07C3: 8D DB 0A     STA $0ADB
C0/07C6: 8A           TXA 
C0/07C7: 0A           ASL 
C0/07C8: AA           TAX 
C0/07C9: BF 97 08 C0  LDA $C00897,X
C0/07CD: 85 26        STA $26
C0/07CF: BF 98 08 C0  LDA $C00898,X
C0/07D3: 85 27        STA $27
C0/07D5: 20 83 45     JSR $4583
C0/07D8: A9 01        LDA #$01
C0/07DA: 85 58        STA $58
C0/07DC: 6C 26 0B     JMP ($0B26)
C0/07DF: A5 23        LDA $23
C0/07E1: 18           CLC 
C0/07E2: 69 04        ADC #$04
C0/07E4: 85 23        STA $23
C0/07E6: C9 18        CMP #$18
C0/07E8: F0 03        BEQ $07ED
C0/07EA: 4C 63 07     JMP $0763
C0/07ED: 60           RTS 
C0/07EE: 3A           DEC 
C0/07EF: 0A           ASL 
C0/07F0: 0A           ASL 
C0/07F1: A8           TAY 
C0/07F2: B9 DD 0A     LDA $0ADD,Y     ; vehicle index
C0/07F5: 29 1C        AND #$1C
C0/07F7: 4A           LSR 
C0/07F8: 4A           LSR 
C0/07F9: AA           TAX 
C0/07FA: AD FB 10     LDA $10FB       ; world tile properties byte 2
C0/07FD: 3F 90 08 C0  AND $C00890,X
C0/0801: D0 EA        BNE $07ED       ; branch if vehicle can't land
C0/0803: BB           TYX 
C0/0804: A5 02        LDA $02
C0/0806: 29 80        AND #$80
C0/0808: F0 E3        BEQ $07ED
C0/080A: AD B8 10     LDA $10B8
C0/080D: D0 DE        BNE $07ED
C0/080F: EE B8 10     INC $10B8
C0/0812: A4 06        LDY $06
C0/0814: 98           TYA 
C0/0815: 4A           LSR 
C0/0816: 4A           LSR 
C0/0817: 1A           INC 
C0/0818: CD DC 0A     CMP $0ADC
C0/081B: F0 15        BEQ $0832
C0/081D: B9 DE 0A     LDA $0ADE,Y
C0/0820: 30 10        BMI $0832
C0/0822: B9 DF 0A     LDA $0ADF,Y
C0/0825: CD D8 0A     CMP $0AD8
C0/0828: D0 08        BNE $0832
C0/082A: B9 E0 0A     LDA $0AE0,Y
C0/082D: CD D9 0A     CMP $0AD9
C0/0830: F0 5D        BEQ $088F
C0/0832: C8           INY 
C0/0833: C8           INY 
C0/0834: C8           INY 
C0/0835: C8           INY 
C0/0836: C0 18 00     CPY #$0018
C0/0839: D0 D9        BNE $0814
C0/083B: 8A           TXA 
C0/083C: 4A           LSR 
C0/083D: 1A           INC 
C0/083E: 1A           INC 
C0/083F: AA           TAX 
C0/0840: BF A5 08 C0  LDA $C008A5,X
C0/0844: 85 26        STA $26
C0/0846: BF A6 08 C0  LDA $C008A6,X
C0/084A: 85 27        STA $27
C0/084C: A9 01        LDA #$01
C0/084E: 85 58        STA $58
C0/0850: 6C 26 0B     JMP ($0B26)
C0/0853: AC 9C 16     LDY $169C
C0/0856: AD D8 0A     LDA $0AD8
C0/0859: 99 DF 0A     STA $0ADF,Y
C0/085C: AD D9 0A     LDA $0AD9
C0/085F: 99 E0 0A     STA $0AE0,Y
C0/0862: B9 DE 0A     LDA $0ADE,Y
C0/0865: 29 7F        AND #$7F
C0/0867: 99 DE 0A     STA $0ADE,Y
C0/086A: AD D6 0A     LDA $0AD6       ; map index
C0/086D: 0A           ASL 
C0/086E: 0A           ASL 
C0/086F: 0A           ASL 
C0/0870: 0A           ASL 
C0/0871: 0A           ASL 
C0/0872: 85 08        STA $08
C0/0874: B9 DD 0A     LDA $0ADD,Y
C0/0877: 29 1F        AND #$1F
C0/0879: 05 08        ORA $08
C0/087B: 99 DD 0A     STA $0ADD,Y
C0/087E: A9 02        LDA #$02
C0/0880: 85 C0        STA $C0
C0/0882: 20 83 45     JSR $4583
C0/0885: A5 57        LDA $57
C0/0887: D0 06        BNE $088F
C0/0889: A2 40 02     LDX #$0240
C0/088C: 20 6A 04     JSR $046A       ; execute trigger script
C0/088F: 60           RTS 

; bit mask to determine if vehicle can't land
C0/0890: 00 10 20 40 00 00 80

; jump table for boarding a vehicle
C0/0897: 0000 08BA 08C1 08EF 098D 0A4D 0A57

; jump table for landing a vehicle
C0/08A5: 0000 08BB 091D 0955 098E 0A54 0AA3

C0/08B3: 02 04 04 04 04 04 10

; get on chocobo
C0/08BA: 60           RTS 

; get off chocobo
C0/08BB: 9C DC 0A     STZ $0ADC
C0/08BE: 4C 53 08     JMP $0853

; get on black chocobo
C0/08C1: A9 00        LDA #$00
C0/08C3: 85 3D        STA $3D
C0/08C5: 20 41 4E     JSR $4E41       ; wait for vblank
C0/08C8: 20 95 4C     JSR $4C95       ; clear sprite data
C0/08CB: AC 9C 16     LDY $169C
C0/08CE: A5 3D        LDA $3D
C0/08D0: AA           TAX 
C0/08D1: BF 4F 0C C0  LDA $C00C4F,X
C0/08D5: 09 80        ORA #$80
C0/08D7: 99 DE 0A     STA $0ADE,Y     ; vehicle height
C0/08DA: 20 37 21     JSR $2137
C0/08DD: 20 2B 61     JSR $612B
C0/08E0: 20 C5 1E     JSR $1EC5
C0/08E3: 20 64 1E     JSR $1E64
C0/08E6: E6 3D        INC $3D
C0/08E8: A5 3D        LDA $3D
C0/08EA: C9 40        CMP #$40
C0/08EC: D0 D7        BNE $08C5
C0/08EE: 60           RTS 

; get on hiryuu
C0/08EF: A9 00        LDA #$00
C0/08F1: 85 3D        STA $3D
C0/08F3: 20 41 4E     JSR $4E41       ; wait for vblank
C0/08F6: 20 95 4C     JSR $4C95       ; clear sprite data
C0/08F9: AC 9C 16     LDY $169C
C0/08FC: A5 3D        LDA $3D
C0/08FE: AA           TAX 
C0/08FF: BF 4F 0C C0  LDA $C00C4F,X
C0/0903: 09 80        ORA #$80
C0/0905: 99 DE 0A     STA $0ADE,Y
C0/0908: 20 37 21     JSR $2137
C0/090B: 20 2B 61     JSR $612B
C0/090E: 20 C5 1E     JSR $1EC5
C0/0911: 20 64 1E     JSR $1E64
C0/0914: E6 3D        INC $3D
C0/0916: A5 3D        LDA $3D
C0/0918: C9 40        CMP #$40
C0/091A: D0 D7        BNE $08F3
C0/091C: 60           RTS 

; land black chocobo
C0/091D: A9 03        LDA #$03
C0/091F: 8D DB 0A     STA $0ADB
C0/0922: A9 3F        LDA #$3F
C0/0924: 85 3D        STA $3D
C0/0926: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0929: 20 95 4C     JSR $4C95       ; clear sprite data
C0/092C: AC 9C 16     LDY $169C
C0/092F: A5 3D        LDA $3D
C0/0931: AA           TAX 
C0/0932: BF 4F 0C C0  LDA $C00C4F,X
C0/0936: 09 80        ORA #$80
C0/0938: 99 DE 0A     STA $0ADE,Y
C0/093B: 20 37 21     JSR $2137
C0/093E: 20 2B 61     JSR $612B
C0/0941: 20 C5 1E     JSR $1EC5
C0/0944: 20 64 1E     JSR $1E64
C0/0947: C6 3D        DEC $3D
C0/0949: A5 3D        LDA $3D
C0/094B: C9 FF        CMP #$FF
C0/094D: D0 D7        BNE $0926
C0/094F: 9C DC 0A     STZ $0ADC
C0/0952: 4C 53 08     JMP $0853

; land hiryuu
C0/0955: A9 03        LDA #$03
C0/0957: 8D DB 0A     STA $0ADB
C0/095A: A9 3F        LDA #$3F
C0/095C: 85 3D        STA $3D
C0/095E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0961: 20 95 4C     JSR $4C95       ; clear sprite data
C0/0964: AC 9C 16     LDY $169C
C0/0967: A5 3D        LDA $3D
C0/0969: AA           TAX 
C0/096A: BF 4F 0C C0  LDA $C00C4F,X
C0/096E: 09 80        ORA #$80
C0/0970: 99 DE 0A     STA $0ADE,Y
C0/0973: 20 37 21     JSR $2137
C0/0976: 20 2B 61     JSR $612B
C0/0979: 20 C5 1E     JSR $1EC5
C0/097C: 20 64 1E     JSR $1E64
C0/097F: C6 3D        DEC $3D
C0/0981: A5 3D        LDA $3D
C0/0983: C9 FF        CMP #$FF
C0/0985: D0 D7        BNE $095E
C0/0987: 9C DC 0A     STZ $0ADC
C0/098A: 4C 53 08     JMP $0853

; get on submarine
C0/098D: 60           RTS 

; get off submarine
C0/098E: A9 03        LDA #$03
C0/0990: 8D DB 0A     STA $0ADB
C0/0993: AE D6 0A     LDX $0AD6       ; map index
C0/0996: E0 03 00     CPX #$0003
C0/0999: 90 1E        BCC $09B9       ; branch if not underwater
C0/099B: AD FA 10     LDA $10FA       ; world tile properties byte 1
C0/099E: 10 18        BPL $09B8       ; return if submarine can't surface
C0/09A0: 20 C6 09     JSR $09C6
C0/09A3: A2 2A 00     LDX #$002A
C0/09A6: 20 6A 04     JSR $046A       ; execute trigger script
C0/09A9: 20 68 4A     JSR $4A68
C0/09AC: A9 01        LDA #$01
C0/09AE: 85 BD        STA $BD
C0/09B0: A9 28        LDA #$28
C0/09B2: 8D 9B 16     STA $169B
C0/09B5: 20 FB 22     JSR $22FB
C0/09B8: 60           RTS 
C0/09B9: 20 F7 09     JSR $09F7
C0/09BC: A2 28 00     LDX #$0028
C0/09BF: 20 6A 04     JSR $046A       ; execute trigger script
C0/09C2: 20 11 0A     JSR $0A11
C0/09C5: 60           RTS 

; [  ]

C0/09C6: A9 80        LDA #$80
C0/09C8: 85 3D        STA $3D
C0/09CA: 64 0D        STZ $0D
C0/09CC: 20 41 4E     JSR $4E41       ; wait for vblank
C0/09CF: A5 0D        LDA $0D
C0/09D1: 18           CLC 
C0/09D2: 65 3D        ADC $3D
C0/09D4: 85 0D        STA $0D
C0/09D6: 90 0C        BCC $09E4
C0/09D8: CE 89 02     DEC $0289
C0/09DB: CE 8D 02     DEC $028D
C0/09DE: CE 91 02     DEC $0291
C0/09E1: CE 95 02     DEC $0295
C0/09E4: A5 3D        LDA $3D
C0/09E6: C9 C0        CMP #$C0
C0/09E8: D0 08        BNE $09F2
C0/09EA: A9 84        LDA #$84
C0/09EC: 85 43        STA $43
C0/09EE: A9 F0        LDA #$F0
C0/09F0: 85 45        STA $45
C0/09F2: E6 3D        INC $3D
C0/09F4: D0 D6        BNE $09CC
C0/09F6: 60           RTS 
C0/09F7: A9 01        LDA #$01
C0/09F9: 85 5B        STA $5B
C0/09FB: 20 98 47     JSR $4798
C0/09FE: A9 88        LDA #$88
C0/0A00: 85 43        STA $43
C0/0A02: A9 F0        LDA #$F0
C0/0A04: 85 45        STA $45
C0/0A06: A9 20        LDA #$20
C0/0A08: 8D 9B 16     STA $169B
C0/0A0B: 20 FB 22     JSR $22FB
C0/0A0E: 64 5B        STZ $5B
C0/0A10: 60           RTS 
C0/0A11: A9 08        LDA #$08
C0/0A13: 85 43        STA $43
C0/0A15: 64 45        STZ $45
C0/0A17: 20 37 21     JSR $2137
C0/0A1A: 9C 89 02     STZ $0289
C0/0A1D: 9C 8D 02     STZ $028D
C0/0A20: A9 08        LDA #$08
C0/0A22: 8D 91 02     STA $0291
C0/0A25: 8D 95 02     STA $0295
C0/0A28: A9 FD        LDA #$FD
C0/0A2A: 85 3D        STA $3D
C0/0A2C: 64 0D        STZ $0D
C0/0A2E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0A31: A5 0D        LDA $0D
C0/0A33: 38           SEC 
C0/0A34: E5 3D        SBC $3D
C0/0A36: 85 0D        STA $0D
C0/0A38: B0 0C        BCS $0A46
C0/0A3A: EE 89 02     INC $0289
C0/0A3D: EE 8D 02     INC $028D
C0/0A40: EE 91 02     INC $0291
C0/0A43: EE 95 02     INC $0295
C0/0A46: C6 3D        DEC $3D
C0/0A48: A5 3D        LDA $3D
C0/0A4A: 30 E2        BMI $0A2E
C0/0A4C: 60           RTS 

; board ship
C0/0A4D: A2 FC 01     LDX #$01FC
C0/0A50: 20 6A 04     JSR $046A       ; execute trigger script
C0/0A53: 60           RTS 

; get off ship
C0/0A54: 64 58        STZ $58
C0/0A56: 60           RTS 

; board airship
C0/0A57: 20 98 47     JSR $4798
C0/0A5A: A9 00        LDA #$00
C0/0A5C: 85 3D        STA $3D
C0/0A5E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0A61: 20 F8 5B     JSR $5BF8
C0/0A64: 20 95 4C     JSR $4C95       ; clear sprite data
C0/0A67: AC 9C 16     LDY $169C
C0/0A6A: A5 3D        LDA $3D
C0/0A6C: AA           TAX 
C0/0A6D: BF 4F 0C C0  LDA $C00C4F,X
C0/0A71: 85 6F        STA $6F
C0/0A73: 0A           ASL 
C0/0A74: 09 80        ORA #$80
C0/0A76: 99 DE 0A     STA $0ADE,Y
C0/0A79: A5 6F        LDA $6F
C0/0A7B: F0 11        BEQ $0A8E
C0/0A7D: C9 0C        CMP #$0C
C0/0A7F: B0 0D        BCS $0A8E
C0/0A81: A9 70        LDA #$70
C0/0A83: 8D 79 18     STA $1879
C0/0A86: A9 7B        LDA #$7B
C0/0A88: 8D 7A 18     STA $187A
C0/0A8B: 20 41 47     JSR $4741
C0/0A8E: 20 37 21     JSR $2137
C0/0A91: 20 2B 61     JSR $612B
C0/0A94: 20 64 1E     JSR $1E64
C0/0A97: 20 F7 47     JSR $47F7
C0/0A9A: E6 3D        INC $3D
C0/0A9C: A5 3D        LDA $3D
C0/0A9E: C9 40        CMP #$40
C0/0AA0: D0 BC        BNE $0A5E
C0/0AA2: 60           RTS 

; land airship
C0/0AA3: A9 03        LDA #$03
C0/0AA5: 8D DB 0A     STA $0ADB
C0/0AA8: AD F1 0A     LDA $0AF1
C0/0AAB: 29 03        AND #$03
C0/0AAD: F0 4C        BEQ $0AFB
C0/0AAF: 3A           DEC 
C0/0AB0: D0 03        BNE $0AB5
C0/0AB2: 4C D1 0B     JMP $0BD1
C0/0AB5: 3A           DEC 
C0/0AB6: D0 0D        BNE $0AC5
C0/0AB8: 20 F7 09     JSR $09F7
C0/0ABB: A2 2C 00     LDX #$002C
C0/0ABE: 20 6A 04     JSR $046A       ; execute trigger script
C0/0AC1: 20 11 0A     JSR $0A11
C0/0AC4: 60           RTS 
C0/0AC5: AD FA 10     LDA $10FA       ; world tile properties byte 1
C0/0AC8: 10 30        BPL $0AFA       ; branch if submarine can't surface
C0/0ACA: 20 C6 09     JSR $09C6
C0/0ACD: A2 2E 00     LDX #$002E
C0/0AD0: 20 6A 04     JSR $046A       ; execute trigger script
C0/0AD3: 20 68 4A     JSR $4A68
C0/0AD6: A9 01        LDA #$01
C0/0AD8: 85 BD        STA $BD
C0/0ADA: A9 28        LDA #$28
C0/0ADC: 8D 9B 16     STA $169B
C0/0ADF: 20 FB 22     JSR $22FB
C0/0AE2: A9 18        LDA #$18
C0/0AE4: 8D 9B 16     STA $169B
C0/0AE7: 20 FB 22     JSR $22FB
C0/0AEA: AD F1 0A     LDA $0AF1
C0/0AED: 29 E0        AND #$E0
C0/0AEF: 09 15        ORA #$15
C0/0AF1: 8D F1 0A     STA $0AF1
C0/0AF4: 20 83 45     JSR $4583
C0/0AF7: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0AFA: 60           RTS 
C0/0AFB: A5 57        LDA $57
C0/0AFD: D0 5D        BNE $0B5C
C0/0AFF: A9 FA        LDA #$FA
C0/0B01: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/0B04: C9 00        CMP #$00
C0/0B06: F0 54        BEQ $0B5C
C0/0B08: 20 9F 0C     JSR $0C9F
C0/0B0B: AD 97 16     LDA $1697
C0/0B0E: 30 4B        BMI $0B5B
C0/0B10: D0 4A        BNE $0B5C
C0/0B12: A9 80        LDA #$80
C0/0B14: 85 3D        STA $3D
C0/0B16: 64 DA        STZ $DA
C0/0B18: 64 DB        STZ $DB
C0/0B1A: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0B1D: 20 37 21     JSR $2137
C0/0B20: A5 DA        LDA $DA
C0/0B22: 18           CLC 
C0/0B23: 65 3D        ADC $3D
C0/0B25: 85 DA        STA $DA
C0/0B27: 90 02        BCC $0B2B
C0/0B29: E6 DB        INC $DB
C0/0B2B: AD 89 02     LDA $0289
C0/0B2E: 38           SEC 
C0/0B2F: E5 DB        SBC $DB
C0/0B31: 8D 89 02     STA $0289
C0/0B34: 8D 8D 02     STA $028D
C0/0B37: AD 91 02     LDA $0291
C0/0B3A: 38           SEC 
C0/0B3B: E5 DB        SBC $DB
C0/0B3D: 8D 91 02     STA $0291
C0/0B40: 8D 95 02     STA $0295
C0/0B43: A5 3D        LDA $3D
C0/0B45: C9 C0        CMP #$C0
C0/0B47: D0 08        BNE $0B51
C0/0B49: A9 84        LDA #$84
C0/0B4B: 85 43        STA $43
C0/0B4D: A9 F0        LDA #$F0
C0/0B4F: 85 45        STA $45
C0/0B51: E6 3D        INC $3D
C0/0B53: D0 C5        BNE $0B1A
C0/0B55: A2 1E 00     LDX #$001E
C0/0B58: 20 6A 04     JSR $046A       ; execute trigger script
C0/0B5B: 60           RTS 
C0/0B5C: A9 2F        LDA #$2F
C0/0B5E: 85 3D        STA $3D
C0/0B60: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0B63: 20 F8 5B     JSR $5BF8
C0/0B66: 20 95 4C     JSR $4C95       ; clear sprite data
C0/0B69: AC 9C 16     LDY $169C
C0/0B6C: A5 3D        LDA $3D
C0/0B6E: AA           TAX 
C0/0B6F: BF 5F 0C C0  LDA $C00C5F,X
C0/0B73: 85 6F        STA $6F
C0/0B75: 0A           ASL 
C0/0B76: 09 80        ORA #$80
C0/0B78: 99 DE 0A     STA $0ADE,Y
C0/0B7B: 20 37 21     JSR $2137
C0/0B7E: 20 2B 61     JSR $612B
C0/0B81: 20 64 1E     JSR $1E64
C0/0B84: 20 F8 5B     JSR $5BF8
C0/0B87: C6 3D        DEC $3D
C0/0B89: A5 3D        LDA $3D
C0/0B8B: C9 FF        CMP #$FF
C0/0B8D: D0 D1        BNE $0B60
C0/0B8F: AD FA 10     LDA $10FA       ; world tile properties byte 1
C0/0B92: 29 10        AND #$10
C0/0B94: F0 32        BEQ $0BC8
C0/0B96: A9 01        LDA #$01
C0/0B98: 85 5B        STA $5B
C0/0B9A: 20 C4 46     JSR $46C4
C0/0B9D: 9C 9B 16     STZ $169B
C0/0BA0: 20 FB 22     JSR $22FB
C0/0BA3: 64 5B        STZ $5B
C0/0BA5: AC 9C 16     LDY $169C
C0/0BA8: B9 DD 0A     LDA $0ADD,Y     ; set vehicle to ship
C0/0BAB: 29 E0        AND #$E0
C0/0BAD: 09 15        ORA #$15
C0/0BAF: 99 DD 0A     STA $0ADD,Y
C0/0BB2: A9 80        LDA #$80
C0/0BB4: 99 DE 0A     STA $0ADE,Y
C0/0BB7: A9 04        LDA #$04
C0/0BB9: 85 C0        STA $C0
C0/0BBB: 20 37 21     JSR $2137
C0/0BBE: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0BC1: 20 83 45     JSR $4583
C0/0BC4: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0BC7: 60           RTS 
C0/0BC8: 9C DC 0A     STZ $0ADC
C0/0BCB: 20 41 4E     JSR $4E41       ; wait for vblank
C0/0BCE: 4C 53 08     JMP $0853
C0/0BD1: AD DC 0A     LDA $0ADC
C0/0BD4: C9 06        CMP #$06
C0/0BD6: D0 46        BNE $0C1E
C0/0BD8: A5 57        LDA $57
C0/0BDA: D0 13        BNE $0BEF
C0/0BDC: A9 F9        LDA #$F9
C0/0BDE: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/0BE1: C9 00        CMP #$00
C0/0BE3: F0 0A        BEQ $0BEF
C0/0BE5: 20 9F 0C     JSR $0C9F
C0/0BE8: AD 97 16     LDA $1697
C0/0BEB: 30 31        BMI $0C1E
C0/0BED: D0 30        BNE $0C1F
C0/0BEF: A9 08        LDA #$08
C0/0BF1: 8D 9B 16     STA $169B
C0/0BF4: A9 80        LDA #$80
C0/0BF6: 99 DE 0A     STA $0ADE,Y
C0/0BF9: AC 9C 16     LDY $169C
C0/0BFC: B9 DD 0A     LDA $0ADD,Y     ; set vehicle to submarine
C0/0BFF: 29 E0        AND #$E0
C0/0C01: 09 18        ORA #$18
C0/0C03: 99 DD 0A     STA $0ADD,Y
C0/0C06: A9 03        LDA #$03
C0/0C08: 8D DB 0A     STA $0ADB
C0/0C0B: A9 10        LDA #$10
C0/0C0D: 85 C0        STA $C0
C0/0C0F: 20 83 45     JSR $4583
C0/0C12: 20 FB 22     JSR $22FB
C0/0C15: A9 01        LDA #$01
C0/0C17: 85 5B        STA $5B
C0/0C19: 20 57 0A     JSR $0A57
C0/0C1C: 64 5B        STZ $5B
C0/0C1E: 60           RTS 
C0/0C1F: A9 10        LDA #$10
C0/0C21: 8D 9B 16     STA $169B
C0/0C24: A9 80        LDA #$80
C0/0C26: 99 DE 0A     STA $0ADE,Y
C0/0C29: 20 FB 22     JSR $22FB
C0/0C2C: AC 9C 16     LDY $169C
C0/0C2F: B9 DD 0A     LDA $0ADD,Y
C0/0C32: 29 E0        AND #$E0
C0/0C34: 09 10        ORA #$10
C0/0C36: 99 DD 0A     STA $0ADD,Y
C0/0C39: A9 03        LDA #$03
C0/0C3B: 8D DB 0A     STA $0ADB
C0/0C3E: A9 02        LDA #$02
C0/0C40: 85 C0        STA $C0
C0/0C42: 20 F7 09     JSR $09F7
C0/0C45: A2 2C 00     LDX #$002C
C0/0C48: 20 6A 04     JSR $046A       ; execute trigger script
C0/0C4B: 20 11 0A     JSR $0A11
C0/0C4E: 60           RTS 

C0/0C4F: 00 00        BRK $00
C0/0C51: 00 00        BRK $00
C0/0C53: 00 00        BRK $00
C0/0C55: 00 00        BRK $00
C0/0C57: 00 00        BRK $00
C0/0C59: 00 00        BRK $00
C0/0C5B: 00 00        BRK $00
C0/0C5D: 00 00        BRK $00
C0/0C5F: 00 01        BRK $01
C0/0C61: 01 01        ORA ($01,X)
C0/0C63: 01 02        ORA ($02,X)
C0/0C65: 02 02        COP $02
C0/0C67: 02 03        COP $03
C0/0C69: 03 03        ORA $03,S
C0/0C6B: 04 04        TSB $04
C0/0C6D: 04 05        TSB $05
C0/0C6F: 05 05        ORA $05
C0/0C71: 06 06        ASL $06
C0/0C73: 06 07        ASL $07
C0/0C75: 07 08        ORA [$08]
C0/0C77: 08           PHP 
C0/0C78: 08           PHP 
C0/0C79: 09 09        ORA #$09
C0/0C7B: 0A           ASL 
C0/0C7C: 0A           ASL 
C0/0C7D: 0A           ASL 
C0/0C7E: 0B           PHD 
C0/0C7F: 0B           PHD 
C0/0C80: 0B           PHD 
C0/0C81: 0C 0C 0C     TSB $0C0C
C0/0C84: 0D 0D 0D     ORA $0D0D
C0/0C87: 0E 0E 0E     ASL $0E0E
C0/0C8A: 0E 0F 0F     ASL $0F0F
C0/0C8D: 0F 0F 0F 0F  ORA $0F0F0F
C0/0C91: 0F 0F 0F 0F  ORA $0F0F0F
C0/0C95: 0F 0F 0F 0F  ORA $0F0F0F
C0/0C99: 0F 0F 0F 0F  ORA $0F0F0F
C0/0C9D: 0F 0F

; [  ]

C0/0C9F: 9C 97 16     STZ $1697
C0/0CA2: 20 41 4E     JSR $4E41
C0/0CA5: 20 95 4C     JSR $4C95       ; clear sprite data
C0/0CA8: 20 37 21     JSR $2137
C0/0CAB: 20 2B 61     JSR $612B
C0/0CAE: 20 64 1E     JSR $1E64
C0/0CB1: A5 03        LDA $03
C0/0CB3: 29 80        AND #$80
C0/0CB5: F0 06        BEQ $0CBD
C0/0CB7: A9 80        LDA #$80
C0/0CB9: 8D 97 16     STA $1697
C0/0CBC: 60           RTS 
C0/0CBD: A5 02        LDA $02
C0/0CBF: 29 80        AND #$80
C0/0CC1: F0 0A        BEQ $0CCD
C0/0CC3: AD B8 10     LDA $10B8
C0/0CC6: D0 05        BNE $0CCD
C0/0CC8: EE B8 10     INC $10B8
C0/0CCB: 80 6F        BRA $0D3C
C0/0CCD: A5 03        LDA $03
C0/0CCF: 29 0C        AND #$0C
C0/0CD1: F0 0E        BEQ $0CE1
C0/0CD3: C9 08        CMP #$08
C0/0CD5: D0 05        BNE $0CDC
C0/0CD7: 9C 97 16     STZ $1697
C0/0CDA: 80 05        BRA $0CE1
C0/0CDC: A9 01        LDA #$01
C0/0CDE: 8D 97 16     STA $1697
C0/0CE1: AD 97 16     LDA $1697
C0/0CE4: D0 06        BNE $0CEC
C0/0CE6: A5 3F        LDA $3F
C0/0CE8: 29 08        AND #$08
C0/0CEA: D0 21        BNE $0D0D
C0/0CEC: AC 9C 16     LDY $169C
C0/0CEF: B9 DE 0A     LDA $0ADE,Y
C0/0CF2: 29 7F        AND #$7F
C0/0CF4: 85 08        STA $08
C0/0CF6: A9 64        LDA #$64
C0/0CF8: 38           SEC 
C0/0CF9: E5 08        SBC $08
C0/0CFB: 8D 01 02     STA $0201
C0/0CFE: A9 74        LDA #$74
C0/0D00: 8D 00 02     STA $0200
C0/0D03: A9 48        LDA #$48
C0/0D05: 8D 02 02     STA $0202
C0/0D08: A9 36        LDA #$36
C0/0D0A: 8D 03 02     STA $0203
C0/0D0D: AD 97 16     LDA $1697
C0/0D10: F0 06        BEQ $0D18
C0/0D12: A5 3F        LDA $3F
C0/0D14: 29 08        AND #$08
C0/0D16: D0 21        BNE $0D39
C0/0D18: AC 9C 16     LDY $169C
C0/0D1B: B9 DE 0A     LDA $0ADE,Y
C0/0D1E: 29 7F        AND #$7F
C0/0D20: 85 08        STA $08
C0/0D22: A9 7E        LDA #$7E
C0/0D24: 38           SEC 
C0/0D25: E5 08        SBC $08
C0/0D27: 8D 05 02     STA $0205
C0/0D2A: A9 74        LDA #$74
C0/0D2C: 8D 04 02     STA $0204
C0/0D2F: A9 48        LDA #$48
C0/0D31: 8D 06 02     STA $0206
C0/0D34: A9 B6        LDA #$B6
C0/0D36: 8D 07 02     STA $0207
C0/0D39: 4C A2 0C     JMP $0CA2
C0/0D3C: 60           RTS 

C0/0D3D: A5 61        LDA $61
C0/0D3F: 29 1F        AND #$1F
C0/0D41: D0 30        BNE $0D73
C0/0D43: A5 63        LDA $63
C0/0D45: 29 1F        AND #$1F
C0/0D47: D0 2A        BNE $0D73
C0/0D49: 20 E8 17     JSR $17E8       ; update local tile properties (normal map)
C0/0D4C: A9 F1        LDA #$F1
C0/0D4E: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/0D51: C9 00        CMP #$00
C0/0D53: D0 0E        BNE $0D63
C0/0D55: A5 02        LDA $02
C0/0D57: 29 80        AND #$80
C0/0D59: F0 18        BEQ $0D73       ; branch if the a button is not down
C0/0D5B: AD B8 10     LDA $10B8
C0/0D5E: D0 13        BNE $0D73       ; 
C0/0D60: EE B8 10     INC $10B8
C0/0D63: 20 7B 31     JSR $317B       ; check npc events
C0/0D66: A5 58        LDA $58
C0/0D68: D0 09        BNE $0D73       ; branch if an event is running
C0/0D6A: A5 02        LDA $02
C0/0D6C: 29 80        AND #$80
C0/0D6E: F0 03        BEQ $0D73       ; branch if the a button is not down
C0/0D70: 20 74 0D     JSR $0D74       ; check treasure chests
C0/0D73: 60           RTS 

; [ check treasure chests ]

C0/0D74: C2 20        REP #$20
C0/0D76: AD D4 0A     LDA $0AD4
C0/0D79: AA           TAX 
C0/0D7A: BF 00 30 D1  LDA $D13000,X   ; first treasure on this map
C0/0D7E: 29 FF 00     AND #$00FF
C0/0D81: 0A           ASL 
C0/0D82: 0A           ASL 
C0/0D83: 85 23        STA $23
C0/0D85: BF 01 30 D1  LDA $D13001,X   ; first treasure on next map
C0/0D89: 29 FF 00     AND #$00FF
C0/0D8C: 0A           ASL 
C0/0D8D: 0A           ASL 
C0/0D8E: 85 26        STA $26
C0/0D90: A5 06        LDA $06
C0/0D92: E2 20        SEP #$20
C0/0D94: AD DB 0A     LDA $0ADB
C0/0D97: AA           TAX 
C0/0D98: AD D8 0A     LDA $0AD8
C0/0D9B: 18           CLC 
C0/0D9C: 7F 84 0F C0  ADC $C00F84,X
C0/0DA0: 29 3F        AND #$3F
C0/0DA2: 85 75        STA $75
C0/0DA4: AD D9 0A     LDA $0AD9
C0/0DA7: 18           CLC 
C0/0DA8: 7F 88 0F C0  ADC $C00F88,X
C0/0DAC: 29 3F        AND #$3F
C0/0DAE: 85 76        STA $76
C0/0DB0: A6 23        LDX $23
C0/0DB2: E4 26        CPX $26
C0/0DB4: F0 1C        BEQ $0DD2
C0/0DB6: B0 1A        BCS $0DD2
C0/0DB8: BF 10 32 D1  LDA $D13210,X   ; check x position
C0/0DBC: C5 75        CMP $75
C0/0DBE: D0 0A        BNE $0DCA
C0/0DC0: BF 11 32 D1  LDA $D13211,X   ; check y position
C0/0DC4: C5 76        CMP $76
C0/0DC6: D0 02        BNE $0DCA
C0/0DC8: 80 09        BRA $0DD3
C0/0DCA: E8           INX 
C0/0DCB: E8           INX 
C0/0DCC: E8           INX 
C0/0DCD: E8           INX 
C0/0DCE: 86 23        STX $23
C0/0DD0: 80 DE        BRA $0DB0
C0/0DD2: 60           RTS 
C0/0DD3: C2 20        REP #$20
C0/0DD5: 8A           TXA 
C0/0DD6: 4A           LSR 
C0/0DD7: 4A           LSR 
C0/0DD8: E2 20        SEP #$20
C0/0DDA: EB           XBA 
C0/0DDB: A9 00        LDA #$00
C0/0DDD: EB           XBA 
C0/0DDE: 8D A1 16     STA $16A1
C0/0DE1: 20 16 CA     JSR $CA16       ; get treasure flag
C0/0DE4: C9 00        CMP #$00
C0/0DE6: D0 EA        BNE $0DD2
C0/0DE8: A9 01        LDA #$01
C0/0DEA: 85 58        STA $58
C0/0DEC: 64 BA        STZ $BA
C0/0DEE: A6 23        LDX $23
C0/0DF0: DA           PHX 
C0/0DF1: BF 11 32 D1  LDA $D13211,X
C0/0DF5: C2 20        REP #$20
C0/0DF7: 0A           ASL 
C0/0DF8: 0A           ASL 
C0/0DF9: 0A           ASL 
C0/0DFA: 0A           ASL 
C0/0DFB: 0A           ASL 
C0/0DFC: 0A           ASL 
C0/0DFD: 85 0D        STA $0D
C0/0DFF: BF 10 32 D1  LDA $D13210,X
C0/0E03: 29 FF 00     AND #$00FF
C0/0E06: 18           CLC 
C0/0E07: 65 0D        ADC $0D
C0/0E09: AA           TAX 
C0/0E0A: A5 06        LDA $06
C0/0E0C: E2 20        SEP #$20
C0/0E0E: BF 00 00 7F  LDA $7F0000,X
C0/0E12: C9 02        CMP #$02
C0/0E14: D0 18        BNE $0E2E
C0/0E16: A9 8E        LDA #$8E
C0/0E18: 20 3C 46     JSR $463C       ; play sound effect
C0/0E1B: A6 06        LDX $06
C0/0E1D: 86 73        STX $73
C0/0E1F: A2 01 01     LDX #$0101
C0/0E22: 86 2C        STX $2C
C0/0E24: A9 12        LDA #$12
C0/0E26: 8D B3 16     STA $16B3
C0/0E29: 20 08 6F     JSR $6F08
C0/0E2C: 80 05        BRA $0E33
C0/0E2E: A9 68        LDA #$68
C0/0E30: 20 3C 46     JSR $463C       ; play sound effect
C0/0E33: FA           PLX 
C0/0E34: BF 12 32 D1  LDA $D13212,X
C0/0E38: 85 11        STA $11
C0/0E3A: BF 13 32 D1  LDA $D13213,X
C0/0E3E: 85 12        STA $12
C0/0E40: A5 11        LDA $11
C0/0E42: 10 03        BPL $0E47
C0/0E44: 4C BC 0E     JMP $0EBC

; gp
C0/0E47: 29 E0        AND #$E0
C0/0E49: D0 18        BNE $0E63
C0/0E4B: 20 3D 0F     JSR $0F3D       ; calculate gp (chest)
C0/0E4E: 20 FE 0E     JSR $0EFE       ; give gp
C0/0E51: 20 D7 4D     JSR $4DD7
C0/0E54: A2 03 00     LDX #$0003
C0/0E57: 86 AF        STX $AF
C0/0E59: 20 AE 83     JSR $83AE       ; show dialog
C0/0E5C: AD A1 16     LDA $16A1
C0/0E5F: 20 21 CA     JSR $CA21
C0/0E62: 60           RTS 

; spell
C0/0E63: C9 20        CMP #$20
C0/0E65: D0 17        BNE $0E7E
C0/0E67: A5 12        LDA $12
C0/0E69: 8D A3 16     STA $16A3
C0/0E6C: 20 A5 C9     JSR $C9A5       ; give magic
C0/0E6F: A2 04 00     LDX #$0004
C0/0E72: 86 AF        STX $AF
C0/0E74: 20 AE 83     JSR $83AE       ; show dialog
C0/0E77: AD A1 16     LDA $16A1
C0/0E7A: 20 21 CA     JSR $CA21
C0/0E7D: 60           RTS 

; item
C0/0E7E: A5 12        LDA $12
C0/0E80: 20 DD BF     JSR $BFDD
C0/0E83: C0 00 01     CPY #$0100
C0/0E86: F0 10        BEQ $0E98
C0/0E88: B9 40 07     LDA $0740,Y
C0/0E8B: C9 63        CMP #$63
C0/0E8D: F0 1E        BEQ $0EAD
C0/0E8F: B9 40 07     LDA $0740,Y
C0/0E92: 1A           INC 
C0/0E93: 99 40 07     STA $0740,Y
C0/0E96: 80 15        BRA $0EAD
C0/0E98: A4 06        LDY $06
C0/0E9A: B9 40 06     LDA $0640,Y
C0/0E9D: F0 03        BEQ $0EA2
C0/0E9F: C8           INY 
C0/0EA0: 80 F8        BRA $0E9A
C0/0EA2: AD A2 16     LDA $16A2
C0/0EA5: 99 40 06     STA $0640,Y
C0/0EA8: A9 01        LDA #$01
C0/0EAA: 99 40 07     STA $0740,Y
C0/0EAD: A2 02 00     LDX #$0002
C0/0EB0: 86 AF        STX $AF
C0/0EB2: 20 AE 83     JSR $83AE       ; show dialog
C0/0EB5: AD A1 16     LDA $16A1
C0/0EB8: 20 21 CA     JSR $CA21
C0/0EBB: 60           RTS 

; monster-in-a-box
C0/0EBC: A2 05 00     LDX #$0005
C0/0EBF: 86 AF        STX $AF
C0/0EC1: 20 AE 83     JSR $83AE       ; show dialog
C0/0EC4: A9 FF        LDA #$FF
C0/0EC6: 8D E0 0B     STA $0BE0
C0/0EC9: A5 11        LDA $11
C0/0ECB: 29 3F        AND #$3F
C0/0ECD: 09 40        ORA #$40
C0/0ECF: A6 11        LDX $11
C0/0ED1: DA           PHX 
C0/0ED2: 20 E6 BD     JSR $BDE6       ; event battle
C0/0ED5: AD C4 09     LDA $09C4
C0/0ED8: 29 01        AND #$01
C0/0EDA: F0 08        BEQ $0EE4       ; branch if party was not defeated
C0/0EDC: A9 F0        LDA #$F0        ; don't reset spc
C0/0EDE: 8D 00 1D     STA $1D00
C0/0EE1: 4C 00 00     JMP $0000       ; reset
C0/0EE4: 20 76 54     JSR $5476       ; reload map
C0/0EE7: FA           PLX 
C0/0EE8: 86 11        STX $11
C0/0EEA: AD C4 09     LDA $09C4
C0/0EED: 29 02        AND #$02
C0/0EEF: D0 0C        BNE $0EFD       ; branch if party ran away
C0/0EF1: A5 11        LDA $11
C0/0EF3: 29 40        AND #$40
C0/0EF5: D0 03        BNE $0EFA
C0/0EF7: 4C 7E 0E     JMP $0E7E       ; item
C0/0EFA: 4C 67 0E     JMP $0E67       ; spell
C0/0EFD: 60           RTS 

; [ give gp ]

; ++$37: gp

C0/0EFE: AD 47 09     LDA $0947       ; current gp
C0/0F01: 18           CLC 
C0/0F02: 65 37        ADC $37
C0/0F04: 8D 47 09     STA $0947
C0/0F07: AD 48 09     LDA $0948
C0/0F0A: 65 38        ADC $38
C0/0F0C: 8D 48 09     STA $0948
C0/0F0F: AD 49 09     LDA $0949
C0/0F12: 65 39        ADC $39
C0/0F14: 8D 49 09     STA $0949
C0/0F17: C9 98        CMP #$98        ; max 9999999
C0/0F19: F0 04        BEQ $0F1F
C0/0F1B: 90 1F        BCC $0F3C
C0/0F1D: B0 12        BCS $0F31
C0/0F1F: AD 48 09     LDA $0948
C0/0F22: C9 96        CMP #$96
C0/0F24: F0 04        BEQ $0F2A
C0/0F26: 90 14        BCC $0F3C
C0/0F28: B0 07        BCS $0F31
C0/0F2A: AD 47 09     LDA $0947
C0/0F2D: C9 7F        CMP #$7F
C0/0F2F: 90 0B        BCC $0F3C
C0/0F31: A2 96 98     LDX #$9896
C0/0F34: 8E 48 09     STX $0948
C0/0F37: A9 7F        LDA #$7F
C0/0F39: 8D 47 09     STA $0947
C0/0F3C: 60           RTS 

; [ calculate gp (chest) ]

;   $11: multiplier (1, 10, 100, 1000, 10000, 34464, 256, 65280)
;   $12: value
; ++$37: value (out)

C0/0F3D: 64 39        STZ $39
C0/0F3F: A5 11        LDA $11
C0/0F41: 29 07        AND #$07
C0/0F43: 0A           ASL 
C0/0F44: AA           TAX 
C0/0F45: A5 12        LDA $12
C0/0F47: 8D 02 42     STA $4202
C0/0F4A: BF 78 0F C0  LDA $C00F78,X
C0/0F4E: 8D 03 42     STA $4203
C0/0F51: EA           NOP 
C0/0F52: EA           NOP 
C0/0F53: EA           NOP 
C0/0F54: EA           NOP 
C0/0F55: AC 16 42     LDY $4216
C0/0F58: 84 37        STY $37
C0/0F5A: A5 12        LDA $12
C0/0F5C: 8D 02 42     STA $4202
C0/0F5F: BF 79 0F C0  LDA $C00F79,X
C0/0F63: 8D 03 42     STA $4203
C0/0F66: EA           NOP 
C0/0F67: EA           NOP 
C0/0F68: EA           NOP 
C0/0F69: C2 20        REP #$20
C0/0F6B: AD 16 42     LDA $4216
C0/0F6E: 18           CLC 
C0/0F6F: 65 38        ADC $38
C0/0F71: 85 38        STA $38
C0/0F73: A5 06        LDA $06
C0/0F75: E2 20        SEP #$20
C0/0F77: 60           RTS 

C0/0F78:              .DW $0001, $000A, $0064, $03E8, $2710, $86A0
C0/0F84:              .DW $0100, $FF00, $00FF, $0001

C0/0F8C: A5 BA        LDA $BA
C0/0F8E: D0 02        BNE $0F92
C0/0F90: 64 41        STZ $41
C0/0F92: A5 61        LDA $61
C0/0F94: 29 1F        AND #$1F
C0/0F96: D0 06        BNE $0F9E
C0/0F98: A5 63        LDA $63
C0/0F9A: 29 1F        AND #$1F
C0/0F9C: F0 01        BEQ $0F9F
C0/0F9E: 60           RTS 
C0/0F9F: A5 57        LDA $57
C0/0FA1: F0 04        BEQ $0FA7
C0/0FA3: A6 3B        LDX $3B
C0/0FA5: 86 02        STX $02
C0/0FA7: 20 4A 10     JSR $104A
C0/0FAA: A5 03        LDA $03
C0/0FAC: 29 0F        AND #$0F
C0/0FAE: D0 03        BNE $0FB3
C0/0FB0: 4C 03 10     JMP $1003
C0/0FB3: A5 03        LDA $03
C0/0FB5: 29 08        AND #$08
C0/0FB7: F0 0E        BEQ $0FC7
C0/0FB9: A9 01        LDA #$01
C0/0FBB: 85 C4        STA $C4
C0/0FBD: 20 55 10     JSR $1055
C0/0FC0: A5 C4        LDA $C4
C0/0FC2: F0 3F        BEQ $1003
C0/0FC4: 4C 06 10     JMP $1006
C0/0FC7: A5 03        LDA $03
C0/0FC9: 29 01        AND #$01
C0/0FCB: F0 0E        BEQ $0FDB
C0/0FCD: A9 02        LDA #$02
C0/0FCF: 85 C4        STA $C4
C0/0FD1: 20 55 10     JSR $1055
C0/0FD4: A5 C4        LDA $C4
C0/0FD6: F0 2B        BEQ $1003
C0/0FD8: 4C 06 10     JMP $1006
C0/0FDB: A5 03        LDA $03
C0/0FDD: 29 04        AND #$04
C0/0FDF: F0 0E        BEQ $0FEF
C0/0FE1: A9 03        LDA #$03
C0/0FE3: 85 C4        STA $C4
C0/0FE5: 20 55 10     JSR $1055
C0/0FE8: A5 C4        LDA $C4
C0/0FEA: F0 17        BEQ $1003
C0/0FEC: 4C 06 10     JMP $1006
C0/0FEF: A5 03        LDA $03
C0/0FF1: 29 02        AND #$02
C0/0FF3: F0 11        BEQ $1006
C0/0FF5: A9 04        LDA #$04
C0/0FF7: 85 C4        STA $C4
C0/0FF9: 20 55 10     JSR $1055
C0/0FFC: A5 C4        LDA $C4
C0/0FFE: F0 03        BEQ $1003
C0/1000: 4C 06 10     JMP $1006
C0/1003: 64 BA        STZ $BA
C0/1005: 60           RTS 
C0/1006: 85 BA        STA $BA
C0/1008: AD D9 0A     LDA $0AD9
C0/100B: 85 76        STA $76
C0/100D: 20 A1 69     JSR $69A1
C0/1010: AD D9 0A     LDA $0AD9
C0/1013: 85 76        STA $76
C0/1015: AD D8 0A     LDA $0AD8
C0/1018: 85 75        STA $75
C0/101A: 20 13 65     JSR $6513
C0/101D: E6 9F        INC $9F
C0/101F: 64 59        STZ $59
C0/1021: 9C AA 16     STZ $16AA
C0/1024: AD DC 0A     LDA $0ADC
C0/1027: D0 03        BNE $102C
C0/1029: 20 8D 14     JSR $148D       ; poison damage
C0/102C: 20 3A 10     JSR $103A
C0/102F: A9 FC        LDA #$FC
C0/1031: 20 96 C7     JSR $C796
C0/1034: A9 FD        LDA #$FD
C0/1036: 20 96 C7     JSR $C796
C0/1039: 60           RTS 

; [  ]

C0/103A: A5 CA        LDA $CA
C0/103C: F0 0B        BEQ $1049
C0/103E: A5 BA        LDA $BA         ; movement direction
C0/1040: AA           TAX 
C0/1041: BF B8 11 C0  LDA $C011B8,X   ; pointer to tile in  movement direction
C0/1045: AA           TAX 
C0/1046: 20 9A 11     JSR $119A       ; get world tile transparent/underwater flags
C0/1049: 60           RTS 

; [  ]

C0/104A: A5 CA        LDA $CA
C0/104C: D0 06        BNE $1054
C0/104E: A2 08 00     LDX #$0008      ; tile at party location
C0/1051: 20 9A 11     JSR $119A       ; get world tile transparent/underwater flags
C0/1054: 60           RTS 

; [  ]

C0/1055: A5 C4        LDA $C4         ; movement direction
C0/1057: 3A           DEC 
C0/1058: 8D DB 0A     STA $0ADB       ; party facing direction
C0/105B: A5 57        LDA $57
C0/105D: D0 64        BNE $10C3       ; return if an event is running
C0/105F: 20 2D 11     JSR $112D       ; check if there is a vehicle at the current position
C0/1062: C9 01        CMP #$01
C0/1064: F0 5D        BEQ $10C3       ; return if there is a vehicle present
C0/1066: A5 C4        LDA $C4
C0/1068: AA           TAX 
C0/1069: AD DC 0A     LDA $0ADC       ; current vehicle
C0/106C: F0 19        BEQ $1087
C0/106E: 3A           DEC 
C0/106F: 0A           ASL 
C0/1070: 0A           ASL 
C0/1071: A8           TAY 
C0/1072: B9 DD 0A     LDA $0ADD,Y     ; vehicle index
C0/1075: 29 1C        AND #$1C
C0/1077: 4A           LSR 
C0/1078: 4A           LSR 
C0/1079: C9 01        CMP #$01
C0/107B: F0 0A        BEQ $1087       ; branch if chocobo
C0/107D: C9 04        CMP #$04
C0/107F: F0 11        BEQ $1092       ; branch if submarine
C0/1081: C9 05        CMP #$05
C0/1083: F0 0D        BEQ $1092       ; branch if ship
C0/1085: 80 16        BRA $109D
C0/1087: AD FB 10     LDA $10FB       ; world tile properties byte 2
C0/108A: 3F BD 11 C0  AND $C011BD,X
C0/108E: F0 34        BEQ $10C4       ; branch if not passable in that direction
C0/1090: 80 0B        BRA $109D
C0/1092: AD FB 10     LDA $10FB       ; world tile properties byte 2
C0/1095: 49 0F        EOR #$0F
C0/1097: 3F BD 11 C0  AND $C011BD,X
C0/109B: F0 27        BEQ $10C4       ; branch if ship/sub can't land there
C0/109D: AD DC 0A     LDA $0ADC
C0/10A0: F0 0B        BEQ $10AD
C0/10A2: 3A           DEC 
C0/10A3: 0A           ASL 
C0/10A4: 0A           ASL 
C0/10A5: A8           TAY 
C0/10A6: B9 DD 0A     LDA $0ADD,Y     ; vehicle index
C0/10A9: 29 1C        AND #$1C
C0/10AB: 4A           LSR 
C0/10AC: 4A           LSR 
C0/10AD: AA           TAX 
C0/10AE: BF B0 11 C0  LDA $C011B0,X   ; bit mask
C0/10B2: 85 0D        STA $0D
C0/10B4: A5 C4        LDA $C4
C0/10B6: AA           TAX 
C0/10B7: BF B8 11 C0  LDA $C011B8,X   ; pointer to tile properties in facing direction
C0/10BB: A8           TAY 
C0/10BC: B9 F2 10     LDA $10F2,Y     ; world tile properties byte 1
C0/10BF: 25 0D        AND $0D
C0/10C1: F0 01        BEQ $10C4       ; branch if not passable
C0/10C3: 60           RTS 
C0/10C4: 20 C8 10     JSR $10C8
C0/10C7: 60           RTS 

; [  ]

C0/10C8: AE D6 0A     LDX $0AD6       ; map index
C0/10CB: E0 03 00     CPX #$0003
C0/10CE: B0 5A        BCS $112A       ; branch if not a world map
C0/10D0: AD DC 0A     LDA $0ADC
C0/10D3: F0 55        BEQ $112A       ; branch if not in a vehicle
C0/10D5: 3A           DEC 
C0/10D6: 0A           ASL 
C0/10D7: 0A           ASL 
C0/10D8: A8           TAY 
C0/10D9: B9 DD 0A     LDA $0ADD,Y
C0/10DC: 29 1C        AND #$1C
C0/10DE: 4A           LSR 
C0/10DF: 4A           LSR 
C0/10E0: C9 04        CMP #$04
C0/10E2: F0 04        BEQ $10E8
C0/10E4: C9 05        CMP #$05
C0/10E6: D0 42        BNE $112A
C0/10E8: A5 C4        LDA $C4
C0/10EA: AA           TAX 
C0/10EB: BF B8 11 C0  LDA $C011B8,X
C0/10EF: AA           TAX 
C0/10F0: BD F2 10     LDA $10F2,X     ; world tile properties byte 1
C0/10F3: 29 01        AND #$01
C0/10F5: F0 33        BEQ $112A       ; branch if not passable on foot
C0/10F7: 9C DC 0A     STZ $0ADC
C0/10FA: AD D6 0A     LDA $0AD6       ; map index
C0/10FD: 0A           ASL 
C0/10FE: 0A           ASL 
C0/10FF: 0A           ASL 
C0/1100: 0A           ASL 
C0/1101: 0A           ASL 
C0/1102: 85 08        STA $08
C0/1104: B9 DD 0A     LDA $0ADD,Y
C0/1107: 29 1F        AND #$1F
C0/1109: 05 08        ORA $08
C0/110B: 99 DD 0A     STA $0ADD,Y
C0/110E: A9 02        LDA #$02
C0/1110: 85 C0        STA $C0
C0/1112: A9 00        LDA #$00
C0/1114: 99 DE 0A     STA $0ADE,Y
C0/1117: AD D8 0A     LDA $0AD8
C0/111A: 99 DF 0A     STA $0ADF,Y
C0/111D: AD D9 0A     LDA $0AD9
C0/1120: 99 E0 0A     STA $0AE0,Y
C0/1123: 20 83 45     JSR $4583
C0/1126: 20 41 4E     JSR $4E41       ; wait for vblank
C0/1129: 60           RTS 
C0/112A: 64 C4        STZ $C4
C0/112C: 60           RTS 

; [ check if there is a vehicle at the current position ]

; return 0 if not, 1 if there is a vehicle
; $23 is a pointer to vehicle data

C0/112D: AD DC 0A     LDA $0ADC
C0/1130: D0 5D        BNE $118F
C0/1132: A5 C4        LDA $C4
C0/1134: 3A           DEC 
C0/1135: AA           TAX 
C0/1136: AD D8 0A     LDA $0AD8
C0/1139: 18           CLC 
C0/113A: 7F 92 11 C0  ADC $C01192,X
C0/113E: 85 75        STA $75
C0/1140: AD D9 0A     LDA $0AD9
C0/1143: 18           CLC 
C0/1144: 7F 96 11 C0  ADC $C01196,X
C0/1148: 85 76        STA $76
C0/114A: A4 06        LDY $06
C0/114C: 84 23        STY $23         ; pointer to vehicle data (+$0ADD)
C0/114E: A4 23        LDY $23
C0/1150: B9 DE 0A     LDA $0ADE,Y
C0/1153: 30 2F        BMI $1184       ; branch if vehicle is hidden
C0/1155: B9 DD 0A     LDA $0ADD,Y
C0/1158: 29 1C        AND #$1C
C0/115A: 4A           LSR 
C0/115B: 4A           LSR 
C0/115C: C9 04        CMP #$04
C0/115E: F0 04        BEQ $1164
C0/1160: C9 05        CMP #$05
C0/1162: D0 20        BNE $1184
C0/1164: B9 DD 0A     LDA $0ADD,Y     ; vehicle map
C0/1167: 29 E0        AND #$E0
C0/1169: 4A           LSR 
C0/116A: 4A           LSR 
C0/116B: 4A           LSR 
C0/116C: 4A           LSR 
C0/116D: 4A           LSR 
C0/116E: CD D6 0A     CMP $0AD6       ; map index
C0/1171: D0 11        BNE $1184       ; branch if vehicle is not on this map
C0/1173: B9 DF 0A     LDA $0ADF,Y
C0/1176: C5 75        CMP $75
C0/1178: D0 0A        BNE $1184       ; branch if xy position doesn't match
C0/117A: B9 E0 0A     LDA $0AE0,Y
C0/117D: C5 76        CMP $76
C0/117F: D0 03        BNE $1184
C0/1181: A9 01        LDA #$01
C0/1183: 60           RTS 
C0/1184: A5 23        LDA $23         ; next vehicle
C0/1186: 18           CLC 
C0/1187: 69 04        ADC #$04
C0/1189: 85 23        STA $23
C0/118B: C9 18        CMP #$18
C0/118D: D0 BF        BNE $114E
C0/118F: A9 00        LDA #$00
C0/1191: 60           RTS 

C0/1192: 00 01 00 FF
C0/1196: FF 00 01 00

; [ get world tile transparent/underwater flags ]

C0/119A: BD BE 10     LDA $10BE,X     ; get tile index * 3
C0/119D: C2 20        REP #$20
C0/119F: 0A           ASL 
C0/11A0: 18           CLC 
C0/11A1: 7D BE 10     ADC $10BE,X
C0/11A4: AA           TAX 
C0/11A5: BD 88 11     LDA $1188,X     ; tile properties byte 3
C0/11A8: 29 60 00     AND #$0060
C0/11AB: E2 20        SEP #$20
C0/11AD: 85 CA        STA $CA
C0/11AF: 60           RTS 

C0/11B0: 01 02 04 08 10 20 40 80
C0/11B8: 00 02 0A 0E 06
C0/11BD: 00 08 01 04 02

; [  ]

C0/11C2: A5 BA        LDA $BA
C0/11C4: D0 02        BNE $11C8       ; branch if party is moving
C0/11C6: 64 41        STZ $41
C0/11C8: A5 61        LDA $61         ; bg1 x position
C0/11CA: 29 1F        AND #$1F
C0/11CC: D0 06        BNE $11D4       ; return if partway between tiles
C0/11CE: A5 63        LDA $63         ; bg1 y position
C0/11D0: 29 1F        AND #$1F
C0/11D2: F0 01        BEQ $11D5
C0/11D4: 60           RTS 
C0/11D5: A5 57        LDA $57
C0/11D7: F0 06        BEQ $11DF       ; branch if an event is running
C0/11D9: A6 3B        LDX $3B         ; override pressed buttons with ???
C0/11DB: 86 02        STX $02
C0/11DD: 80 1D        BRA $11FC
C0/11DF: 20 1D 15     JSR $151D       ; update party sprite priority (current tile)
C0/11E2: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/11E5: 29 40        AND #$40
C0/11E7: F0 0D        BEQ $11F6       ; branch if not forced facing direction
C0/11E9: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/11EC: 29 0F        AND #$0F
C0/11EE: AA           TAX 
C0/11EF: BF 2A 17 C0  LDA $C0172A,X   ; forced facing direction
C0/11F3: 3A           DEC 
C0/11F4: 80 03        BRA $11F9
C0/11F6: A5 BF        LDA $BF
C0/11F8: 3A           DEC 
C0/11F9: 8D DB 0A     STA $0ADB       ; party facing direction
C0/11FC: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/11FF: 29 04        AND #$04
C0/1201: D0 0F        BNE $1212       ; branch if a bridge tile
C0/1203: A5 BE        LDA $BE
C0/1205: D0 0B        BNE $1212       ; branch if jumping
C0/1207: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/120A: 29 03        AND #$03
C0/120C: C9 03        CMP #$03
C0/120E: F0 02        BEQ $1212       ; branch if stairs
C0/1210: 85 C3        STA $C3         ; set z-level
C0/1212: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/1215: 29 20        AND #$20
C0/1217: F0 13        BEQ $122C       ; branch if no tile damage
C0/1219: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/121C: 29 04        AND #$04
C0/121E: F0 0A        BEQ $122A
C0/1220: A5 C3        LDA $C3         ; z-level
C0/1222: 29 01        AND #$01
C0/1224: F0 04        BEQ $122A       ; branch if not passable on upper z-level
C0/1226: A9 00        LDA #$00        ; use downstairs tile damage properties
C0/1228: 80 02        BRA $122C
C0/122A: A9 01        LDA #$01        ; use upstairs tile damage properties
C0/122C: 85 C9        STA $C9
C0/122E: 20 A6 13     JSR $13A6       ; update party z-level (current tile)
C0/1231: 20 B7 16     JSR $16B7
C0/1234: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/1237: 29 30        AND #$30
C0/1239: 4A           LSR 
C0/123A: 4A           LSR 
C0/123B: 4A           LSR 
C0/123C: 4A           LSR 
C0/123D: AA           TAX 
C0/123E: BF 1C 17 C0  LDA $C0171C,X   ; tile movement speed
C0/1242: 85 C0        STA $C0
C0/1244: AD FA 0A     LDA $0AFA       ; walking speed
C0/1247: F0 06        BEQ $124F
C0/1249: 10 2D        BPL $1278
C0/124B: 46 C0        LSR $C0         ; half speed
C0/124D: 80 2B        BRA $127A
C0/124F: A5 03        LDA $03
C0/1251: 29 80        AND #$80
C0/1253: F0 25        BEQ $127A       ; branch if B button is not pressed
C0/1255: A6 06        LDX $06
C0/1257: BD 00 05     LDA $0500,X     ; branch if character not present
C0/125A: 29 40        AND #$40
C0/125C: D0 07        BNE $1265
C0/125E: BD 20 05     LDA $0520,X     ; check for dash ability
C0/1261: 29 08        AND #$08
C0/1263: D0 13        BNE $1278
C0/1265: C2 20        REP #$20        ; next character
C0/1267: 8A           TXA 
C0/1268: 18           CLC 
C0/1269: 69 50 00     ADC #$0050
C0/126C: AA           TAX 
C0/126D: A5 06        LDA $06
C0/126F: E2 20        SEP #$20
C0/1271: E0 40 01     CPX #$0140
C0/1274: D0 E1        BNE $1257
C0/1276: 80 02        BRA $127A
C0/1278: 06 C0        ASL $C0         ; double speed
C0/127A: AD 20 11     LDA $1120
C0/127D: 20 1F 16     JSR $161F       ; calculate parallax scroll
C0/1280: 8D 80 10     STA $1080
C0/1283: 9C 81 10     STZ $1081
C0/1286: AD 20 11     LDA $1120
C0/1289: 4A           LSR 
C0/128A: 4A           LSR 
C0/128B: 20 1F 16     JSR $161F       ; calculate parallax scroll
C0/128E: 8D 82 10     STA $1082
C0/1291: 9C 83 10     STZ $1083
C0/1294: AD 20 11     LDA $1120
C0/1297: 4A           LSR 
C0/1298: 4A           LSR 
C0/1299: 4A           LSR 
C0/129A: 4A           LSR 
C0/129B: 20 1F 16     JSR $161F       ; calculate parallax scroll
C0/129E: 8D 84 10     STA $1084
C0/12A1: 9C 85 10     STZ $1085
C0/12A4: AD 20 11     LDA $1120
C0/12A7: 4A           LSR 
C0/12A8: 4A           LSR 
C0/12A9: 4A           LSR 
C0/12AA: 4A           LSR 
C0/12AB: 4A           LSR 
C0/12AC: 4A           LSR 
C0/12AD: 20 1F 16     JSR $161F       ; calculate parallax scroll
C0/12B0: 8D 86 10     STA $1086
C0/12B3: 9C 87 10     STZ $1087
C0/12B6: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/12B9: 10 0A        BPL $12C5       ; branch if not an auto-move tile
C0/12BB: 29 0F        AND #$0F
C0/12BD: AA           TAX 
C0/12BE: BF 2A 17 C0  LDA $C0172A,X
C0/12C2: 4C 36 13     JMP $1336
C0/12C5: A5 57        LDA $57
C0/12C7: D0 0F        BNE $12D8       ; branch if an event is running
C0/12C9: A5 5D        LDA $5D
C0/12CB: F0 0B        BEQ $12D8       ; branch if party is already moving
C0/12CD: 64 5D        STZ $5D
C0/12CF: 9C AA 16     STZ $16AA
C0/12D2: 20 D7 13     JSR $13D7       ; tile damage
C0/12D5: 20 8D 14     JSR $148D       ; poison damage
C0/12D8: A5 03        LDA $03
C0/12DA: 29 0F        AND #$0F
C0/12DC: D0 03        BNE $12E1       ; branch if any direction buttons are pressed
C0/12DE: 4C 31 13     JMP $1331       ; no move
C0/12E1: A5 03        LDA $03         ; check up button
C0/12E3: 29 08        AND #$08
C0/12E5: F0 0E        BEQ $12F5
C0/12E7: A9 01        LDA #$01        ; up
C0/12E9: 85 C4        STA $C4
C0/12EB: 20 3A 16     JSR $163A       ; check if party can move
C0/12EE: A5 C4        LDA $C4
C0/12F0: F0 3F        BEQ $1331
C0/12F2: 4C 36 13     JMP $1336
C0/12F5: A5 03        LDA $03         ; check right button
C0/12F7: 29 01        AND #$01
C0/12F9: F0 0E        BEQ $1309
C0/12FB: A9 02        LDA #$02        ; right
C0/12FD: 85 C4        STA $C4
C0/12FF: 20 3A 16     JSR $163A       ; check if party can move
C0/1302: A5 C4        LDA $C4
C0/1304: F0 2B        BEQ $1331
C0/1306: 4C 36 13     JMP $1336
C0/1309: A5 03        LDA $03         ; check down button
C0/130B: 29 04        AND #$04
C0/130D: F0 0E        BEQ $131D
C0/130F: A9 03        LDA #$03        ; down
C0/1311: 85 C4        STA $C4
C0/1313: 20 3A 16     JSR $163A       ; check if party can move
C0/1316: A5 C4        LDA $C4
C0/1318: F0 17        BEQ $1331
C0/131A: 4C 36 13     JMP $1336
C0/131D: A5 03        LDA $03         ; check left button
C0/131F: 29 02        AND #$02
C0/1321: F0 13        BEQ $1336
C0/1323: A9 04        LDA #$04        ; left
C0/1325: 85 C4        STA $C4
C0/1327: 20 3A 16     JSR $163A       ; check if party can move
C0/132A: A5 C4        LDA $C4
C0/132C: F0 03        BEQ $1331
C0/132E: 4C 36 13     JMP $1336
C0/1331: 64 BA        STZ $BA         ; no move
C0/1333: 4C 67 13     JMP $1367

; start move
C0/1336: 85 BA        STA $BA         ; set facing/moving direction
C0/1338: 85 BF        STA $BF
C0/133A: A9 01        LDA #$01
C0/133C: 85 5D        STA $5D
C0/133E: 64 59        STZ $59
C0/1340: 20 72 13     JSR $1372       ; update party z-level (destination tile)
C0/1343: A5 57        LDA $57
C0/1345: D0 07        BNE $134E       ; branch if an event is running
C0/1347: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/134A: 29 40        AND #$40
C0/134C: D0 06        BNE $1354       ; branch if forced facing direction
C0/134E: A5 BA        LDA $BA
C0/1350: 3A           DEC 
C0/1351: 8D DB 0A     STA $0ADB       ; set facing direction
C0/1354: 20 38 15     JSR $1538       ; update party sprite priority (destination tile)
C0/1357: A9 FC        LDA #$FC
C0/1359: 20 96 C7     JSR $C796       ; 
C0/135C: A9 FD        LDA #$FD
C0/135E: 20 96 C7     JSR $C796       ; 
C0/1361: 20 5B 15     JSR $155B
C0/1364: 20 AC 15     JSR $15AC
C0/1367: 20 73 29     JSR $2973
C0/136A: A5 58        LDA $58
C0/136C: D0 03        BNE $1371
C0/136E: 20 DA 16     JSR $16DA
C0/1371: 60           RTS 

; [ update party z-level (destination tile) ]

C0/1372: A5 BA        LDA $BA         ; movement direction
C0/1374: AA           TAX 
C0/1375: BF 20 17 C0  LDA $C01720,X   ; pointer to tile properties
C0/1379: AA           TAX 
C0/137A: A5 CA        LDA $CA
C0/137C: D0 07        BNE $1385
C0/137E: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/1381: 29 0C        AND #$0C
C0/1383: 85 CA        STA $CA
C0/1385: A5 CB        LDA $CB         ; return if party sprite is not hidden
C0/1387: F0 1C        BEQ $13A5
C0/1389: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/138C: 29 04        AND #$04
C0/138E: F0 0A        BEQ $139A       ; branch if not a bridge tile
C0/1390: A5 C3        LDA $C3         ; party z-level
C0/1392: 29 01        AND #$01
C0/1394: F0 04        BEQ $139A       ; branch if not on upper z-level
C0/1396: 64 CB        STZ $CB         ; show party sprite
C0/1398: 80 0B        BRA $13A5
C0/139A: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/139D: 29 10        AND #$10
C0/139F: 4A           LSR 
C0/13A0: 4A           LSR 
C0/13A1: 4A           LSR 
C0/13A2: 4A           LSR 
C0/13A3: 85 CB        STA $CB         ; show/hide party sprite
C0/13A5: 60           RTS 

; [ update party z-level (current tile) ]

C0/13A6: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/13A9: 29 03        AND #$03
C0/13AB: 09 04        ORA #$04
C0/13AD: 85 C2        STA $C2         ; set passable z-levels
C0/13AF: A5 CA        LDA $CA
C0/13B1: F0 07        BEQ $13BA       ; 
C0/13B3: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/13B6: 29 0C        AND #$0C
C0/13B8: 85 CA        STA $CA
C0/13BA: A5 CB        LDA $CB
C0/13BC: D0 18        BNE $13D6       ; return if party sprite is already hidden
C0/13BE: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/13C1: 29 10        AND #$10
C0/13C3: F0 11        BEQ $13D6       ; return if tile doesn't hide party sprite
C0/13C5: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/13C8: 29 04        AND #$04
C0/13CA: F0 06        BEQ $13D2       ; hide party sprite if not a bridge tile
C0/13CC: A5 C3        LDA $C3
C0/13CE: 29 01        AND #$01
C0/13D0: D0 04        BNE $13D6       ; return if on upper z-level
C0/13D2: A9 01        LDA #$01        ; hide party sprite
C0/13D4: 85 CB        STA $CB
C0/13D6: 60           RTS 

; [ tile damage ]

C0/13D7: A6 06        LDX $06
C0/13D9: BD 00 05     LDA $0500,X
C0/13DC: 29 40        AND #$40
C0/13DE: D0 0A        BNE $13EA       ; skip empty character slots
C0/13E0: BD 20 05     LDA $0520,X
C0/13E3: 29 04        AND #$04
C0/13E5: F0 03        BEQ $13EA
C0/13E7: 4C 74 14     JMP $1474       ; no damage if any character has floor damage ability
C0/13EA: C2 20        REP #$20
C0/13EC: 8A           TXA             ; next character
C0/13ED: 18           CLC 
C0/13EE: 69 50 00     ADC #$0050
C0/13F1: AA           TAX 
C0/13F2: A5 06        LDA $06
C0/13F4: E2 20        SEP #$20
C0/13F6: E0 40 01     CPX #$0140
C0/13F9: D0 DE        BNE $13D9
C0/13FB: A4 06        LDY $06
C0/13FD: B9 00 05     LDA $0500,Y
C0/1400: 29 40        AND #$40
C0/1402: D0 5F        BNE $1463       ; skip empty character slots
C0/1404: B9 1A 05     LDA $051A,Y
C0/1407: 29 C8        AND #$C8
C0/1409: D0 58        BNE $1463       ; skip dead/petrified/float characters
C0/140B: A5 C9        LDA $C9
C0/140D: AA           TAX 
C0/140E: BD 12 11     LDA $1112,X
C0/1411: 29 40        AND #$40
C0/1413: F0 08        BEQ $141D
C0/1415: B9 1A 05     LDA $051A,Y     ; inflict poison
C0/1418: 09 04        ORA #$04
C0/141A: 99 1A 05     STA $051A,Y
C0/141D: A5 C9        LDA $C9
C0/141F: AA           TAX 
C0/1420: BD 12 11     LDA $1112,X     ; tile damage
C0/1423: 29 07        AND #$07
C0/1425: 0A           ASL 
C0/1426: AA           TAX 
C0/1427: F0 25        BEQ $144E
C0/1429: C2 20        REP #$20
C0/142B: B9 06 05     LDA $0506,Y
C0/142E: F0 0C        BEQ $143C
C0/1430: 38           SEC 
C0/1431: FF 7D 14 C0  SBC $C0147D,X   ; subtract hp
C0/1435: F0 02        BEQ $1439
C0/1437: B0 03        BCS $143C
C0/1439: A9 01 00     LDA #$0001
C0/143C: 99 06 05     STA $0506,Y
C0/143F: A5 06        LDA $06
C0/1441: E2 20        SEP #$20
C0/1443: A9 8F        LDA #$8F
C0/1445: 8D AA 16     STA $16AA
C0/1448: A2 00 1E     LDX #$1E00
C0/144B: 8E AB 16     STX $16AB
C0/144E: A5 C9        LDA $C9
C0/1450: AA           TAX 
C0/1451: BD 12 11     LDA $1112,X     ; tile damage sound effect
C0/1454: 4A           LSR 
C0/1455: 4A           LSR 
C0/1456: 4A           LSR 
C0/1457: 29 07        AND #$07
C0/1459: F0 08        BEQ $1463
C0/145B: AA           TAX 
C0/145C: BF 74 14 C0  LDA $C01474,X
C0/1460: 20 3C 46     JSR $463C       ; play sound effect
C0/1463: C2 20        REP #$20
C0/1465: 98           TYA 
C0/1466: 18           CLC 
C0/1467: 69 50 00     ADC #$0050
C0/146A: A8           TAY 
C0/146B: A5 06        LDA $06
C0/146D: E2 20        SEP #$20
C0/146F: C0 40 01     CPY #$0140
C0/1472: D0 89        BNE $13FD
C0/1474: 60           RTS 

; floor damage sound effect
C0/1475:              .DB $94, $94, $94, $94, $94, $94, $94, $94

; floor damage values (0, 50, 50, 100, 300, 400, 500, 1000)
C0/147D:              .DW $0000, $0032, $0032, $0064, $012C, $0190, $01F4, $03E8

; [ poison damage ]

C0/148D: A5 57        LDA $57
C0/148F: D0 57        BNE $14E8       ; return if an event is running
C0/1491: A4 06        LDY $06
C0/1493: B9 00 05     LDA $0500,Y
C0/1496: 29 40        AND #$40
C0/1498: D0 3D        BNE $14D7       ; branch if character slot is empty
C0/149A: B9 1A 05     LDA $051A,Y
C0/149D: 29 C0        AND #$C0
C0/149F: D0 36        BNE $14D7       ; skip dead/petrified characters
C0/14A1: B9 1A 05     LDA $051A,Y
C0/14A4: 29 04        AND #$04
C0/14A6: F0 2F        BEQ $14D7       ; skip characters that are not poisoned
C0/14A8: A9 8F        LDA #$8F
C0/14AA: 8D AA 16     STA $16AA       ; pixelate screen
C0/14AD: C2 20        REP #$20
C0/14AF: A9 00 1E     LDA #$1E00
C0/14B2: 8D AB 16     STA $16AB
C0/14B5: B9 08 05     LDA $0508,Y
C0/14B8: 4A           LSR 
C0/14B9: 4A           LSR 
C0/14BA: 4A           LSR 
C0/14BB: 4A           LSR 
C0/14BC: 4A           LSR 
C0/14BD: 4A           LSR 
C0/14BE: 1A           INC 
C0/14BF: 85 0D        STA $0D
C0/14C1: B9 06 05     LDA $0506,Y
C0/14C4: F0 0A        BEQ $14D0
C0/14C6: 38           SEC 
C0/14C7: E5 0D        SBC $0D
C0/14C9: F0 02        BEQ $14CD
C0/14CB: B0 03        BCS $14D0
C0/14CD: A9 01 00     LDA #$0001
C0/14D0: 99 06 05     STA $0506,Y
C0/14D3: A5 06        LDA $06
C0/14D5: E2 20        SEP #$20
C0/14D7: C2 20        REP #$20
C0/14D9: 98           TYA 
C0/14DA: 18           CLC 
C0/14DB: 69 50 00     ADC #$0050
C0/14DE: A8           TAY 
C0/14DF: A5 06        LDA $06
C0/14E1: E2 20        SEP #$20
C0/14E3: C0 40 01     CPY #$0140
C0/14E6: D0 AB        BNE $1493
C0/14E8: 60           RTS 

; [ pixelate screen (poison) ]

C0/14E9: A4 06        LDY $06
C0/14EB: B9 00 05     LDA $0500,Y
C0/14EE: 29 40        AND #$40
C0/14F0: D0 19        BNE $150B
C0/14F2: B9 1A 05     LDA $051A,Y
C0/14F5: 29 C0        AND #$C0
C0/14F7: D0 12        BNE $150B
C0/14F9: B9 1A 05     LDA $051A,Y
C0/14FC: 29 04        AND #$04
C0/14FE: F0 0B        BEQ $150B
C0/1500: A9 8F        LDA #$8F        ; 
C0/1502: 8D AA 16     STA $16AA
C0/1505: A2 00 1E     LDX #$1E00      ; 
C0/1508: 8E AB 16     STX $16AB
C0/150B: C2 20        REP #$20
C0/150D: 98           TYA 
C0/150E: 18           CLC 
C0/150F: 69 50 00     ADC #$0050
C0/1512: A8           TAY 
C0/1513: A5 06        LDA $06
C0/1515: E2 20        SEP #$20
C0/1517: C0 40 01     CPY #$0140
C0/151A: D0 CF        BNE $14EB
C0/151C: 60           RTS 

; [ update party sprite priority (current tile) ]

C0/151D: A6 C7        LDX $C7         ; party sprite priority
C0/151F: E0 E8 01     CPX #$01E8
C0/1522: D0 13        BNE $1537       ; return if not currently low priority
C0/1524: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/1527: 29 40        AND #$40
C0/1529: D0 0C        BNE $1537       ; return if a low priority tile
C0/152B: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/152E: 29 04        AND #$04
C0/1530: D0 05        BNE $1537       ; return if a bridge tile
C0/1532: A2 10 01     LDX #$0110      ; change to normal priority
C0/1535: 86 C7        STX $C7
C0/1537: 60           RTS 

; [ update party sprite priority (destination tile) ]

C0/1538: A5 BA        LDA $BA         ; party moving direction
C0/153A: AA           TAX 
C0/153B: BF 20 17 C0  LDA $C01720,X   ; pointer to tile properties
C0/153F: AA           TAX 
C0/1540: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/1543: 29 40        AND #$40
C0/1545: D0 0E        BNE $1555       ; branch if a low priority tile
C0/1547: A4 C7        LDY $C7
C0/1549: C0 10 01     CPY #$0110
C0/154C: D0 0C        BNE $155A       ; return if currently normal priority
C0/154E: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/1551: 29 04        AND #$04
C0/1553: F0 05        BEQ $155A       ; return if not a bridge tile
C0/1555: A2 E8 01     LDX #$01E8      ; change to low priority
C0/1558: 86 C7        STX $C7
C0/155A: 60           RTS 

C0/155B: AD DB 0A     LDA $0ADB
C0/155E: 4A           LSR 
C0/155F: B0 4A        BCS $15AB
C0/1561: 4A           LSR 
C0/1562: B0 11        BCS $1575
C0/1564: AD C0 10     LDA $10C0
C0/1567: C9 13        CMP #$13
C0/1569: D0 40        BNE $15AB
C0/156B: AD D9 0A     LDA $0AD9
C0/156E: 38           SEC 
C0/156F: E9 02        SBC #$02
C0/1571: 85 76        STA $76
C0/1573: 80 0C        BRA $1581
C0/1575: AD CC 10     LDA $10CC
C0/1578: C9 13        CMP #$13
C0/157A: D0 2F        BNE $15AB
C0/157C: AD D9 0A     LDA $0AD9
C0/157F: 85 76        STA $76
C0/1581: A6 06        LDX $06
C0/1583: 86 73        STX $73
C0/1585: AD D8 0A     LDA $0AD8
C0/1588: 85 75        STA $75
C0/158A: A2 01 02     LDX #$0201
C0/158D: 86 2C        STX $2C
C0/158F: A9 04        LDA #$04
C0/1591: 8D B3 16     STA $16B3
C0/1594: A9 14        LDA #$14
C0/1596: 8D B4 16     STA $16B4
C0/1599: 20 08 6F     JSR $6F08
C0/159C: A9 8E        LDA #$8E
C0/159E: 20 3C 46     JSR $463C       ; play sound effect
C0/15A1: A9 01        LDA #$01
C0/15A3: 85 58        STA $58
C0/15A5: A5 57        LDA $57
C0/15A7: D0 02        BNE $15AB
C0/15A9: 64 BA        STZ $BA
C0/15AB: 60           RTS 
C0/15AC: A6 06        LDX $06
C0/15AE: BD 00 05     LDA $0500,X
C0/15B1: 29 40        AND #$40
C0/15B3: D0 07        BNE $15BC
C0/15B5: BD 20 05     LDA $0520,X
C0/15B8: 29 02        AND #$02
C0/15BA: D0 13        BNE $15CF
C0/15BC: C2 20        REP #$20
C0/15BE: 8A           TXA 
C0/15BF: 18           CLC 
C0/15C0: 69 50 00     ADC #$0050
C0/15C3: AA           TAX 
C0/15C4: A5 06        LDA $06
C0/15C6: E2 20        SEP #$20
C0/15C8: E0 40 01     CPX #$0140
C0/15CB: D0 E1        BNE $15AE
C0/15CD: 80 43        BRA $1612
C0/15CF: AD DB 0A     LDA $0ADB
C0/15D2: AA           TAX 
C0/15D3: BF 1B 16 C0  LDA $C0161B,X
C0/15D7: A8           TAY 
C0/15D8: B9 BE 10     LDA $10BE,Y
C0/15DB: C9 05        CMP #$05
C0/15DD: D0 33        BNE $1612
C0/15DF: AD D8 0A     LDA $0AD8
C0/15E2: 18           CLC 
C0/15E3: 7F 17 16 C0  ADC $C01617,X
C0/15E7: 85 75        STA $75
C0/15E9: AD D9 0A     LDA $0AD9
C0/15EC: 18           CLC 
C0/15ED: 7F 13 16 C0  ADC $C01613,X
C0/15F1: 85 76        STA $76
C0/15F3: A6 06        LDX $06
C0/15F5: 86 73        STX $73
C0/15F7: A2 01 01     LDX #$0101
C0/15FA: 86 2C        STX $2C
C0/15FC: A9 15        LDA #$15
C0/15FE: 8D B3 16     STA $16B3
C0/1601: 20 08 6F     JSR $6F08
C0/1604: A9 01        LDA #$01
C0/1606: 85 57        STA $57
C0/1608: A2 0B 00     LDX #$000B      ; event $0B
C0/160B: 86 CE        STX $CE
C0/160D: 20 17 A2     JSR $A217       ; execute event
C0/1610: 64 57        STZ $57
C0/1612: 60           RTS 

C0/1613: FF 00 01 00
C0/1617: 00 01 00 FF
C0/161B: 02 0A 0E 06

; [ calculate parallax scroll ]

; 0 = return $C0 (1x)
; 1 = return $C0 >> 1 (0.5x)
; 2 = return $C0 << 1 (2x)
; 3 = return zero (no scroll)

C0/161F: 29 03        AND #$03
C0/1621: D0 04        BNE $1627
C0/1623: A5 C0        LDA $C0
C0/1625: 80 12        BRA $1639
C0/1627: 3A           DEC 
C0/1628: D0 05        BNE $162F
C0/162A: A5 C0        LDA $C0
C0/162C: 4A           LSR 
C0/162D: 80 0A        BRA $1639
C0/162F: 3A           DEC 
C0/1630: D0 05        BNE $1637
C0/1632: A5 C0        LDA $C0
C0/1634: 0A           ASL 
C0/1635: 80 02        BRA $1639
C0/1637: A5 06        LDA $06
C0/1639: 60           RTS 

; [ check if party can move ]

; $C4: direction (none, up, right, down, left)

C0/163A: A5 57        LDA $57
C0/163C: F0 01        BEQ $163F       ; return if an event is running
C0/163E: 60           RTS 
C0/163F: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/1642: 29 40        AND #$40
C0/1644: D0 08        BNE $164E       ; branch if forced facing direction
C0/1646: A5 C4        LDA $C4
C0/1648: 85 BF        STA $BF
C0/164A: 3A           DEC 
C0/164B: 8D DB 0A     STA $0ADB
C0/164E: A5 C4        LDA $C4         ; moving direction
C0/1650: AA           TAX 
C0/1651: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/1654: 29 40        AND #$40
C0/1656: D0 09        BNE $1661       ; branch if forced facing direction
C0/1658: AD FB 10     LDA $10FB
C0/165B: 3F 25 17 C0  AND $C01725,X   ; facing direction mask
C0/165F: F0 48        BEQ $16A9
C0/1661: A5 C4        LDA $C4
C0/1663: AA           TAX 
C0/1664: BF 20 17 C0  LDA $C01720,X   ; pointer to tile properties
C0/1668: AA           TAX 
C0/1669: BD D8 10     LDA $10D8,X     ; object at destination tile
C0/166C: F0 24        BEQ $1692       ; branch if no object at destination
C0/166E: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/1671: 29 04        AND #$04
C0/1673: F0 08        BEQ $167D       ; branch if not a bridge
C0/1675: A5 C3        LDA $C3
C0/1677: C9 01        CMP #$01
C0/1679: D0 17        BNE $1692
C0/167B: 80 0D        BRA $168A
C0/167D: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/1680: 29 04        AND #$04
C0/1682: F0 06        BEQ $168A
C0/1684: A5 C3        LDA $C3
C0/1686: C9 02        CMP #$02
C0/1688: F0 08        BEQ $1692
C0/168A: BD D8 10     LDA $10D8,X
C0/168D: 85 E4        STA $E4
C0/168F: 4C A9 16     JMP $16A9
C0/1692: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/1695: 29 04        AND #$04
C0/1697: F0 13        BEQ $16AC
C0/1699: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/169C: 29 04        AND #$04
C0/169E: D0 16        BNE $16B6
C0/16A0: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/16A3: 29 03        AND #$03
C0/16A5: 25 C3        AND $C3
C0/16A7: D0 0D        BNE $16B6
C0/16A9: 64 C4        STZ $C4
C0/16AB: 60           RTS 
C0/16AC: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/16AF: 25 C2        AND $C2
C0/16B1: D0 03        BNE $16B6
C0/16B3: 64 C4        STZ $C4
C0/16B5: 60           RTS 
C0/16B6: 60           RTS 

; [  ]

C0/16B7: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/16BA: 29 04        AND #$04
C0/16BC: F0 06        BEQ $16C4
C0/16BE: A5 C3        LDA $C3
C0/16C0: C9 01        CMP #$01
C0/16C2: D0 15        BNE $16D9
C0/16C4: AD D8 0A     LDA $0AD8
C0/16C7: 85 75        STA $75
C0/16C9: AD D9 0A     LDA $0AD9
C0/16CC: 85 76        STA $76
C0/16CE: DA           PHX 
C0/16CF: 20 BB 3C     JSR $3CBB       ; get pointer to object layout
C0/16D2: A9 00        LDA #$00
C0/16D4: 9F 00 30 7F  STA $7F3000,X
C0/16D8: FA           PLX 
C0/16D9: 60           RTS 

; [  ]

C0/16DA: A5 BA        LDA $BA
C0/16DC: AA           TAX 
C0/16DD: BF 20 17 C0  LDA $C01720,X   ; pointer to tile properties
C0/16E1: AA           TAX 
C0/16E2: BD F2 10     LDA $10F2,X     ; map tile properties byte 1
C0/16E5: 29 04        AND #$04
C0/16E7: F0 06        BEQ $16EF
C0/16E9: A5 C3        LDA $C3
C0/16EB: C9 01        CMP #$01
C0/16ED: D0 22        BNE $1711
C0/16EF: A5 BA        LDA $BA
C0/16F1: AA           TAX 
C0/16F2: AD D8 0A     LDA $0AD8
C0/16F5: 18           CLC 
C0/16F6: 7F 12 17 C0  ADC $C01712,X
C0/16FA: 85 75        STA $75
C0/16FC: AD D9 0A     LDA $0AD9
C0/16FF: 18           CLC 
C0/1700: 7F 17 17 C0  ADC $C01717,X
C0/1704: 85 76        STA $76
C0/1706: DA           PHX 
C0/1707: 20 BB 3C     JSR $3CBB       ; get pointer to object layout
C0/170A: A9 FF        LDA #$FF
C0/170C: 9F 00 30 7F  STA $7F3000,X
C0/1710: FA           PLX 
C0/1711: 60           RTS 

; none, up, right, down, left
C0/1712: 00 00 01 00 FF ; delta x
C0/1717: 00 FF 00 01 00 ; delta y
C0/171C: 02 01 04 08 ; tile movement speeds
C0/1720: 08 02 0A 0E 06 ; pointer to tile properties
C0/1725: 00 08 01 04 02
C0/172A: 00 02 04 00 03 00 00 00 01

; [ update local tiles (world map) ]

C0/1733: AD D8 0A     LDA $0AD8       ; x position
C0/1736: 85 0D        STA $0D
C0/1738: 64 0E        STZ $0E
C0/173A: AD D9 0A     LDA $0AD9       ; y position
C0/173D: 29 3F        AND #$3F
C0/173F: C2 20        REP #$20
C0/1741: EB           XBA 
C0/1742: 18           CLC 
C0/1743: 65 0D        ADC $0D
C0/1745: A8           TAY 
C0/1746: 98           TYA 
C0/1747: 38           SEC 
C0/1748: E9 00 01     SBC #$0100      ; tile above
C0/174B: 29 FF 3F     AND #$3FFF
C0/174E: AA           TAX 
C0/174F: BF 00 00 7F  LDA $7F0000,X   ; bg1 layout
C0/1753: 29 FF 00     AND #$00FF
C0/1756: 8D C0 10     STA $10C0
C0/1759: 0A           ASL 
C0/175A: 18           CLC 
C0/175B: 6D C0 10     ADC $10C0
C0/175E: AA           TAX 
C0/175F: BD 86 11     LDA $1186,X     ; tile properties
C0/1762: 8D F4 10     STA $10F4
C0/1765: 98           TYA 
C0/1766: 29 00 3F     AND #$3F00
C0/1769: 85 0D        STA $0D
C0/176B: 98           TYA 
C0/176C: 3A           DEC             ; tile to the left
C0/176D: 29 FF 00     AND #$00FF
C0/1770: 05 0D        ORA $0D
C0/1772: AA           TAX 
C0/1773: BF 00 00 7F  LDA $7F0000,X
C0/1777: 29 FF 00     AND #$00FF
C0/177A: 8D C4 10     STA $10C4
C0/177D: 0A           ASL 
C0/177E: 18           CLC 
C0/177F: 6D C4 10     ADC $10C4
C0/1782: AA           TAX 
C0/1783: BD 86 11     LDA $1186,X
C0/1786: 8D F8 10     STA $10F8
C0/1789: BB           TYX 
C0/178A: BF 00 00 7F  LDA $7F0000,X   ; current tile
C0/178E: 29 FF 00     AND #$00FF
C0/1791: 8D C6 10     STA $10C6
C0/1794: 0A           ASL 
C0/1795: 18           CLC 
C0/1796: 6D C6 10     ADC $10C6
C0/1799: AA           TAX 
C0/179A: BD 86 11     LDA $1186,X
C0/179D: 8D FA 10     STA $10FA       ; map tile properties byte 1
C0/17A0: 98           TYA 
C0/17A1: 29 00 3F     AND #$3F00
C0/17A4: 85 0D        STA $0D
C0/17A6: 98           TYA 
C0/17A7: 1A           INC             ; tile to the right
C0/17A8: 29 FF 00     AND #$00FF
C0/17AB: 05 0D        ORA $0D
C0/17AD: AA           TAX 
C0/17AE: BF 00 00 7F  LDA $7F0000,X
C0/17B2: 29 FF 00     AND #$00FF
C0/17B5: 8D C8 10     STA $10C8
C0/17B8: 0A           ASL 
C0/17B9: 18           CLC 
C0/17BA: 6D C8 10     ADC $10C8
C0/17BD: AA           TAX 
C0/17BE: BD 86 11     LDA $1186,X
C0/17C1: 8D FC 10     STA $10FC
C0/17C4: 98           TYA 
C0/17C5: 18           CLC 
C0/17C6: 69 00 01     ADC #$0100      ; tile below
C0/17C9: 29 FF 3F     AND #$3FFF
C0/17CC: AA           TAX 
C0/17CD: BF 00 00 7F  LDA $7F0000,X
C0/17D1: 29 FF 00     AND #$00FF
C0/17D4: 8D CC 10     STA $10CC
C0/17D7: 0A           ASL 
C0/17D8: 18           CLC 
C0/17D9: 6D CC 10     ADC $10CC
C0/17DC: AA           TAX 
C0/17DD: BD 86 11     LDA $1186,X
C0/17E0: 8D 00 11     STA $1100
C0/17E3: A5 06        LDA $06
C0/17E5: E2 20        SEP #$20
C0/17E7: 60           RTS 

; [ update local tiles (normal map) ]

C0/17E8: AD D8 0A     LDA $0AD8       ; x position
C0/17EB: 29 3F        AND #$3F
C0/17ED: 85 0D        STA $0D
C0/17EF: 64 0E        STZ $0E
C0/17F1: AD D9 0A     LDA $0AD9       ; y position
C0/17F4: 29 3F        AND #$3F
C0/17F6: C2 20        REP #$20
C0/17F8: EB           XBA 
C0/17F9: 4A           LSR 
C0/17FA: 4A           LSR 
C0/17FB: 05 0D        ORA $0D
C0/17FD: A8           TAY 
C0/17FE: 98           TYA 
C0/17FF: 38           SEC 
C0/1800: E9 80 00     SBC #$0080
C0/1803: 29 FF 0F     AND #$0FFF
C0/1806: 85 0D        STA $0D
C0/1808: AA           TAX 
C0/1809: BF 00 30 7F  LDA $7F3000,X
C0/180D: 8D EA 10     STA $10EA
C0/1810: BF 00 00 7F  LDA $7F0000,X
C0/1814: 8D D0 10     STA $10D0
C0/1817: 29 FF 00     AND #$00FF
C0/181A: 0A           ASL 
C0/181B: AA           TAX 
C0/181C: BD 86 11     LDA $1186,X     ; tile properties
C0/181F: 8D 04 11     STA $1104
C0/1822: 98           TYA 
C0/1823: 38           SEC 
C0/1824: E9 40 00     SBC #$0040
C0/1827: 29 C0 0F     AND #$0FC0
C0/182A: 85 0D        STA $0D
C0/182C: 98           TYA 
C0/182D: 3A           DEC 
C0/182E: 29 3F 00     AND #$003F
C0/1831: 05 0D        ORA $0D
C0/1833: AA           TAX 
C0/1834: BF 00 30 7F  LDA $7F3000,X
C0/1838: 8D D8 10     STA $10D8
C0/183B: BF 00 00 7F  LDA $7F0000,X
C0/183F: 8D BE 10     STA $10BE
C0/1842: 29 FF 00     AND #$00FF
C0/1845: 0A           ASL 
C0/1846: AA           TAX 
C0/1847: BD 86 11     LDA $1186,X
C0/184A: 8D F2 10     STA $10F2       ; map tile properties byte 1
C0/184D: 98           TYA 
C0/184E: 38           SEC 
C0/184F: E9 40 00     SBC #$0040
C0/1852: 29 FF 0F     AND #$0FFF
C0/1855: AA           TAX 
C0/1856: BF 00 30 7F  LDA $7F3000,X
C0/185A: 8D DA 10     STA $10DA
C0/185D: BF 00 00 7F  LDA $7F0000,X
C0/1861: 8D C0 10     STA $10C0
C0/1864: 29 FF 00     AND #$00FF
C0/1867: 0A           ASL 
C0/1868: AA           TAX 
C0/1869: BD 86 11     LDA $1186,X
C0/186C: 8D F4 10     STA $10F4
C0/186F: 98           TYA 
C0/1870: 38           SEC 
C0/1871: E9 40 00     SBC #$0040
C0/1874: 29 C0 0F     AND #$0FC0
C0/1877: 85 0D        STA $0D
C0/1879: 98           TYA 
C0/187A: 1A           INC 
C0/187B: 29 3F 00     AND #$003F
C0/187E: 05 0D        ORA $0D
C0/1880: AA           TAX 
C0/1881: BF 00 30 7F  LDA $7F3000,X
C0/1885: 8D DC 10     STA $10DC
C0/1888: BF 00 00 7F  LDA $7F0000,X
C0/188C: 8D C2 10     STA $10C2
C0/188F: 29 FF 00     AND #$00FF
C0/1892: 0A           ASL 
C0/1893: AA           TAX 
C0/1894: BD 86 11     LDA $1186,X
C0/1897: 8D F6 10     STA $10F6
C0/189A: 98           TYA 
C0/189B: 29 C0 0F     AND #$0FC0
C0/189E: 85 0D        STA $0D
C0/18A0: 98           TYA 
C0/18A1: 3A           DEC 
C0/18A2: 29 3F 00     AND #$003F
C0/18A5: 05 0D        ORA $0D
C0/18A7: AA           TAX 
C0/18A8: BF 00 30 7F  LDA $7F3000,X
C0/18AC: 8D DE 10     STA $10DE
C0/18AF: BF 00 00 7F  LDA $7F0000,X
C0/18B3: 8D C4 10     STA $10C4
C0/18B6: 29 FF 00     AND #$00FF
C0/18B9: 0A           ASL 
C0/18BA: AA           TAX 
C0/18BB: BD 86 11     LDA $1186,X
C0/18BE: 8D F8 10     STA $10F8
C0/18C1: 98           TYA 
C0/18C2: 29 C0 0F     AND #$0FC0
C0/18C5: 85 0D        STA $0D
C0/18C7: 98           TYA 
C0/18C8: 3A           DEC 
C0/18C9: 3A           DEC 
C0/18CA: 29 3F 00     AND #$003F
C0/18CD: 05 0D        ORA $0D
C0/18CF: AA           TAX 
C0/18D0: BF 00 30 7F  LDA $7F3000,X
C0/18D4: 8D EC 10     STA $10EC
C0/18D7: BF 00 00 7F  LDA $7F0000,X
C0/18DB: 8D D2 10     STA $10D2
C0/18DE: 29 FF 00     AND #$00FF
C0/18E1: 0A           ASL 
C0/18E2: AA           TAX 
C0/18E3: BD 86 11     LDA $1186,X
C0/18E6: 8D FC 10     STA $10FC
C0/18E9: BB           TYX             ; current tile
C0/18EA: BF 00 30 7F  LDA $7F3000,X
C0/18EE: 8D E0 10     STA $10E0
C0/18F1: BF 00 00 7F  LDA $7F0000,X
C0/18F5: 8D C6 10     STA $10C6
C0/18F8: 29 FF 00     AND #$00FF
C0/18FB: 0A           ASL 
C0/18FC: AA           TAX 
C0/18FD: BD 86 11     LDA $1186,X
C0/1900: 8D FA 10     STA $10FA       ; map tile properties byte 1
C0/1903: 98           TYA 
C0/1904: 29 C0 0F     AND #$0FC0
C0/1907: 85 0D        STA $0D
C0/1909: 98           TYA 
C0/190A: 1A           INC             ; to the right
C0/190B: 29 3F 00     AND #$003F
C0/190E: 05 0D        ORA $0D
C0/1910: AA           TAX 
C0/1911: BF 00 30 7F  LDA $7F3000,X
C0/1915: 8D E2 10     STA $10E2
C0/1918: BF 00 00 7F  LDA $7F0000,X
C0/191C: 8D C8 10     STA $10C8
C0/191F: 29 FF 00     AND #$00FF
C0/1922: 0A           ASL 
C0/1923: AA           TAX 
C0/1924: BD 86 11     LDA $1186,X
C0/1927: 8D FC 10     STA $10FC
C0/192A: 98           TYA 
C0/192B: 29 C0 0F     AND #$0FC0
C0/192E: 85 0D        STA $0D
C0/1930: 98           TYA 
C0/1931: 1A           INC             ; two tiles to the right
C0/1932: 1A           INC 
C0/1933: 29 3F 00     AND #$003F
C0/1936: 05 0D        ORA $0D
C0/1938: AA           TAX 
C0/1939: BF 00 30 7F  LDA $7F3000,X   ; object layout
C0/193D: 8D EE 10     STA $10EE
C0/1940: BF 00 00 7F  LDA $7F0000,X
C0/1944: 8D D4 10     STA $10D4
C0/1947: 29 FF 00     AND #$00FF
C0/194A: 0A           ASL 
C0/194B: AA           TAX 
C0/194C: BD 86 11     LDA $1186,X
C0/194F: 8D 08 11     STA $1108
C0/1952: 98           TYA 
C0/1953: 18           CLC 
C0/1954: 69 40 00     ADC #$0040      ; tile below and to the left
C0/1957: 29 C0 0F     AND #$0FC0
C0/195A: 85 0D        STA $0D
C0/195C: 98           TYA 
C0/195D: 3A           DEC 
C0/195E: 29 3F 00     AND #$003F
C0/1961: 05 0D        ORA $0D
C0/1963: AA           TAX 
C0/1964: BF 00 30 7F  LDA $7F3000,X
C0/1968: 8D E4 10     STA $10E4
C0/196B: BF 00 00 7F  LDA $7F0000,X
C0/196F: 8D CA 10     STA $10CA
C0/1972: 29 FF 00     AND #$00FF
C0/1975: 0A           ASL 
C0/1976: AA           TAX 
C0/1977: BD 86 11     LDA $1186,X
C0/197A: 8D FE 10     STA $10FE
C0/197D: 98           TYA 
C0/197E: 18           CLC 
C0/197F: 69 40 00     ADC #$0040      ; tile below
C0/1982: 29 FF 0F     AND #$0FFF
C0/1985: AA           TAX 
C0/1986: BF 00 30 7F  LDA $7F3000,X
C0/198A: 8D E6 10     STA $10E6
C0/198D: BF 00 00 7F  LDA $7F0000,X
C0/1991: 8D CC 10     STA $10CC
C0/1994: 29 FF 00     AND #$00FF
C0/1997: 0A           ASL 
C0/1998: AA           TAX 
C0/1999: BD 86 11     LDA $1186,X
C0/199C: 8D 00 11     STA $1100
C0/199F: 98           TYA 
C0/19A0: 18           CLC 
C0/19A1: 69 40 00     ADC #$0040      ; tile below and to the right
C0/19A4: 29 C0 0F     AND #$0FC0
C0/19A7: 85 0D        STA $0D
C0/19A9: 98           TYA 
C0/19AA: 1A           INC 
C0/19AB: 29 3F 00     AND #$003F
C0/19AE: 05 0D        ORA $0D
C0/19B0: AA           TAX 
C0/19B1: BF 00 30 7F  LDA $7F3000,X
C0/19B5: 8D E8 10     STA $10E8
C0/19B8: BF 00 00 7F  LDA $7F0000,X
C0/19BC: 8D CE 10     STA $10CE
C0/19BF: 29 FF 00     AND #$00FF
C0/19C2: 0A           ASL 
C0/19C3: AA           TAX 
C0/19C4: BD 86 11     LDA $1186,X
C0/19C7: 8D 02 11     STA $1102
C0/19CA: 98           TYA 
C0/19CB: 18           CLC 
C0/19CC: 69 80 00     ADC #$0080      ; two tiles below
C0/19CF: 29 FF 0F     AND #$0FFF
C0/19D2: AA           TAX 
C0/19D3: BF 00 30 7F  LDA $7F3000,X
C0/19D7: 8D F0 10     STA $10F0
C0/19DA: BF 00 00 7F  LDA $7F0000,X
C0/19DE: 8D D6 10     STA $10D6
C0/19E1: 29 FF 00     AND #$00FF
C0/19E4: 0A           ASL 
C0/19E5: AA           TAX 
C0/19E6: BD 86 11     LDA $1186,X
C0/19E9: 8D 0A 11     STA $110A
C0/19EC: A5 06        LDA $06
C0/19EE: E2 20        SEP #$20
C0/19F0: 60           RTS 

; [ get tile properties at current tile (unused ???) ]

C0/19F1: A5 76        LDA $76         ; y position
C0/19F3: 29 3F        AND #$3F
C0/19F5: C2 20        REP #$20
C0/19F7: EB           XBA 
C0/19F8: 4A           LSR 
C0/19F9: 4A           LSR 
C0/19FA: 85 0D        STA $0D
C0/19FC: A5 06        LDA $06
C0/19FE: E2 20        SEP #$20
C0/1A00: A5 75        LDA $75         ; x position
C0/1A02: 29 3F        AND #$3F
C0/1A04: 05 0D        ORA $0D
C0/1A06: 85 0D        STA $0D
C0/1A08: A6 0D        LDX $0D
C0/1A0A: BF 00 00 7F  LDA $7F0000,X   ; bg1 tile
C0/1A0E: 48           PHA 
C0/1A0F: C2 20        REP #$20
C0/1A11: 0A           ASL 
C0/1A12: AA           TAX 
C0/1A13: BD 86 11     LDA $1186,X     ; tile properties
C0/1A16: AA           TAX 
C0/1A17: A5 06        LDA $06
C0/1A19: E2 20        SEP #$20
C0/1A1B: 68           PLA 
C0/1A1C: 60           RTS 

; [  ]

C0/1A1D: A5 BA        LDA $BA
C0/1A1F: D0 03        BNE $1A24
C0/1A21: E6 41        INC $41
C0/1A23: 60           RTS 
C0/1A24: AD FA 0A     LDA $0AFA
C0/1A27: F0 0C        BEQ $1A35
C0/1A29: 30 05        BMI $1A30
C0/1A2B: A5 C0        LDA $C0
C0/1A2D: 0A           ASL 
C0/1A2E: 80 07        BRA $1A37
C0/1A30: A5 C0        LDA $C0
C0/1A32: 4A           LSR 
C0/1A33: 80 02        BRA $1A37
C0/1A35: A5 C0        LDA $C0
C0/1A37: 85 0F        STA $0F
C0/1A39: 64 10        STZ $10
C0/1A3B: A5 BA        LDA $BA
C0/1A3D: 3A           DEC 
C0/1A3E: D0 23        BNE $1A63
C0/1A40: A5 63        LDA $63
C0/1A42: 29 1F        AND #$1F
C0/1A44: 38           SEC 
C0/1A45: E5 0F        SBC $0F
C0/1A47: B0 07        BCS $1A50
C0/1A49: AD D9 0A     LDA $0AD9
C0/1A4C: 3A           DEC 
C0/1A4D: 8D D9 0A     STA $0AD9
C0/1A50: C2 20        REP #$20
C0/1A52: A5 63        LDA $63
C0/1A54: 38           SEC 
C0/1A55: E5 0F        SBC $0F
C0/1A57: 29 FF 0F     AND #$0FFF
C0/1A5A: 85 63        STA $63
C0/1A5C: A5 06        LDA $06
C0/1A5E: E2 20        SEP #$20
C0/1A60: 4C D3 1A     JMP $1AD3
C0/1A63: 3A           DEC 
C0/1A64: D0 25        BNE $1A8B
C0/1A66: A5 61        LDA $61
C0/1A68: 29 1F        AND #$1F
C0/1A6A: 18           CLC 
C0/1A6B: 65 0F        ADC $0F
C0/1A6D: 29 E0        AND #$E0
C0/1A6F: F0 07        BEQ $1A78
C0/1A71: AD D8 0A     LDA $0AD8
C0/1A74: 1A           INC 
C0/1A75: 8D D8 0A     STA $0AD8
C0/1A78: C2 20        REP #$20
C0/1A7A: A5 61        LDA $61
C0/1A7C: 18           CLC 
C0/1A7D: 29 FF 0F     AND #$0FFF
C0/1A80: 65 0F        ADC $0F
C0/1A82: 85 61        STA $61
C0/1A84: A5 06        LDA $06
C0/1A86: E2 20        SEP #$20
C0/1A88: 4C D3 1A     JMP $1AD3
C0/1A8B: 3A           DEC 
C0/1A8C: D0 25        BNE $1AB3
C0/1A8E: A5 63        LDA $63
C0/1A90: 29 1F        AND #$1F
C0/1A92: 18           CLC 
C0/1A93: 65 0F        ADC $0F
C0/1A95: 29 E0        AND #$E0
C0/1A97: F0 07        BEQ $1AA0
C0/1A99: AD D9 0A     LDA $0AD9
C0/1A9C: 1A           INC 
C0/1A9D: 8D D9 0A     STA $0AD9
C0/1AA0: C2 20        REP #$20
C0/1AA2: A5 63        LDA $63
C0/1AA4: 18           CLC 
C0/1AA5: 29 FF 0F     AND #$0FFF
C0/1AA8: 65 0F        ADC $0F
C0/1AAA: 85 63        STA $63
C0/1AAC: A5 06        LDA $06
C0/1AAE: E2 20        SEP #$20
C0/1AB0: 4C D3 1A     JMP $1AD3
C0/1AB3: A5 61        LDA $61
C0/1AB5: 29 1F        AND #$1F
C0/1AB7: 38           SEC 
C0/1AB8: E5 0F        SBC $0F
C0/1ABA: B0 07        BCS $1AC3
C0/1ABC: AD D8 0A     LDA $0AD8
C0/1ABF: 3A           DEC 
C0/1AC0: 8D D8 0A     STA $0AD8
C0/1AC3: C2 20        REP #$20
C0/1AC5: A5 61        LDA $61
C0/1AC7: 38           SEC 
C0/1AC8: 29 FF 0F     AND #$0FFF
C0/1ACB: E5 0F        SBC $0F
C0/1ACD: 85 61        STA $61
C0/1ACF: A5 06        LDA $06
C0/1AD1: E2 20        SEP #$20
C0/1AD3: A5 61        LDA $61
C0/1AD5: 29 1F        AND #$1F
C0/1AD7: D0 08        BNE $1AE1
C0/1AD9: A5 63        LDA $63
C0/1ADB: 29 1F        AND #$1F
C0/1ADD: D0 02        BNE $1AE1
C0/1ADF: E6 56        INC $56
C0/1AE1: E6 41        INC $41
C0/1AE3: 60           RTS 

; [  ]

C0/1AE4: A5 BE        LDA $BE
C0/1AE6: F0 0D        BEQ $1AF5
C0/1AE8: A5 BE        LDA $BE
C0/1AEA: 38           SEC 
C0/1AEB: E5 C0        SBC $C0
C0/1AED: 85 BE        STA $BE
C0/1AEF: 29 7F        AND #$7F
C0/1AF1: D0 02        BNE $1AF5
C0/1AF3: 64 BE        STZ $BE
C0/1AF5: A5 BA        LDA $BA
C0/1AF7: D0 03        BNE $1AFC
C0/1AF9: E6 41        INC $41
C0/1AFB: 60           RTS 
C0/1AFC: A5 41        LDA $41
C0/1AFE: 4A           LSR 
C0/1AFF: B0 45        BCS $1B46
C0/1B01: AD D9 0A     LDA $0AD9
C0/1B04: 85 76        STA $76
C0/1B06: AD D8 0A     LDA $0AD8
C0/1B09: 85 75        STA $75
C0/1B0B: A5 BA        LDA $BA
C0/1B0D: A6 06        LDX $06
C0/1B0F: 86 71        STX $71
C0/1B11: 20 7D 70     JSR $707D
C0/1B14: AD 21 11     LDA $1121
C0/1B17: 29 40        AND #$40
C0/1B19: D0 12        BNE $1B2D
C0/1B1B: A5 78        LDA $78
C0/1B1D: 85 76        STA $76
C0/1B1F: A5 77        LDA $77
C0/1B21: 85 75        STA $75
C0/1B23: A5 BA        LDA $BA
C0/1B25: A2 00 10     LDX #$1000
C0/1B28: 86 71        STX $71
C0/1B2A: 20 7D 70     JSR $707D
C0/1B2D: AD 21 11     LDA $1121
C0/1B30: 30 12        BMI $1B44
C0/1B32: A5 7A        LDA $7A
C0/1B34: 85 76        STA $76
C0/1B36: A5 79        LDA $79
C0/1B38: 85 75        STA $75
C0/1B3A: A5 BA        LDA $BA
C0/1B3C: A2 00 20     LDX #$2000
C0/1B3F: 86 71        STX $71
C0/1B41: 20 7D 70     JSR $707D
C0/1B44: E6 9F        INC $9F
C0/1B46: A5 BA        LDA $BA
C0/1B48: 3A           DEC 
C0/1B49: D0 5B        BNE $1BA6
C0/1B4B: A5 63        LDA $63
C0/1B4D: 29 1F        AND #$1F
C0/1B4F: 38           SEC 
C0/1B50: E5 C0        SBC $C0
C0/1B52: B0 09        BCS $1B5D
C0/1B54: AD D9 0A     LDA $0AD9
C0/1B57: 3A           DEC 
C0/1B58: 29 3F        AND #$3F
C0/1B5A: 8D D9 0A     STA $0AD9
C0/1B5D: A5 67        LDA $67
C0/1B5F: 29 1F        AND #$1F
C0/1B61: 38           SEC 
C0/1B62: ED 82 10     SBC $1082
C0/1B65: B0 09        BCS $1B70
C0/1B67: AD 78 0B     LDA $0B78
C0/1B6A: 3A           DEC 
C0/1B6B: 29 3F        AND #$3F
C0/1B6D: 8D 78 0B     STA $0B78
C0/1B70: A5 6B        LDA $6B
C0/1B72: 29 1F        AND #$1F
C0/1B74: 38           SEC 
C0/1B75: ED 86 10     SBC $1086
C0/1B78: B0 09        BCS $1B83
C0/1B7A: AD 7A 0B     LDA $0B7A
C0/1B7D: 3A           DEC 
C0/1B7E: 29 3F        AND #$3F
C0/1B80: 8D 7A 0B     STA $0B7A
C0/1B83: C2 20        REP #$20
C0/1B85: A5 63        LDA $63
C0/1B87: 38           SEC 
C0/1B88: E5 C0        SBC $C0
C0/1B8A: 29 FF 0F     AND #$0FFF
C0/1B8D: 85 63        STA $63
C0/1B8F: A5 67        LDA $67
C0/1B91: 38           SEC 
C0/1B92: ED 82 10     SBC $1082
C0/1B95: 85 67        STA $67
C0/1B97: A5 6B        LDA $6B
C0/1B99: 38           SEC 
C0/1B9A: ED 86 10     SBC $1086
C0/1B9D: 85 6B        STA $6B
C0/1B9F: A5 06        LDA $06
C0/1BA1: E2 20        SEP #$20
C0/1BA3: 4C C6 1C     JMP $1CC6
C0/1BA6: 3A           DEC 
C0/1BA7: D0 61        BNE $1C0A
C0/1BA9: A5 61        LDA $61
C0/1BAB: 29 1F        AND #$1F
C0/1BAD: 18           CLC 
C0/1BAE: 65 C0        ADC $C0
C0/1BB0: 29 E0        AND #$E0
C0/1BB2: F0 09        BEQ $1BBD
C0/1BB4: AD D8 0A     LDA $0AD8
C0/1BB7: 1A           INC 
C0/1BB8: 29 3F        AND #$3F
C0/1BBA: 8D D8 0A     STA $0AD8
C0/1BBD: A5 65        LDA $65
C0/1BBF: 29 1F        AND #$1F
C0/1BC1: 18           CLC 
C0/1BC2: 6D 80 10     ADC $1080
C0/1BC5: 29 E0        AND #$E0
C0/1BC7: F0 09        BEQ $1BD2
C0/1BC9: AD 77 0B     LDA $0B77
C0/1BCC: 1A           INC 
C0/1BCD: 29 3F        AND #$3F
C0/1BCF: 8D 77 0B     STA $0B77
C0/1BD2: A5 69        LDA $69
C0/1BD4: 29 1F        AND #$1F
C0/1BD6: 18           CLC 
C0/1BD7: 6D 84 10     ADC $1084
C0/1BDA: 29 E0        AND #$E0
C0/1BDC: F0 09        BEQ $1BE7
C0/1BDE: AD 79 0B     LDA $0B79
C0/1BE1: 1A           INC 
C0/1BE2: 29 3F        AND #$3F
C0/1BE4: 8D 79 0B     STA $0B79
C0/1BE7: C2 20        REP #$20
C0/1BE9: A5 61        LDA $61
C0/1BEB: 18           CLC 
C0/1BEC: 29 FF 0F     AND #$0FFF
C0/1BEF: 65 C0        ADC $C0
C0/1BF1: 85 61        STA $61
C0/1BF3: A5 65        LDA $65
C0/1BF5: 18           CLC 
C0/1BF6: 6D 80 10     ADC $1080
C0/1BF9: 85 65        STA $65
C0/1BFB: A5 69        LDA $69
C0/1BFD: 18           CLC 
C0/1BFE: 6D 84 10     ADC $1084
C0/1C01: 85 69        STA $69
C0/1C03: A5 06        LDA $06
C0/1C05: E2 20        SEP #$20
C0/1C07: 4C C6 1C     JMP $1CC6
C0/1C0A: 3A           DEC 
C0/1C0B: D0 61        BNE $1C6E
C0/1C0D: A5 63        LDA $63
C0/1C0F: 29 1F        AND #$1F
C0/1C11: 18           CLC 
C0/1C12: 65 C0        ADC $C0
C0/1C14: 29 E0        AND #$E0
C0/1C16: F0 09        BEQ $1C21
C0/1C18: AD D9 0A     LDA $0AD9
C0/1C1B: 1A           INC 
C0/1C1C: 29 3F        AND #$3F
C0/1C1E: 8D D9 0A     STA $0AD9
C0/1C21: A5 67        LDA $67
C0/1C23: 29 1F        AND #$1F
C0/1C25: 18           CLC 
C0/1C26: 6D 82 10     ADC $1082
C0/1C29: 29 E0        AND #$E0
C0/1C2B: F0 09        BEQ $1C36
C0/1C2D: AD 78 0B     LDA $0B78
C0/1C30: 1A           INC 
C0/1C31: 29 3F        AND #$3F
C0/1C33: 8D 78 0B     STA $0B78
C0/1C36: A5 6B        LDA $6B
C0/1C38: 29 1F        AND #$1F
C0/1C3A: 18           CLC 
C0/1C3B: 6D 86 10     ADC $1086
C0/1C3E: 29 E0        AND #$E0
C0/1C40: F0 09        BEQ $1C4B
C0/1C42: AD 7A 0B     LDA $0B7A
C0/1C45: 1A           INC 
C0/1C46: 29 3F        AND #$3F
C0/1C48: 8D 7A 0B     STA $0B7A
C0/1C4B: C2 20        REP #$20
C0/1C4D: A5 63        LDA $63
C0/1C4F: 18           CLC 
C0/1C50: 29 FF 0F     AND #$0FFF
C0/1C53: 65 C0        ADC $C0
C0/1C55: 85 63        STA $63
C0/1C57: A5 67        LDA $67
C0/1C59: 18           CLC 
C0/1C5A: 6D 82 10     ADC $1082
C0/1C5D: 85 67        STA $67
C0/1C5F: A5 6B        LDA $6B
C0/1C61: 18           CLC 
C0/1C62: 6D 86 10     ADC $1086
C0/1C65: 85 6B        STA $6B
C0/1C67: A5 06        LDA $06
C0/1C69: E2 20        SEP #$20
C0/1C6B: 4C C6 1C     JMP $1CC6
C0/1C6E: A5 61        LDA $61
C0/1C70: 29 1F        AND #$1F
C0/1C72: 38           SEC 
C0/1C73: E5 C0        SBC $C0
C0/1C75: B0 09        BCS $1C80
C0/1C77: AD D8 0A     LDA $0AD8
C0/1C7A: 3A           DEC 
C0/1C7B: 29 3F        AND #$3F
C0/1C7D: 8D D8 0A     STA $0AD8
C0/1C80: A5 65        LDA $65
C0/1C82: 29 1F        AND #$1F
C0/1C84: 38           SEC 
C0/1C85: ED 80 10     SBC $1080
C0/1C88: B0 09        BCS $1C93
C0/1C8A: AD 77 0B     LDA $0B77
C0/1C8D: 3A           DEC 
C0/1C8E: 29 3F        AND #$3F
C0/1C90: 8D 77 0B     STA $0B77
C0/1C93: A5 69        LDA $69
C0/1C95: 29 1F        AND #$1F
C0/1C97: 38           SEC 
C0/1C98: ED 84 10     SBC $1084
C0/1C9B: B0 09        BCS $1CA6
C0/1C9D: AD 79 0B     LDA $0B79
C0/1CA0: 3A           DEC 
C0/1CA1: 29 3F        AND #$3F
C0/1CA3: 8D 79 0B     STA $0B79
C0/1CA6: C2 20        REP #$20
C0/1CA8: A5 61        LDA $61
C0/1CAA: 38           SEC 
C0/1CAB: 29 FF 0F     AND #$0FFF
C0/1CAE: E5 C0        SBC $C0
C0/1CB0: 85 61        STA $61
C0/1CB2: A5 65        LDA $65
C0/1CB4: 38           SEC 
C0/1CB5: ED 80 10     SBC $1080
C0/1CB8: 85 65        STA $65
C0/1CBA: A5 69        LDA $69
C0/1CBC: 38           SEC 
C0/1CBD: ED 84 10     SBC $1084
C0/1CC0: 85 69        STA $69
C0/1CC2: A5 06        LDA $06
C0/1CC4: E2 20        SEP #$20
C0/1CC6: A5 61        LDA $61
C0/1CC8: 29 1F        AND #$1F
C0/1CCA: D0 08        BNE $1CD4
C0/1CCC: A5 63        LDA $63
C0/1CCE: 29 1F        AND #$1F
C0/1CD0: D0 02        BNE $1CD4
C0/1CD2: E6 56        INC $56
C0/1CD4: E6 41        INC $41
C0/1CD6: 60           RTS 

; [ update showing character ]

C0/1CD7: AD DA 0A     LDA $0ADA
C0/1CDA: C9 07        CMP #$07
C0/1CDC: B0 03        BCS $1CE1       ; branch if a vehicle
C0/1CDE: 20 E2 1C     JSR $1CE2       ; update party graphic
C0/1CE1: 60           RTS 

; [ update party graphic ]

C0/1CE2: A4 06        LDY $06
C0/1CE4: B9 00 05     LDA $0500,Y     ; find the front character
C0/1CE7: 29 40        AND #$40
C0/1CE9: D0 24        BNE $1D0F
C0/1CEB: B9 00 05     LDA $0500,Y     ; character id
C0/1CEE: 29 07        AND #$07
C0/1CF0: 1A           INC 
C0/1CF1: 1A           INC 
C0/1CF2: 8D DA 0A     STA $0ADA       ; party graphic
C0/1CF5: B9 1A 05     LDA $051A,Y
C0/1CF8: 29 20        AND #$20
C0/1CFA: F0 07        BEQ $1D03
C0/1CFC: A9 01        LDA #$01        ; frog graphic
C0/1CFE: 8D DA 0A     STA $0ADA
C0/1D01: 80 1A        BRA $1D1D
C0/1D03: B9 1A 05     LDA $051A,Y
C0/1D06: 29 10        AND #$10
C0/1D08: F0 13        BEQ $1D1D
C0/1D0A: 9C DA 0A     STZ $0ADA       ; tiny graphic
C0/1D0D: 80 0E        BRA $1D1D
C0/1D0F: C2 20        REP #$20        ; next character
C0/1D11: 98           TYA 
C0/1D12: 18           CLC 
C0/1D13: 69 50 00     ADC #$0050
C0/1D16: A8           TAY 
C0/1D17: A5 06        LDA $06
C0/1D19: E2 20        SEP #$20
C0/1D1B: 80 C7        BRA $1CE4
C0/1D1D: 60           RTS 

; [ copy party sprite graphics to vram ]

C0/1D1E: AD DA 0A     LDA $0ADA       ; party graphic
C0/1D21: C9 09        CMP #$09
C0/1D23: 90 03        BCC $1D28
C0/1D25: 4C C3 1D     JMP $1DC3       ; vehicle graphic

; normal graphic
C0/1D28: A9 80        LDA #$80
C0/1D2A: 8D 15 21     STA $2115
C0/1D2D: 9C 0B 42     STZ $420B
C0/1D30: A9 01        LDA #$01
C0/1D32: 8D 00 43     STA $4300
C0/1D35: A9 18        LDA #$18
C0/1D37: 8D 01 43     STA $4301
C0/1D3A: A9 DA        LDA #$DA
C0/1D3C: 8D 04 43     STA $4304
C0/1D3F: A5 57        LDA $57
C0/1D41: D0 39        BNE $1D7C
C0/1D43: AD DA 0A     LDA $0ADA
C0/1D46: 38           SEC 
C0/1D47: E9 02        SBC #$02
C0/1D49: 30 31        BMI $1D7C       ; branch if tiny or frog
C0/1D4B: C9 05        CMP #$05
C0/1D4D: B0 2D        BCS $1D7C       ; branch if chocobo or moogle
C0/1D4F: A4 06        LDY $06
C0/1D51: B9 00 05     LDA $0500,Y
C0/1D54: 29 40        AND #$40
C0/1D56: F0 0E        BEQ $1D66
C0/1D58: C2 20        REP #$20
C0/1D5A: 98           TYA 
C0/1D5B: 18           CLC 
C0/1D5C: 69 50 00     ADC #$0050
C0/1D5F: A8           TAY 
C0/1D60: A5 06        LDA $06
C0/1D62: E2 20        SEP #$20
C0/1D64: 80 EB        BRA $1D51
C0/1D66: B9 1A 05     LDA $051A,Y
C0/1D69: 29 20        AND #$20
C0/1D6B: F0 04        BEQ $1D71
C0/1D6D: A9 01        LDA #$01
C0/1D6F: 80 0E        BRA $1D7F
C0/1D71: B9 1A 05     LDA $051A,Y
C0/1D74: 29 10        AND #$10
C0/1D76: F0 04        BEQ $1D7C
C0/1D78: A9 00        LDA #$00
C0/1D7A: 80 03        BRA $1D7F

; tiny, frog, chocobo, or moogle
C0/1D7C: AD DA 0A     LDA $0ADA
C0/1D7F: 0A           ASL 
C0/1D80: AA           TAX 
C0/1D81: C2 20        REP #$20
C0/1D83: BF 02 1E C0  LDA $C01E02,X
C0/1D87: 8D 02 43     STA $4302
C0/1D8A: A9 00 60     LDA #$6000
C0/1D8D: 8D 16 21     STA $2116
C0/1D90: A5 53        LDA $53
C0/1D92: D0 05        BNE $1D99
C0/1D94: A9 00 02     LDA #$0200
C0/1D97: 80 03        BRA $1D9C
C0/1D99: A9 00 08     LDA #$0800
C0/1D9C: 8D 05 43     STA $4305
C0/1D9F: A5 06        LDA $06
C0/1DA1: E2 20        SEP #$20
C0/1DA3: A9 01        LDA #$01
C0/1DA5: 8D 0B 42     STA $420B
C0/1DA8: A5 53        LDA $53
C0/1DAA: D0 16        BNE $1DC2
C0/1DAC: A2 00 61     LDX #$6100
C0/1DAF: 86 2E        STX $2E
C0/1DB1: A2 00 02     LDX #$0200
C0/1DB4: 86 2C        STX $2C
C0/1DB6: A2 00 6C     LDX #$6C00      ; DA/6C00 (chocobo sprite graphics)
C0/1DB9: 86 23        STX $23
C0/1DBB: A9 DA        LDA #$DA
C0/1DBD: 85 25        STA $25
C0/1DBF: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/1DC2: 60           RTS 

; vehicle
C0/1DC3: 48           PHA 
C0/1DC4: C9 0A        CMP #$0A
C0/1DC6: B0 12        BCS $1DDA
C0/1DC8: A6 06        LDX $06
C0/1DCA: BF 40 FF DF  LDA $DFFF40,X   ; copy color palette
C0/1DCE: 9D 00 0D     STA $0D00,X
C0/1DD1: 9D 80 0D     STA $0D80,X
C0/1DD4: E8           INX 
C0/1DD5: E0 10 00     CPX #$0010
C0/1DD8: D0 F0        BNE $1DCA
C0/1DDA: 68           PLA 
C0/1DDB: 38           SEC 
C0/1DDC: E9 09        SBC #$09
C0/1DDE: 0A           ASL 
C0/1DDF: AA           TAX 
C0/1DE0: C2 20        REP #$20
C0/1DE2: BF FA 1D C0  LDA $C01DFA,X
C0/1DE6: 85 30        STA $30
C0/1DE8: A9 00 60     LDA #$6000
C0/1DEB: 85 33        STA $33
C0/1DED: A9 18 00     LDA #$0018
C0/1DF0: 85 35        STA $35
C0/1DF2: A5 06        LDA $06
C0/1DF4: E2 20        SEP #$20
C0/1DF6: 20 D5 4A     JSR $4AD5       ; copy 3bpp graphics to vram
C0/1DF9: 60           RTS 

; pointers to vehicle graphics (+$DB0000)
C0/1DFA:              .DW $3B80, $4240, $3A00, $3A60

; pointers to party sprite graphics (+$DA0000)
C0/1E02:              .DW $C800, $D000, $D800, $E000, $E800, $F000, $F800, $6C00, $8400

; [ copy alt. sprite graphics to vram ]

C0/1E14: A5 A4        LDA $A4
C0/1E16: F0 41        BEQ $1E59
C0/1E18: 3A           DEC 
C0/1E19: 0A           ASL 
C0/1E1A: AA           TAX 
C0/1E1B: C2 20        REP #$20
C0/1E1D: BF 5A 1E C0  LDA $C01E5A,X   ; pointer to graphics
C0/1E21: 8D 02 43     STA $4302
C0/1E24: A5 06        LDA $06
C0/1E26: E2 20        SEP #$20
C0/1E28: A5 53        LDA $53
C0/1E2A: D0 05        BNE $1E31
C0/1E2C: A2 00 73     LDX #$7300      ; vram address = $7300 (normal map)
C0/1E2F: 80 03        BRA $1E34
C0/1E31: A2 00 61     LDX #$6100      ; vram address = $6100 (world map)
C0/1E34: 8E 16 21     STX $2116
C0/1E37: A9 80        LDA #$80
C0/1E39: 8D 15 21     STA $2115
C0/1E3C: 9C 0B 42     STZ $420B
C0/1E3F: A9 01        LDA #$01
C0/1E41: 8D 00 43     STA $4300
C0/1E44: A9 18        LDA #$18
C0/1E46: 8D 01 43     STA $4301
C0/1E49: A2 00 08     LDX #$0800
C0/1E4C: 8E 05 43     STX $4305
C0/1E4F: A9 DB        LDA #$DB
C0/1E51: 8D 04 43     STA $4304
C0/1E54: A9 01        LDA #$01
C0/1E56: 8D 0B 42     STA $420B
C0/1E59: 60           RTS 

; pointer to alt. party sprite graphics (+DB0000)
C0/1E5A:              .DW $4D80, $5D80, $6580, $6180, $6180

C0/1E64: A5 BD        LDA $BD
C0/1E66: F0 4C        BEQ $1EB4
C0/1E68: AD DC 0A     LDA $0ADC
C0/1E6B: F0 47        BEQ $1EB4
C0/1E6D: 3A           DEC 
C0/1E6E: 0A           ASL 
C0/1E6F: 0A           ASL 
C0/1E70: A8           TAY 
C0/1E71: B9 DD 0A     LDA $0ADD,Y
C0/1E74: 29 1C        AND #$1C
C0/1E76: 4A           LSR 
C0/1E77: 4A           LSR 
C0/1E78: C9 02        CMP #$02
C0/1E7A: F0 0C        BEQ $1E88
C0/1E7C: C9 03        CMP #$03
C0/1E7E: F0 08        BEQ $1E88
C0/1E80: C9 04        CMP #$04
C0/1E82: F0 04        BEQ $1E88
C0/1E84: C9 06        CMP #$06
C0/1E86: D0 2C        BNE $1EB4
C0/1E88: B9 DE 0A     LDA $0ADE,Y
C0/1E8B: 29 7C        AND #$7C
C0/1E8D: 4A           LSR 
C0/1E8E: AA           TAX 
C0/1E8F: C2 20        REP #$20
C0/1E91: BF B5 1E C0  LDA $C01EB5,X
C0/1E95: 85 11        STA $11
C0/1E97: A9 70 75     LDA #$7570
C0/1E9A: 8D F8 02     STA $02F8
C0/1E9D: A5 11        LDA $11
C0/1E9F: 8D FA 02     STA $02FA
C0/1EA2: A9 78 75     LDA #$7578
C0/1EA5: 8D FC 02     STA $02FC
C0/1EA8: A5 11        LDA $11
C0/1EAA: 49 00 40     EOR #$4000
C0/1EAD: 8D FE 02     STA $02FE
C0/1EB0: A5 06        LDA $06
C0/1EB2: E2 20        SEP #$20
C0/1EB4: 60           RTS 

C0/1EB5: 3044 3044 3045 3045 3045 3046 3046 3046

; [  ]

C0/1EC5: A4 06        LDY $06
C0/1EC7: 84 23        STY $23
C0/1EC9: A4 23        LDY $23
C0/1ECB: A5 6F        LDA $6F
C0/1ECD: F0 03        BEQ $1ED2
C0/1ECF: 4C 48 1F     JMP $1F48
C0/1ED2: B9 DE 0A     LDA $0ADE,Y
C0/1ED5: 10 03        BPL $1EDA
C0/1ED7: 4C 48 1F     JMP $1F48
C0/1EDA: B9 DD 0A     LDA $0ADD,Y
C0/1EDD: 4A           LSR 
C0/1EDE: 4A           LSR 
C0/1EDF: 4A           LSR 
C0/1EE0: 4A           LSR 
C0/1EE1: 4A           LSR 
C0/1EE2: CD D6 0A     CMP $0AD6       ; map index
C0/1EE5: F0 03        BEQ $1EEA
C0/1EE7: 4C 48 1F     JMP $1F48
C0/1EEA: B9 DF 0A     LDA $0ADF,Y
C0/1EED: 18           CLC 
C0/1EEE: 6F 5F 20 C0  ADC $C0205F
C0/1EF2: 38           SEC 
C0/1EF3: ED D8 0A     SBC $0AD8
C0/1EF6: CF 60 20 C0  CMP $C02060
C0/1EFA: B0 4C        BCS $1F48
C0/1EFC: 20 1F 20     JSR $201F
C0/1EFF: A5 14        LDA $14
C0/1F01: 4A           LSR 
C0/1F02: B0 44        BCS $1F48
C0/1F04: B9 E0 0A     LDA $0AE0,Y
C0/1F07: 18           CLC 
C0/1F08: 6F 61 20 C0  ADC $C02061
C0/1F0C: 38           SEC 
C0/1F0D: ED D9 0A     SBC $0AD9
C0/1F10: CF 62 20 C0  CMP $C02062
C0/1F14: B0 32        BCS $1F48
C0/1F16: 20 3F 20     JSR $203F
C0/1F19: A4 23        LDY $23
C0/1F1B: B9 DD 0A     LDA $0ADD,Y
C0/1F1E: 29 03        AND #$03
C0/1F20: 18           CLC 
C0/1F21: 65 23        ADC $23
C0/1F23: 18           CLC 
C0/1F24: 69 04        ADC #$04
C0/1F26: 0A           ASL 
C0/1F27: AA           TAX 
C0/1F28: C2 20        REP #$20
C0/1F2A: BF 63 20 C0  LDA $C02063,X
C0/1F2E: 85 11        STA $11
C0/1F30: A5 06        LDA $06
C0/1F32: E2 20        SEP #$20
C0/1F34: A9 60        LDA #$60
C0/1F36: AA           TAX 
C0/1F37: B9 DD 0A     LDA $0ADD,Y
C0/1F3A: 29 1C        AND #$1C
C0/1F3C: C9 08        CMP #$08
C0/1F3E: B0 05        BCS $1F45
C0/1F40: 20 B4 1F     JSR $1FB4
C0/1F43: 80 03        BRA $1F48
C0/1F45: 20 57 1F     JSR $1F57
C0/1F48: A5 23        LDA $23
C0/1F4A: 18           CLC 
C0/1F4B: 69 04        ADC #$04
C0/1F4D: 85 23        STA $23
C0/1F4F: C9 18        CMP #$18
C0/1F51: F0 03        BEQ $1F56
C0/1F53: 4C C9 1E     JMP $1EC9
C0/1F56: 60           RTS 

; [  ]

C0/1F57: A5 23        LDA $23
C0/1F59: 0A           ASL 
C0/1F5A: 0A           ASL 
C0/1F5B: A8           TAY 
C0/1F5C: A9 04        LDA #$04
C0/1F5E: 85 09        STA $09
C0/1F60: A5 13        LDA $13
C0/1F62: 18           CLC 
C0/1F63: 7F B7 20 C0  ADC $C020B7,X
C0/1F67: 38           SEC 
C0/1F68: ED A0 10     SBC $10A0
C0/1F6B: 99 98 02     STA $0298,Y
C0/1F6E: A5 15        LDA $15
C0/1F70: 18           CLC 
C0/1F71: 7F B8 20 C0  ADC $C020B8,X
C0/1F75: 38           SEC 
C0/1F76: ED A2 10     SBC $10A2
C0/1F79: 99 99 02     STA $0299,Y
C0/1F7C: C2 20        REP #$20
C0/1F7E: BF B9 20 C0  LDA $C020B9,X
C0/1F82: 18           CLC 
C0/1F83: 65 11        ADC $11
C0/1F85: 99 9A 02     STA $029A,Y
C0/1F88: A5 06        LDA $06
C0/1F8A: E2 20        SEP #$20
C0/1F8C: E8           INX 
C0/1F8D: E8           INX 
C0/1F8E: E8           INX 
C0/1F8F: E8           INX 
C0/1F90: C8           INY 
C0/1F91: C8           INY 
C0/1F92: C8           INY 
C0/1F93: C8           INY 
C0/1F94: C6 09        DEC $09
C0/1F96: D0 C8        BNE $1F60
C0/1F98: A6 23        LDX $23
C0/1F9A: BD DD 0A     LDA $0ADD,X
C0/1F9D: 29 1C        AND #$1C
C0/1F9F: C9 08        CMP #$08
C0/1FA1: D0 10        BNE $1FB3
C0/1FA3: B9 97 02     LDA $0297,Y
C0/1FA6: 29 0F        AND #$0F
C0/1FA8: 99 97 02     STA $0297,Y
C0/1FAB: B9 93 02     LDA $0293,Y
C0/1FAE: 29 0F        AND #$0F
C0/1FB0: 99 93 02     STA $0293,Y
C0/1FB3: 60           RTS 

; [  ]

C0/1FB4: A5 23        LDA $23
C0/1FB6: 0A           ASL 
C0/1FB7: 0A           ASL 
C0/1FB8: A8           TAY 
C0/1FB9: A9 04        LDA #$04
C0/1FBB: 85 09        STA $09
C0/1FBD: A5 13        LDA $13
C0/1FBF: 18           CLC 
C0/1FC0: 7F 95 2A C0  ADC $C02A95,X
C0/1FC4: 38           SEC 
C0/1FC5: E9 08        SBC #$08
C0/1FC7: 38           SEC 
C0/1FC8: ED A0 10     SBC $10A0
C0/1FCB: 99 98 02     STA $0298,Y
C0/1FCE: A5 15        LDA $15
C0/1FD0: 18           CLC 
C0/1FD1: 7F 96 2A C0  ADC $C02A96,X
C0/1FD5: 38           SEC 
C0/1FD6: E9 07        SBC #$07
C0/1FD8: 38           SEC 
C0/1FD9: ED A2 10     SBC $10A2
C0/1FDC: 99 99 02     STA $0299,Y
C0/1FDF: C2 20        REP #$20
C0/1FE1: BF 97 2A C0  LDA $C02A97,X
C0/1FE5: 18           CLC 
C0/1FE6: 65 11        ADC $11
C0/1FE8: 09 00 30     ORA #$3000
C0/1FEB: 99 9A 02     STA $029A,Y
C0/1FEE: A5 06        LDA $06
C0/1FF0: E2 20        SEP #$20
C0/1FF2: E8           INX 
C0/1FF3: E8           INX 
C0/1FF4: E8           INX 
C0/1FF5: E8           INX 
C0/1FF6: C8           INY 
C0/1FF7: C8           INY 
C0/1FF8: C8           INY 
C0/1FF9: C8           INY 
C0/1FFA: C6 09        DEC $09
C0/1FFC: D0 BF        BNE $1FBD
C0/1FFE: 60           RTS 

; [  ]

C0/1FFF: A5 13        LDA $13
C0/2001: 8D 84 02     STA $0284
C0/2004: 38           SEC 
C0/2005: E9 08        SBC #$08
C0/2007: 8D 80 02     STA $0280
C0/200A: A5 15        LDA $15
C0/200C: 38           SEC 
C0/200D: E9 03        SBC #$03
C0/200F: 8D 81 02     STA $0281
C0/2012: 8D 85 02     STA $0285
C0/2015: A2 38 00     LDX #$0038
C0/2018: 8E 82 02     STX $0282
C0/201B: 8E 86 02     STX $0286
C0/201E: 60           RTS 

; [  ]

C0/201F: C2 20        REP #$20
C0/2021: 0A           ASL 
C0/2022: 0A           ASL 
C0/2023: 0A           ASL 
C0/2024: 0A           ASL 
C0/2025: 18           CLC 
C0/2026: 69 08 00     ADC #$0008
C0/2029: 85 0D        STA $0D
C0/202B: A5 61        LDA $61
C0/202D: 29 1F 00     AND #$001F
C0/2030: 4A           LSR 
C0/2031: 85 0F        STA $0F
C0/2033: A5 0D        LDA $0D
C0/2035: 38           SEC 
C0/2036: E5 0F        SBC $0F
C0/2038: 85 13        STA $13
C0/203A: A5 06        LDA $06
C0/203C: E2 20        SEP #$20
C0/203E: 60           RTS 

; [  ]

C0/203F: C2 20        REP #$20
C0/2041: 0A           ASL 
C0/2042: 0A           ASL 
C0/2043: 0A           ASL 
C0/2044: 0A           ASL 
C0/2045: 18           CLC 
C0/2046: 69 08 00     ADC #$0008
C0/2049: 85 0D        STA $0D
C0/204B: A5 63        LDA $63
C0/204D: 29 1F 00     AND #$001F
C0/2050: 4A           LSR 
C0/2051: 85 0F        STA $0F
C0/2053: A5 0D        LDA $0D
C0/2055: 38           SEC 
C0/2056: E5 0F        SBC $0F
C0/2058: 85 15        STA $15
C0/205A: A5 06        LDA $06
C0/205C: E2 20        SEP #$20
C0/205E: 60           RTS 

C0/205F: 07 11 07 0F

C0/2063: 0000 0000 0000 0000 0010 0000 0000 0000
C0/2073: 0020 0000 0000 0000 046C 0000 0000 0000
C0/2083: 06CC 06B4 06CC 06B4 0654 0684 0000 0000
C0/2093: 069C 0654 06CC 06B4 0000 0000 0000 0000
C0/20A3: 0008 0000 0008 0000 0020 0000 1020 0000
C0/20B3: 2002 0000

C0/20B7: F8 F5 08 30
         00 F5 09 30
         F8 FD 0A 30
         00 FD 0B 30

C0/20c7: F8 F5 0C 30
         00 F5 0D 30
         F8 FD 0E 30
         00 FD 0F 30
         
C0/20D7: F8 F5 11 70
         00 F5 10 70
         F8 FD 13 70
         00 FD 12 70
         
C0/20E7: F8 F5 15 70
         00 F5 14 70
         F8 FD 17 70
         00 FD 16 70
         
C0/20F7: F8 F5 00 30
         00 F5 01 30
         F8 FD 02 30
         00 FD 03 30
         
C0/2107: F8 F5 04 30
         00 F5 05 30
         F8 FD 06 30
         00 FD 07 30
         
C0/2117: F8 F5 10 30
         00 F5 11 30
         F8 FD 12 30
         00 FD 13 30

C0/2127: F8 F5 14 30
         00 F5 15 30
         F8 FD 16 30
         00 FD 17 30

; [  ]

C0/2137: A5 BD        LDA $BD
C0/2139: D0 01        BNE $213C       ; branch if party sprite is visible
C0/213B: 60           RTS 
C0/213C: A5 BE        LDA $BE
C0/213E: 10 03        BPL $2143
C0/2140: 29 7F        AND #$7F
C0/2142: 4A           LSR 
C0/2143: AA           TAX 
C0/2144: BF DB 22 C0  LDA $C022DB,X
C0/2148: 85 0D        STA $0D
C0/214A: AD DC 0A     LDA $0ADC
C0/214D: 3A           DEC 
C0/214E: 0A           ASL 
C0/214F: 0A           ASL 
C0/2150: A8           TAY 
C0/2151: A5 61        LDA $61
C0/2153: 18           CLC 
C0/2154: 65 63        ADC $63
C0/2156: 4A           LSR 
C0/2157: 4A           LSR 
C0/2158: 4A           LSR 
C0/2159: 4A           LSR 
C0/215A: 29 01        AND #$01
C0/215C: 85 08        STA $08
C0/215E: AD DB 0A     LDA $0ADB
C0/2161: 0A           ASL 
C0/2162: 18           CLC 
C0/2163: 65 08        ADC $08
C0/2165: 85 08        STA $08
C0/2167: AD DA 0A     LDA $0ADA
C0/216A: C9 07        CMP #$07
C0/216C: F0 04        BEQ $2172
C0/216E: C9 08        CMP #$08
C0/2170: D0 07        BNE $2179

; chocobo or moogle
C0/2172: A5 08        LDA $08
C0/2174: 18           CLC 
C0/2175: 69 40        ADC #$40
C0/2177: 85 08        STA $08
C0/2179: A5 08        LDA $08
C0/217B: C2 20        REP #$20
C0/217D: 0A           ASL 
C0/217E: 0A           ASL 
C0/217F: 0A           ASL 
C0/2180: 0A           ASL 
C0/2181: AA           TAX 
C0/2182: A5 06        LDA $06
C0/2184: E2 20        SEP #$20
C0/2186: AD DC 0A     LDA $0ADC
C0/2189: C9 02        CMP #$02
C0/218B: 90 03        BCC $2190
C0/218D: 4C 46 22     JMP $2246
C0/2190: 64 11        STZ $11
C0/2192: C9 00        CMP #$00
C0/2194: F0 14        BEQ $21AA
C0/2196: A9 10        LDA #$10
C0/2198: 85 11        STA $11
C0/219A: C2 20        REP #$20
C0/219C: 8A           TXA 
C0/219D: 18           CLC 
C0/219E: 69 00 04     ADC #$0400
C0/21A1: AA           TAX 
C0/21A2: A5 06        LDA $06
C0/21A4: E2 20        SEP #$20
C0/21A6: A9 70        LDA #$70
C0/21A8: 80 0B        BRA $21B5
C0/21AA: A5 61        LDA $61
C0/21AC: 4A           LSR 
C0/21AD: 4A           LSR 
C0/21AE: 4A           LSR 
C0/21AF: 4A           LSR 
C0/21B0: 1A           INC 
C0/21B1: 29 01        AND #$01
C0/21B3: 09 70        ORA #$70
C0/21B5: 85 15        STA $15
C0/21B7: A5 0D        LDA $0D
C0/21B9: D0 06        BNE $21C1
C0/21BB: A5 CA        LDA $CA
C0/21BD: 29 60        AND #$60
C0/21BF: D0 08        BNE $21C9
C0/21C1: A9 30        LDA #$30
C0/21C3: 85 08        STA $08
C0/21C5: 85 09        STA $09
C0/21C7: 80 18        BRA $21E1
C0/21C9: A5 CA        LDA $CA
C0/21CB: 29 20        AND #$20
C0/21CD: F0 0A        BEQ $21D9
C0/21CF: A9 30        LDA #$30
C0/21D1: 85 08        STA $08
C0/21D3: A9 00        LDA #$00
C0/21D5: 85 09        STA $09
C0/21D7: 80 08        BRA $21E1
C0/21D9: A9 30        LDA #$30
C0/21DB: 85 08        STA $08
C0/21DD: A9 38        LDA #$38
C0/21DF: 85 09        STA $09
C0/21E1: A0 88 00     LDY #$0088
C0/21E4: DA           PHX 
C0/21E5: 5A           PHY 
C0/21E6: A9 04        LDA #$04
C0/21E8: 85 0A        STA $0A
C0/21EA: BF 95 2A C0  LDA $C02A95,X
C0/21EE: 18           CLC 
C0/21EF: 69 70        ADC #$70
C0/21F1: 38           SEC 
C0/21F2: ED A0 10     SBC $10A0
C0/21F5: 99 00 02     STA $0200,Y
C0/21F8: BF 96 2A C0  LDA $C02A96,X
C0/21FC: 18           CLC 
C0/21FD: 65 15        ADC $15
C0/21FF: 38           SEC 
C0/2200: ED A2 10     SBC $10A2
C0/2203: 38           SEC 
C0/2204: E5 0D        SBC $0D
C0/2206: 99 01 02     STA $0201,Y
C0/2209: BF 97 2A C0  LDA $C02A97,X
C0/220D: 18           CLC 
C0/220E: 65 11        ADC $11
C0/2210: 99 02 02     STA $0202,Y
C0/2213: E8           INX 
C0/2214: E8           INX 
C0/2215: E8           INX 
C0/2216: E8           INX 
C0/2217: C8           INY 
C0/2218: C8           INY 
C0/2219: C8           INY 
C0/221A: C8           INY 
C0/221B: C6 0A        DEC $0A
C0/221D: D0 CB        BNE $21EA
C0/221F: 7A           PLY 
C0/2220: FA           PLX 
C0/2221: BF 98 2A C0  LDA $C02A98,X
C0/2225: 05 08        ORA $08
C0/2227: 99 03 02     STA $0203,Y
C0/222A: BF 9C 2A C0  LDA $C02A9C,X
C0/222E: 05 08        ORA $08
C0/2230: 99 07 02     STA $0207,Y
C0/2233: BF A0 2A C0  LDA $C02AA0,X
C0/2237: 05 09        ORA $09
C0/2239: 99 0B 02     STA $020B,Y
C0/223C: BF A4 2A C0  LDA $C02AA4,X
C0/2240: 05 09        ORA $09
C0/2242: 99 0F 02     STA $020F,Y
C0/2245: 60           RTS 
C0/2246: B9 DE 0A     LDA $0ADE,Y
C0/2249: 29 7F        AND #$7F
C0/224B: 85 15        STA $15
C0/224D: A9 78        LDA #$78
C0/224F: 38           SEC 
C0/2250: E5 15        SBC $15
C0/2252: 85 15        STA $15
C0/2254: AD DC 0A     LDA $0ADC
C0/2257: 0A           ASL 
C0/2258: 0A           ASL 
C0/2259: 85 09        STA $09
C0/225B: B9 DD 0A     LDA $0ADD,Y
C0/225E: 29 03        AND #$03
C0/2260: 18           CLC 
C0/2261: 65 09        ADC $09
C0/2263: 0A           ASL 
C0/2264: AA           TAX 
C0/2265: C2 20        REP #$20
C0/2267: BF 63 20 C0  LDA $C02063,X
C0/226B: 85 11        STA $11
C0/226D: A5 06        LDA $06
C0/226F: E2 20        SEP #$20
C0/2271: AD DC 0A     LDA $0ADC
C0/2274: 0A           ASL 
C0/2275: 0A           ASL 
C0/2276: 85 09        STA $09
C0/2278: B9 DD 0A     LDA $0ADD,Y
C0/227B: 29 03        AND #$03
C0/227D: 05 09        ORA $09
C0/227F: AA           TAX 
C0/2280: A5 3E        LDA $3E
C0/2282: 3F 9B 20 C0  AND $C0209B,X
C0/2286: F0 02        BEQ $228A
C0/2288: A9 10        LDA #$10
C0/228A: 85 08        STA $08
C0/228C: AD DB 0A     LDA $0ADB
C0/228F: 0A           ASL 
C0/2290: 0A           ASL 
C0/2291: 0A           ASL 
C0/2292: 0A           ASL 
C0/2293: 0A           ASL 
C0/2294: 18           CLC 
C0/2295: 65 08        ADC $08
C0/2297: AA           TAX 
C0/2298: A0 88 00     LDY #$0088
C0/229B: A9 04        LDA #$04
C0/229D: 85 0A        STA $0A
C0/229F: BF B7 20 C0  LDA $C020B7,X
C0/22A3: 18           CLC 
C0/22A4: 69 78        ADC #$78
C0/22A6: 38           SEC 
C0/22A7: ED A0 10     SBC $10A0
C0/22AA: 99 00 02     STA $0200,Y
C0/22AD: BF B8 20 C0  LDA $C020B8,X
C0/22B1: 18           CLC 
C0/22B2: 65 15        ADC $15
C0/22B4: 38           SEC 
C0/22B5: ED A2 10     SBC $10A2
C0/22B8: 38           SEC 
C0/22B9: E5 0D        SBC $0D
C0/22BB: 99 01 02     STA $0201,Y
C0/22BE: C2 20        REP #$20
C0/22C0: BF B9 20 C0  LDA $C020B9,X
C0/22C4: 18           CLC 
C0/22C5: 65 11        ADC $11
C0/22C7: 99 02 02     STA $0202,Y
C0/22CA: A5 06        LDA $06
C0/22CC: E2 20        SEP #$20
C0/22CE: E8           INX 
C0/22CF: E8           INX 
C0/22D0: E8           INX 
C0/22D1: E8           INX 
C0/22D2: C8           INY 
C0/22D3: C8           INY 
C0/22D4: C8           INY 
C0/22D5: C8           INY 
C0/22D6: C6 0A        DEC $0A
C0/22D8: D0 C5        BNE $229F
C0/22DA: 60           RTS 

C0/22DB: 00 01 03 04 05 06 07 08 09 0A 0A 0B 0B 0C 0C 0C
C0/22EB: 0C 0C 0C 0B 0B 0A 0A 09 08 07 06 05 04 03 01 00

C0/22FB: 64 3E        STZ $3E
C0/22FD: 20 41 4E     JSR $4E41
C0/2300: 20 95 4C     JSR $4C95
C0/2303: 20 F7 47     JSR $47F7
C0/2306: A5 3E        LDA $3E
C0/2308: 29 18        AND #$18
C0/230A: 4A           LSR 
C0/230B: 4A           LSR 
C0/230C: 18           CLC 
C0/230D: 6D 9B 16     ADC $169B
C0/2310: AA           TAX 
C0/2311: C2 20        REP #$20
C0/2313: A9 70 6D     LDA #$6D70
C0/2316: 8D 88 02     STA $0288
C0/2319: A9 78 6D     LDA #$6D78
C0/231C: 8D 8C 02     STA $028C
C0/231F: A9 70 75     LDA #$7570
C0/2322: 8D 90 02     STA $0290
C0/2325: A9 78 75     LDA #$7578
C0/2328: 8D 94 02     STA $0294
C0/232B: BF 4C 23 C0  LDA $C0234C,X
C0/232F: 8D 8A 02     STA $028A
C0/2332: 1A           INC 
C0/2333: 8D 8E 02     STA $028E
C0/2336: 1A           INC 
C0/2337: 8D 92 02     STA $0292
C0/233A: 1A           INC 
C0/233B: 8D 96 02     STA $0296
C0/233E: A5 06        LDA $06
C0/2340: E2 20        SEP #$20
C0/2342: 20 C5 1E     JSR $1EC5
C0/2345: A5 3E        LDA $3E
C0/2347: C9 1F        CMP #$1F
C0/2349: D0 B2        BNE $22FD
C0/234B: 60           RTS 

C0/234C: 36E4 36E8 36EC 36F0 36F0 36EC 36E8 36E4
C0/235C: 36F4 36F8 36FC 3700 3700 36FC 36F8 36F4
C0/236C: 3704 3708 370C 3710 3710 370C 3708 3704

; [ update party sprite ]

C0/237C: A5 BD        LDA $BD         ; return if party sprite is not shown
C0/237E: D0 01        BNE $2381
C0/2380: 60           RTS 
C0/2381: A5 CB        LDA $CB         ; return if party sprite is hidden (z-level)
C0/2383: F0 01        BEQ $2386
C0/2385: 60           RTS 
C0/2386: A5 BE        LDA $BE         ; jump counter
C0/2388: 10 03        BPL $238D
C0/238A: 29 7F        AND #$7F
C0/238C: 4A           LSR 
C0/238D: AA           TAX 
C0/238E: BF DB 22 C0  LDA $C022DB,X
C0/2392: 85 0D        STA $0D
C0/2394: AD FB 10     LDA $10FB       ; map tile properties byte 2
C0/2397: 10 0A        BPL $23A3       ; branch if not auto-move tile
C0/2399: A2 40 02     LDX #$0240      ; pointer to sprite frame data ???
C0/239C: A5 C6        LDA $C6
C0/239E: 85 15        STA $15
C0/23A0: 4C 1D 24     JMP $241D
C0/23A3: A5 BC        LDA $BC
C0/23A5: F0 37        BEQ $23DE
C0/23A7: A5 57        LDA $57
C0/23A9: F0 04        BEQ $23AF
C0/23AB: A5 BA        LDA $BA
C0/23AD: F0 2F        BEQ $23DE
C0/23AF: AD DA 0A     LDA $0ADA
C0/23B2: C9 0A        CMP #$0A
C0/23B4: D0 10        BNE $23C6
C0/23B6: A5 C6        LDA $C6
C0/23B8: 85 15        STA $15
C0/23BA: A5 3F        LDA $3F
C0/23BC: 29 02        AND #$02
C0/23BE: 4A           LSR 
C0/23BF: 18           CLC 
C0/23C0: 69 0A        ADC #$0A
C0/23C2: 85 08        STA $08
C0/23C4: 80 4A        BRA $2410
C0/23C6: A5 61        LDA $61
C0/23C8: 18           CLC 
C0/23C9: 65 63        ADC $63
C0/23CB: 4A           LSR 
C0/23CC: 4A           LSR 
C0/23CD: 4A           LSR 
C0/23CE: 4A           LSR 
C0/23CF: 29 01        AND #$01
C0/23D1: 85 08        STA $08
C0/23D3: AD DB 0A     LDA $0ADB
C0/23D6: 0A           ASL 
C0/23D7: 18           CLC 
C0/23D8: 65 08        ADC $08
C0/23DA: 85 BB        STA $BB
C0/23DC: 80 02        BRA $23E0
C0/23DE: A5 BB        LDA $BB
C0/23E0: 85 08        STA $08
C0/23E2: AD DA 0A     LDA $0ADA
C0/23E5: C9 0D        CMP #$0D
C0/23E7: B0 19        BCS $2402
C0/23E9: C9 07        CMP #$07
C0/23EB: 90 15        BCC $2402
C0/23ED: A5 08        LDA $08
C0/23EF: 18           CLC 
C0/23F0: 69 40        ADC #$40
C0/23F2: 85 08        STA $08
C0/23F4: AD DA 0A     LDA $0ADA
C0/23F7: C9 09        CMP #$09
C0/23F9: 90 07        BCC $2402
C0/23FB: A5 08        LDA $08
C0/23FD: 18           CLC 
C0/23FE: 69 08        ADC #$08
C0/2400: 85 08        STA $08
C0/2402: A5 61        LDA $61
C0/2404: 4A           LSR 
C0/2405: 4A           LSR 
C0/2406: 4A           LSR 
C0/2407: 4A           LSR 
C0/2408: 1A           INC 
C0/2409: 29 01        AND #$01
C0/240B: 18           CLC 
C0/240C: 65 C6        ADC $C6
C0/240E: 85 15        STA $15
C0/2410: A5 08        LDA $08
C0/2412: C2 20        REP #$20
C0/2414: 0A           ASL 
C0/2415: 0A           ASL 
C0/2416: 0A           ASL 
C0/2417: 0A           ASL 
C0/2418: AA           TAX 
C0/2419: A5 06        LDA $06
C0/241B: E2 20        SEP #$20
C0/241D: AD DA 0A     LDA $0ADA       ; party sprite graphic
C0/2420: C9 0B        CMP #$0B
C0/2422: 90 08        BCC $242C

; upper half = 3/0, lower half = 3/0
C0/2424: A9 30        LDA #$30
C0/2426: 85 08        STA $08
C0/2428: 85 09        STA $09
C0/242A: 80 68        BRA $2494

C0/242C: A5 0D        LDA $0D
C0/242E: D0 3E        BNE $246E       ; branch if jumping
C0/2430: A5 C6        LDA $C6
C0/2432: C9 70        CMP #$70
C0/2434: D0 38        BNE $246E
C0/2436: A5 CA        LDA $CA
C0/2438: 29 08        AND #$08
C0/243A: D0 0E        BNE $244A       ; branch if sprite gets fully hidden

; half hidden sprite
C0/243C: A5 CA        LDA $CA
C0/243E: 29 04        AND #$04
C0/2440: F0 34        BEQ $2476       ; branch if not a bridge tile
C0/2442: A5 C3        LDA $C3
C0/2444: 29 02        AND #$02
C0/2446: F0 26        BEQ $246E       ; branch if not on lower z-level
C0/2448: 80 06        BRA $2450       ; branch if on lower z-level

; fully hidden sprite
C0/244A: A5 CA        LDA $CA
C0/244C: 29 04        AND #$04
C0/244E: D0 10        BNE $2460       ; branch if a bridge tile

; upper half = 2/p, lower half = 2/4 (fully hidden sprite, bridge || half hidden sprite, bridge, lower z-level)
C0/2450: A9 28        LDA #$28        ; priority 2, palette offset 2
C0/2452: 85 09        STA $09         ; lower half of sprite
C0/2454: AD 0F 11     LDA $110F
C0/2457: 29 10        AND #$10
C0/2459: 4A           LSR 
C0/245A: 09 20        ORA #$20        ; priority 2, palette offset 0 or 4
C0/245C: 85 08        STA $08         ; upper half of sprite
C0/245E: 80 34        BRA $2494

; upper half = 2/p, lower half = 2/p (fully hidden, bridge)
C0/2460: AD 0F 11     LDA $110F
C0/2463: 29 10        AND #$10
C0/2465: 4A           LSR 
C0/2466: 09 20        ORA #$20
C0/2468: 85 08        STA $08
C0/246A: 85 09        STA $09
C0/246C: 80 26        BRA $2494

; upper half = 3/0, lower half = 3/0 (default)
C0/246E: A9 30        LDA #$30
C0/2470: 85 08        STA $08
C0/2472: 85 09        STA $09
C0/2474: 80 1E        BRA $2494

; upper half = 3/p, lower half = 2/4 (half hidden, not bridge)
C0/2476: AD 0F 11     LDA $110F
C0/2479: 29 10        AND #$10
C0/247B: 4A           LSR 
C0/247C: 09 30        ORA #$30
C0/247E: 85 08        STA $08
C0/2480: A9 28        LDA #$28
C0/2482: 85 09        STA $09
C0/2484: 80 0E        BRA $2494

; upper half = 3/p, lower half = 2/0 (unused)
C0/2486: AD 0F 11     LDA $110F
C0/2489: 29 10        AND #$10
C0/248B: 4A           LSR 
C0/248C: 09 30        ORA #$30
C0/248E: 85 08        STA $08
C0/2490: A9 20        LDA #$20
C0/2492: 85 09        STA $09

C0/2494: DA           PHX 
C0/2495: AD DA 0A     LDA $0ADA
C0/2498: AA           TAX 
C0/2499: A5 08        LDA $08
C0/249B: 1F 6C 25 C0  ORA $C0256C,X
C0/249F: 85 08        STA $08
C0/24A1: A5 09        LDA $09
C0/24A3: 1F 6C 25 C0  ORA $C0256C,X
C0/24A7: 85 09        STA $09
C0/24A9: FA           PLX 
C0/24AA: A4 C7        LDY $C7         ; pointer to sprite data for upper half ($0110 for normal priority, $01E8 for low priority)
C0/24AC: BF 95 2A C0  LDA $C02A95,X
C0/24B0: 18           CLC 
C0/24B1: 65 C5        ADC $C5
C0/24B3: 38           SEC 
C0/24B4: ED A0 10     SBC $10A0
C0/24B7: 99 00 02     STA $0200,Y     ; x position
C0/24BA: BF 96 2A C0  LDA $C02A96,X
C0/24BE: 18           CLC 
C0/24BF: 65 15        ADC $15
C0/24C1: 38           SEC 
C0/24C2: ED A2 10     SBC $10A2
C0/24C5: 38           SEC 
C0/24C6: E5 0D        SBC $0D
C0/24C8: 99 01 02     STA $0201,Y     ; y position
C0/24CB: BF 97 2A C0  LDA $C02A97,X
C0/24CF: 99 02 02     STA $0202,Y     ; tile index
C0/24D2: BF 98 2A C0  LDA $C02A98,X
C0/24D6: 05 08        ORA $08
C0/24D8: 99 03 02     STA $0203,Y     ; vhoopppm
C0/24DB: BF 99 2A C0  LDA $C02A99,X
C0/24DF: 18           CLC 
C0/24E0: 65 C5        ADC $C5
C0/24E2: 38           SEC 
C0/24E3: ED A0 10     SBC $10A0
C0/24E6: 99 04 02     STA $0204,Y
C0/24E9: BF 9A 2A C0  LDA $C02A9A,X
C0/24ED: 18           CLC 
C0/24EE: 65 15        ADC $15
C0/24F0: 38           SEC 
C0/24F1: ED A2 10     SBC $10A2
C0/24F4: 38           SEC 
C0/24F5: E5 0D        SBC $0D
C0/24F7: 99 05 02     STA $0205,Y
C0/24FA: BF 9B 2A C0  LDA $C02A9B,X
C0/24FE: 99 06 02     STA $0206,Y
C0/2501: BF 9C 2A C0  LDA $C02A9C,X
C0/2505: 05 08        ORA $08
C0/2507: 99 07 02     STA $0207,Y
C0/250A: A0 E8 01     LDY #$01E8      ; pointer to sprite data for lower half
C0/250D: BF 9D 2A C0  LDA $C02A9D,X
C0/2511: 18           CLC 
C0/2512: 65 C5        ADC $C5
C0/2514: 38           SEC 
C0/2515: ED A0 10     SBC $10A0
C0/2518: 99 08 02     STA $0208,Y
C0/251B: BF 9E 2A C0  LDA $C02A9E,X
C0/251F: 18           CLC 
C0/2520: 65 15        ADC $15
C0/2522: 38           SEC 
C0/2523: ED A2 10     SBC $10A2
C0/2526: 38           SEC 
C0/2527: E5 0D        SBC $0D
C0/2529: 99 09 02     STA $0209,Y
C0/252C: BF 9F 2A C0  LDA $C02A9F,X
C0/2530: 99 0A 02     STA $020A,Y
C0/2533: BF A0 2A C0  LDA $C02AA0,X
C0/2537: 05 09        ORA $09
C0/2539: 99 0B 02     STA $020B,Y
C0/253C: BF A1 2A C0  LDA $C02AA1,X
C0/2540: 18           CLC 
C0/2541: 65 C5        ADC $C5
C0/2543: 38           SEC 
C0/2544: ED A0 10     SBC $10A0
C0/2547: 99 0C 02     STA $020C,Y
C0/254A: BF A2 2A C0  LDA $C02AA2,X
C0/254E: 18           CLC 
C0/254F: 65 15        ADC $15
C0/2551: 38           SEC 
C0/2552: ED A2 10     SBC $10A2
C0/2555: 38           SEC 
C0/2556: E5 0D        SBC $0D
C0/2558: 99 0D 02     STA $020D,Y
C0/255B: BF A3 2A C0  LDA $C02AA3,X
C0/255F: 99 0E 02     STA $020E,Y
C0/2562: BF A4 2A C0  LDA $C02AA4,X
C0/2566: 05 09        ORA $09
C0/2568: 99 0F 02     STA $020F,Y
C0/256B: 60           RTS 

C0/256C: 00 00        BRK $00
C0/256E: 00 00        BRK $00
C0/2570: 00 00        BRK $00
C0/2572: 00 00        BRK $00
C0/2574: 00 00        BRK $00
C0/2576: 00 00        BRK $00
C0/2578: 00 00        BRK $00
C0/257A: 00 00        BRK $00

; [  ]

C0/257C: A9 80        LDA #$80
C0/257E: 8D 15 21     STA $2115
C0/2581: AD 14 11     LDA $1114
C0/2584: C2 20        REP #$20
C0/2586: 0A           ASL 
C0/2587: 0A           ASL 
C0/2588: 0A           ASL 
C0/2589: 0A           ASL 
C0/258A: 85 23        STA $23
C0/258C: A5 06        LDA $06
C0/258E: E2 20        SEP #$20
C0/2590: A6 06        LDX $06
C0/2592: 86 11        STX $11
C0/2594: C2 20        REP #$20
C0/2596: A9 00 7C     LDA #$7C00
C0/2599: 85 2E        STA $2E
C0/259B: A5 11        LDA $11
C0/259D: C9 08 00     CMP #$0008
C0/25A0: 90 05        BCC $25A7
C0/25A2: A9 00 7D     LDA #$7D00
C0/25A5: 85 2E        STA $2E
C0/25A7: A5 11        LDA $11
C0/25A9: 0A           ASL 
C0/25AA: 0A           ASL 
C0/25AB: 0A           ASL 
C0/25AC: 0A           ASL 
C0/25AD: 0A           ASL 
C0/25AE: 18           CLC 
C0/25AF: 65 2E        ADC $2E
C0/25B1: 8D 16 21     STA $2116
C0/25B4: 18           CLC 
C0/25B5: 69 00 01     ADC #$0100
C0/25B8: 85 2E        STA $2E
C0/25BA: A5 06        LDA $06
C0/25BC: E2 20        SEP #$20
C0/25BE: A6 23        LDX $23
C0/25C0: BF 67 26 C0  LDA $C02667,X
C0/25C4: C2 20        REP #$20
C0/25C6: 0A           ASL 
C0/25C7: 0A           ASL 
C0/25C8: 0A           ASL 
C0/25C9: AA           TAX 
C0/25CA: A5 06        LDA $06
C0/25CC: E2 20        SEP #$20
C0/25CE: DA           PHX 
C0/25CF: A0 08 00     LDY #$0008
C0/25D2: BF 00 DF C0  LDA $C0DF00,X
C0/25D6: 9C 18 21     STZ $2118
C0/25D9: 8D 19 21     STA $2119
C0/25DC: E8           INX 
C0/25DD: 88           DEY 
C0/25DE: D0 F2        BNE $25D2
C0/25E0: 20 36 26     JSR $2636
C0/25E3: A0 08 00     LDY #$0008
C0/25E6: BF 00 DF C0  LDA $C0DF00,X
C0/25EA: 9C 18 21     STZ $2118
C0/25ED: 8D 19 21     STA $2119
C0/25F0: E8           INX 
C0/25F1: 88           DEY 
C0/25F2: D0 F2        BNE $25E6
C0/25F4: 20 36 26     JSR $2636
C0/25F7: A4 2E        LDY $2E
C0/25F9: 8C 16 21     STY $2116
C0/25FC: FA           PLX 
C0/25FD: A0 08 00     LDY #$0008
C0/2600: BF 80 DF C0  LDA $C0DF80,X
C0/2604: 9C 18 21     STZ $2118
C0/2607: 8D 19 21     STA $2119
C0/260A: E8           INX 
C0/260B: 88           DEY 
C0/260C: D0 F2        BNE $2600
C0/260E: 20 36 26     JSR $2636
C0/2611: A0 08 00     LDY #$0008
C0/2614: BF 80 DF C0  LDA $C0DF80,X
C0/2618: 9C 18 21     STZ $2118
C0/261B: 8D 19 21     STA $2119
C0/261E: E8           INX 
C0/261F: 88           DEY 
C0/2620: D0 F2        BNE $2614
C0/2622: 20 36 26     JSR $2636
C0/2625: A6 23        LDX $23
C0/2627: E8           INX 
C0/2628: 86 23        STX $23
C0/262A: E6 11        INC $11
C0/262C: A5 11        LDA $11
C0/262E: C9 10        CMP #$10
C0/2630: F0 03        BEQ $2635
C0/2632: 4C 94 25     JMP $2594
C0/2635: 60           RTS 

; [  ]

C0/2636: 9C 18 21     STZ $2118
C0/2639: 9C 19 21     STZ $2119
C0/263C: 9C 18 21     STZ $2118
C0/263F: 9C 19 21     STZ $2119
C0/2642: 9C 18 21     STZ $2118
C0/2645: 9C 19 21     STZ $2119
C0/2648: 9C 18 21     STZ $2118
C0/264B: 9C 19 21     STZ $2119
C0/264E: 9C 18 21     STZ $2118
C0/2651: 9C 19 21     STZ $2119
C0/2654: 9C 18 21     STZ $2118
C0/2657: 9C 19 21     STZ $2119
C0/265A: 9C 18 21     STZ $2118
C0/265D: 9C 19 21     STZ $2119
C0/2660: 9C 18 21     STZ $2118
C0/2663: 9C 19 21     STZ $2119
C0/2666: 60           RTS 

C0/2667: 00 02 8C 8E 00 00 00 00 00 00 00 00 00 00 00 00
C0/2677: 00 02 A0 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/2687: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/2697: 00 02 A4 84 00 00 00 00 00 00 00 00 00 00 00 00
C0/26A7: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/26B7: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/26C7: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/26D7: 00 02 66 68 6A A2 A0 00 00 00 00 00 00 00 00 00
C0/26E7: 00 02 66 68 6A A2 00 00 00 00 00 00 00 00 00 00
C0/26F7: 00 02 2C 2E 40 42 44 62 64 46 48 00 00 00 00 00
C0/2707: 00 02 4A 4C 60 00 00 00 00 00 00 00 00 00 00 00
C0/2717: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/2727: 00 02 04 06 08 0A 0C 0E 20 22 24 26 28 2A 00 00
C0/2737: 00 02 04 06 08 0A 0C 0E 20 22 24 26 28 2A A6 A8
C0/2747: 00 02 04 06 08 0A 0C 0E 20 22 24 26 28 2A A6 A8
C0/2757: 00 02 88 8A 00 00 00 00 00 00 00 00 00 00 00 00
C0/2767: 00 02 88 8A 00 00 00 00 00 00 00 00 00 00 00 00
C0/2777: 00 02 82 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/2787: 00 02 80 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/2797: 00 02 86 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/27A7: 00 02 6C 6E 4E 00 00 00 00 00 00 00 00 00 00 00
C0/27B7: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/27C7: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/27D7: 00 02 8C 8E 00 00 00 00 00 00 00 00 00 00 00 00
C0/27E7: 00 02 2C 2E 40 42 44 62 64 46 00 00 00 00 00 00
C0/27F7: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00
C0/2807: 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00

; [  ]

C0/2817: AD 14 11     LDA $1114       ; tileset
C0/281A: 0A           ASL 
C0/281B: AA           TAX 
C0/281C: C2 20        REP #$20
C0/281E: BF 80 D9 C0  LDA $C0D980,X   ; 
C0/2822: 18           CLC 
C0/2823: 69 80 D9     ADC #$D980
C0/2826: 8D F0 04     STA $04F0
C0/2829: A5 06        LDA $06
C0/282B: E2 20        SEP #$20
C0/282D: A9 C0        LDA #$C0
C0/282F: 8D F2 04     STA $04F2
C0/2832: A2 73 18     LDX #$1873
C0/2835: 8E F3 04     STX $04F3
C0/2838: A9 00        LDA #$00
C0/283A: 8D F5 04     STA $04F5
C0/283D: 22 02 00 C3  JSL $C30002     ; decompress
C0/2841: 60           RTS 

; [  ]

C0/2842: A5 BD        LDA $BD
C0/2844: D0 01        BNE $2847
C0/2846: 60           RTS 
C0/2847: A0 00 01     LDY #$0100
C0/284A: A5 C0        LDA $C0
C0/284C: 3A           DEC 
C0/284D: 0A           ASL 
C0/284E: 0A           ASL 
C0/284F: 85 0D        STA $0D
C0/2851: A5 BA        LDA $BA
C0/2853: F0 22        BEQ $2877
C0/2855: 3A           DEC 
C0/2856: 18           CLC 
C0/2857: 65 0D        ADC $0D
C0/2859: 0A           ASL 
C0/285A: AA           TAX 
C0/285B: C2 20        REP #$20
C0/285D: AD 8C 10     LDA $108C
C0/2860: 18           CLC 
C0/2861: 7F F3 28 C0  ADC $C028F3,X
C0/2865: 8D 8C 10     STA $108C
C0/2868: AD 8E 10     LDA $108E
C0/286B: 18           CLC 
C0/286C: 7F 33 29 C0  ADC $C02933,X
C0/2870: 8D 8E 10     STA $108E
C0/2873: A5 06        LDA $06
C0/2875: E2 20        SEP #$20
C0/2877: A6 06        LDX $06
C0/2879: BD C9 13     LDA $13C9,X
C0/287C: 29 80        AND #$80
C0/287E: D0 2C        BNE $28AC
C0/2880: BD C6 13     LDA $13C6,X
C0/2883: 38           SEC 
C0/2884: ED 8D 10     SBC $108D
C0/2887: 38           SEC 
C0/2888: ED A0 10     SBC $10A0
C0/288B: 99 00 02     STA $0200,Y
C0/288E: BD C7 13     LDA $13C7,X
C0/2891: 38           SEC 
C0/2892: ED 8F 10     SBC $108F
C0/2895: 38           SEC 
C0/2896: ED A2 10     SBC $10A2
C0/2899: 99 01 02     STA $0201,Y
C0/289C: BD C8 13     LDA $13C8,X
C0/289F: 99 02 02     STA $0202,Y
C0/28A2: BD C9 13     LDA $13C9,X
C0/28A5: 29 7F        AND #$7F
C0/28A7: 99 03 02     STA $0203,Y
C0/28AA: 80 2A        BRA $28D6
C0/28AC: BD C6 13     LDA $13C6,X
C0/28AF: 38           SEC 
C0/28B0: ED 8D 10     SBC $108D
C0/28B3: 38           SEC 
C0/28B4: ED A0 10     SBC $10A0
C0/28B7: 99 D8 02     STA $02D8,Y
C0/28BA: BD C7 13     LDA $13C7,X
C0/28BD: 38           SEC 
C0/28BE: ED 8F 10     SBC $108F
C0/28C1: 38           SEC 
C0/28C2: ED A2 10     SBC $10A2
C0/28C5: 99 D9 02     STA $02D9,Y
C0/28C8: BD C8 13     LDA $13C8,X
C0/28CB: 99 DA 02     STA $02DA,Y
C0/28CE: BD C9 13     LDA $13C9,X
C0/28D1: 29 7F        AND #$7F
C0/28D3: 99 DB 02     STA $02DB,Y
C0/28D6: C8           INY 
C0/28D7: C8           INY 
C0/28D8: C8           INY 
C0/28D9: C8           INY 
C0/28DA: E8           INX 
C0/28DB: E8           INX 
C0/28DC: E8           INX 
C0/28DD: E8           INX 
C0/28DE: E0 10 00     CPX #$0010
C0/28E1: D0 96        BNE $2879
C0/28E3: A9 AA        LDA #$AA
C0/28E5: 8D 10 04     STA $0410
C0/28E8: A9 A0        LDA #$A0
C0/28EA: 8D 1D 04     STA $041D
C0/28ED: A9 0A        LDA #$0A
C0/28EF: 8D 1E 04     STA $041E
C0/28F2: 60           RTS 

C0/28F3: 0000 0080 0000 FF80
C0/28FB: 0000 0100 0000 FF00
C0/2903: 0000 0180 0000 FE80
C0/290B: 0000 0200 0000 FE00
C0/2913: 0000 0080 0000 FF80
C0/291B: 0000 0100 0000 FF00
C0/2923: 0000 0180 0000 FE80
C0/292B: 0000 0400 0000 FC00
C0/2933: FF80 0000 0080 0000
C0/293B: FF00 0000 0100 0000
C0/2943: FE80 0000 0180 0000
C0/294B: FE00 0000 0200 0000
C0/2953: FF80 0000 0080 0000
C0/295B: FF00 0000 0100 0000
C0/2963: FE80 0000 0180 0000
C0/296B: FC00 0000 0400 0000

C0/2973: 9C 8C 10     STZ $108C
C0/2976: 9C 8D 10     STZ $108D
C0/2979: 9C 8E 10     STZ $108E
C0/297C: 9C 8F 10     STZ $108F
C0/297F: A5 BA        LDA $BA
C0/2981: F0 04        BEQ $2987
C0/2983: 3A           DEC 
C0/2984: 0A           ASL 
C0/2985: 0A           ASL 
C0/2986: 0A           ASL 
C0/2987: AA           TAX 
C0/2988: A4 06        LDY $06
C0/298A: 5A           PHY 
C0/298B: 64 0F        STZ $0F
C0/298D: 64 10        STZ $10
C0/298F: BF 75 2A C0  LDA $C02A75,X
C0/2993: 99 C6 13     STA $13C6,Y
C0/2996: BF 76 2A C0  LDA $C02A76,X
C0/299A: 99 C7 13     STA $13C7,Y
C0/299D: BF 55 2A C0  LDA $C02A55,X
C0/29A1: A8           TAY 
C0/29A2: C9 12        CMP #$12
C0/29A4: D0 18        BNE $29BE
C0/29A6: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/29A9: 29 04        AND #$04
C0/29AB: F0 34        BEQ $29E1
C0/29AD: A5 C3        LDA $C3
C0/29AF: C9 02        CMP #$02
C0/29B1: D0 2E        BNE $29E1
C0/29B3: AD 04 11     LDA $1104
C0/29B6: 29 03        AND #$03
C0/29B8: C9 01        CMP #$01
C0/29BA: D0 50        BNE $2A0C
C0/29BC: 80 1A        BRA $29D8
C0/29BE: C9 06        CMP #$06
C0/29C0: B0 1F        BCS $29E1
C0/29C2: B9 F8 10     LDA $10F8,Y
C0/29C5: 29 04        AND #$04
C0/29C7: F0 18        BEQ $29E1
C0/29C9: A5 C3        LDA $C3
C0/29CB: C9 02        CMP #$02
C0/29CD: D0 3D        BNE $2A0C
C0/29CF: B9 F2 10     LDA $10F2,Y     ; map tile properties byte 1
C0/29D2: 29 03        AND #$03
C0/29D4: C9 01        CMP #$01
C0/29D6: D0 39        BNE $2A11
C0/29D8: A9 80        LDA #$80
C0/29DA: 85 10        STA $10
C0/29DC: A9 02        LDA #$02
C0/29DE: 4C 1C 2A     JMP $2A1C
C0/29E1: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/29E4: 29 07        AND #$07
C0/29E6: C9 05        CMP #$05
C0/29E8: F0 06        BEQ $29F0
C0/29EA: C9 01        CMP #$01
C0/29EC: D0 11        BNE $29FF
C0/29EE: 80 06        BRA $29F6
C0/29F0: A5 C3        LDA $C3
C0/29F2: C9 02        CMP #$02
C0/29F4: F0 09        BEQ $29FF
C0/29F6: B9 F2 10     LDA $10F2,Y     ; map tile properties byte 1
C0/29F9: 29 03        AND #$03
C0/29FB: C9 02        CMP #$02
C0/29FD: F0 0D        BEQ $2A0C
C0/29FF: B9 F2 10     LDA $10F2,Y     ; map tile properties byte 1
C0/2A02: 29 04        AND #$04
C0/2A04: F0 0F        BEQ $2A15
C0/2A06: A5 C3        LDA $C3
C0/2A08: C9 01        CMP #$01
C0/2A0A: D0 05        BNE $2A11
C0/2A0C: A9 00        LDA #$00
C0/2A0E: 4C 1C 2A     JMP $2A1C
C0/2A11: A9 80        LDA #$80
C0/2A13: 85 10        STA $10
C0/2A15: B9 BE 10     LDA $10BE,Y
C0/2A18: A8           TAY 
C0/2A19: B9 73 18     LDA $1873,Y
C0/2A1C: 7A           PLY 
C0/2A1D: C2 20        REP #$20
C0/2A1F: 18           CLC 
C0/2A20: 69 C0 01     ADC #$01C0
C0/2A23: 09 00 04     ORA #$0400
C0/2A26: 05 0F        ORA $0F
C0/2A28: 99 C8 13     STA $13C8,Y
C0/2A2B: 29 10 00     AND #$0010
C0/2A2E: F0 09        BEQ $2A39
C0/2A30: B9 C8 13     LDA $13C8,Y
C0/2A33: 09 00 40     ORA #$4000
C0/2A36: 99 C8 13     STA $13C8,Y
C0/2A39: B9 C8 13     LDA $13C8,Y
C0/2A3C: 29 EF FF     AND #$FFEF
C0/2A3F: 99 C8 13     STA $13C8,Y
C0/2A42: A5 06        LDA $06
C0/2A44: E2 20        SEP #$20
C0/2A46: E8           INX 
C0/2A47: E8           INX 
C0/2A48: C8           INY 
C0/2A49: C8           INY 
C0/2A4A: C8           INY 
C0/2A4B: C8           INY 
C0/2A4C: C0 10 00     CPY #$0010
C0/2A4F: F0 03        BEQ $2A54
C0/2A51: 4C 8A 29     JMP $298A
C0/2A54: 60           RTS 

C0/2A55: 12 00 02 00        COP $00
C0/2A59: 08 00 08 00
C0/2A5D: 02 00 04 00
C0/2A61: 08 00 0A 00
C0/2A65: 02 00 08 00
C0/2A69: 0E 00 0E 00
C0/2A6D: 00 00 02 00
C0/2A71: 06 00 08 00

C0/2A75: 70 4F 70 5F
C0/2A79: 70 6F 70 6F
C0/2A7D: 70 5F 80 5F
C0/2A81: 70 6F 80 6F
C0/2A85: 70 5F 70 6F
C0/2A89: 70 7F 70 7F
C0/2A8D: 60 5F 70 5F
C0/2A91: 60 6F 70 6F

; sprite frames (80 items, 16 bytes per frame)
C0/2A95: 00 FC 04 00 08 FC 05 00 00 04 06 00 08 04 07 00
C0/2AA5: 00 FC 04 00 08 FC 05 00 00 04 07 40 08 04 06 40
C0/2AB5: 00 FC 09 40 08 FC 08 40 00 04 0B 40 08 04 0A 40
C0/2AC5: 00 FC 0D 40 08 FC 0C 40 00 04 0F 40 08 04 0E 40
C0/2AD5: 00 FC 00 00 08 FC 01 00 00 04 02 00 08 04 03 00
C0/2AE5: 00 FC 00 00 08 FC 01 00 00 04 03 40 08 04 02 40
C0/2AF5: 00 FC 08 00 08 FC 09 00 00 04 0A 00 08 04 0B 00
C0/2B05: 00 FC 0C 00 08 FC 0D 00 00 04 0E 00 08 04 0F 00
C0/2B15: 00 FC 00 00 08 FC 01 00 00 04 02 00 08 04 03 00
C0/2B25: 00 FC 04 00 08 FC 05 00 00 04 06 00 08 04 07 00
C0/2B35: 00 FC 08 00 08 FC 09 00 00 04 0A 00 08 04 0B 00
C0/2B45: 00 FC 0C 00 08 FC 0D 00 00 04 0E 00 08 04 0F 00
C0/2B55: 00 FC 01 40 08 FC 00 40 00 04 03 40 08 04 02 40
C0/2B65: 00 FC 05 40 08 FC 04 40 00 04 07 40 08 04 06 40
C0/2B75: 00 FC 09 40 08 FC 08 40 00 04 0B 40 08 04 0A 40
C0/2B85: 00 FC 0D 40 08 FC 0C 40 00 04 0F 40 08 04 0E 40

C0/2B95: 00 FC 19 00 08 FC 01 00 00 04 1A 00 08 04 03 00
C0/2BA5: 00 FC 18 00 08 FC 01 00 00 04 1A 00 08 04 03 00
C0/2BB5: 00 FC 1B 00 08 FC 01 00 00 04 1A 00 08 04 03 00
C0/2BC5: 00 FC 01 40 08 FC 19 40 00 04 03 40 08 04 1A 40
C0/2BD5: 00 FC 01 40 08 FC 18 40 00 04 03 40 08 04 1A 40
C0/2BE5: 00 FC 01 40 08 FC 1B 40 00 04 03 40 08 04 1A 40
C0/2BF5: 00 FC 04 00 08 FC 31 00 00 04 3E 00 08 04 28 00
C0/2C05: 00 FC 04 00 08 FC 30 00 00 04 3E 00 08 04 28 00
C0/2C15: 00 FC 31 40 08 FC 04 40 00 04 28 40 08 04 3E 40
C0/2C25: 00 FC 30 40 08 FC 04 40 00 04 28 40 08 04 3E 40
C0/2C35: 00 FC 08 00 08 FC 37 00 00 04 0A 00 08 04 38 00
C0/2C45: 00 FC 08 00 08 FC 09 00 00 04 3C 00 08 04 3D 00
C0/2C55: 00 FC 37 40 08 FC 08 40 00 04 38 40 08 04 0A 40
C0/2C65: 00 FC 09 40 08 FC 08 40 00 04 3D 40 08 04 3C 40
C0/2C75: 00 FC 10 00 08 FC 11 00 00 04 12 00 08 04 13 00
C0/2C85: 00 FC 25 00 08 FC 26 00 00 04 06 00 08 04 07 00

C0/2C95: 00 FC 39 00 08 FC 3A 00 00 04 3B 00 08 04 0B 00
C0/2CA5: 00 FC 3A 40 08 FC 39 40 00 04 0B 40 08 04 3B 40
C0/2CB5: 00 FC 1C 00 08 FC 1D 00 00 04 1E 00 08 04 1F 00
C0/2CC5: 00 FC 1D 40 08 FC 1C 40 00 04 1F 40 08 04 1E 40
C0/2CD5: 00 FC 20 00 08 FC 21 00 00 04 22 00 08 04 2F 00
C0/2CE5: 00 FC 21 40 08 FC 20 40 00 04 2F 40 08 04 22 40
C0/2CF5: 00 FC 34 00 08 FC 35 00 00 04 36 00 08 04 36 40
C0/2D05: 00 FC 32 00 08 FC 33 00 00 04 36 00 08 04 36 40
C0/2D15: 00 FC 2D 00 08 FC 2E 00 00 04 2A 00 08 04 2A 40
C0/2D25: 00 FC 2B 00 08 FC 2C 00 00 04 29 00 08 04 29 40
C0/2D35: 00 FC 23 00 08 FC 24 00 00 04 27 00 08 04 27 40
C0/2D45: 00 FC 04 00 08 FC 05 00 00 04 06 00 08 04 07 00
C0/2D55: 00 FC 00 00 08 FC 01 00 00 04 36 00 08 04 36 40
C0/2D65: 00 FC 31 40 08 FC 31 00 00 04 28 40 08 04 28 00
C0/2D75: 00 FC 30 40 08 FC 30 00 00 04 28 40 08 04 28 00
C0/2D85: 00 FC 14 00 08 FC 15 00 00 04 16 00 08 04 17 00

C0/2D95: 00 FC 15 40 08 FC 14 40 00 04 17 40 08 04 16 40
C0/2DA5: 00 FC 04 00 08 FC 04 40 00 04 3E 00 08 04 3E 40
C0/2DB5: 00 FC 12 00 08 FC 13 00 00 04 06 00 08 04 07 00
C0/2DC5: 00 FC 15 40 08 FC 14 40 00 04 0B 40 08 04 16 40
C0/2DD5: 00 FC 10 00 08 FC 11 00 00 04 02 00 08 04 03 00
C0/2DE5: 00 FC 14 00 08 FC 15 00 00 04 16 00 08 04 0B 00
C0/2DF5: 00 FC 01 40 08 FC 17 40 00 04 03 40 08 04 1A 40
C0/2E05: 00 FC 01 40 08 FC 18 40 00 04 03 40 08 04 1A 40
C0/2E15: 00 FC 17 00 08 FC 01 00 00 04 1A 00 08 04 03 00
C0/2E25: 00 FC 18 00 08 FC 01 00 00 04 1A 00 08 04 03 00
C0/2E35: 00 FC 17 00 08 FC 19 00 00 04 1A 00 08 04 1B 00
C0/2E45: 00 FC 1C 00 08 FC 1D 00 00 04 1E 00 08 04 1F 00
C0/2E55: 00 FC 00 00 08 FC 00 00 00 04 00 00 08 04 00 00
C0/2E65: 00 FC 00 00 08 FC 00 00 00 04 00 00 08 04 00 00
C0/2E75: 00 FC 00 00 08 FC 00 00 00 04 00 00 08 04 00 00
C0/2E85: 00 FC 00 00 08 FC 00 00 00 04 00 00 08 04 00 00

C0/2E95: 00 FC 04 00 08 FC 05 00 00 04 06 00 08 04 07 00
C0/2EA5: 00 FC 05 40 08 FC 04 40 00 04 07 40 08 04 06 40
C0/2EB5: 00 FC 09 40 08 FC 08 40 00 04 0B 40 08 04 0A 40
C0/2EC5: 00 FC 0D 40 08 FC 0C 40 00 04 0F 40 08 04 0E 40
C0/2ED5: 00 FC 00 00 08 FC 01 00 00 04 02 00 08 04 03 00
C0/2EE5: 00 FC 01 40 08 FC 00 40 00 04 03 40 08 04 02 40
C0/2EF5: 00 FC 08 00 08 FC 09 00 00 04 0A 00 08 04 0B 00
C0/2F05: 00 FC 0C 00 08 FC 0D 00 00 04 0E 00 08 04 0F 00
C0/2F15: 00 FC 08 00 08 FC 09 00 00 04 0A 00 08 04 0B 00
C0/2F25: 00 FC 0C 00 08 FC 0D 00 00 04 0E 00 08 04 0F 00
C0/2F35: 00 FC 11 40 08 FC 10 40 00 04 13 40 08 04 12 40
C0/2F45: 00 FC 15 40 08 FC 14 40 00 04 17 40 08 04 16 40
C0/2F55: 00 FC 00 00 08 FC 01 00 00 04 02 00 08 04 03 00
C0/2F65: 00 FC 04 00 08 FC 05 00 00 04 06 00 08 04 07 00
C0/2F75: 00 FC 10 00 08 FC 11 00 00 04 12 00 08 04 13 00
C0/2F85: 00 FC 14 00 08 FC 15 00 00 04 16 00 08 04 17 00

; [ execute npc script ]

C0/2F95: C2 20        REP #$20
C0/2F97: BD 7F 14     LDA $147F,X     ; npc script
C0/2F9A: 0A           ASL 
C0/2F9B: AA           TAX 
C0/2F9C: BF 00 00 CE  LDA $CE0000,X
C0/2FA0: 85 23        STA $23
C0/2FA2: 85 29        STA $29
C0/2FA4: BF 02 00 CE  LDA $CE0002,X
C0/2FA8: 85 26        STA $26
C0/2FAA: A5 06        LDA $06
C0/2FAC: E2 20        SEP #$20
C0/2FAE: A6 23        LDX $23
C0/2FB0: BF 00 00 CE  LDA $CE0000,X
C0/2FB4: C9 F0        CMP #$F0        ; find the end of the script ($F0)
C0/2FB6: F0 15        BEQ $2FCD
C0/2FB8: 38           SEC 
C0/2FB9: E9 F0        SBC #$F0
C0/2FBB: AA           TAX 
C0/2FBC: BF 6B 31 C0  LDA $C0316B,X   ; number of bytes for command
C0/2FC0: 18           CLC 
C0/2FC1: 65 23        ADC $23
C0/2FC3: 85 23        STA $23
C0/2FC5: A9 00        LDA #$00
C0/2FC7: 65 24        ADC $24
C0/2FC9: 85 24        STA $24
C0/2FCB: 80 E1        BRA $2FAE
C0/2FCD: E8           INX 
C0/2FCE: C2 20        REP #$20
C0/2FD0: A4 06        LDY $06
C0/2FD2: E4 26        CPX $26
C0/2FD4: F0 0D        BEQ $2FE3
C0/2FD6: BF 00 00 CE  LDA $CE0000,X   ; copy npc dialog
C0/2FDA: 99 D6 13     STA $13D6,Y
C0/2FDD: E8           INX 
C0/2FDE: E8           INX 
C0/2FDF: C8           INY 
C0/2FE0: C8           INY 
C0/2FE1: 80 EF        BRA $2FD2
C0/2FE3: A5 06        LDA $06
C0/2FE5: E2 20        SEP #$20
C0/2FE7: A6 29        LDX $29
C0/2FE9: BF 00 00 CE  LDA $CE0000,X   ; npc script command

; command $FF: execute event
C0/2FED: C9 FF        CMP #$FF
C0/2FEF: D0 03        BNE $2FF4
C0/2FF1: 4C 4D 31     JMP $314D

; command $FE: if event flag $00xx set
C0/2FF4: C9 FE        CMP #$FE
C0/2FF6: D0 0E        BNE $3006
C0/2FF8: BF 01 00 CE  LDA $CE0001,X
C0/2FFC: 20 2F CA     JSR $CA2F       ; get event flag $00xx
C0/2FFF: C9 00        CMP #$00
C0/3001: D0 39        BNE $303C
C0/3003: 4C 36 31     JMP $3136

; command $FD: if event flag $00xx clear
C0/3006: C9 FD        CMP #$FD
C0/3008: D0 0E        BNE $3018
C0/300A: BF 01 00 CE  LDA $CE0001,X
C0/300E: 20 2F CA     JSR $CA2F       ; get event flag $00xx
C0/3011: C9 00        CMP #$00
C0/3013: F0 27        BEQ $303C
C0/3015: 4C 36 31     JMP $3136

; command $FC: if event flag $01xx set
C0/3018: C9 FC        CMP #$FC
C0/301A: D0 0E        BNE $302A
C0/301C: BF 01 00 CE  LDA $CE0001,X
C0/3020: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/3023: C9 00        CMP #$00
C0/3025: D0 15        BNE $303C
C0/3027: 4C 36 31     JMP $3136

; command $FB: if event flag $01xx clear
C0/302A: C9 FB        CMP #$FB
C0/302C: D0 17        BNE $3045
C0/302E: BF 01 00 CE  LDA $CE0001,X
C0/3032: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/3035: C9 00        CMP #$00
C0/3037: F0 03        BEQ $303C
C0/3039: 4C 36 31     JMP $3136
C0/303C: A6 29        LDX $29         ; skip 2 bytes
C0/303E: E8           INX 
C0/303F: E8           INX 
C0/3040: 86 29        STX $29
C0/3042: 4C E7 2F     JMP $2FE7

; command $FA: if character data xxxx <=> yy
C0/3045: C9 FA        CMP #$FA
C0/3047: D0 49        BNE $3092
C0/3049: C2 20        REP #$20
C0/304B: BF 01 00 CE  LDA $CE0001,X
C0/304F: 29 FF 3F     AND #$3FFF
C0/3052: A8           TAY 
C0/3053: A5 06        LDA $06
C0/3055: E2 20        SEP #$20
C0/3057: BF 02 00 CE  LDA $CE0002,X
C0/305B: 29 C0        AND #$C0
C0/305D: D0 0C        BNE $306B

; 0 (if equal)
C0/305F: B9 00 05     LDA $0500,Y     ; character data
C0/3062: DF 03 00 CE  CMP $CE0003,X
C0/3066: F0 1F        BEQ $3087
C0/3068: 4C 36 31     JMP $3136

; 1 (if greater)
C0/306B: C9 40        CMP #$40
C0/306D: D0 0C        BNE $307B
C0/306F: B9 00 05     LDA $0500,Y
C0/3072: DF 03 00 CE  CMP $CE0003,X
C0/3076: B0 0F        BCS $3087
C0/3078: 4C 36 31     JMP $3136

; 2 (if less)
C0/307B: B9 00 05     LDA $0500,Y
C0/307E: DF 03 00 CE  CMP $CE0003,X
C0/3082: 90 03        BCC $3087
C0/3084: 4C 36 31     JMP $3136

C0/3087: A6 29        LDX $29         ; skip 4 bytes
C0/3089: E8           INX 
C0/308A: E8           INX 
C0/308B: E8           INX 
C0/308C: E8           INX 
C0/308D: 86 29        STX $29
C0/308F: 4C E7 2F     JMP $2FE7

; command $F9: if character data xxxx <=> yyyy
C0/3092: C9 F9        CMP #$F9
C0/3094: D0 48        BNE $30DE
C0/3096: C2 20        REP #$20
C0/3098: BF 01 00 CE  LDA $CE0001,X
C0/309C: 29 FF 3F     AND #$3FFF
C0/309F: A8           TAY 
C0/30A0: BF 01 00 CE  LDA $CE0001,X
C0/30A4: 29 00 C0     AND #$C000
C0/30A7: D0 10        BNE $30B9
C0/30A9: B9 00 05     LDA $0500,Y     ; character data
C0/30AC: DF 03 00 CE  CMP $CE0003,X
C0/30B0: F0 D5        BEQ $3087
C0/30B2: A5 06        LDA $06
C0/30B4: E2 20        SEP #$20
C0/30B6: 4C 36 31     JMP $3136
C0/30B9: C9 00 40     CMP #$4000
C0/30BC: D0 10        BNE $30CE
C0/30BE: B9 00 05     LDA $0500,Y
C0/30C1: DF 03 00 CE  CMP $CE0003,X
C0/30C5: B0 35        BCS $30FC
C0/30C7: A5 06        LDA $06
C0/30C9: E2 20        SEP #$20
C0/30CB: 4C 36 31     JMP $3136
C0/30CE: B9 00 05     LDA $0500,Y
C0/30D1: DF 03 00 CE  CMP $CE0003,X
C0/30D5: 90 25        BCC $30FC
C0/30D7: A5 06        LDA $06
C0/30D9: E2 20        SEP #$20
C0/30DB: 4C 36 31     JMP $3136

; command $F8: if character data xxxx & yy
C0/30DE: C9 F8        CMP #$F8
C0/30E0: D0 2A        BNE $310C
C0/30E2: C2 20        REP #$20
C0/30E4: BF 01 00 CE  LDA $CE0001,X   ; pointer to character data
C0/30E8: 29 FF 3F     AND #$3FFF
C0/30EB: A8           TAY 
C0/30EC: A5 06        LDA $06
C0/30EE: E2 20        SEP #$20
C0/30F0: B9 00 05     LDA $0500,Y     ; character data
C0/30F3: 3F 03 00 CE  AND $CE0003,X   ; mask
C0/30F7: D0 8E        BNE $3087
C0/30F9: 4C 36 31     JMP $3136

C0/30FC: A5 06        LDA $06         ; skip 5 bytes
C0/30FE: E2 20        SEP #$20
C0/3100: A6 29        LDX $29
C0/3102: E8           INX 
C0/3103: E8           INX 
C0/3104: E8           INX 
C0/3105: E8           INX 
C0/3106: E8           INX 
C0/3107: 86 29        STX $29
C0/3109: 4C E7 2F     JMP $2FE7

; command $F7: if party is facing xx
C0/310C: C9 F7        CMP #$F7
C0/310E: D0 0C        BNE $311C
C0/3110: BF 01 00 CE  LDA $CE0001,X
C0/3114: CD DB 0A     CMP $0ADB       ; facing direction
C0/3117: D0 1D        BNE $3136
C0/3119: 4C 3C 30     JMP $303C

; command $F5: if character data xxxx & yyyy
C0/311C: C2 20        REP #$20
C0/311E: BF 01 00 CE  LDA $CE0001,X
C0/3122: 29 FF 3F     AND #$3FFF
C0/3125: A8           TAY 
C0/3126: A5 06        LDA $06
C0/3128: E2 20        SEP #$20
C0/312A: B9 00 05     LDA $0500,Y
C0/312D: 3F 03 00 CE  AND $CE0003,X
C0/3131: D0 03        BNE $3136
C0/3133: 4C 87 30     JMP $3087

; condition not met, check next condition
C0/3136: A6 29        LDX $29
C0/3138: E8           INX 
C0/3139: BF 00 00 CE  LDA $CE0000,X
C0/313D: C9 FF        CMP #$FF
C0/313F: D0 F7        BNE $3138
C0/3141: E8           INX 
C0/3142: E8           INX 
C0/3143: E8           INX 
C0/3144: 86 29        STX $29
C0/3146: E4 D0        CPX $D0
C0/3148: F0 03        BEQ $314D
C0/314A: 4C E7 2F     JMP $2FE7
C0/314D: A9 01        LDA #$01
C0/314F: 85 57        STA $57
C0/3151: 64 BA        STZ $BA
C0/3153: C2 20        REP #$20
C0/3155: A6 29        LDX $29
C0/3157: BF 01 00 CE  LDA $CE0001,X   ; event index
C0/315B: 85 CE        STA $CE
C0/315D: A5 06        LDA $06
C0/315F: E2 20        SEP #$20
C0/3161: A6 CE        LDX $CE
C0/3163: F0 03        BEQ $3168
C0/3165: 20 17 A2     JSR $A217       ; execute event
C0/3168: 64 57        STZ $57
C0/316A: 60           RTS 

; number of bytes for each npc script command ($F0-$FF)
C0/316B: 00 00 00 00 00 04 01 02 04 05 04 02 02 02 02 03

; [ check npc events ]

C0/317B: AD DB 0A     LDA $0ADB       ; facing direction
C0/317E: 0A           ASL 
C0/317F: 0A           ASL 
C0/3180: AA           TAX 
C0/3181: BF 9B 32 C0  LDA $C0329B,X   ; pointer to forward tile
C0/3185: A8           TAY 
C0/3186: B9 F3 10     LDA $10F3,Y     ; tile properties byte 2
C0/3189: C9 FF        CMP #$FF
C0/318B: D0 13        BNE $31A0       ; branch if not a through-tile
C0/318D: BF 9E 32 C0  LDA $C0329E,X   ; forward x2 (interact through tile)
C0/3191: A8           TAY 
C0/3192: 20 4B 32     JSR $324B       ; get object at tile
C0/3195: C9 FF        CMP #$FF
C0/3197: D0 01        BNE $319A       ; return if no object
C0/3199: 60           RTS 
C0/319A: 20 89 32     JSR $3289       ; get pointer to object
C0/319D: 4C 30 32     JMP $3230
C0/31A0: 20 4B 32     JSR $324B       ; get object at tile
C0/31A3: C9 FF        CMP #$FF
C0/31A5: F0 06        BEQ $31AD       ; branch if no object
C0/31A7: 20 89 32     JSR $3289       ; get pointer to object
C0/31AA: 4C 30 32     JMP $3230
C0/31AD: BF 9C 32 C0  LDA $C0329C,X
C0/31B1: A8           TAY 
C0/31B2: 20 4B 32     JSR $324B
C0/31B5: C9 FF        CMP #$FF
C0/31B7: F0 1D        BEQ $31D6
C0/31B9: 20 89 32     JSR $3289
C0/31BC: BD 7B 14     LDA $147B,X
C0/31BF: 30 15        BMI $31D6
C0/31C1: AD DB 0A     LDA $0ADB
C0/31C4: 3A           DEC 
C0/31C5: 29 03        AND #$03
C0/31C7: 85 08        STA $08
C0/31C9: BD 7C 14     LDA $147C,X
C0/31CC: 4A           LSR 
C0/31CD: 29 03        AND #$03
C0/31CF: C5 08        CMP $08
C0/31D1: D0 03        BNE $31D6
C0/31D3: 4C 30 32     JMP $3230
C0/31D6: AD DB 0A     LDA $0ADB
C0/31D9: 0A           ASL 
C0/31DA: 0A           ASL 
C0/31DB: AA           TAX 
C0/31DC: BF 9D 32 C0  LDA $C0329D,X
C0/31E0: A8           TAY 
C0/31E1: 20 4B 32     JSR $324B
C0/31E4: C9 FF        CMP #$FF
C0/31E6: F0 1D        BEQ $3205
C0/31E8: 20 89 32     JSR $3289
C0/31EB: BD 7B 14     LDA $147B,X
C0/31EE: 30 15        BMI $3205
C0/31F0: AD DB 0A     LDA $0ADB
C0/31F3: 1A           INC 
C0/31F4: 29 03        AND #$03
C0/31F6: 85 08        STA $08
C0/31F8: BD 7C 14     LDA $147C,X
C0/31FB: 4A           LSR 
C0/31FC: 29 03        AND #$03
C0/31FE: C5 08        CMP $08
C0/3200: D0 03        BNE $3205
C0/3202: 4C 30 32     JMP $3230
C0/3205: AD DB 0A     LDA $0ADB
C0/3208: 0A           ASL 
C0/3209: 0A           ASL 
C0/320A: AA           TAX 
C0/320B: BF 9E 32 C0  LDA $C0329E,X
C0/320F: A8           TAY 
C0/3210: 20 4B 32     JSR $324B
C0/3213: C9 FF        CMP #$FF
C0/3215: F0 16        BEQ $322D
C0/3217: 20 89 32     JSR $3289
C0/321A: BD 7B 14     LDA $147B,X
C0/321D: 30 0E        BMI $322D
C0/321F: BD 7C 14     LDA $147C,X
C0/3222: 4A           LSR 
C0/3223: 29 03        AND #$03
C0/3225: CD DB 0A     CMP $0ADB
C0/3228: D0 03        BNE $322D
C0/322A: 4C 30 32     JMP $3230
C0/322D: 4C 4A 32     JMP $324A
C0/3230: BD 7E 14     LDA $147E,X     ; check if object faces party when active
C0/3233: 30 0B        BMI $3240
C0/3235: AD DB 0A     LDA $0ADB       ; party facing direction
C0/3238: 1A           INC 
C0/3239: 1A           INC 
C0/323A: 29 03        AND #$03
C0/323C: 0A           ASL 
C0/323D: 9D 7C 14     STA $147C,X     ; set graphic frame
C0/3240: DA           PHX 
C0/3241: 20 B3 39     JSR $39B3       ; update object sprites
C0/3244: FA           PLX 
C0/3245: 20 95 2F     JSR $2F95       ; execute npc script
C0/3248: 64 E4        STZ $E4         ; 
C0/324A: 60           RTS 

; [ get object at tile ]

; Y: pointer to tile properties

C0/324B: AD FA 10     LDA $10FA       ; map tile properties byte 1
C0/324E: 29 04        AND #$04
C0/3250: F0 0F        BEQ $3261       ; branch if not a bridge tile

; party is on a bridge tile
C0/3252: A5 C3        LDA $C3
C0/3254: 29 01        AND #$01
C0/3256: F0 2E        BEQ $3286       ; ignore object if party is below bridge
C0/3258: B9 F2 10     LDA $10F2,Y     ; map tile properties byte 1
C0/325B: 29 01        AND #$01
C0/325D: F0 27        BEQ $3286       ; ignore if tile is not passable to upper z-level
C0/325F: 80 1B        BRA $327C

; party is not on a bridge tile
C0/3261: B9 F2 10     LDA $10F2,Y     ; map tile properties byte 1
C0/3264: 29 04        AND #$04
C0/3266: F0 09        BEQ $3271       ; branch if target tile is not a bridge tile
C0/3268: A5 C2        LDA $C2
C0/326A: 29 01        AND #$01
C0/326C: F0 18        BEQ $3286
C0/326E: 4C 7C 32     JMP $327C
C0/3271: B9 F2 10     LDA $10F2,Y     ; map tile properties byte 1
C0/3274: 29 03        AND #$03
C0/3276: F0 04        BEQ $327C
C0/3278: 25 C2        AND $C2
C0/327A: F0 0A        BEQ $3286
C0/327C: B9 D8 10     LDA $10D8,Y
C0/327F: F0 05        BEQ $3286
C0/3281: C9 FF        CMP #$FF
C0/3283: F0 01        BEQ $3286
C0/3285: 60           RTS 
C0/3286: A9 FF        LDA #$FF        ; no object
C0/3288: 60           RTS 

; [ get pointer to object data ]

C0/3289: 29 7F        AND #$7F
C0/328B: 8D 02 42     STA $4202
C0/328E: A9 14        LDA #$14
C0/3290: 8D 03 42     STA $4203
C0/3293: EA           NOP 
C0/3294: EA           NOP 
C0/3295: EA           NOP 
C0/3296: EA           NOP 
C0/3297: AE 16 42     LDX $4216
C0/329A: 60           RTS 

; pointers to tiles in direction (forward, forward/left, forward/right, forward x2 )
C0/329B: 02 00 04 12
C0/329F: 0A 04 10 16
C0/32A3: 0E 10 0C 18
C0/32A7: 06 0C 00 14

; [ update objects ]

C0/32AB: A5 E6        LDA $E6         ; number of objects
C0/32AD: D0 01        BNE $32B0       ; return if there are no objects
C0/32AF: 60           RTS 
C0/32B0: 64 E5        STZ $E5         ; current object
C0/32B2: A4 06        LDY $06
C0/32B4: 84 E9        STY $E9         ; pointer to current object
C0/32B6: A4 E9        LDY $E9
C0/32B8: B9 7E 14     LDA $147E,Y
C0/32BB: 29 04        AND #$04
C0/32BD: F0 0B        BEQ $32CA       ; branch if object is not stationary
C0/32BF: B9 7B 14     LDA $147B,Y
C0/32C2: 09 80        ORA #$80
C0/32C4: 99 7B 14     STA $147B,Y     ; object does not move
C0/32C7: 4C 8A 34     JMP $348A
C0/32CA: B9 7E 14     LDA $147E,Y     ; 
C0/32CD: 29 08        AND #$08
C0/32CF: D0 08        BNE $32D9
C0/32D1: B9 7D 14     LDA $147D,Y
C0/32D4: 10 03        BPL $32D9
C0/32D6: 4C B9 34     JMP $34B9
C0/32D9: B9 7D 14     LDA $147D,Y
C0/32DC: 29 7F        AND #$7F
C0/32DE: F0 03        BEQ $32E3
C0/32E0: 4C B9 34     JMP $34B9
C0/32E3: B9 85 14     LDA $1485,Y
C0/32E6: 29 FD        AND #$FD
C0/32E8: 99 85 14     STA $1485,Y
C0/32EB: A5 E4        LDA $E4
C0/32ED: F0 10        BEQ $32FF
C0/32EF: 29 7F        AND #$7F
C0/32F1: C5 E5        CMP $E5
C0/32F3: D0 0A        BNE $32FF
C0/32F5: 64 E4        STZ $E4
C0/32F7: B9 85 14     LDA $1485,Y
C0/32FA: 09 02        ORA #$02
C0/32FC: 99 85 14     STA $1485,Y
C0/32FF: C2 20        REP #$20
C0/3301: B9 77 14     LDA $1477,Y
C0/3304: 29 00 3F     AND #$3F00
C0/3307: EB           XBA 
C0/3308: 85 0D        STA $0D
C0/330A: B9 79 14     LDA $1479,Y
C0/330D: 4A           LSR 
C0/330E: 4A           LSR 
C0/330F: 29 C0 0F     AND #$0FC0
C0/3312: 05 0D        ORA $0D
C0/3314: AA           TAX 
C0/3315: A8           TAY 
C0/3316: A5 06        LDA $06
C0/3318: E2 20        SEP #$20
C0/331A: A9 7F        LDA #$7F
C0/331C: 48           PHA 
C0/331D: AB           PLB 
C0/331E: C2 20        REP #$20
C0/3320: BD 00 30     LDA $3000,X     ; bg1 tile
C0/3323: 85 F5        STA $F5
C0/3325: BD 00 00     LDA $0000,X     ; object
C0/3328: 85 EB        STA $EB
C0/332A: 98           TYA 
C0/332B: 38           SEC 
C0/332C: E9 40 00     SBC #$0040
C0/332F: 29 FF 0F     AND #$0FFF
C0/3332: AA           TAX 
C0/3333: BD 00 30     LDA $3000,X
C0/3336: 85 F7        STA $F7
C0/3338: BD 00 00     LDA $0000,X
C0/333B: 85 ED        STA $ED
C0/333D: 98           TYA 
C0/333E: 29 C0 0F     AND #$0FC0
C0/3341: 85 0D        STA $0D
C0/3343: 98           TYA 
C0/3344: 3A           DEC 
C0/3345: 29 3F 00     AND #$003F
C0/3348: 05 0D        ORA $0D
C0/334A: AA           TAX 
C0/334B: BD 00 30     LDA $3000,X
C0/334E: 85 FD        STA $FD
C0/3350: BD 00 00     LDA $0000,X
C0/3353: 85 F3        STA $F3
C0/3355: 98           TYA 
C0/3356: 29 C0 0F     AND #$0FC0
C0/3359: 85 0D        STA $0D
C0/335B: 98           TYA 
C0/335C: 1A           INC 
C0/335D: 29 3F 00     AND #$003F
C0/3360: 05 0D        ORA $0D
C0/3362: AA           TAX 
C0/3363: BD 00 30     LDA $3000,X
C0/3366: 85 F9        STA $F9
C0/3368: BD 00 00     LDA $0000,X
C0/336B: 85 EF        STA $EF
C0/336D: 98           TYA 
C0/336E: 18           CLC 
C0/336F: 69 40 00     ADC #$0040
C0/3372: 29 FF 0F     AND #$0FFF
C0/3375: AA           TAX 
C0/3376: BD 00 30     LDA $3000,X
C0/3379: 85 FB        STA $FB
C0/337B: BD 00 00     LDA $0000,X
C0/337E: 85 F1        STA $F1
C0/3380: A5 06        LDA $06
C0/3382: E2 20        SEP #$20
C0/3384: A9 00        LDA #$00
C0/3386: 48           PHA 
C0/3387: AB           PLB 
C0/3388: A5 EB        LDA $EB
C0/338A: C2 20        REP #$20
C0/338C: 29 FF 00     AND #$00FF
C0/338F: 0A           ASL 
C0/3390: AA           TAX 
C0/3391: A5 06        LDA $06
C0/3393: E2 20        SEP #$20
C0/3395: BD 86 11     LDA $1186,X     ; tile properties byte 1
C0/3398: 29 83        AND #$83
C0/339A: 85 0C        STA $0C         ; $0C = z-level and npc passability
C0/339C: BD 87 11     LDA $1187,X     ; tile properties byte 2
C0/339F: 29 0F        AND #$0F
C0/33A1: 85 0B        STA $0B         ; $0B = direction passability
C0/33A3: A4 E9        LDY $E9
C0/33A5: B9 7B 14     LDA $147B,Y     ; 
C0/33A8: 29 7F        AND #$7F
C0/33AA: 99 7B 14     STA $147B,Y
C0/33AD: B9 85 14     LDA $1485,Y
C0/33B0: 10 10        BPL $33C2       ; branch if random movement does not depend on party position
C0/33B2: 29 40        AND #$40
C0/33B4: D0 06        BNE $33BC
C0/33B6: 20 1C 35     JSR $351C       ; move toward party
C0/33B9: 4C 2C 34     JMP $342C
C0/33BC: 20 55 35     JSR $3555       ; move away from party
C0/33BF: 4C 2C 34     JMP $342C
C0/33C2: B9 85 14     LDA $1485,Y     ; movement type
C0/33C5: 29 30        AND #$30
C0/33C7: D0 63        BNE $342C       ; branch if object has custom movement
C0/33C9: B9 7B 14     LDA $147B,Y
C0/33CC: 29 7F        AND #$7F
C0/33CE: D0 0B        BNE $33DB       ; branch if already moving
C0/33D0: 20 2B 4F     JSR $4F2B       ; generate random number
C0/33D3: 29 03        AND #$03
C0/33D5: 1A           INC 
C0/33D6: 99 7B 14     STA $147B,Y     ; random movement direction
C0/33D9: 80 51        BRA $342C
C0/33DB: 20 2B 4F     JSR $4F2B       ; generate random number
C0/33DE: C9 20        CMP #$20
C0/33E0: B0 4A        BCS $342C
C0/33E2: B9 7B 14     LDA $147B,Y
C0/33E5: 4A           LSR 
C0/33E6: 90 22        BCC $340A
C0/33E8: 20 2B 4F     JSR $4F2B       ; generate random number
C0/33EB: 4A           LSR 
C0/33EC: B0 0E        BCS $33FC
C0/33EE: A2 04 00     LDX #$0004
C0/33F1: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/33F4: F0 36        BEQ $342C
C0/33F6: 99 7B 14     STA $147B,Y
C0/33F9: 4C 8A 34     JMP $348A
C0/33FC: A2 08 00     LDX #$0008
C0/33FF: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/3402: F0 28        BEQ $342C
C0/3404: 99 7B 14     STA $147B,Y
C0/3407: 4C 8A 34     JMP $348A
C0/340A: 20 2B 4F     JSR $4F2B       ; generate random number
C0/340D: 4A           LSR 
C0/340E: B0 0E        BCS $341E
C0/3410: A2 02 00     LDX #$0002
C0/3413: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/3416: F0 14        BEQ $342C
C0/3418: 99 7B 14     STA $147B,Y
C0/341B: 4C 8A 34     JMP $348A
C0/341E: A2 06 00     LDX #$0006
C0/3421: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/3424: F0 06        BEQ $342C
C0/3426: 99 7B 14     STA $147B,Y
C0/3429: 4C 8A 34     JMP $348A
C0/342C: B9 7B 14     LDA $147B,Y     ; facing direction
C0/342F: 0A           ASL 
C0/3430: AA           TAX 
C0/3431: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/3434: D0 54        BNE $348A
C0/3436: B9 85 14     LDA $1485,Y     ; movement type
C0/3439: 29 30        AND #$30
C0/343B: C9 10        CMP #$10
C0/343D: F0 2C        BEQ $346B       ; branch if object moves in a circle
C0/343F: C9 30        CMP #$30
C0/3441: F0 16        BEQ $3459       ; branch if object moves in a straight line

; move back and forth
C0/3443: B9 7B 14     LDA $147B,Y     ; facing direction
C0/3446: 3A           DEC 
C0/3447: 18           CLC 
C0/3448: 69 02        ADC #$02        ; reverse direction
C0/344A: 29 03        AND #$03
C0/344C: 1A           INC 
C0/344D: 0A           ASL 
C0/344E: AA           TAX 
C0/344F: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/3452: F0 2B        BEQ $347F
C0/3454: 99 7B 14     STA $147B,Y
C0/3457: 80 31        BRA $348A

; move in a straight line
C0/3459: B9 7B 14     LDA $147B,Y     ; facing direction
C0/345C: 29 03        AND #$03
C0/345E: 1A           INC 
C0/345F: 0A           ASL 
C0/3460: AA           TAX 
C0/3461: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/3464: F0 19        BEQ $347F
C0/3466: 99 7B 14     STA $147B,Y
C0/3469: 80 1F        BRA $348A

; move in a circle
C0/346B: B9 7B 14     LDA $147B,Y     ; facing direction
C0/346E: 3A           DEC 
C0/346F: 3A           DEC 
C0/3470: 29 03        AND #$03
C0/3472: 1A           INC 
C0/3473: 0A           ASL 
C0/3474: AA           TAX 
C0/3475: 20 EB 34     JSR $34EB       ; check if npc can move to tile
C0/3478: F0 05        BEQ $347F
C0/347A: 99 7B 14     STA $147B,Y
C0/347D: 80 0B        BRA $348A
C0/347F: B9 7B 14     LDA $147B,Y
C0/3482: 09 80        ORA #$80
C0/3484: 99 7B 14     STA $147B,Y
C0/3487: 4C B9 34     JMP $34B9
C0/348A: B9 85 14     LDA $1485,Y
C0/348D: 4A           LSR 
C0/348E: B0 03        BCS $3493
C0/3490: 4C B9 34     JMP $34B9
C0/3493: A4 E9        LDY $E9
C0/3495: 20 F8 3C     JSR $3CF8       ; remove object from object layout
C0/3498: B9 7B 14     LDA $147B,Y
C0/349B: 10 02        BPL $349F
C0/349D: A9 00        LDA #$00
C0/349F: 29 7F        AND #$7F
C0/34A1: AA           TAX 
C0/34A2: B9 78 14     LDA $1478,Y
C0/34A5: 18           CLC 
C0/34A6: 7F E1 34 C0  ADC $C034E1,X
C0/34AA: 85 75        STA $75
C0/34AC: B9 7A 14     LDA $147A,Y
C0/34AF: 18           CLC 
C0/34B0: 7F E6 34 C0  ADC $C034E6,X
C0/34B4: 85 76        STA $76
C0/34B6: 20 E0 3C     JSR $3CE0       ; add object to object layout
C0/34B9: A4 E9        LDY $E9
C0/34BB: B9 7B 14     LDA $147B,Y
C0/34BE: 29 7F        AND #$7F
C0/34C0: F0 05        BEQ $34C7
C0/34C2: 3A           DEC 
C0/34C3: 0A           ASL 
C0/34C4: 99 7C 14     STA $147C,Y
C0/34C7: C2 20        REP #$20       ; next object
C0/34C9: A5 E9        LDA $E9
C0/34CB: 18           CLC 
C0/34CC: 69 14 00     ADC #$0014
C0/34CF: 85 E9        STA $E9
C0/34D1: A5 06        LDA $06
C0/34D3: E2 20        SEP #$20
C0/34D5: E6 E5        INC $E5
C0/34D7: A5 E5        LDA $E5
C0/34D9: C5 E6        CMP $E6
C0/34DB: F0 03        BEQ $34E0
C0/34DD: 4C B6 32     JMP $32B6
C0/34E0: 60           RTS 

C0/34E1: 00 00 01 00 FF
C0/34E6: 00 FF 00 01 00

; [ check if npc can move to tile ]

; X: direction
; A: movement direction (out, zero if can't move)

C0/34EB: B5 EB        LDA $EB,X       ; bg1 tile
C0/34ED: DA           PHX 
C0/34EE: C2 20        REP #$20
C0/34F0: 29 FF 00     AND #$00FF
C0/34F3: 0A           ASL 
C0/34F4: AA           TAX 
C0/34F5: A5 06        LDA $06
C0/34F7: E2 20        SEP #$20
C0/34F9: BD 86 11     LDA $1186,X     ; tile properties
C0/34FC: FA           PLX 
C0/34FD: 29 83        AND #$83
C0/34FF: C5 0C        CMP $0C         ; check z-level and npc passability
C0/3501: D0 11        BNE $3514
C0/3503: B5 F5        LDA $F5,X       ; object at tile
C0/3505: D0 0D        BNE $3514
C0/3507: 8A           TXA 
C0/3508: 4A           LSR 
C0/3509: AA           TAX 
C0/350A: A5 0B        LDA $0B         ; check direction passability
C0/350C: 3F 17 35 C0  AND $C03517,X
C0/3510: F0 02        BEQ $3514
C0/3512: 8A           TXA             ; can move (return movement direction)
C0/3513: 60           RTS 
C0/3514: A9 00        LDA #$00        ; can't move
C0/3516: 60           RTS 

C0/3517: 00 08 01 04 02

; [ move toward party ]

C0/351C: A4 E9        LDY $E9
C0/351E: B9 78 14     LDA $1478,Y
C0/3521: CD D8 0A     CMP $0AD8
C0/3524: B0 10        BCS $3536
C0/3526: B9 7A 14     LDA $147A,Y
C0/3529: CD D9 0A     CMP $0AD9
C0/352C: B0 04        BCS $3532
C0/352E: A9 01        LDA #$01
C0/3530: 80 12        BRA $3544
C0/3532: A9 00        LDA #$00
C0/3534: 80 0E        BRA $3544
C0/3536: B9 7A 14     LDA $147A,Y
C0/3539: CD D9 0A     CMP $0AD9
C0/353C: B0 04        BCS $3542
C0/353E: A9 02        LDA #$02
C0/3540: 80 02        BRA $3544
C0/3542: A9 03        LDA #$03
C0/3544: 85 08        STA $08
C0/3546: 20 2B 4F     JSR $4F2B       ; generate random number
C0/3549: 29 01        AND #$01
C0/354B: 18           CLC 
C0/354C: 65 08        ADC $08
C0/354E: 29 03        AND #$03
C0/3550: 1A           INC 
C0/3551: 99 7B 14     STA $147B,Y
C0/3554: 60           RTS 

; [ move away from party ]

C0/3555: A4 E9        LDY $E9
C0/3557: B9 78 14     LDA $1478,Y     ; object x position
C0/355A: CD D8 0A     CMP $0AD8
C0/355D: B0 10        BCS $356F       ; branch if greater than party x position
C0/355F: B9 7A 14     LDA $147A,Y
C0/3562: CD D9 0A     CMP $0AD9
C0/3565: B0 04        BCS $356B
C0/3567: A9 03        LDA #$03
C0/3569: 80 12        BRA $357D
C0/356B: A9 02        LDA #$02
C0/356D: 80 0E        BRA $357D
C0/356F: B9 7A 14     LDA $147A,Y
C0/3572: CD D9 0A     CMP $0AD9
C0/3575: B0 04        BCS $357B
C0/3577: A9 00        LDA #$00
C0/3579: 80 02        BRA $357D
C0/357B: A9 01        LDA #$01
C0/357D: 85 08        STA $08
C0/357F: 20 2B 4F     JSR $4F2B       ; generate random number
C0/3582: 29 01        AND #$01
C0/3584: 18           CLC 
C0/3585: 65 08        ADC $08
C0/3587: 29 03        AND #$03
C0/3589: 1A           INC 
C0/358A: 99 7B 14     STA $147B,Y
C0/358D: 60           RTS 

; [ update hiryuu sprites ]

C0/358E: AD 9F 16     LDA $169F
C0/3591: F0 07        BEQ $359A       ; return if no hiryuu
C0/3593: AD 85 14     LDA $1485
C0/3596: 29 01        AND #$01
C0/3598: D0 01        BNE $359B
C0/359A: 60           RTS 
C0/359B: A9 AA        LDA #$AA
C0/359D: 8D 00 04     STA $0400
C0/35A0: 8D 01 04     STA $0401
C0/35A3: 8D 02 04     STA $0402
C0/35A6: 8D 03 04     STA $0403
C0/35A9: A9 A0        LDA #$A0
C0/35AB: 8D 1F 04     STA $041F
C0/35AE: AD 7C 14     LDA $147C
C0/35B1: 4A           LSR 
C0/35B2: 4A           LSR 
C0/35B3: 4A           LSR 
C0/35B4: 85 0C        STA $0C
C0/35B6: AD 7E 14     LDA $147E
C0/35B9: 29 04        AND #$04
C0/35BB: F0 08        BEQ $35C5
C0/35BD: A9 01        LDA #$01
C0/35BF: 85 0C        STA $0C
C0/35C1: A9 07        LDA #$07
C0/35C3: 80 30        BRA $35F5
C0/35C5: AD 85 14     LDA $1485
C0/35C8: 29 08        AND #$08
C0/35CA: F0 11        BEQ $35DD
C0/35CC: AD 7B 14     LDA $147B
C0/35CF: F0 24        BEQ $35F5
C0/35D1: AD 79 14     LDA $1479
C0/35D4: 29 80        AND #$80
C0/35D6: 18           CLC 
C0/35D7: 2A           ROL 
C0/35D8: 2A           ROL 
C0/35D9: 69 08        ADC #$08
C0/35DB: 80 18        BRA $35F5
C0/35DD: AD 85 14     LDA $1485
C0/35E0: 10 0E        BPL $35F0
C0/35E2: A5 3E        LDA $3E
C0/35E4: 4A           LSR 
C0/35E5: 4A           LSR 
C0/35E6: 4A           LSR 
C0/35E7: 29 03        AND #$03
C0/35E9: AA           TAX 
C0/35EA: BF BD 37 C0  LDA $C037BD,X
C0/35EE: 80 05        BRA $35F5
C0/35F0: AD 7C 14     LDA $147C       ; body frame
C0/35F3: 29 07        AND #$07
C0/35F5: C2 20        REP #$20
C0/35F7: 0A           ASL 
C0/35F8: 0A           ASL 
C0/35F9: 0A           ASL 
C0/35FA: 0A           ASL 
C0/35FB: 85 23        STA $23
C0/35FD: 0A           ASL 
C0/35FE: 18           CLC 
C0/35FF: 65 23        ADC $23
C0/3601: AA           TAX 
C0/3602: AD 77 14     LDA $1477
C0/3605: 4A           LSR 
C0/3606: 4A           LSR 
C0/3607: 4A           LSR 
C0/3608: 18           CLC 
C0/3609: 69 10 00     ADC #$0010
C0/360C: 38           SEC 
C0/360D: E5 61        SBC $61
C0/360F: 85 13        STA $13
C0/3611: AD 79 14     LDA $1479
C0/3614: 4A           LSR 
C0/3615: 4A           LSR 
C0/3616: 4A           LSR 
C0/3617: 18           CLC 
C0/3618: 69 18 00     ADC #$0018
C0/361B: 38           SEC 
C0/361C: E5 63        SBC $63
C0/361E: 85 15        STA $15
C0/3620: AD 88 14     LDA $1488
C0/3623: F0 2D        BEQ $3652
C0/3625: AD 85 14     LDA $1485
C0/3628: 29 04 00     AND #$0004
C0/362B: D0 09        BNE $3636
C0/362D: AD 88 14     LDA $1488
C0/3630: 29 FF 00     AND #$00FF
C0/3633: 4A           LSR 
C0/3634: 80 08        BRA $363E
C0/3636: AD 88 14     LDA $1488
C0/3639: 29 FF 00     AND #$00FF
C0/363C: 4A           LSR 
C0/363D: 4A           LSR 
C0/363E: DA           PHX 
C0/363F: AA           TAX 
C0/3640: BF DB 22 C0  LDA $C022DB,X
C0/3644: FA           PLX 
C0/3645: 29 FF 00     AND #$00FF
C0/3648: 0A           ASL 
C0/3649: 85 0F        STA $0F
C0/364B: A5 15        LDA $15
C0/364D: 38           SEC 
C0/364E: E5 0F        SBC $0F
C0/3650: 85 15        STA $15
C0/3652: A5 06        LDA $06
C0/3654: A8           TAY 
C0/3655: E2 20        SEP #$20
C0/3657: C2 20        REP #$20
C0/3659: C0 00 00     CPY #$0000
C0/365C: D0 13        BNE $3671
C0/365E: A5 0C        LDA $0C
C0/3660: 29 07 00     AND #$0007
C0/3663: DA           PHX 
C0/3664: 0A           ASL 
C0/3665: AA           TAX 
C0/3666: BF C9 37 C0  LDA $C037C9,X
C0/366A: FA           PLX 
C0/366B: 1F D5 37 C0  ORA $C037D5,X
C0/366F: 80 04        BRA $3675
C0/3671: BF D5 37 C0  LDA $C037D5,X
C0/3675: 99 02 02     STA $0202,Y
C0/3678: 29 FF 01     AND #$01FF
C0/367B: F0 39        BEQ $36B6
C0/367D: BF D3 37 C0  LDA $C037D3,X
C0/3681: 29 FF 00     AND #$00FF
C0/3684: C9 80 00     CMP #$0080
C0/3687: 90 03        BCC $368C
C0/3689: 09 00 FF     ORA #$FF00
C0/368C: 65 13        ADC $13
C0/368E: 29 FF 07     AND #$07FF
C0/3691: C9 00 02     CMP #$0200
C0/3694: B0 20        BCS $36B6
C0/3696: 4A           LSR 
C0/3697: 38           SEC 
C0/3698: E9 08 00     SBC #$0008
C0/369B: 85 0D        STA $0D
C0/369D: BF D4 37 C0  LDA $C037D4,X
C0/36A1: 29 FF 00     AND #$00FF
C0/36A4: C9 80 00     CMP #$0080
C0/36A7: 90 03        BCC $36AC
C0/36A9: 09 00 FF     ORA #$FF00
C0/36AC: 65 15        ADC $15
C0/36AE: 29 FF 07     AND #$07FF
C0/36B1: C9 E0 01     CMP #$01E0
C0/36B4: 90 07        BCC $36BD
C0/36B6: A9 F0 00     LDA #$00F0
C0/36B9: 85 0F        STA $0F
C0/36BB: 80 18        BRA $36D5
C0/36BD: 4A           LSR 
C0/36BE: 38           SEC 
C0/36BF: E9 10 00     SBC #$0010
C0/36C2: 85 0F        STA $0F
C0/36C4: C0 00 00     CPY #$0000
C0/36C7: D0 0C        BNE $36D5
C0/36C9: A5 0C        LDA $0C
C0/36CB: 29 08 00     AND #$0008
C0/36CE: 4A           LSR 
C0/36CF: 4A           LSR 
C0/36D0: 18           CLC 
C0/36D1: 65 0F        ADC $0F
C0/36D3: 85 0F        STA $0F
C0/36D5: A5 06        LDA $06
C0/36D7: E2 20        SEP #$20
C0/36D9: A5 0D        LDA $0D
C0/36DB: C9 F8        CMP #$F8
C0/36DD: 90 1A        BCC $36F9
C0/36DF: DA           PHX 
C0/36E0: 5A           PHY 
C0/36E1: 98           TYA 
C0/36E2: 4A           LSR 
C0/36E3: 4A           LSR 
C0/36E4: 29 03        AND #$03
C0/36E6: AA           TAX 
C0/36E7: 98           TYA 
C0/36E8: 4A           LSR 
C0/36E9: 4A           LSR 
C0/36EA: 4A           LSR 
C0/36EB: 4A           LSR 
C0/36EC: A8           TAY 
C0/36ED: B9 00 04     LDA $0400,Y
C0/36F0: 1F B9 37 C0  ORA $C037B9,X
C0/36F4: 99 00 04     STA $0400,Y
C0/36F7: 7A           PLY 
C0/36F8: FA           PLX 
C0/36F9: A5 0D        LDA $0D
C0/36FB: 99 00 02     STA $0200,Y
C0/36FE: A5 0F        LDA $0F
C0/3700: 99 01 02     STA $0201,Y
C0/3703: E8           INX 
C0/3704: E8           INX 
C0/3705: E8           INX 
C0/3706: E8           INX 
C0/3707: C8           INY 
C0/3708: C8           INY 
C0/3709: C8           INY 
C0/370A: C8           INY 
C0/370B: C0 30 00     CPY #$0030
C0/370E: F0 03        BEQ $3713
C0/3710: 4C 57 36     JMP $3657
C0/3713: C2 20        REP #$20
C0/3715: AD 8B 14     LDA $148B
C0/3718: 4A           LSR 
C0/3719: 4A           LSR 
C0/371A: 4A           LSR 
C0/371B: 18           CLC 
C0/371C: 69 10 00     ADC #$0010
C0/371F: 38           SEC 
C0/3720: E5 61        SBC $61
C0/3722: 85 13        STA $13
C0/3724: AD 8D 14     LDA $148D       ; poison damage
C0/3727: 4A           LSR 
C0/3728: 4A           LSR 
C0/3729: 4A           LSR 
C0/372A: 18           CLC 
C0/372B: 69 18 00     ADC #$0018
C0/372E: 38           SEC 
C0/372F: E5 63        SBC $63
C0/3731: 85 15        STA $15
C0/3733: A5 06        LDA $06
C0/3735: E2 20        SEP #$20
C0/3737: A6 06        LDX $06
C0/3739: A4 06        LDY $06
C0/373B: C2 20        REP #$20
C0/373D: BF C3 37 C0  LDA $C037C3,X
C0/3741: 99 FA 03     STA $03FA,Y
C0/3744: BF C1 37 C0  LDA $C037C1,X
C0/3748: 29 FF 00     AND #$00FF
C0/374B: C9 80 00     CMP #$0080
C0/374E: 90 03        BCC $3753
C0/3750: 09 00 FF     ORA #$FF00
C0/3753: 65 13        ADC $13
C0/3755: 29 FF 07     AND #$07FF
C0/3758: C9 00 02     CMP #$0200
C0/375B: B0 18        BCS $3775
C0/375D: 4A           LSR 
C0/375E: 38           SEC 
C0/375F: E9 08 00     SBC #$0008
C0/3762: 85 0D        STA $0D
C0/3764: BF C2 37 C0  LDA $C037C2,X
C0/3768: 29 FF 00     AND #$00FF
C0/376B: 65 15        ADC $15
C0/376D: 29 FF 07     AND #$07FF
C0/3770: C9 E0 01     CMP #$01E0
C0/3773: 90 07        BCC $377C
C0/3775: A9 F0 00     LDA #$00F0
C0/3778: 85 0F        STA $0F
C0/377A: 80 07        BRA $3783
C0/377C: 4A           LSR 
C0/377D: 38           SEC 
C0/377E: E9 10 00     SBC #$0010
C0/3781: 85 0F        STA $0F
C0/3783: A5 06        LDA $06
C0/3785: E2 20        SEP #$20
C0/3787: A5 0D        LDA $0D
C0/3789: C9 F8        CMP #$F8
C0/378B: 90 14        BCC $37A1
C0/378D: C0 00 00     CPY #$0000
C0/3790: D0 07        BNE $3799
C0/3792: AD 1F 04     LDA $041F
C0/3795: 09 10        ORA #$10
C0/3797: 80 05        BRA $379E
C0/3799: AD 1F 04     LDA $041F
C0/379C: 09 40        ORA #$40
C0/379E: 8D 1F 04     STA $041F
C0/37A1: A5 0D        LDA $0D
C0/37A3: 99 F8 03     STA $03F8,Y
C0/37A6: A5 0F        LDA $0F
C0/37A8: 99 F9 03     STA $03F9,Y
C0/37AB: C8           INY 
C0/37AC: C8           INY 
C0/37AD: C8           INY 
C0/37AE: C8           INY 
C0/37AF: E8           INX 
C0/37B0: E8           INX 
C0/37B1: E8           INX 
C0/37B2: E8           INX 
C0/37B3: C0 08 00     CPY #$0008
C0/37B6: D0 83        BNE $373B
C0/37B8: 60           RTS 

C0/37B9:              .DB $01, $04, $10, $40

C0/37BD: 05 04        ORA $04
C0/37BF: 06 06        ASL $06

C0/37C1: F0 0A BE 34
C0/37C5: 10 0A BE 74

C0/37C9: B6 34 BA 34 BC 34 BA 74 B8 34

; hiryuu sprite data (8 frames, 12 sprites per frame, 4 bytes per sprite)
C0/37D3: 00 E8 00 00
C0/37D7: F0 E0 50 34
C0/37DB: 10 E0 50 74
C0/37DF: F0 00 52 34
C0/37E3: 10 00 52 74
C0/37E7: 00 00 00 34
C0/37EB: 00 00 00 34
C0/37EF: 00 00 00 34
C0/37F3: 00 00 00 34
C0/37F7: 00 00 00 34
C0/37FB: 00 00 00 34
C0/37FF: 00 00 00 34

C0/3803: 00 E8 00 00
C0/3807: D0 E0 54 34
C0/380B: F0 E0 58 34
C0/380F: 10 E0 58 74
C0/3813: 30 E0 54 74
C0/3817: D0 00 56 34
C0/381B: F0 00 5A 34
C0/381F: 10 00 5A 74
C0/3823: 30 00 56 74
C0/3827: 00 00 00 34
C0/382B: 00 00 00 34
C0/382F: 00 00 00 34

C0/3833: 00 E8 00 00
C0/3837: F0 C0 70 34
C0/383B: 10 C0 70 74
C0/383F: D0 D0 5C 34
C0/3843: 30 D0 5C 74
C0/3847: F0 E0 72 34
C0/384B: 10 E0 72 74
C0/384F: D0 F0        BNE $3841
C0/3851: 5E 34 30     LSR $3034,X
C0/3854: F0 5E        BEQ $38B4
C0/3856: 74 F0        STZ $F0,X
C0/3858: 00 74        BRK $74
C0/385A: 34 10        BIT $10,X
C0/385C: 00 74        BRK $74
C0/385E: 74 00        STZ $00,X
C0/3860: 00 00        BRK $00
C0/3862: 34

C0/3863: 00 E0 00 00
C0/3867: F0 D0        BEQ $3839
C0/3869: 7C 34 10     JMP ($1034,X)
C0/386C: D0 7C        BNE $38EA
C0/386E: 74 D0        STZ $D0,X
C0/3870: E0 7A 34     CPX #$347A
C0/3873: 30 E0        BMI $3855
C0/3875: 7A           PLY 
C0/3876: 74 F0        STZ $F0,X
C0/3878: F0 7E        BEQ $38F8
C0/387A: 34 10        BIT $10,X
C0/387C: F0 7E        BEQ $38FC
C0/387E: 74 03        STZ $03,X
C0/3880: 00 96        BRK $96
C0/3882: 34 00        BIT $00,X
C0/3884: 00 00        BRK $00
C0/3886: 34 00        BIT $00,X
C0/3888: 00 00        BRK $00
C0/388A: 34 00        BIT $00,X
C0/388C: 00 00        BRK $00
C0/388E: 34 00        BIT $00,X
C0/3890: 00 00        BRK $00
C0/3892: 34

C0/3893: 00 D0 00 00
C0/3897: F0 BC 92 34
C0/389B: 10 BC        BPL $3859
C0/389D: 92 74        STA ($74)
C0/389F: D0 DC        BNE $387D
C0/38A1: 90 34        BCC $38D7
C0/38A3: F0 DC        BEQ $3881
C0/38A5: 94 34        STY $34,X
C0/38A7: 10 DC        BPL $3885
C0/38A9: 94 74        STY $74,X
C0/38AB: 30 DC        BMI $3889
C0/38AD: 90 74        BCC $3923
C0/38AF: 00 FC        BRK $FC
C0/38B1: 96 34        STX $34,Y
C0/38B3: 00 00        BRK $00
C0/38B5: 00 34        BRK $34
C0/38B7: 00 00        BRK $00
C0/38B9: 00 34        BRK $34
C0/38BB: 00 00        BRK $00
C0/38BD: 00 34        BRK $34
C0/38BF: 00 00        BRK $00
C0/38C1: 00 34        BRK $34

C0/38C3: 00 CC 00 00
C0/38C7: F0 B8        BEQ $3881
C0/38C9: 9A           TXS 
C0/38CA: 34 10        BIT $10,X
C0/38CC: B8           CLV 
C0/38CD: 9A           TXS 
C0/38CE: 74 D0        STZ $D0,X
C0/38D0: D8           CLD 
C0/38D1: 98           TYA 
C0/38D2: 34 F0        BIT $F0,X
C0/38D4: D8           CLD 
C0/38D5: 9C 34 10     STZ $1034
C0/38D8: D8           CLD 
C0/38D9: 9C 74 30     STZ $3074
C0/38DC: D8           CLD 
C0/38DD: 98           TYA 
C0/38DE: 74 00        STZ $00,X
C0/38E0: F8           SED 
C0/38E1: 96 74        STX $74,Y
C0/38E3: 00 00        BRK $00
C0/38E5: 00 34        BRK $34
C0/38E7: 00 00        BRK $00
C0/38E9: 00 34        BRK $34
C0/38EB: 00 00        BRK $00
C0/38ED: 00 34        BRK $34
C0/38EF: 00 00        BRK $00
C0/38F1: 00 34        BRK $34

C0/38F3: 00 D4 00 00
C0/38F7: F0 C0 B0 34
C0/38FB: 10 C0 B0 74
C0/38FF: D0 D0        BNE $38D1
C0/3901: 9E 34 30     STZ $3034,X
C0/3904: D0 9E        BNE $38A4
C0/3906: 74 F0        STZ $F0,X
C0/3908: E0 B2 34     CPX #$34B2
C0/390B: 10 E0        BPL $38ED
C0/390D: B2 74        LDA ($74)
C0/390F: 00 00        BRK $00
C0/3911: 96 34        STX $34,Y
C0/3913: 00 00        BRK $00
C0/3915: 00 34        BRK $34
C0/3917: 00 00        BRK $00
C0/3919: 00 34        BRK $34
C0/391B: 00 00        BRK $00
C0/391D: 00 34        BRK $34
C0/391F: 00 00        BRK $00
C0/3921: 00 34        BRK $34

C0/3923: 00 00 00 00
C0/3927: 00 E0 B4 34
C0/392B: 00 00 76 34
C0/392F: F0 E0 50 34
C0/3933: 10 E0 50 74
C0/3937: F0 00 52 34
C0/393B: 10 00        BPL $393D
C0/393D: 52 74        EOR ($74)
C0/393F: 00 00        BRK $00
C0/3941: 00 34        BRK $34
C0/3943: 00 00        BRK $00
C0/3945: 00 34        BRK $34
C0/3947: 00 00        BRK $00
C0/3949: 00 34        BRK $34
C0/394B: 00 00        BRK $00
C0/394D: 00 34        BRK $34
C0/394F: 00 00        BRK $00
C0/3951: 00 34        BRK $34

C0/3953: 00 E8 00 00
C0/3957: F0 E0 50 34
C0/395B: 10 E0 50 74
C0/395F: F0 00 52 34
C0/3963: 10 00 78
C0/3966: 34 00        BIT $00,X
C0/3968: 00 00        BRK $00
C0/396A: 34 00        BIT $00,X
C0/396C: 00 00        BRK $00
C0/396E: 34 00        BIT $00,X
C0/3970: 00 00        BRK $00
C0/3972: 34 00        BIT $00,X
C0/3974: 00 00        BRK $00
C0/3976: 34 00        BIT $00,X
C0/3978: 00 00        BRK $00
C0/397A: 34 00        BIT $00,X
C0/397C: 00 00        BRK $00
C0/397E: 34 00        BIT $00,X
C0/3980: 00 00        BRK $00
C0/3982: 34

C0/3985: 00 E8 00 00
C0/3987: F0 E0 50 34
C0/398B: 10 E0 50 74
C0/398F: F0 00        BEQ $3991
C0/3991: 78           SEI 
C0/3992: 74 10        STZ $10,X
C0/3994: 00 52        BRK $52
C0/3996: 74 00        STZ $00,X
C0/3998: 00 00        BRK $00
C0/399A: 34 00        BIT $00,X
C0/399C: 00 00        BRK $00
C0/399E: 34 00        BIT $00,X
C0/39A0: 00 00        BRK $00
C0/39A2: 34 00        BIT $00,X
C0/39A4: 00 00        BRK $00
C0/39A6: 34 00        BIT $00,X
C0/39A8: 00 00        BRK $00
C0/39AA: 34 00        BIT $00,X
C0/39AC: 00 00        BRK $00
C0/39AE: 34 00        BIT $00,X
C0/39B0: 00 00        BRK $00
C0/39B2: 34 

; [ update object sprites ]

C0/39B3: A5 E6        LDA $E6
C0/39B5: D0 01        BNE $39B8
C0/39B7: 60           RTS 
C0/39B8: A4 06        LDY $06
C0/39BA: 84 E9        STY $E9
C0/39BC: 84 23        STY $23
C0/39BE: 64 E5        STZ $E5
C0/39C0: A5 E6        LDA $E6
C0/39C2: 48           PHA 
C0/39C3: A4 E9        LDY $E9
C0/39C5: AD 9F 16     LDA $169F
C0/39C8: F0 08        BEQ $39D2       ; branch if no hiryuu
C0/39CA: C0 28 00     CPY #$0028
C0/39CD: B0 03        BCS $39D2       ; skip 10 sprites
C0/39CF: 4C 67 3B     JMP $3B67
C0/39D2: B9 85 14     LDA $1485,Y
C0/39D5: 29 01        AND #$01
C0/39D7: D0 03        BNE $39DC
C0/39D9: 4C 67 3B     JMP $3B67
C0/39DC: B9 7E 14     LDA $147E,Y     ; animation type
C0/39DF: 29 70        AND #$70
C0/39E1: F0 28        BEQ $3A0B
C0/39E3: C9 50        CMP #$50
C0/39E5: F0 24        BEQ $3A0B

; special animation
C0/39E7: 4A           LSR 
C0/39E8: 4A           LSR 
C0/39E9: 85 08        STA $08
C0/39EB: B9 7E 14     LDA $147E,Y     ; animation speed
C0/39EE: 29 03        AND #$03
C0/39F0: AA           TAX 
C0/39F1: BF 88 3B C0  LDA $C03B88,X
C0/39F5: AA           TAX 
C0/39F6: A5 3E        LDA $3E
C0/39F8: 4A           LSR 
C0/39F9: CA           DEX 
C0/39FA: D0 FC        BNE $39F8
C0/39FC: 29 03        AND #$03
C0/39FE: 05 08        ORA $08
C0/3A00: AA           TAX 
C0/3A01: BF 8C 3B C0  LDA $C03B8C,X
C0/3A05: 18           CLC 
C0/3A06: 79 87 14     ADC $1487,Y     ; frame offset
C0/3A09: 80 55        BRA $3A60

; walking animation
C0/3A0B: B9 7C 14     LDA $147C,Y
C0/3A0E: 29 7F        AND #$7F
C0/3A10: C9 10        CMP #$10
C0/3A12: 90 04        BCC $3A18
C0/3A14: C9 40        CMP #$40
C0/3A16: 90 48        BCC $3A60
C0/3A18: B9 88 14     LDA $1488,Y
C0/3A1B: D0 2A        BNE $3A47
C0/3A1D: B9 85 14     LDA $1485,Y
C0/3A20: 29 08        AND #$08
C0/3A22: F0 23        BEQ $3A47
C0/3A24: 64 08        STZ $08
C0/3A26: B9 7E 14     LDA $147E,Y
C0/3A29: 29 08        AND #$08
C0/3A2B: D0 05        BNE $3A32
C0/3A2D: B9 7D 14     LDA $147D,Y
C0/3A30: 30 0C        BMI $3A3E
C0/3A32: B9 7D 14     LDA $147D,Y
C0/3A35: 29 20        AND #$20
C0/3A37: 18           CLC 
C0/3A38: 2A           ROL 
C0/3A39: 2A           ROL 
C0/3A3A: 2A           ROL 
C0/3A3B: 2A           ROL 
C0/3A3C: 85 08        STA $08
C0/3A3E: B9 7C 14     LDA $147C,Y
C0/3A41: 29 7F        AND #$7F
C0/3A43: 05 08        ORA $08
C0/3A45: 80 19        BRA $3A60
C0/3A47: B9 7C 14     LDA $147C,Y
C0/3A4A: 30 04        BMI $3A50
C0/3A4C: 29 7F        AND #$7F
C0/3A4E: 80 10        BRA $3A60
C0/3A50: B9 7D 14     LDA $147D,Y
C0/3A53: 29 20        AND #$20
C0/3A55: 4A           LSR 
C0/3A56: 4A           LSR 
C0/3A57: 4A           LSR 
C0/3A58: 4A           LSR 
C0/3A59: 4A           LSR 
C0/3A5A: 18           CLC 
C0/3A5B: 79 7C 14     ADC $147C,Y
C0/3A5E: 29 7F        AND #$7F
C0/3A60: 85 08        STA $08
C0/3A62: C9 08        CMP #$08
C0/3A64: B0 10        BCS $3A76
C0/3A66: B9 7E 14     LDA $147E,Y
C0/3A69: 29 70        AND #$70
C0/3A6B: C9 50        CMP #$50
C0/3A6D: D0 07        BNE $3A76
C0/3A6F: A5 08        LDA $08
C0/3A71: 18           CLC 
C0/3A72: 69 40        ADC #$40
C0/3A74: 85 08        STA $08
C0/3A76: A5 08        LDA $08
C0/3A78: C2 20        REP #$20
C0/3A7A: 0A           ASL 
C0/3A7B: 0A           ASL 
C0/3A7C: 0A           ASL 
C0/3A7D: 0A           ASL 
C0/3A7E: AA           TAX 
C0/3A7F: A4 E9        LDY $E9
C0/3A81: B9 77 14     LDA $1477,Y
C0/3A84: 4A           LSR 
C0/3A85: 4A           LSR 
C0/3A86: 4A           LSR 
C0/3A87: 18           CLC 
C0/3A88: 69 10 00     ADC #$0010
C0/3A8B: 38           SEC 
C0/3A8C: E5 61        SBC $61
C0/3A8E: 29 FF 07     AND #$07FF
C0/3A91: C9 00 02     CMP #$0200
C0/3A94: 90 03        BCC $3A99
C0/3A96: 4C 67 3B     JMP $3B67
C0/3A99: 4A           LSR 
C0/3A9A: 85 0D        STA $0D
C0/3A9C: DA           PHX 
C0/3A9D: B9 85 14     LDA $1485,Y
C0/3AA0: 29 04 00     AND #$0004
C0/3AA3: D0 09        BNE $3AAE
C0/3AA5: B9 88 14     LDA $1488,Y
C0/3AA8: 29 FF 00     AND #$00FF
C0/3AAB: 4A           LSR 
C0/3AAC: 80 08        BRA $3AB6
C0/3AAE: B9 88 14     LDA $1488,Y
C0/3AB1: 29 FF 00     AND #$00FF
C0/3AB4: 4A           LSR 
C0/3AB5: 4A           LSR 
C0/3AB6: AA           TAX 
C0/3AB7: BF DB 22 C0  LDA $C022DB,X
C0/3ABB: 29 FF 00     AND #$00FF
C0/3ABE: 0A           ASL 
C0/3ABF: 85 0F        STA $0F
C0/3AC1: FA           PLX 
C0/3AC2: B9 79 14     LDA $1479,Y
C0/3AC5: 4A           LSR 
C0/3AC6: 4A           LSR 
C0/3AC7: 4A           LSR 
C0/3AC8: 18           CLC 
C0/3AC9: 69 10 00     ADC #$0010
C0/3ACC: 38           SEC 
C0/3ACD: E5 63        SBC $63
C0/3ACF: 38           SEC 
C0/3AD0: E5 0F        SBC $0F
C0/3AD2: 29 FF 07     AND #$07FF
C0/3AD5: C9 F0 07     CMP #$07F0
C0/3AD8: B0 08        BCS $3AE2
C0/3ADA: C9 E0 01     CMP #$01E0
C0/3ADD: 90 03        BCC $3AE2
C0/3ADF: 4C 67 3B     JMP $3B67
C0/3AE2: 4A           LSR 
C0/3AE3: 85 0F        STA $0F
C0/3AE5: B9 77 14     LDA $1477,Y
C0/3AE8: 4A           LSR 
C0/3AE9: 4A           LSR 
C0/3AEA: 4A           LSR 
C0/3AEB: 4A           LSR 
C0/3AEC: 4A           LSR 
C0/3AED: 4A           LSR 
C0/3AEE: 29 01 00     AND #$0001
C0/3AF1: 18           CLC 
C0/3AF2: 65 0F        ADC $0F
C0/3AF4: 85 0F        STA $0F
C0/3AF6: A5 06        LDA $06
C0/3AF8: E2 20        SEP #$20
C0/3AFA: A4 23        LDY $23
C0/3AFC: A5 0D        LDA $0D
C0/3AFE: 38           SEC 
C0/3AFF: ED A0 10     SBC $10A0
C0/3B02: 99 44 02     STA $0244,Y     ; x position
C0/3B05: 99 1C 03     STA $031C,Y
C0/3B08: 38           SEC 
C0/3B09: E9 08        SBC #$08
C0/3B0B: 99 40 02     STA $0240,Y
C0/3B0E: 99 18 03     STA $0318,Y
C0/3B11: A5 0F        LDA $0F
C0/3B13: 38           SEC 
C0/3B14: ED A2 10     SBC $10A2
C0/3B17: 38           SEC 
C0/3B18: E9 03        SBC #$03
C0/3B1A: 99 19 03     STA $0319,Y     ; y position
C0/3B1D: 99 1D 03     STA $031D,Y
C0/3B20: 38           SEC 
C0/3B21: E9 08        SBC #$08
C0/3B23: 99 41 02     STA $0241,Y
C0/3B26: 99 45 02     STA $0245,Y
C0/3B29: C2 20        REP #$20
C0/3B2B: A4 E9        LDY $E9
C0/3B2D: BF 97 2A C0  LDA $C02A97,X
C0/3B31: 18           CLC 
C0/3B32: 79 81 14     ADC $1481,Y
C0/3B35: A4 23        LDY $23
C0/3B37: 99 42 02     STA $0242,Y
C0/3B3A: A4 E9        LDY $E9
C0/3B3C: BF 9B 2A C0  LDA $C02A9B,X
C0/3B40: 18           CLC 
C0/3B41: 79 81 14     ADC $1481,Y
C0/3B44: A4 23        LDY $23
C0/3B46: 99 46 02     STA $0246,Y
C0/3B49: A4 E9        LDY $E9
C0/3B4B: BF 9F 2A C0  LDA $C02A9F,X
C0/3B4F: 18           CLC 
C0/3B50: 79 83 14     ADC $1483,Y
C0/3B53: A4 23        LDY $23
C0/3B55: 99 1A 03     STA $031A,Y
C0/3B58: A4 E9        LDY $E9
C0/3B5A: BF A3 2A C0  LDA $C02AA3,X
C0/3B5E: 18           CLC 
C0/3B5F: 79 83 14     ADC $1483,Y
C0/3B62: A4 23        LDY $23
C0/3B64: 99 1E 03     STA $031E,Y
C0/3B67: C2 20        REP #$20
C0/3B69: A5 23        LDA $23
C0/3B6B: 18           CLC 
C0/3B6C: 69 08 00     ADC #$0008
C0/3B6F: 85 23        STA $23
C0/3B71: A5 E9        LDA $E9
C0/3B73: 18           CLC 
C0/3B74: 69 14 00     ADC #$0014
C0/3B77: 85 E9        STA $E9
C0/3B79: A5 06        LDA $06
C0/3B7B: E2 20        SEP #$20
C0/3B7D: 68           PLA 
C0/3B7E: 3A           DEC 
C0/3B7F: F0 03        BEQ $3B84
C0/3B81: 4C C2 39     JMP $39C2
C0/3B84: 20 8E 35     JSR $358E       ; update hiryuu sprites
C0/3B87: 60           RTS 

; animation speeds
C0/3B88: 03 04 05 02

; animation frames (unused)
C0/3B8C: 00 00        BRK $00
C0/3B8E: 00 00        BRK $00

; animation frames (1 frame)
C0/3B90: 00 00        BRK $00
C0/3B92: 00 00        BRK $00

; animation frames (2 frames)
C0/3B94: 00 01        BRK $01
C0/3B96: 00 01        BRK $01

; animation frames (4 frames)
C0/3B98: 00 01        BRK $01
C0/3B9A: 02 03        COP $03

; animation frames (flip horizontally ???)
C0/3B9C: 00 04        BRK $04
C0/3B9E: 00 04        BRK $04

; animation frames (unused)
C0/3BA0: 00 00        BRK $00
C0/3BA2: 00 00        BRK $00

; animation frames (unused)
C0/3BA4: 00 00        BRK $00
C0/3BA6: 00 00        BRK $00

; animation frames (unused)
C0/3BA8: 00 00        BRK $00
C0/3BAA: 00 00        BRK $00

; [ update object positions ]

C0/3BAC: A5 E6        LDA $E6
C0/3BAE: D0 01        BNE $3BB1       ; return if there are no objects
C0/3BB0: 60           RTS 
C0/3BB1: 64 E5        STZ $E5         ; current object
C0/3BB3: A4 06        LDY $06
C0/3BB5: 84 E9        STY $E9         ; pointer to current object
C0/3BB7: A4 E9        LDY $E9
C0/3BB9: A5 57        LDA $57
C0/3BBB: F0 08        BEQ $3BC5       ; branch if dialog window is not open
C0/3BBD: B9 86 14     LDA $1486,Y
C0/3BC0: D0 1C        BNE $3BDE       ; branch if object is moving
C0/3BC2: 4C 74 3C     JMP $3C74
C0/3BC5: B9 7B 14     LDA $147B,Y
C0/3BC8: 10 03        BPL $3BCD
C0/3BCA: 4C 48 3C     JMP $3C48
C0/3BCD: B9 7E 14     LDA $147E,Y
C0/3BD0: 29 08        AND #$08
C0/3BD2: D0 0A        BNE $3BDE
C0/3BD4: B9 7D 14     LDA $147D,Y
C0/3BD7: 29 80        AND #$80
C0/3BD9: F0 03        BEQ $3BDE
C0/3BDB: 4C 48 3C     JMP $3C48
C0/3BDE: B9 7B 14     LDA $147B,Y
C0/3BE1: 29 7F        AND #$7F
C0/3BE3: D0 03        BNE $3BE8       ; branch if object is moving
C0/3BE5: 4C 48 3C     JMP $3C48
C0/3BE8: A4 E9        LDY $E9
C0/3BEA: B9 85 14     LDA $1485,Y
C0/3BED: 29 02        AND #$02
C0/3BEF: D0 07        BNE $3BF8
C0/3BF1: B9 7E 14     LDA $147E,Y     ; animation speed
C0/3BF4: 29 03        AND #$03
C0/3BF6: 80 02        BRA $3BFA
C0/3BF8: A9 00        LDA #$00
C0/3BFA: 0A           ASL 
C0/3BFB: AA           TAX 
C0/3BFC: B9 7B 14     LDA $147B,Y
C0/3BFF: 3A           DEC 
C0/3C00: F0 08        BEQ $3C0A
C0/3C02: 3A           DEC 
C0/3C03: F0 14        BEQ $3C19
C0/3C05: 3A           DEC 
C0/3C06: F0 20        BEQ $3C28
C0/3C08: 80 2D        BRA $3C37

; moving up
C0/3C0A: C2 20        REP #$20
C0/3C0C: B9 79 14     LDA $1479,Y
C0/3C0F: 38           SEC 
C0/3C10: FF AB 3C C0  SBC $C03CAB,X
C0/3C14: 99 79 14     STA $1479,Y
C0/3C17: 80 2B        BRA $3C44

; moving right
C0/3C19: C2 20        REP #$20
C0/3C1B: B9 77 14     LDA $1477,Y
C0/3C1E: 18           CLC 
C0/3C1F: 7F AB 3C C0  ADC $C03CAB,X
C0/3C23: 99 77 14     STA $1477,Y
C0/3C26: 80 1C        BRA $3C44

; moving down
C0/3C28: C2 20        REP #$20
C0/3C2A: B9 79 14     LDA $1479,Y
C0/3C2D: 18           CLC 
C0/3C2E: 7F AB 3C C0  ADC $C03CAB,X
C0/3C32: 99 79 14     STA $1479,Y
C0/3C35: 80 0D        BRA $3C44

; moving left
C0/3C37: C2 20        REP #$20
C0/3C39: B9 77 14     LDA $1477,Y
C0/3C3C: 38           SEC 
C0/3C3D: FF AB 3C C0  SBC $C03CAB,X
C0/3C41: 99 77 14     STA $1477,Y
C0/3C44: A5 06        LDA $06
C0/3C46: E2 20        SEP #$20
C0/3C48: B9 85 14     LDA $1485,Y
C0/3C4B: 29 02        AND #$02
C0/3C4D: D0 07        BNE $3C56
C0/3C4F: B9 7E 14     LDA $147E,Y     ; animation speed
C0/3C52: 29 03        AND #$03
C0/3C54: 80 02        BRA $3C58
C0/3C56: A9 00        LDA #$00
C0/3C58: AA           TAX 
C0/3C59: B9 7D 14     LDA $147D,Y     ; 
C0/3C5C: 18           CLC 
C0/3C5D: 7F B3 3C C0  ADC $C03CB3,X
C0/3C61: 99 7D 14     STA $147D,Y
C0/3C64: B9 88 14     LDA $1488,Y
C0/3C67: F0 0B        BEQ $3C74
C0/3C69: B9 88 14     LDA $1488,Y     ; 
C0/3C6C: 38           SEC 
C0/3C6D: FF B7 3C C0  SBC $C03CB7,X
C0/3C71: 99 88 14     STA $1488,Y
C0/3C74: A5 57        LDA $57
C0/3C76: F0 19        BEQ $3C91
C0/3C78: B9 86 14     LDA $1486,Y
C0/3C7B: F0 14        BEQ $3C91
C0/3C7D: B9 7D 14     LDA $147D,Y
C0/3C80: 29 7F        AND #$7F
C0/3C82: D0 0D        BNE $3C91
C0/3C84: B9 88 14     LDA $1488,Y
C0/3C87: D0 08        BNE $3C91
C0/3C89: A9 00        LDA #$00        ; movement complete ???
C0/3C8B: 99 86 14     STA $1486,Y
C0/3C8E: 99 7B 14     STA $147B,Y
C0/3C91: C2 20        REP #$20        ; next object
C0/3C93: A5 E9        LDA $E9
C0/3C95: 18           CLC 
C0/3C96: 69 14 00     ADC #$0014
C0/3C99: 85 E9        STA $E9
C0/3C9B: A5 06        LDA $06
C0/3C9D: E2 20        SEP #$20
C0/3C9F: E6 E5        INC $E5
C0/3CA1: A5 E5        LDA $E5
C0/3CA3: C5 E6        CMP $E6
C0/3CA5: F0 03        BEQ $3CAA
C0/3CA7: 4C B7 3B     JMP $3BB7
C0/3CAA: 60           RTS 

; movement speeds (normal, slowest, slow, fast)
C0/3CAB:              .DW $0010, $0004, $0008, $0020

C0/3CB3:              .DB $08, $02, $04, $10
C0/3CB7:              .DB $04, $01, $02, $08

; [ get pointer to object layout ]

C0/3CBB: A5 76        LDA $76
C0/3CBD: 29 3F        AND #$3F
C0/3CBF: EB           XBA 
C0/3CC0: C2 20        REP #$20
C0/3CC2: 4A           LSR 
C0/3CC3: 4A           LSR 
C0/3CC4: 85 0D        STA $0D
C0/3CC6: A5 75        LDA $75
C0/3CC8: 29 3F 00     AND #$003F
C0/3CCB: 05 0D        ORA $0D
C0/3CCD: AA           TAX 
C0/3CCE: A5 06        LDA $06
C0/3CD0: E2 20        SEP #$20
C0/3CD2: 60           RTS 

; [ clear object layout ]

C0/3CD3: A2 00 10     LDX #$1000
C0/3CD6: A9 00        LDA #$00
C0/3CD8: 9F FF 2F 7F  STA $7F2FFF,X
C0/3CDC: CA           DEX 
C0/3CDD: D0 F9        BNE $3CD8
C0/3CDF: 60           RTS 

; [ add object to object layout ]

C0/3CE0: DA           PHX 
C0/3CE1: 20 BB 3C     JSR $3CBB       ; get pointer to object layout
C0/3CE4: C2 20        REP #$20
C0/3CE6: 8A           TXA 
C0/3CE7: 99 89 14     STA $1489,Y
C0/3CEA: A5 06        LDA $06
C0/3CEC: E2 20        SEP #$20
C0/3CEE: A5 E5        LDA $E5
C0/3CF0: 09 80        ORA #$80
C0/3CF2: 9F 00 30 7F  STA $7F3000,X
C0/3CF6: FA           PLX 
C0/3CF7: 60           RTS 

; [ remove object from object layout ]

C0/3CF8: DA           PHX 
C0/3CF9: C2 20        REP #$20
C0/3CFB: B9 89 14     LDA $1489,Y     ; pointer to object layout
C0/3CFE: AA           TAX 
C0/3CFF: A5 06        LDA $06
C0/3D01: E2 20        SEP #$20
C0/3D03: A9 00        LDA #$00
C0/3D05: 9F 00 30 7F  STA $7F3000,X   ; clear location in object layout
C0/3D09: FA           PLX 
C0/3D0A: 60           RTS 

; [ get object in object layout ]

C0/3D0B: DA           PHX 
C0/3D0C: 20 BB 3C     JSR $3CBB       ; get pointer to object layout
C0/3D0F: BF 00 30 7F  LDA $7F3000,X
C0/3D13: FA           PLX 
C0/3D14: 60           RTS 

; [ get tile z-level (unused) ]

; A: tile index, z-level (out)

C0/3D15: DA           PHX 
C0/3D16: C2 20        REP #$20
C0/3D18: 29 FF 00     AND #$00FF
C0/3D1B: 0A           ASL 
C0/3D1C: AA           TAX 
C0/3D1D: A5 06        LDA $06
C0/3D1F: E2 20        SEP #$20
C0/3D21: BD 86 11     LDA $1186,X     ; tile properties
C0/3D24: 29 83        AND #$83
C0/3D26: FA           PLX 
C0/3D27: 60           RTS 

; [ load npc graphics ]

C0/3D28: A5 E6        LDA $E6
C0/3D2A: D0 01        BNE $3D2D
C0/3D2C: 60           RTS 
C0/3D2D: 20 98 3E     JSR $3E98       ; get pointer to npc properties
C0/3D30: A2 00 65     LDX #$6500
C0/3D33: 86 2E        STX $2E
C0/3D35: A6 06        LDX $06
C0/3D37: 86 E9        STX $E9
C0/3D39: A6 E7        LDX $E7
C0/3D3B: 86 29        STX $29
C0/3D3D: A9 00        LDA #$00
C0/3D3F: 48           PHA 
C0/3D40: A9 DA        LDA #$DA        ; graphics start in bank $DA
C0/3D42: 85 25        STA $25
C0/3D44: A6 29        LDX $29
C0/3D46: 68           PLA 
C0/3D47: 48           PHA 
C0/3D48: F0 25        BEQ $3D6F
C0/3D4A: BF C2 59 CE  LDA $CE59C2,X   ; npc graphics
C0/3D4E: DF BB 59 CE  CMP $CE59BB,X
C0/3D52: D0 1B        BNE $3D6F       ; branch if not the same as previous npc
C0/3D54: A5 55        LDA $55
C0/3D56: D0 14        BNE $3D6C
C0/3D58: C2 20        REP #$20
C0/3D5A: A6 E9        LDX $E9
C0/3D5C: BD 6D 14     LDA $146D,X
C0/3D5F: 9D 81 14     STA $1481,X
C0/3D62: BD 6F 14     LDA $146F,X
C0/3D65: 9D 83 14     STA $1483,X
C0/3D68: A5 06        LDA $06
C0/3D6A: E2 20        SEP #$20
C0/3D6C: 4C 78 3E     JMP $3E78
C0/3D6F: BF C2 59 CE  LDA $CE59C2,X
C0/3D73: C9 FF        CMP #$FF
C0/3D75: F0 1E        BEQ $3D95       ; branch if no graphics
C0/3D77: A5 55        LDA $55
C0/3D79: D0 2F        BNE $3DAA
C0/3D7B: C2 20        REP #$20
C0/3D7D: A5 2E        LDA $2E
C0/3D7F: 38           SEC 
C0/3D80: E9 00 60     SBC #$6000
C0/3D83: 4A           LSR 
C0/3D84: 4A           LSR 
C0/3D85: 4A           LSR 
C0/3D86: 4A           LSR 
C0/3D87: A6 E9        LDX $E9
C0/3D89: 9D 81 14     STA $1481,X
C0/3D8C: 9D 83 14     STA $1483,X
C0/3D8F: A5 06        LDA $06
C0/3D91: E2 20        SEP #$20
C0/3D93: 80 15        BRA $3DAA
C0/3D95: A5 55        LDA $55
C0/3D97: D0 0E        BNE $3DA7
C0/3D99: A6 E9        LDX $E9
C0/3D9B: 9E 81 14     STZ $1481,X
C0/3D9E: 9E 82 14     STZ $1482,X
C0/3DA1: 9E 83 14     STZ $1483,X
C0/3DA4: 9E 84 14     STZ $1484,X
C0/3DA7: 4C 78 3E     JMP $3E78
C0/3DAA: A6 29        LDX $29
C0/3DAC: BF C2 59 CE  LDA $CE59C2,X

; $67-$68: hiryuu, 64 tiles each ($0800 bytes)
C0/3DB0: C9 67        CMP #$67
C0/3DB2: 90 20        BCC $3DD4       ; branch if not hiryuu
C0/3DB4: 38           SEC 
C0/3DB5: E9 67        SBC #$67
C0/3DB7: C2 20        REP #$20
C0/3DB9: EB           XBA 
C0/3DBA: 0A           ASL 
C0/3DBB: 0A           ASL 
C0/3DBC: 0A           ASL 
C0/3DBD: 18           CLC 
C0/3DBE: 69 00 2A     ADC #$2A00
C0/3DC1: 85 23        STA $23
C0/3DC3: A5 06        LDA $06
C0/3DC5: E2 20        SEP #$20
C0/3DC7: A9 04        LDA #$04
C0/3DC9: 85 09        STA $09
C0/3DCB: E6 25        INC $25
C0/3DCD: A9 01        LDA #$01
C0/3DCF: 8D 9F 16     STA $169F       ; set hiryuu flag
C0/3DD2: 80 7C        BRA $3E50

; $52-$66: 16 tiles each ($0200 bytes)
C0/3DD4: C9 52        CMP #$52
C0/3DD6: 90 15        BCC $3DED
C0/3DD8: 38           SEC 
C0/3DD9: E9 52        SBC #$52
C0/3DDB: C2 20        REP #$20
C0/3DDD: EB           XBA 
C0/3DDE: 0A           ASL 
C0/3DDF: 85 23        STA $23
C0/3DE1: A5 06        LDA $06
C0/3DE3: E2 20        SEP #$20
C0/3DE5: A9 01        LDA #$01
C0/3DE7: 85 09        STA $09
C0/3DE9: E6 25        INC $25
C0/3DEB: 80 63        BRA $3E50

; $4B-$51: main characters, 64 tiles each ($0800 bytes)
C0/3DED: C9 4B        CMP #$4B
C0/3DEF: 90 27        BCC $3E18
C0/3DF1: 38           SEC 
C0/3DF2: E9 4B        SBC #$4B
C0/3DF4: C2 20        REP #$20
C0/3DF6: EB           XBA 
C0/3DF7: 0A           ASL 
C0/3DF8: 0A           ASL 
C0/3DF9: 0A           ASL 
C0/3DFA: 18           CLC 
C0/3DFB: 69 00 C8     ADC #$C800
C0/3DFE: 85 23        STA $23
C0/3E00: A5 06        LDA $06
C0/3E02: E2 20        SEP #$20
C0/3E04: A6 29        LDX $29
C0/3E06: BF C1 59 CE  LDA $CE59C1,X
C0/3E0A: 4A           LSR 
C0/3E0B: 4A           LSR 
C0/3E0C: 4A           LSR 
C0/3E0D: 4A           LSR 
C0/3E0E: 4A           LSR 
C0/3E0F: 4A           LSR 
C0/3E10: D0 02        BNE $3E14
C0/3E12: A9 04        LDA #$04
C0/3E14: 85 09        STA $09
C0/3E16: 80 38        BRA $3E50

; $32-$4A: 32 tiles each ($0400 bytes)
C0/3E18: C9 32        CMP #$32
C0/3E1A: 90 26        BCC $3E42
C0/3E1C: 38           SEC 
C0/3E1D: E9 32        SBC #$32
C0/3E1F: C2 20        REP #$20
C0/3E21: EB           XBA 
C0/3E22: 0A           ASL 
C0/3E23: 0A           ASL 
C0/3E24: 18           CLC 
C0/3E25: 69 00 64     ADC #$6400
C0/3E28: 85 23        STA $23
C0/3E2A: A5 06        LDA $06
C0/3E2C: E2 20        SEP #$20
C0/3E2E: A6 29        LDX $29
C0/3E30: BF C1 59 CE  LDA $CE59C1,X
C0/3E34: 4A           LSR 
C0/3E35: 4A           LSR 
C0/3E36: 4A           LSR 
C0/3E37: 4A           LSR 
C0/3E38: 4A           LSR 
C0/3E39: 4A           LSR 
C0/3E3A: D0 02        BNE $3E3E
C0/3E3C: A9 02        LDA #$02
C0/3E3E: 85 09        STA $09
C0/3E40: 80 0E        BRA $3E50

; $00-$31: 16 tiles each ($0200 bytes)
C0/3E42: C2 20        REP #$20
C0/3E44: EB           XBA 
C0/3E45: 0A           ASL 
C0/3E46: 85 23        STA $23
C0/3E48: A5 06        LDA $06
C0/3E4A: E2 20        SEP #$20
C0/3E4C: A9 01        LDA #$01
C0/3E4E: 85 09        STA $09
C0/3E50: A2 00 02     LDX #$0200
C0/3E53: 86 2C        STX $2C
C0/3E55: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/3E58: C2 20        REP #$20
C0/3E5A: A5 2E        LDA $2E
C0/3E5C: 18           CLC 
C0/3E5D: 69 00 01     ADC #$0100
C0/3E60: 85 2E        STA $2E
C0/3E62: A5 23        LDA $23
C0/3E64: 18           CLC 
C0/3E65: 69 00 02     ADC #$0200
C0/3E68: 85 23        STA $23
C0/3E6A: E2 20        SEP #$20
C0/3E6C: EB           XBA 
C0/3E6D: D0 02        BNE $3E71
C0/3E6F: E6 25        INC $25
C0/3E71: A9 00        LDA #$00
C0/3E73: EB           XBA 
C0/3E74: C6 09        DEC $09
C0/3E76: D0 DD        BNE $3E55
C0/3E78: C2 20        REP #$20
C0/3E7A: A5 E9        LDA $E9
C0/3E7C: 18           CLC 
C0/3E7D: 69 14 00     ADC #$0014
C0/3E80: 85 E9        STA $E9
C0/3E82: A5 29        LDA $29
C0/3E84: 18           CLC 
C0/3E85: 69 07 00     ADC #$0007
C0/3E88: 85 29        STA $29
C0/3E8A: A5 06        LDA $06
C0/3E8C: E2 20        SEP #$20
C0/3E8E: 68           PLA 
C0/3E8F: 1A           INC 
C0/3E90: C5 E6        CMP $E6
C0/3E92: F0 03        BEQ $3E97
C0/3E94: 4C 3F 3D     JMP $3D3F
C0/3E97: 60           RTS 

; [ get pointer to npc properties ]

C0/3E98: C2 20        REP #$20
C0/3E9A: AD 0C 11     LDA $110C       ; map index
C0/3E9D: 0A           ASL 
C0/3E9E: AA           TAX 
C0/3E9F: BF C0 59 CE  LDA $CE59C0,X   ; pointer to npc properties
C0/3EA3: 85 E7        STA $E7
C0/3EA5: A5 06        LDA $06
C0/3EA7: E2 20        SEP #$20
C0/3EA9: 60           RTS 

; [ load npcs ]

C0/3EAA: 20 D3 3C     JSR $3CD3       ; clear object layout
C0/3EAD: C2 20        REP #$20
C0/3EAF: AD 0C 11     LDA $110C
C0/3EB2: 0A           ASL 
C0/3EB3: AA           TAX 
C0/3EB4: BF C0 59 CE  LDA $CE59C0,X   ; npc data
C0/3EB8: 85 E7        STA $E7
C0/3EBA: BF C2 59 CE  LDA $CE59C2,X
C0/3EBE: 38           SEC 
C0/3EBF: FF C0 59 CE  SBC $CE59C0,X
C0/3EC3: 8D 04 42     STA $4204
C0/3EC6: A5 06        LDA $06
C0/3EC8: E2 20        SEP #$20
C0/3ECA: A9 07        LDA #$07
C0/3ECC: 8D 06 42     STA $4206
C0/3ECF: 48           PHA 
C0/3ED0: 68           PLA 
C0/3ED1: 48           PHA 
C0/3ED2: 68           PLA 
C0/3ED3: EA           NOP 
C0/3ED4: AD 14 42     LDA $4214
C0/3ED7: 85 E6        STA $E6         ; number of objects
C0/3ED9: D0 01        BNE $3EDC
C0/3EDB: 60           RTS 
C0/3EDC: 20 28 3D     JSR $3D28       ; load npc graphics
C0/3EDF: A4 06        LDY $06
C0/3EE1: 84 E9        STY $E9
C0/3EE3: 64 E5        STZ $E5
C0/3EE5: A4 E9        LDY $E9
C0/3EE7: A6 E7        LDX $E7
C0/3EE9: BF C6 59 CE  LDA $CE59C6,X   ; palette
C0/3EED: 29 07        AND #$07
C0/3EEF: 0A           ASL 
C0/3EF0: 85 0F        STA $0F
C0/3EF2: BF C6 59 CE  LDA $CE59C6,X   ; layer priority (top)
C0/3EF6: 29 08        AND #$08
C0/3EF8: 09 10        ORA #$10
C0/3EFA: 0A           ASL 
C0/3EFB: 05 0F        ORA $0F
C0/3EFD: C2 20        REP #$20
C0/3EFF: EB           XBA 
C0/3F00: 19 81 14     ORA $1481,Y
C0/3F03: 99 81 14     STA $1481,Y
C0/3F06: A5 06        LDA $06
C0/3F08: E2 20        SEP #$20
C0/3F0A: BF C6 59 CE  LDA $CE59C6,X   ; layer priority (bottom)
C0/3F0E: 29 10        AND #$10
C0/3F10: 09 20        ORA #$20
C0/3F12: 05 0F        ORA $0F
C0/3F14: C2 20        REP #$20
C0/3F16: EB           XBA 
C0/3F17: 19 83 14     ORA $1483,Y
C0/3F1A: 99 83 14     STA $1483,Y
C0/3F1D: A5 06        LDA $06
C0/3F1F: E2 20        SEP #$20
C0/3F21: BF C5 59 CE  LDA $CE59C5,X   ; misc. flags
C0/3F25: 99 7E 14     STA $147E,Y
C0/3F28: 29 70        AND #$70
C0/3F2A: F0 1B        BEQ $3F47       ; branch if walking animation
C0/3F2C: C9 50        CMP #$50
C0/3F2E: F0 17        BEQ $3F47       ; branch if animal animation
C0/3F30: DA           PHX 
C0/3F31: BF C6 59 CE  LDA $CE59C6,X   ; action frame
C0/3F35: 29 E0        AND #$E0
C0/3F37: 4A           LSR 
C0/3F38: 4A           LSR 
C0/3F39: 4A           LSR 
C0/3F3A: 4A           LSR 
C0/3F3B: 4A           LSR 
C0/3F3C: AA           TAX 
C0/3F3D: BF 00 40 C0  LDA $C04000,X
C0/3F41: 99 87 14     STA $1487,Y
C0/3F44: FA           PLX 
C0/3F45: 80 1C        BRA $3F63
C0/3F47: BF C6 59 CE  LDA $CE59C6,X   ; action frame
C0/3F4B: 29 E0        AND #$E0
C0/3F4D: 4A           LSR 
C0/3F4E: 4A           LSR 
C0/3F4F: 4A           LSR 
C0/3F50: 4A           LSR 
C0/3F51: 4A           LSR 
C0/3F52: 0A           ASL 
C0/3F53: 99 7C 14     STA $147C,Y
C0/3F56: C9 08        CMP #$08
C0/3F58: 90 04        BCC $3F5E
C0/3F5A: A9 00        LDA #$00
C0/3F5C: 80 02        BRA $3F60
C0/3F5E: 4A           LSR 
C0/3F5F: 1A           INC 
C0/3F60: 99 7B 14     STA $147B,Y     ; facing direction
C0/3F63: C2 20        REP #$20
C0/3F65: BF C0 59 CE  LDA $CE59C0,X   ; npc script
C0/3F69: 29 FF 3F     AND #$3FFF
C0/3F6C: 99 7F 14     STA $147F,Y
C0/3F6F: A5 06        LDA $06
C0/3F71: E2 20        SEP #$20
C0/3F73: BF C3 59 CE  LDA $CE59C3,X   ; x position
C0/3F77: 29 3F        AND #$3F
C0/3F79: C2 20        REP #$20
C0/3F7B: EB           XBA 
C0/3F7C: 99 77 14     STA $1477,Y
C0/3F7F: A5 06        LDA $06
C0/3F81: E2 20        SEP #$20
C0/3F83: BF C4 59 CE  LDA $CE59C4,X   ; y position
C0/3F87: 29 3F        AND #$3F
C0/3F89: C2 20        REP #$20
C0/3F8B: EB           XBA 
C0/3F8C: 99 79 14     STA $1479,Y
C0/3F8F: A5 06        LDA $06
C0/3F91: E2 20        SEP #$20
C0/3F93: A9 00        LDA #$00
C0/3F95: 99 7D 14     STA $147D,Y     ; movement animation counter
C0/3F98: 99 86 14     STA $1486,Y     ; 
C0/3F9B: 99 88 14     STA $1488,Y     ; jump counter
C0/3F9E: BF C3 59 CE  LDA $CE59C3,X
C0/3FA2: 29 C0        AND #$C0
C0/3FA4: 99 85 14     STA $1485,Y
C0/3FA7: BF C4 59 CE  LDA $CE59C4,X
C0/3FAB: 29 C0        AND #$C0
C0/3FAD: 4A           LSR 
C0/3FAE: 4A           LSR 
C0/3FAF: 19 85 14     ORA $1485,Y
C0/3FB2: 09 08        ORA #$08
C0/3FB4: 99 85 14     STA $1485,Y
C0/3FB7: C2 20        REP #$20
C0/3FB9: B9 7F 14     LDA $147F,Y
C0/3FBC: E2 20        SEP #$20
C0/3FBE: 5A           PHY 
C0/3FBF: 20 C1 C9     JSR $C9C1       ; get npc flag
C0/3FC2: 7A           PLY 
C0/3FC3: C9 00        CMP #$00
C0/3FC5: F0 17        BEQ $3FDE
C0/3FC7: B9 78 14     LDA $1478,Y
C0/3FCA: 85 75        STA $75
C0/3FCC: B9 7A 14     LDA $147A,Y
C0/3FCF: 85 76        STA $76
C0/3FD1: 20 E0 3C     JSR $3CE0       ; add object to object layout
C0/3FD4: A4 E9        LDY $E9
C0/3FD6: B9 85 14     LDA $1485,Y     ; make object visible
C0/3FD9: 09 01        ORA #$01
C0/3FDB: 99 85 14     STA $1485,Y
C0/3FDE: C2 20        REP #$20
C0/3FE0: A5 E9        LDA $E9         ; next object
C0/3FE2: 18           CLC 
C0/3FE3: 69 14 00     ADC #$0014
C0/3FE6: 85 E9        STA $E9
C0/3FE8: A5 E7        LDA $E7
C0/3FEA: 18           CLC 
C0/3FEB: 69 07 00     ADC #$0007
C0/3FEE: 85 E7        STA $E7
C0/3FF0: A5 06        LDA $06
C0/3FF2: E2 20        SEP #$20
C0/3FF4: E6 E5        INC $E5
C0/3FF6: A5 E5        LDA $E5
C0/3FF8: C5 E6        CMP $E6
C0/3FFA: F0 03        BEQ $3FFF
C0/3FFC: 4C E5 3E     JMP $3EE5
C0/3FFF: 60           RTS 

C0/4000:              .DB $08, $09, $0A, $0B, $0C, $22, $21, $0F

; [ convert color palettes to grayscale ]

C0/4008: A0 08 00     LDY #$0008
C0/400B: C2 20        REP #$20
C0/400D: B9 00 0C     LDA $0C00,Y
C0/4010: 29 1F 00     AND #$001F
C0/4013: 85 0D        STA $0D
C0/4015: B9 00 0C     LDA $0C00,Y
C0/4018: 4A           LSR 
C0/4019: 4A           LSR 
C0/401A: 4A           LSR 
C0/401B: 4A           LSR 
C0/401C: 4A           LSR 
C0/401D: 85 0F        STA $0F
C0/401F: 29 1F 00     AND #$001F
C0/4022: 18           CLC 
C0/4023: 65 0D        ADC $0D
C0/4025: 85 0D        STA $0D
C0/4027: A5 0F        LDA $0F
C0/4029: 4A           LSR 
C0/402A: 4A           LSR 
C0/402B: 4A           LSR 
C0/402C: 4A           LSR 
C0/402D: 4A           LSR 
C0/402E: 29 1F 00     AND #$001F
C0/4031: 18           CLC 
C0/4032: 65 0D        ADC $0D
C0/4034: 8D 04 42     STA $4204
C0/4037: A5 06        LDA $06
C0/4039: E2 20        SEP #$20
C0/403B: A9 03        LDA #$03
C0/403D: 8D 06 42     STA $4206
C0/4040: C2 20        REP #$20
C0/4042: EA           NOP 
C0/4043: EA           NOP 
C0/4044: EA           NOP 
C0/4045: EA           NOP 
C0/4046: EA           NOP 
C0/4047: EA           NOP 
C0/4048: EA           NOP 
C0/4049: AD 14 42     LDA $4214
C0/404C: 0A           ASL 
C0/404D: 0A           ASL 
C0/404E: 0A           ASL 
C0/404F: 0A           ASL 
C0/4050: 0A           ASL 
C0/4051: 0D 14 42     ORA $4214
C0/4054: 0A           ASL 
C0/4055: 0A           ASL 
C0/4056: 0A           ASL 
C0/4057: 0A           ASL 
C0/4058: 0A           ASL 
C0/4059: 0D 14 42     ORA $4214
C0/405C: 99 00 0C     STA $0C00,Y
C0/405F: A5 06        LDA $06
C0/4061: E2 20        SEP #$20
C0/4063: C8           INY 
C0/4064: C8           INY 
C0/4065: C0 00 02     CPY #$0200
C0/4068: D0 A1        BNE $400B
C0/406A: 60           RTS 

; [  ]

C0/406B: 8D 02 42     STA $4202
C0/406E: A4 06        LDY $06
C0/4070: C2 20        REP #$20
C0/4072: B7 23        LDA [$23],Y
C0/4074: 85 0D        STA $0D
C0/4076: 4A           LSR 
C0/4077: 4A           LSR 
C0/4078: 4A           LSR 
C0/4079: 4A           LSR 
C0/407A: 29 3E 00     AND #$003E
C0/407D: 85 0F        STA $0F
C0/407F: A5 0D        LDA $0D
C0/4081: EB           XBA 
C0/4082: 4A           LSR 
C0/4083: 29 3E 00     AND #$003E
C0/4086: 85 11        STA $11
C0/4088: A5 0D        LDA $0D
C0/408A: 29 1F 00     AND #$001F
C0/408D: 0A           ASL 
C0/408E: 85 0D        STA $0D
C0/4090: A5 06        LDA $06
C0/4092: E2 20        SEP #$20
C0/4094: A5 0D        LDA $0D
C0/4096: 8D 03 42     STA $4203
C0/4099: EA           NOP 
C0/409A: EA           NOP 
C0/409B: EA           NOP 
C0/409C: EA           NOP 
C0/409D: AD 17 42     LDA $4217
C0/40A0: 85 13        STA $13
C0/40A2: A5 11        LDA $11
C0/40A4: 8D 03 42     STA $4203
C0/40A7: EA           NOP 
C0/40A8: EA           NOP 
C0/40A9: EA           NOP 
C0/40AA: EA           NOP 
C0/40AB: AD 17 42     LDA $4217
C0/40AE: 0A           ASL 
C0/40AF: 0A           ASL 
C0/40B0: 29 7C        AND #$7C
C0/40B2: 85 14        STA $14
C0/40B4: A5 0F        LDA $0F
C0/40B6: 8D 03 42     STA $4203
C0/40B9: EA           NOP 
C0/40BA: EA           NOP 
C0/40BB: EA           NOP 
C0/40BC: EA           NOP 
C0/40BD: AD 17 42     LDA $4217
C0/40C0: C2 20        REP #$20
C0/40C2: EB           XBA 
C0/40C3: 4A           LSR 
C0/40C4: 4A           LSR 
C0/40C5: 4A           LSR 
C0/40C6: 05 13        ORA $13
C0/40C8: 9D 00 0C     STA $0C00,X
C0/40CB: A5 06        LDA $06
C0/40CD: E2 20        SEP #$20
C0/40CF: E8           INX 
C0/40D0: E8           INX 
C0/40D1: C8           INY 
C0/40D2: C8           INY 
C0/40D3: C4 2C        CPY $2C
C0/40D5: D0 99        BNE $4070
C0/40D7: 60           RTS 

; [ copy data to vram ]

C0/40D8: A9 80        LDA #$80
C0/40DA: 8D 15 21     STA $2115
C0/40DD: 9C 0B 42     STZ $420B
C0/40E0: A9 01        LDA #$01
C0/40E2: 8D 00 43     STA $4300
C0/40E5: A9 18        LDA #$18
C0/40E7: 8D 01 43     STA $4301
C0/40EA: AE AD 16     LDX $16AD       ; vram destination
C0/40ED: 8E 16 21     STX $2116
C0/40F0: A2 00 08     LDX #$0800      ; size = $0800
C0/40F3: 8E 05 43     STX $4305
C0/40F6: A2 22 76     LDX #$7622      ; source = 7F/7622
C0/40F9: 8E 02 43     STX $4302
C0/40FC: A9 7F        LDA #$7F
C0/40FE: 8D 04 43     STA $4304
C0/4101: A9 01        LDA #$01
C0/4103: 8D 0B 42     STA $420B
C0/4106: 60           RTS 

C0/4107: 0A           ASL 
C0/4108: 0A           ASL 
C0/4109: AA           TAX 
C0/410A: BF 71 41 C0  LDA $C04171,X
C0/410E: 85 0D        STA $0D
C0/4110: BF 72 41 C0  LDA $C04172,X
C0/4114: 85 0E        STA $0E
C0/4116: BF 73 41 C0  LDA $C04173,X
C0/411A: 85 0F        STA $0F
C0/411C: BF 74 41 C0  LDA $C04174,X
C0/4120: 85 10        STA $10
C0/4122: A9 7F        LDA #$7F
C0/4124: 48           PHA 
C0/4125: AB           PLB 
C0/4126: A4 06        LDY $06
C0/4128: B7 23        LDA [$23],Y
C0/412A: 25 0D        AND $0D
C0/412C: 99 22 76     STA $7622,Y
C0/412F: C8           INY 
C0/4130: B7 23        LDA [$23],Y
C0/4132: 25 0D        AND $0D
C0/4134: 99 22 76     STA $7622,Y
C0/4137: C8           INY 
C0/4138: B7 23        LDA [$23],Y
C0/413A: 25 0E        AND $0E
C0/413C: 99 22 76     STA $7622,Y
C0/413F: C8           INY 
C0/4140: B7 23        LDA [$23],Y
C0/4142: 25 0E        AND $0E
C0/4144: 99 22 76     STA $7622,Y
C0/4147: C8           INY 
C0/4148: B7 23        LDA [$23],Y
C0/414A: 25 0F        AND $0F
C0/414C: 99 22 76     STA $7622,Y
C0/414F: C8           INY 
C0/4150: B7 23        LDA [$23],Y
C0/4152: 25 0F        AND $0F
C0/4154: 99 22 76     STA $7622,Y
C0/4157: C8           INY 
C0/4158: B7 23        LDA [$23],Y
C0/415A: 25 10        AND $10
C0/415C: 99 22 76     STA $7622,Y
C0/415F: C8           INY 
C0/4160: B7 23        LDA [$23],Y
C0/4162: 25 10        AND $10
C0/4164: 99 22 76     STA $7622,Y
C0/4167: C8           INY 
C0/4168: C4 26        CPY $26
C0/416A: D0 BC        BNE $4128
C0/416C: A9 00        LDA #$00
C0/416E: 48           PHA 
C0/416F: AB           PLB 
C0/4170: 60           RTS 

C0/4171: 80 00 00 00
C0/4175: 80 00 08 00
C0/4179: 88 00 80 00
C0/417D: 88 00 88 00
C0/4181: A8 00 88 00
C0/4185: A8 00 8A 00
C0/4189: AA 00 8A 00
C0/418D: AA 00 AA 00
C0/4191: AA 40 AA 00
C0/4195: AA 44 AA 00
C0/4199: AA 44 AA 40
C0/419D: AA 44 AA 44
C0/41A1: AA 54 AA 44
C0/41A5: AA 55 AA 44
C0/41A9: AA 55 AA 54
C0/41AD: AA 55 AA 55
C0/41B1: EA 55 AA
C0/41B4: 55 EA        EOR $EA,X
C0/41B6: 55 AE        EOR $AE,X
C0/41B8: 55 EE        EOR $EE,X
C0/41BA: 55 AE        EOR $AE,X
C0/41BC: 55 EE        EOR $EE,X
C0/41BE: 55 EE        EOR $EE,X
C0/41C0: 55 EE        EOR $EE,X
C0/41C2: 75 EE        ADC $EE,X
C0/41C4: 55 EE        EOR $EE,X
C0/41C6: 77 EE        ADC [$EE],Y
C0/41C8: 55 EE        EOR $EE,X
C0/41CA: 77 EE        ADC [$EE],Y
C0/41CC: 57 EE        EOR [$EE],Y
C0/41CE: 77 EE        ADC [$EE],Y
C0/41D0: 77 FE        ADC [$FE],Y
C0/41D2: 77 EE        ADC [$EE],Y
C0/41D4: 77 FF        ADC [$FF],Y
C0/41D6: 77 EE        ADC [$EE],Y
C0/41D8: 77 FF        ADC [$FF],Y
C0/41DA: 77 FE        ADC [$FE],Y
C0/41DC: 77 FF        ADC [$FF],Y
C0/41DE: 77 FF        ADC [$FF],Y
C0/41E0: 77 FF        ADC [$FF],Y
C0/41E2: F7 FF        SBC [$FF],Y
C0/41E4: 77 FF        ADC [$FF],Y
C0/41E6: FF FF 77
C0/41E9: FF FF FF 7F
C0/41ED: FF FF FF FF

C0/41F1: A6 06        LDX $06
C0/41F3: A9 00        LDA #$00
C0/41F5: 9D 58 1A     STA $1A58,X
C0/41F8: C2 20        REP #$20
C0/41FA: 8A           TXA 
C0/41FB: 18           CLC 
C0/41FC: 69 08 00     ADC #$0008
C0/41FF: AA           TAX 
C0/4200: A5 06        LDA $06
C0/4202: E2 20        SEP #$20
C0/4204: E0 80 00     CPX #$0080
C0/4207: D0 EA        BNE $41F3
C0/4209: 60           RTS 

; [  ]

C0/420A: A6 06        LDX $06
C0/420C: 8E 56 1A     STX $1A56
C0/420F: A5 3F        LDA $3F
C0/4211: 4A           LSR 
C0/4212: B0 04        BCS $4218
C0/4214: A4 06        LDY $06
C0/4216: 80 03        BRA $421B
C0/4218: A0 08 00     LDY #$0008
C0/421B: 84 23        STY $23
C0/421D: A4 23        LDY $23
C0/421F: B9 58 1A     LDA $1A58,Y
C0/4222: D0 03        BNE $4227
C0/4224: 4C 40 44     JMP $4440
C0/4227: C9 10        CMP #$10
C0/4229: B0 F9        BCS $4224
C0/422B: C2 20        REP #$20
C0/422D: AD 56 1A     LDA $1A56
C0/4230: 4A           LSR 
C0/4231: 4A           LSR 
C0/4232: 4A           LSR 
C0/4233: 4A           LSR 
C0/4234: AA           TAX 
C0/4235: A9 AA AA     LDA #$AAAA
C0/4238: 9D 00 04     STA $0400,X
C0/423B: 9D 02 04     STA $0402,X
C0/423E: 9D 08 04     STA $0408,X
C0/4241: 9D 0A 04     STA $040A,X
C0/4244: B9 5A 1A     LDA $1A5A,Y
C0/4247: 85 13        STA $13
C0/4249: B9 5C 1A     LDA $1A5C,Y
C0/424C: 85 15        STA $15
C0/424E: B9 58 1A     LDA $1A58,Y
C0/4251: 29 0E 00     AND #$000E
C0/4254: 0A           ASL 
C0/4255: 0A           ASL 
C0/4256: AA           TAX 
C0/4257: C0 40 00     CPY #$0040
C0/425A: B0 06        BCS $4262
C0/425C: 98           TYA 
C0/425D: 29 30 00     AND #$0030
C0/4260: 80 07        BRA $4269
C0/4262: 98           TYA 
C0/4263: 29 30 00     AND #$0030
C0/4266: 09 80 00     ORA #$0080
C0/4269: 18           CLC 
C0/426A: 6D 56 1A     ADC $1A56
C0/426D: A8           TAY 
C0/426E: A5 06        LDA $06
C0/4270: E2 20        SEP #$20
C0/4272: A5 53        LDA $53
C0/4274: D0 03        BNE $4279
C0/4276: 4C A8 43     JMP $43A8
C0/4279: C2 20        REP #$20
C0/427B: A5 13        LDA $13
C0/427D: 38           SEC 
C0/427E: E9 10 00     SBC #$0010
C0/4281: 38           SEC 
C0/4282: E5 61        SBC $61
C0/4284: 29 FF 07     AND #$07FF
C0/4287: C9 00 02     CMP #$0200
C0/428A: B0 3A        BCS $42C6
C0/428C: 4A           LSR 
C0/428D: 85 0D        STA $0D
C0/428F: A5 15        LDA $15
C0/4291: 38           SEC 
C0/4292: E9 10 00     SBC #$0010
C0/4295: 38           SEC 
C0/4296: E5 63        SBC $63
C0/4298: 29 FF 07     AND #$07FF
C0/429B: C9 E0 07     CMP #$07E0
C0/429E: B0 05        BCS $42A5
C0/42A0: C9 E0 01     CMP #$01E0
C0/42A3: B0 21        BCS $42C6
C0/42A5: 4A           LSR 
C0/42A6: 85 0F        STA $0F
C0/42A8: A5 06        LDA $06
C0/42AA: E2 20        SEP #$20
C0/42AC: A5 0D        LDA $0D
C0/42AE: 99 00 02     STA $0200,Y
C0/42B1: A5 0F        LDA $0F
C0/42B3: 99 01 02     STA $0201,Y
C0/42B6: BF 88 44 C0  LDA $C04488,X
C0/42BA: 99 02 02     STA $0202,Y
C0/42BD: BF 89 44 C0  LDA $C04489,X
C0/42C1: 99 03 02     STA $0203,Y
C0/42C4: C2 20        REP #$20
C0/42C6: A5 13        LDA $13
C0/42C8: 18           CLC 
C0/42C9: 69 10 00     ADC #$0010
C0/42CC: 38           SEC 
C0/42CD: E5 61        SBC $61
C0/42CF: 29 FF 07     AND #$07FF
C0/42D2: C9 00 02     CMP #$0200
C0/42D5: B0 3A        BCS $4311
C0/42D7: 4A           LSR 
C0/42D8: 85 0D        STA $0D
C0/42DA: A5 15        LDA $15
C0/42DC: 38           SEC 
C0/42DD: E9 10 00     SBC #$0010
C0/42E0: 38           SEC 
C0/42E1: E5 63        SBC $63
C0/42E3: 29 FF 07     AND #$07FF
C0/42E6: C9 E0 07     CMP #$07E0
C0/42E9: B0 05        BCS $42F0
C0/42EB: C9 E0 01     CMP #$01E0
C0/42EE: B0 21        BCS $4311
C0/42F0: 4A           LSR 
C0/42F1: 85 0F        STA $0F
C0/42F3: A5 06        LDA $06
C0/42F5: E2 20        SEP #$20
C0/42F7: A5 0D        LDA $0D
C0/42F9: 99 04 02     STA $0204,Y
C0/42FC: A5 0F        LDA $0F
C0/42FE: 99 05 02     STA $0205,Y
C0/4301: BF 8A 44 C0  LDA $C0448A,X
C0/4305: 99 06 02     STA $0206,Y
C0/4308: BF 8B 44 C0  LDA $C0448B,X
C0/430C: 99 07 02     STA $0207,Y
C0/430F: C2 20        REP #$20
C0/4311: A5 13        LDA $13
C0/4313: 38           SEC 
C0/4314: E9 10 00     SBC #$0010
C0/4317: 38           SEC 
C0/4318: E5 61        SBC $61
C0/431A: 29 FF 07     AND #$07FF
C0/431D: C9 00 02     CMP #$0200
C0/4320: B0 3A        BCS $435C
C0/4322: 4A           LSR 
C0/4323: 85 0D        STA $0D
C0/4325: A5 15        LDA $15
C0/4327: 18           CLC 
C0/4328: 69 10 00     ADC #$0010
C0/432B: 38           SEC 
C0/432C: E5 63        SBC $63
C0/432E: 29 FF 07     AND #$07FF
C0/4331: C9 E0 07     CMP #$07E0
C0/4334: B0 05        BCS $433B
C0/4336: C9 E0 01     CMP #$01E0
C0/4339: B0 21        BCS $435C
C0/433B: 4A           LSR 
C0/433C: 85 0F        STA $0F
C0/433E: A5 06        LDA $06
C0/4340: E2 20        SEP #$20
C0/4342: A5 0D        LDA $0D
C0/4344: 99 08 02     STA $0208,Y
C0/4347: A5 0F        LDA $0F
C0/4349: 99 09 02     STA $0209,Y
C0/434C: BF 8C 44 C0  LDA $C0448C,X
C0/4350: 99 0A 02     STA $020A,Y
C0/4353: BF 8D 44 C0  LDA $C0448D,X
C0/4357: 99 0B 02     STA $020B,Y
C0/435A: C2 20        REP #$20
C0/435C: A5 13        LDA $13
C0/435E: 18           CLC 
C0/435F: 69 10 00     ADC #$0010
C0/4362: 38           SEC 
C0/4363: E5 61        SBC $61
C0/4365: 29 FF 07     AND #$07FF
C0/4368: C9 00 02     CMP #$0200
C0/436B: B0 38        BCS $43A5
C0/436D: 4A           LSR 
C0/436E: 85 0D        STA $0D
C0/4370: A5 15        LDA $15
C0/4372: 18           CLC 
C0/4373: 69 10 00     ADC #$0010
C0/4376: 38           SEC 
C0/4377: E5 63        SBC $63
C0/4379: 29 FF 07     AND #$07FF
C0/437C: C9 E0 07     CMP #$07E0
C0/437F: B0 05        BCS $4386
C0/4381: C9 E0 01     CMP #$01E0
C0/4384: B0 1F        BCS $43A5
C0/4386: 4A           LSR 
C0/4387: 85 0F        STA $0F
C0/4389: A5 06        LDA $06
C0/438B: E2 20        SEP #$20
C0/438D: A5 0D        LDA $0D
C0/438F: 99 0C 02     STA $020C,Y
C0/4392: A5 0F        LDA $0F
C0/4394: 99 0D 02     STA $020D,Y
C0/4397: BF 8E 44 C0  LDA $C0448E,X
C0/439B: 99 0E 02     STA $020E,Y
C0/439E: BF 8F 44 C0  LDA $C0448F,X
C0/43A2: 99 0F 02     STA $020F,Y
C0/43A5: 4C 3C 44     JMP $443C
C0/43A8: 46 14        LSR $14
C0/43AA: 66 13        ROR $13
C0/43AC: 46 16        LSR $16
C0/43AE: 66 15        ROR $15
C0/43B0: A5 13        LDA $13
C0/43B2: 38           SEC 
C0/43B3: E9 08        SBC #$08
C0/43B5: 99 00 02     STA $0200,Y
C0/43B8: A5 15        LDA $15
C0/43BA: 38           SEC 
C0/43BB: E9 08        SBC #$08
C0/43BD: 99 01 02     STA $0201,Y
C0/43C0: BF 88 44 C0  LDA $C04488,X
C0/43C4: 18           CLC 
C0/43C5: 69 20        ADC #$20
C0/43C7: 99 02 02     STA $0202,Y
C0/43CA: BF 89 44 C0  LDA $C04489,X
C0/43CE: 09 01        ORA #$01
C0/43D0: 99 03 02     STA $0203,Y
C0/43D3: A5 13        LDA $13
C0/43D5: 18           CLC 
C0/43D6: 69 08        ADC #$08
C0/43D8: 99 04 02     STA $0204,Y
C0/43DB: A5 15        LDA $15
C0/43DD: 38           SEC 
C0/43DE: E9 08        SBC #$08
C0/43E0: 99 05 02     STA $0205,Y
C0/43E3: BF 8A 44 C0  LDA $C0448A,X
C0/43E7: 18           CLC 
C0/43E8: 69 20        ADC #$20
C0/43EA: 99 06 02     STA $0206,Y
C0/43ED: BF 8B 44 C0  LDA $C0448B,X
C0/43F1: 09 01        ORA #$01
C0/43F3: 99 07 02     STA $0207,Y
C0/43F6: A5 13        LDA $13
C0/43F8: 38           SEC 
C0/43F9: E9 08        SBC #$08
C0/43FB: 99 08 02     STA $0208,Y
C0/43FE: A5 15        LDA $15
C0/4400: 18           CLC 
C0/4401: 69 08        ADC #$08
C0/4403: 99 09 02     STA $0209,Y
C0/4406: BF 8C 44 C0  LDA $C0448C,X
C0/440A: 18           CLC 
C0/440B: 69 20        ADC #$20
C0/440D: 99 0A 02     STA $020A,Y
C0/4410: BF 8D 44 C0  LDA $C0448D,X
C0/4414: 09 01        ORA #$01
C0/4416: 99 0B 02     STA $020B,Y
C0/4419: A5 13        LDA $13
C0/441B: 18           CLC 
C0/441C: 69 08        ADC #$08
C0/441E: 99 0C 02     STA $020C,Y
C0/4421: A5 15        LDA $15
C0/4423: 18           CLC 
C0/4424: 69 08        ADC #$08
C0/4426: 99 0D 02     STA $020D,Y
C0/4429: BF 8E 44 C0  LDA $C0448E,X
C0/442D: 18           CLC 
C0/442E: 69 20        ADC #$20
C0/4430: 99 0E 02     STA $020E,Y
C0/4433: BF 8F 44 C0  LDA $C0448F,X
C0/4437: 09 01        ORA #$01
C0/4439: 99 0F 02     STA $020F,Y
C0/443C: A5 06        LDA $06
C0/443E: E2 20        SEP #$20
C0/4440: A4 23        LDY $23
C0/4442: B9 58 1A     LDA $1A58,Y
C0/4445: F0 04        BEQ $444B
C0/4447: 3A           DEC 
C0/4448: 99 58 1A     STA $1A58,Y
C0/444B: C2 20        REP #$20
C0/444D: A5 23        LDA $23
C0/444F: 18           CLC 
C0/4450: 69 10 00     ADC #$0010
C0/4453: 85 23        STA $23
C0/4455: A8           TAY 
C0/4456: A5 06        LDA $06
C0/4458: E2 20        SEP #$20
C0/445A: C0 88 00     CPY #$0088
C0/445D: F0 08        BEQ $4467
C0/445F: C0 80 00     CPY #$0080
C0/4462: F0 03        BEQ $4467
C0/4464: 4C 1D 42     JMP $421D
C0/4467: 60           RTS 

C0/4468: 00 00        BRK $00
C0/446A: 01 00        ORA ($00,X)
C0/446C: 02 00        COP $00
C0/446E: 03 00        ORA $00,S
C0/4470: 04 00        TSB $00
C0/4472: 05 00        ORA $00
C0/4474: 06 00        ASL $00
C0/4476: 07 00        ORA [$00]
C0/4478: 00 00        BRK $00
C0/447A: F9 FF FA     SBC $FAFF,Y
C0/447D: FF FB FF FC  SBC $FCFFFB,X
C0/4481: FF FD FF FE  SBC $FEFFFD,X
C0/4485: FF FF FF 1E  SBC $1EFFFF,X
C0/4489: 34 3E        BIT $3E,X
C0/448B: F4 3E 34     PEA $343E
C0/448E: 1E F4 1C     ASL $1CF4,X
C0/4491: 34 3C        BIT $3C,X
C0/4493: F4 3C 34     PEA $343C
C0/4496: 1C F4 1A     TRB $1AF4
C0/4499: 34 3A        BIT $3A,X
C0/449B: F4 3A 34     PEA $343A
C0/449E: 1A           INC 
C0/449F: F4 18 34     PEA $3418
C0/44A2: 38           SEC 
C0/44A3: F4 38 34     PEA $3438
C0/44A6: 18           CLC 
C0/44A7: F4 16 34     PEA $3416
C0/44AA: 36 F4        ROL $F4,X
C0/44AC: 36 34        ROL $34,X
C0/44AE: 16 F4        ASL $F4,X
C0/44B0: 14 34        TRB $34
C0/44B2: 34 F4        BIT $F4,X
C0/44B4: 34 34        BIT $34,X
C0/44B6: 14 F4        TRB $F4
C0/44B8: 12 34        ORA ($34)
C0/44BA: 32 F4        AND ($F4)
C0/44BC: 32 34        AND ($34)
C0/44BE: 12 F4        ORA ($F4)
C0/44C0: 10 34        BPL $44F6
C0/44C2: 30 F4        BMI $44B8
C0/44C4: 30 34        BMI $44FA
C0/44C6: 10 F4        BPL $44BC

; [ show cutscene ]

; A: cutscene id

C0/44C8: 48           PHA 
C0/44C9: 9C 0B 42     STZ $420B
C0/44CC: 9C 0C 42     STZ $420C
C0/44CF: A9 00        LDA #$00
C0/44D1: 8D 00 42     STA $4200
C0/44D4: A9 80        LDA #$80
C0/44D6: 8D 00 21     STA $2100
C0/44D9: 78           SEI 
C0/44DA: 68           PLA 
C0/44DB: 22 00 00 C3  JSL $C30000     ; show cutscene
C0/44DF: 20 E3 44     JSR $44E3       ; init map bank
C0/44E2: 60           RTS 

; [ init map bank ]

C0/44E3: C2 10        REP #$10
C0/44E5: E2 20        SEP #$20
C0/44E7: A9 00        LDA #$00
C0/44E9: 48           PHA 
C0/44EA: AB           PLB 
C0/44EB: A2 00 0B     LDX #$0B00
C0/44EE: DA           PHX 
C0/44EF: 2B           PLD 
C0/44F0: 9C 0B 42     STZ $420B
C0/44F3: 9C 0C 42     STZ $420C
C0/44F6: A9 8F        LDA #$8F
C0/44F8: 8D 00 21     STA $2100
C0/44FB: A9 00        LDA #$00
C0/44FD: 8D 00 42     STA $4200
C0/4500: A9 00        LDA #$00
C0/4502: EB           XBA 
C0/4503: 20 4A 4E     JSR $4E4A       ; init interrupt jump code
C0/4506: 20 69 4E     JSR $4E69       ; init hardware registers
C0/4509: 60           RTS 

; [ init vehicles ]

C0/450A: 9C DC 0A     STZ $0ADC
C0/450D: A2 00 80     LDX #$8000
C0/4510: 8E DD 0A     STX $0ADD
C0/4513: 8E E1 0A     STX $0AE1
C0/4516: 8E E5 0A     STX $0AE5
C0/4519: 8E E9 0A     STX $0AE9
C0/451C: 8E ED 0A     STX $0AED
C0/451F: 8E F1 0A     STX $0AF1
C0/4522: A9 02        LDA #$02
C0/4524: 8D DA 0A     STA $0ADA
C0/4527: 60           RTS 

; [ init character names ]

C0/4528: A9 FF        LDA #$FF
C0/452A: A4 06        LDY $06
C0/452C: 99 90 09     STA $0990,Y
C0/452F: C8           INY 
C0/4530: C0 1E 00     CPY #$001E
C0/4533: D0 F7        BNE $452C
C0/4535: A9 CB        LDA #$CB
C0/4537: 8D 90 09     STA $0990
C0/453A: A9 FF        LDA #$FF
C0/453C: 8D 91 09     STA $0991
C0/453F: 8D 92 09     STA $0992
C0/4542: 8D 93 09     STA $0993
C0/4545: 8D 94 09     STA $0994
C0/4548: 8D 95 09     STA $0995
C0/454B: 60           RTS 

; [ open menu ]

C0/454C: 20 81 60     JSR $6081       ; fade out
C0/454F: 9C 0B 42     STZ $420B
C0/4552: 9C 0C 42     STZ $420C
C0/4555: A9 00        LDA #$00
C0/4557: 8D 00 42     STA $4200
C0/455A: A9 80        LDA #$80
C0/455C: 8D 00 21     STA $2100
C0/455F: 78           SEI 
C0/4560: 22 00 A0 C2  JSL $C2A000     ; execute menu command
C0/4564: 20 E3 44     JSR $44E3       ; init map bank
C0/4567: 20 D7 1C     JSR $1CD7       ; update showing character
C0/456A: 60           RTS 

C0/456B: A4 06        LDY $06
C0/456D: B9 00 05     LDA $0500,Y
C0/4570: 29 40        AND #$40
C0/4572: F0 0E        BEQ $4582
C0/4574: C2 20        REP #$20
C0/4576: 98           TYA 
C0/4577: 18           CLC 
C0/4578: 69 50 00     ADC #$0050
C0/457B: A8           TAY 
C0/457C: A5 06        LDA $06
C0/457E: E2 20        SEP #$20
C0/4580: 80 EB        BRA $456D
C0/4582: 60           RTS 

; [  ]

C0/4583: A9 FE        LDA #$FE
C0/4585: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/4588: C9 00        CMP #$00
C0/458A: D0 57        BNE $45E3
C0/458C: 20 35 46     JSR $4635       ; stop sound
C0/458F: AD DC 0A     LDA $0ADC       ; vehicles
C0/4592: F0 38        BEQ $45CC
C0/4594: C9 06        CMP #$06
C0/4596: D0 1C        BNE $45B4
C0/4598: AD D6 0A     LDA $0AD6       ; map index
C0/459B: C9 02        CMP #$02
C0/459D: D0 15        BNE $45B4
C0/459F: AD F1 0A     LDA $0AF1
C0/45A2: 29 03        AND #$03
C0/45A4: D0 05        BNE $45AB
C0/45A6: A9 69        LDA #$69
C0/45A8: 20 3C 46     JSR $463C       ; play sound effect
C0/45AB: A9 79        LDA #$79
C0/45AD: 20 2F CA     JSR $CA2F       ; get event flag $00xx
C0/45B0: C9 00        CMP #$00
C0/45B2: D0 18        BNE $45CC
C0/45B4: AD DC 0A     LDA $0ADC       ; current vehicle
C0/45B7: 0A           ASL 
C0/45B8: 0A           ASL 
C0/45B9: 85 08        STA $08
C0/45BB: A8           TAY 
C0/45BC: B9 D9 0A     LDA $0AD9,Y
C0/45BF: 29 03        AND #$03
C0/45C1: 05 08        ORA $08
C0/45C3: AA           TAX 
C0/45C4: BF EE 45 C0  LDA $C045EE,X
C0/45C8: F0 02        BEQ $45CC
C0/45CA: 80 14        BRA $45E0
C0/45CC: A9 7F        LDA #$7F
C0/45CE: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/45D1: C9 00        CMP #$00
C0/45D3: F0 02        BEQ $45D7
C0/45D5: A9 05        LDA #$05
C0/45D7: 18           CLC 
C0/45D8: 6D D6 0A     ADC $0AD6       ; map index
C0/45DB: AA           TAX 
C0/45DC: BF E4 45 C0  LDA $C045E4,X
C0/45E0: 20 0A 46     JSR $460A       ; play song
C0/45E3: 60           RTS 

; default song for each vehicle
C0/45E4: 23 46 23 1E 1E 23 27 3F 1E 1E

; alt. songs for each vehicle (4 bytes each)
C0/45EE: 00 00 00 00
         03 00 00 00
         1A 00 00 00
         1D 00 00 00
         1E 1E 1E 1E
C0/4602: 00 18 00 00
C0/4606: 28 00 1E 00

; [ play song ]

C0/460A: 85 08        STA $08
C0/460C: A5 55        LDA $55
C0/460E: C9 02        CMP #$02
C0/4610: F0 22        BEQ $4634
C0/4612: A5 08        LDA $08         ; song id
C0/4614: 8D 01 1D     STA $1D01
C0/4617: A9 01        LDA #$01        ; play song
C0/4619: 8D 00 1D     STA $1D00
C0/461C: A9 0F        LDA #$0F        ; full volume
C0/461E: 8D 03 1D     STA $1D03
C0/4621: A5 55        LDA $55
C0/4623: C9 01        CMP #$01
C0/4625: F0 04        BEQ $462B
C0/4627: A9 08        LDA #$08        ; no fade in
C0/4629: 80 02        BRA $462D
C0/462B: A9 28        LDA #$28        ; fade in
C0/462D: 8D 02 1D     STA $1D02
C0/4630: 22 04 00 C4  JSL $C40004
C0/4634: 60           RTS 

; [ stop sound ]

C0/4635: A9 F2        LDA #$F2        ; stop sound
C0/4637: 8D 00 1D     STA $1D00
C0/463A: 80 12        BRA $464E

; [ play sound effect ]

; A: sound effect

C0/463C: 8D 01 1D     STA $1D01
C0/463F: A9 02        LDA #$02        ; play sound effect
C0/4641: 8D 00 1D     STA $1D00
C0/4644: A9 0F        LDA #$0F        ; full volume, no envelope
C0/4646: 8D 02 1D     STA $1D02
C0/4649: A9 88        LDA #$88
C0/464B: 8D 03 1D     STA $1D03
C0/464E: 22 04 00 C4  JSL $C40004
C0/4652: 60           RTS 

; [ update screen pixelation ]

C0/4653: AD AA 16     LDA $16AA
C0/4656: 30 32        BMI $468A
C0/4658: F0 2C        BEQ $4686       ; branch if no pixelation
C0/465A: C2 20        REP #$20
C0/465C: AD AA 16     LDA $16AA
C0/465F: 1A           INC 
C0/4660: 29 FF 00     AND #$00FF
C0/4663: 0A           ASL 
C0/4664: 0A           ASL 
C0/4665: 0A           ASL 
C0/4666: 0A           ASL 
C0/4667: 85 19        STA $19
C0/4669: AD AB 16     LDA $16AB
C0/466C: 38           SEC 
C0/466D: E5 19        SBC $19
C0/466F: 8D AB 16     STA $16AB
C0/4672: 10 06        BPL $467A
C0/4674: 9C AB 16     STZ $16AB
C0/4677: 9C AA 16     STZ $16AA
C0/467A: A5 06        LDA $06
C0/467C: E2 20        SEP #$20
C0/467E: AD AC 16     LDA $16AC
C0/4681: AA           TAX 
C0/4682: BF A6 46 C0  LDA $C046A6,X
C0/4686: 8D 06 21     STA $2106       ; pixelation register
C0/4689: 60           RTS 
C0/468A: A5 57        LDA $57
C0/468C: D0 FB        BNE $4689
C0/468E: A5 BA        LDA $BA
C0/4690: F0 05        BEQ $4697
C0/4692: A5 41        LDA $41
C0/4694: 29 0E        AND #$0E
C0/4696: 4A           LSR 
C0/4697: AA           TAX 
C0/4698: BF 9E 46 C0  LDA $C0469E,X
C0/469C: 80 E8        BRA $4686

; screen pixelation data (poison)
C0/469E: 0F 1F 2F 3F
C0/46A2: 3F 2F 1F 0F

; screen pixelation data (event)
C0/46A6: 0F 1F 2F 3F
C0/46AA: 4F 5F 6F 7F
C0/46AE: 8F 9F AF BF
C0/46B2: CF DF EF FF
C0/46B6: EF DF CF BF
C0/46BA: AF 9F 8F 7F
C0/46BE: 6F 5F 4F 3F
C0/46C2: 2F 1F

C0/46C4: A9 70        LDA #$70
C0/46C6: 8D 79 18     STA $1879
C0/46C9: A9 7B        LDA #$7B
C0/46CB: 8D 7A 18     STA $187A
C0/46CE: A4 06        LDY $06
C0/46D0: 64 09        STZ $09
C0/46D2: A5 09        LDA $09
C0/46D4: 99 80 18     STA $1880,Y
C0/46D7: 20 2B 4F     JSR $4F2B       ; generate random number
C0/46DA: 29 01        AND #$01
C0/46DC: 99 82 18     STA $1882,Y
C0/46DF: 20 2B 4F     JSR $4F2B       ; generate random number
C0/46E2: 29 07        AND #$07
C0/46E4: 18           CLC 
C0/46E5: 69 18        ADC #$18
C0/46E7: 99 83 18     STA $1883,Y
C0/46EA: A9 00        LDA #$00
C0/46EC: 99 7F 18     STA $187F,Y
C0/46EF: 99 81 18     STA $1881,Y
C0/46F2: 99 84 18     STA $1884,Y
C0/46F5: A5 09        LDA $09
C0/46F7: 0A           ASL 
C0/46F8: AA           TAX 
C0/46F9: C2 20        REP #$20
C0/46FB: BF 21 47 C0  LDA $C04721,X
C0/46FF: 99 7B 18     STA $187B,Y
C0/4702: A5 06        LDA $06
C0/4704: E2 20        SEP #$20
C0/4706: 20 2B 4F     JSR $4F2B       ; generate random number
C0/4709: 29 30        AND #$30
C0/470B: 09 C0        ORA #$C0
C0/470D: 99 7D 18     STA $187D,Y
C0/4710: A9 00        LDA #$00
C0/4712: 99 7E 18     STA $187E,Y
C0/4715: E6 09        INC $09
C0/4717: 98           TYA 
C0/4718: 18           CLC 
C0/4719: 69 0A        ADC #$0A
C0/471B: A8           TAY 
C0/471C: C9 A0        CMP #$A0
C0/471E: D0 B2        BNE $46D2
C0/4720: 60           RTS 

C0/4721: 80 FF        BRA $4722
C0/4723: 90 FF        BCC $4724
C0/4725: A0 FF B0     LDY #$B0FF
C0/4728: FF C0 FF D0  SBC $D0FFC0,X
C0/472C: FF E0 FF F0  SBC $F0FFE0,X
C0/4730: FF 10 00 20  SBC $200010,X
C0/4734: 00 30        BRK $30
C0/4736: 00 40        BRK $40
C0/4738: 00 50        BRK $50
C0/473A: 00 60        BRK $60
C0/473C: 00 70        BRK $70
C0/473E: 00 80        BRK $80
C0/4740: 00

C0/4741: A5 5B        LDA $5B
C0/4743: D0 01        BNE $4746
C0/4745: 60           RTS 
C0/4746: A4 06        LDY $06
C0/4748: B9 83 18     LDA $1883,Y
C0/474B: D0 41        BNE $478E
C0/474D: B9 84 18     LDA $1884,Y
C0/4750: D0 3C        BNE $478E
C0/4752: 20 2B 4F     JSR $4F2B       ; generate random number
C0/4755: 29 0F        AND #$0F
C0/4757: 99 80 18     STA $1880,Y
C0/475A: 20 2B 4F     JSR $4F2B       ; generate random number
C0/475D: 29 03        AND #$03
C0/475F: 18           CLC 
C0/4760: 65 6F        ADC $6F
C0/4762: 65 6F        ADC $6F
C0/4764: 99 82 18     STA $1882,Y
C0/4767: 20 2B 4F     JSR $4F2B       ; generate random number
C0/476A: 29 07        AND #$07
C0/476C: 18           CLC 
C0/476D: 69 06        ADC #$06
C0/476F: 99 83 18     STA $1883,Y
C0/4772: C2 20        REP #$20
C0/4774: A5 06        LDA $06
C0/4776: 99 7B 18     STA $187B,Y
C0/4779: A9 80 00     LDA #$0080
C0/477C: 99 7D 18     STA $187D,Y
C0/477F: A5 06        LDA $06
C0/4781: E2 20        SEP #$20
C0/4783: A9 00        LDA #$00
C0/4785: 99 7F 18     STA $187F,Y
C0/4788: 99 81 18     STA $1881,Y
C0/478B: 99 84 18     STA $1884,Y
C0/478E: 98           TYA 
C0/478F: 18           CLC 
C0/4790: 69 0A        ADC #$0A
C0/4792: A8           TAY 
C0/4793: C9 A0        CMP #$A0
C0/4795: D0 B1        BNE $4748
C0/4797: 60           RTS 
C0/4798: A6 06        LDX $06
C0/479A: 9E 83 18     STZ $1883,X
C0/479D: 9E 84 18     STZ $1884,X
C0/47A0: 8A           TXA 
C0/47A1: 18           CLC 
C0/47A2: 69 0A        ADC #$0A
C0/47A4: AA           TAX 
C0/47A5: C9 A0        CMP #$A0
C0/47A7: D0 F1        BNE $479A
C0/47A9: 60           RTS 
C0/47AA: A5 5B        LDA $5B
C0/47AC: F0 48        BEQ $47F6
C0/47AE: A4 06        LDY $06
C0/47B0: 84 17        STY $17
C0/47B2: C2 20        REP #$20
C0/47B4: A5 17        LDA $17
C0/47B6: 0A           ASL 
C0/47B7: 85 19        STA $19
C0/47B9: 0A           ASL 
C0/47BA: 0A           ASL 
C0/47BB: 18           CLC 
C0/47BC: 65 19        ADC $19
C0/47BE: A8           TAY 
C0/47BF: BE 83 18     LDX $1883,Y
C0/47C2: F0 25        BEQ $47E9
C0/47C4: B9 7F 18     LDA $187F,Y
C0/47C7: 18           CLC 
C0/47C8: 79 7B 18     ADC $187B,Y
C0/47CB: 99 7F 18     STA $187F,Y
C0/47CE: B9 81 18     LDA $1881,Y
C0/47D1: 18           CLC 
C0/47D2: 79 7D 18     ADC $187D,Y
C0/47D5: 99 81 18     STA $1881,Y
C0/47D8: B9 83 18     LDA $1883,Y
C0/47DB: 3A           DEC 
C0/47DC: 99 83 18     STA $1883,Y
C0/47DF: B9 7D 18     LDA $187D,Y
C0/47E2: 38           SEC 
C0/47E3: E9 10 00     SBC #$0010
C0/47E6: 99 7D 18     STA $187D,Y
C0/47E9: E6 17        INC $17
C0/47EB: A5 17        LDA $17
C0/47ED: C9 10 00     CMP #$0010
C0/47F0: D0 C2        BNE $47B4
C0/47F2: A5 06        LDA $06
C0/47F4: E2 20        SEP #$20
C0/47F6: 60           RTS 
C0/47F7: AE 73 18     LDX $1873
C0/47FA: A4 06        LDY $06
C0/47FC: B9 83 18     LDA $1883,Y
C0/47FF: D0 05        BNE $4806
C0/4801: B9 84 18     LDA $1884,Y
C0/4804: F0 20        BEQ $4826
C0/4806: B9 80 18     LDA $1880,Y
C0/4809: 18           CLC 
C0/480A: 6D 79 18     ADC $1879
C0/480D: 9D 00 02     STA $0200,X
C0/4810: B9 82 18     LDA $1882,Y
C0/4813: 49 FF        EOR #$FF
C0/4815: 38           SEC 
C0/4816: 6D 7A 18     ADC $187A
C0/4819: 9D 01 02     STA $0201,X
C0/481C: A9 47        LDA #$47
C0/481E: 9D 02 02     STA $0202,X
C0/4821: A9 30        LDA #$30
C0/4823: 9D 03 02     STA $0203,X
C0/4826: E8           INX 
C0/4827: E8           INX 
C0/4828: E8           INX 
C0/4829: E8           INX 
C0/482A: 98           TYA 
C0/482B: 18           CLC 
C0/482C: 69 0A        ADC #$0A
C0/482E: A8           TAY 
C0/482F: C9 A0        CMP #$A0
C0/4831: D0 C9        BNE $47FC
C0/4833: 60           RTS 
C0/4834: AD FB 0A     LDA $0AFB
C0/4837: C9 02        CMP #$02
C0/4839: F0 01        BEQ $483C
C0/483B: 60           RTS 
C0/483C: A9 C8        LDA #$C8
C0/483E: 8D 01 02     STA $0201
C0/4841: 8D 05 02     STA $0205
C0/4844: 8D 09 02     STA $0209
C0/4847: 8D 0D 02     STA $020D
C0/484A: 8D 11 02     STA $0211
C0/484D: A9 C0        LDA #$C0
C0/484F: 8D 00 02     STA $0200
C0/4852: A9 C8        LDA #$C8
C0/4854: 8D 04 02     STA $0204
C0/4857: A9 D0        LDA #$D0
C0/4859: 8D 10 02     STA $0210
C0/485C: A9 D8        LDA #$D8
C0/485E: 8D 08 02     STA $0208
C0/4861: A9 E0        LDA #$E0
C0/4863: 8D 0C 02     STA $020C
C0/4866: A9 30        LDA #$30
C0/4868: 8D 03 02     STA $0203
C0/486B: 8D 07 02     STA $0207
C0/486E: 8D 0B 02     STA $020B
C0/4871: 8D 0F 02     STA $020F
C0/4874: 8D 13 02     STA $0213
C0/4877: AE FC 0A     LDX $0AFC
C0/487A: 8E 04 42     STX $4204
C0/487D: A9 3C        LDA #$3C
C0/487F: 8D 06 42     STA $4206
C0/4882: 48           PHA 
C0/4883: 68           PLA 
C0/4884: 48           PHA 
C0/4885: 68           PLA 
C0/4886: EA           NOP 
C0/4887: AE 14 42     LDX $4214
C0/488A: 8E 04 42     STX $4204
C0/488D: A9 0A        LDA #$0A
C0/488F: 8D 06 42     STA $4206
C0/4892: 48           PHA 
C0/4893: 68           PLA 
C0/4894: 48           PHA 
C0/4895: 68           PLA 
C0/4896: EA           NOP 
C0/4897: AD 16 42     LDA $4216
C0/489A: 09 40        ORA #$40
C0/489C: 8D 0E 02     STA $020E
C0/489F: AE 14 42     LDX $4214
C0/48A2: 8E 04 42     STX $4204
C0/48A5: A9 06        LDA #$06
C0/48A7: 8D 06 42     STA $4206
C0/48AA: 48           PHA 
C0/48AB: 68           PLA 
C0/48AC: 48           PHA 
C0/48AD: 68           PLA 
C0/48AE: EA           NOP 
C0/48AF: AD 16 42     LDA $4216
C0/48B2: 09 40        ORA #$40
C0/48B4: 8D 0A 02     STA $020A
C0/48B7: AE 14 42     LDX $4214
C0/48BA: 8E 04 42     STX $4204
C0/48BD: A9 0A        LDA #$0A
C0/48BF: 8D 06 42     STA $4206
C0/48C2: 48           PHA 
C0/48C3: 68           PLA 
C0/48C4: 48           PHA 
C0/48C5: 68           PLA 
C0/48C6: EA           NOP 
C0/48C7: AD 16 42     LDA $4216
C0/48CA: 09 40        ORA #$40
C0/48CC: 8D 06 02     STA $0206
C0/48CF: AD 14 42     LDA $4214
C0/48D2: 09 40        ORA #$40
C0/48D4: 8D 02 02     STA $0202
C0/48D7: A9 4F        LDA #$4F
C0/48D9: 8D 12 02     STA $0212
C0/48DC: 60           RTS 

; [ init npc flags ]

C0/48DD: A6 06        LDX $06
C0/48DF: BF 00 E0 D8  LDA $D8E000,X
C0/48E3: 9D 54 0A     STA $0A54,X
C0/48E6: E8           INX 
C0/48E7: E0 80 00     CPX #$0080
C0/48EA: D0 F3        BNE $48DF
C0/48EC: 60           RTS 

; [ init event flags ]

C0/48ED: A4 06        LDY $06
C0/48EF: 98           TYA 
C0/48F0: 99 14 0A     STA $0A14,Y
C0/48F3: C8           INY 
C0/48F4: C0 40 00     CPY #$0040
C0/48F7: D0 F7        BNE $48F0
C0/48F9: 60           RTS 

; [ init character data (new game) ]

C0/48FA: A6 06        LDX $06
C0/48FC: BF 00 70 D1  LDA $D17000,X
C0/4900: 9D 00 05     STA $0500,X
C0/4903: E8           INX 
C0/4904: E0 40 01     CPX #$0140
C0/4907: D0 F3        BNE $48FC
C0/4909: 60           RTS 

; [ reset ram $0000-$1D00 ]

C0/490A: C2 20        REP #$20
C0/490C: A4 06        LDY $06
C0/490E: A5 06        LDA $06
C0/4910: 99 00 00     STA $0000,Y
C0/4913: C8           INY 
C0/4914: C8           INY 
C0/4915: C0 00 1D     CPY #$1D00
C0/4918: D0 F6        BNE $4910
C0/491A: E2 20        SEP #$20
C0/491C: 60           RTS 

; [ reset ram $0B00-$1D00 ]

C0/491D: C2 20        REP #$20
C0/491F: A0 00 0B     LDY #$0B00
C0/4922: A5 06        LDA $06
C0/4924: 99 00 00     STA $0000,Y
C0/4927: C8           INY 
C0/4928: C8           INY 
C0/4929: C0 00 1D     CPY #$1D00
C0/492C: D0 F6        BNE $4924
C0/492E: E2 20        SEP #$20
C0/4930: 60           RTS 

C0/4931: A5 D3        LDA $D3
C0/4933: D0 17        BNE $494C
C0/4935: A6 06        LDX $06
C0/4937: 8E A0 10     STX $10A0
C0/493A: 8E A2 10     STX $10A2
C0/493D: 8E A4 10     STX $10A4
C0/4940: 8E A6 10     STX $10A6
C0/4943: 8E A8 10     STX $10A8
C0/4946: 8E AA 10     STX $10AA
C0/4949: 4C D2 49     JMP $49D2
C0/494C: A5 D3        LDA $D3
C0/494E: 4A           LSR 
C0/494F: 4A           LSR 
C0/4950: 4A           LSR 
C0/4951: 4A           LSR 
C0/4952: 4A           LSR 
C0/4953: 4A           LSR 
C0/4954: 85 17        STA $17
C0/4956: A5 3F        LDA $3F
C0/4958: 25 17        AND $17
C0/495A: D0 76        BNE $49D2
C0/495C: A5 D3        LDA $D3
C0/495E: 29 03        AND #$03
C0/4960: AA           TAX 
C0/4961: BF D3 49 C0  LDA $C049D3,X
C0/4965: 85 17        STA $17
C0/4967: A5 3F        LDA $3F
C0/4969: AA           TAX 
C0/496A: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C0/496E: 25 17        AND $17
C0/4970: 8D A0 10     STA $10A0
C0/4973: 8D A4 10     STA $10A4
C0/4976: 8D A8 10     STA $10A8
C0/4979: A5 D3        LDA $D3
C0/497B: 4A           LSR 
C0/497C: 4A           LSR 
C0/497D: 29 03        AND #$03
C0/497F: AA           TAX 
C0/4980: BF D3 49 C0  LDA $C049D3,X
C0/4984: 85 17        STA $17
C0/4986: A5 3F        LDA $3F
C0/4988: AA           TAX 
C0/4989: BF C1 FE C0  LDA $C0FEC1,X
C0/498D: 25 17        AND $17
C0/498F: 8D A2 10     STA $10A2
C0/4992: 8D A6 10     STA $10A6
C0/4995: 8D AA 10     STA $10AA
C0/4998: A5 D3        LDA $D3
C0/499A: 29 30        AND #$30
C0/499C: 4A           LSR 
C0/499D: 4A           LSR 
C0/499E: 4A           LSR 
C0/499F: 4A           LSR 
C0/49A0: F0 30        BEQ $49D2
C0/49A2: C9 01        CMP #$01
C0/49A4: D0 0E        BNE $49B4
C0/49A6: 9C A4 10     STZ $10A4
C0/49A9: 9C A6 10     STZ $10A6
C0/49AC: 9C A8 10     STZ $10A8
C0/49AF: 9C AA 10     STZ $10AA
C0/49B2: 80 1E        BRA $49D2
C0/49B4: C9 02        CMP #$02
C0/49B6: D0 0E        BNE $49C6
C0/49B8: 9C A0 10     STZ $10A0
C0/49BB: 9C A2 10     STZ $10A2
C0/49BE: 9C A8 10     STZ $10A8
C0/49C1: 9C AA 10     STZ $10AA
C0/49C4: 80 0C        BRA $49D2
C0/49C6: 9C A4 10     STZ $10A4
C0/49C9: 9C A6 10     STZ $10A6
C0/49CC: 9C A0 10     STZ $10A0
C0/49CF: 9C A2 10     STZ $10A2
C0/49D2: 60           RTS 

C0/49D3: 00 01 03 07

; [ init color addition ]

C0/49D7: 48           PHA 
C0/49D8: A5 47        LDA $47         ; save previous values
C0/49DA: 85 48        STA $48
C0/49DC: A5 49        LDA $49
C0/49DE: 85 4A        STA $4A
C0/49E0: 64 49        STZ $49
C0/49E2: A9 07        LDA #$07        ; color addition
C0/49E4: 85 47        STA $47
C0/49E6: 68           PLA 
C0/49E7: 80 10        BRA $49F9

; [ init color subtraction ]

C0/49E9: 48           PHA 
C0/49EA: A5 47        LDA $47         ; save previous values
C0/49EC: 85 48        STA $48
C0/49EE: A5 49        LDA $49
C0/49F0: 85 4A        STA $4A
C0/49F2: 64 49        STZ $49
C0/49F4: A9 87        LDA #$87        ; color subtraction
C0/49F6: 85 47        STA $47
C0/49F8: 68           PLA 
C0/49F9: 20 44 4A     JSR $4A44       ; set fixed color parameters
C0/49FC: 64 46        STZ $46
C0/49FE: 60           RTS 

; [ update fixed color ]

C0/49FF: A5 44        LDA $44         ; rate
C0/4A01: 10 1B        BPL $4A1E       ; branch if decreasing
C0/4A03: 29 7F        AND #$7F
C0/4A05: 18           CLC 
C0/4A06: 65 46        ADC $46         ; increase intensity
C0/4A08: 85 46        STA $46
C0/4A0A: A5 4C        LDA $4C
C0/4A0C: 29 1F        AND #$1F
C0/4A0E: 0A           ASL 
C0/4A0F: 0A           ASL 
C0/4A10: 0A           ASL 
C0/4A11: C5 46        CMP $46
C0/4A13: B0 1E        BCS $4A33
C0/4A15: A5 46        LDA $46
C0/4A17: 29 F8        AND #$F8
C0/4A19: 85 46        STA $46
C0/4A1B: 4C 33 4A     JMP $4A33
C0/4A1E: A5 46        LDA $46
C0/4A20: F0 07        BEQ $4A29
C0/4A22: 38           SEC 
C0/4A23: E5 44        SBC $44         ; decrease intensity
C0/4A25: 85 46        STA $46
C0/4A27: 80 0A        BRA $4A33
C0/4A29: A5 48        LDA $48         ; restore original fixed color values
C0/4A2B: 85 47        STA $47
C0/4A2D: A5 4A        LDA $4A
C0/4A2F: 85 49        STA $49
C0/4A31: 64 44        STZ $44
C0/4A33: A5 46        LDA $46
C0/4A35: 4A           LSR 
C0/4A36: 4A           LSR 
C0/4A37: 4A           LSR 
C0/4A38: 85 17        STA $17
C0/4A3A: A5 4C        LDA $4C         ; color components
C0/4A3C: 29 E0        AND #$E0
C0/4A3E: 05 17        ORA $17
C0/4A40: 8D 32 21     STA $2132       ; fixed color
C0/4A43: 60           RTS 

; [ set fixed color parameters ]

C0/4A44: 48           PHA 
C0/4A45: 48           PHA 
C0/4A46: 29 E0        AND #$E0        ; color components
C0/4A48: 85 08        STA $08
C0/4A4A: 68           PLA 
C0/4A4B: 29 07        AND #$07        ; intensity
C0/4A4D: 0A           ASL 
C0/4A4E: 0A           ASL 
C0/4A4F: 18           CLC 
C0/4A50: 69 03        ADC #$03
C0/4A52: 05 08        ORA $08
C0/4A54: 85 4C        STA $4C
C0/4A56: 68           PLA 
C0/4A57: 29 18        AND #$18        ; speed
C0/4A59: 4A           LSR 
C0/4A5A: 4A           LSR 
C0/4A5B: 4A           LSR 
C0/4A5C: AA           TAX 
C0/4A5D: BF 64 4A C0  LDA $C04A64,X
C0/4A61: 85 44        STA $44         ; fixed color rate
C0/4A63: 60           RTS 

C0/4A64: 81 82 84 84

C0/4A68: A9 10        LDA #$10
C0/4A6A: 85 43        STA $43
C0/4A6C: A9 10        LDA #$10
C0/4A6E: 85 45        STA $45
C0/4A70: 60           RTS 
C0/4A71: A9 90        LDA #$90
C0/4A73: 85 43        STA $43
C0/4A75: A9 F0        LDA #$F0
C0/4A77: 85 45        STA $45
C0/4A79: 60           RTS 
C0/4A7A: A5 43        LDA $43
C0/4A7C: 30 14        BMI $4A92
C0/4A7E: A5 45        LDA $45
C0/4A80: 29 F0        AND #$F0
C0/4A82: C9 F0        CMP #$F0
C0/4A84: F0 1D        BEQ $4AA3
C0/4A86: A5 43        LDA $43
C0/4A88: 29 1F        AND #$1F
C0/4A8A: 18           CLC 
C0/4A8B: 65 45        ADC $45
C0/4A8D: 85 45        STA $45
C0/4A8F: 4C A3 4A     JMP $4AA3
C0/4A92: A5 45        LDA $45
C0/4A94: F0 0D        BEQ $4AA3
C0/4A96: A5 43        LDA $43
C0/4A98: 29 1F        AND #$1F
C0/4A9A: 85 19        STA $19
C0/4A9C: A5 45        LDA $45
C0/4A9E: 38           SEC 
C0/4A9F: E5 19        SBC $19
C0/4AA1: 85 45        STA $45
C0/4AA3: A5 45        LDA $45
C0/4AA5: 4A           LSR 
C0/4AA6: 4A           LSR 
C0/4AA7: 4A           LSR 
C0/4AA8: 4A           LSR 
C0/4AA9: 8D 00 21     STA $2100
C0/4AAC: 60           RTS 
C0/4AAD: 20 41 4E     JSR $4E41       ; wait for vblank
C0/4AB0: 20 7C 23     JSR $237C       ; update party sprite
C0/4AB3: 20 B3 39     JSR $39B3       ; update object sprites
C0/4AB6: A5 02        LDA $02
C0/4AB8: 29 CF        AND #$CF
C0/4ABA: D0 F1        BNE $4AAD
C0/4ABC: A5 03        LDA $03
C0/4ABE: D0 ED        BNE $4AAD
C0/4AC0: 60           RTS 

; [ wait for keypress ]

C0/4AC1: 20 41 4E     JSR $4E41       ; wait for vblank
C0/4AC4: 20 7C 23     JSR $237C       ; update party sprite
C0/4AC7: 20 B3 39     JSR $39B3       ; update object sprites
C0/4ACA: A5 02        LDA $02
C0/4ACC: 29 CF        AND #$CF
C0/4ACE: D0 04        BNE $4AD4
C0/4AD0: A5 03        LDA $03
C0/4AD2: F0 ED        BEQ $4AC1
C0/4AD4: 60           RTS 

; [ copy 3bpp graphics to vram ]

; +$30: source address (+$DB0000)
; +$33: vram address
;  $35: tile count

C0/4AD5: 9C 0B 42     STZ $420B
C0/4AD8: A9 80        LDA #$80
C0/4ADA: 8D 15 21     STA $2115
C0/4ADD: A9 08        LDA #$08
C0/4ADF: 8D 00 43     STA $4300
C0/4AE2: A9 19        LDA #$19
C0/4AE4: 8D 01 43     STA $4301
C0/4AE7: A6 33        LDX $33
C0/4AE9: 8E 16 21     STX $2116
C0/4AEC: A2 06 0B     LDX #$0B06
C0/4AEF: 8E 02 43     STX $4302
C0/4AF2: 9C 04 43     STZ $4304
C0/4AF5: C2 20        REP #$20
C0/4AF7: A5 35        LDA $35
C0/4AF9: 0A           ASL 
C0/4AFA: 0A           ASL 
C0/4AFB: 0A           ASL 
C0/4AFC: 85 17        STA $17
C0/4AFE: 0A           ASL 
C0/4AFF: 18           CLC 
C0/4B00: 65 17        ADC $17
C0/4B02: 8D 05 43     STA $4305
C0/4B05: A5 06        LDA $06
C0/4B07: E2 20        SEP #$20
C0/4B09: A9 01        LDA #$01
C0/4B0B: 8D 0B 42     STA $420B
C0/4B0E: 9C 0B 42     STZ $420B
C0/4B11: A6 30        LDX $30
C0/4B13: 8E 02 43     STX $4302
C0/4B16: A9 DB        LDA #$DB
C0/4B18: 8D 04 43     STA $4304
C0/4B1B: A9 18        LDA #$18
C0/4B1D: 8D 01 43     STA $4301
C0/4B20: A6 33        LDX $33
C0/4B22: 8E 16 21     STX $2116
C0/4B25: A4 06        LDY $06
C0/4B27: A9 80        LDA #$80
C0/4B29: 8D 15 21     STA $2115
C0/4B2C: A9 01        LDA #$01
C0/4B2E: 8D 00 43     STA $4300
C0/4B31: A2 10 00     LDX #$0010
C0/4B34: 8E 05 43     STX $4305
C0/4B37: A9 01        LDA #$01
C0/4B39: 8D 0B 42     STA $420B
C0/4B3C: 9C 0B 42     STZ $420B
C0/4B3F: 9C 15 21     STZ $2115
C0/4B42: 9C 00 43     STZ $4300
C0/4B45: A2 08 00     LDX #$0008
C0/4B48: 8E 05 43     STX $4305
C0/4B4B: A9 01        LDA #$01
C0/4B4D: 8D 0B 42     STA $420B
C0/4B50: C8           INY 
C0/4B51: C4 35        CPY $35
C0/4B53: D0 D2        BNE $4B27
C0/4B55: 60           RTS 

C0/4B56: A9 80        LDA #$80
C0/4B58: 8D 15 21     STA $2115
C0/4B5B: A6 06        LDX $06
C0/4B5D: 8E 16 21     STX $2116
C0/4B60: AD D6 0A     LDA $0AD6       ; map index
C0/4B63: AA           TAX 
C0/4B64: BF BB 4B C0  LDA $C04BBB,X
C0/4B68: 85 24        STA $24
C0/4B6A: 64 23        STZ $23
C0/4B6C: A6 23        LDX $23
C0/4B6E: A4 06        LDY $06
C0/4B70: BF C0 F9 CF  LDA $CFF9C0,X
C0/4B74: 99 73 18     STA $1873,Y
C0/4B77: E8           INX 
C0/4B78: C8           INY 
C0/4B79: C0 00 01     CPY #$0100
C0/4B7C: D0 F2        BNE $4B70
C0/4B7E: AD D6 0A     LDA $0AD6       ; map index
C0/4B81: AA           TAX 
C0/4B82: BF BB 4B C0  LDA $C04BBB,X
C0/4B86: 0A           ASL 
C0/4B87: 0A           ASL 
C0/4B88: 0A           ASL 
C0/4B89: 0A           ASL 
C0/4B8A: 0A           ASL 
C0/4B8B: 85 24        STA $24
C0/4B8D: 64 23        STZ $23
C0/4B8F: A6 23        LDX $23
C0/4B91: A0 00 00     LDY #$0000
C0/4B94: BF 00 80 DB  LDA $DB8000,X
C0/4B98: 85 0A        STA $0A
C0/4B9A: E8           INX 
C0/4B9B: 29 0F        AND #$0F
C0/4B9D: 19 73 18     ORA $1873,Y
C0/4BA0: 8D 19 21     STA $2119
C0/4BA3: A5 0A        LDA $0A
C0/4BA5: 4A           LSR 
C0/4BA6: 4A           LSR 
C0/4BA7: 4A           LSR 
C0/4BA8: 4A           LSR 
C0/4BA9: 19 73 18     ORA $1873,Y
C0/4BAC: 8D 19 21     STA $2119
C0/4BAF: 8A           TXA 
C0/4BB0: 29 1F        AND #$1F
C0/4BB2: D0 E0        BNE $4B94
C0/4BB4: C8           INY 
C0/4BB5: C0 00 01     CPY #$0100
C0/4BB8: D0 DA        BNE $4B94
C0/4BBA: 60           RTS 

C0/4BBB:              .DB $00, $01, $00, $02, $02

; [ update scrolling registers ]

C0/4BC0: C2 20        REP #$20
C0/4BC2: A5 61        LDA $61
C0/4BC4: 4A           LSR 
C0/4BC5: 18           CLC 
C0/4BC6: 6D A0 10     ADC $10A0
C0/4BC9: 85 17        STA $17
C0/4BCB: A5 63        LDA $63
C0/4BCD: 4A           LSR 
C0/4BCE: 18           CLC 
C0/4BCF: 6D A2 10     ADC $10A2
C0/4BD2: 85 19        STA $19
C0/4BD4: A5 65        LDA $65
C0/4BD6: 38           SEC 
C0/4BD7: ED 98 10     SBC $1098
C0/4BDA: 85 65        STA $65
C0/4BDC: 4A           LSR 
C0/4BDD: 18           CLC 
C0/4BDE: 6D A4 10     ADC $10A4
C0/4BE1: 85 1B        STA $1B
C0/4BE3: A5 67        LDA $67
C0/4BE5: 38           SEC 
C0/4BE6: ED 9A 10     SBC $109A
C0/4BE9: 85 67        STA $67
C0/4BEB: 4A           LSR 
C0/4BEC: 18           CLC 
C0/4BED: 6D A6 10     ADC $10A6
C0/4BF0: 85 1D        STA $1D
C0/4BF2: A5 69        LDA $69
C0/4BF4: 38           SEC 
C0/4BF5: ED 9C 10     SBC $109C
C0/4BF8: 85 69        STA $69
C0/4BFA: 4A           LSR 
C0/4BFB: 18           CLC 
C0/4BFC: 6D A8 10     ADC $10A8
C0/4BFF: 85 1F        STA $1F
C0/4C01: AD D4 0A     LDA $0AD4
C0/4C04: C9 BE 00     CMP #$BE
C0/4C07: D0 0D        BNE $4C16
C0/4C09: A5 3F        LDA $3F
C0/4C0B: 4A           LSR 
C0/4C0C: 4A           LSR 
C0/4C0D: B0 07        BCS $4C16
C0/4C0F: A5 1F        LDA $1F
C0/4C11: 49 00 01     EOR #$0100
C0/4C14: 85 1F        STA $1F
C0/4C16: A5 6B        LDA $6B
C0/4C18: 38           SEC 
C0/4C19: ED 9E 10     SBC $109E
C0/4C1C: 85 6B        STA $6B
C0/4C1E: 4A           LSR 
C0/4C1F: 18           CLC 
C0/4C20: 6D AA 10     ADC $10AA
C0/4C23: 85 21        STA $21
C0/4C25: A5 06        LDA $06
C0/4C27: E2 20        SEP #$20
C0/4C29: A5 17        LDA $17
C0/4C2B: 8D 0D 21     STA $210D
C0/4C2E: A5 18        LDA $18
C0/4C30: 8D 0D 21     STA $210D
C0/4C33: A5 19        LDA $19
C0/4C35: 8D 0E 21     STA $210E
C0/4C38: A5 1A        LDA $1A
C0/4C3A: 8D 0E 21     STA $210E
C0/4C3D: A5 1B        LDA $1B
C0/4C3F: 8D 0F 21     STA $210F
C0/4C42: A5 1C        LDA $1C
C0/4C44: 8D 0F 21     STA $210F
C0/4C47: A5 1D        LDA $1D
C0/4C49: 8D 10 21     STA $2110
C0/4C4C: A5 1E        LDA $1E
C0/4C4E: 8D 10 21     STA $2110
C0/4C51: A5 1F        LDA $1F
C0/4C53: 8D 11 21     STA $2111
C0/4C56: A5 20        LDA $20
C0/4C58: 8D 11 21     STA $2111
C0/4C5B: A5 21        LDA $21
C0/4C5D: 8D 12 21     STA $2112
C0/4C60: A5 22        LDA $22
C0/4C62: 8D 12 21     STA $2112
C0/4C65: C2 20        REP #$20
C0/4C67: A5 17        LDA $17
C0/4C69: 18           CLC 
C0/4C6A: 69 78 00     ADC #$0078
C0/4C6D: 85 17        STA $17
C0/4C6F: A5 19        LDA $19
C0/4C71: 18           CLC 
C0/4C72: 69 78 00     ADC #$0078
C0/4C75: 85 19        STA $19
C0/4C77: A5 06        LDA $06
C0/4C79: E2 20        SEP #$20
C0/4C7B: A5 17        LDA $17
C0/4C7D: 8D 1F 21     STA $211F
C0/4C80: A5 18        LDA $18
C0/4C82: 8D 1F 21     STA $211F
C0/4C85: A5 19        LDA $19
C0/4C87: 8D 20 21     STA $2120
C0/4C8A: A5 1A        LDA $1A
C0/4C8C: 8D 20 21     STA $2120
C0/4C8F: 60           RTS 

C0/4C90: 22 08 A0 C2  JSL $C2A008     ; update joypad input
C0/4C94: 60           RTS 

; [ clear sprite data ]

C0/4C95: A2 00 02     LDX #$0200
C0/4C98: A9 F0        LDA #$F0
C0/4C9A: 9D FD 01     STA $01FD,X
C0/4C9D: CA           DEX 
C0/4C9E: CA           DEX 
C0/4C9F: CA           DEX 
C0/4CA0: CA           DEX 
C0/4CA1: D0 F7        BNE $4C9A
C0/4CA3: A2 20 00     LDX #$0020
C0/4CA6: 9E FF 03     STZ $03FF,X
C0/4CA9: CA           DEX 
C0/4CAA: D0 FA        BNE $4CA6
C0/4CAC: 60           RTS 

; [ hide all sprites ]

C0/4CAD: A2 00 01     LDX #$0100
C0/4CB0: A9 F0        LDA #$F0
C0/4CB2: 9D FD 01     STA $01FD,X
C0/4CB5: CA           DEX 
C0/4CB6: CA           DEX 
C0/4CB7: CA           DEX 
C0/4CB8: CA           DEX 
C0/4CB9: D0 F7        BNE $4CB2
C0/4CBB: 60           RTS 

; [ copy data to vram ]

; ++$23: source address
;  +$2C: size
;  +$2E: destination address (vram)

C0/4CBC: A9 80        LDA #$80
C0/4CBE: 8D 15 21     STA $2115
C0/4CC1: 9C 0B 42     STZ $420B
C0/4CC4: A9 01        LDA #$01
C0/4CC6: 8D 00 43     STA $4300
C0/4CC9: A9 18        LDA #$18
C0/4CCB: 8D 01 43     STA $4301
C0/4CCE: A5 25        LDA $25
C0/4CD0: 8D 04 43     STA $4304
C0/4CD3: A6 2E        LDX $2E
C0/4CD5: 8E 16 21     STX $2116
C0/4CD8: A6 23        LDX $23
C0/4CDA: 8E 02 43     STX $4302
C0/4CDD: A6 2C        LDX $2C
C0/4CDF: 8E 05 43     STX $4305
C0/4CE2: A9 01        LDA #$01
C0/4CE4: 8D 0B 42     STA $420B
C0/4CE7: 60           RTS 

; [ disable interrupts ]

C0/4CE8: 9C 0B 42     STZ $420B
C0/4CEB: 9C 0C 42     STZ $420C
C0/4CEE: A9 80        LDA #$80
C0/4CF0: 8D 00 21     STA $2100
C0/4CF3: A9 00        LDA #$00
C0/4CF5: 8D 00 42     STA $4200
C0/4CF8: 78           SEI 
C0/4CF9: 60           RTS 

; [ enable interrupts ]

C0/4CFA: A9 81        LDA #$81
C0/4CFC: 8D 00 42     STA $4200
C0/4CFF: A9 00        LDA #$00
C0/4D01: 8D 00 21     STA $2100
C0/4D04: 58           CLI 
C0/4D05: 60           RTS 

; [ clear vram ]

C0/4D06: 20 E8 4C     JSR $4CE8       ; disable interrupts
C0/4D09: 9C 6D 0B     STZ $0B6D
C0/4D0C: 20 13 4D     JSR $4D13       ; fill vram
C0/4D0F: 20 FA 4C     JSR $4CFA       ; enable interrupts
C0/4D12: 60           RTS 

; [ fill vram ]

; +$2C: size
; +$2E: start address
;  $6D: fill value

C0/4D13: A9 80        LDA #$80
C0/4D15: 8D 15 21     STA $2115
C0/4D18: 9C 0B 42     STZ $420B
C0/4D1B: A9 09        LDA #$09
C0/4D1D: 8D 00 43     STA $4300
C0/4D20: A9 18        LDA #$18
C0/4D22: 8D 01 43     STA $4301
C0/4D25: A6 2E        LDX $2E
C0/4D27: 8E 16 21     STX $2116
C0/4D2A: A2 6D 0B     LDX #$0B6D
C0/4D2D: 8E 02 43     STX $4302
C0/4D30: 9C 04 43     STZ $4304
C0/4D33: A6 2C        LDX $2C
C0/4D35: 8E 05 43     STX $4305
C0/4D38: A9 01        LDA #$01
C0/4D3A: 8D 0B 42     STA $420B
C0/4D3D: 60           RTS 

; [ copy sprite data to ppu ]

C0/4D3E: A5 5C        LDA $5C
C0/4D40: D0 24        BNE $4D66
C0/4D42: 9C 02 21     STZ $2102
C0/4D45: 9C 0B 42     STZ $420B
C0/4D48: 9C 00 43     STZ $4300
C0/4D4B: A9 04        LDA #$04
C0/4D4D: 8D 01 43     STA $4301
C0/4D50: A2 00 02     LDX #$0200
C0/4D53: 8E 02 43     STX $4302
C0/4D56: A9 00        LDA #$00
C0/4D58: 8D 04 43     STA $4304
C0/4D5B: A2 20 02     LDX #$0220
C0/4D5E: 8E 05 43     STX $4305
C0/4D61: A9 01        LDA #$01
C0/4D63: 8D 0B 42     STA $420B
C0/4D66: 60           RTS 

; [ copy color palettes to ppu ]

C0/4D67: 9C 0B 42     STZ $420B
C0/4D6A: 9C 21 21     STZ $2121
C0/4D6D: A9 02        LDA #$02
C0/4D6F: 8D 00 43     STA $4300
C0/4D72: A9 22        LDA #$22        ; -> $2122 (color palette address)
C0/4D74: 8D 01 43     STA $4301
C0/4D77: A9 00        LDA #$00
C0/4D79: 8D 04 43     STA $4304
C0/4D7C: A2 00 0C     LDX #$0C00      ; source = 00/0C00
C0/4D7F: 8E 02 43     STX $4302
C0/4D82: A2 00 02     LDX #$0200
C0/4D85: 8E 05 43     STX $4305
C0/4D88: A9 01        LDA #$01
C0/4D8A: 8D 0B 42     STA $420B
C0/4D8D: 60           RTS 

C0/4D8E: A5 02        LDA $02
C0/4D90: 29 80        AND #$80
C0/4D92: D0 03        BNE $4D97
C0/4D94: 9C B8 10     STZ $10B8
C0/4D97: A5 02        LDA $02
C0/4D99: 29 40        AND #$40
C0/4D9B: D0 03        BNE $4DA0
C0/4D9D: 9C B4 10     STZ $10B4
C0/4DA0: A5 02        LDA $02
C0/4DA2: 29 20        AND #$20
C0/4DA4: D0 03        BNE $4DA9
C0/4DA6: 9C B6 10     STZ $10B6
C0/4DA9: A5 02        LDA $02
C0/4DAB: 29 10        AND #$10
C0/4DAD: D0 03        BNE $4DB2
C0/4DAF: 9C B7 10     STZ $10B7
C0/4DB2: A5 03        LDA $03
C0/4DB4: 29 80        AND #$80
C0/4DB6: D0 03        BNE $4DBB
C0/4DB8: 9C B9 10     STZ $10B9
C0/4DBB: A5 03        LDA $03
C0/4DBD: 29 40        AND #$40
C0/4DBF: D0 03        BNE $4DC4
C0/4DC1: 9C B5 10     STZ $10B5
C0/4DC4: A5 03        LDA $03
C0/4DC6: 29 20        AND #$20
C0/4DC8: D0 03        BNE $4DCD
C0/4DCA: 9C BA 10     STZ $10BA
C0/4DCD: A5 03        LDA $03
C0/4DCF: 29 10        AND #$10
C0/4DD1: D0 03        BNE $4DD6
C0/4DD3: 9C BB 10     STZ $10BB
C0/4DD6: 60           RTS 
C0/4DD7: DA           PHX 
C0/4DD8: 5A           PHY 
C0/4DD9: A6 06        LDX $06
C0/4DDB: A0 00 00     LDY #$0000
C0/4DDE: 64 3A        STZ $3A
C0/4DE0: C2 20        REP #$20
C0/4DE2: A5 37        LDA $37
C0/4DE4: 38           SEC 
C0/4DE5: FF 21 4E C0  SBC $C04E21,X
C0/4DE9: 85 37        STA $37
C0/4DEB: A5 39        LDA $39
C0/4DED: FF 31 4E C0  SBC $C04E31,X
C0/4DF1: 85 39        STA $39
C0/4DF3: 90 04        BCC $4DF9
C0/4DF5: C8           INY 
C0/4DF6: 4C E0 4D     JMP $4DE0
C0/4DF9: A5 37        LDA $37
C0/4DFB: 18           CLC 
C0/4DFC: 7F 21 4E C0  ADC $C04E21,X
C0/4E00: 85 37        STA $37
C0/4E02: A5 39        LDA $39
C0/4E04: 7F 31 4E C0  ADC $C04E31,X
C0/4E08: 85 39        STA $39
C0/4E0A: A5 06        LDA $06
C0/4E0C: E2 20        SEP #$20
C0/4E0E: DA           PHX 
C0/4E0F: 8A           TXA 
C0/4E10: 4A           LSR 
C0/4E11: AA           TAX 
C0/4E12: 98           TYA 
C0/4E13: 9D AC 10     STA $10AC,X
C0/4E16: FA           PLX 
C0/4E17: E8           INX 
C0/4E18: E8           INX 
C0/4E19: E0 10 00     CPX #$0010
C0/4E1C: D0 BD        BNE $4DDB
C0/4E1E: 7A           PLY 
C0/4E1F: FA           PLX 
C0/4E20: 60           RTS 

C0/4E21: 80 96        BRA $4DB9
C0/4E23: 40           RTI 
C0/4E24: 42 A0        WDM $A0
C0/4E26: 86 10        STX $10
C0/4E28: 27 E8        AND [$E8]
C0/4E2A: 03 64        ORA $64,S
C0/4E2C: 00 0A        BRK $0A
C0/4E2E: 00 01        BRK $01
C0/4E30: 00 98        BRK $98
C0/4E32: 00 0F        BRK $0F
C0/4E34: 00 01        BRK $01
C0/4E36: 00 00        BRK $00
C0/4E38: 00 00        BRK $00
C0/4E3A: 00 00        BRK $00
C0/4E3C: 00 00        BRK $00
C0/4E3E: 00 00        BRK $00
C0/4E40: 00

; [ wait for vblank ]

C0/4E41: 64 51        STZ $51
C0/4E43: A5 51        LDA $51
C0/4E45: F0 FC        BEQ $4E43
C0/4E47: 64 51        STZ $51
C0/4E49: 60           RTS 

; [ init interrupt jump code ]

C0/4E4A: A9 5C        LDA #$5C
C0/4E4C: 8D 00 1F     STA $1F00
C0/4E4F: 8D 04 1F     STA $1F04
C0/4E52: A2 D1 02     LDX #$02D1
C0/4E55: 8E 01 1F     STX $1F01
C0/4E58: A9 C0        LDA #$C0
C0/4E5A: 8D 03 1F     STA $1F03
C0/4E5D: A2 46 04     LDX #$0446
C0/4E60: 8E 05 1F     STX $1F05
C0/4E63: A9 C0        LDA #$C0
C0/4E65: 8D 07 1F     STA $1F07
C0/4E68: 60           RTS 

; [ init hardware registers ]

C0/4E69: A9 80        LDA #$80
C0/4E6B: 8D 00 21     STA $2100
C0/4E6E: A9 00        LDA #$00
C0/4E70: 8D 00 42     STA $4200
C0/4E73: 9C 0B 42     STZ $420B
C0/4E76: 9C 0C 42     STZ $420C
C0/4E79: A9 03        LDA #$03
C0/4E7B: 8D 01 21     STA $2101
C0/4E7E: 9C 02 21     STZ $2102
C0/4E81: 9C 03 21     STZ $2103
C0/4E84: A9 09        LDA #$09
C0/4E86: 8D 05 21     STA $2105
C0/4E89: 9C 06 21     STZ $2106
C0/4E8C: A9 00        LDA #$00
C0/4E8E: 8D 0B 21     STA $210B
C0/4E91: A9 04        LDA #$04
C0/4E93: 8D 0C 21     STA $210C
C0/4E96: A9 80        LDA #$80
C0/4E98: 8D 15 21     STA $2115
C0/4E9B: 9C 1A 21     STZ $211A
C0/4E9E: 9C 1B 21     STZ $211B
C0/4EA1: A9 08        LDA #$08
C0/4EA3: 8D 1B 21     STA $211B
C0/4EA6: 9C 1C 21     STZ $211C
C0/4EA9: 9C 1C 21     STZ $211C
C0/4EAC: 9C 1D 21     STZ $211D
C0/4EAF: 9C 1D 21     STZ $211D
C0/4EB2: 9C 1E 21     STZ $211E
C0/4EB5: A9 08        LDA #$08
C0/4EB7: 8D 1E 21     STA $211E
C0/4EBA: A9 80        LDA #$80
C0/4EBC: 8D 1F 21     STA $211F
C0/4EBF: 8D 1F 21     STA $211F
C0/4EC2: 8D 20 21     STA $2120
C0/4EC5: 8D 20 21     STA $2120
C0/4EC8: 8D 21 21     STA $2121
C0/4ECB: A9 BF        LDA #$BF
C0/4ECD: 8D 23 21     STA $2123
C0/4ED0: A9 0B        LDA #$0B
C0/4ED2: 8D 24 21     STA $2124
C0/4ED5: A9 BB        LDA #$BB
C0/4ED7: 8D 25 21     STA $2125
C0/4EDA: A9 08        LDA #$08
C0/4EDC: 8D 26 21     STA $2126
C0/4EDF: A9 F7        LDA #$F7
C0/4EE1: 8D 27 21     STA $2127
C0/4EE4: A9 FF        LDA #$FF
C0/4EE6: 8D 28 21     STA $2128
C0/4EE9: A9 00        LDA #$00
C0/4EEB: 8D 29 21     STA $2129
C0/4EEE: A9 01        LDA #$01
C0/4EF0: 8D 2A 21     STA $212A
C0/4EF3: A9 00        LDA #$00
C0/4EF5: 8D 2B 21     STA $212B
C0/4EF8: A9 13        LDA #$13
C0/4EFA: 8D 2C 21     STA $212C
C0/4EFD: A9 04        LDA #$04
C0/4EFF: 8D 2D 21     STA $212D
C0/4F02: A9 17        LDA #$17
C0/4F04: 8D 2E 21     STA $212E
C0/4F07: 9C 2F 21     STZ $212F
C0/4F0A: A9 22        LDA #$22
C0/4F0C: 8D 30 21     STA $2130
C0/4F0F: A9 E0        LDA #$E0
C0/4F11: 8D 32 21     STA $2132
C0/4F14: A9 00        LDA #$00
C0/4F16: 8D 33 21     STA $2133
C0/4F19: A9 FF        LDA #$FF
C0/4F1B: 8D 01 42     STA $4201
C0/4F1E: 9C 07 42     STZ $4207
C0/4F21: 9C 08 42     STZ $4208
C0/4F24: 9C 09 42     STZ $4209
C0/4F27: 9C 0A 42     STZ $420A
C0/4F2A: 60           RTS 

; [ generate random number ]

C0/4F2B: DA           PHX 
C0/4F2C: EE A7 16     INC $16A7
C0/4F2F: D0 09        BNE $4F3A
C0/4F31: AD F9 0A     LDA $0AF9       ; random number seed
C0/4F34: 18           CLC 
C0/4F35: 69 07        ADC #$07
C0/4F37: 8D F9 0A     STA $0AF9
C0/4F3A: AD A7 16     LDA $16A7
C0/4F3D: AA           TAX 
C0/4F3E: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C0/4F42: 38           SEC 
C0/4F43: ED F9 0A     SBC $0AF9
C0/4F46: FA           PLX 
C0/4F47: 60           RTS 

; [ update shattering crystal ]

C0/4F48: A9 00        LDA #$00
C0/4F4A: 85 25        STA $25
C0/4F4C: A5 3F        LDA $3F
C0/4F4E: 2D 55 1A     AND $1A55
C0/4F51: C2 20        REP #$20
C0/4F53: EB           XBA 
C0/4F54: 4A           LSR 
C0/4F55: 18           CLC 
C0/4F56: 6D B1 16     ADC $16B1
C0/4F59: AA           TAX 
C0/4F5A: A5 06        LDA $06
C0/4F5C: E2 20        SEP #$20
C0/4F5E: 8A           TXA 
C0/4F5F: 0A           ASL 
C0/4F60: 29 7F        AND #$7F
C0/4F62: A8           TAY 
C0/4F63: BF 5A 50 C0  LDA $C0505A,X
C0/4F67: 30 25        BMI $4F8E
C0/4F69: 8D 02 42     STA $4202
C0/4F6C: AD 53 1A     LDA $1A53
C0/4F6F: 8D 03 42     STA $4203
C0/4F72: EA           NOP 
C0/4F73: EA           NOP 
C0/4F74: EA           NOP 
C0/4F75: 64 38        STZ $38
C0/4F77: AD 17 42     LDA $4217
C0/4F7A: 85 37        STA $37
C0/4F7C: AD 54 1A     LDA $1A54
C0/4F7F: 8D 03 42     STA $4203
C0/4F82: EA           NOP 
C0/4F83: EA           NOP 
C0/4F84: C2 20        REP #$20
C0/4F86: A5 37        LDA $37
C0/4F88: 18           CLC 
C0/4F89: 6D 16 42     ADC $4216
C0/4F8C: 80 2A        BRA $4FB8
C0/4F8E: 49 FF 1A     EOR #$1AFF
C0/4F91: 8D 02 42     STA $4202
C0/4F94: AD 53 1A     LDA $1A53
C0/4F97: 8D 03 42     STA $4203
C0/4F9A: EA           NOP 
C0/4F9B: EA           NOP 
C0/4F9C: EA           NOP 
C0/4F9D: 64 38        STZ $38
C0/4F9F: AD 17 42     LDA $4217
C0/4FA2: 85 37        STA $37
C0/4FA4: AD 54 1A     LDA $1A54
C0/4FA7: 8D 03 42     STA $4203
C0/4FAA: EA           NOP 
C0/4FAB: EA           NOP 
C0/4FAC: C2 20        REP #$20
C0/4FAE: A5 37        LDA $37
C0/4FB0: 18           CLC 
C0/4FB1: 6D 16 42     ADC $4216
C0/4FB4: 49 FF FF     EOR #$FFFF
C0/4FB7: 1A           INC 
C0/4FB8: 18           CLC 
C0/4FB9: 65 13        ADC $13
C0/4FBB: E2 20        SEP #$20
C0/4FBD: EB           XBA 
C0/4FBE: F0 03        BEQ $4FC3
C0/4FC0: 4C 3C 50     JMP $503C
C0/4FC3: EB           XBA 
C0/4FC4: 97 23        STA [$23],Y
C0/4FC6: C8           INY 
C0/4FC7: BF 5B 50 C0  LDA $C0505B,X
C0/4FCB: 30 25        BMI $4FF2
C0/4FCD: 8D 02 42     STA $4202
C0/4FD0: AD 53 1A     LDA $1A53
C0/4FD3: 8D 03 42     STA $4203
C0/4FD6: EA           NOP 
C0/4FD7: EA           NOP 
C0/4FD8: EA           NOP 
C0/4FD9: 64 38        STZ $38
C0/4FDB: AD 17 42     LDA $4217
C0/4FDE: 85 37        STA $37
C0/4FE0: AD 54 1A     LDA $1A54
C0/4FE3: 8D 03 42     STA $4203
C0/4FE6: EA           NOP 
C0/4FE7: EA           NOP 
C0/4FE8: C2 20        REP #$20
C0/4FEA: A5 37        LDA $37
C0/4FEC: 18           CLC 
C0/4FED: 6D 16 42     ADC $4216
C0/4FF0: 80 2A        BRA $501C
C0/4FF2: 49 FF 1A     EOR #$1AFF
C0/4FF5: 8D 02 42     STA $4202
C0/4FF8: AD 53 1A     LDA $1A53
C0/4FFB: 8D 03 42     STA $4203
C0/4FFE: EA           NOP 
C0/4FFF: EA           NOP 
C0/5000: EA           NOP 
C0/5001: 64 38        STZ $38
C0/5003: AD 17 42     LDA $4217
C0/5006: 85 37        STA $37
C0/5008: AD 54 1A     LDA $1A54
C0/500B: 8D 03 42     STA $4203
C0/500E: EA           NOP 
C0/500F: EA           NOP 
C0/5010: C2 20        REP #$20
C0/5012: A5 37        LDA $37
C0/5014: 18           CLC 
C0/5015: 6D 16 42     ADC $4216
C0/5018: 49 FF FF     EOR #$FFFF
C0/501B: 1A           INC 
C0/501C: 18           CLC 
C0/501D: 65 15        ADC $15
C0/501F: E2 20        SEP #$20
C0/5021: C9 E0        CMP #$E0
C0/5023: B0 18        BCS $503D
C0/5025: EB           XBA 
C0/5026: F0 03        BEQ $502B
C0/5028: 4C 3D 50     JMP $503D
C0/502B: EB           XBA 
C0/502C: 97 23        STA [$23],Y
C0/502E: C8           INY 
C0/502F: AD AF 16     LDA $16AF
C0/5032: 97 23        STA [$23],Y
C0/5034: C8           INY 
C0/5035: AD B0 16     LDA $16B0
C0/5038: 97 23        STA [$23],Y
C0/503A: 80 08        BRA $5044
C0/503C: C8           INY 
C0/503D: A9 00        LDA #$00
C0/503F: EB           XBA 
C0/5040: A9 F8        LDA #$F8
C0/5042: 97 23        STA [$23],Y
C0/5044: E8           INX 
C0/5045: E8           INX 
C0/5046: 8A           TXA 
C0/5047: 29 7F        AND #$7F
C0/5049: F0 0E        BEQ $5059
C0/504B: 29 3F        AND #$3F
C0/504D: F0 03        BEQ $5052
C0/504F: 4C 5E 4F     JMP $4F5E
C0/5052: A4 26        LDY $26
C0/5054: 84 23        STY $23
C0/5056: 4C 5E 4F     JMP $4F5E
C0/5059: 60           RTS 

C0/505A: 13 A0        ORA ($A0,S),Y
C0/505C: 10 A3        BPL $5001
C0/505E: 0B           PHD 
C0/505F: A6 04        LDX $04
C0/5061: A7 FC        LDA [$FC]
C0/5063: A7 F5        LDA [$F5]
C0/5065: A6 F0        LDX $F0
C0/5067: A3 ED        LDA $ED,S
C0/5069: A0 ED 9C     LDY #$9CED
C0/506C: F0 99        BEQ $5007
C0/506E: F5 96        SBC $96,X
C0/5070: FC 94 04     JSR ($0494,X)
C0/5073: 94 0B        STY $0B,X
C0/5075: 96 10        STX $10,Y
C0/5077: 99 13 9C     STA $9C13,Y
C0/507A: 26 A7        ROL $A7
C0/507C: 20 AE 15     JSR $15AE
C0/507F: B4 07        LDY $07,X
C0/5081: B6 F9        LDX $F9,Y
C0/5083: B6 EB        LDX $EB,Y
C0/5085: B4 E0        LDY $E0,X
C0/5087: AE DA A7     LDX $A7DA
C0/508A: DA           PHX 
C0/508B: A0 E0 99     LDY #$99E0
C0/508E: EB           XBA 
C0/508F: 94 F9        STY $F9,X
C0/5091: 91 07        STA ($07),Y
C0/5093: 91 15        STA ($15),Y
C0/5095: 94 20        STY $20,X
C0/5097: 99 26 A0     STA $A026,Y
C0/509A: 36 B2        ROL $B2,X
C0/509C: 2E BC 1F     ROL $1FBC
C0/509F: C4 0B        CPY $0B
C0/50A1: C8           INY 
C0/50A2: F5 C8        SBC $C8,X
C0/50A4: E1 C4        SBC ($C4,X)
C0/50A6: D2 BC        CMP ($BC)
C0/50A8: CA           DEX 
C0/50A9: B2 CA        LDA ($CA)
C0/50AB: A7 D2        LDA [$D2]
C0/50AD: 9D E1 96     STA $96E1,X
C0/50B0: F5 92        SBC $92,X
C0/50B2: 0B           PHD 
C0/50B3: 92 1F        STA ($1F)
C0/50B5: 96 2E        STX $2E,Y
C0/50B7: 9D 36 A7     STA $A736,X
C0/50BA: 45 C0        EOR $C0
C0/50BC: 3B           TSC 
C0/50BD: CD 27 D7     CMP $D727
C0/50C0: 0E DC F2     ASL $F2DC
C0/50C3: DC D9 D7     JML [$D7D9]
C0/50C6: C5 CD        CMP $CD
C0/50C8: BB           TYX 
C0/50C9: C0 BB B2     CPY #$B2BB
C0/50CC: C5 A6        CMP $A6
C0/50CE: D9 9C F2     CMP $F29C,Y
C0/50D1: 97 0E        STA [$0E],Y
C0/50D3: 97 27        STA [$27],Y
C0/50D5: 9C 3B A6     STZ $A63B
C0/50D8: 45 B2        EOR $B2
C0/50DA: 52 D1        EOR ($D1)
C0/50DC: 45 E0        EOR $E0
C0/50DE: 2E EB 10     ROL $10EB
C0/50E1: F1 F0        SBC ($F0),Y
C0/50E3: F1 D2        SBC ($D2),Y
C0/50E5: EB           XBA 
C0/50E6: BB           TYX 
C0/50E7: E0 AE D1     CPX #$D1AE
C0/50EA: AE C0 BB     LDX $BBC0
C0/50ED: B1 D2        LDA ($D2),Y
C0/50EF: A6 F0        LDX $F0
C0/50F1: A0 10 A0     LDY #$A010
C0/50F4: 2E A6 45     ROL $45A6
C0/50F7: B1 52        LDA ($52),Y
C0/50F9: C0 5B E3     CPY #$E35B
C0/50FC: 4D F3 33     EOR $33F3
C0/50FF: 00 12        BRK $12
C0/5101: 07 EE        ORA [$EE]
C0/5103: 07 CD        ORA [$CD]
C0/5105: 00 B3        BRK $B3
C0/5107: F3 A5        SBC ($A5,S),Y
C0/5109: E3 A5        SBC $A5,S
C0/510B: D1 B3        CMP ($B3),Y
C0/510D: C0 CD B3     CPY #$B3CD
C0/5110: EE AC 12     INC $12AC
C0/5113: AC 33 B3     LDY $B333
C0/5116: 4D C0 5B     EOR $5BC0
C0/5119: D1 60        CMP ($60),Y
C0/511B: F6 52        INC $52,X
C0/511D: 08           PHP 
C0/511E: 36 15        ROL $15,X
C0/5120: 13 1D        ORA ($1D,S),Y
C0/5122: ED 1D CA     SBC $CA1D
C0/5125: 15 AE        ORA $AE,X
C0/5127: 08           PHP 
C0/5128: A0 F6 A0     LDY #$A0F6
C0/512B: E3 AE        SBC $AE,S
C0/512D: D1 CA        CMP ($CA),Y
C0/512F: C4 ED        CPY $ED
C0/5131: BC 13 BC     LDY $BC13,X
C0/5134: 36 C4        ROL $C4,X
C0/5136: 52 D1        EOR ($D1)
C0/5138: 60           RTS 
C0/5139: E3 62        SBC $62,S
C0/513B: 0A           ASL 
C0/513C: 53 1C        EOR ($1C,S),Y
C0/513E: 38           SEC 
C0/513F: 2A           ROL 
C0/5140: 14 31        TRB $31
C0/5142: EC 31 C8     CPX $C831
C0/5145: 2A           ROL 
C0/5146: AD 1C 9E     LDA $9E1C
C0/5149: 0A           ASL 
C0/514A: 9E F6 AD     STZ $ADF6,X
C0/514D: E4 C8        CPX $C8
C0/514F: D6 EC        DEC $EC,X
C0/5151: CF 14 CF 38  CMP $38CF14
C0/5155: D6 53        DEC $53,X
C0/5157: E4 62        CPX $62
C0/5159: F6 13        INC $13,X
C0/515B: A1 0F        LDA ($0F,X)
C0/515D: A4 09        LDY $09
C0/515F: A7 02        LDA [$02]
C0/5161: A8           TAY 
C0/5162: FA           PLX 
C0/5163: A7 F4        LDA [$F4]
C0/5165: A5 EF        LDA $EF
C0/5167: A3 ED        LDA $ED,S
C0/5169: 9F ED 9B F1  STA $F19BED,X
C0/516D: 98           TYA 
C0/516E: F7 95        SBC [$95],Y
C0/5170: FE 94 06     INC $0694,X
C0/5173: 95 0C        STA $0C,X
C0/5175: 96 11        STX $11,Y
C0/5177: 99 13 9D     STA $9D13,Y
C0/517A: 25 A9        AND $A9
C0/517C: 1E B0 12     ASL $12B0,X
C0/517F: B4 04        LDY $04,X
C0/5181: B7 F5        LDA [$F5],Y
C0/5183: B6 E8        LDX $E8,Y
C0/5185: B2 DE        LDA ($DE)
C0/5187: AD DA A5     LDA $A5DA
C0/518A: DB           STP 
C0/518B: 9E E2 97     STZ $97E2,X
C0/518E: EE 93 FC     INC $FC93
C0/5191: 91 0B        STA ($0B),Y
C0/5193: 91 18        STA ($18),Y
C0/5195: 95 22        STA $22,X
C0/5197: 9B           TXY 
C0/5198: 26 A2        ROL $A2
C0/519A: 35 B5        AND $B5,X
C0/519C: 2B           PLD 
C0/519D: BE 1A C5     LDX $C51A,Y
C0/51A0: 05 C8        ORA $C8
C0/51A2: F0 C7        BEQ $516B
C0/51A4: DD C2 CF     CMP $CFC2,X
C0/51A7: BA           TSX 
C0/51A8: C9 B0        CMP #$B0
C0/51AA: CB           WAI 
C0/51AB: A5 D5        LDA $D5
C0/51AD: 9B           TXY 
C0/51AE: E6 94        INC $94
C0/51B0: FB           XCE 
C0/51B1: 91 10        STA ($10),Y
C0/51B3: 92 23        STA ($23)
C0/51B5: 97 31        STA [$31],Y
C0/51B7: A0 37 AA     LDY #$AA37
C0/51BA: 44 C4 37     MVP $C4,$37
C0/51BD: D0 21        BNE $51E0
C0/51BF: D8           CLD 
C0/51C0: 07 DC        ORA [$DC]
C0/51C2: EB           XBA 
C0/51C3: DB           STP 
C0/51C4: D3 D5        CMP ($D5,S),Y
C0/51C6: C2 CA        REP #$CA
C0/51C8: BA           TSX 
C0/51C9: BD BC AF     LDA $AFBC,X
C0/51CC: C9 A3        CMP #$A3
C0/51CE: DF 9A F9 96  CMP $96F99A,X
C0/51D2: 15 97        ORA $97,X
C0/51D4: 2D 9E 3E     AND $3E9E
C0/51D7: A9 46        LDA #$46
C0/51D9: B6 50        LDX $50,Y
C0/51DB: D5 40        CMP $40,X
C0/51DD: E3 27        SBC $27,S
C0/51DF: ED 08 F2     SBC $F208
C0/51E2: E8           INX 
C0/51E3: F0 CB        BEQ $51B0
C0/51E5: E9 B7        SBC #$B7
C0/51E7: DC AD CD     JML [$CDAD]
C0/51EA: B0 BC        BCS $51A8
C0/51EC: C0 AE D9     CPY #$D9AE
C0/51EF: A4 F8        LDY $F8
C0/51F1: 9F 18 A1 35  STA $35A118,X
C0/51F5: A8           TAY 
C0/51F6: 49 B5        EOR #$B5
C0/51F8: 53 C4        EOR ($C4,S),Y
C0/51FA: 58           CLI 
C0/51FB: E7 47        SBC [$47]
C0/51FD: F7 2C        SBC [$2C],Y
C0/51FF: 02 09        COP $09
C0/5201: 08           PHP 
C0/5202: E5 06        SBC $06
C0/5204: C5 FD        CMP $FD
C0/5206: AF F0 A4 DE  LDA $DEA4F0
C0/520A: A8           TAY 
C0/520B: CC B9 BC     CPY $BCB9
C0/520E: D4 B1        PEI ($B1)
C0/5210: F7 AC        SBC [$AC],Y
C0/5212: 1B           TCS 
C0/5213: AE 3B B6     LDX $B63B
C0/5216: 51 C4        EOR ($C4),Y
C0/5218: 5C D5 5E FB  JML $FB5ED5
C0/521C: 4C 0C 2E     JMP $2E0C
C0/521F: 18           CLC 
C0/5220: 0A           ASL 
C0/5221: 1D E4 1B     ORA $1BE4,X
C0/5224: C2 12        REP #$12
C0/5226: AA           TAX 
C0/5227: 04 9E        TSB $9E
C0/5229: F1 A2        SBC ($A2),Y
C0/522B: DE B4 CD     DEC $CDB4,X
C0/522E: D2 C1        CMP ($C1)
C0/5230: F6 BC        INC $BC,X
C0/5232: 1C BE 3E     TRB $3EBE
C0/5235: C7 56        CMP [$56]
C0/5237: D5 62        CMP $62,X
C0/5239: E8           INX 
C0/523A: 60           RTS 
C0/523B: 0F 4D 20 2F  ORA $2F204D
C0/523F: 2C 0A 32     BIT $320A
C0/5242: E3 30        SBC $30,S
C0/5244: C1 27        CMP ($27,X)
C0/5246: A8           TAY 
C0/5247: 18           CLC 
C0/5248: 9C 05 A0     STZ $A005
C0/524B: F1 B3        SBC ($B3),Y
C0/524D: E0 D1 D4     CPX #$D4D1
C0/5250: F6 CE        INC $CE,X
C0/5252: 1D D0 3F     ORA $3FD0,X
C0/5255: D9 58 E8     CMP $E858,Y
C0/5258: 64 FB        STZ $FB
C0/525A: 14 9E        TRB $9E
C0/525C: 12 A2        ORA ($A2)
C0/525E: 0E A5 07     ASL $07A5
C0/5261: A7 00        LDA [$00]
C0/5263: A8           TAY 
C0/5264: F9 A7 F2     SBC $F2A7,Y
C0/5267: A5 EE        LDA $EE
C0/5269: A2 EC 9E     LDX #$9EEC
C0/526C: EE 9A F2     INC $F29A
C0/526F: 97 F9        STA [$F9],Y
C0/5271: 95 00        STA $00,X
C0/5273: 94 07        STY $07,X
C0/5275: 95 0E        STA $0E,X
C0/5277: 97 12        STA [$12],Y
C0/5279: 9A           TXS 
C0/527A: 26 A4        ROL $A4
C0/527C: 23 AB        AND $AB,S
C0/527E: 1B           TCS 
C0/527F: B1 0F        LDA ($0F),Y
C0/5281: B5 00        LDA $00,X
C0/5283: B7 F1        LDA [$F1],Y
C0/5285: B5 E5        LDA $E5,X
C0/5287: B1 DD        LDA ($DD),Y
C0/5289: AB           PLB 
C0/528A: DA           PHX 
C0/528B: A4 DD        LDY $DD
C0/528D: 9C E5 96     STZ $96E5
C0/5290: F1 92        SBC ($92),Y
C0/5292: 00 90        BRK $90
C0/5294: 0F 92 1B 96  ORA $961B92
C0/5298: 23 9C        AND $9C,S
C0/529A: 38           SEC 
C0/529B: AD 33 B7     LDA $B733
C0/529E: 27 C0        AND [$C0]
C0/52A0: 15 C7        ORA $C7,X
C0/52A2: 00 C9        BRK $C9
C0/52A4: EB           XBA 
C0/52A5: C7 D9        CMP [$D9]
C0/52A7: C0 CD B7     CPY #$B7CD
C0/52AA: C8           INY 
C0/52AB: AD CD A2     LDA $A2CD
C0/52AE: D9 99 EB     CMP $EB99,Y
C0/52B1: 93 00        STA ($00,S),Y
C0/52B3: 91 15        STA ($15),Y
C0/52B5: 93 27        STA ($27,S),Y
C0/52B7: 99 33 A2     STA $A233,Y
C0/52BA: 47 B9        EOR [$B9]
C0/52BC: 41 C7        EOR ($C7,X)
C0/52BE: 32 D2        AND ($D2)
C0/52C0: 1B           TCS 
C0/52C1: DA           PHX 
C0/52C2: 00 DD        BRK $DD
C0/52C4: E5 DA        SBC $DA
C0/52C6: CE D2 BF     DEC $BFD2
C0/52C9: C7 B9        CMP [$B9]
C0/52CB: B9 BF AC     LDA $ACBF,Y
C0/52CE: CE A0 E5     DEC $E5A0
C0/52D1: 99 00 96     STA $9600,Y
C0/52D4: 1B           TCS 
C0/52D5: 99 32 A0     STA $A032,Y
C0/52D8: 41 AC        EOR ($AC,X)
C0/52DA: 53 C8        EOR ($C8,S),Y
C0/52DC: 4D D8 3B     EOR $3BD8
C0/52DF: E6 20        INC $20
C0/52E1: EF 00 F2 E0  SBC $E0F200
C0/52E5: EF C5 E6 B3  SBC $B3E6C5
C0/52E9: D8           CLD 
C0/52EA: AD C8 B3     LDA $B3C8
C0/52ED: B9 C5 AB     LDA $ABC5,Y
C0/52F0: E0 A2 00     CPX #$00A2
C0/52F3: 9F 20 A2 3B  STA $3BA220,X
C0/52F7: AB           PLB 
C0/52F8: 4D B9 5C     EOR $5CB9
C0/52FB: DA           PHX 
C0/52FC: 55 EB        EOR $EB,X
C0/52FE: 41 FA        EOR ($FA,X)
C0/5300: 23 04        AND $04,S
C0/5302: 00 08        BRK $08
C0/5304: DD 04 BF     CMP $BF04,X
C0/5307: FA           PLX 
C0/5308: AB           PLB 
C0/5309: EB           XBA 
C0/530A: A4 DA        LDY $DA
C0/530C: AB           PLB 
C0/530D: C8           INY 
C0/530E: BF B9 DD AF  LDA $AFDDB9,X
C0/5312: 00 AC        BRK $AC
C0/5314: 23 AF        AND $AF,S
C0/5316: 41 B9        EOR ($B9,X)
C0/5318: 55 C8        EOR $C8,X
C0/531A: 62 EC 5B     PER $AF09
C0/531D: FF 45 0F 26  SBC $260F45,X
C0/5321: 1A           INC 
C0/5322: 00 1E        BRK $1E
C0/5324: DA           PHX 
C0/5325: 1A           INC 
C0/5326: BB           TYX 
C0/5327: 0F A5 FF 9E  ORA $9EFFA5
C0/532B: EC A5 DA     CPX $DAA5
C0/532E: BB           TYX 
C0/532F: CA           DEX 
C0/5330: DA           PHX 
C0/5331: BF 00 BB 26  LDA $26BB00,X
C0/5335: BF 45 CA 5B  LDA $5BCA45,X
C0/5339: DA           PHX 
C0/533A: 64 00        STZ $00
C0/533C: 5C 13 47 23  JML $234713
C0/5340: 26 2E        ROL $2E
C0/5342: 00 32        BRK $32
C0/5344: DA           PHX 
C0/5345: 2E B9 23     ROL $23B9
C0/5348: A4 13        LDY $13
C0/534A: 9C 00 A4     STZ $A400
C0/534D: ED B9 DD     SBC $DDB9
C0/5350: DA           PHX 
C0/5351: D2 00        CMP ($00)
C0/5353: CE 26 D2     DEC $D226
C0/5356: 47 DD        EOR [$DD]
C0/5358: 5C ED 13 9F  JML $9F13ED
C0/535C: 11 A3        ORA ($A3),Y
C0/535E: 0C A5 06     TSB $06A5
C0/5361: A7 FE        LDA [$FE]
C0/5363: A8           TAY 
C0/5364: F7 A7        SBC [$A7],Y
C0/5366: F1 A4        SBC ($A4),Y
C0/5368: ED A1 ED     SBC $EDA1
C0/536B: 9D EF 99     STA $99EF,X
C0/536E: F4 96 FA     PEA $FA96
C0/5371: 95 02        STA $02,X
C0/5373: 94 09        STY $09,X
C0/5375: 95 0F        STA $0F,X
C0/5377: 98           TYA 
C0/5378: 13 9B        ORA ($9B,S),Y
C0/537A: 26 A5        ROL $A5
C0/537C: 22 AD 18 B2  JSL $B218AD
C0/5380: 0B           PHD 
C0/5381: B6 FC        LDX $FC,Y
C0/5383: B7 EE        LDA [$EE],Y
C0/5385: B4 E2        LDY $E2,X
C0/5387: B0 DB        BCS $5364
C0/5389: A9 DA        LDA #$DA
C0/538B: A2 DE 9B     LDX #$9BDE
C0/538E: E8           INX 
C0/538F: 95 F5        STA $F5,X
C0/5391: 91 04        STA ($04),Y
C0/5393: 91 12        STA ($12),Y
C0/5395: 93 1E        STA ($1E,S),Y
C0/5397: 97 25        STA [$25],Y
C0/5399: 9E 37 B0     STZ $B037,X
C0/539C: 31 BA        AND ($BA),Y
C0/539E: 23 C2        AND $C2,S
C0/53A0: 10 C7        BPL $5369
C0/53A2: FB           XCE 
C0/53A3: C8           INY 
C0/53A4: E6 C5        INC $C5
C0/53A6: D5 BE        CMP $BE,X
C0/53A8: CB           WAI 
C0/53A9: B5 C9        LDA $C9,X
C0/53AB: AA           TAX 
C0/53AC: CF A0 DD 97  CMP $97DDA0
C0/53B0: F0 92        BEQ $5344
C0/53B2: 05 91        ORA $91
C0/53B4: 1A           INC 
C0/53B5: 94 2B        STY $2B,X
C0/53B7: 9B           TXY 
C0/53B8: 35 A5        AND $A5,X
C0/53BA: 46 BD        LSR $BD
C0/53BC: 3E CA 2D     ROL $2DCA,X
C0/53BF: D5 15        CMP $15,X
C0/53C1: DB           STP 
C0/53C2: F9 DC DF     SBC $DFDC,Y
C0/53C5: D8           CLD 
C0/53C6: C9 D0        CMP #$D0
C0/53C8: BC C4 BA     LDY $BAC4,X
C0/53CB: B6 C2        LDX $C2,Y
C0/53CD: A9 D3        LDA #$D3
C0/53CF: 9E EB 97     STZ $97EB,X
C0/53D2: 07 96        ORA [$96]
C0/53D4: 21 9A        AND ($9A,X)
C0/53D6: 37 A3        AND [$A3],Y
C0/53D8: 44 AF 53     MVP $AF,$53
C0/53DB: CD 49 DC     CMP $DC49
C0/53DE: 35 E9        AND $E9,X
C0/53E0: 18           CLC 
C0/53E1: F0 F8        BEQ $53DB
C0/53E3: F2 D9        SBC ($D9)
C0/53E5: ED C0 E3     SBC $E3C0
C0/53E8: B0 D5        BCS $53BF
C0/53EA: AD C4 B7     LDA $B7C4
C0/53ED: B5 CB        LDA $CB,X
C0/53EF: A8           TAY 
C0/53F0: E8           INX 
C0/53F1: A1 08        LDA ($08,X)
C0/53F3: 9F 27 A4 40  STA $40A427,X
C0/53F7: AE 50 BC     LDX $BC50
C0/53FA: 5C DE 51 F0  JML $F051DE
C0/53FE: 3B           TSC 
C0/53FF: FD 1B 06     SBC $061B,X
C0/5402: F7 08        SBC [$08],Y
C0/5404: D4 02        PEI ($02)
C0/5406: B9 F7 A8     LDA $A8F7,Y
C0/5409: E7 A4        SBC [$A4]
C0/540B: D5 AF        CMP $AF,X
C0/540D: C4 C5        CPY $C5
C0/540F: B6 E5        LDX $E5,Y
C0/5411: AE 09 AC     LDX $AC09
C0/5414: 2C B1 47     BIT $47B1
C0/5417: BC 58 CC     LDY $CC58,X
C0/541A: 62 F1 56     PER $AB0E
C0/541D: 04 3E        TSB $3E
C0/541F: 12 1C        ORA ($1C)
C0/5421: 1B           TCS 
C0/5422: F6 1D        INC $1D,X
C0/5424: D2 18        CMP ($18)
C0/5426: B4 0C        LDY $0C,X
C0/5428: A2 FB 9E     LDX #$9EFB
C0/542B: E8           INX 
C0/542C: AA           TAX 
C0/542D: D5 C2        CMP $C2,X
C0/542F: C7 E4        CMP [$E4]
C0/5431: BE 0A BC     LDX $BC0A,Y
C0/5434: 2E C1 4C     ROL $4CC1
C0/5437: CD 5E DE     CMP $DE5E
C0/543A: 64 05        STZ $05
C0/543C: 58           CLI 
C0/543D: 18           CLC 
C0/543E: 3F 27 1D 30  AND $301D27,X
C0/5442: F6 32        INC $32,X
C0/5444: D1 2C        CMP ($2C),Y
C0/5446: B3 20        LDA ($20,S),Y
C0/5448: A0 0F 9C     LDY #$9C0F
C0/544B: FB           XCE 
C0/544C: A8           TAY 
C0/544D: E8           INX 
C0/544E: C1 D9        CMP ($D9,X)
C0/5450: E3 D0        SBC $D0,S
C0/5452: 0A           ASL 
C0/5453: CE 2F D4     DEC $D42F
C0/5456: 4D E0 60     EOR $60E0
C0/5459: F1

; [ load map ]

C0/545A: 20 81 60     JSR $6081       ; fade out
C0/545D: AE D6 0A     LDX $0AD6       ; map index
C0/5460: E0 05 00     CPX #$0005
C0/5463: B0 07        BCS $546C
C0/5465: 20 28 55     JSR $5528       ; load world map
C0/5468: 20 00 61     JSR $6100       ; fade in
C0/546B: 60           RTS 
C0/546C: 20 4C 57     JSR $574C       ; load normal map
C0/546F: 20 00 61     JSR $6100       ; fade in
C0/5472: 20 67 92     JSR $9267       ; show map title
C0/5475: 60           RTS 

; [ reload map ]

C0/5476: AE D6 0A     LDX $0AD6       ; map index
C0/5479: E0 05 00     CPX #$0005
C0/547C: B0 07        BCS $5485
C0/547E: 20 32 55     JSR $5532       ; reload world map
C0/5481: 20 00 61     JSR $6100       ; fade in
C0/5484: 60           RTS 
C0/5485: 20 7C 57     JSR $577C       ; reload map
C0/5488: 20 00 61     JSR $6100       ; fade in
C0/548B: 20 67 92     JSR $9267       ; show map title
C0/548E: 60           RTS 

; [ load parent map ]

C0/548F: AE F5 0A     LDX $0AF5
C0/5492: 8E D6 0A     STX $0AD6       ; map index
C0/5495: AD F7 0A     LDA $0AF7
C0/5498: 8D 88 10     STA $1088
C0/549B: AD F8 0A     LDA $0AF8
C0/549E: 8D 89 10     STA $1089
C0/54A1: E6 6E        INC $6E
C0/54A3: 20 5A 54     JSR $545A       ; load map
C0/54A6: 60           RTS 

C0/54A7: 64 6E        STZ $6E
C0/54A9: 64 BE        STZ $BE
C0/54AB: 64 5B        STZ $5B
C0/54AD: 64 B5        STZ $B5
C0/54AF: 64 A0        STZ $A0
C0/54B1: 64 A5        STZ $A5
C0/54B3: 64 9F        STZ $9F
C0/54B5: 64 A6        STZ $A6
C0/54B7: 64 A3        STZ $A3
C0/54B9: 64 56        STZ $56
C0/54BB: 64 5A        STZ $5A
C0/54BD: 64 5C        STZ $5C
C0/54BF: 9C 34 0A     STZ $0A34
C0/54C2: 9C 35 0A     STZ $0A35
C0/54C5: A9 01        LDA #$01
C0/54C7: 85 59        STA $59
C0/54C9: 85 C3        STA $C3         ; party z-level
C0/54CB: 85 5D        STA $5D
C0/54CD: A2 10 01     LDX #$0110      ; party sprite priority (normal)
C0/54D0: 86 C7        STX $C7
C0/54D2: AD 88 10     LDA $1088
C0/54D5: 8D D8 0A     STA $0AD8
C0/54D8: AD 89 10     LDA $1089
C0/54DB: 8D D9 0A     STA $0AD9
C0/54DE: A6 06        LDX $06
C0/54E0: 8E A8 16     STX $16A8
C0/54E3: A9 F1        LDA #$F1
C0/54E5: 20 96 C7     JSR $C796
C0/54E8: A9 FD        LDA #$FD
C0/54EA: 20 96 C7     JSR $C796
C0/54ED: 9C A4 16     STZ $16A4
C0/54F0: 9C A5 16     STZ $16A5
C0/54F3: 9C A6 16     STZ $16A6
C0/54F6: 9C 0B 42     STZ $420B
C0/54F9: 9C 0C 42     STZ $420C
C0/54FC: A9 80        LDA #$80
C0/54FE: 8D 00 21     STA $2100
C0/5501: A9 00        LDA #$00
C0/5503: 8D 00 42     STA $4200
C0/5506: 78           SEI 
C0/5507: 64 5E        STZ $5E
C0/5509: 20 69 4E     JSR $4E69       ; init hardware registers
C0/550C: 20 95 4C     JSR $4C95       ; clear sprite data
C0/550F: 20 3E 4D     JSR $4D3E       ; copy sprite data to ppu
C0/5512: A9 70        LDA #$70
C0/5514: 85 C5        STA $C5
C0/5516: 85 C6        STA $C6
C0/5518: 20 E5 5E     JSR $5EE5
C0/551B: 20 8D 5F     JSR $5F8D
C0/551E: 20 0D 99     JSR $990D       ; init palette animation
C0/5521: 20 F1 41     JSR $41F1
C0/5524: 20 BC 62     JSR $62BC
C0/5527: 60           RTS 

; [ load world map ]

C0/5528: AD DC 0A     LDA $0ADC
C0/552B: F0 05        BEQ $5532
C0/552D: A9 03        LDA #$03
C0/552F: 8D DB 0A     STA $0ADB
C0/5532: 64 53        STZ $53
C0/5534: 9C 9A 16     STZ $169A
C0/5537: 20 A7 54     JSR $54A7
C0/553A: A9 00        LDA #$00
C0/553C: 8D 07 21     STA $2107
C0/553F: A9 10        LDA #$10
C0/5541: 85 49        STA $49
C0/5543: 85 4A        STA $4A
C0/5545: AE D6 0A     LDX $0AD6       ; map index
C0/5548: E0 03 00     CPX #$0003
C0/554B: 90 04        BCC $5551
C0/554D: A9 C1        LDA #$C1
C0/554F: 80 02        BRA $5553
C0/5551: A9 41        LDA #$41
C0/5553: 85 48        STA $48
C0/5555: A5 44        LDA $44
C0/5557: D0 04        BNE $555D
C0/5559: A5 48        LDA $48
C0/555B: 85 47        STA $47
C0/555D: 20 56 4B     JSR $4B56
C0/5560: 20 1E 1D     JSR $1D1E       ; copy party sprite graphics to vram
C0/5563: 20 14 1E     JSR $1E14
C0/5566: A2 00 61     LDX #$6100
C0/5569: 86 2E        STX $2E
C0/556B: A2 00 02     LDX #$0200
C0/556E: 86 2C        STX $2C
C0/5570: A2 00 6C     LDX #$6C00
C0/5573: 86 23        STX $23
C0/5575: A9 DA        LDA #$DA
C0/5577: 85 25        STA $25
C0/5579: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/557C: A2 00 62     LDX #$6200
C0/557F: 86 2E        STX $2E
C0/5581: A2 00 04     LDX #$0400
C0/5584: 86 2C        STX $2C
C0/5586: A2 00 C0     LDX #$C000
C0/5589: 86 23        STX $23
C0/558B: A9 DA        LDA #$DA        ; DA/C000 (flying chocobo graphics)
C0/558D: 85 25        STA $25
C0/558F: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/5592: A2 40 64     LDX #$6440
C0/5595: 86 33        STX $33
C0/5597: A2 0C 00     LDX #$000C
C0/559A: 86 35        STX $35
C0/559C: A2 C0 3A     LDX #$3AC0
C0/559F: 86 30        STX $30
C0/55A1: 20 D5 4A     JSR $4AD5       ; copy 3bpp graphics to vram
C0/55A4: A2 40 65     LDX #$6540
C0/55A7: 86 33        STX $33
C0/55A9: A2 F0 00     LDX #$00F0
C0/55AC: 86 35        STX $35
C0/55AE: A2 80 3B     LDX #$3B80
C0/55B1: 86 30        STX $30
C0/55B3: 20 D5 4A     JSR $4AD5       ; copy 3bpp graphics to vram
C0/55B6: A2 00 64     LDX #$6400
C0/55B9: 86 2E        STX $2E
C0/55BB: A2 80 00     LDX #$0080
C0/55BE: 86 2C        STX $2C
C0/55C0: A2 00 1F     LDX #$1F00
C0/55C3: 86 23        STX $23
C0/55C5: A9 DA        LDA #$DA        ; DA/1F00 (gradient graphics 1)
C0/55C7: 85 25        STA $25
C0/55C9: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/55CC: A2 00 65     LDX #$6500
C0/55CF: 86 2E        STX $2E
C0/55D1: A2 80 00     LDX #$0080
C0/55D4: 86 2C        STX $2C
C0/55D6: A2 80 1F     LDX #$1F80
C0/55D9: 86 23        STX $23
C0/55DB: A9 DA        LDA #$DA        ; DA/1F80 (gradient graphics 2)
C0/55DD: 85 25        STA $25
C0/55DF: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/55E2: 20 F8 56     JSR $56F8
C0/55E5: A2 80 00     LDX #$0080
C0/55E8: BF FF FC DF  LDA $DFFCFF,X
C0/55EC: 9D FF 0C     STA $0CFF,X
C0/55EF: CA           DEX 
C0/55F0: D0 F6        BNE $55E8
C0/55F2: A2 40 00     LDX #$0040
C0/55F5: BF FF FB DF  LDA $DFFBFF,X
C0/55F9: 9D FF 0C     STA $0CFF,X
C0/55FC: CA           DEX 
C0/55FD: D0 F6        BNE $55F5
C0/55FF: AE D6 0A     LDX $0AD6       ; map index
C0/5602: E0 03 00     CPX #$0003
C0/5605: 90 05        BCC $560C
C0/5607: A2 20 00     LDX #$0020
C0/560A: 80 02        BRA $560E
C0/560C: A6 06        LDX $06
C0/560E: A4 06        LDY $06
C0/5610: BF 40 D3 C0  LDA $C0D340,X
C0/5614: 99 80 0D     STA $0D80,Y
C0/5617: E8           INX 
C0/5618: C8           INY 
C0/5619: C0 20 00     CPY #$0020
C0/561C: D0 F2        BNE $5610
C0/561E: 20 67 4D     JSR $4D67       ; copy color palettes to ppu
C0/5621: 20 95 4C     JSR $4C95       ; clear sprite data
C0/5624: 20 3E 4D     JSR $4D3E       ; copy sprite data to ppu
C0/5627: AD D6 0A     LDA $0AD6       ; map index
C0/562A: AA           TAX 
C0/562B: BF 39 57 C0  LDA $C05739,X
C0/562F: C2 20        REP #$20
C0/5631: EB           XBA 
C0/5632: 4A           LSR 
C0/5633: 4A           LSR 
C0/5634: 85 0D        STA $0D
C0/5636: A5 06        LDA $06
C0/5638: E2 20        SEP #$20
C0/563A: AD D6 0A     LDA $0AD6       ; map index
C0/563D: AA           TAX 
C0/563E: BF 39 57 C0  LDA $C05739,X
C0/5642: C2 20        REP #$20
C0/5644: EB           XBA 
C0/5645: 0A           ASL 
C0/5646: 18           CLC 
C0/5647: 65 0D        ADC $0D
C0/5649: AA           TAX 
C0/564A: A5 06        LDA $06
C0/564C: E2 20        SEP #$20
C0/564E: A4 06        LDY $06
C0/5650: BF 00 EA CF  LDA $CFEA00,X   ; world map tile properties
C0/5654: 99 86 11     STA $1186,Y
C0/5657: E8           INX 
C0/5658: C8           INY 
C0/5659: C0 40 02     CPY #$0240
C0/565C: D0 F2        BNE $5650
C0/565E: A9 01        LDA #$01
C0/5660: 85 BA        STA $BA
C0/5662: AD D6 0A     LDA $0AD6       ; map index
C0/5665: AA           TAX 
C0/5666: BF 39 57 C0  LDA $C05739,X
C0/566A: 0A           ASL 
C0/566B: 18           CLC 
C0/566C: 7F 39 57 C0  ADC $C05739,X
C0/5670: C2 20        REP #$20
C0/5672: EB           XBA 
C0/5673: 18           CLC 
C0/5674: 69 C0 F0     ADC #$F0C0
C0/5677: A8           TAY 
C0/5678: A5 06        LDA $06
C0/567A: E2 20        SEP #$20
C0/567C: A9 CF        LDA #$CF
C0/567E: 20 2D 6B     JSR $6B2D       ; load world tileset
C0/5681: 20 4A 6C     JSR $6C4A
C0/5684: 20 83 45     JSR $4583
C0/5687: 20 98 47     JSR $4798
C0/568A: 20 92 8C     JSR $8C92
C0/568D: 20 2E 8C     JSR $8C2E       ; init hdma #1 (window 2 position)
C0/5690: 64 6F        STZ $6F
C0/5692: AE D6 0A     LDX $0AD6       ; map index
C0/5695: E0 03 00     CPX #$0003
C0/5698: B0 17        BCS $56B1
C0/569A: AD DC 0A     LDA $0ADC
C0/569D: F0 16        BEQ $56B5
C0/569F: C9 06        CMP #$06
C0/56A1: D0 12        BNE $56B5
C0/56A3: AD F1 0A     LDA $0AF1
C0/56A6: 29 03        AND #$03
C0/56A8: D0 0B        BNE $56B5
C0/56AA: AD F2 0A     LDA $0AF2
C0/56AD: 29 7F        AND #$7F
C0/56AF: F0 04        BEQ $56B5
C0/56B1: A9 0F        LDA #$0F
C0/56B3: 85 6F        STA $6F
C0/56B5: 20 F8 5B     JSR $5BF8
C0/56B8: 20 33 17     JSR $1733       ; update local tile properties (world map)
C0/56BB: 20 4A 10     JSR $104A
C0/56BE: 20 2B 61     JSR $612B
C0/56C1: 20 37 21     JSR $2137
C0/56C4: 20 64 1E     JSR $1E64
C0/56C7: 20 C5 1E     JSR $1EC5
C0/56CA: 20 D7 61     JSR $61D7
C0/56CD: A9 07        LDA #$07
C0/56CF: 8D 05 21     STA $2105
C0/56D2: 20 0A 63     JSR $630A
C0/56D5: 64 BA        STZ $BA
C0/56D7: AD DC 0A     LDA $0ADC
C0/56DA: F0 0B        BEQ $56E7
C0/56DC: 3A           DEC 
C0/56DD: 0A           ASL 
C0/56DE: 0A           ASL 
C0/56DF: A8           TAY 
C0/56E0: B9 DD 0A     LDA $0ADD,Y
C0/56E3: 29 1C        AND #$1C
C0/56E5: 4A           LSR 
C0/56E6: 4A           LSR 
C0/56E7: 0A           ASL 
C0/56E8: AA           TAX 
C0/56E9: C2 20        REP #$20
C0/56EB: BF 3E 57 C0  LDA $C0573E,X
C0/56EF: 85 C0        STA $C0
C0/56F1: A5 06        LDA $06
C0/56F3: E2 20        SEP #$20
C0/56F5: 64 55        STZ $55
C0/56F7: 60           RTS 

C0/56F8: AD D6 0A     LDA $0AD6       ; map index
C0/56FB: AA           TAX 
C0/56FC: BF 39 57 C0  LDA $C05739,X
C0/5700: C2 20        REP #$20
C0/5702: EB           XBA 
C0/5703: AA           TAX 
C0/5704: A4 06        LDY $06
C0/5706: BF C0 FC CF  LDA $CFFCC0,X
C0/570A: 99 00 0C     STA $0C00,Y
C0/570D: E8           INX 
C0/570E: E8           INX 
C0/570F: C8           INY 
C0/5710: C8           INY 
C0/5711: C0 00 01     CPY #$0100
C0/5714: D0 F0        BNE $5706
C0/5716: A5 06        LDA $06
C0/5718: E2 20        SEP #$20
C0/571A: 9C 23 11     STZ $1123
C0/571D: AD D6 0A     LDA $0AD6       ; map index
C0/5720: F0 04        BEQ $5726
C0/5722: C9 02        CMP #$02
C0/5724: D0 08        BNE $572E
C0/5726: A9 0E        LDA #$0E
C0/5728: 8D 23 11     STA $1123
C0/572B: 20 0D 99     JSR $990D       ; init palette animation
C0/572E: 20 18 96     JSR $9618
C0/5731: 20 04 97     JSR $9704
C0/5734: A9 66        LDA #$66
C0/5736: 85 5E        STA $5E
C0/5738: 60           RTS 

; world map tilesets
C0/5739: 00 01 00 02 02

C0/573E: 02 00 04        BRK $04
C0/5741: 00 04        BRK $04
C0/5743: 00 04        BRK $04
C0/5745: 00 04        BRK $04
C0/5747: 00 04        BRK $04
C0/5749: 00 10        BRK $10
C0/574B: 00

; [ load normal map ]

C0/574C: A9 01        LDA #$01
C0/574E: 85 53        STA $53
C0/5750: 9C 9F 16     STZ $169F       ; clear hiryuu flag
C0/5753: A5 B9        LDA $B9
C0/5755: 8D DB 0A     STA $0ADB
C0/5758: 1A           INC 
C0/5759: 85 BF        STA $BF
C0/575B: 20 A7 54     JSR $54A7
C0/575E: 20 F6 5A     JSR $5AF6       ; load map properties
C0/5761: 20 DB 5A     JSR $5ADB
C0/5764: 20 AA 3E     JSR $3EAA       ; load npcs
C0/5767: 20 44 6B     JSR $6B44       ; load tile properties and tileset
C0/576A: 20 75 58     JSR $5875       ; load map layouts
C0/576D: 20 DB 58     JSR $58DB       ; load map palette
C0/5770: 20 BD 5C     JSR $5CBD       ; load treasure chests
C0/5773: 20 D4 63     JSR $63D4
C0/5776: 20 0E 58     JSR $580E
C0/5779: 20 F9 57     JSR $57F9
C0/577C: 20 F6 54     JSR $54F6
C0/577F: AE 71 09     LDX $0971
C0/5782: 8E 02 0C     STX $0C02
C0/5785: 20 1A 59     JSR $591A       ; load map graphics
C0/5788: A5 55        LDA $55
C0/578A: F0 06        BEQ $5792       ; branch if not a world map
C0/578C: 20 DB 5A     JSR $5ADB
C0/578F: 20 28 3D     JSR $3D28       ; load npc graphics
C0/5792: 64 BA        STZ $BA
C0/5794: A2 02 00     LDX #$0002
C0/5797: 86 C0        STX $C0
C0/5799: 20 2D 5B     JSR $5B2D       ; init map color math
C0/579C: 20 44 6B     JSR $6B44       ; load tile properties and tileset
C0/579F: 20 0C 6D     JSR $6D0C
C0/57A2: 20 6A 6C     JSR $6C6A
C0/57A5: 20 92 8C     JSR $8C92
C0/57A8: 20 2E 8C     JSR $8C2E       ; init hdma #1 (window 2 position)
C0/57AB: 20 0E 8D     JSR $8D0E
C0/57AE: 20 53 8B     JSR $8B53
C0/57B1: 20 96 9A     JSR $9A96       ; init map animation
C0/57B4: 20 30 5D     JSR $5D30
C0/57B7: 20 17 28     JSR $2817
C0/57BA: 20 8C 92     JSR $928C       ; init map title
C0/57BD: A9 FE        LDA #$FE
C0/57BF: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/57C2: C9 00        CMP #$00
C0/57C4: D0 06        BNE $57CC
C0/57C6: AD 25 11     LDA $1125       ; song
C0/57C9: 20 0A 46     JSR $460A       ; play song
C0/57CC: 20 E8 17     JSR $17E8       ; update local tile properties (normal map)
C0/57CF: 20 72 13     JSR $1372       ; update party z-level (destination tile)
C0/57D2: 20 A6 13     JSR $13A6       ; update party z-level (current tile)
C0/57D5: 20 7C 23     JSR $237C       ; update party sprite
C0/57D8: 20 B3 39     JSR $39B3       ; update object sprites
C0/57DB: 20 73 29     JSR $2973
C0/57DE: 20 42 28     JSR $2842
C0/57E1: AD 0F 11     LDA $110F
C0/57E4: 4A           LSR 
C0/57E5: 4A           LSR 
C0/57E6: 4A           LSR 
C0/57E7: 4A           LSR 
C0/57E8: 4A           LSR 
C0/57E9: 29 03        AND #$03
C0/57EB: AA           TAX 
C0/57EC: BF F5 57 C0  LDA $C057F5,X
C0/57F0: 85 5E        STA $5E
C0/57F2: 64 55        STZ $55
C0/57F4: 60           RTS 

C0/57F5:              .DB $06, $46, $7E, $06

C0/57F9: AD 0F 11     LDA $110F
C0/57FC: 29 0C        AND #$0C
C0/57FE: F0 0A        BEQ $580A
C0/5800: 29 08        AND #$08
C0/5802: D0 04        BNE $5808
C0/5804: A9 10        LDA #$10
C0/5806: 80 02        BRA $580A
C0/5808: A9 3F        LDA #$3F
C0/580A: 8D 9A 16     STA $169A
C0/580D: 60           RTS 

; [ init auto-scroll ]

C0/580E: A2 00 00     LDX #$0000
C0/5811: 8E 98 10     STX $1098
C0/5814: 8E 9A 10     STX $109A
C0/5817: 8E 9C 10     STX $109C
C0/581A: 8E 9E 10     STX $109E
C0/581D: AD 21 11     LDA $1121
C0/5820: 10 2A        BPL $584C       ; branch if bg3 is not tiled
C0/5822: 29 07        AND #$07
C0/5824: 0A           ASL 
C0/5825: AA           TAX 
C0/5826: C2 20        REP #$20
C0/5828: BF A8 5B C0  LDA $C05BA8,X   ; scroll speed
C0/582C: 8D 9E 10     STA $109E
C0/582F: A5 06        LDA $06
C0/5831: E2 20        SEP #$20
C0/5833: AD 21 11     LDA $1121
C0/5836: 4A           LSR 
C0/5837: 4A           LSR 
C0/5838: 4A           LSR 
C0/5839: 29 07        AND #$07
C0/583B: 0A           ASL 
C0/583C: AA           TAX 
C0/583D: C2 20        REP #$20
C0/583F: BF A8 5B C0  LDA $C05BA8,X
C0/5843: 8D 9C 10     STA $109C
C0/5846: A5 06        LDA $06
C0/5848: E2 20        SEP #$20
C0/584A: 80 28        BRA $5874
C0/584C: 29 07        AND #$07
C0/584E: 0A           ASL 
C0/584F: AA           TAX 
C0/5850: C2 20        REP #$20
C0/5852: BF A8 5B C0  LDA $C05BA8,X
C0/5856: 8D 9A 10     STA $109A
C0/5859: A5 06        LDA $06
C0/585B: E2 20        SEP #$20
C0/585D: AD 21 11     LDA $1121
C0/5860: 4A           LSR 
C0/5861: 4A           LSR 
C0/5862: 4A           LSR 
C0/5863: 29 07        AND #$07
C0/5865: 0A           ASL 
C0/5866: AA           TAX 
C0/5867: C2 20        REP #$20
C0/5869: BF A8 5B C0  LDA $C05BA8,X
C0/586D: 8D 98 10     STA $1098
C0/5870: A5 06        LDA $06
C0/5872: E2 20        SEP #$20
C0/5874: 60           RTS 

; [ load map layouts ]

C0/5875: C2 20        REP #$20
C0/5877: AD 18 11     LDA $1118       ; bg1 map layout
C0/587A: 29 FF 03     AND #$03FF
C0/587D: 3A           DEC 
C0/587E: A8           TAY 
C0/587F: A5 06        LDA $06
C0/5881: E2 20        SEP #$20
C0/5883: A6 06        LDX $06
C0/5885: C0 FF FF     CPY #$FFFF
C0/5888: F0 05        BEQ $588F
C0/588A: 20 CA 6A     JSR $6ACA       ; load map layout
C0/588D: 80 05        BRA $5894
C0/588F: A9 01        LDA #$01
C0/5891: 20 21 6B     JSR $6B21
C0/5894: C2 20        REP #$20
C0/5896: AD 19 11     LDA $1119       ; bg2 map layout
C0/5899: 29 FC 0F     AND #$0FFC
C0/589C: 4A           LSR 
C0/589D: 4A           LSR 
C0/589E: 3A           DEC 
C0/589F: A8           TAY 
C0/58A0: A5 06        LDA $06
C0/58A2: E2 20        SEP #$20
C0/58A4: A2 00 10     LDX #$1000
C0/58A7: C0 FF FF     CPY #$FFFF
C0/58AA: F0 05        BEQ $58B1
C0/58AC: 20 CA 6A     JSR $6ACA       ; load map layout
C0/58AF: 80 05        BRA $58B6
C0/58B1: A9 01        LDA #$01
C0/58B3: 20 21 6B     JSR $6B21
C0/58B6: C2 20        REP #$20
C0/58B8: AD 1A 11     LDA $111A       ; bg3 map layout
C0/58BB: 29 F0 3F     AND #$3FF0
C0/58BE: 4A           LSR 
C0/58BF: 4A           LSR 
C0/58C0: 4A           LSR 
C0/58C1: 4A           LSR 
C0/58C2: 3A           DEC 
C0/58C3: A8           TAY 
C0/58C4: A5 06        LDA $06
C0/58C6: E2 20        SEP #$20
C0/58C8: A2 00 20     LDX #$2000
C0/58CB: C0 FF FF     CPY #$FFFF
C0/58CE: F0 05        BEQ $58D5
C0/58D0: 20 CA 6A     JSR $6ACA       ; load map layout
C0/58D3: 80 05        BRA $58DA
C0/58D5: A9 01        LDA #$01
C0/58D7: 20 21 6B     JSR $6B21
C0/58DA: 60           RTS 

; [ load map palette ]

C0/58DB: AD 22 11     LDA $1122       ; map palette index
C0/58DE: C2 20        REP #$20
C0/58E0: EB           XBA 
C0/58E1: AA           TAX 
C0/58E2: A5 06        LDA $06
C0/58E4: A8           TAY 
C0/58E5: E2 20        SEP #$20
C0/58E7: BF 00 BB C3  LDA $C3BB00,X   ; map palette
C0/58EB: 99 00 0C     STA $0C00,Y
C0/58EE: E8           INX 
C0/58EF: C8           INY 
C0/58F0: C0 00 01     CPY #$0100
C0/58F3: D0 F2        BNE $58E7
C0/58F5: A6 06        LDX $06
C0/58F7: 8E 00 0C     STX $0C00
C0/58FA: A2 8C 31     LDX #$318C
C0/58FD: 8E 04 0C     STX $0C04
C0/5900: A2 FF 7F     LDX #$7FFF
C0/5903: 8E 06 0C     STX $0C06
C0/5906: A2 80 00     LDX #$0080
C0/5909: BF FF FB DF  LDA $DFFBFF,X   ; sprite palettes
C0/590D: 9D FF 0C     STA $0CFF,X
C0/5910: 9D 7F 0D     STA $0D7F,X
C0/5913: CA           DEX 
C0/5914: D0 F3        BNE $5909
C0/5916: 20 67 4D     JSR $4D67       ; copy color palettes to ppu
C0/5919: 60           RTS 

; [ load map graphics ]

C0/591A: C2 20        REP #$20
C0/591C: AD 14 11     LDA $1114       ; map graphics 1
C0/591F: 29 00 3F     AND #$3F00
C0/5922: EB           XBA 
C0/5923: 0A           ASL 
C0/5924: 0A           ASL 
C0/5925: AA           TAX 
C0/5926: BF 84 2D DC  LDA $DC2D84,X   ; pointers to map graphics
C0/592A: 18           CLC 
C0/592B: 69 24 2E     ADC #$2E24
C0/592E: 85 23        STA $23
C0/5930: A9 DC 00     LDA #$00DC
C0/5933: 7F 86 2D DC  ADC $DC2D86,X
C0/5937: 29 FF 00     AND #$00FF
C0/593A: E2 20        SEP #$20
C0/593C: 85 25        STA $25
C0/593E: C2 20        REP #$20
C0/5940: A5 06        LDA $06
C0/5942: 38           SEC 
C0/5943: E5 23        SBC $23
C0/5945: C9 00 20     CMP #$2000
C0/5948: 90 0B        BCC $5955
C0/594A: A9 00 20     LDA #$2000
C0/594D: 85 2C        STA $2C
C0/594F: A5 06        LDA $06
C0/5951: 85 0D        STA $0D
C0/5953: 80 0A        BRA $595F
C0/5955: 85 2C        STA $2C
C0/5957: A5 23        LDA $23
C0/5959: 18           CLC 
C0/595A: 69 00 20     ADC #$2000
C0/595D: 85 0D        STA $0D
C0/595F: A5 06        LDA $06
C0/5961: E2 20        SEP #$20
C0/5963: A6 06        LDX $06
C0/5965: 86 2E        STX $2E
C0/5967: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/596A: C2 20        REP #$20
C0/596C: A5 2C        LDA $2C
C0/596E: 4A           LSR 
C0/596F: 85 2E        STA $2E
C0/5971: A5 06        LDA $06
C0/5973: E2 20        SEP #$20
C0/5975: A6 0D        LDX $0D
C0/5977: F0 0B        BEQ $5984
C0/5979: 86 2C        STX $2C
C0/597B: A6 06        LDX $06
C0/597D: 86 23        STX $23
C0/597F: E6 25        INC $25
C0/5981: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/5984: C2 20        REP #$20
C0/5986: AD 15 11     LDA $1115       ; map graphics 2
C0/5989: 29 C0 0F     AND #$0FC0
C0/598C: 0A           ASL 
C0/598D: 0A           ASL 
C0/598E: EB           XBA 
C0/598F: 0A           ASL 
C0/5990: 0A           ASL 
C0/5991: AA           TAX 
C0/5992: BF 84 2D DC  LDA $DC2D84,X   ; pointers to map graphics
C0/5996: 18           CLC 
C0/5997: 69 24 2E     ADC #$2E24
C0/599A: 85 23        STA $23
C0/599C: A9 DC 00     LDA #$00DC
C0/599F: 7F 86 2D DC  ADC $DC2D86,X
C0/59A3: 29 FF 00     AND #$00FF
C0/59A6: E2 20        SEP #$20
C0/59A8: 85 25        STA $25
C0/59AA: C2 20        REP #$20
C0/59AC: A5 06        LDA $06
C0/59AE: 38           SEC 
C0/59AF: E5 23        SBC $23
C0/59B1: C9 00 20     CMP #$2000
C0/59B4: 90 0B        BCC $59C1
C0/59B6: A9 00 20     LDA #$2000
C0/59B9: 85 2C        STA $2C
C0/59BB: A5 06        LDA $06
C0/59BD: 85 0D        STA $0D
C0/59BF: 80 0A        BRA $59CB
C0/59C1: 85 2C        STA $2C
C0/59C3: A5 23        LDA $23
C0/59C5: 18           CLC 
C0/59C6: 69 00 20     ADC #$2000
C0/59C9: 85 0D        STA $0D
C0/59CB: A5 06        LDA $06
C0/59CD: E2 20        SEP #$20
C0/59CF: A2 00 10     LDX #$1000
C0/59D2: 86 2E        STX $2E
C0/59D4: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/59D7: C2 20        REP #$20
C0/59D9: A5 2C        LDA $2C
C0/59DB: 4A           LSR 
C0/59DC: 18           CLC 
C0/59DD: 69 00 10     ADC #$1000
C0/59E0: 85 2E        STA $2E
C0/59E2: A5 06        LDA $06
C0/59E4: E2 20        SEP #$20
C0/59E6: A6 0D        LDX $0D
C0/59E8: F0 0B        BEQ $59F5
C0/59EA: 86 2C        STX $2C
C0/59EC: A6 06        LDX $06
C0/59EE: 86 23        STX $23
C0/59F0: E6 25        INC $25
C0/59F2: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/59F5: C2 20        REP #$20
C0/59F7: AD 16 11     LDA $1116       ; map graphics 3
C0/59FA: 29 F0 03     AND #$03F0
C0/59FD: 4A           LSR 
C0/59FE: 4A           LSR 
C0/59FF: AA           TAX 
C0/5A00: BF 84 2D DC  LDA $DC2D84,X   ; pointers to map graphics
C0/5A04: 18           CLC 
C0/5A05: 69 24 2E     ADC #$2E24
C0/5A08: 85 23        STA $23
C0/5A0A: A9 DC 00     LDA #$00DC
C0/5A0D: 7F 86 2D DC  ADC $DC2D86,X
C0/5A11: 29 FF 00     AND #$00FF
C0/5A14: E2 20        SEP #$20
C0/5A16: 85 25        STA $25
C0/5A18: C2 20        REP #$20
C0/5A1A: A5 06        LDA $06
C0/5A1C: 38           SEC 
C0/5A1D: E5 23        SBC $23
C0/5A1F: C9 00 20     CMP #$2000
C0/5A22: 90 0B        BCC $5A2F
C0/5A24: A9 00 20     LDA #$2000
C0/5A27: 85 2C        STA $2C
C0/5A29: A5 06        LDA $06
C0/5A2B: 85 0D        STA $0D
C0/5A2D: 80 0A        BRA $5A39
C0/5A2F: 85 2C        STA $2C
C0/5A31: A5 23        LDA $23
C0/5A33: 18           CLC 
C0/5A34: 69 00 20     ADC #$2000
C0/5A37: 85 0D        STA $0D
C0/5A39: A5 06        LDA $06
C0/5A3B: E2 20        SEP #$20
C0/5A3D: A2 00 20     LDX #$2000
C0/5A40: 86 2E        STX $2E
C0/5A42: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/5A45: C2 20        REP #$20
C0/5A47: A5 2C        LDA $2C
C0/5A49: 4A           LSR 
C0/5A4A: 18           CLC 
C0/5A4B: 69 00 20     ADC #$2000
C0/5A4E: 85 2E        STA $2E
C0/5A50: A5 06        LDA $06
C0/5A52: E2 20        SEP #$20
C0/5A54: A6 0D        LDX $0D
C0/5A56: F0 0B        BEQ $5A63
C0/5A58: 86 2C        STX $2C
C0/5A5A: A6 06        LDX $06
C0/5A5C: 86 23        STX $23
C0/5A5E: E6 25        INC $25
C0/5A60: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/5A63: C2 20        REP #$20
C0/5A65: AD 16 11     LDA $1116
C0/5A68: 29 00 FC     AND #$FC00
C0/5A6B: 4A           LSR 
C0/5A6C: EB           XBA 
C0/5A6D: AA           TAX 
C0/5A6E: BF 00 00 DC  LDA $DC0000,X   ; map bg3 graphics
C0/5A72: 18           CLC 
C0/5A73: 69 24 00     ADC #$0024
C0/5A76: 85 23        STA $23
C0/5A78: A5 06        LDA $06
C0/5A7A: E2 20        SEP #$20
C0/5A7C: A9 DC        LDA #$DC
C0/5A7E: 85 25        STA $25
C0/5A80: A2 00 40     LDX #$4000
C0/5A83: 86 2E        STX $2E
C0/5A85: A2 00 10     LDX #$1000
C0/5A88: 86 2C        STX $2C
C0/5A8A: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/5A8D: 20 1E 1D     JSR $1D1E       ; copy party sprite graphics to vram
C0/5A90: 20 14 1E     JSR $1E14
C0/5A93: A2 00 3D     LDX #$3D00
C0/5A96: 86 2E        STX $2E
C0/5A98: A2 00 06     LDX #$0600
C0/5A9B: 86 2C        STX $2C
C0/5A9D: A2 80 D3     LDX #$D380      ; C0/D380 (menu window graphics)
C0/5AA0: 86 23        STX $23
C0/5AA2: A9 C0        LDA #$C0
C0/5AA4: 85 25        STA $25
C0/5AA6: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/5AA9: 20 7C 25     JSR $257C
C0/5AAC: A6 06        LDX $06
C0/5AAE: BD 00 05     LDA $0500,X
C0/5AB1: 29 40        AND #$40
C0/5AB3: D0 07        BNE $5ABC
C0/5AB5: BD 20 05     LDA $0520,X
C0/5AB8: 29 01        AND #$01
C0/5ABA: D0 1E        BNE $5ADA
C0/5ABC: C2 20        REP #$20
C0/5ABE: 8A           TXA 
C0/5ABF: 18           CLC 
C0/5AC0: 69 50 00     ADC #$0050
C0/5AC3: AA           TAX 
C0/5AC4: A5 06        LDA $06
C0/5AC6: E2 20        SEP #$20
C0/5AC8: E0 40 01     CPX #$0140
C0/5ACB: D0 E1        BNE $5AAE
C0/5ACD: 9C 6D 0B     STZ $0B6D
C0/5AD0: A2 20 00     LDX #$0020
C0/5AD3: 86 2E        STX $2E
C0/5AD5: 86 2C        STX $2C
C0/5AD7: 20 13 4D     JSR $4D13       ; fill vram
C0/5ADA: 60           RTS 

C0/5ADB: A5 A4        LDA $A4
C0/5ADD: D0 16        BNE $5AF5
C0/5ADF: A2 00 64     LDX #$6400
C0/5AE2: 86 2E        STX $2E
C0/5AE4: A2 00 02     LDX #$0200
C0/5AE7: 86 2C        STX $2C
C0/5AE9: A2 00 FE     LDX #$FE00      ; CDFE00
C0/5AEC: 86 23        STX $23
C0/5AEE: A9 CD        LDA #$CD
C0/5AF0: 85 25        STA $25
C0/5AF2: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/5AF5: 60           RTS 

; [ load map properties ]

C0/5AF6: AD D4 0A     LDA $0AD4       ; map index
C0/5AF9: 8D 1B 21     STA $211B
C0/5AFC: AD D5 0A     LDA $0AD5
C0/5AFF: 8D 1B 21     STA $211B
C0/5B02: A9 1A        LDA #$1A        ; 26 bytes each
C0/5B04: 8D 1C 21     STA $211C
C0/5B07: 8D 1C 21     STA $211C
C0/5B0A: AE 34 21     LDX $2134
C0/5B0D: A4 06        LDY $06
C0/5B0F: BF 00 9C CE  LDA $CE9C00,X   ; map properties
C0/5B13: 99 0C 11     STA $110C,Y
C0/5B16: E8           INX 
C0/5B17: C8           INY 
C0/5B18: C0 1A 00     CPY #$001A
C0/5B1B: D0 F2        BNE $5B0F
C0/5B1D: C2 20        REP #$20
C0/5B1F: AD 0C 11     LDA $110C
C0/5B22: 29 FF 0F     AND #$0FFF
C0/5B25: 8D D6 0A     STA $0AD6       ; map index
C0/5B28: A5 06        LDA $06
C0/5B2A: E2 20        SEP #$20
C0/5B2C: 60           RTS 

; [ init map color math settings ]

C0/5B2D: A9 09        LDA #$09
C0/5B2F: 8D 05 21     STA $2105       ; 8x8 tiles, high priority bg3, mode 1
C0/5B32: A9 49        LDA #$49
C0/5B34: 8D 07 21     STA $2107       ; 32x16 bg1 map at $4800
C0/5B37: AE D6 0A     LDX $0AD6       ; map index
C0/5B3A: E0 DD 00     CPX #$00DD
C0/5B3D: F0 0C        BEQ $5B4B       ; branch if ???
C0/5B3F: A9 51        LDA #$51
C0/5B41: 8D 08 21     STA $2108       ; 32x16 bg2 map at $5000
C0/5B44: A9 59        LDA #$59
C0/5B46: 8D 09 21     STA $2109       ; 32x16 bg3 map at $5800
C0/5B49: 80 0A        BRA $5B55
C0/5B4B: A9 52        LDA #$52
C0/5B4D: 8D 08 21     STA $2108       ; 16x32 bg2 map at $5000
C0/5B50: A9 5A        LDA #$5A
C0/5B52: 8D 09 21     STA $2109       ; 16x32 bg3 map at $5800
C0/5B55: AE D4 0A     LDX $0AD4
C0/5B58: E0 BE 00     CPX #$00BE
C0/5B5B: D0 05        BNE $5B62       ; branch if ???
C0/5B5D: A9 23        LDA #$23
C0/5B5F: 8D 09 21     STA $2109       ; 32x32 bg3 map at $2000
C0/5B62: AD 10 11     LDA $1110
C0/5B65: 29 3F        AND #$3F
C0/5B67: 85 08        STA $08
C0/5B69: 0A           ASL 
C0/5B6A: 18           CLC 
C0/5B6B: 65 08        ADC $08
C0/5B6D: AA           TAX 
C0/5B6E: BF B8 5B C0  LDA $C05BB8,X
C0/5B72: 85 48        STA $48
C0/5B74: A5 44        LDA $44
C0/5B76: D0 04        BNE $5B7C
C0/5B78: A5 48        LDA $48
C0/5B7A: 85 47        STA $47
C0/5B7C: BF BA 5B C0  LDA $C05BBA,X
C0/5B80: 85 4A        STA $4A
C0/5B82: 8D 2D 21     STA $212D       ; sub-screen designation
C0/5B85: BF B9 5B C0  LDA $C05BB9,X
C0/5B89: 29 01        AND #$01
C0/5B8B: F0 04        BEQ $5B91
C0/5B8D: A9 BF        LDA #$BF
C0/5B8F: 80 02        BRA $5B93
C0/5B91: A9 BC        LDA #$BC
C0/5B93: 8D 23 21     STA $2123       ; window mask settings bg1/bg2
C0/5B96: BF B9 5B C0  LDA $C05BB9,X
C0/5B9A: 09 01        ORA #$01        ; bg1 always on
C0/5B9C: 8D 2C 21     STA $212C       ; main screen designation
C0/5B9F: A5 44        LDA $44
C0/5BA1: D0 04        BNE $5BA7
C0/5BA3: A5 4A        LDA $4A
C0/5BA5: 85 49        STA $49
C0/5BA7: 60           RTS 

; auto-scroll speeds
C0/5BA8:              .DW $0000, $FFFC, $FFFE, $FFFF, $0000, $0001, $0002, $0004

; color math, main screen, sub-screen
C0/5BB8: 00 17 00
C0/5BBB: 51 13 04
C0/5BBE: 42 13 04
C0/5BC1: 42 13 10
C0/5BC4: 06 17 11
C0/5BC7: D1 13 04
C0/5BCA: 42 06 11
C0/5BCD: 53 13 15
C0/5BD0: 51 11 02
C0/5BD3: 43 12 04
C0/5BD6: 20 15 02
C0/5BD9: 11 13 02
C0/5BDC: 13 13 04
C0/5BDF: 52 13 14
C0/5BE2: 02 17 11
C0/5BE5: C2 12 04
C0/5BE8: 50 17 01
C0/5BEB: 44 17 11
C0/5BEE: 51 12 04
C0/5BF1: 44 17 13

; [  ]

C0/5BF4: A9 10        LDA #$10
C0/5BF6: 80 09        BRA $5C01
C0/5BF8: AD D6 0A     LDA $0AD6       ; map index
C0/5BFB: C9 03        CMP #$03
C0/5BFD: B0 2D        BCS $5C2C       ; return if not a world map
C0/5BFF: A5 6F        LDA $6F
C0/5C01: 4A           LSR 
C0/5C02: 0A           ASL 
C0/5C03: 0A           ASL 
C0/5C04: 0A           ASL 
C0/5C05: 0A           ASL 
C0/5C06: AA           TAX 
C0/5C07: AD D6 0A     LDA $0AD6       ; map index
C0/5C0A: 29 01        AND #$01
C0/5C0C: 0A           ASL 
C0/5C0D: 18           CLC 
C0/5C0E: 69 0E        ADC #$0E
C0/5C10: 85 23        STA $23
C0/5C12: 64 24        STZ $24
C0/5C14: A4 06        LDY $06
C0/5C16: BF 2D 5C C0  LDA $C05C2D,X
C0/5C1A: 99 40 0C     STA $0C40,Y
C0/5C1D: BF 2E 5C C0  LDA $C05C2E,X
C0/5C21: 99 41 0C     STA $0C41,Y
C0/5C24: E8           INX 
C0/5C25: E8           INX 
C0/5C26: C8           INY 
C0/5C27: C8           INY 
C0/5C28: C4 23        CPY $23
C0/5C2A: D0 EA        BNE $5C16
C0/5C2C: 60           RTS 

C0/5C2D: 20 0C 60     JSR $600C
C0/5C30: 40           RTI 
C0/5C31: EC 76 47     CPX $4776
C0/5C34: 72 A5        ADC ($A5)
C0/5C36: 65 E2        ADC $E2
C0/5C38: 58           CLI 
C0/5C39: A1 4C        LDA ($4C,X)
C0/5C3B: 20 0C 20     JSR $200C
C0/5C3E: 18           CLC 
C0/5C3F: 80 44        BRA $5C85
C0/5C41: AB           PLB 
C0/5C42: 76 06        ROR $06,X
C0/5C44: 6E 84 65     ROR $6584
C0/5C47: E2 5C        SEP #$5C
C0/5C49: A1 50        LDA ($50,X)
C0/5C4B: 20 18 40     JSR $4018
C0/5C4E: 24 80        BIT $80
C0/5C50: 48           PHA 
C0/5C51: 49 72        EOR #$72
C0/5C53: C5 6D        CMP $6D
C0/5C55: 64 65        STZ $65
C0/5C57: C2 5C        REP #$5C
C0/5C59: A1 50        LDA ($50,X)
C0/5C5B: 40           RTI 
C0/5C5C: 24 61        BIT $61
C0/5C5E: 30 81        BMI $5BE1
C0/5C60: 50 08        BVC $5C6A
C0/5C62: 6E A5 69     ROR $69A5
C0/5C65: 43 65        EOR $65,S
C0/5C67: C2 5C        REP #$5C
C0/5C69: A1 54        LDA ($54,X)
C0/5C6B: 61 30        ADC ($30,X)
C0/5C6D: 61 3C        ADC ($3C,X)
C0/5C6F: 81 54        STA ($54,X)
C0/5C71: A6 69        LDX $69
C0/5C73: 64 69        STZ $69
C0/5C75: 03 61        ORA $61,S
C0/5C77: C1 5C        CMP ($5C,X)
C0/5C79: A1 58        LDA ($58,X)
C0/5C7B: 61 3C        ADC ($3C,X)
C0/5C7D: 81 48        STA ($48,X)
C0/5C7F: A1 58        LDA ($58,X)
C0/5C81: 44 69 23     MVP $69,$23
C0/5C84: 65 E2        ADC $E2
C0/5C86: 60           RTS 
C0/5C87: C1 60        CMP ($60,X)
C0/5C89: A1 5C        LDA ($5C,X)
C0/5C8B: 81 48        STA ($48,X)
C0/5C8D: 81 54        STA ($54,X)
C0/5C8F: A1 5C        LDA ($5C,X)
C0/5C91: 03 65        ORA $65,S
C0/5C93: E2 64        SEP #$64
C0/5C95: C2 60        REP #$60
C0/5C97: A1 60        LDA ($60,X)
C0/5C99: A1 5C        LDA ($5C,X)
C0/5C9B: 81 54        STA ($54,X)
C0/5C9D: 81 54        STA ($54,X)
C0/5C9F: A1 5C        LDA ($5C,X)
C0/5CA1: 03 65        ORA $65,S
C0/5CA3: E2 64        SEP #$64
C0/5CA5: C2 60        REP #$60
C0/5CA7: A1 60        LDA ($60,X)
C0/5CA9: A1 5C        LDA ($5C,X)
C0/5CAB: 81 54        STA ($54,X)
C0/5CAD: A1 60        LDA ($60,X)
C0/5CAF: A1 60        LDA ($60,X)
C0/5CB1: A1 60        LDA ($60,X)
C0/5CB3: A1 60        LDA ($60,X)
C0/5CB5: A1 60        LDA ($60,X)
C0/5CB7: A1 60        LDA ($60,X)
C0/5CB9: A1 60        LDA ($60,X)
C0/5CBB: A1 60        LDA ($60,X)

; [ load treasure chests ]

C0/5CBD: C2 20        REP #$20
C0/5CBF: AD D4 0A     LDA $0AD4
C0/5CC2: AA           TAX 
C0/5CC3: BF 00 30 D1  LDA $D13000,X   ; pointer to treasure properties
C0/5CC7: 29 FF 00     AND #$00FF
C0/5CCA: 0A           ASL 
C0/5CCB: 0A           ASL 
C0/5CCC: 85 23        STA $23
C0/5CCE: BF 01 30 D1  LDA $D13001,X   ; pointer to next map's treasure properties
C0/5CD2: 29 FF 00     AND #$00FF
C0/5CD5: 0A           ASL 
C0/5CD6: 0A           ASL 
C0/5CD7: 85 26        STA $26
C0/5CD9: A5 06        LDA $06
C0/5CDB: E2 20        SEP #$20
C0/5CDD: A6 23        LDX $23
C0/5CDF: E4 26        CPX $26
C0/5CE1: F0 4C        BEQ $5D2F
C0/5CE3: C2 20        REP #$20
C0/5CE5: 8A           TXA 
C0/5CE6: 4A           LSR 
C0/5CE7: 4A           LSR 
C0/5CE8: E2 20        SEP #$20
C0/5CEA: EB           XBA 
C0/5CEB: A9 00        LDA #$00
C0/5CED: EB           XBA 
C0/5CEE: 8D A1 16     STA $16A1
C0/5CF1: 20 16 CA     JSR $CA16       ; get treasure flag
C0/5CF4: C9 00        CMP #$00
C0/5CF6: F0 2D        BEQ $5D25       ; skip if treasure hasn't been obtained
C0/5CF8: A6 23        LDX $23
C0/5CFA: BF 11 32 D1  LDA $D13211,X
C0/5CFE: C2 20        REP #$20
C0/5D00: 0A           ASL 
C0/5D01: 0A           ASL 
C0/5D02: 0A           ASL 
C0/5D03: 0A           ASL 
C0/5D04: 0A           ASL 
C0/5D05: 0A           ASL 
C0/5D06: 85 0D        STA $0D
C0/5D08: BF 10 32 D1  LDA $D13210,X
C0/5D0C: 29 FF 00     AND #$00FF
C0/5D0F: 18           CLC 
C0/5D10: 65 0D        ADC $0D
C0/5D12: AA           TAX 
C0/5D13: A5 06        LDA $06
C0/5D15: E2 20        SEP #$20
C0/5D17: BF 00 00 7F  LDA $7F0000,X   ; show open treasure chest
C0/5D1B: C9 02        CMP #$02
C0/5D1D: D0 06        BNE $5D25
C0/5D1F: A9 12        LDA #$12
C0/5D21: 9F 00 00 7F  STA $7F0000,X
C0/5D25: A6 23        LDX $23
C0/5D27: E8           INX 
C0/5D28: E8           INX 
C0/5D29: E8           INX 
C0/5D2A: E8           INX 
C0/5D2B: 86 23        STX $23
C0/5D2D: 80 AE        BRA $5CDD
C0/5D2F: 60           RTS 

; [  ]

C0/5D30: 20 87 5D     JSR $5D87
C0/5D33: A9 7F        LDA #$7F
C0/5D35: 48           PHA 
C0/5D36: AB           PLB 
C0/5D37: A2 FE 00     LDX #$00FE
C0/5D3A: A0 00 01     LDY #$0100
C0/5D3D: C2 20        REP #$20
C0/5D3F: BD 6C 6B     LDA $6B6C,X
C0/5D42: 99 6C 6B     STA $6B6C,Y
C0/5D45: C8           INY 
C0/5D46: C8           INY 
C0/5D47: CA           DEX 
C0/5D48: CA           DEX 
C0/5D49: 10 F4        BPL $5D3F
C0/5D4B: A5 06        LDA $06
C0/5D4D: E2 20        SEP #$20
C0/5D4F: A9 00        LDA #$00
C0/5D51: 48           PHA 
C0/5D52: AB           PLB 
C0/5D53: 60           RTS 

; [  ]

C0/5D54: 20 87 5D     JSR $5D87
C0/5D57: A9 7F        LDA #$7F
C0/5D59: 48           PHA 
C0/5D5A: AB           PLB 
C0/5D5B: A2 FE 00     LDX #$00FE
C0/5D5E: A0 00 01     LDY #$0100
C0/5D61: C2 20        REP #$20
C0/5D63: BD 6C 6B     LDA $6B6C,X
C0/5D66: 99 6C 6B     STA $6B6C,Y
C0/5D69: C8           INY 
C0/5D6A: C8           INY 
C0/5D6B: CA           DEX 
C0/5D6C: CA           DEX 
C0/5D6D: CA           DEX 
C0/5D6E: CA           DEX 
C0/5D6F: 10 F2        BPL $5D63
C0/5D71: A9 FF 00     LDA #$00FF
C0/5D74: 99 6C 6B     STA $6B6C,Y
C0/5D77: C8           INY 
C0/5D78: C8           INY 
C0/5D79: C0 00 02     CPY #$0200
C0/5D7C: D0 F6        BNE $5D74
C0/5D7E: A5 06        LDA $06
C0/5D80: E2 20        SEP #$20
C0/5D82: A9 00        LDA #$00
C0/5D84: 48           PHA 
C0/5D85: AB           PLB 
C0/5D86: 60           RTS 

; [  ]

C0/5D87: AD 9A 16     LDA $169A
C0/5D8A: 29 7F        AND #$7F
C0/5D8C: D0 01        BNE $5D8F
C0/5D8E: 60           RTS 
C0/5D8F: 85 0D        STA $0D
C0/5D91: 64 0E        STZ $0E
C0/5D93: C2 20        REP #$20
C0/5D95: A6 06        LDX $06
C0/5D97: 9B           TXY 
C0/5D98: A5 0D        LDA $0D
C0/5D9A: 48           PHA 
C0/5D9B: 85 0F        STA $0F
C0/5D9D: 06 0D        ASL $0D
C0/5D9F: A9 03 00     LDA #$0003
C0/5DA2: 38           SEC 
C0/5DA3: E5 0D        SBC $0D
C0/5DA5: 85 11        STA $11
C0/5DA7: A5 0F        LDA $0F
C0/5DA9: 99 00 0E     STA $0E00,Y
C0/5DAC: A5 11        LDA $11
C0/5DAE: 30 13        BMI $5DC3
C0/5DB0: 8A           TXA 
C0/5DB1: 38           SEC 
C0/5DB2: E5 0F        SBC $0F
C0/5DB4: 0A           ASL 
C0/5DB5: 0A           ASL 
C0/5DB6: 18           CLC 
C0/5DB7: 69 0A 00     ADC #$000A
C0/5DBA: 18           CLC 
C0/5DBB: 65 11        ADC $11
C0/5DBD: 85 11        STA $11
C0/5DBF: C6 0F        DEC $0F
C0/5DC1: 80 0C        BRA $5DCF
C0/5DC3: 8A           TXA 
C0/5DC4: 0A           ASL 
C0/5DC5: 0A           ASL 
C0/5DC6: 18           CLC 
C0/5DC7: 69 06 00     ADC #$0006
C0/5DCA: 18           CLC 
C0/5DCB: 65 11        ADC $11
C0/5DCD: 85 11        STA $11
C0/5DCF: E8           INX 
C0/5DD0: C8           INY 
C0/5DD1: C8           INY 
C0/5DD2: E4 0F        CPX $0F
C0/5DD4: 90 D1        BCC $5DA7
C0/5DD6: BB           TYX 
C0/5DD7: CA           DEX 
C0/5DD8: CA           DEX 
C0/5DD9: BD 00 0E     LDA $0E00,X
C0/5DDC: DD FE 0D     CMP $0DFE,X
C0/5DDF: F0 07        BEQ $5DE8
C0/5DE1: 8A           TXA 
C0/5DE2: 4A           LSR 
C0/5DE3: 99 00 0E     STA $0E00,Y
C0/5DE6: C8           INY 
C0/5DE7: C8           INY 
C0/5DE8: CA           DEX 
C0/5DE9: CA           DEX 
C0/5DEA: D0 ED        BNE $5DD9
C0/5DEC: 68           PLA 
C0/5DED: 0A           ASL 
C0/5DEE: 49 FF FF     EOR #$FFFF
C0/5DF1: 1A           INC 
C0/5DF2: 18           CLC 
C0/5DF3: 69 02 01     ADC #$0102
C0/5DF6: 85 0D        STA $0D
C0/5DF8: AA           TAX 
C0/5DF9: F0 0F        BEQ $5E0A
C0/5DFB: A6 06        LDX $06
C0/5DFD: A9 FF 00     LDA #$00FF
C0/5E00: 9F 6C 6B 7F  STA $7F6B6C,X
C0/5E04: E8           INX 
C0/5E05: E8           INX 
C0/5E06: E4 0D        CPX $0D
C0/5E08: D0 F6        BNE $5E00
C0/5E0A: A5 06        LDA $06
C0/5E0C: E2 20        SEP #$20
C0/5E0E: 88           DEY 
C0/5E0F: 88           DEY 
C0/5E10: B9 00 0E     LDA $0E00,Y
C0/5E13: 18           CLC 
C0/5E14: 69 78        ADC #$78
C0/5E16: 9F 6D 6B 7F  STA $7F6B6D,X
C0/5E1A: A9 78        LDA #$78
C0/5E1C: 38           SEC 
C0/5E1D: F9 00 0E     SBC $0E00,Y
C0/5E20: 9F 6C 6B 7F  STA $7F6B6C,X
C0/5E24: E8           INX 
C0/5E25: E8           INX 
C0/5E26: 88           DEY 
C0/5E27: 88           DEY 
C0/5E28: 10 E6        BPL $5E10
C0/5E2A: 60           RTS 

; [ copy tile layout to vram ??? ]

; +$73: vram offset (+$4800)

C0/5E2B: A9 80        LDA #$80
C0/5E2D: 8D 15 21     STA $2115
C0/5E30: A9 01        LDA #$01
C0/5E32: 8D 00 43     STA $4300
C0/5E35: A9 18        LDA #$18
C0/5E37: 8D 01 43     STA $4301
C0/5E3A: A9 7F        LDA #$7F
C0/5E3C: 8D 04 43     STA $4304
C0/5E3F: C2 20        REP #$20
C0/5E41: A9 22 76     LDA #$7622      ; 7F/7622
C0/5E44: 8D 02 43     STA $4302
C0/5E47: A9 00 10     LDA #$1000
C0/5E4A: 8D 05 43     STA $4305
C0/5E4D: A5 73        LDA $73
C0/5E4F: 4A           LSR 
C0/5E50: 18           CLC 
C0/5E51: 69 00 48     ADC #$4800
C0/5E54: 8D 16 21     STA $2116
C0/5E57: A5 06        LDA $06
C0/5E59: E2 20        SEP #$20
C0/5E5B: A9 01        LDA #$01
C0/5E5D: 8D 0B 42     STA $420B
C0/5E60: 60           RTS 

C0/5E61: AD D9 0A     LDA $0AD9
C0/5E64: 38           SEC 
C0/5E65: E9 03        SBC #$03
C0/5E67: 29 3F        AND #$3F
C0/5E69: EB           XBA 
C0/5E6A: C2 20        REP #$20
C0/5E6C: 4A           LSR 
C0/5E6D: 4A           LSR 
C0/5E6E: 85 23        STA $23
C0/5E70: A5 06        LDA $06
C0/5E72: E2 20        SEP #$20
C0/5E74: AD D8 0A     LDA $0AD8
C0/5E77: 3A           DEC 
C0/5E78: 29 3F        AND #$3F
C0/5E7A: 18           CLC 
C0/5E7B: 65 23        ADC $23
C0/5E7D: 85 23        STA $23
C0/5E7F: A6 23        LDX $23
C0/5E81: BF 00 00 7F  LDA $7F0000,X
C0/5E85: 20 88 5E     JSR $5E88
C0/5E88: C9 20        CMP #$20
C0/5E8A: A5 53        LDA $53
C0/5E8C: D0 08        BNE $5E96
C0/5E8E: A6 61        LDX $61
C0/5E90: 86 69        STX $69
C0/5E92: A6 63        LDX $63
C0/5E94: 86 6B        STX $6B
C0/5E96: A4 06        LDY $06
C0/5E98: A5 3F        LDA $3F
C0/5E9A: 4A           LSR 
C0/5E9B: 4A           LSR 
C0/5E9C: 85 17        STA $17
C0/5E9E: 98           TYA 
C0/5E9F: 18           CLC 
C0/5EA0: 65 6B        ADC $6B
C0/5EA2: 18           CLC 
C0/5EA3: 65 17        ADC $17
C0/5EA5: 29 1E        AND #$1E
C0/5EA7: AA           TAX 
C0/5EA8: C2 20        REP #$20
C0/5EAA: A5 69        LDA $69
C0/5EAC: 4A           LSR 
C0/5EAD: 18           CLC 
C0/5EAE: 7F C3 5E C0  ADC $C05EC3,X
C0/5EB2: BB           TYX 
C0/5EB3: 9F E2 6D 7F  STA $7F6DE2,X
C0/5EB7: A5 06        LDA $06
C0/5EB9: E2 20        SEP #$20
C0/5EBB: C8           INY 
C0/5EBC: C8           INY 
C0/5EBD: C0 20 00     CPY #$0020
C0/5EC0: D0 D6        BNE $5E98
C0/5EC2: 60           RTS 

C0/5EC3: 00 00        BRK $00
C0/5EC5: 00 00        BRK $00
C0/5EC7: 01 00        ORA ($00,X)
C0/5EC9: 01 00        ORA ($00,X)
C0/5ECB: 01 00        ORA ($00,X)
C0/5ECD: 01 00        ORA ($00,X)
C0/5ECF: 01 00        ORA ($00,X)
C0/5ED1: 00 00        BRK $00
C0/5ED3: 00 00        BRK $00
C0/5ED5: 00 00        BRK $00
C0/5ED7: FF FF FF FF  SBC $FFFFFF,X
C0/5EDB: FF FF FF FF  SBC $FFFFFF,X
C0/5EDF: FF FF 00 00  SBC $0000FF,X
C0/5EE3: 00 00        BRK $00

C0/5EE5: A6 06        LDX $06
C0/5EE7: A9 90        LDA #$90
C0/5EE9: 9F 8C 6D 7F  STA $7F6D8C,X
C0/5EED: A9 E2        LDA #$E2
C0/5EEF: 9F 8D 6D 7F  STA $7F6D8D,X
C0/5EF3: A9 6D        LDA #$6D
C0/5EF5: 9F 8E 6D 7F  STA $7F6D8E,X
C0/5EF9: E8           INX 
C0/5EFA: E8           INX 
C0/5EFB: E8           INX 
C0/5EFC: E0 2A 00     CPX #$002A
C0/5EFF: D0 E6        BNE $5EE7
C0/5F01: A9 00        LDA #$00
C0/5F03: 9F 8C 6D 7F  STA $7F6D8C,X
C0/5F07: 9C 0C 42     STZ $420C
C0/5F0A: A9 42        LDA #$42
C0/5F0C: 8D 30 43     STA $4330
C0/5F0F: 8D 50 43     STA $4350
C0/5F12: A2 8C 6D     LDX #$6D8C
C0/5F15: 8E 32 43     STX $4332
C0/5F18: 8E 52 43     STX $4352
C0/5F1B: A9 7F        LDA #$7F
C0/5F1D: 8D 34 43     STA $4334
C0/5F20: 8D 54 43     STA $4354
C0/5F23: 8D 37 43     STA $4337
C0/5F26: 8D 57 43     STA $4357
C0/5F29: A5 53        LDA $53
C0/5F2B: D0 06        BNE $5F33
C0/5F2D: A9 0D        LDA #$0D
C0/5F2F: 8D 31 43     STA $4331
C0/5F32: 60           RTS 
C0/5F33: A9 0F        LDA #$0F
C0/5F35: 8D 31 43     STA $4331
C0/5F38: A9 11        LDA #$11
C0/5F3A: 8D 51 43     STA $4351
C0/5F3D: 60           RTS 
C0/5F3E: A4 06        LDY $06
C0/5F40: A5 3F        LDA $3F
C0/5F42: 4A           LSR 
C0/5F43: 4A           LSR 
C0/5F44: 85 17        STA $17
C0/5F46: 98           TYA 
C0/5F47: 18           CLC 
C0/5F48: 65 6B        ADC $6B
C0/5F4A: 18           CLC 
C0/5F4B: 65 17        ADC $17
C0/5F4D: 29 1E        AND #$1E
C0/5F4F: AA           TAX 
C0/5F50: C2 20        REP #$20
C0/5F52: A5 6B        LDA $6B
C0/5F54: 4A           LSR 
C0/5F55: 18           CLC 
C0/5F56: 7F 6B 5F C0  ADC $C05F6B,X
C0/5F5A: BB           TYX 
C0/5F5B: 9F 02 6E 7F  STA $7F6E02,X
C0/5F5F: A5 06        LDA $06
C0/5F61: E2 20        SEP #$20
C0/5F63: C8           INY 
C0/5F64: C8           INY 
C0/5F65: C0 20 00     CPY #$0020
C0/5F68: D0 D6        BNE $5F40
C0/5F6A: 60           RTS 
C0/5F6B: 00 00        BRK $00
C0/5F6D: 00 00        BRK $00
C0/5F6F: 01 00        ORA ($00,X)
C0/5F71: 01 00        ORA ($00,X)
C0/5F73: 01 00        ORA ($00,X)
C0/5F75: 01 00        ORA ($00,X)
C0/5F77: 01 00        ORA ($00,X)
C0/5F79: 00 00        BRK $00
C0/5F7B: 00 00        BRK $00
C0/5F7D: 00 00        BRK $00
C0/5F7F: FF FF FF FF  SBC $FFFFFF,X
C0/5F83: FF FF FF FF  SBC $FFFFFF,X
C0/5F87: FF FF 00 00  SBC $0000FF,X
C0/5F8B: 00 00        BRK $00

C0/5F8D: A6 06        LDX $06
C0/5F8F: A9 90        LDA #$90
C0/5F91: 9F B7 6D 7F  STA $7F6DB7,X
C0/5F95: A9 02        LDA #$02
C0/5F97: 9F B8 6D 7F  STA $7F6DB8,X
C0/5F9B: A9 6E        LDA #$6E
C0/5F9D: 9F B9 6D 7F  STA $7F6DB9,X
C0/5FA1: E8           INX 
C0/5FA2: E8           INX 
C0/5FA3: E8           INX 
C0/5FA4: E0 2A 00     CPX #$002A
C0/5FA7: D0 E6        BNE $5F8F
C0/5FA9: A9 00        LDA #$00
C0/5FAB: 9F B7 6D 7F  STA $7F6DB7,X
C0/5FAF: 9C 0C 42     STZ $420C
C0/5FB2: A9 42        LDA #$42
C0/5FB4: 8D 40 43     STA $4340
C0/5FB7: 8D 60 43     STA $4360
C0/5FBA: A2 B7 6D     LDX #$6DB7
C0/5FBD: 8E 42 43     STX $4342
C0/5FC0: 8E 62 43     STX $4362
C0/5FC3: A9 7F        LDA #$7F
C0/5FC5: 8D 44 43     STA $4344
C0/5FC8: 8D 64 43     STA $4364
C0/5FCB: 8D 47 43     STA $4347
C0/5FCE: 8D 67 43     STA $4367
C0/5FD1: A5 53        LDA $53
C0/5FD3: D0 06        BNE $5FDB
C0/5FD5: A9 0E        LDA #$0E
C0/5FD7: 8D 41 43     STA $4341
C0/5FDA: 60           RTS 
C0/5FDB: A9 10        LDA #$10
C0/5FDD: 8D 41 43     STA $4341
C0/5FE0: A9 12        LDA #$12
C0/5FE2: 8D 61 43     STA $4361
C0/5FE5: 60           RTS 

C0/5FE6: AD 9E 16     LDA $169E
C0/5FE9: C9 02        CMP #$02
C0/5FEB: F0 03        BEQ $5FF0
C0/5FED: 4C 76 60     JMP $6076
C0/5FF0: A9 70        LDA #$70
C0/5FF2: 8D 00 03     STA $0300
C0/5FF5: A9 80        LDA #$80
C0/5FF7: 8D 01 03     STA $0301
C0/5FFA: A9 C2        LDA #$C2
C0/5FFC: 8D 02 03     STA $0302
C0/5FFF: A9 01        LDA #$01
C0/6001: 8D 03 03     STA $0303
C0/6004: 64 BC        STZ $BC
C0/6006: A5 42        LDA $42
C0/6008: D0 3E        BNE $6048
C0/600A: AD D8 0A     LDA $0AD8
C0/600D: 85 75        STA $75
C0/600F: AD D9 0A     LDA $0AD9
C0/6012: 85 76        STA $76
C0/6014: A5 76        LDA $76
C0/6016: C2 20        REP #$20
C0/6018: 0A           ASL 
C0/6019: 0A           ASL 
C0/601A: 0A           ASL 
C0/601B: 0A           ASL 
C0/601C: 0A           ASL 
C0/601D: 0A           ASL 
C0/601E: 85 0D        STA $0D
C0/6020: A5 75        LDA $75
C0/6022: 29 FF 00     AND #$00FF
C0/6025: 18           CLC 
C0/6026: 65 0D        ADC $0D
C0/6028: AA           TAX 
C0/6029: A5 06        LDA $06
C0/602B: E2 20        SEP #$20
C0/602D: BF 00 00 7F  LDA $7F0000,X
C0/6031: C9 05        CMP #$05
C0/6033: D0 40        BNE $6075
C0/6035: A2 01 01     LDX #$0101
C0/6038: 86 2C        STX $2C
C0/603A: A6 06        LDX $06
C0/603C: 86 73        STX $73
C0/603E: A9 15        LDA #$15
C0/6040: 8D B3 16     STA $16B3
C0/6043: 20 08 6F     JSR $6F08
C0/6046: 80 2D        BRA $6075
C0/6048: A5 42        LDA $42
C0/604A: 4A           LSR 
C0/604B: 4A           LSR 
C0/604C: 4A           LSR 
C0/604D: A9 00        LDA #$00
C0/604F: 69 29        ADC #$29
C0/6051: 85 BB        STA $BB
C0/6053: A5 42        LDA $42
C0/6055: C9 30        CMP #$30
C0/6057: D0 08        BNE $6061
C0/6059: 20 71 4A     JSR $4A71
C0/605C: A9 85        LDA #$85
C0/605E: 20 3C 46     JSR $463C       ; play sound effect
C0/6061: A5 42        LDA $42
C0/6063: C9 30        CMP #$30
C0/6065: 90 0E        BCC $6075
C0/6067: A5 C6        LDA $C6
C0/6069: 1A           INC 
C0/606A: 1A           INC 
C0/606B: 85 C6        STA $C6
C0/606D: C9 80        CMP #$80
C0/606F: D0 04        BNE $6075
C0/6071: A9 80        LDA #$80
C0/6073: 85 42        STA $42
C0/6075: 60           RTS 
C0/6076: A5 42        LDA $42
C0/6078: D0 06        BNE $6080
C0/607A: 20 71 4A     JSR $4A71
C0/607D: 9C 9E 16     STZ $169E
C0/6080: 60           RTS 

; [ fade out ]

C0/6081: AD 9E 16     LDA $169E
C0/6084: D0 03        BNE $6089
C0/6086: 20 71 4A     JSR $4A71
C0/6089: 64 42        STZ $42
C0/608B: 20 41 4E     JSR $4E41       ; wait for vblank
C0/608E: AD 9E 16     LDA $169E
C0/6091: F0 0E        BEQ $60A1
C0/6093: A5 42        LDA $42
C0/6095: 30 0A        BMI $60A1
C0/6097: 20 E6 5F     JSR $5FE6
C0/609A: 20 7C 23     JSR $237C       ; update party sprite
C0/609D: E6 42        INC $42
C0/609F: 80 EA        BRA $608B
C0/60A1: E6 42        INC $42
C0/60A3: A5 45        LDA $45
C0/60A5: D0 E4        BNE $608B
C0/60A7: 60           RTS 

C0/60A8: AD 9E 16     LDA $169E
C0/60AB: C9 02        CMP #$02
C0/60AD: D0 50        BNE $60FF
C0/60AF: A5 42        LDA $42
C0/60B1: C9 1E        CMP #$1E
C0/60B3: B0 0B        BCS $60C0
C0/60B5: 3A           DEC 
C0/60B6: 0A           ASL 
C0/60B7: 0A           ASL 
C0/60B8: 85 C6        STA $C6
C0/60BA: A9 2A        LDA #$2A
C0/60BC: 85 BB        STA $BB
C0/60BE: 80 3F        BRA $60FF
C0/60C0: C9 3E        CMP #$3E
C0/60C2: B0 23        BCS $60E7
C0/60C4: 38           SEC 
C0/60C5: E9 1E        SBC #$1E
C0/60C7: 85 BE        STA $BE
C0/60C9: 4A           LSR 
C0/60CA: B0 0B        BCS $60D7
C0/60CC: 9C A2 10     STZ $10A2
C0/60CF: 9C A6 10     STZ $10A6
C0/60D2: 9C A8 10     STZ $10A8
C0/60D5: 80 28        BRA $60FF
C0/60D7: 49 FF        EOR #$FF
C0/60D9: 18           CLC 
C0/60DA: 69 10        ADC #$10
C0/60DC: 8D A2 10     STA $10A2
C0/60DF: 8D A6 10     STA $10A6
C0/60E2: 8D AA 10     STA $10AA
C0/60E5: 80 18        BRA $60FF
C0/60E7: C9 56        CMP #$56
C0/60E9: B0 08        BCS $60F3
C0/60EB: 64 BE        STZ $BE
C0/60ED: A9 28        LDA #$28
C0/60EF: 85 BB        STA $BB
C0/60F1: 80 0C        BRA $60FF
C0/60F3: 9C 9E 16     STZ $169E
C0/60F6: A9 01        LDA #$01
C0/60F8: 85 BC        STA $BC
C0/60FA: A9 02        LDA #$02
C0/60FC: 8D DB 0A     STA $0ADB
C0/60FF: 60           RTS 

; [ fade in ]

C0/6100: 20 68 4A     JSR $4A68
C0/6103: 64 42        STZ $42
C0/6105: A9 81        LDA #$81
C0/6107: 8D 00 42     STA $4200
C0/610A: A9 00        LDA #$00
C0/610C: 8D 00 21     STA $2100
C0/610F: 58           CLI 
C0/6110: 20 41 4E     JSR $4E41       ; wait for vblank
C0/6113: AD 9E 16     LDA $169E
C0/6116: C9 02        CMP #$02
C0/6118: D0 0A        BNE $6124
C0/611A: 20 A8 60     JSR $60A8
C0/611D: 20 7C 23     JSR $237C       ; update party sprite
C0/6120: E6 42        INC $42
C0/6122: 80 EC        BRA $6110
C0/6124: A5 45        LDA $45
C0/6126: C9 F0        CMP #$F0
C0/6128: D0 E6        BNE $6110
C0/612A: 60           RTS 

C0/612B: A2 3C 00     LDX #$003C
C0/612E: 86 23        STX $23
C0/6130: A6 06        LDX $06
C0/6132: 80 08        BRA $613C
C0/6134: A2 40 00     LDX #$0040
C0/6137: 86 23        STX $23
C0/6139: A2 0F 00     LDX #$000F
C0/613C: A5 6F        LDA $6F
C0/613E: C9 08        CMP #$08
C0/6140: 90 56        BCC $6198
C0/6142: A4 06        LDY $06
C0/6144: BF 99 61 C0  LDA $C06199,X
C0/6148: 99 80 03     STA $0380,Y
C0/614B: 99 C0 03     STA $03C0,Y
C0/614E: A5 6F        LDA $6F
C0/6150: 38           SEC 
C0/6151: E9 08        SBC #$08
C0/6153: 0A           ASL 
C0/6154: 0A           ASL 
C0/6155: 18           CLC 
C0/6156: 7F B8 61 C0  ADC $C061B8,X
C0/615A: 99 81 03     STA $0381,Y
C0/615D: 18           CLC 
C0/615E: 69 10        ADC #$10
C0/6160: 99 C1 03     STA $03C1,Y
C0/6163: A9 40        LDA #$40
C0/6165: 99 82 03     STA $0382,Y
C0/6168: 1A           INC 
C0/6169: 1A           INC 
C0/616A: 99 C2 03     STA $03C2,Y
C0/616D: A9 38        LDA #$38
C0/616F: 99 83 03     STA $0383,Y
C0/6172: 99 C3 03     STA $03C3,Y
C0/6175: E8           INX 
C0/6176: C8           INY 
C0/6177: C8           INY 
C0/6178: C8           INY 
C0/6179: C8           INY 
C0/617A: C4 23        CPY $23
C0/617C: D0 C6        BNE $6144
C0/617E: A9 AA        LDA #$AA
C0/6180: 8D 18 04     STA $0418
C0/6183: 8D 19 04     STA $0419
C0/6186: 8D 1A 04     STA $041A
C0/6189: 8D 1B 04     STA $041B
C0/618C: 8D 1C 04     STA $041C
C0/618F: 8D 1D 04     STA $041D
C0/6192: 8D 1E 04     STA $041E
C0/6195: 8D 1F 04     STA $041F
C0/6198: 60           RTS 
C0/6199: 08           PHP 
C0/619A: 18           CLC 
C0/619B: 28           PLP 
C0/619C: 38           SEC 
C0/619D: 48           PHA 
C0/619E: 58           CLI 
C0/619F: 68           PLA 
C0/61A0: 78           SEI 
C0/61A1: 88           DEY 
C0/61A2: 98           TYA 
C0/61A3: A8           TAY 
C0/61A4: B8           CLV 
C0/61A5: C8           INY 
C0/61A6: D8           CLD 
C0/61A7: E8           INX 
C0/61A8: 00 10        BRK $10
C0/61AA: 20 30 40     JSR $4030
C0/61AD: 50 60        BVC $620F
C0/61AF: 70 80        BVS $6131
C0/61B1: 90 A0        BCC $6153
C0/61B3: B0 C0        BCS $6175
C0/61B5: D0 E0        BNE $6197
C0/61B7: F0 E3        BEQ $619C
C0/61B9: E2 E2        SEP #$E2
C0/61BB: E1 E1        SBC ($E1,X)
C0/61BD: E0 E0 E0     CPX #$E0E0
C0/61C0: E0 E0 E1     CPX #$E1E0
C0/61C3: E1 E2        SBC ($E2,X)
C0/61C5: E2 E3        SEP #$E3
C0/61C7: E3 E2        SBC $E2,S
C0/61C9: E2 E1        SEP #$E1
C0/61CB: E1 E0        SBC ($E0,X)
C0/61CD: E0 E0 E0     CPX #$E0E0
C0/61D0: E0 E0 E1     CPX #$E1E0
C0/61D3: E1 E2        SBC ($E2,X)
C0/61D5: E2 E3        SEP #$E3
C0/61D7: A9 00        LDA #$00
C0/61D9: 8D 05 21     STA $2105
C0/61DC: A6 06        LDX $06
C0/61DE: 86 26        STX $26
C0/61E0: 64 08        STZ $08
C0/61E2: A5 08        LDA $08
C0/61E4: 4A           LSR 
C0/61E5: 85 09        STA $09
C0/61E7: A9 40        LDA #$40
C0/61E9: 38           SEC 
C0/61EA: E5 09        SBC $09
C0/61EC: AA           TAX 
C0/61ED: 86 23        STX $23
C0/61EF: A5 08        LDA $08
C0/61F1: C2 20        REP #$20
C0/61F3: EB           XBA 
C0/61F4: 4A           LSR 
C0/61F5: 4A           LSR 
C0/61F6: 85 26        STA $26
C0/61F8: A5 06        LDA $06
C0/61FA: E2 20        SEP #$20
C0/61FC: A0 00 01     LDY #$0100
C0/61FF: A6 23        LDX $23
C0/6201: BF E0 FB CD  LDA $CDFBE0,X
C0/6205: E8           INX 
C0/6206: 86 23        STX $23
C0/6208: 8D 1B 21     STA $211B
C0/620B: 9C 1B 21     STZ $211B
C0/620E: A5 08        LDA $08
C0/6210: 8D 1C 21     STA $211C
C0/6213: 8D 1C 21     STA $211C
C0/6216: AD D6 0A     LDA $0AD6       ; map index
C0/6219: C9 03        CMP #$03
C0/621B: B0 17        BCS $6234
C0/621D: C2 20        REP #$20
C0/621F: AD 34 21     LDA $2134
C0/6222: 4A           LSR 
C0/6223: 4A           LSR 
C0/6224: 4A           LSR 
C0/6225: 4A           LSR 
C0/6226: 4A           LSR 
C0/6227: 18           CLC 
C0/6228: 69 00 01     ADC #$0100
C0/622B: A6 26        LDX $26
C0/622D: 9F 00 40 7F  STA $7F4000,X
C0/6231: 4C 49 62     JMP $6249
C0/6234: C2 20        REP #$20
C0/6236: AD 34 21     LDA $2134
C0/6239: 4A           LSR 
C0/623A: 4A           LSR 
C0/623B: 4A           LSR 
C0/623C: 4A           LSR 
C0/623D: 4A           LSR 
C0/623E: 4A           LSR 
C0/623F: 18           CLC 
C0/6240: 69 80 00     ADC #$0080
C0/6243: A6 26        LDX $26
C0/6245: 9F 00 40 7F  STA $7F4000,X
C0/6249: A5 06        LDA $06
C0/624B: E2 20        SEP #$20
C0/624D: E8           INX 
C0/624E: E8           INX 
C0/624F: 86 26        STX $26
C0/6251: 88           DEY 
C0/6252: D0 AB        BNE $61FF
C0/6254: A5 08        LDA $08
C0/6256: 18           CLC 
C0/6257: 69 08        ADC #$08
C0/6259: 85 08        STA $08
C0/625B: C9 80        CMP #$80
C0/625D: D0 83        BNE $61E2
C0/625F: A2 08 00     LDX #$0008
C0/6262: 86 26        STX $26
C0/6264: A6 06        LDX $06
C0/6266: 86 23        STX $23
C0/6268: DA           PHX 
C0/6269: A6 23        LDX $23
C0/626B: BF 40 D2 C0  LDA $C0D240,X
C0/626F: E8           INX 
C0/6270: 86 23        STX $23
C0/6272: FA           PLX 
C0/6273: 8D 1B 21     STA $211B
C0/6276: 9C 1B 21     STZ $211B
C0/6279: A5 26        LDA $26
C0/627B: 8D 1C 21     STA $211C
C0/627E: 8D 1C 21     STA $211C
C0/6281: C2 20        REP #$20
C0/6283: AD 34 21     LDA $2134
C0/6286: EB           XBA 
C0/6287: 29 FF 00     AND #$00FF
C0/628A: E2 20        SEP #$20
C0/628C: 18           CLC 
C0/628D: 69 E0        ADC #$E0
C0/628F: 9F 00 62 7F  STA $7F6200,X
C0/6293: E8           INX 
C0/6294: 8A           TXA 
C0/6295: D0 D1        BNE $6268
C0/6297: A0 00 00     LDY #$0000
C0/629A: 84 23        STY $23
C0/629C: A5 26        LDA $26
C0/629E: 18           CLC 
C0/629F: 69 08        ADC #$08
C0/62A1: 85 26        STA $26
C0/62A3: C2 20        REP #$20
C0/62A5: A5 26        LDA $26
C0/62A7: 38           SEC 
C0/62A8: E9 08 00     SBC #$0008
C0/62AB: 0A           ASL 
C0/62AC: 0A           ASL 
C0/62AD: 0A           ASL 
C0/62AE: 0A           ASL 
C0/62AF: 0A           ASL 
C0/62B0: AA           TAX 
C0/62B1: A5 06        LDA $06
C0/62B3: E2 20        SEP #$20
C0/62B5: A5 26        LDA $26
C0/62B7: C9 48        CMP #$48
C0/62B9: D0 AD        BNE $6268
C0/62BB: 60           RTS 
C0/62BC: A6 06        LDX $06
C0/62BE: A9 90        LDA #$90
C0/62C0: 9F 18 6A 7F  STA $7F6A18,X
C0/62C4: A9 49        LDA #$49
C0/62C6: 9F 19 6A 7F  STA $7F6A19,X
C0/62CA: A9 6A        LDA #$6A
C0/62CC: 9F 1A 6A 7F  STA $7F6A1A,X
C0/62D0: E8           INX 
C0/62D1: E8           INX 
C0/62D2: E8           INX 
C0/62D3: E0 2A 00     CPX #$002A
C0/62D6: D0 E6        BNE $62BE
C0/62D8: A9 00        LDA #$00
C0/62DA: 8F 42 6A 7F  STA $7F6A42
C0/62DE: A6 06        LDX $06
C0/62E0: A9 00        LDA #$00
C0/62E2: 9F 49 6A 7F  STA $7F6A49,X
C0/62E6: E8           INX 
C0/62E7: E0 10 00     CPX #$0010
C0/62EA: D0 F6        BNE $62E2
C0/62EC: 9C 0C 42     STZ $420C
C0/62EF: A9 40        LDA #$40
C0/62F1: 8D 70 43     STA $4370
C0/62F4: A9 00        LDA #$00
C0/62F6: A9 06        LDA #$06
C0/62F8: 8D 71 43     STA $4371
C0/62FB: A2 18 6A     LDX #$6A18
C0/62FE: 8E 72 43     STX $4372
C0/6301: A9 7F        LDA #$7F
C0/6303: 8D 74 43     STA $4374
C0/6306: 8D 77 43     STA $4377
C0/6309: 60           RTS 
C0/630A: 9C 1C 21     STZ $211C
C0/630D: 9C 1C 21     STZ $211C
C0/6310: 9C 1D 21     STZ $211D
C0/6313: 9C 1D 21     STZ $211D
C0/6316: A9 F0        LDA #$F0
C0/6318: 8F 00 6A 7F  STA $7F6A00
C0/631C: 8F 03 6A 7F  STA $7F6A03
C0/6320: A9 00        LDA #$00
C0/6322: 8F 06 6A 7F  STA $7F6A06
C0/6326: 9C 0C 42     STZ $420C
C0/6329: A9 42        LDA #$42
C0/632B: 8D 50 43     STA $4350
C0/632E: 8D 60 43     STA $4360
C0/6331: A9 1B        LDA #$1B
C0/6333: 8D 51 43     STA $4351
C0/6336: A9 1E        LDA #$1E
C0/6338: 8D 61 43     STA $4361
C0/633B: A2 00 6A     LDX #$6A00
C0/633E: 8E 52 43     STX $4352
C0/6341: 8E 62 43     STX $4362
C0/6344: A9 7F        LDA #$7F
C0/6346: 8D 54 43     STA $4354
C0/6349: 8D 64 43     STA $4364
C0/634C: 8D 57 43     STA $4357
C0/634F: 8D 67 43     STA $4367
C0/6352: A9 FF        LDA #$FF
C0/6354: 8F 0A 6A 7F  STA $7F6A0A
C0/6358: 8F 0D 6A 7F  STA $7F6A0D
C0/635C: A9 00        LDA #$00
C0/635E: 8F 10 6A 7F  STA $7F6A10
C0/6362: 9C 0C 42     STZ $420C
C0/6365: A9 40        LDA #$40
C0/6367: 8D 20 43     STA $4320
C0/636A: A9 32        LDA #$32
C0/636C: 8D 21 43     STA $4321
C0/636F: A2 07 6A     LDX #$6A07
C0/6372: 8E 22 43     STX $4322
C0/6375: A9 7F        LDA #$7F
C0/6377: 8D 24 43     STA $4324
C0/637A: 8D 27 43     STA $4327
C0/637D: 60           RTS 
C0/637E: A5 6F        LDA $6F
C0/6380: 0A           ASL 
C0/6381: 18           CLC 
C0/6382: 69 40        ADC #$40
C0/6384: 8F 02 6A 7F  STA $7F6A02
C0/6388: 8F 05 6A 7F  STA $7F6A05
C0/638C: A9 00        LDA #$00
C0/638E: 8F 01 6A 7F  STA $7F6A01
C0/6392: A9 E0        LDA #$E0
C0/6394: 8F 04 6A 7F  STA $7F6A04
C0/6398: A5 6F        LDA $6F
C0/639A: 38           SEC 
C0/639B: E9 08        SBC #$08
C0/639D: F0 2E        BEQ $63CD
C0/639F: 90 2C        BCC $63CD
C0/63A1: 48           PHA 
C0/63A2: 0A           ASL 
C0/63A3: 0A           ASL 
C0/63A4: 09 80        ORA #$80
C0/63A6: 8F 07 6A 7F  STA $7F6A07
C0/63AA: 68           PLA 
C0/63AB: C2 20        REP #$20
C0/63AD: EB           XBA 
C0/63AE: 18           CLC 
C0/63AF: 69 00 62     ADC #$6200
C0/63B2: 8F 08 6A 7F  STA $7F6A08
C0/63B6: 8F 0B 6A 7F  STA $7F6A0B
C0/63BA: 18           CLC 
C0/63BB: 69 80 00     ADC #$0080
C0/63BE: 8F 0E 6A 7F  STA $7F6A0E
C0/63C2: A5 06        LDA $06
C0/63C4: E2 20        SEP #$20
C0/63C6: A5 5E        LDA $5E
C0/63C8: 09 04        ORA #$04
C0/63CA: 85 5E        STA $5E
C0/63CC: 60           RTS 
C0/63CD: A5 5E        LDA $5E
C0/63CF: 29 FB        AND #$FB
C0/63D1: 85 5E        STA $5E
C0/63D3: 60           RTS 

C0/63D4: AD 20 11     LDA $1120
C0/63D7: 29 03        AND #$03
C0/63D9: AA           TAX 
C0/63DA: BF 61 64 C0  LDA $C06461,X
C0/63DE: A8           TAY 
C0/63DF: AD D8 0A     LDA $0AD8
C0/63E2: C0 00 00     CPY #$0000
C0/63E5: F0 04        BEQ $63EB
C0/63E7: 0A           ASL 
C0/63E8: 88           DEY 
C0/63E9: 80 F7        BRA $63E2
C0/63EB: 4A           LSR 
C0/63EC: 38           SEC 
C0/63ED: ED 1F 11     SBC $111F
C0/63F0: 29 3F        AND #$3F
C0/63F2: 85 77        STA $77
C0/63F4: AD 20 11     LDA $1120
C0/63F7: 4A           LSR 
C0/63F8: 4A           LSR 
C0/63F9: 29 03        AND #$03
C0/63FB: AA           TAX 
C0/63FC: BF 61 64 C0  LDA $C06461,X
C0/6400: A8           TAY 
C0/6401: AD D9 0A     LDA $0AD9
C0/6404: C0 00 00     CPY #$0000
C0/6407: F0 04        BEQ $640D
C0/6409: 0A           ASL 
C0/640A: 88           DEY 
C0/640B: 80 F7        BRA $6404
C0/640D: 4A           LSR 
C0/640E: 38           SEC 
C0/640F: ED 1E 11     SBC $111E
C0/6412: 29 3F        AND #$3F
C0/6414: 85 78        STA $78
C0/6416: AD 20 11     LDA $1120
C0/6419: 4A           LSR 
C0/641A: 4A           LSR 
C0/641B: 4A           LSR 
C0/641C: 4A           LSR 
C0/641D: 29 03        AND #$03
C0/641F: AA           TAX 
C0/6420: BF 61 64 C0  LDA $C06461,X
C0/6424: A8           TAY 
C0/6425: AD D8 0A     LDA $0AD8
C0/6428: C0 00 00     CPY #$0000
C0/642B: F0 04        BEQ $6431
C0/642D: 0A           ASL 
C0/642E: 88           DEY 
C0/642F: 80 F7        BRA $6428
C0/6431: 4A           LSR 
C0/6432: 38           SEC 
C0/6433: ED 1D 11     SBC $111D
C0/6436: 29 3F        AND #$3F
C0/6438: 85 79        STA $79
C0/643A: AD 20 11     LDA $1120
C0/643D: 4A           LSR 
C0/643E: 4A           LSR 
C0/643F: 4A           LSR 
C0/6440: 4A           LSR 
C0/6441: 4A           LSR 
C0/6442: 4A           LSR 
C0/6443: 29 03        AND #$03
C0/6445: AA           TAX 
C0/6446: BF 61 64 C0  LDA $C06461,X
C0/644A: A8           TAY 
C0/644B: AD D9 0A     LDA $0AD9
C0/644E: C0 00 00     CPY #$0000
C0/6451: F0 04        BEQ $6457
C0/6453: 0A           ASL 
C0/6454: 88           DEY 
C0/6455: 80 F7        BRA $644E
C0/6457: 4A           LSR 
C0/6458: 38           SEC 
C0/6459: ED 1C 11     SBC $111C
C0/645C: 29 3F        AND #$3F
C0/645E: 85 7A        STA $7A
C0/6460: 60           RTS 

; parallax multipliers
C0/6461: 01 00 02 01

C0/6465: 9C 15 21     STZ $2115
C0/6468: 20 E9 6D     JSR $6DE9
C0/646B: 9C 00 43     STZ $4300
C0/646E: A6 7F        LDX $7F
C0/6470: 8E 16 21     STX $2116
C0/6473: A2 F3 16     LDX #$16F3
C0/6476: 8E 02 43     STX $4302
C0/6479: A6 7B        LDX $7B
C0/647B: 8E 05 43     STX $4305
C0/647E: A9 01        LDA #$01
C0/6480: 8D 0B 42     STA $420B
C0/6483: A6 81        LDX $81
C0/6485: 8E 16 21     STX $2116
C0/6488: A6 7D        LDX $7D
C0/648A: F0 08        BEQ $6494
C0/648C: 8E 05 43     STX $4305
C0/648F: A9 01        LDA #$01
C0/6491: 8D 0B 42     STA $420B
C0/6494: A6 83        LDX $83
C0/6496: 8E 16 21     STX $2116
C0/6499: A2 73 17     LDX #$1773
C0/649C: 8E 02 43     STX $4302
C0/649F: A6 7B        LDX $7B
C0/64A1: 8E 05 43     STX $4305
C0/64A4: A9 01        LDA #$01
C0/64A6: 8D 0B 42     STA $420B
C0/64A9: A6 85        LDX $85
C0/64AB: 8E 16 21     STX $2116
C0/64AE: A6 7D        LDX $7D
C0/64B0: F0 08        BEQ $64BA
C0/64B2: 8E 05 43     STX $4305
C0/64B5: A9 01        LDA #$01
C0/64B7: 8D 0B 42     STA $420B
C0/64BA: 60           RTS 

C0/64BB: A9 03        LDA #$03
C0/64BD: 8D 15 21     STA $2115
C0/64C0: 20 E9 6D     JSR $6DE9
C0/64C3: 9C 00 43     STZ $4300
C0/64C6: A6 7F        LDX $7F
C0/64C8: 8E 16 21     STX $2116
C0/64CB: A2 F3 16     LDX #$16F3
C0/64CE: 8E 02 43     STX $4302
C0/64D1: A6 7B        LDX $7B
C0/64D3: 8E 05 43     STX $4305
C0/64D6: A9 01        LDA #$01
C0/64D8: 8D 0B 42     STA $420B
C0/64DB: A6 81        LDX $81
C0/64DD: 8E 16 21     STX $2116
C0/64E0: A6 7D        LDX $7D
C0/64E2: F0 08        BEQ $64EC
C0/64E4: 8E 05 43     STX $4305
C0/64E7: A9 01        LDA #$01
C0/64E9: 8D 0B 42     STA $420B
C0/64EC: A6 83        LDX $83
C0/64EE: 8E 16 21     STX $2116
C0/64F1: A2 73 17     LDX #$1773
C0/64F4: 8E 02 43     STX $4302
C0/64F7: A6 7B        LDX $7B
C0/64F9: 8E 05 43     STX $4305
C0/64FC: A9 01        LDA #$01
C0/64FE: 8D 0B 42     STA $420B
C0/6501: A6 85        LDX $85
C0/6503: 8E 16 21     STX $2116
C0/6506: A6 7D        LDX $7D
C0/6508: F0 08        BEQ $6512
C0/650A: 8E 05 43     STX $4305
C0/650D: A9 01        LDA #$01
C0/650F: 8D 0B 42     STA $420B
C0/6512: 60           RTS 

; [  ]

C0/6513: A5 BA        LDA $BA
C0/6515: D0 01        BNE $6518
C0/6517: 60           RTS 
C0/6518: 29 01        AND #$01
C0/651A: F0 04        BEQ $6520
C0/651C: 5C A3 65 C0  JML $C065A3
C0/6520: A5 BA        LDA $BA
C0/6522: 29 02        AND #$02
C0/6524: F0 09        BEQ $652F
C0/6526: A5 75        LDA $75
C0/6528: 18           CLC 
C0/6529: 69 21        ADC #$21
C0/652B: 85 23        STA $23
C0/652D: 80 07        BRA $6536
C0/652F: A5 75        LDA $75
C0/6531: 38           SEC 
C0/6532: E9 1F        SBC #$1F
C0/6534: 85 23        STA $23
C0/6536: A5 76        LDA $76
C0/6538: 38           SEC 
C0/6539: E9 1F        SBC #$1F
C0/653B: 29 3F        AND #$3F
C0/653D: 85 24        STA $24
C0/653F: A6 23        LDX $23
C0/6541: 86 26        STX $26
C0/6543: A0 00 00     LDY #$0000
C0/6546: A6 23        LDX $23
C0/6548: BF 00 00 7F  LDA $7F0000,X
C0/654C: AA           TAX 
C0/654D: BF 22 6E 7F  LDA $7F6E22,X
C0/6551: 99 F3 16     STA $16F3,Y
C0/6554: BF A2 6F 7F  LDA $7F6FA2,X
C0/6558: 99 F4 16     STA $16F4,Y
C0/655B: BF E2 6E 7F  LDA $7F6EE2,X
C0/655F: 99 73 17     STA $1773,Y
C0/6562: BF 62 70 7F  LDA $7F7062,X
C0/6566: 99 74 17     STA $1774,Y
C0/6569: A5 24        LDA $24
C0/656B: 1A           INC 
C0/656C: 29 3F        AND #$3F
C0/656E: 85 24        STA $24
C0/6570: C8           INY 
C0/6571: C8           INY 
C0/6572: C0 80 00     CPY #$0080
C0/6575: D0 CF        BNE $6546
C0/6577: 64 7E        STZ $7E
C0/6579: 64 7C        STZ $7C
C0/657B: 64 82        STZ $82
C0/657D: 64 86        STZ $86
C0/657F: A5 26        LDA $26
C0/6581: 0A           ASL 
C0/6582: 29 7F        AND #$7F
C0/6584: 85 7F        STA $7F
C0/6586: 85 81        STA $81
C0/6588: 1A           INC 
C0/6589: 85 83        STA $83
C0/658B: 85 85        STA $85
C0/658D: A5 76        LDA $76
C0/658F: 38           SEC 
C0/6590: E9 1F        SBC #$1F
C0/6592: 29 3F        AND #$3F
C0/6594: 85 80        STA $80
C0/6596: 85 84        STA $84
C0/6598: 0A           ASL 
C0/6599: 85 7D        STA $7D
C0/659B: A9 80        LDA #$80
C0/659D: 38           SEC 
C0/659E: E5 7D        SBC $7D
C0/65A0: 85 7B        STA $7B
C0/65A2: 60           RTS 

C0/65A3: A5 BA        LDA $BA
C0/65A5: 29 02        AND #$02
C0/65A7: D0 0D        BNE $65B6
C0/65A9: A5 76        LDA $76
C0/65AB: 38           SEC 
C0/65AC: E9 1F        SBC #$1F
C0/65AE: 85 08        STA $08
C0/65B0: 29 3F        AND #$3F
C0/65B2: 85 24        STA $24
C0/65B4: 80 0B        BRA $65C1
C0/65B6: A5 76        LDA $76
C0/65B8: 18           CLC 
C0/65B9: 69 20        ADC #$20
C0/65BB: 85 08        STA $08
C0/65BD: 29 3F        AND #$3F
C0/65BF: 85 24        STA $24
C0/65C1: A5 75        LDA $75
C0/65C3: 38           SEC 
C0/65C4: E9 1F        SBC #$1F
C0/65C6: 85 23        STA $23
C0/65C8: A6 23        LDX $23
C0/65CA: 86 26        STX $26
C0/65CC: A0 00 00     LDY #$0000
C0/65CF: A6 23        LDX $23
C0/65D1: BF 00 00 7F  LDA $7F0000,X
C0/65D5: AA           TAX 
C0/65D6: BF 22 6E 7F  LDA $7F6E22,X
C0/65DA: 99 F3 16     STA $16F3,Y
C0/65DD: BF E2 6E 7F  LDA $7F6EE2,X
C0/65E1: 99 F4 16     STA $16F4,Y
C0/65E4: BF A2 6F 7F  LDA $7F6FA2,X
C0/65E8: 99 73 17     STA $1773,Y
C0/65EB: BF 62 70 7F  LDA $7F7062,X
C0/65EF: 99 74 17     STA $1774,Y
C0/65F2: C8           INY 
C0/65F3: C8           INY 
C0/65F4: E6 23        INC $23
C0/65F6: C0 80 00     CPY #$0080
C0/65F9: D0 D4        BNE $65CF
C0/65FB: 64 7D        STZ $7D
C0/65FD: 64 7E        STZ $7E
C0/65FF: A9 80        LDA #$80
C0/6601: 85 7B        STA $7B
C0/6603: 64 7C        STZ $7C
C0/6605: 64 81        STZ $81
C0/6607: A9 80        LDA #$80
C0/6609: 85 85        STA $85
C0/660B: A5 08        LDA $08
C0/660D: 29 3F        AND #$3F
C0/660F: 85 80        STA $80
C0/6611: 85 82        STA $82
C0/6613: 85 84        STA $84
C0/6615: 85 86        STA $86
C0/6617: A5 75        LDA $75
C0/6619: 38           SEC 
C0/661A: E9 1F        SBC #$1F
C0/661C: 29 3F        AND #$3F
C0/661E: 0A           ASL 
C0/661F: 85 7F        STA $7F
C0/6621: 18           CLC 
C0/6622: 69 80        ADC #$80
C0/6624: 85 83        STA $83
C0/6626: A5 7F        LDA $7F
C0/6628: 85 7D        STA $7D
C0/662A: A9 80        LDA #$80
C0/662C: 38           SEC 
C0/662D: E5 7D        SBC $7D
C0/662F: 85 7B        STA $7B
C0/6631: 60           RTS 

; [ show mini-map ]

C0/6632: 20 81 60     JSR $6081       ; fade out
C0/6635: 20 E8 4C     JSR $4CE8       ; disable interrupts
C0/6638: 64 5E        STZ $5E
C0/663A: A9 07        LDA #$07
C0/663C: 8D 05 21     STA $2105
C0/663F: A9 80        LDA #$80
C0/6641: 8D 1A 21     STA $211A
C0/6644: A9 00        LDA #$00
C0/6646: 8D 1B 21     STA $211B
C0/6649: A9 08        LDA #$08
C0/664B: 8D 1B 21     STA $211B
C0/664E: A9 00        LDA #$00
C0/6650: 8D 1E 21     STA $211E
C0/6653: A9 08        LDA #$08
C0/6655: 8D 1E 21     STA $211E
C0/6658: A9 C0        LDA #$C0
C0/665A: 8D 0D 21     STA $210D
C0/665D: A9 FF        LDA #$FF
C0/665F: 8D 0D 21     STA $210D
C0/6662: A9 D0        LDA #$D0
C0/6664: 8D 0E 21     STA $210E
C0/6667: A9 FF        LDA #$FF
C0/6669: 8D 0E 21     STA $210E
C0/666C: A9 01        LDA #$01
C0/666E: 8D 1F 21     STA $211F
C0/6671: A9 00        LDA #$00
C0/6673: 8D 1F 21     STA $211F
C0/6676: 8D 20 21     STA $2120
C0/6679: 8D 20 21     STA $2120
C0/667C: A9 11        LDA #$11
C0/667E: 8D 2C 21     STA $212C
C0/6681: A9 E0        LDA #$E0
C0/6683: 8D 32 21     STA $2132
C0/6686: 9C 15 21     STZ $2115
C0/6689: A6 06        LDX $06
C0/668B: 8E 16 21     STX $2116
C0/668E: 86 0D        STX $0D
C0/6690: A9 1F        LDA #$1F
C0/6692: 85 76        STA $76
C0/6694: 64 BA        STZ $BA
C0/6696: 20 A1 69     JSR $69A1
C0/6699: A4 06        LDY $06
C0/669B: A6 26        LDX $26
C0/669D: BF 00 00 7F  LDA $7F0000,X
C0/66A1: AA           TAX 
C0/66A2: BF A2 6F 7F  LDA $7F6FA2,X
C0/66A6: 8D 18 21     STA $2118
C0/66A9: A6 26        LDX $26
C0/66AB: E8           INX 
C0/66AC: E8           INX 
C0/66AD: 86 26        STX $26
C0/66AF: C8           INY 
C0/66B0: C8           INY 
C0/66B1: C0 00 01     CPY #$0100
C0/66B4: D0 E5        BNE $669B
C0/66B6: C2 20        REP #$20
C0/66B8: A5 26        LDA $26
C0/66BA: 18           CLC 
C0/66BB: 69 00 01     ADC #$0100
C0/66BE: 29 FF 3F     AND #$3FFF
C0/66C1: 85 26        STA $26
C0/66C3: A5 06        LDA $06
C0/66C5: E2 20        SEP #$20
C0/66C7: E6 76        INC $76
C0/66C9: E6 76        INC $76
C0/66CB: A5 76        LDA $76
C0/66CD: C9 1F        CMP #$1F
C0/66CF: D0 C5        BNE $6696
C0/66D1: 20 95 4C     JSR $4C95       ; clear sprite data
C0/66D4: 20 F8 56     JSR $56F8
C0/66D7: 20 31 68     JSR $6831
C0/66DA: A9 CF        LDA #$CF
C0/66DC: 85 25        STA $25
C0/66DE: A2 00 D8     LDX #$D800
C0/66E1: 86 23        STX $23
C0/66E3: A2 00 70     LDX #$7000
C0/66E6: 86 2E        STX $2E
C0/66E8: A2 00 04     LDX #$0400
C0/66EB: 86 2C        STX $2C
C0/66ED: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/66F0: A9 01        LDA #$01
C0/66F2: 85 52        STA $52
C0/66F4: 64 3F        STZ $3F
C0/66F6: 20 00 61     JSR $6100       ; fade in
C0/66F9: 20 41 4E     JSR $4E41       ; wait for vblank
C0/66FC: 20 31 67     JSR $6731
C0/66FF: 20 55 67     JSR $6755
C0/6702: 20 EC 67     JSR $67EC
C0/6705: 20 9C 67     JSR $679C
C0/6708: A5 02        LDA $02
C0/670A: 29 CF        AND #$CF
C0/670C: D0 EB        BNE $66F9
C0/670E: A5 03        LDA $03
C0/6710: D0 E7        BNE $66F9
C0/6712: 20 41 4E     JSR $4E41       ; wait for vblank
C0/6715: 20 31 67     JSR $6731
C0/6718: 20 55 67     JSR $6755
C0/671B: 20 EC 67     JSR $67EC
C0/671E: 20 9C 67     JSR $679C
C0/6721: A5 02        LDA $02
C0/6723: 29 CF        AND #$CF
C0/6725: D0 04        BNE $672B
C0/6727: A5 03        LDA $03
C0/6729: F0 E7        BEQ $6712
C0/672B: 20 81 60     JSR $6081       ; fade out
C0/672E: 64 52        STZ $52
C0/6730: 60           RTS 

C0/6731: AD D8 0A     LDA $0AD8
C0/6734: 4A           LSR 
C0/6735: 18           CLC 
C0/6736: 69 3E        ADC #$3E
C0/6738: 8D 00 02     STA $0200
C0/673B: AD D9 0A     LDA $0AD9
C0/673E: 4A           LSR 
C0/673F: 18           CLC 
C0/6740: 69 2D        ADC #$2D
C0/6742: 8D 01 02     STA $0201
C0/6745: A9 49        LDA #$49
C0/6747: 8D 02 02     STA $0202
C0/674A: A5 3F        LDA $3F
C0/674C: 29 10        AND #$10
C0/674E: 0A           ASL 
C0/674F: 09 06        ORA #$06
C0/6751: 8D 03 02     STA $0203
C0/6754: 60           RTS 
C0/6755: A9 F8        LDA #$F8
C0/6757: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/675A: C9 00        CMP #$00
C0/675C: F0 3D        BEQ $679B
C0/675E: A5 3F        LDA $3F
C0/6760: 4A           LSR 
C0/6761: 29 0E        AND #$0E
C0/6763: AA           TAX 
C0/6764: A4 06        LDY $06
C0/6766: BF 61 69 C0  LDA $C06961,X
C0/676A: 99 04 02     STA $0204,Y
C0/676D: BF 62 69 C0  LDA $C06962,X
C0/6771: 99 05 02     STA $0205,Y
C0/6774: A5 3F        LDA $3F
C0/6776: 4A           LSR 
C0/6777: 29 01        AND #$01
C0/6779: 18           CLC 
C0/677A: 69 4A        ADC #$4A
C0/677C: 99 06 02     STA $0206,Y
C0/677F: A9 36        LDA #$36
C0/6781: 99 07 02     STA $0207,Y
C0/6784: C2 20        REP #$20
C0/6786: 8A           TXA 
C0/6787: 18           CLC 
C0/6788: 69 10 00     ADC #$0010
C0/678B: AA           TAX 
C0/678C: 98           TYA 
C0/678D: 18           CLC 
C0/678E: 69 04 00     ADC #$0004
C0/6791: A8           TAY 
C0/6792: A5 06        LDA $06
C0/6794: E2 20        SEP #$20
C0/6796: C0 10 00     CPY #$0010
C0/6799: D0 CB        BNE $6766
C0/679B: 60           RTS 
C0/679C: A4 06        LDY $06
C0/679E: B9 DE 0A     LDA $0ADE,Y
C0/67A1: 30 37        BMI $67DA
C0/67A3: B9 DD 0A     LDA $0ADD,Y
C0/67A6: 4A           LSR 
C0/67A7: 4A           LSR 
C0/67A8: 4A           LSR 
C0/67A9: 4A           LSR 
C0/67AA: 4A           LSR 
C0/67AB: CD D6 0A     CMP $0AD6       ; map index
C0/67AE: D0 2A        BNE $67DA
C0/67B0: B9 DF 0A     LDA $0ADF,Y
C0/67B3: 4A           LSR 
C0/67B4: 18           CLC 
C0/67B5: 69 3C        ADC #$3C
C0/67B7: 99 F4 02     STA $02F4,Y
C0/67BA: B9 E0 0A     LDA $0AE0,Y
C0/67BD: 4A           LSR 
C0/67BE: 18           CLC 
C0/67BF: 69 2C        ADC #$2C
C0/67C1: 99 F5 02     STA $02F5,Y
C0/67C4: 98           TYA 
C0/67C5: 4A           LSR 
C0/67C6: 4A           LSR 
C0/67C7: AA           TAX 
C0/67C8: BF E9 67 C0  LDA $C067E9,X
C0/67CC: 99 F6 02     STA $02F6,Y
C0/67CF: A5 3F        LDA $3F
C0/67D1: 29 10        AND #$10
C0/67D3: 09 05        ORA #$05
C0/67D5: 99 F7 02     STA $02F7,Y
C0/67D8: 80 05        BRA $67DF
C0/67DA: A9 F8        LDA #$F8
C0/67DC: 99 F5 02     STA $02F5,Y
C0/67DF: C8           INY 
C0/67E0: C8           INY 
C0/67E1: C8           INY 
C0/67E2: C8           INY 
C0/67E3: C0 0C 00     CPY #$000C
C0/67E6: D0 B6        BNE $679E
C0/67E8: 60           RTS 
C0/67E9: 0E 0F 1E     ASL $1E0F
C0/67EC: AD D6 0A     LDA $0AD6       ; map index
C0/67EF: 0A           ASL 
C0/67F0: AA           TAX 
C0/67F1: C2 20        REP #$20
C0/67F3: BF EB 68 C0  LDA $C068EB,X
C0/67F7: 38           SEC 
C0/67F8: FF E9 68 C0  SBC $C068E9,X
C0/67FC: 4A           LSR 
C0/67FD: 85 2C        STA $2C
C0/67FF: BF E9 68 C0  LDA $C068E9,X
C0/6803: AA           TAX 
C0/6804: A5 06        LDA $06
C0/6806: E2 20        SEP #$20
C0/6808: A4 06        LDY $06
C0/680A: BF F5 68 C0  LDA $C068F5,X
C0/680E: 99 00 03     STA $0300,Y
C0/6811: BF F6 68 C0  LDA $C068F6,X
C0/6815: 99 01 03     STA $0301,Y
C0/6818: A9 4A        LDA #$4A
C0/681A: 99 02 03     STA $0302,Y
C0/681D: A5 3F        LDA $3F
C0/681F: 29 20        AND #$20
C0/6821: 09 06        ORA #$06
C0/6823: 99 03 03     STA $0303,Y
C0/6826: C8           INY 
C0/6827: C8           INY 
C0/6828: C8           INY 
C0/6829: C8           INY 
C0/682A: E8           INX 
C0/682B: E8           INX 
C0/682C: C6 2C        DEC $2C
C0/682E: D0 DA        BNE $680A
C0/6830: 60           RTS 
C0/6831: A9 0A        LDA #$0A
C0/6833: 85 DF        STA $DF
C0/6835: A9 0B        LDA #$0B
C0/6837: 85 E0        STA $E0
C0/6839: 20 AE BA     JSR $BAAE       ; change color palette
C0/683C: A6 06        LDX $06
C0/683E: BF 59 68 C0  LDA $C06859,X
C0/6842: 9D 60 03     STA $0360,X
C0/6845: E8           INX 
C0/6846: E0 90 00     CPX #$0090
C0/6849: D0 F3        BNE $683E
C0/684B: A6 06        LDX $06
C0/684D: A9 AA        LDA #$AA
C0/684F: 9D 16 04     STA $0416,X
C0/6852: E8           INX 
C0/6853: E0 0A 00     CPX #$000A
C0/6856: D0 F5        BNE $684D
C0/6858: 60           RTS 
C0/6859: 31 1F        AND ($1F),Y
C0/685B: 00 35        BRK $35
C0/685D: 41 1F        EOR ($1F,X)
C0/685F: 02 35        COP $35
C0/6861: 51 1F        EOR ($1F),Y
C0/6863: 04 35        TSB $35
C0/6865: 61 1F        ADC ($1F,X)
C0/6867: 06 35        ASL $35
C0/6869: 71 1F        ADC ($1F),Y
C0/686B: 04 35        TSB $35
C0/686D: 81 1F        STA ($1F,X)
C0/686F: 04 75        TSB $75
C0/6871: 91 1F        STA ($1F),Y
C0/6873: 06 75        ASL $75
C0/6875: A1 1F        LDA ($1F,X)
C0/6877: 04 75        TSB $75
C0/6879: B1 1F        LDA ($1F),Y
C0/687B: 02 75        COP $75
C0/687D: C1 1F        CMP ($1F,X)
C0/687F: 00 75        BRK $75
C0/6881: 31 2F        AND ($2F),Y
C0/6883: 08           PHP 
C0/6884: 35 C1        AND $C1,X
C0/6886: 2F 08 75 31  AND $317508
C0/688A: 3F 0A 35 C1  AND $C1350A,X
C0/688E: 3F 0A 75 31  AND $31750A,X
C0/6892: 4F 0C 35 C1  EOR $C1350C
C0/6896: 4F 0C 75 31  EOR $31750C
C0/689A: 5F 0A 35 C1  EOR $C1350A,X
C0/689E: 5F 0A 75 31  EOR $31750A,X
C0/68A2: 6F 0A B5 C1  ADC $C1B50A
C0/68A6: 6F 0A F5 31  ADC $31F50A
C0/68AA: 7F 0C B5 C1  ADC $C1B50C,X
C0/68AE: 7F 0C F5 31  ADC $31F50C,X
C0/68B2: 8F 0A B5 C1  STA $C1B50A
C0/68B6: 8F 0A F5 31  STA $31F50A
C0/68BA: 9F 08 B5 C1  STA $C1B508,X
C0/68BE: 9F 08 F5 31  STA $31F508,X
C0/68C2: AF 00 B5 41  LDA $41B500
C0/68C6: AF 02 B5 51  LDA $51B502
C0/68CA: AF 04 B5 61  LDA $61B504
C0/68CE: AF 06 B5 71  LDA $71B506
C0/68D2: AF 04 B5 81  LDA $81B504
C0/68D6: AF 04 F5 91  LDA $91F504
C0/68DA: AF 06 F5 A1  LDA $A1F506
C0/68DE: AF 04 F5 B1  LDA $B1F504
C0/68E2: AF 02 F5 C1  LDA $C1F502
C0/68E6: AF 00 F5 00  LDA $00F500
C0/68EA: 00 20        BRK $20
C0/68EC: 00 32        BRK $32
C0/68EE: 00 5E        BRK $5E
C0/68F0: 00 64        BRK $64
C0/68F2: 00 6C        BRK $6C
C0/68F4: 00 51        BRK $51
C0/68F6: 43 5D        EOR $5D,S
C0/68F8: 91 60        STA ($60),Y
C0/68FA: 80 67        BRA $6963
C0/68FC: 6A           ROR 
C0/68FD: 6A           ROR 
C0/68FE: 55 81        EOR $81,X
C0/6900: 5B           TCD 
C0/6901: 97 46        STA [$46],Y
C0/6903: 9B           TXY 
C0/6904: 49 9B        EOR #$9B
C0/6906: 71 AA        ADC ($AA),Y
C0/6908: 69 A2        ADC #$A2
C0/690A: 5B           TCD 
C0/690B: AD 55 A9     LDA $A955
C0/690E: 46 AD        LSR $AD
C0/6910: 93 92        STA ($92,S),Y
C0/6912: 68           PLA 
C0/6913: B1 42        LDA ($42),Y
C0/6915: 66 66        ROR $66
C0/6917: 4B           PHA 
C0/6918: 68           PLA 
C0/6919: 68           PLA 
C0/691A: 72 69        ADC ($69)
C0/691C: 78           SEI 
C0/691D: 6A           ROR 
C0/691E: 86 90        STX $90
C0/6920: 7C 78 61     JMP ($6178,X)
C0/6923: 8A           TXA 
C0/6924: 58           CLI 
C0/6925: 8F 4A 5D 91  STA $915D4A
C0/6929: 67 6A        ADC [$6A]
C0/692B: 6A           ROR 
C0/692C: 55 81        EOR $81,X
C0/692E: 5B           TCD 
C0/692F: 9B           TXY 
C0/6930: 49 9B        EOR #$9B
C0/6932: 71 AD        ADC ($AD),Y
C0/6934: 55 AD        EOR $AD,X
C0/6936: 93 92        STA ($92,S),Y
C0/6938: 68           PLA 
C0/6939: 66 66        ROR $66
C0/693B: 4B           PHA 
C0/693C: 68           PLA 
C0/693D: 68           PLA 
C0/693E: 72 69        ADC ($69)
C0/6940: 78           SEI 
C0/6941: 6A           ROR 
C0/6942: 86 78        STX $78
C0/6944: 61 8A        ADC ($8A,X)
C0/6946: 58           CLI 
C0/6947: 8F 4A A7 93  STA $93A74A
C0/694B: 82 7C 56     BRL $BFCA
C0/694E: 6C 9D 5B     JMP ($5B9D)
C0/6951: B1 42        LDA ($42),Y
C0/6953: 5C 4F 78 61  JML $61784F
C0/6957: 4D 68 5C     EOR $5C68
C0/695A: 4F A2 5B B4  EOR $B45BA2
C0/695E: 82 4D 68     BRL $D1AE
C0/6961: 7C 5C 7E     JMP ($7E5C,X)
C0/6964: 5D 7F 5F     EOR $5F7F,X
C0/6967: 81 60        STA ($60,X)
C0/6969: 82 62 84     BRL $EDCE
C0/696C: 63 85        ADC $85,S
C0/696E: 65 87        ADC $87
C0/6970: 66 97        ROR $97
C0/6972: 76 95        ROR $95,X
C0/6974: 74 93        STZ $93,X
C0/6976: 72 92        ADC ($92)
C0/6978: 70 90        BVS $690A
C0/697A: 6F 8E 6D 8C  ADC $8C6D8E
C0/697E: 6B           RTL 
C0/697F: 8A           TXA 
C0/6980: 6A           ROR 
C0/6981: 5F 7E 64 7C  EOR $7C647E,X
C0/6985: 69 79        ADC #$79
C0/6987: 6E 76 74     ROR $7476
C0/698A: 73 79        ADC ($79,S),Y
C0/698C: 70 7E        BVS $6A0C
C0/698E: 6E 83 6B     ROR $6B83
C0/6991: A6 58        LDX $58
C0/6993: A2 5A 9E     LDX #$9E5A
C0/6996: 5C 9B 5E 97  JML $975E9B
C0/699A: 60           RTS 
C0/699B: 93 62        STA ($62,S),Y
C0/699D: 90 64        BCC $6A03
C0/699F: 8C 66

; [ load world map layout ]

C0/69A1: A9 C7        LDA #$C7
C0/69A3: 85 25        STA $25
C0/69A5: A5 BA        LDA $BA
C0/69A7: 29 02        AND #$02
C0/69A9: D0 07        BNE $69B2
C0/69AB: A5 76        LDA $76
C0/69AD: 38           SEC 
C0/69AE: E9 1F        SBC #$1F
C0/69B0: 80 05        BRA $69B7
C0/69B2: A5 76        LDA $76
C0/69B4: 18           CLC 
C0/69B5: 69 20        ADC #$20
C0/69B7: 85 0F        STA $0F
C0/69B9: C2 20        REP #$20
C0/69BB: 85 23        STA $23
C0/69BD: 06 23        ASL $23
C0/69BF: EB           XBA 
C0/69C0: 29 00 3F     AND #$3F00
C0/69C3: 85 26        STA $26
C0/69C5: AD D6 0A     LDA $0AD6       ; map index
C0/69C8: EB           XBA 
C0/69C9: 0A           ASL 
C0/69CA: 18           CLC 
C0/69CB: 65 23        ADC $23
C0/69CD: AA           TAX 
C0/69CE: BF 00 E0 CF  LDA $CFE000,X   ; pointer to world layout
C0/69D2: 85 23        STA $23
C0/69D4: E0 00 08     CPX #$0800
C0/69D7: 90 0B        BCC $69E4
C0/69D9: BF 00 E0 CF  LDA $CFE000,X
C0/69DD: C9 00 80     CMP #$8000
C0/69E0: B0 02        BCS $69E4
C0/69E2: E6 25        INC $25
C0/69E4: A5 06        LDA $06
C0/69E6: E2 20        SEP #$20
C0/69E8: A6 06        LDX $06
C0/69EA: 9B           TXY 
C0/69EB: B7 23        LDA [$23],Y
C0/69ED: 9F 22 76 7F  STA $7F7622,X
C0/69F1: C8           INY 
C0/69F2: E8           INX 
C0/69F3: E0 00 01     CPX #$0100
C0/69F6: D0 F3        BNE $69EB
C0/69F8: A6 06        LDX $06
C0/69FA: 86 23        STX $23
C0/69FC: A4 26        LDY $26
C0/69FE: A6 23        LDX $23
C0/6A00: BF 22 76 7F  LDA $7F7622,X
C0/6A04: C9 C0        CMP #$C0
C0/6A06: B0 2E        BCS $6A36
C0/6A08: C9 0C        CMP #$0C
C0/6A0A: F0 13        BEQ $6A1F
C0/6A0C: C9 1C        CMP #$1C
C0/6A0E: F0 0F        BEQ $6A1F
C0/6A10: C9 2C        CMP #$2C
C0/6A12: F0 0B        BEQ $6A1F
C0/6A14: E8           INX 
C0/6A15: 86 23        STX $23
C0/6A17: BB           TYX 
C0/6A18: 9F 00 00 7F  STA $7F0000,X
C0/6A1C: C8           INY 
C0/6A1D: 80 2F        BRA $6A4E
C0/6A1F: E8           INX 
C0/6A20: 86 23        STX $23
C0/6A22: BB           TYX 
C0/6A23: 9F 00 00 7F  STA $7F0000,X
C0/6A27: 1A           INC 
C0/6A28: 9F 01 00 7F  STA $7F0001,X
C0/6A2C: 1A           INC 
C0/6A2D: 9F 02 00 7F  STA $7F0002,X
C0/6A31: C8           INY 
C0/6A32: C8           INY 
C0/6A33: C8           INY 
C0/6A34: 80 18        BRA $6A4E
C0/6A36: 38           SEC 
C0/6A37: E9 C0        SBC #$C0
C0/6A39: 85 09        STA $09
C0/6A3B: BF 23 76 7F  LDA $7F7623,X
C0/6A3F: E8           INX 
C0/6A40: E8           INX 
C0/6A41: 86 23        STX $23
C0/6A43: BB           TYX 
C0/6A44: 9F 00 00 7F  STA $7F0000,X
C0/6A48: E8           INX 
C0/6A49: C6 09        DEC $09
C0/6A4B: 10 F7        BPL $6A44
C0/6A4D: 9B           TXY 
C0/6A4E: 98           TYA 
C0/6A4F: D0 AD        BNE $69FE
C0/6A51: C2 20        REP #$20
C0/6A53: AD D6 0A     LDA $0AD6       ; map index
C0/6A56: 0A           ASL 
C0/6A57: AA           TAX 
C0/6A58: BF BF 6A C0  LDA $C06ABF,X
C0/6A5C: 85 0D        STA $0D
C0/6A5E: BF BD 6A C0  LDA $C06ABD,X
C0/6A62: AA           TAX 
C0/6A63: A5 06        LDA $06
C0/6A65: E2 20        SEP #$20
C0/6A67: E4 0D        CPX $0D
C0/6A69: F0 51        BEQ $6ABC
C0/6A6B: BF 00 00 C0  LDA $C00000,X   ; y
C0/6A6F: C5 0F        CMP $0F
C0/6A71: F0 08        BEQ $6A7B
C0/6A73: E8           INX 
C0/6A74: E8           INX 
C0/6A75: E8           INX 
C0/6A76: E8           INX 
C0/6A77: E8           INX 
C0/6A78: E8           INX 
C0/6A79: 80 EC        BRA $6A67
C0/6A7B: BF 03 00 C0  LDA $C00003,X   ; event bit index
C0/6A7F: 18           CLC 
C0/6A80: 69 D0        ADC #$D0
C0/6A82: 20 3C CA     JSR $CA3C       ; get event flag $01xx
C0/6A85: C9 00        CMP #$00
C0/6A87: F0 EA        BEQ $6A73
C0/6A89: DA           PHX 
C0/6A8A: BF 02 00 C0  LDA $C00002,X   ; width
C0/6A8E: 85 2C        STA $2C
C0/6A90: BF 01 00 C0  LDA $C00001,X   ; x
C0/6A94: C2 20        REP #$20
C0/6A96: 18           CLC 
C0/6A97: 65 26        ADC $26
C0/6A99: A8           TAY 
C0/6A9A: BF 04 00 C0  LDA $C00004,X   ; pointer to modified tilemap data
C0/6A9E: AA           TAX 
C0/6A9F: A5 06        LDA $06
C0/6AA1: E2 20        SEP #$20
C0/6AA3: A9 7F        LDA #$7F
C0/6AA5: 48           PHA 
C0/6AA6: AB           PLB 
C0/6AA7: BF 00 00 C0  LDA $C00000,X   ; copy row of tiles
C0/6AAB: 99 00 00     STA $0000,Y
C0/6AAE: E8           INX 
C0/6AAF: C8           INY 
C0/6AB0: C6 2C        DEC $2C
C0/6AB2: D0 F3        BNE $6AA7
C0/6AB4: A9 00        LDA #$00
C0/6AB6: 48           PHA 
C0/6AB7: AB           PLB 
C0/6AB8: FA           PLX 
C0/6AB9: 4C 73 6A     JMP $6A73
C0/6ABC: 60           RTS 

; pointers to world map modification data
C0/6ABD: 726C 73DA 7518 7794 779A 79E6

C0/6AC8: 60           RTS 

; [ load map layout ]

; +X: destination address (+$7F0000)
; +Y: map layout index

C0/6ACA: 86 71        STX $71
C0/6ACC: A9 CB        LDA #$CB
C0/6ACE: 85 25        STA $25
C0/6AD0: C2 20        REP #$20
C0/6AD2: A6 06        LDX $06
C0/6AD4: C0 00 00     CPY #$0000
C0/6AD7: F0 1A        BEQ $6AF3
C0/6AD9: E8           INX 
C0/6ADA: E8           INX 
C0/6ADB: 88           DEY 
C0/6ADC: F0 15        BEQ $6AF3
C0/6ADE: E8           INX 
C0/6ADF: E8           INX 
C0/6AE0: BF 00 00 CB  LDA $CB0000,X
C0/6AE4: CA           DEX 
C0/6AE5: CA           DEX 
C0/6AE6: DF 00 00 CB  CMP $CB0000,X
C0/6AEA: B0 02        BCS $6AEE
C0/6AEC: E6 25        INC $25
C0/6AEE: E8           INX 
C0/6AEF: E8           INX 
C0/6AF0: 88           DEY 
C0/6AF1: D0 EB        BNE $6ADE
C0/6AF3: BF 00 00 CB  LDA $CB0000,X   ; pointer to map layout
C0/6AF7: 8D F0 04     STA $04F0
C0/6AFA: 85 23        STA $23
C0/6AFC: AD 71 0B     LDA $0B71
C0/6AFF: 8D F3 04     STA $04F3
C0/6B02: A5 06        LDA $06
C0/6B04: E2 20        SEP #$20
C0/6B06: A5 25        LDA $25
C0/6B08: 8D F2 04     STA $04F2
C0/6B0B: A9 7F        LDA #$7F
C0/6B0D: 8D F5 04     STA $04F5
C0/6B10: A4 06        LDY $06
C0/6B12: B7 23        LDA [$23],Y
C0/6B14: D0 05        BNE $6B1B
C0/6B16: 22 02 00 C3  JSL $C30002     ; decompress
C0/6B1A: 60           RTS 
C0/6B1B: A6 71        LDX $71
C0/6B1D: 20 21 6B     JSR $6B21       ; clear tile layout
C0/6B20: 60           RTS 

; [ fill map tile layout ]

;  A: fill value
; +X: data offset

C0/6B21: A0 00 10     LDY #$1000
C0/6B24: 9F 00 00 7F  STA $7F0000,X
C0/6B28: E8           INX 
C0/6B29: 88           DEY 
C0/6B2A: D0 F8        BNE $6B24
C0/6B2C: 60           RTS 

; [ load world tileset ]

; +Y: source address
;  A: source bank

C0/6B2D: 48           PHA 
C0/6B2E: AB           PLB 
C0/6B2F: A6 06        LDX $06
C0/6B31: B9 00 00     LDA $0000,Y
C0/6B34: 9F 22 6E 7F  STA $7F6E22,X
C0/6B38: C8           INY 
C0/6B39: E8           INX 
C0/6B3A: E0 00 08     CPX #$0800
C0/6B3D: D0 F2        BNE $6B31
C0/6B3F: A5 06        LDA $06
C0/6B41: 48           PHA 
C0/6B42: AB           PLB 
C0/6B43: 60           RTS 

; [ load tile properties and tileset ]

C0/6B44: AD 11 11     LDA $1111       ; tile properties
C0/6B47: 0A           ASL 
C0/6B48: AA           TAX 
C0/6B49: C2 20        REP #$20
C0/6B4B: BF 40 C5 CF  LDA $CFC540,X   ; pointers to tile properties
C0/6B4F: 18           CLC 
C0/6B50: 69 40 C5     ADC #$C540      ; CF/C540
C0/6B53: 8D F0 04     STA $04F0
C0/6B56: A5 06        LDA $06
C0/6B58: E2 20        SEP #$20
C0/6B5A: A9 CF        LDA #$CF
C0/6B5C: 8D F2 04     STA $04F2
C0/6B5F: A2 86 11     LDX #$1186      ; 00/1186
C0/6B62: 8E F3 04     STX $04F3
C0/6B65: A9 00        LDA #$00
C0/6B67: 8D F5 04     STA $04F5
C0/6B6A: 22 02 00 C3  JSL $C30002     ; decompress
C0/6B6E: AD 14 11     LDA $1114       ; tileset
C0/6B71: 0A           ASL 
C0/6B72: AA           TAX 
C0/6B73: C2 20        REP #$20
C0/6B75: BF 00 00 CF  LDA $CF0000,X   ; pointers to tilesets
C0/6B79: 18           CLC 
C0/6B7A: 69 00 00     ADC #$0000      ; CF/0000
C0/6B7D: 8D F0 04     STA $04F0
C0/6B80: A5 06        LDA $06
C0/6B82: E2 20        SEP #$20
C0/6B84: A9 CF        LDA #$CF
C0/6B86: 8D F2 04     STA $04F2
C0/6B89: A2 22 6E     LDX #$6E22      ; 7F/6E22
C0/6B8C: 8E F3 04     STX $04F3
C0/6B8F: A9 7F        LDA #$7F
C0/6B91: 8D F5 04     STA $04F5
C0/6B94: 22 02 00 C3  JSL $C30002     ; decompress
C0/6B98: 60           RTS 

C0/6B99: A2 00 10     LDX #$1000
C0/6B9C: 9F FF FF 7E  STA $7EFFFF,X
C0/6BA0: 9F FF 0F 7F  STA $7F0FFF,X
C0/6BA4: 9F FF 1F 7F  STA $7F1FFF,X
C0/6BA8: CA           DEX 
C0/6BA9: D0 F1        BNE $6B9C
C0/6BAB: 60           RTS 
C0/6BAC: C2 20        REP #$20
C0/6BAE: AD D9 0A     LDA $0AD9
C0/6BB1: 29 FF 00     AND #$00FF
C0/6BB4: 38           SEC 
C0/6BB5: E9 07 00     SBC #$0007
C0/6BB8: 0A           ASL 
C0/6BB9: 0A           ASL 
C0/6BBA: 0A           ASL 
C0/6BBB: 0A           ASL 
C0/6BBC: 0A           ASL 
C0/6BBD: 29 FF 0F     AND #$0FFF
C0/6BC0: 85 63        STA $63
C0/6BC2: AD D8 0A     LDA $0AD8
C0/6BC5: 29 FF 00     AND #$00FF
C0/6BC8: 38           SEC 
C0/6BC9: E9 07 00     SBC #$0007
C0/6BCC: 0A           ASL 
C0/6BCD: 0A           ASL 
C0/6BCE: 0A           ASL 
C0/6BCF: 0A           ASL 
C0/6BD0: 0A           ASL 
C0/6BD1: 29 FF 0F     AND #$0FFF
C0/6BD4: 85 61        STA $61
C0/6BD6: A5 06        LDA $06
C0/6BD8: E2 20        SEP #$20
C0/6BDA: 60           RTS 

; [ init bg scroll positions ]

C0/6BDB: C2 20        REP #$20
C0/6BDD: AD D9 0A     LDA $0AD9       ; y position ???
C0/6BE0: 29 FF 00     AND #$00FF
C0/6BE3: 38           SEC 
C0/6BE4: E9 07 00     SBC #$0007
C0/6BE7: 0A           ASL 
C0/6BE8: 0A           ASL 
C0/6BE9: 0A           ASL 
C0/6BEA: 0A           ASL 
C0/6BEB: 0A           ASL 
C0/6BEC: 29 FF 0F     AND #$0FFF
C0/6BEF: 85 63        STA $63
C0/6BF1: AD D8 0A     LDA $0AD8       ; x position ???
C0/6BF4: 29 FF 00     AND #$00FF
C0/6BF7: 38           SEC 
C0/6BF8: E9 07 00     SBC #$0007
C0/6BFB: 0A           ASL 
C0/6BFC: 0A           ASL 
C0/6BFD: 0A           ASL 
C0/6BFE: 0A           ASL 
C0/6BFF: 0A           ASL 
C0/6C00: 29 FF 0F     AND #$0FFF
C0/6C03: 85 61        STA $61
C0/6C05: A5 78        LDA $78         ; bg2 v-scroll
C0/6C07: 29 FF 00     AND #$00FF
C0/6C0A: 38           SEC 
C0/6C0B: E9 07 00     SBC #$0007
C0/6C0E: 0A           ASL 
C0/6C0F: 0A           ASL 
C0/6C10: 0A           ASL 
C0/6C11: 0A           ASL 
C0/6C12: 0A           ASL 
C0/6C13: 85 67        STA $67
C0/6C15: A5 77        LDA $77         ; bg2 h-scroll
C0/6C17: 29 FF 00     AND #$00FF
C0/6C1A: 38           SEC 
C0/6C1B: E9 07 00     SBC #$0007
C0/6C1E: 0A           ASL 
C0/6C1F: 0A           ASL 
C0/6C20: 0A           ASL 
C0/6C21: 0A           ASL 
C0/6C22: 0A           ASL 
C0/6C23: 85 65        STA $65
C0/6C25: A5 7A        LDA $7A         ; bg3 v-scroll
C0/6C27: 29 FF 00     AND #$00FF
C0/6C2A: 38           SEC 
C0/6C2B: E9 07 00     SBC #$0007
C0/6C2E: 0A           ASL 
C0/6C2F: 0A           ASL 
C0/6C30: 0A           ASL 
C0/6C31: 0A           ASL 
C0/6C32: 0A           ASL 
C0/6C33: 85 6B        STA $6B
C0/6C35: A5 79        LDA $79         ; bg3 h-scroll
C0/6C37: 29 FF 00     AND #$00FF
C0/6C3A: 38           SEC 
C0/6C3B: E9 07 00     SBC #$0007
C0/6C3E: 0A           ASL 
C0/6C3F: 0A           ASL 
C0/6C40: 0A           ASL 
C0/6C41: 0A           ASL 
C0/6C42: 0A           ASL 
C0/6C43: 85 69        STA $69
C0/6C45: A5 06        LDA $06
C0/6C47: E2 20        SEP #$20
C0/6C49: 60           RTS 

C0/6C4A: 20 AC 6B     JSR $6BAC
C0/6C4D: AD D9 0A     LDA $0AD9
C0/6C50: 85 76        STA $76
C0/6C52: AD D8 0A     LDA $0AD8
C0/6C55: 85 75        STA $75
C0/6C57: A9 40        LDA #$40
C0/6C59: 48           PHA 
C0/6C5A: 20 A1 69     JSR $69A1
C0/6C5D: 20 13 65     JSR $6513
C0/6C60: 20 65 64     JSR $6465
C0/6C63: E6 76        INC $76
C0/6C65: 68           PLA 
C0/6C66: 3A           DEC 
C0/6C67: D0 F0        BNE $6C59
C0/6C69: 60           RTS 

C0/6C6A: AE D4 0A     LDX $0AD4
C0/6C6D: E0 BE 00     CPX #$00BE
C0/6C70: D0 2A        BNE $6C9C
C0/6C72: 9C 6D 0B     STZ $0B6D
C0/6C75: A2 00 20     LDX #$2000
C0/6C78: 86 2E        STX $2E
C0/6C7A: 86 2C        STX $2C
C0/6C7C: 20 13 4D     JSR $4D13       ; fill vram
C0/6C7F: A9 80        LDA #$80
C0/6C81: 8D 15 21     STA $2115
C0/6C84: A0 02 27     LDY #$2702
C0/6C87: 20 9D 6C     JSR $6C9D
C0/6C8A: A0 82 2D     LDY #$2D82
C0/6C8D: 20 9D 6C     JSR $6C9D
C0/6C90: A0 42 23     LDY #$2342
C0/6C93: 20 D4 6C     JSR $6CD4
C0/6C96: A0 C2 29     LDY #$29C2
C0/6C99: 20 D4 6C     JSR $6CD4
C0/6C9C: 60           RTS 

C0/6C9D: A6 06        LDX $06
C0/6C9F: 8C 16 21     STY $2116
C0/6CA2: BF 00 CF C0  LDA $C0CF00,X
C0/6CA6: 8D 18 21     STA $2118
C0/6CA9: E8           INX 
C0/6CAA: BF 00 CF C0  LDA $C0CF00,X
C0/6CAE: 8D 19 21     STA $2119
C0/6CB1: E8           INX 
C0/6CB2: 8A           TXA 
C0/6CB3: 29 1F        AND #$1F
C0/6CB5: D0 EB        BNE $6CA2
C0/6CB7: C2 20        REP #$20
C0/6CB9: 98           TYA 
C0/6CBA: 18           CLC 
C0/6CBB: 69 20 00     ADC #$0020
C0/6CBE: A8           TAY 
C0/6CBF: 29 E0 03     AND #$03E0
C0/6CC2: D0 06        BNE $6CCA
C0/6CC4: 98           TYA 
C0/6CC5: 18           CLC 
C0/6CC6: 69 00 04     ADC #$0400
C0/6CC9: A8           TAY 
C0/6CCA: A5 06        LDA $06
C0/6CCC: E2 20        SEP #$20
C0/6CCE: E0 E0 01     CPX #$01E0
C0/6CD1: D0 CC        BNE $6C9F
C0/6CD3: 60           RTS 

; [  ]

C0/6CD4: A2 E0 01     LDX #$01E0
C0/6CD7: 8C 16 21     STY $2116
C0/6CDA: BF 00 CF C0  LDA $C0CF00,X
C0/6CDE: 8D 18 21     STA $2118
C0/6CE1: E8           INX 
C0/6CE2: BF 00 CF C0  LDA $C0CF00,X
C0/6CE6: 8D 19 21     STA $2119
C0/6CE9: E8           INX 
C0/6CEA: 8A           TXA 
C0/6CEB: 29 1F        AND #$1F
C0/6CED: D0 EB        BNE $6CDA
C0/6CEF: C2 20        REP #$20
C0/6CF1: 98           TYA 
C0/6CF2: 18           CLC 
C0/6CF3: 69 20 00     ADC #$0020
C0/6CF6: A8           TAY 
C0/6CF7: 29 E0 03     AND #$03E0
C0/6CFA: D0 06        BNE $6D02
C0/6CFC: 98           TYA 
C0/6CFD: 18           CLC 
C0/6CFE: 69 00 04     ADC #$0400
C0/6D01: A8           TAY 
C0/6D02: A5 06        LDA $06
C0/6D04: E2 20        SEP #$20
C0/6D06: E0 40 03     CPX #$0340
C0/6D09: D0 CC        BNE $6CD7
C0/6D0B: 60           RTS 

; [  ]

C0/6D0C: A9 10        LDA #$10
C0/6D0E: 85 09        STA $09
C0/6D10: 20 DB 6B     JSR $6BDB       ; init bg scroll positions
C0/6D13: AD D9 0A     LDA $0AD9       ; y position
C0/6D16: 85 0A        STA $0A
C0/6D18: A5 78        LDA $78
C0/6D1A: 85 0B        STA $0B
C0/6D1C: A5 7A        LDA $7A
C0/6D1E: 85 0C        STA $0C
C0/6D20: AD D8 0A     LDA $0AD8       ; x position
C0/6D23: 85 75        STA $75
C0/6D25: A5 0A        LDA $0A
C0/6D27: 85 76        STA $76
C0/6D29: A9 01        LDA #$01
C0/6D2B: A6 06        LDX $06
C0/6D2D: 86 71        STX $71
C0/6D2F: 20 7D 70     JSR $707D
C0/6D32: 20 7A 6E     JSR $6E7A
C0/6D35: AD 21 11     LDA $1121
C0/6D38: 29 40        AND #$40
C0/6D3A: D0 17        BNE $6D53
C0/6D3C: A5 77        LDA $77
C0/6D3E: 85 75        STA $75
C0/6D40: A5 0B        LDA $0B
C0/6D42: 85 76        STA $76
C0/6D44: A9 01        LDA #$01
C0/6D46: A2 00 10     LDX #$1000
C0/6D49: 86 71        STX $71
C0/6D4B: 20 7D 70     JSR $707D
C0/6D4E: 20 7A 6E     JSR $6E7A
C0/6D51: 80 36        BRA $6D89
C0/6D53: A9 07        LDA #$07
C0/6D55: 85 75        STA $75
C0/6D57: A5 0B        LDA $0B
C0/6D59: 38           SEC 
C0/6D5A: E5 78        SBC $78
C0/6D5C: 18           CLC 
C0/6D5D: 69 08        ADC #$08
C0/6D5F: 85 76        STA $76
C0/6D61: A9 01        LDA #$01
C0/6D63: A2 00 10     LDX #$1000
C0/6D66: 86 71        STX $71
C0/6D68: 20 7D 70     JSR $707D
C0/6D6B: 20 7A 6E     JSR $6E7A
C0/6D6E: A9 17        LDA #$17
C0/6D70: 85 75        STA $75
C0/6D72: A5 0B        LDA $0B
C0/6D74: 38           SEC 
C0/6D75: E5 78        SBC $78
C0/6D77: 18           CLC 
C0/6D78: 69 08        ADC #$08
C0/6D7A: 85 76        STA $76
C0/6D7C: A9 01        LDA #$01
C0/6D7E: A2 00 10     LDX #$1000
C0/6D81: 86 71        STX $71
C0/6D83: 20 7D 70     JSR $707D
C0/6D86: 20 7A 6E     JSR $6E7A
C0/6D89: AD 21 11     LDA $1121
C0/6D8C: 30 17        BMI $6DA5
C0/6D8E: A5 79        LDA $79
C0/6D90: 85 75        STA $75
C0/6D92: A5 0C        LDA $0C
C0/6D94: 85 76        STA $76
C0/6D96: A9 01        LDA #$01
C0/6D98: A2 00 20     LDX #$2000
C0/6D9B: 86 71        STX $71
C0/6D9D: 20 7D 70     JSR $707D
C0/6DA0: 20 7A 6E     JSR $6E7A
C0/6DA3: 80 36        BRA $6DDB
C0/6DA5: A9 07        LDA #$07
C0/6DA7: 85 75        STA $75
C0/6DA9: A5 0C        LDA $0C
C0/6DAB: 38           SEC 
C0/6DAC: E5 7A        SBC $7A
C0/6DAE: 18           CLC 
C0/6DAF: 69 08        ADC #$08
C0/6DB1: 85 76        STA $76
C0/6DB3: A9 01        LDA #$01
C0/6DB5: A2 00 20     LDX #$2000
C0/6DB8: 86 71        STX $71
C0/6DBA: 20 7D 70     JSR $707D
C0/6DBD: 20 7A 6E     JSR $6E7A
C0/6DC0: A9 17        LDA #$17
C0/6DC2: 85 75        STA $75
C0/6DC4: A5 0C        LDA $0C
C0/6DC6: 38           SEC 
C0/6DC7: E5 7A        SBC $7A
C0/6DC9: 18           CLC 
C0/6DCA: 69 08        ADC #$08
C0/6DCC: 85 76        STA $76
C0/6DCE: A9 01        LDA #$01
C0/6DD0: A2 00 20     LDX #$2000
C0/6DD3: 86 71        STX $71
C0/6DD5: 20 7D 70     JSR $707D
C0/6DD8: 20 7A 6E     JSR $6E7A
C0/6DDB: E6 0A        INC $0A
C0/6DDD: E6 0B        INC $0B
C0/6DDF: E6 0C        INC $0C
C0/6DE1: C6 09        DEC $09
C0/6DE3: F0 03        BEQ $6DE8
C0/6DE5: 4C 20 6D     JMP $6D20
C0/6DE8: 60           RTS 

C0/6DE9: 9C 0B 42     STZ $420B
C0/6DEC: A9 18        LDA #$18
C0/6DEE: 8D 01 43     STA $4301
C0/6DF1: 9C 04 43     STZ $4304
C0/6DF4: 60           RTS 

; [ horizontal scrolling ]

C0/6DF5: C2 20        REP #$20
C0/6DF7: A5 71        LDA $71
C0/6DF9: EB           XBA 
C0/6DFA: 4A           LSR 
C0/6DFB: 85 17        STA $17
C0/6DFD: 4A           LSR 
C0/6DFE: 18           CLC 
C0/6DFF: 65 17        ADC $17
C0/6E01: A8           TAY 
C0/6E02: A5 06        LDA $06
C0/6E04: E2 20        SEP #$20
C0/6E06: A9 81        LDA #$81        ; increment vertically
C0/6E08: 8D 15 21     STA $2115
C0/6E0B: 20 E9 6D     JSR $6DE9
C0/6E0E: A9 01        LDA #$01
C0/6E10: 8D 00 43     STA $4300
C0/6E13: C2 20        REP #$20
C0/6E15: A5 71        LDA $71
C0/6E17: EB           XBA 
C0/6E18: 0A           ASL 
C0/6E19: 0A           ASL 
C0/6E1A: 0A           ASL 
C0/6E1B: 18           CLC 
C0/6E1C: 69 F3 16     ADC #$16F3
C0/6E1F: 8D 02 43     STA $4302
C0/6E22: A5 06        LDA $06
C0/6E24: E2 20        SEP #$20
C0/6E26: B6 7F        LDX $7F,Y
C0/6E28: 8E 16 21     STX $2116
C0/6E2B: B6 7B        LDX $7B,Y
C0/6E2D: 8E 05 43     STX $4305
C0/6E30: A9 01        LDA #$01
C0/6E32: 8D 0B 42     STA $420B
C0/6E35: B6 81        LDX $81,Y
C0/6E37: 8E 16 21     STX $2116
C0/6E3A: B6 7D        LDX $7D,Y
C0/6E3C: F0 08        BEQ $6E46
C0/6E3E: 8E 05 43     STX $4305
C0/6E41: A9 01        LDA #$01
C0/6E43: 8D 0B 42     STA $420B
C0/6E46: C2 20        REP #$20
C0/6E48: A5 71        LDA $71
C0/6E4A: EB           XBA 
C0/6E4B: 0A           ASL 
C0/6E4C: 0A           ASL 
C0/6E4D: 0A           ASL 
C0/6E4E: 18           CLC 
C0/6E4F: 69 33 17     ADC #$1733
C0/6E52: 8D 02 43     STA $4302
C0/6E55: A5 06        LDA $06
C0/6E57: E2 20        SEP #$20
C0/6E59: B6 83        LDX $83,Y
C0/6E5B: 8E 16 21     STX $2116
C0/6E5E: B6 7B        LDX $7B,Y
C0/6E60: 8E 05 43     STX $4305
C0/6E63: A9 01        LDA #$01
C0/6E65: 8D 0B 42     STA $420B
C0/6E68: B6 85        LDX $85,Y
C0/6E6A: 8E 16 21     STX $2116
C0/6E6D: B6 7D        LDX $7D,Y
C0/6E6F: F0 08        BEQ $6E79
C0/6E71: 8E 05 43     STX $4305
C0/6E74: A9 01        LDA #$01
C0/6E76: 8D 0B 42     STA $420B
C0/6E79: 60           RTS 

; [ vertical scrolling ]

C0/6E7A: C2 20        REP #$20
C0/6E7C: A5 71        LDA $71         ; pointer to map tile data ($7F0000)
C0/6E7E: EB           XBA 
C0/6E7F: 4A           LSR 
C0/6E80: 85 17        STA $17
C0/6E82: 4A           LSR 
C0/6E83: 18           CLC 
C0/6E84: 65 17        ADC $17
C0/6E86: A8           TAY 
C0/6E87: A5 06        LDA $06
C0/6E89: E2 20        SEP #$20
C0/6E8B: A9 80        LDA #$80
C0/6E8D: 8D 15 21     STA $2115
C0/6E90: 20 E9 6D     JSR $6DE9
C0/6E93: A9 01        LDA #$01
C0/6E95: 8D 00 43     STA $4300
C0/6E98: B6 7F        LDX $7F,Y
C0/6E9A: 8E 16 21     STX $2116
C0/6E9D: C2 20        REP #$20
C0/6E9F: A5 71        LDA $71
C0/6EA1: EB           XBA 
C0/6EA2: 0A           ASL 
C0/6EA3: 0A           ASL 
C0/6EA4: 0A           ASL 
C0/6EA5: 18           CLC 
C0/6EA6: 69 F3 16     ADC #$16F3      ; dma source
C0/6EA9: 8D 02 43     STA $4302
C0/6EAC: A5 06        LDA $06
C0/6EAE: E2 20        SEP #$20
C0/6EB0: B6 7B        LDX $7B,Y
C0/6EB2: 8E 05 43     STX $4305       ; dma size
C0/6EB5: A9 01        LDA #$01
C0/6EB7: 8D 0B 42     STA $420B
C0/6EBA: B6 81        LDX $81,Y
C0/6EBC: 8E 16 21     STX $2116
C0/6EBF: 9C 0B 42     STZ $420B
C0/6EC2: B6 7D        LDX $7D,Y
C0/6EC4: F0 08        BEQ $6ECE
C0/6EC6: 8E 05 43     STX $4305
C0/6EC9: A9 01        LDA #$01
C0/6ECB: 8D 0B 42     STA $420B
C0/6ECE: B6 83        LDX $83,Y
C0/6ED0: 8E 16 21     STX $2116
C0/6ED3: 9C 0B 42     STZ $420B
C0/6ED6: C2 20        REP #$20
C0/6ED8: A5 71        LDA $71
C0/6EDA: EB           XBA 
C0/6EDB: 0A           ASL 
C0/6EDC: 0A           ASL 
C0/6EDD: 0A           ASL 
C0/6EDE: 18           CLC 
C0/6EDF: 69 33 17     ADC #$1733
C0/6EE2: 8D 02 43     STA $4302
C0/6EE5: A5 06        LDA $06
C0/6EE7: E2 20        SEP #$20
C0/6EE9: B6 7B        LDX $7B,Y
C0/6EEB: 8E 05 43     STX $4305
C0/6EEE: A9 01        LDA #$01
C0/6EF0: 8D 0B 42     STA $420B
C0/6EF3: B6 85        LDX $85,Y
C0/6EF5: 8E 16 21     STX $2116
C0/6EF8: 9C 0B 42     STZ $420B
C0/6EFB: B6 7D        LDX $7D,Y
C0/6EFD: F0 08        BEQ $6F07
C0/6EFF: 8E 05 43     STX $4305
C0/6F02: A9 01        LDA #$01
C0/6F04: 8D 0B 42     STA $420B
C0/6F07: 60           RTS 

C0/6F08: A5 76        LDA $76
C0/6F0A: 29 3F        AND #$3F
C0/6F0C: EB           XBA 
C0/6F0D: C2 20        REP #$20
C0/6F0F: 4A           LSR 
C0/6F10: 4A           LSR 
C0/6F11: 05 73        ORA $73
C0/6F13: 85 0D        STA $0D
C0/6F15: A5 75        LDA $75
C0/6F17: 29 3F 00     AND #$003F
C0/6F1A: 05 0D        ORA $0D
C0/6F1C: AA           TAX 
C0/6F1D: A5 06        LDA $06
C0/6F1F: E2 20        SEP #$20
C0/6F21: A4 06        LDY $06
C0/6F23: A5 2D        LDA $2D
C0/6F25: 85 15        STA $15
C0/6F27: A5 2C        LDA $2C
C0/6F29: 85 13        STA $13
C0/6F2B: DA           PHX 
C0/6F2C: B9 B3 16     LDA $16B3,Y
C0/6F2F: 9F 00 00 7F  STA $7F0000,X
C0/6F33: C8           INY 
C0/6F34: E8           INX 
C0/6F35: C6 13        DEC $13
C0/6F37: D0 F3        BNE $6F2C
C0/6F39: C2 20        REP #$20
C0/6F3B: 68           PLA 
C0/6F3C: 18           CLC 
C0/6F3D: 69 40 00     ADC #$0040
C0/6F40: AA           TAX 
C0/6F41: A5 06        LDA $06
C0/6F43: E2 20        SEP #$20
C0/6F45: C6 15        DEC $15
C0/6F47: D0 DE        BNE $6F27
C0/6F49: A4 73        LDY $73
C0/6F4B: D0 0C        BNE $6F59
C0/6F4D: AD D8 0A     LDA $0AD8
C0/6F50: 85 75        STA $75
C0/6F52: AD D9 0A     LDA $0AD9
C0/6F55: 85 76        STA $76
C0/6F57: 80 17        BRA $6F70
C0/6F59: C0 00 10     CPY #$1000
C0/6F5C: D0 0A        BNE $6F68
C0/6F5E: A5 77        LDA $77
C0/6F60: 85 75        STA $75
C0/6F62: A5 78        LDA $78
C0/6F64: 85 76        STA $76
C0/6F66: 80 08        BRA $6F70
C0/6F68: A5 79        LDA $79
C0/6F6A: 85 75        STA $75
C0/6F6C: A5 7A        LDA $7A
C0/6F6E: 85 76        STA $76
C0/6F70: A5 76        LDA $76
C0/6F72: 38           SEC 
C0/6F73: E9 08        SBC #$08
C0/6F75: 29 3F        AND #$3F
C0/6F77: EB           XBA 
C0/6F78: C2 20        REP #$20
C0/6F7A: 4A           LSR 
C0/6F7B: 4A           LSR 
C0/6F7C: 05 73        ORA $73
C0/6F7E: 85 23        STA $23
C0/6F80: A5 06        LDA $06
C0/6F82: E2 20        SEP #$20
C0/6F84: A5 75        LDA $75
C0/6F86: 38           SEC 
C0/6F87: E9 07        SBC #$07
C0/6F89: 29 3F        AND #$3F
C0/6F8B: 05 23        ORA $23
C0/6F8D: 85 23        STA $23
C0/6F8F: A5 76        LDA $76
C0/6F91: 38           SEC 
C0/6F92: E9 08        SBC #$08
C0/6F94: 29 0F        AND #$0F
C0/6F96: EB           XBA 
C0/6F97: C2 20        REP #$20
C0/6F99: 4A           LSR 
C0/6F9A: 85 26        STA $26
C0/6F9C: A5 06        LDA $06
C0/6F9E: E2 20        SEP #$20
C0/6FA0: A5 75        LDA $75
C0/6FA2: 38           SEC 
C0/6FA3: E9 07        SBC #$07
C0/6FA5: 85 0D        STA $0D
C0/6FA7: 64 0E        STZ $0E
C0/6FA9: 29 10        AND #$10
C0/6FAB: D0 05        BNE $6FB2
C0/6FAD: A0 00 00     LDY #$0000
C0/6FB0: 80 03        BRA $6FB5
C0/6FB2: A0 00 08     LDY #$0800
C0/6FB5: A5 0D        LDA $0D
C0/6FB7: 29 0F        AND #$0F
C0/6FB9: 0A           ASL 
C0/6FBA: 0A           ASL 
C0/6FBB: 85 0D        STA $0D
C0/6FBD: C2 20        REP #$20
C0/6FBF: 98           TYA 
C0/6FC0: 18           CLC 
C0/6FC1: 65 0D        ADC $0D
C0/6FC3: 18           CLC 
C0/6FC4: 65 26        ADC $26
C0/6FC6: 85 26        STA $26
C0/6FC8: 29 80 0F     AND #$0F80
C0/6FCB: 49 00 08     EOR #$0800
C0/6FCE: 85 29        STA $29
C0/6FD0: A5 06        LDA $06
C0/6FD2: E2 20        SEP #$20
C0/6FD4: A9 7F        LDA #$7F
C0/6FD6: 48           PHA 
C0/6FD7: AB           PLB 
C0/6FD8: C2 20        REP #$20
C0/6FDA: A9 10 00     LDA #$0010
C0/6FDD: 85 11        STA $11
C0/6FDF: A6 23        LDX $23
C0/6FE1: 86 0D        STX $0D
C0/6FE3: A4 26        LDY $26
C0/6FE5: 20 3E 70     JSR $703E
C0/6FE8: A4 29        LDY $29
C0/6FEA: 20 3E 70     JSR $703E
C0/6FED: A5 23        LDA $23
C0/6FEF: 18           CLC 
C0/6FF0: 69 40 00     ADC #$0040
C0/6FF3: 29 FF 0F     AND #$0FFF
C0/6FF6: 05 73        ORA $73
C0/6FF8: 85 23        STA $23
C0/6FFA: A5 26        LDA $26
C0/6FFC: 18           CLC 
C0/6FFD: 69 80 00     ADC #$0080
C0/7000: 85 26        STA $26
C0/7002: 29 FF 07     AND #$07FF
C0/7005: C9 80 00     CMP #$0080
C0/7008: B0 08        BCS $7012
C0/700A: A5 26        LDA $26
C0/700C: 38           SEC 
C0/700D: E9 00 08     SBC #$0800
C0/7010: 85 26        STA $26
C0/7012: A5 29        LDA $29
C0/7014: 18           CLC 
C0/7015: 69 80 00     ADC #$0080
C0/7018: 85 29        STA $29
C0/701A: 29 FF 07     AND #$07FF
C0/701D: C9 80 00     CMP #$0080
C0/7020: B0 08        BCS $702A
C0/7022: A5 29        LDA $29
C0/7024: 38           SEC 
C0/7025: E9 00 08     SBC #$0800
C0/7028: 85 29        STA $29
C0/702A: C6 11        DEC $11
C0/702C: D0 B1        BNE $6FDF
C0/702E: A5 06        LDA $06
C0/7030: E2 20        SEP #$20
C0/7032: 48           PHA 
C0/7033: AB           PLB 
C0/7034: E6 A0        INC $A0
C0/7036: 20 41 4E     JSR $4E41       ; wait for vblank
C0/7039: A5 A0        LDA $A0
C0/703B: D0 F9        BNE $7036
C0/703D: 60           RTS 

C0/703E: A6 0D        LDX $0D
C0/7040: BD 00 00     LDA $0000,X
C0/7043: 29 FF 00     AND #$00FF
C0/7046: 0A           ASL 
C0/7047: AA           TAX 
C0/7048: BD 22 6E     LDA $6E22,X
C0/704B: 99 22 76     STA $7622,Y
C0/704E: BD 22 70     LDA $7022,X
C0/7051: 99 24 76     STA $7624,Y
C0/7054: BD 22 72     LDA $7222,X
C0/7057: 99 62 76     STA $7662,Y
C0/705A: BD 22 74     LDA $7422,X
C0/705D: 99 64 76     STA $7664,Y
C0/7060: A5 0D        LDA $0D
C0/7062: 1A           INC 
C0/7063: 29 3F 00     AND #$003F
C0/7066: 85 0F        STA $0F
C0/7068: A5 0D        LDA $0D
C0/706A: 29 C0 FF     AND #$FFC0
C0/706D: 05 0F        ORA $0F
C0/706F: 85 0D        STA $0D
C0/7071: 98 18        TYA 
C0/7073: 69 04 00     ADC #$0004
C0/7076: A8           TAY 
C0/7077: 29 3F 00     AND #$003F
C0/707A: D0 C2        BNE $703E
C0/707C: 60           RTS 

; [  ]

C0/707D: 85 70        STA $70
C0/707F: 29 01        AND #$01
C0/7081: F0 03        BEQ $7086
C0/7083: 4C 4B 71     JMP $714B
C0/7086: A5 76        LDA $76
C0/7088: 38           SEC 
C0/7089: E9 07        SBC #$07
C0/708B: 29 3F        AND #$3F
C0/708D: 85 24        STA $24
C0/708F: 64 23        STZ $23
C0/7091: C2 20        REP #$20
C0/7093: A5 23        LDA $76
C0/7095: 4A           LSR 
C0/7096: 4A           LSR 
C0/7097: 18           CLC 
C0/7098: 65 71        ADC $71
C0/709A: 85 23        STA $23
C0/709C: A5 06        LDA $06
C0/709E: E2 20        SEP #$20
C0/70A0: A5 70        LDA $70
C0/70A2: 29 02        AND #$02
C0/70A4: F0 08        BEQ $70AE
C0/70A6: A5 75        LDA $75
C0/70A8: 18           CLC 
C0/70A9: 69 09        ADC #$09
C0/70AB: 4C B3 70     JMP $70B3
C0/70AE: A5 75        LDA $75
C0/70B0: 38           SEC 
C0/70B1: E9 08        SBC #$08
C0/70B3: 29 3F        AND #$3F
C0/70B5: 18           CLC 
C0/70B6: 65 23        ADC $23
C0/70B8: 18           CLC 
C0/70B9: 85 23        STA $23
C0/70BB: A6 23        LDX $23
C0/70BD: 86 26        STX $26
C0/70BF: 20 21 72     JSR $7221
C0/70C2: A6 23        LDX $23
C0/70C4: BF 00 00 7F  LDA $7F0000,X
C0/70C8: C2 20        REP #$20
C0/70CA: 0A           ASL 
C0/70CB: AA           TAX 
C0/70CC: BF 22 6E 7F  LDA $7F6E22,X   ; top left tile
C0/70D0: 99 F3 16     STA $16F3,Y
C0/70D3: BF 22 72 7F  LDA $7F7222,X   ; top right tile
C0/70D7: 99 F5 16     STA $16F5,Y
C0/70DA: BF 22 70 7F  LDA $7F7022,X   ; bottom left tile
C0/70DE: 99 33 17     STA $1733,Y
C0/70E1: BF 22 74 7F  LDA $7F7422,X   ; bottom right tile
C0/70E5: 99 35 17     STA $1735,Y
C0/70E8: A5 23        LDA $23
C0/70EA: 18           CLC 
C0/70EB: 69 40 00     ADC #$0040
C0/70EE: 29 FF 0F     AND #$0FFF
C0/70F1: 85 23        STA $23
C0/70F3: A5 26        LDA $26
C0/70F5: 29 00 F0     AND #$F000
C0/70F8: 18           CLC 
C0/70F9: 65 23        ADC $23
C0/70FB: 85 23        STA $23
C0/70FD: C8           INY 
C0/70FE: C8           INY 
C0/70FF: C8           INY 
C0/7100: C8           INY 
C0/7101: 98           TYA 
C0/7102: 29 3F 00     AND #$003F
C0/7105: E2 20        SEP #$20
C0/7107: D0 B9        BNE $70C2
C0/7109: 20 2F 72     JSR $722F
C0/710C: 20 41 72     JSR $7241
C0/710F: C2 20        REP #$20
C0/7111: A5 71        LDA $71
C0/7113: 4A           LSR 
C0/7114: 18           CLC 
C0/7115: 69 00 48     ADC #$4800
C0/7118: 18           CLC 
C0/7119: 65 26        ADC $26
C0/711B: 95 7F        STA $7F,X
C0/711D: 29 C0 03     AND #$03C0
C0/7120: 4A           LSR 
C0/7121: 4A           LSR 
C0/7122: 4A           LSR 
C0/7123: 4A           LSR 
C0/7124: 95 7D        STA $7D,X
C0/7126: A9 40 00     LDA #$0040
C0/7129: 38           SEC 
C0/712A: F5 7D        SBC $7D,X
C0/712C: 95 7B        STA $7B,X
C0/712E: A5 06        LDA $06
C0/7130: E2 20        SEP #$20
C0/7132: B5 80        LDA $80,X
C0/7134: 95 84        STA $84,X
C0/7136: 29 FC        AND #$FC
C0/7138: 95 82        STA $82,X
C0/713A: 95 86        STA $86,X
C0/713C: B5 7F        LDA $7F,X
C0/713E: 29 1F        AND #$1F
C0/7140: 95 81        STA $81,X
C0/7142: 1A           INC 
C0/7143: 95 85        STA $85,X
C0/7145: B5 7F        LDA $7F,X
C0/7147: 1A           INC 
C0/7148: 95 83        STA $83,X
C0/714A: 60           RTS 
C0/714B: A5 70        LDA $70
C0/714D: 29 02        AND #$02
C0/714F: D0 08        BNE $7159
C0/7151: A5 76        LDA $76
C0/7153: 38           SEC 
C0/7154: E9 08        SBC #$08
C0/7156: 4C 5E 71     JMP $715E
C0/7159: A5 76        LDA $76
C0/715B: 18           CLC 
C0/715C: 69 08        ADC #$08
C0/715E: 29 3F        AND #$3F
C0/7160: 85 24        STA $24
C0/7162: 64 23        STZ $23
C0/7164: C2 20        REP #$20
C0/7166: A5 23        LDA $23
C0/7168: 4A           LSR 
C0/7169: 4A           LSR 
C0/716A: 18           CLC 
C0/716B: 65 71        ADC $71
C0/716D: 85 23        STA $23
C0/716F: A5 06        LDA $06
C0/7171: E2 20        SEP #$20
C0/7173: A5 75        LDA $75
C0/7175: 38           SEC 
C0/7176: E9 07        SBC #$07
C0/7178: 29 3F        AND #$3F
C0/717A: 18           CLC 
C0/717B: 65 23        ADC $23
C0/717D: 85 23        STA $23
C0/717F: A6 23        LDX $23
C0/7181: 86 26        STX $26
C0/7183: 20 21 72     JSR $7221
C0/7186: A6 23        LDX $23
C0/7188: BF 00 00 7F  LDA $7F0000,X
C0/718C: C2 20        REP #$20
C0/718E: 0A           ASL 
C0/718F: AA           TAX 
C0/7190: BF 22 6E 7F  LDA $7F6E22,X
C0/7194: 99 F3 16     STA $16F3,Y
C0/7197: BF 22 70 7F  LDA $7F7022,X
C0/719B: 99 F5 16     STA $16F5,Y
C0/719E: BF 22 72 7F  LDA $7F7222,X
C0/71A2: 99 33 17     STA $1733,Y
C0/71A5: BF 22 74 7F  LDA $7F7422,X
C0/71A9: 99 35 17     STA $1735,Y
C0/71AC: A5 06        LDA $06
C0/71AE: E2 20        SEP #$20
C0/71B0: A5 23        LDA $23
C0/71B2: 1A           INC 
C0/71B3: 29 3F        AND #$3F
C0/71B5: 85 29        STA $29
C0/71B7: A5 23        LDA $23
C0/71B9: 29 C0        AND #$C0
C0/71BB: 05 29        ORA $29
C0/71BD: 85 23        STA $23
C0/71BF: C8           INY 
C0/71C0: C8           INY 
C0/71C1: C8           INY 
C0/71C2: C8           INY 
C0/71C3: 98           TYA 
C0/71C4: 29 3F        AND #$3F
C0/71C6: D0 BE        BNE $7186
C0/71C8: 20 2F 72     JSR $722F
C0/71CB: 20 41 72     JSR $7241
C0/71CE: A5 27        LDA $27
C0/71D0: 95 80        STA $80,X
C0/71D2: A5 26        LDA $26
C0/71D4: 95 7F        STA $7F,X
C0/71D6: B5 7F        LDA $7F,X
C0/71D8: 29 1F        AND #$1F
C0/71DA: 0A           ASL 
C0/71DB: 95 7D        STA $7D,X
C0/71DD: 74 7E        STZ $7E,X
C0/71DF: A9 40        LDA #$40
C0/71E1: 38           SEC 
C0/71E2: F5 7D        SBC $7D,X
C0/71E4: 95 7B        STA $7B,X
C0/71E6: 74 7C        STZ $7C,X
C0/71E8: B5 7F        LDA $7F,X
C0/71EA: 29 E0        AND #$E0
C0/71EC: 95 81        STA $81,X
C0/71EE: B5 80        LDA $80,X
C0/71F0: 18           CLC 
C0/71F1: 69 04        ADC #$04
C0/71F3: 29 07        AND #$07
C0/71F5: 95 82        STA $82,X
C0/71F7: C2 20        REP #$20
C0/71F9: A5 71        LDA $71
C0/71FB: 4A           LSR 
C0/71FC: 18           CLC 
C0/71FD: 69 00 48     ADC #$4800
C0/7200: 48           PHA 
C0/7201: 18           CLC 
C0/7202: 75 7F        ADC $7F,X
C0/7204: 95 7F        STA $7F,X
C0/7206: 68           PLA 
C0/7207: 18           CLC 
C0/7208: 75 81        ADC $81,X
C0/720A: 95 81        STA $81,X
C0/720C: B5 7F        LDA $7F,X
C0/720E: 18           CLC 
C0/720F: 69 20 00     ADC #$0020
C0/7212: 95 83        STA $83,X
C0/7214: B5 81        LDA $81,X
C0/7216: 18           CLC 
C0/7217: 69 20 00     ADC #$0020
C0/721A: 95 85        STA $85,X
C0/721C: A5 06        LDA $06
C0/721E: E2 20        SEP #$20
C0/7220: 60           RTS 

C0/7221: C2 20        REP #$20
C0/7223: A5 71        LDA $71
C0/7225: EB           XBA 
C0/7226: 0A           ASL 
C0/7227: 0A           ASL 
C0/7228: 0A           ASL 
C0/7229: A8           TAY 
C0/722A: A5 06        LDA $06
C0/722C: E2 20        SEP #$20
C0/722E: 60           RTS 

C0/722F: C2 20        REP #$20
C0/7231: A5 71        LDA $71
C0/7233: EB           XBA 
C0/7234: 4A           LSR 
C0/7235: 85 0D        STA $0D
C0/7237: 4A           LSR 
C0/7238: 18           CLC 
C0/7239: 65 0D        ADC $0D
C0/723B: AA           TAX 
C0/723C: A5 06        LDA $06
C0/723E: E2 20        SEP #$20
C0/7240: 60           RTS 
C0/7241: C2 20        REP #$20
C0/7243: A5 26        LDA $26
C0/7245: 29 C0 03     AND #$03C0
C0/7248: 85 29        STA $29
C0/724A: A5 26        LDA $26
C0/724C: 29 10 00     AND #$0010
C0/724F: F0 08        BEQ $7259
C0/7251: A5 29        LDA $29
C0/7253: 18           CLC 
C0/7254: 69 00 04     ADC #$0400
C0/7257: 85 29        STA $29
C0/7259: A5 26        LDA $26
C0/725B: 29 0F 00     AND #$000F
C0/725E: 0A           ASL 
C0/725F: 18           CLC 
C0/7260: 65 29        ADC $29
C0/7262: 29 FF 07     AND #$07FF
C0/7265: 85 26        STA $26
C0/7267: A5 06        LDA $06
C0/7269: E2 20        SEP #$20
C0/726B: 60           RTS 

; $726C-$79E5 world map modification data (y, x, width, event bit, pointer to tilemap)
; $79E6-$83AD world map modification tile data

; ========================================================================================

; [ show dialog ]

C0/83AE: 20 01 84     JSR $8401       ; get pointer to dialog
C0/83B1: 20 54 8F     JSR $8F54
C0/83B4: A6 B1        LDX $B1
C0/83B6: BF 00 00 CA  LDA $CA0000,X
C0/83BA: F0 3E        BEQ $83FA
C0/83BC: 20 27 84     JSR $8427
C0/83BF: A4 06        LDY $06
C0/83C1: 84 AB        STY $AB
C0/83C3: 20 3B 8D     JSR $8D3B
C0/83C6: 20 41 4E     JSR $4E41       ; wait for vblank
C0/83C9: 20 7C 23     JSR $237C       ; update party sprite
C0/83CC: 20 B3 39     JSR $39B3       ; update object sprites
C0/83CF: 20 42 28     JSR $2842
C0/83D2: A4 AB        LDY $AB
C0/83D4: C0 40 00     CPY #$0040
C0/83D7: D0 EA        BNE $83C3
C0/83D9: A5 B8        LDA $B8
C0/83DB: D0 09        BNE $83E6
C0/83DD: 20 AD 4A     JSR $4AAD
C0/83E0: 20 C1 4A     JSR $4AC1       ; wait for keypress
C0/83E3: 20 AD 4A     JSR $4AAD
C0/83E6: 64 B8        STZ $B8
C0/83E8: E6 A5        INC $A5
C0/83EA: 20 41 4E     JSR $4E41       ; wait for vblank
C0/83ED: 20 7C 23     JSR $237C       ; update party sprite
C0/83F0: 20 B3 39     JSR $39B3       ; update object sprites
C0/83F3: 20 42 28     JSR $2842
C0/83F6: A5 B3        LDA $B3
C0/83F8: F0 B7        BEQ $83B1
C0/83FA: 20 A8 94     JSR $94A8
C0/83FD: 20 41 4E     JSR $4E41       ; wait for vblank
C0/8400: 60           RTS 

; [ get pointer to dialog ]

C0/8401: 64 B3        STZ $B3         ; 
C0/8403: C2 20        REP #$20
C0/8405: A5 AF        LDA $AF         ; dialog index
C0/8407: 29 FF 7F     AND #$7FFF
C0/840A: 0A           ASL 
C0/840B: AA           TAX 
C0/840C: BF 20 22 C8  LDA $C82220,X   ; pointer to dialog
C0/8410: 85 B1        STA $B1
C0/8412: A5 06        LDA $06
C0/8414: E2 20        SEP #$20
C0/8416: A5 B0        LDA $B0
C0/8418: 30 05        BMI $841F
C0/841A: A9 01        LDA #$01        ; dialog window at top of screen
C0/841C: 4C 21 84     JMP $8421
C0/841F: A9 08        LDA #$08        ; dialog window at bottom of screen
C0/8421: 85 B4        STA $B4
C0/8423: 20 40 94     JSR $9440       ; 
C0/8426: 60           RTS 

C0/8427: A6 06        LDX $06
C0/8429: 86 AB        STX $AB
C0/842B: A6 B1        LDX $B1
C0/842D: BF 00 00 CA  LDA $CA0000,X
C0/8431: C9 FF        CMP #$FF
C0/8433: F0 1C        BEQ $8451
C0/8435: C9 CD        CMP #$CD
C0/8437: 90 03        BCC $843C
C0/8439: 4C 08 85     JMP $8508
C0/843C: C9 20        CMP #$20
C0/843E: B0 11        BCS $8451
C0/8440: C2 20        REP #$20
C0/8442: 0A           ASL 
C0/8443: AA           TAX 
C0/8444: BF 13 8B C0  LDA $C08B13,X
C0/8448: 85 23        STA $23
C0/844A: A5 06        LDA $06
C0/844C: E2 20        SEP #$20
C0/844E: 6C 23 0B     JMP ($0B23)
C0/8451: A4 AB        LDY $AB
C0/8453: 99 D3 19     STA $19D3,Y
C0/8456: C8           INY 
C0/8457: 84 AB        STY $AB
C0/8459: A4 B1        LDY $B1
C0/845B: C8           INY 
C0/845C: 84 B1        STY $B1
C0/845E: A4 AB        LDY $AB
C0/8460: C0 40 00     CPY #$0040
C0/8463: D0 C6        BNE $842B
C0/8465: 60           RTS 
C0/8466: A6 B1        LDX $B1
C0/8468: A4 AB        LDY $AB
C0/846A: BF 00 00 CA  LDA $CA0000,X
C0/846E: 99 D3 19     STA $19D3,Y
C0/8471: C8           INY 
C0/8472: 84 AB        STY $AB
C0/8474: 4C 59 84     JMP $8459
C0/8477: A6 B1        LDX $B1
C0/8479: A4 AB        LDY $AB
C0/847B: BF 00 00 CA  LDA $CA0000,X
C0/847F: 99 D3 19     STA $19D3,Y
C0/8482: E8           INX 
C0/8483: C8           INY 
C0/8484: BF 00 00 CA  LDA $CA0000,X
C0/8488: 99 D3 19     STA $19D3,Y
C0/848B: 86 B1        STX $B1
C0/848D: C8           INY 
C0/848E: 84 AB        STY $AB
C0/8490: 4C 59 84     JMP $8459
C0/8493: A4 AB        LDY $AB
C0/8495: A9 FF        LDA #$FF
C0/8497: 99 D3 19     STA $19D3,Y
C0/849A: C8           INY 
C0/849B: C0 40 00     CPY #$0040
C0/849E: F0 05        BEQ $84A5
C0/84A0: A9 00        LDA #$00
C0/84A2: 99 D3 19     STA $19D3,Y
C0/84A5: A0 40 00     LDY #$0040
C0/84A8: 84 AB        STY $AB
C0/84AA: E6 B3        INC $B3
C0/84AC: 4C 59 84     JMP $8459
C0/84AF: C2 20        REP #$20
C0/84B1: A5 AB        LDA $AB
C0/84B3: 29 F0 FF     AND #$FFF0
C0/84B6: 18           CLC 
C0/84B7: 69 10 00     ADC #$0010
C0/84BA: 85 23        STA $23
C0/84BC: A5 06        LDA $06
C0/84BE: E2 20        SEP #$20
C0/84C0: A4 AB        LDY $AB
C0/84C2: C4 23        CPY $23
C0/84C4: F0 1E        BEQ $84E4
C0/84C6: A9 FF        LDA #$FF
C0/84C8: 99 D3 19     STA $19D3,Y
C0/84CB: C8           INY 
C0/84CC: C4 23        CPY $23
C0/84CE: F0 14        BEQ $84E4
C0/84D0: A9 01        LDA #$01
C0/84D2: 99 D3 19     STA $19D3,Y
C0/84D5: C8           INY 
C0/84D6: C4 23        CPY $23
C0/84D8: F0 0A        BEQ $84E4
C0/84DA: A9 FF        LDA #$FF
C0/84DC: 99 D3 19     STA $19D3,Y
C0/84DF: C8           INY 
C0/84E0: C4 23        CPY $23
C0/84E2: D0 F8        BNE $84DC
C0/84E4: 84 AB        STY $AB
C0/84E6: 4C 59 84     JMP $8459
C0/84E9: A6 06        LDX $06
C0/84EB: A4 AB        LDY $AB
C0/84ED: BD 90 09     LDA $0990,X
C0/84F0: C9 FF        CMP #$FF
C0/84F2: F0 0F        BEQ $8503
C0/84F4: 99 D3 19     STA $19D3,Y
C0/84F7: A9 00        LDA #$00
C0/84F9: 99 13 1A     STA $1A13,Y
C0/84FC: C8           INY 
C0/84FD: E8           INX 
C0/84FE: E0 06 00     CPX #$0006
C0/8501: D0 EA        BNE $84ED
C0/8503: 84 AB        STY $AB
C0/8505: 4C 59 84     JMP $8459
C0/8508: 38           SEC 
C0/8509: E9 B2        SBC #$B2
C0/850B: 80 05        BRA $8512
C0/850D: 8A           TXA 
C0/850E: 4A           LSR 
C0/850F: 38           SEC 
C0/8510: E9 03        SBC #$03
C0/8512: AA           TAX 
C0/8513: BF 41 85 C0  LDA $C08541,X
C0/8517: 85 0D        STA $0D
C0/8519: 64 0E        STZ $0E
C0/851B: C2 20        REP #$20
C0/851D: 8A           TXA 
C0/851E: 0A           ASL 
C0/851F: 0A           ASL 
C0/8520: 0A           ASL 
C0/8521: AA           TAX 
C0/8522: A5 06        LDA $06
C0/8524: E2 20        SEP #$20
C0/8526: A4 AB        LDY $AB
C0/8528: BF 8F 85 C0  LDA $C0858F,X
C0/852C: 99 D3 19     STA $19D3,Y
C0/852F: BF F7 87 C0  LDA $C087F7,X
C0/8533: 99 13 1A     STA $1A13,Y
C0/8536: E8           INX 
C0/8537: C8           INY 
C0/8538: C6 0D        DEC $0D
C0/853A: D0 EC        BNE $8528
C0/853C: 84 AB        STY $AB
C0/853E: 4C 59 84     JMP $8459

C0/8541: 05 05        ORA $05
C0/8543: 04 02        TSB $02
C0/8545: 02 04        COP $04
C0/8547: 03 02        ORA $02,S
C0/8549: 02 00        COP $00
C0/854B: 04 02        TSB $02
C0/854D: 00 00        BRK $00
C0/854F: 00 00        BRK $00
C0/8551: 02 03        COP $03
C0/8553: 03 02        ORA $02,S
C0/8555: 00 05        BRK $05
C0/8557: 03 04        ORA $04,S
C0/8559: 05 04        ORA $04
C0/855B: 06 02        ASL $02
C0/855D: 01 02        ORA ($02,X)
C0/855F: 01 01        ORA ($01,X)
C0/8561: 01 01        ORA ($01,X)
C0/8563: 01 04        ORA ($04,X)
C0/8565: 01 01        ORA ($01,X)
C0/8567: 01 02        ORA ($02,X)
C0/8569: 01 01        ORA ($01,X)
C0/856B: 01 02        ORA ($02,X)
C0/856D: 06 02        ASL $02
C0/856F: 02 02        COP $02
C0/8571: 02 01        COP $01
C0/8573: 02 01        COP $01
C0/8575: 03 02        ORA $02,S
C0/8577: 02 01        COP $01
C0/8579: 01 02        ORA ($02,X)
C0/857B: 02 04        COP $04
C0/857D: 05 03        ORA $03
C0/857F: 03 02        ORA $02,S
C0/8581: 03 03        ORA $03,S
C0/8583: 04 02        TSB $02
C0/8585: 02 02        COP $02
C0/8587: 02 04        COP $04
C0/8589: 03 02        ORA $02,S
C0/858B: 02 08        COP $08
C0/858D: 06 01        ASL $01
C0/858F: 6E A8 78     ROR $78A8
C0/8592: 7E AA 00     ROR $00AA,X
C0/8595: 00 00        BRK $00
C0/8597: 7E 8C 6E     ROR $6E8C,X
C0/859A: C5 B8        CMP $B8
C0/859C: 00 00        BRK $00
C0/859E: 00 64        BRK $64
C0/85A0: C4 64        CPY $64
C0/85A2: C4 00        CPY $00
C0/85A4: 00 00        BRK $00
C0/85A6: 00 37        BRK $37
C0/85A8: BF 00 00 00  LDA $000000,X
C0/85AC: 00 00        BRK $00
C0/85AE: 00 8D        BRK $8D
C0/85B0: AB           PLB 
C0/85B1: 00 00        BRK $00
C0/85B3: 00 00        BRK $00
C0/85B5: 00 00        BRK $00
C0/85B7: FF FF FF FF  SBC $FFFFFF,X
C0/85BB: 00 00        BRK $00
C0/85BD: 00 00        BRK $00
C0/85BF: FF FF FF 00  SBC $00FFFF,X
C0/85C3: 00 00        BRK $00
C0/85C5: 00 00        BRK $00
C0/85C7: FF FF 00 00  SBC $0000FF,X
C0/85CB: 00 00        BRK $00
C0/85CD: 00 00        BRK $00
C0/85CF: 12 13        ORA ($13)
C0/85D1: 00 00        BRK $00
C0/85D3: 00 00        BRK $00
C0/85D5: 00 00        BRK $00
C0/85D7: 00 00        BRK $00
C0/85D9: 00 00        BRK $00
C0/85DB: 00 00        BRK $00
C0/85DD: 00 00        BRK $00
C0/85DF: 24 9B        BIT $9B
C0/85E1: 52 57        EOR ($57)
C0/85E3: 00 00        BRK $00
C0/85E5: 00 00        BRK $00
C0/85E7: 04 0A        TSB $0A
C0/85E9: 00 00        BRK $00
C0/85EB: 00 00        BRK $00
C0/85ED: 00 00        BRK $00
C0/85EF: 00 00        BRK $00
C0/85F1: 00 00        BRK $00
C0/85F3: 00 00        BRK $00
C0/85F5: 00 00        BRK $00
C0/85F7: 00 00        BRK $00
C0/85F9: 00 00        BRK $00
C0/85FB: 00 00        BRK $00
C0/85FD: 00 00        BRK $00
C0/85FF: 00 00        BRK $00
C0/8601: 00 00        BRK $00
C0/8603: 00 00        BRK $00
C0/8605: 00 00        BRK $00
C0/8607: 00 00        BRK $00
C0/8609: 00 00        BRK $00
C0/860B: 00 00        BRK $00
C0/860D: 00 00        BRK $00
C0/860F: 07 0D        ORA [$0D]
C0/8611: 00 00        BRK $00
C0/8613: 00 00        BRK $00
C0/8615: 00 00        BRK $00
C0/8617: 76 46        ROR $46,X
C0/8619: D0 00        BNE $861B
C0/861B: 00 00        BRK $00
C0/861D: 00 00        BRK $00
C0/861F: 9E 46 D0     STZ $D046,X
C0/8622: 00 00        BRK $00
C0/8624: 00 00        BRK $00
C0/8626: 00 05        BRK $05
C0/8628: 06 00        ASL $00
C0/862A: 00 00        BRK $00
C0/862C: 00 00        BRK $00
C0/862E: 00 00        BRK $00
C0/8630: 00 00        BRK $00
C0/8632: 00 00        BRK $00
C0/8634: 00 00        BRK $00
C0/8636: 00 8E        BRK $8E
C0/8638: 6E 78 44     ROR $4478
C0/863B: 78           SEI 
C0/863C: 00 00        BRK $00
C0/863E: 00 AC        BRK $AC
C0/8640: 92 D0        STA ($D0)
C0/8642: 00 00        BRK $00
C0/8644: 00 00        BRK $00
C0/8646: 00 2A        BRK $2A
C0/8648: A6 64        LDX $64
C0/864A: D0 00        BNE $864C
C0/864C: 00 00        BRK $00
C0/864E: 00 64        BRK $64
C0/8650: C4 A8        CPY $A8
C0/8652: 78           SEI 
C0/8653: D0 00        BNE $8655
C0/8655: 00 00        BRK $00
C0/8657: 6E AA AA     ROR $AAAA
C0/865A: D0 00        BNE $865C
C0/865C: 00 00        BRK $00
C0/865E: 00 91        BRK $91
C0/8660: 37 8D        AND [$8D],Y
C0/8662: 81 BF        STA ($BF,X)
C0/8664: B9 00 00     LDA $0000,Y
C0/8667: C9 C9        CMP #$C9
C0/8669: 00 00        BRK $00
C0/866B: 00 00        BRK $00
C0/866D: 00 00        BRK $00
C0/866F: CE 00 00     DEC $0000
C0/8672: 00 00        BRK $00
C0/8674: 00 00        BRK $00
C0/8676: 00 BD        BRK $BD
C0/8678: 85 00        STA $00
C0/867A: 00 00        BRK $00
C0/867C: 00 00        BRK $00
C0/867E: 00 D0        BRK $D0
C0/8680: 00 00        BRK $00
C0/8682: 00 00        BRK $00
C0/8684: 00 00        BRK $00
C0/8686: 00 D1        BRK $D1
C0/8688: 00 00        BRK $00
C0/868A: 00 00        BRK $00
C0/868C: 00 00        BRK $00
C0/868E: 00 D2        BRK $D2
C0/8690: 00 00        BRK $00
C0/8692: 00 00        BRK $00
C0/8694: 00 00        BRK $00
C0/8696: 00 D3        BRK $D3
C0/8698: 00 00        BRK $00
C0/869A: 00 00        BRK $00
C0/869C: 00 00        BRK $00
C0/869E: 00 D4        BRK $D4
C0/86A0: 00 00        BRK $00
C0/86A2: 00 00        BRK $00
C0/86A4: 00 00        BRK $00
C0/86A6: 00 1B        BRK $1B
C0/86A8: 95 08        STA $08,X
C0/86AA: AD 00 00     LDA $0000
C0/86AD: 00 00        BRK $00
C0/86AF: D6 00        DEC $00,X
C0/86B1: 00 00        BRK $00
C0/86B3: 00 00        BRK $00
C0/86B5: 00 00        BRK $00
C0/86B7: D7 00        CMP [$00],Y
C0/86B9: 00 00        BRK $00
C0/86BB: 00 00        BRK $00
C0/86BD: 00 00        BRK $00
C0/86BF: D8           CLD 
C0/86C0: 00 00        BRK $00
C0/86C2: 00 00        BRK $00
C0/86C4: 00 00        BRK $00
C0/86C6: 00 93        BRK $93
C0/86C8: 8D 00 00     STA $0000
C0/86CB: 00 00        BRK $00
C0/86CD: 00 00        BRK $00
C0/86CF: DA           PHX 
C0/86D0: 00 00        BRK $00
C0/86D2: 00 00        BRK $00
C0/86D4: 00 00        BRK $00
C0/86D6: 00 DB        BRK $DB
C0/86D8: 00 00        BRK $00
C0/86DA: 00 00        BRK $00
C0/86DC: 00 00        BRK $00
C0/86DE: 00 DC        BRK $DC
C0/86E0: 00 00        BRK $00
C0/86E2: 00 00        BRK $00
C0/86E4: 00 00        BRK $00
C0/86E6: 00 C7        BRK $C7
C0/86E8: C7 00        CMP [$00]
C0/86EA: 00 00        BRK $00
C0/86EC: 00 00        BRK $00
C0/86EE: 00 3F        BRK $3F
C0/86F0: 8D 37 C3     STA $C337
C0/86F3: 89 25        BIT #$25
C0/86F5: 00 00        BRK $00
C0/86F7: 61 E3        ADC ($E3,X)
C0/86F9: 00 00        BRK $00
C0/86FB: 00 00        BRK $00
C0/86FD: 00 00        BRK $00
C0/86FF: B9 3F 00     LDA $003F,Y
C0/8702: 00 00        BRK $00
C0/8704: 00 00        BRK $00
C0/8706: 00 85        BRK $85
C0/8708: 8D 00 00     STA $0000
C0/870B: 00 00        BRK $00
C0/870D: 00 00        BRK $00
C0/870F: 77 7F        ADC [$7F],Y
C0/8711: 00 00        BRK $00
C0/8713: 00 00        BRK $00
C0/8715: 00 00        BRK $00
C0/8717: E3 00        SBC $00,S
C0/8719: 00 00        BRK $00
C0/871B: 00 00        BRK $00
C0/871D: 00 00        BRK $00
C0/871F: 77 85        ADC [$85],Y
C0/8721: 00 00        BRK $00
C0/8723: 00 00        BRK $00
C0/8725: 00 00        BRK $00
C0/8727: E5 00        SBC $00
C0/8729: 00 00        BRK $00
C0/872B: 00 00        BRK $00
C0/872D: 00 00        BRK $00
C0/872F: 91 0F        STA ($0F),Y
C0/8731: 03 00        ORA $00,S
C0/8733: 00 00        BRK $00
C0/8735: 00 00        BRK $00
C0/8737: C9 CB        CMP #$CB
C0/8739: 00 00        BRK $00
C0/873B: 00 00        BRK $00
C0/873D: 00 00        BRK $00
C0/873F: 45 79        EOR $79
C0/8741: 00 00        BRK $00
C0/8743: 00 00        BRK $00
C0/8745: 00 00        BRK $00
C0/8747: E9 00        SBC #$00
C0/8749: 00 00        BRK $00
C0/874B: 00 00        BRK $00
C0/874D: 00 00        BRK $00
C0/874F: EA           NOP 
C0/8750: 00 00        BRK $00
C0/8752: 00 00        BRK $00
C0/8754: 00 00        BRK $00
C0/8756: 00 73        BRK $73
C0/8758: 9B           TXY 
C0/8759: 00 00        BRK $00
C0/875B: 00 00        BRK $00
C0/875D: 00 00        BRK $00
C0/875F: 9B           TXY 
C0/8760: 02 00        COP $00
C0/8762: 00 00        BRK $00
C0/8764: 00 00        BRK $00
C0/8766: 00 70        BRK $70
C0/8768: AA           TAX 
C0/8769: 2A           ROL 
C0/876A: C5 00        CMP $00
C0/876C: 00 00        BRK $00
C0/876E: 00 86        BRK $86
C0/8770: D7 87        CMP [$87],Y
C0/8772: 62 A7 00     PER $881C
C0/8775: 00 00        BRK $00
C0/8777: 1C BD 85     TRB $85BD
C0/877A: 00 00        BRK $00
C0/877C: 00 00        BRK $00
C0/877E: 00 2B        BRK $2B
C0/8780: 0B           PHD 
C0/8781: D0 00        BNE $8783
C0/8783: 00 00        BRK $00
C0/8785: 00 00        BRK $00
C0/8787: 6B           RTL 
C0/8788: A7 00        LDA [$00]
C0/878A: 00 00        BRK $00
C0/878C: 00 00        BRK $00
C0/878E: 00 2C        BRK $2C
C0/8790: 02 0C        COP $0C
C0/8792: 00 00        BRK $00
C0/8794: 00 00        BRK $00
C0/8796: 00 0E        BRK $0E
C0/8798: 3D 6F 00     AND $006F,X
C0/879B: 00 00        BRK $00
C0/879D: 00 00        BRK $00
C0/879F: 8D 37 C3     STA $C337
C0/87A2: 89 00        BIT #$00
C0/87A4: 00 00        BRK $00
C0/87A6: 00 2B        BRK $2B
C0/87A8: E3 00        SBC $00,S
C0/87AA: 00 00        BRK $00
C0/87AC: 00 00        BRK $00
C0/87AE: 00 7F        BRK $7F
C0/87B0: 81 00        STA ($00,X)
C0/87B2: 00 00        BRK $00
C0/87B4: 00 00        BRK $00
C0/87B6: 00 7F        BRK $7F
C0/87B8: 9B           TXY 
C0/87B9: 00 00        BRK $00
C0/87BB: 00 00        BRK $00
C0/87BD: 00 00        BRK $00
C0/87BF: 9D 79 00     STA $0079,X
C0/87C2: 00 00        BRK $00
C0/87C4: 00 00        BRK $00
C0/87C6: 00 6F        BRK $6F
C0/87C8: 3F 75 8D 00  AND $008D75,X
C0/87CC: 00 00        BRK $00
C0/87CE: 00 6B        BRK $6B
C0/87D0: BD 7F 00     LDA $007F,X
C0/87D3: 00 00        BRK $00
C0/87D5: 00 00        BRK $00
C0/87D7: 7F C9 00 00  ADC $0000C9,X
C0/87DB: 00 00        BRK $00
C0/87DD: 00 00        BRK $00
C0/87DF: 95 E3        STA $E3,X
C0/87E1: 00 00        BRK $00
C0/87E3: 00 00        BRK $00
C0/87E5: 00 00        BRK $00
C0/87E7: 8D 93 8D     STA $8D93
C0/87EA: 6B           RTL 
C0/87EB: A7 93        LDA [$93]
C0/87ED: B9 3F 20     LDA $203F,Y
C0/87F0: 38           SEC 
C0/87F1: 9B           TXY 
C0/87F2: 61 35        ADC ($35,X)
C0/87F4: 9D 00 00     STA $0000,X
C0/87F7: 00 00        BRK $00
C0/87F9: 00 00        BRK $00
C0/87FB: 00 00        BRK $00
C0/87FD: 00 00        BRK $00
C0/87FF: 00 00        BRK $00
C0/8801: 00 00        BRK $00
C0/8803: 00 00        BRK $00
C0/8805: 00 00        BRK $00
C0/8807: 00 00        BRK $00
C0/8809: 00 00        BRK $00
C0/880B: 00 00        BRK $00
C0/880D: 00 00        BRK $00
C0/880F: 00 00        BRK $00
C0/8811: 00 00        BRK $00
C0/8813: 00 00        BRK $00
C0/8815: 00 00        BRK $00
C0/8817: 00 00        BRK $00
C0/8819: 00 00        BRK $00
C0/881B: 00 00        BRK $00
C0/881D: 00 00        BRK $00
C0/881F: 00 00        BRK $00
C0/8821: 00 00        BRK $00
C0/8823: 00 00        BRK $00
C0/8825: 00 00        BRK $00
C0/8827: 00 00        BRK $00
C0/8829: 00 00        BRK $00
C0/882B: 00 00        BRK $00
C0/882D: 00 00        BRK $00
C0/882F: 00 00        BRK $00
C0/8831: 00 00        BRK $00
C0/8833: 00 00        BRK $00
C0/8835: 00 00        BRK $00
C0/8837: 01 01        ORA ($01,X)
C0/8839: 00 00        BRK $00
C0/883B: 00 00        BRK $00
C0/883D: 00 00        BRK $00
C0/883F: 00 00        BRK $00
C0/8841: 00 00        BRK $00
C0/8843: 00 00        BRK $00
C0/8845: 00 00        BRK $00
C0/8847: 01 00        ORA ($00,X)
C0/8849: 01 01        ORA ($01,X)
C0/884B: 00 00        BRK $00
C0/884D: 00 00        BRK $00
C0/884F: 01 01        ORA ($01,X)
C0/8851: 00 00        BRK $00
C0/8853: 00 00        BRK $00
C0/8855: 00 00        BRK $00
C0/8857: 00 00        BRK $00
C0/8859: 00 00        BRK $00
C0/885B: 00 00        BRK $00
C0/885D: 00 00        BRK $00
C0/885F: 00 00        BRK $00
C0/8861: 00 00        BRK $00
C0/8863: 00 00        BRK $00
C0/8865: 00 00        BRK $00
C0/8867: 00 00        BRK $00
C0/8869: 00 00        BRK $00
C0/886B: 00 00        BRK $00
C0/886D: 00 00        BRK $00
C0/886F: 00 00        BRK $00
C0/8871: 00 00        BRK $00
C0/8873: 00 00        BRK $00
C0/8875: 00 00        BRK $00
C0/8877: 01 01        ORA ($01,X)
C0/8879: 00 00        BRK $00
C0/887B: 00 00        BRK $00
C0/887D: 00 00        BRK $00
C0/887F: 00 00        BRK $00
C0/8881: 00 00        BRK $00
C0/8883: 00 00        BRK $00
C0/8885: 00 00        BRK $00
C0/8887: 00 00        BRK $00
C0/8889: 00 00        BRK $00
C0/888B: 00 00        BRK $00
C0/888D: 00 00        BRK $00
C0/888F: 01 01        ORA ($01,X)
C0/8891: 00 00        BRK $00
C0/8893: 00 00        BRK $00
C0/8895: 00 00        BRK $00
C0/8897: 00 00        BRK $00
C0/8899: 00 00        BRK $00
C0/889B: 00 00        BRK $00
C0/889D: 00 00        BRK $00
C0/889F: 00 00        BRK $00
C0/88A1: 00 00        BRK $00
C0/88A3: 00 00        BRK $00
C0/88A5: 00 00        BRK $00
C0/88A7: 00 00        BRK $00
C0/88A9: 00 00        BRK $00
C0/88AB: 00 00        BRK $00
C0/88AD: 00 00        BRK $00
C0/88AF: 00 00        BRK $00
C0/88B1: 00 00        BRK $00
C0/88B3: 00 00        BRK $00
C0/88B5: 00 00        BRK $00
C0/88B7: 00 00        BRK $00
C0/88B9: 00 00        BRK $00
C0/88BB: 00 00        BRK $00
C0/88BD: 00 00        BRK $00
C0/88BF: 00 00        BRK $00
C0/88C1: 00 00        BRK $00
C0/88C3: 00 00        BRK $00
C0/88C5: 00 00        BRK $00
C0/88C7: 00 00        BRK $00
C0/88C9: 00 00        BRK $00
C0/88CB: 00 00        BRK $00
C0/88CD: 00 00        BRK $00
C0/88CF: 00 00        BRK $00
C0/88D1: 00 00        BRK $00
C0/88D3: 00 00        BRK $00
C0/88D5: 00 00        BRK $00
C0/88D7: 00 00        BRK $00
C0/88D9: 00 00        BRK $00
C0/88DB: 00 00        BRK $00
C0/88DD: 00 00        BRK $00
C0/88DF: 00 00        BRK $00
C0/88E1: 00 00        BRK $00
C0/88E3: 00 00        BRK $00
C0/88E5: 00 00        BRK $00
C0/88E7: 00 00        BRK $00
C0/88E9: 00 00        BRK $00
C0/88EB: 00 00        BRK $00
C0/88ED: 00 00        BRK $00
C0/88EF: 00 00        BRK $00
C0/88F1: 00 00        BRK $00
C0/88F3: 00 00        BRK $00
C0/88F5: 00 00        BRK $00
C0/88F7: 00 00        BRK $00
C0/88F9: 00 00        BRK $00
C0/88FB: 00 00        BRK $00
C0/88FD: 00 00        BRK $00
C0/88FF: 00 00        BRK $00
C0/8901: 00 00        BRK $00
C0/8903: 00 00        BRK $00
C0/8905: 00 00        BRK $00
C0/8907: 00 00        BRK $00
C0/8909: 00 00        BRK $00
C0/890B: 00 00        BRK $00
C0/890D: 00 00        BRK $00
C0/890F: 01 00        ORA ($00,X)
C0/8911: 01 00        ORA ($00,X)
C0/8913: 00 00        BRK $00
C0/8915: 00 00        BRK $00
C0/8917: 00 00        BRK $00
C0/8919: 00 00        BRK $00
C0/891B: 00 00        BRK $00
C0/891D: 00 00        BRK $00
C0/891F: 00 00        BRK $00
C0/8921: 00 00        BRK $00
C0/8923: 00 00        BRK $00
C0/8925: 00 00        BRK $00
C0/8927: 00 00        BRK $00
C0/8929: 00 00        BRK $00
C0/892B: 00 00        BRK $00
C0/892D: 00 00        BRK $00
C0/892F: 00 00        BRK $00
C0/8931: 00 00        BRK $00
C0/8933: 00 00        BRK $00
C0/8935: 00 00        BRK $00
C0/8937: 00 00        BRK $00
C0/8939: 00 00        BRK $00
C0/893B: 00 00        BRK $00
C0/893D: 00 00        BRK $00
C0/893F: 00 00        BRK $00
C0/8941: 00 00        BRK $00
C0/8943: 00 00        BRK $00
C0/8945: 00 00        BRK $00
C0/8947: 00 00        BRK $00
C0/8949: 00 00        BRK $00
C0/894B: 00 00        BRK $00
C0/894D: 00 00        BRK $00
C0/894F: 00 00        BRK $00
C0/8951: 00 00        BRK $00
C0/8953: 00 00        BRK $00
C0/8955: 00 00        BRK $00
C0/8957: 00 00        BRK $00
C0/8959: 00 00        BRK $00
C0/895B: 00 00        BRK $00
C0/895D: 00 00        BRK $00
C0/895F: 00 00        BRK $00
C0/8961: 00 00        BRK $00
C0/8963: 00 00        BRK $00
C0/8965: 00 00        BRK $00
C0/8967: 00 00        BRK $00
C0/8969: 00 00        BRK $00
C0/896B: 00 00        BRK $00
C0/896D: 00 00        BRK $00
C0/896F: 00 00        BRK $00
C0/8971: 00 00        BRK $00
C0/8973: 00 00        BRK $00
C0/8975: 00 00        BRK $00
C0/8977: 00 00        BRK $00
C0/8979: 00 00        BRK $00
C0/897B: 00 00        BRK $00
C0/897D: 00 00        BRK $00
C0/897F: 00 00        BRK $00
C0/8981: 00 00        BRK $00
C0/8983: 00 00        BRK $00
C0/8985: 00 00        BRK $00
C0/8987: 00 00        BRK $00
C0/8989: 00 00        BRK $00
C0/898B: 00 00        BRK $00
C0/898D: 00 00        BRK $00
C0/898F: 00 00        BRK $00
C0/8991: 00 00        BRK $00
C0/8993: 00 00        BRK $00
C0/8995: 00 00        BRK $00
C0/8997: 00 01        BRK $01
C0/8999: 01 00        ORA ($00,X)
C0/899B: 00 00        BRK $00
C0/899D: 00 00        BRK $00
C0/899F: 00 00        BRK $00
C0/89A1: 00 00        BRK $00
C0/89A3: 00 00        BRK $00
C0/89A5: 00 00        BRK $00
C0/89A7: 00 00        BRK $00
C0/89A9: 00 00        BRK $00
C0/89AB: 00 00        BRK $00
C0/89AD: 00 00        BRK $00
C0/89AF: 00 00        BRK $00
C0/89B1: 00 00        BRK $00
C0/89B3: 00 00        BRK $00
C0/89B5: 00 00        BRK $00
C0/89B7: 00 00        BRK $00
C0/89B9: 00 00        BRK $00
C0/89BB: 00 00        BRK $00
C0/89BD: 00 00        BRK $00
C0/89BF: 00 00        BRK $00
C0/89C1: 00 00        BRK $00
C0/89C3: 00 00        BRK $00
C0/89C5: 00 00        BRK $00
C0/89C7: 00 01        BRK $01
C0/89C9: 00 00        BRK $00
C0/89CB: 00 00        BRK $00
C0/89CD: 00 00        BRK $00
C0/89CF: 00 00        BRK $00
C0/89D1: 00 00        BRK $00
C0/89D3: 00 00        BRK $00
C0/89D5: 00 00        BRK $00
C0/89D7: 01 01        ORA ($01,X)
C0/89D9: 01 01        ORA ($01,X)
C0/89DB: 01 00        ORA ($00,X)
C0/89DD: 00 00        BRK $00
C0/89DF: 01 00        ORA ($00,X)
C0/89E1: 00 00        BRK $00
C0/89E3: 00 00        BRK $00
C0/89E5: 00 00        BRK $00
C0/89E7: 01 01        ORA ($01,X)
C0/89E9: 00 00        BRK $00
C0/89EB: 00 00        BRK $00
C0/89ED: 00 00        BRK $00
C0/89EF: 00 00        BRK $00
C0/89F1: 00 00        BRK $00
C0/89F3: 00 00        BRK $00
C0/89F5: 00 00        BRK $00
C0/89F7: 01 01        ORA ($01,X)
C0/89F9: 01 00        ORA ($00,X)
C0/89FB: 00 00        BRK $00
C0/89FD: 00 00        BRK $00
C0/89FF: 01 00        ORA ($00,X)
C0/8A01: 00 00        BRK $00
C0/8A03: 00 00        BRK $00
C0/8A05: 00 00        BRK $00
C0/8A07: 00 00        BRK $00
C0/8A09: 00 00        BRK $00
C0/8A0B: 00 00        BRK $00
C0/8A0D: 00 00        BRK $00
C0/8A0F: 00 00        BRK $00
C0/8A11: 00 00        BRK $00
C0/8A13: 00 00        BRK $00
C0/8A15: 00 00        BRK $00
C0/8A17: 00 00        BRK $00
C0/8A19: 00 00        BRK $00
C0/8A1B: 00 00        BRK $00
C0/8A1D: 00 00        BRK $00
C0/8A1F: 00 00        BRK $00
C0/8A21: 00 00        BRK $00
C0/8A23: 00 00        BRK $00
C0/8A25: 00 00        BRK $00
C0/8A27: 00 00        BRK $00
C0/8A29: 00 00        BRK $00
C0/8A2B: 00 00        BRK $00
C0/8A2D: 00 00        BRK $00
C0/8A2F: 00 00        BRK $00
C0/8A31: 00 00        BRK $00
C0/8A33: 00 00        BRK $00
C0/8A35: 00 00        BRK $00
C0/8A37: 00 00        BRK $00
C0/8A39: 00 00        BRK $00
C0/8A3B: 00 00        BRK $00
C0/8A3D: 00 00        BRK $00
C0/8A3F: 00 00        BRK $00
C0/8A41: 00 00        BRK $00
C0/8A43: 00 00        BRK $00
C0/8A45: 00 00        BRK $00
C0/8A47: 00 00        BRK $00
C0/8A49: 00 00        BRK $00
C0/8A4B: 00 00        BRK $00
C0/8A4D: 00 00        BRK $00
C0/8A4F: 00 00        BRK $00
C0/8A51: 00 00        BRK $00
C0/8A53: 00 00        BRK $00
C0/8A55: 00 00        BRK $00
C0/8A57: 02 02        COP $02
C0/8A59: 00 00        BRK $00
C0/8A5B: 00 00        BRK $00
C0/8A5D: 00 00        BRK $00

C0/8A5F: A6 B1        LDX $B1
C0/8A61: A4 AB        LDY $AB
C0/8A63: A9 01        LDA #$01
C0/8A65: 99 13 1A     STA $1A13,Y
C0/8A68: 80 09        BRA $8A73
C0/8A6A: A6 B1        LDX $B1
C0/8A6C: A4 AB        LDY $AB
C0/8A6E: A9 02        LDA #$02
C0/8A70: 99 13 1A     STA $1A13,Y
C0/8A73: BF 01 00 CA  LDA $CA0001,X
C0/8A77: 99 D3 19     STA $19D3,Y
C0/8A7A: C8           INY 
C0/8A7B: 84 AB        STY $AB
C0/8A7D: A4 B1        LDY $B1
C0/8A7F: C8           INY 
C0/8A80: 84 B1        STY $B1
C0/8A82: 4C 59 84     JMP $8459
C0/8A85: AD A3 16     LDA $16A3
C0/8A88: C2 20        REP #$20
C0/8A8A: 0A           ASL 
C0/8A8B: 85 0F        STA $0F
C0/8A8D: 0A           ASL 
C0/8A8E: 18           CLC 
C0/8A8F: 65 0F        ADC $0F
C0/8A91: AA           TAX 
C0/8A92: A5 06        LDA $06
C0/8A94: E2 20        SEP #$20
C0/8A96: 64 09        STZ $09
C0/8A98: BF 81 1C D1  LDA $D11C81,X
C0/8A9C: C9 FF        CMP #$FF
C0/8A9E: F0 12        BEQ $8AB2
C0/8AA0: 99 D3 19     STA $19D3,Y
C0/8AA3: A9 00        LDA #$00
C0/8AA5: 99 13 1A     STA $1A13,Y
C0/8AA8: C8           INY 
C0/8AA9: E8           INX 
C0/8AAA: E6 09        INC $09
C0/8AAC: A5 09        LDA $09
C0/8AAE: C9 06        CMP #$06
C0/8AB0: D0 E6        BNE $8A98
C0/8AB2: 84 AB        STY $AB
C0/8AB4: 4C 59 84     JMP $8459
C0/8AB7: AD A2 16     LDA $16A2
C0/8ABA: C2 20        REP #$20
C0/8ABC: 85 0F        STA $0F
C0/8ABE: 0A           ASL 
C0/8ABF: 0A           ASL 
C0/8AC0: 0A           ASL 
C0/8AC1: 18           CLC 
C0/8AC2: 65 0F        ADC $0F
C0/8AC4: AA           TAX 
C0/8AC5: A5 06        LDA $06
C0/8AC7: E2 20        SEP #$20
C0/8AC9: 64 09        STZ $09
C0/8ACB: BF 81 13 D1  LDA $D11381,X
C0/8ACF: C9 FF        CMP #$FF
C0/8AD1: F0 12        BEQ $8AE5
C0/8AD3: 99 D3 19     STA $19D3,Y
C0/8AD6: A9 00        LDA #$00
C0/8AD8: 99 13 1A     STA $1A13,Y
C0/8ADB: C8           INY 
C0/8ADC: E8           INX 
C0/8ADD: E6 09        INC $09
C0/8ADF: A5 09        LDA $09
C0/8AE1: C9 08        CMP #$08
C0/8AE3: D0 E6        BNE $8ACB
C0/8AE5: 84 AB        STY $AB
C0/8AE7: 4C 59 84     JMP $8459
C0/8AEA: 64 0C        STZ $0C
C0/8AEC: A6 06        LDX $06
C0/8AEE: A5 0C        LDA $0C
C0/8AF0: D0 07        BNE $8AF9
C0/8AF2: BD AD 10     LDA $10AD,X
C0/8AF5: F0 11        BEQ $8B08
C0/8AF7: E6 0C        INC $0C
C0/8AF9: BD AD 10     LDA $10AD,X
C0/8AFC: 18           CLC 
C0/8AFD: 69 53        ADC #$53
C0/8AFF: 99 D3 19     STA $19D3,Y
C0/8B02: A9 00        LDA #$00
C0/8B04: 99 13 1A     STA $1A13,Y
C0/8B07: C8           INY 
C0/8B08: E8           INX 
C0/8B09: E0 07 00     CPX #$0007
C0/8B0C: D0 E0        BNE $8AEE
C0/8B0E: 84 AB        STY $AB
C0/8B10: 4C 59 84     JMP $8459
C0/8B13: 93 84        STA ($84,S),Y
C0/8B15: AF 84 E9 84  LDA $84E984
C0/8B19: 0D 85 0D     ORA $0D85
C0/8B1C: 85 0D        STA $0D
C0/8B1E: 85 0D        STA $0D
C0/8B20: 85 0D        STA $0D
C0/8B22: 85 0D        STA $0D
C0/8B24: 85 0D        STA $0D
C0/8B26: 85 0D        STA $0D
C0/8B28: 85 0D        STA $0D
C0/8B2A: 85 66        STA $66
C0/8B2C: 84 0D        STY $0D
C0/8B2E: 85 0D        STA $0D
C0/8B30: 85 66        STA $66
C0/8B32: 84 EA        STY $EA
C0/8B34: 8A           TXA 
C0/8B35: B7 8A        LDA [$8A],Y
C0/8B37: 85 8A        STA $8A
C0/8B39: 0D 85 0D     ORA $0D85
C0/8B3C: 85 0D        STA $0D
C0/8B3E: 85 0D        STA $0D
C0/8B40: 85 77        STA $77
C0/8B42: 84 0D        STY $0D
C0/8B44: 85 0D        STA $0D
C0/8B46: 85 0D        STA $0D
C0/8B48: 85 0D        STA $0D
C0/8B4A: 85 0D        STA $0D
C0/8B4C: 85 0D        STA $0D
C0/8B4E: 85 5F        STA $5F
C0/8B50: 8A           TXA 
C0/8B51: 6A           ROR 
C0/8B52: 8A           TXA 
C0/8B53: A9 80        LDA #$80
C0/8B55: 8D 15 21     STA $2115
C0/8B58: A2 00 30     LDX #$3000
C0/8B5B: 8E 16 21     STX $2116
C0/8B5E: C2 20        REP #$20
C0/8B60: A2 00 00     LDX #$0000
C0/8B63: A9 FF 00     LDA #$00FF
C0/8B66: 8D 18 21     STA $2118
C0/8B69: 8D 18 21     STA $2118
C0/8B6C: 8D 18 21     STA $2118
C0/8B6F: 8D 18 21     STA $2118
C0/8B72: 8D 18 21     STA $2118
C0/8B75: 8D 18 21     STA $2118
C0/8B78: 8D 18 21     STA $2118
C0/8B7B: 8D 18 21     STA $2118
C0/8B7E: A9 00 00     LDA #$0000
C0/8B81: 8D 18 21     STA $2118
C0/8B84: 8D 18 21     STA $2118
C0/8B87: 8D 18 21     STA $2118
C0/8B8A: 8D 18 21     STA $2118
C0/8B8D: 8D 18 21     STA $2118
C0/8B90: 8D 18 21     STA $2118
C0/8B93: 8D 18 21     STA $2118
C0/8B96: 8D 18 21     STA $2118
C0/8B99: E8           INX 
C0/8B9A: E0 D0 00     CPX #$00D0
C0/8B9D: D0 C4        BNE $8B63
C0/8B9F: A5 06        LDA $06
C0/8BA1: E2 20        SEP #$20
C0/8BA3: 60           RTS 

C0/8BA4: A9 80        LDA #$80
C0/8BA6: 8D 15 21     STA $2115
C0/8BA9: 9C 0B 42     STZ $420B
C0/8BAC: A9 08        LDA #$08
C0/8BAE: 8D 00 43     STA $4300
C0/8BB1: A9 19        LDA #$19
C0/8BB3: 8D 01 43     STA $4301
C0/8BB6: A2 00 30     LDX #$3000
C0/8BB9: 8E 16 21     STX $2116
C0/8BBC: 64 6D        STZ $6D
C0/8BBE: A2 6D 0B     LDX #$0B6D
C0/8BC1: 8E 02 43     STX $4302
C0/8BC4: 9C 04 43     STZ $4304
C0/8BC7: A2 00 0D     LDX #$0D00
C0/8BCA: 8E 05 43     STX $4305
C0/8BCD: A9 01        LDA #$01
C0/8BCF: 8D 0B 42     STA $420B
C0/8BD2: 60           RTS 

C0/8BD3: A6 06        LDX $06
C0/8BD5: BF 8A 6A 7F  LDA $7F6A8A,X
C0/8BD9: 9F 59 6A 7F  STA $7F6A59,X
C0/8BDD: E8           INX 
C0/8BDE: E0 31 00     CPX #$0031
C0/8BE1: D0 F2        BNE $8BD5
C0/8BE3: 60           RTS 
C0/8BE4: A5 B4        LDA $B4
C0/8BE6: 0A           ASL 
C0/8BE7: 18           CLC 
C0/8BE8: 65 B4        ADC $B4
C0/8BEA: AA           TAX 
C0/8BEB: A5 B5        LDA $B5
C0/8BED: F0 1B        BEQ $8C0A
C0/8BEF: A8           TAY 
C0/8BF0: C2 20        REP #$20
C0/8BF2: A9 EC 6A     LDA #$6AEC
C0/8BF5: 9F 8B 6A 7F  STA $7F6A8B,X
C0/8BF9: A9 6C 6D     LDA #$6D6C
C0/8BFC: 9F BC 6A 7F  STA $7F6ABC,X
C0/8C00: E8           INX 
C0/8C01: E8           INX 
C0/8C02: E8           INX 
C0/8C03: 88           DEY 
C0/8C04: D0 EC        BNE $8BF2
C0/8C06: A5 06        LDA $06
C0/8C08: E2 20        SEP #$20
C0/8C0A: A9 05        LDA #$05
C0/8C0C: 38           SEC 
C0/8C0D: E5 B5        SBC $B5
C0/8C0F: F0 1C        BEQ $8C2D
C0/8C11: A8           TAY 
C0/8C12: C2 20        REP #$20
C0/8C14: BF 5A 6A 7F  LDA $7F6A5A,X
C0/8C18: 9F 8B 6A 7F  STA $7F6A8B,X
C0/8C1C: A9 7C 6D     LDA #$6D7C
C0/8C1F: 9F BC 6A 7F  STA $7F6ABC,X
C0/8C23: E8           INX 
C0/8C24: E8           INX 
C0/8C25: E8           INX 
C0/8C26: 88           DEY 
C0/8C27: D0 EB        BNE $8C14
C0/8C29: A5 06        LDA $06
C0/8C2B: E2 20        SEP #$20
C0/8C2D: 60           RTS 

; [ init hdma #1 (window 2 position) ]

C0/8C2E: A9 41        LDA #$41
C0/8C30: 8D 10 43     STA $4310
C0/8C33: A9 28        LDA #$28
C0/8C35: 8D 11 43     STA $4311
C0/8C38: A2 8A 6A     LDX #$6A8A
C0/8C3B: 8E 12 43     STX $4312
C0/8C3E: A9 7F        LDA #$7F
C0/8C40: 8D 14 43     STA $4314
C0/8C43: 8D 17 43     STA $4317
C0/8C46: A2 8C 6B     LDX #$6B8C
C0/8C49: 86 23        STX $23
C0/8C4B: A6 06        LDX $06
C0/8C4D: A9 90        LDA #$90
C0/8C4F: 9F 8A 6A 7F  STA $7F6A8A,X
C0/8C53: C2 20        REP #$20
C0/8C55: A5 23        LDA $23
C0/8C57: 9F 8B 6A 7F  STA $7F6A8B,X
C0/8C5B: 18           CLC 
C0/8C5C: 69 20 00     ADC #$0020
C0/8C5F: 85 23        STA $23
C0/8C61: A5 06        LDA $06
C0/8C63: E2 20        SEP #$20
C0/8C65: E8           INX 
C0/8C66: E8           INX 
C0/8C67: E8           INX 
C0/8C68: E0 2A 00     CPX #$002A
C0/8C6B: D0 E0        BNE $8C4D
C0/8C6D: A9 8F        LDA #$8F
C0/8C6F: 8F 8A 6A 7F  STA $7F6A8A
C0/8C73: A5 55        LDA $55
C0/8C75: D0 03        BNE $8C7A
C0/8C77: 20 7B 8C     JSR $8C7B
C0/8C7A: 60           RTS 

C0/8C7B: C2 20        REP #$20
C0/8C7D: A6 06        LDX $06
C0/8C7F: A9 FF 00     LDA #$00FF
C0/8C82: 9F 6C 6B 7F  STA $7F6B6C,X
C0/8C86: E8           INX 
C0/8C87: E8           INX 
C0/8C88: E0 00 02     CPX #$0200
C0/8C8B: D0 F5        BNE $8C82
C0/8C8D: A5 06        LDA $06
C0/8C8F: E2 20        SEP #$20
C0/8C91: 60           RTS 
C0/8C92: A6 06        LDX $06
C0/8C94: A9 90        LDA #$90
C0/8C96: 9F 8A 6A 7F  STA $7F6A8A,X
C0/8C9A: A9 0C        LDA #$0C
C0/8C9C: 9F 8B 6A 7F  STA $7F6A8B,X
C0/8CA0: A9 6B        LDA #$6B
C0/8CA2: 9F 8C 6A 7F  STA $7F6A8C,X
C0/8CA6: A9 90        LDA #$90
C0/8CA8: 9F BB 6A 7F  STA $7F6ABB,X
C0/8CAC: A9 7C        LDA #$7C
C0/8CAE: 9F BC 6A 7F  STA $7F6ABC,X
C0/8CB2: A9 6D        LDA #$6D
C0/8CB4: 9F BD 6A 7F  STA $7F6ABD,X
C0/8CB8: E8           INX 
C0/8CB9: E8           INX 
C0/8CBA: E8           INX 
C0/8CBB: E0 2D 00     CPX #$002D
C0/8CBE: D0 D4        BNE $8C94
C0/8CC0: A9 80        LDA #$80
C0/8CC2: 9F 8A 6A 7F  STA $7F6A8A,X
C0/8CC6: 9F BB 6A 7F  STA $7F6ABB,X
C0/8CCA: A9 8F        LDA #$8F
C0/8CCC: 8F 8A 6A 7F  STA $7F6A8A
C0/8CD0: 8F BB 6A 7F  STA $7F6ABB
C0/8CD4: A6 06        LDX $06
C0/8CD6: A9 FF        LDA #$FF
C0/8CD8: 9F 0C 6B 7F  STA $7F6B0C,X
C0/8CDC: A9 00        LDA #$00
C0/8CDE: 9F 0D 6B 7F  STA $7F6B0D,X
C0/8CE2: A9 10        LDA #$10
C0/8CE4: 9F EC 6A 7F  STA $7F6AEC,X
C0/8CE8: A9 EF        LDA #$EF
C0/8CEA: 9F ED 6A 7F  STA $7F6AED,X
C0/8CEE: A9 90        LDA #$90
C0/8CF0: 9F 2C 6B 7F  STA $7F6B2C,X
C0/8CF4: A9 F0        LDA #$F0
C0/8CF6: 9F 2D 6B 7F  STA $7F6B2D,X
C0/8CFA: A9 10        LDA #$10
C0/8CFC: 9F 4C 6B 7F  STA $7F6B4C,X
C0/8D00: A9 60        LDA #$60
C0/8D02: 9F 4D 6B 7F  STA $7F6B4D,X
C0/8D06: E8           INX 
C0/8D07: E8           INX 
C0/8D08: E0 20 00     CPX #$0020
C0/8D0B: D0 C9        BNE $8CD6
C0/8D0D: 60           RTS 
C0/8D0E: A6 06        LDX $06
C0/8D10: A9 BB        LDA #$BB
C0/8D12: 9F 6C 6D 7F  STA $7F6D6C,X
C0/8D16: A9 33        LDA #$33
C0/8D18: 9F 7C 6D 7F  STA $7F6D7C,X
C0/8D1C: E8           INX 
C0/8D1D: E0 10 00     CPX #$0010
C0/8D20: D0 EE        BNE $8D10
C0/8D22: A9 40        LDA #$40
C0/8D24: 8D 20 43     STA $4320
C0/8D27: A9 25        LDA #$25
C0/8D29: 8D 21 43     STA $4321
C0/8D2C: A2 BB 6A     LDX #$6ABB
C0/8D2F: 8E 22 43     STX $4322
C0/8D32: A9 7F        LDA #$7F
C0/8D34: 8D 24 43     STA $4324
C0/8D37: 8D 27 43     STA $4327
C0/8D3A: 60           RTS 
C0/8D3B: 20 08 8E     JSR $8E08
C0/8D3E: A4 AB        LDY $AB
C0/8D40: B9 13 1A     LDA $1A13,Y
C0/8D43: F0 03        BEQ $8D48
C0/8D45: 4C E1 8D     JMP $8DE1
C0/8D48: B9 D3 19     LDA $19D3,Y
C0/8D4B: C9 0C        CMP #$0C
C0/8D4D: D0 05        BNE $8D54
C0/8D4F: A2 3C 00     LDX #$003C
C0/8D52: 80 15        BRA $8D69
C0/8D54: C9 17        CMP #$17
C0/8D56: D0 2B        BNE $8D83
C0/8D58: C8           INY 
C0/8D59: B9 D3 19     LDA $19D3,Y
C0/8D5C: C2 20        REP #$20
C0/8D5E: 0A           ASL 
C0/8D5F: 0A           ASL 
C0/8D60: 0A           ASL 
C0/8D61: 0A           ASL 
C0/8D62: 0A           ASL 
C0/8D63: 0A           ASL 
C0/8D64: AA           TAX 
C0/8D65: A5 06        LDA $06
C0/8D67: E2 20        SEP #$20
C0/8D69: 86 AD        STX $AD
C0/8D6B: C8           INY 
C0/8D6C: 84 AB        STY $AB
C0/8D6E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/8D71: 20 7C 23     JSR $237C       ; update party sprite
C0/8D74: 20 B3 39     JSR $39B3       ; update object sprites
C0/8D77: 20 42 28     JSR $2842
C0/8D7A: A6 AD        LDX $AD
C0/8D7C: CA           DEX 
C0/8D7D: 86 AD        STX $AD
C0/8D7F: D0 ED        BNE $8D6E
C0/8D81: 80 BB        BRA $8D3E
C0/8D83: C9 0F        CMP #$0F
C0/8D85: D0 07        BNE $8D8E
C0/8D87: E6 B8        INC $B8
C0/8D89: C8           INY 
C0/8D8A: 84 AB        STY $AB
C0/8D8C: 80 B0        BRA $8D3E
C0/8D8E: C9 00        CMP #$00
C0/8D90: D0 07        BNE $8D99
C0/8D92: A9 40        LDA #$40
C0/8D94: 85 AB        STA $AB
C0/8D96: 4C 07 8E     JMP $8E07
C0/8D99: C9 01        CMP #$01
C0/8D9B: D0 44        BNE $8DE1
C0/8D9D: A5 A8        LDA $A8
C0/8D9F: F0 19        BEQ $8DBA
C0/8DA1: E6 A7        INC $A7
C0/8DA3: 20 41 4E     JSR $4E41       ; wait for vblank
C0/8DA6: 20 7C 23     JSR $237C       ; update party sprite
C0/8DA9: 20 B3 39     JSR $39B3       ; update object sprites
C0/8DAC: 20 42 28     JSR $2842
C0/8DAF: A5 A8        LDA $A8
C0/8DB1: 18           CLC 
C0/8DB2: 69 0D        ADC #$0D
C0/8DB4: 85 A8        STA $A8
C0/8DB6: C9 10        CMP #$10
C0/8DB8: 90 E3        BCC $8D9D
C0/8DBA: 64 A8        STZ $A8
C0/8DBC: A4 AB        LDY $AB
C0/8DBE: 98           TYA 
C0/8DBF: 29 F0        AND #$F0
C0/8DC1: 18           CLC 
C0/8DC2: 69 10        ADC #$10
C0/8DC4: 85 AB        STA $AB
C0/8DC6: C9 40        CMP #$40
C0/8DC8: F0 3D        BEQ $8E07
C0/8DCA: 4A           LSR 
C0/8DCB: 4A           LSR 
C0/8DCC: 4A           LSR 
C0/8DCD: AA           TAX 
C0/8DCE: BF 1B 8E C0  LDA $C08E1B,X
C0/8DD2: 8D A9 0B     STA $0BA9
C0/8DD5: BF 1C 8E C0  LDA $C08E1C,X
C0/8DD9: 8D AA 0B     STA $0BAA
C0/8DDC: 80 29        BRA $8E07
C0/8DDE: 4C 3E 8D     JMP $8D3E
C0/8DE1: B9 13 1A     LDA $1A13,Y
C0/8DE4: EB           XBA 
C0/8DE5: B9 D3 19     LDA $19D3,Y
C0/8DE8: C8           INY 
C0/8DE9: 84 AB        STY $AB
C0/8DEB: 20 01 8F     JSR $8F01
C0/8DEE: A5 A8        LDA $A8
C0/8DF0: 20 D3 8E     JSR $8ED3
C0/8DF3: A5 A8        LDA $A8
C0/8DF5: 18           CLC 
C0/8DF6: 69 0D        ADC #$0D
C0/8DF8: 85 A8        STA $A8
C0/8DFA: C9 10        CMP #$10
C0/8DFC: B0 03        BCS $8E01
C0/8DFE: 4C 3E 8D     JMP $8D3E
C0/8E01: 29 0F        AND #$0F
C0/8E03: 85 A8        STA $A8
C0/8E05: E6 A7        INC $A7
C0/8E07: 60           RTS 
C0/8E08: A2 00 00     LDX #$0000
C0/8E0B: BD BB 19     LDA $19BB,X
C0/8E0E: 9D A3 19     STA $19A3,X
C0/8E11: 9E BB 19     STZ $19BB,X
C0/8E14: E8           INX 
C0/8E15: E0 18 00     CPX #$0018
C0/8E18: D0 F1        BNE $8E0B
C0/8E1A: 60           RTS 
C0/8E1B: 00 30        BRK $30
C0/8E1D: 40           RTI 
C0/8E1E: 33 80        AND ($80,S),Y
C0/8E20: 36 C0        ROL $C0,X
C0/8E22: 39 64 A7     AND $A764,Y
C0/8E25: A9 80        LDA #$80
C0/8E27: 8D 15 21     STA $2115
C0/8E2A: 9C 0B 42     STZ $420B
C0/8E2D: A9 00        LDA #$00
C0/8E2F: 8D 00 43     STA $4300
C0/8E32: A9 19        LDA #$19
C0/8E34: 8D 01 43     STA $4301
C0/8E37: A9 00        LDA #$00
C0/8E39: 8D 04 43     STA $4304
C0/8E3C: C2 20        REP #$20
C0/8E3E: A5 A9        LDA $A9
C0/8E40: 18           CLC 
C0/8E41: 69 02 00     ADC #$0002
C0/8E44: 85 A9        STA $A9
C0/8E46: 8D 16 21     STA $2116
C0/8E49: A5 06        LDA $06
C0/8E4B: E2 20        SEP #$20
C0/8E4D: A2 A3 19     LDX #$19A3
C0/8E50: 8E 02 43     STX $4302
C0/8E53: A2 06 00     LDX #$0006
C0/8E56: 8E 05 43     STX $4305
C0/8E59: A9 01        LDA #$01
C0/8E5B: 8D 0B 42     STA $420B
C0/8E5E: C2 20        REP #$20
C0/8E60: A5 A9        LDA $A9
C0/8E62: 18           CLC 
C0/8E63: 69 0E 00     ADC #$000E
C0/8E66: 85 A9        STA $A9
C0/8E68: 8D 16 21     STA $2116
C0/8E6B: A5 06        LDA $06
C0/8E6D: E2 20        SEP #$20
C0/8E6F: A2 A9 19     LDX #$19A9
C0/8E72: 8E 02 43     STX $4302
C0/8E75: A2 06 00     LDX #$0006
C0/8E78: 8E 05 43     STX $4305
C0/8E7B: A9 01        LDA #$01
C0/8E7D: 8D 0B 42     STA $420B
C0/8E80: C2 20        REP #$20
C0/8E82: A5 A9        LDA $A9
C0/8E84: 18           CLC 
C0/8E85: 69 12 00     ADC #$0012
C0/8E88: 85 A9        STA $A9
C0/8E8A: 8D 16 21     STA $2116
C0/8E8D: A5 06        LDA $06
C0/8E8F: E2 20        SEP #$20
C0/8E91: A2 AF 19     LDX #$19AF
C0/8E94: 8E 02 43     STX $4302
C0/8E97: A2 06 00     LDX #$0006
C0/8E9A: 8E 05 43     STX $4305
C0/8E9D: A9 01        LDA #$01
C0/8E9F: 8D 0B 42     STA $420B
C0/8EA2: C2 20        REP #$20
C0/8EA4: A5 A9        LDA $A9
C0/8EA6: 18           CLC 
C0/8EA7: 69 0E 00     ADC #$000E
C0/8EAA: 85 A9        STA $A9
C0/8EAC: 8D 16 21     STA $2116
C0/8EAF: A5 06        LDA $06
C0/8EB1: E2 20        SEP #$20
C0/8EB3: A2 B5 19     LDX #$19B5
C0/8EB6: 8E 02 43     STX $4302
C0/8EB9: A2 06 00     LDX #$0006
C0/8EBC: 8E 05 43     STX $4305
C0/8EBF: A9 01        LDA #$01
C0/8EC1: 8D 0B 42     STA $420B
C0/8EC4: C2 20        REP #$20
C0/8EC6: A5 A9        LDA $A9
C0/8EC8: 18           CLC 
C0/8EC9: 69 10 00     ADC #$0010
C0/8ECC: 85 A9        STA $A9
C0/8ECE: A5 06        LDA $06
C0/8ED0: E2 20        SEP #$20
C0/8ED2: 60           RTS 

C0/8ED3: C9 00        CMP #$00
C0/8ED5: F0 1A        BEQ $8EF1
C0/8ED7: 48           PHA 
C0/8ED8: A2 00 00     LDX #$0000
C0/8EDB: 5E 73 19     LSR $1973,X
C0/8EDE: 7E 7F 19     ROR $197F,X
C0/8EE1: 7E 8B 19     ROR $198B,X
C0/8EE4: 7E 97 19     ROR $1997,X
C0/8EE7: E8           INX 
C0/8EE8: E0 0C 00     CPX #$000C
C0/8EEB: D0 EE        BNE $8EDB
C0/8EED: 68           PLA 
C0/8EEE: 3A           DEC 
C0/8EEF: D0 E6        BNE $8ED7
C0/8EF1: A2 30 00     LDX #$0030
C0/8EF4: BD A2 19     LDA $19A2,X
C0/8EF7: 1D 72 19     ORA $1972,X
C0/8EFA: 9D A2 19     STA $19A2,X
C0/8EFD: CA           DEX 
C0/8EFE: D0 F4        BNE $8EF4
C0/8F00: 60           RTS 

; [  ]

C0/8F01: C2 20        REP #$20
C0/8F03: C9 00 01     CMP #$0100
C0/8F06: B0 24        BCS $8F2C
C0/8F08: 0A           ASL 
C0/8F09: 0A           ASL 
C0/8F0A: 0A           ASL 
C0/8F0B: 85 0D        STA $0D
C0/8F0D: 0A           ASL 
C0/8F0E: 18           CLC 
C0/8F0F: 65 0D        ADC $0D
C0/8F11: AA           TAX 
C0/8F12: A5 06        LDA $06
C0/8F14: E2 20        SEP #$20
C0/8F16: A4 06        LDY $06
C0/8F18: BF 00 E8 C3  LDA $C3E800,X
C0/8F1C: 99 73 19     STA $1973,Y
C0/8F1F: A9 00        LDA #$00
C0/8F21: 99 8B 19     STA $198B,Y
C0/8F24: E8           INX 
C0/8F25: C8           INY 
C0/8F26: C0 18 00     CPY #$0018
C0/8F29: D0 ED        BNE $8F18
C0/8F2B: 60           RTS 
C0/8F2C: 38           SEC 
C0/8F2D: E9 00 01     SBC #$01
C0/8F30: 0A           ASL 
C0/8F31: 0A           ASL 
C0/8F32: 0A           ASL 
C0/8F33: 85 0D        STA $0D
C0/8F35: 0A           ASL 
C0/8F36: 18           CLC 
C0/8F37: 65 0D        ADC $0D
C0/8F39: AA           TAX 
C0/8F3A: A5 06        LDA $06
C0/8F3C: E2 20        SEP #$20
C0/8F3E: A4 06        LDY $06
C0/8F40: BF 00 D0 DB  LDA $DBD000,X
C0/8F44: 99 73 19     STA $1973,Y
C0/8F47: A9 00        LDA #$00
C0/8F49: 99 8B 19     STA $198B,Y
C0/8F4C: E8           INX 
C0/8F4D: C8           INY 
C0/8F4E: C0 18 00     CPY #$0018
C0/8F51: D0 ED        BNE $8F40
C0/8F53: 60           RTS 

; [  ]

C0/8F54: 64 A8        STZ $A8
C0/8F56: A2 00 30     LDX #$3000
C0/8F59: 86 A9        STX $A9
C0/8F5B: A2 00 00     LDX #$0000
C0/8F5E: 9E A3 19     STZ $19A3,X
C0/8F61: E8           INX 
C0/8F62: E0 30 00     CPX #$0030
C0/8F65: D0 F7        BNE $8F5E
C0/8F67: A6 06        LDX $06
C0/8F69: A9 FF        LDA #$FF
C0/8F6B: 9D D3 19     STA $19D3,X
C0/8F6E: 9E 13 1A     STZ $1A13,X
C0/8F71: E8           INX 
C0/8F72: E0 40 00     CPX #$0040
C0/8F75: D0 F2        BNE $8F69
C0/8F77: 60           RTS 

; [ draw yes/no indicator ]

C0/8F78: AD 97 16     LDA $1697
C0/8F7B: 10 5F        BPL $8FDC
C0/8F7D: 29 01        AND #$01
C0/8F7F: 0A           ASL 
C0/8F80: 0A           ASL 
C0/8F81: 0A           ASL 
C0/8F82: AA           TAX 
C0/8F83: A9 00        LDA #$00
C0/8F85: 8D 15 21     STA $2115
C0/8F88: A9 04        LDA #$04
C0/8F8A: 85 19        STA $19
C0/8F8C: AC 98 16     LDY $1698
C0/8F8F: 84 1B        STY $1B
C0/8F91: A4 1B        LDY $1B
C0/8F93: 8C 16 21     STY $2116
C0/8F96: BF DD 8F C0  LDA $C08FDD,X
C0/8F9A: 8D 18 21     STA $2118
C0/8F9D: E8           INX 
C0/8F9E: C8           INY 
C0/8F9F: 98           TYA 
C0/8FA0: C2 20        REP #$20
C0/8FA2: 29 1F 00     AND #$001F
C0/8FA5: D0 0B        BNE $8FB2
C0/8FA7: 98           TYA 
C0/8FA8: 38           SEC 
C0/8FA9: E9 20 00     SBC #$0020
C0/8FAC: 49 00 04     EOR #$0400
C0/8FAF: 8D 16 21     STA $2116
C0/8FB2: A5 06        LDA $06
C0/8FB4: E2 20        SEP #$20
C0/8FB6: BF DD 8F C0  LDA $C08FDD,X
C0/8FBA: 8D 18 21     STA $2118
C0/8FBD: E8           INX 
C0/8FBE: C2 20        REP #$20
C0/8FC0: A5 1B        LDA $1B
C0/8FC2: 18           CLC 
C0/8FC3: 69 20 00     ADC #$0020
C0/8FC6: 29 FF 03     AND #$03FF
C0/8FC9: 85 17        STA $17
C0/8FCB: A5 1B        LDA $1B
C0/8FCD: 29 00 FC     AND #$FC00
C0/8FD0: 05 17        ORA $17
C0/8FD2: 85 1B        STA $1B
C0/8FD4: A5 06        LDA $06
C0/8FD6: E2 20        SEP #$20
C0/8FD8: C6 19        DEC $19
C0/8FDA: D0 B5        BNE $8F91
C0/8FDC: 60           RTS 

C0/8FDD: D9 DA DB DC D0 D0 D0 D0
C0/8FE5: D0 D0 D0 D0 D9 DA DB DC

; [ show yes/no window ]

C0/8FED: AD D9 0A     LDA $0AD9
C0/8FF0: 1A           INC 
C0/8FF1: 85 76        STA $76
C0/8FF3: AD D8 0A     LDA $0AD8
C0/8FF6: 38           SEC 
C0/8FF7: E9 06        SBC #$06
C0/8FF9: 85 75        STA $75
C0/8FFB: C2 20        REP #$20
C0/8FFD: A5 75        LDA $75
C0/8FFF: 29 10 00     AND #$0010
C0/9002: F0 03        BEQ $9007
C0/9004: A9 00 04     LDA #$0400
C0/9007: 85 23        STA $23
C0/9009: A5 76        LDA $76
C0/900B: 29 0F 00     AND #$000F
C0/900E: EB           XBA 
C0/900F: 4A           LSR 
C0/9010: 4A           LSR 
C0/9011: 18           CLC 
C0/9012: 69 20 00     ADC #$0020
C0/9015: 18           CLC 
C0/9016: 65 23        ADC $23
C0/9018: 85 23        STA $23
C0/901A: A5 75        LDA $75
C0/901C: 29 0F 00     AND #$000F
C0/901F: 0A           ASL 
C0/9020: 38           SEC 
C0/9021: 65 23        ADC $23
C0/9023: 18           CLC 
C0/9024: 69 00 48     ADC #$4800
C0/9027: 8D 98 16     STA $1698
C0/902A: A5 06        LDA $06
C0/902C: E2 20        SEP #$20
C0/902E: A9 08        LDA #$08
C0/9030: 38           SEC 
C0/9031: 6D D9 0A     ADC $0AD9
C0/9034: 85 76        STA $76
C0/9036: AD D8 0A     LDA $0AD8
C0/9039: 85 75        STA $75
C0/903B: 64 B7        STZ $B7
C0/903D: 20 41 4E     JSR $4E41       ; wait for vblank
C0/9040: A9 01        LDA #$01
C0/9042: A6 06        LDX $06
C0/9044: 86 71        STX $71
C0/9046: 20 7D 70     JSR $707D
C0/9049: A5 B7        LDA $B7
C0/904B: C2 20        REP #$20
C0/904D: 0A           ASL 
C0/904E: 0A           ASL 
C0/904F: 85 0D        STA $0D
C0/9051: 0A           ASL 
C0/9052: 0A           ASL 
C0/9053: 18           CLC 
C0/9054: 65 0D        ADC $0D
C0/9056: AA           TAX 
C0/9057: A5 06        LDA $06
C0/9059: E2 20        SEP #$20
C0/905B: A0 04 00     LDY #$0004
C0/905E: BF F7 90 C0  LDA $C090F7,X
C0/9062: 99 F3 16     STA $16F3,Y
C0/9065: A9 03        LDA #$03
C0/9067: 99 F4 16     STA $16F4,Y
C0/906A: BF 01 91 C0  LDA $C09101,X
C0/906E: 99 33 17     STA $1733,Y
C0/9071: A9 03        LDA #$03
C0/9073: 99 34 17     STA $1734,Y
C0/9076: E8           INX 
C0/9077: C8           INY 
C0/9078: C8           INY 
C0/9079: C0 18 00     CPY #$0018
C0/907C: D0 E0        BNE $905E
C0/907E: A5 B7        LDA $B7
C0/9080: 0A           ASL 
C0/9081: 18           CLC 
C0/9082: 65 B7        ADC $B7
C0/9084: 18           CLC 
C0/9085: 69 18        ADC #$18
C0/9087: AA           TAX 
C0/9088: A9 4C        LDA #$4C
C0/908A: 9F 8B 6A 7F  STA $7F6A8B,X
C0/908E: A9 6B        LDA #$6B
C0/9090: 9F 8C 6A 7F  STA $7F6A8C,X
C0/9094: A9 6C        LDA #$6C
C0/9096: 9F BC 6A 7F  STA $7F6ABC,X
C0/909A: A9 6D        LDA #$6D
C0/909C: 9F BD 6A 7F  STA $7F6ABD,X
C0/90A0: E6 A6        INC $A6
C0/90A2: E6 76        INC $76
C0/90A4: E6 B7        INC $B7
C0/90A6: A5 B7        LDA $B7
C0/90A8: C9 03        CMP #$03
C0/90AA: D0 91        BNE $903D
C0/90AC: 60           RTS 
C0/90AD: A9 0A        LDA #$0A
C0/90AF: 38           SEC 
C0/90B0: 6D D9 0A     ADC $0AD9
C0/90B3: 85 76        STA $76
C0/90B5: AD D8 0A     LDA $0AD8
C0/90B8: 85 75        STA $75
C0/90BA: 20 41 4E     JSR $4E41       ; wait for vblank
C0/90BD: A9 01        LDA #$01
C0/90BF: A6 06        LDX $06
C0/90C1: 86 71        STX $71
C0/90C3: 20 7D 70     JSR $707D
C0/90C6: E6 A6        INC $A6
C0/90C8: A5 B7        LDA $B7
C0/90CA: 0A           ASL 
C0/90CB: 18           CLC 
C0/90CC: 65 B7        ADC $B7
C0/90CE: 18           CLC 
C0/90CF: 69 15        ADC #$15
C0/90D1: AA           TAX 
C0/90D2: BF 5A 6A 7F  LDA $7F6A5A,X
C0/90D6: 9F 8B 6A 7F  STA $7F6A8B,X
C0/90DA: BF 5B 6A 7F  LDA $7F6A5B,X
C0/90DE: 9F 8C 6A 7F  STA $7F6A8C,X
C0/90E2: A9 7C        LDA #$7C
C0/90E4: 9F BC 6A 7F  STA $7F6ABC,X
C0/90E8: A9 6D        LDA #$6D
C0/90EA: 9F BD 6A 7F  STA $7F6ABD,X
C0/90EE: C6 76        DEC $76
C0/90F0: C6 B7        DEC $B7
C0/90F2: A5 B7        LDA $B7
C0/90F4: D0 C4        BNE $90BA
C0/90F6: 60           RTS 

; tile data for yes/no window
C0/90F7: D1 D7 D7 D7 D7 D7 D7 D7 D7 D2
C0/9101: D5 D9 DA D0 EA EB EC ED D0 D6
C0/910B: D5 DB DC D0 FA FB FC FD D0 D6
C0/9115: D5 D0 D0 EC ED EC ED EE EF D6
C0/911F: D5 D0 D0 FC FD FC FD FE FF D6
C0/9129: D3 D8 D8 D8 D8 D8 D8 D8 D8 D4 

; [ show gp window ]

C0/9133: A9 06        LDA #$06
C0/9135: 38           SEC 
C0/9136: 6D D9 0A     ADC $0AD9       ; y position
C0/9139: 85 76        STA $76
C0/913B: AD D8 0A     LDA $0AD8       ; x position
C0/913E: 85 75        STA $75
C0/9140: 64 B6        STZ $B6
C0/9142: 20 41 4E     JSR $4E41       ; wait for vblank
C0/9145: A9 01        LDA #$01
C0/9147: A6 06        LDX $06
C0/9149: 86 71        STX $71
C0/914B: 20 7D 70     JSR $707D
C0/914E: A5 B6        LDA $B6
C0/9150: C2 20        REP #$20
C0/9152: 0A           ASL 
C0/9153: 0A           ASL 
C0/9154: 0A           ASL 
C0/9155: 85 0D        STA $0D
C0/9157: 0A           ASL 
C0/9158: 18           CLC 
C0/9159: 65 0D        ADC $0D
C0/915B: AA           TAX 
C0/915C: A5 06        LDA $06
C0/915E: E2 20        SEP #$20
C0/9160: A0 24 00     LDY #$0024
C0/9163: BF 37 92 C0  LDA $C09237,X
C0/9167: 99 F3 16     STA $16F3,Y
C0/916A: A9 03        LDA #$03
C0/916C: 99 F4 16     STA $16F4,Y
C0/916F: BF 43 92 C0  LDA $C09243,X
C0/9173: 99 33 17     STA $1733,Y
C0/9176: A9 03        LDA #$03
C0/9178: 99 34 17     STA $1734,Y
C0/917B: E8           INX 
C0/917C: C8           INY 
C0/917D: C8           INY 
C0/917E: C0 3C 00     CPY #$003C
C0/9181: D0 E0        BNE $9163
C0/9183: A6 06        LDX $06
C0/9185: A0 28 00     LDY #$0028
C0/9188: A5 B6        LDA $B6
C0/918A: D0 19        BNE $91A5
C0/918C: BD AD 10     LDA $10AD,X
C0/918F: 18           CLC 
C0/9190: 69 E0        ADC #$E0
C0/9192: 99 33 17     STA $1733,Y
C0/9195: A9 03        LDA #$03
C0/9197: 99 34 17     STA $1734,Y
C0/919A: E8           INX 
C0/919B: C8           INY 
C0/919C: C8           INY 
C0/919D: C0 36 00     CPY #$0036
C0/91A0: D0 EA        BNE $918C
C0/91A2: 4C BB 91     JMP $91BB
C0/91A5: BD AD 10     LDA $10AD,X
C0/91A8: 18           CLC 
C0/91A9: 69 F0        ADC #$F0
C0/91AB: 99 F3 16     STA $16F3,Y
C0/91AE: A9 03        LDA #$03
C0/91B0: 99 F4 16     STA $16F4,Y
C0/91B3: E8           INX 
C0/91B4: C8           INY 
C0/91B5: C8           INY 
C0/91B6: C0 36 00     CPY #$0036
C0/91B9: D0 EA        BNE $91A5
C0/91BB: A5 B6        LDA $B6
C0/91BD: 0A           ASL 
C0/91BE: 18           CLC 
C0/91BF: 65 B6        ADC $B6
C0/91C1: 18           CLC 
C0/91C2: 69 12        ADC #$12
C0/91C4: AA           TAX 
C0/91C5: A9 2C        LDA #$2C
C0/91C7: 9F 8B 6A 7F  STA $7F6A8B,X
C0/91CB: A9 6B        LDA #$6B
C0/91CD: 9F 8C 6A 7F  STA $7F6A8C,X
C0/91D1: A9 6C        LDA #$6C
C0/91D3: 9F BC 6A 7F  STA $7F6ABC,X
C0/91D7: A9 6D        LDA #$6D
C0/91D9: 9F BD 6A 7F  STA $7F6ABD,X
C0/91DD: E6 A6        INC $A6
C0/91DF: E6 76        INC $76
C0/91E1: E6 B6        INC $B6
C0/91E3: A5 B6        LDA $B6
C0/91E5: C9 02        CMP #$02
C0/91E7: F0 03        BEQ $91EC
C0/91E9: 4C 42 91     JMP $9142
C0/91EC: 60           RTS 
C0/91ED: A9 07        LDA #$07
C0/91EF: 38           SEC 
C0/91F0: 6D D9 0A     ADC $0AD9
C0/91F3: 85 76        STA $76
C0/91F5: AD D8 0A     LDA $0AD8
C0/91F8: 85 75        STA $75
C0/91FA: 20 41 4E     JSR $4E41       ; wait for vblank
C0/91FD: A9 01        LDA #$01
C0/91FF: A6 06        LDX $06
C0/9201: 86 71        STX $71
C0/9203: 20 7D 70     JSR $707D
C0/9206: E6 A6        INC $A6
C0/9208: A5 B6        LDA $B6
C0/920A: 0A           ASL 
C0/920B: 18           CLC 
C0/920C: 65 B6        ADC $B6
C0/920E: 18           CLC 
C0/920F: 69 0F        ADC #$0F
C0/9211: AA           TAX 
C0/9212: BF 5A 6A 7F  LDA $7F6A5A,X
C0/9216: 9F 8B 6A 7F  STA $7F6A8B,X
C0/921A: BF 5B 6A 7F  LDA $7F6A5B,X
C0/921E: 9F 8C 6A 7F  STA $7F6A8C,X
C0/9222: A9 7C        LDA #$7C
C0/9224: 9F BC 6A 7F  STA $7F6ABC,X
C0/9228: A9 6D        LDA #$6D
C0/922A: 9F BD 6A 7F  STA $7F6ABD,X
C0/922E: C6 76        DEC $76
C0/9230: C6 B6        DEC $B6
C0/9232: A5 B6        LDA $B6
C0/9234: D0 C4        BNE $91FA
C0/9236: 60           RTS 

; tile data for gp window
C0/9237: D1 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D2
C0/9243: D5 D0 D0 D0 D0 D0 D0 D0 D0 D0 DD D6
C0/924F: D5 D0 D0 D0 D0 D0 D0 D0 D0 D0 DE D6
C0/925B: D3 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D4

; [ show map title ]

C0/9267: AD 53 0B     LDA $0B53       ; 
C0/926A: F0 1F        BEQ $928B
C0/926C: AD A0 16     LDA $16A0
C0/926F: F0 0D        BEQ $927E       ; branch if map title is disabled
C0/9271: A9 01        LDA #$01        ; dialog window at top
C0/9273: 85 B4        STA $B4
C0/9275: 20 3D 93     JSR $933D       ; show dialog window (map title)
C0/9278: 20 C1 4A     JSR $4AC1       ; wait for keypress
C0/927B: 20 19 94     JSR $9419       ; hide dialog window (map title)
C0/927E: 9C A0 16     STZ $16A0
C0/9281: E6 A5        INC $A5
C0/9283: 20 41 4E     JSR $4E41       ; wait for vblank
C0/9286: A9 01        LDA #$01
C0/9288: 8D B8 10     STA $10B8
C0/928B: 60           RTS 

; [ init map title ]

C0/928C: 20 54 8F     JSR $8F54
C0/928F: A5 57        LDA $57
C0/9291: F0 0A        BEQ $929D
C0/9293: AD A0 16     LDA $16A0
C0/9296: F0 0A        BEQ $92A2
C0/9298: AD 0E 11     LDA $110E
C0/929B: 80 06        BRA $92A3
C0/929D: AD 0E 11     LDA $110E
C0/92A0: D0 01        BNE $92A3
C0/92A2: 60           RTS 
C0/92A3: C2 20        REP #$20
C0/92A5: 0A           ASL 
C0/92A6: AA           TAX 
C0/92A7: BF 02 70 D0  LDA $D07002,X
C0/92AB: 38           SEC 
C0/92AC: FF 00 70 D0  SBC $D07000,X
C0/92B0: 85 2C        STA $2C
C0/92B2: BF 00 70 D0  LDA $D07000,X   ; pointer to map title
C0/92B6: AA           TAX 
C0/92B7: A5 06        LDA $06
C0/92B9: E2 20        SEP #$20
C0/92BB: A4 06        LDY $06
C0/92BD: BF 00 72 D0  LDA $D07200,X   ; map title
C0/92C1: C9 1E        CMP #$1E
C0/92C3: D0 07        BNE $92CC
C0/92C5: A9 01        LDA #$01
C0/92C7: 99 13 1A     STA $1A13,Y
C0/92CA: 80 09        BRA $92D5
C0/92CC: C9 1F        CMP #$1F
C0/92CE: D0 12        BNE $92E2
C0/92D0: A9 02        LDA #$02
C0/92D2: 99 13 1A     STA $1A13,Y
C0/92D5: E8           INX 
C0/92D6: C6 2C        DEC $2C
C0/92D8: BF 00 72 D0  LDA $D07200,X
C0/92DC: 99 D3 19     STA $19D3,Y
C0/92DF: C8           INY 
C0/92E0: 80 04        BRA $92E6
C0/92E2: 99 D3 19     STA $19D3,Y
C0/92E5: C8           INY 
C0/92E6: E8           INX 
C0/92E7: C6 2C        DEC $2C
C0/92E9: D0 D2        BNE $92BD
C0/92EB: 98           TYA 
C0/92EC: 8D 02 42     STA $4202
C0/92EF: A9 06        LDA #$06
C0/92F1: 8D 03 42     STA $4203
C0/92F4: EA           NOP 
C0/92F5: EA           NOP 
C0/92F6: EA           NOP 
C0/92F7: EA           NOP 
C0/92F8: A9 60        LDA #$60
C0/92FA: 38           SEC 
C0/92FB: ED 16 42     SBC $4216
C0/92FE: 8D 04 42     STA $4204
C0/9301: 9C 05 42     STZ $4205
C0/9304: A9 10        LDA #$10
C0/9306: 8D 06 42     STA $4206
C0/9309: EA           NOP 
C0/930A: EA           NOP 
C0/930B: EA           NOP 
C0/930C: EA           NOP 
C0/930D: EA           NOP 
C0/930E: EA           NOP 
C0/930F: EA           NOP 
C0/9310: EA           NOP 
C0/9311: AD 16 42     LDA $4216
C0/9314: 85 A8        STA $A8
C0/9316: C2 20        REP #$20
C0/9318: AD 14 42     LDA $4214
C0/931B: 0A           ASL 
C0/931C: 0A           ASL 
C0/931D: 0A           ASL 
C0/931E: 0A           ASL 
C0/931F: 0A           ASL 
C0/9320: 0A           ASL 
C0/9321: 18           CLC 
C0/9322: 69 00 30     ADC #$3000
C0/9325: 85 A9        STA $A9
C0/9327: A5 06        LDA $06
C0/9329: E2 20        SEP #$20
C0/932B: A9 10        LDA #$10
C0/932D: A4 06        LDY $06
C0/932F: 84 AB        STY $AB
C0/9331: 48           PHA 
C0/9332: 20 3B 8D     JSR $8D3B
C0/9335: 20 23 8E     JSR $8E23
C0/9338: 68           PLA 
C0/9339: 3A           DEC 
C0/933A: D0 F5        BNE $9331
C0/933C: 60           RTS 

; [ show dialog window (map title) ]

C0/933D: 20 D3 8B     JSR $8BD3
C0/9340: A5 B4        LDA $B4
C0/9342: 38           SEC 
C0/9343: 6D D9 0A     ADC $0AD9
C0/9346: 85 76        STA $76
C0/9348: AD D8 0A     LDA $0AD8
C0/934B: 85 75        STA $75
C0/934D: A9 00        LDA #$00
C0/934F: 85 B5        STA $B5
C0/9351: 20 41 4E     JSR $4E41       ; wait for vblank
C0/9354: A9 01        LDA #$01
C0/9356: A6 06        LDX $06
C0/9358: 86 71        STX $71
C0/935A: 20 7D 70     JSR $707D
C0/935D: A5 B5        LDA $B5
C0/935F: C2 20        REP #$20
C0/9361: EB           XBA 
C0/9362: 4A           LSR 
C0/9363: 4A           LSR 
C0/9364: AA           TAX 
C0/9365: A5 06        LDA $06
C0/9367: E2 20        SEP #$20
C0/9369: A0 04 00     LDY #$0004
C0/936C: BF 99 93 C0  LDA $C09399,X
C0/9370: 99 F3 16     STA $16F3,Y
C0/9373: A9 03        LDA #$03
C0/9375: 99 F4 16     STA $16F4,Y
C0/9378: BF B9 93 C0  LDA $C093B9,X
C0/937C: 99 33 17     STA $1733,Y
C0/937F: A9 03        LDA #$03
C0/9381: 99 34 17     STA $1734,Y
C0/9384: E8           INX 
C0/9385: C8           INY 
C0/9386: C8           INY 
C0/9387: C0 3C 00     CPY #$003C
C0/938A: D0 E0        BNE $936C
C0/938C: E6 A6        INC $A6
C0/938E: E6 76        INC $76
C0/9390: E6 B5        INC $B5
C0/9392: A5 B5        LDA $B5
C0/9394: C9 02        CMP #$02
C0/9396: D0 B9        BNE $9351
C0/9398: 60           RTS 

; tile data for map window
C0/9399: D1 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7
C0/93A9: D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D2 00 00 00 00

C0/93B9: D5 00 02 04 06 08 0A 0C 0E 10 12 14 16 18 1A 1C
C0/93C9: 1E 20 22 24 26 28 2A 2C 2E 30 32 D6 00 00 00 00

C0/93D9: D5 01 03 05 07 09 0B 0D 0F 11 13 15 17 19 1B 1D
C0/93E9: 1F 21 23 25 27 29 2B 2D 2F 31 33 D6 00 00 00 00

C0/93F9: D3 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8
C0/9409: D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D4 00 00 00 00

; [ hide dialog window (map title) ]

C0/9419: A5 B4        LDA $B4
C0/941B: 38           SEC 
C0/941C: 6D D9 0A     ADC $0AD9
C0/941F: 18           CLC 
C0/9420: 69 01        ADC #$01
C0/9422: 85 76        STA $76
C0/9424: AD D8 0A     LDA $0AD8
C0/9427: 85 75        STA $75
C0/9429: 20 41 4E     JSR $4E41       ; wait for vblank
C0/942C: A9 01        LDA #$01
C0/942E: A6 06        LDX $06
C0/9430: 86 71        STX $71
C0/9432: 20 7D 70     JSR $707D
C0/9435: E6 A6        INC $A6
C0/9437: C6 76        DEC $76
C0/9439: C6 B5        DEC $B5
C0/943B: A5 B5        LDA $B5
C0/943D: D0 EA        BNE $9429
C0/943F: 60           RTS 

; [  ]

C0/9440: 20 D3 8B     JSR $8BD3
C0/9443: A5 B4        LDA $B4
C0/9445: 38           SEC 
C0/9446: 6D D9 0A     ADC $0AD9
C0/9449: 85 76        STA $76
C0/944B: AD D8 0A     LDA $0AD8
C0/944E: 85 75        STA $75
C0/9450: A9 00        LDA #$00
C0/9452: 85 B5        STA $B5
C0/9454: 20 41 4E     JSR $4E41       ; wait for vblank
C0/9457: 20 7C 23     JSR $237C       ; update party sprite
C0/945A: 20 B3 39     JSR $39B3       ; update object sprites
C0/945D: 20 42 28     JSR $2842
C0/9460: A9 01        LDA #$01
C0/9462: A6 06        LDX $06
C0/9464: 86 71        STX $71
C0/9466: 20 7D 70     JSR $707D
C0/9469: A5 B5        LDA $B5
C0/946B: C2 20        REP #$20
C0/946D: EB           XBA 
C0/946E: 4A           LSR 
C0/946F: 4A           LSR 
C0/9470: AA           TAX 
C0/9471: A5 06        LDA $06
C0/9473: E2 20        SEP #$20
C0/9475: A0 04 00     LDY #$0004
C0/9478: BF D8 94 C0  LDA $C094D8,X
C0/947C: 99 F3 16     STA $16F3,Y
C0/947F: A9 03        LDA #$03
C0/9481: 99 F4 16     STA $16F4,Y
C0/9484: BF F8 94 C0  LDA $C094F8,X
C0/9488: 99 33 17     STA $1733,Y
C0/948B: A9 03        LDA #$03
C0/948D: 99 34 17     STA $1734,Y
C0/9490: E8           INX 
C0/9491: C8           INY 
C0/9492: C8           INY 
C0/9493: C0 3C 00     CPY #$003C
C0/9496: D0 E0        BNE $9478
C0/9498: E6 A6        INC $A6
C0/949A: E6 76        INC $76
C0/949C: E6 B5        INC $B5
C0/949E: A5 B5        LDA $B5
C0/94A0: C9 05        CMP #$05
C0/94A2: D0 B0        BNE $9454
C0/94A4: 20 41 4E     JSR $4E41       ; wait for vblank
C0/94A7: 60           RTS 

; [  ]

C0/94A8: A5 B4        LDA $B4
C0/94AA: 38           SEC 
C0/94AB: 6D D9 0A     ADC $0AD9
C0/94AE: 18           CLC 
C0/94AF: 69 04        ADC #$04
C0/94B1: 85 76        STA $76
C0/94B3: AD D8 0A     LDA $0AD8
C0/94B6: 85 75        STA $75
C0/94B8: 20 41 4E     JSR $4E41       ; wait for vblank
C0/94BB: 20 7C 23     JSR $237C       ; update party sprite
C0/94BE: 20 B3 39     JSR $39B3       ; update object sprites
C0/94C1: 20 42 28     JSR $2842
C0/94C4: A9 01        LDA #$01
C0/94C6: A6 06        LDX $06
C0/94C8: 86 71        STX $71
C0/94CA: 20 7D 70     JSR $707D
C0/94CD: E6 A6        INC $A6
C0/94CF: C6 76        DEC $76
C0/94D1: C6 B5        DEC $B5
C0/94D3: A5 B5        LDA $B5
C0/94D5: D0 E1        BNE $94B8
C0/94D7: 60           RTS 

; tile data for dialogue window
C0/94D8: D1 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7
C0/94E8: D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D7 D2 00 00 00 00

C0/94F8: D5 00 02 04 06 08 0A 0C 0E 10 12 14 16 18 1A 1C
C0/9508: 1E 20 22 24 26 28 2A 2C 2E 30 32 D6 00 00 00 00

C0/9518: D5 01 03 05 07 09 0B 0D 0F 11 13 15 17 19 1B 1D
C0/9528: 1F 21 23 25 27 29 2B 2D 2F 31 33 D6 00 00 00 00

C0/9538: D5 34 36 38 3A 3C 3E 40 42 44 46 48 4A 4C 4E 50
C0/9548: 52 54 56 58 5A 5C 5E 60 62 64 66 D6 00 00 00 00

C0/9558: D5 35 37 39 3B 3D 3F 41 43 45 47 49 4B 4D 4F 51
C0/9568: 53 55 57 59 5B 5D 5F 61 63 65 67 D6 00 00 00 00

C0/9578: D5 68 6A 6C 6E 70 72 74 76 78 7A 7C 7E 80 82 84
C0/9588: 86 88 8A 8C 8E 90 92 94 96 98 9A D6 00 00 00 00

C0/9598: D5 69 6B 6D 6F 71 73 75 77 79 7B 7D 7F 81 83 85
C0/95A8: 87 89 8B 8D 8F 91 93 95 97 99 9B D6 00 00 00 00

C0/95B8: D5 9C 9E A0 A2 A4 A6 A8 AA AC AE B0 B2 B4 B6 B8
C0/95C8: BA BC BE C0 C2 C4 C6 C8 CA CC CE D6 00 00 00 00

C0/95D8: D5 9D 9F A1 A3 A5 A7 A9 AB AD AF B1 B3 B5 B7 B9
C0/95E8: BB BD BF C1 C3 C5 C7 C9 CB CD CF D6 00 00 00 00

C0/95F8: D3 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8
C0/9608: D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D8 D4 00 00 00 00

C0/9618: A9 80        LDA #$80
C0/961A: 8D 15 21     STA $2115
C0/961D: A0 80 18     LDY #$1880
C0/9620: 8C 16 21     STY $2116
C0/9623: AD 3A 21     LDA $213A
C0/9626: A6 06        LDX $06
C0/9628: AD 3A 21     LDA $213A
C0/962B: 9F 22 86 7F  STA $7F8622,X
C0/962F: E8           INX 
C0/9630: E0 80 00     CPX #$0080
C0/9633: D0 F3        BNE $9628
C0/9635: A0 80 1C     LDY #$1C80
C0/9638: 8C 16 21     STY $2116
C0/963B: AD 3A 21     LDA $213A
C0/963E: AD 3A 21     LDA $213A
C0/9641: 9F 22 86 7F  STA $7F8622,X
C0/9645: E8           INX 
C0/9646: E0 00 01     CPX #$0100
C0/9649: D0 F3        BNE $963E
C0/964B: 60           RTS 
C0/964C: A5 3E        LDA $3E
C0/964E: 29 0F        AND #$0F
C0/9650: AA           TAX 
C0/9651: BD F4 96     LDA $96F4,X
C0/9654: 09 07        ORA #$07
C0/9656: AA           TAX 
C0/9657: BF 22 86 7F  LDA $7F8622,X
C0/965B: 85 17        STA $17
C0/965D: A0 07 00     LDY #$0007
C0/9660: BF 21 86 7F  LDA $7F8621,X
C0/9664: 9F 22 86 7F  STA $7F8622,X
C0/9668: CA           DEX 
C0/9669: 88           DEY 
C0/966A: D0 F4        BNE $9660
C0/966C: 8A           TXA 
C0/966D: 29 F8        AND #$F8
C0/966F: 18           CLC 
C0/9670: 69 47        ADC #$47
C0/9672: AA           TAX 
C0/9673: BF 22 86 7F  LDA $7F8622,X
C0/9677: 9F DB 85 7F  STA $7F85DB,X
C0/967B: A0 07 00     LDY #$0007
C0/967E: BF 21 86 7F  LDA $7F8621,X
C0/9682: 9F 22 86 7F  STA $7F8622,X
C0/9686: CA           DEX 
C0/9687: 88           DEY 
C0/9688: D0 F4        BNE $967E
C0/968A: 8A           TXA 
C0/968B: 29 F8        AND #$F8
C0/968D: AA           TAX 
C0/968E: A5 17        LDA $17
C0/9690: 9F 22 86 7F  STA $7F8622,X
C0/9694: 60           RTS 
C0/9695: AD D6 0A     LDA $0AD6       ; map index
C0/9698: C9 03        CMP #$03
C0/969A: B0 57        BCS $96F3
C0/969C: A9 80        LDA #$80
C0/969E: 8D 15 21     STA $2115
C0/96A1: 9C 0B 42     STZ $420B
C0/96A4: A9 00        LDA #$00
C0/96A6: 8D 00 43     STA $4300
C0/96A9: A9 19        LDA #$19
C0/96AB: 8D 01 43     STA $4301
C0/96AE: A9 7F        LDA #$7F
C0/96B0: 8D 04 43     STA $4304
C0/96B3: A2 80 00     LDX #$0080
C0/96B6: 8E 05 43     STX $4305
C0/96B9: A2 22 86     LDX #$8622
C0/96BC: 8E 02 43     STX $4302
C0/96BF: A2 80 18     LDX #$1880
C0/96C2: 8E 16 21     STX $2116
C0/96C5: A9 01        LDA #$01
C0/96C7: 8D 0B 42     STA $420B
C0/96CA: 9C 0B 42     STZ $420B
C0/96CD: A9 00        LDA #$00
C0/96CF: 8D 00 43     STA $4300
C0/96D2: A9 19        LDA #$19
C0/96D4: 8D 01 43     STA $4301
C0/96D7: A9 7F        LDA #$7F
C0/96D9: 8D 04 43     STA $4304
C0/96DC: A2 80 00     LDX #$0080
C0/96DF: 8E 05 43     STX $4305
C0/96E2: A2 A2 86     LDX #$86A2
C0/96E5: 8E 02 43     STX $4302
C0/96E8: A2 80 1C     LDX #$1C80
C0/96EB: 8E 16 21     STX $2116
C0/96EE: A9 01        LDA #$01
C0/96F0: 8D 0B 42     STA $420B
C0/96F3: 60           RTS 
C0/96F4: 00 88        BRK $88
C0/96F6: 10 98        BPL $9690
C0/96F8: 20 A8 30     JSR $30A8
C0/96FB: B8           CLV 
C0/96FC: 80 08        BRA $9706
C0/96FE: 90 18        BCC $9718
C0/9700: A0 28 B0     LDY #$B028
C0/9703: 38           SEC 
C0/9704: A9 80        LDA #$80
C0/9706: 8D 15 21     STA $2115
C0/9709: A0 C0 21     LDY #$21C0
C0/970C: 8C 16 21     STY $2116
C0/970F: AD 3A 21     LDA $213A
C0/9712: A6 06        LDX $06
C0/9714: AD 3A 21     LDA $213A
C0/9717: 9F 22 87 7F  STA $7F8722,X
C0/971B: E8           INX 
C0/971C: E0 80 00     CPX #$0080
C0/971F: D0 F3        BNE $9714
C0/9721: 60           RTS 
C0/9722: A5 3E        LDA $3E
C0/9724: 29 0E        AND #$0E
C0/9726: 4A           LSR 
C0/9727: AA           TAX 
C0/9728: BF 57 97 C0  LDA $C09757,X
C0/972C: 29 07        AND #$07
C0/972E: 09 70        ORA #$70
C0/9730: AA           TAX 
C0/9731: BF 2A 87 7F  LDA $7F872A,X
C0/9735: 85 17        STA $17
C0/9737: BF 22 87 7F  LDA $7F8722,X
C0/973B: 9F 2A 87 7F  STA $7F872A,X
C0/973F: 8A           TXA 
C0/9740: 38           SEC 
C0/9741: E9 08        SBC #$08
C0/9743: AA           TAX 
C0/9744: 29 F8        AND #$F8
C0/9746: D0 EF        BNE $9737
C0/9748: BF 22 87 7F  LDA $7F8722,X
C0/974C: 9F 2A 87 7F  STA $7F872A,X
C0/9750: A5 17        LDA $17
C0/9752: 9F 22 87 7F  STA $7F8722,X
C0/9756: 60           RTS 
C0/9757: 00 04        BRK $04
C0/9759: 02 06        COP $06
C0/975B: 01 05        ORA ($05,X)
C0/975D: 03 07        ORA $07,S
C0/975F: AD D6 0A     LDA $0AD6       ; map index
C0/9762: C9 03        CMP #$03
C0/9764: B0 32        BCS $9798
C0/9766: 29 01        AND #$01
C0/9768: D0 2E        BNE $9798
C0/976A: A9 80        LDA #$80
C0/976C: 8D 15 21     STA $2115
C0/976F: 9C 0B 42     STZ $420B
C0/9772: A9 00        LDA #$00
C0/9774: 8D 00 43     STA $4300
C0/9777: A9 19        LDA #$19
C0/9779: 8D 01 43     STA $4301
C0/977C: A9 7F        LDA #$7F
C0/977E: 8D 04 43     STA $4304
C0/9781: A2 80 00     LDX #$0080
C0/9784: 8E 05 43     STX $4305
C0/9787: A2 22 87     LDX #$8722
C0/978A: 8E 02 43     STX $4302
C0/978D: A2 C0 21     LDX #$21C0
C0/9790: 8E 16 21     STX $2116
C0/9793: A9 01        LDA #$01
C0/9795: 8D 0B 42     STA $420B
C0/9798: 60           RTS 

; [ update palette animation ]

C0/9799: AD 23 11     LDA $1123
C0/979C: F0 43        BEQ $97E1
C0/979E: A4 06        LDY $06
C0/97A0: B9 5A 16     LDA $165A,Y
C0/97A3: 30 30        BMI $97D5
C0/97A5: 29 F0        AND #$F0
C0/97A7: 4A           LSR 
C0/97A8: 4A           LSR 
C0/97A9: 4A           LSR 
C0/97AA: 4A           LSR 
C0/97AB: D0 0D        BNE $97BA
C0/97AD: 20 E2 98     JSR $98E2
C0/97B0: C9 00        CMP #$00
C0/97B2: D0 21        BNE $97D5
C0/97B4: 20 E2 97     JSR $97E2
C0/97B7: 4C D5 97     JMP $97D5
C0/97BA: 3A           DEC 
C0/97BB: D0 0D        BNE $97CA
C0/97BD: 20 E2 98     JSR $98E2
C0/97C0: C9 00        CMP #$00
C0/97C2: D0 11        BNE $97D5
C0/97C4: 20 0D 98     JSR $980D
C0/97C7: 4C D5 97     JMP $97D5
C0/97CA: 3A           DEC 
C0/97CB: D0 08        BNE $97D5
C0/97CD: 20 E2 98     JSR $98E2
C0/97D0: 5A           PHY 
C0/97D1: 20 38 98     JSR $9838
C0/97D4: 7A           PLY 
C0/97D5: 98           TYA 
C0/97D6: 18           CLC 
C0/97D7: 69 08        ADC #$08
C0/97D9: A8           TAY 
C0/97DA: C9 20        CMP #$20
C0/97DC: F0 03        BEQ $97E1
C0/97DE: 4C A0 97     JMP $97A0
C0/97E1: 60           RTS 

C0/97E2: B9 5C 16     LDA $165C,Y
C0/97E5: C2 20        REP #$20
C0/97E7: 0A           ASL 
C0/97E8: AA           TAX 
C0/97E9: BD 00 0C     LDA $0C00,X
C0/97EC: 85 17        STA $17
C0/97EE: B9 5B 16     LDA $165B,Y
C0/97F1: 29 FF 00     AND #$00FF
C0/97F4: 0A           ASL 
C0/97F5: 85 19        STA $19
C0/97F7: BD FE 0B     LDA $0BFE,X
C0/97FA: 9D 00 0C     STA $0C00,X
C0/97FD: CA           DEX 
C0/97FE: CA           DEX 
C0/97FF: E4 19        CPX $19
C0/9801: D0 F4        BNE $97F7
C0/9803: A5 17        LDA $17
C0/9805: 9D 00 0C     STA $0C00,X
C0/9808: A5 06        LDA $06
C0/980A: E2 20        SEP #$20
C0/980C: 60           RTS 
C0/980D: B9 5B 16     LDA $165B,Y
C0/9810: C2 20        REP #$20
C0/9812: 0A           ASL 
C0/9813: AA           TAX 
C0/9814: BD 00 0C     LDA $0C00,X
C0/9817: 85 17        STA $17
C0/9819: B9 5C 16     LDA $165C,Y
C0/981C: 29 FF 00     AND #$00FF
C0/981F: 0A           ASL 
C0/9820: 85 19        STA $19
C0/9822: BD 02 0C     LDA $0C02,X
C0/9825: 9D 00 0C     STA $0C00,X
C0/9828: E8           INX 
C0/9829: E8           INX 
C0/982A: E4 19        CPX $19
C0/982C: D0 F4        BNE $9822
C0/982E: A5 17        LDA $17
C0/9830: 9D 00 0C     STA $0C00,X
C0/9833: A5 06        LDA $06
C0/9835: E2 20        SEP #$20
C0/9837: 60           RTS 

C0/9838: C2 20        REP #$20
C0/983A: B9 5D 16     LDA $165D,Y
C0/983D: 85 30        STA $30
C0/983F: A5 06        LDA $06
C0/9841: E2 20        SEP #$20
C0/9843: A9 CD        LDA #$CD
C0/9845: 85 32        STA $32
C0/9847: B9 5C 16     LDA $165C,Y
C0/984A: 38           SEC 
C0/984B: F9 5B 16     SBC $165B,Y
C0/984E: 0A           ASL 
C0/984F: AA           TAX 
C0/9850: 86 35        STX $35
C0/9852: B9 59 16     LDA $1659,Y
C0/9855: AA           TAX 
C0/9856: BF D2 98 C0  LDA $C098D2,X
C0/985A: 48           PHA 
C0/985B: B9 5B 16     LDA $165B,Y
C0/985E: 0A           ASL 
C0/985F: AA           TAX 
C0/9860: 68           PLA 
C0/9861: 20 65 98     JSR $9865
C0/9864: 60           RTS 
C0/9865: 8D 02 42     STA $4202
C0/9868: A4 06        LDY $06
C0/986A: C2 20        REP #$20
C0/986C: B7 30        LDA [$30],Y
C0/986E: 85 17        STA $17
C0/9870: 4A           LSR 
C0/9871: 4A           LSR 
C0/9872: 4A           LSR 
C0/9873: 4A           LSR 
C0/9874: 29 3E 00     AND #$003E
C0/9877: 85 19        STA $19
C0/9879: A5 17        LDA $17
C0/987B: EB           XBA 
C0/987C: 4A           LSR 
C0/987D: 29 3E 00     AND #$003E
C0/9880: 85 1B        STA $1B
C0/9882: A5 17        LDA $17
C0/9884: 29 1F 00     AND #$001F
C0/9887: 0A           ASL 
C0/9888: 85 17        STA $17
C0/988A: A5 06        LDA $06
C0/988C: E2 20        SEP #$20
C0/988E: A5 17        LDA $17
C0/9890: 8D 03 42     STA $4203
C0/9893: EA           NOP 
C0/9894: EA           NOP 
C0/9895: EA           NOP 
C0/9896: EA           NOP 
C0/9897: AD 17 42     LDA $4217
C0/989A: 85 1D        STA $1D
C0/989C: A5 1B        LDA $1B
C0/989E: 8D 03 42     STA $4203
C0/98A1: EA           NOP 
C0/98A2: EA           NOP 
C0/98A3: EA           NOP 
C0/98A4: EA           NOP 
C0/98A5: AD 17 42     LDA $4217
C0/98A8: 0A           ASL 
C0/98A9: 0A           ASL 
C0/98AA: 29 7C        AND #$7C
C0/98AC: 85 1E        STA $1E
C0/98AE: A5 19        LDA $19
C0/98B0: 8D 03 42     STA $4203
C0/98B3: EA           NOP 
C0/98B4: EA           NOP 
C0/98B5: EA           NOP 
C0/98B6: EA           NOP 
C0/98B7: AD 17 42     LDA $4217
C0/98BA: C2 20        REP #$20
C0/98BC: EB           XBA 
C0/98BD: 4A           LSR 
C0/98BE: 4A           LSR 
C0/98BF: 4A           LSR 
C0/98C0: 05 1D        ORA $1D
C0/98C2: 9D 00 0C     STA $0C00,X
C0/98C5: A5 06        LDA $06
C0/98C7: E2 20        SEP #$20
C0/98C9: E8           INX 
C0/98CA: E8           INX 
C0/98CB: C8           INY 
C0/98CC: C8           INY 
C0/98CD: C4 35        CPY $35
C0/98CF: D0 99        BNE $986A
C0/98D1: 60           RTS 
C0/98D2: 80 78        BRA $994C
C0/98D4: 70 68        BVS $993E
C0/98D6: 60           RTS 
C0/98D7: 58           CLI 
C0/98D8: 50 48        BVC $9922
C0/98DA: 40           RTI 
C0/98DB: 48           PHA 
C0/98DC: 50 58        BVC $9936
C0/98DE: 60           RTS 
C0/98DF: 68           PLA 
C0/98E0: 70 78        BVS $995A
C0/98E2: B9 57 16     LDA $1657,Y
C0/98E5: 1A           INC 
C0/98E6: 99 57 16     STA $1657,Y
C0/98E9: D9 58 16     CMP $1658,Y
C0/98EC: D0 1C        BNE $990A
C0/98EE: A9 00        LDA #$00
C0/98F0: 99 57 16     STA $1657,Y
C0/98F3: B9 59 16     LDA $1659,Y
C0/98F6: 1A           INC 
C0/98F7: 99 59 16     STA $1659,Y
C0/98FA: B9 5A 16     LDA $165A,Y
C0/98FD: 29 0F        AND #$0F
C0/98FF: D9 59 16     CMP $1659,Y
C0/9902: D0 06        BNE $990A
C0/9904: A9 00        LDA #$00
C0/9906: 99 59 16     STA $1659,Y
C0/9909: 60           RTS 
C0/990A: A9 01        LDA #$01
C0/990C: 60           RTS 

; [ init palette animation ]

C0/990D: AD 23 11     LDA $1123
C0/9910: D0 01        BNE $9913
C0/9912: 60           RTS 
C0/9913: 3A           DEC 
C0/9914: 8D 02 42     STA $4202
C0/9917: A9 18        LDA #$18        ; 24 bytes each
C0/9919: 8D 03 42     STA $4203
C0/991C: EA           NOP 
C0/991D: EA           NOP 
C0/991E: EA           NOP 
C0/991F: EA           NOP 
C0/9920: AE 16 42     LDX $4216
C0/9923: A4 06        LDY $06
C0/9925: BF 40 FA CD  LDA $CDFA40,X
C0/9929: 99 5A 16     STA $165A,Y
C0/992C: BF 41 FA CD  LDA $CDFA41,X
C0/9930: 99 58 16     STA $1658,Y
C0/9933: BF 42 FA CD  LDA $CDFA42,X
C0/9937: 99 5B 16     STA $165B,Y
C0/993A: BF 43 FA CD  LDA $CDFA43,X
C0/993E: 99 5C 16     STA $165C,Y
C0/9941: BF 44 FA CD  LDA $CDFA44,X
C0/9945: 99 5D 16     STA $165D,Y
C0/9948: BF 45 FA CD  LDA $CDFA45,X
C0/994C: 99 5E 16     STA $165E,Y
C0/994F: A9 00        LDA #$00
C0/9951: 99 57 16     STA $1657,Y
C0/9954: 99 59 16     STA $1659,Y
C0/9957: C2 20        REP #$20
C0/9959: 8A           TXA 
C0/995A: 18           CLC 
C0/995B: 69 06 00     ADC #$0006
C0/995E: AA           TAX 
C0/995F: A5 06        LDA $06
C0/9961: E2 20        SEP #$20
C0/9963: 98           TYA 
C0/9964: 18           CLC 
C0/9965: 69 08        ADC #$08
C0/9967: A8           TAY 
C0/9968: C9 20        CMP #$20
C0/996A: D0 B9        BNE $9925
C0/996C: 60           RTS 

; [ copy map animation graphics to vram ]

C0/996D: AD 10 11     LDA $1110       ; return if map animation is disabled
C0/9970: 10 01        BPL $9973
C0/9972: 60           RTS 
C0/9973: A9 80        LDA #$80
C0/9975: 8D 15 21     STA $2115
C0/9978: A9 01        LDA #$01
C0/997A: 8D 00 43     STA $4300
C0/997D: A9 18        LDA #$18
C0/997F: 8D 01 43     STA $4301
C0/9982: A4 06        LDY $06
C0/9984: A2 00 2E     LDX #$2E00
C0/9987: B9 17 14     LDA $1417,Y
C0/998A: 30 04        BMI $9990
C0/998C: A9 DF        LDA #$DF        ; load from rom (bank $DF)
C0/998E: 80 02        BRA $9992
C0/9990: A9 7F        LDA #$7F        ; load from ram (bank $7F)
C0/9992: 8D 04 43     STA $4304
C0/9995: C2 20        REP #$20
C0/9997: B9 1B 14     LDA $141B,Y     ; source address
C0/999A: 8D 02 43     STA $4302
C0/999D: A9 80 00     LDA #$0080
C0/99A0: 8D 05 43     STA $4305
C0/99A3: 8E 16 21     STX $2116
C0/99A6: 8A           TXA 
C0/99A7: 18           CLC 
C0/99A8: 69 40 00     ADC #$0040
C0/99AB: AA           TAX 
C0/99AC: A5 06        LDA $06
C0/99AE: E2 20        SEP #$20
C0/99B0: A9 01        LDA #$01
C0/99B2: 8D 0B 42     STA $420B
C0/99B5: 98           TYA 
C0/99B6: 18           CLC 
C0/99B7: 69 08        ADC #$08        ; 8 tiles
C0/99B9: A8           TAY 
C0/99BA: C0 40 00     CPY #$0040
C0/99BD: D0 C8        BNE $9987
C0/99BF: A9 DF        LDA #$DF
C0/99C1: 8D 04 43     STA $4304
C0/99C4: A2 80 47     LDX #$4780      ; bg3 animation graphics
C0/99C7: B9 17 14     LDA $1417,Y
C0/99CA: 30 04        BMI $99D0
C0/99CC: A9 DF        LDA #$DF
C0/99CE: 80 02        BRA $99D2
C0/99D0: A9 7F        LDA #$7F
C0/99D2: 8D 04 43     STA $4304
C0/99D5: C2 20        REP #$20
C0/99D7: B9 1B 14     LDA $141B,Y
C0/99DA: 8D 02 43     STA $4302
C0/99DD: A9 40 00     LDA #$0040
C0/99E0: 8D 05 43     STA $4305
C0/99E3: 8E 16 21     STX $2116
C0/99E6: 8A           TXA 
C0/99E7: 18           CLC 
C0/99E8: 69 20 00     ADC #$0020
C0/99EB: AA           TAX 
C0/99EC: A5 06        LDA $06
C0/99EE: E2 20        SEP #$20
C0/99F0: A9 01        LDA #$01
C0/99F2: 8D 0B 42     STA $420B
C0/99F5: 98           TYA 
C0/99F6: 18           CLC 
C0/99F7: 69 08        ADC #$08        ; 4 tiles
C0/99F9: A8           TAY 
C0/99FA: C0 60 00     CPY #$0060
C0/99FD: D0 C8        BNE $99C7
C0/99FF: 60           RTS 

; [ update map animation ]

C0/9A00: A4 06        LDY $06
C0/9A02: B9 18 14     LDA $1418,Y
C0/9A05: 4A           LSR 
C0/9A06: 4A           LSR 
C0/9A07: 4A           LSR 
C0/9A08: 4A           LSR 
C0/9A09: EB           XBA 
C0/9A0A: C2 20        REP #$20
C0/9A0C: 4A           LSR 
C0/9A0D: 18           CLC 
C0/9A0E: 79 19 14     ADC $1419,Y
C0/9A11: 99 1B 14     STA $141B,Y
C0/9A14: A5 06        LDA $06
C0/9A16: E2 20        SEP #$20
C0/9A18: B9 17 14     LDA $1417,Y
C0/9A1B: 29 1C        AND #$1C
C0/9A1D: 4A           LSR 
C0/9A1E: 4A           LSR 
C0/9A1F: AA           TAX 
C0/9A20: B9 18 14     LDA $1418,Y
C0/9A23: 18           CLC 
C0/9A24: 7F 8E 9A C0  ADC $C09A8E,X
C0/9A28: 99 18 14     STA $1418,Y
C0/9A2B: B9 17 14     LDA $1417,Y
C0/9A2E: 29 03        AND #$03
C0/9A30: AA           TAX 
C0/9A31: B9 18 14     LDA $1418,Y
C0/9A34: 3F 8A 9A C0  AND $C09A8A,X
C0/9A38: 99 18 14     STA $1418,Y
C0/9A3B: 98           TYA 
C0/9A3C: 18           CLC 
C0/9A3D: 69 08        ADC #$08
C0/9A3F: A8           TAY 
C0/9A40: C0 40 00     CPY #$0040
C0/9A43: D0 BD        BNE $9A02
C0/9A45: B9 18 14     LDA $1418,Y
C0/9A48: 4A           LSR 
C0/9A49: 4A           LSR 
C0/9A4A: 4A           LSR 
C0/9A4B: 4A           LSR 
C0/9A4C: EB           XBA 
C0/9A4D: C2 20        REP #$20
C0/9A4F: 4A           LSR 
C0/9A50: 4A           LSR 
C0/9A51: 18           CLC 
C0/9A52: 79 19 14     ADC $1419,Y
C0/9A55: 99 1B 14     STA $141B,Y
C0/9A58: A5 06        LDA $06
C0/9A5A: E2 20        SEP #$20
C0/9A5C: B9 17 14     LDA $1417,Y
C0/9A5F: 29 1C        AND #$1C
C0/9A61: 4A           LSR 
C0/9A62: 4A           LSR 
C0/9A63: AA           TAX 
C0/9A64: B9 18 14     LDA $1418,Y
C0/9A67: 18           CLC 
C0/9A68: 7F 8E 9A C0  ADC $C09A8E,X
C0/9A6C: 99 18 14     STA $1418,Y
C0/9A6F: B9 17 14     LDA $1417,Y
C0/9A72: 29 03        AND #$03
C0/9A74: AA           TAX 
C0/9A75: B9 18 14     LDA $1418,Y
C0/9A78: 3F 8A 9A C0  AND $C09A8A,X
C0/9A7C: 99 18 14     STA $1418,Y
C0/9A7F: 98           TYA 
C0/9A80: 18           CLC 
C0/9A81: 69 08        ADC #$08
C0/9A83: A8           TAY 
C0/9A84: C0 60 00     CPY #$0060
C0/9A87: D0 BC        BNE $9A45
C0/9A89: 60           RTS 

C0/9A8A: 1F 3F 7F FF  ORA $FF7F3F,X

C0/9A8E: 01 02        ORA ($02,X)
C0/9A90: 03 04        ORA $04,S
C0/9A92: 05 06        ORA $06
C0/9A94: 07 08        ORA [$08]

; [ init map animation ]

C0/9A96: AD 14 11     LDA $1114       ; tileset
C0/9A99: 8D 02 42     STA $4202
C0/9A9C: A9 24        LDA #$24        ; animation properties are 36 bytes long
C0/9A9E: 8D 03 42     STA $4203
C0/9AA1: EA           NOP 
C0/9AA2: EA           NOP 
C0/9AA3: EA           NOP 
C0/9AA4: EA           NOP 
C0/9AA5: AE 16 42     LDX $4216
C0/9AA8: 86 13        STX $13
C0/9AAA: A6 06        LDX $06
C0/9AAC: 86 15        STX $15
C0/9AAE: C2 20        REP #$20
C0/9AB0: A5 15        LDA $15         ; animated tile index
C0/9AB2: 0A           ASL 
C0/9AB3: 18           CLC 
C0/9AB4: 65 13        ADC $13         ; pointer to animation properties
C0/9AB6: AA           TAX 
C0/9AB7: A5 15        LDA $15
C0/9AB9: 0A           ASL 
C0/9ABA: 0A           ASL 
C0/9ABB: 0A           ASL 
C0/9ABC: A8           TAY 
C0/9ABD: BF A7 9D C0  LDA $C09DA7,X   ; map animation properties
C0/9AC1: 99 19 14     STA $1419,Y     ; graphics offset
C0/9AC4: 85 2E        STA $2E
C0/9AC6: A5 15        LDA $15
C0/9AC8: EB           XBA 
C0/9AC9: 0A           ASL 
C0/9ACA: 0A           ASL 
C0/9ACB: 0A           ASL 
C0/9ACC: 85 23        STA $23         ; $23 = tile index * #$0800
C0/9ACE: A5 15        LDA $15
C0/9AD0: 18           CLC 
C0/9AD1: 65 13        ADC $13
C0/9AD3: AA           TAX 
C0/9AD4: A5 06        LDA $06
C0/9AD6: E2 20        SEP #$20
C0/9AD8: A9 00        LDA #$00
C0/9ADA: 99 18 14     STA $1418,Y     ; frame counter
C0/9ADD: BF 9B 9D C0  LDA $C09D9B,X
C0/9AE1: 99 17 14     STA $1417,Y     ; animation flags
C0/9AE4: 10 12        BPL $9AF8
C0/9AE6: C2 20        REP #$20
C0/9AE8: A5 23        LDA $23
C0/9AEA: 18           CLC 
C0/9AEB: 69 22 86     ADC #$8622      ; offset if loading from ram
C0/9AEE: 99 19 14     STA $1419,Y
C0/9AF1: A5 06        LDA $06
C0/9AF3: E2 20        SEP #$20
C0/9AF5: 20 01 9B     JSR $9B01       ; load animated tile graphics
C0/9AF8: E6 15        INC $15         ; next tile
C0/9AFA: A5 15        LDA $15
C0/9AFC: C9 0C        CMP #$0C
C0/9AFE: D0 AE        BNE $9AAE
C0/9B00: 60           RTS 

; [ load animated tile graphics ]

C0/9B01: C2 20        REP #$20
C0/9B03: A6 2E        LDX $2E
C0/9B05: A4 06        LDY $06
C0/9B07: BF 00 9B DF  LDA $DF9B00,X   ; map animation graphics
C0/9B0B: 99 00 0F     STA $0F00,Y     ; copy 4 tiles
C0/9B0E: E8           INX 
C0/9B0F: E8           INX 
C0/9B10: C8           INY 
C0/9B11: C8           INY 
C0/9B12: C0 80 00     CPY #$0080
C0/9B15: D0 F0        BNE $9B07
C0/9B17: A5 06        LDA $06
C0/9B19: E2 20        SEP #$20
C0/9B1B: A5 15        LDA $15
C0/9B1D: C9 08        CMP #$08
C0/9B1F: B0 19        BCS $9B3A       ; branch if a bg3 tile
C0/9B21: A4 06        LDY $06
C0/9B23: 20 3D 9C     JSR $9C3D
C0/9B26: C8           INY 
C0/9B27: C0 20 00     CPY #$0020
C0/9B2A: D0 F7        BNE $9B23
C0/9B2C: A0 40 00     LDY #$0040
C0/9B2F: 20 3D 9C     JSR $9C3D
C0/9B32: C8           INY 
C0/9B33: C0 60 00     CPY #$0060
C0/9B36: D0 F7        BNE $9B2F
C0/9B38: 80 17        BRA $9B51
C0/9B3A: A4 06        LDY $06
C0/9B3C: 20 AC 9C     JSR $9CAC
C0/9B3F: C8           INY 
C0/9B40: C0 10 00     CPY #$0010
C0/9B43: D0 F7        BNE $9B3C
C0/9B45: A0 20 00     LDY #$0020
C0/9B48: 20 AC 9C     JSR $9CAC
C0/9B4B: C8           INY 
C0/9B4C: C0 30 00     CPY #$0030
C0/9B4F: D0 F7        BNE $9B48
C0/9B51: C2 20        REP #$20
C0/9B53: A5 23        LDA $23
C0/9B55: 85 0F        STA $0F
C0/9B57: A5 06        LDA $06
C0/9B59: 85 0D        STA $0D
C0/9B5B: A5 06        LDA $06
C0/9B5D: 85 11        STA $11
C0/9B5F: A5 15        LDA $15
C0/9B61: C9 08 00     CMP #$0008
C0/9B64: B0 4F        BCS $9BB5
C0/9B66: A6 0D        LDX $0D
C0/9B68: BF 2B 9D C0  LDA $C09D2B,X
C0/9B6C: 18           CLC 
C0/9B6D: 65 11        ADC $11
C0/9B6F: 48           PHA 
C0/9B70: BF 1B 9D C0  LDA $C09D1B,X
C0/9B74: 18           CLC 
C0/9B75: 65 11        ADC $11
C0/9B77: A8           TAY 
C0/9B78: A6 0F        LDX $0F
C0/9B7A: B9 00 0E     LDA $0E00,Y
C0/9B7D: 9F 22 86 7F  STA $7F8622,X
C0/9B81: B9 20 0E     LDA $0E20,Y
C0/9B84: 9F 42 86 7F  STA $7F8642,X
C0/9B88: B9 10 0E     LDA $0E10,Y
C0/9B8B: 9F 32 86 7F  STA $7F8632,X
C0/9B8F: B9 30 0E     LDA $0E30,Y
C0/9B92: 9F 52 86 7F  STA $7F8652,X
C0/9B96: 7A           PLY 
C0/9B97: B9 40 0E     LDA $0E40,Y
C0/9B9A: 9F 62 86 7F  STA $7F8662,X
C0/9B9E: B9 60 0E     LDA $0E60,Y
C0/9BA1: 9F 82 86 7F  STA $7F8682,X
C0/9BA5: B9 50 0E     LDA $0E50,Y
C0/9BA8: 9F 72 86 7F  STA $7F8672,X
C0/9BAC: B9 70 0E     LDA $0E70,Y
C0/9BAF: 9F 92 86 7F  STA $7F8692,X
C0/9BB3: 80 36        BRA $9BEB
C0/9BB5: A5 0D        LDA $0D
C0/9BB7: 0A           ASL 
C0/9BB8: AA           TAX 
C0/9BB9: BF 2B 9D C0  LDA $C09D2B,X
C0/9BBD: 18           CLC 
C0/9BBE: 65 11        ADC $11
C0/9BC0: 48           PHA 
C0/9BC1: BF 1B 9D C0  LDA $C09D1B,X
C0/9BC5: 18           CLC 
C0/9BC6: 65 11        ADC $11
C0/9BC8: A8           TAY 
C0/9BC9: A6 0F        LDX $0F
C0/9BCB: B9 00 0E     LDA $0E00,Y
C0/9BCE: 9F 22 86 7F  STA $7F8622,X
C0/9BD2: B9 10 0E     LDA $0E10,Y
C0/9BD5: 9F 32 86 7F  STA $7F8632,X
C0/9BD9: 7A           PLY 
C0/9BDA: B9 20 0E     LDA $0E20,Y
C0/9BDD: 9F 42 86 7F  STA $7F8642,X
C0/9BE1: B9 30 0E     LDA $0E30,Y
C0/9BE4: 9F 52 86 7F  STA $7F8652,X
C0/9BE8: 80 01        BRA $9BEB
C0/9BEA: 7A           PLY 
C0/9BEB: A5 0D        LDA $0D
C0/9BED: 1A           INC 
C0/9BEE: 1A           INC 
C0/9BEF: 29 1F 00     AND #$001F
C0/9BF2: 85 0D        STA $0D
C0/9BF4: E6 0F        INC $0F
C0/9BF6: E6 0F        INC $0F
C0/9BF8: E6 11        INC $11
C0/9BFA: E6 11        INC $11
C0/9BFC: A5 11        LDA $11
C0/9BFE: C9 10 00     CMP #$0010
C0/9C01: F0 03        BEQ $9C06
C0/9C03: 4C 5F 9B     JMP $9B5F
C0/9C06: A5 0D        LDA $0D
C0/9C08: 18           CLC 
C0/9C09: 69 12 00     ADC #$0012
C0/9C0C: 29 1F 00     AND #$001F
C0/9C0F: 85 0D        STA $0D
C0/9C11: A4 15        LDY $15
C0/9C13: C0 08 00     CPY #$0008
C0/9C16: B0 10        BCS $9C28
C0/9C18: A5 0F        LDA $0F
C0/9C1A: 18           CLC 
C0/9C1B: 69 70 00     ADC #$0070
C0/9C1E: 85 0F        STA $0F
C0/9C20: 29 FF 07     AND #$07FF
C0/9C23: F0 13        BEQ $9C38
C0/9C25: 4C 5B 9B     JMP $9B5B
C0/9C28: A5 0F        LDA $0F
C0/9C2A: 18           CLC 
C0/9C2B: 69 30 00     ADC #$0030
C0/9C2E: 85 0F        STA $0F
C0/9C30: 29 FF 03     AND #$03FF
C0/9C33: F0 03        BEQ $9C38
C0/9C35: 4C 5B 9B     JMP $9B5B
C0/9C38: A5 06        LDA $06
C0/9C3A: E2 20        SEP #$20
C0/9C3C: 60           RTS 

; [ ??? 4bpp ]

C0/9C3D: AD 10 11     LDA $1110
C0/9C40: 29 40        AND #$40
C0/9C42: F0 1F        BEQ $9C63
C0/9C44: B9 00 0F     LDA $0F00,Y
C0/9C47: 99 80 0F     STA $0F80,Y
C0/9C4A: 99 00 10     STA $1000,Y
C0/9C4D: 99 80 0E     STA $0E80,Y
C0/9C50: 99 00 0E     STA $0E00,Y
C0/9C53: B9 20 0F     LDA $0F20,Y
C0/9C56: 99 A0 0F     STA $0FA0,Y
C0/9C59: 99 20 10     STA $1020,Y
C0/9C5C: 99 A0 0E     STA $0EA0,Y
C0/9C5F: 99 20 0E     STA $0E20,Y
C0/9C62: 60           RTS 
C0/9C63: B9 20 0F     LDA $0F20,Y
C0/9C66: 4A           LSR 
C0/9C67: B9 00 0F     LDA $0F00,Y
C0/9C6A: 6A           ROR 
C0/9C6B: 99 80 0F     STA $0F80,Y
C0/9C6E: B9 20 0F     LDA $0F20,Y
C0/9C71: 6A           ROR 
C0/9C72: 99 A0 0F     STA $0FA0,Y
C0/9C75: B9 A0 0F     LDA $0FA0,Y
C0/9C78: 4A           LSR 
C0/9C79: B9 80 0F     LDA $0F80,Y
C0/9C7C: 6A           ROR 
C0/9C7D: 99 00 10     STA $1000,Y
C0/9C80: B9 A0 0F     LDA $0FA0,Y
C0/9C83: 6A           ROR 
C0/9C84: 99 20 10     STA $1020,Y
C0/9C87: B9 00 0F     LDA $0F00,Y
C0/9C8A: 0A           ASL 
C0/9C8B: B9 20 0F     LDA $0F20,Y
C0/9C8E: 2A           ROL 
C0/9C8F: 99 A0 0E     STA $0EA0,Y
C0/9C92: B9 00 0F     LDA $0F00,Y
C0/9C95: 2A           ROL 
C0/9C96: 99 80 0E     STA $0E80,Y
C0/9C99: B9 80 0E     LDA $0E80,Y
C0/9C9C: 0A           ASL 
C0/9C9D: B9 A0 0E     LDA $0EA0,Y
C0/9CA0: 2A           ROL 
C0/9CA1: 99 20 0E     STA $0E20,Y
C0/9CA4: B9 80 0E     LDA $0E80,Y
C0/9CA7: 2A           ROL 
C0/9CA8: 99 00 0E     STA $0E00,Y
C0/9CAB: 60           RTS 

; [ ??? 2bpp ]

C0/9CAC: AD 10 11     LDA $1110
C0/9CAF: 29 40        AND #$40
C0/9CB1: F0 1F        BEQ $9CD2
C0/9CB3: B9 00 0F     LDA $0F00,Y
C0/9CB6: 99 80 0F     STA $0F80,Y
C0/9CB9: 99 00 10     STA $1000,Y
C0/9CBC: 99 80 0E     STA $0E80,Y
C0/9CBF: 99 00 0E     STA $0E00,Y
C0/9CC2: B9 10 0F     LDA $0F10,Y
C0/9CC5: 99 90 0F     STA $0F90,Y
C0/9CC8: 99 10 10     STA $1010,Y
C0/9CCB: 99 90 0E     STA $0E90,Y
C0/9CCE: 99 10 0E     STA $0E10,Y
C0/9CD1: 60           RTS 
C0/9CD2: B9 10 0F     LDA $0F10,Y
C0/9CD5: 4A           LSR 
C0/9CD6: B9 00 0F     LDA $0F00,Y
C0/9CD9: 6A           ROR 
C0/9CDA: 99 80 0F     STA $0F80,Y
C0/9CDD: B9 10 0F     LDA $0F10,Y
C0/9CE0: 6A           ROR 
C0/9CE1: 99 90 0F     STA $0F90,Y
C0/9CE4: B9 90 0F     LDA $0F90,Y
C0/9CE7: 4A           LSR 
C0/9CE8: B9 80 0F     LDA $0F80,Y
C0/9CEB: 6A           ROR 
C0/9CEC: 99 00 10     STA $1000,Y
C0/9CEF: B9 90 0F     LDA $0F90,Y
C0/9CF2: 6A           ROR 
C0/9CF3: 99 10 10     STA $1010,Y
C0/9CF6: B9 00 0F     LDA $0F00,Y
C0/9CF9: 0A           ASL 
C0/9CFA: B9 10 0F     LDA $0F10,Y
C0/9CFD: 2A           ROL 
C0/9CFE: 99 90 0E     STA $0E90,Y
C0/9D01: B9 00 0F     LDA $0F00,Y
C0/9D04: 2A           ROL 
C0/9D05: 99 80 0E     STA $0E80,Y
C0/9D08: B9 80 0E     LDA $0E80,Y
C0/9D0B: 0A           ASL 
C0/9D0C: B9 90 0E     LDA $0E90,Y
C0/9D0F: 2A           ROL 
C0/9D10: 99 10 0E     STA $0E10,Y
C0/9D13: B9 80 0E     LDA $0E80,Y
C0/9D16: 2A           ROL 
C0/9D17: 99 00 0E     STA $0E00,Y
C0/9D1A: 60           RTS 

C0/9D1B: 00 01        BRK $01
C0/9D1D: 80 01        BRA $9D20
C0/9D1F: 80 01        BRA $9D22
C0/9D21: 00 02        BRK $02
C0/9D23: 00 02        BRK $02
C0/9D25: 00 02        BRK $02
C0/9D27: 80 01        BRA $9D2A
C0/9D29: 80 01        BRA $9D2C
C0/9D2B: 00 01        BRK $01
C0/9D2D: 80 00        BRA $9D2F
C0/9D2F: 80 00        BRA $9D31
C0/9D31: 00 00        BRK $00
C0/9D33: 00 00        BRK $00
C0/9D35: 00 00        BRK $00
C0/9D37: 80 00        BRA $9D39
C0/9D39: 80 00        BRA $9D3B
C0/9D3B: 00 01        BRK $01
C0/9D3D: 80 01        BRA $9D40
C0/9D3F: 80 01        BRA $9D42
C0/9D41: 00 02        BRK $02
C0/9D43: 00 02        BRK $02
C0/9D45: 00 02        BRK $02
C0/9D47: 80 01        BRA $9D4A
C0/9D49: 80 01        BRA $9D4C
C0/9D4B: 00 01        BRK $01
C0/9D4D: 80 00        BRA $9D4F
C0/9D4F: 80 00        BRA $9D51
C0/9D51: 00 00        BRK $00
C0/9D53: 00 00        BRK $00
C0/9D55: 00 00        BRK $00
C0/9D57: 80 00        BRA $9D59
C0/9D59: 80 00        BRA $9D5B
C0/9D5B: 00 01        BRK $01
C0/9D5D: 00 01        BRK $01
C0/9D5F: 80 01        BRA $9D62
C0/9D61: 80 01        BRA $9D64
C0/9D63: 80 01        BRA $9D66
C0/9D65: 80 01        BRA $9D68
C0/9D67: 00 01        BRK $01
C0/9D69: 00 01        BRK $01
C0/9D6B: 00 01        BRK $01
C0/9D6D: 00 01        BRK $01
C0/9D6F: 80 00        BRA $9D71
C0/9D71: 80 00        BRA $9D73
C0/9D73: 80 00        BRA $9D75
C0/9D75: 80 00        BRA $9D77
C0/9D77: 00 01        BRK $01
C0/9D79: 00 01        BRK $01
C0/9D7B: 00 01        BRK $01
C0/9D7D: 00 01        BRK $01
C0/9D7F: 80 01        BRA $9D82
C0/9D81: 80 01        BRA $9D84
C0/9D83: 80 01        BRA $9D86
C0/9D85: 80 01        BRA $9D88
C0/9D87: 00 01        BRK $01
C0/9D89: 00 01        BRK $01
C0/9D8B: 00 01        BRK $01
C0/9D8D: 00 01        BRK $01
C0/9D8F: 80 00        BRA $9D91
C0/9D91: 80 00        BRA $9D93
C0/9D93: 80 00        BRA $9D95
C0/9D95: 80 00        BRA $9D97
C0/9D97: 00 01        BRK $01
C0/9D99: 00 01        BRK $01

; map animation properties (28 items, 36 bytes each)

; animation flags (1 byte per tile)
; graphics offsets (2 bytes per tile)

C0/9D9B: 09 00 00 00 87 87 87 87 8B 8B 8B 00
C0/9DA7: B200 0000 0000 0000 1500 1580
C0/9DB3: 1600 1680 5F40 5F80 6000 0000

C0/9DBF: 09 05 01 0D 87 87 87 0D 8B 8B 8B 00
C0/9DCB: B400 B600 B800 A700 1F00 1F80
C0/9DD7: 2000 A900 5EC0 5F00 6040 0000

C0/9DE3: 87        BRK $87
C0/9DE4: 87 00        STA [$00]
C0/9DE6: 00 09        BRK $09
C0/9DE8: 09 00        ORA #$00
C0/9DEA: 00 8B        BRK $8B
C0/9DEC: 00 00        BRK $00
C0/9DEE: 00 00        BRK $00
C0/9DF0: 51 80        EOR ($80),Y
C0/9DF2: 51 00        EOR ($00),Y
C0/9DF4: 00 00        BRK $00
C0/9DF6: 00 00        BRK $00
C0/9DF8: F1 00        SBC ($00),Y
C0/9DFA: F3 00        SBC ($00,S),Y
C0/9DFC: 00 00        BRK $00
C0/9DFE: 00 00        BRK $00
C0/9E00: 5E 00 00     LSR $0000,X
C0/9E03: 00 00        BRK $00
C0/9E05: 00 00        BRK $00

C0/9E07: 08           PHP 
C0/9E08: 08           PHP 
C0/9E09: 00 00        BRK $00
C0/9E0B: 00 00        BRK $00
C0/9E0D: 00 00        BRK $00
C0/9E0F: 00 00        BRK $00
C0/9E11: 00 00        BRK $00
C0/9E13: 00 00        BRK $00
C0/9E15: 00 DC        BRK $DC
C0/9E17: 00 00        BRK $00
C0/9E19: 00 00        BRK $00
C0/9E1B: 00 00        BRK $00
C0/9E1D: 00 00        BRK $00
C0/9E1F: 00 00        BRK $00
C0/9E21: 00 00        BRK $00
C0/9E23: 00 00        BRK $00
C0/9E25: 00 00        BRK $00
C0/9E27: 00 00        BRK $00
C0/9E29: 00 00        BRK $00

C0/9E2B: 00 00        BRK $00
C0/9E2D: 00 00        BRK $00
C0/9E2F: 00 00        BRK $00
C0/9E31: 00 00        BRK $00
C0/9E33: 00 00        BRK $00
C0/9E35: 00 00        BRK $00
C0/9E37: 00 00        BRK $00
C0/9E39: 00 00        BRK $00
C0/9E3B: 00 00        BRK $00
C0/9E3D: 00 00        BRK $00
C0/9E3F: 00 00        BRK $00
C0/9E41: 00 00        BRK $00
C0/9E43: 00 00        BRK $00
C0/9E45: 00 00        BRK $00
C0/9E47: 00 00        BRK $00
C0/9E49: 00 00        BRK $00
C0/9E4B: 00 00        BRK $00
C0/9E4D: 00 00        BRK $00

C0/9E4F: 87 87        STA [$87]
C0/9E51: 87 87        STA [$87]
C0/9E53: 09 09        ORA #$09
C0/9E55: 00 00        BRK $00
C0/9E57: 8B           PHB 
C0/9E58: 00 00        BRK $00
C0/9E5A: 00 00        BRK $00
C0/9E5C: 54 80 54     MVN $80,$54
C0/9E5F: 00 55        BRK $55
C0/9E61: 80 55        BRA $9EB8
C0/9E63: 00 F1        BRK $F1
C0/9E65: 00 F3        BRK $F3
C0/9E67: 00 00        BRK $00
C0/9E69: 00 00        BRK $00
C0/9E6B: 00 5E        BRK $5E
C0/9E6D: 00 00        BRK $00
C0/9E6F: 00 00        BRK $00
C0/9E71: 00 00        BRK $00

C0/9E73: 05 01        ORA $01
C0/9E75: 00 00        BRK $00
C0/9E77: 00 00        BRK $00
C0/9E79: 00 00        BRK $00
C0/9E7B: 00 00        BRK $00
C0/9E7D: 00 00        BRK $00
C0/9E7F: 00 B6        BRK $B6
C0/9E81: 00 B8        BRK $B8
C0/9E83: 00 00        BRK $00
C0/9E85: 00 00        BRK $00
C0/9E87: 00 00        BRK $00
C0/9E89: 00 00        BRK $00
C0/9E8B: 00 00        BRK $00
C0/9E8D: 00 00        BRK $00
C0/9E8F: 00 00        BRK $00
C0/9E91: 00 00        BRK $00
C0/9E93: 00 00        BRK $00
C0/9E95: 00 00        BRK $00

C0/9E97: 87 0D        STA [$0D]
C0/9E99: 0D 00 00     ORA $0000
C0/9E9C: 00 00        BRK $00
C0/9E9E: 00 8B        BRK $8B
C0/9EA0: 8B           PHB 
C0/9EA1: 00 00        BRK $00
C0/9EA3: 00 10        BRK $10
C0/9EA5: 00 A7        BRK $A7
C0/9EA7: 00 A9        BRK $A9
C0/9EA9: 00 00        BRK $00
C0/9EAB: 00 00        BRK $00
C0/9EAD: 00 00        BRK $00
C0/9EAF: 00 00        BRK $00
C0/9EB1: 00 00        BRK $00
C0/9EB3: C0 5F 40     CPY #$405F
C0/9EB6: 5E 00 00     LSR $0000,X
C0/9EB9: 00 00        BRK $00

C0/9EBB: 87 0D        STA [$0D]
C0/9EBD: 0D 11 00     ORA $0011
C0/9EC0: 00 00        BRK $00
C0/9EC2: 00 8B        BRK $8B
C0/9EC4: 8B           PHB 
C0/9EC5: 8B           PHB 
C0/9EC6: 00 00        BRK $00
C0/9EC8: 10 00        BPL $9ECA
C0/9ECA: A7 00        LDA [$00]
C0/9ECC: A9 00        LDA #$00
C0/9ECE: DD 00 00     CMP $0000,X
C0/9ED1: 00 00        BRK $00
C0/9ED3: 00 00        BRK $00
C0/9ED5: 00 00        BRK $00
C0/9ED7: 80 5E        BRA $9F37
C0/9ED9: C0 5F 40     CPY #$405F
C0/9EDC: 5E 00 00     LSR $0000,X

C0/9EDF: 00 00        BRK $00
C0/9EE1: 00 00        BRK $00
C0/9EE3: 00 00        BRK $00
C0/9EE5: 00 00        BRK $00
C0/9EE7: 00 00        BRK $00
C0/9EE9: 00 00        BRK $00
C0/9EEB: 00 00        BRK $00
C0/9EED: 00 00        BRK $00
C0/9EEF: 00 00        BRK $00
C0/9EF1: 00 00        BRK $00
C0/9EF3: 00 00        BRK $00
C0/9EF5: 00 00        BRK $00
C0/9EF7: 00 00        BRK $00
C0/9EF9: 00 00        BRK $00
C0/9EFB: 00 00        BRK $00
C0/9EFD: 00 00        BRK $00
C0/9EFF: 00 00        BRK $00
C0/9F01: 00 00        BRK $00

C0/9F03: 15 0D        ORA $0D,X
C0/9F05: 0D 02 87     ORA $8702
C0/9F08: 87 00        STA [$00]
C0/9F0A: 00 00        BRK $00
C0/9F0C: 00 00        BRK $00
C0/9F0E: 00 00        BRK $00
C0/9F10: DD 00 A7     CMP $A700,X
C0/9F13: 00 A9        BRK $A9
C0/9F15: 00 C8        BRK $C8
C0/9F17: 00 21        BRK $21
C0/9F19: 80 21        BRA $9F3C
C0/9F1B: 00 00        BRK $00
C0/9F1D: 00 00        BRK $00
C0/9F1F: 00 00        BRK $00
C0/9F21: 00 00        BRK $00
C0/9F23: 00 00        BRK $00
C0/9F25: 00 00        BRK $00

C0/9F27: 00 00        BRK $00
C0/9F29: 00 00        BRK $00
C0/9F2B: 00 00        BRK $00
C0/9F2D: 00 00        BRK $00
C0/9F2F: 00 00        BRK $00
C0/9F31: 00 00        BRK $00
C0/9F33: 00 00        BRK $00
C0/9F35: 00 00        BRK $00
C0/9F37: 00 00        BRK $00
C0/9F39: 00 00        BRK $00
C0/9F3B: 00 00        BRK $00
C0/9F3D: 00 00        BRK $00
C0/9F3F: 00 00        BRK $00
C0/9F41: 00 00        BRK $00
C0/9F43: 00 00        BRK $00
C0/9F45: 00 00        BRK $00
C0/9F47: 00 00        BRK $00
C0/9F49: 00 00        BRK $00

C0/9F4B: 10 00        BPL $9F4D
C0/9F4D: 00 00        BRK $00
C0/9F4F: 00 00        BRK $00
C0/9F51: 00 00        BRK $00
C0/9F53: 00 00        BRK $00
C0/9F55: 00 00        BRK $00
C0/9F57: 00 EB        BRK $EB
C0/9F59: 00 00        BRK $00
C0/9F5B: 00 00        BRK $00
C0/9F5D: 00 00        BRK $00
C0/9F5F: 00 00        BRK $00
C0/9F61: 00 00        BRK $00
C0/9F63: 00 00        BRK $00
C0/9F65: 00 00        BRK $00
C0/9F67: 00 00        BRK $00
C0/9F69: 00 00        BRK $00
C0/9F6B: 00 00        BRK $00
C0/9F6D: 00 00        BRK $00

C0/9F6F: 00 00        BRK $00
C0/9F71: 00 00        BRK $00
C0/9F73: 00 00        BRK $00
C0/9F75: 00 00        BRK $00
C0/9F77: 1D 1D 1D     ORA $1D1D,X
C0/9F7A: 1D 00 00     ORA $0000,X
C0/9F7D: 00 00        BRK $00
C0/9F7F: 00 00        BRK $00
C0/9F81: 00 00        BRK $00
C0/9F83: 00 00        BRK $00
C0/9F85: 00 00        BRK $00
C0/9F87: 00 00        BRK $00
C0/9F89: 00 00        BRK $00
C0/9F8B: 00 F5        BRK $F5
C0/9F8D: 00 F6        BRK $F6
C0/9F8F: 00 F7        BRK $F7
C0/9F91: 00 F8        BRK $F8

C0/9F93: 00 00        BRK $00
C0/9F95: 00 00        BRK $00
C0/9F97: 00 00        BRK $00
C0/9F99: 00 00        BRK $00
C0/9F9B: 00 00        BRK $00
C0/9F9D: 00 00        BRK $00
C0/9F9F: 00 00        BRK $00
C0/9FA1: 00 00        BRK $00
C0/9FA3: 00 00        BRK $00
C0/9FA5: 00 00        BRK $00
C0/9FA7: 00 00        BRK $00
C0/9FA9: 00 00        BRK $00
C0/9FAB: 00 00        BRK $00
C0/9FAD: 00 00        BRK $00
C0/9FAF: 00 00        BRK $00
C0/9FB1: 00 00        BRK $00
C0/9FB3: 00 00        BRK $00
C0/9FB5: 00 00        BRK $00

C0/9FB7: 01 01        ORA ($01,X)
C0/9FB9: 00 00        BRK $00
C0/9FBB: 00 00        BRK $00
C0/9FBD: 00 00        BRK $00
C0/9FBF: 00 00        BRK $00
C0/9FC1: 00 00        BRK $00
C0/9FC3: 80 AB        BRA $9F70
C0/9FC5: 00 ED        BRK $ED
C0/9FC7: 00 00        BRK $00
C0/9FC9: 00 00        BRK $00
C0/9FCB: 00 00        BRK $00
C0/9FCD: 00 00        BRK $00
C0/9FCF: 00 00        BRK $00
C0/9FD1: 00 00        BRK $00
C0/9FD3: 00 00        BRK $00
C0/9FD5: 00 00        BRK $00
C0/9FD7: 00 00        BRK $00
C0/9FD9: 00 00        BRK $00

C0/9FDB: 00 00        BRK $00
C0/9FDD: 00 00        BRK $00
C0/9FDF: 00 00        BRK $00
C0/9FE1: 00 00        BRK $00
C0/9FE3: 00 00        BRK $00
C0/9FE5: 00 00        BRK $00
C0/9FE7: 00 00        BRK $00
C0/9FE9: 00 00        BRK $00
C0/9FEB: 00 00        BRK $00
C0/9FED: 00 00        BRK $00
C0/9FEF: 00 00        BRK $00
C0/9FF1: 00 00        BRK $00
C0/9FF3: 00 00        BRK $00
C0/9FF5: 00 00        BRK $00
C0/9FF7: 00 00        BRK $00
C0/9FF9: 00 00        BRK $00
C0/9FFB: 00 00        BRK $00
C0/9FFD: 00 00        BRK $00

C0/9FFF: 02 02        COP $02
C0/A001: 02 02        COP $02
C0/A003: 02 0D        COP $0D
C0/A005: 0D 00 00     ORA $0000
C0/A008: 00 00        BRK $00
C0/A00A: 00 00        BRK $00
C0/A00C: C8           INY 
C0/A00D: 00 CC        BRK $CC
C0/A00F: 00 D0        BRK $D0
C0/A011: 00 D4        BRK $D4
C0/A013: 00 D8        BRK $D8
C0/A015: 00 A7        BRK $A7
C0/A017: 00 A9        BRK $A9
C0/A019: 00 00        BRK $00
C0/A01B: 00 00        BRK $00
C0/A01D: 00 00        BRK $00
C0/A01F: 00 00        BRK $00
C0/A021: 00 00        BRK $00
C0/A023: 1D 1D 1D     ORA $1D1D,X
C0/A026: 1D 1C 1D     ORA $1D1C,X
C0/A029: 0D 0D 00     ORA $000D
C0/A02C: 00 00        BRK $00
C0/A02E: 00 00        BRK $00
C0/A030: BD 00 BF     LDA $BF00,X
C0/A033: 00 C1        BRK $C1
C0/A035: 00 C3        BRK $C3
C0/A037: 00 C5        BRK $C5
C0/A039: 00 C6        BRK $C6
C0/A03B: 00 A7        BRK $A7
C0/A03D: 00 A9        BRK $A9
C0/A03F: 00 00        BRK $00
C0/A041: 00 00        BRK $00
C0/A043: 00 00        BRK $00
C0/A045: 00 00        BRK $00
C0/A047: 02 02        COP $02
C0/A049: 02 02        COP $02
C0/A04B: 02 0D        COP $0D
C0/A04D: 0D 00 00     ORA $0000
C0/A050: 00 00        BRK $00
C0/A052: 00 00        BRK $00
C0/A054: C8           INY 
C0/A055: 00 CC        BRK $CC
C0/A057: 00 D0        BRK $D0
C0/A059: 00 D4        BRK $D4
C0/A05B: 00 D8        BRK $D8
C0/A05D: 00 A7        BRK $A7
C0/A05F: 00 A9        BRK $A9
C0/A061: 00 00        BRK $00
C0/A063: 00 00        BRK $00
C0/A065: 00 00        BRK $00
C0/A067: 00 00        BRK $00
C0/A069: 00 00        BRK $00
C0/A06B: 0D 0D 0D     ORA $0D0D
C0/A06E: 0D 0D 0D     ORA $0D0D
C0/A071: 0D 0D 00     ORA $000D
C0/A074: 00 00        BRK $00
C0/A076: 00 00        BRK $00
C0/A078: DF 00 E1 00  CMP $00E100,X
C0/A07C: E3 00        SBC $00,S
C0/A07E: E5 00        SBC $00
C0/A080: E7 00        SBC [$00]
C0/A082: E9 00        SBC #$00
C0/A084: A7 00        LDA [$00]
C0/A086: A9 00        LDA #$00
C0/A088: 00 00        BRK $00
C0/A08A: 00 00        BRK $00
C0/A08C: 00 00        BRK $00
C0/A08E: 00 19        BRK $19
C0/A090: 0D 0D 00     ORA $000D
C0/A093: 00 00        BRK $00
C0/A095: 00 00        BRK $00
C0/A097: 00 00        BRK $00
C0/A099: 00 00        BRK $00
C0/A09B: 00 AE        BRK $AE
C0/A09D: 00 A7        BRK $A7
C0/A09F: 00 A9        BRK $A9
C0/A0A1: 00 00        BRK $00
C0/A0A3: 00 00        BRK $00
C0/A0A5: 00 00        BRK $00
C0/A0A7: 00 00        BRK $00
C0/A0A9: 00 00        BRK $00
C0/A0AB: 00 00        BRK $00
C0/A0AD: 00 00        BRK $00
C0/A0AF: 00 00        BRK $00
C0/A0B1: 00 00        BRK $00
C0/A0B3: 05 05        ORA $05
C0/A0B5: 05 09        ORA $09
C0/A0B7: 09 01        ORA #$01
C0/A0B9: 0D 0D 00     ORA $000D
C0/A0BC: 00 00        BRK $00
C0/A0BE: 00 00        BRK $00
C0/A0C0: 9B           TXY 
C0/A0C1: 00 9D        BRK $9D
C0/A0C3: 00 9F        BRK $9F
C0/A0C5: 00 A1        BRK $A1
C0/A0C7: 00 A3        BRK $A3
C0/A0C9: 00 A5        BRK $A5
C0/A0CB: 00 A7        BRK $A7
C0/A0CD: 00 A9        BRK $A9
C0/A0CF: 00 00        BRK $00
C0/A0D1: 00 00        BRK $00
C0/A0D3: 00 00        BRK $00
C0/A0D5: 00 00        BRK $00
C0/A0D7: 09 00        ORA #$00
C0/A0D9: 00 00        BRK $00
C0/A0DB: 00 00        BRK $00
C0/A0DD: 00 00        BRK $00
C0/A0DF: 00 00        BRK $00
C0/A0E1: 00 00        BRK $00
C0/A0E3: 00 B2        BRK $B2
C0/A0E5: 00 00        BRK $00
C0/A0E7: 00 00        BRK $00
C0/A0E9: 00 00        BRK $00
C0/A0EB: 00 00        BRK $00
C0/A0ED: 00 00        BRK $00
C0/A0EF: 00 00        BRK $00
C0/A0F1: 00 00        BRK $00
C0/A0F3: 00 00        BRK $00
C0/A0F5: 00 00        BRK $00
C0/A0F7: 00 00        BRK $00
C0/A0F9: 00 00        BRK $00
C0/A0FB: 00 00        BRK $00
C0/A0FD: 00 00        BRK $00
C0/A0FF: 00 00        BRK $00
C0/A101: 00 00        BRK $00
C0/A103: 00 00        BRK $00
C0/A105: 00 00        BRK $00
C0/A107: 00 00        BRK $00
C0/A109: 00 00        BRK $00
C0/A10B: 00 00        BRK $00
C0/A10D: 00 00        BRK $00
C0/A10F: 00 00        BRK $00
C0/A111: 00 00        BRK $00
C0/A113: 00 00        BRK $00
C0/A115: 00 00        BRK $00
C0/A117: 00 00        BRK $00
C0/A119: 00 00        BRK $00
C0/A11B: 00 00        BRK $00
C0/A11D: 00 00        BRK $00
C0/A11F: 00 00        BRK $00
C0/A121: 00 00        BRK $00
C0/A123: 00 00        BRK $00
C0/A125: 00 00        BRK $00
C0/A127: 00 00        BRK $00
C0/A129: 00 00        BRK $00
C0/A12B: 00 00        BRK $00
C0/A12D: 00 00        BRK $00
C0/A12F: 00 00        BRK $00
C0/A131: 00 00        BRK $00
C0/A133: 00 00        BRK $00
C0/A135: 00 00        BRK $00
C0/A137: 00 00        BRK $00
C0/A139: 00 00        BRK $00
C0/A13B: 00 00        BRK $00
C0/A13D: 00 00        BRK $00
C0/A13F: 00 00        BRK $00
C0/A141: 00 00        BRK $00
C0/A143: 0D 0D 00     ORA $000D
C0/A146: 00 00        BRK $00
C0/A148: 00 00        BRK $00
C0/A14A: 00 1D        BRK $1D
C0/A14C: 1D 1D 1D     ORA $1D1D,X
C0/A14F: 00 A7        BRK $A7
C0/A151: 00 A9        BRK $A9
C0/A153: 00 00        BRK $00
C0/A155: 00 00        BRK $00
C0/A157: 00 00        BRK $00
C0/A159: 00 00        BRK $00
C0/A15B: 00 00        BRK $00
C0/A15D: 00 00        BRK $00
C0/A15F: 00 F5        BRK $F5
C0/A161: 00 F6        BRK $F6
C0/A163: 00 F7        BRK $F7
C0/A165: 00 F8        BRK $F8
C0/A167: 00 00        BRK $00
C0/A169: 00 00        BRK $00
C0/A16B: 00 00        BRK $00
C0/A16D: 00 00        BRK $00
C0/A16F: 00 00        BRK $00
C0/A171: 00 00        BRK $00
C0/A173: 00 00        BRK $00
C0/A175: 00 00        BRK $00
C0/A177: 00 00        BRK $00
C0/A179: 00 00        BRK $00
C0/A17B: 00 00        BRK $00
C0/A17D: 00 00        BRK $00
C0/A17F: 00 00        BRK $00
C0/A181: 00 00        BRK $00
C0/A183: 00 00        BRK $00
C0/A185: 00 00        BRK $00
C0/A187: 00 00        BRK $00
C0/A189: 00 00        BRK $00

; [ update timer ]

C0/A18B: AD FB 0A     LDA $0AFB       ; return if timer is disabled
C0/A18E: F0 30        BEQ $A1C0
C0/A190: AE FC 0A     LDX $0AFC
C0/A193: F0 0E        BEQ $A1A3
C0/A195: C2 20        REP #$20
C0/A197: CE FC 0A     DEC $0AFC       ; decrement timer counter
C0/A19A: A5 06        LDA $06
C0/A19C: E2 20        SEP #$20
C0/A19E: 20 C1 A1     JSR $A1C1       ; 
C0/A1A1: 80 1D        BRA $A1C0
C0/A1A3: A5 61        LDA $61
C0/A1A5: 29 1F        AND #$1F
C0/A1A7: D0 17        BNE $A1C0       ; return if scrolling
C0/A1A9: A5 63        LDA $63
C0/A1AB: 29 1F        AND #$1F
C0/A1AD: D0 11        BNE $A1C0
C0/A1AF: 9C FB 0A     STZ $0AFB       ; disable timer
C0/A1B2: A9 01        LDA #$01
C0/A1B4: 85 57        STA $57
C0/A1B6: AE FE 0A     LDX $0AFE       ; timer event
C0/A1B9: 86 CE        STX $CE
C0/A1BB: 20 17 A2     JSR $A217       ; execute event
C0/A1BE: 64 57        STZ $57
C0/A1C0: 60           RTS 

; [ speed up music with timer ]

C0/A1C1: AD FB 0A     LDA $0AFB
C0/A1C4: C9 02        CMP #$02
C0/A1C6: D0 4E        BNE $A216
C0/A1C8: AE FC 0A     LDX $0AFC
C0/A1CB: E0 2C 01     CPX #$012C
C0/A1CE: D0 04        BNE $A1D4
C0/A1D0: A9 07        LDA #$07
C0/A1D2: 80 34        BRA $A208
C0/A1D4: E0 58 02     CPX #$0258
C0/A1D7: D0 04        BNE $A1DD
C0/A1D9: A9 06        LDA #$06
C0/A1DB: 80 2B        BRA $A208
C0/A1DD: E0 B0 04     CPX #$04B0
C0/A1E0: D0 04        BNE $A1E6
C0/A1E2: A9 05        LDA #$05
C0/A1E4: 80 22        BRA $A208
C0/A1E6: E0 08 07     CPX #$0708
C0/A1E9: D0 04        BNE $A1EF
C0/A1EB: A9 04        LDA #$04
C0/A1ED: 80 19        BRA $A208
C0/A1EF: E0 60 09     CPX #$0960
C0/A1F2: D0 04        BNE $A1F8
C0/A1F4: A9 03        LDA #$03
C0/A1F6: 80 10        BRA $A208
C0/A1F8: E0 B8 0B     CPX #$0BB8
C0/A1FB: D0 04        BNE $A201
C0/A1FD: A9 02        LDA #$02
C0/A1FF: 80 07        BRA $A208
C0/A201: E0 10 0E     CPX #$0E10
C0/A204: D0 10        BNE $A216
C0/A206: A9 01        LDA #$01
C0/A208: 8D 01 1D     STA $1D01       ; multiplier 1 to 7 depending on timer
C0/A20B: A9 86        LDA #$86        ; set tempo multiplier (song & sfx)
C0/A20D: 8D 00 1D     STA $1D00
C0/A210: 22 04 00 C4  JSL $C40004
C0/A214: 80 00        BRA $A216
C0/A216: 60           RTS 

; [ execute event ]

C0/A217: 64 D2        STZ $D2
C0/A219: 9C AA 16     STZ $16AA
C0/A21C: C2 20        REP #$20
C0/A21E: A4 06        LDY $06
C0/A220: 84 D4        STY $D4
C0/A222: A5 CE        LDA $CE         ; event index
C0/A224: 0A           ASL 
C0/A225: 18           CLC 
C0/A226: 65 CE        ADC $CE
C0/A228: AA           TAX 
C0/A229: BF 20 33 C8  LDA $C83320,X   ; pointer to event
C0/A22D: 99 26 11     STA $1126,Y
C0/A230: 85 D6        STA $D6
C0/A232: BF 22 33 C8  LDA $C83322,X
C0/A236: 29 FF 00     AND #$00FF
C0/A239: 99 28 11     STA $1128,Y
C0/A23C: 85 D8        STA $D8
C0/A23E: A9 01 00     LDA #$0001
C0/A241: 99 66 11     STA $1166,Y     ; event stack repeat count ???
C0/A244: A5 06        LDA $06
C0/A246: E2 20        SEP #$20
C0/A248: 64 BA        STZ $BA
C0/A24A: A6 D4        LDX $D4
C0/A24C: A0 05 00     LDY #$0005
C0/A24F: B7 D6        LDA [$D6],Y     ; event script
C0/A251: 85 E3        STA $E3
C0/A253: 88           DEY 
C0/A254: B7 D6        LDA [$D6],Y
C0/A256: 85 E2        STA $E2
C0/A258: 88           DEY 
C0/A259: B7 D6        LDA [$D6],Y
C0/A25B: 85 E1        STA $E1
C0/A25D: 88           DEY 
C0/A25E: B7 D6        LDA [$D6],Y
C0/A260: 85 E0        STA $E0
C0/A262: 88           DEY 
C0/A263: B7 D6        LDA [$D6],Y
C0/A265: 85 DF        STA $DF
C0/A267: 88           DEY 
C0/A268: B7 D6        LDA [$D6],Y
C0/A26A: 85 DE        STA $DE

; event command $C7
C0/A26C: C9 C7        CMP #$C7
C0/A26E: D0 08        BNE $A278
C0/A270: E6 D2        INC $D2
C0/A272: 20 0A A4     JSR $A40A
C0/A275: 4C CB A2     JMP $A2CB       ; next command

; event command $CF
C0/A278: C9 CF        CMP #$CF
C0/A27A: D0 08        BNE $A284
C0/A27C: E6 D2        INC $D2
C0/A27E: 20 C9 A3     JSR $A3C9
C0/A281: 4C CB A2     JMP $A2CB       ; next command

; event command $CE
C0/A284: C9 CE        CMP #$CE
C0/A286: D0 06        BNE $A28E
C0/A288: 20 C9 A3     JSR $A3C9
C0/A28B: 4C CB A2     JMP $A2CB       ; next command

; event command $CD
C0/A28E: C9 CD        CMP #$CD
C0/A290: D0 06        BNE $A298
C0/A292: 20 80 A3     JSR $A380       ; jump to event
C0/A295: 4C CB A2     JMP $A2CB       ; next command

; event command $FF: end of script
C0/A298: C9 FF        CMP #$FF
C0/A29A: D0 0A        BNE $A2A6
C0/A29C: A4 D4        LDY $D4
C0/A29E: F0 7C        BEQ $A31C       ; end of event if not a nested event
C0/A2A0: 20 65 A3     JSR $A365       ; return from subroutine
C0/A2A3: 4C CB A2     JMP $A2CB       ; next command

C0/A2A6: C9 05        CMP #$05
C0/A2A8: 90 12        BCC $A2BC
C0/A2AA: C9 70        CMP #$70
C0/A2AC: 90 1A        BCC $A2C8
C0/A2AE: C9 80        CMP #$80
C0/A2B0: 90 07        BCC $A2B9
C0/A2B2: C9 A0        CMP #$A0
C0/A2B4: 90 09        BCC $A2BF
C0/A2B6: 38           SEC 
C0/A2B7: E9 20        SBC #$20
C0/A2B9: 4C 49 A4     JMP $A449       ; event command $70-$7F, $A0-$FF

; event command $00-$04: move object
C0/A2BC: 4C 5F A4     JMP $A45F

; event command $80-$9F: object action
C0/A2BF: A5 DF        LDA $DF
C0/A2C1: C9 05        CMP #$05
C0/A2C3: 90 F7        BCC $A2BC       ; branch if move command
C0/A2C5: 4C F9 C7     JMP $C7F9       ; object action

; event command $05-$6F: party action
C0/A2C8: 4C 32 C9     JMP $C932

; next command
C0/A2CB: C2 20        REP #$20
C0/A2CD: A6 D4        LDX $D4
C0/A2CF: F0 44        BEQ $A315
C0/A2D1: A5 D6        LDA $D6
C0/A2D3: DD 42 11     CMP $1142,X
C0/A2D6: D0 3D        BNE $A315
C0/A2D8: A5 D8        LDA $D8
C0/A2DA: DD 44 11     CMP $1144,X
C0/A2DD: D0 36        BNE $A315
C0/A2DF: BD 62 11     LDA $1162,X
C0/A2E2: 3A           DEC 
C0/A2E3: 9D 62 11     STA $1162,X
C0/A2E6: D0 23        BNE $A30B
C0/A2E8: C6 D4        DEC $D4
C0/A2EA: C6 D4        DEC $D4
C0/A2EC: C6 D4        DEC $D4
C0/A2EE: C6 D4        DEC $D4
C0/A2F0: A6 D4        LDX $D4
C0/A2F2: BD 46 11     LDA $1146,X
C0/A2F5: 85 D6        STA $D6
C0/A2F7: BD 48 11     LDA $1148,X
C0/A2FA: 85 D8        STA $D8
C0/A2FC: A5 06        LDA $06
C0/A2FE: E2 20        SEP #$20
C0/A300: 64 D2        STZ $D2
C0/A302: C2 20        REP #$20
C0/A304: E0 00 00     CPX #$0000
C0/A307: F0 0C        BEQ $A315
C0/A309: 80 C0        BRA $A2CB       ; next command
C0/A30B: BD 22 11     LDA $1122,X
C0/A30E: 85 D6        STA $D6
C0/A310: BD 24 11     LDA $1124,X
C0/A313: 85 D8        STA $D8
C0/A315: A5 06        LDA $06
C0/A317: E2 20        SEP #$20
C0/A319: 4C 48 A2     JMP $A248

; [ end of event ]

C0/A31C: A5 53        LDA $53
C0/A31E: F0 38        BEQ $A358
C0/A320: A5 E6        LDA $E6
C0/A322: F0 34        BEQ $A358
C0/A324: A4 06        LDY $06
C0/A326: 64 E5        STZ $E5
C0/A328: B9 85 14     LDA $1485,Y
C0/A32B: 4A           LSR 
C0/A32C: 90 16        BCC $A344
C0/A32E: B9 7B 14     LDA $147B,Y
C0/A331: 30 04        BMI $A337
C0/A333: 29 7F        AND #$7F
C0/A335: D0 0D        BNE $A344
C0/A337: B9 78 14     LDA $1478,Y
C0/A33A: 85 75        STA $75
C0/A33C: B9 7A 14     LDA $147A,Y
C0/A33F: 85 76        STA $76
C0/A341: 20 E0 3C     JSR $3CE0       ; add object to object layout
C0/A344: C2 20        REP #$20
C0/A346: 98           TYA             ; next object
C0/A347: 18           CLC 
C0/A348: 69 14 00     ADC #$0014
C0/A34B: A8           TAY 
C0/A34C: A5 06        LDA $06
C0/A34E: E2 20        SEP #$20
C0/A350: E6 E5        INC $E5
C0/A352: A5 E5        LDA $E5
C0/A354: C5 E6        CMP $E6
C0/A356: D0 D0        BNE $A328
C0/A358: AD DB 0A     LDA $0ADB
C0/A35B: 1A           INC 
C0/A35C: 85 BF        STA $BF
C0/A35E: A9 01        LDA #$01
C0/A360: 85 58        STA $58
C0/A362: 85 A1        STA $A1
C0/A364: 60           RTS 

; [ event command $FF: return from subroutine ]

C0/A365: C2 20        REP #$20
C0/A367: C6 D4        DEC $D4
C0/A369: C6 D4        DEC $D4
C0/A36B: C6 D4        DEC $D4
C0/A36D: C6 D4        DEC $D4
C0/A36F: A6 D4        LDX $D4
C0/A371: BD 46 11     LDA $1146,X
C0/A374: 85 D6        STA $D6
C0/A376: BD 48 11     LDA $1148,X
C0/A379: 85 D8        STA $D8
C0/A37B: A5 06        LDA $06
C0/A37D: E2 20        SEP #$20
C0/A37F: 60           RTS 

; [ event command $CD: jump to event ]

; +b1: event index

C0/A380: C2 20        REP #$20
C0/A382: A4 D4        LDY $D4         ; event stack pointer
C0/A384: A9 01 00     LDA #$0001
C0/A387: 99 66 11     STA $1166,Y     ; repeat once
C0/A38A: A5 D6        LDA $D6         ; add 3 to event script pointer
C0/A38C: 18           CLC 
C0/A38D: 69 03 00     ADC #$0003
C0/A390: 99 46 11     STA $1146,Y
C0/A393: A5 06        LDA $06
C0/A395: 65 D8        ADC $D8
C0/A397: 99 48 11     STA $1148,Y
C0/A39A: A5 DF        LDA $DF         ; event index
C0/A39C: 0A           ASL 
C0/A39D: 18           CLC 
C0/A39E: 65 DF        ADC $DF
C0/A3A0: AA           TAX 
C0/A3A1: BF 20 33 C8  LDA $C83320,X   ; pointer to event script
C0/A3A5: 99 26 11     STA $1126,Y
C0/A3A8: 85 D6        STA $D6
C0/A3AA: BF 22 33 C8  LDA $C83322,X
C0/A3AE: 29 FF 00     AND #$00FF
C0/A3B1: 99 28 11     STA $1128,Y
C0/A3B4: 85 D8        STA $D8
C0/A3B6: A9 01 00     LDA #$0001
C0/A3B9: 99 66 11     STA $1166,Y     ; repeat once
C0/A3BC: E6 D4        INC $D4         ; increment stack pointer
C0/A3BE: E6 D4        INC $D4
C0/A3C0: E6 D4        INC $D4
C0/A3C2: E6 D4        INC $D4
C0/A3C4: A5 06        LDA $06
C0/A3C6: E2 20        SEP #$20
C0/A3C8: 60           RTS 

; [ event command $CE/$CF:  ]

; b1: repeat count
; b2: branch vector (forward)

C0/A3C9: C2 20        REP #$20
C0/A3CB: A6 D4        LDX $D4
C0/A3CD: A5 DF        LDA $DF         ; repeat count
C0/A3CF: 29 FF 00     AND #$00FF
C0/A3D2: 9D 66 11     STA $1166,X
C0/A3D5: A5 D6        LDA $D6         ; event pointer + 3
C0/A3D7: 18           CLC 
C0/A3D8: 69 03 00     ADC #$0003
C0/A3DB: 85 D6        STA $D6
C0/A3DD: 9D 26 11     STA $1126,X     ; event repeat stack
C0/A3E0: A5 06        LDA $06
C0/A3E2: 65 D8        ADC $D8
C0/A3E4: 85 D8        STA $D8
C0/A3E6: 9D 28 11     STA $1128,X
C0/A3E9: A5 E0        LDA $E0         ; branch vector
C0/A3EB: 29 FF 00     AND #$00FF
C0/A3EE: 18           CLC 
C0/A3EF: 7D 26 11     ADC $1126,X     ; add to repeat pointer
C0/A3F2: 9D 46 11     STA $1146,X
C0/A3F5: A5 06        LDA $06
C0/A3F7: 7D 28 11     ADC $1128,X
C0/A3FA: 9D 48 11     STA $1148,X
C0/A3FD: E6 D4        INC $D4
C0/A3FF: E6 D4        INC $D4
C0/A401: E6 D4        INC $D4
C0/A403: E6 D4        INC $D4
C0/A405: A5 06        LDA $06
C0/A407: E2 20        SEP #$20
C0/A409: 60           RTS 

; [ event command $C7:  ]

; b1: branch vector (forward)

C0/A40A: C2 20        REP #$20
C0/A40C: A6 D4        LDX $D4
C0/A40E: A9 01 00     LDA #$0001
C0/A411: 9D 66 11     STA $1166,X
C0/A414: A5 D6        LDA $D6
C0/A416: 18           CLC 
C0/A417: 69 02 00     ADC #$0002
C0/A41A: 85 D6        STA $D6
C0/A41C: 9D 26 11     STA $1126,X
C0/A41F: A5 06        LDA $06
C0/A421: 65 D8        ADC $D8
C0/A423: 85 D8        STA $D8
C0/A425: 9D 28 11     STA $1128,X
C0/A428: A5 DF        LDA $DF         ; 
C0/A42A: 29 FF 00     AND #$00FF
C0/A42D: 18           CLC 
C0/A42E: 7D 26 11     ADC $1126,X
C0/A431: 9D 46 11     STA $1146,X
C0/A434: A5 06        LDA $06
C0/A436: 7D 28 11     ADC $1128,X
C0/A439: 9D 48 11     STA $1148,X
C0/A43C: E6 D4        INC $D4
C0/A43E: E6 D4        INC $D4
C0/A440: E6 D4        INC $D4
C0/A442: E6 D4        INC $D4
C0/A444: A5 06        LDA $06
C0/A446: E2 20        SEP #$20
C0/A448: 60           RTS 

; event command $70-$7F, $A0-$FF
C0/A449: 38           SEC 
C0/A44A: E9 70        SBC #$70
C0/A44C: C2 20        REP #$20
C0/A44E: 0A           ASL 
C0/A44F: AA           TAX 
C0/A450: BF 08 A5 C0  LDA $C0A508,X   ; event command jump table
C0/A454: 85 23        STA $23
C0/A456: A5 06        LDA $06
C0/A458: E2 20        SEP #$20
C0/A45A: A5 DF        LDA $DF
C0/A45C: 6C 23 0B     JMP ($0B23)     ; execute event command

; [ event command $00-$05: move object ]

C0/A45F: A4 06        LDY $06
C0/A461: B7 D6        LDA [$D6],Y
C0/A463: C9 80        CMP #$80
C0/A465: B0 05        BCS $A46C       ; branch if moving an object (not camera)
C0/A467: 20 8A C9     JSR $C98A       ; init camera movement
C0/A46A: 80 03        BRA $A46F
C0/A46C: 20 C8 C7     JSR $C7C8       ; init object movement
C0/A46F: A9 01        LDA #$01
C0/A471: 20 60 A6     JSR $A660       ; add to event pointer
C0/A474: A5 D2        LDA $D2
C0/A476: F0 10        BEQ $A488       ; branch if not executing in parallel ???
C0/A478: A4 D4        LDY $D4
C0/A47A: BE 42 11     LDX $1142,Y
C0/A47D: E4 D6        CPX $D6
C0/A47F: D0 DE        BNE $A45F
C0/A481: B9 44 11     LDA $1144,Y
C0/A484: C5 D8        CMP $D8
C0/A486: D0 D7        BNE $A45F
C0/A488: A5 53        LDA $53         ; branch if on a normal map ???
C0/A48A: D0 1D        BNE $A4A9
C0/A48C: 20 33 17     JSR $1733       ; update local tile properties (world map)
C0/A48F: 20 8C 0F     JSR $0F8C
C0/A492: 20 1D 1A     JSR $1A1D
C0/A495: 20 95 4C     JSR $4C95       ; clear sprite data
C0/A498: 20 37 21     JSR $2137
C0/A49B: 20 C5 1E     JSR $1EC5
C0/A49E: 20 64 1E     JSR $1E64
C0/A4A1: 20 0A 42     JSR $420A
C0/A4A4: 20 2B 61     JSR $612B
C0/A4A7: 80 1B        BRA $A4C4
C0/A4A9: 20 E8 17     JSR $17E8       ; update local tile properties (normal map)
C0/A4AC: 20 C2 11     JSR $11C2       ; 
C0/A4AF: 20 E4 1A     JSR $1AE4
C0/A4B2: 20 AC 3B     JSR $3BAC
C0/A4B5: 20 95 4C     JSR $4C95       ; clear sprite data
C0/A4B8: 20 7C 23     JSR $237C       ; update party sprite
C0/A4BB: 20 B3 39     JSR $39B3       ; update object sprites
C0/A4BE: 20 42 28     JSR $2842
C0/A4C1: 20 0A 42     JSR $420A
C0/A4C4: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A4C7: A5 BE        LDA $BE
C0/A4C9: 29 7F        AND #$7F
C0/A4CB: D0 BB        BNE $A488
C0/A4CD: A5 61        LDA $61
C0/A4CF: 29 1F        AND #$1F
C0/A4D1: D0 B5        BNE $A488       ; branch if scrolling
C0/A4D3: A5 63        LDA $63
C0/A4D5: 29 1F        AND #$1F
C0/A4D7: D0 AF        BNE $A488
C0/A4D9: 64 BA        STZ $BA
C0/A4DB: 64 3B        STZ $3B
C0/A4DD: 64 3C        STZ $3C
C0/A4DF: A5 E6        LDA $E6
C0/A4E1: F0 22        BEQ $A505       ; branch if there are no objects
C0/A4E3: 64 09        STZ $09
C0/A4E5: A4 06        LDY $06
C0/A4E7: B9 88 14     LDA $1488,Y     ; 
C0/A4EA: D0 9C        BNE $A488
C0/A4EC: B9 86 14     LDA $1486,Y     ; object is moving
C0/A4EF: D0 97        BNE $A488
C0/A4F1: C2 20        REP #$20
C0/A4F3: 98           TYA             ; next object
C0/A4F4: 18           CLC 
C0/A4F5: 69 14 00     ADC #$0014
C0/A4F8: A8           TAY 
C0/A4F9: A5 06        LDA $06
C0/A4FB: E2 20        SEP #$20
C0/A4FD: E6 09        INC $09
C0/A4FF: A5 09        LDA $09
C0/A501: C5 E6        CMP $E6         ; number of objects
C0/A503: D0 E2        BNE $A4E7
C0/A505: 4C CB A2     JMP $A2CB       ; next command

; event command jump table ($70-$7F, $A0-$FF)
C0/A508:              .DW $BCCE, $BCCE, $BCCE, $BCCE, $BCCE, $BCCE, $C27C, $C28A
C0/A518:              .DW $C282, $BA98, $BD0D, $BAFF, $C56F, $C64B, $C6A7, $BB24
C0/A528:              .DW $C735, $BD1E, $C758, $C77C, $C76A, $C78E, $BAEF, $BAF7
C0/A538:              .DW $C04B, $C0E0, $BF92, $BFC0, $BC64, $BB4C, $BAE1, $BF07
C0/A548:              .DW $BF10, $C6D4, $C70B, $C71C, $C212, $C25A, $BAD9, $BE62
C0/A558:              .DW $C67D, $C692, $BFF1, $C00F, $C02D, $BD8D, $C6C4, $A672
C0/A568:              .DW $BC6C, $C6CB, $C1AA, $C6AC, $C6B7, $C65A, $BEE9, $0000
C0/A578:              .DW $C7A4, $C1ED, $C9CE, $C9E4, $0000, $0000, $0000, $0000
C0/A588:              .DW $BCB4, $C5FB, $C1BB, $C5C4, $C236, $C266, $C362, $C623
C0/A598:              .DW $C57A, $BAA8, $B9EF, $BA9E, $BCF5, $B9E5, $0000, $0000
C0/A5A8:              .DW $C3D3, $C3F7, $BDBC, $C418, $B9D5, $B9DD, $B9CF, $B991
C0/A5B8:              .DW $BD36, $B8C8, $B8A0, $B8B7, $0000, $0000, $0000, $0000
C0/A5C8:              .DW $C2AF, $C292, $0000, $C504, $C4E0, $0000, $0000, $0000
C0/A5D8:              .DW $0000, $0000, $0000, $0000, $0000, $0000, $0000, $0000

; 
C0/A5E8:              .DW $B044, $B04C, $B0A7, $B6B0, $B259, $B185, $B548, $AC37
C0/A5F8:              .DW $AC4A, $AC65, $AC71, $B5B1, $B834, $B848, $B83A, $AC01
C0/A608:              .DW $AC1C, $B10B, $AB65, $AB49, $A98B, $A86D, $B052, $B60E
C0/A618:              .DW $A766, $A7C9, $A685, $0000, $0000, $0000, $0000, $0000

C0/A628: A9 01        LDA #$01        ; 1-byte command
C0/A62A: 20 60 A6     JSR $A660
C0/A62D: 4C CB A2     JMP $A2CB       ; next command

C0/A630: A9 02        LDA #$02        ; 2-byte command
C0/A632: 20 60 A6     JSR $A660
C0/A635: 4C CB A2     JMP $A2CB       ; next command

C0/A638: A9 03        LDA #$03        ; 3-byte command
C0/A63A: 20 60 A6     JSR $A660
C0/A63D: 4C CB A2     JMP $A2CB       ; next command

C0/A640: A9 04        LDA #$04        ; 4-byte command
C0/A642: 20 60 A6     JSR $A660
C0/A645: 4C CB A2     JMP $A2CB       ; next command

C0/A648: A9 05        LDA #$05        ; 5-byte command
C0/A64A: 20 60 A6     JSR $A660
C0/A64D: 4C CB A2     JMP $A2CB       ; next command

C0/A650: A9 06        LDA #$06        ; 6-byte command
C0/A652: 20 60 A6     JSR $A660
C0/A655: 4C CB A2     JMP $A2CB       ; next command

C0/A658: A9 07        LDA #$07        ; 7-byte command
C0/A65A: 20 60 A6     JSR $A660
C0/A65D: 4C CB A2     JMP $A2CB       ; next command

C0/A660: C2 20        REP #$20        ; add A to event pointer
C0/A662: 18           CLC 
C0/A663: 65 D6        ADC $D6
C0/A665: 85 D6        STA $D6
C0/A667: A5 06        LDA $06
C0/A669: 65 D8        ADC $D8
C0/A66B: 85 D8        STA $D8
C0/A66D: A5 06        LDA $06
C0/A66F: E2 20        SEP #$20
C0/A671: 60           RTS 

; [ event command $BF:  ]

; b1: subcommand

C0/A672: A5 DF        LDA $DF
C0/A674: C2 20        REP #$20
C0/A676: 0A           ASL 
C0/A677: AA           TAX 
C0/A678: BF E8 A5 C0  LDA $C0A5E8,X   ; event command $BF jump table
C0/A67C: 85 23        STA $23
C0/A67E: A5 06        LDA $06
C0/A680: E2 20        SEP #$20
C0/A682: 6C 23 0B     JMP ($0B23)

; [ event command $BF1A:  ]

C0/A685: A9 FB        LDA #$FB
C0/A687: 8D 25 21     STA $2125
C0/A68A: C2 20        REP #$20
C0/A68C: A9 00 62     LDA #$6200
C0/A68F: 8F 08 6A 7F  STA $7F6A08
C0/A693: 8F 0B 6A 7F  STA $7F6A0B
C0/A697: A9 80 62     LDA #$6280
C0/A69A: 8F 0E 6A 7F  STA $7F6A0E
C0/A69E: A5 06        LDA $06
C0/A6A0: E2 20        SEP #$20
C0/A6A2: A9 3F        LDA #$3F
C0/A6A4: A6 06        LDX $06
C0/A6A6: 9F 00 62 7F  STA $7F6200,X
C0/A6AA: E8           INX 
C0/A6AB: E0 80 00     CPX #$0080
C0/A6AE: D0 F6        BNE $A6A6
C0/A6B0: A9 01        LDA #$01
C0/A6B2: 85 52        STA $52
C0/A6B4: C2 20        REP #$20
C0/A6B6: A6 06        LDX $06
C0/A6B8: A9 08 F7     LDA #$F708
C0/A6BB: 9F 6C 6B 7F  STA $7F6B6C,X
C0/A6BF: E8           INX 
C0/A6C0: E8           INX 
C0/A6C1: E0 E0 00     CPX #$00E0
C0/A6C4: D0 F5        BNE $A6BB
C0/A6C6: A6 06        LDX $06
C0/A6C8: BF 26 A7 C0  LDA $C0A726,X
C0/A6CC: 9F 4C 6C 7F  STA $7F6C4C,X
C0/A6D0: E8           INX 
C0/A6D1: E8           INX 
C0/A6D2: E0 40 00     CPX #$0040
C0/A6D5: D0 F1        BNE $A6C8
C0/A6D7: A5 06        LDA $06
C0/A6D9: E2 20        SEP #$20
C0/A6DB: 64 3D        STZ $3D
C0/A6DD: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A6E0: A5 3D        LDA $3D
C0/A6E2: 29 01        AND #$01
C0/A6E4: F0 06        BEQ $A6EC
C0/A6E6: A5 5E        LDA $5E
C0/A6E8: 29 FB        AND #$FB
C0/A6EA: 80 04        BRA $A6F0
C0/A6EC: A5 5E        LDA $5E
C0/A6EE: 09 04        ORA #$04
C0/A6F0: 8D 0C 42     STA $420C
C0/A6F3: E6 3D        INC $3D
C0/A6F5: A5 3D        LDA $3D
C0/A6F7: C9 08        CMP #$08
C0/A6F9: D0 E2        BNE $A6DD
C0/A6FB: A9 E0        LDA #$E0
C0/A6FD: A6 06        LDX $06
C0/A6FF: 9F 00 62 7F  STA $7F6200,X
C0/A703: E8           INX 
C0/A704: E0 80 00     CPX #$0080
C0/A707: D0 F6        BNE $A6FF
C0/A709: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A70C: A5 5E        LDA $5E
C0/A70E: 09 04        ORA #$04
C0/A710: 8D 0C 42     STA $420C
C0/A713: 64 52        STZ $52
C0/A715: A5 5E        LDA $5E
C0/A717: 29 FB        AND #$FB
C0/A719: 85 5E        STA $5E
C0/A71B: A9 BB        LDA #$BB
C0/A71D: 8D 25 21     STA $2125
C0/A720: 20 7B 8C     JSR $8C7B
C0/A723: 4C 30 A6     JMP $A630       ; 2-byte command

C0/A726: 08           PHP 
C0/A727: F7 09        SBC [$09],Y
C0/A729: F7 0A        SBC [$0A],Y
C0/A72B: F6 0C        INC $0C,X
C0/A72D: F4 0E F2     PEA $F20E
C0/A730: 10 F0        BPL $A722
C0/A732: 12 EE        ORA ($EE)
C0/A734: 14 EC        TRB $EC
C0/A736: 16 EA        ASL $EA,X
C0/A738: 18           CLC 
C0/A739: E8           INX 
C0/A73A: 1A           INC 
C0/A73B: E6 1C        INC $1C
C0/A73D: E4 1E        CPX $1E
C0/A73F: E2 21        SEP #$21
C0/A741: DF 23 DD 26  CMP $26DD23,X
C0/A745: DA           PHX 
C0/A746: 28           PLP 
C0/A747: D8           CLD 
C0/A748: 2B           PLD 
C0/A749: D5 2E        CMP $2E,X
C0/A74B: D2 30        CMP ($30)
C0/A74D: D0 33        BNE $A782
C0/A74F: CD 37 C9     CMP $C937
C0/A752: 3A           DEC 
C0/A753: C6 3D        DEC $3D
C0/A755: C3 41        CMP $41,S
C0/A757: BF 45 BB 49  LDA $49BB45,X
C0/A75B: B7 4E        LDA [$4E],Y
C0/A75D: B2 53        LDA ($53)
C0/A75F: AD 59 A7     LDA $A759
C0/A762: 60           RTS 
C0/A763: A0 69 97     LDY #$9769

; [ event command $BF18:  ]

C0/A766: A9 0F        LDA #$0F
C0/A768: 85 6F        STA $6F
C0/A76A: 20 BE A7     JSR $A7BE
C0/A76D: 20 F4 5B     JSR $5BF4
C0/A770: 20 68 4A     JSR $4A68
C0/A773: 64 3D        STZ $3D
C0/A775: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A778: 20 95 4C     JSR $4C95       ; clear sprite data
C0/A77B: A5 3D        LDA $3D
C0/A77D: 29 01        AND #$01
C0/A77F: D0 06        BNE $A787
C0/A781: A5 5E        LDA $5E
C0/A783: 29 FD        AND #$FD
C0/A785: 80 04        BRA $A78B
C0/A787: A5 5E        LDA $5E
C0/A789: 09 02        ORA #$02
C0/A78B: 85 5E        STA $5E
C0/A78D: A9 1F        LDA #$1F
C0/A78F: 8D 00 0C     STA $0C00
C0/A792: A9 03        LDA #$03
C0/A794: 8D 2A 21     STA $212A
C0/A797: A9 00        LDA #$00
C0/A799: 8D 2B 21     STA $212B
C0/A79C: 20 34 61     JSR $6134
C0/A79F: A5 3D        LDA $3D
C0/A7A1: 4A           LSR 
C0/A7A2: 1A           INC 
C0/A7A3: 1A           INC 
C0/A7A4: 8D 9A 16     STA $169A
C0/A7A7: 20 54 5D     JSR $5D54
C0/A7AA: A5 3D        LDA $3D
C0/A7AC: C9 E0        CMP #$E0
C0/A7AE: D0 03        BNE $A7B3
C0/A7B0: 20 71 4A     JSR $4A71
C0/A7B3: E6 3D        INC $3D
C0/A7B5: A5 3D        LDA $3D
C0/A7B7: C9 F0        CMP #$F0
C0/A7B9: D0 BA        BNE $A775
C0/A7BB: 4C 30 A6     JMP $A630       ; 2-byte command
C0/A7BE: A9 00        LDA #$00
C0/A7C0: 8D 26 21     STA $2126
C0/A7C3: A9 FF        LDA #$FF
C0/A7C5: 8D 27 21     STA $2127
C0/A7C8: 60           RTS 

; [ event command $BF19:  ]

C0/A7C9: A9 0F        LDA #$0F
C0/A7CB: 85 6F        STA $6F
C0/A7CD: 20 BE A7     JSR $A7BE
C0/A7D0: 20 F4 5B     JSR $5BF4
C0/A7D3: 20 68 4A     JSR $4A68
C0/A7D6: A9 1F        LDA #$1F
C0/A7D8: 8D 00 0C     STA $0C00
C0/A7DB: A9 03        LDA #$03
C0/A7DD: 8D 2A 21     STA $212A
C0/A7E0: A9 00        LDA #$00
C0/A7E2: 8D 2B 21     STA $212B
C0/A7E5: A9 40        LDA #$40
C0/A7E7: 85 3D        STA $3D
C0/A7E9: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A7EC: 20 34 61     JSR $6134
C0/A7EF: C6 3D        DEC $3D
C0/A7F1: D0 F6        BNE $A7E9
C0/A7F3: A9 77        LDA #$77
C0/A7F5: 8D 9A 16     STA $169A
C0/A7F8: 20 54 5D     JSR $5D54
C0/A7FB: 64 DA        STZ $DA
C0/A7FD: 64 3D        STZ $3D
C0/A7FF: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A802: 20 95 4C     JSR $4C95       ; clear sprite data
C0/A805: A5 DA        LDA $DA
C0/A807: 18           CLC 
C0/A808: 65 3D        ADC $3D
C0/A80A: 85 DA        STA $DA
C0/A80C: B0 06        BCS $A814
C0/A80E: A5 5E        LDA $5E
C0/A810: 29 FD        AND #$FD
C0/A812: 80 04        BRA $A818
C0/A814: A5 5E        LDA $5E
C0/A816: 09 02        ORA #$02
C0/A818: 85 5E        STA $5E
C0/A81A: 20 34 61     JSR $6134
C0/A81D: E6 3D        INC $3D
C0/A81F: A5 3D        LDA $3D
C0/A821: C9 80        CMP #$80
C0/A823: D0 DA        BNE $A7FF
C0/A825: A9 E0        LDA #$E0
C0/A827: 85 3D        STA $3D
C0/A829: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A82C: A5 3D        LDA $3D
C0/A82E: 29 01        AND #$01
C0/A830: D0 06        BNE $A838
C0/A832: A5 5E        LDA $5E
C0/A834: 29 FD        AND #$FD
C0/A836: 80 04        BRA $A83C
C0/A838: A5 5E        LDA $5E
C0/A83A: 09 02        ORA #$02
C0/A83C: 85 5E        STA $5E
C0/A83E: 20 34 61     JSR $6134
C0/A841: A5 3D        LDA $3D
C0/A843: 4A           LSR 
C0/A844: 1A           INC 
C0/A845: 1A           INC 
C0/A846: 8D 9A 16     STA $169A
C0/A849: 20 54 5D     JSR $5D54
C0/A84C: C6 3D        DEC $3D
C0/A84E: D0 D9        BNE $A829
C0/A850: A5 5E        LDA $5E
C0/A852: 29 FD        AND #$FD
C0/A854: 85 5E        STA $5E
C0/A856: A9 40        LDA #$40
C0/A858: 85 3D        STA $3D
C0/A85A: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A85D: A5 3D        LDA $3D
C0/A85F: C9 10        CMP #$10
C0/A861: D0 03        BNE $A866
C0/A863: 20 71 4A     JSR $4A71
C0/A866: C6 3D        DEC $3D
C0/A868: D0 F0        BNE $A85A
C0/A86A: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF15:  ]

C0/A86D: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A870: A2 00 78     LDX #$7800
C0/A873: 8E AD 16     STX $16AD
C0/A876: A9 DB        LDA #$DB
C0/A878: 85 25        STA $25
C0/A87A: A2 80 5A     LDX #$5A80
C0/A87D: 86 23        STX $23
C0/A87F: A2 00 04     LDX #$0400
C0/A882: 86 26        STX $26
C0/A884: 20 07 41     JSR $4107
C0/A887: E6 A3        INC $A3
C0/A889: 64 3D        STZ $3D
C0/A88B: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A88E: 20 C5 1E     JSR $1EC5
C0/A891: 20 33 A9     JSR $A933
C0/A894: A9 DB        LDA #$DB
C0/A896: 85 25        STA $25
C0/A898: A2 80 5A     LDX #$5A80
C0/A89B: 86 23        STX $23
C0/A89D: A2 00 04     LDX #$0400
C0/A8A0: 86 26        STX $26
C0/A8A2: A5 3D        LDA $3D
C0/A8A4: 4A           LSR 
C0/A8A5: 4A           LSR 
C0/A8A6: 20 07 41     JSR $4107
C0/A8A9: E6 A3        INC $A3
C0/A8AB: E6 3D        INC $3D
C0/A8AD: A5 3D        LDA $3D
C0/A8AF: 10 DA        BPL $A88B
C0/A8B1: 64 3D        STZ $3D
C0/A8B3: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A8B6: 64 49        STZ $49
C0/A8B8: 20 95 4C     JSR $4C95       ; clear sprite data
C0/A8BB: 20 33 A9     JSR $A933
C0/A8BE: A9 A0        LDA #$A0
C0/A8C0: 8D 0F 04     STA $040F
C0/A8C3: A9 60        LDA #$60
C0/A8C5: 38           SEC 
C0/A8C6: ED A0 10     SBC $10A0
C0/A8C9: 8D FC 02     STA $02FC
C0/A8CC: 8D F8 02     STA $02F8
C0/A8CF: A5 3D        LDA $3D
C0/A8D1: 4A           LSR 
C0/A8D2: 4A           LSR 
C0/A8D3: 4A           LSR 
C0/A8D4: 4A           LSR 
C0/A8D5: 18           CLC 
C0/A8D6: 69 7C        ADC #$7C
C0/A8D8: 38           SEC 
C0/A8D9: ED A2 10     SBC $10A2
C0/A8DC: 8D FD 02     STA $02FD
C0/A8DF: A9 8C        LDA #$8C
C0/A8E1: 38           SEC 
C0/A8E2: ED A2 10     SBC $10A2
C0/A8E5: 8D F9 02     STA $02F9
C0/A8E8: A9 38        LDA #$38
C0/A8EA: 8D FE 02     STA $02FE
C0/A8ED: A9 30        LDA #$30
C0/A8EF: 8D FA 02     STA $02FA
C0/A8F2: A9 37        LDA #$37
C0/A8F4: 8D FF 02     STA $02FF
C0/A8F7: A9 07        LDA #$07
C0/A8F9: 8D FB 02     STA $02FB
C0/A8FC: E6 3D        INC $3D
C0/A8FE: D0 B3        BNE $A8B3
C0/A900: AD EE 0A     LDA $0AEE
C0/A903: 09 80        ORA #$80
C0/A905: 8D EE 0A     STA $0AEE
C0/A908: A9 7F        LDA #$7F
C0/A90A: 85 3D        STA $3D
C0/A90C: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A90F: 20 95 4C     JSR $4C95       ; clear sprite data
C0/A912: 20 33 A9     JSR $A933
C0/A915: A9 DB        LDA #$DB
C0/A917: 85 25        STA $25
C0/A919: A2 80 5A     LDX #$5A80
C0/A91C: 86 23        STX $23
C0/A91E: A2 00 04     LDX #$0400
C0/A921: 86 26        STX $26
C0/A923: A5 3D        LDA $3D
C0/A925: 4A           LSR 
C0/A926: 4A           LSR 
C0/A927: 20 07 41     JSR $4107
C0/A92A: E6 A3        INC $A3
C0/A92C: C6 3D        DEC $3D
C0/A92E: D0 DC        BNE $A90C
C0/A930: 4C 30 A6     JMP $A630       ; 2-byte command
C0/A933: A5 3F        LDA $3F
C0/A935: 29 0C        AND #$0C
C0/A937: 4A           LSR 
C0/A938: 18           CLC 
C0/A939: 69 80        ADC #$80
C0/A93B: 8D 02 03     STA $0302
C0/A93E: 1A           INC 
C0/A93F: 8D 06 03     STA $0306
C0/A942: 18           CLC 
C0/A943: 69 10        ADC #$10
C0/A945: 8D 06 02     STA $0206
C0/A948: 3A           DEC 
C0/A949: 8D 02 02     STA $0202
C0/A94C: A9 60        LDA #$60
C0/A94E: 38           SEC 
C0/A94F: ED A2 10     SBC $10A2
C0/A952: 8D 00 03     STA $0300
C0/A955: 8D 00 02     STA $0200
C0/A958: A9 84        LDA #$84
C0/A95A: 38           SEC 
C0/A95B: ED A2 10     SBC $10A2
C0/A95E: 8D 01 03     STA $0301
C0/A961: 8D 05 03     STA $0305
C0/A964: A9 68        LDA #$68
C0/A966: 38           SEC 
C0/A967: ED A2 10     SBC $10A2
C0/A96A: 8D 04 03     STA $0304
C0/A96D: 8D 04 02     STA $0204
C0/A970: A9 8C        LDA #$8C
C0/A972: 38           SEC 
C0/A973: ED A2 10     SBC $10A2
C0/A976: 8D 01 02     STA $0201
C0/A979: 8D 05 02     STA $0205
C0/A97C: A9 37        LDA #$37
C0/A97E: 8D 03 02     STA $0203
C0/A981: 8D 07 02     STA $0207
C0/A984: 8D 03 03     STA $0303
C0/A987: 8D 07 03     STA $0307
C0/A98A: 60           RTS 

; [ event command $BF14:  ]

C0/A98B: A2 00 72     LDX #$7200
C0/A98E: 86 2E        STX $2E
C0/A990: A2 00 10     LDX #$1000
C0/A993: 86 2C        STX $2C
C0/A995: 20 06 4D     JSR $4D06       ; clear vram
C0/A998: A2 00 08     LDX #$0800
C0/A99B: A9 00        LDA #$00
C0/A99D: 9F 21 76 7F  STA $7F7621,X
C0/A9A1: CA           DEX 
C0/A9A2: D0 F9        BNE $A99D
C0/A9A4: 20 68 4A     JSR $4A68
C0/A9A7: A5 5E        LDA $5E
C0/A9A9: 09 18        ORA #$18
C0/A9AB: 85 5E        STA $5E
C0/A9AD: 20 95 4C     JSR $4C95       ; clear sprite data
C0/A9B0: 20 2B 61     JSR $612B
C0/A9B3: 20 41 4E     JSR $4E41       ; wait for vblank
C0/A9B6: A5 3D        LDA $3D
C0/A9B8: 29 E0        AND #$E0
C0/A9BA: 4A           LSR 
C0/A9BB: 4A           LSR 
C0/A9BC: 4A           LSR 
C0/A9BD: 4A           LSR 
C0/A9BE: 85 08        STA $08
C0/A9C0: 18           CLC 
C0/A9C1: 69 72        ADC #$72
C0/A9C3: 8D AE 16     STA $16AE
C0/A9C6: 9C AD 16     STZ $16AD
C0/A9C9: A5 3D        LDA $3D
C0/A9CB: 29 E0        AND #$E0
C0/A9CD: C2 20        REP #$20
C0/A9CF: 0A           ASL 
C0/A9D0: 0A           ASL 
C0/A9D1: 18           CLC 
C0/A9D2: 69 80 69     ADC #$6980
C0/A9D5: 85 23        STA $23
C0/A9D7: A5 06        LDA $06
C0/A9D9: E2 20        SEP #$20
C0/A9DB: A9 DB        LDA #$DB
C0/A9DD: 85 25        STA $25
C0/A9DF: A2 00 04     LDX #$0400
C0/A9E2: 86 26        STX $26
C0/A9E4: A5 3D        LDA $3D
C0/A9E6: 29 1F        AND #$1F
C0/A9E8: 20 07 41     JSR $4107
C0/A9EB: E6 A3        INC $A3
C0/A9ED: 20 0E AA     JSR $AA0E
C0/A9F0: A5 3F        LDA $3F
C0/A9F2: 29 03        AND #$03
C0/A9F4: D0 BD        BNE $A9B3
C0/A9F6: A5 3D        LDA $3D
C0/A9F8: C9 70        CMP #$70
C0/A9FA: D0 03        BNE $A9FF
C0/A9FC: 20 71 4A     JSR $4A71
C0/A9FF: E6 3D        INC $3D
C0/AA01: A5 3D        LDA $3D
C0/AA03: 10 AE        BPL $A9B3
C0/AA05: A5 5E        LDA $5E
C0/AA07: 29 E7        AND #$E7
C0/AA09: 85 5E        STA $5E
C0/AA0B: 4C 30 A6     JMP $A630       ; 2-byte command
C0/AA0E: A4 06        LDY $06
C0/AA10: A5 3F        LDA $3F
C0/AA12: 29 01        AND #$01
C0/AA14: AA           TAX 
C0/AA15: BF 89 AA C0  LDA $C0AA89,X
C0/AA19: F0 59        BEQ $AA74
C0/AA1B: 8A           TXA 
C0/AA1C: 29 F0        AND #$F0
C0/AA1E: 4A           LSR 
C0/AA1F: 4A           LSR 
C0/AA20: 4A           LSR 
C0/AA21: 4A           LSR 
C0/AA22: 4A           LSR 
C0/AA23: 85 08        STA $08
C0/AA25: A9 10        LDA #$10
C0/AA27: 38           SEC 
C0/AA28: E5 08        SBC $08
C0/AA2A: 8D 02 42     STA $4202
C0/AA2D: 8A           TXA 
C0/AA2E: 29 0F        AND #$0F
C0/AA30: 8D 03 42     STA $4203
C0/AA33: 8A           TXA 
C0/AA34: 18           CLC 
C0/AA35: 65 3F        ADC $3F
C0/AA37: DA           PHX 
C0/AA38: AA           TAX 
C0/AA39: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C0/AA3D: 29 07        AND #$07
C0/AA3F: FA           PLX 
C0/AA40: 6D 16 42     ADC $4216
C0/AA43: 99 00 02     STA $0200,Y
C0/AA46: 8A           TXA 
C0/AA47: 29 F0        AND #$F0
C0/AA49: 4A           LSR 
C0/AA4A: 85 08        STA $08
C0/AA4C: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C0/AA50: 29 07        AND #$07
C0/AA52: 18           CLC 
C0/AA53: 69 90        ADC #$90
C0/AA55: 38           SEC 
C0/AA56: E5 08        SBC $08
C0/AA58: 99 01 02     STA $0201,Y
C0/AA5B: 8A           TXA 
C0/AA5C: 18           CLC 
C0/AA5D: 65 3F        ADC $3F
C0/AA5F: 29 08        AND #$08
C0/AA61: 4A           LSR 
C0/AA62: 4A           LSR 
C0/AA63: 18           CLC 
C0/AA64: 7F 89 AA C0  ADC $C0AA89,X
C0/AA68: 99 02 02     STA $0202,Y
C0/AA6B: A9 35        LDA #$35
C0/AA6D: 99 03 02     STA $0203,Y
C0/AA70: C8           INY 
C0/AA71: C8           INY 
C0/AA72: C8           INY 
C0/AA73: C8           INY 
C0/AA74: E8           INX 
C0/AA75: E8           INX 
C0/AA76: E0 C0 00     CPX #$00C0
C0/AA79: 90 9A        BCC $AA15
C0/AA7B: A6 06        LDX $06
C0/AA7D: A9 AA        LDA #$AA
C0/AA7F: 9D 00 04     STA $0400,X
C0/AA82: E8           INX 
C0/AA83: E0 20 00     CPX #$0020
C0/AA86: D0 F5        BNE $AA7D
C0/AA88: 60           RTS 
C0/AA89: 00 00        BRK $00
C0/AA8B: 00 00        BRK $00
C0/AA8D: 00 20        BRK $20
C0/AA8F: 20 20 20     JSR $2020
C0/AA92: 00 00        BRK $00
C0/AA94: 00 00        BRK $00
C0/AA96: 00 00        BRK $00
C0/AA98: 00 00        BRK $00
C0/AA9A: 00 00        BRK $00
C0/AA9C: 00 20        BRK $20
C0/AA9E: 20 20 20     JSR $2020
C0/AAA1: 20 00 00     JSR $0000
C0/AAA4: 00 00        BRK $00
C0/AAA6: 00 00        BRK $00
C0/AAA8: 00 00        BRK $00
C0/AAAA: 00 00        BRK $00
C0/AAAC: 00 20        BRK $20
C0/AAAE: 20 20 20     JSR $2020
C0/AAB1: 40           RTI 
C0/AAB2: 20 00 00     JSR $0000
C0/AAB5: 00 00        BRK $00
C0/AAB7: 00 00        BRK $00
C0/AAB9: 00 00        BRK $00
C0/AABB: 00 00        BRK $00
C0/AABD: 40           RTI 
C0/AABE: 20 40 40     JSR $4040
C0/AAC1: 20 40 20     JSR $2040
C0/AAC4: 00 00        BRK $00
C0/AAC6: 00 00        BRK $00
C0/AAC8: 00 00        BRK $00
C0/AACA: 00 00        BRK $00
C0/AACC: 40           RTI 
C0/AACD: 40           RTI 
C0/AACE: 40           RTI 
C0/AACF: 40           RTI 
C0/AAD0: 40           RTI 
C0/AAD1: 40           RTI 
C0/AAD2: 40           RTI 
C0/AAD3: 40           RTI 
C0/AAD4: 40           RTI 
C0/AAD5: 40           RTI 
C0/AAD6: 00 00        BRK $00
C0/AAD8: 00 00        BRK $00
C0/AADA: 00 00        BRK $00
C0/AADC: 40           RTI 
C0/AADD: 40           RTI 
C0/AADE: 40           RTI 
C0/AADF: 40           RTI 
C0/AAE0: 40           RTI 
C0/AAE1: 40           RTI 
C0/AAE2: 40           RTI 
C0/AAE3: 40           RTI 
C0/AAE4: 40           RTI 
C0/AAE5: 40           RTI 
C0/AAE6: 00 00        BRK $00
C0/AAE8: 00 00        BRK $00
C0/AAEA: 00 40        BRK $40
C0/AAEC: 60           RTS 
C0/AAED: 40           RTI 
C0/AAEE: 60           RTS 
C0/AAEF: 40           RTI 
C0/AAF0: 40           RTI 
C0/AAF1: 40           RTI 
C0/AAF2: 60           RTS 
C0/AAF3: 40           RTI 
C0/AAF4: 60           RTS 
C0/AAF5: 60           RTS 
C0/AAF6: 00 00        BRK $00
C0/AAF8: 00 00        BRK $00
C0/AAFA: 00 60        BRK $60
C0/AAFC: 40           RTI 
C0/AAFD: 60           RTS 
C0/AAFE: 60           RTS 
C0/AAFF: 60           RTS 
C0/AB00: 40           RTI 
C0/AB01: 60           RTS 
C0/AB02: 60           RTS 
C0/AB03: 60           RTS 
C0/AB04: 60           RTS 
C0/AB05: 60           RTS 
C0/AB06: 00 00        BRK $00
C0/AB08: 00 00        BRK $00
C0/AB0A: 00 60        BRK $60
C0/AB0C: 60           RTS 
C0/AB0D: 60           RTS 
C0/AB0E: 80 60        BRA $AB70
C0/AB10: 60           RTS 
C0/AB11: 60           RTS 
C0/AB12: 60           RTS 
C0/AB13: 60           RTS 
C0/AB14: 60           RTS 
C0/AB15: 60           RTS 
C0/AB16: 00 00        BRK $00
C0/AB18: 00 00        BRK $00
C0/AB1A: 00 60        BRK $60
C0/AB1C: 80 80        BRA $AA9E
C0/AB1E: 80 80        BRA $AAA0
C0/AB20: 60           RTS 
C0/AB21: 80 80        BRA $AAA3
C0/AB23: 60           RTS 
C0/AB24: 60           RTS 
C0/AB25: 80 80        BRA $AAA7
C0/AB27: 00 00        BRK $00
C0/AB29: 00 00        BRK $00
C0/AB2B: 00 80        BRK $80
C0/AB2D: 80 80        BRA $AAAF
C0/AB2F: 80 00        BRA $AB31
C0/AB31: 80 80        BRA $AAB3
C0/AB33: 80 80        BRA $AAB5
C0/AB35: 80 80        BRA $AAB7
C0/AB37: 00 00        BRK $00
C0/AB39: 00 00        BRK $00
C0/AB3B: 00 00        BRK $00
C0/AB3D: 80 80        BRA $AABF
C0/AB3F: 00 00        BRK $00
C0/AB41: 80 80        BRA $AAC3
C0/AB43: 00 80        BRK $80
C0/AB45: 80 80        BRA $AAC7
C0/AB47: 00 00        BRK $00

; [ event command $BF13:  ]

C0/AB49: 20 B5 AB     JSR $ABB5
C0/AB4C: 20 68 4A     JSR $4A68
C0/AB4F: A9 7F        LDA #$7F
C0/AB51: 85 3D        STA $3D
C0/AB53: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AB56: 20 8E AB     JSR $AB8E
C0/AB59: C6 3D        DEC $3D
C0/AB5B: A5 3D        LDA $3D
C0/AB5D: 10 F4        BPL $AB53
C0/AB5F: 20 95 4C     JSR $4C95       ; clear sprite data
C0/AB62: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF12:  ]

C0/AB65: 20 B5 AB     JSR $ABB5
C0/AB68: 64 3D        STZ $3D
C0/AB6A: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AB6D: 20 8E AB     JSR $AB8E
C0/AB70: E6 3D        INC $3D
C0/AB72: A5 3D        LDA $3D
C0/AB74: C9 81        CMP #$81
C0/AB76: D0 F2        BNE $AB6A
C0/AB78: 20 71 4A     JSR $4A71
C0/AB7B: 9C 3D 0B     STZ $0B3D
C0/AB7E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AB81: 64 49        STZ $49
C0/AB83: E6 3D        INC $3D
C0/AB85: A5 3D        LDA $3D
C0/AB87: C9 10        CMP #$10
C0/AB89: D0 F3        BNE $AB7E
C0/AB8B: 4C 30 A6     JMP $A630       ; 2-byte command

C0/AB8E: 64 49        STZ $49
C0/AB90: A5 3D        LDA $3D
C0/AB92: 4A           LSR 
C0/AB93: 4A           LSR 
C0/AB94: 4A           LSR 
C0/AB95: 85 DA        STA $DA
C0/AB97: A9 70        LDA #$70
C0/AB99: 18           CLC 
C0/AB9A: 65 DA        ADC $DA
C0/AB9C: 8D 25 02     STA $0225
C0/AB9F: 3A           DEC 
C0/ABA0: 3A           DEC 
C0/ABA1: 8D 21 02     STA $0221
C0/ABA4: A9 58        LDA #$58
C0/ABA6: 18           CLC 
C0/ABA7: 65 DA        ADC $DA
C0/ABA9: 8D 18 02     STA $0218
C0/ABAC: A9 88        LDA #$88
C0/ABAE: 38           SEC 
C0/ABAF: E5 DA        SBC $DA
C0/ABB1: 8D 1C 02     STA $021C
C0/ABB4: 60           RTS 
C0/ABB5: 64 49        STZ $49
C0/ABB7: 20 95 4C     JSR $4C95       ; clear sprite data
C0/ABBA: A6 06        LDX $06
C0/ABBC: BF D5 AB C0  LDA $C0ABD5,X
C0/ABC0: 9D 00 02     STA $0200,X
C0/ABC3: E8           INX 
C0/ABC4: E0 2C 00     CPX #$002C
C0/ABC7: D0 F3        BNE $ABBC
C0/ABC9: A9 AA        LDA #$AA
C0/ABCB: 8D 00 04     STA $0400
C0/ABCE: 8D 01 04     STA $0401
C0/ABD1: 8D 02 04     STA $0402
C0/ABD4: 60           RTS 
C0/ABD5: 50 70        BVC $AC47
C0/ABD7: 30 01        BMI $ABDA
C0/ABD9: 60           RTS 
C0/ABDA: 70 30        BVS $AC0C
C0/ABDC: 01 80        ORA ($80,X)
C0/ABDE: 70 30        BVS $AC10
C0/ABE0: 01 90        ORA ($90,X)
C0/ABE2: 70 30        BVS $AC14
C0/ABE4: 01 70        ORA ($70,X)
C0/ABE6: 80 30        BRA $AC18
C0/ABE8: 01 70        ORA ($70,X)
C0/ABEA: 90 30        BCC $AC1C
C0/ABEC: 01 58        ORA ($58,X)
C0/ABEE: 70 34        BVS $AC24
C0/ABF0: 35 88        AND $88,X
C0/ABF2: 70 34        BVS $AC28
C0/ABF4: 35 70        AND $70,X
C0/ABF6: 6F 36 35 70  ADC $703536
C0/ABFA: 70 30        BVS $AC2C
C0/ABFC: 35 70        AND $70,X
C0/ABFE: 70 32        BVS $AC32
C0/AC00: 35

; [ event command $BF0F: show epilogue cutscene ]

C0/AC01: 9C 0B 42     STZ $420B
C0/AC04: 9C 0C 42     STZ $420C
C0/AC07: A9 00        LDA #$00
C0/AC09: 8D 00 42     STA $4200
C0/AC0C: A9 80        LDA #$80
C0/AC0E: 8D 00 21     STA $2100
C0/AC11: 78           SEI 
C0/AC12: 22 03 00 C1  JSL $C10003     ; epilogue cutscene
C0/AC16: 20 E3 44     JSR $44E3       ; init map bank
C0/AC19: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF10: show game stats (unknown cave psychic) ]

C0/AC1C: 9C 0B 42     STZ $420B
C0/AC1F: 9C 0C 42     STZ $420C
C0/AC22: A9 00        LDA #$00
C0/AC24: 8D 00 42     STA $4200
C0/AC27: A9 80        LDA #$80
C0/AC29: 8D 00 21     STA $2100
C0/AC2C: 78           SEI 
C0/AC2D: 22 06 00 C1  JSL $C10006     ; show game stats (unknown cave psychic)
C0/AC31: 20 E3 44     JSR $44E3       ; init map bank
C0/AC34: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF07:  ]

C0/AC37: 20 28 AD     JSR $AD28
C0/AC3A: 20 0B AE     JSR $AE0B
C0/AC3D: 20 54 AD     JSR $AD54
C0/AC40: A9 01        LDA #$01        ; show party sprite
C0/AC42: 85 BD        STA $BD
C0/AC44: 20 80 AC     JSR $AC80
C0/AC47: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF08:  ]

C0/AC4A: 64 BD        STZ $BD         ; hide party sprite
C0/AC4C: 20 AD 4C     JSR $4CAD       ; hide all sprites
C0/AC4F: 20 A0 AD     JSR $ADA0
C0/AC52: 20 DD AC     JSR $ACDD
C0/AC55: 20 0B AE     JSR $AE0B
C0/AC58: 20 B1 AC     JSR $ACB1
C0/AC5B: A9 01        LDA #$01        ; show party sprite
C0/AC5D: 85 BD        STA $BD
C0/AC5F: 20 80 AC     JSR $AC80
C0/AC62: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF09:  ]

C0/AC65: 20 01 AD     JSR $AD01
C0/AC68: 20 D6 AD     JSR $ADD6
C0/AC6B: 20 80 AC     JSR $AC80
C0/AC6E: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF0A:  ]

C0/AC71: 20 A0 AD     JSR $ADA0
C0/AC74: 20 0B AE     JSR $AE0B
C0/AC77: 20 8B AC     JSR $AC8B
C0/AC7A: 20 80 AC     JSR $AC80
C0/AC7D: 4C 30 A6     JMP $A630       ; 2-byte command
C0/AC80: A9 01        LDA #$01
C0/AC82: 8D 2A 21     STA $212A
C0/AC85: A9 00        LDA #$00
C0/AC87: 8D 2B 21     STA $212B
C0/AC8A: 60           RTS 
C0/AC8B: A9 3F        LDA #$3F
C0/AC8D: 85 3D        STA $3D
C0/AC8F: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AC92: A9 03        LDA #$03
C0/AC94: 8D 2A 21     STA $212A
C0/AC97: A9 01        LDA #$01
C0/AC99: 8D 2B 21     STA $212B
C0/AC9C: A5 3D        LDA $3D
C0/AC9E: 1A           INC 
C0/AC9F: 1A           INC 
C0/ACA0: 8D 9A 16     STA $169A
C0/ACA3: 20 30 5D     JSR $5D30
C0/ACA6: 20 86 AD     JSR $AD86
C0/ACA9: C6 3D        DEC $3D
C0/ACAB: D0 E2        BNE $AC8F
C0/ACAD: 20 7B 8C     JSR $8C7B
C0/ACB0: 60           RTS 
C0/ACB1: A9 3F        LDA #$3F
C0/ACB3: 85 3D        STA $3D
C0/ACB5: 20 41 4E     JSR $4E41       ; wait for vblank
C0/ACB8: A9 03        LDA #$03
C0/ACBA: 8D 2A 21     STA $212A
C0/ACBD: A9 01        LDA #$01
C0/ACBF: 8D 2B 21     STA $212B
C0/ACC2: A5 3D        LDA $3D
C0/ACC4: 1A           INC 
C0/ACC5: 1A           INC 
C0/ACC6: 8D 9A 16     STA $169A
C0/ACC9: 20 30 5D     JSR $5D30
C0/ACCC: 20 86 AD     JSR $AD86
C0/ACCF: 20 B7 AD     JSR $ADB7
C0/ACD2: C6 3D        DEC $3D
C0/ACD4: D0 DF        BNE $ACB5
C0/ACD6: 20 41 4E     JSR $4E41       ; wait for vblank
C0/ACD9: 20 7B 8C     JSR $8C7B
C0/ACDC: 60           RTS 
C0/ACDD: A9 70        LDA #$70
C0/ACDF: 85 3D        STA $3D
C0/ACE1: 20 41 4E     JSR $4E41       ; wait for vblank
C0/ACE4: A9 03        LDA #$03
C0/ACE6: 8D 2A 21     STA $212A
C0/ACE9: A9 00        LDA #$00
C0/ACEB: 8D 2B 21     STA $212B
C0/ACEE: A5 3D        LDA $3D
C0/ACF0: 1A           INC 
C0/ACF1: 1A           INC 
C0/ACF2: 8D 9A 16     STA $169A
C0/ACF5: 20 30 5D     JSR $5D30
C0/ACF8: C6 3D        DEC $3D
C0/ACFA: A5 3D        LDA $3D
C0/ACFC: C9 40        CMP #$40
C0/ACFE: D0 E1        BNE $ACE1
C0/AD00: 60           RTS 
C0/AD01: 64 3D        STZ $3D
C0/AD03: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AD06: A9 03        LDA #$03
C0/AD08: 8D 2A 21     STA $212A
C0/AD0B: A9 01        LDA #$01
C0/AD0D: 8D 2B 21     STA $212B
C0/AD10: A5 3D        LDA $3D
C0/AD12: 1A           INC 
C0/AD13: 1A           INC 
C0/AD14: 8D 9A 16     STA $169A
C0/AD17: 20 30 5D     JSR $5D30
C0/AD1A: 20 86 AD     JSR $AD86
C0/AD1D: E6 3D        INC $3D
C0/AD1F: A5 3D        LDA $3D
C0/AD21: C9 40        CMP #$40
C0/AD23: D0 DE        BNE $AD03
C0/AD25: 64 BD        STZ $BD         ; hide party sprite
C0/AD27: 60           RTS 
C0/AD28: 64 3D        STZ $3D
C0/AD2A: 64 DA        STZ $DA
C0/AD2C: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AD2F: A9 03        LDA #$03
C0/AD31: 8D 2A 21     STA $212A
C0/AD34: A9 01        LDA #$01
C0/AD36: 8D 2B 21     STA $212B
C0/AD39: A5 3D        LDA $3D
C0/AD3B: 1A           INC 
C0/AD3C: 1A           INC 
C0/AD3D: 8D 9A 16     STA $169A
C0/AD40: 20 30 5D     JSR $5D30
C0/AD43: 20 86 AD     JSR $AD86
C0/AD46: 20 B7 AD     JSR $ADB7
C0/AD49: E6 3D        INC $3D
C0/AD4B: A5 3D        LDA $3D
C0/AD4D: C9 40        CMP #$40
C0/AD4F: D0 DB        BNE $AD2C
C0/AD51: 64 BD        STZ $BD         ; hide party sprite
C0/AD53: 60           RTS 
C0/AD54: A9 40        LDA #$40
C0/AD56: 85 3D        STA $3D
C0/AD58: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AD5B: A9 03        LDA #$03
C0/AD5D: 8D 2A 21     STA $212A
C0/AD60: A9 00        LDA #$00
C0/AD62: 8D 2B 21     STA $212B
C0/AD65: A5 3D        LDA $3D
C0/AD67: 1A           INC 
C0/AD68: 1A           INC 
C0/AD69: 8D 9A 16     STA $169A
C0/AD6C: 20 30 5D     JSR $5D30
C0/AD6F: A5 3D        LDA $3D
C0/AD71: C9 60        CMP #$60
C0/AD73: D0 08        BNE $AD7D
C0/AD75: A9 90        LDA #$90
C0/AD77: 85 43        STA $43
C0/AD79: A9 F0        LDA #$F0
C0/AD7B: 85 45        STA $45
C0/AD7D: E6 3D        INC $3D
C0/AD7F: A5 3D        LDA $3D
C0/AD81: C9 78        CMP #$78
C0/AD83: D0 D3        BNE $AD58
C0/AD85: 60           RTS 
C0/AD86: A9 C0        LDA #$C0
C0/AD88: 85 25        STA $25
C0/AD8A: A2 40 D3     LDX #$D340
C0/AD8D: 86 23        STX $23
C0/AD8F: A2 20 00     LDX #$0020
C0/AD92: 86 2C        STX $2C
C0/AD94: A2 80 01     LDX #$0180
C0/AD97: A9 7F        LDA #$7F
C0/AD99: 38           SEC 
C0/AD9A: E5 3D        SBC $3D
C0/AD9C: 20 6B 40     JSR $406B
C0/AD9F: 60           RTS 
C0/ADA0: A9 C0        LDA #$C0
C0/ADA2: 85 25        STA $25
C0/ADA4: A2 40 D3     LDX #$D340
C0/ADA7: 86 23        STX $23
C0/ADA9: A2 20 00     LDX #$0020
C0/ADAC: 86 2C        STX $2C
C0/ADAE: A2 80 01     LDX #$0180
C0/ADB1: A9 40        LDA #$40
C0/ADB3: 20 6B 40     JSR $406B
C0/ADB6: 60           RTS 
C0/ADB7: A5 DA        LDA $DA
C0/ADB9: 29 1F        AND #$1F
C0/ADBB: 18           CLC 
C0/ADBC: 65 3D        ADC $3D
C0/ADBE: 85 DA        STA $DA
C0/ADC0: 29 60        AND #$60
C0/ADC2: F0 04        BEQ $ADC8
C0/ADC4: A9 00        LDA #$00
C0/ADC6: 80 02        BRA $ADCA
C0/ADC8: A9 01        LDA #$01        ; show party sprite
C0/ADCA: 85 BD        STA $BD
C0/ADCC: 20 95 4C     JSR $4C95       ; clear sprite data
C0/ADCF: 20 37 21     JSR $2137
C0/ADD2: 20 2B 61     JSR $612B
C0/ADD5: 60           RTS 
C0/ADD6: 64 DA        STZ $DA
C0/ADD8: 64 DB        STZ $DB
C0/ADDA: 64 3D        STZ $3D
C0/ADDC: 20 41 4E     JSR $4E41       ; wait for vblank
C0/ADDF: A9 03        LDA #$03
C0/ADE1: 8D 2A 21     STA $212A
C0/ADE4: A9 01        LDA #$01
C0/ADE6: 8D 2B 21     STA $212B
C0/ADE9: 20 32 AE     JSR $AE32
C0/ADEC: A5 3D        LDA $3D
C0/ADEE: 29 01        AND #$01
C0/ADF0: 09 3E        ORA #$3E
C0/ADF2: 8D 9A 16     STA $169A
C0/ADF5: 20 30 5D     JSR $5D30
C0/ADF8: A5 3D        LDA $3D
C0/ADFA: C9 F0        CMP #$F0
C0/ADFC: D0 08        BNE $AE06
C0/ADFE: A9 90        LDA #$90
C0/AE00: 85 43        STA $43
C0/AE02: A9 F0        LDA #$F0
C0/AE04: 85 45        STA $45
C0/AE06: E6 3D        INC $3D
C0/AE08: D0 D2        BNE $ADDC
C0/AE0A: 60           RTS 
C0/AE0B: 64 DA        STZ $DA
C0/AE0D: 64 DB        STZ $DB
C0/AE0F: 64 3D        STZ $3D
C0/AE11: 20 41 4E     JSR $4E41       ; wait for vblank
C0/AE14: A9 03        LDA #$03
C0/AE16: 8D 2A 21     STA $212A
C0/AE19: A9 01        LDA #$01
C0/AE1B: 8D 2B 21     STA $212B
C0/AE1E: 20 32 AE     JSR $AE32
C0/AE21: A5 3D        LDA $3D
C0/AE23: 29 01        AND #$01
C0/AE25: 09 3E        ORA #$3E
C0/AE27: 8D 9A 16     STA $169A
C0/AE2A: 20 30 5D     JSR $5D30
C0/AE2D: E6 3D        INC $3D
C0/AE2F: D0 E0        BNE $AE11
C0/AE31: 60           RTS 
C0/AE32: A0 70 00     LDY #$0070
C0/AE35: 84 13        STY $13
C0/AE37: A0 68 00     LDY #$0068
C0/AE3A: 84 15        STY $15
C0/AE3C: A9 AA        LDA #$AA
C0/AE3E: 8D 10 04     STA $0410
C0/AE41: 8D 11 04     STA $0411
C0/AE44: 8D 12 04     STA $0412
C0/AE47: 8D 13 04     STA $0413
C0/AE4A: 20 2B 4F     JSR $4F2B       ; generate random number
C0/AE4D: 29 01        AND #$01
C0/AE4F: D0 1C        BNE $AE6D
C0/AE51: 20 2B 4F     JSR $4F2B       ; generate random number
C0/AE54: 29 E0        AND #$E0
C0/AE56: 85 DA        STA $DA
C0/AE58: 20 2B 4F     JSR $4F2B       ; generate random number
C0/AE5B: 29 E0        AND #$E0
C0/AE5D: 85 DB        STA $DB
C0/AE5F: 20 2B 4F     JSR $4F2B       ; generate random number
C0/AE62: 29 C0        AND #$C0
C0/AE64: 85 DC        STA $DC
C0/AE66: 20 2B 4F     JSR $4F2B       ; generate random number
C0/AE69: 29 C0        AND #$C0
C0/AE6B: 85 DD        STA $DD
C0/AE6D: A5 DA        LDA $DA
C0/AE6F: AA           TAX 
C0/AE70: A4 06        LDY $06
C0/AE72: A5 3D        LDA $3D
C0/AE74: 4A           LSR 
C0/AE75: B0 50        BCS $AEC7
C0/AE77: BF 44 AF C0  LDA $C0AF44,X
C0/AE7B: C9 80        CMP #$80
C0/AE7D: F0 48        BEQ $AEC7
C0/AE7F: A5 DC        LDA $DC
C0/AE81: 0A           ASL 
C0/AE82: 30 09        BMI $AE8D
C0/AE84: A5 13        LDA $13
C0/AE86: 18           CLC 
C0/AE87: 7F 44 AF C0  ADC $C0AF44,X
C0/AE8B: 80 07        BRA $AE94
C0/AE8D: A5 13        LDA $13
C0/AE8F: 38           SEC 
C0/AE90: FF 44 AF C0  SBC $C0AF44,X
C0/AE94: 99 00 03     STA $0300,Y
C0/AE97: A5 DC        LDA $DC
C0/AE99: 30 09        BMI $AEA4
C0/AE9B: A5 15        LDA $15
C0/AE9D: 18           CLC 
C0/AE9E: 7F 45 AF C0  ADC $C0AF45,X
C0/AEA2: 80 07        BRA $AEAB
C0/AEA4: A5 15        LDA $15
C0/AEA6: 38           SEC 
C0/AEA7: FF 45 AF C0  SBC $C0AF45,X
C0/AEAB: 99 01 03     STA $0301,Y
C0/AEAE: A5 3D        LDA $3D
C0/AEB0: 0A           ASL 
C0/AEB1: 0A           ASL 
C0/AEB2: 29 08        AND #$08
C0/AEB4: 18           CLC 
C0/AEB5: 7F 46 AF C0  ADC $C0AF46,X
C0/AEB9: 99 02 03     STA $0302,Y
C0/AEBC: BF 47 AF C0  LDA $C0AF47,X
C0/AEC0: 45 DC        EOR $DC
C0/AEC2: 99 03 03     STA $0303,Y
C0/AEC5: 80 05        BRA $AECC
C0/AEC7: A9 F0        LDA #$F0
C0/AEC9: 99 01 03     STA $0301,Y
C0/AECC: E8           INX 
C0/AECD: E8           INX 
C0/AECE: E8           INX 
C0/AECF: E8           INX 
C0/AED0: C8           INY 
C0/AED1: C8           INY 
C0/AED2: C8           INY 
C0/AED3: C8           INY 
C0/AED4: C0 20 00     CPY #$0020
C0/AED7: D0 99        BNE $AE72
C0/AED9: A5 DB        LDA $DB
C0/AEDB: AA           TAX 
C0/AEDC: A5 3D        LDA $3D
C0/AEDE: 4A           LSR 
C0/AEDF: B0 50        BCS $AF31
C0/AEE1: BF 44 AF C0  LDA $C0AF44,X
C0/AEE5: C9 80        CMP #$80
C0/AEE7: F0 48        BEQ $AF31
C0/AEE9: A5 DD        LDA $DD
C0/AEEB: 0A           ASL 
C0/AEEC: 30 09        BMI $AEF7
C0/AEEE: A5 13        LDA $13
C0/AEF0: 18           CLC 
C0/AEF1: 7F 44 AF C0  ADC $C0AF44,X
C0/AEF5: 80 07        BRA $AEFE
C0/AEF7: A5 13        LDA $13
C0/AEF9: 38           SEC 
C0/AEFA: FF 44 AF C0  SBC $C0AF44,X
C0/AEFE: 99 00 03     STA $0300,Y
C0/AF01: A5 DD        LDA $DD
C0/AF03: 30 09        BMI $AF0E
C0/AF05: BF 45 AF C0  LDA $C0AF45,X
C0/AF09: 18           CLC 
C0/AF0A: 65 15        ADC $15
C0/AF0C: 80 07        BRA $AF15
C0/AF0E: A5 15        LDA $15
C0/AF10: 38           SEC 
C0/AF11: FF 45 AF C0  SBC $C0AF45,X
C0/AF15: 99 01 03     STA $0301,Y
C0/AF18: A5 3D        LDA $3D
C0/AF1A: 0A           ASL 
C0/AF1B: 0A           ASL 
C0/AF1C: 29 08        AND #$08
C0/AF1E: 18           CLC 
C0/AF1F: 7F 46 AF C0  ADC $C0AF46,X
C0/AF23: 99 02 03     STA $0302,Y
C0/AF26: BF 47 AF C0  LDA $C0AF47,X
C0/AF2A: 45 DD        EOR $DD
C0/AF2C: 99 03 03     STA $0303,Y
C0/AF2F: 80 05        BRA $AF36
C0/AF31: A9 F0        LDA #$F0
C0/AF33: 99 01 03     STA $0301,Y
C0/AF36: E8           INX 
C0/AF37: E8           INX 
C0/AF38: E8           INX 
C0/AF39: E8           INX 
C0/AF3A: C8           INY 
C0/AF3B: C8           INY 
C0/AF3C: C8           INY 
C0/AF3D: C8           INY 
C0/AF3E: C0 40 00     CPY #$0040
C0/AF41: D0 99        BNE $AEDC
C0/AF43: 60           RTS 
C0/AF44: 00 B0        BRK $B0
C0/AF46: 30 3B        BMI $AF83
C0/AF48: 10 B0        BPL $AEFA
C0/AF4A: 32 3B        AND ($3B)
C0/AF4C: 20 B0 36     JSR $36B0
C0/AF4F: 3B           TSC 
C0/AF50: 00 C0        BRK $C0
C0/AF52: 36 BB        ROL $BB,X
C0/AF54: 30 C0        BMI $AF16
C0/AF56: 34 3B        BIT $3B,X
C0/AF58: 30 D0        BMI $AF2A
C0/AF5A: 30 BB        BMI $AF17
C0/AF5C: 40           RTI 
C0/AF5D: D0 36        BNE $AF95
C0/AF5F: 3B           TSC 
C0/AF60: 40           RTI 
C0/AF61: E0 34 3B     CPX #$3B34
C0/AF64: 00 E0        BRK $E0
C0/AF66: 36 3B        ROL $3B,X
C0/AF68: 00 F0        BRK $F0
C0/AF6A: 30 BB        BMI $AF27
C0/AF6C: 10 F0        BPL $AF5E
C0/AF6E: 36 3B        ROL $3B,X
C0/AF70: 10 00        BPL $AF72
C0/AF72: 34 3B        BIT $3B,X
C0/AF74: 00 10        BRK $10
C0/AF76: 30 3B        BMI $AFB3
C0/AF78: 10 10        BPL $AF8A
C0/AF7A: 36 BB        ROL $BB,X
C0/AF7C: 80 00        BRA $AF7E
C0/AF7E: 30 3B        BMI $AFBB
C0/AF80: 80 00        BRA $AF82
C0/AF82: 30 3B        BMI $AFBF
C0/AF84: F0 C0        BEQ $AF46
C0/AF86: 30 3B        BMI $AFC3
C0/AF88: 00 C0        BRK $C0
C0/AF8A: 32 3B        AND ($3B)
C0/AF8C: 10 C0        BPL $AF4E
C0/AF8E: 36 3B        ROL $3B,X
C0/AF90: E0 D0 30     CPX #$30D0
C0/AF93: 3B           TSC 
C0/AF94: F0 D0        BEQ $AF66
C0/AF96: 36 BB        ROL $BB,X
C0/AF98: 10 D0        BPL $AF6A
C0/AF9A: 34 3B        BIT $3B,X
C0/AF9C: E0 E0 36     CPX #$36E0
C0/AF9F: BB           TYX 
C0/AFA0: 10 E0        BPL $AF82
C0/AFA2: 36 BB        ROL $BB,X
C0/AFA4: E0 B0 30     CPX #$30B0
C0/AFA7: 3B           TSC 
C0/AFA8: F0 B0        BEQ $AF5A
C0/AFAA: 32 3B        AND ($3B)
C0/AFAC: 00 B0        BRK $B0
C0/AFAE: 36 3B        ROL $3B,X
C0/AFB0: E0 C0 34     CPX #$34C0
C0/AFB3: 3B           TSC 
C0/AFB4: 00 C0        BRK $C0
C0/AFB6: 30 BB        BMI $AF73
C0/AFB8: 10 C0        BPL $AF7A
C0/AFBA: 36 3B        ROL $3B,X
C0/AFBC: 80 00        BRA $AFBE
C0/AFBE: 30 3B        BMI $AFFB
C0/AFC0: 80 00        BRA $AFC2
C0/AFC2: 30 3B        BMI $AFFF
C0/AFC4: 00 D0        BRK $D0
C0/AFC6: 30 3B        BMI $B003
C0/AFC8: 10 D0        BPL $AF9A
C0/AFCA: 32 3B        AND ($3B)
C0/AFCC: 20 D0 36     JSR $36D0
C0/AFCF: 3B           TSC 
C0/AFD0: 20 E0 34     JSR $34E0
C0/AFD3: 3B           TSC 
C0/AFD4: 20 F0 36     JSR $36F0
C0/AFD7: BB           TYX 
C0/AFD8: 80 00        BRA $AFDA
C0/AFDA: 30 3B        BMI $B017
C0/AFDC: 80 00        BRA $AFDE
C0/AFDE: 30 3B        BMI $B01B
C0/AFE0: 80 00        BRA $AFE2
C0/AFE2: 30 3B        BMI $B01F
C0/AFE4: F0 C0        BEQ $AFA6
C0/AFE6: 30 3B        BMI $B023
C0/AFE8: 00 C0        BRK $C0
C0/AFEA: 36 3B        ROL $3B,X
C0/AFEC: E0 D0 30     CPX #$30D0
C0/AFEF: 3B           TSC 
C0/AFF0: F0 D0        BEQ $AFC2
C0/AFF2: 36 BB        ROL $BB,X
C0/AFF4: 00 D0        BRK $D0
C0/AFF6: 30 BB        BMI $AFB3
C0/AFF8: 10 D0        BPL $AFCA
C0/AFFA: 32 3B        AND ($3B)
C0/AFFC: 80 00        BRA $AFFE
C0/AFFE: 30 3B        BMI $B03B
C0/B000: 80 00        BRA $B002
C0/B002: 30 3B        BMI $B03F
C0/B004: 20 D0 30     JSR $30D0
C0/B007: 3B           TSC 
C0/B008: 30 D0        BMI $AFDA
C0/B00A: 36 3B        ROL $3B,X
C0/B00C: 30 E0        BMI $AFEE
C0/B00E: 30 BB        BMI $AFCB
C0/B010: 40           RTI 
C0/B011: E0 36 3B     CPX #$3B36
C0/B014: 40           RTI 
C0/B015: F0 34        BEQ $B04B
C0/B017: 3B           TSC 
C0/B018: 30 00        BMI $B01A
C0/B01A: 30 3B        BMI $B057
C0/B01C: 40           RTI 
C0/B01D: 00 36        BRK $36
C0/B01F: BB           TYX 
C0/B020: 80 00        BRA $B022
C0/B022: 30 3B        BMI $B05F
C0/B024: 00 E0        BRK $E0
C0/B026: 32 3B        AND ($3B)
C0/B028: 10 E0        BPL $B00A
C0/B02A: 36 3B        ROL $3B,X
C0/B02C: 10 F0        BPL $B01E
C0/B02E: 30 BB        BMI $AFEB
C0/B030: 20 F0 36     JSR $36F0
C0/B033: 3B           TSC 
C0/B034: 20 00 34     JSR $3400
C0/B037: 3B           TSC 
C0/B038: 80 00        BRA $B03A
C0/B03A: 30 3B        BMI $B077
C0/B03C: 80 00        BRA $B03E
C0/B03E: 30 3B        BMI $B07B
C0/B040: 80 00        BRA $B042
C0/B042: 30 3B        BMI $B07F

; [ event command $BF00: game over ]

C0/B044: A9 F0        LDA #$F0        ; don't reset spc
C0/B046: 8D 00 1D     STA $1D00
C0/B049: 4C 00 00     JMP $0000       ; reset

; [ event command $BF01: load parent map ]

C0/B04C: 20 8F 54     JSR $548F       ; load parent map
C0/B04F: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF16:  ]

C0/B052: A9 FF        LDA #$FF
C0/B054: 85 3D        STA $3D
C0/B056: A2 10 04     LDX #$0410
C0/B059: 8E 53 1A     STX $1A53
C0/B05C: A9 07        LDA #$07
C0/B05E: 8D 55 1A     STA $1A55
C0/B061: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B064: A5 3D        LDA $3D
C0/B066: 4A           LSR 
C0/B067: 4A           LSR 
C0/B068: 4A           LSR 
C0/B069: 4A           LSR 
C0/B06A: AA           TAX 
C0/B06B: BF FB B0 C0  LDA $C0B0FB,X
C0/B06F: 8D AF 16     STA $16AF
C0/B072: A9 34        LDA #$34
C0/B074: 8D B0 16     STA $16B0
C0/B077: A0 80 02     LDY #$0280
C0/B07A: 84 23        STY $23
C0/B07C: A0 58 03     LDY #$0358
C0/B07F: 84 26        STY $26
C0/B081: A0 74 00     LDY #$0074
C0/B084: 84 13        STY $13
C0/B086: 84 15        STY $15
C0/B088: A6 06        LDX $06
C0/B08A: 8E B1 16     STX $16B1
C0/B08D: 20 48 4F     JSR $4F48       ; update shattering crystal
C0/B090: C2 20        REP #$20
C0/B092: AD 53 1A     LDA $1A53
C0/B095: 38           SEC 
C0/B096: E9 04 00     SBC #$0004
C0/B099: 8D 53 1A     STA $1A53
C0/B09C: A5 06        LDA $06
C0/B09E: E2 20        SEP #$20
C0/B0A0: C6 3D        DEC $3D
C0/B0A2: D0 BD        BNE $B061
C0/B0A4: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF02: crystal shatters ]

C0/B0A7: 64 3D        STZ $3D
C0/B0A9: A2 20 00     LDX #$0020
C0/B0AC: 8E 53 1A     STX $1A53
C0/B0AF: A9 01        LDA #$01
C0/B0B1: 8D 55 1A     STA $1A55
C0/B0B4: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B0B7: A5 3D        LDA $3D
C0/B0B9: 4A           LSR 
C0/B0BA: 4A           LSR 
C0/B0BB: 4A           LSR 
C0/B0BC: AA           TAX 
C0/B0BD: BF FB B0 C0  LDA $C0B0FB,X
C0/B0C1: 8D AF 16     STA $16AF
C0/B0C4: A9 34        LDA #$34
C0/B0C6: 8D B0 16     STA $16B0
C0/B0C9: A0 80 02     LDY #$0280
C0/B0CC: 84 23        STY $23
C0/B0CE: A0 58 03     LDY #$0358
C0/B0D1: 84 26        STY $26
C0/B0D3: A0 74 00     LDY #$0074
C0/B0D6: 84 13        STY $13
C0/B0D8: 84 15        STY $15
C0/B0DA: A6 06        LDX $06
C0/B0DC: 8E B1 16     STX $16B1
C0/B0DF: 20 48 4F     JSR $4F48       ; update shattering crystal
C0/B0E2: C2 20        REP #$20
C0/B0E4: AD 53 1A     LDA $1A53
C0/B0E7: 18           CLC 
C0/B0E8: 69 10 00     ADC #$0010
C0/B0EB: 8D 53 1A     STA $1A53
C0/B0EE: A5 06        LDA $06
C0/B0F0: E2 20        SEP #$20
C0/B0F2: E6 3D        INC $3D
C0/B0F4: A5 3D        LDA $3D
C0/B0F6: 10 BC        BPL $B0B4
C0/B0F8: 4C 30 A6     JMP $A630       ; 2-byte command

C0/B0FB: 10 11        BPL $B10E
C0/B0FD: 12 13        ORA ($13)
C0/B0FF: 14 15        TRB $15
C0/B101: 16 17        ASL $17,X
C0/B103: 17 17        ORA [$17],Y
C0/B105: 17 17        ORA [$17],Y
C0/B107: 17 17        ORA [$17],Y
C0/B109: 17 17        ORA [$17],Y

; [ event command $BF11:  ]

C0/B10B: A9 07        LDA #$07
C0/B10D: 85 6F        STA $6F
C0/B10F: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B112: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B115: A9 01        LDA #$01
C0/B117: 85 52        STA $52
C0/B119: 20 F4 5B     JSR $5BF4
C0/B11C: 20 68 4A     JSR $4A68
C0/B11F: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B122: A2 00 78     LDX #$7800
C0/B125: 86 2E        STX $2E
C0/B127: A2 00 08     LDX #$0800
C0/B12A: 86 2C        STX $2C
C0/B12C: A9 DB        LDA #$DB
C0/B12E: 85 25        STA $25
C0/B130: A2 80 6D     LDX #$6D80
C0/B133: 86 23        STX $23
C0/B135: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/B138: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B13B: A2 00 7C     LDX #$7C00
C0/B13E: 86 2E        STX $2E
C0/B140: A2 00 08     LDX #$0800
C0/B143: 86 2C        STX $2C
C0/B145: A9 DB        LDA #$DB
C0/B147: 85 25        STA $25
C0/B149: A2 80 75     LDX #$7580
C0/B14C: 86 23        STX $23
C0/B14E: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/B151: 64 52        STZ $52
C0/B153: A2 80 FF     LDX #$FF80
C0/B156: 86 15        STX $15
C0/B158: 64 3D        STZ $3D
C0/B15A: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B15D: A5 3F        LDA $3F
C0/B15F: 4A           LSR 
C0/B160: 90 F8        BCC $B15A
C0/B162: A6 63        LDX $63
C0/B164: E8           INX 
C0/B165: 86 63        STX $63
C0/B167: A5 3D        LDA $3D
C0/B169: C9 B0        CMP #$B0
C0/B16B: B0 05        BCS $B172
C0/B16D: A6 15        LDX $15
C0/B16F: E8           INX 
C0/B170: 86 15        STX $15
C0/B172: 20 40 B2     JSR $B240
C0/B175: A5 3D        LDA $3D
C0/B177: C9 F0        CMP #$F0
C0/B179: D0 03        BNE $B17E
C0/B17B: 20 71 4A     JSR $4A71
C0/B17E: E6 3D        INC $3D
C0/B180: D0 D8        BNE $B15A
C0/B182: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF05:  ]

C0/B185: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B188: 20 F4 5B     JSR $5BF4
C0/B18B: A9 07        LDA #$07
C0/B18D: 85 6F        STA $6F
C0/B18F: A2 00 78     LDX #$7800
C0/B192: 86 2E        STX $2E
C0/B194: A2 00 10     LDX #$1000
C0/B197: 86 2C        STX $2C
C0/B199: 20 06 4D     JSR $4D06       ; clear vram
C0/B19C: A2 50 00     LDX #$0050
C0/B19F: 86 15        STX $15
C0/B1A1: A9 00        LDA #$00
C0/B1A3: 20 CD B3     JSR $B3CD
C0/B1A6: 20 E8 4C     JSR $4CE8       ; disable interrupts
C0/B1A9: A2 00 7C     LDX #$7C00
C0/B1AC: 86 2E        STX $2E
C0/B1AE: A2 00 08     LDX #$0800
C0/B1B1: 86 2C        STX $2C
C0/B1B3: A9 DB        LDA #$DB
C0/B1B5: 85 25        STA $25
C0/B1B7: A2 80 75     LDX #$7580
C0/B1BA: 86 23        STX $23
C0/B1BC: 20 BC 4C     JSR $4CBC       ; copy data to vram
C0/B1BF: 20 FA 4C     JSR $4CFA       ; enable interrupts
C0/B1C2: 20 68 4A     JSR $4A68
C0/B1C5: 64 3D        STZ $3D
C0/B1C7: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B1CA: A9 DF        LDA #$DF
C0/B1CC: 85 25        STA $25
C0/B1CE: A2 24 FE     LDX #$FE24
C0/B1D1: 86 23        STX $23
C0/B1D3: A2 18 00     LDX #$0018
C0/B1D6: 86 2C        STX $2C
C0/B1D8: A2 04 01     LDX #$0104
C0/B1DB: A5 3D        LDA $3D
C0/B1DD: 4A           LSR 
C0/B1DE: 1A           INC 
C0/B1DF: 20 6B 40     JSR $406B
C0/B1E2: A2 00 78     LDX #$7800
C0/B1E5: 8E AD 16     STX $16AD
C0/B1E8: A9 DB        LDA #$DB
C0/B1EA: 85 25        STA $25
C0/B1EC: A2 80 6D     LDX #$6D80
C0/B1EF: 86 23        STX $23
C0/B1F1: A2 00 08     LDX #$0800
C0/B1F4: 86 26        STX $26
C0/B1F6: A5 3D        LDA $3D
C0/B1F8: 4A           LSR 
C0/B1F9: 4A           LSR 
C0/B1FA: 4A           LSR 
C0/B1FB: 20 07 41     JSR $4107
C0/B1FE: E6 A3        INC $A3
C0/B200: E6 3D        INC $3D
C0/B202: D0 C3        BNE $B1C7
C0/B204: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B207: A5 3D        LDA $3D
C0/B209: 4A           LSR 
C0/B20A: B0 05        BCS $B211
C0/B20C: A6 15        LDX $15
C0/B20E: CA           DEX 
C0/B20F: 86 15        STX $15
C0/B211: 20 40 B2     JSR $B240
C0/B214: E6 3D        INC $3D
C0/B216: A5 3D        LDA $3D
C0/B218: C9 60        CMP #$60
C0/B21A: D0 E8        BNE $B204
C0/B21C: 64 3D        STZ $3D
C0/B21E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B221: 20 40 B2     JSR $B240
C0/B224: A5 3D        LDA $3D
C0/B226: 4A           LSR 
C0/B227: B0 05        BCS $B22E
C0/B229: A6 63        LDX $63
C0/B22B: E8           INX 
C0/B22C: 86 63        STX $63
C0/B22E: A5 3D        LDA $3D
C0/B230: C9 F0        CMP #$F0
C0/B232: D0 03        BNE $B237
C0/B234: 20 71 4A     JSR $4A71
C0/B237: E6 3D        INC $3D
C0/B239: D0 E3        BNE $B21E
C0/B23B: 64 52        STZ $52
C0/B23D: 4C 30 A6     JMP $A630       ; 2-byte command
C0/B240: A5 3F        LDA $3F
C0/B242: 4A           LSR 
C0/B243: 4A           LSR 
C0/B244: 4A           LSR 
C0/B245: 29 07        AND #$07
C0/B247: AA           TAX 
C0/B248: BF 50 B2 C0  LDA $C0B250,X
C0/B24C: 20 CD B3     JSR $B3CD
C0/B24F: 60           RTS 
C0/B250: 00 00        BRK $00
C0/B252: 00 60        BRK $60
C0/B254: C0 C0 C0     CPY #$C0C0
C0/B257: C0 60

; [ event command $BF04:  ]

C0/B259: 20 71 B3     JSR $B371
C0/B25C: A9 38        LDA #$38
C0/B25E: 85 13        STA $13
C0/B260: A9 58        LDA #$58
C0/B262: 85 15        STA $15
C0/B264: A0 80 00     LDY #$0080
C0/B267: A2 50 00     LDX #$0050
C0/B26A: 20 A5 B2     JSR $B2A5
C0/B26D: 64 3D        STZ $3D
C0/B26F: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B272: 20 AD 4C     JSR $4CAD       ; hide all sprites
C0/B275: 20 5C B3     JSR $B35C
C0/B278: A2 00 78     LDX #$7800
C0/B27B: 8E AD 16     STX $16AD
C0/B27E: A9 DB        LDA #$DB
C0/B280: 85 25        STA $25
C0/B282: A2 40 7A     LDX #$7A40
C0/B285: 86 23        STX $23
C0/B287: A2 00 08     LDX #$0800
C0/B28A: 86 26        STX $26
C0/B28C: A5 3D        LDA $3D
C0/B28E: 4A           LSR 
C0/B28F: 4A           LSR 
C0/B290: 4A           LSR 
C0/B291: 20 07 41     JSR $4107
C0/B294: E6 A3        INC $A3
C0/B296: 20 FD B5     JSR $B5FD
C0/B299: E6 3D        INC $3D
C0/B29B: D0 D2        BNE $B26F
C0/B29D: 20 94 B5     JSR $B594
C0/B2A0: 64 52        STZ $52
C0/B2A2: 4C 30 A6     JMP $A630       ; 2-byte command
C0/B2A5: 84 0D        STY $0D
C0/B2A7: A4 06        LDY $06
C0/B2A9: 98           TYA 
C0/B2AA: 29 E0        AND #$E0
C0/B2AC: 4A           LSR 
C0/B2AD: 18           CLC 
C0/B2AE: 65 15        ADC $15
C0/B2B0: 99 01 03     STA $0301,Y
C0/B2B3: 98           TYA 
C0/B2B4: 29 1C        AND #$1C
C0/B2B6: 0A           ASL 
C0/B2B7: 0A           ASL 
C0/B2B8: 18           CLC 
C0/B2B9: 65 13        ADC $13
C0/B2BB: 99 00 03     STA $0300,Y
C0/B2BE: BF EC B2 C0  LDA $C0B2EC,X
C0/B2C2: 29 0F        AND #$0F
C0/B2C4: 09 80        ORA #$80
C0/B2C6: 99 02 03     STA $0302,Y
C0/B2C9: BF EC B2 C0  LDA $C0B2EC,X
C0/B2CD: 29 C0        AND #$C0
C0/B2CF: 09 31        ORA #$31
C0/B2D1: 99 03 03     STA $0303,Y
C0/B2D4: E8           INX 
C0/B2D5: C8           INY 
C0/B2D6: C8           INY 
C0/B2D7: C8           INY 
C0/B2D8: C8           INY 
C0/B2D9: C4 0D        CPY $0D
C0/B2DB: D0 CC        BNE $B2A9
C0/B2DD: A0 10 00     LDY #$0010
C0/B2E0: A9 AA        LDA #$AA
C0/B2E2: 99 00 04     STA $0400,Y
C0/B2E5: C8           INY 
C0/B2E6: C0 20 00     CPY #$0020
C0/B2E9: D0 F7        BNE $B2E2
C0/B2EB: 60           RTS 

C0/B2EC: 02 02        COP $02
C0/B2EE: 02 02        COP $02
C0/B2F0: 02 02        COP $02
C0/B2F2: 02 84        COP $84
C0/B2F4: 02 02        COP $02
C0/B2F6: 02 02        COP $02
C0/B2F8: 02 02        COP $02
C0/B2FA: 84 00        STY $00
C0/B2FC: 02 02        COP $02
C0/B2FE: 02 02        COP $02
C0/B300: 02 02        COP $02
C0/B302: 04 00        TSB $00
C0/B304: 02 02        COP $02
C0/B306: 02 02        COP $02
C0/B308: 02 02        COP $02
C0/B30A: 02 04        COP $04
C0/B30C: 02 02        COP $02
C0/B30E: 02 02        COP $02
C0/B310: 02 02        COP $02
C0/B312: 02 02        COP $02
C0/B314: 02 02        COP $02
C0/B316: 02 02        COP $02
C0/B318: 02 02        COP $02
C0/B31A: 02 02        COP $02
C0/B31C: 02 02        COP $02
C0/B31E: 02 02        COP $02
C0/B320: 02 02        COP $02
C0/B322: 02 02        COP $02
C0/B324: 02 02        COP $02
C0/B326: 02 02        COP $02
C0/B328: 02 02        COP $02
C0/B32A: 02 02        COP $02
C0/B32C: 02 02        COP $02
C0/B32E: 02 02        COP $02
C0/B330: 02 02        COP $02
C0/B332: 02 02        COP $02
C0/B334: 02 02        COP $02
C0/B336: 02 02        COP $02
C0/B338: 02 02        COP $02
C0/B33A: 02 02        COP $02
C0/B33C: 06 06        ASL $06
C0/B33E: 06 06        ASL $06
C0/B340: 06 06        ASL $06
C0/B342: 06 06        ASL $06
C0/B344: 02 02        COP $02
C0/B346: 02 02        COP $02
C0/B348: 02 02        COP $02
C0/B34A: 02 02        COP $02
C0/B34C: 02 02        COP $02
C0/B34E: 02 02        COP $02
C0/B350: 02 02        COP $02
C0/B352: 02 02        COP $02
C0/B354: 02 02        COP $02
C0/B356: 02 02        COP $02
C0/B358: 02 02        COP $02
C0/B35A: 02 02        COP $02

C0/B35C: A9 00        LDA #$00
C0/B35E: 8D 1B 21     STA $211B
C0/B361: A9 02        LDA #$02
C0/B363: 8D 1B 21     STA $211B
C0/B366: A9 00        LDA #$00
C0/B368: 8D 1E 21     STA $211E
C0/B36B: A9 02        LDA #$02
C0/B36D: 8D 1E 21     STA $211E
C0/B370: 60           RTS 
C0/B371: A9 02        LDA #$02
C0/B373: 85 5E        STA $5E
C0/B375: A2 00 78     LDX #$7800
C0/B378: 86 2E        STX $2E
C0/B37A: A2 00 10     LDX #$1000
C0/B37D: 86 2C        STX $2C
C0/B37F: 20 06 4D     JSR $4D06       ; clear vram
C0/B382: A9 0A        LDA #$0A
C0/B384: 85 DF        STA $DF
C0/B386: A9 00        LDA #$00
C0/B388: 85 E0        STA $E0
C0/B38A: 20 AE BA     JSR $BAAE       ; change color palette
C0/B38D: A9 01        LDA #$01
C0/B38F: 85 A4        STA $A4
C0/B391: E6 A2        INC $A2
C0/B393: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B396: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B399: A9 01        LDA #$01
C0/B39B: 85 52        STA $52
C0/B39D: 20 F1 41     JSR $41F1
C0/B3A0: 20 68 4A     JSR $4A68
C0/B3A3: 64 3D        STZ $3D
C0/B3A5: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B3A8: A5 3D        LDA $3D
C0/B3AA: 8D 1B 21     STA $211B
C0/B3AD: A9 01        LDA #$01
C0/B3AF: 8D 1B 21     STA $211B
C0/B3B2: A5 3D        LDA $3D
C0/B3B4: 8D 1E 21     STA $211E
C0/B3B7: A9 01        LDA #$01
C0/B3B9: 8D 1E 21     STA $211E
C0/B3BC: A5 3D        LDA $3D
C0/B3BE: 4A           LSR 
C0/B3BF: 4A           LSR 
C0/B3C0: 4A           LSR 
C0/B3C1: 4A           LSR 
C0/B3C2: 20 01 5C     JSR $5C01
C0/B3C5: E6 3D        INC $3D
C0/B3C7: D0 DC        BNE $B3A5
C0/B3C9: 20 F4 5B     JSR $5BF4
C0/B3CC: 60           RTS 
C0/B3CD: AA           TAX 
C0/B3CE: A4 06        LDY $06
C0/B3D0: BF 28 B4 C0  LDA $C0B428,X
C0/B3D4: 18           CLC 
C0/B3D5: 69 2C        ADC #$2C
C0/B3D7: 99 00 02     STA $0200,Y
C0/B3DA: BF 29 B4 C0  LDA $C0B429,X
C0/B3DE: C2 20        REP #$20
C0/B3E0: C9 FF 00     CMP #$00FF
C0/B3E3: F0 12        BEQ $B3F7
C0/B3E5: 18           CLC 
C0/B3E6: 65 15        ADC $15
C0/B3E8: C9 F0 FF     CMP #$FFF0
C0/B3EB: B0 05        BCS $B3F2
C0/B3ED: C9 F0 00     CMP #$00F0
C0/B3F0: B0 05        BCS $B3F7
C0/B3F2: 29 FF 00     AND #$00FF
C0/B3F5: 80 03        BRA $B3FA
C0/B3F7: A9 F0 00     LDA #$00F0
C0/B3FA: E2 20        SEP #$20
C0/B3FC: 99 01 02     STA $0201,Y
C0/B3FF: BF 2A B4 C0  LDA $C0B42A,X
C0/B403: 99 02 02     STA $0202,Y
C0/B406: BF 2B B4 C0  LDA $C0B42B,X
C0/B40A: 99 03 02     STA $0203,Y
C0/B40D: E8           INX 
C0/B40E: E8           INX 
C0/B40F: E8           INX 
C0/B410: E8           INX 
C0/B411: C8           INY 
C0/B412: C8           INY 
C0/B413: C8           INY 
C0/B414: C8           INY 
C0/B415: C0 60 00     CPY #$0060
C0/B418: D0 B6        BNE $B3D0
C0/B41A: A4 06        LDY $06
C0/B41C: A9 AA        LDA #$AA
C0/B41E: 99 00 04     STA $0400,Y
C0/B421: C8           INY 
C0/B422: C0 20 00     CPY #$0020
C0/B425: D0 F7        BNE $B41E
C0/B427: 60           RTS 
C0/B428: 00 00        BRK $00
C0/B42A: A6 71        LDX $71
C0/B42C: 10 00        BPL $B42E
C0/B42E: A4 71        LDY $71
C0/B430: 20 00 A2     JSR $A200
C0/B433: 71 30        ADC ($30),Y
C0/B435: 00 A0        BRK $A0
C0/B437: 71 50        ADC ($50),Y
C0/B439: 00 A0        BRK $A0
C0/B43B: 31 60        AND ($60),Y
C0/B43D: 00 A2        BRK $A2
C0/B43F: 31 70        AND ($70),Y
C0/B441: 00 A4        BRK $A4
C0/B443: 31 80        AND ($80),Y
C0/B445: 00 A6        BRK $A6
C0/B447: 31 10        AND ($10),Y
C0/B449: 10 AC        BPL $B3F7
C0/B44B: 71 20        ADC ($20),Y
C0/B44D: 10 AA        BPL $B3F9
C0/B44F: 71 30        ADC ($30),Y
C0/B451: 10 A8        BPL $B3FB
C0/B453: 71 40        ADC ($40),Y
C0/B455: 10 80        BPL $B3D7
C0/B457: 31 50        AND ($50),Y
C0/B459: 10 A8        BPL $B403
C0/B45B: 31 60        AND ($60),Y
C0/B45D: 10 AA        BPL $B409
C0/B45F: 31 70        AND ($70),Y
C0/B461: 10 AC        BPL $B40F
C0/B463: 31 30        AND ($30),Y
C0/B465: 20 82 31     JSR $3182
C0/B468: 40           RTI 
C0/B469: 20 84 31     JSR $3184
C0/B46C: 50 20        BVC $B48E
C0/B46E: 86 31        STX $31
C0/B470: 30 30        BMI $B4A2
C0/B472: 88           DEY 
C0/B473: 31 40        AND ($40),Y
C0/B475: 30 8A        BMI $B401
C0/B477: 31 50        AND ($50),Y
C0/B479: 30 8C        BMI $B407
C0/B47B: 31 40        AND ($40),Y
C0/B47D: 40           RTI 
C0/B47E: 8E 31 80     STX $8031
C0/B481: FF 00 00 80  SBC $800000,X
C0/B485: FF 00 00 00  SBC $000000,X
C0/B489: 10 C4        BPL $B44F
C0/B48B: 71 10        ADC ($10),Y
C0/B48D: 10 C2        BPL $B451
C0/B48F: 71 20        ADC ($20),Y
C0/B491: 10 C0        BPL $B453
C0/B493: 71 30        ADC ($30),Y
C0/B495: 10 AE        BPL $B445
C0/B497: 71 40        ADC ($40),Y
C0/B499: 10 E4        BPL $B47F
C0/B49B: 31 50        AND ($50),Y
C0/B49D: 10 AE        BPL $B44D
C0/B49F: 31 60        AND ($60),Y
C0/B4A1: 10 C0        BPL $B463
C0/B4A3: 31 70        AND ($70),Y
C0/B4A5: 10 C2        BPL $B469
C0/B4A7: 31 80        AND ($80),Y
C0/B4A9: 10 C4        BPL $B46F
C0/B4AB: 31 30        AND ($30),Y
C0/B4AD: 20 82 31     JSR $3182
C0/B4B0: 40           RTI 
C0/B4B1: 20 84 31     JSR $3184
C0/B4B4: 50 20        BVC $B4D6
C0/B4B6: 86 31        STX $31
C0/B4B8: 30 30        BMI $B4EA
C0/B4BA: 88           DEY 
C0/B4BB: 31 40        AND ($40),Y
C0/B4BD: 30 8A        BMI $B449
C0/B4BF: 31 50        AND ($50),Y
C0/B4C1: 30 8C        BMI $B44F
C0/B4C3: 31 40        AND ($40),Y
C0/B4C5: 40           RTI 
C0/B4C6: 8E 31 80     STX $8031
C0/B4C9: FF 00 00 80  SBC $800000,X
C0/B4CD: FF 00 00 80  SBC $800000,X
C0/B4D1: FF 00 00 80  SBC $800000,X
C0/B4D5: FF 00 00 80  SBC $800000,X
C0/B4D9: FF 00 00 80  SBC $800000,X
C0/B4DD: FF 00 00 80  SBC $800000,X
C0/B4E1: FF 00 00 80  SBC $800000,X
C0/B4E5: FF 00 00 30  SBC $300000,X
C0/B4E9: 10 C6        BPL $B4B1
C0/B4EB: 71 40        ADC ($40),Y
C0/B4ED: 10 E0        BPL $B4CF
C0/B4EF: 31 50        AND ($50),Y
C0/B4F1: 10 C6        BPL $B4B9
C0/B4F3: 31 20        AND ($20),Y
C0/B4F5: 20 CA 71     JSR $71CA
C0/B4F8: 30 20        BMI $B51A
C0/B4FA: E2 31        SEP #$31
C0/B4FC: 40           RTI 
C0/B4FD: 20 84 31     JSR $3184
C0/B500: 50 20        BVC $B522
C0/B502: C8           INY 
C0/B503: 31 60        AND ($60),Y
C0/B505: 20 CA 31     JSR $31CA
C0/B508: 10 30        BPL $B53A
C0/B50A: CE 71 20     DEC $2071
C0/B50D: 30 CC        BMI $B4DB
C0/B50F: 71 30        ADC ($30),Y
C0/B511: 30 88        BMI $B49B
C0/B513: 31 40        AND ($40),Y
C0/B515: 30 8A        BMI $B4A1
C0/B517: 31 50        AND ($50),Y
C0/B519: 30 8C        BMI $B4A7
C0/B51B: 31 60        AND ($60),Y
C0/B51D: 30 CC        BMI $B4EB
C0/B51F: 31 70        AND ($70),Y
C0/B521: 30 CE        BMI $B4F1
C0/B523: 31 40        AND ($40),Y
C0/B525: 40           RTI 
C0/B526: 8E 31 80     STX $8031
C0/B529: FF 00 00 80  SBC $800000,X
C0/B52D: FF 00 00 80  SBC $800000,X
C0/B531: FF 00 00 80  SBC $800000,X
C0/B535: FF 00 00 80  SBC $800000,X
C0/B539: FF 00 00 80  SBC $800000,X
C0/B53D: FF 00 00 80  SBC $800000,X
C0/B541: FF 00 00 80  SBC $800000,X
C0/B545: FF 00 00

; [ event command $BF06:  ]

C0/B548: 20 71 B3     JSR $B371
C0/B54B: A9 40        LDA #$40
C0/B54D: 85 13        STA $13
C0/B54F: A9 40        LDA #$40
C0/B551: 85 15        STA $15
C0/B553: A0 C0 00     LDY #$00C0
C0/B556: A2 00        LDX #$00
C0/B558: 00 20        BRK $20
C0/B55A: A5 B2        LDA $B2
C0/B55C: 64 3D        STZ $3D
C0/B55E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B561: 20 AD 4C     JSR $4CAD       ; hide all sprites
C0/B564: 20 5C B3     JSR $B35C
C0/B567: A2 00        LDX #$00
C0/B569: 78           SEI 
C0/B56A: 8E AD 16     STX $16AD
C0/B56D: A9 DB        LDA #$DB
C0/B56F: 85 25        STA $25
C0/B571: A2 40        LDX #$40
C0/B573: 7A           PLY 
C0/B574: 86 23        STX $23
C0/B576: A2 00        LDX #$00
C0/B578: 04 86        TSB $86
C0/B57A: 26 A5        ROL $A5
C0/B57C: 3D 4A 4A     AND $4A4A,X
C0/B57F: 4A           LSR 
C0/B580: 20 07 41     JSR $4107
C0/B583: E6 A3        INC $A3
C0/B585: 20 FD B5     JSR $B5FD
C0/B588: E6 3D        INC $3D
C0/B58A: D0 D2        BNE $B55E
C0/B58C: 20 94 B5     JSR $B594
C0/B58F: 64 52        STZ $52
C0/B591: 4C 30 A6     JMP $A630       ; 2-byte command

; [  ]

C0/B594: A9 84        LDA #$84
C0/B596: 85 43        STA $43
C0/B598: A9 F0        LDA #$F0
C0/B59A: 85 45        STA $45
C0/B59C: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B59F: 20 AD 4C     JSR $4CAD       ; hide all sprites
C0/B5A2: 20 5C B3     JSR $B35C
C0/B5A5: 20 0A 42     JSR $420A
C0/B5A8: E6 3D        INC $3D
C0/B5AA: A5 3D        LDA $3D
C0/B5AC: C9 40        CMP #$40
C0/B5AE: D0 EC        BNE $B59C
C0/B5B0: 60           RTS 

; [ event command $BF0B: tower of walse sinking ]

C0/B5B1: 20 71 B3     JSR $B371
C0/B5B4: A9 22        LDA #$22
C0/B5B6: 85 13        STA $13
C0/B5B8: A9 41        LDA #$41
C0/B5BA: 85 15        STA $15
C0/B5BC: A0 E0 00     LDY #$00E0
C0/B5BF: A2 00        LDX #$00
C0/B5C1: 00 20        BRK $20
C0/B5C3: A5 B2        LDA $B2
C0/B5C5: 64 3D        STZ $3D
C0/B5C7: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B5CA: 20 AD 4C     JSR $4CAD       ; hide all sprites
C0/B5CD: 20 5C B3     JSR $B35C
C0/B5D0: A2 00        LDX #$00
C0/B5D2: 78           SEI 
C0/B5D3: 8E AD 16     STX $16AD
C0/B5D6: A9 DB        LDA #$DB
C0/B5D8: 85 25        STA $25
C0/B5DA: A2 40        LDX #$40
C0/B5DC: 7A           PLY 
C0/B5DD: 86 23        STX $23
C0/B5DF: A2 00        LDX #$00
C0/B5E1: 08           PHP 
C0/B5E2: 86 26        STX $26
C0/B5E4: A5 3D        LDA $3D
C0/B5E6: 4A           LSR 
C0/B5E7: 4A           LSR 
C0/B5E8: 4A           LSR 
C0/B5E9: 20 07 41     JSR $4107
C0/B5EC: E6 A3        INC $A3
C0/B5EE: 20 FD B5     JSR $B5FD
C0/B5F1: E6 3D        INC $3D
C0/B5F3: D0 D2        BNE $B5C7
C0/B5F5: 20 94 B5     JSR $B594
C0/B5F8: 64 52        STZ $52
C0/B5FA: 4C 30 A6     JMP $A630       ; 2-byte command

; [  ]

C0/B5FD: A9 C7        LDA #$C7
C0/B5FF: 85 DF        STA $DF
C0/B601: A9 1E        LDA #$1E
C0/B603: 85 E0        STA $E0
C0/B605: 85 E1        STA $E1
C0/B607: 20 F5 B9     JSR $B9F5
C0/B60A: 20 0A 42     JSR $420A
C0/B60D: 60           RTS 

; [ event command $BF17:  ]

C0/B60E: 20 E8 4C     JSR $4CE8       ; disable interrupts
C0/B611: 20 14 1E     JSR $1E14
C0/B614: 20 FA 4C     JSR $4CFA       ; enable interrupts
C0/B617: A2 00        LDX #$00
C0/B619: 78           SEI 
C0/B61A: 8E AD 16     STX $16AD
C0/B61D: A9 DB        LDA #$DB
C0/B61F: 85 25        STA $25
C0/B621: A2 80        LDX #$80
C0/B623: 55 86        EOR $86,X
C0/B625: 23 A2        AND $A2,S
C0/B627: 00 07        BRK $07
C0/B629: 86 26        STX $26
C0/B62B: A9 1F        LDA #$1F
C0/B62D: 20 07 41     JSR $4107
C0/B630: E6 A3        INC $A3
C0/B632: 20 68 4A     JSR $4A68
C0/B635: 20 50 B7     JSR $B750
C0/B638: 20 F4 5B     JSR $5BF4
C0/B63B: A9 0F        LDA #$0F
C0/B63D: 85 6F        STA $6F
C0/B63F: A9 FF        LDA #$FF
C0/B641: 85 3D        STA $3D
C0/B643: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B646: A5 3D        LDA $3D
C0/B648: 4A           LSR 
C0/B649: 4A           LSR 
C0/B64A: 85 DA        STA $DA
C0/B64C: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B64F: 20 91 B7     JSR $B791
C0/B652: 20 2B 61     JSR $612B
C0/B655: A9 87        LDA #$87
C0/B657: 85 DF        STA $DF
C0/B659: A9 1E        LDA #$1E
C0/B65B: 85 E0        STA $E0
C0/B65D: A5 3D        LDA $3D
C0/B65F: 49 FF        EOR #$FF
C0/B661: 1A           INC 
C0/B662: 4A           LSR 
C0/B663: 4A           LSR 
C0/B664: 4A           LSR 
C0/B665: 4A           LSR 
C0/B666: 18           CLC 
C0/B667: 69 0E        ADC #$0E
C0/B669: 85 E1        STA $E1
C0/B66B: 20 F5 B9     JSR $B9F5
C0/B66E: 20 0A 42     JSR $420A
C0/B671: 20 9F BC     JSR $BC9F
C0/B674: C6 3D        DEC $3D
C0/B676: A5 3D        LDA $3D
C0/B678: D0 C9        BNE $B643
C0/B67A: 64 3D        STZ $3D
C0/B67C: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B67F: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B682: 20 91 B7     JSR $B791
C0/B685: 20 2B 61     JSR $612B
C0/B688: A9 87        LDA #$87
C0/B68A: 85 DF        STA $DF
C0/B68C: A9 1E        LDA #$1E
C0/B68E: 85 E0        STA $E0
C0/B690: 85 E1        STA $E1
C0/B692: 20 F5 B9     JSR $B9F5
C0/B695: 20 0A 42     JSR $420A
C0/B698: 20 9F BC     JSR $BC9F
C0/B69B: A5 3D        LDA $3D
C0/B69D: C9 E0        CMP #$E0
C0/B69F: D0 08        BNE $B6A9
C0/B6A1: A9 88        LDA #$88
C0/B6A3: 85 43        STA $43
C0/B6A5: A9 F0        LDA #$F0
C0/B6A7: 85 45        STA $45
C0/B6A9: E6 3D        INC $3D
C0/B6AB: D0 CF        BNE $B67C
C0/B6AD: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF03:  ]

C0/B6B0: A2 00        LDX #$00
C0/B6B2: 78           SEI 
C0/B6B3: 86 2E        STX $2E
C0/B6B5: A2 00        LDX #$00
C0/B6B7: 10 86        BPL $B63F
C0/B6B9: 2C 20 06     BIT $0620
C0/B6BC: 4D A9 0F     EOR $0FA9
C0/B6BF: 85 6F        STA $6F
C0/B6C1: 20 50 B7     JSR $B750
C0/B6C4: 64 DA        STZ $DA
C0/B6C6: 20 91 B7     JSR $B791
C0/B6C9: 20 F4 5B     JSR $5BF4
C0/B6CC: 20 68 4A     JSR $4A68
C0/B6CF: 64 3D        STZ $3D
C0/B6D1: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B6D4: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B6D7: 20 91 B7     JSR $B791
C0/B6DA: 20 2B 61     JSR $612B
C0/B6DD: A5 3D        LDA $3D
C0/B6DF: C9 C0        CMP #$C0
C0/B6E1: B0 0D        BCS $B6F0
C0/B6E3: A9 87        LDA #$87
C0/B6E5: 85 DF        STA $DF
C0/B6E7: A9 1E        LDA #$1E
C0/B6E9: 85 E0        STA $E0
C0/B6EB: 85 E1        STA $E1
C0/B6ED: 20 F5 B9     JSR $B9F5
C0/B6F0: 20 0A 42     JSR $420A
C0/B6F3: E6 3D        INC $3D
C0/B6F5: D0 DA        BNE $B6D1
C0/B6F7: 64 D3        STZ $D3
C0/B6F9: 64 3D        STZ $3D
C0/B6FB: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B6FE: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B701: 20 91 B7     JSR $B791
C0/B704: 20 2B 61     JSR $612B
C0/B707: A2 00        LDX #$00
C0/B709: 78           SEI 
C0/B70A: 8E AD 16     STX $16AD
C0/B70D: A9 DB        LDA #$DB
C0/B70F: 85 25        STA $25
C0/B711: A2 80        LDX #$80
C0/B713: 55 86        EOR $86,X
C0/B715: 23 A2        AND $A2,S
C0/B717: 00 07        BRK $07
C0/B719: 86 26        STX $26
C0/B71B: A5 3D        LDA $3D
C0/B71D: 4A           LSR 
C0/B71E: 4A           LSR 
C0/B71F: 20 07 41     JSR $4107
C0/B722: E6 A3        INC $A3
C0/B724: E6 3D        INC $3D
C0/B726: A5 3D        LDA $3D
C0/B728: 10 D1        BPL $B6FB
C0/B72A: 64 3D        STZ $3D
C0/B72C: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B72F: A5 3D        LDA $3D
C0/B731: 4A           LSR 
C0/B732: 4A           LSR 
C0/B733: 85 DA        STA $DA
C0/B735: A5 3D        LDA $3D
C0/B737: C9 F0        CMP #$F0
C0/B739: D0 03        BNE $B73E
C0/B73B: 20 71 4A     JSR $4A71
C0/B73E: 20 95 4C     JSR $4C95       ; clear sprite data
C0/B741: 20 91 B7     JSR $B791
C0/B744: 20 2B 61     JSR $612B
C0/B747: E6 3D        INC $3D
C0/B749: A5 3D        LDA $3D
C0/B74B: D0 DF        BNE $B72C
C0/B74D: 4C 30 A6     JMP $A630       ; 2-byte command
C0/B750: A4 06        LDY $06
C0/B752: A9 00        LDA #$00
C0/B754: 99 A0 0D     STA $0DA0,Y
C0/B757: C8           INY 
C0/B758: C0 20 00     CPY #$0020
C0/B75B: D0 F7        BNE $B754
C0/B75D: 60           RTS 
C0/B75E: A5 3D        LDA $3D
C0/B760: C2 20        REP #$20
C0/B762: 0A           ASL 
C0/B763: 18           CLC 
C0/B764: 69 00 02     ADC #$0200
C0/B767: 85 0D        STA $0D
C0/B769: A5 06        LDA $06
C0/B76B: E2 20        SEP #$20
C0/B76D: A5 0D        LDA $0D
C0/B76F: 8D 1B 21     STA $211B
C0/B772: A5 0E        LDA $0E
C0/B774: 8D 1B 21     STA $211B
C0/B777: A5 0D        LDA $0D
C0/B779: 8D 1E 21     STA $211E
C0/B77C: A5 0E        LDA $0E
C0/B77E: 8D 1E 21     STA $211E
C0/B781: A5 3D        LDA $3D
C0/B783: 10 0B        BPL $B790
C0/B785: 29 7F        AND #$7F
C0/B787: 4A           LSR 
C0/B788: 4A           LSR 
C0/B789: 4A           LSR 
C0/B78A: 4A           LSR 
C0/B78B: 09 E0        ORA #$E0
C0/B78D: 8D 32 21     STA $2132
C0/B790: 60           RTS 
C0/B791: A6 06        LDX $06
C0/B793: BF 04 B8 C0  LDA $C0B804,X
C0/B797: 9D 00 03     STA $0300,X
C0/B79A: BF 05 B8 C0  LDA $C0B805,X
C0/B79E: 38           SEC 
C0/B79F: E5 DA        SBC $DA
C0/B7A1: 9D 01 03     STA $0301,X
C0/B7A4: BF 06 B8 C0  LDA $C0B806,X
C0/B7A8: 9D 02 03     STA $0302,X
C0/B7AB: BF 07 B8 C0  LDA $C0B807,X
C0/B7AF: 09 36        ORA #$36
C0/B7B1: 9D 03 03     STA $0303,X
C0/B7B4: E8           INX 
C0/B7B5: E8           INX 
C0/B7B6: E8           INX 
C0/B7B7: E8           INX 
C0/B7B8: E0 30        CPX #$30
C0/B7BA: 00 D0        BRK $D0
C0/B7BC: D6 A6        DEC $A6,X
C0/B7BE: 06 BF        ASL $BF
C0/B7C0: 04 B8        TSB $B8
C0/B7C2: C0 9D 30     CPY #$309D
C0/B7C5: 03 BF        ORA $BF,S
C0/B7C7: 05 B8        ORA $B8
C0/B7C9: C0 18 69     CPY #$6918
C0/B7CC: 04 9D        TSB $9D
C0/B7CE: 31 03        AND ($03),Y
C0/B7D0: BF 06 B8 C0  LDA $C0B806,X
C0/B7D4: 9D 32 03     STA $0332,X
C0/B7D7: BF 07 B8 C0  LDA $C0B807,X
C0/B7DB: 09 0A        ORA #$0A
C0/B7DD: 9D 33 03     STA $0333,X
C0/B7E0: E8           INX 
C0/B7E1: E8           INX 
C0/B7E2: E8           INX 
C0/B7E3: E8           INX 
C0/B7E4: E0 30        CPX #$30
C0/B7E6: 00 D0        BRK $D0
C0/B7E8: D6 A9        DEC $A9,X
C0/B7EA: AA           TAX 
C0/B7EB: 8D 10 04     STA $0410
C0/B7EE: 8D 11 04     STA $0411
C0/B7F1: 8D 12 04     STA $0412
C0/B7F4: 8D 13 04     STA $0413
C0/B7F7: 8D 14 04     STA $0414
C0/B7FA: 8D 15 04     STA $0415
C0/B7FD: 8D 16 04     STA $0416
C0/B800: 8D 17 04     STA $0417
C0/B803: 60           RTS 
C0/B804: 68           PLA 
C0/B805: 58           CLI 
C0/B806: 80 01        BRA $B809
C0/B808: 78           SEI 
C0/B809: 58           CLI 
C0/B80A: 82 01 88     BRL $400E
C0/B80D: 58           CLI 
C0/B80E: 84 01        STY $01
C0/B810: 60           RTS 
C0/B811: 68           PLA 
C0/B812: 86 01        STX $01
C0/B814: 70 68        BVS $B87E
C0/B816: 88           DEY 
C0/B817: 01 80        ORA ($80,X)
C0/B819: 68           PLA 
C0/B81A: 8A           TXA 
C0/B81B: 01 90        ORA ($90,X)
C0/B81D: 68           PLA 
C0/B81E: 8C 01 60     STY $6001
C0/B821: 78           SEI 
C0/B822: 8E 01 70     STX $7001
C0/B825: 78           SEI 
C0/B826: A0 01 80     LDY #$8001
C0/B829: 78           SEI 
C0/B82A: A2 01        LDX #$01
C0/B82C: 90 78        BCC $B8A6
C0/B82E: A4 01        LDY $01
C0/B830: 78           SEI 
C0/B831: 88           DEY 
C0/B832: A6 01        LDX $01

; [ event command $BF0C:  ]

C0/B834: 20 54 B8     JSR $B854
C0/B837: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF0E:  ]

C0/B83A: A9 82        LDA #$82
C0/B83C: 85 43        STA $43
C0/B83E: A9 F0        LDA #$F0
C0/B840: 85 45        STA $45
C0/B842: 20 54 B8     JSR $B854
C0/B845: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BF0D:  ]

C0/B848: A9 02        LDA #$02
C0/B84A: 85 43        STA $43
C0/B84C: 64 45        STZ $45
C0/B84E: 20 54 B8     JSR $B854
C0/B851: 4C 30 A6     JMP $A630       ; 2-byte command
C0/B854: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B857: A9 80        LDA #$80
C0/B859: 85 DA        STA $DA
C0/B85B: A9 01        LDA #$01
C0/B85D: 85 52        STA $52
C0/B85F: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B862: A5 5E        LDA $5E
C0/B864: 09 80        ORA #$80
C0/B866: 8D 0C 42     STA $420C
C0/B869: A5 45        LDA $45
C0/B86B: 49 FF        EOR #$FF
C0/B86D: 1A           INC 
C0/B86E: 8D 02 42     STA $4202
C0/B871: A6 06        LDX $06
C0/B873: 20 2B 4F     JSR $4F2B       ; generate random number
C0/B876: 29 F0        AND #$F0
C0/B878: 8D 03 42     STA $4203
C0/B87B: EA           NOP 
C0/B87C: EA           NOP 
C0/B87D: EA           NOP 
C0/B87E: EA           NOP 
C0/B87F: AD 17 42     LDA $4217
C0/B882: 09 0F        ORA #$0F
C0/B884: 9F 49 6A 7F  STA $7F6A49,X
C0/B888: E8           INX 
C0/B889: E0 10        CPX #$10
C0/B88B: 00 D0        BRK $D0
C0/B88D: E5 C6        SBC $C6
C0/B88F: DA           PHX 
C0/B890: D0 CD        BNE $B85F
C0/B892: 20 41 4E     JSR $4E41       ; wait for vblank
C0/B895: 9C 0C 42     STZ $420C
C0/B898: 64 52        STZ $52
C0/B89A: A9 00        LDA #$00
C0/B89C: 8D 06 21     STA $2106
C0/B89F: 60           RTS 

; [ event command $EA: show map title ]

C0/B8A0: A9 01        LDA #$01        ; enable map title
C0/B8A2: 8D A0 16     STA $16A0
C0/B8A5: 20 E8 4C     JSR $4CE8       ; disable interrupts
C0/B8A8: 20 8C 92     JSR $928C       ; init map title
C0/B8AB: 20 FA 4C     JSR $4CFA       ; enable interrupts
C0/B8AE: 20 68 4A     JSR $4A68
C0/B8B1: 20 67 92     JSR $9267       ; show map title
C0/B8B4: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $EB: transfer galuf's stats to krile ]

C0/B8B7: A9 06        LDA #$06        ; menu command $06 (transfer galuf's stats to krile)
C0/B8B9: 8D 34 01     STA $0134
C0/B8BC: 20 4F 45     JSR $454F       ; open menu
C0/B8BF: 20 32 55     JSR $5532       ; load world map
C0/B8C2: 20 00 61     JSR $6100       ; fade in
C0/B8C5: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $E9: load character stats (ending) ]

C0/B8C8: A4 06        LDY $06
C0/B8CA: A6 06        LDX $06
C0/B8CC: B9 00 05     LDA $0500,Y
C0/B8CF: 29 BF        AND #$BF
C0/B8D1: 99 00 05     STA $0500,Y
C0/B8D4: 29 07        AND #$07
C0/B8D6: C5 DF        CMP $DF
C0/B8D8: F0 0A        BEQ $B8E4
C0/B8DA: B9 00 05     LDA $0500,Y
C0/B8DD: 09 40        ORA #$40
C0/B8DF: 99 00 05     STA $0500,Y
C0/B8E2: 80 04        BRA $B8E8
C0/B8E4: 84 23        STY $23
C0/B8E6: 86 26        STX $26
C0/B8E8: E8           INX 
C0/B8E9: 20 9D C1     JSR $C19D
C0/B8EC: C0 40 01     CPY #$0140
C0/B8EF: D0 DB        BNE $B8CC
C0/B8F1: A5 26        LDA $26
C0/B8F3: AA           TAX 
C0/B8F4: BF 8D B9 C0  LDA $C0B98D,X   ; pointers to character abilities (+$08F7)
C0/B8F8: A8           TAY 
C0/B8F9: A6 06        LDX $06
C0/B8FB: B9 F7 08     LDA $08F7,Y
C0/B8FE: 9F 22 76 7F  STA $7F7622,X
C0/B902: C8           INY 
C0/B903: C0 50 00     CPY #$0050
C0/B906: D0 02        BNE $B90A
C0/B908: A4 06        LDY $06
C0/B90A: E8           INX 
C0/B90B: E0 50 00     CPX #$0050
C0/B90E: D0 EB        BNE $B8FB
C0/B910: A0 14 00     LDY #$0014
C0/B913: A6 06        LDX $06
C0/B915: BF 22 76 7F  LDA $7F7622,X
C0/B919: 99 F7 08     STA $08F7,Y     ; character abilities
C0/B91C: C8           INY 
C0/B91D: C0 50 00     CPY #$0050
C0/B920: D0 02        BNE $B924
C0/B922: A4 06        LDY $06
C0/B924: E8           INX 
C0/B925: E0 50 00     CPX #$0050
C0/B928: D0 EB        BNE $B915
C0/B92A: A4 26        LDY $26
C0/B92C: A6 06        LDX $06
C0/B92E: B9 F3 08     LDA $08F3,Y
C0/B931: 9F 22 76 7F  STA $7F7622,X
C0/B935: C8           INY 
C0/B936: 98           TYA 
C0/B937: 29 03        AND #$03
C0/B939: A8           TAY 
C0/B93A: E8           INX 
C0/B93B: E0 04 00     CPX #$0004
C0/B93E: D0 EE        BNE $B92E
C0/B940: A0 01 00     LDY #$0001
C0/B943: A6 06        LDX $06
C0/B945: BF 22 76 7F  LDA $7F7622,X
C0/B949: 99 F3 08     STA $08F3,Y
C0/B94C: C8           INY 
C0/B94D: 98           TYA 
C0/B94E: 29 03        AND #$03
C0/B950: A8           TAY 
C0/B951: E8           INX 
C0/B952: E0 04 00     CPX #$0004
C0/B955: D0 EE        BNE $B945
C0/B957: A4 23        LDY $23
C0/B959: A6 06        LDX $06
C0/B95B: B9 00 05     LDA $0500,Y
C0/B95E: 9F 22 76 7F  STA $7F7622,X
C0/B962: C8           INY 
C0/B963: C0 40 01     CPY #$0140
C0/B966: D0 02        BNE $B96A
C0/B968: A4 06        LDY $06
C0/B96A: E8           INX 
C0/B96B: E0 40 01     CPX #$40
C0/B96E: D0 EB        BNE $B95B
C0/B970: A0 50 00     LDY #$0050
C0/B973: A6 06        LDX $06
C0/B975: BF 22 76 7F  LDA $7F7622,X
C0/B979: 99 00 05     STA $0500,Y
C0/B97C: C8           INY 
C0/B97D: C0 40 01     CPY #$0140
C0/B980: D0 02        BNE $B984
C0/B982: A4 06        LDY $06
C0/B984: E8           INX 
C0/B985: E0 40 01     CPX #$0140
C0/B988: D0 EB        BNE $B975
C0/B98A: 4C 30 A6     JMP $A630       ; 2-byte command

C0/B98D: 00 14 28 3C

; [ event command $E7:  ]

C0/B991: A4 06        LDY $06
C0/B993: 64 0D        STZ $0D
C0/B995: B9 1A 05     LDA $051A,Y     ; character status
C0/B998: 29 02        AND #$02
C0/B99A: D0 1A        BNE $B9B6
C0/B99C: B9 1A 05     LDA $051A,Y
C0/B99F: 29 40        AND #$40
C0/B9A1: D0 13        BNE $B9B6
C0/B9A3: B9 1A 05     LDA $051A,Y
C0/B9A6: 30 0E        BMI $B9B6
C0/B9A8: B9 00 05     LDA $0500,Y
C0/B9AB: 29 07        AND #$07
C0/B9AD: AA           TAX 
C0/B9AE: A5 0D        LDA $0D
C0/B9B0: 1F CA B9 C0  ORA $C0B9CA,X
C0/B9B4: 85 0D        STA $0D
C0/B9B6: 20 9D C1     JSR $C19D
C0/B9B9: C0 40 01     CPY #$0140
C0/B9BC: D0 D7        BNE $B995
C0/B9BE: A5 0D        LDA $0D
C0/B9C0: 3A           DEC 
C0/B9C1: 0A           ASL 
C0/B9C2: 0A           ASL 
C0/B9C3: 1A           INC 
C0/B9C4: 20 60 A6     JSR $A660       ; add to event pointer
C0/B9C7: 4C CB A2     JMP $A2CB       ; next command

C0/B9CA:              .DB $01, $02, $04, $08, $04

; [ event command $E6: convert color palettes to grayscale ]

C0/B9CF: 20 08 40     JSR $4008       ; convert color palettes to grayscale
C0/B9D2: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $E4: wait for spc-2 ]

C0/B9D5: AD 42 21     LDA $2142       ; wait for spc-2
C0/B9D8: D0 FB        BNE $B9D5
C0/B9DA: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $E5: wait for spc-3 ]

C0/B9DD: AD 43 21     LDA $2143       ; wait for spc-3
C0/B9E0: D0 FB        BNE $B9DD
C0/B9E2: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $DD: set character data ]

; +b1: pointer to character data
;  b2: data value

C0/B9E5: A4 DF        LDY $DF
C0/B9E7: A5 E1        LDA $E1
C0/B9E9: 99 00 05     STA $0500,Y     ; character data
C0/B9EC: 4C 40 A6     JMP $A640       ; 4-byte command

; [ event command $DA:  ]

C0/B9EF: 20 F5 B9     JSR $B9F5       ; 
C0/B9F2: 4C 40 A6     JMP $A640       ; 4-byte command

; [  ]

C0/B9F5: A4 06        LDY $06
C0/B9F7: B9 58 1A     LDA $1A58,Y
C0/B9FA: F0 14        BEQ $BA10
C0/B9FC: C2 20        REP #$20
C0/B9FE: 98           TYA 
C0/B9FF: 18           CLC 
C0/BA00: 69 08 00     ADC #$0008
C0/BA03: A8           TAY 
C0/BA04: A5 06        LDA $06
C0/BA06: E2 20        SEP #$20
C0/BA08: C0 80 00     CPY #$0080
C0/BA0B: D0 EA        BNE $B9F7
C0/BA0D: 4C 85 BA     JMP $BA85
C0/BA10: C2 20        REP #$20
C0/BA12: A5 DF        LDA $DF
C0/BA14: 29 38 00     AND #$0038
C0/BA17: 0A           ASL 
C0/BA18: 0A           ASL 
C0/BA19: 0A           ASL 
C0/BA1A: 8D 56 1A     STA $1A56
C0/BA1D: A5 06        LDA $06
C0/BA1F: E2 20        SEP #$20
C0/BA21: A5 DF        LDA $DF
C0/BA23: 29 C0        AND #$C0
C0/BA25: 4A           LSR 
C0/BA26: 4A           LSR 
C0/BA27: 4A           LSR 
C0/BA28: 4A           LSR 
C0/BA29: AA           TAX 
C0/BA2A: 20 2B 4F     JSR $4F2B       ; generate random number
C0/BA2D: 3F 88 BA C0  AND $C0BA88,X
C0/BA31: 18           CLC 
C0/BA32: 69 10        ADC #$10
C0/BA34: 99 58 1A     STA $1A58,Y
C0/BA37: A5 DF        LDA $DF
C0/BA39: 29 07        AND #$07
C0/BA3B: 0A           ASL 
C0/BA3C: AA           TAX 
C0/BA3D: 20 2B 4F     JSR $4F2B       ; generate random number
C0/BA40: 3F 88 BA C0  AND $C0BA88,X
C0/BA44: C2 20        REP #$20
C0/BA46: 38           SEC 
C0/BA47: FF 86 BA C0  SBC $C0BA86,X
C0/BA4B: 99 5A 1A     STA $1A5A,Y
C0/BA4E: A5 06        LDA $06
C0/BA50: E2 20        SEP #$20
C0/BA52: 20 2B 4F     JSR $4F2B       ; generate random number
C0/BA55: 3F 88 BA C0  AND $C0BA88,X
C0/BA59: C2 20        REP #$20
C0/BA5B: 38           SEC 
C0/BA5C: FF 86 BA C0  SBC $C0BA86,X
C0/BA60: 99 5C 1A     STA $1A5C,Y
C0/BA63: A5 E0        LDA $E0
C0/BA65: 29 FF 00     AND #$00FF
C0/BA68: 0A           ASL 
C0/BA69: 0A           ASL 
C0/BA6A: 0A           ASL 
C0/BA6B: 18           CLC 
C0/BA6C: 79 5A 1A     ADC $1A5A,Y
C0/BA6F: 99 5A 1A     STA $1A5A,Y
C0/BA72: A5 E1        LDA $E1
C0/BA74: 29 FF 00     AND #$00FF
C0/BA77: 0A           ASL 
C0/BA78: 0A           ASL 
C0/BA79: 0A           ASL 
C0/BA7A: 18           CLC 
C0/BA7B: 79 5C 1A     ADC $1A5C,Y
C0/BA7E: 99 5C 1A     STA $1A5C,Y
C0/BA81: A5 06        LDA $06
C0/BA83: E2 20        SEP #$20
C0/BA85: 60           RTS 

C0/BA86: 00 00        BRK $00
C0/BA88: 00 00        BRK $00
C0/BA8A: 01 00        ORA ($00,X)
C0/BA8C: 03 00        ORA $00,S
C0/BA8E: 07 00        ORA [$00]
C0/BA90: 0F 00 1F 00  ORA $001F00
C0/BA94: 3F 00 7F 00  AND $007F00,X

; [ event command $79: show mini-map ]

C0/BA98: 20 35 66     JSR $6635       ; show mini-map
C0/BA9B: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $DB: update party graphic ]

C0/BA9E: 20 E2 1C     JSR $1CE2       ; update party graphic
C0/BAA1: A9 01        LDA #$01
C0/BAA3: 85 A1        STA $A1
C0/BAA5: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $D9: change color palette ]

C0/BAA8: 20 AE BA     JSR $BAAE       ; change color palette
C0/BAAB: 4C 38 A6     JMP $A638       ; 3-byte command

; [ change color palette ]

C0/BAAE: A5 DF        LDA $DF
C0/BAB0: C2 20        REP #$20
C0/BAB2: 0A           ASL 
C0/BAB3: 0A           ASL 
C0/BAB4: 0A           ASL 
C0/BAB5: 0A           ASL 
C0/BAB6: 0A           ASL 
C0/BAB7: A8           TAY 
C0/BAB8: A5 E0        LDA $E0
C0/BABA: 29 FF 00     AND #$00FF
C0/BABD: 0A           ASL 
C0/BABE: 0A           ASL 
C0/BABF: 0A           ASL 
C0/BAC0: 0A           ASL 
C0/BAC1: 0A           ASL 
C0/BAC2: AA           TAX 
C0/BAC3: A5 06        LDA $06
C0/BAC5: E2 20        SEP #$20
C0/BAC7: A9 20        LDA #$20
C0/BAC9: 85 09        STA $09
C0/BACB: BF 00 FE DF  LDA $DFFE00,X   ; color palette
C0/BACF: 99 00 0C     STA $0C00,Y
C0/BAD2: E8           INX 
C0/BAD3: C8           INY 
C0/BAD4: C6 09        DEC $09
C0/BAD6: D0 F3        BNE $BACB
C0/BAD8: 60           RTS 

; [ event command $B6: show cutscene ]

; b1: cutscene id

C0/BAD9: A5 DF        LDA $DF
C0/BADB: 20 C8 44     JSR $44C8       ; show cutscene
C0/BADE: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $AE: pixelate the screen ]

; b1: speed

C0/BAE1: A5 DF        LDA $DF
C0/BAE3: 8D AA 16     STA $16AA
C0/BAE6: A2 00 1E     LDX #$1E00
C0/BAE9: 8E AB 16     STX $16AB
C0/BAEC: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $A6: set battle flag ]

C0/BAEF: A5 DF        LDA $DF
C0/BAF1: 20 FA C9     JSR $C9FA       ; set battle flag
C0/BAF4: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $A7: clear battle flag ]

C0/BAF7: A5 DF        LDA $DF
C0/BAF9: 20 08 CA     JSR $CA08       ; clear battle flag
C0/BAFC: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $7B:  ]

C0/BAFF: AD DC 0A     LDA $0ADC
C0/BB02: 3A           DEC 
C0/BB03: 0A           ASL 
C0/BB04: 0A           ASL 
C0/BB05: A8           TAY 
C0/BB06: 8C 9C 16     STY $169C
C0/BB09: AD DC 0A     LDA $0ADC
C0/BB0C: C9 02        CMP #$02
C0/BB0E: D0 05        BNE $BB15
C0/BB10: 20 C1 08     JSR $08C1
C0/BB13: 80 0C        BRA $BB21
C0/BB15: C9 03        CMP #$03
C0/BB17: D0 05        BNE $BB1E
C0/BB19: 20 EF 08     JSR $08EF
C0/BB1C: 80 03        BRA $BB21
C0/BB1E: 20 57 0A     JSR $0A57
C0/BB21: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $7F:  ]

C0/BB24: 20 33 17     JSR $1733       ; update local tile properties (world map)
C0/BB27: AD DC 0A     LDA $0ADC
C0/BB2A: 3A           DEC 
C0/BB2B: 0A           ASL 
C0/BB2C: 0A           ASL 
C0/BB2D: A8           TAY 
C0/BB2E: 8C 9C 16     STY $169C
C0/BB31: AD DC 0A     LDA $0ADC
C0/BB34: C9 02        CMP #$02
C0/BB36: D0 05        BNE $BB3D
C0/BB38: 20 1D 09     JSR $091D
C0/BB3B: 80 0C        BRA $BB49
C0/BB3D: C9 03        CMP #$03
C0/BB3F: D0 05        BNE $BB46
C0/BB41: 20 55 09     JSR $0955
C0/BB44: 80 03        BRA $BB49
C0/BB46: 20 A3 0A     JSR $0AA3
C0/BB49: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $AD: inn ]

; b1: price

C0/BB4C: 20 51 BC     JSR $BC51       ; get inn price
C0/BB4F: 20 D7 4D     JSR $4DD7       ; 
C0/BB52: A2 0D 00     LDX #$000D      ; dialog message $000D "Welcome!  It is \gp GP per night ..."
C0/BB55: 86 AF        STX $AF
C0/BB57: 20 01 84     JSR $8401       ; get pointer to dialog
C0/BB5A: 20 54 8F     JSR $8F54       ; 
C0/BB5D: A6 B1        LDX $B1
C0/BB5F: BF 00 00 CA  LDA $CA0000,X   ; dialog
C0/BB63: F0 25        BEQ $BB8A
C0/BB65: 20 27 84     JSR $8427
C0/BB68: A4 06        LDY $06
C0/BB6A: 84 AB        STY $AB
C0/BB6C: 20 3B 8D     JSR $8D3B
C0/BB6F: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BB72: A4 AB        LDY $AB
C0/BB74: C0 40 00     CPY #$0040
C0/BB77: D0 F3        BNE $BB6C
C0/BB79: A5 B3        LDA $B3
C0/BB7B: D0 0D        BNE $BB8A
C0/BB7D: 20 AD 4A     JSR $4AAD
C0/BB80: 20 C1 4A     JSR $4AC1       ; wait for keypress
C0/BB83: E6 A5        INC $A5
C0/BB85: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BB88: 80 D0        BRA $BB5A
C0/BB8A: AD 47 09     LDA $0947
C0/BB8D: 85 37        STA $37
C0/BB8F: AD 48 09     LDA $0948
C0/BB92: 85 38        STA $38
C0/BB94: AD 49 09     LDA $0949
C0/BB97: 85 39        STA $39
C0/BB99: 20 D7 4D     JSR $4DD7
C0/BB9C: 20 33 91     JSR $9133       ; show gp window
C0/BB9F: 20 ED 8F     JSR $8FED       ; show yes/no window
C0/BBA2: A9 80        LDA #$80
C0/BBA4: 8D 97 16     STA $1697
C0/BBA7: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BBAA: A5 03        LDA $03
C0/BBAC: 29 0C        AND #$0C
C0/BBAE: F0 0D        BEQ $BBBD
C0/BBB0: C9 08        CMP #$08
C0/BBB2: D0 04        BNE $BBB8
C0/BBB4: A9 80        LDA #$80
C0/BBB6: 80 02        BRA $BBBA
C0/BBB8: A9 81        LDA #$81
C0/BBBA: 8D 97 16     STA $1697
C0/BBBD: A5 03        LDA $03
C0/BBBF: 10 07        BPL $BBC8
C0/BBC1: A9 01        LDA #$01
C0/BBC3: 8D 97 16     STA $1697
C0/BBC6: 80 0E        BRA $BBD6
C0/BBC8: A5 02        LDA $02
C0/BBCA: 29 80        AND #$80
C0/BBCC: F0 D9        BEQ $BBA7
C0/BBCE: AD B8 10     LDA $10B8
C0/BBD1: D0 D4        BNE $BBA7
C0/BBD3: EE B8 10     INC $10B8
C0/BBD6: AD 97 16     LDA $1697
C0/BBD9: 29 01        AND #$01
C0/BBDB: 8D 97 16     STA $1697
C0/BBDE: 20 AD 90     JSR $90AD
C0/BBE1: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BBE4: 20 ED 91     JSR $91ED
C0/BBE7: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BBEA: 20 A8 94     JSR $94A8
C0/BBED: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BBF0: E6 A5        INC $A5
C0/BBF2: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BBF5: AD 97 16     LDA $1697
C0/BBF8: D0 44        BNE $BC3E
C0/BBFA: 20 51 BC     JSR $BC51
C0/BBFD: AD 47 09     LDA $0947
C0/BC00: 38           SEC 
C0/BC01: E5 37        SBC $37
C0/BC03: 85 08        STA $08
C0/BC05: AD 48 09     LDA $0948
C0/BC08: E5 38        SBC $38
C0/BC0A: 85 09        STA $09
C0/BC0C: AD 49 09     LDA $0949
C0/BC0F: E5 38        SBC $38
C0/BC11: 85 0A        STA $0A
C0/BC13: B0 0A        BCS $BC1F
C0/BC15: A2 0F 00     LDX #$000F      ; dialog message $000F "Please come again!"
C0/BC18: 86 AF        STX $AF
C0/BC1A: 20 AE 83     JSR $83AE       ; show dialog
C0/BC1D: 80 1F        BRA $BC3E
C0/BC1F: A5 08        LDA $08
C0/BC21: 8D 47 09     STA $0947
C0/BC24: A5 09        LDA $09
C0/BC26: 8D 48 09     STA $0948
C0/BC29: A5 0A        LDA $0A
C0/BC2B: 8D 49 09     STA $0949
C0/BC2E: A2 0E 00     LDX #$000E      ; dialog message $000E "Please rest well..."
C0/BC31: 86 AF        STX $AF
C0/BC33: 20 AE 83     JSR $83AE       ; show dialog
C0/BC36: A9 02        LDA #$02
C0/BC38: 20 60 A6     JSR $A660       ; add to event pointer
C0/BC3B: 4C CB A2     JMP $A2CB       ; next command
C0/BC3E: 4C 1C A3     JMP $A31C       ; end of event

; inn prices
C0/BC41:              .DW $000A, $0014, $001E, $0028, $0032, $003C, $0046, $0050

; [ get inn price ]

C0/BC51: A5 DF        LDA $DF
C0/BC53: 0A           ASL 
C0/BC54: AA           TAX 
C0/BC55: BF 41 BC C0  LDA $C0BC41,X
C0/BC59: 85 37        STA $37
C0/BC5B: BF 42 BC C0  LDA $C0BC42,X
C0/BC5F: 85 38        STA $38
C0/BC61: 64 39        STZ $39
C0/BC63: 60           RTS 

; [ event command $AC:  ]

C0/BC64: A5 DF        LDA $DF
C0/BC66: 20 A5 C9     JSR $C9A5       ; give magic
C0/BC69: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $C0:  ]

C0/BC6C: A5 DF        LDA $DF
C0/BC6E: 29 7F        AND #$7F
C0/BC70: 8D 9A 16     STA $169A
C0/BC73: D0 15        BNE $BC8A
C0/BC75: A9 BF        LDA #$BF
C0/BC77: 8D 23 21     STA $2123
C0/BC7A: A9 0B        LDA #$0B
C0/BC7C: 8D 24 21     STA $2124
C0/BC7F: A9 01        LDA #$01
C0/BC81: 8D 2A 21     STA $212A
C0/BC84: 20 7B 8C     JSR $8C7B
C0/BC87: 4C 30 A6     JMP $A630       ; 2-byte command
C0/BC8A: A5 DF        LDA $DF
C0/BC8C: 10 0B        BPL $BC99
C0/BC8E: A9 FF        LDA #$FF
C0/BC90: 8D 23 21     STA $2123
C0/BC93: 8D 24 21     STA $2124
C0/BC96: 8D 2A 21     STA $212A
C0/BC99: 20 30 5D     JSR $5D30
C0/BC9C: 4C 30 A6     JMP $A630       ; 2-byte command

; [  ]

C0/BC9F: A5 3F        LDA $3F
C0/BCA1: AA           TAX 
C0/BCA2: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C0/BCA6: C9 10        CMP #$10
C0/BCA8: B0 09        BCS $BCB3
C0/BCAA: A9 1A        LDA #$1A        ; system sound effect $1A
C0/BCAC: 8D 00 1D     STA $1D00
C0/BCAF: 22 04 00 C4  JSL $C40004
C0/BCB3: 60           RTS 

; [ event command $D0: spc command ]

C0/BCB4: A5 DF        LDA $DF
C0/BCB6: 8D 00 1D     STA $1D00
C0/BCB9: A5 E0        LDA $E0
C0/BCBB: 8D 01 1D     STA $1D01
C0/BCBE: A9 01        LDA #$01
C0/BCC0: 85 5C        STA $5C
C0/BCC2: 22 04 00 C4  JSL $C40004
C0/BCC6: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BCC9: 64 5C        STZ $5C
C0/BCCB: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $70-$75: wait ]

C0/BCCE: A5 DE        LDA $DE
C0/BCD0: 38           SEC 
C0/BCD1: E9 70        SBC #$70
C0/BCD3: AA           TAX 
C0/BCD4: BF EF BC C0  LDA $C0BCEF,X   ; wait duration
C0/BCD8: AA           TAX 
C0/BCD9: DA           PHX 
C0/BCDA: A0 0F 00     LDY #$000F
C0/BCDD: 5A           PHY 
C0/BCDE: 20 DE C6     JSR $C6DE
C0/BCE1: 20 41 4E     JSR $4E41       ; wait for vblank
C0/BCE4: 7A           PLY 
C0/BCE5: 88           DEY 
C0/BCE6: D0 F5        BNE $BCDD
C0/BCE8: FA           PLX 
C0/BCE9: CA           DEX 
C0/BCEA: D0 ED        BNE $BCD9
C0/BCEC: 4C 28 A6     JMP $A628       ; 1-byte command

; wait durations
C0/BCEF:              .DB $01, $02, $03, $04, $06, $08

; [ event command $DC: tutorial menu ]

; 0-4: job, 5: row, 6: order

C0/BCF5: A9 04        LDA #$04        ; menu command $04 (tutorial)
C0/BCF7: 8D 34 01     STA $0134
C0/BCFA: A5 DF        LDA $DF
C0/BCFC: 8D 35 01     STA $0135       ; tutorial index
C0/BCFF: 20 4C 45     JSR $454C       ; open menu
C0/BD02: E6 55        INC $55
C0/BD04: 20 7C 57     JSR $577C       ; 
C0/BD07: 20 00 61     JSR $6100       ; fade in
C0/BD0A: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $7A: name change menu ]

C0/BD0D: A9 05        LDA #$05        ; menu command $05 (name change)
C0/BD0F: 8D 34 01     STA $0134
C0/BD12: 20 4C 45     JSR $454C       ; open menu
C0/BD15: 20 7C 57     JSR $577C       ; 
C0/BD18: 20 00 61     JSR $6100       ; fade in
C0/BD1B: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $A1: shop ]

C0/BD1E: A5 DF        LDA $DF
C0/BD20: 8D 35 01     STA $0135
C0/BD23: A9 02        LDA #$02        ; menu command $02 (shop)
C0/BD25: 8D 34 01     STA $0134
C0/BD28: 20 4C 45     JSR $454C       ; open menu
C0/BD2B: E6 55        INC $55
C0/BD2D: 20 7C 57     JSR $577C
C0/BD30: 20 00 61     JSR $6100       ; fade in
C0/BD33: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $E8: character stats battle (ending) ]

C0/BD36: A6 06        LDX $06
C0/BD38: 8E A8 16     STX $16A8
C0/BD3B: A5 DF        LDA $DF
C0/BD3D: 29 7F        AND #$7F
C0/BD3F: C2 20        REP #$20
C0/BD41: 0A           ASL 
C0/BD42: 0A           ASL 
C0/BD43: AA           TAX 
C0/BD44: A5 06        LDA $06
C0/BD46: E2 20        SEP #$20
C0/BD48: 20 52 CC     JSR $CC52
C0/BD4B: C9 C0        CMP #$C0
C0/BD4D: 90 02        BCC $BD51
C0/BD4F: E8           INX 
C0/BD50: E8           INX 
C0/BD51: C2 20        REP #$20
C0/BD53: BF 00 78 D0  LDA $D07800,X
C0/BD57: 8D F0 04     STA $04F0       ; battle index
C0/BD5A: A5 06        LDA $06
C0/BD5C: E2 20        SEP #$20
C0/BD5E: A5 E0        LDA $E0
C0/BD60: C9 FF        CMP #$FF
C0/BD62: D0 03        BNE $BD67
C0/BD64: AD 24 11     LDA $1124       ; map default battle background
C0/BD67: 8D F2 04     STA $04F2
C0/BD6A: E6 55        INC $55
C0/BD6C: 9C 0B 42     STZ $420B
C0/BD6F: 9C 0C 42     STZ $420C
C0/BD72: A9 00        LDA #$00
C0/BD74: 8D 00 42     STA $4200
C0/BD77: A9 80        LDA #$80
C0/BD79: 8D 00 21     STA $2100
C0/BD7C: 78           SEI 
C0/BD7D: 22 00 00 C2  JSL $C20000     ; battle
C0/BD81: 20 E3 44     JSR $44E3       ; init map bank
C0/BD84: A9 81        LDA #$81
C0/BD86: 8D 00 42     STA $4200
C0/BD89: 58           CLI 
C0/BD8A: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $BD: event battle ]

; b1: battle index (msb = manual fade in)
; b2: battle background ($FF = use map default)

C0/BD8D: A5 DF        LDA $DF
C0/BD8F: 29 7F        AND #$7F
C0/BD91: 20 E6 BD     JSR $BDE6       ; event battle
C0/BD94: AD C4 09     LDA $09C4       ; battle return code
C0/BD97: 29 01        AND #$01
C0/BD99: F0 08        BEQ $BDA3       ; branch if not defeated
C0/BD9B: A9 F0        LDA #$F0
C0/BD9D: 8D 00 1D     STA $1D00       ; don't reset spc
C0/BDA0: 4C 00 00     JMP $0000       ; reset
C0/BDA3: 20 7C 57     JSR $577C
C0/BDA6: A9 F0        LDA #$F0
C0/BDA8: 85 43        STA $43
C0/BDAA: 64 45        STZ $45
C0/BDAC: A5 DF        LDA $DF
C0/BDAE: 30 03        BMI $BDB3
C0/BDB0: 20 00 61     JSR $6100       ; fade in
C0/BDB3: A9 81        LDA #$81
C0/BDB5: 8D 00 42     STA $4200
C0/BDB8: 58           CLI 
C0/BDB9: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $E2: event battle (can lose) ]

C0/BDBC: A5 DF        LDA $DF
C0/BDBE: 29 7F        AND #$7F
C0/BDC0: 20 E6 BD     JSR $BDE6       ; event battle
C0/BDC3: 20 7C 57     JSR $577C
C0/BDC6: A9 F0        LDA #$F0
C0/BDC8: 85 43        STA $43
C0/BDCA: 64 45        STZ $45
C0/BDCC: A5 DF        LDA $DF
C0/BDCE: 30 03        BMI $BDD3
C0/BDD0: 20 00 61     JSR $6100       ; fade in
C0/BDD3: A9 81        LDA #$81
C0/BDD5: 8D 00 42     STA $4200
C0/BDD8: 58           CLI 
C0/BDD9: AD C4 09     LDA $09C4
C0/BDDC: 29 01        AND #$01
C0/BDDE: F0 03        BEQ $BDE3
C0/BDE0: 4C 38 A6     JMP $A638       ; 3-byte command
C0/BDE3: 4C 58 A6     JMP $A658       ; 7-byte command

; [ event battle ]

; A: battle index

C0/BDE6: A6 06        LDX $06
C0/BDE8: 8E A8 16     STX $16A8
C0/BDEB: C2 20        REP #$20
C0/BDED: 0A           ASL 
C0/BDEE: 0A           ASL 
C0/BDEF: AA           TAX 
C0/BDF0: A5 06        LDA $06
C0/BDF2: E2 20        SEP #$20
C0/BDF4: 20 52 CC     JSR $CC52
C0/BDF7: C9 C0        CMP #$C0
C0/BDF9: 90 02        BCC $BDFD
C0/BDFB: E8           INX 
C0/BDFC: E8           INX 
C0/BDFD: C2 20        REP #$20
C0/BDFF: BF 00 78 D0  LDA $D07800,X   ; event battle group
C0/BE03: 8D F0 04     STA $04F0
C0/BE06: A5 06        LDA $06
C0/BE08: E2 20        SEP #$20
C0/BE0A: A5 E0        LDA $E0
C0/BE0C: C9 FF        CMP #$FF
C0/BE0E: D0 03        BNE $BE13
C0/BE10: AD 24 11     LDA $1124
C0/BE13: 8D F2 04     STA $04F2
C0/BE16: E6 55        INC $55
C0/BE18: A9 6F        LDA #$6F
C0/BE1A: 20 3C 46     JSR $463C       ; play sound effect
C0/BE1D: 20 DD CC     JSR $CCDD       ; battle blur
C0/BE20: 9C 0B 42     STZ $420B
C0/BE23: 9C 0C 42     STZ $420C
C0/BE26: A9 00        LDA #$00
C0/BE28: 8D 00 42     STA $4200
C0/BE2B: A9 80        LDA #$80
C0/BE2D: 8D 00 21     STA $2100
C0/BE30: 78           SEI 
C0/BE31: 22 00 00 C2  JSL $C20000     ; battle
C0/BE35: 20 E3 44     JSR $44E3       ; init map bank
C0/BE38: AD C4 09     LDA $09C4
C0/BE3B: 29 01        AND #$01
C0/BE3D: D0 22        BNE $BE61
C0/BE3F: AD 3B 01     LDA $013B
C0/BE42: 0D 3C 01     ORA $013C
C0/BE45: 0D 3D 01     ORA $013D
C0/BE48: 0D 3E 01     ORA $013E
C0/BE4B: 0D 3F 01     ORA $013F
C0/BE4E: 0D 40 01     ORA $0140
C0/BE51: 0D 41 01     ORA $0141
C0/BE54: 0D 42 01     ORA $0142
C0/BE57: F0 08        BEQ $BE61
C0/BE59: A9 01        LDA #$01        ; menu command $01 (collect items after battle)
C0/BE5B: 8D 34 01     STA $0134
C0/BE5E: 20 4F 45     JSR $454F       ; open menu
C0/BE61: 60           RTS 

; [ event command $B7: add/remove character ]

C0/BE62: A5 DF        LDA $DF
C0/BE64: 30 46        BMI $BEAC

; add character
C0/BE66: 29 07        AND #$07
C0/BE68: 48           PHA 
C0/BE69: C9 04        CMP #$04        ; cara
C0/BE6B: D0 11        BNE $BE7E
C0/BE6D: A9 02        LDA #$02        ; galuf
C0/BE6F: 20 64 C1     JSR $C164       ; get pointer to character data
C0/BE72: B9 00 05     LDA $0500,Y
C0/BE75: 29 80        AND #$80
C0/BE77: 05 DF        ORA $DF
C0/BE79: 99 00 05     STA $0500,Y
C0/BE7C: 80 0B        BRA $BE89
C0/BE7E: 20 64 C1     JSR $C164       ; get pointer to character data
C0/BE81: B9 00 05     LDA $0500,Y
C0/BE84: 29 BF        AND #$BF
C0/BE86: 99 00 05     STA $0500,Y
C0/BE89: 68           PLA 
C0/BE8A: 0A           ASL 
C0/BE8B: 85 08        STA $08
C0/BE8D: 0A           ASL 
C0/BE8E: 18           CLC 
C0/BE8F: 65 08        ADC $08
C0/BE91: A8           TAY 
C0/BE92: 18           CLC 
C0/BE93: 65 08        ADC $08
C0/BE95: AA           TAX 
C0/BE96: F0 11        BEQ $BEA9
C0/BE98: A9 06        LDA #$06
C0/BE9A: 85 09        STA $09
C0/BE9C: BF C1 BE C0  LDA $C0BEC1,X
C0/BEA0: 99 90 09     STA $0990,Y     ; character name
C0/BEA3: E8           INX 
C0/BEA4: C8           INY 
C0/BEA5: C6 09        DEC $09
C0/BEA7: D0 F3        BNE $BE9C
C0/BEA9: 4C 30 A6     JMP $A630       ; 2-byte command

; remove character
C0/BEAC: 29 07        AND #$07
C0/BEAE: 20 64 C1     JSR $C164       ; get pointer to character data
C0/BEB1: C0 40 01     CPY #$0140
C0/BEB4: F0 08        BEQ $BEBE
C0/BEB6: B9 00 05     LDA $0500,Y
C0/BEB9: 09 40        ORA #$40        ; character is not present
C0/BEBB: 99 00 05     STA $0500,Y
C0/BEBE: 4C 30 A6     JMP $A630       ; 2-byte command

; character names (8 bytes each, 6 bytes useable)
C0/BEC1: C7 C7 FF FF FF FF FF FF      ; ……
C0/BEC9: AC 92 FF FF FF FF FF FF      ; レナ
C0/BED1: 2A A6 64 FF FF FF FF FF      ; ガラフ
C0/BED9: 64 C4 A8 78 FF FF FF FF      ; ファリス
C0/BEE1: 6E AA AA FF FF FF FF FF      ; クルル

; [ event command $C6: give job ]

; b1: job index

C0/BEE9: A5 DF        LDA $DF
C0/BEEB: C2 20        REP #$20
C0/BEED: AA           TAX 
C0/BEEE: 4A           LSR 
C0/BEEF: 4A           LSR 
C0/BEF0: 4A           LSR 
C0/BEF1: A8           TAY 
C0/BEF2: A5 06        LDA $06
C0/BEF4: E2 20        SEP #$20
C0/BEF6: 8A           TXA 
C0/BEF7: 29 07        AND #$07
C0/BEF9: AA           TAX 
C0/BEFA: B9 40 08     LDA $0840,Y
C0/BEFD: 1F 59 CA C0  ORA $C0CA59,X
C0/BF01: 99 40 08     STA $0840,Y
C0/BF04: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $AF: give gp ]

C0/BF07: 20 3F BF     JSR $BF3F       ; calculate gp (event)
C0/BF0A: 20 FE 0E     JSR $0EFE       ; give gp
C0/BF0D: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $B0: take gp ]

C0/BF10: 20 3F BF     JSR $BF3F       ; calculate gp (event)
C0/BF13: AD 47 09     LDA $0947       ; current gp
C0/BF16: 38           SEC 
C0/BF17: ED 37 0B     SBC $0B37
C0/BF1A: 8D 47 09     STA $0947
C0/BF1D: AD 48 09     LDA $0948
C0/BF20: ED 38 0B     SBC $0B38
C0/BF23: 8D 48 09     STA $0948
C0/BF26: AD 49 09     LDA $0949
C0/BF29: ED 39 0B     SBC $0B39
C0/BF2C: 8D 49 09     STA $0949
C0/BF2F: C9 9A        CMP #$9A
C0/BF31: 90 09        BCC $BF3C
C0/BF33: 9C 47 09     STZ $0947
C0/BF36: 9C 48 09     STZ $0948
C0/BF39: 9C 49 09     STZ $0949
C0/BF3C: 4C 30 A6     JMP $A630       ; 2-byte command

; [ calculate gp (event) ]

C0/BF3F: A5 DF        LDA $DF
C0/BF41: 30 15        BMI $BF58
C0/BF43: 29 7F        AND #$7F        ; add gp
C0/BF45: C2 20        REP #$20
C0/BF47: 0A           ASL 
C0/BF48: 85 37        STA $37         ; multiply by 10
C0/BF4A: 0A           ASL 
C0/BF4B: 0A           ASL 
C0/BF4C: 18           CLC 
C0/BF4D: 65 37        ADC $37
C0/BF4F: 85 37        STA $37
C0/BF51: A5 06        LDA $06
C0/BF53: E2 20        SEP #$20
C0/BF55: 64 39        STZ $39
C0/BF57: 60           RTS 
C0/BF58: 29 7F        AND #$7F        ; subtract gp
C0/BF5A: C2 20        REP #$20
C0/BF5C: 48           PHA 
C0/BF5D: 0A           ASL 
C0/BF5E: 0A           ASL 
C0/BF5F: 0A           ASL 
C0/BF60: 85 0D        STA $0D
C0/BF62: 0A           ASL 
C0/BF63: 18           CLC 
C0/BF64: 65 0D        ADC $0D
C0/BF66: 85 0D        STA $0D
C0/BF68: 68           PLA 
C0/BF69: EB           XBA 
C0/BF6A: 85 37        STA $37
C0/BF6C: A5 06        LDA $06
C0/BF6E: E2 20        SEP #$20
C0/BF70: 64 39        STZ $39
C0/BF72: 06 37        ASL $37
C0/BF74: 26 38        ROL $38
C0/BF76: 26 39        ROL $39
C0/BF78: 06 37        ASL $37
C0/BF7A: 26 38        ROL $38
C0/BF7C: 26 39        ROL $39
C0/BF7E: A5 37        LDA $37
C0/BF80: 38           SEC 
C0/BF81: E5 0D        SBC $0D
C0/BF83: 85 37        STA $37
C0/BF85: A5 38        LDA $38
C0/BF87: E5 0E        SBC $0E
C0/BF89: 85 38        STA $38
C0/BF8B: A5 39        LDA $39
C0/BF8D: E9 00        SBC #$00
C0/BF8F: 85 39        STA $39
C0/BF91: 60           RTS 

; [ event command $AA: add item to inventory ]

C0/BF92: A5 DF        LDA $DF
C0/BF94: 20 DD BF     JSR $BFDD       ; find item slot
C0/BF97: C0 00 01     CPY #$0100
C0/BF9A: F0 0D        BEQ $BFA9       ; branch if not found
C0/BF9C: B9 40 07     LDA $0740,Y
C0/BF9F: C9 63        CMP #$63
C0/BFA1: F0 1A        BEQ $BFBD       ; branch if 99
C0/BFA3: 1A           INC 
C0/BFA4: 99 40 07     STA $0740,Y     ; increment item quantity
C0/BFA7: 80 14        BRA $BFBD
C0/BFA9: A4 06        LDY $06
C0/BFAB: B9 40 06     LDA $0640,Y     ; find the first empty slot
C0/BFAE: F0 03        BEQ $BFB3
C0/BFB0: C8           INY 
C0/BFB1: 80 F8        BRA $BFAB
C0/BFB3: A5 DF        LDA $DF
C0/BFB5: 99 40 06     STA $0640,Y     ; store item id
C0/BFB8: A9 01        LDA #$01
C0/BFBA: 99 40 07     STA $0740,Y     ; quantity 1
C0/BFBD: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $AB: remove item from inventory ]

C0/BFC0: A5 DF        LDA $DF
C0/BFC2: 20 DD BF     JSR $BFDD       ; find item slot
C0/BFC5: C0 00 01     CPY #$0100
C0/BFC8: F0 10        BEQ $BFDA
C0/BFCA: B9 40 07     LDA $0740,Y
C0/BFCD: F0 0B        BEQ $BFDA
C0/BFCF: 3A           DEC 
C0/BFD0: 99 40 07     STA $0740,Y
C0/BFD3: D0 05        BNE $BFDA
C0/BFD5: A9 00        LDA #$00
C0/BFD7: 99 40 06     STA $0640,Y
C0/BFDA: 4C 30 A6     JMP $A630       ; 2-byte command

; [ find item slot ]

C0/BFDD: 8D A2 16     STA $16A2
C0/BFE0: A4 06        LDY $06
C0/BFE2: B9 40 06     LDA $0640,Y     ; item id
C0/BFE5: CD A2 16     CMP $16A2
C0/BFE8: F0 06        BEQ $BFF0
C0/BFEA: C8           INY 
C0/BFEB: C0 00 01     CPY #$0100
C0/BFEE: D0 F2        BNE $BFE2
C0/BFF0: 60           RTS 

; [ event command $BA: remove status ]

C0/BFF1: A5 DF        LDA $DF
C0/BFF3: 29 07        AND #$07
C0/BFF5: 20 64 C1     JSR $C164       ; get pointer to character data
C0/BFF8: C0 40 01     CPY #$0140
C0/BFFB: F0 0F        BEQ $C00C
C0/BFFD: B9 00 05     LDA $0500,Y
C0/C000: 29 40        AND #$40
C0/C002: D0 08        BNE $C00C
C0/C004: B9 1A 05     LDA $051A,Y
C0/C007: 25 E0        AND $E0
C0/C009: 99 1A 05     STA $051A,Y
C0/C00C: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $BB: set status ]

C0/C00F: A5 DF        LDA $DF
C0/C011: 29 07        AND #$07
C0/C013: 20 64 C1     JSR $C164       ; get pointer to character data
C0/C016: C0 40 01     CPY #$0140
C0/C019: F0 0F        BEQ $C02A
C0/C01B: B9 00 05     LDA $0500,Y
C0/C01E: 29 40        AND #$40
C0/C020: D0 08        BNE $C02A
C0/C022: B9 1A 05     LDA $051A,Y
C0/C025: 05 E0        ORA $E0
C0/C027: 99 1A 05     STA $051A,Y
C0/C02A: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $BC:  ]

C0/C02D: A5 DF        LDA $DF
C0/C02F: 29 07        AND #$07
C0/C031: 20 64 C1     JSR $C164       ; get pointer to character data
C0/C034: C0 40 01     CPY #$0140
C0/C037: F0 0F        BEQ $C048
C0/C039: B9 00 05     LDA $0500,Y
C0/C03C: 29 40        AND #$40
C0/C03E: D0 08        BNE $C048
C0/C040: B9 1A 05     LDA $051A,Y
C0/C043: 45 E0        EOR $E0
C0/C045: 99 1A 05     STA $051A,Y
C0/C048: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $A8: modify hp ]

; b1: ccsvvvvv (c: character, s: subtract, v: hp value, #$1F = restore to max)

C0/C04B: A5 DF        LDA $DF
C0/C04D: 29 C0        AND #$C0
C0/C04F: 4A           LSR 
C0/C050: 4A           LSR 
C0/C051: 4A           LSR 
C0/C052: 4A           LSR 
C0/C053: 4A           LSR 
C0/C054: 4A           LSR 
C0/C055: 20 64 C1     JSR $C164       ; get pointer to character data
C0/C058: C0 40 01     CPY #$0140
C0/C05B: F0 70        BEQ $C0CD
C0/C05D: B9 00 05     LDA $0500,Y
C0/C060: 29 40        AND #$40
C0/C062: D0 69        BNE $C0CD
C0/C064: A5 DF        LDA $DF
C0/C066: 29 20        AND #$20
C0/C068: D0 33        BNE $C09D
C0/C06A: A5 DF        LDA $DF
C0/C06C: 29 1F        AND #$1F
C0/C06E: C9 1F        CMP #$1F
C0/C070: D0 0E        BNE $C080
C0/C072: C2 20        REP #$20
C0/C074: B9 08 05     LDA $0508,Y
C0/C077: 99 06 05     STA $0506,Y
C0/C07A: A5 06        LDA $06
C0/C07C: E2 20        SEP #$20
C0/C07E: 80 4D        BRA $C0CD
C0/C080: 0A           ASL 
C0/C081: AA           TAX 
C0/C082: C2 20        REP #$20
C0/C084: B9 06 05     LDA $0506,Y
C0/C087: 18           CLC 
C0/C088: 7F D0 C0 C0  ADC $C0C0D0,X
C0/C08C: D9 08 05     CMP $0508,Y
C0/C08F: 90 03        BCC $C094
C0/C091: B9 08 05     LDA $0508,Y
C0/C094: 99 06 05     STA $0506,Y
C0/C097: A5 06        LDA $06
C0/C099: E2 20        SEP #$20
C0/C09B: 80 30        BRA $C0CD
C0/C09D: A5 DF        LDA $DF
C0/C09F: 29 1F        AND #$1F
C0/C0A1: C9 1F        CMP #$1F
C0/C0A3: D0 0B        BNE $C0B0
C0/C0A5: C2 20        REP #$20
C0/C0A7: A5 06        LDA $06
C0/C0A9: 99 06 05     STA $0506,Y
C0/C0AC: E2 20        SEP #$20
C0/C0AE: 80 1D        BRA $C0CD
C0/C0B0: 0A           ASL 
C0/C0B1: AA           TAX 
C0/C0B2: C2 20        REP #$20
C0/C0B4: B9 06 05     LDA $0506,Y
C0/C0B7: 38           SEC 
C0/C0B8: FF D0 C0 C0  SBC $C0C0D0,X
C0/C0BC: F0 05        BEQ $C0C3
C0/C0BE: C9 0F 27     CMP #$270F
C0/C0C1: 90 03        BCC $C0C6
C0/C0C3: A9 01 00     LDA #$0001
C0/C0C6: 99 06 05     STA $0506,Y
C0/C0C9: A5 06        LDA $06
C0/C0CB: E2 20        SEP #$20
C0/C0CD: 4C 30 A6     JMP $A630       ; 2-byte command

; hp constants
C0/C0D0:              .DW $000A, $0014, $0032, $0064, $00C8, $01F4, $03E8, $07D0

; [ event command $A9: modify mp ]

C0/C0E0: A5 DF        LDA $DF
C0/C0E2: 29 C0        AND #$C0
C0/C0E4: 4A           LSR 
C0/C0E5: 4A           LSR 
C0/C0E6: 4A           LSR 
C0/C0E7: 4A           LSR 
C0/C0E8: 4A           LSR 
C0/C0E9: 4A           LSR 
C0/C0EA: 20 64 C1     JSR $C164       ; get pointer to character data
C0/C0ED: C0 40 01     CPY #$0140
C0/C0F0: F0 61        BEQ $C153
C0/C0F2: B9 00 05     LDA $0500,Y
C0/C0F5: 29 40        AND #$40
C0/C0F7: D0 5A        BNE $C153
C0/C0F9: A5 DF        LDA $DF
C0/C0FB: 29 20        AND #$20
C0/C0FD: D0 33        BNE $C132
C0/C0FF: A5 DF        LDA $DF
C0/C101: 29 1F        AND #$1F
C0/C103: C9 1F        CMP #$1F
C0/C105: D0 0E        BNE $C115
C0/C107: C2 20        REP #$20
C0/C109: B9 0C 05     LDA $050C,Y
C0/C10C: 99 0A 05     STA $050A,Y
C0/C10F: A5 06        LDA $06
C0/C111: E2 20        SEP #$20
C0/C113: 80 3E        BRA $C153
C0/C115: 0A           ASL 
C0/C116: AA           TAX 
C0/C117: C2 20        REP #$20
C0/C119: B9 0A 05     LDA $050A,Y
C0/C11C: 18           CLC 
C0/C11D: 7F 56 C1 C0  ADC $C0C156,X
C0/C121: D9 0C 05     CMP $050C,Y
C0/C124: 90 03        BCC $C129
C0/C126: B9 0C 05     LDA $050C,Y
C0/C129: 99 0A 05     STA $050A,Y
C0/C12C: A5 06        LDA $06
C0/C12E: E2 20        SEP #$20
C0/C130: 80 21        BRA $C153
C0/C132: A5 DF        LDA $DF
C0/C134: 29 1F        AND #$1F
C0/C136: 0A           ASL 
C0/C137: AA           TAX 
C0/C138: C2 20        REP #$20
C0/C13A: B9 0A 05     LDA $050A,Y
C0/C13D: 38           SEC 
C0/C13E: FF 56 C1 C0  SBC $C0C156,X
C0/C142: F0 05        BEQ $C149
C0/C144: C9 0F 27     CMP #$270F
C0/C147: 90 03        BCC $C14C
C0/C149: A9 01 00     LDA #$0001
C0/C14C: 99 0A 05     STA $050A,Y
C0/C14F: A5 06        LDA $06
C0/C151: E2 20        SEP #$20
C0/C153: 4C 30 A6     JMP $A630       ; 2-byte command

; mp constants
C0/C156:              .DW $000A, $0014, $0032, $0064, $00C8, $01F4, $03E8

; [ get pointer to character data ]

C0/C164: 85 09        STA $09
C0/C166: C9 02        CMP #$02
C0/C168: F0 19        BEQ $C183       ; branch if galuf
C0/C16A: C9 04        CMP #$04
C0/C16C: F0 15        BEQ $C183       ; branch if krile
C0/C16E: A4 06        LDY $06
C0/C170: B9 00 05     LDA $0500,Y
C0/C173: 29 07        AND #$07
C0/C175: C5 09        CMP $09
C0/C177: F0 23        BEQ $C19C
C0/C179: 20 9D C1     JSR $C19D
C0/C17C: C0 40 01     CPY #$0140
C0/C17F: F0 1B        BEQ $C19C
C0/C181: 80 ED        BRA $C170
C0/C183: A4 06        LDY $06
C0/C185: B9 00 05     LDA $0500,Y
C0/C188: 29 07        AND #$07
C0/C18A: C9 02        CMP #$02
C0/C18C: F0 0E        BEQ $C19C
C0/C18E: C9 04        CMP #$04
C0/C190: F0 0A        BEQ $C19C
C0/C192: 20 9D C1     JSR $C19D
C0/C195: C0 40 01     CPY #$0140
C0/C198: F0 02        BEQ $C19C
C0/C19A: 80 E9        BRA $C185
C0/C19C: 60           RTS 

C0/C19D: C2 20        REP #$20
C0/C19F: 98           TYA 
C0/C1A0: 18           CLC 
C0/C1A1: 69 50 00     ADC #$0050
C0/C1A4: A8           TAY 
C0/C1A5: A5 06        LDA $06
C0/C1A7: E2 20        SEP #$20
C0/C1A9: 60           RTS 

; [ event command $C2: hide vehicle ]

; b1: vehicle index

C0/C1AA: A5 DF        LDA $DF
C0/C1AC: 3A           DEC 
C0/C1AD: 0A           ASL 
C0/C1AE: 0A           ASL 
C0/C1AF: A8           TAY 
C0/C1B0: B9 DE 0A     LDA $0ADE,Y     ; hide vehicle
C0/C1B3: 09 80        ORA #$80
C0/C1B5: 99 DE 0A     STA $0ADE,Y
C0/C1B8: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $D2: show vehicle ]

; b1: map
; b2: x position
; b3: y position
; b4: vvvaaagg
;       v: vehicle index
;       a: 
;       g: graphics

C0/C1BB: A5 E2        LDA $E2
C0/C1BD: 29 E0        AND #$E0        ; vehicle index
C0/C1BF: 4A           LSR 
C0/C1C0: 4A           LSR 
C0/C1C1: 4A           LSR 
C0/C1C2: 38           SEC 
C0/C1C3: E9 04        SBC #$04
C0/C1C5: A8           TAY 
C0/C1C6: A5 DF        LDA $DF         ; map
C0/C1C8: 0A           ASL 
C0/C1C9: 0A           ASL 
C0/C1CA: 0A           ASL 
C0/C1CB: 0A           ASL 
C0/C1CC: 0A           ASL 
C0/C1CD: 85 08        STA $08
C0/C1CF: A5 E2        LDA $E2
C0/C1D1: 29 1F        AND #$1F
C0/C1D3: 05 08        ORA $08
C0/C1D5: 99 DD 0A     STA $0ADD,Y
C0/C1D8: A5 E0        LDA $E0
C0/C1DA: 99 DF 0A     STA $0ADF,Y     ; x position
C0/C1DD: A5 E1        LDA $E1
C0/C1DF: 99 E0 0A     STA $0AE0,Y     ; y position
C0/C1E2: B9 DE 0A     LDA $0ADE,Y     ; show vehicle
C0/C1E5: 29 7F        AND #$7F
C0/C1E7: 99 DE 0A     STA $0ADE,Y
C0/C1EA: 4C 48 A6     JMP $A648       ; 5-byte command

; [ event command $C9: resume suspended song ]

C0/C1ED: A5 DF        LDA $DF
C0/C1EF: 8D 02 1D     STA $1D02
C0/C1F2: A5 E0        LDA $E0
C0/C1F4: 8D 03 1D     STA $1D03
C0/C1F7: AD 09 1D     LDA $1D09       ; suspended song id
C0/C1FA: 8D 01 1D     STA $1D01
C0/C1FD: A9 01        LDA #$01
C0/C1FF: 8D 00 1D     STA $1D00
C0/C202: A9 01        LDA #$01
C0/C204: 85 5C        STA $5C
C0/C206: 22 04 00 C4  JSL $C40004
C0/C20A: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C20D: 64 5C        STZ $5C
C0/C20F: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $B4: play song ]

C0/C212: A5 DF        LDA $DF
C0/C214: 8D 01 1D     STA $1D01
C0/C217: A9 01        LDA #$01
C0/C219: 8D 00 1D     STA $1D00
C0/C21C: A9 08        LDA #$08        ; relative volume 100%
C0/C21E: 8D 02 1D     STA $1D02
C0/C221: A9 0F        LDA #$0F        ; absolute volume full
C0/C223: 8D 03 1D     STA $1D03
C0/C226: A9 01        LDA #$01
C0/C228: 85 5C        STA $5C
C0/C22A: 22 04 00 C4  JSL $C40004
C0/C22E: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C231: 64 5C        STZ $5C
C0/C233: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $D4: play song (specify volume) ]

C0/C236: A5 E0        LDA $E0
C0/C238: 8D 02 1D     STA $1D02
C0/C23B: A5 E1        LDA $E1
C0/C23D: 8D 03 1D     STA $1D03
C0/C240: A5 DF        LDA $DF
C0/C242: 8D 01 1D     STA $1D01
C0/C245: A9 01        LDA #$01
C0/C247: 8D 00 1D     STA $1D00
C0/C24A: A9 01        LDA #$01
C0/C24C: 85 5C        STA $5C
C0/C24E: 22 04 00 C4  JSL $C40004
C0/C252: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C255: 64 5C        STZ $5C
C0/C257: 4C 40 A6     JMP $A640       ; 4-byte command

; [ event command $B5: play sound effect ]

C0/C25A: A5 DF        LDA $DF
C0/C25C: 20 3C 46     JSR $463C       ; play sound effect
C0/C25F: 22 04 00 C4  JSL $C40004
C0/C263: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $D5: play sound effect (specify volume) ]

C0/C266: A5 DF        LDA $DF
C0/C268: 20 3C 46     JSR $463C       ; play sound effect
C0/C26B: A5 E0        LDA $E0
C0/C26D: 8D 02 1D     STA $1D02
C0/C270: A5 E1        LDA $E1
C0/C272: 8D 03 1D     STA $1D03
C0/C275: 22 04 00 C4  JSL $C40004
C0/C279: 4C 40 A6     JMP $A640       ; 4-byte command

; [ event command $76: set scroll speed to normal ]

C0/C27C: 9C FA 0A     STZ $0AFA
C0/C27F: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $78: set scroll speed to slow ]

C0/C282: A9 FF        LDA #$FF
C0/C284: 8D FA 0A     STA $0AFA
C0/C287: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $77: set scroll speed to fast ]

C0/C28A: A9 01        LDA #$01
C0/C28C: 8D FA 0A     STA $0AFA
C0/C28F: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $F1: jump forward randomly ]

; b1: bitmask with number of options (4 bytes each)

C0/C292: 20 2B 4F     JSR $4F2B       ; generate random number
C0/C295: 25 DF        AND $DF
C0/C297: C2 20        REP #$20
C0/C299: 0A           ASL 
C0/C29A: 0A           ASL 
C0/C29B: 1A           INC 
C0/C29C: 1A           INC 
C0/C29D: 18           CLC 
C0/C29E: 65 D6        ADC $D6
C0/C2A0: 85 D6        STA $D6
C0/C2A2: A5 06        LDA $06
C0/C2A4: 65 D8        ADC $D8
C0/C2A6: 85 D8        STA $D8
C0/C2A8: A5 06        LDA $06
C0/C2AA: E2 20        SEP #$20
C0/C2AC: 4C CB A2     JMP $A2CB       ; next command

; [ event command $F0: show dialog (yes/no) ]

C0/C2AF: C2 20        REP #$20
C0/C2B1: A5 DF        LDA $DF
C0/C2B3: 85 AF        STA $AF
C0/C2B5: A5 06        LDA $06
C0/C2B7: E2 20        SEP #$20
C0/C2B9: AE D6 0A     LDX $0AD6       ; map index
C0/C2BC: E0 05 00     CPX #$0005
C0/C2BF: 90 0C        BCC $C2CD
C0/C2C1: 20 95 4C     JSR $4C95       ; clear sprite data
C0/C2C4: 20 7C 23     JSR $237C       ; update party sprite
C0/C2C7: 20 B3 39     JSR $39B3       ; update object sprites
C0/C2CA: 20 42 28     JSR $2842
C0/C2CD: 20 01 84     JSR $8401       ; get pointer to dialog
C0/C2D0: 20 54 8F     JSR $8F54
C0/C2D3: A6 B1        LDX $B1
C0/C2D5: BF 00 00 CA  LDA $CA0000,X   ; dialog
C0/C2D9: F0 25        BEQ $C300       ; branch if end of string
C0/C2DB: 20 27 84     JSR $8427
C0/C2DE: A4 06        LDY $06
C0/C2E0: 84 AB        STY $AB
C0/C2E2: 20 3B 8D     JSR $8D3B
C0/C2E5: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C2E8: A4 AB        LDY $AB
C0/C2EA: C0 40 00     CPY #$0040
C0/C2ED: D0 F3        BNE $C2E2
C0/C2EF: A5 B3        LDA $B3
C0/C2F1: D0 0D        BNE $C300
C0/C2F3: 20 AD 4A     JSR $4AAD
C0/C2F6: 20 C1 4A     JSR $4AC1       ; wait for keypress
C0/C2F9: E6 A5        INC $A5
C0/C2FB: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C2FE: 80 D0        BRA $C2D0
C0/C300: 20 ED 8F     JSR $8FED       ; show yes/no window
C0/C303: A9 80        LDA #$80
C0/C305: 8D 97 16     STA $1697
C0/C308: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C30B: A5 03        LDA $03
C0/C30D: 29 0C        AND #$0C
C0/C30F: F0 0D        BEQ $C31E
C0/C311: C9 08        CMP #$08
C0/C313: D0 04        BNE $C319
C0/C315: A9 80        LDA #$80
C0/C317: 80 02        BRA $C31B
C0/C319: A9 81        LDA #$81
C0/C31B: 8D 97 16     STA $1697
C0/C31E: A5 03        LDA $03
C0/C320: 10 07        BPL $C329
C0/C322: A9 01        LDA #$01
C0/C324: 8D 97 16     STA $1697
C0/C327: 80 16        BRA $C33F
C0/C329: A5 02        LDA $02
C0/C32B: 29 80        AND #$80
C0/C32D: F0 D9        BEQ $C308
C0/C32F: AD B8 10     LDA $10B8
C0/C332: D0 D4        BNE $C308
C0/C334: EE B8 10     INC $10B8
C0/C337: AD 97 16     LDA $1697
C0/C33A: 29 01        AND #$01
C0/C33C: 8D 97 16     STA $1697
C0/C33F: 20 AD 90     JSR $90AD
C0/C342: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C345: 20 A8 94     JSR $94A8
C0/C348: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C34B: E6 A5        INC $A5
C0/C34D: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C350: A9 03        LDA #$03
C0/C352: 20 60 A6     JSR $A660       ; add to event pointer
C0/C355: AD 97 16     LDA $1697
C0/C358: F0 05        BEQ $C35F
C0/C35A: A9 04        LDA #$04
C0/C35C: 20 60 A6     JSR $A660       ; add to event pointer
C0/C35F: 4C CB A2     JMP $A2CB       ; next command

; [ event command $D6: change vehicle ]

; +b1: --ammmmm mmmmmmmm
;        m: map id
;        a: something with height ???
;  b3: vvvaaabb
;        v: vehicle id
;        a: vehicle graphic
;        g: vehicle frame ???

C0/C362: 20 E8 4C     JSR $4CE8       ; disable interrupts
C0/C365: 9C 9E 16     STZ $169E
C0/C368: AD D8 0A     LDA $0AD8
C0/C36B: 8D 88 10     STA $1088
C0/C36E: AD D9 0A     LDA $0AD9
C0/C371: 8D 89 10     STA $1089
C0/C374: C2 20        REP #$20
C0/C376: A5 DF        LDA $DF
C0/C378: 29 FF 1F     AND #$1FFF
C0/C37B: 8D D4 0A     STA $0AD4
C0/C37E: 8D D6 0A     STA $0AD6       ; map index
C0/C381: A5 06        LDA $06
C0/C383: E2 20        SEP #$20
C0/C385: A5 E1        LDA $E1
C0/C387: 4A           LSR 
C0/C388: 4A           LSR 
C0/C389: 4A           LSR 
C0/C38A: 4A           LSR 
C0/C38B: 4A           LSR 
C0/C38C: 8D DC 0A     STA $0ADC       ; current vehicle
C0/C38F: F0 2E        BEQ $C3BF       ; branch if no vehicle
C0/C391: 3A           DEC 
C0/C392: 0A           ASL 
C0/C393: 0A           ASL 
C0/C394: A8           TAY 
C0/C395: A5 E1        LDA $E1
C0/C397: 29 1F        AND #$1F
C0/C399: 99 DD 0A     STA $0ADD,Y
C0/C39C: A9 80        LDA #$80
C0/C39E: 99 DE 0A     STA $0ADE,Y
C0/C3A1: A5 E0        LDA $E0
C0/C3A3: 29 20        AND #$20
C0/C3A5: F0 18        BEQ $C3BF
C0/C3A7: B9 DE 0A     LDA $0ADE,Y
C0/C3AA: 09 0F        ORA #$0F
C0/C3AC: 99 DE 0A     STA $0ADE,Y
C0/C3AF: B9 DD 0A     LDA $0ADD,Y
C0/C3B2: 29 1C        AND #$1C
C0/C3B4: C9 18        CMP #$18
C0/C3B6: D0 07        BNE $C3BF
C0/C3B8: B9 DE 0A     LDA $0ADE,Y
C0/C3BB: 0A           ASL 
C0/C3BC: 99 DE 0A     STA $0ADE,Y
C0/C3BF: 20 28 55     JSR $5528       ; load world map
C0/C3C2: A9 81        LDA #$81
C0/C3C4: 8D 00 42     STA $4200
C0/C3C7: 58           CLI 
C0/C3C8: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C3CB: A9 04        LDA #$04
C0/C3CD: 20 60 A6     JSR $A660       ; add to event pointer
C0/C3D0: 4C CB A2     JMP $A2CB       ; next command


; [ event command $E0: load map (fade out/in) ]

; +b0: ?pt---mm mmmmmmmm
;      p: set parent map
;      t: show map title
;      m: map index
;  b1: ffxxxxxx
;      f: facing direction (normal map only)
;      x: x position
;  b2: y position
;  b3: vvvhhhhh
;      v: vehicle
;      h: vehicle height ???

C0/C3D3: 20 81 60     JSR $6081       ; fade out
C0/C3D6: 20 3F C4     JSR $C43F
C0/C3D9: AE D6 0A     LDX $0AD6       ; map index
C0/C3DC: E0 05 00     CPX #$0005
C0/C3DF: B0 05        BCS $C3E6
C0/C3E1: 20 28 55     JSR $5528       ; load world map
C0/C3E4: 80 03        BRA $C3E9
C0/C3E6: 20 4C 57     JSR $574C       ; load normal map
C0/C3E9: 20 00 61     JSR $6100       ; fade in
C0/C3EC: 20 67 92     JSR $9267       ; show map title
C0/C3EF: A9 06        LDA #$06
C0/C3F1: 20 60 A6     JSR $A660       ; add to event pointer
C0/C3F4: 4C CB A2     JMP $A2CB       ; next command

; [ event command $E1: load map (no fade) ]

C0/C3F7: 20 3F C4     JSR $C43F
C0/C3FA: AE D6 0A     LDX $0AD6       ; map index
C0/C3FD: E0 05 00     CPX #$0005
C0/C400: B0 05        BCS $C407
C0/C402: 20 28 55     JSR $5528       ; load world map
C0/C405: 80 03        BRA $C40A
C0/C407: 20 4C 57     JSR $574C       ; load normal map
C0/C40A: 20 FA 4C     JSR $4CFA       ; enable interrupts
C0/C40D: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C410: A9 06        LDA #$06
C0/C412: 20 60 A6     JSR $A660       ; add to event pointer
C0/C415: 4C CB A2     JMP $A2CB       ; next command

; [ event command $E3: load map (fade out only) ]

C0/C418: 20 81 60     JSR $6081       ; fade out
C0/C41B: 20 3F C4     JSR $C43F
C0/C41E: AE D6 0A     LDX $0AD6       ; map index
C0/C421: E0 05 00     CPX #$0005
C0/C424: B0 05        BCS $C42B
C0/C426: 20 28 55     JSR $5528       ; load world map
C0/C429: 80 03        BRA $C42E
C0/C42B: 20 4C 57     JSR $574C       ; load normal map
C0/C42E: A9 81        LDA #$81
C0/C430: 8D 00 42     STA $4200
C0/C433: 58           CLI 
C0/C434: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C437: A9 06        LDA #$06
C0/C439: 20 60 A6     JSR $A660       ; add to event pointer
C0/C43C: 4C CB A2     JMP $A2CB       ; next command

; [  ]

C0/C43F: 20 E8 4C     JSR $4CE8       ; disable interrupts
C0/C442: 9C A0 16     STZ $16A0       ; disable map title
C0/C445: AE D6 0A     LDX $0AD6       ; map index
C0/C448: E0 05 00     CPX #$0005
C0/C44B: B0 0F        BCS $C45C
C0/C44D: A5 E0        LDA $E0
C0/C44F: 29 40        AND #$40
C0/C451: F0 09        BEQ $C45C
C0/C453: 8E F5 0A     STX $0AF5       ; set parent map
C0/C456: AE D8 0A     LDX $0AD8
C0/C459: 8E F7 0A     STX $0AF7       ; set parent xy position
C0/C45C: 9C 9E 16     STZ $169E
C0/C45F: A5 E2        LDA $E2         ; y position
C0/C461: 8D 89 10     STA $1089
C0/C464: A5 E3        LDA $E3
C0/C466: 4A           LSR 
C0/C467: 4A           LSR 
C0/C468: 4A           LSR 
C0/C469: 4A           LSR 
C0/C46A: 4A           LSR 
C0/C46B: 8D DC 0A     STA $0ADC       ; vehicle
C0/C46E: F0 2E        BEQ $C49E
C0/C470: 3A           DEC 
C0/C471: 0A           ASL 
C0/C472: 0A           ASL 
C0/C473: A8           TAY 
C0/C474: A5 E3        LDA $E3
C0/C476: 29 1F        AND #$1F
C0/C478: 99 DD 0A     STA $0ADD,Y     ; 
C0/C47B: A9 80        LDA #$80
C0/C47D: 99 DE 0A     STA $0ADE,Y
C0/C480: A5 E0        LDA $E0
C0/C482: 29 20        AND #$20
C0/C484: F0 18        BEQ $C49E
C0/C486: B9 DE 0A     LDA $0ADE,Y
C0/C489: 09 0F        ORA #$0F
C0/C48B: 99 DE 0A     STA $0ADE,Y
C0/C48E: B9 DD 0A     LDA $0ADD,Y
C0/C491: 29 1C        AND #$1C
C0/C493: C9 18        CMP #$18
C0/C495: D0 07        BNE $C49E
C0/C497: B9 DE 0A     LDA $0ADE,Y
C0/C49A: 0A           ASL 
C0/C49B: 99 DE 0A     STA $0ADE,Y
C0/C49E: C2 20        REP #$20
C0/C4A0: A5 DF        LDA $DF
C0/C4A2: 29 FF 03     AND #$03FF
C0/C4A5: 8D D4 0A     STA $0AD4
C0/C4A8: 8D D6 0A     STA $0AD6       ; map index
C0/C4AB: A8           TAY 
C0/C4AC: A5 06        LDA $06
C0/C4AE: E2 20        SEP #$20
C0/C4B0: C0 05 00     CPY #$0005
C0/C4B3: B0 08        BCS $C4BD
C0/C4B5: A5 E1        LDA $E1
C0/C4B7: 8D 88 10     STA $1088       ; x position (world map)
C0/C4BA: 4C DF C4     JMP $C4DF
C0/C4BD: A5 E0        LDA $E0
C0/C4BF: 10 03        BPL $C4C4
C0/C4C1: EE A0 16     INC $16A0       ; enable map title
C0/C4C4: A5 E1        LDA $E1
C0/C4C6: 4A           LSR 
C0/C4C7: 4A           LSR 
C0/C4C8: 4A           LSR 
C0/C4C9: 4A           LSR 
C0/C4CA: 4A           LSR 
C0/C4CB: 4A           LSR 
C0/C4CC: 48           PHA 
C0/C4CD: 85 B9        STA $B9
C0/C4CF: 0A           ASL 
C0/C4D0: 85 BB        STA $BB         ; party graphic action
C0/C4D2: 68           PLA 
C0/C4D3: 1A           INC 
C0/C4D4: 85 BA        STA $BA
C0/C4D6: 85 BF        STA $BF
C0/C4D8: A5 E1        LDA $E1
C0/C4DA: 29 3F        AND #$3F
C0/C4DC: 8D 88 10     STA $1088       ; x position (normal map)
C0/C4DF: 60           RTS 

; [ event command $F4: change background (relative) ]

C0/C4E0: A5 DF        LDA $DF
C0/C4E2: 29 C0        AND #$C0
C0/C4E4: 4A           LSR 
C0/C4E5: 4A           LSR 
C0/C4E6: C2 20        REP #$20
C0/C4E8: EB           XBA 
C0/C4E9: 85 73        STA $73
C0/C4EB: A5 06        LDA $06
C0/C4ED: E2 20        SEP #$20
C0/C4EF: A5 DF        LDA $DF
C0/C4F1: 29 3F        AND #$3F
C0/C4F3: 18           CLC 
C0/C4F4: 6D D8 0A     ADC $0AD8       ; party x position
C0/C4F7: 85 75        STA $75
C0/C4F9: A5 E0        LDA $E0
C0/C4FB: 18           CLC 
C0/C4FC: 6D D9 0A     ADC $0AD9       ; party y position
C0/C4FF: 85 76        STA $76
C0/C501: 4C 1D C5     JMP $C51D

; [ event command $F3: change background (absolute) ]

C0/C504: A5 DF        LDA $DF
C0/C506: 29 C0        AND #$C0
C0/C508: 4A           LSR 
C0/C509: 4A           LSR 
C0/C50A: C2 20        REP #$20
C0/C50C: EB           XBA 
C0/C50D: 85 73        STA $73
C0/C50F: A5 06        LDA $06
C0/C511: E2 20        SEP #$20
C0/C513: A5 DF        LDA $DF
C0/C515: 29 3F        AND #$3F
C0/C517: 85 75        STA $75
C0/C519: A5 E0        LDA $E0
C0/C51B: 85 76        STA $76
C0/C51D: A5 E1        LDA $E1
C0/C51F: 29 0F        AND #$0F
C0/C521: 1A           INC 
C0/C522: 85 2C        STA $2C
C0/C524: 8D 02 42     STA $4202
C0/C527: A5 E1        LDA $E1
C0/C529: 4A           LSR 
C0/C52A: 4A           LSR 
C0/C52B: 4A           LSR 
C0/C52C: 4A           LSR 
C0/C52D: 1A           INC 
C0/C52E: 85 2D        STA $2D
C0/C530: 8D 03 42     STA $4203
C0/C533: EA           NOP 
C0/C534: EA           NOP 
C0/C535: EA           NOP 
C0/C536: EA           NOP 
C0/C537: C2 20        REP #$20
C0/C539: AD 16 42     LDA $4216
C0/C53C: 85 0D        STA $0D
C0/C53E: A5 06        LDA $06
C0/C540: E2 20        SEP #$20
C0/C542: A0 04 00     LDY #$0004
C0/C545: A6 06        LDX $06
C0/C547: B7 D6        LDA [$D6],Y
C0/C549: 9D B3 16     STA $16B3,X
C0/C54C: C8           INY 
C0/C54D: E8           INX 
C0/C54E: E4 0D        CPX $0D
C0/C550: D0 F5        BNE $C547
C0/C552: C2 20        REP #$20
C0/C554: A5 0D        LDA $0D
C0/C556: 18           CLC 
C0/C557: 69 04 00     ADC #$0004
C0/C55A: 18           CLC 
C0/C55B: 65 D6        ADC $D6
C0/C55D: 85 D6        STA $D6
C0/C55F: A5 06        LDA $06
C0/C561: 65 D8        ADC $D8
C0/C563: 85 D8        STA $D8
C0/C565: A5 06        LDA $06
C0/C567: E2 20        SEP #$20
C0/C569: 20 08 6F     JSR $6F08
C0/C56C: 4C CB A2     JMP $A2CB       ; next command

; [ event command $7C: disable timer ]

C0/C56F: 9C FB 0A     STZ $0AFB       ; hide timer
C0/C572: A6 06        LDX $06
C0/C574: 8E FC 0A     STX $0AFC       ; clear timer counter
C0/C577: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $D8: set object position (relative) ]

C0/C57A: A5 DF        LDA $DF
C0/C57C: 29 1F        AND #$1F
C0/C57E: 20 E4 C5     JSR $C5E4       ; remove current object from object layout
C0/C581: A5 DF        LDA $DF
C0/C583: 29 C0        AND #$C0
C0/C585: 4A           LSR 
C0/C586: 4A           LSR 
C0/C587: 4A           LSR 
C0/C588: 4A           LSR 
C0/C589: 4A           LSR 
C0/C58A: 99 7C 14     STA $147C,Y     ; graphic frame
C0/C58D: A5 E0        LDA $E0
C0/C58F: 4A           LSR 
C0/C590: 4A           LSR 
C0/C591: 4A           LSR 
C0/C592: 4A           LSR 
C0/C593: 85 08        STA $08
C0/C595: 29 08        AND #$08
C0/C597: F0 06        BEQ $C59F
C0/C599: A5 08        LDA $08
C0/C59B: 09 F0        ORA #$F0
C0/C59D: 85 08        STA $08
C0/C59F: A5 08        LDA $08
C0/C5A1: 18           CLC 
C0/C5A2: 6D D8 0A     ADC $0AD8
C0/C5A5: 99 78 14     STA $1478,Y     ; x position
C0/C5A8: A5 E0        LDA $E0
C0/C5AA: 29 0F        AND #$0F
C0/C5AC: 85 08        STA $08
C0/C5AE: 29 08        AND #$08
C0/C5B0: F0 06        BEQ $C5B8
C0/C5B2: A5 08        LDA $08
C0/C5B4: 09 F0        ORA #$F0
C0/C5B6: 85 08        STA $08
C0/C5B8: A5 08        LDA $08
C0/C5BA: 18           CLC 
C0/C5BB: 6D D9 0A     ADC $0AD9
C0/C5BE: 99 7A 14     STA $147A,Y     ; y position
C0/C5C1: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $D3: set object position (absolute) ]

; b1: object index
; b2: ddxxxxxx
;     d: facing direction
;     x: x position
; b3: y position

C0/C5C4: A5 DF        LDA $DF
C0/C5C6: 20 E4 C5     JSR $C5E4       ; remove current object from object layout
C0/C5C9: A5 E0        LDA $E0
C0/C5CB: 29 C0        AND #$C0
C0/C5CD: 4A           LSR 
C0/C5CE: 4A           LSR 
C0/C5CF: 4A           LSR 
C0/C5D0: 4A           LSR 
C0/C5D1: 4A           LSR 
C0/C5D2: 99 7C 14     STA $147C,Y
C0/C5D5: A5 E0        LDA $E0
C0/C5D7: 29 3F        AND #$3F
C0/C5D9: 99 78 14     STA $1478,Y
C0/C5DC: A5 E1        LDA $E1
C0/C5DE: 99 7A 14     STA $147A,Y
C0/C5E1: 4C 40 A6     JMP $A640       ; 4-byte command

; [ remove current object from object layout ]

C0/C5E4: 29 7F        AND #$7F
C0/C5E6: 85 E5        STA $E5         ; current object
C0/C5E8: 8D 02 42     STA $4202
C0/C5EB: A9 14        LDA #$14
C0/C5ED: 8D 03 42     STA $4203
C0/C5F0: EA           NOP 
C0/C5F1: EA           NOP 
C0/C5F2: EA           NOP 
C0/C5F3: EA           NOP 
C0/C5F4: AC 16 42     LDY $4216
C0/C5F7: 20 F8 3C     JSR $3CF8       ; remove object from object layout
C0/C5FA: 60           RTS 

; [ event command $D1: start timer ]

;  b1: timer duration (seconds)
; +b2: event

C0/C5FB: A5 DF        LDA $DF
C0/C5FD: 8D 02 42     STA $4202
C0/C600: A9 3C        LDA #$3C
C0/C602: 8D 03 42     STA $4203
C0/C605: EA           NOP 
C0/C606: EA           NOP 
C0/C607: EA           NOP 
C0/C608: EA           NOP 
C0/C609: C2 20        REP #$20
C0/C60B: AD 16 42     LDA $4216
C0/C60E: 1A           INC 
C0/C60F: 8D FC 0A     STA $0AFC       ; timer counter
C0/C612: A5 E0        LDA $E0
C0/C614: 8D FE 0A     STA $0AFE       ; timer event
C0/C617: A5 06        LDA $06
C0/C619: E2 20        SEP #$20
C0/C61B: A9 01        LDA #$01        ; enable timer
C0/C61D: 8D FB 0A     STA $0AFB
C0/C620: 4C 40 A6     JMP $A640       ; 4-byte command

; [ event command $D7: start timer (speed up music) ]

;  b1: timer duration (seconds / 4)
; +b2: event

C0/C623: A5 DF        LDA $DF
C0/C625: 8D 02 42     STA $4202
C0/C628: A9 F0        LDA #$F0
C0/C62A: 8D 03 42     STA $4203
C0/C62D: EA           NOP 
C0/C62E: EA           NOP 
C0/C62F: EA           NOP 
C0/C630: EA           NOP 
C0/C631: C2 20        REP #$20
C0/C633: AD 16 42     LDA $4216
C0/C636: 1A           INC 
C0/C637: 8D FC 0A     STA $0AFC
C0/C63A: A5 E0        LDA $E0
C0/C63C: 8D FE 0A     STA $0AFE
C0/C63F: A5 06        LDA $06
C0/C641: E2 20        SEP #$20
C0/C643: A9 02        LDA #$02
C0/C645: 8D FB 0A     STA $0AFB
C0/C648: 4C 40 A6     JMP $A640       ; 4-byte command

; [ event command $7D:  ]

C0/C64B: 64 46        STZ $46
C0/C64D: 64 44        STZ $44
C0/C64F: A5 48        LDA $48
C0/C651: 85 47        STA $47
C0/C653: A5 4A        LDA $4A
C0/C655: 85 49        STA $49
C0/C657: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $C5: flash screen ]

; b1: bgr----- (color components)

C0/C65A: A5 46        LDA $46
C0/C65C: D0 0A        BNE $C668
C0/C65E: A5 47        LDA $47
C0/C660: 85 48        STA $48
C0/C662: A5 49        LDA $49
C0/C664: 85 4A        STA $4A
C0/C666: 64 49        STZ $49
C0/C668: A9 07        LDA #$07
C0/C66A: 85 47        STA $47         ; addition subtraction -> 2131
C0/C66C: A5 DF        LDA $DF
C0/C66E: 29 E0        AND #$E0
C0/C670: 85 4C        STA $4C
C0/C672: A9 F8        LDA #$F8
C0/C674: 85 46        STA $46
C0/C676: A9 08        LDA #$08
C0/C678: 85 44        STA $44
C0/C67A: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $B8: color addition ]

; if color math is already active, reverse the rate using the same parameters

; b1: bgrssiii
;     b: affect blue
;     g: affect green
;     r: affect red
;     s: speed
;     i: intensity

C0/C67D: A5 46        LDA $46
C0/C67F: D0 08        BNE $C689       ; if already active, reverse rate
C0/C681: A5 DF        LDA $DF
C0/C683: 20 D7 49     JSR $49D7       ; init color addition
C0/C686: 4C 30 A6     JMP $A630       ; 2-byte command
C0/C689: A5 44        LDA $44
C0/C68B: 29 7F        AND #$7F
C0/C68D: 85 44        STA $44
C0/C68F: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $B9: color subtraction ]

; same parameters as color subtraction

C0/C692: A5 46        LDA $46
C0/C694: D0 08        BNE $C69E       ; if already active, reverse rate
C0/C696: A5 DF        LDA $DF
C0/C698: 20 E9 49     JSR $49E9       ; init color subtraction
C0/C69B: 4C 30 A6     JMP $A630       ; 2-byte command
C0/C69E: A5 44        LDA $44
C0/C6A0: 29 7F        AND #$7F
C0/C6A2: 85 44        STA $44
C0/C6A4: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $7E: stop fade ]

C0/C6A7: 64 43        STZ $43
C0/C6A9: 4C 28 A6     JMP $A628       ; 1-byte command

; [ event command $C3: fade in ]

C0/C6AC: A5 DF        LDA $DF         ; fade speed
C0/C6AE: 85 43        STA $43
C0/C6B0: A9 10        LDA #$10        ; screen brightness
C0/C6B2: 85 45        STA $45
C0/C6B4: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $C4: fade out ]

C0/C6B7: A5 DF        LDA $DF         ;  fade speed
C0/C6B9: 09 80        ORA #$80
C0/C6BB: 85 43        STA $43
C0/C6BD: A9 F0        LDA #$F0        ; screen brightness
C0/C6BF: 85 45        STA $45
C0/C6C1: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $BE: shake screen ]

C0/C6C4: A5 DF        LDA $DF
C0/C6C6: 85 D3        STA $D3
C0/C6C8: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $C1:  ]

C0/C6CB: A5 DF        LDA $DF
C0/C6CD: 85 A4        STA $A4
C0/C6CF: E6 A2        INC $A2
C0/C6D1: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $B1: set party sprite graphic ]

C0/C6D4: A5 DF        LDA $DF
C0/C6D6: 8D DA 0A     STA $0ADA
C0/C6D9: E6 A1        INC $A1
C0/C6DB: 4C 30 A6     JMP $A630       ; 2-byte command

C0/C6DE: 20 95 4C     JSR $4C95       ; clear sprite data
C0/C6E1: A5 53        LDA $53
C0/C6E3: D0 13        BNE $C6F8
C0/C6E5: 20 1D 1A     JSR $1A1D
C0/C6E8: 20 37 21     JSR $2137
C0/C6EB: 20 C5 1E     JSR $1EC5
C0/C6EE: 20 64 1E     JSR $1E64
C0/C6F1: 20 0A 42     JSR $420A
C0/C6F4: 20 2B 61     JSR $612B
C0/C6F7: 60           RTS 
C0/C6F8: 20 E4 1A     JSR $1AE4
C0/C6FB: 20 AC 3B     JSR $3BAC
C0/C6FE: 20 7C 23     JSR $237C       ; update party sprite
C0/C701: 20 B3 39     JSR $39B3       ; update object sprites
C0/C704: 20 42 28     JSR $2842
C0/C707: 20 0A 42     JSR $420A
C0/C70A: 60           RTS 

; [ event command $B2: wait xx frames ]

C0/C70B: A5 DF        LDA $DF
C0/C70D: AA           TAX 
C0/C70E: DA           PHX 
C0/C70F: 20 DE C6     JSR $C6DE
C0/C712: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C715: FA           PLX 
C0/C716: CA           DEX 
C0/C717: D0 F5        BNE $C70E
C0/C719: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $B3: wait xx * 15 frames ]

C0/C71C: A5 DF        LDA $DF
C0/C71E: AA           TAX 
C0/C71F: DA           PHX 
C0/C720: A0 0F 00     LDY #$000F
C0/C723: 5A           PHY 
C0/C724: 20 DE C6     JSR $C6DE
C0/C727: 20 41 4E     JSR $4E41       ; wait for vblank
C0/C72A: 7A           PLY 
C0/C72B: 88           DEY 
C0/C72C: D0 F5        BNE $C723
C0/C72E: FA           PLX 
C0/C72F: CA           DEX 
C0/C730: D0 ED        BNE $C71F
C0/C732: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $A0: show npc dialog ]

; b1: npc dialog index

C0/C735: A5 DF        LDA $DF
C0/C737: 0A           ASL 
C0/C738: AA           TAX 
C0/C739: BC D6 13     LDY $13D6,X
C0/C73C: 84 AF        STY $AF
C0/C73E: AE D6 0A     LDX $0AD6       ; map index
C0/C741: E0 05 00     CPX #$0005
C0/C744: 90 0C        BCC $C752
C0/C746: 20 95 4C     JSR $4C95       ; clear sprite data
C0/C749: 20 7C 23     JSR $237C       ; update party sprite
C0/C74C: 20 B3 39     JSR $39B3       ; update object sprites
C0/C74F: 20 42 28     JSR $2842
C0/C752: 20 AE 83     JSR $83AE       ; show dialog
C0/C755: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $A2: set event flag ]

; b1: event flag (0-255)

C0/C758: A5 DF        LDA $DF
C0/C75A: 20 49 CA     JSR $CA49       ; get flag index
C0/C75D: B9 14 0A     LDA $0A14,Y     ; event flags
C0/C760: 1F 59 CA C0  ORA $C0CA59,X
C0/C764: 99 14 0A     STA $0A14,Y
C0/C767: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $A4: set event flag ]

; b1: event flag (256-511)

C0/C76A: A5 DF        LDA $DF
C0/C76C: 20 49 CA     JSR $CA49       ; get flag index
C0/C76F: B9 34 0A     LDA $0A34,Y
C0/C772: 1F 59 CA C0  ORA $C0CA59,X
C0/C776: 99 34 0A     STA $0A34,Y
C0/C779: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $A3: clear event flag ]

; b1: event flag (0-255)

C0/C77C: A5 DF        LDA $DF
C0/C77E: 20 49 CA     JSR $CA49       ; get flag index
C0/C781: B9 14 0A     LDA $0A14,Y
C0/C784: 3F 61 CA C0  AND $C0CA61,X
C0/C788: 99 14 0A     STA $0A14,Y
C0/C78B: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $A5: clear event flag ]

; b1: event flag (256-511)

C0/C78E: A5 DF        LDA $DF
C0/C790: 20 96 C7     JSR $C796
C0/C793: 4C 30 A6     JMP $A630       ; 2-byte command
C0/C796: 20 49 CA     JSR $CA49       ; get flag index
C0/C799: B9 34 0A     LDA $0A34,Y
C0/C79C: 3F 61 CA C0  AND $C0CA61,X
C0/C7A0: 99 34 0A     STA $0A34,Y
C0/C7A3: 60           RTS 

; [ event command $C8: show dialog ]

; +b1: dialog index

C0/C7A4: C2 20        REP #$20
C0/C7A6: A5 DF        LDA $DF
C0/C7A8: 85 AF        STA $AF         ; dialog index
C0/C7AA: A5 06        LDA $06
C0/C7AC: E2 20        SEP #$20
C0/C7AE: AE D6 0A     LDX $0AD6       ; map index
C0/C7B1: E0 05 00     CPX #$0005
C0/C7B4: 90 0C        BCC $C7C2       ; branch if a world map
C0/C7B6: 20 95 4C     JSR $4C95       ; clear sprite data
C0/C7B9: 20 7C 23     JSR $237C       ; update party sprite
C0/C7BC: 20 B3 39     JSR $39B3       ; update object sprites
C0/C7BF: 20 42 28     JSR $2842
C0/C7C2: 20 AE 83     JSR $83AE       ; show dialog
C0/C7C5: 4C 38 A6     JMP $A638       ; 3-byte command

; [ init object movement ]

C0/C7C8: 20 E4 C5     JSR $C5E4       ; remove current object from object layout
C0/C7CB: A9 01        LDA #$01
C0/C7CD: 20 60 A6     JSR $A660       ; add to event pointer
C0/C7D0: 5A           PHY 
C0/C7D1: A4 06        LDY $06
C0/C7D3: B7 D6        LDA [$D6],Y     ; action
C0/C7D5: 7A           PLY 
C0/C7D6: C9 05        CMP #$05
C0/C7D8: B0 1F        BCS $C7F9       ; branch if not a move action
C0/C7DA: 99 7B 14     STA $147B,Y     ; set facing direction
C0/C7DD: B9 85 14     LDA $1485,Y
C0/C7E0: 29 08        AND #$08
C0/C7E2: F0 0A        BEQ $C7EE
C0/C7E4: B9 7B 14     LDA $147B,Y     ; facing direction
C0/C7E7: F0 05        BEQ $C7EE
C0/C7E9: 3A           DEC 
C0/C7EA: 0A           ASL 
C0/C7EB: 99 7C 14     STA $147C,Y     ; graphic frame
C0/C7EE: A9 01        LDA #$01
C0/C7F0: 99 86 14     STA $1486,Y
C0/C7F3: A9 00        LDA #$00
C0/C7F5: 99 7D 14     STA $147D,Y     ; movement animation counter
C0/C7F8: 60           RTS 

; [ event command $80-$9F: object action ]

; b0: object
: b1: action

C0/C7F9: A5 DE        LDA $DE
C0/C7FB: 38           SEC 
C0/C7FC: E9 80        SBC #$80
C0/C7FE: 85 E5        STA $E5         ; object
C0/C800: 8D 02 42     STA $4202
C0/C803: A9 14        LDA #$14
C0/C805: 8D 03 42     STA $4203
C0/C808: EA           NOP 
C0/C809: EA           NOP 
C0/C80A: EA           NOP 
C0/C80B: EA           NOP 
C0/C80C: AC 16 42     LDY $4216       ; pointer to object data
C0/C80F: A5 DF        LDA $DF

; object action $05: jump 1 tile
C0/C811: C9 05        CMP #$05
C0/C813: D0 10        BNE $C825
C0/C815: A9 40        LDA #$40
C0/C817: 99 88 14     STA $1488,Y
C0/C81A: B9 85 14     LDA $1485,Y
C0/C81D: 29 FB        AND #$FB
C0/C81F: 99 85 14     STA $1485,Y
C0/C822: 4C 2F C9     JMP $C92F

; object action $06: jump 2 tiles
C0/C825: C9 06        CMP #$06
C0/C827: D0 12        BNE $C83B
C0/C829: A9 80        LDA #$80
C0/C82B: 99 88 14     STA $1488,Y
C0/C82E: B9 85 14     LDA $1485,Y
C0/C831: 29 FB        AND #$FB
C0/C833: 09 04        ORA #$04
C0/C835: 99 85 14     STA $1485,Y
C0/C838: 4C 2F C9     JMP $C92F

; object action $07: toggle sprite priority (top half)
C0/C83B: C9 07        CMP #$07
C0/C83D: D0 0B        BNE $C84A
C0/C83F: B9 82 14     LDA $1482,Y
C0/C842: 49 10        EOR #$10
C0/C844: 99 82 14     STA $1482,Y
C0/C847: 4C 2F C9     JMP $C92F

; object action $08: toggle sprite priority (bottom half)
C0/C84A: C9 08        CMP #$08
C0/C84C: D0 0B        BNE $C859
C0/C84E: B9 84 14     LDA $1484,Y
C0/C851: 49 10        EOR #$10
C0/C853: 99 84 14     STA $1484,Y
C0/C856: 4C 2F C9     JMP $C92F

; object action $09: show object
C0/C859: C9 09        CMP #$09
C0/C85B: D0 0D        BNE $C86A
C0/C85D: B9 85 14     LDA $1485,Y
C0/C860: 29 FE        AND #$FE
C0/C862: 09 01        ORA #$01
C0/C864: 99 85 14     STA $1485,Y
C0/C867: 4C 2F C9     JMP $C92F

; object action $0A: hide object
C0/C86A: C9 0A        CMP #$0A
C0/C86C: D0 18        BNE $C886
C0/C86E: B9 85 14     LDA $1485,Y
C0/C871: 29 FE        AND #$FE
C0/C873: 99 85 14     STA $1485,Y
C0/C876: 20 F8 3C     JSR $3CF8       ; remove object from object layout
C0/C879: 4C 2F C9     JMP $C92F

C0/C87C: 00 00        BRK $00
C0/C87E: 01 00        ORA ($00,X)
C0/C880: FF 00 FF 00  SBC $00FF00,X
C0/C884: 01 00        ORA ($00,X)

; object action $0B: toggle walking animation
C0/C886: C9 0B        CMP #$0B
C0/C888: D0 10        BNE $C89A
C0/C88A: B9 85 14     LDA $1485,Y
C0/C88D: 49 08        EOR #$08
C0/C88F: 99 85 14     STA $1485,Y
C0/C892: A9 00        LDA #$00
C0/C894: 99 7D 14     STA $147D,Y
C0/C897: 4C 2F C9     JMP $C92F

; object action $0C
C0/C89A: C9 0C        CMP #$0C
C0/C89C: D0 10        BNE $C8AE
C0/C89E: B9 7E 14     LDA $147E,Y
C0/C8A1: 49 04        EOR #$04
C0/C8A3: 99 7E 14     STA $147E,Y
C0/C8A6: A9 00        LDA #$00
C0/C8A8: 99 7D 14     STA $147D,Y
C0/C8AB: 4C 2F C9     JMP $C92F

; object action $0D
C0/C8AE: C9 0D        CMP #$0D
C0/C8B0: D0 0A        BNE $C8BC
C0/C8B2: B9 85 14     LDA $1485,Y
C0/C8B5: 29 3F        AND #$3F
C0/C8B7: 99 85 14     STA $1485,Y
C0/C8BA: 80 73        BRA $C92F

; object action $0E
C0/C8BC: C9 0E        CMP #$0E
C0/C8BE: D0 0C        BNE $C8CC
C0/C8C0: B9 85 14     LDA $1485,Y
C0/C8C3: 29 3F        AND #$3F
C0/C8C5: 09 80        ORA #$80
C0/C8C7: 99 85 14     STA $1485,Y
C0/C8CA: 80 63        BRA $C92F

; object action $0F
C0/C8CC: C9 0F        CMP #$0F
C0/C8CE: D0 0C        BNE $C8DC
C0/C8D0: B9 85 14     LDA $1485,Y
C0/C8D3: 29 3F        AND #$3F
C0/C8D5: 09 C0        ORA #$C0
C0/C8D7: 99 85 14     STA $1485,Y
C0/C8DA: 80 53        BRA $C92F

; object action $10-$13: set animation speed
C0/C8DC: C9 14        CMP #$14
C0/C8DE: B0 11        BCS $C8F1
C0/C8E0: 38           SEC 
C0/C8E1: E9 10        SBC #$10
C0/C8E3: 85 08        STA $08
C0/C8E5: B9 7E 14     LDA $147E,Y
C0/C8E8: 29 FC        AND #$FC
C0/C8EA: 05 08        ORA $08
C0/C8EC: 99 7E 14     STA $147E,Y
C0/C8EF: 80 3E        BRA $C92F

; object action $14: toggle layer priority (top half)
C0/C8F1: C9 14        CMP #$14
C0/C8F3: D0 0A        BNE $C8FF
C0/C8F5: B9 82 14     LDA $1482,Y
C0/C8F8: 49 08        EOR #$08
C0/C8FA: 99 82 14     STA $1482,Y
C0/C8FD: 80 30        BRA $C92F

; object action $15: toggle layer priority (bottom half)
C0/C8FF: C9 15        CMP #$15
C0/C901: D0 0A        BNE $C90D
C0/C903: B9 84 14     LDA $1484,Y
C0/C906: 49 08        EOR #$08
C0/C908: 99 84 14     STA $1484,Y
C0/C90B: 80 22        BRA $C92F

; object action $16
C0/C90D: C9 16        CMP #$16
C0/C90F: D0 0A        BNE $C91B
C0/C911: B9 87 14     LDA $1487,Y
C0/C914: 49 01        EOR #$01
C0/C916: 99 87 14     STA $1487,Y
C0/C919: 80 14        BRA $C92F

; object action $17
C0/C91B: C9 17        CMP #$17
C0/C91D: D0 0A        BNE $C929
C0/C91F: B9 87 14     LDA $1487,Y
C0/C922: 49 02        EOR #$02
C0/C924: 99 87 14     STA $1487,Y
C0/C927: 80 06        BRA $C92F

; object action $20+: change graphic frame
C0/C929: 38           SEC 
C0/C92A: E9 20        SBC #$20
C0/C92C: 99 7C 14     STA $147C,Y
C0/C92F: 4C 30 A6     JMP $A630       ; 2-byte command

; [ event command $05-$6F: party action ]

C0/C932: C9 10        CMP #$10
C0/C934: B0 38        BCS $C96E

; $05: jump 1 tile
C0/C936: C9 05        CMP #$05
C0/C938: D0 06        BNE $C940
C0/C93A: A9 20        LDA #$20
C0/C93C: 85 BE        STA $BE
C0/C93E: 80 47        BRA $C987

; $06: jump 2 tiles
C0/C940: C9 06        CMP #$06
C0/C942: D0 06        BNE $C94A
C0/C944: A9 C0        LDA #$C0
C0/C946: 85 BE        STA $BE
C0/C948: 80 3D        BRA $C987

; $09: show party sprite
C0/C94A: C9 09        CMP #$09
C0/C94C: D0 06        BNE $C954
C0/C94E: A9 01        LDA #$01
C0/C950: 85 BD        STA $BD
C0/C952: 80 33        BRA $C987

; $0A: hide party sprite
C0/C954: C9 0A        CMP #$0A
C0/C956: D0 04        BNE $C95C
C0/C958: 64 BD        STZ $BD
C0/C95A: 80 2B        BRA $C987

; $0B: enable party walking animation
C0/C95C: C9 0B        CMP #$0B
C0/C95E: D0 06        BNE $C966
C0/C960: A9 01        LDA #$01
C0/C962: 85 BC        STA $BC
C0/C964: 80 21        BRA $C987

; $0C: disable party walking animation
C0/C966: C9 0C        CMP #$0C
C0/C968: D0 1D        BNE $C987
C0/C96A: 64 BC        STZ $BC
C0/C96C: 80 19        BRA $C987

; $10-$6F: graphic action
C0/C96E: 38           SEC 
C0/C96F: E9 10        SBC #$10
C0/C971: 85 BB        STA $BB
C0/C973: C9 08        CMP #$08
C0/C975: B0 04        BCS $C97B
C0/C977: 4A           LSR 
C0/C978: 8D DB 0A     STA $0ADB       ; facing direction
C0/C97B: A5 53        LDA $53
C0/C97D: D0 05        BNE $C984       ; branch if a world map ???
C0/C97F: 20 37 21     JSR $2137
C0/C982: 80 03        BRA $C987
C0/C984: 20 7C 23     JSR $237C       ; update party sprite
C0/C987: 4C 28 A6     JMP $A628       ; 1-byte command

; [ init camera movement ]

C0/C98A: 0A           ASL 
C0/C98B: AA           TAX 
C0/C98C: BF 9B C9 C0  LDA $C0C99B,X
C0/C990: 85 3B        STA $3B
C0/C992: BF 9C C9 C0  LDA $C0C99C,X
C0/C996: 8F 3C 0B 00  STA $000B3C
C0/C99A: 60           RTS 

C0/C99B: 00 00        BRK $00
C0/C99D: 00 08        BRK $08
C0/C99F: 00 01        BRK $01
C0/C9A1: 00 04        BRK $04
C0/C9A3: 00 02        BRK $02

; [ give spell ]

; A = spell index

C0/C9A5: 48           PHA 
C0/C9A6: 4A           LSR 
C0/C9A7: 4A           LSR 
C0/C9A8: 4A           LSR 
C0/C9A9: A8           TAY 
C0/C9AA: 68           PLA 
C0/C9AB: 29 07        AND #$07
C0/C9AD: AA           TAX 
C0/C9AE: B9 50 09     LDA $0950,Y
C0/C9B1: 1F B9 C9 C0  ORA $C0C9B9,X
C0/C9B5: 99 50 09     STA $0950,Y
C0/C9B8: 60           RTS 

; bit masks for spells
C0/C9B9:              .DW $80, $40, $20, $10, $08, $04, $02, $01

; [ get npc flag ]

C0/C9C1: DA           PHX 
C0/C9C2: 20 49 CA     JSR $CA49       ; get flag index
C0/C9C5: B9 54 0A     LDA $0A54,Y
C0/C9C8: 3F 59 CA C0  AND $C0CA59,X
C0/C9CC: FA           PLX 
C0/C9CD: 60           RTS 

; [ event command $CA: set npc flag ]

C0/C9CE: C2 20        REP #$20
C0/C9D0: A5 DF        LDA $DF
C0/C9D2: E2 20        SEP #$20
C0/C9D4: 20 49 CA     JSR $CA49       ; get flag index
C0/C9D7: B9 54 0A     LDA $0A54,Y
C0/C9DA: 1F 59 CA C0  ORA $C0CA59,X
C0/C9DE: 99 54 0A     STA $0A54,Y
C0/C9E1: 4C 38 A6     JMP $A638       ; 3-byte command

; [ event command $CB: clear npc flag ]

C0/C9E4: C2 20        REP #$20
C0/C9E6: A5 DF        LDA $DF
C0/C9E8: E2 20        SEP #$20
C0/C9EA: 20 49 CA     JSR $CA49       ; get flag index
C0/C9ED: B9 54 0A     LDA $0A54,Y
C0/C9F0: 3F 61 CA C0  AND $C0CA61,X
C0/C9F4: 99 54 0A     STA $0A54,Y
C0/C9F7: 4C 38 A6     JMP $A638       ; 3-byte command

; [ set battle flag ]

C0/C9FA: 20 49 CA     JSR $CA49       ; get flag index
C0/C9FD: B9 B4 09     LDA $09B4,Y
C0/CA00: 1F 59 CA C0  ORA $C0CA59,X
C0/CA04: 99 B4 09     STA $09B4,Y
C0/CA07: 60           RTS 

; [ clear battle flag ]

C0/CA08: 20 49 CA     JSR $CA49       ; get flag index
C0/CA0B: B9 B4 09     LDA $09B4,Y
C0/CA0E: 3F 61 CA C0  AND $C0CA61,X
C0/CA12: 99 B4 09     STA $09B4,Y
C0/CA15: 60           RTS 

; [ get treasure flag ]

C0/CA16: 20 49 CA     JSR $CA49       ; get flag index
C0/CA19: B9 D4 09     LDA $09D4,Y
C0/CA1C: 3F 59 CA C0  AND $C0CA59,X
C0/CA20: 60           RTS 

; [ set treasure flag ]

C0/CA21: 20 49 CA     JSR $CA49       ; get flag index
C0/CA24: B9 D4 09     LDA $09D4,Y
C0/CA27: 1F 59 CA C0  ORA $C0CA59,X
C0/CA2B: 99 D4 09     STA $09D4,Y
C0/CA2E: 60           RTS 

; [ get event flag $00xx ]

C0/CA2F: DA           PHX 
C0/CA30: 20 49 CA     JSR $CA49       ; get flag index
C0/CA33: B9 14 0A     LDA $0A14,Y
C0/CA36: 3F 59 CA C0  AND $C0CA59,X
C0/CA3A: FA           PLX 
C0/CA3B: 60           RTS 

; [ get event flag $01xx ]

C0/CA3C: DA           PHX 
C0/CA3D: 20 49 CA     JSR $CA49       ; get flag index
C0/CA40: B9 34 0A     LDA $0A34,Y
C0/CA43: 3F 59 CA C0  AND $C0CA59,X
C0/CA47: FA           PLX 
C0/CA48: 60           RTS 

; [ get flag index ]

C0/CA49: C2 20        REP #$20
C0/CA4B: AA           TAX 
C0/CA4C: 4A           LSR 
C0/CA4D: 4A           LSR 
C0/CA4E: 4A           LSR 
C0/CA4F: A8           TAY 
C0/CA50: A5 06        LDA $06
C0/CA52: E2 20        SEP #$20
C0/CA54: 8A           TXA 
C0/CA55: 29 07        AND #$07
C0/CA57: AA           TAX 
C0/CA58: 60           RTS 

; flag masks
C0/CA59: 01 02 04 08 10 20 40 80
C0/CA61: FE FD FB F7 EF DF BF 7F

; [ check random battles (normal map) ]

C0/CA69: A5 5A        LDA $5A
C0/CA6B: D0 0E        BNE $CA7B
C0/CA6D: A5 56        LDA $56
C0/CA6F: F0 0A        BEQ $CA7B       ; branch if party didn't take a step
C0/CA71: A5 C9        LDA $C9
C0/CA73: A8           TAY 
C0/CA74: B9 12 11     LDA $1112,Y
C0/CA77: 29 80        AND #$80
C0/CA79: D0 01        BNE $CA7C       ; branch if random battles are enabled
C0/CA7B: 60           RTS 
C0/CA7C: 64 56        STZ $56         ; reset step counter
C0/CA7E: AE A5 16     LDX $16A5       ; increment random battle counter
C0/CA81: E8           INX 
C0/CA82: 8E A5 16     STX $16A5
C0/CA85: AD 24 11     LDA $1124       ; battle background
C0/CA88: 8D F2 04     STA $04F2
C0/CA8B: C2 20        REP #$20
C0/CA8D: AD D6 0A     LDA $0AD6       ; map index
C0/CA90: 29 03 00     AND #$0003
C0/CA93: A8           TAY 
C0/CA94: AD D6 0A     LDA $0AD6
C0/CA97: 4A           LSR 
C0/CA98: 4A           LSR 
C0/CA99: AA           TAX 
C0/CA9A: A5 06        LDA $06
C0/CA9C: E2 20        SEP #$20
C0/CA9E: BF C0 84 D0  LDA $D084C0,X   ; battle probability (2 bits per map)
C0/CAA2: C0 00 00     CPY #$0000
C0/CAA5: F0 05        BEQ $CAAC
C0/CAA7: 4A           LSR 
C0/CAA8: 4A           LSR 
C0/CAA9: 88           DEY 
C0/CAAA: D0 FB        BNE $CAA7
C0/CAAC: 29 03        AND #$03
C0/CAAE: 0A           ASL 
C0/CAAF: AA           TAX 
C0/CAB0: C2 20        REP #$20
C0/CAB2: AD A8 16     LDA $16A8       ; random battle counter
C0/CAB5: 18           CLC 
C0/CAB6: 7F 09 CB C0  ADC $C0CB09,X   ; add probability value
C0/CABA: 90 03        BCC $CABF
C0/CABC: A9 00 FF     LDA #$FF00      ; max $FF00
C0/CABF: 8D A8 16     STA $16A8
C0/CAC2: A5 06        LDA $06
C0/CAC4: E2 20        SEP #$20
C0/CAC6: 20 52 CC     JSR $CC52       ; update random number for random battles
C0/CAC9: CD A9 16     CMP $16A9
C0/CACC: B0 3A        BCS $CB08       ; branch if no battle
C0/CACE: C2 20        REP #$20
C0/CAD0: AD D4 0A     LDA $0AD4       ; map index
C0/CAD3: 0A           ASL 
C0/CAD4: AA           TAX 
C0/CAD5: BF 00 80 D0  LDA $D08000,X   ; map battle group
C0/CAD9: 0A           ASL 
C0/CADA: 0A           ASL 
C0/CADB: 0A           ASL 
C0/CADC: AA           TAX 
C0/CADD: A5 06        LDA $06
C0/CADF: E2 20        SEP #$20
C0/CAE1: 20 6D CC     JSR $CC6D       ; update random number for battle group
C0/CAE4: C9 5A        CMP #$5A
C0/CAE6: 90 0E        BCC $CAF6
C0/CAE8: E8           INX 
C0/CAE9: E8           INX 
C0/CAEA: C9 B4        CMP #$B4
C0/CAEC: 90 08        BCC $CAF6
C0/CAEE: E8           INX 
C0/CAEF: E8           INX 
C0/CAF0: C9 F0        CMP #$F0
C0/CAF2: 90 02        BCC $CAF6
C0/CAF4: E8           INX 
C0/CAF5: E8           INX 
C0/CAF6: C2 20        REP #$20
C0/CAF8: BF 00 68 D0  LDA $D06800,X   ; battle index
C0/CAFC: 8D F0 04     STA $04F0
C0/CAFF: A5 06        LDA $06
C0/CB01: E2 20        SEP #$20
C0/CB03: E6 55        INC $55         ; random battle flag
C0/CB05: EE A4 16     INC $16A4       ; 
C0/CB08: 60           RTS 

; random battle probability values (normal, low, high, very high)
C0/CB09:              .DW $00E0, $0040, $0180, $0200

; [ check random battles (world map) ]

C0/CB11: A5 5A        LDA $5A
C0/CB13: D0 0D        BNE $CB22
C0/CB15: AD DC 0A     LDA $0ADC       ; current vehicle
C0/CB18: F0 0D        BEQ $CB27
C0/CB1A: C9 06        CMP #$06
C0/CB1C: D0 05        BNE $CB23
C0/CB1E: A5 6F        LDA $6F
C0/CB20: F0 05        BEQ $CB27
C0/CB22: 60           RTS 
C0/CB23: C9 05        CMP #$05
C0/CB25: D0 04        BNE $CB2B
C0/CB27: A5 56        LDA $56         ; step counter
C0/CB29: D0 01        BNE $CB2C
C0/CB2B: 60           RTS 
C0/CB2C: 64 56        STZ $56
C0/CB2E: C2 20        REP #$20
C0/CB30: AD C6 10     LDA $10C6       ; current bg1 tile
C0/CB33: 0A           ASL 
C0/CB34: 18           CLC 
C0/CB35: 6D C6 10     ADC $10C6
C0/CB38: AA           TAX 
C0/CB39: A5 06        LDA $06
C0/CB3B: E2 20        SEP #$20
C0/CB3D: AD D6 0A     LDA $0AD6       ; map index
C0/CB40: 29 01        AND #$01
C0/CB42: 0A           ASL 
C0/CB43: 0A           ASL 
C0/CB44: 0A           ASL 
C0/CB45: 0A           ASL 
C0/CB46: 85 08        STA $08
C0/CB48: BD 88 11     LDA $1188,X     ; tile properties byte 3
C0/CB4B: 29 0F        AND #$0F
C0/CB4D: 05 08        ORA $08
C0/CB4F: AA           TAX 
C0/CB50: BF 21 CC C0  LDA $C0CC21,X   ; battle bg
C0/CB54: 8D F2 04     STA $04F2
C0/CB57: 8A           TXA 
C0/CB58: 29 0F        AND #$0F
C0/CB5A: AA           TAX 
C0/CB5B: AD DC 0A     LDA $0ADC
C0/CB5E: C9 05        CMP #$05
C0/CB60: 90 05        BCC $CB67
C0/CB62: A9 15        LDA #$15        ; battle bg $15 (ship exterior)
C0/CB64: 8D F2 04     STA $04F2
C0/CB67: BF 3A CC C0  LDA $C0CC3A,X   ; probability offset
C0/CB6B: 85 11        STA $11
C0/CB6D: 64 12        STZ $12
C0/CB6F: BF 42 CC C0  LDA $C0CC42,X   ; battle group offset
C0/CB73: 85 0F        STA $0F
C0/CB75: 64 10        STZ $10
C0/CB77: AD D6 0A     LDA $0AD6       ; map index
C0/CB7A: 0A           ASL 
C0/CB7B: 0A           ASL 
C0/CB7C: 0A           ASL 
C0/CB7D: 0A           ASL 
C0/CB7E: 0A           ASL 
C0/CB7F: 0A           ASL 
C0/CB80: 85 0D        STA $0D
C0/CB82: AD D9 0A     LDA $0AD9
C0/CB85: 4A           LSR 
C0/CB86: 4A           LSR 
C0/CB87: 29 38        AND #$38
C0/CB89: 18           CLC 
C0/CB8A: 65 0D        ADC $0D
C0/CB8C: 85 0D        STA $0D
C0/CB8E: AD D8 0A     LDA $0AD8
C0/CB91: 4A           LSR 
C0/CB92: 4A           LSR 
C0/CB93: 4A           LSR 
C0/CB94: 4A           LSR 
C0/CB95: 4A           LSR 
C0/CB96: 18           CLC 
C0/CB97: 65 0D        ADC $0D
C0/CB99: AA           TAX 
C0/CB9A: BF 00 84 D0  LDA $D08400,X   ; battle probability
C0/CB9E: A4 11        LDY $11
C0/CBA0: F0 05        BEQ $CBA7
C0/CBA2: 4A           LSR 
C0/CBA3: 4A           LSR 
C0/CBA4: 88           DEY 
C0/CBA5: D0 FB        BNE $CBA2
C0/CBA7: 29 03        AND #$03
C0/CBA9: C9 03        CMP #$03
C0/CBAB: F0 73        BEQ $CC20
C0/CBAD: 0A           ASL 
C0/CBAE: AA           TAX 
C0/CBAF: C2 20        REP #$20
C0/CBB1: AD A8 16     LDA $16A8
C0/CBB4: 18           CLC 
C0/CBB5: 7F 4A CC C0  ADC $C0CC4A,X
C0/CBB9: 90 03        BCC $CBBE
C0/CBBB: A9 00 FF     LDA #$FF00
C0/CBBE: 8D A8 16     STA $16A8
C0/CBC1: A5 06        LDA $06
C0/CBC3: E2 20        SEP #$20
C0/CBC5: 20 52 CC     JSR $CC52
C0/CBC8: CD A9 16     CMP $16A9
C0/CBCB: B0 53        BCS $CC20
C0/CBCD: AD D9 0A     LDA $0AD9
C0/CBD0: 29 E0        AND #$E0
C0/CBD2: C2 20        REP #$20
C0/CBD4: 0A           ASL 
C0/CBD5: 85 0D        STA $0D
C0/CBD7: AD D8 0A     LDA $0AD8
C0/CBDA: 4A           LSR 
C0/CBDB: 4A           LSR 
C0/CBDC: 29 38 00     AND #$0038
C0/CBDF: 18           CLC 
C0/CBE0: 65 0D        ADC $0D
C0/CBE2: 85 23        STA $23
C0/CBE4: AD D6 0A     LDA $0AD6       ; map index
C0/CBE7: EB           XBA 
C0/CBE8: 0A           ASL 
C0/CBE9: 18           CLC 
C0/CBEA: 65 23        ADC $23
C0/CBEC: 18           CLC 
C0/CBED: 65 0F        ADC $0F
C0/CBEF: AA           TAX 
C0/CBF0: BF 00 7A D0  LDA $D07A00,X   ; world map battle groups
C0/CBF4: 0A           ASL 
C0/CBF5: 0A           ASL 
C0/CBF6: 0A           ASL 
C0/CBF7: AA           TAX 
C0/CBF8: A5 06        LDA $06
C0/CBFA: E2 20        SEP #$20
C0/CBFC: 20 6D CC     JSR $CC6D
C0/CBFF: C9 5A        CMP #$5A
C0/CC01: 90 0E        BCC $CC11
C0/CC03: E8           INX 
C0/CC04: E8           INX 
C0/CC05: C9 B4        CMP #$B4
C0/CC07: 90 08        BCC $CC11
C0/CC09: E8           INX 
C0/CC0A: E8           INX 
C0/CC0B: C9 F0        CMP #$F0
C0/CC0D: 90 02        BCC $CC11
C0/CC0F: E8           INX 
C0/CC10: E8           INX 
C0/CC11: C2 20        REP #$20
C0/CC13: BF 00 68 D0  LDA $D06800,X   ; battle index
C0/CC17: 8D F0 04     STA $04F0
C0/CC1A: A5 06        LDA $06
C0/CC1C: E2 20        SEP #$20
C0/CC1E: E6 55        INC $55
C0/CC20: 60           RTS 

; battle bg for world 1 and 3
C0/CC21: 00 01 02 03 04 05 03 07 08 00 00 00 00 00 00 00

; battle bg for world 2
C0/CC31: 21 01 02 03 04 05 03 07 08

; probability offset
C0/CC3A: 03 02 01 00 03 02 01 00

; battle group offset
C0/CC42: 00 02 04 06
C0/CC46: 00 02 04 06

C0/CC4A: 0100 0010 0180 0000

; [ update random number for random battles ]

C0/CC52: DA           PHX 
C0/CC53: E6 4F        INC $4F
C0/CC55: D0 09        BNE $CC60
C0/CC57: AD 60 0B     LDA $0B60
C0/CC5A: 18           CLC 
C0/CC5B: 69 11        ADC #$11
C0/CC5D: 8D 60 0B     STA $0B60
C0/CC60: A5 4F        LDA $4F
C0/CC62: AA           TAX 
C0/CC63: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C0/CC67: 18           CLC 
C0/CC68: 6D 60 0B     ADC $0B60
C0/CC6B: FA           PLX 
C0/CC6C: 60           RTS 

; [  ]

C0/CC6D: DA           PHX 
C0/CC6E: E6 50        INC $50
C0/CC70: D0 09        BNE $CC7B
C0/CC72: AD 5F 0B     LDA $0B5F
C0/CC75: 18           CLC 
C0/CC76: 69 17        ADC #$17
C0/CC78: 8D 5F 0B     STA $0B5F
C0/CC7B: A5 50        LDA $50
C0/CC7D: AA           TAX 
C0/CC7E: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C0/CC82: 18           CLC 
C0/CC83: 6D 5F 0B     ADC $0B5F
C0/CC86: FA           PLX 
C0/CC87: 60           RTS 

; [ battle blur (normal map) ]

C0/CC88: 64 3F        STZ $3F
C0/CC8A: 20 41 4E     JSR $4E41       ; wait for vblank
C0/CC8D: A5 3F        LDA $3F
C0/CC8F: C9 10        CMP #$10
C0/CC91: B0 04        BCS $CC97
C0/CC93: 29 07        AND #$07
C0/CC95: 80 02        BRA $CC99
C0/CC97: 29 0F        AND #$0F
C0/CC99: 0A           ASL 
C0/CC9A: 0A           ASL 
C0/CC9B: 0A           ASL 
C0/CC9C: 0A           ASL 
C0/CC9D: 09 0F        ORA #$0F
C0/CC9F: 8D 06 21     STA $2106
C0/CCA2: A5 3F        LDA $3F
C0/CCA4: C9 20        CMP #$20
C0/CCA6: D0 E2        BNE $CC8A
C0/CCA8: 60           RTS 

; [ battle blur (world map) ]

C0/CCA9: 9C 0B 42     STZ $420B
C0/CCAC: 9C 0C 42     STZ $420C
C0/CCAF: 64 3F        STZ $3F
C0/CCB1: 20 41 4E     JSR $4E41       ; wait for vblank
C0/CCB4: A5 3F        LDA $3F
C0/CCB6: 29 3F        AND #$3F
C0/CCB8: 0A           ASL 
C0/CCB9: AA           TAX 
C0/CCBA: BF 4A CD C0  LDA $C0CD4A,X
C0/CCBE: 8D 1B 21     STA $211B
C0/CCC1: BF 4B CD C0  LDA $C0CD4B,X
C0/CCC5: 8D 1B 21     STA $211B
C0/CCC8: BF 4A CD C0  LDA $C0CD4A,X
C0/CCCC: 8D 1E 21     STA $211E
C0/CCCF: BF 4B CD C0  LDA $C0CD4B,X
C0/CCD3: 8D 1E 21     STA $211E
C0/CCD6: A5 3F        LDA $3F
C0/CCD8: C9 20        CMP #$20
C0/CCDA: D0 D5        BNE $CCB1
C0/CCDC: 60           RTS 

; [ battle blur ]

C0/CCDD: A9 01        LDA #$01
C0/CCDF: 85 52        STA $52
C0/CCE1: A5 53        LDA $53
C0/CCE3: D0 05        BNE $CCEA
C0/CCE5: 20 A9 CC     JSR $CCA9
C0/CCE8: 80 03        BRA $CCED
C0/CCEA: 20 88 CC     JSR $CC88
C0/CCED: 64 52        STZ $52
C0/CCEF: 60           RTS 

; [ random battle ]

C0/CCF0: A6 06        LDX $06
C0/CCF2: 8E A8 16     STX $16A8       ; reset random number for battle
C0/CCF5: A9 6F        LDA #$6F
C0/CCF7: 20 3C 46     JSR $463C       ; play sound effect
C0/CCFA: 20 DD CC     JSR $CCDD       ; battle blur
C0/CCFD: 9C 0B 42     STZ $420B
C0/CD00: 9C 0C 42     STZ $420C
C0/CD03: A9 00        LDA #$00
C0/CD05: 8D 00 42     STA $4200
C0/CD08: A9 80        LDA #$80
C0/CD0A: 8D 00 21     STA $2100
C0/CD0D: 78           SEI 
C0/CD0E: 22 00 00 C2  JSL $C20000     ; battle
C0/CD12: 20 E3 44     JSR $44E3       ; init map bank
C0/CD15: AD C4 09     LDA $09C4
C0/CD18: 29 01        AND #$01
C0/CD1A: F0 08        BEQ $CD24
C0/CD1C: A9 F0        LDA #$F0        ; don't reset spc
C0/CD1E: 8D 00 1D     STA $1D00
C0/CD21: 4C 00 00     JMP $0000       ; reset
C0/CD24: AD 3B 01     LDA $013B
C0/CD27: 0D 3C 01     ORA $013C
C0/CD2A: 0D 3D 01     ORA $013D
C0/CD2D: 0D 3E 01     ORA $013E
C0/CD30: 0D 3F 01     ORA $013F
C0/CD33: 0D 40 01     ORA $0140
C0/CD36: 0D 41 01     ORA $0141
C0/CD39: 0D 42 01     ORA $0142
C0/CD3C: F0 08        BEQ $CD46
C0/CD3E: A9 01        LDA #$01        ; menu command $01 (collect items after battle)
C0/CD40: 8D 34 01     STA $0134
C0/CD43: 20 4F 45     JSR $454F       ; open menu
C0/CD46: 20 D7 1C     JSR $1CD7       ; update showing character
C0/CD49: 60           RTS 

; zoom values for world map battle blur
C0/CD4A:              .DW $02B0, $01D5, $0143, $00E2, $00A1, $0076, $0059, $0046
C0/CD5A:              .DW $0039, $0046, $0059, $0076, $00A1, $00E2, $0143, $01D5
C0/CD6A:              .DW $02B0, $01D5, $0143, $00E2, $00A1, $0076, $0059, $0046
C0/CD7A:              .DW $0039, $0031, $002B, $0027, $0025, $0023, $0022, $0021

; reset
C0/CEC0: 78           SEI 
C0/CEC1: 18           CLC 
C0/CEC2: FB           XCE 
C0/CEC3: 5C 00 00 C0  JML $C00000

C0/CEE0: 5C 00 1F 00  JML $001F00     ; nmi
C0/CEE4: 5C 04 1F 00  JML $001F04     ; irq

C0/FFC0:              .DB "FINAL FANTASY 5      "
C0/FFD5:              .DB $21, $02, $0B, $03, $00, $C3, $00, $0D, $E0, $F2, $1F

C0/FFEA:              .DW $CEE0       ; nmi vector
C0/FFEE:              .DW $CEE4       ; irq vector
C0/FFFC:              .DW $CEC0       ; reset vector

; =============================[ battle graphics ]==============================

C1/0000: 4C 0C 00     JMP $000C       ; execute battle graphics function
C1/0003: 4C 5F F7     JMP $F75F       ; epilogue cutscene
C1/0006: 4C 99 E9     JMP $E999       ; show game stats (unknown cave psychic)
C1/0009: 4C 3F 00     JMP $003F       ; swap character saved cursor positions

; [ execute battle graphics function ]

C1/000C: 0A           ASL 
C1/000D: AA           TAX 
C1/000E: BF 21 00 C1  LDA $C10021,X
C1/0012: 85 7A        STA $7A
C1/0014: BF 22 00 C1  LDA $C10022,X
C1/0018: 85 7B        STA $7B
C1/001A: 20 1E 00     JSR $001E
C1/001D: 6B           RTL 
C1/001E: 6C 7A 00     JMP ($007A)

C1/0021:              .DW $39F9, $3A55, $0348, $02E0, $02DF, $422B, $01E4, $768D
C1/0031:              .DW $75D7, $0208, $8189, $010B, $00F2, $00C6, $0092

; [ swap character saved cursor positions ]

; called from menu

C1/003F: DA           PHX 
C1/0040: 5A           PHY 
C1/0041: 8B           PHB 
C1/0042: A9 00        LDA #$00
C1/0044: 48           PHA 
C1/0045: AB           PLB 
C1/0046: A9 00        LDA #$00
C1/0048: EB           XBA 
C1/0049: A9 2D        LDA #$2D
C1/004B: 8F 70 00 00  STA $000070
C1/004F: AD 00 00     LDA $0000
C1/0052: AA           TAX 
C1/0053: AD 01 00     LDA $0001
C1/0056: A8           TAY 
C1/0057: BD 2D 04     LDA $042D,X
C1/005A: 48           PHA 
C1/005B: B9 2D 04     LDA $042D,Y
C1/005E: 9D 2D 04     STA $042D,X
C1/0061: 68           PLA 
C1/0062: 99 2D 04     STA $042D,Y
C1/0065: E8           INX 
C1/0066: E8           INX 
C1/0067: E8           INX 
C1/0068: E8           INX 
C1/0069: C8           INY 
C1/006A: C8           INY 
C1/006B: C8           INY 
C1/006C: C8           INY 
C1/006D: AF 70 00 00  LDA $000070
C1/0071: 3A           DEC 
C1/0072: 8F 70 00 00  STA $000070
C1/0076: D0 D7        BNE $004F
C1/0078: AD 00 00     LDA $0000
C1/007B: AA           TAX 
C1/007C: AD 01 00     LDA $0001
C1/007F: A8           TAY 
C1/0080: BD 20 04     LDA $0420,X
C1/0083: 48           PHA 
C1/0084: B9 20 04     LDA $0420,Y
C1/0087: 9D 20 04     STA $0420,X
C1/008A: 68           PLA 
C1/008B: 99 20 04     STA $0420,Y
C1/008E: AB           PLB 
C1/008F: 7A           PLY 
C1/0090: FA           PLX 
C1/0091: 6B           RTL 

; [ battle graphics function $0E: fade out ]

C1/0092: 20 1C 08     JSR $081C       ; update saved cursor checksums
C1/0095: AD C4 09     LDA $09C4
C1/0098: 29 01        AND #$01
C1/009A: D0 0B        BNE $00A7       ; branch if defeated
C1/009C: AE F0 04     LDX $04F0
C1/009F: E0 EF 01     CPX #$01EF
C1/00A2: D0 03        BNE $00A7       ; branch if battle $01EF
C1/00A4: 20 EC 73     JSR $73EC       ; 
C1/00A7: 20 F2 02     JSR $02F2       ; wait one frame
C1/00AA: 20 F2 02     JSR $02F2       ; wait one frame
C1/00AD: AD 7F BC     LDA $BC7F
C1/00B0: 29 0F        AND #$0F
C1/00B2: F0 05        BEQ $00B9
C1/00B4: CE 7F BC     DEC $BC7F       ; decrement screen brightness
C1/00B7: 80 EE        BRA $00A7
C1/00B9: A9 FC        LDA #$FC        ; disable reflect sound effect r/l
C1/00BB: 8D 00 1D     STA $1D00
C1/00BE: 9C 01 1D     STZ $1D01
C1/00C1: 22 04 00 C4  JSL $C40004
C1/00C5: 60           RTS 

; [ battle graphics function $0D:  ]

C1/00C6: EE BB DB     INC $DBBB
C1/00C9: 7B           TDC 
C1/00CA: AA           TAX 
C1/00CB: 8A           TXA 
C1/00CC: 0A           ASL 
C1/00CD: 0A           ASL 
C1/00CE: A8           TAY 
C1/00CF: B9 7E 7B     LDA $7B7E,Y
C1/00D2: 29 C0        AND #$C0
C1/00D4: D0 12        BNE $00E8
C1/00D6: 98           TYA 
C1/00D7: 0A           ASL 
C1/00D8: 0A           ASL 
C1/00D9: 0A           ASL 
C1/00DA: A8           TAY 
C1/00DB: A9 06        LDA #$06
C1/00DD: 99 4D CF     STA $CF4D,Y
C1/00E0: 99 58 CF     STA $CF58,Y
C1/00E3: A9 0F        LDA #$0F
C1/00E5: 99 4F CF     STA $CF4F,Y
C1/00E8: FE CB D1     INC $D1CB,X
C1/00EB: E8           INX 
C1/00EC: E0 04 00     CPX #$0004
C1/00EF: D0 DA        BNE $00CB
C1/00F1: 60           RTS 

; [ battle graphics function $0C:  ]

C1/00F2: A2 CC 3B     LDX #$3BCC      ; attack parameters
C1/00F5: 86 EB        STX $EB
C1/00F7: A2 4C 38     LDX #$384C      ; battle graphics script
C1/00FA: 86 E7        STX $E7
C1/00FC: A9 01        LDA #$01
C1/00FE: 8D CF 3B     STA $3BCF
C1/0101: A0 03 00     LDY #$0003
C1/0104: A9 09        LDA #$09
C1/0106: 91 E7        STA ($E7),Y
C1/0108: 4C 9E 97     JMP $979E

; [ battle graphics function $0B:  ]

C1/010B: 7B           TDC 
C1/010C: A8           TAY 
C1/010D: B9 AA D0     LDA $D0AA,Y
C1/0110: 20 74 FC     JSR $FC74
C1/0113: 25 DE        AND $DE
C1/0115: D0 06        BNE $011D
C1/0117: C8           INY 
C1/0118: C0 08 00     CPY #$0008
C1/011B: D0 F0        BNE $010D
C1/011D: B9 AA D0     LDA $D0AA,Y
C1/0120: A8           TAY 
C1/0121: B9 0E D0     LDA $D00E,Y
C1/0124: 85 72        STA $72
C1/0126: 64 70        STZ $70
C1/0128: 7B           TDC 
C1/0129: A8           TAY 
C1/012A: 98           TYA 
C1/012B: 20 74 FC     JSR $FC74
C1/012E: 85 74        STA $74
C1/0130: 25 DE        AND $DE
C1/0132: F0 11        BEQ $0145
C1/0134: B9 0E D0     LDA $D00E,Y
C1/0137: 18           CLC 
C1/0138: 79 FE CF     ADC $CFFE,Y
C1/013B: C5 72        CMP $72
C1/013D: 90 06        BCC $0145
C1/013F: A5 74        LDA $74
C1/0141: 05 70        ORA $70
C1/0143: 85 70        STA $70
C1/0145: C8           INY 
C1/0146: C0 08 00     CPY #$0008
C1/0149: D0 DF        BNE $012A
C1/014B: 60           RTS 

; [  ]

C1/014C: DA           PHX 
C1/014D: 9C 16 D1     STZ $D116
C1/0150: 9C 17 D1     STZ $D117
C1/0153: 20 F6 01     JSR $01F6
C1/0156: FA           PLX 
C1/0157: 60           RTS 

; [  ]

C1/0158: A6 E9        LDX $E9
C1/015A: DA           PHX 
C1/015B: 20 6C 01     JSR $016C
C1/015E: FA           PLX 
C1/015F: C2 20        REP #$20
C1/0161: 8A           TXA 
C1/0162: 18           CLC 
C1/0163: 69 18 00     ADC #$0018
C1/0166: 85 E9        STA $E9
C1/0168: 7B           TDC 
C1/0169: E2 20        SEP #$20
C1/016B: 60           RTS 

; [  ]

C1/016C: 7B           TDC 
C1/016D: AA           TAX 
C1/016E: A0 01 00     LDY #$0001
C1/0171: B1 E9        LDA ($E9),Y
C1/0173: C9 FF        CMP #$FF
C1/0175: D0 0D        BNE $0184
C1/0177: A4 E9        LDY $E9
C1/0179: C8           INY 
C1/017A: C8           INY 
C1/017B: 84 E9        STY $E9
C1/017D: E8           INX 
C1/017E: E0 0C 00     CPX #$000C
C1/0181: D0 EB        BNE $016E
C1/0183: 60           RTS 
C1/0184: B1 E9        LDA ($E9),Y
C1/0186: 30 04        BMI $018C
C1/0188: A9 31        LDA #$31
C1/018A: 80 02        BRA $018E
C1/018C: A9 35        LDA #$35
C1/018E: 8D 24 D1     STA $D124
C1/0191: B1 E9        LDA ($E9),Y
C1/0193: 29 40        AND #$40
C1/0195: F0 17        BEQ $01AE
C1/0197: A9 C4        LDA #$C4
C1/0199: 8D 32 D1     STA $D132
C1/019C: 1A           INC 
C1/019D: 8D 33 D1     STA $D133
C1/01A0: A9 FF        LDA #$FF
C1/01A2: 8D 30 D1     STA $D130
C1/01A5: 8D 31 D1     STA $D131
C1/01A8: A9 80        LDA #$80
C1/01AA: 85 72        STA $72
C1/01AC: 80 0A        BRA $01B8
C1/01AE: DA           PHX 
C1/01AF: A2 00 00     LDX #$0000
C1/01B2: 20 AB 02     JSR $02AB
C1/01B5: FA           PLX 
C1/01B6: 64 72        STZ $72
C1/01B8: DA           PHX 
C1/01B9: A2 00 00     LDX #$0000
C1/01BC: 20 76 02     JSR $0276
C1/01BF: FA           PLX 
C1/01C0: BD 66 D0     LDA $D066,X
C1/01C3: 45 F6        EOR $F6
C1/01C5: 38           SEC 
C1/01C6: E5 70        SBC $70
C1/01C8: 8D 60 D1     STA $D160
C1/01CB: BD 72 D0     LDA $D072,X
C1/01CE: 38           SEC 
C1/01CF: E9 08        SBC #$08
C1/01D1: 8D 6C D1     STA $D16C
C1/01D4: A9 01        LDA #$01
C1/01D6: 05 72        ORA $72
C1/01D8: 8D 18 D1     STA $D118
C1/01DB: 9C 78 D1     STZ $D178
C1/01DE: A9 01        LDA #$01
C1/01E0: 8D 16 D1     STA $D116
C1/01E3: 60           RTS 

; [ battle graphics function $06:  ]

C1/01E4: AD 3A CD     LDA $CD3A
C1/01E7: C9 0B        CMP #$0B
C1/01E9: D0 0A        BNE $01F5
C1/01EB: A5 CF        LDA $CF
C1/01ED: D0 03        BNE $01F2
C1/01EF: 4C C7 3C     JMP $3CC7
C1/01F2: 4C CA 3C     JMP $3CCA
C1/01F5: 60           RTS 

; [ load damage numerals palette ]

C1/01F6: A9 05        LDA #$05
C1/01F8: A0 40 01     LDY #$0140
C1/01FB: 4C 1D AA     JMP $AA1D       ; load attack palette (8-colors)

; [ show damage numerals (not poison/regen) ]

C1/01FE: AD 14 D1     LDA $D114       ; wait for previous damage numerals
C1/0201: F0 0A        BEQ $020D
C1/0203: 20 F2 02     JSR $02F2       ; wait one frame
C1/0206: 80 F6        BRA $01FE

; [ battle graphics function $09: show damage numerals (poison/regen) ]

C1/0208: A2 4C 3A     LDX #$3A4C
C1/020B: 86 E9        STX $E9
; fallthrough

; [ show damage numerals ]

C1/020D: 9C 14 D1     STZ $D114
C1/0210: 20 F6 01     JSR $01F6       ; load damage numerals palette
C1/0213: 7B           TDC 
C1/0214: AA           TAX 
C1/0215: A0 01 00     LDY #$0001
C1/0218: B1 E9        LDA ($E9),Y     ; damage value
C1/021A: C9 FF        CMP #$FF
C1/021C: F0 42        BEQ $0260       ; branch if no damage for this object
C1/021E: B1 E9        LDA ($E9),Y
C1/0220: 30 04        BMI $0226
C1/0222: A9 31        LDA #$31
C1/0224: 80 02        BRA $0228
C1/0226: A9 35        LDA #$35
C1/0228: 9D 24 D1     STA $D124,X
C1/022B: B1 E9        LDA ($E9),Y
C1/022D: 29 40        AND #$40
C1/022F: F0 09        BEQ $023A
C1/0231: 20 93 02     JSR $0293
C1/0234: A9 80        LDA #$80        ; numerals move in unison
C1/0236: 85 72        STA $72
C1/0238: 80 05        BRA $023F
C1/023A: 20 AB 02     JSR $02AB
C1/023D: 64 72        STZ $72
C1/023F: 20 76 02     JSR $0276       ; get x offset
C1/0242: BD 66 D0     LDA $D066,X     ; object x position
C1/0245: 45 F6        EOR $F6
C1/0247: 38           SEC 
C1/0248: E5 70        SBC $70         ; subtract x offset
C1/024A: 9D 60 D1     STA $D160,X     ; x position
C1/024D: BD 72 D0     LDA $D072,X     ; object y position
C1/0250: 38           SEC 
C1/0251: E9 08        SBC #$08
C1/0253: 9D 6C D1     STA $D16C,X     ; y position
C1/0256: A9 01        LDA #$01        ; enable damage numerals
C1/0258: 05 72        ORA $72
C1/025A: 9D 18 D1     STA $D118,X
C1/025D: 9E 78 D1     STZ $D178,X     ; clear frame counter
C1/0260: A4 E9        LDY $E9         ; next object
C1/0262: C8           INY 
C1/0263: C8           INY 
C1/0264: 84 E9        STY $E9
C1/0266: E8           INX 
C1/0267: E0 0C 00     CPX #$000C
C1/026A: D0 A9        BNE $0215
C1/026C: A9 01        LDA #$01
C1/026E: 8D 14 D1     STA $D114
C1/0271: 60           RTS 

; damage numerals x offsets (0, 1, 2, or 3 digits)
C1/0272:              .DB $10, $14, $18, $1C 

; [ get damage numerals x offset ]

C1/0276: DA           PHX 
C1/0277: 8A           TXA 
C1/0278: 0A           ASL 
C1/0279: 0A           ASL 
C1/027A: A8           TAY 
C1/027B: 7B           TDC 
C1/027C: AA           TAX 
C1/027D: B9 30 D1     LDA $D130,Y
C1/0280: C9 FF        CMP #$FF
C1/0282: D0 07        BNE $028B
C1/0284: C8           INY 
C1/0285: E8           INX 
C1/0286: E0 03 00     CPX #$0003
C1/0289: D0 F2        BNE $027D
C1/028B: BF 72 02 C1  LDA $C10272,X
C1/028F: 85 70        STA $70
C1/0291: FA           PLX 
C1/0292: 60           RTS 

C1/0293: DA           PHX 
C1/0294: 8A           TXA 
C1/0295: 0A           ASL 
C1/0296: 0A           ASL 
C1/0297: A8           TAY 
C1/0298: A9 C4        LDA #$C4
C1/029A: 99 32 D1     STA $D132,Y
C1/029D: 1A           INC 
C1/029E: 99 33 D1     STA $D133,Y
C1/02A1: A9 FF        LDA #$FF
C1/02A3: 99 30 D1     STA $D130,Y
C1/02A6: 99 31 D1     STA $D131,Y
C1/02A9: FA           PLX 
C1/02AA: 60           RTS 

; [  ]

C1/02AB: DA           PHX 
C1/02AC: A5 CE        LDA $CE
C1/02AE: 48           PHA 
C1/02AF: A9 C6        LDA #$C6
C1/02B1: 85 CE        STA $CE
C1/02B3: C2 20        REP #$20
C1/02B5: 7B           TDC 
C1/02B6: A8           TAY 
C1/02B7: B1 E9        LDA ($E9),Y
C1/02B9: 29 FF 3F     AND #$3FFF
C1/02BC: AA           TAX 
C1/02BD: 7B           TDC 
C1/02BE: E2 20        SEP #$20
C1/02C0: 20 2E FF     JSR $FF2E
C1/02C3: 20 12 FF     JSR $FF12
C1/02C6: 68           PLA 
C1/02C7: 85 CE        STA $CE
C1/02C9: FA           PLX 
C1/02CA: DA           PHX 
C1/02CB: 8A           TXA 
C1/02CC: 0A           ASL 
C1/02CD: 0A           ASL 
C1/02CE: A8           TAY 
C1/02CF: 7B           TDC 
C1/02D0: AA           TAX 
C1/02D1: B5 C4        LDA $C4,X
C1/02D3: 99 30 D1     STA $D130,Y
C1/02D6: C8           INY 
C1/02D7: E8           INX 
C1/02D8: E0 04 00     CPX #$0004
C1/02DB: D0 F4        BNE $02D1
C1/02DD: FA           PLX 
C1/02DE: 60           RTS 

; [ battle graphics function $04: no effect ]

C1/02DF: 60           RTS 

; [ battle graphics function $03: wait one frame ]

C1/02E0: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/02E3: 20 6E 3A     JSR $3A6E
C1/02E6: 20 F6 AE     JSR $AEF6
C1/02E9: 20 64 AD     JSR $AD64
C1/02EC: 20 2D AD     JSR $AD2D
C1/02EF: 4C EF 37     JMP $37EF

; [ wait one frame ]

C1/02F2: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/02F5: 20 6E 3A     JSR $3A6E
C1/02F8: 20 2D AD     JSR $AD2D
C1/02FB: 4C EF 37     JMP $37EF

; [  ]

C1/02FE: A5 DF        LDA $DF
C1/0300: 85 74        STA $74
C1/0302: 7B           TDC 
C1/0303: A8           TAY 
C1/0304: AA           TAX 
C1/0305: 06 74        ASL $74
C1/0307: 90 34        BCC $033D
C1/0309: B9 7E 7B     LDA $7B7E,Y
C1/030C: 29 C0        AND #$C0
C1/030E: D0 2D        BNE $033D
C1/0310: BD 4A DB     LDA $DB4A,X
C1/0313: F0 04        BEQ $0319
C1/0315: A9 20        LDA #$20
C1/0317: 80 02        BRA $031B
C1/0319: A9 30        LDA #$30
C1/031B: 85 70        STA $70
C1/031D: DA           PHX 
C1/031E: 8A           TXA 
C1/031F: 0A           ASL 
C1/0320: 0A           ASL 
C1/0321: 0A           ASL 
C1/0322: 0A           ASL 
C1/0323: 0A           ASL 
C1/0324: AA           TAX 
C1/0325: A5 70        LDA $70
C1/0327: 9D 54 CF     STA $CF54,X
C1/032A: A9 02        LDA #$02
C1/032C: 9D 4D CF     STA $CF4D,X
C1/032F: A9 01        LDA #$01
C1/0331: 9D 53 CF     STA $CF53,X
C1/0334: 9E 55 CF     STZ $CF55,X
C1/0337: A9 F8        LDA #$F8
C1/0339: 9D 45 CF     STA $CF45,X
C1/033C: FA           PLX 
C1/033D: E8           INX 
C1/033E: C8           INY 
C1/033F: C8           INY 
C1/0340: C8           INY 
C1/0341: C8           INY 
C1/0342: C0 10 00     CPY #$0010
C1/0345: D0 BE        BNE $0305
C1/0347: 60           RTS 

; [ battle graphics function $02: init battle graphics ]

C1/0348: C2 10        REP #$10
C1/034A: E2 20        SEP #$20
C1/034C: 20 88 08     JSR $0888       ; init hardware registers
C1/034F: 20 C9 04     JSR $04C9       ; init ram
C1/0352: 9C A1 F9     STZ $F9A1
C1/0355: A9 70        LDA #$70
C1/0357: 8D BD DB     STA $DBBD
C1/035A: 8D BE DB     STA $DBBE
C1/035D: A9 01        LDA #$01
C1/035F: 8D BC DB     STA $DBBC
C1/0362: AD EF 3E     LDA $3EEF
C1/0365: 29 0F        AND #$0F
C1/0367: C9 04        CMP #$04
C1/0369: D0 15        BNE $0380
C1/036B: A9 01        LDA #$01
C1/036D: 8D A1 F9     STA $F9A1
C1/0370: AD 84 BC     LDA $BC84
C1/0373: 09 01        ORA #$01
C1/0375: 8D 84 BC     STA $BC84
C1/0378: 20 6B 88     JSR $886B
C1/037B: A9 BF        LDA #$BF
C1/037D: 8D 86 BC     STA $BC86
C1/0380: A2 00 01     LDX #$0100
C1/0383: 8E 77 BC     STX $BC77
C1/0386: 8E 79 BC     STX $BC79
C1/0389: A9 1F        LDA #$1F
C1/038B: 8F 2C 21 00  STA $00212C
C1/038F: 8F 2E 21 00  STA $00212E
C1/0393: AF 10 42 00  LDA $004210
C1/0397: 10 FA        BPL $0393
C1/0399: 20 DC FC     JSR $FCDC
C1/039C: A9 81        LDA #$81
C1/039E: 8F 00 42 00  STA $004200
C1/03A2: 58           CLI 
C1/03A3: 4C 36 87     JMP $8736       ; do monster entry

; [ update song tempo multiplier ]

C1/03A6: AD 94 7C     LDA $7C94
C1/03A9: C9 02        CMP #$02
C1/03AB: D0 42        BNE $03EF
C1/03AD: A2 07 00     LDX #$0007
C1/03B0: C2 20        REP #$20
C1/03B2: AD 95 7C     LDA $7C95
C1/03B5: C9 2C 01     CMP #$012C      ; 300
C1/03B8: 90 25        BCC $03DF
C1/03BA: CA           DEX 
C1/03BB: C9 58 02     CMP #$0258      ; 600
C1/03BE: 90 1F        BCC $03DF
C1/03C0: CA           DEX 
C1/03C1: C9 B0 04     CMP #$04B0      ; 1200
C1/03C4: 90 19        BCC $03DF
C1/03C6: CA           DEX 
C1/03C7: C9 08 07     CMP #$0708      ; 1800
C1/03CA: 90 13        BCC $03DF
C1/03CC: CA           DEX 
C1/03CD: C9 60 09     CMP #$0960      ; 2400
C1/03D0: 90 0D        BCC $03DF
C1/03D2: CA           DEX 
C1/03D3: C9 B8 0B     CMP #$0BB8      ; 3000
C1/03D6: 90 07        BCC $03DF
C1/03D8: CA           DEX 
C1/03D9: C9 10 0E     CMP #$0E10      ; 3600
C1/03DC: 90 01        BCC $03DF
C1/03DE: CA           DEX 
C1/03DF: 7B           TDC 
C1/03E0: E2 20        SEP #$20
C1/03E2: 8A           TXA 
C1/03E3: 8D 01 1D     STA $1D01
C1/03E6: A9 87        LDA #$87        ; set tempo multiplier (song only)
C1/03E8: 8D 00 1D     STA $1D00
C1/03EB: 22 04 00 C4  JSL $C40004
C1/03EF: 60           RTS 

; [ update reflect sfx l/r ]

C1/03F0: A5 F6        LDA $F6
C1/03F2: F0 0C        BEQ $0400
C1/03F4: A9 FC        LDA #$FC        ; reflect sound l/r
C1/03F6: 8D 00 1D     STA $1D00
C1/03F9: 8D 01 1D     STA $1D01
C1/03FC: 22 04 00 C4  JSL $C40004
C1/0400: 60           RTS 

; [  ]

C1/0401: 7B           TDC 
C1/0402: AA           TAX 
C1/0403: C2 20        REP #$20
C1/0405: A9 00 08     LDA #$0800
C1/0408: 85 70        STA $70
C1/040A: A5 70        LDA $70
C1/040C: 9D 09 A0     STA $A009,X
C1/040F: 9D 09 A2     STA $A209,X
C1/0412: 9D 0B A0     STA $A00B,X
C1/0415: 9D 0B A2     STA $A20B,X
C1/0418: 38           SEC 
C1/0419: E9 40 00     SBC #$0040
C1/041C: 85 70        STA $70
C1/041E: 8A           TXA 
C1/041F: 29 07 00     AND #$0007
C1/0422: D0 1E        BNE $0442
C1/0424: A5 70        LDA $70
C1/0426: 10 0E        BPL $0436
C1/0428: 1E 09 A0     ASL $A009,X
C1/042B: 1E 09 A2     ASL $A209,X
C1/042E: 1E 0B A0     ASL $A00B,X
C1/0431: 1E 0B A2     ASL $A20B,X
C1/0434: 80 0C        BRA $0442
C1/0436: 5E 09 A0     LSR $A009,X
C1/0439: 5E 09 A2     LSR $A209,X
C1/043C: 5E 0B A0     LSR $A00B,X
C1/043F: 5E 0B A2     LSR $A20B,X
C1/0442: E8           INX 
C1/0443: E8           INX 
C1/0444: E8           INX 
C1/0445: E8           INX 
C1/0446: E0 00 01     CPX #$0100
C1/0449: D0 BF        BNE $040A
C1/044B: A5 70        LDA $70
C1/044D: 18           CLC 
C1/044E: 69 40 00     ADC #$0040
C1/0451: 85 70        STA $70
C1/0453: 9D 09 A0     STA $A009,X
C1/0456: 9D 09 A2     STA $A209,X
C1/0459: 9D 0B A0     STA $A00B,X
C1/045C: 9D 0B A2     STA $A20B,X
C1/045F: 8A           TXA 
C1/0460: 29 07 00     AND #$0007
C1/0463: D0 1E        BNE $0483
C1/0465: A5 70        LDA $70
C1/0467: 10 0E        BPL $0477
C1/0469: 1E 09 A0     ASL $A009,X
C1/046C: 1E 09 A2     ASL $A209,X
C1/046F: 1E 0B A0     ASL $A00B,X
C1/0472: 1E 0B A2     ASL $A20B,X
C1/0475: 80 0C        BRA $0483
C1/0477: 5E 09 A0     LSR $A009,X
C1/047A: 5E 09 A2     LSR $A209,X
C1/047D: 5E 0B A0     LSR $A00B,X
C1/0480: 5E 0B A2     LSR $A20B,X
C1/0483: E8           INX 
C1/0484: E8           INX 
C1/0485: E8           INX 
C1/0486: E8           INX 
C1/0487: E0 00 02     CPX #$0200
C1/048A: D0 BF        BNE $044B
C1/048C: 7B           TDC 
C1/048D: E2 20        SEP #$20
C1/048F: 60           RTS 

C1/0490: 60           RTS 

C1/0491: 7B           TDC 
C1/0492: AA           TAX 
C1/0493: A9 FF        LDA #$FF
C1/0495: 9D 55 B4     STA $B455,X
C1/0498: E8           INX 
C1/0499: E0 20 00     CPX #$0020
C1/049C: D0 F7        BNE $0495
C1/049E: 9D 55 B4     STA $B455,X
C1/04A1: 3A           DEC 
C1/04A2: E8           INX 
C1/04A3: E0 40 00     CPX #$0040
C1/04A6: D0 F6        BNE $049E
C1/04A8: A9 E0        LDA #$E0
C1/04AA: 9D 55 B4     STA $B455,X
C1/04AD: E8           INX 
C1/04AE: E0 A0 00     CPX #$00A0
C1/04B1: D0 F7        BNE $04AA
C1/04B3: 9D 55 B4     STA $B455,X
C1/04B6: 1A           INC 
C1/04B7: E8           INX 
C1/04B8: E0 C0 00     CPX #$00C0
C1/04BB: D0 F6        BNE $04B3
C1/04BD: A9 FF        LDA #$FF
C1/04BF: 9D 55 B4     STA $B455,X
C1/04C2: E8           INX 
C1/04C3: E0 E0 00     CPX #$00E0
C1/04C6: D0 F7        BNE $04BF
C1/04C8: 60           RTS 

; [ init ram ]

C1/04C9: 9C FA FE     STZ $FEFA
C1/04CC: 9C 2E FF     STZ $FF2E
C1/04CF: 9C 2F FF     STZ $FF2F
C1/04D2: 9C 31 FF     STZ $FF31
C1/04D5: A2 09 80     LDX #$8009
C1/04D8: 20 EA 0A     JSR $0AEA
C1/04DB: 20 90 04     JSR $0490
C1/04DE: A9 80        LDA #$80
C1/04E0: 8D 0C 01     STA $010C
C1/04E3: AD 70 09     LDA $0970       ; get window/short setting
C1/04E6: 29 80        AND #$80
C1/04E8: 8D 26 04     STA $0426
C1/04EB: AD 70 09     LDA $0970       ; get message speed
C1/04EE: 4A           LSR 
C1/04EF: 4A           LSR 
C1/04F0: 4A           LSR 
C1/04F1: 4A           LSR 
C1/04F2: 29 07        AND #$07
C1/04F4: 8D 24 04     STA $0424
C1/04F7: AD 73 09     LDA $0973       ; get gauge setting
C1/04FA: 29 80        AND #$80
C1/04FC: 49 80        EOR #$80
C1/04FE: 8D 25 04     STA $0425       ; get reset/memory setting
C1/0501: AD 73 09     LDA $0973
C1/0504: 29 04        AND #$04
C1/0506: 4A           LSR 
C1/0507: 4A           LSR 
C1/0508: 0D 26 04     ORA $0426
C1/050B: 8D 26 04     STA $0426
C1/050E: 20 E9 FC     JSR $FCE9
C1/0511: A9 09        LDA #$09        ; mode 1
C1/0513: 8D 81 BC     STA $BC81
C1/0516: A9 01        LDA #$01
C1/0518: 8D 83 BC     STA $BC83
C1/051B: A9 0F        LDA #$0F
C1/051D: 8D 7F BC     STA $BC7F
C1/0520: 9C 80 BC     STZ $BC80
C1/0523: 9C 2B FF     STZ $FF2B
C1/0526: A2 00 58     LDX #$5800
C1/0529: A0 00 10     LDY #$1000
C1/052C: 20 BB FD     JSR $FDBB
C1/052F: A2 00 10     LDX #$1000
C1/0532: A0 00 20     LDY #$2000
C1/0535: 20 BB FD     JSR $FDBB
C1/0538: A2 00 48     LDX #$4800
C1/053B: A0 00 20     LDY #$2000
C1/053E: 20 BB FD     JSR $FDBB
C1/0541: A2 00 40     LDX #$4000
C1/0544: A0 00 02     LDY #$0200
C1/0547: 20 BB FD     JSR $FDBB
C1/054A: A2 00 00     LDX #$0000
C1/054D: A0 20 00     LDY #$0020
C1/0550: 20 BB FD     JSR $FDBB
C1/0553: 9C 56 EE     STZ $EE56
C1/0556: 9C 33 FF     STZ $FF33
C1/0559: A9 13        LDA #$13
C1/055B: 8D C1 DB     STA $DBC1
C1/055E: 8D C2 DB     STA $DBC2
C1/0561: 8D C3 DB     STA $DBC3
C1/0564: A9 FF        LDA #$FF
C1/0566: 8D E1 DB     STA $DBE1
C1/0569: 8D E2 DB     STA $DBE2
C1/056C: AD EF 3E     LDA $3EEF
C1/056F: 29 20        AND #$20
C1/0571: F0 05        BEQ $0578
C1/0573: A9 3F        LDA #$3F
C1/0575: 8D E1 DB     STA $DBE1
C1/0578: A9 82        LDA #$82
C1/057A: 8D 9E BC     STA $BC9E
C1/057D: AE F0 04     LDX $04F0
C1/0580: E0 BF 01     CPX #$01BF
C1/0583: D0 05        BNE $058A
C1/0585: A9 1E        LDA #$1E
C1/0587: 8D F2 04     STA $04F2
C1/058A: A9 00        LDA #$00
C1/058C: 8D BA B3     STA $B3BA
C1/058F: 1A           INC 
C1/0590: 8D BB B3     STA $B3BB
C1/0593: 8D B8 B3     STA $B3B8
C1/0596: AD EF 3E     LDA $3EEF
C1/0599: 10 1C        BPL $05B7       ; branch if not credits
C1/059B: A9 03        LDA #$03
C1/059D: 8D BA B3     STA $B3BA
C1/05A0: 1A           INC 
C1/05A1: 8D BB B3     STA $B3BB
C1/05A4: EE D3 DB     INC $DBD3
C1/05A7: A2 00 00     LDX #$0000
C1/05AA: A9 FF        LDA #$FF
C1/05AC: 9D 55 B4     STA $B455,X
C1/05AF: E8           INX 
C1/05B0: E0 E0 00     CPX #$00E0
C1/05B3: D0 F7        BNE $05AC
C1/05B5: 80 0A        BRA $05C1
C1/05B7: AD F2 04     LDA $04F2       ; battle bg
C1/05BA: C9 1F        CMP #$1F
C1/05BC: D0 03        BNE $05C1       ; branch if not neo exdeath
C1/05BE: EE BB B3     INC $B3BB
C1/05C1: 20 82 14     JSR $1482
C1/05C4: AD 19 7C     LDA $7C19
C1/05C7: F0 0F        BEQ $05D8
C1/05C9: A9 FF        LDA #$FF
C1/05CB: 85 F6        STA $F6
C1/05CD: A9 40        LDA #$40
C1/05CF: 85 F7        STA $F7
C1/05D1: A9 08        LDA #$08
C1/05D3: 85 F8        STA $F8
C1/05D5: 0A           ASL 
C1/05D6: 85 F9        STA $F9
C1/05D8: 20 A6 03     JSR $03A6       ; update song tempo multiplier
C1/05DB: 20 F0 03     JSR $03F0       ; update reflect sfx l/r
C1/05DE: 9C 2C FF     STZ $FF2C
C1/05E1: 9C 2D FF     STZ $FF2D
C1/05E4: A9 04        LDA #$04
C1/05E6: 85 04        STA $04
C1/05E8: A9 53        LDA #$53
C1/05EA: 85 CE        STA $CE
C1/05EC: A2 FF FF     LDX #$FFFF
C1/05EF: 8E 44 B4     STX $B444
C1/05F2: 8E 46 B4     STX $B446
C1/05F5: 7B           TDC 
C1/05F6: AA           TAX 
C1/05F7: A8           TAY 
C1/05F8: 64 70        STZ $70
C1/05FA: BD 00 20     LDA $2000,X
C1/05FD: 29 40        AND #$40
C1/05FF: D0 11        BNE $0612
C1/0601: A5 70        LDA $70
C1/0603: 99 44 B4     STA $B444,Y
C1/0606: C8           INY 
C1/0607: 5A           PHY 
C1/0608: A5 70        LDA $70
C1/060A: A8           TAY 
C1/060B: BD 00 20     LDA $2000,X
C1/060E: 29 07        AND #$07
C1/0610: 80 06        BRA $0618
C1/0612: 5A           PHY 
C1/0613: A5 70        LDA $70
C1/0615: A8           TAY 
C1/0616: A9 FF        LDA #$FF
C1/0618: 99 C6 CF     STA $CFC6,Y     ; character id
C1/061B: BD 01 20     LDA $2001,X
C1/061E: 99 CA CF     STA $CFCA,Y     ; character job
C1/0621: BD 21 20     LDA $2021,X
C1/0624: 99 CE CF     STA $CFCE,Y     ; character passive abilities
C1/0627: AD D3 DB     LDA $DBD3
C1/062A: D0 05        BNE $0631
C1/062C: BD 00 20     LDA $2000,X
C1/062F: 30 03        BMI $0634
C1/0631: 7B           TDC 
C1/0632: 80 02        BRA $0636
C1/0634: A9 01        LDA #$01
C1/0636: 99 4A DB     STA $DB4A,Y     ; character row
C1/0639: 7A           PLY 
C1/063A: E6 70        INC $70
C1/063C: C2 20        REP #$20
C1/063E: 8A           TXA 
C1/063F: 18           CLC 
C1/0640: 69 80 00     ADC #$0080
C1/0643: AA           TAX 
C1/0644: 7B           TDC 
C1/0645: E2 20        SEP #$20
C1/0647: E0 00 02     CPX #$0200
C1/064A: D0 AE        BNE $05FA
C1/064C: A2 00 00     LDX #$0000
C1/064F: BD 2C 38     LDA $382C,X     ; copy damage buffer
C1/0652: 9D D9 7C     STA $7CD9,X
C1/0655: E8           INX 
C1/0656: E0 20 00     CPX #$0020
C1/0659: D0 F4        BNE $064F
C1/065B: 20 17 B1     JSR $B117
C1/065E: 20 49 AE     JSR $AE49
C1/0661: A2 00 00     LDX #$0000
C1/0664: BD 38 40     LDA $4038,X
C1/0667: 9D F9 7C     STA $7CF9,X
C1/066A: E8           INX 
C1/066B: E0 10 00     CPX #$0010
C1/066E: D0 F4        BNE $0664
C1/0670: 9C C7 F8     STZ $F8C7
C1/0673: A9 03        LDA #$03
C1/0675: 8D 4B CD     STA $CD4B
C1/0678: 8D 4F CD     STA $CD4F
C1/067B: 8D 53 CD     STA $CD53
C1/067E: 8D 57 CD     STA $CD57
C1/0681: A9 33        LDA #$33
C1/0683: 8D 5B CD     STA $CD5B
C1/0686: 8D 5F CD     STA $CD5F
C1/0689: 8D 63 CD     STA $CD63
C1/068C: 8D 67 CD     STA $CD67
C1/068F: A9 E9        LDA #$E9
C1/0691: 8D 6D CD     STA $CD6D
C1/0694: 8D 71 CD     STA $CD71
C1/0697: A9 A4        LDA #$A4
C1/0699: 8D 6E CD     STA $CD6E
C1/069C: A9 CA        LDA #$CA
C1/069E: 8D 72 CD     STA $CD72
C1/06A1: 20 22 FD     JSR $FD22       ; clear sprite data
C1/06A4: AD F2 3E     LDA $3EF2
C1/06A7: 85 DE        STA $DE
C1/06A9: A2 00 00     LDX #$0000
C1/06AC: BD A1 7B     LDA $7BA1,X     ; get erased monsters
C1/06AF: 0A           ASL 
C1/06B0: 26 70        ROL $70
C1/06B2: E8           INX 
C1/06B3: E8           INX 
C1/06B4: E8           INX 
C1/06B5: E8           INX 
C1/06B6: E0 20 00     CPX #$0020
C1/06B9: D0 F1        BNE $06AC
C1/06BB: A5 70        LDA $70
C1/06BD: 49 FF        EOR #$FF
C1/06BF: 85 70        STA $70
C1/06C1: A5 DE        LDA $DE
C1/06C3: 25 70        AND $70         ; remove erased monsters
C1/06C5: 85 DE        STA $DE
C1/06C7: 20 E2 24     JSR $24E2       ; load character graphics
C1/06CA: A2 00 20     LDX #$2000
C1/06CD: 86 70        STX $70
C1/06CF: A2 00 D0     LDX #$D000
C1/06D2: A0 00 60     LDY #$6000
C1/06D5: A9 7F        LDA #$7F
C1/06D7: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/06DA: 20 2A 24     JSR $242A
C1/06DD: 20 54 24     JSR $2454
C1/06E0: 20 5A 33     JSR $335A       ; load battle bg
C1/06E3: 20 FF 3C     JSR $3CFF
C1/06E6: 20 89 26     JSR $2689
C1/06E9: 20 57 1A     JSR $1A57
C1/06EC: A9 03        LDA #$03
C1/06EE: A0 00 00     LDY #$0000
C1/06F1: 20 3E AA     JSR $AA3E       ; load attack palette (16-colors)
C1/06F4: A9 01        LDA #$01
C1/06F6: A0 00 01     LDY #$0100
C1/06F9: 20 3E AA     JSR $AA3E       ; load attack palette (16-colors)
C1/06FC: A9 06        LDA #$06
C1/06FE: A0 E0 00     LDY #$00E0
C1/0701: 20 3E AA     JSR $AA3E       ; load attack palette (16-colors)
C1/0704: A9 08        LDA #$08
C1/0706: A0 20 01     LDY #$0120
C1/0709: 20 3E AA     JSR $AA3E       ; load attack palette (16-colors)
C1/070C: 20 A7 09     JSR $09A7
C1/070F: AE 71 09     LDX $0971
C1/0712: 8E 0B 7E     STX $7E0B
C1/0715: 8E 13 7E     STX $7E13
C1/0718: 8E 1B 7E     STX $7E1B
C1/071B: 8E 23 7E     STX $7E23
C1/071E: A2 53 53     LDX #$5353
C1/0721: 8E 6E 7C     STX $7C6E
C1/0724: 8E 70 7C     STX $7C70
C1/0727: 7B           TDC 
C1/0728: AA           TAX 
C1/0729: A8           TAY 
C1/072A: BF 2D 7D D9  LDA $D97D2D,X
C1/072E: 99 A2 F9     STA $F9A2,Y
C1/0731: A9 20        LDA #$20
C1/0733: 99 A3 F9     STA $F9A3,Y
C1/0736: E8           INX 
C1/0737: C8           INY 
C1/0738: C8           INY 
C1/0739: C0 2A 00     CPY #$002A
C1/073C: D0 EC        BNE $072A
C1/073E: AD FB 3E     LDA $3EFB       ; get monster palettes
C1/0741: 20 7F 08     JSR $087F
C1/0744: 8D D6 CF     STA $CFD6
C1/0747: AD FB 3E     LDA $3EFB
C1/074A: 20 81 08     JSR $0881
C1/074D: 8D D7 CF     STA $CFD7
C1/0750: AD FB 3E     LDA $3EFB
C1/0753: 20 83 08     JSR $0883
C1/0756: 8D D8 CF     STA $CFD8
C1/0759: AD FB 3E     LDA $3EFB
C1/075C: 20 85 08     JSR $0885
C1/075F: 8D D9 CF     STA $CFD9
C1/0762: AD FC 3E     LDA $3EFC
C1/0765: 20 7F 08     JSR $087F
C1/0768: 8D DA CF     STA $CFDA
C1/076B: AD FC 3E     LDA $3EFC
C1/076E: 20 81 08     JSR $0881
C1/0771: 8D DB CF     STA $CFDB
C1/0774: AD FC 3E     LDA $3EFC
C1/0777: 20 83 08     JSR $0883
C1/077A: 8D DC CF     STA $CFDC
C1/077D: AD FC 3E     LDA $3EFC
C1/0780: 20 85 08     JSR $0885
C1/0783: 8D DD CF     STA $CFDD
C1/0786: 20 C4 20     JSR $20C4       ; load monster graphics
C1/0789: 20 02 22     JSR $2202
C1/078C: A5 DE        LDA $DE
C1/078E: 85 70        STA $70
C1/0790: 20 68 20     JSR $2068       ; load monster palettes
C1/0793: A2 00 00     LDX #$0000
C1/0796: DA           PHX 
C1/0797: 7B           TDC 
C1/0798: 85 7E        STA $7E
C1/079A: 8A           TXA 
C1/079B: 20 02 7B     JSR $7B02
C1/079E: FA           PLX 
C1/079F: E8           INX 
C1/07A0: E0 08 00     CPX #$0008
C1/07A3: D0 F1        BNE $0796
C1/07A5: A2 00 00     LDX #$0000
C1/07A8: BD 00 40     LDA $4000,X     ; monster x position
C1/07AB: 4A           LSR 
C1/07AC: 4A           LSR 
C1/07AD: 4A           LSR 
C1/07AE: 4A           LSR 
C1/07AF: 29 0F        AND #$0F
C1/07B1: 9D 0E D0     STA $D00E,X
C1/07B4: BD 00 40     LDA $4000,X     ; monster y position
C1/07B7: 29 0F        AND #$0F
C1/07B9: 9D 16 D0     STA $D016,X
C1/07BC: E8           INX 
C1/07BD: E0 08 00     CPX #$0008
C1/07C0: D0 E6        BNE $07A8
C1/07C2: 20 EB 1C     JSR $1CEB
C1/07C5: 20 48 1D     JSR $1D48
C1/07C8: 9C BB DB     STZ $DBBB
C1/07CB: 20 07 26     JSR $2607       ; load character palettes
C1/07CE: 20 65 1B     JSR $1B65
C1/07D1: 20 0D 1B     JSR $1B0D
C1/07D4: 20 5C 6D     JSR $6D5C
C1/07D7: 20 F6 AE     JSR $AEF6
C1/07DA: 20 FE 02     JSR $02FE
C1/07DD: 20 01 04     JSR $0401
C1/07E0: AD 26 04     LDA $0426
C1/07E3: CD 27 04     CMP $0427
C1/07E6: F0 15        BEQ $07FD       ; branch if command/cursor setting didn't change
C1/07E8: 20 71 08     JSR $0871       ; clear saved cursor positions
C1/07EB: AD 26 04     LDA $0426
C1/07EE: 8D 27 04     STA $0427
C1/07F1: 18           CLC 
C1/07F2: 6D 27 04     ADC $0427
C1/07F5: 1A           INC 
C1/07F6: 49 FF        EOR #$FF
C1/07F8: 8D 28 04     STA $0428       ; update command/cursor checksum
C1/07FB: 80 15        BRA $0812
C1/07FD: AD 26 04     LDA $0426
C1/0800: 18           CLC 
C1/0801: 6D 27 04     ADC $0427
C1/0804: 1A           INC 
C1/0805: 49 FF        EOR #$FF
C1/0807: CD 28 04     CMP $0428
C1/080A: F0 06        BEQ $0812       ; branch if command/cursor checksum is valid
C1/080C: 8D 28 04     STA $0428
C1/080F: 20 71 08     JSR $0871       ; clear saved cursor positions
C1/0812: 20 2C 08     JSR $082C       ; validate saved cursor checksums
C1/0815: AD 26 04     LDA $0426
C1/0818: 8D 27 04     STA $0427
C1/081B: 60           RTS 

; [ update saved cursor checksums ]

C1/081C: A2 00 00     LDX #$0000
C1/081F: 20 5A 08     JSR $085A
C1/0822: 9D 20 04     STA $0420,X
C1/0825: E8           INX 
C1/0826: E0 04 00     CPX #$0004
C1/0829: D0 F4        BNE $081F
C1/082B: 60           RTS 

; [ validate saved cursor checksums ]

C1/082C: A2 00 00     LDX #$0000
C1/082F: 20 5A 08     JSR $085A
C1/0832: DD 20 04     CMP $0420,X
C1/0835: F0 09        BEQ $0840
C1/0837: 20 47 08     JSR $0847
C1/083A: 20 5A 08     JSR $085A
C1/083D: 9D 20 04     STA $0420,X
C1/0840: E8           INX 
C1/0841: E0 04 00     CPX #$0004
C1/0844: D0 E9        BNE $082F
C1/0846: 60           RTS 

; [ reset saved cursor positions ]

C1/0847: DA           PHX 
C1/0848: A9 2D        LDA #$2D
C1/084A: 85 70        STA $70
C1/084C: 7B           TDC 
C1/084D: 9D 2D 04     STA $042D,X
C1/0850: E8           INX 
C1/0851: E8           INX 
C1/0852: E8           INX 
C1/0853: E8           INX 
C1/0854: C6 70        DEC $70
C1/0856: D0 F5        BNE $084D
C1/0858: FA           PLX 
C1/0859: 60           RTS 

; [ calculate saved cursor checksum ]

C1/085A: DA           PHX 
C1/085B: A9 2D        LDA #$2D
C1/085D: 85 70        STA $70
C1/085F: 7B           TDC 
C1/0860: 18           CLC 
C1/0861: 7D 2D 04     ADC $042D,X     ; add saved positions for each character
C1/0864: E8           INX 
C1/0865: E8           INX 
C1/0866: E8           INX 
C1/0867: E8           INX 
C1/0868: C6 70        DEC $70
C1/086A: D0 F4        BNE $0860
C1/086C: 1A           INC 
C1/086D: 49 FF        EOR #$FF        ; increment and invert bits
C1/086F: FA           PLX 
C1/0870: 60           RTS 

; [ clear saved cursor positions ]

C1/0871: A2 2D 04     LDX #$042D
C1/0874: 7B           TDC 
C1/0875: 9D 00 00     STA $0000,X
C1/0878: E8           INX 
C1/0879: E0 E1 04     CPX #$04E1
C1/087C: D0 F7        BNE $0875
C1/087E: 60           RTS 

; [ get monster palette ]

C1/087F: 4A           LSR 
C1/0880: 4A           LSR 
C1/0881: 4A           LSR 
C1/0882: 4A           LSR 
C1/0883: 4A           LSR 
C1/0884: 4A           LSR 
C1/0885: 29 03        AND #$03
C1/0887: 60           RTS 

; [ init hardware registers ]

C1/0888: A9 00        LDA #$00
C1/088A: 48           PHA 
C1/088B: AB           PLB 
C1/088C: 8D 00 42     STA $4200
C1/088F: A2 00 00     LDX #$0000
C1/0892: DA           PHX 
C1/0893: 2B           PLD 
C1/0894: A9 80        LDA #$80
C1/0896: 8D 00 21     STA $2100
C1/0899: AD 3F 21     LDA $213F
C1/089C: A9 02        LDA #$02        ; mode 2
C1/089E: 8D 05 21     STA $2105
C1/08A1: A2 00 03     LDX #$0300
C1/08A4: 8E 02 21     STX $2102
C1/08A7: A9 03        LDA #$03
C1/08A9: 8D 01 21     STA $2101
C1/08AC: A9 00        LDA #$00
C1/08AE: 8D 0B 21     STA $210B
C1/08B1: A9 44        LDA #$44
C1/08B3: 8D 0C 21     STA $210C
C1/08B6: A9 13        LDA #$13
C1/08B8: 8D 08 21     STA $2108
C1/08BB: A9 59        LDA #$59
C1/08BD: 8D 07 21     STA $2107
C1/08C0: A9 4B        LDA #$4B
C1/08C2: 8D 09 21     STA $2109
C1/08C5: A9 4B        LDA #$4B
C1/08C7: 8D 0A 21     STA $210A
C1/08CA: A9 80        LDA #$80
C1/08CC: 8D 15 21     STA $2115
C1/08CF: A9 00        LDA #$00
C1/08D1: AA           TAX 
C1/08D2: 8D 06 21     STA $2106
C1/08D5: 8D 0D 21     STA $210D
C1/08D8: 8D 0D 21     STA $210D
C1/08DB: 8D 0E 21     STA $210E
C1/08DE: 8D 0E 21     STA $210E
C1/08E1: 8D 0F 21     STA $210F
C1/08E4: 8D 0F 21     STA $210F
C1/08E7: 8D 10 21     STA $2110
C1/08EA: 8D 10 21     STA $2110
C1/08ED: 8D 11 21     STA $2111
C1/08F0: 8D 11 21     STA $2111
C1/08F3: 8D 12 21     STA $2112
C1/08F6: 8D 12 21     STA $2112
C1/08F9: 8D 13 21     STA $2113
C1/08FC: 8D 13 21     STA $2113
C1/08FF: 8D 14 21     STA $2114
C1/0902: 8D 14 21     STA $2114
C1/0905: 8E 2A 21     STX $212A
C1/0908: 8D 2E 21     STA $212E
C1/090B: 8D 2F 21     STA $212F
C1/090E: 8D 0B 42     STA $420B
C1/0911: 8D 0C 42     STA $420C
C1/0914: 8D 31 21     STA $2131
C1/0917: 8D 33 21     STA $2133
C1/091A: 8D 30 21     STA $2130
C1/091D: A9 08        LDA #$08
C1/091F: 8D 26 21     STA $2126
C1/0922: 8D 28 21     STA $2128
C1/0925: A9 F7        LDA #$F7
C1/0927: 8D 27 21     STA $2127
C1/092A: 8D 29 21     STA $2129
C1/092D: A9 C1        LDA #$C1
C1/092F: 8D 03 1F     STA $1F03
C1/0932: A2 EA 19     LDX #$19EA      ; C1/19EA (battle nmi)
C1/0935: 8E 01 1F     STX $1F01
C1/0938: A9 5C        LDA #$5C
C1/093A: 8D 00 1F     STA $1F00
C1/093D: 8D 04 1F     STA $1F04
C1/0940: A9 C1        LDA #$C1
C1/0942: 8D 07 1F     STA $1F07
C1/0945: A2 E9 19     LDX #$19E9      ; C1/19E9 (battle irq)
C1/0948: 8E 05 1F     STX $1F05
C1/094B: A9 33        LDA #$33
C1/094D: 8D 23 21     STA $2123
C1/0950: 8D 24 21     STA $2124
C1/0953: 8D 25 21     STA $2125
C1/0956: A9 1F        LDA #$1F
C1/0958: 8D 2C 21     STA $212C
C1/095B: 8D 2E 21     STA $212E
C1/095E: A9 7E        LDA #$7E
C1/0960: 48           PHA 
C1/0961: AB           PLB 
C1/0962: A2 B7 B3     LDX #$B3B7      ; clear $B3B7-$DBF5
C1/0965: 9E 00 00     STZ $0000,X
C1/0968: E8           INX 
C1/0969: E0 F6 DB     CPX #$DBF6
C1/096C: D0 F7        BNE $0965
C1/096E: A2 70 00     LDX #$0070      ; clear $0070-$00FA
C1/0971: 9E 00 00     STZ $0000,X
C1/0974: E8           INX 
C1/0975: E0 FB 00     CPX #$00FB
C1/0978: D0 F7        BNE $0971
C1/097A: 7B           TDC 
C1/097B: AA           TAX 
C1/097C: 9D 09 7E     STA $7E09,X     ; clear palettes
C1/097F: E8           INX 
C1/0980: E0 00 02     CPX #$0200
C1/0983: D0 F7        BNE $097C
C1/0985: 7B           TDC 
C1/0986: AA           TAX 
C1/0987: 9D F6 DC     STA $DCF6,X
C1/098A: E8           INX 
C1/098B: E0 00 10     CPX #$1000
C1/098E: D0 F7        BNE $0987
C1/0990: A9 FF        LDA #$FF
C1/0992: 8D 04 FF     STA $FF04
C1/0995: 60           RTS 

C1/0996: 48           PHA 
C1/0997: 18           CLC 
C1/0998: 7D 7B CE     ADC $CE7B,X
C1/099B: 9D 7B CE     STA $CE7B,X
C1/099E: 68           PLA 
C1/099F: 18           CLC 
C1/09A0: 7D BB CE     ADC $CEBB,X
C1/09A3: 9D BB CE     STA $CEBB,X
C1/09A6: 60           RTS 

C1/09A7: A2 00 00     LDX #$0000
C1/09AA: A9 40        LDA #$40
C1/09AC: 9E 7B CE     STZ $CE7B,X
C1/09AF: 9D BB CE     STA $CEBB,X
C1/09B2: E8           INX 
C1/09B3: E0 10 00     CPX #$0010
C1/09B6: D0 F4        BNE $09AC
C1/09B8: 60           RTS 

C1/09B9: 48           PHA 
C1/09BA: 18           CLC 
C1/09BB: 7D FB CD     ADC $CDFB,X
C1/09BE: 9D FB CD     STA $CDFB,X
C1/09C1: 68           PLA 
C1/09C2: 18           CLC 
C1/09C3: 7D 3B CE     ADC $CE3B,X
C1/09C6: 9D 3B CE     STA $CE3B,X
C1/09C9: 60           RTS 

C1/09CA: BD FB CD     LDA $CDFB,X
C1/09CD: 0A           ASL 
C1/09CE: 85 80        STA $80
C1/09D0: BD 7B CE     LDA $CE7B,X
C1/09D3: 4C 00 0A     JMP $0A00

C1/09D6: 48           PHA 
C1/09D7: BD FB CD     LDA $CDFB,X
C1/09DA: 0A           ASL 
C1/09DB: 85 80        STA $80
C1/09DD: 68           PLA 
C1/09DE: 18           CLC 
C1/09DF: 7D 7B CE     ADC $CE7B,X
C1/09E2: 4C 00 0A     JMP $0A00

C1/09E5: BD 3B CE     LDA $CE3B,X
C1/09E8: 0A           ASL 
C1/09E9: 85 80        STA $80
C1/09EB: BD BB CE     LDA $CEBB,X
C1/09EE: 4C 00 0A     JMP $0A00

C1/09F1: 48           PHA 
C1/09F2: BD 3B CE     LDA $CE3B,X
C1/09F5: 0A           ASL 
C1/09F6: 85 80        STA $80
C1/09F8: 68           PLA 
C1/09F9: 18           CLC 
C1/09FA: 7D BB CE     ADC $CEBB,X
C1/09FD: 4C 00 0A     JMP $0A00

C1/0A00: AA           TAX 
C1/0A01: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/0A05: 10 18        BPL $0A1F
C1/0A07: 49 FF        EOR #$FF
C1/0A09: 8F 02 42 00  STA $004202
C1/0A0D: A5 80        LDA $80
C1/0A0F: 8F 03 42 00  STA $004203
C1/0A13: EA           NOP 
C1/0A14: EA           NOP 
C1/0A15: EA           NOP 
C1/0A16: EA           NOP 
C1/0A17: AF 17 42 00  LDA $004217
C1/0A1B: 49 FF        EOR #$FF
C1/0A1D: 1A           INC 
C1/0A1E: 60           RTS 
C1/0A1F: 8F 02 42 00  STA $004202
C1/0A23: A5 80        LDA $80
C1/0A25: 8F 03 42 00  STA $004203
C1/0A29: EA           NOP 
C1/0A2A: EA           NOP 
C1/0A2B: EA           NOP 
C1/0A2C: EA           NOP 
C1/0A2D: AF 17 42 00  LDA $004217
C1/0A31: 60           RTS 

; [  ]

C1/0A32: AA           TAX 
C1/0A33: A5 FA        LDA $FA
C1/0A35: D0 1C        BNE $0A53
C1/0A37: A5 9A        LDA $9A
C1/0A39: 8F 1B 21 00  STA $00211B
C1/0A3D: 7B           TDC 
C1/0A3E: 8F 1B 21 00  STA $00211B
C1/0A42: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/0A46: 8F 1C 21 00  STA $00211C
C1/0A4A: 8F 1C 21 00  STA $00211C
C1/0A4E: AF 35 21 00  LDA $002135
C1/0A52: 60           RTS 
C1/0A53: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/0A57: 10 0D        BPL $0A66
C1/0A59: 49 FF        EOR #$FF
C1/0A5B: 85 98        STA $98
C1/0A5D: 20 4B FE     JSR $FE4B
C1/0A60: A5 9D        LDA $9D
C1/0A62: 49 FF        EOR #$FF
C1/0A64: 1A           INC 
C1/0A65: 60           RTS 
C1/0A66: 85 98        STA $98
C1/0A68: 20 4B FE     JSR $FE4B
C1/0A6B: A5 9D        LDA $9D
C1/0A6D: 60           RTS 

; [  ]

C1/0A6E: A5 A6        LDA $A6
C1/0A70: 38           SEC 
C1/0A71: E5 A8        SBC $A8
C1/0A73: 85 AA        STA $AA
C1/0A75: A9 00        LDA #$00
C1/0A77: E9 00        SBC #$00
C1/0A79: 85 AB        STA $AB
C1/0A7B: A5 A7        LDA $A7
C1/0A7D: 38           SEC 
C1/0A7E: E5 A9        SBC $A9
C1/0A80: 85 AC        STA $AC
C1/0A82: A9 00        LDA #$00
C1/0A84: E9 00        SBC #$00
C1/0A86: 85 AD        STA $AD
C1/0A88: A5 AA        LDA $AA
C1/0A8A: 45 AB        EOR $AB
C1/0A8C: 38           SEC 
C1/0A8D: E5 AB        SBC $AB
C1/0A8F: 85 B1        STA $B1
C1/0A91: 64 B2        STZ $B2
C1/0A93: A5 AC        LDA $AC
C1/0A95: 45 AD        EOR $AD
C1/0A97: 38           SEC 
C1/0A98: E5 AD        SBC $AD
C1/0A9A: 85 B3        STA $B3
C1/0A9C: 64 B4        STZ $B4
C1/0A9E: C2 20        REP #$20
C1/0AA0: A5 B1        LDA $B1
C1/0AA2: 4A           LSR 
C1/0AA3: 4A           LSR 
C1/0AA4: 4A           LSR 
C1/0AA5: 85 AF        STA $AF
C1/0AA7: A5 B3        LDA $B3
C1/0AA9: 29 F8 FF     AND #$FFF8
C1/0AAC: 0A           ASL 
C1/0AAD: 0A           ASL 
C1/0AAE: 18           CLC 
C1/0AAF: 65 AF        ADC $AF
C1/0AB1: 85 B5        STA $B5
C1/0AB3: 0A           ASL 
C1/0AB4: AA           TAX 
C1/0AB5: BF 09 80 7E  LDA $7E8009,X
C1/0AB9: 85 AF        STA $AF
C1/0ABB: 7B           TDC 
C1/0ABC: E2 20        SEP #$20
C1/0ABE: A6 B5        LDX $B5
C1/0AC0: BF 00 FB CE  LDA $CEFB00,X
C1/0AC4: 85 AE        STA $AE
C1/0AC6: A5 AB        LDA $AB
C1/0AC8: 30 14        BMI $0ADE
C1/0ACA: A5 AD        LDA $AD
C1/0ACC: 30 08        BMI $0AD6
C1/0ACE: A9 80        LDA #$80
C1/0AD0: 18           CLC 
C1/0AD1: 65 AE        ADC $AE
C1/0AD3: 85 AE        STA $AE
C1/0AD5: 60           RTS 
C1/0AD6: A9 80        LDA #$80
C1/0AD8: 38           SEC 
C1/0AD9: E5 AE        SBC $AE
C1/0ADB: 85 AE        STA $AE
C1/0ADD: 60           RTS 
C1/0ADE: A5 AD        LDA $AD
C1/0AE0: 30 07        BMI $0AE9
C1/0AE2: A9 00        LDA #$00
C1/0AE4: 38           SEC 
C1/0AE5: E5 AE        SBC $AE
C1/0AE7: 85 AE        STA $AE
C1/0AE9: 60           RTS 

; [  ]

C1/0AEA: 86 70        STX $70
C1/0AEC: C2 20        REP #$20
C1/0AEE: 7B           TDC 
C1/0AEF: AA           TAX 
C1/0AF0: 7B           TDC 
C1/0AF1: 85 72        STA $72
C1/0AF3: A8           TAY 
C1/0AF4: BF 00 F7 CE  LDA $CEF700,X
C1/0AF8: 29 FF 00     AND #$00FF
C1/0AFB: 18           CLC 
C1/0AFC: 65 72        ADC $72
C1/0AFE: 85 72        STA $72
C1/0B00: 91 70        STA ($70),Y
C1/0B02: C8           INY 
C1/0B03: C8           INY 
C1/0B04: E8           INX 
C1/0B05: C0 40 00     CPY #$0040
C1/0B08: D0 EA        BNE $0AF4
C1/0B0A: A5 70        LDA $70
C1/0B0C: 18           CLC 
C1/0B0D: 69 40 00     ADC #$0040
C1/0B10: 85 70        STA $70
C1/0B12: E0 00 04     CPX #$0400
C1/0B15: D0 D9        BNE $0AF0
C1/0B17: 7B           TDC 
C1/0B18: E2 20        SEP #$20
C1/0B1A: 60           RTS 

; [  ]

C1/0B1B: E2 20        SEP #$20
C1/0B1D: A5 80        LDA $80
C1/0B1F: 8F 02 42 00  STA $004202
C1/0B23: A5 7E        LDA $7E
C1/0B25: 8F 03 42 00  STA $004203
C1/0B29: EA           NOP 
C1/0B2A: EA           NOP 
C1/0B2B: EA           NOP 
C1/0B2C: EA           NOP 
C1/0B2D: AF 16 42 00  LDA $004216
C1/0B31: 85 82        STA $82
C1/0B33: AF 17 42 00  LDA $004217
C1/0B37: 85 83        STA $83
C1/0B39: A5 80        LDA $80
C1/0B3B: 8F 02 42 00  STA $004202
C1/0B3F: A5 7F        LDA $7F
C1/0B41: 8F 03 42 00  STA $004203
C1/0B45: C2 20        REP #$20
C1/0B47: EA           NOP 
C1/0B48: EA           NOP 
C1/0B49: 64 84        STZ $84
C1/0B4B: AF 16 42 00  LDA $004216
C1/0B4F: 18           CLC 
C1/0B50: 65 83        ADC $83
C1/0B52: 85 83        STA $83
C1/0B54: 06 82        ASL $82
C1/0B56: 26 84        ROL $84
C1/0B58: 60           RTS 

; [  ]

C1/0B59: C2 20        REP #$20
C1/0B5B: 29 FF 00     AND #$00FF
C1/0B5E: 0A           ASL 
C1/0B5F: AA           TAX 
C1/0B60: BF 00 F4 CE  LDA $CEF400,X
C1/0B64: 10 12        BPL $0B78
C1/0B66: 49 FF FF     EOR #$FFFF
C1/0B69: 85 7E        STA $7E
C1/0B6B: 20 1B 0B     JSR $0B1B
C1/0B6E: A5 84        LDA $84
C1/0B70: 49 FF FF     EOR #$FFFF
C1/0B73: 1A           INC 
C1/0B74: 85 84        STA $84
C1/0B76: 80 05        BRA $0B7D
C1/0B78: 85 7E        STA $7E
C1/0B7A: 20 1B 0B     JSR $0B1B
C1/0B7D: 7B           TDC 
C1/0B7E: E2 20        SEP #$20
C1/0B80: 60           RTS 

; [ play queued song ]

C1/0B81: AD 04 FF     LDA $FF04
C1/0B84: C9 FF        CMP #$FF
C1/0B86: F0 1B        BEQ $0BA3
C1/0B88: 8D 01 1D     STA $1D01
C1/0B8B: A9 01        LDA #$01        ; spc interrupt $01 (play song)
C1/0B8D: 8D 00 1D     STA $1D00
C1/0B90: A9 08        LDA #$08
C1/0B92: 8D 02 1D     STA $1D02
C1/0B95: A9 0F        LDA #$0F
C1/0B97: 8D 03 1D     STA $1D03
C1/0B9A: 22 04 00 C4  JSL $C40004
C1/0B9E: A9 FF        LDA #$FF
C1/0BA0: 8D 04 FF     STA $FF04
C1/0BA3: 60           RTS 

; [ update battle bg hdma ??? ]

C1/0BA4: 9C C5 F8     STZ $F8C5
C1/0BA7: 9C C6 F8     STZ $F8C6
C1/0BAA: AD 9A DB     LDA $DB9A
C1/0BAD: D0 50        BNE $0BFF
C1/0BAF: AD 2F FF     LDA $FF2F
C1/0BB2: F0 08        BEQ $0BBC
C1/0BB4: 20 96 FC     JSR $FC96       ; generate random number
C1/0BB7: 29 03        AND #$03
C1/0BB9: 8D 77 BC     STA $BC77
C1/0BBC: AD F2 04     LDA $04F2       ; battle background id
C1/0BBF: C9 1F        CMP #$1F
C1/0BC1: D0 0E        BNE $0BD1       ; branch if not neo exdeath
C1/0BC3: A9 12        LDA #$12
C1/0BC5: 8D C1 DB     STA $DBC1
C1/0BC8: EE C5 F8     INC $F8C5
C1/0BCB: EE C6 F8     INC $F8C6
C1/0BCE: 4C 5F 0C     JMP $0C5F
C1/0BD1: C9 1D        CMP #$1D
C1/0BD3: D0 0C        BNE $0BE1       ; branch if not underwater tower of walse
C1/0BD5: EE C5 F8     INC $F8C5
C1/0BD8: 20 F4 10     JSR $10F4
C1/0BDB: EE C6 F8     INC $F8C6
C1/0BDE: 4C C3 0F     JMP $0FC3
C1/0BE1: C9 1A        CMP #$1A
C1/0BE3: D0 06        BNE $0BEB       ; branch if not karnak castle interior
C1/0BE5: EE C5 F8     INC $F8C5
C1/0BE8: 4C EB 10     JMP $10EB
C1/0BEB: C9 02        CMP #$02
C1/0BED: D0 06        BNE $0BF5       ; branch if not desert
C1/0BEF: EE C6 F8     INC $F8C6
C1/0BF2: 4C D4 0F     JMP $0FD4
C1/0BF5: C9 FF        CMP #$FF
C1/0BF7: D0 06        BNE $0BFF
C1/0BF9: EE C6 F8     INC $F8C6
C1/0BFC: 4C 15 10     JMP $1015
C1/0BFF: C9 FE        CMP #$FE
C1/0C01: D0 06        BNE $0C09
C1/0C03: EE C6 F8     INC $F8C6
C1/0C06: 4C 5A 10     JMP $105A
C1/0C09: AD D3 DB     LDA $DBD3
C1/0C0C: F0 27        BEQ $0C35       ; branch if not credits
C1/0C0E: AD D4 DB     LDA $DBD4
C1/0C11: F0 22        BEQ $0C35
C1/0C13: 9C D4 DB     STZ $DBD4
C1/0C16: 8B           PHB 
C1/0C17: C2 20        REP #$20
C1/0C19: A2 09 A0     LDX #$A009
C1/0C1C: A0 37 A9     LDY #$A937
C1/0C1F: A9 7F 03     LDA #$037F
C1/0C22: 54 7E 7E     MVN $7E,$7E
C1/0C25: A2 09 A4     LDX #$A409
C1/0C28: A0 B7 AC     LDY #$ACB7
C1/0C2B: A9 7F 03     LDA #$037F
C1/0C2E: 54 7E 7E     MVN $7E,$7E
C1/0C31: 7B           TDC 
C1/0C32: E2 20        SEP #$20
C1/0C34: AB           PLB 
C1/0C35: 60           RTS 

; neo exdeath battle bg data
C1/0C36: 01 00 01 00 00 01 00 00 00 01 00 00 00 00 01 00
C1/0C46: 00 00 00 00 FF 00 00 00 00 00 01 00 00 00 00 01
C1/0C56: 00 00 00 01 00 00 01 00 01

; [ update neo exdeath battle bg ]

C1/0C5F: AD 2D FF     LDA $FF2D
C1/0C62: F0 0A        BEQ $0C6E
C1/0C64: AD 9E BC     LDA $BC9E
C1/0C67: 09 01        ORA #$01
C1/0C69: 8D 9E BC     STA $BC9E
C1/0C6C: 80 08        BRA $0C76
C1/0C6E: AD 9E BC     LDA $BC9E
C1/0C71: 29 FE        AND #$FE
C1/0C73: 8D 9E BC     STA $BC9E
C1/0C76: AD E9 DB     LDA $DBE9
C1/0C79: D0 36        BNE $0CB1

; $DBE9 = 0
C1/0C7B: A9 1F        LDA #$1F
C1/0C7D: 8F 2C 21 00  STA $00212C
C1/0C81: 20 96 FC     JSR $FC96       ; generate random number
C1/0C84: 29 03        AND #$03
C1/0C86: 85 88        STA $88
C1/0C88: 20 96 FC     JSR $FC96       ; generate random number
C1/0C8B: 29 03        AND #$03
C1/0C8D: 85 8A        STA $8A
C1/0C8F: 64 89        STZ $89
C1/0C91: 64 8B        STZ $8B
C1/0C93: C2 20        REP #$20
C1/0C95: AD E7 DB     LDA $DBE7
C1/0C98: 18           CLC 
C1/0C99: 65 8A        ADC $8A
C1/0C9B: 8D 79 BC     STA $BC79       ; bg1 v-scroll
C1/0C9E: AD E5 DB     LDA $DBE5
C1/0CA1: 18           CLC 
C1/0CA2: 65 88        ADC $88
C1/0CA4: 18           CLC 
C1/0CA5: 69 08 00     ADC #$0008
C1/0CA8: 8D 77 BC     STA $BC77       ; bg1 h-scroll
C1/0CAB: 7B           TDC 
C1/0CAC: E2 20        SEP #$20
C1/0CAE: 4C 2A 0D     JMP $0D2A

; $DBE9 = 1
C1/0CB1: C9 01        CMP #$01
C1/0CB3: D0 01        BNE $0CB6
C1/0CB5: 60           RTS 
C1/0CB6: A2 00 00     LDX #$0000
C1/0CB9: 86 88        STX $88
C1/0CBB: 86 8A        STX $8A
C1/0CBD: AD EB DB     LDA $DBEB
C1/0CC0: F0 10        BEQ $0CD2
C1/0CC2: 20 96 FC     JSR $FC96       ; generate random number
C1/0CC5: 2D EC DB     AND $DBEC
C1/0CC8: 85 88        STA $88
C1/0CCA: 20 96 FC     JSR $FC96       ; generate random number
C1/0CCD: 2D EC DB     AND $DBEC
C1/0CD0: 85 8A        STA $8A
C1/0CD2: A9 08        LDA #$08
C1/0CD4: 8F 1B 21 00  STA $00211B
C1/0CD8: A9 00        LDA #$00
C1/0CDA: 8F 1B 21 00  STA $00211B
C1/0CDE: AD EA DB     LDA $DBEA
C1/0CE1: AA           TAX 
C1/0CE2: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/0CE6: 8F 1C 21 00  STA $00211C
C1/0CEA: C2 20        REP #$20
C1/0CEC: AF 35 21 00  LDA $002135
C1/0CF0: 18           CLC 
C1/0CF1: 69 08 00     ADC #$0008
C1/0CF4: 18           CLC 
C1/0CF5: 65 88        ADC $88
C1/0CF7: 8D 77 BC     STA $BC77       ; bg1 h-scroll
C1/0CFA: 7B           TDC 
C1/0CFB: E2 20        SEP #$20
C1/0CFD: A9 08        LDA #$08
C1/0CFF: 8F 1B 21 00  STA $00211B
C1/0D03: A9 00        LDA #$00
C1/0D05: 8F 1B 21 00  STA $00211B
C1/0D09: AD EA DB     LDA $DBEA
C1/0D0C: 18           CLC 
C1/0D0D: 69 20        ADC #$20
C1/0D0F: AA           TAX 
C1/0D10: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/0D14: 8F 1C 21 00  STA $00211C
C1/0D18: C2 20        REP #$20
C1/0D1A: AF 35 21 00  LDA $002135
C1/0D1E: 18           CLC 
C1/0D1F: 65 8A        ADC $8A
C1/0D21: 8D 79 BC     STA $BC79       ; bg1 v-scroll
C1/0D24: 7B           TDC 
C1/0D25: E2 20        SEP #$20
C1/0D27: EE EA DB     INC $DBEA

; 
C1/0D2A: AD 2C FF     LDA $FF2C
C1/0D2D: F0 16        BEQ $0D45
C1/0D2F: A5 A2        LDA $A2
C1/0D31: 29 01        AND #$01
C1/0D33: F0 10        BEQ $0D45
C1/0D35: 20 96 FC     JSR $FC96       ; generate random number
C1/0D38: 29 07        AND #$07
C1/0D3A: 8D 77 BC     STA $BC77       ; bg1 h-scroll
C1/0D3D: 20 96 FC     JSR $FC96       ; generate random number
C1/0D40: 29 07        AND #$07
C1/0D42: 8D 79 BC     STA $BC79       ; bg1 v-scroll
C1/0D45: EE A6 DB     INC $DBA6
C1/0D48: AD A6 DB     LDA $DBA6
C1/0D4B: AA           TAX 
C1/0D4C: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/0D50: 85 8C        STA $8C
C1/0D52: AD C6 DB     LDA $DBC6
C1/0D55: F0 20        BEQ $0D77
C1/0D57: AA           TAX 
C1/0D58: CE C6 DB     DEC $DBC6
C1/0D5B: BF 36 0C C1  LDA $C10C36,X
C1/0D5F: 10 0F        BPL $0D70

; $FF
C1/0D61: AD C4 DB     LDA $DBC4
C1/0D64: 30 04        BMI $0D6A
C1/0D66: A9 FF        LDA #$FF
C1/0D68: 80 02        BRA $0D6C
C1/0D6A: A9 01        LDA #$01
C1/0D6C: 8D C4 DB     STA $DBC4
C1/0D6F: 7B           TDC 
C1/0D70: C9 01        CMP #$01
C1/0D72: F0 25        BEQ $0D99
C1/0D74: 4C A3 0D     JMP $0DA3
C1/0D77: AD C5 DB     LDA $DBC5
C1/0D7A: D0 1A        BNE $0D96
C1/0D7C: 20 96 FC     JSR $FC96       ; generate random number
C1/0D7F: 09 80        ORA #$80
C1/0D81: 8D C5 DB     STA $DBC5
C1/0D84: 29 01        AND #$01
C1/0D86: F0 01        BEQ $0D89
C1/0D88: 1A           INC 
C1/0D89: 3A           DEC 
C1/0D8A: CD C4 DB     CMP $DBC4
C1/0D8D: F0 07        BEQ $0D96
C1/0D8F: A9 27        LDA #$27
C1/0D91: 8D C6 DB     STA $DBC6
C1/0D94: 80 03        BRA $0D99
C1/0D96: CE C5 DB     DEC $DBC5
C1/0D99: AD A5 DB     LDA $DBA5
C1/0D9C: 18           CLC 
C1/0D9D: 6D C4 DB     ADC $DBC4
C1/0DA0: 8D A5 DB     STA $DBA5
C1/0DA3: AD A5 DB     LDA $DBA5
C1/0DA6: C2 20        REP #$20
C1/0DA8: 0A           ASL 
C1/0DA9: A8           TAY 
C1/0DAA: 0A           ASL 
C1/0DAB: 85 88        STA $88
C1/0DAD: 7B           TDC 
C1/0DAE: E2 20        SEP #$20
C1/0DB0: 98           TYA 
C1/0DB1: 29 02        AND #$02
C1/0DB3: D0 43        BNE $0DF8

; 
C1/0DB5: A2 00 00     LDX #$0000
C1/0DB8: B9 09 A0     LDA $A009,Y
C1/0DBB: 8F 1B 21 00  STA $00211B
C1/0DBF: B9 0A A0     LDA $A00A,Y
C1/0DC2: 8F 1B 21 00  STA $00211B
C1/0DC6: A5 8C        LDA $8C
C1/0DC8: 8F 1C 21 00  STA $00211C
C1/0DCC: C2 20        REP #$20
C1/0DCE: AF 35 21 00  LDA $002135
C1/0DD2: 29 FF 03     AND #$03FF
C1/0DD5: 9D B7 AC     STA $ACB7,X
C1/0DD8: 9D C7 AC     STA $ACC7,X
C1/0DDB: A5 88        LDA $88
C1/0DDD: 9D B9 AC     STA $ACB9,X
C1/0DE0: 9D C9 AC     STA $ACC9,X
C1/0DE3: C8           INY 
C1/0DE4: C8           INY 
C1/0DE5: C8           INY 
C1/0DE6: C8           INY 
C1/0DE7: 8A           TXA 
C1/0DE8: 18           CLC 
C1/0DE9: 69 20 00     ADC #$0020
C1/0DEC: AA           TAX 
C1/0DED: 7B           TDC 
C1/0DEE: E2 20        SEP #$20
C1/0DF0: E0 80 02     CPX #$0280
C1/0DF3: D0 C3        BNE $0DB8
C1/0DF5: 4C 90 0E     JMP $0E90

; 
C1/0DF8: A2 00 00     LDX #$0000
C1/0DFB: B9 09 A0     LDA $A009,Y
C1/0DFE: 8F 1B 21 00  STA $00211B
C1/0E02: B9 0A A0     LDA $A00A,Y
C1/0E05: 8F 1B 21 00  STA $00211B
C1/0E09: A5 8C        LDA $8C
C1/0E0B: 8F 1C 21 00  STA $00211C
C1/0E0F: C2 20        REP #$20
C1/0E11: AF 35 21 00  LDA $002135
C1/0E15: 29 FF 03     AND #$03FF
C1/0E18: 9D B7 AC     STA $ACB7,X     ; bg2 h-scroll hdma data
C1/0E1B: A5 88        LDA $88
C1/0E1D: 9D B9 AC     STA $ACB9,X     ; bg2 v-scroll hdma data
C1/0E20: C8           INY 
C1/0E21: C8           INY 
C1/0E22: 8A           TXA 
C1/0E23: 18           CLC 
C1/0E24: 69 10 00     ADC #$0010
C1/0E27: AA           TAX 
C1/0E28: 7B           TDC 
C1/0E29: E2 20        SEP #$20
C1/0E2B: B9 09 A0     LDA $A009,Y
C1/0E2E: 8F 1B 21 00  STA $00211B
C1/0E32: B9 0A A0     LDA $A00A,Y
C1/0E35: 8F 1B 21 00  STA $00211B
C1/0E39: A5 8C        LDA $8C
C1/0E3B: 8F 1C 21 00  STA $00211C
C1/0E3F: C2 20        REP #$20
C1/0E41: AF 35 21 00  LDA $002135
C1/0E45: 29 FF 03     AND #$03FF
C1/0E48: 9D B7 AC     STA $ACB7,X
C1/0E4B: 9D C7 AC     STA $ACC7,X
C1/0E4E: A5 88        LDA $88
C1/0E50: 9D B9 AC     STA $ACB9,X
C1/0E53: 9D C9 AC     STA $ACC9,X
C1/0E56: C8           INY 
C1/0E57: C8           INY 
C1/0E58: C8           INY 
C1/0E59: C8           INY 
C1/0E5A: 8A           TXA 
C1/0E5B: 18           CLC 
C1/0E5C: 69 20 00     ADC #$0020
C1/0E5F: AA           TAX 
C1/0E60: 7B           TDC 
C1/0E61: E2 20        SEP #$20
C1/0E63: E0 70 02     CPX #$0270
C1/0E66: D0 C3        BNE $0E2B
C1/0E68: B9 09 A0     LDA $A009,Y
C1/0E6B: 8F 1B 21 00  STA $00211B
C1/0E6F: B9 0A A0     LDA $A00A,Y
C1/0E72: 8F 1B 21 00  STA $00211B
C1/0E76: A5 8C        LDA $8C
C1/0E78: 8F 1C 21 00  STA $00211C
C1/0E7C: C2 20        REP #$20
C1/0E7E: AF 35 21 00  LDA $002135
C1/0E82: 29 FF 03     AND #$03FF
C1/0E85: 9D B7 AC     STA $ACB7,X
C1/0E88: A5 88        LDA $88
C1/0E8A: 9D B9 AC     STA $ACB9,X
C1/0E8D: 7B           TDC 
C1/0E8E: E2 20        SEP #$20

; change bg colors ??? (every 8 frames)
C1/0E90: AD A2 00     LDA $00A2
C1/0E93: 29 07        AND #$07
C1/0E95: D0 79        BNE $0F10
C1/0E97: AD C7 DB     LDA $DBC7
C1/0E9A: D0 33        BNE $0ECF
C1/0E9C: A9 08        LDA #$08
C1/0E9E: 8D C7 DB     STA $DBC7
C1/0EA1: 20 96 FC     JSR $FC96       ; generate random number
C1/0EA4: 29 07        AND #$07
C1/0EA6: 8D C8 DB     STA $DBC8
C1/0EA9: 85 88        STA $88
C1/0EAB: 46 88        LSR $88
C1/0EAD: 90 08        BCC $0EB7
C1/0EAF: AD C9 DB     LDA $DBC9
C1/0EB2: 49 01        EOR #$01
C1/0EB4: 8D C9 DB     STA $DBC9
C1/0EB7: 46 88        LSR $88
C1/0EB9: 90 08        BCC $0EC3
C1/0EBB: AD C9 DB     LDA $DBC9
C1/0EBE: 49 02        EOR #$02
C1/0EC0: 8D C9 DB     STA $DBC9
C1/0EC3: 46 88        LSR $88
C1/0EC5: 90 08        BCC $0ECF
C1/0EC7: AD C9 DB     LDA $DBC9
C1/0ECA: 49 04        EOR #$04
C1/0ECC: 8D C9 DB     STA $DBC9
C1/0ECF: CE C7 DB     DEC $DBC7
C1/0ED2: AD C8 DB     LDA $DBC8
C1/0ED5: 85 88        STA $88
C1/0ED7: 46 88        LSR $88
C1/0ED9: 90 0F        BCC $0EEA
C1/0EDB: AD C9 DB     LDA $DBC9
C1/0EDE: 29 01        AND #$01
C1/0EE0: D0 05        BNE $0EE7
C1/0EE2: CE 9B BC     DEC $BC9B       ; red
C1/0EE5: 80 03        BRA $0EEA
C1/0EE7: EE 9B BC     INC $BC9B
C1/0EEA: 46 88        LSR $88
C1/0EEC: 90 0F        BCC $0EFD
C1/0EEE: AD C9 DB     LDA $DBC9
C1/0EF1: 29 02        AND #$02
C1/0EF3: D0 05        BNE $0EFA
C1/0EF5: CE 9C BC     DEC $BC9C       ; green
C1/0EF8: 80 03        BRA $0EFD
C1/0EFA: EE 9C BC     INC $BC9C
C1/0EFD: 46 88        LSR $88
C1/0EFF: 90 0F        BCC $0F10
C1/0F01: AD C9 DB     LDA $DBC9
C1/0F04: 29 04        AND #$04
C1/0F06: D0 05        BNE $0F0D
C1/0F08: CE 9D BC     DEC $BC9D       ; blue
C1/0F0B: 80 03        BRA $0F10
C1/0F0D: EE 9D BC     INC $BC9D
C1/0F10: 60           RTS 

C1/0F11: 02 0F 2E 16 20 38 3C 3D 33 34 35 1A 36 29 28 1F
C1/0F21: 2A 3A 0D 13 26 30 31 1B 2D 03 19 06 07 0B 00 04
C1/0F31: 05 17 3E 0C 01 0E 10 08 11 09 15 0A 12 2F 27 25
C1/0F41: 14 1E 22 32 2C 21 1D 23 24 3B 1C 2B 18 3F 37 39

; [  ]

C1/0F51: AD D0 DB     LDA $DBD0
C1/0F54: F0 6C        BEQ $0FC2
C1/0F56: AD 84 BC     LDA $BC84
C1/0F59: 09 01        ORA #$01
C1/0F5B: 8D 84 BC     STA $BC84
C1/0F5E: AD D2 DB     LDA $DBD2
C1/0F61: C9 40        CMP #$40
C1/0F63: F0 1D        BEQ $0F82
C1/0F65: AD D1 DB     LDA $DBD1
C1/0F68: AA           TAX 
C1/0F69: BF 11 0F C1  LDA $C10F11,X
C1/0F6D: EE D1 DB     INC $DBD1
C1/0F70: EE D2 DB     INC $DBD2
C1/0F73: C2 20        REP #$20
C1/0F75: 0A           ASL 
C1/0F76: 0A           ASL 
C1/0F77: AA           TAX 
C1/0F78: BD 37 A9     LDA $A937,X
C1/0F7B: 38           SEC 
C1/0F7C: E9 08 00     SBC #$0008
C1/0F7F: 9D 37 A9     STA $A937,X
C1/0F82: C2 20        REP #$20
C1/0F84: 7B           TDC 
C1/0F85: AA           TAX 
C1/0F86: A8           TAY 
C1/0F87: B9 37 A9     LDA $A937,Y
C1/0F8A: 29 FF 07     AND #$07FF
C1/0F8D: F0 0A        BEQ $0F99
C1/0F8F: 38           SEC 
C1/0F90: E9 08 00     SBC #$0008
C1/0F93: 99 37 A9     STA $A937,Y
C1/0F96: 4C 9A 0F     JMP $0F9A
C1/0F99: E8           INX 
C1/0F9A: AD 79 BC     LDA $BC79
C1/0F9D: 99 39 A9     STA $A939,Y
C1/0FA0: C8           INY 
C1/0FA1: C8           INY 
C1/0FA2: C8           INY 
C1/0FA3: C8           INY 
C1/0FA4: C0 00 01     CPY #$0100
C1/0FA7: D0 DE        BNE $0F87
C1/0FA9: 7B           TDC 
C1/0FAA: E2 20        SEP #$20
C1/0FAC: E0 40 00     CPX #$0040
C1/0FAF: D0 11        BNE $0FC2
C1/0FB1: 9C D0 DB     STZ $DBD0
C1/0FB4: 9C BA B3     STZ $B3BA
C1/0FB7: EE B8 B3     INC $B3B8
C1/0FBA: AD 84 BC     LDA $BC84
C1/0FBD: 29 FE        AND #$FE
C1/0FBF: 8D 84 BC     STA $BC84
C1/0FC2: 60           RTS 

; [ update underwater tower of walse bg ]

C1/0FC3: AD A5 DB     LDA $DBA5
C1/0FC6: 18           CLC 
C1/0FC7: 69 02        ADC #$02        ; oscillation period is 256/2 = 128 frames
C1/0FC9: 8D A5 DB     STA $DBA5
C1/0FCC: AA           TAX 
C1/0FCD: 7B           TDC 
C1/0FCE: A8           TAY 
C1/0FCF: A9 06        LDA #$06        ; amplitude 6 pixels
C1/0FD1: 4C E2 0F     JMP $0FE2

; [ update desert bg ]

C1/0FD4: AD A5 DB     LDA $DBA5
C1/0FD7: 18           CLC 
C1/0FD8: 69 02        ADC #$02        ; oscillation period is 256/2 = 128 frames
C1/0FDA: 8D A5 DB     STA $DBA5
C1/0FDD: AA           TAX 
C1/0FDE: 7B           TDC 
C1/0FDF: A8           TAY 
C1/0FE0: A9 03        LDA #$03        ; amplitude 3 pixels
C1/0FE2: 8F 1B 21 00  STA $00211B
C1/0FE6: A9 00        LDA #$00
C1/0FE8: 8F 1B 21 00  STA $00211B
C1/0FEC: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/0FF0: 8F 1C 21 00  STA $00211C
C1/0FF4: 8F 1C 21 00  STA $00211C
C1/0FF8: AF 35 21 00  LDA $002135
C1/0FFC: 99 B9 AC     STA $ACB9,Y     ; bg2 vertical scroll hdma data
C1/0FFF: AF 36 21 00  LDA $002136
C1/1003: 99 BA AC     STA $ACBA,Y
C1/1006: 8A           TXA 
C1/1007: 18           CLC 
C1/1008: 69 08        ADC #$08
C1/100A: AA           TAX 
C1/100B: C8           INY 
C1/100C: C8           INY 
C1/100D: C8           INY 
C1/100E: C8           INY 
C1/100F: C0 80 00     CPY #$0080
C1/1012: D0 D8        BNE $0FEC
C1/1014: 60           RTS 

; [ update battle bg $FF ??? ]

; maybe this is how the monster and bg fade in/out during the credits ???

C1/1015: AD A5 DB     LDA $DBA5
C1/1018: 18           CLC 
C1/1019: 69 02        ADC #$02        ; oscillation period is 256/2 = 128 frames
C1/101B: 8D A5 DB     STA $DBA5
C1/101E: AA           TAX 
C1/101F: 7B           TDC 
C1/1020: A8           TAY 
C1/1021: A9 06        LDA #$06
C1/1023: 8F 1B 21 00  STA $00211B
C1/1027: A9 00        LDA #$00
C1/1029: 8F 1B 21 00  STA $00211B
C1/102D: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/1031: 8F 1C 21 00  STA $00211C
C1/1035: 8F 1C 21 00  STA $00211C
C1/1039: C2 20        REP #$20
C1/103B: AF 35 21 00  LDA $002135
C1/103F: 99 B9 AC     STA $ACB9,Y
C1/1042: 99 39 A9     STA $A939,Y
C1/1045: 99 B9 A9     STA $A9B9,Y
C1/1048: 7B           TDC 
C1/1049: E2 20        SEP #$20
C1/104B: 8A           TXA 
C1/104C: 18           CLC 
C1/104D: 69 08        ADC #$08
C1/104F: AA           TAX 
C1/1050: C8           INY 
C1/1051: C8           INY 
C1/1052: C8           INY 
C1/1053: C8           INY 
C1/1054: C0 80 00     CPY #$0080
C1/1057: D0 D4        BNE $102D
C1/1059: 60           RTS 

; [ update battle bg $FE ??? ]

C1/105A: AD A5 DB     LDA $DBA5
C1/105D: 18           CLC 
C1/105E: 69 02        ADC #$02        ; oscillation period is 256/2 = 128 frames
C1/1060: 8D A5 DB     STA $DBA5
C1/1063: AA           TAX 
C1/1064: 7B           TDC 
C1/1065: A8           TAY 
C1/1066: DA           PHX 
C1/1067: 20 96 FC     JSR $FC96       ; generate random number
C1/106A: 29 03        AND #$03
C1/106C: 85 88        STA $88
C1/106E: 64 89        STZ $89
C1/1070: AD E7 DB     LDA $DBE7
C1/1073: 8F 1B 21 00  STA $00211B
C1/1077: AD E8 DB     LDA $DBE8
C1/107A: 8F 1B 21 00  STA $00211B
C1/107E: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/1082: 8F 1C 21 00  STA $00211C
C1/1086: 8F 1C 21 00  STA $00211C
C1/108A: C2 20        REP #$20
C1/108C: AF 35 21 00  LDA $002135
C1/1090: 99 B9 AC     STA $ACB9,Y
C1/1093: 99 39 A9     STA $A939,Y
C1/1096: 99 B9 A9     STA $A9B9,Y
C1/1099: 7B           TDC 
C1/109A: E2 20        SEP #$20
C1/109C: 8A           TXA 
C1/109D: 18           CLC 
C1/109E: 69 08        ADC #$08
C1/10A0: AA           TAX 
C1/10A1: C8           INY 
C1/10A2: C8           INY 
C1/10A3: C8           INY 
C1/10A4: C8           INY 
C1/10A5: C0 80 00     CPY #$0080
C1/10A8: D0 D4        BNE $107E
C1/10AA: FA           PLX 
C1/10AB: 7B           TDC 
C1/10AC: A8           TAY 
C1/10AD: AD E5 DB     LDA $DBE5
C1/10B0: 8F 1B 21 00  STA $00211B
C1/10B4: AD E6 DB     LDA $DBE6
C1/10B7: 8F 1B 21 00  STA $00211B
C1/10BB: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/10BF: 8F 1C 21 00  STA $00211C
C1/10C3: 8F 1C 21 00  STA $00211C
C1/10C7: C2 20        REP #$20
C1/10C9: AF 35 21 00  LDA $002135
C1/10CD: 18           CLC 
C1/10CE: 65 88        ADC $88
C1/10D0: 99 B7 AC     STA $ACB7,Y
C1/10D3: 99 37 A9     STA $A937,Y
C1/10D6: 99 B7 A9     STA $A9B7,Y
C1/10D9: 7B           TDC 
C1/10DA: E2 20        SEP #$20
C1/10DC: 8A           TXA 
C1/10DD: 18           CLC 
C1/10DE: 69 08        ADC #$08
C1/10E0: AA           TAX 
C1/10E1: C8           INY 
C1/10E2: C8           INY 
C1/10E3: C8           INY 
C1/10E4: C8           INY 
C1/10E5: C0 80 00     CPY #$0080
C1/10E8: D0 D1        BNE $10BB
C1/10EA: 60           RTS 

; [ update karnak castle bg ]

C1/10EB: AD A5 DB     LDA $DBA5
C1/10EE: 18           CLC 
C1/10EF: 69 04        ADC #$04        ; oscillation period is 256/4 = 64 frames
C1/10F1: 8D A5 DB     STA $DBA5
C1/10F4: AD A5 DB     LDA $DBA5
C1/10F7: AA           TAX 
C1/10F8: 7B           TDC 
C1/10F9: A8           TAY 
C1/10FA: A9 03        LDA #$03        ; amplitude 3 pixels
C1/10FC: 8F 1B 21 00  STA $00211B
C1/1100: A9 00        LDA #$00
C1/1102: 8F 1B 21 00  STA $00211B
C1/1106: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/110A: 8F 1C 21 00  STA $00211C
C1/110E: 8F 1C 21 00  STA $00211C
C1/1112: AF 35 21 00  LDA $002135
C1/1116: 99 B7 AC     STA $ACB7,Y     ; bg2 horizontal scroll hdma data
C1/1119: AF 36 21 00  LDA $002136
C1/111D: 99 B8 AC     STA $ACB8,Y
C1/1120: 8A           TXA 
C1/1121: 18           CLC 
C1/1122: 69 08        ADC #$08
C1/1124: AA           TAX 
C1/1125: C8           INY 
C1/1126: C8           INY 
C1/1127: C8           INY 
C1/1128: C8           INY 
C1/1129: C0 80 00     CPY #$0080
C1/112C: D0 D8        BNE $1106
C1/112E: 60           RTS 

; [  ]

C1/112F: AE F0 04     LDX $04F0
C1/1132: E0 D5 01     CPX #$01D5
C1/1135: D0 4E        BNE $1185
C1/1137: 7B           TDC 
C1/1138: AA           TAX 
C1/1139: A8           TAY 
C1/113A: 9C 87 7C     STZ $7C87
C1/113D: B9 43 CF     LDA $CF43,Y
C1/1140: D0 38        BNE $117A
C1/1142: B9 45 CF     LDA $CF45,Y
C1/1145: C9 60        CMP #$60
C1/1147: 90 1B        BCC $1164
C1/1149: FE A7 DB     INC $DBA7,X
C1/114C: BD A7 DB     LDA $DBA7,X
C1/114F: 29 07        AND #$07
C1/1151: D0 27        BNE $117A
C1/1153: BD AF DB     LDA $DBAF,X
C1/1156: F0 22        BEQ $117A
C1/1158: DE AF DB     DEC $DBAF,X
C1/115B: B9 45 CF     LDA $CF45,Y
C1/115E: 3A           DEC 
C1/115F: 99 45 CF     STA $CF45,Y
C1/1162: 80 16        BRA $117A
C1/1164: B9 43 CF     LDA $CF43,Y
C1/1167: 85 88        STA $88
C1/1169: B9 58 CF     LDA $CF58,Y
C1/116C: 05 88        ORA $88
C1/116E: D0 0A        BNE $117A
C1/1170: 8A           TXA 
C1/1171: 20 74 FC     JSR $FC74
C1/1174: 0D 87 7C     ORA $7C87
C1/1177: 8D 87 7C     STA $7C87
C1/117A: E8           INX 
C1/117B: 98           TYA 
C1/117C: 18           CLC 
C1/117D: 69 20        ADC #$20
C1/117F: A8           TAY 
C1/1180: C0 80 00     CPY #$0080
C1/1183: D0 B8        BNE $113D
C1/1185: 60           RTS 

; [  ]

C1/1186: AD 3A CD     LDA $CD3A
C1/1189: 0A           ASL 
C1/118A: AA           TAX 
C1/118B: BF 9B 11 C1  LDA $C1119B,X
C1/118F: 85 88        STA $88
C1/1191: BF 9C 11 C1  LDA $C1119C,X
C1/1195: 85 89        STA $89
C1/1197: 6C 88 00     JMP ($0088)
C1/119A: 60           RTS 

C1/119B:              .DW $119A, $4986, $49C4, $4A86, $4B22, $11E4, $53CE, $5C88
C1/11AB:              .DW $5BA3, $119A, $53CE, $55D0, $4759, $4735, $11D3, $51A5
C1/11BB:              .DW $51E9, $11C5, $4D80, $4CEF, $FD07

C1/11C5: AD 39 CD     LDA $CD39
C1/11C8: D0 08        BNE $11D2
C1/11CA: A9 1A        LDA #$1A
C1/11CC: 8D 39 CD     STA $CD39
C1/11CF: 4C 07 FD     JMP $FD07
C1/11D2: 60           RTS 

C1/11D3: 9C B0 41     STZ $41B0
C1/11D6: 9C B7 41     STZ $41B7
C1/11D9: 9C 41 CD     STZ $CD41
C1/11DC: A9 FF        LDA #$FF
C1/11DE: 8D 42 CD     STA $CD42
C1/11E1: 4C 07 FD     JMP $FD07

C1/11E4: AD 38 CD     LDA $CD38
C1/11E7: 0D 39 CD     ORA $CD39
C1/11EA: 0D 65 BC     ORA $BC65
C1/11ED: D0 05        BNE $11F4
C1/11EF: A9 14        LDA #$14
C1/11F1: 8D 3A CD     STA $CD3A
C1/11F4: 60           RTS 

; [ update bg scroll/mosaic registers ]

C1/11F5: AD 77 BC     LDA $BC77
C1/11F8: 8F 0D 21 00  STA $00210D     ; bg scroll registers
C1/11FC: AD 78 BC     LDA $BC78
C1/11FF: 8F 0D 21 00  STA $00210D
C1/1203: AD 79 BC     LDA $BC79
C1/1206: 8F 0E 21 00  STA $00210E
C1/120A: AD 7A BC     LDA $BC7A
C1/120D: 8F 0E 21 00  STA $00210E
C1/1211: AD 7B BC     LDA $BC7B
C1/1214: 8F 0F 21 00  STA $00210F
C1/1218: AD 7C BC     LDA $BC7C
C1/121B: 8F 0F 21 00  STA $00210F
C1/121F: AD 7D BC     LDA $BC7D
C1/1222: 8F 10 21 00  STA $002110
C1/1226: AD 7E BC     LDA $BC7E
C1/1229: 8F 10 21 00  STA $002110
C1/122D: AD 80 BC     LDA $BC80
C1/1230: 8F 06 21 00  STA $002106     ; screen mosaic register
C1/1234: 60           RTS 

C1/1235: 20 F5 11     JSR $11F5       ; update bg scroll/mosaic registers
C1/1238: 20 DD 12     JSR $12DD
C1/123B: AD 84 BC     LDA $BC84
C1/123E: 8F 0C 42 00  STA $00420C
C1/1242: AD 85 BC     LDA $BC85
C1/1245: 8F 31 21 00  STA $002131
C1/1249: 60           RTS 

; [  ]

C1/124A: 20 F5 11     JSR $11F5       ; update bg scroll/mosaic registers
C1/124D: AF D3 DB 7E  LDA $7EDBD3
C1/1251: F0 09        BEQ $125C

; credits
C1/1253: AD 85 BC     LDA $BC85
C1/1256: 8F 31 21 00  STA $002131
C1/125A: 80 55        BRA $12B1

; neo-exdeath
C1/125C: AD F2 04     LDA $04F2
C1/125F: C9 1F        CMP #$1F
C1/1261: D0 2F        BNE $1292       ; branch if not neo-exdeath
C1/1263: AD 85 BC     LDA $BC85
C1/1266: D0 2A        BNE $1292
C1/1268: AD 9B BC     LDA $BC9B
C1/126B: 09 20        ORA #$20
C1/126D: 8F 32 21 00  STA $002132
C1/1271: AD 9C BC     LDA $BC9C
C1/1274: 09 40        ORA #$40
C1/1276: 8F 32 21 00  STA $002132
C1/127A: AD 9D BC     LDA $BC9D
C1/127D: 09 80        ORA #$80
C1/127F: 8F 32 21 00  STA $002132
C1/1283: AD 9E BC     LDA $BC9E
C1/1286: 8D 9F BC     STA $BC9F
C1/1289: 8D 86 BC     STA $BC86
C1/128C: 8F 31 21 00  STA $002131
C1/1290: 80 1F        BRA $12B1

; normal
C1/1292: AD 88 BC     LDA $BC88
C1/1295: 8F 32 21 00  STA $002132
C1/1299: AD 89 BC     LDA $BC89
C1/129C: 8F 32 21 00  STA $002132
C1/12A0: AD 8A BC     LDA $BC8A
C1/12A3: 8F 32 21 00  STA $002132
C1/12A7: AD 85 BC     LDA $BC85
C1/12AA: 8D 86 BC     STA $BC86
C1/12AD: 8F 31 21 00  STA $002131
C1/12B1: AD 81 BC     LDA $BC81
C1/12B4: 8D 82 BC     STA $BC82
C1/12B7: 8F 05 21 00  STA $002105
C1/12BB: 20 82 14     JSR $1482
C1/12BE: AD C1 DB     LDA $DBC1
C1/12C1: 8D C2 DB     STA $DBC2
C1/12C4: 8F 08 21 00  STA $002108
C1/12C8: AD 84 BC     LDA $BC84
C1/12CB: 8F 0C 42 00  STA $00420C
C1/12CF: AD 8B BC     LDA $BC8B
C1/12D2: 8F 2D 21 00  STA $00212D
C1/12D6: AD 8C BC     LDA $BC8C
C1/12D9: 8F 30 21 00  STA $002130
C1/12DD: AD 8D BC     LDA $BC8D
C1/12E0: F0 03        BEQ $12E5
C1/12E2: 20 E8 12     JSR $12E8
C1/12E5: 4C D7 FC     JMP $FCD7

; [  ]

C1/12E8: AD 8E BC     LDA $BC8E
C1/12EB: 8F 1B 21 00  STA $00211B
C1/12EF: AD 8F BC     LDA $BC8F
C1/12F2: 8F 1B 21 00  STA $00211B
C1/12F6: AD 90 BC     LDA $BC90
C1/12F9: 8F 1C 21 00  STA $00211C
C1/12FD: AD 91 BC     LDA $BC91
C1/1300: 8F 1C 21 00  STA $00211C
C1/1304: AD 92 BC     LDA $BC92
C1/1307: 8F 1D 21 00  STA $00211D
C1/130B: AD 93 BC     LDA $BC93
C1/130E: 8F 1D 21 00  STA $00211D
C1/1312: AD 94 BC     LDA $BC94
C1/1315: 8F 1E 21 00  STA $00211E
C1/1319: AD 95 BC     LDA $BC95
C1/131C: 8F 1E 21 00  STA $00211E
C1/1320: AD 96 BC     LDA $BC96
C1/1323: 8F 1F 21 00  STA $00211F
C1/1327: AD 97 BC     LDA $BC97
C1/132A: 8F 1F 21 00  STA $00211F
C1/132E: AD 98 BC     LDA $BC98
C1/1331: 8F 20 21 00  STA $002120
C1/1335: AD 99 BC     LDA $BC99
C1/1338: 8F 20 21 00  STA $002120
C1/133C: 60           RTS 

; [ copy battle bg graphics to vram ]

C1/133D: AD 95 A8     LDA $A895       ; battle bg graphics vram transfer counter
C1/1340: 29 07        AND #$07        ; copy $0100 bytes per frame, 8 frames to update
C1/1342: 0A           ASL 
C1/1343: AA           TAX 
C1/1344: BF 6E 13 C1  LDA $C1136E,X
C1/1348: 85 8A        STA $8A
C1/134A: BF 6F 13 C1  LDA $C1136F,X
C1/134E: 85 8B        STA $8B
C1/1350: BF 7E 13 C1  LDA $C1137E,X
C1/1354: 85 8C        STA $8C
C1/1356: BF 7F 13 C1  LDA $C1137F,X
C1/135A: 85 8D        STA $8D
C1/135C: A2 00 01     LDX #$0100
C1/135F: 86 88        STX $88
C1/1361: A6 8A        LDX $8A
C1/1363: A4 8C        LDY $8C
C1/1365: A9 7E        LDA #$7E
C1/1367: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/136A: EE 95 A8     INC $A895
C1/136D: 60           RTS 

C1/136E: 09 88        ORA #$88
C1/1370: 09 89        ORA #$89
C1/1372: 09 8A        ORA #$8A
C1/1374: 09 8B        ORA #$8B
C1/1376: 09 8C        ORA #$8C
C1/1378: 09 8D        ORA #$8D
C1/137A: 09 8E        ORA #$8E
C1/137C: 09 8F        ORA #$8F

C1/137E: 00 08        BRK $08
C1/1380: 80 08        BRA $138A
C1/1382: 00 09        BRK $09
C1/1384: 80 09        BRA $138F
C1/1386: 00 0A        BRK $0A
C1/1388: 80 0A        BRA $1394
C1/138A: 00 0B        BRK $0B
C1/138C: 80 0B        BRA $1399

C1/138E: AD E3 DB     LDA $DBE3
C1/1391: F0 16        BEQ $13A9
C1/1393: A2 00 00     LDX #$0000
C1/1396: BD 55 B4     LDA $B455,X
C1/1399: C9 FF        CMP #$FF
C1/139B: F0 03        BEQ $13A0
C1/139D: FE 55 B4     INC $B455,X
C1/13A0: E8           INX 
C1/13A1: E0 E0 00     CPX #$00E0
C1/13A4: D0 F0        BNE $1396
C1/13A6: 9C E3 DB     STZ $DBE3
C1/13A9: A9 10        LDA #$10
C1/13AB: 85 8E        STA $8E
C1/13AD: A5 A2        LDA $A2
C1/13AF: 29 03        AND #$03
C1/13B1: 0A           ASL 
C1/13B2: 0A           ASL 
C1/13B3: 0A           ASL 
C1/13B4: 0A           ASL 
C1/13B5: 0A           ASL 
C1/13B6: AA           TAX 
C1/13B7: A5 A2        LDA $A2
C1/13B9: 0A           ASL 
C1/13BA: 0A           ASL 
C1/13BB: 0A           ASL 
C1/13BC: 29 C0        AND #$C0
C1/13BE: 85 8C        STA $8C
C1/13C0: BD 09 A8     LDA $A809,X
C1/13C3: C9 FF        CMP #$FF
C1/13C5: F0 12        BEQ $13D9
C1/13C7: 85 88        STA $88
C1/13C9: 29 C0        AND #$C0
C1/13CB: C5 8C        CMP $8C
C1/13CD: D0 03        BNE $13D2
C1/13CF: 20 DA 13     JSR $13DA
C1/13D2: E8           INX 
C1/13D3: E8           INX 
C1/13D4: C6 8E        DEC $8E
C1/13D6: 4C C0 13     JMP $13C0
C1/13D9: 60           RTS 

; [  ]

C1/13DA: DA           PHX 
C1/13DB: BD 09 A8     LDA $A809,X
C1/13DE: 29 3F        AND #$3F
C1/13E0: C2 20        REP #$20
C1/13E2: 0A           ASL 
C1/13E3: 0A           ASL 
C1/13E4: 0A           ASL 
C1/13E5: 0A           ASL 
C1/13E6: 0A           ASL 
C1/13E7: 18           CLC 
C1/13E8: 69 09 88     ADC #$8809
C1/13EB: 85 88        STA $88
C1/13ED: 7B           TDC 
C1/13EE: E2 20        SEP #$20
C1/13F0: BD 0A A8     LDA $A80A,X
C1/13F3: 29 3F        AND #$3F
C1/13F5: C2 20        REP #$20
C1/13F7: 0A           ASL 
C1/13F8: 0A           ASL 
C1/13F9: 0A           ASL 
C1/13FA: 0A           ASL 
C1/13FB: 0A           ASL 
C1/13FC: 85 8A        STA $8A
C1/13FE: 7B           TDC 
C1/13FF: E2 20        SEP #$20
C1/1401: BD 0A A8     LDA $A80A,X
C1/1404: 29 C0        AND #$C0
C1/1406: 4A           LSR 
C1/1407: 4A           LSR 
C1/1408: 4A           LSR 
C1/1409: 4A           LSR 
C1/140A: 4A           LSR 
C1/140B: AA           TAX 
C1/140C: BF 2C 14 C1  LDA $C1142C,X
C1/1410: 18           CLC 
C1/1411: 65 8A        ADC $8A
C1/1413: 85 8A        STA $8A
C1/1415: BF 2D 14 C1  LDA $C1142D,X
C1/1419: 65 8B        ADC $8B
C1/141B: 85 8B        STA $8B
C1/141D: A0 00 00     LDY #$0000
C1/1420: B1 8A        LDA ($8A),Y
C1/1422: 91 88        STA ($88),Y
C1/1424: C8           INY 
C1/1425: C0 20 00     CPY #$0020
C1/1428: D0 F6        BNE $1420
C1/142A: FA           PLX 
C1/142B: 60           RTS 

; pointers to battle bg graphics buffers
C1/142C:              .DW $9009, $9809, $A009, $A009

C1/1434: A0 00 00     LDY #$0000
C1/1437: BB           TYX 
C1/1438: BF 26 B1 C1  LDA $C1B126,X
C1/143C: AA           TAX 
C1/143D: BD 45 CF     LDA $CF45,X
C1/1440: 18           CLC 
C1/1441: 7D 49 CF     ADC $CF49,X
C1/1444: 99 1E D0     STA $D01E,Y
C1/1447: 38           SEC 
C1/1448: E9 10        SBC #$10
C1/144A: 99 56 D0     STA $D056,Y
C1/144D: B9 22 D0     LDA $D022,Y
C1/1450: 99 62 D0     STA $D062,Y
C1/1453: 99 92 D0     STA $D092,Y
C1/1456: 18           CLC 
C1/1457: 69 0C        ADC #$0C
C1/1459: 99 4A D0     STA $D04A,Y
C1/145C: 18           CLC 
C1/145D: 69 0C        ADC #$0C
C1/145F: 99 7A D0     STA $D07A,Y
C1/1462: BD 46 CF     LDA $CF46,X
C1/1465: 18           CLC 
C1/1466: 7D 4A CF     ADC $CF4A,X
C1/1469: 99 62 D0     STA $D062,Y
C1/146C: B9 1E D0     LDA $D01E,Y
C1/146F: 18           CLC 
C1/1470: 69 08        ADC #$08
C1/1472: 99 3E D0     STA $D03E,Y
C1/1475: 99 6E D0     STA $D06E,Y
C1/1478: 99 86 D0     STA $D086,Y
C1/147B: C8           INY 
C1/147C: C0 04 00     CPY #$0004
C1/147F: D0 B6        BNE $1437
C1/1481: 60           RTS 

; [  ]

C1/1482: AD B8 B3     LDA $B3B8
C1/1485: F0 62        BEQ $14E9
C1/1487: AD BA B3     LDA $B3BA
C1/148A: 0A           ASL 
C1/148B: AA           TAX 
C1/148C: BF ED 14 C1  LDA $C114ED,X
C1/1490: 85 88        STA $88
C1/1492: BF EE 14 C1  LDA $C114EE,X
C1/1496: 85 89        STA $89
C1/1498: AD BB B3     LDA $B3BB
C1/149B: 0A           ASL 
C1/149C: AA           TAX 
C1/149D: BF ED 14 C1  LDA $C114ED,X
C1/14A1: 85 8C        STA $8C
C1/14A3: BF EE 14 C1  LDA $C114EE,X
C1/14A7: 85 8D        STA $8D
C1/14A9: A9 C1        LDA #$C1
C1/14AB: 85 8A        STA $8A
C1/14AD: 85 8E        STA $8E
C1/14AF: A0 00 00     LDY #$0000
C1/14B2: B7 88        LDA [$88],Y
C1/14B4: 99 97 A8     STA $A897,Y     ; copy to bg1 scroll hdma table
C1/14B7: C8           INY 
C1/14B8: C0 19 00     CPY #$0019
C1/14BB: D0 F5        BNE $14B2
C1/14BD: A0 00 00     LDY #$0000
C1/14C0: B7 8C        LDA [$8C],Y
C1/14C2: 99 B0 A8     STA $A8B0,Y     ; copy to bg2 scroll hdma table
C1/14C5: C8           INY 
C1/14C6: C0 80 00     CPY #$0080
C1/14C9: D0 F5        BNE $14C0
C1/14CB: C2 20        REP #$20
C1/14CD: AD BE B3     LDA $B3BE
C1/14D0: 0A           ASL 
C1/14D1: 0A           ASL 
C1/14D2: 85 88        STA $88
C1/14D4: AD B1 A8     LDA $A8B1
C1/14D7: 18           CLC 
C1/14D8: 65 88        ADC $88
C1/14DA: 8D B1 A8     STA $A8B1
C1/14DD: AD B4 A8     LDA $A8B4
C1/14E0: 18           CLC 
C1/14E1: 65 88        ADC $88
C1/14E3: 8D B4 A8     STA $A8B4
C1/14E6: 7B           TDC 
C1/14E7: E2 20        SEP #$20
C1/14E9: 9C B8 B3     STZ $B3B8
C1/14EC: 60           RTS 

; pointers to bg scroll hdma data
C1/14ED:              .DW $1596, $1507, $151A, $14F9, $1500, $1596

; credits (bg1)
C1/14F9: F0 37 A9
C1/14FC: F0 F7 AA
C1/14FF: 80

; credits (bg2)
C1/1500: F0 B7 AC
C1/1503: F0 77 AE
C1/1506: 80

; normal (bg2)
C1/1507: A0 B7 AC
C1/150A: A0 B7 AC
C1/150D: A0 B7 AC
C1/1510: A0 B7 AC
C1/1513: A0 B7 AC
C1/1516: C0 37 AF
C1/1519: 80

; neo exdeath (bg2)
C1/151A: 04 B7 AC
C1/151D: 04 C7 AC
C1/1520: 04 D7 AC
C1/1523: 04 E7 AC
C1/1526: 04 F7 AC
C1/1529: 04 07 AD
C1/152C: 04 17 AD
C1/152F: 04 27 AD
C1/1532: 04 37 AD
C1/1536: 04 47 AD
C1/1538: 04 57 AD
C1/153B: 04 67 AD
C1/153E: 04 77 AD
C1/1541: 04 87 AD
C1/1544: 04 97 AD
C1/1547: 04 A7 AD
C1/154A: 04 B7 AD
C1/154D: 04 C7 AD
C1/1550: 04 D7 AD
C1/1553: 04 E7 AD
C1/1556: 04 F7 AD
C1/1559: 04 07 AE
C1/155C: 04 17 AE
C1/155F: 04 27 AE
C1/1562: 04 37 AE
C1/1565: 04 47 AE
C1/1568: 04 57 AE
C1/156B: 04 67 AE
C1/156E: 04 77 AE
C1/1571: 04 87 AE
C1/1574: 04 97 AE
C1/1577: 04 A7 AE
C1/157A: 04 B7 AE
C1/157D: 04 C7 AE
C1/1580: 04 D7 AE
C1/1583: 04 E7 AE
C1/1586: 04 F7 AE
C1/1589: 04 07 AF
C1/158C: 04 17 AF
C1/158F: 04 27 AF
C1/1592: C0 37 AF
C1/1595: 80

; normal (bg1)
C1/1596: A0 37 A9
C1/1599: A0 B7 A9
C1/159C: A0 37 A9
C1/159F: A0 B7 A9
C1/15A2: A0 37 A9
C1/15A5: C0 B7 AB
C1/15A8: 80

; unused (bg1)
C1/15A9: A0 37 A9
C1/15AC: A0 B7 A9
C1/15AF: A0 37 AA
C1/15B2: A0 B7 AA
C1/15B5: A0 37 AB
C1/15B8: C0 B7 AB
C1/15BB: 80

C1/15BC: 01
C1/15BD: 02 02        COP $02
C1/15BF: 02 02        COP $02
C1/15C1: 02 03        COP $03
C1/15C3: 04 DC        TSB $DC
C1/15C5: D3 F5        CMP ($F5,S),Y
C1/15C7: DD D9 05     CMP $05D9,X
C1/15CA: 06 07        ASL $07
C1/15CC: 07 07        ORA [$07]
C1/15CE: 07 07        ORA [$07]
C1/15D0: 08           PHP 

; [  ]

C1/15D1: AD 94 7C     LDA $7C94
C1/15D4: C9 02        CMP #$02
C1/15D6: D0 53        BNE $162B
C1/15D8: A5 F6        LDA $F6
C1/15DA: D0 05        BNE $15E1
C1/15DC: A2 21 4A     LDX #$4A21
C1/15DF: 80 03        BRA $15E4
C1/15E1: A2 38 4A     LDX #$4A38
C1/15E4: 86 88        STX $88
C1/15E6: AD 6E 7C     LDA $7C6E
C1/15E9: 8D B2 F9     STA $F9B2
C1/15EC: AD 6F 7C     LDA $7C6F
C1/15EF: 8D B4 F9     STA $F9B4
C1/15F2: AD 70 7C     LDA $7C70
C1/15F5: 8D B8 F9     STA $F9B8
C1/15F8: AD 71 7C     LDA $7C71
C1/15FB: 8D BA F9     STA $F9BA
C1/15FE: A2 00 00     LDX #$0000
C1/1601: C2 20        REP #$20
C1/1603: A5 88        LDA $88
C1/1605: 8F 16 21 00  STA $002116
C1/1609: A9 07 00     LDA #$0007
C1/160C: 85 8A        STA $8A
C1/160E: BD A2 F9     LDA $F9A2,X
C1/1611: 8F 18 21 00  STA $002118
C1/1615: E8           INX 
C1/1616: E8           INX 
C1/1617: C6 8A        DEC $8A
C1/1619: D0 F3        BNE $160E
C1/161B: A5 88        LDA $88
C1/161D: 18           CLC 
C1/161E: 69 20 00     ADC #$0020
C1/1621: 85 88        STA $88
C1/1623: E0 2A 00     CPX #$002A
C1/1626: D0 DB        BNE $1603
C1/1628: 7B           TDC 
C1/1629: E2 20        SEP #$20
C1/162B: 60           RTS 

C1/162C: A2 4D 49     LDX #$494D
C1/162F: 86 88        STX $88
C1/1631: AD 99 DB     LDA $DB99
C1/1634: F0 66        BEQ $169C
C1/1636: 9C 99 DB     STZ $DB99
C1/1639: C9 01        CMP #$01
C1/163B: F0 2C        BEQ $1669
C1/163D: A2 00 00     LDX #$0000
C1/1640: C2 20        REP #$20
C1/1642: A5 88        LDA $88
C1/1644: 8F 16 21 00  STA $002116
C1/1648: A9 07 00     LDA #$0007
C1/164B: 85 8A        STA $8A
C1/164D: 7B           TDC 
C1/164E: 8F 18 21 00  STA $002118
C1/1652: E8           INX 
C1/1653: C6 8A        DEC $8A
C1/1655: D0 F7        BNE $164E
C1/1657: A5 88        LDA $88
C1/1659: 18           CLC 
C1/165A: 69 20 00     ADC #$0020
C1/165D: 85 88        STA $88
C1/165F: E0 15 00     CPX #$0015
C1/1662: D0 DE        BNE $1642
C1/1664: 7B           TDC 
C1/1665: E2 20        SEP #$20
C1/1667: 80 33        BRA $169C
C1/1669: A2 00 00     LDX #$0000
C1/166C: C2 20        REP #$20
C1/166E: A5 88        LDA $88
C1/1670: 8F 16 21 00  STA $002116
C1/1674: A9 07 00     LDA #$0007
C1/1677: 85 8A        STA $8A
C1/1679: BF BC 15 C1  LDA $C115BC,X
C1/167D: 29 FF 00     AND #$00FF
C1/1680: 09 00 20     ORA #$2000
C1/1683: 8F 18 21 00  STA $002118
C1/1687: E8           INX 
C1/1688: C6 8A        DEC $8A
C1/168A: D0 ED        BNE $1679
C1/168C: A5 88        LDA $88
C1/168E: 18           CLC 
C1/168F: 69 20 00     ADC #$0020
C1/1692: 85 88        STA $88
C1/1694: E0 15 00     CPX #$0015
C1/1697: D0 D5        BNE $166E
C1/1699: 7B           TDC 
C1/169A: E2 20        SEP #$20
C1/169C: 60           RTS 

C1/169D: AD 9B DB     LDA $DB9B
C1/16A0: F0 09        BEQ $16AB
C1/16A2: A5 03        LDA $03
C1/16A4: 29 10        AND #$10
C1/16A6: D0 39        BNE $16E1
C1/16A8: 9C 9B DB     STZ $DB9B
C1/16AB: A5 03        LDA $03
C1/16AD: 29 10        AND #$10
C1/16AF: F0 30        BEQ $16E1
C1/16B1: A9 01        LDA #$01
C1/16B3: 8D 9B DB     STA $DB9B
C1/16B6: AD 98 DB     LDA $DB98
C1/16B9: D0 13        BNE $16CE
C1/16BB: A9 F6        LDA #$F6
C1/16BD: 8D 00 1D     STA $1D00
C1/16C0: 22 04 00 C4  JSL $C40004
C1/16C4: A9 01        LDA #$01
C1/16C6: 8D 99 DB     STA $DB99
C1/16C9: EE 98 DB     INC $DB98
C1/16CC: 80 1F        BRA $16ED
C1/16CE: A9 F7        LDA #$F7
C1/16D0: 8D 00 1D     STA $1D00
C1/16D3: 22 04 00 C4  JSL $C40004
C1/16D7: A9 02        LDA #$02
C1/16D9: 8D 99 DB     STA $DB99
C1/16DC: 9C 98 DB     STZ $DB98
C1/16DF: 80 05        BRA $16E6
C1/16E1: AD 98 DB     LDA $DB98
C1/16E4: F0 07        BEQ $16ED
C1/16E6: A9 01        LDA #$01
C1/16E8: 8D 9A DB     STA $DB9A
C1/16EB: 18           CLC 
C1/16EC: 60           RTS 
C1/16ED: 9C 9A DB     STZ $DB9A
C1/16F0: 38           SEC 
C1/16F1: 60           RTS 

; [  ]

C1/16F2: AD C0 B3     LDA $B3C0
C1/16F5: F0 13        BEQ $170A
C1/16F7: A2 80 00     LDX #$0080
C1/16FA: 86 88        STX $88
C1/16FC: A2 C4 B3     LDX #$B3C4
C1/16FF: A0 00 48     LDY #$4800
C1/1702: A9 7E        LDA #$7E
C1/1704: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/1707: 9C C0 B3     STZ $B3C0
C1/170A: 60           RTS 

; [  ]

C1/170B: AD 52 7C     LDA $7C52
C1/170E: 0D 98 DB     ORA $DB98
C1/1711: F0 01        BEQ $1714
C1/1713: 60           RTS 
C1/1714: AD 94 7C     LDA $7C94
C1/1717: C9 02        CMP #$02
C1/1719: D0 F8        BNE $1713
C1/171B: AD 95 7C     LDA $7C95
C1/171E: 0D 96 7C     ORA $7C96
C1/1721: F0 F0        BEQ $1713
C1/1723: C2 20        REP #$20
C1/1725: CE 95 7C     DEC $7C95
C1/1728: A2 07 00     LDX #$0007
C1/172B: AD 95 7C     LDA $7C95
C1/172E: C9 2C 01     CMP #$012C
C1/1731: F0 25        BEQ $1758
C1/1733: CA           DEX 
C1/1734: C9 58 02     CMP #$0258
C1/1737: F0 1F        BEQ $1758
C1/1739: CA           DEX 
C1/173A: C9 B0 04     CMP #$04B0
C1/173D: F0 19        BEQ $1758
C1/173F: CA           DEX 
C1/1740: C9 08 07     CMP #$0708
C1/1743: F0 13        BEQ $1758
C1/1745: CA           DEX 
C1/1746: C9 60 09     CMP #$0960
C1/1749: F0 0D        BEQ $1758
C1/174B: CA           DEX 
C1/174C: C9 B8 0B     CMP #$0BB8
C1/174F: F0 07        BEQ $1758
C1/1751: CA           DEX 
C1/1752: C9 10 0E     CMP #$0E10
C1/1755: F0 01        BEQ $1758
C1/1757: CA           DEX 
C1/1758: 7B           TDC 
C1/1759: E2 20        SEP #$20
C1/175B: 8A           TXA 
C1/175C: F0 0C        BEQ $176A
C1/175E: 8D 01 1D     STA $1D01
C1/1761: A9 87        LDA #$87        ; set tempo multiplier
C1/1763: 8D 00 1D     STA $1D00
C1/1766: 22 04 00 C4  JSL $C40004
C1/176A: A5 A2        LDA $A2
C1/176C: 29 1F        AND #$1F
C1/176E: D0 53        BNE $17C3
C1/1770: AE 95 7C     LDX $7C95
C1/1773: 86 98        STX $98
C1/1775: A2 3C 00     LDX #$003C
C1/1778: 86 9A        STX $9A
C1/177A: 20 19 FE     JSR $FE19
C1/177D: A6 9C        LDX $9C
C1/177F: 86 98        STX $98
C1/1781: A2 3C 00     LDX #$003C
C1/1784: 86 9A        STX $9A
C1/1786: 20 19 FE     JSR $FE19
C1/1789: A6 9E        LDX $9E
C1/178B: DA           PHX 
C1/178C: A6 9C        LDX $9C
C1/178E: 86 98        STX $98
C1/1790: A2 0A 00     LDX #$000A
C1/1793: 86 9A        STX $9A
C1/1795: 20 19 FE     JSR $FE19
C1/1798: A5 9C        LDA $9C
C1/179A: 18           CLC 
C1/179B: 69 53        ADC #$53
C1/179D: 8D 6E 7C     STA $7C6E
C1/17A0: A5 9E        LDA $9E
C1/17A2: 18           CLC 
C1/17A3: 69 53        ADC #$53
C1/17A5: 8D 6F 7C     STA $7C6F
C1/17A8: FA           PLX 
C1/17A9: 86 98        STX $98
C1/17AB: A2 0A 00     LDX #$000A
C1/17AE: 86 9A        STX $9A
C1/17B0: 20 19 FE     JSR $FE19
C1/17B3: A5 9C        LDA $9C
C1/17B5: 18           CLC 
C1/17B6: 69 53        ADC #$53
C1/17B8: 8D 70 7C     STA $7C70
C1/17BB: A5 9E        LDA $9E
C1/17BD: 18           CLC 
C1/17BE: 69 53        ADC #$53
C1/17C0: 8D 71 7C     STA $7C71
C1/17C3: 60           RTS 

C1/17C4: AD 98 DB     LDA $DB98
C1/17C7: D0 0D        BNE $17D6
C1/17C9: C2 20        REP #$20
C1/17CB: EE 6E DB     INC $DB6E
C1/17CE: D0 03        BNE $17D3
C1/17D0: EE 70 DB     INC $DB70
C1/17D3: 7B           TDC 
C1/17D4: E2 20        SEP #$20
C1/17D6: 60           RTS 

C1/17D7: AD 00 FF     LDA $FF00
C1/17DA: F0 13        BEQ $17EF
C1/17DC: A2 80 00     LDX #$0080
C1/17DF: 86 88        STX $88
C1/17E1: A2 B1 BC     LDX #$BCB1
C1/17E4: AC 01 FF     LDY $FF01
C1/17E7: A9 7E        LDA #$7E
C1/17E9: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/17EC: 9C 00 FF     STZ $FF00
C1/17EF: 60           RTS 

; [  ]

C1/17F0: 20 35 12     JSR $1235
C1/17F3: 20 9C FD     JSR $FD9C
C1/17F6: AD 81 BC     LDA $BC81
C1/17F9: 8F 05 21 00  STA $002105
C1/17FD: AD FB FE     LDA $FEFB
C1/1800: 8F 2C 21 00  STA $00212C
C1/1804: AD 7F BC     LDA $BC7F
C1/1807: 8F 00 21 00  STA $002100
C1/180B: A6 A2        LDX $A2
C1/180D: E8           INX 
C1/180E: 86 A2        STX $A2
C1/1810: 64 A5        STZ $A5
C1/1812: 64 A4        STZ $A4
C1/1814: 60           RTS 

C1/1815: 20 35 12     JSR $1235
C1/1818: 20 9C FD     JSR $FD9C
C1/181B: 20 3D 13     JSR $133D
C1/181E: 20 D7 17     JSR $17D7
C1/1821: A9 09        LDA #$09
C1/1823: 8F 05 21 00  STA $002105
C1/1827: A9 00        LDA #$00
C1/1829: 8F 25 21 00  STA $002125
C1/182D: AD FB FE     LDA $FEFB
C1/1830: 8F 2C 21 00  STA $00212C
C1/1834: A9 08        LDA #$08
C1/1836: 8F 26 21 00  STA $002126
C1/183A: A9 F7        LDA #$F7
C1/183C: 8F 27 21 00  STA $002127
C1/1840: AD FC FE     LDA $FEFC
C1/1843: 8F 11 21 00  STA $002111
C1/1847: AD FD FE     LDA $FEFD
C1/184A: 8F 11 21 00  STA $002111
C1/184E: AD FE FE     LDA $FEFE
C1/1851: 8F 12 21 00  STA $002112
C1/1855: AD FF FE     LDA $FEFF
C1/1858: 8F 12 21 00  STA $002112
C1/185C: A9 5A        LDA #$5A
C1/185E: 8F 07 21 00  STA $002107
C1/1862: A9 4A        LDA #$4A
C1/1864: 8F 09 21 00  STA $002109
C1/1868: AD 7F BC     LDA $BC7F
C1/186B: 8F 00 21 00  STA $002100
C1/186F: 20 8E 13     JSR $138E
C1/1872: 20 09 33     JSR $3309
C1/1875: A6 A2        LDX $A2
C1/1877: E8           INX 
C1/1878: 86 A2        STX $A2
C1/187A: 64 A5        STZ $A5
C1/187C: 64 A4        STZ $A4
C1/187E: 60           RTS 

; [  ]

C1/187F: 20 4A 12     JSR $124A
C1/1882: 20 9C FD     JSR $FD9C
C1/1885: AD 7F BC     LDA $BC7F
C1/1888: 8F 00 21 00  STA $002100
C1/188C: A2 00 00     LDX #$0000
C1/188F: BF 00 77 7F  LDA $7F7700,X
C1/1893: 9D 00 02     STA $0200,X
C1/1896: E8           INX 
C1/1897: E0 00 01     CPX #$0100
C1/189A: D0 F3        BNE $188F
C1/189C: 7B           TDC 
C1/189D: AA           TAX 
C1/189E: A9 00        LDA #$00
C1/18A0: 9D 00 04     STA $0400,X
C1/18A3: E8           INX 
C1/18A4: E0 10 00     CPX #$0010
C1/18A7: D0 F7        BNE $18A0
C1/18A9: 64 A5        STZ $A5
C1/18AB: 64 A4        STZ $A4
C1/18AD: 60           RTS 

; [  ]

C1/18AE: 20 4A 12     JSR $124A
C1/18B1: 20 9C FD     JSR $FD9C
C1/18B4: AD 7F BC     LDA $BC7F
C1/18B7: 8F 00 21 00  STA $002100
C1/18BB: 7B           TDC 
C1/18BC: AA           TAX 
C1/18BD: BF 00 77 7F  LDA $7F7700,X
C1/18C1: 9D 00 02     STA $0200,X
C1/18C4: 9E 00 03     STZ $0300,X
C1/18C7: E8           INX 
C1/18C8: E0 00 01     CPX #$0100
C1/18CB: D0 F0        BNE $18BD
C1/18CD: 64 A5        STZ $A5
C1/18CF: 64 A4        STZ $A4
C1/18D1: 60           RTS 

; [ normal battle nmi ??? ]

C1/18D2: 20 4A 12     JSR $124A
C1/18D5: 20 9C FD     JSR $FD9C
C1/18D8: 20 3D 13     JSR $133D
C1/18DB: 20 68 4A     JSR $4A68
C1/18DE: 20 4F 4A     JSR $4A4F
C1/18E1: 20 5B 55     JSR $555B
C1/18E4: 20 F2 16     JSR $16F2
C1/18E7: 20 05 4A     JSR $4A05
C1/18EA: 20 25 1D     JSR $1D25
C1/18ED: 20 A8 AC     JSR $ACA8
C1/18F0: 20 D1 15     JSR $15D1
C1/18F3: 20 2C 16     JSR $162C
C1/18F6: AD 7F BC     LDA $BC7F
C1/18F9: 8F 00 21 00  STA $002100
C1/18FD: 20 F4 FF     JSR $FFF4
C1/1900: 20 A4 0B     JSR $0BA4
C1/1903: AD B3 DB     LDA $DBB3
C1/1906: D0 0D        BNE $1915
C1/1908: AD D3 DB     LDA $DBD3
C1/190B: D0 08        BNE $1915
C1/190D: 20 9D 16     JSR $169D
C1/1910: B0 03        BCS $1915
C1/1912: 4C D4 19     JMP $19D4
C1/1915: 20 8E 13     JSR $138E
C1/1918: 20 09 33     JSR $3309
C1/191B: 20 79 79     JSR $7979
C1/191E: 20 86 11     JSR $1186
C1/1921: 20 D7 62     JSR $62D7
C1/1924: 20 FE 78     JSR $78FE       ; update screen flash
C1/1927: 20 0B 17     JSR $170B
C1/192A: AD 60 DB     LDA $DB60
C1/192D: D0 12        BNE $1941
C1/192F: 20 D3 70     JSR $70D3
C1/1932: 20 D5 6F     JSR $6FD5
C1/1935: 20 7C 66     JSR $667C
C1/1938: 20 34 14     JSR $1434
C1/193B: 20 2F 11     JSR $112F
C1/193E: 20 51 0F     JSR $0F51
C1/1941: 20 F0 5F     JSR $5FF0
C1/1944: AD 72 DB     LDA $DB72
C1/1947: D0 14        BNE $195D
C1/1949: 20 B0 64     JSR $64B0
C1/194C: AD 60 DB     LDA $DB60
C1/194F: D0 0C        BNE $195D
C1/1951: 20 E4 67     JSR $67E4
C1/1954: 20 F1 68     JSR $68F1
C1/1957: 20 58 6C     JSR $6C58
C1/195A: 20 2A B1     JSR $B12A
C1/195D: 20 CC 5F     JSR $5FCC
C1/1960: 20 92 5F     JSR $5F92
C1/1963: 20 33 65     JSR $6533
C1/1966: 20 D4 6C     JSR $6CD4       ; update damage numeral sprites
C1/1969: 20 C3 61     JSR $61C3
C1/196C: AD BB DB     LDA $DBBB
C1/196F: D0 1C        BNE $198D
C1/1971: A5 04        LDA $04
C1/1973: 29 30        AND #$30
C1/1975: C9 30        CMP #$30
C1/1977: D0 14        BNE $198D       ; branch if l+r not pressed
C1/1979: 20 6B 70     JSR $706B
C1/197C: AD E8 7B     LDA $7BE8
C1/197F: 30 17        BMI $1998       ; branch if exit spell was used
C1/1981: AD 52 7C     LDA $7C52
C1/1984: D0 0F        BNE $1995       ; branch if battle paused (menu open + wait mode)
C1/1986: A9 01        LDA #$01
C1/1988: 8D E8 7B     STA $7BE8       ; party is trying to run
C1/198B: 80 0B        BRA $1998
C1/198D: 20 5C 70     JSR $705C
C1/1990: AD E8 7B     LDA $7BE8
C1/1993: 30 03        BMI $1998
C1/1995: 9C E8 7B     STZ $7BE8
C1/1998: A6 A2        LDX $A2
C1/199A: E8           INX 
C1/199B: 86 A2        STX $A2
C1/199D: AD 3A CD     LDA $CD3A
C1/19A0: D0 32        BNE $19D4
C1/19A2: AD 41 CD     LDA $CD41
C1/19A5: 0D 35 CD     ORA $CD35
C1/19A8: F0 2A        BEQ $19D4
C1/19AA: AD F8 CD     LDA $CDF8
C1/19AD: D0 25        BNE $19D4
C1/19AF: 20 6E 48     JSR $486E
C1/19B2: AD 74 09     LDA $0974
C1/19B5: 30 03        BMI $19BA       ; branch if multi-controller
C1/19B7: 7B           TDC             ; cursor sound effect 0 (player 1)
C1/19B8: 80 0B        BRA $19C5
C1/19BA: AD 42 CD     LDA $CD42
C1/19BD: AA           TAX 
C1/19BE: BD 84 09     LDA $0984,X
C1/19C1: F0 02        BEQ $19C5
C1/19C3: A9 01        LDA #$01        ; cursor sound effect 1 (player 2)
C1/19C5: 18           CLC 
C1/19C6: 69 18        ADC #$18
C1/19C8: 8D 00 1D     STA $1D00
C1/19CB: AD B3 DB     LDA $DBB3
C1/19CE: D0 04        BNE $19D4
C1/19D0: 22 04 00 C4  JSL $C40004     ; execute spc interrupt
C1/19D4: AD B3 DB     LDA $DBB3
C1/19D7: D0 09        BNE $19E2
C1/19D9: 20 05 FC     JSR $FC05       ; play queued game sound effect/set volume
C1/19DC: 20 44 FC     JSR $FC44       ; play queued system sound effect
C1/19DF: 20 81 0B     JSR $0B81       ; play queued song
C1/19E2: 64 A5        STZ $A5         ; clear vblank flag
C1/19E4: 64 A4        STZ $A4
C1/19E6: 4C C4 17     JMP $17C4

; [ battle irq ]

C1/19E9: 40           RTI 

; [ battle nmi ]

C1/19EA: 08           PHP 
C1/19EB: C2 30        REP #$30
C1/19ED: 48           PHA 
C1/19EE: DA           PHX 
C1/19EF: 5A           PHY 
C1/19F0: 8B           PHB 
C1/19F1: 0B           PHD 
C1/19F2: A2 00 00     LDX #$0000
C1/19F5: DA           PHX 
C1/19F6: 2B           PLD 
C1/19F7: 7B           TDC 
C1/19F8: E2 20        SEP #$20
C1/19FA: AF 10 42 00  LDA $004210
C1/19FE: A9 7E        LDA #$7E
C1/1A00: 48           PHA 
C1/1A01: AB           PLB 
C1/1A02: A5 A4        LDA $A4
C1/1A04: D0 48        BNE $1A4E
C1/1A06: E6 A4        INC $A4
C1/1A08: AF 3F 21 00  LDA $00213F
C1/1A0C: A9 00        LDA #$00
C1/1A0E: 8F 00 21 00  STA $002100
C1/1A12: 20 C0 FD     JSR $FDC0
C1/1A15: 20 C5 FD     JSR $FDC5
C1/1A18: AD F5 DB     LDA $DBF5
C1/1A1B: F0 2E        BEQ $1A4B
C1/1A1D: C9 01        CMP #$01
C1/1A1F: F0 24        BEQ $1A45
C1/1A21: C9 02        CMP #$02
C1/1A23: F0 1A        BEQ $1A3F
C1/1A25: C9 03        CMP #$03
C1/1A27: F0 10        BEQ $1A39
C1/1A29: C9 04        CMP #$04
C1/1A2B: F0 06        BEQ $1A33
C1/1A2D: 20 DC FA     JSR $FADC
C1/1A30: 4C 4E 1A     JMP $1A4E
C1/1A33: 20 F0 17     JSR $17F0
C1/1A36: 4C 4E 1A     JMP $1A4E
C1/1A39: 20 AE 18     JSR $18AE
C1/1A3C: 4C 4E 1A     JMP $1A4E
C1/1A3F: 20 7F 18     JSR $187F
C1/1A42: 4C 4E 1A     JMP $1A4E
C1/1A45: 20 15 18     JSR $1815
C1/1A48: 4C 4E 1A     JMP $1A4E
C1/1A4B: 20 D2 18     JSR $18D2
C1/1A4E: C2 30        REP #$30
C1/1A50: 2B           PLD 
C1/1A51: AB           PLB 
C1/1A52: 7A           PLY 
C1/1A53: FA           PLX 
C1/1A54: 68           PLA 
C1/1A55: 28           PLP 
C1/1A56: 40           RTI 

C1/1A57: A2 00 02     LDX #$0200
C1/1A5A: 86 70        STX $70
C1/1A5C: A2 03 E0     LDX #$E003
C1/1A5F: A9 D0        LDA #$D0
C1/1A61: A0 00 01     LDY #$0100
C1/1A64: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/1A67: A2 0A 00     LDX #$000A
C1/1A6A: 86 70        STX $70
C1/1A6C: A2 50 9E     LDX #$9E50
C1/1A6F: A0 10 00     LDY #$0010
C1/1A72: A9 D4        LDA #$D4
C1/1A74: 4C A2 FC     JMP $FCA2
C1/1A77: DA           PHX 
C1/1A78: 5A           PHY 
C1/1A79: 85 81        STA $81
C1/1A7B: C2 20        REP #$20
C1/1A7D: 7B           TDC 
C1/1A7E: A8           TAY 
C1/1A7F: B9 70 00     LDA $0070,Y
C1/1A82: 48           PHA 
C1/1A83: C8           INY 
C1/1A84: C8           INY 
C1/1A85: C0 0C 00     CPY #$000C
C1/1A88: D0 F5        BNE $1A7F
C1/1A8A: 7B           TDC 
C1/1A8B: E2 20        SEP #$20
C1/1A8D: 20 EB 1C     JSR $1CEB
C1/1A90: 20 2A 8B     JSR $8B2A
C1/1A93: C2 20        REP #$20
C1/1A95: A0 0C 00     LDY #$000C
C1/1A98: 68           PLA 
C1/1A99: 99 6E 00     STA $006E,Y
C1/1A9C: 88           DEY 
C1/1A9D: 88           DEY 
C1/1A9E: D0 F8        BNE $1A98
C1/1AA0: 7B           TDC 
C1/1AA1: E2 20        SEP #$20
C1/1AA3: 7A           PLY 
C1/1AA4: FA           PLX 
C1/1AA5: 60           RTS 

; [  ]

C1/1AA6: DA           PHX 
C1/1AA7: 5A           PHY 
C1/1AA8: 85 81        STA $81
C1/1AAA: C2 20        REP #$20
C1/1AAC: 7B           TDC 
C1/1AAD: A8           TAY 
C1/1AAE: B9 70 00     LDA $0070,Y
C1/1AB1: 48           PHA 
C1/1AB2: C8           INY 
C1/1AB3: C8           INY 
C1/1AB4: C0 0C 00     CPY #$000C
C1/1AB7: D0 F5        BNE $1AAE
C1/1AB9: 7B           TDC 
C1/1ABA: E2 20        SEP #$20
C1/1ABC: A5 80        LDA $80
C1/1ABE: AA           TAX 
C1/1ABF: BD 26 D0     LDA $D026,X
C1/1AC2: F0 1A        BEQ $1ADE
C1/1AC4: A5 81        LDA $81
C1/1AC6: 85 7E        STA $7E
C1/1AC8: A5 80        LDA $80
C1/1ACA: AA           TAX 
C1/1ACB: BD 0E D0     LDA $D00E,X
C1/1ACE: 85 70        STA $70
C1/1AD0: BD 16 D0     LDA $D016,X
C1/1AD3: 3A           DEC 
C1/1AD4: 18           CLC 
C1/1AD5: 7D 26 D0     ADC $D026,X
C1/1AD8: 85 72        STA $72
C1/1ADA: 8A           TXA 
C1/1ADB: 20 2F 20     JSR $202F
C1/1ADE: A5 81        LDA $81
C1/1AE0: 85 7E        STA $7E
C1/1AE2: A5 80        LDA $80
C1/1AE4: AA           TAX 
C1/1AE5: BD 0E D0     LDA $D00E,X
C1/1AE8: 85 70        STA $70
C1/1AEA: BD 16 D0     LDA $D016,X
C1/1AED: 18           CLC 
C1/1AEE: 7D 26 D0     ADC $D026,X
C1/1AF1: 85 72        STA $72
C1/1AF3: 8A           TXA 
C1/1AF4: 20 22 1F     JSR $1F22
C1/1AF7: EE A4 DB     INC $DBA4
C1/1AFA: C2 20        REP #$20
C1/1AFC: A0 0C 00     LDY #$000C
C1/1AFF: 68           PLA 
C1/1B00: 99 6E 00     STA $006E,Y
C1/1B03: 88           DEY 
C1/1B04: 88           DEY 
C1/1B05: D0 F8        BNE $1AFF
C1/1B07: 7B           TDC 
C1/1B08: E2 20        SEP #$20
C1/1B0A: 7A           PLY 
C1/1B0B: FA           PLX 
C1/1B0C: 60           RTS 

C1/1B0D: 7B           TDC 
C1/1B0E: AA           TAX 
C1/1B0F: AD D3 DB     LDA $DBD3
C1/1B12: F0 04        BEQ $1B18
C1/1B14: A9 54        LDA #$54
C1/1B16: 80 02        BRA $1B1A
C1/1B18: A9 34        LDA #$34
C1/1B1A: 85 70        STA $70
C1/1B1C: BD 4A DB     LDA $DB4A,X
C1/1B1F: F0 04        BEQ $1B25
C1/1B21: A9 D8        LDA #$D8
C1/1B23: 80 02        BRA $1B27
C1/1B25: A9 C8        LDA #$C8
C1/1B27: 9D 1E D0     STA $D01E,X
C1/1B2A: A5 70        LDA $70
C1/1B2C: 9D 22 D0     STA $D022,X
C1/1B2F: 18           CLC 
C1/1B30: 69 1A        ADC #$1A
C1/1B32: 85 70        STA $70
C1/1B34: BD 1E D0     LDA $D01E,X
C1/1B37: 38           SEC 
C1/1B38: E9 10        SBC #$10
C1/1B3A: 9D 56 D0     STA $D056,X
C1/1B3D: BD 22 D0     LDA $D022,X
C1/1B40: 9D 62 D0     STA $D062,X
C1/1B43: BD 1E D0     LDA $D01E,X
C1/1B46: 18           CLC 
C1/1B47: 69 08        ADC #$08
C1/1B49: 9D 3E D0     STA $D03E,X
C1/1B4C: 9D 6E D0     STA $D06E,X
C1/1B4F: BD 22 D0     LDA $D022,X
C1/1B52: 18           CLC 
C1/1B53: 69 0C        ADC #$0C
C1/1B55: 9D 4A D0     STA $D04A,X
C1/1B58: 18           CLC 
C1/1B59: 69 0C        ADC #$0C
C1/1B5B: 9D 7A D0     STA $D07A,X
C1/1B5E: E8           INX 
C1/1B5F: E0 04 00     CPX #$0004
C1/1B62: D0 B8        BNE $1B1C
C1/1B64: 60           RTS 

C1/1B65: 64 74        STZ $74
C1/1B67: AD D3 DB     LDA $DBD3
C1/1B6A: F0 04        BEQ $1B70
C1/1B6C: A9 20        LDA #$20
C1/1B6E: 85 74        STA $74
C1/1B70: 7B           TDC 
C1/1B71: AA           TAX 
C1/1B72: BD 0E D0     LDA $D00E,X
C1/1B75: 0A           ASL 
C1/1B76: 0A           ASL 
C1/1B77: 0A           ASL 
C1/1B78: 85 70        STA $70
C1/1B7A: 38           SEC 
C1/1B7B: E9 08        SBC #$08
C1/1B7D: 9D 4E D0     STA $D04E,X
C1/1B80: BD FE CF     LDA $CFFE,X
C1/1B83: 29 FE        AND #$FE
C1/1B85: 0A           ASL 
C1/1B86: 0A           ASL 
C1/1B87: 18           CLC 
C1/1B88: 65 70        ADC $70
C1/1B8A: 9D 36 D0     STA $D036,X
C1/1B8D: 9D 66 D0     STA $D066,X
C1/1B90: 9D 7E D0     STA $D07E,X
C1/1B93: BD 16 D0     LDA $D016,X
C1/1B96: 0A           ASL 
C1/1B97: 0A           ASL 
C1/1B98: 0A           ASL 
C1/1B99: 85 70        STA $70
C1/1B9B: 18           CLC 
C1/1B9C: 65 74        ADC $74
C1/1B9E: 9D 8A D0     STA $D08A,X
C1/1BA1: BD 06 D0     LDA $D006,X
C1/1BA4: 29 FE        AND #$FE
C1/1BA6: 0A           ASL 
C1/1BA7: 0A           ASL 
C1/1BA8: 18           CLC 
C1/1BA9: 65 70        ADC $70
C1/1BAB: 18           CLC 
C1/1BAC: 65 74        ADC $74
C1/1BAE: 9D 42 D0     STA $D042,X
C1/1BB1: 38           SEC 
C1/1BB2: E9 08        SBC #$08
C1/1BB4: 18           CLC 
C1/1BB5: 65 74        ADC $74
C1/1BB7: 9D 5A D0     STA $D05A,X
C1/1BBA: BD 06 D0     LDA $D006,X
C1/1BBD: 0A           ASL 
C1/1BBE: 0A           ASL 
C1/1BBF: 0A           ASL 
C1/1BC0: 18           CLC 
C1/1BC1: 65 70        ADC $70
C1/1BC3: 18           CLC 
C1/1BC4: 65 74        ADC $74
C1/1BC6: 9D 72 D0     STA $D072,X
C1/1BC9: E8           INX 
C1/1BCA: E0 08 00     CPX #$0008
C1/1BCD: D0 A3        BNE $1B72
C1/1BCF: 7B           TDC 
C1/1BD0: AA           TAX 
C1/1BD1: A9 FF        LDA #$FF
C1/1BD3: 9D A2 D0     STA $D0A2,X
C1/1BD6: 9D AA D0     STA $D0AA,X
C1/1BD9: 9D B2 D0     STA $D0B2,X
C1/1BDC: 9D BA D0     STA $D0BA,X
C1/1BDF: E8           INX 
C1/1BE0: E0 08 00     CPX #$0008
C1/1BE3: D0 EE        BNE $1BD3
C1/1BE5: 7B           TDC 
C1/1BE6: AA           TAX 
C1/1BE7: A8           TAY 
C1/1BE8: BD 36 D0     LDA $D036,X
C1/1BEB: 99 F6 DB     STA $DBF6,Y
C1/1BEE: BD 42 D0     LDA $D042,X
C1/1BF1: 99 06 DC     STA $DC06,Y
C1/1BF4: 8A           TXA 
C1/1BF5: 99 F7 DB     STA $DBF7,Y
C1/1BF8: 99 07 DC     STA $DC07,Y
C1/1BFB: E8           INX 
C1/1BFC: C8           INY 
C1/1BFD: C8           INY 
C1/1BFE: C0 10 00     CPY #$0010
C1/1C01: D0 E5        BNE $1BE8
C1/1C03: A0 10 00     LDY #$0010
C1/1C06: 7B           TDC 
C1/1C07: AA           TAX 
C1/1C08: BD F6 DB     LDA $DBF6,X
C1/1C0B: DD F8 DB     CMP $DBF8,X
C1/1C0E: 90 19        BCC $1C29
C1/1C10: 48           PHA 
C1/1C11: BD F8 DB     LDA $DBF8,X
C1/1C14: 9D F6 DB     STA $DBF6,X
C1/1C17: 68           PLA 
C1/1C18: 9D F8 DB     STA $DBF8,X
C1/1C1B: BD F7 DB     LDA $DBF7,X
C1/1C1E: 48           PHA 
C1/1C1F: BD F9 DB     LDA $DBF9,X
C1/1C22: 9D F7 DB     STA $DBF7,X
C1/1C25: 68           PLA 
C1/1C26: 9D F9 DB     STA $DBF9,X
C1/1C29: BD 06 DC     LDA $DC06,X
C1/1C2C: DD 08 DC     CMP $DC08,X
C1/1C2F: 90 19        BCC $1C4A
C1/1C31: 48           PHA 
C1/1C32: BD 08 DC     LDA $DC08,X
C1/1C35: 9D 06 DC     STA $DC06,X
C1/1C38: 68           PLA 
C1/1C39: 9D 08 DC     STA $DC08,X
C1/1C3C: BD 07 DC     LDA $DC07,X
C1/1C3F: 48           PHA 
C1/1C40: BD 09 DC     LDA $DC09,X
C1/1C43: 9D 07 DC     STA $DC07,X
C1/1C46: 68           PLA 
C1/1C47: 9D 09 DC     STA $DC09,X
C1/1C4A: E8           INX 
C1/1C4B: E8           INX 
C1/1C4C: E0 0E 00     CPX #$000E
C1/1C4F: D0 B7        BNE $1C08
C1/1C51: 88           DEY 
C1/1C52: D0 B2        BNE $1C06
C1/1C54: 7B           TDC 
C1/1C55: AA           TAX 
C1/1C56: A8           TAY 
C1/1C57: BD F7 DB     LDA $DBF7,X
C1/1C5A: 99 A2 D0     STA $D0A2,Y
C1/1C5D: BD 07 DC     LDA $DC07,X
C1/1C60: 99 B2 D0     STA $D0B2,Y
C1/1C63: E8           INX 
C1/1C64: E8           INX 
C1/1C65: C8           INY 
C1/1C66: C0 08 00     CPY #$0008
C1/1C69: D0 EC        BNE $1C57
C1/1C6B: 7B           TDC 
C1/1C6C: AA           TAX 
C1/1C6D: A0 07 00     LDY #$0007
C1/1C70: BD A2 D0     LDA $D0A2,X
C1/1C73: 99 AA D0     STA $D0AA,Y
C1/1C76: BD B2 D0     LDA $D0B2,X
C1/1C79: 99 BA D0     STA $D0BA,Y
C1/1C7C: E8           INX 
C1/1C7D: 88           DEY 
C1/1C7E: E0 08 00     CPX #$0008
C1/1C81: D0 ED        BNE $1C70
C1/1C83: 60           RTS 

C1/1C84: 20 DF 1C     JSR $1CDF
C1/1C87: 4C 94 1C     JMP $1C94

C1/1C8A: 20 EB 1C     JSR $1CEB
C1/1C8D: A5 DE        LDA $DE
C1/1C8F: 85 70        STA $70
C1/1C91: 20 68 20     JSR $2068       ; load monster palettes
C1/1C94: 20 65 1D     JSR $1D65
C1/1C97: A2 00 05     LDX #$0500
C1/1C9A: 86 70        STX $70
C1/1C9C: A2 00 78     LDX #$7800
C1/1C9F: AD D3 DB     LDA $DBD3
C1/1CA2: F0 05        BEQ $1CA9
C1/1CA4: A0 80 5C     LDY #$5C80
C1/1CA7: 80 03        BRA $1CAC
C1/1CA9: A0 00 5C     LDY #$5C00
C1/1CAC: A9 7F        LDA #$7F
C1/1CAE: 4C 27 FD     JMP $FD27

; [ load black and white monster palette ]

C1/1CB1: 85 7B        STA $7B
C1/1CB3: 20 ED 1C     JSR $1CED
C1/1CB6: 80 0A        BRA $1CC2

; [ restore monster palette ??? ]

C1/1CB8: 20 EB 1C     JSR $1CEB
C1/1CBB: A5 DE        LDA $DE
C1/1CBD: 85 70        STA $70
C1/1CBF: 20 68 20     JSR $2068       ; load monster palettes
C1/1CC2: 20 65 1D     JSR $1D65
C1/1CC5: A2 00 05     LDX #$0500
C1/1CC8: 86 70        STX $70
C1/1CCA: A2 00 78     LDX #$7800
C1/1CCD: AD D3 DB     LDA $DBD3
C1/1CD0: F0 05        BEQ $1CD7
C1/1CD2: A0 80 58     LDY #$5880
C1/1CD5: 80 03        BRA $1CDA
C1/1CD7: A0 00 58     LDY #$5800
C1/1CDA: A9 7F        LDA #$7F
C1/1CDC: 4C 27 FD     JMP $FD27

C1/1CDF: 7B           TDC 
C1/1CE0: AA           TAX 
C1/1CE1: 9D 57 EE     STA $EE57,X
C1/1CE4: E8           INX 
C1/1CE5: E0 00 05     CPX #$0500
C1/1CE8: D0 F7        BNE $1CE1
C1/1CEA: 60           RTS 

C1/1CEB: 64 7B        STZ $7B
C1/1CED: 20 DF 1C     JSR $1CDF
C1/1CF0: A5 DE        LDA $DE
C1/1CF2: 85 7A        STA $7A
C1/1CF4: 7B           TDC 
C1/1CF5: AA           TAX 
C1/1CF6: 06 7A        ASL $7A
C1/1CF8: 90 22        BCC $1D1C
C1/1CFA: 64 7E        STZ $7E
C1/1CFC: 06 7B        ASL $7B
C1/1CFE: 90 04        BCC $1D04
C1/1D00: A9 0C        LDA #$0C
C1/1D02: 85 7E        STA $7E
C1/1D04: BD 0E D0     LDA $D00E,X
C1/1D07: 85 70        STA $70
C1/1D09: BD 16 D0     LDA $D016,X
C1/1D0C: 38           SEC 
C1/1D0D: FD 2E D0     SBC $D02E,X
C1/1D10: 18           CLC 
C1/1D11: 7D 26 D0     ADC $D026,X
C1/1D14: 85 72        STA $72
C1/1D16: 8A           TXA 
C1/1D17: 20 22 1F     JSR $1F22
C1/1D1A: 80 02        BRA $1D1E
C1/1D1C: 06 7B        ASL $7B
C1/1D1E: E8           INX 
C1/1D1F: E0 08 00     CPX #$0008
C1/1D22: D0 D2        BNE $1CF6
C1/1D24: 60           RTS 

C1/1D25: AD 42 DB     LDA $DB42
C1/1D28: F0 1D        BEQ $1D47
C1/1D2A: 9C 42 DB     STZ $DB42
C1/1D2D: A2 00 05     LDX #$0500
C1/1D30: 86 88        STX $88
C1/1D32: A2 00 78     LDX #$7800
C1/1D35: AD D3 DB     LDA $DBD3
C1/1D38: F0 05        BEQ $1D3F
C1/1D3A: A0 80 58     LDY #$5880
C1/1D3D: 80 03        BRA $1D42
C1/1D3F: A0 00 58     LDY #$5800
C1/1D42: A9 7F        LDA #$7F
C1/1D44: 4C B6 FD     JMP $FDB6       ; copy data to vram
C1/1D47: 60           RTS 

C1/1D48: 20 65 1D     JSR $1D65
C1/1D4B: A2 00 05     LDX #$0500
C1/1D4E: 86 70        STX $70
C1/1D50: A2 00 78     LDX #$7800
C1/1D53: AD D3 DB     LDA $DBD3
C1/1D56: F0 05        BEQ $1D5D
C1/1D58: A0 80 58     LDY #$5880
C1/1D5B: 80 03        BRA $1D60
C1/1D5D: A0 00 58     LDY #$5800
C1/1D60: A9 7F        LDA #$7F
C1/1D62: 4C CA FD     JMP $FDCA       ; copy data to vram

C1/1D65: AD EF 3E     LDA $3EEF
C1/1D68: 29 10        AND #$10
C1/1D6A: F0 2F        BEQ $1D9B
C1/1D6C: C2 20        REP #$20
C1/1D6E: A9 57 EE     LDA #$EE57
C1/1D71: 85 76        STA $76
C1/1D73: A9 14 00     LDA #$0014
C1/1D76: 85 72        STA $72
C1/1D78: A9 09 00     LDA #$0009
C1/1D7B: 18           CLC 
C1/1D7C: 6D B7 B3     ADC $B3B7
C1/1D7F: 85 70        STA $70
C1/1D81: 7B           TDC 
C1/1D82: A8           TAY 
C1/1D83: 7B           TDC 
C1/1D84: 91 76        STA ($76),Y
C1/1D86: C8           INY 
C1/1D87: C8           INY 
C1/1D88: C6 70        DEC $70
C1/1D8A: D0 F7        BNE $1D83
C1/1D8C: A5 76        LDA $76
C1/1D8E: 18           CLC 
C1/1D8F: 69 40 00     ADC #$0040
C1/1D92: 85 76        STA $76
C1/1D94: C6 72        DEC $72
C1/1D96: D0 E0        BNE $1D78
C1/1D98: 7B           TDC 
C1/1D99: E2 20        SEP #$20
C1/1D9B: A5 F6        LDA $F6
C1/1D9D: F0 43        BEQ $1DE2
C1/1D9F: 8B           PHB 
C1/1DA0: A9 7F        LDA #$7F
C1/1DA2: 48           PHA 
C1/1DA3: AB           PLB 
C1/1DA4: 7B           TDC 
C1/1DA5: AA           TAX 
C1/1DA6: C2 20        REP #$20
C1/1DA8: DA           PHX 
C1/1DA9: 7B           TDC 
C1/1DAA: A8           TAY 
C1/1DAB: BF 57 EE 7E  LDA $7EEE57,X
C1/1DAF: 99 00 7F     STA $7F00,Y
C1/1DB2: C8           INY 
C1/1DB3: C8           INY 
C1/1DB4: E8           INX 
C1/1DB5: E8           INX 
C1/1DB6: C0 40 00     CPY #$0040
C1/1DB9: D0 F0        BNE $1DAB
C1/1DBB: CA           DEX 
C1/1DBC: CA           DEX 
C1/1DBD: 7B           TDC 
C1/1DBE: A8           TAY 
C1/1DBF: B9 00 7F     LDA $7F00,Y
C1/1DC2: 49 00 40     EOR #$4000
C1/1DC5: 9D 00 78     STA $7800,X
C1/1DC8: C8           INY 
C1/1DC9: C8           INY 
C1/1DCA: CA           DEX 
C1/1DCB: CA           DEX 
C1/1DCC: C0 40 00     CPY #$0040
C1/1DCF: D0 EE        BNE $1DBF
C1/1DD1: FA           PLX 
C1/1DD2: 8A           TXA 
C1/1DD3: 18           CLC 
C1/1DD4: 69 40 00     ADC #$0040
C1/1DD7: AA           TAX 
C1/1DD8: C9 00 05     CMP #$0500
C1/1DDB: D0 CB        BNE $1DA8
C1/1DDD: 7B           TDC 
C1/1DDE: E2 20        SEP #$20
C1/1DE0: AB           PLB 
C1/1DE1: 60           RTS 
C1/1DE2: 8B           PHB 
C1/1DE3: C2 20        REP #$20
C1/1DE5: A2 57 EE     LDX #$EE57
C1/1DE8: A0 00 78     LDY #$7800
C1/1DEB: A9 FF 04     LDA #$04FF
C1/1DEE: 54 7F 7E     MVN $7F,$7E
C1/1DF1: 7B           TDC 
C1/1DF2: E2 20        SEP #$20
C1/1DF4: AB           PLB 
C1/1DF5: 60           RTS 

C1/1DF6: B9 FE CF     LDA $CFFE,Y
C1/1DF9: 0A           ASL 
C1/1DFA: 85 7A        STA $7A
C1/1DFC: 64 7B        STZ $7B
C1/1DFE: 64 79        STZ $79
C1/1E00: B9 06 D0     LDA $D006,Y
C1/1E03: 38           SEC 
C1/1E04: F9 26 D0     SBC $D026,Y
C1/1E07: 85 78        STA $78
C1/1E09: D0 03        BNE $1E0E
C1/1E0B: 4C D0 1E     JMP $1ED0
C1/1E0E: C2 20        REP #$20
C1/1E10: 06 70        ASL $70
C1/1E12: 06 72        ASL $72
C1/1E14: 06 72        ASL $72
C1/1E16: 06 72        ASL $72
C1/1E18: 06 72        ASL $72
C1/1E1A: 06 72        ASL $72
C1/1E1C: 06 72        ASL $72
C1/1E1E: A5 72        LDA $72
C1/1E20: 18           CLC 
C1/1E21: 65 70        ADC $70
C1/1E23: 18           CLC 
C1/1E24: 69 57 EE     ADC #$EE57
C1/1E27: 85 70        STA $70
C1/1E29: A5 74        LDA $74
C1/1E2B: 18           CLC 
C1/1E2C: 69 F6 DC     ADC #$DCF6
C1/1E2F: 85 74        STA $74
C1/1E31: 7B           TDC 
C1/1E32: E2 20        SEP #$20
C1/1E34: A9 10        LDA #$10
C1/1E36: 85 80        STA $80
C1/1E38: 98           TYA 
C1/1E39: 0A           ASL 
C1/1E3A: 0A           ASL 
C1/1E3B: AA           TAX 
C1/1E3C: BD 9E 7B     LDA $7B9E,X
C1/1E3F: 29 30        AND #$30
C1/1E41: D0 03        BNE $1E46
C1/1E43: 4C D1 1E     JMP $1ED1
C1/1E46: 29 20        AND #$20
C1/1E48: F0 04        BEQ $1E4E
C1/1E4A: A9 14        LDA #$14
C1/1E4C: 85 80        STA $80
C1/1E4E: B9 9C DB     LDA $DB9C,Y
C1/1E51: 0A           ASL 
C1/1E52: 0A           ASL 
C1/1E53: 0A           ASL 
C1/1E54: 0A           ASL 
C1/1E55: 0A           ASL 
C1/1E56: 0A           ASL 
C1/1E57: 29 40        AND #$40
C1/1E59: 09 3C        ORA #$3C
C1/1E5B: 85 81        STA $81
C1/1E5D: 5A           PHY 
C1/1E5E: A0 01 00     LDY #$0001
C1/1E61: B1 74        LDA ($74),Y
C1/1E63: 29 FC        AND #$FC
C1/1E65: 05 81        ORA $81
C1/1E67: 85 81        STA $81
C1/1E69: 7A           PLY 
C1/1E6A: 7B           TDC 
C1/1E6B: AA           TAX 
C1/1E6C: C2 20        REP #$20
C1/1E6E: B2 74        LDA ($74)
C1/1E70: 29 00 FC     AND #$FC00
C1/1E73: 9F 00 7D 7F  STA $7F7D00,X
C1/1E77: E8           INX 
C1/1E78: E8           INX 
C1/1E79: E0 00 02     CPX #$0200
C1/1E7C: D0 F5        BNE $1E73
C1/1E7E: A5 7A        LDA $7A
C1/1E80: 4A           LSR 
C1/1E81: 29 FE FF     AND #$FFFE
C1/1E84: F0 02        BEQ $1E88
C1/1E86: 3A           DEC 
C1/1E87: 3A           DEC 
C1/1E88: 85 7A        STA $7A
C1/1E8A: A5 78        LDA $78
C1/1E8C: 4A           LSR 
C1/1E8D: F0 01        BEQ $1E90
C1/1E8F: 3A           DEC 
C1/1E90: 0A           ASL 
C1/1E91: 0A           ASL 
C1/1E92: 0A           ASL 
C1/1E93: 0A           ASL 
C1/1E94: 0A           ASL 
C1/1E95: 18           CLC 
C1/1E96: 65 7A        ADC $7A
C1/1E98: AA           TAX 
C1/1E99: B9 9C DB     LDA $DB9C,Y
C1/1E9C: 29 01 00     AND #$0001
C1/1E9F: F0 17        BEQ $1EB8
C1/1EA1: A5 80        LDA $80
C1/1EA3: 9F 02 7D 7F  STA $7F7D02,X
C1/1EA7: 1A           INC 
C1/1EA8: 9F 00 7D 7F  STA $7F7D00,X
C1/1EAC: 1A           INC 
C1/1EAD: 9F 22 7D 7F  STA $7F7D22,X
C1/1EB1: 1A           INC 
C1/1EB2: 9F 20 7D 7F  STA $7F7D20,X
C1/1EB6: 80 15        BRA $1ECD
C1/1EB8: A5 80        LDA $80
C1/1EBA: 9F 00 7D 7F  STA $7F7D00,X
C1/1EBE: 1A           INC 
C1/1EBF: 9F 02 7D 7F  STA $7F7D02,X
C1/1EC3: 1A           INC 
C1/1EC4: 9F 20 7D 7F  STA $7F7D20,X
C1/1EC8: 1A           INC 
C1/1EC9: 9F 22 7D 7F  STA $7F7D22,X
C1/1ECD: 7B           TDC 
C1/1ECE: E2 20        SEP #$20
C1/1ED0: 60           RTS 
C1/1ED1: B9 9C DB     LDA $DB9C,Y
C1/1ED4: 29 01        AND #$01
C1/1ED6: F0 32        BEQ $1F0A
C1/1ED8: C2 20        REP #$20
C1/1EDA: 7B           TDC 
C1/1EDB: AA           TAX 
C1/1EDC: A4 7A        LDY $7A
C1/1EDE: 88           DEY 
C1/1EDF: 88           DEY 
C1/1EE0: DA           PHX 
C1/1EE1: B1 74        LDA ($74),Y
C1/1EE3: 49 00 40     EOR #$4000
C1/1EE6: 9F 00 7D 7F  STA $7F7D00,X
C1/1EEA: E8           INX 
C1/1EEB: E8           INX 
C1/1EEC: 88           DEY 
C1/1EED: 88           DEY 
C1/1EEE: C0 FE FF     CPY #$FFFE
C1/1EF1: D0 EE        BNE $1EE1
C1/1EF3: FA           PLX 
C1/1EF4: 8A           TXA 
C1/1EF5: 18           CLC 
C1/1EF6: 69 20 00     ADC #$0020
C1/1EF9: AA           TAX 
C1/1EFA: A5 74        LDA $74
C1/1EFC: 18           CLC 
C1/1EFD: 69 20 00     ADC #$0020
C1/1F00: 85 74        STA $74
C1/1F02: C6 78        DEC $78
C1/1F04: D0 D6        BNE $1EDC
C1/1F06: 7B           TDC 
C1/1F07: E2 20        SEP #$20
C1/1F09: 60           RTS 
C1/1F0A: 7B           TDC 
C1/1F0B: A8           TAY 
C1/1F0C: AA           TAX 
C1/1F0D: C2 20        REP #$20
C1/1F0F: B1 74        LDA ($74),Y
C1/1F11: 9F 00 7D 7F  STA $7F7D00,X
C1/1F15: C8           INY 
C1/1F16: C8           INY 
C1/1F17: E8           INX 
C1/1F18: E8           INX 
C1/1F19: C0 00 02     CPY #$0200
C1/1F1C: D0 F1        BNE $1F0F
C1/1F1E: 7B           TDC 
C1/1F1F: E2 20        SEP #$20
C1/1F21: 60           RTS 

; [  ]

C1/1F22: DA           PHX 
C1/1F23: 64 71        STZ $71
C1/1F25: 64 73        STZ $73
C1/1F27: 64 7C        STZ $7C
C1/1F29: A8           TAY 
C1/1F2A: 0A           ASL 
C1/1F2B: 85 75        STA $75
C1/1F2D: 64 74        STZ $74
C1/1F2F: A6 7A        LDX $7A
C1/1F31: DA           PHX 
C1/1F32: 5A           PHY 
C1/1F33: 20 F6 1D     JSR $1DF6
C1/1F36: 7A           PLY 
C1/1F37: B9 FE CF     LDA $CFFE,Y
C1/1F3A: 0A           ASL 
C1/1F3B: 85 7A        STA $7A
C1/1F3D: 64 7B        STZ $7B
C1/1F3F: 64 79        STZ $79
C1/1F41: B9 06 D0     LDA $D006,Y
C1/1F44: 38           SEC 
C1/1F45: F9 26 D0     SBC $D026,Y
C1/1F48: 85 78        STA $78
C1/1F4A: D0 03        BNE $1F4F
C1/1F4C: 4C 2A 20     JMP $202A
C1/1F4F: 5A           PHY 
C1/1F50: A0 00 7D     LDY #$7D00
C1/1F53: 84 74        STY $74
C1/1F55: A9 7F        LDA #$7F
C1/1F57: 85 76        STA $76
C1/1F59: A4 70        LDY $70
C1/1F5B: C8           INY 
C1/1F5C: 84 72        STY $72
C1/1F5E: 7B           TDC 
C1/1F5F: A8           TAY 
C1/1F60: B1 72        LDA ($72),Y
C1/1F62: 29 03        AND #$03
C1/1F64: 85 86        STA $86
C1/1F66: B1 70        LDA ($70),Y
C1/1F68: D0 0C        BNE $1F76
C1/1F6A: A5 86        LDA $86
C1/1F6C: D0 08        BNE $1F76
C1/1F6E: B7 74        LDA [$74],Y
C1/1F70: 91 70        STA ($70),Y
C1/1F72: C8           INY 
C1/1F73: 4C 89 1F     JMP $1F89
C1/1F76: B7 74        LDA [$74],Y
C1/1F78: D1 70        CMP ($70),Y
C1/1F7A: F0 04        BEQ $1F80
C1/1F7C: C8           INY 
C1/1F7D: 4C A0 1F     JMP $1FA0
C1/1F80: C8           INY 
C1/1F81: B7 74        LDA [$74],Y
C1/1F83: 29 03        AND #$03
C1/1F85: C5 86        CMP $86
C1/1F87: D0 17        BNE $1FA0
C1/1F89: A5 7E        LDA $7E
C1/1F8B: D0 05        BNE $1F92
C1/1F8D: B7 74        LDA [$74],Y
C1/1F8F: 4C 98 1F     JMP $1F98
C1/1F92: B7 74        LDA [$74],Y
C1/1F94: 29 C3        AND #$C3
C1/1F96: 05 7E        ORA $7E
C1/1F98: 91 70        STA ($70),Y
C1/1F9A: 29 3C        AND #$3C
C1/1F9C: 05 7C        ORA $7C
C1/1F9E: 85 7C        STA $7C
C1/1FA0: C8           INY 
C1/1FA1: C4 7A        CPY $7A
C1/1FA3: D0 BB        BNE $1F60
C1/1FA5: C2 20        REP #$20
C1/1FA7: A5 70        LDA $70
C1/1FA9: 18           CLC 
C1/1FAA: 69 40 00     ADC #$0040
C1/1FAD: 85 70        STA $70
C1/1FAF: A5 74        LDA $74
C1/1FB1: 18           CLC 
C1/1FB2: 69 20 00     ADC #$0020
C1/1FB5: 85 74        STA $74
C1/1FB7: 7B           TDC 
C1/1FB8: E2 20        SEP #$20
C1/1FBA: C6 78        DEC $78
C1/1FBC: D0 9B        BNE $1F59
C1/1FBE: 7A           PLY 
C1/1FBF: B9 9C DB     LDA $DB9C,Y
C1/1FC2: 10 66        BPL $202A
C1/1FC4: A5 7C        LDA $7C
C1/1FC6: 85 81        STA $81
C1/1FC8: A5 7E        LDA $7E
C1/1FCA: F0 08        BEQ $1FD4
C1/1FCC: A5 81        LDA $81
C1/1FCE: 29 E3        AND #$E3
C1/1FD0: 05 7E        ORA $7E
C1/1FD2: 85 81        STA $81
C1/1FD4: 64 80        STZ $80
C1/1FD6: 98           TYA 
C1/1FD7: 0A           ASL 
C1/1FD8: 0A           ASL 
C1/1FD9: A8           TAY 
C1/1FDA: B9 9E 7B     LDA $7B9E,Y
C1/1FDD: 29 30        AND #$30
C1/1FDF: D0 49        BNE $202A
C1/1FE1: C2 20        REP #$20
C1/1FE3: A5 70        LDA $70
C1/1FE5: 38           SEC 
C1/1FE6: E9 40 00     SBC #$0040
C1/1FE9: 85 70        STA $70
C1/1FEB: A0 02 00     LDY #$0002
C1/1FEE: 46 7A        LSR $7A
C1/1FF0: A5 7A        LDA $7A
C1/1FF2: C9 04 00     CMP #$0004
C1/1FF5: B0 0B        BCS $2002
C1/1FF7: 88           DEY 
C1/1FF8: 88           DEY 
C1/1FF9: A9 13 00     LDA #$0013
C1/1FFC: 05 80        ORA $80
C1/1FFE: 91 70        STA ($70),Y
C1/2000: 80 1E        BRA $2020
C1/2002: C6 7A        DEC $7A
C1/2004: C6 7A        DEC $7A
C1/2006: C6 7A        DEC $7A
C1/2008: A9 18 00     LDA #$0018
C1/200B: 05 80        ORA $80
C1/200D: 91 70        STA ($70),Y
C1/200F: C8           INY 
C1/2010: C8           INY 
C1/2011: C6 7A        DEC $7A
C1/2013: F0 0B        BEQ $2020
C1/2015: A9 19 00     LDA #$0019
C1/2018: 05 80        ORA $80
C1/201A: 91 70        STA ($70),Y
C1/201C: C8           INY 
C1/201D: C8           INY 
C1/201E: 80 F1        BRA $2011
C1/2020: A9 1A 00     LDA #$001A
C1/2023: 05 80        ORA $80
C1/2025: 91 70        STA ($70),Y
C1/2027: 7B           TDC 
C1/2028: E2 20        SEP #$20
C1/202A: FA           PLX 
C1/202B: 86 7A        STX $7A
C1/202D: FA           PLX 
C1/202E: 60           RTS 

; [  ]

C1/202F: DA           PHX 
C1/2030: 64 71        STZ $71
C1/2032: 64 73        STZ $73
C1/2034: A8           TAY 
C1/2035: B9 FE CF     LDA $CFFE,Y
C1/2038: 0A           ASL 
C1/2039: 85 76        STA $76
C1/203B: 64 77        STZ $77
C1/203D: C2 20        REP #$20
C1/203F: 06 70        ASL $70
C1/2041: 06 72        ASL $72
C1/2043: 06 72        ASL $72
C1/2045: 06 72        ASL $72
C1/2047: 06 72        ASL $72
C1/2049: 06 72        ASL $72
C1/204B: 06 72        ASL $72
C1/204D: A5 72        LDA $72
C1/204F: 18           CLC 
C1/2050: 65 70        ADC $70
C1/2052: 18           CLC 
C1/2053: 69 57 EE     ADC #$EE57
C1/2056: 85 70        STA $70
C1/2058: 7B           TDC 
C1/2059: A8           TAY 
C1/205A: 7B           TDC 
C1/205B: 91 70        STA ($70),Y
C1/205D: C8           INY 
C1/205E: C8           INY 
C1/205F: C4 76        CPY $76
C1/2061: D0 F7        BNE $205A
C1/2063: 7B           TDC 
C1/2064: E2 20        SEP #$20
C1/2066: FA           PLX 
C1/2067: 60           RTS 

; [ load monster palettes ]

C1/2068: 5A           PHY 
C1/2069: AD 56 EE     LDA $EE56
C1/206C: D0 54        BNE $20C2
C1/206E: 7B           TDC 
C1/206F: A8           TAY 
C1/2070: 06 70        ASL $70
C1/2072: 90 48        BCC $20BC
C1/2074: B9 D6 CF     LDA $CFD6,Y
C1/2077: 0A           ASL 
C1/2078: 0A           ASL 
C1/2079: 0A           ASL 
C1/207A: 0A           ASL 
C1/207B: 0A           ASL 
C1/207C: 85 72        STA $72
C1/207E: 98           TYA 
C1/207F: 0A           ASL 
C1/2080: AA           TAX 
C1/2081: BD DE CF     LDA $CFDE,X
C1/2084: 85 74        STA $74
C1/2086: BD DF CF     LDA $CFDF,X
C1/2089: 85 75        STA $75
C1/208B: A6 74        LDX $74
C1/208D: AD EF 3E     LDA $3EEF
C1/2090: 29 40        AND #$40
C1/2092: F0 02        BEQ $2096
C1/2094: 7B           TDC 
C1/2095: AA           TAX 
C1/2096: 5A           PHY 
C1/2097: A5 72        LDA $72
C1/2099: A8           TAY 
C1/209A: A9 20        LDA #$20
C1/209C: 85 76        STA $76
C1/209E: AD EF 3E     LDA $3EEF
C1/20A1: 29 40        AND #$40
C1/20A3: F0 06        BEQ $20AB
C1/20A5: BF 55 97 D9  LDA $D99755,X   ; underwater monster palette
C1/20A9: 80 04        BRA $20AF
C1/20AB: BF 00 D0 CE  LDA $CED000,X   ; monster palettes
C1/20AF: 99 89 7E     STA $7E89,Y
C1/20B2: 99 F6 ED     STA $EDF6,Y
C1/20B5: E8           INX 
C1/20B6: C8           INY 
C1/20B7: C6 76        DEC $76
C1/20B9: D0 E3        BNE $209E
C1/20BB: 7A           PLY 
C1/20BC: C8           INY 
C1/20BD: C0 08 00     CPY #$0008
C1/20C0: D0 AE        BNE $2070
C1/20C2: 7A           PLY 
C1/20C3: 60           RTS 

; [ load monster graphics ]

C1/20C4: A0 00 02     LDY #$0200
C1/20C7: 8C F6 DB     STY $DBF6
C1/20CA: A0 00 20     LDY #$2000
C1/20CD: 8C FE DB     STY $DBFE
C1/20D0: 7B           TDC 
C1/20D1: A8           TAY 
C1/20D2: 98           TYA 
C1/20D3: 0A           ASL 
C1/20D4: AA           TAX 
C1/20D5: AD F6 DB     LDA $DBF6
C1/20D8: 9D EE CF     STA $CFEE,X
C1/20DB: AD F7 DB     LDA $DBF7
C1/20DE: 9D EF CF     STA $CFEF,X
C1/20E1: BD 21 40     LDA $4021,X     ; monster graphics index
C1/20E4: C9 FF        CMP #$FF
C1/20E6: F0 3B        BEQ $2123       ; branch if slot is empty
C1/20E8: 85 7F        STA $7F
C1/20EA: BD 20 40     LDA $4020,X
C1/20ED: 85 7E        STA $7E         ; +$7E = monster graphics index
C1/20EF: A2 05 00     LDX #$0005
C1/20F2: 86 80        STX $80
C1/20F4: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/20F7: B9 D6 CF     LDA $CFD6,Y
C1/20FA: 0A           ASL 
C1/20FB: 0A           ASL 
C1/20FC: 09 30        ORA #$30
C1/20FE: 8D F8 DB     STA $DBF8
C1/2101: A6 82        LDX $82
C1/2103: 98           TYA 
C1/2104: 20 06 23     JSR $2306       ; 
C1/2107: AD FB DB     LDA $DBFB
C1/210A: 1A           INC 
C1/210B: 99 FE CF     STA $CFFE,Y
C1/210E: AD FC DB     LDA $DBFC
C1/2111: 1A           INC 
C1/2112: 99 06 D0     STA $D006,Y
C1/2115: AD FD DB     LDA $DBFD
C1/2118: 99 E6 D0     STA $D0E6,Y
C1/211B: 20 57 21     JSR $2157       ; 
C1/211E: 20 33 21     JSR $2133       ; get pointer to monster palette
C1/2121: 80 07        BRA $212A
C1/2123: 7B           TDC 
C1/2124: 99 FE CF     STA $CFFE,Y
C1/2127: 99 06 D0     STA $D006,Y
C1/212A: C8           INY             ; next monster
C1/212B: C0 08 00     CPY #$0008
C1/212E: D0 A2        BNE $20D2
C1/2130: 4C F2 22     JMP $22F2

; [ get pointer to monster palette ]

C1/2133: DA           PHX 
C1/2134: 5A           PHY 
C1/2135: BF 82 B1 D4  LDA $D4B182,X   ; msb of palette index
C1/2139: 29 03        AND #$03
C1/213B: 85 71        STA $71
C1/213D: BF 83 B1 D4  LDA $D4B183,X   ; palette index
C1/2141: 85 70        STA $70
C1/2143: 98           TYA 
C1/2144: 0A           ASL 
C1/2145: A8           TAY 
C1/2146: C2 20        REP #$20
C1/2148: A5 70        LDA $70
C1/214A: 0A           ASL 
C1/214B: 0A           ASL 
C1/214C: 0A           ASL 
C1/214D: 0A           ASL 
C1/214E: 99 DE CF     STA $CFDE,Y     ; pointer to monster palette
C1/2151: 7B           TDC 
C1/2152: E2 20        SEP #$20
C1/2154: 7A           PLY 
C1/2155: FA           PLX 
C1/2156: 60           RTS 

; [ copy monster graphics to vram ]

C1/2157: 5A           PHY 
C1/2158: DA           PHX 
C1/2159: 85 76        STA $76
C1/215B: 64 77        STZ $77
C1/215D: BF 80 B1 D4  LDA $D4B180,X   ; pointer to monster graphics
C1/2161: 85 70        STA $70
C1/2163: 29 7F        AND #$7F
C1/2165: 85 73        STA $73
C1/2167: BF 81 B1 D4  LDA $D4B181,X
C1/216B: 85 72        STA $72
C1/216D: 64 74        STZ $74
C1/216F: 06 72        ASL $72
C1/2171: 26 73        ROL $73
C1/2173: 26 74        ROL $74
C1/2175: 06 72        ASL $72
C1/2177: 26 73        ROL $73
C1/2179: 26 74        ROL $74
C1/217B: 06 72        ASL $72
C1/217D: 26 73        ROL $73
C1/217F: 26 74        ROL $74
C1/2181: A5 72        LDA $72
C1/2183: 18           CLC 
C1/2184: 69 00        ADC #$00
C1/2186: 85 72        STA $72
C1/2188: A5 73        LDA $73
C1/218A: 69 00        ADC #$00
C1/218C: 85 73        STA $73
C1/218E: A5 74        LDA $74
C1/2190: 69 D5        ADC #$D5
C1/2192: 85 74        STA $74
C1/2194: 7B           TDC 
C1/2195: A8           TAY 
C1/2196: A5 70        LDA $70
C1/2198: 29 80        AND #$80
C1/219A: D0 2B        BNE $21C7       ; if msb is set, graphics are 3bpp
C1/219C: C2 20        REP #$20
C1/219E: AD FE DB     LDA $DBFE
C1/21A1: 8F 16 21 00  STA $002116
C1/21A5: A2 10 00     LDX #$0010
C1/21A8: B7 72        LDA [$72],Y
C1/21AA: 8F 18 21 00  STA $002118
C1/21AE: C8           INY 
C1/21AF: C8           INY 
C1/21B0: CA           DEX 
C1/21B1: D0 F5        BNE $21A8
C1/21B3: AD FE DB     LDA $DBFE
C1/21B6: 18           CLC 
C1/21B7: 69 10 00     ADC #$0010
C1/21BA: 8D FE DB     STA $DBFE
C1/21BD: C6 76        DEC $76
C1/21BF: D0 E4        BNE $21A5
C1/21C1: 7B           TDC 
C1/21C2: E2 20        SEP #$20
C1/21C4: FA           PLX 
C1/21C5: 7A           PLY 
C1/21C6: 60           RTS 
C1/21C7: C2 20        REP #$20
C1/21C9: AD FE DB     LDA $DBFE
C1/21CC: 8F 16 21 00  STA $002116
C1/21D0: A2 08 00     LDX #$0008
C1/21D3: B7 72        LDA [$72],Y
C1/21D5: 8F 18 21 00  STA $002118
C1/21D9: C8           INY 
C1/21DA: C8           INY 
C1/21DB: CA           DEX 
C1/21DC: D0 F5        BNE $21D3
C1/21DE: A2 08 00     LDX #$0008
C1/21E1: B7 72        LDA [$72],Y
C1/21E3: 29 FF 00     AND #$00FF
C1/21E6: 8F 18 21 00  STA $002118
C1/21EA: C8           INY 
C1/21EB: CA           DEX 
C1/21EC: D0 F3        BNE $21E1
C1/21EE: AD FE DB     LDA $DBFE
C1/21F1: 18           CLC 
C1/21F2: 69 10 00     ADC #$0010
C1/21F5: 8D FE DB     STA $DBFE
C1/21F8: C6 76        DEC $76
C1/21FA: D0 D4        BNE $21D0
C1/21FC: 7B           TDC 
C1/21FD: E2 20        SEP #$20
C1/21FF: FA           PLX 
C1/2200: 7A           PLY 
C1/2201: 60           RTS 

; [  ]

C1/2202: A9 00        LDA #$00
C1/2204: 8F 81 21 00  STA $002181
C1/2208: A9 C0        LDA #$C0
C1/220A: 8F 82 21 00  STA $002182
C1/220E: A9 01        LDA #$01
C1/2210: 8F 83 21 00  STA $002183
C1/2214: 7B           TDC 
C1/2215: A8           TAY 
C1/2216: 98           TYA 
C1/2217: 0A           ASL 
C1/2218: AA           TAX 
C1/2219: BD 21 40     LDA $4021,X
C1/221C: C9 FF        CMP #$FF
C1/221E: F0 17        BEQ $2237
C1/2220: 85 7F        STA $7F
C1/2222: BD 20 40     LDA $4020,X
C1/2225: 85 7E        STA $7E
C1/2227: A2 05 00     LDX #$0005
C1/222A: 86 80        STX $80
C1/222C: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/222F: A6 82        LDX $82
C1/2231: B9 E6 D0     LDA $D0E6,Y
C1/2234: 20 89 22     JSR $2289
C1/2237: C8           INY 
C1/2238: C0 08 00     CPY #$0008
C1/223B: D0 D9        BNE $2216
C1/223D: 8B           PHB 
C1/223E: C2 20        REP #$20
C1/2240: A2 00 C0     LDX #$C000
C1/2243: A0 00 80     LDY #$8000
C1/2246: A9 FF 3F     LDA #$3FFF
C1/2249: 54 7F 7F     MVN $7F,$7F
C1/224C: 7B           TDC 
C1/224D: E2 20        SEP #$20
C1/224F: AB           PLB 
C1/2250: 60           RTS 

; [ get pointer to monster graphics ]

C1/2251: BF 80 B1 D4  LDA $D4B180,X   ; pointer to monster graphics
C1/2255: 85 70        STA $70
C1/2257: 29 7F        AND #$7F
C1/2259: 85 73        STA $73
C1/225B: BF 81 B1 D4  LDA $D4B181,X
C1/225F: 85 72        STA $72
C1/2261: 64 74        STZ $74
C1/2263: 06 72        ASL $72
C1/2265: 26 73        ROL $73
C1/2267: 26 74        ROL $74
C1/2269: 06 72        ASL $72
C1/226B: 26 73        ROL $73
C1/226D: 26 74        ROL $74
C1/226F: 06 72        ASL $72
C1/2271: 26 73        ROL $73
C1/2273: 26 74        ROL $74
C1/2275: A5 72        LDA $72
C1/2277: 18           CLC 
C1/2278: 69 00        ADC #$00
C1/227A: 85 72        STA $72
C1/227C: A5 73        LDA $73
C1/227E: 69 00        ADC #$00
C1/2280: 85 73        STA $73
C1/2282: A5 74        LDA $74
C1/2284: 69 D5        ADC #$D5
C1/2286: 85 74        STA $74
C1/2288: 60           RTS 

; [  ]

C1/2289: 5A           PHY 
C1/228A: DA           PHX 
C1/228B: 85 76        STA $76
C1/228D: 64 77        STZ $77
C1/228F: 20 51 22     JSR $2251       ; get pointer to monster graphics
C1/2292: 7B           TDC 
C1/2293: A8           TAY 
C1/2294: A5 70        LDA $70
C1/2296: 29 80        AND #$80
C1/2298: D0 23        BNE $22BD
C1/229A: A2 20 00     LDX #$0020
C1/229D: B7 72        LDA [$72],Y
C1/229F: 8F 80 21 00  STA $002180
C1/22A3: C8           INY 
C1/22A4: CA           DEX 
C1/22A5: D0 F6        BNE $229D
C1/22A7: C2 20        REP #$20
C1/22A9: AD FE DB     LDA $DBFE
C1/22AC: 18           CLC 
C1/22AD: 69 10 00     ADC #$0010
C1/22B0: 8D FE DB     STA $DBFE
C1/22B3: 7B           TDC 
C1/22B4: E2 20        SEP #$20
C1/22B6: C6 76        DEC $76
C1/22B8: D0 E0        BNE $229A
C1/22BA: FA           PLX 
C1/22BB: 7A           PLY 
C1/22BC: 60           RTS 
C1/22BD: A2 10 00     LDX #$0010
C1/22C0: B7 72        LDA [$72],Y
C1/22C2: 8F 80 21 00  STA $002180
C1/22C6: C8           INY 
C1/22C7: CA           DEX 
C1/22C8: D0 F6        BNE $22C0
C1/22CA: A2 08 00     LDX #$0008
C1/22CD: B7 72        LDA [$72],Y
C1/22CF: 8F 80 21 00  STA $002180
C1/22D3: 7B           TDC 
C1/22D4: 8F 80 21 00  STA $002180
C1/22D8: C8           INY 
C1/22D9: CA           DEX 
C1/22DA: D0 F1        BNE $22CD
C1/22DC: C2 20        REP #$20
C1/22DE: AD FE DB     LDA $DBFE
C1/22E1: 18           CLC 
C1/22E2: 69 10 00     ADC #$0010
C1/22E5: 8D FE DB     STA $DBFE
C1/22E8: 7B           TDC 
C1/22E9: E2 20        SEP #$20
C1/22EB: C6 76        DEC $76
C1/22ED: D0 CE        BNE $22BD
C1/22EF: FA           PLX 
C1/22F0: 7A           PLY 
C1/22F1: 60           RTS 

; [  ]

C1/22F2: 7B           TDC 
C1/22F3: AA           TAX 
C1/22F4: BD 9C DB     LDA $DB9C,X
C1/22F7: 10 06        BPL $22FF
C1/22F9: FE 06 D0     INC $D006,X
C1/22FC: FE 06 D0     INC $D006,X
C1/22FF: E8           INX 
C1/2300: E0 08 00     CPX #$0008
C1/2303: D0 EF        BNE $22F4
C1/2305: 60           RTS 

; [  ]

C1/2306: 5A           PHY 
C1/2307: DA           PHX 
C1/2308: 0A           ASL 
C1/2309: 85 71        STA $71
C1/230B: 64 70        STZ $70
C1/230D: 64 76        STZ $76
C1/230F: A9 D0        LDA #$D0
C1/2311: 85 74        STA $74
C1/2313: 9C FB DB     STZ $DBFB
C1/2316: 9C FC DB     STZ $DBFC
C1/2319: 9C FD DB     STZ $DBFD
C1/231C: BF 82 B1 D4  LDA $D4B182,X
C1/2320: 29 40        AND #$40
C1/2322: F0 08        BEQ $232C
C1/2324: B9 9C DB     LDA $DB9C,Y
C1/2327: 09 80        ORA #$80
C1/2329: 99 9C DB     STA $DB9C,Y
C1/232C: BF 82 B1 D4  LDA $D4B182,X
C1/2330: 30 79        BMI $23AB       ; branch if monster uses large map
C1/2332: BF 84 B1 D4  LDA $D4B184,X   ; graphics map index
C1/2336: C2 20        REP #$20
C1/2338: 0A           ASL 
C1/2339: 0A           ASL 
C1/233A: 0A           ASL 
C1/233B: 18           CLC 
C1/233C: 6F 00 D0 D0  ADC $D0D000     ; pointer to small graphic maps
C1/2340: 85 72        STA $72
C1/2342: 7B           TDC 
C1/2343: E2 20        SEP #$20
C1/2345: 64 7A        STZ $7A
C1/2347: A6 70        LDX $70
C1/2349: A7 72        LDA [$72]
C1/234B: 85 7E        STA $7E
C1/234D: F0 05        BEQ $2354
C1/234F: A5 7A        LDA $7A
C1/2351: 8D FC DB     STA $DBFC
C1/2354: 7B           TDC 
C1/2355: A8           TAY 
C1/2356: 06 7E        ASL $7E
C1/2358: 90 25        BCC $237F
C1/235A: 98           TYA 
C1/235B: CD FB DB     CMP $DBFB
C1/235E: 90 03        BCC $2363
C1/2360: 8D FB DB     STA $DBFB
C1/2363: AD F6 DB     LDA $DBF6
C1/2366: 9D F6 DC     STA $DCF6,X
C1/2369: AD F7 DB     LDA $DBF7
C1/236C: 0D F8 DB     ORA $DBF8
C1/236F: 9D F7 DC     STA $DCF7,X
C1/2372: C2 20        REP #$20
C1/2374: EE F6 DB     INC $DBF6
C1/2377: 7B           TDC 
C1/2378: E2 20        SEP #$20
C1/237A: EE FD DB     INC $DBFD
C1/237D: 80 07        BRA $2386
C1/237F: 7B           TDC 
C1/2380: 9D F6 DC     STA $DCF6,X
C1/2383: 9D F7 DC     STA $DCF7,X
C1/2386: E8           INX 
C1/2387: E8           INX 
C1/2388: C8           INY 
C1/2389: C0 08 00     CPY #$0008
C1/238C: D0 C8        BNE $2356
C1/238E: A4 72        LDY $72
C1/2390: C8           INY 
C1/2391: 84 72        STY $72
C1/2393: C2 20        REP #$20
C1/2395: A5 70        LDA $70
C1/2397: 18           CLC 
C1/2398: 69 20 00     ADC #$0020
C1/239B: 85 70        STA $70
C1/239D: 7B           TDC 
C1/239E: E2 20        SEP #$20
C1/23A0: E6 7A        INC $7A
C1/23A2: A5 7A        LDA $7A
C1/23A4: C9 08        CMP #$08
C1/23A6: D0 9F        BNE $2347
C1/23A8: FA           PLX 
C1/23A9: 7A           PLY 
C1/23AA: 60           RTS 
C1/23AB: BF 84 B1 D4  LDA $D4B184,X   ; graphics map index
C1/23AF: C2 20        REP #$20
C1/23B1: 0A           ASL 
C1/23B2: 0A           ASL 
C1/23B3: 0A           ASL 
C1/23B4: 0A           ASL 
C1/23B5: 0A           ASL 
C1/23B6: 18           CLC 
C1/23B7: 6F 02 D0 D0  ADC $D0D002     ; pointer to large graphic maps
C1/23BB: 85 72        STA $72
C1/23BD: 7B           TDC 
C1/23BE: E2 20        SEP #$20
C1/23C0: 64 7A        STZ $7A
C1/23C2: 64 7B        STZ $7B
C1/23C4: A6 70        LDX $70
C1/23C6: C2 20        REP #$20
C1/23C8: A7 72        LDA [$72]
C1/23CA: 85 7E        STA $7E
C1/23CC: F0 09        BEQ $23D7
C1/23CE: E2 20        SEP #$20
C1/23D0: A5 7A        LDA $7A
C1/23D2: 8D FC DB     STA $DBFC
C1/23D5: C2 20        REP #$20
C1/23D7: 7B           TDC 
C1/23D8: A8           TAY 
C1/23D9: 06 7E        ASL $7E
C1/23DB: 90 25        BCC $2402
C1/23DD: 7B           TDC 
C1/23DE: E2 20        SEP #$20
C1/23E0: 98           TYA 
C1/23E1: CD FB DB     CMP $DBFB
C1/23E4: 90 03        BCC $23E9
C1/23E6: 8D FB DB     STA $DBFB
C1/23E9: AD F6 DB     LDA $DBF6
C1/23EC: 9D F6 DC     STA $DCF6,X
C1/23EF: AD F7 DB     LDA $DBF7
C1/23F2: 0D F8 DB     ORA $DBF8
C1/23F5: 9D F7 DC     STA $DCF7,X
C1/23F8: EE FD DB     INC $DBFD
C1/23FB: C2 20        REP #$20
C1/23FD: EE F6 DB     INC $DBF6
C1/2400: 80 04        BRA $2406
C1/2402: 7B           TDC 
C1/2403: 9D F6 DC     STA $DCF6,X
C1/2406: E8           INX 
C1/2407: E8           INX 
C1/2408: C8           INY 
C1/2409: C0 10 00     CPY #$0010
C1/240C: D0 CB        BNE $23D9
C1/240E: A5 70        LDA $70
C1/2410: 18           CLC 
C1/2411: 69 20 00     ADC #$0020
C1/2414: 85 70        STA $70
C1/2416: AA           TAX 
C1/2417: E6 72        INC $72
C1/2419: E6 72        INC $72
C1/241B: E6 7A        INC $7A
C1/241D: A5 7A        LDA $7A
C1/241F: C9 10 00     CMP #$0010
C1/2422: D0 A4        BNE $23C8
C1/2424: 7B           TDC 
C1/2425: E2 20        SEP #$20
C1/2427: FA           PLX 
C1/2428: 7A           PLY 
C1/2429: 60           RTS 
C1/242A: A2 00 10     LDX #$1000
C1/242D: 86 70        STX $70
C1/242F: A2 00 F0     LDX #$F000
C1/2432: A0 00 40     LDY #$4000
C1/2435: A9 D1        LDA #$D1
C1/2437: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/243A: C2 20        REP #$20
C1/243C: A9 80 40     LDA #$4080
C1/243F: 8F 16 21 00  STA $002116
C1/2443: A2 00 02     LDX #$0200
C1/2446: A9 FF 00     LDA #$00FF
C1/2449: 8F 18 21 00  STA $002118
C1/244D: CA           DEX 
C1/244E: D0 F9        BNE $2449
C1/2450: 7B           TDC 
C1/2451: E2 20        SEP #$20
C1/2453: 60           RTS 
C1/2454: A2 00 05     LDX #$0500
C1/2457: A0 00 06     LDY #$0600
C1/245A: 20 BB FD     JSR $FDBB
C1/245D: A2 00 05     LDX #$0500
C1/2460: 86 74        STX $74
C1/2462: 7B           TDC 
C1/2463: AA           TAX 
C1/2464: A4 74        LDY $74
C1/2466: BF 95 FF CE  LDA $CEFF95,X
C1/246A: 20 81 24     JSR $2481
C1/246D: C2 20        REP #$20
C1/246F: A5 74        LDA $74
C1/2471: 18           CLC 
C1/2472: 69 10 00     ADC #$0010
C1/2475: 85 74        STA $74
C1/2477: 7B           TDC 
C1/2478: E2 20        SEP #$20
C1/247A: E8           INX 
C1/247B: E0 30 00     CPX #$0030
C1/247E: D0 E4        BNE $2464
C1/2480: 60           RTS 
C1/2481: DA           PHX 
C1/2482: 85 7E        STA $7E
C1/2484: A9 10        LDA #$10
C1/2486: 85 80        STA $80
C1/2488: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/248B: C2 20        REP #$20
C1/248D: A5 82        LDA $82
C1/248F: 18           CLC 
C1/2490: 69 00 F0     ADC #$F000
C1/2493: AA           TAX 
C1/2494: A9 10 00     LDA #$0010
C1/2497: 85 70        STA $70
C1/2499: 7B           TDC 
C1/249A: E2 20        SEP #$20
C1/249C: A9 D1        LDA #$D1
C1/249E: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/24A1: FA           PLX 
C1/24A2: 60           RTS 

; pointers to character graphics
C1/24A3: 00 00 D2 00 ; bartz
C1/24A7: 00 94 D4 00 ; bartz (dead)
C1/24AB: 00 84 D2 00
C1/24AF: C0 94 D4 00
C1/24B3: 00 08 D3 00
C1/24B7: 80 95 D4 00
C1/24BB: 00 8C D3 00
C1/24BF: 40 96 D4 00
C1/24C3: 00 10 D4 00
C1/24C7: 00 97 D4 00

; pointers to character palettes (+$D40000)
C1/24CB: C0 A3
C1/24CD: 80 A6
C1/24CF: 40 A9
C1/24D1: 00 AC
C1/24D3: C0 AE

; [  ]

C1/24D5: 20 E2 24     JSR $24E2       ; load character graphics
C1/24D8: 20 C4 28     JSR $28C4       ; copy character graphics to vram
C1/24DB: 9C 61 DB     STZ $DB61
C1/24DE: 9C 60 DB     STZ $DB60
C1/24E1: 60           RTS 

; [ load character graphics ]

C1/24E2: A0 00 D0     LDY #$D000      ; destination address 7F/D000
C1/24E5: 84 7A        STY $7A
C1/24E7: A9 7F        LDA #$7F
C1/24E9: 85 7C        STA $7C
C1/24EB: 7B           TDC 
C1/24EC: A8           TAY 
C1/24ED: 5A           PHY 
C1/24EE: B9 C6 CF     LDA $CFC6,Y     ; character index
C1/24F1: C9 FF        CMP #$FF
C1/24F3: D0 10        BNE $2505
C1/24F5: C2 20        REP #$20
C1/24F7: A5 7A        LDA $7A
C1/24F9: 18           CLC 
C1/24FA: 69 00 08     ADC #$0800
C1/24FD: 85 7A        STA $7A
C1/24FF: 7B           TDC 
C1/2500: E2 20        SEP #$20
C1/2502: 4C 9A 25     JMP $259A
C1/2505: 0A           ASL 
C1/2506: 0A           ASL 
C1/2507: 0A           ASL 
C1/2508: AA           TAX 
C1/2509: C2 20        REP #$20
C1/250B: BF A3 24 C1  LDA $C124A3,X   ; pointer to character graphics
C1/250F: 85 70        STA $70
C1/2511: BF A5 24 C1  LDA $C124A5,X
C1/2515: 85 72        STA $72
C1/2517: BF A7 24 C1  LDA $C124A7,X   ; pointer to character graphics (dead)
C1/251B: 85 76        STA $76
C1/251D: BF A9 24 C1  LDA $C124A9,X
C1/2521: 85 78        STA $78
C1/2523: 7B           TDC 
C1/2524: E2 20        SEP #$20
C1/2526: B9 CA CF     LDA $CFCA,Y
C1/2529: 85 7E        STA $7E
C1/252B: 64 7F        STZ $7F
C1/252D: A2 00 06     LDX #$0600      ; graphics for each job are $0600 bytes
C1/2530: 86 80        STX $80
C1/2532: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/2535: A5 70        LDA $70
C1/2537: 18           CLC 
C1/2538: 65 82        ADC $82
C1/253A: 85 70        STA $70
C1/253C: A5 71        LDA $71
C1/253E: 65 83        ADC $83
C1/2540: 85 71        STA $71
C1/2542: A5 72        LDA $72
C1/2544: 65 84        ADC $84
C1/2546: 85 72        STA $72
C1/2548: C2 20        REP #$20
C1/254A: 7B           TDC 
C1/254B: A8           TAY 
C1/254C: B7 70        LDA [$70],Y     ; copy character graphics
C1/254E: 97 7A        STA [$7A],Y
C1/2550: C8           INY 
C1/2551: C8           INY 
C1/2552: C0 00 06     CPY #$0600
C1/2555: D0 F5        BNE $254C
C1/2557: A5 7A        LDA $7A
C1/2559: 18           CLC 
C1/255A: 69 00 06     ADC #$0600
C1/255D: 85 7A        STA $7A
C1/255F: 7B           TDC 
C1/2560: A8           TAY 
C1/2561: B7 76        LDA [$76],Y     ; copy dead character graphics
C1/2563: 97 7A        STA [$7A],Y
C1/2565: C8           INY 
C1/2566: C8           INY 
C1/2567: C0 C0 00     CPY #$00C0
C1/256A: D0 F5        BNE $2561
C1/256C: A5 7A        LDA $7A
C1/256E: 18           CLC 
C1/256F: 69 C0 00     ADC #$00C0
C1/2572: 85 7A        STA $7A
C1/2574: 7B           TDC 
C1/2575: E2 20        SEP #$20
C1/2577: A0 C0 03     LDY #$03C0
C1/257A: 20 A5 25     JSR $25A5
C1/257D: C2 20        REP #$20
C1/257F: 98           TYA 
C1/2580: 18           CLC 
C1/2581: 69 20 00     ADC #$0020
C1/2584: A8           TAY 
C1/2585: 7B           TDC 
C1/2586: E2 20        SEP #$20
C1/2588: C0 80 04     CPY #$0480
C1/258B: D0 ED        BNE $257A
C1/258D: C2 20        REP #$20
C1/258F: A5 7A        LDA $7A         ; next character
C1/2591: 18           CLC 
C1/2592: 69 80 00     ADC #$0080
C1/2595: 85 7A        STA $7A
C1/2597: 7B           TDC 
C1/2598: E2 20        SEP #$20
C1/259A: 7A           PLY 
C1/259B: C8           INY 
C1/259C: C0 04 00     CPY #$0004
C1/259F: F0 03        BEQ $25A4
C1/25A1: 4C ED 24     JMP $24ED
C1/25A4: 60           RTS 

; [  ]

C1/25A5: 5A           PHY 
C1/25A6: A2 00 00     LDX #$0000
C1/25A9: 20 E8 25     JSR $25E8
C1/25AC: C8           INY 
C1/25AD: A2 01 00     LDX #$0001
C1/25B0: 20 E8 25     JSR $25E8
C1/25B3: C2 20        REP #$20
C1/25B5: 98           TYA 
C1/25B6: 18           CLC 
C1/25B7: 69 0F 00     ADC #$000F
C1/25BA: A8           TAY 
C1/25BB: 7B           TDC 
C1/25BC: E2 20        SEP #$20
C1/25BE: A2 10 00     LDX #$0010
C1/25C1: 20 E8 25     JSR $25E8
C1/25C4: A2 11 00     LDX #$0011
C1/25C7: C8           INY 
C1/25C8: 20 E8 25     JSR $25E8
C1/25CB: 7B           TDC 
C1/25CC: A8           TAY 
C1/25CD: C2 20        REP #$20
C1/25CF: B9 F6 DB     LDA $DBF6,Y
C1/25D2: 97 7A        STA [$7A],Y
C1/25D4: C8           INY 
C1/25D5: C8           INY 
C1/25D6: C0 20 00     CPY #$0020
C1/25D9: D0 F4        BNE $25CF
C1/25DB: A5 7A        LDA $7A
C1/25DD: 18           CLC 
C1/25DE: 69 20 00     ADC #$0020
C1/25E1: 85 7A        STA $7A
C1/25E3: 7B           TDC 
C1/25E4: E2 20        SEP #$20
C1/25E6: 7A           PLY 
C1/25E7: 60           RTS 

; [  ]

C1/25E8: 5A           PHY 
C1/25E9: A9 08        LDA #$08
C1/25EB: 85 74        STA $74
C1/25ED: A9 08        LDA #$08
C1/25EF: 85 75        STA $75
C1/25F1: DA           PHX 
C1/25F2: B7 70        LDA [$70],Y
C1/25F4: 0A           ASL 
C1/25F5: 7E F6 DB     ROR $DBF6,X
C1/25F8: E8           INX 
C1/25F9: E8           INX 
C1/25FA: C6 75        DEC $75
C1/25FC: D0 F6        BNE $25F4
C1/25FE: C8           INY 
C1/25FF: C8           INY 
C1/2600: FA           PLX 
C1/2601: C6 74        DEC $74
C1/2603: D0 E8        BNE $25ED
C1/2605: 7A           PLY 
C1/2606: 60           RTS 

; [ load character palettes ]

C1/2607: 7B           TDC 
C1/2608: A8           TAY 
C1/2609: B9 C6 CF     LDA $CFC6,Y     ; character index
C1/260C: C9 FF        CMP #$FF
C1/260E: F0 72        BEQ $2682
C1/2610: 0A           ASL 
C1/2611: AA           TAX 
C1/2612: BF CB 24 C1  LDA $C124CB,X   ; pointers to character palettes
C1/2616: 85 70        STA $70
C1/2618: 85 74        STA $74
C1/261A: BF CC 24 C1  LDA $C124CC,X
C1/261E: 85 71        STA $71
C1/2620: 85 75        STA $75
C1/2622: B9 CA CF     LDA $CFCA,Y     ; job
C1/2625: C2 20        REP #$20
C1/2627: 0A           ASL 
C1/2628: 0A           ASL 
C1/2629: 0A           ASL 
C1/262A: 0A           ASL 
C1/262B: 0A           ASL 
C1/262C: 18           CLC 
C1/262D: 65 70        ADC $70
C1/262F: 85 70        STA $70
C1/2631: 98           TYA 
C1/2632: 0A           ASL 
C1/2633: 0A           ASL 
C1/2634: 0A           ASL 
C1/2635: 0A           ASL 
C1/2636: 0A           ASL 
C1/2637: AA           TAX 
C1/2638: A9 A0 02     LDA #$02A0      ; pointer for freelancer (for dead sprite)
C1/263B: 18           CLC 
C1/263C: 65 74        ADC $74
C1/263E: 85 74        STA $74
C1/2640: 7B           TDC 
C1/2641: E2 20        SEP #$20
C1/2643: 5A           PHY 
C1/2644: A9 D4        LDA #$D4
C1/2646: 85 72        STA $72
C1/2648: 85 76        STA $76
C1/264A: 7B           TDC 
C1/264B: A8           TAY 
C1/264C: AD 2B FF     LDA $FF2B
C1/264F: D0 07        BNE $2658
C1/2651: B7 70        LDA [$70],Y
C1/2653: 9D 89 7F     STA $7F89,X
C1/2656: 80 05        BRA $265D
C1/2658: B7 70        LDA [$70],Y
C1/265A: 9D 09 7F     STA $7F09,X
C1/265D: E8           INX 
C1/265E: C8           INY 
C1/265F: C0 20 00     CPY #$0020
C1/2662: D0 E8        BNE $264C
C1/2664: 7A           PLY 
C1/2665: 98           TYA 
C1/2666: 0A           ASL 
C1/2667: 0A           ASL 
C1/2668: 0A           ASL 
C1/2669: 0A           ASL 
C1/266A: 0A           ASL 
C1/266B: AA           TAX 
C1/266C: 5A           PHY 
C1/266D: 7B           TDC 
C1/266E: A8           TAY 
C1/266F: B7 74        LDA [$74],Y
C1/2671: 9D F6 EC     STA $ECF6,X
C1/2674: BD 89 7F     LDA $7F89,X
C1/2677: 9D 76 ED     STA $ED76,X
C1/267A: E8           INX 
C1/267B: C8           INY 
C1/267C: C0 20 00     CPY #$0020
C1/267F: D0 EE        BNE $266F
C1/2681: 7A           PLY             ; next character
C1/2682: C8           INY 
C1/2683: C0 04 00     CPY #$0004
C1/2686: D0 81        BNE $2609
C1/2688: 60           RTS 

C1/2689: A2 80 00     LDX #$0080
C1/268C: 86 70        STX $70
C1/268E: A2 C0 97     LDX #$97C0
C1/2691: A0 00 78     LDY #$7800
C1/2694: A9 D4        LDA #$D4
C1/2696: 20 A2 FC     JSR $FCA2
C1/2699: A0 48 7E     LDY #$7E48
C1/269C: A2 60 09     LDX #$0960
C1/269F: 20 AB 26     JSR $26AB
C1/26A2: A0 48 7F     LDY #$7F48
C1/26A5: A2 E0 0A     LDX #$0AE0
C1/26A8: 4C AB 26     JMP $26AB
C1/26AB: 84 70        STY $70
C1/26AD: 86 76        STX $76
C1/26AF: A9 0A        LDA #$0A
C1/26B1: 85 74        STA $74
C1/26B3: A5 70        LDA $70
C1/26B5: 8F 16 21 00  STA $002116
C1/26B9: A5 71        LDA $71
C1/26BB: 8F 17 21 00  STA $002117
C1/26BF: A9 08        LDA #$08
C1/26C1: 85 72        STA $72
C1/26C3: A6 76        LDX $76
C1/26C5: A4 76        LDY $76
C1/26C7: BF C0 97 D4  LDA $D497C0,X
C1/26CB: 1F C1 97 D4  ORA $D497C1,X
C1/26CF: DA           PHX 
C1/26D0: BB           TYX 
C1/26D1: 1F D0 97 D4  ORA $D497D0,X
C1/26D5: FA           PLX 
C1/26D6: 8F 19 21 00  STA $002119
C1/26DA: C8           INY 
C1/26DB: E8           INX 
C1/26DC: E8           INX 
C1/26DD: C6 72        DEC $72
C1/26DF: D0 E6        BNE $26C7
C1/26E1: C2 20        REP #$20
C1/26E3: A5 76        LDA $76
C1/26E5: 18           CLC 
C1/26E6: 69 18 00     ADC #$0018
C1/26E9: 85 76        STA $76
C1/26EB: A5 70        LDA $70
C1/26ED: 18           CLC 
C1/26EE: 69 10 00     ADC #$0010
C1/26F1: 85 70        STA $70
C1/26F3: 7B           TDC 
C1/26F4: E2 20        SEP #$20
C1/26F6: C6 74        DEC $74
C1/26F8: D0 B9        BNE $26B3
C1/26FA: 60           RTS 
C1/26FB: DA           PHX 
C1/26FC: 86 7E        STX $7E
C1/26FE: A2 05 00     LDX #$0005
C1/2701: 86 80        STX $80
C1/2703: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/2706: A6 82        LDX $82
C1/2708: BF 82 B1 D4  LDA $D4B182,X
C1/270C: 29 03        AND #$03
C1/270E: 85 71        STA $71
C1/2710: BF 83 B1 D4  LDA $D4B183,X
C1/2714: 85 70        STA $70
C1/2716: C2 20        REP #$20
C1/2718: A5 70        LDA $70
C1/271A: 0A           ASL 
C1/271B: 0A           ASL 
C1/271C: 0A           ASL 
C1/271D: 0A           ASL 
C1/271E: AA           TAX 
C1/271F: 7B           TDC 
C1/2720: A8           TAY 
C1/2721: BF 00 D0 CE  LDA $CED000,X
C1/2725: 99 89 7F     STA $7F89,Y
C1/2728: C8           INY 
C1/2729: C8           INY 
C1/272A: E8           INX 
C1/272B: E8           INX 
C1/272C: C0 20 00     CPY #$0020
C1/272F: D0 F0        BNE $2721
C1/2731: 7B           TDC 
C1/2732: E2 20        SEP #$20
C1/2734: FA           PLX 
C1/2735: 60           RTS 

; [  ]

C1/2736: 5A           PHY 
C1/2737: DA           PHX 
C1/2738: 86 7E        STX $7E
C1/273A: A2 05 00     LDX #$0005
C1/273D: 86 80        STX $80
C1/273F: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/2742: 7B           TDC 
C1/2743: AA           TAX 
C1/2744: 9E 92 F8     STZ $F892,X
C1/2747: E8           INX 
C1/2748: E0 20 00     CPX #$0020
C1/274B: D0 F7        BNE $2744
C1/274D: A6 82        LDX $82
C1/274F: 20 51 22     JSR $2251       ; get pointer to monster graphics
C1/2752: A9 D0        LDA #$D0
C1/2754: 85 78        STA $78
C1/2756: A5 70        LDA $70
C1/2758: 85 71        STA $71
C1/275A: BF 82 B1 D4  LDA $D4B182,X
C1/275E: 30 24        BMI $2784
C1/2760: BF 84 B1 D4  LDA $D4B184,X
C1/2764: C2 20        REP #$20
C1/2766: 0A           ASL 
C1/2767: 0A           ASL 
C1/2768: 0A           ASL 
C1/2769: 18           CLC 
C1/276A: 6F 00 D0 D0  ADC $D0D000
C1/276E: 85 76        STA $76
C1/2770: 7B           TDC 
C1/2771: E2 20        SEP #$20
C1/2773: AA           TAX 
C1/2774: A8           TAY 
C1/2775: B7 76        LDA [$76],Y
C1/2777: 9D 93 F8     STA $F893,X
C1/277A: C8           INY 
C1/277B: E8           INX 
C1/277C: E8           INX 
C1/277D: C0 08 00     CPY #$0008
C1/2780: D0 F3        BNE $2775
C1/2782: 80 1F        BRA $27A3
C1/2784: BF 84 B1 D4  LDA $D4B184,X
C1/2788: C2 20        REP #$20
C1/278A: 0A           ASL 
C1/278B: 0A           ASL 
C1/278C: 0A           ASL 
C1/278D: 0A           ASL 
C1/278E: 0A           ASL 
C1/278F: 18           CLC 
C1/2790: 6F 02 D0 D0  ADC $D0D002
C1/2794: 85 76        STA $76
C1/2796: 7B           TDC 
C1/2797: A8           TAY 
C1/2798: B7 76        LDA [$76],Y
C1/279A: 99 92 F8     STA $F892,Y
C1/279D: C8           INY 
C1/279E: C0 20 00     CPY #$0020
C1/27A1: D0 F5        BNE $2798
C1/27A3: C2 20        REP #$20
C1/27A5: A9 92 F8     LDA #$F892
C1/27A8: 85 76        STA $76
C1/27AA: A9 08 00     LDA #$0008
C1/27AD: 85 7E        STA $7E
C1/27AF: 7B           TDC 
C1/27B0: AA           TAX 
C1/27B1: A8           TAY 
C1/27B2: A9 08 00     LDA #$0008
C1/27B5: 85 80        STA $80
C1/27B7: B1 76        LDA ($76),Y
C1/27B9: 85 82        STA $82
C1/27BB: C8           INY 
C1/27BC: C8           INY 
C1/27BD: B1 76        LDA ($76),Y
C1/27BF: 05 82        ORA $82
C1/27C1: 85 82        STA $82
C1/27C3: C8           INY 
C1/27C4: C8           INY 
C1/27C5: 7B           TDC 
C1/27C6: 06 82        ASL $82
C1/27C8: 90 01        BCC $27CB
C1/27CA: 1A           INC 
C1/27CB: 9F 00 77 7F  STA $7F7700,X
C1/27CF: 7B           TDC 
C1/27D0: 06 82        ASL $82
C1/27D2: 90 01        BCC $27D5
C1/27D4: 1A           INC 
C1/27D5: 1F 00 77 7F  ORA $7F7700,X
C1/27D9: 9F 00 77 7F  STA $7F7700,X
C1/27DD: E8           INX 
C1/27DE: E8           INX 
C1/27DF: E8           INX 
C1/27E0: E8           INX 
C1/27E1: C6 80        DEC $80
C1/27E3: D0 E0        BNE $27C5
C1/27E5: C6 7E        DEC $7E
C1/27E7: D0 C9        BNE $27B2
C1/27E9: 7B           TDC 
C1/27EA: AA           TAX 
C1/27EB: A5 70        LDA $70
C1/27ED: 10 2A        BPL $2819
C1/27EF: A9 10 00     LDA #$0010
C1/27F2: 85 82        STA $82
C1/27F4: A9 10 00     LDA #$0010
C1/27F7: 85 7E        STA $7E
C1/27F9: B2 76        LDA ($76)
C1/27FB: 85 80        STA $80
C1/27FD: 06 80        ASL $80
C1/27FF: 90 05        BCC $2806
C1/2801: 20 00 29     JSR $2900
C1/2804: 80 03        BRA $2809
C1/2806: 20 5E 29     JSR $295E
C1/2809: C2 20        REP #$20
C1/280B: C6 7E        DEC $7E
C1/280D: D0 EE        BNE $27FD
C1/280F: E6 76        INC $76
C1/2811: E6 76        INC $76
C1/2813: C6 82        DEC $82
C1/2815: D0 DD        BNE $27F4
C1/2817: 80 28        BRA $2841
C1/2819: A9 10 00     LDA #$0010
C1/281C: 85 82        STA $82
C1/281E: A9 10 00     LDA #$0010
C1/2821: 85 7E        STA $7E
C1/2823: B2 76        LDA ($76)
C1/2825: 85 80        STA $80
C1/2827: 06 80        ASL $80
C1/2829: 90 05        BCC $2830
C1/282B: 20 D7 28     JSR $28D7
C1/282E: 80 03        BRA $2833
C1/2830: 20 5E 29     JSR $295E
C1/2833: C2 20        REP #$20
C1/2835: C6 7E        DEC $7E
C1/2837: D0 EE        BNE $2827
C1/2839: E6 76        INC $76
C1/283B: E6 76        INC $76
C1/283D: C6 82        DEC $82
C1/283F: D0 DD        BNE $281E
C1/2841: 7B           TDC 
C1/2842: AA           TAX 
C1/2843: A9 80 00     LDA #$0080
C1/2846: 85 72        STA $72
C1/2848: A9 10 00     LDA #$0010
C1/284B: 85 70        STA $70
C1/284D: BF 00 D0 7F  LDA $7FD000,X
C1/2851: 85 7E        STA $7E
C1/2853: BF 20 D0 7F  LDA $7FD020,X
C1/2857: 9F 00 D0 7F  STA $7FD000,X
C1/285B: A5 7E        LDA $7E
C1/285D: 9F 20 D0 7F  STA $7FD020,X
C1/2861: E8           INX 
C1/2862: E8           INX 
C1/2863: C6 70        DEC $70
C1/2865: D0 E6        BNE $284D
C1/2867: 8A           TXA 
C1/2868: 18           CLC 
C1/2869: 69 20 00     ADC #$0020
C1/286C: AA           TAX 
C1/286D: C6 72        DEC $72
C1/286F: D0 D7        BNE $2848
C1/2871: A9 92 F8     LDA #$F892
C1/2874: 85 76        STA $76
C1/2876: A9 10 00     LDA #$0010
C1/2879: 85 7E        STA $7E
C1/287B: 64 84        STZ $84
C1/287D: 64 72        STZ $72
C1/287F: 7B           TDC 
C1/2880: A8           TAY 
C1/2881: A9 10 00     LDA #$0010
C1/2884: 85 80        STA $80
C1/2886: B1 76        LDA ($76),Y
C1/2888: 85 82        STA $82
C1/288A: 64 70        STZ $70
C1/288C: B1 76        LDA ($76),Y
C1/288E: F0 02        BEQ $2892
C1/2890: E6 72        INC $72
C1/2892: 06 82        ASL $82
C1/2894: 90 08        BCC $289E
C1/2896: A5 70        LDA $70
C1/2898: C5 84        CMP $84
C1/289A: 90 02        BCC $289E
C1/289C: 85 84        STA $84
C1/289E: E6 70        INC $70
C1/28A0: C6 80        DEC $80
C1/28A2: D0 EE        BNE $2892
C1/28A4: C8           INY 
C1/28A5: C8           INY 
C1/28A6: C6 7E        DEC $7E
C1/28A8: D0 D7        BNE $2881
C1/28AA: 7B           TDC 
C1/28AB: E2 20        SEP #$20
C1/28AD: A5 72        LDA $72
C1/28AF: 48           PHA 
C1/28B0: A5 84        LDA $84
C1/28B2: 48           PHA 
C1/28B3: 20 C4 28     JSR $28C4       ; copy character graphics to vram
C1/28B6: 68           PLA 
C1/28B7: 1A           INC 
C1/28B8: 85 74        STA $74
C1/28BA: 68           PLA 
C1/28BB: 85 76        STA $76
C1/28BD: 64 75        STZ $75
C1/28BF: 64 77        STZ $77
C1/28C1: FA           PLX 
C1/28C2: 7A           PLY 
C1/28C3: 60           RTS 

; [ copy character graphics to vram ]

C1/28C4: DA           PHX 
C1/28C5: A2 00 20     LDX #$2000      ; size
C1/28C8: 86 70        STX $70
C1/28CA: A2 00 D0     LDX #$D000      ; 7F/D000 (character graphics buffer)
C1/28CD: A0 00 60     LDY #$6000      ; vram address
C1/28D0: A9 7F        LDA #$7F
C1/28D2: 20 27 FD     JSR $FD27
C1/28D5: FA           PLX 
C1/28D6: 60           RTS 

; [  ]

C1/28D7: C2 20        REP #$20
C1/28D9: 7B           TDC 
C1/28DA: A8           TAY 
C1/28DB: B7 72        LDA [$72],Y
C1/28DD: 20 3D 29     JSR $293D
C1/28E0: 9F 00 D0 7F  STA $7FD000,X
C1/28E4: E8           INX 
C1/28E5: E8           INX 
C1/28E6: C8           INY 
C1/28E7: C8           INY 
C1/28E8: C0 20 00     CPY #$0020
C1/28EB: D0 EE        BNE $28DB
C1/28ED: A5 72        LDA $72
C1/28EF: 18           CLC 
C1/28F0: 69 20 00     ADC #$0020
C1/28F3: 85 72        STA $72
C1/28F5: A5 74        LDA $74
C1/28F7: 69 00 00     ADC #$0000
C1/28FA: 85 74        STA $74
C1/28FC: 7B           TDC 
C1/28FD: E2 20        SEP #$20
C1/28FF: 60           RTS 
C1/2900: C2 20        REP #$20
C1/2902: 7B           TDC 
C1/2903: A8           TAY 
C1/2904: B7 72        LDA [$72],Y
C1/2906: 20 3D 29     JSR $293D
C1/2909: 9F 00 D0 7F  STA $7FD000,X
C1/290D: E8           INX 
C1/290E: E8           INX 
C1/290F: C8           INY 
C1/2910: C8           INY 
C1/2911: C0 10 00     CPY #$0010
C1/2914: D0 EE        BNE $2904
C1/2916: B7 72        LDA [$72],Y
C1/2918: 29 FF 00     AND #$00FF
C1/291B: 20 3D 29     JSR $293D
C1/291E: 9F 00 D0 7F  STA $7FD000,X
C1/2922: E8           INX 
C1/2923: E8           INX 
C1/2924: C8           INY 
C1/2925: C0 18 00     CPY #$0018
C1/2928: D0 EC        BNE $2916
C1/292A: A5 72        LDA $72
C1/292C: 18           CLC 
C1/292D: 69 18 00     ADC #$0018
C1/2930: 85 72        STA $72
C1/2932: A5 74        LDA $74
C1/2934: 69 00 00     ADC #$0000
C1/2937: 85 74        STA $74
C1/2939: 7B           TDC 
C1/293A: E2 20        SEP #$20
C1/293C: 60           RTS 
C1/293D: DA           PHX 
C1/293E: 85 84        STA $84
C1/2940: E2 20        SEP #$20
C1/2942: A2 08 00     LDX #$0008
C1/2945: A5 84        LDA $84
C1/2947: 0A           ASL 
C1/2948: 66 84        ROR $84
C1/294A: CA           DEX 
C1/294B: D0 FA        BNE $2947
C1/294D: A2 08 00     LDX #$0008
C1/2950: A5 85        LDA $85
C1/2952: 0A           ASL 
C1/2953: 66 85        ROR $85
C1/2955: CA           DEX 
C1/2956: D0 FA        BNE $2952
C1/2958: C2 20        REP #$20
C1/295A: A5 84        LDA $84
C1/295C: FA           PLX 
C1/295D: 60           RTS 
C1/295E: C2 20        REP #$20
C1/2960: A0 10 00     LDY #$0010
C1/2963: 7B           TDC 
C1/2964: 9F 00 D0 7F  STA $7FD000,X
C1/2968: E8           INX 
C1/2969: E8           INX 
C1/296A: 88           DEY 
C1/296B: D0 F7        BNE $2964
C1/296D: 7B           TDC 
C1/296E: E2 20        SEP #$20
C1/2970: 60           RTS 

; ===============================[ text strings ]===============================

; [ draw big text string ]

C1/2971: AE A0 BC     LDX $BCA0
C1/2974: 86 B8        STX $B8
C1/2976: AD A2 BC     LDA $BCA2
C1/2979: 85 BA        STA $BA
C1/297B: A7 B8        LDA [$B8]
C1/297D: F0 1A        BEQ $2999
C1/297F: C9 01        CMP #$01
C1/2981: F0 16        BEQ $2999
C1/2983: C9 20        CMP #$20
C1/2985: 90 09        BCC $2990
C1/2987: 20 F1 2C     JSR $2CF1
C1/298A: 20 9A 29     JSR $299A       ; get next byte
C1/298D: 4C 7B 29     JMP $297B
C1/2990: 20 A0 29     JSR $29A0       ; do big text escape code
C1/2993: 20 9A 29     JSR $299A       ; get next byte
C1/2996: 4C 7B 29     JMP $297B
C1/2999: 60           RTS 

; [ get next byte of string ]

C1/299A: A6 B8        LDX $B8
C1/299C: E8           INX 
C1/299D: 86 B8        STX $B8
C1/299F: 60           RTS 

; [ do big text escape code ]

C1/29A0: 0A           ASL 
C1/29A1: AA           TAX 
C1/29A2: BF B1 29 C1  LDA $C129B1,X
C1/29A6: 85 70        STA $70
C1/29A8: BF B2 29 C1  LDA $C129B2,X
C1/29AC: 85 71        STA $71
C1/29AE: 6C 70 00     JMP ($0070)

; jump table for escape codes $00-$1F
C1/29B1: 2F0F 2F0F 2F0F 2F0F 2F0F 2C9A 2F0F 2F0F ; $00
C1/29C1: 2F0F 2F0F 2F0F 2F0F 2F0F 2F0F 2C81 2C15
C1/29D1: 2B35 2B13 2AF9 2A90 2A6E 2A2F 29F1 2F0F ; $10
C1/29E1: 2BDB 2B9D 2BB6 2F0F 2F0F 2F0F 2CAB 2CB2

; [ $16: butz' name ]

C1/29F1: 7B           TDC 
C1/29F2: AA           TAX 
C1/29F3: 64 7E        STZ $7E
C1/29F5: BD 00 05     LDA $0500,X
C1/29F8: 29 07        AND #$07
C1/29FA: F0 12        BEQ $2A0E
C1/29FC: C2 20        REP #$20
C1/29FE: 8A           TXA 
C1/29FF: 18           CLC 
C1/2A00: 69 50 00     ADC #$0050
C1/2A03: AA           TAX 
C1/2A04: 7B           TDC 
C1/2A05: E2 20        SEP #$20
C1/2A07: E0 40 01     CPX #$0140
C1/2A0A: D0 E9        BNE $29F5
C1/2A0C: 64 7E        STZ $7E
C1/2A0E: A5 7E        LDA $7E
C1/2A10: AA           TAX 
C1/2A11: BF 2A 2A C1  LDA $C12A2A,X
C1/2A15: AA           TAX 
C1/2A16: A9 06        LDA #$06        ; copy 6 letters
C1/2A18: 85 70        STA $70
C1/2A1A: BD 90 09     LDA $0990,X
C1/2A1D: C9 FF        CMP #$FF
C1/2A1F: F0 08        BEQ $2A29
C1/2A21: 20 F1 2C     JSR $2CF1
C1/2A24: E8           INX 
C1/2A25: C6 70        DEC $70
C1/2A27: D0 F1        BNE $2A1A
C1/2A29: 60           RTS 

; pointers to character names (+$0990)
C1/2A2A: 00 06 0C 12 18

; [ $15: battle command name ]

C1/2A2F: B2 F4        LDA ($F4)       ; message variable
C1/2A31: 30 18        BMI $2A4B
C1/2A33: 20 CF 2B     JSR $2BCF
C1/2A36: A9 05        LDA #$05
C1/2A38: 85 70        STA $70
C1/2A3A: BF 00 58 D1  LDA $D15800,X
C1/2A3E: C9 FF        CMP #$FF
C1/2A40: F0 08        BEQ $2A4A
C1/2A42: 20 F1 2C     JSR $2CF1
C1/2A45: E8           INX 
C1/2A46: C6 70        DEC $70
C1/2A48: D0 F0        BNE $2A3A
C1/2A4A: 60           RTS 
C1/2A4B: 38           SEC 
C1/2A4C: E9 80        SBC #$80
C1/2A4E: 85 7E        STA $7E
C1/2A50: A9 08        LDA #$08
C1/2A52: 85 80        STA $80
C1/2A54: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2A57: A6 82        LDX $82
C1/2A59: A9 08        LDA #$08
C1/2A5B: 85 70        STA $70
C1/2A5D: BF 00 62 D1  LDA $D16200,X
C1/2A61: C9 FF        CMP #$FF
C1/2A63: F0 08        BEQ $2A6D
C1/2A65: 20 F1 2C     JSR $2CF1
C1/2A68: E8           INX 
C1/2A69: C6 70        DEC $70
C1/2A6B: D0 F0        BNE $2A5D
C1/2A6D: 60           RTS 

; [ $14: job name ]

C1/2A6E: B2 F4        LDA ($F4)
C1/2A70: 85 7E        STA $7E
C1/2A72: A9 08        LDA #$08
C1/2A74: 85 80        STA $80
C1/2A76: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2A79: A6 82        LDX $82
C1/2A7B: A9 08        LDA #$08
C1/2A7D: 85 70        STA $70
C1/2A7F: BF 00 56 D1  LDA $D15600,X
C1/2A83: C9 FF        CMP #$FF
C1/2A85: F0 08        BEQ $2A8F
C1/2A87: 20 F1 2C     JSR $2CF1
C1/2A8A: E8           INX 
C1/2A8B: C6 70        DEC $70
C1/2A8D: D0 F0        BNE $2A7F
C1/2A8F: 60           RTS 

; [ $13: attack name ]

C1/2A90: B2 F4        LDA ($F4)
C1/2A92: C9 57        CMP #$57
C1/2A94: 90 21        BCC $2AB7
C1/2A96: 38           SEC 
C1/2A97: E9 57        SBC #$57
C1/2A99: 85 7E        STA $7E
C1/2A9B: A9 09        LDA #$09
C1/2A9D: 85 70        STA $70
C1/2A9F: 85 80        STA $80
C1/2AA1: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2AA4: A6 82        LDX $82
C1/2AA6: BF 8A 1E D1  LDA $D11E8A,X
C1/2AAA: C9 FF        CMP #$FF
C1/2AAC: F0 08        BEQ $2AB6
C1/2AAE: 20 F1 2C     JSR $2CF1
C1/2AB1: E8           INX 
C1/2AB2: C6 70        DEC $70
C1/2AB4: D0 F0        BNE $2AA6
C1/2AB6: 60           RTS 
C1/2AB7: C9 48        CMP #$48
C1/2AB9: 90 1E        BCC $2AD9
C1/2ABB: 85 7E        STA $7E
C1/2ABD: A9 06        LDA #$06
C1/2ABF: 85 70        STA $70
C1/2AC1: 85 80        STA $80
C1/2AC3: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2AC6: A6 82        LDX $82
C1/2AC8: BF 80 1C D1  LDA $D11C80,X
C1/2ACC: C9 FF        CMP #$FF
C1/2ACE: F0 08        BEQ $2AD8
C1/2AD0: 20 F1 2C     JSR $2CF1
C1/2AD3: E8           INX 
C1/2AD4: C6 70        DEC $70
C1/2AD6: D0 F0        BNE $2AC8
C1/2AD8: 60           RTS 
C1/2AD9: 85 7E        STA $7E
C1/2ADB: A9 06        LDA #$06
C1/2ADD: 85 80        STA $80
C1/2ADF: A9 05        LDA #$05
C1/2AE1: 85 70        STA $70
C1/2AE3: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2AE6: A6 82        LDX $82
C1/2AE8: BF 81 1C D1  LDA $D11C81,X
C1/2AEC: C9 FF        CMP #$FF
C1/2AEE: F0 08        BEQ $2AF8
C1/2AF0: 20 F1 2C     JSR $2CF1
C1/2AF3: E8           INX 
C1/2AF4: C6 70        DEC $70
C1/2AF6: D0 F0        BNE $2AE8
C1/2AF8: 60           RTS 

; [ $12: item name ]

C1/2AF9: B2 F4        LDA ($F4)
C1/2AFB: 20 75 2C     JSR $2C75
C1/2AFE: A9 08        LDA #$08
C1/2B00: 85 70        STA $70
C1/2B02: BF 81 13 D1  LDA $D11381,X
C1/2B06: C9 FF        CMP #$FF
C1/2B08: F0 08        BEQ $2B12
C1/2B0A: 20 F1 2C     JSR $2CF1
C1/2B0D: E8           INX 
C1/2B0E: C6 70        DEC $70
C1/2B10: D0 F0        BNE $2B02
C1/2B12: 60           RTS 

; [ $11: character name ]

C1/2B13: B2 F4        LDA ($F4)
C1/2B15: 85 7E        STA $7E
C1/2B17: A9 06        LDA #$06
C1/2B19: 85 80        STA $80
C1/2B1B: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2B1E: A6 82        LDX $82
C1/2B20: A9 06        LDA #$06
C1/2B22: 85 76        STA $76
C1/2B24: BF 90 09 00  LDA $000990,X
C1/2B28: C9 FF        CMP #$FF
C1/2B2A: F0 08        BEQ $2B34
C1/2B2C: 20 F1 2C     JSR $2CF1
C1/2B2F: E8           INX 
C1/2B30: C6 76        DEC $76
C1/2B32: D0 F0        BNE $2B24
C1/2B34: 60           RTS 

; [  ]

C1/2B35: 5A           PHY 
C1/2B36: 20 9A 29     JSR $299A       ; get next byte
C1/2B39: A7 B8        LDA [$B8]
C1/2B3B: 85 7E        STA $7E
C1/2B3D: 0A           ASL 
C1/2B3E: 18           CLC 
C1/2B3F: 65 7E        ADC $7E
C1/2B41: A8           TAY 
C1/2B42: B1 F4        LDA ($F4),Y
C1/2B44: 85 70        STA $70
C1/2B46: C8           INY 
C1/2B47: B1 F4        LDA ($F4),Y
C1/2B49: 85 71        STA $71
C1/2B4B: C8           INY 
C1/2B4C: B1 F4        LDA ($F4),Y
C1/2B4E: 85 72        STA $72
C1/2B50: A5 70        LDA $70
C1/2B52: C9 FF        CMP #$FF
C1/2B54: D0 1C        BNE $2B72
C1/2B56: A5 71        LDA $71
C1/2B58: C9 FF        CMP #$FF
C1/2B5A: D0 16        BNE $2B72
C1/2B5C: A5 72        LDA $72
C1/2B5E: C9 FF        CMP #$FF
C1/2B60: D0 10        BNE $2B72
C1/2B62: A2 00 00     LDX #$0000
C1/2B65: A9 CB        LDA #$CB
C1/2B67: 20 F1 2C     JSR $2CF1
C1/2B6A: E8           INX 
C1/2B6B: E0 04 00     CPX #$0004
C1/2B6E: D0 F5        BNE $2B65
C1/2B70: 7A           PLY 
C1/2B71: 60           RTS 
C1/2B72: 20 88 FF     JSR $FF88       ; convert hex to decimal digits
C1/2B75: 20 FE FE     JSR $FEFE
C1/2B78: B5 C4        LDA $C4,X
C1/2B7A: 20 F1 2C     JSR $2CF1
C1/2B7D: E8           INX 
C1/2B7E: E0 08 00     CPX #$0008
C1/2B81: D0 F5        BNE $2B78
C1/2B83: 7A           PLY 
C1/2B84: 60           RTS 

; [  ]

C1/2B85: 85 7E        STA $7E
C1/2B87: A9 09        LDA #$09
C1/2B89: 85 80        STA $80
C1/2B8B: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2B8E: A6 82        LDX $82
C1/2B90: 60           RTS 

; [  ]

C1/2B91: 85 7E        STA $7E
C1/2B93: A9 08        LDA #$08
C1/2B95: 85 80        STA $80
C1/2B97: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2B9A: A6 82        LDX $82
C1/2B9C: 60           RTS 

; [ $19: special ability name (animals/conjure/combine/terrain) ]

C1/2B9D: 20 9A 29     JSR $299A       ; get next byte
C1/2BA0: A7 B8        LDA [$B8]
C1/2BA2: 20 85 2B     JSR $2B85
C1/2BA5: A9 09        LDA #$09
C1/2BA7: 85 70        STA $70
C1/2BA9: BF 00 67 D1  LDA $D16700,X
C1/2BAD: 20 F1 2C     JSR $2CF1
C1/2BB0: E8           INX 
C1/2BB1: C6 70        DEC $70
C1/2BB3: D0 F4        BNE $2BA9
C1/2BB5: 60           RTS 

; [ $1A: monster special attack name ]

C1/2BB6: 20 9A 29     JSR $299A       ; get next byte
C1/2BB9: A7 B8        LDA [$B8]
C1/2BBB: 20 91 2B     JSR $2B91
C1/2BBE: A9 08        LDA #$08
C1/2BC0: 85 70        STA $70
C1/2BC2: BF 00 87 D0  LDA $D08700,X
C1/2BC6: 20 F1 2C     JSR $2CF1
C1/2BC9: E8           INX 
C1/2BCA: C6 70        DEC $70
C1/2BCC: D0 F4        BNE $2BC2
C1/2BCE: 60           RTS 
C1/2BCF: 85 7E        STA $7E
C1/2BD1: A9 05        LDA #$05
C1/2BD3: 85 80        STA $80
C1/2BD5: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2BD8: A6 82        LDX $82
C1/2BDA: 60           RTS 

; [ $18: ability name ]

C1/2BDB: 20 9A 29     JSR $299A       ; get next byte
C1/2BDE: A7 B8        LDA [$B8]
C1/2BE0: C9 80        CMP #$80
C1/2BE2: 90 1D        BCC $2C01
C1/2BE4: 38           SEC 
C1/2BE5: E9 80        SBC #$80
C1/2BE7: 85 7E        STA $7E
C1/2BE9: A9 08        LDA #$08
C1/2BEB: 85 70        STA $70
C1/2BED: 85 80        STA $80
C1/2BEF: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2BF2: A6 7E        LDX $7E
C1/2BF4: BF 00 62 D1  LDA $D16200,X
C1/2BF8: 20 F1 2C     JSR $2CF1
C1/2BFB: E8           INX 
C1/2BFC: C6 70        DEC $70
C1/2BFE: D0 F4        BNE $2BF4
C1/2C00: 60           RTS 
C1/2C01: 20 CF 2B     JSR $2BCF
C1/2C04: A9 05        LDA #$05
C1/2C06: 85 70        STA $70
C1/2C08: BF 00 58 D1  LDA $D15800,X
C1/2C0C: 20 F1 2C     JSR $2CF1
C1/2C0F: E8           INX 
C1/2C10: C6 70        DEC $70
C1/2C12: D0 F4        BNE $2C08
C1/2C14: 60           RTS 

; [ $0F: attack name ]

C1/2C15: 20 9A 29     JSR $299A       ; get next byte
C1/2C18: A7 B8        LDA [$B8]
C1/2C1A: C9 57        CMP #$57
C1/2C1C: 90 1D        BCC $2C3B
C1/2C1E: 38           SEC 
C1/2C1F: E9 57        SBC #$57
C1/2C21: 85 7E        STA $7E
C1/2C23: A9 09        LDA #$09
C1/2C25: 85 70        STA $70
C1/2C27: 85 80        STA $80
C1/2C29: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2C2C: A6 82        LDX $82
C1/2C2E: BF 8A 1E D1  LDA $D11E8A,X
C1/2C32: 20 F1 2C     JSR $2CF1
C1/2C35: E8           INX 
C1/2C36: C6 70        DEC $70
C1/2C38: D0 F4        BNE $2C2E
C1/2C3A: 60           RTS 
C1/2C3B: C9 48        CMP #$48
C1/2C3D: 90 1A        BCC $2C59
C1/2C3F: 85 7E        STA $7E
C1/2C41: A9 06        LDA #$06
C1/2C43: 85 70        STA $70
C1/2C45: 85 80        STA $80
C1/2C47: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2C4A: A6 82        LDX $82
C1/2C4C: BF 80 1C D1  LDA $D11C80,X
C1/2C50: 20 F1 2C     JSR $2CF1
C1/2C53: E8           INX 
C1/2C54: C6 70        DEC $70
C1/2C56: D0 F4        BNE $2C4C
C1/2C58: 60           RTS 
C1/2C59: 85 7E        STA $7E
C1/2C5B: A9 06        LDA #$06
C1/2C5D: 85 80        STA $80
C1/2C5F: A9 05        LDA #$05
C1/2C61: 85 70        STA $70
C1/2C63: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2C66: A6 82        LDX $82
C1/2C68: BF 81 1C D1  LDA $D11C81,X
C1/2C6C: 20 F1 2C     JSR $2CF1
C1/2C6F: E8           INX 
C1/2C70: C6 70        DEC $70
C1/2C72: D0 F4        BNE $2C68
C1/2C74: 60           RTS 
C1/2C75: 85 7E        STA $7E
C1/2C77: A9 09        LDA #$09
C1/2C79: 85 80        STA $80
C1/2C7B: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2C7E: A6 82        LDX $82
C1/2C80: 60           RTS 

; [ $0E: item name ]

C1/2C81: 20 9A 29     JSR $299A       ; get next byte
C1/2C84: A7 B8        LDA [$B8]
C1/2C86: 20 75 2C     JSR $2C75
C1/2C89: A9 08        LDA #$08
C1/2C8B: 85 70        STA $70
C1/2C8D: BF 81 13 D1  LDA $D11381,X
C1/2C91: 20 F1 2C     JSR $2CF1
C1/2C94: E8           INX 
C1/2C95: C6 70        DEC $70
C1/2C97: D0 F4        BNE $2C8D
C1/2C99: 60           RTS 

C1/2C9A: 20 9A 29     JSR $299A       ; get next byte
C1/2C9D: A7 B8        LDA [$B8]
C1/2C9F: 85 70        STA $70
C1/2CA1: A9 FF        LDA #$FF
C1/2CA3: 20 F1 2C     JSR $2CF1
C1/2CA6: C6 70        DEC $70
C1/2CA8: D0 F7        BNE $2CA1
C1/2CAA: 60           RTS 

; [  ]

C1/2CAB: A2 00 00     LDX #$0000
C1/2CAE: 86 70        STX $70
C1/2CB0: 80 05        BRA $2CB7

; [ $1F: kanji ]

C1/2CB2: A2 00 01     LDX #$0100
C1/2CB5: 86 70        STX $70
C1/2CB7: 5A           PHY 
C1/2CB8: DA           PHX 
C1/2CB9: 20 9A 29     JSR $299A       ; get next byte
C1/2CBC: A7 B8        LDA [$B8]
C1/2CBE: C2 20        REP #$20
C1/2CC0: 18           CLC 
C1/2CC1: 65 70        ADC $70
C1/2CC3: 85 7E        STA $7E
C1/2CC5: 7B           TDC 
C1/2CC6: E2 20        SEP #$20
C1/2CC8: A2 18 00     LDX #$0018
C1/2CCB: 86 80        STX $80
C1/2CCD: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/2CD0: A6 82        LDX $82
C1/2CD2: A0 00 00     LDY #$0000
C1/2CD5: BF 00 D0 DB  LDA $DBD000,X   ; kanji graphics
C1/2CD9: 99 08 F5     STA $F508,Y
C1/2CDC: BF 0C D0 DB  LDA $DBD00C,X
C1/2CE0: 99 14 F5     STA $F514,Y
C1/2CE3: 7B           TDC 
C1/2CE4: 99 20 F5     STA $F520,Y
C1/2CE7: E8           INX 
C1/2CE8: C8           INY 
C1/2CE9: C0 0C 00     CPY #$000C
C1/2CEC: D0 E7        BNE $2CD5
C1/2CEE: 4C 1F 2D     JMP $2D1F

; [ draw kana ]

C1/2CF1: 5A           PHY 
C1/2CF2: DA           PHX 
C1/2CF3: 38           SEC 
C1/2CF4: E9 20        SBC #$20
C1/2CF6: AA           TAX 
C1/2CF7: 86 7E        STX $7E
C1/2CF9: A2 18 00     LDX #$0018
C1/2CFC: 86 80        STX $80
C1/2CFE: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/2D01: A6 82        LDX $82
C1/2D03: A0 00 00     LDY #$0000
C1/2D06: BF 00 EB C3  LDA $C3EB00,X   ; kana graphics
C1/2D0A: 99 08 F5     STA $F508,Y
C1/2D0D: BF 0C EB C3  LDA $C3EB0C,X
C1/2D11: 99 14 F5     STA $F514,Y
C1/2D14: 7B           TDC 
C1/2D15: 99 20 F5     STA $F520,Y
C1/2D18: E8           INX 
C1/2D19: C8           INY 
C1/2D1A: C0 0C 00     CPY #$000C
C1/2D1D: D0 E7        BNE $2D06
C1/2D1F: AD 07 F5     LDA $F507       ; text horizontal position
C1/2D22: 29 07        AND #$07
C1/2D24: F0 18        BEQ $2D3E
C1/2D26: 85 74        STA $74
C1/2D28: A2 00 00     LDX #$0000
C1/2D2B: 5E 08 F5     LSR $F508,X     ; shift pixels right
C1/2D2E: 7E 14 F5     ROR $F514,X
C1/2D31: 7E 20 F5     ROR $F520,X
C1/2D34: E8           INX 
C1/2D35: E0 0C 00     CPX #$000C
C1/2D38: D0 F1        BNE $2D2B
C1/2D3A: C6 74        DEC $74
C1/2D3C: D0 EA        BNE $2D28
C1/2D3E: AD 07 F5     LDA $F507
C1/2D41: 4A           LSR 
C1/2D42: 4A           LSR 
C1/2D43: 4A           LSR 
C1/2D44: 85 7E        STA $7E
C1/2D46: A9 10        LDA #$10
C1/2D48: 85 80        STA $80
C1/2D4A: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2D4D: A6 82        LDX $82
C1/2D4F: AD F1 DB     LDA $DBF1       ; $DFB1 determines which buffer to draw to
C1/2D52: F0 27        BEQ $2D7B
C1/2D54: A0 00 00     LDY #$0000
C1/2D57: BD 37 A9     LDA $A937,X
C1/2D5A: 19 08 F5     ORA $F508,Y
C1/2D5D: 9D 37 A9     STA $A937,X
C1/2D60: BD 47 A9     LDA $A947,X
C1/2D63: 19 14 F5     ORA $F514,Y
C1/2D66: 9D 47 A9     STA $A947,X
C1/2D69: BD 57 A9     LDA $A957,X
C1/2D6C: 19 20 F5     ORA $F520,Y
C1/2D6F: 9D 57 A9     STA $A957,X
C1/2D72: E8           INX 
C1/2D73: C8           INY 
C1/2D74: C0 0C 00     CPY #$000C
C1/2D77: D0 DE        BNE $2D57
C1/2D79: 80 25        BRA $2DA0
C1/2D7B: A0 00 00     LDY #$0000
C1/2D7E: BD 57 F3     LDA $F357,X
C1/2D81: 19 08 F5     ORA $F508,Y
C1/2D84: 9D 57 F3     STA $F357,X
C1/2D87: BD 67 F3     LDA $F367,X
C1/2D8A: 19 14 F5     ORA $F514,Y
C1/2D8D: 9D 67 F3     STA $F367,X
C1/2D90: BD 77 F3     LDA $F377,X
C1/2D93: 19 20 F5     ORA $F520,Y
C1/2D96: 9D 77 F3     STA $F377,X
C1/2D99: E8           INX 
C1/2D9A: C8           INY 
C1/2D9B: C0 0C 00     CPY #$000C
C1/2D9E: D0 DE        BNE $2D7E
C1/2DA0: AD 07 F5     LDA $F507
C1/2DA3: 18           CLC 
C1/2DA4: 69 0D        ADC #$0D        ; all characters are 13 pixels wide
C1/2DA6: 8D 07 F5     STA $F507
C1/2DA9: FA           PLX 
C1/2DAA: 7A           PLY 
C1/2DAB: 60           RTS 

; [ draw small text ]

C1/2DAC: AD A5 BC     LDA $BCA5       ; tile flags
C1/2DAF: 85 BE        STA $BE
C1/2DB1: 0E A4 BC     ASL $BCA4
C1/2DB4: AE A0 BC     LDX $BCA0       ; source address
C1/2DB7: 86 B8        STX $B8
C1/2DB9: AE A2 BC     LDX $BCA2       ; destination address
C1/2DBC: 86 BA        STX $BA
C1/2DBE: A5 BA        LDA $BA
C1/2DC0: 18           CLC 
C1/2DC1: 6D A4 BC     ADC $BCA4       ; line width (kana line - dakuten line)
C1/2DC4: 85 BC        STA $BC
C1/2DC6: A5 BB        LDA $BB
C1/2DC8: 69 00        ADC #$00
C1/2DCA: 85 BD        STA $BD
C1/2DCC: A0 00 00     LDY #$0000
C1/2DCF: B2 B8        LDA ($B8)
C1/2DD1: F0 16        BEQ $2DE9
C1/2DD3: C9 20        CMP #$20
C1/2DD5: 90 09        BCC $2DE0
C1/2DD7: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2DDA: 20 9A 29     JSR $299A       ; get next byte
C1/2DDD: 4C CF 2D     JMP $2DCF
C1/2DE0: 20 5D 2F     JSR $2F5D       ; decode small text escape code
C1/2DE3: 20 9A 29     JSR $299A       ; get next byte
C1/2DE6: 4C CF 2D     JMP $2DCF
C1/2DE9: 60           RTS 

; [ draw small text character ]

C1/2DEA: C9 53        CMP #$53
C1/2DEC: 90 0F        BCC $2DFD
C1/2DEE: 91 BC        STA ($BC),Y
C1/2DF0: A9 FF        LDA #$FF        ; no dakuten
C1/2DF2: 91 BA        STA ($BA),Y
C1/2DF4: C8           INY 
C1/2DF5: A5 BE        LDA $BE         ; tile flags
C1/2DF7: 91 BC        STA ($BC),Y
C1/2DF9: 91 BA        STA ($BA),Y
C1/2DFB: C8           INY 
C1/2DFC: 60           RTS 
C1/2DFD: C9 49        CMP #$49
C1/2DFF: 90 0A        BCC $2E0B
C1/2E01: 18           CLC 
C1/2E02: 69 17        ADC #$17
C1/2E04: 91 BC        STA ($BC),Y
C1/2E06: A9 52        LDA #$52        ; handakuten
C1/2E08: 4C F2 2D     JMP $2DF2
C1/2E0B: 18           CLC 
C1/2E0C: 69 40        ADC #$40
C1/2E0E: 91 BC        STA ($BC),Y
C1/2E10: A9 51        LDA #$51        ; dakuten
C1/2E12: 4C F2 2D     JMP $2DF2

; jump table for small text escape codes $00-$20
C1/2E15: 2F0F 2F10 2F0F 2F55 2F0F 2F31 2F42 3061 ; $00
C1/2E25: 306E 307B 3088 3004 303E 2F29 2FE3 2FA3
C1/2E35: 2EBF 2E9A 2E9F 2EA4 2E55 2F0F 2F0F 2F0F ; $10
C1/2E45: 2F0F 2F0F 2F0F 2F6E 2F0F 2F0F 2F0F 2F0F

; [ small text escape code $14: average experience ]

C1/2E55: 7B           TDC 
C1/2E56: AA           TAX 
C1/2E57: 86 70        STX $70
C1/2E59: 86 72        STX $72
C1/2E5B: A5 70        LDA $70
C1/2E5D: 18           CLC 
C1/2E5E: 7D 03 05     ADC $0503,X
C1/2E61: 85 70        STA $70
C1/2E63: A5 71        LDA $71
C1/2E65: 7D 04 05     ADC $0504,X
C1/2E68: 85 71        STA $71
C1/2E6A: A5 72        LDA $72
C1/2E6C: 7D 05 05     ADC $0505,X
C1/2E6F: 85 72        STA $72
C1/2E71: A5 73        LDA $73
C1/2E73: 69 00        ADC #$00
C1/2E75: 85 73        STA $73
C1/2E77: C2 20        REP #$20
C1/2E79: 8A           TXA 
C1/2E7A: 18           CLC 
C1/2E7B: 69 50 00     ADC #$0050
C1/2E7E: AA           TAX 
C1/2E7F: 7B           TDC 
C1/2E80: E2 20        SEP #$20
C1/2E82: E0 40 01     CPX #$0140
C1/2E85: D0 D4        BNE $2E5B
C1/2E87: 66 73        ROR $73
C1/2E89: 66 72        ROR $72
C1/2E8B: 66 71        ROR $71
C1/2E8D: 66 70        ROR $70
C1/2E8F: 66 73        ROR $73
C1/2E91: 66 72        ROR $72
C1/2E93: 66 71        ROR $71
C1/2E95: 66 70        ROR $70
C1/2E97: 4C AB 2E     JMP $2EAB

; [ small text escape code $11: battle count ]

C1/2E9A: AE C0 09     LDX $09C0       ; battle count
C1/2E9D: 80 08        BRA $2EA7

; [ small text escape code $12: monsters slain ]

C1/2E9F: AE 4E 09     LDX $094E       ; monsters slain
C1/2EA2: 80 03        BRA $2EA7

; [ small text escape code $13: save count ]

C1/2EA4: AE C2 09     LDX $09C2       ; save count
C1/2EA7: 86 70        STX $70
C1/2EA9: 64 72        STZ $72
C1/2EAB: 5A           PHY 
C1/2EAC: 20 88 FF     JSR $FF88       ; convert hex to decimal digits
C1/2EAF: 20 FE FE     JSR $FEFE
C1/2EB2: 7A           PLY 
C1/2EB3: B5 C4        LDA $C4,X
C1/2EB5: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2EB8: E8           INX 
C1/2EB9: E0 08 00     CPX #$0008
C1/2EBC: D0 F5        BNE $2EB3
C1/2EBE: 60           RTS 

; [ small text escape code $10: percentage of treasures ]

C1/2EBF: 7B           TDC 
C1/2EC0: AA           TAX 
C1/2EC1: 64 7E        STZ $7E
C1/2EC3: A9 08        LDA #$08
C1/2EC5: 85 80        STA $80
C1/2EC7: BD D4 09     LDA $09D4,X
C1/2ECA: 0A           ASL 
C1/2ECB: 90 02        BCC $2ECF
C1/2ECD: E6 7E        INC $7E
C1/2ECF: C6 80        DEC $80
C1/2ED1: D0 F7        BNE $2ECA
C1/2ED3: E8           INX 
C1/2ED4: E0 20 00     CPX #$0020
C1/2ED7: D0 EA        BNE $2EC3
C1/2ED9: 64 7F        STZ $7F
C1/2EDB: A5 7E        LDA $7E
C1/2EDD: C9 FC        CMP #$FC
C1/2EDF: D0 0F        BNE $2EF0       ; branch if not 100%
C1/2EE1: A9 54        LDA #$54
C1/2EE3: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2EE6: A9 53        LDA #$53
C1/2EE8: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2EEB: A9 53        LDA #$53
C1/2EED: 4C EA 2D     JMP $2DEA       ; draw small text character
C1/2EF0: A2 80 0F     LDX #$0F80
C1/2EF3: 86 80        STX $80
C1/2EF5: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/2EF8: A6 82        LDX $82
C1/2EFA: 86 70        STX $70
C1/2EFC: A6 84        LDX $84
C1/2EFE: 86 72        STX $72
C1/2F00: 20 88 FF     JSR $FF88       ; convert hex to decimal digits
C1/2F03: AD C6 00     LDA $00C6
C1/2F06: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2F09: AD C7 00     LDA $00C7
C1/2F0C: 4C EA 2D     JMP $2DEA       ; draw small text character

C1/2F0F: 60           RTS 

; [ small text escape code $01:  ]

C1/2F10: AD A4 BC     LDA $BCA4
C1/2F13: C2 20        REP #$20
C1/2F15: 48           PHA 
C1/2F16: 0A           ASL 
C1/2F17: 18           CLC 
C1/2F18: 65 BA        ADC $BA
C1/2F1A: 85 BA        STA $BA
C1/2F1C: 68           PLA 
C1/2F1D: 18           CLC 
C1/2F1E: 65 BA        ADC $BA
C1/2F20: 85 BC        STA $BC
C1/2F22: A9 00 00     LDA #$0000
C1/2F25: A8           TAY 
C1/2F26: E2 20        SEP #$20
C1/2F28: 60           RTS 

; [ small text escape code $0D:  ]

C1/2F29: 20 9A 29     JSR $299A       ; get next byte
C1/2F2C: B2 B8        LDA ($B8)
C1/2F2E: 85 BE        STA $BE
C1/2F30: 60           RTS 

; [ small text escape code $05:  ]

C1/2F31: 20 9A 29     JSR $299A       ; get next byte
C1/2F34: B2 B8        LDA ($B8)
C1/2F36: 85 70        STA $70
C1/2F38: A9 FF        LDA #$FF
C1/2F3A: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2F3D: C6 70        DEC $70
C1/2F3F: D0 F7        BNE $2F38
C1/2F41: 60           RTS 

; [ small text escape code $06:  ]

C1/2F42: 20 9A 29     JSR $299A       ; get next byte
C1/2F45: B2 B8        LDA ($B8)
C1/2F47: 85 70        STA $70
C1/2F49: A9 00        LDA #$00
C1/2F4B: 91 BC        STA ($BC),Y
C1/2F4D: 20 F2 2D     JSR $2DF2
C1/2F50: C6 70        DEC $70
C1/2F52: D0 F5        BNE $2F49
C1/2F54: 60           RTS 

; [ small text escape code $03:  ]

C1/2F55: 20 9A 29     JSR $299A       ; get next byte
C1/2F58: B2 B8        LDA ($B8)
C1/2F5A: 4C EE 2D     JMP $2DEE

; [ decode small text escape code ]

C1/2F5D: 0A           ASL 
C1/2F5E: AA           TAX 
C1/2F5F: BF 15 2E C1  LDA $C12E15,X
C1/2F63: 85 70        STA $70
C1/2F65: BF 16 2E C1  LDA $C12E16,X
C1/2F69: 85 71        STA $71
C1/2F6B: 6C 70 00     JMP ($0070)

; [ small text escape code $1B: variable ]

C1/2F6E: 20 9A 29     JSR $299A       ; get next byte
C1/2F71: 64 70        STZ $70
C1/2F73: B2 B8        LDA ($B8)
C1/2F75: 38           SEC 
C1/2F76: E9 0A        SBC #$0A
C1/2F78: 90 05        BCC $2F7F
C1/2F7A: E6 70        INC $70
C1/2F7C: 4C 75 2F     JMP $2F75
C1/2F7F: 18           CLC 
C1/2F80: 69 0A        ADC #$0A
C1/2F82: 85 71        STA $71
C1/2F84: A5 70        LDA $70
C1/2F86: D0 02        BNE $2F8A       ; branch if two digits
C1/2F88: A9 AC        LDA #$AC        ; this is a hack to draw a space ($AC + $53 = $FF)
C1/2F8A: 18           CLC 
C1/2F8B: 69 53        ADC #$53
C1/2F8D: 20 EE 2D     JSR $2DEE
C1/2F90: A5 71        LDA $71
C1/2F92: 05 70        ORA $70
C1/2F94: D0 05        BNE $2F9B
C1/2F96: A9 FF        LDA #$FF
C1/2F98: 4C EE 2D     JMP $2DEE
C1/2F9B: A5 71        LDA $71
C1/2F9D: 18           CLC 
C1/2F9E: 69 53        ADC #$53
C1/2FA0: 4C EE 2D     JMP $2DEE

; [ small text escape code $0F: attack name ]

C1/2FA3: 20 9A 29     JSR $299A       ; get next byte
C1/2FA6: B2 B8        LDA ($B8)
C1/2FA8: C9 57        CMP #$57
C1/2FAA: 90 1D        BCC $2FC9
C1/2FAC: 38           SEC 
C1/2FAD: E9 57        SBC #$57
C1/2FAF: 85 7E        STA $7E
C1/2FB1: A9 09        LDA #$09
C1/2FB3: 85 70        STA $70
C1/2FB5: 85 80        STA $80
C1/2FB7: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2FBA: A6 82        LDX $82
C1/2FBC: BF 8A 1E D1  LDA $D11E8A,X   ; short attack names
C1/2FC0: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2FC3: E8           INX 
C1/2FC4: C6 70        DEC $70
C1/2FC6: D0 F4        BNE $2FBC
C1/2FC8: 60           RTS 
C1/2FC9: 85 7E        STA $7E
C1/2FCB: A9 06        LDA #$06
C1/2FCD: 85 70        STA $70
C1/2FCF: 85 80        STA $80
C1/2FD1: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2FD4: A6 82        LDX $82
C1/2FD6: BF 80 1C D1  LDA $D11C80,X   ; spell names
C1/2FDA: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2FDD: E8           INX 
C1/2FDE: C6 70        DEC $70
C1/2FE0: D0 F4        BNE $2FD6
C1/2FE2: 60           RTS 

; [ small text escape code $0E: item name ]

C1/2FE3: 20 9A 29     JSR $299A       ; get next byte
C1/2FE6: B2 B8        LDA ($B8)
C1/2FE8: 85 7E        STA $7E
C1/2FEA: A9 09        LDA #$09
C1/2FEC: 85 80        STA $80
C1/2FEE: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/2FF1: A6 82        LDX $82
C1/2FF3: A9 09        LDA #$09
C1/2FF5: 85 76        STA $76
C1/2FF7: BF 80 13 D1  LDA $D11380,X   ; item names
C1/2FFB: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/2FFE: E8           INX 
C1/2FFF: C6 76        DEC $76
C1/3001: D0 F4        BNE $2FF7
C1/3003: 60           RTS 

; [ small text escape code $0B: monster name ]

C1/3004: 20 9A 29     JSR $299A       ; get next byte
C1/3007: B2 B8        LDA ($B8)
C1/3009: 0A           ASL 
C1/300A: 0A           ASL 
C1/300B: AA           TAX 
C1/300C: C2 20        REP #$20
C1/300E: BD 38 40     LDA $4038,X
C1/3011: 0A           ASL 
C1/3012: 0A           ASL 
C1/3013: 0A           ASL 
C1/3014: AA           TAX 
C1/3015: 7B           TDC 
C1/3016: E2 20        SEP #$20
C1/3018: A9 08        LDA #$08
C1/301A: 85 70        STA $70
C1/301C: AF F1 04 00  LDA $0004F1
C1/3020: C9 02        CMP #$02
C1/3022: D0 0D        BNE $3031
C1/3024: BF 00 64 D0  LDA $D06400,X
C1/3028: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/302B: E8           INX 
C1/302C: C6 70        DEC $70
C1/302E: D0 F4        BNE $3024
C1/3030: 60           RTS 
C1/3031: BF 00 5C D0  LDA $D05C00,X
C1/3035: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/3038: E8           INX 
C1/3039: C6 70        DEC $70
C1/303B: D0 F4        BNE $3031
C1/303D: 60           RTS 

; [ small text escape code $0C:  ]

C1/303E: 20 9A 29     JSR $299A       ; get next byte
C1/3041: AE F0 04     LDX $04F0
C1/3044: E0 EF 01     CPX #$01EF
C1/3047: F0 17        BEQ $3060
C1/3049: E0 E6 01     CPX #$01E6
C1/304C: F0 12        BEQ $3060
C1/304E: B2 B8        LDA ($B8)
C1/3050: 0A           ASL 
C1/3051: 0A           ASL 
C1/3052: AA           TAX 
C1/3053: BD 3A 40     LDA $403A,X
C1/3056: C9 02        CMP #$02
C1/3058: 90 06        BCC $3060
C1/305A: 18           CLC 
C1/305B: 69 53        ADC #$53
C1/305D: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/3060: 60           RTS 

; [ small text escape code $07:  ]

C1/3061: A2 00 20     LDX #$2000
C1/3064: 86 70        STX $70
C1/3066: A2 2C 38     LDX #$382C
C1/3069: 86 78        STX $78
C1/306B: 4C 92 30     JMP $3092

; [ small text escape code $08:  ]

C1/306E: A2 80 20     LDX #$2080
C1/3071: 86 70        STX $70
C1/3073: A2 34 38     LDX #$3834
C1/3076: 86 78        STX $78
C1/3078: 4C 92 30     JMP $3092

; [ small text escape code $09:  ]

C1/307B: A2 00 21     LDX #$2100
C1/307E: 86 70        STX $70
C1/3080: A2 3C 38     LDX #$383C
C1/3083: 86 78        STX $78
C1/3085: 4C 92 30     JMP $3092

; [ small text escape code $0A:  ]

C1/3088: A2 80 21     LDX #$2180
C1/308B: 86 70        STX $70
C1/308D: A2 44 38     LDX #$3844
C1/3090: 86 78        STX $78
C1/3092: A9 7E        LDA #$7E
C1/3094: 85 72        STA $72
C1/3096: 20 9A 29     JSR $299A       ; get next byte
C1/3099: B2 B8        LDA ($B8)
C1/309B: 0A           ASL 
C1/309C: AA           TAX 
C1/309D: BF AC 30 C1  LDA $C130AC,X
C1/30A1: 85 7E        STA $7E
C1/30A3: BF AD 30 C1  LDA $C130AD,X
C1/30A7: 85 7F        STA $7F
C1/30A9: 6C 7E 00     JMP ($007E)

C1/30AC: 327B 313F 3144 3149 314E 315D 3177 3182
C1/30BC: 318D 3198 3112 30E5 31A3 31AA 31B1 31B8
C1/30CC: 31BF 31C6 3158 3153 30D6

; [  ]

C1/30D6: AD F4 08     LDA $08F4
C1/30D9: AA           TAX 
C1/30DA: 20 2E FF     JSR $FF2E
C1/30DD: 20 12 FF     JSR $FF12
C1/30E0: 7B           TDC 
C1/30E1: AA           TAX 
C1/30E2: 4C F0 32     JMP $32F0
C1/30E5: 5A           PHY 
C1/30E6: A0 03 00     LDY #$0003
C1/30E9: B7 70        LDA [$70],Y
C1/30EB: 85 74        STA $74
C1/30ED: C8           INY 
C1/30EE: B7 70        LDA [$70],Y
C1/30F0: 85 75        STA $75
C1/30F2: C8           INY 
C1/30F3: B7 70        LDA [$70],Y
C1/30F5: 85 72        STA $72
C1/30F7: A5 74        LDA $74
C1/30F9: 85 70        STA $70
C1/30FB: A5 75        LDA $75
C1/30FD: 85 71        STA $71
C1/30FF: 20 88 FF     JSR $FF88       ; convert hex to decimal digits
C1/3102: 20 FE FE     JSR $FEFE
C1/3105: 7A           PLY 
C1/3106: B5 C4        LDA $C4,X
C1/3108: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/310B: E8           INX 
C1/310C: E0 08 00     CPX #$0008
C1/310F: D0 F5        BNE $3106
C1/3111: 60           RTS 
C1/3112: 5A           PHY 
C1/3113: A0 01 00     LDY #$0001
C1/3116: B7 70        LDA [$70],Y
C1/3118: 7A           PLY 
C1/3119: 85 7E        STA $7E
C1/311B: A9 08        LDA #$08
C1/311D: 85 80        STA $80
C1/311F: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/3122: A6 82        LDX $82
C1/3124: A9 08        LDA #$08
C1/3126: 85 70        STA $70
C1/3128: 9C F5 FE     STZ $FEF5
C1/312B: BF 00 56 D1  LDA $D15600,X
C1/312F: C9 FF        CMP #$FF
C1/3131: F0 0B        BEQ $313E
C1/3133: EE F5 FE     INC $FEF5
C1/3136: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/3139: E8           INX 
C1/313A: C6 70        DEC $70
C1/313C: D0 ED        BNE $312B
C1/313E: 60           RTS 
C1/313F: A9 00        LDA #$00
C1/3141: 4C BC 32     JMP $32BC
C1/3144: A9 02        LDA #$02
C1/3146: 4C BC 32     JMP $32BC
C1/3149: A9 04        LDA #$04
C1/314B: 4C CB 32     JMP $32CB
C1/314E: A9 06        LDA #$06
C1/3150: 4C CB 32     JMP $32CB
C1/3153: A9 06        LDA #$06
C1/3155: 4C ED 32     JMP $32ED
C1/3158: A9 02        LDA #$02
C1/315A: 4C DA 32     JMP $32DA
C1/315D: 5A           PHY 
C1/315E: A0 02 00     LDY #$0002
C1/3161: B7 70        LDA [$70],Y
C1/3163: AA           TAX 
C1/3164: 20 2E FF     JSR $FF2E
C1/3167: 7A           PLY 
C1/3168: A2 00 00     LDX #$0000
C1/316B: B5 C6        LDA $C6,X
C1/316D: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/3170: E8           INX 
C1/3171: E0 02 00     CPX #$0002
C1/3174: D0 F5        BNE $316B
C1/3176: 60           RTS 
C1/3177: A9 16        LDA #$16
C1/3179: 20 31 32     JSR $3231
C1/317C: A5 72        LDA $72
C1/317E: 8D F0 FE     STA $FEF0
C1/3181: 60           RTS 
C1/3182: A9 17        LDA #$17
C1/3184: 20 31 32     JSR $3231
C1/3187: A5 72        LDA $72
C1/3189: 8D F1 FE     STA $FEF1
C1/318C: 60           RTS 
C1/318D: A9 18        LDA #$18
C1/318F: 20 31 32     JSR $3231
C1/3192: A5 72        LDA $72
C1/3194: 8D F2 FE     STA $FEF2
C1/3197: 60           RTS 
C1/3198: A9 19        LDA #$19
C1/319A: 20 31 32     JSR $3231
C1/319D: A5 72        LDA $72
C1/319F: 8D F3 FE     STA $FEF3
C1/31A2: 60           RTS 

C1/31A3: 20 CD 31     JSR $31CD
C1/31A6: 8D F0 FE     STA $FEF0
C1/31A9: 60           RTS 
C1/31AA: 20 CD 31     JSR $31CD
C1/31AD: 8D F1 FE     STA $FEF1
C1/31B0: 60           RTS 
C1/31B1: 20 CD 31     JSR $31CD
C1/31B4: 8D F2 FE     STA $FEF2
C1/31B7: 60           RTS 
C1/31B8: 20 CD 31     JSR $31CD
C1/31BB: 8D F3 FE     STA $FEF3
C1/31BE: 60           RTS 
C1/31BF: 20 CD 31     JSR $31CD
C1/31C2: 8D F4 FE     STA $FEF4
C1/31C5: 60           RTS 
C1/31C6: 20 CD 31     JSR $31CD
C1/31C9: 8D F5 FE     STA $FEF5
C1/31CC: 60           RTS 

; [  ]

C1/31CD: 20 9A 29     JSR $299A       ; get next byte
C1/31D0: B2 B8        LDA ($B8)
C1/31D2: AA           TAX 
C1/31D3: BD 35 B5     LDA $B535,X
C1/31D6: 48           PHA 
C1/31D7: 20 36 32     JSR $3236
C1/31DA: 68           PLA 
C1/31DB: C9 2C        CMP #$2C
C1/31DD: 90 1C        BCC $31FB
C1/31DF: C9 4C        CMP #$4C
C1/31E1: 90 02        BCC $31E5
C1/31E3: 80 16        BRA $31FB
C1/31E5: 48           PHA 
C1/31E6: A9 2B        LDA #$2B
C1/31E8: 20 EE 2D     JSR $2DEE
C1/31EB: 68           PLA 
C1/31EC: 38           SEC 
C1/31ED: E9 2C        SBC #$2C
C1/31EF: AA           TAX 
C1/31F0: BF 11 32 C1  LDA $C13211,X
C1/31F4: 20 EE 2D     JSR $2DEE
C1/31F7: E6 72        INC $72
C1/31F9: E6 72        INC $72
C1/31FB: A5 72        LDA $72
C1/31FD: C9 08        CMP #$08
C1/31FF: F0 0D        BEQ $320E
C1/3201: 85 73        STA $73
C1/3203: A9 00        LDA #$00
C1/3205: 20 EE 2D     JSR $2DEE
C1/3208: E6 73        INC $73
C1/320A: A5 73        LDA $73
C1/320C: 80 EF        BRA $31FD
C1/320E: A5 72        LDA $72
C1/3210: 60           RTS 

C1/3211: 54 55 56     MVN $55,$56
C1/3214: 57 58        EOR [$58],Y
C1/3216: 59 54 55     EOR $5554,Y
C1/3219: 56 57        LSR $57,X
C1/321B: 58           CLI 
C1/321C: 59 54 55     EOR $5554,Y
C1/321F: 56 57        LSR $57,X
C1/3221: 58           CLI 
C1/3222: 59 54 55     EOR $5554,Y
C1/3225: 56 57        LSR $57,X
C1/3227: 58           CLI 
C1/3228: 59 54 55     EOR $5554,Y
C1/322B: 56 57        LSR $57,X
C1/322D: 58           CLI 
C1/322E: 54 55 56     MVN $55,$56

; [  ]

C1/3231: 5A           PHY 
C1/3232: A8           TAY 
C1/3233: B7 70        LDA [$70],Y
C1/3235: 7A           PLY 
C1/3236: C9 80        CMP #$80
C1/3238: 90 25        BCC $325F
C1/323A: 38           SEC 
C1/323B: E9 80        SBC #$80
C1/323D: 85 7E        STA $7E
C1/323F: A9 08        LDA #$08
C1/3241: 85 70        STA $70
C1/3243: 85 80        STA $80
C1/3245: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/3248: A6 82        LDX $82
C1/324A: 64 72        STZ $72
C1/324C: BF 00 62 D1  LDA $D16200,X
C1/3250: C9 FF        CMP #$FF
C1/3252: F0 0A        BEQ $325E
C1/3254: E6 72        INC $72
C1/3256: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/3259: E8           INX 
C1/325A: C6 70        DEC $70
C1/325C: D0 EE        BNE $324C
C1/325E: 60           RTS 
C1/325F: 20 CF 2B     JSR $2BCF
C1/3262: A9 05        LDA #$05
C1/3264: 85 70        STA $70
C1/3266: 64 72        STZ $72
C1/3268: BF 00 58 D1  LDA $D15800,X
C1/326C: C9 FF        CMP #$FF
C1/326E: F0 0A        BEQ $327A
C1/3270: E6 72        INC $72
C1/3272: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/3275: E8           INX 
C1/3276: C6 70        DEC $70
C1/3278: D0 EE        BNE $3268
C1/327A: 60           RTS 

C1/327B: A7 70        LDA [$70]
C1/327D: 29 07        AND #$07
C1/327F: 85 7E        STA $7E
C1/3281: A9 06        LDA #$06
C1/3283: 85 80        STA $80
C1/3285: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/3288: A6 82        LDX $82
C1/328A: A9 06        LDA #$06
C1/328C: 85 76        STA $76
C1/328E: 9C F4 FE     STZ $FEF4
C1/3291: BF 90 09 00  LDA $000990,X   ; character names
C1/3295: C9 FF        CMP #$FF
C1/3297: F0 03        BEQ $329C
C1/3299: EE F4 FE     INC $FEF4
C1/329C: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/329F: E8           INX 
C1/32A0: C6 76        DEC $76
C1/32A2: D0 ED        BNE $3291
C1/32A4: 60           RTS 

C1/32A5: 5A           PHY 
C1/32A6: A8           TAY 
C1/32A7: B1 78        LDA ($78),Y
C1/32A9: 85 74        STA $74
C1/32AB: C8           INY 
C1/32AC: B1 78        LDA ($78),Y
C1/32AE: 85 75        STA $75
C1/32B0: 7A           PLY 
C1/32B1: A6 74        LDX $74
C1/32B3: 20 2E FF     JSR $FF2E
C1/32B6: 20 12 FF     JSR $FF12
C1/32B9: 7B           TDC 
C1/32BA: AA           TAX 
C1/32BB: 60           RTS 

C1/32BC: 20 A5 32     JSR $32A5
C1/32BF: B5 C4        LDA $C4,X
C1/32C1: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/32C4: E8           INX 
C1/32C5: E0 04 00     CPX #$0004
C1/32C8: D0 F5        BNE $32BF
C1/32CA: 60           RTS 
C1/32CB: 20 A5 32     JSR $32A5
C1/32CE: B5 C5        LDA $C5,X
C1/32D0: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/32D3: E8           INX 
C1/32D4: E0 03 00     CPX #$0003
C1/32D7: D0 F5        BNE $32CE
C1/32D9: 60           RTS 
C1/32DA: 20 A5 32     JSR $32A5
C1/32DD: B5 C4        LDA $C4,X
C1/32DF: C9 FF        CMP #$FF
C1/32E1: F0 03        BEQ $32E6
C1/32E3: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/32E6: E8           INX 
C1/32E7: E0 04 00     CPX #$0004
C1/32EA: D0 F1        BNE $32DD
C1/32EC: 60           RTS 
C1/32ED: 20 A5 32     JSR $32A5
C1/32F0: B5 C5        LDA $C5,X
C1/32F2: C9 FF        CMP #$FF
C1/32F4: F0 03        BEQ $32F9
C1/32F6: 20 EA 2D     JSR $2DEA       ; draw small text character
C1/32F9: E8           INX 
C1/32FA: E0 03 00     CPX #$0003
C1/32FD: D0 F1        BNE $32F0
C1/32FF: 60           RTS 
C1/3300: A9 FF        LDA #$FF
C1/3302: 20 EE 2D     JSR $2DEE
C1/3305: CA           DEX 
C1/3306: D0 F8        BNE $3300
C1/3308: 60           RTS 
C1/3309: AD BD F8     LDA $F8BD
C1/330C: C9 FF        CMP #$FF
C1/330E: F0 49        BEQ $3359
C1/3310: EE C2 F8     INC $F8C2
C1/3313: AE BE F8     LDX $F8BE
C1/3316: 86 88        STX $88
C1/3318: A9 D4        LDA #$D4
C1/331A: 85 8A        STA $8A
C1/331C: AC C0 F8     LDY $F8C0
C1/331F: B7 88        LDA [$88],Y
C1/3321: C9 FF        CMP #$FF
C1/3323: D0 02        BNE $3327
C1/3325: 7B           TDC 
C1/3326: A8           TAY 
C1/3327: B7 88        LDA [$88],Y
C1/3329: 30 05        BMI $3330
C1/332B: A2 00 00     LDX #$0000
C1/332E: 80 03        BRA $3333
C1/3330: A2 20 00     LDX #$0020
C1/3333: C8           INY 
C1/3334: 8C C0 F8     STY $F8C0
C1/3337: 29 7F        AND #$7F
C1/3339: C2 20        REP #$20
C1/333B: 0A           ASL 
C1/333C: 0A           ASL 
C1/333D: 0A           ASL 
C1/333E: 0A           ASL 
C1/333F: 0A           ASL 
C1/3340: 9B           TXY 
C1/3341: AA           TAX 
C1/3342: A9 10 00     LDA #$0010
C1/3345: 85 88        STA $88
C1/3347: BF 31 BB D4  LDA $D4BB31,X
C1/334B: 99 29 7E     STA $7E29,Y
C1/334E: E8           INX 
C1/334F: E8           INX 
C1/3350: C8           INY 
C1/3351: C8           INY 
C1/3352: C6 88        DEC $88
C1/3354: D0 F1        BNE $3347
C1/3356: 7B           TDC 
C1/3357: E2 20        SEP #$20
C1/3359: 60           RTS 

; ============================[ battle background ]=============================

; [ load battle bg ]

C1/335A: AD F2 04     LDA $04F2       ; battle bg
C1/335D: C2 20        REP #$20
C1/335F: 0A           ASL 
C1/3360: 0A           ASL 
C1/3361: 0A           ASL 
C1/3362: AA           TAX 
C1/3363: 8E A6 BC     STX $BCA6       ; pointer to battle bg properties (+$D4BA21)
C1/3366: 7B           TDC 
C1/3367: E2 20        SEP #$20
C1/3369: 20 CC 33     JSR $33CC       ; load battle bg tile layout
C1/336C: 20 25 37     JSR $3725       ; load battle bg graphics
C1/336F: 20 A5 36     JSR $36A5       ; load battle bg palette
C1/3372: AE A6 BC     LDX $BCA6
C1/3375: BF 28 BA D4  LDA $D4BA28,X   ; palette animation
C1/3379: 8D BD F8     STA $F8BD
C1/337C: 0A           ASL 
C1/337D: AA           TAX 
C1/337E: BF CD C6 D4  LDA $D4C6CD,X
C1/3382: 8D BE F8     STA $F8BE
C1/3385: BF CE C6 D4  LDA $D4C6CE,X
C1/3389: 8D BF F8     STA $F8BF
C1/338C: 7B           TDC 
C1/338D: AA           TAX 
C1/338E: 8E C0 F8     STX $F8C0
C1/3391: 9C C2 F8     STZ $F8C2
C1/3394: AE A6 BC     LDX $BCA6
C1/3397: BF 27 BA D4  LDA $D4BA27,X   ; bg animation
C1/339B: 0A           ASL 
C1/339C: AA           TAX 
C1/339D: BF B1 C5 D4  LDA $D4C5B1,X   ; pointer to bg animation
C1/33A1: 85 70        STA $70
C1/33A3: BF B2 C5 D4  LDA $D4C5B2,X
C1/33A7: 85 71        STA $71
C1/33A9: A9 D4        LDA #$D4
C1/33AB: 85 72        STA $72
C1/33AD: 7B           TDC 
C1/33AE: A8           TAY 
C1/33AF: A9 FF        LDA #$FF
C1/33B1: 99 09 A8     STA $A809,Y
C1/33B4: C8           INY 
C1/33B5: C0 8C 00     CPY #$008C
C1/33B8: D0 F7        BNE $33B1
C1/33BA: 7B           TDC 
C1/33BB: A8           TAY 
C1/33BC: B7 70        LDA [$70],Y
C1/33BE: 99 09 A8     STA $A809,Y
C1/33C1: C9 FF        CMP #$FF
C1/33C3: F0 06        BEQ $33CB
C1/33C5: C8           INY 
C1/33C6: C0 80 00     CPY #$0080
C1/33C9: D0 F1        BNE $33BC
C1/33CB: 60           RTS 

; [ load battle bg tile layout ]

C1/33CC: 7B           TDC 
C1/33CD: AA           TAX 
C1/33CE: 9F 00 70 7F  STA $7F7000,X   ; clear buffer
C1/33D2: E8           INX 
C1/33D3: E0 00 05     CPX #$0500
C1/33D6: D0 F6        BNE $33CE
C1/33D8: AE A6 BC     LDX $BCA6
C1/33DB: BF 24 BA D4  LDA $D4BA24,X   ; tile layout
C1/33DF: 0A           ASL 
C1/33E0: AA           TAX 
C1/33E1: BF 6D C8 D4  LDA $D4C86D,X   ; pointer to tile layout
C1/33E5: 85 70        STA $70
C1/33E7: BF 6E C8 D4  LDA $D4C86E,X
C1/33EB: 85 71        STA $71
C1/33ED: A9 D4        LDA #$D4
C1/33EF: 85 72        STA $72
C1/33F1: 7B           TDC 
C1/33F2: A8           TAY 
C1/33F3: AA           TAX 
C1/33F4: B7 70        LDA [$70],Y
C1/33F6: C9 FF        CMP #$FF
C1/33F8: D0 5F        BNE $3459
C1/33FA: C8           INY 
C1/33FB: B7 70        LDA [$70],Y
C1/33FD: 30 36        BMI $3435
C1/33FF: 48           PHA 
C1/3400: 29 3F        AND #$3F
C1/3402: 85 76        STA $76
C1/3404: C8           INY 
C1/3405: B7 70        LDA [$70],Y
C1/3407: 85 78        STA $78
C1/3409: C8           INY 
C1/340A: B7 70        LDA [$70],Y
C1/340C: 85 7A        STA $7A
C1/340E: 68           PLA 
C1/340F: 29 40        AND #$40
C1/3411: F0 11        BEQ $3424
C1/3413: A5 78        LDA $78         ; repeat tile with auto-decrement
C1/3415: 9F 00 70 7F  STA $7F7000,X
C1/3419: 38           SEC 
C1/341A: E5 7A        SBC $7A
C1/341C: E8           INX 
C1/341D: E8           INX 
C1/341E: C6 76        DEC $76
C1/3420: D0 F3        BNE $3415
C1/3422: 80 3B        BRA $345F
C1/3424: A5 78        LDA $78         ; repeat tile with auto-increment
C1/3426: 9F 00 70 7F  STA $7F7000,X
C1/342A: 18           CLC 
C1/342B: 65 7A        ADC $7A
C1/342D: E8           INX 
C1/342E: E8           INX 
C1/342F: C6 76        DEC $76
C1/3431: D0 F3        BNE $3426
C1/3433: 80 2A        BRA $345F
C1/3435: 29 3F        AND #$3F
C1/3437: 85 76        STA $76         ; repeat two tiles
C1/3439: C8           INY 
C1/343A: B7 70        LDA [$70],Y
C1/343C: 85 78        STA $78
C1/343E: C8           INY 
C1/343F: B7 70        LDA [$70],Y
C1/3441: 85 7A        STA $7A
C1/3443: A5 78        LDA $78
C1/3445: 9F 00 70 7F  STA $7F7000,X
C1/3449: E8           INX 
C1/344A: E8           INX 
C1/344B: A5 7A        LDA $7A
C1/344D: 9F 00 70 7F  STA $7F7000,X
C1/3451: E8           INX 
C1/3452: E8           INX 
C1/3453: C6 76        DEC $76
C1/3455: D0 EC        BNE $3443
C1/3457: 80 06        BRA $345F
C1/3459: 9F 00 70 7F  STA $7F7000,X   ; single tile
C1/345D: E8           INX 
C1/345E: E8           INX 
C1/345F: C8           INY 
C1/3460: E0 00 05     CPX #$0500
C1/3463: D0 8F        BNE $33F4
C1/3465: 7B           TDC 
C1/3466: AA           TAX 
C1/3467: BF 01 70 7F  LDA $7F7001,X   ; i don't think this has any effect
C1/346B: 29 DF        AND #$DF
C1/346D: 9F 01 70 7F  STA $7F7001,X
C1/3471: E8           INX 
C1/3472: E8           INX 
C1/3473: E0 00 05     CPX #$0500
C1/3476: D0 EF        BNE $3467
C1/3478: 7B           TDC 
C1/3479: AA           TAX 
C1/347A: 8E A8 BC     STX $BCA8
C1/347D: 8E AA BC     STX $BCAA
C1/3480: AE A6 BC     LDX $BCA6
C1/3483: BF 25 BA D4  LDA $D4BA25,X   ; h-flip
C1/3487: C9 FF        CMP #$FF
C1/3489: D0 05        BNE $3490
C1/348B: EE A8 BC     INC $BCA8
C1/348E: 80 0E        BRA $349E
C1/3490: 0A           ASL 
C1/3491: AA           TAX 
C1/3492: BF 36 C7 D4  LDA $D4C736,X   ; ++$7E = pointer to h-flip data
C1/3496: 85 7E        STA $7E
C1/3498: BF 37 C7 D4  LDA $D4C737,X
C1/349C: 85 7F        STA $7F
C1/349E: AE A6 BC     LDX $BCA6
C1/34A1: BF 26 BA D4  LDA $D4BA26,X   ; v-flip
C1/34A5: C9 FF        CMP #$FF
C1/34A7: D0 05        BNE $34AE
C1/34A9: EE A9 BC     INC $BCA9
C1/34AC: 80 0E        BRA $34BC
C1/34AE: 0A           ASL 
C1/34AF: AA           TAX 
C1/34B0: BF 36 C7 D4  LDA $D4C736,X   ; ++$82 = pointer to v-flip data
C1/34B4: 85 82        STA $82
C1/34B6: BF 37 C7 D4  LDA $D4C737,X
C1/34BA: 85 83        STA $83
C1/34BC: A9 D4        LDA #$D4
C1/34BE: 85 80        STA $80
C1/34C0: 85 84        STA $84
C1/34C2: 9C AD BC     STZ $BCAD
C1/34C5: 9C AE BC     STZ $BCAE
C1/34C8: 7B           TDC 
C1/34C9: AA           TAX 
C1/34CA: BF 00 70 7F  LDA $7F7000,X   ; tile index
C1/34CE: 30 0A        BMI $34DA
C1/34D0: 09 80        ORA #$80
C1/34D2: 9F 00 70 7F  STA $7F7000,X
C1/34D6: A9 04        LDA #$04        ; use palette 1
C1/34D8: 80 08        BRA $34E2
C1/34DA: 09 80        ORA #$80
C1/34DC: 9F 00 70 7F  STA $7F7000,X
C1/34E0: A9 08        LDA #$08        ; use palette 2
C1/34E2: 85 70        STA $70
C1/34E4: BF 01 70 7F  LDA $7F7001,X
C1/34E8: 05 70        ORA $70
C1/34EA: 85 70        STA $70
C1/34EC: 20 70 36     JSR $3670       ; get battle bg tile flip
C1/34EF: 05 70        ORA $70
C1/34F1: 29 DF        AND #$DF        ; clear priority bit
C1/34F3: 9F 01 70 7F  STA $7F7001,X
C1/34F7: E8           INX 
C1/34F8: E8           INX 
C1/34F9: E0 00 05     CPX #$0500
C1/34FC: D0 CC        BNE $34CA
C1/34FE: 20 99 35     JSR $3599       ; flip battle bg horizontally
C1/3501: AD E4 DB     LDA $DBE4
C1/3504: F0 1C        BEQ $3522
C1/3506: A9 D8        LDA #$D8        ; D8/35B2 (tile layout for ???)
C1/3508: 85 74        STA $74
C1/350A: A2 B2 35     LDX #$35B2
C1/350D: 86 72        STX $72
C1/350F: 20 77 FB     JSR $FB77       ; decompress
C1/3512: A2 00 10     LDX #$1000
C1/3515: 86 70        STX $70
C1/3517: A2 00 C0     LDX #$C000
C1/351A: A0 00 10     LDY #$1000
C1/351D: A9 7F        LDA #$7F
C1/351F: 4C 27 FD     JMP $FD27
C1/3522: AD D3 DB     LDA $DBD3
C1/3525: F0 10        BEQ $3537
C1/3527: A0 80 10     LDY #$1080
C1/352A: A2 00 05     LDX #$0500
C1/352D: 86 70        STX $70
C1/352F: A2 00 70     LDX #$7000
C1/3532: A9 7F        LDA #$7F
C1/3534: 4C CA FD     JMP $FDCA       ; copy data to vram
C1/3537: A2 00 05     LDX #$0500
C1/353A: 86 70        STX $70
C1/353C: A2 00 70     LDX #$7000
C1/353F: A9 7F        LDA #$7F
C1/3541: A0 00 10     LDY #$1000
C1/3544: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/3547: A2 00 05     LDX #$0500
C1/354A: 86 70        STX $70
C1/354C: A2 00 70     LDX #$7000
C1/354F: A9 7F        LDA #$7F
C1/3551: A0 00 14     LDY #$1400
C1/3554: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/3557: A2 40 00     LDX #$0040
C1/355A: 86 70        STX $70
C1/355C: A2 C0 74     LDX #$74C0
C1/355F: A9 7F        LDA #$7F
C1/3561: A0 80 12     LDY #$1280
C1/3564: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/3567: A2 40 00     LDX #$0040
C1/356A: 86 70        STX $70
C1/356C: A2 C0 74     LDX #$74C0
C1/356F: A9 7F        LDA #$7F
C1/3571: A0 80 16     LDY #$1680
C1/3574: 4C CA FD     JMP $FDCA       ; copy data to vram

; [  ]

C1/3577: AD F2 04     LDA $04F2
C1/357A: C9 1F        CMP #$1F
C1/357C: F0 1A        BEQ $3598       ; return if neo exdeath
C1/357E: AD D3 DB     LDA $DBD3
C1/3581: F0 05        BEQ $3588
C1/3583: A0 80 10     LDY #$1080
C1/3586: 80 03        BRA $358B
C1/3588: A0 00 10     LDY #$1000
C1/358B: A2 00 05     LDX #$0500
C1/358E: 86 70        STX $70
C1/3590: A2 00 70     LDX #$7000
C1/3593: A9 7F        LDA #$7F
C1/3595: 20 27 FD     JSR $FD27
C1/3598: 60           RTS 

; [ flip battle bg horizontally ]

C1/3599: A5 F6        LDA $F6
C1/359B: F0 43        BEQ $35E0
C1/359D: 8B           PHB 
C1/359E: A9 7F        LDA #$7F
C1/35A0: 48           PHA 
C1/35A1: AB           PLB 
C1/35A2: 7B           TDC 
C1/35A3: AA           TAX 
C1/35A4: C2 20        REP #$20
C1/35A6: DA           PHX 
C1/35A7: A0 00 00     LDY #$0000
C1/35AA: BD 00 70     LDA $7000,X
C1/35AD: 99 00 7F     STA $7F00,Y
C1/35B0: C8           INY 
C1/35B1: C8           INY 
C1/35B2: E8           INX 
C1/35B3: E8           INX 
C1/35B4: C0 40 00     CPY #$0040
C1/35B7: D0 F1        BNE $35AA
C1/35B9: CA           DEX 
C1/35BA: CA           DEX 
C1/35BB: A0 00 00     LDY #$0000
C1/35BE: B9 00 7F     LDA $7F00,Y
C1/35C1: 49 00 40     EOR #$4000
C1/35C4: 9D 00 70     STA $7000,X
C1/35C7: C8           INY 
C1/35C8: C8           INY 
C1/35C9: CA           DEX 
C1/35CA: CA           DEX 
C1/35CB: C0 40 00     CPY #$0040
C1/35CE: D0 EE        BNE $35BE
C1/35D0: FA           PLX 
C1/35D1: 8A           TXA 
C1/35D2: 18           CLC 
C1/35D3: 69 40 00     ADC #$0040
C1/35D6: AA           TAX 
C1/35D7: C9 00 05     CMP #$0500
C1/35DA: D0 CA        BNE $35A6
C1/35DC: 7B           TDC 
C1/35DD: E2 20        SEP #$20
C1/35DF: AB           PLB 
C1/35E0: 60           RTS 

; [ set priority bit for battle bg tiles ]

C1/35E1: A5 70        LDA $70
C1/35E3: 48           PHA 
C1/35E4: 7B           TDC 
C1/35E5: AA           TAX 
C1/35E6: BF 01 70 7F  LDA $7F7001,X
C1/35EA: 09 20        ORA #$20
C1/35EC: 9F 01 70 7F  STA $7F7001,X
C1/35F0: E8           INX 
C1/35F1: E8           INX 
C1/35F2: E0 00 05     CPX #$0500
C1/35F5: D0 EF        BNE $35E6
C1/35F7: 20 77 35     JSR $3577
C1/35FA: 68           PLA 
C1/35FB: 85 70        STA $70
C1/35FD: 60           RTS 

; [ clear priority bit for battle bg tiles ]

C1/35FE: A5 70        LDA $70
C1/3600: 48           PHA 
C1/3601: 7B           TDC 
C1/3602: AA           TAX 
C1/3603: BF 01 70 7F  LDA $7F7001,X
C1/3607: 29 DF        AND #$DF
C1/3609: 9F 01 70 7F  STA $7F7001,X
C1/360D: E8           INX 
C1/360E: E8           INX 
C1/360F: E0 00 05     CPX #$0500
C1/3612: D0 EF        BNE $3603
C1/3614: 20 77 35     JSR $3577
C1/3617: 68           PLA 
C1/3618: 85 70        STA $70
C1/361A: 60           RTS 

; [ get next byte of battle bg tile flip data ]

C1/361B: AD AD BC     LDA $BCAD       ; h-flip repeat count
C1/361E: F0 05        BEQ $3625
C1/3620: CE AD BC     DEC $BCAD
C1/3623: 80 1A        BRA $363F
C1/3625: A7 7E        LDA [$7E]       ; h-flip data
C1/3627: 8D AF BC     STA $BCAF
C1/362A: D0 0E        BNE $363A
C1/362C: A0 01 00     LDY #$0001
C1/362F: B7 7E        LDA [$7E],Y     ; if the first byte is zero, the next byte is the
C1/3631: 3A           DEC             ; new repeat count
C1/3632: 8D AD BC     STA $BCAD
C1/3635: A4 7E        LDY $7E
C1/3637: C8           INY 
C1/3638: 84 7E        STY $7E
C1/363A: A4 7E        LDY $7E
C1/363C: C8           INY 
C1/363D: 84 7E        STY $7E
C1/363F: AD AF BC     LDA $BCAF
C1/3642: 8D AB BC     STA $BCAB       ; h-flip bits
C1/3645: AD AE BC     LDA $BCAE
C1/3648: F0 05        BEQ $364F
C1/364A: CE AE BC     DEC $BCAE
C1/364D: 80 1A        BRA $3669
C1/364F: A7 82        LDA [$82]
C1/3651: 8D B0 BC     STA $BCB0
C1/3654: D0 0E        BNE $3664
C1/3656: A0 01 00     LDY #$0001
C1/3659: B7 82        LDA [$82],Y
C1/365B: 3A           DEC 
C1/365C: 8D AE BC     STA $BCAE
C1/365F: A4 82        LDY $82
C1/3661: C8           INY 
C1/3662: 84 82        STY $82
C1/3664: A4 82        LDY $82
C1/3666: C8           INY 
C1/3667: 84 82        STY $82
C1/3669: AD B0 BC     LDA $BCB0
C1/366C: 8D AC BC     STA $BCAC       ; v-flip bits
C1/366F: 60           RTS 

; [ get battle bg tile flip ]

C1/3670: 64 72        STZ $72
C1/3672: AD AA BC     LDA $BCAA       ; bit index
C1/3675: 29 07        AND #$07
C1/3677: D0 03        BNE $367C
C1/3679: 20 1B 36     JSR $361B       ; get next byte of battle bg tile flip data
C1/367C: AD A8 BC     LDA $BCA8
C1/367F: F0 03        BEQ $3684       ; branch if there is no h-flip data
C1/3681: 9C AB BC     STZ $BCAB
C1/3684: AD A9 BC     LDA $BCA9
C1/3687: F0 03        BEQ $368C       ; branch if there is no v-flip data
C1/3689: 9C AC BC     STZ $BCAC
C1/368C: 0E AB BC     ASL $BCAB       ; h-flip bits
C1/368F: 6A           ROR 
C1/3690: 6A           ROR 
C1/3691: 29 40        AND #$40
C1/3693: 05 72        ORA $72
C1/3695: 85 72        STA $72
C1/3697: 0E AC BC     ASL $BCAC       ; v-flip bits
C1/369A: 6A           ROR 
C1/369B: 29 80        AND #$80
C1/369D: 05 72        ORA $72
C1/369F: 85 72        STA $72
C1/36A1: EE AA BC     INC $BCAA
C1/36A4: 60           RTS 

; [ load battle bg palette ]

C1/36A5: AE A6 BC     LDX $BCA6
C1/36A8: BF 22 BA D4  LDA $D4BA22,X   ; palette 1
C1/36AC: 20 DC 36     JSR $36DC
C1/36AF: BF 31 BB D4  LDA $D4BB31,X
C1/36B3: 99 29 7E     STA $7E29,Y
C1/36B6: 99 40 F5     STA $F540,Y
C1/36B9: E8           INX 
C1/36BA: C8           INY 
C1/36BB: C0 20 00     CPY #$0020
C1/36BE: D0 EF        BNE $36AF
C1/36C0: AE A6 BC     LDX $BCA6
C1/36C3: BF 23 BA D4  LDA $D4BA23,X   ; palette 2
C1/36C7: 20 DC 36     JSR $36DC
C1/36CA: BF 31 BB D4  LDA $D4BB31,X
C1/36CE: 99 49 7E     STA $7E49,Y
C1/36D1: 99 60 F5     STA $F560,Y
C1/36D4: E8           INX 
C1/36D5: C8           INY 
C1/36D6: C0 20 00     CPY #$0020
C1/36D9: D0 EF        BNE $36CA
C1/36DB: 60           RTS 

; [ get pointer to battle bg palette ]

C1/36DC: 85 7E        STA $7E
C1/36DE: A9 20        LDA #$20
C1/36E0: 85 80        STA $80
C1/36E2: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/36E5: A6 82        LDX $82
C1/36E7: A0 00 00     LDY #$0000
C1/36EA: 60           RTS 

; [ decompress battle bg graphics ]

C1/36EB: AE A6 BC     LDX $BCA6
C1/36EE: BF 21 BA D4  LDA $D4BA21,X   ; graphics
C1/36F2: 85 7E        STA $7E
C1/36F4: A9 03        LDA #$03
C1/36F6: 85 80        STA $80
C1/36F8: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/36FB: A6 82        LDX $82
C1/36FD: BF 96 41 D8  LDA $D84196,X   ; pointer to battle bg graphics
C1/3701: 85 72        STA $72
C1/3703: BF 97 41 D8  LDA $D84197,X
C1/3707: 85 73        STA $73
C1/3709: BF 98 41 D8  LDA $D84198,X
C1/370D: 85 74        STA $74
C1/370F: 20 77 FB     JSR $FB77       ; decompress
C1/3712: BF 57 41 D8  LDA $D84157,X   ; destination address for battle bg graphics
C1/3716: 85 72        STA $72
C1/3718: BF 58 41 D8  LDA $D84158,X
C1/371C: 85 73        STA $73
C1/371E: BF 59 41 D8  LDA $D84159,X
C1/3722: 85 74        STA $74
C1/3724: 60           RTS 

; [ load battle bg graphics ]

C1/3725: 20 EB 36     JSR $36EB       ; decompress battle bg graphics
C1/3728: 7B           TDC 
C1/3729: A8           TAY 
C1/372A: B7 72        LDA [$72],Y
C1/372C: 99 09 90     STA $9009,Y
C1/372F: 99 09 88     STA $8809,Y
C1/3732: C8           INY 
C1/3733: C0 00 08     CPY #$0800
C1/3736: D0 F2        BNE $372A
C1/3738: A2 00 10     LDX #$1000
C1/373B: 86 70        STX $70
C1/373D: A6 72        LDX $72
C1/373F: A0 00 08     LDY #$0800
C1/3742: AD FA FE     LDA $FEFA       ; 
C1/3745: D0 05        BNE $374C
C1/3747: AD E4 DB     LDA $DBE4
C1/374A: F0 07        BEQ $3753
C1/374C: A5 74        LDA $74
C1/374E: 20 27 FD     JSR $FD27
C1/3751: 80 05        BRA $3758
C1/3753: A5 74        LDA $74
C1/3755: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/3758: 7B           TDC 
C1/3759: A8           TAY 
C1/375A: B9 09 90     LDA $9009,Y     ; flip tiles vertically
C1/375D: 99 10 A0     STA $A010,Y
C1/3760: B9 0A 90     LDA $900A,Y
C1/3763: 99 0F A0     STA $A00F,Y
C1/3766: B9 0B 90     LDA $900B,Y
C1/3769: 99 0E A0     STA $A00E,Y
C1/376C: B9 0C 90     LDA $900C,Y
C1/376F: 99 0D A0     STA $A00D,Y
C1/3772: B9 0D 90     LDA $900D,Y
C1/3775: 99 0C A0     STA $A00C,Y
C1/3778: B9 0E 90     LDA $900E,Y
C1/377B: 99 0B A0     STA $A00B,Y
C1/377E: B9 0F 90     LDA $900F,Y
C1/3781: 99 0A A0     STA $A00A,Y
C1/3784: B9 10 90     LDA $9010,Y
C1/3787: 99 09 A0     STA $A009,Y
C1/378A: C8           INY 
C1/378B: C8           INY 
C1/378C: C8           INY 
C1/378D: C8           INY 
C1/378E: C8           INY 
C1/378F: C8           INY 
C1/3790: C8           INY 
C1/3791: C8           INY 
C1/3792: C0 00 08     CPY #$0800
C1/3795: D0 C3        BNE $375A
C1/3797: 7B           TDC 
C1/3798: A8           TAY 
C1/3799: B9 09 90     LDA $9009,Y
C1/379C: 20 AC 37     JSR $37AC       ; reverse bit order
C1/379F: 99 09 98     STA $9809,Y
C1/37A2: B9 09 A0     LDA $A009,Y     ; i don't think this does anything
C1/37A5: C8           INY 
C1/37A6: C0 00 08     CPY #$0800
C1/37A9: D0 EE        BNE $3799
C1/37AB: 60           RTS 

; [ reverse bit order ]

C1/37AC: A2 08 00     LDX #$0008
C1/37AF: 0A           ASL 
C1/37B0: 66 70        ROR $70
C1/37B2: CA           DEX 
C1/37B3: D0 FA        BNE $37AF
C1/37B5: 60           RTS 

; ===============================[ battle menu ]================================

; [  ]

; 0: spellblade
; 1: white
; 2: black
; 3: time
; 4: summon
; 5: blue
; 6: song
; 7: red
; 8: x-magic

C1/37B6: 0A           ASL 
C1/37B7: 0A           ASL 
C1/37B8: 0A           ASL 
C1/37B9: AA           TAX 
C1/37BA: BF 16 33 D8  LDA $D83316,X   ; first spell
C1/37BE: 85 DB        STA $DB
C1/37C0: BF 17 33 D8  LDA $D83317,X   ; last spell
C1/37C4: 85 DC        STA $DC
C1/37C6: BF 1A 33 D8  LDA $D8331A,X
C1/37CA: 85 DD        STA $DD
C1/37CC: C2 20        REP #$20
C1/37CE: BF 18 33 D8  LDA $D83318,X
C1/37D2: 85 D3        STA $D3
C1/37D4: 18           CLC 
C1/37D5: 69 04 00     ADC #$0004
C1/37D8: 85 D5        STA $D5
C1/37DA: 18           CLC 
C1/37DB: 69 04 00     ADC #$0004
C1/37DE: 85 D7        STA $D7
C1/37E0: 18           CLC 
C1/37E1: 69 04 00     ADC #$0004
C1/37E4: 85 D9        STA $D9
C1/37E6: 7B           TDC 
C1/37E7: E2 20        SEP #$20
C1/37E9: A2 20 00     LDX #$0020
C1/37EC: 4C 95 3F     JMP $3F95

; [  ]

C1/37EF: AD 65 BC     LDA $BC65
C1/37F2: 0D 38 CD     ORA $CD38
C1/37F5: 0D 39 CD     ORA $CD39
C1/37F8: 0D 10 D1     ORA $D110
C1/37FB: 0D D3 DB     ORA $DBD3
C1/37FE: D0 19        BNE $3819
C1/3800: AD 47 CD     LDA $CD47
C1/3803: 29 07        AND #$07
C1/3805: 0A           ASL 
C1/3806: AA           TAX 
C1/3807: BF 1D 38 C1  LDA $C1381D,X
C1/380B: 85 70        STA $70
C1/380D: BF 1E 38 C1  LDA $C1381E,X
C1/3811: 85 71        STA $71
C1/3813: 20 1A 38     JSR $381A
C1/3816: EE 47 CD     INC $CD47
C1/3819: 60           RTS 
C1/381A: 6C 70 00     JMP ($0070)

C1/381D:              .DW $38FE, $3940, $3954, $382D, $397E, $38C2, $3835, $382D 

C1/382D: 60           RTS 

C1/382E: 20 35 38     JSR $3835
C1/3831: 9C 38 CD     STZ $CD38
C1/3834: 60           RTS 

C1/3835: A2 0D BD     LDX #$BD0D
C1/3838: A0 F5 CA     LDY #$CAF5
C1/383B: A9 08        LDA #$08
C1/383D: 85 76        STA $76
C1/383F: A9 22        LDA #$22
C1/3841: 20 B2 39     JSR $39B2
C1/3844: 7B           TDC 
C1/3845: A8           TAY 
C1/3846: A9 FF        LDA #$FF
C1/3848: 99 F6 DB     STA $DBF6,Y
C1/384B: C8           INY 
C1/384C: C0 24 00     CPY #$0024
C1/384F: D0 F7        BNE $3848
C1/3851: A9 01        LDA #$01
C1/3853: 8D FE DB     STA $DBFE
C1/3856: 8D 07 DC     STA $DC07
C1/3859: 8D 10 DC     STA $DC10
C1/385C: 9C 19 DC     STZ $DC19
C1/385F: 7B           TDC 
C1/3860: AA           TAX 
C1/3861: A8           TAY 
C1/3862: BD 44 B4     LDA $B444,X
C1/3865: C9 FF        CMP #$FF
C1/3867: F0 46        BEQ $38AF
C1/3869: DA           PHX 
C1/386A: 0A           ASL 
C1/386B: 0A           ASL 
C1/386C: AA           TAX 
C1/386D: BD 8E 7B     LDA $7B8E,X
C1/3870: 85 70        STA $70
C1/3872: BD 8F 7B     LDA $7B8F,X
C1/3875: 85 71        STA $71
C1/3877: BD 90 7B     LDA $7B90,X
C1/387A: 85 72        STA $72
C1/387C: 64 7E        STZ $7E
C1/387E: 06 72        ASL $72
C1/3880: 26 71        ROL $71
C1/3882: 26 70        ROL $70
C1/3884: B0 10        BCS $3896
C1/3886: E6 7E        INC $7E
C1/3888: A5 7E        LDA $7E
C1/388A: C9 18        CMP #$18
C1/388C: D0 F0        BNE $387E
C1/388E: 98           TYA 
C1/388F: 18           CLC 
C1/3890: 69 09        ADC #$09
C1/3892: A8           TAY 
C1/3893: FA           PLX 
C1/3894: 80 19        BRA $38AF
C1/3896: A5 7E        LDA $7E
C1/3898: 0A           ASL 
C1/3899: 0A           ASL 
C1/389A: 0A           ASL 
C1/389B: AA           TAX 
C1/389C: A9 08        LDA #$08
C1/389E: 85 76        STA $76
C1/38A0: BF B6 28 D1  LDA $D128B6,X
C1/38A4: 99 F6 DB     STA $DBF6,Y
C1/38A7: C8           INY 
C1/38A8: E8           INX 
C1/38A9: C6 76        DEC $76
C1/38AB: D0 F3        BNE $38A0
C1/38AD: FA           PLX 
C1/38AE: C8           INY 
C1/38AF: E8           INX 
C1/38B0: E0 04 00     CPX #$0004
C1/38B3: D0 AD        BNE $3862
C1/38B5: A9 07        LDA #$07
C1/38B7: 20 41 46     JSR $4641
C1/38BA: 20 AC 2D     JSR $2DAC
C1/38BD: A9 07        LDA #$07
C1/38BF: 4C 22 46     JMP $4622
C1/38C2: A2 04 00     LDX #$0004
C1/38C5: 20 DC 38     JSR $38DC
C1/38C8: B0 0A        BCS $38D4
C1/38CA: E8           INX 
C1/38CB: E8           INX 
C1/38CC: E8           INX 
C1/38CD: E8           INX 
C1/38CE: E0 24 00     CPX #$0024
C1/38D1: D0 F2        BNE $38C5
C1/38D3: 60           RTS 
C1/38D4: 20 E4 40     JSR $40E4
C1/38D7: A9 05        LDA #$05
C1/38D9: 4C 22 46     JMP $4622
C1/38DC: A9 04        LDA #$04
C1/38DE: 85 71        STA $71
C1/38E0: 64 70        STZ $70
C1/38E2: BD 2C 38     LDA $382C,X
C1/38E5: DD D9 7C     CMP $7CD9,X
C1/38E8: D0 02        BNE $38EC
C1/38EA: E6 70        INC $70
C1/38EC: 9D D9 7C     STA $7CD9,X
C1/38EF: E8           INX 
C1/38F0: C6 71        DEC $71
C1/38F2: D0 EE        BNE $38E2
C1/38F4: A5 70        LDA $70
C1/38F6: C9 04        CMP #$04
C1/38F8: D0 02        BNE $38FC
C1/38FA: 18           CLC 
C1/38FB: 60           RTS 
C1/38FC: 38           SEC 
C1/38FD: 60           RTS 
C1/38FE: 9C 49 DB     STZ $DB49
C1/3901: 7B           TDC 
C1/3902: AA           TAX 
C1/3903: 20 DC 38     JSR $38DC
C1/3906: B0 0B        BCS $3913
C1/3908: E8           INX 
C1/3909: E8           INX 
C1/390A: E8           INX 
C1/390B: E8           INX 
C1/390C: E0 20 00     CPX #$0020
C1/390F: D0 F2        BNE $3903
C1/3911: 80 06        BRA $3919
C1/3913: EE 49 DB     INC $DB49
C1/3916: 20 5B 40     JSR $405B
C1/3919: AD 25 04     LDA $0425
C1/391C: F0 18        BEQ $3936
C1/391E: 7B           TDC 
C1/391F: AA           TAX 
C1/3920: BD D0 3E     LDA $3ED0,X
C1/3923: DD 3C F5     CMP $F53C,X
C1/3926: D0 08        BNE $3930
C1/3928: E8           INX 
C1/3929: E0 04 00     CPX #$0004
C1/392C: D0 F2        BNE $3920
C1/392E: 80 06        BRA $3936
C1/3930: 20 F4 3F     JSR $3FF4
C1/3933: EE 49 DB     INC $DB49
C1/3936: AD 49 DB     LDA $DB49
C1/3939: F0 04        BEQ $393F
C1/393B: 7B           TDC 
C1/393C: 20 22 46     JSR $4622
C1/393F: 60           RTS 
C1/3940: A2 1B BD     LDX #$BD1B
C1/3943: A0 9B BF     LDY #$BF9B
C1/3946: A9 08        LDA #$08
C1/3948: 85 76        STA $76
C1/394A: A9 12        LDA #$12
C1/394C: 20 B2 39     JSR $39B2
C1/394F: A9 01        LDA #$01
C1/3951: 4C 22 46     JMP $4622
C1/3954: 64 70        STZ $70
C1/3956: 7B           TDC 
C1/3957: AA           TAX 
C1/3958: BD 38 40     LDA $4038,X
C1/395B: DD F9 7C     CMP $7CF9,X
C1/395E: D0 02        BNE $3962
C1/3960: E6 70        INC $70
C1/3962: BD 38 40     LDA $4038,X
C1/3965: 9D F9 7C     STA $7CF9,X
C1/3968: E8           INX 
C1/3969: E8           INX 
C1/396A: E8           INX 
C1/396B: E8           INX 
C1/396C: E0 10 00     CPX #$0010
C1/396F: D0 E7        BNE $3958
C1/3971: 8A           TXA 
C1/3972: C5 70        CMP $70
C1/3974: F0 07        BEQ $397D
C1/3976: 20 A8 3F     JSR $3FA8
C1/3979: 7B           TDC 
C1/397A: 20 22 46     JSR $4622
C1/397D: 60           RTS 
C1/397E: A2 F5 BC     LDX #$BCF5
C1/3981: A0 75 BF     LDY #$BF75
C1/3984: A9 08        LDA #$08
C1/3986: 85 76        STA $76
C1/3988: AD 40 CD     LDA $CD40
C1/398B: D0 1B        BNE $39A8
C1/398D: AD 26 04     LDA $0426
C1/3990: 10 16        BPL $39A8
C1/3992: A9 02        LDA #$02
C1/3994: 20 B2 39     JSR $39B2
C1/3997: A2 B5 BE     LDX #$BEB5
C1/399A: A0 35 C1     LDY #$C135
C1/399D: A9 01        LDA #$01
C1/399F: 85 76        STA $76
C1/39A1: A9 0A        LDA #$0A
C1/39A3: 20 B2 39     JSR $39B2
C1/39A6: 80 05        BRA $39AD
C1/39A8: A9 0A        LDA #$0A
C1/39AA: 20 B2 39     JSR $39B2
C1/39AD: A9 01        LDA #$01
C1/39AF: 4C 22 46     JMP $4622
C1/39B2: 86 70        STX $70
C1/39B4: 84 72        STY $72
C1/39B6: 85 74        STA $74
C1/39B8: 64 75        STZ $75
C1/39BA: 64 77        STZ $77
C1/39BC: C2 20        REP #$20
C1/39BE: 7B           TDC 
C1/39BF: A8           TAY 
C1/39C0: B1 70        LDA ($70),Y
C1/39C2: 91 72        STA ($72),Y
C1/39C4: C8           INY 
C1/39C5: C8           INY 
C1/39C6: C4 74        CPY $74
C1/39C8: D0 F6        BNE $39C0
C1/39CA: A5 70        LDA $70
C1/39CC: 18           CLC 
C1/39CD: 69 40 00     ADC #$0040
C1/39D0: 85 70        STA $70
C1/39D2: A5 72        LDA $72
C1/39D4: 18           CLC 
C1/39D5: 69 40 00     ADC #$0040
C1/39D8: 85 72        STA $72
C1/39DA: C6 76        DEC $76
C1/39DC: D0 E0        BNE $39BE
C1/39DE: 7B           TDC 
C1/39DF: E2 20        SEP #$20
C1/39E1: 60           RTS 
C1/39E2: 7B           TDC 
C1/39E3: AA           TAX 
C1/39E4: BD 34 27     LDA $2734,X
C1/39E7: F0 0C        BEQ $39F5
C1/39E9: E8           INX 
C1/39EA: E0 00 01     CPX #$0100
C1/39ED: D0 F5        BNE $39E4
C1/39EF: A9 01        LDA #$01
C1/39F1: 8D D5 CF     STA $CFD5
C1/39F4: 60           RTS 
C1/39F5: 9C D5 CF     STZ $CFD5
C1/39F8: 60           RTS 

; [ battle graphics function $00: open menu ]

C1/39F9: AD 42 7C     LDA $7C42
C1/39FC: 8D 40 CD     STA $CD40
C1/39FF: A5 71        LDA $71
C1/3A01: D0 51        BNE $3A54
C1/3A03: A5 70        LDA $70
C1/3A05: 0A           ASL 
C1/3A06: 0A           ASL 
C1/3A07: AA           TAX 
C1/3A08: BD 80 09     LDA $0980,X
C1/3A0B: 8D F6 FE     STA $FEF6
C1/3A0E: BD 81 09     LDA $0981,X
C1/3A11: 8D F7 FE     STA $FEF7
C1/3A14: BD 82 09     LDA $0982,X
C1/3A17: 8D F8 FE     STA $FEF8
C1/3A1A: BD 83 09     LDA $0983,X
C1/3A1D: 8D F9 FE     STA $FEF9
C1/3A20: A6 70        LDX $70
C1/3A22: DA           PHX 
C1/3A23: 20 F2 02     JSR $02F2       ; wait one frame
C1/3A26: AD 41 CD     LDA $CD41
C1/3A29: D0 F8        BNE $3A23
C1/3A2B: FA           PLX 
C1/3A2C: 86 70        STX $70
C1/3A2E: 9C F8 CD     STZ $CDF8
C1/3A31: 9C F9 CD     STZ $CDF9
C1/3A34: AD 26 04     LDA $0426
C1/3A37: 29 01        AND #$01
C1/3A39: D0 03        BNE $3A3E
C1/3A3B: 20 71 08     JSR $0871
C1/3A3E: 20 E2 39     JSR $39E2
C1/3A41: A5 70        LDA $70
C1/3A43: 8D 42 CD     STA $CD42
C1/3A46: 8D 0D 01     STA $010D       ; selected character (for multi controller)
C1/3A49: A9 01        LDA #$01
C1/3A4B: 8D B0 41     STA $41B0
C1/3A4E: 8D B7 41     STA $41B7
C1/3A51: EE 41 CD     INC $CD41
C1/3A54: 60           RTS 

; [ battle graphics function $01: close menu ]

C1/3A55: AD 42 CD     LDA $CD42
C1/3A58: C5 70        CMP $70
C1/3A5A: D0 11        BNE $3A6D
C1/3A5C: EE F9 CD     INC $CDF9
C1/3A5F: EE F8 CD     INC $CDF8
C1/3A62: 20 F2 02     JSR $02F2       ; wait one frame
C1/3A65: AD 41 CD     LDA $CD41
C1/3A68: D0 F8        BNE $3A62
C1/3A6A: 20 F2 02     JSR $02F2       ; wait one frame
C1/3A6D: 60           RTS 

; [  ]

C1/3A6E: AD 65 BC     LDA $BC65
C1/3A71: D0 22        BNE $3A95
C1/3A73: AD 38 CD     LDA $CD38
C1/3A76: D0 09        BNE $3A81
C1/3A78: AD 39 CD     LDA $CD39
C1/3A7B: 8D 38 CD     STA $CD38
C1/3A7E: 9C 39 CD     STZ $CD39
C1/3A81: AD 38 CD     LDA $CD38
C1/3A84: 0A           ASL 
C1/3A85: AA           TAX 
C1/3A86: BF 96 3A C1  LDA $C13A96,X
C1/3A8A: 85 70        STA $70
C1/3A8C: BF 97 3A C1  LDA $C13A97,X
C1/3A90: 85 71        STA $71
C1/3A92: 6C 70 00     JMP ($0070)
C1/3A95: 60           RTS 

; battle menu jump table
C1/3A96:              .DW $3A95, $416B, $422B, $455B, $43CE, $4176, $3A95, $422B
C1/3AA6:              .DW $4552, $3CD3, $3CD7, $3CDC, $3CE1, $3CE6, $3CEB, $3CF0
C1/3AB6:              .DW $3CF5, $3CFA, $414B, $421D, $4224, $609D, $60CC, $605C
C1/3AC6:              .DW $60BB, $3CCD, $3CD0, $3CC7, $3CCA, $382E

; 08: item
; 09: spellblade
; 0A: white magic
; 0B: black magic
; 0C: time magic
; 0D: summon
; 0E: blue magic
; 0F: red magic
; 10: song
; 11: x-magic

; [  ]

C1/3AD2: 7B           TDC 
C1/3AD3: AA           TAX 
C1/3AD4: 9D B1 C9     STA $C9B1,X
C1/3AD7: E8           INX 
C1/3AD8: E0 00 01     CPX #$0100
C1/3ADB: D0 F7        BNE $3AD4
C1/3ADD: 60           RTS 

; [  ]

C1/3ADE: 7B           TDC 
C1/3ADF: AA           TAX 
C1/3AE0: 9D 57 F3     STA $F357,X
C1/3AE3: E8           INX 
C1/3AE4: E0 A0 01     CPX #$01A0
C1/3AE7: D0 F7        BNE $3AE0
C1/3AE9: 60           RTS 

; [  ]

C1/3AEA: C2 20        REP #$20
C1/3AEC: A2 38 00     LDX #$0038
C1/3AEF: A9 02 00     LDA #$0002
C1/3AF2: 9D 35 B0     STA $B035,X
C1/3AF5: E8           INX 
C1/3AF6: E8           INX 
C1/3AF7: E8           INX 
C1/3AF8: E8           INX 
C1/3AF9: E0 70 00     CPX #$0070
C1/3AFC: D0 F1        BNE $3AEF
C1/3AFE: A9 07 00     LDA #$0007
C1/3B01: 9D 35 B0     STA $B035,X
C1/3B04: E8           INX 
C1/3B05: E8           INX 
C1/3B06: E8           INX 
C1/3B07: E8           INX 
C1/3B08: E0 B0 00     CPX #$00B0
C1/3B0B: D0 F4        BNE $3B01
C1/3B0D: 7B           TDC 
C1/3B0E: E2 20        SEP #$20
C1/3B10: 60           RTS 

; [  ]

C1/3B11: A2 38 00     LDX #$0038
C1/3B14: 7B           TDC 
C1/3B15: 9D 35 B0     STA $B035,X
C1/3B18: E8           INX 
C1/3B19: E0 B0 00     CPX #$00B0
C1/3B1C: D0 F7        BNE $3B15
C1/3B1E: 60           RTS 

; [  ]

C1/3B1F: 20 D2 3A     JSR $3AD2
C1/3B22: 20 DE 3A     JSR $3ADE
C1/3B25: A2 60 00     LDX #$0060
C1/3B28: 20 95 3F     JSR $3F95
C1/3B2B: AE A0 BC     LDX $BCA0
C1/3B2E: 86 70        STX $70
C1/3B30: AD A2 BC     LDA $BCA2
C1/3B33: 85 72        STA $72
C1/3B35: 7B           TDC 
C1/3B36: AA           TAX 
C1/3B37: A9 10        LDA #$10
C1/3B39: 85 70        STA $70
C1/3B3B: A5 70        LDA $70
C1/3B3D: 9D 01 CA     STA $CA01,X
C1/3B40: 1A           INC 
C1/3B41: 9D 41 CA     STA $CA41,X
C1/3B44: E6 70        INC $70
C1/3B46: E6 70        INC $70
C1/3B48: E8           INX 
C1/3B49: E8           INX 
C1/3B4A: E0 1E 00     CPX #$001E
C1/3B4D: D0 EC        BNE $3B3B
C1/3B4F: 20 5C 3B     JSR $3B5C
C1/3B52: 20 71 29     JSR $2971       ; draw big text string
C1/3B55: 20 EA 3A     JSR $3AEA
C1/3B58: EE 76 BC     INC $BC76
C1/3B5B: 60           RTS 

; [  ]

C1/3B5C: AD F6 DB     LDA $DBF6
C1/3B5F: C9 0F        CMP #$0F
C1/3B61: F0 15        BEQ $3B78
C1/3B63: C9 18        CMP #$18
C1/3B65: F0 14        BEQ $3B7B
C1/3B67: C9 19        CMP #$19
C1/3B69: F0 13        BEQ $3B7E
C1/3B6B: C9 0E        CMP #$0E
C1/3B6D: F0 12        BEQ $3B81
C1/3B6F: C9 1A        CMP #$1A
C1/3B71: F0 11        BEQ $3B84
C1/3B73: A9 09        LDA #$09
C1/3B75: 4C 7F 3C     JMP $3C7F
C1/3B78: 4C 87 3B     JMP $3B87
C1/3B7B: 4C 02 3C     JMP $3C02
C1/3B7E: 4C 22 3C     JMP $3C22
C1/3B81: 4C 62 3C     JMP $3C62
C1/3B84: 4C 42 3C     JMP $3C42

; [  ]

C1/3B87: AD F7 DB     LDA $DBF7
C1/3B8A: C9 57        CMP #$57
C1/3B8C: 90 28        BCC $3BB6
C1/3B8E: 38           SEC 
C1/3B8F: E9 57        SBC #$57
C1/3B91: 85 7E        STA $7E
C1/3B93: A9 09        LDA #$09
C1/3B95: 85 80        STA $80
C1/3B97: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/3B9A: A6 82        LDX $82
C1/3B9C: A9 09        LDA #$09
C1/3B9E: 85 7E        STA $7E
C1/3BA0: 64 80        STZ $80
C1/3BA2: BF 8A 1E D1  LDA $D11E8A,X   ; short attack names
C1/3BA6: C9 FF        CMP #$FF
C1/3BA8: F0 02        BEQ $3BAC
C1/3BAA: E6 80        INC $80
C1/3BAC: E8           INX 
C1/3BAD: C6 7E        DEC $7E
C1/3BAF: D0 F1        BNE $3BA2
C1/3BB1: A5 80        LDA $80
C1/3BB3: 4C 7F 3C     JMP $3C7F
C1/3BB6: 85 7E        STA $7E
C1/3BB8: C9 48        CMP #$48
C1/3BBA: 90 23        BCC $3BDF
C1/3BBC: A9 06        LDA #$06
C1/3BBE: 85 80        STA $80
C1/3BC0: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/3BC3: A6 82        LDX $82
C1/3BC5: A9 06        LDA #$06
C1/3BC7: 85 7E        STA $7E
C1/3BC9: 64 80        STZ $80
C1/3BCB: BF 80 1C D1  LDA $D11C80,X   ; spell type
C1/3BCF: C9 FF        CMP #$FF
C1/3BD1: F0 02        BEQ $3BD5
C1/3BD3: E6 80        INC $80
C1/3BD5: E8           INX 
C1/3BD6: C6 7E        DEC $7E
C1/3BD8: D0 F1        BNE $3BCB
C1/3BDA: A5 80        LDA $80
C1/3BDC: 4C 7F 3C     JMP $3C7F
C1/3BDF: A9 06        LDA #$06
C1/3BE1: 85 80        STA $80
C1/3BE3: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/3BE6: A6 82        LDX $82
C1/3BE8: A9 05        LDA #$05
C1/3BEA: 85 7E        STA $7E
C1/3BEC: 64 80        STZ $80
C1/3BEE: BF 81 1C D1  LDA $D11C81,X   ; spell names
C1/3BF2: C9 FF        CMP #$FF
C1/3BF4: F0 02        BEQ $3BF8
C1/3BF6: E6 80        INC $80
C1/3BF8: E8           INX 
C1/3BF9: C6 7E        DEC $7E
C1/3BFB: D0 F1        BNE $3BEE
C1/3BFD: A5 80        LDA $80
C1/3BFF: 4C 7F 3C     JMP $3C7F

; [  ]

C1/3C02: AD F7 DB     LDA $DBF7
C1/3C05: 20 CF 2B     JSR $2BCF
C1/3C08: A9 05        LDA #$05
C1/3C0A: 85 7E        STA $7E
C1/3C0C: 64 80        STZ $80
C1/3C0E: BF 00 58 D1  LDA $D15800,X
C1/3C12: C9 FF        CMP #$FF
C1/3C14: F0 02        BEQ $3C18
C1/3C16: E6 80        INC $80
C1/3C18: E8           INX 
C1/3C19: C6 7E        DEC $7E
C1/3C1B: D0 F1        BNE $3C0E
C1/3C1D: A5 80        LDA $80
C1/3C1F: 4C 7F 3C     JMP $3C7F
C1/3C22: AD F7 DB     LDA $DBF7
C1/3C25: 20 85 2B     JSR $2B85
C1/3C28: A9 09        LDA #$09
C1/3C2A: 85 7E        STA $7E
C1/3C2C: 64 80        STZ $80
C1/3C2E: BF 00 67 D1  LDA $D16700,X
C1/3C32: C9 FF        CMP #$FF
C1/3C34: F0 02        BEQ $3C38
C1/3C36: E6 80        INC $80
C1/3C38: E8           INX 
C1/3C39: C6 7E        DEC $7E
C1/3C3B: D0 F1        BNE $3C2E
C1/3C3D: A5 80        LDA $80
C1/3C3F: 4C 7F 3C     JMP $3C7F
C1/3C42: AD F7 DB     LDA $DBF7
C1/3C45: 20 91 2B     JSR $2B91
C1/3C48: A9 08        LDA #$08
C1/3C4A: 85 7E        STA $7E
C1/3C4C: 64 80        STZ $80
C1/3C4E: BF 00 87 D0  LDA $D08700,X
C1/3C52: C9 FF        CMP #$FF
C1/3C54: F0 02        BEQ $3C58
C1/3C56: E6 80        INC $80
C1/3C58: E8           INX 
C1/3C59: C6 7E        DEC $7E
C1/3C5B: D0 F1        BNE $3C4E
C1/3C5D: A5 80        LDA $80
C1/3C5F: 4C 7F 3C     JMP $3C7F
C1/3C62: AD F7 DB     LDA $DBF7
C1/3C65: 20 75 2C     JSR $2C75
C1/3C68: A9 08        LDA #$08
C1/3C6A: 85 7E        STA $7E
C1/3C6C: 64 80        STZ $80
C1/3C6E: BF 81 13 D1  LDA $D11381,X
C1/3C72: C9 FF        CMP #$FF
C1/3C74: F0 02        BEQ $3C78
C1/3C76: E6 80        INC $80
C1/3C78: E8           INX 
C1/3C79: C6 7E        DEC $7E
C1/3C7B: D0 F1        BNE $3C6E
C1/3C7D: A5 80        LDA $80
C1/3C7F: AA           TAX 
C1/3C80: BF 02 33 D8  LDA $D83302,X
C1/3C84: 8D 07 F5     STA $F507
C1/3C87: 60           RTS 

; [ draw battle message/dialogue ]

C1/3C88: 20 D2 3A     JSR $3AD2
C1/3C8B: 20 DE 3A     JSR $3ADE
C1/3C8E: A2 50 00     LDX #$0050
C1/3C91: 20 95 3F     JSR $3F95
C1/3C94: 7B           TDC 
C1/3C95: AA           TAX 
C1/3C96: A9 10        LDA #$10
C1/3C98: 85 70        STA $70
C1/3C9A: A5 70        LDA $70
C1/3C9C: 9D F7 C9     STA $C9F7,X
C1/3C9F: 1A           INC 
C1/3CA0: 9D 37 CA     STA $CA37,X
C1/3CA3: E6 70        INC $70
C1/3CA5: E6 70        INC $70
C1/3CA7: E8           INX 
C1/3CA8: E8           INX 
C1/3CA9: E0 34 00     CPX #$0034
C1/3CAC: D0 EC        BNE $3C9A
C1/3CAE: 9C 07 F5     STZ $F507
C1/3CB1: 20 71 29     JSR $2971       ; draw big text string
C1/3CB4: 20 EA 3A     JSR $3AEA
C1/3CB7: EE 76 BC     INC $BC76
C1/3CBA: 60           RTS 

; [ close message window ]

; or maybe just clear text ???

C1/3CBB: 20 D2 3A     JSR $3AD2
C1/3CBE: EE 76 BC     INC $BC76
C1/3CC1: 20 F2 02     JSR $02F2       ; wait one frame
C1/3CC4: 4C 11 3B     JMP $3B11

C1/3CC7: 4C D1 44     JMP $44D1
C1/3CCA: 4C 5A 44     JMP $445A
C1/3CCD: 4C 5E 45     JMP $455E
C1/3CD0: 4C CE 43     JMP $43CE

; [ battle menu $09: spellblade ]

C1/3CD3: 7B           TDC 
C1/3CD4: 4C C8 44     JMP $44C8

; [ battle menu $0A: white magic ]

C1/3CD7: A9 01        LDA #$01
C1/3CD9: 4C C8 44     JMP $44C8

; [ battle menu $0B: black magic ]

C1/3CDC: A9 02        LDA #$02
C1/3CDE: 4C C8 44     JMP $44C8

; [ battle menu $0C: time magic ]

C1/3CE1: A9 03        LDA #$03
C1/3CE3: 4C C8 44     JMP $44C8

; [ battle menu $0D: summon magic ]

C1/3CE6: A9 04        LDA #$04
C1/3CE8: 4C C8 44     JMP $44C8

; [ battle menu $0E: blue magic ]

C1/3CEB: A9 05        LDA #$05
C1/3CED: 4C 51 44     JMP $4451

; [ battle menu $0F: songs ]

C1/3CF0: A9 06        LDA #$06
C1/3CF2: 4C 51 44     JMP $4451

; [ battle menu $10: red magic ]

C1/3CF5: A9 07        LDA #$07
C1/3CF7: 4C C8 44     JMP $44C8

; [ battle menu $11: x-magic ]

C1/3CFA: A9 08        LDA #$08
C1/3CFC: 4C C8 44     JMP $44C8

; [  ]

C1/3CFF: 20 C5 3D     JSR $3DC5
C1/3D02: 20 71 3F     JSR $3F71
C1/3D05: 20 8C 3D     JSR $3D8C
C1/3D08: A2 FF 00     LDX #$00FF
C1/3D0B: 86 70        STX $70
C1/3D0D: A2 35 B5     LDX #$B535
C1/3D10: A0 B3 B2     LDY #$B2B3
C1/3D13: A9 7E        LDA #$7E
C1/3D15: 20 E1 FC     JSR $FCE1       ; move data
C1/3D18: AD B5 B3     LDA $B3B5
C1/3D1B: 38           SEC 
C1/3D1C: E9 E0        SBC #$E0
C1/3D1E: 8D B5 B3     STA $B3B5
C1/3D21: A9 73        LDA #$73
C1/3D23: 8D 21 C2     STA $C221
C1/3D26: A9 75        LDA #$75
C1/3D28: 8D 23 C2     STA $C223
C1/3D2B: 7B           TDC 
C1/3D2C: AA           TAX 
C1/3D2D: A8           TAY 
C1/3D2E: BF EB 32 D8  LDA $D832EB,X
C1/3D32: 99 DF C2     STA $C2DF,Y
C1/3D35: C8           INY 
C1/3D36: C8           INY 
C1/3D37: E8           INX 
C1/3D38: E0 07 00     CPX #$0007
C1/3D3B: D0 F1        BNE $3D2E
C1/3D3D: 7B           TDC 
C1/3D3E: A8           TAY 
C1/3D3F: AA           TAX 
C1/3D40: BF F2 32 D8  LDA $D832F2,X
C1/3D44: 99 F3 C8     STA $C8F3,Y
C1/3D47: BF F6 32 D8  LDA $D832F6,X
C1/3D4B: 99 33 C9     STA $C933,Y
C1/3D4E: BF FA 32 D8  LDA $D832FA,X
C1/3D52: 99 27 C9     STA $C927,Y
C1/3D55: BF FE 32 D8  LDA $D832FE,X
C1/3D59: 99 67 C9     STA $C967,Y
C1/3D5C: C8           INY 
C1/3D5D: C8           INY 
C1/3D5E: E8           INX 
C1/3D5F: E0 04 00     CPX #$0004
C1/3D62: D0 DC        BNE $3D40
C1/3D64: 20 A0 40     JSR $40A0
C1/3D67: AD D3 DB     LDA $DBD3
C1/3D6A: D0 10        BNE $3D7C
C1/3D6C: A2 80 02     LDX #$0280
C1/3D6F: 86 70        STX $70
C1/3D71: A0 80 4A     LDY #$4A80
C1/3D74: A2 B1 BC     LDX #$BCB1
C1/3D77: A9 7E        LDA #$7E
C1/3D79: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/3D7C: A2 00 01     LDX #$0100
C1/3D7F: 86 70        STX $70
C1/3D81: A0 80 1F     LDY #$1F80
C1/3D84: A2 B1 C8     LDX #$C8B1
C1/3D87: A9 7E        LDA #$7E
C1/3D89: 4C CA FD     JMP $FDCA       ; copy data to vram

; [  ]

C1/3D8C: A2 00 00     LDX #$0000
C1/3D8F: 20 95 3F     JSR $3F95
C1/3D92: 20 A8 3F     JSR $3FA8
C1/3D95: 20 5B 40     JSR $405B
C1/3D98: 20 6B 41     JSR $416B
C1/3D9B: AD 40 CD     LDA $CD40
C1/3D9E: F0 03        BEQ $3DA3
C1/3DA0: 4C 76 41     JMP $4176
C1/3DA3: A2 7F 02     LDX #$027F
C1/3DA6: 86 70        STX $70
C1/3DA8: A2 B1 BC     LDX #$BCB1
C1/3DAB: A0 31 BF     LDY #$BF31
C1/3DAE: A9 7E        LDA #$7E
C1/3DB0: 20 E1 FC     JSR $FCE1       ; move data
C1/3DB3: A2 10 00     LDX #$0010
C1/3DB6: 20 95 3F     JSR $3F95
C1/3DB9: A2 40 00     LDX #$0040
C1/3DBC: 20 95 3F     JSR $3F95
C1/3DBF: A2 48 00     LDX #$0048
C1/3DC2: 4C 95 3F     JMP $3F95

; [ init hdma data ]

C1/3DC5: 7B           TDC 
C1/3DC6: AA           TAX 
C1/3DC7: BF E4 32 D8  LDA $D832E4,X   ; load bg3 scroll hdma table
C1/3DCB: 9D 30 A9     STA $A930,X
C1/3DCE: E8           INX 
C1/3DCF: E0 07 00     CPX #$0007
C1/3DD2: D0 F3        BNE $3DC7
C1/3DD4: 7B           TDC 
C1/3DD5: AA           TAX 
C1/3DD6: 9D 37 A9     STA $A937,X     ; clear bg1 and bg2 scroll hdma data
C1/3DD9: E8           INX 
C1/3DDA: E0 80 0A     CPX #$0A80
C1/3DDD: D0 F7        BNE $3DD6
C1/3DDF: AD D3 DB     LDA $DBD3
C1/3DE2: D0 13        BNE $3DF7
C1/3DE4: 7B           TDC 
C1/3DE5: AA           TAX 
C1/3DE6: A9 01        LDA #$01        ; set bg2 v-scroll for menu region to $0101
C1/3DE8: 9D 36 AF     STA $AF36,X
C1/3DEB: 9D 35 AF     STA $AF35,X
C1/3DEE: E8           INX 
C1/3DEF: E8           INX 
C1/3DF0: E8           INX 
C1/3DF1: E8           INX 
C1/3DF2: E0 00 01     CPX #$0100
C1/3DF5: D0 EF        BNE $3DE6
C1/3DF7: 7B           TDC 
C1/3DF8: AA           TAX 
C1/3DF9: A9 01        LDA #$01
C1/3DFB: 9D 27 BB     STA $BB27,X
C1/3DFE: 9D 28 BB     STA $BB28,X
C1/3E01: E8           INX 
C1/3E02: E8           INX 
C1/3E03: E8           INX 
C1/3E04: E8           INX 
C1/3E05: E0 60 00     CPX #$0060
C1/3E08: D0 F1        BNE $3DFB
C1/3E0A: 7B           TDC 
C1/3E0B: AA           TAX 
C1/3E0C: A8           TAY 
C1/3E0D: A9 04        LDA #$04
C1/3E0F: 85 70        STA $70
C1/3E11: BF C6 32 D8  LDA $D832C6,X
C1/3E15: 99 37 B5     STA $B537,Y
C1/3E18: C8           INY 
C1/3E19: C8           INY 
C1/3E1A: C8           INY 
C1/3E1B: C8           INY 
C1/3E1C: C6 70        DEC $70
C1/3E1E: D0 F1        BNE $3E11
C1/3E20: E8           INX 
C1/3E21: C0 00 01     CPY #$0100
C1/3E24: D0 E7        BNE $3E0D
C1/3E26: 7B           TDC 
C1/3E27: AA           TAX 
C1/3E28: C2 20        REP #$20
C1/3E2A: DE 37 B5     DEC $B537,X
C1/3E2D: BD 37 B5     LDA $B537,X
C1/3E30: 9D 17 B7     STA $B717,X
C1/3E33: 48           PHA 
C1/3E34: 38           SEC 
C1/3E35: E9 50 00     SBC #$0050
C1/3E38: 18           CLC 
C1/3E39: 69 00 01     ADC #$0100
C1/3E3C: 9D 37 B6     STA $B637,X
C1/3E3F: 68           PLA 
C1/3E40: 38           SEC 
C1/3E41: E9 0A 00     SBC #$000A
C1/3E44: 18           CLC 
C1/3E45: 69 00 01     ADC #$0100
C1/3E48: 9D 57 B9     STA $B957,X
C1/3E4B: FE 56 B9     INC $B956,X
C1/3E4E: FE 16 B7     INC $B716,X
C1/3E51: BD 35 B5     LDA $B535,X
C1/3E54: 18           CLC 
C1/3E55: 69 00 01     ADC #$0100
C1/3E58: 9D 85 BB     STA $BB85,X
C1/3E5B: BD 37 B5     LDA $B537,X
C1/3E5E: 18           CLC 
C1/3E5F: 69 F8 00     ADC #$00F8
C1/3E62: 9D 87 BB     STA $BB87,X
C1/3E65: E8           INX 
C1/3E66: E8           INX 
C1/3E67: E8           INX 
C1/3E68: E8           INX 
C1/3E69: E0 E0 00     CPX #$00E0
C1/3E6C: D0 BC        BNE $3E2A
C1/3E6E: 7B           TDC 
C1/3E6F: AA           TAX 
C1/3E70: BD E7 AF     LDA $AFE7,X
C1/3E73: 1A           INC 
C1/3E74: 9D 05 BA     STA $BA05,X
C1/3E77: BD E9 AF     LDA $AFE9,X
C1/3E7A: 1A           INC 
C1/3E7B: 9D 07 BA     STA $BA07,X
C1/3E7E: E8           INX 
C1/3E7F: E8           INX 
C1/3E80: E8           INX 
C1/3E81: E8           INX 
C1/3E82: E0 10 00     CPX #$0010
C1/3E85: D0 E9        BNE $3E70
C1/3E87: 7B           TDC 
C1/3E88: E2 20        SEP #$20
C1/3E8A: 7B           TDC 
C1/3E8B: AA           TAX 
C1/3E8C: C2 20        REP #$20
C1/3E8E: BD 37 B5     LDA $B537,X
C1/3E91: 38           SEC 
C1/3E92: E9 80 00     SBC #$0080
C1/3E95: 18           CLC 
C1/3E96: 69 F8 00     ADC #$00F8
C1/3E99: 9D D7 B8     STA $B8D7,X
C1/3E9C: E8           INX 
C1/3E9D: E8           INX 
C1/3E9E: E8           INX 
C1/3E9F: E8           INX 
C1/3EA0: E0 80 00     CPX #$0080
C1/3EA3: D0 E9        BNE $3E8E
C1/3EA5: 7B           TDC 
C1/3EA6: E2 20        SEP #$20
C1/3EA8: 7B           TDC 
C1/3EA9: AA           TAX 
C1/3EAA: A8           TAY 
C1/3EAB: A9 04        LDA #$04
C1/3EAD: 85 70        STA $70
C1/3EAF: A9 01        LDA #$01
C1/3EB1: 99 F6 B7     STA $B7F6,Y
C1/3EB4: BF D6 32 D8  LDA $D832D6,X
C1/3EB8: C2 20        REP #$20
C1/3EBA: 38           SEC 
C1/3EBB: E9 A4 00     SBC #$00A4
C1/3EBE: 99 F7 B7     STA $B7F7,Y
C1/3EC1: 7B           TDC 
C1/3EC2: E2 20        SEP #$20
C1/3EC4: C8           INY 
C1/3EC5: C8           INY 
C1/3EC6: C8           INY 
C1/3EC7: C8           INY 
C1/3EC8: C6 70        DEC $70
C1/3ECA: D0 E3        BNE $3EAF
C1/3ECC: E8           INX 
C1/3ECD: C0 E0 00     CPY #$00E0
C1/3ED0: D0 D9        BNE $3EAB
C1/3ED2: 60           RTS 

; [  ]

C1/3ED3: DA           PHX 
C1/3ED4: 5A           PHY 
C1/3ED5: AD 70 BC     LDA $BC70
C1/3ED8: 85 7E        STA $7E
C1/3EDA: A9 40        LDA #$40
C1/3EDC: 85 80        STA $80
C1/3EDE: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/3EE1: AD 6F BC     LDA $BC6F
C1/3EE4: C2 20        REP #$20
C1/3EE6: 0A           ASL 
C1/3EE7: 18           CLC 
C1/3EE8: 65 82        ADC $82
C1/3EEA: 18           CLC 
C1/3EEB: 6D 6D BC     ADC $BC6D
C1/3EEE: 85 70        STA $70
C1/3EF0: 7B           TDC 
C1/3EF1: E2 20        SEP #$20
C1/3EF3: AD 74 BC     LDA $BC74
C1/3EF6: 85 74        STA $74
C1/3EF8: AD 73 BC     LDA $BC73
C1/3EFB: AA           TAX 
C1/3EFC: 7B           TDC 
C1/3EFD: A8           TAY 
C1/3EFE: CE 71 BC     DEC $BC71
C1/3F01: CE 72 BC     DEC $BC72
C1/3F04: CE 72 BC     DEC $BC72
C1/3F07: 0E 71 BC     ASL $BC71
C1/3F0A: 20 53 3F     JSR $3F53
C1/3F0D: E8           INX 
C1/3F0E: 20 53 3F     JSR $3F53
C1/3F11: 98           TYA 
C1/3F12: CD 71 BC     CMP $BC71
C1/3F15: D0 F7        BNE $3F0E
C1/3F17: E8           INX 
C1/3F18: 20 53 3F     JSR $3F53
C1/3F1B: 20 60 3F     JSR $3F60
C1/3F1E: AD 73 BC     LDA $BC73
C1/3F21: 18           CLC 
C1/3F22: 69 03        ADC #$03
C1/3F24: AA           TAX 
C1/3F25: 20 53 3F     JSR $3F53
C1/3F28: E8           INX 
C1/3F29: 20 53 3F     JSR $3F53
C1/3F2C: 98           TYA 
C1/3F2D: CD 71 BC     CMP $BC71
C1/3F30: D0 F7        BNE $3F29
C1/3F32: E8           INX 
C1/3F33: 20 53 3F     JSR $3F53
C1/3F36: 20 60 3F     JSR $3F60
C1/3F39: CE 72 BC     DEC $BC72
C1/3F3C: D0 E0        BNE $3F1E
C1/3F3E: E8           INX 
C1/3F3F: 20 53 3F     JSR $3F53
C1/3F42: E8           INX 
C1/3F43: 20 53 3F     JSR $3F53
C1/3F46: 98           TYA 
C1/3F47: CD 71 BC     CMP $BC71
C1/3F4A: D0 F7        BNE $3F43
C1/3F4C: E8           INX 
C1/3F4D: 20 53 3F     JSR $3F53
C1/3F50: 7A           PLY 
C1/3F51: FA           PLX 
C1/3F52: 60           RTS 

; [  ]

C1/3F53: BF 57 B9 D4  LDA $D4B957,X
C1/3F57: 91 70        STA ($70),Y
C1/3F59: C8           INY 
C1/3F5A: A5 74        LDA $74
C1/3F5C: 91 70        STA ($70),Y
C1/3F5E: C8           INY 
C1/3F5F: 60           RTS 

; [  ]

C1/3F60: A5 70        LDA $70
C1/3F62: 18           CLC 
C1/3F63: 69 40        ADC #$40
C1/3F65: 85 70        STA $70
C1/3F67: A5 71        LDA $71
C1/3F69: 69 00        ADC #$00
C1/3F6B: 85 71        STA $71
C1/3F6D: A0 00 00     LDY #$0000
C1/3F70: 60           RTS 

; [  ]

C1/3F71: A2 00 00     LDX #$0000
C1/3F74: 20 95 3F     JSR $3F95
C1/3F77: A2 08 00     LDX #$0008
C1/3F7A: 20 95 3F     JSR $3F95
C1/3F7D: A2 20 00     LDX #$0020
C1/3F80: 20 95 3F     JSR $3F95
C1/3F83: A2 38 00     LDX #$0038
C1/3F86: 20 95 3F     JSR $3F95
C1/3F89: A2 68 00     LDX #$0068
C1/3F8C: 20 95 3F     JSR $3F95
C1/3F8F: A2 70 00     LDX #$0070
C1/3F92: 4C 95 3F     JMP $3F95

; [  ]

C1/3F95: 7B           TDC 
C1/3F96: A8           TAY 
C1/3F97: BF 96 31 D8  LDA $D83196,X
C1/3F9B: 99 6D BC     STA $BC6D,Y
C1/3F9E: C8           INY 
C1/3F9F: E8           INX 
C1/3FA0: C0 08 00     CPY #$0008
C1/3FA3: D0 F2        BNE $3F97
C1/3FA5: 4C D3 3E     JMP $3ED3

; [  ]

C1/3FA8: A2 00 00     LDX #$0000
C1/3FAB: 20 95 3F     JSR $3F95
C1/3FAE: AD EF 3E     LDA $3EEF
C1/3FB1: 29 40        AND #$40
C1/3FB3: D0 3E        BNE $3FF3
C1/3FB5: 7B           TDC 
C1/3FB6: 20 41 46     JSR $4641
C1/3FB9: 7B           TDC 
C1/3FBA: A8           TAY 
C1/3FBB: AA           TAX 
C1/3FBC: BD 3A 40     LDA $403A,X
C1/3FBF: F0 22        BEQ $3FE3
C1/3FC1: A9 0B        LDA #$0B
C1/3FC3: 99 F6 DB     STA $DBF6,Y
C1/3FC6: 8A           TXA 
C1/3FC7: 4A           LSR 
C1/3FC8: 4A           LSR 
C1/3FC9: 99 F7 DB     STA $DBF7,Y
C1/3FCC: 99 FA DB     STA $DBFA,Y
C1/3FCF: A9 0C        LDA #$0C
C1/3FD1: 99 F9 DB     STA $DBF9,Y
C1/3FD4: A9 FF        LDA #$FF
C1/3FD6: 99 F8 DB     STA $DBF8,Y
C1/3FD9: A9 01        LDA #$01
C1/3FDB: 99 FB DB     STA $DBFB,Y
C1/3FDE: 98           TYA 
C1/3FDF: 18           CLC 
C1/3FE0: 69 06        ADC #$06
C1/3FE2: A8           TAY 
C1/3FE3: E8           INX 
C1/3FE4: E8           INX 
C1/3FE5: E8           INX 
C1/3FE6: E8           INX 
C1/3FE7: E0 10 00     CPX #$0010
C1/3FEA: D0 D0        BNE $3FBC
C1/3FEC: 7B           TDC 
C1/3FED: 99 F6 DB     STA $DBF6,Y
C1/3FF0: 20 AC 2D     JSR $2DAC
C1/3FF3: 60           RTS 

; [  ]

C1/3FF4: 7B           TDC 
C1/3FF5: AA           TAX 
C1/3FF6: BD D0 3E     LDA $3ED0,X
C1/3FF9: 9D 3C F5     STA $F53C,X
C1/3FFC: E8           INX 
C1/3FFD: E0 04 00     CPX #$0004
C1/4000: D0 F4        BNE $3FF6
C1/4002: A2 63 BD     LDX #$BD63
C1/4005: 86 70        STX $70
C1/4007: 7B           TDC 
C1/4008: A8           TAY 
C1/4009: B9 44 B4     LDA $B444,Y
C1/400C: C9 FF        CMP #$FF
C1/400E: F0 44        BEQ $4054
C1/4010: AA           TAX 
C1/4011: 64 74        STZ $74
C1/4013: BD D0 3E     LDA $3ED0,X
C1/4016: D0 04        BNE $401C
C1/4018: A9 08        LDA #$08
C1/401A: 85 74        STA $74
C1/401C: BD D0 3E     LDA $3ED0,X
C1/401F: C9 80        CMP #$80
C1/4021: 90 02        BCC $4025
C1/4023: A9 7F        LDA #$7F
C1/4025: 29 FC        AND #$FC
C1/4027: AA           TAX 
C1/4028: 5A           PHY 
C1/4029: A0 02 00     LDY #$0002
C1/402C: A9 0A        LDA #$0A
C1/402E: 92 70        STA ($70)
C1/4030: BF 46 32 D8  LDA $D83246,X
C1/4034: 91 70        STA ($70),Y
C1/4036: C8           INY 
C1/4037: A5 74        LDA $74
C1/4039: 91 70        STA ($70),Y
C1/403B: C8           INY 
C1/403C: E8           INX 
C1/403D: C0 0A 00     CPY #$000A
C1/4040: D0 EE        BNE $4030
C1/4042: A9 0B        LDA #$0B
C1/4044: 91 70        STA ($70),Y
C1/4046: C2 20        REP #$20
C1/4048: A5 70        LDA $70
C1/404A: 18           CLC 
C1/404B: 69 80 00     ADC #$0080
C1/404E: 85 70        STA $70
C1/4050: 7B           TDC 
C1/4051: E2 20        SEP #$20
C1/4053: 7A           PLY 
C1/4054: C8           INY 
C1/4055: C0 04 00     CPY #$0004
C1/4058: D0 AF        BNE $4009
C1/405A: 60           RTS 

; [  ]

C1/405B: A9 04        LDA #$04
C1/405D: 20 41 46     JSR $4641
C1/4060: A9 02        LDA #$02
C1/4062: 20 56 46     JSR $4656
C1/4065: 7B           TDC 
C1/4066: AA           TAX 
C1/4067: A8           TAY 
C1/4068: BD 44 B4     LDA $B444,X
C1/406B: C9 FF        CMP #$FF
C1/406D: F0 12        BEQ $4081
C1/406F: B9 F6 DB     LDA $DBF6,Y
C1/4072: 18           CLC 
C1/4073: 7D 44 B4     ADC $B444,X
C1/4076: 99 F6 DB     STA $DBF6,Y
C1/4079: 99 F9 DB     STA $DBF9,Y
C1/407C: 98           TYA 
C1/407D: 18           CLC 
C1/407E: 69 06        ADC #$06
C1/4080: A8           TAY 
C1/4081: E8           INX 
C1/4082: E0 04 00     CPX #$0004
C1/4085: D0 E1        BNE $4068
C1/4087: 7B           TDC 
C1/4088: 99 F6 DB     STA $DBF6,Y
C1/408B: 20 AC 2D     JSR $2DAC
C1/408E: A9 5E        LDA #$5E
C1/4090: 8D 1F BD     STA $BD1F
C1/4093: 1A           INC 
C1/4094: 8D 21 BD     STA $BD21
C1/4097: AD 25 04     LDA $0425
C1/409A: F0 03        BEQ $409F
C1/409C: 20 F4 3F     JSR $3FF4
C1/409F: 60           RTS 

; [  ]

C1/40A0: A9 01        LDA #$01
C1/40A2: 20 41 46     JSR $4641
C1/40A5: A9 01        LDA #$01
C1/40A7: 20 56 46     JSR $4656
C1/40AA: 7B           TDC 
C1/40AB: AA           TAX 
C1/40AC: A8           TAY 
C1/40AD: BD 44 B4     LDA $B444,X
C1/40B0: C9 FF        CMP #$FF
C1/40B2: F0 23        BEQ $40D7
C1/40B4: B9 F8 DB     LDA $DBF8,Y
C1/40B7: 18           CLC 
C1/40B8: 7D 44 B4     ADC $B444,X
C1/40BB: 99 F8 DB     STA $DBF8,Y
C1/40BE: AD B0 41     LDA $41B0
C1/40C1: 29 01        AND #$01
C1/40C3: F0 0D        BEQ $40D2
C1/40C5: BD 44 B4     LDA $B444,X
C1/40C8: CD 42 CD     CMP $CD42
C1/40CB: D0 05        BNE $40D2
C1/40CD: A9 08        LDA #$08
C1/40CF: 99 F7 DB     STA $DBF7,Y
C1/40D2: 98           TYA 
C1/40D3: 18           CLC 
C1/40D4: 69 05        ADC #$05
C1/40D6: A8           TAY 
C1/40D7: E8           INX 
C1/40D8: E0 04 00     CPX #$0004
C1/40DB: D0 D0        BNE $40AD
C1/40DD: 7B           TDC 
C1/40DE: 99 F6 DB     STA $DBF6,Y
C1/40E1: 4C AC 2D     JMP $2DAC

; [  ]

C1/40E4: AD 42 CD     LDA $CD42
C1/40E7: 0A           ASL 
C1/40E8: 0A           ASL 
C1/40E9: 0A           ASL 
C1/40EA: AA           TAX 
C1/40EB: C2 20        REP #$20
C1/40ED: BD 30 38     LDA $3830,X
C1/40F0: 85 70        STA $70
C1/40F2: BD 32 38     LDA $3832,X
C1/40F5: 85 72        STA $72
C1/40F7: 7B           TDC 
C1/40F8: E2 20        SEP #$20
C1/40FA: A5 CE        LDA $CE
C1/40FC: 48           PHA 
C1/40FD: A9 69        LDA #$69
C1/40FF: 85 CE        STA $CE
C1/4101: A6 70        LDX $70
C1/4103: A0 AE 00     LDY #$00AE
C1/4106: 20 2F 41     JSR $412F
C1/4109: A9 76        LDA #$76
C1/410B: 8D 65 C2     STA $C265
C1/410E: C8           INY 
C1/410F: C8           INY 
C1/4110: A6 72        LDX $72
C1/4112: 20 2F 41     JSR $412F
C1/4115: AD 42 CD     LDA $CD42
C1/4118: A8           TAY 
C1/4119: 0A           ASL 
C1/411A: AA           TAX 
C1/411B: A5 DB        LDA $DB
C1/411D: 18           CLC 
C1/411E: 71 D3        ADC ($D3),Y
C1/4120: C2 20        REP #$20
C1/4122: 18           CLC 
C1/4123: 7F 8D FF CE  ADC $CEFF8D,X
C1/4127: AA           TAX 
C1/4128: 7B           TDC 
C1/4129: E2 20        SEP #$20
C1/412B: 68           PLA 
C1/412C: 85 CE        STA $CE
C1/412E: 60           RTS 

; [  ]

C1/412F: 20 2E FF     JSR $FF2E
C1/4132: 20 0E FF     JSR $FF0E
C1/4135: A5 C5        LDA $C5
C1/4137: 99 B1 C1     STA $C1B1,Y
C1/413A: C8           INY 
C1/413B: C8           INY 
C1/413C: A5 C6        LDA $C6
C1/413E: 99 B1 C1     STA $C1B1,Y
C1/4141: C8           INY 
C1/4142: C8           INY 
C1/4143: A5 C7        LDA $C7
C1/4145: 99 B1 C1     STA $C1B1,Y
C1/4148: C8           INY 
C1/4149: C8           INY 
C1/414A: 60           RTS 
C1/414B: 20 E4 40     JSR $40E4
C1/414E: A5 CE        LDA $CE
C1/4150: 48           PHA 
C1/4151: A9 69        LDA #$69
C1/4153: 85 CE        STA $CE
C1/4155: BD 38 2E     LDA $2E38,X
C1/4158: AA           TAX 
C1/4159: A0 B2 01     LDY #$01B2
C1/415C: 20 2F 41     JSR $412F
C1/415F: 68           PLA 
C1/4160: 85 CE        STA $CE
C1/4162: A9 05        LDA #$05
C1/4164: 20 22 46     JSR $4622
C1/4167: 9C 38 CD     STZ $CD38
C1/416A: 60           RTS 
C1/416B: 20 A0 40     JSR $40A0
C1/416E: 7B           TDC 
C1/416F: 20 22 46     JSR $4622
C1/4172: 9C 38 CD     STZ $CD38
C1/4175: 60           RTS 
C1/4176: A2 7F 02     LDX #$027F
C1/4179: 86 70        STX $70
C1/417B: A2 B1 BC     LDX #$BCB1
C1/417E: A9 7E        LDA #$7E
C1/4180: A0 31 BF     LDY #$BF31
C1/4183: 20 E1 FC     JSR $FCE1       ; move data
C1/4186: A2 28 00     LDX #$0028
C1/4189: 20 95 3F     JSR $3F95
C1/418C: 20 A7 41     JSR $41A7
C1/418F: A9 04        LDA #$04
C1/4191: 85 75        STA $75
C1/4193: 20 7F 42     JSR $427F
C1/4196: A9 03        LDA #$03
C1/4198: 20 41 46     JSR $4641
C1/419B: 20 AC 2D     JSR $2DAC
C1/419E: A9 01        LDA #$01
C1/41A0: 20 22 46     JSR $4622
C1/41A3: 9C 38 CD     STZ $CD38
C1/41A6: 60           RTS 
C1/41A7: AD 42 CD     LDA $CD42
C1/41AA: 0A           ASL 
C1/41AB: AA           TAX 
C1/41AC: C2 20        REP #$20
C1/41AE: BF 10 FF CE  LDA $CEFF10,X
C1/41B2: 85 70        STA $70
C1/41B4: BF 18 FF CE  LDA $CEFF18,X
C1/41B8: 85 72        STA $72
C1/41BA: 7B           TDC 
C1/41BB: E2 20        SEP #$20
C1/41BD: 60           RTS 
C1/41BE: AD 42 CD     LDA $CD42
C1/41C1: 0A           ASL 
C1/41C2: AA           TAX 
C1/41C3: C2 20        REP #$20
C1/41C5: BF 00 FF CE  LDA $CEFF00,X
C1/41C9: 85 70        STA $70
C1/41CB: BF 08 FF CE  LDA $CEFF08,X
C1/41CF: 85 72        STA $72
C1/41D1: 7B           TDC 
C1/41D2: E2 20        SEP #$20
C1/41D4: 60           RTS 

; [  ]

C1/41D5: A2 98 00     LDX #$0098
C1/41D8: 80 03        BRA $41DD
C1/41DA: A2 C0 01     LDX #$01C0
C1/41DD: 86 72        STX $72
C1/41DF: AD 26 04     LDA $0426
C1/41E2: 10 03        BPL $41E7       ; branch if memory cursor setting
C1/41E4: 7B           TDC 
C1/41E5: 80 08        BRA $41EF
C1/41E7: AD 42 CD     LDA $CD42
C1/41EA: AA           TAX 
C1/41EB: BD 2D 04     LDA $042D,X
C1/41EE: 0A           ASL 
C1/41EF: AA           TAX 
C1/41F0: C2 20        REP #$20
C1/41F2: BF 00 30 D8  LDA $D83000,X   ; battle menu cursor positions
C1/41F6: 85 70        STA $70
C1/41F8: 7B           TDC 
C1/41F9: AA           TAX 
C1/41FA: A5 72        LDA $72
C1/41FC: 9D 25 BB     STA $BB25,X
C1/41FF: BD 37 B5     LDA $B537,X
C1/4202: 18           CLC 
C1/4203: 65 70        ADC $70
C1/4205: 18           CLC 
C1/4206: 69 40 00     ADC #$0040
C1/4209: 18           CLC 
C1/420A: 69 00 01     ADC #$0100
C1/420D: 9D 27 BB     STA $BB27,X
C1/4210: E8           INX 
C1/4211: E8           INX 
C1/4212: E8           INX 
C1/4213: E8           INX 
C1/4214: E0 50 00     CPX #$0050
C1/4217: D0 E1        BNE $41FA
C1/4219: 7B           TDC 
C1/421A: E2 20        SEP #$20
C1/421C: 60           RTS 
C1/421D: 20 DA 41     JSR $41DA
C1/4220: 9C 38 CD     STZ $CD38
C1/4223: 60           RTS 
C1/4224: 20 D5 41     JSR $41D5
C1/4227: 9C 38 CD     STZ $CD38
C1/422A: 60           RTS 

; [ battle graphics function $05:  ]

C1/422B: 20 A0 40     JSR $40A0
C1/422E: AD 40 CD     LDA $CD40
C1/4231: F0 03        BEQ $4236
C1/4233: 4C 76 41     JMP $4176
C1/4236: A2 7F 02     LDX #$027F
C1/4239: 86 70        STX $70
C1/423B: A2 B1 BC     LDX #$BCB1
C1/423E: A9 7E        LDA #$7E
C1/4240: A0 31 BF     LDY #$BF31
C1/4243: 20 E1 FC     JSR $FCE1       ; move data
C1/4246: AD 26 04     LDA $0426
C1/4249: 10 13        BPL $425E
C1/424B: A2 78 00     LDX #$0078
C1/424E: 20 95 3F     JSR $3F95
C1/4251: 20 BE 41     JSR $41BE
C1/4254: 20 65 43     JSR $4365
C1/4257: A9 08        LDA #$08
C1/4259: 20 41 46     JSR $4641
C1/425C: 80 15        BRA $4273
C1/425E: A2 10 00     LDX #$0010
C1/4261: 20 95 3F     JSR $3F95
C1/4264: 20 BE 41     JSR $41BE
C1/4267: A9 04        LDA #$04
C1/4269: 85 75        STA $75
C1/426B: 20 F3 42     JSR $42F3
C1/426E: A9 03        LDA #$03
C1/4270: 20 41 46     JSR $4641
C1/4273: 20 AC 2D     JSR $2DAC
C1/4276: A9 01        LDA #$01
C1/4278: 20 22 46     JSR $4622
C1/427B: 9C 38 CD     STZ $CD38
C1/427E: 60           RTS 
C1/427F: 7B           TDC 
C1/4280: A8           TAY 
C1/4281: A9 0D        LDA #$0D
C1/4283: 99 F6 DB     STA $DBF6,Y
C1/4286: C8           INY 
C1/4287: B2 72        LDA ($72)
C1/4289: 30 04        BMI $428F
C1/428B: A9 00        LDA #$00
C1/428D: 80 02        BRA $4291
C1/428F: A9 04        LDA #$04
C1/4291: 99 F6 DB     STA $DBF6,Y
C1/4294: C8           INY 
C1/4295: B2 70        LDA ($70)
C1/4297: C9 57        CMP #$57
C1/4299: 90 21        BCC $42BC
C1/429B: 38           SEC 
C1/429C: E9 57        SBC #$57
C1/429E: 85 7E        STA $7E
C1/42A0: A9 09        LDA #$09
C1/42A2: 85 80        STA $80
C1/42A4: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/42A7: A6 82        LDX $82
C1/42A9: A9 09        LDA #$09
C1/42AB: 85 74        STA $74
C1/42AD: BF 8A 1E D1  LDA $D11E8A,X
C1/42B1: 99 F6 DB     STA $DBF6,Y
C1/42B4: E8           INX 
C1/42B5: C8           INY 
C1/42B6: C6 74        DEC $74
C1/42B8: D0 F3        BNE $42AD
C1/42BA: 80 1C        BRA $42D8
C1/42BC: 85 7E        STA $7E
C1/42BE: A9 06        LDA #$06
C1/42C0: 85 80        STA $80
C1/42C2: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/42C5: A6 82        LDX $82
C1/42C7: A9 06        LDA #$06
C1/42C9: 85 74        STA $74
C1/42CB: BF 80 1C D1  LDA $D11C80,X
C1/42CF: 99 F6 DB     STA $DBF6,Y
C1/42D2: E8           INX 
C1/42D3: C8           INY 
C1/42D4: C6 74        DEC $74
C1/42D6: D0 F3        BNE $42CB
C1/42D8: A9 01        LDA #$01
C1/42DA: 99 F6 DB     STA $DBF6,Y
C1/42DD: C8           INY 
C1/42DE: DA           PHX 
C1/42DF: A6 70        LDX $70
C1/42E1: E8           INX 
C1/42E2: 86 70        STX $70
C1/42E4: A6 72        LDX $72
C1/42E6: E8           INX 
C1/42E7: 86 72        STX $72
C1/42E9: FA           PLX 
C1/42EA: C6 75        DEC $75
C1/42EC: D0 93        BNE $4281
C1/42EE: 7B           TDC 
C1/42EF: 99 F6 DB     STA $DBF6,Y
C1/42F2: 60           RTS 
C1/42F3: 7B           TDC 
C1/42F4: A8           TAY 
C1/42F5: 20 16 43     JSR $4316
C1/42F8: 20 36 43     JSR $4336
C1/42FB: A9 01        LDA #$01
C1/42FD: 99 F6 DB     STA $DBF6,Y
C1/4300: C8           INY 
C1/4301: DA           PHX 
C1/4302: A6 70        LDX $70
C1/4304: E8           INX 
C1/4305: 86 70        STX $70
C1/4307: A6 72        LDX $72
C1/4309: E8           INX 
C1/430A: 86 72        STX $72
C1/430C: FA           PLX 
C1/430D: C6 75        DEC $75
C1/430F: D0 E4        BNE $42F5
C1/4311: 7B           TDC 
C1/4312: 99 F6 DB     STA $DBF6,Y
C1/4315: 60           RTS 
C1/4316: B2 70        LDA ($70)
C1/4318: 85 7E        STA $7E
C1/431A: A9 05        LDA #$05
C1/431C: 85 80        STA $80
C1/431E: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/4321: A9 0D        LDA #$0D
C1/4323: 99 F6 DB     STA $DBF6,Y
C1/4326: C8           INY 
C1/4327: B2 72        LDA ($72)
C1/4329: 30 04        BMI $432F
C1/432B: A9 00        LDA #$00
C1/432D: 80 02        BRA $4331
C1/432F: A9 04        LDA #$04
C1/4331: 99 F6 DB     STA $DBF6,Y
C1/4334: C8           INY 
C1/4335: 60           RTS 
C1/4336: A6 82        LDX $82
C1/4338: A9 05        LDA #$05
C1/433A: 85 74        STA $74
C1/433C: BF 00 58 D1  LDA $D15800,X
C1/4340: 99 F6 DB     STA $DBF6,Y
C1/4343: E8           INX 
C1/4344: C8           INY 
C1/4345: C6 74        DEC $74
C1/4347: D0 F3        BNE $433C
C1/4349: 60           RTS 
C1/434A: 99 F6 DB     STA $DBF6,Y
C1/434D: C8           INY 
C1/434E: 60           RTS 
C1/434F: AA           TAX 
C1/4350: BD F6 FE     LDA $FEF6,X
C1/4353: C2 20        REP #$20
C1/4355: 48           PHA 
C1/4356: 18           CLC 
C1/4357: 65 78        ADC $78
C1/4359: 85 70        STA $70
C1/435B: 68           PLA 
C1/435C: 18           CLC 
C1/435D: 65 7A        ADC $7A
C1/435F: 85 72        STA $72
C1/4361: 7B           TDC 
C1/4362: E2 20        SEP #$20
C1/4364: 60           RTS 
C1/4365: A6 70        LDX $70
C1/4367: 86 78        STX $78
C1/4369: A6 72        LDX $72
C1/436B: 86 7A        STX $7A
C1/436D: 7B           TDC 
C1/436E: A8           TAY 
C1/436F: 7B           TDC 
C1/4370: 20 4F 43     JSR $434F
C1/4373: 20 16 43     JSR $4316
C1/4376: A9 FF        LDA #$FF
C1/4378: 20 4A 43     JSR $434A
C1/437B: 20 4A 43     JSR $434A
C1/437E: 20 4A 43     JSR $434A
C1/4381: 20 4A 43     JSR $434A
C1/4384: 20 36 43     JSR $4336
C1/4387: A9 01        LDA #$01
C1/4389: 20 4A 43     JSR $434A
C1/438C: A9 01        LDA #$01
C1/438E: 20 4F 43     JSR $434F
C1/4391: 20 16 43     JSR $4316
C1/4394: 20 36 43     JSR $4336
C1/4397: A9 FF        LDA #$FF
C1/4399: 20 4A 43     JSR $434A
C1/439C: A9 02        LDA #$02
C1/439E: 20 4F 43     JSR $434F
C1/43A1: 20 16 43     JSR $4316
C1/43A4: A9 FF        LDA #$FF
C1/43A6: 20 4A 43     JSR $434A
C1/43A9: 20 36 43     JSR $4336
C1/43AC: A9 01        LDA #$01
C1/43AE: 20 4A 43     JSR $434A
C1/43B1: A9 03        LDA #$03
C1/43B3: 20 4F 43     JSR $434F
C1/43B6: 20 16 43     JSR $4316
C1/43B9: A9 FF        LDA #$FF
C1/43BB: 20 4A 43     JSR $434A
C1/43BE: 20 4A 43     JSR $434A
C1/43C1: 20 4A 43     JSR $434A
C1/43C4: 20 4A 43     JSR $434A
C1/43C7: 20 36 43     JSR $4336
C1/43CA: 7B           TDC 
C1/43CB: 4C 4A 43     JMP $434A
C1/43CE: A2 18 00     LDX #$0018
C1/43D1: 20 95 3F     JSR $3F95
C1/43D4: A9 04        LDA #$04
C1/43D6: 20 56 46     JSR $4656
C1/43D9: A9 06        LDA #$06
C1/43DB: 20 41 46     JSR $4641
C1/43DE: AD 42 CD     LDA $CD42
C1/43E1: AA           TAX 
C1/43E2: BF 80 FF CE  LDA $CEFF80,X
C1/43E6: 85 7A        STA $7A
C1/43E8: 64 70        STZ $70
C1/43EA: BF 84 FF CE  LDA $CEFF84,X
C1/43EE: AA           TAX 
C1/43EF: BD AC 37     LDA $37AC,X
C1/43F2: 1D AD 37     ORA $37AD,X
C1/43F5: D0 04        BNE $43FB
C1/43F7: E6 70        INC $70
C1/43F9: 80 1A        BRA $4415
C1/43FB: BD AC 37     LDA $37AC,X
C1/43FE: D0 09        BNE $4409
C1/4400: BD AD 37     LDA $37AD,X
C1/4403: 10 04        BPL $4409
C1/4405: E6 70        INC $70
C1/4407: 80 0C        BRA $4415
C1/4409: BD AD 37     LDA $37AD,X
C1/440C: D0 07        BNE $4415
C1/440E: BD AC 37     LDA $37AC,X
C1/4411: 10 02        BPL $4415
C1/4413: E6 70        INC $70
C1/4415: A0 0A 00     LDY #$000A
C1/4418: 20 2E 44     JSR $442E
C1/441B: E8           INX 
C1/441C: A0 13 00     LDY #$0013
C1/441F: 20 2E 44     JSR $442E
C1/4422: 20 AC 2D     JSR $2DAC
C1/4425: A9 02        LDA #$02
C1/4427: 20 22 46     JSR $4622
C1/442A: 9C 38 CD     STZ $CD38
C1/442D: 60           RTS 
C1/442E: A9 00        LDA #$00
C1/4430: 09 20        ORA #$20
C1/4432: 99 F7 DB     STA $DBF7,Y
C1/4435: BD AC 37     LDA $37AC,X
C1/4438: D0 03        BNE $443D
C1/443A: 18           CLC 
C1/443B: 65 70        ADC $70
C1/443D: 99 F9 DB     STA $DBF9,Y
C1/4440: BD AE 37     LDA $37AE,X
C1/4443: 99 FC DB     STA $DBFC,Y
C1/4446: BD AC 37     LDA $37AC,X
C1/4449: D0 05        BNE $4450
C1/444B: A9 FF        LDA #$FF
C1/444D: 99 FA DB     STA $DBFA,Y
C1/4450: 60           RTS 

; [  ]

C1/4451: 20 B6 37     JSR $37B6
C1/4454: 20 F1 45     JSR $45F1
C1/4457: 20 A8 3E     JSR $3EA8
C1/445A: A9 06        LDA #$06
C1/445C: 20 56 46     JSR $4656
C1/445F: AD FA CD     LDA $CDFA
C1/4462: AA           TAX 
C1/4463: BF 67 FF CE  LDA $CEFF67,X
C1/4467: 85 72        STA $72
C1/4469: AD 42 CD     LDA $CD42
C1/446C: A8           TAY 
C1/446D: 0A           ASL 
C1/446E: AA           TAX 
C1/446F: B1 D9        LDA ($D9),Y
C1/4471: 0A           ASL 
C1/4472: 18           CLC 
C1/4473: 65 DB        ADC $DB
C1/4475: 85 70        STA $70
C1/4477: 64 71        STZ $71
C1/4479: C2 20        REP #$20
C1/447B: BF 8D FF CE  LDA $CEFF8D,X
C1/447F: 18           CLC 
C1/4480: 65 70        ADC $70
C1/4482: 85 70        STA $70
C1/4484: 7B           TDC 
C1/4485: E2 20        SEP #$20
C1/4487: A6 70        LDX $70
C1/4489: A9 0A        LDA #$0A
C1/448B: 85 74        STA $74
C1/448D: DA           PHX 
C1/448E: A5 72        LDA $72
C1/4490: AA           TAX 
C1/4491: BF 6C FF CE  LDA $CEFF6C,X
C1/4495: A8           TAY 
C1/4496: E6 72        INC $72
C1/4498: FA           PLX 
C1/4499: BD 3C 2F     LDA $2F3C,X
C1/449C: 30 04        BMI $44A2
C1/449E: A9 00        LDA #$00
C1/44A0: 80 02        BRA $44A4
C1/44A2: A9 04        LDA #$04
C1/44A4: 99 F7 DB     STA $DBF7,Y
C1/44A7: BD 34 2D     LDA $2D34,X
C1/44AA: 99 F9 DB     STA $DBF9,Y
C1/44AD: E8           INX 
C1/44AE: E0 82 00     CPX #$0082
C1/44B1: F0 04        BEQ $44B7
C1/44B3: C6 74        DEC $74
C1/44B5: D0 D6        BNE $448D
C1/44B7: A9 05        LDA #$05
C1/44B9: 20 41 46     JSR $4641
C1/44BC: 20 AC 2D     JSR $2DAC
C1/44BF: A9 03        LDA #$03
C1/44C1: 20 22 46     JSR $4622
C1/44C4: 9C 38 CD     STZ $CD38
C1/44C7: 60           RTS 

C1/44C8: 20 B6 37     JSR $37B6
C1/44CB: 20 F1 45     JSR $45F1
C1/44CE: 20 A8 3E     JSR $3EA8
C1/44D1: A9 05        LDA #$05
C1/44D3: 20 56 46     JSR $4656
C1/44D6: AD FA CD     LDA $CDFA
C1/44D9: AA           TAX 
C1/44DA: BF 62 FF CE  LDA $CEFF62,X
C1/44DE: 85 72        STA $72
C1/44E0: AD 42 CD     LDA $CD42
C1/44E3: A8           TAY 
C1/44E4: 0A           ASL 
C1/44E5: AA           TAX 
C1/44E6: B1 D9        LDA ($D9),Y
C1/44E8: 0A           ASL 
C1/44E9: 18           CLC 
C1/44EA: 71 D9        ADC ($D9),Y
C1/44EC: 18           CLC 
C1/44ED: 65 DB        ADC $DB
C1/44EF: 85 70        STA $70
C1/44F1: 64 71        STZ $71
C1/44F3: C2 20        REP #$20
C1/44F5: BF 8D FF CE  LDA $CEFF8D,X
C1/44F9: 18           CLC 
C1/44FA: 65 70        ADC $70
C1/44FC: 85 70        STA $70
C1/44FE: 7B           TDC 
C1/44FF: E2 20        SEP #$20
C1/4501: A6 70        LDX $70
C1/4503: A9 0F        LDA #$0F
C1/4505: 85 74        STA $74
C1/4507: DA           PHX 
C1/4508: A5 72        LDA $72
C1/450A: AA           TAX 
C1/450B: BF 44 FF CE  LDA $CEFF44,X
C1/450F: A8           TAY 
C1/4510: E6 72        INC $72
C1/4512: FA           PLX 
C1/4513: BD 3C 2F     LDA $2F3C,X
C1/4516: 30 04        BMI $451C
C1/4518: A9 00        LDA #$00
C1/451A: 80 02        BRA $451E
C1/451C: A9 04        LDA #$04
C1/451E: 99 F7 DB     STA $DBF7,Y
C1/4521: BD 34 2D     LDA $2D34,X
C1/4524: C9 FF        CMP #$FF
C1/4526: D0 07        BNE $452F
C1/4528: A9 05        LDA #$05
C1/452A: 99 F8 DB     STA $DBF8,Y
C1/452D: A9 06        LDA #$06
C1/452F: C9 57        CMP #$57
C1/4531: 90 01        BCC $4534
C1/4533: 7B           TDC 
C1/4534: 99 F9 DB     STA $DBF9,Y
C1/4537: E8           INX 
C1/4538: E0 82 00     CPX #$0082
C1/453B: F0 04        BEQ $4541
C1/453D: C6 74        DEC $74
C1/453F: D0 C6        BNE $4507
C1/4541: A9 05        LDA #$05
C1/4543: 20 41 46     JSR $4641
C1/4546: 20 AC 2D     JSR $2DAC
C1/4549: A9 03        LDA #$03
C1/454B: 20 22 46     JSR $4622
C1/454E: 9C 38 CD     STZ $CD38
C1/4551: 60           RTS 
C1/4552: 20 F1 45     JSR $45F1
C1/4555: 20 A8 3E     JSR $3EA8
C1/4558: 4C 5E 45     JMP $455E
C1/455B: 20 F1 45     JSR $45F1
C1/455E: A9 03        LDA #$03
C1/4560: 20 56 46     JSR $4656
C1/4563: AD FA CD     LDA $CDFA
C1/4566: AA           TAX 
C1/4567: BF 88 FF CE  LDA $CEFF88,X
C1/456B: 85 70        STA $70
C1/456D: AD 42 CD     LDA $CD42
C1/4570: AA           TAX 
C1/4571: AD 4F DB     LDA $DB4F
C1/4574: F0 04        BEQ $457A
C1/4576: A9 40        LDA #$40
C1/4578: 80 15        BRA $458F
C1/457A: AD 4E DB     LDA $DB4E
C1/457D: F0 0C        BEQ $458B
C1/457F: C9 01        CMP #$01
C1/4581: F0 04        BEQ $4587
C1/4583: A9 02        LDA #$02
C1/4585: 80 08        BRA $458F
C1/4587: A9 10        LDA #$10
C1/4589: 80 04        BRA $458F
C1/458B: BF 80 FF CE  LDA $CEFF80,X
C1/458F: 85 7A        STA $7A
C1/4591: BD 4D 04     LDA $044D,X
C1/4594: 0A           ASL 
C1/4595: AA           TAX 
C1/4596: A9 0A        LDA #$0A
C1/4598: 85 72        STA $72
C1/459A: DA           PHX 
C1/459B: A5 70        LDA $70
C1/459D: AA           TAX 
C1/459E: BF 30 FF CE  LDA $CEFF30,X
C1/45A2: A8           TAY 
C1/45A3: E6 70        INC $70
C1/45A5: FA           PLX 
C1/45A6: AD 4E DB     LDA $DB4E
C1/45A9: 0D 4F DB     ORA $DB4F
C1/45AC: F0 05        BEQ $45B3
C1/45AE: BD 34 2B     LDA $2B34,X
C1/45B1: 80 03        BRA $45B6
C1/45B3: BD 34 2C     LDA $2C34,X
C1/45B6: 25 7A        AND $7A
C1/45B8: F0 04        BEQ $45BE
C1/45BA: A9 04        LDA #$04
C1/45BC: 80 02        BRA $45C0
C1/45BE: A9 00        LDA #$00
C1/45C0: 99 F7 DB     STA $DBF7,Y
C1/45C3: BD 34 28     LDA $2834,X
C1/45C6: 99 FE DB     STA $DBFE,Y
C1/45C9: BD 34 27     LDA $2734,X
C1/45CC: 99 FB DB     STA $DBFB,Y
C1/45CF: D0 05        BNE $45D6
C1/45D1: A9 FF        LDA #$FF
C1/45D3: 99 FC DB     STA $DBFC,Y
C1/45D6: E8           INX 
C1/45D7: E0 00 01     CPX #$0100
C1/45DA: F0 04        BEQ $45E0
C1/45DC: C6 72        DEC $72
C1/45DE: D0 BA        BNE $459A
C1/45E0: A9 05        LDA #$05
C1/45E2: 20 41 46     JSR $4641
C1/45E5: 20 AC 2D     JSR $2DAC
C1/45E8: A9 03        LDA #$03
C1/45EA: 20 22 46     JSR $4622
C1/45ED: 9C 38 CD     STZ $CD38
C1/45F0: 60           RTS 

; [  ]

C1/45F1: A9 04        LDA #$04
C1/45F3: 8D FA CD     STA $CDFA
C1/45F6: 7B           TDC 
C1/45F7: AA           TAX 
C1/45F8: A8           TAY 
C1/45F9: A9 0C        LDA #$0C
C1/45FB: 85 70        STA $70
C1/45FD: BF 52 B9 D4  LDA $D4B952,X
C1/4601: C2 20        REP #$20
C1/4603: 38           SEC 
C1/4604: E9 A4 00     SBC #$00A4
C1/4607: 99 37 BA     STA $BA37,Y
C1/460A: A9 01 00     LDA #$0001
C1/460D: 99 35 BA     STA $BA35,Y
C1/4610: 7B           TDC 
C1/4611: E2 20        SEP #$20
C1/4613: C8           INY 
C1/4614: C8           INY 
C1/4615: C8           INY 
C1/4616: C8           INY 
C1/4617: C6 70        DEC $70
C1/4619: D0 E2        BNE $45FD
C1/461B: E8           INX 
C1/461C: C0 F0 00     CPY #$00F0
C1/461F: D0 D8        BNE $45F9
C1/4621: 60           RTS 

; [  ]

C1/4622: 85 7E        STA $7E
C1/4624: A9 06        LDA #$06
C1/4626: 85 80        STA $80
C1/4628: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/462B: A6 82        LDX $82
C1/462D: 7B           TDC 
C1/462E: A8           TAY 
C1/462F: BF 16 32 D8  LDA $D83216,X
C1/4633: 99 66 BC     STA $BC66,Y
C1/4636: C8           INY 
C1/4637: E8           INX 
C1/4638: C0 06 00     CPY #$0006
C1/463B: D0 F2        BNE $462F
C1/463D: EE 65 BC     INC $BC65
C1/4640: 60           RTS 

; [  ]

C1/4641: 0A           ASL 
C1/4642: 0A           ASL 
C1/4643: 0A           ASL 
C1/4644: AA           TAX 
C1/4645: 7B           TDC 
C1/4646: A8           TAY 
C1/4647: BF 4E 31 D8  LDA $D8314E,X
C1/464B: 99 A0 BC     STA $BCA0,Y
C1/464E: C8           INY 
C1/464F: E8           INX 
C1/4650: C0 06 00     CPY #$0006
C1/4653: D0 F2        BNE $4647
C1/4655: 60           RTS 

; [  ]

C1/4656: 0A           ASL 
C1/4657: AA           TAX 
C1/4658: BF 08 30 D8  LDA $D83008,X
C1/465C: 85 70        STA $70
C1/465E: BF 09 30 D8  LDA $D83009,X
C1/4662: 85 71        STA $71
C1/4664: A9 D8        LDA #$D8
C1/4666: 85 72        STA $72
C1/4668: 7B           TDC 
C1/4669: A8           TAY 
C1/466A: B7 70        LDA [$70],Y
C1/466C: 99 F6 DB     STA $DBF6,Y
C1/466F: C8           INY 
C1/4670: C0 80 00     CPY #$0080
C1/4673: D0 F5        BNE $466A
C1/4675: 60           RTS 

; [ battle command menu $00/$0A: no menu ]

C1/4676: AD 42 CD     LDA $CD42
C1/4679: AA           TAX 
C1/467A: 20 70 52     JSR $5270
C1/467D: B2 88        LDA ($88)
C1/467F: 48           PHA 
C1/4680: A9 09        LDA #$09
C1/4682: 18           CLC 
C1/4683: 6D F7 CD     ADC $CDF7
C1/4686: 85 88        STA $88
C1/4688: 68           PLA 
C1/4689: 4C 0E 51     JMP $510E

; [ battle command menu $0B: ??? ]

C1/468C: 60           RTS 

; [ battle command menu $0D: combine ]

C1/468D: 20 B6 47     JSR $47B6
C1/4690: A9 08        LDA #$08
C1/4692: 8D 91 F8     STA $F891
C1/4695: A9 01        LDA #$01
C1/4697: 8D C3 CF     STA $CFC3
C1/469A: 1A           INC 
C1/469B: 8D 4E DB     STA $DB4E
C1/469E: 60           RTS 

; [ battle command menu $0E: drink ]

C1/469F: 20 B6 47     JSR $47B6
C1/46A2: A9 01        LDA #$01
C1/46A4: 8D C3 CF     STA $CFC3
C1/46A7: 8D 4E DB     STA $DB4E
C1/46AA: 60           RTS 

; [ battle command menu $0F: throw ]

C1/46AB: 20 B6 47     JSR $47B6
C1/46AE: A9 01        LDA #$01
C1/46B0: 8D C3 CF     STA $CFC3
C1/46B3: 8D 4F DB     STA $DB4F
C1/46B6: 60           RTS 

; [ battle command menu $01: spellblade ]

C1/46B7: A9 09        LDA #$09
C1/46B9: 4C FD 46     JMP $46FD

; [ battle command menu $02: white magic ]

C1/46BC: A9 0A        LDA #$0A
C1/46BE: 4C FD 46     JMP $46FD

; [ battle command menu $03: black magic ]

C1/46C1: A9 0B        LDA #$0B
C1/46C3: 4C FD 46     JMP $46FD

; [ battle command menu $04: time magic ]

C1/46C6: A9 0C        LDA #$0C
C1/46C8: 4C FD 46     JMP $46FD

; [ battle command menu $05: summon ]

C1/46CB: A9 0D        LDA #$0D
C1/46CD: 4C FD 46     JMP $46FD

; [ battle command menu $06: blue magic ]

C1/46D0: A9 0E        LDA #$0E
C1/46D2: 4C E9 46     JMP $46E9

; [ battle command menu $09: red magic ]

C1/46D5: A9 0F        LDA #$0F
C1/46D7: 4C E9 46     JMP $46E9

; [ battle command menu $07: song ??? ]

C1/46DA: A9 10        LDA #$10
C1/46DC: 4C FD 46     JMP $46FD

; [ battle command menu $08: x-magic ]

C1/46DF: A9 08        LDA #$08
C1/46E1: 8D 91 F8     STA $F891
C1/46E4: A9 11        LDA #$11
C1/46E6: 4C FD 46     JMP $46FD

; [  ]

C1/46E9: 48           PHA 
C1/46EA: A9 01        LDA #$01
C1/46EC: 85 CF        STA $CF
C1/46EE: A9 03        LDA #$03
C1/46F0: 85 D0        STA $D0
C1/46F2: A9 01        LDA #$01
C1/46F4: 85 D1        STA $D1
C1/46F6: A9 02        LDA #$02
C1/46F8: 85 D2        STA $D2
C1/46FA: 68           PLA 
C1/46FB: 80 0E        BRA $470B

; [  ]

C1/46FD: 48           PHA 
C1/46FE: 64 CF        STZ $CF
C1/4700: 64 D0        STZ $D0
C1/4702: A9 02        LDA #$02
C1/4704: 85 D1        STA $D1
C1/4706: A9 03        LDA #$03
C1/4708: 85 D2        STA $D2
C1/470A: 68           PLA 
C1/470B: 8D 39 CD     STA $CD39       ; menu id ???
C1/470E: 9C C3 CF     STZ $CFC3
C1/4711: A9 04        LDA #$04
C1/4713: 8D FA CD     STA $CDFA
C1/4716: A9 04        LDA #$04
C1/4718: 20 6A 49     JSR $496A
C1/471B: A9 05        LDA #$05
C1/471D: 8D 3A CD     STA $CD3A
C1/4720: A9 01        LDA #$01
C1/4722: 8D 3B CD     STA $CD3B
C1/4725: A9 0C        LDA #$0C
C1/4727: 8D 3C CD     STA $CD3C
C1/472A: A9 20        LDA #$20
C1/472C: 20 18 53     JSR $5318
C1/472F: 20 EF 47     JSR $47EF
C1/4732: 4C 94 54     JMP $5494

; [  ]

C1/4735: 9C 6C CD     STZ $CD6C
C1/4738: 9C 70 CD     STZ $CD70
C1/473B: A9 05        LDA #$05
C1/473D: 20 6A 49     JSR $496A
C1/4740: A9 07        LDA #$07
C1/4742: 8D 39 CD     STA $CD39
C1/4745: A9 05        LDA #$05
C1/4747: 8D 3A CD     STA $CD3A
C1/474A: A9 02        LDA #$02
C1/474C: 8D 3B CD     STA $CD3B
C1/474F: A9 09        LDA #$09
C1/4751: 18           CLC 
C1/4752: 6D F7 CD     ADC $CDF7
C1/4755: 8D 3C CD     STA $CD3C
C1/4758: 60           RTS 

; [  ]

C1/4759: A9 12        LDA #$12
C1/475B: 8D 39 CD     STA $CD39
C1/475E: A9 0A        LDA #$0A
C1/4760: 20 6A 49     JSR $496A
C1/4763: A9 05        LDA #$05
C1/4765: 8D 3A CD     STA $CD3A
C1/4768: A9 01        LDA #$01
C1/476A: 8D 3B CD     STA $CD3B
C1/476D: A9 0B        LDA #$0B
C1/476F: 8D 3C CD     STA $CD3C
C1/4772: 60           RTS 

; [  ]

C1/4773: 9C 6C CD     STZ $CD6C
C1/4776: 9C 70 CD     STZ $CD70
C1/4779: A9 0B        LDA #$0B
C1/477B: 20 6A 49     JSR $496A
C1/477E: A9 02        LDA #$02
C1/4780: 8D 3A CD     STA $CD3A
C1/4783: A9 0D        LDA #$0D
C1/4785: 8D 3B CD     STA $CD3B
C1/4788: 60           RTS 

; [  ]

C1/4789: A9 06        LDA #$06
C1/478B: 20 6A 49     JSR $496A
C1/478E: A9 04        LDA #$04
C1/4790: 8D 39 CD     STA $CD39
C1/4793: A9 05        LDA #$05
C1/4795: 8D 3A CD     STA $CD3A
C1/4798: A9 01        LDA #$01
C1/479A: 8D 3B CD     STA $CD3B
C1/479D: A9 08        LDA #$08
C1/479F: 8D 3C CD     STA $CD3C
C1/47A2: 60           RTS 

; [  ]

C1/47A3: A9 07        LDA #$07
C1/47A5: 20 6A 49     JSR $496A
C1/47A8: A9 02        LDA #$02
C1/47AA: 8D 3A CD     STA $CD3A
C1/47AD: A9 07        LDA #$07
C1/47AF: 8D 3B CD     STA $CD3B
C1/47B2: 9C 50 CD     STZ $CD50
C1/47B5: 60           RTS 

; [ battle command menu $0C: item ]

C1/47B6: 9C C3 CF     STZ $CFC3
C1/47B9: 9C 4E DB     STZ $DB4E
C1/47BC: 9C 4F DB     STZ $DB4F
C1/47BF: A9 04        LDA #$04
C1/47C1: 8D FA CD     STA $CDFA
C1/47C4: A9 04        LDA #$04
C1/47C6: 20 6A 49     JSR $496A
C1/47C9: A9 08        LDA #$08
C1/47CB: 8D 39 CD     STA $CD39
C1/47CE: A9 05        LDA #$05
C1/47D0: 8D 3A CD     STA $CD3A
C1/47D3: A9 01        LDA #$01
C1/47D5: 8D 3B CD     STA $CD3B
C1/47D8: A9 07        LDA #$07
C1/47DA: 8D 3C CD     STA $CD3C
C1/47DD: 20 EF 47     JSR $47EF
C1/47E0: 9C 91 F8     STZ $F891
C1/47E3: 9C 8C F8     STZ $F88C
C1/47E6: 9C 8E F8     STZ $F88E
C1/47E9: 9C 3B CF     STZ $CF3B
C1/47EC: 4C 94 54     JMP $5494

; [  ]

C1/47EF: 7B           TDC 
C1/47F0: AA           TAX 
C1/47F1: BD F1 C5     LDA $C5F1,X
C1/47F4: 9D 77 CD     STA $CD77,X
C1/47F7: E8           INX 
C1/47F8: E0 80 00     CPX #$0080
C1/47FB: D0 F4        BNE $47F1
C1/47FD: 60           RTS 

; [  ]

C1/47FE: A9 05        LDA #$05
C1/4800: 20 6A 49     JSR $496A
C1/4803: A9 06        LDA #$06
C1/4805: 18           CLC 
C1/4806: 6D F7 CD     ADC $CDF7
C1/4809: 8D 39 CD     STA $CD39
C1/480C: A9 05        LDA #$05
C1/480E: 8D 3A CD     STA $CD3A
C1/4811: A9 02        LDA #$02
C1/4813: 8D 3B CD     STA $CD3B
C1/4816: A9 09        LDA #$09
C1/4818: 18           CLC 
C1/4819: 6D F7 CD     ADC $CDF7
C1/481C: 8D 3C CD     STA $CD3C
C1/481F: 9C C3 CF     STZ $CFC3
C1/4822: 9C F7 CD     STZ $CDF7
C1/4825: 9C 3B CF     STZ $CF3B
C1/4828: 9C 4C CD     STZ $CD4C
C1/482B: 9C 48 CD     STZ $CD48
C1/482E: 9C 8C F8     STZ $F88C
C1/4831: 9C 8E F8     STZ $F88E
C1/4834: 9C 6C CD     STZ $CD6C
C1/4837: 9C 70 CD     STZ $CD70
C1/483A: 60           RTS 

; [  ]

C1/483B: A9 09        LDA #$09
C1/483D: 8D 83 BC     STA $BC83
C1/4840: A9 0E        LDA #$0E
C1/4842: 20 6A 49     JSR $496A
C1/4845: A9 1D        LDA #$1D
C1/4847: 8D 39 CD     STA $CD39
C1/484A: A9 05        LDA #$05
C1/484C: 8D 3A CD     STA $CD3A
C1/484F: A9 01        LDA #$01
C1/4851: 8D 3B CD     STA $CD3B
C1/4854: A9 12        LDA #$12
C1/4856: 8D 3C CD     STA $CD3C
C1/4859: 4C 94 54     JMP $5494

; [  ]

C1/485C: 48           PHA 
C1/485D: A9 0F        LDA #$0F
C1/485F: 20 6A 49     JSR $496A
C1/4862: A9 02        LDA #$02
C1/4864: 8D 3A CD     STA $CD3A
C1/4867: 68           PLA 
C1/4868: 8D 3B CD     STA $CD3B
C1/486B: 4C 94 54     JMP $5494

; [  ]

C1/486E: AD 42 CD     LDA $CD42
C1/4871: 0A           ASL 
C1/4872: 0A           ASL 
C1/4873: 0A           ASL 
C1/4874: 0A           ASL 
C1/4875: 0A           ASL 
C1/4876: AA           TAX 
C1/4877: 9E 58 CF     STZ $CF58,X
C1/487A: BD 56 CF     LDA $CF56,X
C1/487D: 29 FE        AND #$FE
C1/487F: 9D 56 CF     STA $CF56,X
C1/4882: A9 02        LDA #$02
C1/4884: 20 6A 49     JSR $496A
C1/4887: A9 02        LDA #$02
C1/4889: 8D 39 CD     STA $CD39
C1/488C: A9 05        LDA #$05
C1/488E: 8D 3A CD     STA $CD3A
C1/4891: A9 01        LDA #$01
C1/4893: 8D 3B CD     STA $CD3B
C1/4896: A9 06        LDA #$06
C1/4898: 8D 3C CD     STA $CD3C
C1/489B: 9C D2 CF     STZ $CFD2
C1/489E: 9C C3 CF     STZ $CFC3
C1/48A1: 60           RTS 

; [  ]

C1/48A2: A9 03        LDA #$03
C1/48A4: 20 6A 49     JSR $496A
C1/48A7: A9 01        LDA #$01
C1/48A9: 8D 39 CD     STA $CD39
C1/48AC: A9 05        LDA #$05
C1/48AE: 8D 3A CD     STA $CD3A
C1/48B1: A9 02        LDA #$02
C1/48B3: 8D 3B CD     STA $CD3B
C1/48B6: A9 0E        LDA #$0E
C1/48B8: 8D 3C CD     STA $CD3C
C1/48BB: AD F9 CD     LDA $CDF9
C1/48BE: D0 36        BNE $48F6
C1/48C0: AD 42 CD     LDA $CD42
C1/48C3: 0A           ASL 
C1/48C4: 0A           ASL 
C1/48C5: 0A           ASL 
C1/48C6: 0A           ASL 
C1/48C7: 0A           ASL 
C1/48C8: AA           TAX 
C1/48C9: AD B1 41     LDA $41B1
C1/48CC: 30 0C        BMI $48DA
C1/48CE: 29 20        AND #$20
C1/48D0: F0 04        BEQ $48D6
C1/48D2: A9 09        LDA #$09
C1/48D4: 80 15        BRA $48EB
C1/48D6: A9 01        LDA #$01
C1/48D8: 80 11        BRA $48EB
C1/48DA: BD 4D CF     LDA $CF4D,X
C1/48DD: C9 03        CMP #$03
C1/48DF: F0 0A        BEQ $48EB
C1/48E1: DA           PHX 
C1/48E2: AD B6 41     LDA $41B6
C1/48E5: AA           TAX 
C1/48E6: BF 66 33 D8  LDA $D83366,X
C1/48EA: FA           PLX 
C1/48EB: 9D 58 CF     STA $CF58,X
C1/48EE: BD 56 CF     LDA $CF56,X
C1/48F1: 09 01        ORA #$01
C1/48F3: 9D 56 CF     STA $CF56,X
C1/48F6: 60           RTS 
C1/48F7: AD 26 04     LDA $0426
C1/48FA: 10 03        BPL $48FF
C1/48FC: 7B           TDC 
C1/48FD: 80 08        BRA $4907
C1/48FF: AD 42 CD     LDA $CD42
C1/4902: AA           TAX 
C1/4903: BD 2D 04     LDA $042D,X
C1/4906: 0A           ASL 
C1/4907: AA           TAX 
C1/4908: C2 20        REP #$20
C1/490A: BF 5E 33 D8  LDA $D8335E,X
C1/490E: 85 88        STA $88
C1/4910: AD 33 CD     LDA $CD33
C1/4913: 18           CLC 
C1/4914: 65 88        ADC $88
C1/4916: 8D 33 CD     STA $CD33
C1/4919: 7B           TDC 
C1/491A: E2 20        SEP #$20
C1/491C: 60           RTS 
C1/491D: A9 0D        LDA #$0D
C1/491F: 20 6A 49     JSR $496A
C1/4922: 20 F7 48     JSR $48F7
C1/4925: A9 02        LDA #$02
C1/4927: 8D 3A CD     STA $CD3A
C1/492A: A9 06        LDA #$06
C1/492C: 8D 3B CD     STA $CD3B
C1/492F: 60           RTS 
C1/4930: A9 0C        LDA #$0C
C1/4932: 20 6A 49     JSR $496A
C1/4935: 20 F7 48     JSR $48F7
C1/4938: A9 14        LDA #$14
C1/493A: 8D 39 CD     STA $CD39
C1/493D: A9 05        LDA #$05
C1/493F: 8D 3A CD     STA $CD3A
C1/4942: A9 01        LDA #$01
C1/4944: 8D 3B CD     STA $CD3B
C1/4947: A9 10        LDA #$10
C1/4949: 8D 3C CD     STA $CD3C
C1/494C: 60           RTS 
C1/494D: A9 0C        LDA #$0C
C1/494F: 20 6A 49     JSR $496A
C1/4952: 20 F7 48     JSR $48F7
C1/4955: A9 13        LDA #$13
C1/4957: 8D 39 CD     STA $CD39
C1/495A: A9 05        LDA #$05
C1/495C: 8D 3A CD     STA $CD3A
C1/495F: A9 01        LDA #$01
C1/4961: 8D 3B CD     STA $CD3B
C1/4964: A9 0F        LDA #$0F
C1/4966: 8D 3C CD     STA $CD3C
C1/4969: 60           RTS 
C1/496A: 85 98        STA $98
C1/496C: A9 05        LDA #$05
C1/496E: 85 9A        STA $9A
C1/4970: 20 4B FE     JSR $FE4B
C1/4973: A6 9C        LDX $9C
C1/4975: 7B           TDC 
C1/4976: A8           TAY 
C1/4977: BF 92 33 D8  LDA $D83392,X
C1/497B: 99 31 CD     STA $CD31,Y
C1/497E: E8           INX 
C1/497F: C8           INY 
C1/4980: C0 05 00     CPY #$0005
C1/4983: D0 F2        BNE $4977
C1/4985: 60           RTS 

C1/4986: AE 31 CD     LDX $CD31
C1/4989: 86 88        STX $88
C1/498B: AE 33 CD     LDX $CD33
C1/498E: 86 8A        STX $8A
C1/4990: 7B           TDC 
C1/4991: A8           TAY 
C1/4992: B1 88        LDA ($88),Y
C1/4994: 85 8C        STA $8C
C1/4996: B1 8A        LDA ($8A),Y
C1/4998: 91 88        STA ($88),Y
C1/499A: A5 8C        LDA $8C
C1/499C: 91 8A        STA ($8A),Y
C1/499E: C8           INY 
C1/499F: C0 20 00     CPY #$0020
C1/49A2: D0 EE        BNE $4992
C1/49A4: C2 20        REP #$20
C1/49A6: A5 88        LDA $88
C1/49A8: 18           CLC 
C1/49A9: 69 20 00     ADC #$0020
C1/49AC: 8D 31 CD     STA $CD31
C1/49AF: A5 8A        LDA $8A
C1/49B1: 18           CLC 
C1/49B2: 69 20 00     ADC #$0020
C1/49B5: 8D 33 CD     STA $CD33
C1/49B8: 7B           TDC 
C1/49B9: E2 20        SEP #$20
C1/49BB: CE 35 CD     DEC $CD35
C1/49BE: D0 03        BNE $49C3
C1/49C0: 20 07 FD     JSR $FD07
C1/49C3: 60           RTS 
C1/49C4: AE 31 CD     LDX $CD31
C1/49C7: 86 88        STX $88
C1/49C9: AE 33 CD     LDX $CD33
C1/49CC: 86 8A        STX $8A
C1/49CE: 7B           TDC 
C1/49CF: A8           TAY 
C1/49D0: B1 88        LDA ($88),Y
C1/49D2: 48           PHA 
C1/49D3: B1 8A        LDA ($8A),Y
C1/49D5: 91 88        STA ($88),Y
C1/49D7: 68           PLA 
C1/49D8: 91 8A        STA ($8A),Y
C1/49DA: C8           INY 
C1/49DB: C0 20 00     CPY #$0020
C1/49DE: D0 F0        BNE $49D0
C1/49E0: C2 20        REP #$20
C1/49E2: A5 88        LDA $88
C1/49E4: 38           SEC 
C1/49E5: E9 20 00     SBC #$0020
C1/49E8: 8D 31 CD     STA $CD31
C1/49EB: A5 8A        LDA $8A
C1/49ED: 38           SEC 
C1/49EE: E9 20 00     SBC #$0020
C1/49F1: 8D 33 CD     STA $CD33
C1/49F4: 7B           TDC 
C1/49F5: E2 20        SEP #$20
C1/49F7: CE 35 CD     DEC $CD35
C1/49FA: D0 08        BNE $4A04
C1/49FC: 20 07 FD     JSR $FD07
C1/49FF: A9 01        LDA #$01
C1/4A01: 8D 83 BC     STA $BC83
C1/4A04: 60           RTS 
C1/4A05: AD 76 BC     LDA $BC76
C1/4A08: F0 44        BEQ $4A4E
C1/4A0A: A2 00 01     LDX #$0100
C1/4A0D: 86 88        STX $88
C1/4A0F: A2 B1 C9     LDX #$C9B1
C1/4A12: A9 7E        LDA #$7E
C1/4A14: A0 20 48     LDY #$4820
C1/4A17: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/4A1A: 9C 76 BC     STZ $BC76
C1/4A1D: C2 20        REP #$20
C1/4A1F: A9 80 40     LDA #$4080
C1/4A22: 8F 16 21 00  STA $002116
C1/4A26: A9 57 F3     LDA #$F357
C1/4A29: 8F 42 43 00  STA $004342
C1/4A2D: A9 A0 01     LDA #$01A0
C1/4A30: 8F 45 43 00  STA $004345
C1/4A34: 7B           TDC 
C1/4A35: E2 20        SEP #$20
C1/4A37: A9 7E        LDA #$7E
C1/4A39: 8F 44 43 00  STA $004344
C1/4A3D: 7B           TDC 
C1/4A3E: 8F 40 43 00  STA $004340
C1/4A42: A9 19        LDA #$19
C1/4A44: 8F 41 43 00  STA $004341
C1/4A48: A9 10        LDA #$10
C1/4A4A: 8F 0B 42 00  STA $00420B
C1/4A4E: 60           RTS 
C1/4A4F: AD 74 CD     LDA $CD74
C1/4A52: F0 13        BEQ $4A67
C1/4A54: A2 80 00     LDX #$0080
C1/4A57: 86 88        STX $88
C1/4A59: AC 75 CD     LDY $CD75
C1/4A5C: A2 77 CD     LDX #$CD77
C1/4A5F: A9 7E        LDA #$7E
C1/4A61: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/4A64: 9C 74 CD     STZ $CD74
C1/4A67: 60           RTS 
C1/4A68: AD D3 DB     LDA $DBD3
C1/4A6B: D0 18        BNE $4A85
C1/4A6D: AD 65 BC     LDA $BC65
C1/4A70: F0 13        BEQ $4A85
C1/4A72: AE 66 BC     LDX $BC66
C1/4A75: 86 88        STX $88
C1/4A77: AC 68 BC     LDY $BC68
C1/4A7A: AE 6A BC     LDX $BC6A
C1/4A7D: A9 7E        LDA #$7E
C1/4A7F: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/4A82: 9C 65 BC     STZ $BC65
C1/4A85: 60           RTS 
C1/4A86: 7B           TDC 
C1/4A87: AA           TAX 
C1/4A88: C2 20        REP #$20
C1/4A8A: BD 37 BA     LDA $BA37,X
C1/4A8D: 85 88        STA $88
C1/4A8F: BD 3B BA     LDA $BA3B,X
C1/4A92: 85 8A        STA $8A
C1/4A94: BD 3F BA     LDA $BA3F,X
C1/4A97: 85 8C        STA $8C
C1/4A99: BD 43 BA     LDA $BA43,X
C1/4A9C: 85 8E        STA $8E
C1/4A9E: BD 47 BA     LDA $BA47,X
C1/4AA1: 18           CLC 
C1/4AA2: 69 04 00     ADC #$0004
C1/4AA5: 9D 37 BA     STA $BA37,X
C1/4AA8: BD 4B BA     LDA $BA4B,X
C1/4AAB: 18           CLC 
C1/4AAC: 69 04 00     ADC #$0004
C1/4AAF: 9D 3B BA     STA $BA3B,X
C1/4AB2: BD 4F BA     LDA $BA4F,X
C1/4AB5: 18           CLC 
C1/4AB6: 69 04 00     ADC #$0004
C1/4AB9: 9D 3F BA     STA $BA3F,X
C1/4ABC: BD 53 BA     LDA $BA53,X
C1/4ABF: 18           CLC 
C1/4AC0: 69 04 00     ADC #$0004
C1/4AC3: 9D 43 BA     STA $BA43,X
C1/4AC6: 8A           TXA 
C1/4AC7: 18           CLC 
C1/4AC8: 69 10 00     ADC #$0010
C1/4ACB: AA           TAX 
C1/4ACC: E0 E0 00     CPX #$00E0
C1/4ACF: D0 CD        BNE $4A9E
C1/4AD1: A5 8E        LDA $8E
C1/4AD3: 38           SEC 
C1/4AD4: E9 38 00     SBC #$0038
C1/4AD7: 9D 43 BA     STA $BA43,X
C1/4ADA: A5 8C        LDA $8C
C1/4ADC: 38           SEC 
C1/4ADD: E9 38 00     SBC #$0038
C1/4AE0: 9D 3F BA     STA $BA3F,X
C1/4AE3: A5 8A        LDA $8A
C1/4AE5: 38           SEC 
C1/4AE6: E9 38 00     SBC #$0038
C1/4AE9: 9D 3B BA     STA $BA3B,X
C1/4AEC: A5 88        LDA $88
C1/4AEE: 38           SEC 
C1/4AEF: E9 38 00     SBC #$0038
C1/4AF2: 9D 37 BA     STA $BA37,X
C1/4AF5: 7B           TDC 
C1/4AF6: AA           TAX 
C1/4AF7: BD 37 BA     LDA $BA37,X
C1/4AFA: 9D D5 B2     STA $B2D5,X
C1/4AFD: E8           INX 
C1/4AFE: E8           INX 
C1/4AFF: E8           INX 
C1/4B00: E8           INX 
C1/4B01: E0 C0 00     CPX #$00C0
C1/4B04: D0 F1        BNE $4AF7
C1/4B06: AD 3E CF     LDA $CF3E
C1/4B09: 38           SEC 
C1/4B0A: E9 04 00     SBC #$0004
C1/4B0D: 8D 3E CF     STA $CF3E
C1/4B10: 7B           TDC 
C1/4B11: E2 20        SEP #$20
C1/4B13: 20 BC 4B     JSR $4BBC
C1/4B16: CE 37 CD     DEC $CD37
C1/4B19: D0 06        BNE $4B21
C1/4B1B: 20 07 FD     JSR $FD07
C1/4B1E: 20 86 11     JSR $1186
C1/4B21: 60           RTS 
C1/4B22: A2 E0 00     LDX #$00E0
C1/4B25: C2 20        REP #$20
C1/4B27: BD 37 BA     LDA $BA37,X
C1/4B2A: 85 88        STA $88
C1/4B2C: BD 3B BA     LDA $BA3B,X
C1/4B2F: 85 8A        STA $8A
C1/4B31: BD 3F BA     LDA $BA3F,X
C1/4B34: 85 8C        STA $8C
C1/4B36: BD 43 BA     LDA $BA43,X
C1/4B39: 85 8E        STA $8E
C1/4B3B: BD 33 BA     LDA $BA33,X
C1/4B3E: 38           SEC 
C1/4B3F: E9 04 00     SBC #$0004
C1/4B42: 9D 43 BA     STA $BA43,X
C1/4B45: BD 2F BA     LDA $BA2F,X
C1/4B48: 38           SEC 
C1/4B49: E9 04 00     SBC #$0004
C1/4B4C: 9D 3F BA     STA $BA3F,X
C1/4B4F: BD 2B BA     LDA $BA2B,X
C1/4B52: 38           SEC 
C1/4B53: E9 04 00     SBC #$0004
C1/4B56: 9D 3B BA     STA $BA3B,X
C1/4B59: BD 27 BA     LDA $BA27,X
C1/4B5C: 38           SEC 
C1/4B5D: E9 04 00     SBC #$0004
C1/4B60: 9D 37 BA     STA $BA37,X
C1/4B63: 8A           TXA 
C1/4B64: 38           SEC 
C1/4B65: E9 10 00     SBC #$0010
C1/4B68: AA           TAX 
C1/4B69: D0 D0        BNE $4B3B
C1/4B6B: A5 8E        LDA $8E
C1/4B6D: 18           CLC 
C1/4B6E: 69 38 00     ADC #$0038
C1/4B71: 9D 43 BA     STA $BA43,X
C1/4B74: A5 8C        LDA $8C
C1/4B76: 18           CLC 
C1/4B77: 69 38 00     ADC #$0038
C1/4B7A: 9D 3F BA     STA $BA3F,X
C1/4B7D: A5 8A        LDA $8A
C1/4B7F: 18           CLC 
C1/4B80: 69 38 00     ADC #$0038
C1/4B83: 9D 3B BA     STA $BA3B,X
C1/4B86: A5 88        LDA $88
C1/4B88: 18           CLC 
C1/4B89: 69 38 00     ADC #$0038
C1/4B8C: 9D 37 BA     STA $BA37,X
C1/4B8F: 7B           TDC 
C1/4B90: AA           TAX 
C1/4B91: BD 37 BA     LDA $BA37,X
C1/4B94: 9D D5 B2     STA $B2D5,X
C1/4B97: E8           INX 
C1/4B98: E8           INX 
C1/4B99: E8           INX 
C1/4B9A: E8           INX 
C1/4B9B: E0 C0 00     CPX #$00C0
C1/4B9E: D0 F1        BNE $4B91
C1/4BA0: AD 3E CF     LDA $CF3E
C1/4BA3: 18           CLC 
C1/4BA4: 69 04 00     ADC #$0004
C1/4BA7: 8D 3E CF     STA $CF3E
C1/4BAA: 7B           TDC 
C1/4BAB: E2 20        SEP #$20
C1/4BAD: 20 BC 4B     JSR $4BBC
C1/4BB0: CE 37 CD     DEC $CD37
C1/4BB3: D0 06        BNE $4BBB
C1/4BB5: 20 07 FD     JSR $FD07
C1/4BB8: 20 86 11     JSR $1186
C1/4BBB: 60           RTS 
C1/4BBC: 9C 4C CD     STZ $CD4C
C1/4BBF: AD 3B CF     LDA $CF3B
C1/4BC2: F0 24        BEQ $4BE8
C1/4BC4: C2 20        REP #$20
C1/4BC6: AD 3E CF     LDA $CF3E
C1/4BC9: C9 A8 00     CMP #$00A8
C1/4BCC: 90 17        BCC $4BE5
C1/4BCE: C9 D0 00     CMP #$00D0
C1/4BD1: B0 12        BCS $4BE5
C1/4BD3: 7B           TDC 
C1/4BD4: E2 20        SEP #$20
C1/4BD6: AD 3C CF     LDA $CF3C
C1/4BD9: 8D 4D CD     STA $CD4D
C1/4BDC: AD 3E CF     LDA $CF3E
C1/4BDF: 8D 4E CD     STA $CD4E
C1/4BE2: EE 4C CD     INC $CD4C
C1/4BE5: 7B           TDC 
C1/4BE6: E2 20        SEP #$20
C1/4BE8: 60           RTS 
C1/4BE9: 9C 58 CD     STZ $CD58
C1/4BEC: 9C 5C CD     STZ $CD5C
C1/4BEF: 9C 60 CD     STZ $CD60
C1/4BF2: 9C 64 CD     STZ $CD64
C1/4BF5: 60           RTS 
C1/4BF6: AA           TAX 
C1/4BF7: 7B           TDC 
C1/4BF8: A8           TAY 
C1/4BF9: 06 88        ASL $88
C1/4BFB: 90 15        BCC $4C12
C1/4BFD: BD 4E D0     LDA $D04E,X
C1/4C00: 18           CLC 
C1/4C01: 7D 96 D0     ADC $D096,X
C1/4C04: 99 59 CD     STA $CD59,Y
C1/4C07: BD 5A D0     LDA $D05A,X
C1/4C0A: 99 5A CD     STA $CD5A,Y
C1/4C0D: A9 01        LDA #$01
C1/4C0F: 99 58 CD     STA $CD58,Y
C1/4C12: E8           INX 
C1/4C13: C8           INY 
C1/4C14: C8           INY 
C1/4C15: C8           INY 
C1/4C16: C8           INY 
C1/4C17: C0 10 00     CPY #$0010
C1/4C1A: D0 DD        BNE $4BF9
C1/4C1C: 60           RTS 
C1/4C1D: 20 E9 4B     JSR $4BE9
C1/4C20: AD C5 D0     LDA $D0C5
C1/4C23: F0 34        BEQ $4C59
C1/4C25: C9 01        CMP #$01
C1/4C27: F0 0F        BEQ $4C38
C1/4C29: A5 A2        LDA $A2
C1/4C2B: 29 01        AND #$01
C1/4C2D: D0 43        BNE $4C72
C1/4C2F: A5 DF        LDA $DF
C1/4C31: 85 88        STA $88
C1/4C33: A9 08        LDA #$08
C1/4C35: 4C F6 4B     JMP $4BF6
C1/4C38: A5 A2        LDA $A2
C1/4C3A: 29 01        AND #$01
C1/4C3C: F0 0B        BEQ $4C49
C1/4C3E: A5 DE        LDA $DE
C1/4C40: 2D E1 DB     AND $DBE1
C1/4C43: 85 88        STA $88
C1/4C45: 7B           TDC 
C1/4C46: 4C F6 4B     JMP $4BF6
C1/4C49: A5 DE        LDA $DE
C1/4C4B: 2D E1 DB     AND $DBE1
C1/4C4E: 0A           ASL 
C1/4C4F: 0A           ASL 
C1/4C50: 0A           ASL 
C1/4C51: 0A           ASL 
C1/4C52: 85 88        STA $88
C1/4C54: A9 04        LDA #$04
C1/4C56: 4C F6 4B     JMP $4BF6
C1/4C59: AD C4 D0     LDA $D0C4
C1/4C5C: AA           TAX 
C1/4C5D: BD 4E D0     LDA $D04E,X
C1/4C60: 18           CLC 
C1/4C61: 7D 96 D0     ADC $D096,X
C1/4C64: 8D 59 CD     STA $CD59
C1/4C67: BD 5A D0     LDA $D05A,X
C1/4C6A: 8D 5A CD     STA $CD5A
C1/4C6D: A9 01        LDA #$01
C1/4C6F: 8D 58 CD     STA $CD58
C1/4C72: 60           RTS 
C1/4C73: 20 96 FC     JSR $FC96       ; generate random number
C1/4C76: 29 0F        AND #$0F
C1/4C78: 85 88        STA $88
C1/4C7A: 0A           ASL 
C1/4C7B: AA           TAX 
C1/4C7C: C2 20        REP #$20
C1/4C7E: A5 DE        LDA $DE
C1/4C80: 2D E1 DB     AND $DBE1
C1/4C83: 3F D5 FF CE  AND $CEFFD5,X
C1/4C87: D0 05        BNE $4C8E
C1/4C89: 7B           TDC 
C1/4C8A: E2 20        SEP #$20
C1/4C8C: 80 E5        BRA $4C73
C1/4C8E: 7B           TDC 
C1/4C8F: E2 20        SEP #$20
C1/4C91: A5 88        LDA $88
C1/4C93: 8D C4 D0     STA $D0C4
C1/4C96: 60           RTS 
C1/4C97: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/4C9A: AD C4 D0     LDA $D0C4
C1/4C9D: 85 88        STA $88
C1/4C9F: E6 88        INC $88
C1/4CA1: A5 88        LDA $88
C1/4CA3: 29 0F        AND #$0F
C1/4CA5: 85 88        STA $88
C1/4CA7: 0A           ASL 
C1/4CA8: AA           TAX 
C1/4CA9: C2 20        REP #$20
C1/4CAB: A5 DE        LDA $DE
C1/4CAD: 2D E1 DB     AND $DBE1
C1/4CB0: 3F D5 FF CE  AND $CEFFD5,X
C1/4CB4: D0 05        BNE $4CBB
C1/4CB6: 7B           TDC 
C1/4CB7: E2 20        SEP #$20
C1/4CB9: 80 E4        BRA $4C9F
C1/4CBB: 7B           TDC 
C1/4CBC: E2 20        SEP #$20
C1/4CBE: A5 88        LDA $88
C1/4CC0: 8D C4 D0     STA $D0C4
C1/4CC3: 60           RTS 
C1/4CC4: AD C5 D0     LDA $D0C5
C1/4CC7: F0 15        BEQ $4CDE
C1/4CC9: C9 01        CMP #$01
C1/4CCB: F0 07        BEQ $4CD4
C1/4CCD: 64 88        STZ $88
C1/4CCF: A5 DF        LDA $DF
C1/4CD1: 85 89        STA $89
C1/4CD3: 60           RTS 
C1/4CD4: 64 89        STZ $89
C1/4CD6: A5 DE        LDA $DE
C1/4CD8: 2D E1 DB     AND $DBE1
C1/4CDB: 85 88        STA $88
C1/4CDD: 60           RTS 
C1/4CDE: AD C4 D0     LDA $D0C4
C1/4CE1: 0A           ASL 
C1/4CE2: C2 20        REP #$20
C1/4CE4: AA           TAX 
C1/4CE5: BF D5 FF CE  LDA $CEFFD5,X
C1/4CE9: 85 88        STA $88
C1/4CEB: 7B           TDC 
C1/4CEC: E2 20        SEP #$20
C1/4CEE: 60           RTS 
C1/4CEF: AD 47 DB     LDA $DB47
C1/4CF2: D0 1E        BNE $4D12
C1/4CF4: AD 48 DB     LDA $DB48
C1/4CF7: 29 02        AND #$02
C1/4CF9: F0 05        BEQ $4D00
C1/4CFB: 20 E9 4B     JSR $4BE9
C1/4CFE: 80 03        BRA $4D03
C1/4D00: 20 1D 4C     JSR $4C1D
C1/4D03: CE 48 DB     DEC $DB48
C1/4D06: D0 09        BNE $4D11
C1/4D08: 20 3C 4D     JSR $4D3C
C1/4D0B: 20 E9 4B     JSR $4BE9
C1/4D0E: 20 28 4D     JSR $4D28
C1/4D11: 60           RTS 
C1/4D12: CE 47 DB     DEC $DB47
C1/4D15: D0 05        BNE $4D1C
C1/4D17: A9 10        LDA #$10
C1/4D19: 8D 48 DB     STA $DB48
C1/4D1C: A5 A2        LDA $A2
C1/4D1E: 29 0F        AND #$0F
C1/4D20: D0 03        BNE $4D25
C1/4D22: 20 97 4C     JSR $4C97
C1/4D25: 4C 1D 4C     JMP $4C1D
C1/4D28: AD C2 D0     LDA $D0C2
C1/4D2B: 29 08        AND #$08
C1/4D2D: D0 06        BNE $4D35
C1/4D2F: AD C3 D0     LDA $D0C3
C1/4D32: 4C 5C 48     JMP $485C
C1/4D35: AD C3 D0     LDA $D0C3
C1/4D38: 8D 3A CD     STA $CD3A
C1/4D3B: 60           RTS 
C1/4D3C: 20 C4 4C     JSR $4CC4
C1/4D3F: AD 90 F8     LDA $F890
C1/4D42: AA           TAX 
C1/4D43: A5 88        LDA $88
C1/4D45: 9D B4 41     STA $41B4,X
C1/4D48: A5 89        LDA $89
C1/4D4A: 9D B5 41     STA $41B5,X
C1/4D4D: AD C2 D0     LDA $D0C2
C1/4D50: 29 04        AND #$04
C1/4D52: D0 03        BNE $4D57
C1/4D54: 20 E9 4B     JSR $4BE9
C1/4D57: AD 4E DB     LDA $DB4E
C1/4D5A: C9 02        CMP #$02
C1/4D5C: D0 0B        BNE $4D69
C1/4D5E: AD B2 41     LDA $41B2
C1/4D61: 8D B9 41     STA $41B9
C1/4D64: A6 88        LDX $88
C1/4D66: 8E B4 41     STX $41B4
C1/4D69: AD 91 F8     LDA $F891
C1/4D6C: F0 0B        BEQ $4D79
C1/4D6E: AD 90 F8     LDA $F890
C1/4D71: D0 06        BNE $4D79
C1/4D73: A9 07        LDA #$07
C1/4D75: 8D 90 F8     STA $F890
C1/4D78: 60           RTS 
C1/4D79: 9C 90 F8     STZ $F890
C1/4D7C: EE F8 CD     INC $CDF8
C1/4D7F: 60           RTS 
C1/4D80: A5 01        LDA $01
C1/4D82: 29 0F        AND #$0F
C1/4D84: F0 03        BEQ $4D89
C1/4D86: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/4D89: AD C2 D0     LDA $D0C2
C1/4D8C: C9 08        CMP #$08
C1/4D8E: F0 07        BEQ $4D97
C1/4D90: A5 00        LDA $00
C1/4D92: 10 25        BPL $4DB9
C1/4D94: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/4D97: AD C2 D0     LDA $D0C2
C1/4D9A: 29 04        AND #$04
C1/4D9C: F0 15        BEQ $4DB3
C1/4D9E: 20 94 54     JSR $5494
C1/4DA1: 20 96 FC     JSR $FC96       ; generate random number
C1/4DA4: 29 3F        AND #$3F
C1/4DA6: 18           CLC 
C1/4DA7: 69 20        ADC #$20
C1/4DA9: 8D 47 DB     STA $DB47
C1/4DAC: A9 13        LDA #$13
C1/4DAE: 8D 3A CD     STA $CD3A
C1/4DB1: 80 03        BRA $4DB6
C1/4DB3: 20 28 4D     JSR $4D28
C1/4DB6: 4C 3C 4D     JMP $4D3C
C1/4DB9: AD F8 CD     LDA $CDF8
C1/4DBC: D0 0A        BNE $4DC8
C1/4DBE: A5 01        LDA $01
C1/4DC0: 10 22        BPL $4DE4
C1/4DC2: 20 C3 FB     JSR $FBC3       ; play system sound effect $11
C1/4DC5: 20 94 54     JSR $5494
C1/4DC8: AD C2 D0     LDA $D0C2
C1/4DCB: 29 08        AND #$08
C1/4DCD: D0 08        BNE $4DD7
C1/4DCF: AD C3 D0     LDA $D0C3
C1/4DD2: 20 5C 48     JSR $485C
C1/4DD5: 80 06        BRA $4DDD
C1/4DD7: AD C3 D0     LDA $D0C3
C1/4DDA: 8D 3A CD     STA $CD3A
C1/4DDD: 20 E9 4B     JSR $4BE9
C1/4DE0: 9C 90 F8     STZ $F890
C1/4DE3: 60           RTS 
C1/4DE4: AD C2 D0     LDA $D0C2
C1/4DE7: 29 20        AND #$20
C1/4DE9: F0 42        BEQ $4E2D
C1/4DEB: AD C2 D0     LDA $D0C2
C1/4DEE: 29 04        AND #$04
C1/4DF0: F0 0B        BEQ $4DFD
C1/4DF2: A5 A2        LDA $A2
C1/4DF4: 29 03        AND #$03
C1/4DF6: D0 35        BNE $4E2D
C1/4DF8: 20 97 4C     JSR $4C97
C1/4DFB: 80 30        BRA $4E2D
C1/4DFD: A5 01        LDA $01
C1/4DFF: 29 0F        AND #$0F
C1/4E01: C9 08        CMP #$08
C1/4E03: D0 05        BNE $4E0A
C1/4E05: 20 A3 4E     JSR $4EA3
C1/4E08: 80 23        BRA $4E2D
C1/4E0A: C9 04        CMP #$04
C1/4E0C: D0 05        BNE $4E13
C1/4E0E: 20 C6 4E     JSR $4EC6
C1/4E11: 80 1A        BRA $4E2D
C1/4E13: C9 02        CMP #$02
C1/4E15: D0 09        BNE $4E20
C1/4E17: A5 F6        LDA $F6
C1/4E19: D0 0D        BNE $4E28
C1/4E1B: 20 28 4F     JSR $4F28
C1/4E1E: 80 0D        BRA $4E2D
C1/4E20: C9 01        CMP #$01
C1/4E22: D0 09        BNE $4E2D
C1/4E24: A5 F6        LDA $F6
C1/4E26: D0 F3        BNE $4E1B
C1/4E28: 20 E9 4E     JSR $4EE9
C1/4E2B: 80 00        BRA $4E2D
C1/4E2D: 20 5E 4E     JSR $4E5E
C1/4E30: 90 96        BCC $4DC8
C1/4E32: 4C 1D 4C     JMP $4C1D
C1/4E35: 38           SEC 
C1/4E36: E9 08        SBC #$08
C1/4E38: 85 88        STA $88
C1/4E3A: A5 88        LDA $88
C1/4E3C: 29 03        AND #$03
C1/4E3E: 0A           ASL 
C1/4E3F: 0A           ASL 
C1/4E40: 0A           ASL 
C1/4E41: 0A           ASL 
C1/4E42: 0A           ASL 
C1/4E43: AA           TAX 
C1/4E44: BD 43 CF     LDA $CF43,X
C1/4E47: F0 0A        BEQ $4E53
C1/4E49: A5 88        LDA $88
C1/4E4B: 18           CLC 
C1/4E4C: 65 8A        ADC $8A
C1/4E4E: 85 88        STA $88
C1/4E50: 4C 3A 4E     JMP $4E3A
C1/4E53: A5 88        LDA $88
C1/4E55: 29 03        AND #$03
C1/4E57: 18           CLC 
C1/4E58: 69 08        ADC #$08
C1/4E5A: 8D C4 D0     STA $D0C4
C1/4E5D: 60           RTS 
C1/4E5E: AD C5 D0     LDA $D0C5
C1/4E61: D0 3B        BNE $4E9E
C1/4E63: AD C4 D0     LDA $D0C4
C1/4E66: 0A           ASL 
C1/4E67: AA           TAX 
C1/4E68: C2 20        REP #$20
C1/4E6A: A5 DE        LDA $DE
C1/4E6C: 2D E1 DB     AND $DBE1
C1/4E6F: 3F D5 FF CE  AND $CEFFD5,X
C1/4E73: D0 29        BNE $4E9E
C1/4E75: 7B           TDC 
C1/4E76: E2 20        SEP #$20
C1/4E78: AD C4 D0     LDA $D0C4
C1/4E7B: C9 08        CMP #$08
C1/4E7D: 90 02        BCC $4E81
C1/4E7F: 18           CLC 
C1/4E80: 60           RTS 
C1/4E81: A5 DE        LDA $DE
C1/4E83: F0 FA        BEQ $4E7F
C1/4E85: 7B           TDC 
C1/4E86: A8           TAY 
C1/4E87: B9 AA D0     LDA $D0AA,Y
C1/4E8A: 20 95 51     JSR $5195
C1/4E8D: B0 09        BCS $4E98
C1/4E8F: C8           INY 
C1/4E90: C0 08 00     CPY #$0008
C1/4E93: D0 F2        BNE $4E87
C1/4E95: 4C 7F 4E     JMP $4E7F
C1/4E98: B9 AA D0     LDA $D0AA,Y
C1/4E9B: 8D C4 D0     STA $D0C4
C1/4E9E: 7B           TDC 
C1/4E9F: E2 20        SEP #$20
C1/4EA1: 38           SEC 
C1/4EA2: 60           RTS 
C1/4EA3: AD C5 D0     LDA $D0C5
C1/4EA6: D0 1D        BNE $4EC5
C1/4EA8: AD C4 D0     LDA $D0C4
C1/4EAB: C9 08        CMP #$08
C1/4EAD: 90 0A        BCC $4EB9
C1/4EAF: 48           PHA 
C1/4EB0: A9 FF        LDA #$FF
C1/4EB2: 85 8A        STA $8A
C1/4EB4: 68           PLA 
C1/4EB5: 3A           DEC 
C1/4EB6: 4C 35 4E     JMP $4E35
C1/4EB9: 20 FE 4F     JSR $4FFE
C1/4EBC: A5 E2        LDA $E2
C1/4EBE: C9 FF        CMP #$FF
C1/4EC0: F0 03        BEQ $4EC5
C1/4EC2: 8D C4 D0     STA $D0C4
C1/4EC5: 60           RTS 
C1/4EC6: AD C5 D0     LDA $D0C5
C1/4EC9: D0 1D        BNE $4EE8
C1/4ECB: AD C4 D0     LDA $D0C4
C1/4ECE: C9 08        CMP #$08
C1/4ED0: 90 0A        BCC $4EDC
C1/4ED2: 48           PHA 
C1/4ED3: A9 01        LDA #$01
C1/4ED5: 85 8A        STA $8A
C1/4ED7: 68           PLA 
C1/4ED8: 1A           INC 
C1/4ED9: 4C 35 4E     JMP $4E35
C1/4EDC: 20 41 50     JSR $5041
C1/4EDF: A5 E2        LDA $E2
C1/4EE1: C9 FF        CMP #$FF
C1/4EE3: F0 03        BEQ $4EE8
C1/4EE5: 8D C4 D0     STA $D0C4
C1/4EE8: 60           RTS 
C1/4EE9: AD C4 D0     LDA $D0C4
C1/4EEC: C9 08        CMP #$08
C1/4EEE: 90 10        BCC $4F00
C1/4EF0: AD C5 D0     LDA $D0C5
C1/4EF3: D0 0A        BNE $4EFF
C1/4EF5: AD C2 D0     LDA $D0C2
C1/4EF8: 10 05        BPL $4EFF
C1/4EFA: A9 02        LDA #$02
C1/4EFC: 8D C5 D0     STA $D0C5
C1/4EFF: 60           RTS 
C1/4F00: AD C5 D0     LDA $D0C5
C1/4F03: C9 01        CMP #$01
C1/4F05: D0 04        BNE $4F0B
C1/4F07: 9C C5 D0     STZ $D0C5
C1/4F0A: 60           RTS 
C1/4F0B: 20 C9 50     JSR $50C9
C1/4F0E: A5 E2        LDA $E2
C1/4F10: C9 FF        CMP #$FF
C1/4F12: D0 10        BNE $4F24
C1/4F14: AD C2 D0     LDA $D0C2
C1/4F17: 29 10        AND #$10
C1/4F19: F0 E4        BEQ $4EFF
C1/4F1B: A9 01        LDA #$01
C1/4F1D: 85 8A        STA $8A
C1/4F1F: A9 08        LDA #$08
C1/4F21: 4C 35 4E     JMP $4E35
C1/4F24: 8D C4 D0     STA $D0C4
C1/4F27: 60           RTS 
C1/4F28: AD C4 D0     LDA $D0C4
C1/4F2B: C9 08        CMP #$08
C1/4F2D: 90 2A        BCC $4F59
C1/4F2F: AD C5 D0     LDA $D0C5
C1/4F32: C9 02        CMP #$02
C1/4F34: D0 04        BNE $4F3A
C1/4F36: 9C C5 D0     STZ $D0C5
C1/4F39: 60           RTS 
C1/4F3A: AD C2 D0     LDA $D0C2
C1/4F3D: 29 10        AND #$10
C1/4F3F: F0 17        BEQ $4F58
C1/4F41: 7B           TDC 
C1/4F42: A8           TAY 
C1/4F43: B9 AA D0     LDA $D0AA,Y
C1/4F46: 20 95 51     JSR $5195
C1/4F49: B0 07        BCS $4F52
C1/4F4B: C8           INY 
C1/4F4C: C0 08 00     CPY #$0008
C1/4F4F: D0 F2        BNE $4F43
C1/4F51: 60           RTS 
C1/4F52: B9 AA D0     LDA $D0AA,Y
C1/4F55: 8D C4 D0     STA $D0C4
C1/4F58: 60           RTS 
C1/4F59: 20 86 50     JSR $5086
C1/4F5C: A5 E2        LDA $E2
C1/4F5E: C9 FF        CMP #$FF
C1/4F60: D0 0B        BNE $4F6D
C1/4F62: AD C2 D0     LDA $D0C2
C1/4F65: 10 F1        BPL $4F58
C1/4F67: A9 01        LDA #$01
C1/4F69: 8D C5 D0     STA $D0C5
C1/4F6C: 60           RTS 
C1/4F6D: 8D C4 D0     STA $D0C4
C1/4F70: 60           RTS 
C1/4F71: A9 FF        LDA #$FF
C1/4F73: 85 E0        STA $E0
C1/4F75: 85 E1        STA $E1
C1/4F77: 85 E2        STA $E2
C1/4F79: AD C4 D0     LDA $D0C4
C1/4F7C: AA           TAX 
C1/4F7D: BD 36 D0     LDA $D036,X
C1/4F80: 4A           LSR 
C1/4F81: 4A           LSR 
C1/4F82: 4A           LSR 
C1/4F83: 85 88        STA $88
C1/4F85: 64 89        STZ $89
C1/4F87: BD 42 D0     LDA $D042,X
C1/4F8A: 4A           LSR 
C1/4F8B: 4A           LSR 
C1/4F8C: 4A           LSR 
C1/4F8D: 85 8A        STA $8A
C1/4F8F: 64 8B        STZ $8B
C1/4F91: 60           RTS 
C1/4F92: B9 36 D0     LDA $D036,Y
C1/4F95: 4A           LSR 
C1/4F96: 4A           LSR 
C1/4F97: 4A           LSR 
C1/4F98: 85 8C        STA $8C
C1/4F9A: 64 8D        STZ $8D
C1/4F9C: B9 42 D0     LDA $D042,Y
C1/4F9F: 4A           LSR 
C1/4FA0: 4A           LSR 
C1/4FA1: 4A           LSR 
C1/4FA2: 85 8E        STA $8E
C1/4FA4: 64 8F        STZ $8F
C1/4FA6: C2 20        REP #$20
C1/4FA8: A5 8C        LDA $8C
C1/4FAA: 38           SEC 
C1/4FAB: E5 88        SBC $88
C1/4FAD: 85 90        STA $90
C1/4FAF: A5 8E        LDA $8E
C1/4FB1: 38           SEC 
C1/4FB2: E5 8A        SBC $8A
C1/4FB4: 85 92        STA $92
C1/4FB6: 7B           TDC 
C1/4FB7: E2 20        SEP #$20
C1/4FB9: 60           RTS 
C1/4FBA: C2 20        REP #$20
C1/4FBC: A5 90        LDA $90
C1/4FBE: 10 06        BPL $4FC6
C1/4FC0: 49 FF FF     EOR #$FFFF
C1/4FC3: 1A           INC 
C1/4FC4: 85 90        STA $90
C1/4FC6: A5 92        LDA $92
C1/4FC8: 10 06        BPL $4FD0
C1/4FCA: 49 FF FF     EOR #$FFFF
C1/4FCD: 1A           INC 
C1/4FCE: 85 92        STA $92
C1/4FD0: 7B           TDC 
C1/4FD1: E2 20        SEP #$20
C1/4FD3: A5 90        LDA $90
C1/4FD5: 85 98        STA $98
C1/4FD7: 85 9A        STA $9A
C1/4FD9: 20 4B FE     JSR $FE4B
C1/4FDC: A6 9C        LDX $9C
C1/4FDE: A5 92        LDA $92
C1/4FE0: 85 98        STA $98
C1/4FE2: 85 9A        STA $9A
C1/4FE4: 20 4B FE     JSR $FE4B
C1/4FE7: C2 20        REP #$20
C1/4FE9: 8A           TXA 
C1/4FEA: 18           CLC 
C1/4FEB: 65 9C        ADC $9C
C1/4FED: C5 E0        CMP $E0
C1/4FEF: B0 09        BCS $4FFA
C1/4FF1: 85 E0        STA $E0
C1/4FF3: 7B           TDC 
C1/4FF4: E2 20        SEP #$20
C1/4FF6: 98           TYA 
C1/4FF7: 85 E2        STA $E2
C1/4FF9: 60           RTS 
C1/4FFA: 7B           TDC 
C1/4FFB: E2 20        SEP #$20
C1/4FFD: 60           RTS 
C1/4FFE: 20 71 4F     JSR $4F71
C1/5001: 7B           TDC 
C1/5002: A8           TAY 
C1/5003: 98           TYA 
C1/5004: CD C4 D0     CMP $D0C4
C1/5007: F0 05        BEQ $500E
C1/5009: 20 95 51     JSR $5195
C1/500C: B0 0A        BCS $5018
C1/500E: 7B           TDC 
C1/500F: E2 20        SEP #$20
C1/5011: C8           INY 
C1/5012: C0 08 00     CPY #$0008
C1/5015: D0 EC        BNE $5003
C1/5017: 60           RTS 
C1/5018: 20 92 4F     JSR $4F92
C1/501B: C2 20        REP #$20
C1/501D: A5 92        LDA $92
C1/501F: 10 ED        BPL $500E
C1/5021: A5 90        LDA $90
C1/5023: 10 0A        BPL $502F
C1/5025: A5 92        LDA $92
C1/5027: C5 90        CMP $90
C1/5029: F0 0D        BEQ $5038
C1/502B: 90 0B        BCC $5038
C1/502D: 80 DF        BRA $500E
C1/502F: A5 92        LDA $92
C1/5031: 18           CLC 
C1/5032: 65 90        ADC $90
C1/5034: F0 02        BEQ $5038
C1/5036: 10 D6        BPL $500E
C1/5038: 7B           TDC 
C1/5039: E2 20        SEP #$20
C1/503B: 20 BA 4F     JSR $4FBA
C1/503E: 4C 0E 50     JMP $500E
C1/5041: 20 71 4F     JSR $4F71
C1/5044: 7B           TDC 
C1/5045: A8           TAY 
C1/5046: 98           TYA 
C1/5047: CD C4 D0     CMP $D0C4
C1/504A: F0 05        BEQ $5051
C1/504C: 20 95 51     JSR $5195
C1/504F: B0 0A        BCS $505B
C1/5051: 7B           TDC 
C1/5052: E2 20        SEP #$20
C1/5054: C8           INY 
C1/5055: C0 08 00     CPY #$0008
C1/5058: D0 EC        BNE $5046
C1/505A: 60           RTS 
C1/505B: 20 92 4F     JSR $4F92
C1/505E: C2 20        REP #$20
C1/5060: A5 92        LDA $92
C1/5062: F0 ED        BEQ $5051
C1/5064: 30 EB        BMI $5051
C1/5066: A5 90        LDA $90
C1/5068: 30 0A        BMI $5074
C1/506A: A5 90        LDA $90
C1/506C: C5 92        CMP $92
C1/506E: 90 0D        BCC $507D
C1/5070: F0 0B        BEQ $507D
C1/5072: 80 DD        BRA $5051
C1/5074: A5 92        LDA $92
C1/5076: 18           CLC 
C1/5077: 65 90        ADC $90
C1/5079: F0 02        BEQ $507D
C1/507B: 30 D4        BMI $5051
C1/507D: 7B           TDC 
C1/507E: E2 20        SEP #$20
C1/5080: 20 BA 4F     JSR $4FBA
C1/5083: 4C 51 50     JMP $5051
C1/5086: 20 71 4F     JSR $4F71
C1/5089: 7B           TDC 
C1/508A: A8           TAY 
C1/508B: 98           TYA 
C1/508C: CD C4 D0     CMP $D0C4
C1/508F: F0 05        BEQ $5096
C1/5091: 20 95 51     JSR $5195
C1/5094: B0 0A        BCS $50A0
C1/5096: 7B           TDC 
C1/5097: E2 20        SEP #$20
C1/5099: C8           INY 
C1/509A: C0 08 00     CPY #$0008
C1/509D: D0 EC        BNE $508B
C1/509F: 60           RTS 
C1/50A0: 20 92 4F     JSR $4F92
C1/50A3: C2 20        REP #$20
C1/50A5: A5 90        LDA $90
C1/50A7: 10 ED        BPL $5096
C1/50A9: A5 92        LDA $92
C1/50AB: 10 0A        BPL $50B7
C1/50AD: A5 90        LDA $90
C1/50AF: C5 92        CMP $92
C1/50B1: 90 0D        BCC $50C0
C1/50B3: F0 0B        BEQ $50C0
C1/50B5: 80 DF        BRA $5096
C1/50B7: A5 92        LDA $92
C1/50B9: 18           CLC 
C1/50BA: 65 90        ADC $90
C1/50BC: F0 02        BEQ $50C0
C1/50BE: 10 D6        BPL $5096
C1/50C0: 7B           TDC 
C1/50C1: E2 20        SEP #$20
C1/50C3: 20 BA 4F     JSR $4FBA
C1/50C6: 4C 96 50     JMP $5096
C1/50C9: 20 71 4F     JSR $4F71
C1/50CC: 7B           TDC 
C1/50CD: A8           TAY 
C1/50CE: 98           TYA 
C1/50CF: CD C4 D0     CMP $D0C4
C1/50D2: F0 05        BEQ $50D9
C1/50D4: 20 95 51     JSR $5195
C1/50D7: B0 0A        BCS $50E3
C1/50D9: 7B           TDC 
C1/50DA: E2 20        SEP #$20
C1/50DC: C8           INY 
C1/50DD: C0 08 00     CPY #$0008
C1/50E0: D0 EC        BNE $50CE
C1/50E2: 60           RTS 
C1/50E3: 20 92 4F     JSR $4F92
C1/50E6: C2 20        REP #$20
C1/50E8: A5 90        LDA $90
C1/50EA: F0 ED        BEQ $50D9
C1/50EC: 30 EB        BMI $50D9
C1/50EE: A5 92        LDA $92
C1/50F0: 30 0A        BMI $50FC
C1/50F2: A5 92        LDA $92
C1/50F4: C5 90        CMP $90
C1/50F6: F0 0D        BEQ $5105
C1/50F8: 90 0B        BCC $5105
C1/50FA: 80 DD        BRA $50D9
C1/50FC: A5 92        LDA $92
C1/50FE: 18           CLC 
C1/50FF: 65 90        ADC $90
C1/5101: F0 02        BEQ $5105
C1/5103: 30 D4        BMI $50D9
C1/5105: 7B           TDC 
C1/5106: E2 20        SEP #$20
C1/5108: 20 BA 4F     JSR $4FBA
C1/510B: 4C D9 50     JMP $50D9
C1/510E: 9C C5 D0     STZ $D0C5
C1/5111: 8D C2 D0     STA $D0C2
C1/5114: 85 8A        STA $8A
C1/5116: A5 88        LDA $88
C1/5118: 8D C3 D0     STA $D0C3
C1/511B: A5 8A        LDA $8A
C1/511D: D0 05        BNE $5124
C1/511F: AD 42 CD     LDA $CD42
C1/5122: 80 05        BRA $5129
C1/5124: 29 08        AND #$08
C1/5126: D0 22        BNE $514A
C1/5128: 7B           TDC 
C1/5129: 85 8C        STA $8C
C1/512B: A5 8C        LDA $8C
C1/512D: 29 03        AND #$03
C1/512F: 0A           ASL 
C1/5130: 0A           ASL 
C1/5131: 0A           ASL 
C1/5132: 0A           ASL 
C1/5133: 0A           ASL 
C1/5134: AA           TAX 
C1/5135: BD 43 CF     LDA $CF43,X
C1/5138: F0 05        BEQ $513F
C1/513A: E6 8C        INC $8C
C1/513C: 4C 2B 51     JMP $512B
C1/513F: A5 8C        LDA $8C
C1/5141: 18           CLC 
C1/5142: 69 08        ADC #$08
C1/5144: 8D C4 D0     STA $D0C4
C1/5147: 4C 60 51     JMP $5160
C1/514A: 7B           TDC 
C1/514B: A8           TAY 
C1/514C: B9 AA D0     LDA $D0AA,Y
C1/514F: 20 95 51     JSR $5195
C1/5152: B0 06        BCS $515A
C1/5154: C8           INY 
C1/5155: C0 08 00     CPY #$0008
C1/5158: D0 F2        BNE $514C
C1/515A: B9 AA D0     LDA $D0AA,Y
C1/515D: 8D C4 D0     STA $D0C4
C1/5160: AD C2 D0     LDA $D0C2
C1/5163: 29 04        AND #$04
C1/5165: F0 05        BEQ $516C
C1/5167: 20 73 4C     JSR $4C73
C1/516A: 80 19        BRA $5185
C1/516C: AD C2 D0     LDA $D0C2
C1/516F: 29 48        AND #$48
C1/5171: C9 40        CMP #$40
C1/5173: D0 07        BNE $517C
C1/5175: A9 02        LDA #$02
C1/5177: 8D C5 D0     STA $D0C5
C1/517A: 80 09        BRA $5185
C1/517C: C9 48        CMP #$48
C1/517E: D0 05        BNE $5185
C1/5180: A9 01        LDA #$01
C1/5182: 8D C5 D0     STA $D0C5
C1/5185: AD C2 D0     LDA $D0C2
C1/5188: 29 08        AND #$08
C1/518A: D0 03        BNE $518F
C1/518C: 4C 3B 48     JMP $483B
C1/518F: A9 12        LDA #$12
C1/5191: 8D 3A CD     STA $CD3A
C1/5194: 60           RTS 
C1/5195: AA           TAX 
C1/5196: A5 DE        LDA $DE
C1/5198: 2D E1 DB     AND $DBE1
C1/519B: 3F CD FF CE  AND $CEFFCD,X
C1/519F: F0 02        BEQ $51A3
C1/51A1: 38           SEC 
C1/51A2: 60           RTS 
C1/51A3: 18           CLC 
C1/51A4: 60           RTS 
C1/51A5: 9C 48 CD     STZ $CD48
C1/51A8: AD F8 CD     LDA $CDF8
C1/51AB: F0 03        BEQ $51B0
C1/51AD: 4C 1D 49     JMP $491D
C1/51B0: A5 00        LDA $00
C1/51B2: 10 0E        BPL $51C2
C1/51B4: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/51B7: A9 03        LDA #$03
C1/51B9: 8D B2 41     STA $41B2
C1/51BC: EE F8 CD     INC $CDF8
C1/51BF: 4C 1D 49     JMP $491D
C1/51C2: A5 01        LDA $01
C1/51C4: 29 01        AND #$01
C1/51C6: F0 05        BEQ $51CD
C1/51C8: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/51CB: 80 14        BRA $51E1
C1/51CD: AD 26 04     LDA $0426
C1/51D0: 10 08        BPL $51DA
C1/51D2: A5 02        LDA $02
C1/51D4: 29 30        AND #$30
C1/51D6: C9 20        CMP #$20
C1/51D8: D0 07        BNE $51E1
C1/51DA: A5 01        LDA $01
C1/51DC: 10 06        BPL $51E4
C1/51DE: 20 C3 FB     JSR $FBC3       ; play system sound effect $11
C1/51E1: 4C 1D 49     JMP $491D
C1/51E4: A9 08        LDA #$08
C1/51E6: 4C 2F 52     JMP $522F
C1/51E9: 9C 48 CD     STZ $CD48
C1/51EC: A9 03        LDA #$03
C1/51EE: 8D 4B CD     STA $CD4B
C1/51F1: AD F8 CD     LDA $CDF8
C1/51F4: F0 03        BEQ $51F9
C1/51F6: 4C 1D 49     JMP $491D
C1/51F9: A5 00        LDA $00
C1/51FB: 10 0E        BPL $520B
C1/51FD: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/5200: A9 04        LDA #$04
C1/5202: 8D B2 41     STA $41B2
C1/5205: EE F8 CD     INC $CDF8
C1/5208: 4C 1D 49     JMP $491D
C1/520B: A5 01        LDA $01
C1/520D: 29 02        AND #$02
C1/520F: F0 05        BEQ $5216
C1/5211: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5214: 80 14        BRA $522A
C1/5216: AD 26 04     LDA $0426
C1/5219: 10 08        BPL $5223
C1/521B: A5 02        LDA $02
C1/521D: 29 30        AND #$30
C1/521F: C9 10        CMP #$10
C1/5221: D0 07        BNE $522A
C1/5223: A5 01        LDA $01
C1/5225: 10 06        BPL $522D
C1/5227: 20 C3 FB     JSR $FBC3       ; play system sound effect $11
C1/522A: 4C 1D 49     JMP $491D
C1/522D: A9 60        LDA #$60
C1/522F: 8D 49 CD     STA $CD49
C1/5232: AD 26 04     LDA $0426
C1/5235: 10 03        BPL $523A
C1/5237: 7B           TDC 
C1/5238: 80 08        BRA $5242
C1/523A: AD 42 CD     LDA $CD42
C1/523D: AA           TAX 
C1/523E: BD 2D 04     LDA $042D,X
C1/5241: 0A           ASL 
C1/5242: AA           TAX 
C1/5243: BF C6 FF CE  LDA $CEFFC6,X
C1/5247: 8D 4A CD     STA $CD4A
C1/524A: EE 48 CD     INC $CD48
C1/524D: A9 33        LDA #$33
C1/524F: 8D 4B CD     STA $CD4B
C1/5252: 60           RTS 
C1/5253: 30 A6        BMI $51FB
C1/5255: 10 B2        BPL $5209
C1/5257: 48           PHA 
C1/5258: B2 30        LDA ($30)
C1/525A: BE 10 BA     LDX $BA10,Y
C1/525D: 80 BA        BRA $5219
C1/525F: 30 A6        BMI $5207
C1/5261: 30 B2        BMI $5215
C1/5263: 30 BE        BMI $5223
C1/5265: 04 3C        TSB $3C
C1/5267: 74 04        STZ $04,X
C1/5269: 54 10 80     MVN $10,$80
C1/526C: AA           TAX 
C1/526D: B6 C2        LDX $C2,Y
C1/526F: CE DA BD     DEC $BDDA
C1/5272: 2D 04 29     AND $2904
C1/5275: 03 9D        ORA $9D,S
C1/5277: 2D 04 85     AND $8504
C1/527A: 88           DEY 
C1/527B: 64 89        STZ $89
C1/527D: AD 42 CD     LDA $CD42
C1/5280: 0A           ASL 
C1/5281: AA           TAX 
C1/5282: AD 40 CD     LDA $CD40
C1/5285: F0 10        BEQ $5297
C1/5287: C2 20        REP #$20
C1/5289: BF 28 FF CE  LDA $CEFF28,X
C1/528D: 18           CLC 
C1/528E: 65 88        ADC $88
C1/5290: 85 88        STA $88
C1/5292: 7B           TDC 
C1/5293: E2 20        SEP #$20
C1/5295: 80 0E        BRA $52A5
C1/5297: C2 20        REP #$20
C1/5299: BF 20 FF CE  LDA $CEFF20,X
C1/529D: 18           CLC 
C1/529E: 65 88        ADC $88
C1/52A0: 85 88        STA $88
C1/52A2: 7B           TDC 
C1/52A3: E2 20        SEP #$20
C1/52A5: FA           PLX 
C1/52A6: 60           RTS 

; [ get menu id for battle command ]

C1/52A7: AA           TAX 
C1/52A8: BF 17 5F C1  LDA $C15F17,X
C1/52AC: 60           RTS 

C1/52AD: AD 40 CD     LDA $CD40
C1/52B0: F0 22        BEQ $52D4
C1/52B2: DA           PHX 
C1/52B3: BD 2D 04     LDA $042D,X
C1/52B6: 29 03        AND #$03
C1/52B8: 9D 2D 04     STA $042D,X
C1/52BB: 85 88        STA $88
C1/52BD: 64 89        STZ $89
C1/52BF: AD 42 CD     LDA $CD42
C1/52C2: 0A           ASL 
C1/52C3: AA           TAX 
C1/52C4: C2 20        REP #$20
C1/52C6: BF 18 FF CE  LDA $CEFF18,X
C1/52CA: 18           CLC 
C1/52CB: 65 88        ADC $88
C1/52CD: 85 88        STA $88
C1/52CF: 7B           TDC 
C1/52D0: E2 20        SEP #$20
C1/52D2: FA           PLX 
C1/52D3: 60           RTS 
C1/52D4: DA           PHX 
C1/52D5: BD 2D 04     LDA $042D,X
C1/52D8: 29 03        AND #$03
C1/52DA: 9D 2D 04     STA $042D,X
C1/52DD: 85 88        STA $88
C1/52DF: 64 89        STZ $89
C1/52E1: AD 42 CD     LDA $CD42
C1/52E4: 0A           ASL 
C1/52E5: AA           TAX 
C1/52E6: C2 20        REP #$20
C1/52E8: BF 08 FF CE  LDA $CEFF08,X
C1/52EC: 18           CLC 
C1/52ED: 65 88        ADC $88
C1/52EF: 85 88        STA $88
C1/52F1: 7B           TDC 
C1/52F2: E2 20        SEP #$20
C1/52F4: FA           PLX 
C1/52F5: 60           RTS 
C1/52F6: DA           PHX 
C1/52F7: BD 2D 04     LDA $042D,X
C1/52FA: 29 03        AND #$03
C1/52FC: 9D 2D 04     STA $042D,X
C1/52FF: 85 88        STA $88
C1/5301: 64 89        STZ $89
C1/5303: AD 42 CD     LDA $CD42
C1/5306: 0A           ASL 
C1/5307: AA           TAX 
C1/5308: C2 20        REP #$20
C1/530A: BF 00 FF CE  LDA $CEFF00,X
C1/530E: 18           CLC 
C1/530F: 65 88        ADC $88
C1/5311: 85 88        STA $88
C1/5313: 7B           TDC 
C1/5314: E2 20        SEP #$20
C1/5316: FA           PLX 
C1/5317: 60           RTS 
C1/5318: 8D B1 41     STA $41B1
C1/531B: 8D B8 41     STA $41B8
C1/531E: 60           RTS 
C1/531F: BD 2D 04     LDA $042D,X
C1/5322: 85 98        STA $98
C1/5324: 20 AD 52     JSR $52AD
C1/5327: B2 88        LDA ($88)
C1/5329: 10 07        BPL $5332
C1/532B: A9 03        LDA #$03
C1/532D: 9D 2D 04     STA $042D,X
C1/5330: 85 98        STA $98
C1/5332: A5 01        LDA $01
C1/5334: 29 0F        AND #$0F
C1/5336: F0 35        BEQ $536D
C1/5338: 29 08        AND #$08
C1/533A: F0 03        BEQ $533F
C1/533C: 7B           TDC 
C1/533D: 80 16        BRA $5355
C1/533F: A5 01        LDA $01
C1/5341: 29 04        AND #$04
C1/5343: F0 04        BEQ $5349
C1/5345: A9 03        LDA #$03
C1/5347: 80 0C        BRA $5355
C1/5349: A5 01        LDA $01
C1/534B: 29 02        AND #$02
C1/534D: F0 04        BEQ $5353
C1/534F: A9 01        LDA #$01
C1/5351: 80 02        BRA $5355
C1/5353: A9 02        LDA #$02
C1/5355: A8           TAY 
C1/5356: B9 F6 FE     LDA $FEF6,Y
C1/5359: 9D 2D 04     STA $042D,X
C1/535C: 20 AD 52     JSR $52AD
C1/535F: B2 88        LDA ($88)
C1/5361: 10 07        BPL $536A
C1/5363: A5 98        LDA $98
C1/5365: 9D 2D 04     STA $042D,X
C1/5368: 80 03        BRA $536D
C1/536A: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/536D: AD 40 CD     LDA $CD40
C1/5370: D0 22        BNE $5394
C1/5372: A5 02        LDA $02
C1/5374: 29 30        AND #$30
C1/5376: C9 20        CMP #$20
C1/5378: D0 09        BNE $5383
C1/537A: 9C 48 CD     STZ $CD48
C1/537D: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5380: 4C 4D 49     JMP $494D
C1/5383: A5 02        LDA $02
C1/5385: 29 30        AND #$30
C1/5387: C9 10        CMP #$10
C1/5389: D0 09        BNE $5394
C1/538B: 9C 48 CD     STZ $CD48
C1/538E: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5391: 4C 30 49     JMP $4930
C1/5394: DA           PHX 
C1/5395: BD 2D 04     LDA $042D,X
C1/5398: 85 98        STA $98
C1/539A: 7B           TDC 
C1/539B: AA           TAX 
C1/539C: BD F6 FE     LDA $FEF6,X
C1/539F: C5 98        CMP $98
C1/53A1: F0 06        BEQ $53A9
C1/53A3: E8           INX 
C1/53A4: E0 04 00     CPX #$0004
C1/53A7: D0 F3        BNE $539C
C1/53A9: 8A           TXA 
C1/53AA: 0A           ASL 
C1/53AB: AA           TAX 
C1/53AC: BF 53 52 C1  LDA $C15253,X
C1/53B0: 8D 49 CD     STA $CD49
C1/53B3: BF 54 52 C1  LDA $C15254,X
C1/53B7: 8D 4A CD     STA $CD4A
C1/53BA: A9 01        LDA #$01
C1/53BC: 8D 48 CD     STA $CD48
C1/53BF: FA           PLX 
C1/53C0: A5 00        LDA $00
C1/53C2: 10 09        BPL $53CD
C1/53C4: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/53C7: 9C 48 CD     STZ $CD48
C1/53CA: 20 A1 54     JSR $54A1
C1/53CD: 60           RTS 
C1/53CE: 9C 52 7C     STZ $7C52       ; unpause battle (wait mode)
C1/53D1: AD F8 CD     LDA $CDF8
C1/53D4: F0 09        BEQ $53DF
C1/53D6: 9C F8 CD     STZ $CDF8
C1/53D9: 9C 48 CD     STZ $CD48
C1/53DC: 4C A2 48     JMP $48A2
C1/53DF: AD 42 CD     LDA $CD42
C1/53E2: 8D B3 41     STA $41B3
C1/53E5: 8D BA 41     STA $41BA
C1/53E8: 9C B4 41     STZ $41B4
C1/53EB: 9C B5 41     STZ $41B5
C1/53EE: 9C B6 41     STZ $41B6
C1/53F1: 9C BB 41     STZ $41BB
C1/53F4: 9C BC 41     STZ $41BC
C1/53F7: 9C BD 41     STZ $41BD
C1/53FA: 9C 91 F8     STZ $F891
C1/53FD: 9C 90 F8     STZ $F890
C1/5400: A9 80        LDA #$80
C1/5402: 20 18 53     JSR $5318
C1/5405: A9 01        LDA #$01
C1/5407: 8D F7 CD     STA $CDF7
C1/540A: AD 42 CD     LDA $CD42
C1/540D: AA           TAX 
C1/540E: AD 40 CD     LDA $CD40
C1/5411: D0 08        BNE $541B
C1/5413: AD 26 04     LDA $0426
C1/5416: 10 03        BPL $541B
C1/5418: 4C 1F 53     JMP $531F
C1/541B: A5 01        LDA $01
C1/541D: 29 0C        AND #$0C
C1/541F: F0 21        BEQ $5442
C1/5421: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5424: C9 08        CMP #$08
C1/5426: F0 10        BEQ $5438
C1/5428: C9 04        CMP #$04
C1/542A: D0 16        BNE $5442
C1/542C: FE 2D 04     INC $042D,X
C1/542F: 20 AD 52     JSR $52AD
C1/5432: B2 88        LDA ($88)
C1/5434: 30 F6        BMI $542C
C1/5436: 80 0A        BRA $5442
C1/5438: DE 2D 04     DEC $042D,X
C1/543B: 20 AD 52     JSR $52AD
C1/543E: B2 88        LDA ($88)
C1/5440: 30 F6        BMI $5438
C1/5442: 20 AD 52     JSR $52AD
C1/5445: B2 88        LDA ($88)
C1/5447: 30 E3        BMI $542C
C1/5449: DA           PHX 
C1/544A: BD 2D 04     LDA $042D,X
C1/544D: 0A           ASL 
C1/544E: AA           TAX 
C1/544F: BF C5 FF CE  LDA $CEFFC5,X
C1/5453: 8D 49 CD     STA $CD49
C1/5456: BF C6 FF CE  LDA $CEFFC6,X
C1/545A: 8D 4A CD     STA $CD4A
C1/545D: A9 01        LDA #$01
C1/545F: 8D 48 CD     STA $CD48
C1/5462: FA           PLX 
C1/5463: AD 40 CD     LDA $CD40
C1/5466: D0 1E        BNE $5486
C1/5468: A5 01        LDA $01
C1/546A: 29 02        AND #$02
C1/546C: F0 09        BEQ $5477
C1/546E: 9C 48 CD     STZ $CD48
C1/5471: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5474: 4C 4D 49     JMP $494D
C1/5477: A5 01        LDA $01
C1/5479: 29 01        AND #$01
C1/547B: F0 09        BEQ $5486
C1/547D: 9C 48 CD     STZ $CD48
C1/5480: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5483: 4C 30 49     JMP $4930
C1/5486: A5 00        LDA $00
C1/5488: 10 09        BPL $5493
C1/548A: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/548D: 9C 48 CD     STZ $CD48
C1/5490: 20 A1 54     JSR $54A1
C1/5493: 60           RTS 
C1/5494: AD 70 09     LDA $0970
C1/5497: 29 08        AND #$08
C1/5499: F0 05        BEQ $54A0       ; branch if not wait mode
C1/549B: A9 01        LDA #$01
C1/549D: 8D 52 7C     STA $7C52       ; pause battle while menu is open
C1/54A0: 60           RTS 

; [  ]

C1/54A1: BD 2D 04     LDA $042D,X     ; cursor position
C1/54A4: A8           TAY 
C1/54A5: AD 42 CD     LDA $CD42
C1/54A8: 0A           ASL 
C1/54A9: AA           TAX 
C1/54AA: AD 40 CD     LDA $CD40
C1/54AD: F0 1B        BEQ $54CA
C1/54AF: BF 10 FF CE  LDA $CEFF10,X
C1/54B3: 85 88        STA $88
C1/54B5: BF 11 FF CE  LDA $CEFF11,X
C1/54B9: 85 89        STA $89
C1/54BB: B1 88        LDA ($88),Y
C1/54BD: 8D B2 41     STA $41B2
C1/54C0: 98           TYA 
C1/54C1: 8D B6 41     STA $41B6
C1/54C4: 8D BD 41     STA $41BD
C1/54C7: 4C 76 46     JMP $4676
C1/54CA: BF 00 FF CE  LDA $CEFF00,X
C1/54CE: 85 88        STA $88
C1/54D0: BF 01 FF CE  LDA $CEFF01,X
C1/54D4: 85 89        STA $89
C1/54D6: B1 88        LDA ($88),Y
C1/54D8: 8D B2 41     STA $41B2
C1/54DB: B1 88        LDA ($88),Y
C1/54DD: 20 A7 52     JSR $52A7       ; get menu id for battle command
C1/54E0: 0A           ASL 
C1/54E1: AA           TAX 
C1/54E2: BF F1 54 C1  LDA $C154F1,X
C1/54E6: 85 88        STA $88
C1/54E8: BF F2 54 C1  LDA $C154F2,X
C1/54EC: 85 89        STA $89
C1/54EE: 6C 88 00     JMP ($0088)

; battle command menu jump table
C1/54F1:              .DW $4676, $46B7, $46BC, $46C1, $46C6, $46CB, $46D0, $46DA
C1/5501:              .DW $46DF, $46D5, $4676, $468C, $47B6, $468D, $469F, $46AB

C1/5511: DA           PHX 
C1/5512: AD 42 CD     LDA $CD42
C1/5515: A8           TAY 
C1/5516: B9 45 04     LDA $0445,Y
C1/5519: AA           TAX 
C1/551A: BF 6A 52 C1  LDA $C1526A,X
C1/551E: 8D 49 CD     STA $CD49
C1/5521: B9 49 04     LDA $0449,Y
C1/5524: AA           TAX 
C1/5525: BF 6C 52 C1  LDA $C1526C,X
C1/5529: 8D 4A CD     STA $CD4A
C1/552C: A9 01        LDA #$01
C1/552E: 8D 48 CD     STA $CD48
C1/5531: 20 BC 4B     JSR $4BBC
C1/5534: FA           PLX 
C1/5535: 60           RTS 
C1/5536: DA           PHX 
C1/5537: 5A           PHY 
C1/5538: AD 42 CD     LDA $CD42
C1/553B: A8           TAY 
C1/553C: B1 D5        LDA ($D5),Y
C1/553E: 18           CLC 
C1/553F: 65 D0        ADC $D0
C1/5541: AA           TAX 
C1/5542: BF 65 52 C1  LDA $C15265,X
C1/5546: 8D 49 CD     STA $CD49
C1/5549: B1 D7        LDA ($D7),Y
C1/554B: AA           TAX 
C1/554C: BF 6C 52 C1  LDA $C1526C,X
C1/5550: 8D 4A CD     STA $CD4A
C1/5553: A9 01        LDA #$01
C1/5555: 8D 48 CD     STA $CD48
C1/5558: 7A           PLY 
C1/5559: FA           PLX 
C1/555A: 60           RTS 

; [  ]

C1/555B: AD 44 CD     LDA $CD44
C1/555E: F0 13        BEQ $5573
C1/5560: A2 06 00     LDX #$0006
C1/5563: 86 88        STX $88
C1/5565: A2 63 C3     LDX #$C363
C1/5568: A0 59 1F     LDY #$1F59
C1/556B: A9 7E        LDA #$7E
C1/556D: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/5570: 9C 44 CD     STZ $CD44
C1/5573: 60           RTS 
C1/5574: A5 DB        LDA $DB
C1/5576: 18           CLC 
C1/5577: 71 D3        ADC ($D3),Y
C1/5579: C2 20        REP #$20
C1/557B: 18           CLC 
C1/557C: 7F 8D FF CE  ADC $CEFF8D,X
C1/5580: AA           TAX 
C1/5581: 7B           TDC 
C1/5582: E2 20        SEP #$20
C1/5584: 64 88        STZ $88
C1/5586: 64 89        STZ $89
C1/5588: BD 38 2E     LDA $2E38,X
C1/558B: 38           SEC 
C1/558C: E9 64        SBC #$64
C1/558E: 90 04        BCC $5594
C1/5590: E6 88        INC $88
C1/5592: 80 F7        BRA $558B
C1/5594: 18           CLC 
C1/5595: 69 64        ADC #$64
C1/5597: 38           SEC 
C1/5598: E9 0A        SBC #$0A
C1/559A: 90 04        BCC $55A0
C1/559C: E6 89        INC $89
C1/559E: 80 F7        BRA $5597
C1/55A0: 18           CLC 
C1/55A1: 69 73        ADC #$73
C1/55A3: 8D 67 C3     STA $C367
C1/55A6: A5 88        LDA $88
C1/55A8: D0 0C        BNE $55B6
C1/55AA: A9 68        LDA #$68
C1/55AC: 85 88        STA $88
C1/55AE: A5 89        LDA $89
C1/55B0: D0 0B        BNE $55BD
C1/55B2: A9 68        LDA #$68
C1/55B4: 80 0A        BRA $55C0
C1/55B6: 18           CLC 
C1/55B7: 69 69        ADC #$69
C1/55B9: 85 88        STA $88
C1/55BB: A5 89        LDA $89
C1/55BD: 18           CLC 
C1/55BE: 69 69        ADC #$69
C1/55C0: 85 89        STA $89
C1/55C2: A5 88        LDA $88
C1/55C4: 8D 63 C3     STA $C363
C1/55C7: A5 89        LDA $89
C1/55C9: 8D 65 C3     STA $C365
C1/55CC: EE 44 CD     INC $CD44
C1/55CF: 60           RTS 
C1/55D0: AD 42 CD     LDA $CD42
C1/55D3: A8           TAY 
C1/55D4: 0A           ASL 
C1/55D5: AA           TAX 
C1/55D6: 9C 6C CD     STZ $CD6C
C1/55D9: 9C 70 CD     STZ $CD70
C1/55DC: AD F8 CD     LDA $CDF8
C1/55DF: D0 65        BNE $5646
C1/55E1: EE 6C CD     INC $CD6C
C1/55E4: EE 70 CD     INC $CD70
C1/55E7: A9 33        LDA #$33
C1/55E9: 8D 6F CD     STA $CD6F
C1/55EC: A9 B3        LDA #$B3
C1/55EE: 8D 73 CD     STA $CD73
C1/55F1: B1 D9        LDA ($D9),Y
C1/55F3: D0 05        BNE $55FA
C1/55F5: 9C 6C CD     STZ $CD6C
C1/55F8: 80 07        BRA $5601
C1/55FA: C5 DD        CMP $DD
C1/55FC: D0 03        BNE $5601
C1/55FE: 9C 70 CD     STZ $CD70
C1/5601: A5 00        LDA $00
C1/5603: 10 47        BPL $564C
C1/5605: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/5608: B1 D3        LDA ($D3),Y
C1/560A: 18           CLC 
C1/560B: 65 DB        ADC $DB
C1/560D: C2 20        REP #$20
C1/560F: 18           CLC 
C1/5610: 7F 8D FF CE  ADC $CEFF8D,X
C1/5614: AA           TAX 
C1/5615: 7B           TDC 
C1/5616: E2 20        SEP #$20
C1/5618: BD 3C 2F     LDA $2F3C,X
C1/561B: 10 06        BPL $5623
C1/561D: 20 CE FB     JSR $FBCE       ; play system sound effect $12
C1/5620: 4C 83 56     JMP $5683
C1/5623: 9C 48 CD     STZ $CD48
C1/5626: DA           PHX 
C1/5627: AD 90 F8     LDA $F890
C1/562A: AA           TAX 
C1/562B: B1 D3        LDA ($D3),Y
C1/562D: 18           CLC 
C1/562E: 65 DB        ADC $DB
C1/5630: 9D B6 41     STA $41B6,X
C1/5633: A9 20        LDA #$20
C1/5635: 0D 91 F8     ORA $F891
C1/5638: 9D B1 41     STA $41B1,X
C1/563B: FA           PLX 
C1/563C: A9 0B        LDA #$0B
C1/563E: 85 88        STA $88
C1/5640: BD BA 2E     LDA $2EBA,X
C1/5643: 4C 0E 51     JMP $510E
C1/5646: 9C 48 CD     STZ $CD48
C1/5649: 4C 73 47     JMP $4773
C1/564C: A5 01        LDA $01
C1/564E: 10 09        BPL $5659
C1/5650: 20 C3 FB     JSR $FBC3       ; play system sound effect $11
C1/5653: 9C 48 CD     STZ $CD48
C1/5656: 4C 73 47     JMP $4773
C1/5659: 20 74 55     JSR $5574
C1/565C: 20 36 55     JSR $5536
C1/565F: A5 01        LDA $01
C1/5661: 29 02        AND #$02
C1/5663: F0 03        BEQ $5668
C1/5665: 4C B5 56     JMP $56B5
C1/5668: A5 01        LDA $01
C1/566A: 29 01        AND #$01
C1/566C: F0 03        BEQ $5671
C1/566E: 4C 84 56     JMP $5684
C1/5671: A5 01        LDA $01
C1/5673: 29 04        AND #$04
C1/5675: F0 03        BEQ $567A
C1/5677: 4C E0 56     JMP $56E0
C1/567A: A5 01        LDA $01
C1/567C: 29 08        AND #$08
C1/567E: F0 03        BEQ $5683
C1/5680: 4C 1A 57     JMP $571A
C1/5683: 60           RTS 
C1/5684: B1 D5        LDA ($D5),Y
C1/5686: C5 D1        CMP $D1
C1/5688: F0 0F        BEQ $5699
C1/568A: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/568D: B1 D3        LDA ($D3),Y
C1/568F: 1A           INC 
C1/5690: 91 D3        STA ($D3),Y
C1/5692: B1 D5        LDA ($D5),Y
C1/5694: 1A           INC 
C1/5695: 91 D5        STA ($D5),Y
C1/5697: 80 19        BRA $56B2
C1/5699: A5 DC        LDA $DC
C1/569B: 38           SEC 
C1/569C: E5 DB        SBC $DB
C1/569E: D1 D3        CMP ($D3),Y
C1/56A0: F0 10        BEQ $56B2
C1/56A2: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/56A5: B1 D3        LDA ($D3),Y
C1/56A7: 38           SEC 
C1/56A8: E5 D1        SBC $D1
C1/56AA: 91 D3        STA ($D3),Y
C1/56AC: 7B           TDC 
C1/56AD: 91 D5        STA ($D5),Y
C1/56AF: 20 E0 56     JSR $56E0
C1/56B2: 4C 36 55     JMP $5536
C1/56B5: B1 D5        LDA ($D5),Y
C1/56B7: F0 0F        BEQ $56C8
C1/56B9: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/56BC: B1 D5        LDA ($D5),Y
C1/56BE: 3A           DEC 
C1/56BF: 91 D5        STA ($D5),Y
C1/56C1: B1 D3        LDA ($D3),Y
C1/56C3: 3A           DEC 
C1/56C4: 91 D3        STA ($D3),Y
C1/56C6: 80 15        BRA $56DD
C1/56C8: B1 D3        LDA ($D3),Y
C1/56CA: F0 11        BEQ $56DD
C1/56CC: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/56CF: B1 D3        LDA ($D3),Y
C1/56D1: 18           CLC 
C1/56D2: 65 D1        ADC $D1
C1/56D4: 91 D3        STA ($D3),Y
C1/56D6: A5 D1        LDA $D1
C1/56D8: 91 D5        STA ($D5),Y
C1/56DA: 20 1A 57     JSR $571A
C1/56DD: 4C 36 55     JMP $5536
C1/56E0: B1 D7        LDA ($D7),Y
C1/56E2: C9 03        CMP #$03
C1/56E4: F0 10        BEQ $56F6
C1/56E6: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/56E9: B1 D3        LDA ($D3),Y
C1/56EB: 18           CLC 
C1/56EC: 65 D2        ADC $D2
C1/56EE: 91 D3        STA ($D3),Y
C1/56F0: B1 D7        LDA ($D7),Y
C1/56F2: 1A           INC 
C1/56F3: 91 D7        STA ($D7),Y
C1/56F5: 60           RTS 
C1/56F6: B1 D9        LDA ($D9),Y
C1/56F8: C5 DD        CMP $DD
C1/56FA: D0 01        BNE $56FD
C1/56FC: 60           RTS 
C1/56FD: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5700: B1 D3        LDA ($D3),Y
C1/5702: 18           CLC 
C1/5703: 65 D2        ADC $D2
C1/5705: 91 D3        STA ($D3),Y
C1/5707: 20 50 57     JSR $5750
C1/570A: A9 03        LDA #$03
C1/570C: 8D 37 CD     STA $CD37
C1/570F: A9 03        LDA #$03
C1/5711: 8D 3A CD     STA $CD3A
C1/5714: A9 0B        LDA #$0B
C1/5716: 8D 3B CD     STA $CD3B
C1/5719: 60           RTS 
C1/571A: B1 D7        LDA ($D7),Y
C1/571C: F0 10        BEQ $572E
C1/571E: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5721: B1 D3        LDA ($D3),Y
C1/5723: 38           SEC 
C1/5724: E5 D2        SBC $D2
C1/5726: 91 D3        STA ($D3),Y
C1/5728: B1 D7        LDA ($D7),Y
C1/572A: 3A           DEC 
C1/572B: 91 D7        STA ($D7),Y
C1/572D: 60           RTS 
C1/572E: B1 D9        LDA ($D9),Y
C1/5730: D0 01        BNE $5733
C1/5732: 60           RTS 
C1/5733: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5736: B1 D3        LDA ($D3),Y
C1/5738: 38           SEC 
C1/5739: E5 D2        SBC $D2
C1/573B: 91 D3        STA ($D3),Y
C1/573D: 20 6C 57     JSR $576C
C1/5740: A9 03        LDA #$03
C1/5742: 8D 37 CD     STA $CD37
C1/5745: A9 04        LDA #$04
C1/5747: 8D 3A CD     STA $CD3A
C1/574A: A9 0B        LDA #$0B
C1/574C: 8D 3B CD     STA $CD3B
C1/574F: 60           RTS 
C1/5750: A9 03        LDA #$03
C1/5752: 85 88        STA $88
C1/5754: B1 D9        LDA ($D9),Y
C1/5756: 1A           INC 
C1/5757: 91 D9        STA ($D9),Y
C1/5759: 20 B1 57     JSR $57B1
C1/575C: AD FA CD     LDA $CDFA
C1/575F: C9 04        CMP #$04
C1/5761: D0 05        BNE $5768
C1/5763: A9 FF        LDA #$FF
C1/5765: 8D FA CD     STA $CDFA
C1/5768: EE FA CD     INC $CDFA
C1/576B: 60           RTS 
C1/576C: 64 88        STZ $88
C1/576E: B1 D9        LDA ($D9),Y
C1/5770: 3A           DEC 
C1/5771: 91 D9        STA ($D9),Y
C1/5773: 20 B1 57     JSR $57B1
C1/5776: AD FA CD     LDA $CDFA
C1/5779: D0 05        BNE $5780
C1/577B: A9 05        LDA #$05
C1/577D: 8D FA CD     STA $CDFA
C1/5780: CE FA CD     DEC $CDFA
C1/5783: 60           RTS 

; [  ]

C1/5784: A5 CF        LDA $CF
C1/5786: F0 08        BEQ $5790
C1/5788: B1 D9        LDA ($D9),Y
C1/578A: 18           CLC 
C1/578B: 65 88        ADC $88
C1/578D: 0A           ASL 
C1/578E: 80 0B        BRA $579B
C1/5790: B1 D9        LDA ($D9),Y
C1/5792: 18           CLC 
C1/5793: 65 88        ADC $88
C1/5795: 85 88        STA $88
C1/5797: 0A           ASL 
C1/5798: 18           CLC 
C1/5799: 65 88        ADC $88
C1/579B: 65 DB        ADC $DB
C1/579D: 85 88        STA $88
C1/579F: 64 89        STZ $89
C1/57A1: C2 20        REP #$20
C1/57A3: BF 8D FF CE  LDA $CEFF8D,X   ; pointers to character battle lists
C1/57A7: 18           CLC 
C1/57A8: 65 88        ADC $88
C1/57AA: 85 88        STA $88
C1/57AC: AA           TAX 
C1/57AD: 7B           TDC 
C1/57AE: E2 20        SEP #$20
C1/57B0: 60           RTS 

; [  ]

C1/57B1: 5A           PHY 
C1/57B2: A2 7B CD     LDX #$CD7B
C1/57B5: 86 BF        STX $BF
C1/57B7: A2 BB CD     LDX #$CDBB
C1/57BA: 86 C1        STX $C1
C1/57BC: 98           TYA             ; Y = character index
C1/57BD: 0A           ASL 
C1/57BE: AA           TAX 
C1/57BF: 20 84 57     JSR $5784
C1/57C2: A5 CF        LDA $CF
C1/57C4: F0 0F        BEQ $57D5
C1/57C6: A0 00 00     LDY #$0000
C1/57C9: 20 4B 58     JSR $584B
C1/57CC: E8           INX 
C1/57CD: 20 4B 58     JSR $584B
C1/57D0: A2 08 00     LDX #$0008
C1/57D3: 80 11        BRA $57E6
C1/57D5: A0 00 00     LDY #$0000
C1/57D8: 20 06 58     JSR $5806
C1/57DB: E8           INX 
C1/57DC: 20 06 58     JSR $5806
C1/57DF: E8           INX 
C1/57E0: 20 06 58     JSR $5806
C1/57E3: A2 07 00     LDX #$0007
C1/57E6: A9 FF        LDA #$FF
C1/57E8: 20 6B 5F     JSR $5F6B
C1/57EB: CA           DEX 
C1/57EC: D0 F8        BNE $57E6
C1/57EE: AD FA CD     LDA $CDFA
C1/57F1: 0A           ASL 
C1/57F2: AA           TAX 
C1/57F3: BF F5 FF CE  LDA $CEFFF5,X
C1/57F7: 8D 75 CD     STA $CD75
C1/57FA: BF F6 FF CE  LDA $CEFFF6,X
C1/57FE: 8D 76 CD     STA $CD76
C1/5801: EE 74 CD     INC $CD74
C1/5804: 7A           PLY 
C1/5805: 60           RTS 

; [  ]

C1/5806: BD 3C 2F     LDA $2F3C,X
C1/5809: 30 04        BMI $580F
C1/580B: A9 00        LDA #$00
C1/580D: 80 02        BRA $5811
C1/580F: A9 04        LDA #$04
C1/5811: 85 C3        STA $C3
C1/5813: BD 34 2D     LDA $2D34,X
C1/5816: C9 FF        CMP #$FF
C1/5818: D0 0F        BNE $5829
C1/581A: DA           PHX 
C1/581B: A2 06 00     LDX #$0006
C1/581E: A9 FF        LDA #$FF
C1/5820: 20 6B 5F     JSR $5F6B
C1/5823: CA           DEX 
C1/5824: D0 F8        BNE $581E
C1/5826: 4C 45 58     JMP $5845
C1/5829: 85 98        STA $98
C1/582B: A9 06        LDA #$06
C1/582D: 85 9A        STA $9A
C1/582F: 20 4B FE     JSR $FE4B
C1/5832: DA           PHX 
C1/5833: A6 9C        LDX $9C
C1/5835: A9 06        LDA #$06
C1/5837: 85 88        STA $88
C1/5839: BF 80 1C D1  LDA $D11C80,X   ; spell names
C1/583D: 20 67 5F     JSR $5F67
C1/5840: E8           INX 
C1/5841: C6 88        DEC $88
C1/5843: D0 F4        BNE $5839
C1/5845: FA           PLX 
C1/5846: A9 FF        LDA #$FF
C1/5848: 4C 6B 5F     JMP $5F6B

; [  ]

C1/584B: BD 3C 2F     LDA $2F3C,X
C1/584E: 30 04        BMI $5854
C1/5850: A9 00        LDA #$00
C1/5852: 80 02        BRA $5856
C1/5854: A9 04        LDA #$04
C1/5856: 85 C3        STA $C3
C1/5858: BD 34 2D     LDA $2D34,X
C1/585B: 38           SEC 
C1/585C: E9 57        SBC #$57
C1/585E: 85 98        STA $98
C1/5860: A9 09        LDA #$09
C1/5862: 85 9A        STA $9A
C1/5864: 20 4B FE     JSR $FE4B
C1/5867: DA           PHX 
C1/5868: A6 9C        LDX $9C
C1/586A: A9 09        LDA #$09
C1/586C: 85 88        STA $88
C1/586E: BF 8A 1E D1  LDA $D11E8A,X   ; short attack names
C1/5872: 20 67 5F     JSR $5F67
C1/5875: E8           INX 
C1/5876: C6 88        DEC $88
C1/5878: D0 F4        BNE $586E
C1/587A: FA           PLX 
C1/587B: A9 FF        LDA #$FF
C1/587D: 4C 6B 5F     JMP $5F6B

; [  ]

C1/5880: AD 42 CD     LDA $CD42
C1/5883: AA           TAX 
C1/5884: BF 84 FF CE  LDA $CEFF84,X
C1/5888: 18           CLC 
C1/5889: 65 88        ADC $88
C1/588B: AA           TAX 
C1/588C: 60           RTS 

; [  ]

C1/588D: DA           PHX 
C1/588E: 85 88        STA $88
C1/5890: 8D D4 CF     STA $CFD4
C1/5893: AD 8D F8     LDA $F88D
C1/5896: 8D D3 CF     STA $CFD3
C1/5899: AD 8C F8     LDA $F88C
C1/589C: 30 0D        BMI $58AB
C1/589E: A5 88        LDA $88
C1/58A0: 8D 8D F8     STA $F88D
C1/58A3: A9 C0        LDA #$C0
C1/58A5: 8D 8C F8     STA $F88C
C1/58A8: FA           PLX 
C1/58A9: 18           CLC 
C1/58AA: 60           RTS 
C1/58AB: 29 40        AND #$40
C1/58AD: D0 42        BNE $58F1
C1/58AF: 20 80 58     JSR $5880
C1/58B2: AD D3 CF     LDA $CFD3
C1/58B5: A8           TAY 
C1/58B6: BD AC 37     LDA $37AC,X
C1/58B9: F0 16        BEQ $58D1
C1/58BB: D9 34 27     CMP $2734,Y
C1/58BE: F0 11        BEQ $58D1
C1/58C0: B9 34 27     LDA $2734,Y
C1/58C3: F0 0C        BEQ $58D1
C1/58C5: B9 34 28     LDA $2834,Y
C1/58C8: C9 01        CMP #$01
C1/58CA: F0 05        BEQ $58D1
C1/58CC: AD D5 CF     LDA $CFD5
C1/58CF: D0 58        BNE $5929
C1/58D1: A5 88        LDA $88
C1/58D3: 20 D0 5A     JSR $5AD0
C1/58D6: B9 34 27     LDA $2734,Y
C1/58D9: 8D D0 D0     STA $D0D0
C1/58DC: B9 34 2B     LDA $2B34,Y
C1/58DF: 8D D1 D0     STA $D0D1
C1/58E2: B9 34 2C     LDA $2C34,Y
C1/58E5: 8D D2 D0     STA $D0D2
C1/58E8: 20 F9 5A     JSR $5AF9
C1/58EB: 90 3C        BCC $5929
C1/58ED: A9 18        LDA #$18
C1/58EF: 80 09        BRA $58FA
C1/58F1: AD 8D F8     LDA $F88D
C1/58F4: C5 88        CMP $88
C1/58F6: F0 1F        BEQ $5917
C1/58F8: A9 15        LDA #$15
C1/58FA: 8D 39 CD     STA $CD39
C1/58FD: A9 05        LDA #$05
C1/58FF: 8D 3A CD     STA $CD3A
C1/5902: A9 11        LDA #$11
C1/5904: 8D 3B CD     STA $CD3B
C1/5907: A9 05        LDA #$05
C1/5909: 8D 3C CD     STA $CD3C
C1/590C: A9 08        LDA #$08
C1/590E: 8D 3D CD     STA $CD3D
C1/5911: 20 93 5B     JSR $5B93
C1/5914: FA           PLX 
C1/5915: 18           CLC 
C1/5916: 60           RTS 
C1/5917: 20 80 58     JSR $5880
C1/591A: 20 86 5B     JSR $5B86
C1/591D: BD B6 37     LDA $37B6,X
C1/5920: 25 92        AND $92
C1/5922: D0 05        BNE $5929
C1/5924: BD AC 37     LDA $37AC,X
C1/5927: 10 09        BPL $5932
C1/5929: 20 CE FB     JSR $FBCE       ; play system sound effect $12
C1/592C: 20 93 5B     JSR $5B93
C1/592F: FA           PLX 
C1/5930: 18           CLC 
C1/5931: 60           RTS 
C1/5932: 5A           PHY 
C1/5933: AD 90 F8     LDA $F890
C1/5936: A8           TAY 
C1/5937: AD D4 CF     LDA $CFD4
C1/593A: 99 B6 41     STA $41B6,Y
C1/593D: 7A           PLY 
C1/593E: A9 08        LDA #$08
C1/5940: 85 88        STA $88
C1/5942: BD B2 37     LDA $37B2,X
C1/5945: 20 0E 51     JSR $510E
C1/5948: 20 99 5B     JSR $5B99
C1/594B: FA           PLX 
C1/594C: 38           SEC 
C1/594D: 60           RTS 
C1/594E: DA           PHX 
C1/594F: 85 88        STA $88
C1/5951: 8D D4 CF     STA $CFD4
C1/5954: AD 8D F8     LDA $F88D
C1/5957: 8D D3 CF     STA $CFD3
C1/595A: AD 4F DB     LDA $DB4F
C1/595D: D0 09        BNE $5968
C1/595F: AD 4E DB     LDA $DB4E
C1/5962: F0 1E        BEQ $5982
C1/5964: C9 01        CMP #$01
C1/5966: D0 05        BNE $596D
C1/5968: A5 88        LDA $88
C1/596A: 4C 47 5A     JMP $5A47
C1/596D: AD 8C F8     LDA $F88C
C1/5970: 30 3A        BMI $59AC
C1/5972: DA           PHX 
C1/5973: AD D4 CF     LDA $CFD4
C1/5976: AA           TAX 
C1/5977: BD 34 2B     LDA $2B34,X
C1/597A: FA           PLX 
C1/597B: 29 02        AND #$02
C1/597D: F0 03        BEQ $5982
C1/597F: 4C 97 5A     JMP $5A97
C1/5982: AD 8C F8     LDA $F88C
C1/5985: 30 25        BMI $59AC
C1/5987: A5 88        LDA $88
C1/5989: 8D 8D F8     STA $F88D
C1/598C: A9 80        LDA #$80
C1/598E: 8D 8C F8     STA $F88C
C1/5991: AD 49 CD     LDA $CD49
C1/5994: 18           CLC 
C1/5995: 69 04        ADC #$04
C1/5997: 8D 3C CF     STA $CF3C
C1/599A: 9C 3D CF     STZ $CF3D
C1/599D: AD 4A CD     LDA $CD4A
C1/59A0: 8D 3E CF     STA $CF3E
C1/59A3: 9C 3F CF     STZ $CF3F
C1/59A6: EE 3B CF     INC $CF3B
C1/59A9: FA           PLX 
C1/59AA: 18           CLC 
C1/59AB: 60           RTS 
C1/59AC: 29 40        AND #$40
C1/59AE: F0 4F        BEQ $59FF
C1/59B0: AD 42 CD     LDA $CD42
C1/59B3: AA           TAX 
C1/59B4: BF 84 FF CE  LDA $CEFF84,X
C1/59B8: 18           CLC 
C1/59B9: 6D D3 CF     ADC $CFD3
C1/59BC: A8           TAY 
C1/59BD: A5 88        LDA $88
C1/59BF: AA           TAX 
C1/59C0: B9 AC 37     LDA $37AC,Y
C1/59C3: F0 16        BEQ $59DB
C1/59C5: DD 34 27     CMP $2734,X
C1/59C8: F0 11        BEQ $59DB
C1/59CA: BD 34 28     LDA $2834,X
C1/59CD: F0 0C        BEQ $59DB
C1/59CF: C9 01        CMP #$01
C1/59D1: F0 08        BEQ $59DB
C1/59D3: AD D5 CF     LDA $CFD5
C1/59D6: F0 03        BEQ $59DB
C1/59D8: 4C 91 5A     JMP $5A91
C1/59DB: AD D3 CF     LDA $CFD3
C1/59DE: 20 D0 5A     JSR $5AD0
C1/59E1: BD 34 27     LDA $2734,X
C1/59E4: 8D D0 D0     STA $D0D0
C1/59E7: BD 34 2B     LDA $2B34,X
C1/59EA: 8D D1 D0     STA $D0D1
C1/59ED: BD 34 2C     LDA $2C34,X
C1/59F0: 8D D2 D0     STA $D0D2
C1/59F3: 20 F9 5A     JSR $5AF9
C1/59F6: B0 03        BCS $59FB
C1/59F8: 4C 91 5A     JMP $5A91
C1/59FB: A9 16        LDA #$16
C1/59FD: 80 2B        BRA $5A2A
C1/59FF: AD 4E DB     LDA $DB4E
C1/5A02: C9 02        CMP #$02
C1/5A04: D0 1B        BNE $5A21
C1/5A06: AD 90 F8     LDA $F890
C1/5A09: AA           TAX 
C1/5A0A: A9 40        LDA #$40
C1/5A0C: 0D 91 F8     ORA $F891
C1/5A0F: 9D B1 41     STA $41B1,X
C1/5A12: AD D3 CF     LDA $CFD3
C1/5A15: 9D B6 41     STA $41B6,X
C1/5A18: A9 07        LDA #$07
C1/5A1A: 8D 90 F8     STA $F890
C1/5A1D: A5 88        LDA $88
C1/5A1F: 80 26        BRA $5A47
C1/5A21: AD 8D F8     LDA $F88D
C1/5A24: C5 88        CMP $88
C1/5A26: F0 1F        BEQ $5A47
C1/5A28: A9 17        LDA #$17
C1/5A2A: 8D 39 CD     STA $CD39
C1/5A2D: A9 05        LDA #$05
C1/5A2F: 8D 3A CD     STA $CD3A
C1/5A32: A9 11        LDA #$11
C1/5A34: 8D 3B CD     STA $CD3B
C1/5A37: A9 05        LDA #$05
C1/5A39: 8D 3C CD     STA $CD3C
C1/5A3C: A9 07        LDA #$07
C1/5A3E: 8D 3D CD     STA $CD3D
C1/5A41: 20 93 5B     JSR $5B93
C1/5A44: FA           PLX 
C1/5A45: 18           CLC 
C1/5A46: 60           RTS 
C1/5A47: AA           TAX 
C1/5A48: AD 4F DB     LDA $DB4F
C1/5A4B: F0 04        BEQ $5A51
C1/5A4D: A9 40        LDA #$40
C1/5A4F: 80 1E        BRA $5A6F
C1/5A51: AD 4E DB     LDA $DB4E
C1/5A54: F0 24        BEQ $5A7A
C1/5A56: C9 01        CMP #$01
C1/5A58: F0 13        BEQ $5A6D
C1/5A5A: AD D3 CF     LDA $CFD3
C1/5A5D: CD D4 CF     CMP $CFD4
C1/5A60: D0 07        BNE $5A69
C1/5A62: BD 34 28     LDA $2834,X
C1/5A65: C9 02        CMP #$02
C1/5A67: 90 2E        BCC $5A97
C1/5A69: A9 02        LDA #$02
C1/5A6B: 80 02        BRA $5A6F
C1/5A6D: A9 10        LDA #$10
C1/5A6F: 85 92        STA $92
C1/5A71: BD 34 2B     LDA $2B34,X
C1/5A74: 25 92        AND $92
C1/5A76: F0 22        BEQ $5A9A
C1/5A78: 80 1D        BRA $5A97
C1/5A7A: 20 86 5B     JSR $5B86
C1/5A7D: BD 34 2C     LDA $2C34,X
C1/5A80: 25 92        AND $92
C1/5A82: D0 0D        BNE $5A91
C1/5A84: BD 34 27     LDA $2734,X
C1/5A87: C9 E0        CMP #$E0
C1/5A89: 90 06        BCC $5A91
C1/5A8B: 80 0D        BRA $5A9A
C1/5A8D: 25 92        AND $92
C1/5A8F: F0 09        BEQ $5A9A
C1/5A91: 20 CE FB     JSR $FBCE       ; play system sound effect $12
C1/5A94: 20 93 5B     JSR $5B93
C1/5A97: FA           PLX 
C1/5A98: 18           CLC 
C1/5A99: 60           RTS 
C1/5A9A: 5A           PHY 
C1/5A9B: AD 90 F8     LDA $F890
C1/5A9E: A8           TAY 
C1/5A9F: AD D4 CF     LDA $CFD4
C1/5AA2: 99 B6 41     STA $41B6,Y
C1/5AA5: 7A           PLY 
C1/5AA6: A9 07        LDA #$07
C1/5AA8: 85 88        STA $88
C1/5AAA: AD 4F DB     LDA $DB4F
C1/5AAD: F0 04        BEQ $5AB3
C1/5AAF: A9 28        LDA #$28
C1/5AB1: 80 14        BRA $5AC7
C1/5AB3: AD 4E DB     LDA $DB4E
C1/5AB6: F0 0C        BEQ $5AC4
C1/5AB8: C9 01        CMP #$01
C1/5ABA: F0 04        BEQ $5AC0
C1/5ABC: A9 30        LDA #$30
C1/5ABE: 80 07        BRA $5AC7
C1/5AC0: A9 00        LDA #$00
C1/5AC2: 80 03        BRA $5AC7
C1/5AC4: BD 34 2A     LDA $2A34,X
C1/5AC7: 20 0E 51     JSR $510E
C1/5ACA: 20 99 5B     JSR $5B99
C1/5ACD: FA           PLX 
C1/5ACE: 38           SEC 
C1/5ACF: 60           RTS 
C1/5AD0: DA           PHX 
C1/5AD1: 5A           PHY 
C1/5AD2: 29 01        AND #$01
C1/5AD4: 49 01        EOR #$01
C1/5AD6: 85 8C        STA $8C
C1/5AD8: AD 42 CD     LDA $CD42
C1/5ADB: AA           TAX 
C1/5ADC: BF 84 FF CE  LDA $CEFF84,X
C1/5AE0: 18           CLC 
C1/5AE1: 65 8C        ADC $8C
C1/5AE3: A8           TAY 
C1/5AE4: B9 AC 37     LDA $37AC,Y
C1/5AE7: 8D CA D0     STA $D0CA
C1/5AEA: B9 B4 37     LDA $37B4,Y
C1/5AED: 8D CB D0     STA $D0CB
C1/5AF0: B9 B6 37     LDA $37B6,Y
C1/5AF3: 8D CC D0     STA $D0CC
C1/5AF6: 7A           PLY 
C1/5AF7: FA           PLX 
C1/5AF8: 60           RTS 
C1/5AF9: DA           PHX 
C1/5AFA: 20 86 5B     JSR $5B86
C1/5AFD: AD CA D0     LDA $D0CA
C1/5B00: D0 03        BNE $5B05
C1/5B02: 9C CC D0     STZ $D0CC
C1/5B05: AD D0 D0     LDA $D0D0
C1/5B08: D0 03        BNE $5B0D
C1/5B0A: 9C D2 D0     STZ $D0D2
C1/5B0D: AD CC D0     LDA $D0CC
C1/5B10: 0D D2 D0     ORA $D0D2
C1/5B13: 25 92        AND $92
C1/5B15: F0 03        BEQ $5B1A
C1/5B17: FA           PLX 
C1/5B18: 18           CLC 
C1/5B19: 60           RTS 
C1/5B1A: AD CA D0     LDA $D0CA
C1/5B1D: 85 88        STA $88
C1/5B1F: AD CB D0     LDA $D0CB
C1/5B22: 85 8A        STA $8A
C1/5B24: 20 65 5B     JSR $5B65
C1/5B27: 85 8C        STA $8C
C1/5B29: AD D0 D0     LDA $D0D0
C1/5B2C: 85 88        STA $88
C1/5B2E: AD D1 D0     LDA $D0D1
C1/5B31: 85 8A        STA $8A
C1/5B33: 20 65 5B     JSR $5B65
C1/5B36: 85 8D        STA $8D
C1/5B38: A5 8C        LDA $8C
C1/5B3A: 05 8D        ORA $8D
C1/5B3C: C9 FF        CMP #$FF
C1/5B3E: F0 D7        BEQ $5B17
C1/5B40: 29 01        AND #$01
C1/5B42: D0 1E        BNE $5B62
C1/5B44: A6 8C        LDX $8C
C1/5B46: E0 02 08     CPX #$0802
C1/5B49: F0 17        BEQ $5B62
C1/5B4B: E0 08 02     CPX #$0208
C1/5B4E: F0 12        BEQ $5B62
C1/5B50: AD 42 CD     LDA $CD42
C1/5B53: AA           TAX 
C1/5B54: BD CE CF     LDA $CFCE,X
C1/5B57: 29 01        AND #$01
C1/5B59: F0 BC        BEQ $5B17
C1/5B5B: A6 8C        LDX $8C
C1/5B5D: E0 02 02     CPX #$0202
C1/5B60: D0 B5        BNE $5B17
C1/5B62: FA           PLX 
C1/5B63: 38           SEC 
C1/5B64: 60           RTS 
C1/5B65: A5 88        LDA $88
C1/5B67: D0 03        BNE $5B6C
C1/5B69: A9 01        LDA #$01
C1/5B6B: 60           RTS 
C1/5B6C: A5 88        LDA $88
C1/5B6E: 30 0C        BMI $5B7C
C1/5B70: A5 8A        LDA $8A
C1/5B72: 29 04        AND #$04
C1/5B74: D0 03        BNE $5B79
C1/5B76: A9 02        LDA #$02
C1/5B78: 60           RTS 
C1/5B79: A9 04        LDA #$04
C1/5B7B: 60           RTS 
C1/5B7C: C9 E0        CMP #$E0
C1/5B7E: 90 03        BCC $5B83
C1/5B80: A9 FF        LDA #$FF
C1/5B82: 60           RTS 
C1/5B83: A9 08        LDA #$08
C1/5B85: 60           RTS 
C1/5B86: DA           PHX 
C1/5B87: AD 42 CD     LDA $CD42
C1/5B8A: AA           TAX 
C1/5B8B: BF 80 FF CE  LDA $CEFF80,X
C1/5B8F: 85 92        STA $92
C1/5B91: FA           PLX 
C1/5B92: 60           RTS 
C1/5B93: 9C 8C F8     STZ $F88C
C1/5B96: 9C 8E F8     STZ $F88E
C1/5B99: 9C 3B CF     STZ $CF3B
C1/5B9C: 9C 4C CD     STZ $CD4C
C1/5B9F: 9C 50 CD     STZ $CD50
C1/5BA2: 60           RTS 
C1/5BA3: A9 03        LDA #$03
C1/5BA5: 8D 4B CD     STA $CD4B
C1/5BA8: AD 42 CD     LDA $CD42
C1/5BAB: AA           TAX 
C1/5BAC: AD F8 CD     LDA $CDF8
C1/5BAF: D0 58        BNE $5C09
C1/5BB1: A9 01        LDA #$01
C1/5BB3: 9D 3D 04     STA $043D,X
C1/5BB6: A5 00        LDA $00
C1/5BB8: 10 20        BPL $5BDA
C1/5BBA: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/5BBD: BD 35 04     LDA $0435,X
C1/5BC0: 20 8D 58     JSR $588D
C1/5BC3: 90 7F        BCC $5C44
C1/5BC5: DA           PHX 
C1/5BC6: AD 90 F8     LDA $F890
C1/5BC9: AA           TAX 
C1/5BCA: A9 10        LDA #$10
C1/5BCC: 0D 91 F8     ORA $F891
C1/5BCF: 9D B1 41     STA $41B1,X
C1/5BD2: FA           PLX 
C1/5BD3: 20 93 5B     JSR $5B93
C1/5BD6: 9C 48 CD     STZ $CD48
C1/5BD9: 60           RTS 
C1/5BDA: A5 01        LDA $01
C1/5BDC: 10 16        BPL $5BF4
C1/5BDE: 20 C3 FB     JSR $FBC3       ; play system sound effect $11
C1/5BE1: AD 8C F8     LDA $F88C
C1/5BE4: 10 06        BPL $5BEC
C1/5BE6: 20 93 5B     JSR $5B93
C1/5BE9: 4C 44 5C     JMP $5C44
C1/5BEC: A9 01        LDA #$01
C1/5BEE: 9D 39 04     STA $0439,X
C1/5BF1: 4C 09 5C     JMP $5C09
C1/5BF4: A5 01        LDA $01
C1/5BF6: 29 04        AND #$04
C1/5BF8: F0 15        BEQ $5C0F
C1/5BFA: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5BFD: BD 35 04     LDA $0435,X
C1/5C00: 9D 45 04     STA $0445,X
C1/5C03: 9D 41 04     STA $0441,X
C1/5C06: 9E 3D 04     STZ $043D,X
C1/5C09: 9C 48 CD     STZ $CD48
C1/5C0C: 4C A3 47     JMP $47A3
C1/5C0F: A5 01        LDA $01
C1/5C11: 29 02        AND #$02
C1/5C13: F0 0D        BEQ $5C22
C1/5C15: BD 35 04     LDA $0435,X
C1/5C18: F0 2A        BEQ $5C44
C1/5C1A: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5C1D: DE 35 04     DEC $0435,X
C1/5C20: 80 22        BRA $5C44
C1/5C22: A5 01        LDA $01
C1/5C24: 29 01        AND #$01
C1/5C26: F0 1C        BEQ $5C44
C1/5C28: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5C2B: BD 35 04     LDA $0435,X
C1/5C2E: F0 11        BEQ $5C41
C1/5C30: A9 00        LDA #$00
C1/5C32: 9D 45 04     STA $0445,X
C1/5C35: 9D 41 04     STA $0441,X
C1/5C38: 9C 48 CD     STZ $CD48
C1/5C3B: 9E 3D 04     STZ $043D,X
C1/5C3E: 4C A3 47     JMP $47A3
C1/5C41: FE 35 04     INC $0435,X
C1/5C44: BD 35 04     LDA $0435,X
C1/5C47: 0A           ASL 
C1/5C48: AA           TAX 
C1/5C49: BF 5B 52 C1  LDA $C1525B,X
C1/5C4D: 8D 49 CD     STA $CD49
C1/5C50: BF 5C 52 C1  LDA $C1525C,X
C1/5C54: 8D 4A CD     STA $CD4A
C1/5C57: A9 01        LDA #$01
C1/5C59: 8D 48 CD     STA $CD48
C1/5C5C: A9 33        LDA #$33
C1/5C5E: 8D 4B CD     STA $CD4B
C1/5C61: 8D 53 CD     STA $CD53
C1/5C64: 9C 50 CD     STZ $CD50
C1/5C67: AD 8C F8     LDA $F88C
C1/5C6A: 29 40        AND #$40
C1/5C6C: F0 19        BEQ $5C87
C1/5C6E: AD 8D F8     LDA $F88D
C1/5C71: 0A           ASL 
C1/5C72: AA           TAX 
C1/5C73: BF 5B 52 C1  LDA $C1525B,X
C1/5C77: 18           CLC 
C1/5C78: 69 04        ADC #$04
C1/5C7A: 8D 51 CD     STA $CD51
C1/5C7D: BF 5C 52 C1  LDA $C1525C,X
C1/5C81: 8D 52 CD     STA $CD52
C1/5C84: EE 50 CD     INC $CD50
C1/5C87: 60           RTS 
C1/5C88: AD 42 CD     LDA $CD42
C1/5C8B: AA           TAX 
C1/5C8C: 9C 6C CD     STZ $CD6C
C1/5C8F: 9C 70 CD     STZ $CD70
C1/5C92: AD F8 CD     LDA $CDF8
C1/5C95: D0 6C        BNE $5D03
C1/5C97: BD 39 04     LDA $0439,X
C1/5C9A: D0 67        BNE $5D03
C1/5C9C: EE 6C CD     INC $CD6C
C1/5C9F: EE 70 CD     INC $CD70
C1/5CA2: A9 03        LDA #$03
C1/5CA4: 8D 6F CD     STA $CD6F
C1/5CA7: A9 83        LDA #$83
C1/5CA9: 8D 73 CD     STA $CD73
C1/5CAC: BD 4D 04     LDA $044D,X
C1/5CAF: C9 7C        CMP #$7C
C1/5CB1: D0 03        BNE $5CB6
C1/5CB3: 9C 70 CD     STZ $CD70
C1/5CB6: AD C3 CF     LDA $CFC3
C1/5CB9: F0 06        BEQ $5CC1
C1/5CBB: 7B           TDC 
C1/5CBC: 9D 3D 04     STA $043D,X
C1/5CBF: 80 0B        BRA $5CCC
C1/5CC1: BD 3D 04     LDA $043D,X
C1/5CC4: F0 06        BEQ $5CCC
C1/5CC6: 9C 48 CD     STZ $CD48
C1/5CC9: 4C 89 47     JMP $4789
C1/5CCC: 20 11 55     JSR $5511
C1/5CCF: A5 00        LDA $00
C1/5CD1: 10 21        BPL $5CF4
C1/5CD3: 20 B8 FB     JSR $FBB8       ; play system sound effect $11
C1/5CD6: BD 41 04     LDA $0441,X
C1/5CD9: 20 4E 59     JSR $594E
C1/5CDC: 90 15        BCC $5CF3
C1/5CDE: DA           PHX 
C1/5CDF: AD 90 F8     LDA $F890
C1/5CE2: AA           TAX 
C1/5CE3: A9 40        LDA #$40
C1/5CE5: 0D 91 F8     ORA $F891
C1/5CE8: 9D B1 41     STA $41B1,X
C1/5CEB: FA           PLX 
C1/5CEC: 20 93 5B     JSR $5B93
C1/5CEF: 9C 48 CD     STZ $CD48
C1/5CF2: 60           RTS 
C1/5CF3: 60           RTS 
C1/5CF4: A5 01        LDA $01
C1/5CF6: 10 14        BPL $5D0C
C1/5CF8: 20 C3 FB     JSR $FBC3       ; play system sound effect $11
C1/5CFB: AD 8C F8     LDA $F88C
C1/5CFE: 10 03        BPL $5D03
C1/5D00: 4C 93 5B     JMP $5B93
C1/5D03: 9C 48 CD     STZ $CD48
C1/5D06: 9E 39 04     STZ $0439,X
C1/5D09: 4C FE 47     JMP $47FE
C1/5D0C: A5 01        LDA $01
C1/5D0E: 29 02        AND #$02
C1/5D10: F0 03        BEQ $5D15
C1/5D12: 4C 31 5D     JMP $5D31
C1/5D15: A5 01        LDA $01
C1/5D17: 29 01        AND #$01
C1/5D19: F0 03        BEQ $5D1E
C1/5D1B: 4C 66 5D     JMP $5D66
C1/5D1E: A5 01        LDA $01
C1/5D20: 29 04        AND #$04
C1/5D22: F0 03        BEQ $5D27
C1/5D24: 4C E0 5E     JMP $5EE0
C1/5D27: A5 01        LDA $01
C1/5D29: 29 08        AND #$08
C1/5D2B: F0 03        BEQ $5D30
C1/5D2D: 4C 8C 5D     JMP $5D8C
C1/5D30: 60           RTS 
C1/5D31: BD 45 04     LDA $0445,X
C1/5D34: F0 0B        BEQ $5D41
C1/5D36: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5D39: DE 41 04     DEC $0441,X
C1/5D3C: DE 45 04     DEC $0445,X
C1/5D3F: 80 22        BRA $5D63
C1/5D41: BD 41 04     LDA $0441,X
C1/5D44: D0 14        BNE $5D5A
C1/5D46: AD C3 CF     LDA $CFC3
C1/5D49: F0 01        BEQ $5D4C
C1/5D4B: 60           RTS 
C1/5D4C: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5D4F: 9C 48 CD     STZ $CD48
C1/5D52: A9 01        LDA #$01
C1/5D54: 9D 35 04     STA $0435,X
C1/5D57: 4C 89 47     JMP $4789
C1/5D5A: FE 41 04     INC $0441,X
C1/5D5D: FE 45 04     INC $0445,X
C1/5D60: 20 8C 5D     JSR $5D8C
C1/5D63: 4C 11 55     JMP $5511
C1/5D66: BD 45 04     LDA $0445,X
C1/5D69: D0 0B        BNE $5D76
C1/5D6B: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5D6E: FE 41 04     INC $0441,X
C1/5D71: FE 45 04     INC $0445,X
C1/5D74: 80 13        BRA $5D89
C1/5D76: BD 41 04     LDA $0441,X
C1/5D79: C9 FF        CMP #$FF
C1/5D7B: F0 0C        BEQ $5D89
C1/5D7D: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5D80: DE 41 04     DEC $0441,X
C1/5D83: 9E 45 04     STZ $0445,X
C1/5D86: 20 E0 5E     JSR $5EE0
C1/5D89: 4C 11 55     JMP $5511
C1/5D8C: BD 49 04     LDA $0449,X
C1/5D8F: F0 0D        BEQ $5D9E
C1/5D91: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5D94: DE 49 04     DEC $0449,X
C1/5D97: DE 41 04     DEC $0441,X
C1/5D9A: DE 41 04     DEC $0441,X
C1/5D9D: 60           RTS 
C1/5D9E: BD 4D 04     LDA $044D,X
C1/5DA1: D0 15        BNE $5DB8
C1/5DA3: AD C3 CF     LDA $CFC3
C1/5DA6: F0 01        BEQ $5DA9
C1/5DA8: 60           RTS 
C1/5DA9: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5DAC: 9C 48 CD     STZ $CD48
C1/5DAF: BD 45 04     LDA $0445,X
C1/5DB2: 9D 35 04     STA $0435,X
C1/5DB5: 4C 89 47     JMP $4789
C1/5DB8: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5DBB: DE 41 04     DEC $0441,X
C1/5DBE: DE 41 04     DEC $0441,X
C1/5DC1: 20 D4 5D     JSR $5DD4
C1/5DC4: A9 03        LDA #$03
C1/5DC6: 8D 37 CD     STA $CD37
C1/5DC9: A9 04        LDA #$04
C1/5DCB: 8D 3A CD     STA $CD3A
C1/5DCE: A9 07        LDA #$07
C1/5DD0: 8D 3B CD     STA $CD3B
C1/5DD3: 60           RTS 
C1/5DD4: 64 88        STZ $88
C1/5DD6: DE 4D 04     DEC $044D,X
C1/5DD9: 20 04 5E     JSR $5E04
C1/5DDC: AD FA CD     LDA $CDFA
C1/5DDF: D0 05        BNE $5DE6
C1/5DE1: A9 05        LDA #$05
C1/5DE3: 8D FA CD     STA $CDFA
C1/5DE6: CE FA CD     DEC $CDFA
C1/5DE9: 60           RTS 
C1/5DEA: A9 03        LDA #$03
C1/5DEC: 85 88        STA $88
C1/5DEE: FE 4D 04     INC $044D,X
C1/5DF1: 20 04 5E     JSR $5E04
C1/5DF4: AD FA CD     LDA $CDFA
C1/5DF7: C9 04        CMP #$04
C1/5DF9: D0 05        BNE $5E00
C1/5DFB: A9 FF        LDA #$FF
C1/5DFD: 8D FA CD     STA $CDFA
C1/5E00: EE FA CD     INC $CDFA
C1/5E03: 60           RTS 
C1/5E04: DA           PHX 
C1/5E05: 20 86 5B     JSR $5B86
C1/5E08: A0 7B CD     LDY #$CD7B
C1/5E0B: 84 BF        STY $BF
C1/5E0D: A0 BB CD     LDY #$CDBB
C1/5E10: 84 C1        STY $C1
C1/5E12: 7B           TDC 
C1/5E13: A8           TAY 
C1/5E14: BD 4D 04     LDA $044D,X
C1/5E17: 18           CLC 
C1/5E18: 65 88        ADC $88
C1/5E1A: 0A           ASL 
C1/5E1B: AA           TAX 
C1/5E1C: 20 3B 5E     JSR $5E3B
C1/5E1F: E8           INX 
C1/5E20: 20 3B 5E     JSR $5E3B
C1/5E23: AD FA CD     LDA $CDFA
C1/5E26: 0A           ASL 
C1/5E27: AA           TAX 
C1/5E28: BF F5 FF CE  LDA $CEFFF5,X
C1/5E2C: 8D 75 CD     STA $CD75
C1/5E2F: BF F6 FF CE  LDA $CEFFF6,X
C1/5E33: 8D 76 CD     STA $CD76
C1/5E36: EE 74 CD     INC $CD74
C1/5E39: FA           PLX 
C1/5E3A: 60           RTS 
C1/5E3B: DA           PHX 
C1/5E3C: A9 FF        LDA #$FF
C1/5E3E: 20 6B 5F     JSR $5F6B
C1/5E41: A9 FF        LDA #$FF
C1/5E43: 20 6B 5F     JSR $5F6B
C1/5E46: AD 4F DB     LDA $DB4F
C1/5E49: F0 09        BEQ $5E54
C1/5E4B: BD 34 2B     LDA $2B34,X
C1/5E4E: 29 40        AND #$40
C1/5E50: F0 28        BEQ $5E7A
C1/5E52: 80 22        BRA $5E76
C1/5E54: AD 4E DB     LDA $DB4E
C1/5E57: F0 16        BEQ $5E6F
C1/5E59: C9 01        CMP #$01
C1/5E5B: F0 09        BEQ $5E66
C1/5E5D: BD 34 2B     LDA $2B34,X
C1/5E60: 29 02        AND #$02
C1/5E62: F0 16        BEQ $5E7A
C1/5E64: 80 10        BRA $5E76
C1/5E66: BD 34 2B     LDA $2B34,X
C1/5E69: 29 10        AND #$10
C1/5E6B: F0 0D        BEQ $5E7A
C1/5E6D: 80 07        BRA $5E76
C1/5E6F: BD 34 2C     LDA $2C34,X
C1/5E72: 25 92        AND $92
C1/5E74: F0 04        BEQ $5E7A
C1/5E76: A9 04        LDA #$04
C1/5E78: 80 02        BRA $5E7C
C1/5E7A: A9 00        LDA #$00
C1/5E7C: 85 C3        STA $C3
C1/5E7E: BD 34 27     LDA $2734,X
C1/5E81: 85 98        STA $98
C1/5E83: A9 09        LDA #$09
C1/5E85: 85 9A        STA $9A
C1/5E87: 20 4B FE     JSR $FE4B
C1/5E8A: DA           PHX 
C1/5E8B: A6 9C        LDX $9C
C1/5E8D: A9 09        LDA #$09
C1/5E8F: 85 88        STA $88
C1/5E91: BF 80 13 D1  LDA $D11380,X   ; item names
C1/5E95: 20 67 5F     JSR $5F67
C1/5E98: E8           INX 
C1/5E99: C6 88        DEC $88
C1/5E9B: D0 F4        BNE $5E91
C1/5E9D: FA           PLX 
C1/5E9E: BD 34 27     LDA $2734,X
C1/5EA1: F0 04        BEQ $5EA7
C1/5EA3: A9 CF        LDA #$CF
C1/5EA5: 80 02        BRA $5EA9
C1/5EA7: A9 FF        LDA #$FF
C1/5EA9: 20 6B 5F     JSR $5F6B
C1/5EAC: 64 88        STZ $88
C1/5EAE: BD 34 28     LDA $2834,X
C1/5EB1: 38           SEC 
C1/5EB2: E9 0A        SBC #$0A
C1/5EB4: 90 05        BCC $5EBB
C1/5EB6: E6 88        INC $88
C1/5EB8: 4C B1 5E     JMP $5EB1
C1/5EBB: 18           CLC 
C1/5EBC: 69 0A        ADC #$0A
C1/5EBE: 85 89        STA $89
C1/5EC0: A5 88        LDA $88
C1/5EC2: D0 02        BNE $5EC6
C1/5EC4: A9 AC        LDA #$AC
C1/5EC6: 18           CLC 
C1/5EC7: 69 53        ADC #$53
C1/5EC9: 20 6B 5F     JSR $5F6B
C1/5ECC: A5 89        LDA $89
C1/5ECE: 05 88        ORA $88
C1/5ED0: D0 04        BNE $5ED6
C1/5ED2: A9 FF        LDA #$FF
C1/5ED4: 80 05        BRA $5EDB
C1/5ED6: A5 89        LDA $89
C1/5ED8: 18           CLC 
C1/5ED9: 69 53        ADC #$53
C1/5EDB: 20 6B 5F     JSR $5F6B
C1/5EDE: FA           PLX 
C1/5EDF: 60           RTS 
C1/5EE0: BD 49 04     LDA $0449,X
C1/5EE3: C9 03        CMP #$03
C1/5EE5: F0 0D        BEQ $5EF4
C1/5EE7: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5EEA: FE 41 04     INC $0441,X
C1/5EED: FE 41 04     INC $0441,X
C1/5EF0: FE 49 04     INC $0449,X
C1/5EF3: 60           RTS 
C1/5EF4: BD 4D 04     LDA $044D,X
C1/5EF7: C9 7C        CMP #$7C
C1/5EF9: F0 1B        BEQ $5F16
C1/5EFB: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/5EFE: FE 41 04     INC $0441,X
C1/5F01: FE 41 04     INC $0441,X
C1/5F04: 20 EA 5D     JSR $5DEA
C1/5F07: A9 03        LDA #$03
C1/5F09: 8D 37 CD     STA $CD37
C1/5F0C: A9 03        LDA #$03
C1/5F0E: 8D 3A CD     STA $CD3A
C1/5F11: A9 07        LDA #$07
C1/5F13: 8D 3B CD     STA $CD3B
C1/5F16: 60           RTS 

; menu for each battle command
C1/5F17: 00 0A 0C 00 00 00 00 00 00 00 00 00 00 00 00 00
C1/5F27: 00 0F 00 00 00 00 00 00 00 00 00 00 00 00 00 0D
C1/5F37: 0E 00 00 00 00 00 00 00 09 00 00 00 01 01 01 01
C1/5F47: 01 01 02 02 02 02 02 02 03 03 03 03 03 03 04 04
C1/5F57: 04 04 04 04 05 05 05 05 05 07 07 07 08 06 00 00

; 00: none
; 01: spellblade
; 02: white
; 03: black
; 04: time
; 05: summon
; 06: blue
; 07: red
; 08: x-magic
; 09: sing
; 0A: other ???
; 0B: ???
; 0C: item
; 0D: combine
; 0E: drink
; 0F: throw

C1/5F67: C9 53        CMP #53
C1/5F69: 90 0F        BCC 5F7A
C1/5F6B: 91 C1        STA (C1),Y
C1/5F6D: A9 FF        LDA #FF
C1/5F6F: 91 BF        STA (BF),Y
C1/5F71: C8           INY
C1/5F72: A5 C3        LDA $C3
C1/5F74: 91 C1        STA ($C1),Y
C1/5F76: 91 BF        STA ($BF),Y
C1/5F78: C8           INY 
C1/5F79: 60           RTS
C1/5F7A: C9 49        CMP #$49
C1/5F7C: 90 0A        BCC $5F88
C1/5F7E: 18           CLC 
C1/5F7F: 69 17        ADC #$17
C1/5F81: 91 C1        STA ($C1),Y
C1/5F83: A9 52        LDA #$52
C1/5F85: 4C 6F 5F     JMP $5F6F
C1/5F88: 18           CLC 
C1/5F89: 69 40        ADC #$40
C1/5F8B: 91 C1        STA ($C1),Y
C1/5F8D: A9 51        LDA #$51
C1/5F8F: 4C 6F 5F     JMP $5F6F

C1/5F92: 7B           TDC 
C1/5F93: AA           TAX 
C1/5F94: BD 6C CD     LDA $CD6C,X
C1/5F97: D0 08        BNE $5FA1
C1/5F99: A9 F0        LDA #$F0
C1/5F9B: 9D F9 02     STA $02F9,X
C1/5F9E: 4C B8 5F     JMP $5FB8
C1/5FA1: BD 6D CD     LDA $CD6D,X
C1/5FA4: 9D F8 02     STA $02F8,X
C1/5FA7: BD 6E CD     LDA $CD6E,X
C1/5FAA: 9D F9 02     STA $02F9,X
C1/5FAD: A9 E2        LDA #$E2
C1/5FAF: 9D FA 02     STA $02FA,X
C1/5FB2: BD 6F CD     LDA $CD6F,X
C1/5FB5: 9D FB 02     STA $02FB,X
C1/5FB8: E8           INX 
C1/5FB9: E8           INX 
C1/5FBA: E8           INX 
C1/5FBB: E8           INX 
C1/5FBC: E0 08 00     CPX #$0008
C1/5FBF: D0 D3        BNE $5F94
C1/5FC1: AD 0F 04     LDA $040F
C1/5FC4: 29 0F        AND #$0F
C1/5FC6: 09 A0        ORA #$A0
C1/5FC8: 8D 0F 04     STA $040F
C1/5FCB: 60           RTS 
C1/5FCC: AD 68 CD     LDA $CD68
C1/5FCF: F0 1E        BEQ $5FEF
C1/5FD1: AD 69 CD     LDA $CD69
C1/5FD4: 45 F6        EOR $F6
C1/5FD6: 38           SEC 
C1/5FD7: E5 F9        SBC $F9
C1/5FD9: 8D 20 02     STA $0220
C1/5FDC: AD 6A CD     LDA $CD6A
C1/5FDF: 8D 21 02     STA $0221
C1/5FE2: A9 D0        LDA #$D0
C1/5FE4: 8D 22 02     STA $0222
C1/5FE7: AD 6B CD     LDA $CD6B
C1/5FEA: 45 F7        EOR $F7
C1/5FEC: 8D 23 02     STA $0223
C1/5FEF: 60           RTS 

; [  ]

C1/5FF0: 7B           TDC 
C1/5FF1: AA           TAX 
C1/5FF2: BD 48 CD     LDA $CD48,X
C1/5FF5: D0 08        BNE $5FFF
C1/5FF7: A9 F0        LDA #$F0
C1/5FF9: 9D 01 02     STA $0201,X
C1/5FFC: 4C 16 60     JMP $6016
C1/5FFF: BD 49 CD     LDA $CD49,X
C1/6002: 9D 00 02     STA $0200,X
C1/6005: BD 4A CD     LDA $CD4A,X
C1/6008: 9D 01 02     STA $0201,X
C1/600B: A9 D0        LDA #$D0
C1/600D: 9D 02 02     STA $0202,X
C1/6010: BD 4B CD     LDA $CD4B,X
C1/6013: 9D 03 02     STA $0203,X
C1/6016: E8           INX 
C1/6017: E8           INX 
C1/6018: E8           INX 
C1/6019: E8           INX 
C1/601A: E0 10 00     CPX #$0010
C1/601D: D0 D3        BNE $5FF2
C1/601F: BD 48 CD     LDA $CD48,X
C1/6022: D0 08        BNE $602C
C1/6024: A9 F0        LDA #$F0
C1/6026: 9D 01 02     STA $0201,X
C1/6029: 4C 4A 60     JMP $604A
C1/602C: BD 49 CD     LDA $CD49,X
C1/602F: 45 F6        EOR $F6
C1/6031: 38           SEC 
C1/6032: E5 F9        SBC $F9
C1/6034: 9D 00 02     STA $0200,X
C1/6037: BD 4A CD     LDA $CD4A,X
C1/603A: 9D 01 02     STA $0201,X
C1/603D: A9 D0        LDA #$D0
C1/603F: 9D 02 02     STA $0202,X
C1/6042: BD 4B CD     LDA $CD4B,X
C1/6045: 45 F7        EOR $F7
C1/6047: 9D 03 02     STA $0203,X
C1/604A: E8           INX 
C1/604B: E8           INX 
C1/604C: E8           INX 
C1/604D: E8           INX 
C1/604E: E0 20 00     CPX #$0020
C1/6051: D0 CC        BNE $601F
C1/6053: A9 AA        LDA #$AA
C1/6055: 8D 00 04     STA $0400
C1/6058: 8D 01 04     STA $0401
C1/605B: 60           RTS 

; [  ]

C1/605C: AD D3 CF     LDA $CFD3
C1/605F: AA           TAX 
C1/6060: AD D4 CF     LDA $CFD4
C1/6063: A8           TAY 
C1/6064: A9 06        LDA #$06
C1/6066: 85 70        STA $70
C1/6068: BD 34 27     LDA $2734,X
C1/606B: 48           PHA 
C1/606C: B9 34 27     LDA $2734,Y
C1/606F: 9D 34 27     STA $2734,X
C1/6072: 68           PLA 
C1/6073: 99 34 27     STA $2734,Y
C1/6076: C2 20        REP #$20
C1/6078: 8A           TXA 
C1/6079: 18           CLC 
C1/607A: 69 00 01     ADC #$0100
C1/607D: AA           TAX 
C1/607E: 98           TYA 
C1/607F: 18           CLC 
C1/6080: 69 00 01     ADC #$0100
C1/6083: A8           TAY 
C1/6084: 7B           TDC 
C1/6085: E2 20        SEP #$20
C1/6087: C6 70        DEC $70
C1/6089: D0 DD        BNE $6068
C1/608B: 4C B6 61     JMP $61B6
C1/608E: AD 42 CD     LDA $CD42
C1/6091: 85 7E        STA $7E
C1/6093: A9 0C        LDA #$0C
C1/6095: 85 80        STA $80
C1/6097: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/609A: A6 82        LDX $82
C1/609C: 60           RTS 
C1/609D: 20 8E 60     JSR $608E
C1/60A0: A9 06        LDA #$06
C1/60A2: 85 70        STA $70
C1/60A4: BD AC 37     LDA $37AC,X
C1/60A7: 48           PHA 
C1/60A8: BD AD 37     LDA $37AD,X
C1/60AB: 9D AC 37     STA $37AC,X
C1/60AE: 68           PLA 
C1/60AF: 9D AD 37     STA $37AD,X
C1/60B2: E8           INX 
C1/60B3: E8           INX 
C1/60B4: C6 70        DEC $70
C1/60B6: D0 EC        BNE $60A4
C1/60B8: 4C B6 61     JMP $61B6

; [  ]

C1/60BB: 20 8E 60     JSR $608E
C1/60BE: A5 82        LDA $82
C1/60C0: 18           CLC 
C1/60C1: 6D D4 CF     ADC $CFD4
C1/60C4: AA           TAX 
C1/60C5: AD D3 CF     LDA $CFD3
C1/60C8: A8           TAY 
C1/60C9: 4C DA 60     JMP $60DA
C1/60CC: 20 8E 60     JSR $608E
C1/60CF: A5 82        LDA $82
C1/60D1: 18           CLC 
C1/60D2: 6D D3 CF     ADC $CFD3
C1/60D5: AA           TAX 
C1/60D6: AD D4 CF     LDA $CFD4
C1/60D9: A8           TAY 
C1/60DA: B9 34 27     LDA $2734,Y
C1/60DD: D0 03        BNE $60E2
C1/60DF: 4C 66 61     JMP $6166
C1/60E2: DD AC 37     CMP $37AC,X
C1/60E5: D0 25        BNE $610C
C1/60E7: B9 34 28     LDA $2834,Y
C1/60EA: 18           CLC 
C1/60EB: 7D AE 37     ADC $37AE,X
C1/60EE: 99 34 28     STA $2834,Y
C1/60F1: C9 64        CMP #$64
C1/60F3: 90 05        BCC $60FA
C1/60F5: A9 63        LDA #$63
C1/60F7: 99 34 28     STA $2834,Y
C1/60FA: 7B           TDC 
C1/60FB: 9D AC 37     STA $37AC,X
C1/60FE: 9D AE 37     STA $37AE,X
C1/6101: A9 FF        LDA #$FF
C1/6103: 9D B4 37     STA $37B4,X
C1/6106: 9D B6 37     STA $37B6,X
C1/6109: 4C B6 61     JMP $61B6
C1/610C: B9 34 28     LDA $2834,Y
C1/610F: F0 55        BEQ $6166
C1/6111: C9 01        CMP #$01
C1/6113: F0 51        BEQ $6166
C1/6115: BD AC 37     LDA $37AC,X
C1/6118: D0 0A        BNE $6124
C1/611A: B9 34 28     LDA $2834,Y
C1/611D: 3A           DEC 
C1/611E: 99 34 28     STA $2834,Y
C1/6121: 4C 69 61     JMP $6169
C1/6124: DA           PHX 
C1/6125: 7B           TDC 
C1/6126: AA           TAX 
C1/6127: BD 34 27     LDA $2734,X
C1/612A: F0 0D        BEQ $6139
C1/612C: E8           INX 
C1/612D: E0 00 01     CPX #$0100
C1/6130: D0 F5        BNE $6127
C1/6132: A9 01        LDA #$01
C1/6134: 8D D5 CF     STA $CFD5
C1/6137: FA           PLX 
C1/6138: 60           RTS 
C1/6139: B9 34 28     LDA $2834,Y
C1/613C: 3A           DEC 
C1/613D: 99 34 28     STA $2834,Y
C1/6140: B9 34 27     LDA $2734,Y
C1/6143: 9D 34 27     STA $2734,X
C1/6146: A9 01        LDA #$01
C1/6148: 9D 34 28     STA $2834,X
C1/614B: B9 34 29     LDA $2934,Y
C1/614E: 9D 34 29     STA $2934,X
C1/6151: B9 34 2A     LDA $2A34,Y
C1/6154: 9D 34 2A     STA $2A34,X
C1/6157: B9 34 2B     LDA $2B34,Y
C1/615A: 9D 34 2B     STA $2B34,X
C1/615D: B9 34 2C     LDA $2C34,Y
C1/6160: 9D 34 2C     STA $2C34,X
C1/6163: 8A           TXA 
C1/6164: A8           TAY 
C1/6165: FA           PLX 
C1/6166: 4C 8F 61     JMP $618F
C1/6169: B9 34 27     LDA $2734,Y
C1/616C: 9D AC 37     STA $37AC,X
C1/616F: B9 34 29     LDA $2934,Y
C1/6172: 9D B0 37     STA $37B0,X
C1/6175: B9 34 2A     LDA $2A34,Y
C1/6178: 9D B2 37     STA $37B2,X
C1/617B: B9 34 2B     LDA $2B34,Y
C1/617E: 9D B4 37     STA $37B4,X
C1/6181: B9 34 2C     LDA $2C34,Y
C1/6184: 9D B6 37     STA $37B6,X
C1/6187: A9 01        LDA #$01
C1/6189: 9D AE 37     STA $37AE,X
C1/618C: 4C B6 61     JMP $61B6
C1/618F: A9 06        LDA #$06
C1/6191: 85 70        STA $70
C1/6193: B9 34 27     LDA $2734,Y
C1/6196: 48           PHA 
C1/6197: BD AC 37     LDA $37AC,X
C1/619A: 99 34 27     STA $2734,Y
C1/619D: 68           PLA 
C1/619E: 9D AC 37     STA $37AC,X
C1/61A1: C2 20        REP #$20
C1/61A3: 98           TYA 
C1/61A4: 18           CLC 
C1/61A5: 69 00 01     ADC #$0100
C1/61A8: A8           TAY 
C1/61A9: 8A           TXA 
C1/61AA: 18           CLC 
C1/61AB: 69 02 00     ADC #$0002
C1/61AE: AA           TAX 
C1/61AF: 7B           TDC 
C1/61B0: E2 20        SEP #$20
C1/61B2: C6 70        DEC $70
C1/61B4: D0 DD        BNE $6193
C1/61B6: 20 E2 39     JSR $39E2
C1/61B9: 20 CD 3C     JSR $3CCD
C1/61BC: 9C 38 CD     STZ $CD38
C1/61BF: EE 7D 7B     INC $7B7D
C1/61C2: 60           RTS 

; =================================[ sprites ]==================================

; [  ]

C1/61C3: AD 74 DB     LDA $DB74
C1/61C6: D0 01        BNE $61C9
C1/61C8: 60           RTS 
C1/61C9: 7B           TDC 
C1/61CA: AA           TAX 
C1/61CB: A0 E8 00     LDY #$00E8
C1/61CE: AD 75 DB     LDA $DB75
C1/61D1: 29 80        AND #$80
C1/61D3: F0 20        BEQ $61F5
C1/61D5: AD 78 DB     LDA $DB78
C1/61D8: F0 05        BEQ $61DF
C1/61DA: CE 78 DB     DEC $DB78
C1/61DD: 80 16        BRA $61F5
C1/61DF: CE 7C DB     DEC $DB7C
C1/61E2: D0 0B        BNE $61EF
C1/61E4: AD 75 DB     LDA $DB75
C1/61E7: 29 7F        AND #$7F
C1/61E9: 8D 74 DB     STA $DB74
C1/61EC: 8D 75 DB     STA $DB75
C1/61EF: AD ED DB     LDA $DBED
C1/61F2: 20 68 62     JSR $6268
C1/61F5: E8           INX 
C1/61F6: AD 75 DB     LDA $DB75
C1/61F9: 29 40        AND #$40
C1/61FB: F0 1E        BEQ $621B
C1/61FD: AD 79 DB     LDA $DB79
C1/6200: F0 03        BEQ $6205
C1/6202: CE 79 DB     DEC $DB79
C1/6205: CE 7D DB     DEC $DB7D
C1/6208: D0 0B        BNE $6215
C1/620A: AD 75 DB     LDA $DB75
C1/620D: 29 BF        AND #$BF
C1/620F: 8D 74 DB     STA $DB74
C1/6212: 8D 75 DB     STA $DB75
C1/6215: AD EE DB     LDA $DBEE
C1/6218: 20 68 62     JSR $6268
C1/621B: E8           INX 
C1/621C: AD 75 DB     LDA $DB75
C1/621F: 29 20        AND #$20
C1/6221: F0 1E        BEQ $6241
C1/6223: AD 7B DB     LDA $DB7B
C1/6226: F0 03        BEQ $622B
C1/6228: CE 7B DB     DEC $DB7B
C1/622B: CE 7E DB     DEC $DB7E
C1/622E: D0 0B        BNE $623B
C1/6230: AD 75 DB     LDA $DB75
C1/6233: 29 DF        AND #$DF
C1/6235: 8D 75 DB     STA $DB75
C1/6238: 8D 74 DB     STA $DB74
C1/623B: AD EF DB     LDA $DBEF
C1/623E: 20 68 62     JSR $6268
C1/6241: E8           INX 
C1/6242: AD 75 DB     LDA $DB75
C1/6245: 29 10        AND #$10
C1/6247: F0 1E        BEQ $6267
C1/6249: AD 7C DB     LDA $DB7C
C1/624C: F0 03        BEQ $6251
C1/624E: CE 7C DB     DEC $DB7C
C1/6251: CE 7F DB     DEC $DB7F
C1/6254: D0 0B        BNE $6261
C1/6256: AD 75 DB     LDA $DB75
C1/6259: 29 EF        AND #$EF
C1/625B: 8D 75 DB     STA $DB75
C1/625E: 8D 74 DB     STA $DB74
C1/6261: AD F0 DB     LDA $DBF0
C1/6264: 20 68 62     JSR $6268
C1/6267: 60           RTS 

; [  ]

C1/6268: 85 88        STA $88
C1/626A: BD 3E D0     LDA $D03E,X
C1/626D: 38           SEC 
C1/626E: E9 10        SBC #$10
C1/6270: 45 F6        EOR $F6
C1/6272: 38           SEC 
C1/6273: E5 F9        SBC $F9
C1/6275: 99 00 02     STA $0200,Y
C1/6278: BD 4A D0     LDA $D04A,X
C1/627B: 38           SEC 
C1/627C: E9 08        SBC #$08
C1/627E: 18           CLC 
C1/627F: 65 88        ADC $88
C1/6281: 99 01 02     STA $0201,Y
C1/6284: A9 EC        LDA #$EC
C1/6286: 99 02 02     STA $0202,Y
C1/6289: A9 33        LDA #$33
C1/628B: 45 F7        EOR $F7
C1/628D: 99 03 02     STA $0203,Y
C1/6290: C8           INY 
C1/6291: C8           INY 
C1/6292: C8           INY 
C1/6293: C8           INY 
C1/6294: 60           RTS 

; [  ]

C1/6295: C2 20        REP #$20
C1/6297: A2 70 00     LDX #$0070
C1/629A: 86 88        STX $88
C1/629C: 7B           TDC 
C1/629D: AA           TAX 
C1/629E: 86 8A        STX $8A
C1/62A0: A5 98        LDA $98
C1/62A2: 18           CLC 
C1/62A3: 65 88        ADC $88
C1/62A5: 9D 88 F5     STA $F588,X
C1/62A8: A5 9A        LDA $9A
C1/62AA: 18           CLC 
C1/62AB: 65 8A        ADC $8A
C1/62AD: 9D 8A F5     STA $F58A,X
C1/62B0: E8           INX 
C1/62B1: E8           INX 
C1/62B2: E8           INX 
C1/62B3: E8           INX 
C1/62B4: A5 88        LDA $88
C1/62B6: 38           SEC 
C1/62B7: E9 10 00     SBC #$0010
C1/62BA: 85 88        STA $88
C1/62BC: C9 F0 FF     CMP #$FFF0
C1/62BF: D0 DF        BNE $62A0
C1/62C1: A9 70 00     LDA #$0070
C1/62C4: 85 88        STA $88
C1/62C6: A5 8A        LDA $8A
C1/62C8: 18           CLC 
C1/62C9: 69 10 00     ADC #$0010
C1/62CC: 85 8A        STA $8A
C1/62CE: C9 80 00     CMP #$0080
C1/62D1: D0 CD        BNE $62A0
C1/62D3: 7B           TDC 
C1/62D4: E2 20        SEP #$20
C1/62D6: 60           RTS 
C1/62D7: AD 60 DB     LDA $DB60
C1/62DA: 10 03        BPL $62DF
C1/62DC: 4C 3A 70     JMP $703A
C1/62DF: AD 61 DB     LDA $DB61
C1/62E2: D0 01        BNE $62E5
C1/62E4: 60           RTS 
C1/62E5: C2 20        REP #$20
C1/62E7: 7B           TDC 
C1/62E8: AA           TAX 
C1/62E9: C2 20        REP #$20
C1/62EB: A9 F0 F0     LDA #$F0F0
C1/62EE: 9D 00 03     STA $0300,X
C1/62F1: E8           INX 
C1/62F2: E8           INX 
C1/62F3: E8           INX 
C1/62F4: E8           INX 
C1/62F5: E0 00 01     CPX #$0100
C1/62F8: D0 F4        BNE $62EE
C1/62FA: 7B           TDC 
C1/62FB: AA           TAX 
C1/62FC: A9 AA AA     LDA #$AAAA
C1/62FF: 9D 10 04     STA $0410,X
C1/6302: E8           INX 
C1/6303: E8           INX 
C1/6304: E0 10 00     CPX #$0010
C1/6307: D0 F6        BNE $62FF
C1/6309: AD 62 DB     LDA $DB62
C1/630C: 85 98        STA $98
C1/630E: AD 64 DB     LDA $DB64
C1/6311: 85 9A        STA $9A
C1/6313: E2 20        SEP #$20
C1/6315: 20 95 62     JSR $6295
C1/6318: A9 40        LDA #$40
C1/631A: 85 92        STA $92
C1/631C: A0 00 01     LDY #$0100
C1/631F: 20 AA 63     JSR $63AA
C1/6322: AD 72 DB     LDA $DB72
C1/6325: F0 BD        BEQ $62E4
C1/6327: C2 20        REP #$20
C1/6329: 7B           TDC 
C1/632A: AA           TAX 
C1/632B: A9 F0 F0     LDA #$F0F0
C1/632E: 9D 20 02     STA $0220,X
C1/6331: E8           INX 
C1/6332: E8           INX 
C1/6333: E8           INX 
C1/6334: E8           INX 
C1/6335: E0 D8 00     CPX #$00D8
C1/6338: D0 F4        BNE $632E
C1/633A: 7B           TDC 
C1/633B: E2 20        SEP #$20
C1/633D: EE 73 DB     INC $DB73
C1/6340: AD 73 DB     LDA $DB73
C1/6343: 29 01        AND #$01
C1/6345: F0 9D        BEQ $62E4
C1/6347: 0A           ASL 
C1/6348: AA           TAX 
C1/6349: C2 20        REP #$20
C1/634B: BF 00 B9 D4  LDA $D4B900,X
C1/634F: 85 9C        STA $9C
C1/6351: BF 22 B9 D4  LDA $D4B922,X
C1/6355: 85 9E        STA $9E
C1/6357: AD 62 DB     LDA $DB62
C1/635A: 18           CLC 
C1/635B: 65 9C        ADC $9C
C1/635D: 85 98        STA $98
C1/635F: AD 64 DB     LDA $DB64
C1/6362: 18           CLC 
C1/6363: 65 9E        ADC $9E
C1/6365: 85 9A        STA $9A
C1/6367: E2 20        SEP #$20
C1/6369: 20 95 62     JSR $6295
C1/636C: A9 28        LDA #$28
C1/636E: 85 92        STA $92
C1/6370: A0 20 00     LDY #$0020
C1/6373: 20 AA 63     JSR $63AA
C1/6376: AD 73 DB     LDA $DB73
C1/6379: 29 01        AND #$01
C1/637B: 0A           ASL 
C1/637C: AA           TAX 
C1/637D: C2 20        REP #$20
C1/637F: BF 02 B9 D4  LDA $D4B902,X
C1/6383: 85 9C        STA $9C
C1/6385: BF 24 B9 D4  LDA $D4B924,X
C1/6389: 85 9E        STA $9E
C1/638B: AD 62 DB     LDA $DB62
C1/638E: 18           CLC 
C1/638F: 65 9C        ADC $9C
C1/6391: 85 98        STA $98
C1/6393: AD 64 DB     LDA $DB64
C1/6396: 18           CLC 
C1/6397: 65 9E        ADC $9E
C1/6399: 85 9A        STA $9A
C1/639B: E2 20        SEP #$20
C1/639D: 20 95 62     JSR $6295
C1/63A0: A9 28        LDA #$28
C1/63A2: 85 92        STA $92
C1/63A4: A0 84 00     LDY #$0084
C1/63A7: 4C AA 63     JMP $63AA

C1/63AA: AD D3 DB     LDA $DBD3
C1/63AD: F0 04        BEQ $63B3
C1/63AF: A9 C0        LDA #$C0
C1/63B1: 80 02        BRA $63B5
C1/63B3: A9 A0        LDA #$A0
C1/63B5: 85 8E        STA $8E
C1/63B7: 7B           TDC 
C1/63B8: AA           TAX 
C1/63B9: AD 66 DB     LDA $DB66
C1/63BC: 85 88        STA $88
C1/63BE: 64 8A        STZ $8A
C1/63C0: 64 8C        STZ $8C
C1/63C2: BF 00 77 7F  LDA $7F7700,X
C1/63C6: F0 19        BEQ $63E1
C1/63C8: BD 89 F5     LDA $F589,X
C1/63CB: D0 14        BNE $63E1
C1/63CD: BD 88 F5     LDA $F588,X
C1/63D0: C9 F8        CMP #$F8
C1/63D2: B0 0D        BCS $63E1
C1/63D4: 45 F6        EOR $F6
C1/63D6: 38           SEC 
C1/63D7: E5 F9        SBC $F9
C1/63D9: 99 00 02     STA $0200,Y
C1/63DC: BD 8B F5     LDA $F58B,X
C1/63DF: F0 04        BEQ $63E5
C1/63E1: A9 F0        LDA #$F0
C1/63E3: 80 22        BRA $6407
C1/63E5: BD 8A F5     LDA $F58A,X
C1/63E8: C5 8E        CMP $8E
C1/63EA: 90 02        BCC $63EE
C1/63EC: 80 F3        BRA $63E1
C1/63EE: BD 8A F5     LDA $F58A,X
C1/63F1: 99 01 02     STA $0201,Y
C1/63F4: A5 8A        LDA $8A
C1/63F6: 18           CLC 
C1/63F7: 65 8C        ADC $8C
C1/63F9: 99 02 02     STA $0202,Y
C1/63FC: A5 88        LDA $88
C1/63FE: 45 F7        EOR $F7
C1/6400: 99 03 02     STA $0203,Y
C1/6403: C8           INY 
C1/6404: C8           INY 
C1/6405: C8           INY 
C1/6406: C8           INY 
C1/6407: E6 8A        INC $8A
C1/6409: E6 8A        INC $8A
C1/640B: A5 8A        LDA $8A
C1/640D: 29 0F        AND #$0F
C1/640F: 85 8A        STA $8A
C1/6411: D0 07        BNE $641A
C1/6413: A5 8C        LDA $8C
C1/6415: 18           CLC 
C1/6416: 69 20        ADC #$20
C1/6418: 85 8C        STA $8C
C1/641A: E8           INX 
C1/641B: E8           INX 
C1/641C: E8           INX 
C1/641D: E8           INX 
C1/641E: C6 92        DEC $92
C1/6420: D0 A0        BNE $63C2
C1/6422: 60           RTS 

; [  ]

C1/6423: AD 39 DB     LDA $DB39
C1/6426: 29 01        AND #$01
C1/6428: F0 03        BEQ $642D
C1/642A: 4C 4C 64     JMP $644C
C1/642D: E6 EF        INC $EF
C1/642F: A9 08        LDA #$08
C1/6431: 85 92        STA $92
C1/6433: 8D 3A DB     STA $DB3A
C1/6436: A0 00 00     LDY #$0000
C1/6439: 20 9A 64     JSR $649A
C1/643C: C0 00 01     CPY #$0100
C1/643F: D0 F8        BNE $6439
C1/6441: A5 92        LDA $92
C1/6443: 8D 3A DB     STA $DB3A
C1/6446: EE 39 DB     INC $DB39
C1/6449: 64 EF        STZ $EF
C1/644B: 60           RTS 
C1/644C: E6 EF        INC $EF
C1/644E: AD 3A DB     LDA $DB3A
C1/6451: 85 92        STA $92
C1/6453: A0 00 01     LDY #$0100
C1/6456: 20 9A 64     JSR $649A
C1/6459: C0 00 02     CPY #$0200
C1/645C: D0 F8        BNE $6456
C1/645E: EE 39 DB     INC $DB39
C1/6461: A5 92        LDA $92
C1/6463: 8D 3A DB     STA $DB3A
C1/6466: C9 3E        CMP #$3E
C1/6468: F0 16        BEQ $6480
C1/646A: C2 20        REP #$20
C1/646C: 0A           ASL 
C1/646D: 0A           ASL 
C1/646E: AA           TAX 
C1/646F: 7B           TDC 
C1/6470: E2 20        SEP #$20
C1/6472: A9 F0        LDA #$F0
C1/6474: 9D 0A 7D     STA $7D0A,X
C1/6477: E8           INX 
C1/6478: E8           INX 
C1/6479: E8           INX 
C1/647A: E8           INX 
C1/647B: E0 F8 00     CPX #$00F8
C1/647E: D0 F4        BNE $6474
C1/6480: 20 86 64     JSR $6486
C1/6483: 64 EF        STZ $EF
C1/6485: 60           RTS 

; [  ]

C1/6486: A2 29 7D     LDX #$7D29      ; copy from sprite data buffer
C1/6489: A0 20 02     LDY #$0220
C1/648C: 8B           PHB 
C1/648D: C2 20        REP #$20
C1/648F: A9 D7 00     LDA #$00D7
C1/6492: 54 00 7E     MVN $00,$7E
C1/6495: 7B           TDC 
C1/6496: E2 20        SEP #$20
C1/6498: AB           PLB 
C1/6499: 60           RTS 

; [  ]

C1/649A: A5 92        LDA $92
C1/649C: 99 D9 D1     STA $D1D9,Y
C1/649F: 5A           PHY 
C1/64A0: 20 D7 65     JSR $65D7
C1/64A3: 7A           PLY 
C1/64A4: C2 20        REP #$20
C1/64A6: 98           TYA 
C1/64A7: 18           CLC 
C1/64A8: 69 10 00     ADC #$0010
C1/64AB: A8           TAY 
C1/64AC: 7B           TDC 
C1/64AD: E2 20        SEP #$20
C1/64AF: 60           RTS 

; [  ]

C1/64B0: AD 38 DB     LDA $DB38
C1/64B3: D0 01        BNE $64B6
C1/64B5: 60           RTS 
C1/64B6: C9 02        CMP #$02
C1/64B8: D0 03        BNE $64BD
C1/64BA: 4C 23 64     JMP $6423
C1/64BD: AD 3B DB     LDA $DB3B
C1/64C0: F0 06        BEQ $64C8
C1/64C2: 20 CF 64     JSR $64CF
C1/64C5: 4C F4 64     JMP $64F4
C1/64C8: AD 39 DB     LDA $DB39
C1/64CB: 29 01        AND #$01
C1/64CD: D0 25        BNE $64F4
C1/64CF: E6 EF        INC $EF
C1/64D1: A0 70 00     LDY #$0070
C1/64D4: A9 08        LDA #$08
C1/64D6: 85 92        STA $92
C1/64D8: A5 92        LDA $92
C1/64DA: 99 D9 D1     STA $D1D9,Y
C1/64DD: 5A           PHY 
C1/64DE: 20 D7 65     JSR $65D7
C1/64E1: 7A           PLY 
C1/64E2: 98           TYA 
C1/64E3: 38           SEC 
C1/64E4: E9 10        SBC #$10
C1/64E6: A8           TAY 
C1/64E7: C9 30        CMP #$30
C1/64E9: D0 ED        BNE $64D8
C1/64EB: A5 92        LDA $92
C1/64ED: 8D 3A DB     STA $DB3A
C1/64F0: EE 39 DB     INC $DB39
C1/64F3: 60           RTS 
C1/64F4: A0 30 00     LDY #$0030
C1/64F7: AD 3A DB     LDA $DB3A
C1/64FA: 85 92        STA $92
C1/64FC: A5 92        LDA $92
C1/64FE: 99 D9 D1     STA $D1D9,Y
C1/6501: 5A           PHY 
C1/6502: 20 D7 65     JSR $65D7
C1/6505: 7A           PLY 
C1/6506: 98           TYA 
C1/6507: 38           SEC 
C1/6508: E9 10        SBC #$10
C1/650A: A8           TAY 
C1/650B: C9 F0        CMP #$F0
C1/650D: D0 ED        BNE $64FC
C1/650F: A5 92        LDA $92
C1/6511: 8D 3A DB     STA $DB3A
C1/6514: C2 20        REP #$20
C1/6516: 0A           ASL 
C1/6517: 0A           ASL 
C1/6518: AA           TAX 
C1/6519: 7B           TDC 
C1/651A: E2 20        SEP #$20
C1/651C: A9 F0        LDA #$F0
C1/651E: 9D 0A 7D     STA $7D0A,X
C1/6521: E8           INX 
C1/6522: E8           INX 
C1/6523: E8           INX 
C1/6524: E8           INX 
C1/6525: E0 00 01     CPX #$0100
C1/6528: D0 F4        BNE $651E
C1/652A: 64 EF        STZ $EF
C1/652C: EE 39 DB     INC $DB39
C1/652F: 20 86 64     JSR $6486
C1/6532: 60           RTS 

; =============================[ animation frames ]=============================

; [  ]

C1/6533: AD 69 DB     LDA $DB69
C1/6536: D0 01        BNE $6539
C1/6538: 60           RTS 
C1/6539: 7B           TDC 
C1/653A: AA           TAX 
C1/653B: 64 88        STZ $88
C1/653D: BD D8 DA     LDA $DAD8,X
C1/6540: F0 07        BEQ $6549
C1/6542: A5 88        LDA $88
C1/6544: 18           CLC 
C1/6545: 69 07        ADC #$07
C1/6547: 85 88        STA $88
C1/6549: 8A           TXA 
C1/654A: 18           CLC 
C1/654B: 69 08        ADC #$08
C1/654D: AA           TAX 
C1/654E: C9 40        CMP #$40
C1/6550: D0 EB        BNE $653D
C1/6552: A5 88        LDA $88
C1/6554: D0 03        BNE $6559
C1/6556: 4C D3 65     JMP $65D3
C1/6559: A9 3E        LDA #$3E
C1/655B: 38           SEC 
C1/655C: E5 88        SBC $88
C1/655E: C2 20        REP #$20
C1/6560: 0A           ASL 
C1/6561: 0A           ASL 
C1/6562: A8           TAY 
C1/6563: 7B           TDC 
C1/6564: E2 20        SEP #$20
C1/6566: 7B           TDC 
C1/6567: AA           TAX 
C1/6568: BD D8 DA     LDA $DAD8,X
C1/656B: F0 5C        BEQ $65C9
C1/656D: BD DC DA     LDA $DADC,X
C1/6570: F0 06        BEQ $6578
C1/6572: DE DC DA     DEC $DADC,X
C1/6575: 4C C9 65     JMP $65C9
C1/6578: DE DD DA     DEC $DADD,X
C1/657B: D0 03        BNE $6580
C1/657D: 9E D8 DA     STZ $DAD8,X
C1/6580: DA           PHX 
C1/6581: BD D9 DA     LDA $DAD9,X
C1/6584: 85 88        STA $88
C1/6586: BD DA DA     LDA $DADA,X
C1/6589: 85 89        STA $89
C1/658B: BD DB DA     LDA $DADB,X
C1/658E: AA           TAX 
C1/658F: A9 07        LDA #$07
C1/6591: 85 8C        STA $8C
C1/6593: BF E8 E1 D0  LDA $D0E1E8,X
C1/6597: 18           CLC 
C1/6598: 65 88        ADC $88
C1/659A: 45 F6        EOR $F6
C1/659C: 38           SEC 
C1/659D: E5 F9        SBC $F9
C1/659F: 99 00 02     STA $0200,Y
C1/65A2: BF E9 E1 D0  LDA $D0E1E9,X
C1/65A6: 18           CLC 
C1/65A7: 65 89        ADC $89
C1/65A9: 99 01 02     STA $0201,Y
C1/65AC: BF EA E1 D0  LDA $D0E1EA,X
C1/65B0: 99 02 02     STA $0202,Y
C1/65B3: BF EB E1 D0  LDA $D0E1EB,X
C1/65B7: 45 F7        EOR $F7
C1/65B9: 99 03 02     STA $0203,Y
C1/65BC: E8           INX 
C1/65BD: E8           INX 
C1/65BE: E8           INX 
C1/65BF: E8           INX 
C1/65C0: C8           INY 
C1/65C1: C8           INY 
C1/65C2: C8           INY 
C1/65C3: C8           INY 
C1/65C4: C6 8C        DEC $8C
C1/65C6: D0 CB        BNE $6593
C1/65C8: FA           PLX 
C1/65C9: 8A           TXA 
C1/65CA: 18           CLC 
C1/65CB: 69 08        ADC #$08
C1/65CD: AA           TAX 
C1/65CE: C9 40        CMP #$40
C1/65D0: D0 96        BNE $6568
C1/65D2: 60           RTS 
C1/65D3: 9C 69 DB     STZ $DB69
C1/65D6: 60           RTS 

; [  ]

C1/65D7: B9 D8 D1     LDA $D1D8,Y
C1/65DA: D0 01        BNE $65DD
C1/65DC: 60           RTS 
C1/65DD: AD 5F DB     LDA $DB5F
C1/65E0: D0 FA        BNE $65DC
C1/65E2: AD 3C DB     LDA $DB3C
C1/65E5: F0 19        BEQ $6600
C1/65E7: 5A           PHY 
C1/65E8: 7B           TDC 
C1/65E9: AA           TAX 
C1/65EA: B9 D8 D9     LDA $D9D8,Y
C1/65ED: 9D 18 DB     STA $DB18,X
C1/65F0: B9 58 DA     LDA $DA58,Y
C1/65F3: 9D 28 DB     STA $DB28,X
C1/65F6: E8           INX 
C1/65F7: C8           INY 
C1/65F8: E0 10 00     CPX #$0010
C1/65FB: D0 ED        BNE $65EA
C1/65FD: 7A           PLY 
C1/65FE: 80 03        BRA $6603
C1/6600: 20 7D 69     JSR $697D
C1/6603: B9 E3 D1     LDA $D1E3,Y     ; frame offset ???
C1/6606: C2 20        REP #$20
C1/6608: 18           CLC 
C1/6609: 79 DA D1     ADC $D1DA,Y     ; frame index
C1/660C: 0A           ASL 
C1/660D: AA           TAX 
C1/660E: BF 5E B3 D9  LDA $D9B35E,X   ; pointer to animation frame data
C1/6612: 85 88        STA $88
C1/6614: 7B           TDC 
C1/6615: E2 20        SEP #$20
C1/6617: A9 D9        LDA #$D9
C1/6619: 85 8A        STA $8A
C1/661B: B9 E5 D1     LDA $D1E5,Y     ; width
C1/661E: 85 8C        STA $8C
C1/6620: B9 E6 D1     LDA $D1E6,Y     ; height
C1/6623: 85 8D        STA $8D
C1/6625: B9 DE D1     LDA $D1DE,Y     ; tile count
C1/6628: 85 9C        STA $9C
C1/662A: B9 DF D1     LDA $D1DF,Y
C1/662D: 8D C5 D1     STA $D1C5
C1/6630: B9 E0 D1     LDA $D1E0,Y
C1/6633: 8D C6 D1     STA $D1C6
C1/6636: B9 E1 D1     LDA $D1E1,Y
C1/6639: 8D C7 D1     STA $D1C7
C1/663C: B9 E2 D1     LDA $D1E2,Y
C1/663F: 8D C8 D1     STA $D1C8
C1/6642: B9 DC D1     LDA $D1DC,Y
C1/6645: 85 8E        STA $8E
C1/6647: B9 DD D1     LDA $D1DD,Y
C1/664A: 85 90        STA $90
C1/664C: B9 D9 D1     LDA $D1D9,Y
C1/664F: 85 92        STA $92
C1/6651: B9 E7 D1     LDA $D1E7,Y
C1/6654: 29 80        AND #$80
C1/6656: 85 96        STA $96
C1/6658: 64 97        STZ $97
C1/665A: 64 94        STZ $94
C1/665C: B9 E7 D1     LDA $D1E7,Y
C1/665F: 29 40        AND #$40
C1/6661: F0 04        BEQ $6667
C1/6663: A9 35        LDA #$35
C1/6665: 80 02        BRA $6669
C1/6667: A9 37        LDA #$37
C1/6669: 85 95        STA $95
C1/666B: B9 E7 D1     LDA $D1E7,Y
C1/666E: 29 20        AND #$20
C1/6670: F0 06        BEQ $6678
C1/6672: A5 95        LDA $95
C1/6674: 29 EF        AND #$EF
C1/6676: 85 95        STA $95
C1/6678: 20 8C 69     JSR $698C
C1/667B: 60           RTS 

; [  ]

C1/667C: AD D3 DB     LDA $DBD3
C1/667F: D0 53        BNE $66D4
C1/6681: 7B           TDC 
C1/6682: AA           TAX 
C1/6683: 64 8E        STZ $8E
C1/6685: BD CB D1     LDA $D1CB,X
C1/6688: D0 44        BNE $66CE
C1/668A: BD CF D1     LDA $D1CF,X
C1/668D: F0 3F        BEQ $66CE
C1/668F: C9 08        CMP #$08
C1/6691: D0 05        BNE $6698
C1/6693: 20 D5 66     JSR $66D5
C1/6696: 80 36        BRA $66CE
C1/6698: 48           PHA 
C1/6699: 8A           TXA 
C1/669A: 0A           ASL 
C1/669B: 0A           ASL 
C1/669C: 0A           ASL 
C1/669D: 0A           ASL 
C1/669E: 0A           ASL 
C1/669F: A8           TAY 
C1/66A0: 68           PLA 
C1/66A1: C9 02        CMP #$02
C1/66A3: D0 0B        BNE $66B0
C1/66A5: B9 4D CF     LDA $CF4D,Y
C1/66A8: C9 03        CMP #$03
C1/66AA: D0 04        BNE $66B0
C1/66AC: A9 05        LDA #$05
C1/66AE: 85 8E        STA $8E
C1/66B0: B9 4E CF     LDA $CF4E,Y
C1/66B3: D0 19        BNE $66CE
C1/66B5: 64 8A        STZ $8A
C1/66B7: BD CF D1     LDA $D1CF,X
C1/66BA: C9 06        CMP #$06
C1/66BC: F0 0B        BEQ $66C9
C1/66BE: BD ED DB     LDA $DBED,X
C1/66C1: 18           CLC 
C1/66C2: 65 8E        ADC $8E
C1/66C4: 85 8A        STA $8A
C1/66C6: BD CF D1     LDA $D1CF,X
C1/66C9: DA           PHX 
C1/66CA: 20 3A 67     JSR $673A
C1/66CD: FA           PLX 
C1/66CE: E8           INX 
C1/66CF: E0 04 00     CPX #$0004
C1/66D2: D0 AF        BNE $6683
C1/66D4: 60           RTS 

; [  ]

C1/66D5: DA           PHX 
C1/66D6: 8A           TXA 
C1/66D7: 85 8C        STA $8C
C1/66D9: 0A           ASL 
C1/66DA: 0A           ASL 
C1/66DB: 0A           ASL 
C1/66DC: 0A           ASL 
C1/66DD: 0A           ASL 
C1/66DE: A8           TAY 
C1/66DF: B9 45 CF     LDA $CF45,Y
C1/66E2: 18           CLC 
C1/66E3: 79 49 CF     ADC $CF49,Y
C1/66E6: 45 F6        EOR $F6
C1/66E8: 38           SEC 
C1/66E9: E5 F9        SBC $F9
C1/66EB: 85 88        STA $88
C1/66ED: B9 46 CF     LDA $CF46,Y
C1/66F0: 18           CLC 
C1/66F1: 79 4A CF     ADC $CF4A,Y
C1/66F4: 18           CLC 
C1/66F5: 7D ED DB     ADC $DBED,X
C1/66F8: 85 89        STA $89
C1/66FA: B9 44 CF     LDA $CF44,Y
C1/66FD: C2 20        REP #$20
C1/66FF: 0A           ASL 
C1/6700: 0A           ASL 
C1/6701: A8           TAY 
C1/6702: 7B           TDC 
C1/6703: E2 20        SEP #$20
C1/6705: A5 8C        LDA $8C
C1/6707: 0A           ASL 
C1/6708: AA           TAX 
C1/6709: A9 02        LDA #$02
C1/670B: 85 8A        STA $8A
C1/670D: A5 88        LDA $88
C1/670F: 99 00 02     STA $0200,Y
C1/6712: A5 89        LDA $89
C1/6714: 38           SEC 
C1/6715: E9 08        SBC #$08
C1/6717: 99 01 02     STA $0201,Y
C1/671A: BD 74 F8     LDA $F874,X
C1/671D: 18           CLC 
C1/671E: 69 C6        ADC #$C6
C1/6720: 99 02 02     STA $0202,Y
C1/6723: A9 31        LDA #$31
C1/6725: 99 03 02     STA $0203,Y
C1/6728: A5 88        LDA $88
C1/672A: 18           CLC 
C1/672B: 69 08        ADC #$08
C1/672D: 85 88        STA $88
C1/672F: C8           INY 
C1/6730: C8           INY 
C1/6731: C8           INY 
C1/6732: C8           INY 
C1/6733: E8           INX 
C1/6734: C6 8A        DEC $8A
C1/6736: D0 D5        BNE $670D
C1/6738: FA           PLX 
C1/6739: 60           RTS 

; [  ]

C1/673A: 48           PHA 
C1/673B: 3A           DEC 
C1/673C: 0A           ASL 
C1/673D: 0A           ASL 
C1/673E: 0A           ASL 
C1/673F: 85 88        STA $88
C1/6741: 68           PLA 
C1/6742: C9 07        CMP #$07
C1/6744: D0 04        BNE $674A
C1/6746: A9 04        LDA #$04        ; 4 sprites
C1/6748: 80 02        BRA $674C
C1/674A: A9 02        LDA #$02        ; 2 sprites
C1/674C: 85 8C        STA $8C
C1/674E: 64 89        STZ $89
C1/6750: 8A           TXA 
C1/6751: 0A           ASL 
C1/6752: 0A           ASL 
C1/6753: 0A           ASL 
C1/6754: 0A           ASL 
C1/6755: 0A           ASL 
C1/6756: A8           TAY 
C1/6757: B9 56 CF     LDA $CF56,Y
C1/675A: 10 07        BPL $6763
C1/675C: A5 88        LDA $88
C1/675E: 18           CLC 
C1/675F: 69 38        ADC #$38
C1/6761: 85 88        STA $88
C1/6763: B9 50 CF     LDA $CF50,Y
C1/6766: 29 38        AND #$38
C1/6768: 4A           LSR 
C1/6769: 4A           LSR 
C1/676A: 4A           LSR 
C1/676B: 18           CLC 
C1/676C: 65 88        ADC $88
C1/676E: AA           TAX 
C1/676F: BF E2 33 D8  LDA $D833E2,X
C1/6773: C2 20        REP #$20
C1/6775: 0A           ASL 
C1/6776: 0A           ASL 
C1/6777: 0A           ASL 
C1/6778: 0A           ASL 
C1/6779: AA           TAX 
C1/677A: 7B           TDC 
C1/677B: E2 20        SEP #$20
C1/677D: B9 45 CF     LDA $CF45,Y
C1/6780: 18           CLC 
C1/6781: 79 49 CF     ADC $CF49,Y
C1/6784: 85 88        STA $88         ; x offset
C1/6786: B9 46 CF     LDA $CF46,Y
C1/6789: 18           CLC 
C1/678A: 79 4A CF     ADC $CF4A,Y
C1/678D: 18           CLC 
C1/678E: 65 8A        ADC $8A
C1/6790: 85 8A        STA $8A
C1/6792: B9 44 CF     LDA $CF44,Y
C1/6795: C2 20        REP #$20
C1/6797: 0A           ASL 
C1/6798: 0A           ASL 
C1/6799: A8           TAY 
C1/679A: 7B           TDC 
C1/679B: E2 20        SEP #$20
C1/679D: BF 52 34 D8  LDA $D83452,X
C1/67A1: 18           CLC 
C1/67A2: 65 88        ADC $88         ; x offset
C1/67A4: 45 F6        EOR $F6
C1/67A6: 38           SEC 
C1/67A7: E5 F8        SBC $F8         ; x offset (for back attack)
C1/67A9: 99 00 02     STA $0200,Y
C1/67AC: C8           INY 
C1/67AD: E8           INX 
C1/67AE: BF 52 34 D8  LDA $D83452,X
C1/67B2: 18           CLC 
C1/67B3: 65 8A        ADC $8A         ; y offset
C1/67B5: 99 00 02     STA $0200,Y
C1/67B8: C8           INY 
C1/67B9: E8           INX 
C1/67BA: BF 52 34 D8  LDA $D83452,X
C1/67BE: 99 00 02     STA $0200,Y     ; tile index
C1/67C1: C8           INY 
C1/67C2: E8           INX 
C1/67C3: BF 52 34 D8  LDA $D83452,X
C1/67C7: 45 F7        EOR $F7
C1/67C9: 99 00 02     STA $0200,Y     ; tile flags
C1/67CC: C8           INY 
C1/67CD: E8           INX 
C1/67CE: C6 8C        DEC $8C
C1/67D0: D0 CB        BNE $679D
C1/67D2: 60           RTS 

; [  ]

C1/67D3: 7B           TDC 
C1/67D4: AA           TAX 
C1/67D5: A9 F0        LDA #$F0
C1/67D7: 9D 20 02     STA $0220,X
C1/67DA: 9D 29 7D     STA $7D29,X
C1/67DD: E8           INX 
C1/67DE: E0 D8 00     CPX #$00D8
C1/67E1: D0 F4        BNE $67D7
C1/67E3: 60           RTS 

; [  ]

C1/67E4: AD AE D1     LDA $D1AE
C1/67E7: D0 03        BNE $67EC
C1/67E9: 4C F0 68     JMP $68F0
C1/67EC: 64 EF        STZ $EF
C1/67EE: 20 7D 69     JSR $697D
C1/67F1: 7B           TDC 
C1/67F2: AA           TAX 
C1/67F3: A9 AA        LDA #$AA
C1/67F5: 9D 02 04     STA $0402,X
C1/67F8: E8           INX 
C1/67F9: E0 0C 00     CPX #$000C
C1/67FC: D0 F7        BNE $67F5
C1/67FE: AD BB D1     LDA $D1BB
C1/6801: D0 05        BNE $6808
C1/6803: 20 D3 67     JSR $67D3
C1/6806: 80 4F        BRA $6857
C1/6808: AD BB D1     LDA $D1BB
C1/680B: C9 FF        CMP #$FF
C1/680D: D0 09        BNE $6818
C1/680F: 20 D3 67     JSR $67D3
C1/6812: 9C AE D1     STZ $D1AE
C1/6815: 4C F0 68     JMP $68F0
C1/6818: AD BB D1     LDA $D1BB
C1/681B: 10 3A        BPL $6857
C1/681D: A9 01        LDA #$01
C1/681F: 8D BB D1     STA $D1BB
C1/6822: A2 3B 00     LDX #$003B
C1/6825: BD 1C 02     LDA $021C,X
C1/6828: 49 40        EOR #$40
C1/682A: 9D 20 02     STA $0220,X
C1/682D: 29 40        AND #$40
C1/682F: F0 0B        BEQ $683C
C1/6831: BD 19 02     LDA $0219,X
C1/6834: 38           SEC 
C1/6835: E9 08        SBC #$08
C1/6837: 9D 1D 02     STA $021D,X
C1/683A: 80 09        BRA $6845
C1/683C: BD 19 02     LDA $0219,X
C1/683F: 18           CLC 
C1/6840: 69 08        ADC #$08
C1/6842: 9D 1D 02     STA $021D,X
C1/6845: BD 1B 02     LDA $021B,X
C1/6848: 9D 1F 02     STA $021F,X
C1/684B: BD 1A 02     LDA $021A,X
C1/684E: 9D 1E 02     STA $021E,X
C1/6851: CA           DEX 
C1/6852: CA           DEX 
C1/6853: CA           DEX 
C1/6854: CA           DEX 
C1/6855: 10 CE        BPL $6825
C1/6857: AD B9 D1     LDA $D1B9
C1/685A: C2 20        REP #$20
C1/685C: 18           CLC 
C1/685D: 6D B0 D1     ADC $D1B0
C1/6860: 0A           ASL 
C1/6861: AA           TAX 
C1/6862: BF 86 A4 D9  LDA $D9A486,X
C1/6866: 85 88        STA $88
C1/6868: 7B           TDC 
C1/6869: E2 20        SEP #$20
C1/686B: A9 D9        LDA #$D9
C1/686D: 85 8A        STA $8A
C1/686F: AE 92 D1     LDX $D192
C1/6872: 86 8C        STX $8C
C1/6874: A5 8C        LDA $8C
C1/6876: 85 98        STA $98
C1/6878: A5 8D        LDA $8D
C1/687A: 85 9A        STA $9A
C1/687C: 20 4B FE     JSR $FE4B
C1/687F: AD B7 D1     LDA $D1B7
C1/6882: 8D C5 D1     STA $D1C5
C1/6885: AD B8 D1     LDA $D1B8
C1/6888: 8D C7 D1     STA $D1C7
C1/688B: 9C C6 D1     STZ $D1C6
C1/688E: 9C C8 D1     STZ $D1C8
C1/6891: AD B2 D1     LDA $D1B2
C1/6894: 85 8E        STA $8E
C1/6896: AD B3 D1     LDA $D1B3
C1/6899: 85 90        STA $90
C1/689B: AD B6 D1     LDA $D1B6
C1/689E: 10 0D        BPL $68AD
C1/68A0: DA           PHX 
C1/68A1: 29 03        AND #$03
C1/68A3: AA           TAX 
C1/68A4: A5 90        LDA $90
C1/68A6: 18           CLC 
C1/68A7: 7D ED DB     ADC $DBED,X
C1/68AA: 85 90        STA $90
C1/68AC: FA           PLX 
C1/68AD: AD AF D1     LDA $D1AF
C1/68B0: 85 92        STA $92
C1/68B2: 64 97        STZ $97
C1/68B4: AD B6 D1     LDA $D1B6
C1/68B7: 29 40        AND #$40
C1/68B9: 85 96        STA $96
C1/68BB: F0 07        BEQ $68C4
C1/68BD: A5 8E        LDA $8E
C1/68BF: 38           SEC 
C1/68C0: E9 08        SBC #$08
C1/68C2: 85 8E        STA $8E
C1/68C4: 64 94        STZ $94
C1/68C6: A9 37        LDA #$37
C1/68C8: 85 95        STA $95
C1/68CA: 20 8C 69     JSR $698C
C1/68CD: AD AF D1     LDA $D1AF
C1/68D0: 85 88        STA $88
C1/68D2: A9 10        LDA #$10
C1/68D4: 85 8C        STA $8C
C1/68D6: A5 88        LDA $88
C1/68D8: 4A           LSR 
C1/68D9: 4A           LSR 
C1/68DA: A8           TAY 
C1/68DB: A5 88        LDA $88
C1/68DD: 29 03        AND #$03
C1/68DF: AA           TAX 
C1/68E0: BF 79 69 C1  LDA $C16979,X
C1/68E4: 19 00 04     ORA $0400,Y
C1/68E7: 99 00 04     STA $0400,Y
C1/68EA: E6 88        INC $88
C1/68EC: C6 8C        DEC $8C
C1/68EE: D0 E6        BNE $68D6
C1/68F0: 60           RTS 

; [  ]

C1/68F1: AD A0 D1     LDA $D1A0
C1/68F4: D0 01        BNE $68F7
C1/68F6: 60           RTS 
C1/68F7: 64 EF        STZ $EF
C1/68F9: 20 7D 69     JSR $697D
C1/68FC: AD AB D1     LDA $D1AB
C1/68FF: C2 20        REP #$20
C1/6901: 18           CLC 
C1/6902: 6D A2 D1     ADC $D1A2
C1/6905: 0A           ASL 
C1/6906: AA           TAX 
C1/6907: BF 86 A4 D9  LDA $D9A486,X   ; pointers to ??? (+$D90000)
C1/690B: 85 88        STA $88
C1/690D: 7B           TDC 
C1/690E: E2 20        SEP #$20
C1/6910: A9 D9        LDA #$D9
C1/6912: 85 8A        STA $8A
C1/6914: AE 84 D1     LDX $D184
C1/6917: 86 8C        STX $8C
C1/6919: A5 8C        LDA $8C
C1/691B: 85 98        STA $98
C1/691D: A5 8D        LDA $8D
C1/691F: 85 9A        STA $9A
C1/6921: 20 4B FE     JSR $FE4B
C1/6924: AD A9 D1     LDA $D1A9
C1/6927: 8D C5 D1     STA $D1C5
C1/692A: AD AA D1     LDA $D1AA
C1/692D: 8D C7 D1     STA $D1C7
C1/6930: 9C C6 D1     STZ $D1C6
C1/6933: 9C C8 D1     STZ $D1C8
C1/6936: AD A4 D1     LDA $D1A4
C1/6939: 85 8E        STA $8E
C1/693B: AD A5 D1     LDA $D1A5
C1/693E: 85 90        STA $90
C1/6940: AD A1 D1     LDA $D1A1
C1/6943: 85 92        STA $92
C1/6945: AD A8 D1     LDA $D1A8
C1/6948: 85 96        STA $96
C1/694A: 64 97        STZ $97
C1/694C: 64 94        STZ $94
C1/694E: A9 35        LDA #$35
C1/6950: 85 95        STA $95
C1/6952: 20 8C 69     JSR $698C       ; 
C1/6955: AD A1 D1     LDA $D1A1
C1/6958: 85 88        STA $88
C1/695A: A9 04        LDA #$04
C1/695C: 85 8C        STA $8C
C1/695E: A5 88        LDA $88
C1/6960: 4A           LSR 
C1/6961: 4A           LSR 
C1/6962: A8           TAY 
C1/6963: A5 88        LDA $88
C1/6965: 29 03        AND #$03
C1/6967: AA           TAX 
C1/6968: BF 79 69 C1  LDA $C16979,X
C1/696C: 19 00 04     ORA $0400,Y     ; 16x16 sprite
C1/696F: 99 00 04     STA $0400,Y
C1/6972: E6 88        INC $88
C1/6974: C6 8C        DEC $8C
C1/6976: D0 E6        BNE $695E
C1/6978: 60           RTS 

C1/6979: 02 08 20 80

C1/697D: 7B           TDC 
C1/697E: AA           TAX 
C1/697F: 9E 18 DB     STZ $DB18,X
C1/6982: 9E 28 DB     STZ $DB28,X
C1/6985: E8           INX 
C1/6986: E0 10 00     CPX #$0010
C1/6989: D0 F4        BNE $697F
C1/698B: 60           RTS 

; [  ]

C1/698C: A6 9C        LDX $9C         ; tile count
C1/698E: DA           PHX 
C1/698F: AD 6B DB     LDA $DB6B
C1/6992: F0 0F        BEQ $69A3
C1/6994: AD D3 DB     LDA $DBD3
C1/6997: F0 05        BEQ $699E
C1/6999: A0 B0 00     LDY #$00B0
C1/699C: 80 08        BRA $69A6
C1/699E: A0 90 00     LDY #$0090
C1/69A1: 80 03        BRA $69A6
C1/69A3: A0 E0 00     LDY #$00E0
C1/69A6: 8C 6C DB     STY $DB6C
C1/69A9: 64 8F        STZ $8F
C1/69AB: 64 91        STZ $91
C1/69AD: A5 96        LDA $96
C1/69AF: F0 0A        BEQ $69BB
C1/69B1: A5 8E        LDA $8E
C1/69B3: 49 FF        EOR #$FF
C1/69B5: 1A           INC 
C1/69B6: 38           SEC 
C1/69B7: E9 08        SBC #$08
C1/69B9: 85 8E        STA $8E
C1/69BB: A5 8E        LDA $8E
C1/69BD: 10 04        BPL $69C3
C1/69BF: A9 FF        LDA #$FF
C1/69C1: 85 8F        STA $8F
C1/69C3: A5 90        LDA $90
C1/69C5: 10 04        BPL $69CB
C1/69C7: A9 FF        LDA #$FF
C1/69C9: 85 91        STA $91
C1/69CB: A5 8C        LDA $8C
C1/69CD: 0A           ASL 
C1/69CE: 0A           ASL 
C1/69CF: 0A           ASL 
C1/69D0: 85 98        STA $98
C1/69D2: 64 99        STZ $99
C1/69D4: A5 8D        LDA $8D
C1/69D6: 0A           ASL 
C1/69D7: 0A           ASL 
C1/69D8: 0A           ASL 
C1/69D9: 85 9A        STA $9A
C1/69DB: 64 9B        STZ $9B
C1/69DD: C2 20        REP #$20
C1/69DF: A5 96        LDA $96
C1/69E1: F0 04        BEQ $69E7
C1/69E3: 46 98        LSR $98
C1/69E5: 80 06        BRA $69ED
C1/69E7: 7B           TDC 
C1/69E8: 38           SEC 
C1/69E9: E5 98        SBC $98
C1/69EB: 85 98        STA $98
C1/69ED: 7B           TDC 
C1/69EE: 38           SEC 
C1/69EF: E5 9A        SBC $9A
C1/69F1: 85 9A        STA $9A
C1/69F3: 7B           TDC 
C1/69F4: AA           TAX 
C1/69F5: E2 20        SEP #$20
C1/69F7: A5 8D        LDA $8D
C1/69F9: C2 20        REP #$20
C1/69FB: 85 9E        STA $9E
C1/69FD: A5 98        LDA $98
C1/69FF: 85 9C        STA $9C
C1/6A01: A5 8C        LDA $8C
C1/6A03: 29 FF 00     AND #$00FF
C1/6A06: A8           TAY 
C1/6A07: AD 3C DB     LDA $DB3C
C1/6A0A: F0 08        BEQ $6A14
C1/6A0C: A5 9C        LDA $9C
C1/6A0E: 18           CLC 
C1/6A0F: 7D 18 DB     ADC $DB18,X
C1/6A12: 80 02        BRA $6A16
C1/6A14: A5 9C        LDA $9C
C1/6A16: 18           CLC 
C1/6A17: 6D C5 D1     ADC $D1C5
C1/6A1A: 18           CLC 
C1/6A1B: 65 8E        ADC $8E
C1/6A1D: C9 F8 00     CMP #$00F8
C1/6A20: 90 05        BCC $6A27
C1/6A22: A9 F0 00     LDA #$00F0
C1/6A25: 80 26        BRA $6A4D
C1/6A27: 9D 88 F5     STA $F588,X
C1/6A2A: AD 3C DB     LDA $DB3C
C1/6A2D: F0 08        BEQ $6A37
C1/6A2F: A5 9A        LDA $9A
C1/6A31: 18           CLC 
C1/6A32: 7D 28 DB     ADC $DB28,X
C1/6A35: 80 02        BRA $6A39
C1/6A37: A5 9A        LDA $9A
C1/6A39: 18           CLC 
C1/6A3A: 6D C7 D1     ADC $D1C7
C1/6A3D: 18           CLC 
C1/6A3E: 65 90        ADC $90
C1/6A40: CD 6C DB     CMP $DB6C
C1/6A43: 90 08        BCC $6A4D
C1/6A45: C9 F0 FF     CMP #$FFF0
C1/6A48: B0 03        BCS $6A4D
C1/6A4A: A9 F0 00     LDA #$00F0
C1/6A4D: 9D 89 F5     STA $F589,X
C1/6A50: A5 96        LDA $96
C1/6A52: F0 0A        BEQ $6A5E
C1/6A54: A5 9C        LDA $9C
C1/6A56: 38           SEC 
C1/6A57: E9 10 00     SBC #$0010
C1/6A5A: 85 9C        STA $9C
C1/6A5C: 80 08        BRA $6A66
C1/6A5E: A5 9C        LDA $9C
C1/6A60: 18           CLC 
C1/6A61: 69 10 00     ADC #$0010
C1/6A64: 85 9C        STA $9C
C1/6A66: E8           INX 
C1/6A67: E8           INX 
C1/6A68: 88           DEY 
C1/6A69: D0 9C        BNE $6A07
C1/6A6B: A5 9A        LDA $9A
C1/6A6D: 18           CLC 
C1/6A6E: 69 10 00     ADC #$0010
C1/6A71: 85 9A        STA $9A
C1/6A73: C6 9E        DEC $9E
C1/6A75: D0 86        BNE $69FD
C1/6A77: 7B           TDC 
C1/6A78: E2 20        SEP #$20
C1/6A7A: FA           PLX 
C1/6A7B: 86 9C        STX $9C
C1/6A7D: A5 92        LDA $92
C1/6A7F: C2 20        REP #$20
C1/6A81: 0A           ASL 
C1/6A82: 0A           ASL 
C1/6A83: AA           TAX 
C1/6A84: 7B           TDC 
C1/6A85: 85 8C        STA $8C
C1/6A87: E2 20        SEP #$20
C1/6A89: A7 88        LDA [$88]
C1/6A8B: 85 98        STA $98
C1/6A8D: 30 0C        BMI $6A9B       ; branch if string of tiles
C1/6A8F: 20 6C 6B     JSR $6B6C       ; decode single animation frame tile
C1/6A92: B0 1C        BCS $6AB0
C1/6A94: A4 88        LDY $88
C1/6A96: C8           INY 
C1/6A97: 84 88        STY $88
C1/6A99: 80 EE        BRA $6A89
C1/6A9B: A4 88        LDY $88
C1/6A9D: C8           INY 
C1/6A9E: 84 88        STY $88
C1/6AA0: A7 88        LDA [$88]
C1/6AA2: 85 9E        STA $9E
C1/6AA4: 20 B1 6A     JSR $6AB1       ; decode string of animation frame tiles
C1/6AA7: B0 07        BCS $6AB0
C1/6AA9: A4 88        LDY $88
C1/6AAB: C8           INY 
C1/6AAC: 84 88        STY $88
C1/6AAE: 80 D9        BRA $6A89
C1/6AB0: 60           RTS 

; [ decode string of animation frame tiles ]

; $98: 1vhttttt
;      v = v-flip
;      h = h-flip
;      t = tile index
; $9E: tile count

C1/6AB1: A5 98        LDA $98
C1/6AB3: 29 1F        AND #$1F
C1/6AB5: C9 1F        CMP #$1F
C1/6AB7: D0 1A        BNE $6AD3
C1/6AB9: A5 9E        LDA $9E         ; skip n tiles ???
C1/6ABB: C2 20        REP #$20
C1/6ABD: 0A           ASL 
C1/6ABE: 18           CLC 
C1/6ABF: 65 8C        ADC $8C
C1/6AC1: 85 8C        STA $8C
C1/6AC3: 7B           TDC 
C1/6AC4: E2 20        SEP #$20
C1/6AC6: A5 9C        LDA $9C
C1/6AC8: 38           SEC 
C1/6AC9: E5 9E        SBC $9E
C1/6ACB: 85 9C        STA $9C
C1/6ACD: F0 02        BEQ $6AD1
C1/6ACF: 18           CLC 
C1/6AD0: 60           RTS 
C1/6AD1: 38           SEC 
C1/6AD2: 60           RTS 
C1/6AD3: A4 8C        LDY $8C
C1/6AD5: 29 07        AND #$07
C1/6AD7: 0A           ASL 
C1/6AD8: 85 8B        STA $8B
C1/6ADA: A5 98        LDA $98
C1/6ADC: 29 18        AND #$18
C1/6ADE: 0A           ASL 
C1/6ADF: 0A           ASL 
C1/6AE0: 18           CLC 
C1/6AE1: 65 8B        ADC $8B
C1/6AE3: 18           CLC 
C1/6AE4: 65 94        ADC $94
C1/6AE6: 85 9A        STA $9A
C1/6AE8: A5 98        LDA $98
C1/6AEA: 0A           ASL 
C1/6AEB: 29 C0        AND #$C0        ; vh flip
C1/6AED: 05 95        ORA $95
C1/6AEF: 45 96        EOR $96
C1/6AF1: 85 9B        STA $9B
C1/6AF3: A5 92        LDA $92
C1/6AF5: 18           CLC 
C1/6AF6: 65 9E        ADC $9E
C1/6AF8: 85 92        STA $92
C1/6AFA: A5 9E        LDA $9E
C1/6AFC: 48           PHA 
C1/6AFD: A5 EF        LDA $EF
C1/6AFF: F0 2E        BEQ $6B2F       ; branch if sprite
C1/6B01: B9 88 F5     LDA $F588,Y
C1/6B04: 45 F6        EOR $F6
C1/6B06: 38           SEC 
C1/6B07: E5 F9        SBC $F9
C1/6B09: 9D 09 7D     STA $7D09,X
C1/6B0C: B9 89 F5     LDA $F589,Y
C1/6B0F: 9D 0A 7D     STA $7D0A,X
C1/6B12: A5 9A        LDA $9A
C1/6B14: 9D 0B 7D     STA $7D0B,X
C1/6B17: A5 9B        LDA $9B
C1/6B19: 45 F7        EOR $F7
C1/6B1B: 9D 0C 7D     STA $7D0C,X
C1/6B1E: E8           INX 
C1/6B1F: E8           INX 
C1/6B20: E8           INX 
C1/6B21: E8           INX 
C1/6B22: C8           INY 
C1/6B23: C8           INY 
C1/6B24: C6 9E        DEC $9E
C1/6B26: D0 D9        BNE $6B01
C1/6B28: C6 9F        DEC $9F
C1/6B2A: 10 D5        BPL $6B01
C1/6B2C: 4C 5A 6B     JMP $6B5A
C1/6B2F: B9 88 F5     LDA $F588,Y
C1/6B32: 45 F6        EOR $F6
C1/6B34: 38           SEC 
C1/6B35: E5 F9        SBC $F9
C1/6B37: 9D 00 02     STA $0200,X     ; x position
C1/6B3A: B9 89 F5     LDA $F589,Y
C1/6B3D: 9D 01 02     STA $0201,X     ; y position
C1/6B40: A5 9A        LDA $9A
C1/6B42: 9D 02 02     STA $0202,X     ; tile index
C1/6B45: A5 9B        LDA $9B
C1/6B47: 45 F7        EOR $F7
C1/6B49: 9D 03 02     STA $0203,X     ; vhoopppm
C1/6B4C: E8           INX 
C1/6B4D: E8           INX 
C1/6B4E: E8           INX 
C1/6B4F: E8           INX 
C1/6B50: C8           INY 
C1/6B51: C8           INY 
C1/6B52: C6 9E        DEC $9E
C1/6B54: D0 D9        BNE $6B2F
C1/6B56: C6 9F        DEC $9F
C1/6B58: 10 D5        BPL $6B2F
C1/6B5A: 84 8C        STY $8C
C1/6B5C: 68           PLA 
C1/6B5D: 85 9E        STA $9E
C1/6B5F: A5 9C        LDA $9C
C1/6B61: 38           SEC 
C1/6B62: E5 9E        SBC $9E
C1/6B64: 85 9C        STA $9C
C1/6B66: F0 02        BEQ $6B6A
C1/6B68: 18           CLC 
C1/6B69: 60           RTS 
C1/6B6A: 38           SEC 
C1/6B6B: 60           RTS 

; [ decode single animation frame tile ]

; $98: 0vhttttt
;      c = tile count
;      v = v-flip
;      h = h-flip
;      t = tile index

C1/6B6C: A4 8C        LDY $8C
C1/6B6E: A5 98        LDA $98
C1/6B70: 29 1F        AND #$1F
C1/6B72: C9 1F        CMP #$1F
C1/6B74: F0 6E        BEQ $6BE4       ; skip one tile
C1/6B76: 29 07        AND #$07
C1/6B78: 0A           ASL 
C1/6B79: 85 8B        STA $8B
C1/6B7B: A5 EF        LDA $EF
C1/6B7D: F0 31        BEQ $6BB0       ; branch if sprite
C1/6B7F: A5 98        LDA $98
C1/6B81: 29 18        AND #$18
C1/6B83: 0A           ASL 
C1/6B84: 0A           ASL 
C1/6B85: 18           CLC 
C1/6B86: 65 8B        ADC $8B
C1/6B88: 18           CLC 
C1/6B89: 65 94        ADC $94
C1/6B8B: 9D 0B 7D     STA $7D0B,X
C1/6B8E: A5 98        LDA $98
C1/6B90: 0A           ASL 
C1/6B91: 29 C0        AND #$C0        ; vh flip
C1/6B93: 05 95        ORA $95
C1/6B95: 45 96        EOR $96
C1/6B97: 45 F7        EOR $F7
C1/6B99: 9D 0C 7D     STA $7D0C,X
C1/6B9C: B9 88 F5     LDA $F588,Y
C1/6B9F: 45 F6        EOR $F6
C1/6BA1: 38           SEC 
C1/6BA2: E5 F9        SBC $F9
C1/6BA4: 9D 09 7D     STA $7D09,X
C1/6BA7: B9 89 F5     LDA $F589,Y
C1/6BAA: 9D 0A 7D     STA $7D0A,X
C1/6BAD: 4C DE 6B     JMP $6BDE
C1/6BB0: A5 98        LDA $98
C1/6BB2: 29 18        AND #$18
C1/6BB4: 0A           ASL 
C1/6BB5: 0A           ASL 
C1/6BB6: 18           CLC 
C1/6BB7: 65 8B        ADC $8B
C1/6BB9: 18           CLC 
C1/6BBA: 65 94        ADC $94
C1/6BBC: 9D 02 02     STA $0202,X     ; tile index
C1/6BBF: A5 98        LDA $98
C1/6BC1: 0A           ASL 
C1/6BC2: 29 C0        AND #$C0
C1/6BC4: 05 95        ORA $95
C1/6BC6: 45 96        EOR $96
C1/6BC8: 45 F7        EOR $F7
C1/6BCA: 9D 03 02     STA $0203,X     ; vhoopppm
C1/6BCD: B9 88 F5     LDA $F588,Y
C1/6BD0: 45 F6        EOR $F6
C1/6BD2: 38           SEC 
C1/6BD3: E5 F9        SBC $F9
C1/6BD5: 9D 00 02     STA $0200,X     ; x position
C1/6BD8: B9 89 F5     LDA $F589,Y
C1/6BDB: 9D 01 02     STA $0201,X     ; y position
C1/6BDE: E6 92        INC $92
C1/6BE0: E8           INX 
C1/6BE1: E8           INX 
C1/6BE2: E8           INX 
C1/6BE3: E8           INX 
C1/6BE4: C8           INY 
C1/6BE5: C8           INY 
C1/6BE6: 84 8C        STY $8C
C1/6BE8: C6 9C        DEC $9C
C1/6BEA: F0 02        BEQ $6BEE
C1/6BEC: 18           CLC 
C1/6BED: 60           RTS 
C1/6BEE: 38           SEC 
C1/6BEF: 60           RTS 

; [ hide damage numeral sprites ]

C1/6BF0: 7B           TDC 
C1/6BF1: AA           TAX 
C1/6BF2: A9 F8        LDA #$F8
C1/6BF4: 9D 20 02     STA $0220,X
C1/6BF7: E8           INX 
C1/6BF8: E0 C0 00     CPX #$00C0      ; 48 sprites (4 digits per character/monster)
C1/6BFB: D0 F7        BNE $6BF4
C1/6BFD: 7B           TDC 
C1/6BFE: AA           TAX 
C1/6BFF: 9D 02 04     STA $0402,X     ; clear hi-sprite data
C1/6C02: E8           INX 
C1/6C03: E0 0C 00     CPX #$000C
C1/6C06: D0 F7        BNE $6BFF
C1/6C08: 60           RTS 

; [  ]

C1/6C09: 7B           TDC 
C1/6C0A: AA           TAX 
C1/6C0B: A9 F8        LDA #$F8
C1/6C0D: 9D E0 02     STA $02E0,X
C1/6C10: E8           INX 
C1/6C11: E0 18 00     CPX #$0018
C1/6C14: D0 F7        BNE $6C0D
C1/6C16: 9C 0E 04     STZ $040E
C1/6C19: 60           RTS 

; [ get damage numeral vertical offset ]

C1/6C1A: DA           PHX 
C1/6C1B: BD 78 D1     LDA $D178,X     ; frame counter
C1/6C1E: C9 24        CMP #$24
C1/6C20: 90 02        BCC $6C24
C1/6C22: A9 24        LDA #$24
C1/6C24: AA           TAX 
C1/6C25: BF 72 B9 D4  LDA $D4B972,X   ; first digit
C1/6C29: 18           CLC 
C1/6C2A: 65 8B        ADC $8B
C1/6C2C: 85 8C        STA $8C
C1/6C2E: BF 6F B9 D4  LDA $D4B96F,X   ; second digit
C1/6C32: 18           CLC 
C1/6C33: 65 8B        ADC $8B
C1/6C35: 85 8D        STA $8D
C1/6C37: BF 6C B9 D4  LDA $D4B96C,X   ; third digit
C1/6C3B: 18           CLC 
C1/6C3C: 65 8B        ADC $8B
C1/6C3E: 85 8E        STA $8E
C1/6C40: BF 69 B9 D4  LDA $D4B969,X   ; fourth digit
C1/6C44: 18           CLC 
C1/6C45: 65 8B        ADC $8B
C1/6C47: 85 8F        STA $8F
C1/6C49: FA           PLX 
C1/6C4A: BD 18 D1     LDA $D118,X
C1/6C4D: 10 08        BPL $6C57       ; branch if not miss
C1/6C4F: A5 8C        LDA $8C         ; digits move in unison
C1/6C51: 85 8D        STA $8D
C1/6C53: 85 8E        STA $8E
C1/6C55: 85 8F        STA $8F
C1/6C57: 60           RTS 

; [ update damage numeral sprites (golem ???) ]

C1/6C58: AD 16 D1     LDA $D116
C1/6C5B: D0 03        BNE $6C60
C1/6C5D: 4C D3 6C     JMP $6CD3
C1/6C60: 20 09 6C     JSR $6C09
C1/6C63: A0 E0 00     LDY #$00E0
C1/6C66: 7B           TDC 
C1/6C67: AA           TAX 
C1/6C68: BD 18 D1     LDA $D118,X
C1/6C6B: F0 59        BEQ $6CC6       ; branch if disabled for this object
C1/6C6D: BD 24 D1     LDA $D124,X
C1/6C70: 85 88        STA $88
C1/6C72: BD 60 D1     LDA $D160,X
C1/6C75: 85 8A        STA $8A
C1/6C77: BD 6C D1     LDA $D16C,X
C1/6C7A: 85 8B        STA $8B
C1/6C7C: 20 1A 6C     JSR $6C1A
C1/6C7F: DA           PHX 
C1/6C80: 8A           TXA 
C1/6C81: 0A           ASL 
C1/6C82: 0A           ASL 
C1/6C83: AA           TAX 
C1/6C84: 64 90        STZ $90
C1/6C86: DA           PHX 
C1/6C87: A5 90        LDA $90
C1/6C89: AA           TAX 
C1/6C8A: B5 8C        LDA $8C,X
C1/6C8C: 85 8B        STA $8B
C1/6C8E: FA           PLX 
C1/6C8F: A5 8A        LDA $8A
C1/6C91: 99 00 02     STA $0200,Y
C1/6C94: A5 8B        LDA $8B
C1/6C96: 99 01 02     STA $0201,Y
C1/6C99: BD 30 D1     LDA $D130,X
C1/6C9C: 99 02 02     STA $0202,Y
C1/6C9F: A5 88        LDA $88
C1/6CA1: 99 03 02     STA $0203,Y
C1/6CA4: A5 8A        LDA $8A
C1/6CA6: 18           CLC 
C1/6CA7: 69 08        ADC #$08
C1/6CA9: 85 8A        STA $8A
C1/6CAB: E8           INX 
C1/6CAC: C8           INY 
C1/6CAD: C8           INY 
C1/6CAE: C8           INY 
C1/6CAF: C8           INY 
C1/6CB0: E6 90        INC $90
C1/6CB2: A5 90        LDA $90
C1/6CB4: C9 04        CMP #$04
C1/6CB6: D0 CE        BNE $6C86
C1/6CB8: FA           PLX 
C1/6CB9: FE 78 D1     INC $D178,X
C1/6CBC: BD 78 D1     LDA $D178,X
C1/6CBF: C9 20        CMP #$20
C1/6CC1: D0 03        BNE $6CC6
C1/6CC3: 9E 18 D1     STZ $D118,X     ; disable damage numerals
C1/6CC6: 7B           TDC 
C1/6CC7: AA           TAX 
C1/6CC8: BD 18 D1     LDA $D118,X
C1/6CCB: D0 06        BNE $6CD3
C1/6CCD: 20 09 6C     JSR $6C09
C1/6CD0: 9C 16 D1     STZ $D116
C1/6CD3: 60           RTS 

; [ update damage numeral sprites ]

C1/6CD4: AD 14 D1     LDA $D114
C1/6CD7: D0 03        BNE $6CDC       ; branch if damage numerals pending
C1/6CD9: 4C 5B 6D     JMP $6D5B
C1/6CDC: 20 F0 6B     JSR $6BF0       ; hide damage numeral sprites
C1/6CDF: A0 20 00     LDY #$0020
C1/6CE2: 7B           TDC 
C1/6CE3: AA           TAX 
C1/6CE4: BD 18 D1     LDA $D118,X
C1/6CE7: F0 59        BEQ $6D42       ; branch if disabled for this object
C1/6CE9: BD 24 D1     LDA $D124,X     ; tile flags
C1/6CEC: 85 88        STA $88
C1/6CEE: BD 60 D1     LDA $D160,X
C1/6CF1: 85 8A        STA $8A
C1/6CF3: BD 6C D1     LDA $D16C,X
C1/6CF6: 85 8B        STA $8B
C1/6CF8: 20 1A 6C     JSR $6C1A       ; get damage numeral vertical offset
C1/6CFB: DA           PHX 
C1/6CFC: 8A           TXA 
C1/6CFD: 0A           ASL 
C1/6CFE: 0A           ASL 
C1/6CFF: AA           TAX 
C1/6D00: 64 90        STZ $90
C1/6D02: DA           PHX 
C1/6D03: A5 90        LDA $90
C1/6D05: AA           TAX 
C1/6D06: B5 8C        LDA $8C,X
C1/6D08: 85 8B        STA $8B
C1/6D0A: FA           PLX 
C1/6D0B: A5 8A        LDA $8A
C1/6D0D: 99 00 02     STA $0200,Y     ; x
C1/6D10: A5 8B        LDA $8B
C1/6D12: 99 01 02     STA $0201,Y     ; y
C1/6D15: BD 30 D1     LDA $D130,X
C1/6D18: 99 02 02     STA $0202,Y     ; tile index
C1/6D1B: A5 88        LDA $88
C1/6D1D: 99 03 02     STA $0203,Y     ; tile flags
C1/6D20: A5 8A        LDA $8A         ; next digit
C1/6D22: 18           CLC 
C1/6D23: 69 08        ADC #$08
C1/6D25: 85 8A        STA $8A
C1/6D27: E8           INX 
C1/6D28: C8           INY 
C1/6D29: C8           INY 
C1/6D2A: C8           INY 
C1/6D2B: C8           INY 
C1/6D2C: E6 90        INC $90
C1/6D2E: A5 90        LDA $90
C1/6D30: C9 04        CMP #$04
C1/6D32: D0 CE        BNE $6D02
C1/6D34: FA           PLX 
C1/6D35: FE 78 D1     INC $D178,X     ; increment frame counter
C1/6D38: BD 78 D1     LDA $D178,X
C1/6D3B: C9 30        CMP #$30        ; 36 frames moving, 48 frames total
C1/6D3D: D0 03        BNE $6D42
C1/6D3F: 9E 18 D1     STZ $D118,X     ; disable damage numerals for this object
C1/6D42: E8           INX 
C1/6D43: E0 0C 00     CPX #$000C
C1/6D46: D0 9C        BNE $6CE4
C1/6D48: 7B           TDC 
C1/6D49: AA           TAX 
C1/6D4A: BD 18 D1     LDA $D118,X
C1/6D4D: D0 0C        BNE $6D5B       ; return if damage numerals enabled
C1/6D4F: E8           INX 
C1/6D50: E0 0C 00     CPX #$000C
C1/6D53: D0 F5        BNE $6D4A
C1/6D55: 20 F0 6B     JSR $6BF0       ; hide damage numeral sprites
C1/6D58: 9C 14 D1     STZ $D114
C1/6D5B: 60           RTS 

; [  ]

C1/6D5C: 7B           TDC 
C1/6D5D: AA           TAX 
C1/6D5E: A8           TAY 
C1/6D5F: A9 5E        LDA #$5E
C1/6D61: 85 70        STA $70
C1/6D63: 64 72        STZ $72
C1/6D65: B9 1E D0     LDA $D01E,Y
C1/6D68: 9D 45 CF     STA $CF45,X
C1/6D6B: B9 22 D0     LDA $D022,Y
C1/6D6E: 9D 46 CF     STA $CF46,X
C1/6D71: A9 00        LDA #$00
C1/6D73: 9D 47 CF     STA $CF47,X
C1/6D76: 9D 49 CF     STA $CF49,X
C1/6D79: 9D 4A CF     STA $CF4A,X
C1/6D7C: 9D 4E CF     STA $CF4E,X
C1/6D7F: 9D 51 CF     STA $CF51,X
C1/6D82: 9D 43 CF     STA $CF43,X
C1/6D85: 9D 4D CF     STA $CF4D,X
C1/6D88: 9D 53 CF     STA $CF53,X
C1/6D8B: 9D 56 CF     STA $CF56,X
C1/6D8E: 9D 57 CF     STA $CF57,X
C1/6D91: 9D 58 CF     STA $CF58,X
C1/6D94: 9D 59 CF     STA $CF59,X
C1/6D97: 9D 5A CF     STA $CF5A,X
C1/6D9A: 9D 5D CF     STA $CF5D,X
C1/6D9D: 9D 5E CF     STA $CF5E,X
C1/6DA0: 9D 5F CF     STA $CF5F,X
C1/6DA3: 9D 60 CF     STA $CF60,X
C1/6DA6: 9D 61 CF     STA $CF61,X
C1/6DA9: 9D 62 CF     STA $CF62,X
C1/6DAC: A9 07        LDA #$07
C1/6DAE: 9D 4F CF     STA $CF4F,X
C1/6DB1: A9 01        LDA #$01
C1/6DB3: 9D 52 CF     STA $CF52,X
C1/6DB6: A5 72        LDA $72
C1/6DB8: 9D 4C CF     STA $CF4C,X
C1/6DBB: A5 7A        LDA $7A
C1/6DBD: 18           CLC 
C1/6DBE: 69 09        ADC #$09
C1/6DC0: 85 7A        STA $7A
C1/6DC2: 9D 50 CF     STA $CF50,X
C1/6DC5: A9 04        LDA #$04
C1/6DC7: 9D 48 CF     STA $CF48,X
C1/6DCA: 98           TYA 
C1/6DCB: 0A           ASL 
C1/6DCC: 09 38        ORA #$38
C1/6DCE: 9D 4B CF     STA $CF4B,X
C1/6DD1: A5 70        LDA $70
C1/6DD3: 9D 44 CF     STA $CF44,X
C1/6DD6: 38           SEC 
C1/6DD7: E9 0A        SBC #$0A
C1/6DD9: 85 70        STA $70
C1/6DDB: B9 C6 CF     LDA $CFC6,Y
C1/6DDE: C9 FF        CMP #$FF
C1/6DE0: D0 03        BNE $6DE5
C1/6DE2: FE 43 CF     INC $CF43,X
C1/6DE5: A5 72        LDA $72
C1/6DE7: 18           CLC 
C1/6DE8: 69 40        ADC #$40
C1/6DEA: 85 72        STA $72
C1/6DEC: C8           INY 
C1/6DED: 8A           TXA 
C1/6DEE: 18           CLC 
C1/6DEF: 69 20        ADC #$20
C1/6DF1: AA           TAX 
C1/6DF2: E0 80 00     CPX #$0080
C1/6DF5: F0 03        BEQ $6DFA
C1/6DF7: 4C 65 6D     JMP $6D65
C1/6DFA: 4C FD 6D     JMP $6DFD
C1/6DFD: 7B           TDC 
C1/6DFE: AA           TAX 
C1/6DFF: 64 DF        STZ $DF
C1/6E01: A9 80        LDA #$80
C1/6E03: 85 88        STA $88
C1/6E05: BD 43 CF     LDA $CF43,X
C1/6E08: D0 06        BNE $6E10
C1/6E0A: A5 DF        LDA $DF
C1/6E0C: 05 88        ORA $88
C1/6E0E: 85 DF        STA $DF
C1/6E10: 46 88        LSR $88
C1/6E12: 8A           TXA 
C1/6E13: 18           CLC 
C1/6E14: 69 20        ADC #$20
C1/6E16: AA           TAX 
C1/6E17: E0 80 00     CPX #$0080
C1/6E1A: D0 E9        BNE $6E05
C1/6E1C: 60           RTS 
C1/6E1D: 85 88        STA $88
C1/6E1F: 85 8A        STA $8A
C1/6E21: BD 54 CF     LDA $CF54,X
C1/6E24: 30 11        BMI $6E37
C1/6E26: BD 56 CF     LDA $CF56,X
C1/6E29: 29 7F        AND #$7F
C1/6E2B: 9D 56 CF     STA $CF56,X
C1/6E2E: A5 88        LDA $88
C1/6E30: 49 FF        EOR #$FF
C1/6E32: 1A           INC 
C1/6E33: 85 8A        STA $8A
C1/6E35: 80 08        BRA $6E3F
C1/6E37: BD 56 CF     LDA $CF56,X
C1/6E3A: 09 80        ORA #$80
C1/6E3C: 9D 56 CF     STA $CF56,X
C1/6E3F: BD 45 CF     LDA $CF45,X
C1/6E42: 18           CLC 
C1/6E43: 65 8A        ADC $8A
C1/6E45: 9D 45 CF     STA $CF45,X
C1/6E48: BD 54 CF     LDA $CF54,X
C1/6E4B: 38           SEC 
C1/6E4C: E5 88        SBC $88
C1/6E4E: 9D 54 CF     STA $CF54,X
C1/6E51: 60           RTS 
C1/6E52: BD 53 CF     LDA $CF53,X
C1/6E55: F0 53        BEQ $6EAA
C1/6E57: DA           PHX 
C1/6E58: BD 47 CF     LDA $CF47,X
C1/6E5B: 0A           ASL 
C1/6E5C: 0A           ASL 
C1/6E5D: 0A           ASL 
C1/6E5E: 85 88        STA $88
C1/6E60: BD 55 CF     LDA $CF55,X
C1/6E63: 29 07        AND #$07
C1/6E65: 18           CLC 
C1/6E66: 65 88        ADC $88
C1/6E68: AA           TAX 
C1/6E69: BF 3A B9 D4  LDA $D4B93A,X
C1/6E6D: 85 88        STA $88
C1/6E6F: BF 22 B9 D4  LDA $D4B922,X
C1/6E73: FA           PLX 
C1/6E74: 9D 4A CF     STA $CF4A,X
C1/6E77: A5 88        LDA $88
C1/6E79: 9D 51 CF     STA $CF51,X
C1/6E7C: FE 55 CF     INC $CF55,X
C1/6E7F: BD 47 CF     LDA $CF47,X
C1/6E82: F0 0C        BEQ $6E90
C1/6E84: C9 01        CMP #$01
C1/6E86: D0 04        BNE $6E8C
C1/6E88: A9 02        LDA #$02
C1/6E8A: 80 06        BRA $6E92
C1/6E8C: A9 01        LDA #$01
C1/6E8E: 80 02        BRA $6E92
C1/6E90: A9 02        LDA #$02
C1/6E92: 20 1D 6E     JSR $6E1D
C1/6E95: 29 7F        AND #$7F
C1/6E97: D0 10        BNE $6EA9
C1/6E99: 9E 4D CF     STZ $CF4D,X
C1/6E9C: 9E 53 CF     STZ $CF53,X
C1/6E9F: BD 56 CF     LDA $CF56,X
C1/6EA2: 29 7F        AND #$7F
C1/6EA4: 9D 56 CF     STA $CF56,X
C1/6EA7: 80 01        BRA $6EAA
C1/6EA9: 60           RTS 
C1/6EAA: 5A           PHY 
C1/6EAB: 8A           TXA 
C1/6EAC: 4A           LSR 
C1/6EAD: 4A           LSR 
C1/6EAE: 4A           LSR 
C1/6EAF: 4A           LSR 
C1/6EB0: 4A           LSR 
C1/6EB1: A8           TAY 
C1/6EB2: B9 C1 D1     LDA $D1C1,Y
C1/6EB5: F0 0E        BEQ $6EC5
C1/6EB7: C9 01        CMP #$01
C1/6EB9: F0 0F        BEQ $6ECA
C1/6EBB: BD 56 CF     LDA $CF56,X
C1/6EBE: 29 7F        AND #$7F
C1/6EC0: 9D 56 CF     STA $CF56,X
C1/6EC3: 80 0D        BRA $6ED2
C1/6EC5: B9 BD D1     LDA $D1BD,Y
C1/6EC8: F0 08        BEQ $6ED2
C1/6ECA: BD 56 CF     LDA $CF56,X
C1/6ECD: 09 80        ORA #$80
C1/6ECF: 9D 56 CF     STA $CF56,X
C1/6ED2: 7A           PLY 
C1/6ED3: 60           RTS 
C1/6ED4: BD 45 CF     LDA $CF45,X
C1/6ED7: DD 5B CF     CMP $CF5B,X
C1/6EDA: F0 0A        BEQ $6EE6
C1/6EDC: 9D 5B CF     STA $CF5B,X
C1/6EDF: A9 08        LDA #$08
C1/6EE1: 9D 5C CF     STA $CF5C,X
C1/6EE4: 80 0D        BRA $6EF3
C1/6EE6: DE 5C CF     DEC $CF5C,X
C1/6EE9: D0 08        BNE $6EF3
C1/6EEB: FE 5C CF     INC $CF5C,X
C1/6EEE: A9 06        LDA #$06
C1/6EF0: 85 88        STA $88
C1/6EF2: 60           RTS 
C1/6EF3: 64 88        STZ $88
C1/6EF5: 60           RTS 

; [  ]

C1/6EF6: DA           PHX 
C1/6EF7: 5A           PHY 
C1/6EF8: 8A           TXA 
C1/6EF9: 4A           LSR 
C1/6EFA: 4A           LSR 
C1/6EFB: 4A           LSR 
C1/6EFC: 4A           LSR 
C1/6EFD: 4A           LSR 
C1/6EFE: A8           TAY 
C1/6EFF: B9 CB D1     LDA $D1CB,Y
C1/6F02: D0 70        BNE $6F74
C1/6F04: 20 D4 6E     JSR $6ED4
C1/6F07: BD 5A CF     LDA $CF5A,X
C1/6F0A: F0 68        BEQ $6F74
C1/6F0C: C9 01        CMP #$01
C1/6F0E: D0 0D        BNE $6F1D
C1/6F10: BD 50 CF     LDA $CF50,X
C1/6F13: 29 01        AND #$01
C1/6F15: F0 5D        BEQ $6F74
C1/6F17: 7B           TDC 
C1/6F18: AA           TAX 
C1/6F19: 86 94        STX $94
C1/6F1B: 80 12        BRA $6F2F
C1/6F1D: BD 50 CF     LDA $CF50,X
C1/6F20: 29 01        AND #$01
C1/6F22: F0 07        BEQ $6F2B
C1/6F24: 06 88        ASL $88
C1/6F26: A2 60 00     LDX #$0060
C1/6F29: 80 02        BRA $6F2D
C1/6F2B: 7B           TDC 
C1/6F2C: AA           TAX 
C1/6F2D: 86 94        STX $94
C1/6F2F: A5 96        LDA $96
C1/6F31: 0A           ASL 
C1/6F32: AA           TAX 
C1/6F33: C2 20        REP #$20
C1/6F35: BF D8 E1 D0  LDA $D0E1D8,X
C1/6F39: A8           TAY 
C1/6F3A: BF E0 E1 D0  LDA $D0E1E0,X
C1/6F3E: 18           CLC 
C1/6F3F: 65 94        ADC $94
C1/6F41: AA           TAX 
C1/6F42: 7B           TDC 
C1/6F43: E2 20        SEP #$20
C1/6F45: A5 F6        LDA $F6
C1/6F47: F0 2D        BEQ $6F76
C1/6F49: A9 06        LDA #$06
C1/6F4B: 85 89        STA $89
C1/6F4D: BD 89 F7     LDA $F789,X
C1/6F50: 38           SEC 
C1/6F51: E5 88        SBC $88
C1/6F53: 99 00 02     STA $0200,Y
C1/6F56: E8           INX 
C1/6F57: C8           INY 
C1/6F58: BD 89 F7     LDA $F789,X
C1/6F5B: 99 00 02     STA $0200,Y
C1/6F5E: E8           INX 
C1/6F5F: C8           INY 
C1/6F60: BD 89 F7     LDA $F789,X
C1/6F63: 99 00 02     STA $0200,Y
C1/6F66: E8           INX 
C1/6F67: C8           INY 
C1/6F68: BD 89 F7     LDA $F789,X
C1/6F6B: 99 00 02     STA $0200,Y
C1/6F6E: E8           INX 
C1/6F6F: C8           INY 
C1/6F70: C6 89        DEC $89
C1/6F72: D0 D9        BNE $6F4D
C1/6F74: 80 2B        BRA $6FA1
C1/6F76: A9 06        LDA #$06
C1/6F78: 85 89        STA $89
C1/6F7A: BD 89 F7     LDA $F789,X
C1/6F7D: 18           CLC 
C1/6F7E: 65 88        ADC $88
C1/6F80: 99 00 02     STA $0200,Y
C1/6F83: E8           INX 
C1/6F84: C8           INY 
C1/6F85: BD 89 F7     LDA $F789,X
C1/6F88: 99 00 02     STA $0200,Y
C1/6F8B: E8           INX 
C1/6F8C: C8           INY 
C1/6F8D: BD 89 F7     LDA $F789,X
C1/6F90: 99 00 02     STA $0200,Y
C1/6F93: E8           INX 
C1/6F94: C8           INY 
C1/6F95: BD 89 F7     LDA $F789,X
C1/6F98: 99 00 02     STA $0200,Y
C1/6F9B: E8           INX 
C1/6F9C: C8           INY 
C1/6F9D: C6 89        DEC $89
C1/6F9F: D0 D9        BNE $6F7A
C1/6FA1: 7A           PLY 
C1/6FA2: FA           PLX 
C1/6FA3: 60           RTS 

; [  ]

C1/6FA4: 5A           PHY 
C1/6FA5: DA           PHX 
C1/6FA6: 8A           TXA 
C1/6FA7: 4A           LSR 
C1/6FA8: 4A           LSR 
C1/6FA9: 4A           LSR 
C1/6FAA: 4A           LSR 
C1/6FAB: 4A           LSR 
C1/6FAC: A8           TAY 
C1/6FAD: B9 CB D1     LDA $D1CB,Y
C1/6FB0: D0 1C        BNE $6FCE
C1/6FB2: BD 59 CF     LDA $CF59,X
C1/6FB5: F0 17        BEQ $6FCE
C1/6FB7: BD 50 CF     LDA $CF50,X
C1/6FBA: 29 38        AND #$38
C1/6FBC: 4A           LSR 
C1/6FBD: 4A           LSR 
C1/6FBE: 4A           LSR 
C1/6FBF: AA           TAX 
C1/6FC0: BF 08 B9 D4  LDA $D4B908,X
C1/6FC4: 99 ED DB     STA $DBED,Y
C1/6FC7: 18           CLC 
C1/6FC8: 65 99        ADC $99
C1/6FCA: 85 99        STA $99
C1/6FCC: 80 04        BRA $6FD2
C1/6FCE: 7B           TDC 
C1/6FCF: 99 ED DB     STA $DBED,Y
C1/6FD2: FA           PLX 
C1/6FD3: 7A           PLY 
C1/6FD4: 60           RTS 

; [  ]

C1/6FD5: AD 3E DB     LDA $DB3E
C1/6FD8: D0 01        BNE $6FDB
C1/6FDA: 60           RTS 
C1/6FDB: 7B           TDC 
C1/6FDC: AA           TAX 
C1/6FDD: 9D 02 04     STA $0402,X
C1/6FE0: E8           INX 
C1/6FE1: E0 0C 00     CPX #$000C
C1/6FE4: D0 F7        BNE $6FDD
C1/6FE6: AD 3F DB     LDA $DB3F
C1/6FE9: 0A           ASL 
C1/6FEA: 0A           ASL 
C1/6FEB: 0A           ASL 
C1/6FEC: 0A           ASL 
C1/6FED: 0A           ASL 
C1/6FEE: AA           TAX 
C1/6FEF: BD 44 CF     LDA $CF44,X
C1/6FF2: 18           CLC 
C1/6FF3: 7D 48 CF     ADC $CF48,X
C1/6FF6: C2 20        REP #$20
C1/6FF8: 0A           ASL 
C1/6FF9: 0A           ASL 
C1/6FFA: AA           TAX 
C1/6FFB: DA           PHX 
C1/6FFC: 8B           PHB 
C1/6FFD: A2 C9 F8     LDX #$F8C9
C1/7000: A0 38 02     LDY #$0238
C1/7003: A9 A7 00     LDA #$00A7
C1/7006: 54 00 7E     MVN $00,$7E
C1/7009: AB           PLB 
C1/700A: FA           PLX 
C1/700B: 7B           TDC 
C1/700C: A8           TAY 
C1/700D: BD 00 02     LDA $0200,X
C1/7010: 99 20 02     STA $0220,Y
C1/7013: E8           INX 
C1/7014: E8           INX 
C1/7015: C8           INY 
C1/7016: C8           INY 
C1/7017: C0 18 00     CPY #$0018
C1/701A: D0 F1        BNE $700D
C1/701C: 7B           TDC 
C1/701D: E2 20        SEP #$20
C1/701F: AA           TAX 
C1/7020: BD 20 02     LDA $0220,X
C1/7023: 9D C9 F8     STA $F8C9,X
C1/7026: E8           INX 
C1/7027: E0 C0 00     CPX #$00C0
C1/702A: D0 F4        BNE $7020
C1/702C: EE 40 DB     INC $DB40
C1/702F: AD 40 DB     LDA $DB40
C1/7032: 29 01        AND #$01
C1/7034: F0 03        BEQ $7039
C1/7036: 20 D3 67     JSR $67D3
C1/7039: 60           RTS 
C1/703A: 7B           TDC 
C1/703B: AA           TAX 
C1/703C: C2 20        REP #$20
C1/703E: A9 F0 F0     LDA #$F0F0
C1/7041: 9D 00 03     STA $0300,X
C1/7044: E8           INX 
C1/7045: E8           INX 
C1/7046: E8           INX 
C1/7047: E8           INX 
C1/7048: E0 00 01     CPX #$0100
C1/704B: D0 F4        BNE $7041
C1/704D: 7B           TDC 
C1/704E: AA           TAX 
C1/704F: 9D 10 04     STA $0410,X
C1/7052: E8           INX 
C1/7053: E8           INX 
C1/7054: E0 10 00     CPX #$0010
C1/7057: D0 F6        BNE $704F
C1/7059: E2 20        SEP #$20
C1/705B: 60           RTS 
C1/705C: 7B           TDC 
C1/705D: AA           TAX 
C1/705E: 9E 4E CF     STZ $CF4E,X
C1/7061: 8A           TXA 
C1/7062: 18           CLC 
C1/7063: 69 20        ADC #$20
C1/7065: AA           TAX 
C1/7066: C9 80        CMP #$80
C1/7068: D0 F4        BNE $705E
C1/706A: 60           RTS 
C1/706B: 7B           TDC 
C1/706C: AA           TAX 
C1/706D: A8           TAY 
C1/706E: AD 75 DB     LDA $DB75
C1/7071: 85 88        STA $88
C1/7073: AD 74 DB     LDA $DB74
C1/7076: D0 02        BNE $707A
C1/7078: 64 88        STZ $88
C1/707A: 06 88        ASL $88
C1/707C: B0 3C        BCS $70BA
C1/707E: B9 7E 7B     LDA $7B7E,Y
C1/7081: 30 02        BMI $7085
C1/7083: 80 07        BRA $708C
C1/7085: B9 8E 7B     LDA $7B8E,Y
C1/7088: 30 33        BMI $70BD
C1/708A: 80 2E        BRA $70BA
C1/708C: B9 8E 7B     LDA $7B8E,Y
C1/708F: 30 2C        BMI $70BD
C1/7091: BD 61 CF     LDA $CF61,X
C1/7094: D0 24        BNE $70BA
C1/7096: B9 7E 7B     LDA $7B7E,Y
C1/7099: 29 C0        AND #$C0
C1/709B: D0 20        BNE $70BD
C1/709D: BD 56 CF     LDA $CF56,X
C1/70A0: 29 01        AND #$01
C1/70A2: D0 05        BNE $70A9
C1/70A4: BD 58 CF     LDA $CF58,X
C1/70A7: D0 11        BNE $70BA
C1/70A9: BD 45 CF     LDA $CF45,X
C1/70AC: 18           CLC 
C1/70AD: 7D 49 CF     ADC $CF49,X
C1/70B0: C9 C8        CMP #$C8
C1/70B2: F0 17        BEQ $70CB
C1/70B4: C9 D8        CMP #$D8
C1/70B6: F0 13        BEQ $70CB
C1/70B8: 80 00        BRA $70BA
C1/70BA: 9E 4E CF     STZ $CF4E,X
C1/70BD: C8           INY 
C1/70BE: C8           INY 
C1/70BF: C8           INY 
C1/70C0: C8           INY 
C1/70C1: 8A           TXA 
C1/70C2: 18           CLC 
C1/70C3: 69 20        ADC #$20
C1/70C5: AA           TAX 
C1/70C6: C9 80        CMP #$80
C1/70C8: D0 B0        BNE $707A
C1/70CA: 60           RTS 
C1/70CB: A9 02        LDA #$02
C1/70CD: 9D 4E CF     STA $CF4E,X
C1/70D0: 4C BD 70     JMP $70BD
C1/70D3: 20 FD 6D     JSR $6DFD
C1/70D6: 20 3A 70     JSR $703A
C1/70D9: 7B           TDC 
C1/70DA: AA           TAX 
C1/70DB: 85 96        STA $96
C1/70DD: BD 44 CF     LDA $CF44,X
C1/70E0: 18           CLC 
C1/70E1: 7D 48 CF     ADC $CF48,X
C1/70E4: C2 20        REP #$20
C1/70E6: 0A           ASL 
C1/70E7: 0A           ASL 
C1/70E8: A8           TAY 
C1/70E9: 7B           TDC 
C1/70EA: E2 20        SEP #$20
C1/70EC: BD 47 CF     LDA $CF47,X
C1/70EF: F0 12        BEQ $7103
C1/70F1: DA           PHX 
C1/70F2: 0A           ASL 
C1/70F3: AA           TAX 
C1/70F4: BF 1C B9 D4  LDA $D4B91C,X
C1/70F8: 85 9E        STA $9E
C1/70FA: BF 1D B9 D4  LDA $D4B91D,X
C1/70FE: 85 9F        STA $9F
C1/7100: FA           PLX 
C1/7101: 80 07        BRA $710A
C1/7103: BD 4C CF     LDA $CF4C,X
C1/7106: 85 9E        STA $9E
C1/7108: 64 9F        STZ $9F
C1/710A: BD 62 CF     LDA $CF62,X
C1/710D: 29 80        AND #$80
C1/710F: D0 05        BNE $7116
C1/7111: BD 43 CF     LDA $CF43,X
C1/7114: F0 14        BEQ $712A
C1/7116: A9 06        LDA #$06
C1/7118: 85 88        STA $88
C1/711A: A9 F8        LDA #$F8
C1/711C: 99 01 02     STA $0201,Y
C1/711F: C8           INY 
C1/7120: C8           INY 
C1/7121: C8           INY 
C1/7122: C8           INY 
C1/7123: C6 88        DEC $88
C1/7125: D0 F5        BNE $711C
C1/7127: 4C AE 72     JMP $72AE
C1/712A: BD 61 CF     LDA $CF61,X
C1/712D: F0 06        BEQ $7135
C1/712F: A5 A2        LDA $A2
C1/7131: 29 02        AND #$02
C1/7133: F0 E1        BEQ $7116
C1/7135: 20 52 6E     JSR $6E52
C1/7138: BD 4E CF     LDA $CF4E,X
C1/713B: F0 06        BEQ $7143
C1/713D: DA           PHX 
C1/713E: 5A           PHY 
C1/713F: 9B           TXY 
C1/7140: 4C 4E 71     JMP $714E
C1/7143: DA           PHX 
C1/7144: 5A           PHY 
C1/7145: 9B           TXY 
C1/7146: BD 58 CF     LDA $CF58,X
C1/7149: D0 03        BNE $714E
C1/714B: BD 4D CF     LDA $CF4D,X
C1/714E: 48           PHA 
C1/714F: AA           TAX 
C1/7150: BF 5A DE D8  LDA $D8DE5A,X
C1/7154: AA           TAX 
C1/7155: 86 8A        STX $8A
C1/7157: BB           TYX 
C1/7158: BD 57 CF     LDA $CF57,X
C1/715B: F0 03        BEQ $7160
C1/715D: 3A           DEC 
C1/715E: 80 03        BRA $7163
C1/7160: BD 51 CF     LDA $CF51,X
C1/7163: 85 98        STA $98
C1/7165: 68           PLA 
C1/7166: 0A           ASL 
C1/7167: 0A           ASL 
C1/7168: 0A           ASL 
C1/7169: 18           CLC 
C1/716A: 65 98        ADC $98
C1/716C: 85 98        STA $98
C1/716E: BD 47 CF     LDA $CF47,X
C1/7171: 0A           ASL 
C1/7172: AA           TAX 
C1/7173: BF 16 B9 D4  LDA $D4B916,X
C1/7177: 18           CLC 
C1/7178: 65 98        ADC $98
C1/717A: 85 98        STA $98
C1/717C: BF 17 B9 D4  LDA $D4B917,X
C1/7180: 69 00        ADC #$00
C1/7182: 85 99        STA $99
C1/7184: A6 98        LDX $98
C1/7186: BF 7A DE D8  LDA $D8DE7A,X
C1/718A: 48           PHA 
C1/718B: 85 98        STA $98
C1/718D: A9 06        LDA #$06
C1/718F: 85 9A        STA $9A
C1/7191: 20 4B FE     JSR $FE4B
C1/7194: BB           TYX 
C1/7195: BD 45 CF     LDA $CF45,X
C1/7198: 18           CLC 
C1/7199: 7D 49 CF     ADC $CF49,X
C1/719C: 85 98        STA $98
C1/719E: 64 99        STZ $99
C1/71A0: C2 20        REP #$20
C1/71A2: BD 5D CF     LDA $CF5D,X
C1/71A5: 18           CLC 
C1/71A6: 65 98        ADC $98
C1/71A8: 85 98        STA $98
C1/71AA: 7B           TDC 
C1/71AB: E2 20        SEP #$20
C1/71AD: 68           PLA 
C1/71AE: C9 07        CMP #$07
C1/71B0: D0 06        BNE $71B8
C1/71B2: BD 46 CF     LDA $CF46,X
C1/71B5: 3A           DEC 
C1/71B6: 80 03        BRA $71BB
C1/71B8: BD 46 CF     LDA $CF46,X
C1/71BB: 18           CLC 
C1/71BC: 7D 4A CF     ADC $CF4A,X
C1/71BF: 85 99        STA $99
C1/71C1: 64 9A        STZ $9A
C1/71C3: C2 20        REP #$20
C1/71C5: BD 5F CF     LDA $CF5F,X
C1/71C8: 18           CLC 
C1/71C9: 65 99        ADC $99
C1/71CB: 85 99        STA $99
C1/71CD: 7B           TDC 
C1/71CE: E2 20        SEP #$20
C1/71D0: BD 4B CF     LDA $CF4B,X
C1/71D3: 85 9A        STA $9A
C1/71D5: AD 9A BC     LDA $BC9A
C1/71D8: F0 06        BEQ $71E0
C1/71DA: A5 9A        LDA $9A
C1/71DC: 29 EF        AND #$EF
C1/71DE: 85 9A        STA $9A
C1/71E0: 20 F6 6E     JSR $6EF6
C1/71E3: 20 A4 6F     JSR $6FA4
C1/71E6: 64 89        STZ $89
C1/71E8: BD 4E CF     LDA $CF4E,X
C1/71EB: D0 05        BNE $71F2
C1/71ED: BD 56 CF     LDA $CF56,X
C1/71F0: 10 08        BPL $71FA
C1/71F2: A9 40        LDA #$40
C1/71F4: 85 94        STA $94
C1/71F6: A9 0C        LDA #$0C
C1/71F8: 80 03        BRA $71FD
C1/71FA: 64 94        STZ $94
C1/71FC: 7B           TDC 
C1/71FD: 85 88        STA $88
C1/71FF: C2 20        REP #$20
C1/7201: A5 8A        LDA $8A
C1/7203: 18           CLC 
C1/7204: 69 4E DE     ADC #$DE4E
C1/7207: 85 90        STA $90
C1/7209: A5 8A        LDA $8A
C1/720B: 18           CLC 
C1/720C: 69 36 DE     ADC #$DE36
C1/720F: 65 88        ADC $88
C1/7211: 85 8C        STA $8C
C1/7213: A5 9C        LDA $9C
C1/7215: 18           CLC 
C1/7216: 69 97 B9     ADC #$B997      ; D4/B997 (battle character tilemaps)
C1/7219: 85 88        STA $88
C1/721B: 7B           TDC 
C1/721C: E2 20        SEP #$20
C1/721E: A9 D4        LDA #$D4
C1/7220: 85 8A        STA $8A
C1/7222: A9 D8        LDA #$D8
C1/7224: 85 8E        STA $8E
C1/7226: A9 D8        LDA #$D8
C1/7228: 85 92        STA $92
C1/722A: AD D3 DB     LDA $DBD3
C1/722D: F0 04        BEQ $7233
C1/722F: A9 C0        LDA #$C0
C1/7231: 80 02        BRA $7235
C1/7233: A9 A0        LDA #$A0
C1/7235: 85 A0        STA $A0
C1/7237: 7A           PLY 
C1/7238: BB           TYX 
C1/7239: DA           PHX 
C1/723A: 7B           TDC 
C1/723B: A8           TAY 
C1/723C: B7 8C        LDA [$8C],Y
C1/723E: 18           CLC 
C1/723F: 65 98        ADC $98
C1/7241: 45 F6        EOR $F6
C1/7243: 38           SEC 
C1/7244: E5 F8        SBC $F8
C1/7246: 9D 00 02     STA $0200,X
C1/7249: E8           INX 
C1/724A: B7 90        LDA [$90],Y
C1/724C: 18           CLC 
C1/724D: 65 99        ADC $99
C1/724F: C5 A0        CMP $A0
C1/7251: 90 02        BCC $7255
C1/7253: A9 F0        LDA #$F0
C1/7255: 9D 00 02     STA $0200,X
C1/7258: E8           INX 
C1/7259: B7 88        LDA [$88],Y
C1/725B: C9 FF        CMP #$FF
C1/725D: D0 08        BNE $7267
C1/725F: 9D 00 02     STA $0200,X
C1/7262: A9 01        LDA #$01
C1/7264: E8           INX 
C1/7265: 80 0C        BRA $7273
C1/7267: 18           CLC 
C1/7268: 65 9E        ADC $9E
C1/726A: 9D 00 02     STA $0200,X
C1/726D: E8           INX 
C1/726E: A5 9A        LDA $9A
C1/7270: 18           CLC 
C1/7271: 65 9F        ADC $9F
C1/7273: 45 94        EOR $94
C1/7275: 45 F7        EOR $F7
C1/7277: 9D 00 02     STA $0200,X
C1/727A: E8           INX 
C1/727B: C8           INY 
C1/727C: C0 06 00     CPY #$0006
C1/727F: D0 BB        BNE $723C
C1/7281: FA           PLX 
C1/7282: A5 A2        LDA $A2
C1/7284: 29 01        AND #$01
C1/7286: D0 25        BNE $72AD
C1/7288: 9B           TXY 
C1/7289: A5 96        LDA $96
C1/728B: 0A           ASL 
C1/728C: AA           TAX 
C1/728D: C2 20        REP #$20
C1/728F: BF E0 E1 D0  LDA $D0E1E0,X
C1/7293: AA           TAX 
C1/7294: 7B           TDC 
C1/7295: E2 20        SEP #$20
C1/7297: A9 18        LDA #$18
C1/7299: 85 88        STA $88
C1/729B: BD 89 F7     LDA $F789,X
C1/729E: 9D E9 F7     STA $F7E9,X
C1/72A1: B9 00 02     LDA $0200,Y
C1/72A4: 9D 89 F7     STA $F789,X
C1/72A7: E8           INX 
C1/72A8: C8           INY 
C1/72A9: C6 88        DEC $88
C1/72AB: D0 EE        BNE $729B
C1/72AD: FA           PLX 
C1/72AE: 20 C1 72     JSR $72C1
C1/72B1: E6 96        INC $96
C1/72B3: 8A           TXA 
C1/72B4: 18           CLC 
C1/72B5: 69 20        ADC #$20
C1/72B7: AA           TAX 
C1/72B8: E0 80 00     CPX #$0080
C1/72BB: F0 03        BEQ $72C0
C1/72BD: 4C DD 70     JMP $70DD
C1/72C0: 60           RTS 
C1/72C1: BD 52 CF     LDA $CF52,X
C1/72C4: F0 14        BEQ $72DA
C1/72C6: FE 50 CF     INC $CF50,X
C1/72C9: BD 50 CF     LDA $CF50,X
C1/72CC: 3D 4F CF     AND $CF4F,X
C1/72CF: D0 09        BNE $72DA
C1/72D1: BD 51 CF     LDA $CF51,X
C1/72D4: 1A           INC 
C1/72D5: 29 07        AND #$07
C1/72D7: 9D 51 CF     STA $CF51,X
C1/72DA: 60           RTS 

; [  ]

C1/72DB: 48           PHA 
C1/72DC: A9 88        LDA #$88
C1/72DE: 8D B6 DB     STA $DBB6
C1/72E1: 20 96 FC     JSR $FC96       ; generate random number
C1/72E4: 29 03        AND #$03
C1/72E6: F0 04        BEQ $72EC
C1/72E8: A9 56        LDA #$56
C1/72EA: 80 02        BRA $72EE
C1/72EC: A9 0E        LDA #$0E
C1/72EE: 20 D9 FB     JSR $FBD9       ; play sound effect
C1/72F1: 20 F5 78     JSR $78F5       ; flash screen
C1/72F4: 68           PLA 
C1/72F5: F0 03        BEQ $72FA
C1/72F7: 20 41 81     JSR $8141       ; wait
C1/72FA: 60           RTS 

; [  ]

C1/72FB: A9 78        LDA #$78
C1/72FD: 20 DB 72     JSR $72DB
C1/7300: A9 78        LDA #$78
C1/7302: 20 DB 72     JSR $72DB
C1/7305: 20 39 75     JSR $7539
C1/7308: A9 13        LDA #$13
C1/730A: 8D E9 F9     STA $F9E9
C1/730D: A9 84        LDA #$84
C1/730F: 20 D9 FB     JSR $FBD9       ; play sound effect
C1/7312: 7B           TDC 
C1/7313: AA           TAX 
C1/7314: BD 58 EE     LDA $EE58,X
C1/7317: 29 03        AND #$03
C1/7319: D0 06        BNE $7321
C1/731B: 9E 57 EE     STZ $EE57,X
C1/731E: 9E 58 EE     STZ $EE58,X
C1/7321: E8           INX 
C1/7322: E8           INX 
C1/7323: E0 00 05     CPX #$0500
C1/7326: D0 EC        BNE $7314
C1/7328: AD 2F FF     LDA $FF2F
C1/732B: F0 0A        BEQ $7337
C1/732D: AE 79 BC     LDX $BC79
C1/7330: CA           DEX 
C1/7331: 8E 79 BC     STX $BC79
C1/7334: 20 C2 1C     JSR $1CC2
C1/7337: 20 29 75     JSR $7529
C1/733A: 64 86        STZ $86
C1/733C: AD E9 F9     LDA $F9E9
C1/733F: 20 75 73     JSR $7375
C1/7342: E6 86        INC $86
C1/7344: AD E9 F9     LDA $F9E9
C1/7347: 18           CLC 
C1/7348: 69 04        ADC #$04
C1/734A: 20 75 73     JSR $7375
C1/734D: A9 10        LDA #$10
C1/734F: 85 86        STA $86
C1/7351: AD E9 F9     LDA $F9E9
C1/7354: 18           CLC 
C1/7355: 69 08        ADC #$08
C1/7357: 20 75 73     JSR $7375
C1/735A: E6 86        INC $86
C1/735C: AD E9 F9     LDA $F9E9
C1/735F: 18           CLC 
C1/7360: 69 0C        ADC #$0C
C1/7362: 20 75 73     JSR $7375
C1/7365: CE E9 F9     DEC $F9E9
C1/7368: AD E9 F9     LDA $F9E9
C1/736B: C9 F0        CMP #$F0
C1/736D: D0 B9        BNE $7328
C1/736F: A9 02        LDA #$02
C1/7371: 8D 2E FF     STA $FF2E
C1/7374: 60           RTS 
C1/7375: 85 81        STA $81
C1/7377: 85 80        STA $80
C1/7379: 64 82        STZ $82
C1/737B: 64 87        STZ $87
C1/737D: 7B           TDC 
C1/737E: A8           TAY 
C1/737F: A5 82        LDA $82
C1/7381: 29 07        AND #$07
C1/7383: AA           TAX 
C1/7384: BF 7A 7C D9  LDA $D97C7A,X
C1/7388: 99 70 00     STA $0070,Y
C1/738B: 99 71 00     STA $0071,Y
C1/738E: E8           INX 
C1/738F: C8           INY 
C1/7390: C8           INY 
C1/7391: C0 10 00     CPY #$0010
C1/7394: D0 EE        BNE $7384
C1/7396: 8B           PHB 
C1/7397: A9 7F        LDA #$7F
C1/7399: 48           PHA 
C1/739A: AB           PLB 
C1/739B: A5 80        LDA $80
C1/739D: 30 37        BMI $73D6
C1/739F: C9 14        CMP #$14
C1/73A1: B0 33        BCS $73D6
C1/73A3: C2 20        REP #$20
C1/73A5: 0A           ASL 
C1/73A6: 0A           ASL 
C1/73A7: 0A           ASL 
C1/73A8: 0A           ASL 
C1/73A9: 0A           ASL 
C1/73AA: 0A           ASL 
C1/73AB: AA           TAX 
C1/73AC: A9 16 00     LDA #$0016
C1/73AF: 85 84        STA $84
C1/73B1: BF 57 EE 7E  LDA $7EEE57,X
C1/73B5: F0 16        BEQ $73CD
C1/73B7: 29 FF 01     AND #$01FF
C1/73BA: 0A           ASL 
C1/73BB: 0A           ASL 
C1/73BC: 0A           ASL 
C1/73BD: 0A           ASL 
C1/73BE: 0A           ASL 
C1/73BF: 18           CLC 
C1/73C0: 65 86        ADC $86
C1/73C2: A8           TAY 
C1/73C3: 20 AB 78     JSR $78AB
C1/73C6: A9 01 00     LDA #$0001
C1/73C9: 8F 2F FF 7E  STA $7EFF2F
C1/73CD: E8           INX 
C1/73CE: E8           INX 
C1/73CF: C6 84        DEC $84
C1/73D1: D0 DE        BNE $73B1
C1/73D3: 7B           TDC 
C1/73D4: E2 20        SEP #$20
C1/73D6: AB           PLB 
C1/73D7: E6 80        INC $80
C1/73D9: E6 81        INC $81
C1/73DB: A5 81        LDA $81
C1/73DD: 30 04        BMI $73E3
C1/73DF: C9 14        CMP #$14
C1/73E1: B0 08        BCS $73EB
C1/73E3: E6 82        INC $82
C1/73E5: A5 82        LDA $82
C1/73E7: C9 08        CMP #$08
C1/73E9: D0 92        BNE $737D
C1/73EB: 60           RTS 
C1/73EC: EE 2E FF     INC $FF2E
C1/73EF: A9 78        LDA #$78
C1/73F1: 20 DB 72     JSR $72DB
C1/73F4: A9 47        LDA #$47
C1/73F6: 8D 04 FF     STA $FF04
C1/73F9: A9 03        LDA #$03
C1/73FB: 8D EC DB     STA $DBEC
C1/73FE: 9C 2C FF     STZ $FF2C
C1/7401: EE EB DB     INC $DBEB
C1/7404: A9 3C        LDA #$3C
C1/7406: 20 DB 72     JSR $72DB
C1/7409: A9 F0        LDA #$F0
C1/740B: 20 DB 72     JSR $72DB
C1/740E: A9 03        LDA #$03
C1/7410: 8D 9E BC     STA $BC9E
C1/7413: A9 02        LDA #$02
C1/7415: 8D 8B BC     STA $BC8B
C1/7418: 8D 8C BC     STA $BC8C
C1/741B: A9 80        LDA #$80
C1/741D: 8D 2D FF     STA $FF2D
C1/7420: A9 1C        LDA #$1C
C1/7422: 8D E9 F9     STA $F9E9
C1/7425: A2 E0 01     LDX #$01E0
C1/7428: DA           PHX 
C1/7429: 20 F2 02     JSR $02F2       ; wait one frame
C1/742C: 20 96 FC     JSR $FC96       ; generate random number
C1/742F: 29 3F        AND #$3F
C1/7431: D0 03        BNE $7436
C1/7433: 20 DB 72     JSR $72DB
C1/7436: FA           PLX 
C1/7437: CA           DEX 
C1/7438: D0 EE        BNE $7428
C1/743A: 20 39 75     JSR $7539
C1/743D: 20 29 75     JSR $7529
C1/7440: 20 96 FC     JSR $FC96       ; generate random number
C1/7443: 29 3F        AND #$3F
C1/7445: D0 03        BNE $744A
C1/7447: 20 DB 72     JSR $72DB
C1/744A: 7B           TDC 
C1/744B: AA           TAX 
C1/744C: 86 86        STX $86
C1/744E: AD E9 F9     LDA $F9E9
C1/7451: 20 71 74     JSR $7471
C1/7454: A2 10 00     LDX #$0010
C1/7457: 86 86        STX $86
C1/7459: AD E9 F9     LDA $F9E9
C1/745C: 18           CLC 
C1/745D: 69 04        ADC #$04
C1/745F: 20 71 74     JSR $7471
C1/7462: CE E9 F9     DEC $F9E9
C1/7465: AD E9 F9     LDA $F9E9
C1/7468: C9 F4        CMP #$F4
C1/746A: D0 D1        BNE $743D
C1/746C: A9 F0        LDA #$F0
C1/746E: 4C 41 81     JMP $8141       ; wait
C1/7471: 85 81        STA $81
C1/7473: 29 1F        AND #$1F
C1/7475: 85 80        STA $80
C1/7477: 64 82        STZ $82
C1/7479: 7B           TDC 
C1/747A: A8           TAY 
C1/747B: A5 82        LDA $82
C1/747D: 29 07        AND #$07
C1/747F: AA           TAX 
C1/7480: BF 7A 7C D9  LDA $D97C7A,X
C1/7484: 99 70 00     STA $0070,Y
C1/7487: 99 71 00     STA $0071,Y
C1/748A: E8           INX 
C1/748B: C8           INY 
C1/748C: C8           INY 
C1/748D: C0 10 00     CPY #$0010
C1/7490: D0 EE        BNE $7480
C1/7492: 8B           PHB 
C1/7493: A9 7F        LDA #$7F
C1/7495: 48           PHA 
C1/7496: AB           PLB 
C1/7497: A5 80        LDA $80
C1/7499: C2 20        REP #$20
C1/749B: 0A           ASL 
C1/749C: AA           TAX 
C1/749D: A9 14 00     LDA #$0014
C1/74A0: 85 84        STA $84
C1/74A2: BF 57 EE 7E  LDA $7EEE57,X
C1/74A6: 29 FF 01     AND #$01FF
C1/74A9: 0A           ASL 
C1/74AA: 0A           ASL 
C1/74AB: 0A           ASL 
C1/74AC: 0A           ASL 
C1/74AD: 0A           ASL 
C1/74AE: 18           CLC 
C1/74AF: 65 86        ADC $86
C1/74B1: A8           TAY 
C1/74B2: 20 64 78     JSR $7864
C1/74B5: 8A           TXA 
C1/74B6: 18           CLC 
C1/74B7: 69 40 00     ADC #$0040
C1/74BA: AA           TAX 
C1/74BB: C6 84        DEC $84
C1/74BD: D0 E3        BNE $74A2
C1/74BF: 7B           TDC 
C1/74C0: E2 20        SEP #$20
C1/74C2: AB           PLB 
C1/74C3: E6 80        INC $80
C1/74C5: E6 81        INC $81
C1/74C7: A5 81        LDA $81
C1/74C9: 30 04        BMI $74CF
C1/74CB: C9 20        CMP #$20
C1/74CD: B0 08        BCS $74D7
C1/74CF: E6 82        INC $82
C1/74D1: A5 82        LDA $82
C1/74D3: C9 08        CMP #$08
C1/74D5: D0 A2        BNE $7479
C1/74D7: 60           RTS 
C1/74D8: 20 39 75     JSR $7539
C1/74DB: A5 E4        LDA $E4
C1/74DD: 85 70        STA $70
C1/74DF: 7B           TDC 
C1/74E0: AA           TAX 
C1/74E1: A8           TAY 
C1/74E2: 06 70        ASL $70
C1/74E4: 90 1D        BCC $7503
C1/74E6: B9 E6 D0     LDA $D0E6,Y
C1/74E9: F0 2E        BEQ $7519
C1/74EB: C2 20        REP #$20
C1/74ED: 0A           ASL 
C1/74EE: 0A           ASL 
C1/74EF: 0A           ASL 
C1/74F0: 0A           ASL 
C1/74F1: 85 72        STA $72
C1/74F3: 7B           TDC 
C1/74F4: 9F 00 C0 7F  STA $7FC000,X
C1/74F8: E8           INX 
C1/74F9: E8           INX 
C1/74FA: C6 72        DEC $72
C1/74FC: D0 F6        BNE $74F4
C1/74FE: 7B           TDC 
C1/74FF: E2 20        SEP #$20
C1/7501: 80 16        BRA $7519
C1/7503: B9 E6 D0     LDA $D0E6,Y
C1/7506: F0 11        BEQ $7519
C1/7508: C2 20        REP #$20
C1/750A: 0A           ASL 
C1/750B: 0A           ASL 
C1/750C: 0A           ASL 
C1/750D: 0A           ASL 
C1/750E: 0A           ASL 
C1/750F: 85 72        STA $72
C1/7511: 8A           TXA 
C1/7512: 18           CLC 
C1/7513: 65 72        ADC $72
C1/7515: AA           TAX 
C1/7516: 7B           TDC 
C1/7517: E2 20        SEP #$20
C1/7519: C8           INY 
C1/751A: C0 08 00     CPY #$0008
C1/751D: D0 C3        BNE $74E2
C1/751F: 20 29 75     JSR $7529
C1/7522: A5 E4        LDA $E4
C1/7524: 85 70        STA $70
C1/7526: 4C 68 20     JMP $2068       ; load monster palettes
C1/7529: A2 00 40     LDX #$4000
C1/752C: 86 70        STX $70
C1/752E: A2 00 C0     LDX #$C000
C1/7531: A9 7F        LDA #$7F
C1/7533: A0 00 20     LDY #$2000
C1/7536: 4C 27 FD     JMP $FD27
C1/7539: 8B           PHB 
C1/753A: C2 20        REP #$20
C1/753C: A2 00 80     LDX #$8000
C1/753F: A0 00 C0     LDY #$C000
C1/7542: A9 FF 3F     LDA #$3FFF
C1/7545: 54 7F 7F     MVN $7F,$7F
C1/7548: 7B           TDC 
C1/7549: E2 20        SEP #$20
C1/754B: AB           PLB 
C1/754C: 60           RTS 

C1/754D: A5 70        LDA $70
C1/754F: 48           PHA 
C1/7550: A2 10 00     LDX #$0010
C1/7553: DA           PHX 
C1/7554: 20 F2 02     JSR $02F2       ; wait one frame
C1/7557: 7B           TDC 
C1/7558: AA           TAX 
C1/7559: C2 20        REP #$20
C1/755B: BD 69 7E     LDA $7E69,X
C1/755E: 20 76 75     JSR $7576
C1/7561: 9D 69 7E     STA $7E69,X
C1/7564: E8           INX 
C1/7565: E8           INX 
C1/7566: E0 20 00     CPX #$0020
C1/7569: D0 F0        BNE $755B
C1/756B: 7B           TDC 
C1/756C: E2 20        SEP #$20
C1/756E: FA           PLX 
C1/756F: CA           DEX 
C1/7570: D0 E1        BNE $7553
C1/7572: 68           PLA 
C1/7573: 85 70        STA $70
C1/7575: 60           RTS 

C1/7576: 85 72        STA $72
C1/7578: 29 1F 00     AND #$001F
C1/757B: C9 1F 00     CMP #$001F
C1/757E: F0 05        BEQ $7585
C1/7580: A5 72        LDA $72
C1/7582: 1A           INC 
C1/7583: 85 72        STA $72
C1/7585: A5 72        LDA $72
C1/7587: 29 E0 03     AND #$03E0
C1/758A: C9 E0 03     CMP #$03E0
C1/758D: F0 08        BEQ $7597
C1/758F: A5 72        LDA $72
C1/7591: 18           CLC 
C1/7592: 69 20 00     ADC #$0020
C1/7595: 85 72        STA $72
C1/7597: A5 72        LDA $72
C1/7599: 29 00 7C     AND #$7C00
C1/759C: C9 00 7C     CMP #$7C00
C1/759F: F0 08        BEQ $75A9
C1/75A1: A5 72        LDA $72
C1/75A3: 18           CLC 
C1/75A4: 69 00 04     ADC #$0400
C1/75A7: 85 72        STA $72
C1/75A9: A5 72        LDA $72
C1/75AB: 60           RTS 

C1/75AC: A5 70        LDA $70
C1/75AE: 49 FF        EOR #$FF
C1/75B0: 85 74        STA $74
C1/75B2: A5 DE        LDA $DE
C1/75B4: 25 74        AND $74
C1/75B6: 85 DE        STA $DE
C1/75B8: 4C B8 1C     JMP $1CB8

C1/75BB: C9 0A        CMP #$0A
C1/75BD: F0 07        BEQ $75C6
C1/75BF: 09 80        ORA #$80
C1/75C1: 85 E5        STA $E5
C1/75C3: 4C DB 75     JMP $75DB
C1/75C6: A5 70        LDA $70
C1/75C8: 48           PHA 
C1/75C9: 20 39 75     JSR $7539
C1/75CC: 20 29 75     JSR $7529
C1/75CF: 68           PLA 
C1/75D0: 05 DE        ORA $DE
C1/75D2: 85 DE        STA $DE
C1/75D4: 4C B8 1C     JMP $1CB8

; [ battle graphics function $08:  ]

C1/75D7: A9 81        LDA #$81
C1/75D9: 85 E5        STA $E5
C1/75DB: A5 70        LDA $70
C1/75DD: 85 E4        STA $E4
C1/75DF: A5 DE        LDA $DE
C1/75E1: 05 E4        ORA $E4
C1/75E3: 85 DE        STA $DE
C1/75E5: 20 D8 74     JSR $74D8
C1/75E8: 20 B8 1C     JSR $1CB8
C1/75EB: A5 E4        LDA $E4
C1/75ED: 49 FF        EOR #$FF
C1/75EF: 85 74        STA $74
C1/75F1: 7B           TDC 
C1/75F2: AA           TAX 
C1/75F3: 9D 2C F5     STA $F52C,X
C1/75F6: E8           INX 
C1/75F7: E0 10 00     CPX #$0010
C1/75FA: D0 F7        BNE $75F3
C1/75FC: 20 2C 77     JSR $772C
C1/75FF: 4C B8 1C     JMP $1CB8
C1/7602: C9 0A        CMP #$0A
C1/7604: F0 05        BEQ $760B
C1/7606: 85 E5        STA $E5
C1/7608: 4C 95 76     JMP $7695
C1/760B: 85 E5        STA $E5
C1/760D: 20 AC 75     JSR $75AC
C1/7610: 4C 2A 8B     JMP $8B2A

; [  ]

C1/7613: C9 0A        CMP #$0A
C1/7615: F0 05        BEQ $761C
C1/7617: 85 E5        STA $E5
C1/7619: 4C 5E 76     JMP $765E
C1/761C: 85 E5        STA $E5
C1/761E: 20 AC 75     JSR $75AC
C1/7621: 4C 2A 8B     JMP $8B2A
C1/7624: 7B           TDC 
C1/7625: AA           TAX 
C1/7626: BF 55 96 D9  LDA $D99655,X
C1/762A: 9D 69 7E     STA $7E69,X
C1/762D: E8           INX 
C1/762E: E0 20 00     CPX #$0020
C1/7631: D0 F3        BNE $7626
C1/7633: A5 70        LDA $70
C1/7635: 48           PHA 
C1/7636: 20 B1 1C     JSR $1CB1       ; load black and white monster palette
C1/7639: 68           PLA 
C1/763A: 85 70        STA $70
C1/763C: 60           RTS 

; [  ]

C1/763D: 7B           TDC 
C1/763E: AA           TAX 
C1/763F: A9 80        LDA #$80
C1/7641: 85 72        STA $72
C1/7643: 64 73        STZ $73
C1/7645: BD 9E 7B     LDA $7B9E,X
C1/7648: 29 30        AND #$30
C1/764A: F0 06        BEQ $7652
C1/764C: A5 73        LDA $73
C1/764E: 05 72        ORA $72
C1/7650: 85 73        STA $73
C1/7652: 46 72        LSR $72
C1/7654: E8           INX 
C1/7655: E8           INX 
C1/7656: E8           INX 
C1/7657: E8           INX 
C1/7658: E0 20 00     CPX #$0020
C1/765B: D0 E8        BNE $7645
C1/765D: 60           RTS 

; [  ]

C1/765E: A5 DE        LDA $DE
C1/7660: 25 70        AND $70
C1/7662: F0 06        BEQ $766A
C1/7664: 20 BC 76     JSR $76BC
C1/7667: 4C 2A 8B     JMP $8B2A
C1/766A: 60           RTS 

; [  ]

C1/766B: A5 DE        LDA $DE
C1/766D: 25 70        AND $70
C1/766F: F0 1A        BEQ $768B
C1/7671: A5 70        LDA $70
C1/7673: 49 FF        EOR #$FF
C1/7675: 85 72        STA $72
C1/7677: A5 DE        LDA $DE
C1/7679: 25 72        AND $72
C1/767B: D0 0E        BNE $768B
C1/767D: AD FE 3E     LDA $3EFE
C1/7680: 29 01        AND #$01
C1/7682: F0 07        BEQ $768B
C1/7684: 20 FB 72     JSR $72FB
C1/7687: 64 DE        STZ $DE
C1/7689: 38           SEC 
C1/768A: 60           RTS 
C1/768B: 18           CLC 
C1/768C: 60           RTS 

; [ battle graphics function $07: condemn death animation ]

C1/768D: 20 6B 76     JSR $766B
C1/7690: 90 01        BCC $7693
C1/7692: 60           RTS 
C1/7693: 64 E5        STZ $E5
C1/7695: A5 DE        LDA $DE
C1/7697: 25 70        AND $70
C1/7699: F0 10        BEQ $76AB
C1/769B: A9 33        LDA #$33
C1/769D: 8D B6 DB     STA $DBB6       ; sound effect volume
C1/76A0: A9 3B        LDA #$3B
C1/76A2: 20 D9 FB     JSR $FBD9       ; play sound effect
C1/76A5: 20 BC 76     JSR $76BC
C1/76A8: 20 2A 8B     JSR $8B2A
C1/76AB: AD 2C FF     LDA $FF2C
C1/76AE: 25 DE        AND $DE
C1/76B0: 8D 2C FF     STA $FF2C
C1/76B3: AD 2D FF     LDA $FF2D
C1/76B6: 25 DE        AND $DE
C1/76B8: 8D 2D FF     STA $FF2D
C1/76BB: 60           RTS 

; [  ]

C1/76BC: A9 01        LDA #$01
C1/76BE: 8D 8B BC     STA $BC8B
C1/76C1: A9 42        LDA #$42
C1/76C3: 8D 85 BC     STA $BC85
C1/76C6: A9 02        LDA #$02
C1/76C8: 8D 8C BC     STA $BC8C
C1/76CB: 20 E1 35     JSR $35E1       ; set priority bit for battle bg tiles
C1/76CE: 20 24 76     JSR $7624
C1/76D1: 20 4D 75     JSR $754D
C1/76D4: 20 3D 76     JSR $763D
C1/76D7: A5 70        LDA $70
C1/76D9: 25 73        AND $73
C1/76DB: 49 FF        EOR #$FF
C1/76DD: 85 73        STA $73
C1/76DF: A5 DE        LDA $DE
C1/76E1: 25 73        AND $73
C1/76E3: 85 DE        STA $DE
C1/76E5: A5 70        LDA $70
C1/76E7: 48           PHA 
C1/76E8: 20 B1 1C     JSR $1CB1       ; load black and white monster palette
C1/76EB: 68           PLA 
C1/76EC: 85 70        STA $70
C1/76EE: 20 FE 76     JSR $76FE
C1/76F1: 20 FE 35     JSR $35FE       ; clear priority bit for battle bg tiles
C1/76F4: 9C 8C BC     STZ $BC8C
C1/76F7: 9C 8B BC     STZ $BC8B
C1/76FA: 9C 85 BC     STZ $BC85
C1/76FD: 60           RTS 

; [  ]

C1/76FE: A5 70        LDA $70
C1/7700: 85 E3        STA $E3
C1/7702: 49 FF        EOR #$FF
C1/7704: 85 74        STA $74
C1/7706: A5 DE        LDA $DE
C1/7708: 25 E3        AND $E3
C1/770A: F0 1F        BEQ $772B
C1/770C: A5 DE        LDA $DE
C1/770E: 25 74        AND $74
C1/7710: 85 DE        STA $DE
C1/7712: 8B           PHB 
C1/7713: C2 20        REP #$20
C1/7715: A2 00 80     LDX #$8000
C1/7718: A0 00 C0     LDY #$C000
C1/771B: A9 FF 3F     LDA #$3FFF
C1/771E: 54 7F 7F     MVN $7F,$7F
C1/7721: 7B           TDC 
C1/7722: E2 20        SEP #$20
C1/7724: AB           PLB 
C1/7725: 20 2C 77     JSR $772C
C1/7728: 4C B8 1C     JMP $1CB8
C1/772B: 60           RTS 

; [ something with boss dissolve death ??? ]

C1/772C: 7B           TDC 
C1/772D: AA           TAX 
C1/772E: A8           TAY 
C1/772F: B9 E6 D0     LDA $D0E6,Y
C1/7732: F0 10        BEQ $7744
C1/7734: 85 76        STA $76
C1/7736: 06 74        ASL $74
C1/7738: 2A           ROL 
C1/7739: 29 01        AND #$01
C1/773B: 9F 00 75 7F  STA $7F7500,X
C1/773F: E8           INX 
C1/7740: C6 76        DEC $76
C1/7742: D0 F7        BNE $773B
C1/7744: C8           INY 
C1/7745: C0 08 00     CPY #$0008
C1/7748: D0 E5        BNE $772F
C1/774A: A2 00 00     LDX #$0000
C1/774D: A0 00 C0     LDY #$C000
C1/7750: 8C E2 D0     STY $D0E2
C1/7753: A0 00 20     LDY #$2000
C1/7756: 8C E4 D0     STY $D0E4
C1/7759: A0 00 00     LDY #$0000
C1/775C: 20 8A 77     JSR $778A
C1/775F: C2 20        REP #$20
C1/7761: AD E2 D0     LDA $D0E2
C1/7764: 18           CLC 
C1/7765: 69 00 08     ADC #$0800
C1/7768: 8D E2 D0     STA $D0E2
C1/776B: AD E4 D0     LDA $D0E4
C1/776E: 18           CLC 
C1/776F: 69 00 04     ADC #$0400
C1/7772: 8D E4 D0     STA $D0E4
C1/7775: 98           TYA 
C1/7776: 18           CLC 
C1/7777: 69 00 08     ADC #$0800
C1/777A: A8           TAY 
C1/777B: 7B           TDC 
C1/777C: E2 20        SEP #$20
C1/777E: C0 00 40     CPY #$4000
C1/7781: D0 D9        BNE $775C
C1/7783: E8           INX 
C1/7784: E0 08 00     CPX #$0008
C1/7787: D0 C4        BNE $774D
C1/7789: 60           RTS 

; [  ]

C1/778A: DA           PHX 
C1/778B: 5A           PHY 
C1/778C: 5A           PHY 
C1/778D: A0 00 00     LDY #$0000
C1/7790: 8A           TXA 
C1/7791: 85 86        STA $86
C1/7793: A5 E5        LDA $E5
C1/7795: 29 7F        AND #$7F
C1/7797: 0A           ASL 
C1/7798: 0A           ASL 
C1/7799: 0A           ASL 
C1/779A: 0A           ASL 
C1/779B: 18           CLC 
C1/779C: 65 86        ADC $86
C1/779E: AA           TAX 
C1/779F: A5 E5        LDA $E5
C1/77A1: 30 06        BMI $77A9
C1/77A3: BF 7A 7C D9  LDA $D97C7A,X
C1/77A7: 80 0C        BRA $77B5
C1/77A9: BF 7A 7C D9  LDA $D97C7A,X
C1/77AD: 49 FF        EOR #$FF
C1/77AF: 19 2C F5     ORA $F52C,Y
C1/77B2: 99 2C F5     STA $F52C,Y
C1/77B5: 99 70 00     STA $0070,Y
C1/77B8: 99 71 00     STA $0071,Y
C1/77BB: A5 E5        LDA $E5
C1/77BD: 85 85        STA $85
C1/77BF: 64 84        STZ $84
C1/77C1: E8           INX 
C1/77C2: C8           INY 
C1/77C3: C8           INY 
C1/77C4: C0 10 00     CPY #$0010
C1/77C7: D0 D6        BNE $779F
C1/77C9: 7A           PLY 
C1/77CA: A9 40        LDA #$40
C1/77CC: 85 86        STA $86
C1/77CE: 64 87        STZ $87
C1/77D0: 8B           PHB 
C1/77D1: A9 7F        LDA #$7F
C1/77D3: 48           PHA 
C1/77D4: AB           PLB 
C1/77D5: C2 20        REP #$20
C1/77D7: 98           TYA 
C1/77D8: 4A           LSR 
C1/77D9: 4A           LSR 
C1/77DA: 4A           LSR 
C1/77DB: 4A           LSR 
C1/77DC: 4A           LSR 
C1/77DD: AA           TAX 
C1/77DE: BF 00 75 7F  LDA $7F7500,X
C1/77E2: 29 01 00     AND #$0001
C1/77E5: F0 08        BEQ $77EF
C1/77E7: 98           TYA 
C1/77E8: 18           CLC 
C1/77E9: 69 20 00     ADC #$0020
C1/77EC: A8           TAY 
C1/77ED: 80 12        BRA $7801
C1/77EF: A5 84        LDA $84
C1/77F1: 30 08        BMI $77FB
C1/77F3: 20 64 78     JSR $7864
C1/77F6: 20 64 78     JSR $7864
C1/77F9: 80 06        BRA $7801
C1/77FB: 20 1D 78     JSR $781D
C1/77FE: 20 1D 78     JSR $781D
C1/7801: E8           INX 
C1/7802: C6 86        DEC $86
C1/7804: D0 D8        BNE $77DE
C1/7806: 7B           TDC 
C1/7807: E2 20        SEP #$20
C1/7809: AB           PLB 
C1/780A: A2 00 08     LDX #$0800
C1/780D: 86 70        STX $70
C1/780F: AE E2 D0     LDX $D0E2
C1/7812: A9 7F        LDA #$7F
C1/7814: AC E4 D0     LDY $D0E4
C1/7817: 20 27 FD     JSR $FD27
C1/781A: 7A           PLY 
C1/781B: FA           PLX 
C1/781C: 60           RTS 

C1/781D: B9 00 80     LDA $8000,Y
C1/7820: 25 70        AND $70
C1/7822: 99 00 C0     STA $C000,Y
C1/7825: B9 02 80     LDA $8002,Y
C1/7828: 25 72        AND $72
C1/782A: 99 02 C0     STA $C002,Y
C1/782D: B9 04 80     LDA $8004,Y
C1/7830: 25 74        AND $74
C1/7832: 99 04 C0     STA $C004,Y
C1/7835: B9 06 80     LDA $8006,Y
C1/7838: 25 76        AND $76
C1/783A: 99 06 C0     STA $C006,Y
C1/783D: B9 08 80     LDA $8008,Y
C1/7840: 25 78        AND $78
C1/7842: 99 08 C0     STA $C008,Y
C1/7845: B9 0A 80     LDA $800A,Y
C1/7848: 25 7A        AND $7A
C1/784A: 99 0A C0     STA $C00A,Y
C1/784D: B9 0C 80     LDA $800C,Y
C1/7850: 25 7C        AND $7C
C1/7852: 99 0C C0     STA $C00C,Y
C1/7855: B9 0E 80     LDA $800E,Y
C1/7858: 25 7E        AND $7E
C1/785A: 99 0E C0     STA $C00E,Y
C1/785D: 98           TYA 
C1/785E: 18           CLC 
C1/785F: 69 10 00     ADC #$0010
C1/7862: A8           TAY
C1/7863: 60           RTS 

; [  ]

C1/7864: B9 00 C0     LDA $C000,Y
C1/7867: 25 70        AND $70
C1/7869: 99 00 C0     STA $C000,Y
C1/786C: B9 02 C0     LDA $C002,Y
C1/786F: 25 72        AND $72
C1/7871: 99 02 C0     STA $C002,Y
C1/7874: B9 04 C0     LDA $C004,Y
C1/7877: 25 74        AND $74
C1/7879: 99 04 C0     STA $C004,Y
C1/787C: B9 06 C0     LDA $C006,Y
C1/787F: 25 76        AND $76
C1/7881: 99 06 C0     STA $C006,Y
C1/7884: B9 08 C0     LDA $C008,Y
C1/7887: 25 78        AND $78
C1/7889: 99 08 C0     STA $C008,Y
C1/788C: B9 0A C0     LDA $C00A,Y
C1/788F: 25 7A        AND $7A
C1/7891: 99 0A C0     STA $C00A,Y
C1/7894: B9 0C C0     LDA $C00C,Y
C1/7897: 25 7C        AND $7C
C1/7899: 99 0C C0     STA $C00C,Y
C1/789C: B9 0E C0     LDA $C00E,Y
C1/789F: 25 7E        AND $7E
C1/78A1: 99 0E C0     STA $C00E,Y
C1/78A4: 98           TYA 
C1/78A5: 18           CLC 
C1/78A6: 69 10 00     ADC #$0010
C1/78A9: A8           TAY 
C1/78AA: 60           RTS 

; [  ]

C1/78AB: C2 20        REP #$20
C1/78AD: B9 00 C0     LDA $C000,Y
C1/78B0: 25 70        AND $70
C1/78B2: 99 00 C0     STA $C000,Y
C1/78B5: B9 02 C0     LDA $C002,Y
C1/78B8: 25 72        AND $72
C1/78BA: 99 02 C0     STA $C002,Y
C1/78BD: B9 04 C0     LDA $C004,Y
C1/78C0: 25 74        AND $74
C1/78C2: 99 04 C0     STA $C004,Y
C1/78C5: B9 06 C0     LDA $C006,Y
C1/78C8: 25 76        AND $76
C1/78CA: 99 06 C0     STA $C006,Y
C1/78CD: B9 08 C0     LDA $C008,Y
C1/78D0: 25 78        AND $78
C1/78D2: 99 08 C0     STA $C008,Y
C1/78D5: B9 0A C0     LDA $C00A,Y
C1/78D8: 25 7A        AND $7A
C1/78DA: 99 0A C0     STA $C00A,Y
C1/78DD: B9 0C C0     LDA $C00C,Y
C1/78E0: 25 7C        AND $7C
C1/78E2: 99 0C C0     STA $C00C,Y
C1/78E5: B9 0E C0     LDA $C00E,Y
C1/78E8: 25 7E        AND $7E
C1/78EA: 99 0E C0     STA $C00E,Y
C1/78ED: 98           TYA 
C1/78EE: 18           CLC 
C1/78EF: 69 10        ADC #$10
C1/78F1: A8           TAY 
C1/78F2: C2 20        REP #$20
C1/78F4: 60           RTS 

; [ misc effect $03: flash screen ]

C1/78F5: A9 1E        LDA #$1E
C1/78F7: 8D C8 F8     STA $F8C8
C1/78FA: EE C7 F8     INC $F8C7
C1/78FD: 60           RTS 

; [ update screen flash ]

C1/78FE: AD C7 F8     LDA $F8C7
C1/7901: F0 2C        BEQ $792F
C1/7903: A9 02        LDA #$02        ; color math affect bg2
C1/7905: 8D 85 BC     STA $BC85
C1/7908: AD C8 F8     LDA $F8C8
C1/790B: 09 E0        ORA #$E0        ; flash white
C1/790D: 8D 88 BC     STA $BC88
C1/7910: 8D 89 BC     STA $BC89
C1/7913: 8D 8A BC     STA $BC8A
C1/7916: CE C8 F8     DEC $F8C8
C1/7919: CE C8 F8     DEC $F8C8
C1/791C: D0 11        BNE $792F
C1/791E: A9 E0        LDA #$E0        ; clear screen flash intensity
C1/7920: 8D 88 BC     STA $BC88
C1/7923: 8D 89 BC     STA $BC89
C1/7926: 8D 8A BC     STA $BC8A
C1/7929: 9C C7 F8     STZ $F8C7
C1/792C: 9C 85 BC     STZ $BC85       ; color math affect none
C1/792F: 60           RTS 

; [  ]

C1/7930: AD 56 DB     LDA $DB56
C1/7933: F0 43        BEQ $7978
C1/7935: A5 A2        LDA $A2
C1/7937: 29 03 D0     AND #$D003
C1/793A: 3D A9 01     AND $01A9,X
C1/793D: 85 98        STA $98
C1/793F: A9 07 85     LDA #$8507
C1/7942: 9A           TXS 
C1/7943: 06 98        ASL $98
C1/7945: A5 9A        LDA $9A
C1/7947: 0A           ASL 
C1/7948: 18           CLC 
C1/7949: 65 98        ADC $98
C1/794B: AA           TAX 
C1/794C: 64 9B        STZ $9B
C1/794E: C2 20        REP #$20
C1/7950: BD 49 F8     LDA $F849,X
C1/7953: 48           PHA 
C1/7954: BD 47 F8     LDA $F847,X
C1/7957: 9D 49 F8     STA $F849,X
C1/795A: CA           DEX 
C1/795B: CA           DEX 
C1/795C: C6 9A        DEC $9A
C1/795E: D0 F4        BNE $7954
C1/7960: 68           PLA 
C1/7961: 9D 49 F8     STA $F849,X
C1/7964: 7B           TDC 
C1/7965: E2 20        SEP #$20
C1/7967: 7B           TDC 
C1/7968: AA           TAX 
C1/7969: BD 49 F8     LDA $F849,X
C1/796C: 9D 69 7E     STA $7E69,X
C1/796F: 9D 79 7E     STA $7E79,X
C1/7972: E8           INX 
C1/7973: E0 10 00     CPX #$0010
C1/7976: D0 F1        BNE $7969
C1/7978: 60           RTS 
C1/7979: 20 30 79     JSR $7930
C1/797C: AD EE D0     LDA $D0EE
C1/797F: F0 03        BEQ $7984
C1/7981: 20 B4 7E     JSR $7EB4
C1/7984: AD F0 D0     LDA $D0F0
C1/7987: F0 03        BEQ $798C
C1/7989: 20 5F 7D     JSR $7D5F
C1/798C: AD F2 D0     LDA $D0F2
C1/798F: F0 03        BEQ $7994
C1/7991: 20 A0 7B     JSR $7BA0
C1/7994: AD F4 D0     LDA $D0F4
C1/7997: F0 03        BEQ $799C
C1/7999: 20 B5 7C     JSR $7CB5
C1/799C: AD F6 D0     LDA $D0F6
C1/799F: F0 03        BEQ $79A4
C1/79A1: 20 49 7C     JSR $7C49
C1/79A4: 60           RTS 

C1/79A5: DA           PHX 
C1/79A6: 5A           PHY 
C1/79A7: AA           TAX 
C1/79A8: BF 25 7D D9  LDA $D97D25,X
C1/79AC: 85 80        STA $80
C1/79AE: AD F7 D0     LDA $D0F7
C1/79B1: D0 10        BNE $79C3
C1/79B3: A9 0A        LDA #$0A        ; mode 2
C1/79B5: 8D 81 BC     STA $BC81
C1/79B8: A5 7E        LDA $7E
C1/79BA: 8D 0D D1     STA $D10D
C1/79BD: 9C 0E D1     STZ $D10E
C1/79C0: 9C 0F D1     STZ $D10F
C1/79C3: A5 7E        LDA $7E
C1/79C5: 10 2E        BPL $79F5
C1/79C7: A5 80        LDA $80
C1/79C9: 49 FF        EOR #$FF
C1/79CB: 85 80        STA $80
C1/79CD: AD F7 D0     LDA $D0F7
C1/79D0: 25 80        AND $80
C1/79D2: 8D F7 D0     STA $D0F7
C1/79D5: D0 2B        BNE $7A02
C1/79D7: 9C F6 D0     STZ $D0F6
C1/79DA: 9C F7 D0     STZ $D0F7
C1/79DD: 9C 0D D1     STZ $D10D
C1/79E0: 7B           TDC 
C1/79E1: AA           TAX 
C1/79E2: 9D 04 B4     STA $B404,X
C1/79E5: E8           INX 
C1/79E6: E0 40 00     CPX #$0040
C1/79E9: D0 F7        BNE $79E2
C1/79EB: EE C0 B3     INC $B3C0
C1/79EE: A9 09        LDA #$09        ; mode 1
C1/79F0: 8D 81 BC     STA $BC81
C1/79F3: 80 0D        BRA $7A02
C1/79F5: A9 01        LDA #$01
C1/79F7: 8D F6 D0     STA $D0F6
C1/79FA: AD F7 D0     LDA $D0F7
C1/79FD: 05 80        ORA $80
C1/79FF: 8D F7 D0     STA $D0F7
C1/7A02: C2 20        REP #$20
C1/7A04: 7B           TDC 
C1/7A05: A8           TAY 
C1/7A06: B9 70 00     LDA $0070,Y
C1/7A09: 48           PHA 
C1/7A0A: C8           INY 
C1/7A0B: C8           INY 
C1/7A0C: C0 0C 00     CPY #$000C
C1/7A0F: D0 F5        BNE $7A06
C1/7A11: 7B           TDC 
C1/7A12: E2 20        SEP #$20
C1/7A14: 20 BB 3C     JSR $3CBB
C1/7A17: C2 20        REP #$20
C1/7A19: A0 0C 00     LDY #$000C
C1/7A1C: 68           PLA 
C1/7A1D: 99 6E 00     STA $006E,Y
C1/7A20: 88           DEY 
C1/7A21: 88           DEY 
C1/7A22: D0 F8        BNE $7A1C
C1/7A24: 7B           TDC 
C1/7A25: E2 20        SEP #$20
C1/7A27: 7A           PLY 
C1/7A28: FA           PLX 
C1/7A29: 60           RTS 

C1/7A2A: DA           PHX 
C1/7A2B: 5A           PHY 
C1/7A2C: AA           TAX 
C1/7A2D: BF 25 7D D9  LDA $D97D25,X
C1/7A31: 85 80        STA $80
C1/7A33: AD F5 D0     LDA $D0F5
C1/7A36: D0 13        BNE $7A4B
C1/7A38: AD 84 BC     LDA $BC84
C1/7A3B: 09 01        ORA #$01
C1/7A3D: 8D 84 BC     STA $BC84
C1/7A40: A5 7E        LDA $7E
C1/7A42: 8D 0A D1     STA $D10A
C1/7A45: 9C 0B D1     STZ $D10B
C1/7A48: 9C 0C D1     STZ $D10C
C1/7A4B: A5 7E        LDA $7E
C1/7A4D: 10 34        BPL $7A83
C1/7A4F: A5 80        LDA $80
C1/7A51: 49 FF        EOR #$FF
C1/7A53: 85 80        STA $80
C1/7A55: AD F5 D0     LDA $D0F5
C1/7A58: 25 80        AND $80
C1/7A5A: 8D F5 D0     STA $D0F5
C1/7A5D: D0 31        BNE $7A90
C1/7A5F: 9C F4 D0     STZ $D0F4
C1/7A62: 9C F5 D0     STZ $D0F5
C1/7A65: 9C 0A D1     STZ $D10A
C1/7A68: 7B           TDC 
C1/7A69: AA           TAX 
C1/7A6A: 9D 37 A9     STA $A937,X
C1/7A6D: 9D B7 A9     STA $A9B7,X
C1/7A70: 9D B7 AC     STA $ACB7,X
C1/7A73: E8           INX 
C1/7A74: E0 80 00     CPX #$0080
C1/7A77: D0 F1        BNE $7A6A
C1/7A79: AD 84 BC     LDA $BC84
C1/7A7C: 29 FE        AND #$FE
C1/7A7E: 8D 84 BC     STA $BC84
C1/7A81: 80 0D        BRA $7A90
C1/7A83: A9 01        LDA #$01
C1/7A85: 8D F4 D0     STA $D0F4
C1/7A88: AD F5 D0     LDA $D0F5
C1/7A8B: 05 80        ORA $80
C1/7A8D: 8D F5 D0     STA $D0F5
C1/7A90: 7A           PLY 
C1/7A91: FA           PLX 
C1/7A92: 60           RTS 

; [  ]

C1/7A93: DA           PHX 
C1/7A94: 5A           PHY 
C1/7A95: AA           TAX 
C1/7A96: BF 25 7D D9  LDA $D97D25,X
C1/7A9A: 85 80        STA $80
C1/7A9C: AD F3 D0     LDA $D0F3
C1/7A9F: D0 0B        BNE $7AAC
C1/7AA1: A5 7E        LDA $7E
C1/7AA3: 8D 06 D1     STA $D106
C1/7AA6: 9C 08 D1     STZ $D108
C1/7AA9: 9C 09 D1     STZ $D109
C1/7AAC: A5 7E        LDA $7E
C1/7AAE: 10 42        BPL $7AF2
C1/7AB0: A5 80        LDA $80
C1/7AB2: 49 FF        EOR #$FF
C1/7AB4: 85 80        STA $80
C1/7AB6: AD F3 D0     LDA $D0F3
C1/7AB9: 25 80        AND $80
C1/7ABB: 8D F3 D0     STA $D0F3
C1/7ABE: D0 3F        BNE $7AFF
C1/7AC0: 9C F2 D0     STZ $D0F2
C1/7AC3: 9C F3 D0     STZ $D0F3
C1/7AC6: 9C 06 D1     STZ $D106
C1/7AC9: 9C 77 BC     STZ $BC77
C1/7ACC: 9C 79 BC     STZ $BC79
C1/7ACF: 7B           TDC 
C1/7AD0: AA           TAX 
C1/7AD1: 9D 37 A9     STA $A937,X
C1/7AD4: 9D B7 A9     STA $A9B7,X
C1/7AD7: 9D B7 AC     STA $ACB7,X
C1/7ADA: E8           INX 
C1/7ADB: E0 80 00     CPX #$0080
C1/7ADE: D0 F1        BNE $7AD1
C1/7AE0: AD C5 F8     LDA $F8C5
C1/7AE3: D0 0B        BNE $7AF0
C1/7AE5: 7B           TDC 
C1/7AE6: AA           TAX 
C1/7AE7: 9D B7 AC     STA $ACB7,X
C1/7AEA: E8           INX 
C1/7AEB: E0 80 00     CPX #$0080
C1/7AEE: D0 F7        BNE $7AE7
C1/7AF0: 80 0D        BRA $7AFF
C1/7AF2: A9 01        LDA #$01
C1/7AF4: 8D F2 D0     STA $D0F2
C1/7AF7: AD F3 D0     LDA $D0F3
C1/7AFA: 05 80        ORA $80
C1/7AFC: 8D F3 D0     STA $D0F3
C1/7AFF: 7A           PLY 
C1/7B00: FA           PLX 
C1/7B01: 60           RTS 

; [  ]

C1/7B02: DA           PHX 
C1/7B03: 5A           PHY 
C1/7B04: AA           TAX 
C1/7B05: BF 25 7D D9  LDA $D97D25,X
C1/7B09: 85 80        STA $80
C1/7B0B: AD F1 D0     LDA $D0F1
C1/7B0E: D0 08        BNE $7B18
C1/7B10: 20 52 7D     JSR $7D52
C1/7B13: A5 7E        LDA $7E
C1/7B15: 8D 02 D1     STA $D102
C1/7B18: A5 7E        LDA $7E
C1/7B1A: 29 07        AND #$07
C1/7B1C: D0 15        BNE $7B33
C1/7B1E: A5 80        LDA $80
C1/7B20: 49 FF        EOR #$FF
C1/7B22: 85 80        STA $80
C1/7B24: AD F1 D0     LDA $D0F1
C1/7B27: 25 80        AND $80
C1/7B29: 8D F1 D0     STA $D0F1
C1/7B2C: D0 12        BNE $7B40
C1/7B2E: 20 8C 7D     JSR $7D8C
C1/7B31: 80 0D        BRA $7B40
C1/7B33: A9 01        LDA #$01
C1/7B35: 8D F0 D0     STA $D0F0
C1/7B38: AD F1 D0     LDA $D0F1
C1/7B3B: 05 80        ORA $80
C1/7B3D: 8D F1 D0     STA $D0F1
C1/7B40: 7A           PLY 
C1/7B41: FA           PLX 
C1/7B42: 60           RTS 

; [  ]

C1/7B43: DA           PHX 
C1/7B44: 5A           PHY 
C1/7B45: AA           TAX 
C1/7B46: AD BD F8     LDA $F8BD
C1/7B49: C9 FF        CMP #$FF
C1/7B4B: D0 44        BNE $7B91
C1/7B4D: BF 25 7D D9  LDA $D97D25,X
C1/7B51: 85 80        STA $80
C1/7B53: AD EF D0     LDA $D0EF
C1/7B56: D0 0B        BNE $7B63
C1/7B58: 9C 00 D1     STZ $D100
C1/7B5B: 20 AB 7E     JSR $7EAB
C1/7B5E: A5 7E        LDA $7E
C1/7B60: 8D FE D0     STA $D0FE
C1/7B63: A5 7E        LDA $7E
C1/7B65: 29 07        AND #$07
C1/7B67: D0 1B        BNE $7B84
C1/7B69: A5 80        LDA $80
C1/7B6B: 49 FF        EOR #$FF
C1/7B6D: 85 80        STA $80
C1/7B6F: AD EF D0     LDA $D0EF
C1/7B72: 25 80        AND $80
C1/7B74: 8D EF D0     STA $D0EF
C1/7B77: D0 18        BNE $7B91
C1/7B79: 9C EE D0     STZ $D0EE
C1/7B7C: 9C FE D0     STZ $D0FE
C1/7B7F: 20 E2 7E     JSR $7EE2
C1/7B82: 80 0D        BRA $7B91
C1/7B84: A9 01        LDA #$01
C1/7B86: 8D EE D0     STA $D0EE
C1/7B89: AD EF D0     LDA $D0EF
C1/7B8C: 05 80        ORA $80
C1/7B8E: 8D EF D0     STA $D0EF
C1/7B91: 7A           PLY 
C1/7B92: FA           PLX 
C1/7B93: 60           RTS 
C1/7B94: 7B           TDC 
C1/7B95: AA           TAX 
C1/7B96: 9D EE D0     STA $D0EE,X
C1/7B99: E8           INX 
C1/7B9A: E0 0A 00     CPX #$000A
C1/7B9D: D0 F7        BNE $7B96
C1/7B9F: 60           RTS 
C1/7BA0: AD 07 D1     LDA $D107
C1/7BA3: 29 01        AND #$01
C1/7BA5: D0 2E        BNE $7BD5
C1/7BA7: AD 06 D1     LDA $D106
C1/7BAA: 29 1C        AND #$1C
C1/7BAC: 4A           LSR 
C1/7BAD: 4A           LSR 
C1/7BAE: 85 8C        STA $8C
C1/7BB0: 64 88        STZ $88
C1/7BB2: 64 8A        STZ $8A
C1/7BB4: AD 06 D1     LDA $D106
C1/7BB7: 29 40        AND #$40
C1/7BB9: F0 08        BEQ $7BC3
C1/7BBB: 20 96 FC     JSR $FC96       ; generate random number
C1/7BBE: 25 8C        AND $8C
C1/7BC0: 8D 08 D1     STA $D108
C1/7BC3: AD 06 D1     LDA $D106
C1/7BC6: 29 20        AND #$20
C1/7BC8: F0 0B        BEQ $7BD5
C1/7BCA: 20 96 FC     JSR $FC96       ; generate random number
C1/7BCD: 25 8C        AND $8C
C1/7BCF: 49 FF        EOR #$FF
C1/7BD1: 1A           INC 
C1/7BD2: 8D 09 D1     STA $D109
C1/7BD5: AD 08 D1     LDA $D108
C1/7BD8: 85 88        STA $88
C1/7BDA: AD 09 D1     LDA $D109
C1/7BDD: 85 8A        STA $8A
C1/7BDF: AD 07 D1     LDA $D107
C1/7BE2: 29 01        AND #$01
C1/7BE4: D0 2E        BNE $7C14
C1/7BE6: AD 06 D1     LDA $D106
C1/7BE9: 29 01        AND #$01
C1/7BEB: F0 27        BEQ $7C14
C1/7BED: 7B           TDC 
C1/7BEE: AA           TAX 
C1/7BEF: A5 88        LDA $88
C1/7BF1: 9D 37 A9     STA $A937,X
C1/7BF4: 9D B7 A9     STA $A9B7,X
C1/7BF7: A5 8A        LDA $8A
C1/7BF9: 9D 39 A9     STA $A939,X
C1/7BFC: 9D B9 A9     STA $A9B9,X
C1/7BFF: E8           INX 
C1/7C00: E8           INX 
C1/7C01: E8           INX 
C1/7C02: E8           INX 
C1/7C03: E0 80 00     CPX #$0080
C1/7C06: D0 E7        BNE $7BEF
C1/7C08: A5 88        LDA $88
C1/7C0A: 8D 77 BC     STA $BC77
C1/7C0D: A5 8A        LDA $8A
C1/7C0F: 8D 79 BC     STA $BC79
C1/7C12: 80 31        BRA $7C45
C1/7C14: AD 06 D1     LDA $D106
C1/7C17: 29 02        AND #$02
C1/7C19: F0 2A        BEQ $7C45
C1/7C1B: AD C5 F8     LDA $F8C5
C1/7C1E: D0 10        BNE $7C30
C1/7C20: 7B           TDC 
C1/7C21: AA           TAX 
C1/7C22: A5 88        LDA $88
C1/7C24: 9D B7 AC     STA $ACB7,X
C1/7C27: E8           INX 
C1/7C28: E8           INX 
C1/7C29: E8           INX 
C1/7C2A: E8           INX 
C1/7C2B: E0 80 00     CPX #$0080
C1/7C2E: D0 F2        BNE $7C22
C1/7C30: AD C6 F8     LDA $F8C6
C1/7C33: D0 10        BNE $7C45
C1/7C35: 7B           TDC 
C1/7C36: AA           TAX 
C1/7C37: A5 88        LDA $88
C1/7C39: 9D B9 AC     STA $ACB9,X
C1/7C3C: E8           INX 
C1/7C3D: E8           INX 
C1/7C3E: E8           INX 
C1/7C3F: E8           INX 
C1/7C40: E0 80 00     CPX #$0080
C1/7C43: D0 F2        BNE $7C37
C1/7C45: EE 07 D1     INC $D107
C1/7C48: 60           RTS 
C1/7C49: AD 0D D1     LDA $D10D
C1/7C4C: 29 1C        AND #$1C
C1/7C4E: 4A           LSR 
C1/7C4F: 4A           LSR 
C1/7C50: 85 8E        STA $8E
C1/7C52: AD 0D D1     LDA $D10D
C1/7C55: 29 03        AND #$03
C1/7C57: 0A           ASL 
C1/7C58: 0A           ASL 
C1/7C59: 0A           ASL 
C1/7C5A: 0A           ASL 
C1/7C5B: 0A           ASL 
C1/7C5C: 85 8C        STA $8C
C1/7C5E: 7B           TDC 
C1/7C5F: A8           TAY 
C1/7C60: AD 0F D1     LDA $D10F
C1/7C63: 85 88        STA $88
C1/7C65: AD 0D D1     LDA $D10D
C1/7C68: 29 1C        AND #$1C
C1/7C6A: 4A           LSR 
C1/7C6B: 85 9A        STA $9A
C1/7C6D: A5 88        LDA $88
C1/7C6F: 20 32 0A     JSR $0A32
C1/7C72: 64 98        STZ $98
C1/7C74: 38           SEC 
C1/7C75: E5 8E        SBC $8E
C1/7C77: 10 06        BPL $7C7F
C1/7C79: 48           PHA 
C1/7C7A: A9 03        LDA #$03
C1/7C7C: 85 98        STA $98
C1/7C7E: 68           PLA 
C1/7C7F: 99 04 B4     STA $B404,Y
C1/7C82: A5 8C        LDA $8C
C1/7C84: 05 98        ORA $98
C1/7C86: 99 05 B4     STA $B405,Y
C1/7C89: A5 88        LDA $88
C1/7C8B: 18           CLC 
C1/7C8C: 69 08        ADC #$08
C1/7C8E: 85 88        STA $88
C1/7C90: C8           INY 
C1/7C91: C8           INY 
C1/7C92: C0 40 00     CPY #$0040
C1/7C95: D0 CE        BNE $7C65
C1/7C97: AD 0D D1     LDA $D10D
C1/7C9A: 29 60        AND #$60
C1/7C9C: 4A           LSR 
C1/7C9D: 4A           LSR 
C1/7C9E: 4A           LSR 
C1/7C9F: 4A           LSR 
C1/7CA0: 4A           LSR 
C1/7CA1: AA           TAX 
C1/7CA2: AD 0F D1     LDA $D10F
C1/7CA5: 18           CLC 
C1/7CA6: 7F B1 7C C1  ADC $C17CB1,X
C1/7CAA: 8D 0F D1     STA $D10F
C1/7CAD: EE C0 B3     INC $B3C0
C1/7CB0: 60           RTS 
C1/7CB1: 04 08        TSB $08
C1/7CB3: 10 20        BPL $7CD5
C1/7CB5: AD 0A D1     LDA $D10A
C1/7CB8: 29 60        AND #$60
C1/7CBA: 4A           LSR 
C1/7CBB: 4A           LSR 
C1/7CBC: 4A           LSR 
C1/7CBD: 4A           LSR 
C1/7CBE: 4A           LSR 
C1/7CBF: AA           TAX 
C1/7CC0: BF 4E 7D C1  LDA $C17D4E,X
C1/7CC4: 85 92        STA $92
C1/7CC6: AD 0A D1     LDA $D10A
C1/7CC9: 29 1C        AND #$1C
C1/7CCB: 4A           LSR 
C1/7CCC: 85 9A        STA $9A
C1/7CCE: AD 0C D1     LDA $D10C
C1/7CD1: 85 88        STA $88
C1/7CD3: 7B           TDC 
C1/7CD4: AA           TAX 
C1/7CD5: DA           PHX 
C1/7CD6: AD 0A D1     LDA $D10A
C1/7CD9: 29 1C        AND #$1C
C1/7CDB: 4A           LSR 
C1/7CDC: 85 9A        STA $9A
C1/7CDE: A5 88        LDA $88
C1/7CE0: 20 32 0A     JSR $0A32
C1/7CE3: FA           PLX 
C1/7CE4: 9D CC F9     STA $F9CC,X
C1/7CE7: A5 88        LDA $88
C1/7CE9: 18           CLC 
C1/7CEA: 69 10        ADC #$10
C1/7CEC: 85 88        STA $88
C1/7CEE: E8           INX 
C1/7CEF: E0 10 00     CPX #$0010
C1/7CF2: D0 E1        BNE $7CD5
C1/7CF4: AD 0B D1     LDA $D10B
C1/7CF7: 29 01        AND #$01
C1/7CF9: D0 23        BNE $7D1E
C1/7CFB: AD 0A D1     LDA $D10A
C1/7CFE: 29 01        AND #$01
C1/7D00: F0 1C        BEQ $7D1E
C1/7D02: 7B           TDC 
C1/7D03: AA           TAX 
C1/7D04: A8           TAY 
C1/7D05: B9 CC F9     LDA $F9CC,Y
C1/7D08: 9D 37 A9     STA $A937,X
C1/7D0B: 9D B7 A9     STA $A9B7,X
C1/7D0E: C8           INY 
C1/7D0F: 98           TYA 
C1/7D10: 29 0F        AND #$0F
C1/7D12: A8           TAY 
C1/7D13: E8           INX 
C1/7D14: E8           INX 
C1/7D15: E8           INX 
C1/7D16: E8           INX 
C1/7D17: E0 80 00     CPX #$0080
C1/7D1A: D0 E9        BNE $7D05
C1/7D1C: 80 2C        BRA $7D4A
C1/7D1E: AD 0C D1     LDA $D10C
C1/7D21: 18           CLC 
C1/7D22: 65 92        ADC $92
C1/7D24: 8D 0C D1     STA $D10C
C1/7D27: AD 0A D1     LDA $D10A
C1/7D2A: 29 02        AND #$02
C1/7D2C: F0 1C        BEQ $7D4A
C1/7D2E: 7B           TDC 
C1/7D2F: AA           TAX 
C1/7D30: A8           TAY 
C1/7D31: AD C5 F8     LDA $F8C5
C1/7D34: D0 14        BNE $7D4A
C1/7D36: B9 CC F9     LDA $F9CC,Y
C1/7D39: 9D B7 AC     STA $ACB7,X
C1/7D3C: C8           INY 
C1/7D3D: 98           TYA 
C1/7D3E: 29 0F        AND #$0F
C1/7D40: A8           TAY 
C1/7D41: E8           INX 
C1/7D42: E8           INX 
C1/7D43: E8           INX 
C1/7D44: E8           INX 
C1/7D45: E0 80 00     CPX #$0080
C1/7D48: D0 EC        BNE $7D36
C1/7D4A: EE 0B D1     INC $D10B
C1/7D4D: 60           RTS 

C1/7D4E: 02 06 0E 1E

C1/7D52: 9C 04 D1     STZ $D104
C1/7D55: 9C 11 D1     STZ $D111
C1/7D58: 9C 12 D1     STZ $D112
C1/7D5B: 9C 13 D1     STZ $D113
C1/7D5E: 60           RTS 
C1/7D5F: AD 02 D1     LDA $D102
C1/7D62: 29 07        AND #$07
C1/7D64: 0A           ASL 
C1/7D65: AA           TAX 
C1/7D66: BF 7C 7D C1  LDA $C17D7C,X
C1/7D6A: 85 88        STA $88
C1/7D6C: BF 7D 7D C1  LDA $C17D7D,X
C1/7D70: 85 89        STA $89
C1/7D72: 20 79 7D     JSR $7D79
C1/7D75: EE 04 D1     INC $D104
C1/7D78: 60           RTS 
C1/7D79: 6C 88 00     JMP ($0088)
C1/7D7C: 8C 7D B0     STY $B07D
C1/7D7F: 7D 1F 7E     ADC $7E1F,X
C1/7D82: 48           PHA 
C1/7D83: 7E 6B 7E     ROR $7E6B,X
C1/7D86: 1B           TCS 
C1/7D87: 7E 44 7E     ROR $7E44,X
C1/7D8A: 8B           PHB 
C1/7D8B: 7E A9 E0     ROR $E0A9,X
C1/7D8E: 8D 88 BC     STA $BC88
C1/7D91: 8D 89 BC     STA $BC89
C1/7D94: 8D 8A BC     STA $BC8A
C1/7D97: 9C 02 D1     STZ $D102
C1/7D9A: 9C 03 D1     STZ $D103
C1/7D9D: 9C 04 D1     STZ $D104
C1/7DA0: 9C F0 D0     STZ $D0F0
C1/7DA3: 9C 85 BC     STZ $BC85
C1/7DA6: 60           RTS 
C1/7DA7: AD 02 D1     LDA $D102
C1/7DAA: 30 03        BMI $7DAF
C1/7DAC: 9C 02 D1     STZ $D102
C1/7DAF: 60           RTS 
C1/7DB0: A9 42        LDA #$42
C1/7DB2: 8D 85 BC     STA $BC85
C1/7DB5: AD 02 D1     LDA $D102
C1/7DB8: 29 08        AND #$08
C1/7DBA: D0 04        BNE $7DC0
C1/7DBC: A9 04        LDA #$04
C1/7DBE: 80 02        BRA $7DC2
C1/7DC0: A9 02        LDA #$02
C1/7DC2: 85 88        STA $88
C1/7DC4: AD 04 D1     LDA $D104
C1/7DC7: 25 88        AND $88
C1/7DC9: F0 0E        BEQ $7DD9
C1/7DCB: A9 E0        LDA #$E0
C1/7DCD: 8D 88 BC     STA $BC88
C1/7DD0: 8D 89 BC     STA $BC89
C1/7DD3: 8D 8A BC     STA $BC8A
C1/7DD6: 4C A7 7D     JMP $7DA7
C1/7DD9: A9 1F        LDA #$1F
C1/7DDB: 8D 11 D1     STA $D111
C1/7DDE: 8D 12 D1     STA $D112
C1/7DE1: 8D 13 D1     STA $D113
C1/7DE4: 4C E7 7D     JMP $7DE7
C1/7DE7: 9C 88 BC     STZ $BC88
C1/7DEA: 9C 89 BC     STZ $BC89
C1/7DED: 9C 8A BC     STZ $BC8A
C1/7DF0: AD 02 D1     LDA $D102
C1/7DF3: 29 40        AND #$40
C1/7DF5: F0 07        BEQ $7DFE
C1/7DF7: 0A           ASL 
C1/7DF8: 0D 13 D1     ORA $D113
C1/7DFB: 8D 88 BC     STA $BC88
C1/7DFE: AD 02 D1     LDA $D102
C1/7E01: 29 20        AND #$20
C1/7E03: F0 07        BEQ $7E0C
C1/7E05: 0A           ASL 
C1/7E06: 0D 12 D1     ORA $D112
C1/7E09: 8D 89 BC     STA $BC89
C1/7E0C: AD 02 D1     LDA $D102
C1/7E0F: 29 10        AND #$10
C1/7E11: F0 07        BEQ $7E1A
C1/7E13: 0A           ASL 
C1/7E14: 0D 11 D1     ORA $D111
C1/7E17: 8D 8A BC     STA $BC8A
C1/7E1A: 60           RTS 
C1/7E1B: A9 82        LDA #$82
C1/7E1D: 80 02        BRA $7E21
C1/7E1F: A9 02        LDA #$02
C1/7E21: 8D 85 BC     STA $BC85
C1/7E24: 20 E5 7E     JSR $7EE5
C1/7E27: 46 88        LSR $88
C1/7E29: AD 04 D1     LDA $D104
C1/7E2C: 25 88        AND $88
C1/7E2E: D0 13        BNE $7E43
C1/7E30: AD 11 D1     LDA $D111
C1/7E33: C9 1F        CMP #$1F
C1/7E35: F0 0C        BEQ $7E43
C1/7E37: EE 11 D1     INC $D111
C1/7E3A: EE 12 D1     INC $D112
C1/7E3D: EE 13 D1     INC $D113
C1/7E40: 20 E7 7D     JSR $7DE7
C1/7E43: 60           RTS 
C1/7E44: A9 82        LDA #$82
C1/7E46: 80 02        BRA $7E4A
C1/7E48: A9 02        LDA #$02
C1/7E4A: 8D 85 BC     STA $BC85
C1/7E4D: 20 E5 7E     JSR $7EE5
C1/7E50: 46 88        LSR $88
C1/7E52: AD 04 D1     LDA $D104
C1/7E55: 25 88        AND $88
C1/7E57: D0 11        BNE $7E6A
C1/7E59: AD 11 D1     LDA $D111
C1/7E5C: F0 0C        BEQ $7E6A
C1/7E5E: CE 11 D1     DEC $D111
C1/7E61: CE 12 D1     DEC $D112
C1/7E64: CE 13 D1     DEC $D113
C1/7E67: 20 E7 7D     JSR $7DE7
C1/7E6A: 60           RTS 
C1/7E6B: AD 03 D1     LDA $D103
C1/7E6E: F0 0A        BEQ $7E7A
C1/7E70: AD 11 D1     LDA $D111
C1/7E73: C9 1F        CMP #$1F
C1/7E75: F0 0B        BEQ $7E82
C1/7E77: 4C 1F 7E     JMP $7E1F
C1/7E7A: AD 11 D1     LDA $D111
C1/7E7D: F0 03        BEQ $7E82
C1/7E7F: 4C 48 7E     JMP $7E48
C1/7E82: AD 03 D1     LDA $D103
C1/7E85: 49 01        EOR #$01
C1/7E87: 8D 03 D1     STA $D103
C1/7E8A: 60           RTS 
C1/7E8B: AD 03 D1     LDA $D103
C1/7E8E: F0 0A        BEQ $7E9A
C1/7E90: AD 11 D1     LDA $D111
C1/7E93: C9 1F        CMP #$1F
C1/7E95: F0 0B        BEQ $7EA2
C1/7E97: 4C 1B 7E     JMP $7E1B
C1/7E9A: AD 11 D1     LDA $D111
C1/7E9D: F0 03        BEQ $7EA2
C1/7E9F: 4C 44 7E     JMP $7E44
C1/7EA2: AD 03 D1     LDA $D103
C1/7EA5: 49 01        EOR #$01
C1/7EA7: 8D 03 D1     STA $D103
C1/7EAA: 60           RTS 
C1/7EAB: 9C 01 D1     STZ $D101
C1/7EAE: A9 20        LDA #$20
C1/7EB0: 8D FF D0     STA $D0FF
C1/7EB3: 60           RTS 
C1/7EB4: AD FE D0     LDA $D0FE
C1/7EB7: 29 07        AND #$07
C1/7EB9: 0A           ASL 
C1/7EBA: AA           TAX 
C1/7EBB: BF D2 7E C1  LDA $C17ED2,X
C1/7EBF: 85 88        STA $88
C1/7EC1: BF D3 7E C1  LDA $C17ED3,X
C1/7EC5: 85 89        STA $89
C1/7EC7: 20 CE 7E     JSR $7ECE
C1/7ECA: EE 01 D1     INC $D101
C1/7ECD: 60           RTS 
C1/7ECE: 6C 88 00     JMP ($0088)
C1/7ED1: 60           RTS 
C1/7ED2: E2 7E        SEP #$7E
C1/7ED4: 43 7F        EOR $7F,S
C1/7ED6: F5 7E        SBC $7E,X
C1/7ED8: 9A           TXS 
C1/7ED9: 7F C7 7F 70  ADC $707FC7,X
C1/7EDD: 7F D1 7E D1  ADC $D17ED1,X
C1/7EE1: 7E 4C 34     ROR $344C,X
C1/7EE4: 7F AD FE D0  ADC $D0FEAD,X
C1/7EE8: 29 08        AND #$08
C1/7EEA: F0 04        BEQ $7EF0
C1/7EEC: A9 01        LDA #$01
C1/7EEE: 80 02        BRA $7EF2
C1/7EF0: A9 03        LDA #$03
C1/7EF2: 85 88        STA $88
C1/7EF4: 60           RTS 
C1/7EF5: 20 E5 7E     JSR $7EE5
C1/7EF8: AD 01 D1     LDA $D101
C1/7EFB: 25 88        AND $88
C1/7EFD: D0 2B        BNE $7F2A
C1/7EFF: C2 20        REP #$20
C1/7F01: AD 2B 7E     LDA $7E2B
C1/7F04: 48           PHA 
C1/7F05: AD 4B 7E     LDA $7E4B
C1/7F08: 48           PHA 
C1/7F09: A2 02        LDX #$02
C1/7F0B: 00 BD        BRK $BD
C1/7F0D: 2B           PLD 
C1/7F0E: 7E 9D 29     ROR $299D,X
C1/7F11: 7E BD 4B     ROR $4BBD,X
C1/7F14: 7E 9D 49     ROR $499D,X
C1/7F17: 7E E8 E8     ROR $E8E8,X
C1/7F1A: E0 1E        CPX #$1E
C1/7F1C: 00 D0        BRK $D0
C1/7F1E: ED 68 8D     SBC $8D68
C1/7F21: 67 7E        ADC [$7E]
C1/7F23: 68           PLA 
C1/7F24: 8D 47 7E     STA $7E47
C1/7F27: 7B           TDC 
C1/7F28: E2 20        SEP #$20
C1/7F2A: 60           RTS 
C1/7F2B: AD FE D0     LDA $D0FE
C1/7F2E: 30 03        BMI $7F33
C1/7F30: 9C FE D0     STZ $D0FE
C1/7F33: 60           RTS 
C1/7F34: 7B           TDC 
C1/7F35: AA           TAX 
C1/7F36: BD 40 F5     LDA $F540,X
C1/7F39: 9D 29 7E     STA $7E29,X
C1/7F3C: E8           INX 
C1/7F3D: E0 40        CPX #$40
C1/7F3F: 00 D0        BRK $D0
C1/7F41: F4 60 AD     PEA $AD60
C1/7F44: FE D0 29     INC $29D0,X
C1/7F47: 08           PHP 
C1/7F48: D0 04        BNE $7F4E
C1/7F4A: A9 04        LDA #$04
C1/7F4C: 80 02        BRA $7F50
C1/7F4E: A9 02        LDA #$02
C1/7F50: 85 88        STA $88
C1/7F52: 7B           TDC 
C1/7F53: AA           TAX 
C1/7F54: AD 01 D1     LDA $D101
C1/7F57: 25 88        AND $88
C1/7F59: F0 06        BEQ $7F61
C1/7F5B: 20 34 7F     JSR $7F34
C1/7F5E: 4C 2B 7F     JMP $7F2B
C1/7F61: A2 02        LDX #$02
C1/7F63: 00 A9        BRK $A9
C1/7F65: FF 9D 29 7E  SBC $7E299D,X
C1/7F69: E8           INX 
C1/7F6A: E0 40        CPX #$40
C1/7F6C: 00 D0        BRK $D0
C1/7F6E: F7 60        SBC [$60],Y
C1/7F70: AD FF D0     LDA $D0FF
C1/7F73: C9 1A        CMP #$1A
C1/7F75: D0 0D        BNE $7F84
C1/7F77: AD 00 D1     LDA $D100
C1/7F7A: 49 01        EOR #$01
C1/7F7C: 8D 00 D1     STA $D100
C1/7F7F: A9 06        LDA #$06
C1/7F81: 8D FF D0     STA $D0FF
C1/7F84: AD 00 D1     LDA $D100
C1/7F87: F0 08        BEQ $7F91
C1/7F89: AD B4 F8     LDA $F8B4
C1/7F8C: D0 0B        BNE $7F99
C1/7F8E: 4C 9A 7F     JMP $7F9A
C1/7F91: 20 C7 7F     JSR $7FC7
C1/7F94: A9 01        LDA #$01
C1/7F96: 8D B4 F8     STA $F8B4
C1/7F99: 60           RTS 
C1/7F9A: 20 E5 7E     JSR $7EE5
C1/7F9D: AD 01 D1     LDA $D101
C1/7FA0: 25 88        AND $88
C1/7FA2: D0 22        BNE $7FC6
C1/7FA4: AD FF D0     LDA $D0FF
C1/7FA7: F0 1D        BEQ $7FC6
C1/7FA9: AA           TAX 
C1/7FAA: 86 98        STX $98
C1/7FAC: 7B           TDC 
C1/7FAD: A8           TAY 
C1/7FAE: C2 20        REP #$20
C1/7FB0: B9 40 F5     LDA $F540,Y
C1/7FB3: 20 FE 7F     JSR $7FFE
C1/7FB6: 99 29 7E     STA $7E29,Y
C1/7FB9: C8           INY 
C1/7FBA: C8           INY 
C1/7FBB: C0 40 00     CPY #$0040
C1/7FBE: D0 F0        BNE $7FB0
C1/7FC0: 7B           TDC 
C1/7FC1: E2 20        SEP #$20
C1/7FC3: CE FF D0     DEC $D0FF
C1/7FC6: 60           RTS 
C1/7FC7: 20 E5 7E     JSR $7EE5
C1/7FCA: AD 01 D1     LDA $D101
C1/7FCD: 25 88        AND $88
C1/7FCF: D0 2C        BNE $7FFD
C1/7FD1: AD FF D0     LDA $D0FF
C1/7FD4: C9 1A        CMP #$1A
C1/7FD6: F0 25        BEQ $7FFD
C1/7FD8: AA           TAX 
C1/7FD9: 86 98        STX $98
C1/7FDB: 7B           TDC 
C1/7FDC: A8           TAY 
C1/7FDD: C2 20        REP #$20
C1/7FDF: A9 20 00     LDA #$0020
C1/7FE2: 38           SEC 
C1/7FE3: E5 98        SBC $98
C1/7FE5: 85 98        STA $98
C1/7FE7: B9 40 F5     LDA $F540,Y
C1/7FEA: 20 FE 7F     JSR $7FFE
C1/7FED: 99 29 7E     STA $7E29,Y
C1/7FF0: C8           INY 
C1/7FF1: C8           INY 
C1/7FF2: C0 40 00     CPY #$0040
C1/7FF5: D0 F0        BNE $7FE7
C1/7FF7: 7B           TDC 
C1/7FF8: E2 20        SEP #$20
C1/7FFA: CE FF D0     DEC $D0FF
C1/7FFD: 60           RTS 
C1/7FFE: 85 88        STA $88
C1/8000: A5 98        LDA $98
C1/8002: 0A           ASL 
C1/8003: 0A           ASL 
C1/8004: 0A           ASL 
C1/8005: 0A           ASL 
C1/8006: 0A           ASL 
C1/8007: 85 9A        STA $9A
C1/8009: 0A           ASL 
C1/800A: 0A           ASL 
C1/800B: 0A           ASL 
C1/800C: 0A           ASL 
C1/800D: 0A           ASL 
C1/800E: 85 9C        STA $9C
C1/8010: A5 88        LDA $88
C1/8012: 29 1F        AND #$1F
C1/8014: 00 F0        BRK $F0
C1/8016: 14 C5        TRB $C5
C1/8018: 98           TYA 
C1/8019: 90 09        BCC $8024
C1/801B: A5 88        LDA $88
C1/801D: 38           SEC 
C1/801E: E5 98        SBC $98
C1/8020: 85 88        STA $88
C1/8022: 80 07        BRA $802B
C1/8024: A5 88        LDA $88
C1/8026: 29 E0        AND #$E0
C1/8028: 7F 85 88 A5  ADC $A58885,X
C1/802C: 88           DEY 
C1/802D: 29 E0        AND #$E0
C1/802F: 03 F0        ORA $F0,S
C1/8031: 14 C5        TRB $C5
C1/8033: 9A           TXS 
C1/8034: 90 09        BCC $803F
C1/8036: A5 88        LDA $88
C1/8038: 38           SEC 
C1/8039: E5 9A        SBC $9A
C1/803B: 85 88        STA $88
C1/803D: 80 07        BRA $8046
C1/803F: A5 88        LDA $88
C1/8041: 29 1F        AND #$1F
C1/8043: 7C 85 88     JMP ($8885,X)
C1/8046: A5 88        LDA $88
C1/8048: 29 00        AND #$00
C1/804A: 7C F0 12     JMP ($12F0,X)
C1/804D: C5 9C        CMP $9C
C1/804F: 90 07        BCC $8058
C1/8051: A5 88        LDA $88
C1/8053: 38           SEC 
C1/8054: E5 9C        SBC $9C
C1/8056: 80 07        BRA $805F
C1/8058: A5 88        LDA $88
C1/805A: 29 FF        AND #$FF
C1/805C: 03 85        ORA $85,S
C1/805E: 88           DEY 
C1/805F: A5 88        LDA $88
C1/8061: 60           RTS 

; [ move character back after attack ??? ]

C1/8062: AD CD 3B     LDA $3BCD
C1/8065: 29 03        AND #$03
C1/8067: 48           PHA 
C1/8068: 0A           ASL 
C1/8069: 0A           ASL 
C1/806A: 0A           ASL 
C1/806B: 0A           ASL 
C1/806C: 0A           ASL 
C1/806D: AA           TAX 
C1/806E: 20 03 81     JSR $8103
C1/8071: 68           PLA 
C1/8072: 48           PHA 
C1/8073: AA           TAX 
C1/8074: A9 80        LDA #$80
C1/8076: 85 72        STA $72
C1/8078: BD BD D1     LDA $D1BD,X
C1/807B: F0 06        BEQ $8083
C1/807D: 64 72        STZ $72
C1/807F: A9 10        LDA #$10
C1/8081: 80 0B        BRA $808E
C1/8083: BD 4A DB     LDA $DB4A,X
C1/8086: F0 04        BEQ $808C
C1/8088: A9 20        LDA #$20
C1/808A: 80 02        BRA $808E
C1/808C: A9 10        LDA #$10
C1/808E: 85 70        STA $70
C1/8090: 68           PLA 
C1/8091: 0A           ASL 
C1/8092: 0A           ASL 
C1/8093: 0A           ASL 
C1/8094: 0A           ASL 
C1/8095: 0A           ASL 
C1/8096: AA           TAX 
C1/8097: A5 70        LDA $70
C1/8099: 05 72        ORA $72
C1/809B: 9D 54 CF     STA $CF54,X
C1/809E: A9 02        LDA #$02
C1/80A0: 9D 4D CF     STA $CF4D,X
C1/80A3: A9 01        LDA #$01
C1/80A5: 9D 53 CF     STA $CF53,X
C1/80A8: 9E 55 CF     STZ $CF55,X
C1/80AB: 20 03 81     JSR $8103
C1/80AE: AD CD 3B     LDA $3BCD
C1/80B1: 29 03        AND #$03
C1/80B3: AA           TAX 
C1/80B4: 9E CB D1     STZ $D1CB,X
C1/80B7: 60           RTS 

; [ move character forward to attack ]

C1/80B8: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/80BB: 29 03        AND #$03
C1/80BD: 48           PHA 
C1/80BE: 0A           ASL 
C1/80BF: 0A           ASL 
C1/80C0: 0A           ASL 
C1/80C1: 0A           ASL 
C1/80C2: 0A           ASL 
C1/80C3: AA           TAX 
C1/80C4: 20 03 81     JSR $8103
C1/80C7: 68           PLA 
C1/80C8: 48           PHA 
C1/80C9: AA           TAX 
C1/80CA: 64 72        STZ $72
C1/80CC: A9 01        LDA #$01
C1/80CE: 9D CB D1     STA $D1CB,X
C1/80D1: BD BD D1     LDA $D1BD,X
C1/80D4: F0 08        BEQ $80DE
C1/80D6: A9 80        LDA #$80        ; move left
C1/80D8: 85 72        STA $72
C1/80DA: A9 10        LDA #$10
C1/80DC: 80 0B        BRA $80E9
C1/80DE: BD 4A DB     LDA $DB4A,X     ; character row
C1/80E1: F0 04        BEQ $80E7
C1/80E3: A9 20        LDA #$20        ; move forward 32 pixels if in back row
C1/80E5: 80 02        BRA $80E9
C1/80E7: A9 10        LDA #$10        ; move forward 16 pixels if in front row
C1/80E9: 85 70        STA $70
C1/80EB: 68           PLA 
C1/80EC: 0A           ASL 
C1/80ED: 0A           ASL 
C1/80EE: 0A           ASL 
C1/80EF: 0A           ASL 
C1/80F0: 0A           ASL 
C1/80F1: AA           TAX 
C1/80F2: A5 70        LDA $70
C1/80F4: 05 72        ORA $72
C1/80F6: 9D 54 CF     STA $CF54,X     ; set movement counter
C1/80F9: A9 02        LDA #$02        ; walking animation
C1/80FB: 9D 4D CF     STA $CF4D,X
C1/80FE: A9 01        LDA #$01
C1/8100: 9D 53 CF     STA $CF53,X
; fallthrough

; [ wait for character to move forward ]

C1/8103: DA           PHX 
C1/8104: 20 F2 02     JSR $02F2       ; wait one frame
C1/8107: FA           PLX 
C1/8108: BD 53 CF     LDA $CF53,X
C1/810B: D0 F6        BNE $8103
C1/810D: 60           RTS 

; [ flash active monster ]

C1/810E: 7B           TDC 
C1/810F: AA           TAX 
C1/8110: 9D 69 7E     STA $7E69,X
C1/8113: E8           INX 
C1/8114: E0 20 00     CPX #$0020
C1/8117: D0 F7        BNE $8110
C1/8119: A2 FF FF     LDX #$FFFF
C1/811C: 8E 6B 7E     STX $7E6B
C1/811F: 20 25 81     JSR $8125       ; flash monster (twice)
C1/8122: 4C 25 81     JMP $8125

; [ flash monster ]

C1/8125: AD E4 DB     LDA $DBE4
C1/8128: F0 04        BEQ $812E
C1/812A: A9 C0        LDA #$C0
C1/812C: 80 06        BRA $8134
C1/812E: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/8131: 20 74 FC     JSR $FC74       ; get monster mask
C1/8134: 20 B1 1C     JSR $1CB1       ; load black and white monster palette
C1/8137: A9 03        LDA #$03
C1/8139: 20 41 81     JSR $8141       ; wait
C1/813C: 20 B8 1C     JSR $1CB8
C1/813F: A9 03        LDA #$03
; fallthrough

; [ wait ]

; a = number of frames to wait

C1/8141: 48           PHA 
C1/8142: 20 F2 02     JSR $02F2       ; wait one frame
C1/8145: 68           PLA 
C1/8146: 3A           DEC 
C1/8147: D0 F8        BNE $8141
C1/8149: 60           RTS 

; [  ]

C1/814A: B2 EB        LDA ($EB)
C1/814C: 30 21        BMI $816F
C1/814E: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/8151: 29 03        AND #$03
C1/8153: 0A           ASL 
C1/8154: 0A           ASL 
C1/8155: 0A           ASL 
C1/8156: 0A           ASL 
C1/8157: 0A           ASL 
C1/8158: AA           TAX 
C1/8159: 9E 58 CF     STZ $CF58,X
C1/815C: BD 56 CF     LDA $CF56,X
C1/815F: 29 FE        AND #$FE
C1/8161: 9D 56 CF     STA $CF56,X
C1/8164: B2 EB        LDA ($EB)
C1/8166: 29 20        AND #$20
C1/8168: D0 0E        BNE $8178
C1/816A: 20 B8 80     JSR $80B8       ; move character forward to attack
C1/816D: 80 09        BRA $8178
C1/816F: B2 EB        LDA ($EB)
C1/8171: 29 20        AND #$20
C1/8173: D0 03        BNE $8178
C1/8175: 20 0E 81     JSR $810E       ; flash active monster
C1/8178: 60           RTS 

; [  ]

C1/8179: AD CC 3B     LDA $3BCC
C1/817C: 29 20        AND #$20
C1/817E: D0 08        BNE $8188
C1/8180: AD CC 3B     LDA $3BCC
C1/8183: 30 03        BMI $8188
C1/8185: 20 62 80     JSR $8062
C1/8188: 60           RTS 

; [ battle graphics function $0A: execute graphics script ]

; $F2: show monster
; $F6: show battle dialogue
; $F8: do misc effect
; $FC: do graphics commands

C1/8189: A2 CC 3B     LDX #$3BCC      ; pointer to attack parameters
C1/818C: 86 EB        STX $EB
C1/818E: A2 4C 3A     LDX #$3A4C      ; pointer to damage values
C1/8191: 86 E9        STX $E9
C1/8193: A2 4C 38     LDX #$384C      ; pointer to graphics commands
C1/8196: 86 E7        STX $E7
C1/8198: A2 49 7B     LDX #$7B49      ; 
C1/819B: 86 ED        STX $ED
C1/819D: A2 3C 3C     LDX #$3C3C      ; pointer to block type
C1/81A0: 86 F0        STX $F0
C1/81A2: A2 BF 3C     LDX #$3CBF      ; pointer to message variables
C1/81A5: 86 F4        STX $F4
C1/81A7: A2 5F 3C     LDX #$3C5F      ; pointer to message ids
C1/81AA: 86 F2        STX $F2
C1/81AC: 9C 76 DB     STZ $DB76
C1/81AF: 20 4A 81     JSR $814A
C1/81B2: B2 E7        LDA ($E7)       ; script command
C1/81B4: C9 FF        CMP #$FF
C1/81B6: F0 54        BEQ $820C       ; branch if terminator
C1/81B8: 20 59 8D     JSR $8D59       ; get graphics script parameter 1
C1/81BB: C9 F2        CMP #$F2        ; opcodes less than $F2 have no effect
C1/81BD: 90 3A        BCC $81F9
C1/81BF: 38           SEC 
C1/81C0: E9 F2        SBC #$F2
C1/81C2: 0A           ASL 
C1/81C3: AA           TAX 
C1/81C4: BF 18 82 C1  LDA $C18218,X
C1/81C8: 85 70        STA $70
C1/81CA: BF 19 82 C1  LDA $C18219,X
C1/81CE: 85 71        STA $71
C1/81D0: 20 09 82     JSR $8209
C1/81D3: 20 59 8D     JSR $8D59       ; get graphics script parameter 1
C1/81D6: C9 FC        CMP #$FC
C1/81D8: D0 1F        BNE $81F9       ; branch if not a graphics command
C1/81DA: C8           INY 
C1/81DB: B1 E7        LDA ($E7),Y
C1/81DD: C9 03        CMP #$03
C1/81DF: 90 04        BCC $81E5
C1/81E1: C9 07        CMP #$07
C1/81E3: D0 14        BNE $81F9
C1/81E5: C2 20        REP #$20
C1/81E7: A5 EB        LDA $EB
C1/81E9: 18           CLC 
C1/81EA: 69 07 00     ADC #$0007
C1/81ED: 85 EB        STA $EB
C1/81EF: 7B           TDC 
C1/81F0: E2 20        SEP #$20
C1/81F2: A5 ED        LDA $ED
C1/81F4: 18           CLC 
C1/81F5: 69 08        ADC #$08
C1/81F7: 85 ED        STA $ED
C1/81F9: C2 20        REP #$20
C1/81FB: A5 E7        LDA $E7
C1/81FD: 18           CLC 
C1/81FE: 69 05 00     ADC #$0005
C1/8201: 85 E7        STA $E7
C1/8203: 7B           TDC 
C1/8204: E2 20        SEP #$20
C1/8206: 4C B2 81     JMP $81B2
C1/8209: 6C 70 00     JMP ($0070)
C1/820C: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/820F: 20 79 81     JSR $8179
C1/8212: 20 BB 3C     JSR $3CBB
C1/8215: 4C 3C 9D     JMP $9D3C

; jump table for graphics script parameter 1 ($F2-$FF)
C1/8218:              .DW               $8B46, $82A4, $82A4, $82A4, $8CBD, $82A4
C1/8224:              .DW $8234, $82A4, $82A4, $82A4, $8B69, $82A4, $82A4, $82A4

; [ graphics script command $F8: execute misc effect ]

C1/8234: 20 4D 8D     JSR $8D4D       ; get graphics script parameter 2
C1/8237: 0A           ASL 
C1/8238: AA           TAX 
C1/8239: BF 48 82 C1  LDA $C18248,X
C1/823D: 85 70        STA $70
C1/823F: BF 49 82 C1  LDA $C18249,X
C1/8243: 85 71        STA $71
C1/8245: 6C 70 00     JMP ($0070)

; misc effect jump table
C1/8248:              .DW $833D, $8332, $830E, $78F5, $82AB, $8317, $8329, $82A5
C1/8258:              .DW $8320, $825E, $8281

; [ misc effect $09:  ]

C1/825E: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8261: 10 10        BPL $8273
C1/8263: 29 07        AND #$07
C1/8265: AA           TAX 
C1/8266: BF 25 7D D9  LDA $D97D25,X
C1/826A: 49 FF        EOR #$FF
C1/826C: 2D 2C FF     AND $FF2C
C1/826F: 8D 2C FF     STA $FF2C
C1/8272: 60           RTS 
C1/8273: 29 07        AND #$07
C1/8275: AA           TAX 
C1/8276: BF 25 7D D9  LDA $D97D25,X
C1/827A: 0D 2C FF     ORA $FF2C
C1/827D: 8D 2C FF     STA $FF2C
C1/8280: 60           RTS 

; [ misc effect $0A:  ]

C1/8281: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8284: 10 10        BPL $8296
C1/8286: 29 07        AND #$07
C1/8288: AA           TAX 
C1/8289: BF 25 7D D9  LDA $D97D25,X
C1/828D: 49 FF        EOR #$FF
C1/828F: 2D 2D FF     AND $FF2D
C1/8292: 8D 2D FF     STA $FF2D
C1/8295: 60           RTS 
C1/8296: 29 07        AND #$07
C1/8298: AA           TAX 
C1/8299: BF 25 7D D9  LDA $D97D25,X
C1/829D: 0D 2D FF     ORA $FF2D
C1/82A0: 8D 2D FF     STA $FF2D
C1/82A3: 60           RTS 

; [ unused graphics script commands ]

C1/82A4: 60           RTS 

; [ misc effect $07: wait ]

C1/82A5: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/82A8: 4C 41 81     JMP $8141       ; wait

; [ misc effect $04:  ]

C1/82AB: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/82AE: 85 7E        STA $7E
C1/82B0: 29 03        AND #$03
C1/82B2: 8D 80 BC     STA $BC80
C1/82B5: A5 7E        LDA $7E
C1/82B7: 29 3C        AND #$3C
C1/82B9: 0A           ASL 
C1/82BA: 0A           ASL 
C1/82BB: 8D 29 FF     STA $FF29
C1/82BE: A5 7E        LDA $7E
C1/82C0: 29 40        AND #$40
C1/82C2: 8D 2A FF     STA $FF2A
C1/82C5: 60           RTS 

C1/82C6: AD 2A FF     LDA $FF2A
C1/82C9: F0 06        BEQ $82D1
C1/82CB: 20 F2 02     JSR $02F2       ; wait one frame
C1/82CE: 20 F2 02     JSR $02F2       ; wait one frame
C1/82D1: 20 F2 02     JSR $02F2       ; wait one frame
C1/82D4: 20 F2 02     JSR $02F2       ; wait one frame
C1/82D7: AD 80 BC     LDA $BC80
C1/82DA: CD 29 FF     CMP $FF29
C1/82DD: F0 0B        BEQ $82EA
C1/82DF: AD 80 BC     LDA $BC80
C1/82E2: 18           CLC 
C1/82E3: 69 10        ADC #$10
C1/82E5: 8D 80 BC     STA $BC80
C1/82E8: 80 DC        BRA $82C6
C1/82EA: AD 2A FF     LDA $FF2A
C1/82ED: F0 06        BEQ $82F5
C1/82EF: 20 F2 02     JSR $02F2       ; wait one frame
C1/82F2: 20 F2 02     JSR $02F2       ; wait one frame
C1/82F5: 20 F2 02     JSR $02F2       ; wait one frame
C1/82F8: 20 F2 02     JSR $02F2       ; wait one frame
C1/82FB: AD 80 BC     LDA $BC80
C1/82FE: 29 F0        AND #$F0
C1/8300: F0 0B        BEQ $830D
C1/8302: AD 80 BC     LDA $BC80
C1/8305: 38           SEC 
C1/8306: E9 10        SBC #$10
C1/8308: 8D 80 BC     STA $BC80
C1/830B: 80 DD        BRA $82EA
C1/830D: 60           RTS 

; [ misc effect $02: shake screen ]

C1/830E: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8311: 85 7E        STA $7E
C1/8313: 7B           TDC 
C1/8314: 4C 93 7A     JMP $7A93

; [ misc effect $05:  ]

C1/8317: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/831A: 85 7E        STA $7E
C1/831C: 7B           TDC 
C1/831D: 4C 43 7B     JMP $7B43

; [ misc effect $08:  ]

C1/8320: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8323: 85 7E        STA $7E
C1/8325: 7B           TDC 
C1/8326: 4C 02 7B     JMP $7B02

; [ misc effect $06:  ]

C1/8329: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/832C: 85 7E        STA $7E
C1/832E: 7B           TDC 
C1/832F: 4C 2A 7A     JMP $7A2A

; [ misc effect $01: play sound effect ]

C1/8332: A9 88        LDA #$88
C1/8334: 8D B6 DB     STA $DBB6
C1/8337: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/833A: 4C D9 FB     JMP $FBD9       ; play sound effect

; [ misc effect $00: play song ]

C1/833D: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8340: 8D 04 FF     STA $FF04
C1/8343: 60           RTS 

; [  ]

C1/8344: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8347: 49 FF        EOR #$FF
C1/8349: 85 70        STA $70
C1/834B: A5 DE        LDA $DE
C1/834D: 25 70        AND $70
C1/834F: 85 70        STA $70
C1/8351: 60           RTS 

; [  ]

C1/8352: A5 DE        LDA $DE
C1/8354: 49 FF        EOR #$FF
C1/8356: 85 71        STA $71
C1/8358: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/835B: 25 71        AND $71
C1/835D: 85 70        STA $70
C1/835F: 60           RTS 

; [  ]

C1/8360: A9 5A        LDA #$5A        ; bg1 screen size 32x64
C1/8362: 8F 07 21 00  STA $002107
C1/8366: 60           RTS 

; [  ]

C1/8367: A9 59        LDA #$59        ; bg1 screen size 64x32 (default)
C1/8369: 8F 07 21 00  STA $002107
C1/836D: 60           RTS 

; [  ]

C1/836E: 7B           TDC 
C1/836F: AA           TAX 
C1/8370: C2 20        REP #$20
C1/8372: 9D B7 AC     STA $ACB7,X
C1/8375: E8           INX 
C1/8376: E8           INX 
C1/8377: E8           INX 
C1/8378: E8           INX 
C1/8379: E0 80        CPX #$80
C1/837B: 02 D0        COP $D0
C1/837D: F4 7B E2     PEA $E27B
C1/8380: 20 60 7B     JSR $7B60
C1/8383: AA           TAX 
C1/8384: C2 20        REP #$20
C1/8386: A5 70        LDA $70
C1/8388: 9D 39 A9     STA $A939,X
C1/838B: 9D B9 A9     STA $A9B9,X
C1/838E: E8           INX 
C1/838F: E8           INX 
C1/8390: E8           INX 
C1/8391: E8           INX 
C1/8392: E0 80        CPX #$80
C1/8394: 00 D0        BRK $D0
C1/8396: F1 7B        SBC ($7B),Y
C1/8398: E2 20        SEP #$20
C1/839A: 60           RTS 
C1/839B: 7B           TDC 
C1/839C: AA           TAX 
C1/839D: C2 20        REP #$20
C1/839F: A5 70        LDA $70
C1/83A1: 9D 37 A9     STA $A937,X
C1/83A4: 9D B7 A9     STA $A9B7,X
C1/83A7: E8           INX 
C1/83A8: E8           INX 
C1/83A9: E8           INX 
C1/83AA: E8           INX 
C1/83AB: E0 80        CPX #$80
C1/83AD: 00 D0        BRK $D0
C1/83AF: F1 7B        SBC ($7B),Y
C1/83B1: E2 20        SEP #$20
C1/83B3: 60           RTS 
C1/83B4: 7B           TDC 
C1/83B5: AA           TAX 
C1/83B6: C2 20        REP #$20
C1/83B8: A5 70        LDA $70
C1/83BA: 9D B7 AC     STA $ACB7,X
C1/83BD: E8           INX 
C1/83BE: E8           INX 
C1/83BF: E8           INX 
C1/83C0: E8           INX 
C1/83C1: E0 80        CPX #$80
C1/83C3: 00 D0        BRK $D0
C1/83C5: F4 7B E2     PEA $E27B
C1/83C8: 20 60 A2     JSR $A260
C1/83CB: 15 00        ORA $00,X
C1/83CD: DA           PHX 
C1/83CE: 20 F2 02     JSR $02F2       ; wait one frame
C1/83D1: 20 5C 87     JSR $875C
C1/83D4: C2 20        REP #$20
C1/83D6: AD 79 BC     LDA $BC79
C1/83D9: 38           SEC 
C1/83DA: E9 0C 00     SBC #$000C
C1/83DD: 8D 79 BC     STA $BC79
C1/83E0: 85 70        STA $70
C1/83E2: 7B           TDC 
C1/83E3: E2 20        SEP #$20
C1/83E5: 20 82 83     JSR $8382
C1/83E8: FA           PLX 
C1/83E9: CA           DEX 
C1/83EA: D0 E1        BNE $83CD
C1/83EC: C2 20        REP #$20
C1/83EE: AD 79 BC     LDA $BC79
C1/83F1: 38           SEC 
C1/83F2: E9 04 00     SBC #$0004
C1/83F5: 8D 79 BC     STA $BC79
C1/83F8: 85 70        STA $70
C1/83FA: 7B           TDC 
C1/83FB: E2 20        SEP #$20
C1/83FD: 4C 82 83     JMP $8382
C1/8400: A2 15        LDX #$15
C1/8402: 00 DA        BRK $DA
C1/8404: 20 F2 02     JSR $02F2       ; wait one frame
C1/8407: 20 5C 87     JSR $875C
C1/840A: C2 20        REP #$20
C1/840C: AD 79 BC     LDA $BC79
C1/840F: 18           CLC 
C1/8410: 69 0C 00     ADC #$000C
C1/8413: 8D 79 BC     STA $BC79
C1/8416: 85 70        STA $70
C1/8418: 7B           TDC 
C1/8419: E2 20        SEP #$20
C1/841B: 20 82 83     JSR $8382
C1/841E: FA           PLX 
C1/841F: CA           DEX 
C1/8420: D0 E1        BNE $8403
C1/8422: C2 20        REP #$20
C1/8424: AD 79 BC     LDA $BC79
C1/8427: 18           CLC 
C1/8428: 69 04 00     ADC #$0004
C1/842B: 8D 79 BC     STA $BC79
C1/842E: 85 70        STA $70
C1/8430: 7B           TDC 
C1/8431: E2 20        SEP #$20
C1/8433: 4C 82 83     JMP $8382
C1/8436: A5 F6        LDA $F6
C1/8438: D0 31        BNE $846B
C1/843A: A2 15        LDX #$15
C1/843C: 00 DA        BRK $DA
C1/843E: 20 F2 02     JSR $02F2       ; wait one frame
C1/8441: 20 5C 87     JSR $875C
C1/8444: C2 20        REP #$20
C1/8446: AD 77 BC     LDA $BC77
C1/8449: 38           SEC 
C1/844A: E9 0C 00     SBC #$000C
C1/844D: 8D 77 BC     STA $BC77
C1/8450: 7B           TDC 
C1/8451: E2 20        SEP #$20
C1/8453: FA           PLX 
C1/8454: CA           DEX 
C1/8455: D0 E6        BNE $843D
C1/8457: C2 20        REP #$20
C1/8459: AD 77 BC     LDA $BC77
C1/845C: 38           SEC 
C1/845D: E9 04 00     SBC #$0004
C1/8460: 8D 77 BC     STA $BC77
C1/8463: 7B           TDC 
C1/8464: E2 20        SEP #$20
C1/8466: 60           RTS 
C1/8467: A5 F6        LDA $F6
C1/8469: D0 CF        BNE $843A
C1/846B: A2 15        LDX #$15
C1/846D: 00 DA        BRK $DA
C1/846F: 20 F2 02     JSR $02F2       ; wait one frame
C1/8472: 20 5C 87     JSR $875C
C1/8475: C2 20        REP #$20
C1/8477: AD 77 BC     LDA $BC77
C1/847A: 18           CLC 
C1/847B: 69 0C 00     ADC #$000C
C1/847E: 8D 77 BC     STA $BC77
C1/8481: 7B           TDC 
C1/8482: E2 20        SEP #$20
C1/8484: FA           PLX 
C1/8485: CA           DEX 
C1/8486: D0 E6        BNE $846E
C1/8488: C2 20        REP #$20
C1/848A: AD 77 BC     LDA $BC77
C1/848D: 18           CLC 
C1/848E: 69 04 00     ADC #$0004
C1/8491: 8D 77 BC     STA $BC77
C1/8494: 7B           TDC 
C1/8495: E2 20        SEP #$20
C1/8497: 60           RTS 
C1/8498: C2 20        REP #$20
C1/849A: AD 77 BC     LDA $BC77
C1/849D: 49 00 01     EOR #$0100
C1/84A0: 8D 77 BC     STA $BC77
C1/84A3: 7B           TDC 
C1/84A4: E2 20        SEP #$20
C1/84A6: 60           RTS 

; [ show monster $00: fade in ]

C1/84A7: 20 44 83     JSR $8344
C1/84AA: 7B           TDC 
C1/84AB: 20 02 76     JSR $7602
C1/84AE: 20 52 83     JSR $8352
C1/84B1: 7B           TDC 
C1/84B2: 4C BB 75     JMP $75BB

; [  ]

C1/84B5: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/84B8: 85 70        STA $70
C1/84BA: A5 DE        LDA $DE
C1/84BC: 25 70        AND $70
C1/84BE: 85 DE        STA $DE
C1/84C0: 60           RTS 

; [ show monster $01: iron claw ]

C1/84C1: 20 60 83     JSR $8360
C1/84C4: 20 00 84     JSR $8400
C1/84C7: 20 B5 84     JSR $84B5
C1/84CA: 20 52 83     JSR $8352
C1/84CD: A9 0A        LDA #$0A
C1/84CF: 20 BB 75     JSR $75BB
C1/84D2: 20 CA 83     JSR $83CA
C1/84D5: 4C 67 83     JMP $8367

; [ show monster $0B: merugene 3 ]

C1/84D8: 20 60 83     JSR $8360
C1/84DB: AD 84 BC     LDA $BC84
C1/84DE: 09 01        ORA #$01
C1/84E0: 8D 84 BC     STA $BC84
C1/84E3: 20 00 84     JSR $8400
C1/84E6: 20 B5 84     JSR $84B5
C1/84E9: 20 52 83     JSR $8352
C1/84EC: A9 0A        LDA #$0A
C1/84EE: 20 BB 75     JSR $75BB
C1/84F1: 20 00 84     JSR $8400
C1/84F4: 20 67 83     JSR $8367
C1/84F7: AD 84 BC     LDA $BC84
C1/84FA: 29 FE        AND #$FE
C1/84FC: 8D 84 BC     STA $BC84
C1/84FF: 60           RTS 

; [ show monster $0C: merugene 4 ]

C1/8500: 20 60 83     JSR $8360
C1/8503: AD 84 BC     LDA $BC84
C1/8506: 09 01        ORA #$01
C1/8508: 8D 84 BC     STA $BC84
C1/850B: 20 CA 83     JSR $83CA
C1/850E: 20 B5 84     JSR $84B5
C1/8511: 20 52 83     JSR $8352
C1/8514: A9 0A        LDA #$0A
C1/8516: 20 BB 75     JSR $75BB
C1/8519: 20 CA 83     JSR $83CA
C1/851C: 20 67 83     JSR $8367
C1/851F: AD 84 BC     LDA $BC84
C1/8522: 29 FE        AND #$FE
C1/8524: 8D 84 BC     STA $BC84
C1/8527: 60           RTS 

; [ show monster $02: discreet ??? ]

C1/8528: 20 B5 84     JSR $84B5
C1/852B: 20 52 83     JSR $8352
C1/852E: A9 0A        LDA #$0A
C1/8530: 4C BB 75     JMP $75BB

; [ show monster $03: motor trap ]

C1/8533: 20 44 83     JSR $8344
C1/8536: 7B           TDC 
C1/8537: 20 02 76     JSR $7602
C1/853A: 20 60 83     JSR $8360
C1/853D: 20 00 84     JSR $8400
C1/8540: 20 52 83     JSR $8352
C1/8543: A9 0A        LDA #$0A
C1/8545: 20 BB 75     JSR $75BB
C1/8548: 20 CA 83     JSR $83CA
C1/854B: 4C 67 83     JMP $8367

; [ show monster $06: fade and drop ]

C1/854E: 20 44 83     JSR $8344
C1/8551: A9 02        LDA #$02
C1/8553: 20 02 76     JSR $7602
C1/8556: 20 60 83     JSR $8360
C1/8559: 20 00 84     JSR $8400
C1/855C: 20 52 83     JSR $8352
C1/855F: A9 0A        LDA #$0A
C1/8561: 20 BB 75     JSR $75BB
C1/8564: 20 CA 83     JSR $83CA
C1/8567: 4C 67 83     JMP $8367

; [ show monster $09: merugene 1 ]

C1/856A: 20 67 83     JSR $8367
C1/856D: 20 67 84     JSR $8467
C1/8570: 20 B5 84     JSR $84B5
C1/8573: 20 52 83     JSR $8352
C1/8576: A9 0A        LDA #$0A
C1/8578: 20 BB 75     JSR $75BB
C1/857B: 4C 67 84     JMP $8467

; [ show monster $0A: merugene 2 ]

C1/857E: 20 67 83     JSR $8367
C1/8581: 20 36 84     JSR $8436
C1/8584: 20 B5 84     JSR $84B5
C1/8587: 20 52 83     JSR $8352
C1/858A: A9 0A        LDA #$0A
C1/858C: 20 BB 75     JSR $75BB
C1/858F: 4C 36 84     JMP $8436

; [ show monster $04: switch ??? ]

C1/8592: 20 67 83     JSR $8367
C1/8595: 20 67 84     JSR $8467
C1/8598: 20 B5 84     JSR $84B5
C1/859B: 20 52 83     JSR $8352
C1/859E: A9 0A        LDA #$0A
C1/85A0: 20 BB 75     JSR $75BB
C1/85A3: 4C 36 84     JMP $8436
C1/85A6: AD 84 BC     LDA $BC84
C1/85A9: 29 FE        AND #$FE
C1/85AB: 8D 84 BC     STA $BC84
C1/85AE: 60           RTS 
C1/85AF: AD 84 BC     LDA $BC84
C1/85B2: 09 01        ORA #$01
C1/85B4: 8D 84 BC     STA $BC84
C1/85B7: 60           RTS 

; [ show monster $05: transform ]

C1/85B8: 20 B5 84     JSR $84B5
C1/85BB: 20 39 75     JSR $7539
C1/85BE: 20 29 75     JSR $7529
C1/85C1: 20 52 83     JSR $8352
C1/85C4: A5 70        LDA $70
C1/85C6: 05 DE        ORA $DE
C1/85C8: 85 DE        STA $DE
C1/85CA: 20 8A 1C     JSR $1C8A
C1/85CD: 7B           TDC 
C1/85CE: AA           TAX 
C1/85CF: DA           PHX 
C1/85D0: BF 06 86 C1  LDA $C18606,X
C1/85D4: DA           PHX 
C1/85D5: 20 41 81     JSR $8141       ; wait
C1/85D8: 20 98 84     JSR $8498
C1/85DB: FA           PLX 
C1/85DC: BF 07 86 C1  LDA $C18607,X
C1/85E0: 20 41 81     JSR $8141       ; wait
C1/85E3: 20 98 84     JSR $8498
C1/85E6: FA           PLX 
C1/85E7: E8           INX 
C1/85E8: E8           INX 
C1/85E9: E0 20 00     CPX #$0020
C1/85EC: D0 E1        BNE $85CF
C1/85EE: 20 98 84     JSR $8498
C1/85F1: 20 B5 84     JSR $84B5
C1/85F4: 20 52 83     JSR $8352
C1/85F7: A5 70        LDA $70
C1/85F9: 05 DE        ORA $DE
C1/85FB: 85 DE        STA $DE
C1/85FD: 20 B8 1C     JSR $1CB8
C1/8600: 20 98 84     JSR $8498
C1/8603: 4C 84 1C     JMP $1C84

C1/8606:              .DB $08, $01
C1/8608:              .DB $08, $01
C1/860A:              .DB $05, $01
C1/860C:              .DB $05, $01
C1/860D:              .DB $03, $01
C1/8610:              .DB $03, $01
C1/8612:              .DB $01, $01
C1/8614:              .DB $01, $01
C1/8616:              .DB $01, $01
C1/8618:              .DB $01, $01
C1/861A:              .DB $01, $03
C1/861C:              .DB $01, $03
C1/861E:              .DB $01, $05
C1/8620:              .DB $01, $05
C1/8622:              .DB $01, $08
C1/8624:              .DB $01, $08

; [ show monster $07: pages ]

C1/8626: 20 F2 02     JSR $02F2       ; wait one frame
C1/8629: 20 B8 1C     JSR $1CB8
C1/862C: 64 70        STZ $70
C1/862E: 7B           TDC 
C1/862F: AA           TAX 
C1/8630: BD 06 D0     LDA $D006,X
C1/8633: F0 0A        BEQ $863F
C1/8635: DD 26 D0     CMP $D026,X
C1/8638: F0 05        BEQ $863F
C1/863A: FE 26 D0     INC $D026,X
C1/863D: 80 02        BRA $8641
C1/863F: E6 70        INC $70
C1/8641: E8           INX 
C1/8642: E0 08 00     CPX #$0008
C1/8645: D0 E9        BNE $8630
C1/8647: A5 70        LDA $70
C1/8649: C9 08        CMP #$08
C1/864B: D0 D9        BNE $8626
C1/864D: 20 B5 84     JSR $84B5
C1/8650: 20 39 75     JSR $7539
C1/8653: 20 29 75     JSR $7529
C1/8656: 20 52 83     JSR $8352
C1/8659: A5 70        LDA $70
C1/865B: 05 DE        ORA $DE
C1/865D: 85 DE        STA $DE
C1/865F: 7B           TDC 
C1/8660: AA           TAX 
C1/8661: BD 06 D0     LDA $D006,X
C1/8664: 9D 26 D0     STA $D026,X
C1/8667: E8           INX 
C1/8668: E0 08 00     CPX #$0008
C1/866B: D0 F4        BNE $8661
C1/866D: 20 F2 02     JSR $02F2
C1/8670: 20 B8 1C     JSR $1CB8
C1/8673: 64 70        STZ $70
C1/8675: 7B           TDC 
C1/8676: AA           TAX 
C1/8677: BD 06 D0     LDA $D006,X
C1/867A: F0 0A        BEQ $8686
C1/867C: BD 26 D0     LDA $D026,X
C1/867F: F0 05        BEQ $8686
C1/8681: DE 26 D0     DEC $D026,X
C1/8684: 80 02        BRA $8688
C1/8686: E6 70        INC $70
C1/8688: E8           INX 
C1/8689: E0 08 00     CPX #$0008
C1/868C: D0 E9        BNE $8675
C1/868E: A5 70        LDA $70
C1/8690: C9 08        CMP #$08
C1/8692: D0 D9        BNE $866D
C1/8694: 60           RTS 

; [  ]

C1/8695: A9 88        LDA #$88
C1/8697: 8D B6 DB     STA $DBB6
C1/869A: A9 8F        LDA #$8F
C1/869C: 4C D9 FB     JMP $FBD9       ; play sound effect

; [ show monster $08: sandworm ]

C1/869F: A5 DE        LDA $DE
C1/86A1: 29 1F        AND #$1F
C1/86A3: F0 03        BEQ $86A8
C1/86A5: 20 95 86     JSR $8695
C1/86A8: 20 F2 02     JSR $02F2       ; wait one frame
C1/86AB: 20 B8 1C     JSR $1CB8
C1/86AE: 64 70        STZ $70
C1/86B0: 7B           TDC 
C1/86B1: AA           TAX 
C1/86B2: A9 01        LDA #$01
C1/86B4: 9D 2E D0     STA $D02E,X
C1/86B7: BD 06 D0     LDA $D006,X
C1/86BA: F0 0A        BEQ $86C6
C1/86BC: DD 26 D0     CMP $D026,X
C1/86BF: F0 05        BEQ $86C6
C1/86C1: FE 26 D0     INC $D026,X
C1/86C4: 80 05        BRA $86CB
C1/86C6: 9E 2E D0     STZ $D02E,X
C1/86C9: E6 70        INC $70
C1/86CB: E8           INX 
C1/86CC: E0 08 00     CPX #$0008
C1/86CF: D0 E1        BNE $86B2
C1/86D1: A5 70        LDA $70
C1/86D3: C9 08        CMP #$08
C1/86D5: D0 D1        BNE $86A8
C1/86D7: 20 B5 84     JSR $84B5
C1/86DA: 20 39 75     JSR $7539
C1/86DD: 20 29 75     JSR $7529
C1/86E0: 20 52 83     JSR $8352
C1/86E3: A5 70        LDA $70
C1/86E5: 05 DE        ORA $DE
C1/86E7: 85 DE        STA $DE
C1/86E9: 7B           TDC 
C1/86EA: AA           TAX 
C1/86EB: BD 06 D0     LDA $D006,X
C1/86EE: 9D 26 D0     STA $D026,X
C1/86F1: E8           INX 
C1/86F2: E0 08 00     CPX #$0008
C1/86F5: D0 F4        BNE $86EB
C1/86F7: 20 95 86     JSR $8695
C1/86FA: 20 F2 02     JSR $02F2
C1/86FD: 20 B8 1C     JSR $1CB8
C1/8700: 64 70        STZ $70
C1/8702: 7B           TDC 
C1/8703: AA           TAX 
C1/8704: A9 01        LDA #$01
C1/8706: 9D 2E D0     STA $D02E,X
C1/8709: BD 06 D0     LDA $D006,X
C1/870C: F0 0E        BEQ $871C
C1/870E: BD 26 D0     LDA $D026,X
C1/8711: F0 09        BEQ $871C
C1/8713: C9 01        CMP #$01
C1/8715: F0 05        BEQ $871C
C1/8717: DE 26 D0     DEC $D026,X
C1/871A: 80 08        BRA $8724
C1/871C: 9E 2E D0     STZ $D02E,X
C1/871F: 9E 26 D0     STZ $D026,X
C1/8722: E6 70        INC $70
C1/8724: E8           INX 
C1/8725: E0 08 00     CPX #$0008
C1/8728: D0 DA        BNE $8704
C1/872A: A5 70        LDA $70
C1/872C: C9 08        CMP #$08
C1/872E: D0 CA        BNE $86FA
C1/8730: 20 F2 02     JSR $02F2       ; wait one frame
C1/8733: 4C B8 1C     JMP $1CB8

; [ do monster entry ]

C1/8736: AD EF 3E     LDA $3EEF       ; monster entry
C1/8739: 29 07        AND #$07
C1/873B: 0A           ASL 
C1/873C: AA           TAX 
C1/873D: BF 4C 87 C1  LDA $C1874C,X
C1/8741: 85 70        STA $70
C1/8743: BF 4D 87 C1  LDA $C1874D,X
C1/8747: 85 71        STA $71
C1/8749: 6C 70 00     JMP ($0070)

; monster entry jump table
C1/874C:              .DW $8962, $897C, $87E3, $890C, $8826, $8926, $8962, $8962

; [  ]

C1/875C: 20 5F 87     JSR $875F
C1/875F: AD BC DB     LDA $DBBC
C1/8762: F0 38        BEQ $879C
C1/8764: AD BD DB     LDA $DBBD
C1/8767: F0 30        BEQ $8799
C1/8769: A8           TAY 
C1/876A: AD BE DB     LDA $DBBE
C1/876D: AA           TAX 
C1/876E: A9 0F        LDA #$0F
C1/8770: 85 70        STA $70
C1/8772: 85 72        STA $72
C1/8774: A5 70        LDA $70
C1/8776: 99 55 B4     STA $B455,Y
C1/8779: 99 56 B4     STA $B456,Y
C1/877C: 9D 53 B4     STA $B453,X
C1/877F: 9D 54 B4     STA $B454,X
C1/8782: E8           INX 
C1/8783: E8           INX 
C1/8784: 88           DEY 
C1/8785: 88           DEY 
C1/8786: 30 04        BMI $878C
C1/8788: C6 70        DEC $70
C1/878A: D0 E8        BNE $8774
C1/878C: CE BD DB     DEC $DBBD
C1/878F: CE BD DB     DEC $DBBD
C1/8792: EE BE DB     INC $DBBE
C1/8795: EE BE DB     INC $DBBE
C1/8798: 60           RTS 
C1/8799: 9C BC DB     STZ $DBBC
C1/879C: 60           RTS 

; [  ]

C1/879D: AD BD DB     LDA $DBBD
C1/87A0: C9 3F        CMP #$3F
C1/87A2: F0 2A        BEQ $87CE
C1/87A4: A8           TAY 
C1/87A5: AD BE DB     LDA $DBBE
C1/87A8: AA           TAX 
C1/87A9: A9 E0        LDA #$E0
C1/87AB: 85 70        STA $70
C1/87AD: C0 71 00     CPY #$0071
C1/87B0: 90 02        BCC $87B4
C1/87B2: 80 08        BRA $87BC
C1/87B4: A5 70        LDA $70
C1/87B6: 99 55 B4     STA $B455,Y
C1/87B9: 9D 55 B4     STA $B455,X
C1/87BC: E8           INX 
C1/87BD: 88           DEY 
C1/87BE: 30 08        BMI $87C8
C1/87C0: E6 70        INC $70
C1/87C2: A5 70        LDA $70
C1/87C4: C9 FF        CMP #$FF
C1/87C6: D0 E5        BNE $87AD
C1/87C8: CE BD DB     DEC $DBBD
C1/87CB: EE BE DB     INC $DBBE
C1/87CE: 60           RTS 

; [  ]

C1/87CF: AD BC DB     LDA $DBBC
C1/87D2: F0 09        BEQ $87DD
C1/87D4: 20 F2 02     JSR $02F2       ; wait one frame
C1/87D7: 20 5C 87     JSR $875C
C1/87DA: 4C CF 87     JMP $87CF
C1/87DD: A9 01        LDA #$01
C1/87DF: 8D A1 F9     STA $F9A1
C1/87E2: 60           RTS 

; [ monster entry $02:  ]

C1/87E3: 7B           TDC 
C1/87E4: AA           TAX 
C1/87E5: 8E 79 BC     STX $BC79
C1/87E8: BD 06 D0     LDA $D006,X
C1/87EB: 9D 26 D0     STA $D026,X
C1/87EE: E8           INX 
C1/87EF: E0 08 00     CPX #$0008
C1/87F2: D0 F4        BNE $87E8
C1/87F4: 20 8A 1C     JSR $1C8A
C1/87F7: 20 5C 87     JSR $875C
C1/87FA: 64 70        STZ $70
C1/87FC: 7B           TDC 
C1/87FD: AA           TAX 
C1/87FE: BD 06 D0     LDA $D006,X
C1/8801: F0 0A        BEQ $880D
C1/8803: BD 26 D0     LDA $D026,X
C1/8806: F0 05        BEQ $880D
C1/8808: DE 26 D0     DEC $D026,X
C1/880B: 80 02        BRA $880F
C1/880D: E6 70        INC $70
C1/880F: E8           INX 
C1/8810: E0 08 00     CPX #$0008
C1/8813: D0 E9        BNE $87FE
C1/8815: A5 70        LDA $70
C1/8817: C9 08        CMP #$08
C1/8819: D0 D9        BNE $87F4
C1/881B: 20 CF 87     JSR $87CF
C1/881E: 7B           TDC 
C1/881F: AA           TAX 
C1/8820: 8E 77 BC     STX $BC77
C1/8823: 4C 84 1C     JMP $1C84

; [ monster entry $04:  ]

C1/8826: A9 8E        LDA #$8E
C1/8828: 8D BD DB     STA $DBBD
C1/882B: A9 52        LDA #$52
C1/882D: 8D BE DB     STA $DBBE
C1/8830: 20 36 88     JSR $8836
C1/8833: 4C 91 04     JMP $0491

; [  ]

C1/8836: 7B           TDC 
C1/8837: AA           TAX 
C1/8838: 8E D9 DB     STX $DBD9
C1/883B: 20 F2 02     JSR $02F2       ; wait one frame
C1/883E: 20 9D 87     JSR $879D
C1/8841: 20 A8 88     JSR $88A8
C1/8844: AE D9 DB     LDX $DBD9
C1/8847: E8           INX 
C1/8848: E8           INX 
C1/8849: 8E D9 DB     STX $DBD9
C1/884C: E0 A0 00     CPX #$00A0
C1/884F: D0 EA        BNE $883B
C1/8851: C2 20        REP #$20
C1/8853: 7B           TDC 
C1/8854: AA           TAX 
C1/8855: 9D 0B A0     STA $A00B,X
C1/8858: 9D 0B A4     STA $A40B,X
C1/885B: E8           INX 
C1/885C: E8           INX 
C1/885D: E8           INX 
C1/885E: E8           INX 
C1/885F: E0 80 03     CPX #$0380
C1/8862: D0 F1        BNE $8855
C1/8864: 7B           TDC 
C1/8865: E2 20        SEP #$20
C1/8867: EE D4 DB     INC $DBD4
C1/886A: 60           RTS 

; [  ]

C1/886B: C2 20        REP #$20
C1/886D: 7B           TDC 
C1/886E: A8           TAY 
C1/886F: A9 FF 00     LDA #$00FF
C1/8872: 99 37 B0     STA $B037,Y     ; clear bg3 scroll hdma data
C1/8875: 3A           DEC 
C1/8876: C8           INY 
C1/8877: C8           INY 
C1/8878: C0 C0 01     CPY #$01C0
C1/887B: D0 F5        BNE $8872
C1/887D: 7B           TDC 
C1/887E: AA           TAX 
C1/887F: A9 FF 00     LDA #$00FF
C1/8882: 9E 0B A0     STZ $A00B,X
C1/8885: 9E 0B A4     STZ $A40B,X
C1/8888: 9E 09 A0     STZ $A009,X
C1/888B: 9E 09 A4     STZ $A409,X
C1/888E: 9E 37 A9     STZ $A937,X
C1/8891: 9D 39 A9     STA $A939,X
C1/8894: 9E B7 AC     STZ $ACB7,X
C1/8897: 9D B9 AC     STA $ACB9,X
C1/889A: 3A           DEC 
C1/889B: E8           INX 
C1/889C: E8           INX 
C1/889D: E8           INX 
C1/889E: E8           INX 
C1/889F: E0 80 03     CPX #$0380
C1/88A2: D0 DE        BNE $8882
C1/88A4: 7B           TDC 
C1/88A5: E2 20        SEP #$20
C1/88A7: 60           RTS

; [  ]

C1/88A8: C2 20        REP #$20
C1/88AA: A9 A0 00     LDA #$00A0
C1/88AD: 38           SEC 
C1/88AE: ED D9 DB     SBC $DBD9
C1/88B1: 4A           LSR 
C1/88B2: 0A           ASL 
C1/88B3: 18           CLC 
C1/88B4: 69 40 00     ADC #$0040
C1/88B7: A8           TAY 
C1/88B8: AD D9 DB     LDA $DBD9
C1/88BB: 1A           INC 
C1/88BC: 85 70        STA $70
C1/88BE: 7B           TDC 
C1/88BF: AA           TAX 
C1/88C0: A9 50 00     LDA #$0050
C1/88C3: 85 74        STA $74
C1/88C5: A5 74        LDA $74
C1/88C7: 18           CLC 
C1/88C8: 65 70        ADC $70
C1/88CA: 85 74        STA $74
C1/88CC: C9 A0 00     CMP #$00A0
C1/88CF: 90 17        BCC $88E8
C1/88D1: 38           SEC 
C1/88D2: E9 A0 00     SBC #$00A0
C1/88D5: 85 74        STA $74
C1/88D7: 8A           TXA 
C1/88D8: 18           CLC 
C1/88D9: 69 20 00     ADC #$0020
C1/88DC: 85 76        STA $76
C1/88DE: 98           TYA 
C1/88DF: 4A           LSR 
C1/88E0: 38           SEC 
C1/88E1: E5 76        SBC $76
C1/88E3: 99 37 B0     STA $B037,Y
C1/88E6: C8           INY 
C1/88E7: C8           INY 
C1/88E8: E8           INX 
C1/88E9: E0 A0 00     CPX #$00A0
C1/88EC: D0 D7        BNE $88C5
C1/88EE: 7B           TDC 
C1/88EF: AA           TAX 
C1/88F0: A8           TAY 
C1/88F1: B9 37 B0     LDA $B037,Y
C1/88F4: 9D 0B A0     STA $A00B,X
C1/88F7: 9D 0B A4     STA $A40B,X
C1/88FA: E8           INX 
C1/88FB: E8           INX 
C1/88FC: E8           INX 
C1/88FD: E8           INX 
C1/88FE: C8           INY 
C1/88FF: C8           INY 
C1/8900: E0 80 03     CPX #$0380
C1/8903: D0 EC        BNE $88F1
C1/8905: 7B           TDC 
C1/8906: E2 20        SEP #$20
C1/8908: EE D4 DB     INC $DBD4
C1/890B: 60           RTS 

; [ monster entry $03:  ]

C1/890C: A5 DE        LDA $DE
C1/890E: 48           PHA 
C1/890F: 64 DE        STZ $DE
C1/8911: 20 B8 1C     JSR $1CB8
C1/8914: 7B           TDC 
C1/8915: AA           TAX 
C1/8916: 8E 77 BC     STX $BC77
C1/8919: 8E 79 BC     STX $BC79
C1/891C: 20 CF 87     JSR $87CF
C1/891F: 68           PLA 
C1/8920: 85 70        STA $70
C1/8922: 7B           TDC 
C1/8923: 4C BB 75     JMP $75BB

; [ monster entry $05:  ]

C1/8926: A2 80 00     LDX #$0080
C1/8929: 8E 77 BC     STX $BC77
C1/892C: 7B           TDC 
C1/892D: AA           TAX 
C1/892E: 8E 79 BC     STX $BC79
C1/8931: A9 0F        LDA #$0F
C1/8933: 8D B7 B3     STA $B3B7
C1/8936: 20 B8 1C     JSR $1CB8
C1/8939: 20 F2 02     JSR $02F2       ; wait one frame
C1/893C: 20 CF 87     JSR $87CF
C1/893F: 20 EB 1C     JSR $1CEB
C1/8942: 20 65 1D     JSR $1D65
C1/8945: AD 77 BC     LDA $BC77
C1/8948: 38           SEC 
C1/8949: E9 08        SBC #$08
C1/894D: 8D 77 BC     STA $BC77
C1/894E: EE 42 DB     INC $DB42
C1/8951: CE B7 B3     DEC $B3B7
C1/8954: 10 E3        BPL $8939
C1/8956: 9C 77 BC     STZ $BC77
C1/8959: 9C B7 B3     STZ $B3B7
C1/895C: 20 B8 1C     JSR $1CB8
C1/895F: 4C CF 87     JMP $87CF

; [ monster entry $00: enter from side ]

C1/8962: A5 F6        LDA $F6
C1/8964: F0 05        BEQ $896B
C1/8966: A2 00 FF     LDX #$FF00
C1/8969: 80 03        BRA $896E
C1/896B: A2 00 01     LDX #$0100
C1/896E: 8E 77 BC     STX $BC77
C1/8971: 7B           TDC 
C1/8972: AA           TAX 
C1/8973: 8E 79 BC     STX $BC79
C1/8976: 20 36 84     JSR $8436
C1/8979: 4C CF 87     JMP $87CF

; [ monster entry $01: enter from top ]

C1/897C: 20 60 83     JSR $8360
C1/897F: A2 00 01     LDX #$0100
C1/8982: 8E 79 BC     STX $BC79
C1/8985: 7B           TDC 
C1/8986: AA           TAX 
C1/8987: 8E 77 BC     STX $BC77
C1/898A: 20 CA 83     JSR $83CA
C1/898D: 20 67 83     JSR $8367
C1/8990: 4C CF 87     JMP $87CF

; show monster jump table
;   0: fade
;   1: iron claw
;   2: discreet
;   3: motor trap
;   4: switch ???
;   5: transform
;   6: fade and drop
;   7: pages
;   8: sandworm
;   9: merugene 1
;   A: merugene 2
;   B: merugene 3
;   C: merugene 4
;   D: neo-exdeath
C1/8993: 84A7 84C1 8528 8533 8592 85B8 854E 8626
C1/89A3: 869F 856A 857E 84D8 8500 89D0

C1/89AF: A9 E0        LDA #$E0
C1/89B1: 8D 8A BC     STA $BC8A
C1/89B4: 20 F2 02     JSR $02F2       ; wait one frame
C1/89B7: EE 8A BC     INC $BC8A
C1/89BA: AD 8A BC     LDA $BC8A
C1/89BD: C9 FF        CMP #$FF
C1/89BF: D0 F3        BNE $89B4
C1/89C1: 60           RTS 

C1/89C2: 20 F2 02     JSR $02F2       ; wait one frame
C1/89C5: CE 8A BC     DEC $BC8A
C1/89C8: AD 8A BC     LDA $BC8A
C1/89CB: C9 E0        CMP #$E0
C1/89CD: D0 F3        BNE $89C2
C1/89CF: 60           RTS 

; [ show monster $0D: neo-exdeath ]

C1/89D0: 9C 56 EE     STZ $EE56
C1/89D3: A9 20        LDA #$20
C1/89D5: 20 DB 72     JSR $72DB
C1/89D8: A9 40        LDA #$40
C1/89DA: 20 DB 72     JSR $72DB
C1/89DD: A9 00        LDA #$00
C1/89DF: 20 DB 72     JSR $72DB
C1/89E2: 7B           TDC 
C1/89E3: AA           TAX 
C1/89E4: DA           PHX 
C1/89E5: 20 F2 02     JSR $02F2       ; wait one frame
C1/89E8: 20 96 FC     JSR $FC96       ; generate random number
C1/89EB: 29 3F        AND #$3F
C1/89ED: D0 03        BNE $89F2
C1/89EF: 20 DB 72     JSR $72DB
C1/89F2: 20 96 FC     JSR $FC96       ; generate random number
C1/89F5: 29 03        AND #$03
C1/89F7: AA           TAX 
C1/89F8: 8E 77 BC     STX $BC77
C1/89FB: 86 70        STX $70
C1/89FD: 20 B4 83     JSR $83B4
C1/8A00: FA           PLX 
C1/8A01: E8           INX 
C1/8A02: E0 80 01     CPX #$0180
C1/8A05: D0 DD        BNE $89E4
C1/8A07: 20 AF 85     JSR $85AF
C1/8A0A: 7B           TDC 
C1/8A0B: AA           TAX 
C1/8A0C: 8E E5 DB     STX $DBE5
C1/8A0F: 8E E7 DB     STX $DBE7
C1/8A12: 9C EA DB     STZ $DBEA
C1/8A15: A9 FE        LDA #$FE
C1/8A17: 8D F2 04     STA $04F2
C1/8A1A: 20 F2 02     JSR $02F2       ; wait one frame
C1/8A1D: EE EA DB     INC $DBEA
C1/8A20: AD EA DB     LDA $DBEA
C1/8A23: 29 1F        AND #$1F
C1/8A25: D0 06        BNE $8A2D
C1/8A27: EE E7 DB     INC $DBE7
C1/8A2A: EE E5 DB     INC $DBE5
C1/8A2D: AD E5 DB     LDA $DBE5
C1/8A30: C9 08        CMP #$08
C1/8A32: D0 E6        BNE $8A1A
C1/8A34: A9 38        LDA #$38
C1/8A36: 20 41 81     JSR $8141       ; wait
C1/8A39: 9C 56 EE     STZ $EE56
C1/8A3C: 20 F2 02     JSR $02F2       ; wait one frame
C1/8A3F: 20 F2 02     JSR $02F2       ; wait one frame
C1/8A42: 20 78 CB     JSR $CB78
C1/8A45: AD 56 EE     LDA $EE56
C1/8A48: C9 20        CMP #$20
C1/8A4A: D0 F0        BNE $8A3C
C1/8A4C: EE 2E FF     INC $FF2E
C1/8A4F: 9C 56 EE     STZ $EE56
C1/8A52: A9 02        LDA #$02
C1/8A54: 8D 85 BC     STA $BC85
C1/8A57: 20 AF 89     JSR $89AF
C1/8A5A: A9 1E        LDA #$1E
C1/8A5C: 8F 2C 21 00  STA $00212C
C1/8A60: A9 1C        LDA #$1C
C1/8A62: 8D F2 04     STA $04F2
C1/8A65: 20 F2 02     JSR $02F2       ; wait one frame
C1/8A68: A2 F0 00     LDX #$00F0
C1/8A6B: 8E 77 BC     STX $BC77
C1/8A6E: 20 A6 85     JSR $85A6
C1/8A71: EE E4 DB     INC $DBE4
C1/8A74: A9 F0        LDA #$F0
C1/8A76: 20 41 81     JSR $8141       ; wait
C1/8A79: A9 F0        LDA #$F0
C1/8A7B: 20 41 81     JSR $8141       ; wait
C1/8A7E: A9 09        LDA #$09
C1/8A80: 8D 04 FF     STA $FF04
C1/8A83: A9 1F        LDA #$1F
C1/8A85: 20 5D 33     JSR $335D
C1/8A88: 20 F2 02     JSR $02F2       ; wait one frame
C1/8A8B: 20 6E 83     JSR $836E
C1/8A8E: 20 01 04     JSR $0401
C1/8A91: EE E9 DB     INC $DBE9
C1/8A94: A9 02        LDA #$02
C1/8A96: 8D BB B3     STA $B3BB
C1/8A99: EE B8 B3     INC $B3B8
C1/8A9C: A9 1F        LDA #$1F
C1/8A9E: 8D F2 04     STA $04F2
C1/8AA1: 20 F2 02     JSR $02F2       ; wait one frame
C1/8AA4: A2 F0 00     LDX #$00F0
C1/8AA7: 8E E5 DB     STX $DBE5
C1/8AAA: 8E 77 BC     STX $BC77
C1/8AAD: 7B           TDC 
C1/8AAE: AA           TAX 
C1/8AAF: 8E E7 DB     STX $DBE7
C1/8AB2: 8E 79 BC     STX $BC79
C1/8AB5: 9C E9 DB     STZ $DBE9
C1/8AB8: 20 A8 8C     JSR $8CA8       ; show neo-exdeath intro dialogue
C1/8ABB: 20 C2 89     JSR $89C2
C1/8ABE: 9C 85 BC     STZ $BC85
C1/8AC1: 20 B5 84     JSR $84B5
C1/8AC4: 20 52 83     JSR $8352
C1/8AC7: A9 0A        LDA #$0A
C1/8AC9: 20 BB 75     JSR $75BB
C1/8ACC: A2 F0 00     LDX #$00F0
C1/8ACF: DA           PHX 
C1/8AD0: 20 F2 02     JSR $02F2       ; wait one frame
C1/8AD3: 20 F2 02     JSR $02F2       ; wait one frame
C1/8AD6: 20 F2 02     JSR $02F2       ; wait one frame
C1/8AD9: FA           PLX 
C1/8ADA: E0 80 00     CPX #$0080
C1/8ADD: D0 03        BNE $8AE2
C1/8ADF: 20 F5 78     JSR $78F5       ; flash screen
C1/8AE2: E0 40 00     CPX #$0040
C1/8AE5: D0 03        BNE $8AEA
C1/8AE7: 20 F5 78     JSR $78F5       ; flash screen
C1/8AEA: 8E E5 DB     STX $DBE5
C1/8AED: CA           DEX 
C1/8AEE: D0 DF        BNE $8ACF
C1/8AF0: A9 07        LDA #$07
C1/8AF2: 8D EC DB     STA $DBEC
C1/8AF5: EE EB DB     INC $DBEB
C1/8AF8: 9C EA DB     STZ $DBEA
C1/8AFB: A9 02        LDA #$02
C1/8AFD: 8D E9 DB     STA $DBE9
C1/8B00: 20 F5 78     JSR $78F5       ; flash screen
C1/8B03: 20 46 9D     JSR $9D46
C1/8B06: A9 03        LDA #$03
C1/8B08: 8D EC DB     STA $DBEC
C1/8B0B: 20 46 9D     JSR $9D46
C1/8B0E: A9 01        LDA #$01
C1/8B10: 8D EC DB     STA $DBEC
C1/8B13: 20 46 9D     JSR $9D46
C1/8B16: 9C EB DB     STZ $DBEB
C1/8B19: 20 F2 02     JSR $02F2       ; wait one frame
C1/8B1C: 7B           TDC 
C1/8B1D: AA           TAX 
C1/8B1E: 86 70        STX $70
C1/8B20: 20 82 83     JSR $8382
C1/8B23: 7B           TDC 
C1/8B24: AA           TAX 
C1/8B25: 86 70        STX $70
C1/8B27: 4C 9B 83     JMP $839B

; [  ]

C1/8B2A: A5 DE        LDA $DE
C1/8B2C: 85 70        STA $70
C1/8B2E: 7B           TDC 
C1/8B2F: AA           TAX 
C1/8B30: 06 70        ASL $70
C1/8B32: B0 08        BCS $8B3C
C1/8B34: BD 9E 7B     LDA $7B9E,X
C1/8B37: 29 CF        AND #$CF
C1/8B39: 9D 9E 7B     STA $7B9E,X
C1/8B3C: E8           INX 
C1/8B3D: E8           INX 
C1/8B3E: E8           INX 
C1/8B3F: E8           INX 
C1/8B40: E0 20 00     CPX #$0020
C1/8B43: D0 EB        BNE $8B30
C1/8B45: 60           RTS 

; [ graphics script command $F2: show monster ]

C1/8B46: EE 10 D1     INC $D110
C1/8B49: 20 4D 8D     JSR $8D4D       ; get graphics script parameter 2
C1/8B4C: 29 3F        AND #$3F
C1/8B4E: 0A           ASL 
C1/8B4F: AA           TAX 
C1/8B50: BF 93 89 C1  LDA $C18993,X
C1/8B54: 85 70        STA $70
C1/8B56: BF 94 89 C1  LDA $C18994,X
C1/8B5A: 85 71        STA $71
C1/8B5C: 20 66 8B     JSR $8B66
C1/8B5F: 20 2A 8B     JSR $8B2A
C1/8B62: 9C 10 D1     STZ $D110
C1/8B65: 60           RTS 
C1/8B66: 6C 70 00     JMP ($0070)

; [ graphics script command $FC: execute graphics commands ]

C1/8B69: 20 4D 8D     JSR $8D4D       ; get graphics script parameter 2
C1/8B6C: 0A           ASL 
C1/8B6D: AA           TAX 
C1/8B6E: BF 7D 8B C1  LDA $C18B7D,X
C1/8B72: 85 70        STA $70
C1/8B74: BF 7E 8B C1  LDA $C18B7E,X
C1/8B78: 85 71        STA $71
C1/8B7A: 6C 70 00     JMP ($0070)

; graphics command jump table
;   0: attack animation
;   1: ability/command animation
;   2: special ability animation (animals/conjure/combine/terrain)
;   3: monster special attack animation ???
;   4: show attack name
;   5: display battle messages
;   6: show damage numerals
;   7:
;   8: no effect
;   9: show item name ???
;   10: item ???
C1/8B7D: B677 8D5F 8CF1 8CF1 8BE4 8C37 01FE B68C
C1/8B8D: 8BA9 8BAA 8B93

C1/8B93: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/8B96: A9 0B        LDA #$0B
C1/8B98: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/8B9B: 99 58 CF     STA $CF58,Y
C1/8B9E: 20 8C B6     JSR $B68C
C1/8BA1: 7B           TDC 
C1/8BA2: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/8BA5: 99 58 CF     STA $CF58,Y
C1/8BA8: 60           RTS 

C1/8BA9: 60           RTS 

C1/8BAA: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/8BAD: A9 0B        LDA #$0B
C1/8BAF: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/8BB2: 99 58 CF     STA $CF58,Y
C1/8BB5: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8BB8: 38           SEC 
C1/8BB9: E9 E0        SBC #$E0
C1/8BBB: C2 20        REP #$20
C1/8BBD: 18           CLC 
C1/8BBE: 69 8A 01     ADC #$018A
C1/8BC1: AA           TAX 
C1/8BC2: 7B           TDC 
C1/8BC3: E2 20        SEP #$20
C1/8BC5: 20 9C B6     JSR $B69C
C1/8BC8: 7B           TDC 
C1/8BC9: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/8BCC: 99 58 CF     STA $CF58,Y
C1/8BCF: 60           RTS 

; string table data
C1/8BD0: 0F 00 05 01 ; attack name
C1/8BD4: 18 00 05 00 ; ability/command name
C1/8BD8: 19 00 09 00 ; special ability name (animals/conjure/combine/terrain)
C1/8BDC: 1A 00 09 00 ; monster special attack name
C1/8BE0: 0E 00 09 00 ; item name

; [ show attack name ]

C1/8BE4: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/8BE7: 20 47 8D     JSR $8D47       ; get graphics script parameter 3 (string table)
C1/8BEA: 0A           ASL 
C1/8BEB: 0A           ASL 
C1/8BEC: AA           TAX 
C1/8BED: 20 53 8D     JSR $8D53       ; get graphics script parameter 4 (string id)
C1/8BF0: 85 70        STA $70
C1/8BF2: BF D2 8B C1  LDA $C18BD2,X
C1/8BF6: 8D A3 BC     STA $BCA3       ; string length (5 or 9)
C1/8BF9: BF D3 8B C1  LDA $C18BD3,X
C1/8BFD: F0 0D        BEQ $8C0C
C1/8BFF: A5 70        LDA $70
C1/8C01: C9 57        CMP #$57
C1/8C03: 90 07        BCC $8C0C
C1/8C05: A9 09        LDA #$09
C1/8C07: 8D A3 BC     STA $BCA3
C1/8C0A: 80 09        BRA $8C15
C1/8C0C: C9 48        CMP #$48
C1/8C0E: 90 05        BCC $8C15
C1/8C10: A9 06        LDA #$06
C1/8C12: 8D A3 BC     STA $BCA3
C1/8C15: BF D0 8B C1  LDA $C18BD0,X   ; escape code
C1/8C19: 8D F6 DB     STA $DBF6
C1/8C1C: BF D1 8B C1  LDA $C18BD1,X   ; string table offset (always zero)
C1/8C20: 18           CLC 
C1/8C21: 65 70        ADC $70
C1/8C23: 8D F7 DB     STA $DBF7       ; string id
C1/8C26: 9C F8 DB     STZ $DBF8       ; null-terminator
C1/8C29: A2 F6 DB     LDX #$DBF6
C1/8C2C: 8E A0 BC     STX $BCA0
C1/8C2F: A9 7E        LDA #$7E        ; source address = $7EDBF6
C1/8C31: 8D A2 BC     STA $BCA2
C1/8C34: 4C 1F 3B     JMP $3B1F       ; 

; [ animation command $05: display queued battle messages ]

C1/8C37: 7B           TDC 
C1/8C38: A8           TAY 
C1/8C39: B1 F2        LDA ($F2),Y     ; battle message queue
C1/8C3B: F0 10        BEQ $8C4D
C1/8C3D: C9 FF        CMP #$FF
C1/8C3F: F0 12        BEQ $8C53       ; branch if end of queue
C1/8C41: C2 20        REP #$20
C1/8C43: 0A           ASL 
C1/8C44: AA           TAX 
C1/8C45: 7B           TDC 
C1/8C46: E2 20        SEP #$20
C1/8C48: 5A           PHY 
C1/8C49: 20 6D 8C     JSR $8C6D       ; display battle message
C1/8C4C: 7A           PLY 
C1/8C4D: C8           INY 
C1/8C4E: C0 18 00     CPY #$0018
C1/8C51: D0 E6        BNE $8C39
C1/8C53: C2 20        REP #$20
C1/8C55: AD F2 00     LDA $00F2       ; increment message queue pointer
C1/8C58: 18           CLC 
C1/8C59: 69 18 00     ADC #$0018
C1/8C5C: 8D F2 00     STA $00F2
C1/8C5F: AD F4 00     LDA $00F4       ; increment variable queue pointer
C1/8C62: 18           CLC 
C1/8C63: 69 0C 00     ADC #$000C
C1/8C66: 8D F4 00     STA $00F4
C1/8C69: 7B           TDC 
C1/8C6A: E2 20        SEP #$20
C1/8C6C: 60           RTS 

; [ display battle message ]

C1/8C6D: BF A9 39 D1  LDA $D139A9,X   ; pointers to battle messages
C1/8C71: 8D A0 BC     STA $BCA0
C1/8C74: BF AA 39 D1  LDA $D139AA,X
C1/8C78: 8D A1 BC     STA $BCA1
C1/8C7B: A9 D1        LDA #$D1
C1/8C7D: 8D A2 BC     STA $BCA2
C1/8C80: 20 88 3C     JSR $3C88       ; draw battle message
C1/8C83: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8C86: F0 05        BEQ $8C8D
C1/8C88: 20 8C FC     JSR $FC8C       ; wait for keypress
C1/8C8B: 80 03        BRA $8C90
C1/8C8D: 20 93 8C     JSR $8C93       ; wait for message
C1/8C90: 4C BB 3C     JMP $3CBB

; [ wait for message ]

C1/8C93: AD 24 04     LDA $0424       ; message speed
C1/8C96: 29 07        AND #$07
C1/8C98: AA           TAX 
C1/8C99: BF A0 8C C1  LDA $C18CA0,X
C1/8C9D: 4C 41 81     JMP $8141       ; wait

; number of frames to wait for each message speed
C1/8CA0:              .DB $20, $40, $60, $80, $A0, $C0, $E0, $00

; [ show neo-exdeath intro dialogue ]

; I am Neo-Exdeath!
; I shall erase all memory...
; All existence...all dimensions...
; And then I too shall disappear...
; For eternity!!!

; わたしは　ネオエクスデス
; すべての記憶　すべてのそんざい (存在)
; すべての次元を消し
; そして　わたしも消えよう
; 永遠に！！

C1/8CA8: A9 CB        LDA #$CB
C1/8CAA: 48           PHA 
C1/8CAB: 20 D4 8C     JSR $8CD4       ; display battle dialogue
C1/8CAE: A9 04        LDA #$04
C1/8CB0: 20 96 8C     JSR $8C96
C1/8CB3: 20 BB 3C     JSR $3CBB       ; 
C1/8CB6: 68           PLA 
C1/8CB7: 1A           INC 
C1/8CB8: C9 D0        CMP #$D0
C1/8CBA: D0 EE        BNE $8CAA
C1/8CBC: 60           RTS 

; [ graphics script command $F6: show battle dialogue ]

C1/8CBD: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8CC0: 20 D4 8C     JSR $8CD4       ; display battle dialogue
C1/8CC3: 20 4D 8D     JSR $8D4D       ; get graphics script parameter 2
C1/8CC6: 20 96 8C     JSR $8C96
C1/8CC9: 20 4D 8D     JSR $8D4D       ; get graphics script parameter 2
C1/8CCC: 10 03        BPL $8CD1
C1/8CCE: 20 8C FC     JSR $FC8C       ; wait for keypress
C1/8CD1: 4C BB 3C     JMP $3CBB

; [ display battle dialogue ]

C1/8CD4: C2 20        REP #$20
C1/8CD6: 0A           ASL 
C1/8CD7: AA           TAX 
C1/8CD8: 7B           TDC 
C1/8CD9: E2 20        SEP #$20
C1/8CDB: BF 00 F0 D0  LDA $D0F000,X   ; pointers to battle dialogue
C1/8CDF: 8D A0 BC     STA $BCA0
C1/8CE2: BF 01 F0 D0  LDA $D0F001,X
C1/8CE6: 8D A1 BC     STA $BCA1
C1/8CE9: A9 D0        LDA #$D0
C1/8CEB: 8D A2 BC     STA $BCA2
C1/8CEE: 4C 88 3C     JMP $3C88       ; draw battle message/dialogue

; [  ]

C1/8CF1: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/8CF4: A9 0B        LDA #$0B
C1/8CF6: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/8CF9: 99 58 CF     STA $CF58,Y
C1/8CFC: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8CFF: C2 20        REP #$20
C1/8D01: 18           CLC 
C1/8D02: 69 1E 01     ADC #$011E
C1/8D05: AA           TAX 
C1/8D06: 7B           TDC 
C1/8D07: E2 20        SEP #$20
C1/8D09: 20 9C B6     JSR $B69C
C1/8D0C: 7B           TDC 
C1/8D0D: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/8D10: 99 58 CF     STA $CF58,Y
C1/8D13: 60           RTS 

; [ show character in ready stance ]

C1/8D14: 5A           PHY 
C1/8D15: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/8D18: 29 03        AND #$03
C1/8D1A: A8           TAY 
C1/8D1B: A9 01        LDA #$01
C1/8D1D: 99 CB D1     STA $D1CB,Y
C1/8D20: 7A           PLY 
C1/8D21: 60           RTS 

; [ show character in normal stance ]

C1/8D22: 5A           PHY 
C1/8D23: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/8D26: 29 03        AND #$03
C1/8D28: A8           TAY 
C1/8D29: 7B           TDC 
C1/8D2A: 99 CB D1     STA $D1CB,Y
C1/8D2D: 7A           PLY 
C1/8D2E: 60           RTS 

; [ get attacker id ]

C1/8D2F: A0 01 00     LDY #$0001      ; attacker id
C1/8D32: B1 EB        LDA ($EB),Y
C1/8D34: 60           RTS 

; [ get target id ]

C1/8D35: A0 02 00     LDY #$0002      ; target id
C1/8D38: B1 EB        LDA ($EB),Y
C1/8D3A: 60           RTS 

C1/8D3B: A0 03 00     LDY #$0003      ; 
C1/8D3E: B1 EB        LDA ($EB),Y
C1/8D40: 60           RTS 

C1/8D41: A0 04 00     LDY #$0004
C1/8D44: B1 EB        LDA ($EB),Y
C1/8D46: 60           RTS 

; [ get graphics script parameter 3 ]

C1/8D47: A0 03 00     LDY #$0003
C1/8D4A: B1 E7        LDA ($E7),Y
C1/8D4C: 60           RTS 

; [ get graphics script parameter 2 ]

C1/8D4D: A0 02 00     LDY #$0002
C1/8D50: B1 E7        LDA ($E7),Y
C1/8D52: 60           RTS 

; [ get graphics script parameter 4 ]

C1/8D53: A0 04 00     LDY #$0004
C1/8D56: B1 E7        LDA ($E7),Y
C1/8D58: 60           RTS 

; [ get graphics script parameter 1 ]

C1/8D59: A0 01 00     LDY #$0001
C1/8D5C: B1 E7        LDA ($E7),Y
C1/8D5E: 60           RTS 

; [ ability animation ]

C1/8D5F: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8D62: 0A           ASL 
C1/8D63: AA           TAX 
C1/8D64: BF 88 8D C1  LDA $C18D88,X
C1/8D68: 85 70        STA $70
C1/8D6A: BF 89 8D C1  LDA $C18D89,X
C1/8D6E: 85 71        STA $71
C1/8D70: 6C 70 00     JMP ($0070)

C1/8D73: 60           RTS 

; [  ]

C1/8D74: 5A           PHY 
C1/8D75: DA           PHX 
C1/8D76: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/8D79: AA           TAX 
C1/8D7A: BF E3 DB D0  LDA $D0DBE3,X
C1/8D7E: C9 FF        CMP #$FF
C1/8D80: F0 03        BEQ $8D85
C1/8D82: 20 E4 FB     JSR $FBE4       ; play animation sound effect
C1/8D85: FA           PLX 
C1/8D86: 7A           PLY 
C1/8D87: 60           RTS 

; ability animation pointers
C1/8D88: 8D73 98D3 9E4D 9986 9F44 9815 9C7C 998B ; $00
C1/8D98: 9966 8D73 9951 9951 9B74 98DF 992D 9977
C1/8DA8: 9EF6 8D73 98C1 9BE3 8D73 8D73 8D73 8D73 ; $10
C1/8DB8: 8D73 8D73 98F7 8D73 98A9 8D73 8D73 8D73
C1/8DC8: 9909 991B 8D73 8D73 972E 974A 8D73 9897 ; $20
C1/8DD8: 987D 981D 8D73 8D73 8D73 99E0 99AD 8D73
C1/8DE8: 8E14 8E20 8E29 8E32 8E3B 8E44 8E4A 8E53 ; $30
C1/8DF8: 8E62 8E72 8E82 8E92 8EA2 8EB2 8EC2 8ED2
C1/8E08: 8EEA 8F01 8F11 8F21 8F2A 8F33           ; $40

; [ ability animation $30: knight (credits) ]

C1/8E14: 20 B8 80     JSR $80B8
C1/8E17: 20 44 9F     JSR $9F44
C1/8E1A: 20 62 80     JSR $8062       ; move character back after attack
C1/8E1D: 4C 6F 90     JMP $906F

; [ ability animation $31: monk (credits) ]

C1/8E20: 20 B8 80     JSR $80B8
C1/8E23: 20 44 9F     JSR $9F44
C1/8E26: 4C 1A 8E     JMP $8E1A

; [ ability animation $32: thief (credits) ]

C1/8E29: 20 B8 80     JSR $80B8
C1/8E2C: 20 51 99     JSR $9951
C1/8E2F: 4C 1A 8E     JMP $8E1A

; [ ability animation $33: dragoon (credits) ]

C1/8E32: 20 74 9B     JSR $9B74
C1/8E35: 20 E0 99     JSR $99E0
C1/8E38: 4C 6F 90     JMP $906F

; [ ability animation $34: ninja (credits) ]

C1/8E3B: 20 B8 80     JSR $80B8
C1/8E3E: 20 F6 9E     JSR $9EF6
C1/8E41: 4C 1A 8E     JMP $8E1A

; [ ability animation $35: samurai (credits) ]

C1/8E44: 20 E3 9B     JSR $9BE3
C1/8E47: 4C 6F 90     JMP $906F

; [ ability animation $36: berserker (credits) ]

C1/8E4A: 20 B8 80     JSR $80B8
C1/8E4D: 20 44 9F     JSR $9F44
C1/8E50: 4C 1A 8E     JMP $8E1A

; [ ability animation $37: hunter (credits) ]

C1/8E53: 20 B8 80     JSR $80B8
C1/8E56: A0 03 00     LDY #$0003
C1/8E59: 7B           TDC 
C1/8E5A: 91 E7        STA ($E7),Y
C1/8E5C: 20 F1 8C     JSR $8CF1
C1/8E5F: 4C 1A 8E     JMP $8E1A

; [ ability animation $38: mystic knight (credits) ]

C1/8E62: 20 B8 80     JSR $80B8
C1/8E65: A0 04 00     LDY #$0004
C1/8E68: A9 01        LDA #$01
C1/8E6A: 91 E7        STA ($E7),Y
C1/8E6C: 20 44 9F     JSR $9F44
C1/8E6F: 4C 1A 8E     JMP $8E1A

; [ ability animation $39: white mage (credits) ]

C1/8E72: 20 B8 80     JSR $80B8       ; move character forward to attack
C1/8E75: A0 03 00     LDY #$0003
C1/8E78: A9 1E        LDA #$1E        ; spell animation $1E
C1/8E7A: 91 E7        STA ($E7),Y
C1/8E7C: 20 77 B6     JSR $B677
C1/8E7F: 4C 1A 8E     JMP $8E1A

; [ ability animation $3A: black mage (credits) ]

C1/8E82: 20 B8 80     JSR $80B8
C1/8E85: A0 03 00     LDY #$0003
C1/8E88: A9 2B        LDA #$2B
C1/8E8A: 91 E7        STA ($E7),Y
C1/8E8C: 20 77 B6     JSR $B677
C1/8E8F: 4C 1A 8E     JMP $8E1A

; [ ability animation $3B: time mage (credits) ]

C1/8E92: 20 B8 80     JSR $80B8
C1/8E95: A0 03 00     LDY #$0003
C1/8E98: A9 42        LDA #$42
C1/8E9A: 91 E7        STA ($E7),Y
C1/8E9C: 20 77 B6     JSR $B677
C1/8E9F: 4C 1A 8E     JMP $8E1A

; [ ability animation $3C: summoner (credits) ]

C1/8EA2: 20 B8 80     JSR $80B8
C1/8EA5: A0 03 00     LDY #$0003
C1/8EA8: A9 69        LDA #$69
C1/8EAA: 91 E7        STA ($E7),Y
C1/8EAC: 20 77 B6     JSR $B677
C1/8EAF: 4C 1A 8E     JMP $8E1A

; [ ability animation $3D: blue mage (credits) ]

C1/8EB2: 20 B8 80     JSR $80B8
C1/8EB5: A0 03 00     LDY #$0003
C1/8EB8: A9 9F        LDA #$9F
C1/8EBA: 91 E7        STA ($E7),Y
C1/8EBC: 20 77 B6     JSR $B677
C1/8EBF: 4C 1A 8E     JMP $8E1A

; [ ability animation $3E: red mage (credits) ]

C1/8EC2: 20 B8 80     JSR $80B8
C1/8EC5: A0 03 00     LDY #$0003
C1/8EC8: A9 30        LDA #$30
C1/8ECA: 91 E7        STA ($E7),Y
C1/8ECC: 20 77 B6     JSR $B677
C1/8ECF: 4C 1A 8E     JMP $8E1A

; [ ability animation $3F: mediator (credits) ]

C1/8ED2: 20 B8 80     JSR $80B8
C1/8ED5: A9 C9        LDA #$C9
C1/8ED7: 8D 4B 7C     STA $7C4B
C1/8EDA: A0 03 00     LDY #$0003
C1/8EDD: A9 E1        LDA #$E1
C1/8EDF: 91 E7        STA ($E7),Y
C1/8EE1: 20 77 B6     JSR $B677
C1/8EE4: 9C 4B 7C     STZ $7C4B
C1/8EE7: 4C 1A 8E     JMP $8E1A

; [ ability animation $40: chemist (credits) ]

C1/8EEA: 20 B8 80     JSR $80B8
C1/8EED: 9C CC 3B     STZ $3BCC
C1/8EF0: A2 2A 01     LDX #$012A
C1/8EF3: 20 8B B5     JSR $B58B
C1/8EF6: A9 01        LDA #$01
C1/8EF8: 20 EC 96     JSR $96EC
C1/8EFB: 20 3C 9D     JSR $9D3C
C1/8EFE: 4C 1A 8E     JMP $8E1A

; [ ability animation $41: geomancer (credits) ]

C1/8F01: 20 B8 80     JSR $80B8
C1/8F04: A0 03 00     LDY #$0003
C1/8F07: A9 51        LDA #$51
C1/8F09: 91 E7        STA ($E7),Y
C1/8F0B: 20 F1 8C     JSR $8CF1
C1/8F0E: 4C 1A 8E     JMP $8E1A

; [ ability animation $42: bard (credits) ]

C1/8F11: 20 B8 80     JSR $80B8
C1/8F14: A0 03 00     LDY #$0003
C1/8F17: A9 57        LDA #$57
C1/8F19: 91 E7        STA ($E7),Y
C1/8F1B: 20 77 B6     JSR $B677
C1/8F1E: 4C 1A 8E     JMP $8E1A

; [ ability animation $43: dancer (credits) ]

C1/8F21: 20 B8 80     JSR $80B8
C1/8F24: 20 1D 98     JSR $981D
C1/8F27: 4C 1A 8E     JMP $8E1A

; [ ability animation $44: mimic (credits) ]

C1/8F2A: 20 B8 80     JSR $80B8
C1/8F2D: 20 DF 98     JSR $98DF
C1/8F30: 4C 1A 8E     JMP $8E1A

; [ ability animation $45: freelancer (credits) ]

C1/8F33: 20 B8 80     JSR $80B8
C1/8F36: 20 44 9F     JSR $9F44
C1/8F39: 4C 1A 8E     JMP $8E1A

; [  ]

C1/8F3C: AD ED F9     LDA $F9ED
C1/8F3F: 29 7F        AND #$7F
C1/8F41: D0 01        BNE $8F44
C1/8F43: 60           RTS 
C1/8F44: 85 70        STA $70
C1/8F46: 64 71        STZ $71
C1/8F48: AD EE F9     LDA $F9EE
C1/8F4B: 85 76        STA $76
C1/8F4D: AD EF F9     LDA $F9EF
C1/8F50: AA           TAX 
C1/8F51: 86 78        STX $78
C1/8F53: C2 20        REP #$20
C1/8F55: 7B           TDC 
C1/8F56: AA           TAX 
C1/8F57: A8           TAY 
C1/8F58: A5 70        LDA $70
C1/8F5A: 48           PHA 
C1/8F5B: 85 72        STA $72
C1/8F5D: 06 70        ASL $70
C1/8F5F: A9 03 00     LDA #$0003
C1/8F62: 38           SEC 
C1/8F63: E5 70        SBC $70
C1/8F65: 85 74        STA $74
C1/8F67: A5 72        LDA $72
C1/8F69: 99 F0 FD     STA $FDF0,Y
C1/8F6C: A5 74        LDA $74
C1/8F6E: 30 13        BMI $8F83
C1/8F70: 8A           TXA 
C1/8F71: 38           SEC 
C1/8F72: E5 72        SBC $72
C1/8F74: 0A           ASL 
C1/8F75: 0A           ASL 
C1/8F76: 18           CLC 
C1/8F77: 69 0A 00     ADC #$000A
C1/8F7A: 18           CLC 
C1/8F7B: 65 74        ADC $74
C1/8F7D: 85 74        STA $74
C1/8F7F: C6 72        DEC $72
C1/8F81: 80 0C        BRA $8F8F
C1/8F83: 8A           TXA 
C1/8F84: 0A           ASL 
C1/8F85: 0A           ASL 
C1/8F86: 18           CLC 
C1/8F87: 69 06 00     ADC #$0006
C1/8F8A: 18           CLC 
C1/8F8B: 65 74        ADC $74
C1/8F8D: 85 74        STA $74
C1/8F8F: E8           INX 
C1/8F90: C8           INY 
C1/8F91: C8           INY 
C1/8F92: E4 72        CPX $72
C1/8F94: 90 D1        BCC $8F67
C1/8F96: BB           TYX 
C1/8F97: CA           DEX 
C1/8F98: CA           DEX 
C1/8F99: BD F0 FD     LDA $FDF0,X
C1/8F9C: DD EE FD     CMP $FDEE,X
C1/8F9F: F0 07        BEQ $8FA8
C1/8FA1: 8A           TXA 
C1/8FA2: 4A           LSR 
C1/8FA3: 99 F0 FD     STA $FDF0,Y
C1/8FA6: C8           INY 
C1/8FA7: C8           INY 
C1/8FA8: CA           DEX 
C1/8FA9: CA           DEX 
C1/8FAA: D0 ED        BNE $8F99
C1/8FAC: 68           PLA 
C1/8FAD: 0A           ASL 
C1/8FAE: 49 FF FF     EOR #$FFFF
C1/8FB1: 1A           INC 
C1/8FB2: 18           CLC 
C1/8FB3: 69 02 01     ADC #$0102
C1/8FB6: 85 70        STA $70
C1/8FB8: AA           TAX 
C1/8FB9: F0 0F        BEQ $8FCA
C1/8FBB: 7B           TDC 
C1/8FBC: AA           TAX 
C1/8FBD: A9 FF 00     LDA #$00FF
C1/8FC0: 9F F0 FB 7E  STA $7EFBF0,X
C1/8FC4: E8           INX 
C1/8FC5: E8           INX 
C1/8FC6: E4 70        CPX $70
C1/8FC8: D0 F6        BNE $8FC0
C1/8FCA: 7B           TDC 
C1/8FCB: E2 20        SEP #$20
C1/8FCD: 88           DEY 
C1/8FCE: 88           DEY 
C1/8FCF: B9 F0 FD     LDA $FDF0,Y
C1/8FD2: 18           CLC 
C1/8FD3: 65 76        ADC $76
C1/8FD5: B0 04        BCS $8FDB
C1/8FD7: C9 F7        CMP #$F7
C1/8FD9: 90 02        BCC $8FDD
C1/8FDB: A9 F7        LDA #$F7
C1/8FDD: 9F F1 FB 7E  STA $7EFBF1,X
C1/8FE1: A5 76        LDA $76
C1/8FE3: 38           SEC 
C1/8FE4: F9 F0 FD     SBC $FDF0,Y
C1/8FE7: 90 04        BCC $8FED
C1/8FE9: C9 08        CMP #$08
C1/8FEB: B0 02        BCS $8FEF
C1/8FED: A9 08        LDA #$08
C1/8FEF: 9F F0 FB 7E  STA $7EFBF0,X
C1/8FF3: E8           INX 
C1/8FF4: E8           INX 
C1/8FF5: 88           DEY 
C1/8FF6: 88           DEY 
C1/8FF7: 10 D6        BPL $8FCF
C1/8FF9: 8B           PHB 
C1/8FFA: A9 7E        LDA #$7E
C1/8FFC: 48           PHA 
C1/8FFD: AB           PLB 
C1/8FFE: 9B           TXY 
C1/8FFF: CA           DEX 
C1/9000: CA           DEX 
C1/9001: A2 FE 00     LDX #$00FE
C1/9004: A0 00 01     LDY #$0100
C1/9007: C2 20        REP #$20
C1/9009: BD F0 FB     LDA $FBF0,X
C1/900C: 99 F0 FB     STA $FBF0,Y
C1/900F: C8           INY 
C1/9010: C8           INY 
C1/9011: CA           DEX 
C1/9012: CA           DEX 
C1/9013: 10 F4        BPL $9009
C1/9015: 7B           TDC 
C1/9016: A8           TAY 
C1/9017: 06 78        ASL $78
C1/9019: A5 78        LDA $78
C1/901B: C9 00 01     CMP #$0100
C1/901E: 90 24        BCC $9044
C1/9020: 38           SEC 
C1/9021: E5 78        SBC $78
C1/9023: 85 70        STA $70
C1/9025: A9 FF 00     LDA #$00FF
C1/9028: 99 F0 F9     STA $F9F0,Y
C1/902B: C8           INY 
C1/902C: C8           INY 
C1/902D: C4 70        CPY $70
C1/902F: D0 F7        BNE $9028
C1/9031: 7B           TDC 
C1/9032: AA           TAX 
C1/9033: BD F0 FB     LDA $FBF0,X
C1/9036: 99 F0 F9     STA $F9F0,Y
C1/9039: E8           INX 
C1/903A: E8           INX 
C1/903B: C8           INY 
C1/903C: C8           INY 
C1/903D: C0 00 02     CPY #$0200
C1/9040: D0 F1        BNE $9033
C1/9042: 80 26        BRA $906A
C1/9044: A9 00 01     LDA #$0100
C1/9047: 38           SEC 
C1/9048: E5 78        SBC $78
C1/904A: AA           TAX 
C1/904B: BD F0 FB     LDA $FBF0,X
C1/904E: 99 F0 F9     STA $F9F0,Y
C1/9051: E8           INX 
C1/9052: E8           INX 
C1/9053: C8           INY 
C1/9054: C8           INY 
C1/9055: E0 00 02     CPX #$0200
C1/9058: D0 F1        BNE $904B
C1/905A: A9 FF 00     LDA #$00FF
C1/905D: C0 00 02     CPY #$0200
C1/9060: F0 08        BEQ $906A
C1/9062: 99 F0 F9     STA $F9F0,Y
C1/9065: C8           INY 
C1/9066: C8           INY 
C1/9067: 4C 5D 90     JMP $905D
C1/906A: 7B           TDC 
C1/906B: E2 20        SEP #$20
C1/906D: AB           PLB 
C1/906E: 60           RTS 

; [ show character stats (credits) ]

C1/906F: A9 BF        LDA #$BF
C1/9071: 8D 86 BC     STA $BC86
C1/9074: A9 7E        LDA #$7E
C1/9076: 8D ED F9     STA $F9ED
C1/9079: A9 80        LDA #$80
C1/907B: 8D EE F9     STA $F9EE
C1/907E: AD 4B D0     LDA $D04B
C1/9081: 8D EF F9     STA $F9EF
C1/9084: 20 3C 8F     JSR $8F3C
C1/9087: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/908A: A9 02        LDA #$02
C1/908C: 8D A1 F9     STA $F9A1
C1/908F: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/9092: 20 3C 8F     JSR $8F3C
C1/9095: AD EE F9     LDA $F9EE
C1/9098: CD 3F D0     CMP $D03F
C1/909B: F0 06        BEQ $90A3
C1/909D: EE EE F9     INC $F9EE
C1/90A0: EE EE F9     INC $F9EE
C1/90A3: CE ED F9     DEC $F9ED
C1/90A6: AD ED F9     LDA $F9ED
C1/90A9: C9 18        CMP #$18
C1/90AB: D0 E2        BNE $908F
C1/90AD: 20 EB 36     JSR $36EB       ; decompress battle bg graphics
C1/90B0: A2 00 10     LDX #$1000
C1/90B3: 86 70        STX $70
C1/90B5: A6 72        LDX $72
C1/90B7: A0 00 78     LDY #$7800
C1/90BA: A5 74        LDA $74
C1/90BC: 20 27 FD     JSR $FD27
C1/90BF: 20 64 FC     JSR $FC64
C1/90C2: 7B           TDC 
C1/90C3: AA           TAX 
C1/90C4: BD 29 7E     LDA $7E29,X
C1/90C7: 9D 29 7F     STA $7F29,X
C1/90CA: E8           INX 
C1/90CB: E0 40 00     CPX #$0040
C1/90CE: D0 F4        BNE $90C4
C1/90D0: 20 81 94     JSR $9481
C1/90D3: A9 02        LDA #$02
C1/90D5: 8D F5 DB     STA $DBF5
C1/90D8: 20 E2 24     JSR $24E2       ; load character graphics
C1/90DB: 20 2C 96     JSR $962C
C1/90DE: A9 01        LDA #$01
C1/90E0: 8D 63 CF     STA $CF63
C1/90E3: EE FA FE     INC $FEFA
C1/90E6: 20 25 37     JSR $3725       ; load battle bg graphics
C1/90E9: A0 80 10     LDY #$1080
C1/90EC: A2 00 05     LDX #$0500
C1/90EF: 86 70        STX $70
C1/90F1: A2 00 70     LDX #$7000
C1/90F4: A9 7F        LDA #$7F
C1/90F6: 20 27 FD     JSR $FD27
C1/90F9: A9 30        LDA #$30
C1/90FB: 8F 23 21 00  STA $002123
C1/90FF: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/9102: 7B           TDC 
C1/9103: AA           TAX 
C1/9104: BF 03 77 7F  LDA $7F7703,X
C1/9108: 29 CF        AND #$CF
C1/910A: 9F 03 77 7F  STA $7F7703,X
C1/910E: E8           INX 
C1/910F: E8           INX 
C1/9110: E8           INX 
C1/9111: E8           INX 
C1/9112: E0 00 01     CPX #$0100
C1/9115: D0 ED        BNE $9104
C1/9117: A9 03        LDA #$03
C1/9119: 8D F5 DB     STA $DBF5
C1/911C: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/911F: 20 6B 94     JSR $946B
C1/9122: 90 F8        BCC $911C
C1/9124: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/9127: 20 EA 94     JSR $94EA
C1/912A: A2 00 18     LDX #$1800
C1/912D: 86 70        STX $70
C1/912F: A2 00 80     LDX #$8000
C1/9132: A0 00 60     LDY #$6000
C1/9135: A9 7F        LDA #$7F
C1/9137: 20 27 FD     JSR $FD27
C1/913A: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/913D: 7B           TDC 
C1/913E: AA           TAX 
C1/913F: A9 AA        LDA #$AA
C1/9141: 9D 00 04     STA $0400,X
C1/9144: E8           INX 
C1/9145: E0 20 00     CPX #$0020
C1/9148: D0 F7        BNE $9141
C1/914A: 7B           TDC 
C1/914B: AA           TAX 
C1/914C: BF 2B E4 D0  LDA $D0E42B,X
C1/9150: 9D 00 02     STA $0200,X
C1/9153: E8           INX 
C1/9154: E0 60 00     CPX #$0060
C1/9157: D0 F3        BNE $914C
C1/9159: A9 F0        LDA #$F0
C1/915B: 9D 00 02     STA $0200,X
C1/915E: E8           INX 
C1/915F: E0 00 02     CPX #$0200
C1/9162: D0 F7        BNE $915B
C1/9164: A9 12        LDA #$12
C1/9166: 8D FB FE     STA $FEFB
C1/9169: 7B           TDC 
C1/916A: AA           TAX 
C1/916B: 8E 77 BC     STX $BC77
C1/916E: 8E FC FE     STX $FEFC
C1/9171: 8E FE FE     STX $FEFE
C1/9174: 9C 00 FF     STZ $FF00
C1/9177: A9 01        LDA #$01
C1/9179: 8D F5 DB     STA $DBF5
C1/917C: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/917F: 20 3C 8F     JSR $8F3C
C1/9182: AD EE F9     LDA $F9EE
C1/9185: C9 80        CMP #$80
C1/9187: F0 09        BEQ $9192
C1/9189: AD EE F9     LDA $F9EE
C1/918C: 38           SEC 
C1/918D: E9 04        SBC #$04
C1/918F: 8D EE F9     STA $F9EE
C1/9192: EE ED F9     INC $F9ED
C1/9195: AD ED F9     LDA $F9ED
C1/9198: C9 7F        CMP #$7F
C1/919A: F0 0A        BEQ $91A6
C1/919C: EE ED F9     INC $F9ED
C1/919F: AD ED F9     LDA $F9ED
C1/91A2: C9 7F        CMP #$7F
C1/91A4: D0 D6        BNE $917C
C1/91A6: A9 C4        LDA #$C4
C1/91A8: 8D 84 BC     STA $BC84
C1/91AB: A0 00 80     LDY #$8000
C1/91AE: 84 70        STY $70
C1/91B0: A9 7F        LDA #$7F
C1/91B2: 85 72        STA $72
C1/91B4: A0 10 80     LDY #$8010
C1/91B7: 84 74        STY $74
C1/91B9: A9 7F        LDA #$7F
C1/91BB: 85 76        STA $76
C1/91BD: 7B           TDC 
C1/91BE: AA           TAX 
C1/91BF: C2 20        REP #$20
C1/91C1: 7B           TDC 
C1/91C2: A8           TAY 
C1/91C3: BF 00 F0 D1  LDA $D1F000,X
C1/91C7: 29 00 FF     AND #$FF00
C1/91CA: 85 7E        STA $7E
C1/91CC: EB           XBA 
C1/91CD: 4A           LSR 
C1/91CE: 05 7E        ORA $7E
C1/91D0: 97 70        STA [$70],Y
C1/91D2: 7B           TDC 
C1/91D3: 97 74        STA [$74],Y
C1/91D5: C8           INY 
C1/91D6: C8           INY 
C1/91D7: E8           INX 
C1/91D8: E8           INX 
C1/91D9: C0 10 00     CPY #$0010
C1/91DC: D0 E5        BNE $91C3
C1/91DE: 98           TYA 
C1/91DF: 18           CLC 
C1/91E0: 69 10 00     ADC #$0010
C1/91E3: A8           TAY 
C1/91E4: A5 70        LDA $70
C1/91E6: 18           CLC 
C1/91E7: 69 20 00     ADC #$0020
C1/91EA: 85 70        STA $70
C1/91EC: A5 74        LDA $74
C1/91EE: 18           CLC 
C1/91EF: 69 20 00     ADC #$0020
C1/91F2: 85 74        STA $74
C1/91F4: E0 00 10     CPX #$1000
C1/91F7: D0 C8        BNE $91C1
C1/91F9: 7B           TDC 
C1/91FA: AA           TAX 
C1/91FB: BF 00 F0 D1  LDA $D1F000,X
C1/91FF: 29 00 FF     AND #$FF00
C1/9202: 85 7E        STA $7E
C1/9204: EB           XBA 
C1/9205: 4A           LSR 
C1/9206: 05 7E        ORA $7E
C1/9208: 9F 00 C0 7F  STA $7FC000,X
C1/920C: E8           INX 
C1/920D: E8           INX 
C1/920E: E0 00 10     CPX #$1000
C1/9211: D0 E8        BNE $91FB
C1/9213: 7B           TDC 
C1/9214: E2 20        SEP #$20
C1/9216: A2 00 20     LDX #$2000
C1/9219: 86 70        STX $70
C1/921B: A2 00 80     LDX #$8000
C1/921E: A0 00 70     LDY #$7000
C1/9221: A9 7F        LDA #$7F
C1/9223: 20 27 FD     JSR $FD27
C1/9226: A2 00 10     LDX #$1000
C1/9229: 86 70        STX $70
C1/922B: A2 00 C0     LDX #$C000
C1/922E: A0 00 40     LDY #$4000
C1/9231: A9 7F        LDA #$7F
C1/9233: 20 27 FD     JSR $FD27
C1/9236: 7B           TDC 
C1/9237: AA           TAX 
C1/9238: 9D 09 7E     STA $7E09,X
C1/923B: E8           INX 
C1/923C: E0 20 00     CPX #$0020
C1/923F: D0 F7        BNE $9238
C1/9241: A2 FF 7F     LDX #$7FFF
C1/9244: 8E 0D 7E     STX $7E0D
C1/9247: 8E 0F 7E     STX $7E0F
C1/924A: 20 3E 93     JSR $933E
C1/924D: A2 00 10     LDX #$1000
C1/9250: 86 70        STX $70
C1/9252: A2 B1 BC     LDX #$BCB1
C1/9255: A0 00 58     LDY #$5800
C1/9258: A9 7E        LDA #$7E
C1/925A: 20 27 FD     JSR $FD27
C1/925D: A2 00 10     LDX #$1000
C1/9260: 86 70        STX $70
C1/9262: A2 B1 BC     LDX #$BCB1
C1/9265: A0 00 48     LDY #$4800
C1/9268: A9 7E        LDA #$7E
C1/926A: 20 27 FD     JSR $FD27
C1/926D: A9 07        LDA #$07
C1/926F: 8F 0B 21 00  STA $00210B
C1/9273: 7B           TDC 
C1/9274: AA           TAX 
C1/9275: BF 69 E1 D0  LDA $D0E169,X
C1/9279: 9D F6 DB     STA $DBF6,X
C1/927C: E8           INX 
C1/927D: E0 80 00     CPX #$0080
C1/9280: D0 F3        BNE $9275
C1/9282: 20 3E 93     JSR $933E
C1/9285: 20 AC 2D     JSR $2DAC
C1/9288: A2 00 05     LDX #$0500
C1/928B: 86 70        STX $70
C1/928D: A2 B1 BC     LDX #$BCB1
C1/9290: A0 00 58     LDY #$5800
C1/9293: A9 7E        LDA #$7E
C1/9295: 20 27 FD     JSR $FD27
C1/9298: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/929B: A2 00 01     LDX #$0100
C1/929E: 8E 79 BC     STX $BC79
C1/92A1: 7B           TDC 
C1/92A2: AA           TAX 
C1/92A3: 8E FE FE     STX $FEFE
C1/92A6: A9 17        LDA #$17
C1/92A8: 8D FB FE     STA $FEFB
C1/92AB: 20 60 93     JSR $9360
C1/92AE: 20 AC 2D     JSR $2DAC
C1/92B1: 20 AF 93     JSR $93AF
C1/92B4: 9C 32 FF     STZ $FF32
C1/92B7: 9C FA CD     STZ $CDFA
C1/92BA: 9C 03 FF     STZ $FF03
C1/92BD: 20 F2 02     JSR $02F2       ; wait one frame
C1/92C0: AD FE FE     LDA $FEFE
C1/92C3: 29 0F        AND #$0F
C1/92C5: D0 08        BNE $92CF
C1/92C7: AD 32 FF     LDA $FF32
C1/92CA: D0 03        BNE $92CF
C1/92CC: 20 1A 93     JSR $931A
C1/92CF: AE 79 BC     LDX $BC79
C1/92D2: F0 04        BEQ $92D8
C1/92D4: CA           DEX 
C1/92D5: 8E 79 BC     STX $BC79
C1/92D8: AD 32 FF     LDA $FF32
C1/92DB: D0 07        BNE $92E4
C1/92DD: AE FE FE     LDX $FEFE
C1/92E0: E8           INX 
C1/92E1: 8E FE FE     STX $FEFE
C1/92E4: A6 A2        LDX $A2
C1/92E6: E0 C4 0A     CPX #$0AC4
C1/92E9: 90 D2        BCC $92BD
C1/92EB: AE F0 04     LDX $04F0
C1/92EE: E0 B1 01     CPX #$01B1
C1/92F1: D0 26        BNE $9319
C1/92F3: 20 F2 02     JSR $02F2       ; wait one frame
C1/92F6: AE FE FE     LDX $FEFE
C1/92F9: E8           INX 
C1/92FA: 8E FE FE     STX $FEFE
C1/92FD: 8A           TXA 
C1/92FE: 29 0F        AND #$0F
C1/9300: D0 03        BNE $9305
C1/9302: 20 1A 93     JSR $931A
C1/9305: AE 79 BC     LDX $BC79
C1/9308: CA           DEX 
C1/9309: 8E 79 BC     STX $BC79
C1/930C: E0 00 FF     CPX #$FF00
C1/930F: D0 E2        BNE $92F3
C1/9311: A9 16        LDA #$16
C1/9313: 8D FB FE     STA $FEFB
C1/9316: 4C 2A EE     JMP $EE2A
C1/9319: 60           RTS 

; [  ]

C1/931A: 20 60 93     JSR $9360
C1/931D: 20 AC 2D     JSR $2DAC
C1/9320: AD 03 FF     LDA $FF03
C1/9323: 29 1F        AND #$1F
C1/9325: C2 20        REP #$20
C1/9327: 0A           ASL 
C1/9328: 0A           ASL 
C1/9329: 0A           ASL 
C1/932A: 0A           ASL 
C1/932B: 0A           ASL 
C1/932C: 0A           ASL 
C1/932D: 18           CLC 
C1/932E: 69 00 48     ADC #$4800
C1/9331: 8D 01 FF     STA $FF01
C1/9334: 7B           TDC 
C1/9335: E2 20        SEP #$20
C1/9337: EE 00 FF     INC $FF00
C1/933A: EE 03 FF     INC $FF03
C1/933D: 60           RTS 

; [  ]

C1/933E: 7B           TDC 
C1/933F: AA           TAX 
C1/9340: 9D B1 BC     STA $BCB1,X
C1/9343: E8           INX 
C1/9344: E0 00 10     CPX #$1000
C1/9347: D0 F7        BNE $9340
C1/9349: A2 F6 DB     LDX #$DBF6
C1/934C: 8E A0 BC     STX $BCA0
C1/934F: A2 B1 BC     LDX #$BCB1
C1/9352: 8E A2 BC     STX $BCA2
C1/9355: A9 20        LDA #$20
C1/9357: 8D A4 BC     STA $BCA4
C1/935A: A9 20        LDA #$20
C1/935C: 8D A5 BC     STA $BCA5
C1/935F: 60           RTS 

; [  ]

C1/9360: 7B           TDC 
C1/9361: AA           TAX 
C1/9362: 9D B1 BC     STA $BCB1,X
C1/9365: E8           INX 
C1/9366: E0 80 00     CPX #$0080
C1/9369: D0 F7        BNE $9362
C1/936B: 20 49 93     JSR $9349
C1/936E: 7B           TDC 
C1/936F: AA           TAX 
C1/9370: AD FA CD     LDA $CDFA
C1/9373: A8           TAY 
C1/9374: B9 35 B5     LDA $B535,Y
C1/9377: C9 FF        CMP #$FF
C1/9379: D0 0F        BNE $938A
C1/937B: BF D4 DB D0  LDA $D0DBD4,X
C1/937F: 9D F6 DB     STA $DBF6,X
C1/9382: E8           INX 
C1/9383: E0 10 00     CPX #$0010
C1/9386: D0 F3        BNE $937B
C1/9388: 80 21        BRA $93AB
C1/938A: C9 FE        CMP #$FE
C1/938C: D0 08        BNE $9396
C1/938E: EE 32 FF     INC $FF32
C1/9391: 9C F6 DB     STZ $DBF6
C1/9394: 80 15        BRA $93AB
C1/9396: BF 63 E1 D0  LDA $D0E163,X
C1/939A: 9D F6 DB     STA $DBF6,X
C1/939D: E8           INX 
C1/939E: E0 08 00     CPX #$0008
C1/93A1: D0 F3        BNE $9396
C1/93A3: 7B           TDC 
C1/93A4: AA           TAX 
C1/93A5: AD FA CD     LDA $CDFA
C1/93A8: 9D FA DB     STA $DBFA,X
C1/93AB: EE FA CD     INC $CDFA
C1/93AE: 60           RTS 

; [  ]

C1/93AF: 7B           TDC 
C1/93B0: AA           TAX 
C1/93B1: 9D F6 DB     STA $DBF6,X
C1/93B4: 9D 35 B5     STA $B535,X
C1/93B7: E8           INX 
C1/93B8: E0 00 02     CPX #$0200
C1/93BB: D0 F4        BNE $93B1
C1/93BD: A2 0B 09     LDX #$090B
C1/93C0: 86 70        STX $70
C1/93C2: A2 06 00     LDX #$0006
C1/93C5: 8A           TXA 
C1/93C6: 20 43 94     JSR $9443
C1/93C9: E8           INX 
C1/93CA: E0 6F 00     CPX #$006F
C1/93CD: D0 F6        BNE $93C5
C1/93CF: A2 2C 00     LDX #$002C
C1/93D2: A9 05        LDA #$05
C1/93D4: 20 2F 94     JSR $942F
C1/93D7: A2 32 00     LDX #$0032
C1/93DA: A9 05        LDA #$05
C1/93DC: 20 2F 94     JSR $942F
C1/93DF: A2 38 00     LDX #$0038
C1/93E2: A9 05        LDA #$05
C1/93E4: 20 2F 94     JSR $942F
C1/93E7: A2 3E 00     LDX #$003E
C1/93EA: A9 05        LDA #$05
C1/93EC: 20 2F 94     JSR $942F
C1/93EF: A2 44 00     LDX #$0044
C1/93F2: A9 04        LDA #$04
C1/93F4: 20 2F 94     JSR $942F
C1/93F7: A2 49 00     LDX #$0049
C1/93FA: A9 02        LDA #$02
C1/93FC: 20 2F 94     JSR $942F
C1/93FF: 7B           TDC 
C1/9400: AA           TAX 
C1/9401: A8           TAY 
C1/9402: BD 35 B5     LDA $B535,X
C1/9405: F0 05        BEQ $940C
C1/9407: 8A           TXA 
C1/9408: 99 F6 DB     STA $DBF6,Y
C1/940B: C8           INY 
C1/940C: 9E 35 B5     STZ $B535,X
C1/940F: E8           INX 
C1/9410: E0 00 02     CPX #$0200
C1/9413: D0 ED        BNE $9402
C1/9415: 7B           TDC 
C1/9416: AA           TAX 
C1/9417: BD F6 DB     LDA $DBF6,X
C1/941A: F0 09        BEQ $9425
C1/941C: 9D 35 B5     STA $B535,X
C1/941F: E8           INX 
C1/9420: E0 00 02     CPX #$0200
C1/9423: D0 F2        BNE $9417
C1/9425: A9 FF        LDA #$FF
C1/9427: 9D 3D B5     STA $B53D,X
C1/942A: 3A           DEC 
C1/942B: 9D 57 B5     STA $B557,X
C1/942E: 60           RTS 

; [  ]

C1/942F: A8           TAY 
C1/9430: BD 36 B5     LDA $B536,X
C1/9433: F0 07        BEQ $943C
C1/9435: 9E 35 B5     STZ $B535,X
C1/9438: E8           INX 
C1/9439: 88           DEY 
C1/943A: D0 F4        BNE $9430
C1/943C: 60           RTS 

; [  ]

C1/943D: DA           PHX 
C1/943E: 20 74 FC     JSR $FC74
C1/9441: FA           PLX 
C1/9442: 60           RTS 

; [  ]

C1/9443: DA           PHX 
C1/9444: 85 75        STA $75
C1/9446: 0A           ASL 
C1/9447: AA           TAX 
C1/9448: BF 01 EC D0  LDA $D0EC01,X
C1/944C: 20 3D 94     JSR $943D
C1/944F: 85 74        STA $74
C1/9451: BF 00 EC D0  LDA $D0EC00,X
C1/9455: A8           TAY 
C1/9456: B1 70        LDA ($70),Y
C1/9458: 25 74        AND $74
C1/945A: F0 0D        BEQ $9469
C1/945C: A5 75        LDA $75
C1/945E: C9 4E        CMP #$4E
C1/9460: 90 03        BCC $9465
C1/9462: 18           CLC 
C1/9463: 69 32        ADC #$32
C1/9465: AA           TAX 
C1/9466: FE 35 B5     INC $B535,X
C1/9469: FA           PLX 
C1/946A: 60           RTS 

; [  ]

C1/946B: AE 8E BC     LDX $BC8E
C1/946E: E0 40 00     CPX #$0040
C1/9471: F0 0C        BEQ $947F
C1/9473: CA           DEX 
C1/9474: CA           DEX 
C1/9475: CA           DEX 
C1/9476: CA           DEX 
C1/9477: 8E 8E BC     STX $BC8E
C1/947A: 8E 94 BC     STX $BC94
C1/947D: 18           CLC 
C1/947E: 60           RTS 
C1/947F: 38           SEC 
C1/9480: 60           RTS 

; [  ]

C1/9481: A2 EC 71     LDX #$71EC
C1/9484: 86 70        STX $70
C1/9486: A9 7F        LDA #$7F
C1/9488: 85 72        STA $72
C1/948A: 7B           TDC 
C1/948B: AA           TAX 
C1/948C: A9 B0        LDA #$B0
C1/948E: 85 7E        STA $7E
C1/9490: A9 57        LDA #$57
C1/9492: 85 80        STA $80
C1/9494: 7B           TDC 
C1/9495: A8           TAY 
C1/9496: A5 7E        LDA $7E
C1/9498: 85 82        STA $82
C1/949A: A5 82        LDA $82
C1/949C: 9F 00 77 7F  STA $7F7700,X
C1/94A0: A5 80        LDA $80
C1/94A2: 9F 01 77 7F  STA $7F7701,X
C1/94A6: B7 70        LDA [$70],Y
C1/94A8: 9F 02 77 7F  STA $7F7702,X
C1/94AC: C8           INY 
C1/94AD: B7 70        LDA [$70],Y
C1/94AF: 29 C0        AND #$C0
C1/94B1: 09 31        ORA #$31
C1/94B3: 85 74        STA $74
C1/94B5: B7 70        LDA [$70],Y
C1/94B7: 29 1C        AND #$1C
C1/94B9: 4A           LSR 
C1/94BA: 05 74        ORA $74
C1/94BC: 9F 03 77 7F  STA $7F7703,X
C1/94C0: C8           INY 
C1/94C1: E8           INX 
C1/94C2: E8           INX 
C1/94C3: E8           INX 
C1/94C4: E8           INX 
C1/94C5: A5 82        LDA $82
C1/94C7: 18           CLC 
C1/94C8: 69 08        ADC #$08
C1/94CA: 85 82        STA $82
C1/94CC: C0 10 00     CPY #$0010
C1/94CF: D0 C9        BNE $949A
C1/94D1: C2 20        REP #$20
C1/94D3: A5 70        LDA $70
C1/94D5: 18           CLC 
C1/94D6: 69 40 00     ADC #$0040
C1/94D9: 85 70        STA $70
C1/94DB: 7B           TDC 
C1/94DC: E2 20        SEP #$20
C1/94DE: A5 80        LDA $80
C1/94E0: 18           CLC 
C1/94E1: 69 08        ADC #$08
C1/94E3: 85 80        STA $80
C1/94E5: C9 97        CMP #$97
C1/94E7: D0 AB        BNE $9494
C1/94E9: 60           RTS 

; [  ]

C1/94EA: 20 E2 24     JSR $24E2       ; load character graphics
C1/94ED: 7B           TDC 
C1/94EE: AA           TAX 
C1/94EF: C2 20        REP #$20
C1/94F1: BF E1 7C D9  LDA $D97CE1,X
C1/94F5: 85 B8        STA $B8
C1/94F7: BF ED 7C D9  LDA $D97CED,X
C1/94FB: 85 82        STA $82
C1/94FD: 7B           TDC 
C1/94FE: E2 20        SEP #$20
C1/9500: DA           PHX 
C1/9501: A9 7F        LDA #$7F
C1/9503: 85 84        STA $84
C1/9505: A9 7F        LDA #$7F
C1/9507: 85 80        STA $80
C1/9509: 7B           TDC 
C1/950A: AA           TAX 
C1/950B: DA           PHX 
C1/950C: C2 20        REP #$20
C1/950E: 8A           TXA 
C1/950F: 0A           ASL 
C1/9510: AA           TAX 
C1/9511: BF F9 7C D9  LDA $D97CF9,X
C1/9515: 18           CLC 
C1/9516: 65 B8        ADC $B8
C1/9518: 85 7E        STA $7E
C1/951A: 7B           TDC 
C1/951B: E2 20        SEP #$20
C1/951D: FA           PLX 
C1/951E: 7B           TDC 
C1/951F: A8           TAY 
C1/9520: B7 82        LDA [$82],Y
C1/9522: 20 59 95     JSR $9559
C1/9525: A0 01 00     LDY #$0001
C1/9528: B7 82        LDA [$82],Y
C1/952A: 20 59 95     JSR $9559
C1/952D: A0 10 00     LDY #$0010
C1/9530: B7 82        LDA [$82],Y
C1/9532: 20 59 95     JSR $9559
C1/9535: A0 11 00     LDY #$0011
C1/9538: B7 82        LDA [$82],Y
C1/953A: 20 59 95     JSR $9559
C1/953D: C2 20        REP #$20
C1/953F: A5 82        LDA $82
C1/9541: 18           CLC 
C1/9542: 69 02 00     ADC #$0002
C1/9545: 85 82        STA $82
C1/9547: 7B           TDC 
C1/9548: E2 20        SEP #$20
C1/954A: E8           INX 
C1/954B: E0 08 00     CPX #$0008
C1/954E: D0 BB        BNE $950B
C1/9550: FA           PLX 
C1/9551: E8           INX 
C1/9552: E8           INX 
C1/9553: E0 0C 00     CPX #$000C
C1/9556: D0 97        BNE $94EF
C1/9558: 60           RTS 

; [  ]

C1/9559: 84 86        STY $86
C1/955B: 85 70        STA $70
C1/955D: A0 00 00     LDY #$0000
C1/9560: 20 81 95     JSR $9581
C1/9563: 20 A6 95     JSR $95A6
C1/9566: A0 20 00     LDY #$0020
C1/9569: 20 81 95     JSR $9581
C1/956C: 20 A6 95     JSR $95A6
C1/956F: A0 40 00     LDY #$0040
C1/9572: 20 81 95     JSR $9581
C1/9575: 20 A6 95     JSR $95A6
C1/9578: A0 60 00     LDY #$0060
C1/957B: 20 81 95     JSR $9581
C1/957E: 4C A6 95     JMP $95A6

; [  ]

C1/9581: C2 20        REP #$20
C1/9583: 98           TYA 
C1/9584: 18           CLC 
C1/9585: 65 86        ADC $86
C1/9587: A8           TAY 
C1/9588: 7B           TDC 
C1/9589: E2 20        SEP #$20
C1/958B: DA           PHX 
C1/958C: 06 70        ASL $70
C1/958E: 2A           ROL 
C1/958F: 29 01        AND #$01
C1/9591: AA           TAX 
C1/9592: BF B7 95 C1  LDA $C195B7,X
C1/9596: 85 72        STA $72
C1/9598: 06 70        ASL $70
C1/959A: 2A           ROL 
C1/959B: 29 01        AND #$01
C1/959D: AA           TAX 
C1/959E: BF B9 95 C1  LDA $C195B9,X
C1/95A2: 05 72        ORA $72
C1/95A4: FA           PLX 
C1/95A5: 60           RTS 

; [  ]

C1/95A6: 5A           PHY 
C1/95A7: 97 7E        STA [$7E],Y
C1/95A9: C8           INY 
C1/95AA: C8           INY 
C1/95AB: 97 7E        STA [$7E],Y
C1/95AD: C8           INY 
C1/95AE: C8           INY 
C1/95AF: 97 7E        STA [$7E],Y
C1/95B1: C8           INY 
C1/95B2: C8           INY 
C1/95B3: 97 7E        STA [$7E],Y
C1/95B5: 7A           PLY 
C1/95B6: 60           RTS 

; [  ]

C1/95B7: 00 F0        BRK $F0
C1/95B9: 00 0F        BRK $0F
C1/95BB: 00 F0        BRK $F0
C1/95BD: 00 0F        BRK $0F

; [  ]

C1/95BF: 7B           TDC 
C1/95C0: AA           TAX 
C1/95C1: A8           TAY 
C1/95C2: A9 08        LDA #$08
C1/95C4: 85 78        STA $78
C1/95C6: DA           PHX 
C1/95C7: BB           TYX 
C1/95C8: BF 00 D8 7F  LDA $7FD800,X
C1/95CC: 85 70        STA $70
C1/95CE: BF 01 D8 7F  LDA $7FD801,X
C1/95D2: 85 71        STA $71
C1/95D4: BF 10 D8 7F  LDA $7FD810,X
C1/95D8: 85 72        STA $72
C1/95DA: BF 11 D8 7F  LDA $7FD811,X
C1/95DE: 85 73        STA $73
C1/95E0: A9 08        LDA #$08
C1/95E2: 85 76        STA $76
C1/95E4: FA           PLX 
C1/95E5: 7B           TDC 
C1/95E6: 06 73        ASL $73
C1/95E8: 2A           ROL 
C1/95E9: 06 72        ASL $72
C1/95EB: 2A           ROL 
C1/95EC: 06 71        ASL $71
C1/95EE: 2A           ROL 
C1/95EF: 06 70        ASL $70
C1/95F1: 2A           ROL 
C1/95F2: 9F 81 E0 7F  STA $7FE081,X
C1/95F6: E8           INX 
C1/95F7: E8           INX 
C1/95F8: C6 76        DEC $76
C1/95FA: D0 E9        BNE $95E5
C1/95FC: C8           INY 
C1/95FD: C8           INY 
C1/95FE: C6 78        DEC $78
C1/9600: D0 C4        BNE $95C6
C1/9602: C2 20        REP #$20
C1/9604: 98           TYA 
C1/9605: 18           CLC 
C1/9606: 69 10 00     ADC #$0010
C1/9609: A8           TAY 
C1/960A: 7B           TDC 
C1/960B: E2 20        SEP #$20
C1/960D: C4 7E        CPY $7E
C1/960F: D0 B1        BNE $95C2
C1/9611: 7B           TDC 
C1/9612: AA           TAX 
C1/9613: 9F 01 E0 7F  STA $7FE001,X
C1/9617: E8           INX 
C1/9618: E8           INX 
C1/9619: E0 80 00     CPX #$0080
C1/961C: D0 F5        BNE $9613
C1/961E: 7B           TDC 
C1/961F: AA           TAX 
C1/9620: 9F 00 E0 7F  STA $7FE000,X
C1/9624: E8           INX 
C1/9625: E8           INX 
C1/9626: E0 00 20     CPX #$2000
C1/9629: D0 F5        BNE $9620
C1/962B: 60           RTS 

; [  ]

C1/962C: A2 C0 00     LDX #$00C0
C1/962F: 86 7E        STX $7E
C1/9631: 20 BF 95     JSR $95BF
C1/9634: A9 C0        LDA #$C0
C1/9636: 8F 1A 21 00  STA $00211A
C1/963A: A2 00 20     LDX #$2000
C1/963D: 86 70        STX $70
C1/963F: A2 00 E0     LDX #$E000
C1/9642: A0 00 10     LDY #$1000
C1/9645: A9 7F        LDA #$7F
C1/9647: 20 27 FD     JSR $FD27
C1/964A: A2 00 20     LDX #$2000
C1/964D: 86 70        STX $70
C1/964F: A2 00 E0     LDX #$E000
C1/9652: A0 00 20     LDY #$2000
C1/9655: A9 7F        LDA #$7F
C1/9657: 20 27 FD     JSR $FD27
C1/965A: A2 00 20     LDX #$2000
C1/965D: 86 70        STX $70
C1/965F: A2 00 E0     LDX #$E000
C1/9662: A0 00 30     LDY #$3000
C1/9665: A9 7F        LDA #$7F
C1/9667: 20 27 FD     JSR $FD27
C1/966A: A9 01        LDA #$01
C1/966C: 8F 00 E0 7F  STA $7FE000
C1/9670: 1A           INC 
C1/9671: 8F 02 E0 7F  STA $7FE002
C1/9675: 1A           INC 
C1/9676: 8F 00 E1 7F  STA $7FE100
C1/967A: 1A           INC 
C1/967B: 8F 02 E1 7F  STA $7FE102
C1/967F: 1A           INC 
C1/9680: 8F 00 E2 7F  STA $7FE200
C1/9684: 1A           INC 
C1/9685: 8F 02 E2 7F  STA $7FE202
C1/9689: A2 00 20     LDX #$2000
C1/968C: 86 70        STX $70
C1/968E: A2 00 E0     LDX #$E000
C1/9691: 7B           TDC 
C1/9692: A8           TAY 
C1/9693: A9 7F        LDA #$7F
C1/9695: 20 27 FD     JSR $FD27
C1/9698: 7B           TDC 
C1/9699: AA           TAX 
C1/969A: BD 96 ED     LDA $ED96,X
C1/969D: 9D 09 7E     STA $7E09,X
C1/96A0: E8           INX 
C1/96A1: E0 20 00     CPX #$0020
C1/96A4: D0 F4        BNE $969A
C1/96A6: 9C 09 7E     STZ $7E09
C1/96A9: 9C 0A 7E     STZ $7E0A
C1/96AC: A9 CC        LDA #$CC
C1/96AE: 8F 84 BC 7E  STA $7EBC84
C1/96B2: A2 24 00     LDX #$0024
C1/96B5: 8E 96 BC     STX $BC96
C1/96B8: A2 10 00     LDX #$0010
C1/96BB: 8E 98 BC     STX $BC98
C1/96BE: A2 38 FF     LDX #$FF38
C1/96C1: 8E 77 BC     STX $BC77
C1/96C4: A2 92 FF     LDX #$FF92
C1/96C7: 8E 79 BC     STX $BC79
C1/96CA: 7B           TDC 
C1/96CB: AA           TAX 
C1/96CC: 8E 90 BC     STX $BC90
C1/96CF: 8E 92 BC     STX $BC92
C1/96D2: A2 00 01     LDX #$0100
C1/96D5: 8E 8E BC     STX $BC8E
C1/96D8: 8E 94 BC     STX $BC94
C1/96DB: 9C 8C BC     STZ $BC8C
C1/96DE: 9C 85 BC     STZ $BC85
C1/96E1: A9 07        LDA #$07        ; mode 7
C1/96E3: 8D 81 BC     STA $BC81
C1/96E6: EE 8D BC     INC $BC8D
C1/96E9: 4C F2 02     JMP $02F2       ; wait one frame

; [ set attacker animation frame ]

C1/96EC: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/96EF: 99 58 CF     STA $CF58,Y
C1/96F2: 5A           PHY 
C1/96F3: DA           PHX 
C1/96F4: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/96F7: AA           TAX 
C1/96F8: BF BC DF D0  LDA $D0DFBC,X   ; 0 or 1
C1/96FC: FA           PLX 
C1/96FD: 7A           PLY 
C1/96FE: 85 70        STA $70
C1/9700: B9 56 CF     LDA $CF56,Y
C1/9703: 05 70        ORA $70
C1/9705: 99 56 CF     STA $CF56,Y
C1/9708: 60           RTS 

; [  ]

C1/9709: 20 F2 02     JSR $02F2       ; wait one frame
C1/970C: AD 53 CF     LDA $CF53
C1/970F: 0D 73 CF     ORA $CF73
C1/9712: 0D 93 CF     ORA $CF93
C1/9715: 0D B3 CF     ORA $CFB3
C1/9718: D0 EF        BNE $9709
C1/971A: 60           RTS 

; [  ]

C1/971B: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/971E: A8           TAY 
C1/971F: A9 01        LDA #$01
C1/9721: 99 D4 D1     STA $D1D4,Y
C1/9724: 60           RTS 

; [  ]

C1/9725: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9728: A8           TAY 
C1/9729: 7B           TDC 
C1/972A: 99 D4 D1     STA $D1D4,Y
C1/972D: 60           RTS 

; [ ability animation $24: hide ]

C1/972E: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9731: AA           TAX 
C1/9732: 0A           ASL 
C1/9733: 0A           ASL 
C1/9734: A8           TAY 
C1/9735: A9 80        LDA #$80
C1/9737: 85 72        STA $72
C1/9739: 20 63 97     JSR $9763
C1/973C: 20 A1 9D     JSR $9DA1
C1/973F: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9742: A9 01        LDA #$01
C1/9744: 99 43 CF     STA $CF43,Y
C1/9747: 4C 1B 97     JMP $971B

; [ ability animation $25: show ]

C1/974A: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/974D: 7B           TDC 
C1/974E: 99 43 CF     STA $CF43,Y
C1/9751: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9754: AA           TAX 
C1/9755: 0A           ASL 
C1/9756: 0A           ASL 
C1/9757: A8           TAY 
C1/9758: 64 72        STZ $72
C1/975A: 20 63 97     JSR $9763
C1/975D: 20 A1 9D     JSR $9DA1
C1/9760: 4C 25 97     JMP $9725

; [ run on/off screen ??? ]

C1/9763: B9 7E 7B     LDA $7B7E,Y
C1/9766: 29 C0        AND #$C0
C1/9768: D0 33        BNE $979D       ; branch if dead or stone
C1/976A: BD BD D1     LDA $D1BD,X
C1/976D: F0 04        BEQ $9773
C1/976F: A9 50        LDA #$50
C1/9771: 80 0B        BRA $977E
C1/9773: BD 4A DB     LDA $DB4A,X
C1/9776: F0 04        BEQ $977C
C1/9778: A9 20        LDA #$20
C1/977A: 80 02        BRA $977E
C1/977C: A9 30        LDA #$30
C1/977E: 85 70        STA $70
C1/9780: DA           PHX 
C1/9781: 8A           TXA 
C1/9782: 0A           ASL 
C1/9783: 0A           ASL 
C1/9784: 0A           ASL 
C1/9785: 0A           ASL 
C1/9786: 0A           ASL 
C1/9787: AA           TAX 
C1/9788: A5 70        LDA $70
C1/978A: 05 72        ORA $72
C1/978C: 9D 54 CF     STA $CF54,X
C1/978F: A9 02        LDA #$02
C1/9791: 9D 4D CF     STA $CF4D,X
C1/9794: A9 01        LDA #$01
C1/9796: 9D 53 CF     STA $CF53,X
C1/9799: 9E 55 CF     STZ $CF55,X
C1/979C: FA           PLX 
C1/979D: 60           RTS 

; [  ]

C1/979E: EE BB DB     INC $DBBB
C1/97A1: 20 09 97     JSR $9709
C1/97A4: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/97A7: 20 3B 8D     JSR $8D3B
C1/97AA: F0 68        BEQ $9814
C1/97AC: 20 74 8D     JSR $8D74
C1/97AF: 9C CF D1     STZ $D1CF
C1/97B2: 9C D0 D1     STZ $D1D0
C1/97B5: 9C D1 D1     STZ $D1D1
C1/97B8: 9C D2 D1     STZ $D1D2
C1/97BB: A5 DF        LDA $DF
C1/97BD: 85 74        STA $74
C1/97BF: 7B           TDC 
C1/97C0: A8           TAY 
C1/97C1: AA           TAX 
C1/97C2: 06 74        ASL $74
C1/97C4: 90 11        BCC $97D7
C1/97C6: B9 81 7B     LDA $7B81,Y
C1/97C9: 30 0C        BMI $97D7
C1/97CB: BD D4 D1     LDA $D1D4,X
C1/97CE: D0 07        BNE $97D7
C1/97D0: A9 80        LDA #$80
C1/97D2: 85 72        STA $72
C1/97D4: 20 63 97     JSR $9763
C1/97D7: E8           INX 
C1/97D8: C8           INY 
C1/97D9: C8           INY 
C1/97DA: C8           INY 
C1/97DB: C8           INY 
C1/97DC: C0 10 00     CPY #$0010
C1/97DF: D0 E1        BNE $97C2
C1/97E1: 20 F2 02     JSR $02F2       ; wait one frame
C1/97E4: A9 04        LDA #$04
C1/97E6: 85 70        STA $70
C1/97E8: 7B           TDC 
C1/97E9: AA           TAX 
C1/97EA: A8           TAY 
C1/97EB: BD 53 CF     LDA $CF53,X
C1/97EE: D0 13        BNE $9803
C1/97F0: B9 81 7B     LDA $7B81,Y
C1/97F3: 30 0C        BMI $9801
C1/97F5: B9 7E 7B     LDA $7B7E,Y
C1/97F8: 29 C0        AND #$C0
C1/97FA: D0 05        BNE $9801
C1/97FC: A9 01        LDA #$01
C1/97FE: 9D 43 CF     STA $CF43,X
C1/9801: C6 70        DEC $70
C1/9803: C8           INY 
C1/9804: C8           INY 
C1/9805: C8           INY 
C1/9806: C8           INY 
C1/9807: 8A           TXA 
C1/9808: 18           CLC 
C1/9809: 69 20        ADC #$20
C1/980B: AA           TAX 
C1/980C: C9 80        CMP #$80
C1/980E: D0 DB        BNE $97EB
C1/9810: A5 70        LDA $70
C1/9812: D0 CD        BNE $97E1
C1/9814: 60           RTS 

; [ ability animation $05: guard ]

C1/9815: 20 74 8D     JSR $8D74
C1/9818: A9 01        LDA #$01
C1/981A: 4C EC 96     JMP $96EC

; [ ability animation $29: dance ]

C1/981D: 20 74 8D     JSR $8D74
C1/9820: A9 0E        LDA #$0E
C1/9822: 20 EC 96     JSR $96EC
C1/9825: A2 40 00     LDX #$0040
C1/9828: DA           PHX 
C1/9829: 20 F2 02     JSR $02F2       ; wait one frame
C1/982C: FA           PLX 
C1/982D: 8A           TXA 
C1/982E: 29 07        AND #$07
C1/9830: D0 30        BNE $9862
C1/9832: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9835: DA           PHX 
C1/9836: 8A           TXA 
C1/9837: 4A           LSR 
C1/9838: 4A           LSR 
C1/9839: 4A           LSR 
C1/983A: 29 03        AND #$03
C1/983C: AA           TAX 
C1/983D: BF 71 98 C1  LDA $C19871,X
C1/9841: 99 57 CF     STA $CF57,Y
C1/9844: BF 75 98 C1  LDA $C19875,X
C1/9848: 85 70        STA $70
C1/984A: B9 49 CF     LDA $CF49,Y
C1/984D: 18           CLC 
C1/984E: 65 70        ADC $70
C1/9850: 99 49 CF     STA $CF49,Y
C1/9853: BF 79 98 C1  LDA $C19879,X
C1/9857: 85 70        STA $70
C1/9859: B9 56 CF     LDA $CF56,Y
C1/985C: 45 70        EOR $70
C1/985E: 99 56 CF     STA $CF56,Y
C1/9861: FA           PLX 
C1/9862: CA           DEX 
C1/9863: D0 C3        BNE $9828
C1/9865: 7B           TDC 
C1/9866: 20 EC 96     JSR $96EC
C1/9869: 7B           TDC 
C1/986A: 99 57 CF     STA $CF57,Y
C1/986D: 99 49 CF     STA $CF49,Y
C1/9870: 60           RTS 
C1/9871: 04 05        TSB $05
C1/9873: 06 07        ASL $07
C1/9875: 00 FE        BRK $FE
C1/9877: 00 02        BRK $02
C1/9879: 80 00        BRA $987B
C1/987B: 80 00        BRA $987D

; [ ability animation $28: flirt ]

C1/987D: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9880: A9 0E        LDA #$0E
C1/9882: 20 EC 96     JSR $96EC
C1/9885: 20 3C 9D     JSR $9D3C
C1/9888: A9 0B        LDA #$0B
C1/988A: 20 EC 96     JSR $96EC
C1/988D: A2 08 01     LDX #$0108
C1/9890: 20 9C B6     JSR $B69C
C1/9893: 7B           TDC 
C1/9894: 4C EC 96     JMP $96EC
C1/9897: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/989A: A9 0B        LDA #$0B
C1/989C: 20 EC 96     JSR $96EC
C1/989F: A2 0E 01     LDX #$010E
C1/98A2: 20 9C B6     JSR $B69C
C1/98A5: 7B           TDC 
C1/98A6: 4C EC 96     JMP $96EC

; [ ability animation $1C: catch ]

C1/98A9: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/98AC: A9 0B        LDA #$0B
C1/98AE: 20 EC 96     JSR $96EC
C1/98B1: A2 0B 01     LDX #$010B
C1/98B4: 20 9C B6     JSR $B69C
C1/98B7: A2 10 01     LDX #$0110
C1/98BA: 20 9C B6     JSR $B69C
C1/98BD: 7B           TDC 
C1/98BE: 4C EC 96     JMP $96EC

; [ ability animation $12: gil toss ]

C1/98C1: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/98C4: A9 0B        LDA #$0B
C1/98C6: 20 EC 96     JSR $96EC
C1/98C9: A2 0A 01     LDX #$010A
C1/98CC: 20 9C B6     JSR $B69C
C1/98CF: 7B           TDC 
C1/98D0: 4C EC 96     JMP $96EC
C1/98D3: A9 0B        LDA #$0B
C1/98D5: 20 EC 96     JSR $96EC
C1/98D8: 20 41 9D     JSR $9D41
C1/98DB: 7B           TDC 
C1/98DC: 4C EC 96     JMP $96EC

; [ ability animation $0D: dragon sword ]

C1/98DF: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/98E2: A9 0B        LDA #$0B
C1/98E4: 20 EC 96     JSR $96EC
C1/98E7: A2 09 01     LDX #$0109
C1/98EA: 20 9C B6     JSR $B69C
C1/98ED: A2 0C 01     LDX #$010C
C1/98F0: 20 9C B6     JSR $B69C
C1/98F3: 7B           TDC 
C1/98F4: 4C EC 96     JMP $96EC

; [ ability animation $1A: tame ]

C1/98F7: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/98FA: A9 0B        LDA #$0B
C1/98FC: 20 EC 96     JSR $96EC
C1/98FF: A2 BF 00     LDX #$00BF
C1/9902: 20 9C B6     JSR $B69C
C1/9905: 7B           TDC 
C1/9906: 4C EC 96     JMP $96EC

; [ ability animation $20: pray ]

C1/9909: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/990C: A9 0B        LDA #$0B
C1/990E: 20 EC 96     JSR $96EC
C1/9911: A2 D8 00     LDX #$00D8
C1/9914: 20 9C B6     JSR $B69C
C1/9917: 7B           TDC 
C1/9918: 4C EC 96     JMP $96EC

; [ ability animation $21: revive ]

C1/991B: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/991E: A9 0B        LDA #$0B
C1/9920: 20 EC 96     JSR $96EC
C1/9923: A2 19 00     LDX #$0019
C1/9926: 20 9C B6     JSR $B69C
C1/9929: 7B           TDC 
C1/992A: 4C EC 96     JMP $96EC

; [ ability animation $0E: smoke ]

C1/992D: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9930: A9 0B        LDA #$0B
C1/9932: 20 EC 96     JSR $96EC
C1/9935: 20 3B 8D     JSR $8D3B
C1/9938: F0 04        BEQ $993E
C1/993A: A5 DF        LDA $DF
C1/993C: 91 EB        STA ($EB),Y
C1/993E: 20 4D 8D     JSR $8D4D       ; get graphics script parameter 2
C1/9941: C8           INY 
C1/9942: 91 E7        STA ($E7),Y
C1/9944: A2 0B 01     LDX #$010B
C1/9947: 20 9C B6     JSR $B69C
C1/994A: 20 41 9D     JSR $9D41
C1/994D: 7B           TDC 
C1/994E: 4C EC 96     JMP $96EC

; [ ability animation $0A: steal/capture ]

C1/9951: 20 74 8D     JSR $8D74
C1/9954: 20 37 9D     JSR $9D37
C1/9957: 20 41 9D     JSR $9D41
C1/995A: A9 0B        LDA #$0B
C1/995C: 20 EC 96     JSR $96EC
C1/995F: 20 41 9D     JSR $9D41
C1/9962: 7B           TDC 
C1/9963: 4C EC 96     JMP $96EC

; [ ability animation $08: mantra ]

C1/9966: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9969: A2 11 01     LDX #$0111
C1/996C: 20 8B B5     JSR $B58B
C1/996F: A9 01        LDA #$01
C1/9971: 20 EC 96     JSR $96EC
C1/9974: 4C 3C 9D     JMP $9D3C

; [ ability animation $0F: image ]

C1/9977: 20 74 8D     JSR $8D74
C1/997A: A9 0B        LDA #$0B
C1/997C: 20 EC 96     JSR $96EC
C1/997F: 20 41 9D     JSR $9D41
C1/9982: 7B           TDC 
C1/9983: 4C EC 96     JMP $96EC

; [ ability animation $03: def ]

C1/9986: A9 01        LDA #$01
C1/9988: 4C EC 96     JMP $96EC

; [ ability animation $07: buildup ]

C1/998B: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/998E: A2 07 01     LDX #$0107
C1/9991: 20 8B B5     JSR $B58B
C1/9994: A9 01        LDA #$01
C1/9996: 20 EC 96     JSR $96EC
C1/9999: 4C 3C 9D     JMP $9D3C
C1/999C: 7B           TDC 
C1/999D: AA           TAX 
C1/999E: A9 F0        LDA #$F0
C1/99A0: 9D C9 F8     STA $F8C9,X
C1/99A3: E8           INX 
C1/99A4: E0 D8 00     CPX #$00D8
C1/99A7: D0 F7        BNE $99A0
C1/99A9: 9C 40 DB     STZ $DB40
C1/99AC: 60           RTS 

; [ ability animation $2E: interceptor rocket ]

C1/99AD: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/99B0: 20 9C 99     JSR $999C
C1/99B3: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/99B6: 8D 3F DB     STA $DB3F
C1/99B9: EE 3E DB     INC $DB3E
C1/99BC: A9 0B        LDA #$0B
C1/99BE: 20 8C 9D     JSR $9D8C
C1/99C1: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/99C4: 7B           TDC 
C1/99C5: 99 5D CF     STA $CF5D,Y
C1/99C8: 99 5E CF     STA $CF5E,Y
C1/99CB: 99 5F CF     STA $CF5F,Y
C1/99CE: 99 60 CF     STA $CF60,Y
C1/99D1: 99 46 CF     STA $CF46,Y
C1/99D4: 5A           PHY 
C1/99D5: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/99D8: 18           CLC 
C1/99D9: 69 08        ADC #$08
C1/99DB: AA           TAX 
C1/99DC: 7A           PLY 
C1/99DD: 4C 16 9A     JMP $9A16

; [ ability animation $2D: jump attack ]

C1/99E0: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/99E3: 20 9C 99     JSR $999C
C1/99E6: 20 64 FC     JSR $FC64
C1/99E9: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/99EC: 8D 3F DB     STA $DB3F
C1/99EF: EE 3E DB     INC $DB3E
C1/99F2: A9 0B        LDA #$0B
C1/99F4: 20 8C 9D     JSR $9D8C
C1/99F7: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/99FA: 7B           TDC 
C1/99FB: 99 5D CF     STA $CF5D,Y
C1/99FE: 99 5E CF     STA $CF5E,Y
C1/9A01: 99 5F CF     STA $CF5F,Y
C1/9A04: 99 60 CF     STA $CF60,Y
C1/9A07: 99 46 CF     STA $CF46,Y
C1/9A0A: 5A           PHY 
C1/9A0B: 20 74 8D     JSR $8D74
C1/9A0E: 20 35 8D     JSR $8D35       ; get target id
C1/9A11: 20 7A FC     JSR $FC7A
C1/9A14: AA           TAX 
C1/9A15: 7A           PLY 
C1/9A16: DA           PHX 
C1/9A17: BD 72 D0     LDA $D072,X
C1/9A1A: 38           SEC 
C1/9A1B: E9 18        SBC #$18
C1/9A1D: 4A           LSR 
C1/9A1E: 4A           LSR 
C1/9A1F: 4A           LSR 
C1/9A20: 4A           LSR 
C1/9A21: 85 70        STA $70
C1/9A23: 18           CLC 
C1/9A24: 7D 66 D0     ADC $D066,X
C1/9A27: 99 45 CF     STA $CF45,Y
C1/9A2A: 7B           TDC 
C1/9A2B: 99 43 CF     STA $CF43,Y
C1/9A2E: A5 70        LDA $70
C1/9A30: F0 1C        BEQ $9A4E
C1/9A32: AA           TAX 
C1/9A33: DA           PHX 
C1/9A34: 20 F2 02     JSR $02F2       ; wait one frame
C1/9A37: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9A3A: B9 45 CF     LDA $CF45,Y
C1/9A3D: 3A           DEC 
C1/9A3E: 99 45 CF     STA $CF45,Y
C1/9A41: B9 46 CF     LDA $CF46,Y
C1/9A44: 18           CLC 
C1/9A45: 69 10        ADC #$10
C1/9A47: 99 46 CF     STA $CF46,Y
C1/9A4A: FA           PLX 
C1/9A4B: CA           DEX 
C1/9A4C: D0 E5        BNE $9A33
C1/9A4E: FA           PLX 
C1/9A4F: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9A52: BD 72 D0     LDA $D072,X
C1/9A55: 38           SEC 
C1/9A56: E9 18        SBC #$18
C1/9A58: 99 46 CF     STA $CF46,Y
C1/9A5B: BD 66 D0     LDA $D066,X
C1/9A5E: 99 45 CF     STA $CF45,Y
C1/9A61: 20 74 8D     JSR $8D74
C1/9A64: 20 37 9D     JSR $9D37
C1/9A67: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9A6A: B9 56 CF     LDA $CF56,Y
C1/9A6D: 09 80        ORA #$80
C1/9A6F: 99 56 CF     STA $CF56,Y
C1/9A72: A9 0B        LDA #$0B
C1/9A74: 20 8C 9D     JSR $9D8C
C1/9A77: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9A7A: B9 45 CF     LDA $CF45,Y
C1/9A7D: 85 A6        STA $A6
C1/9A7F: B9 46 CF     LDA $CF46,Y
C1/9A82: 85 A7        STA $A7
C1/9A84: 20 8A 9A     JSR $9A8A
C1/9A87: 4C 25 97     JMP $9725
C1/9A8A: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9A8D: AA           TAX 
C1/9A8E: BD B9 F8     LDA $F8B9,X
C1/9A91: 85 A9        STA $A9
C1/9A93: BD B5 F8     LDA $F8B5,X
C1/9A96: 85 A8        STA $A8
C1/9A98: 20 6E 0A     JSR $0A6E
C1/9A9B: 20 A7 09     JSR $09A7
C1/9A9E: 7B           TDC 
C1/9A9F: AA           TAX 
C1/9AA0: A5 AE        LDA $AE
C1/9AA2: 20 96 09     JSR $0996
C1/9AA5: 9C FB CD     STZ $CDFB
C1/9AA8: 9C 3B CE     STZ $CE3B
C1/9AAB: C2 20        REP #$20
C1/9AAD: A5 AF        LDA $AF
C1/9AAF: 4A           LSR 
C1/9AB0: 85 B1        STA $B1
C1/9AB2: 4A           LSR 
C1/9AB3: 4A           LSR 
C1/9AB4: 4A           LSR 
C1/9AB5: 85 B3        STA $B3
C1/9AB7: 64 B5        STZ $B5
C1/9AB9: 7B           TDC 
C1/9ABA: E2 20        SEP #$20
C1/9ABC: 20 F2 02     JSR $02F2       ; wait one frame
C1/9ABF: 20 4B 9D     JSR $9D4B
C1/9AC2: 7B           TDC 
C1/9AC3: AA           TAX 
C1/9AC4: A9 0C        LDA #$0C
C1/9AC6: 20 B9 09     JSR $09B9
C1/9AC9: C2 20        REP #$20
C1/9ACB: A5 AF        LDA $AF
C1/9ACD: 38           SEC 
C1/9ACE: E9 0C 00     SBC #$000C
C1/9AD1: 85 AF        STA $AF
C1/9AD3: 18           CLC 
C1/9AD4: 69 0C 00     ADC #$000C
C1/9AD7: C5 B1        CMP $B1
C1/9AD9: 90 19        BCC $9AF4
C1/9ADB: A5 B5        LDA $B5
C1/9ADD: 18           CLC 
C1/9ADE: 65 B3        ADC $B3
C1/9AE0: 85 B5        STA $B5
C1/9AE2: A5 B3        LDA $B3
C1/9AE4: F0 32        BEQ $9B18
C1/9AE6: 3A           DEC 
C1/9AE7: 85 B3        STA $B3
C1/9AE9: B9 5F CF     LDA $CF5F,Y
C1/9AEC: 38           SEC 
C1/9AED: E5 B5        SBC $B5
C1/9AEF: 99 5F CF     STA $CF5F,Y
C1/9AF2: 80 24        BRA $9B18
C1/9AF4: A5 B1        LDA $B1
C1/9AF6: 4A           LSR 
C1/9AF7: 4A           LSR 
C1/9AF8: 4A           LSR 
C1/9AF9: C5 B3        CMP $B3
C1/9AFB: D0 06        BNE $9B03
C1/9AFD: 64 B3        STZ $B3
C1/9AFF: 64 B5        STZ $B5
C1/9B01: 80 0C        BRA $9B0F
C1/9B03: A5 B3        LDA $B3
C1/9B05: 1A           INC 
C1/9B06: 85 B3        STA $B3
C1/9B08: A5 B5        LDA $B5
C1/9B0A: 38           SEC 
C1/9B0B: E5 B3        SBC $B3
C1/9B0D: 85 B5        STA $B5
C1/9B0F: B9 5F CF     LDA $CF5F,Y
C1/9B12: 38           SEC 
C1/9B13: E5 B5        SBC $B5
C1/9B15: 99 5F CF     STA $CF5F,Y
C1/9B18: 7B           TDC 
C1/9B19: E2 20        SEP #$20
C1/9B1B: A5 B0        LDA $B0
C1/9B1D: 10 9D        BPL $9ABC
C1/9B1F: A5 A8        LDA $A8
C1/9B21: 99 45 CF     STA $CF45,Y
C1/9B24: A5 A9        LDA $A9
C1/9B26: 99 46 CF     STA $CF46,Y
C1/9B29: 7B           TDC 
C1/9B2A: 99 5D CF     STA $CF5D,Y
C1/9B2D: 99 5E CF     STA $CF5E,Y
C1/9B30: 99 5F CF     STA $CF5F,Y
C1/9B33: 99 60 CF     STA $CF60,Y
C1/9B36: 20 37 9D     JSR $9D37
C1/9B39: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9B3C: B9 56 CF     LDA $CF56,Y
C1/9B3F: 29 7F        AND #$7F
C1/9B41: 99 56 CF     STA $CF56,Y
C1/9B44: 7B           TDC 
C1/9B45: 20 8C 9D     JSR $9D8C
C1/9B48: 20 41 9D     JSR $9D41
C1/9B4B: 9C 3E DB     STZ $DB3E
C1/9B4E: 20 D3 67     JSR $67D3
C1/9B51: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9B54: AA           TAX 
C1/9B55: 9E CB D1     STZ $D1CB,X
C1/9B58: 4C 6D FC     JMP $FC6D
C1/9B5B: C8           INY 
C1/9B5C: D8           CLD 
C1/9B5D: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9B60: 98           TYA 
C1/9B61: 4A           LSR 
C1/9B62: 4A           LSR 
C1/9B63: 4A           LSR 
C1/9B64: 4A           LSR 
C1/9B65: 4A           LSR 
C1/9B66: AA           TAX 
C1/9B67: B9 45 CF     LDA $CF45,Y
C1/9B6A: 9D B5 F8     STA $F8B5,X
C1/9B6D: B9 46 CF     LDA $CF46,Y
C1/9B70: 9D B9 F8     STA $F8B9,X
C1/9B73: 60           RTS 

; [ ability animation $0C: jump (part 1) ]

C1/9B74: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9B77: 20 9C 99     JSR $999C
C1/9B7A: 9C 41 DB     STZ $DB41
C1/9B7D: 20 64 FC     JSR $FC64
C1/9B80: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9B83: 48           PHA 
C1/9B84: A8           TAY 
C1/9B85: A9 01        LDA #$01
C1/9B87: 99 D4 D1     STA $D1D4,Y
C1/9B8A: 68           PLA 
C1/9B8B: 8D 3F DB     STA $DB3F
C1/9B8E: A9 01        LDA #$01
C1/9B90: 8D 3E DB     STA $DB3E
C1/9B93: 20 74 8D     JSR $8D74
C1/9B96: 20 5D 9B     JSR $9B5D
C1/9B99: 20 B8 80     JSR $80B8
C1/9B9C: 20 37 9D     JSR $9D37
C1/9B9F: A9 0B        LDA #$0B
C1/9BA1: 20 8C 9D     JSR $9D8C
C1/9BA4: 20 F2 02     JSR $02F2       ; wait one frame
C1/9BA7: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9BAA: C2 20        REP #$20
C1/9BAC: B9 5D CF     LDA $CF5D,Y
C1/9BAF: 3A           DEC 
C1/9BB0: 99 5D CF     STA $CF5D,Y
C1/9BB3: 7B           TDC 
C1/9BB4: E2 20        SEP #$20
C1/9BB6: EE 41 DB     INC $DB41
C1/9BB9: EE 41 DB     INC $DB41
C1/9BBC: B9 46 CF     LDA $CF46,Y
C1/9BBF: 38           SEC 
C1/9BC0: ED 41 DB     SBC $DB41
C1/9BC3: 99 46 CF     STA $CF46,Y
C1/9BC6: C9 A0        CMP #$A0
C1/9BC8: 90 DA        BCC $9BA4
C1/9BCA: 20 F2 02     JSR $02F2       ; wait one frame
C1/9BCD: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9BD0: A9 01        LDA #$01
C1/9BD2: 99 43 CF     STA $CF43,Y
C1/9BD5: A9 20        LDA #$20
C1/9BD7: 20 41 81     JSR $8141       ; wait
C1/9BDA: 9C 3E DB     STZ $DB3E
C1/9BDD: 20 D3 67     JSR $67D3
C1/9BE0: 4C 6D FC     JMP $FC6D

; [ ability animation $13: slash ]

C1/9BE3: 20 14 8D     JSR $8D14
C1/9BE6: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9BE9: A9 01        LDA #$01
C1/9BEB: 20 8C 9D     JSR $9D8C
C1/9BEE: B9 45 CF     LDA $CF45,Y
C1/9BF1: 85 A6        STA $A6
C1/9BF3: B9 46 CF     LDA $CF46,Y
C1/9BF6: 85 A7        STA $A7
C1/9BF8: 20 5D 9B     JSR $9B5D
C1/9BFB: A9 00        LDA #$00
C1/9BFD: 85 A8        STA $A8
C1/9BFF: AD D3 DB     LDA $DBD3
C1/9C02: F0 04        BEQ $9C08
C1/9C04: A9 70        LDA #$70
C1/9C06: 80 02        BRA $9C0A
C1/9C08: A9 50        LDA #$50
C1/9C0A: 85 A9        STA $A9
C1/9C0C: 20 6E 0A     JSR $0A6E
C1/9C0F: 20 A7 09     JSR $09A7
C1/9C12: 7B           TDC 
C1/9C13: AA           TAX 
C1/9C14: A5 AE        LDA $AE
C1/9C16: 20 96 09     JSR $0996
C1/9C19: 9C FB CD     STZ $CDFB
C1/9C1C: 9C 3B CE     STZ $CE3B
C1/9C1F: 20 74 8D     JSR $8D74
C1/9C22: 20 F2 02     JSR $02F2       ; wait one frame
C1/9C25: 20 4B 9D     JSR $9D4B
C1/9C28: 7B           TDC 
C1/9C29: AA           TAX 
C1/9C2A: A9 0C        LDA #$0C
C1/9C2C: 20 B9 09     JSR $09B9
C1/9C2F: C2 20        REP #$20
C1/9C31: A5 AF        LDA $AF
C1/9C33: 38           SEC 
C1/9C34: E9 0C 00     SBC #$000C
C1/9C37: 85 AF        STA $AF
C1/9C39: 7B           TDC 
C1/9C3A: E2 20        SEP #$20
C1/9C3C: A5 B0        LDA $B0
C1/9C3E: 10 E2        BPL $9C22
C1/9C40: A2 0D 01     LDX #$010D
C1/9C43: 20 9C B6     JSR $B69C
C1/9C46: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9C49: A9 08        LDA #$08
C1/9C4B: 85 A6        STA $A6
C1/9C4D: 99 45 CF     STA $CF45,Y
C1/9C50: A9 50        LDA #$50
C1/9C52: 85 A7        STA $A7
C1/9C54: 99 46 CF     STA $CF46,Y
C1/9C57: C2 20        REP #$20
C1/9C59: 7B           TDC 
C1/9C5A: 99 5D CF     STA $CF5D,Y
C1/9C5D: 99 5F CF     STA $CF5F,Y
C1/9C60: E2 20        SEP #$20
C1/9C62: B9 56 CF     LDA $CF56,Y
C1/9C65: 09 80        ORA #$80
C1/9C67: 99 56 CF     STA $CF56,Y
C1/9C6A: A9 0B        LDA #$0B
C1/9C6C: 20 EC 96     JSR $96EC
C1/9C6F: 20 74 8D     JSR $8D74
C1/9C72: 20 8A 9A     JSR $9A8A
C1/9C75: 7B           TDC 
C1/9C76: 20 EC 96     JSR $96EC
C1/9C79: 4C 22 8D     JMP $8D22

; [ ability animation $06: kick ]

C1/9C7C: 20 14 8D     JSR $8D14       ; show character in ready stance
C1/9C7F: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9C82: 20 37 9D     JSR $9D37       ; 
C1/9C85: A9 0F        LDA #$0F
C1/9C87: 20 8C 9D     JSR $9D8C
C1/9C8A: 20 74 8D     JSR $8D74
C1/9C8D: B9 45 CF     LDA $CF45,Y
C1/9C90: 85 A6        STA $A6
C1/9C92: B9 46 CF     LDA $CF46,Y
C1/9C95: 85 A7        STA $A7
C1/9C97: A9 08        LDA #$08
C1/9C99: 85 A8        STA $A8
C1/9C9B: A9 50        LDA #$50
C1/9C9D: 85 A9        STA $A9
C1/9C9F: 20 6E 0A     JSR $0A6E
C1/9CA2: 20 A7 09     JSR $09A7
C1/9CA5: 7B           TDC 
C1/9CA6: AA           TAX 
C1/9CA7: A5 AE        LDA $AE
C1/9CA9: 20 96 09     JSR $0996
C1/9CAC: 9C FB CD     STZ $CDFB
C1/9CAF: 9C 3B CE     STZ $CE3B
C1/9CB2: A6 AF        LDX $AF
C1/9CB4: DA           PHX 
C1/9CB5: 20 F2 02     JSR $02F2       ; wait one frame
C1/9CB8: 20 4B 9D     JSR $9D4B
C1/9CBB: 7B           TDC 
C1/9CBC: AA           TAX 
C1/9CBD: A9 0C        LDA #$0C
C1/9CBF: 20 B9 09     JSR $09B9
C1/9CC2: C2 20        REP #$20
C1/9CC4: A5 AF        LDA $AF
C1/9CC6: 38           SEC 
C1/9CC7: E9 0C 00     SBC #$000C
C1/9CCA: 85 AF        STA $AF
C1/9CCC: 7B           TDC 
C1/9CCD: E2 20        SEP #$20
C1/9CCF: A5 B0        LDA $B0
C1/9CD1: 10 E2        BPL $9CB5
C1/9CD3: 20 37 9D     JSR $9D37
C1/9CD6: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9CD9: B9 56 CF     LDA $CF56,Y
C1/9CDC: 09 80        ORA #$80
C1/9CDE: 99 56 CF     STA $CF56,Y
C1/9CE1: 20 37 9D     JSR $9D37
C1/9CE4: A9 0F        LDA #$0F
C1/9CE6: 20 8C 9D     JSR $9D8C
C1/9CE9: FA           PLX 
C1/9CEA: 86 B1        STX $B1
C1/9CEC: 20 F2 02     JSR $02F2       ; wait one frame
C1/9CEF: 20 4B 9D     JSR $9D4B
C1/9CF2: 7B           TDC 
C1/9CF3: AA           TAX 
C1/9CF4: A9 F4        LDA #$F4
C1/9CF6: 20 B9 09     JSR $09B9
C1/9CF9: C2 20        REP #$20
C1/9CFB: A5 AF        LDA $AF
C1/9CFD: 18           CLC 
C1/9CFE: 69 0C 00     ADC #$000C
C1/9D01: 85 AF        STA $AF
C1/9D03: C5 B1        CMP $B1
C1/9D05: F0 05        BEQ $9D0C
C1/9D07: 7B           TDC 
C1/9D08: E2 20        SEP #$20
C1/9D0A: 80 E0        BRA $9CEC
C1/9D0C: 7B           TDC 
C1/9D0D: E2 20        SEP #$20
C1/9D0F: 20 F2 02     JSR $02F2       ; wait one frame
C1/9D12: 20 4B 9D     JSR $9D4B
C1/9D15: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9D18: 7B           TDC 
C1/9D19: 99 5D CF     STA $CF5D,Y
C1/9D1C: 99 5E CF     STA $CF5E,Y
C1/9D1F: 99 5F CF     STA $CF5F,Y
C1/9D22: 99 60 CF     STA $CF60,Y
C1/9D25: B9 56 CF     LDA $CF56,Y
C1/9D28: 29 7F        AND #$7F
C1/9D2A: 99 56 CF     STA $CF56,Y
C1/9D2D: 20 37 9D     JSR $9D37
C1/9D30: 7B           TDC 
C1/9D31: 20 8C 9D     JSR $9D8C
C1/9D34: 4C 22 8D     JMP $8D22

C1/9D37: A9 03        LDA #$03
C1/9D39: 20 8C 9D     JSR $9D8C
C1/9D3C: A9 08        LDA #$08
C1/9D3E: 4C 41 81     JMP $8141       ; wait

C1/9D41: A9 10        LDA #$10
C1/9D43: 4C 41 81     JMP $8141       ; wait

C1/9D46: A9 3C        LDA #$3C
C1/9D48: 4C 41 81     JMP $8141       ; wait

C1/9D4B: AD 3B CE     LDA $CE3B
C1/9D4E: 85 80        STA $80
C1/9D50: 64 81        STZ $81
C1/9D52: AD BB CE     LDA $CEBB
C1/9D55: 20 59 0B     JSR $0B59
C1/9D58: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9D5B: C2 20        REP #$20
C1/9D5D: A5 84        LDA $84
C1/9D5F: 99 5D CF     STA $CF5D,Y
C1/9D62: 7B           TDC 
C1/9D63: E2 20        SEP #$20
C1/9D65: AD FB CD     LDA $CDFB
C1/9D68: 85 80        STA $80
C1/9D6A: 64 81        STZ $81
C1/9D6C: AD 7B CE     LDA $CE7B
C1/9D6F: 20 59 0B     JSR $0B59
C1/9D72: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9D75: C2 20        REP #$20
C1/9D77: A5 84        LDA $84
C1/9D79: 99 5F CF     STA $CF5F,Y
C1/9D7C: 7B           TDC 
C1/9D7D: E2 20        SEP #$20
C1/9D7F: 60           RTS 

; [ get pointer to character graphics properties ]

C1/9D80: 48           PHA 
C1/9D81: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9D84: 0A           ASL 
C1/9D85: 0A           ASL 
C1/9D86: 0A           ASL 
C1/9D87: 0A           ASL 
C1/9D88: 0A           ASL 
C1/9D89: A8           TAY 
C1/9D8A: 68           PLA 
C1/9D8B: 60           RTS 

; [  ]

C1/9D8C: 20 80 9D     JSR $9D80       ; get pointer to character graphics properties
C1/9D8F: 99 58 CF     STA $CF58,Y
C1/9D92: 60           RTS 

; [ wait for damage numerals ]

C1/9D93: AD 14 D1     LDA $D114
C1/9D96: 0D 16 D1     ORA $D116
C1/9D99: F0 05        BEQ $9DA0
C1/9D9B: 20 F2 02     JSR $02F2       ; wait one frame
C1/9D9E: 80 F3        BRA $9D93
C1/9DA0: 60           RTS 

C1/9DA1: 20 F2 02     JSR $02F2       ; wait one frame
C1/9DA4: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9DA7: 0A           ASL 
C1/9DA8: 0A           ASL 
C1/9DA9: 0A           ASL 
C1/9DAA: 0A           ASL 
C1/9DAB: 0A           ASL 
C1/9DAC: A8           TAY 
C1/9DAD: B9 53 CF     LDA $CF53,Y
C1/9DB0: D0 EF        BNE $9DA1
C1/9DB2: 60           RTS 
C1/9DB3: DA           PHX 
C1/9DB4: A5 7E        LDA $7E
C1/9DB6: 48           PHA 
C1/9DB7: 20 F2 02     JSR $02F2       ; wait one frame
C1/9DBA: 68           PLA 
C1/9DBB: 85 7E        STA $7E
C1/9DBD: FA           PLX 
C1/9DBE: 8A           TXA 
C1/9DBF: 0A           ASL 
C1/9DC0: 0A           ASL 
C1/9DC1: 0A           ASL 
C1/9DC2: 0A           ASL 
C1/9DC3: 0A           ASL 
C1/9DC4: A8           TAY 
C1/9DC5: B9 53 CF     LDA $CF53,Y
C1/9DC8: D0 E9        BNE $9DB3
C1/9DCA: 60           RTS 

; [  ]

C1/9DCB: 20 3B 8D     JSR $8D3B
C1/9DCE: 85 7E        STA $7E
C1/9DD0: 7B           TDC 
C1/9DD1: AA           TAX 
C1/9DD2: 06 7E        ASL $7E
C1/9DD4: 90 2B        BCC $9E01
C1/9DD6: BD D4 D1     LDA $D1D4,X
C1/9DD9: D0 1E        BNE $9DF9
C1/9DDB: 20 B3 9D     JSR $9DB3
C1/9DDE: BD BD D1     LDA $D1BD,X
C1/9DE1: 1D CB D1     ORA $D1CB,X
C1/9DE4: D0 13        BNE $9DF9
C1/9DE6: BD 4A DB     LDA $DB4A,X
C1/9DE9: F0 16        BEQ $9E01
C1/9DEB: A9 10        LDA #$10
C1/9DED: 99 54 CF     STA $CF54,Y
C1/9DF0: A9 02        LDA #$02
C1/9DF2: 99 4D CF     STA $CF4D,Y
C1/9DF5: 3A           DEC 
C1/9DF6: 99 53 CF     STA $CF53,Y
C1/9DF9: BD 4A DB     LDA $DB4A,X
C1/9DFC: F0 03        BEQ $9E01
C1/9DFE: 9E 4A DB     STZ $DB4A,X
C1/9E01: E8           INX 
C1/9E02: E0 04 00     CPX #$0004
C1/9E05: D0 CB        BNE $9DD2
C1/9E07: 4C 09 97     JMP $9709
C1/9E0A: 20 3B 8D     JSR $8D3B
C1/9E0D: 85 7E        STA $7E
C1/9E0F: 7B           TDC 
C1/9E10: AA           TAX 
C1/9E11: 06 7E        ASL $7E
C1/9E13: 90 2F        BCC $9E44
C1/9E15: BD D4 D1     LDA $D1D4,X
C1/9E18: D0 22        BNE $9E3C
C1/9E1A: 20 B3 9D     JSR $9DB3
C1/9E1D: BD BD D1     LDA $D1BD,X
C1/9E20: 1D CB D1     ORA $D1CB,X
C1/9E23: D0 17        BNE $9E3C
C1/9E25: BD 4A DB     LDA $DB4A,X
C1/9E28: F0 04        BEQ $9E2E
C1/9E2A: A9 10        LDA #$10
C1/9E2C: 80 02        BRA $9E30
C1/9E2E: A9 90        LDA #$90
C1/9E30: 99 54 CF     STA $CF54,Y
C1/9E33: A9 02        LDA #$02
C1/9E35: 99 4D CF     STA $CF4D,Y
C1/9E38: 3A           DEC 
C1/9E39: 99 53 CF     STA $CF53,Y
C1/9E3C: BD 4A DB     LDA $DB4A,X
C1/9E3F: 49 01        EOR #$01
C1/9E41: 9D 4A DB     STA $DB4A,X
C1/9E44: E8           INX 
C1/9E45: E0 04 00     CPX #$0004
C1/9E48: D0 C7        BNE $9E11
C1/9E4A: 4C 09 97     JMP $9709

; [ ability animation $02: row ]

C1/9E4D: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9E50: AA           TAX 
C1/9E51: BD D4 D1     LDA $D1D4,X
C1/9E54: D0 28        BNE $9E7E
C1/9E56: 20 A1 9D     JSR $9DA1
C1/9E59: 5A           PHY 
C1/9E5A: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9E5D: AA           TAX 
C1/9E5E: 7A           PLY 
C1/9E5F: BD BD D1     LDA $D1BD,X
C1/9E62: 1D CB D1     ORA $D1CB,X
C1/9E65: D0 17        BNE $9E7E
C1/9E67: BD 4A DB     LDA $DB4A,X
C1/9E6A: F0 04        BEQ $9E70
C1/9E6C: A9 10        LDA #$10
C1/9E6E: 80 02        BRA $9E72
C1/9E70: A9 90        LDA #$90
C1/9E72: 99 54 CF     STA $CF54,Y
C1/9E75: A9 02        LDA #$02
C1/9E77: 99 4D CF     STA $CF4D,Y
C1/9E7A: 3A           DEC 
C1/9E7B: 99 53 CF     STA $CF53,Y
C1/9E7E: BD 4A DB     LDA $DB4A,X
C1/9E81: 49 01        EOR #$01
C1/9E83: 9D 4A DB     STA $DB4A,X
C1/9E86: 4C A1 9D     JMP $9DA1
C1/9E89: DA           PHX 
C1/9E8A: 5A           PHY 
C1/9E8B: B2 EB        LDA ($EB)
C1/9E8D: 29 40        AND #$40
C1/9E8F: D0 44        BNE $9ED5
C1/9E91: 20 35 8D     JSR $8D35       ; get target id
C1/9E94: 20 7A FC     JSR $FC7A
C1/9E97: 0A           ASL 
C1/9E98: 0A           ASL 
C1/9E99: 0A           ASL 
C1/9E9A: 0A           ASL 
C1/9E9B: 0A           ASL 
C1/9E9C: AA           TAX 
C1/9E9D: B2 EB        LDA ($EB)
C1/9E9F: 29 10        AND #$10
C1/9EA1: F0 04        BEQ $9EA7       ; branch if no crit flash
C1/9EA3: A9 10        LDA #$10
C1/9EA5: 80 02        BRA $9EA9
C1/9EA7: A9 08        LDA #$08
C1/9EA9: 85 70        STA $70
C1/9EAB: BD 58 CF     LDA $CF58,X
C1/9EAE: 48           PHA 
C1/9EAF: A5 70        LDA $70
C1/9EB1: 48           PHA 
C1/9EB2: BD 49 CF     LDA $CF49,X
C1/9EB5: 18           CLC 
C1/9EB6: 65 70        ADC $70
C1/9EB8: 9D 49 CF     STA $CF49,X
C1/9EBB: A9 07        LDA #$07
C1/9EBD: 9D 58 CF     STA $CF58,X
C1/9EC0: DA           PHX 
C1/9EC1: 20 41 9D     JSR $9D41
C1/9EC4: FA           PLX 
C1/9EC5: 68           PLA 
C1/9EC6: 85 70        STA $70
C1/9EC8: BD 49 CF     LDA $CF49,X
C1/9ECB: 38           SEC 
C1/9ECC: E5 70        SBC $70
C1/9ECE: 9D 49 CF     STA $CF49,X
C1/9ED1: 68           PLA 
C1/9ED2: 9D 58 CF     STA $CF58,X
C1/9ED5: 7A           PLY 
C1/9ED6: FA           PLX 
C1/9ED7: 60           RTS 

; [  ]

C1/9ED8: C9 09        CMP #$09
C1/9EDA: F0 05        BEQ $9EE1
C1/9EDC: C9 11        CMP #$11
C1/9EDE: F0 01        BEQ $9EE1
C1/9EE0: 60           RTS 
C1/9EE1: A2 19 01     LDX #$0119
C1/9EE4: 4C 9C B6     JMP $B69C
C1/9EE7: 0A           ASL 
C1/9EE8: AA           TAX 
C1/9EE9: C2 20        REP #$20
C1/9EEB: BF 44 DF D0  LDA $D0DF44,X
C1/9EEF: AA           TAX 
C1/9EF0: 7B           TDC 
C1/9EF1: E2 20        SEP #$20
C1/9EF3: 4C 8B B5     JMP $B58B

; [ ability animation $10: throw ]

C1/9EF6: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9EF9: AD 63 7C     LDA $7C63
C1/9EFC: C9 5A        CMP #$5A
C1/9EFE: F0 13        BEQ $9F13
C1/9F00: C9 5B        CMP #$5B
C1/9F02: F0 0F        BEQ $9F13
C1/9F04: A9 0B        LDA #$0B
C1/9F06: 20 EC 96     JSR $96EC
C1/9F09: A2 0F 01     LDX #$010F
C1/9F0C: 20 9C B6     JSR $B69C
C1/9F0F: 7B           TDC 
C1/9F10: 4C EC 96     JMP $96EC
C1/9F13: 20 14 8D     JSR $8D14
C1/9F16: 9C D3 D1     STZ $D1D3
C1/9F19: 64 71        STZ $71
C1/9F1B: 64 70        STZ $70
C1/9F1D: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9F20: 0A           ASL 
C1/9F21: 0A           ASL 
C1/9F22: A8           TAY 
C1/9F23: B9 7E 7B     LDA $7B7E,Y
C1/9F26: 29 30        AND #$30
C1/9F28: F0 08        BEQ $9F32
C1/9F2A: A9 02        LDA #$02
C1/9F2C: 8D D3 D1     STA $D1D3
C1/9F2F: 7B           TDC 
C1/9F30: 80 03        BRA $9F35
C1/9F32: AD 63 7C     LDA $7C63
C1/9F35: 20 FC A8     JSR $A8FC
C1/9F38: AD 82 F5     LDA $F582
C1/9F3B: 8D BC D1     STA $D1BC
C1/9F3E: 20 12 A1     JSR $A112
C1/9F41: 4C 22 8D     JMP $8D22

; [ ability animation $04: fight ]

C1/9F44: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/9F47: B2 EB        LDA ($EB)
C1/9F49: 30 0F        BMI $9F5A       ; branch if attacker is a monster
C1/9F4B: 20 14 8D     JSR $8D14
C1/9F4E: 20 53 8D     JSR $8D53       ; get graphics script parameter 4
C1/9F51: 29 7F        AND #$7F
C1/9F53: F0 05        BEQ $9F5A
C1/9F55: 3A           DEC 
C1/9F56: AA           TAX 
C1/9F57: 20 E7 9E     JSR $9EE7
C1/9F5A: B2 EB        LDA ($EB)
C1/9F5C: 10 29        BPL $9F87
C1/9F5E: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9F61: 29 07        AND #$07
C1/9F63: 0A           ASL 
C1/9F64: AA           TAX 
C1/9F65: C2 20        REP #$20
C1/9F67: BF D1 7C D9  LDA $D97CD1,X
C1/9F6B: 85 7E        STA $7E
C1/9F6D: 7B           TDC 
C1/9F6E: E2 20        SEP #$20
C1/9F70: 20 53 8D     JSR $8D53       ; get graphics script parameter 4
C1/9F73: 30 05        BMI $9F7A
C1/9F75: A0 13 00     LDY #$0013
C1/9F78: 80 03        BRA $9F7D
C1/9F7A: A0 14 00     LDY #$0014
C1/9F7D: A9 01        LDA #$01
C1/9F7F: 8D D3 D1     STA $D1D3
C1/9F82: B1 7E        LDA ($7E),Y
C1/9F84: 4C BA 9F     JMP $9FBA
C1/9F87: 9C D3 D1     STZ $D1D3
C1/9F8A: 64 71        STZ $71
C1/9F8C: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9F8F: 0A           ASL 
C1/9F90: 0A           ASL 
C1/9F91: A8           TAY 
C1/9F92: B9 7E 7B     LDA $7B7E,Y
C1/9F95: 29 30        AND #$30
C1/9F97: F0 09        BEQ $9FA2
C1/9F99: A9 02        LDA #$02
C1/9F9B: 8D D3 D1     STA $D1D3
C1/9F9E: 7B           TDC 
C1/9F9F: 4C BA 9F     JMP $9FBA
C1/9FA2: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9FA5: AA           TAX 
C1/9FA6: BF 84 FF CE  LDA $CEFF84,X
C1/9FAA: AA           TAX 
C1/9FAB: 20 53 8D     JSR $8D53       ; get graphics script parameter 4
C1/9FAE: 30 05        BMI $9FB5
C1/9FB0: BD AC 37     LDA $37AC,X
C1/9FB3: 80 05        BRA $9FBA
C1/9FB5: E6 71        INC $71
C1/9FB7: BD AD 37     LDA $37AD,X
C1/9FBA: 48           PHA 
C1/9FBB: B2 EB        LDA ($EB)
C1/9FBD: 29 10        AND #$10
C1/9FBF: 85 70        STA $70         ; crit flash
C1/9FC1: 68           PLA 
C1/9FC2: 20 FC A8     JSR $A8FC
C1/9FC5: AD 82 F5     LDA $F582
C1/9FC8: 8D BC D1     STA $D1BC
C1/9FCB: 20 12 A1     JSR $A112
C1/9FCE: B2 EB        LDA ($EB)
C1/9FD0: 30 0C        BMI $9FDE
C1/9FD2: 20 53 8D     JSR $8D53       ; get graphics script parameter 4
C1/9FD5: 29 7F        AND #$7F
C1/9FD7: F0 05        BEQ $9FDE
C1/9FD9: 3A           DEC 
C1/9FDA: AA           TAX 
C1/9FDB: 20 D8 9E     JSR $9ED8
C1/9FDE: B2 EB        LDA ($EB)
C1/9FE0: 30 03        BMI $9FE5
C1/9FE2: 20 22 8D     JSR $8D22
C1/9FE5: DA           PHX 
C1/9FE6: A6 F0        LDX $F0
C1/9FE8: E8           INX 
C1/9FE9: 86 F0        STX $F0
C1/9FEB: FA           PLX 
C1/9FEC: 60           RTS 

; [  ]

C1/9FED: 5A           PHY 
C1/9FEE: A5 70        LDA $70
C1/9FF0: 48           PHA 
C1/9FF1: B2 EB        LDA ($EB)
C1/9FF3: 10 03        BPL $9FF8
C1/9FF5: 7B           TDC 
C1/9FF6: 80 02        BRA $9FFA
C1/9FF8: A9 08        LDA #$08
C1/9FFA: 85 70        STA $70
C1/9FFC: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/9FFF: 18           CLC 
C1/A000: 65 70        ADC $70
C1/A002: A8           TAY 
C1/A003: B9 36 D0     LDA $D036,Y
C1/A006: 8D A9 D1     STA $D1A9
C1/A009: B9 42 D0     LDA $D042,Y
C1/A00C: 8D AA D1     STA $D1AA
C1/A00F: 9C A4 D1     STZ $D1A4
C1/A012: 9C A5 D1     STZ $D1A5
C1/A015: 68           PLA 
C1/A016: 85 70        STA $70
C1/A018: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/A01B: 7A           PLY 
C1/A01C: 60           RTS 

; [  ]

C1/A01D: 5A           PHY 
C1/A01E: DA           PHX 
C1/A01F: A6 70        LDX $70
C1/A021: DA           PHX 
C1/A022: B2 EB        LDA ($EB)
C1/A024: 29 40        AND #$40
C1/A026: F0 03        BEQ $A02B
C1/A028: 7B           TDC 
C1/A029: 80 02        BRA $A02D
C1/A02B: A9 08        LDA #$08
C1/A02D: 85 70        STA $70
C1/A02F: 64 71        STZ $71
C1/A031: A0 06 00     LDY #$0006
C1/A034: B1 EB        LDA ($EB),Y
C1/A036: F0 08        BEQ $A040
C1/A038: 48           PHA 
C1/A039: A9 10        LDA #$10
C1/A03B: 85 71        STA $71
C1/A03D: 68           PLA 
C1/A03E: 80 03        BRA $A043
C1/A040: 20 35 8D     JSR $8D35       ; get target id
C1/A043: 20 7A FC     JSR $FC7A
C1/A046: 18           CLC 
C1/A047: 65 70        ADC $70
C1/A049: A8           TAY 
C1/A04A: B9 36 D0     LDA $D036,Y
C1/A04D: 38           SEC 
C1/A04E: E5 71        SBC $71
C1/A050: 8D B7 D1     STA $D1B7
C1/A053: B9 42 D0     LDA $D042,Y
C1/A056: 8D B8 D1     STA $D1B8
C1/A059: 9C B2 D1     STZ $D1B2
C1/A05C: 9C B3 D1     STZ $D1B3
C1/A05F: FA           PLX 
C1/A060: 86 70        STX $70
C1/A062: FA           PLX 
C1/A063: 7A           PLY 
C1/A064: 60           RTS 

; [  ]

C1/A065: 5A           PHY 
C1/A066: 20 3B 8D     JSR $8D3B
C1/A069: 12 F0        ORA ($F0)       ; block type
C1/A06B: F0 03        BEQ $A070
C1/A06D: 7A           PLY 
C1/A06E: 38           SEC 
C1/A06F: 60           RTS 
C1/A070: 7A           PLY 
C1/A071: 18           CLC 
C1/A072: 60           RTS 

; [  ]

C1/A073: DA           PHX 
C1/A074: A0 06 00     LDY #$0006
C1/A077: B1 EB        LDA ($EB),Y
C1/A079: F0 0F        BEQ $A08A
C1/A07B: 20 A4 A0     JSR $A0A4
C1/A07E: AD 70 F8     LDA $F870
C1/A081: 9D 45 CF     STA $CF45,X
C1/A084: AD 71 F8     LDA $F871
C1/A087: 9D 46 CF     STA $CF46,X
C1/A08A: FA           PLX 
C1/A08B: AD BC D1     LDA $D1BC
C1/A08E: 29 0F        AND #$0F
C1/A090: C9 01        CMP #$01
C1/A092: F0 0F        BEQ $A0A3
C1/A094: B2 EB        LDA ($EB)
C1/A096: 29 40        AND #$40
C1/A098: D0 09        BNE $A0A3
C1/A09A: 20 A4 A0     JSR $A0A4
C1/A09D: AD 72 F8     LDA $F872
C1/A0A0: 9D 58 CF     STA $CF58,X
C1/A0A3: 60           RTS 

; [  ]

C1/A0A4: 20 35 8D     JSR $8D35       ; get target id
C1/A0A7: 20 7A FC     JSR $FC7A
C1/A0AA: 0A           ASL 
C1/A0AB: 0A           ASL 
C1/A0AC: 0A           ASL 
C1/A0AD: 0A           ASL 
C1/A0AE: 0A           ASL 
C1/A0AF: AA           TAX 
C1/A0B0: 60           RTS 
C1/A0B1: DA           PHX 
C1/A0B2: AD BC D1     LDA $D1BC
C1/A0B5: 29 0F        AND #$0F
C1/A0B7: C9 01        CMP #$01
C1/A0B9: F0 19        BEQ $A0D4
C1/A0BB: B2 EB        LDA ($EB)
C1/A0BD: 29 40        AND #$40
C1/A0BF: D0 13        BNE $A0D4
C1/A0C1: 20 A4 A0     JSR $A0A4
C1/A0C4: BD 58 CF     LDA $CF58,X
C1/A0C7: 8D 72 F8     STA $F872
C1/A0CA: 20 3B 8D     JSR $8D3B
C1/A0CD: F0 05        BEQ $A0D4
C1/A0CF: A9 07        LDA #$07
C1/A0D1: 9D 58 CF     STA $CF58,X
C1/A0D4: FA           PLX 
C1/A0D5: 60           RTS 
C1/A0D6: DA           PHX 
C1/A0D7: A0 06 00     LDY #$0006
C1/A0DA: B1 EB        LDA ($EB),Y
C1/A0DC: F0 32        BEQ $A110
C1/A0DE: 20 7A FC     JSR $FC7A
C1/A0E1: 0A           ASL 
C1/A0E2: 0A           ASL 
C1/A0E3: 0A           ASL 
C1/A0E4: 0A           ASL 
C1/A0E5: 0A           ASL 
C1/A0E6: AA           TAX 
C1/A0E7: BD 45 CF     LDA $CF45,X
C1/A0EA: 85 70        STA $70
C1/A0EC: BD 46 CF     LDA $CF46,X
C1/A0EF: 85 71        STA $71
C1/A0F1: 20 A4 A0     JSR $A0A4
C1/A0F4: BD 45 CF     LDA $CF45,X
C1/A0F7: 8D 70 F8     STA $F870
C1/A0FA: BD 46 CF     LDA $CF46,X
C1/A0FD: 8D 71 F8     STA $F871
C1/A100: A5 70        LDA $70
C1/A102: 38           SEC 
C1/A103: E9 10        SBC #$10
C1/A105: 9D 45 CF     STA $CF45,X
C1/A108: A5 71        LDA $71
C1/A10A: 9D 46 CF     STA $CF46,X
C1/A10D: 20 41 9D     JSR $9D41
C1/A110: FA           PLX 
C1/A111: 60           RTS 

; [  ]

C1/A112: A9 02        LDA #$02
C1/A114: 8D 84 D1     STA $D184
C1/A117: 8D 85 D1     STA $D185
C1/A11A: A9 D9        LDA #$D9
C1/A11C: 8D 88 D1     STA $D188
C1/A11F: AD 86 F5     LDA $F586
C1/A122: 0A           ASL 
C1/A123: AA           TAX 
C1/A124: BF 34 9E D9  LDA $D99E34,X
C1/A128: 8D 86 D1     STA $D186
C1/A12B: BF 35 9E D9  LDA $D99E35,X
C1/A12F: 8D 87 D1     STA $D187
C1/A132: A9 04        LDA #$04
C1/A134: 8D 92 D1     STA $D192
C1/A137: 8D 93 D1     STA $D193
C1/A13A: A9 D9        LDA #$D9        ; animation graphics bank
C1/A13C: 8D 96 D1     STA $D196
C1/A13F: AD 85 F5     LDA $F585
C1/A142: 0A           ASL 
C1/A143: AA           TAX 
C1/A144: BF 94 9E D9  LDA $D99E94,X
C1/A148: 8D 94 D1     STA $D194
C1/A14B: BF 95 9E D9  LDA $D99E95,X
C1/A14F: 8D 95 D1     STA $D195
C1/A152: 9C AB D1     STZ $D1AB
C1/A155: 9C AC D1     STZ $D1AC
C1/A158: 9C B9 D1     STZ $D1B9
C1/A15B: 9C BA D1     STZ $D1BA
C1/A15E: 9C A8 D1     STZ $D1A8
C1/A161: 9C B6 D1     STZ $D1B6
C1/A164: 9C BB D1     STZ $D1BB
C1/A167: 9C C9 D1     STZ $D1C9
C1/A16A: 9C CA D1     STZ $D1CA
C1/A16D: B2 EB        LDA ($EB)
C1/A16F: 29 10        AND #$10
C1/A171: F0 03        BEQ $A176       ; branch if no crit flash
C1/A173: 20 F5 78     JSR $78F5       ; flash screen
C1/A176: 20 B1 A0     JSR $A0B1
C1/A179: 20 65 A0     JSR $A065
C1/A17C: B0 04        BCS $A182
C1/A17E: A9 49        LDA #$49
C1/A180: 80 03        BRA $A185
C1/A182: AD 83 F5     LDA $F583       ; animation sound effect
C1/A185: 20 E4 FB     JSR $FBE4       ; play animation sound effect
C1/A188: B2 EB        LDA ($EB)
C1/A18A: 10 16        BPL $A1A2
C1/A18C: 20 D6 A0     JSR $A0D6
C1/A18F: A9 40        LDA #$40
C1/A191: 8D A8 D1     STA $D1A8
C1/A194: 8D B6 D1     STA $D1B6
C1/A197: B2 EB        LDA ($EB)
C1/A199: 29 40        AND #$40
C1/A19B: F0 50        BEQ $A1ED
C1/A19D: EE C9 D1     INC $D1C9
C1/A1A0: 80 4B        BRA $A1ED
C1/A1A2: 20 D6 A0     JSR $A0D6
C1/A1A5: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/A1A8: 29 03        AND #$03
C1/A1AA: 85 70        STA $70
C1/A1AC: A8           TAY 
C1/A1AD: A9 02        LDA #$02
C1/A1AF: 99 C1 D1     STA $D1C1,Y
C1/A1B2: 20 35 8D     JSR $8D35       ; get target id
C1/A1B5: 20 7A FC     JSR $FC7A
C1/A1B8: 85 72        STA $72
C1/A1BA: B2 EB        LDA ($EB)
C1/A1BC: 29 40        AND #$40
C1/A1BE: F0 05        BEQ $A1C5
C1/A1C0: EE C9 D1     INC $D1C9
C1/A1C3: 80 28        BRA $A1ED
C1/A1C5: A5 70        LDA $70
C1/A1C7: C5 72        CMP $72
C1/A1C9: D0 0A        BNE $A1D5
C1/A1CB: A5 70        LDA $70
C1/A1CD: A8           TAY 
C1/A1CE: B9 BD D1     LDA $D1BD,Y
C1/A1D1: D0 0A        BNE $A1DD
C1/A1D3: 80 EB        BRA $A1C0
C1/A1D5: A5 72        LDA $72
C1/A1D7: A8           TAY 
C1/A1D8: B9 BD D1     LDA $D1BD,Y
C1/A1DB: D0 E3        BNE $A1C0
C1/A1DD: A9 40        LDA #$40
C1/A1DF: 8D A8 D1     STA $D1A8
C1/A1E2: 8D B6 D1     STA $D1B6
C1/A1E5: A5 70        LDA $70
C1/A1E7: A8           TAY 
C1/A1E8: A9 01        LDA #$01
C1/A1EA: 99 C1 D1     STA $D1C1,Y
C1/A1ED: 20 ED 9F     JSR $9FED
C1/A1F0: 48           PHA 
C1/A1F1: AD BC D1     LDA $D1BC
C1/A1F4: 30 05        BMI $A1FB
C1/A1F6: 20 53 8D     JSR $8D53       ; get graphics script parameter 4
C1/A1F9: 10 0C        BPL $A207
C1/A1FB: A9 05        LDA #$05
C1/A1FD: 85 73        STA $73
C1/A1FF: 64 70        STZ $70
C1/A201: A9 04        LDA #$04
C1/A203: 85 72        STA $72
C1/A205: 80 0A        BRA $A211
C1/A207: A9 04        LDA #$04
C1/A209: 85 73        STA $73
C1/A20B: A9 06        LDA #$06
C1/A20D: 85 70        STA $70
C1/A20F: 64 72        STZ $72
C1/A211: 68           PLA 
C1/A212: AA           TAX 
C1/A213: BF 43 A8 C1  LDA $C1A843,X
C1/A217: 18           CLC 
C1/A218: 65 70        ADC $70
C1/A21A: 8D A1 D1     STA $D1A1
C1/A21D: 8A           TXA 
C1/A21E: 0A           ASL 
C1/A21F: 0A           ASL 
C1/A220: 0A           ASL 
C1/A221: 0A           ASL 
C1/A222: 0A           ASL 
C1/A223: AA           TAX 
C1/A224: DA           PHX 
C1/A225: AD D3 D1     LDA $D1D3
C1/A228: C9 01        CMP #$01
C1/A22A: F0 0A        BEQ $A236
C1/A22C: A5 72        LDA $72
C1/A22E: 9D 48 CF     STA $CF48,X
C1/A231: A5 73        LDA $73
C1/A233: 9D 58 CF     STA $CF58,X
C1/A236: 20 1D A0     JSR $A01D
C1/A239: A9 08        LDA #$08
C1/A23B: 8D AF D1     STA $D1AF
C1/A23E: 9C A2 D1     STZ $D1A2
C1/A241: 9C B0 D1     STZ $D1B0
C1/A244: A9 02        LDA #$02
C1/A246: 8D 8B D1     STA $D18B
C1/A249: 8D 99 D1     STA $D199
C1/A24C: AE 86 D1     LDX $D186
C1/A24F: 86 70        STX $70
C1/A251: AD 88 D1     LDA $D188
C1/A254: 85 72        STA $72
C1/A256: AE 94 D1     LDX $D194
C1/A259: 86 74        STX $74
C1/A25B: AD 96 D1     LDA $D196
C1/A25E: 85 76        STA $76
C1/A260: A7 70        LDA [$70]       ; bg1 width ???
C1/A262: 4A           LSR 
C1/A263: 4A           LSR 
C1/A264: 4A           LSR 
C1/A265: 4A           LSR 
C1/A266: 1A           INC 
C1/A267: 8D 89 D1     STA $D189
C1/A26A: A7 74        LDA [$74]       ; bg3 width ???
C1/A26C: 4A           LSR 
C1/A26D: 4A           LSR 
C1/A26E: 4A           LSR 
C1/A26F: 4A           LSR 
C1/A270: 1A           INC 
C1/A271: 8D 97 D1     STA $D197
C1/A274: A7 70        LDA [$70]       ; bg1 height ???
C1/A276: 29 0F        AND #$0F
C1/A278: 1A           INC 
C1/A279: 8D 8C D1     STA $D18C
C1/A27C: A7 74        LDA [$74]       ; bg3 height ???
C1/A27E: 29 0F        AND #$0F
C1/A280: 1A           INC 
C1/A281: 8D 9A D1     STA $D19A
C1/A284: A9 01        LDA #$01
C1/A286: 8D 8A D1     STA $D18A
C1/A289: 8D 98 D1     STA $D198
C1/A28C: AE 86 D1     LDX $D186
C1/A28F: 86 70        STX $70
C1/A291: AD 88 D1     LDA $D188
C1/A294: 85 72        STA $72
C1/A296: AE 94 D1     LDX $D194
C1/A299: 86 74        STX $74
C1/A29B: AD 96 D1     LDA $D196
C1/A29E: 85 76        STA $76
C1/A2A0: A0 01 00     LDY #$0001
C1/A2A3: B7 70        LDA [$70],Y
C1/A2A5: C2 20        REP #$20
C1/A2A7: 0A           ASL 
C1/A2A8: 0A           ASL 
C1/A2A9: 0A           ASL 
C1/A2AA: 0A           ASL 
C1/A2AB: 0A           ASL 
C1/A2AC: 0A           ASL 
C1/A2AD: 0A           ASL 
C1/A2AE: 85 78        STA $78
C1/A2B0: B7 74        LDA [$74],Y
C1/A2B2: 29 FF 00     AND #$00FF
C1/A2B5: 0A           ASL 
C1/A2B6: 0A           ASL 
C1/A2B7: 0A           ASL 
C1/A2B8: 0A           ASL 
C1/A2B9: 0A           ASL 
C1/A2BA: 0A           ASL 
C1/A2BB: 0A           ASL 
C1/A2BC: 85 7A        STA $7A
C1/A2BE: 7B           TDC 
C1/A2BF: E2 20        SEP #$20
C1/A2C1: 64 7C        STZ $7C
C1/A2C3: AD 8B D1     LDA $D18B
C1/A2C6: A8           TAY 
C1/A2C7: CE 8A D1     DEC $D18A
C1/A2CA: D0 5B        BNE $A327
C1/A2CC: AD 89 D1     LDA $D189
C1/A2CF: 8D 8A D1     STA $D18A
C1/A2D2: EE AC D1     INC $D1AC
C1/A2D5: 64 7E        STZ $7E
C1/A2D7: A6 70        LDX $70
C1/A2D9: 86 84        STX $84
C1/A2DB: A5 72        LDA $72
C1/A2DD: 85 86        STA $86
C1/A2DF: AD D3 D1     LDA $D1D3
C1/A2E2: D0 23        BNE $A307
C1/A2E4: B7 84        LDA [$84],Y
C1/A2E6: C9 FF        CMP #$FF
C1/A2E8: F0 1D        BEQ $A307       ; branch if end of frame
C1/A2EA: B7 84        LDA [$84],Y
C1/A2EC: 30 13        BMI $A301
C1/A2EE: C2 20        REP #$20
C1/A2F0: 18           CLC 
C1/A2F1: 65 78        ADC $78
C1/A2F3: 8D A2 D1     STA $D1A2
C1/A2F6: 7B           TDC 
C1/A2F7: E2 20        SEP #$20
C1/A2F9: C8           INY 
C1/A2FA: A9 01        LDA #$01
C1/A2FC: 8D A0 D1     STA $D1A0
C1/A2FF: 80 26        BRA $A327
C1/A301: 20 D3 A3     JSR $A3D3
C1/A304: C8           INY 
C1/A305: 80 CE        BRA $A2D5
C1/A307: AD 8C D1     LDA $D18C
C1/A30A: F0 11        BEQ $A31D
C1/A30C: CE 8C D1     DEC $D18C
C1/A30F: F0 0C        BEQ $A31D
C1/A311: 20 ED 9F     JSR $9FED
C1/A314: A0 02 00     LDY #$0002
C1/A317: 98           TYA 
C1/A318: 8D 8B D1     STA $D18B
C1/A31B: 80 B8        BRA $A2D5
C1/A31D: A9 01        LDA #$01
C1/A31F: 8D 89 D1     STA $D189
C1/A322: 8D 8A D1     STA $D18A
C1/A325: E6 7C        INC $7C
C1/A327: 98           TYA 
C1/A328: 8D 8B D1     STA $D18B
C1/A32B: AD 99 D1     LDA $D199
C1/A32E: A8           TAY 
C1/A32F: AD BC D1     LDA $D1BC
C1/A332: 29 40        AND #$40
C1/A334: F0 04        BEQ $A33A
C1/A336: A5 7C        LDA $7C
C1/A338: F0 62        BEQ $A39C
C1/A33A: CE 98 D1     DEC $D198
C1/A33D: D0 5D        BNE $A39C
C1/A33F: AD 97 D1     LDA $D197
C1/A342: 8D 98 D1     STA $D198
C1/A345: EE BA D1     INC $D1BA
C1/A348: 20 65 A0     JSR $A065
C1/A34B: 90 45        BCC $A392
C1/A34D: A9 0E        LDA #$0E
C1/A34F: 85 7E        STA $7E
C1/A351: A6 74        LDX $74
C1/A353: 86 84        STX $84
C1/A355: A5 76        LDA $76
C1/A357: 85 86        STA $86
C1/A359: B7 84        LDA [$84],Y
C1/A35B: C9 FF        CMP #$FF
C1/A35D: F0 1D        BEQ $A37C
C1/A35F: B7 84        LDA [$84],Y
C1/A361: 30 13        BMI $A376
C1/A363: C2 20        REP #$20
C1/A365: 18           CLC 
C1/A366: 65 7A        ADC $7A
C1/A368: 8D B0 D1     STA $D1B0
C1/A36B: 7B           TDC 
C1/A36C: E2 20        SEP #$20
C1/A36E: C8           INY 
C1/A36F: A9 01        LDA #$01
C1/A371: 8D AE D1     STA $D1AE
C1/A374: 80 26        BRA $A39C
C1/A376: 20 D3 A3     JSR $A3D3
C1/A379: C8           INY 
C1/A37A: 80 CC        BRA $A348
C1/A37C: AD 9A D1     LDA $D19A
C1/A37F: F0 11        BEQ $A392
C1/A381: CE 9A D1     DEC $D19A
C1/A384: F0 0C        BEQ $A392
C1/A386: 20 1D A0     JSR $A01D
C1/A389: A0 02 00     LDY #$0002
C1/A38C: 98           TYA 
C1/A38D: 8D 99 D1     STA $D199
C1/A390: 80 B6        BRA $A348
C1/A392: A9 FF        LDA #$FF
C1/A394: 8D BB D1     STA $D1BB
C1/A397: 8D AE D1     STA $D1AE
C1/A39A: E6 7C        INC $7C
C1/A39C: 98           TYA 
C1/A39D: 8D 99 D1     STA $D199
C1/A3A0: A5 7C        LDA $7C
C1/A3A2: C9 02        CMP #$02
C1/A3A4: F0 06        BEQ $A3AC
C1/A3A6: 20 F2 02     JSR $02F2       ; wait one frame
C1/A3A9: 4C 8C A2     JMP $A28C
C1/A3AC: FA           PLX 
C1/A3AD: 7B           TDC 
C1/A3AE: 8D C1 D1     STA $D1C1
C1/A3B1: 8D C2 D1     STA $D1C2
C1/A3B4: 8D C3 D1     STA $D1C3
C1/A3B7: 8D C4 D1     STA $D1C4
C1/A3BA: 8D A0 D1     STA $D1A0
C1/A3BD: B2 EB        LDA ($EB)
C1/A3BF: 30 0C        BMI $A3CD
C1/A3C1: 7B           TDC 
C1/A3C2: 9D 57 CF     STA $CF57,X
C1/A3C5: 9D 58 CF     STA $CF58,X
C1/A3C8: A9 04        LDA #$04
C1/A3CA: 9D 48 CF     STA $CF48,X
C1/A3CD: 20 73 A0     JSR $A073
C1/A3D0: 4C F2 02     JMP $02F2       ; wait one frame

; [  ]

C1/A3D3: 29 7F        AND #$7F
C1/A3D5: 0A           ASL 
C1/A3D6: AA           TAX 
C1/A3D7: BF E6 A3 C1  LDA $C1A3E6,X
C1/A3DB: 85 80        STA $80
C1/A3DD: BF E7 A3 C1  LDA $C1A3E7,X
C1/A3E1: 85 81        STA $81
C1/A3E3: 6C 80 00     JMP ($0080)

C1/A3E6: A7A5 A7B3 A7C4 A7AC A4E7 A6AD A67B A4DE
C1/A3F6: A70F A7BD A6DF A4D1 A01D A737 A4CB A4BE
C1/A405: A4B5 A4AE A497 A480 A442 A461 A431 A416

; [  ]

C1/A416: 5A           PHY 
C1/A417: AD B6 D1     LDA $D1B6
C1/A41A: 29 40        AND #$40
C1/A41C: 8D B6 D1     STA $D1B6
C1/A41F: 20 35 8D     JSR $8D35       ; get target id
C1/A422: 20 7A FC     JSR $FC7A
C1/A425: 29 03        AND #$03
C1/A427: 09 80        ORA #$80
C1/A429: 0D B6 D1     ORA $D1B6
C1/A42C: 8D B6 D1     STA $D1B6
C1/A42F: 7A           PLY 
C1/A430: 60           RTS 

; [  ]

C1/A431: B2 EB        LDA ($EB)
C1/A433: 29 40        AND #$40
C1/A435: F0 0A        BEQ $A441
C1/A437: B7 84        LDA [$84],Y
C1/A439: C9 FF        CMP #$FF
C1/A43B: F0 03        BEQ $A440
C1/A43D: C8           INY 
C1/A43E: 80 F7        BRA $A437
C1/A440: 88           DEY 
C1/A441: 60           RTS 

; [  ]

C1/A442: 5A           PHY 
C1/A443: 20 35 8D     JSR $8D35       ; get target id
C1/A446: DA           PHX 
C1/A447: 20 7A FC     JSR $FC7A
C1/A44A: FA           PLX 
C1/A44B: 7A           PLY 
C1/A44C: 0A           ASL 
C1/A44D: 0A           ASL 
C1/A44E: 0A           ASL 
C1/A44F: 0A           ASL 
C1/A450: 0A           ASL 
C1/A451: AA           TAX 
C1/A452: C8           INY 
C1/A453: B7 84        LDA [$84],Y
C1/A455: 85 80        STA $80
C1/A457: BD 49 CF     LDA $CF49,X
C1/A45A: 18           CLC 
C1/A45B: 65 80        ADC $80
C1/A45D: 9D 49 CF     STA $CF49,X
C1/A460: 60           RTS 

; [  ]

C1/A461: 5A           PHY 
C1/A462: 20 35 8D     JSR $8D35       ; get target id
C1/A465: DA           PHX 
C1/A466: 20 7A FC     JSR $FC7A
C1/A469: FA           PLX 
C1/A46A: 7A           PLY 
C1/A46B: 0A           ASL 
C1/A46C: 0A           ASL 
C1/A46D: 0A           ASL 
C1/A46E: 0A           ASL 
C1/A46F: 0A           ASL 
C1/A470: AA           TAX 
C1/A471: C8           INY 
C1/A472: B7 84        LDA [$84],Y
C1/A474: 85 80        STA $80
C1/A476: BD 49 CF     LDA $CF49,X
C1/A479: 38           SEC 
C1/A47A: E5 80        SBC $80
C1/A47C: 9D 49 CF     STA $CF49,X
C1/A47F: 60           RTS 

; [  ]

C1/A480: 5A           PHY 
C1/A481: 20 35 8D     JSR $8D35       ; get target id
C1/A484: DA           PHX 
C1/A485: 20 7A FC     JSR $FC7A
C1/A488: FA           PLX 
C1/A489: 7A           PLY 
C1/A48A: 0A           ASL 
C1/A48B: 0A           ASL 
C1/A48C: 0A           ASL 
C1/A48D: 0A           ASL 
C1/A48E: 0A           ASL 
C1/A48F: AA           TAX 
C1/A490: C8           INY 
C1/A491: B7 84        LDA [$84],Y
C1/A493: 9D 57 CF     STA $CF57,X
C1/A496: 60           RTS 

; [  ]

C1/A497: 5A           PHY 
C1/A498: 20 35 8D     JSR $8D35       ; get target id
C1/A49B: DA           PHX 
C1/A49C: 20 7A FC     JSR $FC7A
C1/A49F: FA           PLX 
C1/A4A0: 7A           PLY 
C1/A4A1: 0A           ASL 
C1/A4A2: 0A           ASL 
C1/A4A3: 0A           ASL 
C1/A4A4: 0A           ASL 
C1/A4A5: 0A           ASL 
C1/A4A6: AA           TAX 
C1/A4A7: C8           INY 
C1/A4A8: B7 84        LDA [$84],Y
C1/A4AA: 9D 58 CF     STA $CF58,X
C1/A4AD: 60           RTS 

; [  ]

C1/A4AE: C8           INY 
C1/A4AF: B7 84        LDA [$84],Y
C1/A4B1: 8D CA D1     STA $D1CA
C1/A4B4: 60           RTS 

; [  ]

C1/A4B5: CE CA D1     DEC $D1CA
C1/A4B8: F0 03        BEQ $A4BD
C1/A4BA: 88           DEY 
C1/A4BB: 88           DEY 
C1/A4BC: 88           DEY 
C1/A4BD: 60           RTS 

; [  ]

C1/A4BE: AD BA D1     LDA $D1BA
C1/A4C1: 29 03        AND #$03
C1/A4C3: D0 05        BNE $A4CA
C1/A4C5: A9 81        LDA #$81
C1/A4C7: 8D BB D1     STA $D1BB
C1/A4CA: 60           RTS 

; [  ]

C1/A4CB: A9 FF        LDA #$FF
C1/A4CD: 8D BB D1     STA $D1BB
C1/A4D0: 60           RTS 

; [  ]

C1/A4D1: AE A9 D1     LDX $D1A9
C1/A4D4: 8E B7 D1     STX $D1B7
C1/A4D7: AE A4 D1     LDX $D1A4
C1/A4DA: 8E B2 D1     STX $D1B2
C1/A4DD: 60           RTS 

; [  ]

C1/A4DE: AD BC D1     LDA $D1BC
C1/A4E1: 29 BF        AND #$BF
C1/A4E3: 8D BC D1     STA $D1BC
C1/A4E6: 60           RTS 

; [  ]

C1/A4E7: C8           INY 
C1/A4E8: B7 84        LDA [$84],Y
C1/A4EA: 0A           ASL 
C1/A4EB: AA           TAX 
C1/A4EC: BF FB A4 C1  LDA $C1A4FB,X
C1/A4F0: 85 80        STA $80
C1/A4F2: BF FC A4 C1  LDA $C1A4FC,X
C1/A4F6: 85 81        STA $81
C1/A4F8: 6C 80 00     JMP ($0080)

C1/A4FB:              .DW $A57E, $A519, $A513, $A503

C1/A503: A9 0E        LDA #$0E
C1/A505: 85 AF        STA $AF
C1/A507: A9 08        LDA #$08
C1/A509: 20 1D A5     JSR $A51D
C1/A50C: A6 AF        LDX $AF
C1/A50E: CA           DEX 
C1/A50F: CA           DEX 
C1/A510: 86 AF        STX $AF
C1/A512: 60           RTS 
C1/A513: 64 AF        STZ $AF
C1/A515: A9 10        LDA #$10
C1/A517: 80 04        BRA $A51D
C1/A519: 64 AF        STZ $AF
C1/A51B: A9 08        LDA #$08
C1/A51D: 85 AE        STA $AE
C1/A51F: AD A9 D1     LDA $D1A9
C1/A522: 18           CLC 
C1/A523: 6D B2 D1     ADC $D1B2
C1/A526: 85 A6        STA $A6
C1/A528: AD AA D1     LDA $D1AA
C1/A52B: 18           CLC 
C1/A52C: 6D B3 D1     ADC $D1B3
C1/A52F: 85 A7        STA $A7
C1/A531: AD B7 D1     LDA $D1B7
C1/A534: 18           CLC 
C1/A535: 6D B2 D1     ADC $D1B2
C1/A538: 38           SEC 
C1/A539: E5 AE        SBC $AE
C1/A53B: 85 A8        STA $A8
C1/A53D: AD C9 D1     LDA $D1C9
C1/A540: F0 09        BEQ $A54B
C1/A542: 06 AE        ASL $AE
C1/A544: A5 A8        LDA $A8
C1/A546: 18           CLC 
C1/A547: 65 AE        ADC $AE
C1/A549: 85 A8        STA $A8
C1/A54B: AD B8 D1     LDA $D1B8
C1/A54E: 18           CLC 
C1/A54F: 6D B3 D1     ADC $D1B3
C1/A552: 18           CLC 
C1/A553: 65 AF        ADC $AF
C1/A555: 85 A9        STA $A9
C1/A557: 9C A6 D1     STZ $D1A6
C1/A55A: 9C A7 D1     STZ $D1A7
C1/A55D: 9C B4 D1     STZ $D1B4
C1/A560: 9C B5 D1     STZ $D1B5
C1/A563: 20 6E 0A     JSR $0A6E
C1/A566: 20 70 A5     JSR $A570
C1/A569: AE A9 D1     LDX $D1A9
C1/A56C: 8E B7 D1     STX $D1B7
C1/A56F: 60           RTS 

; [  ]

C1/A570: C2 20        REP #$20
C1/A572: A5 AF        LDA $AF
C1/A574: 18           CLC 
C1/A575: 69 09 00     ADC #$0009
C1/A578: 85 AF        STA $AF
C1/A57A: 7B           TDC 
C1/A57B: E2 20        SEP #$20
C1/A57D: 60           RTS 
C1/A57E: AD A9 D1     LDA $D1A9
C1/A581: 18           CLC 
C1/A582: 6D A4 D1     ADC $D1A4
C1/A585: 85 A6        STA $A6
C1/A587: AD AA D1     LDA $D1AA
C1/A58A: 18           CLC 
C1/A58B: 6D A5 D1     ADC $D1A5
C1/A58E: 85 A7        STA $A7
C1/A590: AD B7 D1     LDA $D1B7
C1/A593: 18           CLC 
C1/A594: 6D A4 D1     ADC $D1A4
C1/A597: 85 A8        STA $A8
C1/A599: AD B8 D1     LDA $D1B8
C1/A59C: 18           CLC 
C1/A59D: 6D A5 D1     ADC $D1A5
C1/A5A0: 69 0C        ADC #$0C
C1/A5A2: 85 A9        STA $A9
C1/A5A4: 9C A6 D1     STZ $D1A6
C1/A5A7: 9C A7 D1     STZ $D1A7
C1/A5AA: 9C B4 D1     STZ $D1B4
C1/A5AD: 9C B5 D1     STZ $D1B5
C1/A5B0: 20 6E 0A     JSR $0A6E
C1/A5B3: 4C 70 A5     JMP $A570

; [  ]

C1/A5B6: A5 AF        LDA $AF
C1/A5B8: C9 08        CMP #$08
C1/A5BA: 90 2C        BCC $A5E8
C1/A5BC: C9 10        CMP #$10
C1/A5BE: 90 24        BCC $A5E4
C1/A5C0: C9 20        CMP #$20
C1/A5C2: 90 1C        BCC $A5E0
C1/A5C4: C9 30        CMP #$30
C1/A5C6: 90 14        BCC $A5DC
C1/A5C8: C9 40        CMP #$40
C1/A5CA: 90 0C        BCC $A5D8
C1/A5CC: C9 50        CMP #$50
C1/A5CE: 90 04        BCC $A5D4
C1/A5D0: A9 08        LDA #$08
C1/A5D2: 80 16        BRA $A5EA
C1/A5D4: A9 07        LDA #$07
C1/A5D6: 80 12        BRA $A5EA
C1/A5D8: A9 06        LDA #$06
C1/A5DA: 80 0E        BRA $A5EA
C1/A5DC: A9 05        LDA #$05
C1/A5DE: 80 0A        BRA $A5EA
C1/A5E0: A9 04        LDA #$04
C1/A5E2: 80 06        BRA $A5EA
C1/A5E4: A9 03        LDA #$03
C1/A5E6: 80 02        BRA $A5EA
C1/A5E8: A9 02        LDA #$02
C1/A5EA: 60           RTS 

; [  ]

C1/A5EB: AD B4 D1     LDA $D1B4
C1/A5EE: AA           TAX 
C1/A5EF: 86 80        STX $80
C1/A5F1: A5 AE        LDA $AE
C1/A5F3: 18           CLC 
C1/A5F4: 69 40        ADC #$40
C1/A5F6: 20 59 0B     JSR $0B59
C1/A5F9: AD A6 00     LDA $00A6
C1/A5FC: C2 20        REP #$20
C1/A5FE: 18           CLC 
C1/A5FF: 65 84        ADC $84
C1/A601: 29 FF 00     AND #$00FF
C1/A604: AA           TAX 
C1/A605: 7B           TDC 
C1/A606: E2 20        SEP #$20
C1/A608: 8A           TXA 
C1/A609: 38           SEC 
C1/A60A: ED B2 D1     SBC $D1B2
C1/A60D: 8D B7 D1     STA $D1B7
C1/A610: AD B4 D1     LDA $D1B4
C1/A613: AA           TAX 
C1/A614: 86 80        STX $80
C1/A616: A5 AE        LDA $AE
C1/A618: 20 59 0B     JSR $0B59
C1/A61B: AD A7 00     LDA $00A7
C1/A61E: C2 20        REP #$20
C1/A620: 18           CLC 
C1/A621: 65 84        ADC $84
C1/A623: 29 FF 00     AND #$00FF
C1/A626: AA           TAX 
C1/A627: 7B           TDC 
C1/A628: E2 20        SEP #$20
C1/A62A: 8A           TXA 
C1/A62B: 38           SEC 
C1/A62C: ED B3 D1     SBC $D1B3
C1/A62F: 8D B8 D1     STA $D1B8
C1/A632: 60           RTS 

; [  ]

C1/A633: AD A6 D1     LDA $D1A6
C1/A636: AA           TAX 
C1/A637: 86 80        STX $80
C1/A639: A5 AE        LDA $AE
C1/A63B: 18           CLC 
C1/A63C: 69 40        ADC #$40
C1/A63E: 20 59 0B     JSR $0B59
C1/A641: AD A6 00     LDA $00A6
C1/A644: C2 20        REP #$20
C1/A646: 18           CLC 
C1/A647: 65 84        ADC $84
C1/A649: 29 FF 00     AND #$00FF
C1/A64C: AA           TAX 
C1/A64D: 7B           TDC 
C1/A64E: E2 20        SEP #$20
C1/A650: 8A           TXA 
C1/A651: 38           SEC 
C1/A652: ED A4 D1     SBC $D1A4
C1/A655: 8D A9 D1     STA $D1A9
C1/A658: AD A6 D1     LDA $D1A6
C1/A65B: AA           TAX 
C1/A65C: 86 80        STX $80
C1/A65E: A5 AE        LDA $AE
C1/A660: 20 59 0B     JSR $0B59
C1/A663: AD A7 00     LDA $00A7
C1/A666: C2 20        REP #$20
C1/A668: 18           CLC 
C1/A669: 65 84        ADC $84
C1/A66B: 29 FF 00     AND #$00FF
C1/A66E: AA           TAX 
C1/A66F: 7B           TDC 
C1/A670: E2 20        SEP #$20
C1/A672: 8A           TXA 
C1/A673: 38           SEC 
C1/A674: ED A5 D1     SBC $D1A5
C1/A677: 8D AA D1     STA $D1AA
C1/A67A: 60           RTS 

C1/A67B: A6 7E        LDX $7E
C1/A67D: DA           PHX 
C1/A67E: A6 84        LDX $84
C1/A680: DA           PHX 
C1/A681: AD AC D1     LDA $D1AC
C1/A684: 4A           LSR 
C1/A685: 29 03        AND #$03
C1/A687: 8D AB D1     STA $D1AB
C1/A68A: 20 33 A6     JSR $A633
C1/A68D: 20 B6 A5     JSR $A5B6
C1/A690: 85 80        STA $80
C1/A692: A5 AF        LDA $AF
C1/A694: 18           CLC 
C1/A695: 65 80        ADC $80
C1/A697: 85 AF        STA $AF
C1/A699: AD A6 D1     LDA $D1A6
C1/A69C: 38           SEC 
C1/A69D: E5 80        SBC $80
C1/A69F: 8D A6 D1     STA $D1A6
C1/A6A2: 90 02        BCC $A6A6
C1/A6A4: 88           DEY 
C1/A6A5: 88           DEY 
C1/A6A6: FA           PLX 
C1/A6A7: 86 84        STX $84
C1/A6A9: FA           PLX 
C1/A6AA: 86 7E        STX $7E
C1/A6AC: 60           RTS 

C1/A6AD: A6 7E        LDX $7E
C1/A6AF: DA           PHX 
C1/A6B0: A6 84        LDX $84
C1/A6B2: DA           PHX 
C1/A6B3: AD AC D1     LDA $D1AC
C1/A6B6: 4A           LSR 
C1/A6B7: 29 03        AND #$03
C1/A6B9: 8D AB D1     STA $D1AB
C1/A6BC: 20 33 A6     JSR $A633
C1/A6BF: 20 B6 A5     JSR $A5B6
C1/A6C2: 85 80        STA $80
C1/A6C4: A5 AF        LDA $AF
C1/A6C6: 38           SEC 
C1/A6C7: E5 80        SBC $80
C1/A6C9: 85 AF        STA $AF
C1/A6CB: 90 02        BCC $A6CF
C1/A6CD: 88           DEY 
C1/A6CE: 88           DEY 
C1/A6CF: AD A6 D1     LDA $D1A6
C1/A6D2: 18           CLC 
C1/A6D3: 65 80        ADC $80
C1/A6D5: 8D A6 D1     STA $D1A6
C1/A6D8: FA           PLX 
C1/A6D9: 86 84        STX $84
C1/A6DB: FA           PLX 
C1/A6DC: 86 7E        STX $7E
C1/A6DE: 60           RTS 

C1/A6DF: A6 7E        LDX $7E
C1/A6E1: DA           PHX 
C1/A6E2: A6 84        LDX $84
C1/A6E4: DA           PHX 
C1/A6E5: AD AC D1     LDA $D1AC
C1/A6E8: 29 01        AND #$01
C1/A6EA: 8D AB D1     STA $D1AB
C1/A6ED: 20 33 A6     JSR $A633
C1/A6F0: A9 0A        LDA #$0A
C1/A6F2: 85 80        STA $80
C1/A6F4: A5 AF        LDA $AF
C1/A6F6: 38           SEC 
C1/A6F7: E5 80        SBC $80
C1/A6F9: 85 AF        STA $AF
C1/A6FB: 90 02        BCC $A6FF
C1/A6FD: 88           DEY 
C1/A6FE: 88           DEY 
C1/A6FF: AD A6 D1     LDA $D1A6
C1/A702: 18           CLC 
C1/A703: 65 80        ADC $80
C1/A705: 8D A6 D1     STA $D1A6
C1/A708: FA           PLX 
C1/A709: 86 84        STX $84
C1/A70B: FA           PLX 
C1/A70C: 86 7E        STX $7E
C1/A70E: 60           RTS 

C1/A70F: A6 7E        LDX $7E
C1/A711: DA           PHX 
C1/A712: A6 84        LDX $84
C1/A714: DA           PHX 
C1/A715: 20 EB A5     JSR $A5EB
C1/A718: A9 0A        LDA #$0A
C1/A71A: 85 80        STA $80
C1/A71C: A5 AF        LDA $AF
C1/A71E: 38           SEC 
C1/A71F: E5 80        SBC $80
C1/A721: 85 AF        STA $AF
C1/A723: 90 02        BCC $A727
C1/A725: 88           DEY 
C1/A726: 88           DEY 
C1/A727: AD B4 D1     LDA $D1B4
C1/A72A: 18           CLC 
C1/A72B: 65 80        ADC $80
C1/A72D: 8D B4 D1     STA $D1B4
C1/A730: FA           PLX 
C1/A731: 86 84        STX $84
C1/A733: FA           PLX 
C1/A734: 86 7E        STX $7E
C1/A736: 60           RTS 

C1/A737: A6 7E        LDX $7E
C1/A739: DA           PHX 
C1/A73A: A6 84        LDX $84
C1/A73C: DA           PHX 
C1/A73D: AD BA D1     LDA $D1BA
C1/A740: 29 04        AND #$04
C1/A742: 4A           LSR 
C1/A743: 4A           LSR 
C1/A744: 8D B9 D1     STA $D1B9
C1/A747: 20 BE A4     JSR $A4BE
C1/A74A: 20 EB A5     JSR $A5EB
C1/A74D: A9 04        LDA #$04
C1/A74F: 85 80        STA $80
C1/A751: A5 AF        LDA $AF
C1/A753: 38           SEC 
C1/A754: E5 80        SBC $80
C1/A756: 85 AF        STA $AF
C1/A758: 90 02        BCC $A75C
C1/A75A: 88           DEY 
C1/A75B: 88           DEY 
C1/A75C: AD B4 D1     LDA $D1B4
C1/A75F: 18           CLC 
C1/A760: 65 80        ADC $80
C1/A762: 8D B4 D1     STA $D1B4
C1/A765: A9 10        LDA #$10
C1/A767: 85 80        STA $80
C1/A769: AD BA D1     LDA $D1BA
C1/A76C: 0A           ASL 
C1/A76D: 0A           ASL 
C1/A76E: 0A           ASL 
C1/A76F: 0A           ASL 
C1/A770: 20 00 0A     JSR $0A00
C1/A773: 18           CLC 
C1/A774: 6D B8 D1     ADC $D1B8
C1/A777: 8D B8 D1     STA $D1B8
C1/A77A: A9 10        LDA #$10
C1/A77C: 85 80        STA $80
C1/A77E: AD BA D1     LDA $D1BA
C1/A781: 18           CLC 
C1/A782: 69 40        ADC #$40
C1/A784: 0A           ASL 
C1/A785: 0A           ASL 
C1/A786: 0A           ASL 
C1/A787: 0A           ASL 
C1/A788: 20 00 0A     JSR $0A00
C1/A78B: 18           CLC 
C1/A78C: 6D B7 D1     ADC $D1B7
C1/A78F: FA           PLX 
C1/A790: 86 84        STX $84
C1/A792: FA           PLX 
C1/A793: 86 7E        STX $7E
C1/A795: 60           RTS 

C1/A796: 5A           PHY 
C1/A797: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/A79A: 7A           PLY 
C1/A79B: 0A           ASL 
C1/A79C: 0A           ASL 
C1/A79D: 0A           ASL 
C1/A79E: 0A           ASL 
C1/A79F: 0A           ASL 
C1/A7A0: AA           TAX 
C1/A7A1: C8           INY 
C1/A7A2: B7 84        LDA [$84],Y
C1/A7A4: 60           RTS 

C1/A7A5: 20 96 A7     JSR $A796
C1/A7A8: 9D 58 CF     STA $CF58,X
C1/A7AB: 60           RTS 

C1/A7AC: 20 96 A7     JSR $A796
C1/A7AF: 9D 57 CF     STA $CF57,X
C1/A7B2: 60           RTS 

C1/A7B3: C8           INY 
C1/A7B4: A5 7E        LDA $7E
C1/A7B6: AA           TAX 
C1/A7B7: B7 84        LDA [$84],Y
C1/A7B9: 9D 89 D1     STA $D189,X
C1/A7BC: 60           RTS 

C1/A7BD: A5 7E        LDA $7E
C1/A7BF: AA           TAX 
C1/A7C0: 9E A0 D1     STZ $D1A0,X
C1/A7C3: 60           RTS 

; [  ]

C1/A7C4: C8           INY 
C1/A7C5: B7 84        LDA [$84],Y
C1/A7C7: 4A           LSR 
C1/A7C8: 4A           LSR 
C1/A7C9: 4A           LSR 
C1/A7CA: 4A           LSR 
C1/A7CB: 29 FE        AND #$FE
C1/A7CD: AA           TAX 
C1/A7CE: BF E7 A7 C1  LDA $C1A7E7,X
C1/A7D2: 85 80        STA $80
C1/A7D4: BF E8 A7 C1  LDA $C1A7E8,X
C1/A7D8: 85 81        STA $81
C1/A7DA: B7 84        LDA [$84],Y
C1/A7DC: 29 1F        AND #$1F
C1/A7DE: 1A           INC 
C1/A7DF: 85 82        STA $82
C1/A7E1: A5 7E        LDA $7E
C1/A7E3: AA           TAX 
C1/A7E4: 6C 80 00     JMP ($0080)

C1/A7E7:              .DW $A7F7, $A7FD, $A800, $A806, $A809, $A80C, $A812, $A815

C1/A7F7: 20 25 A8     JSR $A825
C1/A7FA: 4C 2F A8     JMP $A82F

C1/A7FD: 4C 2F A8     JMP $A82F

C1/A800: 20 1B A8     JSR $A81B
C1/A803: 4C 2F A8     JMP $A82F

C1/A806: 4C 25 A8     JMP $A825

C1/A809: 4C 1B A8     JMP $A81B

C1/A80C: 20 25 A8     JSR $A825
C1/A80F: 4C 39 A8     JMP $A839

C1/A812: 4C 39 A8     JMP $A839

C1/A815: 20 1B A8     JSR $A81B
C1/A818: 4C 39 A8     JMP $A839

C1/A81B: BD A4 D1     LDA $D1A4,X
C1/A81E: 18           CLC 
C1/A81F: 65 82        ADC $82
C1/A821: 9D A4 D1     STA $D1A4,X
C1/A824: 60           RTS 

C1/A825: BD A4 D1     LDA $D1A4,X
C1/A828: 38           SEC 
C1/A829: E5 82        SBC $82
C1/A82B: 9D A4 D1     STA $D1A4,X
C1/A82E: 60           RTS 

C1/A82F: BD A5 D1     LDA $D1A5,X
C1/A832: 18           CLC 
C1/A833: 65 82        ADC $82
C1/A835: 9D A5 D1     STA $D1A5,X
C1/A838: 60           RTS 

C1/A839: BD A5 D1     LDA $D1A5,X
C1/A83C: 38           SEC 
C1/A83D: E5 82        SBC $82
C1/A83F: 9D A5 D1     STA $D1A5,X
C1/A842: 60           RTS 

C1/A843:              .DB $5E, $54, $4A, $40

; [ load attack animation properties ]

C1/A847: 86 7E        STX $7E
C1/A849: A2 05 00     LDX #$0005      ; get pointer to animation properties
C1/A84C: 86 80        STX $80
C1/A84E: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/A851: A6 82        LDX $82
C1/A853: BF EC 38 D8  LDA $D838EC,X   ; graphics type

; type 0: spell 1
C1/A857: 29 E0        AND #$E0
C1/A859: D0 0B        BNE $A866
C1/A85B: 29 1F        AND #$1F
C1/A85D: BF EC 38 D8  LDA $D838EC,X   ; graphics index
C1/A861: 20 BE AA     JSR $AABE       ; load spell 1 graphics
C1/A864: 80 54        BRA $A8BA

; type 1: spell 2
C1/A866: C9 20        CMP #$20
C1/A868: D0 0B        BNE $A875
C1/A86A: BF EC 38 D8  LDA $D838EC,X
C1/A86E: 29 1F        AND #$1F
C1/A870: 20 CE AA     JSR $AACE       ; load spell 2 graphics
C1/A873: 80 45        BRA $A8BA

; type 2: spell 3
C1/A875: C9 40        CMP #$40
C1/A877: D0 0B        BNE $A884
C1/A879: BF EC 38 D8  LDA $D838EC,X
C1/A87D: 29 1F        AND #$1F
C1/A87F: 20 DE AA     JSR $AADE       ; load spell 3 graphics
C1/A882: 80 36        BRA $A8BA

; type 3: weapon hit
C1/A884: C9 60        CMP #$60
C1/A886: D0 0B        BNE $A893
C1/A888: BF EC 38 D8  LDA $D838EC,X
C1/A88C: 29 1F        AND #$1F
C1/A88E: 20 9E AA     JSR $AA9E       ; load weapon hit graphics
C1/A891: 80 27        BRA $A8BA

; type 4: animals
C1/A893: C9 80        CMP #$80
C1/A895: D0 23        BNE $A8BA
C1/A897: BF EC 38 D8  LDA $D838EC,X
C1/A89B: 29 1F        AND #$1F
C1/A89D: 20 EE AA     JSR $AAEE       ; load animals graphics
C1/A8A0: BF ED 38 D8  LDA $D838ED,X   ; palette index
C1/A8A4: 29 7F        AND #$7F
C1/A8A6: A0 40 01     LDY #$0140
C1/A8A9: 20 3E AA     JSR $AA3E       ; load attack palette (16-colors)
C1/A8AC: BF ED 38 D8  LDA $D838ED,X   ; palette index
C1/A8B0: 29 7F        AND #$7F
C1/A8B2: A0 60 01     LDY #$0160
C1/A8B5: 20 3E AA     JSR $AA3E       ; load attack palette (16-colors)
C1/A8B8: 80 18        BRA $A8D2

; type 5, 6, 7: no graphics
C1/A8BA: BF ED 38 D8  LDA $D838ED,X   ; palette index
C1/A8BE: 29 7F        AND #$7F
C1/A8C0: A0 40 01     LDY #$0140
C1/A8C3: 20 1D AA     JSR $AA1D       ; load attack palette (8-colors)
C1/A8C6: BF ED 38 D8  LDA $D838ED,X   ; palette index
C1/A8CA: 29 7F        AND #$7F
C1/A8CC: A0 60 01     LDY #$0160
C1/A8CF: 20 1D AA     JSR $AA1D       ; load attack palette (8-colors)
C1/A8D2: BF EE 38 D8  LDA $D838EE,X   ; script
C1/A8D6: 8D 86 F5     STA $F586
C1/A8D9: BF ED 38 D8  LDA $D838ED,X   ; msb of byte 1
C1/A8DD: 4A           LSR 
C1/A8DE: 4A           LSR 
C1/A8DF: 4A           LSR 
C1/A8E0: 4A           LSR 
C1/A8E1: 4A           LSR 
C1/A8E2: 4A           LSR 
C1/A8E3: 4A           LSR 
C1/A8E4: 8D 87 F5     STA $F587
C1/A8E7: BF EF 38 D8  LDA $D838EF,X   ; init function
C1/A8EB: 8D 82 F5     STA $F582
C1/A8EE: BF F0 38 D8  LDA $D838F0,X   ; sound effect
C1/A8F2: 8D 83 F5     STA $F583
C1/A8F5: 9C 3C DB     STZ $DB3C
C1/A8F8: 9C 3D DB     STZ $DB3D
C1/A8FB: 60           RTS 

; [  ]

C1/A8FC: DA           PHX 
C1/A8FD: 85 7E        STA $7E
C1/A8FF: A9 09        LDA #$09
C1/A901: 85 80        STA $80
C1/A903: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/A906: A6 82        LDX $82
C1/A908: BF 5B 98 D9  LDA $D9985B,X
C1/A90C: 29 20        AND #$20
C1/A90E: F0 0D        BEQ $A91D
C1/A910: A5 71        LDA $71
C1/A912: F0 01        BEQ $A915
C1/A914: E8           INX 
C1/A915: BF 5C 98 D9  LDA $D9985C,X
C1/A919: FA           PLX 
C1/A91A: 4C FC A8     JMP $A8FC
C1/A91D: B2 EB        LDA ($EB)
C1/A91F: 29 01        AND #$01
C1/A921: F0 1C        BEQ $A93F       ; branch if not a monster special attack
C1/A923: B2 EB        LDA ($EB)
C1/A925: 29 FE        AND #$FE
C1/A927: 92 EB        STA ($EB)
C1/A929: 20 53 8D     JSR $8D53       ; get graphics script parameter 4
C1/A92C: 29 80        AND #$80
C1/A92E: 91 E7        STA ($E7),Y
C1/A930: B2 EB        LDA ($EB)
C1/A932: 29 40        AND #$40
C1/A934: F0 03        BEQ $A939
C1/A936: 7B           TDC 
C1/A937: 80 02        BRA $A93B
C1/A939: A9 A6        LDA #$A6
C1/A93B: FA           PLX 
C1/A93C: 4C FC A8     JMP $A8FC
C1/A93F: A5 70        LDA $70
C1/A941: F0 0C        BEQ $A94F
C1/A943: 64 70        STZ $70
C1/A945: BF 5D 98 D9  LDA $D9985D,X
C1/A949: F0 04        BEQ $A94F
C1/A94B: FA           PLX 
C1/A94C: 4C FC A8     JMP $A8FC
C1/A94F: 20 53 8D     JSR $8D53       ; get graphics script parameter 4
C1/A952: 29 7F        AND #$7F
C1/A954: F0 15        BEQ $A96B
C1/A956: 18           CLC 
C1/A957: 69 8D        ADC #$8D
C1/A959: 85 7E        STA $7E
C1/A95B: A9 09        LDA #$09
C1/A95D: 85 80        STA $80
C1/A95F: DA           PHX 
C1/A960: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/A963: A6 82        LDX $82
C1/A965: 20 D5 A9     JSR $A9D5
C1/A968: FA           PLX 
C1/A969: 80 1C        BRA $A987
C1/A96B: B2 F0        LDA ($F0)       ; block type
C1/A96D: F0 15        BEQ $A984
C1/A96F: 18           CLC 
C1/A970: 69 9F        ADC #$9F
C1/A972: 85 7E        STA $7E
C1/A974: A9 09        LDA #$09
C1/A976: 85 80        STA $80
C1/A978: DA           PHX 
C1/A979: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/A97C: A6 82        LDX $82
C1/A97E: 20 B5 A9     JSR $A9B5       ; load alt. weapon graphics
C1/A981: FA           PLX 
C1/A982: 80 03        BRA $A987
C1/A984: 20 D5 A9     JSR $A9D5
C1/A987: 20 92 A9     JSR $A992       ; load weapon graphics
C1/A98A: FA           PLX 
C1/A98B: 9C 3C DB     STZ $DB3C
C1/A98E: 9C 3D DB     STZ $DB3D
C1/A991: 60           RTS 

; [ load weapon graphics ]

C1/A992: BF 55 98 D9  LDA $D99855,X
C1/A996: 20 8E AA     JSR $AA8E       ; load weapon graphics
C1/A999: BF 56 98 D9  LDA $D99856,X
C1/A99D: A0 40 01     LDY #$0140
C1/A9A0: 20 1D AA     JSR $AA1D       ; load attack palette (8-colors)
C1/A9A3: BF 5B 98 D9  LDA $D9985B,X
C1/A9A7: 8D 82 F5     STA $F582
C1/A9AA: BF 57 98 D9  LDA $D99857,X   ; animation script
C1/A9AE: 8D 86 F5     STA $F586
C1/A9B1: 9C 87 F5     STZ $F587
C1/A9B4: 60           RTS 

; [ load alt. weapon graphics ]

C1/A9B5: BF 58 98 D9  LDA $D99858,X
C1/A9B9: 20 AE AA     JSR $AAAE       ; load alt. weapon graphics
C1/A9BC: BF 59 98 D9  LDA $D99859,X
C1/A9C0: A0 60 01     LDY #$0160
C1/A9C3: 20 1D AA     JSR $AA1D       ; load attack palette (8-colors)
C1/A9C6: BF 5A 98 D9  LDA $D9985A,X
C1/A9CA: 8D 85 F5     STA $F585
C1/A9CD: BF 5C 98 D9  LDA $D9985C,X   ; sound effect
C1/A9D1: 8D 83 F5     STA $F583
C1/A9D4: 60           RTS 

; [ load weapon hit graphics ]

C1/A9D5: AD FD 7B     LDA $7BFD
C1/A9D8: F0 23        BEQ $A9FD       ; branch if no sword slap
C1/A9DA: AF 58 98 D9  LDA $D99858
C1/A9DE: 20 9E AA     JSR $AA9E       ; load weapon hit graphics
C1/A9E1: AF 59 98 D9  LDA $D99859
C1/A9E5: A0 60 01     LDY #$0160
C1/A9E8: 20 1D AA     JSR $AA1D       ; load attack palette (8-colors)
C1/A9EB: AF 5A 98 D9  LDA $D9985A
C1/A9EF: 8D 85 F5     STA $F585
C1/A9F2: AF 5C 98 D9  LDA $D9985C     ; sound effect
C1/A9F6: 8D 83 F5     STA $F583
C1/A9F9: 9C FD 7B     STZ $7BFD
C1/A9FC: 60           RTS 
C1/A9FD: BF 58 98 D9  LDA $D99858,X
C1/AA01: 20 9E AA     JSR $AA9E       ; load weapon hit graphics
C1/AA04: BF 59 98 D9  LDA $D99859,X
C1/AA08: A0 60 01     LDY #$0160
C1/AA0B: 20 1D AA     JSR $AA1D       ; load attack palette (8-colors)
C1/AA0E: BF 5A 98 D9  LDA $D9985A,X
C1/AA12: 8D 85 F5     STA $F585
C1/AA15: BF 5C 98 D9  LDA $D9985C,X   ; sound effect
C1/AA19: 8D 83 F5     STA $F583
C1/AA1C: 60           RTS 

; [ load attack palette (8-colors) ]

C1/AA1D: DA           PHX 
C1/AA1E: C2 20        REP #$20
C1/AA20: 0A           ASL 
C1/AA21: 0A           ASL 
C1/AA22: 0A           ASL 
C1/AA23: 0A           ASL 
C1/AA24: AA           TAX 
C1/AA25: 7B           TDC 
C1/AA26: E2 20        SEP #$20
C1/AA28: A9 10        LDA #$10
C1/AA2A: 85 70        STA $70
C1/AA2C: BF A0 A3 D1  LDA $D1A3A0,X   ; load 8-color palette
C1/AA30: 99 09 7E     STA $7E09,Y
C1/AA33: 99 19 7E     STA $7E19,Y
C1/AA36: E8           INX 
C1/AA37: C8           INY 
C1/AA38: C6 70        DEC $70
C1/AA3A: D0 F0        BNE $AA2C
C1/AA3C: FA           PLX 
C1/AA3D: 60           RTS 

; [ load attack palette (16-colors) ]

C1/AA3E: DA           PHX 
C1/AA3F: C2 20        REP #$20
C1/AA41: 0A           ASL 
C1/AA42: 0A           ASL 
C1/AA43: 0A           ASL 
C1/AA44: 0A           ASL 
C1/AA45: AA           TAX 
C1/AA46: 7B           TDC 
C1/AA47: E2 20        SEP #$20
C1/AA49: A9 20        LDA #$20
C1/AA4B: 85 70        STA $70
C1/AA4D: BF A0 A3 D1  LDA $D1A3A0,X   ; load 16-color palette
C1/AA51: 99 09 7E     STA $7E09,Y
C1/AA54: E8           INX 
C1/AA55: C8           INY 
C1/AA56: C6 70        DEC $70
C1/AA58: D0 F3        BNE $AA4D
C1/AA5A: FA           PLX 
C1/AA5B: 60           RTS 

; [ init tile pointers (3bpp) ]

C1/AA5C: 48           PHA 
C1/AA5D: 7B           TDC 
C1/AA5E: AA           TAX 
C1/AA5F: C2 20        REP #$20
C1/AA61: 9F 00 C0 7F  STA $7FC000,X
C1/AA65: 18           CLC 
C1/AA66: 69 18 00     ADC #$0018
C1/AA69: E8           INX 
C1/AA6A: E8           INX 
C1/AA6B: E0 00 08     CPX #$0800
C1/AA6E: D0 F1        BNE $AA61
C1/AA70: 7B           TDC 
C1/AA71: E2 20        SEP #$20
C1/AA73: 68           PLA 
C1/AA74: 60           RTS 

; [ init tile pointers (4bpp) ]

C1/AA75: 48           PHA 
C1/AA76: 7B           TDC 
C1/AA77: AA           TAX 
C1/AA78: C2 20        REP #$20
C1/AA7A: 9F 00 C0 7F  STA $7FC000,X
C1/AA7E: 18           CLC 
C1/AA7F: 69 20 00     ADC #$0020
C1/AA82: E8           INX 
C1/AA83: E8           INX 
C1/AA84: E0 00 08     CPX #$0800
C1/AA87: D0 F1        BNE $AA7A
C1/AA89: 7B           TDC 
C1/AA8A: E2 20        SEP #$20
C1/AA8C: 68           PLA 
C1/AA8D: 60           RTS 

; [ load weapon graphics ]

C1/AA8E: DA           PHX 
C1/AA8F: 48           PHA 
C1/AA90: A9 01        LDA #$01
C1/AA92: 20 FE AA     JSR $AAFE       ; load attack graphics pointers (weapons)
C1/AA95: 20 5C AA     JSR $AA5C       ; init tile pointers (3bpp)
C1/AA98: 68           PLA 
C1/AA99: 20 1A AB     JSR $AB1A
C1/AA9C: FA           PLX 
C1/AA9D: 60           RTS 

; [ load weapon hit graphics ]

C1/AA9E: DA           PHX 
C1/AA9F: 48           PHA 
C1/AAA0: A9 02        LDA #$02
C1/AAA2: 20 FE AA     JSR $AAFE       ; load attack graphics pointers (weapon hits)
C1/AAA5: 20 5C AA     JSR $AA5C       ; init tile pointers (3bpp)
C1/AAA8: 68           PLA 
C1/AAA9: 20 1A AB     JSR $AB1A
C1/AAAC: FA           PLX 
C1/AAAD: 60           RTS 

; [ load alt. weapon graphics ]

C1/AAAE: DA           PHX 
C1/AAAF: 48           PHA 
C1/AAB0: A9 06        LDA #$06
C1/AAB2: 20 FE AA     JSR $AAFE       ; load attack graphics pointers (weapons alt.)
C1/AAB5: 20 5C AA     JSR $AA5C       ; init tile pointers (3bpp)
C1/AAB8: 68           PLA 
C1/AAB9: 20 1A AB     JSR $AB1A
C1/AABC: FA           PLX 
C1/AABD: 60           RTS 

; [ load spell 1 graphics ]

C1/AABE: DA           PHX 
C1/AABF: 48           PHA 
C1/AAC0: A9 00        LDA #$00
C1/AAC2: 20 FE AA     JSR $AAFE       ; load attack graphics pointers (spells 1)
C1/AAC5: 20 5C AA     JSR $AA5C       ; init tile pointers (3bpp)
C1/AAC8: 68           PLA 
C1/AAC9: 20 1A AB     JSR $AB1A
C1/AACC: FA           PLX 
C1/AACD: 60           RTS 

; [ load spell 2 graphics ]

C1/AACE: DA           PHX 
C1/AACF: 48           PHA 
C1/AAD0: A9 03        LDA #$03
C1/AAD2: 20 FE AA     JSR $AAFE       ; load attack graphics pointers (spells 2)
C1/AAD5: 20 5C AA     JSR $AA5C       ; init tile pointers (3bpp)
C1/AAD8: 68           PLA 
C1/AAD9: 20 1A AB     JSR $AB1A
C1/AADC: FA           PLX 
C1/AADD: 60           RTS 

; [ load spell 3 graphics ]

C1/AADE: DA           PHX 
C1/AADF: 48           PHA 
C1/AAE0: A9 04        LDA #$04
C1/AAE2: 20 FE AA     JSR $AAFE       ; load attack graphics pointers (spells 3)
C1/AAE5: 20 5C AA     JSR $AA5C       ; init tile pointers (3bpp)
C1/AAE8: 68           PLA 
C1/AAE9: 20 1A AB     JSR $AB1A
C1/AAEC: FA           PLX 
C1/AAED: 60           RTS 

; [ load animals graphics ]

C1/AAEE: DA           PHX 
C1/AAEF: 48           PHA 
C1/AAF0: A9 05        LDA #$05
C1/AAF2: 20 FE AA     JSR $AAFE       ; load attack graphics pointers (animals)
C1/AAF5: 20 75 AA     JSR $AA75       ; init tile pointers (4bpp)
C1/AAF8: 68           PLA 
C1/AAF9: 20 D7 AB     JSR $ABD7
C1/AAFC: FA           PLX 
C1/AAFD: 60           RTS 

; [ load attack graphics pointers ]

; A: 0 = spells 1, 1 = weapon, 2 = weapon hits,
;    3 = spells 2, 4 = spells 3, 5 = animals, 6 = weapons alt.

C1/AAFE: 85 7E        STA $7E
C1/AB00: A9 0C        LDA #$0C
C1/AB02: 85 80        STA $80
C1/AB04: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/AB07: A6 82        LDX $82
C1/AB09: 7B           TDC 
C1/AB0A: A8           TAY 
C1/AB0B: BF 68 DF D0  LDA $D0DF68,X   ; copy 12 bytes
C1/AB0F: 99 70 00     STA $0070,Y
C1/AB12: E8           INX 
C1/AB13: C8           INY 
C1/AB14: C0 0C 00     CPY #$000C
C1/AB17: D0 F2        BNE $AB0B
C1/AB19: 60           RTS 

; [ load attack graphics (3bpp) ]

C1/AB1A: C2 20        REP #$20
C1/AB1C: 0A           ASL 
C1/AB1D: 0A           ASL 
C1/AB1E: 0A           ASL 
C1/AB1F: 0A           ASL 
C1/AB20: 0A           ASL 
C1/AB21: 0A           ASL 
C1/AB22: 18           CLC 
C1/AB23: 65 70        ADC $70
C1/AB25: 85 70        STA $70
C1/AB27: A5 7A        LDA $7A
C1/AB29: 48           PHA 
C1/AB2A: A5 76        LDA $76
C1/AB2C: 85 80        STA $80         ; graphics bank
C1/AB2E: A9 00 D0     LDA #$D000
C1/AB31: 85 82        STA $82
C1/AB33: A9 7F 00     LDA #$007F
C1/AB36: 85 84        STA $84
C1/AB38: A7 70        LDA [$70]       ; tilemap value (vhtttttt)
C1/AB3A: EB           XBA 
C1/AB3B: 48           PHA 
C1/AB3C: 48           PHA 
C1/AB3D: 29 FF 3F     AND #$3FFF      ; tile index
C1/AB40: 0A           ASL 
C1/AB41: AA           TAX 
C1/AB42: 29 FF 07     AND #$07FF
C1/AB45: BF 00 C0 7F  LDA $7FC000,X   ; tile pointer
C1/AB49: 18           CLC 
C1/AB4A: 65 74        ADC $74
C1/AB4C: 85 7E        STA $7E         ; graphics address
C1/AB4E: 68           PLA 
C1/AB4F: 29 00 40     AND #$4000      ; h-flip
C1/AB52: 85 86        STA $86
C1/AB54: 68           PLA 
C1/AB55: 29 00 80     AND #$8000      ; v-flip
C1/AB58: D0 2A        BNE $AB84

; no v-flip
C1/AB5A: 7B           TDC 
C1/AB5B: A8           TAY 
C1/AB5C: A7 7E        LDA [$7E]       ; get word (first 2 bitplanes)
C1/AB5E: 20 91 AC     JSR $AC91       ; flip horizontally
C1/AB61: 97 82        STA [$82],Y     ; copy to ram buffer
C1/AB63: E6 7E        INC $7E
C1/AB65: E6 7E        INC $7E
C1/AB67: C8           INY 
C1/AB68: C8           INY 
C1/AB69: C0 10 00     CPY #$0010
C1/AB6C: D0 EE        BNE $AB5C
C1/AB6E: A7 7E        LDA [$7E]       ; get byte (3rd bitplane)
C1/AB70: 20 91 AC     JSR $AC91       ; flip horizontally
C1/AB73: 29 FF 00     AND #$00FF
C1/AB76: 97 82        STA [$82],Y
C1/AB78: E6 7E        INC $7E
C1/AB7A: C8           INY 
C1/AB7B: C8           INY 
C1/AB7C: C0 20 00     CPY #$0020
C1/AB7F: D0 ED        BNE $AB6E
C1/AB81: 4C AF AB     JMP $ABAF

; v-flip
C1/AB84: A0 0E 00     LDY #$000E
C1/AB87: A7 7E        LDA [$7E]
C1/AB89: 20 91 AC     JSR $AC91       ; flip horizontally
C1/AB8C: 97 82        STA [$82],Y
C1/AB8E: E6 7E        INC $7E
C1/AB90: E6 7E        INC $7E
C1/AB92: 88           DEY 
C1/AB93: 88           DEY 
C1/AB94: C0 FE FF     CPY #$FFFE
C1/AB97: D0 EE        BNE $AB87
C1/AB99: A0 1E 00     LDY #$001E
C1/AB9C: A7 7E        LDA [$7E]
C1/AB9E: 20 91 AC     JSR $AC91       ; flip horizontally
C1/ABA1: 29 FF 00     AND #$00FF
C1/ABA4: 97 82        STA [$82],Y
C1/ABA6: E6 7E        INC $7E
C1/ABA8: 88           DEY 
C1/ABA9: 88           DEY 
C1/ABAA: C0 0E 00     CPY #$000E
C1/ABAD: D0 ED        BNE $AB9C
C1/ABAF: A5 82        LDA $82         ; next tile
C1/ABB1: 18           CLC 
C1/ABB2: 69 20 00     ADC #$0020
C1/ABB5: 85 82        STA $82
C1/ABB7: E6 70        INC $70
C1/ABB9: E6 70        INC $70
C1/ABBB: C6 7A        DEC $7A
C1/ABBD: F0 03        BEQ $ABC2
C1/ABBF: 4C 38 AB     JMP $AB38
C1/ABC2: 68           PLA             ; copy tile to vram
C1/ABC3: 0A           ASL 
C1/ABC4: 0A           ASL 
C1/ABC5: 0A           ASL 
C1/ABC6: 0A           ASL 
C1/ABC7: 0A           ASL 
C1/ABC8: 85 70        STA $70
C1/ABCA: 7B           TDC 
C1/ABCB: E2 20        SEP #$20
C1/ABCD: A2 00 D0     LDX #$D000
C1/ABD0: A9 7F        LDA #$7F
C1/ABD2: A4 78        LDY $78
C1/ABD4: 4C 27 FD     JMP $FD27

; [ [ load attack graphics (4bpp) ]

C1/ABD7: C2 20        REP #$20
C1/ABD9: 0A           ASL 
C1/ABDA: 0A           ASL 
C1/ABDB: 0A           ASL 
C1/ABDC: 0A           ASL 
C1/ABDD: 0A           ASL 
C1/ABDE: 0A           ASL 
C1/ABDF: 18           CLC 
C1/ABE0: 65 70        ADC $70
C1/ABE2: 85 70        STA $70
C1/ABE4: A5 7A        LDA $7A
C1/ABE6: 48           PHA 
C1/ABE7: A5 76        LDA $76         ; tile graphics bank
C1/ABE9: 85 80        STA $80
C1/ABEB: A9 00 D0     LDA #$D000      ; graphics buffer address
C1/ABEE: 85 82        STA $82
C1/ABF0: A9 7F 00     LDA #$007F      ; graphics buffer bank
C1/ABF3: 85 84        STA $84
C1/ABF5: A7 70        LDA [$70]       ; tilemap value (vhtttttt)
C1/ABF7: EB           XBA 
C1/ABF8: 48           PHA 
C1/ABF9: 48           PHA 
C1/ABFA: 29 FF 3F     AND #$3FFF      ; tile index
C1/ABFD: 0A           ASL 
C1/ABFE: 29 FF 07     AND #$07FF
C1/AC01: AA           TAX 
C1/AC02: BF 00 C0 7F  LDA $7FC000,X   ; tile pointer
C1/AC06: 18           CLC 
C1/AC07: 65 74        ADC $74         ; tile offset
C1/AC09: 85 7E        STA $7E
C1/AC0B: 68           PLA 
C1/AC0C: 29 00 40     AND #$4000      ; h-flip
C1/AC0F: 85 86        STA $86
C1/AC11: 68           PLA 
C1/AC12: 29 00 80     AND #$8000      ; v-flip
C1/AC15: D0 28        BNE $AC3F
C1/AC17: A8           TAY 
C1/AC18: A7 7E        LDA [$7E]
C1/AC1A: 20 91 AC     JSR $AC91       ; flip horizontally
C1/AC1D: 97 82        STA [$82],Y
C1/AC1F: E6 7E        INC $7E
C1/AC21: E6 7E        INC $7E
C1/AC23: C8           INY 
C1/AC24: C8           INY 
C1/AC25: C0 10 00     CPY #$0010
C1/AC28: D0 EE        BNE $AC18
C1/AC2A: A7 7E        LDA [$7E]
C1/AC2C: 20 91 AC     JSR $AC91       ; flip horizontally
C1/AC2F: 97 82        STA [$82],Y
C1/AC31: E6 7E        INC $7E
C1/AC33: E6 7E        INC $7E
C1/AC35: C8           INY 
C1/AC36: C8           INY 
C1/AC37: C0 20 00     CPY #$0020
C1/AC3A: D0 EE        BNE $AC2A
C1/AC3C: 4C 69 AC     JMP $AC69
C1/AC3F: A0 0E 00     LDY #$000E
C1/AC42: A7 7E        LDA [$7E]
C1/AC44: 20 91 AC     JSR $AC91       ; flip horizontally
C1/AC47: 97 82        STA [$82],Y
C1/AC49: E6 7E        INC $7E
C1/AC4B: E6 7E        INC $7E
C1/AC4D: 88           DEY 
C1/AC4E: 88           DEY 
C1/AC4F: C0 FE FF     CPY #$FFFE
C1/AC52: D0 EE        BNE $AC42
C1/AC54: A0 1E 00     LDY #$001E
C1/AC57: A7 7E        LDA [$7E]
C1/AC59: 20 91 AC     JSR $AC91       ; flip horizontally
C1/AC5C: 97 82        STA [$82],Y
C1/AC5E: E6 7E        INC $7E
C1/AC60: E6 7E        INC $7E
C1/AC62: 88           DEY 
C1/AC63: 88           DEY 
C1/AC64: C0 0E 00     CPY #$000E
C1/AC67: D0 EE        BNE $AC57
C1/AC69: A5 82        LDA $82
C1/AC6B: 18           CLC 
C1/AC6C: 69 20 00     ADC #$0020
C1/AC6F: 85 82        STA $82
C1/AC71: E6 70        INC $70
C1/AC73: E6 70        INC $70
C1/AC75: C6 7A        DEC $7A
C1/AC77: F0 03        BEQ $AC7C
C1/AC79: 4C F5 AB     JMP $ABF5
C1/AC7C: 68           PLA 
C1/AC7D: 0A           ASL 
C1/AC7E: 0A           ASL 
C1/AC7F: 0A           ASL 
C1/AC80: 0A           ASL 
C1/AC81: 0A           ASL 
C1/AC82: 85 70        STA $70
C1/AC84: 7B           TDC 
C1/AC85: E2 20        SEP #$20
C1/AC87: A2 00 D0     LDX #$D000
C1/AC8A: A9 7F        LDA #$7F
C1/AC8C: A4 78        LDY $78
C1/AC8E: 4C 27 FD     JMP $FD27

; [ flip horizontally ]

C1/AC91: 48           PHA 
C1/AC92: A5 86        LDA $86         ; return if no horizontal flip
C1/AC94: F0 10        BEQ $ACA6
C1/AC96: 68           PLA 
C1/AC97: EB           XBA 
C1/AC98: 85 7C        STA $7C
C1/AC9A: DA           PHX 
C1/AC9B: A2 10 00     LDX #$0010
C1/AC9E: 06 7C        ASL $7C
C1/ACA0: 6A           ROR 
C1/ACA1: CA           DEX 
C1/ACA2: D0 FA        BNE $AC9E
C1/ACA4: FA           PLX 
C1/ACA5: 60           RTS 
C1/ACA6: 68           PLA 
C1/ACA7: 60           RTS 

; [  ]

C1/ACA8: 7B           TDC 
C1/ACA9: AA           TAX 
C1/ACAA: BD 80 DB     LDA $DB80,X
C1/ACAD: F0 32        BEQ $ACE1
C1/ACAF: 8A           TXA 
C1/ACB0: 0A           ASL 
C1/ACB1: A8           TAY 
C1/ACB2: C2 20        REP #$20
C1/ACB4: B9 88 DB     LDA $DB88,Y
C1/ACB7: 8F 16 21 00  STA $002116
C1/ACBB: B9 7C F8     LDA $F87C,Y
C1/ACBE: D0 02        BNE $ACC2
C1/ACC0: 80 1C        BRA $ACDE
C1/ACC2: B9 7C F8     LDA $F87C,Y
C1/ACC5: 29 FF 00     AND #$00FF
C1/ACC8: 1A           INC 
C1/ACC9: 09 00 3C     ORA #$3C00
C1/ACCC: 8F 18 21 00  STA $002118
C1/ACD0: B9 7D F8     LDA $F87D,Y
C1/ACD3: 29 FF 00     AND #$00FF
C1/ACD6: 1A           INC 
C1/ACD7: 09 00 3C     ORA #$3C00
C1/ACDA: 8F 18 21 00  STA $002118
C1/ACDE: 7B           TDC 
C1/ACDF: E2 20        SEP #$20
C1/ACE1: E8           INX 
C1/ACE2: E0 08 00     CPX #$0008
C1/ACE5: D0 C3        BNE $ACAA
C1/ACE7: 60           RTS 
C1/ACE8: DA           PHX 
C1/ACE9: 5A           PHY 
C1/ACEA: 84 72        STY $72
C1/ACEC: BB           TYX 
C1/ACED: A5 72        LDA $72
C1/ACEF: 0A           ASL 
C1/ACF0: A8           TAY 
C1/ACF1: BD 16 D0     LDA $D016,X
C1/ACF4: 18           CLC 
C1/ACF5: 7D 06 D0     ADC $D006,X
C1/ACF8: 3A           DEC 
C1/ACF9: 85 72        STA $72
C1/ACFB: 64 73        STZ $73
C1/ACFD: BD FE CF     LDA $CFFE,X
C1/AD00: 4A           LSR 
C1/AD01: 3A           DEC 
C1/AD02: 18           CLC 
C1/AD03: 7D 0E D0     ADC $D00E,X
C1/AD06: 85 74        STA $74
C1/AD08: A5 F6        LDA $F6
C1/AD0A: F0 07        BEQ $AD13
C1/AD0C: A9 1E        LDA #$1E
C1/AD0E: 38           SEC 
C1/AD0F: E5 74        SBC $74
C1/AD11: 85 74        STA $74
C1/AD13: 64 75        STZ $75
C1/AD15: C2 20        REP #$20
C1/AD17: A5 72        LDA $72
C1/AD19: 0A           ASL 
C1/AD1A: 0A           ASL 
C1/AD1B: 0A           ASL 
C1/AD1C: 0A           ASL 
C1/AD1D: 0A           ASL 
C1/AD1E: 18           CLC 
C1/AD1F: 65 74        ADC $74
C1/AD21: 69 00 58     ADC #$5800
C1/AD24: 99 88 DB     STA $DB88,Y
C1/AD27: 7B           TDC 
C1/AD28: E2 20        SEP #$20
C1/AD2A: 7A           PLY 
C1/AD2B: FA           PLX 
C1/AD2C: 60           RTS 

; [  ]

C1/AD2D: 7B           TDC 
C1/AD2E: AA           TAX 
C1/AD2F: A8           TAY 
C1/AD30: 64 70        STZ $70
C1/AD32: A5 DE        LDA $DE
C1/AD34: 85 71        STA $71
C1/AD36: 06 71        ASL $71
C1/AD38: 90 1B        BCC $AD55
C1/AD3A: BD 9E 7B     LDA $7B9E,X
C1/AD3D: 29 C0        AND #$C0
C1/AD3F: D0 14        BNE $AD55
C1/AD41: BD A1 7B     LDA $7BA1,X
C1/AD44: 29 10        AND #$10
C1/AD46: F0 0D        BEQ $AD55
C1/AD48: 20 E0 AF     JSR $AFE0
C1/AD4B: 20 E8 AC     JSR $ACE8
C1/AD4E: A9 01        LDA #$01
C1/AD50: 99 80 DB     STA $DB80,Y
C1/AD53: 80 04        BRA $AD59
C1/AD55: 7B           TDC 
C1/AD56: 99 80 DB     STA $DB80,Y
C1/AD59: C8           INY 
C1/AD5A: E8           INX 
C1/AD5B: E8           INX 
C1/AD5C: E8           INX 
C1/AD5D: E8           INX 
C1/AD5E: E0 20 00     CPX #$0020
C1/AD61: D0 D3        BNE $AD36
C1/AD63: 60           RTS 

C1/AD64: 7B           TDC 
C1/AD65: AA           TAX 
C1/AD66: A8           TAY 
C1/AD67: 64 70        STZ $70
C1/AD69: 64 72        STZ $72
C1/AD6B: BD 9E 7B     LDA $7B9E,X
C1/AD6E: 0A           ASL 
C1/AD6F: 26 70        ROL $70
C1/AD71: BD A1 7B     LDA $7BA1,X
C1/AD74: 0A           ASL 
C1/AD75: 26 72        ROL $72
C1/AD77: C8           INY 
C1/AD78: E8           INX 
C1/AD79: E8           INX 
C1/AD7A: E8           INX 
C1/AD7B: E8           INX 
C1/AD7C: E0 20 00     CPX #$0020
C1/AD7F: D0 EA        BNE $AD6B
C1/AD81: A5 70        LDA $70
C1/AD83: 05 72        ORA $72
C1/AD85: 85 70        STA $70
C1/AD87: A5 70        LDA $70
C1/AD89: 48           PHA 
C1/AD8A: 25 DE        AND $DE
C1/AD8C: F0 05        BEQ $AD93
C1/AD8E: 85 70        STA $70
C1/AD90: 20 8D 76     JSR $768D
C1/AD93: 68           PLA 
C1/AD94: 49 FF        EOR #$FF
C1/AD96: 85 70        STA $70
C1/AD98: A5 DE        LDA $DE
C1/AD9A: 49 FF        EOR #$FF
C1/AD9C: 25 70        AND $70
C1/AD9E: F0 05        BEQ $ADA5
C1/ADA0: 85 70        STA $70
C1/ADA2: 20 D7 75     JSR $75D7
C1/ADA5: 7B           TDC 
C1/ADA6: AA           TAX 
C1/ADA7: BD 9E 7B     LDA $7B9E,X
C1/ADAA: 29 30        AND #$30
C1/ADAC: 85 70        STA $70
C1/ADAE: BD BE 7B     LDA $7BBE,X
C1/ADB1: 29 30        AND #$30
C1/ADB3: C5 70        CMP $70
C1/ADB5: D0 2B        BNE $ADE2
C1/ADB7: BD 9F 7B     LDA $7B9F,X
C1/ADBA: 29 10        AND #$10
C1/ADBC: 85 70        STA $70
C1/ADBE: BD BF 7B     LDA $7BBF,X
C1/ADC1: 29 10        AND #$10
C1/ADC3: C5 70        CMP $70
C1/ADC5: D0 1B        BNE $ADE2
C1/ADC7: BD A1 7B     LDA $7BA1,X
C1/ADCA: 29 20        AND #$20
C1/ADCC: 85 70        STA $70
C1/ADCE: BD C1 7B     LDA $7BC1,X
C1/ADD1: 29 20        AND #$20
C1/ADD3: C5 70        CMP $70
C1/ADD5: D0 0B        BNE $ADE2
C1/ADD7: E8           INX 
C1/ADD8: E8           INX 
C1/ADD9: E8           INX 
C1/ADDA: E8           INX 
C1/ADDB: E0 20 00     CPX #$0020
C1/ADDE: D0 C7        BNE $ADA7
C1/ADE0: 80 40        BRA $AE22
C1/ADE2: 7B           TDC 
C1/ADE3: A8           TAY 
C1/ADE4: AA           TAX 
C1/ADE5: B9 9F 7B     LDA $7B9F,Y
C1/ADE8: 29 10        AND #$10
C1/ADEA: 4A           LSR 
C1/ADEB: 4A           LSR 
C1/ADEC: 4A           LSR 
C1/ADED: 4A           LSR 
C1/ADEE: 85 70        STA $70
C1/ADF0: B9 A1 7B     LDA $7BA1,Y
C1/ADF3: 29 20        AND #$20
C1/ADF5: 4A           LSR 
C1/ADF6: 4A           LSR 
C1/ADF7: 4A           LSR 
C1/ADF8: 4A           LSR 
C1/ADF9: 4A           LSR 
C1/ADFA: 05 70        ORA $70
C1/ADFC: 85 70        STA $70
C1/ADFE: BD 9C DB     LDA $DB9C,X
C1/AE01: 29 02        AND #$02
C1/AE03: F0 06        BEQ $AE0B
C1/AE05: A5 70        LDA $70
C1/AE07: 49 01        EOR #$01
C1/AE09: 85 70        STA $70
C1/AE0B: BD 9C DB     LDA $DB9C,X
C1/AE0E: 29 FE        AND #$FE
C1/AE10: 05 70        ORA $70
C1/AE12: 9D 9C DB     STA $DB9C,X
C1/AE15: E8           INX 
C1/AE16: C8           INY 
C1/AE17: C8           INY 
C1/AE18: C8           INY 
C1/AE19: C8           INY 
C1/AE1A: E0 08 00     CPX #$0008
C1/AE1D: D0 C6        BNE $ADE5
C1/AE1F: 20 B8 1C     JSR $1CB8
C1/AE22: 7B           TDC 
C1/AE23: AA           TAX 
C1/AE24: A8           TAY 
C1/AE25: B9 9E 7B     LDA $7B9E,Y
C1/AE28: 29 30        AND #$30
C1/AE2A: F0 0D        BEQ $AE39
C1/AE2C: BD FE CF     LDA $CFFE,X
C1/AE2F: 0A           ASL 
C1/AE30: 0A           ASL 
C1/AE31: 38           SEC 
C1/AE32: E9 0C        SBC #$0C
C1/AE34: 9D 96 D0     STA $D096,X
C1/AE37: 80 03        BRA $AE3C
C1/AE39: 9E 96 D0     STZ $D096,X
C1/AE3C: C8           INY 
C1/AE3D: C8           INY 
C1/AE3E: C8           INY 
C1/AE3F: C8           INY 
C1/AE40: E8           INX 
C1/AE41: E0 08 00     CPX #$0008
C1/AE44: D0 DF        BNE $AE25
C1/AE46: 4C 49 AE     JMP $AE49
C1/AE49: 7B           TDC 
C1/AE4A: AA           TAX 
C1/AE4B: BD 9E 7B     LDA $7B9E,X
C1/AE4E: 9D BE 7B     STA $7BBE,X
C1/AE51: E8           INX 
C1/AE52: E0 20 00     CPX #$0020
C1/AE55: D0 F4        BNE $AE4B
C1/AE57: 60           RTS 
C1/AE58: 5A           PHY 
C1/AE59: DA           PHX 
C1/AE5A: DA           PHX 
C1/AE5B: 20 F2 02     JSR $02F2       ; wait one frame
C1/AE5E: FA           PLX 
C1/AE5F: CA           DEX 
C1/AE60: D0 F8        BNE $AE5A
C1/AE62: FA           PLX 
C1/AE63: 7A           PLY 
C1/AE64: 60           RTS 
C1/AE65: DA           PHX 
C1/AE66: 5A           PHY 
C1/AE67: DA           PHX 
C1/AE68: 8A           TXA 
C1/AE69: 0A           ASL 
C1/AE6A: 0A           ASL 
C1/AE6B: 0A           ASL 
C1/AE6C: 0A           ASL 
C1/AE6D: 0A           ASL 
C1/AE6E: A8           TAY 
C1/AE6F: A9 01        LDA #$01
C1/AE71: 99 61 CF     STA $CF61,Y
C1/AE74: A2 10 00     LDX #$0010
C1/AE77: 20 58 AE     JSR $AE58
C1/AE7A: 7B           TDC 
C1/AE7B: 99 58 CF     STA $CF58,Y
C1/AE7E: 99 57 CF     STA $CF57,Y
C1/AE81: FA           PLX 
C1/AE82: 8A           TXA 
C1/AE83: 85 7A        STA $7A
C1/AE85: 20 9F B0     JSR $B09F
C1/AE88: 8A           TXA 
C1/AE89: 20 05 AF     JSR $AF05
C1/AE8C: 20 D7 AE     JSR $AED7
C1/AE8F: A2 10 00     LDX #$0010
C1/AE92: 20 58 AE     JSR $AE58
C1/AE95: 7B           TDC 
C1/AE96: 99 61 CF     STA $CF61,Y
C1/AE99: 7A           PLY 
C1/AE9A: FA           PLX 
C1/AE9B: 60           RTS 
C1/AE9C: 7B           TDC 
C1/AE9D: AA           TAX 
C1/AE9E: 9E CF D1     STZ $D1CF,X
C1/AEA1: BD CB D1     LDA $D1CB,X
C1/AEA4: D0 27        BNE $AECD
C1/AEA6: 8A           TXA 
C1/AEA7: 0A           ASL 
C1/AEA8: 0A           ASL 
C1/AEA9: A8           TAY 
C1/AEAA: B9 7E 7B     LDA $7B7E,Y
C1/AEAD: 30 0A        BMI $AEB9
C1/AEAF: B9 8E 7B     LDA $7B8E,Y
C1/AEB2: 10 0F        BPL $AEC3
C1/AEB4: 20 65 AE     JSR $AE65
C1/AEB7: 80 14        BRA $AECD
C1/AEB9: B9 8E 7B     LDA $7B8E,Y
C1/AEBC: 30 05        BMI $AEC3
C1/AEBE: 20 65 AE     JSR $AE65
C1/AEC1: 80 0A        BRA $AECD
C1/AEC3: 8A           TXA 
C1/AEC4: 85 7A        STA $7A
C1/AEC6: 20 9F B0     JSR $B09F
C1/AEC9: 8A           TXA 
C1/AECA: 20 05 AF     JSR $AF05
C1/AECD: 20 D7 AE     JSR $AED7
C1/AED0: E8           INX 
C1/AED1: E0 04 00     CPX #$0004
C1/AED4: D0 C8        BNE $AE9E
C1/AED6: 60           RTS 
C1/AED7: 5A           PHY 
C1/AED8: 8A           TXA 
C1/AED9: 0A           ASL 
C1/AEDA: 0A           ASL 
C1/AEDB: A8           TAY 
C1/AEDC: B9 7E 7B     LDA $7B7E,Y
C1/AEDF: 99 8E 7B     STA $7B8E,Y
C1/AEE2: B9 7F 7B     LDA $7B7F,Y
C1/AEE5: 99 8F 7B     STA $7B8F,Y
C1/AEE8: B9 80 7B     LDA $7B80,Y
C1/AEEB: 99 90 7B     STA $7B90,Y
C1/AEEE: B9 81 7B     LDA $7B81,Y
C1/AEF1: 99 91 7B     STA $7B91,Y
C1/AEF4: 7A           PLY 
C1/AEF5: 60           RTS 
C1/AEF6: 4C 9C AE     JMP $AE9C
C1/AEF9: AA           TAX 
C1/AEFA: 0A           ASL 
C1/AEFB: 0A           ASL 
C1/AEFC: 0A           ASL 
C1/AEFD: 0A           ASL 
C1/AEFE: 0A           ASL 
C1/AEFF: A8           TAY 
C1/AF00: 85 74        STA $74
C1/AF02: 64 75        STZ $75
C1/AF04: 60           RTS 

; [  ]

C1/AF05: DA           PHX 
C1/AF06: 5A           PHY 
C1/AF07: 20 F9 AE     JSR $AEF9
C1/AF0A: B9 43 CF     LDA $CF43,Y
C1/AF0D: D0 0F        BNE $AF1E
C1/AF0F: B9 53 CF     LDA $CF53,Y
C1/AF12: D0 0A        BNE $AF1E
C1/AF14: 8A           TXA 
C1/AF15: 0A           ASL 
C1/AF16: 0A           ASL 
C1/AF17: AA           TAX 
C1/AF18: 20 21 AF     JSR $AF21       ; update character status animation
C1/AF1B: 20 1A B0     JSR $B01A       ; update character status sprite
C1/AF1E: 7A           PLY 
C1/AF1F: FA           PLX 
C1/AF20: 60           RTS 

; [ update character status animation ]

C1/AF21: BD 7E 7B     LDA $7B7E,X
C1/AF24: 29 80        AND #$80
C1/AF26: F0 04        BEQ $AF2C       ; branch if not dead
C1/AF28: A9 08        LDA #$08
C1/AF2A: 80 46        BRA $AF72
C1/AF2C: BD 7E 7B     LDA $7B7E,X
C1/AF2F: 29 40        AND #$40
C1/AF31: F0 04        BEQ $AF37       ; branch if not stone
C1/AF33: A9 03        LDA #$03
C1/AF35: 80 3B        BRA $AF72
C1/AF37: BD 7E 7B     LDA $7B7E,X
C1/AF3A: 29 02        AND #$02
C1/AF3C: F0 02        BEQ $AF40       ; branch if not zombie
C1/AF3E: 80 2C        BRA $AF6C
C1/AF40: BD 7E 7B     LDA $7B7E,X
C1/AF43: 29 44        AND #$44
C1/AF45: F0 04        BEQ $AF4B       ; branch if not poison ???
C1/AF47: A9 03        LDA #$03
C1/AF49: 80 27        BRA $AF72
C1/AF4B: BD 7F 7B     LDA $7B7F,X
C1/AF4E: 29 60        AND #$60
C1/AF50: F0 04        BEQ $AF56       ; branch if not paralyzed or sleeping
C1/AF52: A9 03        LDA #$03
C1/AF54: 80 1C        BRA $AF72
C1/AF56: BD 81 7B     LDA $7B81,X
C1/AF59: 29 02        AND #$02
C1/AF5B: F0 04        BEQ $AF61       ; branch if not low hp
C1/AF5D: A9 03        LDA #$03
C1/AF5F: 80 11        BRA $AF72
C1/AF61: BD 81 7B     LDA $7B81,X
C1/AF64: 29 04        AND #$04
C1/AF66: F0 04        BEQ $AF6C       ; branch if not singing
C1/AF68: A9 09        LDA #$09
C1/AF6A: 80 06        BRA $AF72
C1/AF6C: 7B           TDC 
C1/AF6D: 99 4D CF     STA $CF4D,Y
C1/AF70: 80 11        BRA $AF83
C1/AF72: 48           PHA 
C1/AF73: 20 87 B0     JSR $B087       ; check if character is selected
C1/AF76: 90 03        BCC $AF7B
C1/AF78: 68           PLA 
C1/AF79: 80 F1        BRA $AF6C
C1/AF7B: 68           PLA 
C1/AF7C: 99 4D CF     STA $CF4D,Y
C1/AF7F: 7B           TDC 
C1/AF80: 99 58 CF     STA $CF58,Y
C1/AF83: BD 7E 7B     LDA $7B7E,X
C1/AF86: 29 20        AND #$20
C1/AF88: F0 04        BEQ $AF8E       ; branch if not toad
C1/AF8A: A9 01        LDA #$01
C1/AF8C: 80 0C        BRA $AF9A
C1/AF8E: BD 7E 7B     LDA $7B7E,X
C1/AF91: 29 10        AND #$10
C1/AF93: F0 04        BEQ $AF99       ; branch if not mini
C1/AF95: A9 02        LDA #$02
C1/AF97: 80 01        BRA $AF9A
C1/AF99: 7B           TDC 
C1/AF9A: 99 47 CF     STA $CF47,Y     ; graphics
C1/AF9D: BD 7F 7B     LDA $7B7F,X
C1/AFA0: 29 03        AND #$03
C1/AFA2: 99 5A CF     STA $CF5A,Y     ; image charges
C1/AFA5: BD 7E 7B     LDA $7B7E,X
C1/AFA8: 29 08        AND #$08
C1/AFAA: 99 59 CF     STA $CF59,Y     ; float
C1/AFAD: BD 81 7B     LDA $7B81,X
C1/AFB0: 10 11        BPL $AFC3       ; branch if not erased
C1/AFB2: B9 62 CF     LDA $CF62,Y
C1/AFB5: 09 80        ORA #$80
C1/AFB7: 99 62 CF     STA $CF62,Y
C1/AFBA: B9 43 CF     LDA $CF43,Y
C1/AFBD: 09 80        ORA #$80
C1/AFBF: 99 43 CF     STA $CF43,Y
C1/AFC2: 60           RTS 
C1/AFC3: B9 62 CF     LDA $CF62,Y
C1/AFC6: 29 7F        AND #$7F
C1/AFC8: 99 62 CF     STA $CF62,Y
C1/AFCB: B9 43 CF     LDA $CF43,Y
C1/AFCE: 29 7F        AND #$7F
C1/AFD0: 99 43 CF     STA $CF43,Y
C1/AFD3: 60           RTS 

; 
C1/AFD4: 00 0B 16 21 2C 37 42 4D 58 63 6E 79

; [  ]

C1/AFE0: DA           PHX 
C1/AFE1: 8A           TXA 
C1/AFE2: 18           CLC 
C1/AFE3: 69 10        ADC #$10
C1/AFE5: AA           TAX 
C1/AFE6: 20 EB AF     JSR $AFEB
C1/AFE9: FA           PLX 
C1/AFEA: 60           RTS 

; [  ]

C1/AFEB: DA           PHX 
C1/AFEC: 8A           TXA 
C1/AFED: 4A           LSR 
C1/AFEE: 85 74        STA $74
C1/AFF0: 4A           LSR 
C1/AFF1: AA           TAX 
C1/AFF2: BF D4 AF C1  LDA $C1AFD4,X
C1/AFF6: AA           TAX 
C1/AFF7: 64 72        STZ $72
C1/AFF9: BD 78 3D     LDA $3D78,X
C1/AFFC: 38           SEC 
C1/AFFD: E9 0A        SBC #$0A
C1/AFFF: 90 05        BCC $B006
C1/B001: E6 72        INC $72
C1/B003: 4C FC AF     JMP $AFFC
C1/B006: 18           CLC 
C1/B007: 69 0A        ADC #$0A
C1/B009: 85 73        STA $73
C1/B00B: A5 74        LDA $74
C1/B00D: AA           TAX 
C1/B00E: A5 72        LDA $72
C1/B010: 9D 74 F8     STA $F874,X
C1/B013: A5 73        LDA $73
C1/B015: 9D 75 F8     STA $F875,X
C1/B018: FA           PLX 
C1/B019: 60           RTS 

; [ update character status sprite ]

C1/B01A: 5A           PHY 
C1/B01B: DA           PHX 
C1/B01C: A5 7A        LDA $7A
C1/B01E: A8           TAY 
C1/B01F: BD 7E 7B     LDA $7B7E,X     ; character status
C1/B022: 29 80        AND #$80
C1/B024: D0 50        BNE $B076       ; branch if dead
C1/B026: BD 81 7B     LDA $7B81,X
C1/B029: 29 10        AND #$10
C1/B02B: F0 07        BEQ $B034       ; branch if not condemned
C1/B02D: 20 EB AF     JSR $AFEB       ; 
C1/B030: A9 08        LDA #$08
C1/B032: 80 43        BRA $B077
C1/B034: BD 7E 7B     LDA $7B7E,X
C1/B037: 29 08        AND #$08
C1/B039: F0 04        BEQ $B03F       ; branch if not float
C1/B03B: A9 06        LDA #$06
C1/B03D: 80 38        BRA $B077
C1/B03F: BD 7E 7B     LDA $7B7E,X
C1/B042: 29 01        AND #$01
C1/B044: F0 04        BEQ $B04A       ; branch if not blind
C1/B046: A9 02        LDA #$02
C1/B048: 80 2D        BRA $B077
C1/B04A: BD 7F 7B     LDA $7B7F,X
C1/B04D: 29 40        AND #$40
C1/B04F: F0 04        BEQ $B055       ; branch if not sleeping
C1/B051: A9 03        LDA #$03
C1/B053: 80 22        BRA $B077
C1/B055: BD 7F 7B     LDA $7B7F,X
C1/B058: 29 20        AND #$20
C1/B05A: F0 04        BEQ $B060       ; branch if not paralyzed
C1/B05C: A9 04        LDA #$04
C1/B05E: 80 17        BRA $B077
C1/B060: BD 7F 7B     LDA $7B7F,X
C1/B063: 29 10        AND #$10
C1/B065: F0 04        BEQ $B06B       ; branch if not charmed
C1/B067: A9 05        LDA #$05
C1/B069: 80 0C        BRA $B077
C1/B06B: BD 7F 7B     LDA $7B7F,X
C1/B06E: 29 04        AND #$04
C1/B070: F0 04        BEQ $B076       ; branch if not mute
C1/B072: A9 01        LDA #$01
C1/B074: 80 01        BRA $B077
C1/B076: 7B           TDC 
C1/B077: 99 CF D1     STA $D1CF,Y
C1/B07A: 20 87 B0     JSR $B087       ; check if character is selected
C1/B07D: 90 05        BCC $B084
C1/B07F: A9 07        LDA #$07        ; show selected indicator
C1/B081: 99 CF D1     STA $D1CF,Y
C1/B084: FA           PLX 
C1/B085: 7A           PLY 
C1/B086: 60           RTS 

; [ check if character is selected ]

C1/B087: AD 40 CD     LDA $CD40
C1/B08A: D0 11        BNE $B09D
C1/B08C: AD B0 41     LDA $41B0
C1/B08F: 29 01        AND #$01
C1/B091: F0 0A        BEQ $B09D
C1/B093: 8A           TXA 
C1/B094: 4A           LSR 
C1/B095: 4A           LSR 
C1/B096: CD 42 CD     CMP $CD42
C1/B099: D0 02        BNE $B09D
C1/B09B: 38           SEC 
C1/B09C: 60           RTS 
C1/B09D: 18           CLC 
C1/B09E: 60           RTS 

; [  ]

C1/B09F: DA           PHX 
C1/B0A0: 5A           PHY 
C1/B0A1: AA           TAX 
C1/B0A2: C2 20        REP #$20
C1/B0A4: 0A           ASL 
C1/B0A5: 0A           ASL 
C1/B0A6: 0A           ASL 
C1/B0A7: 0A           ASL 
C1/B0A8: 0A           ASL 
C1/B0A9: A8           TAY 
C1/B0AA: 85 74        STA $74
C1/B0AC: 7B           TDC 
C1/B0AD: E2 20        SEP #$20
C1/B0AF: B9 43 CF     LDA $CF43,Y
C1/B0B2: D0 4F        BNE $B103
C1/B0B4: B9 53 CF     LDA $CF53,Y
C1/B0B7: D0 4A        BNE $B103
C1/B0B9: 8A           TXA 
C1/B0BA: 85 70        STA $70
C1/B0BC: 0A           ASL 
C1/B0BD: 0A           ASL 
C1/B0BE: A8           TAY 
C1/B0BF: B9 7E 7B     LDA $7B7E,Y
C1/B0C2: 29 C0        AND #$C0
C1/B0C4: D0 3D        BNE $B103
C1/B0C6: BD BD D1     LDA $D1BD,X
C1/B0C9: F0 1E        BEQ $B0E9
C1/B0CB: B9 7F 7B     LDA $7B7F,Y
C1/B0CE: 29 10        AND #$10
C1/B0D0: D0 31        BNE $B103
C1/B0D2: 9E BD D1     STZ $D1BD,X
C1/B0D5: 20 06 B1     JSR $B106
C1/B0D8: 09 80        ORA #$80
C1/B0DA: 99 54 CF     STA $CF54,Y
C1/B0DD: A9 02        LDA #$02
C1/B0DF: 99 4D CF     STA $CF4D,Y
C1/B0E2: A9 01        LDA #$01
C1/B0E4: 99 53 CF     STA $CF53,Y
C1/B0E7: 80 1A        BRA $B103
C1/B0E9: B9 7F 7B     LDA $7B7F,Y
C1/B0EC: 29 10        AND #$10
C1/B0EE: F0 13        BEQ $B103
C1/B0F0: FE BD D1     INC $D1BD,X
C1/B0F3: 20 06 B1     JSR $B106
C1/B0F6: 99 54 CF     STA $CF54,Y
C1/B0F9: A9 02        LDA #$02
C1/B0FB: 99 4D CF     STA $CF4D,Y
C1/B0FE: A9 01        LDA #$01
C1/B100: 99 53 CF     STA $CF53,Y
C1/B103: 7A           PLY 
C1/B104: FA           PLX 
C1/B105: 60           RTS 
C1/B106: A4 74        LDY $74
C1/B108: A5 70        LDA $70
C1/B10A: AA           TAX 
C1/B10B: BD 4A DB     LDA $DB4A,X
C1/B10E: F0 04        BEQ $B114
C1/B110: A9 30        LDA #$30
C1/B112: 80 02        BRA $B116
C1/B114: A9 20        LDA #$20
C1/B116: 60           RTS 
C1/B117: 7B           TDC 
C1/B118: AA           TAX 
C1/B119: BD 7E 7B     LDA $7B7E,X
C1/B11C: 9D 8E 7B     STA $7B8E,X
C1/B11F: E8           INX 
C1/B120: E0 10 00     CPX #$0010
C1/B123: D0 F4        BNE $B119
C1/B125: 60           RTS 
C1/B126: 00 20        BRK $20
C1/B128: 40           RTI 
C1/B129: 60           RTS 
C1/B12A: 7B           TDC 
C1/B12B: AA           TAX 
C1/B12C: DA           PHX 
C1/B12D: BF 26 B1 C1  LDA $C1B126,X
C1/B131: A8           TAY 
C1/B132: 84 8C        STY $8C
C1/B134: B9 43 CF     LDA $CF43,Y
C1/B137: D0 07        BNE $B140
C1/B139: 8A           TXA 
C1/B13A: 0A           ASL 
C1/B13B: 0A           ASL 
C1/B13C: AA           TAX 
C1/B13D: 20 AC B1     JSR $B1AC
C1/B140: FA           PLX 
C1/B141: E8           INX 
C1/B142: E0 04 00     CPX #$0004
C1/B145: D0 E5        BNE $B12C
C1/B147: 20 81 B1     JSR $B181
C1/B14A: AD C3 F8     LDA $F8C3
C1/B14D: 29 01        AND #$01
C1/B14F: F0 18        BEQ $B169
C1/B151: C2 20        REP #$20
C1/B153: AD 37 7F     LDA $7F37
C1/B156: 38           SEC 
C1/B157: E9 21 04     SBC #$0421
C1/B15A: 8D 37 7F     STA $7F37
C1/B15D: C9 08 21     CMP #$2108
C1/B160: D0 03        BNE $B165
C1/B162: EE C3 F8     INC $F8C3
C1/B165: 7B           TDC 
C1/B166: E2 20        SEP #$20
C1/B168: 60           RTS 
C1/B169: C2 20        REP #$20
C1/B16B: AD 37 7F     LDA $7F37
C1/B16E: 18           CLC 
C1/B16F: 69 21 04     ADC #$0421
C1/B172: 8D 37 7F     STA $7F37
C1/B175: C9 FF 7F     CMP #$7FFF
C1/B178: D0 03        BNE $B17D
C1/B17A: EE C3 F8     INC $F8C3
C1/B17D: 7B           TDC 
C1/B17E: E2 20        SEP #$20
C1/B180: 60           RTS 
C1/B181: 7B           TDC 
C1/B182: AA           TAX 
C1/B183: BD 43 DB     LDA $DB43,X
C1/B186: F0 1D        BEQ $B1A5
C1/B188: BF 26 B1 C1  LDA $C1B126,X
C1/B18C: A8           TAY 
C1/B18D: DA           PHX 
C1/B18E: 7B           TDC 
C1/B18F: AA           TAX 
C1/B190: C2 20        REP #$20
C1/B192: BD 49 F8     LDA $F849,X
C1/B195: 99 89 7F     STA $7F89,Y
C1/B198: E8           INX 
C1/B199: E8           INX 
C1/B19A: C8           INY 
C1/B19B: C8           INY 
C1/B19C: E0 20 00     CPX #$0020
C1/B19F: D0 F1        BNE $B192
C1/B1A1: 7B           TDC 
C1/B1A2: E2 20        SEP #$20
C1/B1A4: FA           PLX 
C1/B1A5: E8           INX 
C1/B1A6: E0 04 00     CPX #$0004
C1/B1A9: D0 D8        BNE $B183
C1/B1AB: 60           RTS 
C1/B1AC: 5A           PHY 
C1/B1AD: A9 20        LDA #$20
C1/B1AF: 85 88        STA $88
C1/B1B1: BD 8E 7B     LDA $7B8E,X
C1/B1B4: 85 8A        STA $8A
C1/B1B6: BD 8F 7B     LDA $7B8F,X
C1/B1B9: 85 8B        STA $8B
C1/B1BB: BD 90 7B     LDA $7B90,X
C1/B1BE: 85 8C        STA $8C
C1/B1C0: A5 8A        LDA $8A
C1/B1C2: 10 0D        BPL $B1D1
C1/B1C4: B9 F6 EC     LDA $ECF6,Y
C1/B1C7: 99 89 7F     STA $7F89,Y
C1/B1CA: C8           INY 
C1/B1CB: C6 88        DEC $88
C1/B1CD: D0 F5        BNE $B1C4
C1/B1CF: 80 0B        BRA $B1DC
C1/B1D1: B9 76 ED     LDA $ED76,Y
C1/B1D4: 99 89 7F     STA $7F89,Y
C1/B1D7: C8           INY 
C1/B1D8: C6 88        DEC $88
C1/B1DA: D0 F5        BNE $B1D1
C1/B1DC: 7A           PLY 
C1/B1DD: A5 8A        LDA $8A
C1/B1DF: F0 14        BEQ $B1F5
C1/B1E1: 29 40        AND #$40
C1/B1E3: F0 05        BEQ $B1EA
C1/B1E5: 20 66 B2     JSR $B266
C1/B1E8: 80 2C        BRA $B216
C1/B1EA: A5 8A        LDA $8A
C1/B1EC: 29 02        AND #$02
C1/B1EE: F0 05        BEQ $B1F5
C1/B1F0: 20 C1 B2     JSR $B2C1
C1/B1F3: 80 21        BRA $B216
C1/B1F5: A5 8A        LDA $8A
C1/B1F7: 29 04        AND #$04
C1/B1F9: F0 05        BEQ $B200
C1/B1FB: 20 82 B2     JSR $B282
C1/B1FE: 80 16        BRA $B216
C1/B200: A5 8B        LDA $8B
C1/B202: F0 12        BEQ $B216
C1/B204: 29 80        AND #$80
C1/B206: F0 05        BEQ $B20D
C1/B208: 20 94 B2     JSR $B294
C1/B20B: 80 09        BRA $B216
C1/B20D: A5 8B        LDA $8B
C1/B20F: 29 08        AND #$08
C1/B211: F0 03        BEQ $B216
C1/B213: 20 AF B2     JSR $B2AF
C1/B216: A5 8C        LDA $8C
C1/B218: F0 4B        BEQ $B265
C1/B21A: 29 80        AND #$80
C1/B21C: F0 06        BEQ $B224
C1/B21E: 7B           TDC 
C1/B21F: 20 D9 B2     JSR $B2D9
C1/B222: 80 41        BRA $B265
C1/B224: A5 8C        LDA $8C
C1/B226: 29 40        AND #$40
C1/B228: F0 07        BEQ $B231
C1/B22A: A9 01        LDA #$01
C1/B22C: 20 D9 B2     JSR $B2D9
C1/B22F: 80 34        BRA $B265
C1/B231: A5 8C        LDA $8C
C1/B233: 29 20        AND #$20
C1/B235: F0 07        BEQ $B23E
C1/B237: A9 02        LDA #$02
C1/B239: 20 D9 B2     JSR $B2D9
C1/B23C: 80 27        BRA $B265
C1/B23E: A5 8C        LDA $8C
C1/B240: 29 10        AND #$10
C1/B242: F0 07        BEQ $B24B
C1/B244: A9 03        LDA #$03
C1/B246: 20 D9 B2     JSR $B2D9
C1/B249: 80 1A        BRA $B265
C1/B24B: A5 8C        LDA $8C
C1/B24D: 29 08        AND #$08
C1/B24F: F0 07        BEQ $B258
C1/B251: A9 04        LDA #$04
C1/B253: 20 D9 B2     JSR $B2D9
C1/B256: 80 0D        BRA $B265
C1/B258: A5 8C        LDA $8C
C1/B25A: 29 04        AND #$04
C1/B25C: F0 07        BEQ $B265
C1/B25E: A9 05        LDA #$05
C1/B260: 20 D9 B2     JSR $B2D9
C1/B263: 80 00        BRA $B265
C1/B265: 60           RTS 

; [  ]

C1/B266: 5A           PHY 
C1/B267: DA           PHX 
C1/B268: C2 20        REP #$20
C1/B26A: 7B           TDC 
C1/B26B: AA           TAX 
C1/B26C: BF 35 98 D9  LDA $D99835,X
C1/B270: 99 89 7F     STA $7F89,Y
C1/B273: C8           INY 
C1/B274: C8           INY 
C1/B275: E8           INX 
C1/B276: E8           INX 
C1/B277: E0 20 00     CPX #$0020
C1/B27A: D0 F0        BNE $B26C
C1/B27C: 7B           TDC 
C1/B27D: E2 20        SEP #$20
C1/B27F: FA           PLX 
C1/B280: 7A           PLY 
C1/B281: 60           RTS 

C1/B282: C2 20        REP #$20
C1/B284: A9 DB 7E     LDA #$7EDB
C1/B287: 99 91 7F     STA $7F91,Y
C1/B28A: A9 D3 4D     LDA #$4DD3
C1/B28D: 99 99 7F     STA $7F99,Y
C1/B290: 7B           TDC 
C1/B291: E2 20        SEP #$20
C1/B293: 60           RTS 
C1/B294: C2 20        REP #$20
C1/B296: A9 FF 00     LDA #$00FF
C1/B299: A9 94 52     LDA #$5294
C1/B29C: 99 93 7F     STA $7F93,Y
C1/B29F: A9 10 42     LDA #$4210
C1/B2A2: 99 9B 7F     STA $7F9B,Y
C1/B2A5: A9 FF 7F     LDA #$7FFF
C1/B2A8: 99 9D 7F     STA $7F9D,Y
C1/B2AB: 7B           TDC 
C1/B2AC: E2 20        SEP #$20
C1/B2AE: 60           RTS 
C1/B2AF: C2 20        REP #$20
C1/B2B1: A9 3F 01     LDA #$013F
C1/B2B4: 99 91 7F     STA $7F91,Y
C1/B2B7: A9 1F 00     LDA #$001F
C1/B2BA: 99 99 7F     STA $7F99,Y
C1/B2BD: 7B           TDC 
C1/B2BE: E2 20        SEP #$20
C1/B2C0: 60           RTS 
C1/B2C1: C2 20        REP #$20
C1/B2C3: A9 F5 3A     LDA #$3AF5
C1/B2C6: 99 91 7F     STA $7F91,Y
C1/B2C9: A9 10 32     LDA #$3210
C1/B2CC: 99 99 7F     STA $7F99,Y
C1/B2CF: A9 FF 7F     LDA #$7FFF
C1/B2D2: 99 8F 7F     STA $7F8F,Y
C1/B2D5: 7B           TDC 
C1/B2D6: E2 20        SEP #$20
C1/B2D8: 60           RTS 
C1/B2D9: DA           PHX 
C1/B2DA: 85 88        STA $88
C1/B2DC: A5 A2        LDA $A2
C1/B2DE: 29 02        AND #$02
C1/B2E0: D0 10        BNE $B2F2
C1/B2E2: A5 88        LDA $88
C1/B2E4: C2 20        REP #$20
C1/B2E6: 0A           ASL 
C1/B2E7: AA           TAX 
C1/B2E8: BF F4 B2 C1  LDA $C1B2F4,X
C1/B2EC: 99 8B 7F     STA $7F8B,Y
C1/B2EF: 7B           TDC 
C1/B2F0: E2 20        SEP #$20
C1/B2F2: FA           PLX 
C1/B2F3: 60           RTS 
C1/B2F4: 60           RTS 
C1/B2F5: 6A           ROR 
C1/B2F6: 1F 03 64 0B  ORA $0B6403,X
C1/B2FA: 1A           INC 
C1/B2FB: 00 7F        BRK $7F
C1/B2FD: 01 FF        ORA ($FF,X)
C1/B2FF: 7F

; [  ]

C1/B300: 20 B8 1C     JSR $1CB8
C1/B303: 9C 55 DB     STZ $DB55
C1/B306: 9C 56 DB     STZ $DB56
C1/B309: 9C 57 DB     STZ $DB57
C1/B30C: 9C 43 DB     STZ $DB43
C1/B30F: 9C 44 DB     STZ $DB44
C1/B312: 9C 45 DB     STZ $DB45
C1/B315: 9C 46 DB     STZ $DB46
C1/B318: 9C 5D DB     STZ $DB5D
C1/B31B: 60           RTS 

; animation frame sizes (width then height)
C1/B31C: 03 03 ; $00
C1/B31E: 02 04
C1/B320: 07 03
C1/B322: 02 02
C1/B324: 01 01
C1/B326: 06 06
C1/B328: 10 0A
C1/B32A: 05 05
C1/B32C: 05 06
C1/B32E: 01 02
C1/B330: 05 03
C1/B332: 01 0A
C1/B334: 0A 0A
C1/B336: 04 0A
C1/B338: 02 0B
C1/B33A: 04 04
C1/B33C: 03 04 ; $10
C1/B33E: 03 05
C1/B340: 01 0B
C1/B342: 06 03
C1/B344: 06 05
C1/B346: 04 07
C1/B348: 04 02
C1/B34A: 01 03
C1/B34C: 06 0A
C1/B34E: 02 03
C1/B350: 04 08
C1/B352: 04 03
C1/B354: 02 01
C1/B356: 05 02
C1/B358: 04 05
C1/B35A: 09 01
C1/B35C: 03 09 ; $20
C1/B35E: 02 02
C1/B360: 05 04
C1/B362: 0B 07
C1/B364: 03 01
C1/B366: 03 08
C1/B368: 0C 07
C1/B36A: 06 02
C1/B36C: 08 02
C1/B36E: 0A 03
C1/B370: 0C 05
C1/B372: 0E 05
C1/B374: 10 05
C1/B376: 08 05
C1/B378: 08 03
C1/B37A: 0A 05
C1/B37C: 09 01 ; $30
C1/B37E: 04 08
C1/B380: 0C 01
C1/B382: 02 0A
C1/B384: 0B 0A
C1/B386: 02 09

; [  ]

C1/B388: 8D 61 CF     STA $CF61
C1/B38B: 8D 81 CF     STA $CF81
C1/B38E: 8D A1 CF     STA $CFA1
C1/B391: 8D C1 CF     STA $CFC1
C1/B394: 60           RTS 

C1/B395: 60           RTS 
C1/B396: 00 50        BRK $50
C1/B398: 00 60        BRK $60
C1/B39A: 00 50        BRK $50
C1/B39C: 00 60        BRK $60
C1/B39E: 00 50        BRK $50
C1/B3A0: 00 68        BRK $68
C1/B3A2: 00 B0        BRK $B0
C1/B3A4: FF 70 00 C0  SBC $C00070,X
C1/B3A8: FF 00 00 A0  SBC $A00000,X
C1/B3AC: 00 70        BRK $70
C1/B3AE: 00 B8        BRK $B8
C1/B3B0: FF 70 00 B0  SBC $B00070,X
C1/B3B4: FF 70 00 50  SBC $500070,X
C1/B3B8: 00 60        BRK $60
C1/B3BA: 00 40        BRK $40
C1/B3BC: 00 78        BRK $78
C1/B3BE: 00 50        BRK $50
C1/B3C0: 00 78        BRK $78
C1/B3C2: 00 40        BRK $40
C1/B3C4: 00 F8        BRK $F8
C1/B3C6: 00 20        BRK $20
C1/B3C8: 00 78        BRK $78
C1/B3CA: 00 38        BRK $38
C1/B3CC: 00 78        BRK $78
C1/B3CE: 00 18        BRK $18
C1/B3D0: 00 70        BRK $70
C1/B3D2: 00 B8        BRK $B8
C1/B3D4: FF 78 00 40  SBC $400078,X
C1/B3D8: 00 F8        BRK $F8
C1/B3DA: 00 20        BRK $20
C1/B3DC: 00 00        BRK $00
C1/B3DE: 00 00        BRK $00
C1/B3E0: 00 00        BRK $00
C1/B3E2: 00 00        BRK $00
C1/B3E4: 00 60        BRK $60
C1/B3E6: 00 50        BRK $50
C1/B3E8: 00 00        BRK $00
C1/B3EA: 00 00        BRK $00
C1/B3EC: 01 01        ORA ($01,X)
C1/B3EE: 01 01        ORA ($01,X)
C1/B3F0: 01 00        ORA ($00,X)
C1/B3F2: 00 00        BRK $00
C1/B3F4: 00 01        BRK $01
C1/B3F6: 00 00        BRK $00
C1/B3F8: 01 00        ORA ($00,X)
C1/B3FA: 00 00        BRK $00
C1/B3FC: 00 00        BRK $00

; [  ]

C1/B3FE: 09 E0        ORA #$E0
C1/B400: 8D 88 BC     STA $BC88
C1/B403: 8D 89 BC     STA $BC89
C1/B406: 8D 8A BC     STA $BC8A
C1/B409: 60           RTS 

; [  ]

C1/B40A: A9 10        LDA #$10
C1/B40C: 8D 85 BC     STA $BC85
C1/B40F: A9 1F        LDA #$1F
C1/B411: 8D 6C F8     STA $F86C
C1/B414: 20 FE B3     JSR $B3FE
C1/B417: 20 F2 02     JSR $02F2       ; wait one frame
C1/B41A: AD 6C F8     LDA $F86C
C1/B41D: 20 FE B3     JSR $B3FE
C1/B420: CE 6C F8     DEC $F86C
C1/B423: 10 F2        BPL $B417
C1/B425: 60           RTS 
C1/B426: A9 10        LDA #$10
C1/B428: 8D 85 BC     STA $BC85
C1/B42B: 9C 6C F8     STZ $F86C
C1/B42E: 20 F2 02     JSR $02F2       ; wait one frame
C1/B431: AD 6C F8     LDA $F86C
C1/B434: 20 FE B3     JSR $B3FE
C1/B437: EE 6C F8     INC $F86C
C1/B43A: AD 6C F8     LDA $F86C
C1/B43D: C9 20        CMP #$20
C1/B43F: D0 ED        BNE $B42E
C1/B441: 60           RTS 
C1/B442: DA           PHX 
C1/B443: A9 DD        LDA #$DD
C1/B445: 8D B6 DB     STA $DBB6
C1/B448: A9 93        LDA #$93
C1/B44A: 20 D9 FB     JSR $FBD9       ; play sound effect
C1/B44D: 20 26 B4     JSR $B426
C1/B450: A9 80        LDA #$80
C1/B452: 8D 60 DB     STA $DB60
C1/B455: 20 F2 02     JSR $02F2       ; wait one frame
C1/B458: AD 4B 7C     LDA $7C4B
C1/B45B: AA           TAX 
C1/B45C: 20 36 27     JSR $2736
C1/B45F: 20 FB 26     JSR $26FB
C1/B462: 7B           TDC 
C1/B463: AA           TAX 
C1/B464: 86 78        STX $78
C1/B466: AD D3 DB     LDA $DBD3
C1/B469: F0 04        BEQ $B46F
C1/B46B: A9 20        LDA #$20
C1/B46D: 85 78        STA $78
C1/B46F: C2 20        REP #$20
C1/B471: A5 74        LDA $74
C1/B473: 0A           ASL 
C1/B474: 0A           ASL 
C1/B475: 18           CLC 
C1/B476: 69 48 00     ADC #$0048
C1/B479: 8D 62 DB     STA $DB62
C1/B47C: A5 76        LDA $76
C1/B47E: 0A           ASL 
C1/B47F: 0A           ASL 
C1/B480: 85 76        STA $76
C1/B482: A9 60 00     LDA #$0060
C1/B485: 38           SEC 
C1/B486: E5 76        SBC $76
C1/B488: 65 78        ADC $78
C1/B48A: 8D 64 DB     STA $DB64
C1/B48D: 7B           TDC 
C1/B48E: E2 20        SEP #$20
C1/B490: A9 38        LDA #$38
C1/B492: 8D 66 DB     STA $DB66
C1/B495: A9 01        LDA #$01
C1/B497: 8D 60 DB     STA $DB60
C1/B49A: 8D 61 DB     STA $DB61
C1/B49D: 20 0A B4     JSR $B40A
C1/B4A0: FA           PLX 
C1/B4A1: 60           RTS 

; [  ]

C1/B4A2: DA           PHX 
C1/B4A3: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/B4A6: C9 60        CMP #$60
C1/B4A8: F0 07        BEQ $B4B1
C1/B4AA: C9 61        CMP #$61
C1/B4AC: F0 03        BEQ $B4B1
C1/B4AE: 4C B4 B4     JMP $B4B4
C1/B4B1: 4C 34 B5     JMP $B534
C1/B4B4: 20 3B 8D     JSR $8D3B
C1/B4B7: F0 F8        BEQ $B4B1
C1/B4B9: 20 26 B4     JSR $B426
C1/B4BC: A9 05        LDA #$05
C1/B4BE: 85 7E        STA $7E
C1/B4C0: 7B           TDC 
C1/B4C1: 20 43 7B     JSR $7B43
C1/B4C4: A9 80        LDA #$80
C1/B4C6: 8D 60 DB     STA $DB60
C1/B4C9: 20 F2 02     JSR $02F2       ; wait one frame
C1/B4CC: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/B4CF: C2 20        REP #$20
C1/B4D1: 38           SEC 
C1/B4D2: E9 5F 00     SBC #$005F
C1/B4D5: 85 70        STA $70
C1/B4D7: 0A           ASL 
C1/B4D8: AA           TAX 
C1/B4D9: BF 50 7C D9  LDA $D97C50,X
C1/B4DD: AA           TAX 
C1/B4DE: 7B           TDC 
C1/B4DF: E2 20        SEP #$20
C1/B4E1: A5 70        LDA $70
C1/B4E3: 48           PHA 
C1/B4E4: 20 36 27     JSR $2736
C1/B4E7: 20 FB 26     JSR $26FB
C1/B4EA: 68           PLA 
C1/B4EB: 48           PHA 
C1/B4EC: 0A           ASL 
C1/B4ED: 0A           ASL 
C1/B4EE: AA           TAX 
C1/B4EF: C2 20        REP #$20
C1/B4F1: BF 95 B3 C1  LDA $C1B395,X
C1/B4F5: 8D 62 DB     STA $DB62
C1/B4F8: BF 97 B3 C1  LDA $C1B397,X
C1/B4FC: 8D 64 DB     STA $DB64
C1/B4FF: 7B           TDC 
C1/B500: E2 20        SEP #$20
C1/B502: AD D3 DB     LDA $DBD3
C1/B505: F0 0F        BEQ $B516
C1/B507: C2 20        REP #$20
C1/B509: AD 64 DB     LDA $DB64
C1/B50C: 18           CLC 
C1/B50D: 69 20 00     ADC #$0020
C1/B510: 8D 64 DB     STA $DB64
C1/B513: 7B           TDC 
C1/B514: E2 20        SEP #$20
C1/B516: A9 38        LDA #$38
C1/B518: 8D 66 DB     STA $DB66
C1/B51B: A9 01        LDA #$01
C1/B51D: 8D 60 DB     STA $DB60
C1/B520: 8D 61 DB     STA $DB61
C1/B523: 68           PLA 
C1/B524: AA           TAX 
C1/B525: BF E9 B3 C1  LDA $C1B3E9,X
C1/B529: D0 05        BNE $B530
C1/B52B: 20 0A B4     JSR $B40A
C1/B52E: 80 04        BRA $B534
C1/B530: 7B           TDC 
C1/B531: 20 FE B3     JSR $B3FE
C1/B534: FA           PLX 
C1/B535: 60           RTS 

; [  ]

C1/B536: AD 4B 7C     LDA $7C4B
C1/B539: C9 FF        CMP #$FF
C1/B53B: F0 03        BEQ $B540
C1/B53D: 4C 42 B4     JMP $B442
C1/B540: B2 EB        LDA ($EB)
C1/B542: 10 03        BPL $B547
C1/B544: 4C 73 B5     JMP $B573
C1/B547: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/B54A: A2 00 01     LDX #$0100
C1/B54D: C9 12        CMP #$12
C1/B54F: 90 23        BCC $B574
C1/B551: E8           INX 
C1/B552: C9 24        CMP #$24
C1/B554: 90 1E        BCC $B574
C1/B556: E8           INX 
C1/B557: C9 36        CMP #$36
C1/B559: 90 19        BCC $B574
C1/B55B: E8           INX 
C1/B55C: C9 57        CMP #$57
C1/B55E: 90 14        BCC $B574
C1/B560: E8           INX 
C1/B561: C9 5F        CMP #$5F
C1/B563: 90 0F        BCC $B574
C1/B565: E8           INX 
C1/B566: C9 71        CMP #$71
C1/B568: 90 0A        BCC $B574
C1/B56A: E8           INX 
C1/B56B: C9 82        CMP #$82
C1/B56D: 90 04        BCC $B573
C1/B56F: C9 A2        CMP #$A2
C1/B571: 90 01        BCC $B574
C1/B573: 60           RTS 
C1/B574: C9 73        CMP #$73
C1/B576: F0 05        BEQ $B57D
C1/B578: E0 05 01     CPX #$0105
C1/B57B: D0 0E        BNE $B58B
C1/B57D: A2 05 01     LDX #$0105
C1/B580: 20 8B B5     JSR $B58B
C1/B583: A9 01        LDA #$01
C1/B585: 8D DF DB     STA $DBDF
C1/B588: 4C A2 B4     JMP $B4A2

; [  ]

C1/B58B: 9C 6D F8     STZ $F86D
C1/B58E: 20 47 A8     JSR $A847       ; load attack animation properties
C1/B591: AD 82 F5     LDA $F582
C1/B594: 8D BC D1     STA $D1BC
C1/B597: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/B59A: 0A           ASL 
C1/B59B: 0A           ASL 
C1/B59C: 0A           ASL 
C1/B59D: 0A           ASL 
C1/B59E: 0A           ASL 
C1/B59F: AA           TAX 
C1/B5A0: DA           PHX 
C1/B5A1: A9 0B        LDA #$0B
C1/B5A3: 9D 58 CF     STA $CF58,X
C1/B5A6: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/B5A9: 20 74 FC     JSR $FC74
C1/B5AC: 8D 53 DB     STA $DB53
C1/B5AF: 8D 52 DB     STA $DB52
C1/B5B2: 9C 50 DB     STZ $DB50
C1/B5B5: 9C 51 DB     STZ $DB51
C1/B5B8: 9C 54 DB     STZ $DB54
C1/B5BB: 20 D5 C0     JSR $C0D5
C1/B5BE: AD BC D1     LDA $D1BC
C1/B5C1: 29 3F        AND #$3F
C1/B5C3: F0 03        BEQ $B5C8
C1/B5C5: 20 33 B6     JSR $B633
C1/B5C8: AD BC D1     LDA $D1BC
C1/B5CB: 29 3F        AND #$3F
C1/B5CD: C9 02        CMP #$02
C1/B5CF: D0 19        BNE $B5EA
C1/B5D1: A9 02        LDA #$02
C1/B5D3: 85 70        STA $70
C1/B5D5: 7B           TDC 
C1/B5D6: AA           TAX 
C1/B5D7: A5 70        LDA $70
C1/B5D9: 9D DE D3     STA $D3DE,X
C1/B5DC: 18           CLC 
C1/B5DD: 69 02        ADC #$02
C1/B5DF: 85 70        STA $70
C1/B5E1: 8A           TXA 
C1/B5E2: 18           CLC 
C1/B5E3: 69 10        ADC #$10
C1/B5E5: AA           TAX 
C1/B5E6: C9 80        CMP #$80
C1/B5E8: D0 ED        BNE $B5D7
C1/B5EA: C9 08        CMP #$08
C1/B5EC: D0 14        BNE $B602
C1/B5EE: 7B           TDC 
C1/B5EF: AA           TAX 
C1/B5F0: A8           TAY 
C1/B5F1: BF E4 E3 C1  LDA $C1E3E4,X
C1/B5F5: 99 DE D3     STA $D3DE,Y
C1/B5F8: E8           INX 
C1/B5F9: 98           TYA 
C1/B5FA: 18           CLC 
C1/B5FB: 69 10        ADC #$10
C1/B5FD: A8           TAY 
C1/B5FE: C9 80        CMP #$80
C1/B600: D0 EF        BNE $B5F1
C1/B602: 20 10 E8     JSR $E810
C1/B605: 20 1E E8     JSR $E81E
C1/B608: EE 10 D1     INC $D110
C1/B60B: A9 01        LDA #$01
C1/B60D: 8D 38 DB     STA $DB38
C1/B610: 20 F2 02     JSR $02F2       ; wait one frame
C1/B613: 7B           TDC 
C1/B614: AA           TAX 
C1/B615: A9 08        LDA #$08
C1/B617: 20 09 C4     JSR $C409
C1/B61A: A5 74        LDA $74
C1/B61C: C9 08        CMP #$08
C1/B61E: D0 EB        BNE $B60B
C1/B620: 9C 10 D1     STZ $D110
C1/B623: 9C 38 DB     STZ $DB38
C1/B626: 20 D3 67     JSR $67D3
C1/B629: 20 F2 02     JSR $02F2       ; wait one frame
C1/B62C: FA           PLX 
C1/B62D: 9E 58 CF     STZ $CF58,X
C1/B630: 4C 6D FC     JMP $FC6D
C1/B633: 20 2F 8D     JSR $8D2F       ; get attacker id
C1/B636: 0A           ASL 
C1/B637: 0A           ASL 
C1/B638: 0A           ASL 
C1/B639: 0A           ASL 
C1/B63A: AA           TAX 
C1/B63B: 86 70        STX $70
C1/B63D: A9 08        LDA #$08
C1/B63F: 85 74        STA $74
C1/B641: 7B           TDC 
C1/B642: A8           TAY 
C1/B643: A9 10        LDA #$10
C1/B645: 85 72        STA $72
C1/B647: A6 70        LDX $70
C1/B649: BD D8 D1     LDA $D1D8,X
C1/B64C: 99 D8 D1     STA $D1D8,Y
C1/B64F: BD D8 D3     LDA $D3D8,X
C1/B652: 99 D8 D3     STA $D3D8,Y
C1/B655: C8           INY 
C1/B656: E8           INX 
C1/B657: C6 72        DEC $72
C1/B659: D0 EE        BNE $B649
C1/B65B: C6 74        DEC $74
C1/B65D: D0 E4        BNE $B643
C1/B65F: 60           RTS 
C1/B660: 7B           TDC 
C1/B661: AA           TAX 
C1/B662: 9D D8 D1     STA $D1D8,X
C1/B665: E8           INX 
C1/B666: E0 00 08     CPX #$0800
C1/B669: D0 F7        BNE $B662
C1/B66B: 7B           TDC 
C1/B66C: AA           TAX 
C1/B66D: 9D D8 D9     STA $D9D8,X
C1/B670: E8           INX 
C1/B671: E0 60 01     CPX #$0160
C1/B674: D0 F7        BNE $B66D
C1/B676: 60           RTS 

; [  ]

C1/B677: 20 60 B6     JSR $B660
C1/B67A: 9C 6B DB     STZ $DB6B
C1/B67D: 9C 77 DB     STZ $DB77
C1/B680: 9C DF DB     STZ $DBDF
C1/B683: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/B686: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/B689: 20 36 B5     JSR $B536
C1/B68C: 9C 6B DB     STZ $DB6B
C1/B68F: 9C 77 DB     STZ $DB77
C1/B692: 20 93 9D     JSR $9D93       ; wait for damage numerals
C1/B695: 20 47 8D     JSR $8D47       ; get graphics script parameter 3
C1/B698: AA           TAX 
C1/B699: 9C 6A DB     STZ $DB6A
C1/B69C: 8E 6E F8     STX $F86E
C1/B69F: 9C 6D F8     STZ $F86D
C1/B6A2: 9C 6B DB     STZ $DB6B
C1/B6A5: 9C 77 DB     STZ $DB77
C1/B6A8: EE 77 DB     INC $DB77
C1/B6AB: 9C 6A F8     STZ $F86A
C1/B6AE: 9C 6B F8     STZ $F86B
C1/B6B1: 20 47 A8     JSR $A847       ; load attack animation properties
C1/B6B4: 20 00 B3     JSR $B300
C1/B6B7: AD 82 F5     LDA $F582
C1/B6BA: 8D BC D1     STA $D1BC
C1/B6BD: 29 3F        AND #$3F
C1/B6BF: 0A           ASL 
C1/B6C0: AA           TAX 
C1/B6C1: BF 46 B7 C1  LDA $C1B746,X
C1/B6C5: 85 70        STA $70
C1/B6C7: BF 47 B7 C1  LDA $C1B747,X
C1/B6CB: 85 71        STA $71
C1/B6CD: 20 42 B7     JSR $B742
C1/B6D0: AE 6A F8     LDX $F86A
C1/B6D3: D0 C7        BNE $B69C
C1/B6D5: AD 61 DB     LDA $DB61
C1/B6D8: F0 43        BEQ $B71D
C1/B6DA: 9C B4 F8     STZ $F8B4
C1/B6DD: A9 80        LDA #$80
C1/B6DF: 8D 60 DB     STA $DB60
C1/B6E2: 20 F2 02     JSR $02F2       ; wait one frame
C1/B6E5: A9 10        LDA #$10
C1/B6E7: 8D 85 BC     STA $BC85
C1/B6EA: A9 1F        LDA #$1F
C1/B6EC: 8D 6C F8     STA $F86C
C1/B6EF: 20 FE B3     JSR $B3FE
C1/B6F2: 20 D5 24     JSR $24D5
C1/B6F5: 20 0A B4     JSR $B40A
C1/B6F8: 7B           TDC 
C1/B6F9: 64 7E        STZ $7E
C1/B6FB: 20 43 7B     JSR $7B43
C1/B6FE: 20 F2 02     JSR $02F2       ; wait one frame
C1/B701: AD EE D0     LDA $D0EE
C1/B704: D0 F8        BNE $B6FE
C1/B706: 9C 60 DB     STZ $DB60
C1/B709: AE 6E F8     LDX $F86E
C1/B70C: E0 68 00     CPX #$0068
C1/B70F: D0 0C        BNE $B71D
C1/B711: A2 00 00     LDX #$0000
C1/B714: 8E 6E F8     STX $F86E
C1/B717: A2 1F 00     LDX #$001F
C1/B71A: 4C A8 B6     JMP $B6A8
C1/B71D: 9C 56 DB     STZ $DB56
C1/B720: AD 6D F8     LDA $F86D
C1/B723: D0 0E        BNE $B733
C1/B725: EE 6D F8     INC $F86D
C1/B728: AE 6E F8     LDX $F86E
C1/B72B: 20 41 8D     JSR $8D41
C1/B72E: F0 03        BEQ $B733
C1/B730: 4C A8 B6     JMP $B6A8
C1/B733: 9C DF DB     STZ $DBDF
C1/B736: 9C 85 BC     STZ $BC85
C1/B739: 20 2D AD     JSR $AD2D
C1/B73C: 20 B8 1C     JSR $1CB8
C1/B73F: 4C BB 3C     JMP $3CBB
C1/B742: 6C 70 00     JMP ($0070)
C1/B745: 60           RTS 

C1/B746:              .DW $E82F, $E82F, $E82F, $E82F, $E82F, $E82F, $E82F, $E82F ; $00
C1/B756:              .DW $E82F, $E82F, $E82F, $E82F, $E82F, $E92C, $E82F, $E92C
C1/B766:              .DW $E82F, $E82F, $E82F, $E82F, $E82F, $E82F, $E82F, $E82F ; $10
C1/B776:              .DW $E962, $E82F, $E82F, $E92C, $E82F, $E82F, $E82F, $E92C
C1/B786:              .DW $E92C, $E92C, $E92C, $D2D0, $E82F, $E92C, $E92C, $E82F ; $20
C1/B796:              .DW $E82F, $E82F, $E82F, $E82F, $E92C, $E92C, $E82F, $E82F 
C1/B7A6:              .DW $E92C, $E82F, $E82F, $E82F, $E82F, $E82F, $E82F, $E92C ; $30
C1/B7B6:              .DW $E82F, $B745, $B745

; [  ]

C1/B7BC: 9C 6B DB     STZ $DB6B
C1/B7BF: 9C 11 D1     STZ $D111
C1/B7C2: 9C 12 D1     STZ $D112
C1/B7C5: 9C 13 D1     STZ $D113
C1/B7C8: 7B           TDC 
C1/B7C9: AA           TAX 
C1/B7CA: 9E D8 D7     STZ $D7D8,X
C1/B7CD: E8           INX 
C1/B7CE: E0 00 02     CPX #$0200
C1/B7D1: D0 F7        BNE $B7CA
C1/B7D3: A8           TAY 
C1/B7D4: B1 EB        LDA ($EB),Y
C1/B7D6: 99 50 DB     STA $DB50,Y
C1/B7D9: C8           INY 
C1/B7DA: C0 05 00     CPY #$0005
C1/B7DD: D0 F5        BNE $B7D4
C1/B7DF: AD 6D F8     LDA $F86D
C1/B7E2: F0 1D        BEQ $B801
C1/B7E4: AD 50 DB     LDA $DB50
C1/B7E7: 0A           ASL 
C1/B7E8: 29 80        AND #$80
C1/B7EA: 85 70        STA $70
C1/B7EC: AD 50 DB     LDA $DB50
C1/B7EF: 49 40        EOR #$40
C1/B7F1: 29 7F        AND #$7F
C1/B7F3: 05 70        ORA $70
C1/B7F5: 8D 50 DB     STA $DB50
C1/B7F8: 20 41 8D     JSR $8D41
C1/B7FB: 8D 53 DB     STA $DB53
C1/B7FE: 9C 54 DB     STZ $DB54
C1/B801: AD BC D1     LDA $D1BC
C1/B804: 29 3F        AND #$3F
C1/B806: C9 0C        CMP #$0C
C1/B808: D0 0F        BNE $B819
C1/B80A: A5 DF        LDA $DF
C1/B80C: 8D 53 DB     STA $DB53
C1/B80F: AD 50 DB     LDA $DB50
C1/B812: 29 3F        AND #$3F
C1/B814: 8D 50 DB     STA $DB50
C1/B817: 80 11        BRA $B82A
C1/B819: AD BC D1     LDA $D1BC
C1/B81C: 29 40        AND #$40
C1/B81E: F0 0A        BEQ $B82A
C1/B820: AD 53 DB     LDA $DB53
C1/B823: F0 02        BEQ $B827
C1/B825: A9 80        LDA #$80
C1/B827: 8D 53 DB     STA $DB53
C1/B82A: 20 D5 C0     JSR $C0D5
C1/B82D: 4C 30 B8     JMP $B830

; [  ]

C1/B830: AD BC D1     LDA $D1BC
C1/B833: 29 3F        AND #$3F
C1/B835: 0A           ASL 
C1/B836: AA           TAX 
C1/B837: BF 47 B8 C1  LDA $C1B847,X
C1/B83B: 85 70        STA $70
C1/B83D: BF 48 B8 C1  LDA $C1B848,X
C1/B841: 85 71        STA $71
C1/B843: 6C 70 00     JMP ($0070)

C1/B846: 60           RTS 

C1/B847:              .DW $B846, $BF29, $BF3F, $BF5B, $BF85, $C035, $C050, $C031 ; $00
C1/B857:              .DW $BF3F, $BEE8, $BEBD, $BEA7, $BE5A, $BDEC, $C02C, $BDBC
C1/B867:              .DW $BE42, $BCDE, $BCDB, $BF39, $BFA2, $BEC9, $BF1D, $BCBD ; $10
C1/B877:              .DW $BD23, $BC97, $BC75, $BC2D, $BCBD, $BBEF, $BC0F, $BBDA
C1/B887:              .DW $BBB8, $BB8E, $BB59, $D2D0, $BB2B, $BAF6, $BA65, $BA3D ; $20
C1/B897:              .DW $BA22, $BA12, $B846, $B846, $B9F6, $B9CB, $B9AF, $B961
C1/B8A7:              .DW $B9F0, $B989, $BFCB, $BFE1, $C019, $BFF7, $C008, $B8BC ; $30
C1/B8B7:              .DW $B8B9

C1/B8B9: 4C E6 BB     JMP $BBE6

C1/B8BC: 20 99 C0     JSR $C099
C1/B8BF: 20 0D BF     JSR $BF0D
C1/B8C2: 20 BF BD     JSR $BDBF
C1/B8C5: 7B           TDC 
C1/B8C6: AA           TAX 
C1/B8C7: 20 96 FC     JSR $FC96       ; generate random number
C1/B8CA: 9D 7B CE     STA $CE7B,X
C1/B8CD: E8           INX 
C1/B8CE: E0 40 00     CPX #$0040
C1/B8D1: D0 F4        BNE $B8C7
C1/B8D3: A2 30 00     LDX #$0030
C1/B8D6: 86 76        STX $76
C1/B8D8: 7B           TDC 
C1/B8D9: AA           TAX 
C1/B8DA: A8           TAY 
C1/B8DB: A9 10        LDA #$10
C1/B8DD: 9D DE D3     STA $D3DE,X
C1/B8E0: 9D 5E D4     STA $D45E,X
C1/B8E3: 9D DE D4     STA $D4DE,X
C1/B8E6: 9D 5E D5     STA $D55E,X
C1/B8E9: B9 7B CE     LDA $CE7B,Y
C1/B8EC: 18           CLC 
C1/B8ED: 69 40        ADC #$40
C1/B8EF: 99 BB CE     STA $CEBB,Y
C1/B8F2: B9 83 CE     LDA $CE83,Y
C1/B8F5: 18           CLC 
C1/B8F6: 69 40        ADC #$40
C1/B8F8: 99 C3 CE     STA $CEC3,Y
C1/B8FB: B9 8B CE     LDA $CE8B,Y
C1/B8FE: 18           CLC 
C1/B8FF: 69 40        ADC #$40
C1/B901: 99 CB CE     STA $CECB,Y
C1/B904: B9 93 CE     LDA $CE93,Y
C1/B907: 18           CLC 
C1/B908: 69 40        ADC #$40
C1/B90A: 99 D3 CE     STA $CED3,Y
C1/B90D: A9 38        LDA #$38
C1/B90F: 99 FB CD     STA $CDFB,Y
C1/B912: 99 03 CE     STA $CE03,Y
C1/B915: 99 0B CE     STA $CE0B,Y
C1/B918: 99 13 CE     STA $CE13,Y
C1/B91B: 99 3B CE     STA $CE3B,Y
C1/B91E: 99 43 CE     STA $CE43,Y
C1/B921: 99 4B CE     STA $CE4B,Y
C1/B924: 99 53 CE     STA $CE53,Y
C1/B927: C2 20        REP #$20
C1/B929: A9 50 00     LDA #$0050
C1/B92C: 9D E1 D1     STA $D1E1,X
C1/B92F: 9D 61 D2     STA $D261,X
C1/B932: 9D E1 D2     STA $D2E1,X
C1/B935: 9D 61 D3     STA $D361,X
C1/B938: A5 76        LDA $76
C1/B93A: 9D DF D1     STA $D1DF,X
C1/B93D: 69 38 00     ADC #$0038
C1/B940: 9D 5F D2     STA $D25F,X
C1/B943: 69 38 00     ADC #$0038
C1/B946: 9D DF D2     STA $D2DF,X
C1/B949: 69 38 00     ADC #$0038
C1/B94C: 9D 5F D3     STA $D35F,X
C1/B94F: 7B           TDC 
C1/B950: E2 20        SEP #$20
C1/B952: C8           INY 
C1/B953: 8A           TXA 
C1/B954: 18           CLC 
C1/B955: 69 10        ADC #$10
C1/B957: AA           TAX 
C1/B958: E0 30 00     CPX #$0030
C1/B95B: F0 03        BEQ $B960
C1/B95D: 4C DB B8     JMP $B8DB
C1/B960: 60           RTS 

; [ load spirit/paraclete animation ??? ]

C1/B961: B2 EB        LDA ($EB)
C1/B963: 29 02        AND #$02
C1/B965: F0 21        BEQ $B988       ; return if not spirit/paraclete
C1/B967: A9 EF        LDA #$EF        ; animation script $EF
C1/B969: C2 20        REP #$20
C1/B96B: 0A           ASL 
C1/B96C: AA           TAX 
C1/B96D: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/B971: 85 70        STA $70
C1/B973: 7B           TDC 
C1/B974: AA           TAX 
C1/B975: A5 70        LDA $70
C1/B977: 9D DA D3     STA $D3DA,X
C1/B97A: 8A           TXA 
C1/B97B: 18           CLC 
C1/B97C: 69 10 00     ADC #$0010
C1/B97F: AA           TAX 
C1/B980: E0 80 00     CPX #$0080      ; load 8 copies ???
C1/B983: D0 F0        BNE $B975
C1/B985: 7B           TDC 
C1/B986: E2 20        SEP #$20
C1/B988: 60           RTS 

; [  ]

C1/B989: A5 F6        LDA $F6
C1/B98B: F0 21        BEQ $B9AE
C1/B98D: A9 FD        LDA #$FD
C1/B98F: C2 20        REP #$20
C1/B991: 0A           ASL 
C1/B992: AA           TAX 
C1/B993: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/B997: 85 70        STA $70
C1/B999: 7B           TDC 
C1/B99A: AA           TAX 
C1/B99B: A5 70        LDA $70
C1/B99D: 9D DA D3     STA $D3DA,X
C1/B9A0: 8A           TXA 
C1/B9A1: 18           CLC 
C1/B9A2: 69 10 00     ADC #$0010
C1/B9A5: AA           TAX 
C1/B9A6: E0 80 00     CPX #$0080
C1/B9A9: D0 F0        BNE $B99B
C1/B9AB: 7B           TDC 
C1/B9AC: E2 20        SEP #$20
C1/B9AE: 60           RTS 

C1/B9AF: 20 99 C0     JSR $C099
C1/B9B2: A0 40 00     LDY #$0040
C1/B9B5: 20 77 C0     JSR $C077
C1/B9B8: A9 21        LDA #$21
C1/B9BA: 8D DE D3     STA $D3DE
C1/B9BD: A9 01        LDA #$01
C1/B9BF: 8D EE D3     STA $D3EE
C1/B9C2: 8D FE D3     STA $D3FE
C1/B9C5: 8D 0E D4     STA $D40E
C1/B9C8: 4C 10 BF     JMP $BF10

C1/B9CB: 20 99 C0     JSR $C099
C1/B9CE: 20 10 BF     JSR $BF10
C1/B9D1: 20 BF BD     JSR $BDBF
C1/B9D4: 7B           TDC 
C1/B9D5: AA           TAX 
C1/B9D6: 20 96 FC     JSR $FC96       ; generate random number
C1/B9D9: 29 07        AND #$07
C1/B9DB: 1A           INC 
C1/B9DC: 9D DE D3     STA $D3DE,X
C1/B9DF: C2 20        REP #$20
C1/B9E1: 8A           TXA 
C1/B9E2: 18           CLC 
C1/B9E3: 69 10 00     ADC #$0010
C1/B9E6: AA           TAX 
C1/B9E7: 7B           TDC 
C1/B9E8: E2 20        SEP #$20
C1/B9EA: E0 00 02     CPX #$0200
C1/B9ED: D0 E7        BNE $B9D6
C1/B9EF: 60           RTS 

C1/B9F0: 20 F6 B9     JSR $B9F6
C1/B9F3: 4C D4 B9     JMP $B9D4

C1/B9F6: 20 BF BD     JSR $BDBF
C1/B9F9: 7B           TDC 
C1/B9FA: AA           TAX 
C1/B9FB: 9E 67 D4     STZ $D467,X
C1/B9FE: 9E 67 D5     STZ $D567,X
C1/BA01: C2 20        REP #$20
C1/BA03: 8A           TXA 
C1/BA04: 18           CLC 
C1/BA05: 69 10 00     ADC #$0010
C1/BA08: AA           TAX 
C1/BA09: 7B           TDC 
C1/BA0A: E2 20        SEP #$20
C1/BA0C: E0 80 00     CPX #$0080
C1/BA0F: D0 EA        BNE $B9FB
C1/BA11: 60           RTS 

C1/BA12: 20 99 C0     JSR $C099
C1/BA15: 20 0A BF     JSR $BF0A
C1/BA18: AD DE D3     LDA $D3DE
C1/BA1B: 18           CLC 
C1/BA1C: 69 02        ADC #$02
C1/BA1E: 8D EE D3     STA $D3EE
C1/BA21: 60           RTS 

C1/BA22: B2 EB        LDA ($EB)
C1/BA24: 30 16        BMI $BA3C
C1/BA26: 20 99 C0     JSR $C099
C1/BA29: 20 07 BF     JSR $BF07
C1/BA2C: A9 F8        LDA #$F8
C1/BA2E: C2 20        REP #$20
C1/BA30: 0A           ASL 
C1/BA31: AA           TAX 
C1/BA32: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BA36: 8D DA D3     STA $D3DA
C1/BA39: 7B           TDC 
C1/BA3A: E2 20        SEP #$20
C1/BA3C: 60           RTS 
C1/BA3D: 20 99 C0     JSR $C099
C1/BA40: 20 0D BF     JSR $BF0D
C1/BA43: A9 00        LDA #$00
C1/BA45: 8D 8B CE     STA $CE8B
C1/BA48: 18           CLC 
C1/BA49: 69 40        ADC #$40
C1/BA4B: 8D CB CE     STA $CECB
C1/BA4E: A9 55        LDA #$55
C1/BA50: 8D 8C CE     STA $CE8C
C1/BA53: 18           CLC 
C1/BA54: 69 40        ADC #$40
C1/BA56: 8D CC CE     STA $CECC
C1/BA59: A9 AA        LDA #$AA
C1/BA5B: 8D 8D CE     STA $CE8D
C1/BA5E: 18           CLC 
C1/BA5F: 69 40        ADC #$40
C1/BA61: 8D CD CE     STA $CECD
C1/BA64: 60           RTS 
C1/BA65: 20 99 C0     JSR $C099
C1/BA68: 20 BF BD     JSR $BDBF
C1/BA6B: 7B           TDC 
C1/BA6C: AA           TAX 
C1/BA6D: 64 70        STZ $70
C1/BA6F: A5 70        LDA $70
C1/BA71: 1A           INC 
C1/BA72: 85 70        STA $70
C1/BA74: 9D DE D3     STA $D3DE,X
C1/BA77: 9E DF D7     STZ $D7DF,X
C1/BA7A: 18           CLC 
C1/BA7B: 69 08        ADC #$08
C1/BA7D: 9D DE D4     STA $D4DE,X
C1/BA80: 9E DF D8     STZ $D8DF,X
C1/BA83: 9E 67 D4     STZ $D467,X
C1/BA86: 9E 67 D5     STZ $D567,X
C1/BA89: C2 20        REP #$20
C1/BA8B: 8A           TXA 
C1/BA8C: 18           CLC 
C1/BA8D: 69 10 00     ADC #$0010
C1/BA90: AA           TAX 
C1/BA91: 7B           TDC 
C1/BA92: E2 20        SEP #$20
C1/BA94: E0 80 00     CPX #$0080
C1/BA97: D0 D6        BNE $BA6F
C1/BA99: 60           RTS 
C1/BA9A: 7B           TDC 
C1/BA9B: AA           TAX 
C1/BA9C: B2 EB        LDA ($EB)
C1/BA9E: 30 0B        BMI $BAAB
C1/BAA0: BD D8 D5     LDA $D5D8,X
C1/BAA3: 38           SEC 
C1/BAA4: E9 10        SBC #$10
C1/BAA6: 9D D8 D5     STA $D5D8,X
C1/BAA9: 80 09        BRA $BAB4
C1/BAAB: BD D8 D5     LDA $D5D8,X
C1/BAAE: 18           CLC 
C1/BAAF: 69 18        ADC #$18
C1/BAB1: 9D D8 D5     STA $D5D8,X
C1/BAB4: BD DA D5     LDA $D5DA,X
C1/BAB7: 38           SEC 
C1/BAB8: E9 08        SBC #$08
C1/BABA: 9D DA D5     STA $D5DA,X
C1/BABD: BD D8 D5     LDA $D5D8,X
C1/BAC0: 85 A6        STA $A6
C1/BAC2: BD DA D5     LDA $D5DA,X
C1/BAC5: 85 A7        STA $A7
C1/BAC7: BD DC D5     LDA $D5DC,X
C1/BACA: 85 A8        STA $A8
C1/BACC: BD DE D5     LDA $D5DE,X
C1/BACF: 85 A9        STA $A9
C1/BAD1: DA           PHX 
C1/BAD2: 20 6E 0A     JSR $0A6E
C1/BAD5: FA           PLX 
C1/BAD6: A5 AE        LDA $AE
C1/BAD8: 9D E3 D3     STA $D3E3,X
C1/BADB: A5 AF        LDA $AF
C1/BADD: 9D E4 D3     STA $D3E4,X
C1/BAE0: A5 B0        LDA $B0
C1/BAE2: 9D E5 D3     STA $D3E5,X
C1/BAE5: C2 20        REP #$20
C1/BAE7: 8A           TXA 
C1/BAE8: 18           CLC 
C1/BAE9: 69 10 00     ADC #$0010
C1/BAEC: AA           TAX 
C1/BAED: 7B           TDC 
C1/BAEE: E2 20        SEP #$20
C1/BAF0: E0 80 00     CPX #$0080
C1/BAF3: D0 A7        BNE $BA9C
C1/BAF5: 60           RTS 
C1/BAF6: 20 99 C0     JSR $C099
C1/BAF9: 20 9A BA     JSR $BA9A
C1/BAFC: 20 BF BD     JSR $BDBF
C1/BAFF: 7B           TDC 
C1/BB00: AA           TAX 
C1/BB01: 64 70        STZ $70
C1/BB03: A5 70        LDA $70
C1/BB05: 1A           INC 
C1/BB06: 85 70        STA $70
C1/BB08: 9D DF D7     STA $D7DF,X
C1/BB0B: 18           CLC 
C1/BB0C: 69 08        ADC #$08
C1/BB0E: 9D DF D8     STA $D8DF,X
C1/BB11: 9E 67 D4     STZ $D467,X
C1/BB14: 9E 67 D5     STZ $D567,X
C1/BB17: C2 20        REP #$20
C1/BB19: 8A           TXA 
C1/BB1A: 18           CLC 
C1/BB1B: 69 10 00     ADC #$0010
C1/BB1E: AA           TAX 
C1/BB1F: 7B           TDC 
C1/BB20: E2 20        SEP #$20
C1/BB22: E0 80 00     CPX #$0080
C1/BB25: D0 DC        BNE $BB03
C1/BB27: EE 6B DB     INC $DB6B
C1/BB2A: 60           RTS 
C1/BB2B: 20 99 C0     JSR $C099
C1/BB2E: A0 80 00     LDY #$0080
C1/BB31: 20 77 C0     JSR $C077
C1/BB34: 7B           TDC 
C1/BB35: AA           TAX 
C1/BB36: 64 70        STZ $70
C1/BB38: A5 70        LDA $70
C1/BB3A: 18           CLC 
C1/BB3B: 69 02        ADC #$02
C1/BB3D: 9D DE D3     STA $D3DE,X
C1/BB40: 85 70        STA $70
C1/BB42: 20 96 FC     JSR $FC96       ; generate random number
C1/BB45: 9D E1 D5     STA $D5E1,X
C1/BB48: C2 20        REP #$20
C1/BB4A: 8A           TXA 
C1/BB4B: 18           CLC 
C1/BB4C: 69 10 00     ADC #$0010
C1/BB4F: AA           TAX 
C1/BB50: 7B           TDC 
C1/BB51: E2 20        SEP #$20
C1/BB53: E0 80 00     CPX #$0080
C1/BB56: D0 E0        BNE $BB38
C1/BB58: 60           RTS 
C1/BB59: 20 99 C0     JSR $C099
C1/BB5C: 20 BF BD     JSR $BDBF
C1/BB5F: 7B           TDC 
C1/BB60: AA           TAX 
C1/BB61: 9E 67 D4     STZ $D467,X
C1/BB64: 9E 67 D5     STZ $D567,X
C1/BB67: 8A           TXA 
C1/BB68: 18           CLC 
C1/BB69: 69 10        ADC #$10
C1/BB6B: AA           TAX 
C1/BB6C: E0 80 00     CPX #$0080
C1/BB6F: D0 F0        BNE $BB61
C1/BB71: 7B           TDC 
C1/BB72: AA           TAX 
C1/BB73: 64 70        STZ $70
C1/BB75: A5 70        LDA $70
C1/BB77: 9D 7B CE     STA $CE7B,X
C1/BB7A: 18           CLC 
C1/BB7B: 69 40        ADC #$40
C1/BB7D: 9D BB CE     STA $CEBB,X
C1/BB80: A5 70        LDA $70
C1/BB82: 18           CLC 
C1/BB83: 69 20        ADC #$20
C1/BB85: 85 70        STA $70
C1/BB87: E8           INX 
C1/BB88: E0 20 00     CPX #$0020
C1/BB8B: D0 E8        BNE $BB75
C1/BB8D: 60           RTS 
C1/BB8E: 20 BF BD     JSR $BDBF
C1/BB91: 7B           TDC 
C1/BB92: AA           TAX 
C1/BB93: A9 02        LDA #$02
C1/BB95: 9D DE D3     STA $D3DE,X
C1/BB98: 18           CLC 
C1/BB99: 69 02        ADC #$02
C1/BB9B: 9D 5E D4     STA $D45E,X
C1/BB9E: 18           CLC 
C1/BB9F: 69 02        ADC #$02
C1/BBA1: 9D DE D4     STA $D4DE,X
C1/BBA4: 9E 67 D5     STZ $D567,X
C1/BBA7: C2 20        REP #$20
C1/BBA9: 8A           TXA 
C1/BBAA: 18           CLC 
C1/BBAB: 69 10 00     ADC #$0010
C1/BBAE: AA           TAX 
C1/BBAF: 7B           TDC 
C1/BBB0: E2 20        SEP #$20
C1/BBB2: E0 80 00     CPX #$0080
C1/BBB5: D0 DC        BNE $BB93
C1/BBB7: 60           RTS 
C1/BBB8: 20 99 C0     JSR $C099
C1/BBBB: 20 BF BD     JSR $BDBF
C1/BBBE: 7B           TDC 
C1/BBBF: AA           TAX 
C1/BBC0: 20 96 FC     JSR $FC96       ; generate random number
C1/BBC3: 29 07        AND #$07
C1/BBC5: 1A           INC 
C1/BBC6: 9D DE D3     STA $D3DE,X
C1/BBC9: C2 20        REP #$20
C1/BBCB: 8A           TXA 
C1/BBCC: 18           CLC 
C1/BBCD: 69 10 00     ADC #$0010
C1/BBD0: AA           TAX 
C1/BBD1: 7B           TDC 
C1/BBD2: E2 20        SEP #$20
C1/BBD4: E0 00 02     CPX #$0200
C1/BBD7: D0 E7        BNE $BBC0
C1/BBD9: 60           RTS 
C1/BBDA: 20 99 C0     JSR $C099
C1/BBDD: 20 E6 BB     JSR $BBE6
C1/BBE0: 20 10 BF     JSR $BF10
C1/BBE3: 4C BF BD     JMP $BDBF
C1/BBE6: 20 3B 8D     JSR $8D3B
C1/BBE9: D0 03        BNE $BBEE
C1/BBEB: 20 04 BF     JSR $BF04
C1/BBEE: 60           RTS 
C1/BBEF: 20 39 BF     JSR $BF39
C1/BBF2: C2 20        REP #$20
C1/BBF4: AD 86 F5     LDA $F586
C1/BBF7: 1A           INC 
C1/BBF8: 0A           ASL 
C1/BBF9: AA           TAX 
C1/BBFA: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BBFE: 8D 3A D4     STA $D43A
C1/BC01: 7B           TDC 
C1/BC02: E2 20        SEP #$20
C1/BC04: A9 01        LDA #$01
C1/BC06: 8D 3E D4     STA $D43E
C1/BC09: EE 47 D4     INC $D447
C1/BC0C: 4C E6 BB     JMP $BBE6

C1/BC0F: 20 3F BF     JSR $BF3F
C1/BC12: C2 20        REP #$20
C1/BC14: AD 86 F5     LDA $F586
C1/BC17: 1A           INC 
C1/BC18: 0A           ASL 
C1/BC19: AA           TAX 
C1/BC1A: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BC1E: 8D 3A D4     STA $D43A
C1/BC21: 7B           TDC 
C1/BC22: E2 20        SEP #$20
C1/BC24: 9C 40 D4     STZ $D440
C1/BC27: 20 E6 BB     JSR $BBE6
C1/BC2A: 4C 19 BF     JMP $BF19

C1/BC2D: 20 99 C0     JSR $C099
C1/BC30: 20 04 BF     JSR $BF04
C1/BC33: 20 3B 8D     JSR $8D3B
C1/BC36: F0 3C        BEQ $BC74
C1/BC38: 20 BF BD     JSR $BDBF
C1/BC3B: EE E7 D3     INC $D3E7
C1/BC3E: A9 01        LDA #$01
C1/BC40: 8D DE D3     STA $D3DE
C1/BC43: C2 20        REP #$20
C1/BC45: AD 86 F5     LDA $F586
C1/BC48: 1A           INC 
C1/BC49: 0A           ASL 
C1/BC4A: AA           TAX 
C1/BC4B: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BC4F: 8D DA D3     STA $D3DA
C1/BC52: 7B           TDC 
C1/BC53: E2 20        SEP #$20
C1/BC55: A2 80 00     LDX #$0080
C1/BC58: FE E7 D3     INC $D3E7,X
C1/BC5B: 20 96 FC     JSR $FC96       ; generate random number
C1/BC5E: 29 0F        AND #$0F
C1/BC60: 1A           INC 
C1/BC61: 9D DE D3     STA $D3DE,X
C1/BC64: C2 20        REP #$20
C1/BC66: 8A           TXA 
C1/BC67: 18           CLC 
C1/BC68: 69 10 00     ADC #$0010
C1/BC6B: AA           TAX 
C1/BC6C: 7B           TDC 
C1/BC6D: E2 20        SEP #$20
C1/BC6F: E0 80 01     CPX #$0180
C1/BC72: D0 E4        BNE $BC58
C1/BC74: 60           RTS 

C1/BC75: 20 29 BF     JSR $BF29
C1/BC78: 20 35 C0     JSR $C035
C1/BC7B: 20 E6 BB     JSR $BBE6
C1/BC7E: C2 20        REP #$20
C1/BC80: AD 86 F5     LDA $F586
C1/BC83: 1A           INC 
C1/BC84: 0A           ASL 
C1/BC85: AA           TAX 
C1/BC86: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BC8A: 8D 0A D4     STA $D40A
C1/BC8D: 8D 2A D4     STA $D42A
C1/BC90: 8D 4A D4     STA $D44A
C1/BC93: 7B           TDC 
C1/BC94: E2 20        SEP #$20
C1/BC96: 60           RTS 
C1/BC97: 20 99 C0     JSR $C099
C1/BC9A: C2 20        REP #$20
C1/BC9C: AD 86 F5     LDA $F586
C1/BC9F: 1A           INC 
C1/BCA0: 0A           ASL 
C1/BCA1: AA           TAX 
C1/BCA2: 7B           TDC 
C1/BCA3: A8           TAY 
C1/BCA4: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BCA8: 99 1A D4     STA $D41A,Y
C1/BCAB: 98           TYA 
C1/BCAC: 18           CLC 
C1/BCAD: 69 10 00     ADC #$0010
C1/BCB0: A8           TAY 
C1/BCB1: C9 40 00     CMP #$0040
C1/BCB4: D0 EE        BNE $BCA4
C1/BCB6: 7B           TDC 
C1/BCB7: E2 20        SEP #$20
C1/BCB9: EE 6B DB     INC $DB6B
C1/BCBC: 60           RTS 
C1/BCBD: 20 99 C0     JSR $C099
C1/BCC0: C2 20        REP #$20
C1/BCC2: AD 86 F5     LDA $F586
C1/BCC5: 1A           INC 
C1/BCC6: 0A           ASL 
C1/BCC7: AA           TAX 
C1/BCC8: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BCCC: 8D 1A D4     STA $D41A
C1/BCCF: 7B           TDC 
C1/BCD0: E2 20        SEP #$20
C1/BCD2: 20 07 BF     JSR $BF07
C1/BCD5: EE 27 D4     INC $D427
C1/BCD8: 4C E6 BB     JMP $BBE6
C1/BCDB: 4C 5F BD     JMP $BD5F
C1/BCDE: 20 5F BD     JSR $BD5F
C1/BCE1: 20 4C 01     JSR $014C
C1/BCE4: A6 E9        LDX $E9
C1/BCE6: 86 70        STX $70
C1/BCE8: 7B           TDC 
C1/BCE9: AA           TAX 
C1/BCEA: A8           TAY 
C1/BCEB: 20 A1 BD     JSR $BDA1
C1/BCEE: C9 08        CMP #$08
C1/BCF0: 90 05        BCC $BCF7
C1/BCF2: 38           SEC 
C1/BCF3: E9 08        SBC #$08
C1/BCF5: 80 02        BRA $BCF9
C1/BCF7: 09 80        ORA #$80
C1/BCF9: 99 E2 D3     STA $D3E2,Y
C1/BCFC: C2 20        REP #$20
C1/BCFE: 98           TYA 
C1/BCFF: 18           CLC 
C1/BD00: 69 10 00     ADC #$0010
C1/BD03: A8           TAY 
C1/BD04: A5 70        LDA $70
C1/BD06: 18           CLC 
C1/BD07: 69 18 00     ADC #$0018
C1/BD0A: 85 70        STA $70
C1/BD0C: 7B           TDC 
C1/BD0D: E2 20        SEP #$20
C1/BD0F: E8           INX 
C1/BD10: E0 08 00     CPX #$0008
C1/BD13: D0 D6        BNE $BCEB
C1/BD15: 20 3B 8D     JSR $8D3B
C1/BD18: F0 08        BEQ $BD22
C1/BD1A: A9 EF        LDA #$EF
C1/BD1C: 85 7E        STA $7E
C1/BD1E: 7B           TDC 
C1/BD1F: 20 02 7B     JSR $7B02
C1/BD22: 60           RTS 
C1/BD23: 20 2C C0     JSR $C02C
C1/BD26: 20 04 BF     JSR $BF04
C1/BD29: 20 3B 8D     JSR $8D3B
C1/BD2C: F0 30        BEQ $BD5E
C1/BD2E: 20 BF BD     JSR $BDBF
C1/BD31: EE E7 D3     INC $D3E7
C1/BD34: EE F7 D3     INC $D3F7
C1/BD37: C2 20        REP #$20
C1/BD39: AD 86 F5     LDA $F586
C1/BD3C: 1A           INC 
C1/BD3D: 0A           ASL 
C1/BD3E: AA           TAX 
C1/BD3F: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BD43: 8D EA D3     STA $D3EA
C1/BD46: A0 20 00     LDY #$0020
C1/BD49: BF 44 7D D9  LDA $D97D44,X
C1/BD4D: 99 DA D3     STA $D3DA,Y
C1/BD50: 98           TYA 
C1/BD51: 18           CLC 
C1/BD52: 69 10 00     ADC #$0010
C1/BD55: A8           TAY 
C1/BD56: C0 00 02     CPY #$0200
C1/BD59: D0 EE        BNE $BD49
C1/BD5B: 7B           TDC 
C1/BD5C: E2 20        SEP #$20
C1/BD5E: 60           RTS 
C1/BD5F: 20 3F BF     JSR $BF3F
C1/BD62: 20 19 BF     JSR $BF19
C1/BD65: AD 50 DB     LDA $DB50
C1/BD68: 29 40        AND #$40
C1/BD6A: D0 24        BNE $BD90
C1/BD6C: C2 20        REP #$20
C1/BD6E: AD 86 F5     LDA $F586
C1/BD71: 1A           INC 
C1/BD72: 0A           ASL 
C1/BD73: AA           TAX 
C1/BD74: 7B           TDC 
C1/BD75: A8           TAY 
C1/BD76: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BD7A: 99 DA D3     STA $D3DA,Y
C1/BD7D: 98           TYA 
C1/BD7E: 18           CLC 
C1/BD7F: 69 10 00     ADC #$0010
C1/BD82: A8           TAY 
C1/BD83: C0 80 00     CPY #$0080
C1/BD86: D0 EE        BNE $BD76
C1/BD88: 7B           TDC 
C1/BD89: E2 20        SEP #$20
C1/BD8B: A9 10        LDA #$10
C1/BD8D: 20 57 FC     JSR $FC57
C1/BD90: AD E7 D1     LDA $D1E7
C1/BD93: 09 20        ORA #$20
C1/BD95: 8D E7 D1     STA $D1E7
C1/BD98: AD F7 D1     LDA $D1F7
C1/BD9B: 09 20        ORA #$20
C1/BD9D: 8D F7 D1     STA $D1F7
C1/BDA0: 60           RTS 
C1/BDA1: DA           PHX 
C1/BDA2: 5A           PHY 
C1/BDA3: 7B           TDC 
C1/BDA4: AA           TAX 
C1/BDA5: A8           TAY 
C1/BDA6: C8           INY 
C1/BDA7: B1 70        LDA ($70),Y
C1/BDA9: C9 FF        CMP #$FF
C1/BDAB: D0 0B        BNE $BDB8
C1/BDAD: C8           INY 
C1/BDAE: C8           INY 
C1/BDAF: E8           INX 
C1/BDB0: E0 0C 00     CPX #$000C
C1/BDB3: D0 F2        BNE $BDA7
C1/BDB5: 7B           TDC 
C1/BDB6: 80 01        BRA $BDB9
C1/BDB8: 8A           TXA 
C1/BDB9: 7A           PLY 
C1/BDBA: FA           PLX 
C1/BDBB: 60           RTS 
C1/BDBC: 4C BF BD     JMP $BDBF
C1/BDBF: 7B           TDC 
C1/BDC0: AA           TAX 
C1/BDC1: BD D8 D1     LDA $D1D8,X
C1/BDC4: 9D 58 D2     STA $D258,X
C1/BDC7: 9D D8 D2     STA $D2D8,X
C1/BDCA: 9D 58 D3     STA $D358,X
C1/BDCD: BD D8 D3     LDA $D3D8,X
C1/BDD0: 9D 58 D4     STA $D458,X
C1/BDD3: 9D D8 D4     STA $D4D8,X
C1/BDD6: 9D 58 D5     STA $D558,X
C1/BDD9: BD D8 D5     LDA $D5D8,X
C1/BDDC: 9D 58 D6     STA $D658,X
C1/BDDF: 9D D8 D6     STA $D6D8,X
C1/BDE2: 9D 58 D7     STA $D758,X
C1/BDE5: E8           INX 
C1/BDE6: E0 80 00     CPX #$0080
C1/BDE9: D0 D6        BNE $BDC1
C1/BDEB: 60           RTS 
C1/BDEC: 20 BF BD     JSR $BDBF
C1/BDEF: 7B           TDC 
C1/BDF0: AA           TAX 
C1/BDF1: BD DE D3     LDA $D3DE,X
C1/BDF4: 1A           INC 
C1/BDF5: 1A           INC 
C1/BDF6: 9D 5E D4     STA $D45E,X
C1/BDF9: 1A           INC 
C1/BDFA: 1A           INC 
C1/BDFB: 9D DE D4     STA $D4DE,X
C1/BDFE: 1A           INC 
C1/BDFF: 1A           INC 
C1/BE00: 9D 5E D5     STA $D55E,X
C1/BE03: 8A           TXA 
C1/BE04: 18           CLC 
C1/BE05: 69 10        ADC #$10
C1/BE07: AA           TAX 
C1/BE08: E0 80 00     CPX #$0080
C1/BE0B: D0 E4        BNE $BDF1
C1/BE0D: AE 86 F5     LDX $F586
C1/BE10: 86 70        STX $70
C1/BE12: 7B           TDC 
C1/BE13: AA           TAX 
C1/BE14: A8           TAY 
C1/BE15: C2 20        REP #$20
C1/BE17: A5 70        LDA $70
C1/BE19: 0A           ASL 
C1/BE1A: AA           TAX 
C1/BE1B: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BE1F: 99 DA D3     STA $D3DA,Y
C1/BE22: 99 EA D3     STA $D3EA,Y
C1/BE25: 99 FA D3     STA $D3FA,Y
C1/BE28: 99 0A D4     STA $D40A,Y
C1/BE2B: 99 1A D4     STA $D41A,Y
C1/BE2E: 99 2A D4     STA $D42A,Y
C1/BE31: E6 70        INC $70
C1/BE33: 98           TYA 
C1/BE34: 18           CLC 
C1/BE35: 69 80 00     ADC #$0080
C1/BE38: A8           TAY 
C1/BE39: C0 00 02     CPY #$0200
C1/BE3C: D0 D9        BNE $BE17
C1/BE3E: 7B           TDC 
C1/BE3F: E2 20        SEP #$20
C1/BE41: 60           RTS 
C1/BE42: 20 99 C0     JSR $C099
C1/BE45: C2 20        REP #$20
C1/BE47: AD 86 F5     LDA $F586
C1/BE4A: 1A           INC 
C1/BE4B: 0A           ASL 
C1/BE4C: AA           TAX 
C1/BE4D: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BE51: 8D EA D3     STA $D3EA
C1/BE54: 7B           TDC 
C1/BE55: E2 20        SEP #$20
C1/BE57: 4C 0A BF     JMP $BF0A
C1/BE5A: 20 04 BF     JSR $BF04
C1/BE5D: AD 53 DB     LDA $DB53
C1/BE60: 85 70        STA $70
C1/BE62: 7B           TDC 
C1/BE63: AA           TAX 
C1/BE64: 06 70        ASL $70
C1/BE66: B0 08        BCS $BE70
C1/BE68: E8           INX 
C1/BE69: E0 04 00     CPX #$0004
C1/BE6C: D0 F6        BNE $BE64
C1/BE6E: 80 36        BRA $BEA6
C1/BE70: 8A           TXA 
C1/BE71: 0A           ASL 
C1/BE72: 0A           ASL 
C1/BE73: 0A           ASL 
C1/BE74: 0A           ASL 
C1/BE75: AA           TAX 
C1/BE76: 7B           TDC 
C1/BE77: A8           TAY 
C1/BE78: BD D8 D1     LDA $D1D8,X
C1/BE7B: 99 18 D2     STA $D218,Y
C1/BE7E: BD D8 D3     LDA $D3D8,X
C1/BE81: 99 18 D4     STA $D418,Y
C1/BE84: BD D8 D5     LDA $D5D8,X
C1/BE87: 99 18 D6     STA $D618,Y
C1/BE8A: E8           INX 
C1/BE8B: C8           INY 
C1/BE8C: C0 10 00     CPY #$0010
C1/BE8F: D0 E7        BNE $BE78
C1/BE91: C2 20        REP #$20
C1/BE93: AD 86 F5     LDA $F586
C1/BE96: 1A           INC 
C1/BE97: 0A           ASL 
C1/BE98: AA           TAX 
C1/BE99: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BE9D: 8D 1A D4     STA $D41A
C1/BEA0: 7B           TDC 
C1/BEA1: E2 20        SEP #$20
C1/BEA3: EE 27 D4     INC $D427
C1/BEA6: 60           RTS 
C1/BEA7: 20 99 C0     JSR $C099
C1/BEAA: A0 40 00     LDY #$0040
C1/BEAD: 20 77 C0     JSR $C077
C1/BEB0: A9 08        LDA #$08
C1/BEB2: 8D DE D3     STA $D3DE
C1/BEB5: A9 10        LDA #$10
C1/BEB7: 8D EE D3     STA $D3EE
C1/BEBA: 4C 0A BF     JMP $BF0A
C1/BEBD: 20 99 C0     JSR $C099
C1/BEC0: A0 20 00     LDY #$0020
C1/BEC3: 20 77 C0     JSR $C077
C1/BEC6: 4C 07 BF     JMP $BF07
C1/BEC9: 20 99 C0     JSR $C099
C1/BECC: 20 04 BF     JSR $BF04
C1/BECF: A9 08        LDA #$08
C1/BED1: 8D DE D3     STA $D3DE
C1/BED4: EE E7 D3     INC $D3E7
C1/BED7: A9 09        LDA #$09
C1/BED9: 8D EE D3     STA $D3EE
C1/BEDC: EE F7 D3     INC $D3F7
C1/BEDF: A9 0A        LDA #$0A
C1/BEE1: 8D 1E D4     STA $D41E
C1/BEE4: EE 27 D4     INC $D427
C1/BEE7: 60           RTS 
C1/BEE8: 20 99 C0     JSR $C099
C1/BEEB: A0 60 00     LDY #$0060
C1/BEEE: 20 77 C0     JSR $C077
C1/BEF1: 20 0D BF     JSR $BF0D
C1/BEF4: A9 08        LDA #$08
C1/BEF6: 8D DE D3     STA $D3DE
C1/BEF9: A9 10        LDA #$10
C1/BEFB: 8D EE D3     STA $D3EE
C1/BEFE: A9 18        LDA #$18
C1/BF00: 8D FE D3     STA $D3FE
C1/BF03: 60           RTS 
C1/BF04: 9C E7 D3     STZ $D3E7
C1/BF07: 9C F7 D3     STZ $D3F7
C1/BF0A: 9C 07 D4     STZ $D407
C1/BF0D: 9C 17 D4     STZ $D417
C1/BF10: 9C 27 D4     STZ $D427
C1/BF13: 9C 37 D4     STZ $D437
C1/BF16: 9C 47 D4     STZ $D447
C1/BF19: 9C 57 D4     STZ $D457
C1/BF1C: 60           RTS 
C1/BF1D: 20 99 C0     JSR $C099
C1/BF20: A0 80 00     LDY #$0080
C1/BF23: 20 77 C0     JSR $C077
C1/BF26: 4C 2C BF     JMP $BF2C

C1/BF29: 20 99 C0     JSR $C099
C1/BF2C: 9C E7 D3     STZ $D3E7
C1/BF2F: 9C 07 D4     STZ $D407
C1/BF32: 9C 27 D4     STZ $D427
C1/BF35: 9C 47 D4     STZ $D447
C1/BF38: 60           RTS 

C1/BF39: 20 3F BF     JSR $BF3F
C1/BF3C: 4C 16 BF     JMP $BF16

C1/BF3F: 20 99 C0     JSR $C099
C1/BF42: 7B           TDC 
C1/BF43: AA           TAX 
C1/BF44: DA           PHX 
C1/BF45: 20 96 FC     JSR $FC96       ; generate random number
C1/BF48: 29 1F        AND #$1F
C1/BF4A: D0 01        BNE $BF4D
C1/BF4C: 1A           INC 
C1/BF4D: FA           PLX 
C1/BF4E: 9D DE D3     STA $D3DE,X
C1/BF51: 8A           TXA 
C1/BF52: 18           CLC 
C1/BF53: 69 10        ADC #$10
C1/BF55: AA           TAX 
C1/BF56: C9 80        CMP #$80
C1/BF58: D0 EA        BNE $BF44
C1/BF5A: 60           RTS 

C1/BF5B: 20 29 BF     JSR $BF29
C1/BF5E: C2 20        REP #$20
C1/BF60: AD 86 F5     LDA $F586
C1/BF63: 0A           ASL 
C1/BF64: AA           TAX 
C1/BF65: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BF69: 8D EA D3     STA $D3EA
C1/BF6C: BF 44 7D D9  LDA $D97D44,X
C1/BF70: 8D 0A D4     STA $D40A
C1/BF73: BF 46 7D D9  LDA $D97D46,X
C1/BF77: 8D 2A D4     STA $D42A
C1/BF7A: BF 48 7D D9  LDA $D97D48,X
C1/BF7E: 8D 4A D4     STA $D44A
C1/BF81: 7B           TDC 
C1/BF82: E2 20        SEP #$20
C1/BF84: 60           RTS 

C1/BF85: 20 99 C0     JSR $C099
C1/BF88: 7B           TDC 
C1/BF89: AA           TAX 
C1/BF8A: A9 10        LDA #$10
C1/BF8C: 9D DE D3     STA $D3DE,X
C1/BF8F: 3A           DEC 
C1/BF90: 48           PHA 
C1/BF91: 8A           TXA 
C1/BF92: 18           CLC 
C1/BF93: 69 10        ADC #$10
C1/BF95: AA           TAX 
C1/BF96: 68           PLA 
C1/BF97: E0 80 00     CPX #$0080
C1/BF9A: D0 F0        BNE $BF8C
C1/BF9C: A0 80 00     LDY #$0080
C1/BF9F: 4C 77 C0     JMP $C077
C1/BFA2: 20 99 C0     JSR $C099
C1/BFA5: 20 E6 BB     JSR $BBE6
C1/BFA8: 4C 10 BF     JMP $BF10
C1/BFAB: 0A           ASL 
C1/BFAC: AA           TAX 
C1/BFAD: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/BFB1: 8D DA D3     STA $D3DA
C1/BFB4: 8D EA D3     STA $D3EA
C1/BFB7: 8D FA D3     STA $D3FA
C1/BFBA: 8D 0A D4     STA $D40A
C1/BFBD: 8D 1A D4     STA $D41A
C1/BFC0: 8D 2A D4     STA $D42A
C1/BFC3: 8D 3A D4     STA $D43A
C1/BFC6: 8D 4A D4     STA $D44A
C1/BFC9: 7B           TDC 
C1/BFCA: 60           RTS 
C1/BFCB: B2 EB        LDA ($EB)
C1/BFCD: 29 40        AND #$40
C1/BFCF: F0 0A        BEQ $BFDB
C1/BFD1: C2 20        REP #$20
C1/BFD3: A9 33 00     LDA #$0033
C1/BFD6: 20 AB BF     JSR $BFAB
C1/BFD9: E2 20        SEP #$20
C1/BFDB: 20 99 C0     JSR $C099
C1/BFDE: 4C 10 BF     JMP $BF10
C1/BFE1: B2 EB        LDA ($EB)
C1/BFE3: 29 40        AND #$40
C1/BFE5: F0 0A        BEQ $BFF1
C1/BFE7: C2 20        REP #$20
C1/BFE9: A9 FE 00     LDA #$00FE
C1/BFEC: 20 AB BF     JSR $BFAB
C1/BFEF: E2 20        SEP #$20
C1/BFF1: 20 99 C0     JSR $C099
C1/BFF4: 4C 10 BF     JMP $BF10
C1/BFF7: B2 EB        LDA ($EB)
C1/BFF9: 29 40        AND #$40
C1/BFFB: F0 0A        BEQ $C007
C1/BFFD: C2 20        REP #$20
C1/BFFF: A9 FF 00     LDA #$00FF
C1/C002: 20 AB BF     JSR $BFAB
C1/C005: E2 20        SEP #$20
C1/C007: 60           RTS 
C1/C008: B2 EB        LDA ($EB)
C1/C00A: 29 40        AND #$40
C1/C00C: F0 0A        BEQ $C018
C1/C00E: C2 20        REP #$20
C1/C010: A9 00 01     LDA #$0100
C1/C013: 20 AB BF     JSR $BFAB
C1/C016: E2 20        SEP #$20
C1/C018: 60           RTS 
C1/C019: B2 EB        LDA ($EB)
C1/C01B: 29 40        AND #$40
C1/C01D: F0 0A        BEQ $C029
C1/C01F: C2 20        REP #$20
C1/C021: A9 38 00     LDA #$0038
C1/C024: 20 AB BF     JSR $BFAB
C1/C027: E2 20        SEP #$20
C1/C029: 4C 2C C0     JMP $C02C
C1/C02C: 20 99 C0     JSR $C099
C1/C02F: 80 04        BRA $C035
C1/C031: A9 01        LDA #$01
C1/C033: 80 02        BRA $C037
C1/C035: A9 04        LDA #$04
C1/C037: 8D DE D3     STA $D3DE
C1/C03A: 8D EE D3     STA $D3EE
C1/C03D: 8D FE D3     STA $D3FE
C1/C040: 8D 0E D4     STA $D40E
C1/C043: 8D 1E D4     STA $D41E
C1/C046: 8D 2E D4     STA $D42E
C1/C049: 8D 3E D4     STA $D43E
C1/C04C: 8D 4E D4     STA $D44E
C1/C04F: 60           RTS 
C1/C050: 20 99 C0     JSR $C099
C1/C053: A0 40 00     LDY #$0040
C1/C056: 20 77 C0     JSR $C077
C1/C059: 20 10 BF     JSR $BF10
C1/C05C: 4C 5F C0     JMP $C05F
C1/C05F: A9 04        LDA #$04
C1/C061: 7B           TDC 
C1/C062: AA           TAX 
C1/C063: 1A           INC 
C1/C064: 9D DE D3     STA $D3DE,X
C1/C067: 18           CLC 
C1/C068: 69 04        ADC #$04
C1/C06A: 48           PHA 
C1/C06B: 8A           TXA 
C1/C06C: 18           CLC 
C1/C06D: 69 10        ADC #$10
C1/C06F: AA           TAX 
C1/C070: 68           PLA 
C1/C071: E0 80 00     CPX #$0080
C1/C074: D0 EE        BNE $C064
C1/C076: 60           RTS 
C1/C077: 84 72        STY $72
C1/C079: C2 20        REP #$20
C1/C07B: AD 86 F5     LDA $F586
C1/C07E: 0A           ASL 
C1/C07F: AA           TAX 
C1/C080: 7B           TDC 
C1/C081: A8           TAY 
C1/C082: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/C086: 99 DA D3     STA $D3DA,Y
C1/C089: E8           INX 
C1/C08A: E8           INX 
C1/C08B: 98           TYA 
C1/C08C: 18           CLC 
C1/C08D: 69 10 00     ADC #$0010
C1/C090: A8           TAY 
C1/C091: C4 72        CPY $72
C1/C093: D0 ED        BNE $C082
C1/C095: 7B           TDC 
C1/C096: E2 20        SEP #$20
C1/C098: 60           RTS 
C1/C099: AD 53 DB     LDA $DB53
C1/C09C: 20 7A FC     JSR $FC7A
C1/C09F: 0A           ASL 
C1/C0A0: 0A           ASL 
C1/C0A1: 0A           ASL 
C1/C0A2: 0A           ASL 
C1/C0A3: AA           TAX 
C1/C0A4: 86 70        STX $70
C1/C0A6: A9 08        LDA #$08
C1/C0A8: 85 74        STA $74
C1/C0AA: 7B           TDC 
C1/C0AB: A8           TAY 
C1/C0AC: A9 10        LDA #$10
C1/C0AE: 85 72        STA $72
C1/C0B0: A6 70        LDX $70
C1/C0B2: BD D8 D1     LDA $D1D8,X
C1/C0B5: 99 D8 D1     STA $D1D8,Y
C1/C0B8: BD D8 D3     LDA $D3D8,X
C1/C0BB: 99 D8 D3     STA $D3D8,Y
C1/C0BE: BD D8 D5     LDA $D5D8,X
C1/C0C1: 99 D8 D5     STA $D5D8,Y
C1/C0C4: BD D8 D7     LDA $D7D8,X
C1/C0C7: 99 D8 D7     STA $D7D8,Y
C1/C0CA: C8           INY 
C1/C0CB: E8           INX 
C1/C0CC: C6 72        DEC $72
C1/C0CE: D0 E2        BNE $C0B2
C1/C0D0: C6 74        DEC $74
C1/C0D2: D0 D8        BNE $C0AC
C1/C0D4: 60           RTS 
C1/C0D5: 7B           TDC 
C1/C0D6: AA           TAX 
C1/C0D7: AD 53 DB     LDA $DB53
C1/C0DA: 85 70        STA $70
C1/C0DC: 64 71        STZ $71
C1/C0DE: 06 70        ASL $70
C1/C0E0: B0 03        BCS $C0E5
C1/C0E2: 4C C0 C1     JMP $C1C0
C1/C0E5: A9 01        LDA #$01
C1/C0E7: 9D E7 D3     STA $D3E7,X
C1/C0EA: C2 20        REP #$20
C1/C0EC: AD 86 F5     LDA $F586
C1/C0EF: 0A           ASL 
C1/C0F0: DA           PHX 
C1/C0F1: AA           TAX 
C1/C0F2: BF 42 7D D9  LDA $D97D42,X   ; pointer to attack animation scripts
C1/C0F6: FA           PLX 
C1/C0F7: 9D DA D3     STA $D3DA,X
C1/C0FA: 85 74        STA $74
C1/C0FC: 7B           TDC 
C1/C0FD: E2 20        SEP #$20
C1/C0FF: A9 D9        LDA #$D9
C1/C101: 9D DC D3     STA $D3DC,X
C1/C104: 85 76        STA $76
C1/C106: DA           PHX 
C1/C107: A7 74        LDA [$74]
C1/C109: 29 3F        AND #$3F
C1/C10B: 0A           ASL 
C1/C10C: AA           TAX 
C1/C10D: BF 1D B3 C1  LDA $C1B31D,X   ; height
C1/C111: 85 78        STA $78
C1/C113: BF 1C B3 C1  LDA $C1B31C,X   ; width
C1/C117: FA           PLX 
C1/C118: 9D D8 D3     STA $D3D8,X
C1/C11B: 9D E5 D1     STA $D1E5,X
C1/C11E: 85 7E        STA $7E
C1/C120: A5 78        LDA $78
C1/C122: 9D D9 D3     STA $D3D9,X
C1/C125: 9D E6 D1     STA $D1E6,X
C1/C128: 85 80        STA $80
C1/C12A: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/C12D: A5 82        LDA $82
C1/C12F: 9D DE D1     STA $D1DE,X
C1/C132: A0 01 00     LDY #$0001
C1/C135: B7 74        LDA [$74],Y     ; animation speed
C1/C137: 4A           LSR 
C1/C138: 4A           LSR 
C1/C139: 4A           LSR 
C1/C13A: 4A           LSR 
C1/C13B: 1A           INC 
C1/C13C: 9D DD D3     STA $D3DD,X     ; set frame duration
C1/C13F: 20 66 C2     JSR $C266
C1/C142: 9D DE D3     STA $D3DE,X
C1/C145: B7 74        LDA [$74],Y
C1/C147: 29 0F        AND #$0F
C1/C149: 1A           INC 
C1/C14A: 9D E0 D3     STA $D3E0,X     ; 
C1/C14D: A9 02        LDA #$02
C1/C14F: 9D DF D3     STA $D3DF,X     ; animation script offset
C1/C152: AD 50 DB     LDA $DB50
C1/C155: 29 80        AND #$80
C1/C157: 85 78        STA $78
C1/C159: AD 50 DB     LDA $DB50
C1/C15C: 0A           ASL 
C1/C15D: 29 80        AND #$80
C1/C15F: 05 71        ORA $71
C1/C161: 9D E2 D3     STA $D3E2,X
C1/C164: AD 51 DB     LDA $DB51
C1/C167: 05 78        ORA $78
C1/C169: 9D E1 D3     STA $D3E1,X
C1/C16C: AD 6D F8     LDA $F86D
C1/C16F: F0 23        BEQ $C194
C1/C171: A5 71        LDA $71
C1/C173: 05 78        ORA $78
C1/C175: 9D E1 D3     STA $D3E1,X
C1/C178: DA           PHX 
C1/C179: A5 71        LDA $71
C1/C17B: A8           TAY 
C1/C17C: B1 ED        LDA ($ED),Y
C1/C17E: D0 04        BNE $C184
C1/C180: FA           PLX 
C1/C181: 4C C0 C1     JMP $C1C0
C1/C184: 20 7A FC     JSR $FC7A
C1/C187: FA           PLX 
C1/C188: 85 72        STA $72
C1/C18A: BD E2 D3     LDA $D3E2,X
C1/C18D: 29 80        AND #$80
C1/C18F: 05 72        ORA $72
C1/C191: 9D E2 D3     STA $D3E2,X
C1/C194: 9E E6 D3     STZ $D3E6,X
C1/C197: 9E E1 D5     STZ $D5E1,X
C1/C19A: 9E DC D1     STZ $D1DC,X
C1/C19D: 9E DD D1     STZ $D1DD,X
C1/C1A0: 9E E3 D1     STZ $D1E3,X
C1/C1A3: 9E E4 D1     STZ $D1E4,X
C1/C1A6: 9E E7 D1     STZ $D1E7,X
C1/C1A9: 9E E7 D1     STZ $D1E7,X
C1/C1AC: BD D8 D3     LDA $D3D8,X
C1/C1AF: 9D E5 D1     STA $D1E5,X
C1/C1B2: BD D9 D3     LDA $D3D9,X
C1/C1B5: 9D E6 D1     STA $D1E6,X
C1/C1B8: 20 5D C3     JSR $C35D
C1/C1BB: 20 96 C2     JSR $C296
C1/C1BE: 80 03        BRA $C1C3
C1/C1C0: 9E E7 D3     STZ $D3E7,X
C1/C1C3: 8A           TXA 
C1/C1C4: 18           CLC 
C1/C1C5: 69 10        ADC #$10
C1/C1C7: AA           TAX 
C1/C1C8: E6 71        INC $71
C1/C1CA: A5 71        LDA $71
C1/C1CC: C9 08        CMP #$08
C1/C1CE: F0 03        BEQ $C1D3
C1/C1D0: 4C DE C0     JMP $C0DE
C1/C1D3: 20 0D C2     JSR $C20D
C1/C1D6: 4C D9 C1     JMP $C1D9

; [  ]

C1/C1D9: 9C 75 DB     STZ $DB75
C1/C1DC: 7B           TDC 
C1/C1DD: AA           TAX 
C1/C1DE: A8           TAY 
C1/C1DF: BF 8D C2 C1  LDA $C1C28D,X
C1/C1E3: 99 78 DB     STA $DB78,Y
C1/C1E6: A9 40        LDA #$40
C1/C1E8: 99 7C DB     STA $DB7C,Y
C1/C1EB: E8           INX 
C1/C1EC: E8           INX 
C1/C1ED: C8           INY 
C1/C1EE: C0 04 00     CPY #$0004
C1/C1F1: D0 EC        BNE $C1DF
C1/C1F3: AD 50 DB     LDA $DB50
C1/C1F6: 29 40        AND #$40
C1/C1F8: D0 12        BNE $C20C
C1/C1FA: AD 77 DB     LDA $DB77
C1/C1FD: F0 0D        BEQ $C20C
C1/C1FF: AD 76 DB     LDA $DB76
C1/C202: A8           TAY 
C1/C203: B9 4C 3C     LDA $3C4C,Y     ; aegis shield characters
C1/C206: 8D 75 DB     STA $DB75
C1/C209: EE 76 DB     INC $DB76
C1/C20C: 60           RTS 

; [  ]

C1/C20D: AD 6A DB     LDA $DB6A
C1/C210: D0 53        BNE $C265
C1/C212: EE 6A DB     INC $DB6A
C1/C215: 7B           TDC 
C1/C216: AA           TAX 
C1/C217: AD 54 DB     LDA $DB54
C1/C21A: 85 76        STA $76
C1/C21C: 64 71        STZ $71
C1/C21E: 06 76        ASL $76
C1/C220: 90 35        BCC $C257
C1/C222: FE D8 DA     INC $DAD8,X
C1/C225: AD 50 DB     LDA $DB50
C1/C228: 29 40        AND #$40
C1/C22A: F0 08        BEQ $C234
C1/C22C: A9 1C        LDA #$1C
C1/C22E: 9D DB DA     STA $DADB,X
C1/C231: 7B           TDC 
C1/C232: 80 06        BRA $C23A
C1/C234: 7B           TDC 
C1/C235: 9D DB DA     STA $DADB,X
C1/C238: A9 08        LDA #$08
C1/C23A: 18           CLC 
C1/C23B: 65 71        ADC $71
C1/C23D: A8           TAY 
C1/C23E: B9 36 D0     LDA $D036,Y
C1/C241: 9D D9 DA     STA $DAD9,X
C1/C244: B9 42 D0     LDA $D042,Y
C1/C247: 9D DA DA     STA $DADA,X
C1/C24A: 20 66 C2     JSR $C266
C1/C24D: 9D DC DA     STA $DADC,X
C1/C250: A9 3C        LDA #$3C
C1/C252: 9D DD DA     STA $DADD,X
C1/C255: 80 03        BRA $C25A
C1/C257: 9E D8 DA     STZ $DAD8,X
C1/C25A: E6 71        INC $71
C1/C25C: 8A           TXA 
C1/C25D: 18           CLC 
C1/C25E: 69 08        ADC #$08
C1/C260: AA           TAX 
C1/C261: C9 40        CMP #$40
C1/C263: D0 B9        BNE $C21E
C1/C265: 60           RTS 

; [  ]

C1/C266: DA           PHX 
C1/C267: AD 50 DB     LDA $DB50
C1/C26A: 29 40        AND #$40
C1/C26C: D0 0A        BNE $C278
C1/C26E: A5 71        LDA $71
C1/C270: 0A           ASL 
C1/C271: AA           TAX 
C1/C272: BF 8D C2 C1  LDA $C1C28D,X
C1/C276: 80 13        BRA $C28B
C1/C278: 7B           TDC 
C1/C279: AA           TAX 
C1/C27A: BD AA D0     LDA $D0AA,X
C1/C27D: C5 71        CMP $71
C1/C27F: F0 06        BEQ $C287
C1/C281: E8           INX 
C1/C282: E0 08 00     CPX #$0008
C1/C285: D0 F3        BNE $C27A
C1/C287: BF 8D C2 C1  LDA $C1C28D,X
C1/C28B: FA           PLX 
C1/C28C: 60           RTS 

;
C1/C28D:              .DB $03, $06, $09, $0C, $0F, $12, $15, $18, $1B

C1/C296: 9E D9 D5     STZ $D5D9,X
C1/C299: 9E DB D5     STZ $D5DB,X
C1/C29C: 9E DD D5     STZ $D5DD,X
C1/C29F: 9E DF D5     STZ $D5DF,X
C1/C2A2: BD E1 D3     LDA $D3E1,X
C1/C2A5: 30 04        BMI $C2AB
C1/C2A7: A9 08        LDA #$08
C1/C2A9: 80 01        BRA $C2AC
C1/C2AB: 7B           TDC 
C1/C2AC: 85 72        STA $72
C1/C2AE: BD E1 D3     LDA $D3E1,X
C1/C2B1: 29 07        AND #$07
C1/C2B3: 18           CLC 
C1/C2B4: 65 72        ADC $72
C1/C2B6: A8           TAY 
C1/C2B7: 5A           PHY 
C1/C2B8: A0 02 00     LDY #$0002
C1/C2BB: B7 74        LDA [$74],Y
C1/C2BD: 7A           PLY 
C1/C2BE: 29 E0        AND #$E0
C1/C2C0: F0 12        BEQ $C2D4
C1/C2C2: B9 36 D0     LDA $D036,Y
C1/C2C5: 85 A6        STA $A6
C1/C2C7: 9D D8 D5     STA $D5D8,X
C1/C2CA: B9 42 D0     LDA $D042,Y
C1/C2CD: 85 A7        STA $A7
C1/C2CF: 9D DA D5     STA $D5DA,X
C1/C2D2: 80 21        BRA $C2F5
C1/C2D4: BD D9 D3     LDA $D3D9,X
C1/C2D7: 0A           ASL 
C1/C2D8: 0A           ASL 
C1/C2D9: 0A           ASL 
C1/C2DA: 85 72        STA $72
C1/C2DC: B9 66 D0     LDA $D066,Y
C1/C2DF: 85 A6        STA $A6
C1/C2E1: 9D D8 D5     STA $D5D8,X
C1/C2E4: B9 72 D0     LDA $D072,Y
C1/C2E7: 38           SEC 
C1/C2E8: E5 72        SBC $72
C1/C2EA: 85 A7        STA $A7
C1/C2EC: 9D DA D5     STA $D5DA,X
C1/C2EF: 7B           TDC 
C1/C2F0: E9 00        SBC #$00
C1/C2F2: 9D DB D5     STA $D5DB,X
C1/C2F5: BD E2 D3     LDA $D3E2,X
C1/C2F8: 30 04        BMI $C2FE
C1/C2FA: A9 08        LDA #$08
C1/C2FC: 80 01        BRA $C2FF
C1/C2FE: 7B           TDC 
C1/C2FF: 85 72        STA $72
C1/C301: BD E2 D3     LDA $D3E2,X
C1/C304: 29 07        AND #$07
C1/C306: 18           CLC 
C1/C307: 65 72        ADC $72
C1/C309: A8           TAY 
C1/C30A: 5A           PHY 
C1/C30B: A0 02 00     LDY #$0002
C1/C30E: B7 74        LDA [$74],Y
C1/C310: 7A           PLY 
C1/C311: 29 E0        AND #$E0
C1/C313: F0 12        BEQ $C327
C1/C315: B9 36 D0     LDA $D036,Y
C1/C318: 9D DC D5     STA $D5DC,X
C1/C31B: 85 A8        STA $A8
C1/C31D: B9 42 D0     LDA $D042,Y
C1/C320: 9D DE D5     STA $D5DE,X
C1/C323: 85 A9        STA $A9
C1/C325: 80 21        BRA $C348
C1/C327: BD D9 D3     LDA $D3D9,X
C1/C32A: 0A           ASL 
C1/C32B: 0A           ASL 
C1/C32C: 0A           ASL 
C1/C32D: 85 72        STA $72
C1/C32F: B9 66 D0     LDA $D066,Y
C1/C332: 9D DC D5     STA $D5DC,X
C1/C335: 85 A8        STA $A8
C1/C337: B9 72 D0     LDA $D072,Y
C1/C33A: 38           SEC 
C1/C33B: E5 72        SBC $72
C1/C33D: 9D DE D5     STA $D5DE,X
C1/C340: 85 A9        STA $A9
C1/C342: 7B           TDC 
C1/C343: E9 00        SBC #$00
C1/C345: 9D DF D5     STA $D5DF,X
C1/C348: DA           PHX 
C1/C349: 20 6E 0A     JSR $0A6E
C1/C34C: FA           PLX 
C1/C34D: A5 AE        LDA $AE
C1/C34F: 9D E3 D3     STA $D3E3,X
C1/C352: A5 AF        LDA $AF
C1/C354: 9D E4 D3     STA $D3E4,X
C1/C357: A5 B0        LDA $B0
C1/C359: 9D E5 D3     STA $D3E5,X
C1/C35C: 60           RTS 
C1/C35D: 9E E0 D1     STZ $D1E0,X
C1/C360: 9E E2 D1     STZ $D1E2,X
C1/C363: BD E2 D3     LDA $D3E2,X
C1/C366: 30 04        BMI $C36C
C1/C368: A9 08        LDA #$08
C1/C36A: 80 01        BRA $C36D
C1/C36C: 7B           TDC 
C1/C36D: 85 72        STA $72
C1/C36F: BD E2 D3     LDA $D3E2,X
C1/C372: 29 07        AND #$07
C1/C374: 18           CLC 
C1/C375: 65 72        ADC $72
C1/C377: A8           TAY 
C1/C378: 5A           PHY 
C1/C379: A0 02 00     LDY #$0002
C1/C37C: B7 74        LDA [$74],Y
C1/C37E: 7A           PLY 
C1/C37F: 29 E0        AND #$E0
C1/C381: F0 68        BEQ $C3EB
C1/C383: C9 20        CMP #$20
C1/C385: F0 56        BEQ $C3DD
C1/C387: C9 40        CMP #$40
C1/C389: F0 33        BEQ $C3BE
C1/C38B: C9 60        CMP #$60
C1/C38D: F0 10        BEQ $C39F
C1/C38F: C9 80        CMP #$80
C1/C391: F0 00        BEQ $C393
C1/C393: A9 80        LDA #$80
C1/C395: 9D DF D1     STA $D1DF,X
C1/C398: A9 50        LDA #$50
C1/C39A: 9D E1 D1     STA $D1E1,X
C1/C39D: 80 69        BRA $C408
C1/C39F: BD D9 D3     LDA $D3D9,X
C1/C3A2: 0A           ASL 
C1/C3A3: 0A           ASL 
C1/C3A4: 0A           ASL 
C1/C3A5: 85 72        STA $72
C1/C3A7: B9 7E D0     LDA $D07E,Y
C1/C3AA: 9D DF D1     STA $D1DF,X
C1/C3AD: B9 8A D0     LDA $D08A,Y
C1/C3B0: 38           SEC 
C1/C3B1: E5 72        SBC $72
C1/C3B3: 9D E1 D1     STA $D1E1,X
C1/C3B6: 7B           TDC 
C1/C3B7: E9 00        SBC #$00
C1/C3B9: 9D E2 D1     STA $D1E2,X
C1/C3BC: 80 4A        BRA $C408
C1/C3BE: BD D9 D3     LDA $D3D9,X
C1/C3C1: 0A           ASL 
C1/C3C2: 0A           ASL 
C1/C3C3: 0A           ASL 
C1/C3C4: 85 72        STA $72
C1/C3C6: B9 7E D0     LDA $D07E,Y
C1/C3C9: 9D DF D1     STA $D1DF,X
C1/C3CC: B9 8A D0     LDA $D08A,Y
C1/C3CF: 18           CLC 
C1/C3D0: 65 72        ADC $72
C1/C3D2: 9D E1 D1     STA $D1E1,X
C1/C3D5: 7B           TDC 
C1/C3D6: 69 00        ADC #$00
C1/C3D8: 9D E2 D1     STA $D1E2,X
C1/C3DB: 80 2B        BRA $C408
C1/C3DD: B9 36 D0     LDA $D036,Y
C1/C3E0: 9D DF D1     STA $D1DF,X
C1/C3E3: B9 42 D0     LDA $D042,Y
C1/C3E6: 9D E1 D1     STA $D1E1,X
C1/C3E9: 80 1D        BRA $C408
C1/C3EB: BD D9 D3     LDA $D3D9,X
C1/C3EE: 0A           ASL 
C1/C3EF: 0A           ASL 
C1/C3F0: 0A           ASL 
C1/C3F1: 85 72        STA $72
C1/C3F3: B9 66 D0     LDA $D066,Y
C1/C3F6: 9D DF D1     STA $D1DF,X
C1/C3F9: B9 72 D0     LDA $D072,Y
C1/C3FC: 38           SEC 
C1/C3FD: E5 72        SBC $72
C1/C3FF: 9D E1 D1     STA $D1E1,X
C1/C402: 7B           TDC 
C1/C403: E9 00        SBC #$00
C1/C405: 9D E2 D1     STA $D1E2,X
C1/C408: 60           RTS 

; [ execute animation script ]

; A: number of threads
; X: first thread offset (thread id * $10)

C1/C409: 85 76        STA $76
C1/C40B: 64 74        STZ $74
C1/C40D: BD E7 D3     LDA $D3E7,X
C1/C410: D0 03        BNE $C415
C1/C412: 4C CF C4     JMP $C4CF
C1/C415: BD DA D3     LDA $D3DA,X     ; pointer to animation script
C1/C418: 85 70        STA $70
C1/C41A: BD DB D3     LDA $D3DB,X
C1/C41D: 85 71        STA $71
C1/C41F: BD DC D3     LDA $D3DC,X
C1/C422: 85 72        STA $72
C1/C424: A0 02 00     LDY #$0002
C1/C427: B7 70        LDA [$70],Y
C1/C429: 29 1F        AND #$1F
C1/C42B: C2 20        REP #$20
C1/C42D: 0A           ASL 
C1/C42E: 0A           ASL 
C1/C42F: 0A           ASL 
C1/C430: 0A           ASL 
C1/C431: 0A           ASL 
C1/C432: 0A           ASL 
C1/C433: 0A           ASL 
C1/C434: 85 7A        STA $7A         ; animation frame offset
C1/C436: 7B           TDC 
C1/C437: E2 20        SEP #$20
C1/C439: DE DE D3     DEC $D3DE,X     ; decrement frame counter
C1/C43C: F0 03        BEQ $C441
C1/C43E: 4C DC C4     JMP $C4DC
C1/C441: BD DD D3     LDA $D3DD,X     ; animation frame duration
C1/C444: 9D DE D3     STA $D3DE,X
C1/C447: BD DF D3     LDA $D3DF,X     ; animation script offset
C1/C44A: A8           TAY 
C1/C44B: C9 02        CMP #$02
C1/C44D: D0 3B        BNE $C48A
C1/C44F: 5A           PHY 
C1/C450: AC 86 F5     LDY $F586
C1/C453: C0 94 00     CPY #$0094
C1/C456: D0 11        BNE $C469
C1/C458: 20 3B 8D     JSR $8D3B
C1/C45B: D0 04        BNE $C461
C1/C45D: A9 49        LDA #$49
C1/C45F: 80 03        BRA $C464
C1/C461: AD 83 F5     LDA $F583       ; animation sound effect
C1/C464: 20 E4 FB     JSR $FBE4       ; play animation sound effect
C1/C467: 80 1F        BRA $C488
C1/C469: AD DF DB     LDA $DBDF
C1/C46C: F0 04        BEQ $C472
C1/C46E: A9 88        LDA #$88
C1/C470: 80 0D        BRA $C47F
C1/C472: AD 50 DB     LDA $DB50
C1/C475: 29 40        AND #$40
C1/C477: F0 04        BEQ $C47D
C1/C479: A9 33        LDA #$33
C1/C47B: 80 02        BRA $C47F
C1/C47D: A9 DD        LDA #$DD
C1/C47F: 8D B6 DB     STA $DBB6
C1/C482: AD 83 F5     LDA $F583
C1/C485: 20 D9 FB     JSR $FBD9       ; play sound effect
C1/C488: 7A           PLY 
C1/C489: C8           INY 
C1/C48A: B7 70        LDA [$70],Y
C1/C48C: C9 FF        CMP #$FF
C1/C48E: F0 28        BEQ $C4B8       ; branch if end of script
C1/C490: B7 70        LDA [$70],Y
C1/C492: 30 1E        BMI $C4B2
C1/C494: 18           CLC 
C1/C495: 7D DE D7     ADC $D7DE,X
C1/C498: C2 20        REP #$20
C1/C49A: 18           CLC 
C1/C49B: 65 7A        ADC $7A         ; add frame offset
C1/C49D: 9D DA D1     STA $D1DA,X
C1/C4A0: 7B           TDC 
C1/C4A1: E2 20        SEP #$20
C1/C4A3: C8           INY 
C1/C4A4: A9 01        LDA #$01
C1/C4A6: 9D D8 D1     STA $D1D8,X     ; animation needs update ???
C1/C4A9: 98           TYA 
C1/C4AA: 9D DF D3     STA $D3DF,X     ; save animation script offset
C1/C4AD: 9C 5F DB     STZ $DB5F
C1/C4B0: 80 2A        BRA $C4DC
C1/C4B2: 20 FD C4     JSR $C4FD       ; execute animation command
C1/C4B5: C8           INY 
C1/C4B6: 80 D2        BRA $C48A
C1/C4B8: 98           TYA 
C1/C4B9: 9D DF D3     STA $D3DF,X
C1/C4BC: BD E0 D3     LDA $D3E0,X
C1/C4BF: F0 0E        BEQ $C4CF
C1/C4C1: DE E0 D3     DEC $D3E0,X
C1/C4C4: F0 09        BEQ $C4CF
C1/C4C6: A9 03        LDA #$03
C1/C4C8: A8           TAY 
C1/C4C9: 9D DF D3     STA $D3DF,X
C1/C4CC: 4C 8A C4     JMP $C48A
C1/C4CF: A9 01        LDA #$01
C1/C4D1: 9D DE D3     STA $D3DE,X
C1/C4D4: 9E D8 D1     STZ $D1D8,X
C1/C4D7: 9E E7 D3     STZ $D3E7,X
C1/C4DA: E6 74        INC $74
C1/C4DC: C2 20        REP #$20
C1/C4DE: 8A           TXA 
C1/C4DF: 18           CLC 
C1/C4E0: 69 10 00     ADC #$0010
C1/C4E3: AA           TAX 
C1/C4E4: 7B           TDC 
C1/C4E5: E2 20        SEP #$20
C1/C4E7: C6 76        DEC $76
C1/C4E9: F0 03        BEQ $C4EE
C1/C4EB: 4C 0D C4     JMP $C40D
C1/C4EE: AD A4 DB     LDA $DBA4
C1/C4F1: F0 09        BEQ $C4FC
C1/C4F3: 20 65 1D     JSR $1D65
C1/C4F6: EE 42 DB     INC $DB42
C1/C4F9: 9C A4 DB     STZ $DBA4
C1/C4FC: 60           RTS 

; [ execute animation command ]

C1/C4FD: 29 7F        AND #$7F
C1/C4FF: 0A           ASL 
C1/C500: DA           PHX 
C1/C501: AA           TAX 
C1/C502: BF 12 C5 C1  LDA $C1C512,X
C1/C506: 85 80        STA $80
C1/C508: BF 13 C5 C1  LDA $C1C513,X
C1/C50C: 85 81        STA $81
C1/C50E: FA           PLX 
C1/C50F: 6C 80 00     JMP ($0080)

; animation command jump table (commands $80-$FE)
C1/C512:              .DW $DF24, $DEB3, $DEB9, $DC04, $DEBF, $DEC5, $DECB, $E64F ; $80
C1/C522:              .DW $E76A, $E774, $E77B, $E791, $DA13, $E80F, $E635, $E80F
C1/C532:              .DW $E2AA, $E27B, $E30A, $E59A, $E425, $E46A, $E2DB, $E5CF ; $90
C1/C542:              .DW $E612, $E61D, $E09C, $E108, $E0FF, $E1CB, $E0FF, $E145
C1/C552:              .DW $E326, $E51B, $FC64, $FC6D, $E096, $E3EC, $E086, $E3A4 ; $A0
C1/C562:              .DW $E4DE, $E058, $E022, $DFE0, $E203, $E184, $DE8D, $DE62
C1/C572:              .DW $DE08, $DD98, $DDB4, $DDD0, $DDEC, $DE3B, $DD48, $DD72 ; $B0
C1/C582:              .DW $DCDF, $DD15, $DCA7, $DC74, $D2D0, $DC4D, $DC3B, $E372
C1/C592:              .DW $DBF0, $DBD6, $DBE3, $DBA9, $D2D0, $DB9C, $E340, $E551 ; $C0
C1/C5A2:              .DW $DB7D, $DB8D, $DB54, $DB67, $DB2B, $DAE4, $DA59, $DAC2
C1/C5B2:              .DW $DA2C, $DA04, $D9ED, $D9B5, $D99A, $D990, $D903, $D8BF ; $D0
C1/C5C2:              .DW $D8D1, $D895, $D83B, $D7E6, $D7D0, $D7AD, $D789, $D777
C1/C5D2:              .DW $D780, $D742, $D723, $D6F3, $D6C1, $D665, $D62B, $D610 ; $E0
C1/C5E2:              .DW $D589, $D5B1, $D536, $D4F1, $D4D0, $D476, $D41D, $D3E2
C1/C5F2:              .DW $D34A, $D2D0, $D281, $D272, $D5E9, $D1B9, $D1CF, $DF9E ; $F0
C1/C602:              .DW $C75B, $C740, $C6E3, $C625, $C616, $C610, $B745

; [  ]

C1/C610: C8           INY 
C1/C611: B7 70        LDA [$70],Y
C1/C613: 4C D9 FB     JMP $FBD9       ; play sound effect
C1/C616: DA           PHX 
C1/C617: BD E2 D3     LDA $D3E2,X
C1/C61A: 29 03        AND #$03
C1/C61C: AA           TAX 
C1/C61D: C8           INY 
C1/C61E: B7 70        LDA [$70],Y
C1/C620: 9D CB D1     STA $D1CB,X
C1/C623: FA           PLX 
C1/C624: 60           RTS 
C1/C625: DA           PHX 
C1/C626: BD E2 D3     LDA $D3E2,X
C1/C629: 29 03        AND #$03
C1/C62B: 0A           ASL 
C1/C62C: 0A           ASL 
C1/C62D: 0A           ASL 
C1/C62E: 0A           ASL 
C1/C62F: 0A           ASL 
C1/C630: AA           TAX 
C1/C631: C8           INY 
C1/C632: B7 70        LDA [$70],Y
C1/C634: 85 7E        STA $7E
C1/C636: 64 7F        STZ $7F
C1/C638: C8           INY 
C1/C639: B7 70        LDA [$70],Y
C1/C63B: F0 54        BEQ $C691
C1/C63D: C9 01        CMP #$01
C1/C63F: F0 40        BEQ $C681
C1/C641: C9 02        CMP #$02
C1/C643: F0 2C        BEQ $C671
C1/C645: C9 03        CMP #$03
C1/C647: F0 18        BEQ $C661
C1/C649: C9 04        CMP #$04
C1/C64B: F0 0A        BEQ $C657
C1/C64D: BD 62 CF     LDA $CF62,X
C1/C650: 29 7F        AND #$7F
C1/C652: 9D 62 CF     STA $CF62,X
C1/C655: FA           PLX 
C1/C656: 60           RTS 
C1/C657: BD 62 CF     LDA $CF62,X
C1/C65A: 09 80        ORA #$80
C1/C65C: 9D 62 CF     STA $CF62,X
C1/C65F: FA           PLX 
C1/C660: 60           RTS 
C1/C661: C2 20        REP #$20
C1/C663: BD 5D CF     LDA $CF5D,X
C1/C666: 38           SEC 
C1/C667: E5 7E        SBC $7E
C1/C669: 9D 5D CF     STA $CF5D,X
C1/C66C: 7B           TDC 
C1/C66D: E2 20        SEP #$20
C1/C66F: FA           PLX 
C1/C670: 60           RTS 
C1/C671: C2 20        REP #$20
C1/C673: BD 5D CF     LDA $CF5D,X
C1/C676: 18           CLC 
C1/C677: 65 7E        ADC $7E
C1/C679: 9D 5D CF     STA $CF5D,X
C1/C67C: 7B           TDC 
C1/C67D: E2 20        SEP #$20
C1/C67F: FA           PLX 
C1/C680: 60           RTS 
C1/C681: C2 20        REP #$20
C1/C683: BD 5F CF     LDA $CF5F,X
C1/C686: 38           SEC 
C1/C687: E5 7E        SBC $7E
C1/C689: 9D 5F CF     STA $CF5F,X
C1/C68C: 7B           TDC 
C1/C68D: E2 20        SEP #$20
C1/C68F: FA           PLX 
C1/C690: 60           RTS 
C1/C691: C2 20        REP #$20
C1/C693: BD 5F CF     LDA $CF5F,X
C1/C696: 18           CLC 
C1/C697: 65 7E        ADC $7E
C1/C699: 9D 5F CF     STA $CF5F,X
C1/C69C: 7B           TDC 
C1/C69D: E2 20        SEP #$20
C1/C69F: FA           PLX 
C1/C6A0: 60           RTS 
C1/C6A1: C2 20        REP #$20
C1/C6A3: AD 77 BC     LDA $BC77
C1/C6A6: 9D DF D7     STA $D7DF,X
C1/C6A9: AD 79 BC     LDA $BC79
C1/C6AC: 9D E1 D7     STA $D7E1,X
C1/C6AF: BD D8 D5     LDA $D5D8,X
C1/C6B2: 38           SEC 
C1/C6B3: FD DC D5     SBC $D5DC,X
C1/C6B6: 8D 77 BC     STA $BC77
C1/C6B9: BD DA D5     LDA $D5DA,X
C1/C6BC: 38           SEC 
C1/C6BD: FD DE D5     SBC $D5DE,X
C1/C6C0: 18           CLC 
C1/C6C1: 69 C0 00     ADC #$00C0
C1/C6C4: 8D 79 BC     STA $BC79
C1/C6C7: 7B           TDC 
C1/C6C8: E2 20        SEP #$20
C1/C6CA: EE 9A BC     INC $BC9A
C1/C6CD: 60           RTS 
C1/C6CE: C2 20        REP #$20
C1/C6D0: BD DF D7     LDA $D7DF,X
C1/C6D3: 8D 77 BC     STA $BC77
C1/C6D6: BD E1 D7     LDA $D7E1,X
C1/C6D9: 8D 79 BC     STA $BC79
C1/C6DC: 7B           TDC 
C1/C6DD: E2 20        SEP #$20
C1/C6DF: 9C 9A BC     STZ $BC9A
C1/C6E2: 60           RTS 
C1/C6E3: C8           INY 
C1/C6E4: B7 70        LDA [$70],Y
C1/C6E6: F0 44        BEQ $C72C
C1/C6E8: C9 01        CMP #$01
C1/C6EA: F0 2C        BEQ $C718
C1/C6EC: C9 02        CMP #$02
C1/C6EE: F0 14        BEQ $C704
C1/C6F0: C8           INY 
C1/C6F1: B7 70        LDA [$70],Y
C1/C6F3: C2 20        REP #$20
C1/C6F5: 85 7E        STA $7E
C1/C6F7: AD 77 BC     LDA $BC77
C1/C6FA: 38           SEC 
C1/C6FB: E5 7E        SBC $7E
C1/C6FD: 8D 77 BC     STA $BC77
C1/C700: 7B           TDC 
C1/C701: E2 20        SEP #$20
C1/C703: 60           RTS 
C1/C704: C8           INY 
C1/C705: B7 70        LDA [$70],Y
C1/C707: C2 20        REP #$20
C1/C709: 85 7E        STA $7E
C1/C70B: AD 77 BC     LDA $BC77
C1/C70E: 18           CLC 
C1/C70F: 65 7E        ADC $7E
C1/C711: 8D 77 BC     STA $BC77
C1/C714: 7B           TDC 
C1/C715: E2 20        SEP #$20
C1/C717: 60           RTS 
C1/C718: C8           INY 
C1/C719: B7 70        LDA [$70],Y
C1/C71B: C2 20        REP #$20
C1/C71D: 85 7E        STA $7E
C1/C71F: AD 79 BC     LDA $BC79
C1/C722: 38           SEC 
C1/C723: E5 7E        SBC $7E
C1/C725: 8D 79 BC     STA $BC79
C1/C728: 7B           TDC 
C1/C729: E2 20        SEP #$20
C1/C72B: 60           RTS 
C1/C72C: C8           INY 
C1/C72D: B7 70        LDA [$70],Y
C1/C72F: C2 20        REP #$20
C1/C731: 85 7E        STA $7E
C1/C733: AD 79 BC     LDA $BC79
C1/C736: 18           CLC 
C1/C737: 65 7E        ADC $7E
C1/C739: 8D 79 BC     STA $BC79
C1/C73C: 7B           TDC 
C1/C73D: E2 20        SEP #$20
C1/C73F: 60           RTS 

; [  ]

C1/C740: C8           INY 
C1/C741: B7 70        LDA [$70],Y
C1/C743: 09 58        ORA #$58
C1/C745: 8F 07 21 00  STA $002107
C1/C749: 60           RTS 

C1/C74A: AD 50 DB     LDA $DB50
C1/C74D: 29 40        AND #$40
C1/C74F: F0 09        BEQ $C75A
C1/C751: B7 70        LDA [$70],Y
C1/C753: C9 FF        CMP #$FF
C1/C755: F0 03        BEQ $C75A
C1/C757: C8           INY 
C1/C758: 80 F7        BRA $C751
C1/C75A: 60           RTS 
C1/C75B: AD 53 DB     LDA $DB53
C1/C75E: D0 0A        BNE $C76A
C1/C760: B7 70        LDA [$70],Y
C1/C762: C9 FE        CMP #$FE
C1/C764: F0 03        BEQ $C769
C1/C766: C8           INY 
C1/C767: 80 F7        BRA $C760
C1/C769: 88           DEY 
C1/C76A: 60           RTS 
C1/C76B: FC E0 ED     JSR ($EDE0,X)
C1/C76E: D1 95        CMP ($95),Y
C1/C770: D1 A7        CMP ($A7),Y
C1/C772: D1 A4        CMP ($A4),Y
C1/C774: CA           DEX 
C1/C775: D0 D2        BNE $C749
C1/C777: 9B           TXY 
C1/C778: CA           DEX 
C1/C779: 55 CA        EOR $CA,X
C1/C77B: FD C9 0A     SBC $0AC9,X
C1/C77E: CA           DEX 
C1/C77F: F4 C9 DC     PEA $DCC9
C1/C782: C9 B9        CMP #$B9
C1/C784: C9 A3        CMP #$A3
C1/C786: C9 A0        CMP #$A0
C1/C788: C9 97        CMP #$97
C1/C78A: C9 8B        CMP #$8B
C1/C78C: C9 84        CMP #$84
C1/C78E: C9 59        CMP #$59
C1/C790: C9 3D        CMP #$3D
C1/C792: C8           INY 
C1/C793: 07 C9        ORA [$C9]
C1/C795: D3 C8        CMP ($C8,S),Y
C1/C797: 91 C8        STA ($C8),Y
C1/C799: 67 C8        ADC [$C8]
C1/C79B: 30 C8        BMI $C765
C1/C79D: F8           SED 
C1/C79E: C7 E8        CMP [$E8]
C1/C7A0: C7 C1        CMP [$C1]
C1/C7A2: C7 B5        CMP [$B5]
C1/C7A4: C7 A1        CMP [$A1]
C1/C7A6: C6 CE        DEC $CE
C1/C7A8: C6 78        DEC $78
C1/C7AA: DE AF C7     DEC $C7AF,X
C1/C7AD: BC DC A9     LDY $A9DC,X
C1/C7B0: FF 8D F2 04  SBC $04F28D,X
C1/C7B4: 60           RTS 
C1/C7B5: A9 07        LDA #$07
C1/C7B7: 8D EC DB     STA $DBEC
C1/C7BA: EE EB DB     INC $DBEB
C1/C7BD: 9C 56 EE     STZ $EE56
C1/C7C0: 60           RTS 
C1/C7C1: DA           PHX 
C1/C7C2: 8A           TXA 
C1/C7C3: D0 09        BNE $C7CE
C1/C7C5: 9C D1 DB     STZ $DBD1
C1/C7C8: 9C D2 DB     STZ $DBD2
C1/C7CB: EE D0 DB     INC $DBD0
C1/C7CE: C2 20        REP #$20
C1/C7D0: 8A           TXA 
C1/C7D1: 4A           LSR 
C1/C7D2: 4A           LSR 
C1/C7D3: 4A           LSR 
C1/C7D4: 4A           LSR 
C1/C7D5: AA           TAX 
C1/C7D6: 7B           TDC 
C1/C7D7: E2 20        SEP #$20
C1/C7D9: 20 96 FC     JSR $FC96       ; generate random number
C1/C7DC: 29 07        AND #$07
C1/C7DE: 18           CLC 
C1/C7DF: 69 04        ADC #$04
C1/C7E1: 9D FB CE     STA $CEFB,X
C1/C7E4: FA           PLX 
C1/C7E5: 4C 81 CC     JMP $CC81
C1/C7E8: C8           INY 
C1/C7E9: B7 70        LDA [$70],Y
C1/C7EB: 85 7E        STA $7E
C1/C7ED: BD E2 D3     LDA $D3E2,X
C1/C7F0: 10 05        BPL $C7F7
C1/C7F2: A5 7E        LDA $7E
C1/C7F4: 9D DE D7     STA $D7DE,X
C1/C7F7: 60           RTS 
C1/C7F8: DA           PHX 
C1/C7F9: 5A           PHY 
C1/C7FA: C2 20        REP #$20
C1/C7FC: 7B           TDC 
C1/C7FD: A8           TAY 
C1/C7FE: B9 70 00     LDA $0070,Y
C1/C801: 48           PHA 
C1/C802: C8           INY 
C1/C803: C8           INY 
C1/C804: C0 0C 00     CPY #$000C
C1/C807: D0 F5        BNE $C7FE
C1/C809: 7B           TDC 
C1/C80A: E2 20        SEP #$20
C1/C80C: BD E1 D3     LDA $D3E1,X
C1/C80F: 29 07        AND #$07
C1/C811: AA           TAX 
C1/C812: BD 9C DB     LDA $DB9C,X
C1/C815: 49 03        EOR #$03
C1/C817: 9D 9C DB     STA $DB9C,X
C1/C81A: 20 B8 1C     JSR $1CB8
C1/C81D: C2 20        REP #$20
C1/C81F: A0 0C 00     LDY #$000C
C1/C822: 68           PLA 
C1/C823: 99 6E 00     STA $006E,Y
C1/C826: 88           DEY 
C1/C827: 88           DEY 
C1/C828: D0 F8        BNE $C822
C1/C82A: 7B           TDC 
C1/C82B: E2 20        SEP #$20
C1/C82D: 7A           PLY 
C1/C82E: FA           PLX 
C1/C82F: 60           RTS 
C1/C830: 8A           TXA 
C1/C831: F0 09        BEQ $C83C
C1/C833: BD DF D1     LDA $D1DF,X
C1/C836: 18           CLC 
C1/C837: 69 50        ADC #$50
C1/C839: 9D DF D1     STA $D1DF,X
C1/C83C: 60           RTS 
C1/C83D: DA           PHX 
C1/C83E: 86 7E        STX $7E
C1/C840: 8A           TXA 
C1/C841: 4A           LSR 
C1/C842: 4A           LSR 
C1/C843: 4A           LSR 
C1/C844: 29 FE        AND #$FE
C1/C846: AA           TAX 
C1/C847: BF 7D D8 C1  LDA $C1D87D,X
C1/C84B: 85 80        STA $80
C1/C84D: BF 7E D8 C1  LDA $C1D87E,X
C1/C851: 85 81        STA $81
C1/C853: A6 7E        LDX $7E
C1/C855: A5 80        LDA $80
C1/C857: 9D DF D1     STA $D1DF,X
C1/C85A: 9E E0 D1     STZ $D1E0,X
C1/C85D: A5 81        LDA $81
C1/C85F: 9D E1 D1     STA $D1E1,X
C1/C862: 9E E2 D1     STZ $D1E2,X
C1/C865: FA           PLX 
C1/C866: 60           RTS 
C1/C867: DA           PHX 
C1/C868: 86 7E        STX $7E
C1/C86A: 8A           TXA 
C1/C86B: 4A           LSR 
C1/C86C: 4A           LSR 
C1/C86D: 4A           LSR 
C1/C86E: 29 FE        AND #$FE
C1/C870: AA           TAX 
C1/C871: BF 85 D8 C1  LDA $C1D885,X
C1/C875: 85 80        STA $80
C1/C877: BF 86 D8 C1  LDA $C1D886,X
C1/C87B: 85 81        STA $81
C1/C87D: A6 7E        LDX $7E
C1/C87F: A5 80        LDA $80
C1/C881: 9D DF D1     STA $D1DF,X
C1/C884: 9E E0 D1     STZ $D1E0,X
C1/C887: A5 81        LDA $81
C1/C889: 9D E1 D1     STA $D1E1,X
C1/C88C: 9E E2 D1     STZ $D1E2,X
C1/C88F: FA           PLX 
C1/C890: 60           RTS 
C1/C891: BD DF D1     LDA $D1DF,X
C1/C894: 9D D8 D5     STA $D5D8,X
C1/C897: 85 A6        STA $A6
C1/C899: BD E1 D1     LDA $D1E1,X
C1/C89C: 9D DA D5     STA $D5DA,X
C1/C89F: 85 A7        STA $A7
C1/C8A1: BD DC D5     LDA $D5DC,X
C1/C8A4: 85 A8        STA $A8
C1/C8A6: BD DE D5     LDA $D5DE,X
C1/C8A9: 85 A9        STA $A9
C1/C8AB: DA           PHX 
C1/C8AC: 20 6E 0A     JSR $0A6E
C1/C8AF: FA           PLX 
C1/C8B0: A5 AE        LDA $AE
C1/C8B2: 9D E3 D3     STA $D3E3,X
C1/C8B5: A5 AF        LDA $AF
C1/C8B7: 9D E4 D3     STA $D3E4,X
C1/C8BA: A5 B0        LDA $B0
C1/C8BC: 9D E5 D3     STA $D3E5,X
C1/C8BF: C2 20        REP #$20
C1/C8C1: BD DF D1     LDA $D1DF,X
C1/C8C4: 9D DC D5     STA $D5DC,X
C1/C8C7: BD E1 D1     LDA $D1E1,X
C1/C8CA: 9D DE D5     STA $D5DE,X
C1/C8CD: 7B           TDC 
C1/C8CE: E2 20        SEP #$20
C1/C8D0: 4C 3B E2     JMP $E23B
C1/C8D3: BD DA D5     LDA $D5DA,X
C1/C8D6: 18           CLC 
C1/C8D7: 69 03        ADC #$03
C1/C8D9: 9D DA D5     STA $D5DA,X
C1/C8DC: 85 A7        STA $A7
C1/C8DE: BD D8 D5     LDA $D5D8,X
C1/C8E1: 18           CLC 
C1/C8E2: 69 28        ADC #$28
C1/C8E4: 9D D8 D5     STA $D5D8,X
C1/C8E7: 85 A6        STA $A6
C1/C8E9: 18           CLC 
C1/C8EA: 69 10        ADC #$10
C1/C8EC: 85 A8        STA $A8
C1/C8EE: BD DE D5     LDA $D5DE,X
C1/C8F1: 85 A9        STA $A9
C1/C8F3: C2 20        REP #$20
C1/C8F5: BD D8 D5     LDA $D5D8,X
C1/C8F8: 9D DC D5     STA $D5DC,X
C1/C8FB: BD DA D5     LDA $D5DA,X
C1/C8FE: 9D DE D5     STA $D5DE,X
C1/C901: 7B           TDC 
C1/C902: E2 20        SEP #$20
C1/C904: 4C 6C E0     JMP $E06C
C1/C907: BD D8 D5     LDA $D5D8,X
C1/C90A: 85 A6        STA $A6
C1/C90C: 9E D9 D5     STZ $D5D9,X
C1/C90F: BD DA D5     LDA $D5DA,X
C1/C912: 85 A7        STA $A7
C1/C914: 9E DB D5     STZ $D5DB,X
C1/C917: BD E2 D3     LDA $D3E2,X
C1/C91A: 10 03        BPL $C91F
C1/C91C: 7B           TDC 
C1/C91D: 80 02        BRA $C921
C1/C91F: A9 FF        LDA #$FF
C1/C921: 9D DF D1     STA $D1DF,X
C1/C924: 85 A8        STA $A8
C1/C926: 9E E0 D1     STZ $D1E0,X
C1/C929: 20 96 FC     JSR $FC96       ; generate random number
C1/C92C: 29 7F        AND #$7F
C1/C92E: 18           CLC 
C1/C92F: 69 18        ADC #$18
C1/C931: 9D E1 D1     STA $D1E1,X
C1/C934: 85 A9        STA $A9
C1/C936: 9E E2 D1     STZ $D1E2,X
C1/C939: 9E DC D1     STZ $D1DC,X
C1/C93C: 9E DD D1     STZ $D1DD,X
C1/C93F: DA           PHX 
C1/C940: 20 6E 0A     JSR $0A6E
C1/C943: FA           PLX 
C1/C944: A5 AE        LDA $AE
C1/C946: 9D E3 D3     STA $D3E3,X
C1/C949: A5 AF        LDA $AF
C1/C94B: 9D E4 D3     STA $D3E4,X
C1/C94E: A5 B0        LDA $B0
C1/C950: 9D E5 D3     STA $D3E5,X
C1/C953: A9 02        LDA #$02
C1/C955: 9D E6 D3     STA $D3E6,X
C1/C958: 60           RTS 
C1/C959: DA           PHX 
C1/C95A: 20 18 DB     JSR $DB18
C1/C95D: DA           PHX 
C1/C95E: A6 78        LDX $78
C1/C960: E0 00 01     CPX #$0100
C1/C963: 90 04        BCC $C969
C1/C965: A9 80        LDA #$80
C1/C967: 80 01        BRA $C96A
C1/C969: 7B           TDC 
C1/C96A: FA           PLX 
C1/C96B: 9D 7B CE     STA $CE7B,X
C1/C96E: 18           CLC 
C1/C96F: 69 40        ADC #$40
C1/C971: 9D BB CE     STA $CEBB,X
C1/C974: A9 18        LDA #$18
C1/C976: 9D FB CD     STA $CDFB,X
C1/C979: 9D 3B CE     STA $CE3B,X
C1/C97C: A9 10        LDA #$10
C1/C97E: 9D FB CE     STA $CEFB,X
C1/C981: 4C C0 E3     JMP $E3C0
C1/C984: 8A           TXA 
C1/C985: D0 03        BNE $C98A
C1/C987: 4C E2 D4     JMP $D4E2
C1/C98A: 60           RTS 
C1/C98B: C2 20        REP #$20
C1/C98D: A9 50 00     LDA #$0050
C1/C990: 8D 64 DB     STA $DB64
C1/C993: 7B           TDC 
C1/C994: E2 20        SEP #$20
C1/C996: 60           RTS 
C1/C997: 20 E6 D7     JSR $D7E6
C1/C99A: A9 10        LDA #$10
C1/C99C: 9D DF D1     STA $D1DF,X
C1/C99F: 60           RTS 
C1/C9A0: 4C FF E0     JMP $E0FF
C1/C9A3: DA           PHX 
C1/C9A4: 20 FF E0     JSR $E0FF
C1/C9A7: 8A           TXA 
C1/C9A8: 4A           LSR 
C1/C9A9: 4A           LSR 
C1/C9AA: 4A           LSR 
C1/C9AB: 4A           LSR 
C1/C9AC: AA           TAX 
C1/C9AD: A9 30        LDA #$30
C1/C9AF: 9D 0B CE     STA $CE0B,X
C1/C9B2: 9D 4B CE     STA $CE4B,X
C1/C9B5: FA           PLX 
C1/C9B6: 4C 2F CF     JMP $CF2F
C1/C9B9: 20 C9 CF     JSR $CFC9
C1/C9BC: 4C FF E0     JMP $E0FF
C1/C9BF: BD DF D7     LDA $D7DF,X
C1/C9C2: 85 7E        STA $7E
C1/C9C4: A9 10        LDA #$10
C1/C9C6: 85 80        STA $80
C1/C9C8: DA           PHX 
C1/C9C9: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/C9CC: FA           PLX 
C1/C9CD: BD E1 D5     LDA $D5E1,X
C1/C9D0: 18           CLC 
C1/C9D1: 69 06        ADC #$06
C1/C9D3: 9D E1 D5     STA $D5E1,X
C1/C9D6: 29 0F        AND #$0F
C1/C9D8: 18           CLC 
C1/C9D9: 65 82        ADC $82
C1/C9DB: 60           RTS 
C1/C9DC: 20 96 FC     JSR $FC96       ; generate random number
C1/C9DF: 9D E1 D5     STA $D5E1,X
C1/C9E2: 20 BF C9     JSR $C9BF
C1/C9E5: 9D E6 D3     STA $D3E6,X
C1/C9E8: BD E3 D3     LDA $D3E3,X
C1/C9EB: 9D E1 D7     STA $D7E1,X
C1/C9EE: 20 EC CF     JSR $CFEC
C1/C9F1: 4C FF E0     JMP $E0FF
C1/C9F4: 20 FD C9     JSR $C9FD
C1/C9F7: A9 08        LDA #$08
C1/C9F9: 9D E6 D3     STA $D3E6,X
C1/C9FC: 60           RTS 
C1/C9FD: 20 81 CA     JSR $CA81
C1/CA00: FE E1 D7     INC $D7E1,X
C1/CA03: BD E3 D3     LDA $D3E3,X
C1/CA06: 9D E2 D7     STA $D7E2,X
C1/CA09: 60           RTS 
C1/CA0A: A9 06        LDA #$06
C1/CA0C: 8D B2 F8     STA $F8B2
C1/CA0F: C2 20        REP #$20
C1/CA11: BD DF D1     LDA $D1DF,X
C1/CA14: 9D DC D5     STA $D5DC,X
C1/CA17: 8D EC D5     STA $D5EC
C1/CA1A: 8D FC D5     STA $D5FC
C1/CA1D: 8D 0C D6     STA $D60C
C1/CA20: 8D 1C D6     STA $D61C
C1/CA23: 8D 2C D6     STA $D62C
C1/CA26: 8D 3C D6     STA $D63C
C1/CA29: 8D 4C D6     STA $D64C
C1/CA2C: BD E1 D1     LDA $D1E1,X
C1/CA2F: 9D DE D5     STA $D5DE,X
C1/CA32: 8D EE D5     STA $D5EE
C1/CA35: 8D FE D5     STA $D5FE
C1/CA38: 8D 0E D6     STA $D60E
C1/CA3B: 8D 1E D6     STA $D61E
C1/CA3E: 8D 2E D6     STA $D62E
C1/CA41: 8D 3E D6     STA $D63E
C1/CA44: 8D 4E D6     STA $D64E
C1/CA47: 7B           TDC 
C1/CA48: E2 20        SEP #$20
C1/CA4A: A9 20        LDA #$20
C1/CA4C: 20 66 CA     JSR $CA66
C1/CA4F: A9 08        LDA #$08
C1/CA51: 9D E6 D3     STA $D3E6,X
C1/CA54: 60           RTS 
C1/CA55: A9 10        LDA #$10
C1/CA57: 8D B2 F8     STA $F8B2
C1/CA5A: 20 96 FC     JSR $FC96       ; generate random number
C1/CA5D: 29 0F        AND #$0F
C1/CA5F: 38           SEC 
C1/CA60: E9 88        SBC #$88
C1/CA62: 18           CLC 
C1/CA63: 7D E3 D3     ADC $D3E3,X
C1/CA66: 9D E3 D3     STA $D3E3,X
C1/CA69: 9D E2 D7     STA $D7E2,X
C1/CA6C: 8D F3 D3     STA $D3F3
C1/CA6F: 8D 03 D4     STA $D403
C1/CA72: 8D 13 D4     STA $D413
C1/CA75: 8D 23 D4     STA $D423
C1/CA78: 8D 33 D4     STA $D433
C1/CA7B: 8D 43 D4     STA $D443
C1/CA7E: 8D 53 D4     STA $D453
C1/CA81: A9 08        LDA #$08
C1/CA83: 9D E6 D3     STA $D3E6,X
C1/CA86: C2 20        REP #$20
C1/CA88: BD D8 D5     LDA $D5D8,X
C1/CA8B: 9D DF D1     STA $D1DF,X
C1/CA8E: BD DA D5     LDA $D5DA,X
C1/CA91: 9D E1 D1     STA $D1E1,X
C1/CA94: 7B           TDC 
C1/CA95: E2 20        SEP #$20
C1/CA97: 9E E1 D7     STZ $D7E1,X
C1/CA9A: 60           RTS 
C1/CA9B: 20 96 FC     JSR $FC96       ; generate random number
C1/CA9E: 29 0F        AND #$0F
C1/CAA0: 8D E4 D5     STA $D5E4
C1/CAA3: 60           RTS 
C1/CAA4: DA           PHX 
C1/CAA5: 20 DB CA     JSR $CADB
C1/CAA8: E0 10 00     CPX #$0010
C1/CAAB: 90 15        BCC $CAC2
C1/CAAD: A9 40        LDA #$40
C1/CAAF: 9D FB CD     STA $CDFB,X
C1/CAB2: 9E 3B CE     STZ $CE3B,X
C1/CAB5: A9 01        LDA #$01
C1/CAB7: 9D 1B CE     STA $CE1B,X
C1/CABA: 9D 5B CE     STA $CE5B,X
C1/CABD: A9 F0        LDA #$F0
C1/CABF: 4C D4 CA     JMP $CAD4
C1/CAC2: A9 58        LDA #$58
C1/CAC4: 9D FB CD     STA $CDFB,X
C1/CAC7: A9 20        LDA #$20
C1/CAC9: 9D 3B CE     STA $CE3B,X
C1/CACC: 9E 1B CE     STZ $CE1B,X
C1/CACF: 9E 5B CE     STZ $CE5B,X
C1/CAD2: A9 10        LDA #$10
C1/CAD4: 9D FB CE     STA $CEFB,X
C1/CAD7: FA           PLX 
C1/CAD8: 4C 5A D1     JMP $D15A
C1/CADB: C2 20        REP #$20
C1/CADD: 86 78        STX $78
C1/CADF: 8A           TXA 
C1/CAE0: 4A           LSR 
C1/CAE1: 4A           LSR 
C1/CAE2: 4A           LSR 
C1/CAE3: 4A           LSR 
C1/CAE4: AA           TAX 
C1/CAE5: 86 84        STX $84
C1/CAE7: 7B           TDC 
C1/CAE8: E2 20        SEP #$20
C1/CAEA: 60           RTS 
C1/CAEB: A6 84        LDX $84
C1/CAED: 20 CA 09     JSR $09CA
C1/CAF0: 85 86        STA $86
C1/CAF2: A6 84        LDX $84
C1/CAF4: 20 E5 09     JSR $09E5
C1/CAF7: 85 87        STA $87
C1/CAF9: A6 78        LDX $78
C1/CAFB: A5 86        LDA $86
C1/CAFD: 9D DC D1     STA $D1DC,X
C1/CB00: A5 87        LDA $87
C1/CB02: 9D DD D1     STA $D1DD,X
C1/CB05: 60           RTS 

C1/CB06: D217 D15A D2D0 D147 D0D5 D0C3 D0BF D02A
C1/CB16: D01D CFD9 CF56 CF07 CEF6 CEDA DBF7 C74A
C1/CB26: D2D0 CEB9 CDE9 CD92 CD53 CD34 CCFD CCF6
C1/CB36: CCE2 CB88 CB6A CB62 CB5A CB56 CB4F CB46

; [ flash screen (if not already flashing) ]

C1/CB46: AD C7 F8     LDA $F8C7
C1/CB49: D0 03        BNE $CB4E
C1/CB4B: 20 F5 78     JSR $78F5       ; flash screen
C1/CB4E: 60           RTS 

; [  ]

C1/CB4F: C8           INY 
C1/CB50: B7 70        LDA [$70],Y
C1/CB52: 8D EC DB     STA $DBEC
C1/CB55: 60           RTS 
C1/CB56: 9C EB DB     STZ $DBEB
C1/CB59: 60           RTS 
C1/CB5A: 8A           TXA 
C1/CB5B: D0 03        BNE $CB60
C1/CB5D: 4C B9 DE     JMP $DEB9
C1/CB60: C8           INY 
C1/CB61: 60           RTS 
C1/CB62: 8A           TXA 
C1/CB63: D0 03        BNE $CB68
C1/CB65: 4C 1D D4     JMP $D41D
C1/CB68: C8           INY 
C1/CB69: 60           RTS 
C1/CB6A: DA           PHX 
C1/CB6B: AD 56 EE     LDA $EE56
C1/CB6E: F0 06        BEQ $CB76
C1/CB70: 20 98 CB     JSR $CB98
C1/CB73: CE 56 EE     DEC $EE56
C1/CB76: FA           PLX 
C1/CB77: 60           RTS 
C1/CB78: DA           PHX 
C1/CB79: AD 56 EE     LDA $EE56
C1/CB7C: C9 20        CMP #$20
C1/CB7E: F0 06        BEQ $CB86
C1/CB80: 20 C9 CB     JSR $CBC9
C1/CB83: EE 56 EE     INC $EE56
C1/CB86: FA           PLX 
C1/CB87: 60           RTS 
C1/CB88: DA           PHX 
C1/CB89: AD 56 EE     LDA $EE56
C1/CB8C: C9 20        CMP #$20
C1/CB8E: F0 06        BEQ $CB96
C1/CB90: 20 98 CB     JSR $CB98
C1/CB93: EE 56 EE     INC $EE56
C1/CB96: FA           PLX 
C1/CB97: 60           RTS 
C1/CB98: 7B           TDC 
C1/CB99: AA           TAX 
C1/CB9A: C2 20        REP #$20
C1/CB9C: AD 56 EE     LDA $EE56
C1/CB9F: 29 FF 00     AND #$00FF
C1/CBA2: 85 7E        STA $7E
C1/CBA4: BD F8 ED     LDA $EDF8,X
C1/CBA7: 20 E9 CB     JSR $CBE9
C1/CBAA: 9D 8B 7E     STA $7E8B,X
C1/CBAD: AD 56 EE     LDA $EE56
C1/CBB0: 29 FF 00     AND #$00FF
C1/CBB3: 85 7E        STA $7E
C1/CBB5: BD 18 EE     LDA $EE18,X
C1/CBB8: 20 E9 CB     JSR $CBE9
C1/CBBB: 9D AB 7E     STA $7EAB,X
C1/CBBE: E8           INX 
C1/CBBF: E8           INX 
C1/CBC0: E0 1E 00     CPX #$001E
C1/CBC3: D0 D7        BNE $CB9C
C1/CBC5: 7B           TDC 
C1/CBC6: E2 20        SEP #$20
C1/CBC8: 60           RTS 
C1/CBC9: 7B           TDC 
C1/CBCA: AA           TAX 
C1/CBCB: C2 20        REP #$20
C1/CBCD: AD 56 EE     LDA $EE56
C1/CBD0: 29 FF 00     AND #$00FF
C1/CBD3: 85 7E        STA $7E
C1/CBD5: BD 38 EE     LDA $EE38,X
C1/CBD8: 20 E9 CB     JSR $CBE9
C1/CBDB: 9D CB 7E     STA $7ECB,X
C1/CBDE: E8           INX 
C1/CBDF: E8           INX 
C1/CBE0: E0 1E 00     CPX #$001E
C1/CBE3: D0 E8        BNE $CBCD
C1/CBE5: 7B           TDC 
C1/CBE6: E2 20        SEP #$20
C1/CBE8: 60           RTS 
C1/CBE9: 85 84        STA $84
C1/CBEB: A5 7E        LDA $7E
C1/CBED: 0A           ASL 
C1/CBEE: 0A           ASL 
C1/CBEF: 0A           ASL 
C1/CBF0: 0A           ASL 
C1/CBF1: 0A           ASL 
C1/CBF2: 85 80        STA $80
C1/CBF4: 0A           ASL 
C1/CBF5: 0A           ASL 
C1/CBF6: 0A           ASL 
C1/CBF7: 0A           ASL 
C1/CBF8: 0A           ASL 
C1/CBF9: 85 82        STA $82
C1/CBFB: A5 84        LDA $84
C1/CBFD: 29 1F        AND #$1F
C1/CBFF: 00 18        BRK $18
C1/CC01: 65 7E        ADC $7E
C1/CC03: 85 7E        STA $7E
C1/CC05: 29 E0        AND #$E0
C1/CC07: 7F D0 0B A5  ADC $A50BD0,X
C1/CC0B: 84 29        STY $29
C1/CC0D: E0 7F 05     CPX #$057F
C1/CC10: 7E 85 84     ROR $8485,X
C1/CC13: 80 07        BRA $CC1C
C1/CC15: A5 84        LDA $84
C1/CC17: 09 1F        ORA #$1F
C1/CC19: 00 85        BRK $85
C1/CC1B: 84 A5        STY $A5
C1/CC1D: 84 29        STY $29
C1/CC1F: E0 03 18     CPX #$1803
C1/CC22: 65 80        ADC $80
C1/CC24: 85 80        STA $80
C1/CC26: 29 1F        AND #$1F
C1/CC28: 7C D0 0B     JMP ($0BD0,X)
C1/CC2B: A5 84        LDA $84
C1/CC2D: 29 1F        AND #$1F
C1/CC2F: 7C 05 80     JMP ($8005,X)
C1/CC32: 85 84        STA $84
C1/CC34: 80 07        BRA $CC3D
C1/CC36: A5 84        LDA $84
C1/CC38: 09 E0        ORA #$E0
C1/CC3A: 03 85        ORA $85,S
C1/CC3C: 84 A5        STY $A5
C1/CC3E: 84 29        STY $29
C1/CC40: 00 7C        BRK $7C
C1/CC42: 18           CLC 
C1/CC43: 65 82        ADC $82
C1/CC45: 85 82        STA $82
C1/CC47: 29 FF        AND #$FF
C1/CC49: 83 D0        STA $D0,S
C1/CC4B: 0B           PHD 
C1/CC4C: A5 84        LDA $84
C1/CC4E: 29 FF        AND #$FF
C1/CC50: 03 05        ORA $05,S
C1/CC52: 82 85 84     BRL $50DA
C1/CC55: 80 07        BRA $CC5E
C1/CC57: A5 84        LDA $84
C1/CC59: 09 00        ORA #$00
C1/CC5B: 7C 85 84     JMP ($8485,X)
C1/CC5E: A5 84        LDA $84
C1/CC60: 60           RTS 
C1/CC61: 00 01        BRK $01
C1/CC63: 02 03        COP $03
C1/CC65: 04 05        TSB $05
C1/CC67: 06 07        ASL $07
C1/CC69: 07 06        ORA [$06]
C1/CC6B: 05 04        ORA $04
C1/CC6D: 03 02        ORA $02,S
C1/CC6F: 01 00        ORA ($00,X)
C1/CC71: 20 20 20     JSR $2020
C1/CC74: 20 00 00     JSR $0000
C1/CC77: 00 00        BRK $00
C1/CC79: 00 00        BRK $00
C1/CC7B: 00 00        BRK $00
C1/CC7D: 20 20 20     JSR $2020
C1/CC80: 20 5A DA     JSR $DA5A
C1/CC83: C2 20        REP #$20
C1/CC85: 8A           TXA 
C1/CC86: 4A           LSR 
C1/CC87: 4A           LSR 
C1/CC88: 4A           LSR 
C1/CC89: 4A           LSR 
C1/CC8A: AA           TAX 
C1/CC8B: 7B           TDC 
C1/CC8C: E2 20        SEP #$20
C1/CC8E: 86 84        STX $84
C1/CC90: BD 7B CE     LDA $CE7B,X
C1/CC93: 18           CLC 
C1/CC94: 7D FB CE     ADC $CEFB,X
C1/CC97: 9D 7B CE     STA $CE7B,X
C1/CC9A: BD BB CE     LDA $CEBB,X
C1/CC9D: 38           SEC 
C1/CC9E: FD FB CE     SBC $CEFB,X
C1/CCA1: 9D BB CE     STA $CEBB,X
C1/CCA4: 20 CA 09     JSR $09CA
C1/CCA7: 85 82        STA $82
C1/CCA9: A6 84        LDX $84
C1/CCAB: 20 E5 09     JSR $09E5
C1/CCAE: 85 83        STA $83
C1/CCB0: A6 84        LDX $84
C1/CCB2: BD 7B CE     LDA $CE7B,X
C1/CCB5: 4A           LSR 
C1/CCB6: 4A           LSR 
C1/CCB7: 4A           LSR 
C1/CCB8: 4A           LSR 
C1/CCB9: AA           TAX 
C1/CCBA: BF 61 CC C1  LDA $C1CC61,X
C1/CCBE: 85 7E        STA $7E
C1/CCC0: BF 71 CC C1  LDA $C1CC71,X
C1/CCC4: 85 7F        STA $7F
C1/CCC6: FA           PLX 
C1/CCC7: BD E7 D1     LDA $D1E7,X
C1/CCCA: 29 DF        AND #$DF
C1/CCCC: 05 7F        ORA $7F
C1/CCCE: 9D E7 D1     STA $D1E7,X
C1/CCD1: A5 7E        LDA $7E
C1/CCD3: 9D E3 D1     STA $D1E3,X
C1/CCD6: A5 82        LDA $82
C1/CCD8: 9D DC D1     STA $D1DC,X
C1/CCDB: A5 83        LDA $83
C1/CCDD: 9D DD D1     STA $D1DD,X
C1/CCE0: 7A           PLY 
C1/CCE1: 60           RTS 
C1/CCE2: 20 81 CC     JSR $CC81
C1/CCE5: AD D0 DB     LDA $DBD0
C1/CCE8: F0 0B        BEQ $CCF5
C1/CCEA: 88           DEY 
C1/CCEB: 88           DEY 
C1/CCEC: 88           DEY 
C1/CCED: 88           DEY 
C1/CCEE: 88           DEY 
C1/CCEF: 88           DEY 
C1/CCF0: 88           DEY 
C1/CCF1: 88           DEY 
C1/CCF2: 20 46 CB     JSR $CB46
C1/CCF5: 60           RTS 
C1/CCF6: 8A           TXA 
C1/CCF7: D0 03        BNE $CCFC
C1/CCF9: 4C AA E2     JMP $E2AA
C1/CCFC: 60           RTS 
C1/CCFD: BD E6 D3     LDA $D3E6,X
C1/CD00: 18           CLC 
C1/CD01: 69 02        ADC #$02
C1/CD03: 9D E6 D3     STA $D3E6,X
C1/CD06: C2 20        REP #$20
C1/CD08: BD E4 D3     LDA $D3E4,X
C1/CD0B: 38           SEC 
C1/CD0C: E9 02 00     SBC #$0002
C1/CD0F: 9D E4 D3     STA $D3E4,X
C1/CD12: BD E4 D3     LDA $D3E4,X
C1/CD15: 30 16        BMI $CD2D
C1/CD17: 7B           TDC 
C1/CD18: E2 20        SEP #$20
C1/CD1A: 88           DEY 
C1/CD1B: 88           DEY 
C1/CD1C: 88           DEY 
C1/CD1D: 20 3B E2     JSR $E23B
C1/CD20: FE E1 D5     INC $D5E1,X
C1/CD23: BD E1 D5     LDA $D5E1,X
C1/CD26: 29 06        AND #$06
C1/CD28: 4A           LSR 
C1/CD29: 9D E3 D1     STA $D1E3,X
C1/CD2C: 60           RTS 
C1/CD2D: 7B           TDC 
C1/CD2E: E2 20        SEP #$20
C1/CD30: 9E E3 D1     STZ $D1E3,X
C1/CD33: 60           RTS 
C1/CD34: DA           PHX 
C1/CD35: 86 78        STX $78
C1/CD37: FE E1 D5     INC $D5E1,X
C1/CD3A: BD E1 D5     LDA $D5E1,X
C1/CD3D: 29 01        AND #$01
C1/CD3F: D0 0A        BNE $CD4B
C1/CD41: BD E2 D3     LDA $D3E2,X
C1/CD44: 10 0B        BPL $CD51
C1/CD46: 20 89 DA     JSR $DA89
C1/CD49: 90 06        BCC $CD51
C1/CD4B: 88           DEY 
C1/CD4C: 88           DEY 
C1/CD4D: 88           DEY 
C1/CD4E: 88           DEY 
C1/CD4F: FA           PLX 
C1/CD50: 60           RTS 
C1/CD51: FA           PLX 
C1/CD52: 60           RTS 
C1/CD53: BD E6 D3     LDA $D3E6,X
C1/CD56: 18           CLC 
C1/CD57: 69 02        ADC #$02
C1/CD59: 9D E6 D3     STA $D3E6,X
C1/CD5C: C2 20        REP #$20
C1/CD5E: BD E4 D3     LDA $D3E4,X
C1/CD61: 38           SEC 
C1/CD62: E9 02 00     SBC #$0002
C1/CD65: 9D E4 D3     STA $D3E4,X
C1/CD68: BD E4 D3     LDA $D3E4,X
C1/CD6B: 30 1E        BMI $CD8B
C1/CD6D: 7B           TDC 
C1/CD6E: E2 20        SEP #$20
C1/CD70: 88           DEY 
C1/CD71: 88           DEY 
C1/CD72: 88           DEY 
C1/CD73: 20 BC E0     JSR $E0BC
C1/CD76: FE E1 D5     INC $D5E1,X
C1/CD79: BD E1 D5     LDA $D5E1,X
C1/CD7C: 29 03        AND #$03
C1/CD7E: F0 0A        BEQ $CD8A
C1/CD80: BD E3 D1     LDA $D1E3,X
C1/CD83: C9 04        CMP #$04
C1/CD85: F0 03        BEQ $CD8A
C1/CD87: FE E3 D1     INC $D1E3,X
C1/CD8A: 60           RTS 
C1/CD8B: 7B           TDC 
C1/CD8C: E2 20        SEP #$20
C1/CD8E: 9E E3 D1     STZ $D1E3,X
C1/CD91: 60           RTS 
C1/CD92: BD E6 D3     LDA $D3E6,X
C1/CD95: 18           CLC 
C1/CD96: 69 0C        ADC #$0C
C1/CD98: 9D E6 D3     STA $D3E6,X
C1/CD9B: C2 20        REP #$20
C1/CD9D: BD E4 D3     LDA $D3E4,X
C1/CDA0: 38           SEC 
C1/CDA1: E9 0C 00     SBC #$000C
C1/CDA4: 9D E4 D3     STA $D3E4,X
C1/CDA7: BD E4 D3     LDA $D3E4,X
C1/CDAA: 30 2A        BMI $CDD6
C1/CDAC: 7B           TDC 
C1/CDAD: E2 20        SEP #$20
C1/CDAF: 88           DEY 
C1/CDB0: 88           DEY 
C1/CDB1: 88           DEY 
C1/CDB2: 20 3B E2     JSR $E23B
C1/CDB5: FE E1 D5     INC $D5E1,X
C1/CDB8: A9 10        LDA #$10
C1/CDBA: 85 80        STA $80
C1/CDBC: BD E1 D5     LDA $D5E1,X
C1/CDBF: 0A           ASL 
C1/CDC0: 0A           ASL 
C1/CDC1: 0A           ASL 
C1/CDC2: DA           PHX 
C1/CDC3: 20 00 0A     JSR $0A00
C1/CDC6: FA           PLX 
C1/CDC7: 18           CLC 
C1/CDC8: 7D E3 D5     ADC $D5E3,X
C1/CDCB: 9D DD D1     STA $D1DD,X
C1/CDCE: 20 96 FC     JSR $FC96       ; generate random number
C1/CDD1: 29 03        AND #$03
C1/CDD3: 9D E3 D1     STA $D1E3,X
C1/CDD6: 7B           TDC 
C1/CDD7: E2 20        SEP #$20
C1/CDD9: 60           RTS 
C1/CDDA: AE 3D CE     LDX $CE3D
C1/CDDD: BD E2 D3     LDA $D3E2,X
C1/CDE0: 29 7F        AND #$7F
C1/CDE2: 0A           ASL 
C1/CDE3: 0A           ASL 
C1/CDE4: 0A           ASL 
C1/CDE5: 0A           ASL 
C1/CDE6: 0A           ASL 
C1/CDE7: A8           TAY 
C1/CDE8: 60           RTS 
C1/CDE9: DA           PHX 
C1/CDEA: 5A           PHY 
C1/CDEB: 8E 3D CE     STX $CE3D
C1/CDEE: C2 20        REP #$20
C1/CDF0: 7B           TDC 
C1/CDF1: A8           TAY 
C1/CDF2: B9 70 00     LDA $0070,Y
C1/CDF5: 48           PHA 
C1/CDF6: C8           INY 
C1/CDF7: C8           INY 
C1/CDF8: C0 0C 00     CPY #$000C
C1/CDFB: D0 F5        BNE $CDF2
C1/CDFD: 7B           TDC 
C1/CDFE: E2 20        SEP #$20
C1/CE00: 20 DA CD     JSR $CDDA
C1/CE03: B9 45 CF     LDA $CF45,Y
C1/CE06: 85 A6        STA $A6
C1/CE08: B9 46 CF     LDA $CF46,Y
C1/CE0B: 85 A7        STA $A7
C1/CE0D: A9 20        LDA #$20
C1/CE0F: 85 A8        STA $A8
C1/CE11: A9 50        LDA #$50
C1/CE13: 85 A9        STA $A9
C1/CE15: 20 6E 0A     JSR $0A6E
C1/CE18: 20 A7 09     JSR $09A7
C1/CE1B: 7B           TDC 
C1/CE1C: AA           TAX 
C1/CE1D: A5 AE        LDA $AE
C1/CE1F: 20 96 09     JSR $0996
C1/CE22: 9C FB CD     STZ $CDFB
C1/CE25: 9C 3B CE     STZ $CE3B
C1/CE28: 20 F2 02     JSR $02F2       ; wait one frame
C1/CE2B: AD 3B CE     LDA $CE3B
C1/CE2E: AA           TAX 
C1/CE2F: 86 80        STX $80
C1/CE31: AD BB CE     LDA $CEBB
C1/CE34: 20 59 0B     JSR $0B59
C1/CE37: 20 DA CD     JSR $CDDA
C1/CE3A: C2 20        REP #$20
C1/CE3C: A5 84        LDA $84
C1/CE3E: 99 5D CF     STA $CF5D,Y
C1/CE41: 7B           TDC 
C1/CE42: E2 20        SEP #$20
C1/CE44: AD FB CD     LDA $CDFB
C1/CE47: AA           TAX 
C1/CE48: 86 80        STX $80
C1/CE4A: AD 7B CE     LDA $CE7B
C1/CE4D: 20 59 0B     JSR $0B59
C1/CE50: 20 DA CD     JSR $CDDA
C1/CE53: C2 20        REP #$20
C1/CE55: A5 84        LDA $84
C1/CE57: 99 5F CF     STA $CF5F,Y
C1/CE5A: 7B           TDC 
C1/CE5B: E2 20        SEP #$20
C1/CE5D: 7B           TDC 
C1/CE5E: AA           TAX 
C1/CE5F: 1A           INC 
C1/CE60: 20 B9 09     JSR $09B9
C1/CE63: C2 20        REP #$20
C1/CE65: A5 AF        LDA $AF
C1/CE67: 38           SEC 
C1/CE68: E9 01 00     SBC #$0001
C1/CE6B: 85 AF        STA $AF
C1/CE6D: 7B           TDC 
C1/CE6E: E2 20        SEP #$20
C1/CE70: A5 B0        LDA $B0
C1/CE72: 10 B4        BPL $CE28
C1/CE74: A2 20 00     LDX #$0020
C1/CE77: DA           PHX 
C1/CE78: 20 F2 02     JSR $02F2       ; wait one frame
C1/CE7B: 20 DA CD     JSR $CDDA
C1/CE7E: B9 62 CF     LDA $CF62,Y
C1/CE81: 49 80        EOR #$80
C1/CE83: 99 62 CF     STA $CF62,Y
C1/CE86: FA           PLX 
C1/CE87: CA           DEX 
C1/CE88: D0 ED        BNE $CE77
C1/CE8A: 20 DA CD     JSR $CDDA
C1/CE8D: B9 62 CF     LDA $CF62,Y
C1/CE90: 09 80        ORA #$80
C1/CE92: 99 62 CF     STA $CF62,Y
C1/CE95: AE 3D CE     LDX $CE3D
C1/CE98: BD E2 D3     LDA $D3E2,X
C1/CE9B: 0A           ASL 
C1/CE9C: 0A           ASL 
C1/CE9D: AA           TAX 
C1/CE9E: BD 81 7B     LDA $7B81,X
C1/CEA1: 09 80        ORA #$80
C1/CEA3: 9D 81 7B     STA $7B81,X
C1/CEA6: C2 20        REP #$20
C1/CEA8: A0 0C 00     LDY #$000C
C1/CEAB: 68           PLA 
C1/CEAC: 99 6E 00     STA $006E,Y
C1/CEAF: 88           DEY 
C1/CEB0: 88           DEY 
C1/CEB1: D0 F8        BNE $CEAB
C1/CEB3: 7B           TDC 
C1/CEB4: E2 20        SEP #$20
C1/CEB6: 7A           PLY 
C1/CEB7: FA           PLX 
C1/CEB8: 60           RTS 
C1/CEB9: DA           PHX 
C1/CEBA: 7B           TDC 
C1/CEBB: AA           TAX 
C1/CEBC: AD 52 DB     LDA $DB52
C1/CEBF: 85 98        STA $98
C1/CEC1: 06 98        ASL $98
C1/CEC3: 90 0D        BCC $CED2
C1/CEC5: BD AF DB     LDA $DBAF,X
C1/CEC8: C9 F7        CMP #$F7
C1/CECA: B0 06        BCS $CED2
C1/CECC: 18           CLC 
C1/CECD: 69 08        ADC #$08
C1/CECF: 9D AF DB     STA $DBAF,X
C1/CED2: E8           INX 
C1/CED3: E0 04 00     CPX #$0004
C1/CED6: D0 E9        BNE $CEC1
C1/CED8: FA           PLX 
C1/CED9: 60           RTS 
C1/CEDA: DA           PHX 
C1/CEDB: 20 18 DB     JSR $DB18
C1/CEDE: 20 5B E4     JSR $E45B
C1/CEE1: A6 84        LDX $84
C1/CEE3: A9 20        LDA #$20
C1/CEE5: 20 96 09     JSR $0996
C1/CEE8: A6 78        LDX $78
C1/CEEA: A5 86        LDA $86
C1/CEEC: 9D DC D1     STA $D1DC,X
C1/CEEF: A5 87        LDA $87
C1/CEF1: 9D DD D1     STA $D1DD,X
C1/CEF4: FA           PLX 
C1/CEF5: 60           RTS 
C1/CEF6: 20 2A D0     JSR $D02A
C1/CEF9: FE E1 D5     INC $D5E1,X
C1/CEFC: BD E1 D5     LDA $D5E1,X
C1/CEFF: 29 0C        AND #$0C
C1/CF01: 4A           LSR 
C1/CF02: 4A           LSR 
C1/CF03: 9D E3 D1     STA $D1E3,X
C1/CF06: 60           RTS 
C1/CF07: BD E6 D3     LDA $D3E6,X
C1/CF0A: 18           CLC 
C1/CF0B: 69 08        ADC #$08
C1/CF0D: 9D E6 D3     STA $D3E6,X
C1/CF10: C2 20        REP #$20
C1/CF12: BD E4 D3     LDA $D3E4,X
C1/CF15: 38           SEC 
C1/CF16: E9 08 00     SBC #$0008
C1/CF19: 9D E4 D3     STA $D3E4,X
C1/CF1C: BD E4 D3     LDA $D3E4,X
C1/CF1F: 30 0A        BMI $CF2B
C1/CF21: 7B           TDC 
C1/CF22: E2 20        SEP #$20
C1/CF24: 88           DEY 
C1/CF25: 88           DEY 
C1/CF26: 88           DEY 
C1/CF27: 88           DEY 
C1/CF28: 20 3B E2     JSR $E23B
C1/CF2B: 7B           TDC 
C1/CF2C: E2 20        SEP #$20
C1/CF2E: 60           RTS 
C1/CF2F: DA           PHX 
C1/CF30: 8A           TXA 
C1/CF31: 4A           LSR 
C1/CF32: 4A           LSR 
C1/CF33: 4A           LSR 
C1/CF34: 4A           LSR 
C1/CF35: 18           CLC 
C1/CF36: 69 10        ADC #$10
C1/CF38: AA           TAX 
C1/CF39: DA           PHX 
C1/CF3A: A9 0C        LDA #$0C
C1/CF3C: 20 96 09     JSR $0996
C1/CF3F: 20 CA 09     JSR $09CA
C1/CF42: 85 74        STA $74
C1/CF44: FA           PLX 
C1/CF45: 20 E5 09     JSR $09E5
C1/CF48: 85 75        STA $75
C1/CF4A: FA           PLX 
C1/CF4B: A5 74        LDA $74
C1/CF4D: 9D DC D1     STA $D1DC,X
C1/CF50: A5 75        LDA $75
C1/CF52: 9D DD D1     STA $D1DD,X
C1/CF55: 60           RTS 
C1/CF56: BD E6 D3     LDA $D3E6,X
C1/CF59: 18           CLC 
C1/CF5A: 69 02        ADC #$02
C1/CF5C: 9D E6 D3     STA $D3E6,X
C1/CF5F: BD E5 D3     LDA $D3E5,X
C1/CF62: D0 0F        BNE $CF73
C1/CF64: BD E4 D3     LDA $D3E4,X
C1/CF67: C9 20        CMP #$20
C1/CF69: 90 10        BCC $CF7B
C1/CF6B: C9 40        CMP #$40
C1/CF6D: 90 13        BCC $CF82
C1/CF6F: C9 60        CMP #$60
C1/CF71: 90 17        BCC $CF8A
C1/CF73: A9 30        LDA #$30
C1/CF75: 85 7E        STA $7E
C1/CF77: A9 03        LDA #$03
C1/CF79: 80 15        BRA $CF90
C1/CF7B: A9 18        LDA #$18
C1/CF7D: 85 7E        STA $7E
C1/CF7F: 7B           TDC 
C1/CF80: 80 0E        BRA $CF90
C1/CF82: A9 20        LDA #$20
C1/CF84: 85 7E        STA $7E
C1/CF86: A9 01        LDA #$01
C1/CF88: 80 06        BRA $CF90
C1/CF8A: A9 28        LDA #$28
C1/CF8C: 85 7E        STA $7E
C1/CF8E: A9 02        LDA #$02
C1/CF90: 9D E3 D1     STA $D1E3,X
C1/CF93: 8A           TXA 
C1/CF94: 4A           LSR 
C1/CF95: 4A           LSR 
C1/CF96: 4A           LSR 
C1/CF97: 4A           LSR 
C1/CF98: DA           PHX 
C1/CF99: AA           TAX 
C1/CF9A: A5 7E        LDA $7E
C1/CF9C: 9D 0B CE     STA $CE0B,X
C1/CF9F: 9D 4B CE     STA $CE4B,X
C1/CFA2: FA           PLX 
C1/CFA3: C2 20        REP #$20
C1/CFA5: BD E4 D3     LDA $D3E4,X
C1/CFA8: 38           SEC 
C1/CFA9: E9 02 00     SBC #$0002
C1/CFAC: 9D E4 D3     STA $D3E4,X
C1/CFAF: BD E4 D3     LDA $D3E4,X
C1/CFB2: 30 0E        BMI $CFC2
C1/CFB4: 7B           TDC 
C1/CFB5: E2 20        SEP #$20
C1/CFB7: 88           DEY 
C1/CFB8: 88           DEY 
C1/CFB9: 88           DEY 
C1/CFBA: 20 2F CF     JSR $CF2F
C1/CFBD: 20 3B E2     JSR $E23B
C1/CFC0: 80 03        BRA $CFC5
C1/CFC2: 9E E3 D1     STZ $D1E3,X
C1/CFC5: 7B           TDC 
C1/CFC6: E2 20        SEP #$20
C1/CFC8: 60           RTS 
C1/CFC9: BD DF D7     LDA $D7DF,X
C1/CFCC: 9D E3 D1     STA $D1E3,X
C1/CFCF: 1A           INC 
C1/CFD0: C9 06        CMP #$06
C1/CFD2: D0 01        BNE $CFD5
C1/CFD4: 7B           TDC 
C1/CFD5: 9D DF D7     STA $D7DF,X
C1/CFD8: 60           RTS 
C1/CFD9: BD E6 D3     LDA $D3E6,X
C1/CFDC: C9 FC        CMP #$FC
C1/CFDE: F0 06        BEQ $CFE6
C1/CFE0: 18           CLC 
C1/CFE1: 69 0C        ADC #$0C
C1/CFE3: 9D E6 D3     STA $D3E6,X
C1/CFE6: 20 C9 CF     JSR $CFC9
C1/CFE9: 4C 3B E2     JMP $E23B
C1/CFEC: A9 08        LDA #$08
C1/CFEE: 85 80        STA $80
C1/CFF0: BD E3 D7     LDA $D7E3,X
C1/CFF3: 18           CLC 
C1/CFF4: 69 08        ADC #$08
C1/CFF6: 9D E3 D7     STA $D7E3,X
C1/CFF9: BD DF D7     LDA $D7DF,X
C1/CFFC: 0A           ASL 
C1/CFFD: 0A           ASL 
C1/CFFE: 0A           ASL 
C1/CFFF: 18           CLC 
C1/D000: 7D E3 D7     ADC $D7E3,X
C1/D003: DA           PHX 
C1/D004: 20 00 0A     JSR $0A00
C1/D007: FA           PLX 
C1/D008: 85 7E        STA $7E
C1/D00A: BD E1 D7     LDA $D7E1,X
C1/D00D: 18           CLC 
C1/D00E: 65 7E        ADC $7E
C1/D010: 9D E3 D3     STA $D3E3,X
C1/D013: BD DF D7     LDA $D7DF,X
C1/D016: 29 0F        AND #$0F
C1/D018: 4A           LSR 
C1/D019: 9D E3 D1     STA $D1E3,X
C1/D01C: 60           RTS 
C1/D01D: 20 3B E2     JSR $E23B
C1/D020: 20 EC CF     JSR $CFEC
C1/D023: 20 BF C9     JSR $C9BF
C1/D026: 9D E6 D3     STA $D3E6,X
C1/D029: 60           RTS 
C1/D02A: BD DF D1     LDA $D1DF,X
C1/D02D: 85 A6        STA $A6
C1/D02F: BD E1 D1     LDA $D1E1,X
C1/D032: 85 A7        STA $A7
C1/D034: C2 20        REP #$20
C1/D036: BD DF D1     LDA $D1DF,X
C1/D039: 9D D8 D5     STA $D5D8,X
C1/D03C: BD E1 D1     LDA $D1E1,X
C1/D03F: 9D DA D5     STA $D5DA,X
C1/D042: 7B           TDC 
C1/D043: E2 20        SEP #$20
C1/D045: BD DC D5     LDA $D5DC,X
C1/D048: 85 A8        STA $A8
C1/D04A: BD DE D5     LDA $D5DE,X
C1/D04D: 85 A9        STA $A9
C1/D04F: DA           PHX 
C1/D050: 20 6E 0A     JSR $0A6E
C1/D053: FA           PLX 
C1/D054: BD DD D5     LDA $D5DD,X
C1/D057: 1D DF D5     ORA $D5DF,X
C1/D05A: D0 46        BNE $D0A2
C1/D05C: 20 A6 D0     JSR $D0A6
C1/D05F: A5 AE        LDA $AE
C1/D061: 38           SEC 
C1/D062: FD E2 D7     SBC $D7E2,X
C1/D065: 30 0B        BMI $D072
C1/D067: BD E2 D7     LDA $D7E2,X
C1/D06A: 18           CLC 
C1/D06B: 65 7E        ADC $7E
C1/D06D: 9D E2 D7     STA $D7E2,X
C1/D070: 80 09        BRA $D07B
C1/D072: BD E2 D7     LDA $D7E2,X
C1/D075: 38           SEC 
C1/D076: E5 7E        SBC $7E
C1/D078: 9D E2 D7     STA $D7E2,X
C1/D07B: 9D E3 D3     STA $D3E3,X
C1/D07E: BD E1 D7     LDA $D7E1,X
C1/D081: D0 0E        BNE $D091
C1/D083: BD E3 D3     LDA $D3E3,X
C1/D086: 18           CLC 
C1/D087: 69 10        ADC #$10
C1/D089: 4A           LSR 
C1/D08A: 4A           LSR 
C1/D08B: 4A           LSR 
C1/D08C: 4A           LSR 
C1/D08D: 4A           LSR 
C1/D08E: 9D E3 D1     STA $D1E3,X
C1/D091: A5 B0        LDA $B0
C1/D093: D0 06        BNE $D09B
C1/D095: A5 AF        LDA $AF
C1/D097: C9 0C        CMP #$0C
C1/D099: 90 07        BCC $D0A2
C1/D09B: 20 3B E2     JSR $E23B
C1/D09E: 88           DEY 
C1/D09F: 88           DEY 
C1/D0A0: 88           DEY 
C1/D0A1: 60           RTS 
C1/D0A2: 9E E3 D1     STZ $D1E3,X
C1/D0A5: 60           RTS 
C1/D0A6: A5 AE        LDA $AE
C1/D0A8: 38           SEC 
C1/D0A9: FD E2 D7     SBC $D7E2,X
C1/D0AC: 30 0A        BMI $D0B8
C1/D0AE: CD B2 F8     CMP $F8B2
C1/D0B1: 90 09        BCC $D0BC
C1/D0B3: AD B2 F8     LDA $F8B2
C1/D0B6: 80 04        BRA $D0BC
C1/D0B8: 49 FF        EOR #$FF
C1/D0BA: 80 F2        BRA $D0AE
C1/D0BC: 85 7E        STA $7E
C1/D0BE: 60           RTS 
C1/D0BF: 9C 68 CD     STZ $CD68
C1/D0C2: 60           RTS 
C1/D0C3: EE E3 D5     INC $D5E3
C1/D0C6: AD E3 D5     LDA $D5E3
C1/D0C9: 29 02        AND #$02
C1/D0CB: F0 04        BEQ $D0D1
C1/D0CD: 9C 68 CD     STZ $CD68
C1/D0D0: 60           RTS 
C1/D0D1: EE 68 CD     INC $CD68
C1/D0D4: 60           RTS 
C1/D0D5: EE E3 D5     INC $D5E3
C1/D0D8: AD E3 D5     LDA $D5E3
C1/D0DB: 29 0F        AND #$0F
C1/D0DD: D0 21        BNE $D100
C1/D0DF: 20 04 D1     JSR $D104
C1/D0E2: 64 7E        STZ $7E
C1/D0E4: AD 50 DB     LDA $DB50
C1/D0E7: 29 40        AND #$40
C1/D0E9: D0 04        BNE $D0EF
C1/D0EB: A9 08        LDA #$08
C1/D0ED: 85 7E        STA $7E
C1/D0EF: AD 53 DB     LDA $DB53
C1/D0F2: DA           PHX 
C1/D0F3: 20 7A FC     JSR $FC7A
C1/D0F6: 18           CLC 
C1/D0F7: 65 7E        ADC $7E
C1/D0F9: FA           PLX 
C1/D0FA: CD E4 D5     CMP $D5E4
C1/D0FD: D0 01        BNE $D100
C1/D0FF: 60           RTS 
C1/D100: 88           DEY 
C1/D101: 88           DEY 
C1/D102: 88           DEY 
C1/D103: 60           RTS 
C1/D104: DA           PHX 
C1/D105: EE E4 D5     INC $D5E4
C1/D108: AD E4 D5     LDA $D5E4
C1/D10B: 29 0F        AND #$0F
C1/D10D: 8D E4 D5     STA $D5E4
C1/D110: 0A           ASL 
C1/D111: AA           TAX 
C1/D112: C2 20        REP #$20
C1/D114: A5 DE        LDA $DE
C1/D116: 3F D5 FF CE  AND $CEFFD5,X
C1/D11A: D0 05        BNE $D121
C1/D11C: 7B           TDC 
C1/D11D: E2 20        SEP #$20
C1/D11F: 80 E4        BRA $D105
C1/D121: 7B           TDC 
C1/D122: E2 20        SEP #$20
C1/D124: AD E4 D5     LDA $D5E4
C1/D127: AA           TAX 
C1/D128: BD 4E D0     LDA $D04E,X
C1/D12B: 18           CLC 
C1/D12C: 7D 96 D0     ADC $D096,X
C1/D12F: 8D 69 CD     STA $CD69
C1/D132: BD 5A D0     LDA $D05A,X
C1/D135: 8D 6A CD     STA $CD6A
C1/D138: A9 33        LDA #$33
C1/D13A: 8D 6B CD     STA $CD6B
C1/D13D: A9 01        LDA #$01
C1/D13F: 8D 68 CD     STA $CD68
C1/D142: 20 AD FB     JSR $FBAD       ; play system sound effect $10
C1/D145: FA           PLX 
C1/D146: 60           RTS 
C1/D147: C8           INY 
C1/D148: B7 70        LDA [$70],Y
C1/D14A: 85 7E        STA $7E
C1/D14C: EE E3 D5     INC $D5E3
C1/D14F: AD E3 D5     LDA $D5E3
C1/D152: 25 7E        AND $7E
C1/D154: D0 03        BNE $D159
C1/D156: 20 04 D1     JSR $D104
C1/D159: 60           RTS 
C1/D15A: DA           PHX 
C1/D15B: 20 DB CA     JSR $CADB
C1/D15E: A6 84        LDX $84
C1/D160: BD 5B CE     LDA $CE5B,X
C1/D163: F0 12        BEQ $D177
C1/D165: BD 3B CE     LDA $CE3B,X
C1/D168: 18           CLC 
C1/D169: 69 04        ADC #$04
C1/D16B: 9D 3B CE     STA $CE3B,X
C1/D16E: C9 20        CMP #$20
C1/D170: D0 13        BNE $D185
C1/D172: 9E 5B CE     STZ $CE5B,X
C1/D175: 80 0E        BRA $D185
C1/D177: BD 3B CE     LDA $CE3B,X
C1/D17A: 38           SEC 
C1/D17B: E9 04        SBC #$04
C1/D17D: 9D 3B CE     STA $CE3B,X
C1/D180: D0 03        BNE $D185
C1/D182: FE 5B CE     INC $CE5B,X
C1/D185: 20 EB CA     JSR $CAEB
C1/D188: A6 84        LDX $84
C1/D18A: DE FB CD     DEC $CDFB,X
C1/D18D: BD FB CE     LDA $CEFB,X
C1/D190: 20 96 09     JSR $0996
C1/D193: FA           PLX 
C1/D194: 60           RTS 
C1/D195: C2 20        REP #$20
C1/D197: BD DC D5     LDA $D5DC,X
C1/D19A: 9D DF D1     STA $D1DF,X
C1/D19D: BD DE D5     LDA $D5DE,X
C1/D1A0: 9D E1 D1     STA $D1E1,X
C1/D1A3: 7B           TDC 
C1/D1A4: E2 20        SEP #$20
C1/D1A6: 60           RTS 
C1/D1A7: C2 20        REP #$20
C1/D1A9: BD D8 D5     LDA $D5D8,X
C1/D1AC: 9D DF D1     STA $D1DF,X
C1/D1AF: BD DA D5     LDA $D5DA,X
C1/D1B2: 9D E1 D1     STA $D1E1,X
C1/D1B5: 7B           TDC 
C1/D1B6: E2 20        SEP #$20
C1/D1B8: 60           RTS 

; [  ]

C1/D1B9: C8           INY 
C1/D1BA: B7 70        LDA [$70],Y
C1/D1BC: DA           PHX 
C1/D1BD: 0A           ASL 
C1/D1BE: AA           TAX 
C1/D1BF: BF 6B C7 C1  LDA $C1C76B,X
C1/D1C3: 85 7E        STA $7E
C1/D1C5: BF 6C C7 C1  LDA $C1C76C,X
C1/D1C9: 85 7F        STA $7F
C1/D1CB: FA           PLX 
C1/D1CC: 6C 7E 00     JMP ($007E)

; [  ]

C1/D1CF: C8           INY 
C1/D1D0: B7 70        LDA [$70],Y
C1/D1D2: DA           PHX 
C1/D1D3: 0A           ASL 
C1/D1D4: AA           TAX 
C1/D1D5: BF 06 CB C1  LDA $C1CB06,X
C1/D1D9: 85 7E        STA $7E
C1/D1DB: BF 07 CB C1  LDA $C1CB07,X
C1/D1DF: 85 7F        STA $7F
C1/D1E1: FA           PLX 
C1/D1E2: 6C 7E 00     JMP ($007E)

C1/D1E5: 00 28
C1/D1E7: 00 58
C1/D1E9: 09 70
C1/D1EB: 00 80

C1/D1ED: DA           PHX 
C1/D1EE: 86 7E        STX $7E
C1/D1F0: 8A           TXA 
C1/D1F1: 4A           LSR 
C1/D1F2: 4A           LSR 
C1/D1F3: 4A           LSR 
C1/D1F4: 29 FE        AND #$FE
C1/D1F6: AA           TAX 
C1/D1F7: BF E5 D1 C1  LDA $C1D1E5,X
C1/D1FB: 85 80        STA $80
C1/D1FD: BF E6 D1 C1  LDA $C1D1E6,X
C1/D201: 85 81        STA $81
C1/D203: A6 7E        LDX $7E
C1/D205: A5 80        LDA $80
C1/D207: 9D DF D1     STA $D1DF,X
C1/D20A: 9E E0 D1     STZ $D1E0,X
C1/D20D: A5 81        LDA $81
C1/D20F: 9D E1 D1     STA $D1E1,X
C1/D212: 9E E2 D1     STZ $D1E2,X
C1/D215: FA           PLX 
C1/D216: 60           RTS 

C1/D217: BD E6 D3     LDA $D3E6,X
C1/D21A: 18           CLC 
C1/D21B: 69 08        ADC #$08
C1/D21D: 9D E6 D3     STA $D3E6,X
C1/D220: C2 20        REP #$20
C1/D222: BD E4 D3     LDA $D3E4,X
C1/D225: 38           SEC 
C1/D226: E9 08 00     SBC #$0008
C1/D229: 9D E4 D3     STA $D3E4,X
C1/D22C: BD E4 D3     LDA $D3E4,X
C1/D22F: 30 3A        BMI $D26B
C1/D231: 7B           TDC 
C1/D232: E2 20        SEP #$20
C1/D234: 88           DEY 
C1/D235: 88           DEY 
C1/D236: 88           DEY 
C1/D237: 88           DEY 
C1/D238: 88           DEY 
C1/D239: 88           DEY 
C1/D23A: 20 3B E2     JSR $E23B
C1/D23D: FE E1 D5     INC $D5E1,X
C1/D240: A9 10        LDA #$10
C1/D242: 85 80        STA $80
C1/D244: BD E1 D5     LDA $D5E1,X
C1/D247: 0A           ASL 
C1/D248: 0A           ASL 
C1/D249: 0A           ASL 
C1/D24A: 0A           ASL 
C1/D24B: 0A           ASL 
C1/D24C: DA           PHX 
C1/D24D: 20 00 0A     JSR $0A00
C1/D250: FA           PLX 
C1/D251: 18           CLC 
C1/D252: 7D E3 D5     ADC $D5E3,X
C1/D255: 9D DD D1     STA $D1DD,X
C1/D258: BD E2 D7     LDA $D7E2,X
C1/D25B: 9D E3 D1     STA $D1E3,X
C1/D25E: FE E2 D7     INC $D7E2,X
C1/D261: BD E2 D7     LDA $D7E2,X
C1/D264: C9 03        CMP #$03
C1/D266: D0 03        BNE $D26B
C1/D268: 9E E2 D7     STZ $D7E2,X
C1/D26B: 9E E3 D1     STZ $D1E3,X
C1/D26E: 7B           TDC 
C1/D26F: E2 20        SEP #$20
C1/D271: 60           RTS 
C1/D272: C8           INY 
C1/D273: B7 70        LDA [$70],Y
C1/D275: F0 04        BEQ $D27B
C1/D277: 9C 72 DB     STZ $DB72
C1/D27A: 60           RTS 
C1/D27B: A9 01        LDA #$01
C1/D27D: 8D 72 DB     STA $DB72
C1/D280: 60           RTS 
C1/D281: C8           INY 
C1/D282: A9 02        LDA #$02
C1/D284: 8D 85 BC     STA $BC85
C1/D287: B7 70        LDA [$70],Y
C1/D289: 29 1F        AND #$1F
C1/D28B: 85 7E        STA $7E
C1/D28D: B7 70        LDA [$70],Y
C1/D28F: 30 38        BMI $D2C9
C1/D291: 29 40        AND #$40
C1/D293: F0 26        BEQ $D2BB
C1/D295: B7 70        LDA [$70],Y
C1/D297: 29 20        AND #$20
C1/D299: F0 10        BEQ $D2AB
C1/D29B: AD 88 BC     LDA $BC88
C1/D29E: 38           SEC 
C1/D29F: E5 7E        SBC $7E
C1/D2A1: 8D 88 BC     STA $BC88
C1/D2A4: 8D 89 BC     STA $BC89
C1/D2A7: 8D 8A BC     STA $BC8A
C1/D2AA: 60           RTS 
C1/D2AB: AD 88 BC     LDA $BC88
C1/D2AE: 18           CLC 
C1/D2AF: 65 7E        ADC $7E
C1/D2B1: 8D 88 BC     STA $BC88
C1/D2B4: 8D 89 BC     STA $BC89
C1/D2B7: 8D 8A BC     STA $BC8A
C1/D2BA: 60           RTS 
C1/D2BB: B7 70        LDA [$70],Y
C1/D2BD: 09 E0        ORA #$E0
C1/D2BF: 8D 88 BC     STA $BC88
C1/D2C2: 8D 89 BC     STA $BC89
C1/D2C5: 8D 8A BC     STA $BC8A
C1/D2C8: 60           RTS 
C1/D2C9: 9C 85 BC     STZ $BC85
C1/D2CC: 7B           TDC 
C1/D2CD: 4C BD D2     JMP $D2BD

C1/D2D0: C8           INY 
C1/D2D1: B7 70        LDA [$70],Y
C1/D2D3: D0 17        BNE $D2EC
C1/D2D5: DA           PHX 
C1/D2D6: 20 91 E3     JSR $E391
C1/D2D9: 18           CLC 
C1/D2DA: 69 40        ADC #$40
C1/D2DC: 9D BB CE     STA $CEBB,X
C1/D2DF: A9 60        LDA #$60
C1/D2E1: 9D FB CD     STA $CDFB,X
C1/D2E4: A9 30        LDA #$30
C1/D2E6: 9D 3B CE     STA $CE3B,X
C1/D2E9: 4C C0 E3     JMP $E3C0
C1/D2EC: DA           PHX 
C1/D2ED: 20 89 E5     JSR $E589
C1/D2F0: 20 5B E4     JSR $E45B
C1/D2F3: A6 84        LDX $84
C1/D2F5: A9 08        LDA #$08
C1/D2F7: 20 96 09     JSR $0996
C1/D2FA: B7 70        LDA [$70],Y
C1/D2FC: C9 02        CMP #$02
C1/D2FE: D0 20        BNE $D320
C1/D300: BD FB CD     LDA $CDFB,X
C1/D303: D0 05        BNE $D30A
C1/D305: A9 40        LDA #$40
C1/D307: 9D FB CD     STA $CDFB,X
C1/D30A: DE FB CD     DEC $CDFB,X
C1/D30D: DE FB CD     DEC $CDFB,X
C1/D310: BD 3B CE     LDA $CE3B,X
C1/D313: D0 05        BNE $D31A
C1/D315: A9 20        LDA #$20
C1/D317: 9D 3B CE     STA $CE3B,X
C1/D31A: DE 3B CE     DEC $CE3B,X
C1/D31D: DE 3B CE     DEC $CE3B,X
C1/D320: A6 78        LDX $78
C1/D322: BD E3 D1     LDA $D1E3,X
C1/D325: 1A           INC 
C1/D326: 29 01        AND #$01
C1/D328: 9D E3 D1     STA $D1E3,X
C1/D32B: A6 78        LDX $78
C1/D32D: A5 86        LDA $86
C1/D32F: 9D DC D1     STA $D1DC,X
C1/D332: A5 87        LDA $87
C1/D334: 9D DD D1     STA $D1DD,X
C1/D337: FA           PLX 
C1/D338: 60           RTS 
C1/D339: 03 03        ORA $03,S
C1/D33B: 02 02        COP $02
C1/D33D: 02 02        COP $02
C1/D33F: 01 01        ORA ($01,X)
C1/D341: 01 00        ORA ($00,X)
C1/D343: 01 00        ORA ($00,X)
C1/D345: 01 00        ORA ($00,X)
C1/D347: 00 01        BRK $01
C1/D349: 00 DA        BRK $DA
C1/D34B: 5A           PHY 
C1/D34C: C2 20        REP #$20
C1/D34E: 7B           TDC 
C1/D34F: A8           TAY 
C1/D350: B9 70 00     LDA $0070,Y
C1/D353: 48           PHA 
C1/D354: C8           INY 
C1/D355: C8           INY 
C1/D356: C0 0C 00     CPY #$000C
C1/D359: D0 F5        BNE $D350
C1/D35B: 7B           TDC 
C1/D35C: E2 20        SEP #$20
C1/D35E: AD 84 BC     LDA $BC84
C1/D361: 09 01        ORA #$01
C1/D363: 8D 84 BC     STA $BC84
C1/D366: 9C 7B CE     STZ $CE7B
C1/D369: 9C 7C CE     STZ $CE7C
C1/D36C: 20 F2 02     JSR $02F2       ; wait one frame
C1/D36F: EE 7B CE     INC $CE7B
C1/D372: AD 7B CE     LDA $CE7B
C1/D375: 29 03        AND #$03
C1/D377: D0 F3        BNE $D36C
C1/D379: AD 7C CE     LDA $CE7C
C1/D37C: AA           TAX 
C1/D37D: BF 39 D3 C1  LDA $C1D339,X
C1/D381: C2 20        REP #$20
C1/D383: 85 70        STA $70
C1/D385: 7B           TDC 
C1/D386: AA           TAX 
C1/D387: BD 37 A9     LDA $A937,X
C1/D38A: 18           CLC 
C1/D38B: 65 70        ADC $70
C1/D38D: 9D 37 A9     STA $A937,X
C1/D390: BD B7 A9     LDA $A9B7,X
C1/D393: 38           SEC 
C1/D394: E5 70        SBC $70
C1/D396: 9D B7 A9     STA $A9B7,X
C1/D399: E8           INX 
C1/D39A: E8           INX 
C1/D39B: E8           INX 
C1/D39C: E8           INX 
C1/D39D: E0 80 00     CPX #$0080
C1/D3A0: D0 E5        BNE $D387
C1/D3A2: 7B           TDC 
C1/D3A3: E2 20        SEP #$20
C1/D3A5: EE 7C CE     INC $CE7C
C1/D3A8: AD 7C CE     LDA $CE7C
C1/D3AB: C9 10        CMP #$10
C1/D3AD: D0 BD        BNE $D36C
C1/D3AF: A5 DE        LDA $DE
C1/D3B1: 85 70        STA $70
C1/D3B3: A9 02        LDA #$02
C1/D3B5: 20 02 76     JSR $7602
C1/D3B8: C2 20        REP #$20
C1/D3BA: 7B           TDC 
C1/D3BB: AA           TAX 
C1/D3BC: 9E 37 A9     STZ $A937,X
C1/D3BF: E8           INX 
C1/D3C0: E8           INX 
C1/D3C1: E8           INX 
C1/D3C2: E8           INX 
C1/D3C3: E0 00 01     CPX #$0100
C1/D3C6: D0 F4        BNE $D3BC
C1/D3C8: AD 84 BC     LDA $BC84
C1/D3CB: 29 FE 00     AND #$00FE
C1/D3CE: 8D 84 BC     STA $BC84
C1/D3D1: A0 0C 00     LDY #$000C
C1/D3D4: 68           PLA 
C1/D3D5: 99 6E 00     STA $006E,Y
C1/D3D8: 88           DEY 
C1/D3D9: 88           DEY 
C1/D3DA: D0 F8        BNE $D3D4
C1/D3DC: 7B           TDC 
C1/D3DD: E2 20        SEP #$20
C1/D3DF: 7A           PLY 
C1/D3E0: FA           PLX 
C1/D3E1: 60           RTS 
C1/D3E2: DA           PHX 
C1/D3E3: 8A           TXA 
C1/D3E4: 4A           LSR 
C1/D3E5: 4A           LSR 
C1/D3E6: 4A           LSR 
C1/D3E7: 4A           LSR 
C1/D3E8: AA           TAX 
C1/D3E9: C8           INY 
C1/D3EA: B7 70        LDA [$70],Y
C1/D3EC: D0 09        BNE $D3F7
C1/D3EE: 9E FB CD     STZ $CDFB,X
C1/D3F1: 20 96 FC     JSR $FC96       ; generate random number
C1/D3F4: 9D 7B CE     STA $CE7B,X
C1/D3F7: BD FB CD     LDA $CDFB,X
C1/D3FA: C9 80        CMP #$80
C1/D3FC: B0 06        BCS $D404
C1/D3FE: 18           CLC 
C1/D3FF: 69 04        ADC #$04
C1/D401: 9D FB CD     STA $CDFB,X
C1/D404: BD 7B CE     LDA $CE7B,X
C1/D407: 18           CLC 
C1/D408: 69 10        ADC #$10
C1/D40A: 9D 7B CE     STA $CE7B,X
C1/D40D: 20 CA 09     JSR $09CA
C1/D410: FA           PLX 
C1/D411: 9D DD D1     STA $D1DD,X
C1/D414: 20 96 FC     JSR $FC96       ; generate random number
C1/D417: 29 03        AND #$03
C1/D419: 9D E3 D1     STA $D1E3,X
C1/D41C: 60           RTS 

C1/D41D: DA           PHX 
C1/D41E: C8           INY 
C1/D41F: B7 70        LDA [$70],Y
C1/D421: 29 07        AND #$07
C1/D423: D0 18        BNE $D43D
C1/D425: 7B           TDC 
C1/D426: AA           TAX 
C1/D427: 8A           TXA 
C1/D428: 86 80        STX $80
C1/D42A: 20 09 DF     JSR $DF09
C1/D42D: 90 06        BCC $D435
C1/D42F: DA           PHX 
C1/D430: 7B           TDC 
C1/D431: 20 A6 1A     JSR $1AA6
C1/D434: FA           PLX 
C1/D435: E8           INX 
C1/D436: E0 08 00     CPX #$0008
C1/D439: D0 EC        BNE $D427
C1/D43B: FA           PLX 
C1/D43C: 60           RTS 
C1/D43D: 7B           TDC 
C1/D43E: AA           TAX 
C1/D43F: 86 80        STX $80
C1/D441: 8A           TXA 
C1/D442: 20 09 DF     JSR $DF09
C1/D445: 90 07        BCC $D44E
C1/D447: DA           PHX 
C1/D448: A9 0C        LDA #$0C
C1/D44A: 20 A6 1A     JSR $1AA6
C1/D44D: FA           PLX 
C1/D44E: E8           INX 
C1/D44F: E0 08 00     CPX #$0008
C1/D452: D0 EB        BNE $D43F
C1/D454: AD E2 D3     LDA $D3E2
C1/D457: 09 80        ORA #$80
C1/D459: 8D E2 D3     STA $D3E2
C1/D45C: B7 70        LDA [$70],Y
C1/D45E: 4A           LSR 
C1/D45F: 4A           LSR 
C1/D460: 4A           LSR 
C1/D461: 29 0F        AND #$0F
C1/D463: A2 00 00     LDX #$0000
C1/D466: 20 D1 DE     JSR $DED1
C1/D469: EE 56 DB     INC $DB56
C1/D46C: FA           PLX 
C1/D46D: 60           RTS 

C1/D46E: 10 10        BPL $D480
C1/D470: 50 50        BVC $D4C2
C1/D472: 90 90        BCC $D404
C1/D474: D0 D0        BNE $D446
C1/D476: DA           PHX 
C1/D477: 8A           TXA 
C1/D478: 4A           LSR 
C1/D479: 4A           LSR 
C1/D47A: 4A           LSR 
C1/D47B: 4A           LSR 
C1/D47C: AA           TAX 
C1/D47D: C8           INY 
C1/D47E: B7 70        LDA [$70],Y
C1/D480: D0 1C        BNE $D49E
C1/D482: BF 6E D4 C1  LDA $C1D46E,X
C1/D486: 9D 7B CE     STA $CE7B,X
C1/D489: A9 40        LDA #$40
C1/D48B: 9D FB CD     STA $CDFB,X
C1/D48E: AD 37 D2     LDA $D237
C1/D491: 09 20        ORA #$20
C1/D493: 8D 37 D2     STA $D237
C1/D496: AD 57 D2     LDA $D257
C1/D499: 09 20        ORA #$20
C1/D49B: 8D 57 D2     STA $D257
C1/D49E: 8A           TXA 
C1/D49F: C9 04        CMP #$04
C1/D4A1: 90 0E        BCC $D4B1
C1/D4A3: BD 7B CE     LDA $CE7B,X
C1/D4A6: 18           CLC 
C1/D4A7: 69 04        ADC #$04
C1/D4A9: 09 80        ORA #$80
C1/D4AB: 9D 7B CE     STA $CE7B,X
C1/D4AE: 4C BC D4     JMP $D4BC
C1/D4B1: BD 7B CE     LDA $CE7B,X
C1/D4B4: 18           CLC 
C1/D4B5: 69 04        ADC #$04
C1/D4B7: 29 7F        AND #$7F
C1/D4B9: 9D 7B CE     STA $CE7B,X
C1/D4BC: BD FB CD     LDA $CDFB,X
C1/D4BF: 0A           ASL 
C1/D4C0: 85 80        STA $80
C1/D4C2: BD 7B CE     LDA $CE7B,X
C1/D4C5: 18           CLC 
C1/D4C6: 69 40        ADC #$40
C1/D4C8: 20 00 0A     JSR $0A00
C1/D4CB: FA           PLX 
C1/D4CC: 9D DC D1     STA $D1DC,X
C1/D4CF: 60           RTS 
C1/D4D0: C8           INY 
C1/D4D1: B7 70        LDA [$70],Y
C1/D4D3: D0 0D        BNE $D4E2
C1/D4D5: A9 10        LDA #$10
C1/D4D7: 8D 85 BC     STA $BC85
C1/D4DA: A9 1F        LDA #$1F
C1/D4DC: 8D 6C F8     STA $F86C
C1/D4DF: 4C FE B3     JMP $B3FE
C1/D4E2: AD 6C F8     LDA $F86C
C1/D4E5: 20 FE B3     JSR $B3FE
C1/D4E8: AD 6C F8     LDA $F86C
C1/D4EB: F0 03        BEQ $D4F0
C1/D4ED: CE 6C F8     DEC $F86C
C1/D4F0: 60           RTS 
C1/D4F1: C8           INY 
C1/D4F2: B7 70        LDA [$70],Y
C1/D4F4: F0 18        BEQ $D50E
C1/D4F6: 8D FB CD     STA $CDFB
C1/D4F9: 9C 7B CE     STZ $CE7B
C1/D4FC: C2 20        REP #$20
C1/D4FE: AD 62 DB     LDA $DB62
C1/D501: 8D D8 D5     STA $D5D8
C1/D504: AD 64 DB     LDA $DB64
C1/D507: 8D DA D5     STA $D5DA
C1/D50A: 7B           TDC 
C1/D50B: E2 20        SEP #$20
C1/D50D: 60           RTS 
C1/D50E: DA           PHX 
C1/D50F: AD FB CD     LDA $CDFB
C1/D512: AA           TAX 
C1/D513: 86 80        STX $80
C1/D515: AD 7B CE     LDA $CE7B
C1/D518: 09 80        ORA #$80
C1/D51A: 20 59 0B     JSR $0B59
C1/D51D: C2 20        REP #$20
C1/D51F: A5 84        LDA $84
C1/D521: 18           CLC 
C1/D522: 6D DA D5     ADC $D5DA
C1/D525: 8D 64 DB     STA $DB64
C1/D528: 7B           TDC 
C1/D529: E2 20        SEP #$20
C1/D52B: AD 7B CE     LDA $CE7B
C1/D52E: 18           CLC 
C1/D52F: 69 08        ADC #$08
C1/D531: 8D 7B CE     STA $CE7B
C1/D534: FA           PLX 
C1/D535: 60           RTS 
C1/D536: C8           INY 
C1/D537: B7 70        LDA [$70],Y
C1/D539: 29 3F        AND #$3F
C1/D53B: 85 7E        STA $7E
C1/D53D: 64 7F        STZ $7F
C1/D53F: B7 70        LDA [$70],Y
C1/D541: 29 C0        AND #$C0
C1/D543: F0 17        BEQ $D55C
C1/D545: C9 40        CMP #$40
C1/D547: F0 22        BEQ $D56B
C1/D549: C9 80        CMP #$80
C1/D54B: F0 2D        BEQ $D57A
C1/D54D: C2 20        REP #$20
C1/D54F: AD 64 DB     LDA $DB64
C1/D552: 38           SEC 
C1/D553: E5 7E        SBC $7E
C1/D555: 8D 64 DB     STA $DB64
C1/D558: 7B           TDC 
C1/D559: E2 20        SEP #$20
C1/D55B: 60           RTS 
C1/D55C: C2 20        REP #$20
C1/D55E: AD 62 DB     LDA $DB62
C1/D561: 18           CLC 
C1/D562: 65 7E        ADC $7E
C1/D564: 8D 62 DB     STA $DB62
C1/D567: 7B           TDC 
C1/D568: E2 20        SEP #$20
C1/D56A: 60           RTS 
C1/D56B: C2 20        REP #$20
C1/D56D: AD 62 DB     LDA $DB62
C1/D570: 38           SEC 
C1/D571: E5 7E        SBC $7E
C1/D573: 8D 62 DB     STA $DB62
C1/D576: 7B           TDC 
C1/D577: E2 20        SEP #$20
C1/D579: 60           RTS 
C1/D57A: C2 20        REP #$20
C1/D57C: AD 64 DB     LDA $DB64
C1/D57F: 18           CLC 
C1/D580: 65 7E        ADC $7E
C1/D582: 8D 64 DB     STA $DB64
C1/D585: 7B           TDC 
C1/D586: E2 20        SEP #$20
C1/D588: 60           RTS 
C1/D589: BD DF D1     LDA $D1DF,X
C1/D58C: 85 A6        STA $A6
C1/D58E: BD E1 D1     LDA $D1E1,X
C1/D591: 85 A7        STA $A7
C1/D593: BD DC D5     LDA $D5DC,X
C1/D596: 85 A8        STA $A8
C1/D598: BD DE D5     LDA $D5DE,X
C1/D59B: 85 A9        STA $A9
C1/D59D: C2 20        REP #$20
C1/D59F: BD DF D1     LDA $D1DF,X
C1/D5A2: 9D DC D5     STA $D5DC,X
C1/D5A5: BD E1 D1     LDA $D1E1,X
C1/D5A8: 9D DE D5     STA $D5DE,X
C1/D5AB: 7B           TDC 
C1/D5AC: E2 20        SEP #$20
C1/D5AE: 4C 6C E0     JMP $E06C
C1/D5B1: BD E6 D3     LDA $D3E6,X
C1/D5B4: 18           CLC 
C1/D5B5: 69 04        ADC #$04
C1/D5B7: 9D E6 D3     STA $D3E6,X
C1/D5BA: C2 20        REP #$20
C1/D5BC: BD E4 D3     LDA $D3E4,X
C1/D5BF: 38           SEC 
C1/D5C0: E9 04 00     SBC #$0004
C1/D5C3: 9D E4 D3     STA $D3E4,X
C1/D5C6: BD E4 D3     LDA $D3E4,X
C1/D5C9: 30 17        BMI $D5E2
C1/D5CB: 7B           TDC 
C1/D5CC: E2 20        SEP #$20
C1/D5CE: 88           DEY 
C1/D5CF: 88           DEY 
C1/D5D0: 88           DEY 
C1/D5D1: 20 BC E0     JSR $E0BC
C1/D5D4: FE E1 D5     INC $D5E1,X
C1/D5D7: BD E1 D5     LDA $D5E1,X
C1/D5DA: 29 04        AND #$04
C1/D5DC: 4A           LSR 
C1/D5DD: 4A           LSR 
C1/D5DE: 9D E3 D1     STA $D1E3,X
C1/D5E1: 60           RTS 
C1/D5E2: 7B           TDC 
C1/D5E3: E2 20        SEP #$20
C1/D5E5: 9E E3 D1     STZ $D1E3,X
C1/D5E8: 60           RTS 
C1/D5E9: BD E6 D3     LDA $D3E6,X
C1/D5EC: 18           CLC 
C1/D5ED: 69 08        ADC #$08
C1/D5EF: 9D E6 D3     STA $D3E6,X
C1/D5F2: C2 20        REP #$20
C1/D5F4: BD E4 D3     LDA $D3E4,X
C1/D5F7: 38           SEC 
C1/D5F8: E9 08 00     SBC #$0008
C1/D5FB: 9D E4 D3     STA $D3E4,X
C1/D5FE: BD E4 D3     LDA $D3E4,X
C1/D601: 30 09        BMI $D60C
C1/D603: 7B           TDC 
C1/D604: E2 20        SEP #$20
C1/D606: 88           DEY 
C1/D607: 88           DEY 
C1/D608: 20 BC E0     JSR $E0BC
C1/D60B: 60           RTS 
C1/D60C: 7B           TDC 
C1/D60D: E2 20        SEP #$20
C1/D60F: 60           RTS 
C1/D610: A9 20        LDA #$20
C1/D612: 9D E4 D5     STA $D5E4,X
C1/D615: A9 80        LDA #$80
C1/D617: 9D E5 D5     STA $D5E5,X
C1/D61A: C2 20        REP #$20
C1/D61C: BD DF D1     LDA $D1DF,X
C1/D61F: 9D D8 D5     STA $D5D8,X
C1/D622: BD E1 D1     LDA $D1E1,X
C1/D625: 9D DA D5     STA $D5DA,X
C1/D628: 7B           TDC 
C1/D629: E2 20        SEP #$20
C1/D62B: 5A           PHY 
C1/D62C: DA           PHX 
C1/D62D: 64 81        STZ $81
C1/D62F: BD E4 D5     LDA $D5E4,X
C1/D632: 85 80        STA $80
C1/D634: BD E5 D5     LDA $D5E5,X
C1/D637: 20 59 0B     JSR $0B59
C1/D63A: FA           PLX 
C1/D63B: C2 20        REP #$20
C1/D63D: A5 84        LDA $84
C1/D63F: 18           CLC 
C1/D640: 7D D8 D5     ADC $D5D8,X
C1/D643: 9D DF D1     STA $D1DF,X
C1/D646: 7B           TDC 
C1/D647: E2 20        SEP #$20
C1/D649: BD E5 D5     LDA $D5E5,X
C1/D64C: 18           CLC 
C1/D64D: 69 02        ADC #$02
C1/D64F: 9D E5 D5     STA $D5E5,X
C1/D652: 18           CLC 
C1/D653: 69 40        ADC #$40
C1/D655: C9 80        CMP #$80
C1/D657: B0 07        BCS $D660
C1/D659: A9 02        LDA #$02
C1/D65B: 9D E3 D1     STA $D1E3,X
C1/D65E: 80 03        BRA $D663
C1/D660: 9E E3 D1     STZ $D1E3,X
C1/D663: 7A           PLY 
C1/D664: 60           RTS 
C1/D665: DA           PHX 
C1/D666: 20 96 FC     JSR $FC96       ; generate random number
C1/D669: 29 0F        AND #$0F
C1/D66B: 85 84        STA $84
C1/D66D: 64 85        STZ $85
C1/D66F: C2 20        REP #$20
C1/D671: A5 84        LDA $84
C1/D673: 18           CLC 
C1/D674: 7D DF D1     ADC $D1DF,X
C1/D677: 38           SEC 
C1/D678: E9 08 00     SBC #$0008
C1/D67B: 85 80        STA $80
C1/D67D: A5 84        LDA $84
C1/D67F: 18           CLC 
C1/D680: 7D E1 D1     ADC $D1E1,X
C1/D683: 38           SEC 
C1/D684: E9 08 00     SBC #$0008
C1/D687: 85 82        STA $82
C1/D689: 7B           TDC 
C1/D68A: E2 20        SEP #$20
C1/D68C: A2 80 00     LDX #$0080
C1/D68F: BD E7 D3     LDA $D3E7,X
C1/D692: D0 1B        BNE $D6AF
C1/D694: A9 03        LDA #$03
C1/D696: 9D DF D3     STA $D3DF,X
C1/D699: A9 01        LDA #$01
C1/D69B: 9D E7 D3     STA $D3E7,X
C1/D69E: C2 20        REP #$20
C1/D6A0: A5 80        LDA $80
C1/D6A2: 9D DF D1     STA $D1DF,X
C1/D6A5: A5 82        LDA $82
C1/D6A7: 9D E1 D1     STA $D1E1,X
C1/D6AA: 7B           TDC 
C1/D6AB: E2 20        SEP #$20
C1/D6AD: FA           PLX 
C1/D6AE: 60           RTS 
C1/D6AF: C2 20        REP #$20
C1/D6B1: 8A           TXA 
C1/D6B2: 18           CLC 
C1/D6B3: 69 10 00     ADC #$0010
C1/D6B6: AA           TAX 
C1/D6B7: 7B           TDC 
C1/D6B8: E2 20        SEP #$20
C1/D6BA: E0 00 02     CPX #$0200
C1/D6BD: D0 D0        BNE $D68F
C1/D6BF: FA           PLX 
C1/D6C0: 60           RTS 
C1/D6C1: 5A           PHY 
C1/D6C2: DA           PHX 
C1/D6C3: 8A           TXA 
C1/D6C4: 4A           LSR 
C1/D6C5: 4A           LSR 
C1/D6C6: 4A           LSR 
C1/D6C7: 4A           LSR 
C1/D6C8: AA           TAX 
C1/D6C9: BD 7B CE     LDA $CE7B,X
C1/D6CC: 18           CLC 
C1/D6CD: 69 08        ADC #$08
C1/D6CF: 09 80        ORA #$80
C1/D6D1: 9D 7B CE     STA $CE7B,X
C1/D6D4: 20 CA 09     JSR $09CA
C1/D6D7: FA           PLX 
C1/D6D8: 9D DD D1     STA $D1DD,X
C1/D6DB: BD DC D1     LDA $D1DC,X
C1/D6DE: 18           CLC 
C1/D6DF: 7D E4 D5     ADC $D5E4,X
C1/D6E2: 9D DC D1     STA $D1DC,X
C1/D6E5: 7A           PLY 
C1/D6E6: 60           RTS 
C1/D6E7: FD FE FF     SBC $FFFE,X
C1/D6EA: 01 02        ORA ($02,X)
C1/D6EC: 03 48        ORA $48,S
C1/D6EE: 48           PHA 
C1/D6EF: 40           RTI 
C1/D6F0: 40           RTI 
C1/D6F1: 38           SEC 
C1/D6F2: 30 DA        BMI $D6CE
C1/D6F4: 86 7E        STX $7E
C1/D6F6: 8A           TXA 
C1/D6F7: 4A           LSR 
C1/D6F8: 4A           LSR 
C1/D6F9: 4A           LSR 
C1/D6FA: 4A           LSR 
C1/D6FB: 85 82        STA $82
C1/D6FD: AA           TAX 
C1/D6FE: BF ED D6 C1  LDA $C1D6ED,X
C1/D702: 9D FB CD     STA $CDFB,X
C1/D705: 9E 7B CE     STZ $CE7B,X
C1/D708: BF E7 D6 C1  LDA $C1D6E7,X
C1/D70C: A6 7E        LDX $7E
C1/D70E: 9D E4 D5     STA $D5E4,X
C1/D711: BD E2 D3     LDA $D3E2,X
C1/D714: 29 80        AND #$80
C1/D716: 05 82        ORA $82
C1/D718: 9D E2 D3     STA $D3E2,X
C1/D71B: 9E DD D1     STZ $D1DD,X
C1/D71E: 9E DC D1     STZ $D1DC,X
C1/D721: FA           PLX 
C1/D722: 60           RTS 
C1/D723: 5A           PHY 
C1/D724: DA           PHX 
C1/D725: 8A           TXA 
C1/D726: 4A           LSR 
C1/D727: 4A           LSR 
C1/D728: 4A           LSR 
C1/D729: 4A           LSR 
C1/D72A: 4A           LSR 
C1/D72B: AA           TAX 
C1/D72C: A9 08        LDA #$08
C1/D72E: 20 96 09     JSR $0996
C1/D731: 20 CA 09     JSR $09CA
C1/D734: FA           PLX 
C1/D735: 9D DC D1     STA $D1DC,X
C1/D738: 7A           PLY 
C1/D739: 60           RTS 
C1/D73A: 30 90        BMI $D6CC
C1/D73C: 40           RTI 
C1/D73D: A0 88 88     LDY #$8888
C1/D740: 68           PLA 
C1/D741: 68           PLA 
C1/D742: DA           PHX 
C1/D743: 86 7E        STX $7E
C1/D745: 8A           TXA 
C1/D746: 4A           LSR 
C1/D747: 4A           LSR 
C1/D748: 4A           LSR 
C1/D749: 4A           LSR 
C1/D74A: 4A           LSR 
C1/D74B: AA           TAX 
C1/D74C: A9 08        LDA #$08
C1/D74E: 9D FB CD     STA $CDFB,X
C1/D751: 20 96 FC     JSR $FC96       ; generate random number
C1/D754: 9D 7B CE     STA $CE7B,X
C1/D757: BF 3A D7 C1  LDA $C1D73A,X
C1/D75B: 85 80        STA $80
C1/D75D: BF 3E D7 C1  LDA $C1D73E,X
C1/D761: 85 81        STA $81
C1/D763: A6 7E        LDX $7E
C1/D765: A5 80        LDA $80
C1/D767: 9D DF D1     STA $D1DF,X
C1/D76A: 9E E0 D1     STZ $D1E0,X
C1/D76D: A5 81        LDA $81
C1/D76F: 9D E1 D1     STA $D1E1,X
C1/D772: 9E E2 D1     STZ $D1E2,X
C1/D775: FA           PLX 
C1/D776: 60           RTS 
C1/D777: BD E7 D1     LDA $D1E7,X
C1/D77A: 09 20        ORA #$20
C1/D77C: 9D E7 D1     STA $D1E7,X
C1/D77F: 60           RTS 
C1/D780: BD E7 D1     LDA $D1E7,X
C1/D783: 29 DF        AND #$DF
C1/D785: 9D E7 D1     STA $D1E7,X
C1/D788: 60           RTS 
C1/D789: 5A           PHY 
C1/D78A: DA           PHX 
C1/D78B: 8A           TXA 
C1/D78C: 4A           LSR 
C1/D78D: 4A           LSR 
C1/D78E: 4A           LSR 
C1/D78F: 4A           LSR 
C1/D790: AA           TAX 
C1/D791: BD 7B CE     LDA $CE7B,X
C1/D794: 48           PHA 
C1/D795: A9 08        LDA #$08
C1/D797: 20 96 09     JSR $0996
C1/D79A: 20 CA 09     JSR $09CA
C1/D79D: 85 7E        STA $7E
C1/D79F: 68           PLA 
C1/D7A0: 18           CLC 
C1/D7A1: 69 40        ADC #$40
C1/D7A3: 85 80        STA $80
C1/D7A5: FA           PLX 
C1/D7A6: A5 7E        LDA $7E
C1/D7A8: 9D DC D1     STA $D1DC,X
C1/D7AB: 7A           PLY 
C1/D7AC: 60           RTS 

; [ animation command $DD:  ]

C1/D7AD: DA           PHX 
C1/D7AE: 8A           TXA 
C1/D7AF: 4A           LSR 
C1/D7B0: 4A           LSR 
C1/D7B1: 4A           LSR 
C1/D7B2: 4A           LSR 
C1/D7B3: AA           TAX 
C1/D7B4: A9 40        LDA #$40
C1/D7B6: 9D FB CD     STA $CDFB,X
C1/D7B9: A9 80        LDA #$80
C1/D7BB: 9D 7B CE     STA $CE7B,X
C1/D7BE: FA           PLX 
C1/D7BF: A9 F0        LDA #$F0
C1/D7C1: 9D DF D1     STA $D1DF,X
C1/D7C4: 9E E0 D1     STZ $D1E0,X
C1/D7C7: A9 60        LDA #$60
C1/D7C9: 9D E1 D1     STA $D1E1,X
C1/D7CC: 9E E2 D1     STZ $D1E2,X
C1/D7CF: 60           RTS 
C1/D7D0: 5A           PHY 
C1/D7D1: DA           PHX 
C1/D7D2: 8A           TXA 
C1/D7D3: 4A           LSR 
C1/D7D4: 4A           LSR 
C1/D7D5: 4A           LSR 
C1/D7D6: 4A           LSR 
C1/D7D7: AA           TAX 
C1/D7D8: A9 20        LDA #$20
C1/D7DA: 20 96 09     JSR $0996
C1/D7DD: 20 CA 09     JSR $09CA
C1/D7E0: FA           PLX 
C1/D7E1: 9D DC D1     STA $D1DC,X
C1/D7E4: 7A           PLY 
C1/D7E5: 60           RTS 
C1/D7E6: DA           PHX 
C1/D7E7: 86 7E        STX $7E
C1/D7E9: 8A           TXA 
C1/D7EA: 4A           LSR 
C1/D7EB: 4A           LSR 
C1/D7EC: 4A           LSR 
C1/D7ED: 4A           LSR 
C1/D7EE: AA           TAX 
C1/D7EF: BF 2B D8 C1  LDA $C1D82B,X
C1/D7F3: 9D FB CD     STA $CDFB,X
C1/D7F6: BF 33 D8 C1  LDA $C1D833,X
C1/D7FA: 9D 7B CE     STA $CE7B,X
C1/D7FD: BF 23 D8 C1  LDA $C1D823,X
C1/D801: 85 80        STA $80
C1/D803: AD D3 DB     LDA $DBD3
C1/D806: F0 07        BEQ $D80F
C1/D808: A5 80        LDA $80
C1/D80A: 18           CLC 
C1/D80B: 69 20        ADC #$20
C1/D80D: 85 80        STA $80
C1/D80F: A6 7E        LDX $7E
C1/D811: A9 F0        LDA #$F0
C1/D813: 9D DF D1     STA $D1DF,X
C1/D816: 9E E0 D1     STZ $D1E0,X
C1/D819: A5 80        LDA $80
C1/D81B: 9D E1 D1     STA $D1E1,X
C1/D81E: 9E E2 D1     STZ $D1E2,X
C1/D821: FA           PLX 
C1/D822: 60           RTS 
C1/D823: 90 80        BCC $D7A5
C1/D825: 70 60        BVS $D887
C1/D827: 50 40        BVC $D869
C1/D829: 30 20        BMI $D84B
C1/D82B: 14 18        TRB $18
C1/D82D: 1C 20 24     TRB $2420
C1/D830: 28           PLP 
C1/D831: 2C 30 00     BIT $0030
C1/D834: 10 20        BPL $D856
C1/D836: 30 40        BMI $D878
C1/D838: 50 60        BVC $D89A
C1/D83A: 70 5A        BVS $D896
C1/D83C: DA           PHX 
C1/D83D: 86 7E        STX $7E
C1/D83F: BD E0 D1     LDA $D1E0,X
C1/D842: D0 35        BNE $D879
C1/D844: BD DF D1     LDA $D1DF,X
C1/D847: 4A           LSR 
C1/D848: 4A           LSR 
C1/D849: 4A           LSR 
C1/D84A: 4A           LSR 
C1/D84B: 85 82        STA $82
C1/D84D: 8A           TXA 
C1/D84E: 4A           LSR 
C1/D84F: 4A           LSR 
C1/D850: 4A           LSR 
C1/D851: 4A           LSR 
C1/D852: 85 80        STA $80
C1/D854: 0A           ASL 
C1/D855: 0A           ASL 
C1/D856: A8           TAY 
C1/D857: B9 9E 7B     LDA $7B9E,Y
C1/D85A: 30 1D        BMI $D879
C1/D85C: A5 80        LDA $80
C1/D85E: A8           TAY 
C1/D85F: B9 36 D0     LDA $D036,Y
C1/D862: 4A           LSR 
C1/D863: 4A           LSR 
C1/D864: 4A           LSR 
C1/D865: 4A           LSR 
C1/D866: C5 82        CMP $82
C1/D868: D0 0F        BNE $D879
C1/D86A: 8A           TXA 
C1/D86B: 4A           LSR 
C1/D86C: 4A           LSR 
C1/D86D: 4A           LSR 
C1/D86E: 4A           LSR 
C1/D86F: 09 80        ORA #$80
C1/D871: 9D E2 D3     STA $D3E2,X
C1/D874: FA           PLX 
C1/D875: 7A           PLY 
C1/D876: 4C 24 DF     JMP $DF24
C1/D879: FA           PLX 
C1/D87A: 7A           PLY 
C1/D87B: C8           INY 
C1/D87C: 60           RTS 
C1/D87D: F0 58        BEQ $D8D7
C1/D87F: C8           INY 
C1/D880: 68           PLA 
C1/D881: F9 70 D0     SBC $D070,Y
C1/D884: 80 20        BRA $D8A6
C1/D886: 58           CLI 
C1/D887: 40           RTI 
C1/D888: 68           PLA 
C1/D889: 29 70        AND #$70
C1/D88B: 48           PHA 
C1/D88C: 80 F0        BRA $D87E
C1/D88E: 28           PLP 
C1/D88F: F0 58        BEQ $D8E9
C1/D891: F9 70 F0     SBC $F070,Y
C1/D894: 80 DA        BRA $D870
C1/D896: 86 7E        STX $7E
C1/D898: 8A           TXA 
C1/D899: 4A           LSR 
C1/D89A: 4A           LSR 
C1/D89B: 4A           LSR 
C1/D89C: 29 FE        AND #$FE
C1/D89E: AA           TAX 
C1/D89F: BF 8D D8 C1  LDA $C1D88D,X
C1/D8A3: 85 80        STA $80
C1/D8A5: BF 8E D8 C1  LDA $C1D88E,X
C1/D8A9: 85 81        STA $81
C1/D8AB: A6 7E        LDX $7E
C1/D8AD: A5 80        LDA $80
C1/D8AF: 9D DF D1     STA $D1DF,X
C1/D8B2: 9E E0 D1     STZ $D1E0,X
C1/D8B5: A5 81        LDA $81
C1/D8B7: 9D E1 D1     STA $D1E1,X
C1/D8BA: 9E E2 D1     STZ $D1E2,X
C1/D8BD: FA           PLX 
C1/D8BE: 60           RTS 
C1/D8BF: C8           INY 
C1/D8C0: B7 70        LDA [$70],Y
C1/D8C2: 0A           ASL 
C1/D8C3: 0A           ASL 
C1/D8C4: 85 7E        STA $7E
C1/D8C6: AD 0D D1     LDA $D10D
C1/D8C9: 29 E3        AND #$E3
C1/D8CB: 05 7E        ORA $7E
C1/D8CD: 8D 0D D1     STA $D10D
C1/D8D0: 60           RTS 
C1/D8D1: C8           INY 
C1/D8D2: B7 70        LDA [$70],Y
C1/D8D4: 0A           ASL 
C1/D8D5: 0A           ASL 
C1/D8D6: 85 7E        STA $7E
C1/D8D8: AD 0A D1     LDA $D10A
C1/D8DB: 29 E3        AND #$E3
C1/D8DD: 05 7E        ORA $7E
C1/D8DF: 8D 0A D1     STA $D10A
C1/D8E2: 60           RTS 
C1/D8E3: 20 40 80     JSR $8040
C1/D8E6: 08           PHP 
C1/D8E7: 20 40 80     JSR $8040
C1/D8EA: 18           CLC 
C1/D8EB: 20 40 20     JSR $2040
C1/D8EE: 40           RTI 
C1/D8EF: 88           DEY 
C1/D8F0: 80 80        BRA $D872
C1/D8F2: 80 F8        BRA $D8EC
C1/D8F4: F8           SED 
C1/D8F5: F8           SED 
C1/D8F6: F8           SED 
C1/D8F7: F8           SED 
C1/D8F8: F8           SED 
C1/D8F9: F8           SED 
C1/D8FA: F8           SED 
C1/D8FB: 20 40 20     JSR $2040
C1/D8FE: 40           RTI 
C1/D8FF: 88           DEY 
C1/D900: 80 80        BRA $D882
C1/D902: 80 BD        BRA $D8C1
C1/D904: D8           CLD 
C1/D905: D5 85        CMP $85,X
C1/D907: A6 9E        LDX $9E
C1/D909: D9 D5 BD     CMP $BDD5,Y
C1/D90C: DA           PHX 
C1/D90D: D5 85        CMP $85,X
C1/D90F: A7 9E        LDA [$9E]
C1/D911: DB           STP 
C1/D912: D5 DA        CMP $DA,X
C1/D914: 8A           TXA 
C1/D915: 4A           LSR 
C1/D916: 4A           LSR 
C1/D917: 4A           LSR 
C1/D918: 4A           LSR 
C1/D919: AA           TAX 
C1/D91A: AD 50 DB     LDA $DB50
C1/D91D: 30 0E        BMI $D92D
C1/D91F: BF E3 D8 C1  LDA $C1D8E3,X
C1/D923: 85 7E        STA $7E
C1/D925: BF EB D8 C1  LDA $C1D8EB,X
C1/D929: 85 80        STA $80
C1/D92B: 80 0C        BRA $D939
C1/D92D: BF F3 D8 C1  LDA $C1D8F3,X
C1/D931: 85 7E        STA $7E
C1/D933: BF FB D8 C1  LDA $C1D8FB,X
C1/D937: 85 80        STA $80
C1/D939: FA           PLX 
C1/D93A: A5 7E        LDA $7E
C1/D93C: 9D DF D1     STA $D1DF,X
C1/D93F: 85 A8        STA $A8
C1/D941: 9E E0 D1     STZ $D1E0,X
C1/D944: A5 80        LDA $80
C1/D946: 9D E1 D1     STA $D1E1,X
C1/D949: 85 A9        STA $A9
C1/D94B: 9E E2 D1     STZ $D1E2,X
C1/D94E: 9E DC D1     STZ $D1DC,X
C1/D951: 9E DD D1     STZ $D1DD,X
C1/D954: DA           PHX 
C1/D955: 20 6E 0A     JSR $0A6E
C1/D958: FA           PLX 
C1/D959: A5 AE        LDA $AE
C1/D95B: 9D E3 D3     STA $D3E3,X
C1/D95E: A5 AF        LDA $AF
C1/D960: 9D E4 D3     STA $D3E4,X
C1/D963: A5 B0        LDA $B0
C1/D965: 9D E5 D3     STA $D3E5,X
C1/D968: 9E E6 D3     STZ $D3E6,X
C1/D96B: 20 3B E2     JSR $E23B
C1/D96E: FE E1 D5     INC $D5E1,X
C1/D971: A9 10        LDA #$10
C1/D973: 85 80        STA $80
C1/D975: BD E1 D5     LDA $D5E1,X
C1/D978: 0A           ASL 
C1/D979: 0A           ASL 
C1/D97A: 0A           ASL 
C1/D97B: DA           PHX 
C1/D97C: 20 00 0A     JSR $0A00
C1/D97F: FA           PLX 
C1/D980: 18           CLC 
C1/D981: 7D E3 D5     ADC $D5E3,X
C1/D984: 9D DD D1     STA $D1DD,X
C1/D987: 8A           TXA 
C1/D988: 4A           LSR 
C1/D989: 4A           LSR 
C1/D98A: 4A           LSR 
C1/D98B: 4A           LSR 
C1/D98C: 9D E3 D1     STA $D1E3,X
C1/D98F: 60           RTS 
C1/D990: BD E3 D7     LDA $D7E3,X
C1/D993: D0 02        BNE $D997
C1/D995: C8           INY 
C1/D996: 60           RTS 
C1/D997: 4C 24 DF     JMP $DF24
C1/D99A: AD 16 D1     LDA $D116
C1/D99D: D0 0E        BNE $D9AD
C1/D99F: 8A           TXA 
C1/D9A0: 4A           LSR 
C1/D9A1: 4A           LSR 
C1/D9A2: 4A           LSR 
C1/D9A3: 4A           LSR 
C1/D9A4: C9 04        CMP #$04
C1/D9A6: B0 05        BCS $D9AD
C1/D9A8: CD 17 D1     CMP $D117
C1/D9AB: F0 02        BEQ $D9AF
C1/D9AD: C8           INY 
C1/D9AE: 60           RTS 
C1/D9AF: FE E3 D7     INC $D7E3,X
C1/D9B2: 4C 24 DF     JMP $DF24
C1/D9B5: BD E3 D7     LDA $D7E3,X
C1/D9B8: D0 01        BNE $D9BB
C1/D9BA: 60           RTS 
C1/D9BB: 9E E3 D7     STZ $D7E3,X
C1/D9BE: EE 17 D1     INC $D117
C1/D9C1: DA           PHX 
C1/D9C2: 5A           PHY 
C1/D9C3: 85 81        STA $81
C1/D9C5: C2 20        REP #$20
C1/D9C7: 7B           TDC 
C1/D9C8: A8           TAY 
C1/D9C9: B9 70 00     LDA $0070,Y
C1/D9CC: 48           PHA 
C1/D9CD: C8           INY 
C1/D9CE: C8           INY 
C1/D9CF: C0 0C 00     CPY #$000C
C1/D9D2: D0 F5        BNE $D9C9
C1/D9D4: 7B           TDC 
C1/D9D5: E2 20        SEP #$20
C1/D9D7: 20 58 01     JSR $0158
C1/D9DA: C2 20        REP #$20
C1/D9DC: A0 0C 00     LDY #$000C
C1/D9DF: 68           PLA 
C1/D9E0: 99 6E 00     STA $006E,Y
C1/D9E3: 88           DEY 
C1/D9E4: 88           DEY 
C1/D9E5: D0 F8        BNE $D9DF
C1/D9E7: 7B           TDC 
C1/D9E8: E2 20        SEP #$20
C1/D9EA: 7A           PLY 
C1/D9EB: FA           PLX 
C1/D9EC: 60           RTS 
C1/D9ED: C8           INY 
C1/D9EE: B7 70        LDA [$70],Y
C1/D9F0: 30 09        BMI $D9FB
C1/D9F2: BD E7 D1     LDA $D1E7,X
C1/D9F5: 09 20        ORA #$20
C1/D9F7: 9D E7 D1     STA $D1E7,X
C1/D9FA: 60           RTS 
C1/D9FB: BD E7 D1     LDA $D1E7,X
C1/D9FE: 29 DF        AND #$DF
C1/DA00: 9D E7 D1     STA $D1E7,X
C1/DA03: 60           RTS 
C1/DA04: C8           INY 
C1/DA05: B7 70        LDA [$70],Y
C1/DA07: 30 06        BMI $DA0F
C1/DA09: 29 0F        AND #$0F
C1/DA0B: 8D 7F BC     STA $BC7F
C1/DA0E: 60           RTS 
C1/DA0F: 9C 7F BC     STZ $BC7F
C1/DA12: 60           RTS 
C1/DA13: C8           INY 
C1/DA14: B7 70        LDA [$70],Y
C1/DA16: 30 10        BMI $DA28
C1/DA18: 29 3C        AND #$3C
C1/DA1A: 0A           ASL 
C1/DA1B: 0A           ASL 
C1/DA1C: 85 80        STA $80
C1/DA1E: B7 70        LDA [$70],Y
C1/DA20: 29 03        AND #$03
C1/DA22: 05 80        ORA $80
C1/DA24: 8D 80 BC     STA $BC80
C1/DA27: 60           RTS 
C1/DA28: 9C 80 BC     STZ $BC80
C1/DA2B: 60           RTS 
C1/DA2C: DA           PHX 
C1/DA2D: C8           INY 
C1/DA2E: B7 70        LDA [$70],Y
C1/DA30: 85 80        STA $80
C1/DA32: A9 08        LDA #$08
C1/DA34: 85 82        STA $82
C1/DA36: 20 96 FC     JSR $FC96       ; generate random number
C1/DA39: 25 80        AND $80
C1/DA3B: 9D D8 D9     STA $D9D8,X
C1/DA3E: 9E D9 D9     STZ $D9D9,X
C1/DA41: 20 96 FC     JSR $FC96       ; generate random number
C1/DA44: 25 80        AND $80
C1/DA46: 9D 58 DA     STA $DA58,X
C1/DA49: 9E 59 DA     STZ $DA59,X
C1/DA4C: E8           INX 
C1/DA4D: E8           INX 
C1/DA4E: C6 82        DEC $82
C1/DA50: D0 E4        BNE $DA36
C1/DA52: A9 01        LDA #$01
C1/DA54: 8D 3C DB     STA $DB3C
C1/DA57: FA           PLX 
C1/DA58: 60           RTS 
C1/DA59: DA           PHX 
C1/DA5A: 20 64 FC     JSR $FC64
C1/DA5D: BD E2 D3     LDA $D3E2,X
C1/DA60: 30 03        BMI $DA65
C1/DA62: 7B           TDC 
C1/DA63: 80 1F        BRA $DA84
C1/DA65: 29 07        AND #$07
C1/DA67: AA           TAX 
C1/DA68: BD FE CF     LDA $CFFE,X
C1/DA6B: C9 07        CMP #$07
C1/DA6D: 90 14        BCC $DA83
C1/DA6F: C9 0B        CMP #$0B
C1/DA71: 90 0C        BCC $DA7F
C1/DA73: C9 0F        CMP #$0F
C1/DA75: 90 04        BCC $DA7B
C1/DA77: A9 03        LDA #$03
C1/DA79: 80 09        BRA $DA84
C1/DA7B: A9 02        LDA #$02
C1/DA7D: 80 05        BRA $DA84
C1/DA7F: A9 01        LDA #$01
C1/DA81: 80 01        BRA $DA84
C1/DA83: 7B           TDC 
C1/DA84: FA           PLX 
C1/DA85: 9D DE D7     STA $D7DE,X
C1/DA88: 60           RTS 
C1/DA89: A6 78        LDX $78
C1/DA8B: BD E2 D3     LDA $D3E2,X
C1/DA8E: 29 07        AND #$07
C1/DA90: AA           TAX 
C1/DA91: BD 26 D0     LDA $D026,X
C1/DA94: DD 06 D0     CMP $D006,X
C1/DA97: F0 0D        BEQ $DAA6
C1/DA99: FE 26 D0     INC $D026,X
C1/DA9C: A5 DE        LDA $DE
C1/DA9E: 20 77 1A     JSR $1A77
C1/DAA1: EE A4 DB     INC $DBA4
C1/DAA4: 38           SEC 
C1/DAA5: 60           RTS 
C1/DAA6: 9E 26 D0     STZ $D026,X
C1/DAA9: A6 78        LDX $78
C1/DAAB: BD E2 D3     LDA $D3E2,X
C1/DAAE: 29 07        AND #$07
C1/DAB0: 20 74 FC     JSR $FC74
C1/DAB3: 49 FF        EOR #$FF
C1/DAB5: 85 74        STA $74
C1/DAB7: A5 DE        LDA $DE
C1/DAB9: 25 74        AND $74
C1/DABB: 85 DE        STA $DE
C1/DABD: 20 77 1A     JSR $1A77
C1/DAC0: 18           CLC 
C1/DAC1: 60           RTS 
C1/DAC2: DA           PHX 
C1/DAC3: 86 78        STX $78
C1/DAC5: FE E1 D5     INC $D5E1,X
C1/DAC8: BD E1 D5     LDA $D5E1,X
C1/DACB: 29 01        AND #$01
C1/DACD: D0 0A        BNE $DAD9
C1/DACF: BD E2 D3     LDA $D3E2,X
C1/DAD2: 10 09        BPL $DADD
C1/DAD4: 20 89 DA     JSR $DA89
C1/DAD7: 90 04        BCC $DADD
C1/DAD9: 88           DEY 
C1/DADA: 88           DEY 
C1/DADB: FA           PLX 
C1/DADC: 60           RTS 
C1/DADD: A6 78        LDX $78
C1/DADF: 9E F7 D3     STZ $D3F7,X
C1/DAE2: FA           PLX 
C1/DAE3: 60           RTS 
C1/DAE4: DA           PHX 
C1/DAE5: 20 18 DB     JSR $DB18
C1/DAE8: 20 5B E4     JSR $E45B
C1/DAEB: A6 84        LDX $84
C1/DAED: BD FB CE     LDA $CEFB,X
C1/DAF0: 20 96 09     JSR $0996
C1/DAF3: A6 78        LDX $78
C1/DAF5: FE E1 D5     INC $D5E1,X
C1/DAF8: BD E1 D5     LDA $D5E1,X
C1/DAFB: 29 03        AND #$03
C1/DAFD: D0 07        BNE $DB06
C1/DAFF: A6 84        LDX $84
C1/DB01: DE FB CE     DEC $CEFB,X
C1/DB04: 30 10        BMI $DB16
C1/DB06: A6 78        LDX $78
C1/DB08: A5 86        LDA $86
C1/DB0A: 9D DC D1     STA $D1DC,X
C1/DB0D: A5 87        LDA $87
C1/DB0F: 9D DD D1     STA $D1DD,X
C1/DB12: 88           DEY 
C1/DB13: 88           DEY 
C1/DB14: FA           PLX 
C1/DB15: 60           RTS 
C1/DB16: FA           PLX 
C1/DB17: 60           RTS 
C1/DB18: 86 78        STX $78
C1/DB1A: C2 20        REP #$20
C1/DB1C: 8A           TXA 
C1/DB1D: 4A           LSR 
C1/DB1E: 85 80        STA $80
C1/DB20: 4A           LSR 
C1/DB21: 4A           LSR 
C1/DB22: 85 84        STA $84
C1/DB24: 64 85        STZ $85
C1/DB26: AA           TAX 
C1/DB27: 7B           TDC 
C1/DB28: E2 20        SEP #$20
C1/DB2A: 60           RTS 
C1/DB2B: DA           PHX 
C1/DB2C: 20 18 DB     JSR $DB18
C1/DB2F: DA           PHX 
C1/DB30: C2 20        REP #$20
C1/DB32: A5 78        LDA $78
C1/DB34: 4A           LSR 
C1/DB35: AA           TAX 
C1/DB36: 7B           TDC 
C1/DB37: E2 20        SEP #$20
C1/DB39: 8A           TXA 
C1/DB3A: FA           PLX 
C1/DB3B: 9D 7B CE     STA $CE7B,X
C1/DB3E: 18           CLC 
C1/DB3F: 69 40        ADC #$40
C1/DB41: 9D BB CE     STA $CEBB,X
C1/DB44: A9 18        LDA #$18
C1/DB46: 9D FB CD     STA $CDFB,X
C1/DB49: 9D 3B CE     STA $CE3B,X
C1/DB4C: A9 10        LDA #$10
C1/DB4E: 9D FB CE     STA $CEFB,X
C1/DB51: 4C C0 E3     JMP $E3C0
C1/DB54: C8           INY 
C1/DB55: B7 70        LDA [$70],Y
C1/DB57: 9D DD D7     STA $D7DD,X
C1/DB5A: 9E DE D7     STZ $D7DE,X
C1/DB5D: C2 10        REP #$10
C1/DB5F: 98           TYA 
C1/DB60: 9D DB D7     STA $D7DB,X
C1/DB63: 7B           TDC 
C1/DB64: E2 20        SEP #$20
C1/DB66: 60           RTS 
C1/DB67: DE DD D7     DEC $D7DD,X
C1/DB6A: F0 0D        BEQ $DB79
C1/DB6C: FE DE D7     INC $D7DE,X
C1/DB6F: C2 20        REP #$20
C1/DB71: BD DB D7     LDA $D7DB,X
C1/DB74: A8           TAY 
C1/DB75: 7B           TDC 
C1/DB76: E2 20        SEP #$20
C1/DB78: 60           RTS 
C1/DB79: 9E DE D7     STZ $D7DE,X
C1/DB7C: 60           RTS 
C1/DB7D: C8           INY 
C1/DB7E: B7 70        LDA [$70],Y
C1/DB80: 9D DA D7     STA $D7DA,X
C1/DB83: C2 10        REP #$10
C1/DB85: 98           TYA 
C1/DB86: 9D D8 D7     STA $D7D8,X
C1/DB89: 7B           TDC 
C1/DB8A: E2 20        SEP #$20
C1/DB8C: 60           RTS 
C1/DB8D: DE DA D7     DEC $D7DA,X
C1/DB90: F0 09        BEQ $DB9B
C1/DB92: C2 20        REP #$20
C1/DB94: BD D8 D7     LDA $D7D8,X
C1/DB97: A8           TAY 
C1/DB98: 7B           TDC 
C1/DB99: E2 20        SEP #$20
C1/DB9B: 60           RTS 
C1/DB9C: C8           INY 
C1/DB9D: C2 20        REP #$20
C1/DB9F: B7 70        LDA [$70],Y
C1/DBA1: 8D 6A F8     STA $F86A
C1/DBA4: 7B           TDC 
C1/DBA5: E2 20        SEP #$20
C1/DBA7: C8           INY 
C1/DBA8: 60           RTS 

; [ animation command $C3: set animation size ]

; b1 = size

C1/DBA9: C8           INY 
C1/DBAA: B7 70        LDA [$70],Y
C1/DBAC: DA           PHX 
C1/DBAD: 29 3F        AND #$3F
C1/DBAF: 0A           ASL 
C1/DBB0: AA           TAX 
C1/DBB1: BF 1C B3 C1  LDA $C1B31C,X   ; width
C1/DBB5: 85 7E        STA $7E
C1/DBB7: BF 1D B3 C1  LDA $C1B31D,X   ; height
C1/DBBB: 85 80        STA $80
C1/DBBD: FA           PLX 
C1/DBBE: EE 5F DB     INC $DB5F
C1/DBC1: A5 7E        LDA $7E
C1/DBC3: 9D E5 D1     STA $D1E5,X
C1/DBC6: A5 80        LDA $80
C1/DBC8: 9D E6 D1     STA $D1E6,X
C1/DBCB: DA           PHX 
C1/DBCC: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/DBCF: FA           PLX 
C1/DBD0: A5 82        LDA $82
C1/DBD2: 9D DE D1     STA $D1DE,X
C1/DBD5: 60           RTS 

; [  ]

C1/DBD6: BD DC D1     LDA $D1DC,X
C1/DBD9: 9D E4 D7     STA $D7E4,X
C1/DBDC: BD DD D1     LDA $D1DD,X
C1/DBDF: 9D E5 D7     STA $D7E5,X
C1/DBE2: 60           RTS 
C1/DBE3: BD E4 D7     LDA $D7E4,X
C1/DBE6: 9D DC D1     STA $D1DC,X
C1/DBE9: BD E5 D7     LDA $D7E5,X
C1/DBEC: 9D DD D1     STA $D1DD,X
C1/DBEF: 60           RTS 
C1/DBF0: 9E DC D1     STZ $D1DC,X
C1/DBF3: 9E DD D1     STZ $D1DD,X
C1/DBF6: 60           RTS 
C1/DBF7: BD E2 D7     LDA $D7E2,X
C1/DBFA: D0 08        BNE $DC04
C1/DBFC: A9 80        LDA #$80
C1/DBFE: 85 7E        STA $7E
C1/DC00: C8           INY 
C1/DC01: 4C 09 DC     JMP $DC09

; [ animation command $83: set animation palette ]

; b1 = palette index

C1/DC04: C8           INY 
C1/DC05: B7 70        LDA [$70],Y
C1/DC07: 85 7E        STA $7E
C1/DC09: A5 7E        LDA $7E
C1/DC0B: 30 25        BMI $DC32
C1/DC0D: AD 5D DB     LDA $DB5D
C1/DC10: D0 14        BNE $DC26
C1/DC12: A5 70        LDA $70
C1/DC14: 48           PHA 
C1/DC15: B7 70        LDA [$70],Y
C1/DC17: 29 7F        AND #$7F
C1/DC19: DA           PHX 
C1/DC1A: 5A           PHY 
C1/DC1B: A0 40 01     LDY #$0140
C1/DC1E: 20 1D AA     JSR $AA1D       ; load attack palette (8-colors)
C1/DC21: 7A           PLY 
C1/DC22: FA           PLX 
C1/DC23: 68           PLA 
C1/DC24: 85 70        STA $70
C1/DC26: BD E7 D1     LDA $D1E7,X
C1/DC29: 09 40        ORA #$40
C1/DC2B: 9D E7 D1     STA $D1E7,X
C1/DC2E: EE 5D DB     INC $DB5D
C1/DC31: 60           RTS 
C1/DC32: BD E7 D1     LDA $D1E7,X
C1/DC35: 29 BF        AND #$BF
C1/DC37: 9D E7 D1     STA $D1E7,X
C1/DC3A: 60           RTS 

; [ animation command $BE:  ]

C1/DC3B: C2 20        REP #$20
C1/DC3D: BD DC D5     LDA $D5DC,X
C1/DC40: 9D DF D1     STA $D1DF,X
C1/DC43: BD DE D5     LDA $D5DE,X
C1/DC46: 9D E1 D1     STA $D1E1,X
C1/DC49: 7B           TDC 
C1/DC4A: E2 20        SEP #$20
C1/DC4C: 60           RTS 
C1/DC4D: BD E6 D3     LDA $D3E6,X
C1/DC50: 18           CLC 
C1/DC51: 69 10        ADC #$10
C1/DC53: 9D E6 D3     STA $D3E6,X
C1/DC56: C2 20        REP #$20
C1/DC58: BD E4 D3     LDA $D3E4,X
C1/DC5B: 38           SEC 
C1/DC5C: E9 10 00     SBC #$0010
C1/DC5F: 9D E4 D3     STA $D3E4,X
C1/DC62: BD E4 D3     LDA $D3E4,X
C1/DC65: 30 09        BMI $DC70
C1/DC67: 7B           TDC 
C1/DC68: E2 20        SEP #$20
C1/DC6A: 88           DEY 
C1/DC6B: 88           DEY 
C1/DC6C: 88           DEY 
C1/DC6D: 20 3B E2     JSR $E23B
C1/DC70: 7B           TDC 
C1/DC71: E2 20        SEP #$20
C1/DC73: 60           RTS 
C1/DC74: C2 20        REP #$20
C1/DC76: BD DF D1     LDA $D1DF,X
C1/DC79: 38           SEC 
C1/DC7A: E9 04 00     SBC #$0004
C1/DC7D: 9D DF D1     STA $D1DF,X
C1/DC80: 7B           TDC 
C1/DC81: E2 20        SEP #$20
C1/DC83: BD E1 D5     LDA $D5E1,X
C1/DC86: C9 40        CMP #$40
C1/DC88: D0 05        BNE $DC8F
C1/DC8A: A9 01        LDA #$01
C1/DC8C: 9D 07 D4     STA $D407,X
C1/DC8F: BD E1 D5     LDA $D5E1,X
C1/DC92: C9 80        CMP #$80
C1/DC94: F0 0D        BEQ $DCA3
C1/DC96: FE E1 D5     INC $D5E1,X
C1/DC99: 29 04        AND #$04
C1/DC9B: 4A           LSR 
C1/DC9C: 4A           LSR 
C1/DC9D: 9D E3 D1     STA $D1E3,X
C1/DCA0: 88           DEY 
C1/DCA1: 88           DEY 
C1/DCA2: 60           RTS 
C1/DCA3: 9E E3 D1     STZ $D1E3,X
C1/DCA6: 60           RTS 
C1/DCA7: DA           PHX 
C1/DCA8: C8           INY 
C1/DCA9: B7 70        LDA [$70],Y
C1/DCAB: C2 20        REP #$20
C1/DCAD: 0A           ASL 
C1/DCAE: 0A           ASL 
C1/DCAF: 0A           ASL 
C1/DCB0: 0A           ASL 
C1/DCB1: AA           TAX 
C1/DCB2: 7B           TDC 
C1/DCB3: E2 20        SEP #$20
C1/DCB5: A9 01        LDA #$01
C1/DCB7: 9D E7 D3     STA $D3E7,X
C1/DCBA: FA           PLX 
C1/DCBB: 60           RTS 
C1/DCBC: DA           PHX 
C1/DCBD: C8           INY 
C1/DCBE: B7 70        LDA [$70],Y
C1/DCC0: 20 74 FC     JSR $FC74
C1/DCC3: 85 7E        STA $7E
C1/DCC5: AD 53 DB     LDA $DB53
C1/DCC8: 25 7E        AND $7E
C1/DCCA: F0 11        BEQ $DCDD
C1/DCCC: B7 70        LDA [$70],Y
C1/DCCE: C2 20        REP #$20
C1/DCD0: 0A           ASL 
C1/DCD1: 0A           ASL 
C1/DCD2: 0A           ASL 
C1/DCD3: 0A           ASL 
C1/DCD4: AA           TAX 
C1/DCD5: 7B           TDC 
C1/DCD6: E2 20        SEP #$20
C1/DCD8: A9 01        LDA #$01
C1/DCDA: 9D E7 D3     STA $D3E7,X
C1/DCDD: FA           PLX 
C1/DCDE: 60           RTS 
C1/DCDF: C2 20        REP #$20
C1/DCE1: BD DF D1     LDA $D1DF,X
C1/DCE4: 38           SEC 
C1/DCE5: E9 04 00     SBC #$0004
C1/DCE8: 9D DF D1     STA $D1DF,X
C1/DCEB: BD E1 D1     LDA $D1E1,X
C1/DCEE: 18           CLC 
C1/DCEF: 69 04 00     ADC #$0004
C1/DCF2: 9D E1 D1     STA $D1E1,X
C1/DCF5: 7B           TDC 
C1/DCF6: E2 20        SEP #$20
C1/DCF8: BD E1 D5     LDA $D5E1,X
C1/DCFB: C9 28        CMP #$28
C1/DCFD: F0 0F        BEQ $DD0E
C1/DCFF: C9 10        CMP #$10
C1/DD01: D0 05        BNE $DD08
C1/DD03: A9 01        LDA #$01
C1/DD05: 9D E3 D1     STA $D1E3,X
C1/DD08: FE E1 D5     INC $D5E1,X
C1/DD0B: 88           DEY 
C1/DD0C: 88           DEY 
C1/DD0D: 60           RTS 
C1/DD0E: 9E E1 D5     STZ $D5E1,X
C1/DD11: 9E E3 D1     STZ $D1E3,X
C1/DD14: 60           RTS 
C1/DD15: C2 20        REP #$20
C1/DD17: BD DF D1     LDA $D1DF,X
C1/DD1A: 38           SEC 
C1/DD1B: E9 04 00     SBC #$0004
C1/DD1E: 9D DF D1     STA $D1DF,X
C1/DD21: BD E1 D1     LDA $D1E1,X
C1/DD24: 38           SEC 
C1/DD25: E9 04 00     SBC #$0004
C1/DD28: 9D E1 D1     STA $D1E1,X
C1/DD2B: 7B           TDC 
C1/DD2C: E2 20        SEP #$20
C1/DD2E: BD E1 D5     LDA $D5E1,X
C1/DD31: C9 28        CMP #$28
C1/DD33: F0 0F        BEQ $DD44
C1/DD35: C9 04        CMP #$04
C1/DD37: D0 05        BNE $DD3E
C1/DD39: A9 01        LDA #$01
C1/DD3B: 9D E3 D1     STA $D1E3,X
C1/DD3E: FE E1 D5     INC $D5E1,X
C1/DD41: 88           DEY 
C1/DD42: 88           DEY 
C1/DD43: 60           RTS 
C1/DD44: 9E E1 D5     STZ $D5E1,X
C1/DD47: 60           RTS 
C1/DD48: C2 20        REP #$20
C1/DD4A: BD DF D1     LDA $D1DF,X
C1/DD4D: 38           SEC 
C1/DD4E: E9 04 00     SBC #$0004
C1/DD51: 9D DF D1     STA $D1DF,X
C1/DD54: BD E1 D1     LDA $D1E1,X
C1/DD57: 18           CLC 
C1/DD58: 69 02 00     ADC #$0002
C1/DD5B: 9D E1 D1     STA $D1E1,X
C1/DD5E: 7B           TDC 
C1/DD5F: E2 20        SEP #$20
C1/DD61: BD E1 D5     LDA $D5E1,X
C1/DD64: C9 28        CMP #$28
C1/DD66: F0 06        BEQ $DD6E
C1/DD68: FE E1 D5     INC $D5E1,X
C1/DD6B: 88           DEY 
C1/DD6C: 88           DEY 
C1/DD6D: 60           RTS 
C1/DD6E: 9E E1 D5     STZ $D5E1,X
C1/DD71: 60           RTS 
C1/DD72: C2 20        REP #$20
C1/DD74: BD DF D1     LDA $D1DF,X
C1/DD77: 18           CLC 
C1/DD78: 69 04 00     ADC #$0004
C1/DD7B: 9D DF D1     STA $D1DF,X
C1/DD7E: BD E1 D1     LDA $D1E1,X
C1/DD81: 18           CLC 
C1/DD82: 69 02 00     ADC #$0002
C1/DD85: 9D E1 D1     STA $D1E1,X
C1/DD88: 7B           TDC 
C1/DD89: E2 20        SEP #$20
C1/DD8B: BD E1 D5     LDA $D5E1,X
C1/DD8E: C9 24        CMP #$24
C1/DD90: F0 05        BEQ $DD97
C1/DD92: FE E1 D5     INC $D5E1,X
C1/DD95: 88           DEY 
C1/DD96: 88           DEY 
C1/DD97: 60           RTS 
C1/DD98: C8           INY 
C1/DD99: B7 70        LDA [$70],Y
C1/DD9B: 85 80        STA $80
C1/DD9D: 64 81        STZ $81
C1/DD9F: C2 20        REP #$20
C1/DDA1: BD DF D1     LDA $D1DF,X
C1/DDA4: 18           CLC 
C1/DDA5: 65 80        ADC $80
C1/DDA7: 9D DF D1     STA $D1DF,X
C1/DDAA: BD DC D1     LDA $D1DC,X
C1/DDAD: 9D E2 D5     STA $D5E2,X
C1/DDB0: 7B           TDC 
C1/DDB1: E2 20        SEP #$20
C1/DDB3: 60           RTS 
C1/DDB4: C8           INY 
C1/DDB5: B7 70        LDA [$70],Y
C1/DDB7: 85 80        STA $80
C1/DDB9: 64 81        STZ $81
C1/DDBB: C2 20        REP #$20
C1/DDBD: BD E1 D1     LDA $D1E1,X
C1/DDC0: 18           CLC 
C1/DDC1: 65 80        ADC $80
C1/DDC3: 9D E1 D1     STA $D1E1,X
C1/DDC6: BD DC D1     LDA $D1DC,X
C1/DDC9: 9D E2 D5     STA $D5E2,X
C1/DDCC: 7B           TDC 
C1/DDCD: E2 20        SEP #$20
C1/DDCF: 60           RTS 
C1/DDD0: C8           INY 
C1/DDD1: B7 70        LDA [$70],Y
C1/DDD3: 85 80        STA $80
C1/DDD5: 64 81        STZ $81
C1/DDD7: C2 20        REP #$20
C1/DDD9: BD DF D1     LDA $D1DF,X
C1/DDDC: 38           SEC 
C1/DDDD: E5 80        SBC $80
C1/DDDF: 9D DF D1     STA $D1DF,X
C1/DDE2: BD DC D1     LDA $D1DC,X
C1/DDE5: 9D E2 D5     STA $D5E2,X
C1/DDE8: 7B           TDC 
C1/DDE9: E2 20        SEP #$20
C1/DDEB: 60           RTS 
C1/DDEC: C8           INY 
C1/DDED: B7 70        LDA [$70],Y
C1/DDEF: 85 80        STA $80
C1/DDF1: 64 81        STZ $81
C1/DDF3: C2 20        REP #$20
C1/DDF5: BD E1 D1     LDA $D1E1,X
C1/DDF8: 38           SEC 
C1/DDF9: E5 80        SBC $80
C1/DDFB: 9D E1 D1     STA $D1E1,X
C1/DDFE: BD DC D1     LDA $D1DC,X
C1/DE01: 9D E2 D5     STA $D5E2,X
C1/DE04: 7B           TDC 
C1/DE05: E2 20        SEP #$20
C1/DE07: 60           RTS 
C1/DE08: C2 20        REP #$20
C1/DE0A: BD DF D1     LDA $D1DF,X
C1/DE0D: 38           SEC 
C1/DE0E: E9 04 00     SBC #$0004
C1/DE11: 9D DF D1     STA $D1DF,X
C1/DE14: 7B           TDC 
C1/DE15: E2 20        SEP #$20
C1/DE17: BD E1 D5     LDA $D5E1,X
C1/DE1A: C9 40        CMP #$40
C1/DE1C: D0 05        BNE $DE23
C1/DE1E: A9 01        LDA #$01
C1/DE20: 9D 17 D4     STA $D417,X
C1/DE23: BD E1 D5     LDA $D5E1,X
C1/DE26: C9 80        CMP #$80
C1/DE28: F0 0D        BEQ $DE37
C1/DE2A: FE E1 D5     INC $D5E1,X
C1/DE2D: 29 04        AND #$04
C1/DE2F: 4A           LSR 
C1/DE30: 4A           LSR 
C1/DE31: 9D E3 D1     STA $D1E3,X
C1/DE34: 88           DEY 
C1/DE35: 88           DEY 
C1/DE36: 60           RTS 
C1/DE37: 9E E3 D1     STZ $D1E3,X
C1/DE3A: 60           RTS 
C1/DE3B: C2 20        REP #$20
C1/DE3D: BD DF D1     LDA $D1DF,X
C1/DE40: 38           SEC 
C1/DE41: E9 04 00     SBC #$0004
C1/DE44: 9D DF D1     STA $D1DF,X
C1/DE47: 7B           TDC 
C1/DE48: E2 20        SEP #$20
C1/DE4A: BD E1 D5     LDA $D5E1,X
C1/DE4D: C9 40        CMP #$40
C1/DE4F: F0 0D        BEQ $DE5E
C1/DE51: FE E1 D5     INC $D5E1,X
C1/DE54: 29 04        AND #$04
C1/DE56: 4A           LSR 
C1/DE57: 4A           LSR 
C1/DE58: 9D E3 D1     STA $D1E3,X
C1/DE5B: 88           DEY 
C1/DE5C: 88           DEY 
C1/DE5D: 60           RTS 
C1/DE5E: 9E E3 D1     STZ $D1E3,X
C1/DE61: 60           RTS 
C1/DE62: C2 20        REP #$20
C1/DE64: BD DF D1     LDA $D1DF,X
C1/DE67: 18           CLC 
C1/DE68: 69 00 01     ADC #$0100
C1/DE6B: 9D DF D1     STA $D1DF,X
C1/DE6E: BD DC D1     LDA $D1DC,X
C1/DE71: 9D E2 D5     STA $D5E2,X
C1/DE74: 7B           TDC 
C1/DE75: E2 20        SEP #$20
C1/DE77: 60           RTS 

C1/DE78: AD D3 DB     LDA $DBD3
C1/DE7B: F0 0F        BEQ $DE8C
C1/DE7D: C2 20        REP #$20
C1/DE7F: BD E1 D1     LDA $D1E1,X
C1/DE82: 18           CLC 
C1/DE83: 69 20 00     ADC #$0020
C1/DE86: 9D E1 D1     STA $D1E1,X
C1/DE89: 7B           TDC 
C1/DE8A: E2 20        SEP #$20
C1/DE8C: 60           RTS 

; [ animation command $AE: set position ]

C1/DE8D: C8           INY 
C1/DE8E: B7 70        LDA [$70],Y
C1/DE90: 9D DF D1     STA $D1DF,X
C1/DE93: 9E E0 D1     STZ $D1E0,X
C1/DE96: C8           INY 
C1/DE97: B7 70        LDA [$70],Y
C1/DE99: 9D E1 D1     STA $D1E1,X
C1/DE9C: 9E E2 D1     STZ $D1E2,X
C1/DE9F: 9E DC D1     STZ $D1DC,X
C1/DEA2: 9E DD D1     STZ $D1DD,X
C1/DEA5: 60           RTS 

C1/DEA6: C8           INY 
C1/DEA7: B7 70        LDA [$70],Y
C1/DEA9: 85 7E        STA $7E
C1/DEAB: 8A           TXA 
C1/DEAC: 4A           LSR 
C1/DEAD: 4A           LSR 
C1/DEAE: 4A           LSR 
C1/DEAF: 4A           LSR 
C1/DEB0: 29 07        AND #$07
C1/DEB2: 60           RTS 

C1/DEB3: 20 A6 DE     JSR $DEA6
C1/DEB6: 4C 43 7B     JMP $7B43

C1/DEB9: 20 A6 DE     JSR $DEA6
C1/DEBC: 4C 02 7B     JMP $7B02

C1/DEBF: 20 A6 DE     JSR $DEA6
C1/DEC2: 4C 93 7A     JMP $7A93

C1/DEC5: 20 A6 DE     JSR $DEA6
C1/DEC8: 4C A5 79     JMP $79A5

C1/DECB: 20 A6 DE     JSR $DEA6
C1/DECE: 4C 2A 7A     JMP $7A2A

; [ load target palette ]

C1/DED1: 5A           PHY 
C1/DED2: DA           PHX 
C1/DED3: C2 20        REP #$20
C1/DED5: 0A           ASL 
C1/DED6: 0A           ASL 
C1/DED7: 0A           ASL 
C1/DED8: 0A           ASL 
C1/DED9: 0A           ASL 
C1/DEDA: AA           TAX 
C1/DEDB: 7B           TDC 
C1/DEDC: E2 20        SEP #$20
C1/DEDE: AD 55 DB     LDA $DB55
C1/DEE1: D0 16        BNE $DEF9
C1/DEE3: 7B           TDC 
C1/DEE4: A8           TAY 
C1/DEE5: BF 55 96 D9  LDA $D99655,X   ; target palette
C1/DEE9: 99 69 7E     STA $7E69,Y
C1/DEEC: 99 49 F8     STA $F849,Y
C1/DEEF: E8           INX 
C1/DEF0: C8           INY 
C1/DEF1: C0 20 00     CPY #$0020
C1/DEF4: D0 EF        BNE $DEE5
C1/DEF6: EE 55 DB     INC $DB55
C1/DEF9: FA           PLX 
C1/DEFA: DA           PHX 
C1/DEFB: BD E2 D3     LDA $D3E2,X
C1/DEFE: 30 06        BMI $DF06
C1/DF00: 29 03        AND #$03
C1/DF02: AA           TAX 
C1/DF03: FE 43 DB     INC $DB43,X
C1/DF06: FA           PLX 
C1/DF07: 7A           PLY 
C1/DF08: 60           RTS 

C1/DF09: DA           PHX 
C1/DF0A: 20 74 FC     JSR $FC74
C1/DF0D: 85 82        STA $82
C1/DF0F: A5 DE        LDA $DE
C1/DF11: 25 82        AND $82
C1/DF13: F0 03        BEQ $DF18
C1/DF15: FA           PLX 
C1/DF16: 38           SEC 
C1/DF17: 60           RTS 
C1/DF18: FA           PLX 
C1/DF19: 18           CLC 
C1/DF1A: 60           RTS 

C1/DF1B: AD E4 DB     LDA $DBE4
C1/DF1E: F0 02        BEQ $DF22
C1/DF20: 38           SEC 
C1/DF21: 60           RTS 
C1/DF22: 18           CLC 
C1/DF23: 60           RTS 

; [ animation command $80:  ]

; b1: -aaaaccc
;     a: 
;     c: 

C1/DF24: C8           INY 
C1/DF25: B7 70        LDA [$70],Y
C1/DF27: 29 07        AND #$07
C1/DF29: D0 33        BNE $DF5E
C1/DF2B: BD E2 D3     LDA $D3E2,X
C1/DF2E: 30 09        BMI $DF39
C1/DF30: 29 03        AND #$03
C1/DF32: DA           PHX 
C1/DF33: AA           TAX 
C1/DF34: 9E 43 DB     STZ $DB43,X     ; don't use target palette (character)
C1/DF37: FA           PLX 
C1/DF38: 60           RTS 
C1/DF39: BD E2 D3     LDA $D3E2,X
C1/DF3C: 29 07        AND #$07
C1/DF3E: 85 80        STA $80
C1/DF40: 20 09 DF     JSR $DF09
C1/DF43: 90 18        BCC $DF5D
C1/DF45: 20 1B DF     JSR $DF1B
C1/DF48: 90 0F        BCC $DF59
C1/DF4A: 64 80        STZ $80
C1/DF4C: 7B           TDC 
C1/DF4D: 20 A6 1A     JSR $1AA6
C1/DF50: A9 01        LDA #$01
C1/DF52: 85 80        STA $80
C1/DF54: 7B           TDC 
C1/DF55: 20 A6 1A     JSR $1AA6
C1/DF58: 60           RTS 
C1/DF59: 7B           TDC 
C1/DF5A: 20 A6 1A     JSR $1AA6
C1/DF5D: 60           RTS 
C1/DF5E: B7 70        LDA [$70],Y
C1/DF60: 4A           LSR 
C1/DF61: 4A           LSR 
C1/DF62: 4A           LSR 
C1/DF63: 29 0F        AND #$0F
C1/DF65: 20 D1 DE     JSR $DED1
C1/DF68: BD E2 D3     LDA $D3E2,X
C1/DF6B: 10 25        BPL $DF92
C1/DF6D: 29 07        AND #$07
C1/DF6F: 85 80        STA $80
C1/DF71: 20 09 DF     JSR $DF09
C1/DF74: 90 27        BCC $DF9D
C1/DF76: 20 1B DF     JSR $DF1B
C1/DF79: 90 12        BCC $DF8D
C1/DF7B: 64 80        STZ $80
C1/DF7D: A9 0C        LDA #$0C
C1/DF7F: 20 A6 1A     JSR $1AA6
C1/DF82: A9 01        LDA #$01
C1/DF84: 85 80        STA $80
C1/DF86: A9 0C        LDA #$0C
C1/DF88: 20 A6 1A     JSR $1AA6
C1/DF8B: 80 05        BRA $DF92
C1/DF8D: A9 0C        LDA #$0C
C1/DF8F: 20 A6 1A     JSR $1AA6
C1/DF92: B7 70        LDA [$70],Y
C1/DF94: 29 07        AND #$07
C1/DF96: C9 02        CMP #$02
C1/DF98: D0 03        BNE $DF9D
C1/DF9A: EE 56 DB     INC $DB56
C1/DF9D: 60           RTS 

; [ animation command $F7:  ]

C1/DF9E: DA           PHX 
C1/DF9F: 5A           PHY 
C1/DFA0: 84 7E        STY $7E
C1/DFA2: C2 20        REP #$20
C1/DFA4: 7B           TDC 
C1/DFA5: A8           TAY 
C1/DFA6: B9 70 00     LDA $0070,Y
C1/DFA9: 48           PHA 
C1/DFAA: C8           INY 
C1/DFAB: C8           INY 
C1/DFAC: C0 0C 00     CPY #$000C
C1/DFAF: D0 F5        BNE $DFA6
C1/DFB1: 7B           TDC 
C1/DFB2: E2 20        SEP #$20
C1/DFB4: A4 7E        LDY $7E
C1/DFB6: C8           INY 
C1/DFB7: B7 70        LDA [$70],Y
C1/DFB9: 85 72        STA $72
C1/DFBB: BD E1 D3     LDA $D3E1,X
C1/DFBE: 10 0C        BPL $DFCC
C1/DFC0: 29 07        AND #$07
C1/DFC2: 20 74 FC     JSR $FC74       ; get bit mask
C1/DFC5: 85 70        STA $70
C1/DFC7: A5 72        LDA $72
C1/DFC9: 20 13 76     JSR $7613
C1/DFCC: C2 20        REP #$20
C1/DFCE: A0 0C 00     LDY #$000C
C1/DFD1: 68           PLA 
C1/DFD2: 99 6E 00     STA $006E,Y
C1/DFD5: 88           DEY 
C1/DFD6: 88           DEY 
C1/DFD7: D0 F8        BNE $DFD1
C1/DFD9: 7B           TDC 
C1/DFDA: E2 20        SEP #$20
C1/DFDC: 7A           PLY 
C1/DFDD: FA           PLX 
C1/DFDE: C8           INY 
C1/DFDF: 60           RTS 

; [  ]

C1/DFE0: DA           PHX 
C1/DFE1: 5A           PHY 
C1/DFE2: 84 7E        STY $7E
C1/DFE4: C2 20        REP #$20
C1/DFE6: 7B           TDC 
C1/DFE7: A8           TAY 
C1/DFE8: B9 70 00     LDA $0070,Y
C1/DFEB: 48           PHA 
C1/DFEC: C8           INY 
C1/DFED: C8           INY 
C1/DFEE: C0 0C 00     CPY #$000C
C1/DFF1: D0 F5        BNE $DFE8
C1/DFF3: 7B           TDC 
C1/DFF4: E2 20        SEP #$20
C1/DFF6: A4 7E        LDY $7E
C1/DFF8: C8           INY 
C1/DFF9: B7 70        LDA [$70],Y
C1/DFFB: 85 72        STA $72
C1/DFFD: BD E2 D3     LDA $D3E2,X
C1/E000: 10 0C        BPL $E00E
C1/E002: 29 07        AND #$07
C1/E004: 20 74 FC     JSR $FC74       ; get bit mask
C1/E007: 85 70        STA $70
C1/E009: A5 72        LDA $72
C1/E00B: 20 13 76     JSR $7613
C1/E00E: C2 20        REP #$20
C1/E010: A0 0C 00     LDY #$000C
C1/E013: 68           PLA 
C1/E014: 99 6E 00     STA $006E,Y
C1/E017: 88           DEY 
C1/E018: 88           DEY 
C1/E019: D0 F8        BNE $E013
C1/E01B: 7B           TDC 
C1/E01C: E2 20        SEP #$20
C1/E01E: 7A           PLY 
C1/E01F: FA           PLX 
C1/E020: C8           INY 
C1/E021: 60           RTS 

; [  ]

C1/E022: BD E6 D3     LDA $D3E6,X
C1/E025: 18           CLC 
C1/E026: 69 08        ADC #$08
C1/E028: 9D E6 D3     STA $D3E6,X
C1/E02B: C2 20        REP #$20
C1/E02D: BD E4 D3     LDA $D3E4,X
C1/E030: 38           SEC 
C1/E031: E9 08 00     SBC #$0008
C1/E034: 9D E4 D3     STA $D3E4,X
C1/E037: BD E4 D3     LDA $D3E4,X
C1/E03A: 30 15        BMI $E051
C1/E03C: 7B           TDC 
C1/E03D: E2 20        SEP #$20
C1/E03F: 88           DEY 
C1/E040: 88           DEY 
C1/E041: 20 BC E0     JSR $E0BC
C1/E044: FE E1 D5     INC $D5E1,X
C1/E047: BD E1 D5     LDA $D5E1,X
C1/E04A: 29 02        AND #$02
C1/E04C: 4A           LSR 
C1/E04D: 9D E3 D1     STA $D1E3,X
C1/E050: 60           RTS 

; [  ]

C1/E051: 7B           TDC 
C1/E052: E2 20        SEP #$20
C1/E054: 9E E3 D1     STZ $D1E3,X
C1/E057: 60           RTS 
C1/E058: BD DC D5     LDA $D5DC,X
C1/E05B: 85 A6        STA $A6
C1/E05D: BD DE D5     LDA $D5DE,X
C1/E060: 85 A7        STA $A7
C1/E062: BD D8 D5     LDA $D5D8,X
C1/E065: 85 A8        STA $A8
C1/E067: BD DA D5     LDA $D5DA,X
C1/E06A: 85 A9        STA $A9
C1/E06C: DA           PHX 
C1/E06D: 20 6E 0A     JSR $0A6E
C1/E070: FA           PLX 
C1/E071: A5 AE        LDA $AE
C1/E073: 9D E3 D3     STA $D3E3,X
C1/E076: A5 AF        LDA $AF
C1/E078: 9D E4 D3     STA $D3E4,X
C1/E07B: A5 B0        LDA $B0
C1/E07D: 9D E5 D3     STA $D3E5,X
C1/E080: 9E E6 D3     STZ $D3E6,X
C1/E083: 4C BC E0     JMP $E0BC

; [  ]

C1/E086: DA           PHX 
C1/E087: 8A           TXA 
C1/E088: 4A           LSR 
C1/E089: 4A           LSR 
C1/E08A: 4A           LSR 
C1/E08B: 4A           LSR 
C1/E08C: AA           TAX 
C1/E08D: BF D4 E3 C1  LDA $C1E3D4,X
C1/E091: 20 57 FC     JSR $FC57
C1/E094: FA           PLX 
C1/E095: 60           RTS 

; [  ]

C1/E096: C8           INY 
C1/E097: B7 70        LDA [$70],Y
C1/E099: 4C 57 FC     JMP $FC57
C1/E09C: C2 20        REP #$20
C1/E09E: BD DF D1     LDA $D1DF,X
C1/E0A1: 18           CLC 
C1/E0A2: 69 90 00     ADC #$0090
C1/E0A5: 9D DF D1     STA $D1DF,X
C1/E0A8: BD E1 D1     LDA $D1E1,X
C1/E0AB: 38           SEC 
C1/E0AC: E9 90 00     SBC #$0090
C1/E0AF: 9D E1 D1     STA $D1E1,X
C1/E0B2: BD DC D1     LDA $D1DC,X
C1/E0B5: 9D E2 D5     STA $D5E2,X
C1/E0B8: 7B           TDC 
C1/E0B9: E2 20        SEP #$20
C1/E0BB: 60           RTS 

; [  ]

C1/E0BC: 5A           PHY 
C1/E0BD: DA           PHX 
C1/E0BE: 64 81        STZ $81
C1/E0C0: BD E6 D3     LDA $D3E6,X
C1/E0C3: 85 80        STA $80
C1/E0C5: BD E3 D3     LDA $D3E3,X
C1/E0C8: 18           CLC 
C1/E0C9: 69 40        ADC #$40
C1/E0CB: 20 59 0B     JSR $0B59
C1/E0CE: FA           PLX 
C1/E0CF: C2 20        REP #$20
C1/E0D1: A5 84        LDA $84
C1/E0D3: 18           CLC 
C1/E0D4: 7D DC D5     ADC $D5DC,X
C1/E0D7: 9D DF D1     STA $D1DF,X
C1/E0DA: 7B           TDC 
C1/E0DB: E2 20        SEP #$20
C1/E0DD: DA           PHX 
C1/E0DE: 64 81        STZ $81
C1/E0E0: BD E6 D3     LDA $D3E6,X
C1/E0E3: 85 80        STA $80
C1/E0E5: BD E3 D3     LDA $D3E3,X
C1/E0E8: 20 59 0B     JSR $0B59
C1/E0EB: FA           PLX 
C1/E0EC: C2 20        REP #$20
C1/E0EE: A5 84        LDA $84
C1/E0F0: 18           CLC 
C1/E0F1: 7D DE D5     ADC $D5DE,X
C1/E0F4: 9D E1 D1     STA $D1E1,X
C1/E0F7: 7B           TDC 
C1/E0F8: E2 20        SEP #$20
C1/E0FA: 7A           PLY 
C1/E0FB: 60           RTS 
C1/E0FC: 9E E2 D7     STZ $D7E2,X
C1/E0FF: BD DD D1     LDA $D1DD,X
C1/E102: 9D E3 D5     STA $D5E3,X
C1/E105: 4C 3B E2     JMP $E23B
C1/E108: C2 20        REP #$20
C1/E10A: BD DF D1     LDA $D1DF,X
C1/E10D: 38           SEC 
C1/E10E: E9 08 00     SBC #$0008
C1/E111: 9D DF D1     STA $D1DF,X
C1/E114: BD E1 D1     LDA $D1E1,X
C1/E117: 18           CLC 
C1/E118: 69 08 00     ADC #$0008
C1/E11B: 9D E1 D1     STA $D1E1,X
C1/E11E: 7B           TDC 
C1/E11F: E2 20        SEP #$20
C1/E121: DA           PHX 
C1/E122: A9 10        LDA #$10
C1/E124: 85 80        STA $80
C1/E126: BD E1 D5     LDA $D5E1,X
C1/E129: 0A           ASL 
C1/E12A: 0A           ASL 
C1/E12B: 0A           ASL 
C1/E12C: 0A           ASL 
C1/E12D: 20 00 0A     JSR $0A00
C1/E130: FA           PLX 
C1/E131: 18           CLC 
C1/E132: 7D E3 D5     ADC $D5E3,X
C1/E135: 9D DD D1     STA $D1DD,X
C1/E138: BD E1 D5     LDA $D5E1,X
C1/E13B: C9 24        CMP #$24
C1/E13D: F0 05        BEQ $E144
C1/E13F: FE E1 D5     INC $D5E1,X
C1/E142: 88           DEY 
C1/E143: 88           DEY 
C1/E144: 60           RTS 
C1/E145: BD E6 D3     LDA $D3E6,X
C1/E148: 18           CLC 
C1/E149: 69 04        ADC #$04
C1/E14B: 9D E6 D3     STA $D3E6,X
C1/E14E: C2 20        REP #$20
C1/E150: BD E4 D3     LDA $D3E4,X
C1/E153: 38           SEC 
C1/E154: E9 04 00     SBC #$0004
C1/E157: 9D E4 D3     STA $D3E4,X
C1/E15A: BD E4 D3     LDA $D3E4,X
C1/E15D: 30 21        BMI $E180
C1/E15F: 7B           TDC 
C1/E160: E2 20        SEP #$20
C1/E162: 88           DEY 
C1/E163: 88           DEY 
C1/E164: 20 3B E2     JSR $E23B
C1/E167: FE E1 D5     INC $D5E1,X
C1/E16A: A9 10        LDA #$10
C1/E16C: 85 80        STA $80
C1/E16E: BD E1 D5     LDA $D5E1,X
C1/E171: 0A           ASL 
C1/E172: 0A           ASL 
C1/E173: 0A           ASL 
C1/E174: DA           PHX 
C1/E175: 20 00 0A     JSR $0A00
C1/E178: FA           PLX 
C1/E179: 18           CLC 
C1/E17A: 7D E3 D5     ADC $D5E3,X
C1/E17D: 9D DD D1     STA $D1DD,X
C1/E180: 7B           TDC 
C1/E181: E2 20        SEP #$20
C1/E183: 60           RTS 
C1/E184: BD E6 D3     LDA $D3E6,X
C1/E187: 18           CLC 
C1/E188: 69 04        ADC #$04
C1/E18A: 9D E6 D3     STA $D3E6,X
C1/E18D: C2 20        REP #$20
C1/E18F: BD E4 D3     LDA $D3E4,X
C1/E192: 38           SEC 
C1/E193: E9 04 00     SBC #$0004
C1/E196: 9D E4 D3     STA $D3E4,X
C1/E199: BD E4 D3     LDA $D3E4,X
C1/E19C: 30 29        BMI $E1C7
C1/E19E: 7B           TDC 
C1/E19F: E2 20        SEP #$20
C1/E1A1: 88           DEY 
C1/E1A2: 88           DEY 
C1/E1A3: 20 3B E2     JSR $E23B
C1/E1A6: FE E1 D5     INC $D5E1,X
C1/E1A9: A9 10        LDA #$10
C1/E1AB: 85 80        STA $80
C1/E1AD: BD E1 D5     LDA $D5E1,X
C1/E1B0: 0A           ASL 
C1/E1B1: 0A           ASL 
C1/E1B2: 0A           ASL 
C1/E1B3: DA           PHX 
C1/E1B4: 20 00 0A     JSR $0A00
C1/E1B7: FA           PLX 
C1/E1B8: 18           CLC 
C1/E1B9: 7D E3 D5     ADC $D5E3,X
C1/E1BC: 9D DD D1     STA $D1DD,X
C1/E1BF: 8A           TXA 
C1/E1C0: 4A           LSR 
C1/E1C1: 4A           LSR 
C1/E1C2: 4A           LSR 
C1/E1C3: 4A           LSR 
C1/E1C4: 9D E3 D1     STA $D1E3,X
C1/E1C7: 7B           TDC 
C1/E1C8: E2 20        SEP #$20
C1/E1CA: 60           RTS 
C1/E1CB: BD E6 D3     LDA $D3E6,X
C1/E1CE: 18           CLC 
C1/E1CF: 69 08        ADC #$08
C1/E1D1: 9D E6 D3     STA $D3E6,X
C1/E1D4: C2 20        REP #$20
C1/E1D6: BD E4 D3     LDA $D3E4,X
C1/E1D9: 38           SEC 
C1/E1DA: E9 08 00     SBC #$0008
C1/E1DD: 9D E4 D3     STA $D3E4,X
C1/E1E0: BD E4 D3     LDA $D3E4,X
C1/E1E3: 30 17        BMI $E1FC
C1/E1E5: 7B           TDC 
C1/E1E6: E2 20        SEP #$20
C1/E1E8: 88           DEY 
C1/E1E9: 88           DEY 
C1/E1EA: 88           DEY 
C1/E1EB: 20 3B E2     JSR $E23B
C1/E1EE: FE E1 D5     INC $D5E1,X
C1/E1F1: BD E1 D5     LDA $D5E1,X
C1/E1F4: 29 0C        AND #$0C
C1/E1F6: 4A           LSR 
C1/E1F7: 4A           LSR 
C1/E1F8: 9D E3 D1     STA $D1E3,X
C1/E1FB: 60           RTS 
C1/E1FC: 7B           TDC 
C1/E1FD: E2 20        SEP #$20
C1/E1FF: 9E E3 D1     STZ $D1E3,X
C1/E202: 60           RTS 
C1/E203: BD E6 D3     LDA $D3E6,X
C1/E206: 18           CLC 
C1/E207: 69 08        ADC #$08
C1/E209: 9D E6 D3     STA $D3E6,X
C1/E20C: C2 20        REP #$20
C1/E20E: BD E4 D3     LDA $D3E4,X
C1/E211: 38           SEC 
C1/E212: E9 08 00     SBC #$0008
C1/E215: 9D E4 D3     STA $D3E4,X
C1/E218: BD E4 D3     LDA $D3E4,X
C1/E21B: 30 17        BMI $E234
C1/E21D: 7B           TDC 
C1/E21E: E2 20        SEP #$20
C1/E220: 88           DEY 
C1/E221: 88           DEY 
C1/E222: 88           DEY 
C1/E223: 20 3B E2     JSR $E23B
C1/E226: FE E1 D5     INC $D5E1,X
C1/E229: BD E1 D5     LDA $D5E1,X
C1/E22C: 29 04        AND #$04
C1/E22E: 4A           LSR 
C1/E22F: 4A           LSR 
C1/E230: 9D E3 D1     STA $D1E3,X
C1/E233: 60           RTS 
C1/E234: 7B           TDC 
C1/E235: E2 20        SEP #$20
C1/E237: 9E E3 D1     STZ $D1E3,X
C1/E23A: 60           RTS 
C1/E23B: 5A           PHY 
C1/E23C: DA           PHX 
C1/E23D: 64 81        STZ $81
C1/E23F: BD E6 D3     LDA $D3E6,X
C1/E242: 85 80        STA $80
C1/E244: BD E3 D3     LDA $D3E3,X
C1/E247: 18           CLC 
C1/E248: 69 40        ADC #$40
C1/E24A: 20 59 0B     JSR $0B59
C1/E24D: FA           PLX 
C1/E24E: C2 20        REP #$20
C1/E250: A5 84        LDA $84
C1/E252: 18           CLC 
C1/E253: 7D D8 D5     ADC $D5D8,X
C1/E256: 9D DF D1     STA $D1DF,X
C1/E259: 7B           TDC 
C1/E25A: E2 20        SEP #$20
C1/E25C: DA           PHX 
C1/E25D: 64 81        STZ $81
C1/E25F: BD E6 D3     LDA $D3E6,X
C1/E262: 85 80        STA $80
C1/E264: BD E3 D3     LDA $D3E3,X
C1/E267: 20 59 0B     JSR $0B59
C1/E26A: FA           PLX 
C1/E26B: C2 20        REP #$20
C1/E26D: A5 84        LDA $84
C1/E26F: 18           CLC 
C1/E270: 7D DA D5     ADC $D5DA,X
C1/E273: 9D E1 D1     STA $D1E1,X
C1/E276: 7B           TDC 
C1/E277: E2 20        SEP #$20
C1/E279: 7A           PLY 
C1/E27A: 60           RTS 
C1/E27B: A9 01        LDA #$01
C1/E27D: 85 7E        STA $7E
C1/E27F: A9 07        LDA #$07
C1/E281: 85 80        STA $80
C1/E283: DA           PHX 
C1/E284: 06 7E        ASL $7E
C1/E286: A5 7E        LDA $7E
C1/E288: AA           TAX 
C1/E289: 64 81        STZ $81
C1/E28B: C2 20        REP #$20
C1/E28D: C6 80        DEC $80
C1/E28F: BD 69 7F     LDA $7F69,X
C1/E292: 48           PHA 
C1/E293: 85 82        STA $82
C1/E295: BD 6B 7F     LDA $7F6B,X
C1/E298: 9D 69 7F     STA $7F69,X
C1/E29B: E8           INX 
C1/E29C: E8           INX 
C1/E29D: C6 80        DEC $80
C1/E29F: D0 F2        BNE $E293
C1/E2A1: 68           PLA 
C1/E2A2: 9D 69 7F     STA $7F69,X
C1/E2A5: 7B           TDC 
C1/E2A6: E2 20        SEP #$20
C1/E2A8: FA           PLX 
C1/E2A9: 60           RTS 
C1/E2AA: A9 01        LDA #$01
C1/E2AC: 85 7E        STA $7E
C1/E2AE: A9 07        LDA #$07
C1/E2B0: 85 80        STA $80
C1/E2B2: DA           PHX 
C1/E2B3: 06 7E        ASL $7E
C1/E2B5: C6 80        DEC $80
C1/E2B7: A5 80        LDA $80
C1/E2B9: 0A           ASL 
C1/E2BA: 18           CLC 
C1/E2BB: 65 7E        ADC $7E
C1/E2BD: AA           TAX 
C1/E2BE: 64 81        STZ $81
C1/E2C0: C2 20        REP #$20
C1/E2C2: BD 69 7F     LDA $7F69,X
C1/E2C5: 48           PHA 
C1/E2C6: BD 67 7F     LDA $7F67,X
C1/E2C9: 9D 69 7F     STA $7F69,X
C1/E2CC: CA           DEX 
C1/E2CD: CA           DEX 
C1/E2CE: C6 80        DEC $80
C1/E2D0: D0 F4        BNE $E2C6
C1/E2D2: 68           PLA 
C1/E2D3: 9D 69 7F     STA $7F69,X
C1/E2D6: 7B           TDC 
C1/E2D7: E2 20        SEP #$20
C1/E2D9: FA           PLX 
C1/E2DA: 60           RTS 
C1/E2DB: DA           PHX 
C1/E2DC: 20 89 E5     JSR $E589
C1/E2DF: A5 80        LDA $80
C1/E2E1: 9D 7B CE     STA $CE7B,X
C1/E2E4: 18           CLC 
C1/E2E5: 69 40        ADC #$40
C1/E2E7: 9D BB CE     STA $CEBB,X
C1/E2EA: A9 18        LDA #$18
C1/E2EC: 9D FB CD     STA $CDFB,X
C1/E2EF: A9 08        LDA #$08
C1/E2F1: 9D 3B CE     STA $CE3B,X
C1/E2F4: A9 20        LDA #$20
C1/E2F6: 9D FB CE     STA $CEFB,X
C1/E2F9: 20 5B E4     JSR $E45B
C1/E2FC: A6 78        LDX $78
C1/E2FE: A5 86        LDA $86
C1/E300: 9D DC D1     STA $D1DC,X
C1/E303: A5 87        LDA $87
C1/E305: 9D DD D1     STA $D1DD,X
C1/E308: FA           PLX 
C1/E309: 60           RTS 
C1/E30A: DA           PHX 
C1/E30B: 20 89 E5     JSR $E589
C1/E30E: A5 80        LDA $80
C1/E310: 9D 7B CE     STA $CE7B,X
C1/E313: 18           CLC 
C1/E314: 69 40        ADC #$40
C1/E316: 9D BB CE     STA $CEBB,X
C1/E319: 9E FB CD     STZ $CDFB,X
C1/E31C: 9E 3B CE     STZ $CE3B,X
C1/E31F: A9 01        LDA #$01
C1/E321: 9D FB CE     STA $CEFB,X
C1/E324: FA           PLX 
C1/E325: 60           RTS 
C1/E326: DA           PHX 
C1/E327: 20 91 E3     JSR $E391
C1/E32A: 18           CLC 
C1/E32B: 69 40        ADC #$40
C1/E32D: 9D BB CE     STA $CEBB,X
C1/E330: A9 70        LDA #$70
C1/E332: 9D FB CD     STA $CDFB,X
C1/E335: 9D 3B CE     STA $CE3B,X
C1/E338: A9 FC        LDA #$FC
C1/E33A: 9D FB CE     STA $CEFB,X
C1/E33D: 4C C0 E3     JMP $E3C0
C1/E340: DA           PHX 
C1/E341: 20 89 E5     JSR $E589
C1/E344: A5 80        LDA $80
C1/E346: 9D 7B CE     STA $CE7B,X
C1/E349: 18           CLC 
C1/E34A: 69 40        ADC #$40
C1/E34C: 9D BB CE     STA $CEBB,X
C1/E34F: A9 10        LDA #$10
C1/E351: 9D FB CD     STA $CDFB,X
C1/E354: 9D 3B CE     STA $CE3B,X
C1/E357: A9 10        LDA #$10
C1/E359: 9D FB CE     STA $CEFB,X
C1/E35C: 20 5B E4     JSR $E45B
C1/E35F: A6 78        LDX $78
C1/E361: A5 86        LDA $86
C1/E363: 9D DC D1     STA $D1DC,X
C1/E366: A5 87        LDA $87
C1/E368: 9D DD D1     STA $D1DD,X
C1/E36B: A9 07        LDA #$07
C1/E36D: 9D E3 D1     STA $D1E3,X
C1/E370: FA           PLX 
C1/E371: 60           RTS 
C1/E372: DA           PHX 
C1/E373: 20 89 E5     JSR $E589
C1/E376: A5 80        LDA $80
C1/E378: 9D 7B CE     STA $CE7B,X
C1/E37B: 18           CLC 
C1/E37C: 69 40        ADC #$40
C1/E37E: 9D BB CE     STA $CEBB,X
C1/E381: A9 70        LDA #$70
C1/E383: 9D FB CD     STA $CDFB,X
C1/E386: 9D 3B CE     STA $CE3B,X
C1/E389: A9 FC        LDA #$FC
C1/E38B: 9D FB CE     STA $CEFB,X
C1/E38E: 4C C0 E3     JMP $E3C0
C1/E391: 86 78        STX $78
C1/E393: 8A           TXA 
C1/E394: 4A           LSR 
C1/E395: 4A           LSR 
C1/E396: 4A           LSR 
C1/E397: 4A           LSR 
C1/E398: 85 84        STA $84
C1/E39A: 64 85        STZ $85
C1/E39C: AA           TAX 
C1/E39D: 20 96 FC     JSR $FC96       ; generate random number
C1/E3A0: 9D 7B CE     STA $CE7B,X
C1/E3A3: 60           RTS 
C1/E3A4: DA           PHX 
C1/E3A5: 20 89 E5     JSR $E589
C1/E3A8: A5 80        LDA $80
C1/E3AA: 9D 7B CE     STA $CE7B,X
C1/E3AD: 18           CLC 
C1/E3AE: 69 40        ADC #$40
C1/E3B0: 9D BB CE     STA $CEBB,X
C1/E3B3: A9 40        LDA #$40
C1/E3B5: 9D FB CD     STA $CDFB,X
C1/E3B8: 9D 3B CE     STA $CE3B,X
C1/E3BB: A9 FC        LDA #$FC
C1/E3BD: 9D FB CE     STA $CEFB,X
C1/E3C0: 20 5B E4     JSR $E45B
C1/E3C3: A6 78        LDX $78
C1/E3C5: A5 86        LDA $86
C1/E3C7: 9D DC D1     STA $D1DC,X
C1/E3CA: A5 87        LDA $87
C1/E3CC: 9D DD D1     STA $D1DD,X
C1/E3CF: 9E E3 D1     STZ $D1E3,X
C1/E3D2: FA           PLX 
C1/E3D3: 60           RTS 

C1/E3D4: 00 00        BRK $00
C1/E3D6: 00 00        BRK $00
C1/E3D8: 0E 0C 10     ASL $100C
C1/E3DB: 0A           ASL 
C1/E3DC: 60           RTS 
C1/E3DD: 00 40        BRK $40
C1/E3DF: 20 C0 A0     JSR $A0C0
C1/E3E2: E0 80 08     CPX #$0880
C1/E3E5: 02 06        COP $06
C1/E3E7: 04 0E        TSB $0E
C1/E3E9: 0C 10 0A     TSB $0A10

C1/E3EC: DA           PHX 
C1/E3ED: 20 89 E5     JSR $E589
C1/E3F0: DA           PHX 
C1/E3F1: BF DC E3 C1  LDA $C1E3DC,X
C1/E3F5: FA           PLX 
C1/E3F6: 38           SEC 
C1/E3F7: E9 40        SBC #$40
C1/E3F9: 9D 7B CE     STA $CE7B,X
C1/E3FC: 18           CLC 
C1/E3FD: 69 40        ADC #$40
C1/E3FF: 9D BB CE     STA $CEBB,X
C1/E402: A9 18        LDA #$18
C1/E404: 9D FB CD     STA $CDFB,X
C1/E407: A9 08        LDA #$08
C1/E409: 9D 3B CE     STA $CE3B,X
C1/E40C: A9 02        LDA #$02
C1/E40E: 9D FB CE     STA $CEFB,X
C1/E411: 20 5B E4     JSR $E45B
C1/E414: A6 78        LDX $78
C1/E416: A5 86        LDA $86
C1/E418: 9D DC D1     STA $D1DC,X
C1/E41B: A5 87        LDA $87
C1/E41D: 9D DD D1     STA $D1DD,X
C1/E420: 9E E3 D1     STZ $D1E3,X
C1/E423: FA           PLX 
C1/E424: 60           RTS 

; [ animation command $94:  ]

C1/E425: DA           PHX 
C1/E426: 20 89 E5     JSR $E589
C1/E429: A5 80        LDA $80
C1/E42B: 9D 7B CE     STA $CE7B,X
C1/E42E: 18           CLC 
C1/E42F: 69 40        ADC #$40
C1/E431: 9D BB CE     STA $CEBB,X
C1/E434: A9 04        LDA #$04
C1/E436: 9D FB CD     STA $CDFB,X
C1/E439: 9D 3B CE     STA $CE3B,X
C1/E43C: A9 02        LDA #$02
C1/E43E: 9D FB CE     STA $CEFB,X
C1/E441: 20 5B E4     JSR $E45B
C1/E444: A6 78        LDX $78
C1/E446: A5 86        LDA $86
C1/E448: 38           SEC 
C1/E449: E9 05        SBC #$05
C1/E44B: 9D DC D1     STA $D1DC,X
C1/E44E: A5 87        LDA $87
C1/E450: 38           SEC 
C1/E451: E9 08        SBC #$08
C1/E453: 9D DD D1     STA $D1DD,X
C1/E456: 9E E3 D1     STZ $D1E3,X
C1/E459: FA           PLX 
C1/E45A: 60           RTS 

; [  ]

C1/E45B: A6 84        LDX $84
C1/E45D: 20 CA 09     JSR $09CA
C1/E460: 85 86        STA $86
C1/E462: A6 84        LDX $84
C1/E464: 20 E5 09     JSR $09E5
C1/E467: 85 87        STA $87
C1/E469: 60           RTS 

; [ animation command $95:  ]

C1/E46A: DA           PHX 
C1/E46B: 20 89 E5     JSR $E589
C1/E46E: 20 5B E4     JSR $E45B
C1/E471: A6 84        LDX $84
C1/E473: A9 FC        LDA #$FC
C1/E475: 20 96 09     JSR $0996
C1/E478: A6 84        LDX $84
C1/E47A: BD FB CE     LDA $CEFB,X
C1/E47D: 20 B9 09     JSR $09B9
C1/E480: C9 20        CMP #$20
C1/E482: B0 28        BCS $E4AC
C1/E484: 29 07        AND #$07
C1/E486: D0 0E        BNE $E496
C1/E488: A6 78        LDX $78
C1/E48A: BD E3 D1     LDA $D1E3,X
C1/E48D: 29 03        AND #$03
C1/E48F: C9 03        CMP #$03
C1/E491: F0 03        BEQ $E496
C1/E493: FE E3 D1     INC $D1E3,X
C1/E496: A6 78        LDX $78
C1/E498: A5 86        LDA $86
C1/E49A: 38           SEC 
C1/E49B: E9 05        SBC #$05
C1/E49D: 9D DC D1     STA $D1DC,X
C1/E4A0: A5 87        LDA $87
C1/E4A2: 38           SEC 
C1/E4A3: E9 08        SBC #$08
C1/E4A5: 9D DD D1     STA $D1DD,X
C1/E4A8: 88           DEY 
C1/E4A9: 88           DEY 
C1/E4AA: FA           PLX 
C1/E4AB: 60           RTS 
C1/E4AC: A6 78        LDX $78
C1/E4AE: 9E E3 D1     STZ $D1E3,X
C1/E4B1: FA           PLX 
C1/E4B2: 60           RTS 
C1/E4B3: BD FB CD     LDA $CDFB,X
C1/E4B6: A2 07 00     LDX #$0007
C1/E4B9: C9 08        CMP #$08
C1/E4BB: 90 1F        BCC $E4DC
C1/E4BD: CA           DEX 
C1/E4BE: C9 10        CMP #$10
C1/E4C0: 90 1A        BCC $E4DC
C1/E4C2: CA           DEX 
C1/E4C3: C9 18        CMP #$18
C1/E4C5: 90 15        BCC $E4DC
C1/E4C7: CA           DEX 
C1/E4C8: C9 20        CMP #$20
C1/E4CA: 90 10        BCC $E4DC
C1/E4CC: CA           DEX 
C1/E4CD: C9 28        CMP #$28
C1/E4CF: 90 0B        BCC $E4DC
C1/E4D1: CA           DEX 
C1/E4D2: C9 30        CMP #$30
C1/E4D4: 90 06        BCC $E4DC
C1/E4D6: CA           DEX 
C1/E4D7: C9 38        CMP #$38
C1/E4D9: 90 01        BCC $E4DC
C1/E4DB: CA           DEX 
C1/E4DC: 8A           TXA 
C1/E4DD: 60           RTS 
C1/E4DE: DA           PHX 
C1/E4DF: 20 89 E5     JSR $E589
C1/E4E2: 20 5B E4     JSR $E45B
C1/E4E5: A6 84        LDX $84
C1/E4E7: A9 FC        LDA #$FC
C1/E4E9: 20 96 09     JSR $0996
C1/E4EC: A6 84        LDX $84
C1/E4EE: BD FB CD     LDA $CDFB,X
C1/E4F1: F0 21        BEQ $E514
C1/E4F3: BD FB CE     LDA $CEFB,X
C1/E4F6: 20 B9 09     JSR $09B9
C1/E4F9: BD FB CD     LDA $CDFB,X
C1/E4FC: 20 B3 E4     JSR $E4B3
C1/E4FF: A6 78        LDX $78
C1/E501: 9D E3 D1     STA $D1E3,X
C1/E504: A6 78        LDX $78
C1/E506: A5 86        LDA $86
C1/E508: 9D DC D1     STA $D1DC,X
C1/E50B: A5 87        LDA $87
C1/E50D: 9D DD D1     STA $D1DD,X
C1/E510: 88           DEY 
C1/E511: 88           DEY 
C1/E512: FA           PLX 
C1/E513: 60           RTS 
C1/E514: A6 78        LDX $78
C1/E516: 9E E3 D1     STZ $D1E3,X
C1/E519: FA           PLX 
C1/E51A: 60           RTS 
C1/E51B: DA           PHX 
C1/E51C: 20 89 E5     JSR $E589
C1/E51F: 20 5B E4     JSR $E45B
C1/E522: A6 84        LDX $84
C1/E524: BD FB CD     LDA $CDFB,X
C1/E527: F0 21        BEQ $E54A
C1/E529: BD FB CE     LDA $CEFB,X
C1/E52C: 20 B9 09     JSR $09B9
C1/E52F: BD FB CD     LDA $CDFB,X
C1/E532: 20 B3 E4     JSR $E4B3
C1/E535: A6 78        LDX $78
C1/E537: 9D E3 D1     STA $D1E3,X
C1/E53A: A6 78        LDX $78
C1/E53C: A5 86        LDA $86
C1/E53E: 9D DC D1     STA $D1DC,X
C1/E541: A5 87        LDA $87
C1/E543: 9D DD D1     STA $D1DD,X
C1/E546: 88           DEY 
C1/E547: 88           DEY 
C1/E548: FA           PLX 
C1/E549: 60           RTS 
C1/E54A: A6 78        LDX $78
C1/E54C: 9E E3 D1     STZ $D1E3,X
C1/E54F: FA           PLX 
C1/E550: 60           RTS 
C1/E551: DA           PHX 
C1/E552: 20 89 E5     JSR $E589
C1/E555: 20 5B E4     JSR $E45B
C1/E558: A6 84        LDX $84
C1/E55A: BD FB CD     LDA $CDFB,X
C1/E55D: C9 70        CMP #$70
C1/E55F: F0 21        BEQ $E582
C1/E561: BD FB CE     LDA $CEFB,X
C1/E564: 20 B9 09     JSR $09B9
C1/E567: BD FB CD     LDA $CDFB,X
C1/E56A: 20 B3 E4     JSR $E4B3
C1/E56D: A6 78        LDX $78
C1/E56F: 9D E3 D1     STA $D1E3,X
C1/E572: A6 78        LDX $78
C1/E574: A5 86        LDA $86
C1/E576: 9D DC D1     STA $D1DC,X
C1/E579: A5 87        LDA $87
C1/E57B: 9D DD D1     STA $D1DD,X
C1/E57E: 88           DEY 
C1/E57F: 88           DEY 
C1/E580: FA           PLX 
C1/E581: 60           RTS 
C1/E582: A6 78        LDX $78
C1/E584: 9E E3 D1     STZ $D1E3,X
C1/E587: FA           PLX 
C1/E588: 60           RTS 
C1/E589: 8A           TXA 
C1/E58A: 86 78        STX $78
C1/E58C: 0A           ASL 
C1/E58D: 85 80        STA $80
C1/E58F: 8A           TXA 
C1/E590: 4A           LSR 
C1/E591: 4A           LSR 
C1/E592: 4A           LSR 
C1/E593: 4A           LSR 
C1/E594: 85 84        STA $84
C1/E596: 64 85        STZ $85
C1/E598: AA           TAX 
C1/E599: 60           RTS 
C1/E59A: DA           PHX 
C1/E59B: 20 89 E5     JSR $E589
C1/E59E: 20 5B E4     JSR $E45B
C1/E5A1: A6 84        LDX $84
C1/E5A3: BD FB CE     LDA $CEFB,X
C1/E5A6: 20 B9 09     JSR $09B9
C1/E5A9: C9 20        CMP #$20
C1/E5AB: B0 1B        BCS $E5C8
C1/E5AD: 4A           LSR 
C1/E5AE: 4A           LSR 
C1/E5AF: 4A           LSR 
C1/E5B0: 29 03        AND #$03
C1/E5B2: A6 78        LDX $78
C1/E5B4: 9D E3 D1     STA $D1E3,X
C1/E5B7: A5 86        LDA $86
C1/E5B9: 9D DC D1     STA $D1DC,X
C1/E5BC: A5 87        LDA $87
C1/E5BE: 38           SEC 
C1/E5BF: E9 08        SBC #$08
C1/E5C1: 9D DD D1     STA $D1DD,X
C1/E5C4: 88           DEY 
C1/E5C5: 88           DEY 
C1/E5C6: FA           PLX 
C1/E5C7: 60           RTS 
C1/E5C8: A6 78        LDX $78
C1/E5CA: 9E E3 D1     STZ $D1E3,X
C1/E5CD: FA           PLX 
C1/E5CE: 60           RTS 
C1/E5CF: DA           PHX 
C1/E5D0: 20 89 E5     JSR $E589
C1/E5D3: 20 5B E4     JSR $E45B
C1/E5D6: A6 84        LDX $84
C1/E5D8: A9 04        LDA #$04
C1/E5DA: 20 96 09     JSR $0996
C1/E5DD: DE FB CE     DEC $CEFB,X
C1/E5E0: F0 29        BEQ $E60B
C1/E5E2: A6 78        LDX $78
C1/E5E4: 29 08        AND #$08
C1/E5E6: 4A           LSR 
C1/E5E7: 4A           LSR 
C1/E5E8: 4A           LSR 
C1/E5E9: 9D E3 D1     STA $D1E3,X
C1/E5EC: A5 87        LDA $87
C1/E5EE: 29 80        AND #$80
C1/E5F0: 4A           LSR 
C1/E5F1: 4A           LSR 
C1/E5F2: 4A           LSR 
C1/E5F3: 4A           LSR 
C1/E5F4: 4A           LSR 
C1/E5F5: 4A           LSR 
C1/E5F6: 18           CLC 
C1/E5F7: 7D E3 D1     ADC $D1E3,X
C1/E5FA: 9D E3 D1     STA $D1E3,X
C1/E5FD: A5 86        LDA $86
C1/E5FF: 9D DC D1     STA $D1DC,X
C1/E602: A5 87        LDA $87
C1/E604: 9D DD D1     STA $D1DD,X
C1/E607: 88           DEY 
C1/E608: 88           DEY 
C1/E609: FA           PLX 
C1/E60A: 60           RTS 
C1/E60B: A6 78        LDX $78
C1/E60D: 9E E3 D1     STZ $D1E3,X
C1/E610: FA           PLX 
C1/E611: 60           RTS 
C1/E612: BD DD D1     LDA $D1DD,X
C1/E615: F0 05        BEQ $E61C
C1/E617: 88           DEY 
C1/E618: 88           DEY 
C1/E619: 88           DEY 
C1/E61A: 88           DEY 
C1/E61B: 88           DEY 
C1/E61C: 60           RTS 
C1/E61D: BD DD D1     LDA $D1DD,X
C1/E620: F0 0F        BEQ $E631
C1/E622: 88           DEY 
C1/E623: 88           DEY 
C1/E624: 88           DEY 
C1/E625: 88           DEY 
C1/E626: A5 A2        LDA $A2
C1/E628: 4A           LSR 
C1/E629: 4A           LSR 
C1/E62A: 4A           LSR 
C1/E62B: 29 01        AND #$01
C1/E62D: 9D E3 D1     STA $D1E3,X
C1/E630: 60           RTS 
C1/E631: 9E E3 D1     STZ $D1E3,X
C1/E634: 60           RTS 
C1/E635: C8           INY 
C1/E636: B7 70        LDA [$70],Y
C1/E638: 85 7E        STA $7E
C1/E63A: DA           PHX 
C1/E63B: 20 96 FC     JSR $FC96       ; generate random number
C1/E63E: 85 80        STA $80
C1/E640: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/E643: FA           PLX 
C1/E644: A5 83        LDA $83
C1/E646: 46 7E        LSR $7E
C1/E648: 38           SEC 
C1/E649: E5 7E        SBC $7E
C1/E64B: 9D DC D1     STA $D1DC,X
C1/E64E: 60           RTS 
C1/E64F: C8           INY 
C1/E650: B7 70        LDA [$70],Y
C1/E652: 0A           ASL 
C1/E653: DA           PHX 
C1/E654: AA           TAX 
C1/E655: BF 65 E6 C1  LDA $C1E665,X
C1/E659: 85 80        STA $80
C1/E65B: BF 66 E6 C1  LDA $C1E666,X
C1/E65F: 85 81        STA $81
C1/E661: FA           PLX 
C1/E662: 6C 80 00     JMP ($0080)
C1/E665: D5 E6        CMP $E6,X
C1/E667: 99 E6 A6     STA $A6E6,Y
C1/E66A: E6 6F        INC $6F
C1/E66C: E6 7C        INC $7C
C1/E66E: E6 AD        INC $AD
C1/E670: 50 DB        BVC $E64D
C1/E672: 29 40        AND #$40
C1/E674: D0 03        BNE $E679
C1/E676: 4C 87 E6     JMP $E687
C1/E679: 4C 90 E6     JMP $E690
C1/E67C: AD 50 DB     LDA $DB50
C1/E67F: 30 03        BMI $E684
C1/E681: 4C 87 E6     JMP $E687
C1/E684: 4C 90 E6     JMP $E690
C1/E687: A9 20        LDA #$20
C1/E689: 85 84        STA $84
C1/E68B: 85 86        STA $86
C1/E68D: 4C 21 E7     JMP $E721
C1/E690: A9 30        LDA #$30
C1/E692: 85 84        STA $84
C1/E694: 85 86        STA $86
C1/E696: 4C 21 E7     JMP $E721
C1/E699: AD 50 DB     LDA $DB50
C1/E69C: 29 40        AND #$40
C1/E69E: D0 03        BNE $E6A3
C1/E6A0: 4C C2 E6     JMP $E6C2
C1/E6A3: 4C B1 E6     JMP $E6B1
C1/E6A6: AD 50 DB     LDA $DB50
C1/E6A9: 30 03        BMI $E6AE
C1/E6AB: 4C C2 E6     JMP $E6C2
C1/E6AE: 4C B1 E6     JMP $E6B1
C1/E6B1: A9 A0        LDA #$A0
C1/E6B3: 85 84        STA $84
C1/E6B5: 64 85        STZ $85
C1/E6B7: A9 70        LDA #$70
C1/E6B9: 85 86        STA $86
C1/E6BB: A9 30        LDA #$30
C1/E6BD: 85 87        STA $87
C1/E6BF: 4C E4 E6     JMP $E6E4
C1/E6C2: A9 40        LDA #$40
C1/E6C4: 85 84        STA $84
C1/E6C6: A9 B0        LDA #$B0
C1/E6C8: 85 85        STA $85
C1/E6CA: A9 70        LDA #$70
C1/E6CC: 85 86        STA $86
C1/E6CE: A9 30        LDA #$30
C1/E6D0: 85 87        STA $87
C1/E6D2: 4C E4 E6     JMP $E6E4
C1/E6D5: A9 FF        LDA #$FF
C1/E6D7: 85 84        STA $84
C1/E6D9: 64 85        STZ $85
C1/E6DB: A9 90        LDA #$90
C1/E6DD: 85 86        STA $86
C1/E6DF: 64 87        STZ $87
C1/E6E1: 4C E4 E6     JMP $E6E4
C1/E6E4: A5 84        LDA $84
C1/E6E6: 85 7E        STA $7E
C1/E6E8: DA           PHX 
C1/E6E9: 20 96 FC     JSR $FC96       ; generate random number
C1/E6EC: 85 80        STA $80
C1/E6EE: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/E6F1: FA           PLX 
C1/E6F2: A5 83        LDA $83
C1/E6F4: 18           CLC 
C1/E6F5: 65 85        ADC $85
C1/E6F7: 9D DF D1     STA $D1DF,X
C1/E6FA: BD E0 D1     LDA $D1E0,X
C1/E6FD: 69 00        ADC #$00
C1/E6FF: 9D E0 D1     STA $D1E0,X
C1/E702: A5 86        LDA $86
C1/E704: 85 7E        STA $7E
C1/E706: DA           PHX 
C1/E707: 20 96 FC     JSR $FC96       ; generate random number
C1/E70A: 85 80        STA $80
C1/E70C: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/E70F: FA           PLX 
C1/E710: A5 83        LDA $83
C1/E712: 18           CLC 
C1/E713: 65 87        ADC $87
C1/E715: 9D E1 D1     STA $D1E1,X
C1/E718: BD E2 D1     LDA $D1E2,X
C1/E71B: 69 00        ADC #$00
C1/E71D: 9D E2 D1     STA $D1E2,X
C1/E720: 60           RTS 
C1/E721: A5 84        LDA $84
C1/E723: 85 7E        STA $7E
C1/E725: DA           PHX 
C1/E726: 20 96 FC     JSR $FC96       ; generate random number
C1/E729: 85 80        STA $80
C1/E72B: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/E72E: FA           PLX 
C1/E72F: 46 84        LSR $84
C1/E731: A5 83        LDA $83
C1/E733: 38           SEC 
C1/E734: E5 84        SBC $84
C1/E736: C2 20        REP #$20
C1/E738: 18           CLC 
C1/E739: 7D DC D5     ADC $D5DC,X
C1/E73C: 29 FF 00     AND #$00FF
C1/E73F: 9D DF D1     STA $D1DF,X
C1/E742: 7B           TDC 
C1/E743: E2 20        SEP #$20
C1/E745: A5 86        LDA $86
C1/E747: 85 7E        STA $7E
C1/E749: DA           PHX 
C1/E74A: 20 96 FC     JSR $FC96       ; generate random number
C1/E74D: 85 80        STA $80
C1/E74F: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/E752: FA           PLX 
C1/E753: A5 83        LDA $83
C1/E755: 46 86        LSR $86
C1/E757: 38           SEC 
C1/E758: E5 86        SBC $86
C1/E75A: C2 20        REP #$20
C1/E75C: 18           CLC 
C1/E75D: 7D DE D5     ADC $D5DE,X
C1/E760: 29 FF 00     AND #$00FF
C1/E763: 9D E1 D1     STA $D1E1,X
C1/E766: 7B           TDC 
C1/E767: E2 20        SEP #$20
C1/E769: 60           RTS 

; [ animation command $88: set animation speed]

; b1 = speed

C1/E76A: C8           INY 
C1/E76B: B7 70        LDA [$70],Y
C1/E76D: 9D DD D3     STA $D3DD,X
C1/E770: 9D DE D3     STA $D3DE,X
C1/E773: 60           RTS 

C1/E774: C8           INY 
C1/E775: B7 70        LDA [$70],Y
C1/E777: 9D DE D3     STA $D3DE,X
C1/E77A: 60           RTS 
C1/E77B: C8           INY 
C1/E77C: B7 70        LDA [$70],Y
C1/E77E: 85 80        STA $80
C1/E780: DA           PHX 
C1/E781: 20 96 FC     JSR $FC96       ; generate random number
C1/E784: 85 7E        STA $7E
C1/E786: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/E789: A5 83        LDA $83
C1/E78B: 1A           INC 
C1/E78C: FA           PLX 
C1/E78D: 9D DE D3     STA $D3DE,X
C1/E790: 60           RTS 
C1/E791: C8           INY 
C1/E792: B7 70        LDA [$70],Y
C1/E794: 4A           LSR 
C1/E795: 4A           LSR 
C1/E796: 4A           LSR 
C1/E797: 4A           LSR 
C1/E798: 29 FE        AND #$FE
C1/E79A: DA           PHX 
C1/E79B: AA           TAX 
C1/E79C: BF B3 E7 C1  LDA $C1E7B3,X
C1/E7A0: 85 80        STA $80
C1/E7A2: BF B4 E7 C1  LDA $C1E7B4,X
C1/E7A6: 85 81        STA $81
C1/E7A8: B7 70        LDA [$70],Y
C1/E7AA: 29 1F        AND #$1F
C1/E7AC: 1A           INC 
C1/E7AD: 85 82        STA $82
C1/E7AF: FA           PLX 
C1/E7B0: 6C 80 00     JMP ($0080)
C1/E7B3: C3 E7        CMP $E7,S
C1/E7B5: C9 E7        CMP #$E7
C1/E7B7: CC E7 D2     CPY $D2E7
C1/E7BA: E7 D5        SBC [$D5]
C1/E7BC: E7 D8        SBC [$D8]
C1/E7BE: E7 DE        SBC [$DE]
C1/E7C0: E7 E1        SBC [$E1]
C1/E7C2: E7 20        SBC [$20]
C1/E7C4: FB           XCE 
C1/E7C5: E7 4C        SBC [$4C]
C1/E7C7: F1 E7        SBC ($E7),Y
C1/E7C9: 4C F1 E7     JMP $E7F1
C1/E7CC: 20 E7 E7     JSR $E7E7
C1/E7CF: 4C F1 E7     JMP $E7F1
C1/E7D2: 4C FB E7     JMP $E7FB
C1/E7D5: 4C E7 E7     JMP $E7E7
C1/E7D8: 20 FB E7     JSR $E7FB
C1/E7DB: 4C 05 E8     JMP $E805
C1/E7DE: 4C 05 E8     JMP $E805
C1/E7E1: 20 E7 E7     JSR $E7E7
C1/E7E4: 4C 05 E8     JMP $E805
C1/E7E7: BD DC D1     LDA $D1DC,X
C1/E7EA: 18           CLC 
C1/E7EB: 65 82        ADC $82
C1/E7ED: 9D DC D1     STA $D1DC,X
C1/E7F0: 60           RTS 
C1/E7F1: BD DD D1     LDA $D1DD,X
C1/E7F4: 18           CLC 
C1/E7F5: 65 82        ADC $82
C1/E7F7: 9D DD D1     STA $D1DD,X
C1/E7FA: 60           RTS 
C1/E7FB: BD DC D1     LDA $D1DC,X
C1/E7FE: 38           SEC 
C1/E7FF: E5 82        SBC $82
C1/E801: 9D DC D1     STA $D1DC,X
C1/E804: 60           RTS 
C1/E805: BD DD D1     LDA $D1DD,X
C1/E808: 38           SEC 
C1/E809: E5 82        SBC $82
C1/E80B: 9D DD D1     STA $D1DD,X
C1/E80E: 60           RTS 
C1/E80F: 60           RTS 
C1/E810: 7B           TDC 
C1/E811: AA           TAX 
C1/E812: A9 AA        LDA #$AA
C1/E814: 9D 02 04     STA $0402,X
C1/E817: E8           INX 
C1/E818: E0 0E 00     CPX #$000E
C1/E81B: D0 F7        BNE $E814
C1/E81D: 60           RTS 
C1/E81E: A9 08        LDA #$08
C1/E820: 8D 3A DB     STA $DB3A
C1/E823: 9C 39 DB     STZ $DB39
C1/E826: AD BC D1     LDA $D1BC
C1/E829: 29 80        AND #$80
C1/E82B: 8D 3B DB     STA $DB3B
C1/E82E: 60           RTS 

; [  ]

C1/E82F: 20 BC B7     JSR $B7BC
C1/E832: 20 10 E8     JSR $E810
C1/E835: 20 1E E8     JSR $E81E
C1/E838: EE 10 D1     INC $D110
C1/E83B: 20 F2 02     JSR $02F2       ; wait one frame
C1/E83E: A9 01        LDA #$01
C1/E840: 8D 69 DB     STA $DB69
C1/E843: AD 75 DB     LDA $DB75
C1/E846: 8D 74 DB     STA $DB74
C1/E849: A9 01        LDA #$01
C1/E84B: 8D 38 DB     STA $DB38
C1/E84E: 20 F2 02     JSR $02F2       ; wait one frame
C1/E851: AD BC D1     LDA $D1BC
C1/E854: 29 80        AND #$80
C1/E856: F0 0F        BEQ $E867
C1/E858: 7B           TDC 
C1/E859: AA           TAX 
C1/E85A: A9 08        LDA #$08
C1/E85C: 20 09 C4     JSR $C409
C1/E85F: A5 74        LDA $74
C1/E861: C9 08        CMP #$08
C1/E863: D0 E4        BNE $E849
C1/E865: 80 1D        BRA $E884
C1/E867: 7B           TDC 
C1/E868: AA           TAX 
C1/E869: A9 04        LDA #$04
C1/E86B: 20 09 C4     JSR $C409
C1/E86E: A5 74        LDA $74
C1/E870: 48           PHA 
C1/E871: 20 F2 02     JSR $02F2       ; wait one frame
C1/E874: A2 40 00     LDX #$0040
C1/E877: A9 04        LDA #$04
C1/E879: 20 09 C4     JSR $C409
C1/E87C: 68           PLA 
C1/E87D: 18           CLC 
C1/E87E: 65 74        ADC $74
C1/E880: C9 08        CMP #$08
C1/E882: D0 C5        BNE $E849
C1/E884: 20 F2 02     JSR $02F2       ; wait one frame
C1/E887: AD 69 DB     LDA $DB69
C1/E88A: 0D 74 DB     ORA $DB74
C1/E88D: D0 F5        BNE $E884
C1/E88F: 9C 38 DB     STZ $DB38
C1/E892: 9C 10 D1     STZ $D110
C1/E895: 20 D3 67     JSR $67D3
C1/E898: 20 6D FC     JSR $FC6D
C1/E89B: 9C 3C DB     STZ $DB3C
C1/E89E: AD BC D1     LDA $D1BC
C1/E8A1: 29 3F        AND #$3F
C1/E8A3: C9 1C        CMP #$1C
C1/E8A5: F0 1A        BEQ $E8C1
C1/E8A7: C9 08        CMP #$08
C1/E8A9: F0 16        BEQ $E8C1
C1/E8AB: C9 11        CMP #$11
C1/E8AD: D0 15        BNE $E8C4
C1/E8AF: C2 20        REP #$20
C1/E8B1: A5 EB        LDA $EB
C1/E8B3: 18           CLC 
C1/E8B4: 69 15 00     ADC #$0015
C1/E8B7: 85 EB        STA $EB
C1/E8B9: 7B           TDC 
C1/E8BA: E2 20        SEP #$20
C1/E8BC: AD 53 DB     LDA $DB53
C1/E8BF: F0 10        BEQ $E8D1
C1/E8C1: 20 D8 E8     JSR $E8D8
C1/E8C4: AD BC D1     LDA $D1BC
C1/E8C7: 29 3F        AND #$3F
C1/E8C9: C9 2A        CMP #$2A
C1/E8CB: F0 08        BEQ $E8D5
C1/E8CD: C9 2B        CMP #$2B
C1/E8CF: F0 01        BEQ $E8D2
C1/E8D1: 60           RTS 
C1/E8D2: 4C CB 9D     JMP $9DCB
C1/E8D5: 4C 0A 9E     JMP $9E0A
C1/E8D8: 20 F2 02     JSR $02F2       ; wait one frame
C1/E8DB: AD 11 D1     LDA $D111
C1/E8DE: 29 1F        AND #$1F
C1/E8E0: 85 7E        STA $7E
C1/E8E2: AD 12 D1     LDA $D112
C1/E8E5: 29 1F        AND #$1F
C1/E8E7: 05 7E        ORA $7E
C1/E8E9: AD 13 D1     LDA $D113
C1/E8EC: 29 1F        AND #$1F
C1/E8EE: 05 7E        ORA $7E
C1/E8F0: F0 04        BEQ $E8F6
C1/E8F2: C9 01        CMP #$01
C1/E8F4: D0 E2        BNE $E8D8
C1/E8F6: 7B           TDC 
C1/E8F7: AA           TAX 
C1/E8F8: DA           PHX 
C1/E8F9: 7B           TDC 
C1/E8FA: 85 7E        STA $7E
C1/E8FC: 8A           TXA 
C1/E8FD: 20 02 7B     JSR $7B02
C1/E900: FA           PLX 
C1/E901: E8           INX 
C1/E902: E0 08 00     CPX #$0008
C1/E905: D0 F1        BNE $E8F8
C1/E907: 60           RTS 

; [  ]

C1/E908: 20 BC B7     JSR $B7BC
C1/E90B: 20 10 E8     JSR $E810
C1/E90E: 20 1E E8     JSR $E81E
C1/E911: EE 10 D1     INC $D110
C1/E914: 20 F2 02     JSR $02F2       ; wait one frame
C1/E917: 9C 5F DB     STZ $DB5F
C1/E91A: 9C 39 DB     STZ $DB39
C1/E91D: 9C 69 F8     STZ $F869
C1/E920: A9 01        LDA #$01
C1/E922: 8D 69 DB     STA $DB69
C1/E925: AD 75 DB     LDA $DB75
C1/E928: 8D 74 DB     STA $DB74
C1/E92B: 60           RTS 

; [  ]

C1/E92C: 20 08 E9     JSR $E908
C1/E92F: A9 02        LDA #$02
C1/E931: 8D 38 DB     STA $DB38
C1/E934: A2 00 00     LDX #$0000
C1/E937: A9 10        LDA #$10
C1/E939: 20 09 C4     JSR $C409
C1/E93C: A5 74        LDA $74
C1/E93E: 8D 69 F8     STA $F869
C1/E941: 20 F2 02     JSR $02F2       ; wait one frame
C1/E944: A2 00 01     LDX #$0100
C1/E947: A9 10        LDA #$10
C1/E949: 20 09 C4     JSR $C409
C1/E94C: AD 69 F8     LDA $F869
C1/E94F: 18           CLC 
C1/E950: 65 74        ADC $74
C1/E952: 8D 69 F8     STA $F869
C1/E955: 20 F2 02     JSR $02F2       ; wait one frame
C1/E958: AD 69 F8     LDA $F869
C1/E95B: C9 20        CMP #$20
C1/E95D: D0 D0        BNE $E92F
C1/E95F: 4C 7B E9     JMP $E97B
C1/E962: 20 08 E9     JSR $E908
C1/E965: 20 F2 02     JSR $02F2       ; wait one frame
C1/E968: A9 02        LDA #$02
C1/E96A: 8D 38 DB     STA $DB38
C1/E96D: A2 00 00     LDX #$0000
C1/E970: A9 20        LDA #$20
C1/E972: 20 09 C4     JSR $C409
C1/E975: A5 74        LDA $74
C1/E977: C9 20        CMP #$20
C1/E979: D0 EA        BNE $E965
C1/E97B: 20 F2 02     JSR $02F2       ; wait one frame
C1/E97E: AD 69 DB     LDA $DB69
C1/E981: 0D 74 DB     ORA $DB74
C1/E984: D0 F5        BNE $E97B
C1/E986: 9C 38 DB     STZ $DB38
C1/E989: 9C 10 D1     STZ $D110
C1/E98C: 9C 5D DB     STZ $DB5D
C1/E98F: 20 D3 67     JSR $67D3
C1/E992: 20 6D FC     JSR $FC6D
C1/E995: 9C 3C DB     STZ $DB3C
C1/E998: 60           RTS 

; [ show game stats (unknown cave psychic) ]

C1/E999: C2 10        REP #$10
C1/E99B: E2 20        SEP #$20
C1/E99D: 20 88 08     JSR $0888       ; init hardware registers
C1/E9A0: 20 8C F8     JSR $F88C
C1/E9A3: 20 FB EA     JSR $EAFB
C1/E9A6: A9 53        LDA #$53
C1/E9A8: 85 CE        STA $CE
C1/E9AA: 7B           TDC 
C1/E9AB: AA           TAX 
C1/E9AC: BF FA DE D0  LDA $D0DEFA,X
C1/E9B0: 9D F6 DB     STA $DBF6,X
C1/E9B3: E8           INX 
C1/E9B4: E0 00 01     CPX #$0100
C1/E9B7: D0 F3        BNE $E9AC
C1/E9B9: 7B           TDC 
C1/E9BA: AA           TAX 
C1/E9BB: BF F3 EA C1  LDA $C1EAF3,X
C1/E9BF: 9D 6D BC     STA $BC6D,X
C1/E9C2: E8           INX 
C1/E9C3: E0 08 00     CPX #$0008
C1/E9C6: D0 F3        BNE $E9BB
C1/E9C8: 7B           TDC 
C1/E9C9: AA           TAX 
C1/E9CA: 9D 09 80     STA $8009,X
C1/E9CD: E8           INX 
C1/E9CE: E0 00 08     CPX #$0800
C1/E9D1: D0 F7        BNE $E9CA
C1/E9D3: 20 D3 3E     JSR $3ED3
C1/E9D6: A2 F6 DB     LDX #$DBF6
C1/E9D9: 8E A0 BC     STX $BCA0
C1/E9DC: A2 93 80     LDX #$8093
C1/E9DF: 8E A2 BC     STX $BCA2
C1/E9E2: A9 20        LDA #$20
C1/E9E4: 8D A4 BC     STA $BCA4
C1/E9E7: 9C A5 BC     STZ $BCA5
C1/E9EA: 20 AC 2D     JSR $2DAC
C1/E9ED: 7B           TDC 
C1/E9EE: AA           TAX 
C1/E9EF: A8           TAY 
C1/E9F0: A9 20        LDA #$20
C1/E9F2: 85 70        STA $70
C1/E9F4: B9 09 80     LDA $8009,Y
C1/E9F7: 9F 00 80 7F  STA $7F8000,X
C1/E9FB: C6 70        DEC $70
C1/E9FD: D0 0F        BNE $EA0E
C1/E9FF: A9 20        LDA #$20
C1/EA01: 85 70        STA $70
C1/EA03: C2 20        REP #$20
C1/EA05: 8A           TXA 
C1/EA06: 18           CLC 
C1/EA07: 69 C0 00     ADC #$00C0
C1/EA0A: AA           TAX 
C1/EA0B: 7B           TDC 
C1/EA0C: E2 20        SEP #$20
C1/EA0E: E8           INX 
C1/EA0F: E8           INX 
C1/EA10: C8           INY 
C1/EA11: C8           INY 
C1/EA12: C0 00 08     CPY #$0800
C1/EA15: D0 DD        BNE $E9F4
C1/EA17: A2 00 80     LDX #$8000
C1/EA1A: 86 70        STX $70
C1/EA1C: A2 00 80     LDX #$8000
C1/EA1F: 7B           TDC 
C1/EA20: A8           TAY 
C1/EA21: A9 7F        LDA #$7F
C1/EA23: 20 CA FD     JSR $FDCA       ; copy data to vram
C1/EA26: 7B           TDC 
C1/EA27: A8           TAY 
C1/EA28: A9 03        LDA #$03
C1/EA2A: 20 3E AA     JSR $AA3E       ; load attack palette (16-colors)
C1/EA2D: 7B           TDC 
C1/EA2E: AA           TAX 
C1/EA2F: 8E 77 BC     STX $BC77
C1/EA32: A2 D0 FF     LDX #$FFD0
C1/EA35: 8E 79 BC     STX $BC79
C1/EA38: A2 80 00     LDX #$0080
C1/EA3B: 8E E7 F9     STX $F9E7
C1/EA3E: A9 07        LDA #$07        ; mode 7
C1/EA40: 8D 81 BC     STA $BC81
C1/EA43: A9 01        LDA #$01
C1/EA45: 8D 05 FF     STA $FF05
C1/EA48: 9C 4C DB     STZ $DB4C
C1/EA4B: 9C EB F9     STZ $F9EB
C1/EA4E: A9 FE        LDA #$FE
C1/EA50: 8D EC F9     STA $F9EC
C1/EA53: 9C 4A DB     STZ $DB4A
C1/EA56: A9 04        LDA #$04
C1/EA58: 8D 4B DB     STA $DB4B
C1/EA5B: A9 01        LDA #$01
C1/EA5D: 8D FB FE     STA $FEFB
C1/EA60: 8F 2C 21 00  STA $00212C
C1/EA64: 8F 2E 21 00  STA $00212E
C1/EA68: AF 10 42 00  LDA $004210
C1/EA6C: 10 FA        BPL $EA68
C1/EA6E: A9 81        LDA #$81
C1/EA70: 8F 00 42 00  STA $004200
C1/EA74: 58           CLI 
C1/EA75: A9 0F        LDA #$0F
C1/EA77: 8D 7F BC     STA $BC7F
C1/EA7A: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/EA7D: C2 20        REP #$20
C1/EA7F: AD E7 F9     LDA $F9E7
C1/EA82: 18           CLC 
C1/EA83: 69 20 00     ADC #$0020
C1/EA86: 8D E7 F9     STA $F9E7
C1/EA89: AA           TAX 
C1/EA8A: 7B           TDC 
C1/EA8B: E2 20        SEP #$20
C1/EA8D: E0 00 02     CPX #$0200
C1/EA90: D0 E8        BNE $EA7A
C1/EA92: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/EA95: AD 4C DB     LDA $DB4C
C1/EA98: F0 12        BEQ $EAAC
C1/EA9A: AD EB F9     LDA $F9EB
C1/EA9D: CD 4A DB     CMP $DB4A
C1/EAA0: B0 05        BCS $EAA7
C1/EAA2: 20 E8 EA     JSR $EAE8
C1/EAA5: 80 05        BRA $EAAC
C1/EAA7: CE EB F9     DEC $F9EB
C1/EAAA: 80 16        BRA $EAC2
C1/EAAC: AD EB F9     LDA $F9EB
C1/EAAF: CD 4B DB     CMP $DB4B
C1/EAB2: 90 0B        BCC $EABF
C1/EAB4: 20 E8 EA     JSR $EAE8
C1/EAB7: CE 4B DB     DEC $DB4B
C1/EABA: EE 4A DB     INC $DB4A
C1/EABD: 80 DB        BRA $EA9A
C1/EABF: EE EB F9     INC $F9EB
C1/EAC2: AD 4A DB     LDA $DB4A
C1/EAC5: C9 02        CMP #$02
C1/EAC7: D0 C9        BNE $EA92
C1/EAC9: A9 1E        LDA #$1E        ; 30 * 2 = 60 frames (1 second)
C1/EACB: 48           PHA 
C1/EACC: 20 F2 02     JSR $02F2       ; wait one frame
C1/EACF: EE EB F9     INC $F9EB
C1/EAD2: 20 F2 02     JSR $02F2       ; wait one frame
C1/EAD5: CE EB F9     DEC $F9EB
C1/EAD8: 68           PLA 
C1/EAD9: 3A           DEC 
C1/EADA: D0 EF        BNE $EACB
C1/EADC: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/EADF: A5 00        LDA $00
C1/EAE1: 05 01        ORA $01
C1/EAE3: F0 F7        BEQ $EADC       ; wait for keypress
C1/EAE5: 4C 90 F7     JMP $F790       ; fade out and return

; [  ]

C1/EAE8: 48           PHA 
C1/EAE9: AD 4C DB     LDA $DB4C
C1/EAEC: 49 01        EOR #$01
C1/EAEE: 8D 4C DB     STA $DB4C
C1/EAF1: 68           PLA 
C1/EAF2: 60           RTS 

C1/EAF3: 09 80
C1/EAF5: 03 00
C1/EAF7: 1A
C1/EAF8: 0E 00 00

C1/EAFB: 8B           PHB 
C1/EAFC: A9 D1        LDA #$D1
C1/EAFE: 48           PHA 
C1/EAFF: AB           PLB 
C1/EB00: 7B           TDC 
C1/EB01: AA           TAX 
C1/EB02: A8           TAY 
C1/EB03: A9 08        LDA #$08
C1/EB05: 85 78        STA $78
C1/EB07: C2 20        REP #$20
C1/EB09: B9 00 F0     LDA $F000,Y
C1/EB0C: 85 70        STA $70
C1/EB0E: 7B           TDC 
C1/EB0F: E2 20        SEP #$20
C1/EB11: A9 08        LDA #$08
C1/EB13: 85 76        STA $76
C1/EB15: 7B           TDC 
C1/EB16: 06 71        ASL $71
C1/EB18: 2A           ROL 
C1/EB19: 06 70        ASL $70
C1/EB1B: 2A           ROL 
C1/EB1C: 9F 01 80 7F  STA $7F8001,X
C1/EB20: 7B           TDC 
C1/EB21: 9F 00 80 7F  STA $7F8000,X
C1/EB25: E8           INX 
C1/EB26: E8           INX 
C1/EB27: C6 76        DEC $76
C1/EB29: D0 EA        BNE $EB15
C1/EB2B: C8           INY 
C1/EB2C: C8           INY 
C1/EB2D: C6 78        DEC $78
C1/EB2F: D0 D6        BNE $EB07
C1/EB31: C0 00 10     CPY #$1000
C1/EB34: D0 CD        BNE $EB03
C1/EB36: AB           PLB 
C1/EB37: 60           RTS 

; [  ]

C1/EB38: DA           PHX 
C1/EB39: A2 00 20     LDX #$2000
C1/EB3C: 86 70        STX $70
C1/EB3E: FA           PLX 
C1/EB3F: A9 7F        LDA #$7F
C1/EB41: 5A           PHY 
C1/EB42: 20 01 ED     JSR $ED01
C1/EB45: 7A           PLY 
C1/EB46: C2 20        REP #$20
C1/EB48: 98           TYA 
C1/EB49: 18           CLC 
C1/EB4A: 69 00 10     ADC #$1000
C1/EB4D: A8           TAY 
C1/EB4E: 7B           TDC 
C1/EB4F: E2 20        SEP #$20
C1/EB51: 60           RTS 

; [  ]

C1/EB52: 7B           TDC 
C1/EB53: A8           TAY 
C1/EB54: AA           TAX 
C1/EB55: 20 38 EB     JSR $EB38
C1/EB58: A2 00 20     LDX #$2000
C1/EB5B: 20 38 EB     JSR $EB38
C1/EB5E: A2 00 20     LDX #$2000
C1/EB61: 20 38 EB     JSR $EB38
C1/EB64: A2 00 20     LDX #$2000
C1/EB67: 20 38 EB     JSR $EB38
C1/EB6A: 7B           TDC 
C1/EB6B: AA           TAX 
C1/EB6C: BD 76 ED     LDA $ED76,X
C1/EB6F: 9D 29 7E     STA $7E29,X
C1/EB72: BD 96 ED     LDA $ED96,X
C1/EB75: 9D 09 7E     STA $7E09,X
C1/EB78: BD B6 ED     LDA $EDB6,X
C1/EB7B: 9D 49 7E     STA $7E49,X
C1/EB7E: BD D6 ED     LDA $EDD6,X
C1/EB81: 9D 69 7E     STA $7E69,X
C1/EB84: E8           INX 
C1/EB85: E0 20 00     CPX #$0020
C1/EB88: D0 E2        BNE $EB6C
C1/EB8A: A2 40 00     LDX #$0040
C1/EB8D: 8E 8E BC     STX $BC8E
C1/EB90: 8E 94 BC     STX $BC94
C1/EB93: 7B           TDC 
C1/EB94: AA           TAX 
C1/EB95: 8E 90 BC     STX $BC90
C1/EB98: 8E 92 BC     STX $BC92
C1/EB9B: E8           INX 
C1/EB9C: 8E 77 BC     STX $BC77
C1/EB9F: 8E 79 BC     STX $BC79
C1/EBA2: A2 81 00     LDX #$0081
C1/EBA5: 8E 96 BC     STX $BC96
C1/EBA8: A2 EB FF     LDX #$FFEB
C1/EBAB: 8E 98 BC     STX $BC98
C1/EBAE: A9 11        LDA #$11
C1/EBB0: 8D FB FE     STA $FEFB
C1/EBB3: A9 07        LDA #$07        ; mode 7
C1/EBB5: 8D 81 BC     STA $BC81
C1/EBB8: A9 04        LDA #$04
C1/EBBA: 8D F5 DB     STA $DBF5
C1/EBBD: EE 8D BC     INC $BC8D
C1/EBC0: 7B           TDC 
C1/EBC1: AA           TAX 
C1/EBC2: A9 F0        LDA #$F0
C1/EBC4: 9D 00 02     STA $0200,X
C1/EBC7: E8           INX 
C1/EBC8: E0 00 01     CPX #$0100
C1/EBCB: D0 F7        BNE $EBC4
C1/EBCD: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/EBD0: 20 F6 F5     JSR $F5F6
C1/EBD3: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/EBD6: 20 F6 F5     JSR $F5F6
C1/EBD9: AE 8E BC     LDX $BC8E
C1/EBDC: E8           INX 
C1/EBDD: 8E 8E BC     STX $BC8E
C1/EBE0: 8E 94 BC     STX $BC94
C1/EBE3: E0 80 00     CPX #$0080
C1/EBE6: D0 E5        BNE $EBCD
C1/EBE8: 60           RTS 
C1/EBE9: 7B           TDC 
C1/EBEA: AA           TAX 
C1/EBEB: A8           TAY 
C1/EBEC: BD 00 20     LDA $2000,X
C1/EBEF: 29 07        AND #$07
C1/EBF1: 99 C6 CF     STA $CFC6,Y
C1/EBF4: BD 01 20     LDA $2001,X
C1/EBF7: 99 CA CF     STA $CFCA,Y
C1/EBFA: C8           INY 
C1/EBFB: C2 20        REP #$20
C1/EBFD: 8A           TXA 
C1/EBFE: 18           CLC 
C1/EBFF: 69 80 00     ADC #$0080
C1/EC02: AA           TAX 
C1/EC03: 7B           TDC 
C1/EC04: E2 20        SEP #$20
C1/EC06: E0 00 02     CPX #$0200
C1/EC09: D0 E1        BNE $EBEC
C1/EC0B: 20 E2 24     JSR $24E2       ; load character graphics
C1/EC0E: EE 2B FF     INC $FF2B
C1/EC11: 20 07 26     JSR $2607       ; load character palettes
C1/EC14: 7B           TDC 
C1/EC15: AA           TAX 
C1/EC16: BD 09 7F     LDA $7F09,X
C1/EC19: 9D 76 ED     STA $ED76,X
C1/EC1C: E8           INX 
C1/EC1D: E0 80 00     CPX #$0080
C1/EC20: D0 F4        BNE $EC16
C1/EC22: 7B           TDC 
C1/EC23: AA           TAX 
C1/EC24: 8E 76 ED     STX $ED76
C1/EC27: 8E 96 ED     STX $ED96
C1/EC2A: 8E B6 ED     STX $EDB6
C1/EC2D: 8E D6 ED     STX $EDD6
C1/EC30: BF 00 D0 7F  LDA $7FD000,X
C1/EC34: 9F C0 D8 7F  STA $7FD8C0,X
C1/EC38: BF 00 E0 7F  LDA $7FE000,X
C1/EC3C: 9F 80 D9 7F  STA $7FD980,X
C1/EC40: BF 00 E8 7F  LDA $7FE800,X
C1/EC44: 9F 40 DA 7F  STA $7FDA40,X
C1/EC48: E8           INX 
C1/EC49: E0 C0 00     CPX #$00C0
C1/EC4C: D0 E2        BNE $EC30
C1/EC4E: A2 00 03     LDX #$0300
C1/EC51: 86 7E        STX $7E
C1/EC53: 20 BF 95     JSR $95BF
C1/EC56: 7B           TDC 
C1/EC57: AA           TAX 
C1/EC58: BF 00 E0 7F  LDA $7FE000,X
C1/EC5C: 9F 00 00 7F  STA $7F0000,X
C1/EC60: 7B           TDC 
C1/EC61: 9F 00 20 7F  STA $7F2000,X
C1/EC65: E8           INX 
C1/EC66: E0 00 20     CPX #$2000
C1/EC69: D0 ED        BNE $EC58
C1/EC6B: 7B           TDC 
C1/EC6C: AA           TAX 
C1/EC6D: 64 70        STZ $70
C1/EC6F: A0 80 01     LDY #$0180
C1/EC72: BF 81 00 7F  LDA $7F0081,X
C1/EC76: 05 70        ORA $70
C1/EC78: 9F 81 00 7F  STA $7F0081,X
C1/EC7C: 88           DEY 
C1/EC7D: D0 0A        BNE $EC89
C1/EC7F: A0 80 01     LDY #$0180
C1/EC82: A5 70        LDA $70
C1/EC84: 18           CLC 
C1/EC85: 69 10        ADC #$10
C1/EC87: 85 70        STA $70
C1/EC89: E8           INX 
C1/EC8A: E8           INX 
C1/EC8B: E0 00 0C     CPX #$0C00
C1/EC8E: D0 E2        BNE $EC72
C1/EC90: A9 0F        LDA #$0F
C1/EC92: 85 70        STA $70
C1/EC94: 64 73        STZ $73
C1/EC96: 7B           TDC 
C1/EC97: 20 C1 EC     JSR $ECC1
C1/EC9A: A9 0F        LDA #$0F
C1/EC9C: 85 70        STA $70
C1/EC9E: A9 08        LDA #$08
C1/ECA0: 85 73        STA $73
C1/ECA2: A9 01        LDA #$01
C1/ECA4: 20 C1 EC     JSR $ECC1
C1/ECA7: A9 0A        LDA #$0A
C1/ECA9: 85 70        STA $70
C1/ECAB: A9 04        LDA #$04
C1/ECAD: 85 73        STA $73
C1/ECAF: A9 02        LDA #$02
C1/ECB1: 20 C1 EC     JSR $ECC1
C1/ECB4: A9 14        LDA #$14
C1/ECB6: 85 70        STA $70
C1/ECB8: A9 04        LDA #$04
C1/ECBA: 85 73        STA $73
C1/ECBC: A9 03        LDA #$03
C1/ECBE: 4C C1 EC     JMP $ECC1
C1/ECC1: AA           TAX 
C1/ECC2: BF FD EC C1  LDA $C1ECFD,X
C1/ECC6: 85 74        STA $74
C1/ECC8: A5 70        LDA $70
C1/ECCA: 64 71        STZ $71
C1/ECCC: 64 72        STZ $72
C1/ECCE: A5 72        LDA $72
C1/ECD0: C2 20        REP #$20
C1/ECD2: 06 70        ASL $70
C1/ECD4: A5 70        LDA $70
C1/ECD6: 18           CLC 
C1/ECD7: 65 72        ADC $72
C1/ECD9: AA           TAX 
C1/ECDA: 7B           TDC 
C1/ECDB: E2 20        SEP #$20
C1/ECDD: A5 74        LDA $74
C1/ECDF: 9F 00 00 7F  STA $7F0000,X
C1/ECE3: 1A           INC 
C1/ECE4: 9F 02 00 7F  STA $7F0002,X
C1/ECE8: 1A           INC 
C1/ECE9: 9F 00 01 7F  STA $7F0100,X
C1/ECED: 1A           INC 
C1/ECEE: 9F 02 01 7F  STA $7F0102,X
C1/ECF2: 1A           INC 
C1/ECF3: 9F 00 02 7F  STA $7F0200,X
C1/ECF7: 1A           INC 
C1/ECF8: 9F 02 02 7F  STA $7F0202,X
C1/ECFC: 60           RTS 
C1/ECFD: 01 07        ORA ($07,X)
C1/ECFF: 0D 13 DA     ORA $DA13
C1/ED02: 5A           PHY 
C1/ED03: 48           PHA 
C1/ED04: A6 70        LDX $70
C1/ED06: DA           PHX 
C1/ED07: AD D6 D0     LDA $D0D6
C1/ED0A: F0 08        BEQ $ED14
C1/ED0C: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/ED0F: 20 F6 F5     JSR $F5F6
C1/ED12: 80 F3        BRA $ED07
C1/ED14: FA           PLX 
C1/ED15: 8E DE D0     STX $D0DE
C1/ED18: 68           PLA 
C1/ED19: 8D D9 D0     STA $D0D9
C1/ED1C: 7A           PLY 
C1/ED1D: 8C DA D0     STY $D0DA
C1/ED20: FA           PLX 
C1/ED21: 8E D7 D0     STX $D0D7
C1/ED24: 9C E0 D0     STZ $D0E0
C1/ED27: C2 20        REP #$20
C1/ED29: AD DE D0     LDA $D0DE
C1/ED2C: C9 00 08     CMP #$0800
C1/ED2F: F0 0A        BEQ $ED3B
C1/ED31: 90 08        BCC $ED3B
C1/ED33: A9 00 08     LDA #$0800
C1/ED36: 8D DC D0     STA $D0DC
C1/ED39: 80 06        BRA $ED41
C1/ED3B: 8D DC D0     STA $D0DC
C1/ED3E: EE E0 D0     INC $D0E0
C1/ED41: 7B           TDC 
C1/ED42: E2 20        SEP #$20
C1/ED44: EE D6 D0     INC $D0D6
C1/ED47: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/ED4A: 20 F6 F5     JSR $F5F6
C1/ED4D: C2 20        REP #$20
C1/ED4F: AD D7 D0     LDA $D0D7
C1/ED52: 18           CLC 
C1/ED53: 69 00 08     ADC #$0800
C1/ED56: 8D D7 D0     STA $D0D7
C1/ED59: AD DA D0     LDA $D0DA
C1/ED5C: 18           CLC 
C1/ED5D: 69 00 04     ADC #$0400
C1/ED60: 8D DA D0     STA $D0DA
C1/ED63: AD DE D0     LDA $D0DE
C1/ED66: 38           SEC 
C1/ED67: E9 00 08     SBC #$0800
C1/ED6A: 8D DE D0     STA $D0DE
C1/ED6D: 7B           TDC 
C1/ED6E: E2 20        SEP #$20
C1/ED70: AD E0 D0     LDA $D0E0
C1/ED73: F0 B2        BEQ $ED27
C1/ED75: 60           RTS 

; [  ]

C1/ED76: A9 D0        LDA #$D0        ; ??? (D0/E4CB)
C1/ED78: 85 74        STA $74
C1/ED7A: A2 CB E4     LDX #$E4CB
C1/ED7D: 86 72        STX $72
C1/ED7F: 20 77 FB     JSR $FB77       ; decompress
C1/ED82: 8B           PHB 
C1/ED83: A9 7F        LDA #$7F
C1/ED85: 48           PHA 
C1/ED86: AB           PLB 
C1/ED87: 7B           TDC 
C1/ED88: AA           TAX 
C1/ED89: A8           TAY 
C1/ED8A: A9 08        LDA #$08
C1/ED8C: 85 78        STA $78
C1/ED8E: C2 20        REP #$20
C1/ED90: B9 00 C0     LDA $C000,Y
C1/ED93: 85 70        STA $70
C1/ED95: B9 10 C0     LDA $C010,Y
C1/ED98: 85 72        STA $72
C1/ED9A: 7B           TDC 
C1/ED9B: E2 20        SEP #$20
C1/ED9D: A9 08        LDA #$08
C1/ED9F: 85 76        STA $76
C1/EDA1: 7B           TDC 
C1/EDA2: 06 73        ASL $73
C1/EDA4: 2A           ROL 
C1/EDA5: 06 72        ASL $72
C1/EDA7: 2A           ROL 
C1/EDA8: 06 71        ASL $71
C1/EDAA: 2A           ROL 
C1/EDAB: 06 70        ASL $70
C1/EDAD: 2A           ROL 
C1/EDAE: 9D 81 D0     STA $D081,X
C1/EDB1: 9E 80 D0     STZ $D080,X
C1/EDB4: E8           INX 
C1/EDB5: E8           INX 
C1/EDB6: C6 76        DEC $76
C1/EDB8: D0 E7        BNE $EDA1
C1/EDBA: C8           INY 
C1/EDBB: C8           INY 
C1/EDBC: C6 78        DEC $78
C1/EDBE: D0 CE        BNE $ED8E
C1/EDC0: C2 20        REP #$20
C1/EDC2: 98           TYA 
C1/EDC3: 18           CLC 
C1/EDC4: 69 10 00     ADC #$0010
C1/EDC7: A8           TAY 
C1/EDC8: 7B           TDC 
C1/EDC9: E2 20        SEP #$20
C1/EDCB: C0 00 08     CPY #$0800
C1/EDCE: D0 BA        BNE $ED8A
C1/EDD0: 7B           TDC 
C1/EDD1: AA           TAX 
C1/EDD2: 9D 00 D0     STA $D000,X
C1/EDD5: E8           INX 
C1/EDD6: E0 80 00     CPX #$0080
C1/EDD9: D0 F7        BNE $EDD2
C1/EDDB: A2 10 DC     LDX #$DC10
C1/EDDE: 86 70        STX $70
C1/EDE0: 64 72        STZ $72
C1/EDE2: 7B           TDC 
C1/EDE3: A8           TAY 
C1/EDE4: E6 72        INC $72
C1/EDE6: A5 72        LDA $72
C1/EDE8: 91 70        STA ($70),Y
C1/EDEA: C8           INY 
C1/EDEB: C8           INY 
C1/EDEC: C0 20 00     CPY #$0020
C1/EDEF: D0 F3        BNE $EDE4
C1/EDF1: C2 20        REP #$20
C1/EDF3: A5 70        LDA $70
C1/EDF5: 18           CLC 
C1/EDF6: 69 00 01     ADC #$0100
C1/EDF9: 85 70        STA $70
C1/EDFB: 7B           TDC 
C1/EDFC: E2 20        SEP #$20
C1/EDFE: A5 72        LDA $72
C1/EE00: C9 40        CMP #$40
C1/EE02: D0 DE        BNE $EDE2
C1/EE04: AB           PLB 
C1/EE05: 60           RTS 

; [  ]

C1/EE06: A2 E0 00     LDX #$00E0
C1/EE09: BD 54 B4     LDA $B454,X
C1/EE0C: 9D 55 B4     STA $B455,X
C1/EE0F: CA           DEX 
C1/EE10: E0 70 00     CPX #$0070
C1/EE13: D0 F4        BNE $EE09
C1/EE15: 7B           TDC 
C1/EE16: AA           TAX 
C1/EE17: BD 56 B4     LDA $B456,X
C1/EE1A: 9D 55 B4     STA $B455,X
C1/EE1D: E8           INX 
C1/EE1E: E0 70 00     CPX #$0070
C1/EE21: D0 F4        BNE $EE17
C1/EE23: 60           RTS 

; [  ]

C1/EE24: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/EE27: 4C F6 F5     JMP $F5F6

; [  ]

C1/EE2A: A2 00 02     LDX #$0200
C1/EE2D: 86 70        STX $70
C1/EE2F: A2 20 E2     LDX #$E220
C1/EE32: A0 00 70     LDY #$7000
C1/EE35: A9 D0        LDA #$D0
C1/EE37: 20 27 FD     JSR $FD27
C1/EE3A: 20 BA F3     JSR $F3BA
C1/EE3D: 20 6D FC     JSR $FC6D
C1/EE40: 20 E9 EB     JSR $EBE9
C1/EE43: 20 76 ED     JSR $ED76
C1/EE46: 7B           TDC 
C1/EE47: AA           TAX 
C1/EE48: BD A9 7F     LDA $7FA9,X
C1/EE4B: 9D 09 7F     STA $7F09,X
C1/EE4E: E8           INX 
C1/EE4F: E0 20 00     CPX #$0020
C1/EE52: D0 F4        BNE $EE48
C1/EE54: 7B           TDC 
C1/EE55: AA           TAX 
C1/EE56: BD 03 02     LDA $0203,X
C1/EE59: 29 F1        AND #$F1
C1/EE5B: 9D 03 02     STA $0203,X
C1/EE5E: E8           INX 
C1/EE5F: E8           INX 
C1/EE60: E8           INX 
C1/EE61: E8           INX 
C1/EE62: E0 00 01     CPX #$0100
C1/EE65: D0 EF        BNE $EE56
C1/EE67: 7B           TDC 
C1/EE68: AA           TAX 
C1/EE69: 9D 10 04     STA $0410,X
C1/EE6C: E8           INX 
C1/EE6D: E0 10 00     CPX #$0010
C1/EE70: D0 F7        BNE $EE69
C1/EE72: A2 00 01     LDX #$0100
C1/EE75: DA           PHX 
C1/EE76: 20 24 EE     JSR $EE24
C1/EE79: 20 50 EF     JSR $EF50
C1/EE7C: FA           PLX 
C1/EE7D: CA           DEX 
C1/EE7E: D0 F5        BNE $EE75
C1/EE80: A9 10        LDA #$10
C1/EE82: 8D FB FE     STA $FEFB
C1/EE85: A2 70 00     LDX #$0070
C1/EE88: DA           PHX 
C1/EE89: 20 24 EE     JSR $EE24
C1/EE8C: 20 06 EE     JSR $EE06
C1/EE8F: FA           PLX 
C1/EE90: CA           DEX 
C1/EE91: D0 F5        BNE $EE88
C1/EE93: 9C 84 BC     STZ $BC84
C1/EE96: 20 52 EB     JSR $EB52
C1/EE99: A9 78        LDA #$78
C1/EE9B: 20 26 EF     JSR $EF26
C1/EE9E: A2 00 01     LDX #$0100
C1/EEA1: DA           PHX 
C1/EEA2: 20 24 EE     JSR $EE24
C1/EEA5: 20 30 EF     JSR $EF30
C1/EEA8: FA           PLX 
C1/EEA9: CA           DEX 
C1/EEAA: D0 F5        BNE $EEA1
C1/EEAC: A9 10        LDA #$10
C1/EEAE: 8D FB FE     STA $FEFB
C1/EEB1: 7B           TDC 
C1/EEB2: AA           TAX 
C1/EEB3: BF 8B E4 D0  LDA $D0E48B,X
C1/EEB7: 9D 09 7E     STA $7E09,X
C1/EEBA: BF AB E4 D0  LDA $D0E4AB,X
C1/EEBE: 9D 89 7F     STA $7F89,X
C1/EEC1: E8           INX 
C1/EEC2: E0 20 00     CPX #$0020
C1/EEC5: D0 EC        BNE $EEB3
C1/EEC7: A2 80 20     LDX #$2080
C1/EECA: 86 70        STX $70
C1/EECC: A2 00 D0     LDX #$D000
C1/EECF: 7B           TDC 
C1/EED0: A8           TAY 
C1/EED1: A9 7F        LDA #$7F
C1/EED3: 20 01 ED     JSR $ED01
C1/EED6: A2 00 08     LDX #$0800
C1/EED9: 86 70        STX $70
C1/EEDB: A2 00 C8     LDX #$C800
C1/EEDE: A0 00 60     LDY #$6000
C1/EEE1: A9 7F        LDA #$7F
C1/EEE3: 20 01 ED     JSR $ED01
C1/EEE6: A2 80 1F     LDX #$1F80
C1/EEE9: 86 70        STX $70
C1/EEEB: A2 00 20     LDX #$2000
C1/EEEE: A0 40 10     LDY #$1040
C1/EEF1: A9 7F        LDA #$7F
C1/EEF3: 20 01 ED     JSR $ED01
C1/EEF6: 20 4D F5     JSR $F54D
C1/EEF9: 20 DA F4     JSR $F4DA
C1/EEFC: A2 00 00     LDX #$0000
C1/EEFF: 8E 77 BC     STX $BC77
C1/EF02: 8E 79 BC     STX $BC79
C1/EF05: A2 80 00     LDX #$0080
C1/EF08: 8E 96 BC     STX $BC96
C1/EF0B: A2 70 00     LDX #$0070
C1/EF0E: 8E 98 BC     STX $BC98
C1/EF11: 20 B4 F0     JSR $F0B4
C1/EF14: A9 FF        LDA #$FF
C1/EF16: 8D F5 DB     STA $DBF5
C1/EF19: A9 07        LDA #$07        ; mode 7
C1/EF1B: 8D 81 BC     STA $BC81
C1/EF1E: A9 11        LDA #$11
C1/EF20: 8D FB FE     STA $FEFB
C1/EF23: 4C 13 F4     JMP $F413

; [  ]

C1/EF26: AA           TAX 
C1/EF27: DA           PHX 
C1/EF28: 20 24 EE     JSR $EE24
C1/EF2B: FA           PLX 
C1/EF2C: CA           DEX 
C1/EF2D: D0 F8        BNE $EF27
C1/EF2F: 60           RTS 

; [  ]

C1/EF30: A5 A2        LDA $A2
C1/EF32: 29 07        AND #$07
C1/EF34: D0 19        BNE $EF4F
C1/EF36: 7B           TDC 
C1/EF37: AA           TAX 
C1/EF38: C2 20        REP #$20
C1/EF3A: BD 09 7E     LDA $7E09,X
C1/EF3D: 20 70 EF     JSR $EF70
C1/EF40: A5 70        LDA $70
C1/EF42: 9D 09 7E     STA $7E09,X
C1/EF45: E8           INX 
C1/EF46: E8           INX 
C1/EF47: E0 80 00     CPX #$0080
C1/EF4A: D0 EE        BNE $EF3A
C1/EF4C: 7B           TDC 
C1/EF4D: E2 20        SEP #$20
C1/EF4F: 60           RTS 

; [  ]

C1/EF50: A5 A2        LDA $A2
C1/EF52: 29 07        AND #$07
C1/EF54: D0 19        BNE $EF6F
C1/EF56: 7B           TDC 
C1/EF57: AA           TAX 
C1/EF58: C2 20        REP #$20
C1/EF5A: BD 29 7E     LDA $7E29,X
C1/EF5D: 20 70 EF     JSR $EF70
C1/EF60: A5 70        LDA $70
C1/EF62: 9D 29 7E     STA $7E29,X
C1/EF65: E8           INX 
C1/EF66: E8           INX 
C1/EF67: E0 40 00     CPX #$0040
C1/EF6A: D0 EE        BNE $EF5A
C1/EF6C: 7B           TDC 
C1/EF6D: E2 20        SEP #$20
C1/EF6F: 60           RTS 

; [  ]

C1/EF70: 85 70        STA $70
C1/EF72: 29 1F 00     AND #$001F
C1/EF75: F0 08        BEQ $EF7F
C1/EF77: A5 70        LDA $70
C1/EF79: 38           SEC 
C1/EF7A: E9 01 00     SBC #$0001
C1/EF7D: 85 70        STA $70
C1/EF7F: A5 70        LDA $70
C1/EF81: 29 E0 03     AND #$03E0
C1/EF84: F0 08        BEQ $EF8E
C1/EF86: A5 70        LDA $70
C1/EF88: 38           SEC 
C1/EF89: E9 20 00     SBC #$0020
C1/EF8C: 85 70        STA $70
C1/EF8E: A5 70        LDA $70
C1/EF90: 29 00 7C     AND #$7C00
C1/EF93: F0 08        BEQ $EF9D
C1/EF95: A5 70        LDA $70
C1/EF97: 38           SEC 
C1/EF98: E9 00 04     SBC #$0400
C1/EF9B: 85 70        STA $70
C1/EF9D: 60           RTS 

C1/EF9E: E2 10        SEP #$10
C1/EFA0: 7B           TDC 
C1/EFA1: AA           TAX 
C1/EFA2: BD 09 A2     LDA $A209,X
C1/EFA5: F0 06        BEQ $EFAD
C1/EFA7: DE 09 A2     DEC $A209,X
C1/EFAA: 4C 15 F0     JMP $F015
C1/EFAD: BD 09 98     LDA $9809,X
C1/EFB0: D0 2C        BNE $EFDE
C1/EFB2: A4 E6        LDY $E6
C1/EFB4: E6 E6        INC $E6
C1/EFB6: B9 89 A2     LDA $A289,Y
C1/EFB9: 9D 89 98     STA $9889,X
C1/EFBC: 69 40        ADC #$40
C1/EFBE: 9D 09 99     STA $9909,X
C1/EFC1: B9 8A A2     LDA $A28A,Y
C1/EFC4: 29 3F        AND #$3F
C1/EFC6: 69 08        ADC #$08
C1/EFC8: 9D 89 99     STA $9989,X
C1/EFCB: B9 8B A2     LDA $A28B,Y
C1/EFCE: 29 3F        AND #$3F
C1/EFD0: 9D 09 9C     STA $9C09,X
C1/EFD3: 9E 89 9A     STZ $9A89,X
C1/EFD6: A9 03        LDA #$03
C1/EFD8: 9D 09 98     STA $9809,X
C1/EFDB: 9D 89 9B     STA $9B89,X
C1/EFDE: BD 89 9C     LDA $9C89,X
C1/EFE1: 18           CLC 
C1/EFE2: 7D 09 9C     ADC $9C09,X
C1/EFE5: 9D 89 9C     STA $9C89,X
C1/EFE8: 90 04        BCC $EFEE
C1/EFEA: FE 89 9B     INC $9B89,X
C1/EFED: 18           CLC 
C1/EFEE: BD 89 9A     LDA $9A89,X
C1/EFF1: 7D 89 9B     ADC $9B89,X
C1/EFF4: 9D 89 9A     STA $9A89,X
C1/EFF7: BD 89 99     LDA $9989,X
C1/EFFA: 18           CLC 
C1/EFFB: 7D 89 9B     ADC $9B89,X
C1/EFFE: 9D 89 99     STA $9989,X
C1/F001: 90 03        BCC $F006
C1/F003: 9E 09 98     STZ $9809,X
C1/F006: BD 89 9A     LDA $9A89,X
C1/F009: 4A           LSR 
C1/F00A: 4A           LSR 
C1/F00B: 4A           LSR 
C1/F00C: 4A           LSR 
C1/F00D: 4A           LSR 
C1/F00E: A8           TAY 
C1/F00F: B9 89 A3     LDA $A389,Y
C1/F012: 9D 09 A1     STA $A109,X
C1/F015: E8           INX 
C1/F016: E0 40        CPX #$40
C1/F018: D0 88        BNE $EFA2
C1/F01A: C2 10        REP #$10
C1/F01C: 60           RTS 

; [  ]

C1/F01D: 7B           TDC 
C1/F01E: AA           TAX 
C1/F01F: A8           TAY 
C1/F020: E2 10        SEP #$10
C1/F022: B9 09 98     LDA $9809,Y
C1/F025: D0 0A        BNE $F031
C1/F027: A9 F0        LDA #$F0
C1/F029: 9D 00 03     STA $0300,X
C1/F02C: 9D 01 03     STA $0301,X
C1/F02F: 80 76        BRA $F0A7
C1/F031: 86 74        STX $74
C1/F033: B9 89 99     LDA $9989,Y
C1/F036: 8F 02 42 00  STA $004202
C1/F03A: BE 89 98     LDX $9889,Y
C1/F03D: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/F041: 30 0F        BMI $F052
C1/F043: 8F 03 42 00  STA $004203
C1/F047: EA           NOP 
C1/F048: EA           NOP 
C1/F049: EA           NOP 
C1/F04A: EA           NOP 
C1/F04B: AF 17 42 00  LDA $004217
C1/F04F: 4C 62 F0     JMP $F062
C1/F052: 49 FF        EOR #$FF
C1/F054: 8F 03 42 00  STA $004203
C1/F058: EA           NOP 
C1/F059: EA           NOP 
C1/F05A: EA           NOP 
C1/F05B: EA           NOP 
C1/F05C: AF 17 42 00  LDA $004217
C1/F060: 49 FF        EOR #$FF
C1/F062: 85 70        STA $70
C1/F064: BE 09 99     LDX $9909,Y
C1/F067: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/F06B: 30 0F        BMI $F07C
C1/F06D: 8F 03 42 00  STA $004203
C1/F071: EA           NOP 
C1/F072: EA           NOP 
C1/F073: EA           NOP 
C1/F074: EA           NOP 
C1/F075: AF 17 42 00  LDA $004217
C1/F079: 4C 8C F0     JMP $F08C
C1/F07C: 49 FF        EOR #$FF
C1/F07E: 8F 03 42 00  STA $004203
C1/F082: EA           NOP 
C1/F083: EA           NOP 
C1/F084: EA           NOP 
C1/F085: EA           NOP 
C1/F086: AF 17 42 00  LDA $004217
C1/F08A: 49 FF        EOR #$FF
C1/F08C: A6 74        LDX $74
C1/F08E: 79 09 9E     ADC $9E09,Y
C1/F091: 9D 01 03     STA $0301,X
C1/F094: A5 70        LDA $70
C1/F096: 79 09 9D     ADC $9D09,Y
C1/F099: 9D 00 03     STA $0300,X
C1/F09C: B9 09 A1     LDA $A109,Y
C1/F09F: 9D 02 03     STA $0302,X
C1/F0A2: A9 2D        LDA #$2D
C1/F0A4: 9D 03 03     STA $0303,X
C1/F0A7: C8           INY 
C1/F0A8: E8           INX 
C1/F0A9: E8           INX 
C1/F0AA: E8           INX 
C1/F0AB: E8           INX 
C1/F0AC: F0 03        BEQ $F0B1
C1/F0AE: 4C 22 F0     JMP $F022
C1/F0B1: C2 10        REP #$10
C1/F0B3: 60           RTS 
C1/F0B4: C2 20        REP #$20
C1/F0B6: AF CD DD D0  LDA $D0DDCD
C1/F0BA: 8D E3 F9     STA $F9E3
C1/F0BD: AF CF DD D0  LDA $D0DDCF
C1/F0C1: 8D E5 F9     STA $F9E5
C1/F0C4: AF D1 DD D0  LDA $D0DDD1
C1/F0C8: 8D E7 F9     STA $F9E7
C1/F0CB: AF D3 DD D0  LDA $D0DDD3
C1/F0CF: 8D E9 F9     STA $F9E9
C1/F0D2: AF D5 DD D0  LDA $D0DDD5
C1/F0D6: 8D 77 BC     STA $BC77
C1/F0D9: AF D7 DD D0  LDA $D0DDD7
C1/F0DD: 8D 79 BC     STA $BC79
C1/F0E0: 7B           TDC 
C1/F0E1: E2 20        SEP #$20
C1/F0E3: AF D9 DD D0  LDA $D0DDD9
C1/F0E7: 8D EB F9     STA $F9EB
C1/F0EA: 20 FF F0     JSR $F0FF
C1/F0ED: 7B           TDC 
C1/F0EE: AA           TAX 
C1/F0EF: 8E 06 FF     STX $FF06
C1/F0F2: 8D 28 FF     STA $FF28
C1/F0F5: 9D 08 FF     STA $FF08,X
C1/F0F8: E8           INX 
C1/F0F9: E0 20 00     CPX #$0020
C1/F0FC: D0 F7        BNE $F0F5
C1/F0FE: 60           RTS 

; [  ]

C1/F0FF: 7B           TDC 
C1/F100: AA           TAX 
C1/F101: 86 18        STX $18
C1/F103: 86 1A        STX $1A
C1/F105: 86 1E        STX $1E
C1/F107: 86 20        STX $20
C1/F109: AD EB F9     LDA $F9EB
C1/F10C: 18           CLC 
C1/F10D: 69 40        ADC #$40
C1/F10F: AA           TAX 
C1/F110: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/F114: 10 09        BPL $F11F
C1/F116: A2 FF FF     LDX #$FFFF
C1/F119: 86 18        STX $18
C1/F11B: E6 1E        INC $1E
C1/F11D: 49 FF        EOR #$FF
C1/F11F: 0A           ASL 
C1/F120: 85 7A        STA $7A
C1/F122: AD EB F9     LDA $F9EB
C1/F125: AA           TAX 
C1/F126: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/F12A: 10 09        BPL $F135
C1/F12C: A2 FF FF     LDX #$FFFF
C1/F12F: 86 1A        STX $1A
C1/F131: E6 20        INC $20
C1/F133: 49 FF        EOR #$FF
C1/F135: 0A           ASL 
C1/F136: 85 7C        STA $7C
C1/F138: C2 20        REP #$20
C1/F13A: AD E7 F9     LDA $F9E7
C1/F13D: CD E9 F9     CMP $F9E9
C1/F140: 90 03        BCC $F145
C1/F142: 4C EA F1     JMP $F1EA
C1/F145: AD E7 F9     LDA $F9E7
C1/F148: 85 70        STA $70
C1/F14A: AD E9 F9     LDA $F9E9
C1/F14D: 38           SEC 
C1/F14E: ED E7 F9     SBC $F9E7
C1/F151: 8F 04 42 00  STA $004204
C1/F155: 7B           TDC 
C1/F156: E2 20        SEP #$20
C1/F158: A9 70        LDA #$70
C1/F15A: 8F 06 42 00  STA $004206
C1/F15E: 8B           PHB 
C1/F15F: A9 00        LDA #$00
C1/F161: A8           TAY 
C1/F162: 48           PHA 
C1/F163: AB           PLB 
C1/F164: C2 20        REP #$20
C1/F166: E2 10        SEP #$10
C1/F168: AF E3 F9 7E  LDA $7EF9E3
C1/F16C: 8D 04 42     STA $4204
C1/F16F: AD 14 42     LDA $4214
C1/F172: 85 76        STA $76
C1/F174: 84 1C        STY $1C
C1/F176: E2 20        SEP #$20
C1/F178: A5 71        LDA $71
C1/F17A: 0A           ASL 
C1/F17B: 8D 06 42     STA $4206
C1/F17E: C2 20        REP #$20
C1/F180: A5 70        LDA $70
C1/F182: 18           CLC 
C1/F183: 65 76        ADC $76
C1/F185: 85 70        STA $70
C1/F187: A6 7A        LDX $7A
C1/F189: 8E 02 42     STX $4202
C1/F18C: AD 14 42     LDA $4214
C1/F18F: AA           TAX 
C1/F190: 8E 03 42     STX $4203
C1/F193: 85 7E        STA $7E
C1/F195: 64 82        STZ $82
C1/F197: A6 7F        LDX $7F
C1/F199: AC 17 42     LDY $4217
C1/F19C: 8E 03 42     STX $4203
C1/F19F: 84 82        STY $82
C1/F1A1: A6 7C        LDX $7C
C1/F1A3: 64 84        STZ $84
C1/F1A5: AD 16 42     LDA $4216
C1/F1A8: 8E 02 42     STX $4202
C1/F1AB: A6 7E        LDX $7E
C1/F1AD: 8E 03 42     STX $4203
C1/F1B0: 18           CLC 
C1/F1B1: 65 82        ADC $82
C1/F1B3: 45 18        EOR $18
C1/F1B5: 65 1E        ADC $1E
C1/F1B7: AE 17 42     LDX $4217
C1/F1BA: 86 84        STX $84
C1/F1BC: A6 7F        LDX $7F
C1/F1BE: 8E 03 42     STX $4203
C1/F1C1: A4 1C        LDY $1C
C1/F1C3: 99 A0 0C     STA $0CA0,Y
C1/F1C6: 99 40 0F     STA $0F40,Y
C1/F1C9: AD 16 42     LDA $4216
C1/F1CC: 18           CLC 
C1/F1CD: 65 84        ADC $84
C1/F1CF: 45 1A        EOR $1A
C1/F1D1: 65 20        ADC $20
C1/F1D3: 99 80 0D     STA $0D80,Y
C1/F1D6: 49 FF FF     EOR #$FFFF
C1/F1D9: 1A           INC 
C1/F1DA: 99 60 0E     STA $0E60,Y
C1/F1DD: C8           INY 
C1/F1DE: C8           INY 
C1/F1DF: C0 E0 D0     CPY #$D0E0
C1/F1E2: 91 7B        STA ($7B),Y
C1/F1E4: E2 20        SEP #$20
C1/F1E6: C2 10        REP #$10
C1/F1E8: AB           PLB 
C1/F1E9: 60           RTS 
C1/F1EA: C2 20        REP #$20
C1/F1EC: AD E7 F9     LDA $F9E7
C1/F1EF: 85 70        STA $70
C1/F1F1: AD E7 F9     LDA $F9E7
C1/F1F4: 38           SEC 
C1/F1F5: ED E9 F9     SBC $F9E9
C1/F1F8: 8F 04 42 00  STA $004204
C1/F1FC: 7B           TDC 
C1/F1FD: E2 20        SEP #$20
C1/F1FF: A9 70        LDA #$70
C1/F201: 8F 06 42 00  STA $004206
C1/F205: 8B           PHB 
C1/F206: A9 00        LDA #$00
C1/F208: A8           TAY 
C1/F209: 48           PHA 
C1/F20A: AB           PLB 
C1/F20B: C2 20        REP #$20
C1/F20D: EA           NOP 
C1/F20E: EA           NOP 
C1/F20F: AD 14 42     LDA $4214
C1/F212: 0A           ASL 
C1/F213: 85 76        STA $76
C1/F215: E2 10        SEP #$10
C1/F217: AF E3 F9 7E  LDA $7EF9E3
C1/F21B: 8D 04 42     STA $4204
C1/F21E: 84 1C        STY $1C
C1/F220: E2 20        SEP #$20
C1/F222: A5 71        LDA $71
C1/F224: 0A           ASL 
C1/F225: 8D 06 42     STA $4206
C1/F228: C2 20        REP #$20
C1/F22A: A5 70        LDA $70
C1/F22C: 38           SEC 
C1/F22D: E5 76        SBC $76
C1/F22F: 85 70        STA $70
C1/F231: A6 7A        LDX $7A
C1/F233: 8E 02 42     STX $4202
C1/F236: AD 14 42     LDA $4214
C1/F239: AA           TAX 
C1/F23A: 8E 03 42     STX $4203
C1/F23D: 85 7E        STA $7E
C1/F23F: 64 82        STZ $82
C1/F241: A6 7F        LDX $7F
C1/F243: AC 17 42     LDY $4217
C1/F246: 8E 03 42     STX $4203
C1/F249: 84 82        STY $82
C1/F24B: A6 7C        LDX $7C
C1/F24D: 64 84        STZ $84
C1/F24F: AD 16 42     LDA $4216
C1/F252: 8E 02 42     STX $4202
C1/F255: A6 7E        LDX $7E
C1/F257: 8E 03 42     STX $4203
C1/F25A: 18           CLC 
C1/F25B: 65 82        ADC $82
C1/F25D: 45 18        EOR $18
C1/F25F: 65 1E        ADC $1E
C1/F261: AE 17 42     LDX $4217
C1/F264: 86 84        STX $84
C1/F266: A6 7F        LDX $7F
C1/F268: 8E 03 42     STX $4203
C1/F26B: A4 1C        LDY $1C
C1/F26D: 99 A0 0C     STA $0CA0,Y
C1/F270: 99 40 0F     STA $0F40,Y
C1/F273: AD 16 42     LDA $4216
C1/F276: 18           CLC 
C1/F277: 65 84        ADC $84
C1/F279: 45 1A        EOR $1A
C1/F27B: 65 20        ADC $20
C1/F27D: 99 80 0D     STA $0D80,Y
C1/F280: 49 FF FF     EOR #$FFFF
C1/F283: 1A           INC 
C1/F284: 99 60 0E     STA $0E60,Y
C1/F287: C8           INY 
C1/F288: C8           INY 
C1/F289: C0 E0 D0     CPY #$D0E0
C1/F28C: 91 7B        STA ($7B),Y
C1/F28E: E2 20        SEP #$20
C1/F290: C2 10        REP #$10
C1/F292: AB           PLB 
C1/F293: 60           RTS 

C1/F294: F2BC F2C0 F2C4 F2CB F2F4 F2FC F304 F30C
C1/F2A4: F314 F31C F324 F32C F334 F33C F344 F34C
C1/F2B4: F2D2 F2DF F2EC F2F0

C1/F2BC: EE EB F9     INC $F9EB
C1/F2BF: 60           RTS 

C1/F2C0: CE EB F9     DEC $F9EB
C1/F2C3: 60           RTS 

C1/F2C4: EE E4 F9     INC $F9E4
C1/F2C7: EE E6 F9     INC $F9E6
C1/F2CA: 60           RTS 

C1/F2CB: CE E4 F9     DEC $F9E4
C1/F2CE: CE E6 F9     DEC $F9E6
C1/F2D1: 60           RTS 

C1/F2D2: EE E4 F9     INC $F9E4
C1/F2D5: EE E4 F9     INC $F9E4
C1/F2D8: EE E4 F9     INC $F9E4
C1/F2DB: EE E4 F9     INC $F9E4
C1/F2DE: 60           RTS 

C1/F2DF: CE E4 F9     DEC $F9E4
C1/F2E2: CE E4 F9     DEC $F9E4
C1/F2E5: CE E4 F9     DEC $F9E4
C1/F2E8: CE E4 F9     DEC $F9E4
C1/F2EB: 60           RTS 

C1/F2EC: EE E6 F9     INC $F9E6
C1/F2EF: 60           RTS 

C1/F2F0: CE E6 F9     DEC $F9E6
C1/F2F3: 60           RTS 

C1/F2F4: AE E7 F9     LDX $F9E7
C1/F2F7: E8           INX 
C1/F2F8: 8E E7 F9     STX $F9E7
C1/F2FB: 60           RTS 

C1/F2FC: AE E7 F9     LDX $F9E7
C1/F2FF: CA           DEX 
C1/F300: 8E E7 F9     STX $F9E7
C1/F303: 60           RTS 

C1/F304: AE E9 F9     LDX $F9E9
C1/F307: E8           INX 
C1/F308: 8E E9 F9     STX $F9E9
C1/F30B: 60           RTS 

C1/F30C: AE E7 F9     LDX $F9E7
C1/F30F: CA           DEX 
C1/F310: 8E E7 F9     STX $F9E7
C1/F313: 60           RTS 

C1/F314: AD E8 F9     LDA $F9E8
C1/F317: 1A           INC 
C1/F318: 8D E8 F9     STA $F9E8
C1/F31B: 60           RTS 

C1/F31C: AD E8 F9     LDA $F9E8
C1/F31F: 3A           DEC 
C1/F320: 8D E8 F9     STA $F9E8
C1/F323: 60           RTS 

C1/F324: AD EA F9     LDA $F9EA
C1/F327: 1A           INC 
C1/F328: 8D EA F9     STA $F9EA
C1/F32B: 60           RTS 

C1/F32C: AD EA F9     LDA $F9EA
C1/F32F: 3A           DEC 
C1/F330: 8D EA F9     STA $F9EA
C1/F333: 60           RTS 

C1/F334: AE 77 BC     LDX $BC77
C1/F337: E8           INX 
C1/F338: 8E 77 BC     STX $BC77
C1/F33B: 60           RTS 

C1/F33C: AE 77 BC     LDX $BC77
C1/F33F: CA           DEX 
C1/F340: 8E 77 BC     STX $BC77
C1/F343: 60           RTS 

C1/F344: AE 79 BC     LDX $BC79
C1/F347: E8           INX 
C1/F348: 8E 79 BC     STX $BC79
C1/F34B: 60           RTS 

C1/F34C: AE 79 BC     LDX $BC79
C1/F34F: CA           DEX 
C1/F350: 8E 79 BC     STX $BC79
C1/F353: 60           RTS 

C1/F354: AD 28 FF     LDA $FF28
C1/F357: F0 05        BEQ $F35E
C1/F359: CE 28 FF     DEC $FF28
C1/F35C: 38           SEC 
C1/F35D: 60           RTS 

C1/F35E: AE 06 FF     LDX $FF06
C1/F361: BF DA DD D0  LDA $D0DDDA,X
C1/F365: C9 FF        CMP #$FF
C1/F367: F0 27        BEQ $F390
C1/F369: C9 FE        CMP #$FE
C1/F36B: F0 1D        BEQ $F38A
C1/F36D: C9 FD        CMP #$FD
C1/F36F: D0 0A        BNE $F37B
C1/F371: BF DB DD D0  LDA $D0DDDB,X
C1/F375: 8D 28 FF     STA $FF28
C1/F378: 4C 85 F3     JMP $F385
C1/F37B: 29 1F        AND #$1F
C1/F37D: A8           TAY 
C1/F37E: BF DB DD D0  LDA $D0DDDB,X
C1/F382: 99 08 FF     STA $FF08,Y
C1/F385: E8           INX 
C1/F386: E8           INX 
C1/F387: 4C 61 F3     JMP $F361
C1/F38A: E8           INX 
C1/F38B: 8E 06 FF     STX $FF06
C1/F38E: 38           SEC 
C1/F38F: 60           RTS 
C1/F390: 18           CLC 
C1/F391: 60           RTS 

; [  ]

C1/F392: 7B           TDC 
C1/F393: AA           TAX 
C1/F394: BD 08 FF     LDA $FF08,X
C1/F397: F0 17        BEQ $F3B0
C1/F399: DE 08 FF     DEC $FF08,X
C1/F39C: DA           PHX 
C1/F39D: 8A           TXA 
C1/F39E: 0A           ASL 
C1/F39F: AA           TAX 
C1/F3A0: BF 94 F2 C1  LDA $C1F294,X
C1/F3A4: 85 74        STA $74
C1/F3A6: BF 95 F2 C1  LDA $C1F295,X
C1/F3AA: 85 75        STA $75
C1/F3AC: 20 B7 F3     JSR $F3B7
C1/F3AF: FA           PLX 
C1/F3B0: E8           INX 
C1/F3B1: E0 20 00     CPX #$0020
C1/F3B4: D0 DE        BNE $F394
C1/F3B6: 60           RTS 
C1/F3B7: 6C 74 00     JMP ($0074)

; [  ]

C1/F3BA: 9C DC F9     STZ $F9DC
C1/F3BD: 64 E6        STZ $E6
C1/F3BF: 7B           TDC 
C1/F3C0: AA           TAX 
C1/F3C1: 85 70        STA $70
C1/F3C3: 9E 09 98     STZ $9809,X
C1/F3C6: A5 70        LDA $70
C1/F3C8: 18           CLC 
C1/F3C9: 69 02        ADC #$02
C1/F3CB: 85 70        STA $70
C1/F3CD: 9D 09 A2     STA $A209,X
C1/F3D0: A9 7C        LDA #$7C
C1/F3D2: 9D 09 9D     STA $9D09,X
C1/F3D5: A9 6C        LDA #$6C
C1/F3D7: 9D 09 9E     STA $9E09,X
C1/F3DA: A9 07        LDA #$07
C1/F3DC: 9D 09 A1     STA $A109,X
C1/F3DF: E8           INX 
C1/F3E0: E0 40 00     CPX #$0040
C1/F3E3: D0 DE        BNE $F3C3
C1/F3E5: 7B           TDC 
C1/F3E6: AA           TAX 
C1/F3E7: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C1/F3EB: 9D 89 A2     STA $A289,X
C1/F3EE: E8           INX 
C1/F3EF: E0 00 01     CPX #$0100
C1/F3F2: D0 F3        BNE $F3E7
C1/F3F4: 7B           TDC 
C1/F3F5: AA           TAX 
C1/F3F6: BF A9 F6 C1  LDA $C1F6A9,X
C1/F3FA: 9D 89 A3     STA $A389,X
C1/F3FD: E8           INX 
C1/F3FE: E0 10 00     CPX #$0010
C1/F401: D0 F3        BNE $F3F6
C1/F403: 7B           TDC 
C1/F404: AA           TAX 
C1/F405: BF 20 E3 D0  LDA $D0E320,X
C1/F409: 9D C9 7F     STA $7FC9,X
C1/F40C: E8           INX 
C1/F40D: E0 20 00     CPX #$0020
C1/F410: D0 F3        BNE $F405
C1/F412: 60           RTS 

; [  ]

C1/F413: 20 24 EE     JSR $EE24
C1/F416: 20 FF F0     JSR $F0FF
C1/F419: 20 54 F3     JSR $F354
C1/F41C: B0 F5        BCS $F413
C1/F41E: 7B           TDC 
C1/F41F: AA           TAX 
C1/F420: C2 20        REP #$20
C1/F422: A9 00 01     LDA #$0100
C1/F425: 9D A0 0C     STA $0CA0,X
C1/F428: 9D 40 0F     STA $0F40,X
C1/F42B: 9E 80 0D     STZ $0D80,X
C1/F42E: 9E 60 0E     STZ $0E60,X
C1/F431: E8           INX 
C1/F432: E8           INX 
C1/F433: E0 70 00     CPX #$0070
C1/F436: D0 ED        BNE $F425
C1/F438: 7B           TDC 
C1/F439: E2 20        SEP #$20
C1/F43B: A9 E0        LDA #$E0
C1/F43D: 8D 88 BC     STA $BC88
C1/F440: 8D 89 BC     STA $BC89
C1/F443: 8D 8A BC     STA $BC8A
C1/F446: 8F 32 21 00  STA $002132
C1/F44A: A9 01        LDA #$01
C1/F44C: 8F 2D 21 00  STA $00212D
C1/F450: A9 02        LDA #$02
C1/F452: 8F 30 21 00  STA $002130
C1/F456: A9 10        LDA #$10
C1/F458: 8F 31 21 00  STA $002131
C1/F45C: 20 BD F4     JSR $F4BD
C1/F45F: A2 10 0E     LDX #$0E10
C1/F462: DA           PHX 
C1/F463: 20 75 F4     JSR $F475
C1/F466: FA           PLX 
C1/F467: CA           DEX 
C1/F468: D0 F8        BNE $F462
C1/F46A: A9 08        LDA #$08
C1/F46C: 8D 04 FF     STA $FF04
C1/F46F: 20 75 F4     JSR $F475
C1/F472: 4C 6F F4     JMP $F46F

; [  ]

C1/F475: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F478: 20 F6 F5     JSR $F5F6
C1/F47B: 20 96 FC     JSR $FC96       ; generate random number
C1/F47E: 29 7F        AND #$7F
C1/F480: D0 03        BNE $F485
C1/F482: 4C 86 F4     JMP $F486
C1/F485: 60           RTS 
C1/F486: A9 02        LDA #$02
C1/F488: 8D 11 D1     STA $D111
C1/F48B: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F48E: 20 F6 F5     JSR $F5F6
C1/F491: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F494: 20 F6 F5     JSR $F5F6
C1/F497: 7B           TDC 
C1/F498: AA           TAX 
C1/F499: 9D 89 7F     STA $7F89,X
C1/F49C: E8           INX 
C1/F49D: E0 20 00     CPX #$0020
C1/F4A0: D0 F7        BNE $F499
C1/F4A2: AD 11 D1     LDA $D111
C1/F4A5: 0A           ASL 
C1/F4A6: AA           TAX 
C1/F4A7: C2 20        REP #$20
C1/F4A9: A9 FF 7F     LDA #$7FFF
C1/F4AC: 9D 89 7F     STA $7F89,X
C1/F4AF: 7B           TDC 
C1/F4B0: E2 20        SEP #$20
C1/F4B2: EE 11 D1     INC $D111
C1/F4B5: AD 11 D1     LDA $D111
C1/F4B8: C9 0A        CMP #$0A
C1/F4BA: D0 CF        BNE $F48B
C1/F4BC: 60           RTS 

; [  ]

C1/F4BD: 7B           TDC 
C1/F4BE: AA           TAX 
C1/F4BF: BF 98 E1 D0  LDA $D0E198,X
C1/F4C3: 9D 00 02     STA $0200,X
C1/F4C6: E8           INX 
C1/F4C7: E0 40 00     CPX #$0040
C1/F4CA: D0 F3        BNE $F4BF
C1/F4CC: 7B           TDC 
C1/F4CD: AA           TAX 
C1/F4CE: A9 AA        LDA #$AA
C1/F4D0: 9D 00 04     STA $0400,X
C1/F4D3: E8           INX 
C1/F4D4: E0 10 00     CPX #$0010
C1/F4D7: D0 F7        BNE $F4D0
C1/F4D9: 60           RTS 

; [  ]

C1/F4DA: 8B           PHB 
C1/F4DB: A9 00        LDA #$00
C1/F4DD: 48           PHA 
C1/F4DE: AB           PLB 
C1/F4DF: A9 42        LDA #$42
C1/F4E1: 8D 00 43     STA $4300
C1/F4E4: 8D 10 43     STA $4310
C1/F4E7: 8D 30 43     STA $4330
C1/F4EA: 8D 70 43     STA $4370
C1/F4ED: A9 1B        LDA #$1B        ; HDMA to M7A through M7D
C1/F4EF: 8D 01 43     STA $4301
C1/F4F2: A9 1C        LDA #$1C
C1/F4F4: 8D 11 43     STA $4311
C1/F4F7: A9 1D        LDA #$1D
C1/F4F9: 8D 31 43     STA $4331
C1/F4FC: A9 1E        LDA #$1E
C1/F4FE: 8D 71 43     STA $4371
C1/F501: A2 B1 BC     LDX #$BCB1
C1/F504: 8E 02 43     STX $4302
C1/F507: A2 52 BF     LDX #$BF52
C1/F50A: 8E 12 43     STX $4312
C1/F50D: A2 F3 C1     LDX #$C1F3
C1/F510: 8E 32 43     STX $4332
C1/F513: A2 94 C4     LDX #$C494
C1/F516: 8E 72 43     STX $4372
C1/F519: A9 7E        LDA #$7E
C1/F51B: 8D 04 43     STA $4304
C1/F51E: A9 7E        LDA #$7E
C1/F520: 8D 14 43     STA $4314
C1/F523: A9 7E        LDA #$7E
C1/F525: 8D 34 43     STA $4334
C1/F528: A9 7E        LDA #$7E
C1/F52A: 8D 74 43     STA $4374
C1/F52D: A9 00        LDA #$00
C1/F52F: 8D 07 43     STA $4307
C1/F532: A9 00        LDA #$00
C1/F534: 8D 17 43     STA $4317
C1/F537: A9 00        LDA #$00
C1/F539: 8D 37 43     STA $4337
C1/F53C: A9 00        LDA #$00
C1/F53E: 8D 77 43     STA $4377
C1/F541: AF 84 BC 7E  LDA $7EBC84
C1/F545: 09 8B        ORA #$8B
C1/F547: 8F 84 BC 7E  STA $7EBC84
C1/F54B: AB           PLB 
C1/F54C: 60           RTS 

; [  ]

C1/F54D: A0 A0 0C     LDY #$0CA0
C1/F550: 7B           TDC 
C1/F551: AA           TAX 
C1/F552: A9 02        LDA #$02
C1/F554: 9D B1 BC     STA $BCB1,X
C1/F557: 9D B4 BC     STA $BCB4,X
C1/F55A: C2 20        REP #$20
C1/F55C: 98           TYA 
C1/F55D: 9D B2 BC     STA $BCB2,X
C1/F560: 9D B5 BC     STA $BCB5,X
C1/F563: 8A           TXA 
C1/F564: 18           CLC 
C1/F565: 69 06 00     ADC #$0006
C1/F568: AA           TAX 
C1/F569: 7B           TDC 
C1/F56A: E2 20        SEP #$20
C1/F56C: C8           INY 
C1/F56D: C8           INY 
C1/F56E: C0 80 0D     CPY #$0D80
C1/F571: D0 DF        BNE $F552
C1/F573: 7B           TDC 
C1/F574: 9D B1 BC     STA $BCB1,X
C1/F577: A0 80 0D     LDY #$0D80
C1/F57A: 7B           TDC 
C1/F57B: AA           TAX 
C1/F57C: A9 02        LDA #$02
C1/F57E: 9D 52 BF     STA $BF52,X
C1/F581: 9D 55 BF     STA $BF55,X
C1/F584: C2 20        REP #$20
C1/F586: 98           TYA 
C1/F587: 9D 53 BF     STA $BF53,X
C1/F58A: 9D 56 BF     STA $BF56,X
C1/F58D: 8A           TXA 
C1/F58E: 18           CLC 
C1/F58F: 69 06 00     ADC #$0006
C1/F592: AA           TAX 
C1/F593: 7B           TDC 
C1/F594: E2 20        SEP #$20
C1/F596: C8           INY 
C1/F597: C8           INY 
C1/F598: C0 60 0E     CPY #$0E60
C1/F59B: D0 DF        BNE $F57C
C1/F59D: 7B           TDC 
C1/F59E: 9D 52 BF     STA $BF52,X
C1/F5A1: A0 60 0E     LDY #$0E60
C1/F5A4: 7B           TDC 
C1/F5A5: AA           TAX 
C1/F5A6: A9 02        LDA #$02
C1/F5A8: 9D F3 C1     STA $C1F3,X
C1/F5AB: 9D F6 C1     STA $C1F6,X
C1/F5AE: C2 20        REP #$20
C1/F5B0: 98           TYA 
C1/F5B1: 9D F4 C1     STA $C1F4,X
C1/F5B4: 9D F7 C1     STA $C1F7,X
C1/F5B7: 8A           TXA 
C1/F5B8: 18           CLC 
C1/F5B9: 69 06 00     ADC #$0006
C1/F5BC: AA           TAX 
C1/F5BD: 7B           TDC 
C1/F5BE: E2 20        SEP #$20
C1/F5C0: C8           INY 
C1/F5C1: C8           INY 
C1/F5C2: C0 40 0F     CPY #$0F40
C1/F5C5: D0 DF        BNE $F5A6
C1/F5C7: 7B           TDC 
C1/F5C8: 9D F3 C1     STA $C1F3,X
C1/F5CB: A0 40 0F     LDY #$0F40
C1/F5CE: 7B           TDC 
C1/F5CF: AA           TAX 
C1/F5D0: A9 02        LDA #$02
C1/F5D2: 9D 94 C4     STA $C494,X
C1/F5D5: 9D 97 C4     STA $C497,X
C1/F5D8: C2 20        REP #$20
C1/F5DA: 98           TYA 
C1/F5DB: 9D 95 C4     STA $C495,X
C1/F5DE: 9D 98 C4     STA $C498,X
C1/F5E1: 8A           TXA 
C1/F5E2: 18           CLC 
C1/F5E3: 69 06 00     ADC #$0006
C1/F5E6: AA           TAX 
C1/F5E7: 7B           TDC 
C1/F5E8: E2 20        SEP #$20
C1/F5EA: C8           INY 
C1/F5EB: C8           INY 
C1/F5EC: C0 20 10     CPY #$1020
C1/F5EF: D0 DF        BNE $F5D0
C1/F5F1: 7B           TDC 
C1/F5F2: 9D 94 C4     STA $C494,X
C1/F5F5: 60           RTS 

; [  ]

C1/F5F6: 20 1D F0     JSR $F01D
C1/F5F9: 4C 9E EF     JMP $EF9E

; [  ]

C1/F5FC: 7B           TDC 
C1/F5FD: AA           TAX 
C1/F5FE: A8           TAY 
C1/F5FF: B9 09 A2     LDA $A209,Y
C1/F602: F0 06        BEQ $F60A
C1/F604: 3A           DEC 
C1/F605: 99 09 A2     STA $A209,Y
C1/F608: 80 7C        BRA $F686
C1/F60A: B9 09 98     LDA $9809,Y
C1/F60D: D0 35        BNE $F644
C1/F60F: 20 96 FC     JSR $FC96       ; generate random number
C1/F612: 99 89 98     STA $9889,Y
C1/F615: 18           CLC 
C1/F616: 69 40        ADC #$40
C1/F618: 99 09 99     STA $9909,Y
C1/F61B: 20 96 FC     JSR $FC96       ; generate random number
C1/F61E: 29 7F        AND #$7F
C1/F620: 18           CLC 
C1/F621: 69 08        ADC #$08
C1/F623: C2 20        REP #$20
C1/F625: 9D 89 99     STA $9989,X
C1/F628: 7B           TDC 
C1/F629: E2 20        SEP #$20
C1/F62B: A9 01        LDA #$01
C1/F62D: 99 09 98     STA $9809,Y
C1/F630: A9 03        LDA #$03
C1/F632: 99 89 9B     STA $9B89,Y
C1/F635: 20 96 FC     JSR $FC96       ; generate random number
C1/F638: 29 3F        AND #$3F
C1/F63A: 99 09 9C     STA $9C09,Y
C1/F63D: 7B           TDC 
C1/F63E: 9D 89 9A     STA $9A89,X
C1/F641: 9D 8A 9A     STA $9A8A,X
C1/F644: B9 09 9C     LDA $9C09,Y
C1/F647: 85 8C        STA $8C
C1/F649: B9 89 9C     LDA $9C89,Y
C1/F64C: 18           CLC 
C1/F64D: 65 8C        ADC $8C
C1/F64F: 99 89 9C     STA $9C89,Y
C1/F652: 90 07        BCC $F65B
C1/F654: B9 89 9B     LDA $9B89,Y
C1/F657: 1A           INC 
C1/F658: 99 89 9B     STA $9B89,Y
C1/F65B: B9 89 9B     LDA $9B89,Y
C1/F65E: C2 20        REP #$20
C1/F660: 85 8A        STA $8A
C1/F662: BD 89 99     LDA $9989,X
C1/F665: 18           CLC 
C1/F666: 65 8A        ADC $8A
C1/F668: 9D 89 99     STA $9989,X
C1/F66B: 85 88        STA $88
C1/F66D: BD 89 9A     LDA $9A89,X
C1/F670: 18           CLC 
C1/F671: 65 8A        ADC $8A
C1/F673: 9D 89 9A     STA $9A89,X
C1/F676: 7B           TDC 
C1/F677: E2 20        SEP #$20
C1/F679: DA           PHX 
C1/F67A: A6 88        LDX $88
C1/F67C: E0 20 01     CPX #$0120
C1/F67F: 90 04        BCC $F685
C1/F681: 7B           TDC 
C1/F682: 99 09 98     STA $9809,Y
C1/F685: FA           PLX 
C1/F686: DA           PHX 
C1/F687: C2 20        REP #$20
C1/F689: BD 89 9A     LDA $9A89,X
C1/F68C: 4A           LSR 
C1/F68D: 4A           LSR 
C1/F68E: 4A           LSR 
C1/F68F: 4A           LSR 
C1/F690: 4A           LSR 
C1/F691: AA           TAX 
C1/F692: 7B           TDC 
C1/F693: E2 20        SEP #$20
C1/F695: BF A9 F6 C1  LDA $C1F6A9,X
C1/F699: FA           PLX 
C1/F69A: 9D 09 A1     STA $A109,X
C1/F69D: C8           INY 
C1/F69E: E8           INX 
C1/F69F: E8           INX 
C1/F6A0: C0 60 00     CPY #$0060
C1/F6A3: F0 03        BEQ $F6A8
C1/F6A5: 4C FF F5     JMP $F5FF
C1/F6A8: 60           RTS 

C1/F6A9: 07 06 05 04 03 02 02 01 01 00 00 00

C1/F6B5: 7B           TDC 
C1/F6B6: AA           TAX 
C1/F6B7: A8           TAY 
C1/F6B8: B9 09 98     LDA $9809,Y
C1/F6BB: D0 10        BNE $F6CD
C1/F6BD: C2 20        REP #$20
C1/F6BF: A9 F0 00     LDA #$00F0
C1/F6C2: 9D 09 A0     STA $A009,X
C1/F6C5: 9D 09 9F     STA $9F09,X
C1/F6C8: 7B           TDC 
C1/F6C9: E2 20        SEP #$20
C1/F6CB: 80 50        BRA $F71D
C1/F6CD: DA           PHX 
C1/F6CE: B9 89 98     LDA $9889,Y
C1/F6D1: AA           TAX 
C1/F6D2: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/F6D6: 85 88        STA $88
C1/F6D8: B9 09 99     LDA $9909,Y
C1/F6DB: AA           TAX 
C1/F6DC: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/F6E0: 85 89        STA $89
C1/F6E2: FA           PLX 
C1/F6E3: BD 89 99     LDA $9989,X
C1/F6E6: 8F 1B 21 00  STA $00211B
C1/F6EA: BD 8A 99     LDA $998A,X
C1/F6ED: 8F 1B 21 00  STA $00211B
C1/F6F1: A5 88        LDA $88
C1/F6F3: 8F 1C 21 00  STA $00211C
C1/F6F7: C2 20        REP #$20
C1/F6F9: AF 35 21 00  LDA $002135
C1/F6FD: 18           CLC 
C1/F6FE: 7D 09 9E     ADC $9E09,X
C1/F701: 9D 09 A0     STA $A009,X
C1/F704: 7B           TDC 
C1/F705: E2 20        SEP #$20
C1/F707: A5 89        LDA $89
C1/F709: 8F 1C 21 00  STA $00211C
C1/F70D: C2 20        REP #$20
C1/F70F: AF 35 21 00  LDA $002135
C1/F713: 18           CLC 
C1/F714: 7D 09 9D     ADC $9D09,X
C1/F717: 9D 09 9F     STA $9F09,X
C1/F71A: 7B           TDC 
C1/F71B: E2 20        SEP #$20
C1/F71D: C8           INY 
C1/F71E: E8           INX 
C1/F71F: E8           INX 
C1/F720: C0 60 00     CPY #$0060
C1/F723: D0 93        BNE $F6B8
C1/F725: 7B           TDC 
C1/F726: AA           TAX 
C1/F727: A8           TAY 
C1/F728: BD 0A 9F     LDA $9F0A,X
C1/F72B: 1D 0A A0     ORA $A00A,X
C1/F72E: 29 01        AND #$01
C1/F730: F0 0A        BEQ $F73C
C1/F732: A9 F0        LDA #$F0
C1/F734: 99 00 02     STA $0200,Y
C1/F737: 99 01 02     STA $0201,Y
C1/F73A: 80 17        BRA $F753
C1/F73C: BD 09 9F     LDA $9F09,X
C1/F73F: 99 00 02     STA $0200,Y
C1/F742: BD 09 A0     LDA $A009,X
C1/F745: 99 01 02     STA $0201,Y
C1/F748: BD 09 A1     LDA $A109,X
C1/F74B: 99 02 02     STA $0202,Y
C1/F74E: A9 30        LDA #$30
C1/F750: 99 03 02     STA $0203,Y
C1/F753: C8           INY 
C1/F754: C8           INY 
C1/F755: C8           INY 
C1/F756: C8           INY 
C1/F757: E8           INX 
C1/F758: E8           INX 
C1/F759: C0 80 01     CPY #$0180
C1/F75C: D0 CA        BNE $F728
C1/F75E: 60           RTS 

; [ epilogue cutscene ]

; show the warp speed cutscene with epilogue text, "In the beginning, there was Void..."

C1/F75F: C2 10        REP #$10
C1/F761: E2 20        SEP #$20
C1/F763: 20 88 08     JSR $0888       ; init hardware registers
C1/F766: 20 8C F8     JSR $F88C
C1/F769: 20 F9 F8     JSR $F8F9
C1/F76C: A9 14        LDA #$14
C1/F76E: 8F 2C 21 00  STA $00212C
C1/F772: 8F 2E 21 00  STA $00212E
C1/F776: AF 10 42 00  LDA $004210
C1/F77A: 10 FA        BPL $F776
C1/F77C: A9 81        LDA #$81
C1/F77E: 8F 00 42 00  STA $004200
C1/F782: 58           CLI 
C1/F783: A9 0F        LDA #$0F
C1/F785: 8D 7F BC     STA $BC7F
C1/F788: A9 B4        LDA #$B4        ; 180 frames (3 seconds)
C1/F78A: 20 83 F8     JSR $F883       ; wait
C1/F78D: 20 2B F8     JSR $F82B
; fallthrough

; [ fade out and return ]

C1/F790: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F793: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F796: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F799: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F79C: CE 7F BC     DEC $BC7F       ; decrement screen brightness
C1/F79F: AD 7F BC     LDA $BC7F
C1/F7A2: D0 EC        BNE $F790
C1/F7A4: 7B           TDC 
C1/F7A5: 8F 0C 42 00  STA $00420C
C1/F7A9: 8F 00 42 00  STA $004200
C1/F7AD: A9 80        LDA #$80
C1/F7AF: 8F 00 21 00  STA $002100
C1/F7B3: 9C 84 BC     STZ $BC84
C1/F7B6: 6B           RTL 

; [  ]

C1/F7B7: AD DC F9     LDA $F9DC
C1/F7BA: F0 34        BEQ $F7F0
C1/F7BC: 9C DC F9     STZ $F9DC
C1/F7BF: C2 20        REP #$20
C1/F7C1: AD DD F9     LDA $F9DD
C1/F7C4: 8F 16 21 00  STA $002116
C1/F7C8: A9 37 A9     LDA #$A937
C1/F7CB: 8F 42 43 00  STA $004342
C1/F7CF: A9 00 02     LDA #$0200
C1/F7D2: 8F 45 43 00  STA $004345
C1/F7D6: 7B           TDC 
C1/F7D7: E2 20        SEP #$20
C1/F7D9: A9 7E        LDA #$7E
C1/F7DB: 8F 44 43 00  STA $004344
C1/F7DF: 7B           TDC 
C1/F7E0: 8F 40 43 00  STA $004340
C1/F7E4: A9 19        LDA #$19
C1/F7E6: 8F 41 43 00  STA $004341
C1/F7EA: A9 10        LDA #$10
C1/F7EC: 8F 0B 42 00  STA $00420B
C1/F7F0: 60           RTS 

; [  ]

C1/F7F1: DA           PHX 
C1/F7F2: 64 74        STZ $74
C1/F7F4: AE A0 BC     LDX $BCA0
C1/F7F7: 86 70        STX $70
C1/F7F9: AD A2 BC     LDA $BCA2
C1/F7FC: 85 72        STA $72
C1/F7FE: 7B           TDC 
C1/F7FF: A8           TAY 
C1/F800: B7 70        LDA [$70],Y
C1/F802: F0 11        BEQ $F815
C1/F804: C9 01        CMP #$01
C1/F806: F0 0D        BEQ $F815
C1/F808: C9 20        CMP #$20
C1/F80A: 90 02        BCC $F80E
C1/F80C: 80 01        BRA $F80F
C1/F80E: C8           INY 
C1/F80F: C8           INY 
C1/F810: E6 74        INC $74
C1/F812: 4C 00 F8     JMP $F800
C1/F815: A9 10        LDA #$10
C1/F817: 38           SEC 
C1/F818: E5 74        SBC $74
C1/F81A: 85 7E        STA $7E
C1/F81C: A9 0D        LDA #$0D
C1/F81E: 85 80        STA $80
C1/F820: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/F823: A5 82        LDA $82
C1/F825: 4A           LSR 
C1/F826: 8D 07 F5     STA $F507
C1/F829: FA           PLX 
C1/F82A: 60           RTS 

; [  ]

C1/F82B: A9 02        LDA #$02
C1/F82D: 8D F1 DB     STA $DBF1
C1/F830: A2 40 E3     LDX #$E340
C1/F833: 8E DF F9     STX $F9DF
C1/F836: 7B           TDC 
C1/F837: AA           TAX 
C1/F838: 8E DD F9     STX $F9DD
C1/F83B: EE F4 DB     INC $DBF4
C1/F83E: A9 28        LDA #$28
C1/F840: 48           PHA 
C1/F841: 7B           TDC 
C1/F842: AA           TAX 
C1/F843: 9D 37 A9     STA $A937,X
C1/F846: E8           INX 
C1/F847: E0 00 02     CPX #$0200
C1/F84A: D0 F7        BNE $F843
C1/F84C: AE DF F9     LDX $F9DF
C1/F84F: 8E A0 BC     STX $BCA0
C1/F852: A9 D0        LDA #$D0
C1/F854: 8D A2 BC     STA $BCA2
C1/F857: 20 F1 F7     JSR $F7F1
C1/F85A: 20 71 29     JSR $2971       ; draw big text string
C1/F85D: AE B8 00     LDX $00B8
C1/F860: E8           INX 
C1/F861: 8E DF F9     STX $F9DF
C1/F864: EE DC F9     INC $F9DC
C1/F867: A9 3F        LDA #$3F        ; 63 frames
C1/F869: 20 83 F8     JSR $F883       ; wait
C1/F86C: C2 20        REP #$20
C1/F86E: AD DD F9     LDA $F9DD
C1/F871: 18           CLC 
C1/F872: 69 00 02     ADC #$0200
C1/F875: 29 FF 1F     AND #$1FFF
C1/F878: 8D DD F9     STA $F9DD
C1/F87B: 7B           TDC 
C1/F87C: E2 20        SEP #$20
C1/F87E: 68           PLA 
C1/F87F: 3A           DEC 
C1/F880: D0 BE        BNE $F840
C1/F882: 60           RTS 

; [ wait ]

; a: number of frames to wait

C1/F883: 48           PHA 
C1/F884: 20 1D FD     JSR $FD1D       ; wait for vblank
C1/F887: 68           PLA 
C1/F888: 3A           DEC 
C1/F889: D0 F8        BNE $F883
C1/F88B: 60           RTS 

; [  ]

C1/F88C: A9 C1        LDA #$C1
C1/F88E: 8D 03 1F     STA $1F03
C1/F891: A2 EF FA     LDX #$FAEF      ; nmi = C1/FAEF
C1/F894: 8E 01 1F     STX $1F01
C1/F897: A9 5C        LDA #$5C
C1/F899: 8D 00 1F     STA $1F00
C1/F89C: 8D 04 1F     STA $1F04
C1/F89F: A9 C1        LDA #$C1
C1/F8A1: 8D 07 1F     STA $1F07
C1/F8A4: A2 0D FA     LDX #$FA0D      ; irq = C1/FA0D (RTI)
C1/F8A7: 8E 05 1F     STX $1F05
C1/F8AA: 7B           TDC 
C1/F8AB: AA           TAX 
C1/F8AC: 9E 00 04     STZ $0400,X     ; clear hi-sprite data
C1/F8AF: E8           INX 
C1/F8B0: E0 20 00     CPX #$0020
C1/F8B3: D0 F7        BNE $F8AC
C1/F8B5: 7B           TDC 
C1/F8B6: AA           TAX 
C1/F8B7: A0 00 40     LDY #$4000
C1/F8BA: 20 BB FD     JSR $FDBB
C1/F8BD: 7B           TDC 
C1/F8BE: AA           TAX 
C1/F8BF: A8           TAY 
C1/F8C0: 64 70        STZ $70
C1/F8C2: 9E 09 98     STZ $9809,X
C1/F8C5: A5 70        LDA $70
C1/F8C7: 18           CLC 
C1/F8C8: 69 02        ADC #$02
C1/F8CA: 85 70        STA $70
C1/F8CC: 9D 09 A2     STA $A209,X
C1/F8CF: C2 20        REP #$20
C1/F8D1: A9 7C 00     LDA #$007C
C1/F8D4: 99 09 9D     STA $9D09,Y
C1/F8D7: A9 6C 00     LDA #$006C
C1/F8DA: 99 09 9E     STA $9E09,Y
C1/F8DD: A9 07 00     LDA #$0007
C1/F8E0: 99 09 A1     STA $A109,Y
C1/F8E3: E2 20        SEP #$20
C1/F8E5: E8           INX 
C1/F8E6: C8           INY 
C1/F8E7: C8           INY 
C1/F8E8: E0 60 00     CPX #$0060
C1/F8EB: D0 D5        BNE $F8C2
C1/F8ED: 9C DC F9     STZ $F9DC
C1/F8F0: 20 E3 F9     JSR $F9E3
C1/F8F3: 20 F3 F9     JSR $F9F3
C1/F8F6: 4C 22 FD     JMP $FD22       ; clear sprite data

; [  ]

C1/F8F9: 20 53 F9     JSR $F953
C1/F8FC: 9C 05 FF     STZ $FF05
C1/F8FF: 7B           TDC 
C1/F900: 8F 0C 21 00  STA $00210C
C1/F904: 9C F4 DB     STZ $DBF4
C1/F907: A9 48        LDA #$48
C1/F909: 8F 09 21 00  STA $002109
C1/F90D: A2 10 00     LDX #$0010
C1/F910: 8E FE FE     STX $FEFE
C1/F913: A2 E8 FF     LDX #$FFE8
C1/F916: 8E FC FE     STX $FEFC
C1/F919: A9 09        LDA #$09
C1/F91B: 8F 05 21 00  STA $002105
C1/F91F: 20 AB F9     JSR $F9AB
C1/F922: A9 84        LDA #$84
C1/F924: 8F 31 21 00  STA $002131
C1/F928: 8B           PHB 
C1/F929: A9 00        LDA #$00
C1/F92B: 48           PHA 
C1/F92C: AB           PLB 
C1/F92D: A9 40        LDA #$40
C1/F92F: 8D 20 43     STA $4320
C1/F932: A9 32        LDA #$32
C1/F934: 8D 21 43     STA $4321
C1/F937: A2 7A DD     LDX #$DD7A
C1/F93A: 8E 22 43     STX $4322
C1/F93D: A9 D0        LDA #$D0
C1/F93F: 8D 24 43     STA $4324
C1/F942: A9 7E        LDA #$7E
C1/F944: 8D 27 43     STA $4327
C1/F947: AF 84 BC 7E  LDA $7EBC84
C1/F94B: 09 04        ORA #$04
C1/F94D: 8F 84 BC 7E  STA $7EBC84
C1/F951: AB           PLB 
C1/F952: 60           RTS 

; [  ]

C1/F953: A2 00 C0     LDX #$C000
C1/F956: 86 70        STX $70
C1/F958: A9 7F        LDA #$7F
C1/F95A: 85 72        STA $72
C1/F95C: 85 76        STA $76
C1/F95E: A2 40 C0     LDX #$C040
C1/F961: 86 74        STX $74
C1/F963: C2 20        REP #$20
C1/F965: 64 78        STZ $78
C1/F967: 7B           TDC 
C1/F968: A8           TAY 
C1/F969: A5 78        LDA $78
C1/F96B: 09 00 20     ORA #$2000
C1/F96E: 97 70        STA [$70],Y
C1/F970: 1A           INC 
C1/F971: 97 74        STA [$74],Y
C1/F973: 1A           INC 
C1/F974: C8           INY 
C1/F975: C8           INY 
C1/F976: C0 40 00     CPY #$0040
C1/F979: D0 F0        BNE $F96B
C1/F97B: A5 70        LDA $70
C1/F97D: 18           CLC 
C1/F97E: 69 80 00     ADC #$0080
C1/F981: 85 70        STA $70
C1/F983: A5 74        LDA $74
C1/F985: 18           CLC 
C1/F986: 69 80 00     ADC #$0080
C1/F989: 85 74        STA $74
C1/F98B: A5 78        LDA $78
C1/F98D: 18           CLC 
C1/F98E: 69 40 00     ADC #$0040
C1/F991: 85 78        STA $78
C1/F993: C9 00 08     CMP #$0800
C1/F996: D0 CF        BNE $F967
C1/F998: 7B           TDC 
C1/F999: E2 20        SEP #$20
C1/F99B: A2 00 08     LDX #$0800
C1/F99E: 86 70        STX $70
C1/F9A0: A2 00 C0     LDX #$C000
C1/F9A3: A0 00 48     LDY #$4800
C1/F9A6: A9 7F        LDA #$7F
C1/F9A8: 4C CA FD     JMP $FDCA       ; copy data to vram

; [  ]

C1/F9AB: 7B           TDC 
C1/F9AC: AA           TAX 
C1/F9AD: A9 FF        LDA #$FF
C1/F9AF: 9D 55 B4     STA $B455,X
C1/F9B2: E8           INX 
C1/F9B3: E0 10 00     CPX #$0010
C1/F9B6: D0 F7        BNE $F9AF
C1/F9B8: 9D 55 B4     STA $B455,X
C1/F9BB: 3A           DEC 
C1/F9BC: E8           INX 
C1/F9BD: E0 30 00     CPX #$0030
C1/F9C0: D0 F6        BNE $F9B8
C1/F9C2: A9 E0        LDA #$E0
C1/F9C4: 9D 55 B4     STA $B455,X
C1/F9C7: E8           INX 
C1/F9C8: E0 B0 00     CPX #$00B0
C1/F9CB: D0 F7        BNE $F9C4
C1/F9CD: 9D 55 B4     STA $B455,X
C1/F9D0: 1A           INC 
C1/F9D1: E8           INX 
C1/F9D2: E0 D0 00     CPX #$00D0
C1/F9D5: D0 F6        BNE $F9CD
C1/F9D7: A9 FF        LDA #$FF
C1/F9D9: 9D 55 B4     STA $B455,X
C1/F9DC: E8           INX 
C1/F9DD: E0 E0 00     CPX #$00E0
C1/F9E0: D0 F7        BNE $F9D9
C1/F9E2: 60           RTS 
C1/F9E3: A2 00 02     LDX #$0200
C1/F9E6: 86 70        STX $70
C1/F9E8: A2 20 E2     LDX #$E220
C1/F9EB: A0 00 60     LDY #$6000
C1/F9EE: A9 D0        LDA #$D0
C1/F9F0: 4C CA FD     JMP $FDCA       ; copy data to vram

; [  ]

C1/F9F3: 7B           TDC 
C1/F9F4: AA           TAX 
C1/F9F5: BF 20 E3 D0  LDA $D0E320,X
C1/F9F9: 9D 09 7F     STA $7F09,X
C1/F9FC: A9 FF        LDA #$FF
C1/F9FE: 9D 09 7E     STA $7E09,X
C1/FA01: E8           INX 
C1/FA02: E0 20 00     CPX #$0020
C1/FA05: D0 EE        BNE $F9F5
C1/FA07: 7B           TDC 
C1/FA08: AA           TAX 
C1/FA09: 8E 09 7E     STX $7E09
C1/FA0C: 60           RTS 

; [ epilogue/stats screen irq ]

C1/FA0D: 40           RTI 

; [  ]

C1/FA0E: 7B           TDC 
C1/FA0F: AA           TAX 
C1/FA10: 86 88        STX $88
C1/FA12: 86 8A        STX $8A
C1/FA14: AD E7 F9     LDA $F9E7
C1/FA17: 8F 1B 21 00  STA $00211B
C1/FA1B: AD E8 F9     LDA $F9E8
C1/FA1E: 8F 1B 21 00  STA $00211B
C1/FA22: AD EB F9     LDA $F9EB
C1/FA25: 18           CLC 
C1/FA26: 6D EC F9     ADC $F9EC
C1/FA29: 85 98        STA $98
C1/FA2B: 18           CLC 
C1/FA2C: 69 40        ADC #$40
C1/FA2E: AA           TAX 
C1/FA2F: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/FA33: 10 07        BPL $FA3C
C1/FA35: A2 FF FF     LDX #$FFFF
C1/FA38: 86 88        STX $88
C1/FA3A: 49 FF        EOR #$FF
C1/FA3C: 8F 1C 21 00  STA $00211C
C1/FA40: C2 20        REP #$20
C1/FA42: AF 35 21 00  LDA $002135
C1/FA46: 45 88        EOR $88
C1/FA48: 8D 8E BC     STA $BC8E
C1/FA4B: 8D 94 BC     STA $BC94
C1/FA4E: 7B           TDC 
C1/FA4F: E2 20        SEP #$20
C1/FA51: A5 98        LDA $98
C1/FA53: AA           TAX 
C1/FA54: BF 00 F6 CE  LDA $CEF600,X   ; sine table
C1/FA58: 10 07        BPL $FA61
C1/FA5A: A2 FF FF     LDX #$FFFF
C1/FA5D: 86 8A        STX $8A
C1/FA5F: 49 FF        EOR #$FF
C1/FA61: 8F 1C 21 00  STA $00211C
C1/FA65: C2 20        REP #$20
C1/FA67: AF 35 21 00  LDA $002135
C1/FA6B: 45 8A        EOR $8A
C1/FA6D: 8D 90 BC     STA $BC90
C1/FA70: 49 FF FF     EOR #$FFFF
C1/FA73: 1A           INC 
C1/FA74: 8D 92 BC     STA $BC92
C1/FA77: 7B           TDC 
C1/FA78: E2 20        SEP #$20
C1/FA7A: 20 87 FA     JSR $FA87
C1/FA7D: 20 F4 FF     JSR $FFF4
C1/FA80: E6 A2        INC $A2
C1/FA82: 64 A5        STZ $A5
C1/FA84: 64 A4        STZ $A4
C1/FA86: 60           RTS 

; [  ]

C1/FA87: AD 81 BC     LDA $BC81
C1/FA8A: 8F 05 21 00  STA $002105
C1/FA8E: AD FB FE     LDA $FEFB
C1/FA91: 8F 2C 21 00  STA $00212C
C1/FA95: AD 84 BC     LDA $BC84
C1/FA98: 8F 0C 42 00  STA $00420C
C1/FA9C: AD 77 BC     LDA $BC77
C1/FA9F: 8F 0D 21 00  STA $00210D
C1/FAA3: AD 78 BC     LDA $BC78
C1/FAA6: 8F 0D 21 00  STA $00210D
C1/FAAA: AD 79 BC     LDA $BC79
C1/FAAD: 8F 0E 21 00  STA $00210E
C1/FAB1: AD 7A BC     LDA $BC7A
C1/FAB4: 8F 0E 21 00  STA $00210E
C1/FAB8: C2 20        REP #$20
C1/FABA: AD 77 BC     LDA $BC77
C1/FABD: 18           CLC 
C1/FABE: 69 80 00     ADC #$0080
C1/FAC1: 8D 96 BC     STA $BC96
C1/FAC4: AD 79 BC     LDA $BC79
C1/FAC7: 18           CLC 
C1/FAC8: 69 70 00     ADC #$0070
C1/FACB: 8D 98 BC     STA $BC98
C1/FACE: 7B           TDC 
C1/FACF: E2 20        SEP #$20
C1/FAD1: 20 E8 12     JSR $12E8
C1/FAD4: AD 7F BC     LDA $BC7F
C1/FAD7: 8F 00 21 00  STA $002100
C1/FADB: 60           RTS 


; [  ]

C1/FADC: 20 9C FD     JSR $FD9C
C1/FADF: 20 87 FA     JSR $FA87
C1/FAE2: 20 92 F3     JSR $F392
C1/FAE5: E6 A2        INC $A2
C1/FAE7: 20 81 0B     JSR $0B81       ; play queued song
C1/FAEA: 64 A5        STZ $A5
C1/FAEC: 64 A4        STZ $A4
C1/FAEE: 60           RTS 

; [ epilogue/stats screen nmi ]

C1/FAEF: 08           PHP 
C1/FAF0: C2 30        REP #$30
C1/FAF2: 48           PHA 
C1/FAF3: DA           PHX 
C1/FAF4: 5A           PHY 
C1/FAF5: 8B           PHB 
C1/FAF6: 0B           PHD 
C1/FAF7: A2 00 00     LDX #$0000
C1/FAFA: DA           PHX 
C1/FAFB: 2B           PLD 
C1/FAFC: 7B           TDC 
C1/FAFD: E2 20        SEP #$20
C1/FAFF: AF 10 42 00  LDA $004210
C1/FB03: A9 7E        LDA #$7E
C1/FB05: 48           PHA 
C1/FB06: AB           PLB 
C1/FB07: A5 A4        LDA $A4
C1/FB09: D0 63        BNE $FB6E
C1/FB0B: E6 A4        INC $A4
C1/FB0D: 7B           TDC 
C1/FB0E: 8F 00 21 00  STA $002100
C1/FB12: 20 C0 FD     JSR $FDC0
C1/FB15: 20 C5 FD     JSR $FDC5
C1/FB18: AD 05 FF     LDA $FF05
C1/FB1B: F0 06        BEQ $FB23
C1/FB1D: 20 0E FA     JSR $FA0E
C1/FB20: 4C 68 FB     JMP $FB68
C1/FB23: 20 B7 F7     JSR $F7B7
C1/FB26: AD 84 BC     LDA $BC84
C1/FB29: 8F 0C 42 00  STA $00420C
C1/FB2D: AD FC FE     LDA $FEFC
C1/FB30: 8F 11 21 00  STA $002111
C1/FB34: AD FD FE     LDA $FEFD
C1/FB37: 8F 11 21 00  STA $002111
C1/FB3B: AD FE FE     LDA $FEFE
C1/FB3E: 8F 12 21 00  STA $002112
C1/FB42: AD FF FE     LDA $FEFF
C1/FB45: 8F 12 21 00  STA $002112
C1/FB49: AD 7F BC     LDA $BC7F
C1/FB4C: 8F 00 21 00  STA $002100
C1/FB50: 20 B5 F6     JSR $F6B5
C1/FB53: 20 FC F5     JSR $F5FC
C1/FB56: AD F4 DB     LDA $DBF4
C1/FB59: F0 0D        BEQ $FB68
C1/FB5B: A5 A2        LDA $A2
C1/FB5D: 29 03        AND #$03
C1/FB5F: D0 07        BNE $FB68
C1/FB61: AE FE FE     LDX $FEFE
C1/FB64: E8           INX 
C1/FB65: 8E FE FE     STX $FEFE
C1/FB68: 64 A5        STZ $A5
C1/FB6A: 64 A4        STZ $A4
C1/FB6C: E6 A2        INC $A2
C1/FB6E: C2 30        REP #$30
C1/FB70: 2B           PLD 
C1/FB71: AB           PLB 
C1/FB72: 7A           PLY 
C1/FB73: FA           PLX 
C1/FB74: 68           PLA 
C1/FB75: 28           PLP 
C1/FB76: 40           RTI 

; [ decompress ]

C1/FB77: DA           PHX 
C1/FB78: 8B           PHB 
C1/FB79: AE F0 04     LDX $04F0
C1/FB7C: DA           PHX 
C1/FB7D: AE F2 04     LDX $04F2
C1/FB80: DA           PHX 
C1/FB81: AE F4 04     LDX $04F4
C1/FB84: DA           PHX 
C1/FB85: A5 74        LDA $74
C1/FB87: 8D F2 04     STA $04F2
C1/FB8A: A6 72        LDX $72
C1/FB8C: 8E F0 04     STX $04F0
C1/FB8F: A9 7F        LDA #$7F
C1/FB91: 8D F5 04     STA $04F5
C1/FB94: A2 00 C0     LDX #$C000
C1/FB97: 8E F3 04     STX $04F3
C1/FB9A: 22 02 00 C3  JSL $C30002     ; decompress
C1/FB9E: FA           PLX 
C1/FB9F: 8E F4 04     STX $04F4
C1/FBA2: FA           PLX 
C1/FBA3: 8E F2 04     STX $04F2
C1/FBA6: FA           PLX 
C1/FBA7: 8E F0 04     STX $04F0
C1/FBAA: AB           PLB 
C1/FBAB: FA           PLX 
C1/FBAC: 60           RTS 

; [ play system sound effect $10 ]

C1/FBAD: 48           PHA 
C1/FBAE: A9 10        LDA #$10
C1/FBB0: 8D B8 DB     STA $DBB8
C1/FBB3: EE B7 DB     INC $DBB7
C1/FBB6: 68           PLA 
C1/FBB7: 60           RTS 

; [ play system sound effect $11 ]

C1/FBB8: 48           PHA 
C1/FBB9: A9 11        LDA #$11
C1/FBBB: 8D B8 DB     STA $DBB8
C1/FBBE: EE B7 DB     INC $DBB7
C1/FBC1: 68           PLA 
C1/FBC2: 60           RTS 

; [ play system sound effect $11 ]

C1/FBC3: 48           PHA 
C1/FBC4: A9 11        LDA #$11
C1/FBC6: 8D B8 DB     STA $DBB8
C1/FBC9: EE B7 DB     INC $DBB7
C1/FBCC: 68           PLA 
C1/FBCD: 60           RTS 

; [ play system sound effect $12 ]

C1/FBCE: 48           PHA 
C1/FBCF: A9 12        LDA #$12
C1/FBD1: 8D B8 DB     STA $DBB8
C1/FBD4: EE B7 DB     INC $DBB7
C1/FBD7: 68           PLA 
C1/FBD8: 60           RTS 

; [ play sound effect ]

C1/FBD9: C9 FF        CMP #$FF
C1/FBDB: F0 06        BEQ $FBE3
C1/FBDD: 8D B5 DB     STA $DBB5
C1/FBE0: EE B4 DB     INC $DBB4
C1/FBE3: 60           RTS 

; [ play animation sound effect ]

C1/FBE4: 8D B5 DB     STA $DBB5       ; sound effect id
C1/FBE7: B2 EB        LDA ($EB)
C1/FBE9: 29 08        AND #$08
C1/FBEB: F0 05        BEQ $FBF2
C1/FBED: A9 52        LDA #$52        ; different sound effect ???
C1/FBEF: 8D B5 DB     STA $DBB5
C1/FBF2: B2 EB        LDA ($EB)
C1/FBF4: 29 40        AND #$40
C1/FBF6: F0 04        BEQ $FBFC
C1/FBF8: A9 33        LDA #$33        ; volume 3
C1/FBFA: 80 02        BRA $FBFE
C1/FBFC: A9 DD        LDA #$DD        ; volume 13
C1/FBFE: 8D B6 DB     STA $DBB6
C1/FC01: EE B4 DB     INC $DBB4
C1/FC04: 60           RTS 

; [ play queued game sound effect/set volume ]

C1/FC05: AD B4 DB     LDA $DBB4
C1/FC08: F0 22        BEQ $FC2C       ; branch if no sound effect
C1/FC0A: AD D3 DB     LDA $DBD3
C1/FC0D: D0 1D        BNE $FC2C       ; 
C1/FC0F: A9 02        LDA #$02        ; spc interrupt $02 (play game sound effect)
C1/FC11: 8D 00 1D     STA $1D00
C1/FC14: AD B5 DB     LDA $DBB5       ; sound effect id
C1/FC17: 8D 01 1D     STA $1D01
C1/FC1A: A9 0F        LDA #$0F        ; no envelope
C1/FC1C: 8D 02 1D     STA $1D02
C1/FC1F: AD B6 DB     LDA $DBB6       ; volume
C1/FC22: 8D 03 1D     STA $1D03
C1/FC25: 22 04 00 C4  JSL $C40004     ; execute spc command
C1/FC29: 9C B4 DB     STZ $DBB4
C1/FC2C: AD 2E FF     LDA $FF2E       ; fade out sound ???
C1/FC2F: F0 12        BEQ $FC43
C1/FC31: 18           CLC 
C1/FC32: 69 80        ADC #$80        ; spc interrupt $80/$81/$82 (set volume)
C1/FC34: 8D 00 1D     STA $1D00
C1/FC37: A9 F0        LDA #$F0        ; volume zero, max envelope duration
C1/FC39: 8D 01 1D     STA $1D01
C1/FC3C: 22 04 00 C4  JSL $C40004     ; execute spc command
C1/FC40: 9C 2E FF     STZ $FF2E
C1/FC43: 60           RTS 

; [ play queued system sound effect ]

C1/FC44: AD B7 DB     LDA $DBB7
C1/FC47: F0 0D        BEQ $FC56
C1/FC49: AD B8 DB     LDA $DBB8
C1/FC4C: 8D 00 1D     STA $1D00
C1/FC4F: 22 04 00 C4  JSL $C40004
C1/FC53: 9C B7 DB     STZ $DBB7
C1/FC56: 60           RTS 

; [  ]

C1/FC57: C2 20        REP #$20
C1/FC59: 0A           ASL 
C1/FC5A: 09 00 80     ORA #$8000
C1/FC5D: 8D 45 CD     STA $CD45
C1/FC60: 7B           TDC 
C1/FC61: E2 20        SEP #$20
C1/FC63: 60           RTS 
C1/FC64: DA           PHX 
C1/FC65: A2 80 80     LDX #$8080
C1/FC68: 8E 45 CD     STX $CD45
C1/FC6B: FA           PLX 
C1/FC6C: 60           RTS 
C1/FC6D: 9C 45 CD     STZ $CD45
C1/FC70: 9C 46 CD     STZ $CD46
C1/FC73: 60           RTS 

; [ get monster mask ]

C1/FC74: AA           TAX 
C1/FC75: BF 25 7D D9  LDA $D97D25,X
C1/FC79: 60           RTS 

; [  ]

C1/FC7A: DA           PHX 
C1/FC7B: A2 00 00     LDX #$0000
C1/FC7E: 0A           ASL 
C1/FC7F: B0 06        BCS $FC87
C1/FC81: E8           INX 
C1/FC82: E0 08 00     CPX #$0008
C1/FC85: D0 F7        BNE $FC7E
C1/FC87: 8A           TXA 
C1/FC88: 29 07        AND #$07
C1/FC8A: FA           PLX 
C1/FC8B: 60           RTS 

; [ wait for keypress ]

C1/FC8C: A5 00        LDA $00
C1/FC8E: 30 05        BMI $FC95
C1/FC90: 20 F2 02     JSR $02F2       ; wait one frame
C1/FC93: 80 F7        BRA $FC8C
C1/FC95: 60           RTS 

; [ generate random number ]

C1/FC96: DA           PHX 
C1/FC97: A5 E6        LDA $E6
C1/FC99: AA           TAX 
C1/FC9A: E6 E6        INC $E6
C1/FC9C: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C1/FCA0: FA           PLX 

; [  ]

C1/FCA1: 60           RTS 
C1/FCA2: 8B           PHB 
C1/FCA3: 85 74        STA $74
C1/FCA5: 7B           TDC 
C1/FCA6: 48           PHA 
C1/FCA7: AB           PLB 
C1/FCA8: 8C 16 21     STY $2116
C1/FCAB: 86 72        STX $72
C1/FCAD: A0 00 00     LDY #$0000
C1/FCB0: C2 20        REP #$20
C1/FCB2: A2 08 00     LDX #$0008
C1/FCB5: B7 72        LDA [$72],Y
C1/FCB7: 8D 18 21     STA $2118
C1/FCBA: C8           INY 
C1/FCBB: C8           INY 
C1/FCBC: CA           DEX 
C1/FCBD: D0 F6        BNE $FCB5
C1/FCBF: A2 08 00     LDX #$0008
C1/FCC2: B7 72        LDA [$72],Y
C1/FCC4: 29 FF 00     AND #$00FF
C1/FCC7: 8D 18 21     STA $2118
C1/FCCA: C8           INY 
C1/FCCB: CA           DEX 
C1/FCCC: D0 F4        BNE $FCC2
C1/FCCE: 7B           TDC 
C1/FCCF: E2 20        SEP #$20
C1/FCD1: C6 70        DEC $70
C1/FCD3: D0 DB        BNE $FCB0
C1/FCD5: AB           PLB 
C1/FCD6: 60           RTS 

; [  ]

C1/FCD7: 22 2A DC D0  JSL $D0DC2A
C1/FCDB: 60           RTS 

; [ init battle hdma ]

C1/FCDC: 22 A5 DC D0  JSL $D0DCA5
C1/FCE0: 60           RTS 

; [ move data ]

;  A: source bank
; +X: source address
; +Y: destination address (bank $7E)

C1/FCE1: 8D 4F B4     STA $B44F       ; set source bank
C1/FCE4: 22 48 B4 7E  JSL $7EB448
C1/FCE8: 60           RTS 

; [ init move data subroutine in ram ]

C1/FCE9: A2 00 00     LDX #$0000
C1/FCEC: BF FA FC C1  LDA $C1FCFA,X   ; copy subroutine below into ram
C1/FCF0: 9D 48 B4     STA $B448,X
C1/FCF3: E8           INX 
C1/FCF4: E0 0D 00     CPX #$000D
C1/FCF7: D0 F3        BNE $FCEC
C1/FCF9: 60           RTS 

; [  ]

C1/FCFA: 8B           PHB 
C1/FCFB: C2 20        REP #$20
C1/FCFD: A5 70        LDA $70
C1/FCFF: 54 7E 00     MVN $7E,$00     ; this $00 is at $B44F
C1/FD02: 7B           TDC 
C1/FD03: E2 20        SEP #$20
C1/FD05: AB           PLB 
C1/FD06: 6B           RTL 

; [ go to previous menu ]

C1/FD07: AD 3B CD     LDA $CD3B
C1/FD0A: 8D 3A CD     STA $CD3A
C1/FD0D: AD 3C CD     LDA $CD3C
C1/FD10: 8D 3B CD     STA $CD3B
C1/FD13: AD 3D CD     LDA $CD3D
C1/FD16: 8D 3C CD     STA $CD3C
C1/FD19: 9C 3D CD     STZ $CD3D
C1/FD1C: 60           RTS 

; [ wait for vblank ]

C1/FD1D: 22 AA 7C D9  JSL $D97CAA
C1/FD21: 60           RTS 

; [ clear sprite data ]

C1/FD22: 22 B4 7C D9  JSL $D97CB4
C1/FD26: 60           RTS 

; [  ]

C1/FD27: EE 10 D1     INC $D110
C1/FD2A: DA           PHX 
C1/FD2B: 5A           PHY 
C1/FD2C: 48           PHA 
C1/FD2D: A6 70        LDX $70
C1/FD2F: DA           PHX 
C1/FD30: AD D6 D0     LDA $D0D6
C1/FD33: F0 05        BEQ $FD3A
C1/FD35: 20 F2 02     JSR $02F2       ; wait one frame
C1/FD38: 80 F6        BRA $FD30
C1/FD3A: FA           PLX 
C1/FD3B: 8E DE D0     STX $D0DE
C1/FD3E: 68           PLA 
C1/FD3F: 8D D9 D0     STA $D0D9
C1/FD42: 7A           PLY 
C1/FD43: 8C DA D0     STY $D0DA
C1/FD46: FA           PLX 
C1/FD47: 8E D7 D0     STX $D0D7
C1/FD4A: 9C E0 D0     STZ $D0E0
C1/FD4D: C2 20        REP #$20
C1/FD4F: AD DE D0     LDA $D0DE
C1/FD52: C9 00 08     CMP #$0800
C1/FD55: F0 0A        BEQ $FD61
C1/FD57: 90 08        BCC $FD61
C1/FD59: A9 00 08     LDA #$0800
C1/FD5C: 8D DC D0     STA $D0DC
C1/FD5F: 80 06        BRA $FD67
C1/FD61: 8D DC D0     STA $D0DC
C1/FD64: EE E0 D0     INC $D0E0
C1/FD67: 7B           TDC 
C1/FD68: E2 20        SEP #$20
C1/FD6A: EE D6 D0     INC $D0D6
C1/FD6D: 20 F2 02     JSR $02F2       ; wait one frame
C1/FD70: C2 20        REP #$20
C1/FD72: AD D7 D0     LDA $D0D7
C1/FD75: 18           CLC 
C1/FD76: 69 00 08     ADC #$0800
C1/FD79: 8D D7 D0     STA $D0D7
C1/FD7C: AD DA D0     LDA $D0DA
C1/FD7F: 18           CLC 
C1/FD80: 69 00 04     ADC #$0400
C1/FD83: 8D DA D0     STA $D0DA
C1/FD86: AD DE D0     LDA $D0DE
C1/FD89: 38           SEC 
C1/FD8A: E9 00 08     SBC #$0800
C1/FD8D: 8D DE D0     STA $D0DE
C1/FD90: 7B           TDC 
C1/FD91: E2 20        SEP #$20
C1/FD93: AD E0 D0     LDA $D0E0
C1/FD96: F0 B5        BEQ $FD4D
C1/FD98: 9C 10 D1     STZ $D110
C1/FD9B: 60           RTS 

; [  ]

C1/FD9C: AD D6 D0     LDA $D0D6
C1/FD9F: F0 14        BEQ $FDB5
C1/FDA1: AE DC D0     LDX $D0DC
C1/FDA4: 86 88        STX $88
C1/FDA6: AE D7 D0     LDX $D0D7
C1/FDA9: AC DA D0     LDY $D0DA
C1/FDAC: AD D9 D0     LDA $D0D9
C1/FDAF: 20 B6 FD     JSR $FDB6       ; copy data to vram
C1/FDB2: 9C D6 D0     STZ $D0D6
C1/FDB5: 60           RTS 

; [  ]

C1/FDB6: 22 40 DE D0  JSL $D0DE40     ; copy data to vram (channel 4)
C1/FDBA: 60           RTS 

; [  ]

C1/FDBB: 22 D1 DE D0  JSL $D0DED1     ; clear vram
C1/FDBF: 60           RTS 

; [  ]

C1/FDC0: 22 8C DE D0  JSL $D0DE8C
C1/FDC4: 60           RTS 

; [  ]

C1/FDC5: 22 66 DE D0  JSL $D0DE66     ; copy color palettes to vram
C1/FDC9: 60           RTS 

; [  ]

C1/FDCA: 22 1A DE D0  JSL $D0DE1A     ; copy data to vram (channel 5)
C1/FDCE: 60           RTS 

; [  ]

C1/FDCF: 20 E7 FD     JSR $FDE7
C1/FDD2: 6B           RTL 

; [  ]

C1/FDD3: 20 BA FE     JSR $FEBA       ; +$82 = $7E * $80
C1/FDD6: 6B           RTL 

; [  ]

C1/FDD7: 20 67 FE     JSR $FE67       ; ++$82 = +$7E * +$80
C1/FDDA: 6B           RTL 

; [  ]

C1/FDDB: 20 4B FE     JSR $FE4B
C1/FDDE: 6B           RTL 

; [  ]

C1/FDDF: 20 90 FE     JSR $FE90
C1/FDE2: 6B           RTL 

; [  ]

C1/FDE3: 20 D5 FE     JSR $FED5
C1/FDE6: 6B           RTL 

; [  ]

C1/FDE7: DA           PHX 
C1/FDE8: C2 20        REP #$20
C1/FDEA: 64 82        STZ $82
C1/FDEC: 64 84        STZ $84
C1/FDEE: A5 7E        LDA $7E
C1/FDF0: F0 20        BEQ $FE12
C1/FDF2: A5 80        LDA $80
C1/FDF4: F0 1C        BEQ $FE12
C1/FDF6: A2 10 00     LDX #$0010
C1/FDF9: 26 7E        ROL $7E
C1/FDFB: 26 84        ROL $84
C1/FDFD: A5 84        LDA $84
C1/FDFF: 38           SEC 
C1/FE00: E5 80        SBC $80
C1/FE02: 85 84        STA $84
C1/FE04: B0 07        BCS $FE0D
C1/FE06: A5 84        LDA $84
C1/FE08: 65 80        ADC $80
C1/FE0A: 85 84        STA $84
C1/FE0C: 18           CLC 
C1/FE0D: 26 82        ROL $82
C1/FE0F: CA           DEX 
C1/FE10: D0 E7        BNE $FDF9
C1/FE12: A9 00 00     LDA #$0000
C1/FE15: E2 20        SEP #$20
C1/FE17: FA           PLX 
C1/FE18: 60           RTS 

; [  ]

C1/FE19: DA           PHX 
C1/FE1A: C2 20        REP #$20
C1/FE1C: 64 9C        STZ $9C
C1/FE1E: 64 9E        STZ $9E
C1/FE20: A5 98        LDA $98
C1/FE22: F0 20        BEQ $FE44
C1/FE24: A5 9A        LDA $9A
C1/FE26: F0 1C        BEQ $FE44
C1/FE28: A2 10 00     LDX #$0010
C1/FE2B: 26 98        ROL $98
C1/FE2D: 26 9E        ROL $9E
C1/FE2F: A5 9E        LDA $9E
C1/FE31: 38           SEC 
C1/FE32: E5 9A        SBC $9A
C1/FE34: 85 9E        STA $9E
C1/FE36: B0 07        BCS $FE3F
C1/FE38: A5 9E        LDA $9E
C1/FE3A: 65 9A        ADC $9A
C1/FE3C: 85 9E        STA $9E
C1/FE3E: 18           CLC 
C1/FE3F: 26 9C        ROL $9C
C1/FE41: CA           DEX 
C1/FE42: D0 E7        BNE $FE2B
C1/FE44: A9 00 00     LDA #$0000
C1/FE47: E2 20        SEP #$20
C1/FE49: FA           PLX 
C1/FE4A: 60           RTS 

; [  ]

C1/FE4B: DA           PHX 
C1/FE4C: A2 08 00     LDX #$0008
C1/FE4F: 64 9C        STZ $9C
C1/FE51: 64 9D        STZ $9D
C1/FE53: 66 9A        ROR $9A
C1/FE55: 90 07        BCC $FE5E
C1/FE57: A5 98        LDA $98
C1/FE59: 18           CLC 
C1/FE5A: 65 9D        ADC $9D
C1/FE5C: 85 9D        STA $9D
C1/FE5E: 66 9D        ROR $9D
C1/FE60: 66 9C        ROR $9C
C1/FE62: CA           DEX 
C1/FE63: D0 EE        BNE $FE53
C1/FE65: FA           PLX 
C1/FE66: 60           RTS 

; [ ++$82 = +$7E * +$80 ]

C1/FE67: DA           PHX 
C1/FE68: C2 20        REP #$20
C1/FE6A: 64 86        STZ $86
C1/FE6C: 64 82        STZ $82
C1/FE6E: 64 84        STZ $84
C1/FE70: A2 10 00     LDX #$0010
C1/FE73: 46 7E        LSR $7E
C1/FE75: 90 0D        BCC $FE84
C1/FE77: 18           CLC 
C1/FE78: A5 82        LDA $82
C1/FE7A: 65 80        ADC $80
C1/FE7C: 85 82        STA $82
C1/FE7E: A5 84        LDA $84
C1/FE80: 65 86        ADC $86
C1/FE82: 85 84        STA $84
C1/FE84: 06 80        ASL $80
C1/FE86: 26 86        ROL $86
C1/FE88: CA           DEX 
C1/FE89: D0 E8        BNE $FE73
C1/FE8B: 7B           TDC 
C1/FE8C: E2 20        SEP #$20
C1/FE8E: FA           PLX 
C1/FE8F: 60           RTS 

; [  ]

C1/FE90: DA           PHX 
C1/FE91: C2 20        REP #$20
C1/FE93: 48           PHA 
C1/FE94: 64 A0        STZ $A0
C1/FE96: 64 9C        STZ $9C
C1/FE98: 64 9E        STZ $9E
C1/FE9A: A2 10 00     LDX #$0010
C1/FE9D: 46 98        LSR $98
C1/FE9F: 90 0D        BCC $FEAE
C1/FEA1: 18           CLC 
C1/FEA2: A5 9C        LDA $9C
C1/FEA4: 65 9A        ADC $9A
C1/FEA6: 85 9C        STA $9C
C1/FEA8: A5 9E        LDA $9E
C1/FEAA: 65 A0        ADC $A0
C1/FEAC: 85 9E        STA $9E
C1/FEAE: 06 9A        ASL $9A
C1/FEB0: 26 A0        ROL $A0
C1/FEB2: CA           DEX 
C1/FEB3: D0 E8        BNE $FE9D
C1/FEB5: 68           PLA 
C1/FEB6: E2 20        SEP #$20
C1/FEB8: FA           PLX 
C1/FEB9: 60           RTS 

; [ +$82 = $7E * $80 ]

C1/FEBA: A5 7E        LDA $7E
C1/FEBC: 8F 02 42 00  STA $004202
C1/FEC0: A5 80        LDA $80
C1/FEC2: 8F 03 42 00  STA $004203
C1/FEC6: C2 20        REP #$20
C1/FEC8: EA           NOP 
C1/FEC9: EA           NOP 
C1/FECA: EA           NOP 
C1/FECB: AF 16 42 00  LDA $004216
C1/FECF: 85 82        STA $82
C1/FED1: 7B           TDC 
C1/FED2: E2 20        SEP #$20
C1/FED4: 60           RTS 

; [ +$82 = +$7E / $80 (unused) ]

C1/FED5: A5 7E        LDA $7E
C1/FED7: 8F 04 42 00  STA $004204
C1/FEDB: A5 7F        LDA $7F
C1/FEDD: 8F 05 42 00  STA $004205
C1/FEE1: A5 80        LDA $80
C1/FEE3: 8F 06 42 00  STA $004206
C1/FEE7: C2 20        REP #$20
C1/FEE9: 48           PHA 
C1/FEEA: EA           NOP 
C1/FEEB: 48           PHA 
C1/FEEC: EA           NOP 
C1/FEED: 68           PLA 
C1/FEEE: AF 14 42 00  LDA $004214
C1/FEF2: 85 82        STA $82
C1/FEF4: AF 16 42 00  LDA $004216
C1/FEF8: 85 84        STA $84
C1/FEFA: 68           PLA 
C1/FEFB: E2 20        SEP #$20
C1/FEFD: 60           RTS 

C1/FEFE: A2 00 00     LDX #$0000
C1/FF01: B5 C4        LDA $C4,X
C1/FF03: C5 CE        CMP $CE
C1/FF05: D0 06        BNE $FF0D
C1/FF07: E8           INX 
C1/FF08: E0 07 00     CPX #$0007
C1/FF0B: D0 F4        BNE $FF01
C1/FF0D: 60           RTS 
C1/FF0E: A9 68        LDA #$68
C1/FF10: 80 02        BRA $FF14
C1/FF12: A9 FF        LDA #$FF
C1/FF14: 8D 43 CD     STA $CD43
C1/FF17: DA           PHX 
C1/FF18: 7B           TDC 
C1/FF19: AA           TAX 
C1/FF1A: B5 C4        LDA $C4,X
C1/FF1C: 38           SEC 
C1/FF1D: E5 CE        SBC $CE
C1/FF1F: D0 0B        BNE $FF2C
C1/FF21: AD 43 CD     LDA $CD43
C1/FF24: 95 C4        STA $C4,X
C1/FF26: E8           INX 
C1/FF27: E0 03 00     CPX #$0003
C1/FF2A: D0 EE        BNE $FF1A
C1/FF2C: FA           PLX 
C1/FF2D: 60           RTS 

; [  ]

C1/FF2E: C2 20        REP #$20
C1/FF30: 64 7E        STZ $7E
C1/FF32: 64 80        STZ $80
C1/FF34: 64 82        STZ $82
C1/FF36: 64 84        STZ $84
C1/FF38: 8A           TXA 
C1/FF39: 38           SEC 
C1/FF3A: E9 E8 03     SBC #$03E8
C1/FF3D: 90 05        BCC $FF44
C1/FF3F: E6 7E        INC $7E
C1/FF41: 4C 39 FF     JMP $FF39
C1/FF44: 18           CLC 
C1/FF45: 69 E8 03     ADC #$03E8
C1/FF48: 38           SEC 
C1/FF49: E9 64 00     SBC #$0064
C1/FF4C: 90 05        BCC $FF53
C1/FF4E: E6 80        INC $80
C1/FF50: 4C 48 FF     JMP $FF48
C1/FF53: 18           CLC 
C1/FF54: 69 64 00     ADC #$0064
C1/FF57: 38           SEC 
C1/FF58: E9 0A 00     SBC #$000A
C1/FF5B: 90 05        BCC $FF62
C1/FF5D: E6 82        INC $82
C1/FF5F: 4C 57 FF     JMP $FF57
C1/FF62: 18           CLC 
C1/FF63: 69 0A 00     ADC #$000A
C1/FF66: 85 84        STA $84
C1/FF68: 7B           TDC 
C1/FF69: E2 20        SEP #$20
C1/FF6B: A5 7E        LDA $7E
C1/FF6D: 18           CLC 
C1/FF6E: 65 CE        ADC $CE
C1/FF70: 85 C4        STA $C4
C1/FF72: A5 80        LDA $80
C1/FF74: 18           CLC 
C1/FF75: 65 CE        ADC $CE
C1/FF77: 85 C5        STA $C5
C1/FF79: A5 82        LDA $82
C1/FF7B: 18           CLC 
C1/FF7C: 65 CE        ADC $CE
C1/FF7E: 85 C6        STA $C6
C1/FF80: A5 84        LDA $84
C1/FF82: 18           CLC 
C1/FF83: 65 CE        ADC $CE
C1/FF85: 85 C7        STA $C7
C1/FF87: 60           RTS 

; [ convert hex to decimal digits ]

C1/FF88: 7B           TDC 
C1/FF89: AA           TAX 
C1/FF8A: 95 C4        STA $C4,X
C1/FF8C: E8           INX 
C1/FF8D: E0 08 00     CPX #$0008
C1/FF90: D0 F8        BNE $FF8A
C1/FF92: A2 00 00     LDX #$0000
C1/FF95: DA           PHX 
C1/FF96: 8A           TXA 
C1/FF97: 0A           ASL 
C1/FF98: 0A           ASL 
C1/FF99: AA           TAX 
C1/FF9A: BF 09 7D D9  LDA $D97D09,X   ; hex to decimal conversion constants
C1/FF9E: 85 74        STA $74
C1/FFA0: BF 0A 7D D9  LDA $D97D0A,X
C1/FFA4: 85 75        STA $75
C1/FFA6: BF 0B 7D D9  LDA $D97D0B,X
C1/FFAA: 85 76        STA $76
C1/FFAC: 20 C5 FF     JSR $FFC5
C1/FFAF: FA           PLX 
C1/FFB0: A5 78        LDA $78
C1/FFB2: 18           CLC 
C1/FFB3: 65 CE        ADC $CE
C1/FFB5: 95 C4        STA $C4,X
C1/FFB7: E8           INX 
C1/FFB8: E0 07 00     CPX #$0007
C1/FFBB: D0 D8        BNE $FF95
C1/FFBD: A5 70        LDA $70
C1/FFBF: 18           CLC 
C1/FFC0: 65 CE        ADC $CE
C1/FFC2: 85 CB        STA $CB
C1/FFC4: 60           RTS 

; [  ]

C1/FFC5: 64 78        STZ $78
C1/FFC7: A5 70        LDA $70
C1/FFC9: 38           SEC 
C1/FFCA: E5 74        SBC $74
C1/FFCC: 85 70        STA $70
C1/FFCE: A5 71        LDA $71
C1/FFD0: E5 75        SBC $75
C1/FFD2: 85 71        STA $71
C1/FFD4: A5 72        LDA $72
C1/FFD6: E5 76        SBC $76
C1/FFD8: 85 72        STA $72
C1/FFDA: E6 78        INC $78
C1/FFDC: B0 E9        BCS $FFC7
C1/FFDE: C6 78        DEC $78
C1/FFE0: A5 70        LDA $70
C1/FFE2: 18           CLC 
C1/FFE3: 65 74        ADC $74
C1/FFE5: 85 70        STA $70
C1/FFE7: A5 71        LDA $71
C1/FFE9: 65 75        ADC $75
C1/FFEB: 85 71        STA $71
C1/FFED: A5 72        LDA $72
C1/FFEF: 65 76        ADC $76
C1/FFF1: 85 72        STA $72
C1/FFF3: 60           RTS 

; [ update joypad input ]

C1/FFF4: AD EF 3E     LDA $3EEF       ; no input if credits
C1/FFF7: 30 04        BMI $FFFD
C1/FFF9: 22 06 A0 C2  JSL $C2A006     ; update joypad input
C1/FFFD: 60           RTS 

; unused padding
C1/FFFE:              .DB $00, $00

; =======================================[ battle ]=======================================

; battle
C2/0000: 4C 03 00     JMP $0003

; [ battle ]

C2/0003: 08           PHP 
C2/0004: C2 30        REP #$30
C2/0006: 8B           PHB 
C2/0007: 0B           PHD 
C2/0008: 48           PHA 
C2/0009: DA           PHX 
C2/000A: 5A           PHY 
C2/000B: A9 00 00     LDA #$0000
C2/000E: E2 20        SEP #$20
C2/0010: C2 10        REP #$10
C2/0012: 20 53 00     JSR $0053       ; screen off, disable interrupts
C2/0015: C2 20        REP #$20
C2/0017: 18           CLC 
C2/0018: AD C0 09     LDA $09C0       ; increment battle count
C2/001B: 69 01 00     ADC #$0001
C2/001E: 90 03        BCC $0023
C2/0020: A9 FF FF     LDA #$FFFF
C2/0023: 8D C0 09     STA $09C0
C2/0026: 7B           TDC 
C2/0027: E2 20        SEP #$20
C2/0029: 9C D8 7C     STZ $7CD8       ; clear battle reset
C2/002C: 20 E0 4C     JSR $4CE0       ; init/exec battle
C2/002F: A9 00        LDA #$00
C2/0031: 8F 00 21 00  STA $002100     ; clear screen brightness
C2/0035: 8F 0C 42 00  STA $00420C     ; disable dma and hdma
C2/0039: 8F 0B 42 00  STA $00420B
C2/003D: 8F 00 42 00  STA $004200     ; disable interrupts
C2/0041: AD D8 7C     LDA $7CD8
C2/0044: D0 E6        BNE $002C       ; branch if reset battle
C2/0046: 78           SEI 
C2/0047: 20 53 00     JSR $0053       ; screen off, disable interrupts
C2/004A: C2 30        REP #$30
C2/004C: 7A           PLY 
C2/004D: FA           PLX 
C2/004E: 68           PLA 
C2/004F: 2B           PLD 
C2/0050: AB           PLB 
C2/0051: 28           PLP 
C2/0052: 6B           RTL 

; [ screen off, disable interrupts ]

C2/0053: A9 00        LDA #$00        ; set data bank to $00
C2/0055: 48           PHA 
C2/0056: AB           PLB 
C2/0057: 8D 00 42     STA $4200       ; disable interrupts
C2/005A: A2 00 00     LDX #$0000      ; set direct page to $0000
C2/005D: DA           PHX 
C2/005E: 2B           PLD 
C2/005F: A9 80        LDA #$80
C2/0061: 8D 00 21     STA $2100       ; screen off
C2/0064: A9 7E        LDA #$7E        ; set data bank to $7E
C2/0066: 48           PHA 
C2/0067: AB           PLB 
C2/0068: 60           RTS 

; [ execute battle graphics function ]

C2/0069: 22 00 00 C1  JSL $C10000
C2/006D: 60           RTS 

; [ play song ]

C2/006E: EE B3 DB     INC $DBB3
C2/0071: 8D 00 1D     STA $1D00
C2/0074: 22 04 00 C4  JSL $C40004     ; execute spc interrupt
C2/0078: 9C B3 DB     STZ $DBB3
C2/007B: 60           RTS 

; [ a = (x..a) ]

C2/007C: E2 10        SEP #$10
C2/007E: 86 3C        STX $3C         ; minimum value
C2/0080: E0 FF        CPX #$FF
C2/0082: D0 02        BNE $0086
C2/0084: 80 41        BRA $00C7       ; branch if x = 255
C2/0086: C9 00        CMP #$00
C2/0088: F0 3D        BEQ $00C7       ; branch if a = 0
C2/008A: C5 3C        CMP $3C
C2/008C: F0 39        BEQ $00C7       ; branch if x = a
C2/008E: 48           PHA             ; maximum value
C2/008F: 7B           TDC 
C2/0090: AA           TAX 
C2/0091: AD 55 7C     LDA $7C55       ; toggle random number pointer
C2/0094: 49 01        EOR #$01
C2/0096: 8D 55 7C     STA $7C55
C2/0099: AA           TAX 
C2/009A: B5 3A        LDA $3A,X       ; random number pointer
C2/009C: AA           TAX 
C2/009D: 68           PLA 
C2/009E: 38           SEC 
C2/009F: E5 3C        SBC $3C         ; a = max - min
C2/00A1: C9 FF        CMP #$FF
C2/00A3: D0 06        BNE $00AB
C2/00A5: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C2/00A9: 80 1C        BRA $00C7
C2/00AB: 1A           INC 
C2/00AC: 8D B9 7C     STA $7CB9       ; +$7CB9 = max - min + 1
C2/00AF: 9C BA 7C     STZ $7CBA
C2/00B2: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
C2/00B6: AA           TAX 
C2/00B7: 8E B7 7C     STX $7CB7
C2/00BA: C2 10        REP #$10
C2/00BC: 20 0C 01     JSR $010C       ; +$7CBB = +$7CB7 / +$7CB9, R -> +$7CBD
C2/00BF: E2 10        SEP #$10
C2/00C1: 18           CLC 
C2/00C2: AD BD 7C     LDA $7CBD
C2/00C5: 65 3C        ADC $3C         ; a = rand % (max - min + 1) + min
C2/00C7: 48           PHA 
C2/00C8: AD 55 7C     LDA $7C55
C2/00CB: AA           TAX 
C2/00CC: F6 3A        INC $3A,X
C2/00CE: C2 10        REP #$10
C2/00D0: 68           PLA 
C2/00D1: 60           RTS 

; [ +++$2E = +$2A * +$2C ]

C2/00D2: C2 20        REP #$20
C2/00D4: A2 10 00     LDX #$0010
C2/00D7: 64 2E        STZ $2E
C2/00D9: 64 30        STZ $30
C2/00DB: 66 2C        ROR $2C
C2/00DD: 90 07        BCC $00E6
C2/00DF: 18           CLC 
C2/00E0: A5 2A        LDA $2A
C2/00E2: 65 30        ADC $30
C2/00E4: 85 30        STA $30
C2/00E6: 66 30        ROR $30
C2/00E8: 66 2E        ROR $2E
C2/00EA: CA           DEX 
C2/00EB: D0 EE        BNE $00DB
C2/00ED: 7B           TDC 
C2/00EE: E2 20        SEP #$20
C2/00F0: 60           RTS 

; [ +$26 = $24 * $25 ]

C2/00F1: A5 24        LDA $24
C2/00F3: 8F 02 42 00  STA $004202
C2/00F7: A5 25        LDA $25
C2/00F9: 8F 03 42 00  STA $004203
C2/00FD: C2 20        REP #$20
C2/00FF: EA           NOP 
C2/0100: EA           NOP 
C2/0101: EA           NOP 
C2/0102: AF 16 42 00  LDA $004216
C2/0106: 85 26        STA $26
C2/0108: 7B           TDC 
C2/0109: E2 20        SEP #$20
C2/010B: 60           RTS 

; [ +$7CBB = +$7CB7 / +$7CB9, R -> +$7CBD ]

C2/010C: C2 20        REP #$20
C2/010E: 9C BB 7C     STZ $7CBB
C2/0111: 9C BD 7C     STZ $7CBD
C2/0114: AD B7 7C     LDA $7CB7
C2/0117: F0 2B        BEQ $0144
C2/0119: AD B9 7C     LDA $7CB9
C2/011C: F0 26        BEQ $0144
C2/011E: 18           CLC 
C2/011F: A2 10 00     LDX #$0010
C2/0122: 2E B7 7C     ROL $7CB7
C2/0125: 2E BD 7C     ROL $7CBD
C2/0128: 38           SEC 
C2/0129: AD BD 7C     LDA $7CBD
C2/012C: ED B9 7C     SBC $7CB9
C2/012F: 8D BD 7C     STA $7CBD
C2/0132: B0 0A        BCS $013E
C2/0134: AD BD 7C     LDA $7CBD
C2/0137: 6D B9 7C     ADC $7CB9
C2/013A: 8D BD 7C     STA $7CBD
C2/013D: 18           CLC 
C2/013E: 2E BB 7C     ROL $7CBB
C2/0141: CA           DEX 
C2/0142: D0 DE        BNE $0122
C2/0144: 7B           TDC 
C2/0145: E2 20        SEP #$20
C2/0147: 60           RTS 

C2/0148: .byte $20,$20,$20,$20,$20,$BA,$C9,$20
C2/0150: .byte $BB,$B8,$CB,$DD,$20,$A6,$20,$BB
C2/0158: .byte $B2,$B1,$B2,$C5,$D9,$20,$B5,$C4
C2/0160: .byte $B3,$C4,$20,$CB,$B8,$DE,$C1,$20
C2/0168: .byte $C0,$B6,$C9,$D8,$20,$C6,$20,$BB
C2/0170: .byte $BB,$B9,$DE,$D9,$20,$20,$20,$C8
C2/0178: .byte $B6,$DE,$DC,$B8,$CA,$DE,$20,$BF
C2/0180: .byte $C9,$20,$C0,$CF,$BC,$B2,$20,$C9
C2/0188: .byte $20,$D4,$BD,$D7,$B6,$20,$C5,$D7
C2/0190: .byte $DD,$20,$BA,$C4,$20,$A6,$20,$20
C2/0198: .byte $20,$31,$39,$39,$32,$20,$32,$2E
C2/01A0: .byte $31,$33,$20,$CB,$B8,$DE,$C1,$20
C2/01A8: .byte $B6,$C2,$CB,$BB,$20,$20,$20,$20
C2/01B0: .byte $20

; [ a << n ]

C2/01B1: 0A           ASL 
C2/01B2: 0A           ASL 
C2/01B3: 0A           ASL 
C2/01B4: 0A           ASL 
C2/01B5: 0A           ASL 
C2/01B6: 0A           ASL 
C2/01B7: 0A           ASL 
C2/01B8: 0A           ASL 
C2/01B9: 60           RTS 

; [ a >> n ]

C2/01BA: 4A           LSR 
C2/01BB: 4A           LSR 
C2/01BC: 4A           LSR 
C2/01BD: 4A           LSR 
C2/01BE: 4A           LSR 
C2/01BF: 4A           LSR 
C2/01C0: 4A           LSR 
C2/01C1: 4A           LSR 
C2/01C2: 60           RTS 

; [ count set bits ]

C2/01C3: A2 00 00     LDX #$0000
C2/01C6: A0 08 00     LDY #$0008
C2/01C9: 0A           ASL 
C2/01CA: 90 01        BCC $01CD
C2/01CC: E8           INX 
C2/01CD: 88           DEY 
C2/01CE: D0 F9        BNE $01C9
C2/01D0: 60           RTS 

; [ clear bit x ]

C2/01D1: 3F DE EC D0  AND $D0ECDE,X   ; inverse bit masks
C2/01D5: 60           RTS 

; [ set bit x ]

C2/01D6: 1F E6 EC D0  ORA $D0ECE6,X   ; bit masks
C2/01DA: 60           RTS 

; [ check bit x ]

C2/01DB: 3F E6 EC D0  AND $D0ECE6,X   ; bit masks
C2/01DF: 60           RTS 

; [ increment pointer to character/monster properties ]

C2/01E0: C2 20        REP #$20
C2/01E2: 18           CLC 
C2/01E3: 8A           TXA 
C2/01E4: 69 80 00     ADC #$0080
C2/01E7: AA           TAX 
C2/01E8: 7B           TDC 
C2/01E9: E2 20        SEP #$20
C2/01EB: 60           RTS 

; [ get pointer to character/monster properties ]

; a: character/monster index

C2/01EC: C2 20        REP #$20
C2/01EE: 20 B2 01     JSR $01B2       ; a << 7
C2/01F1: AA           TAX 
C2/01F2: 7B           TDC 
C2/01F3: E2 20        SEP #$20
C2/01F5: 86 32        STX $32
C2/01F7: 60           RTS 

; [ get spell list offset ]

; a: character index

C2/01F8: 0A           ASL 
C2/01F9: AA           TAX 
C2/01FA: C2 20        REP #$20
C2/01FC: BF 59 ED D0  LDA $D0ED59,X   ; spell list offsets
C2/0200: 85 34        STA $34
C2/0202: A8           TAY 
C2/0203: 7B           TDC 
C2/0204: E2 20        SEP #$20
C2/0206: 60           RTS 

; [ get timer data offset ]

; a: character/monster index

C2/0207: DA           PHX 
C2/0208: 0A           ASL 
C2/0209: AA           TAX 
C2/020A: C2 20        REP #$20
C2/020C: BF 61 ED D0  LDA $D0ED61,X   ; timer data offsets
C2/0210: 85 36        STA $36
C2/0212: A8           TAY 
C2/0213: 7B           TDC 
C2/0214: E2 20        SEP #$20
C2/0216: FA           PLX 
C2/0217: 60           RTS 

; [ reset battle graphics parameters ]

C2/0218: A2 90 00     LDX #$0090
C2/021B: 9E CC 3B     STZ $3BCC,X     ; reset attack parameters
C2/021E: CA           DEX 
C2/021F: 10 FA        BPL $021B
C2/0221: 8A           TXA 
C2/0222: A2 7F 03     LDX #$037F
C2/0225: 9D 4C 38     STA $384C,X     ; reset animation commands (set to $FF)
C2/0228: CA           DEX 
C2/0229: 10 FA        BPL $0225
C2/022B: A2 5F 00     LDX #$005F
C2/022E: 9D 5F 3C     STA $3C5F,X     ; 
C2/0231: CA           DEX 
C2/0232: 10 FA        BPL $022E
C2/0234: 7B           TDC 
C2/0235: A2 0F 00     LDX #$000F
C2/0238: 9E 49 7B     STZ $7B49,X     ; 
C2/023B: CA           DEX 
C2/023C: 10 FA        BPL $0238
C2/023E: A2 2F 00     LDX #$002F
C2/0241: 9E BF 3C     STZ $3CBF,X     ; 
C2/0244: CA           DEX 
C2/0245: 10 FA        BPL $0241
C2/0247: 60           RTS 

; [ get attacker stats and level modified by song effects ]

C2/0248: DA           PHX 
C2/0249: 5A           PHY 
C2/024A: 7B           TDC 
C2/024B: A8           TAY 
C2/024C: 18           CLC 
C2/024D: BD 28 20     LDA $2028,X     ; attacker stats
C2/0250: 7D 74 20     ADC $2074,X     ; add stat modifier
C2/0253: C9 64        CMP #$64
C2/0255: 90 02        BCC $0259
C2/0257: A9 63        LDA #$63        ; max 99
C2/0259: 99 E1 7B     STA $7BE1,Y
C2/025C: E8           INX 
C2/025D: C8           INY 
C2/025E: C0 04 00     CPY #$0004
C2/0261: D0 E9        BNE $024C
C2/0263: 7A           PLY 
C2/0264: FA           PLX 
C2/0265: 18           CLC 
C2/0266: BD 02 20     LDA $2002,X     ; attacker level
C2/0269: 7D 78 20     ADC $2078,X     ; add level modifier
C2/026C: C9 64        CMP #$64
C2/026E: 90 02        BCC $0272
C2/0270: A9 63        LDA #$63        ; max 99
C2/0272: 8D E5 7B     STA $7BE5
C2/0275: 60           RTS 

; [  ]

C2/0276: AA           TAX 
C2/0277: BF 79 ED D0  LDA $D0ED79,X
C2/027B: 0A           ASL 
C2/027C: AA           TAX 
C2/027D: AD 5D 3C     LDA $3C5D
C2/0280: 9D 4C 3A     STA $3A4C,X
C2/0283: AD 5E 3C     LDA $3C5E
C2/0286: 9D 4D 3A     STA $3A4D,X
C2/0289: 60           RTS 

; [  ]

C2/028A: 9C 48 00     STZ $0048
C2/028D: A2 33 01     LDX #$0133
C2/0290: 9E F9 79     STZ $79F9,X
C2/0293: CA           DEX 
C2/0294: 10 FA        BPL $0290
C2/0296: 8A           TXA 
C2/0297: A2 10 00     LDX #$0010
C2/029A: 9D 2D 7B     STA $7B2D,X
C2/029D: CA           DEX 
C2/029E: 10 FA        BPL $029A
C2/02A0: 7B           TDC 
C2/02A1: 60           RTS 

; [ a = (0..99) ]

C2/02A2: 7B           TDC 
C2/02A3: AA           TAX 
C2/02A4: A9 63        LDA #$63
C2/02A6: 4C 7C 00     JMP $007C       ; a = (x..a)

; [  ]

C2/02A9: A5 65        LDA $65
C2/02AB: 48           PHA 
C2/02AC: 29 F0        AND #$F0
C2/02AE: 4A           LSR 
C2/02AF: 4A           LSR 
C2/02B0: 4A           LSR 
C2/02B1: 4A           LSR 
C2/02B2: 05 66        ORA $66
C2/02B4: 8D 20 27     STA $2720
C2/02B7: 68           PLA 
C2/02B8: 29 0F        AND #$0F
C2/02BA: 0A           ASL 
C2/02BB: 0A           ASL 
C2/02BC: 0A           ASL 
C2/02BD: 0A           ASL 
C2/02BE: 8D 21 27     STA $2721
C2/02C1: 60           RTS 

; [  ]

C2/02C2: A5 65        LDA $65
C2/02C4: 05 66        ORA $66
C2/02C6: 20 C3 01     JSR $01C3       ; count set bits
C2/02C9: CA           DEX 
C2/02CA: 8A           TXA 
C2/02CB: 8D A0 26     STA $26A0
C2/02CE: 60           RTS 

; [  ]

C2/02CF: 9C 29 7C     STZ $7C29
C2/02D2: 7B           TDC 
C2/02D3: AA           TAX 
C2/02D4: 86 0E        STX $0E
C2/02D6: BD C2 3E     LDA $3EC2,X
C2/02D9: F0 10        BEQ $02EB
C2/02DB: A4 0E        LDY $0E
C2/02DD: B9 1A 20     LDA $201A,Y
C2/02E0: 29 C0        AND #$C0
C2/02E2: D0 07        BNE $02EB
C2/02E4: B9 1D 20     LDA $201D,Y
C2/02E7: 29 81        AND #$81
C2/02E9: F0 1C        BEQ $0307
C2/02EB: DA           PHX 
C2/02EC: E0 04 00     CPX #$0004
C2/02EF: B0 09        BCS $02FA
C2/02F1: A5 66        LDA $66
C2/02F3: 20 D1 01     JSR $01D1       ; clear bit x
C2/02F6: 85 66        STA $66
C2/02F8: 80 0C        BRA $0306
C2/02FA: 8A           TXA 
C2/02FB: 38           SEC 
C2/02FC: E9 04        SBC #$04
C2/02FE: AA           TAX 
C2/02FF: A5 65        LDA $65
C2/0301: 20 D1 01     JSR $01D1       ; clear bit x
C2/0304: 85 65        STA $65
C2/0306: FA           PLX 
C2/0307: C2 20        REP #$20
C2/0309: 18           CLC 
C2/030A: A5 0E        LDA $0E
C2/030C: 69 80 00     ADC #$0080
C2/030F: 85 0E        STA $0E
C2/0311: 7B           TDC 
C2/0312: E2 20        SEP #$20
C2/0314: E8           INX 
C2/0315: E0 0C 00     CPX #$000C
C2/0318: D0 BC        BNE $02D6
C2/031A: A5 66        LDA $66
C2/031C: 05 65        ORA $65
C2/031E: D0 03        BNE $0323
C2/0320: EE 29 7C     INC $7C29
C2/0323: 60           RTS 

; [  ]

C2/0324: C2 20        REP #$20
C2/0326: 20 B6 01     JSR $01B6       ; a << 3
C2/0329: AA           TAX 
C2/032A: 7B           TDC 
C2/032B: E2 20        SEP #$20
C2/032D: 64 3D        STZ $3D
C2/032F: BF 80 0B D1  LDA $D10B80,X   ; attack properties
C2/0333: 99 FC 79     STA $79FC,Y
C2/0336: E8           INX 
C2/0337: C8           INY 
C2/0338: E6 3D        INC $3D
C2/033A: A5 3D        LDA $3D
C2/033C: C9 05        CMP #$05        ; copy first 5 bytes
C2/033E: D0 EF        BNE $032F
C2/0340: C8           INY             ; skip 4 bytes
C2/0341: C8           INY 
C2/0342: C8           INY 
C2/0343: C8           INY 
C2/0344: BF 80 0B D1  LDA $D10B80,X   ; attack properties
C2/0348: 99 FC 79     STA $79FC,Y
C2/034B: E8           INX 
C2/034C: C8           INY 
C2/034D: E6 3D        INC $3D
C2/034F: A5 3D        LDA $3D
C2/0351: C9 08        CMP #$08        ; copy last 3 bytes
C2/0353: D0 EF        BNE $0344
C2/0355: 60           RTS 

; [  ]

C2/0356: 18           CLC 
C2/0357: AD EF 3C     LDA $3CEF
C2/035A: 69 18        ADC #$18
C2/035C: 8D EF 3C     STA $3CEF
C2/035F: 18           CLC 
C2/0360: AD F0 3C     LDA $3CF0
C2/0363: 69 0C        ADC #$0C
C2/0365: 8D F0 3C     STA $3CF0
C2/0368: 60           RTS 

; [  ]

C2/0369: B9 20 26     LDA $2620,Y
C2/036C: 10 05        BPL $0373
C2/036E: A9 AA        LDA #$AA
C2/0370: 4C F9 03     JMP $03F9
C2/0373: 29 40        AND #$40
C2/0375: F0 0F        BEQ $0386
C2/0377: B9 34 2B     LDA $2B34,Y
C2/037A: 29 20        AND #$20
C2/037C: F0 04        BEQ $0382
C2/037E: A9 AA        LDA #$AA
C2/0380: 80 77        BRA $03F9
C2/0382: A9 00        LDA #$00
C2/0384: 80 73        BRA $03F9
C2/0386: B9 20 26     LDA $2620,Y
C2/0389: 0A           ASL 
C2/038A: 0A           ASL 
C2/038B: AA           TAX 
C2/038C: 7B           TDC 
C2/038D: A8           TAY 
C2/038E: BF 80 24 D1  LDA $D12480,X   ; item equipment types
C2/0392: 99 20 27     STA $2720,Y
C2/0395: E8           INX 
C2/0396: C8           INY 
C2/0397: C0 04 00     CPY #$0004
C2/039A: D0 F2        BNE $038E
C2/039C: 7B           TDC 
C2/039D: AA           TAX 
C2/039E: A8           TAY 
C2/039F: A9 AA        LDA #$AA
C2/03A1: 85 0E        STA $0E
C2/03A3: BD 99 41     LDA $4199,X
C2/03A6: 39 20 27     AND $2720,Y
C2/03A9: D0 18        BNE $03C3
C2/03AB: BD 9A 41     LDA $419A,X
C2/03AE: 39 21 27     AND $2721,Y
C2/03B1: D0 10        BNE $03C3
C2/03B3: BD 9B 41     LDA $419B,X
C2/03B6: 39 22 27     AND $2722,Y
C2/03B9: D0 08        BNE $03C3
C2/03BB: BD 9C 41     LDA $419C,X
C2/03BE: 39 23 27     AND $2723,Y
C2/03C1: F0 2B        BEQ $03EE
C2/03C3: 8A           TXA 
C2/03C4: 4A           LSR 
C2/03C5: 4A           LSR 
C2/03C6: D0 08        BNE $03D0
C2/03C8: A5 0E        LDA $0E
C2/03CA: 29 7F        AND #$7F
C2/03CC: 85 0E        STA $0E
C2/03CE: 80 1E        BRA $03EE
C2/03D0: C9 01        CMP #$01
C2/03D2: D0 08        BNE $03DC
C2/03D4: A5 0E        LDA $0E
C2/03D6: 29 DF        AND #$DF
C2/03D8: 85 0E        STA $0E
C2/03DA: 80 12        BRA $03EE
C2/03DC: C9 02        CMP #$02
C2/03DE: D0 08        BNE $03E8
C2/03E0: A5 0E        LDA $0E
C2/03E2: 29 F7        AND #$F7
C2/03E4: 85 0E        STA $0E
C2/03E6: 80 06        BRA $03EE
C2/03E8: A5 0E        LDA $0E
C2/03EA: 29 FD        AND #$FD
C2/03EC: 85 0E        STA $0E
C2/03EE: E8           INX 
C2/03EF: E8           INX 
C2/03F0: E8           INX 
C2/03F1: E8           INX 
C2/03F2: E0 10 00     CPX #$0010
C2/03F5: D0 AC        BNE $03A3
C2/03F7: A5 0E        LDA $0E
C2/03F9: 60           RTS 

; [  ]

C2/03FA: F0 31        BEQ $042D       ; branch if slot is empty
C2/03FC: C9 E0        CMP #$E0
C2/03FE: B0 71        BCS $0471       ; branch if a useable item
C2/0400: C9 80        CMP #$80
C2/0402: 90 35        BCC $0439

; armor
C2/0404: 38           SEC 
C2/0405: E9 80        SBC #$80
C2/0407: C2 20        REP #$20
C2/0409: 0A           ASL 
C2/040A: 0A           ASL 
C2/040B: 85 0E        STA $0E
C2/040D: 0A           ASL 
C2/040E: 18           CLC 
C2/040F: 65 0E        ADC $0E
C2/0411: AA           TAX 
C2/0412: 7B           TDC 
C2/0413: E2 20        SEP #$20
C2/0415: BF 00 06 D1  LDA $D10600,X
C2/0419: 29 08        AND #$08
C2/041B: F0 10        BEQ $042D
C2/041D: BF 02 06 D1  LDA $D10602,X
C2/0421: 29 3F        AND #$3F
C2/0423: 99 20 26     STA $2620,Y
C2/0426: A9 5A        LDA #$5A
C2/0428: 99 34 2B     STA $2B34,Y
C2/042B: 80 63        BRA $0490
C2/042D: A9 80        LDA #$80
C2/042F: 99 20 26     STA $2620,Y
C2/0432: A9 5A        LDA #$5A
C2/0434: 99 34 2B     STA $2B34,Y
C2/0437: 80 57        BRA $0490

; weapon
C2/0439: C2 20        REP #$20
C2/043B: 0A           ASL             ; multiply by 12
C2/043C: 0A           ASL 
C2/043D: 85 0E        STA $0E
C2/043F: 0A           ASL 
C2/0440: 18           CLC 
C2/0441: 65 0E        ADC $0E
C2/0443: AA           TAX 
C2/0444: 7B           TDC 
C2/0445: E2 20        SEP #$20
C2/0447: BF 04 00 D1  LDA $D10004,X   ; double grip flag
C2/044B: 29 80        AND #$80
C2/044D: 20 BD 01     JSR $01BD       ; a >> 5
C2/0450: 99 34 2B     STA $2B34,Y
C2/0453: BF 00 00 D1  LDA $D10000,X   ; item targeting
C2/0457: 99 34 2A     STA $2A34,Y
C2/045A: BF 02 00 D1  LDA $D10002,X   ; item usability (throw/break)
C2/045E: 48           PHA 
C2/045F: 29 C0        AND #$C0
C2/0461: 09 1A        ORA #$1A
C2/0463: 19 34 2B     ORA $2B34,Y
C2/0466: 99 34 2B     STA $2B34,Y
C2/0469: 68           PLA 
C2/046A: 29 3F        AND #$3F
C2/046C: 99 20 26     STA $2620,Y
C2/046F: 80 1F        BRA $0490
C2/0471: 38           SEC 
C2/0472: E9 E0        SBC #$E0
C2/0474: C2 20        REP #$20
C2/0476: 0A           ASL 
C2/0477: 0A           ASL 
C2/0478: 0A           ASL 
C2/0479: AA           TAX 
C2/047A: 7B           TDC 
C2/047B: E2 20        SEP #$20
C2/047D: BF 80 0A D1  LDA $D10A80,X
C2/0481: 99 34 2A     STA $2A34,Y
C2/0484: BF 82 0A D1  LDA $D10A82,X
C2/0488: 99 34 2B     STA $2B34,Y
C2/048B: A9 40        LDA #$40
C2/048D: 99 20 26     STA $2620,Y
C2/0490: 60           RTS 

; [  ]

C2/0491: A2 0F 00     LDX #$000F
C2/0494: 74 0E        STZ $0E,X
C2/0496: CA           DEX 
C2/0497: 10 FB        BPL $0494
C2/0499: A2 64 00     LDX #$0064
C2/049C: 86 12        STX $12
C2/049E: A6 2E        LDX $2E
C2/04A0: 86 0E        STX $0E
C2/04A2: A5 30        LDA $30
C2/04A4: 85 10        STA $10
C2/04A6: C2 20        REP #$20
C2/04A8: 18           CLC 
C2/04A9: A2 20 00     LDX #$0020
C2/04AC: 26 0E        ROL $0E
C2/04AE: 26 10        ROL $10
C2/04B0: 26 1A        ROL $1A
C2/04B2: 26 1C        ROL $1C
C2/04B4: 38           SEC 
C2/04B5: A5 1A        LDA $1A
C2/04B7: E5 12        SBC $12
C2/04B9: 85 1A        STA $1A
C2/04BB: A5 1C        LDA $1C
C2/04BD: E5 14        SBC $14
C2/04BF: 85 1C        STA $1C
C2/04C1: B0 0D        BCS $04D0
C2/04C3: A5 1A        LDA $1A
C2/04C5: 65 12        ADC $12
C2/04C7: 85 1A        STA $1A
C2/04C9: A5 1C        LDA $1C
C2/04CB: 65 14        ADC $14
C2/04CD: 85 1C        STA $1C
C2/04CF: 18           CLC 
C2/04D0: 26 16        ROL $16
C2/04D2: 26 18        ROL $18
C2/04D4: CA           DEX 
C2/04D5: D0 D5        BNE $04AC
C2/04D7: 7B           TDC 
C2/04D8: E2 20        SEP #$20
C2/04DA: 18           CLC 
C2/04DB: A5 16        LDA $16
C2/04DD: 65 08        ADC $08
C2/04DF: 85 08        STA $08
C2/04E1: A5 17        LDA $17
C2/04E3: 65 09        ADC $09
C2/04E5: 85 09        STA $09
C2/04E7: 38           SEC 
C2/04E8: A5 08        LDA $08
C2/04EA: E5 0A        SBC $0A
C2/04EC: A5 09        LDA $09
C2/04EE: E5 0B        SBC $0B
C2/04F0: 90 08        BCC $04FA
C2/04F2: A5 0A        LDA $0A
C2/04F4: 85 08        STA $08
C2/04F6: A5 0B        LDA $0B
C2/04F8: 85 09        STA $09
C2/04FA: 60           RTS 

; [  ]

C2/04FB: 20 E1 16     JSR $16E1
C2/04FE: AD FA 79     LDA $79FA
C2/0501: AA           TAX 
C2/0502: 9E 2D 7B     STZ $7B2D,X
C2/0505: 9E 1C 7B     STZ $7B1C,X
C2/0508: 9E CC 7A     STZ $7ACC,X
C2/050B: EE FB 7B     INC $7BFB
C2/050E: 4C 50 17     JMP $1750

; [ battle command $01/$24: other ]

C2/0511: A5 47        LDA $47
C2/0513: C9 04        CMP #$04
C2/0515: 90 24        BCC $053B
C2/0517: 38           SEC 
C2/0518: E9 04        SBC #$04
C2/051A: 0A           ASL 
C2/051B: AA           TAX 
C2/051C: BF 95 EE D0  LDA $D0EE95,X
C2/0520: 85 0E        STA $0E
C2/0522: BF 96 EE D0  LDA $D0EE96,X
C2/0526: 85 0F        STA $0F
C2/0528: 7B           TDC 
C2/0529: A8           TAY 
C2/052A: A6 0E        LDX $0E
C2/052C: BD 67 43     LDA $4367,X
C2/052F: 99 4C 38     STA $384C,Y
C2/0532: E8           INX 
C2/0533: C8           INY 
C2/0534: C0 64 00     CPY #$0064
C2/0537: D0 F3        BNE $052C
C2/0539: 80 12        BRA $054D
C2/053B: 20 FA 98     JSR $98FA       ; create graphics command
C2/053E: 9E 4C 38     STZ $384C,X
C2/0541: 9E 4D 38     STZ $384D,X
C2/0544: 9E 4E 38     STZ $384E,X
C2/0547: 9E 4F 38     STZ $384F,X
C2/054A: 9E 50 38     STZ $3850,X
C2/054D: AD FA 79     LDA $79FA
C2/0550: AA           TAX 
C2/0551: A9 7E        LDA #$7E
C2/0553: 9D 2D 7B     STA $7B2D,X
C2/0556: 9E 1C 7B     STZ $7B1C,X
C2/0559: 9E CC 7A     STZ $7ACC,X
C2/055C: EE FB 7B     INC $7BFB
C2/055F: AD FA 79     LDA $79FA
C2/0562: 0A           ASL 
C2/0563: AA           TAX 
C2/0564: A9 80        LDA #$80
C2/0566: 9D DC 7A     STA $7ADC,X
C2/0569: 9E DD 7A     STZ $7ADD,X
C2/056C: EE FA 79     INC $79FA
C2/056F: 60           RTS 

; [ battle command $02/$20: item/mix ]

C2/0570: 9C 62 7C     STZ $7C62
C2/0573: 20 23 99     JSR $9923
C2/0576: 20 5F 17     JSR $175F
C2/0579: A6 32        LDX $32
C2/057B: BD 56 20     LDA $2056,X
C2/057E: 29 10        AND #$10
C2/0580: F0 03        BEQ $0585
C2/0582: 4C 32 06     JMP $0632
C2/0585: BD 5A 20     LDA $205A,X
C2/0588: C9 EF        CMP #$EF
C2/058A: D0 06        BNE $0592
C2/058C: 20 67 07     JSR $0767
C2/058F: 4C 43 0E     JMP $0E43
C2/0592: 8D 22 27     STA $2722
C2/0595: 38           SEC 
C2/0596: E9 E0        SBC #$E0
C2/0598: C2 20        REP #$20
C2/059A: 20 B6 01     JSR $01B6       ; a << 3
C2/059D: AA           TAX 
C2/059E: 7B           TDC 
C2/059F: E2 20        SEP #$20
C2/05A1: A4 0C        LDY $0C
C2/05A3: 64 0A        STZ $0A
C2/05A5: BF 80 0A D1  LDA $D10A80,X   ; useable item properties
C2/05A9: 99 FC 79     STA $79FC,Y
C2/05AC: E8           INX 
C2/05AD: C8           INY 
C2/05AE: E6 0A        INC $0A
C2/05B0: A5 0A        LDA $0A
C2/05B2: C9 05        CMP #$05        ; copy first 5 bytes
C2/05B4: D0 EF        BNE $05A5
C2/05B6: C8           INY             ; skip 4 bytes
C2/05B7: C8           INY 
C2/05B8: C8           INY 
C2/05B9: C8           INY 
C2/05BA: BF 80 0A D1  LDA $D10A80,X   ; useable item properties
C2/05BE: 99 FC 79     STA $79FC,Y
C2/05C1: E8           INX 
C2/05C2: C8           INY 
C2/05C3: E6 0A        INC $0A
C2/05C5: A5 0A        LDA $0A
C2/05C7: C9 08        CMP #$08        ; copy last 3 bytes
C2/05C9: D0 EF        BNE $05BA
C2/05CB: 20 C2 02     JSR $02C2
C2/05CE: D0 13        BNE $05E3
C2/05D0: A4 0C        LDY $0C
C2/05D2: B9 00 7A     LDA $7A00,Y
C2/05D5: 10 09        BPL $05E0
C2/05D7: AD FA 79     LDA $79FA
C2/05DA: AA           TAX 
C2/05DB: FE EB 7B     INC $7BEB,X
C2/05DE: 80 03        BRA $05E3
C2/05E0: 20 FE 4A     JSR $4AFE
C2/05E3: 20 A9 02     JSR $02A9
C2/05E6: AD 22 27     LDA $2722
C2/05E9: 8D 21 26     STA $2621
C2/05EC: A9 04        LDA #$04
C2/05EE: 8D 20 26     STA $2620
C2/05F1: 20 2F 99     JSR $992F
C2/05F4: 20 FA 98     JSR $98FA       ; create graphics command
C2/05F7: 9E 4C 38     STZ $384C,X
C2/05FA: A9 FC        LDA #$FC
C2/05FC: 9D 4D 38     STA $384D,X
C2/05FF: A9 09        LDA #$09
C2/0601: 9D 4E 38     STA $384E,X
C2/0604: AD 22 27     LDA $2722
C2/0607: 9D 4F 38     STA $384F,X
C2/060A: 9E 50 38     STZ $3850,X
C2/060D: A4 0C        LDY $0C
C2/060F: AD FA 79     LDA $79FA
C2/0612: AA           TAX 
C2/0613: B9 00 7A     LDA $7A00,Y
C2/0616: 29 7F        AND #$7F
C2/0618: 9D 2D 7B     STA $7B2D,X
C2/061B: AD A0 26     LDA $26A0
C2/061E: 9D 1C 7B     STA $7B1C,X
C2/0621: F0 05        BEQ $0628
C2/0623: FE 1C 7B     INC $7B1C,X
C2/0626: A9 80        LDA #$80
C2/0628: 9D CC 7A     STA $7ACC,X
C2/062B: 20 35 17     JSR $1735
C2/062E: 20 E3 98     JSR $98E3
C2/0631: 60           RTS 

; [  ]

C2/0632: 64 45        STZ $45
C2/0634: A5 47        LDA $47
C2/0636: AA           TAX 
C2/0637: BF 85 ED D0  LDA $D0ED85,X
C2/063B: A8           TAY 
C2/063C: A6 32        LDX $32
C2/063E: BD 5A 20     LDA $205A,X
C2/0641: D0 0F        BNE $0652
C2/0643: BD 13 20     LDA $2013,X
C2/0646: 9D 5A 20     STA $205A,X
C2/0649: 8D 62 7C     STA $7C62
C2/064C: AA           TAX 
C2/064D: B9 8B 40     LDA $408B,Y
C2/0650: 80 0F        BRA $0661
C2/0652: E6 45        INC $45
C2/0654: BD 14 20     LDA $2014,X
C2/0657: 9D 5A 20     STA $205A,X
C2/065A: 8D 62 7C     STA $7C62
C2/065D: AA           TAX 
C2/065E: B9 97 40     LDA $4097,Y
C2/0661: 85 46        STA $46
C2/0663: 29 7F        AND #$7F
C2/0665: 9B           TXY 
C2/0666: 48           PHA 
C2/0667: 48           PHA 
C2/0668: AD FA 79     LDA $79FA
C2/066B: AA           TAX 
C2/066C: 68           PLA 
C2/066D: 9D 2D 7B     STA $7B2D,X
C2/0670: 98           TYA 
C2/0671: 8D 21 26     STA $2621
C2/0674: A9 04        LDA #$04
C2/0676: 8D 20 26     STA $2620
C2/0679: 20 2F 99     JSR $992F
C2/067C: AD FA 79     LDA $79FA
C2/067F: AA           TAX 
C2/0680: BD 2D 7B     LDA $7B2D,X
C2/0683: A4 0C        LDY $0C
C2/0685: 20 24 03     JSR $0324
C2/0688: 20 C2 02     JSR $02C2
C2/068B: D0 13        BNE $06A0
C2/068D: A4 0C        LDY $0C
C2/068F: B9 00 7A     LDA $7A00,Y
C2/0692: 10 09        BPL $069D
C2/0694: AD FA 79     LDA $79FA
C2/0697: AA           TAX 
C2/0698: FE EB 7B     INC $7BEB,X
C2/069B: 80 03        BRA $06A0
C2/069D: 20 FE 4A     JSR $4AFE
C2/06A0: 20 A9 02     JSR $02A9
C2/06A3: 20 FA 98     JSR $98FA       ; create graphics command
C2/06A6: 9E 4C 38     STZ $384C,X
C2/06A9: A9 FC        LDA #$FC
C2/06AB: 9D 4D 38     STA $384D,X
C2/06AE: A9 0A        LDA #$0A
C2/06B0: 9D 4E 38     STA $384E,X
C2/06B3: 68           PLA 
C2/06B4: 9D 4F 38     STA $384F,X
C2/06B7: 9E 50 38     STZ $3850,X
C2/06BA: AD FA 79     LDA $79FA
C2/06BD: AA           TAX 
C2/06BE: BD 2D 7B     LDA $7B2D,X
C2/06C1: 10 03        BPL $06C6
C2/06C3: 7B           TDC 
C2/06C4: 80 07        BRA $06CD
C2/06C6: A4 0C        LDY $0C
C2/06C8: B9 00 7A     LDA $7A00,Y
C2/06CB: 29 7F        AND #$7F
C2/06CD: 9D 2D 7B     STA $7B2D,X
C2/06D0: AD A0 26     LDA $26A0
C2/06D3: 9D 1C 7B     STA $7B1C,X
C2/06D6: F0 05        BEQ $06DD
C2/06D8: FE 1C 7B     INC $7B1C,X
C2/06DB: A9 80        LDA #$80
C2/06DD: 9D CC 7A     STA $7ACC,X
C2/06E0: 20 35 17     JSR $1735
C2/06E3: 20 E3 98     JSR $98E3
C2/06E6: A5 46        LDA $46
C2/06E8: 10 7C        BPL $0766
C2/06EA: A5 47        LDA $47
C2/06EC: 20 B7 01     JSR $01B7       ; a << 2
C2/06EF: 85 0E        STA $0E
C2/06F1: 0A           ASL 
C2/06F2: 18           CLC 
C2/06F3: 65 0E        ADC $0E
C2/06F5: A8           TAY 
C2/06F6: A5 45        LDA $45
C2/06F8: D0 1B        BNE $0715
C2/06FA: 7B           TDC 
C2/06FB: 99 AC 37     STA $37AC,Y
C2/06FE: 99 AE 37     STA $37AE,Y
C2/0701: 99 B0 37     STA $37B0,Y
C2/0704: A9 38        LDA #$38
C2/0706: 99 B2 37     STA $37B2,Y
C2/0709: A9 5A        LDA #$5A
C2/070B: 99 B4 37     STA $37B4,Y
C2/070E: A9 AA        LDA #$AA
C2/0710: 99 B6 37     STA $37B6,Y
C2/0713: 80 19        BRA $072E
C2/0715: 7B           TDC 
C2/0716: 99 AD 37     STA $37AD,Y
C2/0719: 99 AF 37     STA $37AF,Y
C2/071C: 99 B1 37     STA $37B1,Y
C2/071F: A9 38        LDA #$38
C2/0721: 99 B3 37     STA $37B3,Y
C2/0724: A9 5A        LDA #$5A
C2/0726: 99 B5 37     STA $37B5,Y
C2/0729: A9 AA        LDA #$AA
C2/072B: 99 B7 37     STA $37B7,Y
C2/072E: AD EF 3C     LDA $3CEF
C2/0731: A8           TAY 
C2/0732: A9 50        LDA #$50
C2/0734: 99 5F 3C     STA $3C5F,Y
C2/0737: AD EF 3C     LDA $3CEF
C2/073A: 85 0E        STA $0E
C2/073C: 0A           ASL 
C2/073D: 18           CLC 
C2/073E: 65 0E        ADC $0E
C2/0740: AA           TAX 
C2/0741: AD 62 7C     LDA $7C62
C2/0744: 9D BF 3C     STA $3CBF,X
C2/0747: 9E C0 3C     STZ $3CC0,X
C2/074A: 9E C1 3C     STZ $3CC1,X
C2/074D: 20 4C 99     JSR $994C
C2/0750: AD CC 41     LDA $41CC
C2/0753: 48           PHA 
C2/0754: A5 47        LDA $47
C2/0756: 8D CC 41     STA $41CC
C2/0759: 8D 7B 7B     STA $7B7B
C2/075C: 20 3A 9F     JSR $9F3A
C2/075F: 68           PLA 
C2/0760: 8D CC 41     STA $41CC
C2/0763: 20 6F 9A     JSR $9A6F       ; update character equipment
C2/0766: 60           RTS 
C2/0767: AD 74 7C     LDA $7C74       ; magic lamp spell
C2/076A: C9 0D        CMP #$0D
C2/076C: 90 0A        BCC $0778
C2/076E: C9 20        CMP #$20
C2/0770: B0 04        BCS $0776
C2/0772: A9 0D        LDA #$0D
C2/0774: 80 02        BRA $0778
C2/0776: A9 0E        LDA #$0E
C2/0778: AA           TAX 
C2/0779: BF E7 EE D0  LDA $D0EEE7,X
C2/077D: 8D 22 27     STA $2722
C2/0780: 9C 23 27     STZ $2723
C2/0783: 18           CLC 
C2/0784: AD 74 7C     LDA $7C74
C2/0787: 69 01        ADC #$01
C2/0789: 90 02        BCC $078D
C2/078B: A9 FF        LDA #$FF
C2/078D: 8D 74 7C     STA $7C74
C2/0790: 60           RTS 

; [ battle command $03: row ]

C2/0791: A9 03        LDA #$03
C2/0793: 20 AA 16     JSR $16AA
C2/0796: EE FB 7B     INC $7BFB
C2/0799: A9 02        LDA #$02
C2/079B: 20 E1 16     JSR $16E1
C2/079E: 20 05 17     JSR $1705
C2/07A1: 4C 50 17     JMP $1750

; [ battle command $04: def ]

C2/07A4: A9 03        LDA #$03
C2/07A6: 4C FB 04     JMP $04FB

; [ battle command $06: guard ]

C2/07A9: A9 05        LDA #$05
C2/07AB: 4C FB 04     JMP $04FB

; [ battle command $07: kick ]

C2/07AE: A9 07        LDA #$07
C2/07B0: 20 AA 16     JSR $16AA
C2/07B3: 20 5F 17     JSR $175F
C2/07B6: 20 A9 02     JSR $02A9
C2/07B9: 20 C2 02     JSR $02C2
C2/07BC: A9 07        LDA #$07
C2/07BE: 20 FA 16     JSR $16FA
C2/07C1: A9 06        LDA #$06
C2/07C3: 20 E1 16     JSR $16E1
C2/07C6: 20 1A 17     JSR $171A
C2/07C9: 20 35 17     JSR $1735
C2/07CC: 4C E3 98     JMP $98E3

; [ battle command $08: buildup ]

C2/07CF: A9 08        LDA #$08
C2/07D1: 20 FA 16     JSR $16FA
C2/07D4: A9 07        LDA #$07
C2/07D6: 20 E1 16     JSR $16E1
C2/07D9: AD FA 79     LDA $79FA
C2/07DC: AA           TAX 
C2/07DD: 9E 2D 7B     STZ $7B2D,X
C2/07E0: 9E 1C 7B     STZ $7B1C,X
C2/07E3: 9E CC 7A     STZ $7ACC,X
C2/07E6: 20 50 17     JSR $1750
C2/07E9: A6 32        LDX $32
C2/07EB: A9 4E        LDA #$4E
C2/07ED: 9D 57 20     STA $2057,X
C2/07F0: A9 10        LDA #$10
C2/07F2: 9D 1F 20     STA $201F,X
C2/07F5: A9 4E        LDA #$4E
C2/07F7: AA           TAX 
C2/07F8: BF A0 5D D1  LDA $D15DA0,X
C2/07FC: 48           PHA 
C2/07FD: A5 47        LDA $47
C2/07FF: 20 07 02     JSR $0207       ; get timer data offset
C2/0802: A6 32        LDX $32         ; attacker properties offset
C2/0804: 68           PLA 
C2/0805: 20 63 61     JSR $6163
C2/0808: 99 7F 3D     STA $3D7F,Y
C2/080B: A9 41        LDA #$41
C2/080D: 99 FB 3C     STA $3CFB,Y
C2/0810: EE FC 7B     INC $7BFC
C2/0813: 60           RTS 

; [ battle command $2D:  ]

C2/0814: 20 5F 17     JSR $175F       ; get cursor targets
C2/0817: 20 FE 4A     JSR $4AFE       ; validate targets
C2/081A: A6 32        LDX $32
C2/081C: A5 66        LDA $66
C2/081E: 9D 59 20     STA $2059,X     ; set targets
C2/0821: A5 65        LDA $65
C2/0823: 9D 58 20     STA $2058,X
C2/0826: 20 A9 02     JSR $02A9       ; 
C2/0829: A5 47        LDA $47         ; attacker index
C2/082B: AA           TAX 
C2/082C: BF 85 ED D0  LDA $D0ED85,X   ; character item data offset
C2/0830: AA           TAX 
C2/0831: 86 0E        STX $0E
C2/0833: A6 32        LDX $32
C2/0835: BD 13 20     LDA $2013,X     ; right hand weapon
C2/0838: D0 03        BNE $083D
C2/083A: 4C 9D 08     JMP $089D       ; skip right hand, go to left hand
C2/083D: 20 23 99     JSR $9923
C2/0840: 84 14        STY $14
C2/0842: 64 12        STZ $12
C2/0844: A6 0E        LDX $0E
C2/0846: BD 85 40     LDA $4085,X     ; copy item properties (12 bytes)
C2/0849: 99 FC 79     STA $79FC,Y
C2/084C: E8           INX 
C2/084D: C8           INY 
C2/084E: E6 12        INC $12
C2/0850: A5 12        LDA $12
C2/0852: C9 0C        CMP #$0C
C2/0854: D0 F0        BNE $0846
C2/0856: A6 0E        LDX $0E
C2/0858: BD 8A 40     LDA $408A,X     ; spellblade flag ???
C2/085B: 29 04        AND #$04
C2/085D: D0 03        BNE $0862
C2/085F: 7B           TDC 
C2/0860: 80 07        BRA $0869
C2/0862: A6 32        LDX $32
C2/0864: BD 7A 20     LDA $207A,X     ; spellblade spell ???
C2/0867: 29 7F        AND #$7F
C2/0869: 48           PHA 
C2/086A: 20 FA 98     JSR $98FA       ; create graphics command
C2/086D: 9E 4C 38     STZ $384C,X
C2/0870: A9 FC        LDA #$FC
C2/0872: 9D 4D 38     STA $384D,X
C2/0875: A9 01        LDA #$01
C2/0877: 9D 4E 38     STA $384E,X
C2/087A: A9 04        LDA #$04
C2/087C: 9D 4F 38     STA $384F,X
C2/087F: 68           PLA 
C2/0880: 9D 50 38     STA $3850,X
C2/0883: A6 0E        LDX $0E
C2/0885: BD 8D 40     LDA $408D,X     ; attack effect
C2/0888: 48           PHA 
C2/0889: AD FA 79     LDA $79FA
C2/088C: AA           TAX 
C2/088D: 68           PLA 
C2/088E: 9D 2D 7B     STA $7B2D,X
C2/0891: 9E 1C 7B     STZ $7B1C,X
C2/0894: 9E CC 7A     STZ $7ACC,X
C2/0897: 20 35 17     JSR $1735
C2/089A: 20 E3 98     JSR $98E3
C2/089D: A6 32        LDX $32
C2/089F: BD 14 20     LDA $2014,X     ; left hand weapon
C2/08A2: D0 01        BNE $08A5
C2/08A4: 60           RTS 
C2/08A5: 20 23 99     JSR $9923
C2/08A8: 84 12        STY $12
C2/08AA: 64 14        STZ $14
C2/08AC: A6 0E        LDX $0E
C2/08AE: BD 91 40     LDA $4091,X     ; copy item properties
C2/08B1: 99 FC 79     STA $79FC,Y
C2/08B4: E8           INX 
C2/08B5: C8           INY 
C2/08B6: E6 14        INC $14
C2/08B8: A5 14        LDA $14
C2/08BA: C9 0C        CMP #$0C
C2/08BC: D0 F0        BNE $08AE
C2/08BE: A6 0E        LDX $0E
C2/08C0: AD FA 79     LDA $79FA       ; current action id
C2/08C3: A8           TAY 
C2/08C4: BD 99 40     LDA $4099,X
C2/08C7: 99 2D 7B     STA $7B2D,Y
C2/08CA: 20 FA 98     JSR $98FA       ; create graphics command
C2/08CD: 9E 4C 38     STZ $384C,X
C2/08D0: A9 FC        LDA #$FC
C2/08D2: 9D 4D 38     STA $384D,X
C2/08D5: A9 01        LDA #$01
C2/08D7: 9D 4E 38     STA $384E,X
C2/08DA: A9 04        LDA #$04
C2/08DC: 9D 4F 38     STA $384F,X
C2/08DF: 86 08        STX $08
C2/08E1: A6 0E        LDX $0E
C2/08E3: BD 96 40     LDA $4096,X
C2/08E6: 29 04        AND #$04
C2/08E8: D0 04        BNE $08EE
C2/08EA: A9 80        LDA #$80
C2/08EC: 80 07        BRA $08F5
C2/08EE: A6 32        LDX $32
C2/08F0: BD 7A 20     LDA $207A,X
C2/08F3: 09 80        ORA #$80
C2/08F5: A6 08        LDX $08
C2/08F7: 9D 50 38     STA $3850,X
C2/08FA: AD FA 79     LDA $79FA
C2/08FD: AA           TAX 
C2/08FE: 9E 1C 7B     STZ $7B1C,X
C2/0901: 9E CC 7A     STZ $7ACC,X
C2/0904: 20 35 17     JSR $1735
C2/0907: 20 E3 98     JSR $98E3
C2/090A: 60           RTS 

; [ battle command $09: mantra ]

C2/090B: A9 09        LDA #$09
C2/090D: 20 AA 16     JSR $16AA
C2/0910: A9 09        LDA #$09
C2/0912: 20 FA 16     JSR $16FA
C2/0915: A9 08        LDA #$08
C2/0917: 20 E1 16     JSR $16E1
C2/091A: 20 05 17     JSR $1705
C2/091D: 20 50 17     JSR $1750
C2/0920: AD FA 79     LDA $79FA
C2/0923: AA           TAX 
C2/0924: 9E 2D 7B     STZ $7B2D,X
C2/0927: 9E 1C 7B     STZ $7B1C,X
C2/092A: 9E CC 7A     STZ $7ACC,X
C2/092D: 20 50 17     JSR $1750
C2/0930: 4C E3 98     JMP $98E3

; [ battle command $0A: escape ]

C2/0933: A9 0A        LDA #$0A
C2/0935: 20 AA 16     JSR $16AA       ; get battle command properties
C2/0938: EE FB 7B     INC $7BFB       ;
C2/093B: A9 0A        LDA #$0A
C2/093D: 20 FA 16     JSR $16FA       ; 
C2/0940: A9 09        LDA #$09
C2/0942: 20 E1 16     JSR $16E1
C2/0945: 20 05 17     JSR $1705
C2/0948: 20 50 17     JSR $1750
C2/094B: 4C 4C 99     JMP $994C

; [ battle command $0B: steal ]

C2/094E: A9 0B        LDA #$0B
C2/0950: 20 AA 16     JSR $16AA
C2/0953: 20 5F 17     JSR $175F
C2/0956: 20 FE 4A     JSR $4AFE
C2/0959: 20 A9 02     JSR $02A9
C2/095C: A9 0B        LDA #$0B
C2/095E: 20 FA 16     JSR $16FA
C2/0961: A9 0A        LDA #$0A
C2/0963: 20 E1 16     JSR $16E1
C2/0966: 20 05 17     JSR $1705
C2/0969: 20 35 17     JSR $1735
C2/096C: 4C 4C 99     JMP $994C

; [ battle command $0C: capture ]

C2/096F: 9C FA 79     STZ $79FA
C2/0972: 9C F9 79     STZ $79F9
C2/0975: A9 0C        LDA #$0C
C2/0977: 20 FA 16     JSR $16FA
C2/097A: 20 14 08     JSR $0814
C2/097D: A9 0B        LDA #$0B
C2/097F: 20 AA 16     JSR $16AA
C2/0982: A9 0A        LDA #$0A
C2/0984: 20 E1 16     JSR $16E1
C2/0987: 20 05 17     JSR $1705
C2/098A: 20 35 17     JSR $1735
C2/098D: 4C 4C 99     JMP $994C

; [ battle command $0D: jump ]

C2/0990: A9 0D        LDA #$0D
C2/0992: 20 FA 16     JSR $16FA
C2/0995: A9 0C        LDA #$0C
C2/0997: 20 E1 16     JSR $16E1
C2/099A: AD FA 79     LDA $79FA
C2/099D: AA           TAX 
C2/099E: 9E 2D 7B     STZ $7B2D,X
C2/09A1: 9E 1C 7B     STZ $7B1C,X
C2/09A4: 9E CC 7A     STZ $7ACC,X
C2/09A7: 20 50 17     JSR $1750
C2/09AA: EE FB 7B     INC $7BFB
C2/09AD: A6 32        LDX $32
C2/09AF: A9 4F        LDA #$4F
C2/09B1: 9D 57 20     STA $2057,X
C2/09B4: A9 10        LDA #$10
C2/09B6: 9D 1E 20     STA $201E,X
C2/09B9: A9 80        LDA #$80
C2/09BB: 9D 1F 20     STA $201F,X
C2/09BE: A9 4F        LDA #$4F
C2/09C0: AA           TAX 
C2/09C1: BF A0 5D D1  LDA $D15DA0,X
C2/09C5: 48           PHA 
C2/09C6: A5 47        LDA $47
C2/09C8: 20 07 02     JSR $0207       ; get timer data offset
C2/09CB: A6 32        LDX $32
C2/09CD: 68           PLA 
C2/09CE: 20 63 61     JSR $6163
C2/09D1: 99 7F 3D     STA $3D7F,Y
C2/09D4: A9 41        LDA #$41
C2/09D6: 99 FB 3C     STA $3CFB,Y
C2/09D9: EE FC 7B     INC $7BFC
C2/09DC: 60           RTS 

; [ battle command $2E:  ]

C2/09DD: A9 2D        LDA #$2D
C2/09DF: 20 E1 16     JSR $16E1
C2/09E2: 20 5F 17     JSR $175F
C2/09E5: 20 FE 4A     JSR $4AFE
C2/09E8: A6 32        LDX $32
C2/09EA: A5 66        LDA $66
C2/09EC: 9D 59 20     STA $2059,X
C2/09EF: A5 65        LDA $65
C2/09F1: 9D 58 20     STA $2058,X
C2/09F4: 20 A9 02     JSR $02A9
C2/09F7: A5 47        LDA $47
C2/09F9: AA           TAX 
C2/09FA: BF 85 ED D0  LDA $D0ED85,X
C2/09FE: AA           TAX 
C2/09FF: 86 0E        STX $0E
C2/0A01: A6 32        LDX $32
C2/0A03: BD 13 20     LDA $2013,X
C2/0A06: D0 03        BNE $0A0B
C2/0A08: 4C 3C 0A     JMP $0A3C
C2/0A0B: 20 23 99     JSR $9923
C2/0A0E: 64 12        STZ $12
C2/0A10: A6 0E        LDX $0E
C2/0A12: BD 85 40     LDA $4085,X     ; right hand weapon
C2/0A15: 99 FC 79     STA $79FC,Y
C2/0A18: E8           INX 
C2/0A19: C8           INY 
C2/0A1A: E6 12        INC $12
C2/0A1C: A5 12        LDA $12
C2/0A1E: C9 0C        CMP #$0C
C2/0A20: D0 F0        BNE $0A12
C2/0A22: A6 0E        LDX $0E
C2/0A24: BD 8D 40     LDA $408D,X
C2/0A27: 48           PHA 
C2/0A28: AD FA 79     LDA $79FA
C2/0A2B: AA           TAX 
C2/0A2C: 68           PLA 
C2/0A2D: 9D 2D 7B     STA $7B2D,X
C2/0A30: 9E 1C 7B     STZ $7B1C,X
C2/0A33: 9E CC 7A     STZ $7ACC,X
C2/0A36: 20 35 17     JSR $1735
C2/0A39: 20 E3 98     JSR $98E3
C2/0A3C: A6 32        LDX $32
C2/0A3E: BD 14 20     LDA $2014,X
C2/0A41: D0 03        BNE $0A46
C2/0A43: 4C 79 0A     JMP $0A79
C2/0A46: 20 23 99     JSR $9923
C2/0A49: 64 12        STZ $12
C2/0A4B: A6 0E        LDX $0E
C2/0A4D: BD 91 40     LDA $4091,X     ; left hand weapon
C2/0A50: 99 FC 79     STA $79FC,Y
C2/0A53: E8           INX 
C2/0A54: C8           INY 
C2/0A55: E6 12        INC $12
C2/0A57: A5 12        LDA $12
C2/0A59: C9 0C        CMP #$0C
C2/0A5B: D0 F0        BNE $0A4D
C2/0A5D: A6 0E        LDX $0E
C2/0A5F: AD FA 79     LDA $79FA
C2/0A62: A8           TAY 
C2/0A63: BD 99 40     LDA $4099,X
C2/0A66: 99 2D 7B     STA $7B2D,Y
C2/0A69: AD FA 79     LDA $79FA
C2/0A6C: AA           TAX 
C2/0A6D: 9E 1C 7B     STZ $7B1C,X
C2/0A70: 9E CC 7A     STZ $7ACC,X
C2/0A73: 20 35 17     JSR $1735
C2/0A76: 20 E3 98     JSR $98E3
C2/0A79: EE FB 7B     INC $7BFB
C2/0A7C: 60           RTS 

; [ battle command $2F:  ]

C2/0A7D: A9 50        LDA #$50
C2/0A7F: 20 AA 16     JSR $16AA
C2/0A82: 20 5F 17     JSR $175F
C2/0A85: 20 FE 4A     JSR $4AFE
C2/0A88: 64 65        STZ $65
C2/0A8A: A5 47        LDA $47
C2/0A8C: AA           TAX 
C2/0A8D: 7B           TDC 
C2/0A8E: 20 D6 01     JSR $01D6       ; set bit x
C2/0A91: 85 66        STA $66
C2/0A93: 20 A9 02     JSR $02A9
C2/0A96: EE FB 7B     INC $7BFB
C2/0A99: A9 2E        LDA #$2E
C2/0A9B: 20 E1 16     JSR $16E1
C2/0A9E: 20 05 17     JSR $1705
C2/0AA1: 4C 35 17     JMP $1735

; [ battle command $0E: dragon sword ]

C2/0AA4: 20 5F 17     JSR $175F
C2/0AA7: 20 FE 4A     JSR $4AFE
C2/0AAA: 20 A9 02     JSR $02A9
C2/0AAD: 20 C2 02     JSR $02C2
C2/0AB0: A9 0E        LDA #$0E
C2/0AB2: 20 FA 16     JSR $16FA
C2/0AB5: A9 0D        LDA #$0D
C2/0AB7: 20 E1 16     JSR $16E1
C2/0ABA: 20 23 99     JSR $9923
C2/0ABD: A9 71        LDA #$71
C2/0ABF: 20 24 03     JSR $0324
C2/0AC2: 20 05 17     JSR $1705
C2/0AC5: 20 35 17     JSR $1735
C2/0AC8: 20 E3 98     JSR $98E3
C2/0ACB: 20 23 99     JSR $9923
C2/0ACE: A9 72        LDA #$72
C2/0AD0: 20 24 03     JSR $0324
C2/0AD3: 20 05 17     JSR $1705
C2/0AD6: 20 35 17     JSR $1735
C2/0AD9: 4C E3 98     JMP $98E3

; [ battle command $0F: smoke ]

C2/0ADC: A9 0F        LDA #$0F
C2/0ADE: 20 AA 16     JSR $16AA
C2/0AE1: 20 5F 17     JSR $175F
C2/0AE4: 20 A9 02     JSR $02A9
C2/0AE7: 20 C2 02     JSR $02C2
C2/0AEA: A9 0F        LDA #$0F
C2/0AEC: 20 FA 16     JSR $16FA
C2/0AEF: A9 0E        LDA #$0E
C2/0AF1: 20 E1 16     JSR $16E1
C2/0AF4: 20 1A 17     JSR $171A
C2/0AF7: 4C 35 17     JMP $1735

; [ battle command $10: image ]

C2/0AFA: A9 10        LDA #$10
C2/0AFC: 20 AA 16     JSR $16AA
C2/0AFF: A9 10        LDA #$10
C2/0B01: 20 FA 16     JSR $16FA
C2/0B04: A9 0F        LDA #$0F
C2/0B06: 20 E1 16     JSR $16E1
C2/0B09: 20 05 17     JSR $1705
C2/0B0C: 4C 50 17     JMP $1750

; [ battle command $11: throw ]

C2/0B0F: A6 32        LDX $32
C2/0B11: BD 5A 20     LDA $205A,X
C2/0B14: 10 38        BPL $0B4E
C2/0B16: 7B           TDC 
C2/0B17: AA           TAX 
C2/0B18: 64 0E        STZ $0E
C2/0B1A: BD C6 3E     LDA $3EC6,X
C2/0B1D: F0 07        BEQ $0B26
C2/0B1F: A5 0E        LDA $0E
C2/0B21: 20 D6 01     JSR $01D6       ; set bit x
C2/0B24: 85 0E        STA $0E
C2/0B26: E8           INX 
C2/0B27: E0 08 00     CPX #$0008
C2/0B2A: D0 EE        BNE $0B1A
C2/0B2C: A6 32        LDX $32
C2/0B2E: A5 0E        LDA $0E
C2/0B30: 9D 58 20     STA $2058,X
C2/0B33: AD F1 04     LDA $04F1
C2/0B36: F0 0E        BEQ $0B46
C2/0B38: AD F0 04     LDA $04F0
C2/0B3B: C9 BF        CMP #$BF
C2/0B3D: D0 07        BNE $0B46
C2/0B3F: A5 0E        LDA $0E
C2/0B41: 29 FC        AND #$FC
C2/0B43: 9D 58 20     STA $2058,X
C2/0B46: A9 40        LDA #$40
C2/0B48: 9D 56 20     STA $2056,X
C2/0B4B: 4C 70 05     JMP $0570
C2/0B4E: A9 11        LDA #$11
C2/0B50: 20 AA 16     JSR $16AA
C2/0B53: 20 5F 17     JSR $175F
C2/0B56: 20 FE 4A     JSR $4AFE
C2/0B59: 20 A9 02     JSR $02A9
C2/0B5C: A9 11        LDA #$11
C2/0B5E: 20 FA 16     JSR $16FA
C2/0B61: A9 10        LDA #$10
C2/0B63: 20 E1 16     JSR $16E1
C2/0B66: 20 05 17     JSR $1705
C2/0B69: 20 35 17     JSR $1735
C2/0B6C: 4C E3 98     JMP $98E3

; [ battle command $12: sword slap ]

C2/0B6F: A9 12        LDA #$12
C2/0B71: 20 FA 16     JSR $16FA
C2/0B74: EE FD 7B     INC $7BFD
C2/0B77: 4C FF 45     JMP $45FF

; [ battle command $13: gil toss ]

C2/0B7A: A9 13        LDA #$13
C2/0B7C: 20 AA 16     JSR $16AA
C2/0B7F: 20 5F 17     JSR $175F
C2/0B82: 20 A9 02     JSR $02A9
C2/0B85: 20 C2 02     JSR $02C2
C2/0B88: A9 13        LDA #$13
C2/0B8A: 20 FA 16     JSR $16FA
C2/0B8D: A9 12        LDA #$12
C2/0B8F: 20 E1 16     JSR $16E1
C2/0B92: 20 1A 17     JSR $171A
C2/0B95: 20 35 17     JSR $1735
C2/0B98: 4C E3 98     JMP $98E3

; [ battle command $14: slash ]

C2/0B9B: A9 14        LDA #$14
C2/0B9D: 20 AA 16     JSR $16AA
C2/0BA0: 20 5F 17     JSR $175F
C2/0BA3: 20 A9 02     JSR $02A9
C2/0BA6: 20 C2 02     JSR $02C2
C2/0BA9: EE FB 7B     INC $7BFB
C2/0BAC: A9 14        LDA #$14
C2/0BAE: 20 FA 16     JSR $16FA
C2/0BB1: A9 13        LDA #$13
C2/0BB3: 20 E1 16     JSR $16E1
C2/0BB6: 20 1A 17     JSR $171A
C2/0BB9: 20 35 17     JSR $1735
C2/0BBC: 4C E3 98     JMP $98E3

; [ battle command $15: animals ]

C2/0BBF: 7B           TDC 
C2/0BC0: AA           TAX 
C2/0BC1: AD E5 7B     LDA $7BE5       ; attacker level
C2/0BC4: 20 7C 00     JSR $007C       ; a = (x..a)
C2/0BC7: D0 03        BNE $0BCC
C2/0BC9: 7B           TDC 
C2/0BCA: 80 3A        BRA $0C06
C2/0BCC: C9 05        CMP #$05
C2/0BCE: B0 04        BCS $0BD4
C2/0BD0: A9 01        LDA #$01
C2/0BD2: 80 32        BRA $0C06
C2/0BD4: C9 0A        CMP #$0A
C2/0BD6: B0 04        BCS $0BDC
C2/0BD8: A9 02        LDA #$02
C2/0BDA: 80 2A        BRA $0C06
C2/0BDC: C9 14        CMP #$14
C2/0BDE: B0 04        BCS $0BE4
C2/0BE0: A9 03        LDA #$03
C2/0BE2: 80 22        BRA $0C06
C2/0BE4: C9 1E        CMP #$1E
C2/0BE6: B0 04        BCS $0BEC
C2/0BE8: A9 04        LDA #$04
C2/0BEA: 80 1A        BRA $0C06
C2/0BEC: C9 28        CMP #$28
C2/0BEE: B0 04        BCS $0BF4
C2/0BF0: A9 05        LDA #$05
C2/0BF2: 80 12        BRA $0C06
C2/0BF4: C9 32        CMP #$32
C2/0BF6: B0 04        BCS $0BFC
C2/0BF8: A9 06        LDA #$06
C2/0BFA: 80 0A        BRA $0C06
C2/0BFC: C9 3C        CMP #$3C
C2/0BFE: B0 04        BCS $0C04
C2/0C00: A9 07        LDA #$07
C2/0C02: 80 02        BRA $0C06
C2/0C04: A9 08        LDA #$08
C2/0C06: 8D 22 27     STA $2722       ; parameter 2
C2/0C09: C2 20        REP #$20
C2/0C0B: 20 B6 01     JSR $01B6       ; a << 3
C2/0C0E: AA           TAX 
C2/0C0F: 7B           TDC 
C2/0C10: E2 20        SEP #$20
C2/0C12: 7B           TDC 
C2/0C13: A8           TAY 
C2/0C14: BF B1 6A D1  LDA $D16AB1,X
C2/0C18: 99 20 26     STA $2620,Y
C2/0C1B: E8           INX 
C2/0C1C: C8           INY 
C2/0C1D: C0 08 00     CPY #$0008
C2/0C20: D0 F2        BNE $0C14
C2/0C22: 64 66        STZ $66
C2/0C24: 64 65        STZ $65
C2/0C26: AD 20 26     LDA $2620
C2/0C29: D0 0B        BNE $0C36
C2/0C2B: A5 47        LDA $47
C2/0C2D: AA           TAX 
C2/0C2E: 7B           TDC 
C2/0C2F: 20 D6 01     JSR $01D6       ; set bit x
C2/0C32: 85 66        STA $66
C2/0C34: 80 25        BRA $0C5B
C2/0C36: 29 08        AND #$08
C2/0C38: D0 06        BNE $0C40
C2/0C3A: A9 F0        LDA #$F0
C2/0C3C: 85 66        STA $66
C2/0C3E: 80 1B        BRA $0C5B
C2/0C40: AD 20 26     LDA $2620
C2/0C43: 29 40        AND #$40
C2/0C45: D0 10        BNE $0C57
C2/0C47: 7B           TDC 
C2/0C48: AA           TAX 
C2/0C49: A9 07        LDA #$07
C2/0C4B: 20 7C 00     JSR $007C       ; a = (x..a)
C2/0C4E: AA           TAX 
C2/0C4F: 7B           TDC 
C2/0C50: 20 D6 01     JSR $01D6       ; set bit x
C2/0C53: 85 65        STA $65
C2/0C55: 80 04        BRA $0C5B
C2/0C57: A9 FF        LDA #$FF
C2/0C59: 85 65        STA $65
C2/0C5B: 64 20        STZ $20
C2/0C5D: 64 21        STZ $21
C2/0C5F: A9 01        LDA #$01
C2/0C61: 8D 23 27     STA $2723
C2/0C64: 4C E1 5C     JMP $5CE1

; [ battle command $16: aim ]

C2/0C67: A9 16        LDA #$16
C2/0C69: 20 FA 16     JSR $16FA
C2/0C6C: 4C FF 45     JMP $45FF

; [ battle command $17: x-fight ]

C2/0C6F: A9 17        LDA #$17
C2/0C71: 20 FA 16     JSR $16FA
C2/0C74: 64 22        STZ $22
C2/0C76: 7B           TDC 
C2/0C77: AA           TAX 
C2/0C78: A9 07        LDA #$07
C2/0C7A: 20 7C 00     JSR $007C       ; a = (x..a)
C2/0C7D: AA           TAX 
C2/0C7E: 7B           TDC 
C2/0C7F: 20 D6 01     JSR $01D6       ; set bit x
C2/0C82: A6 32        LDX $32
C2/0C84: 9D 58 20     STA $2058,X
C2/0C87: 9E 59 20     STZ $2059,X
C2/0C8A: A6 32        LDX $32
C2/0C8C: BD 58 20     LDA $2058,X
C2/0C8F: 85 65        STA $65
C2/0C91: BD 59 20     LDA $2059,X
C2/0C94: 85 66        STA $66
C2/0C96: 20 FE 4A     JSR $4AFE
C2/0C99: A6 32        LDX $32
C2/0C9B: A5 66        LDA $66
C2/0C9D: 9D 59 20     STA $2059,X
C2/0CA0: A5 65        LDA $65
C2/0CA2: 9D 58 20     STA $2058,X
C2/0CA5: 48           PHA 
C2/0CA6: 29 F0        AND #$F0
C2/0CA8: 4A           LSR 
C2/0CA9: 4A           LSR 
C2/0CAA: 4A           LSR 
C2/0CAB: 4A           LSR 
C2/0CAC: 1D 59 20     ORA $2059,X
C2/0CAF: 8D 20 27     STA $2720
C2/0CB2: 68           PLA 
C2/0CB3: 29 0F        AND #$0F
C2/0CB5: 0A           ASL 
C2/0CB6: 0A           ASL 
C2/0CB7: 0A           ASL 
C2/0CB8: 0A           ASL 
C2/0CB9: 8D 21 27     STA $2721
C2/0CBC: A5 47        LDA $47
C2/0CBE: AA           TAX 
C2/0CBF: BF 85 ED D0  LDA $D0ED85,X
C2/0CC3: AA           TAX 
C2/0CC4: 86 0E        STX $0E
C2/0CC6: A6 32        LDX $32
C2/0CC8: BD 13 20     LDA $2013,X
C2/0CCB: D0 03        BNE $0CD0
C2/0CCD: 4C 2C 0D     JMP $0D2C
C2/0CD0: 20 23 99     JSR $9923
C2/0CD3: 84 14        STY $14
C2/0CD5: 64 12        STZ $12
C2/0CD7: A6 0E        LDX $0E
C2/0CD9: BD 85 40     LDA $4085,X     ; right hand weapon
C2/0CDC: 99 FC 79     STA $79FC,Y
C2/0CDF: E8           INX 
C2/0CE0: C8           INY 
C2/0CE1: E6 12        INC $12
C2/0CE3: A5 12        LDA $12
C2/0CE5: C9 0C        CMP #$0C
C2/0CE7: D0 F0        BNE $0CD9
C2/0CE9: 20 FA 98     JSR $98FA       ; create graphics command
C2/0CEC: 9E 4C 38     STZ $384C,X
C2/0CEF: A9 FC        LDA #$FC
C2/0CF1: 9D 4D 38     STA $384D,X
C2/0CF4: A9 01        LDA #$01
C2/0CF6: 9D 4E 38     STA $384E,X
C2/0CF9: A9 04        LDA #$04
C2/0CFB: 9D 4F 38     STA $384F,X
C2/0CFE: 9E 50 38     STZ $3850,X
C2/0D01: A6 0E        LDX $0E
C2/0D03: BD 8D 40     LDA $408D,X
C2/0D06: 48           PHA 
C2/0D07: AD FA 79     LDA $79FA
C2/0D0A: AA           TAX 
C2/0D0B: 68           PLA 
C2/0D0C: 9D 2D 7B     STA $7B2D,X
C2/0D0F: 9E 1C 7B     STZ $7B1C,X
C2/0D12: 9E CC 7A     STZ $7ACC,X
C2/0D15: AD FA 79     LDA $79FA
C2/0D18: 0A           ASL 
C2/0D19: AA           TAX 
C2/0D1A: AD 20 27     LDA $2720
C2/0D1D: 9D DC 7A     STA $7ADC,X
C2/0D20: AD 21 27     LDA $2721
C2/0D23: 9D DD 7A     STA $7ADD,X
C2/0D26: EE FA 79     INC $79FA
C2/0D29: 20 E3 98     JSR $98E3
C2/0D2C: A6 32        LDX $32
C2/0D2E: BD 14 20     LDA $2014,X
C2/0D31: D0 03        BNE $0D36
C2/0D33: 4C 96 0D     JMP $0D96
C2/0D36: 20 23 99     JSR $9923
C2/0D39: 84 12        STY $12
C2/0D3B: 64 14        STZ $14
C2/0D3D: A6 0E        LDX $0E
C2/0D3F: BD 91 40     LDA $4091,X     ; left hand weapon
C2/0D42: 99 FC 79     STA $79FC,Y
C2/0D45: E8           INX 
C2/0D46: C8           INY 
C2/0D47: E6 14        INC $14
C2/0D49: A5 14        LDA $14
C2/0D4B: C9 0C        CMP #$0C
C2/0D4D: D0 F0        BNE $0D3F
C2/0D4F: A6 0E        LDX $0E
C2/0D51: AD FA 79     LDA $79FA
C2/0D54: A8           TAY 
C2/0D55: BD 99 40     LDA $4099,X
C2/0D58: 99 2D 7B     STA $7B2D,Y
C2/0D5B: 20 FA 98     JSR $98FA       ; create graphics command
C2/0D5E: 9E 4C 38     STZ $384C,X
C2/0D61: A9 FC        LDA #$FC
C2/0D63: 9D 4D 38     STA $384D,X
C2/0D66: A9 01        LDA #$01
C2/0D68: 9D 4E 38     STA $384E,X
C2/0D6B: A9 04        LDA #$04
C2/0D6D: 9D 4F 38     STA $384F,X
C2/0D70: A9 80        LDA #$80
C2/0D72: 9D 50 38     STA $3850,X
C2/0D75: AD FA 79     LDA $79FA
C2/0D78: AA           TAX 
C2/0D79: 9E 1C 7B     STZ $7B1C,X
C2/0D7C: 9E CC 7A     STZ $7ACC,X
C2/0D7F: AD FA 79     LDA $79FA
C2/0D82: 0A           ASL 
C2/0D83: AA           TAX 
C2/0D84: AD 20 27     LDA $2720
C2/0D87: 9D DC 7A     STA $7ADC,X
C2/0D8A: AD 21 27     LDA $2721
C2/0D8D: 9D DD 7A     STA $7ADD,X
C2/0D90: EE FA 79     INC $79FA
C2/0D93: 20 E3 98     JSR $98E3
C2/0D96: E6 22        INC $22
C2/0D98: A5 22        LDA $22
C2/0D9A: C9 04        CMP #$04
C2/0D9C: F0 03        BEQ $0DA1
C2/0D9E: 4C 76 0C     JMP $0C76
C2/0DA1: 60           RTS 

; [ battle command $19: observe ]

C2/0DA2: A9 19        LDA #$19
C2/0DA4: 20 AA 16     JSR $16AA
C2/0DA7: 20 5F 17     JSR $175F
C2/0DAA: 20 FE 4A     JSR $4AFE
C2/0DAD: 20 A9 02     JSR $02A9
C2/0DB0: A9 19        LDA #$19
C2/0DB2: 20 FA 16     JSR $16FA
C2/0DB5: A9 18        LDA #$18
C2/0DB7: 20 E1 16     JSR $16E1
C2/0DBA: 20 05 17     JSR $1705
C2/0DBD: 20 35 17     JSR $1735
C2/0DC0: 4C 4C 99     JMP $994C

; [ battle command $1A: analyze ]

C2/0DC3: A9 1A        LDA #$1A
C2/0DC5: 20 AA 16     JSR $16AA
C2/0DC8: 20 5F 17     JSR $175F
C2/0DCB: 20 FE 4A     JSR $4AFE
C2/0DCE: 20 A9 02     JSR $02A9
C2/0DD1: A9 1A        LDA #$1A
C2/0DD3: 20 FA 16     JSR $16FA
C2/0DD6: A9 19        LDA #$19
C2/0DD8: 20 E1 16     JSR $16E1
C2/0DDB: 20 05 17     JSR $1705
C2/0DDE: 20 35 17     JSR $1735
C2/0DE1: 4C 4C 99     JMP $994C

; [ battle command $18: conjure ]

C2/0DE4: AD 5A 09     LDA $095A
C2/0DE7: 29 FE        AND #$FE
C2/0DE9: 0D 59 09     ORA $0959
C2/0DEC: D0 2B        BNE $0E19
C2/0DEE: A9 18        LDA #$18
C2/0DF0: 20 FA 16     JSR $16FA
C2/0DF3: AD EF 3C     LDA $3CEF
C2/0DF6: AA           TAX 
C2/0DF7: A9 1D        LDA #$1D
C2/0DF9: 9D 5F 3C     STA $3C5F,X
C2/0DFC: AD FA 79     LDA $79FA
C2/0DFF: AA           TAX 
C2/0E00: A9 7E        LDA #$7E
C2/0E02: 9D 2D 7B     STA $7B2D,X
C2/0E05: 9E 1C 7B     STZ $7B1C,X
C2/0E08: 9E CC 7A     STZ $7ACC,X
C2/0E0B: A9 0D        LDA #$0D
C2/0E0D: 20 E1 16     JSR $16E1
C2/0E10: 20 50 17     JSR $1750
C2/0E13: 20 4C 99     JSR $994C
C2/0E16: 4C DF 0E     JMP $0EDF
C2/0E19: 7B           TDC 
C2/0E1A: AA           TAX 
C2/0E1B: 86 0E        STX $0E
C2/0E1D: A9 0E        LDA #$0E
C2/0E1F: 20 7C 00     JSR $007C       ; a = (x..a)
C2/0E22: 18           CLC 
C2/0E23: 69 48        ADC #$48
C2/0E25: 8D 22 27     STA $2722
C2/0E28: 9C 23 27     STZ $2723
C2/0E2B: 4A           LSR 
C2/0E2C: 66 0E        ROR $0E
C2/0E2E: 4A           LSR 
C2/0E2F: 66 0E        ROR $0E
C2/0E31: 4A           LSR 
C2/0E32: 66 0E        ROR $0E
C2/0E34: A8           TAY 
C2/0E35: A5 0E        LDA $0E
C2/0E37: 20 BD 01     JSR $01BD       ; a >> 5
C2/0E3A: AA           TAX 
C2/0E3B: B9 50 09     LDA $0950,Y     ; spells known
C2/0E3E: 20 DB 01     JSR $01DB       ; check bit x
C2/0E41: F0 D6        BEQ $0E19
C2/0E43: 64 66        STZ $66
C2/0E45: 64 65        STZ $65
C2/0E47: AD 22 27     LDA $2722
C2/0E4A: C2 20        REP #$20
C2/0E4C: 20 B6 01     JSR $01B6       ; a << 3
C2/0E4F: AA           TAX 
C2/0E50: 7B           TDC 
C2/0E51: E2 20        SEP #$20
C2/0E53: 7B           TDC 
C2/0E54: A8           TAY 
C2/0E55: BF 80 0B D1  LDA $D10B80,X   ; attack properties
C2/0E59: 99 20 26     STA $2620,Y
C2/0E5C: E8           INX 
C2/0E5D: C8           INY 
C2/0E5E: C0 08 00     CPY #$0008
C2/0E61: D0 F2        BNE $0E55
C2/0E63: AD 20 26     LDA $2620
C2/0E66: D0 0B        BNE $0E73
C2/0E68: A5 47        LDA $47
C2/0E6A: AA           TAX 
C2/0E6B: 7B           TDC 
C2/0E6C: 20 D6 01     JSR $01D6       ; set bit x
C2/0E6F: 85 66        STA $66
C2/0E71: 80 4C        BRA $0EBF
C2/0E73: 29 40        AND #$40
C2/0E75: D0 37        BNE $0EAE
C2/0E77: AD 20 26     LDA $2620
C2/0E7A: 29 08        AND #$08
C2/0E7C: D0 20        BNE $0E9E
C2/0E7E: 7B           TDC 
C2/0E7F: AA           TAX 
C2/0E80: A8           TAY 
C2/0E81: BD 1A 20     LDA $201A,X
C2/0E84: 29 80        AND #$80
C2/0E86: D0 0D        BNE $0E95
C2/0E88: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/0E8B: C8           INY 
C2/0E8C: C0 04 00     CPY #$0004
C2/0E8F: D0 F0        BNE $0E81
C2/0E91: A9 80        LDA #$80
C2/0E93: 80 05        BRA $0E9A
C2/0E95: BB           TYX 
C2/0E96: 7B           TDC 
C2/0E97: 20 D6 01     JSR $01D6       ; set bit x
C2/0E9A: 85 66        STA $66
C2/0E9C: 80 21        BRA $0EBF
C2/0E9E: 7B           TDC 
C2/0E9F: AA           TAX 
C2/0EA0: A9 07        LDA #$07
C2/0EA2: 20 7C 00     JSR $007C       ; a = (x..a)
C2/0EA5: AA           TAX 
C2/0EA6: 7B           TDC 
C2/0EA7: 20 D6 01     JSR $01D6       ; set bit x
C2/0EAA: 85 65        STA $65
C2/0EAC: 80 11        BRA $0EBF
C2/0EAE: AD 20 26     LDA $2620
C2/0EB1: 29 08        AND #$08
C2/0EB3: D0 06        BNE $0EBB
C2/0EB5: A9 F0        LDA #$F0
C2/0EB7: 85 66        STA $66
C2/0EB9: 80 04        BRA $0EBF
C2/0EBB: A9 FF        LDA #$FF
C2/0EBD: 85 65        STA $65
C2/0EBF: 64 20        STZ $20
C2/0EC1: 64 21        STZ $21
C2/0EC3: 20 E1 5C     JSR $5CE1
C2/0EC6: A5 20        LDA $20
C2/0EC8: F0 15        BEQ $0EDF
C2/0ECA: A5 20        LDA $20
C2/0ECC: 8D 22 27     STA $2722
C2/0ECF: 9C 23 27     STZ $2723
C2/0ED2: A5 23        LDA $23
C2/0ED4: 85 65        STA $65
C2/0ED6: A5 22        LDA $22
C2/0ED8: 85 66        STA $66
C2/0EDA: E6 21        INC $21
C2/0EDC: 20 E1 5C     JSR $5CE1
C2/0EDF: 60           RTS 

; [ battle command $1B: tame ]

C2/0EE0: A9 1B        LDA #$1B
C2/0EE2: 20 AA 16     JSR $16AA
C2/0EE5: 20 5F 17     JSR $175F
C2/0EE8: 20 FE 4A     JSR $4AFE
C2/0EEB: 20 A9 02     JSR $02A9
C2/0EEE: A9 1B        LDA #$1B
C2/0EF0: 20 FA 16     JSR $16FA
C2/0EF3: A9 1A        LDA #$1A
C2/0EF5: 20 E1 16     JSR $16E1
C2/0EF8: 20 05 17     JSR $1705
C2/0EFB: 4C 35 17     JMP $1735

; [ battle command $1C: control ]

C2/0EFE: A9 1C        LDA #$1C
C2/0F00: 20 AA 16     JSR $16AA
C2/0F03: 20 5F 17     JSR $175F
C2/0F06: 20 FE 4A     JSR $4AFE
C2/0F09: 20 A9 02     JSR $02A9
C2/0F0C: A9 1C        LDA #$1C
C2/0F0E: 20 FA 16     JSR $16FA
C2/0F11: A9 1B        LDA #$1B
C2/0F13: 20 E1 16     JSR $16E1
C2/0F16: 20 05 17     JSR $1705
C2/0F19: 20 35 17     JSR $1735
C2/0F1C: 4C 4C 99     JMP $994C

; [ battle command $1D: catch ]

C2/0F1F: A9 1D        LDA #$1D
C2/0F21: 20 AA 16     JSR $16AA
C2/0F24: 20 5F 17     JSR $175F
C2/0F27: 20 FE 4A     JSR $4AFE
C2/0F2A: 20 A9 02     JSR $02A9
C2/0F2D: A9 1D        LDA #$1D
C2/0F2F: 20 FA 16     JSR $16FA
C2/0F32: A9 1C        LDA #$1C
C2/0F34: 20 E1 16     JSR $16E1
C2/0F37: 20 05 17     JSR $1705
C2/0F3A: 20 35 17     JSR $1735
C2/0F3D: 4C 4C 99     JMP $994C

; [ battle command $1E: release ]

C2/0F40: A6 32        LDX $32
C2/0F42: BD 15 20     LDA $2015,X
C2/0F45: 8D 4B 7C     STA $7C4B
C2/0F48: 48           PHA 
C2/0F49: A9 FF        LDA #$FF
C2/0F4B: 9D 15 20     STA $2015,X
C2/0F4E: 68           PLA 
C2/0F4F: AA           TAX 
C2/0F50: BF 00 86 D0  LDA $D08600,X
C2/0F54: 8D 22 27     STA $2722
C2/0F57: C2 20        REP #$20
C2/0F59: 20 B6 01     JSR $01B6       ; a << 3
C2/0F5C: AA           TAX 
C2/0F5D: 7B           TDC 
C2/0F5E: E2 20        SEP #$20
C2/0F60: 7B           TDC 
C2/0F61: A8           TAY 
C2/0F62: BF 80 0B D1  LDA $D10B80,X
C2/0F66: 99 2A 26     STA $262A,Y
C2/0F69: E8           INX 
C2/0F6A: C8           INY 
C2/0F6B: C0 08 00     CPY #$0008
C2/0F6E: D0 F2        BNE $0F62
C2/0F70: 20 23 99     JSR $9923
C2/0F73: 7B           TDC 
C2/0F74: AA           TAX 
C2/0F75: BD 2A 26     LDA $262A,X
C2/0F78: 99 FC 79     STA $79FC,Y
C2/0F7B: E8           INX 
C2/0F7C: C8           INY 
C2/0F7D: E0 05 00     CPX #$0005
C2/0F80: D0 F3        BNE $0F75
C2/0F82: C8           INY 
C2/0F83: C8           INY 
C2/0F84: C8           INY 
C2/0F85: C8           INY 
C2/0F86: BD 2A 26     LDA $262A,X
C2/0F89: 99 FC 79     STA $79FC,Y
C2/0F8C: E8           INX 
C2/0F8D: C8           INY 
C2/0F8E: E0 08 00     CPX #$0008
C2/0F91: D0 F3        BNE $0F86
C2/0F93: 64 65        STZ $65
C2/0F95: 64 66        STZ $66
C2/0F97: AD 2A 26     LDA $262A
C2/0F9A: D0 0B        BNE $0FA7
C2/0F9C: A5 47        LDA $47
C2/0F9E: AA           TAX 
C2/0F9F: 7B           TDC 
C2/0FA0: 20 D6 01     JSR $01D6       ; set bit x
C2/0FA3: 85 66        STA $66
C2/0FA5: 80 40        BRA $0FE7
C2/0FA7: 29 40        AND #$40
C2/0FA9: D0 2B        BNE $0FD6
C2/0FAB: AD 2A 26     LDA $262A
C2/0FAE: 29 08        AND #$08
C2/0FB0: D0 14        BNE $0FC6
C2/0FB2: 7B           TDC 
C2/0FB3: AA           TAX 
C2/0FB4: A9 03        LDA #$03
C2/0FB6: 20 7C 00     JSR $007C       ; a = (x..a)
C2/0FB9: C5 47        CMP $47
C2/0FBB: F0 F5        BEQ $0FB2
C2/0FBD: AA           TAX 
C2/0FBE: 7B           TDC 
C2/0FBF: 20 D6 01     JSR $01D6       ; set bit x
C2/0FC2: 85 66        STA $66
C2/0FC4: 80 21        BRA $0FE7
C2/0FC6: 7B           TDC 
C2/0FC7: AA           TAX 
C2/0FC8: A9 07        LDA #$07
C2/0FCA: 20 7C 00     JSR $007C       ; a = (x..a)
C2/0FCD: AA           TAX 
C2/0FCE: 7B           TDC 
C2/0FCF: 20 D6 01     JSR $01D6       ; set bit x
C2/0FD2: 85 65        STA $65
C2/0FD4: 80 11        BRA $0FE7
C2/0FD6: AD 2A 26     LDA $262A
C2/0FD9: 29 08        AND #$08
C2/0FDB: D0 06        BNE $0FE3
C2/0FDD: A9 F0        LDA #$F0
C2/0FDF: 85 66        STA $66
C2/0FE1: 80 04        BRA $0FE7
C2/0FE3: A9 FF        LDA #$FF
C2/0FE5: 85 65        STA $65
C2/0FE7: 20 C2 02     JSR $02C2
C2/0FEA: D0 13        BNE $0FFF
C2/0FEC: AD 2E 26     LDA $262E
C2/0FEF: 10 09        BPL $0FFA
C2/0FF1: AD FA 79     LDA $79FA
C2/0FF4: AA           TAX 
C2/0FF5: FE EB 7B     INC $7BEB,X
C2/0FF8: 80 0B        BRA $1005
C2/0FFA: 20 FE 4A     JSR $4AFE
C2/0FFD: 80 06        BRA $1005
C2/0FFF: 20 CF 02     JSR $02CF
C2/1002: 20 C2 02     JSR $02C2
C2/1005: 20 A9 02     JSR $02A9
C2/1008: AD 22 27     LDA $2722
C2/100B: 8D 21 26     STA $2621
C2/100E: 9C 20 26     STZ $2620
C2/1011: 20 2F 99     JSR $992F
C2/1014: 20 FA 98     JSR $98FA       ; create graphics command
C2/1017: 9E 4C 38     STZ $384C,X
C2/101A: 9E 50 38     STZ $3850,X
C2/101D: A9 FC        LDA #$FC
C2/101F: 9D 4D 38     STA $384D,X
C2/1022: A9 00        LDA #$00
C2/1024: 9D 4E 38     STA $384E,X
C2/1027: AD 21 26     LDA $2621
C2/102A: 9D 4F 38     STA $384F,X
C2/102D: AD FA 79     LDA $79FA
C2/1030: AA           TAX 
C2/1031: AD 2E 26     LDA $262E
C2/1034: 29 7F        AND #$7F
C2/1036: 9D 2D 7B     STA $7B2D,X
C2/1039: AD A0 26     LDA $26A0
C2/103C: 9D 1C 7B     STA $7B1C,X
C2/103F: F0 05        BEQ $1046
C2/1041: FE 1C 7B     INC $7B1C,X
C2/1044: A9 80        LDA #$80
C2/1046: 9D CC 7A     STA $7ACC,X
C2/1049: AD FA 79     LDA $79FA
C2/104C: 0A           ASL 
C2/104D: AA           TAX 
C2/104E: AD 20 27     LDA $2720
C2/1051: 9D DC 7A     STA $7ADC,X
C2/1054: 9D FC 7A     STA $7AFC,X
C2/1057: AD 21 27     LDA $2721
C2/105A: 9D DD 7A     STA $7ADD,X
C2/105D: 9D FD 7A     STA $7AFD,X
C2/1060: EE FA 79     INC $79FA
C2/1063: 20 E3 98     JSR $98E3
C2/1066: A5 47        LDA $47
C2/1068: 85 24        STA $24
C2/106A: A9 14        LDA #$14
C2/106C: 85 25        STA $25
C2/106E: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/1071: 7B           TDC 
C2/1072: A8           TAY 
C2/1073: A6 26        LDX $26
C2/1075: BD 5C 37     LDA $375C,X
C2/1078: C9 1E        CMP #$1E
C2/107A: F0 09        BEQ $1085
C2/107C: E8           INX 
C2/107D: C8           INY 
C2/107E: C0 04 00     CPY #$0004
C2/1081: D0 F2        BNE $1075
C2/1083: F0 0E        BEQ $1093
C2/1085: A9 1D        LDA #$1D
C2/1087: 9D 5C 37     STA $375C,X
C2/108A: A9 28        LDA #$28
C2/108C: 9D 68 37     STA $3768,X
C2/108F: E8           INX 
C2/1090: C8           INY 
C2/1091: 80 E2        BRA $1075
C2/1093: A6 32        LDX $32
C2/1095: BD 02 20     LDA $2002,X
C2/1098: 8D 00 26     STA $2600
C2/109B: BD 44 20     LDA $2044,X
C2/109E: 8D 01 26     STA $2601
C2/10A1: BD 62 20     LDA $2062,X
C2/10A4: 8D 02 26     STA $2602
C2/10A7: BD 2B 20     LDA $202B,X
C2/10AA: 8D 03 26     STA $2603
C2/10AD: BD 00 20     LDA $2000,X
C2/10B0: 8D 04 26     STA $2604
C2/10B3: 7B           TDC 
C2/10B4: A8           TAY 
C2/10B5: BD 1A 20     LDA $201A,X
C2/10B8: 99 05 26     STA $2605,Y
C2/10BB: 9E 1A 20     STZ $201A,X
C2/10BE: E8           INX 
C2/10BF: C8           INY 
C2/10C0: C0 09 00     CPY #$0009
C2/10C3: D0 F0        BNE $10B5
C2/10C5: 7B           TDC 
C2/10C6: A8           TAY 
C2/10C7: A6 32        LDX $32
C2/10C9: BD 50 20     LDA $2050,X
C2/10CC: 99 0E 26     STA $260E,Y
C2/10CF: 9E 50 20     STZ $2050,X
C2/10D2: E8           INX 
C2/10D3: C8           INY 
C2/10D4: C0 06 00     CPY #$0006
C2/10D7: D0 F0        BNE $10C9
C2/10D9: 7B           TDC 
C2/10DA: A8           TAY 
C2/10DB: A6 32        LDX $32
C2/10DD: BD 70 20     LDA $2070,X     ; copy to buffer
C2/10E0: 99 14 26     STA $2614,Y
C2/10E3: 9E 70 20     STZ $2070,X
C2/10E6: E8           INX 
C2/10E7: C8           INY 
C2/10E8: C0 0B 00     CPY #$000B
C2/10EB: D0 F0        BNE $10DD
C2/10ED: AD 4B 7C     LDA $7C4B
C2/10F0: C2 20        REP #$20
C2/10F2: 20 B4 01     JSR $01B4       ; a << 5
C2/10F5: AA           TAX 
C2/10F6: 7B           TDC 
C2/10F7: E2 20        SEP #$20
C2/10F9: A4 32        LDY $32
C2/10FB: B9 00 20     LDA $2000,Y
C2/10FE: 29 7F        AND #$7F
C2/1100: 99 00 20     STA $2000,Y
C2/1103: BF 1F 00 D0  LDA $D0001F,X
C2/1107: 99 02 20     STA $2002,Y
C2/110A: BF 01 00 D0  LDA $D00001,X
C2/110E: 99 44 20     STA $2044,Y
C2/1111: BF 02 00 D0  LDA $D00002,X
C2/1115: 99 62 20     STA $2062,Y
C2/1118: BF 05 00 D0  LDA $D00005,X
C2/111C: 99 2B 20     STA $202B,Y
C2/111F: A9 01        LDA #$01
C2/1121: 8D 4F 7C     STA $7C4F
C2/1124: 60           RTS 

; [ battle command $1F: combine ]

C2/1125: A6 32        LDX $32
C2/1127: BD 58 20     LDA $2058,X
C2/112A: 85 65        STA $65
C2/112C: BD 59 20     LDA $2059,X
C2/112F: 85 66        STA $66
C2/1131: BD 5A 20     LDA $205A,X
C2/1134: 38           SEC 
C2/1135: E9 E0        SBC #$E0
C2/1137: AA           TAX 
C2/1138: 86 0E        STX $0E
C2/113A: A6 32        LDX $32
C2/113C: BD 5F 20     LDA $205F,X
C2/113F: 38           SEC 
C2/1140: E9 E0        SBC #$E0
C2/1142: 85 24        STA $24
C2/1144: A9 0C        LDA #$0C
C2/1146: 85 25        STA $25
C2/1148: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/114B: C2 20        REP #$20
C2/114D: 18           CLC 
C2/114E: A5 26        LDA $26
C2/1150: 65 0E        ADC $0E
C2/1152: AA           TAX 
C2/1153: 7B           TDC 
C2/1154: E2 20        SEP #$20
C2/1156: BF F9 6E D1  LDA $D16EF9,X
C2/115A: 8D 22 27     STA $2722
C2/115D: 64 20        STZ $20
C2/115F: 64 21        STZ $21
C2/1161: A9 01        LDA #$01
C2/1163: 8D 23 27     STA $2723
C2/1166: 4C E1 5C     JMP $5CE1

; [ battle command $21: pray ]

C2/1169: A9 21        LDA #$21
C2/116B: 20 AA 16     JSR $16AA
C2/116E: 20 5F 17     JSR $175F
C2/1171: 20 A9 02     JSR $02A9
C2/1174: 20 C2 02     JSR $02C2
C2/1177: A9 21        LDA #$21
C2/1179: 20 FA 16     JSR $16FA
C2/117C: A9 20        LDA #$20
C2/117E: 20 E1 16     JSR $16E1
C2/1181: 20 1A 17     JSR $171A
C2/1184: 20 35 17     JSR $1735
C2/1187: 4C E3 98     JMP $98E3

; [ battle command $22: revive ]

C2/118A: A9 22        LDA #$22
C2/118C: 20 AA 16     JSR $16AA
C2/118F: 20 5F 17     JSR $175F
C2/1192: 20 A9 02     JSR $02A9
C2/1195: 20 C2 02     JSR $02C2
C2/1198: AD FA 79     LDA $79FA
C2/119B: AA           TAX 
C2/119C: FE EB 7B     INC $7BEB,X
C2/119F: A9 22        LDA #$22
C2/11A1: 20 FA 16     JSR $16FA
C2/11A4: A9 21        LDA #$21
C2/11A6: 20 E1 16     JSR $16E1
C2/11A9: 20 1A 17     JSR $171A
C2/11AC: 20 35 17     JSR $1735
C2/11AF: 4C E3 98     JMP $98E3

; [ battle command $23: terrain ]

C2/11B2: 7B           TDC 
C2/11B3: AA           TAX 
C2/11B4: AD E5 7B     LDA $7BE5       ; attacker level
C2/11B7: 20 7C 00     JSR $007C       ; a = (x..a)
C2/11BA: C9 0B        CMP #$0B
C2/11BC: B0 03        BCS $11C1
C2/11BE: 7B           TDC             ; 0-10, a = 0
C2/11BF: 80 12        BRA $11D3
C2/11C1: C9 15        CMP #$15
C2/11C3: B0 04        BCS $11C9
C2/11C5: A9 01        LDA #$01        ; 11-20, a = 1
C2/11C7: 80 0A        BRA $11D3
C2/11C9: C9 33        CMP #$33
C2/11CB: B0 04        BCS $11D1
C2/11CD: A9 02        LDA #$02        ; 20-50, a = 2
C2/11CF: 80 02        BRA $11D3
C2/11D1: A9 03        LDA #$03        ; 50-99, a = 3
C2/11D3: 85 0E        STA $0E
C2/11D5: AD F2 04     LDA $04F2       ; battle background
C2/11D8: 20 B7 01     JSR $01B7       ; a << 2
C2/11DB: 18           CLC 
C2/11DC: 65 0E        ADC $0E
C2/11DE: AA           TAX 
C2/11DF: BF F9 6D D1  LDA $D16DF9,X   ; terrain attack
C2/11E3: 8D 22 27     STA $2722
C2/11E6: AD 22 27     LDA $2722
C2/11E9: C2 20        REP #$20
C2/11EB: 20 B6 01     JSR $01B6       ; a << 3
C2/11EE: AA           TAX 
C2/11EF: 7B           TDC 
C2/11F0: E2 20        SEP #$20
C2/11F2: 7B           TDC 
C2/11F3: A8           TAY 
C2/11F4: BF B1 6A D1  LDA $D16AB1,X   ; job attack targets
C2/11F8: 99 20 26     STA $2620,Y
C2/11FB: E8           INX 
C2/11FC: C8           INY 
C2/11FD: C0 08 00     CPY #$0008
C2/1200: D0 F2        BNE $11F4
C2/1202: 64 66        STZ $66
C2/1204: 64 65        STZ $65
C2/1206: AD 20 26     LDA $2620
C2/1209: D0 0B        BNE $1216
C2/120B: A5 47        LDA $47
C2/120D: AA           TAX 
C2/120E: 7B           TDC 
C2/120F: 20 D6 01     JSR $01D6       ; set bit x
C2/1212: 85 66        STA $66
C2/1214: 80 3C        BRA $1252
C2/1216: 29 08        AND #$08
C2/1218: D0 1D        BNE $1237
C2/121A: AD 20 26     LDA $2620
C2/121D: 29 40        AND #$40
C2/121F: D0 10        BNE $1231
C2/1221: 7B           TDC 
C2/1222: AA           TAX 
C2/1223: A9 03        LDA #$03
C2/1225: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1228: AA           TAX 
C2/1229: 7B           TDC 
C2/122A: 20 D6 01     JSR $01D6       ; set bit x
C2/122D: 85 66        STA $66
C2/122F: 80 21        BRA $1252
C2/1231: A9 F0        LDA #$F0
C2/1233: 85 66        STA $66
C2/1235: 80 1B        BRA $1252
C2/1237: AD 20 26     LDA $2620
C2/123A: 29 40        AND #$40
C2/123C: D0 10        BNE $124E
C2/123E: 7B           TDC 
C2/123F: AA           TAX 
C2/1240: A9 07        LDA #$07
C2/1242: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1245: AA           TAX 
C2/1246: 7B           TDC 
C2/1247: 20 D6 01     JSR $01D6       ; set bit x
C2/124A: 85 65        STA $65
C2/124C: 80 04        BRA $1252
C2/124E: A9 FF        LDA #$FF
C2/1250: 85 65        STA $65
C2/1252: 64 20        STZ $20
C2/1254: 64 21        STZ $21
C2/1256: A9 01        LDA #$01
C2/1258: 8D 23 27     STA $2723
C2/125B: 4C E1 5C     JMP $5CE1

; [ battle command $25: hide ]

C2/125E: A6 32        LDX $32
C2/1260: BD 1D 20     LDA $201D,X
C2/1263: 09 01        ORA #$01
C2/1265: 9D 1D 20     STA $201D,X
C2/1268: A9 25        LDA #$25
C2/126A: 20 FA 16     JSR $16FA
C2/126D: A9 24        LDA #$24
C2/126F: 20 E1 16     JSR $16E1
C2/1272: AD FA 79     LDA $79FA
C2/1275: AA           TAX 
C2/1276: 9E 2D 7B     STZ $7B2D,X
C2/1279: 9E 1C 7B     STZ $7B1C,X
C2/127C: 9E CC 7A     STZ $7ACC,X
C2/127F: EE FB 7B     INC $7BFB
C2/1282: 20 50 17     JSR $1750
C2/1285: A5 47        LDA $47
C2/1287: 85 24        STA $24
C2/1289: A9 14        LDA #$14
C2/128B: 85 25        STA $25
C2/128D: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/1290: 7B           TDC 
C2/1291: A8           TAY 
C2/1292: A6 26        LDX $26
C2/1294: BD 5C 37     LDA $375C,X
C2/1297: C9 25        CMP #$25
C2/1299: F0 09        BEQ $12A4
C2/129B: E8           INX 
C2/129C: C8           INY 
C2/129D: C0 04 00     CPY #$0004
C2/12A0: D0 F2        BNE $1294
C2/12A2: F0 0E        BEQ $12B2
C2/12A4: A9 26        LDA #$26
C2/12A6: 9D 5C 37     STA $375C,X
C2/12A9: A9 08        LDA #$08
C2/12AB: 9D 68 37     STA $3768,X
C2/12AE: E8           INX 
C2/12AF: C8           INY 
C2/12B0: 80 E2        BRA $1294
C2/12B2: 60           RTS 

; [ battle command $26: show ]

C2/12B3: A6 32        LDX $32
C2/12B5: BD 1D 20     LDA $201D,X
C2/12B8: 29 FE        AND #$FE
C2/12BA: 9D 1D 20     STA $201D,X
C2/12BD: A9 26        LDA #$26
C2/12BF: 20 FA 16     JSR $16FA
C2/12C2: A9 25        LDA #$25
C2/12C4: 20 E1 16     JSR $16E1
C2/12C7: AD FA 79     LDA $79FA
C2/12CA: AA           TAX 
C2/12CB: 9E 2D 7B     STZ $7B2D,X
C2/12CE: 9E 1C 7B     STZ $7B1C,X
C2/12D1: 9E CC 7A     STZ $7ACC,X
C2/12D4: EE FB 7B     INC $7BFB
C2/12D7: 20 50 17     JSR $1750
C2/12DA: A5 47        LDA $47
C2/12DC: 85 24        STA $24
C2/12DE: A9 14        LDA #$14
C2/12E0: 85 25        STA $25
C2/12E2: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/12E5: 7B           TDC 
C2/12E6: A8           TAY 
C2/12E7: A6 26        LDX $26
C2/12E9: BD 5C 37     LDA $375C,X
C2/12EC: C9 26        CMP #$26
C2/12EE: F0 09        BEQ $12F9
C2/12F0: E8           INX 
C2/12F1: C8           INY 
C2/12F2: C0 04 00     CPY #$0004
C2/12F5: D0 F2        BNE $12E9
C2/12F7: F0 0C        BEQ $1305
C2/12F9: A9 25        LDA #$25
C2/12FB: 9D 5C 37     STA $375C,X
C2/12FE: 9E 68 37     STZ $3768,X
C2/1301: E8           INX 
C2/1302: C8           INY 
C2/1303: 80 E4        BRA $12E9
C2/1305: 60           RTS 

; [ battle command $29: flirt ]

C2/1306: A9 29        LDA #$29
C2/1308: 20 AA 16     JSR $16AA
C2/130B: 20 5F 17     JSR $175F
C2/130E: 20 FE 4A     JSR $4AFE
C2/1311: 20 A9 02     JSR $02A9
C2/1314: A9 29        LDA #$29
C2/1316: 20 FA 16     JSR $16FA
C2/1319: A9 28        LDA #$28
C2/131B: 20 E1 16     JSR $16E1
C2/131E: 20 05 17     JSR $1705
C2/1321: 20 35 17     JSR $1735
C2/1324: 20 E3 98     JSR $98E3
C2/1327: AD EF 3C     LDA $3CEF
C2/132A: AA           TAX 
C2/132B: A9 27        LDA #$27
C2/132D: 9D 5F 3C     STA $3C5F,X
C2/1330: 4C 4C 99     JMP $994C

; [ battle command $2A: dance ]

C2/1333: 9C FA 79     STZ $79FA
C2/1336: 9C F9 79     STZ $79F9
C2/1339: 7B           TDC 
C2/133A: AA           TAX 
C2/133B: A9 03        LDA #$03
C2/133D: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1340: 8D 33 27     STA $2733
C2/1343: A6 32        LDX $32
C2/1345: BD 39 20     LDA $2039,X
C2/1348: 29 04        AND #$04
C2/134A: F0 17        BEQ $1363
C2/134C: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/134F: 4A           LSR 
C2/1350: B0 07        BCS $1359
C2/1352: A9 03        LDA #$03
C2/1354: 8D 33 27     STA $2733
C2/1357: 80 0A        BRA $1363
C2/1359: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/135C: 4A           LSR 
C2/135D: 9C 33 27     STZ $2733
C2/1360: 2E 33 27     ROL $2733
C2/1363: AD 33 27     LDA $2733
C2/1366: C9 03        CMP #$03
C2/1368: F0 32        BEQ $139C
C2/136A: 20 5F 17     JSR $175F
C2/136D: 20 FE 4A     JSR $4AFE
C2/1370: 20 A9 02     JSR $02A9
C2/1373: 20 C2 02     JSR $02C2
C2/1376: 18           CLC 
C2/1377: AD 33 27     LDA $2733
C2/137A: 69 79        ADC #$79
C2/137C: 8D 21 26     STA $2621
C2/137F: 9C 20 26     STZ $2620
C2/1382: 20 2F 99     JSR $992F
C2/1385: A9 29        LDA #$29
C2/1387: 20 E1 16     JSR $16E1
C2/138A: 20 23 99     JSR $9923
C2/138D: AD 21 26     LDA $2621
C2/1390: 20 24 03     JSR $0324
C2/1393: 20 05 17     JSR $1705
C2/1396: 20 35 17     JSR $1735
C2/1399: 4C E3 98     JMP $98E3
C2/139C: A9 7D        LDA #$7D
C2/139E: 8D 21 26     STA $2621
C2/13A1: 9C 20 26     STZ $2620
C2/13A4: 20 2F 99     JSR $992F
C2/13A7: A9 29        LDA #$29
C2/13A9: 20 E1 16     JSR $16E1
C2/13AC: AD FA 79     LDA $79FA
C2/13AF: AA           TAX 
C2/13B0: A9 7F        LDA #$7F
C2/13B2: 9D 2D 7B     STA $7B2D,X
C2/13B5: 9E 1C 7B     STZ $7B1C,X
C2/13B8: 9E CC 7A     STZ $7ACC,X
C2/13BB: 20 50 17     JSR $1750
C2/13BE: 20 E3 98     JSR $98E3
C2/13C1: A6 32        LDX $32
C2/13C3: BD 1F 20     LDA $201F,X
C2/13C6: 09 D0        ORA #$D0
C2/13C8: 9D 1F 20     STA $201F,X
C2/13CB: 4C 14 08     JMP $0814

; [ battle command $2B: mimic ]

C2/13CE: 7B           TDC 
C2/13CF: A8           TAY 
C2/13D0: A6 32        LDX $32
C2/13D2: B9 D4 41     LDA $41D4,Y
C2/13D5: 9D 56 20     STA $2056,X
C2/13D8: E8           INX 
C2/13D9: C8           INY 
C2/13DA: C0 0A 00     CPY #$000A
C2/13DD: D0 F3        BNE $13D2
C2/13DF: A6 32        LDX $32
C2/13E1: BD 56 20     LDA $2056,X
C2/13E4: 29 FE        AND #$FE
C2/13E6: 9D 56 20     STA $2056,X
C2/13E9: BD 57 20     LDA $2057,X
C2/13EC: 4C D5 49     JMP $49D5

; [ battle command $30:  ]

C2/13EF: 20 FA 98     JSR $98FA       ; create graphics command
C2/13F2: 9E 4C 38     STZ $384C,X
C2/13F5: 9E 4D 38     STZ $384D,X
C2/13F8: 9E 4E 38     STZ $384E,X
C2/13FB: 9E 4F 38     STZ $384F,X
C2/13FE: 9E 50 38     STZ $3850,X
C2/1401: AD FA 79     LDA $79FA
C2/1404: AA           TAX 
C2/1405: 9E 2D 7B     STZ $7B2D,X
C2/1408: 9E 1C 7B     STZ $7B1C,X
C2/140B: 9E CC 7A     STZ $7ACC,X
C2/140E: 20 50 17     JSR $1750
C2/1411: AD EF 3C     LDA $3CEF
C2/1414: AA           TAX 
C2/1415: A9 28        LDA #$28
C2/1417: 9D 5F 3C     STA $3C5F,X
C2/141A: 4C 4C 99     JMP $994C

; [ battle command $31:  ]

C2/141D: A9 52        LDA #$52
C2/141F: 20 FA 16     JSR $16FA
C2/1422: 4C 95 09     JMP $0995

; [ battle command $32:  ]

C2/1425: A9 4B        LDA #$4B
C2/1427: 8D 33 27     STA $2733
C2/142A: 64 0E        STZ $0E
C2/142C: 9C F9 79     STZ $79F9
C2/142F: A6 32        LDX $32
C2/1431: BD 13 20     LDA $2013,X
C2/1434: D0 04        BNE $143A
C2/1436: A9 80        LDA #$80
C2/1438: 85 0E        STA $0E
C2/143A: 20 FA 98     JSR $98FA       ; create graphics command
C2/143D: 9C 4C 38     STZ $384C
C2/1440: A9 FC        LDA #$FC
C2/1442: 8D 4D 38     STA $384D
C2/1445: A9 01        LDA #$01
C2/1447: 8D 4E 38     STA $384E
C2/144A: A9 04        LDA #$04
C2/144C: 8D 4F 38     STA $384F
C2/144F: A5 0E        LDA $0E
C2/1451: 8D 50 38     STA $3850
C2/1454: A9 7E        LDA #$7E
C2/1456: 8D 2D 7B     STA $7B2D
C2/1459: 9C 1C 7B     STZ $7B1C
C2/145C: 9C CC 7A     STZ $7ACC
C2/145F: 9C DC 7A     STZ $7ADC
C2/1462: 9C DD 7A     STZ $7ADD
C2/1465: EE FA 79     INC $79FA
C2/1468: 20 E3 98     JSR $98E3
C2/146B: A9 FF        LDA #$FF
C2/146D: 8D 65 00     STA $0065
C2/1470: 9C 66 00     STZ $0066
C2/1473: AD 33 27     LDA $2733
C2/1476: 8D 22 27     STA $2722
C2/1479: A9 01        LDA #$01
C2/147B: 8D 23 27     STA $2723
C2/147E: 85 21        STA $21
C2/1480: 64 20        STZ $20
C2/1482: 20 E1 5C     JSR $5CE1
C2/1485: A6 32        LDX $32
C2/1487: BD 57 20     LDA $2057,X
C2/148A: C9 0C        CMP #$0C
C2/148C: D0 01        BNE $148F
C2/148E: FA           PLX 
C2/148F: 60           RTS 

; [ battle command $33:  ]

C2/1490: A6 32        LDX $32
C2/1492: 18           CLC 
C2/1493: BD 01 20     LDA $2001,X
C2/1496: 69 30        ADC #$30
C2/1498: 20 E1 16     JSR $16E1
C2/149B: A9 7F        LDA #$7F
C2/149D: 8D 2D 7B     STA $7B2D
C2/14A0: 9C 1C 7B     STZ $7B1C
C2/14A3: 9C CC 7A     STZ $7ACC
C2/14A6: A9 08        LDA #$08
C2/14A8: 8D DC 7A     STA $7ADC
C2/14AB: 8D FC 7A     STA $7AFC
C2/14AE: 9C DD 7A     STZ $7ADD
C2/14B1: 9C FD 7A     STZ $7AFD
C2/14B4: EE FB 7B     INC $7BFB
C2/14B7: 60           RTS 

; [ battle command $34:  ]

C2/14B8: 9C FA 79     STZ $79FA
C2/14BB: 9C F9 79     STZ $79F9
C2/14BE: A6 32        LDX $32
C2/14C0: BD 58 20     LDA $2058,X
C2/14C3: 85 65        STA $65
C2/14C5: BD 59 20     LDA $2059,X
C2/14C8: 85 66        STA $66
C2/14CA: 20 FE 4A     JSR $4AFE
C2/14CD: A6 32        LDX $32
C2/14CF: A5 66        LDA $66
C2/14D1: 9D 59 20     STA $2059,X
C2/14D4: A5 65        LDA $65
C2/14D6: 9D 58 20     STA $2058,X
C2/14D9: 48           PHA 
C2/14DA: 29 F0        AND #$F0
C2/14DC: 4A           LSR 
C2/14DD: 4A           LSR 
C2/14DE: 4A           LSR 
C2/14DF: 4A           LSR 
C2/14E0: 1D 59 20     ORA $2059,X
C2/14E3: 8D 20 27     STA $2720
C2/14E6: 68           PLA 
C2/14E7: 29 0F        AND #$0F
C2/14E9: 0A           ASL 
C2/14EA: 0A           ASL 
C2/14EB: 0A           ASL 
C2/14EC: 0A           ASL 
C2/14ED: 8D 21 27     STA $2721
C2/14F0: A5 47        LDA $47
C2/14F2: AA           TAX 
C2/14F3: BF 85 ED D0  LDA $D0ED85,X
C2/14F7: AA           TAX 
C2/14F8: 86 0E        STX $0E
C2/14FA: A6 32        LDX $32
C2/14FC: BD 13 20     LDA $2013,X
C2/14FF: D0 03        BNE $1504
C2/1501: 4C C9 15     JMP $15C9
C2/1504: 20 23 99     JSR $9923
C2/1507: 84 14        STY $14
C2/1509: 64 12        STZ $12
C2/150B: A6 0E        LDX $0E
C2/150D: BD 85 40     LDA $4085,X
C2/1510: 99 FC 79     STA $79FC,Y
C2/1513: E8           INX 
C2/1514: C8           INY 
C2/1515: E6 12        INC $12
C2/1517: A5 12        LDA $12
C2/1519: C9 0C        CMP #$0C
C2/151B: D0 F0        BNE $150D
C2/151D: 20 FA 98     JSR $98FA       ; create graphics command
C2/1520: 9E 4C 38     STZ $384C,X
C2/1523: A9 FC        LDA #$FC
C2/1525: 9D 4D 38     STA $384D,X
C2/1528: A9 01        LDA #$01
C2/152A: 9D 4E 38     STA $384E,X
C2/152D: A9 04        LDA #$04
C2/152F: 9D 4F 38     STA $384F,X
C2/1532: 9E 50 38     STZ $3850,X
C2/1535: A6 0E        LDX $0E
C2/1537: BD 8D 40     LDA $408D,X
C2/153A: 48           PHA 
C2/153B: AD FA 79     LDA $79FA
C2/153E: AA           TAX 
C2/153F: 68           PLA 
C2/1540: 9D 2D 7B     STA $7B2D,X
C2/1543: 9E 1C 7B     STZ $7B1C,X
C2/1546: 9E CC 7A     STZ $7ACC,X
C2/1549: AD FA 79     LDA $79FA
C2/154C: 0A           ASL 
C2/154D: AA           TAX 
C2/154E: AD 20 27     LDA $2720
C2/1551: 9D DC 7A     STA $7ADC,X
C2/1554: AD 21 27     LDA $2721
C2/1557: 9D DD 7A     STA $7ADD,X
C2/155A: EE FA 79     INC $79FA
C2/155D: 20 E3 98     JSR $98E3
C2/1560: 20 23 99     JSR $9923
C2/1563: 84 14        STY $14
C2/1565: 64 12        STZ $12
C2/1567: A6 0E        LDX $0E
C2/1569: BD 8A 40     LDA $408A,X
C2/156C: 29 02        AND #$02
C2/156E: F0 59        BEQ $15C9
C2/1570: BD 90 40     LDA $4090,X
C2/1573: C9 55        CMP #$55
C2/1575: D0 52        BNE $15C9
C2/1577: BD 85 40     LDA $4085,X
C2/157A: 99 FC 79     STA $79FC,Y
C2/157D: E8           INX 
C2/157E: C8           INY 
C2/157F: E6 12        INC $12
C2/1581: A5 12        LDA $12
C2/1583: C9 0C        CMP #$0C
C2/1585: D0 F0        BNE $1577
C2/1587: A9 80        LDA #$80
C2/1589: 8D 9B 7C     STA $7C9B
C2/158C: 20 FA 98     JSR $98FA       ; create graphics command
C2/158F: 9E 4C 38     STZ $384C,X
C2/1592: 9E 4D 38     STZ $384D,X
C2/1595: 9E 4E 38     STZ $384E,X
C2/1598: 9E 4F 38     STZ $384F,X
C2/159B: 9E 50 38     STZ $3850,X
C2/159E: A6 0E        LDX $0E
C2/15A0: BD 8D 40     LDA $408D,X
C2/15A3: 48           PHA 
C2/15A4: AD FA 79     LDA $79FA
C2/15A7: AA           TAX 
C2/15A8: 68           PLA 
C2/15A9: 9D 2D 7B     STA $7B2D,X
C2/15AC: 9E 1C 7B     STZ $7B1C,X
C2/15AF: 9E CC 7A     STZ $7ACC,X
C2/15B2: AD FA 79     LDA $79FA
C2/15B5: 0A           ASL 
C2/15B6: AA           TAX 
C2/15B7: AD 20 27     LDA $2720
C2/15BA: 9D DC 7A     STA $7ADC,X
C2/15BD: AD 21 27     LDA $2721
C2/15C0: 9D DD 7A     STA $7ADD,X
C2/15C3: EE FA 79     INC $79FA
C2/15C6: 20 E3 98     JSR $98E3
C2/15C9: A6 32        LDX $32
C2/15CB: BD 14 20     LDA $2014,X
C2/15CE: D0 03        BNE $15D3
C2/15D0: 4C A1 16     JMP $16A1
C2/15D3: 20 23 99     JSR $9923
C2/15D6: 84 12        STY $12
C2/15D8: 64 14        STZ $14
C2/15DA: A6 0E        LDX $0E
C2/15DC: BD 91 40     LDA $4091,X
C2/15DF: 99 FC 79     STA $79FC,Y
C2/15E2: E8           INX 
C2/15E3: C8           INY 
C2/15E4: E6 14        INC $14
C2/15E6: A5 14        LDA $14
C2/15E8: C9 0C        CMP #$0C
C2/15EA: D0 F0        BNE $15DC
C2/15EC: A6 0E        LDX $0E
C2/15EE: AD FA 79     LDA $79FA
C2/15F1: A8           TAY 
C2/15F2: BD 99 40     LDA $4099,X
C2/15F5: 99 2D 7B     STA $7B2D,Y
C2/15F8: 20 FA 98     JSR $98FA       ; create graphics command
C2/15FB: 9E 4C 38     STZ $384C,X
C2/15FE: A9 FC        LDA #$FC
C2/1600: 9D 4D 38     STA $384D,X
C2/1603: A9 01        LDA #$01
C2/1605: 9D 4E 38     STA $384E,X
C2/1608: A9 04        LDA #$04
C2/160A: 9D 4F 38     STA $384F,X
C2/160D: A9 80        LDA #$80
C2/160F: 9D 50 38     STA $3850,X
C2/1612: AD FA 79     LDA $79FA
C2/1615: AA           TAX 
C2/1616: 9E 1C 7B     STZ $7B1C,X
C2/1619: 9E CC 7A     STZ $7ACC,X
C2/161C: AD FA 79     LDA $79FA
C2/161F: 0A           ASL 
C2/1620: AA           TAX 
C2/1621: AD 20 27     LDA $2720
C2/1624: 9D DC 7A     STA $7ADC,X
C2/1627: AD 21 27     LDA $2721
C2/162A: 9D DD 7A     STA $7ADD,X
C2/162D: EE FA 79     INC $79FA
C2/1630: 20 E3 98     JSR $98E3
C2/1633: 20 23 99     JSR $9923
C2/1636: 84 12        STY $12
C2/1638: 64 14        STZ $14
C2/163A: A6 0E        LDX $0E
C2/163C: BD 96 40     LDA $4096,X
C2/163F: 29 02        AND #$02
C2/1641: F0 5E        BEQ $16A1
C2/1643: BD 9C 40     LDA $409C,X
C2/1646: C9 55        CMP #$55
C2/1648: D0 57        BNE $16A1
C2/164A: BD 91 40     LDA $4091,X
C2/164D: 99 FC 79     STA $79FC,Y
C2/1650: E8           INX 
C2/1651: C8           INY 
C2/1652: E6 14        INC $14
C2/1654: A5 14        LDA $14
C2/1656: C9 0C        CMP #$0C
C2/1658: D0 F0        BNE $164A
C2/165A: AD 9B 7C     LDA $7C9B
C2/165D: 09 40        ORA #$40
C2/165F: 8D 9B 7C     STA $7C9B
C2/1662: A6 0E        LDX $0E
C2/1664: AD FA 79     LDA $79FA
C2/1667: A8           TAY 
C2/1668: BD 99 40     LDA $4099,X
C2/166B: 99 2D 7B     STA $7B2D,Y
C2/166E: 20 FA 98     JSR $98FA       ; create graphics command
C2/1671: 9E 4C 38     STZ $384C,X
C2/1674: 9E 4D 38     STZ $384D,X
C2/1677: 9E 4E 38     STZ $384E,X
C2/167A: 9E 4F 38     STZ $384F,X
C2/167D: 9E 50 38     STZ $3850,X
C2/1680: AD FA 79     LDA $79FA
C2/1683: AA           TAX 
C2/1684: 9E 1C 7B     STZ $7B1C,X
C2/1687: 9E CC 7A     STZ $7ACC,X
C2/168A: AD FA 79     LDA $79FA
C2/168D: 0A           ASL 
C2/168E: AA           TAX 
C2/168F: AD 20 27     LDA $2720
C2/1692: 9D DC 7A     STA $7ADC,X
C2/1695: AD 21 27     LDA $2721
C2/1698: 9D DD 7A     STA $7ADD,X
C2/169B: EE FA 79     INC $79FA
C2/169E: 20 E3 98     JSR $98E3
C2/16A1: 60           RTS 

; [ battle command $35:  ]

C2/16A2: A9 4A        LDA #$4A
C2/16A4: 8D 33 27     STA $2733
C2/16A7: 4C 2A 14     JMP $142A

; [ get battle command properties ]

C2/16AA: 48           PHA 
C2/16AB: 20 23 99     JSR $9923       ; get pointer to action properties (+$79FC)
C2/16AE: 68           PLA 
C2/16AF: C2 20        REP #$20
C2/16B1: 20 B6 01     JSR $01B6       ; a << 3
C2/16B4: AA           TAX 
C2/16B5: 7B           TDC 
C2/16B6: E2 20        SEP #$20
C2/16B8: 64 0A        STZ $0A
C2/16BA: BF E0 59 D1  LDA $D159E0,X   ; battle command properties
C2/16BE: 99 FC 79     STA $79FC,Y
C2/16C1: E8           INX 
C2/16C2: C8           INY 
C2/16C3: E6 0A        INC $0A
C2/16C5: A5 0A        LDA $0A
C2/16C7: C9 05        CMP #$05        ; copy first 5 bytes
C2/16C9: D0 EF        BNE $16BA
C2/16CB: C8           INY             ; skip 4 bytes
C2/16CC: C8           INY 
C2/16CD: C8           INY 
C2/16CE: C8           INY 
C2/16CF: BF E0 59 D1  LDA $D159E0,X   ; battle command properties
C2/16D3: 99 FC 79     STA $79FC,Y
C2/16D6: E8           INX 
C2/16D7: C8           INY 
C2/16D8: E6 0A        INC $0A
C2/16DA: A5 0A        LDA $0A
C2/16DC: C9 08        CMP #$08        ; copy last 3 bytes
C2/16DE: D0 EF        BNE $16CF
C2/16E0: 60           RTS 

; [  ]

C2/16E1: 48           PHA 
C2/16E2: 20 FA 98     JSR $98FA       ; create graphics command
C2/16E5: 9E 4C 38     STZ $384C,X
C2/16E8: A9 FC        LDA #$FC
C2/16EA: 9D 4D 38     STA $384D,X
C2/16ED: A9 01        LDA #$01
C2/16EF: 9D 4E 38     STA $384E,X
C2/16F2: 68           PLA 
C2/16F3: 9D 4F 38     STA $384F,X
C2/16F6: 9E 50 38     STZ $3850,X
C2/16F9: 60           RTS 

; [  ]

C2/16FA: 8D 21 26     STA $2621
C2/16FD: A9 01        LDA #$01
C2/16FF: 8D 20 26     STA $2620
C2/1702: 4C 2F 99     JMP $992F

; [  ]

C2/1705: AD FA 79     LDA $79FA
C2/1708: AA           TAX 
C2/1709: A4 0C        LDY $0C
C2/170B: B9 00 7A     LDA $7A00,Y
C2/170E: 29 7F        AND #$7F
C2/1710: 9D 2D 7B     STA $7B2D,X
C2/1713: 9E 1C 7B     STZ $7B1C,X
C2/1716: 9E CC 7A     STZ $7ACC,X
C2/1719: 60           RTS 

; [  ]

C2/171A: AD FA 79     LDA $79FA
C2/171D: AA           TAX 
C2/171E: A4 0C        LDY $0C
C2/1720: B9 00 7A     LDA $7A00,Y
C2/1723: 29 7F        AND #$7F
C2/1725: 9D 2D 7B     STA $7B2D,X
C2/1728: AD A0 26     LDA $26A0
C2/172B: 1A           INC 
C2/172C: 9D 1C 7B     STA $7B1C,X
C2/172F: A9 80        LDA #$80
C2/1731: 9D CC 7A     STA $7ACC,X
C2/1734: 60           RTS 

; [  ]

C2/1735: AD FA 79     LDA $79FA
C2/1738: 0A           ASL 
C2/1739: AA           TAX 
C2/173A: AD 20 27     LDA $2720
C2/173D: 9D DC 7A     STA $7ADC,X
C2/1740: 9D FC 7A     STA $7AFC,X
C2/1743: AD 21 27     LDA $2721
C2/1746: 9D DD 7A     STA $7ADD,X
C2/1749: 9D FD 7A     STA $7AFD,X
C2/174C: EE FA 79     INC $79FA
C2/174F: 60           RTS 

; [  ]

C2/1750: AD FA 79     LDA $79FA
C2/1753: 0A           ASL 
C2/1754: AA           TAX 
C2/1755: 9E DC 7A     STZ $7ADC,X
C2/1758: 9E DD 7A     STZ $7ADD,X
C2/175B: EE FA 79     INC $79FA
C2/175E: 60           RTS 

; [  ]

C2/175F: A6 32        LDX $32         ; attacker pointer
C2/1761: BD 59 20     LDA $2059,X     ; cursor position 2 ???
C2/1764: 85 66        STA $66
C2/1766: BD 58 20     LDA $2058,X     ; cursor position 1 ???
C2/1769: 85 65        STA $65
C2/176B: 60           RTS 

; [  ]

C2/176C: AD BE 41     LDA $41BE
C2/176F: D0 03        BNE $1774
C2/1771: 4C 49 18     JMP $1849
C2/1774: AD CC 41     LDA $41CC
C2/1777: 8D 7B 7B     STA $7B7B
C2/177A: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/177D: C2 20        REP #$20
C2/177F: BD 1A 20     LDA $201A,X
C2/1782: CD CE 41     CMP $41CE
C2/1785: D0 15        BNE $179C
C2/1787: BD 1C 20     LDA $201C,X
C2/178A: CD D0 41     CMP $41D0
C2/178D: D0 0D        BNE $179C
C2/178F: BD 0A 20     LDA $200A,X
C2/1792: CD D2 41     CMP $41D2
C2/1795: D0 05        BNE $179C
C2/1797: 7B           TDC 
C2/1798: E2 20        SEP #$20
C2/179A: 80 62        BRA $17FE
C2/179C: 7B           TDC 
C2/179D: E2 20        SEP #$20
C2/179F: 20 74 1C     JSR $1C74
C2/17A2: D0 2D        BNE $17D1
C2/17A4: 20 B3 1C     JSR $1CB3
C2/17A7: 20 9A 1C     JSR $1C9A
C2/17AA: D0 25        BNE $17D1
C2/17AC: A9 05        LDA #$05
C2/17AE: 20 69 00     JSR $0069       ; execute battle graphics function
C2/17B1: A9 06        LDA #$06
C2/17B3: 20 69 00     JSR $0069       ; execute battle graphics function
C2/17B6: C2 20        REP #$20
C2/17B8: A6 32        LDX $32
C2/17BA: BD 1A 20     LDA $201A,X
C2/17BD: 8D CE 41     STA $41CE
C2/17C0: BD 1C 20     LDA $201C,X
C2/17C3: 8D D0 41     STA $41D0
C2/17C6: BD 0A 20     LDA $200A,X
C2/17C9: 8D D2 41     STA $41D2
C2/17CC: 7B           TDC 
C2/17CD: E2 20        SEP #$20
C2/17CF: 80 2D        BRA $17FE
C2/17D1: AD CC 41     LDA $41CC
C2/17D4: 85 70        STA $70
C2/17D6: AD 7D 7B     LDA $7B7D
C2/17D9: F0 09        BEQ $17E4
C2/17DB: 9C 7D 7B     STZ $7B7D
C2/17DE: 20 3A 9F     JSR $9F3A
C2/17E1: 20 6F 9A     JSR $9A6F       ; update character equipment
C2/17E4: AD CC 41     LDA $41CC
C2/17E7: 85 70        STA $70
C2/17E9: AD B0 41     LDA $41B0
C2/17EC: F0 05        BEQ $17F3
C2/17EE: A9 01        LDA #$01
C2/17F0: 20 69 00     JSR $0069       ; execute battle graphics function
C2/17F3: AD B0 41     LDA $41B0
C2/17F6: D0 FB        BNE $17F3
C2/17F8: A9 FF        LDA #$FF
C2/17FA: 8D CC 41     STA $41CC
C2/17FD: 60           RTS 
C2/17FE: AD 42 7C     LDA $7C42
C2/1801: F0 45        BEQ $1848
C2/1803: AD CC 41     LDA $41CC
C2/1806: AA           TAX 
C2/1807: BD 3A 7C     LDA $7C3A,X
C2/180A: F0 06        BEQ $1812
C2/180C: AA           TAX 
C2/180D: BD C2 3E     LDA $3EC2,X
C2/1810: D0 36        BNE $1848
C2/1812: AD CC 41     LDA $41CC
C2/1815: 85 70        STA $70
C2/1817: AD B0 41     LDA $41B0
C2/181A: F0 05        BEQ $1821
C2/181C: A9 01        LDA #$01
C2/181E: 20 69 00     JSR $0069       ; execute battle graphics function
C2/1821: AD B0 41     LDA $41B0
C2/1824: D0 FB        BNE $1821
C2/1826: A9 80        LDA #$80
C2/1828: 8D BF 41     STA $41BF
C2/182B: 9C C0 41     STZ $41C0
C2/182E: 9C C2 41     STZ $41C2
C2/1831: 9C C3 41     STZ $41C3
C2/1834: 9C C4 41     STZ $41C4
C2/1837: 9C C6 41     STZ $41C6
C2/183A: 9C C7 41     STZ $41C7
C2/183D: 9C C9 41     STZ $41C9
C2/1840: 9C CA 41     STZ $41CA
C2/1843: 9C CB 41     STZ $41CB
C2/1846: 80 01        BRA $1849
C2/1848: 60           RTS 
C2/1849: AD CC 41     LDA $41CC
C2/184C: C9 FF        CMP #$FF
C2/184E: F0 03        BEQ $1853
C2/1850: 4C FF 18     JMP $18FF
C2/1853: AD A9 41     LDA $41A9
C2/1856: C9 FF        CMP #$FF
C2/1858: D0 01        BNE $185B
C2/185A: 60           RTS 
C2/185B: 48           PHA 
C2/185C: 7B           TDC 
C2/185D: AA           TAX 
C2/185E: BD AA 41     LDA $41AA,X
C2/1861: 9D A9 41     STA $41A9,X
C2/1864: E8           INX 
C2/1865: E0 04 00     CPX #$0004
C2/1868: D0 F4        BNE $185E
C2/186A: CE AE 41     DEC $41AE
C2/186D: 68           PLA 
C2/186E: 85 70        STA $70
C2/1870: 8D CC 41     STA $41CC
C2/1873: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/1876: AD 51 7C     LDA $7C51
C2/1879: F0 1A        BEQ $1895       ; branch if there are quick turns pending
C2/187B: AD CC 41     LDA $41CC
C2/187E: CD B6 7C     CMP $7CB6
C2/1881: F0 12        BEQ $1895       ; branch if quick target
C2/1883: 20 07 02     JSR $0207       ; get timer data offset
C2/1886: B9 7F 3D     LDA $3D7F,Y
C2/1889: D0 0F        BNE $189A
C2/188B: A9 01        LDA #$01
C2/188D: 99 7F 3D     STA $3D7F,Y
C2/1890: 99 FB 3C     STA $3CFB,Y
C2/1893: 80 05        BRA $189A
C2/1895: 20 74 1C     JSR $1C74
C2/1898: F0 06        BEQ $18A0
C2/189A: A9 FF        LDA #$FF
C2/189C: 8D CC 41     STA $41CC
C2/189F: 60           RTS 
C2/18A0: 64 71        STZ $71
C2/18A2: 20 9A 1C     JSR $1C9A
C2/18A5: D0 F3        BNE $189A
C2/18A7: 20 B3 1C     JSR $1CB3
C2/18AA: A9 01        LDA #$01
C2/18AC: 8D D4 3E     STA $3ED4
C2/18AF: AD D6 3E     LDA $3ED6       ; battle tick duration
C2/18B2: 8D D5 3E     STA $3ED5
C2/18B5: C2 20        REP #$20
C2/18B7: A6 32        LDX $32
C2/18B9: BD 1A 20     LDA $201A,X
C2/18BC: 8D CE 41     STA $41CE
C2/18BF: BD 1C 20     LDA $201C,X
C2/18C2: 8D D0 41     STA $41D0
C2/18C5: BD 0A 20     LDA $200A,X
C2/18C8: 8D D2 41     STA $41D2
C2/18CB: 9E 1E 20     STZ $201E,X
C2/18CE: 7B           TDC 
C2/18CF: E2 20        SEP #$20
C2/18D1: 20 0B 19     JSR $190B
C2/18D4: A9 01        LDA #$01
C2/18D6: 8D 4E 7C     STA $7C4E
C2/18D9: AD EF 3E     LDA $3EEF
C2/18DC: 10 04        BPL $18E2
C2/18DE: 9C BE 41     STZ $41BE
C2/18E1: 60           RTS 
C2/18E2: AD CC 41     LDA $41CC
C2/18E5: 20 07 02     JSR $0207       ; get timer data offset
C2/18E8: B9 FB 3C     LDA $3CFB,Y
C2/18EB: F0 08        BEQ $18F5
C2/18ED: A9 FF        LDA #$FF
C2/18EF: 8D CC 41     STA $41CC
C2/18F2: 4C 53 18     JMP $1853
C2/18F5: 7B           TDC 
C2/18F6: 20 69 00     JSR $0069       ; execute battle graphics function
C2/18F9: AD B0 41     LDA $41B0
C2/18FC: F0 FB        BEQ $18F9
C2/18FE: 60           RTS 
C2/18FF: 9C D4 3E     STZ $3ED4
C2/1902: 20 26 19     JSR $1926
C2/1905: A9 FF        LDA #$FF
C2/1907: 8D CC 41     STA $41CC
C2/190A: 60           RTS 

; [  ]

C2/190B: 9C 42 7C     STZ $7C42
C2/190E: AD CC 41     LDA $41CC
C2/1911: AA           TAX 
C2/1912: BD 3A 7C     LDA $7C3A,X
C2/1915: F0 0B        BEQ $1922
C2/1917: A8           TAY 
C2/1918: B9 C2 3E     LDA $3EC2,Y
C2/191B: F0 05        BEQ $1922
C2/191D: A9 01        LDA #$01
C2/191F: 8D 42 7C     STA $7C42
C2/1922: 8D 4D 7C     STA $7C4D
C2/1925: 60           RTS 

; [  ]

C2/1926: AD EF 3E     LDA $3EEF
C2/1929: 10 03        BPL $192E
C2/192B: 20 51 1C     JSR $1C51
C2/192E: AD CC 41     LDA $41CC       ; selected character
C2/1931: 8D 7B 7B     STA $7B7B
C2/1934: AD 7D 7B     LDA $7B7D
C2/1937: F0 09        BEQ $1942
C2/1939: 9C 7D 7B     STZ $7B7D
C2/193C: 20 3A 9F     JSR $9F3A
C2/193F: 20 6F 9A     JSR $9A6F       ; update character equipment
C2/1942: AD CC 41     LDA $41CC
C2/1945: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/1948: BD 1A 20     LDA $201A,X
C2/194B: 29 C0        AND #$C0
C2/194D: D0 18        BNE $1967
C2/194F: BD 1B 20     LDA $201B,X
C2/1952: 1D 71 20     ORA $2071,X
C2/1955: 29 78        AND #$78
C2/1957: D0 0E        BNE $1967
C2/1959: BD 1C 20     LDA $201C,X
C2/195C: 29 10        AND #$10
C2/195E: D0 07        BNE $1967
C2/1960: BD 1D 20     LDA $201D,X
C2/1963: 29 80        AND #$80
C2/1965: F0 09        BEQ $1970
C2/1967: AD CC 41     LDA $41CC
C2/196A: AA           TAX 
C2/196B: 9E 3A 7C     STZ $7C3A,X
C2/196E: 80 53        BRA $19C3
C2/1970: AD CC 41     LDA $41CC
C2/1973: CD C1 41     CMP $41C1
C2/1976: F0 0C        BEQ $1984
C2/1978: AD EF 3E     LDA $3EEF
C2/197B: 30 07        BMI $1984
C2/197D: A9 0D        LDA #$0D
C2/197F: 20 69 00     JSR $0069       ; execute battle graphics function
C2/1982: 80 FE        BRA $1982
C2/1984: AD CC 41     LDA $41CC
C2/1987: AA           TAX 
C2/1988: BD 3A 7C     LDA $7C3A,X
C2/198B: F0 58        BEQ $19E5
C2/198D: A8           TAY 
C2/198E: B9 C2 3E     LDA $3EC2,Y
C2/1991: F0 30        BEQ $19C3
C2/1993: FE 3E 7C     INC $7C3E,X
C2/1996: 38           SEC 
C2/1997: BD 3A 7C     LDA $7C3A,X
C2/199A: E9 04        SBC #$04
C2/199C: 85 0E        STA $0E
C2/199E: A8           TAY 
C2/199F: AD CC 41     LDA $41CC
C2/19A2: AA           TAX 
C2/19A3: 18           CLC 
C2/19A4: BF DB EE D0  LDA $D0EEDB,X   ; pointer to attack list
C2/19A8: 6D C4 41     ADC $41C4       ; cursor position
C2/19AB: AA           TAX 
C2/19AC: BD DC 37     LDA $37DC,X     ; control attack
C2/19AF: 99 43 7C     STA $7C43,Y
C2/19B2: 38           SEC 
C2/19B3: A5 0E        LDA $0E
C2/19B5: 0A           ASL 
C2/19B6: AA           TAX 
C2/19B7: AD C3 41     LDA $41C3
C2/19BA: 9D 2A 7C     STA $7C2A,X
C2/19BD: AD C2 41     LDA $41C2
C2/19C0: 9D 2B 7C     STA $7C2B,X
C2/19C3: A9 80        LDA #$80
C2/19C5: 8D BF 41     STA $41BF
C2/19C8: 9C C0 41     STZ $41C0
C2/19CB: 9C C2 41     STZ $41C2
C2/19CE: 9C C3 41     STZ $41C3
C2/19D1: 9C C4 41     STZ $41C4
C2/19D4: 9C C6 41     STZ $41C6
C2/19D7: 9C C7 41     STZ $41C7
C2/19DA: 9C C9 41     STZ $41C9
C2/19DD: 9C CA 41     STZ $41CA
C2/19E0: 9C CB 41     STZ $41CB
C2/19E3: 80 05        BRA $19EA
C2/19E5: AD 4D 7C     LDA $7C4D
C2/19E8: D0 D9        BNE $19C3
C2/19EA: AD CC 41     LDA $41CC
C2/19ED: AA           TAX 
C2/19EE: 86 2A        STX $2A
C2/19F0: A2 8A 02     LDX #$028A
C2/19F3: 86 2C        STX $2C
C2/19F5: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/19F8: C2 20        REP #$20
C2/19FA: 18           CLC 
C2/19FB: A5 2E        LDA $2E
C2/19FD: 69 34 2D     ADC #$2D34
C2/1A00: 85 45        STA $45
C2/1A02: 7B           TDC 
C2/1A03: E2 20        SEP #$20
C2/1A05: A6 32        LDX $32
C2/1A07: BD 1B 20     LDA $201B,X
C2/1A0A: 1D 71 20     ORA $2071,X
C2/1A0D: 29 18        AND #$18
C2/1A0F: D0 64        BNE $1A75
C2/1A11: AD C0 41     LDA $41C0       ; selected battle command
C2/1A14: 9D 57 20     STA $2057,X
C2/1A17: AD C2 41     LDA $41C2       ; cursor 1 position
C2/1A1A: 9D 58 20     STA $2058,X
C2/1A1D: AD C3 41     LDA $41C3       ; cursor 2 position
C2/1A20: 9D 59 20     STA $2059,X
C2/1A23: AD C4 41     LDA $41C4       ; cursor 3 position
C2/1A26: 9D 5A 20     STA $205A,X
C2/1A29: AD BF 41     LDA $41BF       ; cursor flags ???
C2/1A2C: 9D 56 20     STA $2056,X
C2/1A2F: 29 20        AND #$20
C2/1A31: F0 33        BEQ $1A66
C2/1A33: AD C4 41     LDA $41C4
C2/1A36: A8           TAY 
C2/1A37: B1 45        LDA ($45),Y
C2/1A39: 9D 5A 20     STA $205A,X
C2/1A3C: AD BF 41     LDA $41BF
C2/1A3F: 29 08        AND #$08
C2/1A41: F0 23        BEQ $1A66
C2/1A43: AD C7 41     LDA $41C7
C2/1A46: 9D 5C 20     STA $205C,X
C2/1A49: AD C9 41     LDA $41C9
C2/1A4C: 9D 5D 20     STA $205D,X
C2/1A4F: AD CA 41     LDA $41CA
C2/1A52: 9D 5E 20     STA $205E,X
C2/1A55: AD CB 41     LDA $41CB
C2/1A58: A8           TAY 
C2/1A59: B1 45        LDA ($45),Y
C2/1A5B: 9D 5F 20     STA $205F,X
C2/1A5E: AD C6 41     LDA $41C6
C2/1A61: 9D 5B 20     STA $205B,X
C2/1A64: 80 0F        BRA $1A75
C2/1A66: 9E 5C 20     STZ $205C,X
C2/1A69: 9E 5D 20     STZ $205D,X
C2/1A6C: 9E 5D 20     STZ $205D,X
C2/1A6F: 9E 5F 20     STZ $205F,X
C2/1A72: 9E 5B 20     STZ $205B,X
C2/1A75: AD C0 41     LDA $41C0      ; selected battle command
C2/1A78: 85 24        STA $24
C2/1A7A: A9 08        LDA #$08
C2/1A7C: 85 25        STA $25
C2/1A7E: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/1A81: A6 26        LDX $26
C2/1A83: A4 32        LDY $32
C2/1A85: BF E2 59 D1  LDA $D159E2,X   ; action flags
C2/1A89: 99 1E 20     STA $201E,Y
C2/1A8C: BF E3 59 D1  LDA $D159E3,X   ; damage modifier flags
C2/1A90: 99 1F 20     STA $201F,Y
C2/1A93: AD C0 41     LDA $41C0
C2/1A96: C9 2C        CMP #$2C
C2/1A98: 90 0C        BCC $1AA6
C2/1A9A: C9 4E        CMP #$4E
C2/1A9C: B0 08        BCS $1AA6
C2/1A9E: B9 56 20     LDA $2056,Y
C2/1AA1: 09 01        ORA #$01
C2/1AA3: 99 56 20     STA $2056,Y
C2/1AA6: AD C0 41     LDA $41C0
C2/1AA9: AA           TAX 
C2/1AAA: BF A0 5D D1  LDA $D15DA0,X
C2/1AAE: 30 36        BMI $1AE6
C2/1AB0: 48           PHA 
C2/1AB1: AD C0 41     LDA $41C0
C2/1AB4: C9 11        CMP #$11
C2/1AB6: F0 19        BEQ $1AD1
C2/1AB8: C9 20        CMP #$20
C2/1ABA: F0 15        BEQ $1AD1
C2/1ABC: C9 1F        CMP #$1F
C2/1ABE: D0 22        BNE $1AE2
C2/1AC0: AD CB 41     LDA $41CB
C2/1AC3: 48           PHA 
C2/1AC4: AA           TAX 
C2/1AC5: BD 34 27     LDA $2734,X
C2/1AC8: A6 32        LDX $32
C2/1ACA: 9D 5F 20     STA $205F,X
C2/1ACD: 68           PLA 
C2/1ACE: 20 36 1C     JSR $1C36
C2/1AD1: AD C4 41     LDA $41C4
C2/1AD4: 48           PHA 
C2/1AD5: AA           TAX 
C2/1AD6: BD 34 27     LDA $2734,X
C2/1AD9: A6 32        LDX $32
C2/1ADB: 9D 5A 20     STA $205A,X
C2/1ADE: 68           PLA 
C2/1ADF: 20 36 1C     JSR $1C36
C2/1AE2: 68           PLA 
C2/1AE3: 4C F7 1B     JMP $1BF7
C2/1AE6: AD BF 41     LDA $41BF
C2/1AE9: 29 08        AND #$08
C2/1AEB: F0 03        BEQ $1AF0
C2/1AED: 4C 7C 1B     JMP $1B7C
C2/1AF0: AD BF 41     LDA $41BF
C2/1AF3: 29 40        AND #$40
C2/1AF5: D0 52        BNE $1B49
C2/1AF7: AD BF 41     LDA $41BF
C2/1AFA: 29 20        AND #$20
C2/1AFC: F0 03        BEQ $1B01
C2/1AFE: 4C 7C 1B     JMP $1B7C
C2/1B01: AD BF 41     LDA $41BF
C2/1B04: 29 10        AND #$10
C2/1B06: F0 03        BEQ $1B0B
C2/1B08: 4C BE 1B     JMP $1BBE
C2/1B0B: 64 0E        STZ $0E
C2/1B0D: AD CC 41     LDA $41CC
C2/1B10: 85 24        STA $24
C2/1B12: A9 54        LDA #$54
C2/1B14: 85 25        STA $25
C2/1B16: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/1B19: A4 26        LDY $26
C2/1B1B: A6 32        LDX $32
C2/1B1D: BD 13 20     LDA $2013,X
C2/1B20: F0 0C        BEQ $1B2E
C2/1B22: B9 85 40     LDA $4085,Y
C2/1B25: 29 03        AND #$03
C2/1B27: AA           TAX 
C2/1B28: BF EE EC D0  LDA $D0ECEE,X
C2/1B2C: 85 0E        STA $0E
C2/1B2E: A6 32        LDX $32
C2/1B30: BD 14 20     LDA $2014,X
C2/1B33: F0 0F        BEQ $1B44
C2/1B35: B9 91 40     LDA $4091,Y
C2/1B38: 29 03        AND #$03
C2/1B3A: AA           TAX 
C2/1B3B: 18           CLC 
C2/1B3C: BF EE EC D0  LDA $D0ECEE,X
C2/1B40: 65 0E        ADC $0E
C2/1B42: 85 0E        STA $0E
C2/1B44: A5 0E        LDA $0E
C2/1B46: 4C F7 1B     JMP $1BF7
C2/1B49: AD C4 41     LDA $41C4
C2/1B4C: AA           TAX 
C2/1B4D: BD 34 27     LDA $2734,X
C2/1B50: A6 32        LDX $32
C2/1B52: 9D 5A 20     STA $205A,X
C2/1B55: 38           SEC 
C2/1B56: E9 E0        SBC #$E0
C2/1B58: C2 20        REP #$20
C2/1B5A: 20 B6 01     JSR $01B6       ; a << 3
C2/1B5D: AA           TAX 
C2/1B5E: 7B           TDC 
C2/1B5F: E2 20        SEP #$20
C2/1B61: BF 82 0A D1  LDA $D10A82,X
C2/1B65: 29 08        AND #$08
C2/1B67: D0 06        BNE $1B6F
C2/1B69: AD C4 41     LDA $41C4
C2/1B6C: 20 36 1C     JSR $1C36
C2/1B6F: BF 80 0A D1  LDA $D10A80,X
C2/1B73: 29 03        AND #$03
C2/1B75: AA           TAX 
C2/1B76: BF EE EC D0  LDA $D0ECEE,X
C2/1B7A: 80 7B        BRA $1BF7
C2/1B7C: 64 0E        STZ $0E
C2/1B7E: AD C4 41     LDA $41C4
C2/1B81: C2 20        REP #$20
C2/1B83: 20 B6 01     JSR $01B6       ; a << 3
C2/1B86: AA           TAX 
C2/1B87: 7B           TDC 
C2/1B88: E2 20        SEP #$20
C2/1B8A: BF 80 0B D1  LDA $D10B80,X
C2/1B8E: 29 03        AND #$03
C2/1B90: AA           TAX 
C2/1B91: BF EE EC D0  LDA $D0ECEE,X
C2/1B95: 85 0E        STA $0E
C2/1B97: AD BF 41     LDA $41BF
C2/1B9A: 29 08        AND #$08
C2/1B9C: F0 1C        BEQ $1BBA
C2/1B9E: AD CB 41     LDA $41CB
C2/1BA1: C2 20        REP #$20
C2/1BA3: 20 B6 01     JSR $01B6       ; a << 3
C2/1BA6: AA           TAX 
C2/1BA7: 7B           TDC 
C2/1BA8: E2 20        SEP #$20
C2/1BAA: BF 80 0B D1  LDA $D10B80,X
C2/1BAE: 29 03        AND #$03
C2/1BB0: AA           TAX 
C2/1BB1: 18           CLC 
C2/1BB2: BF EE EC D0  LDA $D0ECEE,X
C2/1BB6: 65 0E        ADC $0E
C2/1BB8: 85 0E        STA $0E
C2/1BBA: A5 0E        LDA $0E
C2/1BBC: 80 39        BRA $1BF7
C2/1BBE: AD CC 41     LDA $41CC
C2/1BC1: 85 24        STA $24
C2/1BC3: A9 54        LDA #$54
C2/1BC5: 85 25        STA $25
C2/1BC7: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/1BCA: A4 26        LDY $26
C2/1BCC: AD C4 41     LDA $41C4
C2/1BCF: F0 0B        BEQ $1BDC
C2/1BD1: C2 20        REP #$20
C2/1BD3: 98           TYA 
C2/1BD4: 18           CLC 
C2/1BD5: 69 0C 00     ADC #$000C
C2/1BD8: A8           TAY 
C2/1BD9: 7B           TDC 
C2/1BDA: E2 20        SEP #$20
C2/1BDC: B9 8B 40     LDA $408B,Y
C2/1BDF: 29 7F        AND #$7F
C2/1BE1: F0 14        BEQ $1BF7
C2/1BE3: C2 20        REP #$20
C2/1BE5: 20 B6 01     JSR $01B6       ; a << 3
C2/1BE8: AA           TAX 
C2/1BE9: 7B           TDC 
C2/1BEA: E2 20        SEP #$20
C2/1BEC: BF 80 0B D1  LDA $D10B80,X
C2/1BF0: 29 03        AND #$03
C2/1BF2: AA           TAX 
C2/1BF3: BF EE EC D0  LDA $D0ECEE,X
C2/1BF7: 48           PHA 
C2/1BF8: AD CC 41     LDA $41CC
C2/1BFB: 20 07 02     JSR $0207       ; get timer data offset
C2/1BFE: A6 32        LDX $32
C2/1C00: 68           PLA 
C2/1C01: 20 63 61     JSR $6163
C2/1C04: 99 7F 3D     STA $3D7F,Y
C2/1C07: A9 41        LDA #$41
C2/1C09: 99 FB 3C     STA $3CFB,Y
C2/1C0C: A9 80        LDA #$80
C2/1C0E: 8D BF 41     STA $41BF
C2/1C11: 9C C0 41     STZ $41C0
C2/1C14: 9C C1 41     STZ $41C1
C2/1C17: 9C C2 41     STZ $41C2
C2/1C1A: 9C C3 41     STZ $41C3
C2/1C1D: 9C C4 41     STZ $41C4
C2/1C20: 9C C5 41     STZ $41C5
C2/1C23: 9C C6 41     STZ $41C6
C2/1C26: 9C C7 41     STZ $41C7
C2/1C29: 9C C8 41     STZ $41C8
C2/1C2C: 9C C9 41     STZ $41C9
C2/1C2F: 9C CA 41     STZ $41CA
C2/1C32: 9C CB 41     STZ $41CB
C2/1C35: 60           RTS 

; [  ]

C2/1C36: AA           TAX 
C2/1C37: BD 34 28     LDA $2834,X
C2/1C3A: 3A           DEC 
C2/1C3B: 9D 34 28     STA $2834,X
C2/1C3E: D0 10        BNE $1C50
C2/1C40: 9E 34 27     STZ $2734,X
C2/1C43: 9E 34 2A     STZ $2A34,X
C2/1C46: A9 5A        LDA #$5A
C2/1C48: 9D 34 2B     STA $2B34,X
C2/1C4B: A9 AA        LDA #$AA
C2/1C4D: 9D 34 2C     STA $2C34,X
C2/1C50: 60           RTS 

; [  ]

C2/1C51: A9 80        LDA #$80
C2/1C53: 8D BF 41     STA $41BF
C2/1C56: 8D C2 41     STA $41C2
C2/1C59: A9 54        LDA #$54
C2/1C5B: 8D C0 41     STA $41C0
C2/1C5E: 9C C3 41     STZ $41C3
C2/1C61: 9C C4 41     STZ $41C4
C2/1C64: 9C C6 41     STZ $41C6
C2/1C67: 9C C7 41     STZ $41C7
C2/1C6A: 9C C9 41     STZ $41C9
C2/1C6D: 9C CA 41     STZ $41CA
C2/1C70: 9C CB 41     STZ $41CB
C2/1C73: 60           RTS 

; [  ]

C2/1C74: A6 32        LDX $32
C2/1C76: BD 1A 20     LDA $201A,X
C2/1C79: 1D 70 20     ORA $2070,X
C2/1C7C: 29 C2        AND #$C2
C2/1C7E: D0 19        BNE $1C99
C2/1C80: BD 1B 20     LDA $201B,X
C2/1C83: 1D 71 20     ORA $2071,X
C2/1C86: 29 78        AND #$78
C2/1C88: D0 0F        BNE $1C99
C2/1C8A: BD 1C 20     LDA $201C,X
C2/1C8D: 29 10        AND #$10
C2/1C8F: D0 08        BNE $1C99
C2/1C91: BD 1D 20     LDA $201D,X
C2/1C94: 29 84        AND #$84
C2/1C96: D0 01        BNE $1C99
C2/1C98: 7B           TDC 
C2/1C99: 60           RTS 

; [  ]

C2/1C9A: A6 32        LDX $32
C2/1C9C: BD 21 20     LDA $2021,X
C2/1C9F: 29 08        AND #$08
C2/1CA1: F0 05        BEQ $1CA8
C2/1CA3: AD EF 3E     LDA $3EEF
C2/1CA6: 10 02        BPL $1CAA       ; branch if not credits
C2/1CA8: 7B           TDC 
C2/1CA9: 60           RTS 
C2/1CAA: BD 71 20     LDA $2071,X
C2/1CAD: 09 08        ORA #$08
C2/1CAF: 9D 71 20     STA $2071,X
C2/1CB2: 60           RTS 

; [  ]

C2/1CB3: 7B           TDC 
C2/1CB4: AA           TAX 
C2/1CB5: 86 16        STX $16
C2/1CB7: AD E6 7B     LDA $7BE6
C2/1CBA: 29 40        AND #$40
C2/1CBC: F0 05        BEQ $1CC3
C2/1CBE: A2 80 00     LDX #$0080
C2/1CC1: 86 16        STX $16
C2/1CC3: AD CC 41     LDA $41CC
C2/1CC6: 20 F8 01     JSR $01F8       ; get spell list offset
C2/1CC9: C2 20        REP #$20
C2/1CCB: 7B           TDC 
C2/1CCC: 85 12        STA $12
C2/1CCE: 85 14        STA $14
C2/1CD0: A6 32        LDX $32
C2/1CD2: BD 0A 20     LDA $200A,X
C2/1CD5: 85 0E        STA $0E
C2/1CD7: BD 1C 20     LDA $201C,X
C2/1CDA: 1D 72 20     ORA $2072,X
C2/1CDD: 85 22        STA $22
C2/1CDF: BD 1A 20     LDA $201A,X
C2/1CE2: 1D 70 20     ORA $2070,X
C2/1CE5: 85 10        STA $10
C2/1CE7: 29 00 04     AND #$0400
C2/1CEA: F0 05        BEQ $1CF1
C2/1CEC: A9 80 00     LDA #$0080
C2/1CEF: 85 12        STA $12
C2/1CF1: BD 1A 20     LDA $201A,X
C2/1CF4: 1D 70 20     ORA $2070,X
C2/1CF7: 29 20 00     AND #$0020
C2/1CFA: F0 05        BEQ $1D01
C2/1CFC: A9 80 00     LDA #$0080
C2/1CFF: 85 14        STA $14
C2/1D01: 7B           TDC 
C2/1D02: AA           TAX 
C2/1D03: B9 3C 2F     LDA $2F3C,Y
C2/1D06: 29 01 00     AND #$0001
C2/1D09: D0 57        BNE $1D62
C2/1D0B: B9 38 2E     LDA $2E38,Y
C2/1D0E: 29 FF 00     AND #$00FF
C2/1D11: C5 0E        CMP $0E
C2/1D13: F0 0D        BEQ $1D22
C2/1D15: 90 0B        BCC $1D22
C2/1D17: B9 3C 2F     LDA $2F3C,Y
C2/1D1A: 09 80 00     ORA #$0080
C2/1D1D: 99 3C 2F     STA $2F3C,Y
C2/1D20: 80 40        BRA $1D62
C2/1D22: B9 3C 2F     LDA $2F3C,Y
C2/1D25: 29 7F FF     AND #$FF7F
C2/1D28: 99 3C 2F     STA $2F3C,Y
C2/1D2B: B9 34 2D     LDA $2D34,Y
C2/1D2E: 29 FF 00     AND #$00FF
C2/1D31: C9 80 00     CMP #$0080
C2/1D34: B0 2C        BCS $1D62
C2/1D36: B9 3C 2F     LDA $2F3C,Y
C2/1D39: 05 12        ORA $12
C2/1D3B: 05 14        ORA $14
C2/1D3D: 05 16        ORA $16
C2/1D3F: 99 3C 2F     STA $2F3C,Y
C2/1D42: A5 16        LDA $16
C2/1D44: D0 1C        BNE $1D62
C2/1D46: A5 12        LDA $12
C2/1D48: D0 18        BNE $1D62
C2/1D4A: A5 14        LDA $14
C2/1D4C: F0 14        BEQ $1D62
C2/1D4E: B9 34 2D     LDA $2D34,Y     ; spell index
C2/1D51: 29 FF 00     AND #$00FF
C2/1D54: C9 29 00     CMP #$0029
C2/1D57: D0 09        BNE $1D62       ; branch if not toad
C2/1D59: B9 3C 2F     LDA $2F3C,Y
C2/1D5C: 29 7F FF     AND #$FF7F
C2/1D5F: 99 3C 2F     STA $2F3C,Y
C2/1D62: C8           INY 
C2/1D63: E8           INX 
C2/1D64: E0 82 00     CPX #$0082
C2/1D67: D0 9A        BNE $1D03
C2/1D69: 7B           TDC 
C2/1D6A: E2 20        SEP #$20
C2/1D6C: AD CC 41     LDA $41CC
C2/1D6F: 85 24        STA $24
C2/1D71: A9 14        LDA #$14
C2/1D73: 85 25        STA $25
C2/1D75: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/1D78: 7B           TDC 
C2/1D79: AA           TAX 
C2/1D7A: 86 0E        STX $0E
C2/1D7C: A4 26        LDY $26
C2/1D7E: C2 20        REP #$20
C2/1D80: B9 5C 37     LDA $375C,Y
C2/1D83: 29 FF 00     AND #$00FF
C2/1D86: 85 12        STA $12
C2/1D88: F0 18        BEQ $1DA2
C2/1D8A: 0A           ASL 
C2/1D8B: AA           TAX 
C2/1D8C: BF E0 5C D1  LDA $D15CE0,X
C2/1D90: 25 10        AND $10
C2/1D92: D0 0E        BNE $1DA2
C2/1D94: A5 12        LDA $12
C2/1D96: C9 26 00     CMP #$0026
C2/1D99: F0 12        BEQ $1DAD
C2/1D9B: A5 22        LDA $22
C2/1D9D: 29 00 01     AND #$0100
C2/1DA0: F0 0B        BEQ $1DAD
C2/1DA2: B9 6C 37     LDA $376C,Y
C2/1DA5: 09 80 00     ORA #$0080
C2/1DA8: 99 6C 37     STA $376C,Y
C2/1DAB: 80 09        BRA $1DB6
C2/1DAD: B9 6C 37     LDA $376C,Y
C2/1DB0: 29 7F FF     AND #$FF7F
C2/1DB3: 99 6C 37     STA $376C,Y
C2/1DB6: C8           INY 
C2/1DB7: E6 0E        INC $0E
C2/1DB9: A5 0E        LDA $0E
C2/1DBB: C9 04 00     CMP #$0004
C2/1DBE: D0 C0        BNE $1D80
C2/1DC0: 7B           TDC 
C2/1DC1: E2 20        SEP #$20
C2/1DC3: 60           RTS 

; [  ]

C2/1DC4: 7B           TDC 
C2/1DC5: AA           TAX 
C2/1DC6: 86 3D        STX $3D
C2/1DC8: 86 3F        STX $3F
C2/1DCA: A6 3D        LDX $3D
C2/1DCC: BD 04 7C     LDA $7C04,X
C2/1DCF: F0 1A        BEQ $1DEB
C2/1DD1: A6 3F        LDX $3F
C2/1DD3: BD 1C 20     LDA $201C,X
C2/1DD6: 29 10        AND #$10
C2/1DD8: D0 43        BNE $1E1D
C2/1DDA: BD 1B 20     LDA $201B,X
C2/1DDD: 1D 71 20     ORA $2071,X
C2/1DE0: 29 60        AND #$60
C2/1DE2: D0 39        BNE $1E1D
C2/1DE4: A6 3D        LDX $3D
C2/1DE6: DE 04 7C     DEC $7C04,X
C2/1DE9: 80 32        BRA $1E1D
C2/1DEB: A6 3F        LDX $3F
C2/1DED: A9 01        LDA #$01
C2/1DEF: 9D 61 20     STA $2061,X
C2/1DF2: BD 1A 20     LDA $201A,X
C2/1DF5: 1D 70 20     ORA $2070,X
C2/1DF8: 29 02        AND #$02
C2/1DFA: F0 05        BEQ $1E01
C2/1DFC: 20 2F 1E     JSR $1E2F
C2/1DFF: 80 1C        BRA $1E1D
C2/1E01: BD 1B 20     LDA $201B,X
C2/1E04: 1D 71 20     ORA $2071,X
C2/1E07: 29 10        AND #$10
C2/1E09: F0 05        BEQ $1E10
C2/1E0B: 20 62 1E     JSR $1E62
C2/1E0E: 80 0D        BRA $1E1D
C2/1E10: BD 1B 20     LDA $201B,X
C2/1E13: 1D 71 20     ORA $2071,X
C2/1E16: 29 08        AND #$08
C2/1E18: F0 03        BEQ $1E1D
C2/1E1A: 20 80 1F     JSR $1F80
C2/1E1D: A6 3F        LDX $3F
C2/1E1F: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/1E22: 86 3F        STX $3F
C2/1E24: EE 3D 00     INC $003D
C2/1E27: AD 3D 00     LDA $003D
C2/1E2A: C9 04        CMP #$04
C2/1E2C: D0 9C        BNE $1DCA
C2/1E2E: 60           RTS 

; [  ]

C2/1E2F: A9 80        LDA #$80
C2/1E31: 9D 56 20     STA $2056,X
C2/1E34: A9 05        LDA #$05
C2/1E36: 9D 57 20     STA $2057,X
C2/1E39: 9E 58 20     STZ $2058,X
C2/1E3C: 9E 5A 20     STZ $205A,X
C2/1E3F: 9E 5B 20     STZ $205B,X
C2/1E42: 9E 5C 20     STZ $205C,X
C2/1E45: 9E 5D 20     STZ $205D,X
C2/1E48: 9E 5E 20     STZ $205E,X
C2/1E4B: 9E 5F 20     STZ $205F,X
C2/1E4E: DA           PHX 
C2/1E4F: 7B           TDC 
C2/1E50: AA           TAX 
C2/1E51: A9 03        LDA #$03
C2/1E53: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1E56: AA           TAX 
C2/1E57: 7B           TDC 
C2/1E58: 20 D6 01     JSR $01D6       ; set bit x
C2/1E5B: FA           PLX 
C2/1E5C: 9D 59 20     STA $2059,X
C2/1E5F: 4C B3 1F     JMP $1FB3

; [  ]

C2/1E62: BD 3D 20     LDA $203D,X
C2/1E65: 29 0F        AND #$0F
C2/1E67: 1D 3E 20     ORA $203E,X
C2/1E6A: F0 07        BEQ $1E73
C2/1E6C: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/1E6F: C9 32        CMP #$32
C2/1E71: 90 35        BCC $1EA8
C2/1E73: A6 3F        LDX $3F
C2/1E75: A9 80        LDA #$80
C2/1E77: 9D 56 20     STA $2056,X
C2/1E7A: A9 05        LDA #$05
C2/1E7C: 9D 57 20     STA $2057,X
C2/1E7F: 9E 58 20     STZ $2058,X
C2/1E82: 9E 5A 20     STZ $205A,X
C2/1E85: 9E 5B 20     STZ $205B,X
C2/1E88: 9E 5C 20     STZ $205C,X
C2/1E8B: 9E 5D 20     STZ $205D,X
C2/1E8E: 9E 5E 20     STZ $205E,X
C2/1E91: 9E 5F 20     STZ $205F,X
C2/1E94: DA           PHX 
C2/1E95: 7B           TDC 
C2/1E96: AA           TAX 
C2/1E97: A9 03        LDA #$03
C2/1E99: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1E9C: AA           TAX 
C2/1E9D: 7B           TDC 
C2/1E9E: 20 D6 01     JSR $01D6       ; set bit x
C2/1EA1: FA           PLX 
C2/1EA2: 9D 59 20     STA $2059,X
C2/1EA5: 4C 7D 1F     JMP $1F7D
C2/1EA8: A5 3D        LDA $3D
C2/1EAA: AA           TAX 
C2/1EAB: 86 2A        STX $2A
C2/1EAD: A2 8A 02     LDX #$028A
C2/1EB0: 86 2C        STX $2C
C2/1EB2: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/1EB5: A6 2E        LDX $2E
C2/1EB7: 86 41        STX $41
C2/1EB9: 64 0E        STZ $0E
C2/1EBB: BD 46 2D     LDA $2D46,X
C2/1EBE: C9 46        CMP #$46
C2/1EC0: F0 04        BEQ $1EC6
C2/1EC2: C9 FF        CMP #$FF
C2/1EC4: D0 0B        BNE $1ED1
C2/1EC6: E8           INX 
C2/1EC7: E6 0E        INC $0E
C2/1EC9: A5 0E        LDA $0E
C2/1ECB: C9 36        CMP #$36
C2/1ECD: D0 EC        BNE $1EBB
C2/1ECF: 80 A2        BRA $1E73
C2/1ED1: A2 12 00     LDX #$0012
C2/1ED4: A9 47        LDA #$47
C2/1ED6: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1ED9: C2 20        REP #$20
C2/1EDB: 65 41        ADC $41
C2/1EDD: AA           TAX 
C2/1EDE: 7B           TDC 
C2/1EDF: E2 20        SEP #$20
C2/1EE1: BD 34 2D     LDA $2D34,X
C2/1EE4: C9 FF        CMP #$FF
C2/1EE6: F0 E9        BEQ $1ED1
C2/1EE8: C9 46        CMP #$46
C2/1EEA: F0 E5        BEQ $1ED1
C2/1EEC: 48           PHA 
C2/1EED: C2 20        REP #$20
C2/1EEF: 20 B6 01     JSR $01B6       ; a << 3
C2/1EF2: AA           TAX 
C2/1EF3: 7B           TDC 
C2/1EF4: E2 20        SEP #$20
C2/1EF6: BF 80 0B D1  LDA $D10B80,X
C2/1EFA: 8D A0 26     STA $26A0
C2/1EFD: 7B           TDC 
C2/1EFE: A8           TAY 
C2/1EFF: 84 16        STY $16
C2/1F01: AD A0 26     LDA $26A0
C2/1F04: D0 12        BNE $1F18
C2/1F06: C2 20        REP #$20
C2/1F08: A5 3F        LDA $3F
C2/1F0A: 20 BB 01     JSR $01BB       ; a >> 7
C2/1F0D: AA           TAX 
C2/1F0E: 7B           TDC 
C2/1F0F: E2 20        SEP #$20
C2/1F11: 20 D6 01     JSR $01D6       ; set bit x
C2/1F14: 85 16        STA $16
C2/1F16: 80 3C        BRA $1F54
C2/1F18: 29 40        AND #$40
C2/1F1A: D0 27        BNE $1F43
C2/1F1C: AD A0 26     LDA $26A0
C2/1F1F: 29 08        AND #$08
C2/1F21: D0 10        BNE $1F33
C2/1F23: 7B           TDC 
C2/1F24: AA           TAX 
C2/1F25: A9 07        LDA #$07
C2/1F27: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1F2A: AA           TAX 
C2/1F2B: 7B           TDC 
C2/1F2C: 20 D6 01     JSR $01D6       ; set bit x
C2/1F2F: 85 17        STA $17
C2/1F31: 80 21        BRA $1F54
C2/1F33: 7B           TDC 
C2/1F34: AA           TAX 
C2/1F35: A9 03        LDA #$03
C2/1F37: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1F3A: AA           TAX 
C2/1F3B: 7B           TDC 
C2/1F3C: 20 D6 01     JSR $01D6       ; set bit x
C2/1F3F: 85 16        STA $16
C2/1F41: 80 11        BRA $1F54
C2/1F43: AD A0 26     LDA $26A0
C2/1F46: 29 08        AND #$08
C2/1F48: D0 06        BNE $1F50
C2/1F4A: A9 FF        LDA #$FF
C2/1F4C: 85 17        STA $17
C2/1F4E: 80 04        BRA $1F54
C2/1F50: A9 F0        LDA #$F0
C2/1F52: 85 16        STA $16
C2/1F54: A6 3F        LDX $3F
C2/1F56: 68           PLA 
C2/1F57: 9D 5A 20     STA $205A,X
C2/1F5A: A5 16        LDA $16
C2/1F5C: 9D 59 20     STA $2059,X
C2/1F5F: A5 17        LDA $17
C2/1F61: 9D 58 20     STA $2058,X
C2/1F64: A9 21        LDA #$21
C2/1F66: 9D 56 20     STA $2056,X
C2/1F69: A9 2C        LDA #$2C
C2/1F6B: 9D 57 20     STA $2057,X
C2/1F6E: 9E 5B 20     STZ $205B,X
C2/1F71: 9E 5C 20     STZ $205C,X
C2/1F74: 9E 5D 20     STZ $205D,X
C2/1F77: 9E 5E 20     STZ $205E,X
C2/1F7A: 9E 5F 20     STZ $205F,X
C2/1F7D: 4C B3 1F     JMP $1FB3

; [  ]

C2/1F80: A9 80        LDA #$80
C2/1F82: 9D 56 20     STA $2056,X
C2/1F85: A9 05        LDA #$05
C2/1F87: 9D 57 20     STA $2057,X
C2/1F8A: 9E 59 20     STZ $2059,X
C2/1F8D: 9E 5A 20     STZ $205A,X
C2/1F90: 9E 5B 20     STZ $205B,X
C2/1F93: 9E 5C 20     STZ $205C,X
C2/1F96: 9E 5D 20     STZ $205D,X
C2/1F99: 9E 5E 20     STZ $205E,X
C2/1F9C: 9E 5F 20     STZ $205F,X
C2/1F9F: DA           PHX 
C2/1FA0: 7B           TDC 
C2/1FA1: AA           TAX 
C2/1FA2: A9 07        LDA #$07
C2/1FA4: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1FA7: AA           TAX 
C2/1FA8: 7B           TDC 
C2/1FA9: 20 D6 01     JSR $01D6       ; set bit x
C2/1FAC: FA           PLX 
C2/1FAD: 9D 58 20     STA $2058,X
C2/1FB0: 4C B3 1F     JMP $1FB3

; [  ]

C2/1FB3: A5 3D        LDA $3D
C2/1FB5: 20 82 24     JSR $2482
C2/1FB8: A5 3D        LDA $3D
C2/1FBA: AA           TAX 
C2/1FBB: B9 7F 3D     LDA $3D7F,Y
C2/1FBE: C9 7F        CMP #$7F
C2/1FC0: 90 02        BCC $1FC4
C2/1FC2: A9 7F        LDA #$7F
C2/1FC4: 9D 04 7C     STA $7C04,X
C2/1FC7: A9 01        LDA #$01
C2/1FC9: 99 7F 3D     STA $3D7F,Y
C2/1FCC: A9 41        LDA #$41
C2/1FCE: 99 FB 3C     STA $3CFB,Y
C2/1FD1: 60           RTS 

; [  ]

C2/1FD2: AD 4E 47     LDA $474E
C2/1FD5: D0 03        BNE $1FDA
C2/1FD7: 20 90 20     JSR $2090       ; update global timers
C2/1FDA: 7B           TDC 
C2/1FDB: AA           TAX 
C2/1FDC: 3A           DEC 
C2/1FDD: 9D 93 3E     STA $3E93,X
C2/1FE0: E8           INX 
C2/1FE1: E0 0C 00     CPX #$000C
C2/1FE4: D0 F7        BNE $1FDD
C2/1FE6: 7B           TDC 
C2/1FE7: A8           TAY 
C2/1FE8: 7B           TDC 
C2/1FE9: AA           TAX 
C2/1FEA: A9 0B        LDA #$0B
C2/1FEC: 20 7C 00     JSR $007C       ; a = (x..a)
C2/1FEF: 85 0E        STA $0E
C2/1FF1: A2 00 00     LDX #$0000
C2/1FF4: A5 0E        LDA $0E
C2/1FF6: DD 93 3E     CMP $3E93,X
C2/1FF9: F0 0A        BEQ $2005
C2/1FFB: E8           INX 
C2/1FFC: E0 0C 00     CPX #$000C
C2/1FFF: D0 F3        BNE $1FF4
C2/2001: 99 93 3E     STA $3E93,Y
C2/2004: C8           INY 
C2/2005: C0 0C 00     CPY #$000C
C2/2008: D0 DE        BNE $1FE8
C2/200A: 60           RTS 

; [ decrement timers ]

C2/200B: 20 90 20     JSR $2090       ; update global timers
C2/200E: 7B           TDC 
C2/200F: AA           TAX 
C2/2010: 86 0A        STX $0A         ; character/monster index
C2/2012: 7B           TDC 
C2/2013: A8           TAY 
C2/2014: 84 0C        STY $0C         ; timer index
C2/2016: A5 0A        LDA $0A
C2/2018: 20 07 02     JSR $0207       ; get timer data offset
C2/201B: BB           TYX 
C2/201C: A4 0A        LDY $0A
C2/201E: B9 C2 3E     LDA $3EC2,Y
C2/2021: F0 29        BEQ $204C
C2/2023: B9 9F 3E     LDA $3E9F,Y
C2/2026: D0 24        BNE $204C
C2/2028: AD 4E 47     LDA $474E
C2/202B: D0 05        BNE $2032
C2/202D: B9 AB 3E     LDA $3EAB,Y
C2/2030: D0 1A        BNE $204C
C2/2032: 20 55 20     JSR $2055       ; decrement timer
C2/2035: A5 08        LDA $08
C2/2037: D0 13        BNE $204C       ; don't decrement other timers if stop timer is active
C2/2039: A0 08 00     LDY #$0008      ; decrement next 8 timers (poison thru sing)
C2/203C: 20 55 20     JSR $2055       ; decrement timer
C2/203F: 88           DEY 
C2/2040: D0 FA        BNE $203C
C2/2042: 20 55 20     JSR $2055       ; decrement timer (paralyze)
C2/2045: A5 08        LDA $08
C2/2047: D0 03        BNE $204C       ; don't decrement atb if paralyze timer is active
C2/2049: 20 55 20     JSR $2055       ; decrement timer
C2/204C: E6 0A        INC $0A         ; next timer
C2/204E: A5 0A        LDA $0A
C2/2050: C9 0C        CMP #$0C
C2/2052: D0 BE        BNE $2012
C2/2054: 60           RTS 

; [ decrement timer ]

C2/2055: 64 08        STZ $08         ; clear flag for active timer
C2/2057: 5A           PHY 
C2/2058: A4 0C        LDY $0C
C2/205A: B9 E4 3E     LDA $3EE4,Y
C2/205D: F0 2C        BEQ $208B       ; branch if global timer didn't expire
C2/205F: C0 0A 00     CPY #$000A
C2/2062: F0 05        BEQ $2069       ; branch if timer $0A (atb ???)
C2/2064: AD 4E 47     LDA $474E
C2/2067: D0 22        BNE $208B
C2/2069: BD F1 3C     LDA $3CF1,X
C2/206C: F0 1D        BEQ $208B       ; branch if timer is not active
C2/206E: 30 15        BMI $2085       ; branch if timer expired
C2/2070: BD 75 3D     LDA $3D75,X     ; decrement timer
C2/2073: F0 08        BEQ $207D
C2/2075: DE 75 3D     DEC $3D75,X
C2/2078: BD 75 3D     LDA $3D75,X
C2/207B: D0 08        BNE $2085       ; branch if timer didn't expire
C2/207D: BD F1 3C     LDA $3CF1,X
C2/2080: 09 81        ORA #$81
C2/2082: 9D F1 3C     STA $3CF1,X     ; set timer status
C2/2085: A5 0C        LDA $0C
C2/2087: D0 00        BNE $2089
C2/2089: E6 08        INC $08         ; set flag for active timer
C2/208B: 7A           PLY 
C2/208C: E8           INX 
C2/208D: E6 0C        INC $0C
C2/208F: 60           RTS 

; [ update global timers ]

C2/2090: 7B           TDC 
C2/2091: AA           TAX 
C2/2092: BD D9 3E     LDA $3ED9,X
C2/2095: F0 08        BEQ $209F       ; branch if timer needs to be reset
C2/2097: DE D9 3E     DEC $3ED9,X
C2/209A: 9E E4 3E     STZ $3EE4,X     ; timer is not active
C2/209D: 80 0C        BRA $20AB
C2/209F: A9 01        LDA #$01
C2/20A1: 9D E4 3E     STA $3EE4,X     ; timer is active
C2/20A4: BF 76 29 D1  LDA $D12976,X   ; timer duration
C2/20A8: 9D D9 3E     STA $3ED9,X     ; set timer value
C2/20AB: E8           INX             ; next timer
C2/20AC: E0 0B 00     CPX #$000B
C2/20AF: D0 E1        BNE $2092
C2/20B1: 60           RTS 

; [  ]

C2/20B2: 7B           TDC 
C2/20B3: AA           TAX 
C2/20B4: 86 08        STX $08
C2/20B6: A8           TAY 
C2/20B7: 99 88 3E     STA $3E88,Y     ; disable all timer types
C2/20BA: C8           INY 
C2/20BB: C0 0B 00     CPY #$000B
C2/20BE: D0 F7        BNE $20B7
C2/20C0: 7B           TDC 
C2/20C1: AA           TAX 
C2/20C2: 86 0A        STX $0A
C2/20C4: A6 08        LDX $08
C2/20C6: BD 7D 3E     LDA $3E7D,X
C2/20C9: 48           PHA 
C2/20CA: A6 08        LDX $08
C2/20CC: BD 7D 3E     LDA $3E7D,X
C2/20CF: AA           TAX 
C2/20D0: BD 93 3E     LDA $3E93,X
C2/20D3: 85 0C        STA $0C
C2/20D5: AA           TAX 
C2/20D6: BD 9F 3E     LDA $3E9F,X
C2/20D9: D0 72        BNE $214D
C2/20DB: AD 4E 47     LDA $474E
C2/20DE: D0 05        BNE $20E5
C2/20E0: BD AB 3E     LDA $3EAB,X
C2/20E3: D0 68        BNE $214D
C2/20E5: A5 0C        LDA $0C
C2/20E7: 20 07 02     JSR $0207       ; get timer data offset
C2/20EA: 98           TYA 
C2/20EB: 18           CLC 
C2/20EC: 65 08        ADC $08
C2/20EE: AA           TAX 
C2/20EF: BD F1 3C     LDA $3CF1,X
C2/20F2: 10 59        BPL $214D
C2/20F4: A5 0C        LDA $0C
C2/20F6: A8           TAY 
C2/20F7: B9 C2 3E     LDA $3EC2,Y
C2/20FA: F0 51        BEQ $214D
C2/20FC: A5 08        LDA $08
C2/20FE: C9 01        CMP #$01
C2/2100: F0 08        BEQ $210A
C2/2102: C9 03        CMP #$03
C2/2104: F0 04        BEQ $210A
C2/2106: C9 07        CMP #$07
C2/2108: D0 25        BNE $212F
C2/210A: DA           PHX 
C2/210B: A6 08        LDX $08
C2/210D: BD 7D 3E     LDA $3E7D,X
C2/2110: AA           TAX 
C2/2111: BD 93 3E     LDA $3E93,X
C2/2114: C2 20        REP #$20
C2/2116: 20 B2 01     JSR $01B2       ; a << 7
C2/2119: AA           TAX 
C2/211A: 7B           TDC 
C2/211B: E2 20        SEP #$20
C2/211D: BD 1D 20     LDA $201D,X
C2/2120: 29 81        AND #$81
C2/2122: D0 07        BNE $212B
C2/2124: BD 1E 20     LDA $201E,X
C2/2127: 29 10        AND #$10
C2/2129: F0 03        BEQ $212E
C2/212B: FA           PLX 
C2/212C: 80 1F        BRA $214D
C2/212E: FA           PLX 
C2/212F: 68           PLA 
C2/2130: BD F1 3C     LDA $3CF1,X
C2/2133: 29 7E        AND #$7E
C2/2135: 9D F1 3C     STA $3CF1,X
C2/2138: A6 08        LDX $08
C2/213A: DA           PHX 
C2/213B: A9 01        LDA #$01
C2/213D: 9D 88 3E     STA $3E88,X
C2/2140: BD 7D 3E     LDA $3E7D,X
C2/2143: AA           TAX 
C2/2144: BD 93 3E     LDA $3E93,X
C2/2147: FA           PLX 
C2/2148: 9D B7 3E     STA $3EB7,X
C2/214B: 80 1E        BRA $216B
C2/214D: A6 08        LDX $08
C2/214F: FE 7D 3E     INC $3E7D,X
C2/2152: BD 7D 3E     LDA $3E7D,X
C2/2155: C9 0C        CMP #$0C
C2/2157: D0 03        BNE $215C
C2/2159: 9E 7D 3E     STZ $3E7D,X
C2/215C: E6 0A        INC $0A         ; next character/monster
C2/215E: A5 0A        LDA $0A
C2/2160: C9 0C        CMP #$0C
C2/2162: F0 03        BEQ $2167
C2/2164: 4C CA 20     JMP $20CA
C2/2167: 68           PLA 
C2/2168: 9D 7D 3E     STA $3E7D,X
C2/216B: E6 08        INC $08         ; next timer
C2/216D: A5 08        LDA $08
C2/216F: C9 0B        CMP #$0B
C2/2171: F0 03        BEQ $2176
C2/2173: 4C C0 20     JMP $20C0
C2/2176: 60           RTS 

; [ check timers ]

C2/2177: 7B           TDC 
C2/2178: AA           TAX 
C2/2179: 8E CE 3E     STX $3ECE
C2/217C: AE CE 3E     LDX $3ECE
C2/217F: BD 88 3E     LDA $3E88,X
C2/2182: F0 26        BEQ $21AA       ; skip if timer is not active
C2/2184: FE 7D 3E     INC $3E7D,X
C2/2187: BD 7D 3E     LDA $3E7D,X     ; next character/monster
C2/218A: C9 0C        CMP #$0C
C2/218C: D0 03        BNE $2191
C2/218E: 9E 7D 3E     STZ $3E7D,X
C2/2191: BD B7 3E     LDA $3EB7,X
C2/2194: 20 07 02     JSR $0207       ; get timer data offset
C2/2197: BD B7 3E     LDA $3EB7,X
C2/219A: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/219D: AD CE 3E     LDA $3ECE
C2/21A0: F0 05        BEQ $21A7       ; branch if stop timer
C2/21A2: B9 F1 3C     LDA $3CF1,Y
C2/21A5: D0 03        BNE $21AA       ; branch if timer not expired
C2/21A7: 20 B5 21     JSR $21B5       ; timer expired
C2/21AA: EE CE 3E     INC $3ECE       ; next timer
C2/21AD: AD CE 3E     LDA $3ECE
C2/21B0: C9 0B        CMP #$0B
C2/21B2: D0 C8        BNE $217C
C2/21B4: 60           RTS 

; [ timer expired ]

C2/21B5: AD CE 3E     LDA $3ECE       ; timer index
C2/21B8: 0A           ASL 
C2/21B9: AA           TAX 
C2/21BA: BF CD 21 C2  LDA $C221CD,X   ; timer expiration jump table
C2/21BE: 85 08        STA $08
C2/21C0: BF CE 21 C2  LDA $C221CE,X
C2/21C4: 85 09        STA $09
C2/21C6: A9 C2        LDA #$C2
C2/21C8: 85 0A        STA $0A
C2/21CA: DC 08 00     JML [$0008]

; timer expired jump table
C2/21CD:              .DW $21E3, $21EE, $222A, $2235, $224E, $2259, $2264, $22AD
C2/21DD:              .DW $2319, $237C, $238F

; $00: stop
C2/21E3: A6 32        LDX $32
C2/21E5: BD 1C 20     LDA $201C,X     ; remove stop status
C2/21E8: 29 EF        AND #$EF
C2/21EA: 9D 1C 20     STA $201C,X
C2/21ED: 60           RTS 

; $01: poison
C2/21EE: A9 01        LDA #$01
C2/21F0: 99 F2 3C     STA $3CF2,Y     ; restart timer
C2/21F3: B9 FA 3D     LDA $3DFA,Y
C2/21F6: 99 76 3D     STA $3D76,Y
C2/21F9: 20 18 02     JSR $0218       ; reset battle graphics parameters
C2/21FC: C2 20        REP #$20
C2/21FE: A6 32        LDX $32
C2/2200: BD 08 20     LDA $2008,X
C2/2203: 20 BE 01     JSR $01BE       ; a >> 4
C2/2206: D0 01        BNE $2209
C2/2208: 1A           INC 
C2/2209: 85 0E        STA $0E
C2/220B: 38           SEC 
C2/220C: BD 06 20     LDA $2006,X     ; current hp -= max hp / 16
C2/220F: E5 0E        SBC $0E
C2/2211: B0 01        BCS $2214
C2/2213: 7B           TDC 
C2/2214: 9D 06 20     STA $2006,X
C2/2217: 7B           TDC 
C2/2218: E2 20        SEP #$20
C2/221A: AD B8 3E     LDA $3EB8
C2/221D: A6 0E        LDX $0E
C2/221F: 8E 5D 3C     STX $3C5D       ; damage
C2/2222: 20 76 02     JSR $0276       ; 
C2/2225: A9 09        LDA #$09
C2/2227: 4C 69 00     JMP $0069       ; execute battle graphics function

; $02: reflect
C2/222A: A6 32        LDX $32
C2/222C: BD 1C 20     LDA $201C,X     ; remove reflect status
C2/222F: 29 7F        AND #$7F
C2/2231: 9D 1C 20     STA $201C,X
C2/2234: 60           RTS 

; $03: countdown/condemn
C2/2235: A6 32        LDX $32
C2/2237: BD 1A 20     LDA $201A,X
C2/223A: 29 02        AND #$02
C2/223C: D0 0F        BNE $224D       ; branch if no countdown status
C2/223E: AD BA 3E     LDA $3EBA
C2/2241: 20 8A 61     JSR $618A       ; 
C2/2244: A5 70        LDA $70
C2/2246: F0 05        BEQ $224D
C2/2248: A9 07        LDA #$07
C2/224A: 20 69 00     JSR $0069       ; execute battle graphics function
C2/224D: 60           RTS 

; $04: mute
C2/224E: A6 32        LDX $32
C2/2250: BD 1B 20     LDA $201B,X     ; remove mute status
C2/2253: 29 FB        AND #$FB
C2/2255: 9D 1B 20     STA $201B,X
C2/2258: 60           RTS 

; $05: hp leak
C2/2259: A6 32        LDX $32
C2/225B: BD 1D 20     LDA $201D,X     ; remove hp leak status
C2/225E: 29 F7        AND #$F7
C2/2260: 9D 1D 20     STA $201D,X
C2/2263: 60           RTS 

; $06: old
C2/2264: A9 01        LDA #$01
C2/2266: 99 F7 3C     STA $3CF7,Y
C2/2269: B9 FF 3D     LDA $3DFF,Y
C2/226C: 99 7B 3D     STA $3D7B,Y
C2/226F: A6 32        LDX $32
C2/2271: 64 0E        STZ $0E
C2/2273: BD 24 20     LDA $2024,X
C2/2276: 3A           DEC 
C2/2277: F0 03        BEQ $227C
C2/2279: 9D 24 20     STA $2024,X
C2/227C: BD 28 20     LDA $2028,X
C2/227F: 3A           DEC 
C2/2280: F0 03        BEQ $2285
C2/2282: 9D 28 20     STA $2028,X
C2/2285: E8           INX 
C2/2286: E6 0E        INC $0E
C2/2288: A5 0E        LDA $0E
C2/228A: C9 04        CMP #$04
C2/228C: D0 E5        BNE $2273
C2/228E: AE CE 3E     LDX $3ECE
C2/2291: BD B7 3E     LDA $3EB7,X
C2/2294: C9 04        CMP #$04
C2/2296: 90 14        BCC $22AC
C2/2298: A6 32        LDX $32
C2/229A: BD 02 20     LDA $2002,X
C2/229D: 3A           DEC 
C2/229E: F0 03        BEQ $22A3
C2/22A0: 9D 02 20     STA $2002,X
C2/22A3: BD 44 20     LDA $2044,X
C2/22A6: 3A           DEC 
C2/22A7: 10 03        BPL $22AC
C2/22A9: 9D 44 20     STA $2044,X
C2/22AC: 60           RTS 

; $07: regen
C2/22AD: A9 01        LDA #$01
C2/22AF: 99 F8 3C     STA $3CF8,Y
C2/22B2: B9 00 3E     LDA $3E00,Y
C2/22B5: C9 1E        CMP #$1E
C2/22B7: B0 05        BCS $22BE
C2/22B9: A9 1E        LDA #$1E
C2/22BB: 99 00 3E     STA $3E00,Y
C2/22BE: 99 7C 3D     STA $3D7C,Y
C2/22C1: 20 18 02     JSR $0218       ; reset battle graphics parameters
C2/22C4: A6 32        LDX $32
C2/22C6: 20 48 02     JSR $0248       ; get attacker stats and level
C2/22C9: AD E5 7B     LDA $7BE5       ; level
C2/22CC: 85 24        STA $24
C2/22CE: AD E3 7B     LDA $7BE3       ; stamina
C2/22D1: 85 25        STA $25
C2/22D3: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/22D6: A6 32        LDX $32
C2/22D8: BD 1A 20     LDA $201A,X
C2/22DB: 29 02        AND #$02
C2/22DD: D0 39        BNE $2318       ; branch if zombie
C2/22DF: C2 20        REP #$20
C2/22E1: A5 26        LDA $26
C2/22E3: 20 BE 01     JSR $01BE       ; a >> 4
C2/22E6: AA           TAX 
C2/22E7: D0 01        BNE $22EA
C2/22E9: 1A           INC 
C2/22EA: 85 0E        STA $0E
C2/22EC: A6 32        LDX $32
C2/22EE: 18           CLC 
C2/22EF: 7D 06 20     ADC $2006,X     ; current hp
C2/22F2: B0 05        BCS $22F9
C2/22F4: DD 08 20     CMP $2008,X     ; max hp
C2/22F7: 90 03        BCC $22FC
C2/22F9: BD 08 20     LDA $2008,X
C2/22FC: 9D 06 20     STA $2006,X
C2/22FF: 7B           TDC 
C2/2300: E2 20        SEP #$20
C2/2302: A5 0F        LDA $0F
C2/2304: 09 80        ORA #$80        ; use green numerals
C2/2306: 85 0F        STA $0F
C2/2308: AD BE 3E     LDA $3EBE
C2/230B: A6 0E        LDX $0E
C2/230D: 8E 5D 3C     STX $3C5D       ; damage numeral value
C2/2310: 20 76 02     JSR $0276
C2/2313: A9 09        LDA #$09
C2/2315: 20 69 00     JSR $0069       ; execute battle graphics function
C2/2318: 60           RTS 

; $08: sing
C2/2319: A9 01        LDA #$01
C2/231B: 99 F9 3C     STA $3CF9,Y
C2/231E: B9 01 3E     LDA $3E01,Y
C2/2321: 99 7D 3D     STA $3D7D,Y
C2/2324: 7B           TDC 
C2/2325: A8           TAY 
C2/2326: A6 32        LDX $32
C2/2328: BD 6F 20     LDA $206F,X     ; current sing parameter
C2/232B: F0 4E        BEQ $237B       ; branch if no stat increase
C2/232D: 0A           ASL 
C2/232E: B0 03        BCS $2333
C2/2330: C8           INY 
C2/2331: 80 FA        BRA $232D
C2/2333: 84 12        STY $12
C2/2335: 7B           TDC 
C2/2336: AA           TAX 
C2/2337: 86 0E        STX $0E
C2/2339: A9 04        LDA #$04
C2/233B: 85 10        STA $10
C2/233D: AD BF 3E     LDA $3EBF
C2/2340: C9 04        CMP #$04
C2/2342: 90 0B        BCC $234F
C2/2344: A9 04        LDA #$04
C2/2346: 85 0E        STA $0E
C2/2348: A9 0C        LDA #$0C
C2/234A: 85 10        STA $10
C2/234C: A2 80 01     LDX #$0180
C2/234F: 86 14        STX $14
C2/2351: C2 20        REP #$20
C2/2353: 8A           TXA 
C2/2354: 18           CLC 
C2/2355: 65 12        ADC $12
C2/2357: AA           TAX 
C2/2358: 7B           TDC 
C2/2359: E2 20        SEP #$20
C2/235B: A4 0E        LDY $0E
C2/235D: B9 C2 3E     LDA $3EC2,Y
C2/2360: F0 0C        BEQ $236E
C2/2362: 18           CLC 
C2/2363: BD 74 20     LDA $2074,X
C2/2366: 1A           INC 
C2/2367: C9 64        CMP #$64
C2/2369: B0 03        BCS $236E
C2/236B: 9D 74 20     STA $2074,X
C2/236E: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2371: 86 14        STX $14
C2/2373: E6 0E        INC $0E
C2/2375: A5 0E        LDA $0E
C2/2377: C5 10        CMP $10
C2/2379: D0 E0        BNE $235B
C2/237B: 60           RTS 

; $09: paralyze
C2/237C: A6 32        LDX $32
C2/237E: BD 1B 20     LDA $201B,X     ; remove paralyze status
C2/2381: 29 DF        AND #$DF
C2/2383: 9D 1B 20     STA $201B,X
C2/2386: AE CE 3E     LDX $3ECE
C2/2389: BD B7 3E     LDA $3EB7,X
C2/238C: 4C 82 24     JMP $2482

; $0A: action
C2/238F: 20 B4 5A     JSR $5AB4
C2/2392: AD DE 7B     LDA $7BDE
C2/2395: D0 41        BNE $23D8
C2/2397: AD C1 3E     LDA $3EC1
C2/239A: 85 47        STA $47         ; set attacker id
C2/239C: 20 07 02     JSR $0207       ; get timer data offset
C2/239F: BB           TYX 
C2/23A0: BD FA 3C     LDA $3CFA,X
C2/23A3: D0 33        BNE $23D8
C2/23A5: BD FB 3C     LDA $3CFB,X
C2/23A8: F0 03        BEQ $23AD
C2/23AA: 4C DF 23     JMP $23DF       ; do action ???
C2/23AD: AD C1 3E     LDA $3EC1
C2/23B0: C9 04        CMP #$04
C2/23B2: B0 27        BCS $23DB
C2/23B4: 7B           TDC 
C2/23B5: AA           TAX 
C2/23B6: BD A9 41     LDA $41A9,X
C2/23B9: CD C1 3E     CMP $3EC1
C2/23BC: F0 1A        BEQ $23D8
C2/23BE: E8           INX 
C2/23BF: E0 04 00     CPX #$0004
C2/23C2: D0 F2        BNE $23B6
C2/23C4: AD C1 3E     LDA $3EC1
C2/23C7: 20 74 1C     JSR $1C74
C2/23CA: D0 0C        BNE $23D8
C2/23CC: AE AE 41     LDX $41AE
C2/23CF: AD C1 3E     LDA $3EC1
C2/23D2: 9D A9 41     STA $41A9,X
C2/23D5: EE AE 41     INC $41AE
C2/23D8: 4C DE 23     JMP $23DE
C2/23DB: 20 D3 25     JSR $25D3       ; monster ???
C2/23DE: 60           RTS 

; [ do action ??? ]

C2/23DF: 20 BD 48     JSR $48BD
C2/23E2: AD FC 7B     LDA $7BFC
C2/23E5: D0 4A        BNE $2431
C2/23E7: A5 47        LDA $47
C2/23E9: C9 04        CMP #$04
C2/23EB: B0 39        BCS $2426       ; branch if a monster
C2/23ED: A6 32        LDX $32
C2/23EF: BD 1E 20     LDA $201E,X     ; clear jumping, flirting, ... flags
C2/23F2: 29 E0        AND #$E0
C2/23F4: 9D 1E 20     STA $201E,X
C2/23F7: 9E 1F 20     STZ $201F,X     ; clear damage modifier
C2/23FA: BD 1A 20     LDA $201A,X
C2/23FD: 1D 70 20     ORA $2070,X
C2/2400: 29 02        AND #$02
C2/2402: D0 0A        BNE $240E       ; branch if zombie
C2/2404: BD 1B 20     LDA $201B,X
C2/2407: 1D 71 20     ORA $2071,X
C2/240A: 29 18        AND #$18
C2/240C: F0 18        BEQ $2426       ; branch if not charm or berserk
C2/240E: A5 47        LDA $47
C2/2410: 20 07 02     JSR $0207       ; get timer data offset
C2/2413: 7B           TDC 
C2/2414: 99 FB 3C     STA $3CFB,Y     ; clear action timer status
C2/2417: 1A           INC 
C2/2418: 99 7F 3D     STA $3D7F,Y     ; timer value = 1
C2/241B: A5 47        LDA $47
C2/241D: AA           TAX 
C2/241E: BD 04 7C     LDA $7C04,X
C2/2421: 29 7F        AND #$7F
C2/2423: 9D 04 7C     STA $7C04,X
C2/2426: EE C7 7C     INC $7CC7
C2/2429: A5 47        LDA $47
C2/242B: 20 82 24     JSR $2482
C2/242E: 9C C7 7C     STZ $7CC7
C2/2431: 60           RTS 

; [  ]

C2/2432: AD D4 3E     LDA $3ED4
C2/2435: F0 0F        BEQ $2446
C2/2437: AD D5 3E     LDA $3ED5
C2/243A: F0 06        BEQ $2442
C2/243C: 3A           DEC 
C2/243D: 8D D5 3E     STA $3ED5
C2/2440: D0 04        BNE $2446
C2/2442: 7B           TDC 
C2/2443: 8D D4 3E     STA $3ED4
C2/2446: 60           RTS 

; [  ]

C2/2447: 7B           TDC 
C2/2448: AA           TAX 
C2/2449: A8           TAY 
C2/244A: 86 0E        STX $0E
C2/244C: A5 0E        LDA $0E
C2/244E: 20 82 24     JSR $2482       ; 
C2/2451: A5 0E        LDA $0E
C2/2453: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/2456: A5 0E        LDA $0E
C2/2458: C9 04        CMP #$04
C2/245A: B0 0B        BCS $2467       ; branch if a monster
C2/245C: A6 32        LDX $32
C2/245E: BD 00 20     LDA $2000,X     ; battle row
C2/2461: 29 40        AND #$40
C2/2463: F0 0D        BEQ $2472       ; branch if front row
C2/2465: D0 12        BNE $2479       ; branch if back row

; monster
C2/2467: 38           SEC 
C2/2468: A5 0E        LDA $0E
C2/246A: E9 04        SBC #$04
C2/246C: AA           TAX 
C2/246D: BD 18 40     LDA $4018,X     ; 
C2/2470: F0 07        BEQ $2479

; front row
C2/2472: A6 0E        LDX $0E
C2/2474: A9 01        LDA #$01
C2/2476: 9D C2 3E     STA $3EC2,X     ; 

; back row
C2/2479: E6 0E        INC $0E         ; next character/monster
C2/247B: A5 0E        LDA $0E
C2/247D: C9 0C        CMP #$0C
C2/247F: D0 CB        BNE $244C
C2/2481: 60           RTS 

; [  ]

C2/2482: 48           PHA 
C2/2483: 20 07 02     JSR $0207       ; get timer data offset
C2/2486: 68           PLA 
C2/2487: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/248A: 20 48 02     JSR $0248       ; get attacker stats and level
C2/248D: BD 23 20     LDA $2023,X     ; equipment weight
C2/2490: 20 BF 01     JSR $01BF       ; a >> 3
C2/2493: 18           CLC 
C2/2494: 69 78        ADC #$78        ; weight / 8 + 120 - agility
C2/2496: 38           SEC 
C2/2497: ED E2 7B     SBC $7BE2
C2/249A: F0 02        BEQ $249E
C2/249C: B0 02        BCS $24A0
C2/249E: A9 01        LDA #$01        ; min 1
C2/24A0: 20 63 61     JSR $6163
C2/24A3: 99 7F 3D     STA $3D7F,Y     ; timer value
C2/24A6: AD EF 3E     LDA $3EEF
C2/24A9: 10 10        BPL $24BB
C2/24AB: A6 32        LDX $32
C2/24AD: E0 00 02     CPX #$0200
C2/24B0: B0 04        BCS $24B6
C2/24B2: A9 01        LDA #$01
C2/24B4: 80 02        BRA $24B8
C2/24B6: A9 FF        LDA #$FF
C2/24B8: 99 7F 3D     STA $3D7F,Y
C2/24BB: AD C7 7C     LDA $7CC7
C2/24BE: F0 1E        BEQ $24DE
C2/24C0: AD 51 7C     LDA $7C51       ; branch if there are no quick turns pending
C2/24C3: F0 19        BEQ $24DE
C2/24C5: AD 4E 47     LDA $474E
C2/24C8: D0 14        BNE $24DE
C2/24CA: CE 51 7C     DEC $7C51       ; decrement number of quick turns
C2/24CD: AD 51 7C     LDA $7C51
C2/24D0: D0 07        BNE $24D9
C2/24D2: 5A           PHY 
C2/24D3: 20 E4 24     JSR $24E4
C2/24D6: 7A           PLY 
C2/24D7: 80 05        BRA $24DE
C2/24D9: A9 01        LDA #$01
C2/24DB: 99 7F 3D     STA $3D7F,Y     ; timer value
C2/24DE: A9 01        LDA #$01
C2/24E0: 99 FB 3C     STA $3CFB,Y     ; activate timer
C2/24E3: 60           RTS 

; [  ]

C2/24E4: 7B           TDC 
C2/24E5: AA           TAX 
C2/24E6: 9E AB 3E     STZ $3EAB,X
C2/24E9: E8           INX 
C2/24EA: E0 0C 00     CPX #$000C
C2/24ED: D0 F7        BNE $24E6
C2/24EF: 60           RTS 

; [ stop timer ]

; a: character/monster index
; x: timer index

C2/24F0: DA           PHX 
C2/24F1: 20 07 02     JSR $0207       ; get timer data offset
C2/24F4: FA           PLX 
C2/24F5: 20 3F 25     JSR $253F       ; get pointer to timer data
C2/24F8: 7B           TDC 
C2/24F9: 99 F1 3C     STA $3CF1,Y     ; stop timer
C2/24FC: 60           RTS 

; [ start timer ]

; a: character/monster index
; x: timer index

C2/24FD: DA           PHX 
C2/24FE: 48           PHA 
C2/24FF: 20 07 02     JSR $0207       ; get timer data offset
C2/2502: 68           PLA 
C2/2503: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/2506: 20 48 02     JSR $0248       ; get attacker stats and level
C2/2509: FA           PLX 
C2/250A: 20 21 25     JSR $2521       ; calculate timer duration
C2/250D: A6 32        LDX $32
C2/250F: 20 63 61     JSR $6163       ; haste/slow timer modification
C2/2512: 99 75 3D     STA $3D75,Y     ; set timer duration
C2/2515: 99 F9 3D     STA $3DF9,Y     ; 
C2/2518: A9 01        LDA #$01
C2/251A: 99 F1 3C     STA $3CF1,Y     ; start timer
C2/251D: 9C D7 3E     STZ $3ED7       ; custom timer duration
C2/2520: 60           RTS 

; [ calculate timer duration ]

C2/2521: 20 3F 25     JSR $253F       ; get pointer to timer data
C2/2524: 8A           TXA 
C2/2525: 0A           ASL 
C2/2526: 18           CLC 
C2/2527: 6D D7 3E     ADC $3ED7       ; 0 = custom duration, 1 = default duration
C2/252A: 0A           ASL 
C2/252B: AA           TAX 
C2/252C: BF 4A 25 C2  LDA $C2254A,X   ; timer duration jump table
C2/2530: 85 08        STA $08
C2/2532: BF 4B 25 C2  LDA $C2254B,X
C2/2536: 85 09        STA $09
C2/2538: A9 C2        LDA #$C2
C2/253A: 85 0A        STA $0A
C2/253C: DC 08 00     JML [$0008]

; [ get pointer to timer data ]

; x: timer index

C2/253F: 8A           TXA 
C2/2540: C2 20        REP #$20
C2/2542: 18           CLC 
C2/2543: 65 36        ADC $36         ; timer data offset
C2/2545: A8           TAY 
C2/2546: 7B           TDC 
C2/2547: E2 20        SEP #$20
C2/2549: 60           RTS 

; timer duration jump table (first address = custom duration, second address = default)
C2/254A:              .DW $2572, $2576, $2579, $2579, $2572, $2584, $2572, $2587
C2/255A:              .DW $2572, $258A, $2572, $259A, $259D, $259D, $25A0, $25A0
C2/256A:              .DW $25AF, $25AF, $25B2, $25C3

; 0, 2, 3, 4, 5 (stop, reflect, countdown, mute, hp leak)
C2/2572: AD D8 3E     LDA $3ED8       ; status duration
C2/2575: 60           RTS 

; 0 (stop, default)
C2/2576: A9 78        LDA #$78        ; 120
C2/2578: 60           RTS 

; 1 (poison)
C2/2579: 18           CLC 
C2/257A: AD E3 7B     LDA $7BE3       ; stamina + 20
C2/257D: 69 14        ADC #$14
C2/257F: 90 02        BCC $2583
C2/2581: A9 FF        LDA #$FF        ; max 255
C2/2583: 60           RTS 

; 2 (reflect, default)
C2/2584: A9 78        LDA #$78        ; 120
C2/2586: 60           RTS 

; 3 (countdown, default)
C2/2587: A9 31        LDA #$31        ; 49
C2/2589: 60           RTS 

; 4 (mute, default)
C2/258A: AD E4 7B     LDA $7BE4       ; 180 - magic power / 2
C2/258D: 4A           LSR 
C2/258E: 85 0E        STA $0E
C2/2590: 38           SEC 
C2/2591: A9 B4        LDA #$B4
C2/2593: E5 0E        SBC $0E
C2/2595: B0 02        BCS $2599
C2/2597: A9 01        LDA #$01        ; min 1
C2/2599: 60           RTS 

; 5 (hp leak, default)
C2/259A: A9 B4        LDA #$B4        ; 180
C2/259C: 60           RTS 

; 6 (old)
C2/259D: A9 0A        LDA #$0A        ; 10
C2/259F: 60           RTS 

; 7 (regen)
C2/25A0: 38           SEC 
C2/25A1: A9 6E        LDA #$6E        ; 110 - magic power
C2/25A3: ED E4 7B     SBC $7BE4
C2/25A6: 90 04        BCC $25AC
C2/25A8: C9 1E        CMP #$1E        ; min 30
C2/25AA: B0 02        BCS $25AE
C2/25AC: A9 1E        LDA #$1E
C2/25AE: 60           RTS 

; 8 (sing)
C2/25AF: A9 1E        LDA #$1E        ; 30
C2/25B1: 60           RTS 

; 9 (paralyze)
C2/25B2: AD E4 7B     LDA $7BE4
C2/25B5: 4A           LSR 
C2/25B6: 85 0E        STA $0E
C2/25B8: 38           SEC 
C2/25B9: AD D8 3E     LDA $3ED8       ; status duration - magic power / 2
C2/25BC: E5 0E        SBC $0E
C2/25BE: B0 02        BCS $25C2
C2/25C0: A9 01        LDA #$01        ; min 1
C2/25C2: 60           RTS 

; 9 (paralyze, default)
C2/25C3: AD E4 7B     LDA $7BE4
C2/25C6: 4A           LSR 
C2/25C7: 85 0E        STA $0E
C2/25C9: 38           SEC 
C2/25CA: A9 78        LDA #$78        ; 120 - magic power / 2
C2/25CC: E5 0E        SBC $0E
C2/25CE: B0 02        BCS $25D2
C2/25D0: A9 01        LDA #$01        ; min 1
C2/25D2: 60           RTS 

; [  ]

C2/25D3: A9 01        LDA #$01
C2/25D5: 8D 50 7C     STA $7C50
C2/25D8: 38           SEC 
C2/25D9: A5 47        LDA $47
C2/25DB: E9 04        SBC #$04
C2/25DD: 8D 03 7C     STA $7C03
C2/25E0: 20 B5 01     JSR $01B5       ; a << 4
C2/25E3: AA           TAX 
C2/25E4: 8E 5E 43     STX $435E
C2/25E7: 0A           ASL 
C2/25E8: AA           TAX 
C2/25E9: 8E 60 43     STX $4360
C2/25EC: 7B           TDC 
C2/25ED: A8           TAY 
C2/25EE: 84 22        STY $22
C2/25F0: AE 5E 43     LDX $435E
C2/25F3: A9 FF        LDA #$FF
C2/25F5: 9D DE 41     STA $41DE,X
C2/25F8: E8           INX 
C2/25F9: C8           INY 
C2/25FA: C0 10 00     CPY #$0010
C2/25FD: D0 F6        BNE $25F5
C2/25FF: AD 03 7C     LDA $7C03
C2/2602: 0A           ASL 
C2/2603: AA           TAX 
C2/2604: BF 95 EE D0  LDA $D0EE95,X
C2/2608: 85 0E        STA $0E
C2/260A: BF 96 EE D0  LDA $D0EE96,X
C2/260E: 85 0F        STA $0F
C2/2610: 7B           TDC 
C2/2611: A8           TAY 
C2/2612: A6 0E        LDX $0E
C2/2614: A9 FF        LDA #$FF
C2/2616: 9D 67 43     STA $4367,X
C2/2619: E8           INX 
C2/261A: C8           INY 
C2/261B: C0 64 00     CPY #$0064
C2/261E: D0 F6        BNE $2616
C2/2620: A5 47        LDA $47
C2/2622: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/2625: A6 32        LDX $32
C2/2627: A9 2C        LDA #$2C
C2/2629: 9D 57 20     STA $2057,X
C2/262C: A9 21        LDA #$21
C2/262E: 9D 56 20     STA $2056,X
C2/2631: A6 32        LDX $32
C2/2633: BD 1B 20     LDA $201B,X
C2/2636: 1D 71 20     ORA $2071,X
C2/2639: 29 08        AND #$08
C2/263B: F0 15        BEQ $2652
C2/263D: A9 01        LDA #$01
C2/263F: 9D 61 20     STA $2061,X
C2/2642: A9 80        LDA #$80
C2/2644: 8D 40 26     STA $2640
C2/2647: A9 FF        LDA #$FF
C2/2649: 8D 41 26     STA $2641
C2/264C: 20 10 32     JSR $3210
C2/264F: 4C EC 26     JMP $26EC
C2/2652: BD 1B 20     LDA $201B,X
C2/2655: 1D 71 20     ORA $2071,X
C2/2658: 29 10        AND #$10
C2/265A: F0 3C        BEQ $2698
C2/265C: A6 32        LDX $32
C2/265E: A9 01        LDA #$01
C2/2660: 9D 61 20     STA $2061,X
C2/2663: 7B           TDC 
C2/2664: AA           TAX 
C2/2665: A9 03        LDA #$03
C2/2667: 20 7C 00     JSR $007C       ; a = (x..a)
C2/266A: AA           TAX 
C2/266B: 86 0E        STX $0E
C2/266D: AD 03 7C     LDA $7C03
C2/2670: 0A           ASL 
C2/2671: AA           TAX 
C2/2672: C2 20        REP #$20
C2/2674: BD 20 40     LDA $4020,X
C2/2677: 20 B7 01     JSR $01B7       ; a << 2
C2/267A: 18           CLC 
C2/267B: 65 0E        ADC $0E
C2/267D: AA           TAX 
C2/267E: 7B           TDC 
C2/267F: E2 20        SEP #$20
C2/2681: BF 00 56 D0  LDA $D05600,X
C2/2685: C9 FF        CMP #$FF
C2/2687: F0 D3        BEQ $265C
C2/2689: 8D 40 26     STA $2640
C2/268C: A9 FF        LDA #$FF
C2/268E: 8D 41 26     STA $2641
C2/2691: E6 22        INC $22
C2/2693: 20 10 32     JSR $3210
C2/2696: 80 54        BRA $26EC
C2/2698: BD 1E 20     LDA $201E,X
C2/269B: 29 08        AND #$08
C2/269D: F0 0C        BEQ $26AB
C2/269F: A9 51        LDA #$51
C2/26A1: 9D 57 20     STA $2057,X
C2/26A4: A9 80        LDA #$80
C2/26A6: 9D 56 20     STA $2056,X
C2/26A9: 80 41        BRA $26EC
C2/26AB: BD 1D 20     LDA $201D,X
C2/26AE: 29 20        AND #$20
C2/26B0: D0 09        BNE $26BB
C2/26B2: BD 1B 20     LDA $201B,X
C2/26B5: 29 40        AND #$40
C2/26B7: D0 13        BNE $26CC
C2/26B9: 80 34        BRA $26EF
C2/26BB: 7B           TDC 
C2/26BC: A8           TAY 
C2/26BD: B9 3A 7C     LDA $7C3A,Y
C2/26C0: C5 47        CMP $47
C2/26C2: F0 03        BEQ $26C7
C2/26C4: C8           INY 
C2/26C5: 80 F6        BRA $26BD
C2/26C7: B9 3E 7C     LDA $7C3E,Y
C2/26CA: D0 0A        BNE $26D6
C2/26CC: 9E 57 20     STZ $2057,X
C2/26CF: A9 80        LDA #$80
C2/26D1: 9D 56 20     STA $2056,X
C2/26D4: 80 16        BRA $26EC
C2/26D6: 7B           TDC 
C2/26D7: 99 3E 7C     STA $7C3E,Y
C2/26DA: AD 03 7C     LDA $7C03
C2/26DD: AA           TAX 
C2/26DE: BD 43 7C     LDA $7C43,X
C2/26E1: 8D 40 26     STA $2640
C2/26E4: A9 FF        LDA #$FF
C2/26E6: 8D 41 26     STA $2641
C2/26E9: 20 10 32     JSR $3210
C2/26EC: 4C 8A 27     JMP $278A
C2/26EF: AD 03 7C     LDA $7C03
C2/26F2: AA           TAX 
C2/26F3: BD 87 46     LDA $4687,X
C2/26F6: 8D 8F 46     STA $468F
C2/26F9: AD 03 7C     LDA $7C03
C2/26FC: 0A           ASL 
C2/26FD: AA           TAX 
C2/26FE: C2 20        REP #$20
C2/2700: 18           CLC 
C2/2701: BF A5 EE D0  LDA $D0EEA5,X
C2/2705: 69 59 47     ADC #$4759
C2/2708: 85 4B        STA $4B
C2/270A: 7B           TDC 
C2/270B: E2 20        SEP #$20
C2/270D: 9C 90 46     STZ $4690
C2/2710: AD 90 46     LDA $4690
C2/2713: AA           TAX 
C2/2714: BF C9 EE D0  LDA $D0EEC9,X
C2/2718: A8           TAY 
C2/2719: 8C 92 46     STY $4692
C2/271C: 9C 91 46     STZ $4691
C2/271F: AC 92 46     LDY $4692
C2/2722: B1 4B        LDA ($4B),Y
C2/2724: F0 2A        BEQ $2750
C2/2726: C9 FE        CMP #$FE
C2/2728: F0 26        BEQ $2750
C2/272A: 20 BF 27     JSR $27BF       ; check monster condition
C2/272D: AD 94 46     LDA $4694
C2/2730: F0 14        BEQ $2746       ; branch if monster condition false
C2/2732: C2 20        REP #$20
C2/2734: 18           CLC 
C2/2735: AD 92 46     LDA $4692
C2/2738: 69 04 00     ADC #$0004
C2/273B: 8D 92 46     STA $4692
C2/273E: 7B           TDC 
C2/273F: E2 20        SEP #$20
C2/2741: EE 91 46     INC $4691
C2/2744: 80 D9        BRA $271F
C2/2746: EE 90 46     INC $4690
C2/2749: AD 90 46     LDA $4690
C2/274C: C9 0A        CMP #$0A
C2/274E: D0 C0        BNE $2710
C2/2750: C2 20        REP #$20
C2/2752: 18           CLC 
C2/2753: A5 4B        LDA $4B
C2/2755: 69 AA 00     ADC #$00AA
C2/2758: 85 4B        STA $4B
C2/275A: 7B           TDC 
C2/275B: E2 20        SEP #$20
C2/275D: AD 8F 46     LDA $468F
C2/2760: CD 90 46     CMP $4690
C2/2763: F0 22        BEQ $2787
C2/2765: AD 03 7C     LDA $7C03
C2/2768: AA           TAX 
C2/2769: AD 90 46     LDA $4690
C2/276C: 9D 87 46     STA $4687,X
C2/276F: AD 03 7C     LDA $7C03
C2/2772: 0A           ASL 
C2/2773: A8           TAY 
C2/2774: AD 90 46     LDA $4690
C2/2777: 0A           ASL 
C2/2778: AA           TAX 
C2/2779: BF B5 EE D0  LDA $D0EEB5,X
C2/277D: 99 96 46     STA $4696,Y
C2/2780: BF B6 EE D0  LDA $D0EEB6,X
C2/2784: 99 97 46     STA $4697,Y
C2/2787: 20 3B 31     JSR $313B       ; execute ai script
C2/278A: AE 5E 43     LDX $435E
C2/278D: BD DE 41     LDA $41DE,X
C2/2790: C2 20        REP #$20
C2/2792: 20 B6 01     JSR $01B6       ; a << 3
C2/2795: AA           TAX 
C2/2796: 7B           TDC 
C2/2797: E2 20        SEP #$20
C2/2799: BF 80 0B D1  LDA $D10B80,X
C2/279D: 29 03        AND #$03
C2/279F: AA           TAX 
C2/27A0: BF EE EC D0  LDA $D0ECEE,X
C2/27A4: 48           PHA 
C2/27A5: A5 47        LDA $47
C2/27A7: 20 07 02     JSR $0207       ; get timer data offset
C2/27AA: 68           PLA 
C2/27AB: 99 7F 3D     STA $3D7F,Y
C2/27AE: A9 41        LDA #$41
C2/27B0: 99 FB 3C     STA $3CFB,Y
C2/27B3: AD 03 7C     LDA $7C03
C2/27B6: 0A           ASL 
C2/27B7: AA           TAX 
C2/27B8: 9E 2A 7C     STZ $7C2A,X
C2/27BB: 9E 2B 7C     STZ $7C2B,X
C2/27BE: 60           RTS 

; [ check monster condition ]

C2/27BF: C9 13        CMP #$13
C2/27C1: 90 01        BCC $27C4       ; ignore invalid conditions
C2/27C3: 7B           TDC 
C2/27C4: 85 0E        STA $0E
C2/27C6: 0A           ASL 
C2/27C7: AA           TAX 
C2/27C8: BF 14 28 C2  LDA $C22814,X   ; monster condition jump table
C2/27CC: 85 08        STA $08
C2/27CE: BF 15 28 C2  LDA $C22815,X
C2/27D2: 85 09        STA $09
C2/27D4: A9 C2        LDA #$C2
C2/27D6: 85 0A        STA $0A
C2/27D8: C8           INY 
C2/27D9: B1 4B        LDA ($4B),Y     ; parameter 1
C2/27DB: 8D 21 27     STA $2721
C2/27DE: C8           INY 
C2/27DF: B1 4B        LDA ($4B),Y     ; parameter 2
C2/27E1: 8D 22 27     STA $2722
C2/27E4: C8           INY 
C2/27E5: B1 4B        LDA ($4B),Y     ; parameter 3
C2/27E7: 8D 23 27     STA $2723
C2/27EA: 9C 94 46     STZ $4694       ; monster condition false
C2/27ED: AD 50 7C     LDA $7C50
C2/27F0: D0 1F        BNE $2811       ; 
C2/27F2: A6 32        LDX $32         ; pointer to attacker properties
C2/27F4: BD 06 20     LDA $2006,X
C2/27F7: 1D 07 20     ORA $2007,X
C2/27FA: F0 07        BEQ $2803       ; branch if zero hp
C2/27FC: BD 1A 20     LDA $201A,X
C2/27FF: 29 C0        AND #$C0
C2/2801: F0 07        BEQ $280A       ; branch if not wound or stone
C2/2803: A5 0E        LDA $0E
C2/2805: C9 0F        CMP #$0F
C2/2807: F0 08        BEQ $2811       ; only do "if dead" condition
C2/2809: 60           RTS 
C2/280A: A5 0E        LDA $0E
C2/280C: C9 0F        CMP #$0F
C2/280E: D0 01        BNE $2811       ; don't do "if dead" condition
C2/2810: 60           RTS 
C2/2811: DC 08 00     JML [$0008]

; monster condition jump table
C2/2814:              .DW $283A, $283E, $289D, $28DB, $28EB, $291F, $2939, $29B1
C2/2824:              .DW $2A29, $2A63, $2A9D, $2AD2, $2B19, $2B2A, $2B6F, $2B87
C2/2834:              .DW $2B93, $2BC0, $2BFD

; [ monster condition $00: always ]

C2/283A: EE 94 46     INC $4694       ; monster condition true
C2/283D: 60           RTS 

; [ monster condition $01: status ]

C2/283E: AD 21 27     LDA $2721
C2/2841: 20 27 2C     JSR $2C27       ; get monster script targets
C2/2844: AD 22 27     LDA $2722
C2/2847: AA           TAX 
C2/2848: 86 0E        STX $0E
C2/284A: 7B           TDC 
C2/284B: A8           TAY 
C2/284C: C2 20        REP #$20
C2/284E: B9 20 26     LDA $2620,Y
C2/2851: C9 FF FF     CMP #$FFFF
C2/2854: D0 05        BNE $285B
C2/2856: 7B           TDC 
C2/2857: E2 20        SEP #$20
C2/2859: 80 31        BRA $288C
C2/285B: 85 10        STA $10
C2/285D: 18           CLC 
C2/285E: 65 0E        ADC $0E
C2/2860: AA           TAX 
C2/2861: 7B           TDC 
C2/2862: E2 20        SEP #$20
C2/2864: BD 1A 20     LDA $201A,X
C2/2867: 1D 70 20     ORA $2070,X
C2/286A: 2D 23 27     AND $2723
C2/286D: D0 13        BNE $2882
C2/286F: A5 0E        LDA $0E
C2/2871: D0 12        BNE $2885
C2/2873: AD 23 27     LDA $2723
C2/2876: 10 0D        BPL $2885
C2/2878: A6 10        LDX $10
C2/287A: BD 06 20     LDA $2006,X
C2/287D: 1D 06 20     ORA $2006,X
C2/2880: D0 03        BNE $2885
C2/2882: EE 94 46     INC $4694       ; monster condition true
C2/2885: C8           INY 
C2/2886: C8           INY 
C2/2887: C0 18 00     CPY #$0018
C2/288A: D0 C0        BNE $284C
C2/288C: AD 24 27     LDA $2724
C2/288F: F0 0B        BEQ $289C
C2/2891: AD 25 27     LDA $2725
C2/2894: CD 94 46     CMP $4694
C2/2897: F0 03        BEQ $289C
C2/2899: 9C 94 46     STZ $4694       ; monster condition false
C2/289C: 60           RTS 

; [ monster condition $02: hp ]

C2/289D: AD 21 27     LDA $2721
C2/28A0: 20 27 2C     JSR $2C27       ; get monster script targets
C2/28A3: 7B           TDC 
C2/28A4: A8           TAY 
C2/28A5: C2 20        REP #$20
C2/28A7: B9 20 26     LDA $2620,Y
C2/28AA: AA           TAX 
C2/28AB: C9 FF FF     CMP #$FFFF
C2/28AE: F0 17        BEQ $28C7
C2/28B0: BD 06 20     LDA $2006,X
C2/28B3: CD 22 27     CMP $2722
C2/28B6: B0 03        BCS $28BB
C2/28B8: EE 94 46     INC $4694       ; monster condition true
C2/28BB: 7B           TDC 
C2/28BC: E2 20        SEP #$20
C2/28BE: C8           INY 
C2/28BF: C8           INY 
C2/28C0: C0 18 00     CPY #$0018
C2/28C3: D0 E0        BNE $28A5
C2/28C5: 80 03        BRA $28CA
C2/28C7: 7B           TDC 
C2/28C8: E2 20        SEP #$20
C2/28CA: AD 24 27     LDA $2724
C2/28CD: F0 0B        BEQ $28DA
C2/28CF: AD 25 27     LDA $2725
C2/28D2: CD 94 46     CMP $4694
C2/28D5: F0 03        BEQ $28DA
C2/28D7: 9C 94 46     STZ $4694       ; monster condition false
C2/28DA: 60           RTS 

; [ monster condition $03: variable ]

C2/28DB: AD 22 27     LDA $2722
C2/28DE: AA           TAX 
C2/28DF: BD 63 43     LDA $4363,X     ; battle variable
C2/28E2: CD 23 27     CMP $2723
C2/28E5: D0 03        BNE $28EA
C2/28E7: EE 94 46     INC $4694       ; monster condition true
C2/28EA: 60           RTS 

; [ monster condition $04: alone ]

C2/28EB: AD 22 27     LDA $2722
C2/28EE: D0 0A        BNE $28FA
C2/28F0: AD 48 40     LDA $4048
C2/28F3: 20 C3 01     JSR $01C3       ; count set bits
C2/28F6: CA           DEX 
C2/28F7: F0 22        BEQ $291B
C2/28F9: 60           RTS 
C2/28FA: AD 03 7C     LDA $7C03
C2/28FD: 0A           ASL 
C2/28FE: AA           TAX 
C2/28FF: BD 20 40     LDA $4020,X
C2/2902: 85 0E        STA $0E
C2/2904: 7B           TDC 
C2/2905: A8           TAY 
C2/2906: B9 C6 3E     LDA $3EC6,Y
C2/2909: F0 0A        BEQ $2915
C2/290B: 98           TYA 
C2/290C: 0A           ASL 
C2/290D: AA           TAX 
C2/290E: BD 20 40     LDA $4020,X
C2/2911: C5 0E        CMP $0E
C2/2913: D0 09        BNE $291E
C2/2915: C8           INY 
C2/2916: C0 08 00     CPY #$0008
C2/2919: D0 EB        BNE $2906
C2/291B: EE 94 46     INC $4694       ; monster condition true
C2/291E: 60           RTS 

; [ monster condition $05:  ]

C2/291F: AD 21 27     LDA $2721
C2/2922: F0 09        BEQ $292D
C2/2924: AD 48 40     LDA $4048
C2/2927: CD 23 27     CMP $2723
C2/292A: D0 09        BNE $2935
C2/292C: 60           RTS 
C2/292D: AD 48 40     LDA $4048
C2/2930: CD 23 27     CMP $2723
C2/2933: D0 03        BNE $2938
C2/2935: EE 94 46     INC $4694       ; monster condition true
C2/2938: 60           RTS 

; [ monster condition $06:  ]

C2/2939: A6 32        LDX $32
C2/293B: AD 53 47     LDA $4753
C2/293E: 29 01        AND #$01
C2/2940: D0 36        BNE $2978
C2/2942: AD 22 27     LDA $2722
C2/2945: C9 07        CMP #$07
C2/2947: F0 16        BEQ $295F
C2/2949: AD 21 27     LDA $2721
C2/294C: F0 09        BEQ $2957
C2/294E: AD 22 27     LDA $2722
C2/2951: DD 46 20     CMP $2046,X
C2/2954: D0 57        BNE $29AD
C2/2956: 60           RTS 
C2/2957: AD 22 27     LDA $2722
C2/295A: DD 46 20     CMP $2046,X
C2/295D: D0 51        BNE $29B0
C2/295F: AD 21 27     LDA $2721
C2/2962: F0 09        BEQ $296D
C2/2964: AD 23 27     LDA $2723
C2/2967: 3D 49 20     AND $2049,X
C2/296A: F0 41        BEQ $29AD
C2/296C: 60           RTS 
C2/296D: AD 23 27     LDA $2723
C2/2970: F0 3B        BEQ $29AD
C2/2972: 3D 49 20     AND $2049,X
C2/2975: D0 36        BNE $29AD
C2/2977: 60           RTS 
C2/2978: AD 22 27     LDA $2722
C2/297B: C9 07        CMP #$07
C2/297D: F0 16        BEQ $2995
C2/297F: AD 21 27     LDA $2721
C2/2982: F0 09        BEQ $298D
C2/2984: AD 22 27     LDA $2722
C2/2987: DD 4D 20     CMP $204D,X
C2/298A: D0 21        BNE $29AD
C2/298C: 60           RTS 
C2/298D: AD 22 27     LDA $2722
C2/2990: DD 4D 20     CMP $204D,X
C2/2993: D0 1B        BNE $29B0
C2/2995: AD 21 27     LDA $2721
C2/2998: F0 09        BEQ $29A3
C2/299A: AD 23 27     LDA $2723
C2/299D: 3D 7B 20     AND $207B,X
C2/29A0: F0 0B        BEQ $29AD
C2/29A2: 60           RTS 
C2/29A3: AD 23 27     LDA $2723
C2/29A6: F0 05        BEQ $29AD
C2/29A8: 3D 7B 20     AND $207B,X
C2/29AB: F0 03        BEQ $29B0
C2/29AD: EE 94 46     INC $4694       ; monster condition true
C2/29B0: 60           RTS 

; [ monster condition $07:  ]

C2/29B1: A6 32        LDX $32
C2/29B3: AD 53 47     LDA $4753
C2/29B6: 29 01        AND #$01
C2/29B8: D0 36        BNE $29F0
C2/29BA: AD 22 27     LDA $2722
C2/29BD: C9 07        CMP #$07
C2/29BF: F0 16        BEQ $29D7
C2/29C1: AD 21 27     LDA $2721
C2/29C4: F0 09        BEQ $29CF
C2/29C6: AD 22 27     LDA $2722
C2/29C9: DD 46 20     CMP $2046,X
C2/29CC: D0 57        BNE $2A25
C2/29CE: 60           RTS 
C2/29CF: AD 22 27     LDA $2722
C2/29D2: DD 46 20     CMP $2046,X
C2/29D5: D0 51        BNE $2A28
C2/29D7: AD 21 27     LDA $2721
C2/29DA: F0 09        BEQ $29E5
C2/29DC: AD 23 27     LDA $2723
C2/29DF: 3D 4A 20     AND $204A,X
C2/29E2: F0 41        BEQ $2A25
C2/29E4: 60           RTS 
C2/29E5: AD 23 27     LDA $2723
C2/29E8: F0 3B        BEQ $2A25
C2/29EA: 3D 4A 20     AND $204A,X
C2/29ED: D0 36        BNE $2A25
C2/29EF: 60           RTS 
C2/29F0: AD 22 27     LDA $2722
C2/29F3: C9 07        CMP #$07
C2/29F5: F0 16        BEQ $2A0D
C2/29F7: AD 21 27     LDA $2721
C2/29FA: F0 09        BEQ $2A05
C2/29FC: AD 22 27     LDA $2722
C2/29FF: DD 4D 20     CMP $204D,X
C2/2A02: D0 21        BNE $2A25
C2/2A04: 60           RTS 
C2/2A05: AD 22 27     LDA $2722
C2/2A08: DD 4D 20     CMP $204D,X
C2/2A0B: D0 1B        BNE $2A28
C2/2A0D: AD 21 27     LDA $2721
C2/2A10: F0 09        BEQ $2A1B
C2/2A12: AD 23 27     LDA $2723
C2/2A15: 3D 7C 20     AND $207C,X
C2/2A18: F0 0B        BEQ $2A25
C2/2A1A: 60           RTS 
C2/2A1B: AD 23 27     LDA $2723
C2/2A1E: F0 05        BEQ $2A25
C2/2A20: 3D 7C 20     AND $207C,X
C2/2A23: F0 03        BEQ $2A28
C2/2A25: EE 94 46     INC $4694       ; monster condition true
C2/2A28: 60           RTS 

; [ monster condition $08: spell ]

C2/2A29: A6 32        LDX $32
C2/2A2B: AD 53 47     LDA $4753
C2/2A2E: 29 01        AND #$01
C2/2A30: D0 17        BNE $2A49
C2/2A32: AD 21 27     LDA $2721
C2/2A35: F0 09        BEQ $2A40
C2/2A37: BD 47 20     LDA $2047,X
C2/2A3A: CD 22 27     CMP $2722
C2/2A3D: D0 20        BNE $2A5F
C2/2A3F: 60           RTS 
C2/2A40: BD 47 20     LDA $2047,X
C2/2A43: CD 22 27     CMP $2722
C2/2A46: F0 17        BEQ $2A5F
C2/2A48: 60           RTS 
C2/2A49: AD 21 27     LDA $2721
C2/2A4C: F0 09        BEQ $2A57
C2/2A4E: BD 4E 20     LDA $204E,X
C2/2A51: CD 22 27     CMP $2722
C2/2A54: D0 09        BNE $2A5F
C2/2A56: 60           RTS 
C2/2A57: BD 4E 20     LDA $204E,X
C2/2A5A: CD 22 27     CMP $2722
C2/2A5D: D0 03        BNE $2A62
C2/2A5F: EE 94 46     INC $4694       ; monster condition true
C2/2A62: 60           RTS 

; [ monster condition $09: item ]

C2/2A63: A6 32        LDX $32
C2/2A65: AD 53 47     LDA $4753
C2/2A68: 29 01        AND #$01
C2/2A6A: D0 17        BNE $2A83
C2/2A6C: AD 21 27     LDA $2721
C2/2A6F: F0 09        BEQ $2A7A
C2/2A71: BD 48 20     LDA $2048,X
C2/2A74: CD 22 27     CMP $2722
C2/2A77: D0 20        BNE $2A99
C2/2A79: 60           RTS 
C2/2A7A: BD 48 20     LDA $2048,X
C2/2A7D: CD 22 27     CMP $2722
C2/2A80: F0 17        BEQ $2A99
C2/2A82: 60           RTS 
C2/2A83: AD 21 27     LDA $2721
C2/2A86: F0 09        BEQ $2A91
C2/2A88: BD 4F 20     LDA $204F,X
C2/2A8B: CD 22 27     CMP $2722
C2/2A8E: D0 09        BNE $2A99
C2/2A90: 60           RTS 
C2/2A91: BD 4F 20     LDA $204F,X
C2/2A94: CD 22 27     CMP $2722
C2/2A97: D0 03        BNE $2A9C
C2/2A99: EE 94 46     INC $4694       ; monster condition true
C2/2A9C: 60           RTS 

; [ monster condition $0A: targeting ]

C2/2A9D: AD 53 47     LDA $4753
C2/2AA0: 29 01        AND #$01
C2/2AA2: D0 0E        BNE $2AB2
C2/2AA4: A6 32        LDX $32
C2/2AA6: BD 4B 20     LDA $204B,X
C2/2AA9: 20 C3 01     JSR $01C3       ; count set bits
C2/2AAC: CA           DEX 
C2/2AAD: 30 11        BMI $2AC0
C2/2AAF: 4C C1 2A     JMP $2AC1
C2/2AB2: A6 32        LDX $32
C2/2AB4: BD 7D 20     LDA $207D,X
C2/2AB7: 20 C3 01     JSR $01C3       ; count set bits
C2/2ABA: CA           DEX 
C2/2ABB: 30 03        BMI $2AC0
C2/2ABD: 20 C1 2A     JSR $2AC1
C2/2AC0: 60           RTS 
C2/2AC1: AD 23 27     LDA $2723
C2/2AC4: D0 05        BNE $2ACB
C2/2AC6: 8A           TXA 
C2/2AC7: D0 08        BNE $2AD1
C2/2AC9: F0 03        BEQ $2ACE
C2/2ACB: 8A           TXA 
C2/2ACC: F0 03        BEQ $2AD1
C2/2ACE: EE 94 46     INC $4694       ; monster condition true
C2/2AD1: 60           RTS 

; [ monster condition $0B:  ]

; p1: target
; p2: character/monster properties offset (+$2000)
; p3: comparison value

C2/2AD2: AD 21 27     LDA $2721
C2/2AD5: 20 27 2C     JSR $2C27       ; get monster script targets
C2/2AD8: AD 22 27     LDA $2722
C2/2ADB: AA           TAX 
C2/2ADC: 86 0E        STX $0E
C2/2ADE: 7B           TDC 
C2/2ADF: A8           TAY 
C2/2AE0: C2 20        REP #$20
C2/2AE2: B9 20 26     LDA $2620,Y     ; monster script target
C2/2AE5: C9 FF FF     CMP #$FFFF
C2/2AE8: D0 05        BNE $2AEF       ; branch if a valid target
C2/2AEA: 7B           TDC 
C2/2AEB: E2 20        SEP #$20
C2/2AED: 80 19        BRA $2B08
C2/2AEF: 18           CLC 
C2/2AF0: 65 0E        ADC $0E
C2/2AF2: AA           TAX 
C2/2AF3: 7B           TDC 
C2/2AF4: E2 20        SEP #$20
C2/2AF6: BD 00 20     LDA $2000,X
C2/2AF9: CD 23 27     CMP $2723
C2/2AFC: D0 03        BNE $2B01
C2/2AFE: EE 94 46     INC $4694       ; monster condition true
C2/2B01: C8           INY             ; next target
C2/2B02: C8           INY 
C2/2B03: C0 18 00     CPY #$0018
C2/2B06: D0 D8        BNE $2AE0
C2/2B08: AD 24 27     LDA $2724
C2/2B0B: F0 0B        BEQ $2B18
C2/2B0D: AD 25 27     LDA $2725
C2/2B10: CD 94 46     CMP $4694
C2/2B13: F0 03        BEQ $2B18
C2/2B15: 9C 94 46     STZ $4694       ; monster condition false
C2/2B18: 60           RTS 

; [ monster condition $0C:  ]

C2/2B19: C2 20        REP #$20
C2/2B1B: AD A2 00     LDA $00A2
C2/2B1E: CD 22 27     CMP $2722
C2/2B21: 90 03        BCC $2B26
C2/2B23: EE 94 46     INC $4694       ; monster condition true
C2/2B26: 7B           TDC 
C2/2B27: E2 20        SEP #$20
C2/2B29: 60           RTS 

; [ monster condition $0D:  ]

C2/2B2A: AD 22 27     LDA $2722
C2/2B2D: AA           TAX 
C2/2B2E: C9 03        CMP #$03
C2/2B30: D0 31        BNE $2B63
C2/2B32: 64 0E        STZ $0E
C2/2B34: 7B           TDC 
C2/2B35: AA           TAX 
C2/2B36: A8           TAY 
C2/2B37: AD 87 7C     LDA $7C87
C2/2B3A: 20 DB 01     JSR $01DB       ; check bit x
C2/2B3D: F0 0F        BEQ $2B4E
C2/2B3F: DA           PHX 
C2/2B40: B9 00 20     LDA $2000,Y
C2/2B43: 29 07        AND #$07
C2/2B45: AA           TAX 
C2/2B46: A5 0E        LDA $0E
C2/2B48: 20 D6 01     JSR $01D6       ; set bit x
C2/2B4B: 85 0E        STA $0E
C2/2B4D: FA           PLX 
C2/2B4E: C2 20        REP #$20
C2/2B50: 98           TYA 
C2/2B51: 18           CLC 
C2/2B52: 69 80 00     ADC #$0080
C2/2B55: A8           TAY 
C2/2B56: 7B           TDC 
C2/2B57: E2 20        SEP #$20
C2/2B59: E8           INX 
C2/2B5A: E0 04 00     CPX #$0004
C2/2B5D: D0 D8        BNE $2B37
C2/2B5F: A5 0E        LDA $0E
C2/2B61: 80 03        BRA $2B66
C2/2B63: BD 84 7C     LDA $7C84,X
C2/2B66: 2D 23 27     AND $2723
C2/2B69: F0 03        BEQ $2B6E
C2/2B6B: EE 94 46     INC $4694       ; monster condition true
C2/2B6E: 60           RTS 

; [ monster condition $0E: hp damage ]

C2/2B6F: AD 53 47     LDA $4753
C2/2B72: 29 01        AND #$01
C2/2B74: D0 08        BNE $2B7E
C2/2B76: A6 32        LDX $32
C2/2B78: BD 4C 20     LDA $204C,X
C2/2B7B: D0 06        BNE $2B83
C2/2B7D: 60           RTS 
C2/2B7E: BD 7E 20     LDA $207E,X
C2/2B81: F0 03        BEQ $2B86
C2/2B83: EE 94 46     INC $4694       ; monster condition true
C2/2B86: 60           RTS 

; [ monster condition $0F: dead ]

C2/2B87: 9C 51 47     STZ $4751
C2/2B8A: A9 01        LDA #$01
C2/2B8C: 8D 50 7C     STA $7C50
C2/2B8F: 8D 94 46     STA $4694       ; monster condition true
C2/2B92: 60           RTS 

; [ monster condition $10: only one character alive ]

C2/2B93: 7B           TDC 
C2/2B94: AA           TAX 
C2/2B95: A8           TAY 
C2/2B96: 84 0E        STY $0E
C2/2B98: B9 C2 3E     LDA $3EC2,Y
C2/2B9B: F0 11        BEQ $2BAE
C2/2B9D: BD 1A 20     LDA $201A,X
C2/2BA0: 29 C2        AND #$C2
C2/2BA2: D0 0A        BNE $2BAE       ; branch if wound, stone, or zombie
C2/2BA4: BD 06 20     LDA $2006,X
C2/2BA7: 1D 07 20     ORA $2007,X
C2/2BAA: F0 02        BEQ $2BAE       ; branch if zero hp
C2/2BAC: E6 0E        INC $0E         ; increment number of characters
C2/2BAE: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2BB1: C8           INY 
C2/2BB2: C0 04 00     CPY #$0004
C2/2BB5: D0 E1        BNE $2B98
C2/2BB7: A5 0E        LDA $0E
C2/2BB9: 3A           DEC 
C2/2BBA: D0 03        BNE $2BBF       ; branch if more than one character
C2/2BBC: EE 94 46     INC $4694
C2/2BBF: 60           RTS 

; [ monster condition $11: summon ]

C2/2BC0: AD 53 47     LDA $4753
C2/2BC3: 29 01        AND #$01
C2/2BC5: D0 1A        BNE $2BE1
C2/2BC7: A6 32        LDX $32
C2/2BC9: BD 46 20     LDA $2046,X
C2/2BCC: C9 2B        CMP #$2B
C2/2BCE: F0 04        BEQ $2BD4
C2/2BD0: C9 17        CMP #$17
C2/2BD2: D0 28        BNE $2BFC
C2/2BD4: BD 47 20     LDA $2047,X
C2/2BD7: C9 48        CMP #$48
C2/2BD9: 90 21        BCC $2BFC
C2/2BDB: C9 57        CMP #$57
C2/2BDD: B0 1D        BCS $2BFC
C2/2BDF: 80 18        BRA $2BF9
C2/2BE1: A6 32        LDX $32
C2/2BE3: BD 4D 20     LDA $204D,X
C2/2BE6: C9 2B        CMP #$2B
C2/2BE8: F0 04        BEQ $2BEE
C2/2BEA: C9 17        CMP #$17
C2/2BEC: D0 0E        BNE $2BFC
C2/2BEE: BD 4E 20     LDA $204E,X
C2/2BF1: C9 48        CMP #$48
C2/2BF3: 90 07        BCC $2BFC
C2/2BF5: C9 57        CMP #$57
C2/2BF7: B0 03        BCS $2BFC
C2/2BF9: EE 94 46     INC $4694
C2/2BFC: 60           RTS 

; [ monster condition $12: no female characters ]

C2/2BFD: 7B           TDC 
C2/2BFE: AA           TAX 
C2/2BFF: A8           TAY 
C2/2C00: BD 00 20     LDA $2000,X
C2/2C03: 29 08        AND #$08
C2/2C05: F0 13        BEQ $2C1A       ; branch if not female
C2/2C07: B9 C2 3E     LDA $3EC2,Y
C2/2C0A: F0 0E        BEQ $2C1A       ; 
C2/2C0C: BD 1D 20     LDA $201D,X
C2/2C0F: 29 81        AND #$81
C2/2C11: D0 07        BNE $2C1A       ; branch if erased or hidden
C2/2C13: BD 1E 20     LDA $201E,X
C2/2C16: 29 10        AND #$10
C2/2C18: F0 0C        BEQ $2C26       ; branch if not jumping
C2/2C1A: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2C1D: C8           INY 
C2/2C1E: C0 04 00     CPY #$0004
C2/2C21: D0 DD        BNE $2C00
C2/2C23: EE 94 46     INC $4694
C2/2C26: 60           RTS 

; [ get monster script targets ]

C2/2C27: 0A           ASL 
C2/2C28: AA           TAX 
C2/2C29: BF 4D 2C C2  LDA $C22C4D,X
C2/2C2D: 85 08        STA $08
C2/2C2F: BF 4E 2C C2  LDA $C22C4E,X
C2/2C33: 85 09        STA $09
C2/2C35: A9 C2        LDA #$C2
C2/2C37: 85 0A        STA $0A
C2/2C39: A2 17 00     LDX #$0017
C2/2C3C: A9 FF        LDA #$FF
C2/2C3E: 9D 20 26     STA $2620,X     ; clear monster script targets
C2/2C41: CA           DEX 
C2/2C42: 10 FA        BPL $2C3E
C2/2C44: 9C 24 27     STZ $2724
C2/2C47: 9C 25 27     STZ $2725
C2/2C4A: DC 08 00     JML [$0008]

; monster script target jump table
C2/2C4D:              .DW $2CB3, $2CDA, $2CE0, $2CE6, $2CEC, $2CF2, $2CFE, $2D0A ; $00
C2/2C5D:              .DW $2D16, $2D22, $2D2E, $2D3A, $2D46, $2D52, $2D79, $2DBD
C2/2C6D:              .DW $2DC6, $2DCD, $2DD3, $2E18, $2E25, $2E2D, $2E37, $2E44 ; $10
C2/2C7D:              .DW $2E4F, $2E59, $2E62, $2E65, $2EA6, $2F00, $2F0B, $2F19
C2/2C8D:              .DW $2F24, $2F27, $2F70, $2FAB, $2FB7, $2FC0, $2FC3, $3019 ; $20
C2/2C9D:              .DW $305D, $309B, $30A1, $30A7, $30AD, $30B3, $30C2, $30F1
C2/2CAD:              .DW $3115, $311B, $3121                                    ; $30

; [ monster target $00: bartz ]

C2/2CB3: 64 0E        STZ $0E
C2/2CB5: 7B           TDC 
C2/2CB6: A8           TAY 
C2/2CB7: AA           TAX 
C2/2CB8: BD 00 20     LDA $2000,X
C2/2CBB: 29 07        AND #$07
C2/2CBD: C5 0E        CMP $0E
C2/2CBF: D0 0F        BNE $2CD0
C2/2CC1: B9 C2 3E     LDA $3EC2,Y
C2/2CC4: F0 13        BEQ $2CD9
C2/2CC6: 20 27 31     JSR $3127
C2/2CC9: D0 0E        BNE $2CD9
C2/2CCB: 8E 20 26     STX $2620
C2/2CCE: 80 09        BRA $2CD9
C2/2CD0: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2CD3: C8           INY 
C2/2CD4: C0 04 00     CPY #$0004
C2/2CD7: D0 DF        BNE $2CB8
C2/2CD9: 60           RTS 

; [ monster target $01: lenna ]

C2/2CDA: A9 01        LDA #$01
C2/2CDC: 85 0E        STA $0E
C2/2CDE: 80 D5        BRA $2CB5

; [ monster target $02: galuf ]

C2/2CE0: A9 02        LDA #$02
C2/2CE2: 85 0E        STA $0E
C2/2CE4: 80 CF        BRA $2CB5

; [ monster target $03: faris ]

C2/2CE6: A9 03        LDA #$03
C2/2CE8: 85 0E        STA $0E
C2/2CEA: 80 C9        BRA $2CB5

; [ monster target $04: krile ]

C2/2CEC: A9 04        LDA #$04
C2/2CEE: 85 0E        STA $0E
C2/2CF0: 80 C3        BRA $2CB5

; [ monster target $05: monster slot 1 ]

C2/2CF2: AD C6 3E     LDA $3EC6
C2/2CF5: F0 06        BEQ $2CFD
C2/2CF7: A2 00 02     LDX #$0200
C2/2CFA: 8E 20 26     STX $2620
C2/2CFD: 60           RTS 

; [ monster target $06: monster slot 2 ]

C2/2CFE: AD C7 3E     LDA $3EC7
C2/2D01: F0 06        BEQ $2D09
C2/2D03: A2 80 02     LDX #$0280
C2/2D06: 8E 20 26     STX $2620
C2/2D09: 60           RTS 

; [ monster target $07: monster slot 3 ]

C2/2D0A: AD C8 3E     LDA $3EC8
C2/2D0D: F0 06        BEQ $2D15
C2/2D0F: A2 00 03     LDX #$0300
C2/2D12: 8E 20 26     STX $2620
C2/2D15: 60           RTS 

; [ monster target $08: monster slot 4 ]

C2/2D16: AD C9 3E     LDA $3EC9
C2/2D19: F0 06        BEQ $2D21
C2/2D1B: A2 80 03     LDX #$0380
C2/2D1E: 8E 20 26     STX $2620
C2/2D21: 60           RTS 

; [ monster target $09: monster slot 5 ]

C2/2D22: AD CA 3E     LDA $3ECA
C2/2D25: F0 06        BEQ $2D2D
C2/2D27: A2 00 04     LDX #$0400
C2/2D2A: 8E 20 26     STX $2620
C2/2D2D: 60           RTS 

; [ monster target $0A: monster slot 6 ]

C2/2D2E: AD CB 3E     LDA $3ECB
C2/2D31: F0 06        BEQ $2D39
C2/2D33: A2 80 04     LDX #$0480
C2/2D36: 8E 20 26     STX $2620
C2/2D39: 60           RTS 

; [ monster target $0B: monster slot 7 ]

C2/2D3A: AD CC 3E     LDA $3ECC
C2/2D3D: F0 06        BEQ $2D45
C2/2D3F: A2 00 05     LDX #$0500
C2/2D42: 8E 20 26     STX $2620
C2/2D45: 60           RTS 

; [ monster target $0C: monster slot 8 ]

C2/2D46: AD CD 3E     LDA $3ECD
C2/2D49: F0 06        BEQ $2D51
C2/2D4B: A2 80 05     LDX #$0580
C2/2D4E: 8E 20 26     STX $2620
C2/2D51: 60           RTS 

; [ monster target $0D: self ]

C2/2D52: AD 56 7C     LDA $7C56
C2/2D55: F0 13        BEQ $2D6A
C2/2D57: 3A           DEC 
C2/2D58: F0 08        BEQ $2D62
C2/2D5A: CE 56 7C     DEC $7C56
C2/2D5D: AD 55 47     LDA $4755
C2/2D60: 80 0A        BRA $2D6C
C2/2D62: 18           CLC 
C2/2D63: AD 55 47     LDA $4755
C2/2D66: 69 04        ADC #$04
C2/2D68: 80 02        BRA $2D6C
C2/2D6A: A5 47        LDA $47
C2/2D6C: C2 20        REP #$20
C2/2D6E: 20 B2 01     JSR $01B2       ; a << 7
C2/2D71: AA           TAX 
C2/2D72: 7B           TDC 
C2/2D73: E2 20        SEP #$20
C2/2D75: 8E 20 26     STX $2620
C2/2D78: 60           RTS 

; [ monster target $0E:  ]

C2/2D79: AD 03 7C     LDA $7C03
C2/2D7C: 85 12        STA $12
C2/2D7E: EE 24 27     INC $2724
C2/2D81: 7B           TDC 
C2/2D82: AA           TAX 
C2/2D83: 86 0E        STX $0E
C2/2D85: 86 10        STX $10
C2/2D87: A2 00 02     LDX #$0200
C2/2D8A: A4 10        LDY $10
C2/2D8C: B9 C6 3E     LDA $3EC6,Y
C2/2D8F: F0 20        BEQ $2DB1
C2/2D91: A5 10        LDA $10
C2/2D93: C5 12        CMP $12
C2/2D95: F0 1A        BEQ $2DB1
C2/2D97: 20 27 31     JSR $3127
C2/2D9A: D0 15        BNE $2DB1
C2/2D9C: A4 0E        LDY $0E
C2/2D9E: 86 08        STX $08
C2/2DA0: A5 08        LDA $08
C2/2DA2: 99 20 26     STA $2620,Y
C2/2DA5: A5 09        LDA $09
C2/2DA7: 99 21 26     STA $2621,Y
C2/2DAA: C8           INY 
C2/2DAB: C8           INY 
C2/2DAC: 84 0E        STY $0E
C2/2DAE: EE 25 27     INC $2725
C2/2DB1: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2DB4: E6 10        INC $10
C2/2DB6: A5 10        LDA $10
C2/2DB8: C9 08        CMP #$08
C2/2DBA: D0 CE        BNE $2D8A
C2/2DBC: 60           RTS 

; [ monster target $0F:  ]

C2/2DBD: A9 FF        LDA #$FF
C2/2DBF: 85 12        STA $12
C2/2DC1: EE 24 27     INC $2724
C2/2DC4: 80 BB        BRA $2D81

; [ monster target $10:  ]

C2/2DC6: AD 03 7C     LDA $7C03
C2/2DC9: 85 12        STA $12
C2/2DCB: 80 B4        BRA $2D81

; [ monster target $11:  ]

C2/2DCD: A9 FF        LDA #$FF
C2/2DCF: 85 12        STA $12
C2/2DD1: 80 AE        BRA $2D81

; [ monster target $12:  ]

C2/2DD3: A9 80        LDA #$80
C2/2DD5: 85 12        STA $12
C2/2DD7: 64 13        STZ $13
C2/2DD9: EE 24 27     INC $2724
C2/2DDC: 7B           TDC 
C2/2DDD: AA           TAX 
C2/2DDE: 86 0E        STX $0E
C2/2DE0: 86 10        STX $10
C2/2DE2: A4 10        LDY $10
C2/2DE4: B9 C2 3E     LDA $3EC2,Y
C2/2DE7: F0 23        BEQ $2E0C
C2/2DE9: 20 27 31     JSR $3127
C2/2DEC: D0 1E        BNE $2E0C
C2/2DEE: BD 00 20     LDA $2000,X
C2/2DF1: 25 12        AND $12
C2/2DF3: C5 13        CMP $13
C2/2DF5: D0 15        BNE $2E0C
C2/2DF7: A4 0E        LDY $0E
C2/2DF9: 86 08        STX $08
C2/2DFB: A5 08        LDA $08
C2/2DFD: 99 20 26     STA $2620,Y
C2/2E00: A5 09        LDA $09
C2/2E02: 99 21 26     STA $2621,Y
C2/2E05: C8           INY 
C2/2E06: C8           INY 
C2/2E07: 84 0E        STY $0E
C2/2E09: EE 25 27     INC $2725
C2/2E0C: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2E0F: E6 10        INC $10
C2/2E11: A5 10        LDA $10
C2/2E13: C9 04        CMP #$04
C2/2E15: D0 CB        BNE $2DE2
C2/2E17: 60           RTS 

; [ monster target $13:  ]

C2/2E18: A9 80        LDA #$80
C2/2E1A: 85 12        STA $12
C2/2E1C: A9 80        LDA #$80
C2/2E1E: 85 13        STA $13
C2/2E20: EE 24 27     INC $2724
C2/2E23: 80 B7        BRA $2DDC

; [ monster target $14:  ]

C2/2E25: A9 80        LDA #$80
C2/2E27: 85 12        STA $12
C2/2E29: 64 13        STZ $13
C2/2E2B: 80 AF        BRA $2DDC

; [ monster target $15:  ]

C2/2E2D: A9 80        LDA #$80
C2/2E2F: 85 12        STA $12
C2/2E31: A9 80        LDA #$80
C2/2E33: 85 13        STA $13
C2/2E35: 80 A5        BRA $2DDC

; [ monster target $16:  ]

C2/2E37: A9 08        LDA #$08
C2/2E39: 85 12        STA $12
C2/2E3B: A9 08        LDA #$08
C2/2E3D: 85 13        STA $13
C2/2E3F: EE 24 27     INC $2724
C2/2E42: 80 98        BRA $2DDC

; [ monster target $17:  ]

C2/2E44: A9 08        LDA #$08
C2/2E46: 85 12        STA $12
C2/2E48: 64 13        STZ $13
C2/2E4A: EE 24 27     INC $2724
C2/2E4D: 80 8D        BRA $2DDC

; [ monster target $18:  ]

C2/2E4F: A9 08        LDA #$08
C2/2E51: 85 12        STA $12
C2/2E53: A9 08        LDA #$08
C2/2E55: 85 13        STA $13
C2/2E57: 80 83        BRA $2DDC

; [ monster target $19:  ]

C2/2E59: A9 08        LDA #$08
C2/2E5B: 85 12        STA $12
C2/2E5D: 64 13        STZ $13
C2/2E5F: 4C DC 2D     JMP $2DDC

; [ monster target $1A:  ]

C2/2E62: EE 24 27     INC $2724
; fallthrough

; [ monster target $1B:  ]

C2/2E65: 7B           TDC 
C2/2E66: AA           TAX 
C2/2E67: 86 0E        STX $0E
C2/2E69: 86 10        STX $10
C2/2E6B: BD 1A 20     LDA $201A,X
C2/2E6E: 29 40        AND #$40
C2/2E70: D0 28        BNE $2E9A
C2/2E72: BD 1D 20     LDA $201D,X
C2/2E75: 29 81        AND #$81
C2/2E77: D0 21        BNE $2E9A
C2/2E79: BD 1E 20     LDA $201E,X
C2/2E7C: 29 10        AND #$10
C2/2E7E: D0 1A        BNE $2E9A
C2/2E80: BD 1A 20     LDA $201A,X
C2/2E83: 10 15        BPL $2E9A
C2/2E85: A4 0E        LDY $0E
C2/2E87: 86 08        STX $08
C2/2E89: A5 08        LDA $08
C2/2E8B: 99 20 26     STA $2620,Y
C2/2E8E: A5 09        LDA $09
C2/2E90: 99 21 26     STA $2621,Y
C2/2E93: C8           INY 
C2/2E94: C8           INY 
C2/2E95: 84 0E        STY $0E
C2/2E97: EE 25 27     INC $2725
C2/2E9A: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2E9D: E6 10        INC $10
C2/2E9F: A5 10        LDA $10
C2/2EA1: C9 04        CMP #$04
C2/2EA3: D0 C6        BNE $2E6B
C2/2EA5: 60           RTS 

; [ monster target $1C:  ]

C2/2EA6: A9 1C        LDA #$1C
C2/2EA8: AA           TAX 
C2/2EA9: 86 14        STX $14
C2/2EAB: A9 80        LDA #$80
C2/2EAD: 85 12        STA $12
C2/2EAF: EE 24 27     INC $2724
C2/2EB2: 7B           TDC 
C2/2EB3: AA           TAX 
C2/2EB4: 86 0E        STX $0E
C2/2EB6: 86 10        STX $10
C2/2EB8: A2 00 02     LDX #$0200
C2/2EBB: DA           PHX 
C2/2EBC: A4 10        LDY $10
C2/2EBE: B9 C6 3E     LDA $3EC6,Y
C2/2EC1: F0 30        BEQ $2EF3
C2/2EC3: 20 27 31     JSR $3127
C2/2EC6: D0 2B        BNE $2EF3
C2/2EC8: C2 20        REP #$20
C2/2ECA: 18           CLC 
C2/2ECB: 8A           TXA 
C2/2ECC: 65 14        ADC $14
C2/2ECE: AA           TAX 
C2/2ECF: 7B           TDC 
C2/2ED0: E2 20        SEP #$20
C2/2ED2: BD 00 20     LDA $2000,X
C2/2ED5: 1D 56 20     ORA $2056,X
C2/2ED8: 25 12        AND $12
C2/2EDA: C5 12        CMP $12
C2/2EDC: D0 15        BNE $2EF3
C2/2EDE: A4 0E        LDY $0E
C2/2EE0: 86 08        STX $08
C2/2EE2: A5 08        LDA $08
C2/2EE4: 99 20 26     STA $2620,Y
C2/2EE7: A5 09        LDA $09
C2/2EE9: 99 21 26     STA $2621,Y
C2/2EEC: C8           INY 
C2/2EED: C8           INY 
C2/2EEE: 84 0E        STY $0E
C2/2EF0: EE 25 27     INC $2725
C2/2EF3: FA           PLX 
C2/2EF4: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2EF7: E6 10        INC $10
C2/2EF9: A5 10        LDA $10
C2/2EFB: C9 08        CMP #$08
C2/2EFD: D0 BC        BNE $2EBB
C2/2EFF: 60           RTS 

; [ monster target $1D:  ]

C2/2F00: A9 1C        LDA #$1C
C2/2F02: AA           TAX 
C2/2F03: 86 14        STX $14
C2/2F05: A9 80        LDA #$80
C2/2F07: 85 12        STA $12
C2/2F09: 80 A7        BRA $2EB2

; [ monster target $1E:  ]

C2/2F0B: A9 1D        LDA #$1D
C2/2F0D: AA           TAX 
C2/2F0E: 86 14        STX $14
C2/2F10: A9 02        LDA #$02
C2/2F12: 85 12        STA $12
C2/2F14: EE 24 27     INC $2724
C2/2F17: 80 99        BRA $2EB2

; [ monster target $1F:  ]

C2/2F19: A9 1D        LDA #$1D
C2/2F1B: AA           TAX 
C2/2F1C: 86 14        STX $14
C2/2F1E: A9 02        LDA #$02
C2/2F20: 85 12        STA $12
C2/2F22: 80 8E        BRA $2EB2

; [ monster target $20:  ]

C2/2F24: EE 24 27     INC $2724

; [ monster target $21:  ]

C2/2F27: 7B           TDC 
C2/2F28: AA           TAX 
C2/2F29: 86 0E        STX $0E
C2/2F2B: 86 10        STX $10
C2/2F2D: A2 00 02     LDX #$0200
C2/2F30: A4 10        LDY $10
C2/2F32: B9 C6 3E     LDA $3EC6,Y
C2/2F35: F0 2D        BEQ $2F64
C2/2F37: 20 27 31     JSR $3127
C2/2F3A: D0 28        BNE $2F64
C2/2F3C: C2 20        REP #$20
C2/2F3E: BD 08 20     LDA $2008,X
C2/2F41: 4A           LSR 
C2/2F42: DD 06 20     CMP $2006,X
C2/2F45: B0 05        BCS $2F4C
C2/2F47: 7B           TDC 
C2/2F48: E2 20        SEP #$20
C2/2F4A: 80 18        BRA $2F64
C2/2F4C: 7B           TDC 
C2/2F4D: E2 20        SEP #$20
C2/2F4F: A4 0E        LDY $0E
C2/2F51: 86 08        STX $08
C2/2F53: A5 08        LDA $08
C2/2F55: 99 20 26     STA $2620,Y
C2/2F58: A5 09        LDA $09
C2/2F5A: 99 21 26     STA $2621,Y
C2/2F5D: C8           INY 
C2/2F5E: C8           INY 
C2/2F5F: 84 0E        STY $0E
C2/2F61: EE 25 27     INC $2725
C2/2F64: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2F67: E6 10        INC $10
C2/2F69: A5 10        LDA $10
C2/2F6B: C9 08        CMP #$08
C2/2F6D: D0 C1        BNE $2F30
C2/2F6F: 60           RTS 

; [ monster target $22:  ]

C2/2F70: 7B           TDC 
C2/2F71: AA           TAX 
C2/2F72: 86 0E        STX $0E
C2/2F74: 86 10        STX $10
C2/2F76: A4 10        LDY $10
C2/2F78: B9 C2 3E     LDA $3EC2,Y
C2/2F7B: F0 22        BEQ $2F9F
C2/2F7D: 20 27 31     JSR $3127
C2/2F80: D0 1D        BNE $2F9F
C2/2F82: BD 1C 20     LDA $201C,X
C2/2F85: 1D 72 20     ORA $2072,X
C2/2F88: 10 15        BPL $2F9F
C2/2F8A: A4 0E        LDY $0E
C2/2F8C: 86 08        STX $08
C2/2F8E: A5 08        LDA $08
C2/2F90: 99 20 26     STA $2620,Y
C2/2F93: A5 09        LDA $09
C2/2F95: 99 21 26     STA $2621,Y
C2/2F98: C8           INY 
C2/2F99: C8           INY 
C2/2F9A: 84 0E        STY $0E
C2/2F9C: EE 25 27     INC $2725
C2/2F9F: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/2FA2: E6 10        INC $10
C2/2FA4: A5 10        LDA $10
C2/2FA6: C9 04        CMP #$04
C2/2FA8: D0 CC        BNE $2F76
C2/2FAA: 60           RTS 

; [ monster target $23:  ]

C2/2FAB: A9 40        LDA #$40
C2/2FAD: 85 12        STA $12
C2/2FAF: 64 13        STZ $13
C2/2FB1: EE 24 27     INC $2724
C2/2FB4: 4C DC 2D     JMP $2DDC

; [ monster target $24:  ]

C2/2FB7: A9 40        LDA #$40
C2/2FB9: 85 12        STA $12
C2/2FBB: 64 13        STZ $13
C2/2FBD: 4C DC 2D     JMP $2DDC

; [ monster target $25:  ]

C2/2FC0: EE 24 27     INC $2724

; [ monster target $26:  ]

C2/2FC3: 7B           TDC 
C2/2FC4: AA           TAX 
C2/2FC5: 86 0E        STX $0E
C2/2FC7: 86 10        STX $10
C2/2FC9: A2 00 02     LDX #$0200
C2/2FCC: BD 1A 20     LDA $201A,X
C2/2FCF: 29 40        AND #$40
C2/2FD1: D0 3A        BNE $300D
C2/2FD3: E0 00 02     CPX #$0200
C2/2FD6: 90 05        BCC $2FDD
C2/2FD8: AD 4C 7C     LDA $7C4C
C2/2FDB: D0 0E        BNE $2FEB
C2/2FDD: BD 1D 20     LDA $201D,X
C2/2FE0: 29 81        AND #$81
C2/2FE2: D0 29        BNE $300D
C2/2FE4: BD 1E 20     LDA $201E,X
C2/2FE7: 29 10        AND #$10
C2/2FE9: D0 22        BNE $300D
C2/2FEB: BD 1A 20     LDA $201A,X
C2/2FEE: 30 08        BMI $2FF8
C2/2FF0: BD 06 20     LDA $2006,X
C2/2FF3: 1D 07 20     ORA $2007,X
C2/2FF6: D0 15        BNE $300D
C2/2FF8: A4 0E        LDY $0E
C2/2FFA: 86 08        STX $08
C2/2FFC: A5 08        LDA $08
C2/2FFE: 99 20 26     STA $2620,Y
C2/3001: A5 09        LDA $09
C2/3003: 99 21 26     STA $2621,Y
C2/3006: C8           INY 
C2/3007: C8           INY 
C2/3008: 84 0E        STY $0E
C2/300A: EE 25 27     INC $2725
C2/300D: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/3010: E6 10        INC $10
C2/3012: A5 10        LDA $10
C2/3014: C9 08        CMP #$08
C2/3016: D0 B4        BNE $2FCC
C2/3018: 60           RTS 

; [ monster target $27:  ]

C2/3019: 7B           TDC 
C2/301A: A8           TAY 
C2/301B: 38           SEC 
C2/301C: A5 41        LDA $41
C2/301E: E9 1B        SBC #$1B
C2/3020: AA           TAX 
C2/3021: BD 67 43     LDA $4367,X
C2/3024: F0 36        BEQ $305C
C2/3026: 85 12        STA $12
C2/3028: AD 56 7C     LDA $7C56
C2/302B: D0 07        BNE $3034
C2/302D: 38           SEC 
C2/302E: A5 47        LDA $47
C2/3030: E9 04        SBC #$04
C2/3032: 80 03        BRA $3037
C2/3034: AD 55 47     LDA $4755
C2/3037: AA           TAX 
C2/3038: 86 10        STX $10
C2/303A: A5 12        LDA $12
C2/303C: 0A           ASL 
C2/303D: B0 03        BCS $3042
C2/303F: C8           INY 
C2/3040: 80 FA        BRA $303C
C2/3042: C4 10        CPY $10
C2/3044: D0 03        BNE $3049
C2/3046: C8           INY 
C2/3047: 80 F3        BRA $303C
C2/3049: 98           TYA 
C2/304A: 18           CLC 
C2/304B: 69 04        ADC #$04
C2/304D: AA           TAX 
C2/304E: FE C2 3E     INC $3EC2,X
C2/3051: C2 20        REP #$20
C2/3053: 20 B2 01     JSR $01B2       ; a << 7
C2/3056: 8D 20 26     STA $2620
C2/3059: 7B           TDC 
C2/305A: E2 20        SEP #$20
C2/305C: 60           RTS 

; [ monster target $28:  ]

C2/305D: 64 0E        STZ $0E
C2/305F: 7B           TDC 
C2/3060: A8           TAY 
C2/3061: AA           TAX 
C2/3062: BD 00 20     LDA $2000,X
C2/3065: 29 07        AND #$07
C2/3067: C5 0E        CMP $0E
C2/3069: D0 26        BNE $3091
C2/306B: B9 C2 3E     LDA $3EC2,Y
C2/306E: F0 2A        BEQ $309A
C2/3070: BD 1A 20     LDA $201A,X
C2/3073: 29 C0        AND #$C0
C2/3075: D0 23        BNE $309A
C2/3077: BD 1D 20     LDA $201D,X
C2/307A: 29 81        AND #$81
C2/307C: D0 1C        BNE $309A
C2/307E: BD 1E 20     LDA $201E,X
C2/3081: 29 10        AND #$10
C2/3083: F0 15        BEQ $309A
C2/3085: BD 57 20     LDA $2057,X
C2/3088: C9 50        CMP #$50
C2/308A: F0 0E        BEQ $309A
C2/308C: 8E 20 26     STX $2620
C2/308F: 80 09        BRA $309A
C2/3091: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/3094: C8           INY 
C2/3095: C0 04 00     CPY #$0004
C2/3098: D0 C8        BNE $3062
C2/309A: 60           RTS 

; [ monster target $29:  ]

C2/309B: A9 01        LDA #$01
C2/309D: 85 0E        STA $0E
C2/309F: 80 BE        BRA $305F

; [ monster target $2A:  ]

C2/30A1: A9 02        LDA #$02
C2/30A3: 85 0E        STA $0E
C2/30A5: 80 B8        BRA $305F

; [ monster target $2B:  ]

C2/30A7: A9 03        LDA #$03
C2/30A9: 85 0E        STA $0E
C2/30AB: 80 B2        BRA $305F

; [ monster target $2C:  ]

C2/30AD: A9 04        LDA #$04
C2/30AF: 85 0E        STA $0E
C2/30B1: 80 AC        BRA $305F

; [ monster target $2D:  ]

C2/30B3: AD 73 7C     LDA $7C73
C2/30B6: C2 20        REP #$20
C2/30B8: 20 B2 01     JSR $01B2       ; a << 7
C2/30BB: 8D 20 26     STA $2620
C2/30BE: 7B           TDC 
C2/30BF: E2 20        SEP #$20
C2/30C1: 60           RTS 

; [ monster target $2E:  ]

C2/30C2: EE 24 27     INC $2724
C2/30C5: 7B           TDC 
C2/30C6: AA           TAX 
C2/30C7: 86 0E        STX $0E
C2/30C9: 86 10        STX $10
C2/30CB: A6 0E        LDX $0E
C2/30CD: AD 87 7C     LDA $7C87
C2/30D0: 20 DB 01     JSR $01DB       ; check bit x
C2/30D3: F0 13        BEQ $30E8
C2/30D5: C2 20        REP #$20
C2/30D7: A6 10        LDX $10
C2/30D9: A5 0E        LDA $0E
C2/30DB: 20 B2 01     JSR $01B2       ; a << 7
C2/30DE: 9D 20 26     STA $2620,X
C2/30E1: E6 10        INC $10
C2/30E3: E6 10        INC $10
C2/30E5: 7B           TDC 
C2/30E6: E2 20        SEP #$20
C2/30E8: E6 0E        INC $0E
C2/30EA: A5 0E        LDA $0E
C2/30EC: C9 04        CMP #$04
C2/30EE: D0 DB        BNE $30CB
C2/30F0: 60           RTS 

; [ monster target $2F: butz ]

C2/30F1: 64 0E        STZ $0E
C2/30F3: 7B           TDC 
C2/30F4: A8           TAY 
C2/30F5: AA           TAX 
C2/30F6: BD 00 20     LDA $2000,X
C2/30F9: 29 07        AND #$07
C2/30FB: C5 0E        CMP $0E
C2/30FD: D0 0C        BNE $310B
C2/30FF: BD 1A 20     LDA $201A,X
C2/3102: 29 80        AND #$80
C2/3104: F0 0E        BEQ $3114       ; branch if not wounded
C2/3106: 8E 20 26     STX $2620
C2/3109: 80 09        BRA $3114
C2/310B: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/310E: C8           INY 
C2/310F: C0 04 00     CPY #$0004
C2/3112: D0 E2        BNE $30F6
C2/3114: 60           RTS 

; [ monster target $30: lenna ]

C2/3115: A9 01        LDA #$01
C2/3117: 85 0E        STA $0E
C2/3119: 80 D8        BRA $30F3

; [ monster target $31: galuf/krile ]

C2/311B: A9 02        LDA #$02
C2/311D: 85 0E        STA $0E
C2/311F: 80 D2        BRA $30F3

; [ monster target $32: faris ]

C2/3121: A9 03        LDA #$03
C2/3123: 85 0E        STA $0E
C2/3125: 80 CC        BRA $30F3

; [ check if target valid ]

C2/3127: BD 1A 20     LDA $201A,X     ; check if dead or stone
C2/312A: 29 C0        AND #$C0
C2/312C: D0 0C        BNE $313A
C2/312E: BD 1D 20     LDA $201D,X     ; check if erased or hidden
C2/3131: 29 81        AND #$81
C2/3133: D0 05        BNE $313A
C2/3135: BD 1E 20     LDA $201E,X     ; check if jumping
C2/3138: 29 10        AND #$10
C2/313A: 60           RTS 

; [ execute ai script ]

C2/313B: A2 40 00     LDX #$0040
C2/313E: A9 FF        LDA #$FF
C2/3140: 9D 40 26     STA $2640,X     ; clear monster script buffer
C2/3143: CA           DEX 
C2/3144: 10 FA        BPL $3140
C2/3146: AD 03 7C     LDA $7C03       ; 
C2/3149: 0A           ASL 
C2/314A: AA           TAX 
C2/314B: BD 96 46     LDA $4696,X
C2/314E: 85 0E        STA $0E
C2/3150: BD 97 46     LDA $4697,X
C2/3153: 85 0F        STA $0F
C2/3155: 7B           TDC 
C2/3156: AA           TAX 
C2/3157: A4 0E        LDY $0E
C2/3159: B1 4B        LDA ($4B),Y
C2/315B: 9D 40 26     STA $2640,X
C2/315E: C8           INY 
C2/315F: E8           INX 
C2/3160: C9 FE        CMP #$FE
C2/3162: D0 03        BNE $3167
C2/3164: 4C F8 31     JMP $31F8
C2/3167: C9 FF        CMP #$FF
C2/3169: D0 03        BNE $316E
C2/316B: 4C F8 31     JMP $31F8
C2/316E: C9 FD        CMP #$FD
C2/3170: D0 69        BNE $31DB
C2/3172: B1 4B        LDA ($4B),Y
C2/3174: 9D 40 26     STA $2640,X
C2/3177: C8           INY 
C2/3178: E8           INX 
C2/3179: C9 F7        CMP #$F7
C2/317B: F0 1E        BEQ $319B
C2/317D: C9 F0        CMP #$F0
C2/317F: B0 49        BCS $31CA
C2/3181: B1 4B        LDA ($4B),Y
C2/3183: 9D 40 26     STA $2640,X
C2/3186: C8           INY 
C2/3187: E8           INX 
C2/3188: B1 4B        LDA ($4B),Y
C2/318A: 9D 40 26     STA $2640,X
C2/318D: C8           INY 
C2/318E: E8           INX 
C2/318F: B1 4B        LDA ($4B),Y
C2/3191: C9 FE        CMP #$FE
C2/3193: F0 63        BEQ $31F8
C2/3195: C9 FF        CMP #$FF
C2/3197: F0 5F        BEQ $31F8
C2/3199: 80 4A        BRA $31E5
C2/319B: B1 4B        LDA ($4B),Y
C2/319D: 9D 40 26     STA $2640,X
C2/31A0: 85 10        STA $10
C2/31A2: C8           INY 
C2/31A3: E8           INX 
C2/31A4: B1 4B        LDA ($4B),Y
C2/31A6: 9D 40 26     STA $2640,X
C2/31A9: C8           INY 
C2/31AA: E8           INX 
C2/31AB: 64 11        STZ $11
C2/31AD: B1 4B        LDA ($4B),Y
C2/31AF: 9D 40 26     STA $2640,X
C2/31B2: C8           INY 
C2/31B3: E8           INX 
C2/31B4: E6 11        INC $11
C2/31B6: A5 11        LDA $11
C2/31B8: C5 10        CMP $10
C2/31BA: D0 F1        BNE $31AD
C2/31BC: CA           DEX 
C2/31BD: BD 40 26     LDA $2640,X
C2/31C0: C9 FE        CMP #$FE
C2/31C2: F0 34        BEQ $31F8
C2/31C4: C9 FF        CMP #$FF
C2/31C6: F0 30        BEQ $31F8
C2/31C8: 80 1B        BRA $31E5
C2/31CA: B1 4B        LDA ($4B),Y
C2/31CC: 9D 40 26     STA $2640,X
C2/31CF: C8           INY 
C2/31D0: E8           INX 
C2/31D1: B1 4B        LDA ($4B),Y
C2/31D3: 9D 40 26     STA $2640,X
C2/31D6: C8           INY 
C2/31D7: E8           INX 
C2/31D8: 4C 59 31     JMP $3159
C2/31DB: B1 4B        LDA ($4B),Y
C2/31DD: C9 FE        CMP #$FE
C2/31DF: F0 17        BEQ $31F8
C2/31E1: C9 FF        CMP #$FF
C2/31E3: F0 13        BEQ $31F8
C2/31E5: 84 0E        STY $0E
C2/31E7: AD 03 7C     LDA $7C03
C2/31EA: 0A           ASL 
C2/31EB: A8           TAY 
C2/31EC: A5 0E        LDA $0E
C2/31EE: 99 96 46     STA $4696,Y
C2/31F1: A5 0F        LDA $0F
C2/31F3: 99 97 46     STA $4697,Y
C2/31F6: 80 18        BRA $3210
C2/31F8: AD 03 7C     LDA $7C03
C2/31FB: 0A           ASL 
C2/31FC: A8           TAY 
C2/31FD: AD 90 46     LDA $4690
C2/3200: 0A           ASL 
C2/3201: AA           TAX 
C2/3202: BF B5 EE D0  LDA $D0EEB5,X
C2/3206: 99 96 46     STA $4696,Y
C2/3209: BF B6 EE D0  LDA $D0EEB6,X
C2/320D: 99 97 46     STA $4697,Y
; fall through

; [ execute ai command ]

C2/3210: 64 0E        STZ $0E
C2/3212: AE 60 43     LDX $4360
C2/3215: 9E 5E 42     STZ $425E,X
C2/3218: E8           INX 
C2/3219: E6 0E        INC $0E
C2/321B: A5 0E        LDA $0E
C2/321D: C9 20        CMP #$20
C2/321F: D0 F4        BNE $3215
C2/3221: AE 5E 43     LDX $435E
C2/3224: 86 3D        STX $3D
C2/3226: AE 60 43     LDX $4360
C2/3229: 86 3F        STX $3F
C2/322B: AD 03 7C     LDA $7C03
C2/322E: 0A           ASL 
C2/322F: AA           TAX 
C2/3230: BF 95 EE D0  LDA $D0EE95,X   ; 
C2/3234: 85 41        STA $41
C2/3236: BF 96 EE D0  LDA $D0EE96,X
C2/323A: 85 42        STA $42
C2/323C: 7B           TDC 
C2/323D: A8           TAY 
C2/323E: 84 43        STY $43
C2/3240: 84 45        STY $45
C2/3242: A6 41        LDX $41
C2/3244: A4 43        LDY $43
C2/3246: B9 40 26     LDA $2640,Y     ; monster command
C2/3249: 9D 67 43     STA $4367,X
C2/324C: C9 FE        CMP #$FE
C2/324E: F0 4B        BEQ $329B       ; return if $FE or $FF
C2/3250: C9 FF        CMP #$FF
C2/3252: F0 47        BEQ $329B
C2/3254: C9 FD        CMP #$FD
C2/3256: B0 05        BCS $325D
C2/3258: 20 9C 32     JSR $329C
C2/325B: 80 3C        BRA $3299
C2/325D: B9 41 26     LDA $2641,Y     ; next monster command ???
C2/3260: C9 F0        CMP #$F0
C2/3262: B0 05        BCS $3269
C2/3264: 20 4D 33     JSR $334D       ; single attack
C2/3267: 80 EF        BRA $3258
C2/3269: C9 F2        CMP #$F2
C2/326B: D0 05        BNE $3272
C2/326D: 20 6E 33     JSR $336E       ; monster command $F2
C2/3270: 80 27        BRA $3299
C2/3272: C9 F3        CMP #$F3
C2/3274: D0 05        BNE $327B
C2/3276: 20 EC 33     JSR $33EC       ; monster command $F3
C2/3279: 80 1E        BRA $3299
C2/327B: C9 F4        CMP #$F4
C2/327D: D0 05        BNE $3284
C2/327F: 20 6F 34     JSR $346F       ; monster command $F4
C2/3282: 80 15        BRA $3299
C2/3284: C9 F9        CMP #$F9
C2/3286: D0 05        BNE $328D
C2/3288: 20 7B 34     JSR $347B       ; monster command $F9
C2/328B: 80 0C        BRA $3299
C2/328D: C9 FA        CMP #$FA
C2/328F: D0 05        BNE $3296
C2/3291: 20 8A 34     JSR $348A       ; monster command $FA
C2/3294: 80 03        BRA $3299
C2/3296: 20 D9 34     JSR $34D9       ; monster command ???
C2/3299: 80 A7        BRA $3242
C2/329B: 60           RTS 

; [  ]

C2/329C: A6 3D        LDX $3D
C2/329E: C9 F1        CMP #$F1
C2/32A0: D0 29        BNE $32CB
C2/32A2: A6 41        LDX $41
C2/32A4: A9 FF        LDA #$FF
C2/32A6: 9D 67 43     STA $4367,X
C2/32A9: 64 16        STZ $16
C2/32AB: A5 3D        LDA $3D
C2/32AD: 4A           LSR 
C2/32AE: 66 16        ROR $16
C2/32B0: 4A           LSR 
C2/32B1: 66 16        ROR $16
C2/32B3: 4A           LSR 
C2/32B4: 66 16        ROR $16
C2/32B6: 4A           LSR 
C2/32B7: 66 16        ROR $16
C2/32B9: A5 16        LDA $16
C2/32BB: D0 0A        BNE $32C7
C2/32BD: A6 32        LDX $32
C2/32BF: 9E 57 20     STZ $2057,X
C2/32C2: A9 80        LDA #$80
C2/32C4: 9D 56 20     STA $2056,X
C2/32C7: A9 78        LDA #$78
C2/32C9: A6 3D        LDX $3D
C2/32CB: 9D DE 41     STA $41DE,X
C2/32CE: 85 16        STA $16
C2/32D0: A6 32        LDX $32
C2/32D2: A5 45        LDA $45
C2/32D4: C9 02        CMP #$02
C2/32D6: B0 14        BCS $32EC
C2/32D8: 3A           DEC 
C2/32D9: F0 07        BEQ $32E2
C2/32DB: A5 16        LDA $16
C2/32DD: 9D 5A 20     STA $205A,X
C2/32E0: 80 0A        BRA $32EC
C2/32E2: A5 16        LDA $16
C2/32E4: 9D 5F 20     STA $205F,X
C2/32E7: A9 21        LDA #$21
C2/32E9: 9D 5B 20     STA $205B,X
C2/32EC: E6 3D        INC $3D
C2/32EE: E6 45        INC $45
C2/32F0: A6 41        LDX $41
C2/32F2: 64 17        STZ $17
C2/32F4: A9 FF        LDA #$FF
C2/32F6: 9D 67 43     STA $4367,X
C2/32F9: E8           INX 
C2/32FA: C2 20        REP #$20
C2/32FC: E6 41        INC $41
C2/32FE: E2 20        SEP #$20
C2/3300: E6 17        INC $17
C2/3302: A5 17        LDA $17
C2/3304: C9 14        CMP #$14
C2/3306: D0 EC        BNE $32F4
C2/3308: C2 20        REP #$20
C2/330A: C6 41        DEC $41
C2/330C: E2 20        SEP #$20
C2/330E: A6 3F        LDX $3F
C2/3310: BD 5E 42     LDA $425E,X
C2/3313: 1D 5F 42     ORA $425F,X
C2/3316: F0 06        BEQ $331E
C2/3318: E6 3F        INC $3F
C2/331A: E6 3F        INC $3F
C2/331C: 80 26        BRA $3344
C2/331E: AD 03 7C     LDA $7C03
C2/3321: 0A           ASL 
C2/3322: AA           TAX 
C2/3323: BD 2A 7C     LDA $7C2A,X
C2/3326: 1D 2B 7C     ORA $7C2B,X
C2/3329: F0 14        BEQ $333F
C2/332B: A4 3F        LDY $3F
C2/332D: BD 2A 7C     LDA $7C2A,X
C2/3330: 99 5E 42     STA $425E,Y
C2/3333: BD 2B 7C     LDA $7C2B,X
C2/3336: 99 5F 42     STA $425F,Y
C2/3339: E6 3F        INC $3F
C2/333B: E6 3F        INC $3F
C2/333D: 80 05        BRA $3344
C2/333F: A5 16        LDA $16
C2/3341: 20 04 35     JSR $3504
C2/3344: C2 20        REP #$20
C2/3346: E6 41        INC $41
C2/3348: E6 43        INC $43
C2/334A: E2 20        SEP #$20
C2/334C: 60           RTS 

; [ monster command $FD: choose 1 of 3 attacks ]

C2/334D: 8D 20 27     STA $2720
C2/3350: B9 42 26     LDA $2642,Y
C2/3353: 8D 21 27     STA $2721
C2/3356: B9 43 26     LDA $2643,Y
C2/3359: 8D 22 27     STA $2722
C2/335C: E6 43        INC $43
C2/335E: E6 43        INC $43
C2/3360: E6 43        INC $43
C2/3362: 7B           TDC 
C2/3363: AA           TAX 
C2/3364: A9 02        LDA #$02
C2/3366: 20 7C 00     JSR $007C       ; a = (x..a)
C2/3369: AA           TAX 
C2/336A: BD 20 27     LDA $2720,X
C2/336D: 60           RTS 

; [ monster command $F2: show monster ]

C2/336E: 20 D9 34     JSR $34D9
C2/3371: AD 4E 47     LDA $474E
C2/3374: F0 0F        BEQ $3385
C2/3376: DA           PHX 
C2/3377: AD 03 7C     LDA $7C03
C2/337A: AA           TAX 
C2/337B: AD 51 47     LDA $4751
C2/337E: 20 D1 01     JSR $01D1       ; clear bit x
C2/3381: 8D 51 47     STA $4751
C2/3384: FA           PLX 
C2/3385: A5 0F        LDA $0F
C2/3387: D0 30        BNE $33B9
C2/3389: DA           PHX 
C2/338A: 7B           TDC 
C2/338B: AA           TAX 
C2/338C: A9 07        LDA #$07
C2/338E: 20 7C 00     JSR $007C       ; a = (x..a)
C2/3391: 85 10        STA $10
C2/3393: CD 03 7C     CMP $7C03
C2/3396: F0 F2        BEQ $338A
C2/3398: 0A           ASL 
C2/3399: AA           TAX 
C2/339A: BD 20 40     LDA $4020,X
C2/339D: 3D 21 40     AND $4021,X
C2/33A0: C9 FF        CMP #$FF
C2/33A2: F0 E6        BEQ $338A
C2/33A4: AD 03 7C     LDA $7C03
C2/33A7: AA           TAX 
C2/33A8: 7B           TDC 
C2/33A9: 20 D6 01     JSR $01D6       ; set bit x
C2/33AC: 48           PHA 
C2/33AD: A5 10        LDA $10
C2/33AF: AA           TAX 
C2/33B0: 68           PLA 
C2/33B1: 20 D6 01     JSR $01D6       ; set bit x
C2/33B4: FA           PLX 
C2/33B5: 9D 6A 43     STA $436A,X
C2/33B8: 60           RTS 
C2/33B9: A5 0E        LDA $0E
C2/33BB: 29 40        AND #$40
C2/33BD: F0 2C        BEQ $33EB
C2/33BF: DA           PHX 
C2/33C0: 7B           TDC 
C2/33C1: AA           TAX 
C2/33C2: A9 07        LDA #$07
C2/33C4: 20 7C 00     JSR $007C       ; a = (x..a)
C2/33C7: 85 10        STA $10
C2/33C9: 0A           ASL 
C2/33CA: AA           TAX 
C2/33CB: BD 20 40     LDA $4020,X
C2/33CE: 3D 21 40     AND $4021,X
C2/33D1: C9 FF        CMP #$FF
C2/33D3: F0 EB        BEQ $33C0
C2/33D5: A5 10        LDA $10
C2/33D7: AA           TAX 
C2/33D8: 7B           TDC 
C2/33D9: 20 D6 01     JSR $01D6       ; set bit x
C2/33DC: 25 0F        AND $0F
C2/33DE: F0 E0        BEQ $33C0
C2/33E0: A5 10        LDA $10
C2/33E2: AA           TAX 
C2/33E3: 7B           TDC 
C2/33E4: 20 D6 01     JSR $01D6       ; set bit x
C2/33E7: FA           PLX 
C2/33E8: 9D 6A 43     STA $436A,X
C2/33EB: 60           RTS 

; [ monster command $F3: set target ]

C2/33EC: 20 D9 34     JSR $34D9
C2/33EF: AD 56 7C     LDA $7C56
C2/33F2: F0 03        BEQ $33F7
C2/33F4: EE 56 7C     INC $7C56
C2/33F7: A5 0E        LDA $0E
C2/33F9: 20 27 2C     JSR $2C27       ; get monster script targets
C2/33FC: AD 20 26     LDA $2620
C2/33FF: 2D 21 26     AND $2621
C2/3402: C9 FF        CMP #$FF
C2/3404: F0 68        BEQ $346E
C2/3406: 7B           TDC 
C2/3407: AA           TAX 
C2/3408: A8           TAY 
C2/3409: 86 0E        STX $0E
C2/340B: C2 20        REP #$20
C2/340D: B9 20 26     LDA $2620,Y
C2/3410: 20 BB 01     JSR $01BB       ; a >> 7
C2/3413: AA           TAX 
C2/3414: 7B           TDC 
C2/3415: E2 20        SEP #$20
C2/3417: E0 0C 00     CPX #$000C
C2/341A: B0 1D        BCS $3439
C2/341C: 8A           TXA 
C2/341D: C9 04        CMP #$04
C2/341F: B0 09        BCS $342A
C2/3421: A5 0E        LDA $0E
C2/3423: 20 D6 01     JSR $01D6       ; set bit x
C2/3426: 85 0E        STA $0E
C2/3428: 80 0B        BRA $3435
C2/342A: 38           SEC 
C2/342B: E9 04        SBC #$04
C2/342D: AA           TAX 
C2/342E: A5 0F        LDA $0F
C2/3430: 20 D6 01     JSR $01D6       ; set bit x
C2/3433: 85 0F        STA $0F
C2/3435: C8           INY 
C2/3436: C8           INY 
C2/3437: 80 D2        BRA $340B
C2/3439: AD 24 27     LDA $2724
C2/343C: D0 24        BNE $3462
C2/343E: 7B           TDC 
C2/343F: AA           TAX 
C2/3440: A9 07        LDA #$07
C2/3442: 20 7C 00     JSR $007C       ; a = (x..a)
C2/3445: AA           TAX 
C2/3446: A5 0E        LDA $0E
C2/3448: 20 DB 01     JSR $01DB       ; check bit x
C2/344B: F0 08        BEQ $3455
C2/344D: 7B           TDC 
C2/344E: 20 D6 01     JSR $01D6       ; set bit x
C2/3451: 85 0E        STA $0E
C2/3453: 80 0D        BRA $3462
C2/3455: A5 0F        LDA $0F
C2/3457: 20 DB 01     JSR $01DB       ; check bit x
C2/345A: F0 E2        BEQ $343E
C2/345C: 7B           TDC 
C2/345D: 20 D6 01     JSR $01D6       ; set bit x
C2/3460: 85 0F        STA $0F
C2/3462: A6 3F        LDX $3F
C2/3464: A5 0E        LDA $0E
C2/3466: 9D 5E 42     STA $425E,X
C2/3469: A5 0F        LDA $0F
C2/346B: 9D 5F 42     STA $425F,X
C2/346E: 60           RTS 

; [ monster command $F4: set variable ]

C2/346F: 20 D9 34     JSR $34D9
C2/3472: A5 0E        LDA $0E
C2/3474: AA           TAX 
C2/3475: A5 0F        LDA $0F
C2/3477: 9D 63 43     STA $4363,X     ; battle variable
C2/347A: 60           RTS 

; [ monster command $F9: set victory flag ??? ]

C2/347B: 20 D9 34     JSR $34D9
C2/347E: A5 0E        LDA $0E
C2/3480: AA           TAX 
C2/3481: BD 84 7C     LDA $7C84,X
C2/3484: 05 0F        ORA $0F
C2/3486: 9D 84 7C     STA $7C84,X
C2/3489: 60           RTS 

; [ monster command $FA: toggle status ]

C2/348A: 20 D9 34     JSR $34D9
C2/348D: A5 0E        LDA $0E
C2/348F: C2 20        REP #$20
C2/3491: 18           CLC 
C2/3492: 65 32        ADC $32
C2/3494: AA           TAX 
C2/3495: 7B           TDC 
C2/3496: E2 20        SEP #$20
C2/3498: A5 0E        LDA $0E
C2/349A: C9 1A        CMP #$1A
C2/349C: 90 35        BCC $34D3
C2/349E: C9 1E        CMP #$1E
C2/34A0: 90 08        BCC $34AA
C2/34A2: C9 70        CMP #$70
C2/34A4: 90 2D        BCC $34D3
C2/34A6: C9 74        CMP #$74
C2/34A8: B0 29        BCS $34D3
C2/34AA: 7B           TDC 
C2/34AB: A8           TAY 
C2/34AC: A5 0F        LDA $0F
C2/34AE: F0 22        BEQ $34D2
C2/34B0: 0A           ASL 
C2/34B1: B0 03        BCS $34B6
C2/34B3: C8           INY 
C2/34B4: 80 FA        BRA $34B0
C2/34B6: DA           PHX 
C2/34B7: BB           TYX 
C2/34B8: BF DE EC D0  LDA $D0ECDE,X
C2/34BC: 85 0E        STA $0E
C2/34BE: FA           PLX 
C2/34BF: BD 00 20     LDA $2000,X
C2/34C2: 25 0F        AND $0F
C2/34C4: 45 0F        EOR $0F
C2/34C6: 85 10        STA $10
C2/34C8: BD 00 20     LDA $2000,X
C2/34CB: 25 0E        AND $0E
C2/34CD: 05 10        ORA $10
C2/34CF: 9D 00 20     STA $2000,X
C2/34D2: 60           RTS 
C2/34D3: A5 0F        LDA $0F
C2/34D5: 9D 00 20     STA $2000,X
C2/34D8: 60           RTS 

; [  ]

C2/34D9: 9D 68 43     STA $4368,X
C2/34DC: B9 42 26     LDA $2642,Y
C2/34DF: 9D 69 43     STA $4369,X
C2/34E2: 85 0E        STA $0E
C2/34E4: B9 43 26     LDA $2643,Y
C2/34E7: 9D 6A 43     STA $436A,X
C2/34EA: 85 0F        STA $0F
C2/34EC: 9D 6B 43     STA $436B,X
C2/34EF: C2 20        REP #$20
C2/34F1: 18           CLC 
C2/34F2: A5 41        LDA $41
C2/34F4: 69 05 00     ADC #$0005
C2/34F7: 85 41        STA $41
C2/34F9: 7B           TDC 
C2/34FA: E2 20        SEP #$20
C2/34FC: 18           CLC 
C2/34FD: A5 43        LDA $43
C2/34FF: 69 04        ADC #$04
C2/3501: 85 43        STA $43
C2/3503: 60           RTS 

; [  ]

C2/3504: 48           PHA 
C2/3505: 68           PLA 
C2/3506: D0 05        BNE $350D
C2/3508: 64 17        STZ $17
C2/350A: 4C A9 35     JMP $35A9
C2/350D: C9 EC        CMP #$EC
C2/350F: D0 1D        BNE $352E
C2/3511: A9 F0        LDA #$F0
C2/3513: 85 16        STA $16
C2/3515: 64 17        STZ $17
C2/3517: 7B           TDC 
C2/3518: AA           TAX 
C2/3519: BD C2 3E     LDA $3EC2,X
C2/351C: F0 07        BEQ $3525
C2/351E: A5 16        LDA $16
C2/3520: 20 D1 01     JSR $01D1       ; clear bit x
C2/3523: 85 16        STA $16
C2/3525: E8           INX 
C2/3526: E0 04 00     CPX #$0004
C2/3529: D0 EE        BNE $3519
C2/352B: 4C D2 35     JMP $35D2
C2/352E: C2 20        REP #$20
C2/3530: 20 B6 01     JSR $01B6       ; a << 3
C2/3533: AA           TAX 
C2/3534: 7B           TDC 
C2/3535: E2 20        SEP #$20
C2/3537: BF 80 0B D1  LDA $D10B80,X
C2/353B: 8D A0 26     STA $26A0
C2/353E: 7B           TDC 
C2/353F: A8           TAY 
C2/3540: 84 16        STY $16
C2/3542: AD A0 26     LDA $26A0
C2/3545: D0 0C        BNE $3553
C2/3547: AD 03 7C     LDA $7C03
C2/354A: AA           TAX 
C2/354B: 7B           TDC 
C2/354C: 20 D6 01     JSR $01D6       ; set bit x
C2/354F: 85 17        STA $17
C2/3551: 80 7F        BRA $35D2
C2/3553: 29 04        AND #$04
C2/3555: F0 2C        BEQ $3583
C2/3557: 7B           TDC 
C2/3558: AA           TAX 
C2/3559: A9 0B        LDA #$0B
C2/355B: 20 7C 00     JSR $007C       ; a = (x..a)
C2/355E: 85 16        STA $16
C2/3560: A8           TAY 
C2/3561: B9 C2 3E     LDA $3EC2,Y
C2/3564: F0 F1        BEQ $3557
C2/3566: A5 16        LDA $16
C2/3568: C9 04        CMP #$04
C2/356A: B0 09        BCS $3575
C2/356C: AA           TAX 
C2/356D: 7B           TDC 
C2/356E: 20 D6 01     JSR $01D6       ; set bit x
C2/3571: 85 16        STA $16
C2/3573: 80 5D        BRA $35D2
C2/3575: 64 16        STZ $16
C2/3577: 38           SEC 
C2/3578: E9 04        SBC #$04
C2/357A: AA           TAX 
C2/357B: 7B           TDC 
C2/357C: 20 D6 01     JSR $01D6       ; set bit x
C2/357F: 85 17        STA $17
C2/3581: 80 4F        BRA $35D2
C2/3583: AD A0 26     LDA $26A0
C2/3586: 29 40        AND #$40
C2/3588: D0 2F        BNE $35B9
C2/358A: AD A0 26     LDA $26A0
C2/358D: 29 08        AND #$08
C2/358F: D0 14        BNE $35A5
C2/3591: A5 22        LDA $22
C2/3593: D0 14        BNE $35A9
C2/3595: 7B           TDC 
C2/3596: AA           TAX 
C2/3597: A9 07        LDA #$07
C2/3599: 20 7C 00     JSR $007C       ; a = (x..a)
C2/359C: AA           TAX 
C2/359D: 7B           TDC 
C2/359E: 20 D6 01     JSR $01D6       ; set bit x
C2/35A1: 85 17        STA $17
C2/35A3: 80 2D        BRA $35D2
C2/35A5: A5 22        LDA $22
C2/35A7: D0 EC        BNE $3595
C2/35A9: 7B           TDC 
C2/35AA: AA           TAX 
C2/35AB: A9 03        LDA #$03
C2/35AD: 20 7C 00     JSR $007C       ; a = (x..a)
C2/35B0: AA           TAX 
C2/35B1: 7B           TDC 
C2/35B2: 20 D6 01     JSR $01D6       ; set bit x
C2/35B5: 85 16        STA $16
C2/35B7: 80 19        BRA $35D2
C2/35B9: AD A0 26     LDA $26A0
C2/35BC: 29 08        AND #$08
C2/35BE: D0 0A        BNE $35CA
C2/35C0: A5 22        LDA $22
C2/35C2: D0 0A        BNE $35CE
C2/35C4: A9 FF        LDA #$FF
C2/35C6: 85 17        STA $17
C2/35C8: 80 08        BRA $35D2
C2/35CA: A5 22        LDA $22
C2/35CC: D0 F6        BNE $35C4
C2/35CE: A9 F0        LDA #$F0
C2/35D0: 85 16        STA $16
C2/35D2: A6 3F        LDX $3F
C2/35D4: A5 16        LDA $16
C2/35D6: 9D 5E 42     STA $425E,X
C2/35D9: A5 17        LDA $17
C2/35DB: 9D 5F 42     STA $425F,X
C2/35DE: E6 3F        INC $3F
C2/35E0: E6 3F        INC $3F
C2/35E2: 60           RTS 

; [  ]

C2/35E3: A9 01        LDA #$01
C2/35E5: 8D 56 7C     STA $7C56
C2/35E8: AD 4E 47     LDA $474E
C2/35EB: D0 79        BNE $3666
C2/35ED: AD 54 47     LDA $4754
C2/35F0: D0 03        BNE $35F5
C2/35F2: 4C 0C 3C     JMP $3C0C
C2/35F5: A5 47        LDA $47
C2/35F7: 8D 73 7C     STA $7C73
C2/35FA: A9 FF        LDA #$FF
C2/35FC: 8D 55 47     STA $4755
C2/35FF: 9C 53 47     STZ $4753
C2/3602: 9C 4F 47     STZ $474F
C2/3605: 9C 50 47     STZ $4750
C2/3608: 9C 51 47     STZ $4751
C2/360B: 9C 52 47     STZ $4752
C2/360E: AD CC 3B     LDA $3BCC
C2/3611: 29 40        AND #$40
C2/3613: D0 03        BNE $3618
C2/3615: EE 50 47     INC $4750
C2/3618: AD CF 3B     LDA $3BCF
C2/361B: 8D 4F 47     STA $474F
C2/361E: D0 10        BNE $3630
C2/3620: AD D1 3B     LDA $3BD1
C2/3623: F0 0B        BEQ $3630
C2/3625: 8D 4F 47     STA $474F
C2/3628: AD 50 47     LDA $4750
C2/362B: 49 01        EOR #$01
C2/362D: 8D 50 47     STA $4750
C2/3630: A9 80        LDA #$80
C2/3632: 8D 53 47     STA $4753
C2/3635: AD 2E 7B     LDA $7B2E
C2/3638: C9 FF        CMP #$FF
C2/363A: F0 2A        BEQ $3666
C2/363C: AD D3 3B     LDA $3BD3
C2/363F: 29 40        AND #$40
C2/3641: D0 03        BNE $3646
C2/3643: EE 52 47     INC $4752
C2/3646: AD D6 3B     LDA $3BD6
C2/3649: 8D 51 47     STA $4751
C2/364C: D0 10        BNE $365E
C2/364E: AD D8 3B     LDA $3BD8
C2/3651: F0 0B        BEQ $365E
C2/3653: 8D 51 47     STA $4751
C2/3656: AD 52 47     LDA $4752
C2/3659: 49 01        EOR #$01
C2/365B: 8D 52 47     STA $4752
C2/365E: AD 53 47     LDA $4753
C2/3661: 09 40        ORA #$40
C2/3663: 8D 53 47     STA $4753
C2/3666: AD 56 47     LDA $4756
C2/3669: F0 03        BEQ $366E
C2/366B: 4C 0C 3C     JMP $3C0C
C2/366E: AD 55 47     LDA $4755
C2/3671: 30 03        BMI $3676
C2/3673: 20 08 3D     JSR $3D08
C2/3676: AD 53 47     LDA $4753
C2/3679: 29 01        AND #$01
C2/367B: F0 03        BEQ $3680
C2/367D: 4C 51 39     JMP $3951
C2/3680: 7B           TDC 
C2/3681: AA           TAX 
C2/3682: AD 4F 47     LDA $474F
C2/3685: 20 DB 01     JSR $01DB       ; check bit x
C2/3688: D0 0C        BNE $3696
C2/368A: E8           INX 
C2/368B: E0 08 00     CPX #$0008
C2/368E: D0 F2        BNE $3682
C2/3690: EE 53 47     INC $4753
C2/3693: 4C 51 39     JMP $3951
C2/3696: AD 4F 47     LDA $474F
C2/3699: 20 D1 01     JSR $01D1       ; clear bit x
C2/369C: 8D 4F 47     STA $474F
C2/369F: 8A           TXA 
C2/36A0: 8D 55 47     STA $4755
C2/36A3: AD 50 47     LDA $4750
C2/36A6: D0 08        BNE $36B0
C2/36A8: 18           CLC 
C2/36A9: AD 55 47     LDA $4755
C2/36AC: 69 04        ADC #$04
C2/36AE: 80 03        BRA $36B3
C2/36B0: AD 55 47     LDA $4755
C2/36B3: AA           TAX 
C2/36B4: BD C2 3E     LDA $3EC2,X
C2/36B7: F0 C7        BEQ $3680
C2/36B9: 8A           TXA 
C2/36BA: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/36BD: BD 1A 20     LDA $201A,X
C2/36C0: 29 40        AND #$40
C2/36C2: D0 BC        BNE $3680
C2/36C4: BD 1C 20     LDA $201C,X
C2/36C7: 29 10        AND #$10
C2/36C9: D0 B5        BNE $3680
C2/36CB: BD 1D 20     LDA $201D,X
C2/36CE: 29 81        AND #$81
C2/36D0: D0 AE        BNE $3680
C2/36D2: AD 50 47     LDA $4750
C2/36D5: F0 03        BEQ $36DA
C2/36D7: 4C B9 37     JMP $37B9
C2/36DA: BD 47 20     LDA $2047,X
C2/36DD: C9 80        CMP #$80
C2/36DF: F0 23        BEQ $3704
C2/36E1: C9 81        CMP #$81
C2/36E3: F0 1F        BEQ $3704
C2/36E5: BD 46 20     LDA $2046,X
C2/36E8: C9 04        CMP #$04
C2/36EA: F0 18        BEQ $3704
C2/36EC: C9 0B        CMP #$0B
C2/36EE: F0 14        BEQ $3704
C2/36F0: C9 15        CMP #$15
C2/36F2: F0 10        BEQ $3704
C2/36F4: C9 16        CMP #$16
C2/36F6: F0 0C        BEQ $3704
C2/36F8: C9 2C        CMP #$2C
C2/36FA: F0 08        BEQ $3704
C2/36FC: C9 2D        CMP #$2D
C2/36FE: F0 04        BEQ $3704
C2/3700: C9 33        CMP #$33
C2/3702: D0 7E        BNE $3782
C2/3704: BD 1D 20     LDA $201D,X
C2/3707: 29 DF        AND #$DF
C2/3709: 9D 1D 20     STA $201D,X
C2/370C: 18           CLC 
C2/370D: AD 55 47     LDA $4755
C2/3710: 69 04        ADC #$04
C2/3712: 85 0E        STA $0E
C2/3714: 7B           TDC 
C2/3715: A8           TAY 
C2/3716: B9 3A 7C     LDA $7C3A,Y
C2/3719: C5 0E        CMP $0E
C2/371B: F0 08        BEQ $3725
C2/371D: C8           INY 
C2/371E: C0 04 00     CPY #$0004
C2/3721: D0 F3        BNE $3716
C2/3723: 80 19        BRA $373E
C2/3725: 7B           TDC 
C2/3726: 99 3A 7C     STA $7C3A,Y
C2/3729: BD 1B 20     LDA $201B,X
C2/372C: 1D 71 20     ORA $2071,X
C2/372F: 85 10        STA $10
C2/3731: AD 55 47     LDA $4755
C2/3734: 0A           ASL 
C2/3735: AA           TAX 
C2/3736: 9E 2A 7C     STZ $7C2A,X
C2/3739: 9E 2B 7C     STZ $7C2B,X
C2/373C: 80 16        BRA $3754
C2/373E: BD 1B 20     LDA $201B,X
C2/3741: 1D 71 20     ORA $2071,X
C2/3744: 85 10        STA $10
C2/3746: AD 55 47     LDA $4755
C2/3749: 20 B7 01     JSR $01B7       ; a << 2
C2/374C: A8           TAY 
C2/374D: B9 9F 7B     LDA $7B9F,Y
C2/3750: 29 40        AND #$40
C2/3752: F0 0F        BEQ $3763
C2/3754: DA           PHX 
C2/3755: A5 0E        LDA $0E
C2/3757: 20 82 24     JSR $2482
C2/375A: FA           PLX 
C2/375B: BD 1B 20     LDA $201B,X
C2/375E: 29 BF        AND #$BF
C2/3760: 9D 1B 20     STA $201B,X
C2/3763: AD 55 47     LDA $4755
C2/3766: 20 B7 01     JSR $01B7       ; a << 2
C2/3769: A8           TAY 
C2/376A: B9 9F 7B     LDA $7B9F,Y
C2/376D: 29 10        AND #$10
C2/376F: F0 08        BEQ $3779
C2/3771: BD 1B 20     LDA $201B,X
C2/3774: 29 EF        AND #$EF
C2/3776: 9D 1B 20     STA $201B,X
C2/3779: A5 10        LDA $10
C2/377B: 29 78        AND #$78
C2/377D: F0 03        BEQ $3782
C2/377F: 4C 80 36     JMP $3680
C2/3782: A6 32        LDX $32
C2/3784: BD 1B 20     LDA $201B,X
C2/3787: 29 78        AND #$78
C2/3789: D0 F4        BNE $377F
C2/378B: BD 1D 20     LDA $201D,X
C2/378E: 29 20        AND #$20
C2/3790: D0 ED        BNE $377F
C2/3792: BD 46 20     LDA $2046,X
C2/3795: C9 1C        CMP #$1C
C2/3797: F0 E6        BEQ $377F
C2/3799: 20 10 3C     JSR $3C10
C2/379C: AD 94 46     LDA $4694
C2/379F: D0 03        BNE $37A4
C2/37A1: 4C 80 36     JMP $3680
C2/37A4: 18           CLC 
C2/37A5: AD 55 47     LDA $4755
C2/37A8: 69 04        ADC #$04
C2/37AA: 8D 55 47     STA $4755
C2/37AD: 20 7F 3C     JSR $3C7F
C2/37B0: 20 C7 3D     JSR $3DC7
C2/37B3: 20 9C 3D     JSR $3D9C
C2/37B6: 4C 0C 3C     JMP $3C0C
C2/37B9: A6 32        LDX $32
C2/37BB: BD 1B 20     LDA $201B,X
C2/37BE: 29 04        AND #$04
C2/37C0: D0 07        BNE $37C9
C2/37C2: AD E6 7B     LDA $7BE6
C2/37C5: 29 40        AND #$40
C2/37C7: F0 18        BEQ $37E1
C2/37C9: BD 1D 20     LDA $201D,X
C2/37CC: 29 04        AND #$04
C2/37CE: F0 11        BEQ $37E1
C2/37D0: BD 1D 20     LDA $201D,X
C2/37D3: 29 FB        AND #$FB
C2/37D5: 9D 1D 20     STA $201D,X
C2/37D8: A5 55        LDA $55
C2/37DA: 20 07 02     JSR $0207       ; get timer data offset
C2/37DD: 7B           TDC 
C2/37DE: 99 F9 3C     STA $3CF9,Y
C2/37E1: A6 32        LDX $32
C2/37E3: BD 06 20     LDA $2006,X
C2/37E6: 1D 07 20     ORA $2007,X
C2/37E9: F0 11        BEQ $37FC
C2/37EB: BD 1A 20     LDA $201A,X
C2/37EE: 29 80        AND #$80
C2/37F0: D0 0A        BNE $37FC
C2/37F2: BD 1B 20     LDA $201B,X
C2/37F5: 1D 71 20     ORA $2071,X
C2/37F8: 29 20        AND #$20
C2/37FA: F0 03        BEQ $37FF
C2/37FC: 4C 4B 39     JMP $394B
C2/37FF: BD 47 20     LDA $2047,X
C2/3802: C9 80        CMP #$80
C2/3804: F0 23        BEQ $3829
C2/3806: C9 81        CMP #$81
C2/3808: F0 1F        BEQ $3829
C2/380A: BD 46 20     LDA $2046,X
C2/380D: C9 04        CMP #$04
C2/380F: F0 18        BEQ $3829
C2/3811: C9 0B        CMP #$0B
C2/3813: F0 14        BEQ $3829
C2/3815: C9 15        CMP #$15
C2/3817: F0 10        BEQ $3829
C2/3819: C9 16        CMP #$16
C2/381B: F0 0C        BEQ $3829
C2/381D: C9 2C        CMP #$2C
C2/381F: F0 08        BEQ $3829
C2/3821: C9 2D        CMP #$2D
C2/3823: F0 04        BEQ $3829
C2/3825: C9 33        CMP #$33
C2/3827: D0 5C        BNE $3885
C2/3829: BD 1B 20     LDA $201B,X
C2/382C: 1D 71 20     ORA $2071,X
C2/382F: 85 0E        STA $0E
C2/3831: BD 1D 20     LDA $201D,X
C2/3834: 85 0F        STA $0F
C2/3836: AD 55 47     LDA $4755
C2/3839: 20 B7 01     JSR $01B7       ; a << 2
C2/383C: A8           TAY 
C2/383D: B9 7F 7B     LDA $7B7F,Y
C2/3840: 29 40        AND #$40
C2/3842: F0 08        BEQ $384C
C2/3844: BD 1B 20     LDA $201B,X
C2/3847: 29 BF        AND #$BF
C2/3849: 9D 1B 20     STA $201B,X
C2/384C: B9 7F 7B     LDA $7B7F,Y
C2/384F: 29 10        AND #$10
C2/3851: F0 08        BEQ $385B
C2/3853: BD 1B 20     LDA $201B,X
C2/3856: 29 EF        AND #$EF
C2/3858: 9D 1B 20     STA $201B,X
C2/385B: BD 1D 20     LDA $201D,X
C2/385E: 29 FB        AND #$FB
C2/3860: 9D 1D 20     STA $201D,X
C2/3863: B9 7F 7B     LDA $7B7F,Y
C2/3866: 25 0E        AND $0E
C2/3868: 29 50        AND #$50
C2/386A: D0 10        BNE $387C
C2/386C: A5 0F        LDA $0F
C2/386E: 29 04        AND #$04
C2/3870: F0 27        BEQ $3899
C2/3872: AD 55 47     LDA $4755
C2/3875: 20 07 02     JSR $0207       ; get timer data offset
C2/3878: 7B           TDC 
C2/3879: 99 F9 3C     STA $3CF9,Y
C2/387C: AD 55 47     LDA $4755
C2/387F: 20 82 24     JSR $2482
C2/3882: 4C 4B 39     JMP $394B
C2/3885: BD 1B 20     LDA $201B,X
C2/3888: 1D 71 20     ORA $2071,X
C2/388B: 29 78        AND #$78
C2/388D: D0 07        BNE $3896
C2/388F: BD 1D 20     LDA $201D,X
C2/3892: 29 04        AND #$04
C2/3894: F0 03        BEQ $3899
C2/3896: 4C 4B 39     JMP $394B
C2/3899: BD 20 20     LDA $2020,X
C2/389C: 29 20        AND #$20
C2/389E: F0 50        BEQ $38F0
C2/38A0: BD 1C 20     LDA $201C,X
C2/38A3: 1D 72 20     ORA $2072,X
C2/38A6: 30 48        BMI $38F0
C2/38A8: A5 47        LDA $47
C2/38AA: C9 04        CMP #$04
C2/38AC: 90 42        BCC $38F0
C2/38AE: C2 20        REP #$20
C2/38B0: BD 08 20     LDA $2008,X
C2/38B3: 20 BE 01     JSR $01BE       ; a >> 4
C2/38B6: DD 06 20     CMP $2006,X
C2/38B9: 90 32        BCC $38ED
C2/38BB: 7B           TDC 
C2/38BC: E2 20        SEP #$20
C2/38BE: 20 7F 3C     JSR $3C7F
C2/38C1: A4 32        LDY $32
C2/38C3: A9 20        LDA #$20
C2/38C5: 99 56 20     STA $2056,Y
C2/38C8: A9 2C        LDA #$2C
C2/38CA: 99 57 20     STA $2057,Y
C2/38CD: A9 7C        LDA #$7C
C2/38CF: 99 5A 20     STA $205A,Y
C2/38D2: AD 55 47     LDA $4755
C2/38D5: AA           TAX 
C2/38D6: 7B           TDC 
C2/38D7: 20 D6 01     JSR $01D6       ; set bit x
C2/38DA: 99 59 20     STA $2059,Y
C2/38DD: 7B           TDC 
C2/38DE: 99 58 20     STA $2058,Y
C2/38E1: 20 91 3E     JSR $3E91
C2/38E4: 20 9C 3D     JSR $3D9C
C2/38E7: EE 4E 47     INC $474E
C2/38EA: 4C 4E 39     JMP $394E
C2/38ED: 7B           TDC 
C2/38EE: E2 20        SEP #$20
C2/38F0: BD 20 20     LDA $2020,X
C2/38F3: 29 80        AND #$80
C2/38F5: 10 54        BPL $394B
C2/38F7: BD 47 20     LDA $2047,X
C2/38FA: C9 80        CMP #$80
C2/38FC: F0 17        BEQ $3915
C2/38FE: C9 81        CMP #$81
C2/3900: D0 49        BNE $394B
C2/3902: AD 73 7C     LDA $7C73
C2/3905: C2 20        REP #$20
C2/3907: 20 B2 01     JSR $01B2       ; a << 7
C2/390A: A8           TAY 
C2/390B: 7B           TDC 
C2/390C: E2 20        SEP #$20
C2/390E: B9 6E 20     LDA $206E,Y
C2/3911: 29 83        AND #$83
C2/3913: F0 36        BEQ $394B
C2/3915: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/3918: C9 32        CMP #$32
C2/391A: B0 2F        BCS $394B
C2/391C: 20 7F 3C     JSR $3C7F
C2/391F: A4 32        LDY $32
C2/3921: A9 80        LDA #$80
C2/3923: 99 56 20     STA $2056,Y
C2/3926: A9 05        LDA #$05
C2/3928: 99 57 20     STA $2057,Y
C2/392B: 38           SEC 
C2/392C: A5 47        LDA $47
C2/392E: E9 04        SBC #$04
C2/3930: AA           TAX 
C2/3931: 7B           TDC 
C2/3932: 20 D6 01     JSR $01D6       ; set bit x
C2/3935: 99 58 20     STA $2058,Y
C2/3938: 7B           TDC 
C2/3939: 99 59 20     STA $2059,Y
C2/393C: 99 5A 20     STA $205A,Y
C2/393F: 20 91 3E     JSR $3E91
C2/3942: 20 9C 3D     JSR $3D9C
C2/3945: EE 4E 47     INC $474E
C2/3948: 4C 4E 39     JMP $394E
C2/394B: 4C 80 36     JMP $3680
C2/394E: 4C 0C 3C     JMP $3C0C
C2/3951: 7B           TDC 
C2/3952: AA           TAX 
C2/3953: AD 51 47     LDA $4751
C2/3956: 20 DB 01     JSR $01DB       ; check bit x
C2/3959: D0 14        BNE $396F
C2/395B: E8           INX 
C2/395C: E0 08 00     CPX #$0008
C2/395F: D0 F2        BNE $3953
C2/3961: AD 4E 47     LDA $474E
C2/3964: F0 06        BEQ $396C
C2/3966: 20 BB 3D     JSR $3DBB
C2/3969: 9C 4E 47     STZ $474E
C2/396C: 4C 0C 3C     JMP $3C0C
C2/396F: AD 51 47     LDA $4751
C2/3972: 20 D1 01     JSR $01D1       ; clear bit x
C2/3975: 8D 51 47     STA $4751
C2/3978: 8A           TXA 
C2/3979: 8D 55 47     STA $4755
C2/397C: AD 52 47     LDA $4752
C2/397F: D0 08        BNE $3989
C2/3981: 18           CLC 
C2/3982: AD 55 47     LDA $4755
C2/3985: 69 04        ADC #$04
C2/3987: 80 03        BRA $398C
C2/3989: AD 55 47     LDA $4755
C2/398C: AA           TAX 
C2/398D: BD C2 3E     LDA $3EC2,X
C2/3990: F0 BF        BEQ $3951
C2/3992: 8A           TXA 
C2/3993: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/3996: BD 1A 20     LDA $201A,X
C2/3999: 29 40        AND #$40
C2/399B: D0 B4        BNE $3951
C2/399D: BD 1C 20     LDA $201C,X
C2/39A0: 29 10        AND #$10
C2/39A2: D0 AD        BNE $3951
C2/39A4: BD 1D 20     LDA $201D,X
C2/39A7: 29 81        AND #$81
C2/39A9: D0 A6        BNE $3951
C2/39AB: AD 52 47     LDA $4752
C2/39AE: F0 03        BEQ $39B3
C2/39B0: 4C 92 3A     JMP $3A92
C2/39B3: BD 4E 20     LDA $204E,X
C2/39B6: C9 80        CMP #$80
C2/39B8: F0 23        BEQ $39DD
C2/39BA: C9 81        CMP #$81
C2/39BC: F0 1F        BEQ $39DD
C2/39BE: BD 4D 20     LDA $204D,X
C2/39C1: C9 04        CMP #$04
C2/39C3: F0 18        BEQ $39DD
C2/39C5: C9 0B        CMP #$0B
C2/39C7: F0 14        BEQ $39DD
C2/39C9: C9 15        CMP #$15
C2/39CB: F0 10        BEQ $39DD
C2/39CD: C9 16        CMP #$16
C2/39CF: F0 0C        BEQ $39DD
C2/39D1: C9 2C        CMP #$2C
C2/39D3: F0 08        BEQ $39DD
C2/39D5: C9 2D        CMP #$2D
C2/39D7: F0 04        BEQ $39DD
C2/39D9: C9 33        CMP #$33
C2/39DB: D0 7E        BNE $3A5B
C2/39DD: BD 1D 20     LDA $201D,X
C2/39E0: 29 DF        AND #$DF
C2/39E2: 9D 1D 20     STA $201D,X
C2/39E5: 18           CLC 
C2/39E6: AD 55 47     LDA $4755
C2/39E9: 69 04        ADC #$04
C2/39EB: 85 0E        STA $0E
C2/39ED: 7B           TDC 
C2/39EE: A8           TAY 
C2/39EF: B9 3A 7C     LDA $7C3A,Y
C2/39F2: C5 0E        CMP $0E
C2/39F4: F0 08        BEQ $39FE
C2/39F6: C8           INY 
C2/39F7: C0 04 00     CPY #$0004
C2/39FA: D0 F3        BNE $39EF
C2/39FC: 80 19        BRA $3A17
C2/39FE: 7B           TDC 
C2/39FF: 99 3A 7C     STA $7C3A,Y
C2/3A02: BD 1B 20     LDA $201B,X
C2/3A05: 1D 71 20     ORA $2071,X
C2/3A08: 85 10        STA $10
C2/3A0A: AD 55 47     LDA $4755
C2/3A0D: 0A           ASL 
C2/3A0E: AA           TAX 
C2/3A0F: 9E 2A 7C     STZ $7C2A,X
C2/3A12: 9E 2B 7C     STZ $7C2B,X
C2/3A15: 80 16        BRA $3A2D
C2/3A17: BD 1B 20     LDA $201B,X
C2/3A1A: 1D 71 20     ORA $2071,X
C2/3A1D: 85 10        STA $10
C2/3A1F: AD 55 47     LDA $4755
C2/3A22: 20 B7 01     JSR $01B7       ; a << 2
C2/3A25: A8           TAY 
C2/3A26: B9 9F 7B     LDA $7B9F,Y
C2/3A29: 29 40        AND #$40
C2/3A2B: F0 0F        BEQ $3A3C
C2/3A2D: DA           PHX 
C2/3A2E: A5 0E        LDA $0E
C2/3A30: 20 82 24     JSR $2482
C2/3A33: FA           PLX 
C2/3A34: BD 1B 20     LDA $201B,X
C2/3A37: 29 BF        AND #$BF
C2/3A39: 9D 1B 20     STA $201B,X
C2/3A3C: AD 55 47     LDA $4755
C2/3A3F: 20 B7 01     JSR $01B7       ; a << 2
C2/3A42: A8           TAY 
C2/3A43: B9 9F 7B     LDA $7B9F,Y
C2/3A46: 29 10        AND #$10
C2/3A48: F0 08        BEQ $3A52
C2/3A4A: BD 1B 20     LDA $201B,X
C2/3A4D: 29 EF        AND #$EF
C2/3A4F: 9D 1B 20     STA $201B,X
C2/3A52: A5 10        LDA $10
C2/3A54: 29 78        AND #$78
C2/3A56: F0 03        BEQ $3A5B
C2/3A58: 4C 51 39     JMP $3951
C2/3A5B: A6 32        LDX $32
C2/3A5D: BD 1B 20     LDA $201B,X
C2/3A60: 29 78        AND #$78
C2/3A62: D0 F4        BNE $3A58
C2/3A64: BD 1D 20     LDA $201D,X
C2/3A67: 29 20        AND #$20
C2/3A69: D0 ED        BNE $3A58
C2/3A6B: BD 4D 20     LDA $204D,X
C2/3A6E: C9 1C        CMP #$1C
C2/3A70: F0 E6        BEQ $3A58
C2/3A72: 20 10 3C     JSR $3C10
C2/3A75: AD 94 46     LDA $4694
C2/3A78: D0 03        BNE $3A7D
C2/3A7A: 4C 51 39     JMP $3951
C2/3A7D: 18           CLC 
C2/3A7E: AD 55 47     LDA $4755
C2/3A81: 69 04        ADC #$04
C2/3A83: 8D 55 47     STA $4755
C2/3A86: 20 7F 3C     JSR $3C7F
C2/3A89: 20 C7 3D     JSR $3DC7
C2/3A8C: 20 9C 3D     JSR $3D9C
C2/3A8F: 4C 0C 3C     JMP $3C0C
C2/3A92: AD 4E 47     LDA $474E
C2/3A95: F0 06        BEQ $3A9D
C2/3A97: 20 BB 3D     JSR $3DBB
C2/3A9A: 9C 4E 47     STZ $474E
C2/3A9D: A6 32        LDX $32
C2/3A9F: BD 06 20     LDA $2006,X
C2/3AA2: 1D 07 20     ORA $2007,X
C2/3AA5: F0 11        BEQ $3AB8
C2/3AA7: BD 1A 20     LDA $201A,X
C2/3AAA: 29 80        AND #$80
C2/3AAC: D0 0A        BNE $3AB8
C2/3AAE: BD 1B 20     LDA $201B,X
C2/3AB1: 1D 71 20     ORA $2071,X
C2/3AB4: 29 20        AND #$20
C2/3AB6: F0 03        BEQ $3ABB
C2/3AB8: 4C 09 3C     JMP $3C09
C2/3ABB: BD 4E 20     LDA $204E,X
C2/3ABE: C9 80        CMP #$80
C2/3AC0: F0 23        BEQ $3AE5
C2/3AC2: C9 81        CMP #$81
C2/3AC4: F0 1F        BEQ $3AE5
C2/3AC6: BD 4D 20     LDA $204D,X
C2/3AC9: C9 04        CMP #$04
C2/3ACB: F0 18        BEQ $3AE5
C2/3ACD: C9 0B        CMP #$0B
C2/3ACF: F0 14        BEQ $3AE5
C2/3AD1: C9 15        CMP #$15
C2/3AD3: F0 10        BEQ $3AE5
C2/3AD5: C9 16        CMP #$16
C2/3AD7: F0 0C        BEQ $3AE5
C2/3AD9: C9 2C        CMP #$2C
C2/3ADB: F0 08        BEQ $3AE5
C2/3ADD: C9 2D        CMP #$2D
C2/3ADF: F0 04        BEQ $3AE5
C2/3AE1: C9 33        CMP #$33
C2/3AE3: D0 5C        BNE $3B41
C2/3AE5: BD 1B 20     LDA $201B,X
C2/3AE8: 1D 71 20     ORA $2071,X
C2/3AEB: 85 0E        STA $0E
C2/3AED: BD 1D 20     LDA $201D,X
C2/3AF0: 85 0F        STA $0F
C2/3AF2: AD 55 47     LDA $4755
C2/3AF5: 20 B7 01     JSR $01B7       ; a << 2
C2/3AF8: A8           TAY 
C2/3AF9: B9 7F 7B     LDA $7B7F,Y
C2/3AFC: 29 40        AND #$40
C2/3AFE: F0 08        BEQ $3B08
C2/3B00: BD 1B 20     LDA $201B,X
C2/3B03: 29 BF        AND #$BF
C2/3B05: 9D 1B 20     STA $201B,X
C2/3B08: B9 7F 7B     LDA $7B7F,Y
C2/3B0B: 29 10        AND #$10
C2/3B0D: F0 08        BEQ $3B17
C2/3B0F: BD 1B 20     LDA $201B,X
C2/3B12: 29 EF        AND #$EF
C2/3B14: 9D 1B 20     STA $201B,X
C2/3B17: BD 1D 20     LDA $201D,X
C2/3B1A: 29 FB        AND #$FB
C2/3B1C: 9D 1D 20     STA $201D,X
C2/3B1F: B9 7F 7B     LDA $7B7F,Y
C2/3B22: 25 0E        AND $0E
C2/3B24: 29 50        AND #$50
C2/3B26: D0 10        BNE $3B38
C2/3B28: A5 0F        LDA $0F
C2/3B2A: 29 04        AND #$04
C2/3B2C: F0 27        BEQ $3B55
C2/3B2E: AD 55 47     LDA $4755
C2/3B31: 20 07 02     JSR $0207       ; get timer data offset
C2/3B34: 7B           TDC 
C2/3B35: 99 F9 3C     STA $3CF9,Y
C2/3B38: AD 55 47     LDA $4755
C2/3B3B: 20 82 24     JSR $2482
C2/3B3E: 4C 4B 39     JMP $394B
C2/3B41: BD 1B 20     LDA $201B,X
C2/3B44: 1D 71 20     ORA $2071,X
C2/3B47: 29 78        AND #$78
C2/3B49: D0 07        BNE $3B52
C2/3B4B: BD 1D 20     LDA $201D,X
C2/3B4E: 29 04        AND #$04
C2/3B50: F0 03        BEQ $3B55
C2/3B52: 4C 4B 39     JMP $394B
C2/3B55: BD 20 20     LDA $2020,X
C2/3B58: 29 20        AND #$20
C2/3B5A: F0 51        BEQ $3BAD
C2/3B5C: BD 1C 20     LDA $201C,X
C2/3B5F: 1D 72 20     ORA $2072,X
C2/3B62: 30 49        BMI $3BAD
C2/3B64: AD 73 7C     LDA $7C73
C2/3B67: C9 04        CMP #$04
C2/3B69: 90 42        BCC $3BAD
C2/3B6B: C2 20        REP #$20
C2/3B6D: BD 08 20     LDA $2008,X
C2/3B70: 20 BE 01     JSR $01BE       ; a >> 4
C2/3B73: DD 06 20     CMP $2006,X
C2/3B76: 90 32        BCC $3BAA
C2/3B78: 7B           TDC 
C2/3B79: E2 20        SEP #$20
C2/3B7B: 20 7F 3C     JSR $3C7F
C2/3B7E: A4 32        LDY $32
C2/3B80: A9 20        LDA #$20
C2/3B82: 99 56 20     STA $2056,Y
C2/3B85: A9 2C        LDA #$2C
C2/3B87: 99 57 20     STA $2057,Y
C2/3B8A: A9 7C        LDA #$7C
C2/3B8C: 99 5A 20     STA $205A,Y
C2/3B8F: AD 55 47     LDA $4755
C2/3B92: AA           TAX 
C2/3B93: 7B           TDC 
C2/3B94: 20 D6 01     JSR $01D6       ; set bit x
C2/3B97: 99 59 20     STA $2059,Y
C2/3B9A: 7B           TDC 
C2/3B9B: 99 58 20     STA $2058,Y
C2/3B9E: 20 91 3E     JSR $3E91
C2/3BA1: 20 9C 3D     JSR $3D9C
C2/3BA4: EE 4E 47     INC $474E
C2/3BA7: 4C 0C 3C     JMP $3C0C
C2/3BAA: 7B           TDC 
C2/3BAB: E2 20        SEP #$20
C2/3BAD: BD 20 20     LDA $2020,X
C2/3BB0: 29 80        AND #$80
C2/3BB2: 10 55        BPL $3C09
C2/3BB4: BD 4E 20     LDA $204E,X
C2/3BB7: C9 80        CMP #$80
C2/3BB9: F0 17        BEQ $3BD2
C2/3BBB: C9 81        CMP #$81
C2/3BBD: D0 4A        BNE $3C09
C2/3BBF: AD 73 7C     LDA $7C73
C2/3BC2: C2 20        REP #$20
C2/3BC4: 20 B2 01     JSR $01B2       ; a << 7
C2/3BC7: A8           TAY 
C2/3BC8: 7B           TDC 
C2/3BC9: E2 20        SEP #$20
C2/3BCB: B9 6E 20     LDA $206E,Y
C2/3BCE: 29 83        AND #$83
C2/3BD0: F0 37        BEQ $3C09
C2/3BD2: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/3BD5: C9 32        CMP #$32
C2/3BD7: B0 30        BCS $3C09
C2/3BD9: 20 7F 3C     JSR $3C7F
C2/3BDC: A4 32        LDY $32
C2/3BDE: A9 80        LDA #$80
C2/3BE0: 99 56 20     STA $2056,Y
C2/3BE3: A9 05        LDA #$05
C2/3BE5: 99 57 20     STA $2057,Y
C2/3BE8: 38           SEC 
C2/3BE9: AD 73 7C     LDA $7C73
C2/3BEC: E9 04        SBC #$04
C2/3BEE: AA           TAX 
C2/3BEF: 7B           TDC 
C2/3BF0: 20 D6 01     JSR $01D6       ; set bit x
C2/3BF3: 99 58 20     STA $2058,Y
C2/3BF6: 7B           TDC 
C2/3BF7: 99 59 20     STA $2059,Y
C2/3BFA: 99 5A 20     STA $205A,Y
C2/3BFD: 20 91 3E     JSR $3E91
C2/3C00: 20 9C 3D     JSR $3D9C
C2/3C03: EE 4E 47     INC $474E
C2/3C06: 4C 0C 3C     JMP $3C0C
C2/3C09: 4C 51 39     JMP $3951
C2/3C0C: 9C 56 7C     STZ $7C56
C2/3C0F: 60           RTS 

; [  ]

C2/3C10: 9C 50 7C     STZ $7C50
C2/3C13: 9C 94 46     STZ $4694
C2/3C16: AD 55 47     LDA $4755
C2/3C19: 8D 03 7C     STA $7C03
C2/3C1C: AA           TAX 
C2/3C1D: BD 30 40     LDA $4030,X
C2/3C20: F0 5C        BEQ $3C7E
C2/3C22: BD AE 7C     LDA $7CAE,X
C2/3C25: D0 57        BNE $3C7E
C2/3C27: AD 55 47     LDA $4755
C2/3C2A: 0A           ASL 
C2/3C2B: AA           TAX 
C2/3C2C: C2 20        REP #$20
C2/3C2E: 18           CLC 
C2/3C2F: BF A5 EE D0  LDA $D0EEA5,X
C2/3C33: 69 83 4A     ADC #$4A83
C2/3C36: 85 4B        STA $4B
C2/3C38: 7B           TDC 
C2/3C39: E2 20        SEP #$20
C2/3C3B: 9C 90 46     STZ $4690
C2/3C3E: AD 90 46     LDA $4690
C2/3C41: AA           TAX 
C2/3C42: BF C9 EE D0  LDA $D0EEC9,X
C2/3C46: A8           TAY 
C2/3C47: 8C 92 46     STY $4692
C2/3C4A: 9C 91 46     STZ $4691
C2/3C4D: AC 92 46     LDY $4692
C2/3C50: B1 4B        LDA ($4B),Y
C2/3C52: F0 2A        BEQ $3C7E
C2/3C54: C9 FE        CMP #$FE
C2/3C56: F0 26        BEQ $3C7E
C2/3C58: 20 BF 27     JSR $27BF       ; check monster condition
C2/3C5B: AD 94 46     LDA $4694
C2/3C5E: F0 14        BEQ $3C74       ; branch if monster condition false
C2/3C60: C2 20        REP #$20
C2/3C62: 18           CLC 
C2/3C63: AD 92 46     LDA $4692
C2/3C66: 69 04 00     ADC #$0004
C2/3C69: 8D 92 46     STA $4692
C2/3C6C: 7B           TDC 
C2/3C6D: E2 20        SEP #$20
C2/3C6F: EE 91 46     INC $4691
C2/3C72: 80 D9        BRA $3C4D
C2/3C74: EE 90 46     INC $4690
C2/3C77: AD 90 46     LDA $4690
C2/3C7A: C9 0A        CMP #$0A
C2/3C7C: D0 C0        BNE $3C3E
C2/3C7E: 60           RTS 

; [  ]

C2/3C7F: 7B           TDC 
C2/3C80: A8           TAY 
C2/3C81: A6 32        LDX $32
C2/3C83: BD 56 20     LDA $2056,X
C2/3C86: 99 3A 47     STA $473A,Y
C2/3C89: E8           INX 
C2/3C8A: C8           INY 
C2/3C8B: C0 0A 00     CPY #$000A
C2/3C8E: D0 F3        BNE $3C83
C2/3C90: AD 55 47     LDA $4755
C2/3C93: C9 04        CMP #$04
C2/3C95: 90 5A        BCC $3CF1
C2/3C97: 38           SEC 
C2/3C98: E9 04        SBC #$04
C2/3C9A: 85 10        STA $10
C2/3C9C: 0A           ASL 
C2/3C9D: AA           TAX 
C2/3C9E: BF 95 EE D0  LDA $D0EE95,X
C2/3CA2: 85 0E        STA $0E
C2/3CA4: BF 96 EE D0  LDA $D0EE96,X
C2/3CA8: 85 0F        STA $0F
C2/3CAA: 7B           TDC 
C2/3CAB: A8           TAY 
C2/3CAC: A6 0E        LDX $0E
C2/3CAE: BD 67 43     LDA $4367,X
C2/3CB1: 99 D6 46     STA $46D6,Y
C2/3CB4: E8           INX 
C2/3CB5: C8           INY 
C2/3CB6: C0 64 00     CPY #$0064
C2/3CB9: D0 F3        BNE $3CAE
C2/3CBB: A5 10        LDA $10
C2/3CBD: 20 B5 01     JSR $01B5       ; a << 4
C2/3CC0: AA           TAX 
C2/3CC1: 86 0E        STX $0E
C2/3CC3: 0A           ASL 
C2/3CC4: AA           TAX 
C2/3CC5: 86 10        STX $10
C2/3CC7: 7B           TDC 
C2/3CC8: A8           TAY 
C2/3CC9: A6 0E        LDX $0E
C2/3CCB: BD DE 41     LDA $41DE,X
C2/3CCE: 99 A6 46     STA $46A6,Y
C2/3CD1: E8           INX 
C2/3CD2: C8           INY 
C2/3CD3: C0 10 00     CPY #$0010
C2/3CD6: D0 F3        BNE $3CCB
C2/3CD8: 7B           TDC 
C2/3CD9: A8           TAY 
C2/3CDA: A6 10        LDX $10
C2/3CDC: BD 5E 42     LDA $425E,X
C2/3CDF: 99 B6 46     STA $46B6,Y
C2/3CE2: BD 5F 42     LDA $425F,X
C2/3CE5: 99 B7 46     STA $46B7,Y
C2/3CE8: E8           INX 
C2/3CE9: E8           INX 
C2/3CEA: C8           INY 
C2/3CEB: C8           INY 
C2/3CEC: C0 20 00     CPY #$0020
C2/3CEF: D0 EB        BNE $3CDC
C2/3CF1: AD 55 47     LDA $4755
C2/3CF4: 0A           ASL 
C2/3CF5: AA           TAX 
C2/3CF6: BF 61 ED D0  LDA $D0ED61,X
C2/3CFA: AA           TAX 
C2/3CFB: BD FB 3C     LDA $3CFB,X
C2/3CFE: 8D 44 47     STA $4744
C2/3D01: BD 7F 3D     LDA $3D7F,X
C2/3D04: 8D 45 47     STA $4745
C2/3D07: 60           RTS 

; [  ]

C2/3D08: AD 55 47     LDA $4755
C2/3D0B: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/3D0E: 7B           TDC 
C2/3D0F: A8           TAY 
C2/3D10: A6 32        LDX $32
C2/3D12: B9 3A 47     LDA $473A,Y
C2/3D15: 9D 56 20     STA $2056,X
C2/3D18: E8           INX 
C2/3D19: C8           INY 
C2/3D1A: C0 0A 00     CPY #$000A
C2/3D1D: D0 F3        BNE $3D12
C2/3D1F: AD 55 47     LDA $4755
C2/3D22: C9 04        CMP #$04
C2/3D24: 90 5A        BCC $3D80
C2/3D26: 38           SEC 
C2/3D27: E9 04        SBC #$04
C2/3D29: 85 10        STA $10
C2/3D2B: 0A           ASL 
C2/3D2C: AA           TAX 
C2/3D2D: BF 95 EE D0  LDA $D0EE95,X
C2/3D31: 85 0E        STA $0E
C2/3D33: BF 96 EE D0  LDA $D0EE96,X
C2/3D37: 85 0F        STA $0F
C2/3D39: 7B           TDC 
C2/3D3A: A8           TAY 
C2/3D3B: A6 0E        LDX $0E
C2/3D3D: B9 D6 46     LDA $46D6,Y
C2/3D40: 9D 67 43     STA $4367,X
C2/3D43: E8           INX 
C2/3D44: C8           INY 
C2/3D45: C0 64 00     CPY #$0064
C2/3D48: D0 F3        BNE $3D3D
C2/3D4A: A5 10        LDA $10
C2/3D4C: 20 B5 01     JSR $01B5       ; a << 4
C2/3D4F: AA           TAX 
C2/3D50: 86 0E        STX $0E
C2/3D52: 0A           ASL 
C2/3D53: AA           TAX 
C2/3D54: 86 10        STX $10
C2/3D56: 7B           TDC 
C2/3D57: A8           TAY 
C2/3D58: A6 0E        LDX $0E
C2/3D5A: B9 A6 46     LDA $46A6,Y
C2/3D5D: 9D DE 41     STA $41DE,X
C2/3D60: E8           INX 
C2/3D61: C8           INY 
C2/3D62: C0 10 00     CPY #$0010
C2/3D65: D0 F3        BNE $3D5A
C2/3D67: 7B           TDC 
C2/3D68: A8           TAY 
C2/3D69: A6 10        LDX $10
C2/3D6B: B9 B6 46     LDA $46B6,Y
C2/3D6E: 9D 5E 42     STA $425E,X
C2/3D71: B9 B7 46     LDA $46B7,Y
C2/3D74: 9D 5F 42     STA $425F,X
C2/3D77: E8           INX 
C2/3D78: E8           INX 
C2/3D79: C8           INY 
C2/3D7A: C8           INY 
C2/3D7B: C0 20 00     CPY #$0020
C2/3D7E: D0 EB        BNE $3D6B
C2/3D80: AD 55 47     LDA $4755
C2/3D83: 0A           ASL 
C2/3D84: AA           TAX 
C2/3D85: BF 61 ED D0  LDA $D0ED61,X
C2/3D89: AA           TAX 
C2/3D8A: AD 44 47     LDA $4744
C2/3D8D: 9D FB 3C     STA $3CFB,X
C2/3D90: AD 45 47     LDA $4745
C2/3D93: 9D 7F 3D     STA $3D7F,X
C2/3D96: A9 FF        LDA #$FF
C2/3D98: 8D 55 47     STA $4755
C2/3D9B: 60           RTS 

; [  ]

C2/3D9C: 7B           TDC 
C2/3D9D: AA           TAX 
C2/3D9E: 86 0E        STX $0E
C2/3DA0: AD 55 47     LDA $4755
C2/3DA3: C5 0E        CMP $0E
C2/3DA5: D0 05        BNE $3DAC
C2/3DA7: 9E 9F 3E     STZ $3E9F,X
C2/3DAA: 80 03        BRA $3DAF
C2/3DAC: FE 9F 3E     INC $3E9F,X
C2/3DAF: E6 0E        INC $0E
C2/3DB1: E8           INX 
C2/3DB2: E0 0C 00     CPX #$000C
C2/3DB5: D0 EC        BNE $3DA3
C2/3DB7: EE 56 47     INC $4756
C2/3DBA: 60           RTS 

; [  ]

C2/3DBB: 7B           TDC 
C2/3DBC: AA           TAX 
C2/3DBD: 9E 9F 3E     STZ $3E9F,X
C2/3DC0: E8           INX 
C2/3DC1: E0 0C 00     CPX #$000C
C2/3DC4: D0 F7        BNE $3DBD
C2/3DC6: 60           RTS 

; [  ]

C2/3DC7: 38           SEC 
C2/3DC8: AD 55 47     LDA $4755
C2/3DCB: E9 04        SBC #$04
C2/3DCD: 8D 03 7C     STA $7C03
C2/3DD0: 20 B5 01     JSR $01B5       ; a << 4
C2/3DD3: AA           TAX 
C2/3DD4: 8E 5E 43     STX $435E
C2/3DD7: 0A           ASL 
C2/3DD8: AA           TAX 
C2/3DD9: 8E 60 43     STX $4360
C2/3DDC: 7B           TDC 
C2/3DDD: A8           TAY 
C2/3DDE: AE 5E 43     LDX $435E
C2/3DE1: A9 FF        LDA #$FF
C2/3DE3: 9D DE 41     STA $41DE,X
C2/3DE6: E8           INX 
C2/3DE7: C8           INY 
C2/3DE8: C0 10 00     CPY #$0010
C2/3DEB: D0 F6        BNE $3DE3
C2/3DED: A6 32        LDX $32
C2/3DEF: A9 2C        LDA #$2C
C2/3DF1: 9D 57 20     STA $2057,X
C2/3DF4: A9 21        LDA #$21
C2/3DF6: 9D 56 20     STA $2056,X
C2/3DF9: EE 4E 47     INC $474E
C2/3DFC: A2 40 00     LDX #$0040
C2/3DFF: A9 FF        LDA #$FF
C2/3E01: 9D 40 26     STA $2640,X
C2/3E04: CA           DEX 
C2/3E05: 10 FA        BPL $3E01
C2/3E07: C2 20        REP #$20
C2/3E09: 18           CLC 
C2/3E0A: A5 4B        LDA $4B
C2/3E0C: 69 AA 00     ADC #$00AA
C2/3E0F: 85 4B        STA $4B
C2/3E11: 7B           TDC 
C2/3E12: E2 20        SEP #$20
C2/3E14: AD 90 46     LDA $4690
C2/3E17: 0A           ASL 
C2/3E18: AA           TAX 
C2/3E19: BF B5 EE D0  LDA $D0EEB5,X
C2/3E1D: 85 0E        STA $0E
C2/3E1F: BF B6 EE D0  LDA $D0EEB6,X
C2/3E23: 85 0F        STA $0F
C2/3E25: 7B           TDC 
C2/3E26: AA           TAX 
C2/3E27: A4 0E        LDY $0E
C2/3E29: B1 4B        LDA ($4B),Y
C2/3E2B: 9D 40 26     STA $2640,X
C2/3E2E: C8           INY 
C2/3E2F: E8           INX 
C2/3E30: C9 FE        CMP #$FE
C2/3E32: F0 58        BEQ $3E8C
C2/3E34: C9 FF        CMP #$FF
C2/3E36: F0 54        BEQ $3E8C
C2/3E38: C9 FD        CMP #$FD
C2/3E3A: D0 50        BNE $3E8C
C2/3E3C: B1 4B        LDA ($4B),Y
C2/3E3E: 9D 40 26     STA $2640,X
C2/3E41: C8           INY 
C2/3E42: E8           INX 
C2/3E43: C9 F7        CMP #$F7
C2/3E45: F0 12        BEQ $3E59
C2/3E47: C9 F0        CMP #$F0
C2/3E49: B0 31        BCS $3E7C
C2/3E4B: B1 4B        LDA ($4B),Y
C2/3E4D: 9D 40 26     STA $2640,X
C2/3E50: C8           INY 
C2/3E51: E8           INX 
C2/3E52: B1 4B        LDA ($4B),Y
C2/3E54: 9D 40 26     STA $2640,X
C2/3E57: 80 33        BRA $3E8C
C2/3E59: B1 4B        LDA ($4B),Y
C2/3E5B: 9D 40 26     STA $2640,X
C2/3E5E: 85 10        STA $10
C2/3E60: C8           INY 
C2/3E61: E8           INX 
C2/3E62: B1 4B        LDA ($4B),Y
C2/3E64: 9D 40 26     STA $2640,X
C2/3E67: C8           INY 
C2/3E68: E8           INX 
C2/3E69: 64 11        STZ $11
C2/3E6B: B1 4B        LDA ($4B),Y
C2/3E6D: 9D 40 26     STA $2640,X
C2/3E70: C8           INY 
C2/3E71: E8           INX 
C2/3E72: E6 11        INC $11
C2/3E74: A5 11        LDA $11
C2/3E76: C5 10        CMP $10
C2/3E78: D0 F1        BNE $3E6B
C2/3E7A: 80 10        BRA $3E8C
C2/3E7C: B1 4B        LDA ($4B),Y
C2/3E7E: 9D 40 26     STA $2640,X
C2/3E81: C8           INY 
C2/3E82: E8           INX 
C2/3E83: B1 4B        LDA ($4B),Y
C2/3E85: 9D 40 26     STA $2640,X
C2/3E88: C8           INY 
C2/3E89: E8           INX 
C2/3E8A: 80 9D        BRA $3E29
C2/3E8C: 64 22        STZ $22
C2/3E8E: 20 10 32     JSR $3210
C2/3E91: AD 55 47     LDA $4755
C2/3E94: 20 07 02     JSR $0207       ; get timer data offset
C2/3E97: A9 01        LDA #$01
C2/3E99: 99 7F 3D     STA $3D7F,Y
C2/3E9C: A9 41        LDA #$41
C2/3E9E: 99 FB 3C     STA $3CFB,Y
C2/3EA1: 60           RTS 

; [ init character/monster properties ]

C2/3EA2: 7B           TDC 
C2/3EA3: AA           TAX 
C2/3EA4: A8           TAY 
C2/3EA5: A9 04        LDA #$04
C2/3EA7: 85 10        STA $10
C2/3EA9: A9 50        LDA #$50
C2/3EAB: 85 0E        STA $0E
C2/3EAD: AD F0 04     LDA $04F0
C2/3EB0: C9 F7        CMP #$F7
C2/3EB2: D0 0C        BNE $3EC0
C2/3EB4: AD F1 04     LDA $04F1
C2/3EB7: C9 01        CMP #$01
C2/3EB9: D0 05        BNE $3EC0
C2/3EBB: A9 08        LDA #$08
C2/3EBD: 99 73 20     STA $2073,Y
C2/3EC0: BD 00 05     LDA $0500,X     ; copy character properties
C2/3EC3: 99 00 20     STA $2000,Y
C2/3EC6: E8           INX 
C2/3EC7: C8           INY 
C2/3EC8: C6 0E        DEC $0E
C2/3ECA: A5 0E        LDA $0E
C2/3ECC: D0 F2        BNE $3EC0
C2/3ECE: C2 20        REP #$20
C2/3ED0: 98           TYA 
C2/3ED1: 18           CLC 
C2/3ED2: 69 30 00     ADC #$0030
C2/3ED5: A8           TAY 
C2/3ED6: 7B           TDC 
C2/3ED7: E2 20        SEP #$20
C2/3ED9: C6 10        DEC $10
C2/3EDB: A5 10        LDA $10
C2/3EDD: D0 CA        BNE $3EA9
C2/3EDF: AD F1 04     LDA $04F1
C2/3EE2: F0 2D        BEQ $3F11
C2/3EE4: AD F0 04     LDA $04F0
C2/3EE7: C9 BA        CMP #$BA
C2/3EE9: D0 26        BNE $3F11       ; branch if not battle 442 (Forza, Magisa)
C2/3EEB: 7B           TDC 
C2/3EEC: AA           TAX 
C2/3EED: A8           TAY 
C2/3EEE: BD 00 20     LDA $2000,X
C2/3EF1: 29 07        AND #$07
C2/3EF3: C9 01        CMP #$01
C2/3EF5: D0 11        BNE $3F08       ; branch if not lenna
C2/3EF7: BD 1A 20     LDA $201A,X
C2/3EFA: 29 C6        AND #$C6
C2/3EFC: D0 13        BNE $3F11       ; branch if dead, zombie, etc.
C2/3EFE: BD 1A 20     LDA $201A,X
C2/3F01: 09 04        ORA #$04
C2/3F03: 9D 1A 20     STA $201A,X     ; inflict poison status
C2/3F06: 80 09        BRA $3F11
C2/3F08: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/3F0B: C8           INY 
C2/3F0C: C0 04 00     CPY #$0004
C2/3F0F: D0 DD        BNE $3EEE
C2/3F11: 20 D5 45     JSR $45D5
C2/3F14: 20 5E 9A     JSR $9A5E       ; update character equipment (all)
C2/3F17: 7B           TDC 
C2/3F18: AA           TAX 
C2/3F19: 86 0E        STX $0E
C2/3F1B: 86 10        STX $10
C2/3F1D: 86 12        STX $12
C2/3F1F: A9 D0        LDA #$D0
C2/3F21: 85 22        STA $22
C2/3F23: 85 1E        STA $1E
C2/3F25: A2 00 9C     LDX #$9C00      ; D0/9C00 (pointers to monster scripts)
C2/3F28: 86 20        STX $20
C2/3F2A: A2 00 00     LDX #$0000
C2/3F2D: A9 02        LDA #$02
C2/3F2F: 20 7C 00     JSR $007C       ; a = (x..a)
C2/3F32: C9 02        CMP #$02
C2/3F34: D0 02        BNE $3F38
C2/3F36: A9 FF        LDA #$FF
C2/3F38: 85 16        STA $16         ; $16 = (-1..1)
C2/3F3A: A6 0E        LDX $0E
C2/3F3C: A4 10        LDY $10
C2/3F3E: 18           CLC 
C2/3F3F: BD FF 3E     LDA $3EFF,X     ; monster speed + (-1..1)
C2/3F42: 65 16        ADC $16
C2/3F44: 99 25 22     STA $2225,Y
C2/3F47: 99 29 22     STA $2229,Y
C2/3F4A: BD 00 3F     LDA $3F00,X
C2/3F4D: 99 44 22     STA $2244,Y
C2/3F50: BD 01 3F     LDA $3F01,X
C2/3F53: 99 62 22     STA $2262,Y
C2/3F56: BD 02 3F     LDA $3F02,X
C2/3F59: 99 2C 22     STA $222C,Y
C2/3F5C: BD 03 3F     LDA $3F03,X
C2/3F5F: 99 2D 22     STA $222D,Y
C2/3F62: BD 04 3F     LDA $3F04,X
C2/3F65: 99 27 22     STA $2227,Y
C2/3F68: 99 2B 22     STA $222B,Y
C2/3F6B: BD 05 3F     LDA $3F05,X
C2/3F6E: 99 2F 22     STA $222F,Y
C2/3F71: BD 06 3F     LDA $3F06,X
C2/3F74: 99 2E 22     STA $222E,Y
C2/3F77: C2 20        REP #$20
C2/3F79: BD 07 3F     LDA $3F07,X
C2/3F7C: 99 06 22     STA $2206,Y
C2/3F7F: 99 08 22     STA $2208,Y
C2/3F82: BD 09 3F     LDA $3F09,X
C2/3F85: 99 0A 22     STA $220A,Y
C2/3F88: A9 0F 27     LDA #$270F
C2/3F8B: 99 0C 22     STA $220C,Y
C2/3F8E: BD 0B 3F     LDA $3F0B,X
C2/3F91: 99 67 22     STA $2267,Y
C2/3F94: BD 0D 3F     LDA $3F0D,X
C2/3F97: 99 69 22     STA $2269,Y
C2/3F9A: BD 11 3F     LDA $3F11,X
C2/3F9D: 99 35 22     STA $2235,Y
C2/3FA0: 7B           TDC 
C2/3FA1: E2 20        SEP #$20
C2/3FA3: 99 00 22     STA $2200,Y
C2/3FA6: BD 13 3F     LDA $3F13,X
C2/3FA9: 99 37 22     STA $2237,Y
C2/3FAC: BD 0F 3F     LDA $3F0F,X
C2/3FAF: 99 13 22     STA $2213,Y
C2/3FB2: BD 14 3F     LDA $3F14,X
C2/3FB5: 99 30 22     STA $2230,Y
C2/3FB8: BD 10 3F     LDA $3F10,X
C2/3FBB: 99 32 22     STA $2232,Y
C2/3FBE: BD 15 3F     LDA $3F15,X
C2/3FC1: 99 64 22     STA $2264,Y
C2/3FC4: BD 16 3F     LDA $3F16,X
C2/3FC7: 99 34 22     STA $2234,Y
C2/3FCA: BD 17 3F     LDA $3F17,X
C2/3FCD: 99 65 22     STA $2265,Y
C2/3FD0: BD 18 3F     LDA $3F18,X
C2/3FD3: 99 66 22     STA $2266,Y
C2/3FD6: BD 1E 3F     LDA $3F1E,X
C2/3FD9: 99 02 22     STA $2202,Y
C2/3FDC: 99 2A 22     STA $222A,Y
C2/3FDF: 5A           PHY 
C2/3FE0: BD 19 3F     LDA $3F19,X
C2/3FE3: 10 0B        BPL $3FF0
C2/3FE5: C2 20        REP #$20
C2/3FE7: 98           TYA 
C2/3FE8: 18           CLC 
C2/3FE9: 69 56 00     ADC #$0056
C2/3FEC: A8           TAY 
C2/3FED: 7B           TDC 
C2/3FEE: E2 20        SEP #$20
C2/3FF0: BD 19 3F     LDA $3F19,X
C2/3FF3: 29 7F        AND #$7F
C2/3FF5: 99 1A 22     STA $221A,Y
C2/3FF8: BD 1A 3F     LDA $3F1A,X
C2/3FFB: 99 1B 22     STA $221B,Y
C2/3FFE: BD 1B 3F     LDA $3F1B,X
C2/4001: 99 1C 22     STA $221C,Y
C2/4004: BD 1C 3F     LDA $3F1C,X
C2/4007: 99 1D 22     STA $221D,Y
C2/400A: A5 12        LDA $12
C2/400C: 0A           ASL 
C2/400D: A8           TAY 
C2/400E: BD 1D 3F     LDA $3F1D,X     ; monster index
C2/4011: 99 08 40     STA $4008,Y
C2/4014: AD 21 40     LDA $4021
C2/4017: 99 09 40     STA $4009,Y
C2/401A: A5 12        LDA $12
C2/401C: 0A           ASL 
C2/401D: AA           TAX 
C2/401E: C2 20        REP #$20
C2/4020: BD 20 40     LDA $4020,X
C2/4023: 0A           ASL 
C2/4024: AA           TAX 
C2/4025: 7B           TDC 
C2/4026: E2 20        SEP #$20
C2/4028: BF 00 99 D0  LDA $D09900,X   ; monster special attack properties
C2/402C: 85 1C        STA $1C
C2/402E: BF 01 99 D0  LDA $D09901,X
C2/4032: 85 1D        STA $1D
C2/4034: 7A           PLY 
C2/4035: A5 1C        LDA $1C
C2/4037: 99 6E 22     STA $226E,Y
C2/403A: A5 1D        LDA $1D
C2/403C: 99 7F 22     STA $227F,Y
C2/403F: A5 12        LDA $12
C2/4041: 0A           ASL 
C2/4042: AA           TAX 
C2/4043: C2 20        REP #$20
C2/4045: BD 20 40     LDA $4020,X     ; monster index
C2/4048: 0A           ASL 
C2/4049: A8           TAY 
C2/404A: 7B           TDC 
C2/404B: E2 20        SEP #$20
C2/404D: B7 20        LDA [$20],Y     ; pointer to monster script
C2/404F: 85 1C        STA $1C
C2/4051: C8           INY 
C2/4052: B7 20        LDA [$20],Y
C2/4054: 85 1D        STA $1D
C2/4056: A2 54 06     LDX #$0654      ; monster script buffers are 1620 bytes each
C2/4059: 86 2A        STX $2A
C2/405B: A6 12        LDX $12
C2/405D: 86 2C        STX $2C
C2/405F: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/4062: A6 2E        LDX $2E
C2/4064: 86 08        STX $08
C2/4066: 86 0A        STX $0A
C2/4068: DA           PHX 
C2/4069: 7B           TDC 
C2/406A: A8           TAY 
C2/406B: 84 0C        STY $0C
C2/406D: A6 08        LDX $08
C2/406F: B7 1C        LDA [$1C],Y     ; monster script (condition)
C2/4071: 9D 59 47     STA $4759,X
C2/4074: E8           INX 
C2/4075: C8           INY 
C2/4076: C9 FE        CMP #$FE
C2/4078: D0 F5        BNE $406F
C2/407A: A6 0A        LDX $0A
C2/407C: B7 1C        LDA [$1C],Y     ; monster script (action)
C2/407E: 9D 03 48     STA $4803,X
C2/4081: E8           INX 
C2/4082: C8           INY 
C2/4083: C9 FF        CMP #$FF
C2/4085: F0 21        BEQ $40A8
C2/4087: C9 FE        CMP #$FE
C2/4089: D0 F1        BNE $407C
C2/408B: C2 20        REP #$20
C2/408D: 18           CLC 
C2/408E: A5 08        LDA $08
C2/4090: 69 11 00     ADC #$0011
C2/4093: 85 08        STA $08
C2/4095: 18           CLC 
C2/4096: A5 0A        LDA $0A
C2/4098: 69 40 00     ADC #$0040
C2/409B: 85 0A        STA $0A
C2/409D: 7B           TDC 
C2/409E: E2 20        SEP #$20
C2/40A0: E6 0C        INC $0C
C2/40A2: A5 0C        LDA $0C
C2/40A4: C9 0A        CMP #$0A
C2/40A6: D0 C5        BNE $406D
C2/40A8: FA           PLX 
C2/40A9: 86 08        STX $08
C2/40AB: 86 0A        STX $0A
C2/40AD: 86 0C        STX $0C
C2/40AF: A6 08        LDX $08
C2/40B1: B7 1C        LDA [$1C],Y     ; retaliation script (condition)
C2/40B3: 9D 83 4A     STA $4A83,X
C2/40B6: E8           INX 
C2/40B7: C8           INY 
C2/40B8: C9 FF        CMP #$FF
C2/40BA: F0 37        BEQ $40F3
C2/40BC: C9 FE        CMP #$FE
C2/40BE: D0 F1        BNE $40B1
C2/40C0: A6 12        LDX $12
C2/40C2: FE 30 40     INC $4030,X
C2/40C5: A6 0A        LDX $0A
C2/40C7: B7 1C        LDA [$1C],Y     ; retaliation script (action)
C2/40C9: 9D 2D 4B     STA $4B2D,X
C2/40CC: E8           INX 
C2/40CD: C8           INY 
C2/40CE: C9 FF        CMP #$FF
C2/40D0: F0 21        BEQ $40F3
C2/40D2: C9 FE        CMP #$FE
C2/40D4: D0 F1        BNE $40C7
C2/40D6: C2 20        REP #$20
C2/40D8: 18           CLC 
C2/40D9: A5 08        LDA $08
C2/40DB: 69 11 00     ADC #$0011
C2/40DE: 85 08        STA $08
C2/40E0: 18           CLC 
C2/40E1: A5 0A        LDA $0A
C2/40E3: 69 40 00     ADC #$0040
C2/40E6: 85 0A        STA $0A
C2/40E8: 7B           TDC 
C2/40E9: E2 20        SEP #$20
C2/40EB: E6 0C        INC $0C
C2/40ED: A5 0C        LDA $0C
C2/40EF: C9 0A        CMP #$0A
C2/40F1: D0 BC        BNE $40AF
C2/40F3: A6 10        LDX $10         ; next monster
C2/40F5: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/40F8: 86 10        STX $10
C2/40FA: 18           CLC 
C2/40FB: A5 0E        LDA $0E
C2/40FD: 69 20        ADC #$20
C2/40FF: 85 0E        STA $0E
C2/4101: E6 12        INC $12
C2/4103: A5 12        LDA $12
C2/4105: C9 08        CMP #$08
C2/4107: F0 03        BEQ $410C
C2/4109: 4C 2A 3F     JMP $3F2A
C2/410C: 7B           TDC 
C2/410D: AA           TAX 
C2/410E: A9 04        LDA #$04
C2/4110: 8D 20 26     STA $2620       ; current monster
C2/4113: AD 20 26     LDA $2620
C2/4116: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/4119: BD 1A 20     LDA $201A,X
C2/411C: 29 04        AND #$04
C2/411E: F0 05        BEQ $4125       ; branch if no poison status
C2/4120: A9 01        LDA #$01        ; start poison timer
C2/4122: 20 A3 41     JSR $41A3
C2/4125: A6 32        LDX $32
C2/4127: BD 1B 20     LDA $201B,X
C2/412A: 29 80        AND #$80
C2/412C: F0 05        BEQ $4133
C2/412E: A9 06        LDA #$06        ; start "old" timer
C2/4130: 20 A3 41     JSR $41A3
C2/4133: A6 32        LDX $32
C2/4135: BD 1B 20     LDA $201B,X
C2/4138: 29 20        AND #$20
C2/413A: F0 05        BEQ $4141
C2/413C: A9 09        LDA #$09        ; start paralyze timer
C2/413E: 20 A3 41     JSR $41A3
C2/4141: A6 32        LDX $32
C2/4143: BD 1B 20     LDA $201B,X
C2/4146: 29 04        AND #$04
C2/4148: F0 05        BEQ $414F
C2/414A: A9 04        LDA #$04        ; start mute timer
C2/414C: 20 A3 41     JSR $41A3
C2/414F: A6 32        LDX $32
C2/4151: BD 1C 20     LDA $201C,X
C2/4154: 29 80        AND #$80
C2/4156: F0 05        BEQ $415D
C2/4158: A9 02        LDA #$02        ; start reflect timer
C2/415A: 20 A3 41     JSR $41A3
C2/415D: A6 32        LDX $32
C2/415F: BD 1C 20     LDA $201C,X
C2/4162: 29 10        AND #$10
C2/4164: F0 05        BEQ $416B
C2/4166: A9 00        LDA #$00        ; start "stop" timer
C2/4168: 20 A3 41     JSR $41A3
C2/416B: A6 32        LDX $32
C2/416D: BD 1C 20     LDA $201C,X
C2/4170: 29 01        AND #$01
C2/4172: F0 05        BEQ $4179
C2/4174: A9 07        LDA #$07        ; start regen timer
C2/4176: 20 A3 41     JSR $41A3
C2/4179: A6 32        LDX $32
C2/417B: BD 1D 20     LDA $201D,X
C2/417E: 29 10        AND #$10
C2/4180: F0 05        BEQ $4187
C2/4182: A9 03        LDA #$03        ; start condemn timer
C2/4184: 20 A3 41     JSR $41A3
C2/4187: A6 32        LDX $32
C2/4189: BD 1C 20     LDA $201C,X
C2/418C: 29 08        AND #$08
C2/418E: F0 05        BEQ $4195
C2/4190: A9 05        LDA #$05        ; start hp leak timer
C2/4192: 20 A3 41     JSR $41A3
C2/4195: EE 20 26     INC $2620       ; next monster
C2/4198: AD 20 26     LDA $2620
C2/419B: C9 0C        CMP #$0C
C2/419D: F0 03        BEQ $41A2
C2/419F: 4C 13 41     JMP $4113
C2/41A2: 60           RTS 

; [ start status timer (use default duration) ]

C2/41A3: AA           TAX 
C2/41A4: A9 01        LDA #$01
C2/41A6: 8D D7 3E     STA $3ED7       ; default timer duration
C2/41A9: AD 20 26     LDA $2620
C2/41AC: 4C FD 24     JMP $24FD       ; start timer

; [  ]

C2/41AF: 7B           TDC 
C2/41B0: AA           TAX 
C2/41B1: A9 80        LDA #$80
C2/41B3: 9D 34 2B     STA $2B34,X
C2/41B6: E8           INX 
C2/41B7: E0 00 01     CPX #$0100
C2/41BA: D0 F7        BNE $41B3
C2/41BC: 7B           TDC 
C2/41BD: AA           TAX 
C2/41BE: 86 0E        STX $0E
C2/41C0: 7B           TDC 
C2/41C1: A8           TAY 
C2/41C2: A9 81        LDA #$81
C2/41C4: 9D 3C 2F     STA $2F3C,X
C2/41C7: 9D B6 2D     STA $2DB6,X
C2/41CA: E8           INX 
C2/41CB: C8           INY 
C2/41CC: C0 82 00     CPY #$0082
C2/41CF: D0 F3        BNE $41C4
C2/41D1: C2 20        REP #$20
C2/41D3: 8A           TXA 
C2/41D4: 18           CLC 
C2/41D5: 69 08 02     ADC #$0208
C2/41D8: AA           TAX 
C2/41D9: 7B           TDC 
C2/41DA: E2 20        SEP #$20
C2/41DC: E6 0E        INC $0E
C2/41DE: A5 0E        LDA $0E
C2/41E0: C9 04        CMP #$04
C2/41E2: D0 DC        BNE $41C0
C2/41E4: 7B           TDC 
C2/41E5: AA           TAX 
C2/41E6: 86 0E        STX $0E
C2/41E8: 7B           TDC 
C2/41E9: A8           TAY 
C2/41EA: A9 80        LDA #$80
C2/41EC: 9D 6C 37     STA $376C,X
C2/41EF: E8           INX 
C2/41F0: C8           INY 
C2/41F1: C0 04 00     CPY #$0004
C2/41F4: D0 F6        BNE $41EC
C2/41F6: 8A           TXA 
C2/41F7: 18           CLC 
C2/41F8: 69 10        ADC #$10
C2/41FA: AA           TAX 
C2/41FB: E6 0E        INC $0E
C2/41FD: A5 0E        LDA $0E
C2/41FF: C9 04        CMP #$04
C2/4201: D0 E5        BNE $41E8
C2/4203: 7B           TDC 
C2/4204: AA           TAX 
C2/4205: 86 0E        STX $0E
C2/4207: 7B           TDC 
C2/4208: A8           TAY 
C2/4209: A9 80        LDA #$80
C2/420B: 9D B4 37     STA $37B4,X
C2/420E: E8           INX 
C2/420F: C8           INY 
C2/4210: C0 02 00     CPY #$0002
C2/4213: D0 F6        BNE $420B
C2/4215: 8A           TXA 
C2/4216: 18           CLC 
C2/4217: 69 0A        ADC #$0A
C2/4219: AA           TAX 
C2/421A: E6 0E        INC $0E
C2/421C: A5 0E        LDA $0E
C2/421E: C9 04        CMP #$04
C2/4220: D0 E5        BNE $4207
C2/4222: 7B           TDC 
C2/4223: A8           TAY 
C2/4224: AA           TAX 
C2/4225: 84 0E        STY $0E
C2/4227: 64 0E        STZ $0E
C2/4229: DA           PHX 
C2/422A: BD 40 20     LDA $2040,X     ; equipment types
C2/422D: 99 99 41     STA $4199,Y
C2/4230: E8           INX 
C2/4231: C8           INY 
C2/4232: E6 0E        INC $0E
C2/4234: A5 0E        LDA $0E
C2/4236: C9 04        CMP #$04
C2/4238: D0 F0        BNE $422A
C2/423A: FA           PLX 
C2/423B: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/423E: E6 0F        INC $0F
C2/4240: A5 0F        LDA $0F
C2/4242: C9 04        CMP #$04
C2/4244: D0 E1        BNE $4227
C2/4246: 22 78 EF D0  JSL $D0EF78     ; validate inventory
C2/424A: 7B           TDC 
C2/424B: AA           TAX 
C2/424C: A8           TAY 
C2/424D: BD 40 06     LDA $0640,X     ; item id
C2/4250: 9D 34 27     STA $2734,X
C2/4253: E8           INX 
C2/4254: E0 00 02     CPX #$0200
C2/4257: D0 F4        BNE $424D
C2/4259: B9 34 27     LDA $2734,Y
C2/425C: 20 FA 03     JSR $03FA
C2/425F: C8           INY 
C2/4260: C0 00 01     CPY #$0100
C2/4263: D0 F4        BNE $4259
C2/4265: 7B           TDC 
C2/4266: A8           TAY 
C2/4267: 84 08        STY $08
C2/4269: A4 08        LDY $08
C2/426B: 20 69 03     JSR $0369
C2/426E: A4 08        LDY $08
C2/4270: 99 20 26     STA $2620,Y
C2/4273: E6 08        INC $08
C2/4275: A5 08        LDA $08
C2/4277: D0 F0        BNE $4269
C2/4279: 7B           TDC 
C2/427A: AA           TAX 
C2/427B: BD 20 26     LDA $2620,X
C2/427E: 9D 34 2C     STA $2C34,X
C2/4281: E8           INX 
C2/4282: E0 00 01     CPX #$0100
C2/4285: D0 F4        BNE $427B
C2/4287: 7B           TDC 
C2/4288: AA           TAX 
C2/4289: 86 0E        STX $0E
C2/428B: 86 10        STX $10
C2/428D: 86 18        STX $18
C2/428F: E8           INX 
C2/4290: 86 14        STX $14
C2/4292: A5 0E        LDA $0E
C2/4294: C9 0C        CMP #$0C
C2/4296: 90 0B        BCC $42A3
C2/4298: 38           SEC 
C2/4299: A5 0E        LDA $0E
C2/429B: E9 0C        SBC #$0C
C2/429D: 18           CLC 
C2/429E: 69 10        ADC #$10
C2/42A0: AA           TAX 
C2/42A1: 80 02        BRA $42A5
C2/42A3: A6 0E        LDX $0E
C2/42A5: BD 50 09     LDA $0950,X     ; spells known
C2/42A8: 85 12        STA $12
C2/42AA: A0 08 00     LDY #$0008
C2/42AD: A6 10        LDX $10         ; spell index
C2/42AF: E0 81 00     CPX #$0081
C2/42B2: D0 03        BNE $42B7
C2/42B4: 4C 67 43     JMP $4367       ; exit loop
C2/42B7: 06 12        ASL $12
C2/42B9: B0 10        BCS $42CB       ; branch if spell is known
C2/42BB: A9 FF        LDA #$FF
C2/42BD: 9D 34 2D     STA $2D34,X     ; spell is unavailable
C2/42C0: 9D BE 2F     STA $2FBE,X
C2/42C3: 9D 48 32     STA $3248,X
C2/42C6: 9D D2 34     STA $34D2,X
C2/42C9: 80 6B        BRA $4336
C2/42CB: 8A           TXA 
C2/42CC: C9 5F        CMP #$5F
C2/42CE: 90 18        BCC $42E8
C2/42D0: 38           SEC 
C2/42D1: E9 5F        SBC #$5F
C2/42D3: 18           CLC 
C2/42D4: 69 80        ADC #$80
C2/42D6: 48           PHA 
C2/42D7: A9 FF        LDA #$FF
C2/42D9: 9D 34 2D     STA $2D34,X
C2/42DC: 9D BE 2F     STA $2FBE,X
C2/42DF: 9D 48 32     STA $3248,X
C2/42E2: 9D D2 34     STA $34D2,X
C2/42E5: 68           PLA 
C2/42E6: CA           DEX 
C2/42E7: CA           DEX 
C2/42E8: 86 20        STX $20
C2/42EA: 9D 34 2D     STA $2D34,X     ; spell index
C2/42ED: 9D BE 2F     STA $2FBE,X
C2/42F0: 9D 48 32     STA $3248,X
C2/42F3: 9D D2 34     STA $34D2,X
C2/42F6: A5 14        LDA $14
C2/42F8: 9D B6 2D     STA $2DB6,X     ; 
C2/42FB: 9D 40 30     STA $3040,X
C2/42FE: 9D CA 32     STA $32CA,X
C2/4301: 9D 54 35     STA $3554,X
C2/4304: BD 34 2D     LDA $2D34,X
C2/4307: C2 20        REP #$20
C2/4309: 20 B6 01     JSR $01B6       ; a << 3
C2/430C: AA           TAX 
C2/430D: 7B           TDC 
C2/430E: E2 20        SEP #$20
C2/4310: BF 80 0B D1  LDA $D10B80,X   ; spell targeting
C2/4314: 48           PHA 
C2/4315: BF 83 0B D1  LDA $D10B83,X   ; mp cost
C2/4319: 29 7F        AND #$7F
C2/431B: A6 20        LDX $20
C2/431D: 9D 38 2E     STA $2E38,X
C2/4320: 9D C2 30     STA $30C2,X
C2/4323: 9D 4C 33     STA $334C,X
C2/4326: 9D D6 35     STA $35D6,X
C2/4329: 68           PLA 
C2/432A: 9D BA 2E     STA $2EBA,X
C2/432D: 9D 44 31     STA $3144,X
C2/4330: 9D CE 33     STA $33CE,X
C2/4333: 9D 58 36     STA $3658,X
C2/4336: E6 15        INC $15
C2/4338: A5 15        LDA $15
C2/433A: C9 03        CMP #$03
C2/433C: D0 0E        BNE $434C
C2/433E: 64 15        STZ $15
C2/4340: E6 14        INC $14
C2/4342: A5 14        LDA $14
C2/4344: C9 07        CMP #$07
C2/4346: D0 04        BNE $434C
C2/4348: A9 01        LDA #$01
C2/434A: 85 14        STA $14
C2/434C: E6 10        INC $10
C2/434E: A5 18        LDA $18
C2/4350: D0 0A        BNE $435C
C2/4352: A5 10        LDA $10
C2/4354: C9 5F        CMP #$5F
C2/4356: 90 04        BCC $435C
C2/4358: E6 18        INC $18
C2/435A: 80 06        BRA $4362
C2/435C: 88           DEY             ; next spell
C2/435D: F0 03        BEQ $4362
C2/435F: 4C AD 42     JMP $42AD
C2/4362: E6 0E        INC $0E         ; next byte
C2/4364: 4C 92 42     JMP $4292
C2/4367: 7B           TDC 
C2/4368: A8           TAY 
C2/4369: AA           TAX 
C2/436A: 64 0E        STZ $0E
C2/436C: DA           PHX 
C2/436D: BD 3D 20     LDA $203D,X
C2/4370: 48           PHA 
C2/4371: 20 BE 01     JSR $01BE       ; a >> 4
C2/4374: 1A           INC 
C2/4375: 99 20 26     STA $2620,Y
C2/4378: 68           PLA 
C2/4379: 29 0F        AND #$0F
C2/437B: 1A           INC 
C2/437C: 99 21 26     STA $2621,Y
C2/437F: C8           INY 
C2/4380: C8           INY 
C2/4381: E8           INX 
C2/4382: E6 0E        INC $0E
C2/4384: A5 0E        LDA $0E
C2/4386: C9 03        CMP #$03
C2/4388: D0 E3        BNE $436D
C2/438A: FA           PLX 
C2/438B: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/438E: C0 18 00     CPY #$0018
C2/4391: D0 D7        BNE $436A
C2/4393: 7B           TDC 
C2/4394: AA           TAX 
C2/4395: A8           TAY 
C2/4396: 84 12        STY $12
C2/4398: 84 3D        STY $3D
C2/439A: 84 3F        STY $3F
C2/439C: 64 1A        STZ $1A
C2/439E: DA           PHX 
C2/439F: A5 12        LDA $12
C2/43A1: C2 20        REP #$20
C2/43A3: 20 B2 01     JSR $01B2       ; a << 7
C2/43A6: AA           TAX 
C2/43A7: 7B           TDC 
C2/43A8: E2 20        SEP #$20
C2/43AA: BD 39 20     LDA $2039,X     ; check for half mp cost
C2/43AD: 29 08        AND #$08
C2/43AF: F0 07        BEQ $43B8
C2/43B1: A5 12        LDA $12
C2/43B3: AA           TAX 
C2/43B4: F6 3D        INC $3D,X
C2/43B6: E6 1A        INC $1A
C2/43B8: FA           PLX 
C2/43B9: 64 10        STZ $10
C2/43BB: 64 14        STZ $14
C2/43BD: 64 0E        STZ $0E
C2/43BF: A5 14        LDA $14
C2/43C1: C9 57        CMP #$57
C2/43C3: F0 34        BEQ $43F9
C2/43C5: BD B6 2D     LDA $2DB6,X
C2/43C8: D9 20 26     CMP $2620,Y
C2/43CB: B0 18        BCS $43E5
C2/43CD: AD FE 3E     LDA $3EFE
C2/43D0: 29 04        AND #$04
C2/43D2: D0 1A        BNE $43EE
C2/43D4: 9E 3C 2F     STZ $2F3C,X
C2/43D7: A5 1A        LDA $1A
C2/43D9: F0 13        BEQ $43EE
C2/43DB: 5E 38 2E     LSR $2E38,X
C2/43DE: 90 0E        BCC $43EE
C2/43E0: FE 38 2E     INC $2E38,X
C2/43E3: 80 09        BRA $43EE
C2/43E5: A9 FF        LDA #$FF
C2/43E7: 9D 34 2D     STA $2D34,X
C2/43EA: 1A           INC 
C2/43EB: 9D 38 2E     STA $2E38,X
C2/43EE: E6 14        INC $14
C2/43F0: E8           INX 
C2/43F1: E6 0E        INC $0E
C2/43F3: A5 0E        LDA $0E
C2/43F5: C9 12        CMP #$12
C2/43F7: D0 C6        BNE $43BF
C2/43F9: C8           INY 
C2/43FA: E6 10        INC $10
C2/43FC: A5 10        LDA $10
C2/43FE: C9 05        CMP #$05
C2/4400: D0 BB        BNE $43BD
C2/4402: C2 20        REP #$20
C2/4404: 8A           TXA 
C2/4405: 18           CLC 
C2/4406: 69 33 02     ADC #$0233
C2/4409: AA           TAX 
C2/440A: 7B           TDC 
C2/440B: E2 20        SEP #$20
C2/440D: C8           INY 
C2/440E: E6 12        INC $12
C2/4410: A5 12        LDA $12
C2/4412: C9 04        CMP #$04
C2/4414: D0 86        BNE $439C
C2/4416: AD FE 3E     LDA $3EFE
C2/4419: 29 04        AND #$04
C2/441B: D0 46        BNE $4463
C2/441D: 64 0E        STZ $0E
C2/441F: A2 57 00     LDX #$0057
C2/4422: 86 12        STX $12
C2/4424: A5 0E        LDA $0E
C2/4426: AA           TAX 
C2/4427: B5 3D        LDA $3D,X
C2/4429: 85 1A        STA $1A
C2/442B: 64 10        STZ $10
C2/442D: A6 12        LDX $12
C2/442F: BD 34 2D     LDA $2D34,X
C2/4432: C9 FF        CMP #$FF
C2/4434: F0 0F        BEQ $4445
C2/4436: 9E 3C 2F     STZ $2F3C,X
C2/4439: A5 1A        LDA $1A
C2/443B: F0 08        BEQ $4445
C2/443D: 5E 38 2E     LSR $2E38,X
C2/4440: 90 03        BCC $4445
C2/4442: FE 38 2E     INC $2E38,X
C2/4445: E8           INX 
C2/4446: E6 10        INC $10
C2/4448: A5 10        LDA $10
C2/444A: C9 28        CMP #$28
C2/444C: D0 E1        BNE $442F
C2/444E: C2 20        REP #$20
C2/4450: 18           CLC 
C2/4451: A5 12        LDA $12
C2/4453: 69 8A 02     ADC #$028A
C2/4456: 85 12        STA $12
C2/4458: 7B           TDC 
C2/4459: E2 20        SEP #$20
C2/445B: E6 0E        INC $0E
C2/445D: A5 0E        LDA $0E
C2/445F: C9 04        CMP #$04
C2/4461: D0 C1        BNE $4424
C2/4463: 7B           TDC 
C2/4464: AA           TAX 
C2/4465: A8           TAY 
C2/4466: 84 0E        STY $0E
C2/4468: 84 10        STY $10
C2/446A: 64 11        STZ $11
C2/446C: A6 0E        LDX $0E
C2/446E: DA           PHX 
C2/446F: BD 16 20     LDA $2016,X     ; battle command
C2/4472: F0 2A        BEQ $449E
C2/4474: C9 50        CMP #$50
C2/4476: B0 26        BCS $449E
C2/4478: C9 1D        CMP #$1D
C2/447A: D0 0F        BNE $448B       ; branch if not catch
C2/447C: A6 0E        LDX $0E
C2/447E: BD 15 20     LDA $2015,X     ; caught monster
C2/4481: C9 FF        CMP #$FF
C2/4483: F0 04        BEQ $4489
C2/4485: A9 1E        LDA #$1E
C2/4487: 80 02        BRA $448B
C2/4489: A9 1D        LDA #$1D
C2/448B: 99 5C 37     STA $375C,Y
C2/448E: C2 20        REP #$20
C2/4490: 20 B6 01     JSR $01B6       ; a << 3
C2/4493: AA           TAX 
C2/4494: 7B           TDC 
C2/4495: E2 20        SEP #$20
C2/4497: BF E0 59 D1  LDA $D159E0,X
C2/449B: 99 68 37     STA $3768,Y
C2/449E: FA           PLX 
C2/449F: C8           INY 
C2/44A0: E8           INX 
C2/44A1: E6 11        INC $11
C2/44A3: A5 11        LDA $11
C2/44A5: C9 04        CMP #$04
C2/44A7: D0 C5        BNE $446E
C2/44A9: A6 0E        LDX $0E
C2/44AB: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/44AE: 86 0E        STX $0E
C2/44B0: 98           TYA 
C2/44B1: 18           CLC 
C2/44B2: 69 10        ADC #$10
C2/44B4: A8           TAY 
C2/44B5: E6 10        INC $10
C2/44B7: A5 10        LDA $10
C2/44B9: C9 04        CMP #$04
C2/44BB: D0 AD        BNE $446A
C2/44BD: 7B           TDC 
C2/44BE: AA           TAX 
C2/44BF: A8           TAY 
C2/44C0: 84 0E        STY $0E
C2/44C2: 84 10        STY $10
C2/44C4: 64 11        STZ $11
C2/44C6: A6 0E        LDX $0E
C2/44C8: DA           PHX 
C2/44C9: BD 13 20     LDA $2013,X
C2/44CC: D0 03        BNE $44D1
C2/44CE: BD 11 20     LDA $2011,X
C2/44D1: C9 01        CMP #$01
C2/44D3: D0 01        BNE $44D6
C2/44D5: 7B           TDC 
C2/44D6: 99 AC 37     STA $37AC,Y
C2/44D9: 48           PHA 
C2/44DA: C9 80        CMP #$80
C2/44DC: 90 1D        BCC $44FB
C2/44DE: 38           SEC 
C2/44DF: E9 80        SBC #$80
C2/44E1: C2 20        REP #$20
C2/44E3: 20 B7 01     JSR $01B7       ; a << 2
C2/44E6: 85 12        STA $12
C2/44E8: 0A           ASL 
C2/44E9: 18           CLC 
C2/44EA: 65 12        ADC $12
C2/44EC: AA           TAX 
C2/44ED: 7B           TDC 
C2/44EE: E2 20        SEP #$20
C2/44F0: A9 5A        LDA #$5A
C2/44F2: 99 B4 37     STA $37B4,Y
C2/44F5: BF 02 06 D1  LDA $D10602,X
C2/44F9: 80 32        BRA $452D
C2/44FB: C2 20        REP #$20
C2/44FD: 20 B7 01     JSR $01B7       ; a << 2
C2/4500: 85 12        STA $12
C2/4502: 0A           ASL 
C2/4503: 18           CLC 
C2/4504: 65 12        ADC $12
C2/4506: AA           TAX 
C2/4507: 7B           TDC 
C2/4508: E2 20        SEP #$20
C2/450A: BF 00 00 D1  LDA $D10000,X
C2/450E: 99 B2 37     STA $37B2,Y
C2/4511: BF 04 00 D1  LDA $D10004,X
C2/4515: 29 80        AND #$80
C2/4517: 20 BD 01     JSR $01BD       ; a >> 5
C2/451A: 99 B4 37     STA $37B4,Y
C2/451D: BF 02 00 D1  LDA $D10002,X
C2/4521: 48           PHA 
C2/4522: 29 C0        AND #$C0
C2/4524: 09 1A        ORA #$1A
C2/4526: 19 B4 37     ORA $37B4,Y
C2/4529: 99 B4 37     STA $37B4,Y
C2/452C: 68           PLA 
C2/452D: 20 5E 45     JSR $455E
C2/4530: 99 B6 37     STA $37B6,Y
C2/4533: 68           PLA 
C2/4534: F0 05        BEQ $453B
C2/4536: 7B           TDC 
C2/4537: 1A           INC 
C2/4538: 99 AE 37     STA $37AE,Y
C2/453B: FA           PLX 
C2/453C: C8           INY 
C2/453D: E8           INX 
C2/453E: E6 11        INC $11
C2/4540: A5 11        LDA $11
C2/4542: C9 02        CMP #$02
C2/4544: D0 82        BNE $44C8
C2/4546: A6 0E        LDX $0E
C2/4548: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/454B: 86 0E        STX $0E
C2/454D: 98           TYA 
C2/454E: 18           CLC 
C2/454F: 69 0A        ADC #$0A
C2/4551: A8           TAY 
C2/4552: E6 10        INC $10
C2/4554: A5 10        LDA $10
C2/4556: C9 04        CMP #$04
C2/4558: F0 03        BEQ $455D
C2/455A: 4C C4 44     JMP $44C4
C2/455D: 60           RTS 

; [  ]

C2/455E: 5A           PHY 
C2/455F: 29 3F        AND #$3F
C2/4561: 20 B7 01     JSR $01B7       ; a << 2
C2/4564: AA           TAX 
C2/4565: 7B           TDC 
C2/4566: A8           TAY 
C2/4567: BF 80 24 D1  LDA $D12480,X   ; item equipment types
C2/456B: 99 20 27     STA $2720,Y
C2/456E: E8           INX 
C2/456F: C8           INY 
C2/4570: C0 04 00     CPY #$0004
C2/4573: D0 F2        BNE $4567
C2/4575: 7B           TDC 
C2/4576: AA           TAX 
C2/4577: A8           TAY 
C2/4578: A9 AA        LDA #$AA
C2/457A: 85 14        STA $14
C2/457C: BD 99 41     LDA $4199,X
C2/457F: 39 20 27     AND $2720,Y
C2/4582: D0 18        BNE $459C
C2/4584: BD 9A 41     LDA $419A,X
C2/4587: 39 21 27     AND $2721,Y
C2/458A: D0 10        BNE $459C
C2/458C: BD 9B 41     LDA $419B,X
C2/458F: 39 22 27     AND $2722,Y
C2/4592: D0 08        BNE $459C
C2/4594: BD 9C 41     LDA $419C,X
C2/4597: 39 23 27     AND $2723,Y
C2/459A: F0 2C        BEQ $45C8
C2/459C: 8A           TXA 
C2/459D: 20 C0 01     JSR $01C0       ; a >> 2
C2/45A0: D0 08        BNE $45AA
C2/45A2: A5 14        LDA $14
C2/45A4: 29 7F        AND #$7F
C2/45A6: 85 14        STA $14
C2/45A8: 80 1E        BRA $45C8
C2/45AA: C9 01        CMP #$01
C2/45AC: D0 08        BNE $45B6
C2/45AE: A5 14        LDA $14
C2/45B0: 29 DF        AND #$DF
C2/45B2: 85 14        STA $14
C2/45B4: 80 12        BRA $45C8
C2/45B6: C9 02        CMP #$02
C2/45B8: D0 08        BNE $45C2
C2/45BA: A5 14        LDA $14
C2/45BC: 29 F7        AND #$F7
C2/45BE: 85 14        STA $14
C2/45C0: 80 06        BRA $45C8
C2/45C2: A5 14        LDA $14
C2/45C4: 29 FD        AND #$FD
C2/45C6: 85 14        STA $14
C2/45C8: E8           INX 
C2/45C9: E8           INX 
C2/45CA: E8           INX 
C2/45CB: E8           INX 
C2/45CC: E0 10 00     CPX #$0010
C2/45CF: D0 AB        BNE $457C
C2/45D1: A5 14        LDA $14
C2/45D3: 7A           PLY 
C2/45D4: 60           RTS 

; [ init character poison status ]

; start the poison counter for characters entering battle with poison status

C2/45D5: 7B           TDC 
C2/45D6: AA           TAX 
C2/45D7: 86 22        STX $22
C2/45D9: 8E 20 26     STX $2620
C2/45DC: A6 22        LDX $22
C2/45DE: BD 1A 20     LDA $201A,X
C2/45E1: 1D 70 20     ORA $2070,X
C2/45E4: 29 04        AND #$04
C2/45E6: F0 05        BEQ $45ED
C2/45E8: A9 01        LDA #$01
C2/45EA: 20 A3 41     JSR $41A3
C2/45ED: A6 22        LDX $22
C2/45EF: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/45F2: 86 22        STX $22
C2/45F4: EE 20 26     INC $2620
C2/45F7: AD 20 26     LDA $2620
C2/45FA: C9 04        CMP #$04
C2/45FC: D0 DE        BNE $45DC
C2/45FE: 60           RTS 

; [ battle command $05: fight ]

C2/45FF: A6 32        LDX $32
C2/4601: BD 58 20     LDA $2058,X
C2/4604: 85 65        STA $65
C2/4606: BD 59 20     LDA $2059,X
C2/4609: 85 66        STA $66
C2/460B: 20 FE 4A     JSR $4AFE
C2/460E: A6 32        LDX $32
C2/4610: A5 66        LDA $66
C2/4612: 9D 59 20     STA $2059,X
C2/4615: A5 65        LDA $65
C2/4617: 9D 58 20     STA $2058,X
C2/461A: 48           PHA 
C2/461B: 29 F0        AND #$F0
C2/461D: 4A           LSR 
C2/461E: 4A           LSR 
C2/461F: 4A           LSR 
C2/4620: 4A           LSR 
C2/4621: 1D 59 20     ORA $2059,X
C2/4624: 8D 20 27     STA $2720
C2/4627: 68           PLA 
C2/4628: 29 0F        AND #$0F
C2/462A: 0A           ASL 
C2/462B: 0A           ASL 
C2/462C: 0A           ASL 
C2/462D: 0A           ASL 
C2/462E: 8D 21 27     STA $2721
C2/4631: A5 47        LDA $47
C2/4633: AA           TAX 
C2/4634: BF 85 ED D0  LDA $D0ED85,X
C2/4638: AA           TAX 
C2/4639: 86 0E        STX $0E
C2/463B: A6 32        LDX $32
C2/463D: BD 13 20     LDA $2013,X
C2/4640: D0 03        BNE $4645
C2/4642: 4C 79 47     JMP $4779
C2/4645: A6 0E        LDX $0E
C2/4647: BD 8A 40     LDA $408A,X
C2/464A: 85 10        STA $10
C2/464C: 29 02        AND #$02
C2/464E: F0 25        BEQ $4675
C2/4650: AD 4E 47     LDA $474E
C2/4653: D0 20        BNE $4675
C2/4655: A6 32        LDX $32
C2/4657: BD 1A 20     LDA $201A,X
C2/465A: 29 02        AND #$02
C2/465C: D0 17        BNE $4675
C2/465E: BD 1B 20     LDA $201B,X
C2/4661: 29 10        AND #$10
C2/4663: D0 10        BNE $4675
C2/4665: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/4668: A6 0E        LDX $0E
C2/466A: DD 8F 40     CMP $408F,X
C2/466D: B0 06        BCS $4675
C2/466F: BD 90 40     LDA $4090,X
C2/4672: 4C D5 49     JMP $49D5
C2/4675: 20 23 99     JSR $9923
C2/4678: 84 14        STY $14
C2/467A: 64 12        STZ $12
C2/467C: A6 0E        LDX $0E
C2/467E: BD 85 40     LDA $4085,X
C2/4681: 99 FC 79     STA $79FC,Y
C2/4684: E8           INX 
C2/4685: C8           INY 
C2/4686: E6 12        INC $12
C2/4688: A5 12        LDA $12
C2/468A: C9 0C        CMP #$0C
C2/468C: D0 F0        BNE $467E
C2/468E: A6 0E        LDX $0E
C2/4690: BD 8A 40     LDA $408A,X
C2/4693: 29 04        AND #$04
C2/4695: D0 03        BNE $469A
C2/4697: 7B           TDC 
C2/4698: 80 07        BRA $46A1
C2/469A: A6 32        LDX $32
C2/469C: BD 7A 20     LDA $207A,X
C2/469F: 29 7F        AND #$7F
C2/46A1: 48           PHA 
C2/46A2: 20 FA 98     JSR $98FA       ; create graphics command
C2/46A5: 9E 4C 38     STZ $384C,X
C2/46A8: A9 FC        LDA #$FC
C2/46AA: 9D 4D 38     STA $384D,X
C2/46AD: A9 01        LDA #$01
C2/46AF: 9D 4E 38     STA $384E,X
C2/46B2: A9 04        LDA #$04
C2/46B4: 9D 4F 38     STA $384F,X
C2/46B7: 68           PLA 
C2/46B8: 9D 50 38     STA $3850,X
C2/46BB: A6 0E        LDX $0E
C2/46BD: BD 8D 40     LDA $408D,X
C2/46C0: 48           PHA 
C2/46C1: AD FA 79     LDA $79FA
C2/46C4: AA           TAX 
C2/46C5: 68           PLA 
C2/46C6: 9D 2D 7B     STA $7B2D,X
C2/46C9: 9E 1C 7B     STZ $7B1C,X
C2/46CC: 9E CC 7A     STZ $7ACC,X
C2/46CF: AD FA 79     LDA $79FA
C2/46D2: 0A           ASL 
C2/46D3: AA           TAX 
C2/46D4: AD 20 27     LDA $2720
C2/46D7: 9D DC 7A     STA $7ADC,X
C2/46DA: AD 21 27     LDA $2721
C2/46DD: 9D DD 7A     STA $7ADD,X
C2/46E0: EE FA 79     INC $79FA
C2/46E3: 20 E3 98     JSR $98E3
C2/46E6: A5 10        LDA $10
C2/46E8: 29 01        AND #$01
C2/46EA: F0 1B        BEQ $4707
C2/46EC: 18           CLC 
C2/46ED: AD 76 7C     LDA $7C76
C2/46F0: 69 12        ADC #$12
C2/46F2: 85 10        STA $10
C2/46F4: 18           CLC 
C2/46F5: AD 76 7C     LDA $7C76
C2/46F8: D0 01        BNE $46FB
C2/46FA: 1A           INC 
C2/46FB: 69 01        ADC #$01
C2/46FD: C9 24        CMP #$24
C2/46FF: D0 01        BNE $4702
C2/4701: 7B           TDC 
C2/4702: 8D 76 7C     STA $7C76
C2/4705: 80 15        BRA $471C
C2/4707: A5 10        LDA $10
C2/4709: 29 08        AND #$08
C2/470B: F0 6C        BEQ $4779
C2/470D: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/4710: A6 0E        LDX $0E
C2/4712: DD 8F 40     CMP $408F,X
C2/4715: B0 62        BCS $4779
C2/4717: BD 90 40     LDA $4090,X
C2/471A: 85 10        STA $10
C2/471C: A4 14        LDY $14
C2/471E: 98           TYA 
C2/471F: 18           CLC 
C2/4720: 69 0C        ADC #$0C
C2/4722: A8           TAY 
C2/4723: 84 14        STY $14
C2/4725: A5 10        LDA $10
C2/4727: 48           PHA 
C2/4728: 20 24 03     JSR $0324
C2/472B: AD FA 79     LDA $79FA
C2/472E: AA           TAX 
C2/472F: A4 14        LDY $14
C2/4731: B9 00 7A     LDA $7A00,Y
C2/4734: 29 7F        AND #$7F
C2/4736: 9D 2D 7B     STA $7B2D,X
C2/4739: 20 FA 98     JSR $98FA       ; create graphics command
C2/473C: 68           PLA 
C2/473D: 9D 4F 38     STA $384F,X
C2/4740: 9E 4C 38     STZ $384C,X
C2/4743: 9E 50 38     STZ $3850,X
C2/4746: A9 FC        LDA #$FC
C2/4748: 9D 4D 38     STA $384D,X
C2/474B: A9 07        LDA #$07
C2/474D: 9D 4E 38     STA $384E,X
C2/4750: AD FA 79     LDA $79FA
C2/4753: AA           TAX 
C2/4754: 9E 1C 7B     STZ $7B1C,X
C2/4757: A9 10        LDA #$10
C2/4759: 9D CC 7A     STA $7ACC,X
C2/475C: AD FA 79     LDA $79FA
C2/475F: 0A           ASL 
C2/4760: AA           TAX 
C2/4761: AD 20 27     LDA $2720
C2/4764: 9D DC 7A     STA $7ADC,X
C2/4767: 9D FC 7A     STA $7AFC,X
C2/476A: AD 21 27     LDA $2721
C2/476D: 9D DD 7A     STA $7ADD,X
C2/4770: 9D FD 7A     STA $7AFD,X
C2/4773: EE FA 79     INC $79FA
C2/4776: 20 E3 98     JSR $98E3
C2/4779: A6 32        LDX $32
C2/477B: BD 14 20     LDA $2014,X
C2/477E: D0 01        BNE $4781
C2/4780: 60           RTS 
C2/4781: A6 0E        LDX $0E
C2/4783: BD 96 40     LDA $4096,X
C2/4786: 85 10        STA $10
C2/4788: 29 02        AND #$02
C2/478A: F0 25        BEQ $47B1
C2/478C: AD 4E 47     LDA $474E
C2/478F: D0 20        BNE $47B1
C2/4791: A6 32        LDX $32
C2/4793: BD 1A 20     LDA $201A,X
C2/4796: 29 02        AND #$02
C2/4798: D0 17        BNE $47B1
C2/479A: BD 1B 20     LDA $201B,X
C2/479D: 29 10        AND #$10
C2/479F: D0 10        BNE $47B1
C2/47A1: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/47A4: A6 0E        LDX $0E
C2/47A6: DD 9B 40     CMP $409B,X
C2/47A9: B0 06        BCS $47B1
C2/47AB: BD 9C 40     LDA $409C,X
C2/47AE: 4C D5 49     JMP $49D5
C2/47B1: 20 23 99     JSR $9923
C2/47B4: 84 12        STY $12
C2/47B6: 64 14        STZ $14
C2/47B8: A6 0E        LDX $0E
C2/47BA: BD 91 40     LDA $4091,X
C2/47BD: 99 FC 79     STA $79FC,Y
C2/47C0: E8           INX 
C2/47C1: C8           INY 
C2/47C2: E6 14        INC $14
C2/47C4: A5 14        LDA $14
C2/47C6: C9 0C        CMP #$0C
C2/47C8: D0 F0        BNE $47BA
C2/47CA: A6 0E        LDX $0E
C2/47CC: AD FA 79     LDA $79FA
C2/47CF: A8           TAY 
C2/47D0: BD 99 40     LDA $4099,X
C2/47D3: 99 2D 7B     STA $7B2D,Y
C2/47D6: 20 FA 98     JSR $98FA       ; create graphics command
C2/47D9: 9E 4C 38     STZ $384C,X
C2/47DC: A9 FC        LDA #$FC
C2/47DE: 9D 4D 38     STA $384D,X
C2/47E1: A9 01        LDA #$01
C2/47E3: 9D 4E 38     STA $384E,X
C2/47E6: A9 04        LDA #$04
C2/47E8: 9D 4F 38     STA $384F,X
C2/47EB: 86 08        STX $08
C2/47ED: A6 0E        LDX $0E
C2/47EF: BD 96 40     LDA $4096,X
C2/47F2: 29 04        AND #$04
C2/47F4: D0 04        BNE $47FA
C2/47F6: A9 80        LDA #$80
C2/47F8: 80 07        BRA $4801
C2/47FA: A6 32        LDX $32
C2/47FC: BD 7A 20     LDA $207A,X
C2/47FF: 09 80        ORA #$80
C2/4801: A6 08        LDX $08
C2/4803: 9D 50 38     STA $3850,X
C2/4806: AD FA 79     LDA $79FA
C2/4809: AA           TAX 
C2/480A: 9E 1C 7B     STZ $7B1C,X
C2/480D: 9E CC 7A     STZ $7ACC,X
C2/4810: AD FA 79     LDA $79FA
C2/4813: 0A           ASL 
C2/4814: AA           TAX 
C2/4815: AD 20 27     LDA $2720
C2/4818: 9D DC 7A     STA $7ADC,X
C2/481B: AD 21 27     LDA $2721
C2/481E: 9D DD 7A     STA $7ADD,X
C2/4821: EE FA 79     INC $79FA
C2/4824: 20 E3 98     JSR $98E3
C2/4827: A5 10        LDA $10
C2/4829: 29 01        AND #$01
C2/482B: F0 1B        BEQ $4848
C2/482D: 18           CLC 
C2/482E: AD 76 7C     LDA $7C76
C2/4831: 69 12        ADC #$12
C2/4833: 85 10        STA $10
C2/4835: 18           CLC 
C2/4836: AD 76 7C     LDA $7C76
C2/4839: D0 01        BNE $483C
C2/483B: 1A           INC 
C2/483C: 69 01        ADC #$01
C2/483E: C9 24        CMP #$24
C2/4840: D0 01        BNE $4843
C2/4842: 7B           TDC 
C2/4843: 8D 76 7C     STA $7C76
C2/4846: 80 15        BRA $485D
C2/4848: A5 10        LDA $10
C2/484A: 29 08        AND #$08
C2/484C: F0 6E        BEQ $48BC
C2/484E: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/4851: A6 0E        LDX $0E
C2/4853: DD 9B 40     CMP $409B,X
C2/4856: B0 64        BCS $48BC
C2/4858: BD 9C 40     LDA $409C,X
C2/485B: 85 10        STA $10
C2/485D: A4 12        LDY $12
C2/485F: 98           TYA 
C2/4860: 18           CLC 
C2/4861: 69 0C        ADC #$0C
C2/4863: A8           TAY 
C2/4864: 84 12        STY $12
C2/4866: A6 0E        LDX $0E
C2/4868: A5 10        LDA $10
C2/486A: 48           PHA 
C2/486B: 20 24 03     JSR $0324
C2/486E: A4 12        LDY $12
C2/4870: AD FA 79     LDA $79FA
C2/4873: AA           TAX 
C2/4874: B9 00 7A     LDA $7A00,Y
C2/4877: 29 7F        AND #$7F
C2/4879: 9D 2D 7B     STA $7B2D,X
C2/487C: 20 FA 98     JSR $98FA       ; create graphics command
C2/487F: 9E 4C 38     STZ $384C,X
C2/4882: 9E 50 38     STZ $3850,X
C2/4885: A9 FC        LDA #$FC
C2/4887: 9D 4D 38     STA $384D,X
C2/488A: A9 07        LDA #$07
C2/488C: 9D 4E 38     STA $384E,X
C2/488F: 68           PLA 
C2/4890: 9D 4F 38     STA $384F,X
C2/4893: AD FA 79     LDA $79FA
C2/4896: AA           TAX 
C2/4897: 9E 1C 7B     STZ $7B1C,X
C2/489A: A9 10        LDA #$10
C2/489C: 9D CC 7A     STA $7ACC,X
C2/489F: AD FA 79     LDA $79FA
C2/48A2: 0A           ASL 
C2/48A3: AA           TAX 
C2/48A4: AD 20 27     LDA $2720
C2/48A7: 9D DC 7A     STA $7ADC,X
C2/48AA: 9D FC 7A     STA $7AFC,X
C2/48AD: AD 21 27     LDA $2721
C2/48B0: 9D DD 7A     STA $7ADD,X
C2/48B3: 9D FD 7A     STA $7AFD,X
C2/48B6: EE FA 79     INC $79FA
C2/48B9: 20 E3 98     JSR $98E3
C2/48BC: 60           RTS 

; [  ]

C2/48BD: A5 47        LDA $47
C2/48BF: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/48C2: A6 32        LDX $32
C2/48C4: BD 06 20     LDA $2006,X
C2/48C7: 8D 64 7C     STA $7C64
C2/48CA: BD 07 20     LDA $2007,X
C2/48CD: 8D 65 7C     STA $7C65
C2/48D0: AE 64 7C     LDX $7C64
C2/48D3: E0 0F 27     CPX #$270F
C2/48D6: 90 06        BCC $48DE
C2/48D8: A2 0F 27     LDX #$270F
C2/48DB: 8E 64 7C     STX $7C64
C2/48DE: A6 32        LDX $32
C2/48E0: 20 48 02     JSR $0248       ; get attacker stats and level
C2/48E3: 20 18 02     JSR $0218       ; reset battle graphics parameters
C2/48E6: 20 8A 02     JSR $028A
C2/48E9: 20 68 49     JSR $4968
C2/48EC: 20 27 94     JSR $9427
C2/48EF: 20 10 4C     JSR $4C10       ; check learned blue magic
C2/48F2: AD 4F 7C     LDA $7C4F
C2/48F5: F0 03        BEQ $48FA
C2/48F7: 20 2F 4A     JSR $4A2F
C2/48FA: AD 9B 7C     LDA $7C9B
C2/48FD: F0 03        BEQ $4902
C2/48FF: 20 23 49     JSR $4923
C2/4902: A9 0A        LDA #$0A
C2/4904: 20 69 00     JSR $0069       ; execute battle graphics function
C2/4907: AD EF 3E     LDA $3EEF
C2/490A: 10 0B        BPL $4917
C2/490C: A5 47        LDA $47
C2/490E: C9 04        CMP #$04
C2/4910: B0 05        BCS $4917
C2/4912: A9 20        LDA #$20
C2/4914: 8D DE 7B     STA $7BDE
C2/4917: A9 FF        LDA #$FF
C2/4919: 8D 4B 7C     STA $7C4B
C2/491C: EE 54 47     INC $4754
C2/491F: 9C 56 47     STZ $4756
C2/4922: 60           RTS 

; [  ]

C2/4923: AD 9B 7C     LDA $7C9B
C2/4926: 10 31        BPL $4959
C2/4928: AD CF 3B     LDA $3BCF
C2/492B: 0D D6 3B     ORA $3BD6
C2/492E: F0 06        BEQ $4936
C2/4930: AD CE 3B     LDA $3BCE
C2/4933: 8D CF 3B     STA $3BCF
C2/4936: 7B           TDC 
C2/4937: AA           TAX 
C2/4938: BD DA 3B     LDA $3BDA,X
C2/493B: 9D D3 3B     STA $3BD3,X
C2/493E: E8           INX 
C2/493F: E0 23 00     CPX #$0023
C2/4942: D0 F4        BNE $4938
C2/4944: AD 9B 7C     LDA $7C9B
C2/4947: 29 40        AND #$40
C2/4949: F0 1C        BEQ $4967
C2/494B: AD D6 3B     LDA $3BD6
C2/494E: 0D DD 3B     ORA $3BDD
C2/4951: F0 06        BEQ $4959
C2/4953: AD D5 3B     LDA $3BD5
C2/4956: 8D D6 3B     STA $3BD6
C2/4959: 7B           TDC 
C2/495A: AA           TAX 
C2/495B: BD E1 3B     LDA $3BE1,X
C2/495E: 9D DA 3B     STA $3BDA,X
C2/4961: E8           INX 
C2/4962: E0 23 00     CPX #$0023
C2/4965: D0 F4        BNE $495B
C2/4967: 60           RTS 

; [ execute battle command ]

C2/4968: A6 32        LDX $32
C2/496A: BD 1A 20     LDA $201A,X
C2/496D: 29 02        AND #$02
C2/496F: D0 07        BNE $4978       ; branch if zombie
C2/4971: BD 1B 20     LDA $201B,X
C2/4974: 29 18        AND #$18
C2/4976: F0 12        BEQ $498A       ; branch if charmed or berserk
C2/4978: BD 61 20     LDA $2061,X
C2/497B: D0 0D        BNE $498A       ; 
C2/497D: A9 01        LDA #$01
C2/497F: 9D 61 20     STA $2061,X
C2/4982: 9E 57 20     STZ $2057,X
C2/4985: A9 80        LDA #$80
C2/4987: 9D 56 20     STA $2056,X
C2/498A: BD 1B 20     LDA $201B,X
C2/498D: 29 40        AND #$40
C2/498F: F0 08        BEQ $4999
C2/4991: 9E 57 20     STZ $2057,X
C2/4994: A9 80        LDA #$80
C2/4996: 9D 56 20     STA $2056,X
C2/4999: E0 00 02     CPX #$0200
C2/499C: B0 32        BCS $49D0       ; branch if a monster
C2/499E: BD 57 20     LDA $2057,X     ; battle command id
C2/49A1: F0 2D        BEQ $49D0
C2/49A3: C9 25        CMP #$25
C2/49A5: F0 29        BEQ $49D0       ; branch if hide
C2/49A7: C9 26        CMP #$26
C2/49A9: F0 25        BEQ $49D0       ; branch if show
C2/49AB: C9 2B        CMP #$2B
C2/49AD: F0 21        BEQ $49D0       ; branch if mimic
C2/49AF: C9 4E        CMP #$4E
C2/49B1: B0 1D        BCS $49D0       ; branch if ???
C2/49B3: BD 1A 20     LDA $201A,X
C2/49B6: 29 02        AND #$02
C2/49B8: D0 16        BNE $49D0       ; branch if zombie
C2/49BA: BD 1B 20     LDA $201B,X
C2/49BD: 29 18        AND #$18
C2/49BF: D0 0F        BNE $49D0       ; branch if charmed or berserk
C2/49C1: 7B           TDC 
C2/49C2: A8           TAY 
C2/49C3: BD 56 20     LDA $2056,X
C2/49C6: 99 D4 41     STA $41D4,Y
C2/49C9: E8           INX 
C2/49CA: C8           INY 
C2/49CB: C0 0A 00     CPY #$000A
C2/49CE: D0 F3        BNE $49C3
C2/49D0: A6 32        LDX $32         ; attacker
C2/49D2: BD 57 20     LDA $2057,X     ; selected battle command ???
C2/49D5: 48           PHA 
C2/49D6: C2 20        REP #$20
C2/49D8: 20 B6 01     JSR $01B6       ; a << 3
C2/49DB: AA           TAX 
C2/49DC: BF E2 59 D1  LDA $D159E2,X   ; battle command properties, byte 2
C2/49E0: A6 32        LDX $32
C2/49E2: 9D 1E 20     STA $201E,X     ; action flags
C2/49E5: 7B           TDC 
C2/49E6: E2 20        SEP #$20
C2/49E8: 68           PLA 
C2/49E9: AA           TAX 
C2/49EA: BF 02 ED D0  LDA $D0ED02,X   ; long -> short command id conversion
C2/49EE: 8D 4D 47     STA $474D
C2/49F1: 0A           ASL 
C2/49F2: AA           TAX 
C2/49F3: BF 94 4A C2  LDA $C24A94,X   ; battle command jump table
C2/49F7: 85 08        STA $08
C2/49F9: BF 95 4A C2  LDA $C24A95,X
C2/49FD: 85 09        STA $09
C2/49FF: A9 C2        LDA #$C2
C2/4A01: 85 0A        STA $0A
C2/4A03: 9C FB 7B     STZ $7BFB
C2/4A06: 9C FC 7B     STZ $7BFC
C2/4A09: 9C 03 7C     STZ $7C03
C2/4A0C: 9C 08 7C     STZ $7C08
C2/4A0F: 9C EF 3C     STZ $3CEF
C2/4A12: 9C F0 3C     STZ $3CF0
C2/4A15: 9C 4F 7C     STZ $7C4F
C2/4A18: 9C 9B 7C     STZ $7C9B
C2/4A1B: 9C 9D 7C     STZ $7C9D
C2/4A1E: 9C 9C 7C     STZ $7C9C
C2/4A21: 7B           TDC 
C2/4A22: AA           TAX 
C2/4A23: 9E EB 7B     STZ $7BEB,X
C2/4A26: E8           INX 
C2/4A27: E0 10 00     CPX #$0010
C2/4A2A: D0 F7        BNE $4A23
C2/4A2C: DC 08 00     JML [$0008]

; [  ]

C2/4A2F: A5 47        LDA $47
C2/4A31: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/4A34: A6 32        LDX $32
C2/4A36: AD 00 26     LDA $2600
C2/4A39: 9D 02 20     STA $2002,X
C2/4A3C: AD 01 26     LDA $2601
C2/4A3F: 9D 44 20     STA $2044,X
C2/4A42: AD 02 26     LDA $2602
C2/4A45: 9D 62 20     STA $2062,X
C2/4A48: AD 03 26     LDA $2603
C2/4A4B: 9D 2B 20     STA $202B,X
C2/4A4E: AD 04 26     LDA $2604
C2/4A51: 9D 00 20     STA $2000,X
C2/4A54: BD 1A 20     LDA $201A,X
C2/4A57: 0D 05 26     ORA $2605
C2/4A5A: 29 7F        AND #$7F
C2/4A5C: 9D 1A 20     STA $201A,X
C2/4A5F: 7B           TDC 
C2/4A60: A8           TAY 
C2/4A61: BD 1A 20     LDA $201A,X
C2/4A64: 19 05 26     ORA $2605,Y
C2/4A67: 9D 1A 20     STA $201A,X
C2/4A6A: E8           INX 
C2/4A6B: C8           INY 
C2/4A6C: C0 09 00     CPY #$0009
C2/4A6F: D0 F0        BNE $4A61
C2/4A71: 7B           TDC 
C2/4A72: A8           TAY 
C2/4A73: A6 32        LDX $32
C2/4A75: B9 0E 26     LDA $260E,Y
C2/4A78: 9D 50 20     STA $2050,X
C2/4A7B: E8           INX 
C2/4A7C: C8           INY 
C2/4A7D: C0 06 00     CPY #$0006
C2/4A80: D0 F3        BNE $4A75
C2/4A82: 7B           TDC 
C2/4A83: A8           TAY 
C2/4A84: A6 32        LDX $32
C2/4A86: B9 14 26     LDA $2614,Y     ; copy from buffer
C2/4A89: 9D 70 20     STA $2070,X
C2/4A8C: E8           INX 
C2/4A8D: C8           INY 
C2/4A8E: C0 0B 00     CPY #$000B
C2/4A91: D0 F3        BNE $4A86
C2/4A93: 60           RTS 

; battle command jump table (uses D0/ED02 for index)
C2/4A94:              .DW $0511, $0570, $0791, $07A4, $45FF, $07A9, $07AE, $07CF
C2/4AA4:              .DW $090B, $0933, $094E, $096F, $0990, $0AA4, $0ADC, $0AFA
C2/4AB4:              .DW $0B0F, $0B6F, $0B7A, $0B9B, $0BBF, $0C67, $0C6F, $0DE4
C2/4AC4:              .DW $0DA2, $0DC3, $0EE0, $0EFE, $0F1F, $0F40, $1125, $0570
C2/4AD4:              .DW $1169, $118A, $11B2, $0511, $125E, $12B3, $5B9F, $5B9F
C2/4AE4:              .DW $1306, $1333, $13CE, $5B9F, $0814, $09DD, $0A7D, $13EF
C2/4AF4:              .DW $141D, $1425, $1490, $14B8, $16A2

; [ validate targets ]

C2/4AFE: A6 32        LDX $32         ; attacker pointer
C2/4B00: DA           PHX 
C2/4B01: 64 0E        STZ $0E
C2/4B03: A5 65        LDA $65         ; cursor target ???
C2/4B05: F0 0B        BEQ $4B12
C2/4B07: E6 0E        INC $0E
C2/4B09: 20 C3 01     JSR $01C3       ; count set bits
C2/4B0C: CA           DEX 
C2/4B0D: F0 13        BEQ $4B22
C2/4B0F: 4C D3 4B     JMP $4BD3
C2/4B12: A5 66        LDA $66
C2/4B14: D0 03        BNE $4B19
C2/4B16: 4C D3 4B     JMP $4BD3
C2/4B19: 20 C3 01     JSR $01C3       ; count set bits
C2/4B1C: CA           DEX 
C2/4B1D: F0 03        BEQ $4B22
C2/4B1F: 4C D3 4B     JMP $4BD3
C2/4B22: A5 65        LDA $65
C2/4B24: 48           PHA 
C2/4B25: 29 F0        AND #$F0
C2/4B27: 20 BE 01     JSR $01BE       ; a >> 4
C2/4B2A: 05 66        ORA $66
C2/4B2C: 85 10        STA $10
C2/4B2E: 68           PLA 
C2/4B2F: 20 B5 01     JSR $01B5       ; a << 4
C2/4B32: 85 11        STA $11
C2/4B34: 7B           TDC 
C2/4B35: AA           TAX 
C2/4B36: 06 11        ASL $11
C2/4B38: 26 10        ROL $10
C2/4B3A: B0 03        BCS $4B3F
C2/4B3C: E8           INX 
C2/4B3D: 80 F7        BRA $4B36
C2/4B3F: BD C2 3E     LDA $3EC2,X     ; target index
C2/4B42: F0 19        BEQ $4B5D
C2/4B44: 8A           TXA 
C2/4B45: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/4B48: BD 1A 20     LDA $201A,X
C2/4B4B: 29 C0        AND #$C0
C2/4B4D: D0 0E        BNE $4B5D       ; branch if wounded or stone
C2/4B4F: BD 1D 20     LDA $201D,X
C2/4B52: 29 81        AND #$81
C2/4B54: D0 07        BNE $4B5D       ; branch if erased or hidden
C2/4B56: BD 1E 20     LDA $201E,X
C2/4B59: 29 10        AND #$10
C2/4B5B: F0 76        BEQ $4BD3       ; branch if not jumping
C2/4B5D: A5 0E        LDA $0E
C2/4B5F: D0 14        BNE $4B75
C2/4B61: 64 12        STZ $12         ; check character targets (0-3)
C2/4B63: A9 04        LDA #$04
C2/4B65: 85 13        STA $13
C2/4B67: 20 D7 4B     JSR $4BD7
C2/4B6A: D0 67        BNE $4BD3
C2/4B6C: 7B           TDC 
C2/4B6D: AA           TAX 
C2/4B6E: A9 03        LDA #$03
C2/4B70: 20 7C 00     JSR $007C       ; a = (x..a)
C2/4B73: 80 21        BRA $4B96
C2/4B75: A9 04        LDA #$04        ; check monster targets (4-11)
C2/4B77: 85 12        STA $12
C2/4B79: A9 0C        LDA #$0C
C2/4B7B: 85 13        STA $13
C2/4B7D: 20 D7 4B     JSR $4BD7
C2/4B80: D0 51        BNE $4BD3
C2/4B82: AD 4C 7C     LDA $7C4C
C2/4B85: F0 07        BEQ $4B8E
C2/4B87: A2 04 00     LDX #$0004
C2/4B8A: A9 06        LDA #$06
C2/4B8C: 80 05        BRA $4B93
C2/4B8E: A2 04 00     LDX #$0004
C2/4B91: A9 0B        LDA #$0B
C2/4B93: 20 7C 00     JSR $007C       ; a = (x..a)
C2/4B96: 85 10        STA $10
C2/4B98: AA           TAX 
C2/4B99: BD C2 3E     LDA $3EC2,X
C2/4B9C: F0 BF        BEQ $4B5D
C2/4B9E: A5 10        LDA $10
C2/4BA0: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/4BA3: BD 1A 20     LDA $201A,X
C2/4BA6: 29 C0        AND #$C0
C2/4BA8: D0 B3        BNE $4B5D
C2/4BAA: BD 1D 20     LDA $201D,X
C2/4BAD: 29 81        AND #$81
C2/4BAF: D0 AC        BNE $4B5D
C2/4BB1: BD 1E 20     LDA $201E,X
C2/4BB4: 29 10        AND #$10
C2/4BB6: D0 A5        BNE $4B5D
C2/4BB8: A5 0E        LDA $0E
C2/4BBA: D0 0B        BNE $4BC7
C2/4BBC: A5 10        LDA $10
C2/4BBE: AA           TAX 
C2/4BBF: 7B           TDC 
C2/4BC0: 20 D6 01     JSR $01D6       ; set bit x
C2/4BC3: 85 66        STA $66
C2/4BC5: 80 0C        BRA $4BD3
C2/4BC7: 38           SEC 
C2/4BC8: A5 10        LDA $10
C2/4BCA: E9 04        SBC #$04
C2/4BCC: AA           TAX 
C2/4BCD: 7B           TDC 
C2/4BCE: 20 D6 01     JSR $01D6       ; set bit x
C2/4BD1: 85 65        STA $65
C2/4BD3: FA           PLX 
C2/4BD4: 86 32        STX $32
C2/4BD6: 60           RTS 

; [  ]

C2/4BD7: A5 12        LDA $12
C2/4BD9: A8           TAY 
C2/4BDA: B9 C2 3E     LDA $3EC2,Y
C2/4BDD: F0 23        BEQ $4C02
C2/4BDF: A5 12        LDA $12
C2/4BE1: C2 20        REP #$20
C2/4BE3: 20 B2 01     JSR $01B2       ; a << 7
C2/4BE6: AA           TAX 
C2/4BE7: 7B           TDC 
C2/4BE8: E2 20        SEP #$20
C2/4BEA: BD 1A 20     LDA $201A,X
C2/4BED: 29 C0        AND #$C0
C2/4BEF: D0 11        BNE $4C02       ; branch if wounded or stone
C2/4BF1: BD 1D 20     LDA $201D,X
C2/4BF4: 29 81        AND #$81
C2/4BF6: D0 0A        BNE $4C02       ; branch if erased or hidden
C2/4BF8: BD 1E 20     LDA $201E,X
C2/4BFB: 29 10        AND #$10
C2/4BFD: D0 03        BNE $4C02       ; branch if jumping
C2/4BFF: 7B           TDC 
C2/4C00: 80 0A        BRA $4C0C
C2/4C02: E6 12        INC $12
C2/4C04: A5 12        LDA $12
C2/4C06: C5 13        CMP $13
C2/4C08: D0 CD        BNE $4BD7
C2/4C0A: A9 01        LDA #$01
C2/4C0C: 8D 29 7C     STA $7C29
C2/4C0F: 60           RTS 

; [ check learned blue magic ]

C2/4C10: A5 47        LDA $47         ; attacker
C2/4C12: C9 04        CMP #$04
C2/4C14: B0 01        BCS $4C17       ; return if not a monster
C2/4C16: 60           RTS 
C2/4C17: 38           SEC 
C2/4C18: E9 04        SBC #$04
C2/4C1A: 20 B5 01     JSR $01B5       ; a << 4
C2/4C1D: C2 20        REP #$20
C2/4C1F: 18           CLC 
C2/4C20: 69 DE 41     ADC #$41DE
C2/4C23: 85 3D        STA $3D
C2/4C25: 7B           TDC 
C2/4C26: E2 20        SEP #$20
C2/4C28: 7B           TDC 
C2/4C29: A8           TAY 
C2/4C2A: 84 3F        STY $3F
C2/4C2C: A4 3F        LDY $3F
C2/4C2E: B1 3D        LDA ($3D),Y
C2/4C30: 85 08        STA $08
C2/4C32: F0 0F        BEQ $4C43
C2/4C34: C9 FF        CMP #$FF
C2/4C36: F0 0B        BEQ $4C43
C2/4C38: C9 82        CMP #$82
C2/4C3A: 90 04        BCC $4C40
C2/4C3C: C9 A0        CMP #$A0
C2/4C3E: 90 04        BCC $4C44
C2/4C40: 4C DA 4C     JMP $4CDA
C2/4C43: 60           RTS 
C2/4C44: 64 0E        STZ $0E
C2/4C46: A5 3F        LDA $3F
C2/4C48: AA           TAX 
C2/4C49: BF 85 EE D0  LDA $D0EE85,X   ; pointer to attack data ???
C2/4C4D: AA           TAX 
C2/4C4E: BD CF 3B     LDA $3BCF,X
C2/4C51: 85 0F        STA $0F
C2/4C53: BD CC 3B     LDA $3BCC,X     ; check if a character was hit ???
C2/4C56: 29 40        AND #$40
C2/4C58: F0 07        BEQ $4C61
C2/4C5A: BD D1 3B     LDA $3BD1,X     ; targets hit ???
C2/4C5D: 85 0E        STA $0E
C2/4C5F: 64 0F        STZ $0F
C2/4C61: A5 0F        LDA $0F
C2/4C63: 05 0E        ORA $0E
C2/4C65: 85 0E        STA $0E
C2/4C67: F0 71        BEQ $4CDA
C2/4C69: 7B           TDC 
C2/4C6A: AA           TAX 
C2/4C6B: 86 10        STX $10
C2/4C6D: A6 10        LDX $10
C2/4C6F: 06 0E        ASL $0E
C2/4C71: E6 10        INC $10
C2/4C73: B0 08        BCS $4C7D       ; branch if target was hit
C2/4C75: E8           INX 
C2/4C76: E0 08 00     CPX #$0008      ; check 8 bits
C2/4C79: D0 F4        BNE $4C6F
C2/4C7B: 80 5D        BRA $4CDA
C2/4C7D: C2 20        REP #$20
C2/4C7F: 8A           TXA 
C2/4C80: 20 B2 01     JSR $01B2       ; a << 7
C2/4C83: A8           TAY 
C2/4C84: 7B           TDC 
C2/4C85: E2 20        SEP #$20
C2/4C87: B9 20 20     LDA $2020,Y     ; check if character has the "learn" ability
C2/4C8A: 29 10        AND #$10
C2/4C8C: F0 DF        BEQ $4C6D
C2/4C8E: A5 08        LDA $08
C2/4C90: C2 20        REP #$20
C2/4C92: 20 B6 01     JSR $01B6       ; a << 3
C2/4C95: AA           TAX 
C2/4C96: 7B           TDC 
C2/4C97: E2 20        SEP #$20
C2/4C99: BF 82 0B D1  LDA $D10B82,X   ; attack properties
C2/4C9D: 29 F0        AND #$F0
C2/4C9F: 85 10        STA $10
C2/4CA1: 30 37        BMI $4CDA       ; spell can't be learned
C2/4CA3: 29 40        AND #$40
C2/4CA5: F0 04        BEQ $4CAB
C2/4CA7: A9 64        LDA #$64        ; 100% learn rate
C2/4CA9: 80 12        BRA $4CBD
C2/4CAB: A5 10        LDA $10
C2/4CAD: 29 20        AND #$20
C2/4CAF: F0 04        BEQ $4CB5
C2/4CB1: A9 32        LDA #$32        ; 50% learn rate
C2/4CB3: 80 08        BRA $4CBD
C2/4CB5: A5 10        LDA $10
C2/4CB7: 29 10        AND #$10
C2/4CB9: F0 1F        BEQ $4CDA
C2/4CBB: A9 0A        LDA #$0A        ; 10% learn rate
C2/4CBD: 85 0E        STA $0E
C2/4CBF: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/4CC2: C5 0E        CMP $0E
C2/4CC4: B0 12        BCS $4CD8
C2/4CC6: AD 20 7C     LDA $7C20
C2/4CC9: C9 08        CMP #$08        ; max 8 spells learned per battle
C2/4CCB: F0 12        BEQ $4CDF
C2/4CCD: AA           TAX 
C2/4CCE: A5 08        LDA $08
C2/4CD0: 9D 21 7C     STA $7C21,X     ; learned spell id
C2/4CD3: EE 20 7C     INC $7C20
C2/4CD6: 80 02        BRA $4CDA
C2/4CD8: 80 93        BRA $4C6D       ; next character
C2/4CDA: E6 3F        INC $3F
C2/4CDC: 4C 2C 4C     JMP $4C2C       ; check next attack
C2/4CDF: 60           RTS 

; [ init/exec battle ]

C2/4CE0: 20 0A 4F     JSR $4F0A       ; reset battle ram
C2/4CE3: 7B           TDC 
C2/4CE4: AA           TAX 
C2/4CE5: 7D 00 00     ADC $0000,X
C2/4CE8: E8           INX 
C2/4CE9: E0 E8 03     CPX #$03E8
C2/4CEC: D0 F7        BNE $4CE5
C2/4CEE: 6D F9 0A     ADC $0AF9       ; random number seed
C2/4CF1: 85 3A        STA $3A         ; random number 1
C2/4CF3: 7D 00 00     ADC $0000,X
C2/4CF6: E8           INX 
C2/4CF7: E0 D0 07     CPX #$07D0
C2/4CFA: D0 F7        BNE $4CF3
C2/4CFC: 85 3B        STA $3B         ; random number 2
C2/4CFE: 7B           TDC 
C2/4CFF: AA           TAX 
C2/4D00: BF 76 29 D1  LDA $D12976,X
C2/4D04: 9D D9 3E     STA $3ED9,X
C2/4D07: E8           INX 
C2/4D08: E0 0B 00     CPX #$000B
C2/4D0B: D0 F3        BNE $4D00
C2/4D0D: AD 70 09     LDA $0970       ; battle speed from config
C2/4D10: 29 0F        AND #$0F
C2/4D12: AA           TAX 
C2/4D13: BF F2 EC D0  LDA $D0ECF2,X   ; battle speed value
C2/4D17: 8D D6 3E     STA $3ED6       ; battle speed
C2/4D1A: C2 20        REP #$20
C2/4D1C: AD F0 04     LDA $04F0       ; battle index
C2/4D1F: 20 B5 01     JSR $01B5       ; a << 4
C2/4D22: AA           TAX 
C2/4D23: 7B           TDC 
C2/4D24: E2 20        SEP #$20
C2/4D26: A8           TAY 
C2/4D27: BF 00 30 D0  LDA $D03000,X   ; battle properties
C2/4D2B: 99 EF 3E     STA $3EEF,Y
C2/4D2E: C8           INY 
C2/4D2F: E8           INX 
C2/4D30: C0 10 00     CPY #$0010
C2/4D33: D0 F2        BNE $4D27
C2/4D35: 20 25 4E     JSR $4E25       ; check alt. battle
C2/4D38: 7B           TDC 
C2/4D39: AA           TAX 
C2/4D3A: A8           TAY 
C2/4D3B: BD F3 3E     LDA $3EF3,X     ; monster index
C2/4D3E: 99 20 40     STA $4020,Y
C2/4D41: C9 FF        CMP #$FF
C2/4D43: D0 05        BNE $4D4A
C2/4D45: 99 21 40     STA $4021,Y
C2/4D48: 80 0C        BRA $4D56
C2/4D4A: AD FE 3E     LDA $3EFE
C2/4D4D: 29 20        AND #$20
C2/4D4F: F0 05        BEQ $4D56       ; branch if not a boss battle
C2/4D51: A9 01        LDA #$01
C2/4D53: 99 21 40     STA $4021,Y     ; boss bit (msb of monster index)
C2/4D56: E8           INX 
C2/4D57: C8           INY 
C2/4D58: C8           INY 
C2/4D59: C0 10 00     CPY #$0010
C2/4D5C: D0 DD        BNE $4D3B
C2/4D5E: 7B           TDC 
C2/4D5F: A8           TAY 
C2/4D60: AA           TAX 
C2/4D61: 86 10        STX $10
C2/4D63: A9 D0        LDA #$D0
C2/4D65: 85 14        STA $14
C2/4D67: A0 00 00     LDY #$0000      ; D0/0000 (monster properties)
C2/4D6A: 84 12        STY $12
C2/4D6C: A4 10        LDY $10
C2/4D6E: B9 21 40     LDA $4021,Y
C2/4D71: F0 09        BEQ $4D7C
C2/4D73: A9 D0        LDA #$D0
C2/4D75: 85 14        STA $14
C2/4D77: A0 00 20     LDY #$2000      ; D0/2000 (boss properties)
C2/4D7A: 84 12        STY $12
C2/4D7C: A4 10        LDY $10
C2/4D7E: B9 F3 3E     LDA $3EF3,Y
C2/4D81: C2 20        REP #$20
C2/4D83: 20 B4 01     JSR $01B4       ; a << 5
C2/4D86: A8           TAY 
C2/4D87: 7B           TDC 
C2/4D88: E2 20        SEP #$20
C2/4D8A: 64 0E        STZ $0E
C2/4D8C: B7 12        LDA [$12],Y
C2/4D8E: 9D FF 3E     STA $3EFF,X
C2/4D91: C8           INY 
C2/4D92: E8           INX 
C2/4D93: E6 0E        INC $0E
C2/4D95: A5 0E        LDA $0E
C2/4D97: C9 20        CMP #$20
C2/4D99: D0 F1        BNE $4D8C
C2/4D9B: E6 10        INC $10
C2/4D9D: A5 10        LDA $10
C2/4D9F: C9 08        CMP #$08
C2/4DA1: D0 D9        BNE $4D7C
C2/4DA3: 7B           TDC 
C2/4DA4: AA           TAX 
C2/4DA5: AD F2 3E     LDA $3EF2
C2/4DA8: 8D FF 3F     STA $3FFF
C2/4DAB: 8D 48 40     STA $4048
C2/4DAE: 8D 09 7C     STA $7C09
C2/4DB1: 48           PHA 
C2/4DB2: 49 FF        EOR #$FF
C2/4DB4: 8D 0A 7C     STA $7C0A
C2/4DB7: 68           PLA 
C2/4DB8: 0A           ASL 
C2/4DB9: 90 03        BCC $4DBE
C2/4DBB: FE 18 40     INC $4018,X
C2/4DBE: E8           INX 
C2/4DBF: E0 08 00     CPX #$0008
C2/4DC2: D0 F4        BNE $4DB8
C2/4DC4: C2 20        REP #$20
C2/4DC6: AD F0 04     LDA $04F0
C2/4DC9: 20 B6 01     JSR $01B6       ; a << 3
C2/4DCC: AA           TAX 
C2/4DCD: 7B           TDC 
C2/4DCE: E2 20        SEP #$20
C2/4DD0: 7B           TDC 
C2/4DD1: A8           TAY 
C2/4DD2: BF 00 89 D0  LDA $D08900,X   ; monster positions
C2/4DD6: 99 00 40     STA $4000,Y
C2/4DD9: E8           INX 
C2/4DDA: C8           INY 
C2/4DDB: C0 08 00     CPY #$0008
C2/4DDE: D0 F2        BNE $4DD2
C2/4DE0: 7B           TDC 
C2/4DE1: AA           TAX 
C2/4DE2: BD F3 3E     LDA $3EF3,X
C2/4DE5: C9 FF        CMP #$FF
C2/4DE7: D0 09        BNE $4DF2
C2/4DE9: AD 09 7C     LDA $7C09
C2/4DEC: 20 D6 01     JSR $01D6       ; set bit x
C2/4DEF: 8D 09 7C     STA $7C09
C2/4DF2: E8           INX 
C2/4DF3: E0 08 00     CPX #$0008
C2/4DF6: D0 EA        BNE $4DE2
C2/4DF8: 20 A2 3E     JSR $3EA2       ; init character/monster properties
C2/4DFB: 20 AF 41     JSR $41AF
C2/4DFE: 20 D2 1F     JSR $1FD2
C2/4E01: 20 47 24     JSR $2447
C2/4E04: 20 41 5A     JSR $5A41
C2/4E07: 20 21 59     JSR $5921
C2/4E0A: 20 5C 50     JSR $505C
C2/4E0D: 20 7A 4F     JSR $4F7A
C2/4E10: A9 02        LDA #$02        ; battle graphics command $02 (init battle graphics)
C2/4E12: 20 69 00     JSR $0069       ; execute battle graphics function
C2/4E15: 20 9F 4E     JSR $4E9F
C2/4E18: AD 5F 3C     LDA $3C5F
C2/4E1B: F0 05        BEQ $4E22
C2/4E1D: A9 0A        LDA #$0A
C2/4E1F: 20 69 00     JSR $0069       ; execute battle graphics function
C2/4E22: 4C 72 58     JMP $5872       ; battle loop

; [ check alt. battle ]

C2/4E25: AD FE 3E     LDA $3EFE
C2/4E28: 29 10        AND #$10
C2/4E2A: F0 04        BEQ $4E30       ; branch if no check for alt. battle
C2/4E2C: EE 4C 7C     INC $7C4C       ; no alt. battle
C2/4E2F: 60           RTS 
C2/4E30: 7B           TDC 
C2/4E31: AA           TAX 
C2/4E32: 86 10        STX $10
C2/4E34: A6 10        LDX $10
C2/4E36: AD F0 04     LDA $04F0       ; compare battle index
C2/4E39: DF E0 FF D0  CMP $D0FFE0,X
C2/4E3D: D0 33        BNE $4E72
C2/4E3F: AD F1 04     LDA $04F1
C2/4E42: DF E1 FF D0  CMP $D0FFE1,X
C2/4E46: D0 2A        BNE $4E72
C2/4E48: BF E2 FF D0  LDA $D0FFE2,X   ; alt. battle index
C2/4E4C: 85 12        STA $12
C2/4E4E: BF E3 FF D0  LDA $D0FFE3,X
C2/4E52: 85 13        STA $13
C2/4E54: 8A           TXA 
C2/4E55: 20 C0 01     JSR $01C0       ; a >> 2
C2/4E58: 64 0E        STZ $0E
C2/4E5A: 4A           LSR 
C2/4E5B: 66 0E        ROR $0E
C2/4E5D: 4A           LSR 
C2/4E5E: 66 0E        ROR $0E
C2/4E60: 4A           LSR 
C2/4E61: 66 0E        ROR $0E
C2/4E63: A8           TAY 
C2/4E64: A5 0E        LDA $0E
C2/4E66: 20 BD 01     JSR $01BD       ; a >> 5
C2/4E69: AA           TAX 
C2/4E6A: B9 85 7C     LDA $7C85,Y     ; second byte here is never used
C2/4E6D: 20 DB 01     JSR $01DB       ; check bit x
C2/4E70: D0 0F        BNE $4E81
C2/4E72: E6 10        INC $10         ; check next battle
C2/4E74: E6 10        INC $10
C2/4E76: E6 10        INC $10
C2/4E78: E6 10        INC $10
C2/4E7A: A5 10        LDA $10
C2/4E7C: C9 20        CMP #$20
C2/4E7E: D0 B4        BNE $4E34
C2/4E80: 60           RTS 
C2/4E81: C2 20        REP #$20
C2/4E83: A5 12        LDA $12         ; change to alt. battle
C2/4E85: 8D F0 04     STA $04F0
C2/4E88: 20 B5 01     JSR $01B5       ; a << 4
C2/4E8B: AA           TAX 
C2/4E8C: 7B           TDC 
C2/4E8D: E2 20        SEP #$20
C2/4E8F: A8           TAY 
C2/4E90: BF 00 30 D0  LDA $D03000,X   ; load battle properties
C2/4E94: 99 EF 3E     STA $3EEF,Y
C2/4E97: C8           INY 
C2/4E98: E8           INX 
C2/4E99: C0 10 00     CPY #$0010
C2/4E9C: D0 F2        BNE $4E90
C2/4E9E: 60           RTS 

; [  ]

C2/4E9F: A9 FF        LDA #$FF
C2/4EA1: 85 0E        STA $0E
C2/4EA3: 7B           TDC 
C2/4EA4: AA           TAX 
C2/4EA5: A8           TAY 
C2/4EA6: B9 C2 3E     LDA $3EC2,Y
C2/4EA9: F0 09        BEQ $4EB4
C2/4EAB: BD 7F 3D     LDA $3D7F,X
C2/4EAE: C5 0E        CMP $0E
C2/4EB0: B0 02        BCS $4EB4
C2/4EB2: 85 0E        STA $0E
C2/4EB4: 8A           TXA 
C2/4EB5: 18           CLC 
C2/4EB6: 69 0B        ADC #$0B
C2/4EB8: AA           TAX 
C2/4EB9: C8           INY 
C2/4EBA: C0 0C 00     CPY #$000C
C2/4EBD: D0 E7        BNE $4EA6
C2/4EBF: 38           SEC 
C2/4EC0: A5 0E        LDA $0E
C2/4EC2: E9 02        SBC #$02
C2/4EC4: B0 01        BCS $4EC7
C2/4EC6: 7B           TDC 
C2/4EC7: 85 0E        STA $0E
C2/4EC9: 7B           TDC 
C2/4ECA: AA           TAX 
C2/4ECB: A8           TAY 
C2/4ECC: B9 C2 3E     LDA $3EC2,Y
C2/4ECF: F0 09        BEQ $4EDA
C2/4ED1: 38           SEC 
C2/4ED2: BD 7F 3D     LDA $3D7F,X
C2/4ED5: E5 0E        SBC $0E
C2/4ED7: 9D 7F 3D     STA $3D7F,X
C2/4EDA: 8A           TXA 
C2/4EDB: 18           CLC 
C2/4EDC: 69 0B        ADC #$0B
C2/4EDE: AA           TAX 
C2/4EDF: C8           INY 
C2/4EE0: C0 0C 00     CPY #$000C
C2/4EE3: D0 E7        BNE $4ECC
C2/4EE5: 7B           TDC 
C2/4EE6: AA           TAX 
C2/4EE7: A8           TAY 
C2/4EE8: AD EF 3E     LDA $3EEF
C2/4EEB: 30 0C        BMI $4EF9
C2/4EED: BD 38 20     LDA $2038,X
C2/4EF0: 29 20        AND #$20
C2/4EF2: F0 05        BEQ $4EF9
C2/4EF4: A9 01        LDA #$01
C2/4EF6: 99 7F 3D     STA $3D7F,Y
C2/4EF9: 98           TYA 
C2/4EFA: 18           CLC 
C2/4EFB: 69 0B        ADC #$0B
C2/4EFD: A8           TAY 
C2/4EFE: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/4F01: E6 0E        INC $0E
C2/4F03: A5 0E        LDA $0E
C2/4F05: C9 04        CMP #$04
C2/4F07: D0 DF        BNE $4EE8
C2/4F09: 60           RTS 

; [ reset battle ram ]

C2/4F0A: A2 67 00     LDX #$0067
C2/4F0D: 7B           TDC 
C2/4F0E: 95 00        STA $00,X       ; clear $00-$67
C2/4F10: CA           DEX 
C2/4F11: 10 FB        BPL $4F0E
C2/4F13: A2 D7 5C     LDX #$5CD7
C2/4F16: 7B           TDC 
C2/4F17: 9D 00 20     STA $2000,X     ; clear $2000-$5CD7
C2/4F1A: CA           DEX 
C2/4F1B: 10 FA        BPL $4F17
C2/4F1D: 8A           TXA 
C2/4F1E: 8D A9 41     STA $41A9       ; 
C2/4F21: 8D AA 41     STA $41AA
C2/4F24: 8D AB 41     STA $41AB
C2/4F27: 8D AC 41     STA $41AC
C2/4F2A: 8D AD 41     STA $41AD
C2/4F2D: 8D CC 41     STA $41CC
C2/4F30: 8D 4B 7C     STA $7C4B
C2/4F33: A2 FF 01     LDX #$01FF      ; set $384C-$3A4B to #$FF (battle graphics commands)
C2/4F36: 9D 4C 38     STA $384C,X
C2/4F39: CA           DEX 
C2/4F3A: 10 FA        BPL $4F36
C2/4F3C: 7B           TDC 
C2/4F3D: AA           TAX 
C2/4F3E: BD B4 09     LDA $09B4,X     ; copy battle flags
C2/4F41: 9D 74 7C     STA $7C74,X
C2/4F44: E8           INX 
C2/4F45: E0 20 00     CPX #$0020
C2/4F48: D0 F4        BNE $4F3E
C2/4F4A: AD FB 0A     LDA $0AFB       ; timer enabled flag
C2/4F4D: 8D 94 7C     STA $7C94
C2/4F50: AD FC 0A     LDA $0AFC       ; timer event
C2/4F53: 8D 95 7C     STA $7C95
C2/4F56: AD FD 0A     LDA $0AFD
C2/4F59: 8D 96 7C     STA $7C96
C2/4F5C: EE 72 7C     INC $7C72       ; 
C2/4F5F: A9 40        LDA #$40
C2/4F61: 8D 00 22     STA $2200       ; mark all monsters as not present
C2/4F64: 8D 80 22     STA $2280
C2/4F67: 8D 00 23     STA $2300
C2/4F6A: 8D 80 23     STA $2380
C2/4F6D: 8D 00 24     STA $2400
C2/4F70: 8D 80 24     STA $2480
C2/4F73: 8D 00 25     STA $2500
C2/4F76: 8D 80 25     STA $2580
C2/4F79: 60           RTS 

; [  ]

C2/4F7A: 7B           TDC 
C2/4F7B: AA           TAX 
C2/4F7C: A8           TAY 
C2/4F7D: BD 00 20     LDA $2000,X
C2/4F80: 99 1A 7C     STA $7C1A,Y
C2/4F83: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/4F86: C8           INY 
C2/4F87: C0 04 00     CPY #$0004
C2/4F8A: D0 F1        BNE $4F7D
C2/4F8C: AD 21 40     LDA $4021
C2/4F8F: D0 12        BNE $4FA3
C2/4F91: AD 21 20     LDA $2021
C2/4F94: 0D A1 20     ORA $20A1
C2/4F97: 0D 21 21     ORA $2121
C2/4F9A: 0D A1 21     ORA $21A1
C2/4F9D: 85 0E        STA $0E
C2/4F9F: 29 04        AND #$04
C2/4FA1: D0 27        BNE $4FCA
C2/4FA3: AD FE 3E     LDA $3EFE
C2/4FA6: 30 1A        BMI $4FC2
C2/4FA8: AD 21 40     LDA $4021
C2/4FAB: D0 39        BNE $4FE6
C2/4FAD: AD EF 3E     LDA $3EEF
C2/4FB0: 30 34        BMI $4FE6
C2/4FB2: AD D8 7C     LDA $7CD8
C2/4FB5: D0 13        BNE $4FCA
C2/4FB7: 7B           TDC 
C2/4FB8: AA           TAX 
C2/4FB9: A9 FF        LDA #$FF
C2/4FBB: 20 7C 00     JSR $007C       ; a = (x..a)
C2/4FBE: C9 10        CMP #$10
C2/4FC0: B0 08        BCS $4FCA
C2/4FC2: EE 19 7C     INC $7C19
C2/4FC5: 20 EA 4F     JSR $4FEA
C2/4FC8: 80 1C        BRA $4FE6
C2/4FCA: A9 20        LDA #$20
C2/4FCC: 85 10        STA $10
C2/4FCE: A5 0E        LDA $0E
C2/4FD0: 29 02        AND #$02
C2/4FD2: F0 04        BEQ $4FD8
C2/4FD4: A9 40        LDA #$40
C2/4FD6: 85 10        STA $10
C2/4FD8: 7B           TDC 
C2/4FD9: AA           TAX 
C2/4FDA: A9 FF        LDA #$FF
C2/4FDC: 20 7C 00     JSR $007C       ; a = (x..a)
C2/4FDF: C5 10        CMP $10
C2/4FE1: B0 03        BCS $4FE6
C2/4FE3: 20 01 50     JSR $5001
C2/4FE6: 9C D8 7C     STZ $7CD8
C2/4FE9: 60           RTS 

; [  ]

C2/4FEA: A9 1C        LDA #$1C
C2/4FEC: 8D 5F 3C     STA $3C5F
C2/4FEF: 7B           TDC 
C2/4FF0: AA           TAX 
C2/4FF1: A8           TAY 
C2/4FF2: 84 0E        STY $0E
C2/4FF4: A9 04        LDA #$04
C2/4FF6: 85 10        STA $10
C2/4FF8: 64 12        STZ $12
C2/4FFA: A9 3C        LDA #$3C
C2/4FFC: 85 16        STA $16
C2/4FFE: 4C 1D 50     JMP $501D

; [  ]

C2/5001: A9 1B        LDA #$1B
C2/5003: 8D 5F 3C     STA $3C5F
C2/5006: A2 00 02     LDX #$0200
C2/5009: A0 2C 00     LDY #$002C
C2/500C: A9 04        LDA #$04
C2/500E: 85 0E        STA $0E
C2/5010: A9 0C        LDA #$0C
C2/5012: 85 10        STA $10
C2/5014: 85 12        STA $12
C2/5016: A9 5A        LDA #$5A
C2/5018: 85 16        STA $16
C2/501A: 4C 1D 50     JMP $501D

; [  ]

C2/501D: BD 38 20     LDA $2038,X
C2/5020: 29 20        AND #$20
C2/5022: D0 11        BNE $5035
C2/5024: 18           CLC 
C2/5025: B9 7F 3D     LDA $3D7F,Y
C2/5028: 65 16        ADC $16
C2/502A: 90 02        BCC $502E
C2/502C: A9 FF        LDA #$FF
C2/502E: 99 7F 3D     STA $3D7F,Y
C2/5031: A5 12        LDA $12
C2/5033: D0 13        BNE $5048
C2/5035: BD 00 20     LDA $2000,X
C2/5038: 29 7F        AND #$7F
C2/503A: 85 14        STA $14
C2/503C: BD 00 20     LDA $2000,X
C2/503F: 29 80        AND #$80
C2/5041: 49 80        EOR #$80
C2/5043: 05 14        ORA $14
C2/5045: 9D 00 20     STA $2000,X
C2/5048: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/504B: 98           TYA 
C2/504C: 18           CLC 
C2/504D: 69 0B        ADC #$0B
C2/504F: A8           TAY 
C2/5050: E6 0E        INC $0E
C2/5052: A5 0E        LDA $0E
C2/5054: C5 10        CMP $10
C2/5056: D0 C5        BNE $501D
C2/5058: 7B           TDC 
C2/5059: 4C 47 58     JMP $5847
C2/505C: AD FD 3E     LDA $3EFD
C2/505F: 30 0E        BMI $506F
C2/5061: AD FD 3E     LDA $3EFD
C2/5064: 20 BF 01     JSR $01BF       ; a >> 3
C2/5067: AA           TAX 
C2/5068: BF DF EE D0  LDA $D0EEDF,X   ; spc commands for battle songs
C2/506C: 20 6E 00     JSR $006E       ; play song
C2/506F: 60           RTS 

; [  ]

C2/5070: 20 18 02     JSR $0218       ; reset battle graphics parameters
C2/5073: A2 07 00     LDX #$0007
C2/5076: 9E 3B 01     STZ $013B,X
C2/5079: 9E 66 7C     STZ $7C66,X
C2/507C: CA           DEX 
C2/507D: 10 F7        BPL $5076
C2/507F: AD D8 7C     LDA $7CD8
C2/5082: F0 03        BEQ $5087
C2/5084: 4C 42 51     JMP $5142
C2/5087: AD DE 7B     LDA $7BDE
C2/508A: 29 40        AND #$40
C2/508C: F0 17        BEQ $50A5
C2/508E: A9 01        LDA #$01
C2/5090: 20 47 58     JSR $5847
C2/5093: A9 75        LDA #$75        ; requiem
C2/5095: 20 6E 00     JSR $006E       ; play song
C2/5098: A9 01        LDA #$01
C2/509A: 8D 84 7C     STA $7C84
C2/509D: A9 2A        LDA #$2A
C2/509F: 8D 5F 3C     STA $3C5F
C2/50A2: 4C 17 51     JMP $5117
C2/50A5: AD DE 7B     LDA $7BDE
C2/50A8: 29 01        AND #$01
C2/50AA: F0 30        BEQ $50DC       ; branch if didn't run away
C2/50AC: A9 02        LDA #$02
C2/50AE: 8D 84 7C     STA $7C84
C2/50B1: A9 80        LDA #$80
C2/50B3: 8D CF 3B     STA $3BCF
C2/50B6: A9 0C        LDA #$0C
C2/50B8: 20 69 00     JSR $0069       ; execute battle graphics function
C2/50BB: 20 5C 51     JSR $515C
C2/50BE: 20 5E 9A     JSR $9A5E       ; update character equipment (all)
C2/50C1: 20 F4 51     JSR $51F4
C2/50C4: A9 2B        LDA #$2B
C2/50C6: 8D 5F 3C     STA $3C5F
C2/50C9: 7B           TDC 
C2/50CA: 20 47 58     JSR $5847
C2/50CD: 18           CLC 
C2/50CE: AD 75 7C     LDA $7C75       ; increment escape count
C2/50D1: 69 01        ADC #$01
C2/50D3: 90 02        BCC $50D7
C2/50D5: A9 FF        LDA #$FF        ; max 255
C2/50D7: 8D 75 7C     STA $7C75
C2/50DA: 80 3B        BRA $5117
C2/50DC: 9C 84 7C     STZ $7C84
C2/50DF: 20 5C 51     JSR $515C
C2/50E2: AD DE 7B     LDA $7BDE
C2/50E5: 10 28        BPL $510F
C2/50E7: AD FE 3E     LDA $3EFE
C2/50EA: 29 02        AND #$02
C2/50EC: D0 21        BNE $510F
C2/50EE: AD FD 3E     LDA $3EFD
C2/50F1: 30 05        BMI $50F8
C2/50F3: A9 70        LDA #$70        ; victory fanfare
C2/50F5: 20 6E 00     JSR $006E       ; play song
C2/50F8: A9 0D        LDA #$0D
C2/50FA: 20 69 00     JSR $0069       ; execute battle graphics function
C2/50FD: A9 01        LDA #$01
C2/50FF: 20 47 58     JSR $5847
C2/5102: A9 29        LDA #$29
C2/5104: 8D 5F 3C     STA $3C5F
C2/5107: A9 0A        LDA #$0A
C2/5109: 20 69 00     JSR $0069       ; execute battle graphics function
C2/510C: 20 A2 52     JSR $52A2
C2/510F: 20 5E 9A     JSR $9A5E       ; update character equipment (all)
C2/5112: 20 F4 51     JSR $51F4
C2/5115: 80 05        BRA $511C
C2/5117: A9 0A        LDA #$0A
C2/5119: 20 69 00     JSR $0069       ; execute battle graphics function
C2/511C: 22 78 EF D0  JSL $D0EF78     ; validate inventory
C2/5120: 20 C2 51     JSR $51C2
C2/5123: 7B           TDC 
C2/5124: AA           TAX 
C2/5125: BD 74 7C     LDA $7C74,X
C2/5128: 9D B4 09     STA $09B4,X
C2/512B: E8           INX 
C2/512C: E0 20 00     CPX #$0020
C2/512F: D0 F4        BNE $5125
C2/5131: AD 95 7C     LDA $7C95
C2/5134: 8D FC 0A     STA $0AFC
C2/5137: AD 96 7C     LDA $7C96
C2/513A: 8D FD 0A     STA $0AFD
C2/513D: A9 0E        LDA #$0E
C2/513F: 20 69 00     JSR $0069       ; execute battle graphics function
C2/5142: 7B           TDC 
C2/5143: AA           TAX 
C2/5144: 1D 66 7C     ORA $7C66,X
C2/5147: E8           INX 
C2/5148: E0 08 00     CPX #$0008
C2/514B: D0 F7        BNE $5144
C2/514D: 48           PHA 
C2/514E: 68           PLA 
C2/514F: D0 0A        BNE $515B
C2/5151: AD FD 3E     LDA $3EFD
C2/5154: 30 05        BMI $515B
C2/5156: A9 7F        LDA #$7F        ; fade out soung
C2/5158: 20 6E 00     JSR $006E       ; play song
C2/515B: 60           RTS 

; [  ]

C2/515C: 7B           TDC 
C2/515D: A8           TAY 
C2/515E: AA           TAX 
C2/515F: 86 0E        STX $0E
C2/5161: B9 02 05     LDA $0502,Y
C2/5164: 9D 02 20     STA $2002,X
C2/5167: B9 24 05     LDA $0524,Y
C2/516A: 9D 24 20     STA $2024,X
C2/516D: B9 25 05     LDA $0525,Y
C2/5170: 9D 25 20     STA $2025,X
C2/5173: B9 26 05     LDA $0526,Y
C2/5176: 9D 26 20     STA $2026,X
C2/5179: B9 27 05     LDA $0527,Y
C2/517C: 9D 27 20     STA $2027,X
C2/517F: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5182: C2 20        REP #$20
C2/5184: 98           TYA 
C2/5185: 18           CLC 
C2/5186: 69 50 00     ADC #$0050
C2/5189: A8           TAY 
C2/518A: 7B           TDC 
C2/518B: E2 20        SEP #$20
C2/518D: E6 0E        INC $0E
C2/518F: A5 0E        LDA $0E
C2/5191: C9 04        CMP #$04
C2/5193: D0 CC        BNE $5161
C2/5195: 7B           TDC 
C2/5196: AA           TAX 
C2/5197: 86 0E        STX $0E
C2/5199: 86 10        STX $10
C2/519B: A6 0E        LDX $0E
C2/519D: 9E 1E 20     STZ $201E,X
C2/51A0: 9E 1F 20     STZ $201F,X
C2/51A3: 9E 22 20     STZ $2022,X
C2/51A6: 7B           TDC 
C2/51A7: A8           TAY 
C2/51A8: 9E 30 20     STZ $2030,X
C2/51AB: E8           INX 
C2/51AC: C8           INY 
C2/51AD: C0 0A 00     CPY #$000A
C2/51B0: D0 F6        BNE $51A8
C2/51B2: A6 0E        LDX $0E
C2/51B4: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/51B7: 86 0E        STX $0E
C2/51B9: E6 10        INC $10
C2/51BB: A5 10        LDA $10
C2/51BD: C9 04        CMP #$04
C2/51BF: D0 DA        BNE $519B
C2/51C1: 60           RTS 

; [  ]

C2/51C2: 7B           TDC 
C2/51C3: AA           TAX 
C2/51C4: 9B           TXY 
C2/51C5: C8           INY 
C2/51C6: BD 40 06     LDA $0640,X     ; item id
C2/51C9: F0 22        BEQ $51ED
C2/51CB: D9 40 06     CMP $0640,Y
C2/51CE: D0 17        BNE $51E7
C2/51D0: 18           CLC 
C2/51D1: BD 40 07     LDA $0740,X     ; item quantity
C2/51D4: 79 40 07     ADC $0740,Y
C2/51D7: C9 63        CMP #$63
C2/51D9: 90 02        BCC $51DD
C2/51DB: A9 63        LDA #$63
C2/51DD: 9D 40 07     STA $0740,X
C2/51E0: 7B           TDC 
C2/51E1: 99 40 06     STA $0640,Y
C2/51E4: 99 40 07     STA $0740,Y
C2/51E7: C8           INY 
C2/51E8: C0 00 01     CPY #$0100
C2/51EB: D0 D9        BNE $51C6
C2/51ED: E8           INX 
C2/51EE: E0 FF 00     CPX #$00FF
C2/51F1: D0 D1        BNE $51C4
C2/51F3: 60           RTS 

; [  ]

C2/51F4: 7B           TDC 
C2/51F5: AA           TAX 
C2/51F6: A8           TAY 
C2/51F7: 84 10        STY $10
C2/51F9: 86 12        STX $12
C2/51FB: 64 0E        STZ $0E
C2/51FD: A5 10        LDA $10
C2/51FF: AA           TAX 
C2/5200: BD 59 7C     LDA $7C59,X     ; increase max hp (giant drink effect)
C2/5203: F0 1B        BEQ $5220
C2/5205: 5A           PHY 
C2/5206: A5 10        LDA $10
C2/5208: 0A           ASL 
C2/5209: A8           TAY 
C2/520A: C2 20        REP #$20
C2/520C: B9 11 7C     LDA $7C11,Y     ; saved max hp
C2/520F: A6 12        LDX $12
C2/5211: 9D 08 20     STA $2008,X     ; reset max hp
C2/5214: DD 06 20     CMP $2006,X
C2/5217: B0 03        BCS $521C
C2/5219: 9D 06 20     STA $2006,X     ; validate current hp
C2/521C: 7B           TDC 
C2/521D: E2 20        SEP #$20
C2/521F: 7A           PLY 
C2/5220: A6 12        LDX $12
C2/5222: 9E 1B 20     STZ $201B,X     ; reset status
C2/5225: 9E 1C 20     STZ $201C,X
C2/5228: 9E 1D 20     STZ $201D,X
C2/522B: 9E 1E 20     STZ $201E,X
C2/522E: A6 10        LDX $10
C2/5230: BD 1A 7C     LDA $7C1A,X
C2/5233: A6 12        LDX $12
C2/5235: 9D 00 20     STA $2000,X
C2/5238: BD 00 20     LDA $2000,X     ; copy stats back to sram
C2/523B: 99 00 05     STA $0500,Y
C2/523E: E8           INX 
C2/523F: C8           INY 
C2/5240: E6 0E        INC $0E
C2/5242: A5 0E        LDA $0E
C2/5244: C9 46        CMP #$46
C2/5246: D0 F0        BNE $5238
C2/5248: C2 20        REP #$20
C2/524A: 98           TYA 
C2/524B: 18           CLC 
C2/524C: 69 0A 00     ADC #$000A
C2/524F: A8           TAY 
C2/5250: 7B           TDC 
C2/5251: E2 20        SEP #$20
C2/5253: A6 12        LDX $12
C2/5255: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5258: 86 12        STX $12
C2/525A: E6 10        INC $10
C2/525C: A5 10        LDA $10
C2/525E: C9 04        CMP #$04
C2/5260: D0 99        BNE $51FB
C2/5262: A2 FF 00     LDX #$00FF
C2/5265: BD 34 27     LDA $2734,X
C2/5268: 9D 40 06     STA $0640,X
C2/526B: D0 03        BNE $5270
C2/526D: 7B           TDC 
C2/526E: 80 03        BRA $5273
C2/5270: BD 34 28     LDA $2834,X
C2/5273: 9D 40 07     STA $0740,X
C2/5276: D0 03        BNE $527B
C2/5278: 9D 40 06     STA $0640,X
C2/527B: CA           DEX 
C2/527C: 10 E7        BPL $5265
C2/527E: C2 20        REP #$20
C2/5280: 18           CLC 
C2/5281: AD 4A 09     LDA $094A
C2/5284: 6D 6E DB     ADC $DB6E
C2/5287: 8D 4A 09     STA $094A
C2/528A: AD 4C 09     LDA $094C
C2/528D: 6D 70 DB     ADC $DB70
C2/5290: 8D 4C 09     STA $094C
C2/5293: 90 09        BCC $529E
C2/5295: A9 FF FF     LDA #$FFFF
C2/5298: 8D 4A 09     STA $094A
C2/529B: 8D 4C 09     STA $094C
C2/529E: 7B           TDC 
C2/529F: E2 20        SEP #$20
C2/52A1: 60           RTS 

; [  ]

C2/52A2: AD 09 7C     LDA $7C09
C2/52A5: 49 FF        EOR #$FF
C2/52A7: 8D 09 7C     STA $7C09
C2/52AA: 20 C3 01     JSR $01C3       ; count set bits
C2/52AD: C2 20        REP #$20
C2/52AF: 8A           TXA 
C2/52B0: 18           CLC 
C2/52B1: 6D 4E 09     ADC $094E
C2/52B4: 90 03        BCC $52B9
C2/52B6: A9 FF FF     LDA #$FFFF
C2/52B9: 8D 4E 09     STA $094E
C2/52BC: 7B           TDC 
C2/52BD: E2 20        SEP #$20
C2/52BF: 7B           TDC 
C2/52C0: AA           TAX 
C2/52C1: 8E 0B 7C     STX $7C0B
C2/52C4: 8E 0D 7C     STX $7C0D
C2/52C7: 8E 0F 7C     STX $7C0F
C2/52CA: 86 3D        STX $3D
C2/52CC: A0 00 02     LDY #$0200
C2/52CF: 84 3F        STY $3F
C2/52D1: A6 3D        LDX $3D
C2/52D3: AD 09 7C     LDA $7C09
C2/52D6: 20 DB 01     JSR $01DB       ; check bit x
C2/52D9: F0 39        BEQ $5314
C2/52DB: 18           CLC 
C2/52DC: AD 0B 7C     LDA $7C0B
C2/52DF: 79 69 20     ADC $2069,Y
C2/52E2: 8D 0B 7C     STA $7C0B
C2/52E5: AD 0C 7C     LDA $7C0C
C2/52E8: 79 6A 20     ADC $206A,Y
C2/52EB: 8D 0C 7C     STA $7C0C
C2/52EE: AD 0D 7C     LDA $7C0D
C2/52F1: 69 00        ADC #$00
C2/52F3: 8D 0D 7C     STA $7C0D
C2/52F6: 18           CLC 
C2/52F7: AD 0E 7C     LDA $7C0E
C2/52FA: 79 67 20     ADC $2067,Y
C2/52FD: 8D 0E 7C     STA $7C0E
C2/5300: AD 0F 7C     LDA $7C0F
C2/5303: 79 68 20     ADC $2068,Y
C2/5306: 8D 0F 7C     STA $7C0F
C2/5309: AD 10 7C     LDA $7C10
C2/530C: 69 00        ADC #$00
C2/530E: 8D 10 7C     STA $7C10
C2/5311: 20 9A 56     JSR $569A
C2/5314: A4 3F        LDY $3F
C2/5316: C2 20        REP #$20
C2/5318: 98           TYA 
C2/5319: 18           CLC 
C2/531A: 69 80 00     ADC #$0080
C2/531D: A8           TAY 
C2/531E: 7B           TDC 
C2/531F: E2 20        SEP #$20
C2/5321: 84 3F        STY $3F
C2/5323: E6 3D        INC $3D
C2/5325: A5 3D        LDA $3D
C2/5327: C9 08        CMP #$08
C2/5329: D0 A6        BNE $52D1
C2/532B: 18           CLC 
C2/532C: AD 47 09     LDA $0947
C2/532F: 6D 0B 7C     ADC $7C0B
C2/5332: 8D 47 09     STA $0947
C2/5335: AD 48 09     LDA $0948
C2/5338: 6D 0C 7C     ADC $7C0C
C2/533B: 8D 48 09     STA $0948
C2/533E: AD 49 09     LDA $0949
C2/5341: 6D 0D 7C     ADC $7C0D
C2/5344: 8D 49 09     STA $0949
C2/5347: 38           SEC 
C2/5348: AD 47 09     LDA $0947
C2/534B: E9 7F        SBC #$7F
C2/534D: AD 48 09     LDA $0948
C2/5350: E9 96        SBC #$96
C2/5352: AD 49 09     LDA $0949
C2/5355: E9 98        SBC #$98
C2/5357: 90 0F        BCC $5368
C2/5359: A9 7F        LDA #$7F
C2/535B: 8D 47 09     STA $0947
C2/535E: A9 96        LDA #$96
C2/5360: 8D 48 09     STA $0948
C2/5363: A9 98        LDA #$98
C2/5365: 8D 49 09     STA $0949
C2/5368: AD F1 3E     LDA $3EF1
C2/536B: AA           TAX 
C2/536C: 86 0E        STX $0E
C2/536E: 7B           TDC 
C2/536F: AA           TAX 
C2/5370: 86 10        STX $10
C2/5372: 86 12        STX $12
C2/5374: A5 12        LDA $12
C2/5376: A8           TAY 
C2/5377: B9 C2 3E     LDA $3EC2,Y
C2/537A: F0 15        BEQ $5391
C2/537C: E6 10        INC $10
C2/537E: C2 20        REP #$20
C2/5380: 18           CLC 
C2/5381: BD 3B 20     LDA $203B,X
C2/5384: 65 0E        ADC $0E
C2/5386: 90 03        BCC $538B
C2/5388: A9 FF FF     LDA #$FFFF
C2/538B: 9D 3B 20     STA $203B,X
C2/538E: 7B           TDC 
C2/538F: E2 20        SEP #$20
C2/5391: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5394: E6 12        INC $12
C2/5396: A5 12        LDA $12
C2/5398: C9 04        CMP #$04
C2/539A: D0 D8        BNE $5374
C2/539C: AD 0E 7C     LDA $7C0E
C2/539F: 0D 0F 7C     ORA $7C0F
C2/53A2: 0D 10 7C     ORA $7C10
C2/53A5: F0 03        BEQ $53AA
C2/53A7: 20 E6 57     JSR $57E6
C2/53AA: AD 09 7C     LDA $7C09
C2/53AD: D0 09        BNE $53B8
C2/53AF: 9C 0E 7C     STZ $7C0E
C2/53B2: 9C 0F 7C     STZ $7C0F
C2/53B5: 9C 10 7C     STZ $7C10
C2/53B8: 7B           TDC 
C2/53B9: AA           TAX 
C2/53BA: 86 0E        STX $0E
C2/53BC: A5 0E        LDA $0E
C2/53BE: A8           TAY 
C2/53BF: B9 C2 3E     LDA $3EC2,Y
C2/53C2: F0 3D        BEQ $5401
C2/53C4: 18           CLC 
C2/53C5: BD 03 20     LDA $2003,X
C2/53C8: 6D 0E 7C     ADC $7C0E
C2/53CB: 9D 03 20     STA $2003,X
C2/53CE: BD 04 20     LDA $2004,X
C2/53D1: 6D 0F 7C     ADC $7C0F
C2/53D4: 9D 04 20     STA $2004,X
C2/53D7: BD 05 20     LDA $2005,X
C2/53DA: 6D 10 7C     ADC $7C10
C2/53DD: 9D 05 20     STA $2005,X
C2/53E0: 38           SEC 
C2/53E1: BD 03 20     LDA $2003,X
C2/53E4: E9 7F        SBC #$7F
C2/53E6: BD 04 20     LDA $2004,X
C2/53E9: E9 96        SBC #$96
C2/53EB: BD 05 20     LDA $2005,X
C2/53EE: E9 98        SBC #$98
C2/53F0: 90 0F        BCC $5401
C2/53F2: A9 7F        LDA #$7F
C2/53F4: 9D 03 20     STA $2003,X
C2/53F7: A9 96        LDA #$96
C2/53F9: 9D 04 20     STA $2004,X
C2/53FC: A9 98        LDA #$98
C2/53FE: 9D 05 20     STA $2005,X
C2/5401: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5404: E6 0E        INC $0E
C2/5406: A5 0E        LDA $0E
C2/5408: C9 04        CMP #$04
C2/540A: D0 B0        BNE $53BC
C2/540C: A9 FF        LDA #$FF
C2/540E: 8D 5F 3C     STA $3C5F
C2/5411: A9 01        LDA #$01
C2/5413: 20 47 58     JSR $5847
C2/5416: 7B           TDC 
C2/5417: AA           TAX 
C2/5418: AD 0B 7C     LDA $7C0B
C2/541B: 8D BF 3C     STA $3CBF
C2/541E: AD 0C 7C     LDA $7C0C
C2/5421: 8D C0 3C     STA $3CC0
C2/5424: AD 0D 7C     LDA $7C0D
C2/5427: 8D C1 3C     STA $3CC1
C2/542A: AD 0B 7C     LDA $7C0B
C2/542D: 0D 0C 7C     ORA $7C0C
C2/5430: 0D 0D 7C     ORA $7C0D
C2/5433: F0 06        BEQ $543B
C2/5435: A9 2C        LDA #$2C
C2/5437: 9D 5F 3C     STA $3C5F,X
C2/543A: E8           INX 
C2/543B: AD 0E 7C     LDA $7C0E
C2/543E: 8D C2 3C     STA $3CC2
C2/5441: AD 0F 7C     LDA $7C0F
C2/5444: 8D C3 3C     STA $3CC3
C2/5447: AD 10 7C     LDA $7C10
C2/544A: 8D C4 3C     STA $3CC4
C2/544D: AD 0E 7C     LDA $7C0E
C2/5450: 0D 0F 7C     ORA $7C0F
C2/5453: 0D 10 7C     ORA $7C10
C2/5456: F0 06        BEQ $545E
C2/5458: A9 2D        LDA #$2D
C2/545A: 9D 5F 3C     STA $3C5F,X
C2/545D: E8           INX 
C2/545E: AD F1 3E     LDA $3EF1
C2/5461: F0 15        BEQ $5478
C2/5463: 8D C5 3C     STA $3CC5
C2/5466: 9C C6 3C     STZ $3CC6
C2/5469: 9C C7 3C     STZ $3CC7
C2/546C: 20 74 56     JSR $5674
C2/546F: A5 0E        LDA $0E
C2/5471: D0 05        BNE $5478
C2/5473: A9 2E        LDA #$2E
C2/5475: 9D 5F 3C     STA $3C5F,X
C2/5478: AD 5F 3C     LDA $3C5F
C2/547B: C9 FF        CMP #$FF
C2/547D: F0 0A        BEQ $5489
C2/547F: A9 0A        LDA #$0A
C2/5481: 20 69 00     JSR $0069       ; execute battle graphics function
C2/5484: A9 FF        LDA #$FF
C2/5486: 8D 60 3C     STA $3C60
C2/5489: AD 20 7C     LDA $7C20
C2/548C: F0 52        BEQ $54E0
C2/548E: 7B           TDC 
C2/548F: AA           TAX 
C2/5490: 86 3D        STX $3D
C2/5492: A6 3D        LDX $3D
C2/5494: BD 21 7C     LDA $7C21,X
C2/5497: F0 47        BEQ $54E0
C2/5499: C9 82        CMP #$82
C2/549B: 90 43        BCC $54E0
C2/549D: C9 A0        CMP #$A0
C2/549F: B0 3F        BCS $54E0
C2/54A1: 8D BF 3C     STA $3CBF
C2/54A4: 9C C0 3C     STZ $3CC0
C2/54A7: 9C C1 3C     STZ $3CC1
C2/54AA: 64 0E        STZ $0E
C2/54AC: 4A           LSR 
C2/54AD: 66 0E        ROR $0E
C2/54AF: 4A           LSR 
C2/54B0: 66 0E        ROR $0E
C2/54B2: 4A           LSR 
C2/54B3: 66 0E        ROR $0E
C2/54B5: A8           TAY 
C2/54B6: A5 0E        LDA $0E
C2/54B8: 20 BD 01     JSR $01BD       ; a >> 5
C2/54BB: AA           TAX 
C2/54BC: B9 50 09     LDA $0950,Y     ; spells known
C2/54BF: 20 DB 01     JSR $01DB       ; check bit x
C2/54C2: D0 18        BNE $54DC
C2/54C4: B9 50 09     LDA $0950,Y
C2/54C7: 20 D6 01     JSR $01D6       ; set bit x
C2/54CA: 99 50 09     STA $0950,Y
C2/54CD: A9 01        LDA #$01
C2/54CF: 20 47 58     JSR $5847
C2/54D2: A9 32        LDA #$32
C2/54D4: 8D 5F 3C     STA $3C5F
C2/54D7: A9 0A        LDA #$0A
C2/54D9: 20 69 00     JSR $0069       ; execute battle graphics function
C2/54DC: E6 3D        INC $3D
C2/54DE: 80 B2        BRA $5492
C2/54E0: 7B           TDC 
C2/54E1: AA           TAX 
C2/54E2: 86 3D        STX $3D
C2/54E4: 86 3F        STX $3F
C2/54E6: A5 3D        LDA $3D
C2/54E8: A8           TAY 
C2/54E9: B9 C2 3E     LDA $3EC2,Y
C2/54EC: F0 5E        BEQ $554C
C2/54EE: A6 3F        LDX $3F
C2/54F0: BD 02 20     LDA $2002,X
C2/54F3: C9 63        CMP #$63
C2/54F5: B0 55        BCS $554C
C2/54F7: AA           TAX 
C2/54F8: 86 0E        STX $0E
C2/54FA: C2 20        REP #$20
C2/54FC: A5 0E        LDA $0E
C2/54FE: 0A           ASL 
C2/54FF: 85 10        STA $10
C2/5501: 18           CLC 
C2/5502: 65 0E        ADC $0E
C2/5504: AA           TAX 
C2/5505: BF 00 50 D1  LDA $D15000,X
C2/5509: 85 0E        STA $0E
C2/550B: 7B           TDC 
C2/550C: E2 20        SEP #$20
C2/550E: BF 02 50 D1  LDA $D15002,X
C2/5512: 85 12        STA $12
C2/5514: A6 3F        LDX $3F
C2/5516: 38           SEC 
C2/5517: BD 03 20     LDA $2003,X
C2/551A: E5 0E        SBC $0E
C2/551C: BD 04 20     LDA $2004,X
C2/551F: E5 0F        SBC $0F
C2/5521: BD 05 20     LDA $2005,X
C2/5524: E5 12        SBC $12
C2/5526: 90 24        BCC $554C
C2/5528: 20 EC 56     JSR $56EC
C2/552B: A6 3F        LDX $3F
C2/552D: FE 02 20     INC $2002,X
C2/5530: A6 3F        LDX $3F
C2/5532: BD 00 20     LDA $2000,X
C2/5535: 29 07        AND #$07
C2/5537: 8D BF 3C     STA $3CBF
C2/553A: 9C C0 3C     STZ $3CC0
C2/553D: 9C C1 3C     STZ $3CC1
C2/5540: A9 2F        LDA #$2F
C2/5542: 8D 5F 3C     STA $3C5F
C2/5545: A9 0A        LDA #$0A
C2/5547: 20 69 00     JSR $0069       ; execute battle graphics function
C2/554A: 80 9A        BRA $54E6
C2/554C: A6 3F        LDX $3F
C2/554E: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5551: 86 3F        STX $3F
C2/5553: E6 3D        INC $3D
C2/5555: A5 3D        LDA $3D
C2/5557: C9 04        CMP #$04
C2/5559: D0 8B        BNE $54E6
C2/555B: 7B           TDC 
C2/555C: AA           TAX 
C2/555D: 86 3D        STX $3D
C2/555F: 86 3F        STX $3F
C2/5561: A9 FF        LDA #$FF
C2/5563: 8D 60 3C     STA $3C60
C2/5566: 8D 61 3C     STA $3C61
C2/5569: A5 3D        LDA $3D
C2/556B: A8           TAY 
C2/556C: B9 C2 3E     LDA $3EC2,Y
C2/556F: D0 03        BNE $5574
C2/5571: 4C 61 56     JMP $5661
C2/5574: A6 3F        LDX $3F
C2/5576: BD 3A 20     LDA $203A,X
C2/5579: 85 10        STA $10
C2/557B: BD 01 20     LDA $2001,X
C2/557E: C9 15        CMP #$15
C2/5580: F0 0C        BEQ $558E
C2/5582: AA           TAX 
C2/5583: 0A           ASL 
C2/5584: 85 0E        STA $0E
C2/5586: A5 10        LDA $10
C2/5588: DF EA 52 D1  CMP $D152EA,X
C2/558C: D0 03        BNE $5591
C2/558E: 4C 61 56     JMP $5661
C2/5591: A5 0E        LDA $0E
C2/5593: AA           TAX 
C2/5594: BF C0 52 D1  LDA $D152C0,X
C2/5598: 85 12        STA $12
C2/559A: BF C1 52 D1  LDA $D152C1,X
C2/559E: 85 13        STA $13
C2/55A0: A9 D1        LDA #$D1
C2/55A2: 85 14        STA $14
C2/55A4: A5 10        LDA $10
C2/55A6: 0A           ASL 
C2/55A7: 18           CLC 
C2/55A8: 65 10        ADC $10
C2/55AA: A8           TAY 
C2/55AB: B7 12        LDA [$12],Y
C2/55AD: 85 10        STA $10
C2/55AF: C8           INY 
C2/55B0: B7 12        LDA [$12],Y
C2/55B2: 85 11        STA $11
C2/55B4: C8           INY 
C2/55B5: B7 12        LDA [$12],Y
C2/55B7: 85 12        STA $12
C2/55B9: A6 3F        LDX $3F
C2/55BB: 38           SEC 
C2/55BC: BD 3B 20     LDA $203B,X     ; abp
C2/55BF: E5 10        SBC $10
C2/55C1: BD 3C 20     LDA $203C,X
C2/55C4: E5 11        SBC $11
C2/55C6: B0 03        BCS $55CB
C2/55C8: 4C 61 56     JMP $5661
C2/55CB: 38           SEC 
C2/55CC: BD 3B 20     LDA $203B,X
C2/55CF: E5 10        SBC $10
C2/55D1: 9D 3B 20     STA $203B,X
C2/55D4: BD 3C 20     LDA $203C,X
C2/55D7: E5 11        SBC $11
C2/55D9: 9D 3C 20     STA $203C,X
C2/55DC: FE 3A 20     INC $203A,X
C2/55DF: A5 3D        LDA $3D
C2/55E1: 0A           ASL 
C2/55E2: AA           TAX 
C2/55E3: BF D3 EE D0  LDA $D0EED3,X   ; pointers to character abilities
C2/55E7: 85 0E        STA $0E
C2/55E9: BF D4 EE D0  LDA $D0EED4,X
C2/55ED: 85 0F        STA $0F
C2/55EF: A5 12        LDA $12
C2/55F1: 10 05        BPL $55F8       ; branch if a battle command
C2/55F3: 29 7F        AND #$7F
C2/55F5: 18           CLC 
C2/55F6: 69 4E        ADC #$4E        ; innate abilities add $4E
C2/55F8: 0A           ASL 
C2/55F9: AA           TAX 
C2/55FA: BF 00 EC D0  LDA $D0EC00,X   ; byte index
C2/55FE: A8           TAY 
C2/55FF: BF 01 EC D0  LDA $D0EC01,X   ; bit index
C2/5603: AA           TAX 
C2/5604: B1 0E        LDA ($0E),Y
C2/5606: 20 D6 01     JSR $01D6       ; set bit x
C2/5609: 91 0E        STA ($0E),Y
C2/560B: A5 3D        LDA $3D
C2/560D: AA           TAX 
C2/560E: FE F3 08     INC $08F3,X     ; increment number of abilties
C2/5611: A6 3F        LDX $3F
C2/5613: BD 00 20     LDA $2000,X
C2/5616: 29 07        AND #$07
C2/5618: 8D BF 3C     STA $3CBF
C2/561B: 9C C0 3C     STZ $3CC0
C2/561E: 9C C1 3C     STZ $3CC1
C2/5621: A9 30        LDA #$30
C2/5623: 8D 5F 3C     STA $3C5F
C2/5626: A9 0A        LDA #$0A
C2/5628: 20 69 00     JSR $0069       ; execute battle graphics function
C2/562B: A9 31        LDA #$31
C2/562D: 8D 5F 3C     STA $3C5F
C2/5630: A5 12        LDA $12
C2/5632: 8D BF 3C     STA $3CBF
C2/5635: C9 2C        CMP #$2C
C2/5637: 90 14        BCC $564D
C2/5639: C9 4C        CMP #$4C
C2/563B: B0 10        BCS $564D
C2/563D: 38           SEC 
C2/563E: E9 2C        SBC #$2C
C2/5640: AA           TAX 
C2/5641: BF 06 EF D0  LDA $D0EF06,X
C2/5645: 8D C2 3C     STA $3CC2
C2/5648: A9 33        LDA #$33
C2/564A: 8D 5F 3C     STA $3C5F
C2/564D: 9C C0 3C     STZ $3CC0
C2/5650: 9C C1 3C     STZ $3CC1
C2/5653: 9C C3 3C     STZ $3CC3
C2/5656: 9C C4 3C     STZ $3CC4
C2/5659: A9 0A        LDA #$0A
C2/565B: 20 69 00     JSR $0069       ; execute battle graphics function
C2/565E: 4C 74 55     JMP $5574
C2/5661: A6 3F        LDX $3F
C2/5663: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5666: 86 3F        STX $3F
C2/5668: E6 3D        INC $3D
C2/566A: A5 3D        LDA $3D
C2/566C: C9 04        CMP #$04
C2/566E: F0 03        BEQ $5673
C2/5670: 4C 61 55     JMP $5561
C2/5673: 60           RTS 

; [  ]

C2/5674: DA           PHX 
C2/5675: 7B           TDC 
C2/5676: AA           TAX 
C2/5677: A8           TAY 
C2/5678: 86 0E        STX $0E
C2/567A: BD 00 20     LDA $2000,X
C2/567D: 29 40        AND #$40
C2/567F: D0 0C        BNE $568D
C2/5681: BD 01 20     LDA $2001,X
C2/5684: C9 15        CMP #$15
C2/5686: F0 05        BEQ $568D
C2/5688: B9 C2 3E     LDA $3EC2,Y
C2/568B: D0 0B        BNE $5698
C2/568D: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5690: C8           INY 
C2/5691: C0 04 00     CPY #$0004
C2/5694: D0 E4        BNE $567A
C2/5696: E6 0E        INC $0E
C2/5698: FA           PLX 
C2/5699: 60           RTS 

; [  ]

C2/569A: AD F1 04     LDA $04F1
C2/569D: F0 08        BEQ $56A7
C2/569F: AD F0 04     LDA $04F0
C2/56A2: C9 BF        CMP #$BF
C2/56A4: D0 01        BNE $56A7
C2/56A6: 60           RTS 
C2/56A7: 7B           TDC 
C2/56A8: AA           TAX 
C2/56A9: A9 FF        LDA #$FF
C2/56AB: 20 7C 00     JSR $007C       ; a = (x..a)
C2/56AE: 85 0E        STA $0E
C2/56B0: A5 3D        LDA $3D
C2/56B2: 0A           ASL 
C2/56B3: AA           TAX 
C2/56B4: C2 20        REP #$20
C2/56B6: BD 20 40     LDA $4020,X
C2/56B9: 20 B7 01     JSR $01B7       ; a << 2
C2/56BC: AA           TAX 
C2/56BD: 7B           TDC 
C2/56BE: E2 20        SEP #$20
C2/56C0: A4 3D        LDY $3D
C2/56C2: BF 03 50 D0  LDA $D05003,X
C2/56C6: F0 0C        BEQ $56D4
C2/56C8: C9 80        CMP #$80
C2/56CA: F0 08        BEQ $56D4
C2/56CC: C9 FF        CMP #$FF
C2/56CE: F0 04        BEQ $56D4
C2/56D0: 99 66 7C     STA $7C66,Y
C2/56D3: 60           RTS 
C2/56D4: A5 0E        LDA $0E
C2/56D6: C9 10        CMP #$10
C2/56D8: B0 11        BCS $56EB
C2/56DA: BF 02 50 D0  LDA $D05002,X
C2/56DE: F0 0B        BEQ $56EB
C2/56E0: C9 80        CMP #$80
C2/56E2: F0 07        BEQ $56EB
C2/56E4: C9 FF        CMP #$FF
C2/56E6: F0 03        BEQ $56EB
C2/56E8: 99 66 7C     STA $7C66,Y
C2/56EB: 60           RTS 

; [  ]

C2/56EC: A6 10        LDX $10
C2/56EE: BF 29 51 D1  LDA $D15129,X
C2/56F2: 85 0E        STA $0E
C2/56F4: 85 2A        STA $2A
C2/56F6: BF 2A 51 D1  LDA $D1512A,X
C2/56FA: 85 0F        STA $0F
C2/56FC: 85 2B        STA $2B
C2/56FE: A6 3F        LDX $3F
C2/5700: BD 26 20     LDA $2026,X
C2/5703: AA           TAX 
C2/5704: 86 2C        STX $2C
C2/5706: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/5709: A2 05 00     LDX #$0005
C2/570C: 46 31        LSR $31
C2/570E: 66 30        ROR $30
C2/5710: 66 2F        ROR $2F
C2/5712: 66 2E        ROR $2E
C2/5714: CA           DEX 
C2/5715: D0 F5        BNE $570C
C2/5717: A6 3F        LDX $3F
C2/5719: C2 20        REP #$20
C2/571B: 18           CLC 
C2/571C: A5 0E        LDA $0E
C2/571E: 65 2E        ADC $2E
C2/5720: C9 0F 27     CMP #$270F
C2/5723: 90 03        BCC $5728
C2/5725: A9 0F 27     LDA #$270F
C2/5728: 85 08        STA $08
C2/572A: A9 0F 27     LDA #$270F
C2/572D: 85 0A        STA $0A
C2/572F: 7B           TDC 
C2/5730: E2 20        SEP #$20
C2/5732: 7B           TDC 
C2/5733: A8           TAY 
C2/5734: BD 16 20     LDA $2016,X
C2/5737: C9 8E        CMP #$8E
C2/5739: B0 0F        BCS $574A
C2/573B: C9 8B        CMP #$8B
C2/573D: 90 0B        BCC $574A
C2/573F: DA           PHX 
C2/5740: A6 10        LDX $10
C2/5742: DA           PHX 
C2/5743: 20 C7 57     JSR $57C7
C2/5746: FA           PLX 
C2/5747: 86 10        STX $10
C2/5749: FA           PLX 
C2/574A: E8           INX 
C2/574B: C8           INY 
C2/574C: C0 04 00     CPY #$0004
C2/574F: D0 E3        BNE $5734
C2/5751: A6 3F        LDX $3F
C2/5753: A5 08        LDA $08
C2/5755: 9D 08 20     STA $2008,X
C2/5758: A5 09        LDA $09
C2/575A: 9D 09 20     STA $2009,X
C2/575D: A6 10        LDX $10
C2/575F: BF EF 51 D1  LDA $D151EF,X
C2/5763: 85 0E        STA $0E
C2/5765: 85 2A        STA $2A
C2/5767: BF F0 51 D1  LDA $D151F0,X
C2/576B: 85 0F        STA $0F
C2/576D: 85 2B        STA $2B
C2/576F: A6 3F        LDX $3F
C2/5771: BD 27 20     LDA $2027,X
C2/5774: AA           TAX 
C2/5775: 86 2C        STX $2C
C2/5777: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/577A: A2 05 00     LDX #$0005
C2/577D: 46 31        LSR $31
C2/577F: 66 30        ROR $30
C2/5781: 66 2F        ROR $2F
C2/5783: 66 2E        ROR $2E
C2/5785: CA           DEX 
C2/5786: D0 F5        BNE $577D
C2/5788: A6 3F        LDX $3F
C2/578A: C2 20        REP #$20
C2/578C: 18           CLC 
C2/578D: A5 0E        LDA $0E
C2/578F: 65 2E        ADC $2E
C2/5791: C9 E7 03     CMP #$03E7
C2/5794: 90 03        BCC $5799
C2/5796: A9 E7 03     LDA #$03E7
C2/5799: 85 08        STA $08
C2/579B: A9 E7 03     LDA #$03E7
C2/579E: 85 0A        STA $0A
C2/57A0: 7B           TDC 
C2/57A1: E2 20        SEP #$20
C2/57A3: 7B           TDC 
C2/57A4: A8           TAY 
C2/57A5: BD 16 20     LDA $2016,X
C2/57A8: C9 90        CMP #$90
C2/57AA: B0 07        BCS $57B3
C2/57AC: C9 8E        CMP #$8E
C2/57AE: 90 03        BCC $57B3
C2/57B0: 20 C7 57     JSR $57C7
C2/57B3: E8           INX 
C2/57B4: C8           INY 
C2/57B5: C0 04 00     CPY #$0004
C2/57B8: D0 EB        BNE $57A5
C2/57BA: A6 3F        LDX $3F
C2/57BC: A5 08        LDA $08
C2/57BE: 9D 0C 20     STA $200C,X
C2/57C1: A5 09        LDA $09
C2/57C3: 9D 0D 20     STA $200D,X
C2/57C6: 60           RTS 

; [  ]

C2/57C7: DA           PHX 
C2/57C8: 5A           PHY 
C2/57C9: 38           SEC 
C2/57CA: E9 8B        SBC #$8B
C2/57CC: AA           TAX 
C2/57CD: BF E1 57 C2  LDA $C257E1,X
C2/57D1: AA           TAX 
C2/57D2: 86 2A        STX $2A
C2/57D4: A6 08        LDX $08
C2/57D6: 86 2C        STX $2C
C2/57D8: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/57DB: 20 91 04     JSR $0491
C2/57DE: 7A           PLY 
C2/57DF: FA           PLX 
C2/57E0: 60           RTS 

C2/57E1: 0A 14 1E 0A 1E

; [  ]

C2/57E6: A6 10        LDX $10
C2/57E8: DA           PHX 
C2/57E9: A2 0F 00     LDX #$000F
C2/57EC: 74 0E        STZ $0E,X
C2/57EE: CA           DEX 
C2/57EF: 10 FB        BPL $57EC
C2/57F1: FA           PLX 
C2/57F2: 86 12        STX $12
C2/57F4: AE 0E 7C     LDX $7C0E
C2/57F7: 86 0E        STX $0E
C2/57F9: AD 10 7C     LDA $7C10
C2/57FC: 85 10        STA $10
C2/57FE: C2 20        REP #$20
C2/5800: 18           CLC 
C2/5801: A2 20 00     LDX #$0020
C2/5804: 26 0E        ROL $0E
C2/5806: 26 10        ROL $10
C2/5808: 26 1A        ROL $1A
C2/580A: 26 1C        ROL $1C
C2/580C: 38           SEC 
C2/580D: A5 1A        LDA $1A
C2/580F: E5 12        SBC $12
C2/5811: 85 1A        STA $1A
C2/5813: A5 1C        LDA $1C
C2/5815: E5 14        SBC $14
C2/5817: 85 1C        STA $1C
C2/5819: B0 0D        BCS $5828
C2/581B: A5 1A        LDA $1A
C2/581D: 65 12        ADC $12
C2/581F: 85 1A        STA $1A
C2/5821: A5 1C        LDA $1C
C2/5823: 65 14        ADC $14
C2/5825: 85 1C        STA $1C
C2/5827: 18           CLC 
C2/5828: 26 16        ROL $16
C2/582A: 26 18        ROL $18
C2/582C: CA           DEX 
C2/582D: D0 D5        BNE $5804
C2/582F: 7B           TDC 
C2/5830: E2 20        SEP #$20
C2/5832: A5 16        LDA $16
C2/5834: 05 17        ORA $17
C2/5836: 05 18        ORA $18
C2/5838: D0 02        BNE $583C
C2/583A: E6 16        INC $16
C2/583C: A6 16        LDX $16
C2/583E: 8E 0E 7C     STX $7C0E
C2/5841: A5 18        LDA $18
C2/5843: 8D 10 7C     STA $7C10
C2/5846: 60           RTS 

; [  ]

C2/5847: 8D 4F 38     STA $384F
C2/584A: 9C 4C 38     STZ $384C
C2/584D: A9 FC        LDA #$FC
C2/584F: 8D 4D 38     STA $384D
C2/5852: A9 05        LDA #$05
C2/5854: 8D 4E 38     STA $384E
C2/5857: 9C 50 38     STZ $3850
C2/585A: A9 20        LDA #$20
C2/585C: 8D CC 3B     STA $3BCC
C2/585F: 9C CD 3B     STZ $3BCD
C2/5862: 9C CE 3B     STZ $3BCE
C2/5865: 9C CF 3B     STZ $3BCF
C2/5868: 9C D0 3B     STZ $3BD0
C2/586B: 9C D1 3B     STZ $3BD1
C2/586E: 9C D2 3B     STZ $3BD2
C2/5871: 60           RTS 

; [ battle loop ]

C2/5872: 7B           TDC 
C2/5873: AA           TAX 
C2/5874: BD B0 41     LDA $41B0,X
C2/5877: 9D BE 41     STA $41BE,X
C2/587A: E8           INX 
C2/587B: E0 0E 00     CPX #$000E
C2/587E: D0 F4        BNE $5874
C2/5880: AD D8 7C     LDA $7CD8
C2/5883: D0 6C        BNE $58F1
C2/5885: EE 53 7C     INC $7C53
C2/5888: AD 53 7C     LDA $7C53
C2/588B: C9 04        CMP #$04
C2/588D: D0 08        BNE $5897
C2/588F: 9C 53 7C     STZ $7C53
C2/5892: EE 54 7C     INC $7C54
C2/5895: 80 03        BRA $589A
C2/5897: 9C 54 7C     STZ $7C54
C2/589A: AD 4E 47     LDA $474E
C2/589D: D0 06        BNE $58A5
C2/589F: 20 65 62     JSR $6265
C2/58A2: 20 41 5A     JSR $5A41
C2/58A5: 20 57 62     JSR $6257
C2/58A8: AD 4E 47     LDA $474E
C2/58AB: F0 07        BEQ $58B4
C2/58AD: AD 55 47     LDA $4755
C2/58B0: C9 04        CMP #$04
C2/58B2: 90 03        BCC $58B7
C2/58B4: 20 6C 17     JSR $176C
C2/58B7: 20 21 59     JSR $5921
C2/58BA: A9 03        LDA #$03        ; battle graphics command $03 (wait one frame)
C2/58BC: 20 69 00     JSR $0069       ; execute battle graphics function
C2/58BF: 20 B4 5A     JSR $5AB4       ; check if battle is over
C2/58C2: AD DE 7B     LDA $7BDE
C2/58C5: D0 2A        BNE $58F1       ; branch if battle terminated
C2/58C7: AD 52 7C     LDA $7C52
C2/58CA: D0 EE        BNE $58BA       ; branch if a menu is open (wait mode)
C2/58CC: 20 6C 5B     JSR $5B6C       ; update monster front/back row flags
C2/58CF: AD 4E 47     LDA $474E
C2/58D2: D0 08        BNE $58DC       ; 
C2/58D4: 20 32 24     JSR $2432       ; 
C2/58D7: D0 12        BNE $58EB
C2/58D9: 20 C4 1D     JSR $1DC4
C2/58DC: 9C 54 47     STZ $4754
C2/58DF: 20 0B 20     JSR $200B       ; decrement timers
C2/58E2: 20 B2 20     JSR $20B2
C2/58E5: 20 77 21     JSR $2177       ; check timers
C2/58E8: 20 E3 35     JSR $35E3
C2/58EB: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/58EE: 4C 72 58     JMP $5872       ; battle loop
C2/58F1: A9 03        LDA #$03        ; battle graphics command $03 (wait one frame)
C2/58F3: 20 69 00     JSR $0069       ; execute battle graphics function
C2/58F6: AD CC 41     LDA $41CC
C2/58F9: C9 FF        CMP #$FF
C2/58FB: F0 12        BEQ $590F
C2/58FD: 85 70        STA $70
C2/58FF: AD 7D 7B     LDA $7B7D
C2/5902: F0 06        BEQ $590A
C2/5904: 20 3A 9F     JSR $9F3A
C2/5907: 20 6F 9A     JSR $9A6F       ; update character equipment
C2/590A: A9 01        LDA #$01
C2/590C: 20 69 00     JSR $0069       ; execute battle graphics function
C2/590F: 20 70 50     JSR $5070
C2/5912: 7B           TDC 
C2/5913: AA           TAX 
C2/5914: BD 66 7C     LDA $7C66,X
C2/5917: 9D 3B 01     STA $013B,X     ; items won in battle
C2/591A: E8           INX 
C2/591B: E0 08 00     CPX #$0008
C2/591E: D0 F4        BNE $5914
C2/5920: 60           RTS 

; [  ]

C2/5921: 7B           TDC 
C2/5922: AA           TAX 
C2/5923: A8           TAY 
C2/5924: 86 10        STX $10
C2/5926: C2 20        REP #$20
C2/5928: 64 0E        STZ $0E
C2/592A: BD 06 20     LDA $2006,X     ; current/max hp/mp
C2/592D: 99 2C 38     STA $382C,Y
C2/5930: E8           INX 
C2/5931: E8           INX 
C2/5932: C8           INY 
C2/5933: C8           INY 
C2/5934: E6 0E        INC $0E
C2/5936: A5 0E        LDA $0E
C2/5938: C9 04 00     CMP #$0004
C2/593B: D0 ED        BNE $592A
C2/593D: 18           CLC 
C2/593E: 8A           TXA 
C2/593F: 69 78 00     ADC #$0078
C2/5942: AA           TAX 
C2/5943: C0 20 00     CPY #$0020
C2/5946: D0 E0        BNE $5928
C2/5948: 7B           TDC 
C2/5949: E2 20        SEP #$20
C2/594B: AD EF 3E     LDA $3EEF
C2/594E: 10 03        BPL $5953
C2/5950: 4C E7 59     JMP $59E7
C2/5953: 7B           TDC 
C2/5954: AA           TAX 
C2/5955: A8           TAY 
C2/5956: 64 0E        STZ $0E
C2/5958: DA           PHX 
C2/5959: 5A           PHY 
C2/595A: BD 1A 20     LDA $201A,X
C2/595D: 1D 70 20     ORA $2070,X
C2/5960: 29 02        AND #$02
C2/5962: D0 24        BNE $5988
C2/5964: BD 1B 20     LDA $201B,X
C2/5967: 1D 71 20     ORA $2071,X
C2/596A: 29 78        AND #$78
C2/596C: D0 1A        BNE $5988
C2/596E: BD 1D 20     LDA $201D,X
C2/5971: 29 04        AND #$04
C2/5973: D0 13        BNE $5988
C2/5975: A5 0E        LDA $0E
C2/5977: AA           TAX 
C2/5978: 20 07 02     JSR $0207       ; get timer data offset
C2/597B: B9 FB 3C     LDA $3CFB,Y
C2/597E: 29 40        AND #$40
C2/5980: D0 06        BNE $5988
C2/5982: B9 7F 3D     LDA $3D7F,Y
C2/5985: 9D D0 3E     STA $3ED0,X
C2/5988: 7A           PLY 
C2/5989: FA           PLX 
C2/598A: BD 1A 20     LDA $201A,X
C2/598D: 1D 70 20     ORA $2070,X
C2/5990: 99 7E 7B     STA $7B7E,Y
C2/5993: BD 1B 20     LDA $201B,X
C2/5996: 1D 71 20     ORA $2071,X
C2/5999: 85 10        STA $10
C2/599B: 29 08        AND #$08
C2/599D: F0 0D        BEQ $59AC
C2/599F: BD 01 20     LDA $2001,X
C2/59A2: C9 06        CMP #$06
C2/59A4: D0 06        BNE $59AC
C2/59A6: A5 10        LDA $10
C2/59A8: 29 F7        AND #$F7
C2/59AA: 85 10        STA $10
C2/59AC: BD 1D 20     LDA $201D,X
C2/59AF: 1D 73 20     ORA $2073,X
C2/59B2: 99 81 7B     STA $7B81,Y
C2/59B5: 29 80        AND #$80
C2/59B7: F0 0F        BEQ $59C8
C2/59B9: 99 81 7B     STA $7B81,Y
C2/59BC: 7B           TDC 
C2/59BD: 99 7E 7B     STA $7B7E,Y
C2/59C0: 99 7F 7B     STA $7B7F,Y
C2/59C3: 99 80 7B     STA $7B80,Y
C2/59C6: 80 0E        BRA $59D6
C2/59C8: A5 10        LDA $10
C2/59CA: 99 7F 7B     STA $7B7F,Y
C2/59CD: BD 1C 20     LDA $201C,X
C2/59D0: 1D 72 20     ORA $2072,X
C2/59D3: 99 80 7B     STA $7B80,Y
C2/59D6: E6 0E        INC $0E
C2/59D8: C8           INY 
C2/59D9: C8           INY 
C2/59DA: C8           INY 
C2/59DB: C8           INY 
C2/59DC: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/59DF: C0 10 00     CPY #$0010
C2/59E2: F0 03        BEQ $59E7
C2/59E4: 4C 58 59     JMP $5958
C2/59E7: A0 04 00     LDY #$0004
C2/59EA: 84 0E        STY $0E
C2/59EC: 7B           TDC 
C2/59ED: A8           TAY 
C2/59EE: 5A           PHY 
C2/59EF: A4 0E        LDY $0E
C2/59F1: B9 C2 3E     LDA $3EC2,Y
C2/59F4: D0 17        BNE $5A0D
C2/59F6: 7A           PLY 
C2/59F7: B9 9E 7B     LDA $7B9E,Y
C2/59FA: 29 30        AND #$30
C2/59FC: 09 80        ORA #$80
C2/59FE: 99 9E 7B     STA $7B9E,Y
C2/5A01: 7B           TDC 
C2/5A02: 99 9F 7B     STA $7B9F,Y
C2/5A05: 99 A0 7B     STA $7BA0,Y
C2/5A08: 99 A1 7B     STA $7BA1,Y
C2/5A0B: 80 25        BRA $5A32
C2/5A0D: 7A           PLY 
C2/5A0E: BD 1A 20     LDA $201A,X
C2/5A11: 1D 70 20     ORA $2070,X
C2/5A14: 99 9E 7B     STA $7B9E,Y
C2/5A17: BD 1B 20     LDA $201B,X
C2/5A1A: 1D 71 20     ORA $2071,X
C2/5A1D: 99 9F 7B     STA $7B9F,Y
C2/5A20: BD 1C 20     LDA $201C,X
C2/5A23: 1D 72 20     ORA $2072,X
C2/5A26: 99 A0 7B     STA $7BA0,Y
C2/5A29: BD 1D 20     LDA $201D,X
C2/5A2C: 1D 73 20     ORA $2073,X
C2/5A2F: 99 A1 7B     STA $7BA1,Y
C2/5A32: E6 0E        INC $0E
C2/5A34: C8           INY 
C2/5A35: C8           INY 
C2/5A36: C8           INY 
C2/5A37: C8           INY 
C2/5A38: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5A3B: C0 20 00     CPY #$0020
C2/5A3E: D0 AE        BNE $59EE
C2/5A40: 60           RTS 

; [  ]

C2/5A41: 7B           TDC 
C2/5A42: AA           TAX 
C2/5A43: A8           TAY 
C2/5A44: 8E 38 40     STX $4038
C2/5A47: 8E 3A 40     STX $403A
C2/5A4A: 8E 3C 40     STX $403C
C2/5A4D: 8E 3E 40     STX $403E
C2/5A50: 8E 40 40     STX $4040
C2/5A53: 8E 42 40     STX $4042
C2/5A56: 8E 44 40     STX $4044
C2/5A59: 8E 46 40     STX $4046
C2/5A5C: 9C 48 40     STZ $4048
C2/5A5F: 86 10        STX $10
C2/5A61: 88           DEY 
C2/5A62: 84 0E        STY $0E
C2/5A64: 88           DEY 
C2/5A65: 88           DEY 
C2/5A66: 88           DEY 
C2/5A67: A6 10        LDX $10
C2/5A69: BD C6 3E     LDA $3EC6,X
C2/5A6C: F0 3D        BEQ $5AAB
C2/5A6E: AD 48 40     LDA $4048
C2/5A71: 20 D6 01     JSR $01D6       ; set bit x
C2/5A74: 8D 48 40     STA $4048
C2/5A77: 8A           TXA 
C2/5A78: 18           CLC 
C2/5A79: 69 04        ADC #$04
C2/5A7B: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/5A7E: BD 1A 20     LDA $201A,X
C2/5A81: 1D 70 20     ORA $2070,X
C2/5A84: 29 30        AND #$30
C2/5A86: D0 23        BNE $5AAB
C2/5A88: A5 10        LDA $10
C2/5A8A: 0A           ASL 
C2/5A8B: AA           TAX 
C2/5A8C: BD 08 40     LDA $4008,X     ; monster id
C2/5A8F: C5 0E        CMP $0E
C2/5A91: F0 0F        BEQ $5AA2
C2/5A93: C8           INY 
C2/5A94: C8           INY 
C2/5A95: C8           INY 
C2/5A96: C8           INY 
C2/5A97: 99 38 40     STA $4038,Y
C2/5A9A: 85 0E        STA $0E
C2/5A9C: AD 21 40     LDA $4021
C2/5A9F: 99 39 40     STA $4039,Y
C2/5AA2: 18           CLC 
C2/5AA3: B9 3A 40     LDA $403A,Y
C2/5AA6: 69 01        ADC #$01
C2/5AA8: 99 3A 40     STA $403A,Y
C2/5AAB: E6 10        INC $10
C2/5AAD: A5 10        LDA $10
C2/5AAF: C9 08        CMP #$08
C2/5AB1: D0 B4        BNE $5A67
C2/5AB3: 60           RTS 

; [ check if battle is over ]

C2/5AB4: 7B           TDC 
C2/5AB5: AA           TAX 
C2/5AB6: A8           TAY 
C2/5AB7: AD DE 7B     LDA $7BDE       ; return if battle is already terminating
C2/5ABA: F0 01        BEQ $5ABD
C2/5ABC: 60           RTS 
C2/5ABD: AD 94 7C     LDA $7C94
C2/5AC0: C9 02        CMP #$02
C2/5AC2: D0 0E        BNE $5AD2
C2/5AC4: AD 95 7C     LDA $7C95
C2/5AC7: 0D 96 7C     ORA $7C96
C2/5ACA: D0 06        BNE $5AD2
C2/5ACC: A9 20        LDA #$20
C2/5ACE: 8D DE 7B     STA $7BDE
C2/5AD1: 60           RTS 
C2/5AD2: B9 C2 3E     LDA $3EC2,Y
C2/5AD5: F0 0A        BEQ $5AE1       ; branch if no target
C2/5AD7: BD 1A 20     LDA $201A,X
C2/5ADA: 1D 70 20     ORA $2070,X
C2/5ADD: 29 02        AND #$02
C2/5ADF: F0 0F        BEQ $5AF0       ; branch if not zombie
C2/5AE1: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5AE4: C8           INY 
C2/5AE5: C0 04 00     CPY #$0004
C2/5AE8: D0 E8        BNE $5AD2
C2/5AEA: A9 40        LDA #$40
C2/5AEC: 8D DE 7B     STA $7BDE
C2/5AEF: 60           RTS 
C2/5AF0: B9 C2 3E     LDA $3EC2,Y
C2/5AF3: F0 07        BEQ $5AFC
C2/5AF5: BD 1D 20     LDA $201D,X
C2/5AF8: 29 01        AND #$01
C2/5AFA: F0 0E        BEQ $5B0A       ; branch if not hidden
C2/5AFC: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5AFF: C8           INY 
C2/5B00: C0 04 00     CPY #$0004
C2/5B03: D0 EB        BNE $5AF0
C2/5B05: AD F0 3E     LDA $3EF0
C2/5B08: 10 58        BPL $5B62
C2/5B0A: A0 04 00     LDY #$0004
C2/5B0D: A2 00 02     LDX #$0200
C2/5B10: B9 C2 3E     LDA $3EC2,Y
C2/5B13: F0 0A        BEQ $5B1F
C2/5B15: BD 1A 20     LDA $201A,X
C2/5B18: 1D 70 20     ORA $2070,X
C2/5B1B: 29 02        AND #$02
C2/5B1D: F0 0F        BEQ $5B2E       ; branch if not zombie
C2/5B1F: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/5B22: C8           INY 
C2/5B23: C0 0C 00     CPY #$000C
C2/5B26: D0 E8        BNE $5B10
C2/5B28: A9 80        LDA #$80
C2/5B2A: 8D DE 7B     STA $7BDE
C2/5B2D: 60           RTS 
C2/5B2E: AD 4E 7C     LDA $7C4E
C2/5B31: F0 35        BEQ $5B68
C2/5B33: AD E8 7B     LDA $7BE8
C2/5B36: 30 2A        BMI $5B62
C2/5B38: F0 2E        BEQ $5B68
C2/5B3A: AD F0 3E     LDA $3EF0
C2/5B3D: 10 11        BPL $5B50
C2/5B3F: 20 18 02     JSR $0218       ; reset battle graphics parameters
C2/5B42: 7B           TDC 
C2/5B43: 20 47 58     JSR $5847
C2/5B46: A9 20        LDA #$20        ; "Can't Run!!"
C2/5B48: 8D 5F 3C     STA $3C5F
C2/5B4B: A9 0A        LDA #$0A
C2/5B4D: 4C 69 00     JMP $0069       ; execute battle graphics function
C2/5B50: EE 5F 7C     INC $7C5F
C2/5B53: AD 5F 7C     LDA $7C5F
C2/5B56: C9 14        CMP #$14
C2/5B58: D0 11        BNE $5B6B
C2/5B5A: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/5B5D: CD F0 3E     CMP $3EF0
C2/5B60: B0 06        BCS $5B68
C2/5B62: A9 01        LDA #$01
C2/5B64: 8D DE 7B     STA $7BDE
C2/5B67: 60           RTS 
C2/5B68: 9C 5F 7C     STZ $7C5F
C2/5B6B: 60           RTS 

; [ update monster front/back row flags ]

C2/5B6C: A9 0B        LDA #$0B
C2/5B6E: 20 69 00     JSR $0069       ; execute battle graphics function
C2/5B71: 7B           TDC 
C2/5B72: AA           TAX 
C2/5B73: A0 00 02     LDY #$0200
C2/5B76: B9 00 20     LDA $2000,Y     ; put all monsters in front row
C2/5B79: 29 7F        AND #$7F
C2/5B7B: 99 00 20     STA $2000,Y
C2/5B7E: A5 70        LDA $70
C2/5B80: 20 DB 01     JSR $01DB       ; check bit x
C2/5B83: D0 08        BNE $5B8D
C2/5B85: B9 00 20     LDA $2000,Y     ; put monster in back row
C2/5B88: 09 80        ORA #$80
C2/5B8A: 99 00 20     STA $2000,Y
C2/5B8D: C2 20        REP #$20
C2/5B8F: 98           TYA 
C2/5B90: 18           CLC 
C2/5B91: 69 80 00     ADC #$0080
C2/5B94: A8           TAY 
C2/5B95: 7B           TDC 
C2/5B96: E2 20        SEP #$20
C2/5B98: E8           INX 
C2/5B99: E0 08 00     CPX #$0008
C2/5B9C: D0 D8        BNE $5B76
C2/5B9E: 60           RTS 

; [ battle command $27/$28/$2C: magic ]

C2/5B9F: A5 47        LDA $47
C2/5BA1: C9 04        CMP #$04
C2/5BA3: 90 03        BCC $5BA8
C2/5BA5: 4C 50 5C     JMP $5C50
C2/5BA8: 64 20        STZ $20
C2/5BAA: 64 21        STZ $21
C2/5BAC: A6 32        LDX $32
C2/5BAE: BD 58 20     LDA $2058,X
C2/5BB1: 85 65        STA $65
C2/5BB3: BD 59 20     LDA $2059,X
C2/5BB6: 85 66        STA $66
C2/5BB8: BD 5A 20     LDA $205A,X
C2/5BBB: 8D 22 27     STA $2722
C2/5BBE: BD 56 20     LDA $2056,X
C2/5BC1: 29 08        AND #$08
C2/5BC3: F0 27        BEQ $5BEC
C2/5BC5: A5 66        LDA $66
C2/5BC7: F0 23        BEQ $5BEC
C2/5BC9: BD 59 20     LDA $2059,X
C2/5BCC: DD 5E 20     CMP $205E,X
C2/5BCF: D0 1B        BNE $5BEC
C2/5BD1: AD 22 27     LDA $2722
C2/5BD4: C9 19        CMP #$19
C2/5BD6: F0 11        BEQ $5BE9
C2/5BD8: C9 21        CMP #$21
C2/5BDA: F0 0D        BEQ $5BE9
C2/5BDC: C9 54        CMP #$54
C2/5BDE: F0 09        BEQ $5BE9
C2/5BE0: C9 1D        CMP #$1D
C2/5BE2: D0 08        BNE $5BEC
C2/5BE4: EE 98 7C     INC $7C98
C2/5BE7: 80 03        BRA $5BEC
C2/5BE9: EE 99 7C     INC $7C99
C2/5BEC: 9C 23 27     STZ $2723
C2/5BEF: 20 E1 5C     JSR $5CE1
C2/5BF2: A5 20        LDA $20
C2/5BF4: F0 15        BEQ $5C0B
C2/5BF6: A5 20        LDA $20
C2/5BF8: 8D 22 27     STA $2722
C2/5BFB: 9C 23 27     STZ $2723
C2/5BFE: A5 23        LDA $23
C2/5C00: 85 65        STA $65
C2/5C02: A5 22        LDA $22
C2/5C04: 85 66        STA $66
C2/5C06: E6 21        INC $21
C2/5C08: 20 E1 5C     JSR $5CE1
C2/5C0B: A6 32        LDX $32
C2/5C0D: BD 56 20     LDA $2056,X
C2/5C10: 29 08        AND #$08
C2/5C12: F0 33        BEQ $5C47
C2/5C14: 64 20        STZ $20
C2/5C16: 64 21        STZ $21
C2/5C18: BD 5D 20     LDA $205D,X
C2/5C1B: 85 65        STA $65
C2/5C1D: BD 5E 20     LDA $205E,X
C2/5C20: 85 66        STA $66
C2/5C22: BD 5F 20     LDA $205F,X
C2/5C25: 8D 22 27     STA $2722
C2/5C28: 9C 23 27     STZ $2723
C2/5C2B: 20 E1 5C     JSR $5CE1
C2/5C2E: A5 20        LDA $20
C2/5C30: F0 15        BEQ $5C47
C2/5C32: A5 20        LDA $20
C2/5C34: 8D 22 27     STA $2722
C2/5C37: 9C 23 27     STZ $2723
C2/5C3A: A5 23        LDA $23
C2/5C3C: 85 65        STA $65
C2/5C3E: A5 22        LDA $22
C2/5C40: 85 66        STA $66
C2/5C42: E6 21        INC $21
C2/5C44: 20 E1 5C     JSR $5CE1
C2/5C47: 9C 99 7C     STZ $7C99
C2/5C4A: 9C 98 7C     STZ $7C98
C2/5C4D: 4C E0 5C     JMP $5CE0
C2/5C50: 38           SEC 
C2/5C51: A5 47        LDA $47
C2/5C53: E9 04        SBC #$04
C2/5C55: 0A           ASL 
C2/5C56: AA           TAX 
C2/5C57: BF 95 EE D0  LDA $D0EE95,X
C2/5C5B: 85 0E        STA $0E
C2/5C5D: BF 96 EE D0  LDA $D0EE96,X
C2/5C61: 85 0F        STA $0F
C2/5C63: 7B           TDC 
C2/5C64: A8           TAY 
C2/5C65: A6 0E        LDX $0E
C2/5C67: BD 67 43     LDA $4367,X
C2/5C6A: 99 4C 38     STA $384C,Y
C2/5C6D: E8           INX 
C2/5C6E: C8           INY 
C2/5C6F: C0 64 00     CPY #$0064
C2/5C72: D0 F3        BNE $5C67
C2/5C74: EE 03 7C     INC $7C03
C2/5C77: 64 1E        STZ $1E
C2/5C79: 38           SEC 
C2/5C7A: A5 47        LDA $47
C2/5C7C: E9 04        SBC #$04
C2/5C7E: 20 B5 01     JSR $01B5       ; a << 4
C2/5C81: AA           TAX 
C2/5C82: 86 0E        STX $0E
C2/5C84: C2 20        REP #$20
C2/5C86: 18           CLC 
C2/5C87: 69 DE 41     ADC #$41DE
C2/5C8A: AA           TAX 
C2/5C8B: 86 3D        STX $3D
C2/5C8D: A5 0E        LDA $0E
C2/5C8F: 0A           ASL 
C2/5C90: 18           CLC 
C2/5C91: 69 5E 42     ADC #$425E
C2/5C94: AA           TAX 
C2/5C95: 86 3F        STX $3F
C2/5C97: 7B           TDC 
C2/5C98: E2 20        SEP #$20
C2/5C9A: A5 1E        LDA $1E
C2/5C9C: A8           TAY 
C2/5C9D: B1 3D        LDA ($3D),Y
C2/5C9F: C9 FF        CMP #$FF
C2/5CA1: F0 3D        BEQ $5CE0
C2/5CA3: 8D 22 27     STA $2722
C2/5CA6: C9 E9        CMP #$E9
C2/5CA8: D0 03        BNE $5CAD
C2/5CAA: EE FB 7B     INC $7BFB
C2/5CAD: AD 22 27     LDA $2722
C2/5CB0: C9 A8        CMP #$A8
C2/5CB2: D0 03        BNE $5CB7
C2/5CB4: EE 9C 7C     INC $7C9C
C2/5CB7: AD 22 27     LDA $2722
C2/5CBA: C9 83        CMP #$83
C2/5CBC: D0 03        BNE $5CC1
C2/5CBE: EE 9D 7C     INC $7C9D
C2/5CC1: 64 20        STZ $20
C2/5CC3: 64 21        STZ $21
C2/5CC5: A5 1E        LDA $1E
C2/5CC7: 0A           ASL 
C2/5CC8: A8           TAY 
C2/5CC9: B1 3F        LDA ($3F),Y
C2/5CCB: 85 66        STA $66
C2/5CCD: C8           INY 
C2/5CCE: B1 3F        LDA ($3F),Y
C2/5CD0: 85 65        STA $65
C2/5CD2: 9C 23 27     STZ $2723
C2/5CD5: 20 E1 5C     JSR $5CE1
C2/5CD8: E6 1E        INC $1E
C2/5CDA: A5 1E        LDA $1E
C2/5CDC: C9 10        CMP #$10
C2/5CDE: D0 BA        BNE $5C9A
C2/5CE0: 60           RTS 

; [  ]

C2/5CE1: AD 23 27     LDA $2723
C2/5CE4: D0 24        BNE $5D0A
C2/5CE6: AD 22 27     LDA $2722
C2/5CE9: C9 F1        CMP #$F1
C2/5CEB: D0 02        BNE $5CEF
C2/5CED: A9 78        LDA #$78
C2/5CEF: C2 20        REP #$20
C2/5CF1: 20 B6 01     JSR $01B6       ; a << 3
C2/5CF4: AA           TAX 
C2/5CF5: 7B           TDC 
C2/5CF6: E2 20        SEP #$20
C2/5CF8: 7B           TDC 
C2/5CF9: A8           TAY 
C2/5CFA: BF 80 0B D1  LDA $D10B80,X
C2/5CFE: 99 2A 26     STA $262A,Y
C2/5D01: E8           INX 
C2/5D02: C8           INY 
C2/5D03: C0 08 00     CPY #$0008
C2/5D06: D0 F2        BNE $5CFA
C2/5D08: 80 1C        BRA $5D26
C2/5D0A: AD 22 27     LDA $2722
C2/5D0D: C2 20        REP #$20
C2/5D0F: 20 B6 01     JSR $01B6       ; a << 3
C2/5D12: AA           TAX 
C2/5D13: 7B           TDC 
C2/5D14: E2 20        SEP #$20
C2/5D16: 7B           TDC 
C2/5D17: A8           TAY 
C2/5D18: BF B1 6A D1  LDA $D16AB1,X
C2/5D1C: 99 2A 26     STA $262A,Y
C2/5D1F: E8           INX 
C2/5D20: C8           INY 
C2/5D21: C0 08 00     CPY #$0008
C2/5D24: D0 F2        BNE $5D18
C2/5D26: AD 23 27     LDA $2723
C2/5D29: D0 0E        BNE $5D39
C2/5D2B: AD 22 27     LDA $2722
C2/5D2E: C9 48        CMP #$48
C2/5D30: 90 07        BCC $5D39
C2/5D32: C9 57        CMP #$57
C2/5D34: B0 03        BCS $5D39
C2/5D36: 20 A3 60     JSR $60A3
C2/5D39: 20 23 99     JSR $9923
C2/5D3C: 7B           TDC 
C2/5D3D: AA           TAX 
C2/5D3E: BD 2A 26     LDA $262A,X
C2/5D41: 99 FC 79     STA $79FC,Y
C2/5D44: E8           INX 
C2/5D45: C8           INY 
C2/5D46: E0 05 00     CPX #$0005
C2/5D49: D0 F3        BNE $5D3E
C2/5D4B: C8           INY 
C2/5D4C: C8           INY 
C2/5D4D: C8           INY 
C2/5D4E: C8           INY 
C2/5D4F: BD 2A 26     LDA $262A,X
C2/5D52: 99 FC 79     STA $79FC,Y
C2/5D55: E8           INX 
C2/5D56: C8           INY 
C2/5D57: E0 08 00     CPX #$0008
C2/5D5A: D0 F3        BNE $5D4F
C2/5D5C: AD 2C 26     LDA $262C
C2/5D5F: 29 07        AND #$07
C2/5D61: F0 04        BEQ $5D67
C2/5D63: 20 75 5F     JSR $5F75
C2/5D66: 60           RTS 
C2/5D67: 20 C2 02     JSR $02C2
C2/5D6A: D0 3F        BNE $5DAB
C2/5D6C: AD 2E 26     LDA $262E
C2/5D6F: 10 0B        BPL $5D7C
C2/5D71: AD FA 79     LDA $79FA
C2/5D74: AA           TAX 
C2/5D75: A9 01        LDA #$01
C2/5D77: 9D EB 7B     STA $7BEB,X
C2/5D7A: 80 4A        BRA $5DC6
C2/5D7C: AD 99 7C     LDA $7C99
C2/5D7F: D0 13        BNE $5D94
C2/5D81: AD 98 7C     LDA $7C98
C2/5D84: F0 16        BEQ $5D9C
C2/5D86: 20 4E 61     JSR $614E
C2/5D89: BD 1A 20     LDA $201A,X
C2/5D8C: 30 0E        BMI $5D9C
C2/5D8E: 29 40        AND #$40
C2/5D90: D0 DF        BNE $5D71
C2/5D92: 80 08        BRA $5D9C
C2/5D94: 20 4E 61     JSR $614E
C2/5D97: BD 1A 20     LDA $201A,X
C2/5D9A: 30 D5        BMI $5D71
C2/5D9C: 20 FE 4A     JSR $4AFE
C2/5D9F: AD 29 7C     LDA $7C29
C2/5DA2: F0 22        BEQ $5DC6
C2/5DA4: A9 F1        LDA #$F1
C2/5DA6: 8D 22 27     STA $2722
C2/5DA9: 80 1B        BRA $5DC6
C2/5DAB: AD 2E 26     LDA $262E
C2/5DAE: 10 0B        BPL $5DBB
C2/5DB0: AD FA 79     LDA $79FA
C2/5DB3: AA           TAX 
C2/5DB4: A9 01        LDA #$01
C2/5DB6: 9D EB 7B     STA $7BEB,X
C2/5DB9: 80 0B        BRA $5DC6
C2/5DBB: 20 CF 02     JSR $02CF
C2/5DBE: AD 29 7C     LDA $7C29
C2/5DC1: D0 E1        BNE $5DA4
C2/5DC3: 20 C2 02     JSR $02C2
C2/5DC6: 20 A9 02     JSR $02A9
C2/5DC9: AD 23 27     LDA $2723
C2/5DCC: D0 31        BNE $5DFF
C2/5DCE: AD 22 27     LDA $2722
C2/5DD1: C9 80        CMP #$80
C2/5DD3: F0 04        BEQ $5DD9
C2/5DD5: C9 DE        CMP #$DE
C2/5DD7: D0 1C        BNE $5DF5
C2/5DD9: 20 FA 98     JSR $98FA       ; create graphics command
C2/5DDC: 9E 4C 38     STZ $384C,X
C2/5DDF: A9 FC        LDA #$FC
C2/5DE1: 9D 4D 38     STA $384D,X
C2/5DE4: A9 01        LDA #$01
C2/5DE6: 9D 4E 38     STA $384E,X
C2/5DE9: A9 04        LDA #$04
C2/5DEB: 9D 4F 38     STA $384F,X
C2/5DEE: 7B           TDC 
C2/5DEF: 9D 50 38     STA $3850,X
C2/5DF2: 4C BE 5E     JMP $5EBE
C2/5DF5: AD 22 27     LDA $2722
C2/5DF8: C9 F1        CMP #$F1
C2/5DFA: D0 03        BNE $5DFF
C2/5DFC: 4C BE 5E     JMP $5EBE
C2/5DFF: A5 21        LDA $21
C2/5E01: D0 2C        BNE $5E2F
C2/5E03: AD 23 27     LDA $2723
C2/5E06: D0 47        BNE $5E4F
C2/5E08: AD 22 27     LDA $2722
C2/5E0B: C9 82        CMP #$82
C2/5E0D: 90 40        BCC $5E4F
C2/5E0F: 64 0E        STZ $0E
C2/5E11: 38           SEC 
C2/5E12: E9 80        SBC #$80
C2/5E14: 4A           LSR 
C2/5E15: 66 0E        ROR $0E
C2/5E17: 4A           LSR 
C2/5E18: 66 0E        ROR $0E
C2/5E1A: 4A           LSR 
C2/5E1B: 66 0E        ROR $0E
C2/5E1D: AA           TAX 
C2/5E1E: BF 81 29 D1  LDA $D12981,X
C2/5E22: 48           PHA 
C2/5E23: A5 0E        LDA $0E
C2/5E25: 20 BD 01     JSR $01BD       ; a >> 5
C2/5E28: AA           TAX 
C2/5E29: 68           PLA 
C2/5E2A: 20 DB 01     JSR $01DB       ; check bit x
C2/5E2D: F0 20        BEQ $5E4F
C2/5E2F: AD 23 27     LDA $2723
C2/5E32: D0 1B        BNE $5E4F
C2/5E34: 20 FA 98     JSR $98FA       ; create graphics command
C2/5E37: 9E 4C 38     STZ $384C,X
C2/5E3A: 9E 50 38     STZ $3850,X
C2/5E3D: A9 FC        LDA #$FC
C2/5E3F: 9D 4D 38     STA $384D,X
C2/5E42: A9 07        LDA #$07
C2/5E44: 9D 4E 38     STA $384E,X
C2/5E47: AD 22 27     LDA $2722
C2/5E4A: 9D 4F 38     STA $384F,X
C2/5E4D: 80 6F        BRA $5EBE
C2/5E4F: A9 00        LDA #$00
C2/5E51: 85 0E        STA $0E
C2/5E53: AD 22 27     LDA $2722
C2/5E56: 8D 21 26     STA $2621
C2/5E59: AD 23 27     LDA $2723
C2/5E5C: D0 32        BNE $5E90
C2/5E5E: AD 22 27     LDA $2722
C2/5E61: C9 81        CMP #$81
C2/5E63: D0 2B        BNE $5E90
C2/5E65: A9 03        LDA #$03
C2/5E67: 8D 20 26     STA $2620
C2/5E6A: A6 32        LDX $32
C2/5E6C: BD 7F 20     LDA $207F,X
C2/5E6F: 8D 21 26     STA $2621
C2/5E72: 20 2F 99     JSR $992F
C2/5E75: 20 FA 98     JSR $98FA       ; create graphics command
C2/5E78: 9E 4C 38     STZ $384C,X
C2/5E7B: A9 FC        LDA #$FC
C2/5E7D: 9D 4D 38     STA $384D,X
C2/5E80: A9 01        LDA #$01
C2/5E82: 9D 4E 38     STA $384E,X
C2/5E85: A9 04        LDA #$04
C2/5E87: 9D 4F 38     STA $384F,X
C2/5E8A: 7B           TDC 
C2/5E8B: 9D 50 38     STA $3850,X
C2/5E8E: 80 2E        BRA $5EBE
C2/5E90: AD 23 27     LDA $2723
C2/5E93: F0 06        BEQ $5E9B
C2/5E95: A9 02        LDA #$02
C2/5E97: 85 0E        STA $0E
C2/5E99: A9 02        LDA #$02
C2/5E9B: 8D 20 26     STA $2620
C2/5E9E: A5 21        LDA $21
C2/5EA0: D0 03        BNE $5EA5
C2/5EA2: 20 2F 99     JSR $992F
C2/5EA5: 20 FA 98     JSR $98FA       ; create graphics command
C2/5EA8: 9E 4C 38     STZ $384C,X
C2/5EAB: 9E 50 38     STZ $3850,X
C2/5EAE: A9 FC        LDA #$FC
C2/5EB0: 9D 4D 38     STA $384D,X
C2/5EB3: A5 0E        LDA $0E
C2/5EB5: 9D 4E 38     STA $384E,X
C2/5EB8: AD 21 26     LDA $2621
C2/5EBB: 9D 4F 38     STA $384F,X
C2/5EBE: AD FA 79     LDA $79FA
C2/5EC1: AA           TAX 
C2/5EC2: AD 2E 26     LDA $262E
C2/5EC5: 29 7F        AND #$7F
C2/5EC7: 9D 2D 7B     STA $7B2D,X
C2/5ECA: AD A0 26     LDA $26A0
C2/5ECD: 9D 1C 7B     STA $7B1C,X
C2/5ED0: F0 05        BEQ $5ED7
C2/5ED2: FE 1C 7B     INC $7B1C,X
C2/5ED5: A9 80        LDA #$80
C2/5ED7: 9D CC 7A     STA $7ACC,X
C2/5EDA: AD FA 79     LDA $79FA
C2/5EDD: 0A           ASL 
C2/5EDE: AA           TAX 
C2/5EDF: AD 20 27     LDA $2720
C2/5EE2: 9D DC 7A     STA $7ADC,X
C2/5EE5: 9D FC 7A     STA $7AFC,X
C2/5EE8: AD 21 27     LDA $2721
C2/5EEB: 9D DD 7A     STA $7ADD,X
C2/5EEE: 9D FD 7A     STA $7AFD,X
C2/5EF1: EE FA 79     INC $79FA
C2/5EF4: AD 23 27     LDA $2723
C2/5EF7: D0 61        BNE $5F5A
C2/5EF9: AD 22 27     LDA $2722
C2/5EFC: C9 F1        CMP #$F1
C2/5EFE: F0 25        BEQ $5F25
C2/5F00: A6 32        LDX $32
C2/5F02: C9 82        CMP #$82
C2/5F04: B0 15        BCS $5F1B
C2/5F06: C9 80        CMP #$80
C2/5F08: B0 50        BCS $5F5A
C2/5F0A: BD 1B 20     LDA $201B,X
C2/5F0D: 1D 71 20     ORA $2071,X
C2/5F10: 29 04        AND #$04
C2/5F12: D0 31        BNE $5F45
C2/5F14: AD E6 7B     LDA $7BE6
C2/5F17: 29 40        AND #$40
C2/5F19: D0 2A        BNE $5F45
C2/5F1B: BD 1A 20     LDA $201A,X
C2/5F1E: 1D 70 20     ORA $2070,X
C2/5F21: 29 20        AND #$20
C2/5F23: F0 35        BEQ $5F5A
C2/5F25: AD 22 27     LDA $2722
C2/5F28: 64 0E        STZ $0E
C2/5F2A: 4A           LSR 
C2/5F2B: 66 0E        ROR $0E
C2/5F2D: 4A           LSR 
C2/5F2E: 66 0E        ROR $0E
C2/5F30: 4A           LSR 
C2/5F31: 66 0E        ROR $0E
C2/5F33: AA           TAX 
C2/5F34: A5 0E        LDA $0E
C2/5F36: 20 BD 01     JSR $01BD       ; a >> 5
C2/5F39: A8           TAY 
C2/5F3A: 5A           PHY 
C2/5F3B: BF 58 EF D0  LDA $D0EF58,X
C2/5F3F: FA           PLX 
C2/5F40: 20 DB 01     JSR $01DB       ; check bit x
C2/5F43: D0 15        BNE $5F5A
C2/5F45: AD EF 3C     LDA $3CEF
C2/5F48: AA           TAX 
C2/5F49: A9 1D        LDA #$1D        ; "Ineffective"
C2/5F4B: 9D 5F 3C     STA $3C5F,X
C2/5F4E: AD FA 79     LDA $79FA
C2/5F51: 3A           DEC 
C2/5F52: AA           TAX 
C2/5F53: A9 7E        LDA #$7E
C2/5F55: 9D 2D 7B     STA $7B2D,X
C2/5F58: 80 17        BRA $5F71
C2/5F5A: 20 E3 98     JSR $98E3
C2/5F5D: AD EF 3C     LDA $3CEF
C2/5F60: A8           TAY 
C2/5F61: C2 20        REP #$20
C2/5F63: AD 22 27     LDA $2722
C2/5F66: AA           TAX 
C2/5F67: 7B           TDC 
C2/5F68: E2 20        SEP #$20
C2/5F6A: BF 40 38 D1  LDA $D13840,X   ; battle message
C2/5F6E: 99 5F 3C     STA $3C5F,Y
C2/5F71: 20 4C 99     JSR $994C
C2/5F74: 60           RTS 

; [  ]

C2/5F75: 85 41        STA $41
C2/5F77: AD 23 27     LDA $2723
C2/5F7A: F0 09        BEQ $5F85
C2/5F7C: A9 02        LDA #$02
C2/5F7E: 85 0E        STA $0E
C2/5F80: 8D 20 26     STA $2620
C2/5F83: 80 07        BRA $5F8C
C2/5F85: A9 00        LDA #$00
C2/5F87: 85 0E        STA $0E
C2/5F89: 8D 20 26     STA $2620
C2/5F8C: AD 22 27     LDA $2722
C2/5F8F: 8D 21 26     STA $2621
C2/5F92: 20 2F 99     JSR $992F
C2/5F95: 20 FA 98     JSR $98FA       ; create graphics command
C2/5F98: 9E 4C 38     STZ $384C,X
C2/5F9B: 9E 50 38     STZ $3850,X
C2/5F9E: A9 FC        LDA #$FC
C2/5FA0: 9D 4D 38     STA $384D,X
C2/5FA3: A5 0E        LDA $0E
C2/5FA5: 9D 4E 38     STA $384E,X
C2/5FA8: AD 21 26     LDA $2621
C2/5FAB: 9D 4F 38     STA $384F,X
C2/5FAE: A5 41        LDA $41
C2/5FB0: 85 0E        STA $0E
C2/5FB2: 7B           TDC 
C2/5FB3: AA           TAX 
C2/5FB4: BD 2A 26     LDA $262A,X
C2/5FB7: 99 FC 79     STA $79FC,Y
C2/5FBA: E8           INX 
C2/5FBB: C8           INY 
C2/5FBC: E0 05 00     CPX #$0005
C2/5FBF: D0 F3        BNE $5FB4
C2/5FC1: C8           INY 
C2/5FC2: C8           INY 
C2/5FC3: C8           INY 
C2/5FC4: C8           INY 
C2/5FC5: BD 2A 26     LDA $262A,X
C2/5FC8: 99 FC 79     STA $79FC,Y
C2/5FCB: E8           INX 
C2/5FCC: C8           INY 
C2/5FCD: E0 08 00     CPX #$0008
C2/5FD0: D0 F3        BNE $5FC5
C2/5FD2: C6 0E        DEC $0E
C2/5FD4: A5 0E        LDA $0E
C2/5FD6: D0 DA        BNE $5FB2
C2/5FD8: 64 1A        STZ $1A
C2/5FDA: AD FF 79     LDA $79FF
C2/5FDD: 29 7F        AND #$7F
C2/5FDF: AA           TAX 
C2/5FE0: 86 0E        STX $0E
C2/5FE2: A6 32        LDX $32
C2/5FE4: BD 39 20     LDA $2039,X
C2/5FE7: 29 08        AND #$08
C2/5FE9: F0 06        BEQ $5FF1
C2/5FEB: 46 0E        LSR $0E
C2/5FED: 90 02        BCC $5FF1
C2/5FEF: E6 0E        INC $0E
C2/5FF1: C2 20        REP #$20
C2/5FF3: 38           SEC 
C2/5FF4: BD 0A 20     LDA $200A,X
C2/5FF7: E5 0E        SBC $0E
C2/5FF9: 90 08        BCC $6003
C2/5FFB: 9D 0A 20     STA $200A,X
C2/5FFE: 7B           TDC 
C2/5FFF: E2 20        SEP #$20
C2/6001: 80 05        BRA $6008
C2/6003: 7B           TDC 
C2/6004: E2 20        SEP #$20
C2/6006: E6 1A        INC $1A
C2/6008: A5 65        LDA $65
C2/600A: F0 10        BEQ $601C
C2/600C: 7B           TDC 
C2/600D: AA           TAX 
C2/600E: A9 07        LDA #$07
C2/6010: 20 7C 00     JSR $007C       ; a = (x..a)
C2/6013: AA           TAX 
C2/6014: 7B           TDC 
C2/6015: 20 D6 01     JSR $01D6       ; set bit x
C2/6018: 85 65        STA $65
C2/601A: 80 0E        BRA $602A
C2/601C: 7B           TDC 
C2/601D: AA           TAX 
C2/601E: A9 03        LDA #$03
C2/6020: 20 7C 00     JSR $007C       ; a = (x..a)
C2/6023: AA           TAX 
C2/6024: 7B           TDC 
C2/6025: 20 D6 01     JSR $01D6       ; set bit x
C2/6028: 85 66        STA $66
C2/602A: 20 FE 4A     JSR $4AFE
C2/602D: AD 29 7C     LDA $7C29
C2/6030: F0 05        BEQ $6037
C2/6032: A9 7E        LDA #$7E
C2/6034: 8D 2E 26     STA $262E
C2/6037: 20 A9 02     JSR $02A9
C2/603A: A6 32        LDX $32
C2/603C: BD 1B 20     LDA $201B,X
C2/603F: 1D 71 20     ORA $2071,X
C2/6042: 29 04        AND #$04
C2/6044: D0 11        BNE $6057
C2/6046: AD E6 7B     LDA $7BE6
C2/6049: 29 40        AND #$40
C2/604B: D0 0A        BNE $6057
C2/604D: BD 1A 20     LDA $201A,X
C2/6050: 1D 70 20     ORA $2070,X
C2/6053: 29 20        AND #$20
C2/6055: F0 05        BEQ $605C
C2/6057: A9 7E        LDA #$7E
C2/6059: 8D 2E 26     STA $262E
C2/605C: AD FA 79     LDA $79FA
C2/605F: AA           TAX 
C2/6060: AD 2E 26     LDA $262E
C2/6063: 29 7F        AND #$7F
C2/6065: 9D 2D 7B     STA $7B2D,X
C2/6068: A5 1A        LDA $1A
C2/606A: F0 05        BEQ $6071
C2/606C: A9 7E        LDA #$7E
C2/606E: 9D 2D 7B     STA $7B2D,X
C2/6071: 9E 1C 7B     STZ $7B1C,X
C2/6074: 9E CC 7A     STZ $7ACC,X
C2/6077: AD FA 79     LDA $79FA
C2/607A: 0A           ASL 
C2/607B: AA           TAX 
C2/607C: AD 20 27     LDA $2720
C2/607F: 9D DC 7A     STA $7ADC,X
C2/6082: 9D FC 7A     STA $7AFC,X
C2/6085: AD 21 27     LDA $2721
C2/6088: 9D DD 7A     STA $7ADD,X
C2/608B: 9D FD 7A     STA $7AFD,X
C2/608E: EE FA 79     INC $79FA
C2/6091: AD 23 27     LDA $2723
C2/6094: F0 03        BEQ $6099
C2/6096: 20 E3 98     JSR $98E3
C2/6099: C6 41        DEC $41
C2/609B: A5 41        LDA $41
C2/609D: 30 03        BMI $60A2
C2/609F: 4C 08 60     JMP $6008
C2/60A2: 60           RTS 

; [  ]

C2/60A3: 18           CLC 
C2/60A4: AD 22 27     LDA $2722
C2/60A7: 69 17        ADC #$17
C2/60A9: 8D 22 27     STA $2722
C2/60AC: C9 6B        CMP #$6B
C2/60AE: F0 1D        BEQ $60CD
C2/60B0: C9 6A        CMP #$6A
C2/60B2: F0 2F        BEQ $60E3
C2/60B4: C9 5F        CMP #$5F
C2/60B6: F0 03        BEQ $60BB
C2/60B8: 4C 31 61     JMP $6131
C2/60BB: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/60BE: C9 08        CMP #$08
C2/60C0: B0 6F        BCS $6131
C2/60C2: A9 6E        LDA #$6E
C2/60C4: 8D 22 27     STA $2722
C2/60C7: A9 FF        LDA #$FF
C2/60C9: 85 65        STA $65
C2/60CB: 80 64        BRA $6131
C2/60CD: A5 65        LDA $65
C2/60CF: 85 23        STA $23
C2/60D1: A5 66        LDA $66
C2/60D3: 85 22        STA $22
C2/60D5: A9 FF        LDA #$FF
C2/60D7: 85 65        STA $65
C2/60D9: 64 66        STZ $66
C2/60DB: A9 70        LDA #$70
C2/60DD: 85 20        STA $20
C2/60DF: A6 32        LDX $32
C2/60E1: 80 4E        BRA $6131
C2/60E3: 7B           TDC 
C2/60E4: A8           TAY 
C2/60E5: AA           TAX 
C2/60E6: B9 C6 3E     LDA $3EC6,Y
C2/60E9: F0 07        BEQ $60F2
C2/60EB: BD 65 22     LDA $2265,X
C2/60EE: 29 20        AND #$20
C2/60F0: D0 2C        BNE $611E
C2/60F2: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/60F5: C8           INY 
C2/60F6: C0 08 00     CPY #$0008
C2/60F9: D0 EB        BNE $60E6
C2/60FB: 18           CLC 
C2/60FC: AD E5 7B     LDA $7BE5
C2/60FF: 69 50        ADC #$50
C2/6101: 38           SEC 
C2/6102: ED 02 22     SBC $2202
C2/6105: B0 02        BCS $6109
C2/6107: A9 01        LDA #$01
C2/6109: C9 63        CMP #$63
C2/610B: 90 02        BCC $610F
C2/610D: A9 63        LDA #$63
C2/610F: 85 0E        STA $0E
C2/6111: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/6114: C5 0E        CMP $0E
C2/6116: B0 06        BCS $611E
C2/6118: A9 FF        LDA #$FF
C2/611A: 85 65        STA $65
C2/611C: 80 13        BRA $6131
C2/611E: A9 6F        LDA #$6F
C2/6120: 8D 22 27     STA $2722
C2/6123: 7B           TDC 
C2/6124: AA           TAX 
C2/6125: A9 07        LDA #$07
C2/6127: 20 7C 00     JSR $007C       ; a = (x..a)
C2/612A: AA           TAX 
C2/612B: 7B           TDC 
C2/612C: 20 D6 01     JSR $01D6       ; set bit x
C2/612F: 85 65        STA $65
C2/6131: AD 22 27     LDA $2722
C2/6134: C2 20        REP #$20
C2/6136: 20 B6 01     JSR $01B6       ; a << 3
C2/6139: AA           TAX 
C2/613A: 7B           TDC 
C2/613B: E2 20        SEP #$20
C2/613D: 7B           TDC 
C2/613E: A8           TAY 
C2/613F: BF 80 0B D1  LDA $D10B80,X
C2/6143: 99 2A 26     STA $262A,Y
C2/6146: E8           INX 
C2/6147: C8           INY 
C2/6148: C0 08 00     CPY #$0008
C2/614B: D0 F2        BNE $613F
C2/614D: 60           RTS 

; [  ]

C2/614E: 7B           TDC 
C2/614F: AA           TAX 
C2/6150: A5 66        LDA $66
C2/6152: 0A           ASL 
C2/6153: B0 03        BCS $6158
C2/6155: E8           INX 
C2/6156: 80 FA        BRA $6152
C2/6158: 8A           TXA 
C2/6159: C2 20        REP #$20
C2/615B: 20 B2 01     JSR $01B2       ; a << 7
C2/615E: AA           TAX 
C2/615F: 7B           TDC 
C2/6160: E2 20        SEP #$20
C2/6162: 60           RTS 

; [ haste/slow timer modification ]

C2/6163: 48           PHA 
C2/6164: BD 1C 20     LDA $201C,X
C2/6167: 1D 72 20     ORA $2072,X
C2/616A: 29 08        AND #$08
C2/616C: F0 06        BEQ $6174       ; branch if not haste
C2/616E: 68           PLA 
C2/616F: 4A           LSR 
C2/6170: D0 01        BNE $6173
C2/6172: 1A           INC             ; min 1
C2/6173: 48           PHA 
C2/6174: BD 1C 20     LDA $201C,X     ; branch if not slow
C2/6177: 1D 72 20     ORA $2072,X
C2/617A: 29 04        AND #$04
C2/617C: F0 07        BEQ $6185
C2/617E: 68           PLA 
C2/617F: 0A           ASL 
C2/6180: 90 02        BCC $6184
C2/6182: A9 FF        LDA #$FF        ; max 255
C2/6184: 48           PHA 
C2/6185: 68           PLA 
C2/6186: D0 01        BNE $6189
C2/6188: 1A           INC 
C2/6189: 60           RTS 

; [ kill character/monster ]

C2/618A: 48           PHA 
C2/618B: 48           PHA 
C2/618C: 64 70        STZ $70
C2/618E: AA           TAX 
C2/618F: BD C2 3E     LDA $3EC2,X
C2/6192: D0 01        BNE $6195
C2/6194: 60           RTS 
C2/6195: 9E C2 3E     STZ $3EC2,X
C2/6198: 68           PLA 
C2/6199: 20 82 24     JSR $2482
C2/619C: 7B           TDC 
C2/619D: 99 F1 3C     STA $3CF1,Y     ; reset timers
C2/61A0: 99 F2 3C     STA $3CF2,Y
C2/61A3: 99 F3 3C     STA $3CF3,Y
C2/61A6: 99 F4 3C     STA $3CF4,Y
C2/61A9: 99 F5 3C     STA $3CF5,Y
C2/61AC: 99 F6 3C     STA $3CF6,Y
C2/61AF: 99 F7 3C     STA $3CF7,Y
C2/61B2: 99 F8 3C     STA $3CF8,Y
C2/61B5: 99 F9 3C     STA $3CF9,Y
C2/61B8: 99 FA 3C     STA $3CFA,Y
C2/61BB: A6 32        LDX $32
C2/61BD: 9E 1B 20     STZ $201B,X
C2/61C0: 9E 1C 20     STZ $201C,X
C2/61C3: 9E 1E 20     STZ $201E,X
C2/61C6: 9E 1F 20     STZ $201F,X
C2/61C9: BD 1D 20     LDA $201D,X
C2/61CC: 29 FB        AND #$FB
C2/61CE: 9D 1D 20     STA $201D,X
C2/61D1: BD 1D 20     LDA $201D,X
C2/61D4: 29 80        AND #$80
C2/61D6: D0 06        BNE $61DE
C2/61D8: 9E 06 20     STZ $2006,X
C2/61DB: 9E 07 20     STZ $2007,X
C2/61DE: 68           PLA 
C2/61DF: 48           PHA 
C2/61E0: C9 04        CMP #$04
C2/61E2: B0 43        BCS $6227       ; branch if a monster
C2/61E4: A8           TAY 
C2/61E5: B9 3A 7C     LDA $7C3A,Y
C2/61E8: 48           PHA 
C2/61E9: 7B           TDC 
C2/61EA: 99 3A 7C     STA $7C3A,Y
C2/61ED: 99 3E 7C     STA $7C3E,Y
C2/61F0: 68           PLA 
C2/61F1: C2 20        REP #$20
C2/61F3: 20 B2 01     JSR $01B2       ; a << 7
C2/61F6: A8           TAY 
C2/61F7: 7B           TDC 
C2/61F8: E2 20        SEP #$20
C2/61FA: B9 1D 20     LDA $201D,Y
C2/61FD: 29 DF        AND #$DF
C2/61FF: 99 1D 20     STA $201D,Y
C2/6202: BD 1D 20     LDA $201D,X
C2/6205: 29 80        AND #$80
C2/6207: F0 0A        BEQ $6213
C2/6209: BD 1A 20     LDA $201A,X
C2/620C: 29 F3        AND #$F3
C2/620E: 9D 1A 20     STA $201A,X
C2/6211: 80 0A        BRA $621D
C2/6213: BD 1A 20     LDA $201A,X
C2/6216: 29 F3        AND #$F3
C2/6218: 09 80        ORA #$80
C2/621A: 9D 1A 20     STA $201A,X
C2/621D: BD 1D 20     LDA $201D,X
C2/6220: 29 80        AND #$80
C2/6222: 9D 1D 20     STA $201D,X
C2/6225: 68           PLA 
C2/6226: 60           RTS 
C2/6227: BD 1A 20     LDA $201A,X
C2/622A: 29 30        AND #$30
C2/622C: 09 80        ORA #$80
C2/622E: 9D 1A 20     STA $201A,X
C2/6231: 9E 1D 20     STZ $201D,X
C2/6234: 68           PLA 
C2/6235: 48           PHA 
C2/6236: 38           SEC 
C2/6237: E9 04        SBC #$04
C2/6239: AA           TAX 
C2/623A: 7B           TDC 
C2/623B: 20 D6 01     JSR $01D6       ; set bit x
C2/623E: 85 70        STA $70
C2/6240: 68           PLA 
C2/6241: 85 0E        STA $0E
C2/6243: 7B           TDC 
C2/6244: AA           TAX 
C2/6245: BD 3A 7C     LDA $7C3A,X
C2/6248: C5 0E        CMP $0E
C2/624A: D0 04        BNE $6250
C2/624C: 9E 3A 7C     STZ $7C3A,X
C2/624F: 60           RTS 
C2/6250: E8           INX 
C2/6251: E0 04 00     CPX #$0004
C2/6254: D0 EF        BNE $6245
C2/6256: 60           RTS 

; [  ]

C2/6257: 9C 20 27     STZ $2720
C2/625A: A9 04        LDA #$04
C2/625C: 8D 21 27     STA $2721
C2/625F: 9C 22 27     STZ $2722
C2/6262: 4C 72 62     JMP $6272
C2/6265: A9 04        LDA #$04
C2/6267: 8D 20 27     STA $2720
C2/626A: A9 0C        LDA #$0C
C2/626C: 8D 21 27     STA $2721
C2/626F: 8D 22 27     STA $2722
C2/6272: AD 20 27     LDA $2720
C2/6275: AA           TAX 
C2/6276: 86 0E        STX $0E
C2/6278: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/627B: AD 51 7C     LDA $7C51
C2/627E: F0 31        BEQ $62B1
C2/6280: A5 0E        LDA $0E
C2/6282: CD B6 7C     CMP $7CB6
C2/6285: D0 2A        BNE $62B1       ; branch if not quick target
C2/6287: BD 1A 20     LDA $201A,X
C2/628A: 29 C2        AND #$C2
C2/628C: D0 1D        BNE $62AB
C2/628E: BD 1B 20     LDA $201B,X
C2/6291: 29 78        AND #$78
C2/6293: D0 16        BNE $62AB
C2/6295: BD 1C 20     LDA $201C,X
C2/6298: 29 10        AND #$10
C2/629A: D0 0F        BNE $62AB
C2/629C: BD 1D 20     LDA $201D,X
C2/629F: 29 84        AND #$84
C2/62A1: D0 08        BNE $62AB
C2/62A3: BD 06 20     LDA $2006,X
C2/62A6: 1D 07 20     ORA $2007,X
C2/62A9: D0 06        BNE $62B1
C2/62AB: 9C 51 7C     STZ $7C51
C2/62AE: 20 E4 24     JSR $24E4
C2/62B1: A4 0E        LDY $0E
C2/62B3: B9 C2 3E     LDA $3EC2,Y
C2/62B6: D0 03        BNE $62BB
C2/62B8: 4C F8 63     JMP $63F8
C2/62BB: AD 22 27     LDA $2722
C2/62BE: D0 41        BNE $6301
C2/62C0: BD 1A 20     LDA $201A,X
C2/62C3: 1D 70 20     ORA $2070,X
C2/62C6: 29 C2        AND #$C2
C2/62C8: D0 18        BNE $62E2
C2/62CA: BD 1B 20     LDA $201B,X
C2/62CD: 1D 71 20     ORA $2071,X
C2/62D0: 29 78        AND #$78
C2/62D2: D0 0E        BNE $62E2
C2/62D4: BD 1C 20     LDA $201C,X
C2/62D7: 29 10        AND #$10
C2/62D9: D0 07        BNE $62E2
C2/62DB: BD 1D 20     LDA $201D,X
C2/62DE: 29 80        AND #$80
C2/62E0: F0 1F        BEQ $6301
C2/62E2: A4 0E        LDY $0E
C2/62E4: B9 3A 7C     LDA $7C3A,Y
C2/62E7: 48           PHA 
C2/62E8: 7B           TDC 
C2/62E9: 99 3A 7C     STA $7C3A,Y
C2/62EC: 99 3E 7C     STA $7C3E,Y
C2/62EF: 68           PLA 
C2/62F0: C2 20        REP #$20
C2/62F2: 20 B2 01     JSR $01B2       ; a << 7
C2/62F5: A8           TAY 
C2/62F6: 7B           TDC 
C2/62F7: E2 20        SEP #$20
C2/62F9: B9 1D 20     LDA $201D,Y     ; clear controlled status
C2/62FC: 29 DF        AND #$DF
C2/62FE: 99 1D 20     STA $201D,Y
C2/6301: BD 1D 20     LDA $201D,X
C2/6304: 1D 73 20     ORA $2073,X
C2/6307: 29 08        AND #$08
C2/6309: F0 2C        BEQ $6337       ; branch if no hp leak status
C2/630B: AD 54 7C     LDA $7C54
C2/630E: F0 27        BEQ $6337       ; branch if not hp leak frame (once per 4 frames)
C2/6310: BD 1E 20     LDA $201E,X
C2/6313: 29 10        AND #$10
C2/6315: D0 20        BNE $6337       ; branch if jumping
C2/6317: C2 20        REP #$20
C2/6319: BD 06 20     LDA $2006,X     ; decrement current hp
C2/631C: F0 04        BEQ $6322
C2/631E: 3A           DEC 
C2/631F: 9D 06 20     STA $2006,X
C2/6322: 7B           TDC 
C2/6323: E2 20        SEP #$20
C2/6325: BD 1D 20     LDA $201D,X
C2/6328: 29 01        AND #$01
C2/632A: F0 0B        BEQ $6337       ; branch if no hide status
C2/632C: BD 06 20     LDA $2006,X
C2/632F: 1D 07 20     ORA $2007,X
C2/6332: D0 03        BNE $6337       ; branch if hp not zero
C2/6334: FE 06 20     INC $2006,X     ; set hp to 1
C2/6337: AD F0 04     LDA $04F0
C2/633A: C9 F7        CMP #$F7
C2/633C: D0 07        BNE $6345
C2/633E: AD F1 04     LDA $04F1
C2/6341: C9 01        CMP #$01
C2/6343: F0 0B        BEQ $6350
C2/6345: BD 06 20     LDA $2006,X
C2/6348: 1D 07 20     ORA $2007,X
C2/634B: D0 03        BNE $6350
C2/634D: 4C D1 63     JMP $63D1
C2/6350: C2 20        REP #$20
C2/6352: BD 08 20     LDA $2008,X
C2/6355: 20 BF 01     JSR $01BF       ; a >> 3
C2/6358: DD 06 20     CMP $2006,X
C2/635B: 90 0D        BCC $636A
C2/635D: 7B           TDC 
C2/635E: E2 20        SEP #$20
C2/6360: BD 1D 20     LDA $201D,X
C2/6363: 09 02        ORA #$02
C2/6365: 9D 1D 20     STA $201D,X
C2/6368: 80 19        BRA $6383
C2/636A: BD 06 20     LDA $2006,X
C2/636D: DD 08 20     CMP $2008,X
C2/6370: 90 06        BCC $6378
C2/6372: BD 08 20     LDA $2008,X
C2/6375: 9D 06 20     STA $2006,X
C2/6378: 7B           TDC 
C2/6379: E2 20        SEP #$20
C2/637B: BD 1D 20     LDA $201D,X
C2/637E: 29 FD        AND #$FD
C2/6380: 9D 1D 20     STA $201D,X
C2/6383: BD 1A 20     LDA $201A,X
C2/6386: 29 80        AND #$80
C2/6388: D0 40        BNE $63CA
C2/638A: BD 1A 20     LDA $201A,X
C2/638D: 29 40        AND #$40
C2/638F: D0 11        BNE $63A2
C2/6391: BD 1D 20     LDA $201D,X
C2/6394: 10 62        BPL $63F8
C2/6396: AD 4C 7C     LDA $7C4C
C2/6399: D0 5D        BNE $63F8
C2/639B: DA           PHX 
C2/639C: A5 0E        LDA $0E
C2/639E: 20 8A 61     JSR $618A
C2/63A1: FA           PLX 
C2/63A2: A4 0E        LDY $0E
C2/63A4: 7B           TDC 
C2/63A5: 99 C2 3E     STA $3EC2,Y
C2/63A8: BD 1A 20     LDA $201A,X
C2/63AB: 29 74        AND #$74
C2/63AD: 9D 1A 20     STA $201A,X
C2/63B0: BD 1B 20     LDA $201B,X
C2/63B3: 29 A4        AND #$A4
C2/63B5: 9D 1B 20     STA $201B,X
C2/63B8: BD 1C 20     LDA $201C,X
C2/63BB: 29 91        AND #$91
C2/63BD: 9D 1C 20     STA $201C,X
C2/63C0: BD 1D 20     LDA $201D,X
C2/63C3: 29 9B        AND #$9B
C2/63C5: 9D 1D 20     STA $201D,X
C2/63C8: 80 2E        BRA $63F8
C2/63CA: 7B           TDC 
C2/63CB: 9D 06 20     STA $2006,X
C2/63CE: 9D 07 20     STA $2007,X
C2/63D1: BD 1A 20     LDA $201A,X
C2/63D4: 1D 70 20     ORA $2070,X
C2/63D7: 29 02        AND #$02
C2/63D9: D0 1D        BNE $63F8
C2/63DB: DA           PHX 
C2/63DC: A5 0E        LDA $0E
C2/63DE: C9 04        CMP #$04
C2/63E0: 90 10        BCC $63F2
C2/63E2: 38           SEC 
C2/63E3: E9 04        SBC #$04
C2/63E5: AA           TAX 
C2/63E6: AD 09 7C     LDA $7C09
C2/63E9: 20 D1 01     JSR $01D1       ; clear bit x
C2/63EC: 0D 0A 7C     ORA $7C0A
C2/63EF: 8D 09 7C     STA $7C09
C2/63F2: A5 0E        LDA $0E
C2/63F4: 20 8A 61     JSR $618A
C2/63F7: FA           PLX 
C2/63F8: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/63FB: E6 0E        INC $0E
C2/63FD: A5 0E        LDA $0E
C2/63FF: CD 21 27     CMP $2721
C2/6402: F0 03        BEQ $6407
C2/6404: 4C 7B 62     JMP $627B
C2/6407: 60           RTS 

; [  ]

C2/6408: 20 23 65     JSR $6523
C2/640B: 20 3A 65     JSR $653A
C2/640E: A6 32        LDX $32
C2/6410: 20 48 02     JSR $0248       ; get attacker stats and level
C2/6413: 9C 61 7C     STZ $7C61
C2/6416: AD 4C 7C     LDA $7C4C
C2/6419: F0 19        BEQ $6434
C2/641B: A5 48        LDA $48
C2/641D: C9 07        CMP #$07
C2/641F: 90 13        BCC $6434
C2/6421: C9 0A        CMP #$0A
C2/6423: B0 0F        BCS $6434
C2/6425: 8D 60 7C     STA $7C60
C2/6428: EE 61 7C     INC $7C61
C2/642B: A9 0A        LDA #$0A
C2/642D: 85 48        STA $48
C2/642F: A2 00 05     LDX #$0500
C2/6432: 86 49        STX $49
C2/6434: A5 48        LDA $48
C2/6436: AA           TAX 
C2/6437: BD C2 3E     LDA $3EC2,X
C2/643A: F0 25        BEQ $6461
C2/643C: A6 49        LDX $49
C2/643E: BD 1A 20     LDA $201A,X
C2/6441: 29 C0        AND #$C0
C2/6443: D0 1C        BNE $6461
C2/6445: BD 1D 20     LDA $201D,X
C2/6448: 29 01        AND #$01
C2/644A: D0 15        BNE $6461
C2/644C: BD 1E 20     LDA $201E,X
C2/644F: 29 10        AND #$10
C2/6451: D0 0E        BNE $6461
C2/6453: AD 4C 7C     LDA $7C4C
C2/6456: D0 3E        BNE $6496
C2/6458: BD 1D 20     LDA $201D,X
C2/645B: 29 80        AND #$80
C2/645D: D0 30        BNE $648F
C2/645F: 80 35        BRA $6496
C2/6461: A6 49        LDX $49
C2/6463: BD 1D 20     LDA $201D,X
C2/6466: 29 80        AND #$80
C2/6468: D0 25        BNE $648F
C2/646A: BD 1E 20     LDA $201E,X
C2/646D: 29 10        AND #$10
C2/646F: F0 07        BEQ $6478
C2/6471: AD 9C 7C     LDA $7C9C
C2/6474: D0 20        BNE $6496
C2/6476: 80 17        BRA $648F
C2/6478: AD 9D 7C     LDA $7C9D
C2/647B: D0 12        BNE $648F
C2/647D: AD 2C 7B     LDA $7B2C
C2/6480: AA           TAX 
C2/6481: BD EB 7B     LDA $7BEB,X
C2/6484: D0 10        BNE $6496
C2/6486: BD 2D 7B     LDA $7B2D,X
C2/6489: 29 7F        AND #$7F
C2/648B: C9 60        CMP #$60
C2/648D: F0 07        BEQ $6496
C2/648F: 9C 9D 7C     STZ $7C9D
C2/6492: E6 56        INC $56         ; miss
C2/6494: 80 19        BRA $64AF
C2/6496: 9C 9C 7C     STZ $7C9C
C2/6499: A6 49        LDX $49
C2/649B: BD 00 20     LDA $2000,X
C2/649E: 29 40        AND #$40
C2/64A0: D0 ED        BNE $648F
C2/64A2: AD E8 7B     LDA $7BE8
C2/64A5: 30 E8        BMI $648F
C2/64A7: AD D8 7C     LDA $7CD8
C2/64AA: D0 E3        BNE $648F
C2/64AC: 20 B2 64     JSR $64B2       ; do attack effect
C2/64AF: 4C 4D 65     JMP $654D

; [ do attack effect ]

C2/64B2: A6 49        LDX $49
C2/64B4: BD 1C 20     LDA $201C,X
C2/64B7: 1D 72 20     ORA $2072,X
C2/64BA: 29 02        AND #$02
C2/64BC: F0 0F        BEQ $64CD
C2/64BE: AD 2C 7B     LDA $7B2C
C2/64C1: AA           TAX 
C2/64C2: BD 2D 7B     LDA $7B2D,X
C2/64C5: 29 7F        AND #$7F
C2/64C7: C9 60        CMP #$60
C2/64C9: D0 0E        BNE $64D9
C2/64CB: 80 31        BRA $64FE
C2/64CD: A6 49        LDX $49
C2/64CF: BD 1D 20     LDA $201D,X
C2/64D2: 1D 73 20     ORA $2073,X
C2/64D5: 29 40        AND #$40
C2/64D7: F0 1E        BEQ $64F7
C2/64D9: A6 32        LDX $32
C2/64DB: BD 57 20     LDA $2057,X
C2/64DE: C9 1D        CMP #$1D
C2/64E0: D0 11        BNE $64F3
C2/64E2: AD 2C 7B     LDA $7B2C
C2/64E5: AA           TAX 
C2/64E6: BD 2D 7B     LDA $7B2D,X
C2/64E9: 29 7F        AND #$7F
C2/64EB: C9 60        CMP #$60
C2/64ED: F0 0F        BEQ $64FE
C2/64EF: A9 7E        LDA #$7E
C2/64F1: 80 0B        BRA $64FE
C2/64F3: A9 7F        LDA #$7F
C2/64F5: 80 07        BRA $64FE
C2/64F7: AD 2C 7B     LDA $7B2C
C2/64FA: AA           TAX 
C2/64FB: BD 2D 7B     LDA $7B2D,X
C2/64FE: 29 7F        AND #$7F
C2/6500: C9 7F        CMP #$7F
C2/6502: D0 04        BNE $6508
C2/6504: A9 75        LDA #$75
C2/6506: 80 06        BRA $650E
C2/6508: C9 7E        CMP #$7E
C2/650A: D0 02        BNE $650E
C2/650C: A9 74        LDA #$74
C2/650E: 0A           ASL 
C2/650F: AA           TAX 
C2/6510: BF 21 7B C2  LDA $C27B21,X   ; attack effect jump table
C2/6514: 85 08        STA $08
C2/6516: BF 22 7B C2  LDA $C27B22,X
C2/651A: 85 09        STA $09
C2/651C: A9 C2        LDA #$C2
C2/651E: 85 0A        STA $0A
C2/6520: DC 08 00     JML [$0008]     ; do attack effect

; [  ]

C2/6523: A2 17 00     LDX #$0017
C2/6526: 74 4D        STZ $4D,X
C2/6528: CA           DEX 
C2/6529: 10 FB        BPL $6526
C2/652B: 8A           TXA 
C2/652C: A2 11 00     LDX #$0011
C2/652F: 9D 69 7B     STA $7B69,X
C2/6532: CA           DEX 
C2/6533: 10 FA        BPL $652F
C2/6535: 7B           TDC 
C2/6536: 8D D7 3E     STA $3ED7       ; custom timer duration
C2/6539: 60           RTS 

; [  ]

C2/653A: A5 39        LDA $39
C2/653C: AA           TAX 
C2/653D: BD 05 7A     LDA $7A05,X
C2/6540: 85 57        STA $57
C2/6542: BD 06 7A     LDA $7A06,X
C2/6545: 85 58        STA $58
C2/6547: BD 07 7A     LDA $7A07,X
C2/654A: 85 59        STA $59
C2/654C: 60           RTS 

; [ update hp/mp after attack ]

C2/654D: A5 56        LDA $56
C2/654F: F0 44        BEQ $6595
C2/6551: A5 48        LDA $48
C2/6553: C9 04        CMP #$04
C2/6555: B0 29        BCS $6580
C2/6557: A5 5D        LDA $5D
C2/6559: C9 07        CMP #$07
C2/655B: D0 12        BNE $656F
C2/655D: A5 48        LDA $48
C2/655F: AA           TAX 
C2/6560: 7B           TDC 
C2/6561: 20 D6 01     JSR $01D6       ; set bit x
C2/6564: 48           PHA 
C2/6565: AD 2C 7B     LDA $7B2C
C2/6568: AA           TAX 
C2/6569: 68           PLA 
C2/656A: 9D 4C 3C     STA $3C4C,X
C2/656D: 80 11        BRA $6580
C2/656F: AD 2C 7B     LDA $7B2C
C2/6572: AA           TAX 
C2/6573: A5 5A        LDA $5A
C2/6575: 05 5B        ORA $5B
C2/6577: 05 5C        ORA $5C
C2/6579: 05 5D        ORA $5D
C2/657B: 05 5E        ORA $5E
C2/657D: 9D 3C 3C     STA $3C3C,X
C2/6580: A2 06 00     LDX #$0006
C2/6583: 9E 46 47     STZ $4746,X
C2/6586: CA           DEX 
C2/6587: 10 FA        BPL $6583
C2/6589: A5 56        LDA $56
C2/658B: 10 2A        BPL $65B7
C2/658D: A2 00 40     LDX #$4000
C2/6590: 8E 6D 7B     STX $7B6D
C2/6593: 80 22        BRA $65B7
C2/6595: A5 4D        LDA $4D
C2/6597: 8D 49 47     STA $4749
C2/659A: A5 48        LDA $48
C2/659C: C9 04        CMP #$04
C2/659E: 90 0F        BCC $65AF
C2/65A0: AD 61 7C     LDA $7C61
C2/65A3: F0 05        BEQ $65AA
C2/65A5: AD 60 7C     LDA $7C60
C2/65A8: 80 02        BRA $65AC
C2/65AA: A5 48        LDA $48
C2/65AC: 38           SEC 
C2/65AD: E9 04        SBC #$04
C2/65AF: AA           TAX 
C2/65B0: 7B           TDC 
C2/65B1: 20 D6 01     JSR $01D6       ; set bit x
C2/65B4: 8D 41 7B     STA $7B41
C2/65B7: AD FB 79     LDA $79FB
C2/65BA: 85 24        STA $24
C2/65BC: A9 18        LDA #$18
C2/65BE: 85 25        STA $25
C2/65C0: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/65C3: AE 6B 7B     LDX $7B6B
C2/65C6: 30 2B        BMI $65F3
C2/65C8: A5 47        LDA $47
C2/65CA: 20 5C 68     JSR $685C
C2/65CD: AD 6B 7B     LDA $7B6B
C2/65D0: 9D 4C 3A     STA $3A4C,X
C2/65D3: AD 6C 7B     LDA $7B6C
C2/65D6: 9D 4D 3A     STA $3A4D,X
C2/65D9: 29 40        AND #$40
C2/65DB: D0 16        BNE $65F3
C2/65DD: C2 20        REP #$20
C2/65DF: A6 32        LDX $32
C2/65E1: 38           SEC 
C2/65E2: BD 06 20     LDA $2006,X
C2/65E5: ED 6B 7B     SBC $7B6B
C2/65E8: F0 02        BEQ $65EC
C2/65EA: B0 01        BCS $65ED
C2/65EC: 7B           TDC 
C2/65ED: 9D 06 20     STA $2006,X
C2/65F0: 7B           TDC 
C2/65F1: E2 20        SEP #$20
C2/65F3: AE 6D 7B     LDX $7B6D
C2/65F6: 10 03        BPL $65FB
C2/65F8: 4C E8 66     JMP $66E8
C2/65FB: D0 1E        BNE $661B
C2/65FD: AD 46 47     LDA $4746
C2/6600: C9 2B        CMP #$2B
C2/6602: F0 09        BEQ $660D
C2/6604: AA           TAX 
C2/6605: BF 26 EF D0  LDA $D0EF26,X
C2/6609: F0 10        BEQ $661B
C2/660B: 80 0B        BRA $6618
C2/660D: AD 47 47     LDA $4747
C2/6610: C9 81        CMP #$81
C2/6612: F0 04        BEQ $6618
C2/6614: C9 80        CMP #$80
C2/6616: D0 03        BNE $661B
C2/6618: EE 40 7B     INC $7B40
C2/661B: AD 61 7C     LDA $7C61
C2/661E: F0 05        BEQ $6625
C2/6620: AD 60 7C     LDA $7C60
C2/6623: 80 02        BRA $6627
C2/6625: A5 48        LDA $48
C2/6627: 20 5C 68     JSR $685C
C2/662A: AD 46 7B     LDA $7B46
C2/662D: F0 4A        BEQ $6679
C2/662F: C2 20        REP #$20
C2/6631: BD 4C 3A     LDA $3A4C,X
C2/6634: C9 FF FF     CMP #$FFFF
C2/6637: F0 3D        BEQ $6676
C2/6639: BD 4C 3A     LDA $3A4C,X
C2/663C: 29 FF 3F     AND #$3FFF
C2/663F: 85 0E        STA $0E
C2/6641: BD 4C 3A     LDA $3A4C,X
C2/6644: 29 00 80     AND #$8000
C2/6647: 85 10        STA $10
C2/6649: 18           CLC 
C2/664A: AD 6D 7B     LDA $7B6D
C2/664D: 29 FF 3F     AND #$3FFF
C2/6650: 65 0E        ADC $0E
C2/6652: C9 0F 27     CMP #$270F
C2/6655: 90 12        BCC $6669
C2/6657: 38           SEC 
C2/6658: E9 0F 27     SBC #$270F
C2/665B: 85 12        STA $12
C2/665D: 38           SEC 
C2/665E: AD 6D 7B     LDA $7B6D
C2/6661: E5 12        SBC $12
C2/6663: 8D 6D 7B     STA $7B6D
C2/6666: A9 0F 27     LDA #$270F
C2/6669: 05 10        ORA $10
C2/666B: 9D 4C 3A     STA $3A4C,X
C2/666E: 7B           TDC 
C2/666F: E2 20        SEP #$20
C2/6671: BD 4D 3A     LDA $3A4D,X
C2/6674: 80 0F        BRA $6685
C2/6676: 7B           TDC 
C2/6677: E2 20        SEP #$20
C2/6679: AD 6D 7B     LDA $7B6D
C2/667C: 9D 4C 3A     STA $3A4C,X
C2/667F: AD 6E 7B     LDA $7B6E
C2/6682: 9D 4D 3A     STA $3A4D,X
C2/6685: 29 40        AND #$40
C2/6687: D0 5F        BNE $66E8
C2/6689: A5 48        LDA $48
C2/668B: C9 04        CMP #$04
C2/668D: B0 34        BCS $66C3
C2/668F: AD 47 47     LDA $4747
C2/6692: C9 80        CMP #$80
C2/6694: F0 08        BEQ $669E
C2/6696: C9 DE        CMP #$DE
C2/6698: F0 04        BEQ $669E
C2/669A: C9 81        CMP #$81
C2/669C: D0 25        BNE $66C3
C2/669E: AD 1E 7C     LDA $7C1E
C2/66A1: 0D 1F 7C     ORA $7C1F
C2/66A4: F0 1D        BEQ $66C3
C2/66A6: C2 20        REP #$20
C2/66A8: 38           SEC 
C2/66A9: AD 1E 7C     LDA $7C1E
C2/66AC: ED 6D 7B     SBC $7B6D
C2/66AF: B0 01        BCS $66B2
C2/66B1: 7B           TDC 
C2/66B2: 8D 1E 7C     STA $7C1E
C2/66B5: 7B           TDC 
C2/66B6: E2 20        SEP #$20
C2/66B8: AD 2C 7B     LDA $7B2C
C2/66BB: AA           TAX 
C2/66BC: A9 04        LDA #$04
C2/66BE: 9D 3C 3C     STA $3C3C,X
C2/66C1: 80 25        BRA $66E8
C2/66C3: AD 6D 7B     LDA $7B6D
C2/66C6: 0D 6E 7B     ORA $7B6E
C2/66C9: 8D 4C 47     STA $474C
C2/66CC: A5 48        LDA $48
C2/66CE: C9 04        CMP #$04
C2/66D0: 90 00        BCC $66D2
C2/66D2: C2 20        REP #$20
C2/66D4: A6 49        LDX $49
C2/66D6: 38           SEC 
C2/66D7: BD 06 20     LDA $2006,X
C2/66DA: ED 6D 7B     SBC $7B6D
C2/66DD: F0 02        BEQ $66E1
C2/66DF: B0 01        BCS $66E2
C2/66E1: 7B           TDC 
C2/66E2: 9D 06 20     STA $2006,X
C2/66E5: 7B           TDC 
C2/66E6: E2 20        SEP #$20
C2/66E8: AE 6F 7B     LDX $7B6F
C2/66EB: 30 35        BMI $6722
C2/66ED: A5 47        LDA $47
C2/66EF: 20 5C 68     JSR $685C
C2/66F2: AD 6F 7B     LDA $7B6F
C2/66F5: 9D 4C 3A     STA $3A4C,X
C2/66F8: AD 70 7B     LDA $7B70
C2/66FB: 09 80        ORA #$80
C2/66FD: 9D 4D 3A     STA $3A4D,X
C2/6700: C2 20        REP #$20
C2/6702: AD 6F 7B     LDA $7B6F
C2/6705: 29 FF 3F     AND #$3FFF
C2/6708: 85 0E        STA $0E
C2/670A: A6 32        LDX $32
C2/670C: 18           CLC 
C2/670D: BD 06 20     LDA $2006,X
C2/6710: 65 0E        ADC $0E
C2/6712: B0 05        BCS $6719
C2/6714: DD 08 20     CMP $2008,X
C2/6717: 90 03        BCC $671C
C2/6719: BD 08 20     LDA $2008,X
C2/671C: 9D 06 20     STA $2006,X
C2/671F: 7B           TDC 
C2/6720: E2 20        SEP #$20
C2/6722: AE 71 7B     LDX $7B71
C2/6725: 30 3F        BMI $6766
C2/6727: AD 61 7C     LDA $7C61
C2/672A: F0 05        BEQ $6731
C2/672C: AD 60 7C     LDA $7C60
C2/672F: 80 02        BRA $6733
C2/6731: A5 48        LDA $48
C2/6733: 20 5C 68     JSR $685C
C2/6736: AD 71 7B     LDA $7B71
C2/6739: 9D 4C 3A     STA $3A4C,X
C2/673C: AD 72 7B     LDA $7B72
C2/673F: 09 80        ORA #$80
C2/6741: 9D 4D 3A     STA $3A4D,X
C2/6744: C2 20        REP #$20
C2/6746: AD 71 7B     LDA $7B71
C2/6749: 29 FF 3F     AND #$3FFF
C2/674C: 85 0E        STA $0E
C2/674E: A6 49        LDX $49
C2/6750: 18           CLC 
C2/6751: BD 06 20     LDA $2006,X
C2/6754: 65 0E        ADC $0E
C2/6756: B0 05        BCS $675D
C2/6758: DD 08 20     CMP $2008,X
C2/675B: 90 03        BCC $6760
C2/675D: BD 08 20     LDA $2008,X
C2/6760: 9D 06 20     STA $2006,X
C2/6763: 7B           TDC 
C2/6764: E2 20        SEP #$20
C2/6766: AE 73 7B     LDX $7B73
C2/6769: 30 33        BMI $679E
C2/676B: A5 47        LDA $47
C2/676D: 20 5C 68     JSR $685C
C2/6770: AD 73 7B     LDA $7B73
C2/6773: 9D 4C 3A     STA $3A4C,X
C2/6776: AD 74 7B     LDA $7B74
C2/6779: 09 80        ORA #$80
C2/677B: 9D 4D 3A     STA $3A4D,X
C2/677E: C2 20        REP #$20
C2/6780: AD 73 7B     LDA $7B73
C2/6783: 29 FF 3F     AND #$3FFF
C2/6786: 85 0E        STA $0E
C2/6788: A6 32        LDX $32
C2/678A: 18           CLC 
C2/678B: BD 0A 20     LDA $200A,X
C2/678E: 65 0E        ADC $0E
C2/6790: DD 0C 20     CMP $200C,X
C2/6793: 90 03        BCC $6798
C2/6795: BD 0C 20     LDA $200C,X
C2/6798: 9D 0A 20     STA $200A,X
C2/679B: 7B           TDC 
C2/679C: E2 20        SEP #$20
C2/679E: AE 75 7B     LDX $7B75
C2/67A1: 30 3D        BMI $67E0
C2/67A3: AD 61 7C     LDA $7C61
C2/67A6: F0 05        BEQ $67AD
C2/67A8: AD 60 7C     LDA $7C60
C2/67AB: 80 02        BRA $67AF
C2/67AD: A5 48        LDA $48
C2/67AF: 20 5C 68     JSR $685C
C2/67B2: AD 75 7B     LDA $7B75
C2/67B5: 9D 4C 3A     STA $3A4C,X
C2/67B8: AD 76 7B     LDA $7B76
C2/67BB: 09 80        ORA #$80
C2/67BD: 9D 4D 3A     STA $3A4D,X
C2/67C0: C2 20        REP #$20
C2/67C2: AD 75 7B     LDA $7B75
C2/67C5: 29 FF 3F     AND #$3FFF
C2/67C8: 85 0E        STA $0E
C2/67CA: A6 49        LDX $49
C2/67CC: 18           CLC 
C2/67CD: BD 0A 20     LDA $200A,X
C2/67D0: 65 0E        ADC $0E
C2/67D2: DD 0C 20     CMP $200C,X
C2/67D5: 90 03        BCC $67DA
C2/67D7: BD 0C 20     LDA $200C,X
C2/67DA: 9D 0A 20     STA $200A,X
C2/67DD: 7B           TDC 
C2/67DE: E2 20        SEP #$20
C2/67E0: AE 77 7B     LDX $7B77
C2/67E3: 30 2C        BMI $6811
C2/67E5: A5 47        LDA $47
C2/67E7: 20 5C 68     JSR $685C
C2/67EA: AD 77 7B     LDA $7B77
C2/67ED: 9D 4C 3A     STA $3A4C,X
C2/67F0: AD 78 7B     LDA $7B78
C2/67F3: 9D 4D 3A     STA $3A4D,X
C2/67F6: C2 20        REP #$20
C2/67F8: AD 77 7B     LDA $7B77
C2/67FB: 29 FF 3F     AND #$3FFF
C2/67FE: 85 0E        STA $0E
C2/6800: A6 32        LDX $32
C2/6802: 38           SEC 
C2/6803: BD 0A 20     LDA $200A,X
C2/6806: E5 0E        SBC $0E
C2/6808: B0 01        BCS $680B
C2/680A: 7B           TDC 
C2/680B: 9D 0A 20     STA $200A,X
C2/680E: 7B           TDC 
C2/680F: E2 20        SEP #$20
C2/6811: AE 79 7B     LDX $7B79
C2/6814: 30 36        BMI $684C
C2/6816: AD 61 7C     LDA $7C61
C2/6819: F0 05        BEQ $6820
C2/681B: AD 60 7C     LDA $7C60
C2/681E: 80 02        BRA $6822
C2/6820: A5 48        LDA $48
C2/6822: 20 5C 68     JSR $685C
C2/6825: AD 79 7B     LDA $7B79
C2/6828: 9D 4C 3A     STA $3A4C,X
C2/682B: AD 7A 7B     LDA $7B7A
C2/682E: 9D 4D 3A     STA $3A4D,X
C2/6831: C2 20        REP #$20
C2/6833: AD 79 7B     LDA $7B79
C2/6836: 29 FF 3F     AND #$3FFF
C2/6839: 85 0E        STA $0E
C2/683B: A6 49        LDX $49
C2/683D: 38           SEC 
C2/683E: BD 0A 20     LDA $200A,X
C2/6841: E5 0E        SBC $0E
C2/6843: B0 01        BCS $6846
C2/6845: 7B           TDC 
C2/6846: 9D 0A 20     STA $200A,X
C2/6849: 7B           TDC 
C2/684A: E2 20        SEP #$20
C2/684C: A6 49        LDX $49
C2/684E: BD 1A 20     LDA $201A,X
C2/6851: 29 02        AND #$02
C2/6853: F0 06        BEQ $685B
C2/6855: 9E 06 20     STZ $2006,X
C2/6858: 9E 07 20     STZ $2007,X
C2/685B: 60           RTS 

; [  ]

C2/685C: AA           TAX 
C2/685D: BF 79 ED D0  LDA $D0ED79,X
C2/6861: 0A           ASL 
C2/6862: C2 20        REP #$20
C2/6864: 18           CLC 
C2/6865: 65 26        ADC $26
C2/6867: AA           TAX 
C2/6868: 7B           TDC 
C2/6869: E2 20        SEP #$20
C2/686B: 60           RTS 

; [ attack effect $00:  ]

C2/686C: EE FB 7B     INC $7BFB
C2/686F: 60           RTS 

; [ attack effect $01: monster fight ]

C2/6870: 20 47 7C     JSR $7C47
C2/6873: 20 BE 7E     JSR $7EBE
C2/6876: A5 56        LDA $56
C2/6878: D0 19        BNE $6893
C2/687A: 20 27 82     JSR $8227
C2/687D: 20 9B 83     JSR $839B
C2/6880: 20 BD 83     JSR $83BD
C2/6883: 20 12 85     JSR $8512
C2/6886: 20 33 85     JSR $8533
C2/6889: 20 84 86     JSR $8684
C2/688C: A5 56        LDA $56
C2/688E: D0 03        BNE $6893
C2/6890: 4C 11 88     JMP $8811
C2/6893: A9 80        LDA #$80
C2/6895: 85 56        STA $56
C2/6897: 60           RTS 

; [ attack effect $02: monster special attack ]

C2/6898: A6 32        LDX $32
C2/689A: BD 6E 20     LDA $206E,X
C2/689D: 30 0A        BMI $68A9
C2/689F: 20 47 7C     JSR $7C47
C2/68A2: 20 BE 7E     JSR $7EBE
C2/68A5: A5 56        LDA $56
C2/68A7: D0 34        BNE $68DD
C2/68A9: 20 E2 7D     JSR $7DE2
C2/68AC: A5 56        LDA $56
C2/68AE: D0 2D        BNE $68DD
C2/68B0: 20 27 82     JSR $8227
C2/68B3: 20 9B 83     JSR $839B
C2/68B6: 20 BD 83     JSR $83BD
C2/68B9: 20 12 85     JSR $8512
C2/68BC: 20 33 85     JSR $8533
C2/68BF: 20 AF 84     JSR $84AF
C2/68C2: 20 84 86     JSR $8684
C2/68C5: A5 56        LDA $56
C2/68C7: D0 14        BNE $68DD
C2/68C9: 20 11 88     JSR $8811
C2/68CC: A5 48        LDA $48
C2/68CE: C9 04        CMP #$04
C2/68D0: B0 08        BCS $68DA
C2/68D2: AD 1E 7C     LDA $7C1E
C2/68D5: 0D 1F 7C     ORA $7C1F
C2/68D8: D0 07        BNE $68E1
C2/68DA: 4C 2F 8C     JMP $8C2F
C2/68DD: A9 80        LDA #$80
C2/68DF: 85 56        STA $56
C2/68E1: 60           RTS 

; [ attack effect $03: magic sword (status 1) ]

C2/68E2: 20 E9 90     JSR $90E9
C2/68E5: A6 49        LDX $49
C2/68E7: A5 57        LDA $57
C2/68E9: 9D 7A 20     STA $207A,X
C2/68EC: A5 58        LDA $58
C2/68EE: 9D 50 20     STA $2050,X
C2/68F1: A5 59        LDA $59
C2/68F3: 9D 53 20     STA $2053,X
C2/68F6: 60           RTS 

; [ attack effect $04: magic sword (status 2) ]

C2/68F7: 20 E9 90     JSR $90E9
C2/68FA: A6 49        LDX $49
C2/68FC: A5 57        LDA $57
C2/68FE: 9D 7A 20     STA $207A,X
C2/6901: A5 58        LDA $58
C2/6903: 9D 51 20     STA $2051,X
C2/6906: A5 59        LDA $59
C2/6908: 9D 54 20     STA $2054,X
C2/690B: 60           RTS 

; [ attack effect $05: magic sword (other) ]

C2/690C: 20 E9 90     JSR $90E9
C2/690F: A6 49        LDX $49
C2/6911: A5 57        LDA $57
C2/6913: 9D 7A 20     STA $207A,X
C2/6916: A5 58        LDA $58
C2/6918: 9D 52 20     STA $2052,X
C2/691B: A5 59        LDA $59
C2/691D: 9D 55 20     STA $2055,X
C2/6920: 60           RTS 

; [ attack effect $06: spell attack ]

C2/6921: 20 97 7C     JSR $7C97
C2/6924: A5 56        LDA $56
C2/6926: D0 1A        BNE $6942
C2/6928: A5 59        LDA $59
C2/692A: 85 4D        STA $4D
C2/692C: 20 30 7F     JSR $7F30
C2/692F: 20 66 83     JSR $8366
C2/6932: 20 F3 84     JSR $84F3
C2/6935: 20 6D 86     JSR $866D
C2/6938: 20 6E 87     JSR $876E
C2/693B: A5 56        LDA $56
C2/693D: D0 03        BNE $6942
C2/693F: 20 05 8A     JSR $8A05
C2/6942: AD 97 7C     LDA $7C97
C2/6945: F0 02        BEQ $6949
C2/6947: 64 56        STZ $56
C2/6949: 60           RTS 

; [ attack effect $07:  ]

C2/694A: 20 81 7E     JSR $7E81
C2/694D: A5 56        LDA $56
C2/694F: D0 1F        BNE $6970
C2/6951: A6 49        LDX $49
C2/6953: BD 65 20     LDA $2065,X
C2/6956: 29 20        AND #$20
C2/6958: D0 14        BNE $696E
C2/695A: 20 74 88     JSR $8874
C2/695D: A5 56        LDA $56
C2/695F: D0 0F        BNE $6970
C2/6961: A9 3C        LDA #$3C
C2/6963: 85 58        STA $58
C2/6965: 20 7D 8B     JSR $8B7D
C2/6968: 20 2E 8D     JSR $8D2E
C2/696B: 64 56        STZ $56
C2/696D: 60           RTS 
C2/696E: E6 56        INC $56         ; miss
C2/6970: 60           RTS 

; [ attack effect $08:  ]

C2/6971: A5 59        LDA $59
C2/6973: 85 4D        STA $4D
C2/6975: 20 6A 7F     JSR $7F6A
C2/6978: 20 66 83     JSR $8366
C2/697B: 20 F3 84     JSR $84F3
C2/697E: 20 6D 86     JSR $866D
C2/6981: 20 6E 87     JSR $876E
C2/6984: A5 56        LDA $56
C2/6986: D0 03        BNE $698B
C2/6988: 20 05 8A     JSR $8A05
C2/698B: AD 97 7C     LDA $7C97
C2/698E: F0 02        BEQ $6992
C2/6990: 64 56        STZ $56
C2/6992: 60           RTS 

; [ attack effect $09:  ]

C2/6993: A5 59        LDA $59
C2/6995: 85 4D        STA $4D
C2/6997: 20 A7 7F     JSR $7FA7
C2/699A: 20 66 83     JSR $8366
C2/699D: 20 F3 84     JSR $84F3
C2/69A0: 20 6D 86     JSR $866D
C2/69A3: 20 6E 87     JSR $876E
C2/69A6: A5 56        LDA $56
C2/69A8: D0 03        BNE $69AD
C2/69AA: 20 05 8A     JSR $8A05
C2/69AD: AD 97 7C     LDA $7C97
C2/69B0: F0 02        BEQ $69B4
C2/69B2: 64 56        STZ $56
C2/69B4: 60           RTS 

; [ attack effect $0A:  ]

C2/69B5: 20 1B 7F     JSR $7F1B
C2/69B8: A5 56        LDA $56
C2/69BA: D0 17        BNE $69D3
C2/69BC: A5 59        LDA $59
C2/69BE: 85 4D        STA $4D
C2/69C0: 20 C2 7F     JSR $7FC2
C2/69C3: 20 12 85     JSR $8512
C2/69C6: 20 6D 86     JSR $866D
C2/69C9: 20 6E 87     JSR $876E
C2/69CC: A5 56        LDA $56
C2/69CE: D0 03        BNE $69D3
C2/69D0: 20 05 8A     JSR $8A05
C2/69D3: AD 97 7C     LDA $7C97
C2/69D6: F0 02        BEQ $69DA
C2/69D8: 64 56        STZ $56
C2/69DA: 60           RTS 

; [ attack effect $0B:  ]

C2/69DB: 20 97 7C     JSR $7C97
C2/69DE: A5 56        LDA $56
C2/69E0: D0 1D        BNE $69FF
C2/69E2: 20 05 82     JSR $8205
C2/69E5: 20 66 83     JSR $8366
C2/69E8: 20 F3 84     JSR $84F3
C2/69EB: A5 57        LDA $57
C2/69ED: 85 4D        STA $4D
C2/69EF: 20 6D 86     JSR $866D
C2/69F2: 20 6E 87     JSR $876E
C2/69F5: A5 56        LDA $56
C2/69F7: D0 06        BNE $69FF
C2/69F9: 20 05 8A     JSR $8A05
C2/69FC: 20 F9 8B     JSR $8BF9
C2/69FF: AD 97 7C     LDA $7C97
C2/6A02: F0 02        BEQ $6A06
C2/6A04: 64 56        STZ $56
C2/6A06: 60           RTS 

; [ attack effect $0C:  ]

C2/6A07: 20 97 7C     JSR $7C97
C2/6A0A: A5 56        LDA $56
C2/6A0C: D0 26        BNE $6A34
C2/6A0E: A5 57        LDA $57
C2/6A10: 85 4D        STA $4D
C2/6A12: 20 6A 7F     JSR $7F6A
C2/6A15: 20 66 83     JSR $8366
C2/6A18: 20 F3 84     JSR $84F3
C2/6A1B: 20 6D 86     JSR $866D
C2/6A1E: 20 6E 87     JSR $876E
C2/6A21: A5 56        LDA $56
C2/6A23: D0 0F        BNE $6A34
C2/6A25: 20 05 8A     JSR $8A05
C2/6A28: A5 59        LDA $59
C2/6A2A: 8D D8 3E     STA $3ED8       ; status duration
C2/6A2D: A9 08        LDA #$08
C2/6A2F: 85 59        STA $59
C2/6A31: 20 05 8E     JSR $8E05
C2/6A34: AD 97 7C     LDA $7C97
C2/6A37: F0 02        BEQ $6A3B
C2/6A39: 64 56        STZ $56
C2/6A3B: 60           RTS 

; [ attack effect $0D:  ]

C2/6A3C: A6 32        LDX $32
C2/6A3E: BD 1F 20     LDA $201F,X
C2/6A41: 30 07        BMI $6A4A
C2/6A43: 20 81 7E     JSR $7E81
C2/6A46: A5 56        LDA $56
C2/6A48: D0 09        BNE $6A53
C2/6A4A: 20 30 7F     JSR $7F30
C2/6A4D: 20 F3 84     JSR $84F3
C2/6A50: 4C 26 89     JMP $8926
C2/6A53: A5 47        LDA $47
C2/6A55: C9 04        CMP #$04
C2/6A57: B0 0B        BCS $6A64
C2/6A59: A6 32        LDX $32
C2/6A5B: BD 56 20     LDA $2056,X
C2/6A5E: 10 04        BPL $6A64
C2/6A60: A9 80        LDA #$80
C2/6A62: 85 56        STA $56
C2/6A64: 60           RTS 

; [ attack effect $0E:  ]

C2/6A65: 20 81 7E     JSR $7E81
C2/6A68: A5 56        LDA $56
C2/6A6A: D0 09        BNE $6A75
C2/6A6C: 20 6A 7F     JSR $7F6A
C2/6A6F: 20 F3 84     JSR $84F3
C2/6A72: 20 85 89     JSR $8985
C2/6A75: 60           RTS 

; [ attack effect $0F: hp to critical ]

C2/6A76: 20 81 7E     JSR $7E81
C2/6A79: A5 56        LDA $56
C2/6A7B: D0 03        BNE $6A80
C2/6A7D: 20 FD 88     JSR $88FD
C2/6A80: 60           RTS 

; [ attack effect $10: restore hp ]

C2/6A81: 20 30 7F     JSR $7F30
C2/6A84: 7B           TDC 
C2/6A85: AA           TAX 
C2/6A86: 86 54        STX $54
C2/6A88: 20 66 83     JSR $8366
C2/6A8B: 4C C1 88     JMP $88C1

; [ attack effect $11: restore hp to full ]

C2/6A8E: 20 30 7F     JSR $7F30
C2/6A91: 7B           TDC 
C2/6A92: AA           TAX 
C2/6A93: 86 54        STX $54
C2/6A95: AD 2C 7B     LDA $7B2C
C2/6A98: 0A           ASL 
C2/6A99: AA           TAX 
C2/6A9A: BD FC 7A     LDA $7AFC,X
C2/6A9D: 29 F0        AND #$F0
C2/6A9F: D0 14        BNE $6AB5
C2/6AA1: BD FC 7A     LDA $7AFC,X
C2/6AA4: 29 0F        AND #$0F
C2/6AA6: 20 B5 01     JSR $01B5       ; a << 4
C2/6AA9: 85 0E        STA $0E
C2/6AAB: BD FD 7A     LDA $7AFD,X
C2/6AAE: 29 F0        AND #$F0
C2/6AB0: 20 BE 01     JSR $01BE       ; a >> 4
C2/6AB3: 05 0E        ORA $0E
C2/6AB5: 20 C3 01     JSR $01C3       ; count set bits
C2/6AB8: CA           DEX 
C2/6AB9: F0 06        BEQ $6AC1
C2/6ABB: 20 66 83     JSR $8366
C2/6ABE: 4C C1 88     JMP $88C1
C2/6AC1: 4C DE 88     JMP $88DE

; [ attack effect $12:  ]

C2/6AC4: 20 F6 7E     JSR $7EF6
C2/6AC7: A5 56        LDA $56
C2/6AC9: D0 03        BNE $6ACE
C2/6ACB: 20 AC 8C     JSR $8CAC
C2/6ACE: 60           RTS 

; [ attack effect $13:  ]

C2/6ACF: 20 F6 7E     JSR $7EF6
C2/6AD2: A5 56        LDA $56
C2/6AD4: D0 06        BNE $6ADC
C2/6AD6: 20 7D 8B     JSR $8B7D
C2/6AD9: 20 2E 8D     JSR $8D2E
C2/6ADC: 60           RTS 

; [ attack effect $14:  ]

C2/6ADD: 20 F6 7E     JSR $7EF6
C2/6AE0: A5 56        LDA $56
C2/6AE2: D0 06        BNE $6AEA
C2/6AE4: 20 7D 8B     JSR $8B7D
C2/6AE7: 20 CB 8D     JSR $8DCB
C2/6AEA: 60           RTS 

; [ attack effect $15: toggle status ]

C2/6AEB: 20 81 7E     JSR $7E81
C2/6AEE: A5 56        LDA $56
C2/6AF0: D0 03        BNE $6AF5
C2/6AF2: 20 25 8E     JSR $8E25
C2/6AF5: 60           RTS 

; [ attack effect $16: remove status ]

C2/6AF6: 20 F6 7E     JSR $7EF6
C2/6AF9: A5 56        LDA $56
C2/6AFB: D0 03        BNE $6B00
C2/6AFD: 20 51 8E     JSR $8E51
C2/6B00: 60           RTS 

; [ attack effect $17:  ]

C2/6B01: A6 49        LDX $49
C2/6B03: BD 65 20     LDA $2065,X
C2/6B06: 29 01        AND #$01
C2/6B08: D0 07        BNE $6B11
C2/6B0A: BD 39 20     LDA $2039,X
C2/6B0D: 29 02        AND #$02
C2/6B0F: F0 0C        BEQ $6B1D
C2/6B11: C2 20        REP #$20
C2/6B13: BD 08 20     LDA $2008,X
C2/6B16: 9D 06 20     STA $2006,X
C2/6B19: 7B           TDC 
C2/6B1A: E2 20        SEP #$20
C2/6B1C: 60           RTS 
C2/6B1D: 20 81 7E     JSR $7E81
C2/6B20: A5 56        LDA $56
C2/6B22: D0 0D        BNE $6B31
C2/6B24: A5 48        LDA $48
C2/6B26: A8           TAY 
C2/6B27: B9 C2 3E     LDA $3EC2,Y
C2/6B2A: F0 03        BEQ $6B2F
C2/6B2C: 4C AC 8C     JMP $8CAC
C2/6B2F: E6 56        INC $56         ; miss
C2/6B31: 60           RTS 

; [ attack effect $18: instant death ]

C2/6B32: 4C 82 8F     JMP $8F82

; [ attack effect $19: remove status ]

C2/6B35: A6 32        LDX $32
C2/6B37: BD 1B 20     LDA $201B,X
C2/6B3A: 29 10        AND #$10
C2/6B3C: F0 03        BEQ $6B41
C2/6B3E: E6 56        INC $56         ; miss
C2/6B40: 60           RTS 
C2/6B41: 20 6E 8F     JSR $8F6E
C2/6B44: A5 58        LDA $58
C2/6B46: 85 59        STA $59
C2/6B48: 20 11 8F     JSR $8F11
C2/6B4B: A5 57        LDA $57
C2/6B4D: 85 59        STA $59
C2/6B4F: 4C B6 8E     JMP $8EB6

; [ attack effect $1A: resurrect ]

C2/6B52: A6 49        LDX $49
C2/6B54: BD 65 20     LDA $2065,X
C2/6B57: 29 01        AND #$01
C2/6B59: D0 07        BNE $6B62
C2/6B5B: BD 39 20     LDA $2039,X
C2/6B5E: 29 02        AND #$02
C2/6B60: F0 04        BEQ $6B66
C2/6B62: 20 82 8F     JSR $8F82
C2/6B65: 60           RTS 
C2/6B66: A6 49        LDX $49
C2/6B68: BD 1A 20     LDA $201A,X
C2/6B6B: 29 80        AND #$80
C2/6B6D: D0 03        BNE $6B72
C2/6B6F: E6 56        INC $56         ; miss
C2/6B71: 60           RTS 
C2/6B72: 20 AA 8F     JSR $8FAA
C2/6B75: A5 58        LDA $58
C2/6B77: 10 03        BPL $6B7C
C2/6B79: 20 F7 89     JSR $89F7
C2/6B7C: 60           RTS 

; [ attack effect $1B: whisperwind ]

C2/6B7D: AD FB 79     LDA $79FB
C2/6B80: 85 24        STA $24
C2/6B82: A9 18        LDA #$18
C2/6B84: 85 25        STA $25
C2/6B86: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/6B89: A6 26        LDX $26
C2/6B8B: DA           PHX 
C2/6B8C: 20 30 7F     JSR $7F30
C2/6B8F: 20 F3 84     JSR $84F3
C2/6B92: 20 05 8A     JSR $8A05
C2/6B95: C2 20        REP #$20
C2/6B97: AD 6D 7B     LDA $7B6D
C2/6B9A: 20 C0 01     JSR $01C0       ; a >> 2
C2/6B9D: 85 0E        STA $0E
C2/6B9F: 7B           TDC 
C2/6BA0: E2 20        SEP #$20
C2/6BA2: FA           PLX 
C2/6BA3: 86 26        STX $26
C2/6BA5: 7B           TDC 
C2/6BA6: A8           TAY 
C2/6BA7: AA           TAX 
C2/6BA8: 86 10        STX $10
C2/6BAA: B9 C2 3E     LDA $3EC2,Y
C2/6BAD: F0 3F        BEQ $6BEE
C2/6BAF: A6 10        LDX $10
C2/6BB1: BD 1A 20     LDA $201A,X
C2/6BB4: 29 C0        AND #$C0
C2/6BB6: D0 36        BNE $6BEE
C2/6BB8: BD 1D 20     LDA $201D,X
C2/6BBB: 29 81        AND #$81
C2/6BBD: D0 2F        BNE $6BEE
C2/6BBF: BD 1E 20     LDA $201E,X
C2/6BC2: 29 10        AND #$10
C2/6BC4: D0 28        BNE $6BEE
C2/6BC6: C2 20        REP #$20
C2/6BC8: 18           CLC 
C2/6BC9: BD 06 20     LDA $2006,X
C2/6BCC: 65 0E        ADC $0E
C2/6BCE: B0 05        BCS $6BD5
C2/6BD0: DD 08 20     CMP $2008,X
C2/6BD3: 90 03        BCC $6BD8
C2/6BD5: BD 08 20     LDA $2008,X
C2/6BD8: 9D 06 20     STA $2006,X
C2/6BDB: 7B           TDC 
C2/6BDC: E2 20        SEP #$20
C2/6BDE: 98           TYA 
C2/6BDF: 20 5C 68     JSR $685C
C2/6BE2: A5 0E        LDA $0E
C2/6BE4: 9D 4C 3A     STA $3A4C,X
C2/6BE7: A5 0F        LDA $0F
C2/6BE9: 09 80        ORA #$80
C2/6BEB: 9D 4D 3A     STA $3A4D,X
C2/6BEE: A6 10        LDX $10
C2/6BF0: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/6BF3: 86 10        STX $10
C2/6BF5: C8           INY 
C2/6BF6: C0 04 00     CPY #$0004
C2/6BF9: D0 AF        BNE $6BAA
C2/6BFB: 60           RTS 

; [ attack effect $1C: element change ]

C2/6BFC: A6 49        LDX $49
C2/6BFE: BD 30 20     LDA $2030,X     ; absorbed elements
C2/6C01: 05 57        ORA $57
C2/6C03: 9D 30 20     STA $2030,X
C2/6C06: BD 32 20     LDA $2032,X     ; immune elements
C2/6C09: 05 58        ORA $58
C2/6C0B: 9D 32 20     STA $2032,X
C2/6C0E: BD 34 20     LDA $2034,X     ; weak elements
C2/6C11: 05 59        ORA $59
C2/6C13: 9D 34 20     STA $2034,X
C2/6C16: 60           RTS 

; [ attack effect $1D: scan ]

C2/6C17: 20 65 99     JSR $9965
C2/6C1A: 86 0E        STX $0E
C2/6C1C: 84 10        STY $10
C2/6C1E: A5 57        LDA $57
C2/6C20: 10 08        BPL $6C2A
C2/6C22: AD 21 40     LDA $4021
C2/6C25: F0 03        BEQ $6C2A
C2/6C27: 4C E1 6C     JMP $6CE1
C2/6C2A: A5 57        LDA $57
C2/6C2C: 29 40        AND #$40
C2/6C2E: F0 16        BEQ $6C46
C2/6C30: A9 11        LDA #$11        ; "LV #"
C2/6C32: 9D 5F 3C     STA $3C5F,X
C2/6C35: E6 0E        INC $0E
C2/6C37: A6 49        LDX $49
C2/6C39: BD 02 20     LDA $2002,X
C2/6C3C: 99 BF 3C     STA $3CBF,Y
C2/6C3F: 7B           TDC 
C2/6C40: 99 C0 3C     STA $3CC0,Y
C2/6C43: 99 C1 3C     STA $3CC1,Y
C2/6C46: A5 57        LDA $57
C2/6C48: 29 20        AND #$20
C2/6C4A: F0 45        BEQ $6C91
C2/6C4C: A6 0E        LDX $0E
C2/6C4E: A9 12        LDA #$12
C2/6C50: 9D 5F 3C     STA $3C5F,X     ; "HP #/#"
C2/6C53: E6 0E        INC $0E
C2/6C55: A6 49        LDX $49
C2/6C57: BD 66 20     LDA $2066,X
C2/6C5A: 10 16        BPL $6C72
C2/6C5C: A9 FF        LDA #$FF
C2/6C5E: 99 C2 3C     STA $3CC2,Y
C2/6C61: 99 C3 3C     STA $3CC3,Y
C2/6C64: 99 C4 3C     STA $3CC4,Y
C2/6C67: 99 C5 3C     STA $3CC5,Y
C2/6C6A: 99 C6 3C     STA $3CC6,Y
C2/6C6D: 99 C7 3C     STA $3CC7,Y
C2/6C70: 80 1F        BRA $6C91
C2/6C72: BD 06 20     LDA $2006,X
C2/6C75: 99 C2 3C     STA $3CC2,Y
C2/6C78: BD 07 20     LDA $2007,X
C2/6C7B: 99 C3 3C     STA $3CC3,Y
C2/6C7E: BD 08 20     LDA $2008,X
C2/6C81: 99 C5 3C     STA $3CC5,Y
C2/6C84: BD 09 20     LDA $2009,X
C2/6C87: 99 C6 3C     STA $3CC6,Y
C2/6C8A: 7B           TDC 
C2/6C8B: 99 C4 3C     STA $3CC4,Y
C2/6C8E: 99 C7 3C     STA $3CC7,Y
C2/6C91: A5 57        LDA $57
C2/6C93: 29 08        AND #$08
C2/6C95: F0 1E        BEQ $6CB5
C2/6C97: A6 49        LDX $49
C2/6C99: BD 34 20     LDA $2034,X
C2/6C9C: 85 12        STA $12
C2/6C9E: A6 0E        LDX $0E
C2/6CA0: 7B           TDC 
C2/6CA1: A8           TAY 
C2/6CA2: A9 12        LDA #$12
C2/6CA4: 1A           INC 
C2/6CA5: 06 12        ASL $12
C2/6CA7: 90 06        BCC $6CAF
C2/6CA9: 9D 5F 3C     STA $3C5F,X     ; "Weak against \element"
C2/6CAC: E8           INX 
C2/6CAD: E6 0E        INC $0E
C2/6CAF: C8           INY 
C2/6CB0: C0 08 00     CPY #$0008
C2/6CB3: D0 EF        BNE $6CA4
C2/6CB5: A5 57        LDA $57
C2/6CB7: 29 08        AND #$08
C2/6CB9: F0 25        BEQ $6CE0
C2/6CBB: A6 49        LDX $49
C2/6CBD: BD 1A 20     LDA $201A,X
C2/6CC0: 85 13        STA $13
C2/6CC2: BD 1B 20     LDA $201B,X
C2/6CC5: 85 12        STA $12
C2/6CC7: A6 0E        LDX $0E
C2/6CC9: 7B           TDC 
C2/6CCA: A8           TAY 
C2/6CCB: A9 00        LDA #$00
C2/6CCD: 1A           INC 
C2/6CCE: 06 12        ASL $12
C2/6CD0: 26 13        ROL $13
C2/6CD2: 90 06        BCC $6CDA
C2/6CD4: 9D 5F 3C     STA $3C5F,X     ; "\status"
C2/6CD7: E8           INX 
C2/6CD8: E6 0E        INC $0E
C2/6CDA: C8           INY 
C2/6CDB: C0 10 00     CPY #$0010
C2/6CDE: D0 ED        BNE $6CCD
C2/6CE0: 60           RTS 
C2/6CE1: E6 56        INC $56         ; miss
C2/6CE3: 60           RTS 

; [ attack effect $1E: drag ]

; sets battle speed to 5

C2/6CE4: A2 04 00     LDX #$0004
C2/6CE7: BF F2 EC D0  LDA $D0ECF2,X
C2/6CEB: 8D D6 3E     STA $3ED6       ; battle speed
C2/6CEE: 60           RTS 

; [ attack effect $1F: void ]

C2/6CEF: AD FE 3E     LDA $3EFE
C2/6CF2: 29 40        AND #$40
C2/6CF4: D0 35        BNE $6D2B       ; automatically miss if void is disabled
C2/6CF6: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/6CF9: C5 57        CMP $57         ; hit % (normally 100)
C2/6CFB: B0 2E        BCS $6D2B       ; branch if attack misses
C2/6CFD: AD E6 7B     LDA $7BE6
C2/6D00: 09 40        ORA #$40
C2/6D02: 8D E6 7B     STA $7BE6
C2/6D05: 7B           TDC 
C2/6D06: AA           TAX 
C2/6D07: A8           TAY 
C2/6D08: BD 1D 20     LDA $201D,X     ; remove mute status
C2/6D0B: 29 FB        AND #$FB
C2/6D0D: 9D 1D 20     STA $201D,X
C2/6D10: 7B           TDC 
C2/6D11: 99 F9 3C     STA $3CF9,Y
C2/6D14: 99 7D 3D     STA $3D7D,Y
C2/6D17: 99 01 3E     STA $3E01,Y
C2/6D1A: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/6D1D: 18           CLC 
C2/6D1E: 98           TYA 
C2/6D1F: 69 0B        ADC #$0B
C2/6D21: A8           TAY 
C2/6D22: E6 0E        INC $0E
C2/6D24: A5 0E        LDA $0E
C2/6D26: C9 0C        CMP #$0C
C2/6D28: D0 DE        BNE $6D08
C2/6D2A: 60           RTS 
C2/6D2B: E6 56        INC $56         ; miss
C2/6D2D: 60           RTS 

; [ attack effect $20: terminate battle ]

C2/6D2E: AD F0 3E     LDA $3EF0
C2/6D31: 30 0D        BMI $6D40
C2/6D33: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/6D36: C5 57        CMP $57
C2/6D38: B0 06        BCS $6D40
C2/6D3A: A9 80        LDA #$80
C2/6D3C: 8D E8 7B     STA $7BE8
C2/6D3F: 60           RTS 
C2/6D40: E6 56        INC $56         ; miss
C2/6D42: 20 65 99     JSR $9965
C2/6D45: A9 20        LDA #$20
C2/6D47: 9D 5F 3C     STA $3C5F,X     ; "Can't run!!"
C2/6D4A: 60           RTS 

; [ attack effect $21: reset battle ]

C2/6D4B: AD F2 04     LDA $04F2
C2/6D4E: C9 1F        CMP #$1F
C2/6D50: D0 05        BNE $6D57       ; branch if not battle bg $1F (neo exdeath)
C2/6D52: A9 1C        LDA #$1C
C2/6D54: 8D F2 04     STA $04F2       ; change to battle bg $1C (final battle)
C2/6D57: EE D8 7C     INC $7CD8       ; reset battle
C2/6D5A: 60           RTS 

; [ attack effect $22: quick ]

C2/6D5B: A5 47        LDA $47
C2/6D5D: C9 04        CMP #$04
C2/6D5F: B0 05        BCS $6D66       ; branch if a monster
C2/6D61: AD 51 7C     LDA $7C51
C2/6D64: F0 03        BEQ $6D69       ; branch if already quick
C2/6D66: E6 56        INC $56         ; miss
C2/6D68: 60           RTS 
C2/6D69: 7B           TDC 
C2/6D6A: AA           TAX 
C2/6D6B: FE AB 3E     INC $3EAB,X     ; pause all characters and monsters
C2/6D6E: E8           INX 
C2/6D6F: E0 0C 00     CPX #$000C
C2/6D72: D0 F7        BNE $6D6B
C2/6D74: A5 47        LDA $47
C2/6D76: 8D B6 7C     STA $7CB6       ; set quick target
C2/6D79: AA           TAX 
C2/6D7A: 9E AB 3E     STZ $3EAB,X     ; unpause target
C2/6D7D: A9 03        LDA #$03        ; give 2 quick turns (the third one is this action)
C2/6D7F: 8D 51 7C     STA $7C51
C2/6D82: 60           RTS 

; [ attack effect $23: earth wall ]

C2/6D83: AD 1E 7C     LDA $7C1E
C2/6D86: 0D 1F 7C     ORA $7C1F
C2/6D89: D0 1C        BNE $6DA7
C2/6D8B: A5 58        LDA $58
C2/6D8D: 85 24        STA $24
C2/6D8F: AD E5 7B     LDA $7BE5
C2/6D92: 85 25        STA $25
C2/6D94: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/6D97: 18           CLC 
C2/6D98: A5 26        LDA $26
C2/6D9A: 69 E8        ADC #$E8
C2/6D9C: 8D 1E 7C     STA $7C1E
C2/6D9F: A5 27        LDA $27
C2/6DA1: 69 03        ADC #$03
C2/6DA3: 8D 1F 7C     STA $7C1F
C2/6DA6: 60           RTS 
C2/6DA7: EE 56 00     INC $0056
C2/6DAA: 60           RTS 

; [ attack effect $24: restore hp (fixed) ]

C2/6DAB: 20 52 82     JSR $8252
C2/6DAE: 20 CF 84     JSR $84CF
C2/6DB1: 4C C1 88     JMP $88C1

; [ attack effect $25: restore mp (fixed) ]

C2/6DB4: 20 52 82     JSR $8252
C2/6DB7: 20 CF 84     JSR $84CF
C2/6DBA: 4C DE 89     JMP $89DE

; [ attack effect $26: full hp/mp ]

C2/6DBD: A5 57        LDA $57
C2/6DBF: 10 03        BPL $6DC4
C2/6DC1: 20 DE 88     JSR $88DE
C2/6DC4: A5 57        LDA $57
C2/6DC6: 29 40        AND #$40
C2/6DC8: F0 03        BEQ $6DCD
C2/6DCA: 20 F7 89     JSR $89F7
C2/6DCD: A5 57        LDA $57
C2/6DCF: 29 20        AND #$20
C2/6DD1: F0 03        BEQ $6DD6
C2/6DD3: 20 4D 8B     JSR $8B4D
C2/6DD6: 60           RTS 

; [ attack effect $27: inflict status ]

C2/6DD7: A9 5A        LDA #$5A
C2/6DD9: 8D D8 3E     STA $3ED8       ; status duration
C2/6DDC: 20 CD 90     JSR $90CD
C2/6DDF: A5 58        LDA $58
C2/6DE1: 85 59        STA $59
C2/6DE3: 20 39 90     JSR $9039
C2/6DE6: A5 57        LDA $57
C2/6DE8: 85 59        STA $59
C2/6DEA: 4C 2B 90     JMP $902B

; [ attack effect $28: inflict damage (fixed) ]

C2/6DED: 20 F6 7E     JSR $7EF6
C2/6DF0: A5 56        LDA $56
C2/6DF2: D0 1D        BNE $6E11
C2/6DF4: A5 58        LDA $58
C2/6DF6: AA           TAX 
C2/6DF7: 86 0E        STX $0E
C2/6DF9: A5 59        LDA $59
C2/6DFB: C2 20        REP #$20
C2/6DFD: 20 B1 01     JSR $01B1       ; a << 8
C2/6E00: 18           CLC 
C2/6E01: 65 0E        ADC $0E
C2/6E03: C9 0F 27     CMP #$270F
C2/6E06: 90 03        BCC $6E0B
C2/6E08: A9 0F 27     LDA #$270F
C2/6E0B: 8D 6D 7B     STA $7B6D
C2/6E0E: 7B           TDC 
C2/6E0F: E2 20        SEP #$20
C2/6E11: 60           RTS 

; [ attack effect $29: inflict status 3 ]

C2/6E12: A6 49        LDX $49
C2/6E14: BD 65 20     LDA $2065,X
C2/6E17: 29 20        AND #$20
C2/6E19: D0 0F        BNE $6E2A
C2/6E1B: 20 F6 7E     JSR $7EF6
C2/6E1E: A5 56        LDA $56
C2/6E20: D0 0A        BNE $6E2C
C2/6E22: A5 58        LDA $58
C2/6E24: 8D D8 3E     STA $3ED8       ; status duration
C2/6E27: 4C 05 8E     JMP $8E05
C2/6E2A: E6 56        INC $56         ; miss
C2/6E2C: 60           RTS 

; [ attack effect $2A: damage + hp leak ]

C2/6E2D: A5 57        LDA $57
C2/6E2F: 85 4D        STA $4D
C2/6E31: 20 B5 87     JSR $87B5
C2/6E34: A5 56        LDA $56
C2/6E36: D0 13        BNE $6E4B
C2/6E38: 20 4E 8A     JSR $8A4E
C2/6E3B: A5 59        LDA $59
C2/6E3D: F0 0C        BEQ $6E4B
C2/6E3F: A5 59        LDA $59
C2/6E41: 8D D8 3E     STA $3ED8       ; status duration
C2/6E44: A9 08        LDA #$08
C2/6E46: 85 59        STA $59
C2/6E48: 20 05 8E     JSR $8E05
C2/6E4B: 60           RTS 

; [ attack effect $2B: damage based on attacker hp ]

; exploder, holy breath, poison breath, dragon breath

C2/6E4C: A5 57        LDA $57
C2/6E4E: 85 4D        STA $4D
C2/6E50: 20 B5 87     JSR $87B5
C2/6E53: A5 56        LDA $56
C2/6E55: D0 06        BNE $6E5D
C2/6E57: 20 9D 8A     JSR $8A9D
C2/6E5A: 20 DB 90     JSR $90DB
C2/6E5D: 60           RTS 

; [ attack effect $2C: random effect ]

; blaster, needle

C2/6E5E: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/6E61: C9 32        CMP #$32
C2/6E63: B0 07        BCS $6E6C
C2/6E65: A5 57        LDA $57
C2/6E67: 85 59        STA $59
C2/6E69: 4C AC 8C     JMP $8CAC
C2/6E6C: 20 7D 8B     JSR $8B7D
C2/6E6F: 4C 2E 8D     JMP $8D2E

; [ attack effect $2D: earth attacks ]

; rage of the earth, earth shaker, quake, squirrel, wild boar, earthquake

C2/6E72: 20 03 7E     JSR $7E03
C2/6E75: A5 56        LDA $56
C2/6E77: D0 1A        BNE $6E93
C2/6E79: A5 59        LDA $59
C2/6E7B: 85 4D        STA $4D
C2/6E7D: 20 30 7F     JSR $7F30
C2/6E80: 20 66 83     JSR $8366
C2/6E83: 20 F3 84     JSR $84F3
C2/6E86: 20 6D 86     JSR $866D
C2/6E89: 20 6E 87     JSR $876E
C2/6E8C: A5 56        LDA $56
C2/6E8E: D0 03        BNE $6E93
C2/6E90: 20 05 8A     JSR $8A05
C2/6E93: AD 97 7C     LDA $7C97
C2/6E96: F0 02        BEQ $6E9A
C2/6E98: 64 56        STZ $56
C2/6E9A: 60           RTS 

; [ attack effect $2E: reaper's sword ]

C2/6E9B: 20 1B 7F     JSR $7F1B
C2/6E9E: A5 56        LDA $56
C2/6EA0: D0 0E        BNE $6EB0
C2/6EA2: 20 C2 7F     JSR $7FC2
C2/6EA5: 20 12 85     JSR $8512
C2/6EA8: 20 05 8A     JSR $8A05
C2/6EAB: 20 AC 8C     JSR $8CAC
C2/6EAE: 64 56        STZ $56
C2/6EB0: 60           RTS 

; [ attack effect $2F:  ]

C2/6EB1: 20 5B 7E     JSR $7E5B
C2/6EB4: A5 56        LDA $56
C2/6EB6: D0 03        BNE $6EBB
C2/6EB8: 20 AC 8C     JSR $8CAC
C2/6EBB: 60           RTS 

; [ attack effect $30: unarmed ]

C2/6EBC: 20 47 7C     JSR $7C47
C2/6EBF: 20 BE 7E     JSR $7EBE
C2/6EC2: A5 56        LDA $56
C2/6EC4: F0 05        BEQ $6ECB
C2/6EC6: A9 80        LDA #$80
C2/6EC8: 85 56        STA $56
C2/6ECA: 60           RTS 
C2/6ECB: 20 3E 80     JSR $803E
C2/6ECE: 20 9B 83     JSR $839B
C2/6ED1: 20 BD 83     JSR $83BD
C2/6ED4: 20 12 85     JSR $8512
C2/6ED7: 20 33 85     JSR $8533
C2/6EDA: 20 DF 87     JSR $87DF
C2/6EDD: 20 05 8A     JSR $8A05
C2/6EE0: 60           RTS 

; [ attack effect $31: sword ]

C2/6EE1: 20 47 7C     JSR $7C47
C2/6EE4: 20 BE 7E     JSR $7EBE
C2/6EE7: A5 56        LDA $56
C2/6EE9: D0 2E        BNE $6F19
C2/6EEB: 20 FC 7F     JSR $7FFC
C2/6EEE: 20 9B 83     JSR $839B
C2/6EF1: 20 BD 83     JSR $83BD
C2/6EF4: 20 30 84     JSR $8430
C2/6EF7: 20 12 85     JSR $8512
C2/6EFA: 20 33 85     JSR $8533
C2/6EFD: 20 84 86     JSR $8684
C2/6F00: A5 61        LDA $61
C2/6F02: D0 19        BNE $6F1D
C2/6F04: A5 56        LDA $56
C2/6F06: D0 11        BNE $6F19
C2/6F08: A5 57        LDA $57
C2/6F0A: 85 4D        STA $4D
C2/6F0C: 20 34 87     JSR $8734
C2/6F0F: A5 56        LDA $56
C2/6F11: D0 06        BNE $6F19
C2/6F13: 20 11 88     JSR $8811
C2/6F16: 4C CF 8B     JMP $8BCF
C2/6F19: A9 80        LDA #$80
C2/6F1B: 85 56        STA $56
C2/6F1D: 60           RTS 

; [ attack effect $32: knife ]

C2/6F1E: 20 53 7C     JSR $7C53       ; calculate hit% (100%, evade / 2)
C2/6F21: 20 BE 7E     JSR $7EBE
C2/6F24: A5 56        LDA $56
C2/6F26: D0 2B        BNE $6F53
C2/6F28: 20 D4 80     JSR $80D4
C2/6F2B: 20 9B 83     JSR $839B
C2/6F2E: 20 BD 83     JSR $83BD
C2/6F31: 20 12 85     JSR $8512
C2/6F34: 20 33 85     JSR $8533
C2/6F37: 20 84 86     JSR $8684
C2/6F3A: A5 61        LDA $61
C2/6F3C: D0 19        BNE $6F57
C2/6F3E: A5 56        LDA $56
C2/6F40: D0 11        BNE $6F53
C2/6F42: A5 57        LDA $57
C2/6F44: 85 4D        STA $4D
C2/6F46: 20 34 87     JSR $8734
C2/6F49: A5 56        LDA $56
C2/6F4B: D0 06        BNE $6F53
C2/6F4D: 20 11 88     JSR $8811
C2/6F50: 4C CF 8B     JMP $8BCF
C2/6F53: A9 80        LDA #$80
C2/6F55: 85 56        STA $56
C2/6F57: 60           RTS 

; [ attack effect $33: spear ]

C2/6F58: 20 47 7C     JSR $7C47
C2/6F5B: 20 BE 7E     JSR $7EBE
C2/6F5E: A5 56        LDA $56
C2/6F60: D0 1D        BNE $6F7F
C2/6F62: 20 FC 7F     JSR $7FFC
C2/6F65: 20 BD 83     JSR $83BD
C2/6F68: 20 52 84     JSR $8452
C2/6F6B: 20 12 85     JSR $8512
C2/6F6E: 20 33 85     JSR $8533
C2/6F71: A5 57        LDA $57
C2/6F73: 85 4D        STA $4D
C2/6F75: 20 34 87     JSR $8734
C2/6F78: A5 56        LDA $56
C2/6F7A: D0 03        BNE $6F7F
C2/6F7C: 4C 05 8A     JMP $8A05
C2/6F7F: A9 80        LDA #$80
C2/6F81: 85 56        STA $56
C2/6F83: 60           RTS 

; [ attack effect $34: axe/staff ]

C2/6F84: 20 60 7C     JSR $7C60       ; calculate hit% (normal)
C2/6F87: 20 BE 7E     JSR $7EBE
C2/6F8A: A5 56        LDA $56
C2/6F8C: D0 15        BNE $6FA3
C2/6F8E: 20 2B 81     JSR $812B
C2/6F91: 20 9B 83     JSR $839B
C2/6F94: 20 BD 83     JSR $83BD
C2/6F97: 20 30 84     JSR $8430
C2/6F9A: 20 12 85     JSR $8512
C2/6F9D: 20 33 85     JSR $8533
C2/6FA0: 4C 05 8A     JMP $8A05
C2/6FA3: A9 80        LDA #$80
C2/6FA5: 85 56        STA $56
C2/6FA7: 60           RTS 

; [ attack effect $35: bow w/ status ]

C2/6FA8: 20 6C 7C     JSR $7C6C
C2/6FAB: 20 BE 7E     JSR $7EBE
C2/6FAE: A5 56        LDA $56
C2/6FB0: D0 12        BNE $6FC4
C2/6FB2: 20 D4 80     JSR $80D4
C2/6FB5: 20 BD 83     JSR $83BD
C2/6FB8: 20 12 85     JSR $8512
C2/6FBB: 20 33 85     JSR $8533
C2/6FBE: 20 05 8A     JSR $8A05
C2/6FC1: 4C F9 8B     JMP $8BF9
C2/6FC4: A9 80        LDA #$80
C2/6FC6: 85 56        STA $56
C2/6FC8: 60           RTS 

; [ attack effect $36: bow ]

C2/6FC9: 20 6C 7C     JSR $7C6C
C2/6FCC: 20 BE 7E     JSR $7EBE
C2/6FCF: A5 56        LDA $56
C2/6FD1: D0 21        BNE $6FF4
C2/6FD3: 20 D4 80     JSR $80D4
C2/6FD6: 20 BD 83     JSR $83BD
C2/6FD9: 20 12 85     JSR $8512
C2/6FDC: 20 33 85     JSR $8533
C2/6FDF: A5 59        LDA $59
C2/6FE1: 85 4D        STA $4D
C2/6FE3: 20 34 87     JSR $8734
C2/6FE6: A5 56        LDA $56
C2/6FE8: D0 0A        BNE $6FF4
C2/6FEA: A5 58        LDA $58
C2/6FEC: 85 57        STA $57
C2/6FEE: 20 DF 87     JSR $87DF
C2/6FF1: 4C 05 8A     JMP $8A05
C2/6FF4: A9 80        LDA #$80
C2/6FF6: 85 56        STA $56
C2/6FF8: 60           RTS 

; [ attack effect $37: katana ]

C2/6FF9: 20 47 7C     JSR $7C47
C2/6FFC: 20 BE 7E     JSR $7EBE
C2/6FFF: A5 56        LDA $56
C2/7001: D0 18        BNE $701B
C2/7003: 20 FC 7F     JSR $7FFC
C2/7006: 20 9B 83     JSR $839B
C2/7009: 20 BD 83     JSR $83BD
C2/700C: 20 30 84     JSR $8430
C2/700F: 20 12 85     JSR $8512
C2/7012: 20 33 85     JSR $8533
C2/7015: 20 DF 87     JSR $87DF
C2/7018: 4C 05 8A     JMP $8A05
C2/701B: A9 80        LDA #$80
C2/701D: 85 56        STA $56
C2/701F: 60           RTS 

; [ attack effect $38: whip ]

C2/7020: 20 60 7C     JSR $7C60       ; calculate hit% (normal)
C2/7023: 20 BE 7E     JSR $7EBE
C2/7026: A5 56        LDA $56
C2/7028: D0 0F        BNE $7039
C2/702A: 20 D4 80     JSR $80D4
C2/702D: 20 BD 83     JSR $83BD
C2/7030: 20 12 85     JSR $8512
C2/7033: 20 33 85     JSR $8533
C2/7036: 4C 05 8A     JMP $8A05
C2/7039: A9 80        LDA #$80
C2/703B: 85 56        STA $56
C2/703D: 60           RTS 

; [ attack effect $39: bell ]

C2/703E: 20 F1 7D     JSR $7DF1
C2/7041: A5 56        LDA $56
C2/7043: D0 09        BNE $704E
C2/7045: 20 6F 81     JSR $816F
C2/7048: 20 F3 84     JSR $84F3
C2/704B: 4C 05 8A     JMP $8A05
C2/704E: A9 80        LDA #$80
C2/7050: 85 56        STA $56
C2/7052: 60           RTS 

; [ attack effect $3A: long reach axe ]

C2/7053: 20 60 7C     JSR $7C60       ; calculate hit% (normal)
C2/7056: 20 BE 7E     JSR $7EBE
C2/7059: A5 56        LDA $56
C2/705B: D0 12        BNE $706F
C2/705D: 20 2B 81     JSR $812B
C2/7060: 20 BD 83     JSR $83BD
C2/7063: 20 30 84     JSR $8430
C2/7066: 20 12 85     JSR $8512
C2/7069: 20 33 85     JSR $8533
C2/706C: 4C 05 8A     JMP $8A05
C2/706F: A9 80        LDA #$80
C2/7071: 85 56        STA $56
C2/7073: 60           RTS 

; [ attack effect $3B: rod ]

C2/7074: 20 79 7C     JSR $7C79       ; calculate hit% (magic evade)
C2/7077: 20 97 7C     JSR $7C97
C2/707A: 20 8B 7D     JSR $7D8B
C2/707D: 20 12 7E     JSR $7E12       ; check hit/evade
C2/7080: A5 56        LDA $56
C2/7082: D0 14        BNE $7098       ; branch if attack missed
C2/7084: 20 CB 81     JSR $81CB
C2/7087: 20 F3 84     JSR $84F3
C2/708A: A5 59        LDA $59         ; parameter 3
C2/708C: 85 4D        STA $4D
C2/708E: 20 34 87     JSR $8734
C2/7091: A5 56        LDA $56
C2/7093: D0 03        BNE $7098
C2/7095: 4C 05 8A     JMP $8A05
C2/7098: A9 80        LDA #$80
C2/709A: 85 56        STA $56
C2/709C: 60           RTS 

; [ attack effect $3C: rune weapon ]

C2/709D: 20 60 7C     JSR $7C60       ; calculate hit% (normal)
C2/70A0: 20 BE 7E     JSR $7EBE
C2/70A3: A5 56        LDA $56
C2/70A5: D0 18        BNE $70BF
C2/70A7: 20 2B 81     JSR $812B
C2/70AA: 20 67 84     JSR $8467
C2/70AD: 20 9B 83     JSR $839B
C2/70B0: 20 BD 83     JSR $83BD
C2/70B3: 20 30 84     JSR $8430
C2/70B6: 20 12 85     JSR $8512
C2/70B9: 20 33 85     JSR $8533
C2/70BC: 4C 05 8A     JMP $8A05
C2/70BF: A9 80        LDA #$80
C2/70C1: 85 56        STA $56
C2/70C3: 60           RTS 

; [ attack effect $3D: death claw ]

C2/70C4: 20 F6 7E     JSR $7EF6
C2/70C7: A5 56        LDA $56
C2/70C9: D0 0F        BNE $70DA
C2/70CB: 20 FD 88     JSR $88FD
C2/70CE: A5 56        LDA $56
C2/70D0: D0 08        BNE $70DA
C2/70D2: 20 7D 8B     JSR $8B7D
C2/70D5: 20 2E 8D     JSR $8D2E
C2/70D8: 64 56        STZ $56
C2/70DA: 60           RTS 

; [ attack effect $3E:  ]

C2/70DB: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/70DE: C5 57        CMP $57
C2/70E0: B0 03        BCS $70E5
C2/70E2: 4C FD 88     JMP $88FD
C2/70E5: 20 7D 8B     JSR $8B7D
C2/70E8: 20 05 8E     JSR $8E05
C2/70EB: 60           RTS 

; [ attack effect $3F: zombie breath ]

C2/70EC: 20 97 7C     JSR $7C97
C2/70EF: A5 56        LDA $56
C2/70F1: D0 25        BNE $7118
C2/70F3: 20 A7 7F     JSR $7FA7
C2/70F6: 20 F3 84     JSR $84F3
C2/70F9: 20 05 8A     JSR $8A05
C2/70FC: A6 49        LDX $49
C2/70FE: BD 06 20     LDA $2006,X
C2/7101: 85 0E        STA $0E
C2/7103: BD 07 20     LDA $2007,X
C2/7106: 85 0F        STA $0F
C2/7108: AE 6D 7B     LDX $7B6D
C2/710B: E4 0E        CPX $0E
C2/710D: 90 09        BCC $7118
C2/710F: A6 49        LDX $49
C2/7111: A9 02        LDA #$02
C2/7113: 85 59        STA $59
C2/7115: 20 AC 8C     JSR $8CAC
C2/7118: 60           RTS 

; [ attack effect $40: change row ]

; dynamo, magnet, row command

C2/7119: 20 F6 7E     JSR $7EF6
C2/711C: A5 56        LDA $56
C2/711E: D0 13        BNE $7133
C2/7120: A5 58        LDA $58
C2/7122: 10 03        BPL $7127
C2/7124: 4C 01 91     JMP $9101
C2/7127: A5 58        LDA $58
C2/7129: 29 40        AND #$40
C2/712B: F0 03        BEQ $7130
C2/712D: 4C 17 91     JMP $9117
C2/7130: 4C 22 91     JMP $9122
C2/7133: 60           RTS 

; [ attack effect $41:  ]

C2/7134: 20 61 82     JSR $8261
C2/7137: 20 12 85     JSR $8512
C2/713A: 20 33 85     JSR $8533
C2/713D: 4C 05 8A     JMP $8A05

; [ attack effect $42: hp + remove status 0 ]

C2/7140: 20 30 7F     JSR $7F30
C2/7143: 20 C1 88     JSR $88C1
C2/7146: A5 57        LDA $57
C2/7148: 10 03        BPL $714D
C2/714A: 4C B6 8E     JMP $8EB6
C2/714D: 4C 11 8F     JMP $8F11

; [ attack effect $43: steal ]

C2/7150: 9C 9A 7C     STZ $7C9A       ; clear nothing to steal flag
C2/7153: A6 49        LDX $49
C2/7155: BD 6B 20     LDA $206B,X
C2/7158: F0 05        BEQ $715F
C2/715A: EE 9A 7C     INC $7C9A       ; nothing to steal
C2/715D: 80 37        BRA $7196
C2/715F: 38           SEC 
C2/7160: A5 48        LDA $48         ; target
C2/7162: E9 04        SBC #$04
C2/7164: 0A           ASL 
C2/7165: AA           TAX 
C2/7166: C2 20        REP #$20
C2/7168: BD 20 40     LDA $4020,X     ; monster index
C2/716B: 20 B7 01     JSR $01B7       ; a << 2
C2/716E: AA           TAX 
C2/716F: 7B           TDC 
C2/7170: E2 20        SEP #$20
C2/7172: BF 00 50 D0  LDA $D05000,X   ; monster items
C2/7176: 1F 01 50 D0  ORA $D05001,X
C2/717A: D0 05        BNE $7181
C2/717C: EE 9A 7C     INC $7C9A       ; nothing to steal
C2/717F: 80 15        BRA $7196
C2/7181: 20 85 7C     JSR $7C85       ; calculate hit% (steal)
C2/7184: 20 12 7E     JSR $7E12       ; check hit/evade
C2/7187: A5 56        LDA $56
C2/7189: D0 0B        BNE $7196
C2/718B: 20 08 92     JSR $9208
C2/718E: A5 56        LDA $56
C2/7190: D0 04        BNE $7196
C2/7192: A9 21        LDA #$21        ; "Stole “\item”!"
C2/7194: 80 0D        BRA $71A3
C2/7196: E6 56        INC $56         ; miss
C2/7198: AD 9A 7C     LDA $7C9A
C2/719B: F0 04        BEQ $71A1
C2/719D: A9 4B        LDA #$4B        ; "Doesn’t have anything!"
C2/719F: 80 02        BRA $71A3
C2/71A1: A9 22        LDA #$22        ; "Couldn't steal"
C2/71A3: 48           PHA 
C2/71A4: 20 65 99     JSR $9965
C2/71A7: AD 46 47     LDA $4746
C2/71AA: C9 0B        CMP #$0B
C2/71AC: F0 04        BEQ $71B2
C2/71AE: C9 33        CMP #$33
C2/71B0: D0 02        BNE $71B4
C2/71B2: 7B           TDC 
C2/71B3: AA           TAX 
C2/71B4: 68           PLA 
C2/71B5: 9D 5F 3C     STA $3C5F,X
C2/71B8: 60           RTS 

; [ attack effect $44: escape ]

C2/71B9: A5 47        LDA $47
C2/71BB: C9 04        CMP #$04
C2/71BD: 90 17        BCC $71D6
C2/71BF: 38           SEC 
C2/71C0: E9 04        SBC #$04
C2/71C2: AA           TAX 
C2/71C3: FE AE 7C     INC $7CAE,X
C2/71C6: AD 0A 7C     LDA $7C0A
C2/71C9: 20 D6 01     JSR $01D6       ; set bit x
C2/71CC: 8D 0A 7C     STA $7C0A
C2/71CF: A6 32        LDX $32
C2/71D1: A9 80        LDA #$80
C2/71D3: 9D 1A 20     STA $201A,X
C2/71D6: 60           RTS 

; [ attack effect $45: throw ]

C2/71D7: A5 57        LDA $57
C2/71D9: 85 4E        STA $4E
C2/71DB: 7B           TDC 
C2/71DC: 85 4F        STA $4F
C2/71DE: 20 BE 7E     JSR $7EBE
C2/71E1: A5 56        LDA $56
C2/71E3: D0 0F        BNE $71F4
C2/71E5: 20 99 82     JSR $8299
C2/71E8: 20 BD 83     JSR $83BD
C2/71EB: 20 12 85     JSR $8512
C2/71EE: 20 33 85     JSR $8533
C2/71F1: 20 05 8A     JSR $8A05
C2/71F4: 60           RTS 

; [ attack effect $46: giltoss ]

C2/71F5: 20 0A 83     JSR $830A
C2/71F8: 4C 05 8A     JMP $8A05

; [ attack effect $47: tame ]

C2/71FB: A6 49        LDX $49
C2/71FD: BD 65 20     LDA $2065,X
C2/7200: 29 04        AND #$04
C2/7202: F0 06        BEQ $720A
C2/7204: 20 7D 8B     JSR $8B7D
C2/7207: 4C CB 8D     JMP $8DCB
C2/720A: E6 56        INC $56         ; miss
C2/720C: 60           RTS 

; [ attack effect $48: catch ]

C2/720D: 20 65 99     JSR $9965
C2/7210: 86 14        STX $14
C2/7212: A6 49        LDX $49
C2/7214: BD 66 20     LDA $2066,X
C2/7217: 29 08        AND #$08
C2/7219: F0 04        BEQ $721F
C2/721B: A9 4F        LDA #$4F
C2/721D: 80 29        BRA $7248
C2/721F: BD 1D 20     LDA $201D,X
C2/7222: 29 02        AND #$02
C2/7224: D0 2B        BNE $7251
C2/7226: A6 32        LDX $32
C2/7228: BD 39 20     LDA $2039,X
C2/722B: 29 01        AND #$01
C2/722D: F0 17        BEQ $7246
C2/722F: A6 49        LDX $49
C2/7231: C2 20        REP #$20
C2/7233: BD 08 20     LDA $2008,X
C2/7236: 4A           LSR 
C2/7237: DD 06 20     CMP $2006,X
C2/723A: B0 05        BCS $7241
C2/723C: 7B           TDC 
C2/723D: E2 20        SEP #$20
C2/723F: 80 05        BRA $7246
C2/7241: 7B           TDC 
C2/7242: E2 20        SEP #$20
C2/7244: 80 0B        BRA $7251
C2/7246: A9 25        LDA #$25        ; "Weaken it some more!"
C2/7248: A6 14        LDX $14
C2/724A: 9D 5F 3C     STA $3C5F,X
C2/724D: E6 56        INC $56         ; miss
C2/724F: 80 03        BRA $7254
C2/7251: 20 A5 93     JSR $93A5
C2/7254: 60           RTS 

; [ attack effect $49: flirt ]

; flirt, lillith rod

C2/7255: 20 0D 7C     JSR $7C0D       ; calculate hit% (magic attack)
C2/7258: 20 7F 7D     JSR $7D7F
C2/725B: 20 12 7E     JSR $7E12       ; check hit/evade
C2/725E: A5 56        LDA $56
C2/7260: D0 03        BNE $7265
C2/7262: 20 3A 8E     JSR $8E3A
C2/7265: 60           RTS 

; [ attack effect $4A: dance ]
; [ attack effect $4B: l5 doom ]

C2/7266: 20 67 7E     JSR $7E67
C2/7269: A5 56        LDA $56
C2/726B: D0 1F        BNE $728C
C2/726D: A6 49        LDX $49
C2/726F: BD 65 20     LDA $2065,X
C2/7272: 29 01        AND #$01
C2/7274: D0 07        BNE $727D
C2/7276: BD 39 20     LDA $2039,X
C2/7279: 29 02        AND #$02
C2/727B: F0 0C        BEQ $7289
C2/727D: C2 20        REP #$20
C2/727F: BD 08 20     LDA $2008,X
C2/7282: 9D 06 20     STA $2006,X
C2/7285: 7B           TDC 
C2/7286: E2 20        SEP #$20
C2/7288: 60           RTS 
C2/7289: 20 2B 90     JSR $902B
C2/728C: 60           RTS 

; [ attack effect $4C: l2 old ]

C2/728D: 20 67 7E     JSR $7E67
C2/7290: A5 56        LDA $56
C2/7292: D0 06        BNE $729A
C2/7294: 20 7D 8B     JSR $8B7D
C2/7297: 20 39 90     JSR $9039
C2/729A: 60           RTS 

; [ attack effect $4D: l4 qrter ]

C2/729B: 20 67 7E     JSR $7E67
C2/729E: A5 56        LDA $56
C2/72A0: D0 0F        BNE $72B1
C2/72A2: 20 74 88     JSR $8874
C2/72A5: A9 3C        LDA #$3C
C2/72A7: 85 58        STA $58
C2/72A9: 20 7D 8B     JSR $8B7D
C2/72AC: 20 39 90     JSR $9039
C2/72AF: 64 56        STZ $56
C2/72B1: 60           RTS 

; [ attack effect $4E: l3 flare ]

C2/72B2: 20 67 7E     JSR $7E67
C2/72B5: A5 56        LDA $56
C2/72B7: D0 1A        BNE $72D3
C2/72B9: A5 59        LDA $59
C2/72BB: 85 4D        STA $4D
C2/72BD: 20 6A 7F     JSR $7F6A
C2/72C0: 20 66 83     JSR $8366
C2/72C3: 20 F3 84     JSR $84F3
C2/72C6: 20 6D 86     JSR $866D
C2/72C9: 20 6E 87     JSR $876E
C2/72CC: A5 56        LDA $56
C2/72CE: D0 03        BNE $72D3
C2/72D0: 20 05 8A     JSR $8A05
C2/72D3: AD 97 7C     LDA $7C97
C2/72D6: F0 02        BEQ $72DA
C2/72D8: 64 56        STZ $56
C2/72DA: 60           RTS 

; [ attack effect $4F: spirit ]

C2/72DB: A5 48        LDA $48
C2/72DD: A8           TAY 
C2/72DE: B9 C2 3E     LDA $3EC2,Y
C2/72E1: D0 1A        BNE $72FD
C2/72E3: 20 AA 8F     JSR $8FAA
C2/72E6: A5 56        LDA $56
C2/72E8: D0 15        BNE $72FF
C2/72EA: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/72ED: C5 57        CMP $57
C2/72EF: 90 05        BCC $72F6
C2/72F1: EE 5D 7C     INC $7C5D
C2/72F4: 80 09        BRA $72FF
C2/72F6: A9 02        LDA #$02
C2/72F8: 85 59        STA $59
C2/72FA: 4C AC 8C     JMP $8CAC
C2/72FD: E6 56        INC $56         ; miss
C2/72FF: 60           RTS 

; [ attack effect $50: goblin punch ]

C2/7300: 20 1B 7F     JSR $7F1B
C2/7303: A5 56        LDA $56
C2/7305: D0 11        BNE $7318
C2/7307: 20 AD 85     JSR $85AD
C2/730A: 20 5D 85     JSR $855D
C2/730D: 20 12 85     JSR $8512
C2/7310: 20 05 8A     JSR $8A05
C2/7313: 20 AC 8C     JSR $8CAC
C2/7316: 64 56        STZ $56
C2/7318: 60           RTS 

; [ attack effect $51: modify stats ]

; power drink, hero drink, dark shock, guard off, sonic wave, dragon power, sampson power, split shell

C2/7319: 20 F6 7E     JSR $7EF6
C2/731C: A5 56        LDA $56
C2/731E: D0 3D        BNE $735D
C2/7320: A5 58        LDA $58
C2/7322: 10 03        BPL $7327
C2/7324: 20 36 91     JSR $9136
C2/7327: A5 58        LDA $58
C2/7329: 29 40        AND #$40
C2/732B: F0 03        BEQ $7330
C2/732D: 20 36 91     JSR $9136
C2/7330: A5 58        LDA $58
C2/7332: 29 20        AND #$20
C2/7334: F0 03        BEQ $7339
C2/7336: 20 2D 91     JSR $912D
C2/7339: A5 58        LDA $58
C2/733B: 29 10        AND #$10
C2/733D: F0 03        BEQ $7342
C2/733F: 20 43 91     JSR $9143
C2/7342: A5 58        LDA $58
C2/7344: 29 08        AND #$08
C2/7346: F0 03        BEQ $734B
C2/7348: 20 53 91     JSR $9153
C2/734B: A5 58        LDA $58
C2/734D: 29 04        AND #$04
C2/734F: F0 03        BEQ $7354
C2/7351: 20 97 91     JSR $9197
C2/7354: A5 58        LDA $58
C2/7356: 29 02        AND #$02
C2/7358: F0 03        BEQ $735D
C2/735A: 20 B4 91     JSR $91B4
C2/735D: 60           RTS 

; [ attack effect $52: mucus ]

C2/735E: 20 F6 7E     JSR $7EF6
C2/7361: A5 56        LDA $56
C2/7363: D0 13        BNE $7378
C2/7365: 20 51 8E     JSR $8E51
C2/7368: A5 56        LDA $56
C2/736A: D0 0C        BNE $7378
C2/736C: A9 FF        LDA #$FF
C2/736E: 8D D8 3E     STA $3ED8       ; status duration
C2/7371: A9 08        LDA #$08
C2/7373: 85 59        STA $59
C2/7375: 20 05 8E     JSR $8E05
C2/7378: 60           RTS 

; [ attack effect $53: mp damage ]

C2/7379: 20 F6 7E     JSR $7EF6
C2/737C: A5 56        LDA $56
C2/737E: D0 03        BNE $7383
C2/7380: 20 EC 8A     JSR $8AEC
C2/7383: 60           RTS 

; [ attack effect $54: damage based on attacker hp (negative) ]

; dark breath

C2/7384: 20 F6 7E     JSR $7EF6
C2/7387: A5 56        LDA $56
C2/7389: D0 03        BNE $738E
C2/738B: 20 33 8B     JSR $8B33
C2/738E: 60           RTS 

; [ attack effect $55: fusion ]

C2/738F: 20 DE 88     JSR $88DE
C2/7392: 20 F7 89     JSR $89F7
C2/7395: 4C DB 90     JMP $90DB

; [ attack effect $56:  ]

C2/7398: 20 F6 7E     JSR $7EF6
C2/739B: A5 56        LDA $56
C2/739D: D0 03        BNE $73A2
C2/739F: 20 D1 91     JSR $91D1
C2/73A2: 60           RTS 

; [ attack effect $57: random effect ]

; rainbow wind, dark sigh

C2/73A3: 20 7D 8B     JSR $8B7D
C2/73A6: 20 2E 8D     JSR $8D2E
C2/73A9: 64 56        STZ $56
C2/73AB: A5 57        LDA $57
C2/73AD: 85 59        STA $59
C2/73AF: 20 AC 8C     JSR $8CAC
C2/73B2: 64 56        STZ $56
C2/73B4: A9 FF        LDA #$FF
C2/73B6: 8D D8 3E     STA $3ED8       ; status duration
C2/73B9: A9 08        LDA #$08
C2/73BB: 85 59        STA $59
C2/73BD: 4C 05 8E     JMP $8E05

; [ attack effect $58: mind blast ]

C2/73C0: 20 F6 7E     JSR $7EF6
C2/73C3: A5 56        LDA $56
C2/73C5: D0 28        BNE $73EF
C2/73C7: 20 6A 7F     JSR $7F6A
C2/73CA: 20 66 83     JSR $8366
C2/73CD: 20 F3 84     JSR $84F3
C2/73D0: 20 05 8A     JSR $8A05
C2/73D3: A5 59        LDA $59
C2/73D5: 85 58        STA $58
C2/73D7: 20 7D 8B     JSR $8B7D
C2/73DA: A9 20        LDA #$20
C2/73DC: 85 59        STA $59
C2/73DE: 20 2E 8D     JSR $8D2E
C2/73E1: 64 56        STZ $56
C2/73E3: A9 FF        LDA #$FF
C2/73E5: 8D D8 3E     STA $3ED8       ; status duration
C2/73E8: A9 08        LDA #$08
C2/73EA: 85 59        STA $59
C2/73EC: 20 05 8E     JSR $8E05
C2/73EF: 60           RTS 

; [ attack effect $59: increase max hp ]

C2/73F0: A5 48        LDA $48
C2/73F2: C9 04        CMP #$04
C2/73F4: B0 0E        BCS $7404       ; always miss monsters
C2/73F6: A5 48        LDA $48
C2/73F8: AA           TAX 
C2/73F9: BD 59 7C     LDA $7C59,X
C2/73FC: D0 06        BNE $7404       ; miss if effect already active
C2/73FE: FE 59 7C     INC $7C59,X
C2/7401: 4C 63 91     JMP $9163
C2/7404: E6 56        INC $56         ; miss
C2/7406: 60           RTS 

; [ attack effect $5A: white wind ]

C2/7407: AE 64 7C     LDX $7C64
C2/740A: 8E 71 7B     STX $7B71
C2/740D: 60           RTS 

; [ attack effect $5B:  ]

C2/740E: 20 F6 7E     JSR $7EF6
C2/7411: A5 56        LDA $56
C2/7413: D0 03        BNE $7418
C2/7415: 20 DC 91     JSR $91DC
C2/7418: 60           RTS 

; [ attack effect $5C:  ]

C2/7419: 20 F6 7E     JSR $7EF6
C2/741C: A5 56        LDA $56
C2/741E: D0 06        BNE $7426
C2/7420: 20 DE 88     JSR $88DE
C2/7423: 20 AC 8C     JSR $8CAC
C2/7426: 60           RTS 

; [ attack effect $5D: inflict zombie ]

; dance of the dead, zombie powder

C2/7427: 20 F6 7E     JSR $7EF6
C2/742A: A5 56        LDA $56
C2/742C: D0 0E        BNE $743C
C2/742E: 20 AA 8F     JSR $8FAA
C2/7431: A5 56        LDA $56
C2/7433: D0 07        BNE $743C
C2/7435: A9 02        LDA #$02
C2/7437: 85 59        STA $59
C2/7439: 20 AC 8C     JSR $8CAC
C2/743C: 60           RTS 

; [ attack effect $5E: sing ]

C2/743D: 20 F1 7D     JSR $7DF1       ; 
C2/7440: A5 56        LDA $56
C2/7442: D0 17        BNE $745B       ; branch if attack missed
C2/7444: A6 32        LDX $32
C2/7446: BD 1D 20     LDA $201D,X     ; set singing status
C2/7449: 09 04        ORA #$04
C2/744B: 9D 1D 20     STA $201D,X
C2/744E: A5 59        LDA $59
C2/7450: 9D 6F 20     STA $206F,X     ; 
C2/7453: A9 08        LDA #$08        ; timer $08 (sing)
C2/7455: AA           TAX 
C2/7456: A5 48        LDA $48
C2/7458: 20 FD 24     JSR $24FD       ; start timer
C2/745B: 60           RTS 

; [ attack effect $5F: requiem ]

C2/745C: 20 5B 7E     JSR $7E5B
C2/745F: A5 56        LDA $56
C2/7461: D0 12        BNE $7475
C2/7463: 20 6A 7F     JSR $7F6A
C2/7466: 20 05 8A     JSR $8A05
C2/7469: A5 59        LDA $59
C2/746B: 8D D8 3E     STA $3ED8       ; status duration
C2/746E: A9 08        LDA #$08
C2/7470: 85 59        STA $59
C2/7472: 20 05 8E     JSR $8E05
C2/7475: 60           RTS 

; [ attack effect $60: hide (monster) ]

C2/7476: 7B           TDC 
C2/7477: AA           TAX 
C2/7478: BD 4D 38     LDA $384D,X
C2/747B: C9 F2        CMP #$F2
C2/747D: F0 07        BEQ $7486
C2/747F: E8           INX 
C2/7480: E8           INX 
C2/7481: E8           INX 
C2/7482: E8           INX 
C2/7483: E8           INX 
C2/7484: 80 F2        BRA $7478
C2/7486: BD 4E 38     LDA $384E,X
C2/7489: 85 11        STA $11
C2/748B: BD 4F 38     LDA $384F,X
C2/748E: 85 10        STA $10
C2/7490: 7B           TDC 
C2/7491: AA           TAX 
C2/7492: 86 0E        STX $0E
C2/7494: A6 0E        LDX $0E
C2/7496: AD 48 40     LDA $4048
C2/7499: 20 DB 01     JSR $01DB       ; check bit x
C2/749C: F0 1F        BEQ $74BD
C2/749E: A5 10        LDA $10
C2/74A0: 20 DB 01     JSR $01DB       ; check bit x
C2/74A3: F0 03        BEQ $74A8
C2/74A5: 4C 53 75     JMP $7553
C2/74A8: 7B           TDC 
C2/74A9: 20 D6 01     JSR $01D6       ; set bit x
C2/74AC: 0D 0A 7C     ORA $7C0A
C2/74AF: 8D 0A 7C     STA $7C0A
C2/74B2: 8A           TXA 
C2/74B3: 18           CLC 
C2/74B4: 69 04        ADC #$04
C2/74B6: AA           TAX 
C2/74B7: 9E C2 3E     STZ $3EC2,X
C2/74BA: 4C 53 75     JMP $7553
C2/74BD: A5 10        LDA $10
C2/74BF: 20 DB 01     JSR $01DB       ; check bit x
C2/74C2: D0 03        BNE $74C7
C2/74C4: 4C 53 75     JMP $7553
C2/74C7: 7B           TDC 
C2/74C8: 20 D6 01     JSR $01D6       ; set bit x
C2/74CB: 0D 48 40     ORA $4048
C2/74CE: 8D 48 40     STA $4048
C2/74D1: AD 0A 7C     LDA $7C0A
C2/74D4: 20 D1 01     JSR $01D1       ; clear bit x
C2/74D7: 8D 0A 7C     STA $7C0A
C2/74DA: 8A           TXA 
C2/74DB: 18           CLC 
C2/74DC: 69 04        ADC #$04
C2/74DE: AA           TAX 
C2/74DF: FE C2 3E     INC $3EC2,X
C2/74E2: C2 20        REP #$20
C2/74E4: 18           CLC 
C2/74E5: A5 0E        LDA $0E
C2/74E7: 69 04 00     ADC #$0004
C2/74EA: 20 B2 01     JSR $01B2       ; a << 7
C2/74ED: AA           TAX 
C2/74EE: 86 14        STX $14
C2/74F0: 7B           TDC 
C2/74F1: E2 20        SEP #$20
C2/74F3: 9E 1A 20     STZ $201A,X
C2/74F6: 9E 1B 20     STZ $201B,X
C2/74F9: 9E 1C 20     STZ $201C,X
C2/74FC: 9E 1D 20     STZ $201D,X
C2/74FF: 18           CLC 
C2/7500: A5 0E        LDA $0E
C2/7502: 69 04        ADC #$04
C2/7504: 20 07 02     JSR $0207       ; get timer data offset
C2/7507: 7B           TDC 
C2/7508: 99 F1 3C     STA $3CF1,Y
C2/750B: 99 F2 3C     STA $3CF2,Y
C2/750E: 99 F3 3C     STA $3CF3,Y
C2/7511: 99 F4 3C     STA $3CF4,Y
C2/7514: 99 F5 3C     STA $3CF5,Y
C2/7517: 99 F6 3C     STA $3CF6,Y
C2/751A: 99 F7 3C     STA $3CF7,Y
C2/751D: 99 F8 3C     STA $3CF8,Y
C2/7520: 99 F9 3C     STA $3CF9,Y
C2/7523: 99 FA 3C     STA $3CFA,Y
C2/7526: A5 11        LDA $11
C2/7528: 30 1C        BMI $7546
C2/752A: C2 20        REP #$20
C2/752C: A6 32        LDX $32
C2/752E: BD 06 20     LDA $2006,X
C2/7531: A6 14        LDX $14
C2/7533: 9D 06 20     STA $2006,X
C2/7536: DD 08 20     CMP $2008,X
C2/7539: 90 06        BCC $7541
C2/753B: BD 08 20     LDA $2008,X
C2/753E: 9D 06 20     STA $2006,X
C2/7541: 7B           TDC 
C2/7542: E2 20        SEP #$20
C2/7544: 80 0D        BRA $7553
C2/7546: C2 20        REP #$20
C2/7548: A6 14        LDX $14
C2/754A: BD 08 20     LDA $2008,X
C2/754D: 9D 06 20     STA $2006,X
C2/7550: 7B           TDC 
C2/7551: E2 20        SEP #$20
C2/7553: E6 0E        INC $0E
C2/7555: A5 0E        LDA $0E
C2/7557: C9 08        CMP #$08
C2/7559: F0 03        BEQ $755E
C2/755B: 4C 94 74     JMP $7494
C2/755E: EE FB 7B     INC $7BFB
C2/7561: 60           RTS 

; [ attack effect $61: stalker attack ]

C2/7562: AD 4C 7C     LDA $7C4C
C2/7565: D0 71        BNE $75D8
C2/7567: 7B           TDC 
C2/7568: A8           TAY 
C2/7569: A2 00 02     LDX #$0200
C2/756C: BD 1D 20     LDA $201D,X
C2/756F: 09 40        ORA #$40
C2/7571: 9D 1D 20     STA $201D,X
C2/7574: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/7577: C8           INY 
C2/7578: C0 08 00     CPY #$0008
C2/757B: D0 EF        BNE $756C
C2/757D: A2 04 00     LDX #$0004
C2/7580: A9 0B        LDA #$0B
C2/7582: 20 7C 00     JSR $007C       ; a = (x..a)
C2/7585: A8           TAY 
C2/7586: B9 C2 3E     LDA $3EC2,Y
C2/7589: F0 F2        BEQ $757D
C2/758B: 98           TYA 
C2/758C: C2 20        REP #$20
C2/758E: 20 B2 01     JSR $01B2       ; a << 7
C2/7591: AA           TAX 
C2/7592: 7B           TDC 
C2/7593: E2 20        SEP #$20
C2/7595: BD 1D 20     LDA $201D,X
C2/7598: 29 BF        AND #$BF
C2/759A: 9D 1D 20     STA $201D,X
C2/759D: 7B           TDC 
C2/759E: A8           TAY 
C2/759F: A2 00 02     LDX #$0200
C2/75A2: C2 20        REP #$20
C2/75A4: BD 06 20     LDA $2006,X
C2/75A7: 85 0E        STA $0E
C2/75A9: BD 06 20     LDA $2006,X
C2/75AC: C5 0E        CMP $0E
C2/75AE: B0 02        BCS $75B2
C2/75B0: 85 0E        STA $0E
C2/75B2: 18           CLC 
C2/75B3: 8A           TXA 
C2/75B4: 69 80 00     ADC #$0080
C2/75B7: AA           TAX 
C2/75B8: C8           INY 
C2/75B9: C0 04 00     CPY #$0004
C2/75BC: D0 EB        BNE $75A9
C2/75BE: 7B           TDC 
C2/75BF: A8           TAY 
C2/75C0: A2 00 02     LDX #$0200
C2/75C3: A5 0E        LDA $0E
C2/75C5: 9D 06 20     STA $2006,X
C2/75C8: 18           CLC 
C2/75C9: 8A           TXA 
C2/75CA: 69 80 00     ADC #$0080
C2/75CD: AA           TAX 
C2/75CE: C8           INY 
C2/75CF: C0 04 00     CPY #$0004
C2/75D2: D0 EF        BNE $75C3
C2/75D4: 7B           TDC 
C2/75D5: E2 20        SEP #$20
C2/75D7: 60           RTS 
C2/75D8: 7B           TDC 
C2/75D9: AA           TAX 
C2/75DA: BD 4D 38     LDA $384D,X
C2/75DD: C9 F2        CMP #$F2
C2/75DF: F0 07        BEQ $75E8
C2/75E1: E8           INX 
C2/75E2: E8           INX 
C2/75E3: E8           INX 
C2/75E4: E8           INX 
C2/75E5: E8           INX 
C2/75E6: 80 F2        BRA $75DA
C2/75E8: 86 10        STX $10
C2/75EA: 7B           TDC 
C2/75EB: A8           TAY 
C2/75EC: A2 00 02     LDX #$0200
C2/75EF: BD 1D 20     LDA $201D,X
C2/75F2: 09 40        ORA #$40
C2/75F4: 9D 1D 20     STA $201D,X
C2/75F7: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/75FA: C8           INY 
C2/75FB: C0 06 00     CPY #$0006
C2/75FE: D0 EF        BNE $75EF
C2/7600: A2 07 00     LDX #$0007
C2/7603: A9 09        LDA #$09
C2/7605: 20 7C 00     JSR $007C       ; a = (x..a)
C2/7608: 85 0E        STA $0E
C2/760A: C2 20        REP #$20
C2/760C: 20 B2 01     JSR $01B2       ; a << 7
C2/760F: AA           TAX 
C2/7610: 7B           TDC 
C2/7611: E2 20        SEP #$20
C2/7613: BD 1D 20     LDA $201D,X
C2/7616: 29 BF        AND #$BF
C2/7618: 9D 1D 20     STA $201D,X
C2/761B: 9C C9 3E     STZ $3EC9
C2/761E: 9C CA 3E     STZ $3ECA
C2/7621: 9C CB 3E     STZ $3ECB
C2/7624: EE C6 3E     INC $3EC6
C2/7627: EE C7 3E     INC $3EC7
C2/762A: EE C8 3E     INC $3EC8
C2/762D: A5 0E        LDA $0E
C2/762F: AA           TAX 
C2/7630: FE C2 3E     INC $3EC2,X
C2/7633: 38           SEC 
C2/7634: E9 07        SBC #$07
C2/7636: AA           TAX 
C2/7637: A9 E0        LDA #$E0
C2/7639: 20 D1 01     JSR $01D1       ; clear bit x
C2/763C: 85 12        STA $12
C2/763E: 38           SEC 
C2/763F: A5 0E        LDA $0E
C2/7641: E9 03        SBC #$03
C2/7643: AA           TAX 
C2/7644: 9E C2 3E     STZ $3EC2,X
C2/7647: 38           SEC 
C2/7648: A5 0E        LDA $0E
C2/764A: E9 04        SBC #$04
C2/764C: AA           TAX 
C2/764D: A5 12        LDA $12
C2/764F: 20 D6 01     JSR $01D6       ; set bit x
C2/7652: A6 10        LDX $10
C2/7654: 9D 4F 38     STA $384F,X
C2/7657: A9 02        LDA #$02
C2/7659: 8D 09 7C     STA $7C09
C2/765C: A9 FD        LDA #$FD
C2/765E: 8D 0A 7C     STA $7C0A
C2/7661: 60           RTS 

; [ attack effect $62: byblos attack ]

C2/7662: 7B           TDC 
C2/7663: AA           TAX 
C2/7664: BD 4D 38     LDA $384D,X
C2/7667: C9 F2        CMP #$F2
C2/7669: F0 07        BEQ $7672
C2/766B: E8           INX 
C2/766C: E8           INX 
C2/766D: E8           INX 
C2/766E: E8           INX 
C2/766F: E8           INX 
C2/7670: 80 F2        BRA $7664
C2/7672: 38           SEC 
C2/7673: A5 47        LDA $47
C2/7675: E9 04        SBC #$04
C2/7677: 1A           INC 
C2/7678: 85 0E        STA $0E
C2/767A: 0A           ASL 
C2/767B: A8           TAY 
C2/767C: B9 20 40     LDA $4020,Y
C2/767F: 39 21 40     AND $4021,Y
C2/7682: C9 FF        CMP #$FF
C2/7684: F0 42        BEQ $76C8
C2/7686: DA           PHX 
C2/7687: A5 0E        LDA $0E
C2/7689: AA           TAX 
C2/768A: 7B           TDC 
C2/768B: 20 D6 01     JSR $01D6       ; set bit x
C2/768E: FA           PLX 
C2/768F: 9D 4F 38     STA $384F,X
C2/7692: A5 0E        LDA $0E
C2/7694: AA           TAX 
C2/7695: CA           DEX 
C2/7696: 7B           TDC 
C2/7697: 20 D6 01     JSR $01D6       ; set bit x
C2/769A: 0D 0A 7C     ORA $7C0A
C2/769D: 8D 0A 7C     STA $7C0A
C2/76A0: 8A           TXA 
C2/76A1: 18           CLC 
C2/76A2: 69 04        ADC #$04
C2/76A4: AA           TAX 
C2/76A5: 9E C2 3E     STZ $3EC2,X
C2/76A8: A5 0E        LDA $0E
C2/76AA: AA           TAX 
C2/76AB: 7B           TDC 
C2/76AC: 20 D6 01     JSR $01D6       ; set bit x
C2/76AF: 0D 48 40     ORA $4048
C2/76B2: 8D 48 40     STA $4048
C2/76B5: AD 0A 7C     LDA $7C0A
C2/76B8: 20 D1 01     JSR $01D1       ; clear bit x
C2/76BB: 8D 0A 7C     STA $7C0A
C2/76BE: 8A           TXA 
C2/76BF: 18           CLC 
C2/76C0: 69 04        ADC #$04
C2/76C2: AA           TAX 
C2/76C3: FE C2 3E     INC $3EC2,X
C2/76C6: 80 02        BRA $76CA
C2/76C8: E6 56        INC $56         ; miss
C2/76CA: EE FB 7B     INC $7BFB
C2/76CD: 60           RTS 

; [ attack effect $63: grand cross ]

C2/76CE: A6 49        LDX $49
C2/76D0: BD 1A 20     LDA $201A,X
C2/76D3: 29 C2        AND #$C2
C2/76D5: F0 01        BEQ $76D8
C2/76D7: 60           RTS 
C2/76D8: A9 01        LDA #$01
C2/76DA: 8D D7 3E     STA $3ED7       ; default timer duration
C2/76DD: 7B           TDC 
C2/76DE: AA           TAX 
C2/76DF: A9 11        LDA #$11
C2/76E1: 20 7C 00     JSR $007C       ; a = (x..a)
C2/76E4: D0 04        BNE $76EA
C2/76E6: A9 80        LDA #$80
C2/76E8: 80 28        BRA $7712
C2/76EA: 3A           DEC 
C2/76EB: D0 04        BNE $76F1
C2/76ED: A9 40        LDA #$40
C2/76EF: 80 21        BRA $7712
C2/76F1: 3A           DEC 
C2/76F2: D0 04        BNE $76F8
C2/76F4: A9 20        LDA #$20
C2/76F6: 80 1A        BRA $7712
C2/76F8: 3A           DEC 
C2/76F9: D0 04        BNE $76FF
C2/76FB: A9 10        LDA #$10
C2/76FD: 80 13        BRA $7712
C2/76FF: 3A           DEC 
C2/7700: D0 04        BNE $7706
C2/7702: A9 04        LDA #$04
C2/7704: 80 0C        BRA $7712
C2/7706: 3A           DEC 
C2/7707: D0 04        BNE $770D
C2/7709: A9 02        LDA #$02
C2/770B: 80 05        BRA $7712
C2/770D: 3A           DEC 
C2/770E: D0 09        BNE $7719
C2/7710: A9 01        LDA #$01
C2/7712: 85 59        STA $59
C2/7714: 20 AC 8C     JSR $8CAC
C2/7717: 80 58        BRA $7771
C2/7719: 3A           DEC 
C2/771A: D0 04        BNE $7720
C2/771C: A9 80        LDA #$80
C2/771E: 80 21        BRA $7741
C2/7720: 3A           DEC 
C2/7721: D0 04        BNE $7727
C2/7723: A9 40        LDA #$40
C2/7725: 80 1A        BRA $7741
C2/7727: 3A           DEC 
C2/7728: D0 04        BNE $772E
C2/772A: A9 20        LDA #$20
C2/772C: 80 13        BRA $7741
C2/772E: 3A           DEC 
C2/772F: D0 04        BNE $7735
C2/7731: A9 10        LDA #$10
C2/7733: 80 0C        BRA $7741
C2/7735: 3A           DEC 
C2/7736: D0 04        BNE $773C
C2/7738: A9 08        LDA #$08
C2/773A: 80 05        BRA $7741
C2/773C: 3A           DEC 
C2/773D: D0 09        BNE $7748
C2/773F: A9 04        LDA #$04
C2/7741: 85 59        STA $59
C2/7743: 20 2E 8D     JSR $8D2E
C2/7746: 80 29        BRA $7771
C2/7748: 3A           DEC 
C2/7749: D0 04        BNE $774F
C2/774B: A9 04        LDA #$04
C2/774D: 80 05        BRA $7754
C2/774F: 3A           DEC 
C2/7750: D0 09        BNE $775B
C2/7752: A9 04        LDA #$04
C2/7754: 85 59        STA $59
C2/7756: 20 CB 8D     JSR $8DCB
C2/7759: 80 16        BRA $7771
C2/775B: 3A           DEC 
C2/775C: D0 04        BNE $7762
C2/775E: A9 10        LDA #$10
C2/7760: 80 05        BRA $7767
C2/7762: 3A           DEC 
C2/7763: D0 09        BNE $776E
C2/7765: A9 08        LDA #$08
C2/7767: 85 59        STA $59
C2/7769: 20 05 8E     JSR $8E05
C2/776C: 80 03        BRA $7771
C2/776E: 20 FD 88     JSR $88FD
C2/7771: 64 56        STZ $56
C2/7773: 60           RTS 

; [ attack effect $64: chicken knife ]

C2/7774: 20 53 7C     JSR $7C53       ; calculate hit% (100%, evade / 2)
C2/7777: 20 BE 7E     JSR $7EBE
C2/777A: A5 56        LDA $56
C2/777C: D0 20        BNE $779E
C2/777E: 20 26 86     JSR $8626       ; calculate chicken knife damage
C2/7781: 20 9B 83     JSR $839B
C2/7784: 20 BD 83     JSR $83BD
C2/7787: 20 12 85     JSR $8512
C2/778A: 20 33 85     JSR $8533
C2/778D: 20 84 86     JSR $8684
C2/7790: A5 61        LDA $61
C2/7792: D0 0F        BNE $77A3
C2/7794: A5 56        LDA $56
C2/7796: D0 06        BNE $779E
C2/7798: 20 11 88     JSR $8811
C2/779B: 4C CF 8B     JMP $8BCF
C2/779E: A9 80        LDA #$80
C2/77A0: 85 56        STA $56
C2/77A2: 60           RTS 
C2/77A3: 60           RTS 

; [ attack effect $65: interceptor rocket ]

C2/77A4: A6 49        LDX $49
C2/77A6: BD 1E 20     LDA $201E,X
C2/77A9: 29 10        AND #$10
C2/77AB: F0 06        BEQ $77B3
C2/77AD: A9 50        LDA #$50
C2/77AF: 9D 57 20     STA $2057,X
C2/77B2: 60           RTS 
C2/77B3: E6 56        INC $56         ; miss
C2/77B5: 60           RTS 

; [ attack effect $66: targeting ]

C2/77B6: 38           SEC 
C2/77B7: A5 47        LDA $47
C2/77B9: E9 04        SBC #$04
C2/77BB: 0A           ASL 
C2/77BC: A8           TAY 
C2/77BD: 7B           TDC 
C2/77BE: 99 2A 7C     STA $7C2A,Y
C2/77C1: 99 2B 7C     STA $7C2B,Y
C2/77C4: A5 48        LDA $48
C2/77C6: C9 04        CMP #$04
C2/77C8: B0 09        BCS $77D3
C2/77CA: AA           TAX 
C2/77CB: 7B           TDC 
C2/77CC: 20 D6 01     JSR $01D6       ; set bit x
C2/77CF: 99 2A 7C     STA $7C2A,Y
C2/77D2: 60           RTS 
C2/77D3: 38           SEC 
C2/77D4: E9 04        SBC #$04
C2/77D6: AA           TAX 
C2/77D7: 7B           TDC 
C2/77D8: 20 D6 01     JSR $01D6       ; set bit x
C2/77DB: 99 2B 7C     STA $7C2B,Y
C2/77DE: 60           RTS 
C2/77DF: 60           RTS 

; [ attack effect $68: terminate battle ]

C2/77E0: A9 20        LDA #$20
C2/77E2: 8D DE 7B     STA $7BDE
; fall through

; [ attack effect $67: pull ]

C2/77E5: EE FB 7B     INC $7BFB
C2/77E8: 60           RTS 

; [ attack effect $69: control ]

C2/77E9: 20 65 99     JSR $9965
C2/77EC: 86 14        STX $14
C2/77EE: A6 49        LDX $49
C2/77F0: BD 1B 20     LDA $201B,X
C2/77F3: 29 18        AND #$18
C2/77F5: F0 03        BEQ $77FA
C2/77F7: 4C AE 78     JMP $78AE
C2/77FA: BD 1D 20     LDA $201D,X
C2/77FD: 29 20        AND #$20
C2/77FF: F0 03        BEQ $7804
C2/7801: 4C B2 78     JMP $78B2
C2/7804: BD 66 20     LDA $2066,X
C2/7807: 29 10        AND #$10
C2/7809: F0 03        BEQ $780E
C2/780B: 4C AE 78     JMP $78AE
C2/780E: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7811: 85 0E        STA $0E
C2/7813: A6 32        LDX $32
C2/7815: BD 0E 20     LDA $200E,X
C2/7818: C9 CB        CMP #$CB
C2/781A: D0 08        BNE $7824
C2/781C: A5 0E        LDA $0E
C2/781E: C9 4B        CMP #$4B
C2/7820: 90 0B        BCC $782D
C2/7822: 80 06        BRA $782A
C2/7824: A5 0E        LDA $0E
C2/7826: C9 28        CMP #$28
C2/7828: 90 03        BCC $782D
C2/782A: 4C B9 78     JMP $78B9
C2/782D: A6 49        LDX $49
C2/782F: A9 80        LDA #$80
C2/7831: 9D 56 20     STA $2056,X
C2/7834: 9E 57 20     STZ $2057,X
C2/7837: BD 1D 20     LDA $201D,X
C2/783A: 09 20        ORA #$20
C2/783C: 9D 1D 20     STA $201D,X
C2/783F: A5 47        LDA $47
C2/7841: AA           TAX 
C2/7842: 9E 3E 7C     STZ $7C3E,X
C2/7845: A5 48        LDA $48
C2/7847: 9D 3A 7C     STA $7C3A,X
C2/784A: A5 47        LDA $47
C2/784C: AA           TAX 
C2/784D: BF DB EE D0  LDA $D0EEDB,X
C2/7851: A8           TAY 
C2/7852: 84 10        STY $10
C2/7854: 38           SEC 
C2/7855: A5 48        LDA $48
C2/7857: E9 04        SBC #$04
C2/7859: 0A           ASL 
C2/785A: AA           TAX 
C2/785B: C2 20        REP #$20
C2/785D: BD 20 40     LDA $4020,X
C2/7860: 20 B7 01     JSR $01B7       ; a << 2
C2/7863: AA           TAX 
C2/7864: 7B           TDC 
C2/7865: E2 20        SEP #$20
C2/7867: 64 0E        STZ $0E
C2/7869: BF 00 56 D0  LDA $D05600,X
C2/786D: 99 DC 37     STA $37DC,Y
C2/7870: C9 FF        CMP #$FF
C2/7872: D0 04        BNE $7878
C2/7874: A9 80        LDA #$80
C2/7876: 80 01        BRA $7879
C2/7878: 7B           TDC 
C2/7879: 99 EC 37     STA $37EC,Y
C2/787C: E8           INX 
C2/787D: C8           INY 
C2/787E: E6 0E        INC $0E
C2/7880: A5 0E        LDA $0E
C2/7882: C9 04        CMP #$04
C2/7884: D0 E3        BNE $7869
C2/7886: 64 0E        STZ $0E
C2/7888: A4 10        LDY $10
C2/788A: B9 DC 37     LDA $37DC,Y
C2/788D: C2 20        REP #$20
C2/788F: 20 B6 01     JSR $01B6       ; a << 3
C2/7892: AA           TAX 
C2/7893: 7B           TDC 
C2/7894: E2 20        SEP #$20
C2/7896: BF 80 0B D1  LDA $D10B80,X
C2/789A: 99 E8 37     STA $37E8,Y
C2/789D: C8           INY 
C2/789E: E6 0E        INC $0E
C2/78A0: A5 0E        LDA $0E
C2/78A2: C9 04        CMP #$04
C2/78A4: D0 E4        BNE $788A
C2/78A6: A6 14        LDX $14
C2/78A8: A9 24        LDA #$24        ; "Control"
C2/78AA: 9D 5F 3C     STA $3C5F,X
C2/78AD: 60           RTS 
C2/78AE: A9 4E        LDA #$4E
C2/78B0: 80 02        BRA $78B4
C2/78B2: A9 4C        LDA #$4C        ; "Already being controlled!"
C2/78B4: A6 14        LDX $14
C2/78B6: 9D 5F 3C     STA $3C5F,X
C2/78B9: E6 56        INC $56         ; miss
C2/78BB: 60           RTS 

; [ attack effect $6A: sandworm ]

C2/78BC: 9C C6 3E     STZ $3EC6
C2/78BF: 9C C7 3E     STZ $3EC7
C2/78C2: 9C C8 3E     STZ $3EC8
C2/78C5: 9C C9 3E     STZ $3EC9
C2/78C8: 9C CA 3E     STZ $3ECA
C2/78CB: 9C CB 3E     STZ $3ECB
C2/78CE: 9C CC 3E     STZ $3ECC
C2/78D1: 9C CD 3E     STZ $3ECD
C2/78D4: A9 80        LDA #$80
C2/78D6: 8D DE 7B     STA $7BDE
C2/78D9: EE FB 7B     INC $7BFB
C2/78DC: 60           RTS 

; [ attack effect $6B: change attribute ]

; resist poison, life shield, dragon's kiss, elemental power

C2/78DD: 20 FD 91     JSR $91FD
C2/78E0: A5 58        LDA $58
C2/78E2: 85 59        STA $59
C2/78E4: 20 F2 91     JSR $91F2
C2/78E7: A5 57        LDA $57
C2/78E9: 85 59        STA $59
C2/78EB: 4C E7 91     JMP $91E7

; [ attack effect $6C: bonus vs. creature type ]

C2/78EE: 20 30 7F     JSR $7F30
C2/78F1: 20 DD 84     JSR $84DD
C2/78F4: 20 F3 84     JSR $84F3
C2/78F7: 4C 05 8A     JMP $8A05

; [ attack effect $6D: vampire ]

C2/78FA: 20 F6 7E     JSR $7EF6
C2/78FD: A5 56        LDA $56
C2/78FF: D0 19        BNE $791A
C2/7901: C2 20        REP #$20
C2/7903: A6 32        LDX $32
C2/7905: 38           SEC 
C2/7906: BD 08 20     LDA $2008,X
C2/7909: FD 06 20     SBC $2006,X
C2/790C: 4A           LSR 
C2/790D: 85 50        STA $50
C2/790F: 7B           TDC 
C2/7910: 85 54        STA $54
C2/7912: 1A           INC 
C2/7913: 85 52        STA $52
C2/7915: E2 20        SEP #$20
C2/7917: 20 26 89     JSR $8926
C2/791A: 60           RTS 

; [ attack effect $6E: brave blade ]

C2/791B: 20 47 7C     JSR $7C47
C2/791E: 20 BE 7E     JSR $7EBE
C2/7921: A5 56        LDA $56
C2/7923: D0 23        BNE $7948
C2/7925: 20 77 85     JSR $8577
C2/7928: 20 9B 83     JSR $839B
C2/792B: 20 BD 83     JSR $83BD
C2/792E: 20 30 84     JSR $8430
C2/7931: 20 12 85     JSR $8512
C2/7934: 20 33 85     JSR $8533
C2/7937: 20 84 86     JSR $8684
C2/793A: A5 61        LDA $61
C2/793C: D0 0E        BNE $794C
C2/793E: A5 56        LDA $56
C2/7940: D0 06        BNE $7948
C2/7942: 20 11 88     JSR $8811
C2/7945: 4C CF 8B     JMP $8BCF
C2/7948: A9 80        LDA #$80
C2/794A: 85 56        STA $56
C2/794C: 60           RTS 

; [ attack effect $6F: fight (strong) ]

C2/794D: 20 F1 85     JSR $85F1
C2/7950: 20 12 85     JSR $8512
C2/7953: 4C 05 8A     JMP $8A05

; [ attack effect $70: wormhole ]

C2/7956: A5 48        LDA $48
C2/7958: AA           TAX 
C2/7959: BD C2 3E     LDA $3EC2,X
C2/795C: D0 03        BNE $7961
C2/795E: 4C 05 8E     JMP $8E05
C2/7961: E6 56        INC $56         ; miss
C2/7963: 60           RTS 

; [ attack effect $71:  ]

C2/7964: C2 20        REP #$20
C2/7966: 7B           TDC 
C2/7967: AA           TAX 
C2/7968: A8           TAY 
C2/7969: BF A0 FF D0  LDA $D0FFA0,X   ; compare battle index
C2/796D: CD F0 04     CMP $04F0
C2/7970: F0 10        BEQ $7982
C2/7972: 18           CLC 
C2/7973: 8A           TXA 
C2/7974: 69 10 00     ADC #$0010
C2/7977: AA           TAX 
C2/7978: C8           INY 
C2/7979: C0 04 00     CPY #$0004
C2/797C: D0 EB        BNE $7969
C2/797E: 7B           TDC 
C2/797F: E2 20        SEP #$20
C2/7981: 60           RTS 
C2/7982: 18           CLC 
C2/7983: 8A           TXA 
C2/7984: 69 A0 FF     ADC #$FFA0
C2/7987: 85 0E        STA $0E
C2/7989: 7B           TDC 
C2/798A: E2 20        SEP #$20
C2/798C: A9 D0        LDA #$D0
C2/798E: 85 10        STA $10
C2/7990: AD 72 7C     LDA $7C72
C2/7993: 0A           ASL 
C2/7994: A8           TAY 
C2/7995: B7 0E        LDA [$0E],Y
C2/7997: 85 12        STA $12
C2/7999: C8           INY 
C2/799A: B7 0E        LDA [$0E],Y
C2/799C: 85 13        STA $13
C2/799E: A5 12        LDA $12
C2/79A0: 05 13        ORA $13
C2/79A2: D0 0E        BNE $79B2
C2/79A4: AD 72 7C     LDA $7C72
C2/79A7: 3A           DEC 
C2/79A8: D0 01        BNE $79AB
C2/79AA: 60           RTS 
C2/79AB: A9 01        LDA #$01
C2/79AD: 8D 72 7C     STA $7C72
C2/79B0: 80 DE        BRA $7990
C2/79B2: EE 72 7C     INC $7C72
C2/79B5: A9 D0        LDA #$D0
C2/79B7: 85 10        STA $10
C2/79B9: A0 00 00     LDY #$0000
C2/79BC: 84 0E        STY $0E
C2/79BE: A5 13        LDA $13
C2/79C0: F0 09        BEQ $79CB
C2/79C2: A9 D0        LDA #$D0
C2/79C4: 85 10        STA $10
C2/79C6: A0 00 20     LDY #$2000
C2/79C9: 84 0E        STY $0E
C2/79CB: A5 12        LDA $12
C2/79CD: C2 20        REP #$20
C2/79CF: 20 B4 01     JSR $01B4       ; a << 5
C2/79D2: A8           TAY 
C2/79D3: 7B           TDC 
C2/79D4: AA           TAX 
C2/79D5: E2 20        SEP #$20
C2/79D7: 64 11        STZ $11
C2/79D9: B7 0E        LDA [$0E],Y
C2/79DB: 9D F0 26     STA $26F0,X
C2/79DE: C8           INY 
C2/79DF: E8           INX 
C2/79E0: E6 11        INC $11
C2/79E2: A5 11        LDA $11
C2/79E4: C9 20        CMP #$20
C2/79E6: D0 F1        BNE $79D9
C2/79E8: A5 47        LDA $47
C2/79EA: 20 07 02     JSR $0207       ; get timer data offset
C2/79ED: 7B           TDC 
C2/79EE: 99 F1 3C     STA $3CF1,Y
C2/79F1: 99 F2 3C     STA $3CF2,Y
C2/79F4: 99 F3 3C     STA $3CF3,Y
C2/79F7: 99 F4 3C     STA $3CF4,Y
C2/79FA: 99 F5 3C     STA $3CF5,Y
C2/79FD: 99 F6 3C     STA $3CF6,Y
C2/7A00: 99 F7 3C     STA $3CF7,Y
C2/7A03: 99 F8 3C     STA $3CF8,Y
C2/7A06: 99 F9 3C     STA $3CF9,Y
C2/7A09: 99 FA 3C     STA $3CFA,Y
C2/7A0C: A4 32        LDY $32
C2/7A0E: 7B           TDC 
C2/7A0F: 99 1A 20     STA $201A,Y
C2/7A12: 99 1B 20     STA $201B,Y
C2/7A15: 99 1C 20     STA $201C,Y
C2/7A18: 99 1D 20     STA $201D,Y
C2/7A1B: AA           TAX 
C2/7A1C: BD F0 26     LDA $26F0,X
C2/7A1F: 99 25 20     STA $2025,Y
C2/7A22: 99 29 20     STA $2029,Y
C2/7A25: BD F1 26     LDA $26F1,X
C2/7A28: 99 44 20     STA $2044,Y
C2/7A2B: BD F2 26     LDA $26F2,X
C2/7A2E: 99 62 20     STA $2062,Y
C2/7A31: BD F3 26     LDA $26F3,X
C2/7A34: 99 2C 20     STA $202C,Y
C2/7A37: BD F4 26     LDA $26F4,X
C2/7A3A: 99 2D 20     STA $202D,Y
C2/7A3D: BD F5 26     LDA $26F5,X
C2/7A40: 99 27 20     STA $2027,Y
C2/7A43: 99 2B 20     STA $202B,Y
C2/7A46: BD F6 26     LDA $26F6,X
C2/7A49: 99 2F 20     STA $202F,Y
C2/7A4C: BD F7 26     LDA $26F7,X
C2/7A4F: 99 2E 20     STA $202E,Y
C2/7A52: C2 20        REP #$20
C2/7A54: BD F8 26     LDA $26F8,X
C2/7A57: 99 06 20     STA $2006,Y
C2/7A5A: 99 08 20     STA $2008,Y
C2/7A5D: BD FA 26     LDA $26FA,X
C2/7A60: 99 0A 20     STA $200A,Y
C2/7A63: A9 0F 27     LDA #$270F
C2/7A66: 99 0C 20     STA $200C,Y
C2/7A69: BD FC 26     LDA $26FC,X
C2/7A6C: 99 67 20     STA $2067,Y
C2/7A6F: BD FE 26     LDA $26FE,X
C2/7A72: 99 69 20     STA $2069,Y
C2/7A75: BD 02 27     LDA $2702,X
C2/7A78: 99 35 20     STA $2035,Y
C2/7A7B: 7B           TDC 
C2/7A7C: E2 20        SEP #$20
C2/7A7E: BD 04 27     LDA $2704,X
C2/7A81: 99 37 20     STA $2037,Y
C2/7A84: BD 00 27     LDA $2700,X
C2/7A87: 99 13 20     STA $2013,Y
C2/7A8A: BD 05 27     LDA $2705,X
C2/7A8D: 99 30 20     STA $2030,Y
C2/7A90: BD 01 27     LDA $2701,X
C2/7A93: 99 32 20     STA $2032,Y
C2/7A96: BD 06 27     LDA $2706,X
C2/7A99: 99 64 20     STA $2064,Y
C2/7A9C: BD 07 27     LDA $2707,X
C2/7A9F: 99 34 20     STA $2034,Y
C2/7AA2: BD 08 27     LDA $2708,X
C2/7AA5: 99 65 20     STA $2065,Y
C2/7AA8: BD 09 27     LDA $2709,X
C2/7AAB: 99 66 20     STA $2066,Y
C2/7AAE: BD 0F 27     LDA $270F,X
C2/7AB1: 99 02 20     STA $2002,Y
C2/7AB4: 99 2A 20     STA $202A,Y
C2/7AB7: 5A           PHY 
C2/7AB8: C2 20        REP #$20
C2/7ABA: A5 12        LDA $12
C2/7ABC: 0A           ASL 
C2/7ABD: AA           TAX 
C2/7ABE: 7B           TDC 
C2/7ABF: E2 20        SEP #$20
C2/7AC1: BF 00 99 D0  LDA $D09900,X   ; monster special attack properties
C2/7AC5: 85 1C        STA $1C
C2/7AC7: BF 01 99 D0  LDA $D09901,X
C2/7ACB: 85 1D        STA $1D
C2/7ACD: 7A           PLY 
C2/7ACE: A5 1C        LDA $1C
C2/7AD0: 99 6E 20     STA $206E,Y
C2/7AD3: A5 1D        LDA $1D
C2/7AD5: 99 7F 20     STA $207F,Y
C2/7AD8: 60           RTS 

; [ attack effect $72: bow strong vs. creature type ]

C2/7AD9: 20 53 7C     JSR $7C53       ; calculate hit% (100%, evade / 2)
C2/7ADC: 20 BE 7E     JSR $7EBE
C2/7ADF: A5 56        LDA $56
C2/7AE1: D0 12        BNE $7AF5
C2/7AE3: 20 D4 80     JSR $80D4
C2/7AE6: 20 BD 83     JSR $83BD
C2/7AE9: 20 12 85     JSR $8512
C2/7AEC: 20 33 85     JSR $8533
C2/7AEF: 20 F9 87     JSR $87F9
C2/7AF2: 4C 05 8A     JMP $8A05
C2/7AF5: A9 80        LDA #$80
C2/7AF7: 85 56        STA $56
C2/7AF9: 60           RTS 

; [ attack effect $73: spear strong vs. creature type ]

C2/7AFA: 20 47 7C     JSR $7C47
C2/7AFD: 20 BE 7E     JSR $7EBE
C2/7B00: A5 56        LDA $56
C2/7B02: D0 15        BNE $7B19
C2/7B04: 20 FC 7F     JSR $7FFC
C2/7B07: 20 BD 83     JSR $83BD
C2/7B0A: 20 52 84     JSR $8452
C2/7B0D: 20 12 85     JSR $8512
C2/7B10: 20 33 85     JSR $8533
C2/7B13: 20 F9 87     JSR $87F9
C2/7B16: 4C 05 8A     JMP $8A05
C2/7B19: A9 80        LDA #$80
C2/7B1B: 85 56        STA $56
C2/7B1D: 60           RTS 

; [ attack effect $74:  ]

C2/7B1E: E6 56        INC $56         ; miss
; fallthrough

; [ attack effect $75:  ]

C2/7B20: 60           RTS 

; attack effect jump table
C2/7B21:              .DW $686C, $6870, $6898, $68E2, $68F7, $690C, $6921, $694A ; $00
C2/7B31:              .DW $6971, $6993, $69B5, $69DB, $6A07, $6A3C, $6A65, $6A76
C2/7B41:              .DW $6A81, $6A8E, $6AC4, $6ACF, $6ADD, $6AEB, $6AF6, $6B01 ; $10
C2/7B51:              .DW $6B32, $6B35, $6B52, $6B7D, $6BFC, $6C17, $6CE4, $6CEF
C2/7B61:              .DW $6D2E, $6D4B, $6D5B, $6D83, $6DAB, $6DB4, $6DBD, $6DD7 ; $20
C2/7B71:              .DW $6DED, $6E12, $6E2D, $6E4C, $6E5E, $6E72, $6E9B, $6EB1
C2/7B81:              .DW $6EBC, $6EE1, $6F1E, $6F58, $6F84, $6FA8, $6FC9, $6FF9 ; $30
C2/7B91:              .DW $7020, $703E, $7053, $7074, $709D, $70C4, $70DB, $70EC
C2/7BA1:              .DW $7119, $7134, $7140, $7150, $71B9, $71D7, $71F5, $71FB ; $40
C2/7BB1:              .DW $720D, $7255, $7266, $7266, $728D, $729B, $72B2, $72DB
C2/7BC1:              .DW $7300, $7319, $735E, $7379, $7384, $738F, $7398, $73A3 ; $50
C2/7BD1:              .DW $73C0, $73F0, $7407, $740E, $7419, $7427, $743D, $745C
C2/7BE1:              .DW $7476, $7562, $7662, $76CE, $7774, $77A4, $77B6, $77E5 ; $60
C2/7BF1:              .DW $77E0, $77E9, $78BC, $78DD, $78EE, $78FA, $791B, $794D
C2/7C01:              .DW $7956, $7964, $7AD9, $7AFA, $7B1E, $7B20               ; $70

; [ calculate hit% (magic attack) ]

C2/7C0D: A6 32        LDX $32
C2/7C0F: 18           CLC 
C2/7C10: A5 57        LDA $57         ; hit % parameter
C2/7C12: 6D E5 7B     ADC $7BE5       ; add attacker level
C2/7C15: 85 0E        STA $0E
C2/7C17: A6 49        LDX $49
C2/7C19: 18           CLC 
C2/7C1A: BD 02 20     LDA $2002,X     ; level
C2/7C1D: 7D 78 20     ADC $2078,X     ; level modifier
C2/7C20: 85 0F        STA $0F
C2/7C22: 38           SEC 
C2/7C23: A5 0E        LDA $0E
C2/7C25: E5 0F        SBC $0F         ; hit % + attacker lvl - target lvl
C2/7C27: B0 04        BCS $7C2D
C2/7C29: A9 01        LDA #$01        ; min 1
C2/7C2B: 80 06        BRA $7C33
C2/7C2D: C9 63        CMP #$63        ; max 99
C2/7C2F: 90 02        BCC $7C33
C2/7C31: A9 63        LDA #$63
C2/7C33: 85 4E        STA $4E         ; final hit %
C2/7C35: BD 2E 20     LDA $202E,X     ; magic evade
C2/7C38: 85 4F        STA $4F
C2/7C3A: 60           RTS 

; [ calculate hit% (normal ???) ]

C2/7C3B: A5 57        LDA $57         ; parameter 1 is hit %
C2/7C3D: 85 4E        STA $4E
C2/7C3F: A6 49        LDX $49
C2/7C41: BD 2C 20     LDA $202C,X     ; evade
C2/7C44: 85 4F        STA $4F
C2/7C46: 60           RTS 

; [ calculate hit% (100%) ]

C2/7C47: A9 64        LDA #$64        ; 100% base hit
C2/7C49: 85 4E        STA $4E
C2/7C4B: A6 49        LDX $49
C2/7C4D: BD 2C 20     LDA $202C,X     ; evade
C2/7C50: 85 4F        STA $4F
C2/7C52: 60           RTS 

; [ calculate hit% (100%, evade / 2) ]

C2/7C53: A9 64        LDA #$64        ; 100% base hit
C2/7C55: 85 4E        STA $4E
C2/7C57: A6 49        LDX $49
C2/7C59: BD 2C 20     LDA $202C,X     ; evade / 2
C2/7C5C: 4A           LSR 
C2/7C5D: 85 4F        STA $4F
C2/7C5F: 60           RTS 

; [ calculate hit% (normal) ]

C2/7C60: A5 57        LDA $57         ; parameter 1 is hit %
C2/7C62: 85 4E        STA $4E
C2/7C64: A6 49        LDX $49
C2/7C66: BD 2C 20     LDA $202C,X     ; evade
C2/7C69: 85 4F        STA $4F
C2/7C6B: 60           RTS 

; [ calculate hit% (evade / 2) ]

C2/7C6C: A5 57        LDA $57         ; parameter 1 is hit %
C2/7C6E: 85 4E        STA $4E
C2/7C70: A6 49        LDX $49
C2/7C72: BD 2C 20     LDA $202C,X     ; evade / 2
C2/7C75: 4A           LSR 
C2/7C76: 85 4F        STA $4F
C2/7C78: 60           RTS 

; [ calculate hit% (magic evade) ]

C2/7C79: A5 57        LDA $57         ; parameter 1 is hit %
C2/7C7B: 85 4E        STA $4E
C2/7C7D: A6 49        LDX $49
C2/7C7F: BD 2E 20     LDA $202E,X     ; magic evade
C2/7C82: 85 4F        STA $4F
C2/7C84: 60           RTS 

; [ calculate hit% (steal) ]

C2/7C85: A5 57        LDA $57         ; parameter 1 is hit %
C2/7C87: 85 4E        STA $4E
C2/7C89: 64 4F        STZ $4F
C2/7C8B: A6 32        LDX $32
C2/7C8D: BD 39 20     LDA $2039,X     ; check improved steal
C2/7C90: 29 10        AND #$10
C2/7C92: F0 02        BEQ $7C96
C2/7C94: 06 4E        ASL $4E         ; double hit %
C2/7C96: 60           RTS 

; [  ]

C2/7C97: A6 49        LDX $49         ; target
C2/7C99: BD 1B 20     LDA $201B,X
C2/7C9C: 1D 71 20     ORA $2071,X
C2/7C9F: 29 70        AND #$70
C2/7CA1: D0 1F        BNE $7CC2       ; return if aging, sleep, or paralyze
C2/7CA3: BD 1C 20     LDA $201C,X
C2/7CA6: 29 10        AND #$10
C2/7CA8: D0 18        BNE $7CC2       ; return if stop
C2/7CAA: BD 39 20     LDA $2039,X
C2/7CAD: 10 13        BPL $7CC2       ; return if no aegis shield
C2/7CAF: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7CB2: C9 21        CMP #$21
C2/7CB4: B0 0C        BCS $7CC2       ; 2/3 chance to return
C2/7CB6: A5 47        LDA $47
C2/7CB8: C5 48        CMP $48
C2/7CBA: F0 06        BEQ $7CC2       ; branch if self-target
C2/7CBC: A9 07        LDA #$07
C2/7CBE: 85 5D        STA $5D
C2/7CC0: E6 56        INC $56         ; miss
C2/7CC2: 60           RTS 

; [  ]

C2/7CC3: A5 39        LDA $39
C2/7CC5: AA           TAX 
C2/7CC6: BD FC 79     LDA $79FC,X
C2/7CC9: 29 40        AND #$40
C2/7CCB: D0 2E        BNE $7CFB
C2/7CCD: AD 2C 7B     LDA $7B2C
C2/7CD0: 0A           ASL 
C2/7CD1: AA           TAX 
C2/7CD2: BD FC 7A     LDA $7AFC,X
C2/7CD5: 29 F0        AND #$F0
C2/7CD7: D0 14        BNE $7CED
C2/7CD9: BD FC 7A     LDA $7AFC,X
C2/7CDC: 29 0F        AND #$0F
C2/7CDE: 20 B5 01     JSR $01B5       ; a << 4
C2/7CE1: 85 0E        STA $0E
C2/7CE3: BD FD 7A     LDA $7AFD,X
C2/7CE6: 29 F0        AND #$F0
C2/7CE8: 20 BE 01     JSR $01BE       ; a >> 4
C2/7CEB: 05 0E        ORA $0E
C2/7CED: 20 C3 01     JSR $01C3       ; count set bits
C2/7CF0: CA           DEX 
C2/7CF1: F0 08        BEQ $7CFB
C2/7CF3: 46 4E        LSR $4E
C2/7CF5: A5 4E        LDA $4E
C2/7CF7: D0 02        BNE $7CFB
C2/7CF9: E6 4E        INC $4E
C2/7CFB: 60           RTS 

; [  ]

C2/7CFC: A6 49        LDX $49
C2/7CFE: BD 1B 20     LDA $201B,X
C2/7D01: 1D 71 20     ORA $2071,X
C2/7D04: 29 70        AND #$70
C2/7D06: D0 76        BNE $7D7E
C2/7D08: BD 1C 20     LDA $201C,X
C2/7D0B: 29 10        AND #$10
C2/7D0D: D0 6F        BNE $7D7E
C2/7D0F: BD 20 20     LDA $2020,X
C2/7D12: 29 40        AND #$40
C2/7D14: F0 14        BEQ $7D2A
C2/7D16: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7D19: C9 19        CMP #$19
C2/7D1B: B0 0D        BCS $7D2A
C2/7D1D: A5 47        LDA $47
C2/7D1F: C5 48        CMP $48
C2/7D21: F0 07        BEQ $7D2A
C2/7D23: A9 05        LDA #$05
C2/7D25: 85 5E        STA $5E
C2/7D27: E6 56        INC $56         ; miss
C2/7D29: 60           RTS 
C2/7D2A: A6 49        LDX $49
C2/7D2C: BD 38 20     LDA $2038,X
C2/7D2F: 10 14        BPL $7D45
C2/7D31: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7D34: C9 19        CMP #$19
C2/7D36: B0 0D        BCS $7D45
C2/7D38: A5 47        LDA $47
C2/7D3A: C5 48        CMP $48
C2/7D3C: F0 07        BEQ $7D45
C2/7D3E: A9 01        LDA #$01
C2/7D40: 85 5A        STA $5A
C2/7D42: E6 56        INC $56         ; miss
C2/7D44: 60           RTS 
C2/7D45: A6 49        LDX $49
C2/7D47: BD 38 20     LDA $2038,X
C2/7D4A: 29 40        AND #$40
C2/7D4C: F0 14        BEQ $7D62
C2/7D4E: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7D51: C9 19        CMP #$19
C2/7D53: B0 0D        BCS $7D62
C2/7D55: A5 47        LDA $47
C2/7D57: C5 48        CMP $48
C2/7D59: F0 07        BEQ $7D62
C2/7D5B: A9 02        LDA #$02
C2/7D5D: 85 5B        STA $5B
C2/7D5F: E6 56        INC $56         ; miss
C2/7D61: 60           RTS 
C2/7D62: A6 49        LDX $49
C2/7D64: BD 39 20     LDA $2039,X
C2/7D67: 29 40        AND #$40
C2/7D69: F0 13        BEQ $7D7E
C2/7D6B: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7D6E: C9 21        CMP #$21
C2/7D70: B0 0C        BCS $7D7E
C2/7D72: A5 47        LDA $47
C2/7D74: C5 48        CMP $48
C2/7D76: F0 06        BEQ $7D7E
C2/7D78: A9 03        LDA #$03
C2/7D7A: 85 5C        STA $5C
C2/7D7C: E6 56        INC $56         ; miss
C2/7D7E: 60           RTS 

; [  ]

C2/7D7F: A6 32        LDX $32
C2/7D81: BD 39 20     LDA $2039,X
C2/7D84: 29 04        AND #$04
C2/7D86: F0 02        BEQ $7D8A
C2/7D88: 06 4E        ASL $4E
C2/7D8A: 60           RTS 

; [  ]

C2/7D8B: A6 49        LDX $49         ; pointer to target properties
C2/7D8D: BD 1C 20     LDA $201C,X
C2/7D90: 1D 72 20     ORA $2072,X
C2/7D93: 29 20        AND #$20
C2/7D95: F0 08        BEQ $7D9F
C2/7D97: 46 4E        LSR $4E
C2/7D99: A5 4E        LDA $4E
C2/7D9B: D0 02        BNE $7D9F
C2/7D9D: E6 4E        INC $4E
C2/7D9F: BD 1A 20     LDA $201A,X
C2/7DA2: 1D 70 20     ORA $2070,X
C2/7DA5: 29 20        AND #$20
C2/7DA7: F0 02        BEQ $7DAB
C2/7DA9: 64 4F        STZ $4F
C2/7DAB: 60           RTS 

; [  ]

C2/7DAC: A6 49        LDX $49
C2/7DAE: BD 1A 20     LDA $201A,X
C2/7DB1: 1D 70 20     ORA $2070,X
C2/7DB4: 29 20        AND #$20
C2/7DB6: F0 02        BEQ $7DBA
C2/7DB8: 64 4F        STZ $4F
C2/7DBA: BD 1A 20     LDA $201A,X
C2/7DBD: 1D 70 20     ORA $2070,X
C2/7DC0: 29 10        AND #$10
C2/7DC2: F0 0C        BEQ $7DD0
C2/7DC4: 06 4F        ASL $4F
C2/7DC6: A5 4F        LDA $4F
C2/7DC8: C9 63        CMP #$63
C2/7DCA: 90 04        BCC $7DD0
C2/7DCC: A9 63        LDA #$63
C2/7DCE: 85 4F        STA $4F
C2/7DD0: 60           RTS 

; [  ]

C2/7DD1: A6 32        LDX $32
C2/7DD3: BD 1A 20     LDA $201A,X
C2/7DD6: 1D 70 20     ORA $2070,X
C2/7DD9: 29 01        AND #$01
C2/7DDB: F0 04        BEQ $7DE1
C2/7DDD: 46 4E        LSR $4E
C2/7DDF: 46 4E        LSR $4E
C2/7DE1: 60           RTS 

; [ check image hit ]

C2/7DE2: A6 49        LDX $49
C2/7DE4: BD 1B 20     LDA $201B,X
C2/7DE7: 29 03        AND #$03
C2/7DE9: F0 05        BEQ $7DF0       ; branch if not image
C2/7DEB: 20 8F 93     JSR $938F       ; decrement image status
C2/7DEE: E6 56        INC $56         ; miss
C2/7DF0: 60           RTS 

; [  ]

C2/7DF1: AD E6 7B     LDA $7BE6
C2/7DF4: 29 40        AND #$40
C2/7DF6: F0 0A        BEQ $7E02       ; branch if void not in effect
C2/7DF8: E6 56        INC $56         ; miss
C2/7DFA: 20 65 99     JSR $9965
C2/7DFD: A9 1F        LDA #$1F        ; "No voice!"
C2/7DFF: 9D 5F 3C     STA $3C5F,X
C2/7E02: 60           RTS 

; [  ]

C2/7E03: A6 49        LDX $49
C2/7E05: BD 1A 20     LDA $201A,X
C2/7E08: 1D 70 20     ORA $2070,X
C2/7E0B: 29 08        AND #$08
C2/7E0D: F0 02        BEQ $7E11
C2/7E0F: E6 56        INC $56         ; miss
C2/7E11: 60           RTS 

; [ check hit/evade ]

C2/7E12: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7E15: C5 4E        CMP $4E
C2/7E17: B0 07        BCS $7E20       ; branch if attack missed
C2/7E19: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7E1C: C5 4F        CMP $4F
C2/7E1E: B0 02        BCS $7E22       ; branch if target evaded
C2/7E20: E6 56        INC $56         ; miss
C2/7E22: 60           RTS 

; [  ]

C2/7E23: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7E26: C5 4E        CMP $4E
C2/7E28: B0 2E        BCS $7E58
C2/7E2A: A6 49        LDX $49
C2/7E2C: BD 1B 20     LDA $201B,X
C2/7E2F: 1D 71 20     ORA $2071,X
C2/7E32: 29 70        AND #$70
C2/7E34: D0 24        BNE $7E5A
C2/7E36: BD 1C 20     LDA $201C,X
C2/7E39: 29 10        AND #$10
C2/7E3B: D0 1D        BNE $7E5A
C2/7E3D: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/7E40: C5 4F        CMP $4F
C2/7E42: B0 16        BCS $7E5A
C2/7E44: A6 49        LDX $49
C2/7E46: BD 11 20     LDA $2011,X
C2/7E49: 1D 12 20     ORA $2012,X
C2/7E4C: F0 0A        BEQ $7E58
C2/7E4E: A5 47        LDA $47
C2/7E50: C5 48        CMP $48
C2/7E52: F0 06        BEQ $7E5A
C2/7E54: A9 06        LDA #$06
C2/7E56: 85 5D        STA $5D
C2/7E58: E6 56        INC $56         ; miss
C2/7E5A: 60           RTS 

; [  ]

C2/7E5B: A6 49        LDX $49
C2/7E5D: BD 65 20     LDA $2065,X
C2/7E60: 25 57        AND $57
C2/7E62: D0 02        BNE $7E66
C2/7E64: E6 56        INC $56         ; miss
C2/7E66: 60           RTS 

; [  ]

C2/7E67: A6 49        LDX $49
C2/7E69: BD 02 20     LDA $2002,X
C2/7E6C: AA           TAX 
C2/7E6D: 8E B7 7C     STX $7CB7
C2/7E70: A5 57        LDA $57
C2/7E72: AA           TAX 
C2/7E73: 8E B9 7C     STX $7CB9
C2/7E76: 20 0C 01     JSR $010C       ; +$7CBB = +$7CB7 / +$7CB9, R -> +$7CBD
C2/7E79: AE BD 7C     LDX $7CBD
C2/7E7C: F0 02        BEQ $7E80
C2/7E7E: E6 56        INC $56         ; miss
C2/7E80: 60           RTS 

; [  ]

C2/7E81: A5 57        LDA $57
C2/7E83: 30 38        BMI $7EBD
C2/7E85: A5 58        LDA $58
C2/7E87: 29 80        AND #$80
C2/7E89: F0 12        BEQ $7E9D
C2/7E8B: A5 47        LDA $47
C2/7E8D: C9 04        CMP #$04
C2/7E8F: B0 06        BCS $7E97
C2/7E91: A5 48        LDA $48
C2/7E93: C9 04        CMP #$04
C2/7E95: 90 26        BCC $7EBD
C2/7E97: A5 48        LDA $48
C2/7E99: C9 04        CMP #$04
C2/7E9B: B0 20        BCS $7EBD
C2/7E9D: A5 39        LDA $39
C2/7E9F: AA           TAX 
C2/7EA0: BD FD 79     LDA $79FD,X
C2/7EA3: A6 49        LDX $49
C2/7EA5: 3D 64 20     AND $2064,X
C2/7EA8: D0 13        BNE $7EBD
C2/7EAA: 20 0D 7C     JSR $7C0D       ; calculate hit% (magic attack)
C2/7EAD: 20 97 7C     JSR $7C97
C2/7EB0: A5 56        LDA $56
C2/7EB2: D0 09        BNE $7EBD
C2/7EB4: 20 C3 7C     JSR $7CC3
C2/7EB7: 20 8B 7D     JSR $7D8B
C2/7EBA: 20 12 7E     JSR $7E12       ; check hit/evade
C2/7EBD: 60           RTS 

; [ check automatic hit/miss (physical) ]

C2/7EBE: A6 49        LDX $49         ; target
C2/7EC0: BD 1B 20     LDA $201B,X
C2/7EC3: 1D 71 20     ORA $2071,X
C2/7EC6: 29 70        AND #$70
C2/7EC8: D0 28        BNE $7EF2       ; branch if sleep, paralyze, or charm
C2/7ECA: A6 32        LDX $32
C2/7ECC: BD 1F 20     LDA $201F,X
C2/7ECF: 30 21        BMI $7EF2       ; branch if automatically hits
C2/7ED1: A5 39        LDA $39
C2/7ED3: AA           TAX 
C2/7ED4: BD FD 79     LDA $79FD,X
C2/7ED7: A6 49        LDX $49
C2/7ED9: 3D 64 20     AND $2064,X
C2/7EDC: D0 14        BNE $7EF2       ; branch if automatically hit by action type ???
C2/7EDE: 20 FC 7C     JSR $7CFC       ; 
C2/7EE1: A5 56        LDA $56
C2/7EE3: D0 10        BNE $7EF5       ; branch if attack missed
C2/7EE5: 20 AC 7D     JSR $7DAC       ; 
C2/7EE8: 20 D1 7D     JSR $7DD1       ; 
C2/7EEB: 20 23 7E     JSR $7E23       ; 
C2/7EEE: A5 56        LDA $56
C2/7EF0: D0 03        BNE $7EF5       ; branch if attack missed
C2/7EF2: 20 E2 7D     JSR $7DE2       ; check image hit
C2/7EF5: 60           RTS 

; [  ]

C2/7EF6: A5 57        LDA $57
C2/7EF8: 30 20        BMI $7F1A
C2/7EFA: A5 39        LDA $39
C2/7EFC: AA           TAX 
C2/7EFD: BD FD 79     LDA $79FD,X
C2/7F00: A6 49        LDX $49
C2/7F02: 3D 64 20     AND $2064,X
C2/7F05: D0 13        BNE $7F1A
C2/7F07: 20 0D 7C     JSR $7C0D       ; calculate hit% (magic attack)
C2/7F0A: 20 97 7C     JSR $7C97
C2/7F0D: A5 56        LDA $56
C2/7F0F: D0 09        BNE $7F1A
C2/7F11: 20 C3 7C     JSR $7CC3
C2/7F14: 20 8B 7D     JSR $7D8B
C2/7F17: 20 12 7E     JSR $7E12       ; check hit/evade
C2/7F1A: 60           RTS 

; [  ]

C2/7F1B: A5 57        LDA $57
C2/7F1D: 30 10        BMI $7F2F
C2/7F1F: 20 3B 7C     JSR $7C3B       ; calculate hit % (normal ???)
C2/7F22: 20 FC 7C     JSR $7CFC
C2/7F25: A5 56        LDA $56
C2/7F27: D0 06        BNE $7F2F
C2/7F29: 20 AC 7D     JSR $7DAC
C2/7F2C: 20 23 7E     JSR $7E23
C2/7F2F: 60           RTS 

; [  ]

C2/7F30: 7B           TDC 
C2/7F31: AA           TAX 
C2/7F32: A5 58        LDA $58
C2/7F34: 20 BF 01     JSR $01BF       ; a >> 3
C2/7F37: 20 7C 00     JSR $007C       ; a = (x..a)
C2/7F3A: 18           CLC 
C2/7F3B: 65 58        ADC $58
C2/7F3D: 85 50        STA $50
C2/7F3F: 7B           TDC 
C2/7F40: 69 00        ADC #$00
C2/7F42: 85 51        STA $51
C2/7F44: AD E5 7B     LDA $7BE5
C2/7F47: 85 24        STA $24
C2/7F49: AD E4 7B     LDA $7BE4
C2/7F4C: 85 25        STA $25
C2/7F4E: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/7F51: C2 20        REP #$20
C2/7F53: A5 26        LDA $26
C2/7F55: 20 BA 01     JSR $01BA       ; a >> 8
C2/7F58: 18           CLC 
C2/7F59: 69 04 00     ADC #$0004
C2/7F5C: 85 52        STA $52
C2/7F5E: 7B           TDC 
C2/7F5F: E2 20        SEP #$20
C2/7F61: A6 49        LDX $49
C2/7F63: BD 2F 20     LDA $202F,X
C2/7F66: AA           TAX 
C2/7F67: 86 54        STX $54
C2/7F69: 60           RTS 

; [  ]

C2/7F6A: 7B           TDC 
C2/7F6B: AA           TAX 
C2/7F6C: A5 58        LDA $58
C2/7F6E: 20 BD 01     JSR $01BD       ; a >> 5
C2/7F71: 20 7C 00     JSR $007C       ; a = (x..a)
C2/7F74: 18           CLC 
C2/7F75: 65 58        ADC $58
C2/7F77: 85 50        STA $50
C2/7F79: 7B           TDC 
C2/7F7A: 69 00        ADC #$00
C2/7F7C: 85 51        STA $51
C2/7F7E: AD E5 7B     LDA $7BE5
C2/7F81: 85 24        STA $24
C2/7F83: AD E4 7B     LDA $7BE4
C2/7F86: 85 25        STA $25
C2/7F88: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/7F8B: C2 20        REP #$20
C2/7F8D: A5 26        LDA $26
C2/7F8F: 20 BA 01     JSR $01BA       ; a >> 8
C2/7F92: 18           CLC 
C2/7F93: 69 04 00     ADC #$0004
C2/7F96: 85 52        STA $52
C2/7F98: 7B           TDC 
C2/7F99: E2 20        SEP #$20
C2/7F9B: A6 49        LDX $49
C2/7F9D: BD 2F 20     LDA $202F,X
C2/7FA0: 20 BD 01     JSR $01BD       ; a >> 5
C2/7FA3: AA           TAX 
C2/7FA4: 86 54        STX $54
C2/7FA6: 60           RTS 

; [  ]

C2/7FA7: 7B           TDC 
C2/7FA8: AA           TAX 
C2/7FA9: A9 96        LDA #$96
C2/7FAB: 20 7C 00     JSR $007C       ; a = (x..a)
C2/7FAE: 18           CLC 
C2/7FAF: 69 32        ADC #$32
C2/7FB1: AA           TAX 
C2/7FB2: 86 50        STX $50
C2/7FB4: A5 58        LDA $58
C2/7FB6: AA           TAX 
C2/7FB7: 86 52        STX $52
C2/7FB9: A6 49        LDX $49
C2/7FBB: BD 2F 20     LDA $202F,X
C2/7FBE: AA           TAX 
C2/7FBF: 86 54        STX $54
C2/7FC1: 60           RTS 

; [  ]

C2/7FC2: 7B           TDC 
C2/7FC3: AA           TAX 
C2/7FC4: A5 58        LDA $58
C2/7FC6: 20 BF 01     JSR $01BF       ; a >> 3
C2/7FC9: 20 7C 00     JSR $007C       ; a = (x..a)
C2/7FCC: 18           CLC 
C2/7FCD: 65 58        ADC $58
C2/7FCF: 85 50        STA $50
C2/7FD1: 7B           TDC 
C2/7FD2: 69 00        ADC #$00
C2/7FD4: 85 51        STA $51
C2/7FD6: AD E5 7B     LDA $7BE5
C2/7FD9: 85 24        STA $24
C2/7FDB: AD E4 7B     LDA $7BE4
C2/7FDE: 85 25        STA $25
C2/7FE0: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/7FE3: C2 20        REP #$20
C2/7FE5: A5 26        LDA $26
C2/7FE7: 20 BA 01     JSR $01BA       ; a >> 8
C2/7FEA: 18           CLC 
C2/7FEB: 69 04 00     ADC #$0004
C2/7FEE: 85 52        STA $52
C2/7FF0: 7B           TDC 
C2/7FF1: E2 20        SEP #$20
C2/7FF3: A6 49        LDX $49
C2/7FF5: BD 2D 20     LDA $202D,X
C2/7FF8: AA           TAX 
C2/7FF9: 86 54        STX $54
C2/7FFB: 60           RTS 

; [  ]

C2/7FFC: A5 39        LDA $39
C2/7FFE: AA           TAX 
C2/7FFF: BD 03 7A     LDA $7A03,X
C2/8002: AA           TAX 
C2/8003: 86 0E        STX $0E
C2/8005: 20 BF 01     JSR $01BF       ; a >> 3
C2/8008: A2 00 00     LDX #$0000
C2/800B: 20 7C 00     JSR $007C       ; a = (x..a)
C2/800E: C2 20        REP #$20
C2/8010: 18           CLC 
C2/8011: 65 0E        ADC $0E
C2/8013: 85 50        STA $50
C2/8015: 7B           TDC 
C2/8016: E2 20        SEP #$20
C2/8018: AD E5 7B     LDA $7BE5
C2/801B: 85 24        STA $24
C2/801D: AD E1 7B     LDA $7BE1
C2/8020: 85 25        STA $25
C2/8022: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8025: C2 20        REP #$20
C2/8027: A5 26        LDA $26
C2/8029: 20 BB 01     JSR $01BB       ; a >> 7
C2/802C: 18           CLC 
C2/802D: 69 02 00     ADC #$0002
C2/8030: 85 52        STA $52
C2/8032: 7B           TDC 
C2/8033: E2 20        SEP #$20
C2/8035: A6 49        LDX $49
C2/8037: BD 2D 20     LDA $202D,X
C2/803A: AA           TAX 
C2/803B: 86 54        STX $54
C2/803D: 60           RTS 

; [  ]

C2/803E: A5 39        LDA $39
C2/8040: AA           TAX 
C2/8041: BD 03 7A     LDA $7A03,X
C2/8044: AA           TAX 
C2/8045: 86 0E        STX $0E
C2/8047: 7B           TDC 
C2/8048: AA           TAX 
C2/8049: AD E5 7B     LDA $7BE5
C2/804C: 20 C0 01     JSR $01C0       ; a >> 2
C2/804F: 20 7C 00     JSR $007C       ; a = (x..a)
C2/8052: AA           TAX 
C2/8053: 86 10        STX $10
C2/8055: AD E5 7B     LDA $7BE5
C2/8058: 85 24        STA $24
C2/805A: AD E1 7B     LDA $7BE1
C2/805D: 85 25        STA $25
C2/805F: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8062: A6 26        LDX $26
C2/8064: 86 14        STX $14
C2/8066: A6 32        LDX $32
C2/8068: BD 21 20     LDA $2021,X
C2/806B: 29 40        AND #$40
C2/806D: F0 4B        BEQ $80BA
C2/806F: AD E5 7B     LDA $7BE5
C2/8072: AA           TAX 
C2/8073: 86 12        STX $12
C2/8075: 06 12        ASL $12
C2/8077: 26 13        ROL $13
C2/8079: 18           CLC 
C2/807A: A5 10        LDA $10
C2/807C: 65 12        ADC $12
C2/807E: 85 10        STA $10
C2/8080: A5 11        LDA $11
C2/8082: 65 13        ADC $13
C2/8084: 85 11        STA $11
C2/8086: C2 20        REP #$20
C2/8088: 18           CLC 
C2/8089: A5 0E        LDA $0E
C2/808B: 65 10        ADC $10
C2/808D: 85 50        STA $50
C2/808F: 7B           TDC 
C2/8090: E2 20        SEP #$20
C2/8092: C2 20        REP #$20
C2/8094: A5 14        LDA $14
C2/8096: 20 BA 01     JSR $01BA       ; a >> 8
C2/8099: 18           CLC 
C2/809A: 69 02 00     ADC #$0002
C2/809D: 85 52        STA $52
C2/809F: 7B           TDC 
C2/80A0: E2 20        SEP #$20
C2/80A2: A6 32        LDX $32
C2/80A4: BD 39 20     LDA $2039,X
C2/80A7: 29 20        AND #$20
C2/80A9: F0 20        BEQ $80CB
C2/80AB: C2 20        REP #$20
C2/80AD: 18           CLC 
C2/80AE: A5 50        LDA $50
C2/80B0: 69 32 00     ADC #$0032
C2/80B3: 85 50        STA $50
C2/80B5: 7B           TDC 
C2/80B6: E2 20        SEP #$20
C2/80B8: 80 11        BRA $80CB
C2/80BA: C2 20        REP #$20
C2/80BC: 18           CLC 
C2/80BD: A5 0E        LDA $0E
C2/80BF: 65 10        ADC $10
C2/80C1: 85 50        STA $50
C2/80C3: 7B           TDC 
C2/80C4: E2 20        SEP #$20
C2/80C6: A2 02 00     LDX #$0002
C2/80C9: 86 52        STX $52
C2/80CB: A6 49        LDX $49
C2/80CD: BD 2D 20     LDA $202D,X
C2/80D0: AA           TAX 
C2/80D1: 86 54        STX $54
C2/80D3: 60           RTS 

; [  ]

C2/80D4: A5 39        LDA $39
C2/80D6: AA           TAX 
C2/80D7: BD 03 7A     LDA $7A03,X
C2/80DA: 85 50        STA $50
C2/80DC: 7B           TDC 
C2/80DD: AA           TAX 
C2/80DE: A9 03        LDA #$03
C2/80E0: 20 7C 00     JSR $007C       ; a = (x..a)
C2/80E3: 18           CLC 
C2/80E4: 65 50        ADC $50
C2/80E6: AA           TAX 
C2/80E7: 86 50        STX $50
C2/80E9: AD E1 7B     LDA $7BE1
C2/80EC: 85 24        STA $24
C2/80EE: AD E5 7B     LDA $7BE5
C2/80F1: 85 25        STA $25
C2/80F3: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/80F6: C2 20        REP #$20
C2/80F8: A5 26        LDA $26
C2/80FA: 20 BB 01     JSR $01BB       ; a >> 7
C2/80FD: 18           CLC 
C2/80FE: 69 02 00     ADC #$0002
C2/8101: 85 0E        STA $0E
C2/8103: 7B           TDC 
C2/8104: E2 20        SEP #$20
C2/8106: AD E2 7B     LDA $7BE2
C2/8109: 85 24        STA $24
C2/810B: AD E5 7B     LDA $7BE5
C2/810E: 85 25        STA $25
C2/8110: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8113: A5 26        LDA $26
C2/8115: C2 20        REP #$20
C2/8117: 20 BB 01     JSR $01BB       ; a >> 7
C2/811A: 18           CLC 
C2/811B: 65 0E        ADC $0E
C2/811D: 85 52        STA $52
C2/811F: 7B           TDC 
C2/8120: E2 20        SEP #$20
C2/8122: A6 49        LDX $49
C2/8124: BD 2D 20     LDA $202D,X
C2/8127: AA           TAX 
C2/8128: 86 54        STX $54
C2/812A: 60           RTS 

; [  ]

C2/812B: A5 39        LDA $39
C2/812D: AA           TAX 
C2/812E: BD 03 7A     LDA $7A03,X
C2/8131: AA           TAX 
C2/8132: 86 0E        STX $0E
C2/8134: 46 0E        LSR $0E
C2/8136: A2 00 00     LDX #$0000
C2/8139: 20 7C 00     JSR $007C       ; a = (x..a)
C2/813C: C2 20        REP #$20
C2/813E: 18           CLC 
C2/813F: 65 0E        ADC $0E
C2/8141: 85 50        STA $50
C2/8143: 7B           TDC 
C2/8144: E2 20        SEP #$20
C2/8146: AD E1 7B     LDA $7BE1
C2/8149: 85 24        STA $24
C2/814B: AD E5 7B     LDA $7BE5
C2/814E: 85 25        STA $25
C2/8150: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8153: C2 20        REP #$20
C2/8155: A5 26        LDA $26
C2/8157: 20 BB 01     JSR $01BB       ; a >> 7
C2/815A: 18           CLC 
C2/815B: 69 02 00     ADC #$0002
C2/815E: 85 52        STA $52
C2/8160: 7B           TDC 
C2/8161: E2 20        SEP #$20
C2/8163: A6 49        LDX $49
C2/8165: BD 2D 20     LDA $202D,X
C2/8168: 20 C0 01     JSR $01C0       ; a >> 2
C2/816B: AA           TAX 
C2/816C: 86 54        STX $54
C2/816E: 60           RTS 

; [  ]

C2/816F: A5 39        LDA $39
C2/8171: AA           TAX 
C2/8172: BD 03 7A     LDA $7A03,X
C2/8175: 4A           LSR 
C2/8176: AA           TAX 
C2/8177: 86 0E        STX $0E
C2/8179: A2 00 00     LDX #$0000
C2/817C: 20 7C 00     JSR $007C       ; a = (x..a)
C2/817F: C2 20        REP #$20
C2/8181: 18           CLC 
C2/8182: 65 0E        ADC $0E
C2/8184: 85 50        STA $50
C2/8186: 7B           TDC 
C2/8187: E2 20        SEP #$20
C2/8189: AD E2 7B     LDA $7BE2
C2/818C: 85 24        STA $24
C2/818E: AD E5 7B     LDA $7BE5
C2/8191: 85 25        STA $25
C2/8193: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8196: C2 20        REP #$20
C2/8198: A5 26        LDA $26
C2/819A: 20 BB 01     JSR $01BB       ; a >> 7
C2/819D: 18           CLC 
C2/819E: 69 02 00     ADC #$0002
C2/81A1: 85 0E        STA $0E
C2/81A3: 7B           TDC 
C2/81A4: E2 20        SEP #$20
C2/81A6: AD E4 7B     LDA $7BE4
C2/81A9: 85 24        STA $24
C2/81AB: AD E5 7B     LDA $7BE5
C2/81AE: 85 25        STA $25
C2/81B0: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/81B3: C2 20        REP #$20
C2/81B5: A5 26        LDA $26
C2/81B7: 20 BB 01     JSR $01BB       ; a >> 7
C2/81BA: 18           CLC 
C2/81BB: 65 0E        ADC $0E
C2/81BD: 85 52        STA $52
C2/81BF: 7B           TDC 
C2/81C0: E2 20        SEP #$20
C2/81C2: A6 49        LDX $49
C2/81C4: BD 2F 20     LDA $202F,X
C2/81C7: AA           TAX 
C2/81C8: 86 54        STX $54
C2/81CA: 60           RTS 

; [  ]

C2/81CB: A5 39        LDA $39
C2/81CD: AA           TAX 
C2/81CE: BD 03 7A     LDA $7A03,X
C2/81D1: A2 00 00     LDX #$0000
C2/81D4: 20 7C 00     JSR $007C       ; a = (x..a)
C2/81D7: C2 20        REP #$20
C2/81D9: 0A           ASL 
C2/81DA: 85 50        STA $50
C2/81DC: 7B           TDC 
C2/81DD: E2 20        SEP #$20
C2/81DF: AD E4 7B     LDA $7BE4
C2/81E2: 85 24        STA $24
C2/81E4: AD E5 7B     LDA $7BE5
C2/81E7: 85 25        STA $25
C2/81E9: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/81EC: C2 20        REP #$20
C2/81EE: A5 26        LDA $26
C2/81F0: 20 BA 01     JSR $01BA       ; a >> 8
C2/81F3: 18           CLC 
C2/81F4: 69 02 00     ADC #$0002
C2/81F7: 85 52        STA $52
C2/81F9: 7B           TDC 
C2/81FA: E2 20        SEP #$20
C2/81FC: A6 49        LDX $49
C2/81FE: BD 2F 20     LDA $202F,X
C2/8201: AA           TAX 
C2/8202: 86 54        STX $54
C2/8204: 60           RTS 

; [  ]

C2/8205: 7B           TDC 
C2/8206: AA           TAX 
C2/8207: A9 5A        LDA #$5A
C2/8209: 20 7C 00     JSR $007C       ; a = (x..a)
C2/820C: 18           CLC 
C2/820D: 69 0A        ADC #$0A
C2/820F: AA           TAX 
C2/8210: 86 50        STX $50
C2/8212: AD E5 7B     LDA $7BE5
C2/8215: 20 BF 01     JSR $01BF       ; a >> 3
C2/8218: 18           CLC 
C2/8219: 69 02        ADC #$02
C2/821B: AA           TAX 
C2/821C: 86 52        STX $52
C2/821E: A6 49        LDX $49
C2/8220: BD 2F 20     LDA $202F,X
C2/8223: AA           TAX 
C2/8224: 86 54        STX $54
C2/8226: 60           RTS 

; [  ]

C2/8227: A6 32        LDX $32
C2/8229: BD 44 20     LDA $2044,X
C2/822C: 85 0E        STA $0E
C2/822E: 20 BF 01     JSR $01BF       ; a >> 3
C2/8231: A2 00 00     LDX #$0000
C2/8234: 20 7C 00     JSR $007C       ; a = (x..a)
C2/8237: 18           CLC 
C2/8238: 65 0E        ADC $0E
C2/823A: 85 50        STA $50
C2/823C: 7B           TDC 
C2/823D: 69 00        ADC #$00
C2/823F: 85 51        STA $51
C2/8241: A6 32        LDX $32
C2/8243: BD 62 20     LDA $2062,X
C2/8246: A8           TAY 
C2/8247: 84 52        STY $52
C2/8249: A6 49        LDX $49
C2/824B: BD 2D 20     LDA $202D,X
C2/824E: AA           TAX 
C2/824F: 86 54        STX $54
C2/8251: 60           RTS 

; [  ]

C2/8252: A5 57        LDA $57
C2/8254: AA           TAX 
C2/8255: 86 50        STX $50
C2/8257: A5 58        LDA $58
C2/8259: AA           TAX 
C2/825A: 86 52        STX $52
C2/825C: 7B           TDC 
C2/825D: AA           TAX 
C2/825E: 86 54        STX $54
C2/8260: 60           RTS 

; [  ]

C2/8261: 7B           TDC 
C2/8262: AA           TAX 
C2/8263: A5 58        LDA $58
C2/8265: 20 7C 00     JSR $007C       ; a = (x..a)
C2/8268: 85 50        STA $50
C2/826A: 18           CLC 
C2/826B: A5 50        LDA $50
C2/826D: 65 58        ADC $58
C2/826F: 85 50        STA $50
C2/8271: 7B           TDC 
C2/8272: 69 00        ADC #$00
C2/8274: 85 51        STA $51
C2/8276: AD E5 7B     LDA $7BE5
C2/8279: 85 24        STA $24
C2/827B: AD E1 7B     LDA $7BE1
C2/827E: 85 25        STA $25
C2/8280: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8283: C2 20        REP #$20
C2/8285: A5 26        LDA $26
C2/8287: 20 BB 01     JSR $01BB       ; a >> 7
C2/828A: 1A           INC 
C2/828B: 85 52        STA $52
C2/828D: 7B           TDC 
C2/828E: E2 20        SEP #$20
C2/8290: A6 49        LDX $49
C2/8292: BD 2D 20     LDA $202D,X
C2/8295: AA           TAX 
C2/8296: 86 54        STX $54
C2/8298: 60           RTS 

; [  ]

C2/8299: A6 32        LDX $32
C2/829B: BD 5A 20     LDA $205A,X
C2/829E: 8D 63 7C     STA $7C63
C2/82A1: C2 20        REP #$20
C2/82A3: 20 B7 01     JSR $01B7       ; a << 2
C2/82A6: 85 0E        STA $0E
C2/82A8: 0A           ASL 
C2/82A9: 18           CLC 
C2/82AA: 65 0E        ADC $0E
C2/82AC: AA           TAX 
C2/82AD: 7B           TDC 
C2/82AE: E2 20        SEP #$20
C2/82B0: BF 07 00 D1  LDA $D10007,X   ; item attack power
C2/82B4: 85 0E        STA $0E
C2/82B6: 20 BF 01     JSR $01BF       ; a >> 3
C2/82B9: A2 00 00     LDX #$0000
C2/82BC: 20 7C 00     JSR $007C       ; a = (x..a)
C2/82BF: 18           CLC 
C2/82C0: 65 0E        ADC $0E
C2/82C2: 85 50        STA $50
C2/82C4: 7B           TDC 
C2/82C5: 69 00        ADC #$00
C2/82C7: 85 51        STA $51
C2/82C9: AD E1 7B     LDA $7BE1
C2/82CC: 85 24        STA $24
C2/82CE: AD E5 7B     LDA $7BE5
C2/82D1: 85 25        STA $25
C2/82D3: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/82D6: C2 20        REP #$20
C2/82D8: A5 26        LDA $26
C2/82DA: 20 BB 01     JSR $01BB       ; a >> 7
C2/82DD: 85 0E        STA $0E
C2/82DF: 7B           TDC 
C2/82E0: E2 20        SEP #$20
C2/82E2: AD E2 7B     LDA $7BE2
C2/82E5: 85 24        STA $24
C2/82E7: AD E5 7B     LDA $7BE5
C2/82EA: 85 25        STA $25
C2/82EC: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/82EF: C2 20        REP #$20
C2/82F1: A5 26        LDA $26
C2/82F3: 20 BB 01     JSR $01BB       ; a >> 7
C2/82F6: 18           CLC 
C2/82F7: 65 0E        ADC $0E
C2/82F9: 69 02 00     ADC #$0002
C2/82FC: 85 52        STA $52
C2/82FE: 7B           TDC 
C2/82FF: E2 20        SEP #$20
C2/8301: A6 49        LDX $49
C2/8303: BD 2D 20     LDA $202D,X
C2/8306: AA           TAX 
C2/8307: 86 54        STX $54
C2/8309: 60           RTS 

; [  ]

C2/830A: 18           CLC 
C2/830B: AD E5 7B     LDA $7BE5
C2/830E: 69 0A        ADC #$0A
C2/8310: AA           TAX 
C2/8311: 86 50        STX $50
C2/8313: A5 57        LDA $57
C2/8315: 85 24        STA $24
C2/8317: AD E5 7B     LDA $7BE5
C2/831A: 85 25        STA $25
C2/831C: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/831F: AF 49 09 00  LDA $000949
C2/8323: D0 14        BNE $8339
C2/8325: C2 20        REP #$20
C2/8327: AF 47 09 00  LDA $000947
C2/832B: C5 26        CMP $26
C2/832D: B0 07        BCS $8336
C2/832F: 7B           TDC 
C2/8330: 85 50        STA $50
C2/8332: E2 20        SEP #$20
C2/8334: 80 22        BRA $8358
C2/8336: 7B           TDC 
C2/8337: E2 20        SEP #$20
C2/8339: 38           SEC 
C2/833A: AF 47 09 00  LDA $000947
C2/833E: E5 26        SBC $26
C2/8340: 8F 47 09 00  STA $000947
C2/8344: AF 48 09 00  LDA $000948
C2/8348: E5 27        SBC $27
C2/834A: 8F 48 09 00  STA $000948
C2/834E: AF 49 09 00  LDA $000949
C2/8352: E9 00        SBC #$00
C2/8354: 8F 49 09 00  STA $000949
C2/8358: A5 58        LDA $58
C2/835A: AA           TAX 
C2/835B: 86 52        STX $52
C2/835D: A6 49        LDX $49
C2/835F: BD 2D 20     LDA $202D,X
C2/8362: AA           TAX 
C2/8363: 86 54        STX $54
C2/8365: 60           RTS 

; [  ]

C2/8366: A5 39        LDA $39
C2/8368: AA           TAX 
C2/8369: BD FC 79     LDA $79FC,X
C2/836C: 29 40        AND #$40
C2/836E: D0 2A        BNE $839A
C2/8370: AD 2C 7B     LDA $7B2C
C2/8373: 0A           ASL 
C2/8374: AA           TAX 
C2/8375: BD FC 7A     LDA $7AFC,X
C2/8378: 29 F0        AND #$F0
C2/837A: D0 14        BNE $8390
C2/837C: BD FC 7A     LDA $7AFC,X
C2/837F: 29 0F        AND #$0F
C2/8381: 20 B5 01     JSR $01B5       ; a << 4
C2/8384: 85 0E        STA $0E
C2/8386: BD FD 7A     LDA $7AFD,X
C2/8389: 29 F0        AND #$F0
C2/838B: 20 BE 01     JSR $01BE       ; a >> 4
C2/838E: 05 0E        ORA $0E
C2/8390: 20 C3 01     JSR $01C3       ; count set bits
C2/8393: CA           DEX 
C2/8394: F0 04        BEQ $839A
C2/8396: 46 51        LSR $51
C2/8398: 66 50        ROR $50
C2/839A: 60           RTS 

; [  ]

C2/839B: A6 32        LDX $32
C2/839D: BD 1E 20     LDA $201E,X
C2/83A0: 29 10        AND #$10
C2/83A2: D0 18        BNE $83BC
C2/83A4: BD 00 20     LDA $2000,X
C2/83A7: 10 06        BPL $83AF
C2/83A9: C2 20        REP #$20
C2/83AB: 46 52        LSR $52
C2/83AD: E2 20        SEP #$20
C2/83AF: A6 49        LDX $49
C2/83B1: BD 00 20     LDA $2000,X
C2/83B4: 10 06        BPL $83BC
C2/83B6: C2 20        REP #$20
C2/83B8: 46 52        LSR $52
C2/83BA: E2 20        SEP #$20
C2/83BC: 60           RTS 

; [  ]

C2/83BD: A6 32        LDX $32
C2/83BF: BD 1F 20     LDA $201F,X
C2/83C2: 29 40        AND #$40
C2/83C4: F0 06        BEQ $83CC
C2/83C6: C2 20        REP #$20
C2/83C8: 06 50        ASL $50
C2/83CA: E2 20        SEP #$20
C2/83CC: BD 1F 20     LDA $201F,X
C2/83CF: 29 20        AND #$20
C2/83D1: F0 07        BEQ $83DA
C2/83D3: C2 20        REP #$20
C2/83D5: 46 50        LSR $50
C2/83D7: 7B           TDC 
C2/83D8: E2 20        SEP #$20
C2/83DA: BD 1F 20     LDA $201F,X
C2/83DD: 29 10        AND #$10
C2/83DF: F0 06        BEQ $83E7
C2/83E1: C2 20        REP #$20
C2/83E3: 06 52        ASL $52
C2/83E5: E2 20        SEP #$20
C2/83E7: BD 1F 20     LDA $201F,X
C2/83EA: 29 08        AND #$08
C2/83EC: F0 07        BEQ $83F5
C2/83EE: C2 20        REP #$20
C2/83F0: 46 52        LSR $52
C2/83F2: 7B           TDC 
C2/83F3: E2 20        SEP #$20
C2/83F5: BD 1F 20     LDA $201F,X
C2/83F8: 29 04        AND #$04
C2/83FA: F0 04        BEQ $8400
C2/83FC: 7B           TDC 
C2/83FD: AA           TAX 
C2/83FE: 86 54        STX $54
C2/8400: A6 49        LDX $49
C2/8402: BD 65 20     LDA $2065,X
C2/8405: 10 0F        BPL $8416
C2/8407: A6 32        LDX $32
C2/8409: BD 1F 20     LDA $201F,X
C2/840C: 29 01        AND #$01
C2/840E: F0 06        BEQ $8416
C2/8410: C2 20        REP #$20
C2/8412: 06 50        ASL $50
C2/8414: E2 20        SEP #$20
C2/8416: A6 49        LDX $49
C2/8418: BD 1E 20     LDA $201E,X
C2/841B: 10 07        BPL $8424
C2/841D: C2 20        REP #$20
C2/841F: 46 52        LSR $52
C2/8421: 7B           TDC 
C2/8422: E2 20        SEP #$20
C2/8424: BD 1E 20     LDA $201E,X
C2/8427: 29 40        AND #$40
C2/8429: F0 04        BEQ $842F
C2/842B: 7B           TDC 
C2/842C: AA           TAX 
C2/842D: 86 50        STX $50
C2/842F: 60           RTS 

; [  ]

C2/8430: A6 32        LDX $32
C2/8432: BD 21 20     LDA $2021,X
C2/8435: 29 20        AND #$20
C2/8437: F0 18        BEQ $8451
C2/8439: BD 11 20     LDA $2011,X
C2/843C: 1D 12 20     ORA $2012,X
C2/843F: D0 10        BNE $8451
C2/8441: BD 13 20     LDA $2013,X
C2/8444: F0 05        BEQ $844B
C2/8446: BD 14 20     LDA $2014,X
C2/8449: D0 06        BNE $8451
C2/844B: C2 20        REP #$20
C2/844D: 06 52        ASL $52
C2/844F: E2 20        SEP #$20
C2/8451: 60           RTS 

; [  ]
C2/8452: A6 32        LDX $32
C2/8454: BD 1E 20     LDA $201E,X
C2/8457: 29 10        AND #$10
C2/8459: F0 08        BEQ $8463
C2/845B: C2 20        REP #$20
C2/845D: 06 52        ASL $52
C2/845F: 7B           TDC 
C2/8460: E2 20        SEP #$20
C2/8462: 60           RTS 
C2/8463: 20 9B 83     JSR $839B
C2/8466: 60           RTS 

; [  ]

C2/8467: A5 59        LDA $59
C2/8469: AA           TAX 
C2/846A: 86 12        STX $12
C2/846C: A5 58        LDA $58
C2/846E: AA           TAX 
C2/846F: 86 10        STX $10
C2/8471: C2 20        REP #$20
C2/8473: A6 32        LDX $32
C2/8475: BD 0A 20     LDA $200A,X
C2/8478: C5 12        CMP $12
C2/847A: 90 2F        BCC $84AB
C2/847C: 38           SEC 
C2/847D: E5 12        SBC $12
C2/847F: 9D 0A 20     STA $200A,X
C2/8482: 18           CLC 
C2/8483: A5 50        LDA $50
C2/8485: 65 10        ADC $10
C2/8487: 85 50        STA $50
C2/8489: 7B           TDC 
C2/848A: E2 20        SEP #$20
C2/848C: AD E5 7B     LDA $7BE5
C2/848F: 85 24        STA $24
C2/8491: AD E4 7B     LDA $7BE4
C2/8494: 85 25        STA $25
C2/8496: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8499: C2 20        REP #$20
C2/849B: A5 26        LDA $26
C2/849D: 20 BB 01     JSR $01BB       ; a >> 7
C2/84A0: 18           CLC 
C2/84A1: 65 52        ADC $52
C2/84A3: 85 52        STA $52
C2/84A5: 7B           TDC 
C2/84A6: E2 20        SEP #$20
C2/84A8: E6 5F        INC $5F
C2/84AA: 60           RTS 
C2/84AB: 7B           TDC 
C2/84AC: E2 20        SEP #$20
C2/84AE: 60           RTS 

; [  ]

C2/84AF: A6 32        LDX $32
C2/84B1: BD 6E 20     LDA $206E,X
C2/84B4: 10 04        BPL $84BA
C2/84B6: 64 54        STZ $54
C2/84B8: 64 55        STZ $55
C2/84BA: BD 6E 20     LDA $206E,X
C2/84BD: 29 01        AND #$01
C2/84BF: F0 0D        BEQ $84CE
C2/84C1: C2 20        REP #$20
C2/84C3: A5 50        LDA $50
C2/84C5: 4A           LSR 
C2/84C6: 18           CLC 
C2/84C7: 65 50        ADC $50
C2/84C9: 85 50        STA $50
C2/84CB: 7B           TDC 
C2/84CC: E2 20        SEP #$20
C2/84CE: 60           RTS 

; [  ]

C2/84CF: A6 32        LDX $32
C2/84D1: BD 21 20     LDA $2021,X
C2/84D4: 29 10        AND #$10
C2/84D6: F0 04        BEQ $84DC
C2/84D8: 06 52        ASL $52
C2/84DA: 26 53        ROL $53
C2/84DC: 60           RTS 

; [  ]

C2/84DD: A6 49        LDX $49
C2/84DF: BD 65 20     LDA $2065,X
C2/84E2: 25 59        AND $59
C2/84E4: F0 0C        BEQ $84F2
C2/84E6: C2 20        REP #$20
C2/84E8: A5 50        LDA $50
C2/84EA: 20 B6 01     JSR $01B6       ; a << 3
C2/84ED: 85 50        STA $50
C2/84EF: 7B           TDC 
C2/84F0: E2 20        SEP #$20
C2/84F2: 60           RTS 

; [  ]

C2/84F3: A6 49        LDX $49
C2/84F5: BD 1C 20     LDA $201C,X
C2/84F8: 1D 72 20     ORA $2072,X
C2/84FB: 29 20        AND #$20
C2/84FD: F0 04        BEQ $8503
C2/84FF: 46 53        LSR $53
C2/8501: 66 52        ROR $52
C2/8503: BD 1A 20     LDA $201A,X
C2/8506: 1D 70 20     ORA $2070,X
C2/8509: 29 20        AND #$20
C2/850B: F0 04        BEQ $8511
C2/850D: 64 54        STZ $54
C2/850F: 64 55        STZ $55
C2/8511: 60           RTS 

; [  ]

C2/8512: A6 49        LDX $49
C2/8514: BD 1A 20     LDA $201A,X
C2/8517: 1D 70 20     ORA $2070,X
C2/851A: 29 30        AND #$30
C2/851C: F0 04        BEQ $8522
C2/851E: 7B           TDC 
C2/851F: AA           TAX 
C2/8520: 86 54        STX $54
C2/8522: BD 1C 20     LDA $201C,X
C2/8525: 1D 72 20     ORA $2072,X
C2/8528: 29 40        AND #$40
C2/852A: F0 06        BEQ $8532
C2/852C: C2 20        REP #$20
C2/852E: 46 52        LSR $52
C2/8530: E2 20        SEP #$20
C2/8532: 60           RTS 

; [  ]

C2/8533: A6 32        LDX $32
C2/8535: BD 1A 20     LDA $201A,X
C2/8538: 1D 70 20     ORA $2070,X
C2/853B: 29 30        AND #$30
C2/853D: F0 05        BEQ $8544
C2/853F: A2 03 00     LDX #$0003
C2/8542: 86 50        STX $50
C2/8544: BD 1B 20     LDA $201B,X
C2/8547: 1D 71 20     ORA $2071,X
C2/854A: 29 08        AND #$08
C2/854C: F0 0E        BEQ $855C
C2/854E: C2 20        REP #$20
C2/8550: A5 50        LDA $50
C2/8552: 0A           ASL 
C2/8553: 18           CLC 
C2/8554: 65 50        ADC $50
C2/8556: 4A           LSR 
C2/8557: 85 50        STA $50
C2/8559: 7B           TDC 
C2/855A: E2 20        SEP #$20
C2/855C: 60           RTS 

; [  ]

C2/855D: A6 49        LDX $49
C2/855F: BD 02 20     LDA $2002,X
C2/8562: A6 32        LDX $32
C2/8564: DD 02 20     CMP $2002,X
C2/8567: D0 0D        BNE $8576
C2/8569: C2 20        REP #$20
C2/856B: 06 50        ASL $50
C2/856D: 06 50        ASL $50
C2/856F: 06 50        ASL $50
C2/8571: 7B           TDC 
C2/8572: 85 54        STA $54
C2/8574: E2 20        SEP #$20
C2/8576: 60           RTS 

; [  ]

C2/8577: A5 39        LDA $39
C2/8579: AA           TAX 
C2/857A: 38           SEC 
C2/857B: BD 03 7A     LDA $7A03,X
C2/857E: ED 75 7C     SBC $7C75       ; subtract escape count
C2/8581: B0 01        BCS $8584
C2/8583: 7B           TDC 
C2/8584: AA           TAX 
C2/8585: 86 50        STX $50
C2/8587: AD E5 7B     LDA $7BE5
C2/858A: 85 24        STA $24
C2/858C: AD E1 7B     LDA $7BE1
C2/858F: 85 25        STA $25
C2/8591: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/8594: C2 20        REP #$20
C2/8596: A5 26        LDA $26
C2/8598: 20 BB 01     JSR $01BB       ; a >> 7
C2/859B: 18           CLC 
C2/859C: 69 02 00     ADC #$0002
C2/859F: 85 52        STA $52
C2/85A1: 7B           TDC 
C2/85A2: E2 20        SEP #$20
C2/85A4: A6 49        LDX $49
C2/85A6: BD 2D 20     LDA $202D,X
C2/85A9: AA           TAX 
C2/85AA: 86 54        STX $54
C2/85AC: 60           RTS 

; [  ]

C2/85AD: A6 32        LDX $32
C2/85AF: 18           CLC 
C2/85B0: BD 44 20     LDA $2044,X
C2/85B3: 7D 45 20     ADC $2045,X
C2/85B6: 85 50        STA $50
C2/85B8: 7B           TDC 
C2/85B9: 69 00        ADC #$00
C2/85BB: 85 51        STA $51
C2/85BD: A5 47        LDA $47
C2/85BF: C9 04        CMP #$04
C2/85C1: 90 08        BCC $85CB
C2/85C3: BD 62 20     LDA $2062,X
C2/85C6: AA           TAX 
C2/85C7: 86 52        STX $52
C2/85C9: 80 1D        BRA $85E8
C2/85CB: AD E5 7B     LDA $7BE5
C2/85CE: 85 24        STA $24
C2/85D0: AD E1 7B     LDA $7BE1
C2/85D3: 85 25        STA $25
C2/85D5: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/85D8: C2 20        REP #$20
C2/85DA: A5 26        LDA $26
C2/85DC: 20 BB 01     JSR $01BB       ; a >> 7
C2/85DF: 18           CLC 
C2/85E0: 69 02 00     ADC #$0002
C2/85E3: 85 52        STA $52
C2/85E5: 7B           TDC 
C2/85E6: E2 20        SEP #$20
C2/85E8: A6 49        LDX $49
C2/85EA: BD 2D 20     LDA $202D,X
C2/85ED: AA           TAX 
C2/85EE: 86 54        STX $54
C2/85F0: 60           RTS 

; [  ]

C2/85F1: A6 32        LDX $32
C2/85F3: 18           CLC 
C2/85F4: BD 44 20     LDA $2044,X
C2/85F7: 48           PHA 
C2/85F8: C2 20        REP #$20
C2/85FA: 20 B6 01     JSR $01B6       ; a << 3
C2/85FD: 85 50        STA $50
C2/85FF: 7B           TDC 
C2/8600: E2 20        SEP #$20
C2/8602: BD 62 20     LDA $2062,X
C2/8605: AA           TAX 
C2/8606: 86 52        STX $52
C2/8608: 68           PLA 
C2/8609: 20 BF 01     JSR $01BF       ; a >> 3
C2/860C: A2 00 00     LDX #$0000
C2/860F: 20 7C 00     JSR $007C       ; a = (x..a)
C2/8612: 18           CLC 
C2/8613: 65 50        ADC $50
C2/8615: 85 50        STA $50
C2/8617: A5 51        LDA $51
C2/8619: 69 00        ADC #$00
C2/861B: 85 51        STA $51
C2/861D: A6 49        LDX $49
C2/861F: BD 2D 20     LDA $202D,X
C2/8622: AA           TAX 
C2/8623: 86 54        STX $54
C2/8625: 60           RTS 

; [ calculate chicken knife damage ]

C2/8626: AD 75 7C     LDA $7C75       ; escape count
C2/8629: 4A           LSR 
C2/862A: AA           TAX 
C2/862B: 86 50        STX $50
C2/862D: AD E5 7B     LDA $7BE5
C2/8630: 85 24        STA $24
C2/8632: AD E1 7B     LDA $7BE1
C2/8635: 85 25        STA $25
C2/8637: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/863A: A6 26        LDX $26
C2/863C: 86 0E        STX $0E
C2/863E: AD E5 7B     LDA $7BE5
C2/8641: 85 24        STA $24
C2/8643: AD E2 7B     LDA $7BE2
C2/8646: 85 25        STA $25
C2/8648: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/864B: C2 20        REP #$20
C2/864D: A5 26        LDA $26
C2/864F: 20 BB 01     JSR $01BB       ; a >> 7
C2/8652: 85 10        STA $10
C2/8654: A5 0E        LDA $0E
C2/8656: 20 BB 01     JSR $01BB       ; a >> 7
C2/8659: 18           CLC 
C2/865A: 65 10        ADC $10
C2/865C: 69 02 00     ADC #$0002
C2/865F: 85 52        STA $52
C2/8661: 7B           TDC 
C2/8662: E2 20        SEP #$20
C2/8664: A6 49        LDX $49         ; pointer to target properties
C2/8666: BD 2D 20     LDA $202D,X     ; defense
C2/8669: AA           TAX 
C2/866A: 86 54        STX $54
C2/866C: 60           RTS 

; [  ]

C2/866D: A6 32        LDX $32
C2/866F: BD 22 20     LDA $2022,X
C2/8672: 25 4D        AND $4D
C2/8674: F0 0D        BEQ $8683
C2/8676: C2 20        REP #$20
C2/8678: A5 50        LDA $50
C2/867A: 4A           LSR 
C2/867B: 18           CLC 
C2/867C: 65 50        ADC $50
C2/867E: 85 50        STA $50
C2/8680: 7B           TDC 
C2/8681: E2 20        SEP #$20
C2/8683: 60           RTS 

; [  ]

C2/8684: A6 32        LDX $32
C2/8686: BD 50 20     LDA $2050,X
C2/8689: 1D 51 20     ORA $2051,X
C2/868C: 1D 52 20     ORA $2052,X
C2/868F: 85 4D        STA $4D
C2/8691: 1D 53 20     ORA $2053,X
C2/8694: 1D 54 20     ORA $2054,X
C2/8697: 1D 55 20     ORA $2055,X
C2/869A: F0 02        BEQ $869E
C2/869C: E6 60        INC $60
C2/869E: BD 55 20     LDA $2055,X
C2/86A1: 10 12        BPL $86B5
C2/86A3: C2 20        REP #$20
C2/86A5: 18           CLC 
C2/86A6: A5 50        LDA $50
C2/86A8: 69 64 00     ADC #$0064
C2/86AB: 85 50        STA $50
C2/86AD: 46 54        LSR $54
C2/86AF: 46 54        LSR $54
C2/86B1: 7B           TDC 
C2/86B2: E2 20        SEP #$20
C2/86B4: 60           RTS 
C2/86B5: A6 49        LDX $49
C2/86B7: BD 30 20     LDA $2030,X
C2/86BA: 25 4D        AND $4D
C2/86BC: F0 07        BEQ $86C5
C2/86BE: E6 62        INC $62
C2/86C0: 64 54        STZ $54
C2/86C2: 64 55        STZ $55
C2/86C4: 60           RTS 
C2/86C5: BD 32 20     LDA $2032,X
C2/86C8: 25 4D        AND $4D
C2/86CA: F0 03        BEQ $86CF
C2/86CC: E6 56        INC $56         ; miss
C2/86CE: 60           RTS 
C2/86CF: BD 33 20     LDA $2033,X
C2/86D2: 25 4D        AND $4D
C2/86D4: F0 05        BEQ $86DB
C2/86D6: 46 53        LSR $53
C2/86D8: 66 52        ROR $52
C2/86DA: 60           RTS 
C2/86DB: BD 34 20     LDA $2034,X
C2/86DE: 85 0E        STA $0E
C2/86E0: A6 32        LDX $32
C2/86E2: 3D 52 20     AND $2052,X
C2/86E5: F0 26        BEQ $870D
C2/86E7: A6 49        LDX $49
C2/86E9: BD 65 20     LDA $2065,X
C2/86EC: 29 20        AND #$20
C2/86EE: F0 0B        BEQ $86FB
C2/86F0: C2 20        REP #$20
C2/86F2: 06 50        ASL $50
C2/86F4: 06 50        ASL $50
C2/86F6: 64 54        STZ $54
C2/86F8: E2 20        SEP #$20
C2/86FA: 60           RTS 
C2/86FB: BD 1A 20     LDA $201A,X
C2/86FE: 29 02        AND #$02
C2/8700: D0 31        BNE $8733
C2/8702: BD 1A 20     LDA $201A,X
C2/8705: 09 80        ORA #$80
C2/8707: 9D 1A 20     STA $201A,X
C2/870A: E6 61        INC $61
C2/870C: 60           RTS 
C2/870D: A5 0E        LDA $0E
C2/870F: 3D 51 20     AND $2051,X
C2/8712: F0 10        BEQ $8724
C2/8714: C2 20        REP #$20
C2/8716: A5 50        LDA $50
C2/8718: 0A           ASL 
C2/8719: 18           CLC 
C2/871A: 65 50        ADC $50
C2/871C: 85 50        STA $50
C2/871E: 7B           TDC 
C2/871F: 85 54        STA $54
C2/8721: E2 20        SEP #$20
C2/8723: 60           RTS 
C2/8724: A5 0E        LDA $0E
C2/8726: 3D 50 20     AND $2050,X
C2/8729: F0 08        BEQ $8733
C2/872B: C2 20        REP #$20
C2/872D: 06 50        ASL $50
C2/872F: 64 54        STZ $54
C2/8731: E2 20        SEP #$20
C2/8733: 60           RTS 

; [  ]

C2/8734: A5 60        LDA $60
C2/8736: D0 35        BNE $876D
C2/8738: A6 49        LDX $49
C2/873A: BD 30 20     LDA $2030,X     ; absorbed elements
C2/873D: 25 4D        AND $4D
C2/873F: F0 07        BEQ $8748
C2/8741: E6 62        INC $62
C2/8743: 64 54        STZ $54
C2/8745: 64 55        STZ $55
C2/8747: 60           RTS 
C2/8748: BD 32 20     LDA $2032,X     ; immune elements
C2/874B: 25 4D        AND $4D
C2/874D: F0 03        BEQ $8752
C2/874F: E6 56        INC $56         ; miss
C2/8751: 60           RTS 
C2/8752: BD 33 20     LDA $2033,X     ; halved elements
C2/8755: 25 4D        AND $4D
C2/8757: F0 05        BEQ $875E
C2/8759: 46 51        LSR $51
C2/875B: 66 50        ROR $50
C2/875D: 60           RTS 
C2/875E: BD 34 20     LDA $2034,X     ; weak elements
C2/8761: 25 4D        AND $4D
C2/8763: F0 08        BEQ $876D
C2/8765: 06 50        ASL $50
C2/8767: 26 51        ROL $51
C2/8769: 64 54        STZ $54
C2/876B: 64 55        STZ $55
C2/876D: 60           RTS 

; [  ]

C2/876E: A5 60        LDA $60
C2/8770: D0 42        BNE $87B4
C2/8772: A6 49        LDX $49
C2/8774: BD 30 20     LDA $2030,X
C2/8777: 25 4D        AND $4D
C2/8779: F0 07        BEQ $8782
C2/877B: E6 62        INC $62
C2/877D: 64 54        STZ $54
C2/877F: 64 55        STZ $55
C2/8781: 60           RTS 
C2/8782: BD 31 20     LDA $2031,X
C2/8785: 25 4D        AND $4D
C2/8787: F0 03        BEQ $878C
C2/8789: E6 56        INC $56         ; miss
C2/878B: 60           RTS 
C2/878C: BD 32 20     LDA $2032,X
C2/878F: 25 4D        AND $4D
C2/8791: F0 06        BEQ $8799
C2/8793: E6 56        INC $56         ; miss
C2/8795: EE 97 7C     INC $7C97
C2/8798: 60           RTS 
C2/8799: BD 33 20     LDA $2033,X
C2/879C: 25 4D        AND $4D
C2/879E: F0 05        BEQ $87A5
C2/87A0: 46 51        LSR $51
C2/87A2: 66 50        ROR $50
C2/87A4: 60           RTS 
C2/87A5: BD 34 20     LDA $2034,X
C2/87A8: 25 4D        AND $4D
C2/87AA: F0 08        BEQ $87B4
C2/87AC: 06 50        ASL $50
C2/87AE: 26 51        ROL $51
C2/87B0: 64 54        STZ $54
C2/87B2: 64 55        STZ $55
C2/87B4: 60           RTS 

; [  ]

C2/87B5: A6 49        LDX $49
C2/87B7: BD 30 20     LDA $2030,X
C2/87BA: 25 4D        AND $4D
C2/87BC: F0 03        BEQ $87C1
C2/87BE: E6 62        INC $62
C2/87C0: 60           RTS 
C2/87C1: BD 32 20     LDA $2032,X
C2/87C4: 25 4D        AND $4D
C2/87C6: F0 03        BEQ $87CB
C2/87C8: E6 56        INC $56         ; miss
C2/87CA: 60           RTS 
C2/87CB: BD 33 20     LDA $2033,X
C2/87CE: 25 4D        AND $4D
C2/87D0: F0 03        BEQ $87D5
C2/87D2: 46 58        LSR $58
C2/87D4: 60           RTS 
C2/87D5: BD 34 20     LDA $2034,X
C2/87D8: 25 4D        AND $4D
C2/87DA: F0 02        BEQ $87DE
C2/87DC: 06 58        ASL $58
C2/87DE: 60           RTS 

; [  ]

C2/87DF: A5 60        LDA $60
C2/87E1: D0 15        BNE $87F8
C2/87E3: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/87E6: C5 57        CMP $57
C2/87E8: B0 0E        BCS $87F8
C2/87EA: A9 01        LDA #$01
C2/87EC: 85 5F        STA $5F
C2/87EE: C2 20        REP #$20
C2/87F0: 06 50        ASL $50
C2/87F2: E2 20        SEP #$20
C2/87F4: 7B           TDC 
C2/87F5: AA           TAX 
C2/87F6: 86 54        STX $54
C2/87F8: 60           RTS 

; [  ]

C2/87F9: A6 49        LDX $49
C2/87FB: BD 65 20     LDA $2065,X
C2/87FE: 25 57        AND $57
C2/8800: F0 0E        BEQ $8810
C2/8802: A9 01        LDA #$01
C2/8804: 85 5F        STA $5F
C2/8806: C2 20        REP #$20
C2/8808: 06 52        ASL $52
C2/880A: E2 20        SEP #$20
C2/880C: 7B           TDC 
C2/880D: AA           TAX 
C2/880E: 86 54        STX $54
C2/8810: 60           RTS 

; [  ]

C2/8811: 20 F8 93     JSR $93F8       ; calculate damage
C2/8814: AE 69 7B     LDX $7B69
C2/8817: D0 04        BNE $881D
C2/8819: 8E 6D 7B     STX $7B6D
C2/881C: 60           RTS 
C2/881D: A5 39        LDA $39
C2/881F: AA           TAX 
C2/8820: BD FD 79     LDA $79FD,X
C2/8823: A6 49        LDX $49
C2/8825: 3D 64 20     AND $2064,X
C2/8828: F0 06        BEQ $8830
C2/882A: C2 20        REP #$20
C2/882C: 06 52        ASL $52
C2/882E: E2 20        SEP #$20
C2/8830: A6 32        LDX $32
C2/8832: BD 55 20     LDA $2055,X
C2/8835: 29 40        AND #$40
C2/8837: F0 03        BEQ $883C
C2/8839: 4C 26 89     JMP $8926
C2/883C: BD 55 20     LDA $2055,X
C2/883F: 29 20        AND #$20
C2/8841: F0 03        BEQ $8846
C2/8843: 4C 4D 89     JMP $894D
C2/8846: A5 62        LDA $62
C2/8848: F0 07        BEQ $8851
C2/884A: AE 69 7B     LDX $7B69
C2/884D: 8E 71 7B     STX $7B71
C2/8850: 60           RTS 
C2/8851: A5 63        LDA $63
C2/8853: F0 18        BEQ $886D
C2/8855: A6 32        LDX $32
C2/8857: BD 2D 20     LDA $202D,X
C2/885A: AA           TAX 
C2/885B: 86 54        STX $54
C2/885D: 20 F8 93     JSR $93F8       ; calculate damage
C2/8860: AE 69 7B     LDX $7B69
C2/8863: D0 04        BNE $8869
C2/8865: 8E 6B 7B     STX $7B6B
C2/8868: 60           RTS 
C2/8869: 8E 6B 7B     STX $7B6B
C2/886C: 60           RTS 
C2/886D: AE 69 7B     LDX $7B69
C2/8870: 8E 6D 7B     STX $7B6D
C2/8873: 60           RTS 

; [  ]

C2/8874: A6 49        LDX $49
C2/8876: BD 65 20     LDA $2065,X
C2/8879: 29 20        AND #$20
C2/887B: F0 09        BEQ $8886
C2/887D: 7B           TDC 
C2/887E: AA           TAX 
C2/887F: 8E 69 7B     STX $7B69
C2/8882: 8E 6D 7B     STX $7B6D
C2/8885: 60           RTS 
C2/8886: BD 06 20     LDA $2006,X
C2/8889: 85 2A        STA $2A
C2/888B: BD 07 20     LDA $2007,X
C2/888E: 85 2B        STA $2B
C2/8890: A5 58        LDA $58
C2/8892: AA           TAX 
C2/8893: 86 2C        STX $2C
C2/8895: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/8898: C2 20        REP #$20
C2/889A: 46 30        LSR $30
C2/889C: 66 2E        ROR $2E
C2/889E: 46 30        LSR $30
C2/88A0: 66 2E        ROR $2E
C2/88A2: 46 30        LSR $30
C2/88A4: 66 2E        ROR $2E
C2/88A6: 46 30        LSR $30
C2/88A8: 66 2E        ROR $2E
C2/88AA: E2 20        SEP #$20
C2/88AC: A6 30        LDX $30
C2/88AE: D0 07        BNE $88B7
C2/88B0: A6 2E        LDX $2E
C2/88B2: E0 0F 27     CPX #$270F
C2/88B5: 90 03        BCC $88BA
C2/88B7: A2 0F 27     LDX #$270F
C2/88BA: 8E 69 7B     STX $7B69
C2/88BD: 8E 6D 7B     STX $7B6D
C2/88C0: 60           RTS 

; [  ]

C2/88C1: A6 49        LDX $49
C2/88C3: BD 65 20     LDA $2065,X
C2/88C6: 29 01        AND #$01
C2/88C8: D0 07        BNE $88D1
C2/88CA: BD 39 20     LDA $2039,X
C2/88CD: 29 02        AND #$02
C2/88CF: F0 03        BEQ $88D4
C2/88D1: 4C 11 88     JMP $8811
C2/88D4: 20 F8 93     JSR $93F8       ; calculate damage
C2/88D7: AE 69 7B     LDX $7B69
C2/88DA: 8E 71 7B     STX $7B71
C2/88DD: 60           RTS 

; [  ]

C2/88DE: A6 49        LDX $49
C2/88E0: BD 65 20     LDA $2065,X
C2/88E3: 29 01        AND #$01
C2/88E5: D0 07        BNE $88EE
C2/88E7: BD 39 20     LDA $2039,X
C2/88EA: 29 02        AND #$02
C2/88EC: F0 03        BEQ $88F1
C2/88EE: 4C FD 88     JMP $88FD
C2/88F1: C2 20        REP #$20
C2/88F3: BD 08 20     LDA $2008,X
C2/88F6: 9D 06 20     STA $2006,X
C2/88F9: 7B           TDC 
C2/88FA: E2 20        SEP #$20
C2/88FC: 60           RTS 

; [  ]

C2/88FD: A6 49        LDX $49
C2/88FF: BD 65 20     LDA $2065,X
C2/8902: 29 20        AND #$20
C2/8904: F0 03        BEQ $8909
C2/8906: E6 56        INC $56         ; miss
C2/8908: 60           RTS 
C2/8909: 7B           TDC 
C2/890A: AA           TAX 
C2/890B: A9 08        LDA #$08
C2/890D: 20 7C 00     JSR $007C       ; a = (x..a)
C2/8910: 1A           INC 
C2/8911: AA           TAX 
C2/8912: 86 0E        STX $0E
C2/8914: C2 20        REP #$20
C2/8916: A6 49        LDX $49
C2/8918: A5 0E        LDA $0E
C2/891A: DD 06 20     CMP $2006,X
C2/891D: B0 03        BCS $8922
C2/891F: 9D 06 20     STA $2006,X
C2/8922: 7B           TDC 
C2/8923: E2 20        SEP #$20
C2/8925: 60           RTS 

; [  ]

C2/8926: 20 F8 93     JSR $93F8       ; calculate damage
C2/8929: A6 49        LDX $49
C2/892B: BD 65 20     LDA $2065,X
C2/892E: 29 01        AND #$01
C2/8930: D0 07        BNE $8939
C2/8932: BD 39 20     LDA $2039,X
C2/8935: 29 02        AND #$02
C2/8937: F0 0A        BEQ $8943
C2/8939: AE 69 7B     LDX $7B69
C2/893C: 8E 6B 7B     STX $7B6B
C2/893F: 8E 71 7B     STX $7B71
C2/8942: 60           RTS 
C2/8943: AE 69 7B     LDX $7B69
C2/8946: 8E 6D 7B     STX $7B6D
C2/8949: 8E 6F 7B     STX $7B6F
C2/894C: 60           RTS 

; [  ]

C2/894D: A6 49        LDX $49
C2/894F: BD 65 20     LDA $2065,X
C2/8952: 29 01        AND #$01
C2/8954: D0 07        BNE $895D
C2/8956: BD 39 20     LDA $2039,X
C2/8959: 29 02        AND #$02
C2/895B: F0 14        BEQ $8971
C2/895D: A6 32        LDX $32
C2/895F: C2 20        REP #$20
C2/8961: BD 0A 20     LDA $200A,X
C2/8964: 20 C0 01     JSR $01C0       ; a >> 2
C2/8967: 8D 75 7B     STA $7B75
C2/896A: 8D 77 7B     STA $7B77
C2/896D: 7B           TDC 
C2/896E: E2 20        SEP #$20
C2/8970: 60           RTS 
C2/8971: A6 49        LDX $49
C2/8973: C2 20        REP #$20
C2/8975: BD 0A 20     LDA $200A,X
C2/8978: 20 C0 01     JSR $01C0       ; a >> 2
C2/897B: 8D 73 7B     STA $7B73
C2/897E: 8D 79 7B     STA $7B79
C2/8981: 7B           TDC 
C2/8982: E2 20        SEP #$20
C2/8984: 60           RTS 

; [  ]

C2/8985: C2 20        REP #$20
C2/8987: 38           SEC 
C2/8988: A5 50        LDA $50
C2/898A: E5 54        SBC $54
C2/898C: 85 2A        STA $2A
C2/898E: A5 52        LDA $52
C2/8990: 85 2C        STA $2C
C2/8992: 7B           TDC 
C2/8993: E2 20        SEP #$20
C2/8995: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/8998: A6 49        LDX $49
C2/899A: BD 65 20     LDA $2065,X
C2/899D: 29 01        AND #$01
C2/899F: D0 07        BNE $89A8
C2/89A1: BD 39 20     LDA $2039,X
C2/89A4: 29 02        AND #$02
C2/89A6: F0 1A        BEQ $89C2       ; branch if not undead
C2/89A8: C2 20        REP #$20
C2/89AA: A6 32        LDX $32
C2/89AC: A5 2E        LDA $2E
C2/89AE: DD 0A 20     CMP $200A,X     ; current mp
C2/89B1: 90 05        BCC $89B8
C2/89B3: BD 0A 20     LDA $200A,X
C2/89B6: 85 2E        STA $2E
C2/89B8: A5 2E        LDA $2E
C2/89BA: 8D 75 7B     STA $7B75
C2/89BD: 8D 77 7B     STA $7B77
C2/89C0: 80 18        BRA $89DA
C2/89C2: C2 20        REP #$20
C2/89C4: A6 49        LDX $49
C2/89C6: A5 2E        LDA $2E
C2/89C8: DD 0A 20     CMP $200A,X     ; current mp
C2/89CB: 90 05        BCC $89D2
C2/89CD: BD 0A 20     LDA $200A,X
C2/89D0: 85 2E        STA $2E
C2/89D2: A5 2E        LDA $2E
C2/89D4: 8D 73 7B     STA $7B73
C2/89D7: 8D 79 7B     STA $7B79
C2/89DA: 7B           TDC 
C2/89DB: E2 20        SEP #$20
C2/89DD: 60           RTS 

; [  ]

C2/89DE: C2 20        REP #$20
C2/89E0: 38           SEC 
C2/89E1: A5 50        LDA $50
C2/89E3: E5 54        SBC $54
C2/89E5: 85 2A        STA $2A
C2/89E7: A5 52        LDA $52
C2/89E9: 85 2C        STA $2C
C2/89EB: 7B           TDC 
C2/89EC: E2 20        SEP #$20
C2/89EE: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/89F1: A6 2E        LDX $2E
C2/89F3: 8E 75 7B     STX $7B75
C2/89F6: 60           RTS 

; [  ]

C2/89F7: C2 20        REP #$20
C2/89F9: A6 49        LDX $49
C2/89FB: BD 0C 20     LDA $200C,X
C2/89FE: 9D 0A 20     STA $200A,X
C2/8A01: 7B           TDC 
C2/8A02: E2 20        SEP #$20
C2/8A04: 60           RTS 
C2/8A05: 20 F8 93     JSR $93F8       ; calculate damage
C2/8A08: AE 69 7B     LDX $7B69
C2/8A0B: F0 3A        BEQ $8A47
C2/8A0D: A6 52        LDX $52
C2/8A0F: D0 15        BNE $8A26
C2/8A11: E6 52        INC $52
C2/8A13: A5 39        LDA $39
C2/8A15: AA           TAX 
C2/8A16: BD FD 79     LDA $79FD,X
C2/8A19: A6 49        LDX $49
C2/8A1B: 3D 64 20     AND $2064,X
C2/8A1E: F0 06        BEQ $8A26
C2/8A20: C2 20        REP #$20
C2/8A22: 06 52        ASL $52
C2/8A24: E2 20        SEP #$20
C2/8A26: A5 62        LDA $62
C2/8A28: F0 07        BEQ $8A31
C2/8A2A: AE 69 7B     LDX $7B69
C2/8A2D: 8E 71 7B     STX $7B71
C2/8A30: 60           RTS 
C2/8A31: A5 63        LDA $63
C2/8A33: F0 12        BEQ $8A47
C2/8A35: A6 32        LDX $32
C2/8A37: BD 2D 20     LDA $202D,X
C2/8A3A: AA           TAX 
C2/8A3B: 86 54        STX $54
C2/8A3D: 20 F8 93     JSR $93F8       ; calculate damage
C2/8A40: AE 69 7B     LDX $7B69
C2/8A43: 8E 6B 7B     STX $7B6B
C2/8A46: 60           RTS 
C2/8A47: AE 69 7B     LDX $7B69
C2/8A4A: 8E 6D 7B     STX $7B6D
C2/8A4D: 60           RTS 
C2/8A4E: A5 58        LDA $58
C2/8A50: AA           TAX 
C2/8A51: 86 2C        STX $2C
C2/8A53: A6 49        LDX $49
C2/8A55: BD 08 20     LDA $2008,X
C2/8A58: 85 2A        STA $2A
C2/8A5A: BD 09 20     LDA $2009,X
C2/8A5D: 85 2B        STA $2B
C2/8A5F: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/8A62: C2 20        REP #$20
C2/8A64: 46 30        LSR $30
C2/8A66: 66 2E        ROR $2E
C2/8A68: 46 30        LSR $30
C2/8A6A: 66 2E        ROR $2E
C2/8A6C: 46 30        LSR $30
C2/8A6E: 66 2E        ROR $2E
C2/8A70: 46 30        LSR $30
C2/8A72: 66 2E        ROR $2E
C2/8A74: A5 30        LDA $30
C2/8A76: D0 07        BNE $8A7F
C2/8A78: A5 2E        LDA $2E
C2/8A7A: C9 0F 27     CMP #$270F
C2/8A7D: 90 05        BCC $8A84
C2/8A7F: A9 0F 27     LDA #$270F
C2/8A82: 85 2E        STA $2E
C2/8A84: A5 2E        LDA $2E
C2/8A86: 05 30        ORA $30
C2/8A88: D0 02        BNE $8A8C
C2/8A8A: E6 2E        INC $2E
C2/8A8C: 7B           TDC 
C2/8A8D: E2 20        SEP #$20
C2/8A8F: A6 2E        LDX $2E
C2/8A91: A5 62        LDA $62
C2/8A93: D0 04        BNE $8A99
C2/8A95: 8E 6D 7B     STX $7B6D
C2/8A98: 60           RTS 
C2/8A99: 8E 71 7B     STX $7B71
C2/8A9C: 60           RTS 

; [  ]

C2/8A9D: A5 58        LDA $58
C2/8A9F: AA           TAX 
C2/8AA0: 86 2C        STX $2C
C2/8AA2: A6 32        LDX $32
C2/8AA4: BD 06 20     LDA $2006,X
C2/8AA7: 85 2A        STA $2A
C2/8AA9: BD 07 20     LDA $2007,X
C2/8AAC: 85 2B        STA $2B
C2/8AAE: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/8AB1: C2 20        REP #$20
C2/8AB3: 46 30        LSR $30
C2/8AB5: 66 2E        ROR $2E
C2/8AB7: 46 30        LSR $30
C2/8AB9: 66 2E        ROR $2E
C2/8ABB: 46 30        LSR $30
C2/8ABD: 66 2E        ROR $2E
C2/8ABF: 46 30        LSR $30
C2/8AC1: 66 2E        ROR $2E
C2/8AC3: A5 30        LDA $30
C2/8AC5: D0 07        BNE $8ACE
C2/8AC7: A5 2E        LDA $2E
C2/8AC9: C9 0F 27     CMP #$270F
C2/8ACC: 90 05        BCC $8AD3
C2/8ACE: A9 0F 27     LDA #$270F
C2/8AD1: 85 2E        STA $2E
C2/8AD3: A5 2E        LDA $2E
C2/8AD5: 05 30        ORA $30
C2/8AD7: D0 02        BNE $8ADB
C2/8AD9: E6 2E        INC $2E
C2/8ADB: 7B           TDC 
C2/8ADC: E2 20        SEP #$20
C2/8ADE: A6 2E        LDX $2E
C2/8AE0: A5 62        LDA $62
C2/8AE2: D0 04        BNE $8AE8
C2/8AE4: 8E 6D 7B     STX $7B6D
C2/8AE7: 60           RTS 
C2/8AE8: 8E 71 7B     STX $7B71
C2/8AEB: 60           RTS 

; [  ]

C2/8AEC: A5 58        LDA $58
C2/8AEE: AA           TAX 
C2/8AEF: 86 2C        STX $2C
C2/8AF1: A6 49        LDX $49
C2/8AF3: BD 0A 20     LDA $200A,X
C2/8AF6: 85 2A        STA $2A
C2/8AF8: BD 0B 20     LDA $200B,X
C2/8AFB: 85 2B        STA $2B
C2/8AFD: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/8B00: C2 20        REP #$20
C2/8B02: 46 30        LSR $30
C2/8B04: 66 2E        ROR $2E
C2/8B06: 46 30        LSR $30
C2/8B08: 66 2E        ROR $2E
C2/8B0A: 46 30        LSR $30
C2/8B0C: 66 2E        ROR $2E
C2/8B0E: 46 30        LSR $30
C2/8B10: 66 2E        ROR $2E
C2/8B12: A5 30        LDA $30
C2/8B14: D0 07        BNE $8B1D
C2/8B16: A5 2E        LDA $2E
C2/8B18: C9 0F 27     CMP #$270F
C2/8B1B: 90 05        BCC $8B22
C2/8B1D: A9 0F 27     LDA #$270F
C2/8B20: 85 2E        STA $2E
C2/8B22: A5 2E        LDA $2E
C2/8B24: 05 30        ORA $30
C2/8B26: D0 02        BNE $8B2A
C2/8B28: E6 2E        INC $2E
C2/8B2A: 7B           TDC 
C2/8B2B: E2 20        SEP #$20
C2/8B2D: A6 2E        LDX $2E
C2/8B2F: 8E 79 7B     STX $7B79
C2/8B32: 60           RTS 

; [  ]

C2/8B33: C2 20        REP #$20
C2/8B35: A6 32        LDX $32
C2/8B37: 38           SEC 
C2/8B38: BD 08 20     LDA $2008,X
C2/8B3B: FD 06 20     SBC $2006,X
C2/8B3E: C9 0F 27     CMP #$270F
C2/8B41: 90 03        BCC $8B46
C2/8B43: A9 0F 27     LDA #$270F
C2/8B46: 8D 6D 7B     STA $7B6D
C2/8B49: 7B           TDC 
C2/8B4A: E2 20        SEP #$20
C2/8B4C: 60           RTS 

; [  ]

C2/8B4D: C2 20        REP #$20
C2/8B4F: A6 49        LDX $49
C2/8B51: BD 08 20     LDA $2008,X
C2/8B54: 4A           LSR 
C2/8B55: 18           CLC 
C2/8B56: 7D 06 20     ADC $2006,X
C2/8B59: B0 05        BCS $8B60
C2/8B5B: DD 08 20     CMP $2008,X
C2/8B5E: 90 03        BCC $8B63
C2/8B60: BD 08 20     LDA $2008,X
C2/8B63: 9D 06 20     STA $2006,X
C2/8B66: BD 0C 20     LDA $200C,X
C2/8B69: 4A           LSR 
C2/8B6A: 18           CLC 
C2/8B6B: 7D 0A 20     ADC $200A,X
C2/8B6E: DD 0C 20     CMP $200C,X
C2/8B71: 90 03        BCC $8B76
C2/8B73: BD 0C 20     LDA $200C,X
C2/8B76: 9D 0A 20     STA $200A,X
C2/8B79: 7B           TDC 
C2/8B7A: E2 20        SEP #$20
C2/8B7C: 60           RTS 

; [  ]

C2/8B7D: 64 0F        STZ $0F
C2/8B7F: A5 58        LDA $58
C2/8B81: 29 7F        AND #$7F
C2/8B83: 0A           ASL 
C2/8B84: 26 0F        ROL $0F
C2/8B86: 85 0E        STA $0E
C2/8B88: AD E5 7B     LDA $7BE5
C2/8B8B: 20 C0 01     JSR $01C0       ; a >> 2
C2/8B8E: 18           CLC 
C2/8B8F: 65 0E        ADC $0E
C2/8B91: 85 0E        STA $0E
C2/8B93: A5 0F        LDA $0F
C2/8B95: 69 00        ADC #$00
C2/8B97: F0 04        BEQ $8B9D
C2/8B99: A9 FF        LDA #$FF
C2/8B9B: 85 0E        STA $0E
C2/8B9D: A5 58        LDA $58
C2/8B9F: 30 28        BMI $8BC9
C2/8BA1: A6 49        LDX $49
C2/8BA3: BD 65 20     LDA $2065,X
C2/8BA6: 29 20        AND #$20
C2/8BA8: F0 06        BEQ $8BB0
C2/8BAA: A9 1E        LDA #$1E
C2/8BAC: 85 0E        STA $0E
C2/8BAE: 80 19        BRA $8BC9
C2/8BB0: 18           CLC 
C2/8BB1: BD 02 20     LDA $2002,X
C2/8BB4: 7D 78 20     ADC $2078,X
C2/8BB7: 20 C0 01     JSR $01C0       ; a >> 2
C2/8BBA: 85 0F        STA $0F
C2/8BBC: 38           SEC 
C2/8BBD: A5 0E        LDA $0E
C2/8BBF: E5 0F        SBC $0F
C2/8BC1: F0 02        BEQ $8BC5
C2/8BC3: B0 02        BCS $8BC7
C2/8BC5: A9 01        LDA #$01
C2/8BC7: 85 0E        STA $0E
C2/8BC9: A5 0E        LDA $0E
C2/8BCB: 8D D8 3E     STA $3ED8       ; status duration
C2/8BCE: 60           RTS 

; [  ]

C2/8BCF: A5 59        LDA $59
C2/8BD1: 48           PHA 
C2/8BD2: A6 32        LDX $32
C2/8BD4: BD 53 20     LDA $2053,X
C2/8BD7: 85 59        STA $59
C2/8BD9: A9 01        LDA #$01
C2/8BDB: 8D D7 3E     STA $3ED7       ; default timer duration
C2/8BDE: 20 AC 8C     JSR $8CAC
C2/8BE1: A6 32        LDX $32
C2/8BE3: BD 54 20     LDA $2054,X
C2/8BE6: 85 59        STA $59
C2/8BE8: A9 01        LDA #$01
C2/8BEA: 8D D7 3E     STA $3ED7       ; default timer duration
C2/8BED: 20 2E 8D     JSR $8D2E
C2/8BF0: 64 56        STZ $56
C2/8BF2: 68           PLA 
C2/8BF3: 85 59        STA $59
C2/8BF5: 9C D7 3E     STZ $3ED7       ; custom timer duration
C2/8BF8: 60           RTS 

; [  ]

C2/8BF9: A5 60        LDA $60
C2/8BFB: D0 2E        BNE $8C2B
C2/8BFD: A5 58        LDA $58
C2/8BFF: 29 7F        AND #$7F
C2/8C01: 85 4E        STA $4E
C2/8C03: 20 A2 02     JSR $02A2       ; a = (0..99)
C2/8C06: C5 4E        CMP $4E
C2/8C08: B0 21        BCS $8C2B
C2/8C0A: A5 58        LDA $58
C2/8C0C: 10 13        BPL $8C21
C2/8C0E: A9 01        LDA #$01
C2/8C10: 8D D7 3E     STA $3ED7       ; default timer duration
C2/8C13: 20 AC 8C     JSR $8CAC
C2/8C16: A6 49        LDX $49
C2/8C18: BD 1A 20     LDA $201A,X
C2/8C1B: 10 02        BPL $8C1F
C2/8C1D: E6 61        INC $61
C2/8C1F: 80 08        BRA $8C29
C2/8C21: A9 01        LDA #$01
C2/8C23: 8D D7 3E     STA $3ED7       ; default timer duration
C2/8C26: 20 2E 8D     JSR $8D2E
C2/8C29: 64 56        STZ $56
C2/8C2B: 9C D7 3E     STZ $3ED7       ; custom timer duration
C2/8C2E: 60           RTS 

; [  ]

C2/8C2F: 64 59        STZ $59
C2/8C31: A6 32        LDX $32
C2/8C33: BD 6E 20     LDA $206E,X
C2/8C36: 29 20        AND #$20
C2/8C38: F0 04        BEQ $8C3E
C2/8C3A: A9 04        LDA #$04
C2/8C3C: 85 59        STA $59
C2/8C3E: BD 6E 20     LDA $206E,X
C2/8C41: 29 10        AND #$10
C2/8C43: F0 06        BEQ $8C4B
C2/8C45: A5 59        LDA $59
C2/8C47: 09 01        ORA #$01
C2/8C49: 85 59        STA $59
C2/8C4B: A9 01        LDA #$01
C2/8C4D: 8D D7 3E     STA $3ED7       ; default timer duration
C2/8C50: 20 AC 8C     JSR $8CAC
C2/8C53: 64 59        STZ $59
C2/8C55: A6 32        LDX $32
C2/8C57: BD 6E 20     LDA $206E,X
C2/8C5A: 29 40        AND #$40
C2/8C5C: F0 04        BEQ $8C62
C2/8C5E: A9 80        LDA #$80
C2/8C60: 85 59        STA $59
C2/8C62: BD 6E 20     LDA $206E,X
C2/8C65: 29 08        AND #$08
C2/8C67: F0 06        BEQ $8C6F
C2/8C69: A5 59        LDA $59
C2/8C6B: 09 20        ORA #$20
C2/8C6D: 85 59        STA $59
C2/8C6F: BD 6E 20     LDA $206E,X
C2/8C72: 29 04        AND #$04
C2/8C74: F0 11        BEQ $8C87
C2/8C76: DA           PHX 
C2/8C77: A6 49        LDX $49
C2/8C79: BD 1D 20     LDA $201D,X
C2/8C7C: FA           PLX 
C2/8C7D: 29 20        AND #$20
C2/8C7F: D0 06        BNE $8C87
C2/8C81: A5 59        LDA $59
C2/8C83: 09 10        ORA #$10
C2/8C85: 85 59        STA $59
C2/8C87: A9 01        LDA #$01
C2/8C89: 8D D7 3E     STA $3ED7       ; default timer duration
C2/8C8C: 20 2E 8D     JSR $8D2E
C2/8C8F: 64 59        STZ $59
C2/8C91: A6 32        LDX $32
C2/8C93: BD 6E 20     LDA $206E,X
C2/8C96: 29 02        AND #$02
C2/8C98: F0 0C        BEQ $8CA6
C2/8C9A: A9 08        LDA #$08
C2/8C9C: 85 59        STA $59
C2/8C9E: A9 01        LDA #$01
C2/8CA0: 8D D7 3E     STA $3ED7       ; default timer duration
C2/8CA3: 20 05 8E     JSR $8E05
C2/8CA6: 9C D7 3E     STZ $3ED7       ; custom timer duration
C2/8CA9: 64 56        STZ $56
C2/8CAB: 60           RTS 

; [  ]

C2/8CAC: A6 49        LDX $49
C2/8CAE: BD 35 20     LDA $2035,X
C2/8CB1: 25 59        AND $59
C2/8CB3: D0 76        BNE $8D2B
C2/8CB5: A5 48        LDA $48
C2/8CB7: C9 04        CMP #$04
C2/8CB9: B0 46        BCS $8D01
C2/8CBB: A5 59        LDA $59
C2/8CBD: 29 02        AND #$02
C2/8CBF: F0 40        BEQ $8D01
C2/8CC1: BD 1A 20     LDA $201A,X
C2/8CC4: 1D 70 20     ORA $2070,X
C2/8CC7: 29 42        AND #$42
C2/8CC9: D0 60        BNE $8D2B
C2/8CCB: A6 32        LDX $32
C2/8CCD: DA           PHX 
C2/8CCE: A5 48        LDA $48
C2/8CD0: 20 82 24     JSR $2482
C2/8CD3: A6 32        LDX $32
C2/8CD5: A9 80        LDA #$80
C2/8CD7: 9D 56 20     STA $2056,X
C2/8CDA: 9E 57 20     STZ $2057,X
C2/8CDD: A5 48        LDA $48
C2/8CDF: AA           TAX 
C2/8CE0: B9 7F 3D     LDA $3D7F,Y
C2/8CE3: C9 7F        CMP #$7F
C2/8CE5: 90 02        BCC $8CE9
C2/8CE7: A9 7F        LDA #$7F
C2/8CE9: 9D 04 7C     STA $7C04,X
C2/8CEC: 7B           TDC 
C2/8CED: 99 FB 3C     STA $3CFB,Y
C2/8CF0: 1A           INC 
C2/8CF1: 99 7F 3D     STA $3D7F,Y
C2/8CF4: A6 49        LDX $49
C2/8CF6: 9E 06 20     STZ $2006,X
C2/8CF9: 9E 07 20     STZ $2007,X
C2/8CFC: FA           PLX 
C2/8CFD: 86 32        STX $32
C2/8CFF: 80 16        BRA $8D17
C2/8D01: A5 48        LDA $48
C2/8D03: C9 04        CMP #$04
C2/8D05: 90 10        BCC $8D17
C2/8D07: A5 59        LDA $59
C2/8D09: 29 40        AND #$40
C2/8D0B: F0 0A        BEQ $8D17
C2/8D0D: BD 1A 20     LDA $201A,X
C2/8D10: 09 80        ORA #$80
C2/8D12: 9D 1A 20     STA $201A,X
C2/8D15: 80 11        BRA $8D28
C2/8D17: A6 49        LDX $49
C2/8D19: BD 1A 20     LDA $201A,X
C2/8D1C: 29 02        AND #$02
C2/8D1E: D0 0B        BNE $8D2B
C2/8D20: BD 1A 20     LDA $201A,X
C2/8D23: 05 59        ORA $59
C2/8D25: 9D 1A 20     STA $201A,X
C2/8D28: 4C A5 92     JMP $92A5
C2/8D2B: E6 56        INC $56         ; miss
C2/8D2D: 60           RTS 

; [  ]

C2/8D2E: A6 49        LDX $49
C2/8D30: BD 36 20     LDA $2036,X
C2/8D33: 25 59        AND $59
C2/8D35: F0 03        BEQ $8D3A
C2/8D37: 4C C8 8D     JMP $8DC8
C2/8D3A: A5 59        LDA $59
C2/8D3C: 29 10        AND #$10
C2/8D3E: D0 19        BNE $8D59
C2/8D40: A5 59        LDA $59
C2/8D42: 29 08        AND #$08
C2/8D44: F0 58        BEQ $8D9E
C2/8D46: BD 1B 20     LDA $201B,X
C2/8D49: 1D 71 20     ORA $2071,X
C2/8D4C: 29 18        AND #$18
C2/8D4E: D0 78        BNE $8DC8
C2/8D50: BD 1D 20     LDA $201D,X
C2/8D53: 29 20        AND #$20
C2/8D55: D0 71        BNE $8DC8
C2/8D57: 80 11        BRA $8D6A
C2/8D59: BD 1B 20     LDA $201B,X
C2/8D5C: 1D 71 20     ORA $2071,X
C2/8D5F: 29 18        AND #$18
C2/8D61: D0 65        BNE $8DC8
C2/8D63: BD 1D 20     LDA $201D,X
C2/8D66: 29 20        AND #$20
C2/8D68: D0 5E        BNE $8DC8
C2/8D6A: A5 48        LDA $48
C2/8D6C: C9 04        CMP #$04
C2/8D6E: B0 2E        BCS $8D9E
C2/8D70: A6 32        LDX $32
C2/8D72: DA           PHX 
C2/8D73: A5 48        LDA $48
C2/8D75: 20 82 24     JSR $2482
C2/8D78: A6 32        LDX $32
C2/8D7A: A9 80        LDA #$80
C2/8D7C: 9D 56 20     STA $2056,X
C2/8D7F: 9E 57 20     STZ $2057,X
C2/8D82: A5 48        LDA $48
C2/8D84: AA           TAX 
C2/8D85: B9 7F 3D     LDA $3D7F,Y
C2/8D88: C9 7F        CMP #$7F
C2/8D8A: 90 02        BCC $8D8E
C2/8D8C: A9 7F        LDA #$7F
C2/8D8E: 9D 04 7C     STA $7C04,X
C2/8D91: 7B           TDC 
C2/8D92: 99 FB 3C     STA $3CFB,Y
C2/8D95: 1A           INC 
C2/8D96: 99 7F 3D     STA $3D7F,Y
C2/8D99: FA           PLX 
C2/8D9A: 86 32        STX $32
C2/8D9C: 80 1D        BRA $8DBB
C2/8D9E: A5 59        LDA $59
C2/8DA0: 29 20        AND #$20
C2/8DA2: F0 17        BEQ $8DBB
C2/8DA4: BD 1B 20     LDA $201B,X
C2/8DA7: 1D 71 20     ORA $2071,X
C2/8DAA: 29 20        AND #$20
C2/8DAC: D0 1A        BNE $8DC8
C2/8DAE: A5 48        LDA $48
C2/8DB0: 20 07 02     JSR $0207       ; get timer data offset
C2/8DB3: 7B           TDC 
C2/8DB4: 99 FB 3C     STA $3CFB,Y
C2/8DB7: 1A           INC 
C2/8DB8: 99 7F 3D     STA $3D7F,Y
C2/8DBB: A6 49        LDX $49
C2/8DBD: BD 1B 20     LDA $201B,X
C2/8DC0: 05 59        ORA $59
C2/8DC2: 9D 1B 20     STA $201B,X
C2/8DC5: 4C 28 93     JMP $9328
C2/8DC8: E6 56        INC $56         ; miss
C2/8DCA: 60           RTS 

; [  ]

C2/8DCB: A6 49        LDX $49
C2/8DCD: BD 37 20     LDA $2037,X
C2/8DD0: 25 59        AND $59
C2/8DD2: D0 2E        BNE $8E02
C2/8DD4: A5 59        LDA $59
C2/8DD6: 29 10        AND #$10
C2/8DD8: F0 1B        BEQ $8DF5
C2/8DDA: BD 1B 20     LDA $201B,X
C2/8DDD: 1D 71 20     ORA $2071,X
C2/8DE0: 29 10        AND #$10
C2/8DE2: D0 1E        BNE $8E02
C2/8DE4: A5 48        LDA $48
C2/8DE6: 20 07 02     JSR $0207       ; get timer data offset
C2/8DE9: B9 FB 3C     LDA $3CFB,Y
C2/8DEC: 29 40        AND #$40
C2/8DEE: D0 05        BNE $8DF5
C2/8DF0: A9 01        LDA #$01
C2/8DF2: 99 FB 3C     STA $3CFB,Y
C2/8DF5: A6 49        LDX $49
C2/8DF7: BD 1C 20     LDA $201C,X
C2/8DFA: 05 59        ORA $59
C2/8DFC: 9D 1C 20     STA $201C,X
C2/8DFF: 4C 4D 93     JMP $934D
C2/8E02: E6 56        INC $56         ; miss
C2/8E04: 60           RTS 

; [  ]

C2/8E05: A6 49        LDX $49
C2/8E07: A5 59        LDA $59
C2/8E09: 29 10        AND #$10
C2/8E0B: F0 0A        BEQ $8E17
C2/8E0D: BD 1D 20     LDA $201D,X
C2/8E10: 1D 73 20     ORA $2073,X
C2/8E13: 25 59        AND $59
C2/8E15: D0 0B        BNE $8E22
C2/8E17: BD 1D 20     LDA $201D,X
C2/8E1A: 05 59        ORA $59
C2/8E1C: 9D 1D 20     STA $201D,X
C2/8E1F: 4C 72 93     JMP $9372
C2/8E22: E6 56        INC $56         ; miss
C2/8E24: 60           RTS 

; [  ]

C2/8E25: A6 49        LDX $49
C2/8E27: BD 35 20     LDA $2035,X
C2/8E2A: 25 59        AND $59
C2/8E2C: D0 09        BNE $8E37
C2/8E2E: BD 1A 20     LDA $201A,X
C2/8E31: 45 59        EOR $59
C2/8E33: 9D 1A 20     STA $201A,X
C2/8E36: 60           RTS 
C2/8E37: E6 56        INC $56         ; miss
C2/8E39: 60           RTS 

; [  ]

C2/8E3A: A6 49        LDX $49
C2/8E3C: BD 65 20     LDA $2065,X
C2/8E3F: 29 20        AND #$20
C2/8E41: F0 03        BEQ $8E46
C2/8E43: E6 56        INC $56         ; miss
C2/8E45: 60           RTS 
C2/8E46: A6 49        LDX $49
C2/8E48: BD 1E 20     LDA $201E,X
C2/8E4B: 09 08        ORA #$08
C2/8E4D: 9D 1E 20     STA $201E,X
C2/8E50: 60           RTS 

; [  ]

C2/8E51: A6 49        LDX $49
C2/8E53: BD 37 20     LDA $2037,X
C2/8E56: 25 59        AND $59
C2/8E58: D0 59        BNE $8EB3
C2/8E5A: BD 1C 20     LDA $201C,X
C2/8E5D: 85 0E        STA $0E
C2/8E5F: 25 58        AND $58
C2/8E61: 05 59        ORA $59
C2/8E63: 9D 1C 20     STA $201C,X
C2/8E66: A5 48        LDA $48
C2/8E68: 20 07 02     JSR $0207       ; get timer data offset
C2/8E6B: BD 1C 20     LDA $201C,X
C2/8E6E: 29 04        AND #$04
C2/8E70: F0 1E        BEQ $8E90
C2/8E72: A5 0E        LDA $0E
C2/8E74: 29 04        AND #$04
C2/8E76: D0 18        BNE $8E90
C2/8E78: 7B           TDC 
C2/8E79: AA           TAX 
C2/8E7A: B9 75 3D     LDA $3D75,Y
C2/8E7D: F0 08        BEQ $8E87
C2/8E7F: 0A           ASL 
C2/8E80: 90 02        BCC $8E84
C2/8E82: A9 FF        LDA #$FF
C2/8E84: 99 75 3D     STA $3D75,Y
C2/8E87: C8           INY 
C2/8E88: E8           INX 
C2/8E89: E0 0B 00     CPX #$000B
C2/8E8C: D0 EC        BNE $8E7A
C2/8E8E: 80 22        BRA $8EB2
C2/8E90: BD 1C 20     LDA $201C,X
C2/8E93: 29 08        AND #$08
C2/8E95: F0 1B        BEQ $8EB2
C2/8E97: A5 0E        LDA $0E
C2/8E99: 29 08        AND #$08
C2/8E9B: D0 15        BNE $8EB2
C2/8E9D: 7B           TDC 
C2/8E9E: AA           TAX 
C2/8E9F: B9 75 3D     LDA $3D75,Y
C2/8EA2: F0 07        BEQ $8EAB
C2/8EA4: 4A           LSR 
C2/8EA5: D0 01        BNE $8EA8
C2/8EA7: 1A           INC 
C2/8EA8: 99 75 3D     STA $3D75,Y
C2/8EAB: C8           INY 
C2/8EAC: E8           INX 
C2/8EAD: E0 0B 00     CPX #$000B
C2/8EB0: D0 ED        BNE $8E9F
C2/8EB2: 60           RTS 
C2/8EB3: E6 56        INC $56         ; miss
C2/8EB5: 60           RTS 

; [  ]

C2/8EB6: A5 59        LDA $59
C2/8EB8: 49 FF        EOR #$FF
C2/8EBA: 29 02        AND #$02
C2/8EBC: F0 16        BEQ $8ED4
C2/8EBE: A6 49        LDX $49
C2/8EC0: BD 1A 20     LDA $201A,X
C2/8EC3: 29 02        AND #$02
C2/8EC5: F0 0D        BEQ $8ED4
C2/8EC7: A6 32        LDX $32
C2/8EC9: DA           PHX 
C2/8ECA: A5 48        LDA $48
C2/8ECC: 20 82 24     JSR $2482
C2/8ECF: FA           PLX 
C2/8ED0: 86 32        STX $32
C2/8ED2: 80 11        BRA $8EE5
C2/8ED4: A5 59        LDA $59
C2/8ED6: 49 FF        EOR #$FF
C2/8ED8: 29 40        AND #$40
C2/8EDA: F0 09        BEQ $8EE5
C2/8EDC: A6 49        LDX $49
C2/8EDE: BD 1A 20     LDA $201A,X
C2/8EE1: 29 40        AND #$40
C2/8EE3: D0 E2        BNE $8EC7
C2/8EE5: A6 49        LDX $49
C2/8EE7: BD 1A 20     LDA $201A,X
C2/8EEA: 85 0E        STA $0E
C2/8EEC: 25 59        AND $59
C2/8EEE: 9D 1A 20     STA $201A,X
C2/8EF1: A5 59        LDA $59
C2/8EF3: 85 0F        STA $0F
C2/8EF5: 49 FF        EOR #$FF
C2/8EF7: 85 59        STA $59
C2/8EF9: 20 B4 92     JSR $92B4
C2/8EFC: A5 0E        LDA $0E
C2/8EFE: 29 40        AND #$40
C2/8F00: 85 0E        STA $0E
C2/8F02: A5 0F        LDA $0F
C2/8F04: 49 FF        EOR #$FF
C2/8F06: 25 0E        AND $0E
C2/8F08: F0 06        BEQ $8F10
C2/8F0A: A5 48        LDA $48
C2/8F0C: AA           TAX 
C2/8F0D: FE C2 3E     INC $3EC2,X
C2/8F10: 60           RTS 

; [  ]

C2/8F11: A6 49        LDX $49
C2/8F13: A5 59        LDA $59
C2/8F15: 49 FF        EOR #$FF
C2/8F17: 29 10        AND #$10
C2/8F19: F0 07        BEQ $8F22
C2/8F1B: BD 1B 20     LDA $201B,X
C2/8F1E: 29 10        AND #$10
C2/8F20: D0 2D        BNE $8F4F
C2/8F22: A5 59        LDA $59
C2/8F24: 49 FF        EOR #$FF
C2/8F26: 29 08        AND #$08
C2/8F28: F0 07        BEQ $8F31
C2/8F2A: BD 1B 20     LDA $201B,X
C2/8F2D: 29 18        AND #$18
C2/8F2F: D0 1E        BNE $8F4F
C2/8F31: A5 59        LDA $59
C2/8F33: 49 FF        EOR #$FF
C2/8F35: 29 20        AND #$20
C2/8F37: F0 07        BEQ $8F40
C2/8F39: BD 1B 20     LDA $201B,X
C2/8F3C: 29 20        AND #$20
C2/8F3E: D0 0F        BNE $8F4F
C2/8F40: A5 59        LDA $59
C2/8F42: 49 FF        EOR #$FF
C2/8F44: 29 40        AND #$40
C2/8F46: F0 12        BEQ $8F5A
C2/8F48: BD 1B 20     LDA $201B,X
C2/8F4B: 29 40        AND #$40
C2/8F4D: F0 0B        BEQ $8F5A
C2/8F4F: A6 32        LDX $32
C2/8F51: DA           PHX 
C2/8F52: A5 48        LDA $48
C2/8F54: 20 82 24     JSR $2482
C2/8F57: FA           PLX 
C2/8F58: 86 32        STX $32
C2/8F5A: A6 49        LDX $49
C2/8F5C: BD 1B 20     LDA $201B,X
C2/8F5F: 25 59        AND $59
C2/8F61: 9D 1B 20     STA $201B,X
C2/8F64: A5 59        LDA $59
C2/8F66: 49 FF        EOR #$FF
C2/8F68: 85 59        STA $59
C2/8F6A: 20 C3 92     JSR $92C3
C2/8F6D: 60           RTS 

; [  ]

C2/8F6E: A6 49        LDX $49
C2/8F70: BD 1C 20     LDA $201C,X
C2/8F73: 25 59        AND $59
C2/8F75: 9D 1C 20     STA $201C,X
C2/8F78: A5 59        LDA $59
C2/8F7A: 49 FF        EOR #$FF
C2/8F7C: 85 59        STA $59
C2/8F7E: 20 EE 92     JSR $92EE
C2/8F81: 60           RTS 

; [  ]

C2/8F82: A6 49        LDX $49
C2/8F84: BD 65 20     LDA $2065,X
C2/8F87: 29 20        AND #$20
C2/8F89: F0 03        BEQ $8F8E
C2/8F8B: E6 56        INC $56         ; miss
C2/8F8D: 60           RTS 
C2/8F8E: 20 81 7E     JSR $7E81
C2/8F91: A5 56        LDA $56
C2/8F93: D0 14        BNE $8FA9
C2/8F95: A6 49        LDX $49
C2/8F97: BD 1A 20     LDA $201A,X
C2/8F9A: 29 02        AND #$02
C2/8F9C: D0 09        BNE $8FA7
C2/8F9E: BD 1A 20     LDA $201A,X
C2/8FA1: 09 80        ORA #$80
C2/8FA3: 9D 1A 20     STA $201A,X
C2/8FA6: 60           RTS 
C2/8FA7: E6 56        INC $56         ; miss
C2/8FA9: 60           RTS 

; [  ]

C2/8FAA: A5 48        LDA $48
C2/8FAC: C9 04        CMP #$04
C2/8FAE: 90 0F        BCC $8FBF
C2/8FB0: 38           SEC 
C2/8FB1: E9 04        SBC #$04
C2/8FB3: AA           TAX 
C2/8FB4: AD 0A 7C     LDA $7C0A
C2/8FB7: 20 DB 01     JSR $01DB       ; check bit x
C2/8FBA: F0 03        BEQ $8FBF
C2/8FBC: E6 56        INC $56         ; miss
C2/8FBE: 60           RTS 
C2/8FBF: A6 49        LDX $49
C2/8FC1: BD 1A 20     LDA $201A,X
C2/8FC4: 29 02        AND #$02
C2/8FC6: D0 F4        BNE $8FBC
C2/8FC8: BD 1A 20     LDA $201A,X
C2/8FCB: 29 7F        AND #$7F
C2/8FCD: 9D 1A 20     STA $201A,X
C2/8FD0: A5 59        LDA $59
C2/8FD2: AA           TAX 
C2/8FD3: 86 2C        STX $2C
C2/8FD5: A6 49        LDX $49
C2/8FD7: BD 08 20     LDA $2008,X
C2/8FDA: 85 2A        STA $2A
C2/8FDC: BD 09 20     LDA $2009,X
C2/8FDF: 85 2B        STA $2B
C2/8FE1: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/8FE4: C2 20        REP #$20
C2/8FE6: 46 30        LSR $30
C2/8FE8: 66 2E        ROR $2E
C2/8FEA: 46 30        LSR $30
C2/8FEC: 66 2E        ROR $2E
C2/8FEE: 46 30        LSR $30
C2/8FF0: 66 2E        ROR $2E
C2/8FF2: 46 30        LSR $30
C2/8FF4: 66 2E        ROR $2E
C2/8FF6: A5 30        LDA $30
C2/8FF8: D0 07        BNE $9001
C2/8FFA: A5 2E        LDA $2E
C2/8FFC: C9 0F 27     CMP #$270F
C2/8FFF: 90 05        BCC $9006
C2/9001: A9 0F 27     LDA #$270F
C2/9004: 85 2E        STA $2E
C2/9006: A5 2E        LDA $2E
C2/9008: D0 02        BNE $900C
C2/900A: E6 2E        INC $2E
C2/900C: A6 49        LDX $49
C2/900E: 18           CLC 
C2/900F: BD 06 20     LDA $2006,X
C2/9012: 65 2E        ADC $2E
C2/9014: B0 05        BCS $901B
C2/9016: DD 08 20     CMP $2008,X
C2/9019: 90 03        BCC $901E
C2/901B: BD 08 20     LDA $2008,X
C2/901E: 9D 06 20     STA $2006,X
C2/9021: 7B           TDC 
C2/9022: E2 20        SEP #$20
C2/9024: A5 48        LDA $48
C2/9026: AA           TAX 
C2/9027: FE C2 3E     INC $3EC2,X
C2/902A: 60           RTS 

; [  ]

C2/902B: A6 49        LDX $49
C2/902D: BD 1A 20     LDA $201A,X
C2/9030: 05 59        ORA $59
C2/9032: 9D 1A 20     STA $201A,X
C2/9035: 20 A5 92     JSR $92A5
C2/9038: 60           RTS 

; [  ]

C2/9039: A6 49        LDX $49
C2/903B: A5 59        LDA $59
C2/903D: 29 10        AND #$10
C2/903F: D0 19        BNE $905A
C2/9041: A5 59        LDA $59
C2/9043: 29 08        AND #$08
C2/9045: F0 58        BEQ $909F
C2/9047: BD 1B 20     LDA $201B,X
C2/904A: 1D 71 20     ORA $2071,X
C2/904D: 29 18        AND #$18
C2/904F: D0 78        BNE $90C9
C2/9051: BD 1D 20     LDA $201D,X
C2/9054: 29 20        AND #$20
C2/9056: D0 71        BNE $90C9
C2/9058: 80 11        BRA $906B
C2/905A: BD 1B 20     LDA $201B,X
C2/905D: 1D 71 20     ORA $2071,X
C2/9060: 29 18        AND #$18
C2/9062: D0 65        BNE $90C9
C2/9064: BD 1D 20     LDA $201D,X
C2/9067: 29 20        AND #$20
C2/9069: D0 5E        BNE $90C9
C2/906B: A5 48        LDA $48
C2/906D: C9 04        CMP #$04
C2/906F: B0 2E        BCS $909F
C2/9071: A6 32        LDX $32
C2/9073: DA           PHX 
C2/9074: A5 48        LDA $48
C2/9076: 20 82 24     JSR $2482
C2/9079: A6 32        LDX $32
C2/907B: A9 80        LDA #$80
C2/907D: 9D 56 20     STA $2056,X
C2/9080: 9E 57 20     STZ $2057,X
C2/9083: A5 48        LDA $48
C2/9085: AA           TAX 
C2/9086: B9 7F 3D     LDA $3D7F,Y
C2/9089: C9 7F        CMP #$7F
C2/908B: 90 02        BCC $908F
C2/908D: A9 7F        LDA #$7F
C2/908F: 9D 04 7C     STA $7C04,X
C2/9092: 7B           TDC 
C2/9093: 99 FB 3C     STA $3CFB,Y
C2/9096: 1A           INC 
C2/9097: 99 7F 3D     STA $3D7F,Y
C2/909A: FA           PLX 
C2/909B: 86 32        STX $32
C2/909D: 80 1D        BRA $90BC
C2/909F: A5 59        LDA $59
C2/90A1: 29 20        AND #$20
C2/90A3: F0 17        BEQ $90BC
C2/90A5: BD 1B 20     LDA $201B,X
C2/90A8: 1D 71 20     ORA $2071,X
C2/90AB: 29 20        AND #$20
C2/90AD: D0 1A        BNE $90C9
C2/90AF: A5 48        LDA $48
C2/90B1: 20 07 02     JSR $0207       ; get timer data offset
C2/90B4: 7B           TDC 
C2/90B5: 99 FB 3C     STA $3CFB,Y
C2/90B8: 1A           INC 
C2/90B9: 99 7F 3D     STA $3D7F,Y
C2/90BC: A6 49        LDX $49
C2/90BE: BD 1B 20     LDA $201B,X
C2/90C1: 05 59        ORA $59
C2/90C3: 9D 1B 20     STA $201B,X
C2/90C6: 4C 28 93     JMP $9328
C2/90C9: EE 56 00     INC $0056
C2/90CC: 60           RTS 

; [  ]

C2/90CD: A6 49        LDX $49
C2/90CF: BD 1C 20     LDA $201C,X
C2/90D2: 05 59        ORA $59
C2/90D4: 9D 1C 20     STA $201C,X
C2/90D7: 20 4D 93     JSR $934D
C2/90DA: 60           RTS 

; [  ]

C2/90DB: A6 32        LDX $32
C2/90DD: BD 1A 20     LDA $201A,X
C2/90E0: 05 59        ORA $59
C2/90E2: 9D 1A 20     STA $201A,X
C2/90E5: 20 A5 92     JSR $92A5
C2/90E8: 60           RTS 

; [  ]

C2/90E9: A6 49        LDX $49
C2/90EB: 9E 50 20     STZ $2050,X
C2/90EE: 9E 51 20     STZ $2051,X
C2/90F1: 9E 52 20     STZ $2052,X
C2/90F4: 9E 53 20     STZ $2053,X
C2/90F7: 9E 54 20     STZ $2054,X
C2/90FA: 9E 55 20     STZ $2055,X
C2/90FD: 9E 7A 20     STZ $207A,X
C2/9100: 60           RTS 

; [  ]

C2/9101: A6 49        LDX $49
C2/9103: BD 00 20     LDA $2000,X
C2/9106: 29 80        AND #$80
C2/9108: 49 80        EOR #$80
C2/910A: 85 0E        STA $0E
C2/910C: BD 00 20     LDA $2000,X
C2/910F: 29 7F        AND #$7F
C2/9111: 05 0E        ORA $0E
C2/9113: 9D 00 20     STA $2000,X
C2/9116: 60           RTS 

; [  ]

C2/9117: A6 49        LDX $49
C2/9119: BD 00 20     LDA $2000,X
C2/911C: 29 7F        AND #$7F
C2/911E: 9D 00 20     STA $2000,X
C2/9121: 60           RTS 

; [  ]

C2/9122: A6 32        LDX $32
C2/9124: BD 00 20     LDA $2000,X
C2/9127: 09 80        ORA #$80
C2/9129: 9D 00 20     STA $2000,X
C2/912C: 60           RTS 

; [  ]

C2/912D: A6 49        LDX $49
C2/912F: 5E 2D 20     LSR $202D,X
C2/9132: 5E 2F 20     LSR $202F,X
C2/9135: 60           RTS 

; [  ]

C2/9136: A6 49        LDX $49
C2/9138: BD 02 20     LDA $2002,X
C2/913B: 4A           LSR 
C2/913C: D0 01        BNE $913F
C2/913E: 1A           INC 
C2/913F: 9D 02 20     STA $2002,X
C2/9142: 60           RTS 

; [  ]

C2/9143: A6 49        LDX $49
C2/9145: 18           CLC 
C2/9146: BD 02 20     LDA $2002,X
C2/9149: 65 59        ADC $59
C2/914B: 90 02        BCC $914F
C2/914D: A9 FF        LDA #$FF
C2/914F: 9D 02 20     STA $2002,X
C2/9152: 60           RTS 

; [  ]

C2/9153: A6 49        LDX $49
C2/9155: 38           SEC 
C2/9156: BD 02 20     LDA $2002,X
C2/9159: E5 59        SBC $59
C2/915B: B0 02        BCS $915F
C2/915D: A9 01        LDA #$01
C2/915F: 9D 02 20     STA $2002,X
C2/9162: 60           RTS 

; [ increase max hp ]

; giant's drink effect

C2/9163: A5 48        LDA $48
C2/9165: C9 04        CMP #$04
C2/9167: 90 03        BCC $916C       ; always miss monsters
C2/9169: E6 56        INC $56         ; miss
C2/916B: 60           RTS 
C2/916C: 0A           ASL 
C2/916D: A8           TAY 
C2/916E: C2 20        REP #$20
C2/9170: A6 49        LDX $49
C2/9172: BD 08 20     LDA $2008,X     ; save max hp
C2/9175: 99 11 7C     STA $7C11,Y
C2/9178: 0A           ASL             ; double max hp (max 9999)
C2/9179: C9 0F 27     CMP #$270F
C2/917C: 90 03        BCC $9181
C2/917E: A9 0F 27     LDA #$270F
C2/9181: 9D 08 20     STA $2008,X
C2/9184: BD 06 20     LDA $2006,X     ; double current hp (max 9999)
C2/9187: 0A           ASL 
C2/9188: C9 0F 27     CMP #$270F
C2/918B: 90 03        BCC $9190
C2/918D: A9 0F 27     LDA #$270F
C2/9190: 9D 06 20     STA $2006,X
C2/9193: 7B           TDC 
C2/9194: E2 20        SEP #$20
C2/9196: 60           RTS 

; [  ]

C2/9197: A6 49        LDX $49
C2/9199: 18           CLC 
C2/919A: BD 44 20     LDA $2044,X
C2/919D: 65 59        ADC $59
C2/919F: 90 02        BCC $91A3
C2/91A1: A9 FF        LDA #$FF
C2/91A3: 9D 44 20     STA $2044,X
C2/91A6: 18           CLC 
C2/91A7: BD 45 20     LDA $2045,X
C2/91AA: 65 59        ADC $59
C2/91AC: 90 02        BCC $91B0
C2/91AE: A9 FF        LDA #$FF
C2/91B0: 9D 45 20     STA $2045,X
C2/91B3: 60           RTS 

; [  ]

C2/91B4: A6 49        LDX $49
C2/91B6: 18           CLC 
C2/91B7: BD 2D 20     LDA $202D,X
C2/91BA: 65 59        ADC $59
C2/91BC: 90 02        BCC $91C0
C2/91BE: A9 FF        LDA #$FF
C2/91C0: 9D 2D 20     STA $202D,X
C2/91C3: 18           CLC 
C2/91C4: BD 2F 20     LDA $202F,X
C2/91C7: 65 59        ADC $59
C2/91C9: 90 02        BCC $91CD
C2/91CB: A9 FF        LDA #$FF
C2/91CD: 9D 2F 20     STA $202F,X
C2/91D0: 60           RTS 

; [  ]

C2/91D1: A6 49        LDX $49
C2/91D3: BD 1D 20     LDA $201D,X
C2/91D6: 45 59        EOR $59
C2/91D8: 9D 1D 20     STA $201D,X
C2/91DB: 60           RTS 

; [  ]

C2/91DC: A6 32        LDX $32
C2/91DE: BD 79 20     LDA $2079,X
C2/91E1: 05 59        ORA $59
C2/91E3: 9D 79 20     STA $2079,X
C2/91E6: 60           RTS 

; [  ]

C2/91E7: A6 49        LDX $49
C2/91E9: BD 65 20     LDA $2065,X
C2/91EC: 05 59        ORA $59
C2/91EE: 9D 65 20     STA $2065,X
C2/91F1: 60           RTS 

; [  ]

C2/91F2: A6 49        LDX $49
C2/91F4: BD 35 20     LDA $2035,X
C2/91F7: 05 59        ORA $59
C2/91F9: 9D 35 20     STA $2035,X
C2/91FC: 60           RTS 

; [  ]

C2/91FD: A6 49        LDX $49
C2/91FF: BD 22 20     LDA $2022,X
C2/9202: 05 59        ORA $59
C2/9204: 9D 22 20     STA $2022,X
C2/9207: 60           RTS 

; [  ]

C2/9208: A5 48        LDA $48
C2/920A: C9 04        CMP #$04
C2/920C: B0 03        BCS $9211
C2/920E: 4C A2 92     JMP $92A2
C2/9211: 7B           TDC 
C2/9212: AA           TAX 
C2/9213: A9 FF        LDA #$FF
C2/9215: 20 7C 00     JSR $007C       ; a = (x..a)
C2/9218: 85 0E        STA $0E
C2/921A: 38           SEC 
C2/921B: A5 48        LDA $48
C2/921D: E9 04        SBC #$04
C2/921F: 0A           ASL 
C2/9220: AA           TAX 
C2/9221: C2 20        REP #$20
C2/9223: BD 20 40     LDA $4020,X
C2/9226: 20 B7 01     JSR $01B7       ; a << 2
C2/9229: AA           TAX 
C2/922A: 7B           TDC 
C2/922B: E2 20        SEP #$20
C2/922D: A5 0E        LDA $0E
C2/922F: C9 0A        CMP #$0A
C2/9231: 90 01        BCC $9234
C2/9233: E8           INX 
C2/9234: BF 00 50 D0  LDA $D05000,X
C2/9238: F0 68        BEQ $92A2
C2/923A: 85 0E        STA $0E
C2/923C: A0 FF 00     LDY #$00FF
C2/923F: B9 34 27     LDA $2734,Y
C2/9242: C5 0E        CMP $0E
C2/9244: F0 12        BEQ $9258
C2/9246: 88           DEY 
C2/9247: 10 F6        BPL $923F
C2/9249: 7B           TDC 
C2/924A: A8           TAY 
C2/924B: B9 34 27     LDA $2734,Y
C2/924E: F0 08        BEQ $9258
C2/9250: C8           INY 
C2/9251: C0 00 01     CPY #$0100
C2/9254: D0 F5        BNE $924B
C2/9256: 80 4A        BRA $92A2
C2/9258: A5 0E        LDA $0E
C2/925A: 99 34 27     STA $2734,Y
C2/925D: B9 20 26     LDA $2620,Y
C2/9260: 48           PHA 
C2/9261: 5A           PHY 
C2/9262: A5 0E        LDA $0E
C2/9264: 20 FA 03     JSR $03FA
C2/9267: 20 69 03     JSR $0369
C2/926A: 7A           PLY 
C2/926B: 99 34 2C     STA $2C34,Y
C2/926E: 68           PLA 
C2/926F: 99 20 26     STA $2620,Y
C2/9272: 18           CLC 
C2/9273: B9 34 28     LDA $2834,Y
C2/9276: 1A           INC 
C2/9277: C9 64        CMP #$64
C2/9279: 90 02        BCC $927D
C2/927B: A9 63        LDA #$63
C2/927D: 99 34 28     STA $2834,Y
C2/9280: A6 49        LDX $49
C2/9282: B9 34 27     LDA $2734,Y
C2/9285: 9D 6B 20     STA $206B,X
C2/9288: 5A           PHY 
C2/9289: 20 65 99     JSR $9965
C2/928C: BB           TYX 
C2/928D: 7A           PLY 
C2/928E: AD 46 47     LDA $4746
C2/9291: C9 0B        CMP #$0B
C2/9293: F0 04        BEQ $9299
C2/9295: C9 33        CMP #$33
C2/9297: D0 02        BNE $929B
C2/9299: 7B           TDC 
C2/929A: AA           TAX 
C2/929B: B9 34 27     LDA $2734,Y
C2/929E: 9D BF 3C     STA $3CBF,X
C2/92A1: 60           RTS 
C2/92A2: E6 56        INC $56         ; miss
C2/92A4: 60           RTS 

; [  ]

C2/92A5: A5 59        LDA $59
C2/92A7: 29 04        AND #$04
C2/92A9: F0 08        BEQ $92B3
C2/92AB: A9 01        LDA #$01
C2/92AD: AA           TAX 
C2/92AE: A5 48        LDA $48
C2/92B0: 20 FD 24     JSR $24FD       ; start timer
C2/92B3: 60           RTS 

; [  ]

C2/92B4: A5 59        LDA $59
C2/92B6: 29 04        AND #$04
C2/92B8: F0 08        BEQ $92C2
C2/92BA: A9 01        LDA #$01
C2/92BC: AA           TAX 
C2/92BD: A5 48        LDA $48
C2/92BF: 20 F0 24     JSR $24F0       ; stop timer
C2/92C2: 60           RTS 

; [  ]

C2/92C3: A5 59        LDA $59
C2/92C5: 29 80        AND #$80
C2/92C7: F0 08        BEQ $92D1
C2/92C9: A9 06        LDA #$06
C2/92CB: AA           TAX 
C2/92CC: A5 48        LDA $48
C2/92CE: 20 F0 24     JSR $24F0       ; stop timer
C2/92D1: A5 59        LDA $59
C2/92D3: 29 20        AND #$20
C2/92D5: F0 08        BEQ $92DF
C2/92D7: A9 09        LDA #$09
C2/92D9: AA           TAX 
C2/92DA: A5 48        LDA $48
C2/92DC: 20 F0 24     JSR $24F0       ; stop timer
C2/92DF: A5 59        LDA $59
C2/92E1: 29 04        AND #$04
C2/92E3: F0 08        BEQ $92ED
C2/92E5: A9 04        LDA #$04
C2/92E7: AA           TAX 
C2/92E8: A5 48        LDA $48
C2/92EA: 20 F0 24     JSR $24F0       ; stop timer
C2/92ED: 60           RTS 

; [  ]

C2/92EE: A5 59        LDA $59
C2/92F0: 29 80        AND #$80
C2/92F2: F0 08        BEQ $92FC
C2/92F4: A9 02        LDA #$02
C2/92F6: AA           TAX 
C2/92F7: A5 48        LDA $48
C2/92F9: 20 F0 24     JSR $24F0       ; stop timer
C2/92FC: A5 59        LDA $59
C2/92FE: 29 10        AND #$10
C2/9300: F0 08        BEQ $930A
C2/9302: A9 00        LDA #$00
C2/9304: AA           TAX 
C2/9305: A5 48        LDA $48
C2/9307: 20 F0 24     JSR $24F0       ; stop timer
C2/930A: A5 59        LDA $59
C2/930C: 29 01        AND #$01
C2/930E: F0 08        BEQ $9318
C2/9310: A9 07        LDA #$07
C2/9312: AA           TAX 
C2/9313: A5 48        LDA $48
C2/9315: 20 F0 24     JSR $24F0       ; stop timer
C2/9318: 60           RTS 

; [  ]

C2/9319: A5 59        LDA $59
C2/931B: 29 08        AND #$08
C2/931D: F0 08        BEQ $9327
C2/931F: A9 05        LDA #$05
C2/9321: AA           TAX 
C2/9322: A5 48        LDA $48
C2/9324: 20 F0 24     JSR $24F0       ; stop timer
C2/9327: 60           RTS 

; [  ]

C2/9328: A5 59        LDA $59
C2/932A: 29 80        AND #$80
C2/932C: F0 05        BEQ $9333
C2/932E: A9 06        LDA #$06
C2/9330: AA           TAX 
C2/9331: 80 14        BRA $9347
C2/9333: A5 59        LDA $59
C2/9335: 29 20        AND #$20
C2/9337: F0 05        BEQ $933E
C2/9339: A9 09        LDA #$09
C2/933B: AA           TAX 
C2/933C: 80 09        BRA $9347
C2/933E: A5 59        LDA $59
C2/9340: 29 04        AND #$04
C2/9342: F0 08        BEQ $934C
C2/9344: A9 04        LDA #$04
C2/9346: AA           TAX 
C2/9347: A5 48        LDA $48
C2/9349: 20 FD 24     JSR $24FD       ; start timer
C2/934C: 60           RTS 

; [  ]

C2/934D: A5 59        LDA $59
C2/934F: 29 80        AND #$80
C2/9351: F0 05        BEQ $9358
C2/9353: A9 02        LDA #$02
C2/9355: AA           TAX 
C2/9356: 80 14        BRA $936C
C2/9358: A5 59        LDA $59
C2/935A: 29 10        AND #$10
C2/935C: F0 05        BEQ $9363
C2/935E: A9 00        LDA #$00
C2/9360: AA           TAX 
C2/9361: 80 09        BRA $936C
C2/9363: A5 59        LDA $59
C2/9365: 29 01        AND #$01
C2/9367: F0 08        BEQ $9371
C2/9369: A9 07        LDA #$07
C2/936B: AA           TAX 
C2/936C: A5 48        LDA $48
C2/936E: 20 FD 24     JSR $24FD       ; start timer
C2/9371: 60           RTS 

; [  ]

C2/9372: A5 59        LDA $59
C2/9374: 29 08        AND #$08
C2/9376: F0 08        BEQ $9380
C2/9378: A9 05        LDA #$05
C2/937A: AA           TAX 
C2/937B: A5 48        LDA $48
C2/937D: 4C FD 24     JMP $24FD       ; start timer
C2/9380: A5 59        LDA $59
C2/9382: 29 10        AND #$10
C2/9384: F0 08        BEQ $938E
C2/9386: A9 03        LDA #$03
C2/9388: AA           TAX 
C2/9389: A5 48        LDA $48
C2/938B: 20 FD 24     JSR $24FD       ; start timer
C2/938E: 60           RTS 

; [ decrement image status ]

C2/938F: A6 49        LDX $49
C2/9391: BD 1B 20     LDA $201B,X
C2/9394: 48           PHA 
C2/9395: 29 03        AND #$03
C2/9397: 38           SEC 
C2/9398: E9 01        SBC #$01
C2/939A: 85 0E        STA $0E
C2/939C: 68           PLA 
C2/939D: 29 FC        AND #$FC
C2/939F: 05 0E        ORA $0E
C2/93A1: 9D 1B 20     STA $201B,X
C2/93A4: 60           RTS 

; [  ]

C2/93A5: 38           SEC 
C2/93A6: A5 48        LDA $48
C2/93A8: E9 04        SBC #$04
C2/93AA: AA           TAX 
C2/93AB: 86 0E        STX $0E
C2/93AD: BD F3 3E     LDA $3EF3,X
C2/93B0: A6 32        LDX $32
C2/93B2: 9D 15 20     STA $2015,X
C2/93B5: A5 47        LDA $47
C2/93B7: 85 24        STA $24
C2/93B9: A9 14        LDA #$14
C2/93BB: 85 25        STA $25
C2/93BD: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/93C0: 7B           TDC 
C2/93C1: A8           TAY 
C2/93C2: A6 26        LDX $26
C2/93C4: BD 5C 37     LDA $375C,X
C2/93C7: C9 1D        CMP #$1D
C2/93C9: F0 09        BEQ $93D4
C2/93CB: E8           INX 
C2/93CC: C8           INY 
C2/93CD: C0 04 00     CPY #$0004
C2/93D0: D0 F2        BNE $93C4
C2/93D2: F0 0E        BEQ $93E2
C2/93D4: A9 1E        LDA #$1E
C2/93D6: 9D 5C 37     STA $375C,X
C2/93D9: A9 08        LDA #$08
C2/93DB: 9D 68 37     STA $3768,X
C2/93DE: E8           INX 
C2/93DF: C8           INY 
C2/93E0: 80 E2        BRA $93C4
C2/93E2: A6 49        LDX $49
C2/93E4: BD 1A 20     LDA $201A,X
C2/93E7: 09 80        ORA #$80
C2/93E9: 9D 1A 20     STA $201A,X
C2/93EC: A6 0E        LDX $0E
C2/93EE: AD 0A 7C     LDA $7C0A
C2/93F1: 20 D6 01     JSR $01D6       ; set bit x
C2/93F4: 8D 0A 7C     STA $7C0A
C2/93F7: 60           RTS 

; [ calculate damage ]

; damage = (attack - defense) * multiplier, max 9999

C2/93F8: C2 20        REP #$20
C2/93FA: 38           SEC 
C2/93FB: A5 50        LDA $50         ; attack - defense
C2/93FD: E5 54        SBC $54
C2/93FF: F0 02        BEQ $9403
C2/9401: B0 07        BCS $940A
C2/9403: 7B           TDC 
C2/9404: 8D 69 7B     STA $7B69
C2/9407: E2 20        SEP #$20
C2/9409: 60           RTS 
C2/940A: 85 2A        STA $2A
C2/940C: A5 52        LDA $52         ; damage multiplier
C2/940E: D0 01        BNE $9411
C2/9410: 1A           INC             ; min 1
C2/9411: 85 2C        STA $2C
C2/9413: 7B           TDC 
C2/9414: E2 20        SEP #$20
C2/9416: 20 D2 00     JSR $00D2       ; +++$2E = +$2A * +$2C
C2/9419: A6 2E        LDX $2E
C2/941B: E0 0F 27     CPX #$270F      ; max damage is 9999
C2/941E: 90 03        BCC $9423
C2/9420: A2 0F 27     LDX #$270F
C2/9423: 8E 69 7B     STX $7B69
C2/9426: 60           RTS 

; [  ]

C2/9427: A2 06 00     LDX #$0006
C2/942A: 9E 46 47     STZ $4746,X
C2/942D: CA           DEX 
C2/942E: 10 FA        BPL $942A
C2/9430: A2 1F 00     LDX #$001F
C2/9433: 9E 3C 3C     STZ $3C3C,X
C2/9436: CA           DEX 
C2/9437: 10 FA        BPL $9433
C2/9439: A5 47        LDA $47
C2/943B: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/943E: AD 2C 7B     LDA $7B2C
C2/9441: AA           TAX 
C2/9442: BF 55 EE D0  LDA $D0EE55,X
C2/9446: 85 39        STA $39
C2/9448: BD 2D 7B     LDA $7B2D,X
C2/944B: 10 29        BPL $9476
C2/944D: C9 FF        CMP #$FF
C2/944F: D0 1F        BNE $9470
C2/9451: AD 2C 7B     LDA $7B2C
C2/9454: D0 17        BNE $946D
C2/9456: A5 47        LDA $47
C2/9458: 8D CD 3B     STA $3BCD
C2/945B: 9C CC 3B     STZ $3BCC
C2/945E: 9C CE 3B     STZ $3BCE
C2/9461: 9C CF 3B     STZ $3BCF
C2/9464: 9C D0 3B     STZ $3BD0
C2/9467: 9C D1 3B     STZ $3BD1
C2/946A: 9C D2 3B     STZ $3BD2
C2/946D: 4C FE 94     JMP $94FE
C2/9470: EE 2C 7B     INC $7B2C
C2/9473: 4C FB 94     JMP $94FB
C2/9476: BD CC 7A     LDA $7ACC,X
C2/9479: 29 10        AND #$10
C2/947B: F0 0A        BEQ $9487
C2/947D: A5 56        LDA $56
C2/947F: F0 06        BEQ $9487
C2/9481: 20 80 99     JSR $9980
C2/9484: 4C 39 94     JMP $9439
C2/9487: BD CC 7A     LDA $7ACC,X
C2/948A: 29 EF        AND #$EF
C2/948C: D0 24        BNE $94B2
C2/948E: AD 2C 7B     LDA $7B2C
C2/9491: 0A           ASL 
C2/9492: AA           TAX 
C2/9493: BD DC 7A     LDA $7ADC,X
C2/9496: 1D DD 7A     ORA $7ADD,X
C2/9499: D0 09        BNE $94A4
C2/949B: A5 47        LDA $47
C2/949D: 85 48        STA $48
C2/949F: 8D 45 7B     STA $7B45
C2/94A2: 80 09        BRA $94AD
C2/94A4: 20 FF 94     JSR $94FF
C2/94A7: 3A           DEC 
C2/94A8: 85 48        STA $48
C2/94AA: 8D 45 7B     STA $7B45
C2/94AD: 20 08 9A     JSR $9A08
C2/94B0: 80 17        BRA $94C9
C2/94B2: AD BC 7A     LDA $7ABC
C2/94B5: D0 04        BNE $94BB
C2/94B7: A9 FF        LDA #$FF
C2/94B9: 85 48        STA $48
C2/94BB: 20 FF 94     JSR $94FF
C2/94BE: 18           CLC 
C2/94BF: 65 48        ADC $48
C2/94C1: 85 48        STA $48
C2/94C3: 8D 45 7B     STA $7B45
C2/94C6: 20 08 9A     JSR $9A08
C2/94C9: A5 48        LDA $48
C2/94CB: C2 20        REP #$20
C2/94CD: 20 B2 01     JSR $01B2       ; a << 7
C2/94D0: 85 49        STA $49
C2/94D2: 7B           TDC 
C2/94D3: E2 20        SEP #$20
C2/94D5: 64 5F        STZ $5F
C2/94D7: 9C 40 7B     STZ $7B40
C2/94DA: 9C 41 7B     STZ $7B41
C2/94DD: 9C 42 7B     STZ $7B42
C2/94E0: 9C 43 7B     STZ $7B43
C2/94E3: 9C 44 7B     STZ $7B44
C2/94E6: 9C 46 7B     STZ $7B46
C2/94E9: 9C 5D 7C     STZ $7C5D
C2/94EC: 9C 97 7C     STZ $7C97
C2/94EF: 20 61 95     JSR $9561
C2/94F2: 20 1A 95     JSR $951A
C2/94F5: 20 08 64     JSR $6408
C2/94F8: 20 61 97     JSR $9761
C2/94FB: 4C 39 94     JMP $9439
C2/94FE: 60           RTS 

; [  ]

C2/94FF: AD 2C 7B     LDA $7B2C
C2/9502: 0A           ASL 
C2/9503: AA           TAX 
C2/9504: 7B           TDC 
C2/9505: A8           TAY 
C2/9506: C8           INY 
C2/9507: 1E DD 7A     ASL $7ADD,X
C2/950A: 3E DC 7A     ROL $7ADC,X
C2/950D: B0 09        BCS $9518
C2/950F: C8           INY 
C2/9510: C0 0C 00     CPY #$000C
C2/9513: D0 F2        BNE $9507
C2/9515: A5 47        LDA $47
C2/9517: A8           TAY 
C2/9518: 98           TYA 
C2/9519: 60           RTS 

; [  ]

C2/951A: A6 32        LDX $32
C2/951C: AD 2C 7B     LDA $7B2C
C2/951F: F0 0B        BEQ $952C
C2/9521: C2 20        REP #$20
C2/9523: 8A           TXA 
C2/9524: 18           CLC 
C2/9525: 69 05 00     ADC #$0005
C2/9528: AA           TAX 
C2/9529: 7B           TDC 
C2/952A: E2 20        SEP #$20
C2/952C: A5 39        LDA $39
C2/952E: A8           TAY 
C2/952F: AD 4D 47     LDA $474D
C2/9532: 8D 46 47     STA $4746
C2/9535: BD 56 20     LDA $2056,X
C2/9538: 29 20        AND #$20
C2/953A: F0 08        BEQ $9544
C2/953C: BD 5A 20     LDA $205A,X
C2/953F: 8D 47 47     STA $4747
C2/9542: 80 0D        BRA $9551
C2/9544: BD 56 20     LDA $2056,X
C2/9547: 29 40        AND #$40
C2/9549: F0 06        BEQ $9551
C2/954B: BD 5A 20     LDA $205A,X
C2/954E: 8D 48 47     STA $4748
C2/9551: B9 FD 79     LDA $79FD,Y
C2/9554: 8D 4A 47     STA $474A
C2/9557: BD 58 20     LDA $2058,X
C2/955A: 1D 59 20     ORA $2059,X
C2/955D: 8D 4B 47     STA $474B
C2/9560: 60           RTS 

; [  ]

C2/9561: A5 39        LDA $39
C2/9563: AA           TAX 
C2/9564: BD FD 79     LDA $79FD,X
C2/9567: 29 0F        AND #$0F
C2/9569: D0 02        BNE $956D
C2/956B: 80 11        BRA $957E
C2/956D: BD FF 79     LDA $79FF,X
C2/9570: 10 02        BPL $9574
C2/9572: 80 0A        BRA $957E
C2/9574: A6 49        LDX $49
C2/9576: BD 1C 20     LDA $201C,X
C2/9579: 1D 72 20     ORA $2072,X
C2/957C: 30 03        BMI $9581
C2/957E: 4C 14 96     JMP $9614
C2/9581: BD 00 20     LDA $2000,X
C2/9584: 29 40        AND #$40
C2/9586: D0 F6        BNE $957E
C2/9588: BD 1D 20     LDA $201D,X
C2/958B: 29 C1        AND #$C1
C2/958D: D0 EF        BNE $957E
C2/958F: BD 1E 20     LDA $201E,X
C2/9592: 29 10        AND #$10
C2/9594: D0 E8        BNE $957E
C2/9596: EE 46 7B     INC $7B46
C2/9599: 64 0E        STZ $0E
C2/959B: A9 03        LDA #$03
C2/959D: 85 0F        STA $0F
C2/959F: A5 48        LDA $48
C2/95A1: 85 10        STA $10
C2/95A3: C9 04        CMP #$04
C2/95A5: B0 08        BCS $95AF
C2/95A7: A9 04        LDA #$04
C2/95A9: 85 0E        STA $0E
C2/95AB: A9 0B        LDA #$0B
C2/95AD: 85 0F        STA $0F
C2/95AF: A5 10        LDA $10
C2/95B1: C9 04        CMP #$04
C2/95B3: 90 03        BCC $95B8
C2/95B5: 38           SEC 
C2/95B6: E9 04        SBC #$04
C2/95B8: AA           TAX 
C2/95B9: 7B           TDC 
C2/95BA: 20 D6 01     JSR $01D6       ; set bit x
C2/95BD: 8D 42 7B     STA $7B42
C2/95C0: 20 28 97     JSR $9728
C2/95C3: A5 11        LDA $11
C2/95C5: F0 08        BEQ $95CF
C2/95C7: 7B           TDC 
C2/95C8: 85 48        STA $48
C2/95CA: AA           TAX 
C2/95CB: 86 49        STX $49
C2/95CD: 80 45        BRA $9614
C2/95CF: A5 0E        LDA $0E
C2/95D1: AA           TAX 
C2/95D2: A5 0F        LDA $0F
C2/95D4: 20 7C 00     JSR $007C       ; a = (x..a)
C2/95D7: 85 10        STA $10
C2/95D9: A8           TAY 
C2/95DA: B9 C2 3E     LDA $3EC2,Y
C2/95DD: F0 F0        BEQ $95CF
C2/95DF: A5 10        LDA $10
C2/95E1: C2 20        REP #$20
C2/95E3: 20 B2 01     JSR $01B2       ; a << 7
C2/95E6: AA           TAX 
C2/95E7: 86 49        STX $49
C2/95E9: 7B           TDC 
C2/95EA: E2 20        SEP #$20
C2/95EC: BD 1A 20     LDA $201A,X
C2/95EF: 29 C0        AND #$C0
C2/95F1: D0 DC        BNE $95CF
C2/95F3: BD 1D 20     LDA $201D,X
C2/95F6: 29 81        AND #$81
C2/95F8: D0 D5        BNE $95CF
C2/95FA: BD 1E 20     LDA $201E,X
C2/95FD: 29 10        AND #$10
C2/95FF: D0 CE        BNE $95CF
C2/9601: A5 10        LDA $10
C2/9603: 85 48        STA $48
C2/9605: C9 04        CMP #$04
C2/9607: 90 03        BCC $960C
C2/9609: 38           SEC 
C2/960A: E9 04        SBC #$04
C2/960C: AA           TAX 
C2/960D: 7B           TDC 
C2/960E: 20 D6 01     JSR $01D6       ; set bit x
C2/9611: 8D 43 7B     STA $7B43
C2/9614: A5 47        LDA $47
C2/9616: C9 04        CMP #$04
C2/9618: B0 01        BCS $961B
C2/961A: 60           RTS 
C2/961B: A5 48        LDA $48
C2/961D: C9 04        CMP #$04
C2/961F: 90 01        BCC $9622
C2/9621: 60           RTS 
C2/9622: AD 2C 7B     LDA $7B2C
C2/9625: AA           TAX 
C2/9626: BD 2D 7B     LDA $7B2D,X
C2/9629: C9 01        CMP #$01
C2/962B: F0 05        BEQ $9632
C2/962D: C9 02        CMP #$02
C2/962F: F0 01        BEQ $9632
C2/9631: 60           RTS 
C2/9632: A6 49        LDX $49
C2/9634: BD 1E 20     LDA $201E,X
C2/9637: 29 10        AND #$10
C2/9639: D0 11        BNE $964C
C2/963B: BD 1D 20     LDA $201D,X
C2/963E: 29 02        AND #$02
C2/9640: F0 0A        BEQ $964C
C2/9642: BD 1B 20     LDA $201B,X
C2/9645: 1D 1B 20     ORA $201B,X
C2/9648: 29 10        AND #$10
C2/964A: F0 01        BEQ $964D
C2/964C: 60           RTS 
C2/964D: AD 1E 7C     LDA $7C1E
C2/9650: 0D 1F 7C     ORA $7C1F
C2/9653: D0 F7        BNE $964C
C2/9655: 7B           TDC 
C2/9656: AA           TAX 
C2/9657: 86 0E        STX $0E
C2/9659: 86 10        STX $10
C2/965B: A4 0E        LDY $0E
C2/965D: B9 C2 3E     LDA $3EC2,Y
C2/9660: F0 3B        BEQ $969D
C2/9662: BD 21 20     LDA $2021,X
C2/9665: 10 36        BPL $969D
C2/9667: BD 1A 20     LDA $201A,X
C2/966A: 1D 70 20     ORA $2070,X
C2/966D: 29 42        AND #$42
C2/966F: D0 2C        BNE $969D
C2/9671: BD 1B 20     LDA $201B,X
C2/9674: 1D 71 20     ORA $2071,X
C2/9677: 29 78        AND #$78
C2/9679: D0 22        BNE $969D
C2/967B: BD 1C 20     LDA $201C,X
C2/967E: 29 10        AND #$10
C2/9680: D0 1B        BNE $969D
C2/9682: BD 1D 20     LDA $201D,X
C2/9685: 29 81        AND #$81
C2/9687: D0 14        BNE $969D
C2/9689: BD 1E 20     LDA $201E,X
C2/968C: 29 10        AND #$10
C2/968E: D0 0D        BNE $969D
C2/9690: A4 10        LDY $10
C2/9692: A5 0E        LDA $0E
C2/9694: C5 48        CMP $48
C2/9696: F0 05        BEQ $969D
C2/9698: 99 20 26     STA $2620,Y
C2/969B: E6 10        INC $10
C2/969D: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/96A0: E6 0E        INC $0E
C2/96A2: A5 0E        LDA $0E
C2/96A4: C9 04        CMP #$04
C2/96A6: D0 B3        BNE $965B
C2/96A8: A5 10        LDA $10
C2/96AA: F0 7B        BEQ $9727
C2/96AC: A6 32        LDX $32
C2/96AE: DA           PHX 
C2/96AF: 7B           TDC 
C2/96B0: AA           TAX 
C2/96B1: 86 0E        STX $0E
C2/96B3: 86 12        STX $12
C2/96B5: A6 0E        LDX $0E
C2/96B7: BD 20 26     LDA $2620,X
C2/96BA: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/96BD: A4 12        LDY $12
C2/96BF: C2 20        REP #$20
C2/96C1: BD 06 20     LDA $2006,X
C2/96C4: 99 2A 26     STA $262A,Y
C2/96C7: 7B           TDC 
C2/96C8: E2 20        SEP #$20
C2/96CA: E6 12        INC $12
C2/96CC: E6 12        INC $12
C2/96CE: E6 0E        INC $0E
C2/96D0: A5 0E        LDA $0E
C2/96D2: C5 10        CMP $10
C2/96D4: D0 DF        BNE $96B5
C2/96D6: 06 10        ASL $10
C2/96D8: 7B           TDC 
C2/96D9: AA           TAX 
C2/96DA: 86 0E        STX $0E
C2/96DC: 86 12        STX $12
C2/96DE: 86 14        STX $14
C2/96E0: C2 20        REP #$20
C2/96E2: A6 0E        LDX $0E
C2/96E4: BD 2A 26     LDA $262A,X
C2/96E7: C5 12        CMP $12
C2/96E9: 90 10        BCC $96FB
C2/96EB: 85 12        STA $12
C2/96ED: 7B           TDC 
C2/96EE: E2 20        SEP #$20
C2/96F0: A5 0E        LDA $0E
C2/96F2: 4A           LSR 
C2/96F3: AA           TAX 
C2/96F4: BD 20 26     LDA $2620,X
C2/96F7: 85 14        STA $14
C2/96F9: 80 03        BRA $96FE
C2/96FB: 7B           TDC 
C2/96FC: E2 20        SEP #$20
C2/96FE: E6 0E        INC $0E
C2/9700: E6 0E        INC $0E
C2/9702: A5 0E        LDA $0E
C2/9704: C5 10        CMP $10
C2/9706: D0 D8        BNE $96E0
C2/9708: A5 48        LDA $48
C2/970A: AA           TAX 
C2/970B: 7B           TDC 
C2/970C: 20 D6 01     JSR $01D6       ; set bit x
C2/970F: 8D 44 7B     STA $7B44
C2/9712: A5 14        LDA $14
C2/9714: 85 48        STA $48
C2/9716: 8D 45 7B     STA $7B45
C2/9719: C2 20        REP #$20
C2/971B: 20 B2 01     JSR $01B2       ; a << 7
C2/971E: AA           TAX 
C2/971F: 86 49        STX $49
C2/9721: 7B           TDC 
C2/9722: E2 20        SEP #$20
C2/9724: FA           PLX 
C2/9725: 86 32        STX $32
C2/9727: 60           RTS 

; [  ]

C2/9728: A5 0F        LDA $0F
C2/972A: A8           TAY 
C2/972B: C8           INY 
C2/972C: 84 10        STY $10
C2/972E: 64 11        STZ $11
C2/9730: A5 0E        LDA $0E
C2/9732: A8           TAY 
C2/9733: C2 20        REP #$20
C2/9735: 20 B2 01     JSR $01B2       ; a << 7
C2/9738: AA           TAX 
C2/9739: 7B           TDC 
C2/973A: E2 20        SEP #$20
C2/973C: B9 C2 3E     LDA $3EC2,Y
C2/973F: F0 15        BEQ $9756
C2/9741: BD 1A 20     LDA $201A,X
C2/9744: 29 C0        AND #$C0
C2/9746: D0 0E        BNE $9756
C2/9748: BD 1D 20     LDA $201D,X
C2/974B: 29 81        AND #$81
C2/974D: D0 07        BNE $9756
C2/974F: BD 1E 20     LDA $201E,X
C2/9752: 29 10        AND #$10
C2/9754: F0 0A        BEQ $9760
C2/9756: 20 E0 01     JSR $01E0       ; increment pointer to character/monster properties
C2/9759: C8           INY 
C2/975A: C4 10        CPY $10
C2/975C: D0 DE        BNE $973C
C2/975E: E6 11        INC $11
C2/9760: 60           RTS 

; [  ]

C2/9761: 20 85 98     JSR $9885
C2/9764: AD 2C 7B     LDA $7B2C
C2/9767: 85 24        STA $24
C2/9769: A9 07        LDA #$07
C2/976B: 85 25        STA $25
C2/976D: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/9770: A4 26        LDY $26
C2/9772: AD 47 47     LDA $4747
C2/9775: C9 81        CMP #$81
C2/9777: D0 08        BNE $9781
C2/9779: B9 CC 3B     LDA $3BCC,Y
C2/977C: 09 01        ORA #$01
C2/977E: 99 CC 3B     STA $3BCC,Y
C2/9781: AD FB 7B     LDA $7BFB
C2/9784: F0 08        BEQ $978E
C2/9786: B9 CC 3B     LDA $3BCC,Y
C2/9789: 09 20        ORA #$20
C2/978B: 99 CC 3B     STA $3BCC,Y
C2/978E: AD 5D 7C     LDA $7C5D
C2/9791: F0 08        BEQ $979B
C2/9793: B9 CC 3B     LDA $3BCC,Y
C2/9796: 09 02        ORA #$02
C2/9798: 99 CC 3B     STA $3BCC,Y
C2/979B: A5 47        LDA $47
C2/979D: C9 04        CMP #$04
C2/979F: 90 0D        BCC $97AE
C2/97A1: B9 CC 3B     LDA $3BCC,Y
C2/97A4: 09 80        ORA #$80
C2/97A6: 99 CC 3B     STA $3BCC,Y
C2/97A9: 38           SEC 
C2/97AA: A5 47        LDA $47
C2/97AC: E9 04        SBC #$04
C2/97AE: 99 CD 3B     STA $3BCD,Y
C2/97B1: AD 45 7B     LDA $7B45
C2/97B4: C9 04        CMP #$04
C2/97B6: 90 0E        BCC $97C6
C2/97B8: B9 CC 3B     LDA $3BCC,Y
C2/97BB: 09 40        ORA #$40
C2/97BD: 99 CC 3B     STA $3BCC,Y
C2/97C0: 38           SEC 
C2/97C1: AD 45 7B     LDA $7B45
C2/97C4: E9 04        SBC #$04
C2/97C6: AA           TAX 
C2/97C7: B9 CE 3B     LDA $3BCE,Y
C2/97CA: 20 D6 01     JSR $01D6       ; set bit x
C2/97CD: 99 CE 3B     STA $3BCE,Y
C2/97D0: A5 5F        LDA $5F
C2/97D2: 05 61        ORA $61
C2/97D4: F0 08        BEQ $97DE
C2/97D6: B9 CC 3B     LDA $3BCC,Y
C2/97D9: 09 10        ORA #$10
C2/97DB: 99 CC 3B     STA $3BCC,Y
C2/97DE: AD 40 7B     LDA $7B40
C2/97E1: F0 08        BEQ $97EB
C2/97E3: B9 CC 3B     LDA $3BCC,Y
C2/97E6: 09 08        ORA #$08
C2/97E8: 99 CC 3B     STA $3BCC,Y
C2/97EB: AD 46 7B     LDA $7B46
C2/97EE: D0 0B        BNE $97FB
C2/97F0: B9 CF 3B     LDA $3BCF,Y
C2/97F3: 0D 41 7B     ORA $7B41
C2/97F6: 99 CF 3B     STA $3BCF,Y
C2/97F9: 80 37        BRA $9832
C2/97FB: AD 45 7B     LDA $7B45
C2/97FE: 85 48        STA $48
C2/9800: B9 D0 3B     LDA $3BD0,Y
C2/9803: 0D 42 7B     ORA $7B42
C2/9806: 99 D0 3B     STA $3BD0,Y
C2/9809: AD 41 7B     LDA $7B41
C2/980C: F0 24        BEQ $9832
C2/980E: AD 2C 7B     LDA $7B2C
C2/9811: 20 B6 01     JSR $01B6       ; a << 3
C2/9814: 85 0F        STA $0F
C2/9816: A5 48        LDA $48
C2/9818: C9 04        CMP #$04
C2/981A: 90 03        BCC $981F
C2/981C: 38           SEC 
C2/981D: E9 04        SBC #$04
C2/981F: 18           CLC 
C2/9820: 65 0F        ADC $0F
C2/9822: AA           TAX 
C2/9823: AD 43 7B     LDA $7B43
C2/9826: 9D 49 7B     STA $7B49,X
C2/9829: B9 D1 3B     LDA $3BD1,Y
C2/982C: 0D 43 7B     ORA $7B43
C2/982F: 99 D1 3B     STA $3BD1,Y
C2/9832: AD 44 7B     LDA $7B44
C2/9835: 99 D2 3B     STA $3BD2,Y
C2/9838: AD 2C 7B     LDA $7B2C
C2/983B: AA           TAX 
C2/983C: BD 1C 7B     LDA $7B1C,X
C2/983F: F0 08        BEQ $9849
C2/9841: EE BC 7A     INC $7ABC
C2/9844: CD BC 7A     CMP $7ABC
C2/9847: D0 3B        BNE $9884
C2/9849: B9 CF 3B     LDA $3BCF,Y
C2/984C: D0 2A        BNE $9878
C2/984E: 20 65 99     JSR $9965
C2/9851: 64 0E        STZ $0E
C2/9853: BD 5F 3C     LDA $3C5F,X
C2/9856: 4A           LSR 
C2/9857: 66 0E        ROR $0E
C2/9859: 4A           LSR 
C2/985A: 66 0E        ROR $0E
C2/985C: 4A           LSR 
C2/985D: 66 0E        ROR $0E
C2/985F: AA           TAX 
C2/9860: BF F6 EE D0  LDA $D0EEF6,X
C2/9864: 48           PHA 
C2/9865: A5 0E        LDA $0E
C2/9867: 20 BD 01     JSR $01BD       ; a >> 5
C2/986A: AA           TAX 
C2/986B: 68           PLA 
C2/986C: 20 DB 01     JSR $01DB       ; check bit x
C2/986F: D0 07        BNE $9878
C2/9871: 20 65 99     JSR $9965
C2/9874: 7B           TDC             ; no message
C2/9875: 9D 5F 3C     STA $3C5F,X
C2/9878: EE 2C 7B     INC $7B2C
C2/987B: EE FB 79     INC $79FB
C2/987E: 9C BC 7A     STZ $7ABC
C2/9881: 9C 08 7C     STZ $7C08
C2/9884: 60           RTS 

; [  ]

C2/9885: A6 49        LDX $49
C2/9887: AD 2C 7B     LDA $7B2C
C2/988A: D0 2C        BNE $98B8
C2/988C: AD 46 47     LDA $4746
C2/988F: 9D 46 20     STA $2046,X
C2/9892: AD 47 47     LDA $4747
C2/9895: 9D 47 20     STA $2047,X
C2/9898: AD 48 47     LDA $4748
C2/989B: 9D 48 20     STA $2048,X
C2/989E: AD 49 47     LDA $4749
C2/98A1: 9D 49 20     STA $2049,X
C2/98A4: AD 4A 47     LDA $474A
C2/98A7: 9D 4A 20     STA $204A,X
C2/98AA: AD 4B 47     LDA $474B
C2/98AD: 9D 4B 20     STA $204B,X
C2/98B0: AD 4C 47     LDA $474C
C2/98B3: 9D 4C 20     STA $204C,X
C2/98B6: 80 2A        BRA $98E2
C2/98B8: AD 46 47     LDA $4746
C2/98BB: 9D 4D 20     STA $204D,X
C2/98BE: AD 47 47     LDA $4747
C2/98C1: 9D 4E 20     STA $204E,X
C2/98C4: AD 48 47     LDA $4748
C2/98C7: 9D 4F 20     STA $204F,X
C2/98CA: AD 49 47     LDA $4749
C2/98CD: 9D 7B 20     STA $207B,X
C2/98D0: AD 4A 47     LDA $474A
C2/98D3: 9D 7C 20     STA $207C,X
C2/98D6: AD 4B 47     LDA $474B
C2/98D9: 9D 7D 20     STA $207D,X
C2/98DC: AD 4C 47     LDA $474C
C2/98DF: 9D 7E 20     STA $207E,X
C2/98E2: 60           RTS 

; [  ]

C2/98E3: 20 FA 98     JSR $98FA       ; create graphics command
C2/98E6: 9E 4C 38     STZ $384C,X
C2/98E9: A9 FC        LDA #$FC
C2/98EB: 9D 4D 38     STA $384D,X
C2/98EE: A9 06        LDA #$06
C2/98F0: 9D 4E 38     STA $384E,X
C2/98F3: 9E 4F 38     STZ $384F,X
C2/98F6: 9E 50 38     STZ $3850,X
C2/98F9: 60           RTS 

; [ create graphics command ]

C2/98FA: AD 03 7C     LDA $7C03
C2/98FD: D0 13        BNE $9912
C2/98FF: AD F9 79     LDA $79F9       ; number of pending graphics commands
C2/9902: 0A           ASL 
C2/9903: AA           TAX 
C2/9904: C2 20        REP #$20
C2/9906: BF 89 ED D0  LDA $D0ED89,X   ; pointer to graphics command
C2/990A: AA           TAX 
C2/990B: 7B           TDC 
C2/990C: E2 20        SEP #$20
C2/990E: EE F9 79     INC $79F9
C2/9911: 60           RTS 

; [  ]

C2/9912: 7B           TDC 
C2/9913: AA           TAX 
C2/9914: BD 4C 38     LDA $384C,X     ; find the first unused graphics command
C2/9917: C9 FF        CMP #$FF
C2/9919: F0 07        BEQ $9922
C2/991B: E8           INX 
C2/991C: E8           INX 
C2/991D: E8           INX 
C2/991E: E8           INX 
C2/991F: E8           INX 
C2/9920: 80 F2        BRA $9914
C2/9922: 60           RTS 

; [  ]

C2/9923: AD FA 79     LDA $79FA
C2/9926: AA           TAX 
C2/9927: BF 55 EE D0  LDA $D0EE55,X
C2/992B: A8           TAY 
C2/992C: 84 0C        STY $0C
C2/992E: 60           RTS 


; [  ]

C2/992F: 20 FA 98     JSR $98FA       ; create graphics command
C2/9932: 9E 4C 38     STZ $384C,X
C2/9935: A9 FC        LDA #$FC
C2/9937: 9D 4D 38     STA $384D,X
C2/993A: A9 04        LDA #$04
C2/993C: 9D 4E 38     STA $384E,X
C2/993F: AD 20 26     LDA $2620
C2/9942: 9D 4F 38     STA $384F,X
C2/9945: AD 21 26     LDA $2621
C2/9948: 9D 50 38     STA $3850,X
C2/994B: 60           RTS 

; [  ]

C2/994C: 20 FA 98     JSR $98FA       ; create graphics command
C2/994F: 9E 4C 38     STZ $384C,X
C2/9952: A9 FC        LDA #$FC
C2/9954: 9D 4D 38     STA $384D,X
C2/9957: A9 05        LDA #$05
C2/9959: 9D 4E 38     STA $384E,X
C2/995C: 9E 4F 38     STZ $384F,X
C2/995F: 9E 50 38     STZ $3850,X
C2/9962: 4C 56 03     JMP $0356

; [  ]

C2/9965: AD 2C 7B     LDA $7B2C
C2/9968: 20 B7 01     JSR $01B7       ; a << 2
C2/996B: 85 0E        STA $0E
C2/996D: 0A           ASL 
C2/996E: 18           CLC 
C2/996F: 65 0E        ADC $0E
C2/9971: A8           TAY 
C2/9972: AD 2C 7B     LDA $7B2C
C2/9975: 20 B6 01     JSR $01B6       ; a << 3
C2/9978: 85 0E        STA $0E
C2/997A: 0A           ASL 
C2/997B: 18           CLC 
C2/997C: 65 0E        ADC $0E
C2/997E: AA           TAX 
C2/997F: 60           RTS 

; [  ]

C2/9980: AD 2C 7B     LDA $7B2C
C2/9983: AA           TAX 
C2/9984: BF 55 EE D0  LDA $D0EE55,X
C2/9988: A8           TAY 
C2/9989: AD 2C 7B     LDA $7B2C
C2/998C: 1A           INC 
C2/998D: AA           TAX 
C2/998E: BF 55 EE D0  LDA $D0EE55,X
C2/9992: AA           TAX 
C2/9993: BD FC 79     LDA $79FC,X
C2/9996: 99 FC 79     STA $79FC,Y
C2/9999: E8           INX 
C2/999A: C8           INY 
C2/999B: E0 C0 00     CPX #$00C0
C2/999E: D0 F3        BNE $9993
C2/99A0: AD 2C 7B     LDA $7B2C
C2/99A3: A8           TAY 
C2/99A4: BB           TYX 
C2/99A5: E8           INX 
C2/99A6: BD 2D 7B     LDA $7B2D,X
C2/99A9: 99 2D 7B     STA $7B2D,Y
C2/99AC: BD 1C 7B     LDA $7B1C,X
C2/99AF: 99 1C 7B     STA $7B1C,Y
C2/99B2: BD CC 7A     LDA $7ACC,X
C2/99B5: 99 CC 7A     STA $7ACC,Y
C2/99B8: E8           INX 
C2/99B9: C8           INY 
C2/99BA: E0 10 00     CPX #$0010
C2/99BD: D0 E7        BNE $99A6
C2/99BF: AD 2C 7B     LDA $7B2C
C2/99C2: 0A           ASL 
C2/99C3: A8           TAY 
C2/99C4: BB           TYX 
C2/99C5: E8           INX 
C2/99C6: E8           INX 
C2/99C7: BD DC 7A     LDA $7ADC,X
C2/99CA: 99 DC 7A     STA $7ADC,Y
C2/99CD: BD DD 7A     LDA $7ADD,X
C2/99D0: 99 DD 7A     STA $7ADD,Y
C2/99D3: E8           INX 
C2/99D4: E8           INX 
C2/99D5: C8           INY 
C2/99D6: C8           INY 
C2/99D7: E0 20 00     CPX #$0020
C2/99DA: D0 EB        BNE $99C7
C2/99DC: AD 2C 7B     LDA $7B2C
C2/99DF: 3A           DEC 
C2/99E0: D0 08        BNE $99EA
C2/99E2: A0 0A 00     LDY #$000A
C2/99E5: A2 14 00     LDX #$0014
C2/99E8: 80 11        BRA $99FB
C2/99EA: 3A           DEC 
C2/99EB: D0 08        BNE $99F5
C2/99ED: A0 14 00     LDY #$0014
C2/99F0: A2 1E 00     LDX #$001E
C2/99F3: 80 06        BRA $99FB
C2/99F5: A0 1E 00     LDY #$001E
C2/99F8: A2 28 00     LDX #$0028
C2/99FB: BD 4C 38     LDA $384C,X
C2/99FE: 99 4C 38     STA $384C,Y
C2/9A01: E8           INX 
C2/9A02: C8           INY 
C2/9A03: C9 FF        CMP #$FF
C2/9A05: D0 F4        BNE $99FB
C2/9A07: 60           RTS 

; [  ]

C2/9A08: A5 39        LDA $39
C2/9A0A: AA           TAX 
C2/9A0B: BD FE 79     LDA $79FE,X
C2/9A0E: 29 07        AND #$07
C2/9A10: D0 4B        BNE $9A5D
C2/9A12: BD FF 79     LDA $79FF,X
C2/9A15: 29 7F        AND #$7F
C2/9A17: AA           TAX 
C2/9A18: 86 0E        STX $0E
C2/9A1A: A6 32        LDX $32
C2/9A1C: BD 39 20     LDA $2039,X
C2/9A1F: 29 08        AND #$08
C2/9A21: F0 06        BEQ $9A29
C2/9A23: 46 0E        LSR $0E
C2/9A25: 90 02        BCC $9A29
C2/9A27: E6 0E        INC $0E
C2/9A29: BD 56 20     LDA $2056,X
C2/9A2C: 29 01        AND #$01
C2/9A2E: F0 2D        BEQ $9A5D
C2/9A30: AD 08 7C     LDA $7C08
C2/9A33: D0 28        BNE $9A5D
C2/9A35: EE 08 7C     INC $7C08
C2/9A38: C2 20        REP #$20
C2/9A3A: 38           SEC 
C2/9A3B: BD 0A 20     LDA $200A,X
C2/9A3E: E5 0E        SBC $0E
C2/9A40: 90 07        BCC $9A49
C2/9A42: 9D 0A 20     STA $200A,X
C2/9A45: 7B           TDC 
C2/9A46: E2 20        SEP #$20
C2/9A48: 60           RTS 
C2/9A49: 7B           TDC 
C2/9A4A: E2 20        SEP #$20
C2/9A4C: AD 2C 7B     LDA $7B2C
C2/9A4F: AA           TAX 
C2/9A50: A9 7E        LDA #$7E
C2/9A52: 9D 2D 7B     STA $7B2D,X
C2/9A55: 20 65 99     JSR $9965
C2/9A58: A9 1E        LDA #$1E
C2/9A5A: 9D 5F 3C     STA $3C5F,X     ; "Not enough MP"
C2/9A5D: 60           RTS 

; [ update character equipment (all) ]

C2/9A5E: 9C 7B 7B     STZ $7B7B       ; character id
C2/9A61: 20 6F 9A     JSR $9A6F       ; update character equipment
C2/9A64: EE 7B 7B     INC $7B7B
C2/9A67: AD 7B 7B     LDA $7B7B
C2/9A6A: C9 04        CMP #$04
C2/9A6C: D0 F3        BNE $9A61
C2/9A6E: 60           RTS 

; [ update character equipment ]

C2/9A6F: AD 7B 7B     LDA $7B7B       ; character id
C2/9A72: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/9A75: C2 20        REP #$20
C2/9A77: 8A           TXA 
C2/9A78: 18           CLC 
C2/9A79: 69 0E 20     ADC #$200E      ; helmet (1st item)
C2/9A7C: 85 0E        STA $0E
C2/9A7E: 7B           TDC 
C2/9A7F: E2 20        SEP #$20
C2/9A81: AD 7B 7B     LDA $7B7B
C2/9A84: AA           TAX 
C2/9A85: BF 85 ED D0  LDA $D0ED85,X   ; character item data offset (+$4049)
C2/9A89: AA           TAX 
C2/9A8A: 86 10        STX $10
C2/9A8C: 86 0A        STX $0A
C2/9A8E: 7B           TDC 
C2/9A8F: A8           TAY 
C2/9A90: 84 14        STY $14
C2/9A92: A4 14        LDY $14
C2/9A94: B1 0E        LDA ($0E),Y     ; item index
C2/9A96: C2 20        REP #$20
C2/9A98: 20 B7 01     JSR $01B7       ; a << 2
C2/9A9B: 85 16        STA $16
C2/9A9D: 0A           ASL 
C2/9A9E: 18           CLC 
C2/9A9F: 65 16        ADC $16
C2/9AA1: AA           TAX 
C2/9AA2: 7B           TDC 
C2/9AA3: E2 20        SEP #$20
C2/9AA5: 64 18        STZ $18
C2/9AA7: A4 10        LDY $10
C2/9AA9: BF 00 00 D1  LDA $D10000,X   ; item properties
C2/9AAD: 99 49 40     STA $4049,Y
C2/9AB0: E8           INX 
C2/9AB1: C8           INY 
C2/9AB2: E6 18        INC $18
C2/9AB4: A5 18        LDA $18
C2/9AB6: C9 0C        CMP #$0C        ; copy 12 bytes
C2/9AB8: D0 EF        BNE $9AA9
C2/9ABA: C2 20        REP #$20
C2/9ABC: 18           CLC 
C2/9ABD: A5 10        LDA $10
C2/9ABF: 69 0C 00     ADC #$000C
C2/9AC2: 85 10        STA $10
C2/9AC4: 7B           TDC 
C2/9AC5: E2 20        SEP #$20
C2/9AC7: E6 14        INC $14
C2/9AC9: A5 14        LDA $14
C2/9ACB: C9 07        CMP #$07        ; copy 7 items
C2/9ACD: D0 C3        BNE $9A92
C2/9ACF: 7B           TDC 
C2/9AD0: AA           TAX 
C2/9AD1: 8E 20 26     STX $2620
C2/9AD4: 8E 22 26     STX $2622
C2/9AD7: 8E 24 26     STX $2624
C2/9ADA: 8E 26 26     STX $2626
C2/9ADD: 8E 28 26     STX $2628
C2/9AE0: 86 12        STX $12
C2/9AE2: A8           TAY 
C2/9AE3: A6 32        LDX $32
C2/9AE5: BD 24 20     LDA $2024,X     ; base stat
C2/9AE8: C2 20        REP #$20
C2/9AEA: 18           CLC 
C2/9AEB: 69 E8 03     ADC #$03E8
C2/9AEE: 99 22 26     STA $2622,Y     ; base stat + 1000
C2/9AF1: 7B           TDC 
C2/9AF2: E2 20        SEP #$20
C2/9AF4: E8           INX 
C2/9AF5: C8           INY 
C2/9AF6: C8           INY 
C2/9AF7: E6 12        INC $12
C2/9AF9: A5 12        LDA $12
C2/9AFB: C9 04        CMP #$04        ; load 4 stats
C2/9AFD: D0 E6        BNE $9AE5
C2/9AFF: A4 0A        LDY $0A
C2/9B01: B9 4C 40     LDA $404C,Y     ; helmet bonus
C2/9B04: 30 0A        BMI $9B10       ; branch if stat bonus
C2/9B06: 0D 20 26     ORA $2620
C2/9B09: 8D 20 26     STA $2620       ; elements
C2/9B0C: C2 20        REP #$20
C2/9B0E: 80 35        BRA $9B45
C2/9B10: 48           PHA 
C2/9B11: 29 07        AND #$07
C2/9B13: 0A           ASL 
C2/9B14: AA           TAX 
C2/9B15: BF 80 28 D1  LDA $D12880,X   ; stat bonuses
C2/9B19: 85 14        STA $14
C2/9B1B: BF 81 28 D1  LDA $D12881,X
C2/9B1F: 85 16        STA $16
C2/9B21: 68           PLA 
C2/9B22: 0A           ASL 
C2/9B23: 85 19        STA $19
C2/9B25: 7B           TDC 
C2/9B26: AA           TAX 
C2/9B27: 64 15        STZ $15
C2/9B29: 64 17        STZ $17
C2/9B2B: C2 20        REP #$20
C2/9B2D: 06 18        ASL $18
C2/9B2F: B0 04        BCS $9B35
C2/9B31: A5 14        LDA $14
C2/9B33: 80 02        BRA $9B37
C2/9B35: A5 16        LDA $16
C2/9B37: 18           CLC 
C2/9B38: 7D 22 26     ADC $2622,X
C2/9B3B: 9D 22 26     STA $2622,X
C2/9B3E: E8           INX             ; next stat
C2/9B3F: E8           INX 
C2/9B40: E0 08 00     CPX #$0008
C2/9B43: D0 E8        BNE $9B2D
C2/9B45: 98           TYA             ; next item
C2/9B46: 18           CLC 
C2/9B47: 69 0C 00     ADC #$000C
C2/9B4A: A8           TAY 
C2/9B4B: 7B           TDC 
C2/9B4C: E2 20        SEP #$20
C2/9B4E: E6 13        INC $13
C2/9B50: A5 13        LDA $13
C2/9B52: C9 07        CMP #$07
C2/9B54: D0 AB        BNE $9B01
C2/9B56: 7B           TDC 
C2/9B57: AA           TAX 
C2/9B58: C2 20        REP #$20
C2/9B5A: 38           SEC 
C2/9B5B: BD 22 26     LDA $2622,X     ; subtract 1000 from stat
C2/9B5E: E9 E8 03     SBC #$03E8
C2/9B61: B0 01        BCS $9B64       ; branch if stat is above 0
C2/9B63: 7B           TDC 
C2/9B64: 9D 22 26     STA $2622,X
C2/9B67: E8           INX 
C2/9B68: E8           INX 
C2/9B69: E0 08 00     CPX #$0008
C2/9B6C: D0 EC        BNE $9B5A
C2/9B6E: 7B           TDC 
C2/9B6F: E2 20        SEP #$20
C2/9B71: A4 0A        LDY $0A
C2/9B73: A6 32        LDX $32
C2/9B75: AD 20 26     LDA $2620       ; item elements
C2/9B78: 29 7F        AND #$7F
C2/9B7A: 9D 22 20     STA $2022,X     ; attack element
C2/9B7D: AD 22 26     LDA $2622
C2/9B80: 9D 28 20     STA $2028,X
C2/9B83: AD 24 26     LDA $2624
C2/9B86: 9D 29 20     STA $2029,X
C2/9B89: AD 26 26     LDA $2626
C2/9B8C: 9D 2A 20     STA $202A,X
C2/9B8F: AD 28 26     LDA $2628
C2/9B92: 9D 2B 20     STA $202B,X
C2/9B95: 9E 50 20     STZ $2050,X
C2/9B98: 9E 51 20     STZ $2051,X
C2/9B9B: 9E 52 20     STZ $2052,X
C2/9B9E: 9E 53 20     STZ $2053,X
C2/9BA1: 9E 54 20     STZ $2054,X
C2/9BA4: 9E 55 20     STZ $2055,X
C2/9BA7: 9E 7A 20     STZ $207A,X
C2/9BAA: B9 86 40     LDA $4086,Y     ; right hand attack type
C2/9BAD: 9D 6C 20     STA $206C,X
C2/9BB0: B9 92 40     LDA $4092,Y     ; left hand attack type
C2/9BB3: 9D 6D 20     STA $206D,X
C2/9BB6: B9 8C 40     LDA $408C,Y     ; right hand attack power
C2/9BB9: 9D 44 20     STA $2044,X
C2/9BBC: B9 98 40     LDA $4098,Y     ; left hand attack power
C2/9BBF: 9D 45 20     STA $2045,X
C2/9BC2: B9 8A 40     LDA $408A,Y     ; left/right hand weapon special effect
C2/9BC5: 19 96 40     ORA $4096,Y
C2/9BC8: 9D 38 20     STA $2038,X
C2/9BCB: 18           CLC 
C2/9BCC: B9 73 40     LDA $4073,Y     ; shield evade (left hand + right hand)
C2/9BCF: 79 7F 40     ADC $407F,Y
C2/9BD2: C9 63        CMP #$63        ; max 99
C2/9BD4: 90 02        BCC $9BD8
C2/9BD6: A9 63        LDA #$63
C2/9BD8: 9D 2C 20     STA $202C,X
C2/9BDB: 18           CLC 
C2/9BDC: B9 50 40     LDA $4050,Y     ; defense (sum of all defensive items)
C2/9BDF: 79 5C 40     ADC $405C,Y
C2/9BE2: B0 0F        BCS $9BF3
C2/9BE4: 79 68 40     ADC $4068,Y
C2/9BE7: B0 0A        BCS $9BF3
C2/9BE9: 79 74 40     ADC $4074,Y
C2/9BEC: B0 05        BCS $9BF3
C2/9BEE: 79 80 40     ADC $4080,Y
C2/9BF1: 90 02        BCC $9BF5
C2/9BF3: A9 FF        LDA #$FF        ; max 255
C2/9BF5: 9D 2D 20     STA $202D,X
C2/9BF8: 18           CLC 
C2/9BF9: B9 51 40     LDA $4051,Y     ; magic evade (sum of all defensive items)
C2/9BFC: 79 5D 40     ADC $405D,Y
C2/9BFF: 79 69 40     ADC $4069,Y
C2/9C02: 79 75 40     ADC $4075,Y
C2/9C05: 79 81 40     ADC $4081,Y
C2/9C08: C9 63        CMP #$63        ; max 99
C2/9C0A: 90 02        BCC $9C0E
C2/9C0C: A9 63        LDA #$63
C2/9C0E: 9D 2E 20     STA $202E,X
C2/9C11: 18           CLC 
C2/9C12: B9 52 40     LDA $4052,Y     ; magic defense (sum of all defensive items)
C2/9C15: 79 5E 40     ADC $405E,Y
C2/9C18: B0 0F        BCS $9C29
C2/9C1A: 79 6A 40     ADC $406A,Y
C2/9C1D: B0 0A        BCS $9C29
C2/9C1F: 79 76 40     ADC $4076,Y
C2/9C22: B0 05        BCS $9C29
C2/9C24: 79 82 40     ADC $4082,Y
C2/9C27: 90 02        BCC $9C2B
C2/9C29: A9 FF        LDA #$FF        ; max 255
C2/9C2B: 9D 2F 20     STA $202F,X
C2/9C2E: B9 4E 40     LDA $404E,Y     ; armor special effect
C2/9C31: 19 5A 40     ORA $405A,Y
C2/9C34: 19 66 40     ORA $4066,Y
C2/9C37: 19 72 40     ORA $4072,Y
C2/9C3A: 19 7E 40     ORA $407E,Y
C2/9C3D: 9D 39 20     STA $2039,X
C2/9C40: 7B           TDC 
C2/9C41: AA           TAX 
C2/9C42: 8E 20 26     STX $2620
C2/9C45: 8E 22 26     STX $2622
C2/9C48: 8E 24 26     STX $2624
C2/9C4B: 86 0E        STX $0E
C2/9C4D: A4 0A        LDY $0A
C2/9C4F: 84 10        STY $10
C2/9C51: A4 10        LDY $10
C2/9C53: B9 53 40     LDA $4053,Y     ; elemental defense
C2/9C56: C2 20        REP #$20
C2/9C58: 85 12        STA $12
C2/9C5A: 20 B7 01     JSR $01B7       ; a << 2
C2/9C5D: 18           CLC 
C2/9C5E: 65 12        ADC $12
C2/9C60: AA           TAX 
C2/9C61: 7B           TDC 
C2/9C62: E2 20        SEP #$20
C2/9C64: A8           TAY 
C2/9C65: BF 80 25 D1  LDA $D12580,X   ; armor elemental properties
C2/9C69: 19 20 26     ORA $2620,Y
C2/9C6C: 99 20 26     STA $2620,Y
C2/9C6F: E8           INX 
C2/9C70: C8           INY 
C2/9C71: C0 05 00     CPY #$0005      ; 5 bytes each (absorb, ???, immune, halve, weak)
C2/9C74: D0 EF        BNE $9C65
C2/9C76: C2 20        REP #$20
C2/9C78: A5 10        LDA $10
C2/9C7A: 18           CLC 
C2/9C7B: 69 0C 00     ADC #$000C
C2/9C7E: 85 10        STA $10
C2/9C80: 7B           TDC 
C2/9C81: E2 20        SEP #$20
C2/9C83: E6 0E        INC $0E
C2/9C85: A5 0E        LDA $0E
C2/9C87: C9 05        CMP #$05        ; check defensive items only
C2/9C89: D0 C6        BNE $9C51
C2/9C8B: 7B           TDC 
C2/9C8C: A8           TAY 
C2/9C8D: A6 32        LDX $32
C2/9C8F: B9 20 26     LDA $2620,Y
C2/9C92: 9D 30 20     STA $2030,X
C2/9C95: E8           INX 
C2/9C96: C8           INY 
C2/9C97: C0 05 00     CPY #$0005
C2/9C9A: D0 F3        BNE $9C8F
C2/9C9C: 9C 20 26     STZ $2620
C2/9C9F: 9C 21 26     STZ $2621
C2/9CA2: 9C 22 26     STZ $2622
C2/9CA5: 64 0E        STZ $0E
C2/9CA7: A6 0A        LDX $0A
C2/9CA9: 86 10        STX $10
C2/9CAB: A4 10        LDY $10
C2/9CAD: B9 54 40     LDA $4054,Y     ; status effect
C2/9CB0: 85 24        STA $24
C2/9CB2: A9 07        LDA #$07
C2/9CB4: 85 25        STA $25
C2/9CB6: 20 F1 00     JSR $00F1       ; +$26 = $24 * $25
C2/9CB9: 7B           TDC 
C2/9CBA: A8           TAY 
C2/9CBB: A6 26        LDX $26
C2/9CBD: BF C4 26 D1  LDA $D126C4,X   ; armor status effects
C2/9CC1: 19 20 26     ORA $2620,Y
C2/9CC4: 99 20 26     STA $2620,Y
C2/9CC7: E8           INX 
C2/9CC8: C8           INY 
C2/9CC9: C0 03 00     CPY #$0003
C2/9CCC: D0 EF        BNE $9CBD
C2/9CCE: A5 0E        LDA $0E
C2/9CD0: 48           PHA 
C2/9CD1: 20 01 9D     JSR $9D01
C2/9CD4: 68           PLA 
C2/9CD5: 85 0E        STA $0E
C2/9CD7: C2 20        REP #$20
C2/9CD9: A5 10        LDA $10
C2/9CDB: 18           CLC 
C2/9CDC: 69 0C 00     ADC #$000C
C2/9CDF: 85 10        STA $10
C2/9CE1: 7B           TDC 
C2/9CE2: E2 20        SEP #$20
C2/9CE4: E6 0E        INC $0E
C2/9CE6: A5 0E        LDA $0E
C2/9CE8: C9 05        CMP #$05
C2/9CEA: D0 BF        BNE $9CAB
C2/9CEC: 7B           TDC 
C2/9CED: A8           TAY 
C2/9CEE: A6 32        LDX $32
C2/9CF0: BD 35 20     LDA $2035,X
C2/9CF3: 19 20 26     ORA $2620,Y
C2/9CF6: 9D 35 20     STA $2035,X
C2/9CF9: E8           INX 
C2/9CFA: C8           INY 
C2/9CFB: C0 03 00     CPY #$0003
C2/9CFE: D0 F0        BNE $9CF0
C2/9D00: 60           RTS 

; [  ]

C2/9D01: 64 13        STZ $13
C2/9D03: A4 32        LDY $32
C2/9D05: A6 26        LDX $26
C2/9D07: BF C0 26 D1  LDA $D126C0,X   ; armor status properties byte 0
C2/9D0B: F0 3C        BEQ $9D49       ; branch if no status effects in this byte
C2/9D0D: 85 12        STA $12
C2/9D0F: 30 23        BMI $9D34
C2/9D11: 29 04        AND #$04
C2/9D13: F0 2A        BEQ $9D3F
C2/9D15: A5 12        LDA $12
C2/9D17: 29 FB        AND #$FB
C2/9D19: 85 12        STA $12
C2/9D1B: B9 1A 20     LDA $201A,Y
C2/9D1E: 19 70 20     ORA $2070,Y
C2/9D21: 29 04        AND #$04
C2/9D23: D0 1A        BNE $9D3F
C2/9D25: B9 1A 20     LDA $201A,Y
C2/9D28: 09 04        ORA #$04
C2/9D2A: 99 1A 20     STA $201A,Y
C2/9D2D: A9 01        LDA #$01
C2/9D2F: 20 2E 9F     JSR $9F2E
C2/9D32: 80 0B        BRA $9D3F
C2/9D34: E6 13        INC $13
C2/9D36: A5 12        LDA $12
C2/9D38: 29 7F        AND #$7F
C2/9D3A: 99 70 20     STA $2070,Y
C2/9D3D: 80 0A        BRA $9D49
C2/9D3F: A4 32        LDY $32
C2/9D41: B9 1A 20     LDA $201A,Y
C2/9D44: 05 12        ORA $12
C2/9D46: 99 1A 20     STA $201A,Y
C2/9D49: A4 32        LDY $32
C2/9D4B: A6 26        LDX $26
C2/9D4D: BF C1 26 D1  LDA $D126C1,X   ; armor status properties byte 1
C2/9D51: 85 12        STA $12
C2/9D53: B9 01 20     LDA $2001,Y
C2/9D56: C9 06        CMP #$06
C2/9D58: F0 0C        BEQ $9D66       ; branch if job is berserker
C2/9D5A: B9 1A 20     LDA $201A,Y
C2/9D5D: 19 70 20     ORA $2070,Y
C2/9D60: 29 02        AND #$02
C2/9D62: D0 0C        BNE $9D70       ; branch if zombie
C2/9D64: F0 25        BEQ $9D8B       ; branch if not zombie
C2/9D66: AD EF 3E     LDA $3EEF
C2/9D69: 30 05        BMI $9D70       ; branch if credits
C2/9D6B: A9 08        LDA #$08        ; add berserk status (should this be ORA ???)
C2/9D6D: 99 71 20     STA $2071,Y
C2/9D70: AD 7B 7B     LDA $7B7B
C2/9D73: AA           TAX 
C2/9D74: A9 3C        LDA #$3C
C2/9D76: 9D 04 7C     STA $7C04,X     ; 
C2/9D79: AD 7B 7B     LDA $7B7B
C2/9D7C: 0A           ASL 
C2/9D7D: AA           TAX 
C2/9D7E: BF 61 ED D0  LDA $D0ED61,X   ; timer offset
C2/9D82: AA           TAX 
C2/9D83: 7B           TDC 
C2/9D84: 9D FB 3C     STA $3CFB,X     ; deactivate action counter
C2/9D87: 1A           INC 
C2/9D88: 9D 7F 3D     STA $3D7F,X     ; set action counter to 1
C2/9D8B: A5 12        LDA $12
C2/9D8D: D0 03        BNE $9D92
C2/9D8F: 4C 26 9E     JMP $9E26
C2/9D92: 85 12        STA $12
C2/9D94: A5 13        LDA $13
C2/9D96: D0 7D        BNE $9E15
C2/9D98: A5 12        LDA $12
C2/9D9A: 29 A4        AND #$A4
C2/9D9C: F0 7E        BEQ $9E1C
C2/9D9E: A5 12        LDA $12
C2/9DA0: 29 80        AND #$80
C2/9DA2: F0 1D        BEQ $9DC1
C2/9DA4: A5 12        LDA $12
C2/9DA6: 29 7F        AND #$7F
C2/9DA8: 85 12        STA $12
C2/9DAA: B9 1B 20     LDA $201B,Y
C2/9DAD: 19 71 20     ORA $2071,Y
C2/9DB0: 29 80        AND #$80
C2/9DB2: D0 0D        BNE $9DC1
C2/9DB4: B9 1B 20     LDA $201B,Y
C2/9DB7: 09 80        ORA #$80
C2/9DB9: 99 1B 20     STA $201B,Y
C2/9DBC: A9 06        LDA #$06
C2/9DBE: 20 2E 9F     JSR $9F2E
C2/9DC1: A5 12        LDA $12
C2/9DC3: 29 20        AND #$20
C2/9DC5: F0 27        BEQ $9DEE
C2/9DC7: A5 12        LDA $12
C2/9DC9: 85 14        STA $14
C2/9DCB: 29 DF        AND #$DF
C2/9DCD: 85 12        STA $12
C2/9DCF: A4 32        LDY $32
C2/9DD1: B9 1B 20     LDA $201B,Y
C2/9DD4: 19 71 20     ORA $2071,Y
C2/9DD7: 29 20        AND #$20
C2/9DD9: D0 13        BNE $9DEE
C2/9DDB: A5 14        LDA $14
C2/9DDD: 29 20        AND #$20
C2/9DDF: 85 14        STA $14
C2/9DE1: B9 1B 20     LDA $201B,Y
C2/9DE4: 05 14        ORA $14
C2/9DE6: 99 1B 20     STA $201B,Y
C2/9DE9: A9 09        LDA #$09
C2/9DEB: 20 2E 9F     JSR $9F2E
C2/9DEE: A5 12        LDA $12
C2/9DF0: 29 04        AND #$04
C2/9DF2: F0 1F        BEQ $9E13
C2/9DF4: A5 12        LDA $12
C2/9DF6: 29 FB        AND #$FB
C2/9DF8: 85 12        STA $12
C2/9DFA: A4 32        LDY $32
C2/9DFC: B9 1B 20     LDA $201B,Y
C2/9DFF: 19 71 20     ORA $2071,Y
C2/9E02: 29 04        AND #$04
C2/9E04: D0 0D        BNE $9E13
C2/9E06: B9 1B 20     LDA $201B,Y
C2/9E09: 09 04        ORA #$04
C2/9E0B: 99 1B 20     STA $201B,Y
C2/9E0E: A9 04        LDA #$04
C2/9E10: 20 2E 9F     JSR $9F2E
C2/9E13: 80 07        BRA $9E1C
C2/9E15: A5 12        LDA $12
C2/9E17: 99 71 20     STA $2071,Y
C2/9E1A: 80 0A        BRA $9E26
C2/9E1C: A4 32        LDY $32
C2/9E1E: B9 1B 20     LDA $201B,Y
C2/9E21: 05 12        ORA $12
C2/9E23: 99 1B 20     STA $201B,Y
C2/9E26: A4 32        LDY $32
C2/9E28: A6 26        LDX $26
C2/9E2A: BF C2 26 D1  LDA $D126C2,X   ; armor status properties byte 2
C2/9E2E: D0 03        BNE $9E33
C2/9E30: 4C BC 9E     JMP $9EBC
C2/9E33: 85 12        STA $12
C2/9E35: A5 13        LDA $13
C2/9E37: D0 72        BNE $9EAB
C2/9E39: A5 12        LDA $12
C2/9E3B: 29 91        AND #$91
C2/9E3D: F0 73        BEQ $9EB2
C2/9E3F: A5 12        LDA $12
C2/9E41: 29 80        AND #$80
C2/9E43: F0 1D        BEQ $9E62
C2/9E45: A5 12        LDA $12
C2/9E47: 29 7F        AND #$7F
C2/9E49: 85 12        STA $12
C2/9E4B: B9 1C 20     LDA $201C,Y
C2/9E4E: 19 72 20     ORA $2072,Y
C2/9E51: 29 80        AND #$80
C2/9E53: D0 0D        BNE $9E62
C2/9E55: B9 1C 20     LDA $201C,Y
C2/9E58: 09 80        ORA #$80
C2/9E5A: 99 1C 20     STA $201C,Y
C2/9E5D: A9 02        LDA #$02
C2/9E5F: 20 2E 9F     JSR $9F2E
C2/9E62: A5 12        LDA $12
C2/9E64: 29 10        AND #$10
C2/9E66: F0 1C        BEQ $9E84
C2/9E68: A5 12        LDA $12
C2/9E6A: 29 EF        AND #$EF
C2/9E6C: 85 12        STA $12
C2/9E6E: A4 32        LDY $32
C2/9E70: B9 1C 20     LDA $201C,Y
C2/9E73: 29 10        AND #$10
C2/9E75: D0 0D        BNE $9E84
C2/9E77: B9 1C 20     LDA $201C,Y
C2/9E7A: 09 10        ORA #$10
C2/9E7C: 99 1C 20     STA $201C,Y
C2/9E7F: A9 00        LDA #$00
C2/9E81: 20 2E 9F     JSR $9F2E
C2/9E84: A5 12        LDA $12
C2/9E86: 29 01        AND #$01
C2/9E88: F0 1F        BEQ $9EA9
C2/9E8A: A5 12        LDA $12
C2/9E8C: 29 FE        AND #$FE
C2/9E8E: 85 12        STA $12
C2/9E90: A4 32        LDY $32
C2/9E92: B9 1C 20     LDA $201C,Y
C2/9E95: 19 72 20     ORA $2072,Y
C2/9E98: 29 01        AND #$01
C2/9E9A: D0 0D        BNE $9EA9
C2/9E9C: B9 1C 20     LDA $201C,Y
C2/9E9F: 09 01        ORA #$01
C2/9EA1: 99 1C 20     STA $201C,Y
C2/9EA4: A9 07        LDA #$07
C2/9EA6: 20 2E 9F     JSR $9F2E
C2/9EA9: 80 07        BRA $9EB2
C2/9EAB: A5 12        LDA $12
C2/9EAD: 99 72 20     STA $2072,Y
C2/9EB0: 80 0A        BRA $9EBC
C2/9EB2: A4 32        LDY $32
C2/9EB4: B9 1C 20     LDA $201C,Y
C2/9EB7: 05 12        ORA $12
C2/9EB9: 99 1C 20     STA $201C,Y
C2/9EBC: A4 32        LDY $32
C2/9EBE: A6 26        LDX $26
C2/9EC0: BF C3 26 D1  LDA $D126C3,X   ; armor status properties byte 3
C2/9EC4: F0 67        BEQ $9F2D
C2/9EC6: 85 12        STA $12
C2/9EC8: A5 13        LDA $13
C2/9ECA: D0 50        BNE $9F1C
C2/9ECC: A5 12        LDA $12
C2/9ECE: 29 18        AND #$18
C2/9ED0: F0 51        BEQ $9F23
C2/9ED2: A5 12        LDA $12
C2/9ED4: 29 10        AND #$10
C2/9ED6: F0 1D        BEQ $9EF5
C2/9ED8: A5 12        LDA $12
C2/9EDA: 29 EF        AND #$EF
C2/9EDC: 85 12        STA $12
C2/9EDE: B9 1D 20     LDA $201D,Y
C2/9EE1: 19 73 20     ORA $2073,Y
C2/9EE4: 29 10        AND #$10
C2/9EE6: D0 0D        BNE $9EF5
C2/9EE8: B9 1D 20     LDA $201D,Y
C2/9EEB: 09 10        ORA #$10
C2/9EED: 99 1D 20     STA $201D,Y
C2/9EF0: A9 03        LDA #$03
C2/9EF2: 20 2E 9F     JSR $9F2E
C2/9EF5: A5 12        LDA $12
C2/9EF7: 29 08        AND #$08
C2/9EF9: F0 1F        BEQ $9F1A
C2/9EFB: A5 12        LDA $12
C2/9EFD: 29 F7        AND #$F7
C2/9EFF: 85 12        STA $12
C2/9F01: A4 32        LDY $32
C2/9F03: B9 1D 20     LDA $201D,Y
C2/9F06: 19 73 20     ORA $2073,Y
C2/9F09: 29 08        AND #$08
C2/9F0B: D0 E8        BNE $9EF5
C2/9F0D: B9 1D 20     LDA $201D,Y
C2/9F10: 09 08        ORA #$08
C2/9F12: 99 1D 20     STA $201D,Y
C2/9F15: A9 05        LDA #$05
C2/9F17: 20 2E 9F     JSR $9F2E
C2/9F1A: 80 07        BRA $9F23
C2/9F1C: A5 12        LDA $12
C2/9F1E: 99 73 20     STA $2073,Y
C2/9F21: 80 0A        BRA $9F2D
C2/9F23: A4 32        LDY $32
C2/9F25: B9 1D 20     LDA $201D,Y
C2/9F28: 05 12        ORA $12
C2/9F2A: 99 1D 20     STA $201D,Y
C2/9F2D: 60           RTS 

; [  ]

C2/9F2E: AA           TAX 
C2/9F2F: A9 01        LDA #$01
C2/9F31: 8D D7 3E     STA $3ED7       ; default timer duration
C2/9F34: AD 7B 7B     LDA $7B7B
C2/9F37: 4C FD 24     JMP $24FD       ; start timer

; [  ]

C2/9F3A: 64 12        STZ $12
C2/9F3C: AD CC 41     LDA $41CC
C2/9F3F: 20 EC 01     JSR $01EC       ; get pointer to character/monster properties
C2/9F42: AD CC 41     LDA $41CC
C2/9F45: 20 B7 01     JSR $01B7       ; a << 2
C2/9F48: 85 0E        STA $0E
C2/9F4A: 0A           ASL 
C2/9F4B: 18           CLC 
C2/9F4C: 65 0E        ADC $0E
C2/9F4E: A8           TAY 
C2/9F4F: B9 AC 37     LDA $37AC,Y
C2/9F52: 85 10        STA $10
C2/9F54: B9 AD 37     LDA $37AD,Y
C2/9F57: 85 11        STA $11
C2/9F59: C5 10        CMP $10
C2/9F5B: B0 0A        BCS $9F67
C2/9F5D: 48           PHA 
C2/9F5E: A5 10        LDA $10
C2/9F60: 85 11        STA $11
C2/9F62: 68           PLA 
C2/9F63: 85 10        STA $10
C2/9F65: E6 12        INC $12
C2/9F67: A5 10        LDA $10
C2/9F69: 05 11        ORA $11
C2/9F6B: D0 0A        BNE $9F77
C2/9F6D: A8           TAY 
C2/9F6E: 84 16        STY $16
C2/9F70: 1A           INC 
C2/9F71: 85 14        STA $14
C2/9F73: 85 15        STA $15
C2/9F75: 80 58        BRA $9FCF
C2/9F77: A5 10        LDA $10
C2/9F79: D0 20        BNE $9F9B
C2/9F7B: A5 11        LDA $11
C2/9F7D: C9 80        CMP #$80
C2/9F7F: B0 0C        BCS $9F8D
C2/9F81: 64 14        STZ $14
C2/9F83: A5 11        LDA $11
C2/9F85: 85 15        STA $15
C2/9F87: 64 16        STZ $16
C2/9F89: 64 17        STZ $17
C2/9F8B: 80 42        BRA $9FCF
C2/9F8D: 7B           TDC 
C2/9F8E: 1A           INC 
C2/9F8F: 85 14        STA $14
C2/9F91: 64 15        STZ $15
C2/9F93: 64 16        STZ $16
C2/9F95: A5 11        LDA $11
C2/9F97: 85 17        STA $17
C2/9F99: 80 34        BRA $9FCF
C2/9F9B: A5 10        LDA $10
C2/9F9D: C9 80        CMP #$80
C2/9F9F: 90 0E        BCC $9FAF
C2/9FA1: 64 14        STZ $14
C2/9FA3: 64 15        STZ $15
C2/9FA5: A5 10        LDA $10
C2/9FA7: 85 16        STA $16
C2/9FA9: A5 11        LDA $11
C2/9FAB: 85 17        STA $17
C2/9FAD: 80 20        BRA $9FCF
C2/9FAF: A5 11        LDA $11
C2/9FB1: C9 80        CMP #$80
C2/9FB3: 90 0E        BCC $9FC3
C2/9FB5: A5 10        LDA $10
C2/9FB7: 85 14        STA $14
C2/9FB9: 64 15        STZ $15
C2/9FBB: 64 16        STZ $16
C2/9FBD: A5 11        LDA $11
C2/9FBF: 85 17        STA $17
C2/9FC1: 80 0C        BRA $9FCF
C2/9FC3: A5 10        LDA $10
C2/9FC5: 85 14        STA $14
C2/9FC7: A5 11        LDA $11
C2/9FC9: 85 15        STA $15
C2/9FCB: 64 16        STZ $16
C2/9FCD: 64 17        STZ $17
C2/9FCF: 20 E7 9F     JSR $9FE7
C2/9FD2: A5 14        LDA $14
C2/9FD4: 9D 13 20     STA $2013,X
C2/9FD7: A5 15        LDA $15
C2/9FD9: 9D 14 20     STA $2014,X
C2/9FDC: A5 16        LDA $16
C2/9FDE: 9D 11 20     STA $2011,X
C2/9FE1: A5 17        LDA $17
C2/9FE3: 9D 12 20     STA $2012,X
C2/9FE6: 60           RTS 

; [  ]

C2/9FE7: A5 12        LDA $12
C2/9FE9: F0 14        BEQ $9FFF
C2/9FEB: A5 14        LDA $14
C2/9FED: 48           PHA 
C2/9FEE: A5 15        LDA $15
C2/9FF0: 85 14        STA $14
C2/9FF2: 68           PLA 
C2/9FF3: 85 15        STA $15
C2/9FF5: A5 16        LDA $16
C2/9FF7: 48           PHA 
C2/9FF8: A5 17        LDA $17
C2/9FFA: 85 16        STA $16
C2/9FFC: 68           PLA 
C2/9FFD: 85 17        STA $17
C2/9FFF: 60           RTS 

; ========================================[ menu ]========================================

; execute menu command
C2/A000: 80 14        BRA $A016

; update joypad config
C2/A002: 20 7D FF     JSR $FF7D       ; update joypad config
C2/A005: 6B           RTL 

; update joypad input (battle)
C2/A006: 80 02        BRA $A00A

; update joypad input (field)
C2/A008: 80 05        BRA $A00F

; [ update joypad input (battle) ]

C2/A00A: 20 56 FF     JSR $FF56
C2/A00D: 80 03        BRA $A012

; [ update joypad input (field) ]

C2/A00F: 20 68 FF     JSR $FF68
C2/A012: 20 5B FE     JSR $FE5B       ; update joypad input
C2/A015: 6B           RTL 

; [ execute menu command ]

C2/A016: 20 1B A1     JSR $A11B       ; init menu
C2/A019: 64 39        STZ $39
C2/A01B: A5 34        LDA $34         ; menu command
C2/A01D: 29 07 00     AND #$0007
C2/A020: 0A           ASL 
C2/A021: AA           TAX 
C2/A022: BF 00 E6 C0  LDA $C0E600,X
C2/A026: 85 C7        STA $C7
C2/A028: E2 20        SEP #$20
C2/A02A: 6C C7 01     JMP ($01C7)

; menu command jump table
; C0/E600:              .DW $A033, $A03B, $A03F, $A043, $A053, $A069, $A062

; exit menu
C2/A02D: 20 BD B2     JSR $B2BD
C2/A030: E2 20        SEP #$20
C2/A032: 6B           RTL 

; [ menu command $00: main menu ]

C2/A033: A5 35        LDA $35
C2/A035: 85 44        STA $44
C2/A037: A9 01        LDA #$01
C2/A039: 80 30        BRA $A06B       ; show menu

; [ menu command $01: collect items after battle ]

C2/A03B: A9 0A        LDA #$0A
C2/A03D: 80 2C        BRA $A06B       ; show menu

; [ menu command $02: shop ]

C2/A03F: A9 06        LDA #$06
C2/A041: 80 28        BRA $A06B       ; show menu

; [ menu command $03: init menu settings ]

C2/A043: 20 F0 A1     JSR $A1F0       ; init config settings
C2/A046: 20 7D FF     JSR $FF7D       ; update joypad config
C2/A049: 20 47 D4     JSR $D447       ; update window color
C2/A04C: 20 A9 F5     JSR $F5A9       ; update mono/stereo setting
C2/A04F: A9 0C        LDA #$0C
C2/A051: 80 18        BRA $A06B       ; show menu

; [ menu command $04: tutorial ]

C2/A053: A9 80        LDA #$80
C2/A055: 04 45        TSB $45         ; enable tutorial mode
C2/A057: 64 49        STZ $49         ; clear pause counter
C2/A059: 64 4A        STZ $4A
C2/A05B: 20 94 A3     JSR $A394       ; init tutorial script
C2/A05E: A9 01        LDA #$01
C2/A060: 80 09        BRA $A06B       ; show menu

; [ menu command $06: transfer galuf's stats to krile ]

C2/A062: 64 35        STZ $35
C2/A064: 20 58 D9     JSR $D958
C2/A067: 80 C7        BRA $A030

; [ menu command $05: name change ]

C2/A069: A9 0D        LDA #$0D

; [ show menu ]

C2/A06B: E2 20        SEP #$20
C2/A06D: 85 43        STA $43         ; menu state
C2/A06F: A9 7E        LDA #$7E
C2/A071: 48           PHA 
C2/A072: AB           PLB 
C2/A073: C2 20        REP #$20
C2/A075: 20 6A C1     JSR $C16A       ; load tilemap/???/cursor data
C2/A078: 20 6E A1     JSR $A16E       ; reset sprite data
C2/A07B: A5 43        LDA $43         ; menu state
C2/A07D: 29 FF 00     AND #$00FF
C2/A080: 3A           DEC 
C2/A081: 0A           ASL 
C2/A082: AA           TAX 
C2/A083: BF 0E E6 C0  LDA $C0E60E,X
C2/A087: 85 C7        STA $C7
C2/A089: 62 02 00     PER $A08E
C2/A08C: 6C C7 01     JMP ($01C7)

; menu state jump table
; C0/E60E:            .DW $CFDC, $CEEC, $CCCB, $CA37, $C8A0, $C803, $C6F7, $C5C8
; C0/E61E:            .DW $C34A, $C36F, $C5B9, $C56B, $C442, $A4F0, $A36A, $A378
; C0/E62E:            .DW $A45E, $A466, $A46E, $A476, $A358, $A441

C2/A08F: C2 20        REP #$20
C2/A091: A5 43        LDA $43         ; menu state
C2/A093: 29 FF 00     AND #$00FF
C2/A096: C9 0C 00     CMP #$000C
C2/A099: D0 07        BNE $A0A2
C2/A09B: A5 39        LDA $39
C2/A09D: D0 03        BNE $A0A2
C2/A09F: 4C 30 A0     JMP $A030
C2/A0A2: E2 20        SEP #$20
C2/A0A4: A9 00        LDA #$00
C2/A0A6: 48           PHA 
C2/A0A7: AB           PLB 
C2/A0A8: 9C 21 21     STZ $2121
C2/A0AB: C2 20        REP #$20
C2/A0AD: 9C 02 21     STZ $2102
C2/A0B0: 9C 16 21     STZ $2116
C2/A0B3: A2 B2 F5     LDX #$F5B2      ; 02 04 00 02 00 20 02 (sprite data)
C2/A0B6: 20 F6 A0     JSR $A0F6
C2/A0B9: A2 B9 F5     LDX #$F5B9      ; 02 22 00 73 7E 00 02 (color palettes)
C2/A0BC: 20 F6 A0     JSR $A0F6
C2/A0BF: A2 8B F5     LDX #$F58B      ; 01 18 00 30 7E 00 40 (vram)
C2/A0C2: 20 F6 A0     JSR $A0F6
C2/A0C5: E2 20        SEP #$20
C2/A0C7: A9 04        LDA #$04
C2/A0C9: 85 CA        STA $CA
C2/A0CB: A9 00        LDA #$00
C2/A0CD: 8F 11 75 7E  STA $7E7511
C2/A0D1: 20 06 A1     JSR $A106       ; wait for vblank
C2/A0D4: AF 0E 75 7E  LDA $7E750E
C2/A0D8: 8D 0C 42     STA $420C
C2/A0DB: AD 10 42     LDA $4210
C2/A0DE: A9 81        LDA #$81
C2/A0E0: 8D 00 42     STA $4200
C2/A0E3: A9 00        LDA #$00
C2/A0E5: 8F 22 75 7E  STA $7E7522
C2/A0E9: 8F 25 75 7E  STA $7E7525
C2/A0ED: A9 03        LDA #$03
C2/A0EF: 8F 13 75 7E  STA $7E7513
C2/A0F3: 4C E9 A2     JMP $A2E9       ; get next input

; [ dma ]

; +X: address of dma parameters (+$C00000)

C2/A0F6: A0 00 43     LDY #$4300
C2/A0F9: A9 06 00     LDA #$0006
C2/A0FC: 54 00 C0     MVN $00, $C0
C2/A0FF: A9 01 00     LDA #$0001
C2/A102: 8D 0B 42     STA $420B
C2/A105: 60           RTS 

; [ wait for vblank ]

C2/A106: 08           PHP 
C2/A107: E2 20        SEP #$20
C2/A109: AF 10 42 00  LDA $004210
C2/A10D: 30 FA        BMI $A109
C2/A10F: AF 10 42 00  LDA $004210
C2/A113: 10 FA        BPL $A10F
C2/A115: AF 10 42 00  LDA $004210
C2/A119: 28           PLP 
C2/A11A: 60           RTS 

; [ init menu ]

C2/A11B: C2 30        REP #$30
C2/A11D: A9 00 01     LDA #$0100      ; set direct page to $0100
C2/A120: 5B           TCD 
C2/A121: A2 33 F5     LDX #$F533      ; copy interrupt jump code
C2/A124: A0 00 1F     LDY #$1F00
C2/A127: A9 07 00     LDA #$0007
C2/A12A: 54 7E C0     MVN $7E,$C0
C2/A12D: 64 8E        STZ $8E
C2/A12F: E2 20        SEP #$20
C2/A131: A9 80        LDA #$80
C2/A133: 8F 00 21 00  STA $002100
C2/A137: 64 44        STZ $44
C2/A139: 64 45        STZ $45
C2/A13B: 64 46        STZ $46
C2/A13D: 64 47        STZ $47
C2/A13F: 64 48        STZ $48
C2/A141: 20 8A A1     JSR $A18A
C2/A144: 20 30 D2     JSR $D230
C2/A147: 20 7B D3     JSR $D37B
C2/A14A: 20 DB D3     JSR $D3DB
C2/A14D: 20 47 A2     JSR $A247
C2/A150: 20 CF A1     JSR $A1CF
C2/A153: 20 7D FF     JSR $FF7D       ; update joypad config
C2/A156: 20 47 D4     JSR $D447       ; update window color
C2/A159: 20 A9 F5     JSR $F5A9       ; update mono/stereo setting
C2/A15C: 20 6E A1     JSR $A16E       ; reset sprite data
C2/A15F: C2 20        REP #$20
C2/A161: A2 73 F5     LDX #$F573
C2/A164: A0 0F 75     LDY #$750F
C2/A167: A9 17 00     LDA #$0017
C2/A16A: 54 7E C0     MVN $7E,$C0
C2/A16D: 60           RTS 

; [ reset sprite data ]

C2/A16E: 08           PHP 
C2/A16F: C2 20        REP #$20
C2/A171: A2 20 02     LDX #$0220
C2/A174: 9E FE 01     STZ $01FE,X
C2/A177: CA           DEX 
C2/A178: CA           DEX 
C2/A179: D0 F9        BNE $A174
C2/A17B: A2 20 00     LDX #$0020
C2/A17E: A9 AA AA     LDA #$AAAA
C2/A181: 9D FE 03     STA $03FE,X
C2/A184: CA           DEX 
C2/A185: CA           DEX 
C2/A186: D0 F9        BNE $A181
C2/A188: 28           PLP 
C2/A189: 60           RTS 

; [  ]

C2/A18A: 8B           PHB 
C2/A18B: 08           PHP 
C2/A18C: E2 20        SEP #$20
C2/A18E: A9 00        LDA #$00
C2/A190: 48           PHA 
C2/A191: AB           PLB 
C2/A192: A9 01        LDA #$01
C2/A194: 8D 00 42     STA $4200
C2/A197: A9 01        LDA #$01
C2/A199: 8D 01 21     STA $2101
C2/A19C: A9 00        LDA #$00        ; mode 0
C2/A19E: 8D 05 21     STA $2105
C2/A1A1: 8D 06 21     STA $2106
C2/A1A4: A9 80        LDA #$80
C2/A1A6: 8D 15 21     STA $2115
C2/A1A9: A2 08 00     LDX #$0008
C2/A1AC: 9E 0C 21     STZ $210C,X
C2/A1AF: 9E 0C 21     STZ $210C,X
C2/A1B2: CA           DEX 
C2/A1B3: D0 F7        BNE $A1AC
C2/A1B5: C2 20        REP #$20
C2/A1B7: A2 3B F5     LDX #$F53B
C2/A1BA: A0 07 21     LDY #$2107
C2/A1BD: A9 05 00     LDA #$0005
C2/A1C0: 54 00 C0     MVN $00,$C0
C2/A1C3: A0 2C 21     LDY #$212C
C2/A1C6: A9 05 00     LDA #$0005
C2/A1C9: 54 00 C0     MVN $00,$C0
C2/A1CC: 28           PLP 
C2/A1CD: AB           PLB 
C2/A1CE: 60           RTS 
C2/A1CF: 8B           PHB 
C2/A1D0: 08           PHP 
C2/A1D1: C2 20        REP #$20
C2/A1D3: A5 8E        LDA $8E
C2/A1D5: 8F 0C 42 00  STA $00420C
C2/A1D9: A2 47 F5     LDX #$F547
C2/A1DC: BF 00 00 C0  LDA $C00000,X
C2/A1E0: F0 0B        BEQ $A1ED
C2/A1E2: A8           TAY 
C2/A1E3: E8           INX 
C2/A1E4: E8           INX 
C2/A1E5: A9 04 00     LDA #$0004
C2/A1E8: 54 00 C0     MVN $00,$C0
C2/A1EB: 80 EF        BRA $A1DC
C2/A1ED: 28           PLP 
C2/A1EE: AB           PLB 
C2/A1EF: 60           RTS 

; [ init config settings ]

C2/A1F0: 8B           PHB 
C2/A1F1: 08           PHP 
C2/A1F2: C2 20        REP #$20
C2/A1F4: A2 42 F3     LDX #$F342      ; C0/F342 (default config settings)
C2/A1F7: A0 70 09     LDY #$0970
C2/A1FA: A9 1F 00     LDA #$001F
C2/A1FD: 54 00 C0     MVN $00,$C0
C2/A200: A9 00 01     LDA #$0100      ; set character cursor positions
C2/A203: 8D 2D 04     STA $042D
C2/A206: A9 02 03     LDA #$0302
C2/A209: 8D 2F 04     STA $042F
C2/A20C: E2 20        SEP #$20
C2/A20E: 64 59        STZ $59         ; 
C2/A210: 64 5D        STZ $5D
C2/A212: 64 5F        STZ $5F
C2/A214: 64 61        STZ $61
C2/A216: 64 62        STZ $62
C2/A218: 64 5E        STZ $5E
C2/A21A: 64 5C        STZ $5C
C2/A21C: 64 5B        STZ $5B
C2/A21E: A9 02        LDA #$02
C2/A220: 85 60        STA $60
C2/A222: A9 08        LDA #$08
C2/A224: 85 5A        STA $5A
C2/A226: 64 63        STZ $63
C2/A228: 64 64        STZ $64
C2/A22A: 64 65        STZ $65
C2/A22C: 64 66        STZ $66
C2/A22E: A9 07        LDA #$07
C2/A230: 85 67        STA $67
C2/A232: 85 68        STA $68
C2/A234: 85 69        STA $69
C2/A236: 85 6A        STA $6A
C2/A238: 28           PLP 
C2/A239: AB           PLB 
C2/A23A: 60           RTS 

C2/A23B: 91 E0        STA ($E0),Y
C2/A23D: 18           CLC 
C2/A23E: 65 E4        ADC $E4
C2/A240: C8           INY 
C2/A241: C8           INY 
C2/A242: C4 E2        CPY $E2
C2/A244: D0 F5        BNE $A23B
C2/A246: 60           RTS 

; [ init rom data pointers (data in bank $D1) ]

C2/A247: 08           PHP 
C2/A248: C2 20        REP #$20
C2/A24A: A2 00 D0     LDX #$D000
C2/A24D: 86 E0        STX $E0
C2/A24F: A2 00 01     LDX #$0100
C2/A252: 86 E2        STX $E2
C2/A254: A2 0C 00     LDX #$000C
C2/A257: 86 E4        STX $E4
C2/A259: A4 8E        LDY $8E
C2/A25B: A9 00 00     LDA #$0000
C2/A25E: 20 3B A2     JSR $A23B
C2/A261: A2 C0 01     LDX #$01C0
C2/A264: 86 E2        STX $E2
C2/A266: A9 00 06     LDA #$0600
C2/A269: 20 3B A2     JSR $A23B
C2/A26C: A2 08 00     LDX #$0008
C2/A26F: 86 E4        STX $E4
C2/A271: A2 00 02     LDX #$0200
C2/A274: 86 E2        STX $E2
C2/A276: A9 80 0A     LDA #$0A80
C2/A279: 20 3B A2     JSR $A23B
C2/A27C: A2 00 D2     LDX #$D200
C2/A27F: 86 E0        STX $E0
C2/A281: A2 09 00     LDX #$0009
C2/A284: 86 E4        STX $E4
C2/A286: A4 8E        LDY $8E
C2/A288: A9 80 13     LDA #$1380      ; D1/1380 (item names)
C2/A28B: 20 3B A2     JSR $A23B
C2/A28E: A2 00 D4     LDX #$D400
C2/A291: 86 E0        STX $E0
C2/A293: A2 AE 00     LDX #$00AE
C2/A296: 86 E2        STX $E2
C2/A298: A2 06 00     LDX #$0006
C2/A29B: 86 E4        STX $E4
C2/A29D: A4 8E        LDY $8E
C2/A29F: A9 80 1C     LDA #$1C80      ; D1/1C80 (spell names)
C2/A2A2: 20 3B A2     JSR $A23B
C2/A2A5: A2 00 02     LDX #$0200
C2/A2A8: 86 E2        STX $E2
C2/A2AA: A2 09 00     LDX #$0009
C2/A2AD: 86 E4        STX $E4
C2/A2AF: 20 3B A2     JSR $A23B
C2/A2B2: A2 00 D6     LDX #$D600
C2/A2B5: 86 E0        STX $E0
C2/A2B7: A2 A2 00     LDX #$00A2
C2/A2BA: 86 E2        STX $E2
C2/A2BC: A2 05 00     LDX #$0005
C2/A2BF: 86 E4        STX $E4
C2/A2C1: A4 8E        LDY $8E
C2/A2C3: A9 00 58     LDA #$5800
C2/A2C6: 20 3B A2     JSR $A23B
C2/A2C9: A2 00 01     LDX #$0100
C2/A2CC: 86 E2        STX $E2
C2/A2CE: A6 8E        LDX $8E
C2/A2D0: 64 E4        STZ $E4
C2/A2D2: A5 8E        LDA $8E
C2/A2D4: 20 3B A2     JSR $A23B
C2/A2D7: A2 42 01     LDX #$0142
C2/A2DA: 86 E2        STX $E2
C2/A2DC: A2 08 00     LDX #$0008
C2/A2DF: 86 E4        STX $E4
C2/A2E1: A9 00 62     LDA #$6200
C2/A2E4: 20 3B A2     JSR $A23B
C2/A2E7: 28           PLP 
C2/A2E8: 60           RTS 

; [ get next input ]

C2/A2E9: E2 20        SEP #$20
C2/A2EB: C2 10        REP #$10
C2/A2ED: 20 6F E6     JSR $E66F
C2/A2F0: 20 2F FC     JSR $FC2F
C2/A2F3: F4 7E 7E     PEA $7E7E
C2/A2F6: AB           PLB 
C2/A2F7: AB           PLB 
C2/A2F8: 24 45        BIT $45
C2/A2FA: 30 05        BMI $A301       ; branch if in tutorial mode
C2/A2FC: 20 3A A3     JSR $A33A       ; get pressed button index
C2/A2FF: 80 1F        BRA $A320
C2/A301: A6 49        LDX $49         ; decrement pause counter
C2/A303: 30 07        BMI $A30C
C2/A305: CA           DEX 
C2/A306: 86 49        STX $49
C2/A308: A5 8E        LDA $8E
C2/A30A: 80 14        BRA $A320
C2/A30C: A5 48        LDA $48
C2/A30E: D0 04        BNE $A314       ; branch if tutorial script pointer is valid
C2/A310: A9 08        LDA #$08        ; exit menu
C2/A312: 80 0C        BRA $A320
C2/A314: A7 46        LDA [$46]       ; tutorial script
C2/A316: A6 46        LDX $46
C2/A318: E8           INX 
C2/A319: 86 46        STX $46
C2/A31B: A2 0F 00     LDX #$000F
C2/A31E: 86 49        STX $49
C2/A320: 85 4B        STA $4B
C2/A322: 89 10        BIT #$10
C2/A324: F0 02        BEQ $A328       ; branch if not a pause
C2/A326: A9 07        LDA #$07        ; use pause command
C2/A328: C2 20        REP #$20
C2/A32A: 29 0F 00     AND #$000F
C2/A32D: 0A           ASL 
C2/A32E: AA           TAX 
C2/A32F: BF 28 E6 C0  LDA $C0E628,X
C2/A333: 85 C7        STA $C7
C2/A335: E2 20        SEP #$20
C2/A337: 6C C7 01     JMP ($01C7)

; button jump table (nothing, A, B, up, down, left, right, pause, exit menu)
; C0/E628:            .DW $A4F0, $A36A, $A378, $A45E, $A466, $A46E, $A476, $A358, $A441 

; [ get pressed button index ]

C2/A33A: 08           PHP 
C2/A33B: C2 20        REP #$20
C2/A33D: A6 8E        LDX $8E
C2/A33F: A5 0A        LDA $0A         ; buttons pressed
C2/A341: 3F D2 E7 C0  AND $C0E7D2,X   ; button mask
C2/A345: D0 08        BNE $A34F       ; branch if buttons are pressed
C2/A347: E8           INX             ; next button
C2/A348: E8           INX 
C2/A349: E8           INX 
C2/A34A: E0 12 00     CPX #$0012
C2/A34D: D0 F0        BNE $A33F
C2/A34F: BF D4 E7 C0  LDA $C0E7D4,X   ; button index
C2/A353: 29 FF 00     AND #$00FF
C2/A356: 28           PLP 
C2/A357: 60           RTS 

; C0/E7D2:            .DB $80, $00, $01
; C0/E7D5:            .DB $00, $80, $02
; C0/E7D8:            .DB $00, $08, $03
; C0/E7DB:            .DB $00, $04, $04
; C0/E7DE:            .DB $00, $02, $05
; C0/E7F1:            .DB $00, $01, $06
; C0/E7F4:            .DB $00, $00, $00

; [ menu state $14: pause (tutorial) ]

C2/A358: A5 4B        LDA $4B
C2/A35A: C2 20        REP #$20
C2/A35C: 29 0F 00     AND #$000F
C2/A35F: 0A           ASL 
C2/A360: AA           TAX 
C2/A361: BF 92 F5 C0  LDA $C0F592,X   ; pause duration
C2/A365: 85 49        STA $49
C2/A367: 4C F0 A4     JMP $A4F0

; [ menu state $0E: A button pressed ]

C2/A36A: 20 B0 E0     JSR $E0B0
C2/A36D: A5 54        LDA $54
C2/A36F: C2 20        REP #$20
C2/A371: 29 7F 00     AND #$007F
C2/A374: 0A           ASL 
C2/A375: 0A           ASL 
C2/A376: 80 0E        BRA $A386

; [ menu state $0F: B button pressed ]

C2/A378: 20 B8 E0     JSR $E0B8       ; play sound effect
C2/A37B: A5 54        LDA $54
C2/A37D: C2 20        REP #$20
C2/A37F: 29 7F 00     AND #$007F
C2/A382: 0A           ASL 
C2/A383: 0A           ASL 
C2/A384: 1A           INC 
C2/A385: 1A           INC 
C2/A386: AA           TAX 
C2/A387: BF 24 E7 C0  LDA $C0E724,X
C2/A38B: 85 C7        STA $C7
C2/A38D: A5 8E        LDA $8E
C2/A38F: E2 20        SEP #$20
C2/A391: 6C C7 01     JMP ($01C7)

; A/B button jump table
; C0/E724:            .DW $B25B, $B25B, $B25E, $B2FB, $B302, $B40C, $B429, $B480 
; C0/E734:            .DW $B48F, $B4A8, $B4D7, $B511, $B521, $B5EA, $B6B9, $B74B 
; C0/E744:            .DW $B752, $B796, $B7AD, $B7FC, $B811, $B845, $B84D, $B879 
; C0/E754:            .DW $B8AE, $B91D, $B955, $B993, $B998, $BA05, $BA0A, $BA63 
; C0/E764:            .DW $BA7D, $BBFA, $BC27, $BC2A, $BC2D, $BC48, $BC5E, $BCD9 
; C0/E774:            .DW $BCD9, $BCD9, $BCD9, $BCD9, $BCE0, $BD3D, $BD47, $BDB5 
; C0/E784:            .DW $BDC6, $BDF3, $BDF6, $BE2E, $BE64, $BEC8, $BECD, $BEF4 
; C0/E794:            .DW $BF2E, $BF89, $BF9D, $BFCD, $BFD4, $BFF4, $C003, $C041 
; C0/E7A4:            .DW $C046, $C05E, $C069, $C06C, $C071, $C0BD, $C0F7, $C146 
; C0/E7B4:            .DW $C162, $C162 

; [ init tutorial script ]

C2/A394: 08           PHP 
C2/A395: C2 20        REP #$20
C2/A397: A2 00 05     LDX #$0500      ; copy sram data to $7E2000 ($0600 bytes)
C2/A39A: A0 00 20     LDY #$2000
C2/A39D: A9 FF 05     LDA #$05FF
C2/A3A0: 54 7E 7E     MVN $7E,$7E
C2/A3A3: A2 59 01     LDX #$0159      ; copy $12 bytes from $0159 to $7E2600 (cursor memory positions ???)
C2/A3A6: A0 00 26     LDY #$2600
C2/A3A9: A9 11 00     LDA #$0011
C2/A3AC: 54 7E 7E     MVN $7E,$7E
C2/A3AF: A5 35        LDA $35         ; tutorial index
C2/A3B1: 29 07 00     AND #$0007
C2/A3B4: 0A           ASL 
C2/A3B5: 0A           ASL 
C2/A3B6: AA           TAX 
C2/A3B7: BF 41 E8 C0  LDA $C0E841,X   ; pointer to tutorial script
C2/A3BB: 85 46        STA $46
C2/A3BD: BF 43 E8 C0  LDA $C0E843,X
C2/A3C1: E2 20        SEP #$20
C2/A3C3: 85 48        STA $48
C2/A3C5: EB           XBA             ; tutorial flags
C2/A3C6: 29 0F        AND #$0F
C2/A3C8: 04 45        TSB $45
C2/A3CA: C2 20        REP #$20
C2/A3CC: A2 DF E8     LDX #$E8DF      ; set available abilities for tutorial
C2/A3CF: A0 F7 08     LDY #$08F7      ; copy 20 bytes from $C0E8DF -> $7E08F7
C2/A3D2: A9 13 00     LDA #$0013
C2/A3D5: 54 7E C0     MVN $7E,$C0
C2/A3D8: E2 20        SEP #$20
C2/A3DA: A9 E0        LDA #$E0        ; set available jobs for tutorial
C2/A3DC: 8D 40 08     STA $0840
C2/A3DF: A9 64        LDA #$64
C2/A3E1: 8D 41 08     STA $0841
C2/A3E4: A9 04        LDA #$04
C2/A3E6: 8D 42 08     STA $0842
C2/A3E9: A9 05        LDA #$05
C2/A3EB: 1C 73 09     TRB $0973
C2/A3EE: A9 06        LDA #$06
C2/A3F0: 8D F3 08     STA $08F3
C2/A3F3: A9 40        LDA #$40
C2/A3F5: 1C 00 05     TRB $0500
C2/A3F8: 9C 1A 05     STZ $051A
C2/A3FB: A6 8E        LDX $8E
C2/A3FD: BF F8 E8 C0  LDA $C0E8F8,X   ; 
C2/A401: F0 0C        BEQ $A40F
C2/A403: EB           XBA 
C2/A404: A9 01        LDA #$01
C2/A406: EB           XBA 
C2/A407: DA           PHX 
C2/A408: 20 CE E2     JSR $E2CE
C2/A40B: FA           PLX 
C2/A40C: E8           INX 
C2/A40D: 80 EE        BRA $A3FD
C2/A40F: 64 7E        STZ $7E
C2/A411: 20 C5 D4     JSR $D4C5
C2/A414: 20 A4 DA     JSR $DAA4
C2/A417: C2 20        REP #$20
C2/A419: A5 35        LDA $35
C2/A41B: 29 07 00     AND #$0007
C2/A41E: AA           TAX 
C2/A41F: E2 20        SEP #$20
C2/A421: BF F0 E8 C0  LDA $C0E8F0,X   ; 
C2/A425: 85 D8        STA $D8
C2/A427: 20 7D E4     JSR $E47D
C2/A42A: A5 DA        LDA $DA
C2/A42C: 8D 3A 05     STA $053A
C2/A42F: A5 D8        LDA $D8
C2/A431: 8D 01 05     STA $0501
C2/A434: A6 DC        LDX $DC
C2/A436: 8E 3B 05     STX $053B
C2/A439: 20 82 EB     JSR $EB82
C2/A43C: 20 D6 E6     JSR $E6D6
C2/A43F: 28           PLP 
C2/A440: 60           RTS 

; [ menu state $15: exit menu (tutorial) ]

C2/A441: C2 20        REP #$20
C2/A443: A2 00 20     LDX #$2000      ; restore sram data
C2/A446: A0 00 05     LDY #$0500
C2/A449: A9 FF 05     LDA #$05FF
C2/A44C: 54 7E 7E     MVN $7E,$7E
C2/A44F: A2 00 26     LDX #$2600
C2/A452: A0 59 01     LDY #$0159
C2/A455: A9 11 00     LDA #$0011
C2/A458: 54 7E 7E     MVN $7E,$7E
C2/A45B: 4C 2D A0     JMP $A02D       ; exit menu

; [ menu state $10: move cursor up ]

C2/A45E: 20 DF E4     JSR $E4DF       ; get pointer to current cursor data
C2/A461: BD 04 76     LDA $7604,X
C2/A464: 80 16        BRA $A47C

; [ menu state $11: move cursor down ]

C2/A466: 20 DF E4     JSR $E4DF       ; get pointer to current cursor data
C2/A469: BD 05 76     LDA $7605,X
C2/A46C: 80 0E        BRA $A47C

; [ menu state $12: move cursor left ]

C2/A46E: 20 DF E4     JSR $E4DF       ; get pointer to current cursor data
C2/A471: BD 06 76     LDA $7606,X
C2/A474: 80 06        BRA $A47C

; [ menu state $13: move cursor right ]

C2/A476: 20 DF E4     JSR $E4DF       ; get pointer to current cursor data
C2/A479: BD 07 76     LDA $7607,X
C2/A47C: F4 7E 7E     PEA $7E7E
C2/A47F: AB           PLB 
C2/A480: AB           PLB 
C2/A481: 20 A8 E0     JSR $E0A8       ; play sound effect
C2/A484: E2 20        SEP #$20
C2/A486: 64 4F        STZ $4F
C2/A488: 85 56        STA $56         ; target cursor position
C2/A48A: 20 E1 E4     JSR $E4E1       ; get pointer to cursor data
C2/A48D: BD 01 76     LDA $7601,X
C2/A490: 85 58        STA $58
C2/A492: BD 00 76     LDA $7600,X
C2/A495: 85 57        STA $57
C2/A497: 30 22        BMI $A4BB
C2/A499: C5 54        CMP $54
C2/A49B: F0 04        BEQ $A4A1
C2/A49D: A9 40        LDA #$40
C2/A49F: 04 4F        TSB $4F
C2/A4A1: A5 53        LDA $53
C2/A4A3: 85 50        STA $50
C2/A4A5: A5 54        LDA $54
C2/A4A7: 85 51        STA $51
C2/A4A9: A5 55        LDA $55
C2/A4AB: 85 52        STA $52
C2/A4AD: A5 56        LDA $56
C2/A4AF: 85 53        STA $53
C2/A4B1: A5 57        LDA $57
C2/A4B3: 85 54        STA $54
C2/A4B5: A5 58        LDA $58
C2/A4B7: 85 55        STA $55
C2/A4B9: 80 04        BRA $A4BF
C2/A4BB: A9 80        LDA #$80
C2/A4BD: 04 4F        TSB $4F
C2/A4BF: 24 4F        BIT $4F
C2/A4C1: 30 04        BMI $A4C7
C2/A4C3: 70 0C        BVS $A4D1
C2/A4C5: 80 1E        BRA $A4E5
C2/A4C7: A2 3A E6     LDX #$E63A
C2/A4CA: A5 57        LDA $57
C2/A4CC: 20 F3 A4     JSR $A4F3
C2/A4CF: 80 14        BRA $A4E5
C2/A4D1: A2 AF E6     LDX #$E6AF
C2/A4D4: A5 51        LDA $51
C2/A4D6: 20 F3 A4     JSR $A4F3
C2/A4D9: 24 4F        BIT $4F
C2/A4DB: 50 08        BVC $A4E5
C2/A4DD: A2 52 E6     LDX #$E652
C2/A4E0: A5 54        LDA $54
C2/A4E2: 20 F3 A4     JSR $A4F3
C2/A4E5: A2 E8 E6     LDX #$E6E8
C2/A4E8: A5 54        LDA $54
C2/A4EA: 20 F3 A4     JSR $A4F3
C2/A4ED: 20 AB E6     JSR $E6AB       ; update cursor sprite
; fall through

; [ menu state $0D: name change ]

C2/A4F0: 4C E9 A2     JMP $A2E9       ; get next input

; [  ]

C2/A4F3: E2 20        SEP #$20
C2/A4F5: 85 E0        STA $E0
C2/A4F7: A4 8E        LDY $8E
C2/A4F9: BF 00 00 C0  LDA $C00000,X
C2/A4FD: F0 17        BEQ $A516
C2/A4FF: C5 E0        CMP $E0
C2/A501: F0 05        BEQ $A508
C2/A503: E8           INX 
C2/A504: E8           INX 
C2/A505: E8           INX 
C2/A506: 80 F1        BRA $A4F9
C2/A508: C2 20        REP #$20
C2/A50A: BF 01 00 C0  LDA $C00001,X
C2/A50E: 85 C7        STA $C7
C2/A510: 62 02 00     PER $A515
C2/A513: 6C C7 01     JMP ($01C7)
C2/A516: E2 20        SEP #$20
C2/A518: 60           RTS 

; [  ]

C2/A519: 20 5F A5     JSR $A55F
C2/A51C: B0 2B        BCS $A549
C2/A51E: A4 8E        LDY $8E
C2/A520: B9 AC 29     LDA $29AC,Y
C2/A523: 18           CLC 
C2/A524: 65 6B        ADC $6B
C2/A526: AA           TAX 
C2/A527: BD 00 7A     LDA $7A00,X
C2/A52A: 29 FF        AND #$FF
C2/A52C: 00 BE        BRK $BE
C2/A52E: B0 29        BCS $A559
C2/A530: 20 E4 D8     JSR $D8E4
C2/A533: C8           INY 
C2/A534: C8           INY 
C2/A535: C0 04 00     CPY #$0004
C2/A538: D0 E6        BNE $A520
C2/A53A: 20 67 E3     JSR $E367
C2/A53D: 20 05 FE     JSR $FE05
C2/A540: 20 6F E6     JSR $E66F
C2/A543: 20 2F FC     JSR $FC2F
C2/A546: 20 4A A5     JSR $A54A
C2/A549: 60           RTS 
C2/A54A: E2 20        SEP #$20
C2/A54C: A5 58        LDA $58
C2/A54E: C9 03        CMP #$03
C2/A550: 30 0C        BMI $A55E
C2/A552: 4A           LSR 
C2/A553: 29 02        AND #$02
C2/A555: 3A           DEC 
C2/A556: 18           CLC 
C2/A557: 65 53        ADC $53
C2/A559: 85 53        STA $53
C2/A55B: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A55E: 60           RTS 

; [  ]

C2/A55F: E2 20        SEP #$20
C2/A561: AD 12 75     LDA $7512
C2/A564: D0 4D        BNE $A5B3
C2/A566: C2 20        REP #$20
C2/A568: A5 58        LDA $58
C2/A56A: 29 07 00     AND #$0007
C2/A56D: 3A           DEC 
C2/A56E: 29 01 00     AND #$0001
C2/A571: 0A           ASL 
C2/A572: A8           TAY 
C2/A573: BE 8A 29     LDX $298A,Y
C2/A576: A0 A0 29     LDY #$29A0
C2/A579: A9 15 00     LDA #$0015
C2/A57C: 54 7E C0     MVN $7E,$C0
C2/A57F: A5 6B        LDA $6B
C2/A581: 18           CLC 
C2/A582: 6D A0 29     ADC $29A0
C2/A585: 30 2C        BMI $A5B3
C2/A587: C5 6D        CMP $6D
C2/A589: F0 02        BEQ $A58D
C2/A58B: B0 26        BCS $A5B3
C2/A58D: 85 6B        STA $6B
C2/A58F: E2 20        SEP #$20
C2/A591: A9 01        LDA #$01
C2/A593: 8D 12 75     STA $7512
C2/A596: 9C 28 75     STZ $7528
C2/A599: C2 20        REP #$20
C2/A59B: AE A6 29     LDX $29A6
C2/A59E: AC A8 29     LDY $29A8
C2/A5A1: AD AA 29     LDA $29AA
C2/A5A4: 10 08        BPL $A5AE
C2/A5A6: 29 FF 7F     AND #$7FFF
C2/A5A9: 54 7E 7E     MVN $7E,$7E
C2/A5AC: 80 03        BRA $A5B1
C2/A5AE: 44 7E 7E     MVP $7E,$7E
C2/A5B1: 18           CLC 
C2/A5B2: 60           RTS 
C2/A5B3: 38           SEC 
C2/A5B4: 60           RTS 

; [ job menu, at first job, pressed left, go to last job ]

C2/A5B5: E2 20        SEP #$20
C2/A5B7: A5 6F        LDA $6F
C2/A5B9: D0 26        BNE $A5E1
C2/A5BB: A5 53        LDA $53
C2/A5BD: 85 50        STA $50
C2/A5BF: A5 54        LDA $54
C2/A5C1: 85 51        STA $51
C2/A5C3: A5 55        LDA $55
C2/A5C5: 85 52        STA $52
C2/A5C7: A6 8E        LDX $8E
C2/A5C9: BD 00 7A     LDA $7A00,X     ; find the last available job
C2/A5CC: 30 08        BMI $A5D6
C2/A5CE: E8           INX 
C2/A5CF: E0 17 00     CPX #$0017
C2/A5D2: 10 08        BPL $A5DC
C2/A5D4: 80 F3        BRA $A5C9
C2/A5D6: CA           DEX 
C2/A5D7: 8A           TXA 
C2/A5D8: 29 1F        AND #$1F
C2/A5DA: 85 53        STA $53
C2/A5DC: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A5DF: 80 04        BRA $A5E5
C2/A5E1: A5 53        LDA $53
C2/A5E3: 85 50        STA $50
C2/A5E5: 60           RTS 

; [  ]

C2/A5E6: A5 70        LDA $70
C2/A5E8: 29 FF        AND #$FF
C2/A5EA: 00 D0        BRK $D0
C2/A5EC: 13 20        ORA ($20,S),Y
C2/A5EE: 5F A5 B0 0E  EOR $0EB0A5,X
C2/A5F2: 20 07 A6     JSR $A607
C2/A5F5: 20 05 FE     JSR $FE05
C2/A5F8: 20 6F E6     JSR $E66F
C2/A5FB: 20 2F FC     JSR $FC2F
C2/A5FE: 80 06        BRA $A606
C2/A600: E2 20        SEP #$20
C2/A602: A5 53        LDA $53
C2/A604: 85 50        STA $50
C2/A606: 60           RTS 

; [  ]

C2/A607: AD AC 29     LDA $29AC
C2/A60A: 18           CLC 
C2/A60B: 65 6B        ADC $6B
C2/A60D: AA           TAX 
C2/A60E: AC B0 29     LDY $29B0
C2/A611: 20 E3 E3     JSR $E3E3
C2/A614: 20 67 E3     JSR $E367
C2/A617: 60           RTS 

; [  ]

C2/A618: AD 02 28     LDA $2802
C2/A61B: 10 01        BPL $A61E
C2/A61D: 60           RTS 
C2/A61E: AD 14 28     LDA $2814
C2/A621: 29 FF 00     AND #$00FF
C2/A624: 85 85        STA $85
C2/A626: A5 58        LDA $58
C2/A628: 29 0F 00     AND #$000F
C2/A62B: 3A           DEC 
C2/A62C: AA           TAX 
C2/A62D: E2 20        SEP #$20
C2/A62F: BF C1 F3 C0  LDA $C0F3C1,X
C2/A633: 18           CLC 
C2/A634: 65 85        ADC $85
C2/A636: CD 13 28     CMP $2813
C2/A639: 30 07        BMI $A642
C2/A63B: F0 05        BEQ $A642
C2/A63D: AD 13 28     LDA $2813
C2/A640: 80 06        BRA $A648
C2/A642: C9 01        CMP #$01
C2/A644: 10 02        BPL $A648
C2/A646: A9 01        LDA #$01
C2/A648: 8D 14 28     STA $2814
C2/A64B: 20 E6 F0     JSR $F0E6
C2/A64E: E2 20        SEP #$20
C2/A650: A2 21 28     LDX #$2821
C2/A653: A0 19 28     LDY #$2819
C2/A656: 20 C8 EE     JSR $EEC8
C2/A659: B0 04        BCS $A65F
C2/A65B: A5 85        LDA $85
C2/A65D: 80 E9        BRA $A648
C2/A65F: AD 04 28     LDA $2804
C2/A662: 30 0D        BMI $A671
C2/A664: A2 15 28     LDX #$2815
C2/A667: A0 19 28     LDY #$2819
C2/A66A: 20 C8 EE     JSR $EEC8
C2/A66D: 90 EC        BCC $A65B
C2/A66F: 80 00        BRA $A671
C2/A671: C2 20        REP #$20
C2/A673: 20 7A A6     JSR $A67A
C2/A676: 20 93 A6     JSR $A693
C2/A679: 60           RTS 

; [  ]

C2/A67A: A2 A4 42     LDX #$42A4
C2/A67D: A0 19 28     LDY #$2819
C2/A680: A9 73 7E     LDA #$7E73
C2/A683: 20 ED E4     JSR $E4ED
C2/A686: A2 9A 42     LDX #$429A
C2/A689: A0 14 28     LDY #$2814
C2/A68C: A9 21 7E     LDA #$7E21
C2/A68F: 20 ED E4     JSR $E4ED
C2/A692: 60           RTS 

; [  ]

C2/A693: A2 F9 F3     LDX #$F3F9
C2/A696: 80 08        BRA $A6A0
C2/A698: A2 02 F4     LDX #$F402
C2/A69B: 80 03        BRA $A6A0
C2/A69D: A2 0B F4     LDX #$F40B
C2/A6A0: C2 20        REP #$20
C2/A6A2: A0 14 75     LDY #$7514
C2/A6A5: A9 08 00     LDA #$0008
C2/A6A8: 54 7E C0     MVN $7E,$C0
C2/A6AB: E2 20        SEP #$20
C2/A6AD: A9 01        LDA #$01
C2/A6AF: 8D 11 75     STA $7511
C2/A6B2: 20 6F E6     JSR $E66F
C2/A6B5: 20 2F FC     JSR $FC2F
C2/A6B8: 60           RTS 

; [  ]

C2/A6B9: 20 5F A5     JSR $A55F
C2/A6BC: B0 1F        BCS $A6DD
C2/A6BE: 08           PHP 
C2/A6BF: E2 20        SEP #$20
C2/A6C1: AD A3 29     LDA $29A3
C2/A6C4: 8D 28 75     STA $7528
C2/A6C7: 28           PLP 
C2/A6C8: 20 DE A6     JSR $A6DE
C2/A6CB: 20 05 FE     JSR $FE05
C2/A6CE: 20 6F E6     JSR $E66F
C2/A6D1: 20 2F FC     JSR $FC2F
C2/A6D4: 20 6F E6     JSR $E66F
C2/A6D7: 20 2F FC     JSR $FC2F
C2/A6DA: 20 4A A5     JSR $A54A
C2/A6DD: 60           RTS 

; [  ]

C2/A6DE: AD AC 29     LDA $29AC
C2/A6E1: 18           CLC 
C2/A6E2: 65 6B        ADC $6B
C2/A6E4: AA           TAX 
C2/A6E5: AC B0 29     LDY $29B0
C2/A6E8: 20 F3 E3     JSR $E3F3
C2/A6EB: AD AE 29     LDA $29AE
C2/A6EE: 18           CLC 
C2/A6EF: 65 6B        ADC $6B
C2/A6F1: AA           TAX 
C2/A6F2: AC B2 29     LDY $29B2
C2/A6F5: 20 F3 E3     JSR $E3F3
C2/A6F8: 20 67 E3     JSR $E367
C2/A6FB: 60           RTS 

; [  ]

C2/A6FC: AD 66 2B     LDA $2B66
C2/A6FF: A8           TAY 
C2/A700: A5 58        LDA $58
C2/A702: 3A           DEC 
C2/A703: 29 03 00     AND #$0003
C2/A706: 0A           ASL 
C2/A707: AA           TAX 
C2/A708: BF AB F3 C0  LDA $C0F3AB,X
C2/A70C: 9C 6E 2B     STZ $2B6E
C2/A70F: E2 20        SEP #$20
C2/A711: A6 8E        LDX $8E
C2/A713: 18           CLC 
C2/A714: 7D 66 2B     ADC $2B66,X
C2/A717: 20 80 A7     JSR $A780
C2/A71A: 9D 66 2B     STA $2B66,X
C2/A71D: EB           XBA 
C2/A71E: E8           INX 
C2/A71F: E0 02 00     CPX #$0002
C2/A722: D0 EF        BNE $A713
C2/A724: AD 67 2B     LDA $2B67
C2/A727: 8F 02 42 00  STA $004202
C2/A72B: AD 68 2B     LDA $2B68
C2/A72E: 8F 03 42 00  STA $004203
C2/A732: EA           NOP 
C2/A733: EA           NOP 
C2/A734: EA           NOP 
C2/A735: EA           NOP 
C2/A736: AF 16 42 00  LDA $004216
C2/A73A: 18           CLC 
C2/A73B: 6D 66 2B     ADC $2B66
C2/A73E: C2 20        REP #$20
C2/A740: 29 FF 00     AND #$00FF
C2/A743: AA           TAX 
C2/A744: BD 00 7A     LDA $7A00,X
C2/A747: 29 FF 00     AND #$00FF
C2/A74A: C9 FF 00     CMP #$00FF
C2/A74D: F0 B1        BEQ $A700
C2/A74F: 8A           TXA 
C2/A750: 1A           INC 
C2/A751: E2 20        SEP #$20
C2/A753: AE 6A 2B     LDX $2B6A
C2/A756: 9D 01 76     STA $7601,X
C2/A759: AD 66 2B     LDA $2B66
C2/A75C: 29 0F        AND #$0F
C2/A75E: AA           TAX 
C2/A75F: AD 67 2B     LDA $2B67
C2/A762: 29 0F        AND #$0F
C2/A764: A8           TAY 
C2/A765: E2 20        SEP #$20
C2/A767: BD 70 2B     LDA $2B70,X
C2/A76A: AE 6A 2B     LDX $2B6A
C2/A76D: 9D 02 76     STA $7602,X     ; cursor x position
C2/A770: B9 80 2B     LDA $2B80,Y
C2/A773: 9D 03 76     STA $7603,X     ; cursor y position
C2/A776: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A779: 80 04        BRA $A77F
C2/A77B: 98           TYA 
C2/A77C: 8D 66 2B     STA $2B66
C2/A77F: 60           RTS 

; [  ]

C2/A780: 10 12        BPL $A794
C2/A782: 3C 6C 2B     BIT $2B6C,X
C2/A785: 10 07        BPL $A78E
C2/A787: FE 6E 2B     INC $2B6E,X
C2/A78A: A9 00        LDA #$00
C2/A78C: 80 0D        BRA $A79B
C2/A78E: BD 68 2B     LDA $2B68,X
C2/A791: 3A           DEC 
C2/A792: 80 07        BRA $A79B
C2/A794: DD 68 2B     CMP $2B68,X
C2/A797: 30 02        BMI $A79B
C2/A799: A9 00        LDA #$00
C2/A79B: 60           RTS 

; [  ]

C2/A79C: A5 55        LDA $55
C2/A79E: 29 FF 00     AND #$00FF
C2/A7A1: 3A           DEC 
C2/A7A2: AA           TAX 
C2/A7A3: A5 58        LDA $58
C2/A7A5: 29 FF 00     AND #$00FF
C2/A7A8: 3A           DEC 
C2/A7A9: 3A           DEC 
C2/A7AA: E2 20        SEP #$20
C2/A7AC: 18           CLC 
C2/A7AD: 7D 9C 2C     ADC $2C9C,X
C2/A7B0: 30 0B        BMI $A7BD
C2/A7B2: DF 76 F0 C0  CMP $C0F076,X
C2/A7B6: 30 07        BMI $A7BF
C2/A7B8: BD 9C 2C     LDA $2C9C,X
C2/A7BB: 80 02        BRA $A7BF
C2/A7BD: A9 00        LDA #$00
C2/A7BF: 9D 9C 2C     STA $2C9C,X
C2/A7C2: 8E 94 2C     STX $2C94
C2/A7C5: E0 0A 00     CPX #$000A
C2/A7C8: 30 05        BMI $A7CF
C2/A7CA: E0 0D 00     CPX #$000D
C2/A7CD: 30 0D        BMI $A7DC
C2/A7CF: 20 A6 F7     JSR $F7A6
C2/A7D2: A5 54        LDA $54
C2/A7D4: C9 21        CMP #$21
C2/A7D6: F0 1D        BEQ $A7F5
C2/A7D8: C9 22        CMP #$22
C2/A7DA: F0 11        BEQ $A7ED
C2/A7DC: 20 10 F8     JSR $F810
C2/A7DF: 20 1C F7     JSR $F71C       ; update config settings
C2/A7E2: 20 47 D4     JSR $D447       ; update window color
C2/A7E5: 20 98 A6     JSR $A698
C2/A7E8: 20 F0 FA     JSR $FAF0
C2/A7EB: 80 0E        BRA $A7FB
C2/A7ED: C2 20        REP #$20
C2/A7EF: A9 7A B7     LDA #$B77A
C2/A7F2: 20 B8 C1     JSR $C1B8
C2/A7F5: 20 93 A6     JSR $A693
C2/A7F8: 20 1C F7     JSR $F71C       ; update config settings
C2/A7FB: 60           RTS 

; [  ]

C2/A7FC: E2 20        SEP #$20
C2/A7FE: 9C 0F 75     STZ $750F
C2/A801: 9C 1E 75     STZ $751E
C2/A804: 20 E2 C0     JSR $C0E2
C2/A807: A5 59        LDA $59
C2/A809: 85 53        STA $53
C2/A80B: A9 02        LDA #$02
C2/A80D: 1C 00 75     TRB $7500
C2/A810: A9 08        LDA #$08
C2/A812: 1C 09 75     TRB $7509
C2/A815: A9 04        LDA #$04
C2/A817: 04 CA        TSB $CA
C2/A819: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A81C: 60           RTS 

; [  ]

C2/A81D: 64 6F        STZ $6F
C2/A81F: E2 20        SEP #$20
C2/A821: A5 50        LDA $50
C2/A823: 85 59        STA $59
C2/A825: 60           RTS 
C2/A826: 64 6F        STZ $6F
C2/A828: E2 20        SEP #$20
C2/A82A: A9 02        LDA #$02
C2/A82C: 0C 00 75     TSB $7500
C2/A82F: A9 08        LDA #$08
C2/A831: 0C 09 75     TSB $7509
C2/A834: A9 04        LDA #$04
C2/A836: 04 CA        TSB $CA
C2/A838: 20 7C E6     JSR $E67C
C2/A83B: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A83E: 20 5A A8     JSR $A85A
C2/A841: A2 C7 AD     LDX #$ADC7
C2/A844: 20 F0 A8     JSR $A8F0
C2/A847: 60           RTS 
C2/A848: 08           PHP 
C2/A849: C2 20        REP #$20
C2/A84B: A5 55        LDA $55
C2/A84D: 29 0F 00     AND #$000F
C2/A850: 3A           DEC 
C2/A851: 0A           ASL 
C2/A852: AA           TAX 
C2/A853: BF 64 EA C0  LDA $C0EA64,X
C2/A857: AA           TAX 
C2/A858: 28           PLP 
C2/A859: 60           RTS 
C2/A85A: 20 48 A8     JSR $A848
C2/A85D: 3C 00 05     BIT $0500,X
C2/A860: 50 15        BVC $A877
C2/A862: A5 55        LDA $55
C2/A864: C9 04        CMP #$04
C2/A866: D0 08        BNE $A870
C2/A868: C6 53        DEC $53
C2/A86A: C6 53        DEC $53
C2/A86C: C6 53        DEC $53
C2/A86E: C6 53        DEC $53
C2/A870: E6 53        INC $53
C2/A872: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A875: 80 E3        BRA $A85A
C2/A877: 60           RTS 
C2/A878: A5 53        LDA $53
C2/A87A: 29 03        AND #$03
C2/A87C: 85 E0        STA $E0
C2/A87E: A5 50        LDA $50
C2/A880: 29 03        AND #$03
C2/A882: 1A           INC 
C2/A883: 29 03        AND #$03
C2/A885: C5 E0        CMP $E0
C2/A887: F0 04        BEQ $A88D
C2/A889: A9 FF        LDA #$FF
C2/A88B: 80 02        BRA $A88F
C2/A88D: A9 01        LDA #$01
C2/A88F: 85 E2        STA $E2
C2/A891: 60           RTS 
C2/A892: 08           PHP 
C2/A893: E2 20        SEP #$20
C2/A895: 20 78 A8     JSR $A878
C2/A898: 20 48 A8     JSR $A848
C2/A89B: 3C 00 05     BIT $0500,X
C2/A89E: 50 1F        BVC $A8BF
C2/A8A0: A5 55        LDA $55
C2/A8A2: 18           CLC 
C2/A8A3: 65 E2        ADC $E2
C2/A8A5: F0 08        BEQ $A8AF
C2/A8A7: C9 05        CMP #$05
C2/A8A9: F0 08        BEQ $A8B3
C2/A8AB: A5 E2        LDA $E2
C2/A8AD: 80 06        BRA $A8B5
C2/A8AF: A9 03        LDA #$03
C2/A8B1: 80 02        BRA $A8B5
C2/A8B3: A9 FD        LDA #$FD
C2/A8B5: 18           CLC 
C2/A8B6: 65 53        ADC $53
C2/A8B8: 85 53        STA $53
C2/A8BA: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A8BD: 80 D9        BRA $A898
C2/A8BF: 28           PLP 
C2/A8C0: 60           RTS 
C2/A8C1: E2 20        SEP #$20
C2/A8C3: A5 6F        LDA $6F
C2/A8C5: D0 03        BNE $A8CA
C2/A8C7: 20 92 A8     JSR $A892
C2/A8CA: 60           RTS 
C2/A8CB: A5 50        LDA $50
C2/A8CD: 85 53        STA $53
C2/A8CF: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A8D2: 60           RTS 
C2/A8D3: E2 20        SEP #$20
C2/A8D5: A5 6F        LDA $6F
C2/A8D7: F0 09        BEQ $A8E2
C2/A8D9: 20 CB A8     JSR $A8CB
C2/A8DC: A9 40        LDA #$40
C2/A8DE: 14 4F        TRB $4F
C2/A8E0: 80 0D        BRA $A8EF
C2/A8E2: A2 D8 AD     LDX #$ADD8
C2/A8E5: 20 F0 A8     JSR $A8F0
C2/A8E8: 9C 10 75     STZ $7510
C2/A8EB: A5 50        LDA $50
C2/A8ED: 85 5A        STA $5A
C2/A8EF: 60           RTS 
C2/A8F0: C2 20        REP #$20
C2/A8F2: 8A           TXA 
C2/A8F3: 20 B8 C1     JSR $C1B8
C2/A8F6: 20 93 A6     JSR $A693
C2/A8F9: 60           RTS 
C2/A8FA: A5 59        LDA $59
C2/A8FC: 20 C0 C0     JSR $C0C0
C2/A8FF: E2 20        SEP #$20
C2/A901: A9 01        LDA #$01
C2/A903: 8D 10 75     STA $7510
C2/A906: 20 7C E6     JSR $E67C
C2/A909: A5 53        LDA $53
C2/A90B: 29 03        AND #$03
C2/A90D: 09 0C        ORA #$0C
C2/A90F: 85 53        STA $53
C2/A911: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A914: 20 5A A8     JSR $A85A
C2/A917: 60           RTS 
C2/A918: 20 92 A8     JSR $A892
C2/A91B: 60           RTS 
C2/A91C: E2 20        SEP #$20
C2/A91E: A5 50        LDA $50
C2/A920: 29 0B        AND #$0B
C2/A922: 85 5A        STA $5A
C2/A924: 60           RTS 
C2/A925: 20 17 D7     JSR $D717
C2/A928: 20 98 A6     JSR $A698
C2/A92B: A9 02        LDA #$02
C2/A92D: 0C 00 75     TSB $7500
C2/A930: A9 04        LDA #$04
C2/A932: 04 CA        TSB $CA
C2/A934: 60           RTS 
C2/A935: A5 55        LDA $55
C2/A937: 29 FF        AND #$FF
C2/A939: 00 3A        BRK $3A
C2/A93B: AA           TAX 
C2/A93C: E2 20        SEP #$20
C2/A93E: BD 5F 2B     LDA $2B5F,X
C2/A941: F0 04        BEQ $A947
C2/A943: A5 50        LDA $50
C2/A945: 85 53        STA $53
C2/A947: 60           RTS 
C2/A948: E2 20        SEP #$20
C2/A94A: A5 50        LDA $50
C2/A94C: 85 60        STA $60
C2/A94E: A9 02        LDA #$02
C2/A950: 1C 00 75     TRB $7500
C2/A953: A9 04        LDA #$04
C2/A955: 04 CA        TSB $CA
C2/A957: 60           RTS 
C2/A958: A9 62        LDA #$62
C2/A95A: AE 20 B8     LDX $B820
C2/A95D: C1 20        CMP ($20,X)
C2/A95F: 67 E3        ADC [$E3]
C2/A961: 20 98 A6     JSR $A698
C2/A964: 60           RTS 
C2/A965: 20 60 D7     JSR $D760
C2/A968: 20 98 A6     JSR $A698
C2/A96B: 60           RTS 
C2/A96C: 64 6F        STZ $6F
C2/A96E: 60           RTS 
C2/A96F: A5 55        LDA $55
C2/A971: 29 FF        AND #$FF
C2/A973: 00 3A        BRK $3A
C2/A975: AA           TAX 
C2/A976: E2 20        SEP #$20
C2/A978: A5 6F        LDA $6F
C2/A97A: D0 12        BNE $A98E
C2/A97C: BD 00 7A     LDA $7A00,X
C2/A97F: 10 11        BPL $A992
C2/A981: A5 53        LDA $53
C2/A983: 38           SEC 
C2/A984: E5 50        SBC $50
C2/A986: C9 01        CMP #$01
C2/A988: D0 04        BNE $A98E
C2/A98A: 64 53        STZ $53
C2/A98C: 80 04        BRA $A992
C2/A98E: A5 50        LDA $50
C2/A990: 85 53        STA $53
C2/A992: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/A995: C2 20        REP #$20
C2/A997: A5 52        LDA $52
C2/A999: 29 FF 00     AND #$00FF
C2/A99C: 3A           DEC 
C2/A99D: 0A           ASL 
C2/A99E: 0A           ASL 
C2/A99F: A8           TAY 
C2/A9A0: 0A           ASL 
C2/A9A1: AA           TAX 
C2/A9A2: E2 20        SEP #$20
C2/A9A4: BD 93 02     LDA $0293,X
C2/A9A7: 29 F1        AND #$F1
C2/A9A9: 09 0C        ORA #$0C
C2/A9AB: 9D 93 02     STA $0293,X
C2/A9AE: 9D 97 02     STA $0297,X
C2/A9B1: B9 63 03     LDA $0363,Y
C2/A9B4: 29 F1        AND #$F1
C2/A9B6: 09 0C        ORA #$0C
C2/A9B8: 99 63 03     STA $0363,Y
C2/A9BB: 99 63 03     STA $0363,Y
C2/A9BE: 20 57 CD     JSR $CD57
C2/A9C1: A9 01        LDA #$01
C2/A9C3: 8D 11 75     STA $7511
C2/A9C6: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/A9C9: 20 F0 FA     JSR $FAF0
C2/A9CC: 20 6F E6     JSR $E66F
C2/A9CF: 20 D9 A9     JSR $A9D9
C2/A9D2: 20 08 CD     JSR $CD08
C2/A9D5: 20 9D A6     JSR $A69D
C2/A9D8: 60           RTS 

; [  ]

C2/A9D9: 08           PHP 
C2/A9DA: C2 20        REP #$20
C2/A9DC: A9 1A AF     LDA #$AF1A
C2/A9DF: 20 B8 C1     JSR $C1B8
C2/A9E2: A5 55        LDA $55         ; cursor position ???
C2/A9E4: 29 FF 00     AND #$00FF
C2/A9E7: 3A           DEC 
C2/A9E8: AA           TAX 
C2/A9E9: BD 00 7A     LDA $7A00,X     ; job index
C2/A9EC: 29 1F 00     AND #$001F
C2/A9EF: 0A           ASL 
C2/A9F0: AA           TAX 
C2/A9F1: BF 40 71 D1  LDA $D17140,X   ; pointers to job/ability descriptions
C2/A9F5: 8D EB 2C     STA $2CEB
C2/A9F8: 20 16 DA     JSR $DA16
C2/A9FB: 28           PLP 
C2/A9FC: 60           RTS 

C2/A9FD: A9 36        LDA #$36
C2/A9FF: B0 20        BCS $AA21
C2/AA01: B8           CLV 
C2/AA02: C1 A9        CMP ($A9,X)
C2/AA04: 02 00        COP $00
C2/AA06: 0C 00 75     TSB $7500
C2/AA09: A9 04        LDA #$04
C2/AA0B: 00 04        BRK $04
C2/AA0D: CA           DEX 
C2/AA0E: 20 93 A6     JSR $A693
C2/AA11: 60           RTS 
C2/AA12: 64 6F        STZ $6F
C2/AA14: E2 20        SEP #$20
C2/AA16: A9 02        LDA #$02
C2/AA18: 0C 00 75     TSB $7500
C2/AA1B: A9 04        LDA #$04
C2/AA1D: 04 CA        TSB $CA
C2/AA1F: A5 74        LDA $74
C2/AA21: C9 04        CMP #$04
C2/AA23: F0 04        BEQ $AA29
C2/AA25: C9 03        CMP #$03
C2/AA27: F0 05        BEQ $AA2E
C2/AA29: A2 65 B0     LDX #$B065
C2/AA2C: 80 03        BRA $AA31
C2/AA2E: A2 7D B0     LDX #$B07D
C2/AA31: 20 F0 A8     JSR $A8F0
C2/AA34: 60           RTS 
C2/AA35: 20 67 E3     JSR $E367
C2/AA38: 20 98 A6     JSR $A698
C2/AA3B: 64 72        STZ $72
C2/AA3D: 64 73        STZ $73
C2/AA3F: A9 08        LDA #$08
C2/AA41: 0C 00 75     TSB $7500
C2/AA44: A9 0C        LDA #$0C
C2/AA46: 0C 02 75     TSB $7502
C2/AA49: A9 04        LDA #$04
C2/AA4B: 04 CA        TSB $CA
C2/AA4D: 60           RTS 
C2/AA4E: 9C 08 02     STZ $0208
C2/AA51: 9C 0A 02     STZ $020A
C2/AA54: A9 FA        LDA #$FA
C2/AA56: AF 20 B8 C1  LDA $C1B820
C2/AA5A: 20 98 A6     JSR $A698
C2/AA5D: 64 70        STZ $70
C2/AA5F: A9 08        LDA #$08
C2/AA61: 1C 00 75     TRB $7500
C2/AA64: A9 0C        LDA #$0C
C2/AA66: 1C 02 75     TRB $7502
C2/AA69: A9 04        LDA #$04
C2/AA6B: 04 CA        TSB $CA
C2/AA6D: 60           RTS 
C2/AA6E: A5 55        LDA $55
C2/AA70: 29 FF        AND #$FF
C2/AA72: 00 3A        BRK $3A
C2/AA74: 18           CLC 
C2/AA75: 65 6B        ADC $6B
C2/AA77: AA           TAX 
C2/AA78: E2 20        SEP #$20
C2/AA7A: BD 00 7A     LDA $7A00,X
C2/AA7D: F0 05        BEQ $AA84
C2/AA7F: 20 89 AA     JSR $AA89
C2/AA82: 80 04        BRA $AA88
C2/AA84: A5 50        LDA $50
C2/AA86: 85 53        STA $53
C2/AA88: 60           RTS 
C2/AA89: 85 72        STA $72
C2/AA8B: 20 F7 E0     JSR $E0F7
C2/AA8E: A5 90        LDA $90
C2/AA90: D0 1D        BNE $AAAF
C2/AA92: 20 78 E1     JSR $E178
C2/AA95: 20 11 E2     JSR $E211
C2/AA98: A5 73        LDA $73
C2/AA9A: 20 86 E2     JSR $E286
C2/AA9D: A5 90        LDA $90
C2/AA9F: D0 0E        BNE $AAAF
C2/AAA1: 20 A6 E1     JSR $E1A6
C2/AAA4: 20 B3 E7     JSR $E7B3
C2/AAA7: 20 CC E7     JSR $E7CC
C2/AAAA: 20 F8 CB     JSR $CBF8
C2/AAAD: 80 08        BRA $AAB7
C2/AAAF: C2 20        REP #$20
C2/AAB1: A9 05 B0     LDA #$B005
C2/AAB4: 20 B8 C1     JSR $C1B8
C2/AAB7: 20 98 A6     JSR $A698
C2/AABA: 60           RTS 
C2/AABB: A9 6A B2     LDA #$B26A
C2/AABE: 20 B8 C1     JSR $C1B8
C2/AAC1: A9 04 00     LDA #$0004
C2/AAC4: 20 E7 EE     JSR $EEE7
C2/AAC7: 20 6E A1     JSR $A16E       ; reset sprite data
C2/AACA: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/AACD: 20 6F E6     JSR $E66F
C2/AAD0: 60           RTS 
C2/AAD1: E2 20        SEP #$20
C2/AAD3: AD 01 28     LDA $2801
C2/AAD6: 29 07        AND #$07
C2/AAD8: D0 0E        BNE $AAE8
C2/AADA: A5 53        LDA $53
C2/AADC: C9 01        CMP #$01
C2/AADE: D0 08        BNE $AAE8
C2/AAE0: A5 50        LDA $50
C2/AAE2: 29 03        AND #$03
C2/AAE4: 49 02        EOR #$02
C2/AAE6: 85 53        STA $53
C2/AAE8: 60           RTS 
C2/AAE9: A9 42        LDA #$42
C2/AAEB: B2 20        LDA ($20)
C2/AAED: B8           CLV 
C2/AAEE: C1 E2        CMP ($E2,X)
C2/AAF0: 20 AD 01     JSR $01AD
C2/AAF3: 28           PLP 
C2/AAF4: 29 03        AND #$03
C2/AAF6: C9 03        CMP #$03
C2/AAF8: D0 07        BNE $AB01
C2/AAFA: 9C 86 28     STZ $2886
C2/AAFD: C2 20        REP #$20
C2/AAFF: 80 0E        BRA $AB0F
C2/AB01: C2 20        REP #$20
C2/AB03: 20 89 EF     JSR $EF89
C2/AB06: 20 16 EF     JSR $EF16
C2/AB09: A9 5F B2     LDA #$B25F
C2/AB0C: 20 B8 C1     JSR $C1B8
C2/AB0F: 20 0E F1     JSR $F10E
C2/AB12: A9 00 00     LDA #$0000
C2/AB15: 20 E7 EE     JSR $EEE7
C2/AB18: 60           RTS 
C2/AB19: A9 54 B2     LDA #$B254
C2/AB1C: 20 B8 C1     JSR $C1B8
C2/AB1F: 60           RTS 
C2/AB20: 20 36 AB     JSR $AB36
C2/AB23: AD 01 28     LDA $2801
C2/AB26: 29 03 C9     AND #$C903
C2/AB29: 03 F0        ORA $F0,S
C2/AB2B: 09 20 89     ORA #$8920
C2/AB2E: EF 20 16 EF  SBC $EF1620
C2/AB32: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/AB35: 60           RTS 
C2/AB36: A5 55        LDA $55
C2/AB38: 29 0F 00     AND #$000F
C2/AB3B: 3A           DEC 
C2/AB3C: AA           TAX 
C2/AB3D: E2 20        SEP #$20
C2/AB3F: BD 26 28     LDA $2826,X
C2/AB42: D0 07        BNE $AB4B
C2/AB44: 20 CB A8     JSR $A8CB
C2/AB47: A9 01        LDA #$01
C2/AB49: 14 CA        TRB $CA
C2/AB4B: 60           RTS 
C2/AB4C: 20 7A A6     JSR $A67A
C2/AB4F: A2 5A 43     LDX #$435A
C2/AB52: A0 11 28     LDY #$2811
C2/AB55: 20 ED E4     JSR $E4ED
C2/AB58: A2 DA 43     LDX #$43DA
C2/AB5B: A0 12 28     LDY #$2812
C2/AB5E: 20 ED E4     JSR $E4ED
C2/AB61: A9 E0        LDA #$E0
C2/AB63: B1 20        LDA ($20),Y
C2/AB65: B8           CLV 
C2/AB66: C1 AD        CMP ($AD,X)
C2/AB68: 10 28        BPL $AB92
C2/AB6A: 29 FF        AND #$FF
C2/AB6C: 00 0A        BRK $0A
C2/AB6E: AA           TAX 
C2/AB6F: BF 00 40 D1  LDA $D14000,X
C2/AB73: 8D EB 2C     STA $2CEB
C2/AB76: 20 16 DA     JSR $DA16
C2/AB79: E2 20        SEP #$20
C2/AB7B: AD 09 28     LDA $2809
C2/AB7E: A0 86 42     LDY #$4286
C2/AB81: 20 4E E4     JSR $E44E
C2/AB84: A9 02        LDA #$02
C2/AB86: 0C 00 75     TSB $7500
C2/AB89: A9 04        LDA #$04
C2/AB8B: 04 CA        TSB $CA
C2/AB8D: 20 93 A6     JSR $A693
C2/AB90: 60           RTS 
C2/AB91: 20 4C AB     JSR $AB4C
C2/AB94: A9 05        LDA #$05
C2/AB96: 20 E7 EE     JSR $EEE7
C2/AB99: AD 86 28     LDA $2886
C2/AB9C: 8D 0F 75     STA $750F
C2/AB9F: 60           RTS 
C2/ABA0: E2 20        SEP #$20
C2/ABA2: A9 02        LDA #$02
C2/ABA4: 1C 00 75     TRB $7500
C2/ABA7: A9 04        LDA #$04
C2/ABA9: 04 CA        TSB $CA
C2/ABAB: 9C 0F 75     STZ $750F
C2/ABAE: 9C 1E 75     STZ $751E
C2/ABB1: 60           RTS 
C2/ABB2: 20 A0 AB     JSR $ABA0
C2/ABB5: AD 07 28     LDA $2807
C2/ABB8: 18           CLC 
C2/ABB9: 69 03        ADC #$03
C2/ABBB: 85 53        STA $53
C2/ABBD: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/ABC0: 60           RTS 
C2/ABC1: A9 75        LDA #$75
C2/ABC3: B2 20        LDA ($20)
C2/ABC5: B8           CLV 
C2/ABC6: C1 20        CMP ($20,X)
C2/ABC8: 0E F1 A9     ASL $A9F1
C2/ABCB: 00 00        BRK $00
C2/ABCD: 20 E7 EE     JSR $EEE7
C2/ABD0: 60           RTS 
C2/ABD1: A9 54        LDA #$54
C2/ABD3: B2 20        LDA ($20)
C2/ABD5: B8           CLV 
C2/ABD6: C1 20        CMP ($20,X)
C2/ABD8: 98           TYA 
C2/ABD9: A6 60        LDX $60
C2/ABDB: 20 36 AB     JSR $AB36
C2/ABDE: 60           RTS 
C2/ABDF: A9 A9        LDA #$A9
C2/ABE1: B3 20        LDA ($20,S),Y
C2/ABE3: B8           CLV 
C2/ABE4: C1 20        CMP ($20,X)
C2/ABE6: 98           TYA 
C2/ABE7: A6 A9        LDX $A9
C2/ABE9: 08           PHP 
C2/ABEA: 1C 06 75     TRB $7506
C2/ABED: A9 04        LDA #$04
C2/ABEF: 04 CA        TSB $CA
C2/ABF1: 60           RTS 
C2/ABF2: E2 20        SEP #$20
C2/ABF4: AD 15 2D     LDA $2D15
C2/ABF7: F0 04        BEQ $ABFD
C2/ABF9: A5 50        LDA $50
C2/ABFB: 85 53        STA $53
C2/ABFD: 20 98 A6     JSR $A698
C2/AC00: 60           RTS 
C2/AC01: 20 0E AC     JSR $AC0E
C2/AC04: A9 08        LDA #$08
C2/AC06: 0C 06 75     TSB $7506
C2/AC09: A9 04        LDA #$04
C2/AC0B: 04 CA        TSB $CA
C2/AC0D: 60           RTS 
C2/AC0E: A9 B4        LDA #$B4
C2/AC10: B3 20        LDA ($20,S),Y
C2/AC12: B8           CLV 
C2/AC13: C1 20        CMP ($20,X)
C2/AC15: BD C7 20     LDA $20C7,X
C2/AC18: 9D A6 20     STA $20A6,X
C2/AC1B: 67 E3        ADC [$E3]
C2/AC1D: 60           RTS 
C2/AC1E: 20 90 AC     JSR $AC90
C2/AC21: E2 20        SEP #$20
C2/AC23: 9C A3 29     STZ $29A3
C2/AC26: 9C 28 75     STZ $7528
C2/AC29: 20 5E AC     JSR $AC5E
C2/AC2C: 20 98 A6     JSR $A698
C2/AC2F: AD 89 28     LDA $2889
C2/AC32: F0 29        BEQ $AC5D
C2/AC34: A5 6F        LDA $6F
C2/AC36: C2 20        REP #$20
C2/AC38: 29 FF 00     AND #$00FF
C2/AC3B: 38           SEC 
C2/AC3C: E5 6B        SBC $6B
C2/AC3E: 30 15        BMI $AC55
C2/AC40: C9 16 00     CMP #$0016
C2/AC43: 10 10        BPL $AC55
C2/AC45: 18           CLC 
C2/AC46: 69 04 00     ADC #$0004
C2/AC49: 20 C9 C0     JSR $C0C9
C2/AC4C: E2 20        SEP #$20
C2/AC4E: A9 01        LDA #$01
C2/AC50: 8D 10 75     STA $7510
C2/AC53: 80 08        BRA $AC5D
C2/AC55: 20 E2 C0     JSR $C0E2
C2/AC58: E2 20        SEP #$20
C2/AC5A: 9C 10 75     STZ $7510
C2/AC5D: 60           RTS 
C2/AC5E: 08           PHP 
C2/AC5F: C2 20        REP #$20
C2/AC61: A9 A9 B3     LDA #$B3A9
C2/AC64: 20 B8 C1     JSR $C1B8
C2/AC67: A5 55        LDA $55
C2/AC69: 29 FF 00     AND #$00FF
C2/AC6C: 3A           DEC 
C2/AC6D: 18           CLC 
C2/AC6E: 65 6B        ADC $6B
C2/AC70: AA           TAX 
C2/AC71: E2 20        SEP #$20
C2/AC73: BD 00 7A     LDA $7A00,X
C2/AC76: F0 16        BEQ $AC8E
C2/AC78: BD 8A 28     LDA $288A,X
C2/AC7B: F0 11        BEQ $AC8E
C2/AC7D: C2 20        REP #$20
C2/AC7F: 29 7F 00     AND #$007F
C2/AC82: 0A           ASL 
C2/AC83: AA           TAX 
C2/AC84: BF 00 40 D1  LDA $D14000,X
C2/AC88: 8D EB 2C     STA $2CEB
C2/AC8B: 20 16 DA     JSR $DA16
C2/AC8E: 28           PLP 
C2/AC8F: 60           RTS 
C2/AC90: A5 08        LDA $08
C2/AC92: 29 00        AND #$00
C2/AC94: 10 F0        BPL $AC86
C2/AC96: 2B           PLD 
C2/AC97: A5 4B        LDA $4B
C2/AC99: 29 07        AND #$07
C2/AC9B: 00 C9        BRK $C9
C2/AC9D: 03 00        ORA $00,S
C2/AC9F: F0 0A        BEQ $ACAB
C2/ACA1: C9 04        CMP #$04
C2/ACA3: 00 D0        BRK $D0
C2/ACA5: 1C A9 16     TRB $16A9
C2/ACA8: 00 80        BRK $80
C2/ACAA: 03 A9        ORA $A9,S
C2/ACAC: EA           NOP 
C2/ACAD: FF 18 65 6B  SBC $6B6518,X
C2/ACB1: 10 02        BPL $ACB5
C2/ACB3: A5 8E        LDA $8E
C2/ACB5: C5 6D        CMP $6D
C2/ACB7: 30 04        BMI $ACBD
C2/ACB9: F0 02        BEQ $ACBD
C2/ACBB: A5 6D        LDA $6D
C2/ACBD: 85 6B        STA $6B
C2/ACBF: 20 0E AC     JSR $AC0E
C2/ACC2: 60           RTS 
C2/ACC3: A9 34        LDA #$34
C2/ACC5: B4 20        LDY $20,X
C2/ACC7: B8           CLV 
C2/ACC8: C1 20        CMP ($20,X)
C2/ACCA: 93 A6        STA ($A6,S),Y
C2/ACCC: 20 9D A6     JSR $A69D
C2/ACCF: A6 7E        LDX $7E
C2/ACD1: B5 63        LDA $63,X
C2/ACD3: 85 53        STA $53
C2/ACD5: 60           RTS 
C2/ACD6: A9 99        LDA #$99
C2/ACD8: B4 20        LDY $20,X
C2/ACDA: B8           CLV 
C2/ACDB: C1 A9        CMP ($A9,X)
C2/ACDD: A4 B4        LDY $B4
C2/ACDF: 20 B8 C1     JSR $C1B8
C2/ACE2: AF E2 29 7E  LDA $7E29E2
C2/ACE6: 29 07        AND #$07
C2/ACE8: 00 0A        BRK $0A
C2/ACEA: AA           TAX 
C2/ACEB: BF B3 F3 C0  LDA $C0F3B3,X
C2/ACEF: 20 B8 C1     JSR $C1B8
C2/ACF2: 20 93 A6     JSR $A693
C2/ACF5: 20 98 A6     JSR $A698
C2/ACF8: A6 7E        LDX $7E
C2/ACFA: A5 50        LDA $50
C2/ACFC: 95 63        STA $63,X
C2/ACFE: 60           RTS 
C2/ACFF: A9 FE        LDA #$FE
C2/AD01: B3 20        LDA ($20,S),Y
C2/AD03: B8           CLV 
C2/AD04: C1 20        CMP ($20,X)
C2/AD06: 3E DE 20     ROL $20DE,X
C2/AD09: 4D DF 20     EOR $20DF
C2/AD0C: 9D A6 A5     STA $A5A6,X
C2/AD0F: 54 C9 13     MVN $C9,$13
C2/AD12: D0 23        BNE $AD37
C2/AD14: AD E2 29     LDA $29E2
C2/AD17: C9 04        CMP #$04
C2/AD19: F0 1C        BEQ $AD37
C2/AD1B: A6 7E        LDX $7E
C2/AD1D: AD 73 09     LDA $0973
C2/AD20: 29 04        AND #$04
C2/AD22: D0 04        BNE $AD28
C2/AD24: A9 07        LDA #$07
C2/AD26: 95 67        STA $67,X
C2/AD28: B5 67        LDA $67,X
C2/AD2A: C9 07        CMP #$07
C2/AD2C: 30 F6        BMI $AD24
C2/AD2E: C9 19        CMP #$19
C2/AD30: 10 F2        BPL $AD24
C2/AD32: 85 53        STA $53
C2/AD34: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/AD37: 20 BA C6     JSR $C6BA
C2/AD3A: 20 98 A6     JSR $A698
C2/AD3D: 60           RTS 

C2/AD3E: A9 13 B4     LDA #$B413
C2/AD41: 20 B8 C1     JSR $C1B8
C2/AD44: 20 9D A6     JSR $A69D       ; (this does a sep #$20)
C2/AD47: A5 51        LDA $51
C2/AD49: C9 13        CMP #$13
C2/AD4B: D0 0D        BNE $AD5A
C2/AD4D: AD E2 29     LDA $29E2
C2/AD50: C9 04        CMP #$04
C2/AD52: F0 06        BEQ $AD5A
C2/AD54: A6 7E        LDX $7E
C2/AD56: A5 50        LDA $50
C2/AD58: 95 67        STA $67,X
C2/AD5A: 60           RTS 

C2/AD5B: AD E2 29     LDA $29E2
C2/AD5E: 29 FF 00     AND #$00FF
C2/AD61: C9 06 00     CMP #$0006
C2/AD64: F0 49        BEQ $ADAF
C2/AD66: A5 55        LDA $55
C2/AD68: 29 FF 00     AND #$00FF
C2/AD6B: 3A           DEC 
C2/AD6C: AA           TAX 
C2/AD6D: BD 00 7A     LDA $7A00,X
C2/AD70: 29 FF 00     AND #$00FF
C2/AD73: C9 FF 00     CMP #$00FF
C2/AD76: F0 31        BEQ $ADA9
C2/AD78: 48           PHA 
C2/AD79: A9 8E B4     LDA #$B48E
C2/AD7C: 20 B8 C1     JSR $C1B8
C2/AD7F: 68           PLA 
C2/AD80: C9 FE 00     CMP #$00FE
C2/AD83: F0 1F        BEQ $ADA4
C2/AD85: 48           PHA 
C2/AD86: 29 FF 00     AND #$00FF
C2/AD89: A0 D2 60     LDY #$60D2      ; destination: 7E/60D2
C2/AD8C: 20 2C E4     JSR $E42C       ; draw spell name
C2/AD8F: A9 09 B4     LDA #$B409
C2/AD92: 20 B8 C1     JSR $C1B8
C2/AD95: 68           PLA 
C2/AD96: 18           CLC 
C2/AD97: 69 9D 2A     ADC #$2A9D
C2/AD9A: A8           TAY 
C2/AD9B: A2 F4 60     LDX #$60F4
C2/AD9E: A9 31 7E     LDA #$7E31
C2/ADA1: 20 ED E4     JSR $E4ED
C2/ADA4: 20 9D A6     JSR $A69D
C2/ADA7: 80 06        BRA $ADAF
C2/ADA9: E2 20        SEP #$20
C2/ADAB: A5 50        LDA $50
C2/ADAD: 85 53        STA $53
C2/ADAF: 60           RTS 

C2/ADB0: A9 1E        LDA #$1E
C2/ADB2: B4 20        LDY $20,X
C2/ADB4: B8           CLV 
C2/ADB5: C1 20        CMP ($20,X)
C2/ADB7: 3E DE 20     ROL $20DE,X
C2/ADBA: 4D DF A2     EOR $A2DF
C2/ADBD: EC B8 A0     CPX $A0B8
C2/ADC0: 80 71        BRA $AE33
C2/ADC2: 20 FD C1     JSR $C1FD
C2/ADC5: 20 9D A6     JSR $A69D
C2/ADC8: 9C 66 2B     STZ $2B66
C2/ADCB: 60           RTS 
C2/ADCC: A9 29        LDA #$29
C2/ADCE: B4 20        LDY $20,X
C2/ADD0: B8           CLV 
C2/ADD1: C1 A2        CMP ($A2,X)
C2/ADD3: E6 B8        INC $B8
C2/ADD5: A0 80 71     LDY #$7180
C2/ADD8: 20 FD C1     JSR $C1FD
C2/ADDB: 20 9D A6     JSR $A69D
C2/ADDE: 60           RTS 
C2/ADDF: A9 FE        LDA #$FE
C2/ADE1: B2 20        LDA ($20)
C2/ADE3: B8           CLV 
C2/ADE4: C1 20        CMP ($20,X)
C2/ADE6: BD C7 20     LDA $20C7,X
C2/ADE9: 9D A6 A9     STA $A9A6,X
C2/ADEC: 08           PHP 
C2/ADED: 0C 00 75     TSB $7500
C2/ADF0: A9 1C        LDA #$1C
C2/ADF2: 0C 02 75     TSB $7502
C2/ADF5: A9 32        LDA #$32
C2/ADF7: 8D 05 75     STA $7505
C2/ADFA: A9 04        LDA #$04
C2/ADFC: 0C 0E 75     TSB $750E
C2/ADFF: A9 04        LDA #$04
C2/AE01: 04 CA        TSB $CA
C2/AE03: AD 06 28     LDA $2806
C2/AE06: 85 53        STA $53
C2/AE08: 20 67 E3     JSR $E367
C2/AE0B: A9 07        LDA #$07
C2/AE0D: 20 E7 EE     JSR $EEE7
C2/AE10: 60           RTS 
C2/AE11: A9 10        LDA #$10
C2/AE13: B3 20        LDA ($20,S),Y
C2/AE15: B8           CLV 
C2/AE16: C1 E2        CMP ($E2,X)
C2/AE18: 20 A9 08     JSR $08A9
C2/AE1B: 1C 00 75     TRB $7500
C2/AE1E: 9C 02 75     STZ $7502
C2/AE21: 9C 05 75     STZ $7505
C2/AE24: A9 04        LDA #$04
C2/AE26: 1C 0E 75     TRB $750E
C2/AE29: A9 04        LDA #$04
C2/AE2B: 04 CA        TSB $CA
C2/AE2D: 20 98 A6     JSR $A698
C2/AE30: 60           RTS 
C2/AE31: A5 55        LDA $55
C2/AE33: 29 0F        AND #$0F
C2/AE35: 00 C9        BRK $C9
C2/AE37: 09 00        ORA #$00
C2/AE39: F0 05        BEQ $AE40
C2/AE3B: 20 F6 F3     JSR $F3F6
C2/AE3E: 80 03        BRA $AE43
C2/AE40: 20 50 F4     JSR $F450
C2/AE43: 20 F0 FA     JSR $FAF0
C2/AE46: 60           RTS 
C2/AE47: 9C 6E 2B     STZ $2B6E
C2/AE4A: 60           RTS 
C2/AE4B: E2 20        SEP #$20
C2/AE4D: AD 6F 2B     LDA $2B6F
C2/AE50: F0 09        BEQ $AE5B
C2/AE52: AD 65 2B     LDA $2B65
C2/AE55: 29 01        AND #$01
C2/AE57: 49 01        EOR #$01
C2/AE59: 85 53        STA $53
C2/AE5B: 60           RTS 

C2/AE5C: 20 4C AB     JSR $AB4C
C2/AE5F: A9 08        LDA #$08
C2/AE61: 20 E7 EE     JSR $EEE7
C2/AE64: AD 86 28     LDA $2886
C2/AE67: 8D 0F 75     STA $750F
C2/AE6A: 60           RTS 

C2/AE6B: 20 A0 AB     JSR $ABA0
C2/AE6E: 60           RTS 

C2/AE6F: 20 BD B2     JSR $B2BD
C2/AE72: C2 20        REP #$20
C2/AE74: A2 00 05     LDX #$0500
C2/AE77: A0 00 20     LDY #$2000
C2/AE7A: A9 FF 05     LDA #$05FF
C2/AE7D: 54 7E 7E     MVN $7E,$7E
C2/AE80: 20 7D BF     JSR $BF7D       ; get pointer to save slot in sram
C2/AE83: AA           TAX 
C2/AE84: A0 00 05     LDY #$0500
C2/AE87: A9 FF 05     LDA #$05FF
C2/AE8A: 8B           PHB 
C2/AE8B: 54 00 30     MVN $00,$30     ; load sram
C2/AE8E: AB           PLB 
C2/AE8F: 20 30 D2     JSR $D230
C2/AE92: 20 DB D3     JSR $D3DB
C2/AE95: 20 47 D4     JSR $D447       ; update window color
C2/AE98: 20 6E A1     JSR $A16E       ; reset sprite data
C2/AE9B: A2 94 F3     LDX #$F394
C2/AE9E: 20 4C D0     JSR $D04C
C2/AEA1: 20 DB D4     JSR $D4DB
C2/AEA4: A2 EE 66     LDX #$66EE
C2/AEA7: 20 58 D6     JSR $D658
C2/AEAA: A2 30 66     LDX #$6630
C2/AEAD: A0 4A 09     LDY #$094A
C2/AEB0: 20 62 D6     JSR $D662
C2/AEB3: A9 B8 B5     LDA #$B5B8
C2/AEB6: 20 B8 C1     JSR $C1B8
C2/AEB9: A5 43        LDA $43         ; menu state
C2/AEBB: 29 FF 00     AND #$00FF
C2/AEBE: C9 0C 00     CMP #$000C
C2/AEC1: F0 05        BEQ $AEC8
C2/AEC3: A9 DF B5     LDA #$B5DF
C2/AEC6: 80 03        BRA $AECB
C2/AEC8: A9 CF B5     LDA #$B5CF
C2/AECB: 20 B8 C1     JSR $C1B8
C2/AECE: A2 00 20     LDX #$2000
C2/AED1: A0 00 05     LDY #$0500
C2/AED4: A9 FF 05     LDA #$05FF
C2/AED7: 54 7E 7E     MVN $7E,$7E
C2/AEDA: E2 20        SEP #$20
C2/AEDC: 20 06 A1     JSR $A106
C2/AEDF: AD 0E 75     LDA $750E
C2/AEE2: 8F 0C 42 00  STA $00420C
C2/AEE6: AF 10 42 00  LDA $004210
C2/AEEA: A9 81        LDA #$81
C2/AEEC: 8F 00 42 00  STA $004200
C2/AEF0: A9 00        LDA #$00
C2/AEF2: 8D 22 75     STA $7522
C2/AEF5: 8D 25 75     STA $7525
C2/AEF8: A9 03        LDA #$03
C2/AEFA: 8D 13 75     STA $7513
C2/AEFD: 20 98 A6     JSR $A698
C2/AF00: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/AF03: 20 F0 FA     JSR $FAF0
C2/AF06: A9 0C        LDA #$0C
C2/AF08: 0C 00 75     TSB $7500
C2/AF0B: 0C 02 75     TSB $7502
C2/AF0E: A9 02        LDA #$02
C2/AF10: 1C 00 75     TRB $7500
C2/AF13: A9 04        LDA #$04
C2/AF15: 04 CA        TSB $CA
C2/AF17: 20 9D A6     JSR $A69D
C2/AF1A: 60           RTS 

C2/AF1B: 8B           PHB 
C2/AF1C: 08           PHP 
C2/AF1D: A2 84 F3     LDX #$F384
C2/AF20: 20 4C D0     JSR $D04C
C2/AF23: A6 8E        LDX $8E
C2/AF25: BD 42 02     LDA $0242,X
C2/AF28: 09 00        ORA #$00
C2/AF2A: 20 9D 42     JSR $429D
C2/AF2D: 02 BD        COP $BD
C2/AF2F: 22 02 F0 06  JSL $06F002
C2/AF33: 09 00        ORA #$00
C2/AF35: 20 9D 22     JSR $229D
C2/AF38: 02 E8        COP $E8
C2/AF3A: E8           INX 
C2/AF3B: E8           INX 
C2/AF3C: E8           INX 
C2/AF3D: E0 20 00     CPX #$0020
C2/AF40: D0 E3        BNE $AF25
C2/AF42: A9 0D        LDA #$0D
C2/AF44: B5 20        LDA $20,X
C2/AF46: B8           CLV 
C2/AF47: C1 A2        CMP ($A2,X)
C2/AF49: 6A           ROR 
C2/AF4A: F3 A9        SBC ($A9,S),Y
C2/AF4C: 11 00        ORA ($00),Y
C2/AF4E: 20 9D DA     JSR $DA9D
C2/AF51: 64 7E        STZ $7E
C2/AF53: A5 7E        LDA $7E
C2/AF55: 0A           ASL 
C2/AF56: AA           TAX 
C2/AF57: BF 62 F3 C0  LDA $C0F362,X
C2/AF5B: 8D BA 2B     STA $2BBA
C2/AF5E: 20 D7 DD     JSR $DDD7
C2/AF61: A5 7E        LDA $7E
C2/AF63: 1A           INC 
C2/AF64: 85 7E        STA $7E
C2/AF66: C9 04        CMP #$04
C2/AF68: 00 D0        BRK $D0
C2/AF6A: E8           INX 
C2/AF6B: 20 93 A6     JSR $A693
C2/AF6E: C2 20        REP #$20
C2/AF70: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/AF73: 20 F0 FA     JSR $FAF0
C2/AF76: E2 20        SEP #$20
C2/AF78: A5 53        LDA $53
C2/AF7A: 85 50        STA $50
C2/AF7C: A5 55        LDA $55
C2/AF7E: 85 52        STA $52
C2/AF80: A5 54        LDA $54
C2/AF82: 85 51        STA $51
C2/AF84: 28           PLP 
C2/AF85: AB           PLB 
C2/AF86: 60           RTS 
C2/AF87: A5 71        LDA $71
C2/AF89: 29 0F        AND #$0F
C2/AF8B: 00 85        BRK $85
C2/AF8D: 7E 20 C5     ROR $C520,X
C2/AF90: D4 A9        PEI ($A9)
C2/AF92: 18           CLC 
C2/AF93: B5 20        LDA $20,X
C2/AF95: B8           CLV 
C2/AF96: C1 20        CMP ($20,X)
C2/AF98: 93 A6        STA ($A6,S),Y
C2/AF9A: 9C 10 75     STZ $7510
C2/AF9D: C2 20        REP #$20
C2/AF9F: A6 8E        LDX $8E
C2/AFA1: 9E 00 02     STZ $0200,X
C2/AFA4: E8           INX 
C2/AFA5: E8           INX 
C2/AFA6: E0 60 00     CPX #$0060
C2/AFA9: D0 F6        BNE $AFA1
C2/AFAB: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/AFAE: 20 6F E6     JSR $E66F
C2/AFB1: 60           RTS 
C2/AFB2: 9C EA 29     STZ $29EA
C2/AFB5: 9C EC 29     STZ $29EC
C2/AFB8: 9C 06 02     STZ $0206
C2/AFBB: 9C 0A 02     STZ $020A
C2/AFBE: 9C 0E 02     STZ $020E
C2/AFC1: 9C 12 02     STZ $0212
C2/AFC4: A5 55        LDA $55
C2/AFC6: 29 FF 00     AND #$00FF
C2/AFC9: C9 05 00     CMP #$0005
C2/AFCC: F0 26        BEQ $AFF4
C2/AFCE: E2 20        SEP #$20
C2/AFD0: A5 52        LDA $52
C2/AFD2: C9 05        CMP #$05
C2/AFD4: D0 08        BNE $AFDE
C2/AFD6: AD EE 29     LDA $29EE
C2/AFD9: 85 53        STA $53
C2/AFDB: 20 10 D2     JSR $D210
C2/AFDE: 20 92 A8     JSR $A892
C2/AFE1: C2 20        REP #$20
C2/AFE3: A5 55        LDA $55
C2/AFE5: 29 0F 00     AND #$000F
C2/AFE8: 3A           DEC 
C2/AFE9: AA           TAX 
C2/AFEA: E2 20        SEP #$20
C2/AFEC: FE EA 29     INC $29EA,X
C2/AFEF: 9C 10 75     STZ $7510
C2/AFF2: 80 5A        BRA $B04E
C2/AFF4: E2 20        SEP #$20
C2/AFF6: AD E6 29     LDA $29E6
C2/AFF9: 29 20        AND #$20
C2/AFFB: D0 08        BNE $B005
C2/AFFD: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B000: 20 CB A8     JSR $A8CB
C2/B003: 80 C9        BRA $AFCE
C2/B005: A4 8E        LDY $8E
C2/B007: C2 20        REP #$20
C2/B009: 98           TYA 
C2/B00A: 0A           ASL 
C2/B00B: AA           TAX 
C2/B00C: BF 64 EA C0  LDA $C0EA64,X
C2/B010: AA           TAX 
C2/B011: BD 00 05     LDA $0500,X
C2/B014: 29 40 00     AND #$0040
C2/B017: D0 1D        BNE $B036
C2/B019: 98           TYA 
C2/B01A: 0A           ASL 
C2/B01B: AA           TAX 
C2/B01C: BF 7C F3 C0  LDA $C0F37C,X
C2/B020: 48           PHA 
C2/B021: 98           TYA 
C2/B022: 0A           ASL 
C2/B023: 0A           ASL 
C2/B024: AA           TAX 
C2/B025: 68           PLA 
C2/B026: 9D 04 02     STA $0204,X
C2/B029: A9 02 2E     LDA #$2E02
C2/B02C: 9D 06 02     STA $0206,X
C2/B02F: E2 20        SEP #$20
C2/B031: A9 01        LDA #$01
C2/B033: 99 EA 29     STA $29EA,Y
C2/B036: C8           INY 
C2/B037: C0 04 00     CPY #$0004
C2/B03A: D0 CB        BNE $B007
C2/B03C: E2 20        SEP #$20
C2/B03E: A9 05        LDA #$05
C2/B040: 8D 10 75     STA $7510
C2/B043: A5 52        LDA $52
C2/B045: C9 05        CMP #$05
C2/B047: F0 05        BEQ $B04E
C2/B049: A5 50        LDA $50
C2/B04B: 8D EE 29     STA $29EE
C2/B04E: 60           RTS 
C2/B04F: 20 1B AF     JSR $AF1B
C2/B052: E2 20        SEP #$20
C2/B054: A9 08        LDA #$08
C2/B056: 1C 00 75     TRB $7500
C2/B059: A9 02        LDA #$02
C2/B05B: 0C 00 75     TSB $7500
C2/B05E: A9 04        LDA #$04
C2/B060: 04 CA        TSB $CA
C2/B062: 60           RTS 
C2/B063: E2 20        SEP #$20
C2/B065: A9 08        LDA #$08
C2/B067: 0C 00 75     TSB $7500
C2/B06A: A9 02        LDA #$02
C2/B06C: 1C 00 75     TRB $7500
C2/B06F: A9 04        LDA #$04
C2/B071: 04 CA        TSB $CA
C2/B073: C2 20        REP #$20
C2/B075: 20 91 AF     JSR $AF91
C2/B078: 60           RTS 
C2/B079: A9 E9 B7     LDA #$B7E9
C2/B07C: 20 B8 C1     JSR $C1B8
C2/B07F: A2 04 EA     LDX #$EA04
C2/B082: A9 09 00     LDA #$0009
C2/B085: 20 9D DA     JSR $DA9D
C2/B088: 20 C0 F5     JSR $F5C0
C2/B08B: A2 1D B9     LDX #$B91D
C2/B08E: A0 80 70     LDY #$7080
C2/B091: 20 FD C1     JSR $C1FD
C2/B094: A2 1E EA     LDX #$EA1E
C2/B097: A0 40 02     LDY #$0240
C2/B09A: A9 1F 00     LDA #$001F
C2/B09D: 54 7E C0     MVN $7E,$C0
C2/B0A0: 64 7E        STZ $7E
C2/B0A2: 20 C5 D4     JSR $D4C5
C2/B0A5: A4 80        LDY $80
C2/B0A7: B9 00 05     LDA $0500,Y
C2/B0AA: 29 40 00     AND #$0040
C2/B0AD: F0 12        BEQ $B0C1
C2/B0AF: A5 7E        LDA $7E
C2/B0B1: 0A           ASL 
C2/B0B2: 0A           ASL 
C2/B0B3: 0A           ASL 
C2/B0B4: AA           TAX 
C2/B0B5: 9E 40 02     STZ $0240,X
C2/B0B8: 9E 42 02     STZ $0242,X
C2/B0BB: 9E 44 02     STZ $0244,X
C2/B0BE: 9E 46 02     STZ $0246,X
C2/B0C1: A5 7E        LDA $7E
C2/B0C3: 1A           INC 
C2/B0C4: 85 7E        STA $7E
C2/B0C6: C9 04 00     CMP #$0004
C2/B0C9: D0 D7        BNE $B0A2
C2/B0CB: 64 6F        STZ $6F
C2/B0CD: 64 71        STZ $71
C2/B0CF: A9 20 00     LDA #$0020
C2/B0D2: 20 54 B1     JSR $B154
C2/B0D5: 60           RTS 
C2/B0D6: A9 39 B7     LDA #$B739
C2/B0D9: 20 B8 C1     JSR $C1B8
C2/B0DC: 20 93 A6     JSR $A693
C2/B0DF: A9 02 1C     LDA #$1C02
C2/B0E2: 00 75        BRK $75
C2/B0E4: A9 04 1C     LDA #$1C04
C2/B0E7: 09 75 A9     ORA #$A975
C2/B0EA: 20 1C 0E     JSR $0E1C
C2/B0ED: 75 A9        ADC $A9,X
C2/B0EF: 04 04        TSB $04
C2/B0F1: CA           DEX 
C2/B0F2: 20 6E A1     JSR $A16E       ; reset sprite data
C2/B0F5: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/B0F8: 20 6F E6     JSR $E66F
C2/B0FB: A9 00 8F     LDA #$8F00
C2/B0FE: 10 21        BPL $B121
C2/B100: 00 8F        BRK $8F
C2/B102: 10 21        BPL $B125
C2/B104: 00 60        BRK $60
C2/B106: A9 10 B7     LDA #$B710
C2/B109: 20 B8 C1     JSR $C1B8
C2/B10C: A9 14 00     LDA #$0014
C2/B10F: 8D 94 2C     STA $2C94
C2/B112: 64 7E        STZ $7E
C2/B114: 20 C5 D4     JSR $D4C5
C2/B117: A4 80        LDY $80
C2/B119: A5 7E        LDA $7E
C2/B11B: 0A           ASL 
C2/B11C: AA           TAX 
C2/B11D: BF 8E EA C0  LDA $C0EA8E,X
C2/B121: AA           TAX 
C2/B122: B9 00 05     LDA $0500,Y
C2/B125: 29 40 00     AND #$0040
C2/B128: D0 09        BNE $B133
C2/B12A: 9B           TXY 
C2/B12B: 20 33 D5     JSR $D533
C2/B12E: 20 A6 F7     JSR $F7A6
C2/B131: 80 0A        BRA $B13D
C2/B133: 9B           TXY 
C2/B134: A2 96 EA     LDX #$EA96
C2/B137: A9 31 00     LDA #$0031
C2/B13A: 54 7E C0     MVN $7E,$C0
C2/B13D: EE 94 2C     INC $2C94
C2/B140: E6 7E        INC $7E
C2/B142: A5 7E        LDA $7E
C2/B144: C9 04 00     CMP #$0004
C2/B147: 30 CB        BMI $B114
C2/B149: A9 00 00     LDA #$0000
C2/B14C: 20 54 B1     JSR $B154
C2/B14F: A9 0E 85     LDA #$850E
C2/B152: 50 60        BVC $B1B4
C2/B154: E2 20        SEP #$20
C2/B156: 0C 0E 75     TSB $750E
C2/B159: 20 93 A6     JSR $A693
C2/B15C: A9 02        LDA #$02
C2/B15E: 0C 00 75     TSB $7500
C2/B161: A9 04        LDA #$04
C2/B163: 0C 09 75     TSB $7509
C2/B166: A9 04        LDA #$04
C2/B168: 04 CA        TSB $CA
C2/B16A: 20 6F E6     JSR $E66F
C2/B16D: 60           RTS 
C2/B16E: E2 20        SEP #$20
C2/B170: 20 78 A8     JSR $A878
C2/B173: A5 55        LDA $55
C2/B175: 38           SEC 
C2/B176: E9 15        SBC #$15
C2/B178: 85 7E        STA $7E
C2/B17A: 20 C5 D4     JSR $D4C5
C2/B17D: A6 80        LDX $80
C2/B17F: 3C 00 05     BIT $0500,X
C2/B182: 50 0B        BVC $B18F
C2/B184: A5 7E        LDA $7E
C2/B186: 18           CLC 
C2/B187: 65 E2        ADC $E2
C2/B189: 29 03        AND #$03
C2/B18B: 85 7E        STA $7E
C2/B18D: 80 EB        BRA $B17A
C2/B18F: A5 7E        LDA $7E
C2/B191: 18           CLC 
C2/B192: 69 0F        ADC #$0F
C2/B194: 85 53        STA $53
C2/B196: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/B199: 60           RTS 
C2/B19A: A9 40        LDA #$40
C2/B19C: B7 20        LDA [$20],Y
C2/B19E: B8           CLV 
C2/B19F: C1 A2        CMP ($A2,X)
C2/B1A1: 35 B9        AND $B9,X
C2/B1A3: A0 80 70     LDY #$7080
C2/B1A6: 20 FD C1     JSR $C1FD
C2/B1A9: A9 28        LDA #$28
C2/B1AB: 00 8D        BRK $8D
C2/B1AD: 94 2C        STY $2C,X
C2/B1AF: 20 A6 F7     JSR $F7A6
C2/B1B2: EE 94 2C     INC $2C94
C2/B1B5: AD 94 2C     LDA $2C94
C2/B1B8: C9 2F        CMP #$2F
C2/B1BA: 00 30        BRK $30
C2/B1BC: F2 A9        SBC ($A9)
C2/B1BE: 7A           PLY 
C2/B1BF: B7 20        LDA [$20],Y
C2/B1C1: B8           CLV 
C2/B1C2: C1 A9        CMP ($A9,X)
C2/B1C4: 20 00 20     JSR $2000
C2/B1C7: 54 B1 60     MVN $B1,$60
C2/B1CA: E2 20        SEP #$20
C2/B1CC: A5 71        LDA $71
C2/B1CE: 29 0F        AND #$0F
C2/B1D0: D0 04        BNE $B1D6
C2/B1D2: A5 52        LDA $52
C2/B1D4: 85 71        STA $71
C2/B1D6: 3A           DEC 
C2/B1D7: 85 7E        STA $7E
C2/B1D9: 20 C5 D4     JSR $D4C5
C2/B1DC: A6 80        LDX $80
C2/B1DE: 3C 00 05     BIT $0500,X
C2/B1E1: 50 08        BVC $B1EB
C2/B1E3: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B1E6: 64 71        STZ $71
C2/B1E8: 20 CB A8     JSR $A8CB
C2/B1EB: 60           RTS 

C2/B1EC: A9 C2 B3     LDA #$B3C2
C2/B1EF: 20 B8 C1     JSR $C1B8
C2/B1F2: AD 1B 2D     LDA $2D1B
C2/B1F5: A0 84 42     LDY #$4284
C2/B1F8: 20 4E E4     JSR $E44E
C2/B1FB: 20 CC CE     JSR $CECC       ; get list of available jobs
C2/B1FE: 64 85        STZ $85
C2/B200: A4 85        LDY 
C2/B202: B9 00 7A     LDA $7A00,Y
C2/B205: 29 FF 00     AND #$00FF
C2/B208: C9 FF 00     CMP #$00FF
C2/B20B: F0 44        BEQ $B251
C2/B20D: C9 15 00     CMP #$0015
C2/B210: F0 3F        BEQ $B251
C2/B212: 0A           ASL 
C2/B213: 0A           ASL 
C2/B214: AA           TAX 
C2/B215: A5 85        LDA $85
C2/B217: 0A           ASL 
C2/B218: A8           TAY 
C2/B219: BF 08 57 D1  LDA $D15708,X   ; job equipment types
C2/B21D: 2D 1D 2D     AND $2D1D
C2/B220: 99 21 2D     STA $2D21,Y
C2/B223: BF 0A 57 D1  LDA $D1570A,X
C2/B227: 2D 1F 2D     AND $2D1F
C2/B22A: 19 21 2D     ORA $2D21,Y
C2/B22D: 48           PHA 
C2/B22E: BB           TYX 
C2/B22F: BF 01 E9 C0  LDA $C0E901,X
C2/B233: 85 99        STA $99
C2/B235: A4 85        LDY $85
C2/B237: B9 00 7A     LDA $7A00,Y
C2/B23A: 29 FF 00     AND #$00FF
C2/B23D: A4 99        LDY $99
C2/B23F: 20 C7 E4     JSR $E4C7
C2/B242: 68           PLA 
C2/B243: D0 08        BNE $B24D
C2/B245: A9 08 01     LDA #$0108
C2/B248: A6 99        LDX $99
C2/B24A: 20 DC D6     JSR $D6DC
C2/B24D: E6 85        INC $85
C2/B24F: 80 AF        BRA B200
C2/B251: A5 8E        LDA $8E
C2/B253: 20 54 B1     JSR $B154
C2/B256: 60           RTS 

C2/B257: 20 D6 B0     JSR $B0D6
C2/B25A: 60           RTS 

; [  ]

C2/B25B: 4C F0 A4     JMP $A4F0

; [  ]

C2/B25E: A5 53        LDA $53
C2/B260: 85 59        STA $59
C2/B262: C9 00        CMP #$00
C2/B264: F0 38        BEQ $B29E
C2/B266: C9 01        CMP #$01
C2/B268: F0 47        BEQ $B2B1
C2/B26A: C9 03        CMP #$03
C2/B26C: F0 1C        BEQ $B28A
C2/B26E: C9 04        CMP #$04
C2/B270: F0 18        BEQ $B28A
C2/B272: C9 05        CMP #$05
C2/B274: F0 14        BEQ $B28A
C2/B276: C9 02        CMP #$02
C2/B278: F0 19        BEQ $B293
C2/B27A: C9 07        CMP #$07
C2/B27C: F0 11        BEQ $B28F
C2/B27E: C9 06        CMP #$06
C2/B280: F0 11        BEQ $B293
C2/B282: 80 03        BRA $B287
C2/B284: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B287: 4C F0 A4     JMP $A4F0
C2/B28A: A9 0C        LDA #$0C
C2/B28C: 4C 7C A4     JMP $A47C
C2/B28F: A5 44        LDA $44
C2/B291: 10 F1        BPL $B284
C2/B293: 20 BD B2     JSR $B2BD
C2/B296: 20 E2 C0     JSR $C0E2
C2/B299: A5 55        LDA $55
C2/B29B: 4C 6B A0     JMP $A06B       ; show menu
C2/B29E: C2 20        REP #$20
C2/B2A0: AD 40 08     LDA $0840       ; available jobs
C2/B2A3: D0 08        BNE $B2AD
C2/B2A5: AD 42 08     LDA $0842
C2/B2A8: 29 F8 00     AND #$00F8
C2/B2AB: F0 D7        BEQ $B284
C2/B2AD: E2 20        SEP #$20
C2/B2AF: 80 D9        BRA $B28A
C2/B2B1: C2 20        REP #$20
C2/B2B3: AD F3 08     LDA $08F3
C2/B2B6: 0D F5 08     ORA $08F5
C2/B2B9: D0 F2        BNE $B2AD
C2/B2BB: 80 C7        BRA $B284
C2/B2BD: E2 20        SEP #$20
C2/B2BF: A9 00        LDA #$00
C2/B2C1: 8F 10 75 7E  STA $7E7510
C2/B2C5: 8F 0F 75 7E  STA $7E750F
C2/B2C9: 8F 1D 75 7E  STA $7E751D
C2/B2CD: 8F 1E 75 7E  STA $7E751E
C2/B2D1: 64 CA        STZ $CA
C2/B2D3: A9 04        LDA #$04
C2/B2D5: 8F 13 75 7E  STA $7E7513
C2/B2D9: 20 6F E6     JSR $E66F
C2/B2DC: 20 2F FC     JSR $FC2F
C2/B2DF: AF 13 75 7E  LDA $7E7513
C2/B2E3: D0 F4        BNE $B2D9
C2/B2E5: A9 01        LDA #$01
C2/B2E7: 8F 00 42 00  STA $004200
C2/B2EB: 20 06 A1     JSR $A106
C2/B2EE: A9 00        LDA #$00
C2/B2F0: 8F 0C 42 00  STA $00420C
C2/B2F4: A9 80        LDA #$80
C2/B2F6: 8F 00 21 00  STA $002100
C2/B2FA: 60           RTS 
C2/B2FB: A5 53        LDA $53
C2/B2FD: 85 59        STA $59
C2/B2FF: 4C 2D A0     JMP $A02D       ; exit menu

; [ order/row A button pressed ]

C2/B302: A5 6F        LDA $6F
C2/B304: D0 11        BNE $B317       ; branch if first selection is made
C2/B306: A5 55        LDA $55
C2/B308: 85 6F        STA $6F         ; select first character
C2/B30A: A5 53        LDA $53
C2/B30C: 20 C4 C0     JSR $C0C4
C2/B30F: A9 01        LDA #$01
C2/B311: 8D 10 75     STA $7510
C2/B314: 4C F0 A4     JMP $A4F0
C2/B317: A5 55        LDA $55
C2/B319: 85 70        STA $70
C2/B31B: C5 6F        CMP $6F
C2/B31D: D0 26        BNE $B345       ; branch if not the same character
C2/B31F: 3A           DEC 
C2/B320: 85 7E        STA $7E
C2/B322: 20 C5 D4     JSR $D4C5
C2/B325: A6 80        LDX $80
C2/B327: BD 00 05     LDA $0500,X     ; toggle character row
C2/B32A: 49 80        EOR #$80
C2/B32C: 9D 00 05     STA $0500,X
C2/B32F: A2 94 F3     LDX #$F394
C2/B332: 20 4C D0     JSR $D04C
C2/B335: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/B338: 20 E2 C0     JSR $C0E2
C2/B33B: 64 6F        STZ $6F
C2/B33D: E2 20        SEP #$20
C2/B33F: 9C 10 75     STZ $7510
C2/B342: 4C F0 A4     JMP $A4F0
C2/B345: C6 6F        DEC $6F
C2/B347: C6 70        DEC $70
C2/B349: 9C 10 75     STZ $7510
C2/B34C: C2 20        REP #$20
C2/B34E: A5 6F        LDA $6F
C2/B350: 20 E9 B3     JSR $B3E9
C2/B353: A5 70        LDA $70
C2/B355: 20 E9 B3     JSR $B3E9
C2/B358: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/B35B: 20 6F E6     JSR $E66F
C2/B35E: 8B           PHB 
C2/B35F: E2 20        SEP #$20
C2/B361: A9 C0        LDA #$C0
C2/B363: 48           PHA 
C2/B364: AB           PLB 
C2/B365: C2 20        REP #$20
C2/B367: A5 6F        LDA $6F
C2/B369: 29 03 00     AND #$0003
C2/B36C: 0A           ASL 
C2/B36D: AA           TAX 
C2/B36E: A5 70        LDA $70
C2/B370: 29 03 00     AND #$0003
C2/B373: 0A           ASL 
C2/B374: A8           TAY 
C2/B375: BD FB EF     LDA $EFFB,X
C2/B378: 85 E0        STA $E0
C2/B37A: B9 FB EF     LDA $EFFB,Y
C2/B37D: 85 E2        STA $E2
C2/B37F: A9 53 F0     LDA #$F053
C2/B382: 85 E4        STA $E4
C2/B384: B2 E0        LDA ($E0)
C2/B386: AA           TAX 
C2/B387: B2 E2        LDA ($E2)
C2/B389: A8           TAY 
C2/B38A: B2 E4        LDA ($E4)
C2/B38C: F0 11        BEQ $B39F
C2/B38E: 20 10 E6     JSR $E610
C2/B391: E6 E0        INC $E0
C2/B393: E6 E0        INC $E0
C2/B395: E6 E2        INC $E2
C2/B397: E6 E2        INC $E2
C2/B399: E6 E4        INC $E4
C2/B39B: E6 E4        INC $E4
C2/B39D: 80 E5        BRA $B384
C2/B39F: AB           PLB 
C2/B3A0: C2 20        REP #$20
C2/B3A2: A5 6F        LDA $6F
C2/B3A4: 20 DB B3     JSR $B3DB
C2/B3A7: A2 94 F3     LDX #$F394
C2/B3AA: 20 4C D0     JSR $D04C
C2/B3AD: 20 E2 C0     JSR $C0E2
C2/B3B0: A5 70        LDA $70
C2/B3B2: 20 DB B3     JSR $B3DB
C2/B3B5: 20 F0 FA     JSR $FAF0
C2/B3B8: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/B3BB: 20 6F E6     JSR $E66F
C2/B3BE: 20 DB D4     JSR $D4DB
C2/B3C1: 64 CA        STZ $CA
C2/B3C3: 20 98 A6     JSR $A698
C2/B3C6: A5 6F        LDA $6F
C2/B3C8: 8D 00 00     STA $0000
C2/B3CB: A5 70        LDA $70
C2/B3CD: 8D 01 00     STA $0001
C2/B3D0: 22 09 00 C1  JSL $C10009     ; swap character saved cursor positions
C2/B3D4: 64 6F        STZ $6F
C2/B3D6: 64 70        STZ $70
C2/B3D8: 4C F0 A4     JMP $A4F0

; [  ]

C2/B3DB: 29 03 00     AND #$0003
C2/B3DE: 0A           ASL 
C2/B3DF: AA           TAX 
C2/B3E0: BF CD F3 C0  LDA $C0F3CD,X
C2/B3E4: AA           TAX 
C2/B3E5: 20 A0 A6     JSR $A6A0
C2/B3E8: 60           RTS 
C2/B3E9: 29 03 00     AND #$0003
C2/B3EC: 0A           ASL 
C2/B3ED: AA           TAX 
C2/B3EE: BF 08 EB C0  LDA $C0EB08,X
C2/B3F2: AA           TAX 
C2/B3F3: 9E 00 00     STZ $0000,X
C2/B3F6: 9E 02 00     STZ $0002,X
C2/B3F9: 9E 04 00     STZ $0004,X
C2/B3FC: 9E 06 00     STZ $0006,X
C2/B3FF: 8A           TXA 
C2/B400: 38           SEC 
C2/B401: E9 20 00     SBC #$0020
C2/B404: AA           TAX 
C2/B405: 9E 00 00     STZ $0000,X
C2/B408: 9E 02 00     STZ $0002,X
C2/B40B: 60           RTS 

; [ order/row B button pressed ]

C2/B40C: 20 E2 C0     JSR $C0E2
C2/B40F: 9C 10 75     STZ $7510
C2/B412: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/B415: A5 6F        LDA $6F
C2/B417: D0 09        BNE $B422
C2/B419: A5 53        LDA $53
C2/B41B: 85 5A        STA $5A
C2/B41D: A5 59        LDA $59
C2/B41F: 4C 7C A4     JMP $A47C
C2/B422: 64 6F        STZ $6F
C2/B424: 64 70        STZ $70
C2/B426: 4C F0 A4     JMP $A4F0

; [  ]

C2/B429: A5 55        LDA $55
C2/B42B: 3A           DEC 
C2/B42C: 85 71        STA $71
C2/B42E: C2 20        REP #$20
C2/B430: 29 0F 00     AND #$000F
C2/B433: 0A           ASL 
C2/B434: AA           TAX 
C2/B435: BF 64 EA C0  LDA $C0EA64,X
C2/B439: A8           TAY 
C2/B43A: E2 20        SEP #$20
C2/B43C: A5 59        LDA $59
C2/B43E: 20 E1 E4     JSR $E4E1       ; get pointer to cursor data
C2/B441: BD 01 76     LDA $7601,X
C2/B444: C9 05        CMP #$05
C2/B446: F0 1B        BEQ $B463
C2/B448: C9 02        CMP #$02
C2/B44A: D0 10        BNE $B45C
C2/B44C: A5 55        LDA $55
C2/B44E: 3A           DEC 
C2/B44F: C2 20        REP #$20
C2/B451: 29 0F 00     AND #$000F
C2/B454: AA           TAX 
C2/B455: E2 20        SEP #$20
C2/B457: BD F3 08     LDA $08F3,X
C2/B45A: F0 1E        BEQ $B47A
C2/B45C: B9 1A 05     LDA $051A,Y
C2/B45F: 29 C2        AND #$C2
C2/B461: D0 17        BNE $B47A
C2/B463: A5 53        LDA $53
C2/B465: 29 0B        AND #$0B
C2/B467: 85 5A        STA $5A
C2/B469: 20 E2 C0     JSR $C0E2
C2/B46C: 20 BD B2     JSR $B2BD
C2/B46F: A5 59        LDA $59
C2/B471: 20 E1 E4     JSR $E4E1       ; get pointer to cursor data
C2/B474: BD 01 76     LDA $7601,X
C2/B477: 4C 6B A0     JMP $A06B       ; show menu
C2/B47A: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B47D: 4C F0 A4     JMP $A4F0
C2/B480: 9C 10 75     STZ $7510
C2/B483: A5 53        LDA $53
C2/B485: 38           SEC 
C2/B486: E9 04        SBC #$04
C2/B488: 85 5A        STA $5A
C2/B48A: A5 59        LDA $59
C2/B48C: 4C 7C A4     JMP $A47C
C2/B48F: A5 55        LDA $55
C2/B491: C9 04        CMP #$04
C2/B493: F0 13        BEQ $B4A8
C2/B495: A9 01        LDA #$01
C2/B497: 8D 10 75     STA $7510
C2/B49A: A5 55        LDA $55
C2/B49C: 85 6F        STA $6F
C2/B49E: A5 53        LDA $53
C2/B4A0: 20 C0 C0     JSR $C0C0
C2/B4A3: A9 04        LDA #$04
C2/B4A5: 4C 7C A4     JMP $A47C
C2/B4A8: A5 45        LDA $45
C2/B4AA: 10 04        BPL $B4B0
C2/B4AC: 29 02        AND #$02
C2/B4AE: D0 24        BNE $B4D4
C2/B4B0: C2 20        REP #$20
C2/B4B2: 9C 00 02     STZ $0200
C2/B4B5: 9C 02 02     STZ $0202
C2/B4B8: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/B4BB: E2 20        SEP #$20
C2/B4BD: AD 12 2D     LDA $2D12
C2/B4C0: 0D 11 2D     ORA $2D11
C2/B4C3: F0 07        BEQ $B4CC
C2/B4C5: 20 76 B6     JSR $B676
C2/B4C8: A9 04        LDA #$04
C2/B4CA: 80 05        BRA $B4D1
C2/B4CC: 20 BD B2     JSR $B2BD
C2/B4CF: A9 01        LDA #$01
C2/B4D1: 4C 6B A0     JMP $A06B       ; show menu
C2/B4D4: 4C F0 A4     JMP $A4F0

; [  ]

C2/B4D7: C2 20        REP #$20
C2/B4D9: A5 55        LDA $55
C2/B4DB: 29 FF 00     AND #$00FF
C2/B4DE: 3A           DEC 
C2/B4DF: 18           CLC 
C2/B4E0: 65 6B        ADC $6B
C2/B4E2: AA           TAX 
C2/B4E3: A4 80        LDY $80
C2/B4E5: B9 01 05     LDA $0501,Y     ; job
C2/B4E8: 29 FF 00     AND #$00FF
C2/B4EB: A8           TAY 
C2/B4EC: A5 6F        LDA $6F
C2/B4EE: 29 FF 00     AND #$00FF
C2/B4F1: C0 14 00     CPY #$0014
C2/B4F4: F0 01        BEQ $B4F7       ; branch if mimic
C2/B4F6: 3A           DEC 
C2/B4F7: 18           CLC 
C2/B4F8: 65 80        ADC $80
C2/B4FA: A8           TAY 
C2/B4FB: E2 20        SEP #$20
C2/B4FD: BD 00 7A     LDA $7A00,X
C2/B500: 99 16 05     STA $0516,Y
C2/B503: A9 01        LDA #$01
C2/B505: 8D 12 2D     STA $2D12
C2/B508: 20 73 E9     JSR $E973
C2/B50B: 20 A4 CF     JSR $CFA4
C2/B50E: 20 98 A6     JSR $A698
C2/B511: 20 E2 C0     JSR $C0E2
C2/B514: 9C 10 75     STZ $7510
C2/B517: A5 6F        LDA $6F
C2/B519: 3A           DEC 
C2/B51A: 64 6F        STZ $6F
C2/B51C: 64 70        STZ $70
C2/B51E: 4C 7C A4     JMP $A47C

; [  ]

C2/B521: A5 6F        LDA $6F
C2/B523: F0 03        BEQ $B528
C2/B525: 4C 6D B5     JMP $B56D
C2/B528: A5 55        LDA $55
C2/B52A: 85 6F        STA $6F
C2/B52C: C2 20        REP #$20
C2/B52E: 29 FF 00     AND #$00FF
C2/B531: 3A           DEC 
C2/B532: 0A           ASL 
C2/B533: 0A           ASL 
C2/B534: 0A           ASL 
C2/B535: AA           TAX 
C2/B536: BD 92 02     LDA $0292,X
C2/B539: 29 00 FE     AND #$FE00
C2/B53C: 9D 92 02     STA $0292,X
C2/B53F: 9D 96 02     STA $0296,X
C2/B542: BD 90 02     LDA $0290,X
C2/B545: 8D 40 02     STA $0240
C2/B548: BD 94 02     LDA $0294,X
C2/B54B: 8D 44 02     STA $0244
C2/B54E: A9 8C 0B     LDA #$0B8C
C2/B551: 8D 42 02     STA $0242
C2/B554: A9 AC 0B     LDA #$0BAC
C2/B557: 8D 46 02     STA $0246
C2/B55A: E2 20        SEP #$20
C2/B55C: 20 F0 FA     JSR $FAF0
C2/B55F: 9C 1E 75     STZ $751E
C2/B562: 9C 1D 75     STZ $751D
C2/B565: A9 01        LDA #$01
C2/B567: 8D 0F 75     STA $750F
C2/B56A: 4C F0 A4     JMP $A4F0
C2/B56D: A5 55        LDA $55
C2/B56F: 85 70        STA $70
C2/B571: A9 01        LDA #$01
C2/B573: 8D 11 2D     STA $2D11
C2/B576: 9C 0F 75     STZ $750F
C2/B579: 9C 1E 75     STZ $751E
C2/B57C: C2 20        REP #$20
C2/B57E: 20 03 D5     JSR $D503
C2/B581: 20 64 E4     JSR $E464
C2/B584: A5 6F        LDA $6F
C2/B586: 29 FF 00     AND #$00FF
C2/B589: 3A           DEC 
C2/B58A: AA           TAX 
C2/B58B: BD 00 7A     LDA $7A00,X
C2/B58E: 29 1F 00     AND #$001F
C2/B591: 85 D8        STA $D8
C2/B593: 20 7D E4     JSR $E47D
C2/B596: A4 80        LDY $80
C2/B598: A5 DC        LDA $DC
C2/B59A: 99 3B 05     STA $053B,Y
C2/B59D: E2 20        SEP #$20
C2/B59F: A5 DA        LDA $DA
C2/B5A1: 99 3A 05     STA $053A,Y
C2/B5A4: A5 D8        LDA $D8
C2/B5A6: 99 01 05     STA $0501,Y
C2/B5A9: C2 20        REP #$20
C2/B5AB: 20 C6 CD     JSR $CDC6
C2/B5AE: 20 5F D4     JSR $D45F
C2/B5B1: 20 98 D2     JSR $D298
C2/B5B4: C2 20        REP #$20
C2/B5B6: 64 6F        STZ $6F
C2/B5B8: 9C 40 02     STZ $0240
C2/B5BB: 9C 42 02     STZ $0242
C2/B5BE: 9C 44 02     STZ $0244
C2/B5C1: 9C 46 02     STZ $0246
C2/B5C4: A5 7E        LDA $7E
C2/B5C6: 20 DB B3     JSR $B3DB
C2/B5C9: 20 E3 CD     JSR $CDE3       ; init job sprites
C2/B5CC: 20 57 CD     JSR $CD57
C2/B5CF: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/B5D2: 20 F0 FA     JSR $FAF0
C2/B5D5: 20 6F E6     JSR $E66F
C2/B5D8: 64 CA        STZ $CA
C2/B5DA: 20 98 A6     JSR $A698
C2/B5DD: 20 A4 DA     JSR $DAA4
C2/B5E0: DA           PHX 
C2/B5E1: A6 7E        LDX $7E
C2/B5E3: FE 20 04     INC $0420,X
C2/B5E6: FA           PLX 
C2/B5E7: 20 82 EB     JSR $EB82
C2/B5EA: A5 6F        LDA $6F
C2/B5EC: D0 49        BNE $B637
C2/B5EE: A5 45        LDA $45
C2/B5F0: 10 07        BPL $B5F9
C2/B5F2: 29 01        AND #$01
C2/B5F4: F0 03        BEQ $B5F9
C2/B8F6: 4C F0 A4     JMP $A4F0
C2/B5F9: AD 11 2D     LDA $2D11
C2/B5FC: D0 08        BNE $B606
C2/B5FE: 20 BD B2     JSR $B2BD
C2/B601: A9 01        LDA #$01
C2/B603: 4C 6B A0     JMP $A06B
C2/B606: A6 7E        LDX $7E
C2/B608: BD F3 08     LDA $08F3,X
C2/B60B: F0 22        BEQ $B62F
C2/B60D: C2 20        REP #$20
C2/B60F: A9 2B        LDA #$2B
C2/B611: AF 20 B8 C1  LDA $C1B820
C2/B615: 20 93 A6     JSR $A693
C2/B618: A9 02        LDA #$02
C2/B61A: 0C 00 75     TSB $7500
C2/B61D: A9 04        LDA #$04
C2/B61F: 04 CA        TSB $CA
C2/B621: A2 28 00     LDX #$0028
C2/B624: 20 5B E6     JSR $E65B
C2/B627: 20 BD B2     JSR $B2BD
C2/B62A: A9 02        LDA #$02
C2/B62C: 4C 6B A0     JMP $A06B
C2/B62F: 20 76 B6     JSR $B676
C2/B632: A9 04        LDA #$04
C2/B634: 4C 6B A0     JMP $A06B
C2/B637: 9C 0F 75     STZ $750F
C2/B63A: 9C 1E 75     STZ $751E
C2/B63D: C2 20        REP #$20
C2/B63F: 9C 42 02     STZ $0242
C2/B642: 9C 46 02     STZ $0246
C2/B645: A5 6F        LDA $6F
C2/B647: 29 FF 00     AND #$00FF
C2/B64A: 3A           DEC 
C2/B64B: A8           TAY 
C2/B64C: B9 00 7A     LDA $7A00,Y
C2/B64F: 29 FF 00     AND #$00FF
C2/B652: AA           TAX 
C2/B653: BF 6A EE C0  LDA $C0EE6A,X
C2/B657: 29 FF 00     AND #$00FF
C2/B65A: 09 00 0B     ORA #$0B00
C2/B65D: 48           PHA 
C2/B65E: 98           TYA 
C2/B65F: 0A           ASL 
C2/B660: 0A           ASL 
C2/B661: 0A           ASL 
C2/B662: A8           TAY 
C2/B663: 68           PLA 
C2/B664: 99 92 02     STA $0292,Y
C2/B667: 18           CLC 
C2/B668: 69 20 00     ADC #$0020
C2/B66B: 99 96 02     STA $0296,Y
C2/B66E: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/B671: 64 6F        STZ $6F
C2/B673: 4C F0 A4     JMP $A4F0
C2/B676: 08           PHP 
C2/B677: E2 20        SEP #$20
C2/B679: AD 73 09     LDA $0973
C2/B67C: 29 01        AND #$01
C2/B67E: C2 20        REP #$20
C2/B680: D0 05        BNE $B687
C2/B682: A9 C8 AE     LDA #$AEC8
C2/B685: 80 03        BRA $B68A
C2/B687: A9 D9 AE     LDA #$AED9
C2/B68A: 20 B8 C1     JSR $C1B8
C2/B68D: 20 93 A6     JSR $A693
C2/B690: A9 02 0C     LDA #$0C02
C2/B693: 00 75        BRK $75
C2/B695: A9 04 04     LDA #$0404
C2/B698: CA           DEX 
C2/B699: 20 58 E6     JSR $E658
C2/B69C: 20 BD B2     JSR $B2BD
C2/B69F: 20 A4 DA     JSR $DAA4
C2/B6A2: A6 7E        LDX $7E
C2/B6A4: FE 20 04     INC $0420,X
C2/B6A7: 20 D6 E6     JSR $E6D6
C2/B6AA: AD 73 09     LDA $0973
C2/B6AD: 29 01 D0     AND #$D001
C2/B6B0: 06 20        ASL $20
C2/B6B2: AD FA 20     LDA $20FA
C2/B6B5: 69 F8 28     ADC #$28F8
C2/B6B8: 60           RTS 
C2/B6B9: A5 74        LDA $74
C2/B6BB: C9 03 F0     CMP #$F003
C2/B6BE: 07 C9        ORA [$C9]
C2/B6C0: 04 F0        TSB $F0
C2/B6C2: 30 4C        BMI $B710
C2/B6C4: F0 A4        BEQ $B66A
C2/B6C6: A5 55        LDA $55
C2/B6C8: 85 6F        STA $6F
C2/B6CA: 64 70        STZ $70
C2/B6CC: 20 78 E1     JSR $E178
C2/B6CF: 20 11 E2     JSR $E211
C2/B6D2: A5 73        LDA $73
C2/B6D4: 20 86 E2     JSR $E286
C2/B6D7: A5 90        LDA $90
C2/B6D9: F0 05        BEQ $B6E0
C2/B6DB: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B6DE: 80 08        BRA $B6E8
C2/B6E0: A9 01 EB     LDA #$EB01
C2/B6E3: A5 73        LDA $73
C2/B6E5: 20 CE E2     JSR $E2CE
C2/B6E8: 20 8F E1     JSR $E18F
C2/B6EB: 20 A0 B7     JSR $B7A0
C2/B6EE: 64 6F        STZ $6F
C2/B6F0: 4C F0 A4     JMP $A4F0
C2/B6F3: A5 55        LDA $55
C2/B6F5: 85 6F        STA $6F
C2/B6F7: 64 70        STZ $70
C2/B6F9: A5 6F        LDA $6F
C2/B6FB: C9 03 10     CMP #$1003
C2/B6FE: 05 20        ORA $20
C2/B700: 87 ED        STA [$ED]
C2/B702: 80 03        BRA $B707
C2/B704: 20 5E ED     JSR $ED5E
C2/B707: A6 75        LDX $75
C2/B709: F0 3A        BEQ $B745
C2/B70B: 20 6F E6     JSR $E66F
C2/B70E: 20 94 EE     JSR $EE94
C2/B711: C2 20        REP #$20
C2/B713: A5 75        LDA $75
C2/B715: 38           SEC 
C2/B716: E9 09 00     SBC #$0009
C2/B719: 10 03        BPL $B71E
C2/B71B: A9 00 00     LDA #$0000
C2/B71E: 85 6D        STA $6D
C2/B720: 64 6B        STZ $6B
C2/B722: 20 A5 CA     JSR $CAA5
C2/B725: A5 6F        LDA $6F
C2/B727: 29 FF 00     AND #$00FF
C2/B72A: 3A           DEC 
C2/B72B: 20 C0 C0     JSR $C0C0
C2/B72E: AD 04 02     LDA $0204
C2/B731: 8D 08 02     STA $0208
C2/B734: AD 06 02     LDA $0206
C2/B737: 8D 0A 02     STA $020A
C2/B73A: 20 E2 C0     JSR $C0E2
C2/B73D: 20 9D A6     JSR $A69D
C2/B740: A9 0A        LDA #$0A
C2/B742: 4C 7C A4     JMP $A47C
C2/B745: 20 C0 E0     JSR $E0C0
C2/B748: 4C F0 A4     JMP $A4F0
C2/B74B: 64 6F        STZ $6F
C2/B74D: A9 05        LDA #$05
C2/B74F: 4C 7C A4     JMP $A47C
C2/B752: A5 55        LDA $55
C2/B754: 85 74        STA $74
C2/B756: C9 04        CMP #$04
C2/B758: F0 12        BEQ $B76C
C2/B75A: C9 03        CMP #$03
C2/B75C: F0 0E        BEQ $B76A
C2/B75E: C9 02        CMP #$02
C2/B760: F0 0F        BEQ $B771
C2/B762: C9 01        CMP #$01
C2/B764: F0 16        BEQ $B77C
C2/B766: C9 05        CMP #$05
C2/B768: F0 2C        BEQ $B796
C2/B76A: 80 25        BRA $B791
C2/B76C: A9 00        LDA #$00
C2/B76E: 4C 7C A4     JMP $A47C
C2/B770: 20 A4 DA     JSR $DAA4
C2/B774: 20 6F E6     JSR $E66F
C2/B777: 20 A0 B7     JSR $B7A0
C2/B77A: 80 15        BRA $B791
C2/B77C: 20 A4 DA     JSR $DAA4
C2/B77F: 20 6F E6     JSR $E66F
C2/B782: 20 AD FA     JSR $FAAD
C2/B785: 20 6F E6     JSR $E66F
C2/B788: 20 69 F8     JSR $F869
C2/B78B: 20 6F E6     JSR $E66F
C2/B78E: 20 A0 B7     JSR $B7A0
C2/B791: A9 05        LDA #$05
C2/B793: 4C 7C A4     JMP $A47C
C2/B796: 20 BD B2     JSR $B2BD
C2/B799: 64 74        STZ $74
C2/B79B: A9 01        LDA #$01
C2/B79D: 4C 6B A0     JMP $A06B
C2/B7A0: 20 6C E7     JSR $E76C
C2/B7A3: 20 C8 CA     JSR $CAC8
C2/B7A6: 20 9E CC     JSR $CC9E
C2/B7A9: 20 98 A6     JSR $A698
C2/B7AC: 60           RTS 
C2/B7AD: 20 F7 E0     JSR $E0F7
C2/B7B0: A5 90        LDA $90
C2/B7B2: D0 42        BNE $B7F6
C2/B7B4: 20 86 E2     JSR $E286
C2/B7B7: A5 90        LDA $90
C2/B7B9: D0 3B        BNE $B7F6
C2/B7BB: 20 78 E1     JSR $E178
C2/B7BE: 20 11 E2     JSR $E211
C2/B7C1: A9 01        LDA #$01
C2/B7C3: EB           XBA 
C2/B7C4: A5 73        LDA $73
C2/B7C6: 20 CE E2     JSR $E2CE
C2/B7C9: 20 A6 E1     JSR $E1A6
C2/B7CC: A9 01 EB     LDA #$EB01
C2/B7CF: A5 72        LDA $72
C2/B7D1: 20 28 E3     JSR $E328
C2/B7D4: 20 8F E1     JSR $E18F
C2/B7D7: C2 20        REP #$20
C2/B7D9: A9 05 B0     LDA #$B005
C2/B7DC: 20 B8 C1     JSR $C1B8
C2/B7DF: 20 A0 B7     JSR $B7A0
C2/B7E2: 9C 11 2D     STZ $2D11
C2/B7E5: 9C 12 2D     STZ $2D12
C2/B7E8: 64 70        STZ $70
C2/B7EA: 64 73        STZ $73
C2/B7EC: 64 72        STZ $72
C2/B7EE: A5 6F        LDA $6F
C2/B7F0: 3A           DEC 
C2/B7F1: 29 07 4C     AND #$4C07
C2/B7F4: 7C A4 20     JMP ($20A4,X)
C2/B7F7: C0 E0 4C     CPY #$4CE0
C2/B7FA: F0 A4        BEQ $B7A0
C2/B7FC: C2 20        REP #$20
C2/B7FE: A9 05 B0     LDA #$B005
C2/B801: 20 B8 C1     JSR $C1B8
C2/B804: 20 98 A6     JSR $A698
C2/B807: 64 70        STZ $70
C2/B809: A5 6F        LDA $6F
C2/B80B: 3A           DEC 
C2/B80C: 29 07 4C     AND #$4C07
C2/B80F: 7C A4 A5     JMP ($A5A4,X)
C2/B812: 71 1A        ADC ($1A),Y
C2/B814: 29 03 85     AND #$8503
C2/B817: 71 85        ADC ($85),Y
C2/B819: 7E 64 7F     ROR $7F64,X
C2/B81C: 20 C5 D4     JSR $D4C5
C2/B81F: A6 80        LDX $80
C2/B821: BD 00 05     LDA $0500,X
C2/B824: 29 40 D0     AND #$D040
C2/B827: E9 C2 20     SBC #$20C2
C2/B82A: A9 95 B0     LDA #$B095
C2/B82D: 20 B8 C1     JSR $C1B8
C2/B830: A9 D3 B0     LDA #$B0D3
C2/B833: 20 B8 C1     JSR $C1B8
C2/B836: 20 A0 C8     JSR $C8A0
C2/B839: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/B83C: 20 98 A6     JSR $A698
C2/B83F: 20 9D A6     JSR $A69D
C2/B842: 4C F0 A4     JMP $A4F0
C2/B845: 20 BD B2     JSR $B2BD
C2/B848: A9 01 4C     LDA #$4C01
C2/B84B: 6B           RTL 
C2/B84C: A0 A5 55     LDY #$55A5
C2/B84F: C9 01 F0     CMP #$F001
C2/B852: 0B           PHD 
C2/B853: C9 02 F0     CMP #$F002
C2/B856: 18           CLC 
C2/B857: C9 03 F0     CMP #$F003
C2/B85A: 1E 4C F0     ASL $F04C,X
C2/B85D: A4 9C        LDY $9C
C2/B85F: 04 28        TSB $28
C2/B861: AD 02 28     LDA $2802
C2/B864: 30 04        BMI $B86A
C2/B866: A9 03 80     LDA #$8003
C2/B869: 02 A9        COP $A9
C2/B86B: 10 4C        BPL $B8B9
C2/B86D: 7C A4 A9     JMP ($A9A4,X)
C2/B870: 80 8D        BRA $B7FF
C2/B872: 04 28        TSB $28
C2/B874: A9 18 4C     LDA #$4C18
C2/B877: 7C A4 4C     JMP ($4CA4,X)
C2/B87A: 2D A0 A5     AND $A5A0
C2/B87D: 55 3A        EOR $3A,X
C2/B87F: 8D 07 28     STA $2807
C2/B882: 9C 08 28     STZ $2808
C2/B885: AE 07 28     LDX $2807
C2/B888: BD 26 28     LDA $2826,X
C2/B88B: 8D 09 28     STA $2809
C2/B88E: BD 7E 28     LDA $287E,X
C2/B891: 8D 10 28     STA $2810
C2/B894: C2 20        REP #$20
C2/B896: 8A           TXA 
C2/B897: 0A           ASL 
C2/B898: AA           TAX 
C2/B899: 0A           ASL 
C2/B89A: A8           TAY 
C2/B89B: BD 4E 28     LDA $284E,X
C2/B89E: 8D 0A 28     STA $280A
C2/B8A1: B9 2E 28     LDA $282E,Y
C2/B8A4: 8D 0C 28     STA $280C
C2/B8A7: B9 30 28     LDA $2830,Y
C2/B8AA: 8D 0E 28     STA $280E
C2/B8AD: 60           RTS 
C2/B8AE: 20 7C B8     JSR $B87C
C2/B8B1: 20 70 F0     JSR $F070
C2/B8B4: E2 20        SEP #$20
C2/B8B6: AD 13 28     LDA $2813
C2/B8B9: F0 15        BEQ $B8D0
C2/B8BB: A2 15 28     LDX #$2815
C2/B8BE: A0 19 28     LDY #$2819
C2/B8C1: 20 C8 EE     JSR $EEC8
C2/B8C4: 90 16        BCC $B8DC
C2/B8C6: 2C 05 28     BIT $2805
C2/B8C9: 30 32        BMI $B8FD
C2/B8CB: A9 0B        LDA #$0B
C2/B8CD: 4C 7C A4     JMP $A47C
C2/B8D0: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B8D3: A9 03        LDA #$03
C2/B8D5: 20 E7 EE     JSR $EEE7
C2/B8D8: A9 01        LDA #$01
C2/B8DA: 80 16        BRA $B8F2
C2/B8DC: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B8DF: A9 02        LDA #$02
C2/B8E1: 20 E7 EE     JSR $EEE7
C2/B8E4: AD 01 28     LDA $2801
C2/B8E7: C9 03        CMP #$03
C2/B8E9: D0 05        BNE $B8F0
C2/B8EB: 20 58 E6     JSR $E658
C2/B8EE: 80 05        BRA $B8F5
C2/B8F0: A9 00        LDA #$00
C2/B8F2: 20 FD EE     JSR $EEFD
C2/B8F5: A9 00        LDA #$00
C2/B8F7: 20 E7 EE     JSR $EEE7
C2/B8FA: 4C F0 A4     JMP $A4F0
C2/B8FD: A9 01        LDA #$01
C2/B8FF: 85 39        STA $39
C2/B901: 20 22 B9     JSR $B922
C2/B904: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B907: C2 20        REP #$20
C2/B909: A9 49 B3     LDA #$B349
C2/B90C: 20 B8 C1     JSR $C1B8
C2/B90F: 20 98 A6     JSR $A698
C2/B912: A9 00 20     LDA #$2000
C2/B915: FD EE 20     SBC $20EE,X
C2/B918: 58           CLI 
C2/B919: E6 4C        INC $4C
C2/B91B: 2D A0 A9     AND $A9A0
C2/B91E: 00 4C        BRK $4C
C2/B920: 7C A4 AD     JMP ($ADA4,X)
C2/B923: 1D 28 8D     ORA $8D28,X
C2/B926: 15 28        ORA $28,X
C2/B928: 8D 47 09     STA $0947
C2/B92B: AD 1E 28     LDA $281E
C2/B92E: 8D 16 28     STA $2816
C2/B931: 8D 48 09     STA $0948
C2/B934: AD 1F 28     LDA $281F
C2/B937: 8D 17 28     STA $2817
C2/B93A: 8D 49 09     STA $0949
C2/B93D: AD 14 28     LDA $2814
C2/B940: EB           XBA 
C2/B941: AD 09 28     LDA $2809
C2/B944: 20 CE E2     JSR $E2CE
C2/B947: 60           RTS 
C2/B948: A9 01 00     LDA #$0001
C2/B94B: 20 E7 EE     JSR $EEE7
C2/B94E: A9 38 00     LDA #$0038
C2/B951: 20 D9 E0     JSR $E0D9       ; play sound effect
C2/B954: 60           RTS 
C2/B955: A2 15 28     LDX #$2815
C2/B958: A0 19 28     LDY #$2819
C2/B95B: 20 C8 EE     JSR $EEC8
C2/B95E: 90 1E        BCC $B97E
C2/B960: 20 22 B9     JSR $B922
C2/B963: C2 20        REP #$20
C2/B965: A2 E8 51     LDX #$51E8
C2/B968: A0 15 28     LDY #$2815
C2/B96B: A9 73 7E     LDA #$7E73
C2/B96E: 20 ED E4     JSR $E4ED
C2/B971: 20 48 B9     JSR $B948
C2/B974: 20 58 E6     JSR $E658
C2/B977: E2 20        SEP #$20
C2/B979: A9 03        LDA #$03
C2/B97B: 4C 7C A4     JMP $A47C
C2/B97E: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B981: A9 02        LDA #$02
C2/B983: 20 E7 EE     JSR $EEE7
C2/B986: A9 00        LDA #$00
C2/B988: 20 FD EE     JSR $EEFD
C2/B98B: A9 00        LDA #$00
C2/B98D: 20 E7 EE     JSR $EEE7
C2/B990: 4C F0 A4     JMP $A4F0
C2/B993: A9 03        LDA #$03
C2/B995: 4C 7C A4     JMP $A47C
C2/B998: 20 7C B8     JSR $B87C
C2/B99B: 20 3E F0     JSR $F03E
C2/B99E: E2 20        SEP #$20
C2/B9A0: AD 11 28     LDA $2811
C2/B9A3: D0 3C        BNE $B9E1
C2/B9A5: A2 15 28     LDX #$2815
C2/B9A8: A0 19 28     LDY #$2819
C2/B9AB: 20 C8 EE     JSR $EEC8
C2/B9AE: 90 3E        BCC $B9EE
C2/B9B0: AD 1D 28     LDA $281D
C2/B9B3: 8D 15 28     STA $2815
C2/B9B6: 8D 47 09     STA $0947
C2/B9B9: AD 1E 28     LDA $281E
C2/B9BC: 8D 16 28     STA $2816
C2/B9BF: 8D 48 09     STA $0948
C2/B9C2: AD 1F 28     LDA $281F
C2/B9C5: 8D 17 28     STA $2817
C2/B9C8: 8D 49 09     STA $0949
C2/B9CB: 20 E3 EF     JSR $EFE3
C2/B9CE: C2 20        REP #$20
C2/B9D0: A2 E8 51     LDX #$51E8
C2/B9D3: A0 15 28     LDY #$2815
C2/B9D6: A9 73 7E     LDA #$7E73
C2/B9D9: 20 ED E4     JSR $E4ED
C2/B9DC: 20 48 B9     JSR $B948
C2/B9DF: 80 18        BRA $B9F9
C2/B9E1: C2 20        REP #$20
C2/B9E3: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B9E6: A9 06 00     LDA #$0006
C2/B9E9: 20 E7 EE     JSR $EEE7
C2/B9EC: 80 0B        BRA $B9F9
C2/B9EE: C2 20        REP #$20
C2/B9F0: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/B9F3: A9 02 00     LDA #$0002
C2/B9F6: 20 E7 EE     JSR $EEE7
C2/B9F9: 20 58 E6     JSR $E658
C2/B9FC: A9 00 00     LDA #$0000
C2/B9FF: 20 E7 EE     JSR $EEE7
C2/BA02: 4C F0 A4     JMP $A4F0
C2/BA05: A9 00 4C     LDA #$4C00
C2/BA08: 7C A4 64     JMP ($64A4,X)
C2/BA0B: 6F 64 70 A9  ADC $A97064
C2/BA0F: 00 8D        BRK $8D
C2/BA11: 89 28 A5     BIT #$A528
C2/BA14: 55 C9        EOR $C9,X
C2/BA16: 01 F0        ORA ($F0,X)
C2/BA18: 0B           PHD 
C2/BA19: C9 03 F0     CMP #$F003
C2/BA1C: 1A           INC 
C2/BA1D: C9 04 F0     CMP #$F004
C2/BA20: 23 4C        AND $4C,S
C2/BA22: F0 A4        BEQ $B9C8
C2/BA24: AD 73 09     LDA $0973
C2/BA27: 29 04 D0     AND #$D004
C2/BA2A: 04 A9        TSB $A9
C2/BA2C: 04 80        TSB $80
C2/BA2E: 05 A5        ORA $A5
C2/BA30: 5B           TCD 
C2/BA31: 18           CLC 
C2/BA32: 69 04 4C     ADC #$4C04
C2/BA35: 7C A4 C2     JMP ($C2A4,X)
C2/BA38: 20 20 02     JSR $0220
C2/BA3B: E0 20 0E     CPX #$0E20
C2/BA3E: AC A9 00     LDY $00A9
C2/BA41: 4C 7C A4     JMP $A47C
C2/BA44: C2 20        REP #$20
C2/BA46: A9 B4 B3     LDA #$B3B4
C2/BA49: 20 B8 C1     JSR $C1B8
C2/BA4C: A9 60 B3     LDA #$B360
C2/BA4F: 20 B8 C1     JSR $C1B8
C2/BA52: 20 3D C7     JSR $C73D
C2/BA55: 20 9D A6     JSR $A69D
C2/BA58: 20 98 A6     JSR $A698
C2/BA5B: A9 01 8D     LDA #$8D01
C2/BA5E: 15 2D        ORA $2D,X
C2/BA60: 4C F0 A4     JMP $A4F0
C2/BA63: AD 15 2D     LDA $2D15
C2/BA66: F0 0D        BEQ $BA75
C2/BA68: 9C 15 2D     STZ $2D15
C2/BA6B: C2 20        REP #$20
C2/BA6D: 20 0E AC     JSR $AC0E
C2/BA70: A9 00 4C     LDA #$4C00
C2/BA73: 7C A4 20     JMP ($20A4,X)
C2/BA76: BD B2 A9     LDA $A9B2,X
C2/BA79: 01 4C        ORA ($4C,X)
C2/BA7B: 6B           RTL 
C2/BA7C: A0 AD 89     LDY #$89AD
C2/BA7F: 28           PLP 
C2/BA80: D0 1F        BNE $BAA1
C2/BA82: C2 20        REP #$20
C2/BA84: A5 55        LDA $55
C2/BA86: 29 FF 00     AND #$00FF
C2/BA89: 3A           DEC 
C2/BA8A: 18           CLC 
C2/BA8B: 65 6B        ADC $6B
C2/BA8D: E2 20        SEP #$20
C2/BA8F: 85 6F        STA $6F
C2/BA91: A5 53        LDA $53
C2/BA93: 20 C9 C0     JSR $C0C9
C2/BA96: A9 01        LDA #$01
C2/BA98: 8D 10 75     STA $7510
C2/BA9B: 8D 89 28     STA $2889
C2/BA9E: 4C F0 A4     JMP $A4F0
C2/BAA1: C2 20        REP #$20
C2/BAA3: A5 55        LDA $55
C2/BAA5: 29 FF 00     AND #$00FF
C2/BAA8: 3A           DEC 
C2/BAA9: 18           CLC 
C2/BAAA: 65 6B        ADC $6B
C2/BAAC: E2 20        SEP #$20
C2/BAAE: 85 70        STA $70
C2/BAB0: C5 6F        CMP $6F
C2/BAB2: F0 44        BEQ $BAF8
C2/BAB4: C2 20        REP #$20
C2/BAB6: A5 6F        LDA $6F
C2/BAB8: 29 FF 00     AND #$00FF
C2/BABB: AA           TAX 
C2/BABC: A5 70        LDA $70
C2/BABE: 29 FF 00     AND #$00FF
C2/BAC1: A8           TAY 
C2/BAC2: E2 20        SEP #$20
C2/BAC4: BD 40 06     LDA $0640,X
C2/BAC7: EB           XBA 
C2/BAC8: B9 40 06     LDA $0640,Y
C2/BACB: 9D 40 06     STA $0640,X
C2/BACE: EB           XBA 
C2/BACF: 99 40 06     STA $0640,Y
C2/BAD2: BD 40 07     LDA $0740,X
C2/BAD5: EB           XBA 
C2/BAD6: B9 40 07     LDA $0740,Y
C2/BAD9: 9D 40 07     STA $0740,X
C2/BADC: EB           XBA 
C2/BADD: 99 40 07     STA $0740,Y
C2/BAE0: 9C 10 75     STZ $7510
C2/BAE3: 20 E2 C0     JSR $C0E2
C2/BAE6: 20 BD C7     JSR $C7BD
C2/BAE9: 20 9D A6     JSR $A69D
C2/BAEC: 64 6F        STZ $6F
C2/BAEE: 64 70        STZ $70
C2/BAF0: 9C 89 28     STZ $2889
C2/BAF3: A5 53        LDA $53
C2/BAF5: 4C 7C A4     JMP $A47C
C2/BAF8: C2 20        REP #$20
C2/BAFA: A5 70        LDA $70
C2/BAFC: 29 FF 00     AND #$00FF
C2/BAFF: AA           TAX 
C2/BB00: E2 20        SEP #$20
C2/BB02: BD 00 7A     LDA $7A00,X
C2/BB05: 8D E7 29     STA $29E7
C2/BB08: DA           PHX 
C2/BB09: 20 DA DA     JSR $DADA
C2/BB0C: FA           PLX 
C2/BB0D: AD E7 29     LDA $29E7
C2/BB10: D0 03        BNE $BB15
C2/BB12: 4C AC BB     JMP $BBAC
C2/BB15: A9 40        LDA #$40
C2/BB17: 8D E6 29     STA $29E6
C2/BB1A: BD 00 7B     LDA $7B00,X
C2/BB1D: 30 F3        BMI $BB12
C2/BB1F: F0 F1        BEQ $BB12
C2/BB21: C9 64        CMP #$64
C2/BB23: 10 ED        BPL $BB12
C2/BB25: 8D E8 29     STA $29E8
C2/BB28: 9C E9 29     STZ $29E9
C2/BB2B: AD E7 29     LDA $29E7
C2/BB2E: C9 F0        CMP #$F0
C2/BB30: F0 5E        BEQ $BB90
C2/BB32: C9 F1        CMP #$F1
C2/BB34: F0 5A        BEQ $BB90
C2/BB36: C2 20        REP #$20
C2/BB38: 29 FF 00     AND #$00FF
C2/BB3B: C9 F8 00     CMP #$00F8
C2/BB3E: 30 07        BMI $BB47
C2/BB40: C9 FC 00     CMP #$00FC
C2/BB43: 10 02        BPL $BB47
C2/BB45: 80 1F        BRA $BB66
C2/BB47: 0A           ASL 
C2/BB48: AA           TAX 
C2/BB49: BD 00 D0     LDA $D000,X
C2/BB4C: AA           TAX 
C2/BB4D: A0 F3 29     LDY #$29F3
C2/BB50: A9 07 00     LDA #$0007
C2/BB53: 54 7E D1     MVN $7E,$D1
C2/BB56: E2 20        SEP #$20
C2/BB58: A5 55        LDA $55
C2/BB5A: 3A           DEC 
C2/BB5B: 85 5B        STA $5B
C2/BB5D: A5 6B        LDA $6B
C2/BB5F: 85 5C        STA $5C
C2/BB61: A9 1C        LDA #$1C
C2/BB63: 4C 7C A4     JMP $A47C

C2/BB66: 29 FF 00     AND #$00FF
C2/BB69: 38           SEC 
C2/BB6A: E9 F8 00     SBC #$00F8      ; subtract 248 from item index
C2/BB6D: AA           TAX 
C2/BB6E: BF AE EE C0  LDA $C0EEAE,X   ; spells learned from items (ifrit, ramuh, shoat, golem)
C2/BB72: 20 0B F0     JSR $F00B       ; give spell
C2/BB75: BF B2 EE C0  LDA $C0EEB2,X   ; sound effect to play
C2/BB79: 20 D9 E0     JSR $E0D9       ; play sound effect
C2/BB7C: AD E7 29     LDA $29E7
C2/BB7F: 29 FF 00     AND #$00FF
C2/BB82: 09 00 01     ORA #$0100
C2/BB85: 20 28 E3     JSR $E328
C2/BB88: 20 BD C7     JSR $C7BD
C2/BB8B: 20 9D A6     JSR $A69D
C2/BB8E: 80 5B        BRA $BBEB
C2/BB90: 85 39        STA $39
C2/BB92: 64 3A        STZ $3A
C2/BB94: 24 44        BIT $44
C2/BB96: 10 0E        BPL $BBA6
C2/BB98: C2 20        REP #$20
C2/BB9A: 29 FF 00     AND #$00FF
C2/BB9D: 09 00 01     ORA #$0100
C2/BBA0: 20 28 E3     JSR $E328
C2/BBA3: 4C 2D A0     JMP $A02D       ; exit menu
C2/BBA6: 64 39        STZ $39
C2/BBA8: 64 3A        STZ $3A
C2/BBAA: 80 3F        BRA $BBEB
C2/BBAC: BD 00 7A     LDA $7A00,X
C2/BBAF: C2 20        REP #$20
C2/BBB1: 29 FF 00     AND #$00FF
C2/BBB4: F0 35        BEQ $BBEB
C2/BBB6: C9 E0 00     CMP #$00E0
C2/BBB9: 10 30        BPL $BBEB
C2/BBBB: 8D 1B 2D     STA $2D1B
C2/BBBE: 20 AB D9     JSR $D9AB
C2/BBC1: A5 9D        LDA $9D
C2/BBC3: 29 3F 00     AND #$003F
C2/BBC6: 0A           ASL 
C2/BBC7: 0A           ASL 
C2/BBC8: AA           TAX 
C2/BBC9: BF 80 24 D1  LDA $D12480,X   ; item equipment types
C2/BBCD: 8D 1D 2D     STA $2D1D
C2/BBD0: BF 82 24 D1  LDA $D12482,X
C2/BBD4: 8D 1F 2D     STA $2D1F
C2/BBD7: 64 6F        STZ $6F
C2/BBD9: 20 E2 C0     JSR $C0E2
C2/BBDC: E2 20        SEP #$20
C2/BBDE: 9C 89 28     STZ $2889
C2/BBE1: A5 55        LDA $55
C2/BBE3: 3A           DEC 
C2/BBE4: 85 5B        STA $5B
C2/BBE6: A9 22        LDA #$22
C2/BBE8: 4C 7C A4     JMP $A47C
C2/BBEB: E2 20        SEP #$20
C2/BBED: 64 6F        STZ $6F
C2/BBEF: 64 70        STZ $70
C2/BBF1: 9C 89 28     STZ $2889
C2/BBF4: 20 E2 C0     JSR $C0E2
C2/BBF7: 4C F0 A4     JMP $A4F0
C2/BBFA: AD 89 28     LDA $2889
C2/BBFD: D0 15        BNE $BC14
C2/BBFF: 64 6F        STZ $6F
C2/BC01: 64 70        STZ $70
C2/BC03: 9C 89 28     STZ $2889
C2/BC06: A5 55        LDA $55
C2/BC08: 3A           DEC 
C2/BC09: 85 5B        STA $5B
C2/BC0B: A5 6B        LDA $6B
C2/BC0D: 85 5C        STA $5C
C2/BC0F: A9 00        LDA #$00
C2/BC11: 4C 7C A4     JMP $A47C
C2/BC14: 64 6F        STZ $6F
C2/BC16: 64 70        STZ $70
C2/BC18: 9C 89 28     STZ $2889
C2/BC1B: 9C 10 75     STZ $7510
C2/BC1E: 20 E2 C0     JSR $C0E2
C2/BC21: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/BC24: 4C F0 A4     JMP $A4F0
C2/BC27: 4C F0 A4     JMP $A4F0
C2/BC2A: 4C F0 A4     JMP $A4F0
C2/BC2D: A6 7E        LDX $7E
C2/BC2F: A5 53        LDA $53
C2/BC31: 95 63        STA $63,X
C2/BC33: A5 55        LDA $55
C2/BC35: 3A           DEC 
C2/BC36: 8D E2 29     STA $29E2
C2/BC39: C2 20        REP #$20
C2/BC3B: 29 07 00     AND #$0007
C2/BC3E: AA           TAX 
C2/BC3F: BF A4 F3 C0  LDA $C0F3A4,X
C2/BC43: E2 20        SEP #$20
C2/BC45: 4C 7C A4     JMP $A47C
C2/BC48: 20 BD B2     JSR $B2BD
C2/BC4B: A9 00        LDA #$00
C2/BC4D: EB           XBA 
C2/BC4E: A5 71        LDA $71
C2/BC50: AA           TAX 
C2/BC51: A5 53        LDA $53
C2/BC53: 95 63        STA $63,X
C2/BC55: A5 71        LDA $71
C2/BC57: 85 5D        STA $5D
C2/BC59: A9 01        LDA #$01
C2/BC5B: 4C 6B A0     JMP $A06B       ; show menu
C2/BC5E: C2 20        REP #$20
C2/BC60: A5 55        LDA $55
C2/BC62: 29 FF 00     AND #$00FF
C2/BC65: 3A           DEC 
C2/BC66: AA           TAX 
C2/BC67: BD 00 7A     LDA $7A00,X
C2/BC6A: 29 FF 00     AND #$00FF
C2/BC6D: AA           TAX 
C2/BC6E: E2 20        SEP #$20
C2/BC70: 3C FB 29     BIT $29FB,X
C2/BC73: 50 34        BVC $BCA9
C2/BC75: 8D E7 29     STA $29E7
C2/BC78: BD FB 29     LDA $29FB,X
C2/BC7B: 8D E6 29     STA $29E6
C2/BC7E: BD 9D 2A     LDA $2A9D,X
C2/BC81: 8D E8 29     STA $29E8
C2/BC84: 9C E9 29     STZ $29E9
C2/BC87: AD E7 29     LDA $29E7
C2/BC8A: C9 3E        CMP #$3E
C2/BC8C: F0 23        BEQ $BCB1
C2/BC8E: C2 20        REP #$20
C2/BC90: 8A           TXA 
C2/BC91: 0A           ASL 
C2/BC92: 0A           ASL 
C2/BC93: 0A           ASL 
C2/BC94: 18           CLC 
C2/BC95: 69 80 0B     ADC #$0B80
C2/BC98: AA           TAX 
C2/BC99: A0 F3 29     LDY #$29F3
C2/BC9C: A9 07 00     LDA #$0007
C2/BC9F: 54 7E D1     MVN $7E,$D1
C2/BCA2: E2 20        SEP #$20
C2/BCA4: A9 1F        LDA #$1F
C2/BCA6: 4C 7C A4     JMP $A47C
C2/BCA9: 64 39        STZ $39
C2/BCAB: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/BCAE: 4C F0 A4     JMP $A4F0
C2/BCB1: 85 39        STA $39
C2/BCB3: A5 44        LDA $44
C2/BCB5: 29 02        AND #$02
C2/BCB7: F0 F0        BEQ $BCA9
C2/BCB9: 64 3A        STZ $3A
C2/BCBB: C2 20        REP #$20
C2/BCBD: A5 71        LDA $71
C2/BCBF: 29 0F 00     AND #$000F
C2/BCC2: 85 7E        STA $7E
C2/BCC4: 20 C5 D4     JSR $D4C5
C2/BCC7: A4 80        LDY $80
C2/BCC9: B9 0A 05     LDA $050A,Y
C2/BCCC: 38           SEC 
C2/BCCD: ED E8 29     SBC $29E8
C2/BCD0: 99 0A 05     STA $050A,Y
C2/BCD3: 8D DF 29     STA $29DF
C2/BCD6: 4C 2D A0     JMP $A02D       ; exit menu
C2/BCD9: A6 7E        LDX $7E
C2/BCDB: B5 63        LDA $63,X
C2/BCDD: 4C 7C A4     JMP $A47C

; [  ]

C2/BCE0: C2 20        REP #$20
C2/BCE2: A5 55        LDA $55
C2/BCE4: 29 FF 00     AND #$00FF
C2/BCE7: 3A           DEC 
C2/BCE8: 18           CLC 
C2/BCE9: 65 6B        ADC $6B
C2/BCEB: AA           TAX 
C2/BCEC: E2 20        SEP #$20
C2/BCEE: BD 00 7A     LDA $7A00,X     ; item index
C2/BCF1: F0 44        BEQ $BD37       ; branch if no item
C2/BCF3: 8D 09 28     STA $2809
C2/BCF6: BD 8A 28     LDA $288A,X
C2/BCF9: 8D 10 28     STA $2810
C2/BCFC: A5 53        LDA $53
C2/BCFE: 8D 06 28     STA $2806
C2/BD01: 9C 25 28     STZ $2825
C2/BD04: 20 9F F2     JSR $F29F       ; get item price
C2/BD07: 2C 0A 28     BIT $280A
C2/BD0A: 30 2B        BMI $BD37       ; branch if item can't be sold
C2/BD0C: 50 0E        BVC $BD1C       ; branch if item doesn't sell for 5gp
C2/BD0E: A9 0A        LDA #$0A
C2/BD10: 8D 0C 28     STA $280C       ; price is 10gp
C2/BD13: 9C 0D 28     STZ $280D
C2/BD16: 9C 0E 28     STZ $280E
C2/BD19: 9C 0F 28     STZ $280F
C2/BD1C: C2 20        REP #$20
C2/BD1E: 4E 0E 28     LSR $280E       ; divide price by 2
C2/BD21: 6E 0C 28     ROR $280C
C2/BD24: 20 70 F0     JSR $F070
C2/BD27: E2 20        SEP #$20
C2/BD29: AD 11 28     LDA $2811
C2/BD2C: 8D 13 28     STA $2813
C2/BD2F: 9C 86 28     STZ $2886
C2/BD32: A9 32        LDA #$32
C2/BD34: 4C 7C A4     JMP $A47C
C2/BD37: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/BD3A: 4C F0 A4     JMP $A4F0

; [  ]

C2/BD3D: A5 53        LDA $53
C2/BD3F: 8D 06 28     STA $2806
C2/BD42: A9 00        LDA #$00
C2/BD44: 4C 7C A4     JMP $A47C
C2/BD47: A5 55        LDA $55
C2/BD49: C9 05        CMP #$05
C2/BD4B: 10 25        BPL $BD72
C2/BD4D: 3A           DEC 
C2/BD4E: 85 6F        STA $6F
C2/BD50: A5 53        LDA $53
C2/BD52: 85 62        STA $62
C2/BD54: 20 A5 BD     JSR $BDA5
C2/BD57: F0 0B        BEQ $BD64
C2/BD59: 20 F7 BE     JSR $BEF7       ; save sram
C2/BD5C: 20 BD B2     JSR $B2BD
C2/BD5F: A9 0B        LDA #$0B
C2/BD61: 4C 6B A0     JMP $A06B       ; show menu
C2/BD64: E2 20        SEP #$20
C2/BD66: A5 53        LDA $53
C2/BD68: 85 62        STA $62
C2/BD6A: 9C 13 2D     STZ $2D13
C2/BD6D: A9 04        LDA #$04
C2/BD6F: 4C 7C A4     JMP $A47C
C2/BD72: C9 09        CMP #$09
C2/BD74: F0 1A        BEQ $BD90
C2/BD76: 3A           DEC 
C2/BD77: 29 03        AND #$03
C2/BD79: 85 6F        STA $6F
C2/BD7B: 20 A5 BD     JSR $BDA5
C2/BD7E: D0 1F        BNE $BD9F
C2/BD80: E2 20        SEP #$20
C2/BD82: A5 53        LDA $53
C2/BD84: 85 62        STA $62
C2/BD86: A9 01        LDA #$01
C2/BD88: 8D 13 2D     STA $2D13
C2/BD8B: A9 05        LDA #$05
C2/BD8D: 4C 7C A4     JMP $A47C
C2/BD90: 64 62        STZ $62
C2/BD92: C2 20        REP #$20
C2/BD94: 64 39        STZ $39
C2/BD96: 20 F0 A1     JSR $A1F0       ; init config settings
C2/BD99: 20 7D FF     JSR $FF7D       ; update joypad config
C2/BD9C: 4C 2D A0     JMP $A02D       ; exit menu
C2/BD9F: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/BDA2: 4C F0 A4     JMP $A4F0
C2/BDA5: C2 20        REP #$20
C2/BDA7: 29 03 00     AND #$0003
C2/BDAA: 0A           ASL 
C2/BDAB: 0A           ASL 
C2/BDAC: 0A           ASL 
C2/BDAD: 0A           ASL 
C2/BDAE: 0A           ASL 
C2/BDAF: AA           TAX 
C2/BDB0: BF 14 2C 7E  LDA $7E2C14,X
C2/BDB4: 60           RTS 
C2/BDB5: A5 43        LDA $43         ; menu state
C2/BDB7: C9 0C D0     CMP #$D00C
C2/BDBA: 03 4C        ORA $4C,S
C2/BDBC: F0 A4        BEQ $BD62
C2/BDBE: 20 BD B2     JSR $B2BD
C2/BDC1: A9 01 4C     LDA #$4C01
C2/BDC4: 6B           RTL 
C2/BDC5: A0 A5 55     LDY #$55A5
C2/BDC8: C9 03 F0     CMP #$F003
C2/BDCB: 0F 3A 8D 65  ORA $658D3A
C2/BDCF: 2B           PLD 
C2/BDD0: 20 DA C4     JSR $C4DA
C2/BDD3: 20 9D A6     JSR $A69D
C2/BDD6: A9 03 4C     LDA #$4C03
C2/BDD9: 7C A4 A6     JMP ($A6A4,X)
C2/BDDC: 8E BD 90     STX $90BD
C2/BDDF: 09 C9 FF     ORA #$FFC9
C2/BDE2: D0 0C        BNE $BDF0
C2/BDE4: E8           INX 
C2/BDE5: E0 06 00     CPX #$0006
C2/BDE8: D0 F3        BNE $BDDD
C2/BDEA: 20 C0 E0     JSR $E0C0       ; play sound effect (error)
C2/BDED: 4C F0 A4     JMP $A4F0
C2/BDF0: 4C 2D A0     JMP $A02D       ; exit menu
C2/BDF3: 4C F0 A4     JMP $A4F0
C2/BDF6: C2 20        REP #$20
C2/BDF8: A5 55        LDA $55
C2/BDFA: 29 FF 00     AND #$00FF
C2/BDFD: 3A           DEC 
C2/BDFE: AA           TAX 
C2/BDFF: E2 20        SEP #$20
C2/BE01: 20 1D C5     JSR $C51D
C2/BE04: C9 FF        CMP #$FF
C2/BE06: F0 23        BEQ $BE2B
C2/BE08: AC 92 2B     LDY $2B92
C2/BE0B: 99 90 09     STA $0990,Y
C2/BE0E: C0 05 00     CPY #$0005
C2/BE11: 10 01        BPL $BE14
C2/BE13: C8           INY 
C2/BE14: 8C 92 2B     STY $2B92
C2/BE17: 20 51 C5     JSR $C551
C2/BE1A: C2 20        REP #$20
C2/BE1C: A2 C4 51     LDX #$51C4
C2/BE1F: A0 90 09     LDY #$0990      ; butz's name
C2/BE22: A9 06 00     LDA #$0006
C2/BE25: 20 9D E5     JSR $E59D
C2/BE28: 20 98 A6     JSR $A698
C2/BE2B: 4C F0 A4     JMP $A4F0

C2/BE2E: AE 92 2B     LDX $2B92
C2/BE31: BD 90 09     LDA $0990,X
C2/BE34: C9 FF F0     CMP #$F0FF
C2/BE37: 07 A9        ORA [$A9]
C2/BE39: FF 9D 90 09  SBC $09909D,X
C2/BE3D: 80 0B        BRA $BE4A
C2/BE3F: E0 00 00     CPX #$0000
C2/BE42: F0 06        BEQ $BE4A
C2/BE44: CA           DEX 
C2/BE45: A9 FF 9D     LDA #$9DFF
C2/BE48: 90 09        BCC $BE53
C2/BE4A: 8E 92 2B     STX $2B92
C2/BE4D: 20 51 C5     JSR $C551
C2/BE50: C2 20        REP #$20
C2/BE52: A2 C4 51     LDX #$51C4
C2/BE55: A0 90 09     LDY #$0990
C2/BE58: A9 06 00     LDA #$0006
C2/BE5B: 20 9D E5     JSR $E59D
C2/BE5E: 20 98 A6     JSR $A698
C2/BE61: 4C F0 A4     JMP $A4F0
C2/BE64: C2 20        REP #$20
C2/BE66: AD 15 28     LDA $2815
C2/BE69: 18           CLC 
C2/BE6A: 6D 19 28     ADC $2819
C2/BE6D: 8D 15 28     STA $2815
C2/BE70: AD 17 28     LDA $2817
C2/BE73: 6D 1B 28     ADC $281B
C2/BE76: 8D 17 28     STA $2817
C2/BE79: E2 20        SEP #$20
C2/BE7B: A2 21 28     LDX #$2821
C2/BE7E: A0 15 28     LDY #$2815
C2/BE81: 20 C8 EE     JSR $EEC8
C2/BE84: B0 0E        BCS $BE94
C2/BE86: C2 20        REP #$20
C2/BE88: AD 21 28     LDA $2821
C2/BE8B: 8D 15 28     STA $2815
C2/BE8E: AD 23 28     LDA $2823
C2/BE91: 8D 17 28     STA $2817
C2/BE94: E2 20        SEP #$20
C2/BE96: AD 14 28     LDA $2814
C2/BE99: EB           XBA 
C2/BE9A: AD 09 28     LDA $2809
C2/BE9D: 20 28 E3     JSR $E328
C2/BEA0: C2 20        REP #$20
C2/BEA2: A2 E8 51     LDX #$51E8
C2/BEA5: A0 15 28     LDY #$2815
C2/BEA8: A9 73 7E     LDA #$7E73
C2/BEAB: 20 ED E4     JSR $E4ED
C2/BEAE: AD 15 28     LDA $2815
C2/BEB1: 8D 47 09     STA $0947
C2/BEB4: AD 17 28     LDA $2817
C2/BEB7: 8D 49 09     STA $0949
C2/BEBA: 20 48 B9     JSR $B948
C2/BEBD: 20 58 E6     JSR $E658
C2/BEC0: A9 00 00     LDA #$0000
C2/BEC3: 20 E7 EE     JSR $EEE7
C2/BEC6: E2 20        SEP #$20
C2/BEC8: A9 18        LDA #$18
C2/BECA: 4C 7C A4     JMP $A47C
C2/BECD: A5 55        LDA $55
C2/BECF: C9 01        CMP #$01
C2/BED1: F0 07        BEQ $BEDA
C2/BED3: C9 02        CMP #$02
C2/BED5: F0 1A        BEQ $BEF1
C2/BED7: 4C F0 A4     JMP $A4F0
C2/BEDA: A4 8E        LDY $8E
C2/BEDC: B9 9A 2B     LDA $2B9A,Y
C2/BEDF: F0 0A        BEQ $BEEB
C2/BEE1: EB           XBA 
C2/BEE2: B9 A2 2B     LDA $2BA2,Y
C2/BEE5: F0 04        BEQ $BEEB
C2/BEE7: EB           XBA 
C2/BEE8: 20 CE E2     JSR $E2CE
C2/BEEB: C8           INY 
C2/BEEC: C0 08 00     CPY #$0008
C2/BEEF: D0 EB        BNE $BEDC
C2/BEF1: 4C 2D A0     JMP $A02D       ; exit menu
C2/BEF4: 4C F0 A4     JMP $A4F0

; [ save sram ]

C2/BEF7: 08           PHP 
C2/BEF8: C2 20        REP #$20
C2/BEFA: EE C2 09     INC $09C2
C2/BEFD: 20 7D BF     JSR $BF7D       ; get pointer to save slot in sram
C2/BF00: DA           PHX 
C2/BF01: A8           TAY 
C2/BF02: A2 00 05     LDX #$0500      ; copy $0600 bytes from 00/0500
C2/BF05: A9 FF 05     LDA #$05FF
C2/BF08: 8B           PHB 
C2/BF09: 5A           PHY 
C2/BF0A: 54 30 00     MVN $30,$00     ; save sram
C2/BF0D: 7A           PLY 
C2/BF0E: AB           PLB 
C2/BF0F: 84 FC        STY $FC
C2/BF11: 20 88 F5     JSR $F588
C2/BF14: FA           PLX 
C2/BF15: 9F F0 7F 30  STA $307FF0,X
C2/BF19: A9 1B E4     LDA #$E41B
C2/BF1C: 9F F8 7F 30  STA $307FF8,X
C2/BF20: A5 6F        LDA $6F
C2/BF22: 29 03 00     AND #$0003
C2/BF25: 8F E0 7F 30  STA $307FE0
C2/BF29: 20 C8 E0     JSR $E0C8
C2/BF2C: 28           PLP 
C2/BF2D: 60           RTS 

; [ load sram ]

C2/BF2E: A5 55        LDA $55
C2/BF30: C9 01        CMP #$01
C2/BF32: F0 03        BEQ $BF37
C2/BF34: 4C 89 BF     JMP $BF89       ; 
C2/BF37: AD 13 2D     LDA $2D13
C2/BF3A: D0 0B        BNE $BF47
C2/BF3C: 20 F7 BE     JSR $BEF7       ; save sram
C2/BF3F: 20 BD B2     JSR $B2BD
C2/BF42: A9 0B        LDA #$0B
C2/BF44: 4C 6B A0     JMP $A06B       ; show menu
C2/BF47: 20 F0 A1     JSR $A1F0       ; init config settings
C2/BF4A: AD 4A 09     LDA $094A
C2/BF4D: 48           PHA 
C2/BF4E: 08           PHP 
C2/BF4F: C2 20        REP #$20
C2/BF51: 20 7D BF     JSR $BF7D       ; get pointer to save slot in sram
C2/BF54: AA           TAX 
C2/BF55: A0 00 05     LDY #$0500
C2/BF58: A9 FF 05     LDA #$05FF
C2/BF5B: 8B           PHB 
C2/BF5C: 54 00 30     MVN $00,$30     ; load sram
C2/BF5F: AB           PLB 
C2/BF60: 28           PLP 
C2/BF61: 68           PLA 
C2/BF62: 18           CLC 
C2/BF63: 6D F9 0A     ADC $0AF9       ; update random number seed
C2/BF66: 8D F9 0A     STA $0AF9
C2/BF69: A5 6F        LDA $6F
C2/BF6B: 85 62        STA $62
C2/BF6D: C2 20        REP #$20
C2/BF6F: A9 01 00     LDA #$0001
C2/BF72: 85 39        STA $39
C2/BF74: 20 7D FF     JSR $FF7D       ; update joypad config
C2/BF77: 20 A9 F5     JSR $F5A9       ; update mono/stereo setting
C2/BF7A: 4C 2D A0     JMP $A02D       ; exit menu

; [ get pointer to save slot in sram ]

C2/BF7D: A5 6F        LDA $6F
C2/BF7F: 29 03 00     AND #$0003      ; save slot
C2/BF82: 0A           ASL 
C2/BF83: AA           TAX 
C2/BF84: BF EF F8 C0  LDA $C0F8EF,X   ; pointer to save slot in sram
C2/BF88: 60           RTS 

C0/F8EF:              .DW $6000, $6700, $6E00, $7500

C2/BF89: 20 47 D4     JSR $D447       ; update window color
C2/BF8C: 20 BD B2     JSR $B2BD
C2/BF8F: AD 13 2D     LDA $2D13
C2/BF92: D0 04        BNE $BF98
C2/BF94: A9 0B        LDA #$0B
C2/BF96: 80 02        BRA $BF9A
C2/BF98: A9 0C        LDA #$0C
C2/BF9A: 4C 6B A0     JMP $A06B       ; show menu

C2/BF9D: 20 1B DC     JSR $DC1B
C2/BFA0: C2 20        REP #$20
C2/BFA2: A5 71        LDA $71
C2/BFA4: 29 0F 00     AND #$000F
C2/BFA7: 85 7E        STA $7E
C2/BFA9: 20 C5 D4     JSR $D4C5
C2/BFAC: 20 BA C6     JSR $C6BA
C2/BFAF: E2 20        SEP #$20
C2/BFB1: 20 1B AF     JSR $AF1B
C2/BFB4: 20 98 A6     JSR $A698
C2/BFB7: A2 05 00     LDX #$0005
C2/BFBA: 20 5B E6     JSR $E65B
C2/BFBD: C2 20        REP #$20
C2/BFBF: AD DF 29     LDA $29DF
C2/BFC2: CD E8 29     CMP $29E8
C2/BFC5: 30 03        BMI $BFCA
C2/BFC7: 4C F0 A4     JMP $A4F0
C2/BFCA: 20 53 E6     JSR $E653
C2/BFCD: E2 20        SEP #$20
C2/BFCF: A9 07        LDA #$07
C2/BFD1: 4C 7C A4     JMP $A47C
C2/BFD4: 20 EF DA     JSR $DAEF
C2/BFD7: 20 BD C7     JSR $C7BD
C2/BFDA: 20 9D A6     JSR $A69D
C2/BFDD: 20 1B AF     JSR $AF1B
C2/BFE0: 20 98 A6     JSR $A698
C2/BFE3: A2 05 00     LDX #$0005
C2/BFE6: 20 5B E6     JSR $E65B
C2/BFE9: AD E8 29     LDA $29E8
C2/BFEC: F0 03        BEQ $BFF1
C2/BFEE: 4C F0 A4     JMP $A4F0
C2/BFF1: 20 53 E6     JSR $E653
C2/BFF4: 64 6F        STZ $6F
C2/BFF6: 64 70        STZ $70
C2/BFF8: 9C 89 28     STZ $2889
C2/BFFB: A5 5B        LDA $5B
C2/BFFD: 18           CLC 
C2/BFFE: 69 04        ADC #$04
C2/C000: 4C 7C A4     JMP $A47C
C2/C003: A5 55        LDA $55
C2/C005: C9 05        CMP #$05
C2/C007: F0 13        BEQ $C01C
C2/C009: 85 71        STA $71
C2/C00B: C2 20        REP #$20
C2/C00D: 29 FF 00     AND #$00FF
C2/C010: 3A           DEC 
C2/C011: 0A           ASL 
C2/C012: 0A           ASL 
C2/C013: 18           CLC 
C2/C014: 69 21 00     ADC #$0021
C2/C017: E2 20        SEP #$20
C2/C019: 4C 7C A4     JMP $A47C
C2/C01C: C2 20        REP #$20
C2/C01E: A2 52 F3     LDX #$F352
C2/C021: A0 B4 2C     LDY #$2CB4
C2/C024: A9 0F 00     LDA #$000F
C2/C027: 54 7E C0     MVN $7E,$C0
C2/C02A: 64 6F        STZ $6F
C2/C02C: 20 ED C0     JSR $C0ED
C2/C02F: A6 8E        LDX $8E
C2/C031: FE 20 04     INC $0420,X
C2/C034: E8           INX 
C2/C035: E0 04 00     CPX #$0004
C2/C038: D0 F7        BNE $C031
C2/C03A: 64 71        STZ $71
C2/C03C: A9 1B 4C     LDA #$4C1B
C2/C03F: 7C A4 A9     JMP ($A9A4,X)
C2/C042: 03 4C        ORA $4C,S
C2/C044: 7C A4 A9     JMP ($A9A4,X)
C2/C047: 00 EB        BRK $EB
C2/C049: A5 55        LDA $55
C2/C04B: 3A           DEC 
C2/C04C: AA           TAX 
C2/C04D: BD 9C 2C     LDA $2C9C,X
C2/C050: F0 09        BEQ $C05B
C2/C052: BF 69 F0 C0  LDA $C0F069,X
C2/C056: F0 03        BEQ $C05B
C2/C058: 4C 7C A4     JMP $A47C
C2/C05B: 4C F0 A4     JMP $A4F0
C2/C05E: 20 1C F7     JSR $F71C       ; update config settings
C2/C061: 20 BD B2     JSR $B2BD
C2/C064: A9 01 4C     LDA #$4C01
C2/C067: 6B           RTL 
C2/C068: A0 4C F0     LDY #$F04C
C2/C06B: A4 A9        LDY $A9
C2/C06D: 09 4C 7C     ORA #$7C4C
C2/C070: A4 A5        LDY $A5
C2/C072: 55 C9        EOR $C9,X
C2/C074: 01 F0        ORA ($F0,X)
C2/C076: 03 4C        ORA $4C,S
C2/C078: F0 A4        BEQ $C01E
C2/C07A: A6 8E        LDX $8E
C2/C07C: 8A           TXA 
C2/C07D: 1D A9 2C     ORA $2CA9,X
C2/C080: E8           INX 
C2/C081: E0 07 00     CPX #$0007
C2/C084: 30 F7        BMI $C07D
C2/C086: 29 FC C9     AND #$C9FC
C2/C089: FC D0 0B     JSR ($0BD0,X)
C2/C08C: 20 1C F7     JSR $F71C       ; update config settings
C2/C08F: 20 7D FF     JSR $FF7D       ; update joypad config
C2/C092: A9 08 4C     LDA #$4C08
C2/C095: 7C A4 20     JMP ($20A4,X)
C2/C098: C0 E0 C2     CPY #$C2E0
C2/C09B: 20 A9 D2     JSR $D2A9
C2/C09E: B7 20        LDA [$20],Y
C2/C0A0: B8           CLV 
C2/C0A1: C1 20        CMP ($20,X)
C2/C0A3: 93 A6        STA ($A6,S),Y
C2/C0A5: 20 6E A1     JSR $A16E       ; reset sprite data
C2/C0A8: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/C0AB: A2 78 00     LDX #$0078
C2/C0AE: 20 5B E6     JSR $E65B
C2/C0B1: C2 20        REP #$20
C2/C0B3: 20 9A B1     JSR $B19A
C2/C0B6: E2 20        SEP #$20
C2/C0B8: A5 53        LDA $53
C2/C0BA: 4C 7C A4     JMP $A47C
C2/C0BD: 4C F0 A4     JMP $A4F0

; [  ]

C2/C0C0: A4 8E        LDY $8E
C2/C0C2: 80 08        BRA $C0CC
C2/C0C4: A0 04 FC     LDY #$FC04
C2/C0C7: 80 03        BRA $C0CC
C2/C0C9: A0 02 FF     LDY #$FF02
C2/C0CC: 20 E1 E4     JSR $E4E1       ; get pointer to cursor data
C2/C0CF: 08           PHP 
C2/C0D0: C2 20        REP #$20
C2/C0D2: 98           TYA 
C2/C0D3: 18           CLC 
C2/C0D4: 7D 02 76     ADC $7602,X
C2/C0D7: 8D 04 02     STA $0204
C2/C0DA: A9 02 2E     LDA #$2E02
C2/C0DD: 8D 06 02     STA $0206
C2/C0E0: 28           PLP 
C2/C0E1: 60           RTS 

; [  ]

C2/C0E2: 08           PHP 
C2/C0E3: C2 20        REP #$20
C2/C0E5: 9C 04 02     STZ $0204
C2/C0E8: 9C 06 02     STZ $0206
C2/C0EB: 28           PLP 
C2/C0EC: 60           RTS 
C2/C0ED: 20 C0 F5     JSR $F5C0
C2/C0F0: 20 93 A6     JSR $A693
C2/C0F3: 20 6F E6     JSR $E66F
C2/C0F6: 60           RTS 
C2/C0F7: A5 6F        LDA $6F
C2/C0F9: D0 11        BNE $C10C
C2/C0FB: A9 01        LDA #$01
C2/C0FD: 8D 10 75     STA $7510
C2/C100: A5 55        LDA $55
C2/C102: 85 6F        STA $6F
C2/C104: A5 53        LDA $53
C2/C106: 20 C9 C0     JSR $C0C9
C2/C109: 4C F0 A4     JMP $A4F0
C2/C10C: A5 55        LDA $55
C2/C10E: C5 6F        CMP $6F
C2/C110: F0 F7        BEQ $C109
C2/C112: 3A           DEC 
C2/C113: C2 20        REP #$20
C2/C115: 29 0F 00     AND #$000F
C2/C118: AA           TAX 
C2/C119: A5 6F        LDA $6F
C2/C11B: 3A           DEC 
C2/C11C: 29 0F 00     AND #$000F
C2/C11F: A8           TAY 
C2/C120: E2 20        SEP #$20
C2/C122: BD B4 2C     LDA $2CB4,X
C2/C125: EB           XBA 
C2/C126: B9 B4 2C     LDA $2CB4,Y
C2/C129: 9D B4 2C     STA $2CB4,X
C2/C12C: EB           XBA 
C2/C12D: 99 B4 2C     STA $2CB4,Y
C2/C130: 9C 10 75     STZ $7510
C2/C133: 20 ED C0     JSR $C0ED
C2/C136: C2 20        REP #$20
C2/C138: A5 71        LDA $71
C2/C13A: 29 0F 00     AND #$000F
C2/C13D: 3A           DEC 
C2/C13E: AA           TAX 
C2/C13F: E2 20        SEP #$20
C2/C141: FE 20 04     INC $0420,X
C2/C144: 80 0F        BRA $C155
C2/C146: A5 6F        LDA $6F
C2/C148: D0 0B        BNE $C155
C2/C14A: A5 71        LDA $71
C2/C14C: 3A           DEC 
C2/C14D: 29 03        AND #$03
C2/C14F: 18           CLC 
C2/C150: 69 1B        ADC #$1B
C2/C152: 4C 7C A4     JMP $A47C
C2/C155: C2 20        REP #$20
C2/C157: 64 6F        STZ $6F
C2/C159: 20 E2 C0     JSR $C0E2
C2/C15C: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/C15F: 4C F0 A4     JMP $A4F0

C2/C162: A5 5B        LDA $5B
C2/C164: 18           CLC 
C2/C165: 69 04        ADC #$04
C2/C167: 4C 7C A4     JMP $A47C

; [  ]

C2/C16A: 8B           PHB 
C2/C16B: A5 43        LDA $43         ; menu state
C2/C16D: 29 FF 00     AND #$00FF
C2/C170: 3A           DEC 
C2/C171: 0A           ASL 
C2/C172: AA           TAX 
C2/C173: BF E7 F5 C0  LDA $C0F5E7,X   ; pointer to ??? ($+C00000)
C2/C177: AA           TAX 
C2/C178: A0 DC 2B     LDY #$2BDC      ; copy 24 bytes to 7E/BD2C
C2/C17B: A9 17 00     LDA #$0017
C2/C17E: 54 7E C0     MVN $7E,$C0
C2/C181: A6 8E        LDX $8E
C2/C183: BF CF F5 C0  LDA $C0F5CF,X   ; mvn destination address (+$7E0000)
C2/C187: 85 E6        STA $E6
C2/C189: DA           PHX 
C2/C18A: BF E7 E7 C0  LDA $C0E7E7,X   ; jump address
C2/C18E: 85 C7        STA $C7
C2/C190: BD DC 2B     LDA $2BDC,X     ; pointer to data
C2/C193: 62 02 00     PER $C198
C2/C196: 6C C7 01     JMP ($01C7)

; ram offsets (bg tilemaps, ???, ...)
; C0/F5CF:            .DW $3000, $4000, $5000, $6000, $7000, $7080, $7100, $7180
; C0/F5DF:            .DW $7200, $7280, $7600, $7500

; jump table for loading data
; C0/E7E7:            .DW $C1B8, $C1B8, $C1B8, $C1B8, $C1F7, $C1F7, $C1F7, $C1F7
; C0/E7F7:            .DW $C1A6, $C1A6, $C1A6, $C1A6

C2/C199: FA           PLX 
C2/C19A: E8           INX 
C2/C19B: E8           INX 
C2/C19C: E0 18 00     CPX #$0018
C2/C19F: D0 E2        BNE $C183
C2/C1A1: AB           PLB 
C2/C1A2: 20 8A A1     JSR $A18A
C2/C1A5: 60           RTS 

; [ load menu cursor/??? data ]

C2/C1A6: 8B           PHB 
C2/C1A7: AA           TAX 
C2/C1A8: F0 0C        BEQ $C1B6
C2/C1AA: A4 E6        LDY $E6         ; pointer to cursor data ($+7E0000)
C2/C1AC: BF 00 00 C3  LDA $C30000,X   ; length of cursor data
C2/C1B0: 3A           DEC 
C2/C1B1: E8           INX 
C2/C1B2: E8           INX 
C2/C1B3: 54 7E C3     MVN $7E,$C3
C2/C1B6: AB           PLB 
C2/C1B7: 60           RTS 

; [ load menu tilemap ]

C2/C1B8: 8B           PHB 
C2/C1B9: F4 C3 C3     PEA $C3C3
C2/C1BC: AB           PLB 
C2/C1BD: AB           PLB 
C2/C1BE: AA           TAX 
C2/C1BF: F0 2C        BEQ $C1ED
C2/C1C1: F4 C3 C3     PEA $C3C3
C2/C1C4: AB           PLB 
C2/C1C5: AB           PLB 
C2/C1C6: BD 00 00     LDA $0000,X
C2/C1C9: E8           INX 
C2/C1CA: 29 0F 00     AND #$000F
C2/C1CD: F0 26        BEQ $C1F5
C2/C1CF: 0A           ASL 
C2/C1D0: A8           TAY 
C2/C1D1: B9 31 AD     LDA $AD31,Y
C2/C1D4: F0 08        BEQ $C1DE
C2/C1D6: 5A           PHY 
C2/C1D7: A0 E0 01     LDY #$01E0
C2/C1DA: 54 00 C3     MVN $00,$C3
C2/C1DD: 7A           PLY 
C2/C1DE: F4 7E 7E     PEA $7E7E
C2/C1E1: AB           PLB 
C2/C1E2: AB           PLB 
C2/C1E3: DA           PHX 
C2/C1E4: 08           PHP 
C2/C1E5: BB           TYX 
C2/C1E6: FC EA FF     JSR ($FFEA,X)
C2/C1E9: 28           PLP 
C2/C1EA: FA           PLX 
C2/C1EB: 80 D4        BRA $C1C1
C2/C1ED: F4 7E 7E     PEA $7E7E
C2/C1F0: AB           PLB 
C2/C1F1: AB           PLB 
C2/C1F2: 20 5F C2     JSR $C25F
C2/C1F5: AB           PLB 
C2/C1F6: 60           RTS 

; [ load other menu data ??? ]

C2/C1F7: A4 E6        LDY $E6
C2/C1F9: AA           TAX 
C2/C1FA: D0 01        BNE $C1FD
C2/C1FC: 60           RTS 
C2/C1FD: 8B           PHB 
C2/C1FE: 08           PHP 
C2/C1FF: 64 85        STZ $85
C2/C201: E2 20        SEP #$20
C2/C203: BF 00 00 C3  LDA $C30000,X
C2/C207: F0 31        BEQ $C23A
C2/C209: 30 16        BMI $C221
C2/C20B: 99 00 00     STA $0000,Y
C2/C20E: C2 20        REP #$20
C2/C210: A5 85        LDA $85
C2/C212: 99 01 00     STA $0001,Y
C2/C215: 18           CLC 
C2/C216: 69 04 00     ADC #$0004
C2/C219: 85 85        STA $85
C2/C21B: C8           INY 
C2/C21C: C8           INY 
C2/C21D: C8           INY 
C2/C21E: E8           INX 
C2/C21F: 80 E0        BRA $C201
C2/C221: 48           PHA 
C2/C222: A9 7F        LDA #$7F
C2/C224: 99 00 00     STA $0000,Y
C2/C227: A5 85        LDA $85
C2/C229: 99 01 00     STA $0001,Y
C2/C22C: A9 00        LDA #$00
C2/C230: 99 02 00     STA $0002,Y
C2/C231: C8           INY 
C2/C232: C8           INY 
C2/C233: C8           INY 
C2/C234: 68           PLA 
C2/C235: 29 7F 1A     AND #$1A7F
C2/C238: 80 D1        BRA $C20B
C2/C23A: A9 00        LDA #$00
C2/C23E: 99 00 00     STA $0000,Y
C2/C23F: 28           PLP 
C2/C240: AB           PLB 
C2/C241: 60           RTS 

; [  ]

C2/C242: 48           PHA 
C2/C243: 08           PHP 
C2/C244: A5 E3        LDA $E3
C2/C246: 29 3F        AND #$3F
C2/C248: 00 EB        BRK $EB
C2/C24A: 4A           LSR 
C2/C24B: 4A           LSR 
C2/C24C: 85 E8        STA $E8
C2/C24E: A5 E2        LDA $E2
C2/C250: 29 1F        AND #$1F
C2/C252: 00 0A        BRK $0A
C2/C254: 18           CLC 
C2/C255: 65 E8        ADC $E8
C2/C257: 18           CLC 
C2/C258: 65 E6        ADC $E6
C2/C25A: 85 E8        STA $E8
C2/C25C: 28           PLP 
C2/C25D: 68           PLA 
C2/C25E: 60           RTS 
C2/C25F: 64 E0        STZ $E0
C2/C261: A5 E0        LDA $E0
C2/C263: A0 00 10     LDY #$1000
C2/C266: 88           DEY 
C2/C267: 88           DEY 
C2/C268: 91 E6        STA ($E6),Y
C2/C26A: D0 FA        BNE $C266
C2/C26C: 60           RTS 
C2/C26D: A5 E0        LDA $E0
C2/C26F: 85 E6        STA $E6
C2/C271: 60           RTS 
C2/C272: 9D 00 00     STA $0000,X
C2/C275: E8           INX 
C2/C276: E8           INX 
C2/C277: 88           DEY 
C2/C278: D0 F8        BNE $C272
C2/C27A: 60           RTS 
C2/C27B: 88           DEY 
C2/C27C: 88           DEY 
C2/C27D: 3A           DEC 
C2/C27E: 9D 00 00     STA $0000,X
C2/C281: E8           INX 
C2/C282: E8           INX 
C2/C283: 1A           INC 
C2/C284: 20 72 C2     JSR $C272
C2/C287: 1A           INC 
C2/C288: 9D 00 00     STA $0000,X
C2/C28B: 60           RTS 
C2/C28C: 48           PHA 
C2/C28D: A4 8E        LDY $8E
C2/C28F: A3 01        LDA $01,S
C2/C291: 91 EC        STA ($EC),Y
C2/C293: 8A           TXA 
C2/C294: 91 EE        STA ($EE),Y
C2/C296: C6 EA        DEC $EA
C2/C298: F0 08        BEQ $C2A2
C2/C29A: 98           TYA 
C2/C29B: 18           CLC 
C2/C29C: 69 40        ADC #$40
C2/C29E: 00 A8        BRK $A8
C2/C2A0: 80 ED        BRA $C28F
C2/C2A2: 68           PLA 
C2/C2A3: 60           RTS 
C2/C2A4: 20 42 C2     JSR $C242
C2/C2A7: A5 E5        LDA $E5
C2/C2A9: 29 FF        AND #$FF
C2/C2AB: 00 85        BRK $85
C2/C2AD: EA           NOP 
C2/C2AE: A6 E8        LDX $E8
C2/C2B0: A5 E4        LDA $E4
C2/C2B2: 29 7F        AND #$7F
C2/C2B4: 00 A8        BRK $A8
C2/C2B6: DA           PHX 
C2/C2B7: 5A           PHY 
C2/C2B8: A5 E0        LDA $E0
C2/C2BA: 20 72 C2     JSR $C272
C2/C2BD: 7A           PLY 
C2/C2BE: FA           PLX 
C2/C2BF: C6 EA        DEC $EA
C2/C2C1: F0 08        BEQ $C2CB
C2/C2C3: 8A           TXA 
C2/C2C4: 18           CLC 
C2/C2C5: 69 40        ADC #$40
C2/C2C7: 00 AA        BRK $AA
C2/C2C9: 80 EB        BRA $C2B6
C2/C2CB: 60           RTS 
C2/C2CC: 20 E8 C2     JSR $C2E8
C2/C2CF: A9 FF        LDA #$FF
C2/C2D1: 00 85        BRK $85
C2/C2D3: E0 E2 20     CPX #$20E2
C2/C2D6: E6 E2        INC $E2
C2/C2D8: E6 E3        INC $E3
C2/C2DA: C6 E4        DEC $E4
C2/C2DC: C6 E4        DEC $E4
C2/C2DE: C6 E5        DEC $E5
C2/C2E0: C6 E5        DEC $E5
C2/C2E2: C2 20        REP #$20
C2/C2E4: 20 A4 C2     JSR $C2A4
C2/C2E7: 60           RTS 
C2/C2E8: 20 42 C2     JSR $C242
C2/C2EB: A5 E8        LDA $E8
C2/C2ED: AA           TAX 
C2/C2EE: 18           CLC 
C2/C2EF: 69 40 00     ADC #$0040
C2/C2F2: 85 EC        STA $EC
C2/C2F4: A5 E4        LDA $E4
C2/C2F6: 29 3F 00     AND #$003F
C2/C2F9: A8           TAY 
C2/C2FA: A5 E0        LDA $E0
C2/C2FC: 20 7B C2     JSR $C27B
C2/C2FF: 8A           TXA 
C2/C300: 18           CLC 
C2/C301: 69 40 00     ADC #$0040
C2/C304: 85 EE        STA $EE
C2/C306: A5 E5        LDA $E5
C2/C308: 29 7F 00     AND #$007F
C2/C30B: 3A           DEC 
C2/C30C: 3A           DEC 
C2/C30D: 85 EA        STA $EA
C2/C30F: A9 04 00     LDA #$0004
C2/C312: A2 05 00     LDX #$0005
C2/C315: 20 8C C2     JSR $C28C
C2/C318: 98           TYA 
C2/C319: 18           CLC 
C2/C31A: 69 80 00     ADC #$0080
C2/C31D: 65 E8        ADC $E8
C2/C31F: AA           TAX 
C2/C320: A5 E4        LDA $E4
C2/C322: 29 3F 00     AND #$003F
C2/C325: A8           TAY 
C2/C326: A9 07 00     LDA #$0007
C2/C329: 20 7B C2     JSR $C27B
C2/C32C: 60           RTS 
C2/C32D: 20 42 C2     JSR $C242
C2/C330: A5 E0        LDA $E0
C2/C332: 29 FF 00     AND #$00FF
C2/C335: 0A           ASL 
C2/C336: AA           TAX 
C2/C337: BF 87 F9 C0  LDA $C0F987,X
C2/C33B: A8           TAY 
C2/C33C: A6 E8        LDX $E8
C2/C33E: A5 E4        LDA $E4
C2/C340: 29 FF 00     AND #$00FF
C2/C343: 09 00 C0     ORA #$C000
C2/C346: 20 9D E5     JSR $E59D
C2/C349: 60           RTS 

; [ menu state $08:  ]

C2/C34A: 20 3D F6     JSR $F63D
C2/C34D: A5 8E        LDA $8E
C2/C34F: 8F 94 2C 7E  STA $7E2C94
C2/C353: 20 A6 F7     JSR $F7A6
C2/C356: AF 94 2C 7E  LDA $7E2C94
C2/C35A: 1A           INC 
C2/C35B: 8F 94 2C 7E  STA $7E2C94
C2/C35F: C9 0A 00     CMP #$000A
C2/C362: D0 EF        BNE $C353
C2/C364: 20 10 F8     JSR $F810
C2/C367: E2 20        SEP #$20
C2/C369: 64 53        STZ $53
C2/C36B: 20 10 D2     JSR $D210
C2/C36E: 60           RTS 

; [ menu state $09:  ]

C2/C36F: F4 7E 7E     PEA $7E7E
C2/C372: AB           PLB 
C2/C373: AB           PLB 
C2/C374: E2 20        SEP #$20
C2/C376: 64 53        STZ $53
C2/C378: 20 10 D2     JSR $D210
C2/C37B: A2 08 00     LDX #$0008
C2/C37E: 9E 99 2B     STZ $2B99,X
C2/C381: 9E A1 2B     STZ $2BA1,X
C2/C384: 9E A9 2B     STZ $2BA9,X
C2/C387: 9E B1 2B     STZ $2BB1,X
C2/C38A: CA           DEX 
C2/C38B: D0 F1        BNE $C37E
C2/C38D: A4 8E        LDY $8E
C2/C38F: B9 3B 01     LDA $013B,Y
C2/C392: F0 1D        BEQ $C3B1
C2/C394: A6 8E        LDX $8E
C2/C396: BD 9A 2B     LDA $2B9A,X
C2/C399: F0 0D        BEQ $C3A8
C2/C39B: D9 3B 01     CMP $013B,Y
C2/C39E: F0 0E        BEQ $C3AE
C2/C3A0: E8           INX 
C2/C3A1: E0 08 00     CPX #$0008
C2/C3A4: D0 F0        BNE $C396
C2/C3A6: 80 09        BRA $C3B1
C2/C3A8: B9 3B 01     LDA $013B,Y
C2/C3AB: 9D 9A 2B     STA $2B9A,X
C2/C3AE: FE A2 2B     INC $2BA2,X
C2/C3B1: C8           INY 
C2/C3B2: C0 08 00     CPY #$0008
C2/C3B5: D0 D8        BNE $C38F
C2/C3B7: A4 8E        LDY $8E
C2/C3B9: B9 9A 2B     LDA $2B9A,Y
C2/C3BC: F0 0A        BEQ $C3C8
C2/C3BE: 20 19 C4     JSR $C419
C2/C3C1: 99 AA 2B     STA $2BAA,Y
C2/C3C4: EB           XBA 
C2/C3C5: 99 B2 2B     STA $2BB2,Y
C2/C3C8: C8           INY 
C2/C3C9: C0 08 00     CPY #$0008
C2/C3CC: D0 EB        BNE $C3B9
C2/C3CE: 20 D2 C3     JSR $C3D2
C2/C3D1: 60           RTS 
C2/C3D2: 8B           PHB 
C2/C3D3: 08           PHP 
C2/C3D4: F4 7E 7E     PEA $7E7E
C2/C3D7: AB           PLB 
C2/C3D8: AB           PLB 
C2/C3D9: E2 20        SEP #$20
C2/C3DB: A2 46 52     LDX #$5246
C2/C3DE: 86 99        STX $99
C2/C3E0: A2 08 00     LDX #$0008
C2/C3E3: 86 85        STX $85
C2/C3E5: A6 8E        LDX $8E
C2/C3E7: 20 FD C3     JSR $C3FD
C2/C3EA: A2 64 52     LDX #$5264
C2/C3ED: 86 99        STX $99
C2/C3EF: A2 08 00     LDX #$0008
C2/C3F2: 86 85        STX $85
C2/C3F4: A2 10 00     LDX #$0010
C2/C3F7: 20 FD C3     JSR $C3FD
C2/C3FA: 28           PLP 
C2/C3FB: AB           PLB 
C2/C3FC: 60           RTS 
C2/C3FD: BD 9A 2B     LDA $2B9A,X
C2/C400: EB           XBA 
C2/C401: BD A2 2B     LDA $2BA2,X
C2/C404: EB           XBA 
C2/C405: 08           PHP 
C2/C406: DA           PHX 
C2/C407: A4 99        LDY $99
C2/C409: 20 A6 E3     JSR $E3A6
C2/C40C: C2 20        REP #$20
C2/C40E: 20 8C CB     JSR $CB8C
C2/C411: FA           PLX 
C2/C412: 28           PLP 
C2/C413: E8           INX 
C2/C414: C6 85        DEC $85
C2/C416: D0 E5        BNE $C3FD
C2/C418: 60           RTS 
C2/C419: 08           PHP 
C2/C41A: A6 8E        LDX $8E
C2/C41C: DD 40 06     CMP $0640,X
C2/C41F: F0 1A        BEQ $C43B
C2/C421: E8           INX 
C2/C422: E0 00 01     CPX #$0100
C2/C425: D0 F5        BNE $C41C
C2/C427: A6 8E        LDX $8E
C2/C429: BD 40 06     LDA $0640,X
C2/C42C: F0 07        BEQ $C435
C2/C42E: E8           INX 
C2/C42F: E0 00 01     CPX #$0100
C2/C432: D0 F5        BNE $C429
C2/C434: CA           DEX 
C2/C435: C2 20        REP #$20
C2/C437: A5 8E        LDA $8E
C2/C439: 80 05        BRA $C440
C2/C43B: EB           XBA 
C2/C43C: BD 40 07     LDA $0740,X
C2/C43F: EB           XBA 
C2/C440: 28           PLP 
C2/C441: 60           RTS 

; [ menu state $0C:  ]

C2/C442: F4 7E 7E     PEA $7E7E
C2/C445: AB           PLB 
C2/C446: AB           PLB 
C2/C447: E2 20        SEP #$20
C2/C449: A9 01        LDA #$01
C2/C44B: 8D 65 2B     STA $2B65
C2/C44E: 9C 66 2B     STZ $2B66
C2/C451: 9C 67 2B     STZ $2B67
C2/C454: A9 0A        LDA #$0A
C2/C456: 8D 68 2B     STA $2B68
C2/C459: 8D 69 2B     STA $2B69
C2/C45C: 9C 6C 2B     STZ $2B6C
C2/C45F: A9 80        LDA #$80
C2/C461: 8D 6D 2B     STA $2B6D
C2/C464: 9C 6E 2B     STZ $2B6E
C2/C467: 9C 6F 2B     STZ $2B6F
C2/C46A: 64 53        STZ $53
C2/C46C: 20 10 D2     JSR $D210
C2/C46F: 20 DA C4     JSR $C4DA
C2/C472: C2 20        REP #$20
C2/C474: 9C 92 2B     STZ $2B92
C2/C477: 20 51 C5     JSR $C551
C2/C47A: A9 FF FF     LDA #$FFFF
C2/C47D: 8D 90 09     STA $0990
C2/C480: 8D 92 09     STA $0992
C2/C483: 8D 94 09     STA $0994
C2/C486: A2 C4 51     LDX #$51C4
C2/C489: A0 90 09     LDY #$0990
C2/C48C: A9 06 00     LDA #$0006
C2/C48F: 20 9D E5     JSR $E59D
C2/C492: A2 07 EC     LDX #$EC07
C2/C495: A0 70 2B     LDY #$2B70
C2/C498: A9 09 00     LDA #$0009
C2/C49B: 54 7E C0     MVN $7E,$C0
C2/C49E: A2 11 EC     LDX #$EC11
C2/C4A1: A0 80 2B     LDY #$2B80
C2/C4A4: A9 09 00     LDA #$0009
C2/C4A7: 54 7E C0     MVN $7E,$C0
C2/C4AA: A9 18 00     LDA #$0018
C2/C4AD: 8D 6A 2B     STA $2B6A
C2/C4B0: A2 80 00     LDX #$0080
C2/C4B3: 9E FE 79     STZ $79FE,X
C2/C4B6: CA           DEX 
C2/C4B7: CA           DEX 
C2/C4B8: D0 F9        BNE $C4B3
C2/C4BA: A9 FF FF     LDA #$FFFF
C2/C4BD: 8D 62 7A     STA $7A62
C2/C4C0: 64 7E        STZ $7E
C2/C4C2: 20 C5 D4     JSR $D4C5
C2/C4C5: A6 80        LDX $80
C2/C4C7: BD 00 05     LDA $0500,X
C2/C4CA: 29 07 00     AND #$0007
C2/C4CD: F0 04        BEQ $C4D3
C2/C4CF: E6 7E        INC $7E
C2/C4D1: 80 EF        BRA $C4C2
C2/C4D3: A9 1C 3C     LDA #$3C1C
C2/C4D6: 20 DE C8     JSR $C8DE
C2/C4D9: 60           RTS 
C2/C4DA: 8B           PHB 
C2/C4DB: 08           PHP 
C2/C4DC: F4 7E 7E     PEA $7E7E
C2/C4DF: AB           PLB 
C2/C4E0: AB           PLB 
C2/C4E1: E2 20        SEP #$20
C2/C4E3: A2 94 61     LDX #$6194
C2/C4E6: 86 99        STX $99
C2/C4E8: C2 20        REP #$20
C2/C4EA: A6 8E        LDX $8E
C2/C4EC: A4 8E        LDY $8E
C2/C4EE: 20 44 C5     JSR $C544
C2/C4F1: C0 0A 00     CPY #$000A
C2/C4F4: D0 F8        BNE $C4EE
C2/C4F6: A9 FF 00     LDA #$00FF
C2/C4F9: 99 3F 2B     STA $2B3F,Y
C2/C4FC: C8           INY 
C2/C4FD: 20 44 C5     JSR $C544
C2/C500: C0 15 00     CPY #$0015
C2/C503: 30 F8        BMI $C4FD
C2/C505: DA           PHX 
C2/C506: A6 99        LDX $99
C2/C508: A0 3F 2B     LDY #$2B3F
C2/C50B: A9 14 7E     LDA #$7E14
C2/C50E: 20 9D E5     JSR $E59D
C2/C511: 20 8C CB     JSR $CB8C
C2/C514: FA           PLX 
C2/C515: E0 64 00     CPX #$0064
C2/C518: D0 D2        BNE $C4EC
C2/C51A: 28           PLP 
C2/C51B: AB           PLB 
C2/C51C: 60           RTS 
C2/C51D: 08           PHP 
C2/C51E: C2 20        REP #$20
C2/C520: BF 14 F4 C0  LDA $C0F414,X
C2/C524: 29 FF 00     AND #$00FF
C2/C527: C9 48 00     CMP #$0048
C2/C52A: F0 13        BEQ $C53F
C2/C52C: C9 53 00     CMP #$0053
C2/C52F: 30 0A        BMI $C53B
C2/C531: C9 60 00     CMP #$0060
C2/C534: 30 09        BMI $C53F
C2/C536: C9 C4 00     CMP #$00C4
C2/C539: 10 04        BPL $C53F
C2/C53B: 18           CLC 
C2/C53C: 6D 65 2B     ADC $2B65
C2/C53F: 29 FF 00     AND #$00FF
C2/C542: 28           PLP 
C2/C543: 60           RTS 
C2/C544: 20 1D C5     JSR $C51D
C2/C547: 09 00        ORA #$00
C2/C549: FF 99 3F 2B  SBC $2B3F99,X
C2/C54D: C8           INY 
C2/C54E: C8           INY 
C2/C54F: E8           INX 
C2/C550: 60           RTS 
C2/C551: 08           PHP 
C2/C552: 8B           PHB 
C2/C553: C2 20        REP #$20
C2/C555: A9 2B B6     LDA #$B62B
C2/C558: 20 B8 C1     JSR $C1B8
C2/C55B: AB           PLB 
C2/C55C: C2 20        REP #$20
C2/C55E: AD 92 2B     LDA $2B92
C2/C561: 0A           ASL 
C2/C562: AA           TAX 
C2/C563: A9 E0 00     LDA #$00E0
C2/C566: 9D 04 52     STA $5204,X
C2/C569: 28           PLP 
C2/C56A: 60           RTS 

; [ menu state $0B:  ]

C2/C56B: 8B           PHB 
C2/C56C: 08           PHP 
C2/C56D: 64 39        STZ $39
C2/C56F: 20 D4 F4     JSR $F4D4
C2/C572: A6 8E        LDX $8E
C2/C574: BF 14 2C 7E  LDA $7E2C14,X
C2/C578: F0 0D        BEQ $C587
C2/C57A: 8A           TXA 
C2/C57B: 18           CLC 
C2/C57C: 69 20 00     ADC #$0020
C2/C57F: AA           TAX 
C2/C580: E0 80 00     CPX #$0080
C2/C583: D0 EF        BNE $C574
C2/C585: 80 12        BRA $C599
C2/C587: E6 39        INC $39
C2/C589: E2 20        SEP #$20
C2/C58B: AF E0 7F 30  LDA $307FE0
C2/C58F: 29 03        AND #$03
C2/C591: 1A           INC 
C2/C592: 85 53        STA $53
C2/C594: 20 9C C5     JSR $C59C
C2/C597: 64 6F        STZ $6F
C2/C599: 28           PLP 
C2/C59A: AB           PLB 
C2/C59B: 60           RTS 

C2/C59C: 20 10 D2     JSR $D210
C2/C59F: 20 63 F4     JSR $F463
C2/C5A2: 20 50 F4     JSR $F450
C2/C5A5: 20 F6 F3     JSR $F3F6
C2/C5A8: 20 9C F3     JSR $F39C
C2/C5AB: C2 20        REP #$20
C2/C5AD: A9 00 60     LDA #$6000
C2/C5B0: 85 E6        STA $E6
C2/C5B2: A9 A6 AD     LDA #$ADA6
C2/C5B5: 20 B8 C1     JSR $C1B8
C2/C5B8: 60           RTS 

; [ menu state $0A: collect items after battle ]

C2/C5B9: 20 D4 F4     JSR $F4D4
C2/C5BC: E2 20        SEP #$20
C2/C5BE: A5 62        LDA $62
C2/C5C0: 85 53        STA $53
C2/C5C2: 20 9C C5     JSR $C59C
C2/C5C5: 64 6F        STZ $6F
C2/C5C7: 60           RTS 

; [ menu state $07:  ]

C2/C5C8: A5 71        LDA $71
C2/C5CA: 29 07 00     AND #$0007
C2/C5CD: 85 7E        STA $7E
C2/C5CF: 20 C5 D4     JSR $D4C5
C2/C5D2: 20 BA C6     JSR $C6BA
C2/C5D5: A9 34 B4     LDA #$B434
C2/C5D8: 20 B8 C1     JSR $C1B8
C2/C5DB: F4 7E 7E     PEA $7E7E
C2/C5DE: AB           PLB 
C2/C5DF: AB           PLB 
C2/C5E0: A2 50 09     LDX #$0950      ; known spells
C2/C5E3: A0 B8 29     LDY #$29B8
C2/C5E6: A9 1F 00     LDA #$001F
C2/C5E9: 54 7E 7E     MVN $7E,$7E
C2/C5EC: A6 80        LDX $80
C2/C5EE: A4 8E        LDY $8E
C2/C5F0: E2 20        SEP #$20
C2/C5F2: BD 3D 05     LDA $053D,X     ; spell level
C2/C5F5: 48           PHA 
C2/C5F6: 29 F0        AND #$F0
C2/C5F8: 4A           LSR 
C2/C5F9: 4A           LSR 
C2/C5FA: 4A           LSR 
C2/C5FB: 4A           LSR 
C2/C5FC: 48           PHA 
C2/C5FD: 0A           ASL 
C2/C5FE: 18           CLC 
C2/C5FF: 63 01        ADC $01,S
C2/C601: 99 D8 29     STA $29D8,Y
C2/C604: 68           PLA 
C2/C605: 68           PLA 
C2/C606: C8           INY 
C2/C607: C0 05 00     CPY #$0005
C2/C60A: F0 0F        BEQ $C61B
C2/C60C: 29 0F        AND #$0F
C2/C60E: 48           PHA 
C2/C60F: 0A           ASL 
C2/C610: 18           CLC 
C2/C611: 63 01        ADC $01,S
C2/C613: 99 D8 29     STA $29D8,Y
C2/C616: 68           PLA 
C2/C617: C8           INY 
C2/C618: E8           INX 
C2/C619: 80 D7        BRA $C5F2
C2/C61B: A9 20        LDA #$20
C2/C61D: 99 D8 29     STA $29D8,Y
C2/C620: A9 08        LDA #$08
C2/C622: 99 D9 29     STA $29D9,Y
C2/C625: A2 A2 00     LDX #$00A2
C2/C628: 9E F9 29     STZ $29F9,X
C2/C62B: 9E 9B 2A     STZ $2A9B,X
C2/C62E: CA           DEX 
C2/C62F: D0 F7        BNE $C628
C2/C631: A4 8E        LDY $8E
C2/C633: 98           TYA 
C2/C634: 20 1D F0     JSR $F01D
C2/C637: 3D B8 29     AND $29B8,X
C2/C63A: F0 02        BEQ $C63E
C2/C63C: A9 80        LDA #$80
C2/C63E: 99 FB 29     STA $29FB,Y
C2/C641: 98           TYA 
C2/C642: C2 20        REP #$20
C2/C644: 29 FF 00     AND #$00FF
C2/C647: 0A           ASL 
C2/C648: 0A           ASL 
C2/C649: 0A           ASL 
C2/C64A: AA           TAX 
C2/C64B: E2 20        SEP #$20
C2/C64D: BF 83 0B D1  LDA $D10B83,X
C2/C651: 29 7F        AND #$7F
C2/C653: 99 9D 2A     STA $2A9D,Y
C2/C656: BF 80 0B D1  LDA $D10B80,X
C2/C65A: 29 C0        AND #$C0
C2/C65C: 4A           LSR 
C2/C65D: 4A           LSR 
C2/C65E: 19 FB 29     ORA $29FB,Y
C2/C661: 99 FB 29     STA $29FB,Y
C2/C664: C8           INY 
C2/C665: C0 A0 00     CPY #$00A0
C2/C668: D0 C9        BNE $C633
C2/C66A: E2 20        SEP #$20
C2/C66C: 9C E2 29     STZ $29E2
C2/C66F: 64 6F        STZ $6F
C2/C671: 64 70        STZ $70
C2/C673: A6 7E        LDX $7E
C2/C675: AD 73 09     LDA $0973
C2/C678: 29 04        AND #$04
C2/C67A: D0 06        BNE $C682
C2/C67C: 74 63        STZ $63,X
C2/C67E: A9 07        LDA #$07
C2/C680: 95 67        STA $67,X
C2/C682: B5 63        LDA $63,X
C2/C684: 85 53        STA $53
C2/C686: 20 10 D2     JSR $D210
C2/C689: A9 03        LDA #$03
C2/C68B: 8D 68 2B     STA $2B68
C2/C68E: A9 0A        LDA #$0A
C2/C690: 8D 69 2B     STA $2B69
C2/C693: C2 20        REP #$20
C2/C695: 9C 6C 2B     STZ $2B6C
C2/C698: 9C 6E 2B     STZ $2B6E
C2/C69B: A2 FA EB     LDX #$EBFA
C2/C69E: A0 70 2B     LDY #$2B70
C2/C6A1: A9 02 00     LDA #$0002
C2/C6A4: 54 7E C0     MVN $7E,$C0
C2/C6A7: A2 FD EB     LDX #$EBFD
C2/C6AA: A0 80 2B     LDY #$2B80
C2/C6AD: A9 09 00     LDA #$0009
C2/C6B0: 54 7E C0     MVN $7E,$C0
C2/C6B3: A9 C8 00     LDA #$00C8
C2/C6B6: 8D 6A 2B     STA $2B6A
C2/C6B9: 60           RTS 
C2/C6BA: 8B           PHB 
C2/C6BB: 08           PHP 
C2/C6BC: C2 20        REP #$20
C2/C6BE: A2 85 EF     LDX #$EF85
C2/C6C1: A9 17 00     LDA #$0017
C2/C6C4: 20 9D DA     JSR $DA9D
C2/C6C7: A9 00 50     LDA #$5000
C2/C6CA: 8D BA 2B     STA $2BBA
C2/C6CD: 20 D7 DD     JSR $DDD7
C2/C6D0: A9 12 30     LDA #$3012
C2/C6D3: 20 DE C8     JSR $C8DE
C2/C6D6: A6 80        LDX $80
C2/C6D8: BD 0A 05     LDA $050A,X
C2/C6DB: 8D DF 29     STA $29DF
C2/C6DE: E2 20        SEP #$20
C2/C6E0: BD 1A 05     LDA $051A,X
C2/C6E3: 8D E1 29     STA $29E1
C2/C6E6: 28           PLP 
C2/C6E7: AB           PLB 
C2/C6E8: 60           RTS 
C2/C6E9: 08           PHP 
C2/C6EA: C2 20        REP #$20
C2/C6EC: A0 E5 2C     LDY #$2CE5
C2/C6EF: A9 05 00     LDA #$0005
C2/C6F2: 54 7E C0     MVN $7E,$C0
C2/C6F5: 28           PLP 
C2/C6F6: 60           RTS 

; [ menu state $06: shop ]

C2/C6F7: E2 20        SEP #$20
C2/C6F9: A9 7E        LDA #$7E
C2/C6FB: 48           PHA 
C2/C6FC: AB           PLB 
C2/C6FD: AD 73 09     LDA $0973
C2/C700: 29 04        AND #$04
C2/C702: D0 04        BNE $C708
C2/C704: 64 5C        STZ $5C
C2/C706: 64 5B        STZ $5B
C2/C708: C2 20        REP #$20
C2/C70A: A5 5C        LDA $5C
C2/C70C: 29 FF 00     AND #$00FF
C2/C70F: 85 6B        STA $6B
C2/C711: 20 BD C7     JSR $C7BD
C2/C714: E2 20        SEP #$20
C2/C716: A5 5B        LDA $5B
C2/C718: 18           CLC 
C2/C719: 69 04        ADC #$04
C2/C71B: 85 53        STA $53
C2/C71D: 20 10 D2     JSR $D210
C2/C720: 9C 15 2D     STZ $2D15
C2/C723: 9C 87 28     STZ $2887
C2/C726: 9C 89 28     STZ $2889
C2/C729: A9 02        LDA #$02
C2/C72B: 8D B6 29     STA $29B6
C2/C72E: 20 67 E3     JSR $E367
C2/C731: A2 4E E9     LDX #$E94E
C2/C734: 20 E9 C6     JSR $C6E9
C2/C737: C2 20        REP #$20
C2/C739: 20 5E AC     JSR $AC5E
C2/C73C: 60           RTS 
C2/C73D: 8B           PHB 
C2/C73E: 08           PHP 
C2/C73F: F4 7E 7E     PEA $7E7E
C2/C742: AB           PLB 
C2/C743: AB           PLB 
C2/C744: C2 20        REP #$20
C2/C746: A4 8E        LDY $8E
C2/C748: 64 85        STZ $85
C2/C74A: 5A           PHY 
C2/C74B: 98           TYA 
C2/C74C: E2 20        SEP #$20
C2/C74E: 20 1D F0     JSR $F01D
C2/C751: 3D 4A 0A     AND $0A4A,X
C2/C754: F0 20        BEQ $C776
C2/C756: C2 20        REP #$20
C2/C758: A6 85        LDX $85
C2/C75A: BF 74 E9 C0  LDA $C0E974,X
C2/C75E: 38           SEC 
C2/C75F: E9 C2 00     SBC #$00C2
C2/C762: E8           INX 
C2/C763: E8           INX 
C2/C764: 86 85        STX $85
C2/C766: AA           TAX 
C2/C767: 98           TYA 
C2/C768: 0A           ASL 
C2/C769: 0A           ASL 
C2/C76A: 0A           ASL 
C2/C76B: 18           CLC 
C2/C76C: 69 00 E5     ADC #$E500
C2/C76F: A8           TAY 
C2/C770: A9 08 C0     LDA #$C008
C2/C773: 20 9D E5     JSR $E59D
C2/C776: 7A           PLY 
C2/C777: C8           INY 
C2/C778: C0 20 00     CPY #$0020
C2/C77B: D0 CD        BNE $C74A
C2/C77D: 28           PLP 
C2/C77E: AB           PLB 
C2/C77F: 60           RTS 
C2/C780: 08           PHP 
C2/C781: A6 8E        LDX $8E
C2/C783: E2 20        SEP #$20
C2/C785: BD 00 7A     LDA $7A00,X
C2/C788: D0 08        BNE $C792
C2/C78A: 9E 00 7B     STZ $7B00,X
C2/C78D: 9E 8A 28     STZ $288A,X
C2/C790: 80 23        BRA $C7B5
C2/C792: DA           PHX 
C2/C793: C2 20        REP #$20
C2/C795: 29 FF 00     AND #$00FF
C2/C798: 48           PHA 
C2/C799: 20 AB D9     JSR $D9AB
C2/C79C: 68           PLA 
C2/C79D: C9 E0 00     CMP #$00E0
C2/C7A0: E2 20        SEP #$20
C2/C7A2: 30 06        BMI $C7AA
C2/C7A4: A5 9E        LDA $9E
C2/C7A6: 29 3F        AND #$3F
C2/C7A8: 80 07        BRA $C7B1
C2/C7AA: A5 9F        LDA $9F
C2/C7AC: 29 3F        AND #$3F
C2/C7AE: 18           CLC 
C2/C7AF: 69 00        ADC #$00
C2/C7B1: FA           PLX 
C2/C7B2: 9D 8A 28     STA $288A,X
C2/C7B5: E8           INX 
C2/C7B6: E0 00 01     CPX #$0100
C2/C7B9: D0 C8        BNE $C783
C2/C7BB: 28           PLP 
C2/C7BC: 60           RTS 
C2/C7BD: 8B           PHB 
C2/C7BE: 08           PHP 
C2/C7BF: C2 20        REP #$20
C2/C7C1: A9 EA 00     LDA #$00EA
C2/C7C4: 85 6D        STA $6D
C2/C7C6: 64 6F        STZ $6F
C2/C7C8: A2 40 06     LDX #$0640
C2/C7CB: A0 00 7A     LDY #$7A00
C2/C7CE: A9 FF 01     LDA #$01FF
C2/C7D1: 54 7E 7E     MVN $7E,$7E
C2/C7D4: 20 80 C7     JSR $C780
C2/C7D7: A6 8E        LDX $8E
C2/C7D9: A5 6B        LDA $6B
C2/C7DB: 29 FF 00     AND #$00FF
C2/C7DE: A8           TAY 
C2/C7DF: BF 8F ED C0  LDA $C0ED8F,X
C2/C7E3: DA           PHX 
C2/C7E4: 5A           PHY 
C2/C7E5: BB           TYX 
C2/C7E6: A8           TAY 
C2/C7E7: 20 F3 E3     JSR $E3F3
C2/C7EA: 7A           PLY 
C2/C7EB: FA           PLX 
C2/C7EC: E8           INX 
C2/C7ED: E8           INX 
C2/C7EE: C8           INY 
C2/C7EF: E0 30 00     CPX #$0030
C2/C7F2: D0 EB        BNE $C7DF
C2/C7F4: A2 50 F2     LDX #$F250
C2/C7F7: A0 8A 29     LDY #$298A
C2/C7FA: A9 15 00     LDA #$0015
C2/C7FD: 54 7E C0     MVN $7E,$C0
C2/C800: 28           PLP 
C2/C801: AB           PLB 
C2/C802: 60           RTS 

; [ menu state $05:  ]

C2/C803: E2 20        SEP #$20
C2/C805: A9 7E        LDA #$7E
C2/C807: 48           PHA 
C2/C808: AB           PLB 
C2/C809: A5 35        LDA $35
C2/C80B: 8D 00 28     STA $2800
C2/C80E: 64 39        STZ $39
C2/C810: 9C 05 28     STZ $2805
C2/C813: AD 00 28     LDA $2800
C2/C816: C9 3E        CMP #$3E
C2/C818: F0 04        BEQ $C81E
C2/C81A: C9 3F        CMP #$3F
C2/C81C: D0 05        BNE $C823
C2/C81E: A9 80        LDA #$80
C2/C820: 8D 05 28     STA $2805
C2/C823: 9C 04 28     STZ $2804
C2/C826: 20 8F F1     JSR $F18F
C2/C829: C2 20        REP #$20
C2/C82B: A6 8E        LDX $8E
C2/C82D: 9E 07 28     STZ $2807,X
C2/C830: E8           INX 
C2/C831: E8           INX 
C2/C832: E0 1E 00     CPX #$001E
C2/C835: D0 F6        BNE $C82D
C2/C837: AD 47 09     LDA $0947
C2/C83A: 8D 15 28     STA $2815
C2/C83D: AD 49 09     LDA $0949
C2/C840: 29 FF 00     AND #$00FF
C2/C843: 8D 17 28     STA $2817
C2/C846: A9 7F 96     LDA #$967F
C2/C849: 8D 21 28     STA $2821
C2/C84C: A9 98 00     LDA #$0098
C2/C84F: 8D 23 28     STA $2823
C2/C852: A2 E8 51     LDX #$51E8
C2/C855: A0 15 28     LDY #$2815
C2/C858: A9 73 7E     LDA #$7E73
C2/C85B: 20 ED E4     JSR $E4ED
C2/C85E: 20 5B F1     JSR $F15B
C2/C861: E2 20        SEP #$20
C2/C863: A9 0B        LDA #$0B
C2/C865: 20 BD CF     JSR $CFBD
C2/C868: E2 20        SEP #$20
C2/C86A: 64 5C        STZ $5C
C2/C86C: 64 5B        STZ $5B
C2/C86E: A9 18        LDA #$18
C2/C870: 8D 06 28     STA $2806
C2/C873: C2 20        REP #$20
C2/C875: 64 6B        STZ $6B
C2/C877: 64 6F        STZ $6F
C2/C879: A9 03 00     LDA #$0003
C2/C87C: 8D B6 29     STA $29B6
C2/C87F: A2 54 E9     LDX #$E954
C2/C882: 20 E9 C6     JSR $C6E9
C2/C885: A4 8E        LDY $8E
C2/C887: 84 7E        STY $7E
C2/C889: 20 C5 D4     JSR $D4C5
C2/C88C: A6 80        LDX $80
C2/C88E: BD 00 05     LDA $0500,X
C2/C891: 29 07 1F     AND #$1F07
C2/C894: 5A           PHY 
C2/C895: 20 92 D4     JSR $D492
C2/C898: 7A           PLY 
C2/C899: C8           INY 
C2/C89A: C0 04 00     CPY #$0004
C2/C89D: D0 E8        BNE $C887
C2/C89F: 60           RTS 

; [ menu state $04:  ]

C2/C8A0: E2 20        SEP #$20
C2/C8A2: A9 0A        LDA #$0A
C2/C8A4: 20 BD CF     JSR $CFBD
C2/C8A7: 20 6C E7     JSR $E76C
C2/C8AA: 20 54 C9     JSR $C954
C2/C8AD: A4 80        LDY $80
C2/C8AF: B9 1A 05     LDA $051A,Y
C2/C8B2: 29 7F        AND #$7F
C2/C8B4: 00 F0        BRK $F0
C2/C8B6: 05 A9        ORA $A9
C2/C8B8: 28           PLP 
C2/C8B9: 3B           TSC 
C2/C8BA: 80 03        BRA $C8BF
C2/C8BC: A9 3C        LDA #$3C
C2/C8BE: 3B           TSC 
C2/C8BF: 20 DE C8     JSR $C8DE
C2/C8C2: A6 8E        LDX $8E
C2/C8C4: A4 80        LDY $80
C2/C8C6: DA           PHX 
C2/C8C7: 5A           PHY 
C2/C8C8: BF 4B EE C0  LDA $C0EE4B,X
C2/C8CC: AA           TAX 
C2/C8CD: B9 16 05     LDA $0516,Y
C2/C8D0: 20 E4 D8     JSR $D8E4
C2/C8D3: 7A           PLY 
C2/C8D4: FA           PLX 
C2/C8D5: C8           INY 
C2/C8D6: E8           INX 
C2/C8D7: E8           INX 
C2/C8D8: E0 08 00     CPX #$0008
C2/C8DB: D0 E9        BNE $C8C6
C2/C8DD: 60           RTS 

; [  ]

C2/C8DE: 8B           PHB 
C2/C8DF: 08           PHP 
C2/C8E0: C2 20        REP #$20
C2/C8E2: 48           PHA 
C2/C8E3: 20 B2 D0     JSR $D0B2
C2/C8E6: A5 7E        LDA $7E
C2/C8E8: 0A           ASL 
C2/C8E9: AA           TAX 
C2/C8EA: BF 08 EB C0  LDA $C0EB08,X
C2/C8EE: AA           TAX 
C2/C8EF: DA           PHX 
C2/C8F0: A0 48 03     LDY #$0348
C2/C8F3: A9 07 00     LDA #$0007
C2/C8F6: 54 7E 7E     MVN $7E,$7E
C2/C8F9: FA           PLX 
C2/C8FA: 9E 00 00     STZ $0000,X
C2/C8FD: 9E 02 00     STZ $0002,X
C2/C900: 9E 04 00     STZ $0004,X
C2/C903: 9E 06 00     STZ $0006,X
C2/C906: AD 48 03     LDA $0348
C2/C909: 18           CLC 
C2/C90A: 63 01        ADC $01,S
C2/C90C: 8D 48 03     STA $0348
C2/C90F: AD 4C 03     LDA $034C
C2/C912: 18           CLC 
C2/C913: 63 01        ADC $01,S
C2/C915: 8D 4C 03     STA $034C
C2/C918: 8A           TXA 
C2/C919: 38           SEC 
C2/C91A: E9 20 00     SBC #$0020
C2/C91D: AA           TAX 
C2/C91E: BD 02 00     LDA $0002,X
C2/C921: F0 1A        BEQ $C93D
C2/C923: DA           PHX 
C2/C924: A0 40 03     LDY #$0340
C2/C927: A9 03 00     LDA #$0003
C2/C92A: 54 7E 7E     MVN $7E,$7E
C2/C92D: FA           PLX 
C2/C92E: AD 40 03     LDA $0340
C2/C931: 18           CLC 
C2/C932: 63 01        ADC $01,S
C2/C934: 8D 40 03     STA $0340
C2/C937: 9E 00 00     STZ $0000,X
C2/C93A: 9E 02 00     STZ $0002,X
C2/C93D: 68           PLA 
C2/C93E: 28           PLP 
C2/C93F: AB           PLB 
C2/C940: 60           RTS 
C2/C941: 08           PHP 
C2/C942: A5 80        LDA $80
C2/C944: 18           CLC 
C2/C945: 69 00        ADC #$00
C2/C947: 05 AA        ORA $AA
C2/C949: A0 00 27     LDY #$2700
C2/C94C: A9 45        LDA #$45
C2/C94E: 00 54        BRK $54
C2/C950: 7E 7E 28     ROR $287E,X
C2/C953: 60           RTS 
C2/C954: 8B           PHB 
C2/C955: 08           PHP 
C2/C956: C2 20        REP #$20
C2/C958: A2 9D EF     LDX #$EF9D
C2/C95B: A9 17 00     LDA #$0017
C2/C95E: 20 9D DA     JSR $DA9D
C2/C961: A9 00 50     LDA #$5000
C2/C964: 8D BA 2B     STA $2BBA
C2/C967: 20 D7 DD     JSR $DDD7
C2/C96A: 20 41 C9     JSR $C941
C2/C96D: AD 02 27     LDA $2702
C2/C970: 29 FF 00     AND #$00FF
C2/C973: 48           PHA 
C2/C974: 0A           ASL 
C2/C975: 18           CLC 
C2/C976: 63 01        ADC $01,S
C2/C978: AA           TAX 
C2/C979: 68           PLA 
C2/C97A: AD 03 27     LDA $2703
C2/C97D: 8D 46 27     STA $2746
C2/C980: AD 05 27     LDA $2705
C2/C983: 29 FF 00     AND #$00FF
C2/C986: 8D 48 27     STA $2748
C2/C989: BF 00 50 D1  LDA $D15000,X
C2/C98D: 38           SEC 
C2/C98E: ED 46 27     SBC $2746
C2/C991: 8D 46 27     STA $2746
C2/C994: BF 02 50 D1  LDA $D15002,X
C2/C998: 29 FF 00     AND #$00FF
C2/C99B: ED 48 27     SBC $2748
C2/C99E: 8D 48 27     STA $2748
C2/C9A1: AD 02 27     LDA $2702
C2/C9A4: 29 FF 00     AND #$00FF
C2/C9A7: C9 63 00     CMP #$0063
C2/C9AA: 30 06        BMI $C9B2
C2/C9AC: 9C 46 27     STZ $2746
C2/C9AF: 9C 48 27     STZ $2748
C2/C9B2: A6 7E        LDX $7E
C2/C9B4: BD F3 08     LDA $08F3,X
C2/C9B7: 29 FF 00     AND #$00FF
C2/C9BA: 8D 4A 27     STA $274A
C2/C9BD: A6 8E        LDX $8E
C2/C9BF: DA           PHX 
C2/C9C0: BF 03 EE C0  LDA $C0EE03,X
C2/C9C4: A8           TAY 
C2/C9C5: BF 1B EE C0  LDA $C0EE1B,X
C2/C9C9: 48           PHA 
C2/C9CA: BF 33 EE C0  LDA $C0EE33,X
C2/C9CE: AA           TAX 
C2/C9CF: 68           PLA 
C2/C9D0: 20 ED E4     JSR $E4ED
C2/C9D3: FA           PLX 
C2/C9D4: E8           INX 
C2/C9D5: E8           INX 
C2/C9D6: E0 18 00     CPX #$0018
C2/C9D9: D0 E4        BNE $C9BF
C2/C9DB: AD 02 27     LDA $2702
C2/C9DE: 29 FF 00     AND #$00FF
C2/C9E1: C9 63 00     CMP #$0063
C2/C9E4: 30 0C        BMI $C9F2
C2/C9E6: A2 F5 ED     LDX #$EDF5
C2/C9E9: A0 10 55     LDY #$5510
C2/C9EC: A9 0D 00     LDA #$000D
C2/C9EF: 54 7E C0     MVN $7E,$C0
C2/C9F2: AD 15 27     LDA $2715
C2/C9F5: 29 FF 00     AND #$00FF
C2/C9F8: C9 FF 00     CMP #$00FF
C2/C9FB: F0 1B        BEQ $CA18
C2/C9FD: 48           PHA 
C2/C9FE: A9 95 B1     LDA #$B195
C2/CA01: 20 B8 C1     JSR $C1B8
C2/CA04: 68           PLA 
C2/CA05: 0A           ASL 
C2/CA06: 0A           ASL 
C2/CA07: 0A           ASL 
C2/CA08: 18           CLC 
C2/CA09: 69 00 5C     ADC #$5C00      ; D0/5C00 (monster names)
C2/CA0C: A8           TAY 
C2/CA0D: A2 C8 56     LDX #$56C8      ; copy 8 bytes to 7E/56C8
C2/CA10: A9 08 D0     LDA #$D008
C2/CA13: 20 9D E5     JSR $E59D
C2/CA16: 80 1C        BRA $CA34
C2/CA18: A9 85 B1     LDA #$B185
C2/CA1B: 20 B8 C1     JSR $C1B8
C2/CA1E: AD 40 27     LDA $2740
C2/CA21: 85 F9        STA $F9
C2/CA23: AD 42 27     LDA $2742
C2/CA26: 85 FB        STA $FB
C2/CA28: A0 86 56     LDY #$5686
C2/CA2B: 20 02 D8     JSR $D802
C2/CA2E: A0 C6 56     LDY #$56C6
C2/CA31: 20 F6 D7     JSR $D7F6
C2/CA34: 28           PLP 
C2/CA35: AB           PLB 
C2/CA36: 60           RTS 

; [ menu state $03:  ]

C2/CA37: A5 71        LDA $71
C2/CA39: 85 7E        STA $7E
C2/CA3B: 20 C5 D4     JSR $D4C5
C2/CA3E: 64 6F        STZ $6F
C2/CA40: 64 72        STZ $72
C2/CA42: E2 20        SEP #$20
C2/CA44: AD 12 2D     LDA $2D12
C2/CA47: 0D 11 2D     ORA $2D11
C2/CA4A: F0 0B        BEQ $CA57
C2/CA4C: AD 73 09     LDA $0973
C2/CA4F: 29 01        AND #$01
C2/CA51: D0 04        BNE $CA57
C2/CA53: A9 06        LDA #$06
C2/CA55: 80 02        BRA $CA59
C2/CA57: A9 05        LDA #$05
C2/CA59: 85 53        STA $53
C2/CA5B: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/CA5E: C2 20        REP #$20
C2/CA60: A9 36 B0     LDA #$B036
C2/CA63: 20 B8 C1     JSR $C1B8
C2/CA66: A9 98 1E     LDA #$1E98
C2/CA69: 20 DE C8     JSR $C8DE
C2/CA6C: A0 AC 51     LDY #$51AC
C2/CA6F: 20 33 D5     JSR $D533
C2/CA72: A0 2C 52     LDY #$522C
C2/CA75: 20 54 D5     JSR $D554
C2/CA78: 20 6C E7     JSR $E76C
C2/CA7B: 20 C8 CA     JSR $CAC8
C2/CA7E: 20 9E CC     JSR $CC9E
C2/CA81: A0 AE 52     LDY #$52AE
C2/CA84: 20 CA D7     JSR $D7CA
C2/CA87: C2 20        REP #$20
C2/CA89: 64 6B        STZ $6B
C2/CA8B: A9 F6 00     LDA #$00F6
C2/CA8E: 85 6D        STA $6D
C2/CA90: C2 20        REP #$20
C2/CA92: A2 D4 F2     LDX #$F2D4
C2/CA95: A0 8A 29     LDY #$298A
C2/CA98: A9 15 00     LDA #$0015
C2/CA9B: 54 7E C0     MVN $7E,$C0
C2/CA9E: A9 01 00     LDA #$0001
C2/CAA1: 8D B6 29     STA $29B6
C2/CAA4: 60           RTS 

; [  ]

C2/CAA5: 8B           PHB 
C2/CAA6: 08           PHP 
C2/CAA7: F4 7E 7E     PEA $7E7E
C2/CAAA: AB           PLB 
C2/CAAB: AB           PLB 
C2/CAAC: C2 20        REP #$20
C2/CAAE: A6 8E        LDX $8E
C2/CAB0: A9 C4 63     LDA #$63C4
C2/CAB3: 85 99        STA $99
C2/CAB5: DA           PHX 
C2/CAB6: A4 99        LDY $99
C2/CAB8: 20 8C CB     JSR $CB8C
C2/CABB: 20 E3 E3     JSR $E3E3
C2/CABE: FA           PLX 
C2/CABF: E8           INX 
C2/CAC0: E0 0A 00     CPX #$000A
C2/CAC3: D0 F0        BNE $CAB5
C2/CAC5: 28           PLP 
C2/CAC6: AB           PLB 
C2/CAC7: 60           RTS 

; [  ]

C2/CAC8: 8B           PHB 
C2/CAC9: 08           PHP 
C2/CACA: C2 20        REP #$20
C2/CACC: 9C DF 2C     STZ $2CDF
C2/CACF: 9C E1 2C     STZ $2CE1
C2/CAD2: A9 01 00     LDA #$0001
C2/CAD5: 8D E3 2C     STA $2CE3
C2/CAD8: A6 80        LDX $80
C2/CADA: E2 20        SEP #$20
C2/CADC: A4 8E        LDY $8E
C2/CADE: A9 20        LDA #$20
C2/CAE0: 3D 21 05     AND $0521,X
C2/CAE3: F0 06        BEQ $CAEB
C2/CAE5: A9 91        LDA #$91
C2/CAE7: 99 DF 2C     STA $2CDF,Y
C2/CAEA: C8           INY 
C2/CAEB: A9 01        LDA #$01
C2/CAED: 3D 21 05     AND $0521,X
C2/CAF0: F0 05        BEQ $CAF7
C2/CAF2: A9 92        LDA #$92
C2/CAF4: 99 DF 2C     STA $2CDF,Y
C2/CAF7: A6 80        LDX $80
C2/CAF9: BD 13 05     LDA $0513,X
C2/CAFC: D0 06        BNE $CB04
C2/CAFE: BD 11 05     LDA $0511,X
C2/CB01: 20 F1 CB     JSR $CBF1
C2/CB04: 85 F0        STA $F0
C2/CB06: BD 14 05     LDA $0514,X
C2/CB09: D0 06        BNE $CB11
C2/CB0B: BD 12 05     LDA $0512,X
C2/CB0E: 20 F1 CB     JSR $CBF1
C2/CB11: 85 F1        STA $F1
C2/CB13: BD 0E 05     LDA $050E,X
C2/CB16: 20 F1 CB     JSR $CBF1
C2/CB19: 85 F2        STA $F2
C2/CB1B: BD 0F 05     LDA $050F,X
C2/CB1E: 20 F1 CB     JSR $CBF1
C2/CB21: 85 F3        STA $F3
C2/CB23: BD 10 05     LDA $0510,X
C2/CB26: 20 F1 CB     JSR $CBF1
C2/CB29: 85 F4        STA $F4
C2/CB2B: A5 F0        LDA $F0
C2/CB2D: D0 06        BNE $CB35
C2/CB2F: A5 F1        LDA $F1
C2/CB31: F0 38        BEQ $CB6B
C2/CB33: 80 04        BRA $CB39
C2/CB35: A5 F1        LDA $F1
C2/CB37: D0 32        BNE $CB6B
C2/CB39: A5 F0        LDA $F0
C2/CB3B: 05 F1        ORA $F1
C2/CB3D: 20 AB D9     JSR $D9AB
C2/CB40: A5 9F        LDA $9F
C2/CB42: 89 80        BIT #$80
C2/CB44: D0 0D        BNE $CB53
C2/CB46: 89 40        BIT #$40
C2/CB48: F0 21        BEQ $CB6B
C2/CB4A: A6 80        LDX $80
C2/CB4C: BD 21 05     LDA $0521,X
C2/CB4F: 29 20        AND #$20
C2/CB51: F0 18        BEQ $CB6B
C2/CB53: A5 F0        LDA $F0
C2/CB55: F0 0A        BEQ $CB61
C2/CB57: A9 02        LDA #$02
C2/CB59: 8D E1 2C     STA $2CE1
C2/CB5C: EE E4 2C     INC $2CE4
C2/CB5F: 80 0A        BRA $CB6B
C2/CB61: A9 02        LDA #$02
C2/CB63: 8D E3 2C     STA $2CE3
C2/CB66: EE E2 2C     INC $2CE2
C2/CB69: 80 00        BRA $CB6B
C2/CB6B: C2 20        REP #$20
C2/CB6D: A6 8E        LDX $8E
C2/CB6F: A9 92 51     LDA #$5192
C2/CB72: 85 99        STA $99
C2/CB74: DA           PHX 
C2/CB75: A4 99        LDY $99
C2/CB77: 20 8C CB     JSR $CB8C
C2/CB7A: B5 F0        LDA $F0,X
C2/CB7C: 20 4E E4     JSR $E44E
C2/CB7F: FA           PLX 
C2/CB80: E8           INX 
C2/CB81: E0 05 00     CPX #$0005
C2/CB84: D0 EE        BNE $CB74
C2/CB86: 20 95 CB     JSR $CB95
C2/CB89: 28           PLP 
C2/CB8A: AB           PLB 
C2/CB8B: 60           RTS 

; [  ]

C2/CB8C: A5 99        LDA $99
C2/CB8E: 18           CLC 
C2/CB8F: 69 80        ADC #$80
C2/CB91: 00 85        BRK $85
C2/CB93: 99 60 C2     STA $C260,Y
C2/CB96: 20 AD DF     JSR $DFAD
C2/CB99: 2C 29 FF     BIT $FF29
C2/CB9C: 00 F0        BRK $F0
C2/CB9E: 06 A2        ASL $A2
C2/CBA0: 28           PLP 
C2/CBA1: 53 20        EOR ($20,S),Y
C2/CBA3: E1 CB        SBC ($CB,X)
C2/CBA5: AD E0 2C     LDA $2CE0
C2/CBA8: 29 FF        AND #$FF
C2/CBAA: 00 F0        BRK $F0
C2/CBAC: 06 A2        ASL $A2
C2/CBAE: A8           TAY 
C2/CBAF: 53 20        EOR ($20,S),Y
C2/CBB1: E1 CB        SBC ($CB,X)
C2/CBB3: A6 8E        LDX $8E
C2/CBB5: DA           PHX 
C2/CBB6: BF 44 EA C0  LDA $C0EA44,X
C2/CBBA: 85 E6        STA $E6
C2/CBBC: BD E1 2C     LDA $2CE1,X
C2/CBBF: 48           PHA 
C2/CBC0: 29 0F        AND #$0F
C2/CBC2: 00 0A        BRK $0A
C2/CBC4: AA           TAX 
C2/CBC5: BF 3E EA C0  LDA $C0EA3E,X
C2/CBC9: 20 B8 C1     JSR $C1B8
C2/CBCC: 68           PLA 
C2/CBCD: 29 00        AND #$00
C2/CBCF: FF 09 04 00  SBC $000409,X
C2/CBD3: A6 E6        LDX $E6
C2/CBD5: 20 DC D6     JSR $D6DC
C2/CBD8: FA           PLX 
C2/CBD9: E8           INX 
C2/CBDA: E8           INX 
C2/CBDB: E0 04 00     CPX #$0004
C2/CBDE: D0 D5        BNE $CBB5
C2/CBE0: 60           RTS 
C2/CBE1: DA           PHX 
C2/CBE2: 0A           ASL 
C2/CBE3: AA           TAX 
C2/CBE4: BF 00 D6 7E  LDA $7ED600,X
C2/CBE8: A8           TAY 
C2/CBE9: FA           PLX 
C2/CBEA: A9 08        LDA #$08
C2/CBEC: D1 20        CMP ($20),Y
C2/CBEE: 9D E5 60     STA $60E5,X
C2/CBF1: C9 80        CMP #$80
C2/CBF3: D0 02        BNE $CBF7
C2/CBF5: A9 00        LDA #$00
C2/CBF7: 60           RTS 
C2/CBF8: 8B           PHB 
C2/CBF9: 08           PHP 
C2/CBFA: A5 F1        LDA $F1
C2/CBFC: 8D 23 27     STA $2723
C2/CBFF: A5 F2        LDA $F2
C2/CC01: 8D 2C 27     STA $272C
C2/CC04: A5 F3        LDA $F3
C2/CC06: 8D 2D 27     STA $272D
C2/CC09: A5 F5        LDA $F5
C2/CC0B: 8D 2F 27     STA $272F
C2/CC0E: C2 20        REP #$20
C2/CC10: A5 EB        LDA $EB
C2/CC12: 8D 28 27     STA $2728
C2/CC15: A5 ED        LDA $ED
C2/CC17: 8D 2A 27     STA $272A
C2/CC1A: A5 F6        LDA $F6
C2/CC1C: 8D 44 27     STA $2744
C2/CC1F: A6 8E        LDX $8E
C2/CC21: DA           PHX 
C2/CC22: BF 09 EE C0  LDA $C0EE09,X
C2/CC26: 85 F6        STA $F6
C2/CC28: A8           TAY 
C2/CC29: BF BF ED C0  LDA $C0EDBF,X
C2/CC2D: 85 FE        STA $FE
C2/CC2F: BF 21 EE C0  LDA $C0EE21,X
C2/CC33: 85 F8        STA $F8
C2/CC35: 4A           LSR 
C2/CC36: 4A           LSR 
C2/CC37: 4A           LSR 
C2/CC38: 4A           LSR 
C2/CC39: 29 0F 00     AND #$000F
C2/CC3C: 85 FC        STA $FC
C2/CC3E: BF E3 ED C0  LDA $C0EDE3,X
C2/CC42: 85 FA        STA $FA
C2/CC44: AA           TAX 
C2/CC45: A5 F8        LDA $F8
C2/CC47: 20 ED E4     JSR $E4ED
C2/CC4A: A5 FE        LDA $FE
C2/CC4C: 18           CLC 
C2/CC4D: 65 80        ADC $80
C2/CC4F: AA           TAX 
C2/CC50: A3 01        LDA $01,S
C2/CC52: A8           TAY 
C2/CC53: BD 00 00     LDA $0000,X
C2/CC56: C0 08 00     CPY #$0008
C2/CC59: F0 03        BEQ $CC5E
C2/CC5B: 29 FF 00     AND #$00FF
C2/CC5E: 29 FF 01     AND #$01FF
C2/CC61: 85 FE        STA $FE
C2/CC63: A4 F6        LDY $F6
C2/CC65: A3 01        LDA $01,S
C2/CC67: AA           TAX 
C2/CC68: B9 00 00     LDA $0000,Y
C2/CC6B: E0 08 00     CPX #$0008
C2/CC6E: F0 03        BEQ $CC73
C2/CC70: 29 FF 00     AND #$00FF
C2/CC73: 29 FF 01     AND #$01FF
C2/CC76: C5 FE        CMP $FE
C2/CC78: F0 19        BEQ $CC93
C2/CC7A: 10 05        BPL $CC81
C2/CC7C: A9 00 81     LDA #$8100
C2/CC7F: 80 03        BRA $CC84
C2/CC81: A9 00 82     LDA #$8200
C2/CC84: E0 10 00     CPX #$0010
C2/CC87: D0 03        BNE $CC8C
C2/CC89: 49 00 03     EOR #$0300
C2/CC8C: 05 FC        ORA $FC
C2/CC8E: A6 FA        LDX $FA
C2/CC90: 20 DC D6     JSR $D6DC
C2/CC93: FA           PLX 
C2/CC94: E8           INX 
C2/CC95: E8           INX 
C2/CC96: E0 12 00     CPX #$0012
C2/CC99: D0 86        BNE $CC21
C2/CC9B: 28           PLP 
C2/CC9C: AB           PLB 
C2/CC9D: 60           RTS 
C2/CC9E: 8B           PHB 
C2/CC9F: 08           PHP 
C2/CCA0: F4 7E 7E     PEA $7E7E
C2/CCA3: AB           PLB 
C2/CCA4: AB           PLB 
C2/CCA5: C2 20        REP #$20
C2/CCA7: 20 41 C9     JSR $C941
C2/CCAA: A6 8E        LDX $8E
C2/CCAC: DA           PHX 
C2/CCAD: BF 09 EE C0  LDA $C0EE09,X
C2/CCB1: A8           TAY 
C2/CCB2: BF 21 EE C0  LDA $C0EE21,X
C2/CCB6: 48           PHA 
C2/CCB7: BF D1 ED C0  LDA $C0EDD1,X
C2/CCBB: AA           TAX 
C2/CCBC: 68           PLA 
C2/CCBD: 20 ED E4     JSR $E4ED
C2/CCC0: FA           PLX 
C2/CCC1: E8           INX 
C2/CCC2: E8           INX 
C2/CCC3: E0 12 00     CPX #$0012
C2/CCC6: D0 E4        BNE $CCAC
C2/CCC8: 28           PLP 
C2/CCC9: AB           PLB 
C2/CCCA: 60           RTS 

; [ menu state $02: job menu ]

C2/CCCB: 8B           PHB 
C2/CCCC: E2 20        SEP #$20
C2/CCCE: A9 06        LDA #$06
C2/CCD0: 20 BD CF     JSR $CFBD
C2/CCD3: 64 53        STZ $53
C2/CCD5: 20 10 D2     JSR $D210       ; init cursor ???
C2/CCD8: 64 6F        STZ $6F
C2/CCDA: 20 03 D5     JSR $D503
C2/CCDD: 20 64 E4     JSR $E464
C2/CCE0: 20 C6 CD     JSR $CDC6       ; update current character data
C2/CCE3: 20 88 D3     JSR $D388
C2/CCE6: 20 CC CE     JSR $CECC       ; get list of available jobs
C2/CCE9: 20 E3 CD     JSR $CDE3       ; update job sprites
C2/CCEC: 20 57 CD     JSR $CD57       ; update selected job palette
C2/CCEF: 8B           PHB 
C2/CCF0: A2 53 EE     LDX #$EE53
C2/CCF3: 20 FB D9     JSR $D9FB
C2/CCF6: AB           PLB 
C2/CCF7: 9C 11 2D     STZ $2D11
C2/CCFA: A2 5A E9     LDX #$E95A
C2/CCFD: 20 E9 C6     JSR $C6E9
C2/CD00: 20 D9 A9     JSR $A9D9
C2/CD03: 20 08 CD     JSR $CD08       ; update job name, level, and equipment
C2/CD06: AB           PLB 
C2/CD07: 60           RTS 

; [  ]

C2/CD08: 08           PHP 
C2/CD09: C2 20        REP #$20
C2/CD0B: A5 55        LDA $55
C2/CD0D: 29 FF 00     AND #$00FF
C2/CD10: 3A           DEC 
C2/CD11: AA           TAX 
C2/CD12: BD 00 7A     LDA $7A00,X
C2/CD15: 29 1F 00     AND #$001F
C2/CD18: E2 20        SEP #$20
C2/CD1A: 85 D8        STA $D8
C2/CD1C: 20 7D E4     JSR $E47D
C2/CD1F: C2 20        REP #$20
C2/CD21: A0 C4 65     LDY #$65C4
C2/CD24: A5 D8        LDA $D8
C2/CD26: 20 C7 E4     JSR $E4C7
C2/CD29: A0 D4 65     LDY #$65D4
C2/CD2C: 20 3F D9     JSR $D93F
C2/CD2F: A0 D6 65     LDY #$65D6
C2/CD32: 20 88 D5     JSR $D588
C2/CD35: A0 DA 65     LDY #$65DA
C2/CD38: 20 9D D5     JSR $D59D
C2/CD3B: A5 D8        LDA $D8
C2/CD3D: 29 1F 00     AND #$001F
C2/CD40: 0A           ASL 
C2/CD41: 0A           ASL 
C2/CD42: AA           TAX 
C2/CD43: BF 08 57 D1  LDA $D15708,X   ; job equipment types
C2/CD47: 85 F9        STA $F9
C2/CD49: BF 0A 57 D1  LDA $D1570A,X
C2/CD4D: 85 FB        STA $FB
C2/CD4F: A0 F2 65     LDY #$65F2
C2/CD52: 20 D8 D7     JSR $D7D8
C2/CD55: 28           PLP 
C2/CD56: 60           RTS 

; [ update selected job palette ]

C2/CD57: 08           PHP 
C2/CD58: C2 20        REP #$20
C2/CD5A: A5 55        LDA $55
C2/CD5C: 29 FF 00     AND #$00FF
C2/CD5F: 3A           DEC 
C2/CD60: A8           TAY 
C2/CD61: A6 80        LDX $80
C2/CD63: E2 20        SEP #$20
C2/CD65: B9 00 7A     LDA $7A00,Y
C2/CD68: 85 EB        STA $EB
C2/CD6A: BD 00 05     LDA $0500,X
C2/CD6D: 29 07        AND #$07
C2/CD6F: 85 EA        STA $EA
C2/CD71: C2 20        REP #$20
C2/CD73: A9 80 C1     LDA #$C180
C2/CD76: 85 E4        STA $E4
C2/CD78: 20 DB D2     JSR $D2DB
C2/CD7B: A9 0C 00     LDA #$000C
C2/CD7E: A2 31 ED     LDX #$ED31
C2/CD81: 20 04 D3     JSR $D304
C2/CD84: A2 53 EE     LDX #$EE53
C2/CD87: A0 14 75     LDY #$7514
C2/CD8A: A9 08 00     LDA #$0008
C2/CD8D: 54 7E C0     MVN $7E,$C0
C2/CD90: C2 20        REP #$20
C2/CD92: A5 EA        LDA $EA
C2/CD94: 29 07 1F     AND #$1F07
C2/CD97: A0 05 00     LDY #$0005
C2/CD9A: 20 92 D4     JSR $D492
C2/CD9D: A5 55        LDA $55
C2/CD9F: 29 FF 00     AND #$00FF
C2/CDA2: 3A           DEC 
C2/CDA3: 0A           ASL 
C2/CDA4: 0A           ASL 
C2/CDA5: A8           TAY 
C2/CDA6: 0A           ASL 
C2/CDA7: AA           TAX 
C2/CDA8: E2 20        SEP #$20
C2/CDAA: BD 93 02     LDA $0293,X
C2/CDAD: 29 F1        AND #$F1
C2/CDAF: 09 0A        ORA #$0A
C2/CDB1: 9D 93 02     STA $0293,X
C2/CDB4: 9D 97 02     STA $0297,X
C2/CDB7: B9 63 03     LDA $0363,Y
C2/CDBA: 29 F1        AND #$F1
C2/CDBC: 09 08        ORA #$08
C2/CDBE: 99 63 03     STA $0363,Y
C2/CDC1: 99 63 03     STA $0363,Y
C2/CDC4: 28           PLP 
C2/CDC5: 60           RTS 

; [ update current character data ]

C2/CDC6: 08           PHP 
C2/CDC7: C2 20        REP #$20
C2/CDC9: A2 C7 EF     LDX #$EFC7
C2/CDCC: A9 11 00     LDA #$0011
C2/CDCF: 20 9D DA     JSR $DA9D
C2/CDD2: A9 00 50     LDA #$5000
C2/CDD5: 8D BA 2B     STA $2BBA
C2/CDD8: 20 D7 DD     JSR $DDD7
C2/CDDB: A9 16 10     LDA #$1016
C2/CDDE: 20 DE C8     JSR $C8DE
C2/CDE1: 28           PLP 
C2/CDE2: 60           RTS 

; [ update job sprites ]

C2/CDE3: 8B           PHB 
C2/CDE4: 08           PHP 
C2/CDE5: F4 7E 7E     PEA $7E7E
C2/CDE8: AB           PLB 
C2/CDE9: AB           PLB 
C2/CDEA: C2 20        REP #$20
C2/CDEC: A5 80        LDA $80
C2/CDEE: 18           CLC 
C2/CDEF: 69 4A 05     ADC #$054A      ; job stat modifiers
C2/CDF2: A8           TAY 
C2/CDF3: A2 2B E9     LDX #$E92B      ; C0/E92B (default stat modifiers)
C2/CDF6: A9 05 00     LDA #$0005
C2/CDF9: 54 7E C0     MVN $7E,$C0     ; copy to ram
C2/CDFC: 64 85        STZ $85
C2/CDFE: 64 D8        STZ $D8
C2/CE00: A2 90 00     LDX #$0090      ; start at sprite 36
C2/CE03: 86 EC        STX $EC
C2/CE05: A4 8E        LDY $8E
C2/CE07: E2 20        SEP #$20
C2/CE09: B9 00 7A     LDA $7A00,Y
C2/CE0C: 30 4C        BMI $CE5A       ; branch if at end of available job list
C2/CE0E: C2 20        REP #$20
C2/CE10: 29 FF 00     AND #$00FF
C2/CE13: 85 D8        STA $D8         ; job index
C2/CE15: AA           TAX 
C2/CE16: BF 6A EE C0  LDA $C0EE6A,X   ; tile offset
C2/CE1A: 29 FF 00     AND #$00FF
C2/CE1D: 09 00 0D     ORA #$0D00      ; priority 0, palette 6, tile offset msb set
C2/CE20: 85 E2        STA $E2
C2/CE22: 18           CLC 
C2/CE23: 69 20 00     ADC #$0020
C2/CE26: 85 E6        STA $E6
C2/CE28: 98           TYA 
C2/CE29: 0A           ASL 
C2/CE2A: AA           TAX 
C2/CE2B: BF 82 EE C0  LDA $C0EE82,X   ; sprite xy position
C2/CE2F: 85 E0        STA $E0
C2/CE31: 18           CLC 
C2/CE32: 69 00 10     ADC #$1000
C2/CE35: 85 E4        STA $E4
C2/CE37: A6 EC        LDX $EC
C2/CE39: A5 E0        LDA $E0
C2/CE3B: 9D 00 02     STA $0200,X     ; top sprite
C2/CE3E: A5 E2        LDA $E2
C2/CE40: 9D 02 02     STA $0202,X
C2/CE43: A5 E4        LDA $E4
C2/CE45: 9D 04 02     STA $0204,X     ; bottom sprite
C2/CE48: A5 E6        LDA $E6
C2/CE4A: 9D 06 02     STA $0206,X
C2/CE4D: 8A           TXA 
C2/CE4E: 18           CLC 
C2/CE4F: 69 08 00     ADC #$0008
C2/CE52: 85 EC        STA $EC
C2/CE54: 20 5D CE     JSR $CE5D       ; update character sprite
C2/CE57: C8           INY 
C2/CE58: 80 AD        BRA $CE07       ; next job
C2/CE5A: 28           PLP 
C2/CE5B: AB           PLB 
C2/CE5C: 60           RTS 

; [ update character sprite ]

C2/CE5D: 20 7D E4     JSR $E47D       ; get character job data
C2/CE60: A6 D8        LDX $D8
C2/CE62: E0 15 00     CPX #$0015
C2/CE65: D0 09        BNE $CE70       ; branch if not freelancer
C2/CE67: A5 85        LDA $85
C2/CE69: C9 15 00     CMP #$0015
C2/CE6C: F0 0D        BEQ $CE7B
C2/CE6E: 80 2D        BRA $CE9D
C2/CE70: BF EA 52 D1  LDA $D152EA,X   ; number of abilities for each job
C2/CE74: 29 FF 00     AND #$00FF
C2/CE77: C5 DA        CMP $DA
C2/CE79: D0 22        BNE $CE9D
C2/CE7B: A9 04 0C     LDA #$0C04      ; xy position
C2/CE7E: 85 E2        STA $E2
C2/CE80: A5 E0        LDA $E0
C2/CE82: 38           SEC 
C2/CE83: E9 00 09     SBC #$0900      ; switch to palette 4
C2/CE86: 85 E0        STA $E0
C2/CE88: 98           TYA 
C2/CE89: 0A           ASL 
C2/CE8A: 0A           ASL 
C2/CE8B: AA           TAX 
C2/CE8C: A5 E0        LDA $E0
C2/CE8E: 9D 60 03     STA $0360,X
C2/CE91: A5 E2        LDA $E2
C2/CE93: 9D 62 03     STA $0362,X
C2/CE96: E6 85        INC $85
C2/CE98: 5A           PHY 
C2/CE99: 20 9E CE     JSR $CE9E       ; udpate job stats and abilities
C2/CE9C: 7A           PLY 
C2/CE9D: 60           RTS 

; [ update job stats and abilities ]

C2/CE9E: A5 D8        LDA $D8         ; job index
C2/CEA0: 29 1F 00     AND #$001F
C2/CEA3: 0A           ASL 
C2/CEA4: 0A           ASL 
C2/CEA5: AA           TAX 
C2/CEA6: A0 4A 05     LDY #$054A
C2/CEA9: E2 20        SEP #$20
C2/CEAB: BF B0 56 D1  LDA $D156B0,X   ; stat modifiers for each job
C2/CEAF: D1 80        CMP ($80),Y     ; compare to current stat modifier
C2/CEB1: 30 02        BMI $CEB5
C2/CEB3: 91 80        STA ($80),Y     ; set stat modifier if greater
C2/CEB5: E8           INX 
C2/CEB6: C8           INY 
C2/CEB7: C0 4E 05     CPY #$054E
C2/CEBA: D0 EF        BNE $CEAB
C2/CEBC: C2 20        REP #$20
C2/CEBE: A5 D8        LDA $D8
C2/CEC0: 20 16 E9     JSR $E916       ; get job innate abilities
C2/CEC3: A4 80        LDY $80
C2/CEC5: 19 4E 05     ORA $054E,Y
C2/CEC8: 99 4E 05     STA $054E,Y
C2/CECB: 60           RTS 

; [ get list of available jobs ]

C2/CECC: 8B           PHB 
C2/CECD: 08           PHP 
C2/CECE: E2 20        SEP #$20
C2/CED0: A2 00 01     LDX #$0100
C2/CED3: A9 FF        LDA #$FF
C2/CED5: 9D FF 79     STA $79FF,X
C2/CED8: CA           DEX 
C2/CED9: D0 FA        BNE $CED5
C2/CEDB: A6 8E        LDX $8E
C2/CEDD: A0 40 08     LDY #$0840      ; available jobs
C2/CEE0: A9 00        LDA #$00        ; start at 0
C2/CEE2: 85 E3        STA $E3
C2/CEE4: A9 16        LDA #$16        ; 22 jobs
C2/CEE6: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/CEE9: 28           PLP 
C2/CEEA: AB           PLB 
C2/CEEB: 60           RTS 

; [ menu state $01: ability menu ]

C2/CEEC: E2 20        SEP #$20
C2/CEEE: A9 04        LDA #$04
C2/CEF0: 20 BD CF     JSR $CFBD
C2/CEF3: A2 B5 EF     LDX #$EFB5
C2/CEF6: A9 11 00     LDA #$0011
C2/CEF9: 20 9D DA     JSR $DA9D
C2/CEFC: A9 00 50     LDA #$5000
C2/CEFF: 8D BA 2B     STA $2BBA
C2/CF02: 20 D7 DD     JSR $DDD7
C2/CF05: 20 A4 CF     JSR $CFA4
C2/CF08: A9 16 10     LDA #$1016
C2/CF0B: 20 DE C8     JSR $C8DE
C2/CF0E: A9 F3 08     LDA #$08F3      ; number of abilities
C2/CF11: 18           CLC 
C2/CF12: 65 7E        ADC $7E         ; character index
C2/CF14: A8           TAY 
C2/CF15: A2 F6 51     LDX #$51F6
C2/CF18: A9 31 00     LDA #$0031
C2/CF1B: 20 ED E4     JSR $E4ED       ; 
C2/CF1E: A5 7E        LDA $7E         ; character index
C2/CF20: 0A           ASL 
C2/CF21: AA           TAX 
C2/CF22: BF 3A F3 C0  LDA $C0F33A,X   ; pointer to character abilities
C2/CF26: AA           TAX 
C2/CF27: A4 80        LDY $80
C2/CF29: E2 20        SEP #$20
C2/CF2B: B9 01 05     LDA $0501,Y     ; job
C2/CF2E: C9 14        CMP #$14
C2/CF30: D0 07        BNE $CF39       ; branch if not mimic
C2/CF32: A9 48        LDA #$48        ; include fight and item
C2/CF34: 1D 00 00     ORA $0000,X
C2/CF37: 80 05        BRA $CF3E
C2/CF39: A9 B7        LDA #$B7        ; remove fight and item
C2/CF3B: 3D 00 00     AND $0000,X
C2/CF3E: 9D 00 00     STA $0000,X
C2/CF41: C2 20        REP #$20
C2/CF43: 64 6B        STZ $6B
C2/CF45: A9 40 00     LDA #$0040
C2/CF48: 85 6D        STA $6D
C2/CF4A: 20 51 D8     JSR $D851       ; get list of available abilities
C2/CF4D: 20 37 D8     JSR $D837
C2/CF50: A2 92 F2     LDX #$F292
C2/CF53: A0 8A 29     LDY #$298A
C2/CF56: A9 15 00     LDA #$0015
C2/CF59: 54 7E C0     MVN $7E,$C0
C2/CF5C: 9C B6 29     STZ $29B6
C2/CF5F: 20 67 E3     JSR $E367
C2/CF62: A6 80        LDX $80
C2/CF64: BD 01 05     LDA $0501,X
C2/CF67: 29 1F 00     AND #$001F
C2/CF6A: AA           TAX 
C2/CF6B: BF 61 ED C0  LDA $C0ED61,X   ; ability menu to use for each job
C2/CF6F: 29 FF 00     AND #$00FF
C2/CF72: 0A           ASL 
C2/CF73: 0A           ASL 
C2/CF74: AA           TAX 
C2/CF75: E2 20        SEP #$20
C2/CF77: BF 77 ED C0  LDA $C0ED77,X
C2/CF7B: 85 53        STA $53
C2/CF7D: C2 20        REP #$20
C2/CF7F: BF 78 ED C0  LDA $C0ED78,X
C2/CF83: 29 0F 00     AND #$000F
C2/CF86: 8D 63 2B     STA $2B63
C2/CF89: BF 79 ED C0  LDA $C0ED79,X
C2/CF8D: AA           TAX 
C2/CF8E: A0 5F 2B     LDY #$2B5F
C2/CF91: A9 03 00     LDA #$0003
C2/CF94: 54 7E C0     MVN $7E,$C0
C2/CF97: 20 10 D2     JSR $D210
C2/CF9A: 20 17 D7     JSR $D717
C2/CF9D: A2 60 E9     LDX #$E960
C2/CFA0: 20 E9 C6     JSR $C6E9
C2/CFA3: 60           RTS 

; [  ]

C2/CFA4: 8B           PHB 
C2/CFA5: 08           PHP 
C2/CFA6: C2 20        REP #$20
C2/CFA8: A2 5C EE     LDX #$EE5C
C2/CFAB: A0 D2 51     LDY #$51D2
C2/CFAE: A9 0D 00     LDA #$000D
C2/CFB1: 54 7E C0     MVN $7E,$C0
C2/CFB4: A0 D2 51     LDY #$51D2
C2/CFB7: 20 CA D7     JSR $D7CA
C2/CFBA: 28           PLP 
C2/CFBB: AB           PLB 
C2/CFBC: 60           RTS 

; [  ]

C2/CFBD: E2 20        SEP #$20
C2/CFBF: 85 54        STA $54
C2/CFC1: 20 7C E6     JSR $E67C
C2/CFC4: 20 10 D2     JSR $D210
C2/CFC7: C2 20        REP #$20
C2/CFC9: A5 8E        LDA $8E
C2/CFCB: 8D 04 02     STA $0204
C2/CFCE: 8D 06 02     STA $0206
C2/CFD1: A5 71        LDA $71
C2/CFD3: 29 FF 00     AND #$00FF
C2/CFD6: 85 7E        STA $7E
C2/CFD8: 20 C5 D4     JSR $D4C5
C2/CFDB: 60           RTS 

; [ menu state $00: main menu ]

C2/CFDC: 20 30 D2     JSR $D230
C2/CFDF: 20 DB D3     JSR $D3DB
C2/CFE2: A2 94 F3     LDX #$F394
C2/CFE5: 20 4C D0     JSR $D04C
C2/CFE8: 20 DB D4     JSR $D4DB
C2/CFEB: A2 EE 66     LDX #$66EE
C2/CFEE: 20 58 D6     JSR $D658
C2/CFF1: A2 30 66     LDX #$6630
C2/CFF4: A0 4A 09     LDY #$094A
C2/CFF7: 20 62 D6     JSR $D662
C2/CFFA: A5 44        LDA $44
C2/CFFC: 29 80 00     AND #$0080
C2/CFFF: D0 09        BNE $D00A
C2/D001: A2 F2 64     LDX #$64F2
C2/D004: A9 03 01     LDA #$0103
C2/D007: 20 DC D6     JSR $D6DC
C2/D00A: F4 7E 7E     PEA $7E7E
C2/D00D: AB           PLB 
C2/D00E: AB           PLB 
C2/D00F: AD 40 08     LDA $0840       ; available jobs
C2/D012: D0 11        BNE $D025
C2/D014: AD 42 08     LDA $0842
C2/D017: 29 F8 00     AND #$00F8
C2/D01A: D0 09        BNE $D025
C2/D01C: A2 F2 60     LDX #$60F2
C2/D01F: A9 03 01     LDA #$0103
C2/D022: 20 DC D6     JSR $D6DC
C2/D025: AD F3 08     LDA $08F3       ; number of abilities
C2/D028: 0D F5 08     ORA $08F5
C2/D02B: D0 09        BNE $D036
C2/D02D: A2 72 61     LDX #$6172
C2/D030: A9 05 01     LDA #$0105
C2/D033: 20 DC D6     JSR $D6DC
C2/D036: 9C 04 02     STZ $0204
C2/D039: 9C 06 02     STZ $0206
C2/D03C: 9C 11 2D     STZ $2D11
C2/D03F: E2 20        SEP #$20
C2/D041: A9 01        LDA #$01
C2/D043: 85 54        STA $54
C2/D045: 20 7C E6     JSR $E67C
C2/D048: 20 10 D2     JSR $D210
C2/D04B: 60           RTS 

; [  ]

C2/D04C: 8B           PHB 
C2/D04D: F4 7E 7E     PEA $7E7E
C2/D050: AB           PLB 
C2/D051: AB           PLB 
C2/D052: E2 20        SEP #$20
C2/D054: A9 C0        LDA #$C0
C2/D056: 86 82        STX $82
C2/D058: 85 84        STA $84
C2/D05A: C2 20        REP #$20
C2/D05C: 64 7E        STZ $7E
C2/D05E: E2 20        SEP #$20
C2/D060: 20 C5 D4     JSR $D4C5
C2/D063: A6 80        LDX $80
C2/D065: 3C 00 05     BIT $0500,X
C2/D068: 70 3B        BVS $D0A5
C2/D06A: 20 B2 D0     JSR $D0B2
C2/D06D: C2 20        REP #$20
C2/D06F: A5 7E        LDA $7E
C2/D071: 0A           ASL 
C2/D072: 0A           ASL 
C2/D073: 0A           ASL 
C2/D074: A8           TAY 
C2/D075: 4A           LSR 
C2/D076: A6 80        LDX $80
C2/D078: E2 20        SEP #$20
C2/D07A: 3C 00 05     BIT $0500,X
C2/D07D: C2 20        REP #$20
C2/D07F: 10 02        BPL $D083
C2/D081: 1A           INC 
C2/D082: 1A           INC 
C2/D083: BB           TYX 
C2/D084: A8           TAY 
C2/D085: B7 82        LDA [$82],Y
C2/D087: 18           CLC 
C2/D088: 7D 40 02     ADC $0240,X
C2/D08B: 9D 40 02     STA $0240,X
C2/D08E: B7 82        LDA [$82],Y
C2/D090: 18           CLC 
C2/D091: 7D 44 02     ADC $0244,X
C2/D094: 9D 44 02     STA $0244,X
C2/D097: BD 22 02     LDA $0222,X
C2/D09A: F0 09        BEQ $D0A5
C2/D09C: B7 82        LDA [$82],Y
C2/D09E: 18           CLC 
C2/D09F: 7D 20 02     ADC $0220,X
C2/D0A2: 9D 20 02     STA $0220,X
C2/D0A5: C2 20        REP #$20
C2/D0A7: E6 7E        INC $7E
C2/D0A9: A5 7E        LDA $7E
C2/D0AB: C9 04 00     CMP #$0004
C2/D0AE: D0 AE        BNE $D05E
C2/D0B0: AB           PLB 
C2/D0B1: 60           RTS 
C2/D0B2: 8B           PHB 
C2/D0B3: 08           PHP 
C2/D0B4: 20 C5 D4     JSR $D4C5
C2/D0B7: A6 80        LDX $80
C2/D0B9: E2 20        SEP #$20
C2/D0BB: A9 7E        LDA #$7E
C2/D0BD: 48           PHA 
C2/D0BE: AB           PLB 
C2/D0BF: BD 1A 05     LDA $051A,X
C2/D0C2: 85 E8        STA $E8
C2/D0C4: BD 00 05     LDA $0500,X
C2/D0C7: 85 EA        STA $EA
C2/D0C9: BD 01 05     LDA $0501,X
C2/D0CC: 85 EB        STA $EB
C2/D0CE: A6 8E        LDX $8E
C2/D0D0: A5 E8        LDA $E8
C2/D0D2: 10 01        BPL $D0D5
C2/D0D4: E8           INX 
C2/D0D5: 29 30        AND #$30
C2/D0D7: F0 02        BEQ $D0DB
C2/D0D9: E8           INX 
C2/D0DA: E8           INX 
C2/D0DB: C2 20        REP #$20
C2/D0DD: 8A           TXA 
C2/D0DE: 0A           ASL 
C2/D0DF: 0A           ASL 
C2/D0E0: AA           TAX 
C2/D0E1: BF C8 EA C0  LDA $C0EAC8,X
C2/D0E5: 85 E0        STA $E0
C2/D0E7: BF CA EA C0  LDA $C0EACA,X
C2/D0EB: 85 E4        STA $E4
C2/D0ED: A6 7E        LDX $7E
C2/D0EF: E2 20        SEP #$20
C2/D0F1: A5 E8        LDA $E8
C2/D0F3: 29 30        AND #$30
C2/D0F5: F0 08        BEQ $D0FF
C2/D0F7: A2 04 00     LDX #$0004
C2/D0FA: 29 20        AND #$20
C2/D0FC: F0 01        BEQ $D0FF
C2/D0FE: E8           INX 
C2/D0FF: C2 20        REP #$20
C2/D101: 8A           TXA 
C2/D102: 0A           ASL 
C2/D103: 0A           ASL 
C2/D104: 0A           ASL 
C2/D105: AA           TAX 
C2/D106: E2 20        SEP #$20
C2/D108: A5 E8        LDA $E8
C2/D10A: F0 0E        BEQ $D11A
C2/D10C: 30 06        BMI $D114
C2/D10E: 29 45        AND #$45
C2/D110: D0 04        BNE $D116
C2/D112: 80 06        BRA $D11A
C2/D114: E8           INX 
C2/D115: E8           INX 
C2/D116: E8           INX 
C2/D117: E8           INX 
C2/D118: E8           INX 
C2/D119: E8           INX 
C2/D11A: BF D8 EA C0  LDA $C0EAD8,X
C2/D11E: 85 E2        STA $E2
C2/D120: BF D9 EA C0  LDA $C0EAD9,X
C2/D124: 85 E6        STA $E6
C2/D126: 20 5F D4     JSR $D45F
C2/D129: A5 7E        LDA $7E
C2/D12B: 0A           ASL 
C2/D12C: 29 0E        AND #$0E
C2/D12E: 85 E3        STA $E3
C2/D130: 85 E7        STA $E7
C2/D132: C2 20        REP #$20
C2/D134: A5 7E        LDA $7E
C2/D136: 0A           ASL 
C2/D137: AA           TAX 
C2/D138: BF 08 EB C0  LDA $C0EB08,X
C2/D13C: A8           TAY 
C2/D13D: A2 E0 01     LDX #$01E0
C2/D140: A9 07 00     LDA #$0007
C2/D143: 54 7E 00     MVN $7E,$00
C2/D146: A5 7E        LDA $7E
C2/D148: 0A           ASL 
C2/D149: AA           TAX 
C2/D14A: BF 3E F2 C0  LDA $C0F23E,X
C2/D14E: A8           TAY 
C2/D14F: E2 20        SEP #$20
C2/D151: A9 04        LDA #$04
C2/D153: 25 E8        AND $E8
C2/D155: F0 10        BEQ $D167
C2/D157: C2 20        REP #$20
C2/D159: A9 DB 7E     LDA #$7EDB
C2/D15C: 99 08 00     STA $0008,Y
C2/D15F: A9 D3 4D     LDA #$4DD3
C2/D162: 99 10 00     STA $0010,Y
C2/D165: E2 20        SEP #$20
C2/D167: A9 02        LDA #$02
C2/D169: 25 E8        AND $E8
C2/D16B: F0 14        BEQ $D181
C2/D16D: C2 20        REP #$20
C2/D16F: A9 F5 3A     LDA #$3AF5
C2/D172: 99 08 00     STA $0008,Y
C2/D175: A9 10 32     LDA #$3210
C2/D178: 99 10 00     STA $0010,Y
C2/D17B: A9 FF 7F     LDA #$7FFF
C2/D17E: 99 06 00     STA $0006,Y
C2/D181: C2 20        REP #$20
C2/D183: 64 E2        STZ $E2
C2/D185: E2 20        SEP #$20
C2/D187: A5 E8        LDA $E8
C2/D189: 89 01        BIT #$01
C2/D18B: F0 64        BEQ $D1F1
C2/D18D: 89 A0        BIT #$A0
C2/D18F: D0 60        BNE $D1F1
C2/D191: 89 10        BIT #$10
C2/D193: C2 20        REP #$20
C2/D195: F0 07        BEQ $D19E
C2/D197: A2 0A 00     LDX #$000A
C2/D19A: A5 8E        LDA $8E
C2/D19C: 80 0D        BRA $D1AB
C2/D19E: A5 EA        LDA $EA
C2/D1A0: 29 07 00     AND #$0007
C2/D1A3: 0A           ASL 
C2/D1A4: AA           TAX 
C2/D1A5: A5 EB        LDA $EB
C2/D1A7: 29 FF 00     AND #$00FF
C2/D1AA: 0A           ASL 
C2/D1AB: 18           CLC 
C2/D1AC: 7F 10 EB C0  ADC $C0EB10,X
C2/D1B0: AA           TAX 
C2/D1B1: E2 20        SEP #$20
C2/D1B3: BF 1C EB C0  LDA $C0EB1C,X
C2/D1B7: 18           CLC 
C2/D1B8: 65 E0        ADC $E0
C2/D1BA: 85 E0        STA $E0
C2/D1BC: BF 1D EB C0  LDA $C0EB1D,X
C2/D1C0: 18           CLC 
C2/D1C1: 65 E1        ADC $E1
C2/D1C3: 85 E1        STA $E1
C2/D1C5: A5 EA        LDA $EA
C2/D1C7: 29 07        AND #$07
C2/D1C9: F0 0E        BEQ $D1D9
C2/D1CB: C9 01        CMP #$01
C2/D1CD: D0 1B        BNE $D1EA
C2/D1CF: A5 EB        LDA $EB
C2/D1D1: 29 1F        AND #$1F
C2/D1D3: C9 0A        CMP #$0A
C2/D1D5: F0 0E        BEQ $D1E5
C2/D1D7: 80 11        BRA $D1EA
C2/D1D9: A5 EB        LDA $EB
C2/D1DB: 29 1F        AND #$1F
C2/D1DD: C9 04        CMP #$04
C2/D1DF: F0 04        BEQ $D1E5
C2/D1E1: C9 0A        CMP #$0A
C2/D1E3: D0 05        BNE $D1EA
C2/D1E5: A2 20 4E     LDX #$4E20
C2/D1E8: 80 03        BRA $D1ED
C2/D1EA: A2 20 0E     LDX #$0E20
C2/D1ED: 86 E2        STX $E2
C2/D1EF: 80 04        BRA $D1F5
C2/D1F1: 64 E0        STZ $E0
C2/D1F3: 64 E1        STZ $E1
C2/D1F5: C2 20        REP #$20
C2/D1F7: A5 7E        LDA $7E
C2/D1F9: 0A           ASL 
C2/D1FA: AA           TAX 
C2/D1FB: BF 08 EB C0  LDA $C0EB08,X
C2/D1FF: 38           SEC 
C2/D200: E9 20 00     SBC #$0020
C2/D203: A8           TAY 
C2/D204: A2 E0 01     LDX #$01E0
C2/D207: A9 03 00     LDA #$0003
C2/D20A: 54 00 00     MVN $00,$00
C2/D20D: 28           PLP 
C2/D20E: AB           PLB 
C2/D20F: 60           RTS 

; [ init cursor ??? ]

C2/D210: 08           PHP 
C2/D211: E2 20        SEP #$20
C2/D213: 20 AB E6     JSR $E6AB       ; update cursor sprite
C2/D216: A9 01        LDA #$01
C2/D218: 14 CA        TRB $CA
C2/D21A: A5 53        LDA $53
C2/D21C: 85 50        STA $50
C2/D21E: A5 55        LDA $55
C2/D220: 85 52        STA $52
C2/D222: A5 54        LDA $54
C2/D224: 85 51        STA $51
C2/D226: 64 4F        STZ $4F
C2/D228: 64 56        STZ $56
C2/D22A: 64 57        STZ $57
C2/D22C: 64 58        STZ $58
C2/D22E: 28           PLP 
C2/D22F: 60           RTS 

; [  ]

C2/D230: 8B           PHB 
C2/D231: 08           PHP 
C2/D232: C2 20        REP #$20
C2/D234: A2 00 20     LDX #$2000
C2/D237: A5 8E        LDA $8E
C2/D239: CA           DEX 
C2/D23A: CA           DEX 
C2/D23B: 9E 00 90     STZ $9000,X
C2/D23E: D0 F9        BNE $D239
C2/D240: 64 7E        STZ $7E
C2/D242: 20 98 D2     JSR $D298
C2/D245: A5 7E        LDA $7E
C2/D247: 1A           INC 
C2/D248: 85 7E        STA $7E
C2/D24A: C9 04 00     CMP #$0004
C2/D24D: D0 F3        BNE $D242
C2/D24F: 20 5B D2     JSR $D25B
C2/D252: A2 EB EF     LDX #$EFEB
C2/D255: 20 FB D9     JSR $D9FB
C2/D258: 28           PLP 
C2/D259: AB           PLB 
C2/D25A: 60           RTS 

C2/D25B: A6 8E        LDX $8E
C2/D25D: DA           PHX 
C2/D25E: BF C3 EC C0  LDA $C0ECC3,X
C2/D262: 85 E0        STA $E0
C2/D264: BF C5 EC C0  LDA $C0ECC5,X
C2/D268: 85 E2        STA $E2
C2/D26A: BF C7 EC C0  LDA $C0ECC7,X
C2/D26E: 85 E4        STA $E4
C2/D270: BF C9 EC C0  LDA $C0ECC9,X
C2/D274: 48           PHA 
C2/D275: BF CB EC C0  LDA $C0ECCB,X
C2/D279: FA           PLX 
C2/D27A: 20 04 D3     JSR $D304
C2/D27D: 68           PLA 
C2/D27E: 18           CLC 
C2/D27F: 69 0A 00     ADC #$000A
C2/D282: AA           TAX 
C2/D283: E0 1E 00     CPX #$001E
C2/D286: D0 D5        BNE $D25D
C2/D288: 20 4C D3     JSR $D34C
C2/D28B: A2 A0 B9     LDX #$B9A0
C2/D28E: A0 80 90     LDY #$9080
C2/D291: A9 3F 00     LDA #$003F
C2/D294: 54 7E C3     MVN $7E,$C3
C2/D297: 60           RTS 

C2/D298: 8B           PHB 
C2/D299: 08           PHP 
C2/D29A: A5 7E        LDA $7E
C2/D29C: 0A           ASL 
C2/D29D: AA           TAX 
C2/D29E: BF 1B EC C0  LDA $C0EC1B,X
C2/D2A2: 85 E4        STA $E4
C2/D2A4: 20 C5 D4     JSR $D4C5
C2/D2A7: A6 80        LDX $80
C2/D2A9: BF 00 05 00  LDA $000500,X
C2/D2AD: 85 EA        STA $EA
C2/D2AF: 20 DB D2     JSR $D2DB
C2/D2B2: A9 18 00     LDA #$0018
C2/D2B5: A2 37 EC     LDX #$EC37
C2/D2B8: 20 04 D3     JSR $D304
C2/D2BB: A5 EA        LDA $EA
C2/D2BD: 29 07 00     AND #$0007
C2/D2C0: 0A           ASL 
C2/D2C1: 0A           ASL 
C2/D2C2: AA           TAX 
C2/D2C3: BF 97 EC C0  LDA $C0EC97,X
C2/D2C7: 85 E0        STA $E0
C2/D2C9: BF 99 EC C0  LDA $C0EC99,X
C2/D2CD: 85 E2        STA $E2
C2/D2CF: A9 06 00     LDA #$0006
C2/D2D2: A2 AB EC     LDX #$ECAB
C2/D2D5: 20 04 D3     JSR $D304
C2/D2D8: 28           PLP 
C2/D2D9: AB           PLB 
C2/D2DA: 60           RTS 

C2/D2DB: 08           PHP 
C2/D2DC: C2 20        REP #$20
C2/D2DE: A5 EB        LDA $EB
C2/D2E0: 29 1F 00     AND #$001F
C2/D2E3: 0A           ASL 
C2/D2E4: 48           PHA 
C2/D2E5: 0A           ASL 
C2/D2E6: 63 01        ADC $01,S
C2/D2E8: EB           XBA 
C2/D2E9: 83 01        STA $01,S
C2/D2EB: A5 EA        LDA $EA
C2/D2ED: 29 07 00     AND #$0007
C2/D2F0: 0A           ASL 
C2/D2F1: 0A           ASL 
C2/D2F2: AA           TAX 
C2/D2F3: 68           PLA 
C2/D2F4: 7F 23 EC C0  ADC $C0EC23,X
C2/D2F8: 85 E0        STA $E0
C2/D2FA: A5 8E        LDA $8E
C2/D2FC: 7F 25 EC C0  ADC $C0EC25,X
C2/D300: 85 E2        STA $E2
C2/D302: 28           PLP 
C2/D303: 60           RTS 

C2/D304: 8B           PHB 
C2/D305: 08           PHP 
C2/D306: 85 E8        STA $E8
C2/D308: DA           PHX 
C2/D309: A5 E4        LDA $E4
C2/D30B: 18           CLC 
C2/D30C: 7F 02 00 C0  ADC $C00002,X
C2/D310: A8           TAY 
C2/D311: A5 E0        LDA $E0
C2/D313: 18           CLC 
C2/D314: 7F 00 00 C0  ADC $C00000,X
C2/D318: AA           TAX 
C2/D319: A5 E2        LDA $E2
C2/D31B: 65 8E        ADC $8E
C2/D31D: 29 FF 00     AND #$00FF
C2/D320: C9 D4 00     CMP #$00D4
C2/D323: F0 15        BEQ $D33A
C2/D325: C9 D3 00     CMP #$00D3
C2/D328: F0 08        BEQ $D332
C2/D32A: A9 1F 00     LDA #$001F
C2/D32D: 54 7E D2     MVN $7E,$D2
C2/D330: 80 0E        BRA $D340
C2/D332: A9 1F 00     LDA #$001F
C2/D334: 54 7E D3     MVN $7E,$D3
C2/D337: 80 06        BRA $D33E
C2/D339: A9 1F 00     LDA #$001F
C2/D33B: 54 7E D4     MVN $7E,$D4
C2/D33E: FA           PLX 
C2/D341: E8           INX 
C2/D342: E8           INX 
C2/D343: E8           INX 
C2/D344: E8           INX 
C2/D345: C6 E8        DEC $E8
C2/D347: D0 BF        BNE $D308
C2/D349: 28           PLP 
C2/D34A: AB           PLB 
C2/D34B: 60           RTS 

C2/D34C: A6 8E        LDX $8E
C2/D34E: DA           PHX 
C2/D34F: 8A           TXA 
C2/D350: 18           CLC 
C2/D351: 69 17 00     ADC #$0017
C2/D354: AA           TAX 
C2/D355: 18           CLC 
C2/D356: 69 07 00     ADC #$0007
C2/D359: A8           TAY
C2/D35A: A9 08 00     LDA #$0008
C2/D35D: 85 85        STA $85
C2/D35F: BD 00 90     LDA $9000,X
C2/D362: 29 FF 00     AND #$00FF
C2/D365: 99 00 90     STA $9000,Y
C2/D368: CA           DEX 
C2/D369: 88           DEY 
C2/D36A: 88           DEY 
C2/D36B: C6 85        DEC $85
C2/D36D: D0 F0        BNE $D35F
C2/D36F: 68           PLA 
C2/D370: 18           CLC 
C2/D371: 69 20 00     ADC #$0020
C2/D374: AA           TAX 
C2/D375: C9 00        CMP #$00
C2/D377: 08           PHP 
C2/D378: D0 D4        BNE $D34E
C2/D37A: 60           RTS 

C2/D37B: 8B           PHB 
C2/D37C: 08           PHP 
C2/D37D: C2 20        REP #$20
C2/D37F: A2 E2 EF     LDX #$EFE2
C2/D382: 20 FB D9     JSR $D9FB
C2/D385: 28           PLP 
C2/D386: AB           PLB 
C2/D387: 60           RTS 

; [  ]

C2/D388: 8B           PHB 
C2/D389: 08           PHP 
C2/D38A: C2 20        REP #$20
C2/D38C: A2 00 18     LDX #$1800
C2/D38F: 9E FE AF     STZ $AFFE,X
C2/D392: CA           DEX 
C2/D393: CA           DEX 
C2/D394: D0 F9        BNE $D38F
C2/D396: A6 80        LDX $80
C2/D398: BD 00 05     LDA $0500,X
C2/D39B: 29 07 00     AND #$0007
C2/D39E: 85 EA        STA $EA
C2/D3A0: A0 16 00     LDY #$0016
C2/D3A3: C2 20        REP #$20
C2/D3A5: A5 EB        LDA $EB
C2/D3A7: 29 18 00     AND #$0018
C2/D3AA: 0A           ASL 
C2/D3AB: 0A           ASL 
C2/D3AC: 05 EB        ORA $EB
C2/D3AE: 29 67 00     AND #$0067
C2/D3B1: 0A           ASL 
C2/D3B2: EB           XBA 
C2/D3B3: 4A           LSR 
C2/D3B4: 4A           LSR 
C2/D3B5: 4A           LSR 
C2/D3B6: 69 00 B0     ADC #$B000
C2/D3B9: 85 E4        STA $E4
C2/D3BB: 5A           PHY 
C2/D3BC: 20 DB D2     JSR $D2DB
C2/D3BF: A9 06 00     LDA #$0006
C2/D3C2: A2 31 ED     LDX #$ED31
C2/D3C5: 20 04 D3     JSR $D304
C2/D3C8: 7A           PLY 
C2/D3C9: E2 20        SEP #$20
C2/D3CB: E6 EB        INC $EB
C2/D3CD: 88           DEY 
C2/D3CE: D0 D3        BNE $D3A3
C2/D3D0: C2 20        REP #$20
C2/D3D2: A2 D9 EF     LDX #$EFD9
C2/D3D5: 20 FB D9     JSR $D9FB
C2/D3D8: 28           PLP 
C2/D3D9: AB           PLB 
C2/D3DA: 60           RTS 

; [  ]

C2/D3DB: 8B           PHB 
C2/D3DC: 08           PHP 
C2/D3DD: C2 20        REP #$20
C2/D3DF: 64 7E        STZ $7E
C2/D3E1: 20 5F D4     JSR $D45F
C2/D3E4: A5 7E        LDA $7E
C2/D3E6: 1A           INC 
C2/D3E7: 85 7E        STA $7E
C2/D3E9: C9 04 00     CMP #$0004
C2/D3EC: D0 F3        BNE $D3E1
C2/D3EE: A2 E0 B9     LDX #$B9E0
C2/D3F1: A0 80 74     LDY #$7480
C2/D3F4: A9 1F 00     LDA #$001F
C2/D3F7: 54 7E C3     MVN $7E,$C3
C2/D3FA: A2 67 F8     LDX #$F867
C2/D3FD: A0 C0 74     LDY #$74C0
C2/D400: A9 1F 00     LDA #$001F
C2/D403: 54 7E C0     MVN $7E,$C0
C2/D406: A2 60 B9     LDX #$B960
C2/D409: A0 E0 74     LDY #$74E0
C2/D40C: A9 1F 00     LDA #$001F
C2/D40F: 54 7E C3     MVN $7E,$C3
C2/D412: 20 2E D4     JSR $D42E
C2/D415: A2 F4 EF     LDX #$EFF4
C2/D418: A0 00 43     LDY #$4300
C2/D41B: A9 06 00     LDA #$0006
C2/D41E: 54 00 C0     MVN $00,$C0
C2/D421: E2 20        SEP #$20
C2/D423: 9C 21 21     STZ $2121
C2/D426: A9 01        LDA #$01
C2/D428: 8D 0B 42     STA $420B
C2/D42B: 28           PLP 
C2/D42C: AB           PLB 
C2/D42D: 60           RTS 
C2/D42E: A9 04        LDA #$04
C2/D430: 00 85        BRK $85
C2/D432: E8           INX 
C2/D433: A0 00 73     LDY #$7300
C2/D436: A2 27 F8     LDX #$F827
C2/D439: A9 3F        LDA #$3F
C2/D43B: 00 54        BRK $54
C2/D43D: 7E C0 C6     ROR $C6C0,X
C2/D440: E8           INX 
C2/D441: D0 F3        BNE $D436
C2/D443: 20 47 D4     JSR $D447       ; update window color
C2/D446: 60           RTS 

; [ update window color ]

C2/D447: 08           PHP 
C2/D448: C2 20        REP #$20
C2/D44A: A4 8E        LDY $8E
C2/D44C: AD 71 09     LDA $0971       ; window color
C2/D44F: 99 02 73     STA $7302,Y
C2/D452: 98           TYA 
C2/D453: 18           CLC 
C2/D454: 69 08 00     ADC #$0008
C2/D457: A8           TAY 
C2/D458: C9 00 01     CMP #$0100
C2/D45B: D0 EF        BNE $D44C
C2/D45D: 28           PLP 
C2/D45E: 60           RTS 

C2/D45F: 8B           PHB 
C2/D460: 08           PHP 
C2/D461: E2 20        SEP #$20
C2/D463: 20 C5 D4     JSR $D4C5
C2/D466: A6 80        LDX $80
C2/D468: BD 00 05     LDA $0500,X
C2/D46B: 29 07        AND #$07
C2/D46D: EB           XBA 
C2/D46E: BD 01 05     LDA $0501,X
C2/D471: 29 1F        AND #$1F
C2/D473: A4 7E        LDY $7E
C2/D475: 3C 1A 05     BIT $051A,X
C2/D478: 70 0A        BVS $D484
C2/D47A: 10 02        BPL $D47E
C2/D47C: A9 15        LDA #$15
C2/D47E: EB           XBA 
C2/D47F: 20 92 D4     JSR $D492
C2/D482: 80 0B        BRA $D48F
C2/D484: A2 07 F8     LDX #$F807
C2/D487: C2 20        REP #$20
C2/D489: 20 B4 D4     JSR $D4B4
C2/D48C: 54 7E C0     MVN $7E,$C0
C2/D48F: 28           PLP 
C2/D490: AB           PLB 
C2/D491: 60           RTS 
C2/D492: 8B           PHB 
C2/D493: 08           PHP 
C2/D494: DA           PHX 
C2/D495: C2 20        REP #$20
C2/D497: 48           PHA 
C2/D498: 29 07 00     AND #$0007
C2/D49B: 0A           ASL 
C2/D49C: AA           TAX 
C2/D49D: 68           PLA 
C2/D49E: 29 00 1F     AND #$1F00
C2/D4A1: 4A           LSR 
C2/D4A2: 4A           LSR 
C2/D4A3: 4A           LSR 
C2/D4A4: 18           CLC 
C2/D4A5: 7F 46 F2 C0  ADC $C0F246,X
C2/D4A9: AA           TAX 
C2/D4AA: 20 B4 D4     JSR $D4B4
C2/D4AD: 54 7E D4     MVN $7E,$D4
C2/D4B0: FA           PLX 
C2/D4B1: 28           PLP 
C2/D4B2: AB           PLB 
C2/D4B3: 60           RTS 
C2/D4B4: 98           TYA 
C2/D4B5: 29 07        AND #$07
C2/D4B7: 00 EB        BRK $EB
C2/D4B9: 4A           LSR 
C2/D4BA: 4A           LSR 
C2/D4BB: 4A           LSR 
C2/D4BC: 18           CLC 
C2/D4BD: 69 00        ADC #$00
C2/D4BF: 74 A8        STZ $A8,X
C2/D4C1: A9 1F        LDA #$1F
C2/D4C3: 00 60        BRK $60
C2/D4C5: DA           PHX 
C2/D4C6: 08           PHP 
C2/D4C7: C2 20        REP #$20
C2/D4C9: A5 7E        LDA $7E
C2/D4CB: 29 03 00     AND #$0003
C2/D4CE: 85 7E        STA $7E
C2/D4D0: 0A           ASL 
C2/D4D1: AA           TAX 
C2/D4D2: BF 64 EA C0  LDA $C0EA64,X
C2/D4D6: 85 80        STA $80
C2/D4D8: 28           PLP 
C2/D4D9: FA           PLX 
C2/D4DA: 60           RTS 
C2/D4DB: 8B           PHB 
C2/D4DC: C2 20        REP #$20
C2/D4DE: A2 6D EF     LDX #$EF6D
C2/D4E1: A9 17 00     LDA #$0017
C2/D4E4: 20 9D DA     JSR $DA9D
C2/D4E7: 64 7E        STZ $7E
C2/D4E9: A5 7E        LDA $7E
C2/D4EB: 0A           ASL 
C2/D4EC: AA           TAX 
C2/D4ED: BF 5C EA C0  LDA $C0EA5C,X
C2/D4F1: 8D BA 2B     STA $2BBA
C2/D4F4: 20 D7 DD     JSR $DDD7
C2/D4F7: A5 7E        LDA $7E
C2/D4F9: 1A           INC 
C2/D4FA: 85 7E        STA $7E
C2/D4FC: C9 04 00     CMP #$0004
C2/D4FF: D0 E8        BNE $D4E9
C2/D501: AB           PLB 
C2/D502: 60           RTS 

; [  ]

C2/D503: A6 80        LDX $80
C2/D505: BD 01 05     LDA $0501,X
C2/D508: 29 1F 00     AND #$001F
C2/D50B: 85 D8        STA $D8
C2/D50D: BD 3A 05     LDA $053A,X
C2/D510: 29 0F 00     AND #$000F
C2/D513: 85 DA        STA $DA
C2/D515: BD 3B 05     LDA $053B,X
C2/D518: 29 FF 0F     AND #$0FFF
C2/D51B: 85 DC        STA $DC
C2/D51D: A5 D8        LDA $D8
C2/D51F: 0A           ASL 
C2/D520: AA           TAX 
C2/D521: A5 DA        LDA $DA
C2/D523: 0A           ASL 
C2/D524: 18           CLC 
C2/D525: 65 DA        ADC $DA
C2/D527: 7F C0 52 D1  ADC $D152C0,X   ; pointers to job ability data
C2/D52B: AA           TAX 
C2/D52C: BF 00 00 D1  LDA $D10000,X
C2/D530: 85 DE        STA $DE
C2/D532: 60           RTS 

; [  ]

C2/D533: A6 80        LDX $80
C2/D535: BD 00 05     LDA $0500,X
C2/D538: 29 07 00     AND #$0007
C2/D53B: 0A           ASL 
C2/D53C: AA           TAX 
C2/D53D: BF 50 EA C0  LDA $C0EA50,X
C2/D541: BB           TYX 
C2/D542: A8           TAY 
C2/D543: A9 06 00     LDA #$0006
C2/D546: 20 9D E5     JSR $E59D
C2/D549: 60           RTS 
C2/D54A: A6 80        LDX $80
C2/D54C: BD 1A 05     LDA $051A,X
C2/D54F: 29 7F 00     AND #$007F
C2/D552: D0 08        BNE $D55C
C2/D554: A6 80        LDX $80
C2/D556: BD 01 05     LDA $0501,X
C2/D559: 20 C7 E4     JSR $E4C7
C2/D55C: 60           RTS 
C2/D55D: A5 7E        LDA $7E
C2/D55F: 29 03 00     AND #$0003
C2/D562: 0A           ASL 
C2/D563: AA           TAX 
C2/D564: BF 48 EA C0  LDA $C0EA48,X
C2/D568: BB           TYX 
C2/D569: A8           TAY 
C2/D56A: A9 21 00     LDA #$0021
C2/D56D: 20 ED E4     JSR $E4ED
C2/D570: 60           RTS 
C2/D571: BB           TYX 
C2/D572: A5 D8        LDA $D8
C2/D574: C9 15 00     CMP #$0015
C2/D577: F0 05        BEQ $D57E
C2/D579: A0 74 EA     LDY #$EA74
C2/D57C: 80 03        BRA $D581
C2/D57E: A0 81 EA     LDY #$EA81
C2/D581: A9 8C C0     LDA #$C08C
C2/D584: 20 9D E5     JSR $E59D
C2/D587: 60           RTS 
C2/D588: A5 D8        LDA $D8
C2/D58A: C9 15 00     CMP #$0015
C2/D58D: F0 0D        BEQ $D59C
C2/D58F: BB           TYX 
C2/D590: A5 DA        LDA $DA
C2/D592: 29 0F 00     AND #$000F
C2/D595: 18           CLC 
C2/D596: 69 53 00     ADC #$0053
C2/D599: 9D 00 00     STA $0000,X
C2/D59C: 60           RTS 
C2/D59D: A6 D8        LDX $D8
C2/D59F: E0 15 00     CPX #$0015
C2/D5A2: F0 2E        BEQ $D5D2
C2/D5A4: BF EA 52 D1  LDA $D152EA,X
C2/D5A8: 29 FF 00     AND #$00FF
C2/D5AB: C5 DA        CMP $DA
C2/D5AD: F0 19        BEQ $D5C8
C2/D5AF: BB           TYX 
C2/D5B0: A0 DC 01     LDY #$01DC
C2/D5B3: A9 32 00     LDA #$0032
C2/D5B6: 20 ED E4     JSR $E4ED
C2/D5B9: E8           INX 
C2/D5BA: E8           INX 
C2/D5BB: E8           INX 
C2/D5BC: E8           INX 
C2/D5BD: E8           INX 
C2/D5BE: E8           INX 
C2/D5BF: E8           INX 
C2/D5C0: E8           INX 
C2/D5C1: C8           INY 
C2/D5C2: C8           INY 
C2/D5C3: 20 ED E4     JSR $E4ED
C2/D5C6: 80 0A        BRA $D5D2
C2/D5C8: BB           TYX 
C2/D5C9: A0 6C EA     LDY #$EA6C
C2/D5CC: A9 87 C0     LDA #$C087
C2/D5CF: 20 9D E5     JSR $E59D
C2/D5D2: 60           RTS 
C2/D5D3: BB           TYX 
C2/D5D4: A5 80        LDA $80
C2/D5D6: 18           CLC 
C2/D5D7: 69 06 05     ADC #$0506
C2/D5DA: A8           TAY 
C2/D5DB: A9 42 7E     LDA #$7E42
C2/D5DE: 20 ED E4     JSR $E4ED
C2/D5E1: 48           PHA 
C2/D5E2: 8A           TXA 
C2/D5E3: 18           CLC 
C2/D5E4: 69 0A 00     ADC #$000A
C2/D5E7: AA           TAX 
C2/D5E8: 68           PLA 
C2/D5E9: C8           INY 
C2/D5EA: C8           INY 
C2/D5EB: 20 ED E4     JSR $E4ED
C2/D5EE: 60           RTS 
C2/D5EF: BB           TYX 
C2/D5F0: A5 80        LDA $80
C2/D5F2: 18           CLC 
C2/D5F3: 69 0A 05     ADC #$050A
C2/D5F6: A8           TAY 
C2/D5F7: A9 32 7E     LDA #$7E32
C2/D5FA: 20 ED E4     JSR $E4ED
C2/D5FD: 48           PHA 
C2/D5FE: 8A           TXA 
C2/D5FF: 18           CLC 
C2/D600: 69 0A 00     ADC #$000A
C2/D603: AA           TAX 
C2/D604: 68           PLA 
C2/D605: C8           INY 
C2/D606: C8           INY 
C2/D607: 20 ED E4     JSR $E4ED
C2/D60A: 60           RTS 
C2/D60B: 8B           PHB 
C2/D60C: 08           PHP 
C2/D60D: A6 80        LDX $80
C2/D60F: BD 1A 05     LDA $051A,X
C2/D612: EB           XBA 
C2/D613: 0A           ASL 
C2/D614: 29 00 FE     AND #$FE00
C2/D617: F0 3C        BEQ $D655
C2/D619: 85 E0        STA $E0
C2/D61B: BB           TYX 
C2/D61C: A9 3A 00     LDA #$003A
C2/D61F: 85 E4        STA $E4
C2/D621: A9 08 00     LDA #$0008
C2/D624: 85 E2        STA $E2
C2/D626: A8           TAY 
C2/D627: 88           DEY 
C2/D628: 06 E0        ASL $E0
C2/D62A: 90 10        BCC $D63C
C2/D62C: A5 E4        LDA $E4
C2/D62E: 9D 00 00     STA $0000,X
C2/D631: A9 FF 00     LDA #$00FF
C2/D634: 9F C0 FF 7D  STA $7DFFC0,X
C2/D638: E8           INX 
C2/D639: E8           INX 
C2/D63A: C6 E2        DEC $E2
C2/D63C: E6 E4        INC $E4
C2/D63E: 88           DEY 
C2/D63F: D0 E7        BNE $D628
C2/D641: A4 E2        LDY $E2
C2/D643: C8           INY 
C2/D644: A9 FF 00     LDA #$00FF
C2/D647: 88           DEY 
C2/D648: F0 0B        BEQ $D655
C2/D64A: 9D 00 00     STA $0000,X
C2/D64D: 9F C0 FF 7D  STA $7DFFC0,X
C2/D651: E8           INX 
C2/D652: E8           INX 
C2/D653: 80 F2        BRA $D647
C2/D655: 28           PLP 
C2/D656: AB           PLB 
C2/D657: 60           RTS 
C2/D658: A0 47 09     LDY #$0947
C2/D65B: A9 73        LDA #$73
C2/D65D: 00 20        BRK $20
C2/D65F: ED E4 60     SBC $60E4
C2/D662: 08           PHP 
C2/D663: E2 20        SEP #$20
C2/D665: A9 3C        LDA #$3C
C2/D667: 85 8D        STA $8D
C2/D669: C0 17 2D     CPY #$2D17
C2/D66C: F0 06        BEQ $D674
C2/D66E: 20 A4 D6     JSR $D6A4
C2/D671: A0 89 01     LDY #$0189
C2/D674: 20 A4 D6     JSR $D6A4
C2/D677: A0 89 01     LDY #$0189
C2/D67A: 20 A4 D6     JSR $D6A4
C2/D67D: 85 8B        STA $8B
C2/D67F: C2 20        REP #$20
C2/D681: A9 32 00     LDA #$0032
C2/D684: A4 89        LDY $89
C2/D686: C0 E8 03     CPY #$03E8
C2/D689: 30 03        BMI $D68E
C2/D68B: 09 80 00     ORA #$0080
C2/D68E: A0 89 01     LDY #$0189
C2/D691: 20 ED E4     JSR $E4ED
C2/D694: C8           INY 
C2/D695: C8           INY 
C2/D696: 8A           TXA 
C2/D697: 18           CLC 
C2/D698: 69 08 00     ADC #$0008
C2/D69B: AA           TAX 
C2/D69C: A9 A1 00     LDA #$00A1
C2/D69F: 20 ED E4     JSR $E4ED
C2/D6A2: 28           PLP 
C2/D6A3: 60           RTS 
C2/D6A4: DA           PHX 
C2/D6A5: C8           INY 
C2/D6A6: C8           INY 
C2/D6A7: C8           INY 
C2/D6A8: A9 00        LDA #$00
C2/D6AA: A2 04 00     LDX #$0004
C2/D6AD: 8F 05 42 00  STA $004205
C2/D6B1: B9 00 00     LDA $0000,Y
C2/D6B4: 8F 04 42 00  STA $004204
C2/D6B8: 88           DEY 
C2/D6B9: A5 8D        LDA $8D
C2/D6BB: 8F 06 42 00  STA $004206
C2/D6BF: EA           NOP 
C2/D6C0: EA           NOP 
C2/D6C1: EA           NOP 
C2/D6C2: EA           NOP 
C2/D6C3: EA           NOP 
C2/D6C4: EA           NOP 
C2/D6C5: EA           NOP 
C2/D6C6: EA           NOP 
C2/D6C7: AF 14 42 00  LDA $004214
C2/D6CB: 95 88        STA $88,X
C2/D6CD: AF 16 42 00  LDA $004216
C2/D6D1: CA           DEX 
C2/D6D2: D0 D9        BNE $D6AD
C2/D6D4: 48           PHA 
C2/D6D5: A9 3C        LDA #$3C
C2/D6D7: 85 8D        STA $8D
C2/D6D9: 68           PLA 
C2/D6DA: FA           PLX 
C2/D6DB: 60           RTS 

; [ set font color ??? ]

; $E0: text length
;   A: palette index
;  +X: text address

C2/D6DC: 8B           PHB 
C2/D6DD: 08           PHP 
C2/D6DE: E2 20        SEP #$20
C2/D6E0: 85 E0        STA $E0
C2/D6E2: A5 E0        LDA $E0
C2/D6E4: F0 2E        BEQ $D714
C2/D6E6: EB           XBA 
C2/D6E7: 48           PHA 
C2/D6E8: 29 07        AND #$07
C2/D6EA: 0A           ASL 
C2/D6EB: 0A           ASL 
C2/D6EC: 85 E1        STA $E1
C2/D6EE: 68           PLA 
C2/D6EF: 29 80        AND #$80
C2/D6F1: 85 E2        STA $E2
C2/D6F3: E8           INX 
C2/D6F4: BD 00 00     LDA $0000,X
C2/D6F7: 29 E3        AND #$E3
C2/D6F9: 05 E1        ORA $E1
C2/D6FB: 9D 00 00     STA $0000,X
C2/D6FE: 24 E2        BIT $E2
C2/D700: 30 0C        BMI $D70E
C2/D702: BF C0 FF 7D  LDA $7DFFC0,X
C2/D706: 29 E3        AND #$E3
C2/D708: 05 E1        ORA $E1
C2/D70A: 9F C0 FF 7D  STA $7DFFC0,X
C2/D70E: E8           INX 
C2/D70F: E8           INX 
C2/D710: C6 E0        DEC $E0
C2/D712: D0 E0        BNE $D6F4
C2/D714: 28           PLP 
C2/D715: AB           PLB 
C2/D716: 60           RTS 

C2/D717: 8B           PHB 
C2/D718: 08           PHP 
C2/D719: AD 63 2B     LDA $2B63
C2/D71C: 29 0F        AND #$0F
C2/D71E: 00 0A        BRK $0A
C2/D720: 0A           ASL 
C2/D721: AA           TAX 
C2/D722: BF 16 F3 C0  LDA $C0F316,X
C2/D726: DA           PHX 
C2/D727: 20 B8 C1     JSR $C1B8
C2/D72A: FA           PLX 
C2/D72B: BF 18 F3 C0  LDA $C0F318,X
C2/D72F: AA           TAX 
C2/D730: A0 00 71     LDY #$7100
C2/D733: 20 FD C1     JSR $C1FD
C2/D736: AD 63 2B     LDA $2B63
C2/D739: 29 0F        AND #$0F
C2/D73B: 00 0A        BRK $0A
C2/D73D: 0A           ASL 
C2/D73E: 0A           ASL 
C2/D73F: AA           TAX 
C2/D740: A9 04        LDA #$04
C2/D742: 00 85        BRK $85
C2/D744: 85 A4        STA $A4
C2/D746: 80 BF        BRA $D707
C2/D748: 22 F3 C0 F0  JSL $F0C0F3
C2/D74C: 09 DA        ORA #$DA
C2/D74E: AA           TAX 
C2/D74F: B9 16 05     LDA $0516,Y
C2/D752: 20 E4 D8     JSR $D8E4
C2/D755: FA           PLX 
C2/D756: E8           INX 
C2/D757: E8           INX 
C2/D758: C8           INY 
C2/D759: C6 85        DEC $85
C2/D75B: D0 EA        BNE $D747
C2/D75D: 28           PLP 
C2/D75E: AB           PLB 
C2/D75F: 60           RTS 
C2/D760: A9 53        LDA #$53
C2/D762: AE 20 B8     LDX $B820
C2/D765: C1 A5        CMP ($A5,X)
C2/D767: 55 29        EOR $29,X
C2/D769: FF 00 3A 18  SBC $183A00,X
C2/D76D: 65 6B        ADC $6B
C2/D76F: AA           TAX 
C2/D770: BD 00 7A     LDA $7A00,X
C2/D773: 29 FF        AND #$FF
C2/D775: 00 E2        BRK $E2
C2/D777: 20 89 80     JSR $8089
C2/D77A: F0 05        BEQ $D781
C2/D77C: 29 7F        AND #$7F
C2/D77E: 18           CLC 
C2/D77F: 69 4E        ADC #$4E
C2/D781: C2 20        REP #$20
C2/D783: 29 FF 00     AND #$00FF
C2/D786: 48           PHA 
C2/D787: 0A           ASL 
C2/D788: AA           TAX 
C2/D789: BF 6C 71 D1  LDA $D1716C,X
C2/D78D: 8F EB 2C 7E  STA $7E2CEB
C2/D791: 20 16 DA     JSR $DA16
C2/D794: 68           PLA 
C2/D795: AA           TAX 
C2/D796: E2 20        SEP #$20
C2/D798: BF 39 F7 C0  LDA $C0F739,X
C2/D79C: F0 2B        BEQ $D7C9
C2/D79E: 48           PHA 
C2/D79F: 29 1F        AND #$1F
C2/D7A1: 85 E0        STA $E0
C2/D7A3: 68           PLA 
C2/D7A4: 29 E0        AND #$E0
C2/D7A6: 4A           LSR 
C2/D7A7: 4A           LSR 
C2/D7A8: 4A           LSR 
C2/D7A9: 4A           LSR 
C2/D7AA: 4A           LSR 
C2/D7AB: 85 E1        STA $E1
C2/D7AD: A5 E0        LDA $E0
C2/D7AF: A0 8C 56     LDY #$568C
C2/D7B2: 20 C7 E4     JSR $E4C7
C2/D7B5: C2 20        REP #$20
C2/D7B7: A2 A4 56     LDX #$56A4
C2/D7BA: A0 E1 01     LDY #$01E1
C2/D7BD: A9 11 00     LDA #$0011
C2/D7C0: 20 ED E4     JSR $E4ED
C2/D7C3: A9 37 AE     LDA #$AE37
C2/D7C6: 20 B8 C1     JSR $C1B8
C2/D7C9: 60           RTS 
C2/D7CA: A6 80        LDX $80
C2/D7CC: BF 40 05 00  LDA $000540,X
C2/D7D0: 85 F9        STA $F9
C2/D7D2: BF 42 05 00  LDA $000542,X
C2/D7D6: 85 FB        STA $FB
C2/D7D8: A5 F9        LDA $F9
C2/D7DA: C9 FF FF     CMP #$FFFF
C2/D7DD: D0 13        BNE $D7F2
C2/D7DF: A5 FB        LDA $FB
C2/D7E1: C9 FF FF     CMP #$FFFF
C2/D7E4: D0 0C        BNE $D7F2
C2/D7E6: BB           TYX 
C2/D7E7: A0 A8 F7     LDY #$F7A8
C2/D7EA: A9 04 C0     LDA #$C004
C2/D7ED: 20 9D E5     JSR $E59D
C2/D7F0: 80 03        BRA $D7F5
C2/D7F2: 20 02 D8     JSR $D802
C2/D7F5: 60           RTS 

; [  ]

C2/D7F6: A9 05 00     LDA #$0005
C2/D7F9: 85 85        STA $85
C2/D7FB: A2 41 00     LDX #$0041
C2/D7FE: 20 0D D8     JSR $D80D
C2/D801: 60           RTS 

C2/D802: A9 0D 00     LDA #$000D
C2/D805: 85 85        STA $85
C2/D807: A6 8E        LDX $8E
C2/D809: 20 0D D8     JSR $D80D
C2/D80C: 60           RTS 

C2/D80D: A5 F9        LDA $F9
C2/D80F: 3F AD F7 C0  AND $C0F7AD,X
C2/D813: 85 FD        STA $FD
C2/D815: A5 FB        LDA $FB
C2/D817: 3F AF F7 C0  AND $C0F7AF,X
C2/D81B: 05 FD        ORA $FD
C2/D81D: F0 0E        BEQ $D82D
C2/D81F: BF B1 F7 C0  LDA $C0F7B1,X
C2/D823: 29 FF 00     AND #$00FF
C2/D826: F0 05        BEQ $D82D
C2/D828: 99 00 00     STA $0000,Y
C2/D82B: C8           INY 
C2/D82C: C8           INY 
C2/D82D: E8           INX 
C2/D82E: E8           INX 
C2/D82F: E8           INX 
C2/D830: E8           INX 
C2/D831: E8           INX 
C2/D832: C6 85        DEC $85
C2/D834: D0 D7        BNE $D80D
C2/D836: 60           RTS 

; [  ]

C2/D837: A4 6B        LDY $6B
C2/D839: A6 8E        LDX $8E
C2/D83B: DA           PHX 
C2/D83C: BF 78 F4 C0  LDA $C0F478,X
C2/D840: AA           TAX 
C2/D841: B9 00 7A     LDA $7A00,Y
C2/D844: 20 E4 D8     JSR $D8E4
C2/D847: FA           PLX 
C2/D848: C8           INY 
C2/D849: E8           INX 
C2/D84A: E8           INX 
C2/D84B: E0 20 00     CPX #$0020
C2/D84E: D0 EB        BNE $D83B
C2/D850: 60           RTS 

; [ get list of available abilities ]

C2/D851: 08           PHP 
C2/D852: A2 00 02     LDX #$0200
C2/D855: CA           DEX 
C2/D856: CA           DEX 
C2/D857: 9E 00 7A     STZ $7A00,X
C2/D85A: D0 F9        BNE $D855
C2/D85C: A5 7E        LDA $7E
C2/D85E: 0A           ASL 
C2/D85F: AA           TAX 
C2/D860: BF 3A F3 C0  LDA $C0F33A,X   ; pointer to character abilities
C2/D864: A8           TAY 
C2/D865: E2 20        SEP #$20
C2/D867: A6 8E        LDX $8E
C2/D869: E8           INX 
C2/D86A: 64 E0        STZ $E0
C2/D86C: A9 01        LDA #$01        ; start at $01
C2/D86E: 85 E3        STA $E3
C2/D870: A9 2C        LDA #$2C        ; end at $2C
C2/D872: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D875: A9 80        LDA #$80
C2/D877: 85 E0        STA $E0
C2/D879: C8           INY 
C2/D87A: A9 32        LDA #$32
C2/D87C: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D87F: C8           INY 
C2/D880: A9 38        LDA #$38
C2/D882: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D885: C8           INY 
C2/D886: A9 3E        LDA #$3E
C2/D888: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D88B: C8           INY 
C2/D88C: A9 44        LDA #$44
C2/D88E: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D891: C8           INY 
C2/D892: A9 49        LDA #$49
C2/D894: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D897: C8           INY 
C2/D898: A9 4C        LDA #$4C
C2/D89A: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D89D: 64 E0        STZ $E0
C2/D89F: C8           INY 
C2/D8A0: A9 4E        LDA #$4E
C2/D8A2: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D8A5: C8           INY 
C2/D8A6: A9 80        LDA #$80        ; start at $80
C2/D8A8: 85 E3        STA $E3
C2/D8AA: A9 A1        LDA #$A1        ; end at $A1
C2/D8AC: 20 B1 D8     JSR $D8B1       ; build list from ram bits
C2/D8AF: 28           PLP 
C2/D8B0: 60           RTS 

; [ build list from ram bits ]

C2/D8B1: 85 E4        STA $E4         ; end bit
C2/D8B3: B9 00 00     LDA $0000,Y
C2/D8B6: 85 E2        STA $E2
C2/D8B8: A9 08        LDA #$08        ; 8 bits
C2/D8BA: 85 E5        STA $E5
C2/D8BC: 06 E2        ASL $E2
C2/D8BE: 90 0A        BCC $D8CA
C2/D8C0: A5 E3        LDA $E3         ; start bit
C2/D8C2: 9D 00 7A     STA $7A00,X
C2/D8C5: 24 E0        BIT $E0
C2/D8C7: 30 01        BMI $D8CA
C2/D8C9: E8           INX 
C2/D8CA: E6 E3        INC $E3
C2/D8CC: A5 E3        LDA $E3
C2/D8CE: C5 E4        CMP $E4
C2/D8D0: 10 07        BPL $D8D9
C2/D8D2: C6 E5        DEC $E5         ; next bit
C2/D8D4: D0 E6        BNE $D8BC
C2/D8D6: C8           INY             ; next byte
C2/D8D7: 80 DA        BRA $D8B3
C2/D8D9: 24 E0        BIT $E0
C2/D8DB: 10 06        BPL $D8E3
C2/D8DD: BD 00 7A     LDA $7A00,X
C2/D8E0: F0 01        BEQ $D8E3
C2/D8E2: E8           INX 
C2/D8E3: 60           RTS 

; [  ]

C2/D8E4: 8B           PHB 
C2/D8E5: 5A           PHY 
C2/D8E6: 08           PHP 
C2/D8E7: F4 7E 7E     PEA $7E7E
C2/D8EA: AB           PLB 
C2/D8EB: AB           PLB 
C2/D8EC: C2 20        REP #$20
C2/D8EE: 29 FF 00     AND #$00FF
C2/D8F1: 48           PHA 
C2/D8F2: DA           PHX 
C2/D8F3: 0A           ASL 
C2/D8F4: AA           TAX 
C2/D8F5: BF 00 D6 7E  LDA $7ED600,X
C2/D8F9: A8           TAY 
C2/D8FA: FA           PLX 
C2/D8FB: 68           PLA 
C2/D8FC: 89 80 00     BIT #$0080
C2/D8FF: F0 08        BEQ $D909
C2/D901: A9 08 D1     LDA #$D108
C2/D904: 20 9D E5     JSR $E59D
C2/D907: 80 32        BRA $D93B
C2/D909: DA           PHX 
C2/D90A: 5A           PHY 
C2/D90B: 48           PHA 
C2/D90C: A2 A3 F4     LDX #$F4A3
C2/D90F: A0 3F 2B     LDY #$2B3F
C2/D912: A9 07 00     LDA #$0007
C2/D915: 54 7E C0     MVN $7E,$C0
C2/D918: 68           PLA 
C2/D919: 7A           PLY 
C2/D91A: FA           PLX 
C2/D91B: 29 7F 00     AND #$007F
C2/D91E: F0 06        BEQ $D926
C2/D920: A9 C9 00     LDA #$00C9
C2/D923: 8D 3F 2B     STA $2B3F
C2/D926: DA           PHX 
C2/D927: BB           TYX 
C2/D928: A0 40 2B     LDY #$2B40
C2/D92B: A9 04 00     LDA #$0004
C2/D92E: 54 7E D1     MVN $7E,$D1
C2/D931: FA           PLX 
C2/D932: A0 3F 2B     LDY #$2B3F
C2/D935: A9 08 7E     LDA #$7E08
C2/D938: 20 9D E5     JSR $E59D
C2/D93B: 28           PLP 
C2/D93C: 7A           PLY 
C2/D93D: AB           PLB 
C2/D93E: 60           RTS 
C2/D93F: BB           TYX 
C2/D940: C2 20        REP #$20
C2/D942: A5 D8        LDA $D8
C2/D944: C9 15 00     CMP #$0015
C2/D947: F0 05        BEQ $D94E
C2/D949: A0 98 F4     LDY #$F498
C2/D94C: 80 03        BRA $D951
C2/D94E: A0 A3 F4     LDY #$F4A3
C2/D951: A9 8A C0     LDA #$C08A
C2/D954: 20 9D E5     JSR $E59D
C2/D957: 60           RTS 

; [ menu command $06: transfer galuf's stats to krile ]

C2/D958: 08           PHP 
C2/D959: 8B           PHB 
C2/D95A: 64 7E        STZ $7E
C2/D95C: 20 C5 D4     JSR $D4C5
C2/D95F: A6 80        LDX $80
C2/D961: BD 00 05     LDA $0500,X
C2/D964: 29 07        AND #$07
C2/D966: C9 04        CMP #$04
C2/D968: F0 0A        BEQ $D974
C2/D96A: E6 7E        INC $7E
C2/D96C: A5 7E        LDA $7E
C2/D96E: C9 04        CMP #$04
C2/D970: F0 36        BEQ $D9A8
C2/D972: 80 E8        BRA $D95C
C2/D974: C2 20        REP #$20
C2/D976: 20 03 D5     JSR $D503
C2/D979: 20 64 E4     JSR $E464
C2/D97C: 20 A4 DA     JSR $DAA4
C2/D97F: E2 20        SEP #$20
C2/D981: A6 7E        LDX $7E
C2/D983: FE 20 04     INC $0420,X
C2/D986: A9 15        LDA #$15
C2/D988: 85 D8        STA $D8
C2/D98A: 20 7D E4     JSR $E47D       ; get character job data
C2/D98D: A6 80        LDX $80
C2/D98F: A5 DA        LDA $DA
C2/D991: 9D 3A 05     STA $053A,X     ; job level
C2/D994: A5 D8        LDA $D8
C2/D996: 9D 01 05     STA $0501,X     ; job
C2/D999: C2 20        REP #$20
C2/D99B: A5 DC        LDA $DC
C2/D99D: 9D 3B 05     STA $053B,X
C2/D9A0: E2 20        SEP #$20
C2/D9A2: 20 82 EB     JSR $EB82
C2/D9A5: 20 D6 E6     JSR $E6D6
C2/D9A8: AB           PLB 
C2/D9A9: 28           PLP 
C2/D9AA: 60           RTS 

C2/D9AB: 08           PHP 
C2/D9AC: 8B           PHB 
C2/D9AD: 5A           PHY 
C2/D9AE: C2 20        REP #$20
C2/D9B0: 29 FF 00     AND #$00FF
C2/D9B3: 48           PHA 
C2/D9B4: 0A           ASL 
C2/D9B5: AA           TAX 
C2/D9B6: BF 00 D0 7E  LDA $7ED000,X
C2/D9BA: AA           TAX 
C2/D9BB: DA           PHX 
C2/D9BC: A0 9B 01     LDY #$019B
C2/D9BF: A9 0B 00     LDA #$000B
C2/D9C2: 54 00 D1     MVN $00,$D1
C2/D9C5: FA           PLX 
C2/D9C6: 68           PLA 
C2/D9C7: C9 61 00     CMP #$0061
C2/D9CA: F0 07        BEQ $D9D3
C2/D9CC: C9 63 00     CMP #$0063
C2/D9CF: F0 1E        BEQ $D9EF
C2/D9D1: 80 24        BRA $D9F7
C2/D9D3: AD B5 09     LDA $09B5
C2/D9D6: 29 FF 00     AND #$00FF
C2/D9D9: 48           PHA 
C2/D9DA: A5 A2        LDA $A2
C2/D9DC: 29 FF 00     AND #$00FF
C2/D9DF: 38           SEC 
C2/D9E0: E3 01        SBC $01,S
C2/D9E2: 83 01        STA $01,S
C2/D9E4: 68           PLA 
C2/D9E5: 10 02        BPL $D9E9
C2/D9E7: A5 8E        LDA $8E
C2/D9E9: E2 20        SEP #$20
C2/D9EB: 85 A2        STA $A2
C2/D9ED: 80 08        BRA $D9F7
C2/D9EF: E2 20        SEP #$20
C2/D9F1: AD B5 09     LDA $09B5
C2/D9F4: 4A           LSR 
C2/D9F5: 85 A2        STA $A2
C2/D9F7: 7A           PLY 
C2/D9F8: AB           PLB 
C2/D9F9: 28           PLP 
C2/D9FA: 60           RTS 

; [  ]

C2/D9FB: BF 00 00 C0  LDA $C00000,X
C2/D9FF: 8F 16 21 00  STA $002116
C2/DA03: E8           INX 
C2/DA04: E8           INX 
C2/DA05: A0 00 43     LDY #$4300
C2/DA08: A9 06        LDA #$06
C2/DA0A: 00 54        BRK $54
C2/DA0C: 00 C0        BRK $C0
C2/DA0E: E2 20        SEP #$20
C2/DA10: A9 01        LDA #$01
C2/DA12: 8D 0B 42     STA $420B
C2/DA15: 60           RTS 
C2/DA16: 8B           PHB 
C2/DA17: 08           PHP 
C2/DA18: F4 7E 7E     PEA $7E7E
C2/DA1B: AB           PLB 
C2/DA1C: AB           PLB 
C2/DA1D: C2 20        REP #$20
C2/DA1F: AD E5 2C     LDA $2CE5
C2/DA22: 8D ED 2C     STA $2CED
C2/DA25: 9C EF 2C     STZ $2CEF
C2/DA28: AE EB 2C     LDX $2CEB
C2/DA2B: A0 F1 2C     LDY #$2CF1
C2/DA2E: AD E7 2C     LDA $2CE7
C2/DA31: 3A           DEC 
C2/DA32: 54 7E D1     MVN $7E,$D1
C2/DA35: 1A           INC 
C2/DA36: 99 00 00     STA $0000,Y
C2/DA39: A6 8E        LDX $8E
C2/DA3B: E2 20        SEP #$20
C2/DA3D: BD F1 2C     LDA $2CF1,X
C2/DA40: C9 01        CMP #$01
C2/DA42: F0 08        BEQ $DA4C
C2/DA44: E8           INX 
C2/DA45: EC E7 2C     CPX $2CE7
C2/DA48: D0 F3        BNE $DA3D
C2/DA4A: 80 03        BRA $DA4F
C2/DA4C: 9E F1 2C     STZ $2CF1,X
C2/DA4F: C2 20        REP #$20
C2/DA51: AE ED 2C     LDX $2CED
C2/DA54: A0 F1 2C     LDY #$2CF1
C2/DA57: AD E7 2C     LDA $2CE7
C2/DA5A: 29 FF 00     AND #$00FF
C2/DA5D: 09 00 7E     ORA #$7E00
C2/DA60: 20 9D E5     JSR $E59D
C2/DA63: 98           TYA 
C2/DA64: 38           SEC 
C2/DA65: E9 F1 2C     SBC #$2CF1
C2/DA68: 18           CLC 
C2/DA69: 6D EB 2C     ADC $2CEB
C2/DA6C: AA           TAX 
C2/DA6D: BF 00 00 D1  LDA $D10000,X
C2/DA71: 29 FF 00     AND #$00FF
C2/DA74: F0 24        BEQ $DA9A
C2/DA76: C9 01 00     CMP #$0001
C2/DA79: D0 01        BNE $DA7C
C2/DA7B: E8           INX 
C2/DA7C: 8E EB 2C     STX $2CEB
C2/DA7F: AD ED 2C     LDA $2CED
C2/DA82: 18           CLC 
C2/DA83: 69 80 00     ADC #$0080
C2/DA86: 8D ED 2C     STA $2CED
C2/DA89: AD E7 2C     LDA $2CE7
C2/DA8C: 18           CLC 
C2/DA8D: 6D EF 2C     ADC $2CEF
C2/DA90: 8D EF 2C     STA $2CEF
C2/DA93: CD E9 2C     CMP $2CE9
C2/DA96: F0 02        BEQ $DA9A
C2/DA98: 80 8E        BRA $DA28
C2/DA9A: 28           PLP 
C2/DA9B: AB           PLB 
C2/DA9C: 60           RTS 
C2/DA9D: A0 BE 2B     LDY #$2BBE
C2/DAA0: 54 7E C0     MVN $7E,$C0
C2/DAA3: 60           RTS 
C2/DAA4: 8B           PHB 
C2/DAA5: 08           PHP 
C2/DAA6: C2 20        REP #$20
C2/DAA8: A5 6F        LDA $6F
C2/DAAA: 48           PHA 
C2/DAAB: E2 20        SEP #$20
C2/DAAD: 20 78 E1     JSR $E178
C2/DAB0: A9 01        LDA #$01
C2/DAB2: 85 6F        STA $6F
C2/DAB4: 20 11 E2     JSR $E211
C2/DAB7: A5 73        LDA $73
C2/DAB9: 20 86 E2     JSR $E286
C2/DABC: A5 90        LDA $90
C2/DABE: D0 08        BNE $DAC8
C2/DAC0: A9 01        LDA #$01
C2/DAC2: EB           XBA 
C2/DAC3: A5 73        LDA $73
C2/DAC5: 20 CE E2     JSR $E2CE
C2/DAC8: A5 6F        LDA $6F
C2/DACA: 1A           INC 
C2/DACB: C9 06        CMP #$06
C2/DACD: D0 E3        BNE $DAB2
C2/DACF: 20 8F E1     JSR $E18F
C2/DAD2: C2 20        REP #$20
C2/DAD4: 68           PLA 
C2/DAD5: 85 6F        STA $6F
C2/DAD7: 28           PLP 
C2/DAD8: AB           PLB 
C2/DAD9: 60           RTS 
C2/DADA: A6 8E        LDX $8E
C2/DADC: BF D2 EE C0  LDA $C0EED2,X
C2/DAE0: F0 09        BEQ $DAEB
C2/DAE2: CD E7 29     CMP $29E7
C2/DAE5: F0 07        BEQ $DAEE
C2/DAE7: E8           INX 
C2/DAE8: E8           INX 
C2/DAE9: 80 F1        BRA $DADC
C2/DAEB: 9C E7 29     STZ $29E7
C2/DAEE: 60           RTS 
C2/DAEF: 8B           PHB 
C2/DAF0: 08           PHP 
C2/DAF1: F4 7E 7E     PEA $7E7E
C2/DAF4: AB           PLB 
C2/DAF5: AB           PLB 
C2/DAF6: C2 20        REP #$20
C2/DAF8: 9C F1 29     STZ $29F1
C2/DAFB: E2 20        SEP #$20
C2/DAFD: AD F8 29     LDA $29F8
C2/DB00: 8F 02 42 00  STA $004202
C2/DB04: AD F9 29     LDA $29F9
C2/DB07: 8F 03 42 00  STA $004203
C2/DB0B: EA           NOP 
C2/DB0C: EA           NOP 
C2/DB0D: EA           NOP 
C2/DB0E: C2 20        REP #$20
C2/DB10: AF 16 42 00  LDA $004216
C2/DB14: 8D EF 29     STA $29EF
C2/DB17: E2 20        SEP #$20
C2/DB19: AD E7 29     LDA $29E7
C2/DB1C: 20 DA DA     JSR $DADA
C2/DB1F: AD E7 29     LDA $29E7
C2/DB22: F0 3F        BEQ $DB63
C2/DB24: C2 20        REP #$20
C2/DB26: BF 2B E8 C0  LDA $C0E82B,X
C2/DB2A: 85 C7        STA $C7
C2/DB2C: E2 20        SEP #$20
C2/DB2E: A4 8E        LDY $8E
C2/DB30: B9 EA 29     LDA $29EA,Y
C2/DB33: D0 08        BNE $DB3D
C2/DB35: C8           INY 
C2/DB36: C0 04 00     CPY #$0004
C2/DB39: D0 F5        BNE $DB30
C2/DB3B: 80 26        BRA $DB63
C2/DB3D: 84 7E        STY $7E
C2/DB3F: 20 C5 D4     JSR $D4C5
C2/DB42: A4 80        LDY $80
C2/DB44: 62 02 00     PER $DB49
C2/DB47: 6C C7 01     JMP ($01C7)
C2/DB4A: AD F1 29     LDA $29F1
C2/DB4D: F0 14        BEQ $DB63
C2/DB4F: C2 20        REP #$20
C2/DB51: AD E7 29     LDA $29E7
C2/DB54: 29 FF 00     AND #$00FF
C2/DB57: 09 00 01     ORA #$0100
C2/DB5A: 20 28 E3     JSR $E328
C2/DB5D: CE E8 29     DEC $29E8
C2/DB60: 20 C8 E0     JSR $E0C8
C2/DB63: 28           PLP 
C2/DB64: AB           PLB 
C2/DB65: 60           RTS 
C2/DB66: 08           PHP 
C2/DB67: B9 1A 05     LDA $051A,Y
C2/DB6A: 89 C2        BIT #$C2
C2/DB6C: C2 20        REP #$20
C2/DB6E: D0 20        BNE $DB90
C2/DB70: B9 0A 05     LDA $050A,Y
C2/DB73: D9 0C 05     CMP $050C,Y
C2/DB76: F0 18        BEQ $DB90
C2/DB78: AD EF 29     LDA $29EF
C2/DB7B: 18           CLC 
C2/DB7C: 79 0A 05     ADC $050A,Y
C2/DB7F: 99 0A 05     STA $050A,Y
C2/DB82: B9 0C 05     LDA $050C,Y
C2/DB85: D9 0A 05     CMP $050A,Y
C2/DB88: 10 03        BPL $DB8D
C2/DB8A: 99 0A 05     STA $050A,Y
C2/DB8D: EE F1 29     INC $29F1
C2/DB90: 28           PLP 
C2/DB91: 60           RTS 
C2/DB92: 08           PHP 
C2/DB93: B9 1A 05     LDA $051A,Y
C2/DB96: 89 C2        BIT #$C2
C2/DB98: C2 20        REP #$20
C2/DB9A: D0 1F        BNE $DBBB
C2/DB9C: B9 08 05     LDA $0508,Y
C2/DB9F: D9 06 05     CMP $0506,Y
C2/DBA2: D0 08        BNE $DBAC
C2/DBA4: B9 0C 05     LDA $050C,Y
C2/DBA7: D9 0A 05     CMP $050A,Y
C2/DBAA: F0 0F        BEQ $DBBB
C2/DBAC: B9 08 05     LDA $0508,Y
C2/DBAF: 99 06 05     STA $0506,Y
C2/DBB2: B9 0C 05     LDA $050C,Y
C2/DBB5: 99 0A 05     STA $050A,Y
C2/DBB8: EE F1 29     INC $29F1
C2/DBBB: 28           PLP 
C2/DBBC: 60           RTS 
C2/DBBD: B9 1A 05     LDA $051A,Y
C2/DBC0: 89 20        BIT #$20
C2/DBC2: F0 09        BEQ $DBCD
C2/DBC4: 2D F8 29     AND $29F8
C2/DBC7: 99 1A 05     STA $051A,Y
C2/DBCA: EE F1 29     INC $29F1
C2/DBCD: 60           RTS 
C2/DBCE: 08           PHP 
C2/DBCF: B9 1A 05     LDA $051A,Y
C2/DBD2: 89 02        BIT #$02
C2/DBD4: F0 10        BEQ $DBE6
C2/DBD6: 29 FD        AND #$FD
C2/DBD8: 99 1A 05     STA $051A,Y
C2/DBDB: C2 20        REP #$20
C2/DBDD: A9 01 00     LDA #$0001
C2/DBE0: 99 06 05     STA $0506,Y
C2/DBE3: EE F1 29     INC $29F1
C2/DBE6: 28           PLP 
C2/DBE7: 60           RTS 
C2/DBE8: B9 1A 05     LDA $051A,Y
C2/DBEB: 89 01        BIT #$01
C2/DBED: F0 09        BEQ $DBF8
C2/DBEF: 2D F8 29     AND $29F8
C2/DBF2: 99 1A 05     STA $051A,Y
C2/DBF5: EE F1 29     INC $29F1
C2/DBF8: 60           RTS 
C2/DBF9: B9 1A 05     LDA $051A,Y
C2/DBFC: 89 40        BIT #$40
C2/DBFE: F0 09        BEQ $DC09
C2/DC00: 2D F8 29     AND $29F8
C2/DC03: 99 1A 05     STA $051A,Y
C2/DC06: EE F1 29     INC $29F1
C2/DC09: 60           RTS 
C2/DC0A: B9 1A 05     LDA $051A,Y
C2/DC0D: 89 10        BIT #$10
C2/DC0F: F0 09        BEQ $DC1A
C2/DC11: 2D F8 29     AND $29F8
C2/DC14: 99 1A 05     STA $051A,Y
C2/DC17: EE F1 29     INC $29F1
C2/DC1A: 60           RTS 
C2/DC1B: 8B           PHB 
C2/DC1C: 08           PHP 
C2/DC1D: F4 7E 7E     PEA $7E7E
C2/DC20: AB           PLB 
C2/DC21: AB           PLB 
C2/DC22: C2 20        REP #$20
C2/DC24: 9C F1 29     STZ $29F1
C2/DC27: A5 71        LDA $71
C2/DC29: 29 0F 00     AND #$000F
C2/DC2C: 85 7E        STA $7E
C2/DC2E: 20 C5 D4     JSR $D4C5
C2/DC31: A6 80        LDX $80
C2/DC33: E2 20        SEP #$20
C2/DC35: BD 02 05     LDA $0502,X
C2/DC38: 8F 02 42 00  STA $004202
C2/DC3C: BD 2B 05     LDA $052B,X
C2/DC3F: 8F 03 42 00  STA $004203
C2/DC43: EA           NOP 
C2/DC44: EA           NOP 
C2/DC45: EA           NOP 
C2/DC46: EA           NOP 
C2/DC47: AF 17 42 00  LDA $004217
C2/DC4B: 18           CLC 
C2/DC4C: 69 04        ADC #$04
C2/DC4E: 8F 02 42 00  STA $004202
C2/DC52: AD F9 29     LDA $29F9
C2/DC55: 8F 03 42 00  STA $004203
C2/DC59: EA           NOP 
C2/DC5A: EA           NOP 
C2/DC5B: EA           NOP 
C2/DC5C: C2 20        REP #$20
C2/DC5E: AF 16 42 00  LDA $004216
C2/DC62: A8           TAY 
C2/DC63: A5 55        LDA $55
C2/DC65: 29 0F 00     AND #$000F
C2/DC68: C9 05 00     CMP #$0005
C2/DC6B: D0 03        BNE $DC70
C2/DC6D: 98           TYA 
C2/DC6E: 4A           LSR 
C2/DC6F: A8           TAY 
C2/DC70: 8C EF 29     STY $29EF
C2/DC73: E2 20        SEP #$20
C2/DC75: A6 8E        LDX $8E
C2/DC77: BF BA EE C0  LDA $C0EEBA,X
C2/DC7B: F0 52        BEQ $DCCF
C2/DC7D: CD E7 29     CMP $29E7
C2/DC80: F0 04        BEQ $DC86
C2/DC82: E8           INX 
C2/DC83: E8           INX 
C2/DC84: 80 F1        BRA $DC77
C2/DC86: C2 20        REP #$20
C2/DC88: BF 15 E8 C0  LDA $C0E815,X
C2/DC8C: 85 C7        STA $C7
C2/DC8E: E2 20        SEP #$20
C2/DC90: A4 8E        LDY $8E
C2/DC92: B9 EA 29     LDA $29EA,Y
C2/DC95: F0 0F        BEQ $DCA6
C2/DC97: 5A           PHY 
C2/DC98: 84 7E        STY $7E
C2/DC9A: 20 C5 D4     JSR $D4C5
C2/DC9D: A4 80        LDY $80
C2/DC9F: 62 02 00     PER $DCA4
C2/DCA2: 6C C7 01     JMP ($01C7)
C2/DCA5: 7A           PLY 
C2/DCA6: C8           INY 
C2/DCA7: C0 04 00     CPY #$0004
C2/DCAA: D0 E6        BNE $DC92
C2/DCAC: AD F1 29     LDA $29F1
C2/DCAF: F0 1E        BEQ $DCCF
C2/DCB1: C2 20        REP #$20
C2/DCB3: A5 71        LDA $71
C2/DCB5: 29 0F 00     AND #$000F
C2/DCB8: 85 7E        STA $7E
C2/DCBA: 20 C5 D4     JSR $D4C5
C2/DCBD: A4 80        LDY $80
C2/DCBF: B9 0A 05     LDA $050A,Y
C2/DCC2: 38           SEC 
C2/DCC3: ED E8 29     SBC $29E8
C2/DCC6: 99 0A 05     STA $050A,Y
C2/DCC9: 8D DF 29     STA $29DF
C2/DCCC: 20 C8 E0     JSR $E0C8
C2/DCCF: 28           PLP 
C2/DCD0: AB           PLB 
C2/DCD1: 60           RTS 
C2/DCD2: 08           PHP 
C2/DCD3: B9 1A 05     LDA $051A,Y
C2/DCD6: 89 C2        BIT #$C2
C2/DCD8: C2 20        REP #$20
C2/DCDA: D0 20        BNE $DCFC
C2/DCDC: B9 06 05     LDA $0506,Y
C2/DCDF: D9 08 05     CMP $0508,Y
C2/DCE2: F0 18        BEQ $DCFC
C2/DCE4: AD EF 29     LDA $29EF
C2/DCE7: 18           CLC 
C2/DCE8: 79 06 05     ADC $0506,Y
C2/DCEB: 99 06 05     STA $0506,Y
C2/DCEE: B9 08 05     LDA $0508,Y
C2/DCF1: D9 06 05     CMP $0506,Y
C2/DCF4: 10 03        BPL $DCF9
C2/DCF6: 99 06 05     STA $0506,Y
C2/DCF9: EE F1 29     INC $29F1
C2/DCFC: 28           PLP 
C2/DCFD: 60           RTS 
C2/DCFE: B9 1A 05     LDA $051A,Y
C2/DD01: 89 04        BIT #$04
C2/DD03: F0 09        BEQ $DD0E
C2/DD05: 2D F8 29     AND $29F8
C2/DD08: 99 1A 05     STA $051A,Y
C2/DD0B: EE F1 29     INC $29F1
C2/DD0E: 60           RTS 
C2/DD0F: B9 1A 05     LDA $051A,Y
C2/DD12: 89 C2        BIT #$C2
C2/DD14: D0 09        BNE $DD1F
C2/DD16: 4D FA 29     EOR $29FA
C2/DD19: 99 1A 05     STA $051A,Y
C2/DD1C: EE F1 29     INC $29F1
C2/DD1F: 60           RTS 
C2/DD20: 08           PHP 
C2/DD21: B9 1A 05     LDA $051A,Y
C2/DD24: 89 80        BIT #$80
C2/DD26: F0 30        BEQ $DD58
C2/DD28: 29 7F        AND #$7F
C2/DD2A: 99 1A 05     STA $051A,Y
C2/DD2D: C2 20        REP #$20
C2/DD2F: B9 08 05     LDA $0508,Y
C2/DD32: E2 20        SEP #$20
C2/DD34: 8F 1B 21 00  STA $00211B
C2/DD38: EB           XBA 
C2/DD39: 8F 1B 21 00  STA $00211B
C2/DD3D: AD FA 29     LDA $29FA
C2/DD40: 8F 1C 21 00  STA $00211C
C2/DD44: 8F 1C 21 00  STA $00211C
C2/DD48: C2 20        REP #$20
C2/DD4A: AF 34 21 00  LDA $002134
C2/DD4E: 4A           LSR 
C2/DD4F: 4A           LSR 
C2/DD50: 4A           LSR 
C2/DD51: 4A           LSR 
C2/DD52: 99 06 05     STA $0506,Y
C2/DD55: EE F1 29     INC $29F1
C2/DD58: 28           PLP 
C2/DD59: 60           RTS 
C2/DD5A: B9 1A 05     LDA $051A,Y
C2/DD5D: 89 75        BIT #$75
C2/DD5F: F0 09        BEQ $DD6A
C2/DD61: 2D F8 29     AND $29F8
C2/DD64: 99 1A 05     STA $051A,Y
C2/DD67: EE F1 29     INC $29F1
C2/DD6A: 60           RTS 
C2/DD6B: A5 55        LDA $55
C2/DD6D: C9 05        CMP #$05
C2/DD6F: D0 03        BNE $DD74
C2/DD71: 4C D2 DC     JMP $DCD2
C2/DD74: B9 1A 05     LDA $051A,Y
C2/DD77: 89 C2        BIT #$C2
C2/DD79: D0 12        BNE $DD8D
C2/DD7B: 08           PHP 
C2/DD7C: C2 20        REP #$20
C2/DD7E: B9 08 05     LDA $0508,Y
C2/DD81: D9 06 05     CMP $0506,Y
C2/DD84: F0 06        BEQ $DD8C
C2/DD86: 99 06 05     STA $0506,Y
C2/DD89: EE F1 29     INC $29F1
C2/DD8C: 28           PLP 
C2/DD8D: 60           RTS 
C2/DD8E: 08           PHP 
C2/DD8F: B9 1A 05     LDA $051A,Y
C2/DD92: 89 80        BIT #$80
C2/DD94: F0 10        BEQ $DDA6
C2/DD96: 29 7F        AND #$7F
C2/DD98: 99 1A 05     STA $051A,Y
C2/DD9B: C2 20        REP #$20
C2/DD9D: B9 08 05     LDA $0508,Y
C2/DDA0: 99 06 05     STA $0506,Y
C2/DDA3: EE F1 29     INC $29F1
C2/DDA6: 28           PLP 
C2/DDA7: 60           RTS 
C2/DDA8: B9 1A 05     LDA $051A,Y
C2/DDAB: 2D F8 29     AND $29F8
C2/DDAE: 99 1A 05     STA $051A,Y
C2/DDB1: EE F1 29     INC $29F1
C2/DDB4: 60           RTS 
C2/DDB5: B9 1A 05     LDA $051A,Y
C2/DDB8: 89 C0        BIT #$C0
C2/DDBA: D0 09        BNE $DDC5
C2/DDBC: 4D FA 29     EOR $29FA
C2/DDBF: 99 1A 05     STA $051A,Y
C2/DDC2: EE F1 29     INC $29F1
C2/DDC5: 60           RTS 
C2/DDC6: B9 1A 05     LDA $051A,Y
C2/DDC9: 89 C2        BIT #$C2
C2/DDCB: D0 09        BNE $DDD6
C2/DDCD: 0D FA 29     ORA $29FA
C2/DDD0: 99 1A 05     STA $051A,Y
C2/DDD3: EE F1 29     INC $29F1
C2/DDD6: 60           RTS 
C2/DDD7: 8B           PHB 
C2/DDD8: 08           PHP 
C2/DDD9: F4 7E 7E     PEA $7E7E
C2/DDDC: AB           PLB 
C2/DDDD: AB           PLB 
C2/DDDE: C2 20        REP #$20
C2/DDE0: AD BA 2B     LDA $2BBA
C2/DDE3: 85 E6        STA $E6
C2/DDE5: AD BE 2B     LDA $2BBE
C2/DDE8: F0 03        BEQ $DDED
C2/DDEA: 20 B8 C1     JSR $C1B8
C2/DDED: 20 C5 D4     JSR $D4C5
C2/DDF0: 20 03 D5     JSR $D503
C2/DDF3: A6 80        LDX $80
C2/DDF5: BD 00 05     LDA $0500,X
C2/DDF8: 29 40 00     AND #$0040
C2/DDFB: D0 3E        BNE $DE3B
C2/DDFD: AD BA 2B     LDA $2BBA
C2/DE00: 85 E6        STA $E6
C2/DE02: AD C0 2B     LDA $2BC0
C2/DE05: F0 03        BEQ $DE0A
C2/DE07: 20 B8 C1     JSR $C1B8
C2/DE0A: AD C2 2B     LDA $2BC2
C2/DE0D: 8D BC 2B     STA $2BBC
C2/DE10: A6 8E        LDX $8E
C2/DE12: 9B           TXY 
C2/DE13: 4E BC 2B     LSR $2BBC
C2/DE16: 90 1C        BCC $DE34
C2/DE18: AD BA 2B     LDA $2BBA
C2/DE1B: 18           CLC 
C2/DE1C: 79 C4 2B     ADC $2BC4,Y
C2/DE1F: DA           PHX 
C2/DE20: 5A           PHY 
C2/DE21: 08           PHP 
C2/DE22: A8           TAY 
C2/DE23: BF FF E7 C0  LDA $C0E7FF,X
C2/DE27: 85 C7        STA $C7
C2/DE29: 62 02 00     PER $DE2E
C2/DE2C: 6C C7 01     JMP ($01C7)
C2/DE2F: 28           PLP 
C2/DE30: 7A           PLY 
C2/DE31: FA           PLX 
C2/DE32: C8           INY 
C2/DE33: C8           INY 
C2/DE34: E8           INX 
C2/DE35: E8           INX 
C2/DE36: E0 16 00     CPX #$0016
C2/DE39: D0 D8        BNE $DE13
C2/DE3B: 28           PLP 
C2/DE3C: AB           PLB 
C2/DE3D: 60           RTS 

C2/DE3E: 8B           PHB 
C2/DE3F: 08           PHP 
C2/DE40: F4 7E 7E     PEA $7E7E
C2/DE43: AB           PLB 
C2/DE44: AB           PLB 
C2/DE45: C2 20        REP #$20
C2/DE47: A2 00 02     LDX #$0200
C2/DE4A: A9 FF FF     LDA #$FFFF
C2/DE4D: 9D FE 79     STA $79FE,X
C2/DE50: CA           DEX 
C2/DE51: CA           DEX 
C2/DE52: D0 F9        BNE $DE4D
C2/DE54: A9 00 7A     LDA #$7A00
C2/DE57: 85 E0        STA $E0
C2/DE59: AD E2 29     LDA $29E2
C2/DE5C: 29 FF 00     AND #$00FF
C2/DE5F: 0A           ASL 
C2/DE60: 0A           ASL 
C2/DE61: AA           TAX 
C2/DE62: BF 1A EF C0  LDA $C0EF1A,X
C2/DE66: 29 FF 00     AND #$00FF
C2/DE69: 85 E4        STA $E4
C2/DE6B: BF 1B EF C0  LDA $C0EF1B,X
C2/DE6F: 29 FF 00     AND #$00FF
C2/DE72: 85 E6        STA $E6
C2/DE74: BF 19 EF C0  LDA $C0EF19,X
C2/DE78: 29 FF 00     AND #$00FF
C2/DE7B: AA           TAX 
C2/DE7C: E2 20        SEP #$20
C2/DE7E: A4 E6        LDY $E6
C2/DE80: 84 85        STY $85
C2/DE82: A4 8E        LDY $8E
C2/DE84: BD FB 29     LDA $29FB,X
C2/DE87: 10 0B        BPL $DE94
C2/DE89: 8A           TXA 
C2/DE8A: 91 E0        STA ($E0),Y
C2/DE8C: C8           INY 
C2/DE8D: DA           PHX 
C2/DE8E: 5A           PHY 
C2/DE8F: 20 C7 DE     JSR $DEC7
C2/DE92: 7A           PLY 
C2/DE93: FA           PLX 
C2/DE94: E2 20        SEP #$20
C2/DE96: E8           INX 
C2/DE97: C6 85        DEC $85
C2/DE99: D0 E9        BNE $DE84
C2/DE9B: AD E2 29     LDA $29E2
C2/DE9E: C9 06        CMP #$06
C2/DEA0: F0 16        BEQ $DEB8
C2/DEA2: A9 FE        LDA #$FE
C2/DEA4: C4 E6        CPY $E6
C2/DEA6: F0 05        BEQ $DEAD
C2/DEA8: 91 E0        STA ($E0),Y
C2/DEAA: C8           INY 
C2/DEAB: 80 F7        BRA $DEA4
C2/DEAD: C2 20        REP #$20
C2/DEAF: A5 E0        LDA $E0
C2/DEB1: 18           CLC 
C2/DEB2: 65 E6        ADC $E6
C2/DEB4: 85 E0        STA $E0
C2/DEB6: 80 08        BRA $DEC0
C2/DEB8: C2 20        REP #$20
C2/DEBA: 98           TYA 
C2/DEBB: 18           CLC 
C2/DEBC: 65 E0        ADC $E0
C2/DEBE: 85 E0        STA $E0
C2/DEC0: C6 E4        DEC $E4
C2/DEC2: D0 B8        BNE $DE7C
C2/DEC4: 28           PLP 
C2/DEC5: AB           PLB 
C2/DEC6: 60           RTS 

C2/DEC7: 08           PHP 
C2/DEC8: C2 20        REP #$20
C2/DECA: 29 FF 00     AND #$00FF
C2/DECD: 8D E4 29     STA $29E4
C2/DED0: C9 48 00     CMP #$0048
C2/DED3: 10 69        BPL $DF3E
C2/DED5: C9 12 00     CMP #$0012
C2/DED8: 30 64        BMI $DF3E
C2/DEDA: E2 20        SEP #$20
C2/DEDC: A6 8E        LDX $8E
C2/DEDE: BF F4 EE C0  LDA $C0EEF4,X
C2/DEE2: C9 FF        CMP #$FF
C2/DEE4: F0 58        BEQ $DF3E
C2/DEE6: CD E4 29     CMP $29E4
C2/DEE9: F0 05        BEQ $DEF0
C2/DEEB: E8           INX 
C2/DEEC: E8           INX 
C2/DEED: E8           INX 
C2/DEEE: 80 EE        BRA $DEDE
C2/DEF0: C2 20        REP #$20
C2/DEF2: BF F5 EE C0  LDA $C0EEF5,X
C2/DEF6: 29 0F 00     AND #$000F
C2/DEF9: A8           TAY 
C2/DEFA: BF F6 EE C0  LDA $C0EEF6,X
C2/DEFE: E2 20        SEP #$20
C2/DF00: D9 D8 29     CMP $29D8,Y
C2/DF03: F0 02        BEQ $DF07
C2/DF05: 10 37        BPL $DF3E
C2/DF07: C2 20        REP #$20
C2/DF09: AE E4 29     LDX $29E4
C2/DF0C: BD 9D 2A     LDA $2A9D,X
C2/DF0F: 29 FF 00     AND #$00FF
C2/DF12: CD DF 29     CMP $29DF
C2/DF15: F0 04        BEQ $DF1B
C2/DF17: 30 02        BMI $DF1B
C2/DF19: 80 23        BRA $DF3E
C2/DF1B: E2 20        SEP #$20
C2/DF1D: AD E1 29     LDA $29E1
C2/DF20: 89 C2        BIT #$C2
C2/DF22: D0 1A        BNE $DF3E
C2/DF24: 89 20        BIT #$20
C2/DF26: F0 07        BEQ $DF2F
C2/DF28: AD E4 29     LDA $29E4
C2/DF2B: C9 29        CMP #$29
C2/DF2D: D0 0F        BNE $DF3E
C2/DF2F: E2 20        SEP #$20
C2/DF31: AE E4 29     LDX $29E4
C2/DF34: BD FB 29     LDA $29FB,X
C2/DF37: 09 40        ORA #$40
C2/DF39: 9D FB 29     STA $29FB,X
C2/DF3C: 80 0D        BRA $DF4B
C2/DF3E: E2 20        SEP #$20
C2/DF40: AE E4 29     LDX $29E4
C2/DF43: BD FB 29     LDA $29FB,X
C2/DF46: 29 BF        AND #$BF
C2/DF48: 9D FB 29     STA $29FB,X
C2/DF4B: 28           PLP 
C2/DF4C: 60           RTS 

; [  ]

C2/DF4D: 8B           PHB 
C2/DF4E: 08           PHP 
C2/DF4F: F4 7E 7E     PEA $7E7E
C2/DF52: AB           PLB 
C2/DF53: AB           PLB 
C2/DF54: C2 20        REP #$20
C2/DF56: AD E2 29     LDA $29E2
C2/DF59: 29 FF 00     AND #$00FF
C2/DF5C: AA           TAX 
C2/DF5D: BD D8 29     LDA $29D8,X
C2/DF60: 29 FF 00     AND #$00FF
C2/DF63: 85 F0        STA $F0
C2/DF65: 8A           TXA 
C2/DF66: 0A           ASL 
C2/DF67: AA           TAX 
C2/DF68: BF 43 EF C0  LDA $C0EF43,X   ; source bank and string length
C2/DF6C: 85 ED        STA $ED
C2/DF6E: BF 35 EF C0  LDA $C0EF35,X   ; number of spells ???
C2/DF72: 85 85        STA $85
C2/DF74: BF 66 E9 C0  LDA $C0E966,X
C2/DF78: AA           TAX 
C2/DF79: A4 8E        LDY $8E
C2/DF7B: 64 F2        STZ $F2
C2/DF7D: E6 F2        INC $F2

; start of loop
C2/DF7F: BF 00 00 C0  LDA $C00000,X
C2/DF83: 85 EB        STA $EB
C2/DF85: E8           INX 
C2/DF86: E8           INX 
C2/DF87: B9 00 7A     LDA $7A00,Y
C2/DF8A: 29 FF 00     AND #$00FF
C2/DF8D: C9 FF 00     CMP #$00FF
C2/DF90: F0 64        BEQ $DFF6
C2/DF92: C9 FE 00     CMP #$00FE
C2/DF95: F0 5F        BEQ $DFF6
C2/DF97: DA           PHX 
C2/DF98: 5A           PHY 
C2/DF99: AA           TAX 
C2/DF9A: E2 20        SEP #$20
C2/DF9C: BD FB 29     LDA $29FB,X
C2/DF9F: 85 E8        STA $E8
C2/DFA1: C2 20        REP #$20
C2/DFA3: 8A           TXA 
C2/DFA4: 0A           ASL 
C2/DFA5: AA           TAX 
C2/DFA6: BD 00 D4     LDA $D400,X     ; pointer to spell name
C2/DFA9: 85 E9        STA $E9
C2/DFAB: A6 EB        LDX $EB
C2/DFAD: AD E2 29     LDA $29E2
C2/DFB0: 29 FF 00     AND #$00FF
C2/DFB3: C9 05 00     CMP #$0005
C2/DFB6: D0 04        BNE $DFBC
C2/DFB8: CA           DEX 
C2/DFB9: CA           DEX 
C2/DFBA: 86 EB        STX $EB
C2/DFBC: A4 E9        LDY $E9
C2/DFBE: A5 ED        LDA $ED
C2/DFC0: 20 9D E5     JSR $E59D       ; draw text
C2/DFC3: A6 EB        LDX $EB
C2/DFC5: AD E2 29     LDA $29E2
C2/DFC8: 29 FF 00     AND #$00FF
C2/DFCB: F0 05        BEQ $DFD2
C2/DFCD: C9 04 00     CMP #$0004
C2/DFD0: 30 08        BMI $DFDA
C2/DFD2: A5 F0        LDA $F0
C2/DFD4: C5 F2        CMP $F2
C2/DFD6: 10 1C        BPL $DFF4
C2/DFD8: 80 0F        BRA $DFE9
C2/DFDA: A5 E8        LDA $E8
C2/DFDC: 29 40 00     AND #$0040
C2/DFDF: D0 13        BNE $DFF4
C2/DFE1: A5 F0        LDA $F0
C2/DFE3: C5 F2        CMP $F2
C2/DFE5: 30 02        BMI $DFE9
C2/DFE7: E8           INX 
C2/DFE8: E8           INX 
C2/DFE9: A5 ED        LDA $ED
C2/DFEB: 29 7F 00     AND #$007F
C2/DFEE: 09 00 01     ORA #$0100
C2/DFF1: 20 DC D6     JSR $D6DC       ; set font color
C2/DFF4: 7A           PLY 
C2/DFF5: FA           PLX 
C2/DFF6: C8           INY 
C2/DFF7: C2 20        REP #$20
C2/DFF9: E6 F2        INC $F2
C2/DFFB: C6 85        DEC $85
C2/DFFD: D0 80        BNE $DF7F
C2/DFFF: 28           PLP 
C2/E000: AB           PLB 
C2/E001: 60           RTS 

C2/E002: 8B           PHB 
C2/E003: 08           PHP 
C2/E004: F4 7E 7E     PEA $7E7E
C2/E007: AB           PLB 
C2/E008: AB           PLB 
C2/E009: C2 20        REP #$20
C2/E00B: A6 8E        LDX $8E
C2/E00D: 9E 00 7F     STZ $7F00,X
C2/E010: E8           INX 
C2/E011: E8           INX 
C2/E012: E0 00 03     CPX #$0300
C2/E015: D0 F6        BNE $E00D
C2/E017: C2 20        REP #$20
C2/E019: A4 8E        LDY $8E
C2/E01B: A9 E0 00     LDA #$00E0
C2/E01E: A2 00 01     LDX #$0100
C2/E021: 20 50 E0     JSR $E050
C2/E024: A5 8E        LDA $8E
C2/E026: A2 80 00     LDX #$0080
C2/E029: 20 50 E0     JSR $E050
C2/E02C: A9 80 00     LDA #$0080
C2/E02F: A2 E0 00     LDX #$00E0
C2/E032: 20 50 E0     JSR $E050
C2/E035: A2 00 80     LDX #$8000
C2/E038: A0 40 06     LDY #$0640
C2/E03B: A9 FF 01     LDA #$01FF
C2/E03E: 54 7E 7E     MVN $7E,$7E
C2/E041: A2 00 7F     LDX #$7F00
C2/E044: A0 8A 28     LDY #$288A
C2/E047: A9 FF 00     LDA #$00FF
C2/E04A: 54 7E 7E     MVN $7E,$7E
C2/E04D: 28           PLP 
C2/E04E: AB           PLB 
C2/E04F: 60           RTS 
C2/E050: 85 93        STA $93
C2/E052: 86 95        STX $95
C2/E054: A6 8E        LDX $8E
C2/E056: BD 40 06     LDA $0640,X
C2/E059: 29 FF        AND #$FF
C2/E05B: 00 F0        BRK $F0
C2/E05D: 3D C9 01     AND $01C9,X
C2/E060: 00 F0        BRK $F0
C2/E062: 38           SEC 
C2/E063: C9 80        CMP #$80
C2/E065: 00 F0        BRK $F0
C2/E067: 33 85        AND ($85,S),Y
C2/E069: E0 BD 40     CPX #$40BD
C2/E06C: 07 29        ORA [$29]
C2/E06E: FF 00 F0 29  SBC $29F000,X
C2/E072: C9 64        CMP #$64
C2/E074: 00 30        BRK $30
C2/E076: 03 A9        ORA $A9,S
C2/E078: 63 00        ADC $00,S
C2/E07A: 85 E2        STA $E2
C2/E07C: A5 E0        LDA $E0
C2/E07E: C5 93        CMP $93
C2/E080: 30 19        BMI $E09B
C2/E082: C5 95        CMP $95
C2/E084: 10 15        BPL $E09B
C2/E086: E2 20        SEP #$20
C2/E088: A5 E0        LDA $E0
C2/E08A: 99 00 80     STA $8000,Y
C2/E08D: A5 E2        LDA $E2
C2/E08F: 99 00 81     STA $8100,Y
C2/E092: BD 8A 28     LDA $288A,X
C2/E095: 99 00 7F     STA $7F00,Y
C2/E098: C8           INY 
C2/E099: C2 20        REP #$20
C2/E09B: E8           INX 
C2/E09C: E0 00 01     CPX #$0100
C2/E09F: D0 B5        BNE $E056
C2/E0A1: 98           TYA 
C2/E0A2: 1A           INC 
C2/E0A3: 29 FE FF     AND #$FFFE
C2/E0A6: A8           TAY 
C2/E0A7: 60           RTS 

; [ play sound effect ]

C2/E0A8: 48           PHA 
C2/E0A9: 08           PHP 
C2/E0AA: E2 20        SEP #$20
C2/E0AC: A9 11        LDA #$11        ; cursor 1
C2/E0AE: 80 1E        BRA $E0CE
C2/E0B0: 48           PHA 
C2/E0B1: 08           PHP 
C2/E0B2: E2 20        SEP #$20
C2/E0B4: A9 10        LDA #$10        ; cursor 2
C2/E0B6: 80 16        BRA $E0CE
C2/E0B8: 48           PHA 
C2/E0B9: 08           PHP 
C2/E0BA: E2 20        SEP #$20
C2/E0BC: A9 11        LDA #$11        ; cursor 1
C2/E0BE: 80 0E        BRA $E0CE
C2/E0C0: 48           PHA 
C2/E0C1: 08           PHP 
C2/E0C2: E2 20        SEP #$20
C2/E0C4: A9 12        LDA #$12        ; error
C2/E0C6: 80 06        BRA $E0CE
C2/E0C8: 48           PHA 
C2/E0C9: 08           PHP 
C2/E0CA: E2 20        SEP #$20
C2/E0CC: A9 13        LDA #$13        ; system sound effect $13
C2/E0CE: 8F 00 1D 00  STA $001D00
C2/E0D2: 22 04 00 C4  JSL $C40004     ; execute spc interrupt
C2/E0D6: 28           PLP 
C2/E0D7: 68           PLA 
C2/E0D8: 60           RTS 

; [ play sound effect ]

; a: game sound effect id

C2/E0D9: 8B           PHB 
C2/E0DA: 08           PHP 
C2/E0DB: C2 20        REP #$20
C2/E0DD: 48           PHA 
C2/E0DE: A2 B6 EE     LDX #$EEB6      ; C0/EEB6: $02, $5B, $0F, $88
C2/E0E1: A0 00 1D     LDY #$1D00
C2/E0E4: A9 03 00     LDA #$0003
C2/E0E7: 54 7E C0     MVN $7E,$C0     ; this is a pretty roundabout way of copying 4 bytes
C2/E0EA: 68           PLA 
C2/E0EB: E2 20        SEP #$20
C2/E0ED: 8D 01 1D     STA $1D01
C2/E0F0: 22 04 00 C4  JSL $C40004
C2/E0F4: 28           PLP 
C2/E0F5: AB           PLB 
C2/E0F6: 60           RTS 

C2/E0F7: 8B           PHB 
C2/E0F8: 08           PHP 
C2/E0F9: E2 20        SEP #$20
C2/E0FB: A9 7E        LDA #$7E
C2/E0FD: 48           PHA 
C2/E0FE: AB           PLB 
C2/E0FF: 64 90        STZ $90
C2/E101: A5 6F        LDA $6F
C2/E103: C9 03        CMP #$03
C2/E105: 10 60        BPL $E167
C2/E107: 3A           DEC 
C2/E108: C2 20        REP #$20
C2/E10A: 29 01 00     AND #$0001
C2/E10D: 0A           ASL 
C2/E10E: 0A           ASL 
C2/E10F: AA           TAX 
C2/E110: BF 53 EF C0  LDA $C0EF53,X
C2/E114: 18           CLC 
C2/E115: 65 80        ADC $80
C2/E117: A8           TAY 
C2/E118: A5 72        LDA $72
C2/E11A: 85 E0        STA $E0
C2/E11C: E2 20        SEP #$20
C2/E11E: B9 00 05     LDA $0500,Y
C2/E121: D0 03        BNE $E126
C2/E123: B9 FE 04     LDA $04FE,Y
C2/E126: 85 E2        STA $E2
C2/E128: 20 6A E1     JSR $E16A
C2/E12B: 85 E3        STA $E3
C2/E12D: A5 E0        LDA $E0
C2/E12F: 20 6A E1     JSR $E16A
C2/E132: 85 E1        STA $E1
C2/E134: A4 80        LDY $80
C2/E136: A5 E0        LDA $E0
C2/E138: 30 1B        BMI $E155
C2/E13A: A5 E2        LDA $E2
C2/E13C: 30 11        BMI $E14F
C2/E13E: F0 27        BEQ $E167
C2/E140: C9 01        CMP #$01
C2/E142: F0 23        BEQ $E167
C2/E144: B9 21 05     LDA $0521,Y
C2/E147: 29 01        AND #$01
C2/E149: F0 1A        BEQ $E165
C2/E14B: A5 E3        LDA $E3
C2/E14D: 30 16        BMI $E165
C2/E14F: A5 E1        LDA $E1
C2/E151: 30 12        BMI $E165
C2/E153: 80 12        BRA $E167
C2/E155: A5 E2        LDA $E2
C2/E157: 30 0C        BMI $E165
C2/E159: F0 0C        BEQ $E167
C2/E15B: C9 01        CMP #$01
C2/E15D: F0 08        BEQ $E167
C2/E15F: A5 E3        LDA $E3
C2/E161: 30 02        BMI $E165
C2/E163: 80 02        BRA $E167
C2/E165: E6 90        INC $90
C2/E167: 28           PLP 
C2/E168: AB           PLB 
C2/E169: 60           RTS 
C2/E16A: 30 09        BMI $E175
C2/E16C: 29 7F        AND #$7F
C2/E16E: 20 AB D9     JSR $D9AB
C2/E171: A5 9F        LDA $9F
C2/E173: 80 02        BRA $E177
C2/E175: A9 00        LDA #$00
C2/E177: 60           RTS 
C2/E178: 8B           PHB 
C2/E179: 08           PHP 
C2/E17A: C2 20        REP #$20
C2/E17C: A5 80        LDA $80
C2/E17E: 18           CLC 
C2/E17F: 69 0E 05     ADC #$050E
C2/E182: AA           TAX 
C2/E183: A0 E0 01     LDY #$01E0
C2/E186: A9 06 00     LDA #$0006
C2/E189: 54 7E 7E     MVN $7E,$7E
C2/E18C: 28           PLP 
C2/E18D: AB           PLB 
C2/E18E: 60           RTS 
C2/E18F: 8B           PHB 
C2/E190: 08           PHP 
C2/E191: C2 20        REP #$20
C2/E193: A5 80        LDA $80
C2/E195: 18           CLC 
C2/E196: 69 0E 05     ADC #$050E
C2/E199: A8           TAY 
C2/E19A: A2 E0 01     LDX #$01E0
C2/E19D: A9 06 00     LDA #$0006
C2/E1A0: 54 7E 7E     MVN $7E,$7E
C2/E1A3: 28           PLP 
C2/E1A4: AB           PLB 
C2/E1A5: 60           RTS 
C2/E1A6: 8B           PHB 
C2/E1A7: 08           PHP 
C2/E1A8: E2 20        SEP #$20
C2/E1AA: A9 7E        LDA #$7E
C2/E1AC: 48           PHA 
C2/E1AD: AB           PLB 
C2/E1AE: A5 6F        LDA $6F
C2/E1B0: C9 01        CMP #$01
C2/E1B2: F0 16        BEQ $E1CA
C2/E1B4: C9 02        CMP #$02
C2/E1B6: F0 12        BEQ $E1CA
C2/E1B8: 3A           DEC 
C2/E1B9: 3A           DEC 
C2/E1BA: 3A           DEC 
C2/E1BB: C2 20        REP #$20
C2/E1BD: 29 03 00     AND #$0003
C2/E1C0: A8           TAY 
C2/E1C1: E2 20        SEP #$20
C2/E1C3: A5 72        LDA $72
C2/E1C5: 99 E0 01     STA $01E0,Y
C2/E1C8: 80 44        BRA $E20E
C2/E1CA: 3A           DEC 
C2/E1CB: C2 20        REP #$20
C2/E1CD: 29 01 00     AND #$0001
C2/E1D0: A8           TAY 
C2/E1D1: E2 20        SEP #$20
C2/E1D3: A5 72        LDA $72
C2/E1D5: 30 0A        BMI $E1E1
C2/E1D7: 99 E5 01     STA $01E5,Y
C2/E1DA: A9 00        LDA #$00
C2/E1DC: 99 E3 01     STA $01E3,Y
C2/E1DF: 80 08        BRA $E1E9
C2/E1E1: 99 E3 01     STA $01E3,Y
C2/E1E4: A9 00        LDA #$00
C2/E1E6: 99 E5 01     STA $01E5,Y
C2/E1E9: C2 20        REP #$20
C2/E1EB: 98           TYA 
C2/E1EC: 1A           INC 
C2/E1ED: 29 01 00     AND #$0001
C2/E1F0: AA           TAX 
C2/E1F1: E2 20        SEP #$20
C2/E1F3: B9 E5 01     LDA $01E5,Y
C2/E1F6: F0 0A        BEQ $E202
C2/E1F8: B5 E5        LDA $E5,X
C2/E1FA: C9 01        CMP #$01
C2/E1FC: D0 10        BNE $E20E
C2/E1FE: 74 E5        STZ $E5,X
C2/E200: 80 0C        BRA $E20E
C2/E202: B5 E5        LDA $E5,X
C2/E204: 15 E3        ORA $E3,X
C2/E206: D0 06        BNE $E20E
C2/E208: A9 01        LDA #$01
C2/E20A: 95 E5        STA $E5,X
C2/E20C: 74 E3        STZ $E3,X
C2/E20E: 28           PLP 
C2/E20F: AB           PLB 
C2/E210: 60           RTS 
C2/E211: 8B           PHB 
C2/E212: 08           PHP 
C2/E213: E2 20        SEP #$20
C2/E215: A9 7E        LDA #$7E
C2/E217: 48           PHA 
C2/E218: AB           PLB 
C2/E219: 64 73        STZ $73
C2/E21B: A5 6F        LDA $6F
C2/E21D: C9 01        CMP #$01
C2/E21F: F0 1F        BEQ $E240
C2/E221: C9 02        CMP #$02
C2/E223: F0 1B        BEQ $E240
C2/E225: 3A           DEC 
C2/E226: 3A           DEC 
C2/E227: 3A           DEC 
C2/E228: C2 20        REP #$20
C2/E22A: 29 03 00     AND #$0003
C2/E22D: AA           TAX 
C2/E22E: E2 20        SEP #$20
C2/E230: B5 E0        LDA $E0,X
C2/E232: F0 4F        BEQ $E283
C2/E234: C9 80        CMP #$80
C2/E236: F0 4B        BEQ $E283
C2/E238: 85 73        STA $73
C2/E23A: A9 80        LDA #$80
C2/E23C: 95 E0        STA $E0,X
C2/E23E: 80 43        BRA $E283
C2/E240: 3A           DEC 
C2/E241: C2 20        REP #$20
C2/E243: 29 01 00     AND #$0001
C2/E246: A8           TAY 
C2/E247: E2 20        SEP #$20
C2/E249: B9 E5 01     LDA $01E5,Y
C2/E24C: D0 05        BNE $E253
C2/E24E: B9 E3 01     LDA $01E3,Y
C2/E251: F0 0F        BEQ $E262
C2/E253: C9 01        CMP #$01
C2/E255: F0 0B        BEQ $E262
C2/E257: 85 73        STA $73
C2/E259: A9 00        LDA #$00
C2/E25B: 99 E3 01     STA $01E3,Y
C2/E25E: 1A           INC 
C2/E25F: 99 E5 01     STA $01E5,Y
C2/E262: C2 20        REP #$20
C2/E264: 98           TYA 
C2/E265: 1A           INC 
C2/E266: 29 01 00     AND #$0001
C2/E269: AA           TAX 
C2/E26A: E2 20        SEP #$20
C2/E26C: B5 E5        LDA $E5,X
C2/E26E: F0 0B        BEQ $E27B
C2/E270: C9 01        CMP #$01
C2/E272: F0 0F        BEQ $E283
C2/E274: A9 00        LDA #$00
C2/E276: 99 E5 01     STA $01E5,Y
C2/E279: 80 08        BRA $E283
C2/E27B: B5 E3        LDA $E3,X
C2/E27D: D0 04        BNE $E283
C2/E27F: A9 01        LDA #$01
C2/E281: 95 E5        STA $E5,X
C2/E283: 28           PLP 
C2/E284: AB           PLB 
C2/E285: 60           RTS 
C2/E286: 8B           PHB 
C2/E287: DA           PHX 
C2/E288: 08           PHP 
C2/E289: F4 7E 7E     PEA $7E7E
C2/E28C: AB           PLB 
C2/E28D: AB           PLB 
C2/E28E: E2 20        SEP #$20
C2/E290: 64 90        STZ $90
C2/E292: C9 00        CMP #$00
C2/E294: F0 34        BEQ $E2CA
C2/E296: C9 01        CMP #$01
C2/E298: F0 30        BEQ $E2CA
C2/E29A: C9 80        CMP #$80
C2/E29C: F0 2C        BEQ $E2CA
C2/E29E: A6 8E        LDX $8E
C2/E2A0: DD 40 06     CMP $0640,X
C2/E2A3: F0 08        BEQ $E2AD
C2/E2A5: E8           INX 
C2/E2A6: E0 00 01     CPX #$0100
C2/E2A9: F0 0E        BEQ $E2B9
C2/E2AB: 80 F3        BRA $E2A0
C2/E2AD: BD 40 07     LDA $0740,X
C2/E2B0: 1A           INC 
C2/E2B1: C9 64        CMP #$64
C2/E2B3: 30 15        BMI $E2CA
C2/E2B5: E6 90        INC $90
C2/E2B7: 80 11        BRA $E2CA
C2/E2B9: A6 8E        LDX $8E
C2/E2BB: BD 40 06     LDA $0640,X
C2/E2BE: F0 0A        BEQ $E2CA
C2/E2C0: E8           INX 
C2/E2C1: E0 00 01     CPX #$0100
C2/E2C4: D0 F5        BNE $E2BB
C2/E2C6: E6 90        INC $90
C2/E2C8: E6 90        INC $90
C2/E2CA: 28           PLP 
C2/E2CB: FA           PLX 
C2/E2CC: AB           PLB 
C2/E2CD: 60           RTS 

; [  ]
C2/E2CE: 8B           PHB 
C2/E2CF: DA           PHX 
C2/E2D0: 08           PHP 
C2/E2D1: F4 7E 7E     PEA $7E7E
C2/E2D4: AB           PLB 
C2/E2D5: AB           PLB 
C2/E2D6: E2 20        SEP #$20
C2/E2D8: 64 90        STZ $90
C2/E2DA: C9 00        CMP #$00
C2/E2DC: F0 46        BEQ $E324
C2/E2DE: C9 01        CMP #$01
C2/E2E0: F0 42        BEQ $E324
C2/E2E2: C9 80        CMP #$80
C2/E2E4: F0 3E        BEQ $E324
C2/E2E6: A6 8E        LDX $8E
C2/E2E8: DD 40 06     CMP $0640,X
C2/E2EB: F0 08        BEQ $E2F5
C2/E2ED: E8           INX 
C2/E2EE: E0 00 01     CPX #$0100
C2/E2F1: F0 12        BEQ $E305
C2/E2F3: 80 F3        BRA $E2E8
C2/E2F5: EB           XBA 
C2/E2F6: 18           CLC 
C2/E2F7: 7D 40 07     ADC $0740,X
C2/E2FA: C9 64        CMP #$64
C2/E2FC: 30 02        BMI $E300
C2/E2FE: A9 63        LDA #$63
C2/E300: 9D 40 07     STA $0740,X
C2/E303: 80 1F        BRA $E324
C2/E305: A6 8E        LDX $8E
C2/E307: 48           PHA 
C2/E308: BD 40 06     LDA $0640,X
C2/E30B: F0 08        BEQ $E315
C2/E30D: E8           INX 
C2/E30E: E0 00 01     CPX #$0100
C2/E311: F0 0C        BEQ $E31F
C2/E313: 80 F3        BRA $E308
C2/E315: 68           PLA 
C2/E316: 9D 40 06     STA $0640,X
C2/E319: EB           XBA 
C2/E31A: 9D 40 07     STA $0740,X
C2/E31D: 80 05        BRA $E324
C2/E31F: 68           PLA 
C2/E320: E6 90        INC $90
C2/E322: E6 90        INC $90
C2/E324: 28           PLP 
C2/E325: FA           PLX 
C2/E326: AB           PLB 
C2/E327: 60           RTS 

; [  ]

C2/E328: 8B           PHB 
C2/E329: DA           PHX 
C2/E32A: 08           PHP 
C2/E32B: F4 7E 7E     PEA $7E7E
C2/E32E: AB           PLB 
C2/E32F: AB           PLB 
C2/E330: E2 20        SEP #$20
C2/E332: 64 90        STZ $90
C2/E334: A6 8E        LDX $8E
C2/E336: DD 40 06     CMP $0640,X
C2/E339: F0 08        BEQ $E343
C2/E33B: E8           INX 
C2/E33C: E0 00 01     CPX #$0100
C2/E33F: F0 20        BEQ $E361
C2/E341: 80 F3        BRA $E336
C2/E343: EB           XBA 
C2/E344: 48           PHA 
C2/E345: 38           SEC 
C2/E346: BD 40 07     LDA $0740,X
C2/E349: E3 01        SBC $01,S
C2/E34B: 10 03        BPL $E350
C2/E34D: 68           PLA 
C2/E34E: 80 11        BRA $E361
C2/E350: 9D 40 07     STA $0740,X
C2/E353: 68           PLA 
C2/E354: BD 40 07     LDA $0740,X
C2/E357: D0 0A        BNE $E363
C2/E359: 9E 40 06     STZ $0640,X
C2/E35C: 9E 8A 28     STZ $288A,X
C2/E35F: 80 02        BRA $E363
C2/E361: E6 90        INC $90
C2/E363: 28           PLP 
C2/E364: FA           PLX 
C2/E365: AB           PLB 
C2/E366: 60           RTS 
C2/E367: 08           PHP 
C2/E368: C2 20        REP #$20
C2/E36A: A5 6D        LDA $6D
C2/E36C: F0 26        BEQ $E394
C2/E36E: A4 8E        LDY $8E
C2/E370: A5 6B        LDA $6B
C2/E372: F0 06        BEQ $E37A
C2/E374: C5 6D        CMP $6D
C2/E376: F0 01        BEQ $E379
C2/E378: C8           INY 
C2/E379: C8           INY 
C2/E37A: 98           TYA 
C2/E37B: 0A           ASL 
C2/E37C: 0A           ASL 
C2/E37D: A8           TAY 
C2/E37E: AF B6 29 7E  LDA $7E29B6
C2/E382: 29 0F 00     AND #$000F
C2/E385: 0A           ASL 
C2/E386: 0A           ASL 
C2/E387: AA           TAX 
C2/E388: DA           PHX 
C2/E389: 20 96 E3     JSR $E396
C2/E38C: C8           INY 
C2/E38D: C8           INY 
C2/E38E: FA           PLX 
C2/E38F: E8           INX 
C2/E390: E8           INX 
C2/E391: 20 96 E3     JSR $E396
C2/E394: 28           PLP 
C2/E395: 60           RTS 
C2/E396: BF C6 E9 C0  LDA $C0E9C6,X
C2/E39A: 48           PHA 
C2/E39B: BB           TYX 
C2/E39C: BF D6 E9 C0  LDA $C0E9D6,X
C2/E3A0: FA           PLX 
C2/E3A1: 9F 00 00 7E  STA $7E0000,X
C2/E3A5: 60           RTS 
C2/E3A6: 8B           PHB 
C2/E3A7: 08           PHP 
C2/E3A8: F4 7E 7E     PEA $7E7E
C2/E3AB: AB           PLB 
C2/E3AC: AB           PLB 
C2/E3AD: E2 20        SEP #$20
C2/E3AF: 85 91        STA $91
C2/E3B1: EB           XBA 
C2/E3B2: 85 92        STA $92
C2/E3B4: A5 92        LDA $92
C2/E3B6: F0 1C        BEQ $E3D4
C2/E3B8: A5 91        LDA $91
C2/E3BA: F0 18        BEQ $E3D4
C2/E3BC: 20 4E E4     JSR $E44E
C2/E3BF: C2 20        REP #$20
C2/E3C1: A9 CF 00     LDA #$00CF
C2/E3C4: 9D 00 00     STA $0000,X
C2/E3C7: E8           INX 
C2/E3C8: E8           INX 
C2/E3C9: A0 92 01     LDY #$0192
C2/E3CC: A9 21 00     LDA #$0021
C2/E3CF: 20 ED E4     JSR $E4ED
C2/E3D2: 80 0C        BRA $E3E0
C2/E3D4: C2 20        REP #$20
C2/E3D6: BB           TYX 
C2/E3D7: A0 59 EF     LDY #$EF59
C2/E3DA: A9 0C C0     LDA #$C00C
C2/E3DD: 20 9D E5     JSR $E59D
C2/E3E0: 28           PLP 
C2/E3E1: AB           PLB 
C2/E3E2: 60           RTS 
C2/E3E3: 08           PHP 
C2/E3E4: E2 20        SEP #$20
C2/E3E6: BD 00 7A     LDA $7A00,X
C2/E3E9: EB           XBA 
C2/E3EA: BD 00 7B     LDA $7B00,X
C2/E3ED: EB           XBA 
C2/E3EE: 20 A6 E3     JSR $E3A6
C2/E3F1: 28           PLP 
C2/E3F2: 60           RTS 
C2/E3F3: 5A           PHY 
C2/E3F4: 20 E3 E3     JSR $E3E3
C2/E3F7: 7A           PLY 
C2/E3F8: 08           PHP 
C2/E3F9: C2 20        REP #$20
C2/E3FB: A5 54        LDA $54
C2/E3FD: 29 FF 00     AND #$00FF
C2/E400: C9 16 00     CMP #$0016
C2/E403: F0 25        BEQ $E42A
C2/E405: A5 91        LDA $91
C2/E407: 29 FF 00     AND #$00FF
C2/E40A: C9 E0 00     CMP #$00E0
C2/E40D: 30 12        BMI $E421
C2/E40F: E2 20        SEP #$20
C2/E411: A6 8E        LDX $8E
C2/E413: BF D2 EE C0  LDA $C0EED2,X
C2/E417: F0 08        BEQ $E421
C2/E419: C5 91        CMP $91
C2/E41B: F0 0D        BEQ $E42A
C2/E41D: E8           INX 
C2/E41E: E8           INX 
C2/E41F: 80 F2        BRA $E413
C2/E421: BB           TYX 
C2/E422: C2 20        REP #$20
C2/E424: A9 0C 01     LDA #$010C
C2/E427: 20 DC D6     JSR $D6DC
C2/E42A: 28           PLP 
C2/E42B: 60           RTS 

; [ draw spell name ]

;  A: spell id
; +Y: destination address

C2/E42C: 08           PHP 
C2/E42D: C2 20        REP #$20
C2/E42F: 29 FF 00     AND #$00FF
C2/E432: 48           PHA 
C2/E433: 0A           ASL 
C2/E434: AA           TAX 
C2/E435: BF 00 D4 7E  LDA $7ED400,X   ; pointer to spell name ???
C2/E439: BB           TYX 
C2/E43A: A8           TAY 
C2/E43B: 68           PLA 
C2/E43C: C9 57 00     CMP #$0057
C2/E43F: 10 05        BPL $E446
C2/E441: A9 06 D1     LDA #$D106      ; spells $00-$56: 6 bytes each
C2/E444: 80 03        BRA $E449
C2/E446: A9 08 D1     LDA #$D108      ; spells $57-...: 8 bytes each
C2/E449: 20 9D E5     JSR $E59D
C2/E44C: 28           PLP 
C2/E44D: 60           RTS 

; [ draw item name ]

C2/E44E: 08           PHP 
C2/E44F: C2 20        REP #$20
C2/E451: 29 FF 00     AND #$00FF
C2/E454: 0A           ASL 
C2/E455: AA           TAX 
C2/E456: BF 00 D2 7E  LDA $7ED200,X   ; pointer to item name ???
C2/E45A: BB           TYX 
C2/E45B: A8           TAY 
C2/E45C: A9 09 D1     LDA #$D109
C2/E45F: 20 9D E5     JSR $E59D
C2/E462: 28           PLP 
C2/E463: 60           RTS 

C2/E464: 8B           PHB 
C2/E465: 08           PHP 
C2/E466: A5 D8        LDA $D8
C2/E468: 20 B2 E4     JSR $E4B2
C2/E46B: A5 DA        LDA $DA
C2/E46D: 29 0F        AND #$0F
C2/E46F: 00 0A        BRK $0A
C2/E471: 0A           ASL 
C2/E472: 0A           ASL 
C2/E473: 0A           ASL 
C2/E474: EB           XBA 
C2/E475: 05 DC        ORA $DC
C2/E477: 9D 43 08     STA $0843,X
C2/E47A: 28           PLP 
C2/E47B: AB           PLB 
C2/E47C: 60           RTS 

; [ get character job data ]

; +$7E: character index
; +$D8: job index
; +$DA: job level (out)
; +$DC: current abp (out)
; +$DE: abp to next level (out)

C2/E47D: 8B           PHB 
C2/E47E: 08           PHP 
C2/E47F: C2 20        REP #$20
C2/E481: A5 D8        LDA $D8
C2/E483: 20 B2 E4     JSR $E4B2       ; get pointer to character job data
C2/E486: BD 43 08     LDA $0843,X     ; job level/abp
C2/E489: 48           PHA 
C2/E48A: 29 FF 0F     AND #$0FFF      ; abp
C2/E48D: 85 DC        STA $DC
C2/E48F: 68           PLA 
C2/E490: EB           XBA 
C2/E491: 4A           LSR 
C2/E492: 4A           LSR 
C2/E493: 4A           LSR 
C2/E494: 4A           LSR 
C2/E495: 29 0F 00     AND #$000F
C2/E498: 85 DA        STA $DA
C2/E49A: A5 D8        LDA $D8
C2/E49C: 0A           ASL 
C2/E49D: AA           TAX 
C2/E49E: A5 DA        LDA $DA
C2/E4A0: 0A           ASL 
C2/E4A1: 18           CLC 
C2/E4A2: 65 DA        ADC $DA
C2/E4A4: 7F C0 52 D1  ADC $D152C0,X   ; pointers to job ability data
C2/E4A8: AA           TAX 
C2/E4A9: BF 00 00 D1  LDA $D10000,X   ; number of ability points to next level
C2/E4AD: 85 DE        STA $DE
C2/E4AF: 28           PLP 
C2/E4B0: AB           PLB 
C2/E4B1: 60           RTS 

; [ get pointer to character job data ]

C2/E4B2: 08           PHP 
C2/E4B3: C2 20        REP #$20
C2/E4B5: 29 FF 00     AND #$00FF
C2/E4B8: 48           PHA 
C2/E4B9: A5 7E        LDA $7E
C2/E4BB: 0A           ASL 
C2/E4BC: AA           TAX 
C2/E4BD: 68           PLA 
C2/E4BE: 0A           ASL 
C2/E4BF: 18           CLC 
C2/E4C0: 7F 65 EF C0  ADC $C0EF65,X   ; pointers to character job data (+$0843)
C2/E4C4: AA           TAX 
C2/E4C5: 28           PLP 
C2/E4C6: 60           RTS 

C2/E4C7: 08           PHP 
C2/E4C8: C2 20        REP #$20
C2/E4CA: 29 1F 00     AND #$001F
C2/E4CD: 0A           ASL 
C2/E4CE: 0A           ASL 
C2/E4CF: 0A           ASL 
C2/E4D0: 18           CLC 
C2/E4D1: 69 00 56     ADC #$5600
C2/E4D4: AA           TAX 
C2/E4D5: BB           TYX 
C2/E4D6: A8           TAY 
C2/E4D7: A9 07 D1     LDA #$D107
C2/E4DA: 20 9D E5     JSR $E59D
C2/E4DD: 28           PLP 
C2/E4DE: 60           RTS 

; [ get pointer to current cursor data ]

C2/E4DF: A5 53        LDA $53         ; current cursor position
C2/E4E1: 08           PHP 
C2/E4E2: C2 20        REP #$20
C2/E4E4: 29 FF 00     AND #$00FF
C2/E4E7: 0A           ASL             ; 8 bytes each
C2/E4E8: 0A           ASL 
C2/E4E9: 0A           ASL 
C2/E4EA: AA           TAX 
C2/E4EB: 28           PLP 
C2/E4EC: 60           RTS 

; [  ]

C2/E4ED: 8B           PHB 
C2/E4EE: 48           PHA 
C2/E4EF: DA           PHX 
C2/E4F0: 5A           PHY 
C2/E4F1: 08           PHP 
C2/E4F2: C2 30        REP #$30
C2/E4F4: 64 D2        STZ $D2
C2/E4F6: 64 D4        STZ $D4
C2/E4F8: 86 D6        STX $D6
C2/E4FA: E2 20        SEP #$20
C2/E4FC: EB           XBA 
C2/E4FD: 48           PHA 
C2/E4FE: AB           PLB 
C2/E4FF: EB           XBA 
C2/E500: AA           TAX 
C2/E501: 4A           LSR 
C2/E502: 4A           LSR 
C2/E503: 4A           LSR 
C2/E504: 4A           LSR 
C2/E505: 29 07        AND #$07
C2/E507: 85 CE        STA $CE
C2/E509: 8A           TXA 
C2/E50A: 29 0F        AND #$0F
C2/E50C: 85 CD        STA $CD
C2/E50E: 8A           TXA 
C2/E50F: 49 80        EOR #$80
C2/E511: 85 D1        STA $D1
C2/E513: A6 8E        LDX $8E
C2/E515: B9 00 00     LDA $0000,Y
C2/E518: 5A           PHY 
C2/E519: C2 20        REP #$20
C2/E51B: 29 FF 00     AND #$00FF
C2/E51E: 85 CB        STA $CB
C2/E520: A0 08 00     LDY #$0008
C2/E523: 46 CB        LSR $CB
C2/E525: 90 13        BCC $E53A
C2/E527: F8           SED 
C2/E528: 18           CLC 
C2/E529: BF 87 F8 C0  LDA $C0F887,X
C2/E52D: 65 D2        ADC $D2
C2/E52F: 85 D2        STA $D2
C2/E531: BF 89 F8 C0  LDA $C0F889,X
C2/E535: 65 D4        ADC $D4
C2/E537: 85 D4        STA $D4
C2/E539: D8           CLD 
C2/E53A: E8           INX 
C2/E53B: E8           INX 
C2/E53C: E8           INX 
C2/E53D: E8           INX 
C2/E53E: 88           DEY 
C2/E53F: D0 E2        BNE $E523
C2/E541: 7A           PLY 
C2/E542: E2 20        SEP #$20
C2/E544: C8           INY 
C2/E545: C6 CD        DEC $CD
C2/E547: D0 CC        BNE $E515
C2/E549: 20 52 E5     JSR $E552
C2/E54C: 28           PLP 
C2/E54D: 7A           PLY 
C2/E54E: FA           PLX 
C2/E54F: 68           PLA 
C2/E550: AB           PLB 
C2/E551: 60           RTS 

; [  ]

C2/E552: E2 20        SEP #$20
C2/E554: A9 7E        LDA #$7E
C2/E556: 48           PHA 
C2/E557: AB           PLB 
C2/E558: A4 D6        LDY $D6
C2/E55A: A9 00        LDA #$00
C2/E55C: EB           XBA 
C2/E55D: A5 CE        LDA $CE
C2/E55F: 3A           DEC 
C2/E560: 29 07        AND #$07
C2/E562: 4A           LSR 
C2/E563: AA           TAX 
C2/E564: 90 09        BCC $E56F
C2/E566: B5 D2        LDA $D2,X
C2/E568: 4A           LSR 
C2/E569: 4A           LSR 
C2/E56A: 4A           LSR 
C2/E56B: 4A           LSR 
C2/E56C: 20 7F E5     JSR $E57F
C2/E56F: E0 00 00     CPX #$0000
C2/E572: D0 02        BNE $E576
C2/E574: 64 D1        STZ $D1
C2/E576: B5 D2        LDA $D2,X
C2/E578: 20 7F E5     JSR $E57F
C2/E57B: CA           DEX 
C2/E57C: 10 E8        BPL $E566
C2/E57E: 60           RTS 
C2/E57F: 29 0F        AND #$0F
C2/E581: D0 08        BNE $E58B
C2/E583: 24 D1        BIT $D1
C2/E585: 10 04        BPL $E58B
C2/E587: A9 FF        LDA #$FF
C2/E589: 80 05        BRA $E590
C2/E58B: 64 D1        STZ $D1
C2/E58D: 18           CLC 
C2/E58E: 69 53        ADC #$53
C2/E590: C2 20        REP #$20
C2/E592: 29 FF 00     AND #$00FF
C2/E595: 99 00 00     STA $0000,Y
C2/E598: C8           INY 
C2/E599: C8           INY 
C2/E59A: E2 20        SEP #$20
C2/E59C: 60           RTS 

; [ draw text ]

;  A: text length (msb does something)
;  B: source bank
; +Y: source address
; +X: destination address

C2/E59D: 8B           PHB 
C2/E59E: 08           PHP 
C2/E59F: E2 20        SEP #$20
C2/E5A1: EB           XBA 
C2/E5A2: 48           PHA 
C2/E5A3: AB           PLB 
C2/E5A4: EB           XBA 
C2/E5A5: 48           PHA 
C2/E5A6: 29 7F        AND #$7F
C2/E5A8: 85 7B        STA $7B         ; length
C2/E5AA: 64 7C        STZ $7C
C2/E5AC: 68           PLA 
C2/E5AD: 64 79        STZ $79
C2/E5AF: 64 7A        STZ $7A
C2/E5B1: 29 80        AND #$80
C2/E5B3: 85 7D        STA $7D
C2/E5B5: 30 02        BMI $E5B9
C2/E5B7: C6 7A        DEC $7A
C2/E5B9: E2 20        SEP #$20
C2/E5BB: B9 00 00     LDA $0000,Y
C2/E5BE: F0 2A        BEQ $E5EA
C2/E5C0: C8           INY 
C2/E5C1: 24 7D        BIT $7D
C2/E5C3: 30 16        BMI $E5DB
C2/E5C5: 20 ED E5     JSR $E5ED       ; get dakuten
C2/E5C8: 48           PHA 
C2/E5C9: 29 FF 00     AND #$00FF
C2/E5CC: 9F 00 00 7E  STA $7E0000,X
C2/E5D0: 68           PLA 
C2/E5D1: EB           XBA 
C2/E5D2: 29 FF 00     AND #$00FF
C2/E5D5: 9F C0 FF 7D  STA $7DFFC0,X   ; dakuten
C2/E5D9: 80 09        BRA $E5E4
C2/E5DB: C2 20        REP #$20
C2/E5DD: 29 FF 00     AND #$00FF
C2/E5E0: 9F 00 00 7E  STA $7E0000,X
C2/E5E4: E8           INX 
C2/E5E5: E8           INX 
C2/E5E6: C6 7B        DEC $7B
C2/E5E8: D0 CF        BNE $E5B9
C2/E5EA: 28           PLP 
C2/E5EB: AB           PLB 
C2/E5EC: 60           RTS 

; [ get dakuten ]

C2/E5ED: C2 20        REP #$20
C2/E5EF: 29 FF 00     AND #$00FF
C2/E5F2: C9 53 00     CMP #$0053
C2/E5F5: 10 16        BPL $E60D
C2/E5F7: C9 49 00     CMP #$0049
C2/E5FA: 10 0B        BPL $E607
C2/E5FC: C9 20 00     CMP #$0020
C2/E5FF: 30 0C        BMI $E60D
C2/E601: 18           CLC 
C2/E602: 69 40 51     ADC #$5140
C2/E605: 80 08        BRA $E60F
C2/E607: 18           CLC 
C2/E608: 69 17 52     ADC #$5217
C2/E60B: 80 02        BRA $E60F
C2/E60D: 05 79        ORA $79
C2/E60F: 60           RTS 

C2/E610: 8B           PHB 
C2/E611: 08           PHP 
C2/E612: F4 7E 7E     PEA $7E7E
C2/E615: AB           PLB 
C2/E616: AB           PLB 
C2/E617: C2 20        REP #$20
C2/E619: 85 85        STA $85
C2/E61B: A5 85        LDA $85
C2/E61D: F0 31        BEQ $E650
C2/E61F: C9 01 00     CMP #$0001
C2/E622: F0 1C        BEQ $E640
C2/E624: BD 00 00     LDA $0000,X
C2/E627: 85 87        STA $87
C2/E629: B9 00 00     LDA $0000,Y
C2/E62C: 9D 00 00     STA $0000,X
C2/E62F: A5 87        LDA $87
C2/E631: 99 00 00     STA $0000,Y
C2/E634: E8           INX 
C2/E635: E8           INX 
C2/E636: C8           INY 
C2/E637: C8           INY 
C2/E638: A5 85        LDA $85
C2/E63A: 3A           DEC 
C2/E63B: 3A           DEC 
C2/E63C: 85 85        STA $85
C2/E63E: 80 DD        BRA $E61D
C2/E640: E2 20        SEP #$20
C2/E642: BD 00 00     LDA $0000,X
C2/E645: EB           XBA 
C2/E646: B9 00 00     LDA $0000,Y
C2/E649: 9D 00 00     STA $0000,X
C2/E64C: EB           XBA 
C2/E64D: 99 00 00     STA $0000,Y
C2/E650: 28           PLP 
C2/E651: AB           PLB 
C2/E652: 60           RTS 

; [  ]

C2/E653: A2 14 00     LDX #$0014
C2/E656: 80 03        BRA $E65B
C2/E658: A2 28 00     LDX #$0028
C2/E65B: 08           PHP 
C2/E65C: C2 20        REP #$20
C2/E65E: 48           PHA 
C2/E65F: 20 6F E6     JSR $E66F
C2/E662: A5 0A        LDA $0A
C2/E664: 29 80 80     AND #$8080
C2/E667: D0 03        BNE $E66C
C2/E669: CA           DEX 
C2/E66A: D0 F3        BNE $E65F
C2/E66C: 68           PLA 
C2/E66D: 28           PLP 
C2/E66E: 60           RTS 

; [  ]

C2/E66F: 08           PHP 
C2/E670: E2 20        SEP #$20
C2/E672: A9 80        LDA #$80
C2/E674: 85 C9        STA $C9
C2/E676: 24 C9        BIT $C9
C2/E678: 30 FC        BMI $E676
C2/E67A: 28           PLP 
C2/E67B: 60           RTS 

; [  ]

C2/E67C: 08           PHP 
C2/E67D: C2 20        REP #$20
C2/E67F: A5 54        LDA $54
C2/E681: 29 FF 00     AND #$00FF
C2/E684: AA           TAX 
C2/E685: E2 20        SEP #$20
C2/E687: AF 73 09 00  LDA $000973     ; cursor setting (reset/memory)
C2/E68B: 29 04        AND #$04
C2/E68D: D0 08        BNE $E697
C2/E68F: BF E2 E9 C0  LDA $C0E9E2,X
C2/E693: 85 53        STA $53
C2/E695: 80 12        BRA $E6A9
C2/E697: BF F3 E9 C0  LDA $C0E9F3,X
C2/E69B: F0 F2        BEQ $E68F
C2/E69D: C2 20        REP #$20
C2/E69F: 29 FF 00     AND #$00FF
C2/E6A2: AA           TAX 
C2/E6A3: E2 20        SEP #$20
C2/E6A5: B5 00        LDA $00,X
C2/E6A7: 85 53        STA $53         ; current cursor position
C2/E6A9: 28           PLP 
C2/E6AA: 60           RTS 

; [ update cursor sprite ]

C2/E6AB: 8B           PHB 
C2/E6AC: 08           PHP 
C2/E6AD: E2 20        SEP #$20
C2/E6AF: A9 7E        LDA #$7E
C2/E6B1: 48           PHA 
C2/E6B2: AB           PLB 
C2/E6B3: 20 DF E4     JSR $E4DF       ; get pointer to current cursor data
C2/E6B6: C2 20        REP #$20
C2/E6B8: BD 02 76     LDA $7602,X     ; xy position
C2/E6BB: 8D 00 02     STA $0200
C2/E6BE: A9 02 2E     LDA #$2E02      ; priority 2, palette 7, tile 2
C2/E6C1: 8D 02 02     STA $0202
C2/E6C4: E2 20        SEP #$20
C2/E6C6: BD 00 76     LDA $7600,X
C2/E6C9: 85 54        STA $54
C2/E6CB: BD 01 76     LDA $7601,X
C2/E6CE: 85 55        STA $55
C2/E6D0: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/E6D3: 28           PLP 
C2/E6D4: AB           PLB 
C2/E6D5: 60           RTS 

; [  ]

C2/E6D6: 20 BD EB     JSR $EBBD
C2/E6D9: 20 6C E7     JSR $E76C
C2/E6DC: 20 CE E9     JSR $E9CE
C2/E6DF: 60           RTS 

; [ update spell levels ]

C2/E6E0: 8B           PHB 
C2/E6E1: 08           PHP 
C2/E6E2: E2 20        SEP #$20
C2/E6E4: A9 7E        LDA #$7E
C2/E6E6: 48           PHA 
C2/E6E7: AB           PLB 
C2/E6E8: 64 E0        STZ $E0         ; clear all spell levels
C2/E6EA: 64 E1        STZ $E1
C2/E6EC: 64 E2        STZ $E2
C2/E6EE: 64 E3        STZ $E3
C2/E6F0: 64 E4        STZ $E4
C2/E6F2: 64 E5        STZ $E5
C2/E6F4: A9 04        LDA #$04        ; loop through all 4 battle command slots
C2/E6F6: 85 E6        STA $E6
C2/E6F8: A4 80        LDY $80
C2/E6FA: A6 8E        LDX $8E
C2/E6FC: B9 16 05     LDA $0516,Y     ; battle command
C2/E6FF: 30 45        BMI $E746
C2/E701: C9 2C        CMP #$2C
C2/E703: 30 41        BMI $E746
C2/E705: C9 49        CMP #$49
C2/E707: 10 22        BPL $E72B

; spellblade, white, black, time, summon magic
C2/E709: 38           SEC 
C2/E70A: E9 2C        SBC #$2C
C2/E70C: C2 20        REP #$20
C2/E70E: 29 FF 00     AND #$00FF
C2/E711: AA           TAX 
C2/E712: BF 31 E9 C0  LDA $C0E931,X   ; spell level / spell type (lo/hi nybble)
C2/E716: 29 0F 00     AND #$000F
C2/E719: 48           PHA 
C2/E71A: BF 31 E9 C0  LDA $C0E931,X
C2/E71E: 4A           LSR 
C2/E71F: 4A           LSR 
C2/E720: 4A           LSR 
C2/E721: 4A           LSR 
C2/E722: 29 0F 00     AND #$000F
C2/E725: AA           TAX 
C2/E726: 68           PLA 
C2/E727: E2 20        SEP #$20
C2/E729: 80 18        BRA $E743

C2/E72B: C9 4C        CMP #$4C        ; x-magic
C2/E72D: F0 10        BEQ $E73F
C2/E72F: 10 15        BPL $E746

; red magic
C2/E731: 38           SEC 
C2/E732: E9 48        SBC #$48        ; red mage spell level
C2/E734: A2 01 00     LDX #$0001      ; white
C2/E737: 20 65 E7     JSR $E765
C2/E73A: A2 02 00     LDX #$0002      ; black
C2/E73D: 80 04        BRA $E743

; x-magic
C2/E73F: A9 03        LDA #$03        ; use spell level 3 (black and white)
C2/E741: 80 F1        BRA $E734
C2/E743: 20 65 E7     JSR $E765
C2/E746: C8           INY             ; next command slot
C2/E747: C6 E6        DEC $E6
C2/E749: D0 B1        BNE $E6FC
C2/E74B: A4 80        LDY $80
C2/E74D: A6 8E        LDX $8E
C2/E74F: B5 E0        LDA $E0,X
C2/E751: 0A           ASL 
C2/E752: 0A           ASL 
C2/E753: 0A           ASL 
C2/E754: 0A           ASL 
C2/E755: 15 E1        ORA $E1,X
C2/E757: 99 3D 05     STA $053D,Y     ; spell level
C2/E75A: C8           INY 
C2/E75B: E8           INX 
C2/E75C: E8           INX 
C2/E75D: E0 06 00     CPX #$0006
C2/E760: D0 ED        BNE $E74F
C2/E762: 28           PLP 
C2/E763: AB           PLB 
C2/E764: 60           RTS 

; [ set spell level ]

C2/E765: D5 E0        CMP $E0,X       ; use highest level found so far
C2/E767: 30 02        BMI $E76B
C2/E769: 95 E0        STA $E0,X
C2/E76B: 60           RTS 

; [ update character properties ]

C2/E76C: 8B           PHB 
C2/E76D: 08           PHP 
C2/E76E: E2 20        SEP #$20
C2/E770: A9 7E        LDA #$7E
C2/E772: 48           PHA 
C2/E773: AB           PLB 
C2/E774: 20 73 E9     JSR $E973
C2/E777: 20 33 E9     JSR $E933
C2/E77A: 20 79 E8     JSR $E879
C2/E77D: 20 C5 D4     JSR $D4C5
C2/E780: 20 78 E1     JSR $E178
C2/E783: 20 B3 E7     JSR $E7B3
C2/E786: 20 CC E7     JSR $E7CC
C2/E789: A4 80        LDY $80
C2/E78B: C2 20        REP #$20
C2/E78D: A5 EB        LDA $EB         ; update stats
C2/E78F: 99 28 05     STA $0528,Y
C2/E792: A5 ED        LDA $ED
C2/E794: 99 2A 05     STA $052A,Y
C2/E797: A5 F2        LDA $F2
C2/E799: 99 2C 05     STA $052C,Y
C2/E79C: A5 F4        LDA $F4
C2/E79E: 99 2E 05     STA $052E,Y
C2/E7A1: A5 F6        LDA $F6         ; update attack power
C2/E7A3: 99 44 05     STA $0544,Y
C2/E7A6: E2 20        SEP #$20
C2/E7A8: A5 F1        LDA $F1         ; update equipment weight
C2/E7AA: 99 23 05     STA $0523,Y
C2/E7AD: 20 E0 E6     JSR $E6E0       ; update spell levels
C2/E7B0: 28           PLP 
C2/E7B1: AB           PLB 
C2/E7B2: 60           RTS 

; [  ]

C2/E7B3: 08           PHP 
C2/E7B4: A6 80        LDX $80
C2/E7B6: C2 20        REP #$20
C2/E7B8: BF 24 05 00  LDA $000524,X   ; get base stats
C2/E7BC: 85 E7        STA $E7
C2/E7BE: BF 26 05 00  LDA $000526,X
C2/E7C2: 85 E9        STA $E9
C2/E7C4: BF 20 05 00  LDA $000520,X
C2/E7C8: 85 EF        STA $EF
C2/E7CA: 28           PLP 
C2/E7CB: 60           RTS 

; [  ]

C2/E7CC: 8B           PHB 
C2/E7CD: 08           PHP 
C2/E7CE: E2 20        SEP #$20
C2/E7D0: 64 F1        STZ $F1
C2/E7D2: 64 F2        STZ $F2
C2/E7D4: 64 F3        STZ $F3
C2/E7D6: 64 F4        STZ $F4
C2/E7D8: 64 F5        STZ $F5
C2/E7DA: A6 8E        LDX $8E
C2/E7DC: B5 E0        LDA $E0,X
C2/E7DE: DA           PHX 
C2/E7DF: 20 AB D9     JSR $D9AB
C2/E7E2: 9B           TXY 
C2/E7E3: FA           PLX 
C2/E7E4: A5 9C        LDA $9C
C2/E7E6: 18           CLC 
C2/E7E7: 65 F1        ADC $F1
C2/E7E9: 85 F1        STA $F1
C2/E7EB: A5 A1        LDA $A1
C2/E7ED: 18           CLC 
C2/E7EE: 65 F2        ADC $F2
C2/E7F0: 85 F2        STA $F2
C2/E7F2: A5 A2        LDA $A2
C2/E7F4: 18           CLC 
C2/E7F5: 65 F3        ADC $F3
C2/E7F7: 85 F3        STA $F3
C2/E7F9: A5 A3        LDA $A3
C2/E7FB: 18           CLC 
C2/E7FC: 65 F4        ADC $F4
C2/E7FE: 85 F4        STA $F4
C2/E800: A5 A4        LDA $A4
C2/E802: 18           CLC 
C2/E803: 65 F5        ADC $F5
C2/E805: 85 F5        STA $F5
C2/E807: E8           INX 
C2/E808: E0 05 00     CPX #$0005
C2/E80B: D0 CF        BNE $E7DC
C2/E80D: 64 F8        STZ $F8
C2/E80F: A5 F0        LDA $F0
C2/E811: 29 20        AND #$20
C2/E813: F0 12        BEQ $E827
C2/E815: A5 E3        LDA $E3
C2/E817: 05 E4        ORA $E4
C2/E819: D0 0C        BNE $E827
C2/E81B: A5 E5        LDA $E5
C2/E81D: F0 04        BEQ $E823
C2/E81F: A5 E6        LDA $E6
C2/E821: D0 04        BNE $E827
C2/E823: A9 80        LDA #$80
C2/E825: 85 F8        STA $F8
C2/E827: 64 F6        STZ $F6
C2/E829: 64 F7        STZ $F7
C2/E82B: A6 8E        LDX $8E
C2/E82D: B5 E5        LDA $E5,X
C2/E82F: DA           PHX 
C2/E830: 20 AB D9     JSR $D9AB
C2/E833: 9B           TXY 
C2/E834: FA           PLX 
C2/E835: A5 A2        LDA $A2
C2/E837: 95 F6        STA $F6,X
C2/E839: 24 9F        BIT $9F
C2/E83B: 50 08        BVC $E845
C2/E83D: A5 F8        LDA $F8
C2/E83F: 10 04        BPL $E845
C2/E841: 09 01        ORA #$01
C2/E843: 85 F8        STA $F8
C2/E845: E8           INX 
C2/E846: E0 02 00     CPX #$0002
C2/E849: D0 E2        BNE $E82D
C2/E84B: E2 20        SEP #$20
C2/E84D: A5 E5        LDA $E5
C2/E84F: C9 01        CMP #$01
C2/E851: D0 08        BNE $E85B
C2/E853: A5 E6        LDA $E6
C2/E855: C9 01        CMP #$01
C2/E857: D0 02        BNE $E85B
C2/E859: 64 F7        STZ $F7
C2/E85B: A5 F6        LDA $F6
C2/E85D: 18           CLC 
C2/E85E: 65 F7        ADC $F7
C2/E860: 85 F6        STA $F6
C2/E862: A5 8E        LDA $8E
C2/E864: 2A           ROL 
C2/E865: 29 01        AND #$01
C2/E867: 85 F7        STA $F7
C2/E869: A5 F8        LDA $F8
C2/E86B: C9 81        CMP #$81
C2/E86D: D0 04        BNE $E873
C2/E86F: 06 F6        ASL $F6
C2/E871: 26 F7        ROL $F7
C2/E873: 20 76 EC     JSR $EC76
C2/E876: 28           PLP 
C2/E877: AB           PLB 
C2/E878: 60           RTS 
C2/E879: 8B           PHB 
C2/E87A: 08           PHP 
C2/E87B: E2 20        SEP #$20
C2/E87D: 64 E0        STZ $E0
C2/E87F: 64 E1        STZ $E1
C2/E881: 64 E2        STZ $E2
C2/E883: 64 E3        STZ $E3
C2/E885: 64 E4        STZ $E4
C2/E887: 64 E5        STZ $E5
C2/E889: 64 E6        STZ $E6
C2/E88B: 64 E7        STZ $E7
C2/E88D: 20 C5 D4     JSR $D4C5
C2/E890: A9 05        LDA #$05
C2/E892: 85 85        STA $85
C2/E894: A6 80        LDX $80
C2/E896: DA           PHX 
C2/E897: BF 0E 05 00  LDA $00050E,X
C2/E89B: 20 AB D9     JSR $D9AB
C2/E89E: A5 9E        LDA $9E
C2/E8A0: 30 02        BMI $E8A4
C2/E8A2: 04 E0        TSB $E0
C2/E8A4: A5 A0        LDA $A0
C2/E8A6: 04 E2        TSB $E2
C2/E8A8: A5 A5        LDA $A5
C2/E8AA: C2 20        REP #$20
C2/E8AC: 29 FF 00     AND #$00FF
C2/E8AF: 48           PHA 
C2/E8B0: 0A           ASL 
C2/E8B1: 0A           ASL 
C2/E8B2: 18           CLC 
C2/E8B3: 63 01        ADC $01,S
C2/E8B5: AA           TAX 
C2/E8B6: 68           PLA 
C2/E8B7: BF 80 25 D1  LDA $D12580,X
C2/E8BB: 04 E3        TSB $E3
C2/E8BD: BF 82 25 D1  LDA $D12582,X
C2/E8C1: 04 E5        TSB $E5
C2/E8C3: E2 20        SEP #$20
C2/E8C5: BF 84 25 D1  LDA $D12584,X
C2/E8C9: 04 E7        TSB $E7
C2/E8CB: FA           PLX 
C2/E8CC: E8           INX 
C2/E8CD: C6 85        DEC $85
C2/E8CF: D0 C5        BNE $E896
C2/E8D1: A6 80        LDX $80
C2/E8D3: A9 02        LDA #$02
C2/E8D5: 85 85        STA $85
C2/E8D7: BF 13 05 00  LDA $000513,X
C2/E8DB: DA           PHX 
C2/E8DC: 20 AB D9     JSR $D9AB
C2/E8DF: FA           PLX 
C2/E8E0: A5 9E        LDA $9E
C2/E8E2: 30 02        BMI $E8E6
C2/E8E4: 04 E0        TSB $E0
C2/E8E6: A5 A0        LDA $A0
C2/E8E8: 04 E1        TSB $E1
C2/E8EA: E8           INX 
C2/E8EB: C6 85        DEC $85
C2/E8ED: D0 E8        BNE $E8D7
C2/E8EF: E2 20        SEP #$20
C2/E8F1: A9 7E        LDA #$7E
C2/E8F3: 48           PHA 
C2/E8F4: AB           PLB 
C2/E8F5: A4 80        LDY $80
C2/E8F7: A5 E0        LDA $E0
C2/E8F9: 99 22 05     STA $0522,Y
C2/E8FC: 5A           PHY 
C2/E8FD: A6 8E        LDX $8E
C2/E8FF: B5 E3        LDA $E3,X
C2/E901: 99 30 05     STA $0530,Y
C2/E904: E8           INX 
C2/E905: C8           INY 
C2/E906: E0 05 00     CPX #$0005
C2/E909: D0 F4        BNE $E8FF
C2/E90B: 7A           PLY 
C2/E90C: C2 20        REP #$20
C2/E90E: A5 E1        LDA $E1
C2/E910: 99 38 05     STA $0538,Y
C2/E913: 28           PLP 
C2/E914: AB           PLB 
C2/E915: 60           RTS 

; [ get job innate abilities ]

C2/E916: 5A           PHY 
C2/E917: DA           PHX 
C2/E918: 29 1F 00     AND #$001F
C2/E91B: C9 14 00     CMP #$0014
C2/E91E: 30 0A        BMI $E92A       ; branch if not mimic or freelancer
C2/E920: A4 80        LDY $80
C2/E922: B9 4E 05     LDA $054E,Y
C2/E925: 29 FF F7     AND #$F7FF
C2/E928: 80 06        BRA $E930
C2/E92A: 0A           ASL 
C2/E92B: AA           TAX 
C2/E92C: BF B8 57 D1  LDA $D157B8,X   ; innate abilities
C2/E930: FA           PLX 
C2/E931: 7A           PLY 
C2/E932: 60           RTS 

; [  ]

C2/E933: 8B           PHB 
C2/E934: 08           PHP 
C2/E935: F4 7E 7E     PEA $7E7E
C2/E938: AB           PLB 
C2/E939: AB           PLB 
C2/E93A: C2 20        REP #$20
C2/E93C: 20 C5 D4     JSR $D4C5
C2/E93F: A4 80        LDY $80
C2/E941: B9 01 05     LDA $0501,Y
C2/E944: 20 16 E9     JSR $E916       ; get job innate abilities
C2/E947: 85 EF        STA $EF
C2/E949: A9 04 00     LDA #$0004
C2/E94C: 85 85        STA $85
C2/E94E: E2 20        SEP #$20
C2/E950: B9 16 05     LDA $0516,Y     ; battle command
C2/E953: C2 20        REP #$20
C2/E955: 10 0B        BPL $E962
C2/E957: 29 7F 00     AND #$007F
C2/E95A: 0A           ASL 
C2/E95B: AA           TAX 
C2/E95C: BF 8C 63 D1  LDA $D1638C,X
C2/E960: 04 EF        TSB $EF
C2/E962: C8           INY 
C2/E963: C6 85        DEC $85
C2/E965: D0 E7        BNE $E94E
C2/E967: A4 80        LDY $80
C2/E969: C2 20        REP #$20
C2/E96B: A5 EF        LDA $EF
C2/E96D: 99 20 05     STA $0520,Y
C2/E970: 28           PLP 
C2/E971: AB           PLB 
C2/E972: 60           RTS 

; [  ]

C2/E973: 8B           PHB 
C2/E974: 08           PHP 
C2/E975: F4 7E 7E     PEA $7E7E
C2/E978: AB           PLB 
C2/E979: AB           PLB 
C2/E97A: C2 20        REP #$20
C2/E97C: 20 C5 D4     JSR $D4C5
C2/E97F: A4 80        LDY $80
C2/E981: B9 01 05     LDA $0501,Y
C2/E984: 29 1F 00     AND #$001F
C2/E987: 0A           ASL 
C2/E988: 0A           ASL 
C2/E989: AA           TAX 
C2/E98A: BF 08 57 D1  LDA $D15708,X
C2/E98E: 85 E0        STA $E0
C2/E990: BF 0A 57 D1  LDA $D1570A,X
C2/E994: 85 E2        STA $E2
C2/E996: A9 04 00     LDA #$0004
C2/E999: 85 85        STA $85
C2/E99B: E2 20        SEP #$20
C2/E99D: B9 16 05     LDA $0516,Y
C2/E9A0: 10 16        BPL $E9B8
C2/E9A2: C2 20        REP #$20
C2/E9A4: 29 7F 00     AND #$007F
C2/E9A7: 0A           ASL 
C2/E9A8: 0A           ASL 
C2/E9A9: AA           TAX 
C2/E9AA: BF CE 63 D1  LDA $D163CE,X
C2/E9AE: 04 E0        TSB $E0
C2/E9B0: BF D0 63 D1  LDA $D163D0,X
C2/E9B4: 04 E2        TSB $E2
C2/E9B6: E2 20        SEP #$20
C2/E9B8: C8           INY 
C2/E9B9: C6 85        DEC $85
C2/E9BB: D0 DE        BNE $E99B
C2/E9BD: A4 80        LDY $80
C2/E9BF: C2 20        REP #$20
C2/E9C1: A5 E0        LDA $E0
C2/E9C3: 99 40 05     STA $0540,Y
C2/E9C6: A5 E2        LDA $E2
C2/E9C8: 99 42 05     STA $0542,Y
C2/E9CB: 28           PLP 
C2/E9CC: AB           PLB 
C2/E9CD: 60           RTS 

; [  ]

C2/E9CE: 8B           PHB 
C2/E9CF: 08           PHP 
C2/E9D0: F4 7E 7E     PEA $7E7E
C2/E9D3: AB           PLB 
C2/E9D4: AB           PLB 
C2/E9D5: 20 C5 D4     JSR $D4C5
C2/E9D8: C2 20        REP #$20
C2/E9DA: A4 80        LDY $80
C2/E9DC: B9 02 05     LDA $0502,Y
C2/E9DF: 29 FF 00     AND #$00FF
C2/E9E2: 3A           DEC 
C2/E9E3: 0A           ASL 
C2/E9E4: AA           TAX 
C2/E9E5: BF 29 51 D1  LDA $D15129,X
C2/E9E9: 85 E0        STA $E0
C2/E9EB: 64 E2        STZ $E2
C2/E9ED: E2 20        SEP #$20
C2/E9EF: B9 26 05     LDA $0526,Y
C2/E9F2: 85 E9        STA $E9
C2/E9F4: 20 AC EA     JSR $EAAC
C2/E9F7: A5 E0        LDA $E0
C2/E9F9: 29 FF        AND #$FF
C2/E9FB: 7F C9 10 27  ADC $2710C9,X
C2/E9FF: 30 03        BMI $EA04
C2/EA01: A9 0F        LDA #$0F
C2/EA03: 27 99        AND [$99]
C2/EA05: 08           PHP 
C2/EA06: 05 BF        ORA $BF
C2/EA08: EF 51 D1 85  SBC $85D151
C2/EA0C: E0 64 E2     CPX #$E264
C2/EA0F: E2 20        SEP #$20
C2/EA11: B9 27 05     LDA $0527,Y
C2/EA14: 85 E9        STA $E9
C2/EA16: 20 AC EA     JSR $EAAC
C2/EA19: A5 E0        LDA $E0
C2/EA1B: 29 FF        AND #$FF
C2/EA1D: 7F C9 E8 03  ADC $03E8C9,X
C2/EA21: 30 03        BMI $EA26
C2/EA23: A9 E7        LDA #$E7
C2/EA25: 03 99        ORA $99,S
C2/EA27: 0C 05 A4     TSB $A405
C2/EA2A: 80 BB        BRA $E9E7
C2/EA2C: E2 20        SEP #$20
C2/EA2E: A9 04        LDA #$04
C2/EA30: 85 85        STA $85
C2/EA32: B9 16 05     LDA $0516,Y
C2/EA35: C9 8B        CMP #$8B
C2/EA37: F0 12        BEQ $EA4B
C2/EA39: C9 8C        CMP #$8C
C2/EA3B: F0 0E        BEQ $EA4B
C2/EA3D: C9 8D        CMP #$8D
C2/EA3F: F0 0A        BEQ $EA4B
C2/EA41: C9 8E        CMP #$8E
C2/EA43: F0 23        BEQ $EA68
C2/EA45: C9 8F        CMP #$8F
C2/EA47: F0 1F        BEQ $EA68
C2/EA49: 80 3D        BRA $EA88
C2/EA4B: 38           SEC 
C2/EA4C: E9 8A        SBC #$8A
C2/EA4E: 85 E8        STA $E8
C2/EA50: C2 20        REP #$20
C2/EA52: BD 08 05     LDA $0508,X
C2/EA55: 20 EE EA     JSR $EAEE
C2/EA58: 29 FF 7F     AND #$7FFF
C2/EA5B: C9 10 27     CMP #$2710
C2/EA5E: 30 03        BMI $EA63
C2/EA60: A9 0F 27     LDA #$270F
C2/EA63: 9D 08 05     STA $0508,X
C2/EA66: 80 20        BRA $EA88
C2/EA68: 38           SEC 
C2/EA69: E9 8D        SBC #$8D
C2/EA6B: C9 02        CMP #$02
C2/EA6D: D0 01        BNE $EA70
C2/EA6F: 1A           INC 
C2/EA70: 85 E8        STA $E8
C2/EA72: C2 20        REP #$20
C2/EA74: BD 0C 05     LDA $050C,X
C2/EA77: 20 EE EA     JSR $EAEE
C2/EA7A: 29 FF 7F     AND #$7FFF
C2/EA7D: C9 E8 03     CMP #$03E8
C2/EA80: 30 03        BMI $EA85
C2/EA82: A9 E7 03     LDA #$03E7
C2/EA85: 9D 0C 05     STA $050C,X
C2/EA88: E2 20        SEP #$20
C2/EA8A: C8           INY 
C2/EA8B: C6 85        DEC $85
C2/EA8D: D0 A3        BNE $EA32
C2/EA8F: C2 20        REP #$20
C2/EA91: A6 80        LDX $80
C2/EA93: BD 08 05     LDA $0508,X
C2/EA96: DD 06 05     CMP $0506,X
C2/EA99: 10 03        BPL $EA9E
C2/EA9B: 9D 06 05     STA $0506,X
C2/EA9E: BD 0C 05     LDA $050C,X
C2/EAA1: DD 0A 05     CMP $050A,X
C2/EAA4: 10 03        BPL $EAA9
C2/EAA6: 9D 0A 05     STA $050A,X
C2/EAA9: 28           PLP 
C2/EAAA: AB           PLB 
C2/EAAB: 60           RTS 
C2/EAAC: A5 E0        LDA $E0
C2/EAAE: 8F 1B 21 00  STA $00211B
C2/EAB2: A5 E1        LDA $E1
C2/EAB4: 8F 1B 21 00  STA $00211B
C2/EAB8: A5 E9        LDA $E9
C2/EABA: 18           CLC 
C2/EABB: 69 20        ADC #$20
C2/EABD: 8F 1C 21 00  STA $00211C
C2/EAC1: 8F 1C 21 00  STA $00211C
C2/EAC5: C2 20        REP #$20
C2/EAC7: AF 34 21 00  LDA $002134
C2/EACB: 85 E0        STA $E0
C2/EACD: AF 36 21 00  LDA $002136
C2/EAD1: 29 FF 00     AND #$00FF
C2/EAD4: 85 E2        STA $E2
C2/EAD6: 06 E0        ASL $E0
C2/EAD8: 26 E2        ROL $E2
C2/EADA: 06 E0        ASL $E0
C2/EADC: 26 E2        ROL $E2
C2/EADE: 06 E0        ASL $E0
C2/EAE0: 26 E2        ROL $E2
C2/EAE2: A5 E1        LDA $E1
C2/EAE4: 85 E0        STA $E0
C2/EAE6: A5 E3        LDA $E3
C2/EAE8: 29 FF 00     AND #$00FF
C2/EAEB: 85 E2        STA $E2
C2/EAED: 60           RTS 
C2/EAEE: 08           PHP 
C2/EAEF: C2 20        REP #$20
C2/EAF1: 85 E0        STA $E0
C2/EAF3: 64 E2        STZ $E2
C2/EAF5: E2 20        SEP #$20
C2/EAF7: A5 E8        LDA $E8
C2/EAF9: 0A           ASL 
C2/EAFA: 0A           ASL 
C2/EAFB: 0A           ASL 
C2/EAFC: 18           CLC 
C2/EAFD: 65 E8        ADC $E8
C2/EAFF: 65 E8        ADC $E8
C2/EB01: 85 E8        STA $E8
C2/EB03: 64 E4        STZ $E4
C2/EB05: 64 E5        STZ $E5
C2/EB07: 64 E6        STZ $E6
C2/EB09: 64 E7        STZ $E7
C2/EB0B: A5 E0        LDA $E0
C2/EB0D: 8F 1B 21 00  STA $00211B
C2/EB11: A5 E1        LDA $E1
C2/EB13: 8F 1B 21 00  STA $00211B
C2/EB17: A5 E8        LDA $E8
C2/EB19: 8F 1C 21 00  STA $00211C
C2/EB1D: 8F 1C 21 00  STA $00211C
C2/EB21: AF 35 21 00  LDA $002135
C2/EB25: 8F 04 42 00  STA $004204
C2/EB29: AF 36 21 00  LDA $002136
C2/EB2D: 8F 05 42 00  STA $004205
C2/EB31: A9 64        LDA #$64
C2/EB33: 8F 06 42 00  STA $004206
C2/EB37: EA           NOP 
C2/EB38: EA           NOP 
C2/EB39: EA           NOP 
C2/EB3A: EA           NOP 
C2/EB3B: EA           NOP 
C2/EB3C: EA           NOP 
C2/EB3D: EA           NOP 
C2/EB3E: EA           NOP 
C2/EB3F: AF 14 42 00  LDA $004214
C2/EB43: 85 E5        STA $E5
C2/EB45: AF 15 42 00  LDA $004215
C2/EB49: 85 E6        STA $E6
C2/EB4B: AF 34 21 00  LDA $002134
C2/EB4F: 8F 04 42 00  STA $004204
C2/EB53: AF 16 42 00  LDA $004216
C2/EB57: 8F 05 42 00  STA $004205
C2/EB5B: A9 64        LDA #$64
C2/EB5D: 8F 06 42 00  STA $004206
C2/EB61: EA           NOP 
C2/EB62: EA           NOP 
C2/EB63: EA           NOP 
C2/EB64: EA           NOP 
C2/EB65: EA           NOP 
C2/EB66: EA           NOP 
C2/EB67: EA           NOP 
C2/EB68: EA           NOP 
C2/EB69: AF 14 42 00  LDA $004214
C2/EB6D: 85 E4        STA $E4
C2/EB6F: C2 20        REP #$20
C2/EB71: A5 E0        LDA $E0
C2/EB73: 18           CLC 
C2/EB74: 65 E4        ADC $E4
C2/EB76: 85 E0        STA $E0
C2/EB78: A5 E2        LDA $E2
C2/EB7A: 65 E6        ADC $E6
C2/EB7C: 85 E2        STA $E2
C2/EB7E: A5 E0        LDA $E0
C2/EB80: 28           PLP 
C2/EB81: 60           RTS 

; [  ]

C2/EB82: 8B           PHB 
C2/EB83: 08           PHP 
C2/EB84: F4 7E 7E     PEA $7E7E
C2/EB87: AB           PLB 
C2/EB88: AB           PLB 
C2/EB89: C2 20        REP #$20
C2/EB8B: A4 80        LDY $80
C2/EB8D: B9 01 05     LDA $0501,Y     ; job
C2/EB90: 29 1F 00     AND #$001F
C2/EB93: 48           PHA 
C2/EB94: 0A           ASL 
C2/EB95: 0A           ASL 
C2/EB96: AA           TAX 
C2/EB97: 68           PLA 
C2/EB98: 20 16 E9     JSR $E916       ; get job innate abilities
C2/EB9B: 99 20 05     STA $0520,Y     ; innate abilities
C2/EB9E: BF 60 57 D1  LDA $D15760,X
C2/EBA2: 99 16 05     STA $0516,Y     ; battle commands
C2/EBA5: BF 62 57 D1  LDA $D15762,X
C2/EBA9: 99 18 05     STA $0518,Y
C2/EBAC: BF 08 57 D1  LDA $D15708,X
C2/EBB0: 99 40 05     STA $0540,Y     ; equipment types
C2/EBB3: BF 0A 57 D1  LDA $D1570A,X
C2/EBB7: 99 42 05     STA $0542,Y
C2/EBBA: 28           PLP 
C2/EBBB: AB           PLB 
C2/EBBC: 60           RTS 

; [  ]

C2/EBBD: 8B           PHB 
C2/EBBE: 08           PHP 
C2/EBBF: E2 20        SEP #$20
C2/EBC1: A9 7E        LDA #$7E
C2/EBC3: 48           PHA 
C2/EBC4: AB           PLB 
C2/EBC5: 20 C5 D4     JSR $D4C5
C2/EBC8: 64 E7        STZ $E7
C2/EBCA: 64 E8        STZ $E8
C2/EBCC: 64 E9        STZ $E9
C2/EBCE: 64 EA        STZ $EA
C2/EBD0: A9 D1        LDA #$D1
C2/EBD2: 85 84        STA $84
C2/EBD4: A9 04        LDA #$04
C2/EBD6: 85 85        STA $85
C2/EBD8: A6 80        LDX $80
C2/EBDA: BD 16 05     LDA $0516,X
C2/EBDD: 48           PHA 
C2/EBDE: 30 05        BMI $EBE5
C2/EBE0: A0 00 5E     LDY #$5E00
C2/EBE3: 80 03        BRA $EBE8
C2/EBE5: A0 08 63     LDY #$6308
C2/EBE8: 84 82        STY $82
C2/EBEA: 68           PLA 
C2/EBEB: 29 7F        AND #$7F
C2/EBED: 20 54 EC     JSR $EC54
C2/EBF0: E8           INX 
C2/EBF1: C6 85        DEC $85
C2/EBF3: D0 E5        BNE $EBDA
C2/EBF5: A0 B0 56     LDY #$56B0      ; D1/56B0 (job stat modifiers)
C2/EBF8: 84 82        STY $82
C2/EBFA: A9 D1        LDA #$D1
C2/EBFC: 85 84        STA $84
C2/EBFE: A6 80        LDX $80
C2/EC00: BD 01 05     LDA $0501,X
C2/EC03: 29 1F        AND #$1F
C2/EC05: C9 14        CMP #$14
C2/EC07: 30 0F        BMI $EC18       ; branch if not mimic or freelancer
C2/EC09: C2 20        REP #$20
C2/EC0B: 8A           TXA 
C2/EC0C: 18           CLC 
C2/EC0D: 69 4A 05     ADC #$054A
C2/EC10: 85 82        STA $82
C2/EC12: E2 20        SEP #$20
C2/EC14: 64 84        STZ $84
C2/EC16: A9 00        LDA #$00
C2/EC18: 20 54 EC     JSR $EC54
C2/EC1B: A0 1E 55     LDY #$551E      ; D1/551E (character stat modifiers)
C2/EC1E: 84 82        STY $82
C2/EC20: A9 D1        LDA #$D1
C2/EC22: 85 84        STA $84
C2/EC24: C2 20        REP #$20
C2/EC26: BD 00 05     LDA $0500,X     ; character index
C2/EC29: 29 07 00     AND #$0007
C2/EC2C: 0A           ASL 
C2/EC2D: 0A           ASL 
C2/EC2E: A8           TAY 
C2/EC2F: E2 20        SEP #$20
C2/EC31: A6 8E        LDX $8E
C2/EC33: B7 82        LDA [$82],Y
C2/EC35: 18           CLC 
C2/EC36: 75 E7        ADC $E7,X
C2/EC38: 95 E7        STA $E7,X
C2/EC3A: C8           INY 
C2/EC3B: E8           INX 
C2/EC3C: E0 04 00     CPX #$0004
C2/EC3F: D0 F2        BNE $EC33
C2/EC41: A6 8E        LDX $8E
C2/EC43: A4 80        LDY $80
C2/EC45: B5 E7        LDA $E7,X
C2/EC47: 99 24 05     STA $0524,Y
C2/EC4A: C8           INY 
C2/EC4B: E8           INX 
C2/EC4C: E0 04 00     CPX #$0004
C2/EC4F: D0 F4        BNE $EC45
C2/EC51: 28           PLP 
C2/EC52: AB           PLB 
C2/EC53: 60           RTS 

; [ apply stat bonus ]

C2/EC54: DA           PHX 
C2/EC55: 5A           PHY 
C2/EC56: 08           PHP 
C2/EC57: C2 20        REP #$20
C2/EC59: 29 FF 00     AND #$00FF
C2/EC5C: 0A           ASL 
C2/EC5D: 0A           ASL 
C2/EC5E: A8           TAY 
C2/EC5F: E2 20        SEP #$20
C2/EC61: A6 8E        LDX $8E
C2/EC63: B7 82        LDA [$82],Y
C2/EC65: D5 E7        CMP $E7,X
C2/EC67: 30 02        BMI $EC6B       ; branch if less than current bonus
C2/EC69: 95 E7        STA $E7,X
C2/EC6B: C8           INY 
C2/EC6C: E8           INX 
C2/EC6D: E0 04 00     CPX #$0004
C2/EC70: D0 F1        BNE $EC63
C2/EC72: 28           PLP 
C2/EC73: 7A           PLY 
C2/EC74: FA           PLX 
C2/EC75: 60           RTS 

; [  ]

C2/EC76: 8B           PHB 
C2/EC77: 08           PHP 
C2/EC78: E2 20        SEP #$20
C2/EC7A: 64 EB        STZ $EB
C2/EC7C: 64 EC        STZ $EC
C2/EC7E: 64 ED        STZ $ED
C2/EC80: 64 EE        STZ $EE
C2/EC82: A6 8E        LDX $8E
C2/EC84: B5 E0        LDA $E0,X
C2/EC86: DA           PHX 
C2/EC87: 20 AB D9     JSR $D9AB
C2/EC8A: FA           PLX 
C2/EC8B: A5 9E        LDA $9E
C2/EC8D: 10 2E        BPL $ECBD
C2/EC8F: DA           PHX 
C2/EC90: 48           PHA 
C2/EC91: C2 20        REP #$20
C2/EC93: 29 07 00     AND #$0007
C2/EC96: 0A           ASL 
C2/EC97: AA           TAX 
C2/EC98: BF 80 28 D1  LDA $D12880,X
C2/EC9C: 85 F9        STA $F9
C2/EC9E: E2 20        SEP #$20
C2/ECA0: 68           PLA 
C2/ECA1: 29 78        AND #$78
C2/ECA3: 0A           ASL 
C2/ECA4: A6 8E        LDX $8E
C2/ECA6: 0A           ASL 
C2/ECA7: EB           XBA 
C2/ECA8: 90 04        BCC $ECAE
C2/ECAA: A5 FA        LDA $FA
C2/ECAC: 80 02        BRA $ECB0
C2/ECAE: A5 F9        LDA $F9
C2/ECB0: 18           CLC 
C2/ECB1: 75 EB        ADC $EB,X
C2/ECB3: 95 EB        STA $EB,X
C2/ECB5: EB           XBA 
C2/ECB6: E8           INX 
C2/ECB7: E0 04 00     CPX #$0004
C2/ECBA: D0 EA        BNE $ECA6
C2/ECBC: FA           PLX 
C2/ECBD: E8           INX 
C2/ECBE: E0 07 00     CPX #$0007
C2/ECC1: D0 C1        BNE $EC84
C2/ECC3: A6 8E        LDX $8E
C2/ECC5: B5 E7        LDA $E7,X
C2/ECC7: 18           CLC 
C2/ECC8: 75 EB        ADC $EB,X
C2/ECCA: 10 02        BPL $ECCE
C2/ECCC: A9 00        LDA #$00
C2/ECCE: 95 EB        STA $EB,X
C2/ECD0: E8           INX 
C2/ECD1: E0 04 00     CPX #$0004
C2/ECD4: D0 EF        BNE $ECC5
C2/ECD6: 28           PLP 
C2/ECD7: AB           PLB 
C2/ECD8: 60           RTS 
C2/ECD9: F4 7E 7E     PEA $7E7E
C2/ECDC: AB           PLB 
C2/ECDD: AB           PLB 
C2/ECDE: C2 20        REP #$20
C2/ECE0: 64 75        STZ $75
C2/ECE2: A4 80        LDY $80
C2/ECE4: B9 40 05     LDA $0540,Y
C2/ECE7: 85 E0        STA $E0
C2/ECE9: B9 42 05     LDA $0542,Y
C2/ECEC: 85 E2        STA $E2
C2/ECEE: 64 E6        STZ $E6
C2/ECF0: 64 E8        STZ $E8
C2/ECF2: 60           RTS 
C2/ECF3: A4 8E        LDY $8E
C2/ECF5: C2 20        REP #$20
C2/ECF7: B9 40 07     LDA $0740,Y
C2/ECFA: 29 FF 00     AND #$00FF
C2/ECFD: F0 48        BEQ $ED47
C2/ECFF: 85 E8        STA $E8
C2/ED01: B9 40 06     LDA $0640,Y
C2/ED04: 29 FF 00     AND #$00FF
C2/ED07: 85 E6        STA $E6
C2/ED09: C5 93        CMP $93
C2/ED0B: 30 3A        BMI $ED47
C2/ED0D: C5 95        CMP $95
C2/ED0F: 10 36        BPL $ED47
C2/ED11: 20 AB D9     JSR $D9AB
C2/ED14: A5 E4        LDA $E4
C2/ED16: 30 06        BMI $ED1E
C2/ED18: A5 9B        LDA $9B
C2/ED1A: 25 E4        AND $E4
C2/ED1C: F0 29        BEQ $ED47
C2/ED1E: A5 9D        LDA $9D
C2/ED20: 29 3F 00     AND #$003F
C2/ED23: 0A           ASL 
C2/ED24: 0A           ASL 
C2/ED25: AA           TAX 
C2/ED26: BF 80 24 D1  LDA $D12480,X   ; item equipment types
C2/ED2A: 25 E0        AND $E0
C2/ED2C: D0 08        BNE $ED36
C2/ED2E: BF 82 24 D1  LDA $D12482,X
C2/ED32: 25 E2        AND $E2
C2/ED34: F0 11        BEQ $ED47
C2/ED36: E2 20        SEP #$20
C2/ED38: A6 75        LDX $75
C2/ED3A: A5 E6        LDA $E6
C2/ED3C: 9D 00 7A     STA $7A00,X
C2/ED3F: A5 E8        LDA $E8
C2/ED41: 9D 00 7B     STA $7B00,X
C2/ED44: E8           INX 
C2/ED45: 86 75        STX $75
C2/ED47: C8           INY 
C2/ED48: C0 00 01     CPY #$0100
C2/ED4B: D0 A8        BNE $ECF5
C2/ED4D: E2 20        SEP #$20
C2/ED4F: A6 75        LDX $75
C2/ED51: 9E 00 7A     STZ $7A00,X
C2/ED54: 9E 00 7B     STZ $7B00,X
C2/ED57: E8           INX 
C2/ED58: E0 00 01     CPX #$0100
C2/ED5B: D0 F4        BNE $ED51
C2/ED5D: 60           RTS 
C2/ED5E: 8B           PHB 
C2/ED5F: 08           PHP 
C2/ED60: 20 D9 EC     JSR $ECD9
C2/ED63: A9 89        LDA #$89
C2/ED65: 00 85        BRK $85
C2/ED67: 93 A9        STA ($A9,S),Y
C2/ED69: E0 00 85     CPX #$8500
C2/ED6C: 95 E2        STA $E2,X
C2/ED6E: 20 A5 6F     JSR $6FA5
C2/ED71: 3A           DEC 
C2/ED72: 3A           DEC 
C2/ED73: 3A           DEC 
C2/ED74: C2 20        REP #$20
C2/ED76: 29 03 00     AND #$0003
C2/ED79: 0A           ASL 
C2/ED7A: AA           TAX 
C2/ED7B: BF C9 F5 C0  LDA $C0F5C9,X
C2/ED7F: 85 E4        STA $E4
C2/ED81: 20 F3 EC     JSR $ECF3
C2/ED84: 28           PLP 
C2/ED85: AB           PLB 
C2/ED86: 60           RTS 
C2/ED87: 8B           PHB 
C2/ED88: 08           PHP 
C2/ED89: 20 D9 EC     JSR $ECD9
C2/ED8C: A9 02        LDA #$02
C2/ED8E: 00 85        BRK $85
C2/ED90: 93 A9        STA ($A9,S),Y
C2/ED92: 80 00        BRA $ED94
C2/ED94: 85 95        STA $95
C2/ED96: A9 00        LDA #$00
C2/ED98: 80 85        BRA $ED1F
C2/ED9A: E4 20        CPX $20
C2/ED9C: F3 EC        SBC ($EC,S),Y
C2/ED9E: C2 20        REP #$20
C2/EDA0: A9 80 00     LDA #$0080
C2/EDA3: 85 93        STA $93
C2/EDA5: A9 E0 00     LDA #$00E0
C2/EDA8: 85 95        STA $95
C2/EDAA: A9 08 00     LDA #$0008
C2/EDAD: 85 E4        STA $E4
C2/EDAF: 20 F3 EC     JSR $ECF3
C2/EDB2: 28           PLP 
C2/EDB3: AB           PLB 
C2/EDB4: 60           RTS 
C2/EDB5: A4 8E        LDY $8E
C2/EDB7: E2 20        SEP #$20
C2/EDB9: B9 00 7A     LDA $7A00,Y
C2/EDBC: F0 14        BEQ $EDD2
C2/EDBE: 20 AB D9     JSR $D9AB
C2/EDC1: A5 A2        LDA $A2
C2/EDC3: 99 00 7E     STA $7E00,Y
C2/EDC6: C4 75        CPY $75
C2/EDC8: F0 08        BEQ $EDD2
C2/EDCA: C0 FF 00     CPY #$00FF
C2/EDCD: F0 03        BEQ $EDD2
C2/EDCF: C8           INY 
C2/EDD0: 80 E5        BRA $EDB7
C2/EDD2: 60           RTS 
C2/EDD3: C2 20        REP #$20
C2/EDD5: A2 00 01     LDX #$0100
C2/EDD8: CA           DEX 
C2/EDD9: CA           DEX 
C2/EDDA: 9E 00 7F     STZ $7F00,X
C2/EDDD: D0 F9        BNE $EDD8
C2/EDDF: E2 20        SEP #$20
C2/EDE1: A4 8E        LDY $8E
C2/EDE3: B9 00 7A     LDA $7A00,Y
C2/EDE6: F0 1A        BEQ $EE02
C2/EDE8: B9 00 7E     LDA $7E00,Y
C2/EDEB: C2 20        REP #$20
C2/EDED: 29 FF 00     AND #$00FF
C2/EDF0: AA           TAX 
C2/EDF1: E2 20        SEP #$20
C2/EDF3: FE 00 7F     INC $7F00,X
C2/EDF6: C4 75        CPY $75
C2/EDF8: F0 08        BEQ $EE02
C2/EDFA: C0 FF 00     CPY #$00FF
C2/EDFD: F0 03        BEQ $EE02
C2/EDFF: C8           INY 
C2/EE00: 80 E1        BRA $EDE3
C2/EE02: 60           RTS 
C2/EE03: E2 20        SEP #$20
C2/EE05: A0 FE 00     LDY #$00FE
C2/EE08: B9 00 7F     LDA $7F00,Y
C2/EE0B: 18           CLC 
C2/EE0C: 79 01 7F     ADC $7F01,Y
C2/EE0F: 99 00 7F     STA $7F00,Y
C2/EE12: C0 00 00     CPY #$0000
C2/EE15: F0 03        BEQ $EE1A
C2/EE17: 88           DEY 
C2/EE18: 80 EE        BRA $EE08
C2/EE1A: 60           RTS 
C2/EE1B: E2 20        SEP #$20
C2/EE1D: A4 8E        LDY $8E
C2/EE1F: B9 00 7A     LDA $7A00,Y
C2/EE22: F0 3E        BEQ $EE62
C2/EE24: B9 00 7E     LDA $7E00,Y
C2/EE27: F0 2D        BEQ $EE56
C2/EE29: C9 FF        CMP #$FF
C2/EE2B: D0 05        BNE $EE32
C2/EE2D: A2 00 00     LDX #$0000
C2/EE30: 80 0E        BRA $EE40
C2/EE32: 1A           INC 
C2/EE33: C2 20        REP #$20
C2/EE35: 29 FF 00     AND #$00FF
C2/EE38: AA           TAX 
C2/EE39: BD 00 7F     LDA $7F00,X
C2/EE3C: 29 FF 00     AND #$00FF
C2/EE3F: AA           TAX 
C2/EE40: E2 20        SEP #$20
C2/EE42: BD 00 80     LDA $8000,X
C2/EE45: F0 03        BEQ $EE4A
C2/EE47: E8           INX 
C2/EE48: 80 F8        BRA $EE42
C2/EE4A: B9 00 7A     LDA $7A00,Y
C2/EE4D: 9D 00 80     STA $8000,X
C2/EE50: B9 00 7B     LDA $7B00,Y
C2/EE53: 9D 00 81     STA $8100,X
C2/EE56: C4 75        CPY $75
C2/EE58: F0 08        BEQ $EE62
C2/EE5A: C0 FF 00     CPY #$00FF
C2/EE5D: F0 03        BEQ $EE62
C2/EE5F: C8           INY 
C2/EE60: 80 BD        BRA $EE1F
C2/EE62: 60           RTS 
C2/EE63: C2 20        REP #$20
C2/EE65: AD 01 7F     LDA $7F01
C2/EE68: 29 FF 00     AND #$00FF
C2/EE6B: AA           TAX 
C2/EE6C: E2 20        SEP #$20
C2/EE6E: A4 8E        LDY $8E
C2/EE70: B9 00 7A     LDA $7A00,Y
C2/EE73: F0 1E        BEQ $EE93
C2/EE75: B9 00 7E     LDA $7E00,Y
C2/EE78: D0 0D        BNE $EE87
C2/EE7A: B9 00 7A     LDA $7A00,Y
C2/EE7D: 9D 00 80     STA $8000,X
C2/EE80: B9 00 7B     LDA $7B00,Y
C2/EE83: 9D 00 81     STA $8100,X
C2/EE86: E8           INX 
C2/EE87: C4 75        CPY $75
C2/EE89: F0 08        BEQ $EE93
C2/EE8B: C0 FF 00     CPY #$00FF
C2/EE8E: F0 03        BEQ $EE93
C2/EE90: C8           INY 
C2/EE91: 80 DD        BRA $EE70
C2/EE93: 60           RTS 
C2/EE94: 8B           PHB 
C2/EE95: 08           PHP 
C2/EE96: E2 20        SEP #$20
C2/EE98: A9 7E        LDA #$7E
C2/EE9A: 48           PHA 
C2/EE9B: AB           PLB 
C2/EE9C: C2 20        REP #$20
C2/EE9E: A2 00 04     LDX #$0400
C2/EEA1: CA           DEX 
C2/EEA2: CA           DEX 
C2/EEA3: 9E 00 7E     STZ $7E00,X
C2/EEA6: D0 F9        BNE $EEA1
C2/EEA8: 20 B5 ED     JSR $EDB5
C2/EEAB: 20 D3 ED     JSR $EDD3
C2/EEAE: 20 03 EE     JSR $EE03
C2/EEB1: 20 1B EE     JSR $EE1B
C2/EEB4: 20 63 EE     JSR $EE63
C2/EEB7: C2 20        REP #$20
C2/EEB9: A2 00 80     LDX #$8000
C2/EEBC: A0 00 7A     LDY #$7A00
C2/EEBF: A9 FF 01     LDA #$01FF
C2/EEC2: 54 7E 7E     MVN $7E,$7E
C2/EEC5: 28           PLP 
C2/EEC6: AB           PLB 
C2/EEC7: 60           RTS 
C2/EEC8: 8B           PHB 
C2/EEC9: F4 7E 7E     PEA $7E7E
C2/EECC: AB           PLB 
C2/EECD: AB           PLB 
C2/EECE: 86 F2        STX $F2
C2/EED0: 84 F4        STY $F4
C2/EED2: A9 04        LDA #$04
C2/EED4: 85 F6        STA $F6
C2/EED6: A4 8E        LDY $8E
C2/EED8: 38           SEC 
C2/EED9: B1 F2        LDA ($F2),Y
C2/EEDB: F1 F4        SBC ($F4),Y
C2/EEDD: 99 1D 28     STA $281D,Y
C2/EEE0: C8           INY 
C2/EEE1: C6 F6        DEC $F6
C2/EEE3: D0 F4        BNE $EED9
C2/EEE5: AB           PLB 
C2/EEE6: 60           RTS 
C2/EEE7: 8B           PHB 
C2/EEE8: 08           PHP 
C2/EEE9: C2 20        REP #$20
C2/EEEB: 29 0F 00     AND #$000F
C2/EEEE: 0A           ASL 
C2/EEEF: AA           TAX 
C2/EEF0: BF 08 F2 C0  LDA $C0F208,X
C2/EEF4: 20 B8 C1     JSR $C1B8
C2/EEF7: 20 98 A6     JSR $A698
C2/EEFA: 28           PLP 
C2/EEFB: AB           PLB 
C2/EEFC: 60           RTS 
C2/EEFD: 20 C5 EF     JSR $EFC5
C2/EF00: 20 16 EF     JSR $EF16
C2/EF03: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/EF06: 20 58 E6     JSR $E658
C2/EF09: 20 89 EF     JSR $EF89
C2/EF0C: 20 16 EF     JSR $EF16
C2/EF0F: 20 D4 FA     JSR $FAD4       ; copy sprite data to vram
C2/EF12: 20 6F E6     JSR $E66F
C2/EF15: 60           RTS 
C2/EF16: 8B           PHB 
C2/EF17: 08           PHP 
C2/EF18: F4 7E 7E     PEA $7E7E
C2/EF1B: AB           PLB 
C2/EF1C: AB           PLB 
C2/EF1D: C2 20        REP #$20
C2/EF1F: 64 F1        STZ $F1
C2/EF21: 64 7E        STZ $7E
C2/EF23: 20 C5 D4     JSR $D4C5
C2/EF26: A6 80        LDX $80
C2/EF28: BD 00 05     LDA $0500,X
C2/EF2B: 29 40 00     AND #$0040
C2/EF2E: D0 45        BNE $EF75
C2/EF30: BD 40 05     LDA $0540,X
C2/EF33: 85 EB        STA $EB
C2/EF35: BD 42 05     LDA $0542,X
C2/EF38: 85 ED        STA $ED
C2/EF3A: A5 55        LDA $55
C2/EF3C: 3A           DEC 
C2/EF3D: 29 0F 00     AND #$000F
C2/EF40: 0A           ASL 
C2/EF41: 0A           ASL 
C2/EF42: A8           TAY 
C2/EF43: A5 EB        LDA $EB
C2/EF45: 39 5E 28     AND $285E,Y
C2/EF48: D0 09        BNE $EF53
C2/EF4A: A5 ED        LDA $ED
C2/EF4C: 39 60 28     AND $2860,Y
C2/EF4F: D0 02        BNE $EF53
C2/EF51: 80 22        BRA $EF75
C2/EF53: A5 7E        LDA $7E
C2/EF55: 0A           ASL 
C2/EF56: 0A           ASL 
C2/EF57: 0A           ASL 
C2/EF58: A8           TAY 
C2/EF59: B9 40 02     LDA $0240,Y
C2/EF5C: 38           SEC 
C2/EF5D: E9 0C 00     SBC #$000C
C2/EF60: 99 40 02     STA $0240,Y
C2/EF63: B9 44 02     LDA $0244,Y
C2/EF66: 38           SEC 
C2/EF67: E9 0C 00     SBC #$000C
C2/EF6A: 99 44 02     STA $0244,Y
C2/EF6D: A6 7E        LDX $7E
C2/EF6F: BF 04 F2 C0  LDA $C0F204,X
C2/EF73: 04 F1        TSB $F1
C2/EF75: A5 7E        LDA $7E
C2/EF77: 1A           INC 
C2/EF78: 85 7E        STA $7E
C2/EF7A: C9 04 00     CMP #$0004
C2/EF7D: D0 A4        BNE $EF23
C2/EF7F: E2 20        SEP #$20
C2/EF81: A5 F1        LDA $F1
C2/EF83: 8D 86 28     STA $2886
C2/EF86: 28           PLP 
C2/EF87: AB           PLB 
C2/EF88: 60           RTS 
C2/EF89: 8B           PHB 
C2/EF8A: 08           PHP 
C2/EF8B: C2 20        REP #$20
C2/EF8D: A2 B4 F4     LDX #$F4B4
C2/EF90: A0 40 02     LDY #$0240
C2/EF93: A9 1F 00     LDA #$001F
C2/EF96: 54 7E C0     MVN $7E,$C0
C2/EF99: 20 9F EF     JSR $EF9F
C2/EF9C: 28           PLP 
C2/EF9D: AB           PLB 
C2/EF9E: 60           RTS 
C2/EF9F: 64 7E        STZ $7E
C2/EFA1: 20 C5 D4     JSR $D4C5
C2/EFA4: A4 80        LDY $80
C2/EFA6: A5 7E        LDA $7E
C2/EFA8: 0A           ASL 
C2/EFA9: 0A           ASL 
C2/EFAA: 0A           ASL 
C2/EFAB: AA           TAX 
C2/EFAC: B9 00 05     LDA $0500,Y
C2/EFAF: 29 40        AND #$40
C2/EFB1: 00 F0        BRK $F0
C2/EFB3: 06 9E        ASL $9E
C2/EFB5: 42 02        WDM $02
C2/EFB7: 9E 46 02     STZ $0246,X
C2/EFBA: A5 7E        LDA $7E
C2/EFBC: 1A           INC 
C2/EFBD: 85 7E        STA $7E
C2/EFBF: C9 04        CMP #$04
C2/EFC1: 00 D0        BRK $D0
C2/EFC3: DD 60 8B     CMP $8B60,X
C2/EFC6: 08           PHP 
C2/EFC7: C2 20        REP #$20
C2/EFC9: 29 01 00     AND #$0001
C2/EFCC: 1A           INC 
C2/EFCD: 0A           ASL 
C2/EFCE: AA           TAX 
C2/EFCF: BF AE F4 C0  LDA $C0F4AE,X
C2/EFD3: AA           TAX 
C2/EFD4: A0 40 02     LDY #$0240
C2/EFD7: A9 1F 00     LDA #$001F
C2/EFDA: 54 7E C0     MVN $7E,$C0
C2/EFDD: 20 9F EF     JSR $EF9F
C2/EFE0: 28           PLP 
C2/EFE1: AB           PLB 
C2/EFE2: 60           RTS 

; [  ]

C2/EFE3: 8B           PHB 
C2/EFE4: 08           PHP 
C2/EFE5: F4 7E 7E     PEA $7E7E
C2/EFE8: AB           PLB 
C2/EFE9: AB           PLB 
C2/EFEA: AD 09 28     LDA $2809
C2/EFED: 20 0B F0     JSR $F00B       ; give spell
C2/EFF0: A6 8E        LDX $8E
C2/EFF2: BF 90 28 D1  LDA $D12890,X
C2/EFF6: F0 10        BEQ $F008
C2/EFF8: CD 09 28     CMP $2809
C2/EFFB: F0 04        BEQ $F001
C2/EFFD: E8           INX 
C2/EFFE: E8           INX 
C2/EFFF: 80 F1        BRA $EFF2
C2/F001: BF 91 28 D1  LDA $D12891,X
C2/F005: 20 0B F0     JSR $F00B       ; give spell
C2/F008: 28           PLP 
C2/F009: AB           PLB 
C2/F00A: 60           RTS 

; [ give spell ]

C2/F00B: DA           PHX 
C2/F00C: 08           PHP 
C2/F00D: E2 20        SEP #$20
C2/F00F: 20 1D F0     JSR $F01D
C2/F012: 1F 50 09 00  ORA $000950,X   ; known spells
C2/F016: 9F 50 09 00  STA $000950,X
C2/F01A: 28           PLP 
C2/F01B: FA           PLX 
C2/F01C: 60           RTS 

C2/F01D: 08           PHP 
C2/F01E: 5A           PHY 
C2/F01F: C2 20        REP #$20
C2/F021: 29 FF 00     AND #$00FF
C2/F024: 48           PHA 
C2/F025: 4A           LSR 
C2/F026: 4A           LSR 
C2/F027: 4A           LSR 
C2/F028: AA           TAX 
C2/F029: 68           PLA 
C2/F02A: 29 07 00     AND #$0007
C2/F02D: A8           TAY 
C2/F02E: E2 20        SEP #$20
C2/F030: A9 80        LDA #$80
C2/F032: C0 00 00     CPY #$0000
C2/F035: F0 04        BEQ $F03B
C2/F037: 88           DEY 
C2/F038: 4A           LSR 
C2/F039: 80 F7        BRA $F032
C2/F03B: 7A           PLY 
C2/F03C: 28           PLP 
C2/F03D: 60           RTS 

; [  ]

C2/F03E: 8B           PHB 
C2/F03F: 08           PHP 
C2/F040: F4 7E 7E     PEA $7E7E
C2/F043: AB           PLB 
C2/F044: AB           PLB 
C2/F045: E2 20        SEP #$20
C2/F047: 9C 11 28     STZ $2811
C2/F04A: 9C 12 28     STZ $2812
C2/F04D: 9C 13 28     STZ $2813
C2/F050: AD 09 28     LDA $2809
C2/F053: C2 20        REP #$20
C2/F055: 29 FF 00     AND #$00FF
C2/F058: 20 1D F0     JSR $F01D
C2/F05B: E2 20        SEP #$20
C2/F05D: 3D 50 09     AND $0950,X     ; spells known
C2/F060: F0 03        BEQ $F065       ; branch if spell is not known
C2/F062: EE 11 28     INC $2811
C2/F065: A9 01        LDA #$01
C2/F067: 8D 14 28     STA $2814
C2/F06A: 20 E6 F0     JSR $F0E6
C2/F06D: 28           PLP 
C2/F06E: AB           PLB 
C2/F06F: 60           RTS 

; [  ]

C2/F070: 8B           PHB 
C2/F071: 08           PHP 
C2/F072: F4 7E 7E     PEA $7E7E
C2/F075: AB           PLB 
C2/F076: AB           PLB 
C2/F077: E2 20        SEP #$20
C2/F079: AD 09 28     LDA $2809
C2/F07C: A6 8E        LDX $8E
C2/F07E: DD 40 06     CMP $0640,X     ; item index
C2/F081: F0 08        BEQ $F08B
C2/F083: E8           INX 
C2/F084: E0 00 01     CPX #$0100
C2/F087: F0 0A        BEQ $F093
C2/F089: 80 F3        BRA $F07E
C2/F08B: BD 40 07     LDA $0740,X     ; item quantity
C2/F08E: 8D 11 28     STA $2811
C2/F091: 80 03        BRA $F096
C2/F093: 9C 11 28     STZ $2811
C2/F096: 9C 12 28     STZ $2812
C2/F099: A4 8E        LDY $8E
C2/F09B: 84 7E        STY $7E
C2/F09D: 20 C5 D4     JSR $D4C5
C2/F0A0: A6 80        LDX $80
C2/F0A2: 3C 00 05     BIT $0500,X
C2/F0A5: 70 14        BVS $F0BB       ; branch if character is not present
C2/F0A7: 5A           PHY 
C2/F0A8: A0 07 00     LDY #$0007
C2/F0AB: BD 0E 05     LDA $050E,X
C2/F0AE: CD 09 28     CMP $2809
C2/F0B1: D0 03        BNE $F0B6
C2/F0B3: EE 12 28     INC $2812
C2/F0B6: E8           INX 
C2/F0B7: 88           DEY 
C2/F0B8: D0 F1        BNE $F0AB
C2/F0BA: 7A           PLY 
C2/F0BB: C8           INY 
C2/F0BC: C0 04 00     CPY #$0004
C2/F0BF: D0 DA        BNE $F09B
C2/F0C1: A9 63        LDA #$63
C2/F0C3: 38           SEC 
C2/F0C4: ED 11 28     SBC $2811
C2/F0C7: ED 12 28     SBC $2812
C2/F0CA: 10 02        BPL $F0CE
C2/F0CC: A9 00        LDA #$00
C2/F0CE: 8D 13 28     STA $2813
C2/F0D1: AD 05 28     LDA $2805
C2/F0D4: 10 05        BPL $F0DB
C2/F0D6: A9 01        LDA #$01
C2/F0D8: 8D 13 28     STA $2813
C2/F0DB: A9 01        LDA #$01
C2/F0DD: 8D 14 28     STA $2814
C2/F0E0: 20 E6 F0     JSR $F0E6
C2/F0E3: 28           PLP 
C2/F0E4: AB           PLB 
C2/F0E5: 60           RTS 

; [  ]

C2/F0E6: 08           PHP 
C2/F0E7: E2 20        SEP #$20
C2/F0E9: AF 14 28 7E  LDA $7E2814
C2/F0ED: 85 E0        STA $E0
C2/F0EF: C2 20        REP #$20
C2/F0F1: AF 0C 28 7E  LDA $7E280C
C2/F0F5: 85 E1        STA $E1
C2/F0F7: AF 0E 28 7E  LDA $7E280E
C2/F0FB: 85 E3        STA $E3
C2/F0FD: 20 FB F2     JSR $F2FB
C2/F100: A5 E5        LDA $E5
C2/F102: 8F 19 28 7E  STA $7E2819
C2/F106: A5 E7        LDA $E7
C2/F108: 8F 1B 28 7E  STA $7E281B
C2/F10C: 28           PLP 
C2/F10D: 60           RTS 

; [  ]

C2/F10E: 8B           PHB 
C2/F10F: 08           PHP 
C2/F110: F4 7E 7E     PEA $7E7E
C2/F113: AB           PLB 
C2/F114: AB           PLB 
C2/F115: C2 20        REP #$20
C2/F117: A4 8E        LDY $8E
C2/F119: 98           TYA 
C2/F11A: 0A           ASL 
C2/F11B: AA           TAX 
C2/F11C: BF F4 F1 C0  LDA $C0F1F4,X
C2/F120: AA           TAX 
C2/F121: B9 26 28     LDA $2826,Y
C2/F124: 29 FF 00     AND #$00FF
C2/F127: F0 2F        BEQ $F158
C2/F129: 5A           PHY 
C2/F12A: DA           PHX 
C2/F12B: 9B           TXY 
C2/F12C: 2C 02 28     BIT $2802
C2/F12F: 30 05        BMI $F136
C2/F131: 20 4E E4     JSR $E44E       ; draw item name
C2/F134: 80 03        BRA $F139
C2/F136: 20 2C E4     JSR $E42C       ; draw spell name
C2/F139: 68           PLA 
C2/F13A: 18           CLC 
C2/F13B: 69 14 00     ADC #$0014
C2/F13E: AA           TAX 
C2/F13F: A3 01        LDA $01,S
C2/F141: 29 0F 00     AND #$000F
C2/F144: 0A           ASL 
C2/F145: 0A           ASL 
C2/F146: 18           CLC 
C2/F147: 69 2E 28     ADC #$282E
C2/F14A: A8           TAY 
C2/F14B: A9 73 7E     LDA #$7E73
C2/F14E: 20 ED E4     JSR $E4ED
C2/F151: 7A           PLY 
C2/F152: C8           INY 
C2/F153: C0 08 00     CPY #$0008
C2/F156: D0 C1        BNE $F119
C2/F158: 28           PLP 
C2/F159: AB           PLB 
C2/F15A: 60           RTS 

; [ draw shop type name ]

C2/F15B: 8B           PHB 
C2/F15C: 08           PHP 
C2/F15D: F4 7E 7E     PEA $7E7E
C2/F160: AB           PLB 
C2/F161: AB           PLB 
C2/F162: C2 20        REP #$20
C2/F164: AD 01 28     LDA $2801       ; shop type
C2/F167: 29 07 00     AND #$0007
C2/F16A: 0A           ASL 
C2/F16B: 0A           ASL 
C2/F16C: 0A           ASL 
C2/F16D: 18           CLC 
C2/F16E: 69 00 2D     ADC #$2D00      ; D1/2D00 (shop type names)
C2/F171: A8           TAY 
C2/F172: A2 C4 50     LDX #$50C4
C2/F175: A9 05 D1     LDA #$D105
C2/F178: 20 9D E5     JSR $E59D
C2/F17B: 2C 02 28     BIT $2802
C2/F17E: 30 0C        BMI $F18C
C2/F180: A2 CE 51     LDX #$51CE
C2/F183: A0 14 F5     LDY #$F514
C2/F186: A9 02 C0     LDA #$C002
C2/F189: 20 9D E5     JSR $E59D
C2/F18C: 28           PLP 
C2/F18D: AB           PLB 
C2/F18E: 60           RTS 

; [ load shop properties ]

C2/F18F: 8B           PHB 
C2/F190: 08           PHP 
C2/F191: E2 20        SEP #$20
C2/F193: A9 7E        LDA #$7E
C2/F195: 48           PHA 
C2/F196: AB           PLB 
C2/F197: AD 00 28     LDA $2800       ; shop index
C2/F19A: C2 20        REP #$20
C2/F19C: 29 FF 00     AND #$00FF
C2/F19F: 48           PHA 
C2/F1A0: 0A           ASL             ; multiply by 9
C2/F1A1: 0A           ASL 
C2/F1A2: 0A           ASL 
C2/F1A3: 18           CLC 
C2/F1A4: 63 01        ADC $01,S
C2/F1A6: AA           TAX 
C2/F1A7: 68           PLA 
C2/F1A8: E2 20        SEP #$20
C2/F1AA: BF 40 2D D1  LDA $D12D40,X   ; shop properties
C2/F1AE: 8D 01 28     STA $2801       ; shop type
C2/F1B1: E8           INX 
C2/F1B2: 9B           TXY 
C2/F1B3: 29 07        AND #$07
C2/F1B5: EB           XBA 
C2/F1B6: A9 00        LDA #$00
C2/F1B8: EB           XBA 
C2/F1B9: AA           TAX 
C2/F1BA: BF EC F1 C0  LDA $C0F1EC,X
C2/F1BE: 48           PHA 
C2/F1BF: EB           XBA 
C2/F1C0: 68           PLA 
C2/F1C1: C2 20        REP #$20
C2/F1C3: 8D 02 28     STA $2802
C2/F1C6: 98           TYA 
C2/F1C7: 18           CLC 
C2/F1C8: 69 40 2D     ADC #$2D40      ; pointer to items
C2/F1CB: AA           TAX 
C2/F1CC: A0 26 28     LDY #$2826      ; copy to 7E/2826
C2/F1CF: A9 07 00     LDA #$0007      ; copy 8 bytes
C2/F1D2: 54 7E D1     MVN $7E,$D1
C2/F1D5: E2 20        SEP #$20
C2/F1D7: AD 02 28     LDA $2802
C2/F1DA: 8D 25 28     STA $2825
C2/F1DD: A6 8E        LDX $8E
C2/F1DF: E2 20        SEP #$20
C2/F1E1: BD 26 28     LDA $2826,X     ; item index
C2/F1E4: 8D 09 28     STA $2809
C2/F1E7: 20 9F F2     JSR $F29F       ; get item price
C2/F1EA: C2 20        REP #$20
C2/F1EC: 8A           TXA 
C2/F1ED: 0A           ASL 
C2/F1EE: A8           TAY 
C2/F1EF: AD 0A 28     LDA $280A       ; item price
C2/F1F2: 99 4E 28     STA $284E,Y
C2/F1F5: AD 01 28     LDA $2801
C2/F1F8: 29 80 00     AND #$0080
C2/F1FB: F0 15        BEQ $F212       ; branch if no discount
C2/F1FD: E2 20        SEP #$20
C2/F1FF: 2C 05 28     BIT $2805
C2/F202: C2 20        REP #$20
C2/F204: 10 06        BPL $F20C
C2/F206: 4E 0E 28     LSR $280E       ; divide price by 4
C2/F209: 6E 0C 28     ROR $280C
C2/F20C: 4E 0E 28     LSR $280E       ; divide price by 2
C2/F20F: 6E 0C 28     ROR $280C
C2/F212: 8A           TXA 
C2/F213: 0A           ASL 
C2/F214: 0A           ASL 
C2/F215: A8           TAY 
C2/F216: AD 0C 28     LDA $280C
C2/F219: 99 2E 28     STA $282E,Y
C2/F21C: AD 0E 28     LDA $280E
C2/F21F: 99 30 28     STA $2830,Y
C2/F222: E8           INX 
C2/F223: E0 08 00     CPX #$0008
C2/F226: D0 B7        BNE $F1DF
C2/F228: A6 8E        LDX $8E
C2/F22A: 9E 5E 28     STZ $285E,X
C2/F22D: 9E 60 28     STZ $2860,X
C2/F230: E8           INX 
C2/F231: E8           INX 
C2/F232: E8           INX 
C2/F233: E8           INX 
C2/F234: E0 20 00     CPX #$0020
C2/F237: D0 F1        BNE $F22A
C2/F239: AD 01 28     LDA $2801
C2/F23C: 29 07 00     AND #$0007
C2/F23F: F0 5B        BEQ $F29C       ; branch if a magic shop
C2/F241: A4 8E        LDY $8E
C2/F243: C2 20        REP #$20
C2/F245: B9 26 28     LDA $2826,Y
C2/F248: 20 AB D9     JSR $D9AB
C2/F24B: B9 26 28     LDA $2826,Y
C2/F24E: 29 FF 00     AND #$00FF
C2/F251: F0 3D        BEQ $F290
C2/F253: C9 E0 00     CMP #$00E0
C2/F256: E2 20        SEP #$20
C2/F258: 10 29        BPL $F283
C2/F25A: A5 9D        LDA $9D
C2/F25C: C2 20        REP #$20
C2/F25E: 29 3F 00     AND #$003F
C2/F261: 0A           ASL 
C2/F262: 0A           ASL 
C2/F263: AA           TAX 
C2/F264: 5A           PHY 
C2/F265: 98           TYA 
C2/F266: 0A           ASL 
C2/F267: 0A           ASL 
C2/F268: A8           TAY 
C2/F269: BF 80 24 D1  LDA $D12480,X   ; item equipment types
C2/F26D: 99 5E 28     STA $285E,Y
C2/F270: BF 82 24 D1  LDA $D12482,X
C2/F274: 99 60 28     STA $2860,Y
C2/F277: 7A           PLY 
C2/F278: E2 20        SEP #$20
C2/F27A: A5 9F        LDA $9F
C2/F27C: 29 3F        AND #$3F
C2/F27E: 18           CLC 
C2/F27F: 69 00        ADC #$00
C2/F281: 80 04        BRA $F287
C2/F283: A5 9E        LDA $9E
C2/F285: 29 3F        AND #$3F
C2/F287: 99 7E 28     STA $287E,Y
C2/F28A: C8           INY 
C2/F28B: C0 08 00     CPY #$0008
C2/F28E: D0 B3        BNE $F243
C2/F290: BB           TYX 
C2/F291: E0 08 00     CPX #$0008
C2/F294: F0 06        BEQ $F29C
C2/F296: 9E 7E 28     STZ $287E,X
C2/F299: E8           INX 
C2/F29A: 80 F5        BRA $F291
C2/F29C: 28           PLP 
C2/F29D: AB           PLB 
C2/F29E: 60           RTS 

; [ get item price ]

C2/F29F: 8B           PHB 
C2/F2A0: DA           PHX 
C2/F2A1: 08           PHP 
C2/F2A2: F4 7E 7E     PEA $7E7E
C2/F2A5: AB           PLB 
C2/F2A6: AB           PLB 
C2/F2A7: C2 20        REP #$20
C2/F2A9: AD 09 28     LDA $2809
C2/F2AC: 29 FF 00     AND #$00FF
C2/F2AF: 0A           ASL 
C2/F2B0: AA           TAX 
C2/F2B1: AD 25 28     LDA $2825
C2/F2B4: 29 80 00     AND #$0080
C2/F2B7: D0 06        BNE $F2BF
C2/F2B9: BF 00 2A D1  LDA $D12A00,X   ; item price
C2/F2BD: 80 04        BRA $F2C3
C2/F2BF: BF 00 2C D1  LDA $D12C00,X   ; spell price
C2/F2C3: 8D 0A 28     STA $280A
C2/F2C6: 20 CD F2     JSR $F2CD
C2/F2C9: 28           PLP 
C2/F2CA: FA           PLX 
C2/F2CB: AB           PLB 
C2/F2CC: 60           RTS 

; [  ]

C2/F2CD: 08           PHP 
C2/F2CE: E2 20        SEP #$20
C2/F2D0: AD 0B 28     LDA $280B
C2/F2D3: 85 E0        STA $E0
C2/F2D5: AD 0A 28     LDA $280A
C2/F2D8: C2 20        REP #$20
C2/F2DA: 29 1F 00     AND #$001F
C2/F2DD: 0A           ASL 
C2/F2DE: 0A           ASL 
C2/F2DF: AA           TAX 
C2/F2E0: BF 17 F5 C0  LDA $C0F517,X   ; price multiplier
C2/F2E4: 85 E1        STA $E1
C2/F2E6: BF 19 F5 C0  LDA $C0F519,X
C2/F2EA: 85 E3        STA $E3
C2/F2EC: 20 FB F2     JSR $F2FB       ; multiply
C2/F2EF: A5 E5        LDA $E5
C2/F2F1: 8D 0C 28     STA $280C       ; set item price
C2/F2F4: A5 E7        LDA $E7
C2/F2F6: 8D 0E 28     STA $280E
C2/F2F9: 28           PLP 
C2/F2FA: 60           RTS 

C2/F2FB: 08           PHP 
C2/F2FC: C2 20        REP #$20
C2/F2FE: 64 E5        STZ $E5
C2/F300: 64 E7        STZ $E7
C2/F302: E2 20        SEP #$20
C2/F304: A5 E0        LDA $E0
C2/F306: 8F 02 42 00  STA $004202
C2/F30A: A6 8E        LDX $8E
C2/F30C: E2 20        SEP #$20
C2/F30E: B5 E1        LDA $E1,X
C2/F310: 8F 03 42 00  STA $004203
C2/F314: EA           NOP 
C2/F315: EA           NOP 
C2/F316: EA           NOP 
C2/F317: C2 20        REP #$20
C2/F319: AF 16 42 00  LDA $004216
C2/F31D: 18           CLC 
C2/F31E: 75 E5        ADC $E5,X
C2/F320: 95 E5        STA $E5,X
C2/F322: E8           INX 
C2/F323: E0 03 00     CPX #$0003
C2/F326: D0 E4        BNE $F30C
C2/F328: 28           PLP 
C2/F329: 60           RTS 
C2/F32A: 8B           PHB 
C2/F32B: 08           PHP 
C2/F32C: AD F4 2B     LDA $2BF4
C2/F32F: D0 62        BNE $F393
C2/F331: A9 9E        LDA #$9E
C2/F333: B5 20        LDA $20,X
C2/F335: B8           CLV 
C2/F336: C1 A6        CMP ($A6,X)
C2/F338: E6 A0        INC $A0
C2/F33A: 04 2C        TSB $2C
C2/F33C: A9 06        LDA #$06
C2/F33E: 7E 20 9D     ROR $9D20,X
C2/F341: E5 A5        SBC $A5
C2/F343: E6 18        INC $18
C2/F345: 69 34        ADC #$34
C2/F347: 00 AA        BRK $AA
C2/F349: A0 F6 2B     LDY #$2BF6
C2/F34C: A9 21        LDA #$21
C2/F34E: 7E 20 ED     ROR $ED20,X
C2/F351: E4 A5        CPX $A5
C2/F353: E6 18        INC $18
C2/F355: 69 A6        ADC #$A6
C2/F357: 00 AA        BRK $AA
C2/F359: A0 F8 2B     LDY #$2BF8
C2/F35C: 20 DB D5     JSR $D5DB
C2/F35F: A5 E6        LDA $E6
C2/F361: 18           CLC 
C2/F362: 69 80        ADC #$80
C2/F364: 00 AA        BRK $AA
C2/F366: A0 0C 2C     LDY #$2C0C
C2/F369: 20 62 D6     JSR $D662
C2/F36C: AD 0A 2C     LDA $2C0A
C2/F36F: 0A           ASL 
C2/F370: 0A           ASL 
C2/F371: 0A           ASL 
C2/F372: AA           TAX 
C2/F373: AD 12 2C     LDA $2C12
C2/F376: 9D 62 73     STA $7362,X
C2/F379: A5 E6        LDA $E6
C2/F37B: 38           SEC 
C2/F37C: E9 82        SBC #$82
C2/F37E: 00 AA        BRK $AA
C2/F380: AD 0A 2C     LDA $2C0A
C2/F383: 1A           INC 
C2/F384: 1A           INC 
C2/F385: 1A           INC 
C2/F386: 1A           INC 
C2/F387: EB           XBA 
C2/F388: 29 00        AND #$00
C2/F38A: 07 09        ORA [$09]
C2/F38C: C0 80 20     CPY #$2080
C2/F38F: DC D6 80     JML [$80D6]
C2/F392: 06 A9        ASL $A9
C2/F394: B1 B5        LDA ($B5),Y
C2/F396: 20 B8 C1     JSR $C1B8
C2/F399: 28           PLP 
C2/F39A: AB           PLB 
C2/F39B: 60           RTS 
C2/F39C: 8B           PHB 
C2/F39D: 08           PHP 
C2/F39E: F4 7E 7E     PEA $7E7E
C2/F3A1: AB           PLB 
C2/F3A2: AB           PLB 
C2/F3A3: C2 20        REP #$20
C2/F3A5: A6 8E        LDX $8E
C2/F3A7: A0 14 2C     LDY #$2C14
C2/F3AA: DA           PHX 
C2/F3AB: 5A           PHY 
C2/F3AC: BF C5 F3 C0  LDA $C0F3C5,X
C2/F3B0: 85 E6        STA $E6
C2/F3B2: BB           TYX 
C2/F3B3: A0 F4 2B     LDY #$2BF4
C2/F3B6: A9 1F 00     LDA #$001F
C2/F3B9: 54 7E 7E     MVN $7E,$7E
C2/F3BC: 20 2A F3     JSR $F32A
C2/F3BF: 7A           PLY 
C2/F3C0: FA           PLX 
C2/F3C1: E8           INX 
C2/F3C2: E8           INX 
C2/F3C3: 98           TYA 
C2/F3C4: 18           CLC 
C2/F3C5: 69 20 00     ADC #$0020
C2/F3C8: A8           TAY 
C2/F3C9: E0 08 00     CPX #$0008
C2/F3CC: D0 DC        BNE $F3AA
C2/F3CE: 28           PLP 
C2/F3CF: AB           PLB 
C2/F3D0: 60           RTS 
C2/F3D1: 29 0F        AND #$0F
C2/F3D3: 00 3A        BRK $3A
C2/F3D5: 29 03        AND #$03
C2/F3D7: 00 EB        BRK $EB
C2/F3D9: 4A           LSR 
C2/F3DA: 4A           LSR 
C2/F3DB: 4A           LSR 
C2/F3DC: 60           RTS 
C2/F3DD: 0A           ASL 
C2/F3DE: 48           PHA 
C2/F3DF: BD 93 02     LDA $0293,X
C2/F3E2: 29 F1        AND #$F1
C2/F3E4: 03 01        ORA $01,S
C2/F3E6: 9D 93 02     STA $0293,X
C2/F3E9: 9D 97 02     STA $0297,X
C2/F3EC: 68           PLA 
C2/F3ED: E8           INX 
C2/F3EE: E8           INX 
C2/F3EF: E8           INX 
C2/F3F0: E8           INX 
C2/F3F1: E8           INX 
C2/F3F2: E8           INX 
C2/F3F3: E8           INX 
C2/F3F4: E8           INX 
C2/F3F5: 60           RTS 
C2/F3F6: 8B           PHB 
C2/F3F7: 08           PHP 
C2/F3F8: F4 7E 7E     PEA $7E7E
C2/F3FB: AB           PLB 
C2/F3FC: AB           PLB 
C2/F3FD: C2 20        REP #$20
C2/F3FF: A5 52        LDA $52
C2/F401: 29 FF 00     AND #$00FF
C2/F404: C9 09 00     CMP #$0009
C2/F407: F0 11        BEQ $F41A
C2/F409: 20 D1 F3     JSR $F3D1
C2/F40C: AA           TAX 
C2/F40D: E2 20        SEP #$20
C2/F40F: A0 04 00     LDY #$0004
C2/F412: A9 06        LDA #$06
C2/F414: 20 DD F3     JSR $F3DD
C2/F417: 88           DEY 
C2/F418: D0 F8        BNE $F412
C2/F41A: C2 20        REP #$20
C2/F41C: A5 55        LDA $55
C2/F41E: 20 D1 F3     JSR $F3D1
C2/F421: A8           TAY 
C2/F422: 48           PHA 
C2/F423: 64 85        STZ $85
C2/F425: B9 1C 2C     LDA $2C1C,Y
C2/F428: 29 07 1F     AND #$1F07
C2/F42B: 5A           PHY 
C2/F42C: A4 85        LDY $85
C2/F42E: 20 92 D4     JSR $D492
C2/F431: 7A           PLY 
C2/F432: C8           INY 
C2/F433: C8           INY 
C2/F434: A5 85        LDA $85
C2/F436: 1A           INC 
C2/F437: 85 85        STA $85
C2/F439: C9 04 00     CMP #$0004
C2/F43C: D0 E7        BNE $F425
C2/F43E: FA           PLX 
C2/F43F: E2 20        SEP #$20
C2/F441: A4 8E        LDY $8E
C2/F443: 98           TYA 
C2/F444: 20 DD F3     JSR $F3DD
C2/F447: C8           INY 
C2/F448: C0 04 00     CPY #$0004
C2/F44B: D0 F6        BNE $F443
C2/F44D: 28           PLP 
C2/F44E: AB           PLB 
C2/F44F: 60           RTS 
C2/F450: 8B           PHB 
C2/F451: 08           PHP 
C2/F452: C2 20        REP #$20
C2/F454: A2 07 F9     LDX #$F907
C2/F457: A0 90 02     LDY #$0290
C2/F45A: A9 7F 00     LDA #$007F
C2/F45D: 54 7E C0     MVN $7E,$C0
C2/F460: 28           PLP 
C2/F461: AB           PLB 
C2/F462: 60           RTS 
C2/F463: 8B           PHB 
C2/F464: 08           PHP 
C2/F465: F4 7E 7E     PEA $7E7E
C2/F468: AB           PLB 
C2/F469: AB           PLB 
C2/F46A: C2 20        REP #$20
C2/F46C: A2 00 18     LDX #$1800
C2/F46F: A5 8E        LDA $8E
C2/F471: 9D FE AF     STA $AFFE,X
C2/F474: CA           DEX 
C2/F475: CA           DEX 
C2/F476: D0 F9        BNE $F471
C2/F478: 64 F6        STZ $F6
C2/F47A: A5 F6        LDA $F6
C2/F47C: 0A           ASL 
C2/F47D: 0A           ASL 
C2/F47E: 0A           ASL 
C2/F47F: 0A           ASL 
C2/F480: 0A           ASL 
C2/F481: A8           TAY 
C2/F482: B9 14 2C     LDA $2C14,Y
C2/F485: D0 3A        BNE $F4C1
C2/F487: A5 F6        LDA $F6
C2/F489: 0A           ASL 
C2/F48A: AA           TAX 
C2/F48B: BF FF F8 C0  LDA $C0F8FF,X
C2/F48F: 85 E4        STA $E4
C2/F491: A9 04 00     LDA #$0004
C2/F494: 85 85        STA $85
C2/F496: B9 1C 2C     LDA $2C1C,Y
C2/F499: 89 40 00     BIT #$0040
C2/F49C: D0 15        BNE $F4B3
C2/F49E: 29 07 1F     AND #$1F07
C2/F4A1: 85 EA        STA $EA
C2/F4A3: 5A           PHY 
C2/F4A4: 8B           PHB 
C2/F4A5: 20 DB D2     JSR $D2DB
C2/F4A8: A9 06 00     LDA #$0006
C2/F4AB: A2 31 ED     LDX #$ED31
C2/F4AE: 20 04 D3     JSR $D304
C2/F4B1: AB           PLB 
C2/F4B2: 7A           PLY 
C2/F4B3: C8           INY 
C2/F4B4: C8           INY 
C2/F4B5: A5 E4        LDA $E4
C2/F4B7: 18           CLC 
C2/F4B8: 69 40 00     ADC #$0040
C2/F4BB: 85 E4        STA $E4
C2/F4BD: C6 85        DEC $85
C2/F4BF: D0 D5        BNE $F496
C2/F4C1: A5 F6        LDA $F6
C2/F4C3: 1A           INC 
C2/F4C4: 85 F6        STA $F6
C2/F4C6: C9 04 00     CMP #$0004
C2/F4C9: D0 AF        BNE $F47A
C2/F4CB: A2 D9 EF     LDX #$EFD9
C2/F4CE: 20 FB D9     JSR $D9FB
C2/F4D1: 28           PLP 
C2/F4D2: AB           PLB 
C2/F4D3: 60           RTS 
C2/F4D4: 8B           PHB 
C2/F4D5: 08           PHP 
C2/F4D6: F4 30 30     PEA $3030
C2/F4D9: AB           PLB 
C2/F4DA: AB           PLB 
C2/F4DB: C2 20        REP #$20
C2/F4DD: 64 F6        STZ $F6
C2/F4DF: 20 EF F4     JSR $F4EF
C2/F4E2: A5 F6        LDA $F6
C2/F4E4: 1A           INC 
C2/F4E5: 85 F6        STA $F6
C2/F4E7: C9 04 00     CMP #$0004
C2/F4EA: D0 F3        BNE $F4DF
C2/F4EC: 28           PLP 
C2/F4ED: AB           PLB 
C2/F4EE: 60           RTS 
C2/F4EF: A5 F6        LDA $F6
C2/F4F1: 0A           ASL 
C2/F4F2: AA           TAX 
C2/F4F3: BF E7 F8 C0  LDA $C0F8E7,X
C2/F4F7: 18           CLC 
C2/F4F8: 69 00        ADC #$00
C2/F4FA: 60           RTS 
C2/F4FB: 85 FC        STA $FC
C2/F4FD: AA           TAX 
C2/F4FE: BD 4A 04     LDA $044A,X
C2/F501: 85 F8        STA $F8
C2/F503: BD 4C 04     LDA $044C,X
C2/F506: 85 FA        STA $FA
C2/F508: BD 90 04     LDA $0490,X
C2/F50B: 85 F0        STA $F0
C2/F50D: BD 92 04     LDA $0492,X
C2/F510: 85 F2        STA $F2
C2/F512: BD 94 04     LDA $0494,X
C2/F515: 85 F4        STA $F4
C2/F517: BD 71 04     LDA $0471,X
C2/F51A: 85 FE        STA $FE
C2/F51C: 20 61 F5     JSR $F561
C2/F51F: A4 FC        LDY $FC
C2/F521: A6 8E        LDX $8E
C2/F523: B9 00 00     LDA $0000,Y
C2/F526: 95 E8        STA $E8,X
C2/F528: 29 07        AND #$07
C2/F52A: 00 D0        BRK $D0
C2/F52C: 0F B9 02 00  ORA $0002B9
C2/F530: 85 E2        STA $E2
C2/F532: B9 06 00     LDA $0006,Y
C2/F535: 85 E4        STA $E4
C2/F537: B9 08 00     LDA $0008,Y
C2/F53A: 85 E6        STA $E6
C2/F53C: 98           TYA 
C2/F53D: 18           CLC 
C2/F53E: 69 50        ADC #$50
C2/F540: 00 A8        BRK $A8
C2/F542: E8           INX 
C2/F543: E8           INX 
C2/F544: E0 08 00     CPX #$0008
C2/F547: D0 DA        BNE $F523
C2/F549: A5 F6        LDA $F6
C2/F54B: 29 03        AND #$03
C2/F54D: 00 0A        BRK $0A
C2/F54F: AA           TAX 
C2/F550: BF F7 F8 C0  LDA $C0F8F7,X
C2/F554: A8           TAY 
C2/F555: A2 E0 01     LDX #$01E0
C2/F558: A9 1F        LDA #$1F
C2/F55A: 00 8B        BRK $8B
C2/F55C: 54 7E 00     MVN $7E,$00
C2/F55F: AB           PLB 
C2/F560: 60           RTS 
C2/F561: A5 F6        LDA $F6
C2/F563: 29 03        AND #$03
C2/F565: 00 0A        BRK $0A
C2/F567: AA           TAX 
C2/F568: BD F8 7F     LDA $7FF8,X
C2/F56B: C9 1B        CMP #$1B
C2/F56D: E4 D0        CPX $D0
C2/F56F: 0D 20 88     ORA $8820
C2/F572: F5 DD        SBC $DD,X
C2/F574: F0 7F        BEQ $F5F5
C2/F576: D0 0A        BNE $F582
C2/F578: A9 00        LDA #$00
C2/F57A: 00 80        BRK $80
C2/F57C: 08           PHP 
C2/F57D: A9 00        LDA #$00
C2/F57F: 80 80        BRA $F501
C2/F581: 03 A9        ORA $A9,S
C2/F583: 00 40        BRK $40
C2/F585: 85 E0        STA $E0
C2/F587: 60           RTS 
C2/F588: 8B           PHB 
C2/F589: DA           PHX 
C2/F58A: 5A           PHY 
C2/F58B: 08           PHP 
C2/F58C: F4 30 30     PEA $3030
C2/F58F: AB           PLB 
C2/F590: AB           PLB 
C2/F591: C2 20        REP #$20
C2/F593: A6 FC        LDX $FC
C2/F595: A0 00 06     LDY #$0600
C2/F598: A5 8E        LDA $8E
C2/F59A: 18           CLC 
C2/F59B: 7D 00 00     ADC $0000,X
C2/F59E: E8           INX 
C2/F59F: E8           INX 
C2/F5A0: 88           DEY 
C2/F5A1: 88           DEY 
C2/F5A2: D0 F7        BNE $F59B
C2/F5A4: 28           PLP 
C2/F5A5: 7A           PLY 
C2/F5A6: FA           PLX 
C2/F5A7: AB           PLB 
C2/F5A8: 60           RTS 

; [ update mono/stereo setting ]

C2/F5A9: 08           PHP 
C2/F5AA: E2 20        SEP #$20
C2/F5AC: AF 73 09 00  LDA $000973
C2/F5B0: 29 02        AND #$02
C2/F5B2: 4A           LSR 
C2/F5B3: 18           CLC 
C2/F5B4: 69 F3        ADC #$F3        ; $F3 = stereo, $F4 = mono
C2/F5B6: 8F 00 1D 00  STA $001D00
C2/F5BA: 22 04 00 C4  JSL $C40004
C2/F5BE: 28           PLP 
C2/F5BF: 60           RTS 

C2/F5C0: 8B           PHB 
C2/F5C1: 08           PHP 
C2/F5C2: F4 7E 7E     PEA $7E7E
C2/F5C5: AB           PLB 
C2/F5C6: AB           PLB 
C2/F5C7: C2 20        REP #$20
C2/F5C9: 64 85        STZ $85
C2/F5CB: 64 7E        STZ $7E
C2/F5CD: A5 7E        LDA $7E
C2/F5CF: 0A           ASL 
C2/F5D0: AA           TAX 
C2/F5D1: BF 0E EA C0  LDA $C0EA0E,X
C2/F5D5: 8D BA 2B     STA $2BBA
C2/F5D8: 20 C5 D4     JSR $D4C5
C2/F5DB: 20 D7 DD     JSR $DDD7
C2/F5DE: A6 80        LDX $80
C2/F5E0: BD 00 05     LDA $0500,X
C2/F5E3: 29 40 00     AND #$0040
C2/F5E6: F0 0A        BEQ $F5F2
C2/F5E8: A5 85        LDA $85
C2/F5EA: 18           CLC 
C2/F5EB: 69 04 00     ADC #$0004
C2/F5EE: 85 85        STA $85
C2/F5F0: 80 3F        BRA $F631
C2/F5F2: 8A           TXA 
C2/F5F3: 18           CLC 
C2/F5F4: 69 16 05     ADC #$0516
C2/F5F7: 85 82        STA $82
C2/F5F9: A6 8E        LDX $8E
C2/F5FB: DA           PHX 
C2/F5FC: BF 16 EA C0  LDA $C0EA16,X
C2/F600: 18           CLC 
C2/F601: 6D BA 2B     ADC $2BBA
C2/F604: 48           PHA 
C2/F605: A6 85        LDX $85
C2/F607: BD B4 2C     LDA $2CB4,X
C2/F60A: E8           INX 
C2/F60B: 86 85        STX $85
C2/F60D: 29 03 00     AND #$0003
C2/F610: A8           TAY 
C2/F611: B1 82        LDA ($82),Y
C2/F613: 29 FF 00     AND #$00FF
C2/F616: FA           PLX 
C2/F617: DA           PHX 
C2/F618: 48           PHA 
C2/F619: 20 E4 D8     JSR $D8E4
C2/F61C: 68           PLA 
C2/F61D: FA           PLX 
C2/F61E: C9 80 00     CMP #$0080
C2/F621: 30 06        BMI $F629
C2/F623: A9 08 01     LDA #$0108
C2/F626: 20 DC D6     JSR $D6DC
C2/F629: FA           PLX 
C2/F62A: E8           INX 
C2/F62B: E8           INX 
C2/F62C: E0 08 00     CPX #$0008
C2/F62F: D0 CA        BNE $F5FB
C2/F631: E6 7E        INC $7E
C2/F633: A5 85        LDA $85
C2/F635: C9 10 00     CMP #$0010
C2/F638: D0 93        BNE $F5CD
C2/F63A: 28           PLP 
C2/F63B: AB           PLB 
C2/F63C: 60           RTS 
C2/F63D: 8B           PHB 
C2/F63E: 08           PHP 
C2/F63F: F4 7E 7E     PEA $7E7E
C2/F642: AB           PLB 
C2/F643: AB           PLB 
C2/F644: E2 20        SEP #$20
C2/F646: A2 2F 00     LDX #$002F
C2/F649: 9E 9B 2C     STZ $2C9B,X
C2/F64C: CA           DEX 
C2/F64D: D0 FA        BNE $F649
C2/F64F: C2 20        REP #$20
C2/F651: A5 8E        LDA $8E
C2/F653: E2 20        SEP #$20
C2/F655: A6 8E        LDX $8E
C2/F657: DA           PHX 
C2/F658: BF A5 F0 C0  LDA $C0F0A5,X
C2/F65C: A8           TAY 
C2/F65D: BF A7 F0 C0  LDA $C0F0A7,X
C2/F661: 48           PHA 
C2/F662: BF A6 F0 C0  LDA $C0F0A6,X
C2/F666: AA           TAX 
C2/F667: 68           PLA 
C2/F668: 39 70 09     AND $0970,Y
C2/F66B: F0 03        BEQ $F670
C2/F66D: FE 9C 2C     INC $2C9C,X
C2/F670: FA           PLX 
C2/F671: E8           INX 
C2/F672: E8           INX 
C2/F673: E8           INX 
C2/F674: E0 18 00     CPX #$0018
C2/F677: D0 DE        BNE $F657
C2/F679: E2 20        SEP #$20
C2/F67B: AD 70 09     LDA $0970
C2/F67E: 48           PHA 
C2/F67F: 29 07        AND #$07
C2/F681: 8D 9D 2C     STA $2C9D
C2/F684: 68           PLA 
C2/F685: 4A           LSR 
C2/F686: 4A           LSR 
C2/F687: 4A           LSR 
C2/F688: 4A           LSR 
C2/F689: 29 07        AND #$07
C2/F68B: 8D 9E 2C     STA $2C9E
C2/F68E: C2 20        REP #$20
C2/F690: AD 71 09     LDA $0971
C2/F693: A6 8E        LDX $8E
C2/F695: 20 09 F7     JSR $F709
C2/F698: E0 03 00     CPX #$0003
C2/F69B: D0 F8        BNE $F695
C2/F69D: A2 75 09     LDX #$0975
C2/F6A0: A0 A9 2C     LDY #$2CA9
C2/F6A3: A9 1A 00     LDA #$001A
C2/F6A6: 54 7E 7E     MVN $7E,$7E
C2/F6A9: 20 AF F6     JSR $F6AF
C2/F6AC: 28           PLP 
C2/F6AD: AB           PLB 
C2/F6AE: 60           RTS 
C2/F6AF: 8B           PHB 
C2/F6B0: 08           PHP 
C2/F6B1: F4 7E 7E     PEA $7E7E
C2/F6B4: AB           PLB 
C2/F6B5: AB           PLB 
C2/F6B6: E2 20        SEP #$20
C2/F6B8: A6 8E        LDX $8E
C2/F6BA: A4 8E        LDY $8E
C2/F6BC: BD A9 2C     LDA $2CA9,X
C2/F6BF: 0A           ASL 
C2/F6C0: B0 07        BCS $F6C9
C2/F6C2: C8           INY 
C2/F6C3: C0 06 00     CPY #$0006
C2/F6C6: 30 F7        BMI $F6BF
C2/F6C8: 88           DEY 
C2/F6C9: 98           TYA 
C2/F6CA: 9D C4 2C     STA $2CC4,X
C2/F6CD: E8           INX 
C2/F6CE: E0 07 00     CPX #$0007
C2/F6D1: 30 E7        BMI $F6BA
C2/F6D3: 28           PLP 
C2/F6D4: AB           PLB 
C2/F6D5: 60           RTS 
C2/F6D6: 8B           PHB 
C2/F6D7: 08           PHP 
C2/F6D8: F4 7E 7E     PEA $7E7E
C2/F6DB: AB           PLB 
C2/F6DC: AB           PLB 
C2/F6DD: E2 20        SEP #$20
C2/F6DF: A6 8E        LDX $8E
C2/F6E1: A4 8E        LDY $8E
C2/F6E3: BD C4 2C     LDA $2CC4,X
C2/F6E6: EB           XBA 
C2/F6E7: A9 80        LDA #$80
C2/F6E9: EB           XBA 
C2/F6EA: C9 00        CMP #$00
C2/F6EC: F0 0E        BEQ $F6FC
C2/F6EE: 3A           DEC 
C2/F6EF: EB           XBA 
C2/F6F0: 4A           LSR 
C2/F6F1: EB           XBA 
C2/F6F2: C8           INY 
C2/F6F3: C0 06 00     CPY #$0006
C2/F6F6: 30 F2        BMI $F6EA
C2/F6F8: EB           XBA 
C2/F6F9: A9 04        LDA #$04
C2/F6FB: EB           XBA 
C2/F6FC: EB           XBA 
C2/F6FD: 9D A9 2C     STA $2CA9,X
C2/F700: E8           INX 
C2/F701: E0 07 00     CPX #$0007
C2/F704: 30 DB        BMI $F6E1
C2/F706: 28           PLP 
C2/F707: AB           PLB 
C2/F708: 60           RTS 
C2/F709: 48           PHA 
C2/F70A: 08           PHP 
C2/F70B: 29 1F        AND #$1F
C2/F70D: 00 E2        BRK $E2
C2/F70F: 20 9D A6     JSR $A69D
C2/F712: 2C 28 68     BIT $6828
C2/F715: 4A           LSR 
C2/F716: 4A           LSR 
C2/F717: 4A           LSR 
C2/F718: 4A           LSR 
C2/F719: 4A           LSR 
C2/F71A: E8           INX 
C2/F71B: 60           RTS 

; [ update config settings ]

C2/F71C: 8B           PHB 
C2/F71D: 08           PHP 
C2/F71E: F4 7E 7E     PEA $7E7E
C2/F721: AB           PLB 
C2/F722: AB           PLB 
C2/F723: C2 20        REP #$20
C2/F725: A6 8E        LDX $8E
C2/F727: 9E 70 09     STZ $0970,X
C2/F72A: E8           INX 
C2/F72B: E8           INX 
C2/F72C: E0 20 00     CPX #$0020
C2/F72F: D0 F6        BNE $F727
C2/F731: A6 8E        LDX $8E
C2/F733: 8A           TXA 
C2/F734: E2 20        SEP #$20
C2/F736: DA           PHX 
C2/F737: BF A5 F0 C0  LDA $C0F0A5,X
C2/F73B: A8           TAY 
C2/F73C: BF A6 F0 C0  LDA $C0F0A6,X
C2/F740: AA           TAX 
C2/F741: BD 9C 2C     LDA $2C9C,X
C2/F744: F0 0D        BEQ $F753
C2/F746: FA           PLX 
C2/F747: BF A7 F0 C0  LDA $C0F0A7,X
C2/F74B: 19 70 09     ORA $0970,Y
C2/F74E: 99 70 09     STA $0970,Y
C2/F751: 80 01        BRA $F754
C2/F753: FA           PLX 
C2/F754: E8           INX 
C2/F755: E8           INX 
C2/F756: E8           INX 
C2/F757: E0 18 00     CPX #$0018
C2/F75A: D0 DA        BNE $F736
C2/F75C: E2 20        SEP #$20
C2/F75E: AD 9E 2C     LDA $2C9E
C2/F761: 0A           ASL 
C2/F762: 0A           ASL 
C2/F763: 0A           ASL 
C2/F764: 0A           ASL 
C2/F765: 0D 9D 2C     ORA $2C9D
C2/F768: 29 77        AND #$77
C2/F76A: 0D 70 09     ORA $0970
C2/F76D: 8D 70 09     STA $0970
C2/F770: 20 A9 F5     JSR $F5A9       ; update mono/stereo setting
C2/F773: C2 20        REP #$20
C2/F775: A2 02 00     LDX #$0002
C2/F778: A4 8E        LDY $8E
C2/F77A: AD 71 09     LDA $0971
C2/F77D: 0A           ASL 
C2/F77E: 0A           ASL 
C2/F77F: 0A           ASL 
C2/F780: 0A           ASL 
C2/F781: 0A           ASL 
C2/F782: 8D 71 09     STA $0971
C2/F785: BD A6 2C     LDA $2CA6,X
C2/F788: 29 1F 00     AND #$001F
C2/F78B: 0D 71 09     ORA $0971
C2/F78E: 8D 71 09     STA $0971
C2/F791: CA           DEX 
C2/F792: 10 E6        BPL $F77A
C2/F794: 20 D6 F6     JSR $F6D6
C2/F797: A2 A9 2C     LDX #$2CA9
C2/F79A: A0 75 09     LDY #$0975
C2/F79D: A9 1A 00     LDA #$001A
C2/F7A0: 54 7E 7E     MVN $7E,$7E
C2/F7A3: 28           PLP 
C2/F7A4: AB           PLB 
C2/F7A5: 60           RTS 

; [  ]

C2/F7A6: 8B           PHB 
C2/F7A7: 08           PHP 
C2/F7A8: F4 7E 7E     PEA $7E7E
C2/F7AB: AB           PLB 
C2/F7AC: AB           PLB 
C2/F7AD: C2 20        REP #$20
C2/F7AF: AE 94 2C     LDX $2C94
C2/F7B2: BF BD F1 C0  LDA $C0F1BD,X
C2/F7B6: A8           TAY 
C2/F7B7: BF 8E F1 C0  LDA $C0F18E,X
C2/F7BB: 8D 9A 2C     STA $2C9A
C2/F7BE: BF C3 F0 C0  LDA $C0F0C3,X
C2/F7C2: 29 FF 00     AND #$00FF
C2/F7C5: 8D 96 2C     STA $2C96
C2/F7C8: 0A           ASL 
C2/F7C9: AA           TAX 
C2/F7CA: BF F2 F0 C0  LDA $C0F0F2,X
C2/F7CE: AA           TAX 
C2/F7CF: 98           TYA 
C2/F7D0: 29 FF 00     AND #$00FF
C2/F7D3: 09 00 01     ORA #$0100
C2/F7D6: 20 FC F7     JSR $F7FC
C2/F7D9: AC 9A 2C     LDY $2C9A
C2/F7DC: AE 94 2C     LDX $2C94
C2/F7DF: BD 9C 2C     LDA $2C9C,X
C2/F7E2: 29 FF 00     AND #$00FF
C2/F7E5: 18           CLC 
C2/F7E6: 6D 96 2C     ADC $2C96
C2/F7E9: 0A           ASL 
C2/F7EA: AA           TAX 
C2/F7EB: BF F2 F0 C0  LDA $C0F0F2,X
C2/F7EF: AA           TAX 
C2/F7F0: AD 9A 2C     LDA $2C9A
C2/F7F3: 29 FF 00     AND #$00FF
C2/F7F6: 20 FC F7     JSR $F7FC
C2/F7F9: 28           PLP 
C2/F7FA: AB           PLB 
C2/F7FB: 60           RTS 
C2/F7FC: AC 94 2C     LDY $2C94
C2/F7FF: C0 01 00     CPY #$0001
C2/F802: F0 05        BEQ $F809
C2/F804: C0 02 00     CPY #$0002
C2/F807: D0 03        BNE $F80C
C2/F809: 09 00        ORA #$00
C2/F80B: 80 20        BRA $F82D
C2/F80D: DC D6 60     JML [$60D6]
C2/F810: 8B           PHB 
C2/F811: 08           PHP 
C2/F812: F4 7E 7E     PEA $7E7E
C2/F815: AB           PLB 
C2/F816: AB           PLB 
C2/F817: C2 20        REP #$20
C2/F819: A4 8E        LDY $8E
C2/F81B: 98           TYA 
C2/F81C: 0A           ASL 
C2/F81D: AA           TAX 
C2/F81E: BF BD F0 C0  LDA $C0F0BD,X
C2/F822: AA           TAX 
C2/F823: 5A           PHY 
C2/F824: B9 A6 2C     LDA $2CA6,Y
C2/F827: 48           PHA 
C2/F828: 29 1C 00     AND #$001C
C2/F82B: 4A           LSR 
C2/F82C: 4A           LSR 
C2/F82D: A8           TAY 
C2/F82E: F0 0D        BEQ $F83D
C2/F830: 5A           PHY 
C2/F831: A9 FE 00     LDA #$00FE
C2/F834: 9D 00 00     STA $0000,X
C2/F837: E8           INX 
C2/F838: E8           INX 
C2/F839: 88           DEY 
C2/F83A: D0 F8        BNE $F834
C2/F83C: 7A           PLY 
C2/F83D: 68           PLA 
C2/F83E: 29 03 00     AND #$0003
C2/F841: F0 0C        BEQ $F84F
C2/F843: 3A           DEC 
C2/F844: 0A           ASL 
C2/F845: 18           CLC 
C2/F846: 69 F8 00     ADC #$00F8
C2/F849: 9D 00 00     STA $0000,X
C2/F84C: E8           INX 
C2/F84D: E8           INX 
C2/F84E: C8           INY 
C2/F84F: A9 0C 00     LDA #$000C
C2/F852: C0 08 00     CPY #$0008
C2/F855: F0 08        BEQ $F85F
C2/F857: 9D 00 00     STA $0000,X
C2/F85A: E8           INX 
C2/F85B: E8           INX 
C2/F85C: C8           INY 
C2/F85D: 80 F3        BRA $F852
C2/F85F: 7A           PLY 
C2/F860: C8           INY 
C2/F861: C0 03 00     CPY #$0003
C2/F864: D0 B5        BNE $F81B
C2/F866: 28           PLP 
C2/F867: AB           PLB 
C2/F868: 60           RTS 
C2/F869: 8B           PHB 
C2/F86A: 08           PHP 
C2/F86B: F4 7E 7E     PEA $7E7E
C2/F86E: AB           PLB 
C2/F86F: AB           PLB 
C2/F870: C2 20        REP #$20
C2/F872: 9C D1 2C     STZ $2CD1
C2/F875: 9C D3 2C     STZ $2CD3
C2/F878: 9C D5 2C     STZ $2CD5
C2/F87B: 9C D7 2C     STZ $2CD7
C2/F87E: E2 20        SEP #$20
C2/F880: A9 01        LDA #$01
C2/F882: 85 6F        STA $6F
C2/F884: 20 87 ED     JSR $ED87
C2/F887: A6 75        LDX $75
C2/F889: F0 23        BEQ $F8AE
C2/F88B: 20 94 EE     JSR $EE94
C2/F88E: A6 8E        LDX $8E
C2/F890: A4 80        LDY $80
C2/F892: B9 21 05     LDA $0521,Y
C2/F895: 89 21        BIT #$21
C2/F897: F0 0B        BEQ $F8A4
C2/F899: E8           INX 
C2/F89A: 89 01        BIT #$01
C2/F89C: F0 06        BEQ $F8A4
C2/F89E: E8           INX 
C2/F89F: 89 20        BIT #$20
C2/F8A1: F0 01        BEQ $F8A4
C2/F8A3: E8           INX 
C2/F8A4: C2 20        REP #$20
C2/F8A6: 8A           TXA 
C2/F8A7: 0A           ASL 
C2/F8A8: AA           TAX 
C2/F8A9: E2 20        SEP #$20
C2/F8AB: FC F8 FF     JSR ($FFF8,X)
C2/F8AE: 28           PLP 
C2/F8AF: AB           PLB 
C2/F8B0: 60           RTS 
C2/F8B1: 08           PHP 
C2/F8B2: E2 20        SEP #$20
C2/F8B4: 8E CD 2C     STX $2CCD
C2/F8B7: 29 03        AND #$03
C2/F8B9: 3A           DEC 
C2/F8BA: 8D CF 2C     STA $2CCF
C2/F8BD: 9C D0 2C     STZ $2CD0
C2/F8C0: 9C CB 2C     STZ $2CCB
C2/F8C3: 9C CC 2C     STZ $2CCC
C2/F8C6: A4 8E        LDY $8E
C2/F8C8: B9 00 7B     LDA $7B00,Y
C2/F8CB: F0 28        BEQ $F8F5
C2/F8CD: B9 00 7A     LDA $7A00,Y
C2/F8D0: 30 23        BMI $F8F5
C2/F8D2: 29 7F        AND #$7F
C2/F8D4: 20 AB D9     JSR $D9AB
C2/F8D7: A5 9F        LDA $9F
C2/F8D9: 2D CD 2C     AND $2CCD
C2/F8DC: 4D CE 2C     EOR $2CCE
C2/F8DF: F0 14        BEQ $F8F5
C2/F8E1: A5 A2        LDA $A2
C2/F8E3: 8D CC 2C     STA $2CCC
C2/F8E6: B9 00 7A     LDA $7A00,Y
C2/F8E9: 8D CB 2C     STA $2CCB
C2/F8EC: B9 00 7B     LDA $7B00,Y
C2/F8EF: 3A           DEC 
C2/F8F0: 99 00 7B     STA $7B00,Y
C2/F8F3: 80 05        BRA $F8FA
C2/F8F5: C8           INY 
C2/F8F6: C4 75        CPY $75
C2/F8F8: 30 CE        BMI $F8C8
C2/F8FA: AE CF 2C     LDX $2CCF
C2/F8FD: AD CB 2C     LDA $2CCB
C2/F900: 9D D1 2C     STA $2CD1,X
C2/F903: AD CC 2C     LDA $2CCC
C2/F906: 9D D5 2C     STA $2CD5,X
C2/F909: 28           PLP 
C2/F90A: 60           RTS 
C2/F90B: 08           PHP 
C2/F90C: E2 20        SEP #$20
C2/F90E: 29 03        AND #$03
C2/F910: 3A           DEC 
C2/F911: 8D CF 2C     STA $2CCF
C2/F914: 9C D0 2C     STZ $2CD0
C2/F917: AE CF 2C     LDX $2CCF
C2/F91A: A4 8E        LDY $8E
C2/F91C: B9 00 7B     LDA $7B00,Y
C2/F91F: F0 0A        BEQ $F92B
C2/F921: B9 00 7A     LDA $7A00,Y
C2/F924: 10 05        BPL $F92B
C2/F926: 9D D1 2C     STA $2CD1,X
C2/F929: 80 05        BRA $F930
C2/F92B: C8           INY 
C2/F92C: C4 75        CPY $75
C2/F92E: 30 EC        BMI $F91C
C2/F930: 28           PLP 
C2/F931: 60           RTS 

C2/F932: A4 75        LDY $75
C2/F934: 88           DEY 
C2/F935: B9 00 7A     LDA $7A00,Y
C2/F938: 30 05        BMI $F93F
C2/F93A: 8D D1 2C     STA $2CD1
C2/F93D: 80 03        BRA $F942
C2/F93F: 8D D2 2C     STA $2CD2
C2/F942: 88           DEY 
C2/F943: 10 F0        BPL $F935
C2/F945: 20 75 FA     JSR $FA75
C2/F948: 60           RTS 

C2/F949: A2 40 00     LDX #$0040
C2/F94C: A9 01        LDA #$01
C2/F94E: 20 B1 F8     JSR $F8B1
C2/F951: A2 C0 C0     LDX #$C0C0
C2/F954: A9 02        LDA #$02
C2/F956: 20 B1 F8     JSR $F8B1
C2/F959: A9 03        LDA #$03
C2/F95B: 20 0B F9     JSR $F90B
C2/F95E: C2 20        REP #$20
C2/F960: AD D6 2C     LDA $2CD6
C2/F963: 29 FF 00     AND #$00FF
C2/F966: 48           PHA 
C2/F967: AD D5 2C     LDA $2CD5
C2/F96A: 29 FF 00     AND #$00FF
C2/F96D: 0A           ASL 
C2/F96E: C3 01        CMP $01,S
C2/F970: F0 07        BEQ $F979
C2/F972: 30 05        BMI $F979
C2/F974: 9C D2 2C     STZ $2CD2
C2/F977: 80 06        BRA $F97F
C2/F979: AD D2 2C     LDA $2CD2
C2/F97C: 8D D1 2C     STA $2CD1
C2/F97F: FA           PLX 
C2/F980: 20 75 FA     JSR $FA75
C2/F983: 60           RTS 

C2/F984: A2 80 00     LDX #$0080
C2/F987: A9 01 20     LDA #$2001
C2/F98A: B1 F8        LDA ($F8),Y
C2/F98C: A2 80 80     LDX #$8080
C2/F98F: A9 02 20     LDA #$2002
C2/F992: B1 F8        LDA ($F8),Y
C2/F994: A2 80 80     LDX #$8080
C2/F997: A9 03 20     LDA #$2003
C2/F99A: B1 F8        LDA ($F8),Y
C2/F99C: AD D3 2C     LDA $2CD3
C2/F99F: D0 05        BNE $F9A6
C2/F9A1: A9 03 20     LDA #$2003
C2/F9A4: 0B           PHD 
C2/F9A5: F9 C2 20     SBC $20C2,Y
C2/F9A8: AD D6 2C     LDA $2CD6
C2/F9AB: 29 FF 00     AND #$00FF
C2/F9AE: 48           PHA 
C2/F9AF: AD D7 2C     LDA $2CD7
C2/F9B2: 29 FF 00     AND #$00FF
C2/F9B5: 18           CLC 
C2/F9B6: 63 01        ADC $01,S
C2/F9B8: 83 01        STA $01,S
C2/F9BA: AD D5 2C     LDA $2CD5
C2/F9BD: 29 FF 00     AND #$00FF
C2/F9C0: C3 01        CMP $01,S
C2/F9C2: F0 07        BEQ $F9CB
C2/F9C4: 30 05        BMI $F9CB
C2/F9C6: 9C D2 2C     STZ $2CD2
C2/F9C9: 80 06        BRA $F9D1
C2/F9CB: AD D2 2C     LDA $2CD2
C2/F9CE: 8D D1 2C     STA $2CD1
C2/F9D1: FA           PLX 
C2/F9D2: 20 75 FA     JSR $FA75
C2/F9D5: 60           RTS 

C2/F9D6: A2 40 00     LDX #$0040
C2/F9D9: A9 01 20     LDA #$2001
C2/F9DC: B1 F8        LDA ($F8),Y
C2/F9DE: A2 80 00     LDX #$0080
C2/F9E1: A9 02 20     LDA #$2002
C2/F9E4: B1 F8        LDA ($F8),Y
C2/F9E6: A2 80 80     LDX #$8080
C2/F9E9: A9 03 20     LDA #$2003
C2/F9EC: B1 F8        LDA ($F8),Y
C2/F9EE: AD D1 2C     LDA $2CD1
C2/F9F1: D0 21        BNE $FA14
C2/F9F3: AD D3 2C     LDA $2CD3
C2/F9F6: 8D D1 2C     STA $2CD1
C2/F9F9: AD D7 2C     LDA $2CD7
C2/F9FC: 8D D3 2C     STA $2CD3
C2/F9FF: A2 80 80     LDX #$8080
C2/FA02: A9 03 20     LDA #$2003
C2/FA05: B1 F8        LDA ($F8),Y
C2/FA07: C2 20        REP #$20
C2/FA09: AD D5 2C     LDA $2CD5
C2/FA0C: 29 FF 00     AND #$00FF
C2/FA0F: 8D D9 2C     STA $2CD9
C2/FA12: 80 0C        BRA $FA20
C2/FA14: C2 20        REP #$20
C2/FA16: AD D5 2C     LDA $2CD5
C2/FA19: 29 FF 00     AND #$00FF
C2/FA1C: 0A           ASL 
C2/FA1D: 8D D9 2C     STA $2CD9
C2/FA20: AD D6 2C     LDA $2CD6
C2/FA23: 29 FF 00     AND #$00FF
C2/FA26: 8D DB 2C     STA $2CDB
C2/FA29: AD D5 2C     LDA $2CD5
C2/FA2C: 29 FF 00     AND #$00FF
C2/FA2F: 8D DD 2C     STA $2CDD
C2/FA32: AD D7 2C     LDA $2CD7
C2/FA35: 29 FF 00     AND #$00FF
C2/FA38: 18           CLC 
C2/FA39: 6D DD 2C     ADC $2CDD
C2/FA3C: 8D DD 2C     STA $2CDD
C2/FA3F: CD DB 2C     CMP $2CDB
C2/FA42: F0 09        BEQ $FA4D
C2/FA44: 30 07        BMI $FA4D
C2/FA46: CD D9 2C     CMP $2CD9
C2/FA49: 30 21        BMI $FA6C
C2/FA4B: 80 15        BRA $FA62
C2/FA4D: AD DB 2C     LDA $2CDB
C2/FA50: CD D9 2C     CMP $2CD9
C2/FA53: 30 17        BMI $FA6C
C2/FA55: E2 20        SEP #$20
C2/FA57: AD D2 2C     LDA $2CD2
C2/FA5A: 8D D1 2C     STA $2CD1
C2/FA5D: 9C D2 2C     STZ $2CD2
C2/FA60: 80 0F        BRA $FA71
C2/FA62: E2 20        SEP #$20
C2/FA64: AD D3 2C     LDA $2CD3
C2/FA67: 8D D2 2C     STA $2CD2
C2/FA6A: 80 05        BRA $FA71
C2/FA6C: E2 20        SEP #$20
C2/FA6E: 9C D2 2C     STZ $2CD2
C2/FA71: 20 75 FA     JSR $FA75
C2/FA74: 60           RTS 
C2/FA75: E2 20        SEP #$20
C2/FA77: A9 01        LDA #$01
C2/FA79: 85 6F        STA $6F
C2/FA7B: AD D1 2C     LDA $2CD1
C2/FA7E: F0 05        BEQ $FA85
C2/FA80: 85 72        STA $72
C2/FA82: 20 92 FA     JSR $FA92
C2/FA85: AD D2 2C     LDA $2CD2
C2/FA88: F0 07        BEQ $FA91
C2/FA8A: 85 72        STA $72
C2/FA8C: E6 6F        INC $6F
C2/FA8E: 20 92 FA     JSR $FA92
C2/FA91: 60           RTS 
C2/FA92: 08           PHP 
C2/FA93: 20 F7 E0     JSR $E0F7
C2/FA96: A5 90        LDA $90
C2/FA98: D0 11        BNE $FAAB
C2/FA9A: 20 78 E1     JSR $E178
C2/FA9D: 20 A6 E1     JSR $E1A6
C2/FAA0: 20 8F E1     JSR $E18F
C2/FAA3: A9 01        LDA #$01
C2/FAA5: EB           XBA 
C2/FAA6: A5 72        LDA $72
C2/FAA8: 20 28 E3     JSR $E328
C2/FAAB: 28           PLP 
C2/FAAC: 60           RTS 
C2/FAAD: 8B           PHB 
C2/FAAE: 08           PHP 
C2/FAAF: E2 20        SEP #$20
C2/FAB1: A9 03        LDA #$03
C2/FAB3: 85 6F        STA $6F
C2/FAB5: 20 5E ED     JSR $ED5E
C2/FAB8: A6 75        LDX $75
C2/FABA: F0 0C        BEQ $FAC8
C2/FABC: 20 94 EE     JSR $EE94
C2/FABF: AF 00 7A 7E  LDA $7E7A00
C2/FAC3: 85 72        STA $72
C2/FAC5: 20 92 FA     JSR $FA92
C2/FAC8: A5 6F        LDA $6F
C2/FACA: 1A           INC 
C2/FACB: 85 6F        STA $6F
C2/FACD: C9 06        CMP #$06
C2/FACF: D0 E4        BNE $FAB5
C2/FAD1: 28           PLP 
C2/FAD2: AB           PLB 
C2/FAD3: 60           RTS 

; [ copy sprite data to vram ]

C2/FAD4: 8B           PHB 
C2/FAD5: 08           PHP 
C2/FAD6: C2 20        REP #$20
C2/FAD8: A2 B2 F5     LDX #$F5B2      ; 02 04 00 02 00 20 02 (sprite data)
C2/FADB: A0 00 43     LDY #$4300
C2/FADE: A9 06 00     LDA #$0006
C2/FAE1: 54 00 C0     MVN $00,$C0
C2/FAE4: 9C 02 21     STZ $2102
C2/FAE7: E2 20        SEP #$20
C2/FAE9: A9 01        LDA #$01
C2/FAEB: 04 CA        TSB $CA
C2/FAED: 28           PLP 
C2/FAEE: AB           PLB 
C2/FAEF: 60           RTS 

C2/FAF0: 8B           PHB 
C2/FAF1: 08           PHP 
C2/FAF2: C2 20        REP #$20
C2/FAF4: A2 B9 F5     LDX #$F5B9
C2/FAF7: A0 10 43     LDY #$4310
C2/FAFA: A9 06 00     LDA #$0006
C2/FAFD: 54 00 C0     MVN $00,$C0
C2/FB00: E2 20        SEP #$20
C2/FB02: 9C 21 21     STZ $2121
C2/FB05: A9 02        LDA #$02
C2/FB07: 04 CA        TSB $CA
C2/FB09: 28           PLP 
C2/FB0A: AB           PLB 
C2/FB0B: 60           RTS 

; [ menu nmi ]

C2/FB0C: 8B           PHB 
C2/FB0D: 0B           PHD 
C2/FB0E: 08           PHP 
C2/FB0F: C2 20        REP #$20
C2/FB11: 48           PHA 
C2/FB12: 08           PHP 
C2/FB13: DA           PHX 
C2/FB14: 5A           PHY 
C2/FB15: E2 20        SEP #$20
C2/FB17: A9 00        LDA #$00
C2/FB19: 48           PHA 
C2/FB1A: AB           PLB 
C2/FB1B: AD 10 42     LDA $4210
C2/FB1E: A9 01        LDA #$01
C2/FB20: 8D 00 42     STA $4200
C2/FB23: 9C 0C 42     STZ $420C
C2/FB26: A9 80        LDA #$80
C2/FB28: 8D 00 21     STA $2100
C2/FB2B: F4 00 01     PEA $0100       ; set dp
C2/FB2E: 2B           PLD 
C2/FB2F: A5 C9        LDA $C9
C2/FB31: D0 03        BNE $FB36
C2/FB33: 4C E7 FB     JMP $FBE7
C2/FB36: 64 C9        STZ $C9
C2/FB38: A5 CA        LDA $CA
C2/FB3A: 29 03        AND #$03
C2/FB3C: F0 05        BEQ $FB43
C2/FB3E: 14 CA        TRB $CA
C2/FB40: 8D 0B 42     STA $420B
C2/FB43: A9 04        LDA #$04
C2/FB45: 24 CA        BIT $CA
C2/FB47: F0 47        BEQ $FB90
C2/FB49: 14 CA        TRB $CA
C2/FB4B: 0B           PHD 
C2/FB4C: F4 00 21     PEA $2100       ; use video register dp
C2/FB4F: 2B           PLD 
C2/FB50: A2 00 75     LDX #$7500
C2/FB53: 86 81        STX $81
C2/FB55: 64 83        STZ $83
C2/FB57: A5 80        LDA $80
C2/FB59: 85 2C        STA $2C
C2/FB5B: A5 80        LDA $80
C2/FB5D: 85 2D        STA $2D
C2/FB5F: A5 80        LDA $80
C2/FB61: 85 2E        STA $2E
C2/FB63: A5 80        LDA $80
C2/FB65: 85 2F        STA $2F
C2/FB67: A5 80        LDA $80
C2/FB69: 85 23        STA $23
C2/FB6B: A5 80        LDA $80
C2/FB6D: 85 24        STA $24
C2/FB6F: A5 80        LDA $80
C2/FB71: 85 25        STA $25
C2/FB73: A5 80        LDA $80
C2/FB75: 85 2A        STA $2A
C2/FB77: A5 80        LDA $80
C2/FB79: 85 2B        STA $2B
C2/FB7B: A5 80        LDA $80
C2/FB7D: 85 31        STA $31
C2/FB7F: A5 80        LDA $80
C2/FB81: 85 30        STA $30
C2/FB83: A5 80        LDA $80
C2/FB85: 85 32        STA $32
C2/FB87: A5 80        LDA $80
C2/FB89: 85 32        STA $32
C2/FB8B: A5 80        LDA $80
C2/FB8D: 85 32        STA $32
C2/FB8F: 2B           PLD 
C2/FB90: 64 0C        STZ $0C
C2/FB92: 64 0D        STZ $0D         ; selected character (multi controller)
C2/FB94: 20 5B FE     JSR $FE5B       ; update joypad input
C2/FB97: E2 20        SEP #$20
C2/FB99: A9 7E        LDA #$7E
C2/FB9B: 48           PHA 
C2/FB9C: AB           PLB 
C2/FB9D: A9 FF        LDA #$FF
C2/FB9F: 2C 0F 75     BIT $750F
C2/FBA2: F0 03        BEQ $FBA7
C2/FBA4: CE 1D 75     DEC $751D
C2/FBA7: 2C 10 75     BIT $7510
C2/FBAA: F0 03        BEQ $FBAF
C2/FBAC: CE 1F 75     DEC $751F
C2/FBAF: AD 11 75     LDA $7511
C2/FBB2: F0 33        BEQ $FBE7
C2/FBB4: C2 20        REP #$20
C2/FBB6: AD 14 75     LDA $7514
C2/FBB9: 8F 16 21 00  STA $002116
C2/FBBD: AD 16 75     LDA $7516
C2/FBC0: 8F 00 43 00  STA $004300
C2/FBC4: AD 18 75     LDA $7518
C2/FBC7: 8F 02 43 00  STA $004302
C2/FBCB: AD 1A 75     LDA $751A
C2/FBCE: 8F 04 43 00  STA $004304
C2/FBD2: AD 1B 75     LDA $751B
C2/FBD5: 8F 05 43 00  STA $004305
C2/FBD9: E2 20        SEP #$20
C2/FBDB: AD 11 75     LDA $7511
C2/FBDE: 29 01        AND #$01
C2/FBE0: 8F 0B 42 00  STA $00420B
C2/FBE4: 9C 11 75     STZ $7511
C2/FBE7: C2 20        REP #$20
C2/FBE9: A9 01 00     LDA #$0001
C2/FBEC: 18           CLC 
C2/FBED: 6D 4A 09     ADC $094A
C2/FBF0: 8D 4A 09     STA $094A
C2/FBF3: A5 8E        LDA $8E
C2/FBF5: 6D 4C 09     ADC $094C
C2/FBF8: 8D 4C 09     STA $094C
C2/FBFB: AD FB 0A     LDA $0AFB
C2/FBFE: 29 FF 00     AND #$00FF
C2/FC01: C9 02 00     CMP #$0002
C2/FC04: D0 09        BNE $FC0F
C2/FC06: AD FC 0A     LDA $0AFC
C2/FC09: F0 04        BEQ $FC0F
C2/FC0B: 3A           DEC 
C2/FC0C: 8D FC 0A     STA $0AFC
C2/FC0F: E2 20        SEP #$20
C2/FC11: AF 0E 75 7E  LDA $7E750E
C2/FC15: 8F 0C 42 00  STA $00420C
C2/FC19: A9 81        LDA #$81
C2/FC1B: 8F 00 42 00  STA $004200
C2/FC1F: AF 25 75 7E  LDA $7E7525
C2/FC23: 8F 00 21 00  STA $002100
C2/FC27: 7A           PLY 
C2/FC28: FA           PLX 
C2/FC29: 28           PLP 
C2/FC2A: 68           PLA 
C2/FC2B: 28           PLP 
C2/FC2C: 2B           PLD 
C2/FC2D: AB           PLB 

; [ menu irq ]

C2/FC2E: 40           RTI 

; [  ]

C2/FC2F: 8B           PHB 
C2/FC30: E2 20        SEP #$20
C2/FC32: A9 7E        LDA #$7E
C2/FC34: 48           PHA 
C2/FC35: AB           PLB 
C2/FC36: AD 12 75     LDA $7512
C2/FC39: F0 03        BEQ $FC3E
C2/FC3B: 20 75 FD     JSR $FD75
C2/FC3E: AD 0F 75     LDA $750F
C2/FC41: F0 10        BEQ $FC53
C2/FC43: AD 1D 75     LDA $751D
C2/FC46: 10 0B        BPL $FC53
C2/FC48: A9 10        LDA #$10
C2/FC4A: 8D 1D 75     STA $751D
C2/FC4D: 20 B1 FC     JSR $FCB1
C2/FC50: 20 D4 FA     JSR $FAD4
C2/FC53: AD 10 75     LDA $7510
C2/FC56: F0 10        BEQ $FC68
C2/FC58: AD 1F 75     LDA $751F
C2/FC5B: 10 0B        BPL $FC68
C2/FC5D: A9 01        LDA #$01
C2/FC5F: 8D 1F 75     STA $751F
C2/FC62: 20 09 FD     JSR $FD09
C2/FC65: 20 D4 FA     JSR $FAD4
C2/FC68: AD 13 75     LDA $7513
C2/FC6B: F0 03        BEQ $FC70
C2/FC6D: 20 2E FD     JSR $FD2E
C2/FC70: A5 43        LDA $43         ; menu state
C2/FC72: C9 01        CMP #$01
C2/FC74: D0 39        BNE $FCAF
C2/FC76: AD FB 0A     LDA $0AFB
C2/FC79: C9 02        CMP #$02
C2/FC7B: F0 05        BEQ $FC82
C2/FC7D: A0 4A 09     LDY #$094A
C2/FC80: 80 10        BRA $FC92
C2/FC82: C2 20        REP #$20
C2/FC84: AD FC 0A     LDA $0AFC
C2/FC87: 8D 17 2D     STA $2D17
C2/FC8A: 9C 19 2D     STZ $2D19
C2/FC8D: A0 17 2D     LDY #$2D17
C2/FC90: E2 20        SEP #$20
C2/FC92: 08           PHP 
C2/FC93: A2 30 66     LDX #$6630
C2/FC96: 20 62 D6     JSR $D662
C2/FC99: C2 20        REP #$20
C2/FC9B: A2 C0 F5     LDX #$F5C0
C2/FC9E: A0 14 75     LDY #$7514
C2/FCA1: A9 08 00     LDA #$0008
C2/FCA4: 54 7E C0     MVN $7E,$C0
C2/FCA7: E2 20        SEP #$20
C2/FCA9: A9 01        LDA #$01
C2/FCAB: 8D 11 75     STA $7511
C2/FCAE: 28           PLP 
C2/FCAF: AB           PLB 
C2/FCB0: 60           RTS 
C2/FCB1: AD 1E 75     LDA $751E
C2/FCB4: C2 20        REP #$20
C2/FCB6: 29 01 00     AND #$0001
C2/FCB9: 0A           ASL 
C2/FCBA: AA           TAX 
C2/FCBB: A4 8E        LDY $8E
C2/FCBD: E2 20        SEP #$20
C2/FCBF: AD 0F 75     LDA $750F
C2/FCC2: 4A           LSR 
C2/FCC3: 90 2E        BCC $FCF3
C2/FCC5: 48           PHA 
C2/FCC6: B9 41 02     LDA $0241,Y
C2/FCC9: 18           CLC 
C2/FCCA: 7F 1A F2 C0  ADC $C0F21A,X
C2/FCCE: 99 41 02     STA $0241,Y
C2/FCD1: B9 42 02     LDA $0242,Y
C2/FCD4: 18           CLC 
C2/FCD5: 7F 1B F2 C0  ADC $C0F21B,X
C2/FCD9: 99 42 02     STA $0242,Y
C2/FCDC: B9 45 02     LDA $0245,Y
C2/FCDF: 18           CLC 
C2/FCE0: 7F 1A F2 C0  ADC $C0F21A,X
C2/FCE4: 99 45 02     STA $0245,Y
C2/FCE7: B9 46 02     LDA $0246,Y
C2/FCEA: 18           CLC 
C2/FCEB: 7F 1B F2 C0  ADC $C0F21B,X
C2/FCEF: 99 46 02     STA $0246,Y
C2/FCF2: 68           PLA 
C2/FCF3: C8           INY 
C2/FCF4: C8           INY 
C2/FCF5: C8           INY 
C2/FCF6: C8           INY 
C2/FCF7: C8           INY 
C2/FCF8: C8           INY 
C2/FCF9: C8           INY 
C2/FCFA: C8           INY 
C2/FCFB: C0 20 00     CPY #$0020
C2/FCFE: D0 C2        BNE $FCC2
C2/FD00: AD 1E 75     LDA $751E
C2/FD03: 49 01        EOR #$01
C2/FD05: 8D 1E 75     STA $751E
C2/FD08: 60           RTS 
C2/FD09: E2 20        SEP #$20
C2/FD0B: AD 10 75     LDA $7510
C2/FD0E: C2 20        REP #$20
C2/FD10: 29 07 00     AND #$0007
C2/FD13: 0A           ASL 
C2/FD14: 0A           ASL 
C2/FD15: 8D 20 75     STA $7520
C2/FD18: E2 20        SEP #$20
C2/FD1A: A6 8E        LDX $8E
C2/FD1C: BD 06 02     LDA $0206,X
C2/FD1F: 49 02        EOR #$02
C2/FD21: 9D 06 02     STA $0206,X
C2/FD24: E8           INX 
C2/FD25: E8           INX 
C2/FD26: E8           INX 
C2/FD27: E8           INX 
C2/FD28: EC 20 75     CPX $7520
C2/FD2B: D0 EF        BNE $FD1C
C2/FD2D: 60           RTS 
C2/FD2E: E2 20        SEP #$20
C2/FD30: AD 22 75     LDA $7522
C2/FD33: D0 1F        BNE $FD54
C2/FD35: AD 13 75     LDA $7513
C2/FD38: C2 20        REP #$20
C2/FD3A: 29 07 00     AND #$0007
C2/FD3D: 3A           DEC 
C2/FD3E: 0A           ASL 
C2/FD3F: 0A           ASL 
C2/FD40: AA           TAX 
C2/FD41: BF 1E F2 C0  LDA $C0F21E,X
C2/FD45: 8D 23 75     STA $7523
C2/FD48: BF 20 F2 C0  LDA $C0F220,X
C2/FD4C: 8D 25 75     STA $7525
C2/FD4F: E2 20        SEP #$20
C2/FD51: EE 22 75     INC $7522
C2/FD54: AD 23 75     LDA $7523
C2/FD57: F0 0F        BEQ $FD68
C2/FD59: CE 23 75     DEC $7523
C2/FD5C: AD 24 75     LDA $7524
C2/FD5F: 18           CLC 
C2/FD60: 6D 25 75     ADC $7525
C2/FD63: 8D 25 75     STA $7525
C2/FD66: 80 0C        BRA $FD74
C2/FD68: AD 26 75     LDA $7526
C2/FD6B: 8D 25 75     STA $7525
C2/FD6E: 9C 22 75     STZ $7522
C2/FD71: 9C 13 75     STZ $7513
C2/FD74: 60           RTS 
C2/FD75: E2 20        SEP #$20
C2/FD77: AD 27 75     LDA $7527
C2/FD7A: C9 04        CMP #$04
C2/FD7C: F0 0E        BEQ $FD8C
C2/FD7E: C9 03        CMP #$03
C2/FD80: F0 0E        BEQ $FD90
C2/FD82: C9 02        CMP #$02
C2/FD84: F0 0E        BEQ $FD94
C2/FD86: C9 01        CMP #$01
C2/FD88: F0 06        BEQ $FD90
C2/FD8A: 80 10        BRA $FD9C
C2/FD8C: A9 00        LDA #$00
C2/FD8E: 80 09        BRA $FD99
C2/FD90: A9 02        LDA #$02
C2/FD92: 80 05        BRA $FD99
C2/FD94: 20 41 FE     JSR $FE41
C2/FD97: A9 02        LDA #$02
C2/FD99: 20 CA FD     JSR $FDCA
C2/FD9C: E2 20        SEP #$20
C2/FD9E: AD 28 75     LDA $7528
C2/FDA1: F0 1A        BEQ $FDBD
C2/FDA3: A6 8E        LDX $8E
C2/FDA5: BD 05 02     LDA $0205,X
C2/FDA8: F0 07        BEQ $FDB1
C2/FDAA: 18           CLC 
C2/FDAB: 6D 28 75     ADC $7528
C2/FDAE: 9D 05 02     STA $0205,X
C2/FDB1: E8           INX 
C2/FDB2: E8           INX 
C2/FDB3: E8           INX 
C2/FDB4: E8           INX 
C2/FDB5: E0 20 00     CPX #$0020
C2/FDB8: D0 EB        BNE $FDA5
C2/FDBA: 20 D4 FA     JSR $FAD4
C2/FDBD: AD 27 75     LDA $7527
C2/FDC0: 3A           DEC 
C2/FDC1: 8D 27 75     STA $7527
C2/FDC4: D0 03        BNE $FDC9
C2/FDC6: 9C 12 75     STZ $7512
C2/FDC9: 60           RTS 
C2/FDCA: 08           PHP 
C2/FDCB: C2 20        REP #$20
C2/FDCD: 18           CLC 
C2/FDCE: 6D A2 29     ADC $29A2
C2/FDD1: 29 0F 00     AND #$000F
C2/FDD4: 0A           ASL 
C2/FDD5: 0A           ASL 
C2/FDD6: AA           TAX 
C2/FDD7: AC B4 29     LDY $29B4
C2/FDDA: E2 20        SEP #$20
C2/FDDC: B9 00 00     LDA $0000,Y
C2/FDDF: 18           CLC 
C2/FDE0: 7F 2E F2 C0  ADC $C0F22E,X
C2/FDE4: 99 00 00     STA $0000,Y
C2/FDE7: C8           INY 
C2/FDE8: C8           INY 
C2/FDE9: C8           INY 
C2/FDEA: E2 20        SEP #$20
C2/FDEC: B9 00 00     LDA $0000,Y
C2/FDEF: F0 12        BEQ $FE03
C2/FDF1: C8           INY 
C2/FDF2: C2 20        REP #$20
C2/FDF4: B9 00 00     LDA $0000,Y
C2/FDF7: 18           CLC 
C2/FDF8: 7F 30 F2 C0  ADC $C0F230,X
C2/FDFC: 99 00 00     STA $0000,Y
C2/FDFF: C8           INY 
C2/FE00: C8           INY 
C2/FE01: 80 E7        BRA $FDEA
C2/FE03: 28           PLP 
C2/FE04: 60           RTS 
C2/FE05: 08           PHP 
C2/FE06: C2 20        REP #$20
C2/FE08: A2 8E 29     LDX #$298E
C2/FE0B: A0 14 75     LDY #$7514
C2/FE0E: A9 08 00     LDA #$0008
C2/FE11: 54 7E 7E     MVN $7E,$7E
C2/FE14: E2 20        SEP #$20
C2/FE16: AD 28 75     LDA $7528
C2/FE19: F0 1A        BEQ $FE35
C2/FE1B: A6 8E        LDX $8E
C2/FE1D: BD 05 02     LDA $0205,X
C2/FE20: F0 07        BEQ $FE29
C2/FE22: 18           CLC 
C2/FE23: 6D 28 75     ADC $7528
C2/FE26: 9D 05 02     STA $0205,X
C2/FE29: E8           INX 
C2/FE2A: E8           INX 
C2/FE2B: E8           INX 
C2/FE2C: E8           INX 
C2/FE2D: E0 20 00     CPX #$0020
C2/FE30: D0 EB        BNE $FE1D
C2/FE32: 20 D4 FA     JSR $FAD4
C2/FE35: A9 01        LDA #$01
C2/FE37: 8D 11 75     STA $7511
C2/FE3A: A9 04        LDA #$04
C2/FE3C: 8D 27 75     STA $7527
C2/FE3F: 28           PLP 
C2/FE40: 60           RTS 

; [  ]

C2/FE41: 08           PHP 
C2/FE42: C2 20        REP #$20
C2/FE44: A2 97 29     LDX #$2997
C2/FE47: A0 14 75     LDY #$7514
C2/FE4A: A9 08 00     LDA #$0008
C2/FE4D: 54 7E 7E     MVN $7E,$7E
C2/FE50: E2 20        SEP #$20
C2/FE52: A9 01        LDA #$01
C2/FE54: 8D 11 75     STA $7511
C2/FE57: 64 CA        STZ $CA
C2/FE59: 28           PLP 
C2/FE5A: 60           RTS 

; [ update joypad input ]

C2/FE5B: 08           PHP 
C2/FE5C: C2 20        REP #$20
C2/FE5E: 48           PHA 
C2/FE5F: 08           PHP 
C2/FE60: DA           PHX 
C2/FE61: 5A           PHY 
C2/FE62: 8B           PHB 
C2/FE63: 0B           PHD 
C2/FE64: E2 20        SEP #$20
C2/FE66: C2 10        REP #$10
C2/FE68: A9 00        LDA #$00
C2/FE6A: 48           PHA 
C2/FE6B: AB           PLB 
C2/FE6C: F4 00 01     PEA $0100
C2/FE6F: 2B           PLD 
C2/FE70: A9 01        LDA #$01
C2/FE72: 2C 12 42     BIT $4212
C2/FE75: D0 FB        BNE $FE72
C2/FE77: A0 00 00     LDY #$0000
C2/FE7A: A5 4D        LDA $4D
C2/FE7C: F0 19        BEQ $FE97
C2/FE7E: AD 74 09     LDA $0974
C2/FE81: 29 80        AND #$80
C2/FE83: F0 12        BEQ $FE97       ; branch if single controller
C2/FE85: AD 0D 01     LDA $010D
C2/FE88: C2 20        REP #$20
C2/FE8A: 29 03 00     AND #$0003
C2/FE8D: AA           TAX 
C2/FE8E: BD 7C 09     LDA $097C,X     ; character assigned to controller
C2/FE91: 29 FF 00     AND #$00FF
C2/FE94: F0 01        BEQ $FE97
C2/FE96: C8           INY 
C2/FE97: C2 20        REP #$20
C2/FE99: 84 12        STY $12
C2/FE9B: 98           TYA 
C2/FE9C: 0A           ASL 
C2/FE9D: AA           TAX 
C2/FE9E: BD 18 42     LDA $4218,X     ; joypad register
C2/FEA1: 85 06        STA $06
C2/FEA3: 29 0F 00     AND #$000F
C2/FEA6: F0 02        BEQ $FEAA
C2/FEA8: 64 06        STZ $06
C2/FEAA: B5 14        LDA $14,X
C2/FEAC: 85 0E        STA $0E
C2/FEAE: 20 D0 FE     JSR $FED0
C2/FEB1: A5 12        LDA $12
C2/FEB3: 0A           ASL 
C2/FEB4: AA           TAX 
C2/FEB5: A5 0E        LDA $0E
C2/FEB7: 95 14        STA $14,X
C2/FEB9: 2B           PLD             ; pull previous direct page
C2/FEBA: AD 0A 01     LDA $010A
C2/FEBD: 85 00        STA $00
C2/FEBF: AD 08 01     LDA $0108
C2/FEC2: 85 02        STA $02
C2/FEC4: AD 06 01     LDA $0106
C2/FEC7: 85 04        STA $04
C2/FEC9: AB           PLB 
C2/FECA: 7A           PLY 
C2/FECB: FA           PLX 
C2/FECC: 28           PLP 
C2/FECD: 68           PLA 
C2/FECE: 28           PLP 
C2/FECF: 60           RTS 

; [  ]

C2/FED0: AD 74 09     LDA $0974
C2/FED3: 29 40 00     AND #$0040
C2/FED6: D0 06        BNE $FEDE       ; branch if custom button config
C2/FED8: A5 06        LDA $06
C2/FEDA: 85 08        STA $08
C2/FEDC: 80 1D        BRA $FEFB
C2/FEDE: A5 06        LDA $06
C2/FEE0: 29 0F 1F     AND #$1F0F
C2/FEE3: 85 08        STA $08
C2/FEE5: A2 00 00     LDX #$0000
C2/FEE8: A5 06        LDA $06
C2/FEEA: 3F B8 E7 C0  AND $C0E7B8,X
C2/FEEE: F0 04        BEQ $FEF4
C2/FEF0: B5 26        LDA $26,X
C2/FEF2: 04 08        TSB $08
C2/FEF4: E8           INX 
C2/FEF5: E8           INX 
C2/FEF6: E0 0E 00     CPX #$000E
C2/FEF9: D0 ED        BNE $FEE8
C2/FEFB: A5 0E        LDA $0E
C2/FEFD: 49 FF FF     EOR #$FFFF
C2/FF00: 25 08        AND $08
C2/FF02: 85 0A        STA $0A
C2/FF04: A5 08        LDA $08
C2/FF06: 25 0E        AND $0E
C2/FF08: E2 20        SEP #$20
C2/FF0A: 2C 0C 01     BIT $010C
C2/FF0D: C2 20        REP #$20
C2/FF0F: 30 03        BMI $FF14
C2/FF11: 29 7F 7F     AND #$7F7F
C2/FF14: 85 10        STA $10
C2/FF16: A5 08        LDA $08
C2/FF18: 85 0E        STA $0E
C2/FF1A: A2 00 00     LDX #$0000
C2/FF1D: A4 12        LDY $12
C2/FF1F: C2 20        REP #$20
C2/FF21: BF C6 E7 C0  LDA $C0E7C6,X
C2/FF25: 24 0A        BIT $0A
C2/FF27: D0 1A        BNE $FF43       ; branch if already in repeat mode
C2/FF29: 25 10        AND $10
C2/FF2B: F0 18        BEQ $FF45
C2/FF2D: E2 20        SEP #$20
C2/FF2F: B9 1A 01     LDA $011A,Y     ; decrement delay counter
C2/FF32: 3A           DEC 
C2/FF33: F0 02        BEQ $FF37
C2/FF35: 10 0E        BPL $FF45
C2/FF37: C2 20        REP #$20
C2/FF39: BF C6 E7 C0  LDA $C0E7C6,X
C2/FF3D: 04 0A        TSB $0A         ; set repeat mode
C2/FF3F: A5 19        LDA $19
C2/FF41: 80 02        BRA $FF45
C2/FF43: A5 18        LDA $18
C2/FF45: E2 20        SEP #$20
C2/FF47: 99 1A 01     STA $011A,Y
C2/FF4A: C8           INY             ; next button
C2/FF4B: C8           INY 
C2/FF4C: E8           INX 
C2/FF4D: E8           INX 
C2/FF4E: E0 0C 00     CPX #$000C
C2/FF51: D0 CC        BNE $FF1F
C2/FF53: C2 20        REP #$20
C2/FF55: 60           RTS 

; [ ??? (battle) ]

C2/FF56: 08           PHP 
C2/FF57: C2 20        REP #$20
C2/FF59: 48           PHA 
C2/FF5A: A9 10 03     LDA #$0310      ; delay = 16 frames, rate = 3 frames
C2/FF5D: 8F 18 01 00  STA $000118     ; repeat settings
C2/FF61: 8F 4D 01 00  STA $00014D     ; allow multipler controllers
C2/FF65: 68           PLA 
C2/FF66: 28           PLP 
C2/FF67: 60           RTS 

; [ ??? (field) ]

C2/FF68: 08           PHP 
C2/FF69: C2 20        REP #$20
C2/FF6B: 48           PHA 
C2/FF6C: A9 16 04     LDA #$0416      ; delay = 22 frames, rate = 4 frames
C2/FF6F: 8F 18 01 00  STA $000118     ; repeat settings
C2/FF73: A9 00 00     LDA #$0000
C2/FF76: 8F 4D 01 00  STA $00014D     ; single controller
C2/FF7A: 68           PLA 
C2/FF7B: 28           PLP 
C2/FF7C: 60           RTS 

; [ update joypad config ]

C2/FF7D: 8B           PHB 
C2/FF7E: 0B           PHD 
C2/FF7F: 48           PHA 
C2/FF80: DA           PHX 
C2/FF81: 5A           PHY 
C2/FF82: 08           PHP 
C2/FF83: F4 00 00     PEA $0000
C2/FF86: AB           PLB 
C2/FF87: AB           PLB 
C2/FF88: C2 30        REP #$30
C2/FF8A: F4 00 01     PEA $0100
C2/FF8D: 2B           PLD 
C2/FF8E: A9 16 04     LDA #$0416      ; delay = 22 frames, rate = 4 frames
C2/FF91: 85 18        STA $18
C2/FF93: 64 4D        STZ $4D         ; single controller
C2/FF95: A0 00 00     LDY #$0000
C2/FF98: BB           TYX 
C2/FF99: B9 75 09     LDA $0975,Y     ; joypad config
C2/FF9C: 20 C2 FF     JSR $FFC2
C2/FF9F: 95 26        STA $26,X
C2/FFA1: C8           INY 
C2/FFA2: E8           INX 
C2/FFA3: E8           INX 
C2/FFA4: C0 07 00     CPY #$0007
C2/FFA7: D0 F0        BNE $FF99
C2/FFA9: 64 0E        STZ $0E
C2/FFAB: 64 14        STZ $14
C2/FFAD: 64 16        STZ $16
C2/FFAF: A9 01 01     LDA #$0101
C2/FFB2: A2 0C 00     LDX #$000C
C2/FFB5: CA           DEX 
C2/FFB6: CA           DEX 
C2/FFB7: 95 1A        STA $1A,X
C2/FFB9: D0 FA        BNE $FFB5
C2/FFBB: 28           PLP 
C2/FFBC: 7A           PLY 
C2/FFBD: FA           PLX 
C2/FFBE: 68           PLA 
C2/FFBF: 2B           PLD 
C2/FFC0: AB           PLB 
C2/FFC1: 60           RTS 

; [  ]

C2/FFC2: DA           PHX 
C2/FFC3: 29 FC 00     AND #$00FC
C2/FFC6: EB           XBA 
C2/FFC7: A2 00 00     LDX #$0000
C2/FFCA: 0A           ASL 
C2/FFCB: B0 0A        BCS $FFD7
C2/FFCD: E8           INX 
C2/FFCE: E8           INX 
C2/FFCF: E0 0C 00     CPX #$000C
C2/FFD2: D0 F6        BNE $FFCA
C2/FFD4: A2 00 00     LDX #$0000
C2/FFD7: BF B8 E7 C0  LDA $C0E7B8,X
C2/FFDB: FA           PLX 
C2/FFDC: 60           RTS 

C2/FFDD: 00 00        BRK $00
C2/FFDF: 00 00        BRK $00
C2/FFE1: 00 00        BRK $00
C2/FFE3: 00 00        BRK $00
C2/FFE5: 00 00        BRK $00
C2/FFE7: 00 00        BRK $00
C2/FFE9: 00

C2/FFEA:              .DW $C25F, $C261, $C2A4, $C2E8, $C32D, $C26D, $C2CC
C2/FFF8:              .DW $F932, $F949, $F984, $F9D6

; =====================================[ cutscenes ]======================================

; show cutscene
C3/0000: 80 0D        BRA $000F

; [ decompress ]

C3/0002: 08           PHP 
C3/0003: 8B           PHB 
C3/0004: 0B           PHD 
C3/0005: 20 3D 00     JSR $003D       ; init decompression
C3/0008: 20 53 00     JSR $0053       ; decompress
C3/000B: 2B           PLD 
C3/000C: AB           PLB 
C3/000D: 28           PLP 
C3/000E: 6B           RTL 

; [ show cutscene ]

; A: cutscene id

C3/000F: 48           PHA 
C3/0010: 20 3D 00     JSR $003D       ; init decompression
C3/0013: 78           SEI 
C3/0014: A9 80        LDA #$80
C3/0016: 8D 00 21     STA $2100
C3/0019: A9 00        LDA #$00
C3/001B: 8D 00 42     STA $4200
C3/001E: A5 C7        LDA $C7
C3/0020: 8D 0C 42     STA $420C
C3/0023: A9 C3        LDA #$C3
C3/0025: 85 D2        STA $D2
C3/0027: A2 4D 7E     LDX #$7E4D      ; C3/7E4D
C3/002A: 86 D0        STX $D0
C3/002C: A9 7F        LDA #$7F
C3/002E: 85 D5        STA $D5
C3/0030: A2 00 80     LDX #$8000      ; 7F/8000
C3/0033: 86 D3        STX $D3
C3/0035: 20 53 00     JSR $0053       ; decompress
C3/0038: 68           PLA 
C3/0039: 5C 00 80 7F  JML $7F8000     ; 

; [ init decompression ]

C3/003D: A9 00        LDA #$00
C3/003F: 48           PHA 
C3/0040: AB           PLB 
C3/0041: C2 20        REP #$20
C3/0043: A9 20 04     LDA #$0420      ; direct page is at $0420
C3/0046: 5B           TCD 
C3/0047: E2 20        SEP #$20
C3/0049: A2 00 00     LDX #$0000
C3/004C: 86 C7        STX $C7
C3/004E: A9 FF        LDA #$FF
C3/0050: 85 C6        STA $C6
C3/0052: 60           RTS 

; [ decompress ]

; ++$04F0/$D0: source
; ++$04F3/$D3: destination

C3/0053: 8B           PHB 
C3/0054: A9 7F        LDA #$7F
C3/0056: 48           PHA 
C3/0057: AB           PLB 
C3/0058: A9 7F        LDA #$7F
C3/005A: 85 C9        STA $C9
C3/005C: C2 20        REP #$20
C3/005E: A9 FF 07     LDA #$07FF      ; buffer mask
C3/0061: 85 DE        STA $DE
C3/0063: A5 D0        LDA $D0
C3/0065: C9 FF FF     CMP #$FFFF
C3/0068: D0 20        BNE $008A
C3/006A: E2 20        SEP #$20
C3/006C: A7 D0        LDA [$D0]
C3/006E: C2 20        REP #$20
C3/0070: 25 C6        AND $C6
C3/0072: 85 CA        STA $CA
C3/0074: E6 D0        INC $D0
C3/0076: E2 20        SEP #$20
C3/0078: E6 D2        INC $D2
C3/007A: A7 D0        LDA [$D0]
C3/007C: C2 20        REP #$20
C3/007E: 25 C6        AND $C6
C3/0080: EB           XBA 
C3/0081: 05 CA        ORA $CA
C3/0083: 3A           DEC 
C3/0084: 85 CA        STA $CA
C3/0086: E6 D0        INC $D0
C3/0088: 80 19        BRA $00A3
C3/008A: A7 D0        LDA [$D0]       ; data length
C3/008C: 3A           DEC 
C3/008D: 85 CA        STA $CA
C3/008F: E6 D0        INC $D0
C3/0091: D0 06        BNE $0099
C3/0093: E2 20        SEP #$20
C3/0095: E6 D2        INC $D2
C3/0097: C2 20        REP #$20
C3/0099: E6 D0        INC $D0
C3/009B: D0 06        BNE $00A3
C3/009D: E2 20        SEP #$20
C3/009F: E6 D2        INC $D2
C3/00A1: C2 20        REP #$20
C3/00A3: A2 DE 07     LDX #$07DE
C3/00A6: 86 CC        STX $CC         ; set buffer pointer
C3/00A8: A6 C7        LDX $C7
C3/00AA: 8A           TXA 
C3/00AB: A8           TAY 
C3/00AC: 9D FF F7     STA $F7FF,X     ; clear buffer
C3/00AF: E8           INX 
C3/00B0: E8           INX 
C3/00B1: E4 CC        CPX $CC
C3/00B3: D0 F7        BNE $00AC
C3/00B5: 64 CE        STZ $CE
C3/00B7: 46 CE        LSR $CE
C3/00B9: A5 CE        LDA $CE
C3/00BB: 29 80 00     AND #$0080
C3/00BE: D0 16        BNE $00D6       ; branch if still working on a chunk
C3/00C0: E2 20        SEP #$20
C3/00C2: A7 D0        LDA [$D0]       ; header byte
C3/00C4: C2 20        REP #$20
C3/00C6: E6 D0        INC $D0
C3/00C8: D0 06        BNE $00D0
C3/00CA: E2 20        SEP #$20
C3/00CC: E6 D2        INC $D2
C3/00CE: C2 20        REP #$20
C3/00D0: 25 C6        AND $C6
C3/00D2: 05 C8        ORA $C8
C3/00D4: 85 CE        STA $CE         ; header byte
C3/00D6: A5 CE        LDA $CE
C3/00D8: 29 01 00     AND #$0001
C3/00DB: F0 2E        BEQ $010B       ; branch if compressed
C3/00DD: E2 20        SEP #$20
C3/00DF: A7 D0        LDA [$D0]       ; data byte
C3/00E1: C2 20        REP #$20
C3/00E3: E6 D0        INC $D0
C3/00E5: D0 06        BNE $00ED
C3/00E7: E2 20        SEP #$20
C3/00E9: E6 D2        INC $D2
C3/00EB: C2 20        REP #$20
C3/00ED: E2 20        SEP #$20
C3/00EF: 97 D3        STA [$D3],Y     ; copy to destination
C3/00F1: C2 20        REP #$20
C3/00F3: C4 CA        CPY $CA
C3/00F5: D0 06        BNE $00FD
C3/00F7: A5 C7        LDA $C7         ; end of data
C3/00F9: E2 20        SEP #$20
C3/00FB: AB           PLB 
C3/00FC: 60           RTS 
C3/00FD: C8           INY 
C3/00FE: A6 CC        LDX $CC
C3/0100: 9D FF F7     STA $F7FF,X     ; copy to buffer
C3/0103: 8A           TXA 
C3/0104: 1A           INC 
C3/0105: 25 DE        AND $DE         ; buffer mask
C3/0107: 85 CC        STA $CC
C3/0109: 80 AC        BRA $00B7
C3/010B: E2 20        SEP #$20
C3/010D: A7 D0        LDA [$D0]       ; first byte
C3/010F: EB           XBA 
C3/0110: C2 20        REP #$20
C3/0112: E6 D0        INC $D0
C3/0114: D0 04        BNE $011A
C3/0116: E2 20        SEP #$20
C3/0118: E6 D2        INC $D2
C3/011A: E2 20        SEP #$20
C3/011C: A7 D0        LDA [$D0]       ; second byte
C3/011E: 85 DA        STA $DA
C3/0120: 4A           LSR 
C3/0121: 4A           LSR 
C3/0122: 4A           LSR 
C3/0123: 4A           LSR 
C3/0124: 4A           LSR 
C3/0125: EB           XBA 
C3/0126: C2 20        REP #$20
C3/0128: 85 D8        STA $D8
C3/012A: A5 DA        LDA $DA
C3/012C: 29 1F 00     AND #$001F
C3/012F: 1A           INC 
C3/0130: 1A           INC 
C3/0131: 1A           INC 
C3/0132: 85 DA        STA $DA         ; string length
C3/0134: 64 DC        STZ $DC         ; clear byte counter
C3/0136: E6 D0        INC $D0
C3/0138: D0 06        BNE $0140
C3/013A: E2 20        SEP #$20
C3/013C: E6 D2        INC $D2
C3/013E: C2 20        REP #$20
C3/0140: A5 DC        LDA $DC         ; byte counter
C3/0142: C5 DA        CMP $DA
C3/0144: F0 27        BEQ $016D       ; branch when counter reaches the string length
C3/0146: A5 D8        LDA $D8
C3/0148: 18           CLC 
C3/0149: 65 DC        ADC $DC
C3/014B: 25 DE        AND $DE         ; buffer mask
C3/014D: AA           TAX 
C3/014E: E2 20        SEP #$20
C3/0150: BD FF F7     LDA $F7FF,X
C3/0153: 97 D3        STA [$D3],Y     ; copy to destination
C3/0155: C2 20        REP #$20
C3/0157: C4 CA        CPY $CA
C3/0159: F0 9C        BEQ $00F7
C3/015B: C8           INY 
C3/015C: A6 CC        LDX $CC
C3/015E: 9D FF F7     STA $F7FF,X     ; copy to buffer
C3/0161: E6 CC        INC $CC
C3/0163: A5 CC        LDA $CC
C3/0165: 25 DE        AND $DE
C3/0167: 85 CC        STA $CC
C3/0169: E6 DC        INC $DC
C3/016B: 80 D3        BRA $0140
C3/016D: 82 47 FF     BRL $00B7

; C3/0170-C3/0200 appears to be dummied code
; it matches the compressed code at 7E/818A-7E/821A
; my guess is that this is left over garbage from before they decided to compress it

C3/0170: 2E FF 
C3/0172: 64 44        STZ $44
C3/0174: A2 05 00     LDX #$0005
C3/0177: 86 48        STX $48
C3/0179: 20 BC 0A     JSR $0ABC
C3/017C: 20 96 1C     JSR $1C96
C3/017F: 20 D9 19     JSR $19D9
C3/0182: C6 44        DEC $44
C3/0184: D0 07        BNE $018D
C3/0186: A6 48        LDX $48
C3/0188: CA           DEX 
C3/0189: F0 53        BEQ $01DE
C3/018B: 86 48        STX $48
C3/018D: A5 43        LDA $43
C3/018F: D0 06        BNE $0197
C3/0191: A5 42        LDA $42
C3/0193: D0 02        BNE $0197
C3/0195: 80 E2        BRA $0179
C3/0197: 20 43 0C     JSR $0C43
C3/019A: B0 06        BCS $01A2
C3/019C: A9 01        LDA #$01
C3/019E: 85 4B        STA $4B
C3/01A0: 80 3C        BRA $01DE
C3/01A2: A9 F0        LDA #$F0
C3/01A4: 85 44        STA $44
C3/01A6: A9 01        LDA #$01
C3/01A8: 14 70        TRB $70
C3/01AA: A9 02        LDA #$02
C3/01AC: 04 70        TSB $70
C3/01AE: 64 73        STZ $73
C3/01B0: A9 04        LDA #$04
C3/01B2: 85 72        STA $72
C3/01B4: 20 BC 0A     JSR $0ABC
C3/01B7: 20 96 1C     JSR $1C96
C3/01BA: 20 D9 19     JSR $19D9
C3/01BD: A5 71        LDA $71
C3/01BF: D0 F3        BNE $01B4
C3/01C1: 20 37 00     JSR $0037
C3/01C4: A9 F0        LDA #$F0
C3/01C6: 8D 00 1D     STA $1D00
C3/01C9: 22 04 00 C4  JSL $C40004
C3/01CD: A2 01 00     LDX #$0001
C3/01D0: 8E 00 1D     STX $1D00
C3/01D3: A2 18 04     LDX #$0418
C3/01D6: 8E 02 1D     STX $1D02
C3/01D9: 22 04 00 C4  JSL $C40004
C3/01DD: 60           RTS 

C3/01DE: A9 F0        LDA #$F0
C3/01E0: 8D 00 1D     STA $1D00
C3/01E3: 22 04 00 C4  JSL $C40004
C3/01E7: A2 01 00     LDX #$0001
C3/01EA: 8E 00 1D     STX $1D00
C3/01ED: A2 08 0F     LDX #$0F08
C3/01F0: 8E 02 1D     STX $1D02
C3/01F3: 22 04 00 C4  JSL $C40004
C3/01F7: A9 40        LDA #$40
C3/01F9: 85 44        STA $44
C3/01FB: A6 02        LDX $02
C3/01FD: 86 68        STX $68
C3/01FF: 20 01 D1     JSR $D101

; [ cutscene ]

7E/8000: 48           PHA 
7E/8001: 20 D9 95     JSR $95D9
7E/8004: 68           PLA 
7E/8005: 8D 20 04     STA $0420
7E/8008: C2 20        REP #$20
7E/800A: 29 0F 00     AND #$000F
7E/800D: 0A           ASL 
7E/800E: AA           TAX 
7E/800F: E2 20        SEP #$20
7E/8011: 4B           PHK 
7E/8012: AB           PLB 
7E/8013: FC 1A 80     JSR ($801A,X)
7E/8016: 20 EC 95     JSR $95EC
7E/8019: 6B           RTL 

; cutscene jump table
7E/801A:              .DW $8C78, $804B, $8516, $8784, $8516, $867D, $8516, $8AA2
7E/802A:              .DW $8C09, $8B80, $8888, $8963, $804A, $804A, $804A, $804A

7E/803A: 78           SEI 
7E/803B: A9 80        LDA #$80
7E/803D: 8D 00 21     STA $2100
7E/8040: A9 00        LDA #$00
7E/8042: 8D 00 42     STA $4200
7E/8045: A5 C7        LDA $C7
7E/8047: 8D 0C 42     STA $420C
7E/804A: 60           RTS 

; [ cutscene $01: title/credits ]

7E/804B: 20 A5 94     JSR $94A5
7E/804E: 20 65 94     JSR $9465
7E/8051: 20 F3 AF     JSR $AFF3
7E/8054: 20 3A 96     JSR $963A
7E/8057: 20 63 A9     JSR $A963
7E/805A: 20 3B 98     JSR $983B
7E/805D: 20 1D B2     JSR $B21D
7E/8060: 20 A9 B5     JSR $B5A9
7E/8063: 20 0E 97     JSR $970E
7E/8066: 20 09 C2     JSR $C209
7E/8069: A2 00 02     LDX #$0200
7E/806C: 86 30        STX $30
7E/806E: A2 80 01     LDX #$0180
7E/8071: 86 32        STX $32
7E/8073: A9 01        LDA #$01
7E/8075: 04 70        TSB $70
7E/8077: 64 71        STZ $71
7E/8079: 64 73        STZ $73
7E/807B: A9 02        LDA #$02
7E/807D: 85 72        STA $72
7E/807F: A2 00 03     LDX #$0300
7E/8082: 86 66        STX $66
7E/8084: A2 10 00     LDX #$0010
7E/8087: 86 62        STX $62
7E/8089: A2 AE 00     LDX #$00AE
7E/808C: 86 60        STX $60
7E/808E: A2 20 00     LDX #$0020
7E/8091: 86 64        STX $64
7E/8093: 20 70 A5     JSR $A570
7E/8096: A2 00 80     LDX #$8000
7E/8099: 86 58        STX $58
7E/809B: A2 00 80     LDX #$8000
7E/809E: 86 5C        STX $5C
7E/80A0: A2 00 80     LDX #$8000
7E/80A3: 86 5E        STX $5E
7E/80A5: A9 01        LDA #$01
7E/80A7: 85 4E        STA $4E
7E/80A9: 64 45        STZ $45
7E/80AB: A2 01 00     LDX #$0001
7E/80AE: 8E 00 1D     STX $1D00
7E/80B1: A2 18 00     LDX #$0018
7E/80B4: 8E 02 1D     STX $1D02
7E/80B7: 22 04 00 C4  JSL $C40004
7E/80BB: A9 10        LDA #$10
7E/80BD: 8F 01 F1 7F  STA $7FF101
7E/80C1: C2 20        REP #$20
7E/80C3: A9 00 E0     LDA #$E000
7E/80C6: 8F 10 F1 7F  STA $7FF110
7E/80CA: A9 20 00     LDA #$0020
7E/80CD: 8F 20 F1 7F  STA $7FF120
7E/80D1: E2 20        SEP #$20
7E/80D3: A9 01        LDA #$01
7E/80D5: 85 74        STA $74
7E/80D7: A9 01        LDA #$01
7E/80D9: 04 4F        TSB $4F
7E/80DB: A9 81        LDA #$81
7E/80DD: 8D 00 42     STA $4200
7E/80E0: 58           CLI 
7E/80E1: A6 C7        LDX $C7
7E/80E3: 86 42        STX $42
7E/80E5: A9 80        LDA #$80
7E/80E7: 85 44        STA $44
7E/80E9: 20 5D 94     JSR $945D
7E/80EC: 20 A1 95     JSR $95A1
7E/80EF: 90 03        BCC $80F4
7E/80F1: 82 C6 00     BRL $81BA
7E/80F4: 20 11 A8     JSR $A811
7E/80F7: 20 27 A5     JSR $A527
7E/80FA: 20 54 A5     JSR $A554
7E/80FD: C6 44        DEC $44
7E/80FF: D0 E8        BNE $80E9
7E/8101: A9 E0        LDA #$E0
7E/8103: 8F 05 F1 7F  STA $7FF105
7E/8107: A9 C0        LDA #$C0
7E/8109: 8F 07 F1 7F  STA $7FF107
7E/810D: C2 20        REP #$20
7E/810F: A9 E0 EB     LDA #$EBE0
7E/8112: 8F 14 F1 7F  STA $7FF114
7E/8116: A9 20 00     LDA #$0020
7E/8119: 8F 24 F1 7F  STA $7FF124
7E/811D: A9 E0 EF     LDA #$EFE0
7E/8120: 8F 16 F1 7F  STA $7FF116
7E/8124: A9 20 00     LDA #$0020
7E/8127: 8F 26 F1 7F  STA $7FF126
7E/812B: E2 20        SEP #$20
7E/812D: A9 04        LDA #$04
7E/812F: 09 08        ORA #$08
7E/8131: 04 74        TSB $74
7E/8133: A9 20        LDA #$20
7E/8135: 85 44        STA $44
7E/8137: 20 5D 94     JSR $945D
7E/813A: 20 A1 95     JSR $95A1
7E/813D: 90 03        BCC $8142
7E/813F: 82 78 00     BRL $81BA
7E/8142: 20 11 A8     JSR $A811
7E/8145: 20 27 A5     JSR $A527
7E/8148: 20 C5 B6     JSR $B6C5
7E/814B: A5 44        LDA $44
7E/814D: 29 03        AND #$03
7E/814F: D0 0A        BNE $815B
7E/8151: A9 02        LDA #$02
7E/8153: 20 01 AE     JSR $AE01
7E/8156: A9 03        LDA #$03
7E/8158: 20 01 AE     JSR $AE01
7E/815B: 20 54 A5     JSR $A554
7E/815E: C6 44        DEC $44
7E/8160: D0 D5        BNE $8137
7E/8162: A9 D0        LDA #$D0
7E/8164: 85 44        STA $44
7E/8166: 20 5D 94     JSR $945D
7E/8169: 20 A1 95     JSR $95A1
7E/816C: 90 03        BCC $8171
7E/816E: 82 49 00     BRL $81BA
7E/8171: 20 11 A8     JSR $A811
7E/8174: 20 27 A5     JSR $A527
7E/8177: A5 44        LDA $44
7E/8179: 29 03        AND #$03
7E/817B: D0 0A        BNE $8187
7E/817D: A9 02        LDA #$02
7E/817F: 20 01 AE     JSR $AE01
7E/8182: A9 03        LDA #$03
7E/8184: 20 01 AE     JSR $AE01
7E/8187: 20 54 A5     JSR $A554
7E/818A: C6 44        DEC $44
7E/818C: D0 D8        BNE $8166
7E/818E: A2 05 00     LDX #$0005
7E/8191: 86 48        STX $48
7E/8193: 20 5D 94     JSR $945D
7E/8196: 20 11 A8     JSR $A811
7E/8199: 20 54 A5     JSR $A554
7E/819C: C6 44        DEC $44
7E/819E: D0 07        BNE $81A7
7E/81A0: A6 48        LDX $48
7E/81A2: CA           DEX 
7E/81A3: F0 51        BEQ $81F6
7E/81A5: 86 48        STX $48
7E/81A7: A5 43        LDA $43
7E/81A9: D0 06        BNE $81B1
7E/81AB: A5 42        LDA $42
7E/81AD: D0 02        BNE $81B1
7E/81AF: 80 E2        BRA $8193
7E/81B1: 20 AB 95     JSR $95AB
7E/81B4: B0 04        BCS $81BA
7E/81B6: E6 4B        INC $4B
7E/81B8: 80 3C        BRA $81F6
7E/81BA: A9 F0        LDA #$F0
7E/81BC: 85 44        STA $44
7E/81BE: A9 01        LDA #$01
7E/81C0: 14 70        TRB $70
7E/81C2: A9 02        LDA #$02
7E/81C4: 04 70        TSB $70
7E/81C6: 64 73        STZ $73
7E/81C8: A9 04        LDA #$04
7E/81CA: 85 72        STA $72
7E/81CC: 20 5D 94     JSR $945D
7E/81CF: 20 11 A8     JSR $A811
7E/81D2: 20 54 A5     JSR $A554
7E/81D5: A5 71        LDA $71
7E/81D7: D0 F3        BNE $81CC
7E/81D9: 20 3A 80     JSR $803A
7E/81DC: A9 F0        LDA #$F0
7E/81DE: 8D 00 1D     STA $1D00
7E/81E1: 22 04 00 C4  JSL $C40004
7E/81E5: A2 01 00     LDX #$0001
7E/81E8: 8E 00 1D     STX $1D00
7E/81EB: A2 18 04     LDX #$0418
7E/81EE: 8E 02 1D     STX $1D02
7E/81F1: 22 04 00 C4  JSL $C40004
7E/81F5: 60           RTS 
7E/81F6: A9 F0        LDA #$F0
7E/81F8: 8D 00 1D     STA $1D00
7E/81FB: 22 04 00 C4  JSL $C40004
7E/81FF: A2 01 00     LDX #$0001
7E/8202: 8E 00 1D     STX $1D00
7E/8205: A2 08 0F     LDX #$0F08
7E/8208: 8E 02 1D     STX $1D02
7E/820B: 22 04 00 C4  JSL $C40004
7E/820F: A9 40        LDA #$40
7E/8211: 85 44        STA $44
7E/8213: A6 C7        LDX $C7
7E/8215: 86 68        STX $68
7E/8217: 20 5D 94     JSR $945D
7E/821A: 20 C6 A8     JSR $A8C6
7E/821D: 20 0E A5     JSR $A50E
7E/8220: 20 62 A5     JSR $A562
7E/8223: A9 02        LDA #$02
7E/8225: 20 37 AE     JSR $AE37
7E/8228: A9 03        LDA #$03
7E/822A: 20 37 AE     JSR $AE37
7E/822D: C6 44        DEC $44
7E/822F: D0 E6        BNE $8217
7E/8231: 20 C1 AF     JSR $AFC1
7E/8234: 20 5D 94     JSR $945D
7E/8237: A9 01        LDA #$01
7E/8239: 14 4F        TRB $4F
7E/823B: A9 10        LDA #$10
7E/823D: 8F 03 F1 7F  STA $7FF103
7E/8241: C2 20        REP #$20
7E/8243: A9 00 E4     LDA #$E400
7E/8246: 8F 12 F1 7F  STA $7FF112
7E/824A: A9 20 00     LDA #$0020
7E/824D: 8F 22 F1 7F  STA $7FF122
7E/8251: E2 20        SEP #$20
7E/8253: A9 01        LDA #$01
7E/8255: 14 74        TRB $74
7E/8257: A9 02        LDA #$02
7E/8259: 04 74        TSB $74
7E/825B: A9 20        LDA #$20
7E/825D: 85 44        STA $44
7E/825F: 20 5D 94     JSR $945D
7E/8262: A9 01        LDA #$01
7E/8264: 20 37 AE     JSR $AE37
7E/8267: C6 44        DEC $44
7E/8269: D0 F4        BNE $825F
7E/826B: A9 11        LDA #$11
7E/826D: 85 3B        STA $3B
7E/826F: 20 79 BB     JSR $BB79
7E/8272: 20 5D 94     JSR $945D
7E/8275: 20 97 A7     JSR $A797
7E/8278: A9 02        LDA #$02
7E/827A: 14 74        TRB $74
7E/827C: 20 5D 94     JSR $945D
7E/827F: 20 B0 BB     JSR $BBB0
7E/8282: 20 5D 94     JSR $945D
7E/8285: 20 CA BB     JSR $BBCA
7E/8288: 20 5D 94     JSR $945D
7E/828B: 20 E4 BB     JSR $BBE4
7E/828E: 20 5D 94     JSR $945D
7E/8291: A9 19        LDA #$19
7E/8293: 85 B4        STA $B4
7E/8295: A9 00        LDA #$00
7E/8297: 85 B3        STA $B3
7E/8299: A6 C7        LDX $C7
7E/829B: 86 AC        STX $AC
7E/829D: A2 00 00     LDX #$0000
7E/82A0: 86 AE        STX $AE
7E/82A2: A9 7F        LDA #$7F
7E/82A4: 85 B0        STA $B0
7E/82A6: A2 00 10     LDX #$1000
7E/82A9: 86 B1        STX $B1
7E/82AB: A9 02        LDA #$02
7E/82AD: 04 4F        TSB $4F
7E/82AF: 20 5D 94     JSR $945D
7E/82B2: A9 19        LDA #$19
7E/82B4: 85 B4        STA $B4
7E/82B6: A2 00 10     LDX #$1000
7E/82B9: 86 AC        STX $AC
7E/82BB: A2 00 10     LDX #$1000
7E/82BE: 86 AE        STX $AE
7E/82C0: A9 7F        LDA #$7F
7E/82C2: 85 B0        STA $B0
7E/82C4: A2 00 10     LDX #$1000
7E/82C7: 86 B1        STX $B1
7E/82C9: A9 02        LDA #$02
7E/82CB: 04 4F        TSB $4F
7E/82CD: 20 5D 94     JSR $945D
7E/82D0: A9 02        LDA #$02
7E/82D2: 14 4F        TRB $4F
7E/82D4: A9 01        LDA #$01
7E/82D6: 04 4F        TSB $4F
7E/82D8: A2 80 02     LDX #$0280
7E/82DB: 86 34        STX $34
7E/82DD: A2 A0 02     LDX #$02A0
7E/82E0: 86 36        STX $36
7E/82E2: 64 40        STZ $40
7E/82E4: 20 FA B3     JSR $B3FA
7E/82E7: A9 A0        LDA #$A0
7E/82E9: 85 44        STA $44
7E/82EB: 64 46        STZ $46
7E/82ED: 20 5D 94     JSR $945D
7E/82F0: 20 38 A5     JSR $A538
7E/82F3: 20 EB B5     JSR $B5EB
7E/82F6: C6 44        DEC $44
7E/82F8: D0 F3        BNE $82ED
7E/82FA: 20 5D 94     JSR $945D
7E/82FD: 20 EB B5     JSR $B5EB
7E/8300: 20 44 A2     JSR $A244
7E/8303: 20 5D 94     JSR $945D
7E/8306: 20 EB B5     JSR $B5EB
7E/8309: 20 34 BE     JSR $BE34
7E/830C: A9 48        LDA #$48
7E/830E: 85 44        STA $44
7E/8310: 64 46        STZ $46
7E/8312: 20 5D 94     JSR $945D
7E/8315: 20 EB B5     JSR $B5EB
7E/8318: C6 44        DEC $44
7E/831A: D0 F6        BNE $8312
7E/831C: 64 46        STZ $46
7E/831E: E6 21        INC $21
7E/8320: 64 42        STZ $42
7E/8322: 64 43        STZ $43
7E/8324: 20 5D 94     JSR $945D
7E/8327: 20 67 B6     JSR $B667
7E/832A: 20 85 BE     JSR $BE85
7E/832D: C6 44        DEC $44
7E/832F: A5 43        LDA $43
7E/8331: D0 08        BNE $833B
7E/8333: A5 42        LDA $42
7E/8335: D0 04        BNE $833B
7E/8337: A5 21        LDA $21
7E/8339: D0 E9        BNE $8324
7E/833B: 20 F4 C1     JSR $C1F4
7E/833E: 20 3B BF     JSR $BF3B
7E/8341: A9 50        LDA #$50
7E/8343: 85 44        STA $44
7E/8345: 64 45        STZ $45
7E/8347: 64 46        STZ $46
7E/8349: 20 5D 94     JSR $945D
7E/834C: 20 29 B6     JSR $B629
7E/834F: A9 04        LDA #$04
7E/8351: 20 37 AE     JSR $AE37
7E/8354: A9 05        LDA #$05
7E/8356: 20 37 AE     JSR $AE37
7E/8359: C6 44        DEC $44
7E/835B: F0 04        BEQ $8361
7E/835D: A5 4E        LDA $4E
7E/835F: D0 E8        BNE $8349
7E/8361: 20 A0 A3     JSR $A3A0
7E/8364: A9 30        LDA #$30
7E/8366: 85 44        STA $44
7E/8368: 64 45        STZ $45
7E/836A: 64 46        STZ $46
7E/836C: 20 5D 94     JSR $945D
7E/836F: 20 29 B6     JSR $B629
7E/8372: 20 1B BF     JSR $BF1B
7E/8375: 20 34 84     JSR $8434
7E/8378: 20 A8 9A     JSR $9AA8
7E/837B: 20 F2 9A     JSR $9AF2
7E/837E: E6 45        INC $45
7E/8380: C6 44        DEC $44
7E/8382: F0 04        BEQ $8388
7E/8384: A5 4E        LDA $4E
7E/8386: D0 E4        BNE $836C
7E/8388: 20 C1 AF     JSR $AFC1
7E/838B: 20 34 84     JSR $8434
7E/838E: 20 A8 9A     JSR $9AA8
7E/8391: 20 F2 9A     JSR $9AF2
7E/8394: 20 5D 94     JSR $945D
7E/8397: 20 34 84     JSR $8434
7E/839A: 20 A8 9A     JSR $9AA8
7E/839D: 20 F2 9A     JSR $9AF2
7E/83A0: A9 30        LDA #$30
7E/83A2: 85 44        STA $44
7E/83A4: 20 5D 94     JSR $945D
7E/83A7: 20 34 84     JSR $8434
7E/83AA: 20 A8 9A     JSR $9AA8
7E/83AD: 20 F2 9A     JSR $9AF2
7E/83B0: E6 45        INC $45
7E/83B2: C6 44        DEC $44
7E/83B4: F0 04        BEQ $83BA
7E/83B6: A5 4E        LDA $4E
7E/83B8: D0 EA        BNE $83A4
7E/83BA: A9 50        LDA #$50
7E/83BC: 85 44        STA $44
7E/83BE: 64 45        STZ $45
7E/83C0: 20 5D 94     JSR $945D
7E/83C3: 20 6F 84     JSR $846F
7E/83C6: 20 A8 9A     JSR $9AA8
7E/83C9: 20 F2 9A     JSR $9AF2
7E/83CC: E6 45        INC $45
7E/83CE: C6 44        DEC $44
7E/83D0: F0 04        BEQ $83D6
7E/83D2: A5 4E        LDA $4E
7E/83D4: D0 EA        BNE $83C0
7E/83D6: A9 60        LDA #$60
7E/83D8: 85 44        STA $44
7E/83DA: 64 45        STZ $45
7E/83DC: A5 21        LDA $21
7E/83DE: F0 0C        BEQ $83EC
7E/83E0: A2 81 44     LDX #$4481
7E/83E3: 8E 00 1D     STX $1D00
7E/83E6: 22 04 00 C4  JSL $C40004
7E/83EA: 80 0E        BRA $83FA
7E/83EC: A5 4B        LDA $4B
7E/83EE: D0 F0        BNE $83E0
7E/83F0: A2 81 40     LDX #$4081
7E/83F3: 8E 00 1D     STX $1D00
7E/83F6: 22 04 00 C4  JSL $C40004
7E/83FA: A9 01        LDA #$01
7E/83FC: 14 70        TRB $70
7E/83FE: A9 02        LDA #$02
7E/8400: 04 70        TSB $70
7E/8402: 64 73        STZ $73
7E/8404: A9 04        LDA #$04
7E/8406: 85 72        STA $72
7E/8408: 20 5D 94     JSR $945D
7E/840B: 20 98 84     JSR $8498
7E/840E: 20 A8 9A     JSR $9AA8
7E/8411: 20 F2 9A     JSR $9AF2
7E/8414: E6 45        INC $45
7E/8416: C6 44        DEC $44
7E/8418: F0 04        BEQ $841E
7E/841A: A5 4E        LDA $4E
7E/841C: D0 EA        BNE $8408
7E/841E: 20 5D 94     JSR $945D
7E/8421: A5 71        LDA $71
7E/8423: D0 F9        BNE $841E
7E/8425: 20 3A 80     JSR $803A
7E/8428: A5 21        LDA $21
7E/842A: D0 07        BNE $8433
7E/842C: A5 4B        LDA $4B
7E/842E: D0 03        BNE $8433
7E/8430: 82 18 FC     BRL $804B
7E/8433: 60           RTS 

7E/8434: A5 45        LDA $45
7E/8436: C9 02        CMP #$02
7E/8438: D0 09        BNE $8443
7E/843A: 20 8F 9A     JSR $9A8F
7E/843D: 20 1E 9A     JSR $9A1E
7E/8440: 82 3E 16     BRL $9A81
7E/8443: C9 04        CMP #$04
7E/8445: D0 12        BNE $8459
7E/8447: 20 8F 9A     JSR $9A8F
7E/844A: 20 A8 9A     JSR $9AA8
7E/844D: 20 1E 9A     JSR $9A1E
7E/8450: 20 81 9A     JSR $9A81
7E/8453: 20 39 9A     JSR $9A39
7E/8456: 82 FE 15     BRL $9A57
7E/8459: C9 06        CMP #$06
7E/845B: D0 11        BNE $846E
7E/845D: 20 8F 9A     JSR $9A8F
7E/8460: 20 A8 9A     JSR $9AA8
7E/8463: 20 BD 9A     JSR $9ABD
7E/8466: 64 45        STZ $45
7E/8468: 20 1E 9A     JSR $9A1E
7E/846B: 82 13 16     BRL $9A81
7E/846E: 60           RTS 

7E/846F: 20 1E 9A     JSR $9A1E
7E/8472: 20 81 9A     JSR $9A81
7E/8475: A5 45        LDA $45
7E/8477: C9 02        CMP #$02
7E/8479: D0 03        BNE $847E
7E/847B: 82 11 16     BRL $9A8F
7E/847E: C9 04        CMP #$04
7E/8480: D0 06        BNE $8488
7E/8482: 20 8F 9A     JSR $9A8F
7E/8485: 82 35 16     BRL $9ABD
7E/8488: C9 06        CMP #$06
7E/848A: D0 0B        BNE $8497
7E/848C: 64 45        STZ $45
7E/848E: 20 8F 9A     JSR $9A8F
7E/8491: 20 A8 9A     JSR $9AA8
7E/8494: 82 26 16     BRL $9ABD
7E/8497: 60           RTS 

7E/8498: A5 45        LDA $45
7E/849A: C9 02        CMP #$02
7E/849C: D0 03        BNE $84A1
7E/849E: 82 EE 15     BRL $9A8F
7E/84A1: C9 04        CMP #$04
7E/84A3: D0 06        BNE $84AB
7E/84A5: 20 8F 9A     JSR $9A8F
7E/84A8: 82 12 16     BRL $9ABD
7E/84AB: C9 06        CMP #$06
7E/84AD: D0 0B        BNE $84BA
7E/84AF: 64 45        STZ $45
7E/84B1: 20 8F 9A     JSR $9A8F
7E/84B4: 20 A8 9A     JSR $9AA8
7E/84B7: 82 03 16     BRL $9ABD
7E/84BA: 60           RTS 

7E/84BB: 20 A5 94     JSR $94A5
7E/84BE: 20 65 94     JSR $9465
7E/84C1: 20 79 96     JSR $9679
7E/84C4: 20 F9 AF     JSR $AFF9
7E/84C7: 20 FC AA     JSR $AAFC
7E/84CA: 20 53 97     JSR $9753
7E/84CD: 20 8A 98     JSR $988A
7E/84D0: 20 73 B2     JSR $B273
7E/84D3: 20 7E B4     JSR $B47E
7E/84D6: 20 F4 C1     JSR $C1F4
7E/84D9: A9 01        LDA #$01
7E/84DB: 04 70        TSB $70
7E/84DD: 64 71        STZ $71
7E/84DF: 64 73        STZ $73
7E/84E1: A9 04        LDA #$04
7E/84E3: 85 72        STA $72
7E/84E5: A2 00 FF     LDX #$FF00
7E/84E8: 86 58        STX $58
7E/84EA: A2 00 80     LDX #$8000
7E/84ED: 86 5C        STX $5C
7E/84EF: A2 00 80     LDX #$8000
7E/84F2: 86 5E        STX $5E
7E/84F4: A2 90 01     LDX #$0190
7E/84F7: 86 30        STX $30
7E/84F9: A2 A8 01     LDX #$01A8
7E/84FC: 86 32        STX $32
7E/84FE: A2 10 02     LDX #$0210
7E/8501: 86 34        STX $34
7E/8503: A2 18 02     LDX #$0218
7E/8506: 86 36        STX $36
7E/8508: 20 F2 9A     JSR $9AF2
7E/850B: A9 01        LDA #$01
7E/850D: 04 4F        TSB $4F
7E/850F: A9 81        LDA #$81
7E/8511: 8D 00 42     STA $4200
7E/8514: 58           CLI 
7E/8515: 60           RTS 

; [ cutscene $02, $04, $06: falling meteor ]

7E/8516: 20 BB 84     JSR $84BB
7E/8519: A9 40        LDA #$40
7E/851B: 85 44        STA $44
7E/851D: 20 5D 94     JSR $945D
7E/8520: 20 46 B8     JSR $B846
7E/8523: 20 8F 9A     JSR $9A8F
7E/8526: 20 8F 9A     JSR $9A8F
7E/8529: 20 E4 9A     JSR $9AE4
7E/852C: 20 F2 9A     JSR $9AF2
7E/852F: A5 00        LDA $00
7E/8531: C9 F4        CMP #$F4
7E/8533: D0 06        BNE $853B
7E/8535: 20 81 AF     JSR $AF81
7E/8538: 20 E4 9A     JSR $9AE4
7E/853B: A5 00        LDA $00
7E/853D: C9 F6        CMP #$F6
7E/853F: D0 06        BNE $8547
7E/8541: 20 E4 9A     JSR $9AE4
7E/8544: 20 E4 9A     JSR $9AE4
7E/8547: C6 44        DEC $44
7E/8549: D0 D2        BNE $851D
7E/854B: A9 30        LDA #$30
7E/854D: 85 44        STA $44
7E/854F: 20 5D 94     JSR $945D
7E/8552: 20 46 B8     JSR $B846
7E/8555: 20 8F 9A     JSR $9A8F
7E/8558: 20 8F 9A     JSR $9A8F
7E/855B: 20 E4 9A     JSR $9AE4
7E/855E: 20 BD 9A     JSR $9ABD
7E/8561: 20 A8 9A     JSR $9AA8
7E/8564: 20 F2 9A     JSR $9AF2
7E/8567: A5 00        LDA $00
7E/8569: C9 F4        CMP #$F4
7E/856B: D0 06        BNE $8573
7E/856D: 20 81 AF     JSR $AF81
7E/8570: 20 E4 9A     JSR $9AE4
7E/8573: A5 00        LDA $00
7E/8575: C9 F6        CMP #$F6
7E/8577: D0 06        BNE $857F
7E/8579: 20 E4 9A     JSR $9AE4
7E/857C: 20 E4 9A     JSR $9AE4
7E/857F: C6 44        DEC $44
7E/8581: D0 CC        BNE $854F
7E/8583: A5 00        LDA $00
7E/8585: C9 F6        CMP #$F6
7E/8587: D0 0E        BNE $8597
7E/8589: A9 01        LDA #$01
7E/858B: 14 70        TRB $70
7E/858D: A9 02        LDA #$02
7E/858F: 04 70        TSB $70
7E/8591: 64 73        STZ $73
7E/8593: A9 01        LDA #$01
7E/8595: 85 72        STA $72
7E/8597: A9 10        LDA #$10
7E/8599: 85 44        STA $44
7E/859B: 20 5D 94     JSR $945D
7E/859E: 20 46 B8     JSR $B846
7E/85A1: 20 8F 9A     JSR $9A8F
7E/85A4: 20 8F 9A     JSR $9A8F
7E/85A7: 20 E4 9A     JSR $9AE4
7E/85AA: 20 BD 9A     JSR $9ABD
7E/85AD: 20 A8 9A     JSR $9AA8
7E/85B0: 20 F2 9A     JSR $9AF2
7E/85B3: A5 00        LDA $00
7E/85B5: C9 F4        CMP #$F4
7E/85B7: D0 08        BNE $85C1
7E/85B9: 20 81 AF     JSR $AF81
7E/85BC: 20 E4 9A     JSR $9AE4
7E/85BF: 80 11        BRA $85D2
7E/85C1: C9 F6        CMP #$F6
7E/85C3: D0 0D        BNE $85D2
7E/85C5: 20 E4 9A     JSR $9AE4
7E/85C8: 20 E4 9A     JSR $9AE4
7E/85CB: A5 71        LDA $71
7E/85CD: D0 CC        BNE $859B
7E/85CF: 82 68 FA     BRL $803A
7E/85D2: C6 44        DEC $44
7E/85D4: D0 C5        BNE $859B
7E/85D6: A2 2D 00     LDX #$002D
7E/85D9: 20 E4 9A     JSR $9AE4
7E/85DC: CA           DEX 
7E/85DD: D0 FA        BNE $85D9
7E/85DF: 20 C1 AF     JSR $AFC1
7E/85E2: A9 40        LDA #$40
7E/85E4: 85 44        STA $44
7E/85E6: 20 5D 94     JSR $945D
7E/85E9: 20 98 9A     JSR $9A98
7E/85EC: 20 98 9A     JSR $9A98
7E/85EF: 20 C9 9A     JSR $9AC9
7E/85F2: 20 B1 9A     JSR $9AB1
7E/85F5: 20 A1 9A     JSR $9AA1
7E/85F8: 20 F2 9A     JSR $9AF2
7E/85FB: A5 00        LDA $00
7E/85FD: C9 F4        CMP #$F4
7E/85FF: D0 06        BNE $8607
7E/8601: 20 81 AF     JSR $AF81
7E/8604: 20 C9 9A     JSR $9AC9
7E/8607: C6 44        DEC $44
7E/8609: D0 DB        BNE $85E6
7E/860B: A9 30        LDA #$30
7E/860D: 85 44        STA $44
7E/860F: 20 5D 94     JSR $945D
7E/8612: 20 98 9A     JSR $9A98
7E/8615: 20 98 9A     JSR $9A98
7E/8618: 20 C9 9A     JSR $9AC9
7E/861B: 20 F2 9A     JSR $9AF2
7E/861E: A5 00        LDA $00
7E/8620: C9 F4        CMP #$F4
7E/8622: D0 06        BNE $862A
7E/8624: 20 81 AF     JSR $AF81
7E/8627: 20 C9 9A     JSR $9AC9
7E/862A: C6 44        DEC $44
7E/862C: D0 E1        BNE $860F
7E/862E: A9 01        LDA #$01
7E/8630: 14 70        TRB $70
7E/8632: A9 02        LDA #$02
7E/8634: 04 70        TSB $70
7E/8636: 64 73        STZ $73
7E/8638: A9 01        LDA #$01
7E/863A: 85 72        STA $72
7E/863C: 20 5D 94     JSR $945D
7E/863F: 20 C9 9A     JSR $9AC9
7E/8642: 20 98 9A     JSR $9A98
7E/8645: 20 98 9A     JSR $9A98
7E/8648: 20 F2 9A     JSR $9AF2
7E/864B: A5 00        LDA $00
7E/864D: C9 F4        CMP #$F4
7E/864F: D0 06        BNE $8657
7E/8651: 20 81 AF     JSR $AF81
7E/8654: 20 C9 9A     JSR $9AC9
7E/8657: E6 44        INC $44
7E/8659: A5 71        LDA $71
7E/865B: D0 DF        BNE $863C
7E/865D: 82 DA F9     BRL $803A
7E/8660: 20 A5 94     JSR $94A5
7E/8663: 20 65 94     JSR $9465
7E/8666: 20 B8 96     JSR $96B8
7E/8669: 20 F4 C1     JSR $C1F4
7E/866C: A9 01        LDA #$01
7E/866E: 04 70        TSB $70
7E/8670: 64 71        STZ $71
7E/8672: 64 73        STZ $73
7E/8674: A9 02        LDA #$02
7E/8676: 85 72        STA $72
7E/8678: A9 01        LDA #$01
7E/867A: 04 4F        TSB $4F
7E/867C: 60           RTS 
7E/867D: 20 60 86     JSR $8660
7E/8680: A2 00 FF     LDX #$FF00
7E/8683: 86 58        STX $58
7E/8685: A2 00 80     LDX #$8000
7E/8688: 86 5C        STX $5C
7E/868A: A2 00 80     LDX #$8000
7E/868D: 86 5E        STX $5E
7E/868F: A2 E8 00     LDX #$00E8
7E/8692: 86 30        STX $30
7E/8694: A2 00 02     LDX #$0200
7E/8697: 86 32        STX $32
7E/8699: A2 68 01     LDX #$0168
7E/869C: 86 34        STX $34
7E/869E: A2 80 02     LDX #$0280
7E/86A1: 86 36        STX $36
7E/86A3: A9 81        LDA #$81
7E/86A5: 8D 00 42     STA $4200
7E/86A8: 58           CLI 
7E/86A9: A9 40        LDA #$40
7E/86AB: 85 44        STA $44
7E/86AD: 20 5D 94     JSR $945D
7E/86B0: A5 44        LDA $44
7E/86B2: 29 01        AND #$01
7E/86B4: D0 03        BNE $86B9
7E/86B6: 20 8F 9A     JSR $9A8F
7E/86B9: 20 F2 9A     JSR $9AF2
7E/86BC: C6 44        DEC $44
7E/86BE: D0 ED        BNE $86AD
7E/86C0: A9 60        LDA #$60
7E/86C2: 85 44        STA $44
7E/86C4: 20 5D 94     JSR $945D
7E/86C7: A5 44        LDA $44
7E/86C9: 29 01        AND #$01
7E/86CB: D0 0C        BNE $86D9
7E/86CD: 20 8F 9A     JSR $9A8F
7E/86D0: 20 A8 9A     JSR $9AA8
7E/86D3: 20 C9 9A     JSR $9AC9
7E/86D6: 20 B1 9A     JSR $9AB1
7E/86D9: 20 49 9A     JSR $9A49
7E/86DC: 20 65 9A     JSR $9A65
7E/86DF: 20 F2 9A     JSR $9AF2
7E/86E2: C6 44        DEC $44
7E/86E4: D0 DE        BNE $86C4
7E/86E6: A9 60        LDA #$60
7E/86E8: 85 44        STA $44
7E/86EA: 20 5D 94     JSR $945D
7E/86ED: A5 44        LDA $44
7E/86EF: 29 01        AND #$01
7E/86F1: D0 06        BNE $86F9
7E/86F3: 20 8F 9A     JSR $9A8F
7E/86F6: 20 E4 9A     JSR $9AE4
7E/86F9: 20 A8 9A     JSR $9AA8
7E/86FC: 20 1E 9A     JSR $9A1E
7E/86FF: 20 81 9A     JSR $9A81
7E/8702: 20 49 9A     JSR $9A49
7E/8705: 20 65 9A     JSR $9A65
7E/8708: 20 F2 9A     JSR $9AF2
7E/870B: C6 44        DEC $44
7E/870D: D0 DB        BNE $86EA
7E/870F: A9 60        LDA #$60
7E/8711: 85 44        STA $44
7E/8713: 20 5D 94     JSR $945D
7E/8716: 20 8F 9A     JSR $9A8F
7E/8719: A5 44        LDA $44
7E/871B: 29 03        AND #$03
7E/871D: D0 03        BNE $8722
7E/871F: 20 B1 9A     JSR $9AB1
7E/8722: 20 A8 9A     JSR $9AA8
7E/8725: 20 1E 9A     JSR $9A1E
7E/8728: 20 81 9A     JSR $9A81
7E/872B: 20 F2 9A     JSR $9AF2
7E/872E: C6 44        DEC $44
7E/8730: D0 E1        BNE $8713
7E/8732: A9 20        LDA #$20
7E/8734: 85 44        STA $44
7E/8736: 20 5D 94     JSR $945D
7E/8739: 20 8F 9A     JSR $9A8F
7E/873C: 20 A8 9A     JSR $9AA8
7E/873F: 20 1E 9A     JSR $9A1E
7E/8742: 20 81 9A     JSR $9A81
7E/8745: 20 1E 9A     JSR $9A1E
7E/8748: 20 81 9A     JSR $9A81
7E/874B: 20 F2 9A     JSR $9AF2
7E/874E: C6 44        DEC $44
7E/8750: D0 E4        BNE $8736
7E/8752: A9 01        LDA #$01
7E/8754: 14 70        TRB $70
7E/8756: A9 02        LDA #$02
7E/8758: 04 70        TSB $70
7E/875A: 64 73        STZ $73
7E/875C: A9 01        LDA #$01
7E/875E: 85 72        STA $72
7E/8760: 20 5D 94     JSR $945D
7E/8763: 20 8F 9A     JSR $9A8F
7E/8766: 20 B1 9A     JSR $9AB1
7E/8769: 20 A8 9A     JSR $9AA8
7E/876C: 20 1E 9A     JSR $9A1E
7E/876F: 20 81 9A     JSR $9A81
7E/8772: 20 1E 9A     JSR $9A1E
7E/8775: 20 81 9A     JSR $9A81
7E/8778: 20 F2 9A     JSR $9AF2
7E/877B: E6 44        INC $44
7E/877D: A5 71        LDA $71
7E/877F: D0 DF        BNE $8760
7E/8781: 82 B6 F8     BRL $803A

; [ cutscene $03:  ]

7E/8784: 20 60 86     JSR $8660
7E/8787: A2 00 FF     LDX #$FF00
7E/878A: 86 58        STX $58
7E/878C: A2 00 40     LDX #$4000
7E/878F: 86 5C        STX $5C
7E/8791: A2 00 80     LDX #$8000
7E/8794: 86 5E        STX $5E
7E/8796: A2 B8 01     LDX #$01B8
7E/8799: 86 30        STX $30
7E/879B: A2 B8 01     LDX #$01B8
7E/879E: 86 32        STX $32
7E/87A0: A2 38 02     LDX #$0238
7E/87A3: 86 34        STX $34
7E/87A5: A2 38 02     LDX #$0238
7E/87A8: 86 36        STX $36
7E/87AA: A9 81        LDA #$81
7E/87AC: 8D 00 42     STA $4200
7E/87AF: 58           CLI 
7E/87B0: A9 40        LDA #$40
7E/87B2: 85 44        STA $44
7E/87B4: 20 5D 94     JSR $945D
7E/87B7: A5 44        LDA $44
7E/87B9: 29 01        AND #$01
7E/87BB: D0 03        BNE $87C0
7E/87BD: 20 8F 9A     JSR $9A8F
7E/87C0: 20 F2 9A     JSR $9AF2
7E/87C3: C6 44        DEC $44
7E/87C5: D0 ED        BNE $87B4
7E/87C7: A9 60        LDA #$60
7E/87C9: 85 44        STA $44
7E/87CB: 20 5D 94     JSR $945D
7E/87CE: A5 44        LDA $44
7E/87D0: 29 01        AND #$01
7E/87D2: D0 09        BNE $87DD
7E/87D4: 20 8F 9A     JSR $9A8F
7E/87D7: 20 A8 9A     JSR $9AA8
7E/87DA: 20 E4 9A     JSR $9AE4
7E/87DD: 20 39 9A     JSR $9A39
7E/87E0: 20 57 9A     JSR $9A57
7E/87E3: 20 F2 9A     JSR $9AF2
7E/87E6: C6 44        DEC $44
7E/87E8: D0 E1        BNE $87CB
7E/87EA: A9 60        LDA #$60
7E/87EC: 85 44        STA $44
7E/87EE: 20 5D 94     JSR $945D
7E/87F1: A5 44        LDA $44
7E/87F3: 29 01        AND #$01
7E/87F5: D0 06        BNE $87FD
7E/87F7: 20 8F 9A     JSR $9A8F
7E/87FA: 20 C9 9A     JSR $9AC9
7E/87FD: 20 A8 9A     JSR $9AA8
7E/8800: 20 1E 9A     JSR $9A1E
7E/8803: 20 81 9A     JSR $9A81
7E/8806: 20 39 9A     JSR $9A39
7E/8809: 20 57 9A     JSR $9A57
7E/880C: 20 F2 9A     JSR $9AF2
7E/880F: C6 44        DEC $44
7E/8811: D0 DB        BNE $87EE
7E/8813: A9 60        LDA #$60
7E/8815: 85 44        STA $44
7E/8817: 20 5D 94     JSR $945D
7E/881A: 20 8F 9A     JSR $9A8F
7E/881D: A5 44        LDA $44
7E/881F: 29 03        AND #$03
7E/8821: D0 03        BNE $8826
7E/8823: 20 B1 9A     JSR $9AB1
7E/8826: 20 A8 9A     JSR $9AA8
7E/8829: 20 1E 9A     JSR $9A1E
7E/882C: 20 81 9A     JSR $9A81
7E/882F: 20 F2 9A     JSR $9AF2
7E/8832: C6 44        DEC $44
7E/8834: D0 E1        BNE $8817
7E/8836: A9 60        LDA #$60
7E/8838: 85 44        STA $44
7E/883A: 20 5D 94     JSR $945D
7E/883D: 20 8F 9A     JSR $9A8F
7E/8840: 20 A8 9A     JSR $9AA8
7E/8843: 20 1E 9A     JSR $9A1E
7E/8846: 20 81 9A     JSR $9A81
7E/8849: 20 1E 9A     JSR $9A1E
7E/884C: 20 81 9A     JSR $9A81
7E/884F: 20 F2 9A     JSR $9AF2
7E/8852: C6 44        DEC $44
7E/8854: D0 E4        BNE $883A
7E/8856: A9 01        LDA #$01
7E/8858: 14 70        TRB $70
7E/885A: A9 02        LDA #$02
7E/885C: 04 70        TSB $70
7E/885E: 64 73        STZ $73
7E/8860: A9 01        LDA #$01
7E/8862: 85 72        STA $72
7E/8864: 20 5D 94     JSR $945D
7E/8867: 20 8F 9A     JSR $9A8F
7E/886A: 20 B1 9A     JSR $9AB1
7E/886D: 20 A8 9A     JSR $9AA8
7E/8870: 20 1E 9A     JSR $9A1E
7E/8873: 20 81 9A     JSR $9A81
7E/8876: 20 1E 9A     JSR $9A1E
7E/8879: 20 81 9A     JSR $9A81
7E/887C: 20 F2 9A     JSR $9AF2
7E/887F: E6 44        INC $44
7E/8881: A5 71        LDA $71
7E/8883: D0 DF        BNE $8864
7E/8885: 82 B2 F7     BRL $803A

; [ cutscene $0A: flash red (short) ]

7E/8888: 20 60 86     JSR $8660
7E/888B: 20 7A AB     JSR $AB7A
7E/888E: A9 02        LDA #$02
7E/8890: 8D 30 21     STA $2130
7E/8893: A9 70        LDA #$70
7E/8895: 8D 31 21     STA $2131
7E/8898: 85 8E        STA $8E
7E/889A: A9 01        LDA #$01
7E/889C: 8D 2D 21     STA $212D
7E/889F: 85 3A        STA $3A
7E/88A1: A9 10        LDA #$10
7E/88A3: 8D 2C 21     STA $212C
7E/88A6: 85 3B        STA $3B
7E/88A8: 20 EB 9D     JSR $9DEB
7E/88AB: A2 00 FF     LDX #$FF00
7E/88AE: 86 58        STX $58
7E/88B0: A2 00 54     LDX #$5400
7E/88B3: 86 5C        STX $5C
7E/88B5: A2 00 54     LDX #$5400
7E/88B8: 86 5E        STX $5E
7E/88BA: A2 5A 00     LDX #$005A
7E/88BD: 86 52        STX $52
7E/88BF: A2 70 00     LDX #$0070
7E/88C2: 86 30        STX $30
7E/88C4: A2 60 02     LDX #$0260
7E/88C7: 86 32        STX $32
7E/88C9: A2 F0 00     LDX #$00F0
7E/88CC: 86 34        STX $34
7E/88CE: A2 E0 02     LDX #$02E0
7E/88D1: 86 36        STX $36
7E/88D3: A9 05        LDA #$05
7E/88D5: 85 72        STA $72
7E/88D7: A9 81        LDA #$81
7E/88D9: 8D 00 42     STA $4200
7E/88DC: 58           CLI 
7E/88DD: A9 60        LDA #$60
7E/88DF: 85 44        STA $44
7E/88E1: 20 5D 94     JSR $945D
7E/88E4: A5 44        LDA $44
7E/88E6: 29 01        AND #$01
7E/88E8: D0 03        BNE $88ED
7E/88EA: 20 8F 9A     JSR $9A8F
7E/88ED: 20 2C 9F     JSR $9F2C
7E/88F0: C6 44        DEC $44
7E/88F2: D0 ED        BNE $88E1
7E/88F4: A9 C0        LDA #$C0
7E/88F6: 85 44        STA $44
7E/88F8: 20 5D 94     JSR $945D
7E/88FB: A5 44        LDA $44
7E/88FD: 29 03        AND #$03
7E/88FF: D0 0C        BNE $890D
7E/8901: 20 8F 9A     JSR $9A8F
7E/8904: 20 BD 9A     JSR $9ABD
7E/8907: 20 A8 9A     JSR $9AA8
7E/890A: 20 E4 9A     JSR $9AE4
7E/890D: 20 2C 9F     JSR $9F2C
7E/8910: C6 44        DEC $44
7E/8912: D0 E4        BNE $88F8
7E/8914: A9 90        LDA #$90
7E/8916: 85 44        STA $44
7E/8918: 20 5D 94     JSR $945D
7E/891B: A5 44        LDA $44
7E/891D: 29 03        AND #$03
7E/891F: D0 09        BNE $892A
7E/8921: 20 B1 9A     JSR $9AB1
7E/8924: 20 A8 9A     JSR $9AA8
7E/8927: 20 E4 9A     JSR $9AE4
7E/892A: 20 8F 9A     JSR $9A8F
7E/892D: 20 2C 9F     JSR $9F2C
7E/8930: C6 44        DEC $44
7E/8932: D0 E4        BNE $8918
7E/8934: A9 01        LDA #$01
7E/8936: 14 70        TRB $70
7E/8938: A9 02        LDA #$02
7E/893A: 04 70        TSB $70
7E/893C: 64 73        STZ $73
7E/893E: A9 01        LDA #$01
7E/8940: 85 72        STA $72
7E/8942: 20 5D 94     JSR $945D
7E/8945: A5 44        LDA $44
7E/8947: 29 03        AND #$03
7E/8949: D0 06        BNE $8951
7E/894B: 20 B1 9A     JSR $9AB1
7E/894E: 20 A8 9A     JSR $9AA8
7E/8951: 20 E4 9A     JSR $9AE4
7E/8954: 20 8F 9A     JSR $9A8F
7E/8957: 20 2C 9F     JSR $9F2C
7E/895A: E6 44        INC $44
7E/895C: A5 71        LDA $71
7E/895E: D0 E2        BNE $8942
7E/8960: 82 D7 F6     BRL $803A

; [ cutscene $0B: flash red (long) ]

7E/8963: 20 60 86     JSR $8660
7E/8966: 20 7A AB     JSR $AB7A
7E/8969: A9 02        LDA #$02
7E/896B: 8D 30 21     STA $2130
7E/896E: A9 30        LDA #$30
7E/8970: 8D 31 21     STA $2131
7E/8973: 85 8E        STA $8E
7E/8975: A9 01        LDA #$01
7E/8977: 8D 2D 21     STA $212D
7E/897A: 85 3A        STA $3A
7E/897C: A9 10        LDA #$10
7E/897E: 8D 2C 21     STA $212C
7E/8981: 85 3B        STA $3B
7E/8983: A9 01        LDA #$01
7E/8985: 04 4F        TSB $4F
7E/8987: 20 EB 9D     JSR $9DEB
7E/898A: A2 00 80     LDX #$8000
7E/898D: 86 58        STX $58
7E/898F: A2 00 58     LDX #$5800
7E/8992: 86 5C        STX $5C
7E/8994: A2 00 58     LDX #$5800
7E/8997: 86 5E        STX $5E
7E/8999: A6 C7        LDX $C7
7E/899B: 86 52        STX $52
7E/899D: A2 60 00     LDX #$0060
7E/89A0: 86 30        STX $30
7E/89A2: A2 20 02     LDX #$0220
7E/89A5: 86 32        STX $32
7E/89A7: A2 E0 00     LDX #$00E0
7E/89AA: 86 34        STX $34
7E/89AC: A2 A0 02     LDX #$02A0
7E/89AF: 86 36        STX $36
7E/89B1: A9 05        LDA #$05
7E/89B3: 85 72        STA $72
7E/89B5: 20 2C 9F     JSR $9F2C
7E/89B8: A9 81        LDA #$81
7E/89BA: 8D 00 42     STA $4200
7E/89BD: 58           CLI 
7E/89BE: A9 02        LDA #$02
7E/89C0: 85 48        STA $48
7E/89C2: 64 44        STZ $44
7E/89C4: 20 5D 94     JSR $945D
7E/89C7: A5 44        LDA $44
7E/89C9: 89 01        BIT #$01
7E/89CB: D0 0D        BNE $89DA
7E/89CD: 29 07        AND #$07
7E/89CF: D0 03        BNE $89D4
7E/89D1: 20 8F 9A     JSR $9A8F
7E/89D4: 20 29 9A     JSR $9A29
7E/89D7: 20 73 9A     JSR $9A73
7E/89DA: 20 2C 9F     JSR $9F2C
7E/89DD: C6 44        DEC $44
7E/89DF: D0 E3        BNE $89C4
7E/89E1: C6 48        DEC $48
7E/89E3: D0 DF        BNE $89C4
7E/89E5: 20 5D 94     JSR $945D
7E/89E8: A5 44        LDA $44
7E/89EA: 29 03        AND #$03
7E/89EC: D0 03        BNE $89F1
7E/89EE: 20 A8 9A     JSR $9AA8
7E/89F1: 20 49 9A     JSR $9A49
7E/89F4: 20 65 9A     JSR $9A65
7E/89F7: 20 2C 9F     JSR $9F2C
7E/89FA: C6 44        DEC $44
7E/89FC: D0 E7        BNE $89E5
7E/89FE: A2 81 80     LDX #$8081
7E/8A01: 8E 00 1D     STX $1D00
7E/8A04: 22 04 00 C4  JSL $C40004
7E/8A08: A9 40        LDA #$40
7E/8A0A: 85 44        STA $44
7E/8A0C: 20 5D 94     JSR $945D
7E/8A0F: A5 44        LDA $44
7E/8A11: 29 03        AND #$03
7E/8A13: D0 03        BNE $8A18
7E/8A15: 20 8F 9A     JSR $9A8F
7E/8A18: 20 49 9A     JSR $9A49
7E/8A1B: 20 65 9A     JSR $9A65
7E/8A1E: 20 2C 9F     JSR $9F2C
7E/8A21: C6 44        DEC $44
7E/8A23: D0 E7        BNE $8A0C
7E/8A25: A9 01        LDA #$01
7E/8A27: 14 70        TRB $70
7E/8A29: A9 02        LDA #$02
7E/8A2B: 04 70        TSB $70
7E/8A2D: 64 73        STZ $73
7E/8A2F: A9 01        LDA #$01
7E/8A31: 85 72        STA $72
7E/8A33: 20 5D 94     JSR $945D
7E/8A36: A5 44        LDA $44
7E/8A38: 29 01        AND #$01
7E/8A3A: D0 03        BNE $8A3F
7E/8A3C: 20 8F 9A     JSR $9A8F
7E/8A3F: 20 49 9A     JSR $9A49
7E/8A42: 20 65 9A     JSR $9A65
7E/8A45: E6 44        INC $44
7E/8A47: A5 71        LDA $71
7E/8A49: D0 E8        BNE $8A33
7E/8A4B: 82 EC F5     BRL $803A
7E/8A4E: 20 A5 94     JSR $94A5
7E/8A51: 20 65 94     JSR $9465
7E/8A54: 20 B8 96     JSR $96B8
7E/8A57: 20 F3 AF     JSR $AFF3
7E/8A5A: 20 9E B2     JSR $B29E
7E/8A5D: 20 2A AC     JSR $AC2A
7E/8A60: 20 F4 C1     JSR $C1F4
7E/8A63: A9 00        LDA #$00
7E/8A65: 8D 30 21     STA $2130
7E/8A68: A9 01        LDA #$01
7E/8A6A: 04 70        TSB $70
7E/8A6C: 64 71        STZ $71
7E/8A6E: 64 73        STZ $73
7E/8A70: A9 02        LDA #$02
7E/8A72: 85 72        STA $72
7E/8A74: A9 01        LDA #$01
7E/8A76: 04 4F        TSB $4F
7E/8A78: A2 00 FF     LDX #$FF00
7E/8A7B: 86 58        STX $58
7E/8A7D: A2 00 80     LDX #$8000
7E/8A80: 86 5C        STX $5C
7E/8A82: A2 00 80     LDX #$8000
7E/8A85: 86 5E        STX $5E
7E/8A87: A2 DA 00     LDX #$00DA
7E/8A8A: 86 30        STX $30
7E/8A8C: A2 98 00     LDX #$0098
7E/8A8F: 86 32        STX $32
7E/8A91: A2 5A 01     LDX #$015A
7E/8A94: 86 34        STX $34
7E/8A96: A2 18 01     LDX #$0118
7E/8A99: 86 36        STX $36
7E/8A9B: A9 81        LDA #$81
7E/8A9D: 8D 00 42     STA $4200
7E/8AA0: 58           CLI 
7E/8AA1: 60           RTS 

; [ cutscene $07: lightning bolt ??? ]

7E/8AA2: 20 4E 8A     JSR $8A4E
7E/8AA5: A9 C0        LDA #$C0
7E/8AA7: 85 44        STA $44
7E/8AA9: 20 5D 94     JSR $945D
7E/8AAC: A5 44        LDA $44
7E/8AAE: 29 01        AND #$01
7E/8AB0: D0 03        BNE $8AB5
7E/8AB2: 20 8F 9A     JSR $9A8F
7E/8AB5: 20 E4 9A     JSR $9AE4
7E/8AB8: 20 F2 9A     JSR $9AF2
7E/8ABB: C6 44        DEC $44
7E/8ABD: D0 EA        BNE $8AA9
7E/8ABF: A9 C0        LDA #$C0
7E/8AC1: 85 44        STA $44
7E/8AC3: 20 5D 94     JSR $945D
7E/8AC6: A5 44        LDA $44
7E/8AC8: 29 01        AND #$01
7E/8ACA: D0 09        BNE $8AD5
7E/8ACC: 20 8F 9A     JSR $9A8F
7E/8ACF: 20 A8 9A     JSR $9AA8
7E/8AD2: 20 B1 9A     JSR $9AB1
7E/8AD5: 20 E4 9A     JSR $9AE4
7E/8AD8: 20 F2 9A     JSR $9AF2
7E/8ADB: 20 08 AF     JSR $AF08
7E/8ADE: C6 44        DEC $44
7E/8AE0: D0 E1        BNE $8AC3
7E/8AE2: A9 C0        LDA #$C0
7E/8AE4: 85 44        STA $44
7E/8AE6: 20 5D 94     JSR $945D
7E/8AE9: A5 44        LDA $44
7E/8AEB: 29 03        AND #$03
7E/8AED: D0 03        BNE $8AF2
7E/8AEF: 20 B1 9A     JSR $9AB1
7E/8AF2: 20 A8 9A     JSR $9AA8
7E/8AF5: 20 C9 9A     JSR $9AC9
7E/8AF8: 20 F2 9A     JSR $9AF2
7E/8AFB: 20 08 AF     JSR $AF08
7E/8AFE: C6 44        DEC $44
7E/8B00: D0 E4        BNE $8AE6
7E/8B02: 20 3C B4     JSR $B43C
7E/8B05: A9 C0        LDA #$C0
7E/8B07: 85 44        STA $44
7E/8B09: 20 5D 94     JSR $945D
7E/8B0C: 20 E4 9A     JSR $9AE4
7E/8B0F: A5 44        LDA $44
7E/8B11: 29 01        AND #$01
7E/8B13: D0 03        BNE $8B18
7E/8B15: 20 98 9A     JSR $9A98
7E/8B18: A5 44        LDA $44
7E/8B1A: 29 07        AND #$07
7E/8B1C: D0 03        BNE $8B21
7E/8B1E: 20 B1 9A     JSR $9AB1
7E/8B21: 20 A8 9A     JSR $9AA8
7E/8B24: 20 F2 9A     JSR $9AF2
7E/8B27: 20 08 AF     JSR $AF08
7E/8B2A: 20 5D BA     JSR $BA5D
7E/8B2D: C6 44        DEC $44
7E/8B2F: D0 D8        BNE $8B09
7E/8B31: A9 80        LDA #$80
7E/8B33: 85 44        STA $44
7E/8B35: 20 5D 94     JSR $945D
7E/8B38: 20 E4 9A     JSR $9AE4
7E/8B3B: 20 E4 9A     JSR $9AE4
7E/8B3E: 20 A8 9A     JSR $9AA8
7E/8B41: 20 BD 9A     JSR $9ABD
7E/8B44: 20 F2 9A     JSR $9AF2
7E/8B47: 20 08 AF     JSR $AF08
7E/8B4A: 20 86 BA     JSR $BA86
7E/8B4D: C6 44        DEC $44
7E/8B4F: D0 E4        BNE $8B35
7E/8B51: A9 01        LDA #$01
7E/8B53: 14 70        TRB $70
7E/8B55: A9 02        LDA #$02
7E/8B57: 04 70        TSB $70
7E/8B59: 64 73        STZ $73
7E/8B5B: A9 01        LDA #$01
7E/8B5D: 85 72        STA $72
7E/8B5F: 20 5D 94     JSR $945D
7E/8B62: 20 BD 9A     JSR $9ABD
7E/8B65: 20 8F 9A     JSR $9A8F
7E/8B68: 20 E4 9A     JSR $9AE4
7E/8B6B: 20 E4 9A     JSR $9AE4
7E/8B6E: 20 F2 9A     JSR $9AF2
7E/8B71: 20 08 AF     JSR $AF08
7E/8B74: 20 86 BA     JSR $BA86
7E/8B77: E6 44        INC $44
7E/8B79: A5 71        LDA $71
7E/8B7B: D0 E2        BNE $8B5F
7E/8B7D: 82 BA F4     BRL $803A

; [ cutscene $09: purple sparklies ]

7E/8B80: 20 4E 8A     JSR $8A4E
7E/8B83: 20 5D B4     JSR $B45D
7E/8B86: A2 A0 00     LDX #$00A0
7E/8B89: 86 52        STX $52
7E/8B8B: A9 C0        LDA #$C0
7E/8B8D: 85 44        STA $44
7E/8B8F: 20 5D 94     JSR $945D
7E/8B92: A5 44        LDA $44
7E/8B94: 29 01        AND #$01
7E/8B96: D0 03        BNE $8B9B
7E/8B98: 20 8F 9A     JSR $9A8F
7E/8B9B: A5 44        LDA $44
7E/8B9D: 29 01        AND #$01
7E/8B9F: D0 03        BNE $8BA4
7E/8BA1: 20 E4 9A     JSR $9AE4
7E/8BA4: 20 F2 9A     JSR $9AF2
7E/8BA7: C6 44        DEC $44
7E/8BA9: D0 E4        BNE $8B8F
7E/8BAB: 20 1B B4     JSR $B41B
7E/8BAE: A9 FF        LDA #$FF
7E/8BB0: 85 44        STA $44
7E/8BB2: 20 5D 94     JSR $945D
7E/8BB5: A5 44        LDA $44
7E/8BB7: 29 01        AND #$01
7E/8BB9: D0 09        BNE $8BC4
7E/8BBB: 20 8F 9A     JSR $9A8F
7E/8BBE: 20 A8 9A     JSR $9AA8
7E/8BC1: 20 B1 9A     JSR $9AB1
7E/8BC4: A5 44        LDA $44
7E/8BC6: 29 01        AND #$01
7E/8BC8: D0 03        BNE $8BCD
7E/8BCA: 20 E4 9A     JSR $9AE4
7E/8BCD: 20 28 B8     JSR $B828
7E/8BD0: 20 F2 9A     JSR $9AF2
7E/8BD3: 20 AE AF     JSR $AFAE
7E/8BD6: C6 44        DEC $44
7E/8BD8: D0 D8        BNE $8BB2
7E/8BDA: A9 01        LDA #$01
7E/8BDC: 14 70        TRB $70
7E/8BDE: A9 02        LDA #$02
7E/8BE0: 04 70        TSB $70
7E/8BE2: 64 73        STZ $73
7E/8BE4: A9 01        LDA #$01
7E/8BE6: 85 72        STA $72
7E/8BE8: 20 5D 94     JSR $945D
7E/8BEB: 20 8F 9A     JSR $9A8F
7E/8BEE: A5 44        LDA $44
7E/8BF0: 29 01        AND #$01
7E/8BF2: D0 03        BNE $8BF7
7E/8BF4: 20 E4 9A     JSR $9AE4
7E/8BF7: 20 28 B8     JSR $B828
7E/8BFA: 20 F2 9A     JSR $9AF2
7E/8BFD: 20 AE AF     JSR $AFAE
7E/8C00: E6 44        INC $44
7E/8C02: A5 71        LDA $71
7E/8C04: D0 E2        BNE $8BE8
7E/8C06: 82 31 F4     BRL $803A
7E/8C09: 20 4E 8A     JSR $8A4E
7E/8C0C: A2 00 10     LDX #$1000
7E/8C0F: 86 58        STX $58
7E/8C11: A2 00 80     LDX #$8000
7E/8C14: 86 5C        STX $5C
7E/8C16: A2 00 FF     LDX #$FF00
7E/8C19: 86 5E        STX $5E
7E/8C1B: A9 C0        LDA #$C0
7E/8C1D: 85 44        STA $44
7E/8C1F: 20 5D 94     JSR $945D
7E/8C22: A5 44        LDA $44
7E/8C24: 29 01        AND #$01
7E/8C26: D0 03        BNE $8C2B
7E/8C28: 20 98 9A     JSR $9A98
7E/8C2B: 20 E4 9A     JSR $9AE4
7E/8C2E: 20 F2 9A     JSR $9AF2
7E/8C31: C6 44        DEC $44
7E/8C33: D0 EA        BNE $8C1F
7E/8C35: A9 C0        LDA #$C0
7E/8C37: 85 44        STA $44
7E/8C39: 20 5D 94     JSR $945D
7E/8C3C: A5 44        LDA $44
7E/8C3E: 29 01        AND #$01
7E/8C40: D0 09        BNE $8C4B
7E/8C42: 20 98 9A     JSR $9A98
7E/8C45: 20 A1 9A     JSR $9AA1
7E/8C48: 20 B1 9A     JSR $9AB1
7E/8C4B: 20 E4 9A     JSR $9AE4
7E/8C4E: 20 F2 9A     JSR $9AF2
7E/8C51: C6 44        DEC $44
7E/8C53: D0 E4        BNE $8C39
7E/8C55: A9 01        LDA #$01
7E/8C57: 14 70        TRB $70
7E/8C59: A9 02        LDA #$02
7E/8C5B: 04 70        TSB $70
7E/8C5D: 64 73        STZ $73
7E/8C5F: A9 01        LDA #$01
7E/8C61: 85 72        STA $72
7E/8C63: 20 5D 94     JSR $945D
7E/8C66: 20 98 9A     JSR $9A98
7E/8C69: 20 E4 9A     JSR $9AE4
7E/8C6C: 20 F2 9A     JSR $9AF2
7E/8C6F: E6 44        INC $44
7E/8C71: A5 71        LDA $71
7E/8C73: D0 EE        BNE $8C63
7E/8C75: 82 C2 F3     BRL $803A

; [ cutscene $00: ending credits ]

7E/8C78: 20 A5 94     JSR $94A5
7E/8C7B: 20 65 94     JSR $9465
7E/8C7E: 20 B8 96     JSR $96B8
7E/8C81: 20 F3 AF     JSR $AFF3
7E/8C84: 20 3B AB     JSR $AB3B
7E/8C87: 20 80 97     JSR $9780
7E/8C8A: A9 02        LDA #$02
7E/8C8C: 8D 30 21     STA $2130
7E/8C8F: A9 30        LDA #$30
7E/8C91: 8D 31 21     STA $2131
7E/8C94: 85 8E        STA $8E
7E/8C96: A9 01        LDA #$01
7E/8C98: 8D 2D 21     STA $212D
7E/8C9B: 85 3A        STA $3A
7E/8C9D: A9 10        LDA #$10
7E/8C9F: 8D 2C 21     STA $212C
7E/8CA2: 85 3B        STA $3B
7E/8CA4: 20 C1 AF     JSR $AFC1
7E/8CA7: 20 EB 9D     JSR $9DEB
7E/8CAA: 20 D0 98     JSR $98D0
7E/8CAD: 20 0A B3     JSR $B30A
7E/8CB0: 20 9F B4     JSR $B49F
7E/8CB3: 20 F4 C1     JSR $C1F4
7E/8CB6: 20 79 BB     JSR $BB79
7E/8CB9: A9 01        LDA #$01
7E/8CBB: 04 4F        TSB $4F
7E/8CBD: A9 81        LDA #$81
7E/8CBF: 8D 00 42     STA $4200
7E/8CC2: 58           CLI 
7E/8CC3: 20 B0 BB     JSR $BBB0
7E/8CC6: 20 5D 94     JSR $945D
7E/8CC9: 20 CA BB     JSR $BBCA
7E/8CCC: 20 5D 94     JSR $945D
7E/8CCF: 20 E4 BB     JSR $BBE4
7E/8CD2: 20 5D 94     JSR $945D
7E/8CD5: 20 34 BE     JSR $BE34
7E/8CD8: 20 5D 94     JSR $945D
7E/8CDB: A9 02        LDA #$02
7E/8CDD: 14 70        TRB $70
7E/8CDF: A9 01        LDA #$01
7E/8CE1: 04 70        TSB $70
7E/8CE3: 64 71        STZ $71
7E/8CE5: 64 73        STZ $73
7E/8CE7: A9 02        LDA #$02
7E/8CE9: 85 72        STA $72
7E/8CEB: A2 00 80     LDX #$8000
7E/8CEE: 86 58        STX $58
7E/8CF0: A2 00 80     LDX #$8000
7E/8CF3: 86 5C        STX $5C
7E/8CF5: A2 00 80     LDX #$8000
7E/8CF8: 86 5E        STX $5E
7E/8CFA: A6 C7        LDX $C7
7E/8CFC: 86 52        STX $52
7E/8CFE: A2 C0 00     LDX #$00C0
7E/8D01: 86 30        STX $30
7E/8D03: A2 C8 00     LDX #$00C8
7E/8D06: 86 32        STX $32
7E/8D08: A2 40 01     LDX #$0140
7E/8D0B: 86 34        STX $34
7E/8D0D: A2 48 01     LDX #$0148
7E/8D10: 86 36        STX $36
7E/8D12: 64 44        STZ $44
7E/8D14: E6 29        INC $29
7E/8D16: A9 05        LDA #$05
7E/8D18: 85 48        STA $48
7E/8D1A: 20 5D 94     JSR $945D
7E/8D1D: A5 44        LDA $44
7E/8D1F: 29 03        AND #$03
7E/8D21: D0 06        BNE $8D29
7E/8D23: 20 1E 9A     JSR $9A1E
7E/8D26: 20 81 9A     JSR $9A81
7E/8D29: 20 7E BE     JSR $BE7E
7E/8D2C: A5 29        LDA $29
7E/8D2E: F0 0C        BEQ $8D3C
7E/8D30: C6 44        DEC $44
7E/8D32: D0 E6        BNE $8D1A
7E/8D34: C6 48        DEC $48
7E/8D36: D0 E2        BNE $8D1A
7E/8D38: 64 29        STZ $29
7E/8D3A: 80 DE        BRA $8D1A
7E/8D3C: C6 44        DEC $44
7E/8D3E: A5 2A        LDA $2A
7E/8D40: D0 D8        BNE $8D1A
7E/8D42: A9 40        LDA #$40
7E/8D44: 85 44        STA $44
7E/8D46: 20 5D 94     JSR $945D
7E/8D49: A5 44        LDA $44
7E/8D4B: 29 01        AND #$01
7E/8D4D: D0 06        BNE $8D55
7E/8D4F: 20 A1 9A     JSR $9AA1
7E/8D52: 20 E4 9A     JSR $9AE4
7E/8D55: 20 B1 9A     JSR $9AB1
7E/8D58: 20 2C 9F     JSR $9F2C
7E/8D5B: C6 44        DEC $44
7E/8D5D: D0 E7        BNE $8D46
7E/8D5F: A9 C0        LDA #$C0
7E/8D61: 85 44        STA $44
7E/8D63: 20 5D 94     JSR $945D
7E/8D66: A5 44        LDA $44
7E/8D68: 29 01        AND #$01
7E/8D6A: D0 09        BNE $8D75
7E/8D6C: 20 A8 9A     JSR $9AA8
7E/8D6F: 20 1E 9A     JSR $9A1E
7E/8D72: 20 81 9A     JSR $9A81
7E/8D75: 20 39 9A     JSR $9A39
7E/8D78: 20 57 9A     JSR $9A57
7E/8D7B: 20 2C 9F     JSR $9F2C
7E/8D7E: C6 44        DEC $44
7E/8D80: D0 E1        BNE $8D63
7E/8D82: A2 30 00     LDX #$0030
7E/8D85: 86 60        STX $60
7E/8D87: A2 38 00     LDX #$0038
7E/8D8A: 86 62        STX $62
7E/8D8C: A2 40 00     LDX #$0040
7E/8D8F: 86 64        STX $64
7E/8D91: A2 48 00     LDX #$0048
7E/8D94: 86 66        STX $66
7E/8D96: A2 50 00     LDX #$0050
7E/8D99: 86 68        STX $68
7E/8D9B: A2 58 00     LDX #$0058
7E/8D9E: 86 6A        STX $6A
7E/8DA0: A2 60 00     LDX #$0060
7E/8DA3: 86 6C        STX $6C
7E/8DA5: A2 68 00     LDX #$0068
7E/8DA8: 86 6E        STX $6E
7E/8DAA: 64 46        STZ $46
7E/8DAC: A9 05        LDA #$05
7E/8DAE: 85 48        STA $48
7E/8DB0: E6 29        INC $29
7E/8DB2: 20 5D 94     JSR $945D
7E/8DB5: 20 39 9A     JSR $9A39
7E/8DB8: 20 57 9A     JSR $9A57
7E/8DBB: A5 44        LDA $44
7E/8DBD: 29 01        AND #$01
7E/8DBF: D0 06        BNE $8DC7
7E/8DC1: 20 1E 9A     JSR $9A1E
7E/8DC4: 20 81 9A     JSR $9A81
7E/8DC7: 20 F2 B8     JSR $B8F2
7E/8DCA: 20 7E BE     JSR $BE7E
7E/8DCD: 20 BF B7     JSR $B7BF
7E/8DD0: A5 29        LDA $29
7E/8DD2: F0 0E        BEQ $8DE2
7E/8DD4: C6 46        DEC $46
7E/8DD6: C6 44        DEC $44
7E/8DD8: D0 D8        BNE $8DB2
7E/8DDA: C6 48        DEC $48
7E/8DDC: D0 D4        BNE $8DB2
7E/8DDE: 64 29        STZ $29
7E/8DE0: 80 D0        BRA $8DB2
7E/8DE2: C6 44        DEC $44
7E/8DE4: A5 2A        LDA $2A
7E/8DE6: D0 CA        BNE $8DB2
7E/8DE8: A9 80        LDA #$80
7E/8DEA: 85 44        STA $44
7E/8DEC: 20 5D 94     JSR $945D
7E/8DEF: A5 44        LDA $44
7E/8DF1: 29 01        AND #$01
7E/8DF3: D0 03        BNE $8DF8
7E/8DF5: 20 C9 9A     JSR $9AC9
7E/8DF8: 20 39 9A     JSR $9A39
7E/8DFB: 20 57 9A     JSR $9A57
7E/8DFE: 20 2C 9F     JSR $9F2C
7E/8E01: C6 44        DEC $44
7E/8E03: D0 E7        BNE $8DEC
7E/8E05: 64 44        STZ $44
7E/8E07: A9 03        LDA #$03
7E/8E09: 85 48        STA $48
7E/8E0B: 20 5D 94     JSR $945D
7E/8E0E: 20 7E BE     JSR $BE7E
7E/8E11: A5 44        LDA $44
7E/8E13: 29 01        AND #$01
7E/8E15: D0 06        BNE $8E1D
7E/8E17: 20 1E 9A     JSR $9A1E
7E/8E1A: 20 81 9A     JSR $9A81
7E/8E1D: 20 39 9A     JSR $9A39
7E/8E20: 20 57 9A     JSR $9A57
7E/8E23: C6 44        DEC $44
7E/8E25: D0 E4        BNE $8E0B
7E/8E27: C6 48        DEC $48
7E/8E29: D0 E0        BNE $8E0B
7E/8E2B: E6 29        INC $29
7E/8E2D: A9 02        LDA #$02
7E/8E2F: 85 48        STA $48
7E/8E31: 20 5D 94     JSR $945D
7E/8E34: 20 7E BE     JSR $BE7E
7E/8E37: 20 8E B8     JSR $B88E
7E/8E3A: 20 BF B7     JSR $B7BF
7E/8E3D: A5 44        LDA $44
7E/8E3F: 29 01        AND #$01
7E/8E41: D0 06        BNE $8E49
7E/8E43: 20 1E 9A     JSR $9A1E
7E/8E46: 20 81 9A     JSR $9A81
7E/8E49: 20 39 9A     JSR $9A39
7E/8E4C: 20 57 9A     JSR $9A57
7E/8E4F: A5 29        LDA $29
7E/8E51: F0 0C        BEQ $8E5F
7E/8E53: C6 44        DEC $44
7E/8E55: D0 DA        BNE $8E31
7E/8E57: C6 48        DEC $48
7E/8E59: D0 D6        BNE $8E31
7E/8E5B: 64 29        STZ $29
7E/8E5D: 80 D2        BRA $8E31
7E/8E5F: C6 44        DEC $44
7E/8E61: A5 2A        LDA $2A
7E/8E63: D0 CC        BNE $8E31
7E/8E65: A9 C0        LDA #$C0
7E/8E67: 85 44        STA $44
7E/8E69: 20 5D 94     JSR $945D
7E/8E6C: A5 44        LDA $44
7E/8E6E: 29 01        AND #$01
7E/8E70: D0 0F        BNE $8E81
7E/8E72: 20 39 9A     JSR $9A39
7E/8E75: 20 57 9A     JSR $9A57
7E/8E78: 20 E4 9A     JSR $9AE4
7E/8E7B: 20 8F 9A     JSR $9A8F
7E/8E7E: 20 A8 9A     JSR $9AA8
7E/8E81: 20 1E 9A     JSR $9A1E
7E/8E84: 20 81 9A     JSR $9A81
7E/8E87: 20 2C 9F     JSR $9F2C
7E/8E8A: C6 44        DEC $44
7E/8E8C: D0 DB        BNE $8E69
7E/8E8E: E6 29        INC $29
7E/8E90: A9 02        LDA #$02
7E/8E92: 85 48        STA $48
7E/8E94: A9 10        LDA #$10
7E/8E96: 85 44        STA $44
7E/8E98: 20 5D 94     JSR $945D
7E/8E9B: 20 7E BE     JSR $BE7E
7E/8E9E: 20 39 9A     JSR $9A39
7E/8EA1: 20 57 9A     JSR $9A57
7E/8EA4: 20 1E 9A     JSR $9A1E
7E/8EA7: 20 81 9A     JSR $9A81
7E/8EAA: A5 29        LDA $29
7E/8EAC: F0 0C        BEQ $8EBA
7E/8EAE: C6 44        DEC $44
7E/8EB0: D0 E6        BNE $8E98
7E/8EB2: C6 48        DEC $48
7E/8EB4: D0 E2        BNE $8E98
7E/8EB6: 64 29        STZ $29
7E/8EB8: 80 DE        BRA $8E98
7E/8EBA: C6 44        DEC $44
7E/8EBC: A5 2A        LDA $2A
7E/8EBE: D0 D8        BNE $8E98
7E/8EC0: A9 01        LDA #$01
7E/8EC2: 14 70        TRB $70
7E/8EC4: A9 02        LDA #$02
7E/8EC6: 04 70        TSB $70
7E/8EC8: 64 73        STZ $73
7E/8ECA: A9 01        LDA #$01
7E/8ECC: 85 72        STA $72
7E/8ECE: 20 5D 94     JSR $945D
7E/8ED1: 20 1E 9A     JSR $9A1E
7E/8ED4: 20 81 9A     JSR $9A81
7E/8ED7: 20 39 9A     JSR $9A39
7E/8EDA: 20 57 9A     JSR $9A57
7E/8EDD: C6 44        DEC $44
7E/8EDF: A5 71        LDA $71
7E/8EE1: D0 EB        BNE $8ECE
7E/8EE3: 20 3A 80     JSR $803A
7E/8EE6: 20 35 B3     JSR $B335
7E/8EE9: 20 E1 B4     JSR $B4E1
7E/8EEC: 20 43 99     JSR $9943
7E/8EEF: 20 60 B3     JSR $B360
7E/8EF2: 20 75 B3     JSR $B375
7E/8EF5: 20 50 B5     JSR $B550
7E/8EF8: 20 93 B5     JSR $B593
7E/8EFB: A9 01        LDA #$01
7E/8EFD: 04 4F        TSB $4F
7E/8EFF: A9 81        LDA #$81
7E/8F01: 8D 00 42     STA $4200
7E/8F04: 58           CLI 
7E/8F05: A9 02        LDA #$02
7E/8F07: 14 70        TRB $70
7E/8F09: A9 01        LDA #$01
7E/8F0B: 04 70        TSB $70
7E/8F0D: 64 71        STZ $71
7E/8F0F: 64 73        STZ $73
7E/8F11: A9 02        LDA #$02
7E/8F13: 85 72        STA $72
7E/8F15: A2 00 40     LDX #$4000
7E/8F18: 86 58        STX $58
7E/8F1A: A2 00 20     LDX #$2000
7E/8F1D: 86 5C        STX $5C
7E/8F1F: A2 00 60     LDX #$6000
7E/8F22: 86 5E        STX $5E
7E/8F24: A2 DA 00     LDX #$00DA
7E/8F27: 86 30        STX $30
7E/8F29: A2 98 00     LDX #$0098
7E/8F2C: 86 32        STX $32
7E/8F2E: A2 5A 01     LDX #$015A
7E/8F31: 86 34        STX $34
7E/8F33: A2 18 01     LDX #$0118
7E/8F36: 86 36        STX $36
7E/8F38: A6 C7        LDX $C7
7E/8F3A: 86 52        STX $52
7E/8F3C: 20 2C 9F     JSR $9F2C
7E/8F3F: E6 29        INC $29
7E/8F41: 64 44        STZ $44
7E/8F43: A9 02        LDA #$02
7E/8F45: 85 48        STA $48
7E/8F47: 20 5D 94     JSR $945D
7E/8F4A: 20 1E 9A     JSR $9A1E
7E/8F4D: 20 81 9A     JSR $9A81
7E/8F50: 20 1E 9A     JSR $9A1E
7E/8F53: 20 81 9A     JSR $9A81
7E/8F56: 20 7E BE     JSR $BE7E
7E/8F59: 20 BF B7     JSR $B7BF
7E/8F5C: A5 29        LDA $29
7E/8F5E: F0 0C        BEQ $8F6C
7E/8F60: C6 44        DEC $44
7E/8F62: D0 E3        BNE $8F47
7E/8F64: C6 48        DEC $48
7E/8F66: D0 DF        BNE $8F47
7E/8F68: 64 29        STZ $29
7E/8F6A: 80 DB        BRA $8F47
7E/8F6C: C6 44        DEC $44
7E/8F6E: A5 2A        LDA $2A
7E/8F70: D0 D5        BNE $8F47
7E/8F72: A9 60        LDA #$60
7E/8F74: 85 44        STA $44
7E/8F76: 20 5D 94     JSR $945D
7E/8F79: 20 1E 9A     JSR $9A1E
7E/8F7C: 20 81 9A     JSR $9A81
7E/8F7F: 20 1E 9A     JSR $9A1E
7E/8F82: 20 81 9A     JSR $9A81
7E/8F85: 20 BF B7     JSR $B7BF
7E/8F88: 20 44 BA     JSR $BA44
7E/8F8B: 20 44 BA     JSR $BA44
7E/8F8E: 20 44 BA     JSR $BA44
7E/8F91: A5 44        LDA $44
7E/8F93: 29 01        AND #$01
7E/8F95: D0 03        BNE $8F9A
7E/8F97: 20 93 B6     JSR $B693
7E/8F9A: C6 44        DEC $44
7E/8F9C: D0 D8        BNE $8F76
7E/8F9E: A9 F0        LDA #$F0
7E/8FA0: 85 44        STA $44
7E/8FA2: 20 5D 94     JSR $945D
7E/8FA5: 20 1E 9A     JSR $9A1E
7E/8FA8: 20 81 9A     JSR $9A81
7E/8FAB: 20 1E 9A     JSR $9A1E
7E/8FAE: 20 81 9A     JSR $9A81
7E/8FB1: 20 BF B7     JSR $B7BF
7E/8FB4: 20 44 BA     JSR $BA44
7E/8FB7: A5 44        LDA $44
7E/8FB9: 29 01        AND #$01
7E/8FBB: D0 03        BNE $8FC0
7E/8FBD: 20 DE B6     JSR $B6DE
7E/8FC0: C6 44        DEC $44
7E/8FC2: D0 DE        BNE $8FA2
7E/8FC4: A9 B0        LDA #$B0
7E/8FC6: 85 44        STA $44
7E/8FC8: 20 5D 94     JSR $945D
7E/8FCB: 20 1E 9A     JSR $9A1E
7E/8FCE: 20 81 9A     JSR $9A81
7E/8FD1: 20 1E 9A     JSR $9A1E
7E/8FD4: 20 81 9A     JSR $9A81
7E/8FD7: 20 1E 9A     JSR $9A1E
7E/8FDA: 20 81 9A     JSR $9A81
7E/8FDD: A5 44        LDA $44
7E/8FDF: 29 03        AND #$03
7E/8FE1: D0 03        BNE $8FE6
7E/8FE3: 20 A1 9A     JSR $9AA1
7E/8FE6: 20 BF B7     JSR $B7BF
7E/8FE9: 20 F7 B6     JSR $B6F7
7E/8FEC: 20 2C 9F     JSR $9F2C
7E/8FEF: C6 44        DEC $44
7E/8FF1: D0 D5        BNE $8FC8
7E/8FF3: A9 55        LDA #$55
7E/8FF5: 85 44        STA $44
7E/8FF7: 20 5D 94     JSR $945D
7E/8FFA: 20 1E 9A     JSR $9A1E
7E/8FFD: 20 81 9A     JSR $9A81
7E/9000: 20 1E 9A     JSR $9A1E
7E/9003: 20 81 9A     JSR $9A81
7E/9006: 20 E4 9A     JSR $9AE4
7E/9009: 20 2C 9F     JSR $9F2C
7E/900C: C6 44        DEC $44
7E/900E: D0 E7        BNE $8FF7
7E/9010: A9 01        LDA #$01
7E/9012: 14 4F        TRB $4F
7E/9014: 20 5D 94     JSR $945D
7E/9017: 20 8A B3     JSR $B38A
7E/901A: 20 1E 9A     JSR $9A1E
7E/901D: 20 81 9A     JSR $9A81
7E/9020: 20 1E 9A     JSR $9A1E
7E/9023: 20 81 9A     JSR $9A81
7E/9026: A9 02        LDA #$02
7E/9028: 04 4F        TSB $4F
7E/902A: 20 5D 94     JSR $945D
7E/902D: 20 A6 B3     JSR $B3A6
7E/9030: 20 1E 9A     JSR $9A1E
7E/9033: 20 81 9A     JSR $9A81
7E/9036: 20 1E 9A     JSR $9A1E
7E/9039: 20 81 9A     JSR $9A81
7E/903C: 20 5D 94     JSR $945D
7E/903F: 20 1E 9A     JSR $9A1E
7E/9042: 20 81 9A     JSR $9A81
7E/9045: 20 1E 9A     JSR $9A1E
7E/9048: 20 81 9A     JSR $9A81
7E/904B: 20 23 B5     JSR $B523
7E/904E: A9 02        LDA #$02
7E/9050: 14 4F        TRB $4F
7E/9052: A9 01        LDA #$01
7E/9054: 04 4F        TSB $4F
7E/9056: A9 60        LDA #$60
7E/9058: 85 44        STA $44
7E/905A: 20 5D 94     JSR $945D
7E/905D: 20 1E 9A     JSR $9A1E
7E/9060: 20 81 9A     JSR $9A81
7E/9063: 20 1E 9A     JSR $9A1E
7E/9066: 20 81 9A     JSR $9A81
7E/9069: A5 44        LDA $44
7E/906B: 29 01        AND #$01
7E/906D: D0 03        BNE $9072
7E/906F: 20 A8 9A     JSR $9AA8
7E/9072: 20 2C 9F     JSR $9F2C
7E/9075: C6 44        DEC $44
7E/9077: D0 E1        BNE $905A
7E/9079: E6 29        INC $29
7E/907B: A9 02        LDA #$02
7E/907D: 85 48        STA $48
7E/907F: 20 5D 94     JSR $945D
7E/9082: 20 1E 9A     JSR $9A1E
7E/9085: 20 81 9A     JSR $9A81
7E/9088: 20 1E 9A     JSR $9A1E
7E/908B: 20 81 9A     JSR $9A81
7E/908E: 20 05 B8     JSR $B805
7E/9091: A5 44        LDA $44
7E/9093: 29 03        AND #$03
7E/9095: D0 03        BNE $909A
7E/9097: 20 CC B9     JSR $B9CC
7E/909A: 20 7E BE     JSR $BE7E
7E/909D: A5 29        LDA $29
7E/909F: F0 0C        BEQ $90AD
7E/90A1: C6 44        DEC $44
7E/90A3: D0 DA        BNE $907F
7E/90A5: C6 48        DEC $48
7E/90A7: D0 D6        BNE $907F
7E/90A9: 64 29        STZ $29
7E/90AB: 80 D2        BRA $907F
7E/90AD: C6 44        DEC $44
7E/90AF: A5 2A        LDA $2A
7E/90B1: D0 CC        BNE $907F
7E/90B3: E6 29        INC $29
7E/90B5: A9 40        LDA #$40
7E/90B7: 85 44        STA $44
7E/90B9: A9 01        LDA #$01
7E/90BB: 85 48        STA $48
7E/90BD: 20 5D 94     JSR $945D
7E/90C0: 20 1E 9A     JSR $9A1E
7E/90C3: 20 81 9A     JSR $9A81
7E/90C6: 20 1E 9A     JSR $9A1E
7E/90C9: 20 81 9A     JSR $9A81
7E/90CC: 20 05 B8     JSR $B805
7E/90CF: 20 E5 B9     JSR $B9E5
7E/90D2: 20 E5 B9     JSR $B9E5
7E/90D5: A5 44        LDA $44
7E/90D7: 29 03        AND #$03
7E/90D9: D0 03        BNE $90DE
7E/90DB: 20 CC B9     JSR $B9CC
7E/90DE: 20 7E BE     JSR $BE7E
7E/90E1: A5 29        LDA $29
7E/90E3: F0 0C        BEQ $90F1
7E/90E5: C6 44        DEC $44
7E/90E7: D0 D4        BNE $90BD
7E/90E9: C6 48        DEC $48
7E/90EB: D0 D0        BNE $90BD
7E/90ED: 64 29        STZ $29
7E/90EF: 80 CC        BRA $90BD
7E/90F1: C6 44        DEC $44
7E/90F3: A5 2A        LDA $2A
7E/90F5: D0 C6        BNE $90BD
7E/90F7: E6 29        INC $29
7E/90F9: A9 40        LDA #$40
7E/90FB: 85 44        STA $44
7E/90FD: A9 02        LDA #$02
7E/90FF: 85 48        STA $48
7E/9101: 20 5D 94     JSR $945D
7E/9104: 20 1E 9A     JSR $9A1E
7E/9107: 20 81 9A     JSR $9A81
7E/910A: 20 1E 9A     JSR $9A1E
7E/910D: 20 81 9A     JSR $9A81
7E/9110: 20 05 B8     JSR $B805
7E/9113: 20 E5 B9     JSR $B9E5
7E/9116: A5 44        LDA $44
7E/9118: 29 03        AND #$03
7E/911A: D0 03        BNE $911F
7E/911C: 20 CC B9     JSR $B9CC
7E/911F: 20 7E BE     JSR $BE7E
7E/9122: A5 29        LDA $29
7E/9124: F0 0C        BEQ $9132
7E/9126: C6 44        DEC $44
7E/9128: D0 D7        BNE $9101
7E/912A: C6 48        DEC $48
7E/912C: D0 D3        BNE $9101
7E/912E: 64 29        STZ $29
7E/9130: 80 CF        BRA $9101
7E/9132: C6 44        DEC $44
7E/9134: A5 2A        LDA $2A
7E/9136: D0 C9        BNE $9101
7E/9138: A9 03        LDA #$03
7E/913A: 85 48        STA $48
7E/913C: A9 20        LDA #$20
7E/913E: 85 44        STA $44
7E/9140: E6 29        INC $29
7E/9142: 20 5D 94     JSR $945D
7E/9145: 20 1E 9A     JSR $9A1E
7E/9148: 20 81 9A     JSR $9A81
7E/914B: 20 1E 9A     JSR $9A1E
7E/914E: 20 81 9A     JSR $9A81
7E/9151: 20 05 B8     JSR $B805
7E/9154: A5 44        LDA $44
7E/9156: 29 03        AND #$03
7E/9158: D0 03        BNE $915D
7E/915A: 20 CC B9     JSR $B9CC
7E/915D: 20 7E BE     JSR $BE7E
7E/9160: A5 29        LDA $29
7E/9162: F0 0C        BEQ $9170
7E/9164: C6 44        DEC $44
7E/9166: D0 DA        BNE $9142
7E/9168: C6 48        DEC $48
7E/916A: D0 D6        BNE $9142
7E/916C: 64 29        STZ $29
7E/916E: 80 D2        BRA $9142
7E/9170: C6 44        DEC $44
7E/9172: A5 2A        LDA $2A
7E/9174: D0 CC        BNE $9142
7E/9176: A9 20        LDA #$20
7E/9178: 85 44        STA $44
7E/917A: 20 5D 94     JSR $945D
7E/917D: 20 E4 9A     JSR $9AE4
7E/9180: 20 1E 9A     JSR $9A1E
7E/9183: 20 81 9A     JSR $9A81
7E/9186: 20 1E 9A     JSR $9A1E
7E/9189: 20 81 9A     JSR $9A81
7E/918C: 20 2C 9F     JSR $9F2C
7E/918F: C6 44        DEC $44
7E/9191: D0 E7        BNE $917A
7E/9193: A9 01        LDA #$01
7E/9195: 14 4F        TRB $4F
7E/9197: 20 5D 94     JSR $945D
7E/919A: 20 1E 9A     JSR $9A1E
7E/919D: 20 81 9A     JSR $9A81
7E/91A0: 20 1E 9A     JSR $9A1E
7E/91A3: 20 81 9A     JSR $9A81
7E/91A6: 20 C2 B3     JSR $B3C2
7E/91A9: A9 02        LDA #$02
7E/91AB: 04 4F        TSB $4F
7E/91AD: 20 5D 94     JSR $945D
7E/91B0: 20 1E 9A     JSR $9A1E
7E/91B3: 20 81 9A     JSR $9A81
7E/91B6: 20 1E 9A     JSR $9A1E
7E/91B9: 20 81 9A     JSR $9A81
7E/91BC: 20 DE B3     JSR $B3DE
7E/91BF: 20 5D 94     JSR $945D
7E/91C2: 20 1E 9A     JSR $9A1E
7E/91C5: 20 81 9A     JSR $9A81
7E/91C8: 20 1E 9A     JSR $9A1E
7E/91CB: 20 81 9A     JSR $9A81
7E/91CE: 20 66 B5     JSR $B566
7E/91D1: 20 5D 94     JSR $945D
7E/91D4: 20 1E 9A     JSR $9A1E
7E/91D7: 20 81 9A     JSR $9A81
7E/91DA: 20 1E 9A     JSR $9A1E
7E/91DD: 20 81 9A     JSR $9A81
7E/91E0: A9 02        LDA #$02
7E/91E2: 14 4F        TRB $4F
7E/91E4: A9 01        LDA #$01
7E/91E6: 04 4F        TSB $4F
7E/91E8: E6 29        INC $29
7E/91EA: A9 02        LDA #$02
7E/91EC: 85 48        STA $48
7E/91EE: 20 5D 94     JSR $945D
7E/91F1: 20 1E 9A     JSR $9A1E
7E/91F4: 20 81 9A     JSR $9A81
7E/91F7: 20 1E 9A     JSR $9A1E
7E/91FA: 20 81 9A     JSR $9A81
7E/91FD: 20 7E BE     JSR $BE7E
7E/9200: 20 E2 B7     JSR $B7E2
7E/9203: A5 44        LDA $44
7E/9205: 29 03        AND #$03
7E/9207: D0 03        BNE $920C
7E/9209: 20 FE B9     JSR $B9FE
7E/920C: A5 29        LDA $29
7E/920E: F0 0C        BEQ $921C
7E/9210: C6 44        DEC $44
7E/9212: D0 DA        BNE $91EE
7E/9214: C6 48        DEC $48
7E/9216: D0 D6        BNE $91EE
7E/9218: 64 29        STZ $29
7E/921A: 80 D2        BRA $91EE
7E/921C: C6 44        DEC $44
7E/921E: A5 2A        LDA $2A
7E/9220: D0 CC        BNE $91EE
7E/9222: 64 44        STZ $44
7E/9224: E6 29        INC $29
7E/9226: A9 02        LDA #$02
7E/9228: 85 48        STA $48
7E/922A: 20 5D 94     JSR $945D
7E/922D: 20 1E 9A     JSR $9A1E
7E/9230: 20 81 9A     JSR $9A81
7E/9233: 20 1E 9A     JSR $9A1E
7E/9236: 20 81 9A     JSR $9A81
7E/9239: 20 7E BE     JSR $BE7E
7E/923C: 20 E2 B7     JSR $B7E2
7E/923F: 20 17 BA     JSR $BA17
7E/9242: A5 44        LDA $44
7E/9244: 29 03        AND #$03
7E/9246: D0 03        BNE $924B
7E/9248: 20 FE B9     JSR $B9FE
7E/924B: A5 29        LDA $29
7E/924D: F0 0C        BEQ $925B
7E/924F: C6 44        DEC $44
7E/9251: D0 D7        BNE $922A
7E/9253: C6 48        DEC $48
7E/9255: D0 D3        BNE $922A
7E/9257: 64 29        STZ $29
7E/9259: 80 CF        BRA $922A
7E/925B: C6 44        DEC $44
7E/925D: A5 2A        LDA $2A
7E/925F: D0 C9        BNE $922A
7E/9261: A9 80        LDA #$80
7E/9263: 85 44        STA $44
7E/9265: A9 03        LDA #$03
7E/9267: 85 48        STA $48
7E/9269: E6 29        INC $29
7E/926B: 20 5D 94     JSR $945D
7E/926E: 20 1E 9A     JSR $9A1E
7E/9271: 20 81 9A     JSR $9A81
7E/9274: 20 1E 9A     JSR $9A1E
7E/9277: 20 81 9A     JSR $9A81
7E/927A: 20 7E BE     JSR $BE7E
7E/927D: 20 E2 B7     JSR $B7E2
7E/9280: A5 44        LDA $44
7E/9282: 29 03        AND #$03
7E/9284: D0 03        BNE $9289
7E/9286: 20 FE B9     JSR $B9FE
7E/9289: C6 44        DEC $44
7E/928B: D0 DE        BNE $926B
7E/928D: C6 48        DEC $48
7E/928F: D0 DA        BNE $926B
7E/9291: A9 01        LDA #$01
7E/9293: 14 70        TRB $70
7E/9295: A9 02        LDA #$02
7E/9297: 04 70        TSB $70
7E/9299: 64 73        STZ $73
7E/929B: A9 01        LDA #$01
7E/929D: 85 72        STA $72
7E/929F: 20 3B BF     JSR $BF3B
7E/92A2: 20 5D 94     JSR $945D
7E/92A5: 20 1E 9A     JSR $9A1E
7E/92A8: 20 81 9A     JSR $9A81
7E/92AB: 20 1E 9A     JSR $9A1E
7E/92AE: 20 81 9A     JSR $9A81
7E/92B1: A5 44        LDA $44
7E/92B3: 29 01        AND #$01
7E/92B5: D0 00        BNE $92B7
7E/92B7: E6 44        INC $44
7E/92B9: A5 71        LDA $71
7E/92BB: D0 E5        BNE $92A2
7E/92BD: 20 3A 80     JSR $803A
7E/92C0: 20 D0 98     JSR $98D0
7E/92C3: 20 FE BB     JSR $BBFE
7E/92C6: 20 C1 AF     JSR $AFC1
7E/92C9: A9 01        LDA #$01
7E/92CB: 04 4F        TSB $4F
7E/92CD: A9 81        LDA #$81
7E/92CF: 8D 00 42     STA $4200
7E/92D2: 58           CLI 
7E/92D3: A9 02        LDA #$02
7E/92D5: 14 70        TRB $70
7E/92D7: A9 01        LDA #$01
7E/92D9: 04 70        TSB $70
7E/92DB: 64 71        STZ $71
7E/92DD: 64 73        STZ $73
7E/92DF: A9 01        LDA #$01
7E/92E1: 85 72        STA $72
7E/92E3: A2 00 80     LDX #$8000
7E/92E6: 86 58        STX $58
7E/92E8: A2 00 60     LDX #$6000
7E/92EB: 86 5C        STX $5C
7E/92ED: A2 00 A0     LDX #$A000
7E/92F0: 86 5E        STX $5E
7E/92F2: A2 C0 00     LDX #$00C0
7E/92F5: 86 30        STX $30
7E/92F7: A2 C8 00     LDX #$00C8
7E/92FA: 86 32        STX $32
7E/92FC: A2 40 01     LDX #$0140
7E/92FF: 86 34        STX $34
7E/9301: A2 48 01     LDX #$0148
7E/9304: 86 36        STX $36
7E/9306: A2 17 00     LDX #$0017
7E/9309: 86 52        STX $52
7E/930B: 20 2C 9F     JSR $9F2C
7E/930E: E6 29        INC $29
7E/9310: 64 44        STZ $44
7E/9312: A9 05        LDA #$05
7E/9314: 85 48        STA $48
7E/9316: 20 5D 94     JSR $945D
7E/9319: 20 29 9A     JSR $9A29
7E/931C: 20 73 9A     JSR $9A73
7E/931F: 20 49 9A     JSR $9A49
7E/9322: 20 65 9A     JSR $9A65
7E/9325: 20 D2 BE     JSR $BED2
7E/9328: A5 29        LDA $29
7E/932A: F0 0C        BEQ $9338
7E/932C: C6 44        DEC $44
7E/932E: D0 E6        BNE $9316
7E/9330: C6 48        DEC $48
7E/9332: D0 E2        BNE $9316
7E/9334: 64 29        STZ $29
7E/9336: 80 DE        BRA $9316
7E/9338: C6 44        DEC $44
7E/933A: A5 2A        LDA $2A
7E/933C: D0 D8        BNE $9316
7E/933E: A9 2D        LDA #$2D
7E/9340: 85 44        STA $44
7E/9342: 20 5D 94     JSR $945D
7E/9345: 20 E4 9A     JSR $9AE4
7E/9348: 20 A8 9A     JSR $9AA8
7E/934B: 20 B1 9A     JSR $9AB1
7E/934E: 20 29 9A     JSR $9A29
7E/9351: 20 73 9A     JSR $9A73
7E/9354: 20 49 9A     JSR $9A49
7E/9357: 20 65 9A     JSR $9A65
7E/935A: 20 2C 9F     JSR $9F2C
7E/935D: C6 44        DEC $44
7E/935F: D0 E1        BNE $9342
7E/9361: E6 29        INC $29
7E/9363: 64 44        STZ $44
7E/9365: A9 05        LDA #$05
7E/9367: 85 48        STA $48
7E/9369: 20 5D 94     JSR $945D
7E/936C: 20 29 9A     JSR $9A29
7E/936F: 20 73 9A     JSR $9A73
7E/9372: 20 49 9A     JSR $9A49
7E/9375: 20 65 9A     JSR $9A65
7E/9378: 20 D2 BE     JSR $BED2
7E/937B: A5 29        LDA $29
7E/937D: F0 0C        BEQ $938B
7E/937F: C6 44        DEC $44
7E/9381: D0 E6        BNE $9369
7E/9383: C6 48        DEC $48
7E/9385: D0 E2        BNE $9369
7E/9387: 64 29        STZ $29
7E/9389: 80 DE        BRA $9369
7E/938B: C6 44        DEC $44
7E/938D: A5 2A        LDA $2A
7E/938F: D0 D8        BNE $9369
7E/9391: A9 17        LDA #$17
7E/9393: 85 44        STA $44
7E/9395: 20 5D 94     JSR $945D
7E/9398: 20 C9 9A     JSR $9AC9
7E/939B: 20 29 9A     JSR $9A29
7E/939E: 20 73 9A     JSR $9A73
7E/93A1: 20 49 9A     JSR $9A49
7E/93A4: 20 65 9A     JSR $9A65
7E/93A7: 20 2C 9F     JSR $9F2C
7E/93AA: C6 44        DEC $44
7E/93AC: D0 E7        BNE $9395
7E/93AE: E6 29        INC $29
7E/93B0: 64 44        STZ $44
7E/93B2: A9 04        LDA #$04
7E/93B4: 85 48        STA $48
7E/93B6: 20 5D 94     JSR $945D
7E/93B9: 20 29 9A     JSR $9A29
7E/93BC: 20 73 9A     JSR $9A73
7E/93BF: 20 49 9A     JSR $9A49
7E/93C2: 20 65 9A     JSR $9A65
7E/93C5: 20 D2 BE     JSR $BED2
7E/93C8: A5 29        LDA $29
7E/93CA: F0 0C        BEQ $93D8
7E/93CC: C6 44        DEC $44
7E/93CE: D0 E6        BNE $93B6
7E/93D0: C6 48        DEC $48
7E/93D2: D0 E2        BNE $93B6
7E/93D4: 64 29        STZ $29
7E/93D6: 80 DE        BRA $93B6
7E/93D8: C6 44        DEC $44
7E/93DA: A5 2A        LDA $2A
7E/93DC: D0 D8        BNE $93B6
7E/93DE: A9 17        LDA #$17
7E/93E0: 85 44        STA $44
7E/93E2: 20 5D 94     JSR $945D
7E/93E5: 20 C9 9A     JSR $9AC9
7E/93E8: 20 29 9A     JSR $9A29
7E/93EB: 20 73 9A     JSR $9A73
7E/93EE: 20 49 9A     JSR $9A49
7E/93F1: 20 65 9A     JSR $9A65
7E/93F4: 20 2C 9F     JSR $9F2C
7E/93F7: C6 44        DEC $44
7E/93F9: D0 E7        BNE $93E2
7E/93FB: E6 29        INC $29
7E/93FD: 64 44        STZ $44
7E/93FF: A9 04        LDA #$04
7E/9401: 85 48        STA $48
7E/9403: 20 5D 94     JSR $945D
7E/9406: 20 29 9A     JSR $9A29
7E/9409: 20 73 9A     JSR $9A73
7E/940C: 20 49 9A     JSR $9A49
7E/940F: 20 65 9A     JSR $9A65
7E/9412: 20 D2 BE     JSR $BED2
7E/9415: A5 29        LDA $29
7E/9417: F0 0C        BEQ $9425
7E/9419: C6 44        DEC $44
7E/941B: D0 E6        BNE $9403
7E/941D: C6 48        DEC $48
7E/941F: D0 E2        BNE $9403
7E/9421: 64 29        STZ $29
7E/9423: 80 DE        BRA $9403
7E/9425: C6 44        DEC $44
7E/9427: A5 2A        LDA $2A
7E/9429: D0 D8        BNE $9403
7E/942B: A9 01        LDA #$01
7E/942D: 14 70        TRB $70
7E/942F: A9 02        LDA #$02
7E/9431: 04 70        TSB $70
7E/9433: 64 73        STZ $73
7E/9435: A9 01        LDA #$01
7E/9437: 85 72        STA $72
7E/9439: 20 3B BF     JSR $BF3B
7E/943C: 20 5D 94     JSR $945D
7E/943F: 20 98 9A     JSR $9A98
7E/9442: 20 29 9A     JSR $9A29
7E/9445: 20 73 9A     JSR $9A73
7E/9448: 20 49 9A     JSR $9A49
7E/944B: 20 65 9A     JSR $9A65
7E/944E: A5 44        LDA $44
7E/9450: 29 01        AND #$01
7E/9452: D0 00        BNE $9454
7E/9454: E6 44        INC $44
7E/9456: A5 71        LDA $71
7E/9458: D0 E2        BNE $943C
7E/945A: 82 DD EB     BRL $803A
7E/945D: A5 07        LDA $07
7E/945F: D0 FC        BNE $945D
7E/9461: 1A           INC 
7E/9462: 85 07        STA $07
7E/9464: 60           RTS 

7E/9465: E2 20        SEP #$20
7E/9467: C2 10        REP #$10
7E/9469: A9 5C        LDA #$5C
7E/946B: 8D 00 1F     STA $1F00
7E/946E: A2 00 C5     LDX #$C500
7E/9471: 8E 01 1F     STX $1F01
7E/9474: A9 7F        LDA #$7F
7E/9476: 8D 03 1F     STA $1F03
7E/9479: E2 10        SEP #$10
7E/947B: A2 DF        LDX #$DF
7E/947D: A9 00        LDA #$00
7E/947F: 95 00        STA $00,X
7E/9481: CA           DEX 
7E/9482: D0 FB        BNE $947F
7E/9484: C2 10        REP #$10
7E/9486: A2 FF FF     LDX #$FFFF
7E/9489: 86 C5        STX $C5
7E/948B: A9 01        LDA #$01
7E/948D: 85 07        STA $07
7E/948F: 20 C1 AF     JSR $AFC1
7E/9492: A6 C7        LDX $C7
7E/9494: 86 30        STX $30
7E/9496: 86 32        STX $32
7E/9498: 86 52        STX $52
7E/949A: A2 80 00     LDX #$0080
7E/949D: 86 34        STX $34
7E/949F: A2 00 01     LDX #$0100
7E/94A2: 86 36        STX $36
7E/94A4: 60           RTS 
7E/94A5: A9 00        LDA #$00
7E/94A7: 48           PHA 
7E/94A8: AB           PLB 
7E/94A9: A9 63        LDA #$63
7E/94AB: 8D 01 21     STA $2101
7E/94AE: A9 00        LDA #$00
7E/94B0: 8D 02 21     STA $2102
7E/94B3: 8D 03 21     STA $2103
7E/94B6: A9 09        LDA #$09
7E/94B8: 8D 05 21     STA $2105
7E/94BB: A9 00        LDA #$00
7E/94BD: 8D 06 21     STA $2106
7E/94C0: 8D 07 21     STA $2107
7E/94C3: 8D 08 21     STA $2108
7E/94C6: 8D 09 21     STA $2109
7E/94C9: 8D 0A 21     STA $210A
7E/94CC: 8D 0B 21     STA $210B
7E/94CF: 8D 0C 21     STA $210C
7E/94D2: 8D 0D 21     STA $210D
7E/94D5: 8D 0D 21     STA $210D
7E/94D8: 8D 0E 21     STA $210E
7E/94DB: 8D 0E 21     STA $210E
7E/94DE: 8D 0F 21     STA $210F
7E/94E1: 8D 0F 21     STA $210F
7E/94E4: 8D 10 21     STA $2110
7E/94E7: 8D 10 21     STA $2110
7E/94EA: 8D 11 21     STA $2111
7E/94ED: 8D 11 21     STA $2111
7E/94F0: 8D 12 21     STA $2112
7E/94F3: 8D 12 21     STA $2112
7E/94F6: 8D 13 21     STA $2113
7E/94F9: 8D 13 21     STA $2113
7E/94FC: 8D 14 21     STA $2114
7E/94FF: 8D 14 21     STA $2114
7E/9502: 8D 15 21     STA $2115
7E/9505: 8D 16 21     STA $2116
7E/9508: 8D 17 21     STA $2117
7E/950B: 8D 1A 21     STA $211A
7E/950E: 8D 1B 21     STA $211B
7E/9511: A9 01        LDA #$01
7E/9513: 8D 1B 21     STA $211B
7E/9516: 3A           DEC 
7E/9517: 8D 1C 21     STA $211C
7E/951A: 8D 1C 21     STA $211C
7E/951D: 8D 1D 21     STA $211D
7E/9520: 8D 1D 21     STA $211D
7E/9523: 8D 1E 21     STA $211E
7E/9526: 1A           INC 
7E/9527: 8D 1E 21     STA $211E
7E/952A: 3A           DEC 
7E/952B: 8D 1F 21     STA $211F
7E/952E: 8D 1F 21     STA $211F
7E/9531: 8D 20 21     STA $2120
7E/9534: 8D 20 21     STA $2120
7E/9537: 8D 21 21     STA $2121
7E/953A: 8D 23 21     STA $2123
7E/953D: A9 03        LDA #$03
7E/953F: 8D 24 21     STA $2124
7E/9542: 9C 25 21     STZ $2125
7E/9545: 9C 26 21     STZ $2126
7E/9548: 9C 27 21     STZ $2127
7E/954B: 9C 28 21     STZ $2128
7E/954E: 9C 29 21     STZ $2129
7E/9551: 9C 2A 21     STZ $212A
7E/9554: 9C 2B 21     STZ $212B
7E/9557: 9C 2E 21     STZ $212E
7E/955A: 9C 2F 21     STZ $212F
7E/955D: 9C 30 21     STZ $2130
7E/9560: 9C 31 21     STZ $2131
7E/9563: 64 8E        STZ $8E
7E/9565: 9C 2C 21     STZ $212C
7E/9568: 9C 2D 21     STZ $212D
7E/956B: 64 3A        STZ $3A
7E/956D: 64 3B        STZ $3B
7E/956F: A9 E0        LDA #$E0
7E/9571: 8D 32 21     STA $2132
7E/9574: 9C 33 21     STZ $2133
7E/9577: 9C 00 42     STZ $4200
7E/957A: A9 FF        LDA #$FF
7E/957C: 8D 01 42     STA $4201
7E/957F: 9C 02 42     STZ $4202
7E/9582: 9C 03 42     STZ $4203
7E/9585: 9C 04 42     STZ $4204
7E/9588: 9C 05 42     STZ $4205
7E/958B: 9C 06 42     STZ $4206
7E/958E: 9C 07 42     STZ $4207
7E/9591: 9C 08 42     STZ $4208
7E/9594: 9C 09 42     STZ $4209
7E/9597: 9C 0A 42     STZ $420A
7E/959A: 9C 0B 42     STZ $420B
7E/959D: 9C 0C 42     STZ $420C
7E/95A0: 60           RTS 

7E/95A1: A5 42        LDA $42
7E/95A3: D0 06        BNE $95AB
7E/95A5: A5 43        LDA $43
7E/95A7: D0 02        BNE $95AB
7E/95A9: 18           CLC 
7E/95AA: 60           RTS 
7E/95AB: C2 20        REP #$20
7E/95AD: AF F8 7F 30  LDA $307FF8
7E/95B1: C9 1B E4     CMP #$E41B
7E/95B4: F0 1F        BEQ $95D5
7E/95B6: AF FA 7F 30  LDA $307FFA
7E/95BA: C9 1B E4     CMP #$E41B
7E/95BD: F0 16        BEQ $95D5
7E/95BF: AF FC 7F 30  LDA $307FFC
7E/95C3: C9 1B E4     CMP #$E41B
7E/95C6: F0 0D        BEQ $95D5
7E/95C8: AF FE 7F 30  LDA $307FFE
7E/95CC: C9 1B E4     CMP #$E41B
7E/95CF: F0 04        BEQ $95D5
7E/95D1: E2 20        SEP #$20
7E/95D3: 18           CLC 
7E/95D4: 60           RTS 
7E/95D5: E2 20        SEP #$20
7E/95D7: 38           SEC 
7E/95D8: 60           RTS 

7E/95D9: 8B           PHB 
7E/95DA: C2 20        REP #$20
7E/95DC: A2 20 04     LDX #$0420
7E/95DF: A0 00 F0     LDY #$F000
7E/95E2: A9 C8 00     LDA #$00C8
7E/95E5: 54 7F 00     MVN $7F,$00
7E/95E8: E2 20        SEP #$20
7E/95EA: AB           PLB 
7E/95EB: 60           RTS 

7E/95EC: 8B           PHB 
7E/95ED: C2 20        REP #$20
7E/95EF: A0 20 04     LDY #$0420
7E/95F2: A2 00 F0     LDX #$F000
7E/95F5: A9 C8 00     LDA #$00C8
7E/95F8: 54 00 7F     MVN $00,$7F
7E/95FB: E2 20        SEP #$20
7E/95FD: AB           PLB 
7E/95FE: 60           RTS 

7E/95FF: A9 17        LDA #$17
7E/9601: 8D 05 21     STA $2105
7E/9604: A9 40        LDA #$40
7E/9606: 8D 1A 21     STA $211A
7E/9609: A9 00        LDA #$00
7E/960B: 8D 2D 21     STA $212D
7E/960E: 85 3A        STA $3A
7E/9610: 8D 2D 21     STA $212D
7E/9613: A9 01        LDA #$01
7E/9615: 8D 2C 21     STA $212C
7E/9618: 85 3B        STA $3B
7E/961A: A9 01        LDA #$01
7E/961C: 8D 2E 21     STA $212E
7E/961F: A9 00        LDA #$00
7E/9621: 8D 31 21     STA $2131
7E/9624: 85 8E        STA $8E
7E/9626: A9 E0        LDA #$E0
7E/9628: 8D 32 21     STA $2132
7E/962B: 64 8B        STZ $8B
7E/962D: 64 8C        STZ $8C
7E/962F: 64 8D        STZ $8D
7E/9631: A9 00        LDA #$00
7E/9633: 8D 30 21     STA $2130
7E/9636: 8D 0B 21     STA $210B
7E/9639: 60           RTS 

7E/963A: A9 17        LDA #$17
7E/963C: 8D 05 21     STA $2105
7E/963F: A9 40        LDA #$40
7E/9641: 8D 1A 21     STA $211A
7E/9644: A9 00        LDA #$00
7E/9646: 8D 2F 21     STA $212F
7E/9649: A9 01        LDA #$01
7E/964B: 8D 2D 21     STA $212D
7E/964E: 85 3A        STA $3A
7E/9650: A9 10        LDA #$10
7E/9652: 8D 2C 21     STA $212C
7E/9655: 85 3B        STA $3B
7E/9657: A9 01        LDA #$01
7E/9659: 8D 2E 21     STA $212E
7E/965C: A9 30        LDA #$30
7E/965E: 8D 31 21     STA $2131
7E/9661: 85 8E        STA $8E
7E/9663: A9 E0        LDA #$E0
7E/9665: 8D 32 21     STA $2132
7E/9668: 64 8B        STZ $8B
7E/966A: 64 8C        STZ $8C
7E/966C: 64 8D        STZ $8D
7E/966E: A9 02        LDA #$02
7E/9670: 8D 30 21     STA $2130
7E/9673: A9 00        LDA #$00
7E/9675: 8D 0B 21     STA $210B
7E/9678: 60           RTS 

7E/9679: A9 17        LDA #$17
7E/967B: 8D 05 21     STA $2105
7E/967E: A9 80        LDA #$80
7E/9680: 8D 1A 21     STA $211A
7E/9683: A9 00        LDA #$00
7E/9685: 8D 2F 21     STA $212F
7E/9688: A9 01        LDA #$01
7E/968A: 8D 2D 21     STA $212D
7E/968D: 85 3A        STA $3A
7E/968F: A9 11        LDA #$11
7E/9691: 8D 2C 21     STA $212C
7E/9694: 85 3B        STA $3B
7E/9696: A9 01        LDA #$01
7E/9698: 8D 2E 21     STA $212E
7E/969B: A9 70        LDA #$70
7E/969D: 8D 31 21     STA $2131
7E/96A0: 85 8E        STA $8E
7E/96A2: A9 E0        LDA #$E0
7E/96A4: 8D 32 21     STA $2132
7E/96A7: 64 8B        STZ $8B
7E/96A9: 64 8C        STZ $8C
7E/96AB: 64 8D        STZ $8D
7E/96AD: A9 02        LDA #$02
7E/96AF: 8D 30 21     STA $2130
7E/96B2: A9 00        LDA #$00
7E/96B4: 8D 0B 21     STA $210B
7E/96B7: 60           RTS 

7E/96B8: A9 17        LDA #$17
7E/96BA: 8D 05 21     STA $2105
7E/96BD: A9 40        LDA #$40
7E/96BF: 8D 1A 21     STA $211A
7E/96C2: A9 00        LDA #$00
7E/96C4: 8D 2F 21     STA $212F
7E/96C7: A9 01        LDA #$01
7E/96C9: 8D 2D 21     STA $212D
7E/96CC: 85 3A        STA $3A
7E/96CE: A9 11        LDA #$11
7E/96D0: 8D 2C 21     STA $212C
7E/96D3: 85 3B        STA $3B
7E/96D5: A9 01        LDA #$01
7E/96D7: 8D 2E 21     STA $212E
7E/96DA: A9 00        LDA #$00
7E/96DC: 8D 30 21     STA $2130
7E/96DF: A9 21        LDA #$21
7E/96E1: 85 8E        STA $8E
7E/96E3: 8D 31 21     STA $2131
7E/96E6: 85 8E        STA $8E
7E/96E8: A9 E0        LDA #$E0
7E/96EA: 8D 32 21     STA $2132
7E/96ED: 64 8B        STZ $8B
7E/96EF: 64 8C        STZ $8C
7E/96F1: 64 8D        STZ $8D
7E/96F3: A9 00        LDA #$00
7E/96F5: 8D 0B 21     STA $210B
7E/96F8: 60           RTS 

7E/96F9: A6 C7        LDX $C7
7E/96FB: 86 30        STX $30
7E/96FD: 86 32        STX $32
7E/96FF: A2 80 00     LDX #$0080
7E/9702: 86 34        STX $34
7E/9704: A2 00 01     LDX #$0100
7E/9707: 86 36        STX $36
7E/9709: A6 C7        LDX $C7
7E/970B: 86 52        STX $52
7E/970D: 60           RTS 

7E/970E: A9 C3        LDA #$C3
7E/9710: 85 D2        STA $D2
7E/9712: A2 43 12     LDX #$1243
7E/9715: 86 D0        STX $D0
7E/9717: A9 7E        LDA #$7E
7E/9719: 85 D5        STA $D5
7E/971B: A2 00 91     LDX #$9100
7E/971E: 86 D3        STX $D3
7E/9720: 20 0D C0     JSR $C00D
7E/9723: A9 C3        LDA #$C3
7E/9725: 85 D2        STA $D2
7E/9727: A2 65 1C     LDX #$1C65
7E/972A: 86 D0        STX $D0
7E/972C: A9 7E        LDA #$7E
7E/972E: 85 D5        STA $D5
7E/9730: A2 00 90     LDX #$9000
7E/9733: 86 D3        STX $D3
7E/9735: 20 0D C0     JSR $C00D
7E/9738: 20 AD 97     JSR $97AD
7E/973B: 20 F8 97     JSR $97F8
7E/973E: A9 C3        LDA #$C3
7E/9740: 85 D2        STA $D2
7E/9742: A2 F6 33     LDX #$33F6
7E/9745: 86 D0        STX $D0
7E/9747: A9 7E        LDA #$7E
7E/9749: 85 D5        STA $D5
7E/974B: A2 00 48     LDX #$4800
7E/974E: 86 D3        STX $D3
7E/9750: 82 BA 28     BRL $C00D

7E/9753: A9 C3        LDA #$C3        ; C3/0368
7E/9755: 85 D2        STA $D2
7E/9757: A2 68 03     LDX #$0368
7E/975A: 86 D0        STX $D0
7E/975C: A9 7E        LDA #$7E
7E/975E: 85 D5        STA $D5
7E/9760: A2 00 91     LDX #$9100
7E/9763: 86 D3        STX $D3
7E/9765: 20 0D C0     JSR $C00D
7E/9768: A9 C3        LDA #$C3
7E/976A: 85 D2        STA $D2
7E/976C: A2 F9 05     LDX #$05F9      ; C3/05F9
7E/976F: 86 D0        STX $D0
7E/9771: A9 7E        LDA #$7E
7E/9773: 85 D5        STA $D5
7E/9775: A2 00 90     LDX #$9000
7E/9778: 86 D3        STX $D3
7E/977A: 20 0D C0     JSR $C00D
7E/977D: 82 2D 00     BRL $97AD

7E/9780: A9 C3        LDA #$C3        ; C3/3909
7E/9782: 85 D2        STA $D2
7E/9784: A2 09 39     LDX #$3909
7E/9787: 86 D0        STX $D0
7E/9789: A9 7E        LDA #$7E
7E/978B: 85 D5        STA $D5
7E/978D: A2 00 91     LDX #$9100
7E/9790: 86 D3        STX $D3
7E/9792: 20 0D C0     JSR $C00D
7E/9795: A9 C3        LDA #$C3        ; C3/4452
7E/9797: 85 D2        STA $D2
7E/9799: A2 52 44     LDX #$4452
7E/979C: 86 D0        STX $D0
7E/979E: A9 7E        LDA #$7E
7E/97A0: 85 D5        STA $D5
7E/97A2: A2 00 90     LDX #$9000
7E/97A5: 86 D3        STX $D3
7E/97A7: 20 0D C0     JSR $C00D
7E/97AA: 82 00 00     BRL $97AD

7E/97AD: A2 00 00     LDX #$0000
7E/97B0: 8E 16 21     STX $2116
7E/97B3: A9 80        LDA #$80
7E/97B5: 8D 15 21     STA $2115
7E/97B8: A6 C7        LDX $C7
7E/97BA: 86 0C        STX $0C
7E/97BC: 86 0E        STX $0E
7E/97BE: A6 0C        LDX $0C
7E/97C0: BF 00 91 7E  LDA $7E9100,X
7E/97C4: 48           PHA 
7E/97C5: 29 0F        AND #$0F
7E/97C7: A6 0E        LDX $0E
7E/97C9: 1F 00 90 7E  ORA $7E9000,X
7E/97CD: 8D 19 21     STA $2119
7E/97D0: 68           PLA 
7E/97D1: 29 F0        AND #$F0
7E/97D3: 4A           LSR 
7E/97D4: 4A           LSR 
7E/97D5: 4A           LSR 
7E/97D6: 4A           LSR 
7E/97D7: 1F 00 90 7E  ORA $7E9000,X
7E/97DB: 8D 19 21     STA $2119
7E/97DE: C2 20        REP #$20
7E/97E0: A5 0C        LDA $0C
7E/97E2: 1A           INC 
7E/97E3: C9 00 20     CMP #$2000
7E/97E6: F0 0D        BEQ $97F5
7E/97E8: 85 0C        STA $0C
7E/97EA: 29 1F 00     AND #$001F
7E/97ED: D0 02        BNE $97F1
7E/97EF: E6 0E        INC $0E
7E/97F1: E2 20        SEP #$20
7E/97F3: 80 C9        BRA $97BE
7E/97F5: E2 20        SEP #$20
7E/97F7: 60           RTS 
7E/97F8: A6 C7        LDX $C7
7E/97FA: 86 0C        STX $0C
7E/97FC: 86 0E        STX $0E
7E/97FE: BF 00 91 7E  LDA $7E9100,X
7E/9802: 86 0C        STX $0C
7E/9804: 48           PHA 
7E/9805: 29 0F        AND #$0F
7E/9807: F0 0A        BEQ $9813
7E/9809: A6 0E        LDX $0E
7E/980B: A9 00        LDA #$00
7E/980D: 9F 00 00 7F  STA $7F0000,X
7E/9811: 80 08        BRA $981B
7E/9813: A9 20        LDA #$20
7E/9815: A6 0E        LDX $0E
7E/9817: 9F 00 00 7F  STA $7F0000,X
7E/981B: E8           INX 
7E/981C: 68           PLA 
7E/981D: 29 F0        AND #$F0
7E/981F: F0 08        BEQ $9829
7E/9821: A9 00        LDA #$00
7E/9823: 9F 00 00 7F  STA $7F0000,X
7E/9827: 80 06        BRA $982F
7E/9829: A9 20        LDA #$20
7E/982B: 9F 00 00 7F  STA $7F0000,X
7E/982F: E8           INX 
7E/9830: 86 0E        STX $0E
7E/9832: A6 0C        LDX $0C
7E/9834: E8           INX 
7E/9835: E0 00 18     CPX #$1800
7E/9838: D0 C4        BNE $97FE
7E/983A: 60           RTS 
7E/983B: A9 7E        LDA #$7E
7E/983D: 85 D5        STA $D5
7E/983F: A2 00 90     LDX #$9000
7E/9842: 86 D3        STX $D3
7E/9844: A2 00 10     LDX #$1000
7E/9847: 86 D6        STX $D6
7E/9849: 20 E0 C1     JSR $C1E0
7E/984C: E2 20        SEP #$20
7E/984E: A2 00 20     LDX #$2000
7E/9851: 86 14        STX $14
7E/9853: 20 B6 99     JSR $99B6
7E/9856: A2 40 00     LDX #$0040
7E/9859: 86 14        STX $14
7E/985B: 20 B6 99     JSR $99B6
7E/985E: A6 C7        LDX $C7
7E/9860: 86 14        STX $14
7E/9862: 20 B6 99     JSR $99B6
7E/9865: A2 40 20     LDX #$2040
7E/9868: 86 14        STX $14
7E/986A: 20 B6 99     JSR $99B6
7E/986D: A9 C3        LDA #$C3
7E/986F: 85 D2        STA $D2
7E/9871: A2 69 1C     LDX #$1C69
7E/9874: 86 D0        STX $D0
7E/9876: A9 7E        LDA #$7E
7E/9878: 85 D5        STA $D5
7E/987A: A2 00 90     LDX #$9000
7E/987D: 86 D3        STX $D3
7E/987F: 20 0D C0     JSR $C00D
7E/9882: A2 40 20     LDX #$2040
7E/9885: 86 14        STX $14
7E/9887: 82 60 01     BRL $99EA
7E/988A: A9 C3        LDA #$C3        ; C3/05FD
7E/988C: 85 D2        STA $D2
7E/988E: A2 FD 05     LDX #$05FD
7E/9891: 86 D0        STX $D0
7E/9893: A9 7E        LDA #$7E
7E/9895: 85 D5        STA $D5
7E/9897: A2 00 90     LDX #$9000
7E/989A: 86 D3        STX $D3
7E/989C: 20 0D C0     JSR $C00D
7E/989F: A2 40 20     LDX #$2040
7E/98A2: 86 14        STX $14
7E/98A4: 20 B6 99     JSR $99B6
7E/98A7: C2 20        REP #$20
7E/98A9: A5 C7        LDA $C7
7E/98AB: AA           TAX 
7E/98AC: 8F 00 90 7E  STA $7E9000
7E/98B0: E8           INX 
7E/98B1: E8           INX 
7E/98B2: E0 00 10     CPX #$1000
7E/98B5: D0 F5        BNE $98AC
7E/98B7: E2 20        SEP #$20
7E/98B9: A2 00 20     LDX #$2000
7E/98BC: 86 14        STX $14
7E/98BE: 20 B6 99     JSR $99B6
7E/98C1: A2 40 00     LDX #$0040
7E/98C4: 86 14        STX $14
7E/98C6: 20 B6 99     JSR $99B6
7E/98C9: A6 C7        LDX $C7
7E/98CB: 86 14        STX $14
7E/98CD: 82 E6 00     BRL $99B6
7E/98D0: A9 C3        LDA #$C3
7E/98D2: 85 D2        STA $D2
7E/98D4: A2 69 44     LDX #$4469
7E/98D7: 86 D0        STX $D0
7E/98D9: A9 7F        LDA #$7F
7E/98DB: 85 D5        STA $D5
7E/98DD: A2 00 00     LDX #$0000
7E/98E0: 86 D3        STX $D3
7E/98E2: 20 F0 C0     JSR $C0F0
7E/98E5: A9 7F        LDA #$7F
7E/98E7: 85 D2        STA $D2
7E/98E9: A2 00 00     LDX #$0000
7E/98EC: 86 D0        STX $D0
7E/98EE: A9 7E        LDA #$7E
7E/98F0: 85 D5        STA $D5
7E/98F2: A2 00 90     LDX #$9000
7E/98F5: 86 D3        STX $D3
7E/98F7: 20 5D C0     JSR $C05D
7E/98FA: A2 40 20     LDX #$2040
7E/98FD: 86 14        STX $14
7E/98FF: 20 B6 99     JSR $99B6
7E/9902: A6 C7        LDX $C7
7E/9904: 86 14        STX $14
7E/9906: 20 B6 99     JSR $99B6
7E/9909: A9 C3        LDA #$C3
7E/990B: 85 D2        STA $D2
7E/990D: A2 EF 51     LDX #$51EF
7E/9910: 86 D0        STX $D0
7E/9912: A9 7F        LDA #$7F
7E/9914: 85 D5        STA $D5
7E/9916: A2 00 00     LDX #$0000
7E/9919: 86 D3        STX $D3
7E/991B: 20 F0 C0     JSR $C0F0
7E/991E: A9 7F        LDA #$7F
7E/9920: 85 D2        STA $D2
7E/9922: A2 00 00     LDX #$0000
7E/9925: 86 D0        STX $D0
7E/9927: A9 7E        LDA #$7E
7E/9929: 85 D5        STA $D5
7E/992B: A2 00 90     LDX #$9000
7E/992E: 86 D3        STX $D3
7E/9930: 20 5D C0     JSR $C05D
7E/9933: A2 00 20     LDX #$2000
7E/9936: 86 14        STX $14
7E/9938: 20 B6 99     JSR $99B6
7E/993B: A2 40 00     LDX #$0040
7E/993E: 86 14        STX $14
7E/9940: 82 73 00     BRL $99B6
7E/9943: A9 C3        LDA #$C3
7E/9945: 85 D2        STA $D2
7E/9947: A2 34 4E     LDX #$4E34
7E/994A: 86 D0        STX $D0
7E/994C: A9 7F        LDA #$7F
7E/994E: 85 D5        STA $D5
7E/9950: A2 00 00     LDX #$0000
7E/9953: 86 D3        STX $D3
7E/9955: 20 F0 C0     JSR $C0F0
7E/9958: A9 7F        LDA #$7F
7E/995A: 85 D2        STA $D2
7E/995C: A2 00 00     LDX #$0000
7E/995F: 86 D0        STX $D0
7E/9961: A9 7E        LDA #$7E
7E/9963: 85 D5        STA $D5
7E/9965: A2 00 90     LDX #$9000
7E/9968: 86 D3        STX $D3
7E/996A: 20 5D C0     JSR $C05D
7E/996D: A6 C7        LDX $C7
7E/996F: 86 14        STX $14
7E/9971: 20 B6 99     JSR $99B6
7E/9974: A2 40 20     LDX #$2040
7E/9977: 86 14        STX $14
7E/9979: 20 B6 99     JSR $99B6
7E/997C: A9 C3        LDA #$C3
7E/997E: 85 D2        STA $D2
7E/9980: A2 D4 50     LDX #$50D4
7E/9983: 86 D0        STX $D0
7E/9985: A9 7F        LDA #$7F
7E/9987: 85 D5        STA $D5
7E/9989: A2 00 00     LDX #$0000
7E/998C: 86 D3        STX $D3
7E/998E: 20 F0 C0     JSR $C0F0
7E/9991: A9 7F        LDA #$7F
7E/9993: 85 D2        STA $D2
7E/9995: A2 00 00     LDX #$0000
7E/9998: 86 D0        STX $D0
7E/999A: A9 7E        LDA #$7E
7E/999C: 85 D5        STA $D5
7E/999E: A2 00 90     LDX #$9000
7E/99A1: 86 D3        STX $D3
7E/99A3: 20 5D C0     JSR $C05D
7E/99A6: A2 40 00     LDX #$0040
7E/99A9: 86 14        STX $14
7E/99AB: 20 B6 99     JSR $99B6
7E/99AE: A2 00 20     LDX #$2000
7E/99B1: 86 14        STX $14
7E/99B3: 82 00 00     BRL $99B6
7E/99B6: A9 00        LDA #$00
7E/99B8: 8D 15 21     STA $2115
7E/99BB: A6 14        LDX $14
7E/99BD: 8E 16 21     STX $2116
7E/99C0: A6 C7        LDX $C7
7E/99C2: A0 40 00     LDY #$0040
7E/99C5: BF 00 90 7E  LDA $7E9000,X
7E/99C9: 8D 18 21     STA $2118
7E/99CC: E0 FF 0F     CPX #$0FFF
7E/99CF: F0 18        BEQ $99E9
7E/99D1: E8           INX 
7E/99D2: 88           DEY 
7E/99D3: D0 F0        BNE $99C5
7E/99D5: C2 20        REP #$20
7E/99D7: A5 14        LDA $14
7E/99D9: 18           CLC 
7E/99DA: 69 80 00     ADC #$0080
7E/99DD: 85 14        STA $14
7E/99DF: 8D 16 21     STA $2116
7E/99E2: E2 20        SEP #$20
7E/99E4: A0 40 00     LDY #$0040
7E/99E7: 80 DC        BRA $99C5
7E/99E9: 60           RTS 
7E/99EA: A9 00        LDA #$00
7E/99EC: 8D 15 21     STA $2115
7E/99EF: A6 14        LDX $14
7E/99F1: 8E 16 21     STX $2116
7E/99F4: A6 C7        LDX $C7
7E/99F6: A0 20 00     LDY #$0020
7E/99F9: BF 00 90 7E  LDA $7E9000,X
7E/99FD: 8D 18 21     STA $2118
7E/9A00: E0 00 04     CPX #$0400
7E/9A03: F0 18        BEQ $9A1D
7E/9A05: E8           INX 
7E/9A06: 88           DEY 
7E/9A07: D0 F0        BNE $99F9
7E/9A09: C2 20        REP #$20
7E/9A0B: A5 14        LDA $14
7E/9A0D: 18           CLC 
7E/9A0E: 69 80 00     ADC #$0080
7E/9A11: 85 14        STA $14
7E/9A13: 8D 16 21     STA $2116
7E/9A16: E2 20        SEP #$20
7E/9A18: A0 20 00     LDY #$0020
7E/9A1B: 80 DC        BRA $99F9
7E/9A1D: 60           RTS 
7E/9A1E: A6 32        LDX $32
7E/9A20: D0 03        BNE $9A25
7E/9A22: A2 00 04     LDX #$0400
7E/9A25: CA           DEX 
7E/9A26: 86 32        STX $32
7E/9A28: 60           RTS 
7E/9A29: A6 32        LDX $32
7E/9A2B: E0 FF 03     CPX #$03FF
7E/9A2E: D0 05        BNE $9A35
7E/9A30: A6 C7        LDX $C7
7E/9A32: 86 32        STX $32
7E/9A34: 60           RTS 
7E/9A35: E8           INX 
7E/9A36: 86 32        STX $32
7E/9A38: 60           RTS 
7E/9A39: A6 30        LDX $30
7E/9A3B: E0 FF 03     CPX #$03FF
7E/9A3E: D0 05        BNE $9A45
7E/9A40: A6 C7        LDX $C7
7E/9A42: 86 30        STX $30
7E/9A44: 60           RTS 
7E/9A45: E8           INX 
7E/9A46: 86 30        STX $30
7E/9A48: 60           RTS 
7E/9A49: A6 30        LDX $30
7E/9A4B: D0 06        BNE $9A53
7E/9A4D: A2 FF 03     LDX #$03FF
7E/9A50: 86 30        STX $30
7E/9A52: 60           RTS 
7E/9A53: CA           DEX 
7E/9A54: 86 30        STX $30
7E/9A56: 60           RTS 
7E/9A57: A6 34        LDX $34
7E/9A59: E8           INX 
7E/9A5A: E0 80 04     CPX #$0480
7E/9A5D: D0 03        BNE $9A62
7E/9A5F: A2 80 00     LDX #$0080
7E/9A62: 86 34        STX $34
7E/9A64: 60           RTS 
7E/9A65: A6 34        LDX $34
7E/9A67: CA           DEX 
7E/9A68: E0 80 00     CPX #$0080
7E/9A6B: D0 03        BNE $9A70
7E/9A6D: A2 7F 04     LDX #$047F
7E/9A70: 86 34        STX $34
7E/9A72: 60           RTS 
7E/9A73: A6 36        LDX $36
7E/9A75: E8           INX 
7E/9A76: E0 80 04     CPX #$0480
7E/9A79: D0 03        BNE $9A7E
7E/9A7B: A2 80 00     LDX #$0080
7E/9A7E: 86 36        STX $36
7E/9A80: 60           RTS 
7E/9A81: A6 36        LDX $36
7E/9A83: E0 80 00     CPX #$0080
7E/9A86: D0 03        BNE $9A8B
7E/9A88: A2 80 04     LDX #$0480
7E/9A8B: CA           DEX 
7E/9A8C: 86 36        STX $36
7E/9A8E: 60           RTS 
7E/9A8F: A5 59        LDA $59
7E/9A91: C9 01        CMP #$01
7E/9A93: F0 02        BEQ $9A97
7E/9A95: C6 59        DEC $59
7E/9A97: 60           RTS 
7E/9A98: A5 59        LDA $59
7E/9A9A: C9 FF        CMP #$FF
7E/9A9C: F0 02        BEQ $9AA0
7E/9A9E: E6 59        INC $59
7E/9AA0: 60           RTS 
7E/9AA1: A5 5F        LDA $5F
7E/9AA3: F0 02        BEQ $9AA7
7E/9AA5: C6 5F        DEC $5F
7E/9AA7: 60           RTS 
7E/9AA8: A5 5F        LDA $5F
7E/9AAA: C9 FF        CMP #$FF
7E/9AAC: F0 02        BEQ $9AB0
7E/9AAE: E6 5F        INC $5F
7E/9AB0: 60           RTS 
7E/9AB1: A5 5D        LDA $5D
7E/9AB3: C9 01        CMP #$01
7E/9AB5: F0 03        BEQ $9ABA
7E/9AB7: C6 5D        DEC $5D
7E/9AB9: 60           RTS 
7E/9ABA: 64 4E        STZ $4E
7E/9ABC: 60           RTS 
7E/9ABD: A5 5D        LDA $5D
7E/9ABF: C9 FF        CMP #$FF
7E/9AC1: F0 03        BEQ $9AC6
7E/9AC3: E6 5D        INC $5D
7E/9AC5: 60           RTS 
7E/9AC6: 64 4E        STZ $4E
7E/9AC8: 60           RTS 
7E/9AC9: A6 52        LDX $52
7E/9ACB: E0 67 01     CPX #$0167
7E/9ACE: F0 04        BEQ $9AD4
7E/9AD0: E8           INX 
7E/9AD1: 86 52        STX $52
7E/9AD3: 60           RTS 
7E/9AD4: A6 C7        LDX $C7
7E/9AD6: 86 52        STX $52
7E/9AD8: 60           RTS 
7E/9AD9: A6 38        LDX $38
7E/9ADB: E0 E1 00     CPX #$00E1
7E/9ADE: F0 03        BEQ $9AE3
7E/9AE0: E8           INX 
7E/9AE1: 86 38        STX $38
7E/9AE3: 60           RTS 
7E/9AE4: A6 52        LDX $52
7E/9AE6: F0 04        BEQ $9AEC
7E/9AE8: CA           DEX 
7E/9AE9: 86 52        STX $52
7E/9AEB: 60           RTS 
7E/9AEC: A2 67 01     LDX #$0167
7E/9AEF: 86 52        STX $52
7E/9AF1: 60           RTS 
7E/9AF2: A6 52        LDX $52
7E/9AF4: E0 0E 01     CPX #$010E
7E/9AF7: B0 3E        BCS $9B37
7E/9AF9: E0 B4 00     CPX #$00B4
7E/9AFC: B0 27        BCS $9B25
7E/9AFE: E0 5A 00     CPX #$005A
7E/9B01: B0 10        BCS $9B13
7E/9B03: BF 00 C0 7E  LDA $7EC000,X
7E/9B07: 85 55        STA $55
7E/9B09: BF 5A C0 7E  LDA $7EC05A,X
7E/9B0D: 85 54        STA $54
7E/9B0F: 64 50        STZ $50
7E/9B11: 80 34        BRA $9B47
7E/9B13: BF 00 C0 7E  LDA $7EC000,X
7E/9B17: 85 55        STA $55
7E/9B19: BF A6 BF 7E  LDA $7EBFA6,X
7E/9B1D: 85 54        STA $54
7E/9B1F: A9 01        LDA #$01
7E/9B21: 85 50        STA $50
7E/9B23: 80 22        BRA $9B47
7E/9B25: BF 4C BF 7E  LDA $7EBF4C,X
7E/9B29: 85 55        STA $55
7E/9B2B: BF A6 BF 7E  LDA $7EBFA6,X
7E/9B2F: 85 54        STA $54
7E/9B31: A9 80        LDA #$80
7E/9B33: 85 50        STA $50
7E/9B35: 80 10        BRA $9B47
7E/9B37: BF 4C BF 7E  LDA $7EBF4C,X
7E/9B3B: 85 55        STA $55
7E/9B3D: BF F2 BE 7E  LDA $7EBEF2,X
7E/9B41: 85 54        STA $54
7E/9B43: A9 81        LDA #$81
7E/9B45: 85 50        STA $50
7E/9B47: A9 0F        LDA #$0F
7E/9B49: 04 40        TSB $40
7E/9B4B: A9 42        LDA #$42
7E/9B4D: 8D 00 43     STA $4300
7E/9B50: 8D 10 43     STA $4310
7E/9B53: 8D 20 43     STA $4320
7E/9B56: 8D 30 43     STA $4330
7E/9B59: A9 1B        LDA #$1B
7E/9B5B: 8D 01 43     STA $4301
7E/9B5E: A9 1E        LDA #$1E
7E/9B60: 8D 11 43     STA $4311
7E/9B63: A9 1C        LDA #$1C
7E/9B65: 8D 21 43     STA $4321
7E/9B68: A9 1D        LDA #$1D
7E/9B6A: 8D 31 43     STA $4331
7E/9B6D: A2 00 80     LDX #$8000
7E/9B70: 8E 02 43     STX $4302
7E/9B73: 8E 12 43     STX $4312
7E/9B76: A2 06 80     LDX #$8006
7E/9B79: 8E 22 43     STX $4322
7E/9B7C: A2 0C 80     LDX #$800C
7E/9B7F: 8E 32 43     STX $4332
7E/9B82: A9 7E        LDA #$7E
7E/9B84: 8D 04 43     STA $4304
7E/9B87: 8D 14 43     STA $4314
7E/9B8A: 8D 24 43     STA $4324
7E/9B8D: 8D 34 43     STA $4334
7E/9B90: 8D 07 43     STA $4307
7E/9B93: 8D 17 43     STA $4317
7E/9B96: 8D 27 43     STA $4327
7E/9B99: 8D 37 43     STA $4337
7E/9B9C: A9 FF        LDA #$FF
7E/9B9E: 8F 00 80 7E  STA $7E8000
7E/9BA2: 8F 06 80 7E  STA $7E8006
7E/9BA6: 8F 0C 80 7E  STA $7E800C
7E/9BAA: A9 E2        LDA #$E2
7E/9BAC: 8F 03 80 7E  STA $7E8003
7E/9BB0: 8F 09 80 7E  STA $7E8009
7E/9BB4: 8F 0F 80 7E  STA $7E800F
7E/9BB8: C2 20        REP #$20
7E/9BBA: A9 00 81     LDA #$8100
7E/9BBD: 8F 01 80 7E  STA $7E8001
7E/9BC1: A9 00 82     LDA #$8200
7E/9BC4: 8F 04 80 7E  STA $7E8004
7E/9BC8: A9 00 83     LDA #$8300
7E/9BCB: 8F 07 80 7E  STA $7E8007
7E/9BCF: A9 00 84     LDA #$8400
7E/9BD2: 8F 0A 80 7E  STA $7E800A
7E/9BD6: A9 00 85     LDA #$8500
7E/9BD9: 8F 0D 80 7E  STA $7E800D
7E/9BDD: A9 00 86     LDA #$8600
7E/9BE0: 8F 10 80 7E  STA $7E8010
7E/9BE4: A5 5E        LDA $5E
7E/9BE6: 38           SEC 
7E/9BE7: E5 5C        SBC $5C
7E/9BE9: 8D 04 42     STA $4204
7E/9BEC: A0 71 00     LDY #$0071
7E/9BEF: 8C 06 42     STY $4206
7E/9BF2: 84 0E        STY $0E
7E/9BF4: A6 C7        LDX $C7
7E/9BF6: A5 5C        LDA $5C
7E/9BF8: 85 0A        STA $0A
7E/9BFA: AD 14 42     LDA $4214
7E/9BFD: 85 5A        STA $5A
7E/9BFF: A5 58        LDA $58
7E/9C01: 8D 04 42     STA $4204
7E/9C04: E2 20        SEP #$20
7E/9C06: A5 50        LDA $50
7E/9C08: F0 03        BEQ $9C0D
7E/9C0A: 82 73 00     BRL $9C80
7E/9C0D: C2 20        REP #$20
7E/9C0F: A5 0A        LDA $0A
7E/9C11: 65 5A        ADC $5A
7E/9C13: EB           XBA 
7E/9C14: 8D 06 42     STA $4206
7E/9C17: EB           XBA 
7E/9C18: 85 0A        STA $0A
7E/9C1A: E2 20        SEP #$20
7E/9C1C: A5 54        LDA $54
7E/9C1E: 8D 02 42     STA $4202
7E/9C21: AC 14 42     LDY $4214
7E/9C24: 98           TYA 
7E/9C25: 8D 03 42     STA $4203
7E/9C28: 84 56        STY $56
7E/9C2A: A5 57        LDA $57
7E/9C2C: AC 17 42     LDY $4217
7E/9C2F: 8D 03 42     STA $4203
7E/9C32: 84 08        STY $08
7E/9C34: 64 09        STZ $09
7E/9C36: C2 20        REP #$20
7E/9C38: AD 16 42     LDA $4216
7E/9C3B: 65 08        ADC $08
7E/9C3D: 9F 00 81 7E  STA $7E8100,X
7E/9C41: 9F 02 81 7E  STA $7E8102,X
7E/9C45: A5 55        LDA $55
7E/9C47: 8D 02 42     STA $4202
7E/9C4A: E2 20        SEP #$20
7E/9C4C: A5 57        LDA $57
7E/9C4E: AC 17 42     LDY $4217
7E/9C51: 8D 03 42     STA $4203
7E/9C54: 84 08        STY $08
7E/9C56: 64 09        STZ $09
7E/9C58: C2 20        REP #$20
7E/9C5A: AD 16 42     LDA $4216
7E/9C5D: 65 08        ADC $08
7E/9C5F: 9F 00 83 7E  STA $7E8300,X
7E/9C63: 9F 02 83 7E  STA $7E8302,X
7E/9C67: 45 C5        EOR $C5
7E/9C69: 1A           INC 
7E/9C6A: 9F 00 85 7E  STA $7E8500,X
7E/9C6E: 9F 02 85 7E  STA $7E8502,X
7E/9C72: E8           INX 
7E/9C73: E8           INX 
7E/9C74: E8           INX 
7E/9C75: E8           INX 
7E/9C76: C6 0E        DEC $0E
7E/9C78: F0 03        BEQ $9C7D
7E/9C7A: 82 92 FF     BRL $9C0F
7E/9C7D: E2 20        SEP #$20
7E/9C7F: 60           RTS 
7E/9C80: 10 03        BPL $9C85
7E/9C82: 82 76 00     BRL $9CFB
7E/9C85: C2 20        REP #$20
7E/9C87: A5 0A        LDA $0A
7E/9C89: 65 5A        ADC $5A
7E/9C8B: EB           XBA 
7E/9C8C: 8D 06 42     STA $4206
7E/9C8F: EB           XBA 
7E/9C90: 85 0A        STA $0A
7E/9C92: E2 20        SEP #$20
7E/9C94: A5 54        LDA $54
7E/9C96: 8D 02 42     STA $4202
7E/9C99: AC 14 42     LDY $4214
7E/9C9C: 98           TYA 
7E/9C9D: 8D 03 42     STA $4203
7E/9CA0: 84 56        STY $56
7E/9CA2: A5 57        LDA $57
7E/9CA4: AC 17 42     LDY $4217
7E/9CA7: 8D 03 42     STA $4203
7E/9CAA: 84 08        STY $08
7E/9CAC: 64 09        STZ $09
7E/9CAE: C2 20        REP #$20
7E/9CB0: AD 16 42     LDA $4216
7E/9CB3: 65 08        ADC $08
7E/9CB5: 45 C5        EOR $C5
7E/9CB7: 1A           INC 
7E/9CB8: 9F 00 81 7E  STA $7E8100,X
7E/9CBC: 9F 02 81 7E  STA $7E8102,X
7E/9CC0: A5 55        LDA $55
7E/9CC2: 8D 02 42     STA $4202
7E/9CC5: E2 20        SEP #$20
7E/9CC7: A5 57        LDA $57
7E/9CC9: AC 17 42     LDY $4217
7E/9CCC: 8D 03 42     STA $4203
7E/9CCF: 84 08        STY $08
7E/9CD1: 64 09        STZ $09
7E/9CD3: C2 20        REP #$20
7E/9CD5: AD 16 42     LDA $4216
7E/9CD8: 65 08        ADC $08
7E/9CDA: 9F 00 83 7E  STA $7E8300,X
7E/9CDE: 9F 02 83 7E  STA $7E8302,X
7E/9CE2: 45 C5        EOR $C5
7E/9CE4: 1A           INC 
7E/9CE5: 9F 00 85 7E  STA $7E8500,X
7E/9CE9: 9F 02 85 7E  STA $7E8502,X
7E/9CED: E8           INX 
7E/9CEE: E8           INX 
7E/9CEF: E8           INX 
7E/9CF0: E8           INX 
7E/9CF1: C6 0E        DEC $0E
7E/9CF3: F0 03        BEQ $9CF8
7E/9CF5: 82 8F FF     BRL $9C87
7E/9CF8: E2 20        SEP #$20
7E/9CFA: 60           RTS 
7E/9CFB: 29 7F        AND #$7F
7E/9CFD: F0 03        BEQ $9D02
7E/9CFF: 82 76 00     BRL $9D78
7E/9D02: C2 20        REP #$20
7E/9D04: A5 0A        LDA $0A
7E/9D06: 65 5A        ADC $5A
7E/9D08: EB           XBA 
7E/9D09: 8D 06 42     STA $4206
7E/9D0C: EB           XBA 
7E/9D0D: 85 0A        STA $0A
7E/9D0F: E2 20        SEP #$20
7E/9D11: A5 54        LDA $54
7E/9D13: 8D 02 42     STA $4202
7E/9D16: AC 14 42     LDY $4214
7E/9D19: 98           TYA 
7E/9D1A: 8D 03 42     STA $4203
7E/9D1D: 84 56        STY $56
7E/9D1F: A5 57        LDA $57
7E/9D21: AC 17 42     LDY $4217
7E/9D24: 8D 03 42     STA $4203
7E/9D27: 84 08        STY $08
7E/9D29: 64 09        STZ $09
7E/9D2B: C2 20        REP #$20
7E/9D2D: AD 16 42     LDA $4216
7E/9D30: 65 08        ADC $08
7E/9D32: 45 C5        EOR $C5
7E/9D34: 1A           INC 
7E/9D35: 9F 00 81 7E  STA $7E8100,X
7E/9D39: 9F 02 81 7E  STA $7E8102,X
7E/9D3D: A5 55        LDA $55
7E/9D3F: 8D 02 42     STA $4202
7E/9D42: E2 20        SEP #$20
7E/9D44: A5 57        LDA $57
7E/9D46: AC 17 42     LDY $4217
7E/9D49: 8D 03 42     STA $4203
7E/9D4C: 84 08        STY $08
7E/9D4E: 64 09        STZ $09
7E/9D50: C2 20        REP #$20
7E/9D52: AD 16 42     LDA $4216
7E/9D55: 65 08        ADC $08
7E/9D57: 9F 00 85 7E  STA $7E8500,X
7E/9D5B: 9F 02 85 7E  STA $7E8502,X
7E/9D5F: 45 C5        EOR $C5
7E/9D61: 1A           INC 
7E/9D62: 9F 00 83 7E  STA $7E8300,X
7E/9D66: 9F 02 83 7E  STA $7E8302,X
7E/9D6A: E8           INX 
7E/9D6B: E8           INX 
7E/9D6C: E8           INX 
7E/9D6D: E8           INX 
7E/9D6E: C6 0E        DEC $0E
7E/9D70: F0 03        BEQ $9D75
7E/9D72: 82 8F FF     BRL $9D04
7E/9D75: E2 20        SEP #$20
7E/9D77: 60           RTS 
7E/9D78: C2 20        REP #$20
7E/9D7A: A5 0A        LDA $0A
7E/9D7C: 65 5A        ADC $5A
7E/9D7E: EB           XBA 
7E/9D7F: 8D 06 42     STA $4206
7E/9D82: EB           XBA 
7E/9D83: 85 0A        STA $0A
7E/9D85: E2 20        SEP #$20
7E/9D87: A5 54        LDA $54
7E/9D89: 8D 02 42     STA $4202
7E/9D8C: AC 14 42     LDY $4214
7E/9D8F: 98           TYA 
7E/9D90: 8D 03 42     STA $4203
7E/9D93: 84 56        STY $56
7E/9D95: A5 57        LDA $57
7E/9D97: AC 17 42     LDY $4217
7E/9D9A: 8D 03 42     STA $4203
7E/9D9D: 84 08        STY $08
7E/9D9F: 64 09        STZ $09
7E/9DA1: C2 20        REP #$20
7E/9DA3: AD 16 42     LDA $4216
7E/9DA6: 65 08        ADC $08
7E/9DA8: 9F 00 81 7E  STA $7E8100,X
7E/9DAC: 9F 02 81 7E  STA $7E8102,X
7E/9DB0: A5 55        LDA $55
7E/9DB2: 8D 02 42     STA $4202
7E/9DB5: E2 20        SEP #$20
7E/9DB7: A5 57        LDA $57
7E/9DB9: AC 17 42     LDY $4217
7E/9DBC: 8D 03 42     STA $4203
7E/9DBF: 84 08        STY $08
7E/9DC1: 64 09        STZ $09
7E/9DC3: C2 20        REP #$20
7E/9DC5: AD 16 42     LDA $4216
7E/9DC8: 65 08        ADC $08
7E/9DCA: 9F 00 85 7E  STA $7E8500,X
7E/9DCE: 9F 02 85 7E  STA $7E8502,X
7E/9DD2: 45 C5        EOR $C5
7E/9DD4: 1A           INC 
7E/9DD5: 9F 00 83 7E  STA $7E8300,X
7E/9DD9: 9F 02 83 7E  STA $7E8302,X
7E/9DDD: E8           INX 
7E/9DDE: E8           INX 
7E/9DDF: E8           INX 
7E/9DE0: E8           INX 
7E/9DE1: C6 0E        DEC $0E
7E/9DE3: F0 03        BEQ $9DE8
7E/9DE5: 82 92 FF     BRL $9D7A
7E/9DE8: E2 20        SEP #$20
7E/9DEA: 60           RTS 
7E/9DEB: A9 3F        LDA #$3F
7E/9DED: 04 40        TSB $40
7E/9DEF: A9 42        LDA #$42
7E/9DF1: 8D 00 43     STA $4300
7E/9DF4: 8D 10 43     STA $4310
7E/9DF7: 8D 20 43     STA $4320
7E/9DFA: 8D 30 43     STA $4330
7E/9DFD: 8D 50 43     STA $4350
7E/9E00: A9 40        LDA #$40
7E/9E02: 8D 40 43     STA $4340
7E/9E05: 8D 60 43     STA $4360
7E/9E08: A9 1B        LDA #$1B
7E/9E0A: 8D 01 43     STA $4301
7E/9E0D: A9 1E        LDA #$1E
7E/9E0F: 8D 11 43     STA $4311
7E/9E12: A9 1C        LDA #$1C
7E/9E14: 8D 21 43     STA $4321
7E/9E17: A9 1D        LDA #$1D
7E/9E19: 8D 31 43     STA $4331
7E/9E1C: A9 21        LDA #$21
7E/9E1E: 8D 41 43     STA $4341
7E/9E21: A9 22        LDA #$22
7E/9E23: 8D 51 43     STA $4351
7E/9E26: A2 00 80     LDX #$8000
7E/9E29: 8E 02 43     STX $4302
7E/9E2C: 8E 12 43     STX $4312
7E/9E2F: A2 06 80     LDX #$8006
7E/9E32: 8E 22 43     STX $4322
7E/9E35: A2 0C 80     LDX #$800C
7E/9E38: 8E 32 43     STX $4332
7E/9E3B: A2 12 80     LDX #$8012
7E/9E3E: 8E 42 43     STX $4342
7E/9E41: A2 18 80     LDX #$8018
7E/9E44: 8E 52 43     STX $4352
7E/9E47: A9 7E        LDA #$7E
7E/9E49: 8D 04 43     STA $4304
7E/9E4C: 8D 14 43     STA $4314
7E/9E4F: 8D 24 43     STA $4324
7E/9E52: 8D 34 43     STA $4334
7E/9E55: 8D 44 43     STA $4344
7E/9E58: 8D 54 43     STA $4354
7E/9E5B: 8D 07 43     STA $4307
7E/9E5E: 8D 17 43     STA $4317
7E/9E61: 8D 27 43     STA $4327
7E/9E64: 8D 37 43     STA $4337
7E/9E67: 8D 47 43     STA $4347
7E/9E6A: 8D 57 43     STA $4357
7E/9E6D: A9 FF        LDA #$FF
7E/9E6F: 8F 00 80 7E  STA $7E8000
7E/9E73: 8F 06 80 7E  STA $7E8006
7E/9E77: 8F 0C 80 7E  STA $7E800C
7E/9E7B: 8F 12 80 7E  STA $7E8012
7E/9E7F: 8F 18 80 7E  STA $7E8018
7E/9E83: 8F 1E 80 7E  STA $7E801E
7E/9E87: A9 E2        LDA #$E2
7E/9E89: 8F 03 80 7E  STA $7E8003
7E/9E8D: 8F 09 80 7E  STA $7E8009
7E/9E91: 8F 0F 80 7E  STA $7E800F
7E/9E95: 8F 15 80 7E  STA $7E8015
7E/9E99: 8F 1B 80 7E  STA $7E801B
7E/9E9D: C2 20        REP #$20
7E/9E9F: A9 00 81     LDA #$8100
7E/9EA2: 8F 01 80 7E  STA $7E8001
7E/9EA6: A9 00 82     LDA #$8200
7E/9EA9: 8F 04 80 7E  STA $7E8004
7E/9EAD: A9 00 83     LDA #$8300
7E/9EB0: 8F 07 80 7E  STA $7E8007
7E/9EB4: A9 00 84     LDA #$8400
7E/9EB7: 8F 0A 80 7E  STA $7E800A
7E/9EBB: A9 00 85     LDA #$8500
7E/9EBE: 8F 0D 80 7E  STA $7E800D
7E/9EC2: A9 00 86     LDA #$8600
7E/9EC5: 8F 10 80 7E  STA $7E8010
7E/9EC9: A9 00 87     LDA #$8700
7E/9ECC: 8F 13 80 7E  STA $7E8013
7E/9ED0: A9 80 87     LDA #$8780
7E/9ED3: 8F 16 80 7E  STA $7E8016
7E/9ED7: A9 00 88     LDA #$8800
7E/9EDA: 8F 19 80 7E  STA $7E8019
7E/9EDE: A9 00 89     LDA #$8900
7E/9EE1: 8F 1C 80 7E  STA $7E801C
7E/9EE5: A6 C7        LDX $C7
7E/9EE7: 8A           TXA 
7E/9EE8: 9F 00 87 7E  STA $7E8700,X
7E/9EEC: E8           INX 
7E/9EED: E8           INX 
7E/9EEE: E0 00 01     CPX #$0100
7E/9EF1: D0 F5        BNE $9EE8
7E/9EF3: A6 C7        LDX $C7
7E/9EF5: A5 C7        LDA $C7
7E/9EF7: 9F 00 83 7E  STA $7E8300,X
7E/9EFB: 9F 00 85 7E  STA $7E8500,X
7E/9EFF: E8           INX 
7E/9F00: E8           INX 
7E/9F01: E0 00 02     CPX #$0200
7E/9F04: D0 F1        BNE $9EF7
7E/9F06: A6 C7        LDX $C7
7E/9F08: AF 80 E0 7E  LDA $7EE080
7E/9F0C: 9F 00 88 7E  STA $7E8800,X
7E/9F10: E8           INX 
7E/9F11: E8           INX 
7E/9F12: E0 00 02     CPX #$0200
7E/9F15: D0 F5        BNE $9F0C
7E/9F17: A6 C7        LDX $C7
7E/9F19: A9 00 01     LDA #$0100
7E/9F1C: 9F 00 81 7E  STA $7E8100,X
7E/9F20: E8           INX 
7E/9F21: E8           INX 
7E/9F22: E0 00 02     CPX #$0200
7E/9F25: D0 F5        BNE $9F1C
7E/9F27: 64 38        STZ $38
7E/9F29: E2 20        SEP #$20
7E/9F2B: 60           RTS 
7E/9F2C: A6 52        LDX $52
7E/9F2E: E0 0E 01     CPX #$010E
7E/9F31: B0 3E        BCS $9F71
7E/9F33: E0 B4 00     CPX #$00B4
7E/9F36: B0 27        BCS $9F5F
7E/9F38: E0 5A 00     CPX #$005A
7E/9F3B: B0 10        BCS $9F4D
7E/9F3D: BF 00 C0 7E  LDA $7EC000,X
7E/9F41: 85 55        STA $55
7E/9F43: BF 5A C0 7E  LDA $7EC05A,X
7E/9F47: 85 54        STA $54
7E/9F49: 64 50        STZ $50
7E/9F4B: 80 34        BRA $9F81
7E/9F4D: BF 00 C0 7E  LDA $7EC000,X
7E/9F51: 85 55        STA $55
7E/9F53: BF A6 BF 7E  LDA $7EBFA6,X
7E/9F57: 85 54        STA $54
7E/9F59: A9 01        LDA #$01
7E/9F5B: 85 50        STA $50
7E/9F5D: 80 22        BRA $9F81
7E/9F5F: BF 4C BF 7E  LDA $7EBF4C,X
7E/9F63: 85 55        STA $55
7E/9F65: BF A6 BF 7E  LDA $7EBFA6,X
7E/9F69: 85 54        STA $54
7E/9F6B: A9 80        LDA #$80
7E/9F6D: 85 50        STA $50
7E/9F6F: 80 10        BRA $9F81
7E/9F71: BF 4C BF 7E  LDA $7EBF4C,X
7E/9F75: 85 55        STA $55
7E/9F77: BF F2 BE 7E  LDA $7EBEF2,X
7E/9F7B: 85 54        STA $54
7E/9F7D: A9 81        LDA #$81
7E/9F7F: 85 50        STA $50
7E/9F81: C2 20        REP #$20
7E/9F83: A5 5E        LDA $5E
7E/9F85: 38           SEC 
7E/9F86: E5 5C        SBC $5C
7E/9F88: 8D 04 42     STA $4204
7E/9F8B: A0 71 00     LDY #$0071
7E/9F8E: 8C 06 42     STY $4206
7E/9F91: A9 E1 00     LDA #$00E1
7E/9F94: 38           SEC 
7E/9F95: E5 38        SBC $38
7E/9F97: 4A           LSR 
7E/9F98: 1A           INC 
7E/9F99: 85 0E        STA $0E
7E/9F9B: A5 38        LDA $38
7E/9F9D: 0A           ASL 
7E/9F9E: AA           TAX 
7E/9F9F: A5 5C        LDA $5C
7E/9FA1: 85 0A        STA $0A
7E/9FA3: AD 14 42     LDA $4214
7E/9FA6: 85 5A        STA $5A
7E/9FA8: A5 58        LDA $58
7E/9FAA: 8D 04 42     STA $4204
7E/9FAD: E2 20        SEP #$20
7E/9FAF: A5 50        LDA $50
7E/9FB1: F0 03        BEQ $9FB6
7E/9FB3: 82 9F 00     BRL $A055
7E/9FB6: C2 20        REP #$20
7E/9FB8: A5 0A        LDA $0A
7E/9FBA: 65 5A        ADC $5A
7E/9FBC: EB           XBA 
7E/9FBD: 8D 06 42     STA $4206
7E/9FC0: EB           XBA 
7E/9FC1: 85 0A        STA $0A
7E/9FC3: E2 20        SEP #$20
7E/9FC5: A5 54        LDA $54
7E/9FC7: 8D 02 42     STA $4202
7E/9FCA: AC 14 42     LDY $4214
7E/9FCD: 98           TYA 
7E/9FCE: 8D 03 42     STA $4203
7E/9FD1: 84 56        STY $56
7E/9FD3: A5 57        LDA $57
7E/9FD5: AC 17 42     LDY $4217
7E/9FD8: 8D 03 42     STA $4203
7E/9FDB: 84 08        STY $08
7E/9FDD: 64 09        STZ $09
7E/9FDF: C2 20        REP #$20
7E/9FE1: AD 16 42     LDA $4216
7E/9FE4: 65 08        ADC $08
7E/9FE6: 9F 00 81 7E  STA $7E8100,X
7E/9FEA: 9F 02 81 7E  STA $7E8102,X
7E/9FEE: A5 55        LDA $55
7E/9FF0: 8D 02 42     STA $4202
7E/9FF3: E2 20        SEP #$20
7E/9FF5: A5 57        LDA $57
7E/9FF7: AC 17 42     LDY $4217
7E/9FFA: 8D 03 42     STA $4203
7E/9FFD: 84 08        STY $08
7E/9FFF: 64 09        STZ $09
7E/A001: C2 20        REP #$20
7E/A003: AD 16 42     LDA $4216
7E/A006: 65 08        ADC $08
7E/A008: 9F 00 83 7E  STA $7E8300,X
7E/A00C: 9F 02 83 7E  STA $7E8302,X
7E/A010: 45 C5        EOR $C5
7E/A012: 1A           INC 
7E/A013: 9F 00 85 7E  STA $7E8500,X
7E/A017: 9F 02 85 7E  STA $7E8502,X
7E/A01B: DA           PHX 
7E/A01C: A5 56        LDA $56
7E/A01E: 4A           LSR 
7E/A01F: 4A           LSR 
7E/A020: E2 20        SEP #$20
7E/A022: 8D 02 42     STA $4202
7E/A025: 8D 03 42     STA $4203
7E/A028: C2 20        REP #$20
7E/A02A: EA           NOP 
7E/A02B: EA           NOP 
7E/A02C: AD 16 42     LDA $4216
7E/A02F: 4A           LSR 
7E/A030: 4A           LSR 
7E/A031: EB           XBA 
7E/A032: 25 C6        AND $C6
7E/A034: 0A           ASL 
7E/A035: 0A           ASL 
7E/A036: 0A           ASL 
7E/A037: 0A           ASL 
7E/A038: 0A           ASL 
7E/A039: AA           TAX 
7E/A03A: BF 00 E0 7E  LDA $7EE000,X
7E/A03E: FA           PLX 
7E/A03F: 9F 00 88 7E  STA $7E8800,X
7E/A043: 9F 02 88 7E  STA $7E8802,X
7E/A047: E8           INX 
7E/A048: E8           INX 
7E/A049: E8           INX 
7E/A04A: E8           INX 
7E/A04B: C6 0E        DEC $0E
7E/A04D: F0 03        BEQ $A052
7E/A04F: 82 66 FF     BRL $9FB8
7E/A052: E2 20        SEP #$20
7E/A054: 60           RTS 
7E/A055: 10 03        BPL $A05A
7E/A057: 82 A2 00     BRL $A0FC
7E/A05A: C2 20        REP #$20
7E/A05C: A5 0A        LDA $0A
7E/A05E: 65 5A        ADC $5A
7E/A060: EB           XBA 
7E/A061: 8D 06 42     STA $4206
7E/A064: EB           XBA 
7E/A065: 85 0A        STA $0A
7E/A067: E2 20        SEP #$20
7E/A069: A5 54        LDA $54
7E/A06B: 8D 02 42     STA $4202
7E/A06E: AC 14 42     LDY $4214
7E/A071: 98           TYA 
7E/A072: 8D 03 42     STA $4203
7E/A075: 84 56        STY $56
7E/A077: A5 57        LDA $57
7E/A079: AC 17 42     LDY $4217
7E/A07C: 8D 03 42     STA $4203
7E/A07F: 84 08        STY $08
7E/A081: 64 09        STZ $09
7E/A083: C2 20        REP #$20
7E/A085: AD 16 42     LDA $4216
7E/A088: 65 08        ADC $08
7E/A08A: 45 C5        EOR $C5
7E/A08C: 1A           INC 
7E/A08D: 9F 00 81 7E  STA $7E8100,X
7E/A091: 9F 02 81 7E  STA $7E8102,X
7E/A095: A5 55        LDA $55
7E/A097: 8D 02 42     STA $4202
7E/A09A: E2 20        SEP #$20
7E/A09C: A5 57        LDA $57
7E/A09E: AC 17 42     LDY $4217
7E/A0A1: 8D 03 42     STA $4203
7E/A0A4: 84 08        STY $08
7E/A0A6: 64 09        STZ $09
7E/A0A8: C2 20        REP #$20
7E/A0AA: AD 16 42     LDA $4216
7E/A0AD: 65 08        ADC $08
7E/A0AF: 9F 00 83 7E  STA $7E8300,X
7E/A0B3: 9F 02 83 7E  STA $7E8302,X
7E/A0B7: 45 C5        EOR $C5
7E/A0B9: 1A           INC 
7E/A0BA: 9F 00 85 7E  STA $7E8500,X
7E/A0BE: 9F 02 85 7E  STA $7E8502,X
7E/A0C2: DA           PHX 
7E/A0C3: A5 56        LDA $56
7E/A0C5: 4A           LSR 
7E/A0C6: 4A           LSR 
7E/A0C7: E2 20        SEP #$20
7E/A0C9: 8D 02 42     STA $4202
7E/A0CC: 8D 03 42     STA $4203
7E/A0CF: C2 20        REP #$20
7E/A0D1: EA           NOP 
7E/A0D2: EA           NOP 
7E/A0D3: AD 16 42     LDA $4216
7E/A0D6: 4A           LSR 
7E/A0D7: 4A           LSR 
7E/A0D8: EB           XBA 
7E/A0D9: 25 C6        AND $C6
7E/A0DB: 0A           ASL 
7E/A0DC: 0A           ASL 
7E/A0DD: 0A           ASL 
7E/A0DE: 0A           ASL 
7E/A0DF: 0A           ASL 
7E/A0E0: AA           TAX 
7E/A0E1: BF 00 E0 7E  LDA $7EE000,X
7E/A0E5: FA           PLX 
7E/A0E6: 9F 00 88 7E  STA $7E8800,X
7E/A0EA: 9F 02 88 7E  STA $7E8802,X
7E/A0EE: E8           INX 
7E/A0EF: E8           INX 
7E/A0F0: E8           INX 
7E/A0F1: E8           INX 
7E/A0F2: C6 0E        DEC $0E
7E/A0F4: F0 03        BEQ $A0F9
7E/A0F6: 82 63 FF     BRL $A05C
7E/A0F9: E2 20        SEP #$20
7E/A0FB: 60           RTS 
7E/A0FC: 29 7F        AND #$7F
7E/A0FE: F0 03        BEQ $A103
7E/A100: 82 A2 00     BRL $A1A5
7E/A103: C2 20        REP #$20
7E/A105: A5 0A        LDA $0A
7E/A107: 65 5A        ADC $5A
7E/A109: EB           XBA 
7E/A10A: 8D 06 42     STA $4206
7E/A10D: EB           XBA 
7E/A10E: 85 0A        STA $0A
7E/A110: E2 20        SEP #$20
7E/A112: A5 54        LDA $54
7E/A114: 8D 02 42     STA $4202
7E/A117: AC 14 42     LDY $4214
7E/A11A: 98           TYA 
7E/A11B: 8D 03 42     STA $4203
7E/A11E: 84 56        STY $56
7E/A120: A5 57        LDA $57
7E/A122: AC 17 42     LDY $4217
7E/A125: 8D 03 42     STA $4203
7E/A128: 84 08        STY $08
7E/A12A: 64 09        STZ $09
7E/A12C: C2 20        REP #$20
7E/A12E: AD 16 42     LDA $4216
7E/A131: 65 08        ADC $08
7E/A133: 45 C5        EOR $C5
7E/A135: 1A           INC 
7E/A136: 9F 00 81 7E  STA $7E8100,X
7E/A13A: 9F 02 81 7E  STA $7E8102,X
7E/A13E: A5 55        LDA $55
7E/A140: 8D 02 42     STA $4202
7E/A143: E2 20        SEP #$20
7E/A145: A5 57        LDA $57
7E/A147: AC 17 42     LDY $4217
7E/A14A: 8D 03 42     STA $4203
7E/A14D: 84 08        STY $08
7E/A14F: 64 09        STZ $09
7E/A151: C2 20        REP #$20
7E/A153: AD 16 42     LDA $4216
7E/A156: 65 08        ADC $08
7E/A158: 9F 00 85 7E  STA $7E8500,X
7E/A15C: 9F 02 85 7E  STA $7E8502,X
7E/A160: 45 C5        EOR $C5
7E/A162: 1A           INC 
7E/A163: 9F 00 83 7E  STA $7E8300,X
7E/A167: 9F 02 83 7E  STA $7E8302,X
7E/A16B: DA           PHX 
7E/A16C: A5 56        LDA $56
7E/A16E: 4A           LSR 
7E/A16F: 4A           LSR 
7E/A170: E2 20        SEP #$20
7E/A172: 8D 02 42     STA $4202
7E/A175: 8D 03 42     STA $4203
7E/A178: C2 20        REP #$20
7E/A17A: EA           NOP 
7E/A17B: EA           NOP 
7E/A17C: AD 16 42     LDA $4216
7E/A17F: 4A           LSR 
7E/A180: 4A           LSR 
7E/A181: EB           XBA 
7E/A182: 25 C6        AND $C6
7E/A184: 0A           ASL 
7E/A185: 0A           ASL 
7E/A186: 0A           ASL 
7E/A187: 0A           ASL 
7E/A188: 0A           ASL 
7E/A189: AA           TAX 
7E/A18A: BF 00 E0 7E  LDA $7EE000,X
7E/A18E: FA           PLX 
7E/A18F: 9F 00 88 7E  STA $7E8800,X
7E/A193: 9F 02 88 7E  STA $7E8802,X
7E/A197: E8           INX 
7E/A198: E8           INX 
7E/A199: E8           INX 
7E/A19A: E8           INX 
7E/A19B: C6 0E        DEC $0E
7E/A19D: F0 03        BEQ $A1A2
7E/A19F: 82 63 FF     BRL $A105
7E/A1A2: E2 20        SEP #$20
7E/A1A4: 60           RTS 
7E/A1A5: C2 20        REP #$20
7E/A1A7: A5 0A        LDA $0A
7E/A1A9: 65 5A        ADC $5A
7E/A1AB: EB           XBA 
7E/A1AC: 8D 06 42     STA $4206
7E/A1AF: EB           XBA 
7E/A1B0: 85 0A        STA $0A
7E/A1B2: E2 20        SEP #$20
7E/A1B4: A5 54        LDA $54
7E/A1B6: 8D 02 42     STA $4202
7E/A1B9: AC 14 42     LDY $4214
7E/A1BC: 98           TYA 
7E/A1BD: 8D 03 42     STA $4203
7E/A1C0: 84 56        STY $56
7E/A1C2: A5 57        LDA $57
7E/A1C4: AC 17 42     LDY $4217
7E/A1C7: 8D 03 42     STA $4203
7E/A1CA: 84 08        STY $08
7E/A1CC: 64 09        STZ $09
7E/A1CE: C2 20        REP #$20
7E/A1D0: AD 16 42     LDA $4216
7E/A1D3: 65 08        ADC $08
7E/A1D5: 9F 00 81 7E  STA $7E8100,X
7E/A1D9: 9F 02 81 7E  STA $7E8102,X
7E/A1DD: A5 55        LDA $55
7E/A1DF: 8D 02 42     STA $4202
7E/A1E2: E2 20        SEP #$20
7E/A1E4: A5 57        LDA $57
7E/A1E6: AC 17 42     LDY $4217
7E/A1E9: 8D 03 42     STA $4203
7E/A1EC: 84 08        STY $08
7E/A1EE: 64 09        STZ $09
7E/A1F0: C2 20        REP #$20
7E/A1F2: AD 16 42     LDA $4216
7E/A1F5: 65 08        ADC $08
7E/A1F7: 9F 00 85 7E  STA $7E8500,X
7E/A1FB: 9F 02 85 7E  STA $7E8502,X
7E/A1FF: 45 C5        EOR $C5
7E/A201: 1A           INC 
7E/A202: 9F 00 83 7E  STA $7E8300,X
7E/A206: 9F 02 83 7E  STA $7E8302,X
7E/A20A: DA           PHX 
7E/A20B: A5 56        LDA $56
7E/A20D: 4A           LSR 
7E/A20E: 4A           LSR 
7E/A20F: E2 20        SEP #$20
7E/A211: 8D 02 42     STA $4202
7E/A214: 8D 03 42     STA $4203
7E/A217: C2 20        REP #$20
7E/A219: EA           NOP 
7E/A21A: EA           NOP 
7E/A21B: AD 16 42     LDA $4216
7E/A21E: 4A           LSR 
7E/A21F: 4A           LSR 
7E/A220: EB           XBA 
7E/A221: 25 C6        AND $C6
7E/A223: 0A           ASL 
7E/A224: 0A           ASL 
7E/A225: 0A           ASL 
7E/A226: 0A           ASL 
7E/A227: 0A           ASL 
7E/A228: AA           TAX 
7E/A229: BF 00 E0 7E  LDA $7EE000,X
7E/A22D: FA           PLX 
7E/A22E: 9F 00 88 7E  STA $7E8800,X
7E/A232: 9F 02 88 7E  STA $7E8802,X
7E/A236: E8           INX 
7E/A237: E8           INX 
7E/A238: E8           INX 
7E/A239: E8           INX 
7E/A23A: C6 0E        DEC $0E
7E/A23C: F0 03        BEQ $A241
7E/A23E: 82 66 FF     BRL $A1A7
7E/A241: E2 20        SEP #$20
7E/A243: 60           RTS 
7E/A244: A9 60        LDA #$60
7E/A246: 85 40        STA $40
7E/A248: A9 40        LDA #$40
7E/A24A: 8D 50 43     STA $4350
7E/A24D: A9 42        LDA #$42
7E/A24F: 8D 60 43     STA $4360
7E/A252: A9 21        LDA #$21
7E/A254: 8D 51 43     STA $4351
7E/A257: A9 22        LDA #$22
7E/A259: 8D 61 43     STA $4361
7E/A25C: A2 80 80     LDX #$8080
7E/A25F: 8E 52 43     STX $4352
7E/A262: A2 86 80     LDX #$8086
7E/A265: 8E 62 43     STX $4362
7E/A268: A9 7E        LDA #$7E
7E/A26A: 8D 54 43     STA $4354
7E/A26D: 8D 64 43     STA $4364
7E/A270: 8D 57 43     STA $4357
7E/A273: 8D 67 43     STA $4367
7E/A276: A9 FF        LDA #$FF
7E/A278: 8F 80 80 7E  STA $7E8080
7E/A27C: 8F 86 80 7E  STA $7E8086
7E/A280: A9 E2        LDA #$E2
7E/A282: 8F 83 80 7E  STA $7E8083
7E/A286: 8F 89 80 7E  STA $7E8089
7E/A28A: C2 20        REP #$20
7E/A28C: A9 00 89     LDA #$8900
7E/A28F: 8F 81 80 7E  STA $7E8081
7E/A293: A9 80 89     LDA #$8980
7E/A296: 8F 84 80 7E  STA $7E8084
7E/A29A: A9 00 8A     LDA #$8A00
7E/A29D: 8F 87 80 7E  STA $7E8087
7E/A2A1: A9 00 8B     LDA #$8B00
7E/A2A4: 8F 8A 80 7E  STA $7E808A
7E/A2A8: A6 C7        LDX $C7
7E/A2AA: A5 C7        LDA $C7
7E/A2AC: 9F 00 89 7E  STA $7E8900,X
7E/A2B0: E8           INX 
7E/A2B1: E8           INX 
7E/A2B2: E0 00 01     CPX #$0100
7E/A2B5: D0 F5        BNE $A2AC
7E/A2B7: A2 CA 00     LDX #$00CA
7E/A2BA: 86 1C        STX $1C
7E/A2BC: A6 C7        LDX $C7
7E/A2BE: AF 30 F1 7F  LDA $7FF130
7E/A2C2: 9F 00 8A 7E  STA $7E8A00,X
7E/A2C6: E8           INX 
7E/A2C7: E8           INX 
7E/A2C8: E4 1C        CPX $1C
7E/A2CA: D0 F6        BNE $A2C2
7E/A2CC: AF 32 F1 7F  LDA $7FF132
7E/A2D0: 29 1F 7C     AND #$7C1F
7E/A2D3: 85 08        STA $08
7E/A2D5: AF 32 F1 7F  LDA $7FF132
7E/A2D9: 29 E0 03     AND #$03E0
7E/A2DC: 4A           LSR 
7E/A2DD: 4A           LSR 
7E/A2DE: 4A           LSR 
7E/A2DF: 4A           LSR 
7E/A2E0: 4A           LSR 
7E/A2E1: 85 0A        STA $0A
7E/A2E3: 0A           ASL 
7E/A2E4: 0A           ASL 
7E/A2E5: 0A           ASL 
7E/A2E6: 0A           ASL 
7E/A2E7: 0A           ASL 
7E/A2E8: 05 08        ORA $08
7E/A2EA: 9F 00 8A 7E  STA $7E8A00,X
7E/A2EE: E8           INX 
7E/A2EF: E8           INX 
7E/A2F0: 9F 00 8A 7E  STA $7E8A00,X
7E/A2F4: E8           INX 
7E/A2F5: E8           INX 
7E/A2F6: E6 0A        INC $0A
7E/A2F8: A5 0A        LDA $0A
7E/A2FA: 0A           ASL 
7E/A2FB: 0A           ASL 
7E/A2FC: 0A           ASL 
7E/A2FD: 0A           ASL 
7E/A2FE: 0A           ASL 
7E/A2FF: 05 08        ORA $08
7E/A301: 9F 00 8A 7E  STA $7E8A00,X
7E/A305: E8           INX 
7E/A306: E8           INX 
7E/A307: 9F 00 8A 7E  STA $7E8A00,X
7E/A30B: E8           INX 
7E/A30C: E8           INX 
7E/A30D: E6 0A        INC $0A
7E/A30F: A5 0A        LDA $0A
7E/A311: 0A           ASL 
7E/A312: 0A           ASL 
7E/A313: 0A           ASL 
7E/A314: 0A           ASL 
7E/A315: 0A           ASL 
7E/A316: 05 08        ORA $08
7E/A318: 9F 00 8A 7E  STA $7E8A00,X
7E/A31C: E8           INX 
7E/A31D: E8           INX 
7E/A31E: 9F 00 8A 7E  STA $7E8A00,X
7E/A322: E8           INX 
7E/A323: E8           INX 
7E/A324: 9F 00 8A 7E  STA $7E8A00,X
7E/A328: E8           INX 
7E/A329: E8           INX 
7E/A32A: 9F 00 8A 7E  STA $7E8A00,X
7E/A32E: E8           INX 
7E/A32F: E8           INX 
7E/A330: A5 1C        LDA $1C
7E/A332: 18           CLC 
7E/A333: 69 18 00     ADC #$0018
7E/A336: 85 1C        STA $1C
7E/A338: E6 0A        INC $0A
7E/A33A: A5 0A        LDA $0A
7E/A33C: 0A           ASL 
7E/A33D: 0A           ASL 
7E/A33E: 0A           ASL 
7E/A33F: 0A           ASL 
7E/A340: 0A           ASL 
7E/A341: 05 08        ORA $08
7E/A343: 9F 00 8A 7E  STA $7E8A00,X
7E/A347: E8           INX 
7E/A348: E8           INX 
7E/A349: E4 1C        CPX $1C
7E/A34B: D0 F6        BNE $A343
7E/A34D: A5 1C        LDA $1C
7E/A34F: 18           CLC 
7E/A350: 69 08 00     ADC #$0008
7E/A353: 85 1C        STA $1C
7E/A355: E6 0A        INC $0A
7E/A357: A5 0A        LDA $0A
7E/A359: 0A           ASL 
7E/A35A: 0A           ASL 
7E/A35B: 0A           ASL 
7E/A35C: 0A           ASL 
7E/A35D: 0A           ASL 
7E/A35E: 05 08        ORA $08
7E/A360: 9F 00 8A 7E  STA $7E8A00,X
7E/A364: E8           INX 
7E/A365: E8           INX 
7E/A366: E4 1C        CPX $1C
7E/A368: D0 F6        BNE $A360
7E/A36A: A5 1C        LDA $1C
7E/A36C: 18           CLC 
7E/A36D: 69 08 00     ADC #$0008
7E/A370: 85 1C        STA $1C
7E/A372: E6 0A        INC $0A
7E/A374: A5 0A        LDA $0A
7E/A376: 0A           ASL 
7E/A377: 0A           ASL 
7E/A378: 0A           ASL 
7E/A379: 0A           ASL 
7E/A37A: 0A           ASL 
7E/A37B: 05 08        ORA $08
7E/A37D: 9F 00 8A 7E  STA $7E8A00,X
7E/A381: E8           INX 
7E/A382: E8           INX 
7E/A383: E4 1C        CPX $1C
7E/A385: D0 F6        BNE $A37D
7E/A387: E6 0A        INC $0A
7E/A389: A5 0A        LDA $0A
7E/A38B: 0A           ASL 
7E/A38C: 0A           ASL 
7E/A38D: 0A           ASL 
7E/A38E: 0A           ASL 
7E/A38F: 0A           ASL 
7E/A390: 05 08        ORA $08
7E/A392: 9F 00 8A 7E  STA $7E8A00,X
7E/A396: E8           INX 
7E/A397: E8           INX 
7E/A398: E0 00 02     CPX #$0200
7E/A39B: D0 F5        BNE $A392
7E/A39D: E2 20        SEP #$20
7E/A39F: 60           RTS 
7E/A3A0: C2 20        REP #$20
7E/A3A2: A6 C7        LDX $C7
7E/A3A4: AF 30 F1 7F  LDA $7FF130
7E/A3A8: 9F 00 8A 7E  STA $7E8A00,X
7E/A3AC: E8           INX 
7E/A3AD: E8           INX 
7E/A3AE: E0 00 02     CPX #$0200
7E/A3B1: D0 F5        BNE $A3A8
7E/A3B3: E2 20        SEP #$20
7E/A3B5: 60           RTS 
7E/A3B6: A9 60        LDA #$60
7E/A3B8: 04 40        TSB $40
7E/A3BA: A9 40        LDA #$40
7E/A3BC: 8D 50 43     STA $4350
7E/A3BF: A9 42        LDA #$42
7E/A3C1: 8D 60 43     STA $4360
7E/A3C4: A9 21        LDA #$21
7E/A3C6: 8D 51 43     STA $4351
7E/A3C9: A9 22        LDA #$22
7E/A3CB: 8D 61 43     STA $4361
7E/A3CE: A2 80 80     LDX #$8080
7E/A3D1: 8E 52 43     STX $4352
7E/A3D4: A2 86 80     LDX #$8086
7E/A3D7: 8E 62 43     STX $4362
7E/A3DA: A9 7E        LDA #$7E
7E/A3DC: 8D 54 43     STA $4354
7E/A3DF: 8D 64 43     STA $4364
7E/A3E2: 8D 57 43     STA $4357
7E/A3E5: 8D 67 43     STA $4367
7E/A3E8: A9 FF        LDA #$FF
7E/A3EA: 8F 80 80 7E  STA $7E8080
7E/A3EE: 8F 86 80 7E  STA $7E8086
7E/A3F2: A9 E2        LDA #$E2
7E/A3F4: 8F 83 80 7E  STA $7E8083
7E/A3F8: 8F 89 80 7E  STA $7E8089
7E/A3FC: C2 20        REP #$20
7E/A3FE: A9 00 89     LDA #$8900
7E/A401: 8F 81 80 7E  STA $7E8081
7E/A405: A9 80 89     LDA #$8980
7E/A408: 8F 84 80 7E  STA $7E8084
7E/A40C: A9 00 8A     LDA #$8A00
7E/A40F: 8F 87 80 7E  STA $7E8087
7E/A413: A9 00 8B     LDA #$8B00
7E/A416: 8F 8A 80 7E  STA $7E808A
7E/A41A: A6 C7        LDX $C7
7E/A41C: A5 C7        LDA $C7
7E/A41E: 9F 00 89 7E  STA $7E8900,X
7E/A422: E8           INX 
7E/A423: E8           INX 
7E/A424: E0 00 01     CPX #$0100
7E/A427: D0 F5        BNE $A41E
7E/A429: A6 C7        LDX $C7
7E/A42B: AF 30 F1 7F  LDA $7FF130
7E/A42F: 9F 00 8A 7E  STA $7E8A00,X
7E/A433: E8           INX 
7E/A434: E8           INX 
7E/A435: E0 F8 00     CPX #$00F8
7E/A438: D0 F5        BNE $A42F
7E/A43A: A9 00 3D     LDA #$3D00
7E/A43D: 29 1F 7C     AND #$7C1F
7E/A440: 85 08        STA $08
7E/A442: AF 32 F1 7F  LDA $7FF132
7E/A446: 29 E0 03     AND #$03E0
7E/A449: 4A           LSR 
7E/A44A: 4A           LSR 
7E/A44B: 4A           LSR 
7E/A44C: 4A           LSR 
7E/A44D: 4A           LSR 
7E/A44E: 85 0A        STA $0A
7E/A450: 0A           ASL 
7E/A451: 0A           ASL 
7E/A452: 0A           ASL 
7E/A453: 0A           ASL 
7E/A454: 0A           ASL 
7E/A455: 05 08        ORA $08
7E/A457: 9F 00 8A 7E  STA $7E8A00,X
7E/A45B: E8           INX 
7E/A45C: E8           INX 
7E/A45D: 9F 00 8A 7E  STA $7E8A00,X
7E/A461: E8           INX 
7E/A462: E8           INX 
7E/A463: E6 0A        INC $0A
7E/A465: A5 0A        LDA $0A
7E/A467: 0A           ASL 
7E/A468: 0A           ASL 
7E/A469: 0A           ASL 
7E/A46A: 0A           ASL 
7E/A46B: 0A           ASL 
7E/A46C: 05 08        ORA $08
7E/A46E: 9F 00 8A 7E  STA $7E8A00,X
7E/A472: E8           INX 
7E/A473: E8           INX 
7E/A474: 9F 00 8A 7E  STA $7E8A00,X
7E/A478: E8           INX 
7E/A479: E8           INX 
7E/A47A: E6 0A        INC $0A
7E/A47C: A5 0A        LDA $0A
7E/A47E: 0A           ASL 
7E/A47F: 0A           ASL 
7E/A480: 0A           ASL 
7E/A481: 0A           ASL 
7E/A482: 0A           ASL 
7E/A483: 05 08        ORA $08
7E/A485: 9F 00 8A 7E  STA $7E8A00,X
7E/A489: E8           INX 
7E/A48A: E8           INX 
7E/A48B: 9F 00 8A 7E  STA $7E8A00,X
7E/A48F: E8           INX 
7E/A490: E8           INX 
7E/A491: 9F 00 8A 7E  STA $7E8A00,X
7E/A495: E8           INX 
7E/A496: E8           INX 
7E/A497: 9F 00 8A 7E  STA $7E8A00,X
7E/A49B: E8           INX 
7E/A49C: E8           INX 
7E/A49D: E6 0A        INC $0A
7E/A49F: A5 0A        LDA $0A
7E/A4A1: 0A           ASL 
7E/A4A2: 0A           ASL 
7E/A4A3: 0A           ASL 
7E/A4A4: 0A           ASL 
7E/A4A5: 0A           ASL 
7E/A4A6: 05 08        ORA $08
7E/A4A8: 9F 00 8A 7E  STA $7E8A00,X
7E/A4AC: E8           INX 
7E/A4AD: E8           INX 
7E/A4AE: E0 10 01     CPX #$0110
7E/A4B1: D0 F5        BNE $A4A8
7E/A4B3: E6 0A        INC $0A
7E/A4B5: A5 0A        LDA $0A
7E/A4B7: 0A           ASL 
7E/A4B8: 0A           ASL 
7E/A4B9: 0A           ASL 
7E/A4BA: 0A           ASL 
7E/A4BB: 0A           ASL 
7E/A4BC: 05 08        ORA $08
7E/A4BE: 9F 00 8A 7E  STA $7E8A00,X
7E/A4C2: E8           INX 
7E/A4C3: E8           INX 
7E/A4C4: E0 18 01     CPX #$0118
7E/A4C7: D0 F5        BNE $A4BE
7E/A4C9: E6 0A        INC $0A
7E/A4CB: A5 0A        LDA $0A
7E/A4CD: 0A           ASL 
7E/A4CE: 0A           ASL 
7E/A4CF: 0A           ASL 
7E/A4D0: 0A           ASL 
7E/A4D1: 0A           ASL 
7E/A4D2: 05 08        ORA $08
7E/A4D4: 9F 00 8A 7E  STA $7E8A00,X
7E/A4D8: E8           INX 
7E/A4D9: E8           INX 
7E/A4DA: E0 20 01     CPX #$0120
7E/A4DD: D0 F5        BNE $A4D4
7E/A4DF: E6 0A        INC $0A
7E/A4E1: A5 0A        LDA $0A
7E/A4E3: 0A           ASL 
7E/A4E4: 0A           ASL 
7E/A4E5: 0A           ASL 
7E/A4E6: 0A           ASL 
7E/A4E7: 0A           ASL 
7E/A4E8: 05 08        ORA $08
7E/A4EA: 9F 00 8A 7E  STA $7E8A00,X
7E/A4EE: E8           INX 
7E/A4EF: E8           INX 
7E/A4F0: E0 28 01     CPX #$0128
7E/A4F3: D0 F5        BNE $A4EA
7E/A4F5: E6 0A        INC $0A
7E/A4F7: A5 0A        LDA $0A
7E/A4F9: 0A           ASL 
7E/A4FA: 0A           ASL 
7E/A4FB: 0A           ASL 
7E/A4FC: 0A           ASL 
7E/A4FD: 0A           ASL 
7E/A4FE: 05 08        ORA $08
7E/A500: 9F 00 8A 7E  STA $7E8A00,X
7E/A504: E8           INX 
7E/A505: E8           INX 
7E/A506: E0 00 02     CPX #$0200
7E/A509: D0 F5        BNE $A500
7E/A50B: E2 20        SEP #$20
7E/A50D: 60           RTS 
7E/A50E: A5 62        LDA $62
7E/A510: F0 0C        BEQ $A51E
7E/A512: C6 62        DEC $62
7E/A514: C6 62        DEC $62
7E/A516: C6 64        DEC $64
7E/A518: C6 64        DEC $64
7E/A51A: E6 60        INC $60
7E/A51C: E6 60        INC $60
7E/A51E: A5 64        LDA $64
7E/A520: F0 04        BEQ $A526
7E/A522: C6 64        DEC $64
7E/A524: C6 64        DEC $64
7E/A526: 60           RTS 
7E/A527: A5 44        LDA $44
7E/A529: 89 01        BIT #$01
7E/A52B: D0 0A        BNE $A537
7E/A52D: A6 32        LDX $32
7E/A52F: E0 CF 01     CPX #$01CF
7E/A532: F0 03        BEQ $A537
7E/A534: E8           INX 
7E/A535: 86 32        STX $32
7E/A537: 60           RTS 
7E/A538: A5 44        LDA $44
7E/A53A: 89 01        BIT #$01
7E/A53C: D0 F9        BNE $A537
7E/A53E: A6 32        LDX $32
7E/A540: E0 B8 01     CPX #$01B8
7E/A543: F0 03        BEQ $A548
7E/A545: CA           DEX 
7E/A546: 86 32        STX $32
7E/A548: 60           RTS 
7E/A549: A6 30        LDX $30
7E/A54B: E0 FF 01     CPX #$01FF
7E/A54E: F0 03        BEQ $A553
7E/A550: E8           INX 
7E/A551: 86 30        STX $30
7E/A553: 60           RTS 
7E/A554: A6 66        LDX $66
7E/A556: F0 04        BEQ $A55C
7E/A558: CA           DEX 
7E/A559: 86 66        STX $66
7E/A55B: 60           RTS 
7E/A55C: A2 1C 02     LDX #$021C
7E/A55F: 86 66        STX $66
7E/A561: 60           RTS 
7E/A562: A6 68        LDX $68
7E/A564: E0 00 01     CPX #$0100
7E/A567: F0 06        BEQ $A56F
7E/A569: E8           INX 
7E/A56A: E8           INX 
7E/A56B: E8           INX 
7E/A56C: E8           INX 
7E/A56D: 86 68        STX $68
7E/A56F: 60           RTS 
7E/A570: A9 7F        LDA #$7F
7E/A572: 04 40        TSB $40
7E/A574: A9 42        LDA #$42
7E/A576: 8D 10 43     STA $4310
7E/A579: 8D 20 43     STA $4320
7E/A57C: 8D 30 43     STA $4330
7E/A57F: A9 40        LDA #$40
7E/A581: 8D 00 43     STA $4300
7E/A584: 8D 40 43     STA $4340
7E/A587: 8D 50 43     STA $4350
7E/A58A: A9 42        LDA #$42
7E/A58C: 8D 60 43     STA $4360
7E/A58F: A9 31        LDA #$31
7E/A591: 8D 01 43     STA $4301
7E/A594: A9 1E        LDA #$1E
7E/A596: 8D 11 43     STA $4311
7E/A599: A9 0E        LDA #$0E
7E/A59B: 8D 21 43     STA $4321
7E/A59E: A9 0D        LDA #$0D
7E/A5A0: 8D 31 43     STA $4331
7E/A5A3: A9 1A        LDA #$1A
7E/A5A5: 8D 41 43     STA $4341
7E/A5A8: A9 21        LDA #$21
7E/A5AA: 8D 51 43     STA $4351
7E/A5AD: A9 22        LDA #$22
7E/A5AF: 8D 61 43     STA $4361
7E/A5B2: A2 00 80     LDX #$8000
7E/A5B5: 8E 02 43     STX $4302
7E/A5B8: A2 06 80     LDX #$8006
7E/A5BB: 8E 12 43     STX $4312
7E/A5BE: A2 0C 80     LDX #$800C
7E/A5C1: 8E 22 43     STX $4322
7E/A5C4: A2 12 80     LDX #$8012
7E/A5C7: 8E 32 43     STX $4332
7E/A5CA: A2 18 80     LDX #$8018
7E/A5CD: 8E 42 43     STX $4342
7E/A5D0: A2 1E 80     LDX #$801E
7E/A5D3: 8E 52 43     STX $4352
7E/A5D6: A2 24 80     LDX #$8024
7E/A5D9: 8E 62 43     STX $4362
7E/A5DC: A9 7E        LDA #$7E
7E/A5DE: 8D 04 43     STA $4304
7E/A5E1: 8D 14 43     STA $4314
7E/A5E4: 8D 24 43     STA $4324
7E/A5E7: 8D 34 43     STA $4334
7E/A5EA: 8D 44 43     STA $4344
7E/A5ED: 8D 54 43     STA $4354
7E/A5F0: 8D 64 43     STA $4364
7E/A5F3: 8D 07 43     STA $4307
7E/A5F6: 8D 17 43     STA $4317
7E/A5F9: 8D 27 43     STA $4327
7E/A5FC: 8D 37 43     STA $4337
7E/A5FF: 8D 47 43     STA $4347
7E/A602: 8D 57 43     STA $4357
7E/A605: 8D 67 43     STA $4367
7E/A608: A9 FF        LDA #$FF
7E/A60A: 8F 00 80 7E  STA $7E8000
7E/A60E: 8F 06 80 7E  STA $7E8006
7E/A612: 8F 0C 80 7E  STA $7E800C
7E/A616: 8F 12 80 7E  STA $7E8012
7E/A61A: 8F 18 80 7E  STA $7E8018
7E/A61E: 8F 1E 80 7E  STA $7E801E
7E/A622: 8F 24 80 7E  STA $7E8024
7E/A626: A9 E2        LDA #$E2
7E/A628: 8F 03 80 7E  STA $7E8003
7E/A62C: 8F 09 80 7E  STA $7E8009
7E/A630: 8F 0F 80 7E  STA $7E800F
7E/A634: 8F 15 80 7E  STA $7E8015
7E/A638: 8F 1B 80 7E  STA $7E801B
7E/A63C: 8F 21 80 7E  STA $7E8021
7E/A640: 8F 27 80 7E  STA $7E8027
7E/A644: C2 20        REP #$20
7E/A646: A9 00 81     LDA #$8100
7E/A649: 8F 01 80 7E  STA $7E8001
7E/A64D: A9 80 81     LDA #$8180
7E/A650: 8F 04 80 7E  STA $7E8004
7E/A654: A9 00 83     LDA #$8300
7E/A657: 8F 07 80 7E  STA $7E8007
7E/A65B: A9 00 84     LDA #$8400
7E/A65E: 8F 0A 80 7E  STA $7E800A
7E/A662: A9 00 85     LDA #$8500
7E/A665: 8F 0D 80 7E  STA $7E800D
7E/A669: A9 00 86     LDA #$8600
7E/A66C: 8F 10 80 7E  STA $7E8010
7E/A670: A9 00 87     LDA #$8700
7E/A673: 8F 13 80 7E  STA $7E8013
7E/A677: A9 00 88     LDA #$8800
7E/A67A: 8F 16 80 7E  STA $7E8016
7E/A67E: A9 00 89     LDA #$8900
7E/A681: 8F 19 80 7E  STA $7E8019
7E/A685: A9 80 89     LDA #$8980
7E/A688: 8F 1C 80 7E  STA $7E801C
7E/A68C: A9 00 8A     LDA #$8A00
7E/A68F: 8F 1F 80 7E  STA $7E801F
7E/A693: A9 80 8A     LDA #$8A80
7E/A696: 8F 22 80 7E  STA $7E8022
7E/A69A: A9 00 8B     LDA #$8B00
7E/A69D: 8F 25 80 7E  STA $7E8025
7E/A6A1: A9 00 8C     LDA #$8C00
7E/A6A4: 8F 28 80 7E  STA $7E8028
7E/A6A8: A6 C7        LDX $C7
7E/A6AA: 8A           TXA 
7E/A6AB: 9F 00 8A 7E  STA $7E8A00,X
7E/A6AF: E8           INX 
7E/A6B0: E8           INX 
7E/A6B1: E0 00 01     CPX #$0100
7E/A6B4: D0 F5        BNE $A6AB
7E/A6B6: A9 7E 00     LDA #$007E
7E/A6B9: 85 D5        STA $D5
7E/A6BB: A9 00 8B     LDA #$8B00
7E/A6BE: 85 D3        STA $D3
7E/A6C0: A5 C7        LDA $C7
7E/A6C2: A8           TAY 
7E/A6C3: 97 D3        STA [$D3],Y
7E/A6C5: C8           INY 
7E/A6C6: C8           INY 
7E/A6C7: C4 60        CPY $60
7E/A6C9: D0 F8        BNE $A6C3
7E/A6CB: A6 C7        LDX $C7
7E/A6CD: BF 80 C7 7F  LDA $7FC780,X
7E/A6D1: 97 D3        STA [$D3],Y
7E/A6D3: C8           INY 
7E/A6D4: C8           INY 
7E/A6D5: E4 62        CPX $62
7E/A6D7: F0 04        BEQ $A6DD
7E/A6D9: E8           INX 
7E/A6DA: E8           INX 
7E/A6DB: 80 F0        BRA $A6CD
7E/A6DD: A6 64        LDX $64
7E/A6DF: BF 80 C7 7F  LDA $7FC780,X
7E/A6E3: 97 D3        STA [$D3],Y
7E/A6E5: C8           INY 
7E/A6E6: C8           INY 
7E/A6E7: 97 D3        STA [$D3],Y
7E/A6E9: C8           INY 
7E/A6EA: C8           INY 
7E/A6EB: E4 C7        CPX $C7
7E/A6ED: F0 04        BEQ $A6F3
7E/A6EF: CA           DEX 
7E/A6F0: CA           DEX 
7E/A6F1: 80 EC        BRA $A6DF
7E/A6F3: A5 C7        LDA $C7
7E/A6F5: 97 D3        STA [$D3],Y
7E/A6F7: C8           INY 
7E/A6F8: C8           INY 
7E/A6F9: C0 00 02     CPY #$0200
7E/A6FC: D0 F7        BNE $A6F5
7E/A6FE: A6 C7        LDX $C7
7E/A700: A9 30 30     LDA #$3030
7E/A703: 9F 00 81 7E  STA $7E8100,X
7E/A707: E8           INX 
7E/A708: E8           INX 
7E/A709: E0 60 00     CPX #$0060
7E/A70C: D0 F5        BNE $A703
7E/A70E: A9 70 70     LDA #$7070
7E/A711: 9F 00 81 7E  STA $7E8100,X
7E/A715: E8           INX 
7E/A716: E8           INX 
7E/A717: E0 B0 00     CPX #$00B0
7E/A71A: D0 F5        BNE $A711
7E/A71C: A9 30 30     LDA #$3030
7E/A71F: 9F 00 81 7E  STA $7E8100,X
7E/A723: E8           INX 
7E/A724: E8           INX 
7E/A725: E0 00 02     CPX #$0200
7E/A728: D0 F5        BNE $A71F
7E/A72A: A6 C7        LDX $C7
7E/A72C: A9 C0 C0     LDA #$C0C0
7E/A72F: 9F 00 89 7E  STA $7E8900,X
7E/A733: E8           INX 
7E/A734: E8           INX 
7E/A735: E0 60 00     CPX #$0060
7E/A738: D0 F5        BNE $A72F
7E/A73A: A9 C2 C2     LDA #$C2C2
7E/A73D: 9F 00 89 7E  STA $7E8900,X
7E/A741: E8           INX 
7E/A742: E8           INX 
7E/A743: E0 00 01     CPX #$0100
7E/A746: D0 F5        BNE $A73D
7E/A748: A6 C7        LDX $C7
7E/A74A: A5 32        LDA $32
7E/A74C: 9F 00 85 7E  STA $7E8500,X
7E/A750: E8           INX 
7E/A751: E8           INX 
7E/A752: E0 C0 00     CPX #$00C0
7E/A755: D0 F5        BNE $A74C
7E/A757: 38           SEC 
7E/A758: E9 7A 00     SBC #$007A
7E/A75B: 9F 00 85 7E  STA $7E8500,X
7E/A75F: E8           INX 
7E/A760: E8           INX 
7E/A761: E0 00 02     CPX #$0200
7E/A764: D0 F5        BNE $A75B
7E/A766: A6 C7        LDX $C7
7E/A768: A5 30        LDA $30
7E/A76A: 9F 00 87 7E  STA $7E8700,X
7E/A76E: E8           INX 
7E/A76F: E8           INX 
7E/A770: E0 00 02     CPX #$0200
7E/A773: D0 F5        BNE $A76A
7E/A775: A6 C7        LDX $C7
7E/A777: A9 00 01     LDA #$0100
7E/A77A: 9F 00 83 7E  STA $7E8300,X
7E/A77E: E8           INX 
7E/A77F: E8           INX 
7E/A780: E0 C0 00     CPX #$00C0
7E/A783: D0 F5        BNE $A77A
7E/A785: 18           CLC 
7E/A786: 69 40 00     ADC #$0040
7E/A789: 9F 00 83 7E  STA $7E8300,X
7E/A78D: E8           INX 
7E/A78E: E8           INX 
7E/A78F: E0 00 02     CPX #$0200
7E/A792: D0 F5        BNE $A789
7E/A794: E2 20        SEP #$20
7E/A796: 60           RTS 
7E/A797: C2 20        REP #$20
7E/A799: A6 C7        LDX $C7
7E/A79B: 8A           TXA 
7E/A79C: 9F 00 8A 7E  STA $7E8A00,X
7E/A7A0: E8           INX 
7E/A7A1: E8           INX 
7E/A7A2: E0 00 01     CPX #$0100
7E/A7A5: D0 F5        BNE $A79C
7E/A7A7: A9 7E 00     LDA #$007E
7E/A7AA: 85 D5        STA $D5
7E/A7AC: A9 00 8B     LDA #$8B00
7E/A7AF: 85 D3        STA $D3
7E/A7B1: AF 30 F1 7F  LDA $7FF130
7E/A7B5: A4 C7        LDY $C7
7E/A7B7: 97 D3        STA [$D3],Y
7E/A7B9: C8           INY 
7E/A7BA: C8           INY 
7E/A7BB: C0 00 02     CPY #$0200
7E/A7BE: D0 F7        BNE $A7B7
7E/A7C0: A6 C7        LDX $C7
7E/A7C2: A9 30 30     LDA #$3030
7E/A7C5: 9F 00 81 7E  STA $7E8100,X
7E/A7C9: E8           INX 
7E/A7CA: E8           INX 
7E/A7CB: E0 00 02     CPX #$0200
7E/A7CE: D0 F5        BNE $A7C5
7E/A7D0: A6 C7        LDX $C7
7E/A7D2: A9 C0 C0     LDA #$C0C0
7E/A7D5: 9F 00 89 7E  STA $7E8900,X
7E/A7D9: E8           INX 
7E/A7DA: E8           INX 
7E/A7DB: E0 00 01     CPX #$0100
7E/A7DE: D0 F5        BNE $A7D5
7E/A7E0: A6 C7        LDX $C7
7E/A7E2: A5 32        LDA $32
7E/A7E4: 9F 00 85 7E  STA $7E8500,X
7E/A7E8: E8           INX 
7E/A7E9: E8           INX 
7E/A7EA: E0 00 02     CPX #$0200
7E/A7ED: D0 F5        BNE $A7E4
7E/A7EF: A6 C7        LDX $C7
7E/A7F1: A5 30        LDA $30
7E/A7F3: 9F 00 87 7E  STA $7E8700,X
7E/A7F7: E8           INX 
7E/A7F8: E8           INX 
7E/A7F9: E0 00 02     CPX #$0200
7E/A7FC: D0 F5        BNE $A7F3
7E/A7FE: A6 C7        LDX $C7
7E/A800: A9 00 01     LDA #$0100
7E/A803: 9F 00 83 7E  STA $7E8300,X
7E/A807: E8           INX 
7E/A808: E8           INX 
7E/A809: E0 00 02     CPX #$0200
7E/A80C: D0 F5        BNE $A803
7E/A80E: E2 20        SEP #$20
7E/A810: 60           RTS 
7E/A811: C2 20        REP #$20
7E/A813: A9 7E 00     LDA #$007E
7E/A816: 85 D5        STA $D5
7E/A818: A9 00 8B     LDA #$8B00
7E/A81B: 85 D3        STA $D3
7E/A81D: A5 C7        LDA $C7
7E/A81F: A8           TAY 
7E/A820: 97 D3        STA [$D3],Y
7E/A822: C8           INY 
7E/A823: C8           INY 
7E/A824: C4 60        CPY $60
7E/A826: D0 F8        BNE $A820
7E/A828: A6 C7        LDX $C7
7E/A82A: BF 80 C7 7F  LDA $7FC780,X
7E/A82E: 97 D3        STA [$D3],Y
7E/A830: C8           INY 
7E/A831: C8           INY 
7E/A832: E4 62        CPX $62
7E/A834: F0 04        BEQ $A83A
7E/A836: E8           INX 
7E/A837: E8           INX 
7E/A838: 80 F0        BRA $A82A
7E/A83A: A6 64        LDX $64
7E/A83C: BF 80 C7 7F  LDA $7FC780,X
7E/A840: 97 D3        STA [$D3],Y
7E/A842: C8           INY 
7E/A843: C8           INY 
7E/A844: 97 D3        STA [$D3],Y
7E/A846: C8           INY 
7E/A847: C8           INY 
7E/A848: 97 D3        STA [$D3],Y
7E/A84A: C8           INY 
7E/A84B: C8           INY 
7E/A84C: 97 D3        STA [$D3],Y
7E/A84E: C8           INY 
7E/A84F: C8           INY 
7E/A850: E4 C7        CPX $C7
7E/A852: F0 04        BEQ $A858
7E/A854: CA           DEX 
7E/A855: CA           DEX 
7E/A856: 80 E4        BRA $A83C
7E/A858: A5 C7        LDA $C7
7E/A85A: 97 D3        STA [$D3],Y
7E/A85C: C8           INY 
7E/A85D: C8           INY 
7E/A85E: C0 00 02     CPY #$0200
7E/A861: D0 F7        BNE $A85A
7E/A863: A6 C7        LDX $C7
7E/A865: A5 32        LDA $32
7E/A867: 9F 00 85 7E  STA $7E8500,X
7E/A86B: E8           INX 
7E/A86C: E8           INX 
7E/A86D: E0 C0 00     CPX #$00C0
7E/A870: D0 F5        BNE $A867
7E/A872: 38           SEC 
7E/A873: E9 7A 00     SBC #$007A
7E/A876: 9F 00 85 7E  STA $7E8500,X
7E/A87A: E8           INX 
7E/A87B: E8           INX 
7E/A87C: E0 00 02     CPX #$0200
7E/A87F: D0 F5        BNE $A876
7E/A881: A6 C7        LDX $C7
7E/A883: A5 30        LDA $30
7E/A885: 9F 00 87 7E  STA $7E8700,X
7E/A889: E8           INX 
7E/A88A: E8           INX 
7E/A88B: E0 C0 00     CPX #$00C0
7E/A88E: D0 F5        BNE $A885
7E/A890: 38           SEC 
7E/A891: E9 02 00     SBC #$0002
7E/A894: 85 68        STA $68
7E/A896: A9 7E 00     LDA #$007E
7E/A899: 85 D2        STA $D2
7E/A89B: A9 00 C0     LDA #$C000
7E/A89E: 85 D0        STA $D0
7E/A8A0: A5 66        LDA $66
7E/A8A2: A8           TAY 
7E/A8A3: B7 D0        LDA [$D0],Y
7E/A8A5: 25 C6        AND $C6
7E/A8A7: 4A           LSR 
7E/A8A8: 4A           LSR 
7E/A8A9: 4A           LSR 
7E/A8AA: 4A           LSR 
7E/A8AB: 4A           LSR 
7E/A8AC: 4A           LSR 
7E/A8AD: 18           CLC 
7E/A8AE: 65 68        ADC $68
7E/A8B0: 9F 00 87 7E  STA $7E8700,X
7E/A8B4: C8           INY 
7E/A8B5: C8           INY 
7E/A8B6: C8           INY 
7E/A8B7: C8           INY 
7E/A8B8: C8           INY 
7E/A8B9: C8           INY 
7E/A8BA: C8           INY 
7E/A8BB: C8           INY 
7E/A8BC: E8           INX 
7E/A8BD: E8           INX 
7E/A8BE: E0 00 02     CPX #$0200
7E/A8C1: D0 E0        BNE $A8A3
7E/A8C3: E2 20        SEP #$20
7E/A8C5: 60           RTS 
7E/A8C6: C2 20        REP #$20
7E/A8C8: A9 7E 00     LDA #$007E
7E/A8CB: 85 D5        STA $D5
7E/A8CD: A9 00 8B     LDA #$8B00
7E/A8D0: 85 D3        STA $D3
7E/A8D2: A5 C7        LDA $C7
7E/A8D4: A8           TAY 
7E/A8D5: 97 D3        STA [$D3],Y
7E/A8D7: C8           INY 
7E/A8D8: C8           INY 
7E/A8D9: C4 60        CPY $60
7E/A8DB: D0 F8        BNE $A8D5
7E/A8DD: A6 C7        LDX $C7
7E/A8DF: BF 80 C7 7F  LDA $7FC780,X
7E/A8E3: 97 D3        STA [$D3],Y
7E/A8E5: C8           INY 
7E/A8E6: C8           INY 
7E/A8E7: E4 62        CPX $62
7E/A8E9: F0 04        BEQ $A8EF
7E/A8EB: E8           INX 
7E/A8EC: E8           INX 
7E/A8ED: 80 F0        BRA $A8DF
7E/A8EF: A6 64        LDX $64
7E/A8F1: BF 80 C7 7F  LDA $7FC780,X
7E/A8F5: 97 D3        STA [$D3],Y
7E/A8F7: C8           INY 
7E/A8F8: C8           INY 
7E/A8F9: 97 D3        STA [$D3],Y
7E/A8FB: C8           INY 
7E/A8FC: C8           INY 
7E/A8FD: 97 D3        STA [$D3],Y
7E/A8FF: C8           INY 
7E/A900: C8           INY 
7E/A901: 97 D3        STA [$D3],Y
7E/A903: C8           INY 
7E/A904: C8           INY 
7E/A905: E4 C7        CPX $C7
7E/A907: F0 04        BEQ $A90D
7E/A909: CA           DEX 
7E/A90A: CA           DEX 
7E/A90B: 80 E4        BRA $A8F1
7E/A90D: A5 C7        LDA $C7
7E/A90F: 97 D3        STA [$D3],Y
7E/A911: C8           INY 
7E/A912: C8           INY 
7E/A913: C0 00 02     CPY #$0200
7E/A916: D0 F7        BNE $A90F
7E/A918: A6 C7        LDX $C7
7E/A91A: A5 32        LDA $32
7E/A91C: 9F 00 85 7E  STA $7E8500,X
7E/A920: E8           INX 
7E/A921: E8           INX 
7E/A922: E0 C0 00     CPX #$00C0
7E/A925: D0 F5        BNE $A91C
7E/A927: 38           SEC 
7E/A928: E9 7A 00     SBC #$007A
7E/A92B: 9F 00 85 7E  STA $7E8500,X
7E/A92F: E8           INX 
7E/A930: E8           INX 
7E/A931: E0 00 02     CPX #$0200
7E/A934: D0 F5        BNE $A92B
7E/A936: A6 C7        LDX $C7
7E/A938: A5 30        LDA $30
7E/A93A: 9F 00 87 7E  STA $7E8700,X
7E/A93E: E8           INX 
7E/A93F: E8           INX 
7E/A940: E0 C0 00     CPX #$00C0
7E/A943: D0 F5        BNE $A93A
7E/A945: A5 30        LDA $30
7E/A947: 18           CLC 
7E/A948: 65 68        ADC $68
7E/A94A: 9F 00 87 7E  STA $7E8700,X
7E/A94E: E8           INX 
7E/A94F: E8           INX 
7E/A950: A5 30        LDA $30
7E/A952: 18           CLC 
7E/A953: E5 68        SBC $68
7E/A955: 9F 00 87 7E  STA $7E8700,X
7E/A959: E8           INX 
7E/A95A: E8           INX 
7E/A95B: E0 00 02     CPX #$0200
7E/A95E: D0 E5        BNE $A945
7E/A960: E2 20        SEP #$20
7E/A962: 60           RTS 
7E/A963: A9 C3        LDA #$C3        ; C3/02B3
7E/A965: 85 D2        STA $D2
7E/A967: A2 B3 02     LDX #$02B3
7E/A96A: 86 D0        STX $D0
7E/A96C: A9 7E        LDA #$7E
7E/A96E: 85 D5        STA $D5
7E/A970: A2 00 90     LDX #$9000
7E/A973: 86 D3        STX $D3
7E/A975: 20 0D C0     JSR $C00D
7E/A978: A9 C3        LDA #$C3
7E/A97A: 85 D2        STA $D2
7E/A97C: A2 25 1D     LDX #$1D25
7E/A97F: 86 D0        STX $D0
7E/A981: A9 7E        LDA #$7E
7E/A983: 85 D5        STA $D5
7E/A985: A2 20 90     LDX #$9020
7E/A988: 86 D3        STX $D3
7E/A98A: 20 0D C0     JSR $C00D
7E/A98D: A9 7E        LDA #$7E
7E/A98F: 85 D2        STA $D2
7E/A991: A2 20 90     LDX #$9020
7E/A994: 86 D0        STX $D0
7E/A996: A9 7E        LDA #$7E
7E/A998: 85 D5        STA $D5
7E/A99A: A2 00 E0     LDX #$E000
7E/A99D: 86 D3        STX $D3
7E/A99F: A2 20 00     LDX #$0020
7E/A9A2: 86 D6        STX $D6
7E/A9A4: 20 CC C1     JSR $C1CC
7E/A9A7: A9 7E        LDA #$7E
7E/A9A9: 85 D2        STA $D2
7E/A9AB: A2 C0 91     LDX #$91C0
7E/A9AE: 86 D0        STX $D0
7E/A9B0: A2 20 00     LDX #$0020
7E/A9B3: 86 D6        STX $D6
7E/A9B5: A9 7E        LDA #$7E
7E/A9B7: 85 D5        STA $D5
7E/A9B9: A2 00 F0     LDX #$F000
7E/A9BC: 86 D3        STX $D3
7E/A9BE: A2 20 00     LDX #$0020
7E/A9C1: 86 D6        STX $D6
7E/A9C3: 20 CC C1     JSR $C1CC
7E/A9C6: A9 7E        LDA #$7E
7E/A9C8: 85 D2        STA $D2
7E/A9CA: A2 80 91     LDX #$9180
7E/A9CD: 86 D0        STX $D0
7E/A9CF: A9 7E        LDA #$7E
7E/A9D1: 85 D5        STA $D5
7E/A9D3: A2 00 F4     LDX #$F400
7E/A9D6: 86 D3        STX $D3
7E/A9D8: A2 20 00     LDX #$0020
7E/A9DB: 86 D6        STX $D6
7E/A9DD: 20 CC C1     JSR $C1CC
7E/A9E0: A9 C3        LDA #$C3
7E/A9E2: 85 D2        STA $D2
7E/A9E4: A2 1F 33     LDX #$331F
7E/A9E7: 86 D0        STX $D0
7E/A9E9: A9 7E        LDA #$7E
7E/A9EB: 85 D5        STA $D5
7E/A9ED: A2 00 E8     LDX #$E800
7E/A9F0: 86 D3        STX $D3
7E/A9F2: 20 0D C0     JSR $C00D
7E/A9F5: A9 7E        LDA #$7E
7E/A9F7: 85 D2        STA $D2
7E/A9F9: A2 80 91     LDX #$9180
7E/A9FC: 86 D0        STX $D0
7E/A9FE: A9 7E        LDA #$7E
7E/AA00: 85 D5        STA $D5
7E/AA02: A2 00 EC     LDX #$EC00
7E/AA05: 86 D3        STX $D3
7E/AA07: A2 20 00     LDX #$0020
7E/AA0A: 86 D6        STX $D6
7E/AA0C: 20 CC C1     JSR $C1CC
7E/AA0F: A9 7E        LDA #$7E
7E/AA11: 85 D5        STA $D5
7E/AA13: A2 C0 91     LDX #$91C0
7E/AA16: 86 D3        STX $D3
7E/AA18: A2 20 00     LDX #$0020
7E/AA1B: 86 D6        STX $D6
7E/AA1D: 20 E0 C1     JSR $C1E0
7E/AA20: A9 7E        LDA #$7E
7E/AA22: 85 D5        STA $D5
7E/AA24: A2 80 91     LDX #$9180
7E/AA27: 86 D3        STX $D3
7E/AA29: A2 20 00     LDX #$0020
7E/AA2C: 86 D6        STX $D6
7E/AA2E: 20 E0 C1     JSR $C1E0
7E/AA31: A9 7E        LDA #$7E
7E/AA33: 85 D2        STA $D2
7E/AA35: A2 00 E8     LDX #$E800
7E/AA38: 86 D0        STX $D0
7E/AA3A: 20 AB AC     JSR $ACAB
7E/AA3D: A9 7E        LDA #$7E
7E/AA3F: 85 D2        STA $D2
7E/AA41: A2 00 EC     LDX #$EC00
7E/AA44: 86 D0        STX $D0
7E/AA46: 20 AB AC     JSR $ACAB
7E/AA49: A9 7E        LDA #$7E
7E/AA4B: 85 D5        STA $D5
7E/AA4D: A2 E0 F3     LDX #$F3E0
7E/AA50: 86 D3        STX $D3
7E/AA52: A2 20 00     LDX #$0020
7E/AA55: 86 D6        STX $D6
7E/AA57: 20 E0 C1     JSR $C1E0
7E/AA5A: A9 7E        LDA #$7E
7E/AA5C: 85 D5        STA $D5
7E/AA5E: A2 E0 F7     LDX #$F7E0
7E/AA61: 86 D3        STX $D3
7E/AA63: A2 20 00     LDX #$0020
7E/AA66: 86 D6        STX $D6
7E/AA68: 20 E0 C1     JSR $C1E0
7E/AA6B: A9 7E        LDA #$7E
7E/AA6D: 85 D2        STA $D2
7E/AA6F: A2 00 F0     LDX #$F000
7E/AA72: 86 D0        STX $D0
7E/AA74: 20 0D AD     JSR $AD0D
7E/AA77: A9 7E        LDA #$7E
7E/AA79: 85 D2        STA $D2
7E/AA7B: A2 00 F4     LDX #$F400
7E/AA7E: 86 D0        STX $D0
7E/AA80: 20 0D AD     JSR $AD0D
7E/AA83: A9 7E        LDA #$7E
7E/AA85: 85 D2        STA $D2
7E/AA87: A2 20 90     LDX #$9020
7E/AA8A: 86 D0        STX $D0
7E/AA8C: A9 7E        LDA #$7E
7E/AA8E: 85 D5        STA $D5
7E/AA90: A2 00 E0     LDX #$E000
7E/AA93: 86 D3        STX $D3
7E/AA95: A2 20 00     LDX #$0020
7E/AA98: 86 D6        STX $D6
7E/AA9A: 20 CC C1     JSR $C1CC
7E/AA9D: A2 00 E4     LDX #$E400
7E/AAA0: 86 D3        STX $D3
7E/AAA2: 20 CC C1     JSR $C1CC
7E/AAA5: A9 7E        LDA #$7E
7E/AAA7: 85 D5        STA $D5
7E/AAA9: A2 E0 E7     LDX #$E7E0
7E/AAAC: 86 D3        STX $D3
7E/AAAE: C2 20        REP #$20
7E/AAB0: A5 C7        LDA $C7
7E/AAB2: A4 C7        LDY $C7
7E/AAB4: 97 D3        STA [$D3],Y
7E/AAB6: C8           INY 
7E/AAB7: C8           INY 
7E/AAB8: AF 00 90 7E  LDA $7E9000
7E/AABC: 8F 30 F1 7F  STA $7FF130
7E/AAC0: 97 D3        STA [$D3],Y
7E/AAC2: C8           INY 
7E/AAC3: C8           INY 
7E/AAC4: C0 20 00     CPY #$0020
7E/AAC7: D0 F7        BNE $AAC0
7E/AAC9: E2 20        SEP #$20
7E/AACB: A9 7E        LDA #$7E
7E/AACD: 85 D2        STA $D2
7E/AACF: A2 00 E4     LDX #$E400
7E/AAD2: 86 D0        STX $D0
7E/AAD4: 20 0D AD     JSR $AD0D
7E/AAD7: AF BA 91 7E  LDA $7E91BA
7E/AADB: 8F 32 F1 7F  STA $7FF132
7E/AADF: AF BB 91 7E  LDA $7E91BB
7E/AAE3: 8F 33 F1 7F  STA $7FF133
7E/AAE7: A9 00        LDA #$00
7E/AAE9: 85 B8        STA $B8
7E/AAEB: A9 7E        LDA #$7E
7E/AAED: 85 BC        STA $BC
7E/AAEF: A2 00 90     LDX #$9000
7E/AAF2: 86 BA        STX $BA
7E/AAF4: A2 00 02     LDX #$0200
7E/AAF7: 86 BD        STX $BD
7E/AAF9: 82 58 01     BRL $AC54
7E/AAFC: A9 C3        LDA #$C3
7E/AAFE: 85 D2        STA $D2
7E/AB00: A2 B3 02     LDX #$02B3
7E/AB03: 86 D0        STX $D0
7E/AB05: A9 7E        LDA #$7E
7E/AB07: 85 D5        STA $D5
7E/AB09: A2 00 90     LDX #$9000
7E/AB0C: 86 D3        STX $D3
7E/AB0E: 20 0D C0     JSR $C00D
7E/AB11: A9 C3        LDA #$C3
7E/AB13: 85 D2        STA $D2
7E/AB15: A2 63 06     LDX #$0663
7E/AB18: 86 D0        STX $D0
7E/AB1A: A9 7E        LDA #$7E
7E/AB1C: 85 D5        STA $D5
7E/AB1E: A2 00 90     LDX #$9000
7E/AB21: 86 D3        STX $D3
7E/AB23: 20 0D C0     JSR $C00D
7E/AB26: A9 00        LDA #$00
7E/AB28: 85 B8        STA $B8
7E/AB2A: A9 7E        LDA #$7E
7E/AB2C: 85 BC        STA $BC
7E/AB2E: A2 00 90     LDX #$9000
7E/AB31: 86 BA        STX $BA
7E/AB33: A2 00 02     LDX #$0200
7E/AB36: 86 BD        STX $BD
7E/AB38: 82 19 01     BRL $AC54
7E/AB3B: A9 C3        LDA #$C3
7E/AB3D: 85 D2        STA $D2
7E/AB3F: A2 B3 02     LDX #$02B3
7E/AB42: 86 D0        STX $D0
7E/AB44: A9 7E        LDA #$7E
7E/AB46: 85 D5        STA $D5
7E/AB48: A2 00 90     LDX #$9000
7E/AB4B: 86 D3        STX $D3
7E/AB4D: 20 0D C0     JSR $C00D
7E/AB50: A9 C3        LDA #$C3
7E/AB52: 85 D2        STA $D2
7E/AB54: A2 F8 4D     LDX #$4DF8
7E/AB57: 86 D0        STX $D0
7E/AB59: A9 7E        LDA #$7E
7E/AB5B: 85 D5        STA $D5
7E/AB5D: A2 00 90     LDX #$9000
7E/AB60: 86 D3        STX $D3
7E/AB62: 20 0D C0     JSR $C00D
7E/AB65: A9 00        LDA #$00
7E/AB67: 85 B8        STA $B8
7E/AB69: A9 7E        LDA #$7E
7E/AB6B: 85 BC        STA $BC
7E/AB6D: A2 00 90     LDX #$9000
7E/AB70: 86 BA        STX $BA
7E/AB72: A2 00 02     LDX #$0200
7E/AB75: 86 BD        STX $BD
7E/AB77: 20 54 AC     JSR $AC54
7E/AB7A: C2 20        REP #$20
7E/AB7C: A9 90 6E     LDA #$6E90
7E/AB7F: 8F 00 90 7E  STA $7E9000
7E/AB83: E2 20        SEP #$20
7E/AB85: A9 7E        LDA #$7E
7E/AB87: 85 D2        STA $D2
7E/AB89: A2 00 90     LDX #$9000
7E/AB8C: 86 D0        STX $D0
7E/AB8E: A9 7E        LDA #$7E
7E/AB90: 85 D5        STA $D5
7E/AB92: A2 E0 E3     LDX #$E3E0
7E/AB95: 86 D3        STX $D3
7E/AB97: A2 20 00     LDX #$0020
7E/AB9A: 86 D6        STX $D6
7E/AB9C: 20 CC C1     JSR $C1CC
7E/AB9F: A9 7E        LDA #$7E
7E/ABA1: 85 D5        STA $D5
7E/ABA3: A2 00 E0     LDX #$E000
7E/ABA6: 86 D3        STX $D3
7E/ABA8: 20 E0 C1     JSR $C1E0
7E/ABAB: A9 7E        LDA #$7E
7E/ABAD: 85 D2        STA $D2
7E/ABAF: A2 00 E0     LDX #$E000
7E/ABB2: 86 D0        STX $D0
7E/ABB4: 20 0D AD     JSR $AD0D
7E/ABB7: A9 7E        LDA #$7E
7E/ABB9: 85 D2        STA $D2
7E/ABBB: A2 C0 91     LDX #$91C0
7E/ABBE: 86 D0        STX $D0
7E/ABC0: A2 20 00     LDX #$0020
7E/ABC3: 86 D6        STX $D6
7E/ABC5: A9 7E        LDA #$7E
7E/ABC7: 85 D5        STA $D5
7E/ABC9: A2 00 F0     LDX #$F000
7E/ABCC: 86 D3        STX $D3
7E/ABCE: A2 20 00     LDX #$0020
7E/ABD1: 86 D6        STX $D6
7E/ABD3: 20 CC C1     JSR $C1CC
7E/ABD6: A9 7E        LDA #$7E
7E/ABD8: 85 D2        STA $D2
7E/ABDA: A2 80 91     LDX #$9180
7E/ABDD: 86 D0        STX $D0
7E/ABDF: A9 7E        LDA #$7E
7E/ABE1: 85 D5        STA $D5
7E/ABE3: A2 00 F4     LDX #$F400
7E/ABE6: 86 D3        STX $D3
7E/ABE8: A2 20 00     LDX #$0020
7E/ABEB: 86 D6        STX $D6
7E/ABED: 20 CC C1     JSR $C1CC
7E/ABF0: A9 7E        LDA #$7E
7E/ABF2: 85 D5        STA $D5
7E/ABF4: A2 E0 F3     LDX #$F3E0
7E/ABF7: 86 D3        STX $D3
7E/ABF9: A2 20 00     LDX #$0020
7E/ABFC: 86 D6        STX $D6
7E/ABFE: 20 E0 C1     JSR $C1E0
7E/AC01: A9 7E        LDA #$7E
7E/AC03: 85 D5        STA $D5
7E/AC05: A2 E0 F7     LDX #$F7E0
7E/AC08: 86 D3        STX $D3
7E/AC0A: A2 20 00     LDX #$0020
7E/AC0D: 86 D6        STX $D6
7E/AC0F: 20 E0 C1     JSR $C1E0
7E/AC12: A9 7E        LDA #$7E
7E/AC14: 85 D2        STA $D2
7E/AC16: A2 00 F0     LDX #$F000
7E/AC19: 86 D0        STX $D0
7E/AC1B: 20 0D AD     JSR $AD0D
7E/AC1E: A9 7E        LDA #$7E
7E/AC20: 85 D2        STA $D2
7E/AC22: A2 00 F4     LDX #$F400
7E/AC25: 86 D0        STX $D0
7E/AC27: 82 E3 00     BRL $AD0D
7E/AC2A: A9 C3        LDA #$C3
7E/AC2C: 85 D2        STA $D2
7E/AC2E: A2 89 0D     LDX #$0D89
7E/AC31: 86 D0        STX $D0
7E/AC33: A9 7E        LDA #$7E
7E/AC35: 85 D5        STA $D5
7E/AC37: A2 00 90     LDX #$9000
7E/AC3A: 86 D3        STX $D3
7E/AC3C: 20 0D C0     JSR $C00D
7E/AC3F: A9 80        LDA #$80
7E/AC41: 85 B8        STA $B8
7E/AC43: A9 7E        LDA #$7E
7E/AC45: 85 BC        STA $BC
7E/AC47: A2 00 90     LDX #$9000
7E/AC4A: 86 BA        STX $BA
7E/AC4C: A2 40 00     LDX #$0040
7E/AC4F: 86 BD        STX $BD
7E/AC51: 82 00 00     BRL $AC54
7E/AC54: A5 B8        LDA $B8
7E/AC56: 8D 21 21     STA $2121
7E/AC59: A9 00        LDA #$00
7E/AC5B: 8D 70 43     STA $4370
7E/AC5E: A9 22        LDA #$22
7E/AC60: 8D 71 43     STA $4371
7E/AC63: A6 BA        LDX $BA
7E/AC65: 8E 72 43     STX $4372
7E/AC68: A5 BC        LDA $BC
7E/AC6A: 8D 74 43     STA $4374
7E/AC6D: A6 BD        LDX $BD
7E/AC6F: 8E 75 43     STX $4375
7E/AC72: A9 80        LDA #$80
7E/AC74: 8D 0B 42     STA $420B
7E/AC77: 60           RTS 
7E/AC78: C2 20        REP #$20
7E/AC7A: 29 FF 00     AND #$00FF
7E/AC7D: 0A           ASL 
7E/AC7E: AA           TAX 
7E/AC7F: BF 10 F1 7F  LDA $7FF110,X
7E/AC83: 8D 72 43     STA $4372
7E/AC86: BF 20 F1 7F  LDA $7FF120,X
7E/AC8A: 8D 75 43     STA $4375
7E/AC8D: E2 20        SEP #$20
7E/AC8F: BF 01 F1 7F  LDA $7FF101,X
7E/AC93: 8D 21 21     STA $2121
7E/AC96: A9 00        LDA #$00
7E/AC98: 8D 70 43     STA $4370
7E/AC9B: A9 22        LDA #$22
7E/AC9D: 8D 71 43     STA $4371
7E/ACA0: A9 7E        LDA #$7E
7E/ACA2: 8D 74 43     STA $4374
7E/ACA5: A9 80        LDA #$80
7E/ACA7: 8D 0B 42     STA $420B
7E/ACAA: 60           RTS 
7E/ACAB: A5 D2        LDA $D2
7E/ACAD: 85 D5        STA $D5
7E/ACAF: C2 20        REP #$20
7E/ACB1: A5 D0        LDA $D0
7E/ACB3: 18           CLC 
7E/ACB4: 69 20 00     ADC #$0020
7E/ACB7: 85 D3        STA $D3
7E/ACB9: A4 C7        LDY $C7
7E/ACBB: B7 D0        LDA [$D0],Y
7E/ACBD: 20 CC AC     JSR $ACCC
7E/ACC0: 97 D3        STA [$D3],Y
7E/ACC2: C8           INY 
7E/ACC3: C8           INY 
7E/ACC4: C0 E0 03     CPY #$03E0
7E/ACC7: D0 F2        BNE $ACBB
7E/ACC9: E2 20        SEP #$20
7E/ACCB: 60           RTS 
7E/ACCC: 5A           PHY 
7E/ACCD: 85 18        STA $18
7E/ACCF: 29 1F        AND #$1F
7E/ACD1: 00 F0        BRK $F0
7E/ACD3: 01 3A        ORA ($3A,X)
7E/ACD5: 85 1A        STA $1A
7E/ACD7: 46 18        LSR $18
7E/ACD9: 46 18        LSR $18
7E/ACDB: 46 18        LSR $18
7E/ACDD: 46 18        LSR $18
7E/ACDF: 46 18        LSR $18
7E/ACE1: A5 18        LDA $18
7E/ACE3: 29 1F        AND #$1F
7E/ACE5: 00 F0        BRK $F0
7E/ACE7: 0A           ASL 
7E/ACE8: 3A           DEC 
7E/ACE9: 0A           ASL 
7E/ACEA: 0A           ASL 
7E/ACEB: 0A           ASL 
7E/ACEC: 0A           ASL 
7E/ACED: 0A           ASL 
7E/ACEE: 05 1A        ORA $1A
7E/ACF0: 85 1A        STA $1A
7E/ACF2: A5 18        LDA $18
7E/ACF4: 4A           LSR 
7E/ACF5: 4A           LSR 
7E/ACF6: 4A           LSR 
7E/ACF7: 4A           LSR 
7E/ACF8: 4A           LSR 
7E/ACF9: 29 1F        AND #$1F
7E/ACFB: 00 F0        BRK $F0
7E/ACFD: 0B           PHD 
7E/ACFE: 3A           DEC 
7E/ACFF: 0A           ASL 
7E/AD00: 0A           ASL 
7E/AD01: 0A           ASL 
7E/AD02: 0A           ASL 
7E/AD03: 0A           ASL 
7E/AD04: 0A           ASL 
7E/AD05: 0A           ASL 
7E/AD06: 0A           ASL 
7E/AD07: 0A           ASL 
7E/AD08: 0A           ASL 
7E/AD09: 05 1A        ORA $1A
7E/AD0B: 7A           PLY 
7E/AD0C: 60           RTS 
7E/AD0D: A5 D2        LDA $D2
7E/AD0F: 85 D5        STA $D5
7E/AD11: C2 20        REP #$20
7E/AD13: A2 10 00     LDX #$0010
7E/AD16: 20 23 AD     JSR $AD23
7E/AD19: E6 D0        INC $D0
7E/AD1B: E6 D0        INC $D0
7E/AD1D: CA           DEX 
7E/AD1E: D0 F6        BNE $AD16
7E/AD20: E2 20        SEP #$20
7E/AD22: 60           RTS 
7E/AD23: DA           PHX 
7E/AD24: A5 D0        LDA $D0
7E/AD26: 18           CLC 
7E/AD27: 69 E0        ADC #$E0
7E/AD29: 03 85        ORA $85,S
7E/AD2B: D3 A7        CMP ($A7,S),Y
7E/AD2D: D0 29        BNE $AD58
7E/AD2F: 1F 00 85 0C  ORA $0C8500,X
7E/AD33: A7 D3        LDA [$D3]
7E/AD35: 29 1F        AND #$1F
7E/AD37: 00 C5        BRK $C5
7E/AD39: 0C B0 10     TSB $10B0
7E/AD3C: 45 C5        EOR $C5
7E/AD3E: 1A           INC 
7E/AD3F: 18           CLC 
7E/AD40: 65 0C        ADC $0C
7E/AD42: 0A           ASL 
7E/AD43: 0A           ASL 
7E/AD44: 0A           ASL 
7E/AD45: 45 C5        EOR $C5
7E/AD47: 1A           INC 
7E/AD48: 85 86        STA $86
7E/AD4A: 80 08        BRA $AD54
7E/AD4C: 38           SEC 
7E/AD4D: E5 0C        SBC $0C
7E/AD4F: 0A           ASL 
7E/AD50: 0A           ASL 
7E/AD51: 0A           ASL 
7E/AD52: 85 86        STA $86
7E/AD54: A7 D0        LDA [$D0]
7E/AD56: 29 E0        AND #$E0
7E/AD58: 03 85        ORA $85,S
7E/AD5A: 0C A7 D3     TSB $D3A7
7E/AD5D: 29 E0        AND #$E0
7E/AD5F: 03 C5        ORA $C5,S
7E/AD61: 0C B0 0F     TSB $0FB0
7E/AD64: 45 C5        EOR $C5
7E/AD66: 1A           INC 
7E/AD67: 18           CLC 
7E/AD68: 65 0C        ADC $0C
7E/AD6A: 4A           LSR 
7E/AD6B: 4A           LSR 
7E/AD6C: 45 C5        EOR $C5
7E/AD6E: 1A           INC 
7E/AD6F: 85 88        STA $88
7E/AD71: 80 07        BRA $AD7A
7E/AD73: 38           SEC 
7E/AD74: E5 0C        SBC $0C
7E/AD76: 4A           LSR 
7E/AD77: 4A           LSR 
7E/AD78: 85 88        STA $88
7E/AD7A: A7 D0        LDA [$D0]
7E/AD7C: 29 00        AND #$00
7E/AD7E: 7C 85 0C     JMP ($0C85,X)
7E/AD81: A7 D3        LDA [$D3]
7E/AD83: 29 00        AND #$00
7E/AD85: 7C C5 0C     JMP ($0CC5,X)
7E/AD88: B0 0F        BCS $AD99
7E/AD8A: 45 C5        EOR $C5
7E/AD8C: 1A           INC 
7E/AD8D: 18           CLC 
7E/AD8E: 65 0C        ADC $0C
7E/AD90: EB           XBA 
7E/AD91: 0A           ASL 
7E/AD92: 45 C5        EOR $C5
7E/AD94: 1A           INC 
7E/AD95: 85 8A        STA $8A
7E/AD97: 80 07        BRA $ADA0
7E/AD99: 38           SEC 
7E/AD9A: E5 0C        SBC $0C
7E/AD9C: EB           XBA 
7E/AD9D: 0A           ASL 
7E/AD9E: 85 8A        STA $8A
7E/ADA0: A7 D0        LDA [$D0]
7E/ADA2: 48           PHA 
7E/ADA3: 29 1F        AND #$1F
7E/ADA5: 00 EB        BRK $EB
7E/ADA7: 85 80        STA $80
7E/ADA9: 68           PLA 
7E/ADAA: 48           PHA 
7E/ADAB: 29 E0        AND #$E0
7E/ADAD: 03 0A        ORA $0A,S
7E/ADAF: 0A           ASL 
7E/ADB0: 0A           ASL 
7E/ADB1: 85 82        STA $82
7E/ADB3: 68           PLA 
7E/ADB4: 29 00        AND #$00
7E/ADB6: 7C 4A 4A     JMP ($4A4A,X)
7E/ADB9: 85 84        STA $84
7E/ADBB: A5 D0        LDA $D0
7E/ADBD: 18           CLC 
7E/ADBE: 69 20        ADC #$20
7E/ADC0: 00 85        BRK $85
7E/ADC2: D3 A0        CMP ($A0,S),Y
7E/ADC4: 1F 00 A5 80  ORA $80A500,X
7E/ADC8: 18           CLC 
7E/ADC9: 65 86        ADC $86
7E/ADCB: 85 80        STA $80
7E/ADCD: EB           XBA 
7E/ADCE: 29 1F        AND #$1F
7E/ADD0: 00 85        BRK $85
7E/ADD2: 0A           ASL 
7E/ADD3: A5 82        LDA $82
7E/ADD5: 18           CLC 
7E/ADD6: 65 88        ADC $88
7E/ADD8: 85 82        STA $82
7E/ADDA: 4A           LSR 
7E/ADDB: 4A           LSR 
7E/ADDC: 4A           LSR 
7E/ADDD: 29 E0        AND #$E0
7E/ADDF: 03 05        ORA $05,S
7E/ADE1: 0A           ASL 
7E/ADE2: 85 0A        STA $0A
7E/ADE4: A5 84        LDA $84
7E/ADE6: 18           CLC 
7E/ADE7: 65 8A        ADC $8A
7E/ADE9: 85 84        STA $84
7E/ADEB: 0A           ASL 
7E/ADEC: 0A           ASL 
7E/ADED: 29 00        AND #$00
7E/ADEF: 7C 05 0A     JMP ($0A05,X)
7E/ADF2: 87 D3        STA [$D3]
7E/ADF4: A5 D3        LDA $D3
7E/ADF6: 18           CLC 
7E/ADF7: 69 20        ADC #$20
7E/ADF9: 00 85        BRK $85
7E/ADFB: D3 88        CMP ($88,S),Y
7E/ADFD: D0 C7        BNE $ADC6
7E/ADFF: FA           PLX 
7E/AE00: 60           RTS 
7E/AE01: C2 20        REP #$20
7E/AE03: 29 FF 00     AND #$00FF
7E/AE06: 0A           ASL 
7E/AE07: AA           TAX 
7E/AE08: EB           XBA 
7E/AE09: 0A           ASL 
7E/AE0A: 18           CLC 
7E/AE0B: 69 00 E0     ADC #$E000
7E/AE0E: 85 0A        STA $0A
7E/AE10: E2 20        SEP #$20
7E/AE12: A5 C7        LDA $C7
7E/AE14: 9F 00 F1 7F  STA $7FF100,X
7E/AE18: C2 20        REP #$20
7E/AE1A: BF 10 F1 7F  LDA $7FF110,X
7E/AE1E: C5 0A        CMP $0A
7E/AE20: F0 08        BEQ $AE2A
7E/AE22: 38           SEC 
7E/AE23: E9 20 00     SBC #$0020
7E/AE26: 9F 10 F1 7F  STA $7FF110,X
7E/AE2A: E2 20        SEP #$20
7E/AE2C: 60           RTS 
7E/AE2D: BF 00 F1 7F  LDA $7FF100,X
7E/AE31: 1A           INC 
7E/AE32: 9F 00 F1 7F  STA $7FF100,X
7E/AE36: 60           RTS 
7E/AE37: C2 20        REP #$20
7E/AE39: 29 FF 00     AND #$00FF
7E/AE3C: 0A           ASL 
7E/AE3D: AA           TAX 
7E/AE3E: EB           XBA 
7E/AE3F: 0A           ASL 
7E/AE40: 18           CLC 
7E/AE41: 69 E0 E3     ADC #$E3E0
7E/AE44: 85 0A        STA $0A
7E/AE46: E2 20        SEP #$20
7E/AE48: A5 C7        LDA $C7
7E/AE4A: 9F 00 F1 7F  STA $7FF100,X
7E/AE4E: C2 20        REP #$20
7E/AE50: BF 10 F1 7F  LDA $7FF110,X
7E/AE54: C5 0A        CMP $0A
7E/AE56: F0 15        BEQ $AE6D
7E/AE58: 18           CLC 
7E/AE59: 69 20 00     ADC #$0020
7E/AE5C: 9F 10 F1 7F  STA $7FF110,X
7E/AE60: E2 20        SEP #$20
7E/AE62: 60           RTS 
7E/AE63: BF 00 F1 7F  LDA $7FF100,X
7E/AE67: 1A           INC 
7E/AE68: 9F 00 F1 7F  STA $7FF100,X
7E/AE6C: 60           RTS 
7E/AE6D: E2 20        SEP #$20
7E/AE6F: 60           RTS 
7E/AE70: C2 20        REP #$20
7E/AE72: 29 FF 00     AND #$00FF
7E/AE75: 0A           ASL 
7E/AE76: AA           TAX 
7E/AE77: EB           XBA 
7E/AE78: 0A           ASL 
7E/AE79: 18           CLC 
7E/AE7A: 69 C0 E3     ADC #$E3C0
7E/AE7D: 85 0A        STA $0A
7E/AE7F: E2 20        SEP #$20
7E/AE81: BF 00 F1 7F  LDA $7FF100,X
7E/AE85: C9 02        CMP #$02
7E/AE87: 90 1B        BCC $AEA4
7E/AE89: A5 C7        LDA $C7
7E/AE8B: 9F 00 F1 7F  STA $7FF100,X
7E/AE8F: C2 20        REP #$20
7E/AE91: BF 10 F1 7F  LDA $7FF110,X
7E/AE95: C5 0A        CMP $0A
7E/AE97: F0 15        BEQ $AEAE
7E/AE99: 18           CLC 
7E/AE9A: 69 20 00     ADC #$0020
7E/AE9D: 9F 10 F1 7F  STA $7FF110,X
7E/AEA1: E2 20        SEP #$20
7E/AEA3: 60           RTS 
7E/AEA4: BF 00 F1 7F  LDA $7FF100,X
7E/AEA8: 1A           INC 
7E/AEA9: 9F 00 F1 7F  STA $7FF100,X
7E/AEAD: 60           RTS 
7E/AEAE: 8A           TXA 
7E/AEAF: EB           XBA 
7E/AEB0: 0A           ASL 
7E/AEB1: 18           CLC 
7E/AEB2: 69 00        ADC #$00
7E/AEB4: E0 9F 10     CPX #$109F
7E/AEB7: F1 7F        SBC ($7F),Y
7E/AEB9: E2 20        SEP #$20
7E/AEBB: 60           RTS 
7E/AEBC: C2 20        REP #$20
7E/AEBE: 29 FF 00     AND #$00FF
7E/AEC1: 0A           ASL 
7E/AEC2: AA           TAX 
7E/AEC3: EB           XBA 
7E/AEC4: 0A           ASL 
7E/AEC5: 18           CLC 
7E/AEC6: 69 C0 E3     ADC #$E3C0
7E/AEC9: 85 0A        STA $0A
7E/AECB: E2 20        SEP #$20
7E/AECD: BF 00 F1 7F  LDA $7FF100,X
7E/AED1: C9 01        CMP #$01
7E/AED3: 90 1B        BCC $AEF0
7E/AED5: A5 C7        LDA $C7
7E/AED7: 9F 00 F1 7F  STA $7FF100,X
7E/AEDB: C2 20        REP #$20
7E/AEDD: BF 10 F1 7F  LDA $7FF110,X
7E/AEE1: C5 0A        CMP $0A
7E/AEE3: F0 15        BEQ $AEFA
7E/AEE5: 18           CLC 
7E/AEE6: 69 20 00     ADC #$0020
7E/AEE9: 9F 10 F1 7F  STA $7FF110,X
7E/AEED: E2 20        SEP #$20
7E/AEEF: 60           RTS 
7E/AEF0: BF 00 F1 7F  LDA $7FF100,X
7E/AEF4: 1A           INC 
7E/AEF5: 9F 00 F1 7F  STA $7FF100,X
7E/AEF9: 60           RTS 
7E/AEFA: 8A           TXA 
7E/AEFB: EB           XBA 
7E/AEFC: 0A           ASL 
7E/AEFD: 18           CLC 
7E/AEFE: 69 00        ADC #$00
7E/AF00: E0 9F 10     CPX #$109F
7E/AF03: F1 7F        SBC ($7F),Y
7E/AF05: E2 20        SEP #$20
7E/AF07: 60           RTS 
7E/AF08: A5 44        LDA $44
7E/AF0A: 29 0F        AND #$0F
7E/AF0C: 85 18        STA $18
7E/AF0E: D0 0D        BNE $AF1D
7E/AF10: A9 10        LDA #$10
7E/AF12: 85 8C        STA $8C
7E/AF14: 64 8B        STZ $8B
7E/AF16: 64 8D        STZ $8D
7E/AF18: A9 B1        LDA #$B1
7E/AF1A: 85 8E        STA $8E
7E/AF1C: 60           RTS 
7E/AF1D: C9 01        CMP #$01
7E/AF1F: D0 0D        BNE $AF2E
7E/AF21: A9 08        LDA #$08
7E/AF23: 85 8C        STA $8C
7E/AF25: 64 8B        STZ $8B
7E/AF27: 64 8D        STZ $8D
7E/AF29: A9 B1        LDA #$B1
7E/AF2B: 85 8E        STA $8E
7E/AF2D: 60           RTS 
7E/AF2E: C9 02        CMP #$02
7E/AF30: D0 0D        BNE $AF3F
7E/AF32: A9 04        LDA #$04
7E/AF34: 64 8C        STZ $8C
7E/AF36: 85 8D        STA $8D
7E/AF38: 64 8B        STZ $8B
7E/AF3A: A9 B1        LDA #$B1
7E/AF3C: 85 8E        STA $8E
7E/AF3E: 60           RTS 
7E/AF3F: C9 03        CMP #$03
7E/AF41: D0 0D        BNE $AF50
7E/AF43: A9 02        LDA #$02
7E/AF45: 85 8C        STA $8C
7E/AF47: 64 8D        STZ $8D
7E/AF49: 64 8B        STZ $8B
7E/AF4B: A9 B1        LDA #$B1
7E/AF4D: 85 8E        STA $8E
7E/AF4F: 60           RTS 
7E/AF50: C9 04        CMP #$04
7E/AF52: D0 0D        BNE $AF61
7E/AF54: A9 10        LDA #$10
7E/AF56: 85 8C        STA $8C
7E/AF58: 64 8D        STZ $8D
7E/AF5A: 85 8B        STA $8B
7E/AF5C: A9 B1        LDA #$B1
7E/AF5E: 85 8E        STA $8E
7E/AF60: 60           RTS 
7E/AF61: C9 05        CMP #$05
7E/AF63: D0 0B        BNE $AF70
7E/AF65: 64 8D        STZ $8D
7E/AF67: 64 8B        STZ $8B
7E/AF69: 64 8C        STZ $8C
7E/AF6B: A9 31        LDA #$31
7E/AF6D: 85 8E        STA $8E
7E/AF6F: 60           RTS 
7E/AF70: C9 06        CMP #$06
7E/AF72: D0 0C        BNE $AF80
7E/AF74: A9 08        LDA #$08
7E/AF76: 85 8B        STA $8B
7E/AF78: 85 8C        STA $8C
7E/AF7A: 85 8D        STA $8D
7E/AF7C: A9 31        LDA #$31
7E/AF7E: 85 8E        STA $8E
7E/AF80: 60           RTS 
7E/AF81: 64 8D        STZ $8D
7E/AF83: A9 71        LDA #$71
7E/AF85: 85 8E        STA $8E
7E/AF87: A5 8C        LDA $8C
7E/AF89: D0 0A        BNE $AF95
7E/AF8B: A5 8B        LDA $8B
7E/AF8D: D0 03        BNE $AF92
7E/AF8F: E6 8C        INC $8C
7E/AF91: 60           RTS 
7E/AF92: C6 8B        DEC $8B
7E/AF94: 60           RTS 
7E/AF95: A5 8B        LDA $8B
7E/AF97: C9 10        CMP #$10
7E/AF99: D0 03        BNE $AF9E
7E/AF9B: 64 8C        STZ $8C
7E/AF9D: 60           RTS 
7E/AF9E: E6 8B        INC $8B
7E/AFA0: 60           RTS 
7E/AFA1: A9 31        LDA #$31
7E/AFA3: 85 8E        STA $8E
7E/AFA5: A9 1F        LDA #$1F
7E/AFA7: 85 8B        STA $8B
7E/AFA9: 85 8D        STA $8D
7E/AFAB: 85 8C        STA $8C
7E/AFAD: 60           RTS 
7E/AFAE: A5 8B        LDA $8B
7E/AFB0: F0 02        BEQ $AFB4
7E/AFB2: C6 8B        DEC $8B
7E/AFB4: A5 8C        LDA $8C
7E/AFB6: F0 02        BEQ $AFBA
7E/AFB8: C6 8C        DEC $8C
7E/AFBA: A5 8D        LDA $8D
7E/AFBC: F0 02        BEQ $AFC0
7E/AFBE: C6 8D        DEC $8D
7E/AFC0: 60           RTS 
7E/AFC1: A2 1F 02     LDX #$021F
7E/AFC4: A9 00        LDA #$00
7E/AFC6: 9D 00 02     STA $0200,X
7E/AFC9: CA           DEX 
7E/AFCA: E0 FF 01     CPX #$01FF
7E/AFCD: D0 F7        BNE $AFC6
7E/AFCF: A5 C7        LDA $C7
7E/AFD1: 9D 00 02     STA $0200,X
7E/AFD4: CA           DEX 
7E/AFD5: 9D 00 02     STA $0200,X
7E/AFD8: CA           DEX 
7E/AFD9: A9 F0        LDA #$F0
7E/AFDB: 9D 00 02     STA $0200,X
7E/AFDE: A5 C7        LDA $C7
7E/AFE0: CA           DEX 
7E/AFE1: F0 06        BEQ $AFE9
7E/AFE3: 9D 00 02     STA $0200,X
7E/AFE6: CA           DEX 
7E/AFE7: 80 E6        BRA $AFCF
7E/AFE9: 8D 00 02     STA $0200
7E/AFEC: 60           RTS 
7E/AFED: A9 22        LDA #$22
7E/AFEF: 8D 01 21     STA $2101
7E/AFF2: 60           RTS 
7E/AFF3: A9 02        LDA #$02
7E/AFF5: 8D 01 21     STA $2101
7E/AFF8: 60           RTS 
7E/AFF9: A9 62        LDA #$62
7E/AFFB: 8D 01 21     STA $2101
7E/AFFE: 60           RTS 
7E/AFFF: DA           PHX 
7E/B000: A5 10        LDA $10
7E/B002: 29 FF        AND #$FF
7E/B004: 00 0A        BRK $0A
7E/B006: 0A           ASL 
7E/B007: AA           TAX 
7E/B008: A5 14        LDA $14
7E/B00A: 9D 00 02     STA $0200,X
7E/B00D: A5 12        LDA $12
7E/B00F: 9D 02 02     STA $0202,X
7E/B012: A5 10        LDA $10
7E/B014: 29 07        AND #$07
7E/B016: 00 0A        BRK $0A
7E/B018: AA           TAX 
7E/B019: BF F0 C7 7F  LDA $7FC7F0,X
7E/B01D: 85 12        STA $12
7E/B01F: A5 10        LDA $10
7E/B021: 29 FF        AND #$FF
7E/B023: 00 4A        BRK $4A
7E/B025: 4A           LSR 
7E/B026: 4A           LSR 
7E/B027: 0A           ASL 
7E/B028: AA           TAX 
7E/B029: BD 00 04     LDA $0400,X
7E/B02C: 25 12        AND $12
7E/B02E: 05 16        ORA $16
7E/B030: 9D 00 04     STA $0400,X
7E/B033: FA           PLX 
7E/B034: 60           RTS 
7E/B035: C2 20        REP #$20
7E/B037: A5 10        LDA $10
7E/B039: 25 C6        AND $C6
7E/B03B: 0A           ASL 
7E/B03C: 0A           ASL 
7E/B03D: AA           TAX 
7E/B03E: E2 20        SEP #$20
7E/B040: A5 14        LDA $14
7E/B042: 9D 00 02     STA $0200,X
7E/B045: 60           RTS 
7E/B046: DA           PHX 
7E/B047: A5 10        LDA $10
7E/B049: 25 C6        AND $C6
7E/B04B: 0A           ASL 
7E/B04C: 0A           ASL 
7E/B04D: AA           TAX 
7E/B04E: BD 00 02     LDA $0200,X
7E/B051: E2 20        SEP #$20
7E/B053: 18           CLC 
7E/B054: 65 14        ADC $14
7E/B056: EB           XBA 
7E/B057: 18           CLC 
7E/B058: 65 15        ADC $15
7E/B05A: EB           XBA 
7E/B05B: C2 20        REP #$20
7E/B05D: 9D 00 02     STA $0200,X
7E/B060: A5 12        LDA $12
7E/B062: 9D 02 02     STA $0202,X
7E/B065: FA           PLX 
7E/B066: 60           RTS 

7E/B067: DA           PHX 
7E/B068: A5 10        LDA $10
7E/B06A: 0A           ASL 
7E/B06B: 0A           ASL 
7E/B06C: AA           TAX 
7E/B06D: E2 20        SEP #$20
7E/B06F: BD 01 02     LDA $0201,X
7E/B072: C9 F1        CMP #$F1
7E/B074: F0 08        BEQ $B07E
7E/B076: 3A           DEC 
7E/B077: 9D 01 02     STA $0201,X
7E/B07A: C2 20        REP #$20
7E/B07C: FA           PLX 
7E/B07D: 60           RTS 
7E/B07E: BD 03 02     LDA $0203,X
7E/B081: 29 CF 9D     AND #$9DCF
7E/B084: 03 02        ORA $02,S
7E/B086: C2 20        REP #$20
7E/B088: FA           PLX 
7E/B089: 60           RTS 

7E/B08A: DA           PHX 
7E/B08B: A5 10        LDA $10
7E/B08D: 0A           ASL 
7E/B08E: 0A           ASL 
7E/B08F: AA           TAX 
7E/B090: E2 20        SEP #$20
7E/B092: BD 01 02     LDA $0201,X
7E/B095: C9 E8        CMP #$E8
7E/B097: B0 08        BCS $B0A1
7E/B099: 1A           INC 
7E/B09A: 9D 01 02     STA $0201,X
7E/B09D: C2 20        REP #$20
7E/B09F: FA           PLX 
7E/B0A0: 60           RTS 
7E/B0A1: BD 03 02     LDA $0203,X
7E/B0A4: 29 CF 9D     AND #$9DCF
7E/B0A7: 03 02        ORA $02,S
7E/B0A9: C2 20        REP #$20
7E/B0AB: FA           PLX 
7E/B0AC: 60           RTS 

7E/B0AD: DA           PHX 
7E/B0AE: A5 10        LDA $10
7E/B0B0: 25 C6        AND $C6
7E/B0B2: 85 10        STA $10
7E/B0B4: 4A           LSR 
7E/B0B5: 4A           LSR 
7E/B0B6: 4A           LSR 
7E/B0B7: 0A           ASL 
7E/B0B8: 85 14        STA $14
7E/B0BA: A5 10        LDA $10
7E/B0BC: 29 07 00     AND #$0007
7E/B0BF: 0A           ASL 
7E/B0C0: AA           TAX 
7E/B0C1: BF E0 C7 7F  LDA $7FC7E0,X
7E/B0C5: 85 12        STA $12
7E/B0C7: A6 14        LDX $14
7E/B0C9: BD 00 04     LDA $0400,X
7E/B0CC: 25 12        AND $12
7E/B0CE: D0 26        BNE $B0F6
7E/B0D0: A5 10        LDA $10
7E/B0D2: 0A           ASL 
7E/B0D3: 0A           ASL 
7E/B0D4: AA           TAX 
7E/B0D5: E2 20        SEP #$20
7E/B0D7: BD 00 02     LDA $0200,X
7E/B0DA: F0 08        BEQ $B0E4
7E/B0DC: 3A           DEC 
7E/B0DD: 9D 00 02     STA $0200,X
7E/B0E0: C2 20        REP #$20
7E/B0E2: FA           PLX 
7E/B0E3: 60           RTS 
7E/B0E4: 3A           DEC 
7E/B0E5: 9D 00 02     STA $0200,X
7E/B0E8: C2 20        REP #$20
7E/B0EA: A6 14        LDX $14
7E/B0EC: BD 00 04     LDA $0400,X
7E/B0EF: 05 12        ORA $12
7E/B0F1: 9D 00 04     STA $0400,X
7E/B0F4: FA           PLX 
7E/B0F5: 60           RTS 
7E/B0F6: C2 20        REP #$20
7E/B0F8: A5 10        LDA $10
7E/B0FA: 0A           ASL 
7E/B0FB: 0A           ASL 
7E/B0FC: AA           TAX 
7E/B0FD: E2 20        SEP #$20
7E/B0FF: BD 00 02     LDA $0200,X
7E/B102: F0 08        BEQ $B10C
7E/B104: 3A           DEC 
7E/B105: 9D 00 02     STA $0200,X
7E/B108: C2 20        REP #$20
7E/B10A: FA           PLX 
7E/B10B: 60           RTS 
7E/B10C: 3A           DEC 
7E/B10D: 9D 00 02     STA $0200,X
7E/B110: C2 20        REP #$20
7E/B112: A5 12        LDA $12
7E/B114: 45 C5        EOR $C5
7E/B116: 85 12        STA $12
7E/B118: A6 14        LDX $14
7E/B11A: BD 00 04     LDA $0400,X
7E/B11D: 25 12        AND $12
7E/B11F: 9D 00 04     STA $0400,X
7E/B122: FA           PLX 
7E/B123: 60           RTS 
7E/B124: DA           PHX 
7E/B125: A5 10        LDA $10
7E/B127: 25 C6        AND $C6
7E/B129: 85 10        STA $10
7E/B12B: 4A           LSR 
7E/B12C: 4A           LSR 
7E/B12D: 4A           LSR 
7E/B12E: 0A           ASL 
7E/B12F: 85 14        STA $14
7E/B131: A5 10        LDA $10
7E/B133: 29 07 00     AND #$0007
7E/B136: 0A           ASL 
7E/B137: AA           TAX 
7E/B138: BF E0 C7 7F  LDA $7FC7E0,X
7E/B13C: 85 12        STA $12
7E/B13E: A6 14        LDX $14
7E/B140: BD 00 04     LDA $0400,X
7E/B143: 25 12        AND $12
7E/B145: D0 28        BNE $B16F
7E/B147: A5 10        LDA $10
7E/B149: 0A           ASL 
7E/B14A: 0A           ASL 
7E/B14B: AA           TAX 
7E/B14C: E2 20        SEP #$20
7E/B14E: BD 00 02     LDA $0200,X
7E/B151: C5 C6        CMP $C6
7E/B153: F0 08        BEQ $B15D
7E/B155: 1A           INC 
7E/B156: 9D 00 02     STA $0200,X
7E/B159: C2 20        REP #$20
7E/B15B: FA           PLX 
7E/B15C: 60           RTS 
7E/B15D: 1A           INC 
7E/B15E: 9D 00 02     STA $0200,X
7E/B161: C2 20        REP #$20
7E/B163: A6 14        LDX $14
7E/B165: BD 00 04     LDA $0400,X
7E/B168: 05 12        ORA $12
7E/B16A: 9D 00 04     STA $0400,X
7E/B16D: FA           PLX 
7E/B16E: 60           RTS 
7E/B16F: C2 20        REP #$20
7E/B171: A5 10        LDA $10
7E/B173: 0A           ASL 
7E/B174: 0A           ASL 
7E/B175: AA           TAX 
7E/B176: E2 20        SEP #$20
7E/B178: BD 00 02     LDA $0200,X
7E/B17B: C5 C6        CMP $C6
7E/B17D: F0 08        BEQ $B187
7E/B17F: 1A           INC 
7E/B180: 9D 00 02     STA $0200,X
7E/B183: C2 20        REP #$20
7E/B185: FA           PLX 
7E/B186: 60           RTS 
7E/B187: 1A           INC 
7E/B188: 9D 00 02     STA $0200,X
7E/B18B: C2 20        REP #$20
7E/B18D: A5 12        LDA $12
7E/B18F: 45 C5        EOR $C5
7E/B191: 85 12        STA $12
7E/B193: A6 14        LDX $14
7E/B195: BD 00 04     LDA $0400,X
7E/B198: 25 12        AND $12
7E/B19A: 9D 00 04     STA $0400,X
7E/B19D: FA           PLX 
7E/B19E: 60           RTS 
7E/B19F: DA           PHX 
7E/B1A0: A5 10        LDA $10
7E/B1A2: 4A           LSR 
7E/B1A3: 4A           LSR 
7E/B1A4: 4A           LSR 
7E/B1A5: 0A           ASL 
7E/B1A6: 85 14        STA $14
7E/B1A8: A5 10        LDA $10
7E/B1AA: 29 07 00     AND #$0007
7E/B1AD: 0A           ASL 
7E/B1AE: AA           TAX 
7E/B1AF: BF E0 C7 7F  LDA $7FC7E0,X
7E/B1B3: 85 12        STA $12
7E/B1B5: A6 14        LDX $14
7E/B1B7: BD 00 04     LDA $0400,X
7E/B1BA: 25 12        AND $12
7E/B1BC: D0 27        BNE $B1E5
7E/B1BE: A5 10        LDA $10
7E/B1C0: 0A           ASL 
7E/B1C1: 0A           ASL 
7E/B1C2: AA           TAX 
7E/B1C3: E2 20        SEP #$20
7E/B1C5: BD 00 02     LDA $0200,X
7E/B1C8: F0 08        BEQ $B1D2
7E/B1CA: 3A           DEC 
7E/B1CB: 9D 00 02     STA $0200,X
7E/B1CE: C2 20        REP #$20
7E/B1D0: FA           PLX 
7E/B1D1: 60           RTS 
7E/B1D2: A5 C6        LDA $C6
7E/B1D4: 9D 00 02     STA $0200,X
7E/B1D7: C2 20        REP #$20
7E/B1D9: A6 14        LDX $14
7E/B1DB: BD 00 04     LDA $0400,X
7E/B1DE: 05 12        ORA $12
7E/B1E0: 9D 00 04     STA $0400,X
7E/B1E3: FA           PLX 
7E/B1E4: 60           RTS 
7E/B1E5: C2 20        REP #$20
7E/B1E7: A5 10        LDA $10
7E/B1E9: 0A           ASL 
7E/B1EA: 0A           ASL 
7E/B1EB: AA           TAX 
7E/B1EC: E2 20        SEP #$20
7E/B1EE: BD 00 02     LDA $0200,X
7E/B1F1: C9 F0        CMP #$F0
7E/B1F3: F0 06        BEQ $B1FB
7E/B1F5: 3A           DEC 
7E/B1F6: 9D 00 02     STA $0200,X
7E/B1F9: C2 20        REP #$20
7E/B1FB: FA           PLX 
7E/B1FC: 60           RTS 
7E/B1FD: DA           PHX 
7E/B1FE: A5 10        LDA $10
7E/B200: 0A           ASL 
7E/B201: 0A           ASL 
7E/B202: AA           TAX 
7E/B203: E2 20        SEP #$20
7E/B205: BD 00 02     LDA $0200,X
7E/B208: C9 05        CMP #$05
7E/B20A: F0 08        BEQ $B214
7E/B20C: 3A           DEC 
7E/B20D: 9D 00 02     STA $0200,X
7E/B210: C2 20        REP #$20
7E/B212: FA           PLX 
7E/B213: 60           RTS 
7E/B214: A9 E4        LDA #$E4
7E/B216: 9D 00 02     STA $0200,X
7E/B219: C2 20        REP #$20
7E/B21B: FA           PLX 
7E/B21C: 60           RTS 

7E/B21D: A9 C3        LDA #$C3
7E/B21F: 85 D2        STA $D2
7E/B221: A2 22 2D     LDX #$2D22
7E/B224: 86 D0        STX $D0
7E/B226: A9 7E        LDA #$7E
7E/B228: 85 D5        STA $D5
7E/B22A: A2 00 90     LDX #$9000
7E/B22D: 86 D3        STX $D3
7E/B22F: 20 0D C0     JSR $C00D
7E/B232: A2 00 40     LDX #$4000
7E/B235: 86 B8        STX $B8
7E/B237: A9 7E        LDA #$7E
7E/B239: 85 BC        STA $BC
7E/B23B: A2 00 90     LDX #$9000
7E/B23E: 86 BA        STX $BA
7E/B240: A2 00 12     LDX #$1200
7E/B243: 86 BD        STX $BD
7E/B245: 20 A3 C1     JSR $C1A3
7E/B248: A9 C3        LDA #$C3
7E/B24A: 85 D2        STA $D2
7E/B24C: A2 83 1E     LDX #$1E83
7E/B24F: 86 D0        STX $D0
7E/B251: A9 7E        LDA #$7E
7E/B253: 85 D5        STA $D5
7E/B255: A2 00 90     LDX #$9000
7E/B258: 86 D3        STX $D3
7E/B25A: 20 0D C0     JSR $C00D
7E/B25D: A2 00 4C     LDX #$4C00
7E/B260: 86 B8        STX $B8
7E/B262: A9 7E        LDA #$7E
7E/B264: 85 BC        STA $BC
7E/B266: A2 00 90     LDX #$9000
7E/B269: 86 BA        STX $BA
7E/B26B: A2 00 18     LDX #$1800
7E/B26E: 86 BD        STX $BD
7E/B270: 82 30 0F     BRL $C1A3

7E/B273: A9 C3        LDA #$C3
7E/B275: 85 D2        STA $D2
7E/B277: A2 F5 06     LDX #$06F5
7E/B27A: 86 D0        STX $D0
7E/B27C: A9 7E        LDA #$7E
7E/B27E: 85 D5        STA $D5
7E/B280: A2 00 90     LDX #$9000
7E/B283: 86 D3        STX $D3
7E/B285: 20 0D C0     JSR $C00D
7E/B288: A2 00 4C     LDX #$4C00
7E/B28B: 86 B8        STX $B8
7E/B28D: A9 7E        LDA #$7E
7E/B28F: 85 BC        STA $BC
7E/B291: A2 00 90     LDX #$9000
7E/B294: 86 BA        STX $BA
7E/B296: A2 00 08     LDX #$0800
7E/B299: 86 BD        STX $BD
7E/B29B: 82 05 0F     BRL $C1A3

7E/B29E: A9 C3        LDA #$C3
7E/B2A0: 85 D2        STA $D2
7E/B2A2: A2 D2 09     LDX #$09D2
7E/B2A5: 86 D0        STX $D0
7E/B2A7: A9 7E        LDA #$7E
7E/B2A9: 85 D5        STA $D5
7E/B2AB: A2 00 90     LDX #$9000
7E/B2AE: 86 D3        STX $D3
7E/B2B0: 20 0D C0     JSR $C00D
7E/B2B3: A2 00 40     LDX #$4000
7E/B2B6: 86 B8        STX $B8
7E/B2B8: A9 7E        LDA #$7E
7E/B2BA: 85 BC        STA $BC
7E/B2BC: A2 00 90     LDX #$9000
7E/B2BF: 86 BA        STX $BA
7E/B2C1: A2 00 08     LDX #$0800
7E/B2C4: 86 BD        STX $BD
7E/B2C6: 20 A3 C1     JSR $C1A3
7E/B2C9: A9 C3        LDA #$C3
7E/B2CB: 85 D2        STA $D2
7E/B2CD: A2 70 0E     LDX #$0E70
7E/B2D0: 86 D0        STX $D0
7E/B2D2: A9 7F        LDA #$7F
7E/B2D4: 85 D5        STA $D5
7E/B2D6: A2 00 F2     LDX #$F200
7E/B2D9: 86 D3        STX $D3
7E/B2DB: 20 0D C0     JSR $C00D
7E/B2DE: C2 20        REP #$20
7E/B2E0: A9 00 F2     LDA #$F200
7E/B2E3: 8F 80 F1 7F  STA $7FF180
7E/B2E7: E2 20        SEP #$20
7E/B2E9: A9 C3        LDA #$C3
7E/B2EB: 85 D2        STA $D2
7E/B2ED: A2 4A 0F     LDX #$0F4A
7E/B2F0: 86 D0        STX $D0
7E/B2F2: A9 7F        LDA #$7F
7E/B2F4: 85 D5        STA $D5
7E/B2F6: A2 00 E8     LDX #$E800
7E/B2F9: 86 D3        STX $D3
7E/B2FB: 20 0D C0     JSR $C00D
7E/B2FE: C2 20        REP #$20
7E/B300: A9 00 E8     LDA #$E800
7E/B303: 8F 82 F1 7F  STA $7FF182
7E/B307: E2 20        SEP #$20
7E/B309: 60           RTS 

7E/B30A: A9 C3        LDA #$C3
7E/B30C: 85 D2        STA $D2
7E/B30E: A2 E7 72     LDX #$72E7
7E/B311: 86 D0        STX $D0
7E/B313: A9 7E        LDA #$7E
7E/B315: 85 D5        STA $D5
7E/B317: A2 00 90     LDX #$9000
7E/B31A: 86 D3        STX $D3
7E/B31C: 20 0D C0     JSR $C00D
7E/B31F: A2 00 5C     LDX #$5C00
7E/B322: 86 B8        STX $B8
7E/B324: A9 7E        LDA #$7E
7E/B326: 85 BC        STA $BC
7E/B328: A2 00 90     LDX #$9000
7E/B32B: 86 BA        STX $BA
7E/B32D: A2 00 04     LDX #$0400
7E/B330: 86 BD        STX $BD
7E/B332: 82 6E 0E     BRL $C1A3
7E/B335: A9 C3        LDA #$C3
7E/B337: 85 D2        STA $D2
7E/B339: A2 D8 66     LDX #$66D8
7E/B33C: 86 D0        STX $D0
7E/B33E: A9 7E        LDA #$7E
7E/B340: 85 D5        STA $D5
7E/B342: A2 00 90     LDX #$9000
7E/B345: 86 D3        STX $D3
7E/B347: 20 0D C0     JSR $C00D
7E/B34A: A2 00 4C     LDX #$4C00
7E/B34D: 86 B8        STX $B8
7E/B34F: A9 7E        LDA #$7E
7E/B351: 85 BC        STA $BC
7E/B353: A2 00 90     LDX #$9000
7E/B356: 86 BA        STX $BA
7E/B358: A2 00 20     LDX #$2000
7E/B35B: 86 BD        STX $BD
7E/B35D: 82 43 0E     BRL $C1A3
7E/B360: A9 C3        LDA #$C3
7E/B362: 85 D2        STA $D2
7E/B364: A2 83 1E     LDX #$1E83
7E/B367: 86 D0        STX $D0
7E/B369: A9 7F        LDA #$7F
7E/B36B: 85 D5        STA $D5
7E/B36D: A2 00 00     LDX #$0000
7E/B370: 86 D3        STX $D3
7E/B372: 82 98 0C     BRL $C00D
7E/B375: A9 C3        LDA #$C3
7E/B377: 85 D2        STA $D2
7E/B379: A2 1E 5B     LDX #$5B1E
7E/B37C: 86 D0        STX $D0
7E/B37E: A9 7F        LDA #$7F
7E/B380: 85 D5        STA $D5
7E/B382: A2 00 20     LDX #$2000
7E/B385: 86 D3        STX $D3
7E/B387: 82 83 0C     BRL $C00D
7E/B38A: A9 18        LDA #$18
7E/B38C: 85 B4        STA $B4
7E/B38E: A9 01        LDA #$01
7E/B390: 85 B3        STA $B3
7E/B392: A2 00 4C     LDX #$4C00
7E/B395: 86 AC        STX $AC
7E/B397: A2 00 00     LDX #$0000
7E/B39A: 86 AE        STX $AE
7E/B39C: A9 7F        LDA #$7F
7E/B39E: 85 B0        STA $B0
7E/B3A0: A2 00 10     LDX #$1000
7E/B3A3: 86 B1        STX $B1
7E/B3A5: 60           RTS 

7E/B3A6: A9 18        LDA #$18
7E/B3A8: 85 B4        STA $B4
7E/B3AA: A9 01        LDA #$01
7E/B3AC: 85 B3        STA $B3
7E/B3AE: A2 00 54     LDX #$5400
7E/B3B1: 86 AC        STX $AC
7E/B3B3: A2 00 10     LDX #$1000
7E/B3B6: 86 AE        STX $AE
7E/B3B8: A9 7F        LDA #$7F
7E/B3BA: 85 B0        STA $B0
7E/B3BC: A2 00 10     LDX #$1000
7E/B3BF: 86 B1        STX $B1
7E/B3C1: 60           RTS 

7E/B3C2: A9 18        LDA #$18
7E/B3C4: 85 B4        STA $B4
7E/B3C6: A9 01        LDA #$01
7E/B3C8: 85 B3        STA $B3
7E/B3CA: A2 00 4C     LDX #$4C00
7E/B3CD: 86 AC        STX $AC
7E/B3CF: A2 00 20     LDX #$2000
7E/B3D2: 86 AE        STX $AE
7E/B3D4: A9 7F        LDA #$7F
7E/B3D6: 85 B0        STA $B0
7E/B3D8: A2 00 10     LDX #$1000
7E/B3DB: 86 B1        STX $B1
7E/B3DD: 60           RTS 

7E/B3DE: A9 18        LDA #$18
7E/B3E0: 85 B4        STA $B4
7E/B3E2: A9 01        LDA #$01
7E/B3E4: 85 B3        STA $B3
7E/B3E6: A2 00 54     LDX #$5400
7E/B3E9: 86 AC        STX $AC
7E/B3EB: A2 00 30     LDX #$3000
7E/B3EE: 86 AE        STX $AE
7E/B3F0: A9 7F        LDA #$7F
7E/B3F2: 85 B0        STA $B0
7E/B3F4: A2 00 10     LDX #$1000
7E/B3F7: 86 B1        STX $B1
7E/B3F9: 60           RTS 
7E/B3FA: A9 C3        LDA #$C3
7E/B3FC: 85 D2        STA $D2
7E/B3FE: A2 48 1D     LDX #$1D48
7E/B401: 86 D0        STX $D0
7E/B403: A9 7E        LDA #$7E
7E/B405: 85 D5        STA $D5
7E/B407: A2 00 90     LDX #$9000
7E/B40A: 86 D3        STX $D3
7E/B40C: 20 0D C0     JSR $C00D
7E/B40F: A9 7E        LDA #$7E
7E/B411: 85 D2        STA $D2
7E/B413: A2 00 90     LDX #$9000
7E/B416: 86 D0        STX $D0
7E/B418: 82 8E 06     BRL $BAA9
7E/B41B: A9 C3        LDA #$C3
7E/B41D: 85 D2        STA $D2
7E/B41F: A2 1B 0E     LDX #$0E1B
7E/B422: 86 D0        STX $D0
7E/B424: A9 7E        LDA #$7E
7E/B426: 85 D5        STA $D5
7E/B428: A2 00 90     LDX #$9000
7E/B42B: 86 D3        STX $D3
7E/B42D: 20 0D C0     JSR $C00D
7E/B430: A9 7E        LDA #$7E
7E/B432: 85 D2        STA $D2
7E/B434: A2 00 90     LDX #$9000
7E/B437: 86 D0        STX $D0
7E/B439: 82 6D 06     BRL $BAA9
7E/B43C: A9 C3        LDA #$C3
7E/B43E: 85 D2        STA $D2
7E/B440: A2 A3 0D     LDX #$0DA3
7E/B443: 86 D0        STX $D0
7E/B445: A9 7E        LDA #$7E
7E/B447: 85 D5        STA $D5
7E/B449: A2 00 90     LDX #$9000
7E/B44C: 86 D3        STX $D3
7E/B44E: 20 0D C0     JSR $C00D
7E/B451: A9 7E        LDA #$7E
7E/B453: 85 D2        STA $D2
7E/B455: A2 00 90     LDX #$9000
7E/B458: 86 D0        STX $D0
7E/B45A: 82 4C 06     BRL $BAA9
7E/B45D: A9 C3        LDA #$C3
7E/B45F: 85 D2        STA $D2
7E/B461: A2 70 0F     LDX #$0F70
7E/B464: 86 D0        STX $D0
7E/B466: A9 7F        LDA #$7F
7E/B468: 85 D5        STA $D5
7E/B46A: A2 00 F2     LDX #$F200
7E/B46D: 86 D3        STX $D3
7E/B46F: 20 0D C0     JSR $C00D
7E/B472: C2 20        REP #$20
7E/B474: A9 00 F2     LDA #$F200
7E/B477: 8F 80 F1 7F  STA $7FF180
7E/B47B: E2 20        SEP #$20
7E/B47D: 60           RTS 
7E/B47E: A9 C3        LDA #$C3
7E/B480: 85 D2        STA $D2
7E/B482: A2 7C 06     LDX #$067C
7E/B485: 86 D0        STX $D0
7E/B487: A9 7E        LDA #$7E
7E/B489: 85 D5        STA $D5
7E/B48B: A2 00 90     LDX #$9000
7E/B48E: 86 D3        STX $D3
7E/B490: 20 0D C0     JSR $C00D
7E/B493: A9 7E        LDA #$7E
7E/B495: 85 D2        STA $D2
7E/B497: A2 00 90     LDX #$9000
7E/B49A: 86 D0        STX $D0
7E/B49C: 82 0A 06     BRL $BAA9
7E/B49F: A9 C3        LDA #$C3
7E/B4A1: 85 D2        STA $D2
7E/B4A3: A2 07 7A     LDX #$7A07
7E/B4A6: 86 D0        STX $D0
7E/B4A8: A9 7E        LDA #$7E
7E/B4AA: 85 D5        STA $D5
7E/B4AC: A2 00 90     LDX #$9000
7E/B4AF: 86 D3        STX $D3
7E/B4B1: 20 0D C0     JSR $C00D
7E/B4B4: A9 7E        LDA #$7E
7E/B4B6: 85 D2        STA $D2
7E/B4B8: A2 00 90     LDX #$9000
7E/B4BB: 86 D0        STX $D0
7E/B4BD: 20 A9 BA     JSR $BAA9
7E/B4C0: A9 C3        LDA #$C3
7E/B4C2: 85 D2        STA $D2
7E/B4C4: A2 69 7A     LDX #$7A69
7E/B4C7: 86 D0        STX $D0
7E/B4C9: A9 7E        LDA #$7E
7E/B4CB: 85 D5        STA $D5
7E/B4CD: A2 00 70     LDX #$7000
7E/B4D0: 86 D3        STX $D3
7E/B4D2: 20 0D C0     JSR $C00D
7E/B4D5: C2 20        REP #$20
7E/B4D7: A9 00 70     LDA #$7000
7E/B4DA: 8F 80 F1 7F  STA $7FF180
7E/B4DE: E2 20        SEP #$20
7E/B4E0: 60           RTS 
7E/B4E1: A9 C3        LDA #$C3
7E/B4E3: 85 D2        STA $D2
7E/B4E5: A2 45 74     LDX #$7445
7E/B4E8: 86 D0        STX $D0
7E/B4EA: A9 7E        LDA #$7E
7E/B4EC: 85 D5        STA $D5
7E/B4EE: A2 00 90     LDX #$9000
7E/B4F1: 86 D3        STX $D3
7E/B4F3: 20 0D C0     JSR $C00D
7E/B4F6: A9 7E        LDA #$7E
7E/B4F8: 85 D2        STA $D2
7E/B4FA: A2 00 90     LDX #$9000
7E/B4FD: 86 D0        STX $D0
7E/B4FF: 20 A9 BA     JSR $BAA9
7E/B502: A9 C3        LDA #$C3
7E/B504: 85 D2        STA $D2
7E/B506: A2 0D 75     LDX #$750D
7E/B509: 86 D0        STX $D0
7E/B50B: A9 7E        LDA #$7E
7E/B50D: 85 D5        STA $D5
7E/B50F: A2 00 70     LDX #$7000
7E/B512: 86 D3        STX $D3
7E/B514: 20 0D C0     JSR $C00D
7E/B517: C2 20        REP #$20
7E/B519: A9 00 70     LDA #$7000
7E/B51C: 8F 80 F1 7F  STA $7FF180
7E/B520: E2 20        SEP #$20
7E/B522: 60           RTS 
7E/B523: A9 C3        LDA #$C3
7E/B525: 85 D2        STA $D2
7E/B527: A2 9A 75     LDX #$759A
7E/B52A: 86 D0        STX $D0
7E/B52C: A9 7E        LDA #$7E
7E/B52E: 85 D5        STA $D5
7E/B530: A2 00 90     LDX #$9000
7E/B533: 86 D3        STX $D3
7E/B535: 20 0D C0     JSR $C00D
7E/B538: A9 7E        LDA #$7E
7E/B53A: 85 D2        STA $D2
7E/B53C: A2 00 90     LDX #$9000
7E/B53F: 86 D0        STX $D0
7E/B541: 20 A9 BA     JSR $BAA9
7E/B544: C2 20        REP #$20
7E/B546: A9 00 68     LDA #$6800
7E/B549: 8F 80 F1 7F  STA $7FF180
7E/B54D: E2 20        SEP #$20
7E/B54F: 60           RTS 
7E/B550: A9 C3        LDA #$C3
7E/B552: 85 D2        STA $D2
7E/B554: A2 5C 76     LDX #$765C
7E/B557: 86 D0        STX $D0
7E/B559: A9 7E        LDA #$7E
7E/B55B: 85 D5        STA $D5
7E/B55D: A2 00 68     LDX #$6800
7E/B560: 86 D3        STX $D3
7E/B562: 20 0D C0     JSR $C00D
7E/B565: 60           RTS 
7E/B566: A9 C3        LDA #$C3
7E/B568: 85 D2        STA $D2
7E/B56A: A2 AE 77     LDX #$77AE
7E/B56D: 86 D0        STX $D0
7E/B56F: A9 7E        LDA #$7E
7E/B571: 85 D5        STA $D5
7E/B573: A2 00 90     LDX #$9000
7E/B576: 86 D3        STX $D3
7E/B578: 20 0D C0     JSR $C00D
7E/B57B: A9 7E        LDA #$7E
7E/B57D: 85 D2        STA $D2
7E/B57F: A2 00 90     LDX #$9000
7E/B582: 86 D0        STX $D0
7E/B584: 20 A9 BA     JSR $BAA9
7E/B587: C2 20        REP #$20
7E/B589: A9 00 60     LDA #$6000
7E/B58C: 8F 80 F1 7F  STA $7FF180
7E/B590: E2 20        SEP #$20
7E/B592: 60           RTS 
7E/B593: A9 C3        LDA #$C3
7E/B595: 85 D2        STA $D2
7E/B597: A2 91 78     LDX #$7891
7E/B59A: 86 D0        STX $D0
7E/B59C: A9 7E        LDA #$7E
7E/B59E: 85 D5        STA $D5
7E/B5A0: A2 00 60     LDX #$6000
7E/B5A3: 86 D3        STX $D3
7E/B5A5: 20 0D C0     JSR $C00D
7E/B5A8: 60           RTS 
7E/B5A9: A9 C3        LDA #$C3
7E/B5AB: 85 D2        STA $D2
7E/B5AD: A2 42 33     LDX #$3342
7E/B5B0: 86 D0        STX $D0
7E/B5B2: A9 7E        LDA #$7E
7E/B5B4: 85 D5        STA $D5
7E/B5B6: A2 00 90     LDX #$9000
7E/B5B9: 86 D3        STX $D3
7E/B5BB: 20 0D C0     JSR $C00D
7E/B5BE: A9 7E        LDA #$7E
7E/B5C0: 85 D2        STA $D2
7E/B5C2: A2 00 90     LDX #$9000
7E/B5C5: 86 D0        STX $D0
7E/B5C7: 20 A9 BA     JSR $BAA9
7E/B5CA: A9 C3        LDA #$C3
7E/B5CC: 85 D2        STA $D2
7E/B5CE: A2 FE 1D     LDX #$1DFE
7E/B5D1: 86 D0        STX $D0
7E/B5D3: A9 7E        LDA #$7E
7E/B5D5: 85 D5        STA $D5
7E/B5D7: A2 00 70     LDX #$7000
7E/B5DA: 86 D3        STX $D3
7E/B5DC: 20 0D C0     JSR $C00D
7E/B5DF: C2 20        REP #$20
7E/B5E1: A9 00 70     LDA #$7000
7E/B5E4: 8F 80 F1 7F  STA $7FF180
7E/B5E8: E2 20        SEP #$20
7E/B5EA: 60           RTS 
7E/B5EB: 20 C0 B8     JSR $B8C0
7E/B5EE: 20 C0 B8     JSR $B8C0
7E/B5F1: 20 C0 B8     JSR $B8C0
7E/B5F4: 20 D9 B8     JSR $B8D9
7E/B5F7: A5 46        LDA $46
7E/B5F9: C9 01        CMP #$01
7E/B5FB: D0 05        BNE $B602
7E/B5FD: 20 BF B7     JSR $B7BF
7E/B600: 80 24        BRA $B626
7E/B602: C9 02        CMP #$02
7E/B604: D0 08        BNE $B60E
7E/B606: 20 A7 B8     JSR $B8A7
7E/B609: 20 29 B7     JSR $B729
7E/B60C: 80 18        BRA $B626
7E/B60E: C9 03        CMP #$03
7E/B610: D0 08        BNE $B61A
7E/B612: 20 42 B7     JSR $B742
7E/B615: 20 A6 B7     JSR $B7A6
7E/B618: 80 0C        BRA $B626
7E/B61A: C9 04        CMP #$04
7E/B61C: D0 08        BNE $B626
7E/B61E: 20 AC B6     JSR $B6AC
7E/B621: 20 A7 B8     JSR $B8A7
7E/B624: 64 46        STZ $46
7E/B626: E6 46        INC $46
7E/B628: 60           RTS 
7E/B629: 20 C0 B8     JSR $B8C0
7E/B62C: 20 C0 B8     JSR $B8C0
7E/B62F: 20 C0 B8     JSR $B8C0
7E/B632: 20 D9 B8     JSR $B8D9
7E/B635: A5 46        LDA $46
7E/B637: C9 01        CMP #$01
7E/B639: D0 05        BNE $B640
7E/B63B: 20 BF B7     JSR $B7BF
7E/B63E: 80 24        BRA $B664
7E/B640: C9 02        CMP #$02
7E/B642: D0 08        BNE $B64C
7E/B644: 20 A7 B8     JSR $B8A7
7E/B647: 20 5B B7     JSR $B75B
7E/B64A: 80 18        BRA $B664
7E/B64C: C9 03        CMP #$03
7E/B64E: D0 08        BNE $B658
7E/B650: 20 8D B7     JSR $B78D
7E/B653: 20 74 B7     JSR $B774
7E/B656: 80 0C        BRA $B664
7E/B658: C9 04        CMP #$04
7E/B65A: D0 08        BNE $B664
7E/B65C: 20 10 B7     JSR $B710
7E/B65F: 20 A7 B8     JSR $B8A7
7E/B662: 64 46        STZ $46
7E/B664: E6 46        INC $46
7E/B666: 60           RTS 
7E/B667: 20 C0 B8     JSR $B8C0
7E/B66A: 20 C0 B8     JSR $B8C0
7E/B66D: 20 C0 B8     JSR $B8C0
7E/B670: 20 D9 B8     JSR $B8D9
7E/B673: A5 46        LDA $46
7E/B675: C9 01        CMP #$01
7E/B677: D0 05        BNE $B67E
7E/B679: 20 BF B7     JSR $B7BF
7E/B67C: 80 12        BRA $B690
7E/B67E: C9 02        CMP #$02
7E/B680: D0 05        BNE $B687
7E/B682: 20 A7 B8     JSR $B8A7
7E/B685: 80 09        BRA $B690
7E/B687: C9 04        CMP #$04
7E/B689: D0 05        BNE $B690
7E/B68B: 20 A7 B8     JSR $B8A7
7E/B68E: 64 46        STZ $46
7E/B690: E6 46        INC $46
7E/B692: 60           RTS 
7E/B693: C2 20        REP #$20
7E/B695: A9 30 00     LDA #$0030
7E/B698: 85 10        STA $10
7E/B69A: 20 67 B0     JSR $B067
7E/B69D: E6 10        INC $10
7E/B69F: A5 10        LDA $10
7E/B6A1: C9 4D 00     CMP #$004D
7E/B6A4: D0 F4        BNE $B69A
7E/B6A6: 20 67 B0     JSR $B067
7E/B6A9: E2 20        SEP #$20
7E/B6AB: 60           RTS 
7E/B6AC: C2 20        REP #$20
7E/B6AE: A9 64 00     LDA #$0064
7E/B6B1: 85 10        STA $10
7E/B6B3: 20 67 B0     JSR $B067
7E/B6B6: E6 10        INC $10
7E/B6B8: A5 10        LDA $10
7E/B6BA: C9 7F 00     CMP #$007F
7E/B6BD: D0 F4        BNE $B6B3
7E/B6BF: 20 67 B0     JSR $B067
7E/B6C2: E2 20        SEP #$20
7E/B6C4: 60           RTS 
7E/B6C5: C2 20        REP #$20
7E/B6C7: A9 49 00     LDA #$0049
7E/B6CA: 85 10        STA $10
7E/B6CC: 20 8A B0     JSR $B08A
7E/B6CF: E6 10        INC $10
7E/B6D1: A5 10        LDA $10
7E/B6D3: C9 68 00     CMP #$0068
7E/B6D6: D0 F4        BNE $B6CC
7E/B6D8: 20 8A B0     JSR $B08A
7E/B6DB: E2 20        SEP #$20
7E/B6DD: 60           RTS 
7E/B6DE: C2 20        REP #$20
7E/B6E0: A9 30 00     LDA #$0030
7E/B6E3: 85 10        STA $10
7E/B6E5: 20 8A B0     JSR $B08A
7E/B6E8: E6 10        INC $10
7E/B6EA: A5 10        LDA $10
7E/B6EC: C9 4D 00     CMP #$004D
7E/B6EF: D0 F4        BNE $B6E5
7E/B6F1: 20 8A B0     JSR $B08A
7E/B6F4: E2 20        SEP #$20
7E/B6F6: 60           RTS 
7E/B6F7: C2 20        REP #$20
7E/B6F9: A9 60 00     LDA #$0060
7E/B6FC: 85 10        STA $10
7E/B6FE: 20 8A B0     JSR $B08A
7E/B701: E6 10        INC $10
7E/B703: A5 10        LDA $10
7E/B705: C9 65 00     CMP #$0065
7E/B708: D0 F4        BNE $B6FE
7E/B70A: 20 8A B0     JSR $B08A
7E/B70D: E2 20        SEP #$20
7E/B70F: 60           RTS 
7E/B710: C2 20        REP #$20
7E/B712: A9 64 00     LDA #$0064
7E/B715: 85 10        STA $10
7E/B717: 20 8A B0     JSR $B08A
7E/B71A: E6 10        INC $10
7E/B71C: A5 10        LDA $10
7E/B71E: C9 7F 00     CMP #$007F
7E/B721: D0 F4        BNE $B717
7E/B723: 20 8A B0     JSR $B08A
7E/B726: E2 20        SEP #$20
7E/B728: 60           RTS 
7E/B729: C2 20        REP #$20
7E/B72B: A9 30 00     LDA #$0030
7E/B72E: 85 10        STA $10
7E/B730: 20 67 B0     JSR $B067
7E/B733: E6 10        INC $10
7E/B735: A5 10        LDA $10
7E/B737: C9 43 00     CMP #$0043
7E/B73A: D0 F4        BNE $B730
7E/B73C: 20 67 B0     JSR $B067
7E/B73F: E2 20        SEP #$20
7E/B741: 60           RTS 
7E/B742: C2 20        REP #$20
7E/B744: A9 4C 00     LDA #$004C
7E/B747: 85 10        STA $10
7E/B749: 20 67 B0     JSR $B067
7E/B74C: E6 10        INC $10
7E/B74E: A5 10        LDA $10
7E/B750: C9 63 00     CMP #$0063
7E/B753: D0 F4        BNE $B749
7E/B755: 20 67 B0     JSR $B067
7E/B758: E2 20        SEP #$20
7E/B75A: 60           RTS 
7E/B75B: C2 20        REP #$20
7E/B75D: A9 30 00     LDA #$0030
7E/B760: 85 10        STA $10
7E/B762: 20 8A B0     JSR $B08A
7E/B765: E6 10        INC $10
7E/B767: A5 10        LDA $10
7E/B769: C9 43 00     CMP #$0043
7E/B76C: D0 F4        BNE $B762
7E/B76E: 20 8A B0     JSR $B08A
7E/B771: E2 20        SEP #$20
7E/B773: 60           RTS 
7E/B774: C2 20        REP #$20
7E/B776: A9 4C 00     LDA #$004C
7E/B779: 85 10        STA $10
7E/B77B: 20 8A B0     JSR $B08A
7E/B77E: E6 10        INC $10
7E/B780: A5 10        LDA $10
7E/B782: C9 63 00     CMP #$0063
7E/B785: D0 F4        BNE $B77B
7E/B787: 20 8A B0     JSR $B08A
7E/B78A: E2 20        SEP #$20
7E/B78C: 60           RTS 
7E/B78D: C2 20        REP #$20
7E/B78F: A9 46 00     LDA #$0046
7E/B792: 85 10        STA $10
7E/B794: 20 8A B0     JSR $B08A
7E/B797: E6 10        INC $10
7E/B799: A5 10        LDA $10
7E/B79B: C9 4B 00     CMP #$004B
7E/B79E: D0 F4        BNE $B794
7E/B7A0: 20 8A B0     JSR $B08A
7E/B7A3: E2 20        SEP #$20
7E/B7A5: 60           RTS 
7E/B7A6: C2 20        REP #$20
7E/B7A8: A9 46 00     LDA #$0046
7E/B7AB: 85 10        STA $10
7E/B7AD: 20 67 B0     JSR $B067
7E/B7B0: E6 10        INC $10
7E/B7B2: A5 10        LDA $10
7E/B7B4: C9 4B 00     CMP #$004B
7E/B7B7: D0 F4        BNE $B7AD
7E/B7B9: 20 67 B0     JSR $B067
7E/B7BC: E2 20        SEP #$20
7E/B7BE: 60           RTS 
7E/B7BF: A9 7E        LDA #$7E
7E/B7C1: 85 D2        STA $D2
7E/B7C3: C2 20        REP #$20
7E/B7C5: AF 80 F1 7F  LDA $7FF180
7E/B7C9: 85 D0        STA $D0
7E/B7CB: E2 20        SEP #$20
7E/B7CD: 20 00 BB     JSR $BB00
7E/B7D0: C2 20        REP #$20
7E/B7D2: B0 05        BCS $B7D9
7E/B7D4: A9 00 70     LDA #$7000
7E/B7D7: 80 02        BRA $B7DB
7E/B7D9: A5 D0        LDA $D0
7E/B7DB: 8F 80 F1 7F  STA $7FF180
7E/B7DF: E2 20        SEP #$20
7E/B7E1: 60           RTS 
7E/B7E2: A9 7E        LDA #$7E
7E/B7E4: 85 D2        STA $D2
7E/B7E6: C2 20        REP #$20
7E/B7E8: AF 80 F1 7F  LDA $7FF180
7E/B7EC: 85 D0        STA $D0
7E/B7EE: E2 20        SEP #$20
7E/B7F0: 20 00 BB     JSR $BB00
7E/B7F3: C2 20        REP #$20
7E/B7F5: B0 05        BCS $B7FC
7E/B7F7: A9 00 60     LDA #$6000
7E/B7FA: 80 02        BRA $B7FE
7E/B7FC: A5 D0        LDA $D0
7E/B7FE: 8F 80 F1 7F  STA $7FF180
7E/B802: E2 20        SEP #$20
7E/B804: 60           RTS 
7E/B805: A9 7E        LDA #$7E
7E/B807: 85 D2        STA $D2
7E/B809: C2 20        REP #$20
7E/B80B: AF 80 F1 7F  LDA $7FF180
7E/B80F: 85 D0        STA $D0
7E/B811: E2 20        SEP #$20
7E/B813: 20 00 BB     JSR $BB00
7E/B816: C2 20        REP #$20
7E/B818: B0 05        BCS $B81F
7E/B81A: A9 00 68     LDA #$6800
7E/B81D: 80 02        BRA $B821
7E/B81F: A5 D0        LDA $D0
7E/B821: 8F 80 F1 7F  STA $7FF180
7E/B825: E2 20        SEP #$20
7E/B827: 60           RTS 
7E/B828: A9 7F        LDA #$7F
7E/B82A: 85 D2        STA $D2
7E/B82C: C2 20        REP #$20
7E/B82E: AF 80 F1 7F  LDA $7FF180
7E/B832: 85 D0        STA $D0
7E/B834: E2 20        SEP #$20
7E/B836: 20 00 BB     JSR $BB00
7E/B839: 90 0A        BCC $B845
7E/B83B: C2 20        REP #$20
7E/B83D: A5 D0        LDA $D0
7E/B83F: 8F 80 F1 7F  STA $7FF180
7E/B843: E2 20        SEP #$20
7E/B845: 60           RTS 
7E/B846: C2 20        REP #$20
7E/B848: A9 30 00     LDA #$0030
7E/B84B: 85 10        STA $10
7E/B84D: 20 AD B0     JSR $B0AD
7E/B850: E6 10        INC $10
7E/B852: A5 10        LDA $10
7E/B854: C9 36 00     CMP #$0036
7E/B857: D0 F4        BNE $B84D
7E/B859: 20 AD B0     JSR $B0AD
7E/B85C: A9 37 00     LDA #$0037
7E/B85F: 85 10        STA $10
7E/B861: 20 24 B1     JSR $B124
7E/B864: E6 10        INC $10
7E/B866: A5 10        LDA $10
7E/B868: C9 40 00     CMP #$0040
7E/B86B: D0 F4        BNE $B861
7E/B86D: 20 24 B1     JSR $B124
7E/B870: A5 44        LDA $44
7E/B872: 29 01 00     AND #$0001
7E/B875: D0 14        BNE $B88B
7E/B877: A9 41 00     LDA #$0041
7E/B87A: 85 10        STA $10
7E/B87C: 20 AD B0     JSR $B0AD
7E/B87F: E6 10        INC $10
7E/B881: A5 10        LDA $10
7E/B883: C9 4A 00     CMP #$004A
7E/B886: D0 F4        BNE $B87C
7E/B888: 20 AD B0     JSR $B0AD
7E/B88B: E2 20        SEP #$20
7E/B88D: 60           RTS 
7E/B88E: C2 20        REP #$20
7E/B890: A9 70 00     LDA #$0070
7E/B893: 85 10        STA $10
7E/B895: 20 AD B0     JSR $B0AD
7E/B898: E6 10        INC $10
7E/B89A: A5 10        LDA $10
7E/B89C: C9 72 00     CMP #$0072
7E/B89F: D0 F4        BNE $B895
7E/B8A1: 20 AD B0     JSR $B0AD
7E/B8A4: E2 20        SEP #$20
7E/B8A6: 60           RTS 
7E/B8A7: C2 20        REP #$20
7E/B8A9: A9 64 00     LDA #$0064
7E/B8AC: 85 10        STA $10
7E/B8AE: 20 FD B1     JSR $B1FD
7E/B8B1: E6 10        INC $10
7E/B8B3: A5 10        LDA $10
7E/B8B5: C9 7F 00     CMP #$007F
7E/B8B8: D0 F4        BNE $B8AE
7E/B8BA: 20 FD B1     JSR $B1FD
7E/B8BD: E2 20        SEP #$20
7E/B8BF: 60           RTS 
7E/B8C0: C2 20        REP #$20
7E/B8C2: A9 30 00     LDA #$0030
7E/B8C5: 85 10        STA $10
7E/B8C7: 20 FD B1     JSR $B1FD
7E/B8CA: E6 10        INC $10
7E/B8CC: A5 10        LDA $10
7E/B8CE: C9 43 00     CMP #$0043
7E/B8D1: D0 F4        BNE $B8C7
7E/B8D3: 20 FD B1     JSR $B1FD
7E/B8D6: E2 20        SEP #$20
7E/B8D8: 60           RTS 
7E/B8D9: C2 20        REP #$20
7E/B8DB: A9 4C 00     LDA #$004C
7E/B8DE: 85 10        STA $10
7E/B8E0: 20 FD B1     JSR $B1FD
7E/B8E3: E6 10        INC $10
7E/B8E5: A5 10        LDA $10
7E/B8E7: C9 63 00     CMP #$0063
7E/B8EA: D0 F4        BNE $B8E0
7E/B8EC: 20 FD B1     JSR $B1FD
7E/B8EF: E2 20        SEP #$20
7E/B8F1: 60           RTS 
7E/B8F2: A5 44        LDA $44
7E/B8F4: 29 07        AND #$07
7E/B8F6: D0 1D        BNE $B915
7E/B8F8: EB           XBA 
7E/B8F9: A5 46        LDA $46
7E/B8FB: AA           TAX 
7E/B8FC: BF C0 FE C0  LDA $C0FEC0,X   ; random number table
7E/B900: 29 07        AND #$07
7E/B902: AA           TAX 
7E/B903: BF B8 C7 7F  LDA $7FC7B8,X
7E/B907: 85 CA        STA $CA
7E/B909: 8A           TXA 
7E/B90A: 0A           ASL 
7E/B90B: AA           TAX 
7E/B90C: B5 60        LDA $60,X
7E/B90E: C5 CA        CMP $CA
7E/B910: F0 03        BEQ $B915
7E/B912: 1A           INC 
7E/B913: 95 60        STA $60,X
7E/B915: C2 20        REP #$20
7E/B917: A9 30 00     LDA #$0030
7E/B91A: 85 10        STA $10
7E/B91C: 20 67 B0     JSR $B067
7E/B91F: 20 67 B0     JSR $B067
7E/B922: A5 10        LDA $10
7E/B924: C5 60        CMP $60
7E/B926: F0 04        BEQ $B92C
7E/B928: E6 10        INC $10
7E/B92A: 80 F0        BRA $B91C
7E/B92C: A9 38 00     LDA #$0038
7E/B92F: 85 10        STA $10
7E/B931: 20 67 B0     JSR $B067
7E/B934: 20 67 B0     JSR $B067
7E/B937: 20 24 B1     JSR $B124
7E/B93A: A5 10        LDA $10
7E/B93C: C5 62        CMP $62
7E/B93E: F0 04        BEQ $B944
7E/B940: E6 10        INC $10
7E/B942: 80 ED        BRA $B931
7E/B944: A9 40 00     LDA #$0040
7E/B947: 85 10        STA $10
7E/B949: 20 67 B0     JSR $B067
7E/B94C: A5 10        LDA $10
7E/B94E: C5 64        CMP $64
7E/B950: F0 04        BEQ $B956
7E/B952: E6 10        INC $10
7E/B954: 80 F3        BRA $B949
7E/B956: A9 48 00     LDA #$0048
7E/B959: 85 10        STA $10
7E/B95B: 20 67 B0     JSR $B067
7E/B95E: 20 24 B1     JSR $B124
7E/B961: 20 24 B1     JSR $B124
7E/B964: A5 10        LDA $10
7E/B966: C5 66        CMP $66
7E/B968: F0 04        BEQ $B96E
7E/B96A: E6 10        INC $10
7E/B96C: 80 ED        BRA $B95B
7E/B96E: A5 44        LDA $44
7E/B970: 29 01 00     AND #$0001
7E/B973: D0 54        BNE $B9C9
7E/B975: A9 50 00     LDA #$0050
7E/B978: 85 10        STA $10
7E/B97A: 20 67 B0     JSR $B067
7E/B97D: A5 10        LDA $10
7E/B97F: C5 68        CMP $68
7E/B981: F0 04        BEQ $B987
7E/B983: E6 10        INC $10
7E/B985: 80 F3        BRA $B97A
7E/B987: A9 58 00     LDA #$0058
7E/B98A: 85 10        STA $10
7E/B98C: 20 24 B1     JSR $B124
7E/B98F: 20 67 B0     JSR $B067
7E/B992: A5 10        LDA $10
7E/B994: C5 6A        CMP $6A
7E/B996: F0 04        BEQ $B99C
7E/B998: E6 10        INC $10
7E/B99A: 80 F0        BRA $B98C
7E/B99C: A9 60 00     LDA #$0060
7E/B99F: 85 10        STA $10
7E/B9A1: 20 24 B1     JSR $B124
7E/B9A4: 20 67 B0     JSR $B067
7E/B9A7: A5 10        LDA $10
7E/B9A9: C5 6C        CMP $6C
7E/B9AB: F0 04        BEQ $B9B1
7E/B9AD: E6 10        INC $10
7E/B9AF: 80 F0        BRA $B9A1
7E/B9B1: A9 68 00     LDA #$0068
7E/B9B4: 85 10        STA $10
7E/B9B6: 20 24 B1     JSR $B124
7E/B9B9: 20 24 B1     JSR $B124
7E/B9BC: 20 67 B0     JSR $B067
7E/B9BF: A5 10        LDA $10
7E/B9C1: C5 6E        CMP $6E
7E/B9C3: F0 04        BEQ $B9C9
7E/B9C5: E6 10        INC $10
7E/B9C7: 80 ED        BRA $B9B6
7E/B9C9: E2 20        SEP #$20
7E/B9CB: 60           RTS 
7E/B9CC: C2 20        REP #$20
7E/B9CE: A9 60 00     LDA #$0060
7E/B9D1: 85 10        STA $10
7E/B9D3: 20 AD B0     JSR $B0AD
7E/B9D6: E6 10        INC $10
7E/B9D8: A5 10        LDA $10
7E/B9DA: C9 71 00     CMP #$0071
7E/B9DD: D0 F4        BNE $B9D3
7E/B9DF: 20 AD B0     JSR $B0AD
7E/B9E2: E2 20        SEP #$20
7E/B9E4: 60           RTS 
7E/B9E5: C2 20        REP #$20
7E/B9E7: A9 30 00     LDA #$0030
7E/B9EA: 85 10        STA $10
7E/B9EC: 20 AD B0     JSR $B0AD
7E/B9EF: E6 10        INC $10
7E/B9F1: A5 10        LDA $10
7E/B9F3: C9 3E 00     CMP #$003E
7E/B9F6: D0 F4        BNE $B9EC
7E/B9F8: 20 AD B0     JSR $B0AD
7E/B9FB: E2 20        SEP #$20
7E/B9FD: 60           RTS 
7E/B9FE: C2 20        REP #$20
7E/BA00: A9 60 00     LDA #$0060
7E/BA03: 85 10        STA $10
7E/BA05: 20 24 B1     JSR $B124
7E/BA08: E6 10        INC $10
7E/BA0A: A5 10        LDA $10
7E/BA0C: C9 74 00     CMP #$0074
7E/BA0F: D0 F4        BNE $BA05
7E/BA11: 20 24 B1     JSR $B124
7E/BA14: E2 20        SEP #$20
7E/BA16: 60           RTS 
7E/BA17: C2 20        REP #$20
7E/BA19: A9 30 00     LDA #$0030
7E/BA1C: 85 10        STA $10
7E/BA1E: 20 24 B1     JSR $B124
7E/BA21: A5 44        LDA $44
7E/BA23: 29 03 00     AND #$0003
7E/BA26: D0 03        BNE $BA2B
7E/BA28: 20 8A B0     JSR $B08A
7E/BA2B: E6 10        INC $10
7E/BA2D: A5 10        LDA $10
7E/BA2F: C9 40 00     CMP #$0040
7E/BA32: D0 EA        BNE $BA1E
7E/BA34: A5 44        LDA $44
7E/BA36: 29 03 00     AND #$0003
7E/BA39: D0 03        BNE $BA3E
7E/BA3B: 20 8A B0     JSR $B08A
7E/BA3E: 20 24 B1     JSR $B124
7E/BA41: E2 20        SEP #$20
7E/BA43: 60           RTS 
7E/BA44: C2 20        REP #$20
7E/BA46: A9 30 00     LDA #$0030
7E/BA49: 85 10        STA $10
7E/BA4B: 20 24 B1     JSR $B124
7E/BA4E: E6 10        INC $10
7E/BA50: A5 10        LDA $10
7E/BA52: C9 4D 00     CMP #$004D
7E/BA55: D0 F4        BNE $BA4B
7E/BA57: 20 24 B1     JSR $B124
7E/BA5A: E2 20        SEP #$20
7E/BA5C: 60           RTS 
7E/BA5D: A5 44        LDA $44
7E/BA5F: 29 03        AND #$03
7E/BA61: D0 22        BNE $BA85
7E/BA63: A9 7F        LDA #$7F
7E/BA65: 85 D2        STA $D2
7E/BA67: C2 20        REP #$20
7E/BA69: AF 80 F1 7F  LDA $7FF180
7E/BA6D: 85 D0        STA $D0
7E/BA6F: E2 20        SEP #$20
7E/BA71: 20 00 BB     JSR $BB00
7E/BA74: C2 20        REP #$20
7E/BA76: B0 05        BCS $BA7D
7E/BA78: A9 00 F2     LDA #$F200
7E/BA7B: 80 02        BRA $BA7F
7E/BA7D: A5 D0        LDA $D0
7E/BA7F: 8F 80 F1 7F  STA $7FF180
7E/BA83: E2 20        SEP #$20
7E/BA85: 60           RTS 
7E/BA86: A9 7F        LDA #$7F
7E/BA88: 85 D2        STA $D2
7E/BA8A: C2 20        REP #$20
7E/BA8C: AF 82 F1 7F  LDA $7FF182
7E/BA90: 85 D0        STA $D0
7E/BA92: E2 20        SEP #$20
7E/BA94: 20 00 BB     JSR $BB00
7E/BA97: C2 20        REP #$20
7E/BA99: B0 05        BCS $BAA0
7E/BA9B: A9 00 E8     LDA #$E800
7E/BA9E: 80 02        BRA $BAA2
7E/BAA0: A5 D0        LDA $D0
7E/BAA2: 8F 82 F1 7F  STA $7FF182
7E/BAA6: E2 20        SEP #$20
7E/BAA8: 60           RTS 
7E/BAA9: A4 C7        LDY $C7
7E/BAAB: C2 20        REP #$20
7E/BAAD: B7 D0        LDA [$D0],Y
7E/BAAF: 89 80 00     BIT #$0080
7E/BAB2: F0 0A        BEQ $BABE
7E/BAB4: 25 C6        AND $C6
7E/BAB6: C9 8F 00     CMP #$008F
7E/BAB9: F0 1D        BEQ $BAD8
7E/BABB: E2 20        SEP #$20
7E/BABD: 60           RTS 
7E/BABE: 85 10        STA $10
7E/BAC0: C8           INY 
7E/BAC1: B7 D0        LDA [$D0],Y
7E/BAC3: 85 14        STA $14
7E/BAC5: C8           INY 
7E/BAC6: C8           INY 
7E/BAC7: B7 D0        LDA [$D0],Y
7E/BAC9: 85 12        STA $12
7E/BACB: C8           INY 
7E/BACC: C8           INY 
7E/BACD: B7 D0        LDA [$D0],Y
7E/BACF: 85 16        STA $16
7E/BAD1: C8           INY 
7E/BAD2: C8           INY 
7E/BAD3: 20 FF AF     JSR $AFFF
7E/BAD6: 80 D5        BRA $BAAD
7E/BAD8: E2 20        SEP #$20
7E/BADA: E6 10        INC $10
7E/BADC: C8           INY 
7E/BADD: B7 D0        LDA [$D0],Y
7E/BADF: 18           CLC 
7E/BAE0: 65 14        ADC $14
7E/BAE2: 85 14        STA $14
7E/BAE4: C8           INY 
7E/BAE5: B7 D0        LDA [$D0],Y
7E/BAE7: 18           CLC 
7E/BAE8: 65 15        ADC $15
7E/BAEA: 85 15        STA $15
7E/BAEC: C8           INY 
7E/BAED: C2 20        REP #$20
7E/BAEF: B7 D0        LDA [$D0],Y
7E/BAF1: 85 12        STA $12
7E/BAF3: C8           INY 
7E/BAF4: C8           INY 
7E/BAF5: B7 D0        LDA [$D0],Y
7E/BAF7: 85 16        STA $16
7E/BAF9: C8           INY 
7E/BAFA: C8           INY 
7E/BAFB: 20 FF AF     JSR $AFFF
7E/BAFE: 80 AD        BRA $BAAD
7E/BB00: A4 C7        LDY $C7
7E/BB02: B7 D0        LDA [$D0],Y
7E/BB04: 10 5B        BPL $BB61
7E/BB06: 89 40 D0     BIT #$D040
7E/BB09: 24 C9        BIT $C9
7E/BB0B: 8F D0 06 E6  STA $E606D0
7E/BB0F: 10 C2        BPL $BAD3
7E/BB11: 20 80 51     JSR $5180
7E/BB14: C9 82 D0     CMP #$D082
7E/BB17: 06 20        ASL $20
7E/BB19: A1 AF        LDA ($AF,X)
7E/BB1B: C8           INY 
7E/BB1C: 80 E4        BRA $BB02
7E/BB1E: 48           PHA 
7E/BB1F: C8           INY 
7E/BB20: C2 20        REP #$20
7E/BB22: 98           TYA 
7E/BB23: 18           CLC 
7E/BB24: 65 D0        ADC $D0
7E/BB26: 85 D0        STA $D0
7E/BB28: E2 20        SEP #$20
7E/BB2A: 68           PLA 
7E/BB2B: C9 81        CMP #$81
7E/BB2D: 60           RTS 
7E/BB2E: 89 20        BIT #$20
7E/BB30: D0 14        BNE $BB46
7E/BB32: C2 20        REP #$20
7E/BB34: 29 07 00     AND #$0007
7E/BB37: 0A           ASL 
7E/BB38: AA           TAX 
7E/BB39: C8           INY 
7E/BB3A: 98           TYA 
7E/BB3B: 18           CLC 
7E/BB3C: 65 D0        ADC $D0
7E/BB3E: 9F 38 F1 7F  STA $7FF138,X
7E/BB42: E2 20        SEP #$20
7E/BB44: 80 BC        BRA $BB02
7E/BB46: A6 D0        LDX $D0
7E/BB48: DA           PHX 
7E/BB49: C2 20        REP #$20
7E/BB4B: 29 07 00     AND #$0007
7E/BB4E: 0A           ASL 
7E/BB4F: AA           TAX 
7E/BB50: BF 38 F1 7F  LDA $7FF138,X
7E/BB54: 85 D0        STA $D0
7E/BB56: E2 20        SEP #$20
7E/BB58: 20 00 BB     JSR $BB00
7E/BB5B: FA           PLX 
7E/BB5C: E8           INX 
7E/BB5D: 86 D0        STX $D0
7E/BB5F: 38           SEC 
7E/BB60: 60           RTS 
7E/BB61: C2 20        REP #$20
7E/BB63: 85 10        STA $10
7E/BB65: C8           INY 
7E/BB66: B7 D0        LDA [$D0],Y
7E/BB68: 85 14        STA $14
7E/BB6A: C8           INY 
7E/BB6B: C8           INY 
7E/BB6C: B7 D0        LDA [$D0],Y
7E/BB6E: 85 12        STA $12
7E/BB70: C8           INY 
7E/BB71: C8           INY 
7E/BB72: 20 46 B0     JSR $B046
7E/BB75: E2 20        SEP #$20
7E/BB77: 80 89        BRA $BB02
7E/BB79: A9 7E        LDA #$7E
7E/BB7B: 85 28        STA $28
7E/BB7D: A2 00 D0     LDX #$D000
7E/BB80: 86 26        STX $26
7E/BB82: A6 C7        LDX $C7
7E/BB84: 86 22        STX $22
7E/BB86: A9 C3        LDA #$C3
7E/BB88: 85 D2        STA $D2
7E/BB8A: A2 2B 36     LDX #$362B
7E/BB8D: 86 D0        STX $D0
7E/BB8F: A9 7E        LDA #$7E
7E/BB91: 85 D5        STA $D5
7E/BB93: A2 00 D0     LDX #$D000
7E/BB96: 86 D3        STX $D3
7E/BB98: 20 0D C0     JSR $C00D
7E/BB9B: A9 C3        LDA #$C3
7E/BB9D: 85 D2        STA $D2
7E/BB9F: A2 F6 33     LDX #$33F6
7E/BBA2: 86 D0        STX $D0
7E/BBA4: A9 7E        LDA #$7E
7E/BBA6: 85 D5        STA $D5
7E/BBA8: A2 00 48     LDX #$4800
7E/BBAB: 86 D3        STX $D3
7E/BBAD: 82 5D 04     BRL $C00D
7E/BBB0: A2 00 20     LDX #$2000
7E/BBB3: 86 D3        STX $D3
7E/BBB5: A9 7E        LDA #$7E
7E/BBB7: 85 D5        STA $D5
7E/BBB9: A2 00 08     LDX #$0800
7E/BBBC: 86 D6        STX $D6
7E/BBBE: 20 E0 C1     JSR $C1E0
7E/BBC1: A9 27        LDA #$27
7E/BBC3: 85 20        STA $20
7E/BBC5: A9 10        LDA #$10
7E/BBC7: 04 4F        TSB $4F
7E/BBC9: 60           RTS 
7E/BBCA: A2 00 28     LDX #$2800
7E/BBCD: 86 D3        STX $D3
7E/BBCF: A9 7E        LDA #$7E
7E/BBD1: 85 D5        STA $D5
7E/BBD3: A2 00 08     LDX #$0800
7E/BBD6: 86 D6        STX $D6
7E/BBD8: 20 E0 C1     JSR $C1E0
7E/BBDB: A9 20        LDA #$20
7E/BBDD: 04 4F        TSB $4F
7E/BBDF: A9 10        LDA #$10
7E/BBE1: 14 4F        TRB $4F
7E/BBE3: 60           RTS 
7E/BBE4: A2 00 30     LDX #$3000
7E/BBE7: 86 D3        STX $D3
7E/BBE9: A9 7E        LDA #$7E
7E/BBEB: 85 D5        STA $D5
7E/BBED: A2 00 08     LDX #$0800
7E/BBF0: 86 D6        STX $D6
7E/BBF2: 20 E0 C1     JSR $C1E0
7E/BBF5: A9 40        LDA #$40
7E/BBF7: 04 4F        TSB $4F
7E/BBF9: A9 20        LDA #$20
7E/BBFB: 14 4F        TRB $4F
7E/BBFD: 60           RTS 
7E/BBFE: A9 7E        LDA #$7E
7E/BC00: 85 28        STA $28
7E/BC02: A2 00 D0     LDX #$D000
7E/BC05: 86 26        STX $26
7E/BC07: A9 C3        LDA #$C3
7E/BC09: 85 D2        STA $D2
7E/BC0B: A2 92 7B     LDX #$7B92
7E/BC0E: 86 D0        STX $D0
7E/BC10: A9 7E        LDA #$7E
7E/BC12: 85 D5        STA $D5
7E/BC14: A2 00 D0     LDX #$D000
7E/BC17: 86 D3        STX $D3
7E/BC19: 20 0D C0     JSR $C00D
7E/BC1C: 20 3E BC     JSR $BC3E
7E/BC1F: A2 00 40     LDX #$4000
7E/BC22: 86 B8        STX $B8
7E/BC24: A9 7E        LDA #$7E
7E/BC26: 85 BC        STA $BC
7E/BC28: A2 00 48     LDX #$4800
7E/BC2B: 86 BA        STX $BA
7E/BC2D: A2 00 10     LDX #$1000
7E/BC30: 86 BD        STX $BD
7E/BC32: 20 A3 C1     JSR $C1A3
7E/BC35: A9 40        LDA #$40
7E/BC37: 85 7E        STA $7E
7E/BC39: 64 25        STZ $25
7E/BC3B: 64 22        STZ $22
7E/BC3D: 60           RTS 
7E/BC3E: 8B           PHB 
7E/BC3F: A9 7E        LDA #$7E
7E/BC41: 48           PHA 
7E/BC42: AB           PLB 
7E/BC43: A2 00 48     LDX #$4800
7E/BC46: 86 C0        STX $C0
7E/BC48: A6 C7        LDX $C7
7E/BC4A: 9B           TXY 
7E/BC4B: E8           INX 
7E/BC4C: BF F0 F1 D1  LDA $D1F1F0,X
7E/BC50: 91 C0        STA ($C0),Y
7E/BC52: C8           INY 
7E/BC53: A5 C7        LDA $C7
7E/BC55: 91 C0        STA ($C0),Y
7E/BC57: C8           INY 
7E/BC58: E8           INX 
7E/BC59: 8A           TXA 
7E/BC5A: 29 0F        AND #$0F
7E/BC5C: D0 ED        BNE $BC4B
7E/BC5E: A5 C7        LDA $C7
7E/BC60: 91 C0        STA ($C0),Y
7E/BC62: C8           INY 
7E/BC63: C0 00 10     CPY #$1000
7E/BC66: F0 07        BEQ $BC6F
7E/BC68: 98           TYA 
7E/BC69: 29 0F        AND #$0F
7E/BC6B: D0 F1        BNE $BC5E
7E/BC6D: 80 DC        BRA $BC4B
7E/BC6F: AB           PLB 
7E/BC70: 60           RTS 
7E/BC71: 48           PHA 
7E/BC72: A9 10        LDA #$10
7E/BC74: 09 20        ORA #$20
7E/BC76: 09 40        ORA #$40
7E/BC78: 09 80        ORA #$80
7E/BC7A: 14 4F        TRB $4F
7E/BC7C: 68           PLA 
7E/BC7D: C9 00        CMP #$00
7E/BC7F: D0 04        BNE $BC85
7E/BC81: A9 10        LDA #$10
7E/BC83: 80 10        BRA $BC95
7E/BC85: C9 01        CMP #$01
7E/BC87: D0 04        BNE $BC8D
7E/BC89: A9 20        LDA #$20
7E/BC8B: 80 08        BRA $BC95
7E/BC8D: C9 02        CMP #$02
7E/BC8F: D0 06        BNE $BC97
7E/BC91: A9 40        LDA #$40
7E/BC93: 80 00        BRA $BC95
7E/BC95: 04 4F        TSB $4F
7E/BC97: E6 20        INC $20
7E/BC99: 60           RTS 
7E/BC9A: C2 20        REP #$20
7E/BC9C: 29 FF 00     AND #$00FF
7E/BC9F: EB           XBA 
7E/BCA0: 0A           ASL 
7E/BCA1: 0A           ASL 
7E/BCA2: 85 08        STA $08
7E/BCA4: 0A           ASL 
7E/BCA5: 18           CLC 
7E/BCA6: 69 00 20     ADC #$2000
7E/BCA9: 8D 72 43     STA $4372
7E/BCAC: A9 00 08     LDA #$0800
7E/BCAF: 8D 75 43     STA $4375
7E/BCB2: A5 08        LDA $08
7E/BCB4: 18           CLC 
7E/BCB5: 69 00 40     ADC #$4000
7E/BCB8: 8D 16 21     STA $2116
7E/BCBB: E2 20        SEP #$20
7E/BCBD: A9 01        LDA #$01
7E/BCBF: 8D 70 43     STA $4370
7E/BCC2: A9 18        LDA #$18
7E/BCC4: 8D 71 43     STA $4371
7E/BCC7: A9 7E        LDA #$7E
7E/BCC9: 8D 74 43     STA $4374
7E/BCCC: A9 80        LDA #$80
7E/BCCE: 8D 15 21     STA $2115
7E/BCD1: A9 80        LDA #$80
7E/BCD3: 8D 0B 42     STA $420B
7E/BCD6: 60           RTS 
7E/BCD7: 85 24        STA $24
7E/BCD9: C2 20        REP #$20
7E/BCDB: 25 C6        AND $C6
7E/BCDD: 0A           ASL 
7E/BCDE: AA           TAX 
7E/BCDF: BF B0 C7 7F  LDA $7FC7B0,X
7E/BCE3: 4A           LSR 
7E/BCE4: 4A           LSR 
7E/BCE5: 4A           LSR 
7E/BCE6: 4A           LSR 
7E/BCE7: 4A           LSR 
7E/BCE8: 85 22        STA $22
7E/BCEA: E2 20        SEP #$20
7E/BCEC: 64 25        STZ $25
7E/BCEE: A7 26        LDA [$26]
7E/BCF0: 29 0F        AND #$0F
7E/BCF2: D0 05        BNE $BCF9
7E/BCF4: 64 20        STZ $20
7E/BCF6: 64 21        STZ $21
7E/BCF8: 60           RTS 
7E/BCF9: A6 26        LDX $26
7E/BCFB: E8           INX 
7E/BCFC: 86 26        STX $26
7E/BCFE: A7 26        LDA [$26]
7E/BD00: 10 1B        BPL $BD1D
7E/BD02: C9 86        CMP #$86
7E/BD04: D0 11        BNE $BD17
7E/BD06: A6 26        LDX $26
7E/BD08: E8           INX 
7E/BD09: 86 26        STX $26
7E/BD0B: A6 C7        LDX $C7
7E/BD0D: 86 22        STX $22
7E/BD0F: 20 AF BF     JSR $BFAF
7E/BD12: A9 08        LDA #$08
7E/BD14: 85 20        STA $20
7E/BD16: 60           RTS 
7E/BD17: 20 AF BF     JSR $BFAF
7E/BD1A: E6 20        INC $20
7E/BD1C: 60           RTS 
7E/BD1D: D0 06        BNE $BD25
7E/BD1F: E6 22        INC $22
7E/BD21: E6 25        INC $25
7E/BD23: 80 D4        BRA $BCF9
7E/BD25: 20 B3 BD     JSR $BDB3
7E/BD28: 80 CF        BRA $BCF9
7E/BD2A: A7 26        LDA [$26]
7E/BD2C: 29 0F        AND #$0F
7E/BD2E: D0 05        BNE $BD35
7E/BD30: 64 20        STZ $20
7E/BD32: 64 21        STZ $21
7E/BD34: 60           RTS 
7E/BD35: A6 26        LDX $26
7E/BD37: E8           INX 
7E/BD38: 86 26        STX $26
7E/BD3A: A7 26        LDA [$26]
7E/BD3C: 10 25        BPL $BD63
7E/BD3E: C9 86        CMP #$86
7E/BD40: D0 13        BNE $BD55
7E/BD42: A6 26        LDX $26
7E/BD44: E8           INX 
7E/BD45: 86 26        STX $26
7E/BD47: 20 88 BD     JSR $BD88
7E/BD4A: 64 22        STZ $22
7E/BD4C: 64 25        STZ $25
7E/BD4E: A9 40        LDA #$40
7E/BD50: 85 7E        STA $7E
7E/BD52: E6 20        INC $20
7E/BD54: 60           RTS 
7E/BD55: 20 88 BD     JSR $BD88
7E/BD58: 64 25        STZ $25
7E/BD5A: A5 7E        LDA $7E
7E/BD5C: 18           CLC 
7E/BD5D: 69 0C        ADC #$0C
7E/BD5F: 85 7E        STA $7E
7E/BD61: 80 C7        BRA $BD2A
7E/BD63: 20 6C BD     JSR $BD6C
7E/BD66: E6 22        INC $22
7E/BD68: E6 25        INC $25
7E/BD6A: 80 C9        BRA $BD35
7E/BD6C: C2 20        REP #$20
7E/BD6E: 25 C6        AND $C6
7E/BD70: 09 00 38     ORA #$3800
7E/BD73: 85 12        STA $12
7E/BD75: A5 22        LDA $22
7E/BD77: 85 10        STA $10
7E/BD79: A5 C7        LDA $C7
7E/BD7B: 85 16        STA $16
7E/BD7D: A5 7E        LDA $7E
7E/BD7F: EB           XBA 
7E/BD80: 85 14        STA $14
7E/BD82: 20 FF AF     JSR $AFFF
7E/BD85: E2 20        SEP #$20
7E/BD87: 60           RTS 
7E/BD88: A5 25        LDA $25
7E/BD8A: 0A           ASL 
7E/BD8B: 0A           ASL 
7E/BD8C: 0A           ASL 
7E/BD8D: 85 18        STA $18
7E/BD8F: A9 FF        LDA #$FF
7E/BD91: 38           SEC 
7E/BD92: E5 18        SBC $18
7E/BD94: 4A           LSR 
7E/BD95: 85 14        STA $14
7E/BD97: A5 22        LDA $22
7E/BD99: 38           SEC 
7E/BD9A: E5 25        SBC $25
7E/BD9C: 85 10        STA $10
7E/BD9E: 20 35 B0     JSR $B035
7E/BDA1: A5 10        LDA $10
7E/BDA3: C5 22        CMP $22
7E/BDA5: F0 0B        BEQ $BDB2
7E/BDA7: A5 14        LDA $14
7E/BDA9: 18           CLC 
7E/BDAA: 69 08        ADC #$08
7E/BDAC: 85 14        STA $14
7E/BDAE: E6 10        INC $10
7E/BDB0: 80 EC        BRA $BD9E
7E/BDB2: 60           RTS 
7E/BDB3: C2 20        REP #$20
7E/BDB5: 25 C6        AND $C6
7E/BDB7: 85 18        STA $18
7E/BDB9: 4A           LSR 
7E/BDBA: 4A           LSR 
7E/BDBB: 4A           LSR 
7E/BDBC: 4A           LSR 
7E/BDBD: 0A           ASL 
7E/BDBE: 0A           ASL 
7E/BDBF: 0A           ASL 
7E/BDC0: 0A           ASL 
7E/BDC1: 0A           ASL 
7E/BDC2: 0A           ASL 
7E/BDC3: 0A           ASL 
7E/BDC4: 0A           ASL 
7E/BDC5: 0A           ASL 
7E/BDC6: 0A           ASL 
7E/BDC7: 85 1E        STA $1E
7E/BDC9: A5 18        LDA $18
7E/BDCB: 29 0F 00     AND #$000F
7E/BDCE: 0A           ASL 
7E/BDCF: 0A           ASL 
7E/BDD0: 0A           ASL 
7E/BDD1: 0A           ASL 
7E/BDD2: 0A           ASL 
7E/BDD3: 18           CLC 
7E/BDD4: 65 1E        ADC $1E
7E/BDD6: 18           CLC 
7E/BDD7: 69 00 48     ADC #$4800
7E/BDDA: 85 D0        STA $D0
7E/BDDC: A5 22        LDA $22
7E/BDDE: 4A           LSR 
7E/BDDF: 4A           LSR 
7E/BDE0: 4A           LSR 
7E/BDE1: 4A           LSR 
7E/BDE2: 0A           ASL 
7E/BDE3: 0A           ASL 
7E/BDE4: 0A           ASL 
7E/BDE5: 0A           ASL 
7E/BDE6: 0A           ASL 
7E/BDE7: 0A           ASL 
7E/BDE8: 0A           ASL 
7E/BDE9: 0A           ASL 
7E/BDEA: 0A           ASL 
7E/BDEB: 0A           ASL 
7E/BDEC: 85 1E        STA $1E
7E/BDEE: A5 22        LDA $22
7E/BDF0: 29 0F 00     AND #$000F
7E/BDF3: 0A           ASL 
7E/BDF4: 0A           ASL 
7E/BDF5: 0A           ASL 
7E/BDF6: 0A           ASL 
7E/BDF7: 0A           ASL 
7E/BDF8: 18           CLC 
7E/BDF9: 65 1E        ADC $1E
7E/BDFB: 18           CLC 
7E/BDFC: 69 00 20     ADC #$2000
7E/BDFF: 85 D3        STA $D3
7E/BE01: A9 20 00     LDA #$0020
7E/BE04: 85 D6        STA $D6
7E/BE06: E2 20        SEP #$20
7E/BE08: A9 7E        LDA #$7E
7E/BE0A: 85 D2        STA $D2
7E/BE0C: A9 7E        LDA #$7E
7E/BE0E: 85 D5        STA $D5
7E/BE10: 20 CC C1     JSR $C1CC
7E/BE13: C2 20        REP #$20
7E/BE15: A5 D0        LDA $D0
7E/BE17: 18           CLC 
7E/BE18: 69 00 02     ADC #$0200
7E/BE1B: 85 D0        STA $D0
7E/BE1D: A5 D3        LDA $D3
7E/BE1F: 18           CLC 
7E/BE20: 69 00 02     ADC #$0200
7E/BE23: 85 D3        STA $D3
7E/BE25: A9 20 00     LDA #$0020
7E/BE28: 85 D6        STA $D6
7E/BE2A: E6 22        INC $22
7E/BE2C: E2 20        SEP #$20
7E/BE2E: 20 CC C1     JSR $C1CC
7E/BE31: E6 25        INC $25
7E/BE33: 60           RTS 
7E/BE34: A9 C3        LDA #$C3
7E/BE36: 85 D2        STA $D2
7E/BE38: A2 3C 38     LDX #$383C
7E/BE3B: 86 D0        STX $D0
7E/BE3D: A9 7E        LDA #$7E
7E/BE3F: 85 D5        STA $D5
7E/BE41: A2 00 90     LDX #$9000
7E/BE44: 86 D3        STX $D3
7E/BE46: 20 0D C0     JSR $C00D
7E/BE49: A9 7E        LDA #$7E
7E/BE4B: 85 D2        STA $D2
7E/BE4D: A2 00 90     LDX #$9000
7E/BE50: 86 D0        STX $D0
7E/BE52: 82 54 FC     BRL $BAA9
7E/BE55: C2 20        REP #$20
7E/BE57: 25 C6        AND $C6
7E/BE59: C9 03 00     CMP #$0003
7E/BE5C: F0 1B        BEQ $BE79
7E/BE5E: EB           XBA 
7E/BE5F: 0A           ASL 
7E/BE60: 0A           ASL 
7E/BE61: 0A           ASL 
7E/BE62: 18           CLC 
7E/BE63: 69 00 20     ADC #$2000
7E/BE66: 85 D3        STA $D3
7E/BE68: E2 20        SEP #$20
7E/BE6A: A9 7E        LDA #$7E
7E/BE6C: 85 D5        STA $D5
7E/BE6E: A2 00 08     LDX #$0800
7E/BE71: 86 D6        STX $D6
7E/BE73: 20 E0 C1     JSR $C1E0
7E/BE76: E6 20        INC $20
7E/BE78: 60           RTS 
7E/BE79: E2 20        SEP #$20
7E/BE7B: E6 20        INC $20
7E/BE7D: 60           RTS 
7E/BE7E: A5 44        LDA $44
7E/BE80: 29 01        AND #$01
7E/BE82: F0 01        BEQ $BE85
7E/BE84: 60           RTS 
7E/BE85: A9 01        LDA #$01
7E/BE87: 85 2A        STA $2A
7E/BE89: A5 20        LDA $20
7E/BE8B: C9 04        CMP #$04
7E/BE8D: B0 03        BCS $BE92
7E/BE8F: 82 C3 FF     BRL $BE55
7E/BE92: C9 08        CMP #$08
7E/BE94: D0 03        BNE $BE99
7E/BE96: 82 A2 00     BRL $BF3B
7E/BE99: B0 06        BCS $BEA1
7E/BE9B: 38           SEC 
7E/BE9C: E9 04        SBC #$04
7E/BE9E: 82 36 FE     BRL $BCD7
7E/BEA1: C9 27        CMP #$27
7E/BEA3: B0 03        BCS $BEA8
7E/BEA5: 82 73 00     BRL $BF1B
7E/BEA8: C9 2A        CMP #$2A
7E/BEAA: B0 0C        BCS $BEB8
7E/BEAC: 38           SEC 
7E/BEAD: E9 27        SBC #$27
7E/BEAF: 20 71 BC     JSR $BC71
7E/BEB2: 20 C8 BF     JSR $BFC8
7E/BEB5: 64 2A        STZ $2A
7E/BEB7: 60           RTS 
7E/BEB8: C9 2A        CMP #$2A
7E/BEBA: D0 03        BNE $BEBF
7E/BEBC: 82 B1 00     BRL $BF70
7E/BEBF: C9 FF        CMP #$FF
7E/BEC1: D0 03        BNE $BEC6
7E/BEC3: E6 20        INC $20
7E/BEC5: 60           RTS 
7E/BEC6: C9 50        CMP #$50
7E/BEC8: 90 02        BCC $BECC
7E/BECA: 64 2A        STZ $2A
7E/BECC: 20 28 BF     JSR $BF28
7E/BECF: E6 20        INC $20
7E/BED1: 60           RTS 
7E/BED2: A5 44        LDA $44
7E/BED4: 29 01        AND #$01
7E/BED6: D0 0B        BNE $BEE3
7E/BED8: A9 01        LDA #$01
7E/BEDA: 85 2A        STA $2A
7E/BEDC: A5 20        LDA $20
7E/BEDE: D0 04        BNE $BEE4
7E/BEE0: 20 3B BF     JSR $BF3B
7E/BEE3: 60           RTS 
7E/BEE4: C9 20        CMP #$20
7E/BEE6: B0 03        BCS $BEEB
7E/BEE8: 82 30 00     BRL $BF1B
7E/BEEB: C9 20        CMP #$20
7E/BEED: D0 08        BNE $BEF7
7E/BEEF: 20 C1 AF     JSR $AFC1
7E/BEF2: 64 2A        STZ $2A
7E/BEF4: E6 20        INC $20
7E/BEF6: 60           RTS 
7E/BEF7: C9 21        CMP #$21
7E/BEF9: D0 06        BNE $BF01
7E/BEFB: 20 2A BD     JSR $BD2A
7E/BEFE: 64 2A        STZ $2A
7E/BF00: 60           RTS 
7E/BF01: C9 22        CMP #$22
7E/BF03: D0 03        BNE $BF08
7E/BF05: 82 68 00     BRL $BF70
7E/BF08: C9 FF        CMP #$FF
7E/BF0A: D0 03        BNE $BF0F
7E/BF0C: E6 20        INC $20
7E/BF0E: 60           RTS 
7E/BF0F: C9 52        CMP #$52
7E/BF11: 90 02        BCC $BF15
7E/BF13: 64 2A        STZ $2A
7E/BF15: 20 28 BF     JSR $BF28
7E/BF18: E6 20        INC $20
7E/BF1A: 60           RTS 
7E/BF1B: A9 04        LDA #$04
7E/BF1D: 20 37 AE     JSR $AE37
7E/BF20: A9 05        LDA #$05
7E/BF22: 20 37 AE     JSR $AE37
7E/BF25: E6 20        INC $20
7E/BF27: 60           RTS 
7E/BF28: A9 04        LDA #$04
7E/BF2A: 20 01 AE     JSR $AE01
7E/BF2D: A9 05        LDA #$05
7E/BF2F: 20 01 AE     JSR $AE01
7E/BF32: A5 44        LDA $44
7E/BF34: 29 07        AND #$07
7E/BF36: D0 02        BNE $BF3A
7E/BF38: E6 20        INC $20
7E/BF3A: 60           RTS 
7E/BF3B: A9 E0        LDA #$E0
7E/BF3D: 8F 09 F1 7F  STA $7FF109
7E/BF41: A9 C0        LDA #$C0
7E/BF43: 8F 0B F1 7F  STA $7FF10B
7E/BF47: C2 20        REP #$20
7E/BF49: A9 00 F0     LDA #$F000
7E/BF4C: 8F 18 F1 7F  STA $7FF118
7E/BF50: A9 20 00     LDA #$0020
7E/BF53: 8F 28 F1 7F  STA $7FF128
7E/BF57: A9 00 F4     LDA #$F400
7E/BF5A: 8F 1A F1 7F  STA $7FF11A
7E/BF5E: A9 20 00     LDA #$0020
7E/BF61: 8F 2A F1 7F  STA $7FF12A
7E/BF65: E2 20        SEP #$20
7E/BF67: A9 10        LDA #$10
7E/BF69: 09 20        ORA #$20
7E/BF6B: 04 74        TSB $74
7E/BF6D: E6 20        INC $20
7E/BF6F: 60           RTS 
7E/BF70: A9 10        LDA #$10
7E/BF72: 09 20        ORA #$20
7E/BF74: 09 40        ORA #$40
7E/BF76: 09 80        ORA #$80
7E/BF78: 14 4F        TRB $4F
7E/BF7A: A9 E0        LDA #$E0
7E/BF7C: 8F 09 F1 7F  STA $7FF109
7E/BF80: A9 C0        LDA #$C0
7E/BF82: 8F 0B F1 7F  STA $7FF10B
7E/BF86: C2 20        REP #$20
7E/BF88: A9 E0 F3     LDA #$F3E0
7E/BF8B: 8F 18 F1 7F  STA $7FF118
7E/BF8F: A9 20 00     LDA #$0020
7E/BF92: 8F 28 F1 7F  STA $7FF128
7E/BF96: A9 E0 F7     LDA #$F7E0
7E/BF99: 8F 1A F1 7F  STA $7FF11A
7E/BF9D: A9 20 00     LDA #$0020
7E/BFA0: 8F 2A F1 7F  STA $7FF12A
7E/BFA4: E2 20        SEP #$20
7E/BFA6: A9 10        LDA #$10
7E/BFA8: 09 20        ORA #$20
7E/BFAA: 04 74        TSB $74
7E/BFAC: E6 20        INC $20
7E/BFAE: 60           RTS 

7E/BFAF: A5 24        LDA $24
7E/BFB1: E2 10        SEP #$10
7E/BFB3: AA           TAX 
7E/BFB4: A5 25        LDA $25
7E/BFB6: 0A           ASL 
7E/BFB7: 0A           ASL 
7E/BFB8: 0A           ASL 
7E/BFB9: 85 18        STA $18
7E/BFBB: A5 C6        LDA $C6
7E/BFBD: 38           SEC 
7E/BFBE: E5 18        SBC $18
7E/BFC0: 4A           LSR 
7E/BFC1: 9F 34 F1 7F  STA $7FF134,X
7E/BFC5: C2 10        REP #$10
7E/BFC7: 60           RTS 
7E/BFC8: A9 00        LDA #$00
7E/BFCA: 85 24        STA $24
7E/BFCC: AF 34 F1 7F  LDA $7FF134
7E/BFD0: 20 F4 BF     JSR $BFF4
7E/BFD3: A9 0C        LDA #$0C
7E/BFD5: 85 24        STA $24
7E/BFD7: AF 35 F1 7F  LDA $7FF135
7E/BFDB: 20 F4 BF     JSR $BFF4
7E/BFDE: A9 18        LDA #$18
7E/BFE0: 85 24        STA $24
7E/BFE2: AF 36 F1 7F  LDA $7FF136
7E/BFE6: 20 F4 BF     JSR $BFF4
7E/BFE9: A9 24        LDA #$24
7E/BFEB: 85 24        STA $24
7E/BFED: AF 37 F1 7F  LDA $7FF137
7E/BFF1: 82 00 00     BRL $BFF4
7E/BFF4: 85 14        STA $14
7E/BFF6: A0 0C 00     LDY #$000C
7E/BFF9: A5 24        LDA $24
7E/BFFB: 85 10        STA $10
7E/BFFD: 20 35 B0     JSR $B035
7E/C000: A5 14        LDA $14
7E/C002: 18           CLC 
7E/C003: 69 10        ADC #$10
7E/C005: 85 14        STA $14
7E/C007: E6 10        INC $10
7E/C009: 88           DEY 
7E/C00A: D0 F1        BNE $BFFD
7E/C00C: 60           RTS 

; [ decompress ]

; ++$D0: source
; ++$D3: destination

7E/C00D: A7 D0        LDA [$D0]       ; get compression mode
7E/C00F: A6 D0        LDX $D0
7E/C011: E8           INX 
7E/C012: 86 D0        STX $D0
7E/C014: 48           PHA 
7E/C015: 29 F0        AND #$F0
7E/C017: F0 23        BEQ $C03C
7E/C019: 68           PLA 
7E/C01A: 29 0F        AND #$0F
7E/C01C: D0 0F        BNE $C02D
7E/C01E: C2 20        REP #$20
7E/C020: A7 D0        LDA [$D0]
7E/C022: 85 D6        STA $D6
7E/C024: E6 D0        INC $D0
7E/C026: E6 D0        INC $D0
7E/C028: E2 20        SEP #$20
7E/C02A: 82 9F 01     BRL $C1CC       ; no compression
7E/C02D: C9 01        CMP #$01
7E/C02F: D0 03        BNE $C034
7E/C031: 82 6D 00     BRL $C0A1       ; rle compression (high nybble set)
7E/C034: C9 02        CMP #$02
7E/C036: D0 03        BNE $C03B
7E/C038: 82 B5 00     BRL $C0F0       ; lzss compression
7E/C03B: 60           RTS 
7E/C03C: 68           PLA 
7E/C03D: D0 0F        BNE $C04E
7E/C03F: C2 20        REP #$20
7E/C041: A7 D0        LDA [$D0]
7E/C043: 85 D6        STA $D6         ; compressed length
7E/C045: E6 D0        INC $D0
7E/C047: E6 D0        INC $D0
7E/C049: E2 20        SEP #$20
7E/C04B: 82 7E 01     BRL $C1CC       ; no compression
7E/C04E: C9 01        CMP #$01
7E/C050: D0 03        BNE $C055
7E/C052: 82 08 00     BRL $C05D       ; rle compression (high nybble clear)
7E/C055: C9 02        CMP #$02
7E/C057: D0 03        BNE $C05C
7E/C059: 82 94 00     BRL $C0F0       ; lzss compression
7E/C05C: 60           RTS 

; [ rle (high nybble clear) ]

7E/C05D: 64 09        STZ $09         ; +$08 = repeat count/string length
7E/C05F: A4 C5        LDY $C5
7E/C061: 84 0C        STY $0C         ; +$0C = source pointer
7E/C063: 84 0E        STY $0E         ; +$0E = destination pointer
7E/C065: A4 0C        LDY $0C
7E/C067: C8           INY 
7E/C068: B7 D0        LDA [$D0],Y
7E/C06A: F0 34        BEQ $C0A0       ; null terminator
7E/C06C: 30 16        BMI $C084
7E/C06E: 85 08        STA $08         ; repeat count
7E/C070: C8           INY 
7E/C071: B7 D0        LDA [$D0],Y     ; repeated value
7E/C073: 84 0C        STY $0C
7E/C075: A4 0E        LDY $0E
7E/C077: C8           INY 
7E/C078: 97 D3        STA [$D3],Y
7E/C07A: 84 0E        STY $0E
7E/C07C: A6 08        LDX $08
7E/C07E: F0 E5        BEQ $C065
7E/C080: C6 08        DEC $08
7E/C082: 80 F3        BRA $C077
7E/C084: 29 7F        AND #$7F
7E/C086: 85 08        STA $08         ; string length
7E/C088: 84 0C        STY $0C
7E/C08A: A4 0C        LDY $0C
7E/C08C: C8           INY 
7E/C08D: B7 D0        LDA [$D0],Y
7E/C08F: 84 0C        STY $0C
7E/C091: A4 0E        LDY $0E
7E/C093: C8           INY 
7E/C094: 97 D3        STA [$D3],Y
7E/C096: 84 0E        STY $0E
7E/C098: A6 08        LDX $08
7E/C09A: F0 C9        BEQ $C065
7E/C09C: C6 08        DEC $08
7E/C09E: 80 EA        BRA $C08A
7E/C0A0: 60           RTS 

; [ rle (high nybble set) ]

7E/C0A1: 64 09        STZ $09
7E/C0A3: A4 C7        LDY $C7
7E/C0A5: 84 0C        STY $0C
7E/C0A7: 84 0E        STY $0E
7E/C0A9: E2 20        SEP #$20
7E/C0AB: A4 0C        LDY $0C
7E/C0AD: B7 D0        LDA [$D0],Y
7E/C0AF: F0 3E        BEQ $C0EF
7E/C0B1: 30 1B        BMI $C0CE
7E/C0B3: 85 08        STA $08
7E/C0B5: C8           INY 
7E/C0B6: C2 20        REP #$20
7E/C0B8: B7 D0        LDA [$D0],Y
7E/C0BA: C8           INY 
7E/C0BB: C8           INY 
7E/C0BC: 84 0C        STY $0C
7E/C0BE: A4 0E        LDY $0E
7E/C0C0: 97 D3        STA [$D3],Y
7E/C0C2: C8           INY 
7E/C0C3: C8           INY 
7E/C0C4: 84 0E        STY $0E
7E/C0C6: A6 08        LDX $08
7E/C0C8: F0 DF        BEQ $C0A9
7E/C0CA: C6 08        DEC $08
7E/C0CC: 80 F2        BRA $C0C0
7E/C0CE: 29 7F 85     AND #$857F
7E/C0D1: 08           PHP 
7E/C0D2: C8           INY 
7E/C0D3: 84 0C        STY $0C
7E/C0D5: C2 20        REP #$20
7E/C0D7: A4 0C        LDY $0C
7E/C0D9: B7 D0        LDA [$D0],Y
7E/C0DB: C8           INY 
7E/C0DC: C8           INY 
7E/C0DD: 84 0C        STY $0C
7E/C0DF: A4 0E        LDY $0E
7E/C0E1: 97 D3        STA [$D3],Y
7E/C0E3: C8           INY 
7E/C0E4: C8           INY 
7E/C0E5: 84 0E        STY $0E
7E/C0E7: A6 08        LDX $08
7E/C0E9: F0 BE        BEQ $C0A9
7E/C0EB: C6 08        DEC $08
7E/C0ED: 80 E8        BRA $C0D7
7E/C0EF: 60           RTS 

; [ compression mode 2: lzss ]

; same as C3/0053

7E/C0F0: 8B           PHB 
7E/C0F1: A9 7F        LDA #$7F
7E/C0F3: 48           PHA 
7E/C0F4: AB           PLB 
7E/C0F5: A9 7F        LDA #$7F
7E/C0F7: 85 C9        STA $C9
7E/C0F9L C2 20        REP #$20
7E/C0FB: A9 FF 07     LDA #$07FF
7E/C0FE: 85 DE        STA $DE
7E/C100: A9 1F 00     LDA #$001F
7E/C103: 85 C2        STA $C2
7E/C105: A7 D0        LDA [$D0]
7E/C107: 3A           DEC 
7E/C108: 85 CA        STA $CA
7E/C10A: E6 D0        INC $D0
7E/C10C: E6 D0        INC $D0
7E/C10E: A2 DE 07     LDX #$07DE
7E/C111: 86 CC        STX $CC
7E/C113: A6 C7        LDX $C7
7E/C115: 8A           TXA 
7E/C116: A8           TAY 
7E/C117: 9D FF F7     STA $F7FF,X
7E/C11A: E8           INX 
7E/C11B: E8           INX 
7E/C11C: E4 CC        CPX $CC
7E/C11E: D0 F7        BNE $C117
7E/C120: 64 CE        STZ $CE
7E/C122: 46 CE        LSR $CE
7E/C124: A5 CE        LDA $CE
7E/C126: 29 80 00     AND #$0080
7E/C129: D0 0A        BNE $C135
7E/C12B: A7 D0        LDA [$D0]
7E/C12D: E6 D0        INC $D0
7E/C12F: 25 C6        AND $C6
7E/C131: 05 C8        ORA $C8
7E/C133: 85 CE        STA $CE
7E/C135: A5 CE        LDA $CE
7E/C137: 29 01 00     AND #$0001
7E/C13A: F0 1D        BEQ $C159
7E/C13C: A7 D0        LDA [$D0]
7E/C13E: E6 D0        INC $D0
7E/C140: 97 D3        STA [$D3],Y
7E/C142: C4 CA        CPY $CA
7E/C144: D0 04        BNE $C14A
7E/C146: E2 20        SEP #$20
7E/C148: AB           PLB 
7E/C149: 60           RTS 
7E/C14A: C8           INY 
7E/C14B: A6 CC        LDX $CC
7E/C14D: 9D FF F7     STA $F7FF,X
7E/C150: A5 CC        LDA $CC
7E/C152: 1A           INC 
7E/C153: 25 DE        AND $DE
7E/C155: 85 CC        STA $CC
7E/C157: 80 C9        BRA $C122
7E/C159: A7 D0        LDA [$D0]
7E/C15B: E2 20        SEP #$20
7E/C15D: EB           XBA 
7E/C15E: 85 DA        STA $DA
7E/C160: 4A           LSR 
7E/C161: 4A           LSR 
7E/C162: 4A           LSR 
7E/C163: 4A           LSR 
7E/C164: 4A           LSR 
7E/C165: EB           XBA 
7E/C166: C2 20        REP #$20
7E/C168: 85 D8        STA $D8
7E/C16A: A5 DA        LDA $DA
7E/C16C: 25 C2        AND $C2
7E/C16E: 1A           INC 
7E/C16F: 1A           INC 
7E/C170: 1A           INC 
7E/C171: 85 DA        STA $DA
7E/C173: 64 DC        STZ $DC
7E/C175: E6 D0        INC $D0
7E/C177: E6 D0        INC $D0
7E/C179: A5 DC        LDA $DC
7E/C17B: C5 DA        CMP $DA
7E/C17D: F0 21        BEQ $C1A0
7E/C17F: A5 D8        LDA $D8
7E/C181: 18           CLC 
7E/C182: 65 DC        ADC $DC
7E/C184: 25 DE        AND $DE
7E/C186: AA           TAX 
7E/C187: BD FF F7     LDA $F7FF,X
7E/C18A: 97 D3        STA [$D3],Y
7E/C18C: C4 CA        CPY $CA
7E/C18E: F0 B6        BEQ $C146
7E/C190: C8           INY 
7E/C191: A6 CC        LDX $CC
7E/C193: 9D FF F7     STA $F7FF,X
7E/C196: 8A           TXA 
7E/C197: 1A           INC 
7E/C198: 25 DE        AND $DE
7E/C19A: 85 CC        STA $CC
7E/C19C: E6 DC        INC $DC
7E/C19E: 80 D9        BRA $C179
7E/C1A0: 82 7F FF     BRL $C122

; [  ]

7E/C1A3: A6 B8        LDX $B8
7E/C1A5: 8E 16 21     STX $2116
7E/C1A8: A9 80        LDA #$80
7E/C1AA: 8D 15 21     STA $2115
7E/C1AD: A9 01        LDA #$01
7E/C1AF: 8D 70 43     STA $4370
7E/C1B2: A9 18        LDA #$18
7E/C1B4: 8D 71 43     STA $4371
7E/C1B7: A6 BA        LDX $BA
7E/C1B9: 8E 72 43     STX $4372
7E/C1BC: A5 BC        LDA $BC
7E/C1BE: 8D 74 43     STA $4374
7E/C1C1: A6 BD        LDX $BD
7E/C1C3: 8E 75 43     STX $4375
7E/C1C6: A9 80        LDA #$80
7E/C1C8: 8D 0B 42     STA $420B
7E/C1CB: 60           RTS 

; [ compression mode 0: no compression ]

7E/C1CC: 8B           PHB 
7E/C1CD: A5 D5        LDA $D5
7E/C1CF: 48           PHA 
7E/C1D0: AB           PLB 
7E/C1D1: A4 C7        LDY $C7
7E/C1D3: C4 D6        CPY $D6
7E/C1D5: F0 07        BEQ $C1DE
7E/C1D7: B7 D0        LDA [$D0],Y
7E/C1D9: 91 D3        STA ($D3),Y
7E/C1DB: C8           INY 
7E/C1DC: 80 F5        BRA $C1D3
7E/C1DE: AB           PLB 
7E/C1DF: 60           RTS 
7E/C1E0: 8B           PHB 
7E/C1E1: A5 D5        LDA $D5
7E/C1E3: 48           PHA 
7E/C1E4: AB           PLB 
7E/C1E5: A4 C7        LDY $C7
7E/C1E7: A9 00        LDA #$00        ; fill remaining space with zeroes
7E/C1E9: C4 D6        CPY $D6
7E/C1EB: F0 05        BEQ $C1F2
7E/C1ED: 91 D3        STA ($D3),Y
7E/C1EF: C8           INY 
7E/C1F0: 80 F7        BRA $C1E9
7E/C1F2: AB           PLB 
7E/C1F3: 60           RTS 

7E/C1F4: A9 C3        LDA #$C3        ; C3/0200
7E/C1F6: 85 D2        STA $D2
7E/C1F8: A2 00 02     LDX #$0200
7E/C1FB: 86 D0        STX $D0
7E/C1FD: A9 7E        LDA #$7E
7E/C1FF: 85 D5        STA $D5
7E/C201: A2 00 C0     LDX #$C000
7E/C204: 86 D3        STX $D3
7E/C206: 82 04 FE     BRL $C00D

7E/C209: A9 C3        LDA #$C3
7E/C20B: 85 D2        STA $D2
7E/C20D: A2 77 11     LDX #$1177
7E/C210: 86 D0        STX $D0
7E/C212: A9 7E        LDA #$7E
7E/C214: 85 D5        STA $D5
7E/C216: A2 00 C0     LDX #$C000
7E/C219: 86 D3        STX $D3
7E/C21B: 82 EF FD     BRL $C00D

7E/C500: 08           PHP 
7E/C501: C2 20        REP #$20
7E/C503: 48           PHA 
7E/C504: DA           PHX 
7E/C505: 5A           PHY 
7E/C506: 0B           PHD 
7E/C507: 8B           PHB 
7E/C508: A9 20 04     LDA #$0420
7E/C50B: 5B           TCD 
7E/C50C: E2 20        SEP #$20
7E/C50E: A9 00        LDA #$00
7E/C510: 48           PHA 
7E/C511: AB           PLB 
7E/C512: A5 74        LDA $74
7E/C514: 89 01        BIT #$01
7E/C516: F0 07        BEQ $C51F
7E/C518: A5 C7        LDA $C7
7E/C51A: 20 78 AC     JSR $AC78
7E/C51D: A5 74        LDA $74
7E/C51F: 89 02        BIT #$02
7E/C521: F0 07        BEQ $C52A
7E/C523: A9 01        LDA #$01
7E/C525: 20 78 AC     JSR $AC78
7E/C528: A5 74        LDA $74
7E/C52A: 89 04        BIT #$04
7E/C52C: F0 07        BEQ $C535
7E/C52E: A9 02        LDA #$02
7E/C530: 20 78 AC     JSR $AC78
7E/C533: A5 74        LDA $74
7E/C535: 89 08        BIT #$08
7E/C537: F0 07        BEQ $C540
7E/C539: A9 03        LDA #$03
7E/C53B: 20 78 AC     JSR $AC78
7E/C53E: A5 74        LDA $74
7E/C540: 89 10        BIT #$10
7E/C542: F0 07        BEQ $C54B
7E/C544: A9 04        LDA #$04
7E/C546: 20 78 AC     JSR $AC78
7E/C549: A5 74        LDA $74
7E/C54B: 89 20        BIT #$20
7E/C54D: F0 07        BEQ $C556
7E/C54F: A9 05        LDA #$05
7E/C551: 20 78 AC     JSR $AC78
7E/C554: A5 74        LDA $74
7E/C556: 89 40        BIT #$40
7E/C558: F0 07        BEQ $C561
7E/C55A: A9 06        LDA #$06
7E/C55C: 20 78 AC     JSR $AC78
7E/C55F: A5 74        LDA $74
7E/C561: 89 80        BIT #$80
7E/C563: F0 05        BEQ $C56A
7E/C565: A9 07        LDA #$07
7E/C567: 20 78 AC     JSR $AC78
7E/C56A: A5 4F        LDA $4F
7E/C56C: 89 01        BIT #$01
7E/C56E: F0 03        BEQ $C573
7E/C570: 20 4F C6     JSR $C64F
7E/C573: A5 4F        LDA $4F
7E/C575: 89 02        BIT #$02
7E/C577: F0 03        BEQ $C57C
7E/C579: 20 78 C6     JSR $C678
7E/C57C: A5 4F        LDA $4F
7E/C57E: 89 10        BIT #$10
7E/C580: F0 07        BEQ $C589
7E/C582: A9 00        LDA #$00
7E/C584: 20 9A BC     JSR $BC9A
7E/C587: 80 1F        BRA $C5A8
7E/C589: 89 20        BIT #$20
7E/C58B: F0 07        BEQ $C594
7E/C58D: A9 01        LDA #$01
7E/C58F: 20 9A BC     JSR $BC9A
7E/C592: 80 14        BRA $C5A8
7E/C594: 89 40        BIT #$40
7E/C596: F0 07        BEQ $C59F
7E/C598: A9 02        LDA #$02
7E/C59A: 20 9A BC     JSR $BC9A
7E/C59D: 80 09        BRA $C5A8
7E/C59F: 89 80        BIT #$80
7E/C5A1: F0 05        BEQ $C5A8
7E/C5A3: A9 03        LDA #$03
7E/C5A5: 20 9A BC     JSR $BC9A
7E/C5A8: A9 00        LDA #$00
7E/C5AA: 8D 21 21     STA $2121
7E/C5AD: A5 40        LDA $40
7E/C5AF: 8D 0C 42     STA $420C
7E/C5B2: A5 30        LDA $30
7E/C5B4: 8D 0D 21     STA $210D
7E/C5B7: A5 31        LDA $31
7E/C5B9: 8D 0D 21     STA $210D
7E/C5BC: A5 32        LDA $32
7E/C5BE: 8D 0E 21     STA $210E
7E/C5C1: A5 33        LDA $33
7E/C5C3: 8D 0E 21     STA $210E
7E/C5C6: A5 3B        LDA $3B
7E/C5C8: 8D 2C 21     STA $212C
7E/C5CB: A5 3A        LDA $3A
7E/C5CD: 8D 2D 21     STA $212D
7E/C5D0: A5 34        LDA $34
7E/C5D2: 8D 1F 21     STA $211F
7E/C5D5: A5 35        LDA $35
7E/C5D7: 8D 1F 21     STA $211F
7E/C5DA: A5 36        LDA $36
7E/C5DC: 8D 20 21     STA $2120
7E/C5DF: A5 37        LDA $37
7E/C5E1: 8D 20 21     STA $2120
7E/C5E4: A5 8E        LDA $8E
7E/C5E6: 8D 31 21     STA $2131
7E/C5E9: A5 8B        LDA $8B
7E/C5EB: 09 20        ORA #$20
7E/C5ED: 8D 32 21     STA $2132
7E/C5F0: A5 8C        LDA $8C
7E/C5F2: 09 40        ORA #$40
7E/C5F4: 8D 32 21     STA $2132
7E/C5F7: A5 8D        LDA $8D
7E/C5F9: 09 80        ORA #$80
7E/C5FB: 8D 32 21     STA $2132
7E/C5FE: A5 70        LDA $70
7E/C600: 89 01        BIT #$01
7E/C602: F0 18        BEQ $C61C
7E/C604: A5 73        LDA $73
7E/C606: C5 72        CMP $72
7E/C608: F0 04        BEQ $C60E
7E/C60A: E6 73        INC $73
7E/C60C: 80 0E        BRA $C61C
7E/C60E: 64 73        STZ $73
7E/C610: A5 71        LDA $71
7E/C612: 1A           INC 
7E/C613: C9 10        CMP #$10
7E/C615: F0 05        BEQ $C61C
7E/C617: 8D 00 21     STA $2100
7E/C61A: 85 71        STA $71
7E/C61C: A5 70        LDA $70
7E/C61E: 89 02        BIT #$02
7E/C620: F0 16        BEQ $C638
7E/C622: A5 73        LDA $73
7E/C624: C5 72        CMP $72
7E/C626: F0 04        BEQ $C62C
7E/C628: E6 73        INC $73
7E/C62A: 80 0C        BRA $C638
7E/C62C: 64 73        STZ $73
7E/C62E: A5 71        LDA $71
7E/C630: F0 01        BEQ $C633
7E/C632: 3A           DEC 
7E/C633: 8D 00 21     STA $2100
7E/C636: 85 71        STA $71
7E/C638: AD 12 42     LDA $4212
7E/C63B: 89 01        BIT #$01
7E/C63D: D0 F9        BNE $C638
7E/C63F: AE 18 42     LDX $4218
7E/C642: 86 42        STX $42
7E/C644: 64 07        STZ $07
7E/C646: C2 20        REP #$20
7E/C648: AB           PLB 
7E/C649: 2B           PLD 
7E/C64A: 7A           PLY 
7E/C64B: FA           PLX 
7E/C64C: 68           PLA 
7E/C64D: 28           PLP 
7E/C64E: 40           RTI 

7E/C64F: A9 00        LDA #$00
7E/C651: 8D 02 21     STA $2102
7E/C654: 8D 03 21     STA $2103
7E/C657: A9 00        LDA #$00
7E/C659: 8D 70 43     STA $4370
7E/C65C: A9 04        LDA #$04
7E/C65E: 8D 71 43     STA $4371
7E/C661: A2 00 02     LDX #$0200
7E/C664: 8E 72 43     STX $4372
7E/C667: A9 00        LDA #$00
7E/C669: 8D 74 43     STA $4374
7E/C66C: A2 20 02     LDX #$0220
7E/C66F: 8E 75 43     STX $4375
7E/C672: A9 80        LDA #$80
7E/C674: 8D 0B 42     STA $420B
7E/C677: 60           RTS 

7E/C678: A6 AC        LDX $AC
7E/C67A: 8E 16 21     STX $2116
7E/C67D: A9 80        LDA #$80
7E/C67F: 8D 15 21     STA $2115
7E/C682: A5 B3        LDA $B3
7E/C684: 8D 70 43     STA $4370
7E/C687: A5 B4        LDA $B4
7E/C689: 8D 71 43     STA $4371
7E/C68C: A6 AE        LDX $AE
7E/C68E: 8E 72 43     STX $4372
7E/C691: A5 B0        LDA $B0
7E/C693: 8D 74 43     STA $4374
7E/C696: A6 B1        LDX $B1
7E/C698: 8E 75 43     STX $4375
7E/C69B: A9 80        LDA #$80
7E/C69D: 8D 0B 42     STA $420B
7E/C6A0: 60           RTS 

7E/C780: 00
7E/C781: 04 00        TSB $00
7E/C783: 08           PHP 
7E/C784: 20 0C 20     JSR $200C
7E/C787: 10 20        BPL $C7A9
7E/C789: 14 40        TRB $40
7E/C78B: 14 40        TRB $40
7E/C78D: 18           CLC 
7E/C78E: 60           RTS 
7E/C78F: 1C 60 20     TRB $2060
7E/C792: 60           RTS 
7E/C793: 24 80        BIT $80
7E/C795: 28           PLP 
7E/C796: 80 2C        BRA $C7C4
7E/C798: 80 30        BRA $C7CA
7E/C79A: A0 34 A0     LDY #$A034
7E/C79D: 38           SEC 
7E/C79E: C0 3C C0     CPY #$C03C
7E/C7A1: 40           RTI 
7E/C7A2: 00 00        BRK $00
7E/C7A4: 00 00        BRK $00
7E/C7A6: 00 00        BRK $00
7E/C7A8: 00 00        BRK $00
7E/C7AA: 00 00        BRK $00
7E/C7AC: 00 00        BRK $00
7E/C7AE: 00 00        BRK $00
7E/C7B0: 00 00        BRK $00
7E/C7B2: 00 03        BRK $03
7E/C7B4: 00 06        BRK $06
7E/C7B6: 00 09        BRK $09
7E/C7B8: 37 3F        AND [$3F],Y
7E/C7BA: 47 4F        EOR [$4F]
7E/C7BC: 57 5F        EOR [$5F],Y
7E/C7BE: 67 6F        ADC [$6F]
7E/C7C0: 00 00        BRK $00
7E/C7C2: 00 00        BRK $00
7E/C7C4: 00 00        BRK $00
7E/C7C6: 00 00        BRK $00
7E/C7C8: 00 00        BRK $00
7E/C7CA: 00 00        BRK $00
7E/C7CC: 00 00        BRK $00
7E/C7CE: 00 00        BRK $00
7E/C7D0: 00 00        BRK $00
7E/C7D2: 00 00        BRK $00
7E/C7D4: 00 00        BRK $00
7E/C7D6: 00 00        BRK $00
7E/C7D8: 00 00        BRK $00
7E/C7DA: 00 00        BRK $00
7E/C7DC: 00 00        BRK $00
7E/C7DE: 00 00        BRK $00
7E/C7E0: 01 00        ORA ($00,X)
7E/C7E2: 04 00        TSB $00
7E/C7E4: 10 00        BPL $C7E6
7E/C7E6: 40           RTI 
7E/C7E7: 00 00        BRK $00
7E/C7E9: 01 00        ORA ($00,X)
7E/C7EB: 04 00        TSB $00
7E/C7ED: 10 00        BPL $C7EF
7E/C7EF: 40           RTI 
7E/C7F0: FC FF F3     JSR ($F3FF,X)
7E/C7F3: FF CF FF 3F  SBC $3FFFCF,X
7E/C7F7: FF FF FC FF  SBC $FFFCFF,X
7E/C7FB: F3 FF        SBC ($FF,S),Y
7E/C7FD: CF FF 3F     CMP $003FFF

; ====================================[ sound/music ]=====================================

C4/0000: 4C 2C 00     JMP $002C
C4/0003: EA           NOP 
C4/0004: 4C 4C 01     JMP $014C
C4/0007: EA           NOP 

; spc chunk data
C4/0008:              .DW $064D, $1F95, $1E3F, $1F4F, $1F71, $1F83 ; source address (+C40000)
C4/0014:              .DW $0200, $2C00, $4800, $1B00, $1A80, $1A00 ; dest address (spc)
C4/0020:              .DW $3B97, $3C6F, $3CD8, $3D64, $3D1E, $3DAA

; [ init spc ]

C4/002C: 8B           PHB 
C4/002D: 0B           PHD 
C4/002E: 08           PHP 
C4/002F: C2 20        REP #$20
C4/0031: C2 10        REP #$10
C4/0033: 48           PHA 
C4/0034: DA           PHX 
C4/0035: 5A           PHY 
C4/0036: E2 20        SEP #$20
C4/0038: A9 00        LDA #$00
C4/003A: 48           PHA 
C4/003B: AB           PLB 
C4/003C: A2 00 1D     LDX #$1D00
C4/003F: DA           PHX 
C4/0040: 2B           PLD 
C4/0041: A2 AA BB     LDX #$BBAA
C4/0044: A0 00 08     LDY #$0800
C4/0047: EC 40 21     CPX $2140
C4/004A: F0 32        BEQ $007E
C4/004C: 88           DEY 
C4/004D: D0 F8        BNE $0047
C4/004F: A4 F8        LDY $F8
C4/0051: F0 2B        BEQ $007E
C4/0053: C4 48        CPY $48
C4/0055: D0 27        BNE $007E
C4/0057: A9 F0        LDA #$F0
C4/0059: C5 00        CMP $00
C4/005B: D0 21        BNE $007E       ; branch if full reset
C4/005D: A9 08        LDA #$08
C4/005F: 8D 41 21     STA $2141
C4/0062: A9 00        LDA #$00
C4/0064: 8D 40 21     STA $2140
C4/0067: A2 F8 00     LDX #$00F8
C4/006A: 9D FF 1C     STA $1CFF,X
C4/006D: CA           DEX 
C4/006E: D0 FA        BNE $006A
C4/0070: A4 F8        LDY $F8
C4/0072: 84 48        STY $48
C4/0074: 3A           DEC 
C4/0075: 85 05        STA $05
C4/0077: A9 F0        LDA #$F0
C4/0079: 85 00        STA $00
C4/007B: 4C 61 01     JMP $0161
C4/007E: EC 40 21     CPX $2140
C4/0081: D0 FB        BNE $007E
C4/0083: A2 00 00     LDX #$0000
C4/0086: AF 14 00 C4  LDA $C40014
C4/008A: 8D 42 21     STA $2142
C4/008D: AF 15 00 C4  LDA $C40015
C4/0091: 8D 43 21     STA $2143
C4/0094: A9 CC        LDA #$CC
C4/0096: 8D 41 21     STA $2141
C4/0099: 8D 40 21     STA $2140
C4/009C: CD 40 21     CMP $2140
C4/009F: D0 FB        BNE $009C
C4/00A1: A9 00        LDA #$00
C4/00A3: EB           XBA 
C4/00A4: BF 08 00 C4  LDA $C40008,X
C4/00A8: 85 14        STA $14
C4/00AA: BF 09 00 C4  LDA $C40009,X
C4/00AE: 85 15        STA $15
C4/00B0: A9 C4        LDA #$C4
C4/00B2: 85 16        STA $16
C4/00B4: A0 00 00     LDY #$0000
C4/00B7: B7 14        LDA [$14],Y
C4/00B9: 18           CLC 
C4/00BA: 69 02        ADC #$02
C4/00BC: 85 10        STA $10
C4/00BE: C8           INY 
C4/00BF: B7 14        LDA [$14],Y
C4/00C1: 69 00        ADC #$00
C4/00C3: 85 11        STA $11
C4/00C5: C8           INY 
C4/00C6: B7 14        LDA [$14],Y
C4/00C8: 8D 41 21     STA $2141
C4/00CB: EB           XBA 
C4/00CC: 8D 40 21     STA $2140
C4/00CF: CD 40 21     CMP $2140
C4/00D2: D0 FB        BNE $00CF
C4/00D4: 1A           INC 
C4/00D5: EB           XBA 
C4/00D6: C8           INY 
C4/00D7: C4 10        CPY $10
C4/00D9: D0 EB        BNE $00C6
C4/00DB: EB           XBA 
C4/00DC: 1A           INC 
C4/00DD: 1A           INC 
C4/00DE: 1A           INC 
C4/00DF: D0 01        BNE $00E2
C4/00E1: 1A           INC 
C4/00E2: E8           INX 
C4/00E3: E8           INX 
C4/00E4: E0 0C 00     CPX #$000C
C4/00E7: F0 1D        BEQ $0106
C4/00E9: EB           XBA 
C4/00EA: BF 14 00 C4  LDA $C40014,X
C4/00EE: 8D 42 21     STA $2142
C4/00F1: BF 15 00 C4  LDA $C40015,X
C4/00F5: 8D 43 21     STA $2143
C4/00F8: EB           XBA 
C4/00F9: 8D 41 21     STA $2141
C4/00FC: 8D 40 21     STA $2140
C4/00FF: CD 40 21     CMP $2140
C4/0102: D0 FB        BNE $00FF
C4/0104: 80 9B        BRA $00A1
C4/0106: A0 00 02     LDY #$0200
C4/0109: 8C 42 21     STY $2142
C4/010C: EB           XBA 
C4/010D: A9 00        LDA #$00
C4/010F: 8D 41 21     STA $2141
C4/0112: EB           XBA 
C4/0113: 8D 40 21     STA $2140
C4/0116: CD 40 21     CMP $2140
C4/0119: D0 FB        BNE $0116
C4/011B: EB           XBA 
C4/011C: 8D 40 21     STA $2140
C4/011F: A2 00 01     LDX #$0100
C4/0122: 9D FF 1C     STA $1CFF,X
C4/0125: CA           DEX 
C4/0126: D0 FA        BNE $0122
C4/0128: A9 FF        LDA #$FF
C4/012A: 85 05        STA $05
C4/012C: C2 20        REP #$20
C4/012E: AF 3F 1E C4  LDA $C41E3F
C4/0132: 18           CLC 
C4/0133: 69 00 48     ADC #$4800
C4/0136: 85 F8        STA $F8
C4/0138: 85 48        STA $48
C4/013A: A2 00 08     LDX #$0800
C4/013D: CA           DEX 
C4/013E: D0 FD        BNE $013D
C4/0140: E2 20        SEP #$20
C4/0142: A9 00        LDA #$00
C4/0144: 85 FA        STA $FA
C4/0146: A9 C4        LDA #$C4
C4/0148: 85 FB        STA $FB
C4/014A: 80 31        BRA $017D

; [ spc command ]

C4/014C: 8B           PHB 
C4/014D: 0B           PHD 
C4/014E: 08           PHP 
C4/014F: C2 20        REP #$20
C4/0151: C2 10        REP #$10
C4/0153: 48           PHA 
C4/0154: DA           PHX 
C4/0155: 5A           PHY 
C4/0156: E2 20        SEP #$20
C4/0158: A9 00        LDA #$00
C4/015A: 48           PHA 
C4/015B: AB           PLB 
C4/015C: A2 00 1D     LDX #$1D00
C4/015F: DA           PHX 
C4/0160: 2B           PLD 
C4/0161: E2 20        SEP #$20
C4/0163: A5 00        LDA $00
C4/0165: 64 00        STZ $00
C4/0167: F0 14        BEQ $017D       ; no interrupt ($00)
C4/0169: 30 0C        BMI $0177
C4/016B: C9 01        CMP #$01
C4/016D: F0 19        BEQ $0188       ; play song ($01)
C4/016F: C9 03        CMP #$03
C4/0171: F0 15        BEQ $0188       ; suspend current song and play song ($03)
C4/0173: C9 70        CMP #$70
C4/0175: B0 03        BCS $017A       ; interrupts $70-$7F
C4/0177: 4C 89 05     JMP $0589       ; other interrupts
C4/017A: 4C C9 05     JMP $05C9

; [ common return code ]

C4/017D: C2 20        REP #$20
C4/017F: C2 10        REP #$10
C4/0181: 7A           PLY 
C4/0182: FA           PLX 
C4/0183: 68           PLA 
C4/0184: 28           PLP 
C4/0185: 2B           PLD 
C4/0186: AB           PLB 
C4/0187: 6B           RTL 

; [ play song ]

C4/0188: E2 20        SEP #$20
C4/018A: EB           XBA 
C4/018B: A5 01        LDA $01
C4/018D: C5 05        CMP $05
C4/018F: D0 43        BNE $01D4
C4/0191: A6 02        LDX $02
C4/0193: 86 06        STX $06
C4/0195: 8A           TXA 
C4/0196: 29 0F        AND #$0F
C4/0198: 8D 41 21     STA $2141
C4/019B: A9 84        LDA #$84
C4/019D: CD 40 21     CMP $2140
C4/01A0: F0 FB        BEQ $019D
C4/01A2: 8D 40 21     STA $2140
C4/01A5: CD 40 21     CMP $2140
C4/01A8: D0 FB        BNE $01A5
C4/01AA: A9 00        LDA #$00
C4/01AC: 8D 40 21     STA $2140
C4/01AF: EB           XBA 
C4/01B0: 8A           TXA 
C4/01B1: 29 F0        AND #$F0
C4/01B3: 85 02        STA $02
C4/01B5: A5 03        LDA $03
C4/01B7: 29 0F        AND #$0F
C4/01B9: 05 02        ORA $02
C4/01BB: 8D 41 21     STA $2141
C4/01BE: A9 81        LDA #$81
C4/01C0: CD 40 21     CMP $2140
C4/01C3: F0 FB        BEQ $01C0
C4/01C5: 8D 40 21     STA $2140
C4/01C8: CD 40 21     CMP $2140
C4/01CB: D0 FB        BNE $01C8
C4/01CD: EB           XBA 
C4/01CE: 8D 40 21     STA $2140
C4/01D1: 4C 7D 01     JMP $017D
C4/01D4: 20 E0 05     JSR $05E0
C4/01D7: A5 05        LDA $05
C4/01D9: 30 06        BMI $01E1
C4/01DB: 85 09        STA $09
C4/01DD: A6 06        LDX $06
C4/01DF: 86 0A        STX $0A
C4/01E1: A5 01        LDA $01
C4/01E3: 8D 41 21     STA $2141
C4/01E6: 85 05        STA $05
C4/01E8: A6 02        LDX $02
C4/01EA: 8E 42 21     STX $2142
C4/01ED: 86 06        STX $06
C4/01EF: EB           XBA 
C4/01F0: CD 40 21     CMP $2140
C4/01F3: F0 FB        BEQ $01F0
C4/01F5: 8D 40 21     STA $2140
C4/01F8: CD 40 21     CMP $2140
C4/01FB: D0 FB        BNE $01F8
C4/01FD: A9 02        LDA #$02        ; transfer mode 2 (two bytes at a time)
C4/01FF: 8D 41 21     STA $2141
C4/0202: A2 00 1C     LDX #$1C00
C4/0205: 8E 42 21     STX $2142
C4/0208: 8D 40 21     STA $2140
C4/020B: CD 40 21     CMP $2140
C4/020E: D0 FB        BNE $020B
C4/0210: C2 20        REP #$20
C4/0212: A5 05        LDA $05
C4/0214: 29 FF 00     AND #$00FF
C4/0217: 48           PHA 
C4/0218: 0A           ASL 
C4/0219: 85 E8        STA $E8
C4/021B: 68           PLA 
C4/021C: 18           CLC 
C4/021D: 65 E8        ADC $E8
C4/021F: AA           TAX 
C4/0220: E2 20        SEP #$20
C4/0222: BF 97 3B C4  LDA $C43B97,X
C4/0226: 85 14        STA $14
C4/0228: BF 98 3B C4  LDA $C43B98,X
C4/022C: 85 15        STA $15
C4/022E: BF 99 3B C4  LDA $C43B99,X
C4/0232: 85 16        STA $16
C4/0234: A4 14        LDY $14
C4/0236: 64 14        STZ $14
C4/0238: 64 15        STZ $15
C4/023A: B7 14        LDA [$14],Y
C4/023C: EB           XBA 
C4/023D: C8           INY 
C4/023E: D0 02        BNE $0242
C4/0240: E6 16        INC $16
C4/0242: B7 14        LDA [$14],Y
C4/0244: 48           PHA 
C4/0245: C8           INY 
C4/0246: D0 02        BNE $024A
C4/0248: E6 16        INC $16
C4/024A: EB           XBA 
C4/024B: 48           PHA 
C4/024C: FA           PLX 
C4/024D: A9 05        LDA #$05
C4/024F: EB           XBA 
C4/0250: B7 14        LDA [$14],Y
C4/0252: 8D 42 21     STA $2142
C4/0255: C8           INY 
C4/0256: D0 02        BNE $025A
C4/0258: E6 16        INC $16
C4/025A: B7 14        LDA [$14],Y
C4/025C: 8D 43 21     STA $2143
C4/025F: C8           INY 
C4/0260: D0 02        BNE $0264
C4/0262: E6 16        INC $16
C4/0264: EB           XBA 
C4/0265: 8D 40 21     STA $2140
C4/0268: CD 40 21     CMP $2140
C4/026B: D0 FB        BNE $0268
C4/026D: 1A           INC 
C4/026E: D0 01        BNE $0271
C4/0270: 1A           INC 
C4/0271: EB           XBA 
C4/0272: CA           DEX 
C4/0273: CA           DEX 
C4/0274: 10 DA        BPL $0250
C4/0276: C2 20        REP #$20
C4/0278: A2 00 00     LDX #$0000
C4/027B: 74 88        STZ $88,X
C4/027D: 74 C8        STZ $C8,X
C4/027F: E8           INX 
C4/0280: E8           INX 
C4/0281: E0 20 00     CPX #$0020
C4/0284: D0 F5        BNE $027B
C4/0286: A5 04        LDA $04
C4/0288: 29 00 FF     AND #$FF00
C4/028B: 4A           LSR 
C4/028C: 4A           LSR 
C4/028D: 4A           LSR 
C4/028E: AA           TAX 
C4/028F: 18           CLC 
C4/0290: 69 20 00     ADC #$0020
C4/0293: 85 12        STA $12
C4/0295: A9 A8 1D     LDA #$1DA8
C4/0298: 85 14        STA $14
C4/029A: A9 C8 1D     LDA #$1DC8
C4/029D: 85 16        STA $16
C4/029F: BF AA 3D C4  LDA $C43DAA,X
C4/02A3: 92 14        STA ($14)
C4/02A5: E6 14        INC $14
C4/02A7: E6 14        INC $14
C4/02A9: A0 00 00     LDY #$0000
C4/02AC: D9 28 1D     CMP $1D28,Y
C4/02AF: F0 0F        BEQ $02C0
C4/02B1: C8           INY 
C4/02B2: C8           INY 
C4/02B3: C0 20 00     CPY #$0020
C4/02B6: D0 F4        BNE $02AC
C4/02B8: 92 16        STA ($16)
C4/02BA: E6 16        INC $16
C4/02BC: E6 16        INC $16
C4/02BE: 80 03        BRA $02C3
C4/02C0: 99 88 1D     STA $1D88,Y
C4/02C3: E8           INX 
C4/02C4: E8           INX 
C4/02C5: E4 12        CPX $12
C4/02C7: D0 D6        BNE $029F
C4/02C9: A5 C8        LDA $C8
C4/02CB: D0 03        BNE $02D0
C4/02CD: 4C AC 04     JMP $04AC
C4/02D0: 64 17        STZ $17
C4/02D2: E2 20        SEP #$20
C4/02D4: A2 00 00     LDX #$0000
C4/02D7: B5 C8        LDA $C8,X
C4/02D9: F0 41        BEQ $031C
C4/02DB: DA           PHX 
C4/02DC: 3A           DEC 
C4/02DD: C2 20        REP #$20
C4/02DF: 29 FF 00     AND #$00FF
C4/02E2: 48           PHA 
C4/02E3: 0A           ASL 
C4/02E4: 85 E8        STA $E8
C4/02E6: 68           PLA 
C4/02E7: 18           CLC 
C4/02E8: 65 E8        ADC $E8
C4/02EA: AA           TAX 
C4/02EB: E2 20        SEP #$20
C4/02ED: BF 6F 3C C4  LDA $C43C6F,X
C4/02F1: 85 14        STA $14
C4/02F3: BF 70 3C C4  LDA $C43C70,X
C4/02F7: 85 15        STA $15
C4/02F9: BF 71 3C C4  LDA $C43C71,X
C4/02FD: 85 16        STA $16
C4/02FF: A4 14        LDY $14
C4/0301: 64 14        STZ $14
C4/0303: 64 15        STZ $15
C4/0305: B7 14        LDA [$14],Y
C4/0307: 18           CLC 
C4/0308: 65 17        ADC $17
C4/030A: 85 17        STA $17
C4/030C: C8           INY 
C4/030D: D0 02        BNE $0311
C4/030F: E6 16        INC $16
C4/0311: B7 14        LDA [$14],Y
C4/0313: 65 18        ADC $18
C4/0315: 85 18        STA $18
C4/0317: FA           PLX 
C4/0318: E8           INX 
C4/0319: E8           INX 
C4/031A: 80 BB        BRA $02D7
C4/031C: A2 00 00     LDX #$0000
C4/031F: C2 20        REP #$20
C4/0321: B5 28        LDA $28,X
C4/0323: F0 04        BEQ $0329
C4/0325: E8           INX 
C4/0326: E8           INX 
C4/0327: 80 F8        BRA $0321
C4/0329: B5 48        LDA $48,X
C4/032B: 18           CLC 
C4/032C: 65 17        ADC $17
C4/032E: B0 08        BCS $0338
C4/0330: C9 00 D2     CMP #$D200
C4/0333: B0 03        BCS $0338
C4/0335: 4C EA 03     JMP $03EA
C4/0338: A2 1E 00     LDX #$001E
C4/033B: B5 86        LDA $86,X
C4/033D: D0 04        BNE $0343
C4/033F: CA           DEX 
C4/0340: CA           DEX 
C4/0341: D0 F8        BNE $033B
C4/0343: 86 24        STX $24
C4/0345: A2 00 00     LDX #$0000
C4/0348: B5 88        LDA $88,X
C4/034A: F0 07        BEQ $0353
C4/034C: E8           INX 
C4/034D: E8           INX 
C4/034E: E0 20 00     CPX #$0020
C4/0351: D0 F5        BNE $0348
C4/0353: E4 24        CPX $24
C4/0355: D0 0C        BNE $0363
C4/0357: 74 28        STZ $28,X
C4/0359: E8           INX 
C4/035A: E8           INX 
C4/035B: E0 20 00     CPX #$0020
C4/035E: D0 F7        BNE $0357
C4/0360: 4C EA 03     JMP $03EA
C4/0363: E2 20        SEP #$20
C4/0365: A9 07        LDA #$07        ; transfer mode 7 (move chunk)
C4/0367: 8D 41 21     STA $2141
C4/036A: 64 10        STZ $10
C4/036C: A0 00 00     LDY #$0000
C4/036F: C2 20        REP #$20
C4/0371: B9 88 1D     LDA $1D88,Y
C4/0374: F0 08        BEQ $037E
C4/0376: C8           INY 
C4/0377: C8           INY 
C4/0378: C4 24        CPY $24
C4/037A: D0 F5        BNE $0371
C4/037C: 80 62        BRA $03E0
C4/037E: BB           TYX 
C4/037F: 80 04        BRA $0385
C4/0381: B5 88        LDA $88,X
C4/0383: D0 08        BNE $038D
C4/0385: E8           INX 
C4/0386: E8           INX 
C4/0387: E4 24        CPX $24
C4/0389: D0 F6        BNE $0381
C4/038B: 80 53        BRA $03E0
C4/038D: 74 28        STZ $28,X
C4/038F: 74 88        STZ $88,X
C4/0391: 99 28 1D     STA $1D28,Y
C4/0394: B5 48        LDA $48,X
C4/0396: 8D 42 21     STA $2142
C4/0399: E2 20        SEP #$20
C4/039B: A5 10        LDA $10
C4/039D: 8D 40 21     STA $2140
C4/03A0: CD 40 21     CMP $2140
C4/03A3: D0 FB        BNE $03A0
C4/03A5: E6 10        INC $10
C4/03A7: C2 20        REP #$20
C4/03A9: B9 48 1D     LDA $1D48,Y
C4/03AC: 8D 42 21     STA $2142
C4/03AF: E2 20        SEP #$20
C4/03B1: A5 10        LDA $10
C4/03B3: 8D 40 21     STA $2140
C4/03B6: CD 40 21     CMP $2140
C4/03B9: D0 FB        BNE $03B6
C4/03BB: E6 10        INC $10
C4/03BD: C2 20        REP #$20
C4/03BF: B5 68        LDA $68,X
C4/03C1: 8D 42 21     STA $2142
C4/03C4: 99 68 1D     STA $1D68,Y
C4/03C7: 18           CLC 
C4/03C8: 79 48 1D     ADC $1D48,Y
C4/03CB: 99 4A 1D     STA $1D4A,Y
C4/03CE: E2 20        SEP #$20
C4/03D0: A5 10        LDA $10
C4/03D2: 8D 40 21     STA $2140
C4/03D5: CD 40 21     CMP $2140
C4/03D8: D0 FB        BNE $03D5
C4/03DA: E6 10        INC $10
C4/03DC: C2 20        REP #$20
C4/03DE: 80 96        BRA $0376
C4/03E0: BB           TYX 
C4/03E1: 74 28        STZ $28,X
C4/03E3: E8           INX 
C4/03E4: E8           INX 
C4/03E5: E0 20 00     CPX #$0020
C4/03E8: D0 F7        BNE $03E1
C4/03EA: E2 20        SEP #$20
C4/03EC: A9 03        LDA #$03        ; transfer mode 3 (three bytes at a time)
C4/03EE: 8D 41 21     STA $2141
C4/03F1: A2 00 00     LDX #$0000
C4/03F4: B5 28        LDA $28,X
C4/03F6: F0 04        BEQ $03FC
C4/03F8: E8           INX 
C4/03F9: E8           INX 
C4/03FA: 80 F8        BRA $03F4
C4/03FC: 86 24        STX $24
C4/03FE: B5 48        LDA $48,X
C4/0400: 8D 42 21     STA $2142
C4/0403: B5 49        LDA $49,X
C4/0405: 8D 43 21     STA $2143
C4/0408: A9 00        LDA #$00
C4/040A: 8D 40 21     STA $2140
C4/040D: CD 40 21     CMP $2140
C4/0410: D0 FB        BNE $040D
C4/0412: 1A           INC 
C4/0413: 85 10        STA $10
C4/0415: A2 00 00     LDX #$0000
C4/0418: E2 20        SEP #$20
C4/041A: B5 C8        LDA $C8,X
C4/041C: D0 03        BNE $0421
C4/041E: 4C AC 04     JMP $04AC
C4/0421: A4 24        LDY $24
C4/0423: 99 28 1D     STA $1D28,Y
C4/0426: DA           PHX 
C4/0427: 3A           DEC 
C4/0428: C2 20        REP #$20
C4/042A: 29 FF 00     AND #$00FF
C4/042D: 48           PHA 
C4/042E: 0A           ASL 
C4/042F: 85 E8        STA $E8
C4/0431: 68           PLA 
C4/0432: 18           CLC 
C4/0433: 65 E8        ADC $E8
C4/0435: AA           TAX 
C4/0436: E2 20        SEP #$20
C4/0438: BF 6F 3C C4  LDA $C43C6F,X
C4/043C: 85 14        STA $14
C4/043E: BF 70 3C C4  LDA $C43C70,X
C4/0442: 85 15        STA $15
C4/0444: BF 71 3C C4  LDA $C43C71,X
C4/0448: 85 16        STA $16
C4/044A: A4 14        LDY $14
C4/044C: 64 14        STZ $14
C4/044E: 64 15        STZ $15
C4/0450: B7 14        LDA [$14],Y
C4/0452: EB           XBA 
C4/0453: C8           INY 
C4/0454: D0 02        BNE $0458
C4/0456: E6 16        INC $16
C4/0458: B7 14        LDA [$14],Y
C4/045A: C8           INY 
C4/045B: D0 02        BNE $045F
C4/045D: E6 16        INC $16
C4/045F: EB           XBA 
C4/0460: C2 20        REP #$20
C4/0462: 48           PHA 
C4/0463: A6 24        LDX $24
C4/0465: 95 68        STA $68,X
C4/0467: 18           CLC 
C4/0468: 75 48        ADC $48,X
C4/046A: 95 4A        STA $4A,X
C4/046C: E8           INX 
C4/046D: E8           INX 
C4/046E: 86 24        STX $24
C4/0470: FA           PLX 
C4/0471: E2 20        SEP #$20
C4/0473: B7 14        LDA [$14],Y     ; first byte
C4/0475: 8D 41 21     STA $2141
C4/0478: C8           INY 
C4/0479: D0 02        BNE $047D
C4/047B: E6 16        INC $16
C4/047D: B7 14        LDA [$14],Y     ; second byte
C4/047F: 8D 42 21     STA $2142
C4/0482: C8           INY 
C4/0483: D0 02        BNE $0487
C4/0485: E6 16        INC $16
C4/0487: B7 14        LDA [$14],Y     ; third byte
C4/0489: 8D 43 21     STA $2143
C4/048C: C8           INY 
C4/048D: D0 02        BNE $0491
C4/048F: E6 16        INC $16
C4/0491: A5 10        LDA $10
C4/0493: 8D 40 21     STA $2140
C4/0496: CD 40 21     CMP $2140       ; wait for spc
C4/0499: D0 FB        BNE $0496
C4/049B: E6 10        INC $10
C4/049D: D0 02        BNE $04A1
C4/049F: E6 10        INC $10
C4/04A1: CA           DEX 
C4/04A2: CA           DEX 
C4/04A3: CA           DEX 
C4/04A4: D0 CD        BNE $0473
C4/04A6: FA           PLX 
C4/04A7: E8           INX 
C4/04A8: E8           INX 
C4/04A9: 82 6C FF     BRL $0418
C4/04AC: C2 20        REP #$20
C4/04AE: A5 A8        LDA $A8
C4/04B0: D0 03        BNE $04B5
C4/04B2: 4C 7C 05     JMP $057C
C4/04B5: A9 A8 1D     LDA #$1DA8
C4/04B8: 85 14        STA $14
C4/04BA: A9 00 1E     LDA #$1E00
C4/04BD: 85 16        STA $16
C4/04BF: A9 40 1E     LDA #$1E40
C4/04C2: 85 18        STA $18
C4/04C4: A9 C0 1E     LDA #$1EC0
C4/04C7: 85 1A        STA $1A
C4/04C9: B2 14        LDA ($14)
C4/04CB: F0 3D        BEQ $050A
C4/04CD: E6 14        INC $14
C4/04CF: E6 14        INC $14
C4/04D1: A0 00 00     LDY #$0000
C4/04D4: D9 28 1D     CMP $1D28,Y
C4/04D7: F0 04        BEQ $04DD
C4/04D9: C8           INY 
C4/04DA: C8           INY 
C4/04DB: 80 F7        BRA $04D4
C4/04DD: 3A           DEC 
C4/04DE: 0A           ASL 
C4/04DF: AA           TAX 
C4/04E0: BF 1E 3D C4  LDA $C43D1E,X   ; sample loop pointers ???
C4/04E4: 92 16        STA ($16)
C4/04E6: E6 16        INC $16
C4/04E8: E6 16        INC $16
C4/04EA: B9 48 1D     LDA $1D48,Y
C4/04ED: 92 18        STA ($18)
C4/04EF: E6 18        INC $18
C4/04F1: E6 18        INC $18
C4/04F3: 18           CLC 
C4/04F4: 7F D8 3C C4  ADC $C43CD8,X   ; sample pitch multipliers
C4/04F8: 92 18        STA ($18)
C4/04FA: E6 18        INC $18
C4/04FC: E6 18        INC $18
C4/04FE: BF 64 3D C4  LDA $C43D64,X   ; sample adsr values
C4/0502: 92 1A        STA ($1A)
C4/0504: E6 1A        INC $1A
C4/0506: E6 1A        INC $1A
C4/0508: 80 BF        BRA $04C9
C4/050A: E2 20        SEP #$20
C4/050C: A9 02        LDA #$02
C4/050E: 8D 41 21     STA $2141
C4/0511: A2 00 1E     LDX #$1E00
C4/0514: DA           PHX 
C4/0515: 2B           PLD 
C4/0516: A2 40 1A     LDX #$1A40
C4/0519: 8E 42 21     STX $2142
C4/051C: A9 00        LDA #$00
C4/051E: A2 FE FF     LDX #$FFFE
C4/0521: 80 05        BRA $0528
C4/0523: B4 00        LDY $00,X
C4/0525: 8C 42 21     STY $2142
C4/0528: 8D 40 21     STA $2140
C4/052B: CD 40 21     CMP $2140
C4/052E: D0 FB        BNE $052B
C4/0530: 1A           INC 
C4/0531: E8           INX 
C4/0532: E8           INX 
C4/0533: E0 40 00     CPX #$0040
C4/0536: D0 EB        BNE $0523
C4/0538: A2 80 1B     LDX #$1B80
C4/053B: 8E 42 21     STX $2142
C4/053E: A9 00        LDA #$00
C4/0540: A2 FE FF     LDX #$FFFE
C4/0543: 80 05        BRA $054A
C4/0545: B4 40        LDY $40,X
C4/0547: 8C 42 21     STY $2142
C4/054A: 8D 40 21     STA $2140
C4/054D: CD 40 21     CMP $2140
C4/0550: D0 FB        BNE $054D
C4/0552: 1A           INC 
C4/0553: E8           INX 
C4/0554: E8           INX 
C4/0555: E0 80 00     CPX #$0080
C4/0558: D0 EB        BNE $0545
C4/055A: A2 C0 1A     LDX #$1AC0
C4/055D: 8E 42 21     STX $2142
C4/0560: A9 00        LDA #$00
C4/0562: A2 FE FF     LDX #$FFFE
C4/0565: 80 05        BRA $056C
C4/0567: B4 C0        LDY $C0,X
C4/0569: 8C 42 21     STY $2142
C4/056C: 8D 40 21     STA $2140
C4/056F: CD 40 21     CMP $2140
C4/0572: D0 FB        BNE $056F
C4/0574: 1A           INC 
C4/0575: E8           INX 
C4/0576: E8           INX 
C4/0577: E0 40 00     CPX #$0040
C4/057A: D0 EB        BNE $0567
C4/057C: E2 20        SEP #$20
C4/057E: A9 00        LDA #$00
C4/0580: 8D 41 21     STA $2141
C4/0583: 8D 40 21     STA $2140
C4/0586: 4C 7D 01     JMP $017D

; [ other interrupts ]

C4/0589: E2 20        SEP #$20
C4/058B: EB           XBA 
C4/058C: A5 03        LDA $03
C4/058E: 8D 43 21     STA $2143
C4/0591: A5 02        LDA $02
C4/0593: 8D 42 21     STA $2142
C4/0596: A5 01        LDA $01
C4/0598: 8D 41 21     STA $2141
C4/059B: EB           XBA 
C4/059C: CD 40 21     CMP $2140
C4/059F: F0 FB        BEQ $059C
C4/05A1: 8D 40 21     STA $2140
C4/05A4: C9 F0        CMP #$F0        ; branch if not a "stop music" interrupt
C4/05A6: 90 14        BCC $05BC
C4/05A8: C9 F2        CMP #$F2
C4/05AA: B0 10        BCS $05BC
C4/05AC: EB           XBA 
C4/05AD: A5 05        LDA $05
C4/05AF: 30 06        BMI $05B7       ; branch if no previous song
C4/05B1: 85 09        STA $09
C4/05B3: A6 06        LDX $06
C4/05B5: 86 0A        STX $0A
C4/05B7: A9 FF        LDA #$FF
C4/05B9: 85 05        STA $05
C4/05BB: EB           XBA 
C4/05BC: CD 40 21     CMP $2140
C4/05BF: D0 FB        BNE $05BC
C4/05C1: A9 00        LDA #$00        ; no interrupt
C4/05C3: 8D 40 21     STA $2140
C4/05C6: 4C 7D 01     JMP $017D

; [ interrupts $70-$7F ]

C4/05C9: C2 20        REP #$20
C4/05CB: 29 0F 00     AND #$000F
C4/05CE: 0A           ASL 
C4/05CF: 0A           ASL 
C4/05D0: AA           TAX 
C4/05D1: BF 03 06 C4  LDA $C40603,X
C4/05D5: 85 02        STA $02
C4/05D7: BF 01 06 C4  LDA $C40601,X
C4/05DB: 85 00        STA $00
C4/05DD: 4C 61 01     JMP $0161

; [ check if song needs to be suspended ]

C4/05E0: 08           PHP 
C4/05E1: E2 20        SEP #$20
C4/05E3: EB           XBA 
C4/05E4: C9 03        CMP #$03
C4/05E6: F0 16        BEQ $05FE
C4/05E8: A2 00 00     LDX #$0000
C4/05EB: BF 41 06 C4  LDA $C40641,X   ; songs to suspend the previous song
C4/05EF: 30 0B        BMI $05FC
C4/05F1: C5 01        CMP $01
C4/05F3: F0 03        BEQ $05F8
C4/05F5: E8           INX 
C4/05F6: 80 F3        BRA $05EB
C4/05F8: A9 03        LDA #$03
C4/05FA: 80 02        BRA $05FE
C4/05FC: A9 01        LDA #$01
C4/05FE: EB           XBA 
C4/05FF: 28           PLP 
C4/0600: 60           RTS 

; interrupts $70-$7F
C4/0601:              .DB $01, $0E, $08, $0F ; $70: play song $0E (victory fanfare)
C4/0605:              .DB $01, $2B, $08, $0F ; $71: play song $2B (the battle)
C4/0609:              .DB $01, $01, $08, $0F ; $72: play song $01 (the fierce battle)
C4/060D:              .DB $01, $09, $08, $0F ; $73: play song $09 (the last battle)
C4/0611:              .DB $01, $22, $08, $0F ; $74: play song $22 (gilgamesh)
C4/0615:              .DB $01, $0A, $08, $0F ; $75: play song $0A (requiem)
C4/0619:              .DB $01, $2D, $08, $0F ; $76: play song $2D (the evil lord, exdeath)
C4/061D:              .DB $01, $40, $08, $0F ; $77: play song $40 (the decisive battle)
C4/0621:              .DB $01, $07, $08, $0F ; $78: play song $07 (critter tripper fritter!)
C4/0625:              .DB $01, $3E, $08, $0F ; $79: play song $3E (a meteor is falling)
C4/0629:              .DB $01, $00, $08, $0F ; $7A: play song $00 (ahead on our way)
C4/062D:              .DB $01, $00, $08, $0F ; $7B: play song $00
C4/0631:              .DB $01, $00, $08, $0F ; $7C: play song $00
C4/0635:              .DB $01, $00, $08, $0F ; $7D: play song $00
C4/0639:              .DB $01, $00, $08, $0F ; $7E: play song $00
C4/063D:              .DB $80, $10, $00, $00 ; $7F: fade out sound

; songs to suspend the previous song
C4/0641:              .DB $2B ; the battle
C4/0642:              .DB $34 ; good night!
C4/0642:              .DB $2F ; i'm a dancer
C4/0642:              .DB $35 ; piano lesson 1
C4/0642:              .DB $36 ; piano lesson 2
C4/0642:              .DB $37 ; piano lesson 3
C4/0642:              .DB $38 ; piano lesson 4
C4/0642:              .DB $39 ; piano lesson 5
C4/0642:              .DB $3A ; piano lesson 6
C4/0642:              .DB $3B ; piano lesson 7
C4/0642:              .DB $3C ; piano lesson 8
C4/0642:              .DB $FF ; end of list terminator

; =====================================[ menu misc. ]=====================================

; [  ]

D0/DC2A: 8B           PHB 
D0/DC2B: A9 00        LDA #$00
D0/DC2D: 48           PHA 
D0/DC2E: AB           PLB 
D0/DC2F: AF A1 F9 7E  LDA $7EF9A1
D0/DC33: F0 6B        BEQ $DCA0
D0/DC35: C9 01        CMP #$01
D0/DC37: F0 26        BEQ $DC5F
D0/DC39: A9 41        LDA #$41
D0/DC3B: 8D 30 43     STA $4330
D0/DC3E: A9 26        LDA #$26        ; window position
D0/DC40: 8D 31 43     STA $4331
D0/DC43: A2 81 DD     LDX #$DD81
D0/DC46: 8E 32 43     STX $4332
D0/DC49: A9 D0        LDA #$D0
D0/DC4B: 8D 34 43     STA $4334
D0/DC4E: A9 7E        LDA #$7E
D0/DC50: 8D 37 43     STA $4337
D0/DC53: AF 84 BC 7E  LDA $7EBC84
D0/DC57: 09 08        ORA #$08
D0/DC59: 8F 84 BC 7E  STA $7EBC84
D0/DC5D: 80 41        BRA $DCA0
D0/DC5F: A9 40        LDA #$40
D0/DC61: 8D 60 43     STA $4360
D0/DC64: A9 31        LDA #$31
D0/DC66: 8D 61 43     STA $4361
D0/DC69: AF D3 DB 7E  LDA $7EDBD3
D0/DC6D: F0 05        BEQ $DC74
D0/DC6F: A2 9F DD     LDX #$DD9F
D0/DC72: 80 03        BRA $DC77
D0/DC74: A2 AC DD     LDX #$DDAC
D0/DC77: 8E 62 43     STX $4362
D0/DC7A: A9 D0        LDA #$D0
D0/DC7C: 8D 64 43     STA $4364
D0/DC7F: A9 7E        LDA #$7E
D0/DC81: 8D 67 43     STA $4367
D0/DC84: 80 1A        BRA $DCA0
D0/DC86: A9 40        LDA #$40
D0/DC88: 8D 60 43     STA $4360
D0/DC8B: A9 00        LDA #$00
D0/DC8D: 8D 61 43     STA $4361
D0/DC90: A2 7A DD     LDX #$DD7A
D0/DC93: 8E 62 43     STX $4362
D0/DC96: A9 D0        LDA #$D0
D0/DC98: 8D 64 43     STA $4364
D0/DC9B: A9 7E        LDA #$7E
D0/DC9D: 8D 67 43     STA $4367
D0/DCA0: AB           PLB 
D0/DCA1: 9C A1 F9     STZ $F9A1
D0/DCA4: 6B           RTL 

; [ init battle hdma ]

D0/DCA5: 8B           PHB 
D0/DCA6: A9 00        LDA #$00
D0/DCA8: 48           PHA 
D0/DCA9: AB           PLB 
D0/DCAA: A9 43        LDA #$43        ; 2-address, write twice, indirect
D0/DCAC: 8D 00 43     STA $4300
D0/DCAF: 8D 10 43     STA $4310
D0/DCB2: 8D 20 43     STA $4320
D0/DCB5: A9 0D        LDA #$0D        ; dma channel 0: bg1 scroll
D0/DCB7: 8D 01 43     STA $4301
D0/DCBA: A9 0F        LDA #$0F        ; dma channel 1: bg2 scroll
D0/DCBC: 8D 11 43     STA $4311
D0/DCBF: A9 11        LDA #$11        ; dma channel 2: bg3 scroll
D0/DCC1: 8D 21 43     STA $4321
D0/DCC4: A2 97 A8     LDX #$A897
D0/DCC7: 8E 02 43     STX $4302
D0/DCCA: A2 B0 A8     LDX #$A8B0
D0/DCCD: 8E 12 43     STX $4312
D0/DCD0: A2 30 A9     LDX #$A930
D0/DCD3: 8E 22 43     STX $4322
D0/DCD6: A9 7E        LDA #$7E
D0/DCD8: 8D 04 43     STA $4304
D0/DCDB: 8D 14 43     STA $4314
D0/DCDE: 8D 24 43     STA $4324
D0/DCE1: 8D 07 43     STA $4307
D0/DCE4: 8D 17 43     STA $4317
D0/DCE7: 8D 27 43     STA $4327
D0/DCEA: AF D3 DB 7E  LDA $7EDBD3
D0/DCEE: F0 1A        BEQ $DD0A
D0/DCF0: A9 40        LDA #$40
D0/DCF2: 8D 20 43     STA $4320
D0/DCF5: A9 32        LDA #$32        ; dma channel 2: fixed color
D0/DCF7: 8D 21 43     STA $4321
D0/DCFA: A2 7A DD     LDX #$DD7A
D0/DCFD: 8E 22 43     STX $4322
D0/DD00: A9 D0        LDA #$D0
D0/DD02: 8D 24 43     STA $4324
D0/DD05: A9 7E        LDA #$7E
D0/DD07: 8D 27 43     STA $4327
D0/DD0A: A9 40        LDA #$40
D0/DD0C: 8D 30 43     STA $4330
D0/DD0F: A9 05        LDA #$05        ; dma channel 3: bg mode
D0/DD11: 8D 31 43     STA $4331
D0/DD14: AF D3 DB 7E  LDA $7EDBD3
D0/DD18: F0 05        BEQ $DD1F
D0/DD1A: A2 92 DD     LDX #$DD92
D0/DD1E: 80 03        BRA $DD22
D0/DD1F: A2 88 DD     LDX #$DD88
D0/DD22: 8E 32 43     STX $4332
D0/DD25: A9 D0        LDA #$D0
D0/DD27: 8D 34 43     STA $4334
D0/DD2A: A9 7E        LDA #$7E
D0/DD2C: 8D 37 43     STA $4337
D0/DD2F: A9 40        LDA #$40
D0/DD31: 8D 60 43     STA $4360
D0/DD34: A9 00        LDA #$00        ; dma channel 6: screen brightness
D0/DD36: 8D 61 43     STA $4361
D0/DD39: A2 7A DD     LDX #$DD7A
D0/DD3C: 8E 62 43     STX $4362
D0/DD3F: A9 D0        LDA #$D0
D0/DD41: 8D 64 43     STA $4364
D0/DD44: A9 7E        LDA #$7E
D0/DD46: 8D 67 43     STA $4367
D0/DD49: A9 40        LDA #$40
D0/DD4B: 8D 70 43     STA $4370
D0/DD4E: A9 08        LDA #$08        ; dma channel 7: bg2 base address
D0/DD50: 8D 71 43     STA $4371
D0/DD53: AF D3 DB 7E  LDA $7EDBD3
D0/DD57: F0 05        BEQ $DD5E
D0/DD59: A2 C0 DD     LDX #$DDC0
D0/DD5C: 80 03        BRA $DD61
D0/DD5E: A2 B6 DD     LDX #$DDB6
D0/DD61: 8E 72 43     STX $4372
D0/DD64: A9 D0        LDA #$D0
D0/DD66: 8D 74 43     STA $4374
D0/DD69: A9 7E        LDA #$7E
D0/DD6B: 8D 77 43     STA $4377
D0/DD6E: AF 84 BC 7E  LDA $7EBC84     ; enable hdma channels 2,3,4,6,7
D0/DD72: 09 CE        ORA #$CE
D0/DD74: 8F 84 BC 7E  STA $7EBC84
D0/DD78: AB           PLB 
D0/DD79: 6B           RTL 

; hdma tables

; fixed color / screen brightness
D0/DD7A: F0 55 B4
D0/DD7D: F0 C5 B4
D0/DD80: 80

; window position
D0/DD81: F0 F0 F9
D0/DD84: F0 D0 FA
D0/DD87: 80

; bg mode
D0/DD88: 50 82 BC
D0/DD8B: 50 82 BC
D0/DD8E: 40 83 BC
D0/DD91: 00

; bg mode
D0/DD92: 20 83 BC
D0/DD95: 50 82 BC
D0/DD98: 50 82 BC
D0/DD9B: 20 83 BC
D0/DD9E: 00

; color math
D0/DD9F: 20 86 BC
D0/DDA2: 50 86 BC
D0/DDA5: 50 86 BC
D0/DDA8: 20 86 BC
D0/DDAB: 00

; color math
D0/DDAC: 50 86 BC
D0/DDAF: 50 86 BC
D0/DDB2: 40 87 BC
D0/DDB5: 00

; bg2 base address
D0/DDB6: 50 C2 DB
D0/DDB9: 50 C2 DB
D0/DDBC: 40 C3 DB
D0/DDBF: 00

; bg2 base address
D0/DDC0: 20 C3 DB
D0/DDC3: 50 C2 DB
D0/DDC6: 50 C2 DB
D0/DDC9: 20 C3 DB
D0/DDCC: 00

D0/DDCD: 0010 0010 0010 008F 0080 0000

D0/DDD9: C0

D0/DDDA: 0D 80 FD 40 FE 02 40 01 FF
D0/DDE3: FD 80 FE     SBC $FE80,X
D0/DDE6: 0F 40 FE 01  ORA $01FE40
D0/DDEA: FF FD 80 FE  SBC $FE80FD,X
D0/DDEE: 08           PHP 
D0/DDEF: 60           RTS 
D0/DDF0: 0B           PHD 
D0/DDF1: 60           RTS 
D0/DDF2: 01 FF        ORA ($FF,X)
D0/DDF4: 0E 60 FD     ASL $FD60
D0/DDF7: B0 FE        BCS $DDF7
D0/DDF9: 01 FF        ORA ($FF,X)
D0/DDFB: FE 09 60     INC $6009,X
D0/DDFE: 0A           ASL 
D0/DDFF: 60           RTS 
D0/DE00: 01 FF        ORA ($FF,X)
D0/DE02: FD 80 FE     SBC $FE80,X
D0/DE05: 08           PHP 
D0/DE06: 40           RTI 
D0/DE07: 0B           PHD 
D0/DE08: 40           RTI 
D0/DE09: 03 50        ORA $50,S
D0/DE0B: 01 62        ORA ($62,X)
D0/DE0D: 0F 20 FD 90  ORA $90FD20
D0/DE11: FE 01 28     INC $2801,X
D0/DE14: 10 28        BPL $DE3E
D0/DE16: FD 28 FE     SBC $FE28,X
D0/DE19: FF

; [ copy data to vram (channel 5) ]

;    A: source bank
;   +X: source address
;   +Y: destination address (vram)
; +$70: size

D0/DE1A: 8B           PHB 
D0/DE1B: 48           PHA 
D0/DE1C: A9 00        LDA #$00
D0/DE1E: 48           PHA 
D0/DE1F: AB           PLB 
D0/DE20: 68           PLA 
D0/DE21: 8C 16 21     STY $2116
D0/DE24: 8E 52 43     STX $4352
D0/DE27: 8D 54 43     STA $4354
D0/DE2A: A9 01        LDA #$01
D0/DE2C: 8D 50 43     STA $4350
D0/DE2F: A9 18        LDA #$18
D0/DE31: 8D 51 43     STA $4351
D0/DE34: A6 70        LDX $70
D0/DE36: 8E 55 43     STX $4355
D0/DE39: A9 20        LDA #$20
D0/DE3B: 8D 0B 42     STA $420B
D0/DE3E: AB           PLB 
D0/DE3F: 6B           RTL 

; [ copy data to vram (channel 4) ]

;    A: source bank
;   +X: source address
;   +Y: destination address (vram)
; +$88: size

D0/DE40: 8B           PHB 
D0/DE41: 48           PHA 
D0/DE42: A9 00        LDA #$00
D0/DE44: 48           PHA 
D0/DE45: AB           PLB 
D0/DE46: 68           PLA 
D0/DE47: 8C 16 21     STY $2116
D0/DE4A: 8E 42 43     STX $4342
D0/DE4D: 8D 44 43     STA $4344
D0/DE50: A9 01        LDA #$01
D0/DE52: 8D 40 43     STA $4340
D0/DE55: A9 18        LDA #$18
D0/DE57: 8D 41 43     STA $4341
D0/DE5A: A6 88        LDX $88
D0/DE5C: 8E 45 43     STX $4345
D0/DE5F: A9 10        LDA #$10
D0/DE61: 8D 0B 42     STA $420B
D0/DE64: AB           PLB 
D0/DE65: 6B           RTL 

; [ copy color palettes to vram ]

D0/DE66: 8B           PHB 
D0/DE67: A9 00        LDA #$00
D0/DE69: 48           PHA 
D0/DE6A: AB           PLB 
D0/DE6B: 8D 21 21     STA $2121
D0/DE6E: A2 02 22     LDX #$2202
D0/DE71: 8E 40 43     STX $4340
D0/DE74: A2 09 7E     LDX #$7E09      ; color palettes
D0/DE77: 8E 42 43     STX $4342
D0/DE7A: A9 7E        LDA #$7E
D0/DE7C: 8D 44 43     STA $4344
D0/DE7F: A2 00 02     LDX #$0200
D0/DE82: 8E 45 43     STX $4345
D0/DE85: A9 10        LDA #$10
D0/DE87: 8D 0B 42     STA $420B
D0/DE8A: AB           PLB 
D0/DE8B: 6B           RTL 

; [  ]

D0/DE8C: AD 75 BC     LDA $BC75
D0/DE8F: D0 3F        BNE $DED0
D0/DE91: 8B           PHB 
D0/DE92: A9 00        LDA #$00
D0/DE94: 48           PHA 
D0/DE95: AB           PLB 
D0/DE96: A2 00 00     LDX #$0000
D0/DE99: 8E 02 21     STX $2102
D0/DE9C: A2 00 04     LDX #$0400
D0/DE9F: 8E 40 43     STX $4340
D0/DEA2: A2 00 02     LDX #$0200
D0/DEA5: 8E 42 43     STX $4342
D0/DEA8: A9 00        LDA #$00
D0/DEAA: 8D 44 43     STA $4344
D0/DEAD: 8D 47 43     STA $4347
D0/DEB0: A2 20 02     LDX #$0220
D0/DEB3: 8E 45 43     STX $4345
D0/DEB6: A9 10        LDA #$10
D0/DEB8: 8D 0B 42     STA $420B
D0/DEBB: AF 46 CD 7E  LDA $7ECD46
D0/DEBF: 10 0E        BPL $DECF
D0/DEC1: AF 45 CD 7E  LDA $7ECD45
D0/DEC5: 8D 02 21     STA $2102
D0/DEC8: AF 46 CD 7E  LDA $7ECD46
D0/DECC: 8D 03 21     STA $2103
D0/DECF: AB           PLB 
D0/DED0: 6B           RTL 

; [ clear vram ]

; +x: vram address
; +y: size

D0/DED1: 8B           PHB 
D0/DED2: A9 00        LDA #$00
D0/DED4: 48           PHA 
D0/DED5: AB           PLB 
D0/DED6: 8E 16 21     STX $2116
D0/DED9: A2 F8 DE     LDX #$DEF8      ; D0/DEF8 (16-bit constant zero)
D0/DEDC: 8E 52 43     STX $4352
D0/DEDF: A9 09        LDA #$09
D0/DEE1: 8D 50 43     STA $4350
D0/DEE4: A9 18        LDA #$18
D0/DEE6: 8D 51 43     STA $4351
D0/DEE9: A9 D0        LDA #$D0
D0/DEEB: 8D 54 43     STA $4354
D0/DEEE: 8C 55 43     STY $4355
D0/DEF1: A9 20        LDA #$20
D0/DEF3: 8D 0B 42     STA $420B
D0/DEF6: AB           PLB 
D0/DEF7: 6B           RTL 

; [ validate inventory ]

D0/EF78: 7B           TDC 
D0/EF79: AA           TAX 
D0/EF7A: BD 40 06     LDA $0640,X     ; item id
D0/EF7D: D0 03        BNE $EF82
D0/EF7F: 9E 40 07     STZ $0740,X
D0/EF82: BD 40 07     LDA $0740,X     ; item quantity
D0/EF85: D0 03        BNE $EF8A
D0/EF87: 9E 40 06     STZ $0640,X
D0/EF8A: E8           INX 
D0/EF8B: E0 00 01     CPX #$0100
D0/EF8E: D0 EA        BNE $EF7A
D0/EF90: 6B           RTL 

; ===============================[ battle graphics misc. ]================================

; [ wait for vblank ]

D9/7CAA: E6 A5        INC $A5
D9/7CAC: A5 A5        LDA $A5
D9/7CAE: 0D 9A DB     ORA $DB9A
D9/7CB1: D0 F9        BNE $7CAC
D9/7CB3: 6B           RTL 

; [ clear sprite data ]

D9/7CB4: A2 00 00     LDX #$0000
D9/7CB7: A9 F0        LDA #$F0
D9/7CB9: 9D 00 02     STA $0200,X
D9/7CBC: E8           INX 
D9/7CBD: E0 00 02     CPX #$0200
D9/7CC0: D0 F7        BNE $7CB9
D9/7CC2: A2 00 00     LDX #$0000
D9/7CC5: A9 00        LDA #$00
D9/7CC7: 9D 00 04     STA $0400,X
D9/7CCA: E8           INX 
D9/7CCB: E0 20 00     CPX #$0020
D9/7CCE: D0 F7        BNE $7CC7
D9/7CD0: 6B           RTL 
