ref: 4b8f71a59372da14e3c145f1eb3f642eee45a7c1
parent: 9e11a1e9960d6510f216974b3c687dd30f59e4ae
author: IIMarckus <iimarckus@gmail.com>
date: Sat Jul 30 19:25:17 EDT 2011
Add Good Rod data. hg-commit-id: 14c828bf56a2
--- a/pokered.asm
+++ b/pokered.asm
@@ -3444,9 +3444,69 @@
db 0
+INCBIN "baserom.gbc",$D5C7,$E259 - $D5C7
+GoodRodCode: ; 6259
+ call $62B4
+ jp c,$6581
+Next625F:
+ call $3E5C
+ srl a
+ jr c,Next6278
+ and 3
+ cp 2
+ jr nc,Next625F
+ ; choose which monster appears
+ ld hl,GoodRodMons
+ add a,a
+ ld c,a
+ ld b,0
+ add hl,bc
+ ld b,[hl]
+ inc hl
+ ld c,[hl]
+ and a
+Next6278:
+ ld a,0
+ rla
+ xor 1
+ jr Next628E
-INCBIN "baserom.gbc",$D5C7,$10000 - $D5C7
+GoodRodMons:
+ db 10,GOLDEEN
+ db 10,POLIWAG
+
+Next6283:
+ call $62B4
+ jp c,$6581
+Next6289:
+ call $68EA
+ ld a,e
+Next628E:
+ ld [$CD3D],a
+ dec a
+ jr nz,.next\@
+ ld a,1
+ ld [$D05F],a
+ ld a,b
+ ld [$D127],a
+ ld a,c
+ ld [$D059],a
+.next\@
+ ld hl,$D700
+ ld a,[hl]
+ push af
+ push hl
+ ld [hl],0
+ ld b,$1C
+ ld hl,$47B6
+ call Bankswitch
+ pop hl
+ pop af
+ ld [hl],a
+ ret
+
+INCBIN "baserom.gbc",$E2B4,$10000 - $E2B4
SECTION "bank4",DATA,BANK[$4]
INCBIN "baserom.gbc",$10000,$4000