diff options
author | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-07-21 12:15:14 -0400 |
---|---|---|
committer | Rangi <remy.oukaour+rangi42@gmail.com> | 2020-07-21 12:15:14 -0400 |
commit | d96f914315c6ab82d30facbc4a5be1710f3c4a33 (patch) | |
tree | 7ccab8f4b619268235420d1c59414bf7eff6395c | |
parent | a9941e28cc3beb33742ef072aaa46941606781fa (diff) |
Define JOHTO_FLYPOINT like KANTO_FLYPOINT
-rw-r--r-- | constants/map_data_constants.asm | 1 | ||||
-rw-r--r-- | engine/pokegear/pokegear.asm | 33 |
2 files changed, 10 insertions, 24 deletions
diff --git a/constants/map_data_constants.asm b/constants/map_data_constants.asm index 7746927dd..136456d95 100644 --- a/constants/map_data_constants.asm +++ b/constants/map_data_constants.asm @@ -102,6 +102,7 @@ NUM_SPAWNS EQU const_value ; Flypoints indexes (see data/maps/flypoints.asm) const_def ; johto +JOHTO_FLYPOINT EQU const_value const FLY_NEW_BARK const FLY_CHERRYGROVE const FLY_VIOLET diff --git a/engine/pokegear/pokegear.asm b/engine/pokegear/pokegear.asm index 15ef4eb0f..eed105e87 100644 --- a/engine/pokegear/pokegear.asm +++ b/engine/pokegear/pokegear.asm @@ -1452,7 +1452,6 @@ UpdateRadioStation: RadioChannels: ; entries correspond to constants/radio_constants.asm - ; frequency value given here = 4 × ingame_frequency − 2 dbw 16, .PKMNTalkAndPokedexShow ; 04.5 dbw 28, .PokemonMusic ; 07.5 @@ -1467,7 +1466,6 @@ RadioChannels: .PKMNTalkAndPokedexShow: ; Pokédex Show in the morning - ; Oak's Pokémon Talk in the afternoon and evening call .InJohto jr nc, .NoSignal @@ -1542,7 +1540,6 @@ RadioChannels: .InJohto: ; if in Johto or on the S.S. Aqua, set carry - ; otherwise clear carry ld a, [wPokegearMapPlayerIconLandmark] cp LANDMARK_FAST_SHIP @@ -2271,13 +2268,10 @@ FlyMap: .JohtoFlyMap: ; Note that .NoKanto should be modified in tandem with this branch push af -; Start from New Bark Town - ld a, FLY_NEW_BARK - ld [wTownMapPlayerIconLandmark], a -; Flypoints begin at New Bark Town... + ld a, JOHTO_FLYPOINT ; first Johto flypoint + ld [wTownMapPlayerIconLandmark], a ; first one is default (New Bark Town) ld [wStartFlypoint], a -; ..and end at Silver Cave. - ld a, FLY_MT_SILVER + ld a, KANTO_FLYPOINT - 1 ; last Johto flypoint ld [wEndFlypoint], a ; Fill out the map call FillJohtoMap @@ -2301,16 +2295,11 @@ FlyMap: and a jr z, .NoKanto ; Kanto's map is only loaded if we've visited Indigo Plateau - -; Flypoints begin at Pallet Town... - ld a, FLY_PALLET + ld a, KANTO_FLYPOINT ; first Kanto flypoint ld [wStartFlypoint], a -; ...and end at Indigo Plateau - ld a, FLY_INDIGO + ld a, NUM_FLYPOINTS - 1 ; last Kanto flypoint ld [wEndFlypoint], a -; Because Indigo Plateau is the first flypoint the player -; visits, it's made the default flypoint. - ld [wTownMapPlayerIconLandmark], a + ld [wTownMapPlayerIconLandmark], a ; last one is default (Indigo Plateau) ; Fill out the map call FillKantoMap call .MapHud @@ -2320,14 +2309,10 @@ FlyMap: .NoKanto: ; If Indigo Plateau hasn't been visited, we use Johto's map instead - -; Start from New Bark Town - ld a, FLY_NEW_BARK - ld [wTownMapPlayerIconLandmark], a -; Flypoints begin at New Bark Town... + ld a, JOHTO_FLYPOINT ; first Johto flypoint + ld [wTownMapPlayerIconLandmark], a ; first one is default (New Bark Town) ld [wStartFlypoint], a -; ..and end at Silver Cave - ld a, FLY_MT_SILVER + ld a, KANTO_FLYPOINT - 1 ; last Johto flypoint ld [wEndFlypoint], a call FillJohtoMap pop af |