Guides:Fast 0x1500 ACE: Difference between revisions
Jump to navigation
Jump to search
m
→Effect of the setup box name code
m (→English) |
|||
Line 487:
F5 push af
E1 pop hl ; hl = $F500
E6 EF and $
84 add a, h ; af = $DA10
F5 push af
Line 591:
<pre>
Box 1: $DB75
F5 push af
E1 pop hl ; hl = $F500
E6 E5 and $E5 ; a = $E5
84 add a, h ; af = $DA10
F5 push af
50 ld d, b
Box 2: $DB7E
FB ei ; Overwritten to $22, ldi (hl), a
D0 ret nc ; On first pass, ignored. Taken whenever $DB7F is called
D6 B9 sub $B9 ; a = $21
EA 81 FB ld ($FB81), a
50 ld d, b
Box 3: $DB87
D6 FF sub $FF ; a = $22
EA 7F FB ld ($FB7F), a
D6 F4 sub $F4 ; a = $2E
85 add a, l ; a = $3E, reset carry flag
50 ld d, b
Box 4: $DB90
E6 84 and $84 ; a = $04
50 ld d, b
Box 5: $DB99
D6 D5 sub $D5 ; a = $2F
EA 88 FB ld ($FB88), a
D6 FF sub $FF ; a = $30
FB ei
50 ld d, b
Box 6: $DBA2
EA 89
D6 FE sub $FE ; a = $32
EA 85 FB ld ($FB85), a
50 ld d, b
Box 7: $DBAB
D4 7F FB call nc, $FB7F
EA 87 FB ld ($FB87), a
50 ld d, b
Box 8: $DBB4
F5 push af
D6 A7 sub $A7 ; a = $59
A7 and a ; Reset carry flag
50 ld d, b
Box 9: $DBBD
EA 82 FB ld ($FB82), a
D6 81 sub $81 ; a = $D8
50 ld d, b
Box 10: $DBC6
D4 7F FB call nc, $FB7F
EA 83 FB ld ($FB83), a
F1 pop af ; a = $00
50 ld d, b
Box 11: $DBCF
D6 FF sub $FF ; a = $01
EA 84 FB ld ($FB84), a
E1 pop hl ; first of two pops to prevent side effects of 0x1500 ACE
F6 FF or $FF ; a = $FF
50 ld d, b
Box 12: $DBD8
D4 81 FB call nc, $FB81 ; $FB81 was rewritten to 21 59 D8 01 32 00 C3 2F 30
EA 82 FB ld ($FB82), a ; Replace $59 by $FF to prevent possible crash when viewing $59 as text
E1 pop hl ; second of two pops to prevent side effects of 0x1500 ACE
D6 50 sub $50 ; a = $AF
Box 13: $DBE1
D6 E1 sub $E1 ; a = $CE
EA 93 F8 ld (wItems), a ; Replace first item in item pocket with TM15
A7 and a ; Reset carry flag
D0 ret nc
FB ei
50 ld d, b
Box 14: displayed as screen tiles at $C4BE
AF xor a ; a = $00
F6 FB or $FB ; a = $FB
F5 push af
E1 pop hl ; h = $FB
D6 86 sub $86 ; a = $75
F7 rst30h ; hl = $FB75, de = $C4C5, jump to hl
Bootstrap: $DA10
Line 664 ⟶ 698:
<pre>
Box 1: $DB75
F5 push af
E1 pop hl ; hl = $F500
E6 E5 and $E5 ; a = $E5
84 add a, h ; af = $DA10
F5 push af
50 ld d, b
Box 2: $DB7E
FB ei ; Overwritten to $22, ldi (hl), a
D0 ret nc ; On first pass, ignored. Taken whenever $DB7F is called
D6 B9 sub $B9 ; a = $21
EA 81 FB ld ($FB81), a
50 ld d, b
Box 3: $DB87
D6 FF sub $FF ; a = $22
EA 7F FB ld ($FB7F), a
D6 F4 sub $F4 ; a = $2E
85 add a, l ; a = $3E, reset carry flag
50 ld d, b
Box 4: $DB90
E6 84 and $84 ; a = $04
50 ld d, b
Box 5: $DB99
D6 D4 sub $D4 ; a = $30
EA 89 FB ld ($FB89), a
C6 FB add $FB ; a = $2B
FB ei
50 ld d, b
Box 6: $DBA2
EA 88
D6 F9 sub $F9 ; a = $32
EA 85 FB ld ($FB85), a
50 ld d, b
Box 7: $DBAB
D4 7F FB call nc, $FB7F
EA 87 FB ld ($FB87), a
50 ld d, b
Box 8: $DBB4
F5 push af
D6 A7 sub $A7 ; a = $59
A7 and a ; Reset carry flag
50 ld d, b
Box 9: $DBBD
EA 82 FB ld ($FB82), a
D6 81 sub $81 ; a = $D8
50 ld d, b
Box 10: $DBC6
D4 7F FB call nc, $FB7F
EA 83 FB ld ($FB83), a
F1 pop af ; a = $00
50 ld d, b
Box 11: $DBCF
D6 FF sub $FF ; a = $01
EA 84 FB ld ($FB84), a
E1 pop hl ; first of two pops to prevent side effects of 0x1500 ACE
F6 FF or $FF ; a = $FF
50 ld d, b
Box 12: $DBD8
D4 81 FB call nc, $FB81 ; $FB81 was rewritten to 21 59 D8 01 32 00 C3 2B 30
EA 82 FB ld ($FB82), a ; Replace $59 by $FF to prevent possible crash when viewing $59 as text
E1 pop hl ; second of two pops to prevent side effects of 0x1500 ACE
D6 50 sub $50 ; a = $AF
Box 13: $DBE1
D6 E1 sub $E1 ; a = $CE
EA 93 F8 ld (wItems), a ; Replace first item in item pocket with TM15
A7 and a ; Reset carry flag
D0 ret nc
FB ei
50 ld d, b
Box 14: displayed as screen tiles at $C4BE
AF xor a ; a = $00
F6 FB or $FB ; a = $FB
F5 push af
E1 pop hl ; h = $FB
D6 86 sub $86 ; a = $75
F7 rst30h ; hl = $FB75, de = $C4C5, jump to hl
Bootstrap: $DA10
|