Thinking of a bootstrap (Red/Green/Blue JP)
Posted by: metalmario32
Date: 2018-06-06 13:49:34
[li]Exactly 5 Pokémon in your party[/li]
[li]Pidgey as the first Pokémon[/li]
[li]Parasect as the second Pokémon[/li]
[li]Raticate as the third Pokémon[/li]
[li]Tentacool as the fourth Pokémon[/li]
[li]Nidoran or Clefairy as the fifth Pokémon[/li]
[li]Pidgey must have 233 HP[/li]
This bootstrap redirects code to the third item. This bootstrap was based off the ENG setup for 8F by pigdevil2010. I was wondering if this bootstrap would work, due to how the memory addresses are different in the JP games, not following specific offsets for every portion of memory.
EDIT: Here's the RAM and ASM:
[tt]Initial hl: $D123
$D123 <- 05 || dec b
$D124 <- 24 || inc h; h = $D2
$D125 <- 2E ||
$D126 <- A6 || ld l, $A6; hl = $D2A6
$D127 <- 18 ||
$D128 <- 03 || jr $03; pc = D12C
$D12C <- 00 || nop
$D12D <- E9 || jp (hl); pc = $D2A6
alternatively:
$D128 <- 04 || jr $04; pc = $D12D[/tt]