mirror of
https://github.com/thornAvery/kep-hack.git
synced 2025-09-17 02:40:50 +12:00
Groundwork for new Vermilion Pass system
Alright so this is the start of producing a new and improved pass system - one that actually works. Long story short: Now there are three dock entrances. One for the S.S. Anne, one for Citrine City, and one for Faraway Island. I don't like it, but the old system literally just would not work, and with the time span in mind, I just want to use this instead. Here's how it works; - Usual S.S. Anne trigger is used, but with a new coordinate range. - When triggered, check the coordinates the player is in; if it's not the usual S.S. Anne one, they're getting kicked to a new script. - Use that to flag the player as usual. Glitches: - Triggering these multiple times causes strange jank, including crashes. I have the player forced into the new maps for now, but even going back can cause issues. I don't understand it. - Citrine City's warp just...doesn't work, presumably due to a warp limit. However, after chopping off the warps so there's one each, it still happens. These glitches need fixing before KEP can launch.
This commit is contained in:
parent
fe45fe99c1
commit
72a372dcde
|
@ -10,17 +10,17 @@ VermilionCity_Object:
|
||||||
warp_event 18, 31, VERMILION_DOCK, 1
|
warp_event 18, 31, VERMILION_DOCK, 1
|
||||||
warp_event 19, 31, VERMILION_DOCK, 1
|
warp_event 19, 31, VERMILION_DOCK, 1
|
||||||
warp_event 15, 13, VERMILION_TRADE_HOUSE, 1
|
warp_event 15, 13, VERMILION_TRADE_HOUSE, 1
|
||||||
warp_event 10, 31, CITRINE_CITY, 7
|
warp_event 10, 31, FARAWAY_ISLAND_OUTSIDE, 1
|
||||||
warp_event 11, 31, CITRINE_CITY, 8
|
warp_event 26, 31, CITRINE_CITY, 7
|
||||||
|
|
||||||
def_bg_events
|
def_bg_events
|
||||||
bg_event 27, 3, 9 ; VermilionCityText7
|
bg_event 27, 3, 11 ; VermilionCityText7
|
||||||
bg_event 37, 13, 10 ; VermilionCityText8
|
bg_event 37, 13, 12 ; VermilionCityText8
|
||||||
bg_event 24, 13, 11 ; MartSignText
|
bg_event 24, 13, 13 ; MartSignText
|
||||||
bg_event 12, 3, 12 ; PokeCenterSignText
|
bg_event 12, 3, 14 ; PokeCenterSignText
|
||||||
bg_event 7, 13, 13 ; VermilionCityText11
|
bg_event 7, 13, 15 ; VermilionCityText11
|
||||||
bg_event 7, 19, 14 ; VermilionCityText12
|
bg_event 7, 19, 16 ; VermilionCityText12
|
||||||
bg_event 29, 15, 15 ; VermilionCityText13
|
bg_event 29, 15, 17 ; VermilionCityText13
|
||||||
|
|
||||||
def_object_events
|
def_object_events
|
||||||
object_event 23, 5, SPRITE_BEAUTY, WALK, LEFT_RIGHT, 1 ; person
|
object_event 23, 5, SPRITE_BEAUTY, WALK, LEFT_RIGHT, 1 ; person
|
||||||
|
@ -31,5 +31,7 @@ VermilionCity_Object:
|
||||||
object_event 25, 27, SPRITE_SAILOR, WALK, LEFT_RIGHT, 6 ; person
|
object_event 25, 27, SPRITE_SAILOR, WALK, LEFT_RIGHT, 6 ; person
|
||||||
object_event 19, 8, SPRITE_OFFICER_JENNY, STAY, ANY_DIR, 7 ; squirtle event
|
object_event 19, 8, SPRITE_OFFICER_JENNY, STAY, ANY_DIR, 7 ; squirtle event
|
||||||
object_event 12, 13, SPRITE_BEAUTY, STAY, DOWN, 8 ; arc/pers event
|
object_event 12, 13, SPRITE_BEAUTY, STAY, DOWN, 8 ; arc/pers event
|
||||||
|
object_event 11, 30, SPRITE_SAILOR, STAY, UP, 9 ; person - Faraway Island
|
||||||
|
object_event 27, 30, SPRITE_SAILOR, STAY, UP, 10 ; person - Citrine City
|
||||||
|
|
||||||
def_warps_to VERMILION_CITY
|
def_warps_to VERMILION_CITY
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
CCC ! ! !1 !11111111Ckk7~|r7~17~wVwww111Cd1111111111111111C-111111111IH111CCC-111111DE111CCC !C !11 !111111Cd|~1|~11|swwwwVwCd1111111111111111Cd1
1111 !TCdV21|~edTeCCCCd11111ed111e-T.CCCCd11111e-.CTCdC-.CCCCCCTCdCCCCTTTTTTTTTTTC-gCCCCTxxxTxxxxxxCCCkkkTkTkkkkkkkCCCCCCCCCCCCCCCCCCCCCCCCTCCCTCCCCCCCCCC
|
CCC ! ! !1 !11111111Ckk7~|r7~17~wVwww111Cd1111111111111111C-111111111IH111CCC-111111DE111CCC !C !11 !111111Cd|~1|~11|swwwwVwCd1111111111111111Cd1
1111 !TCdV21|~edTeCCCCd11111ed111e-T.CCCCd11111e-.CTCdC-.CCCCCCTCdCCCCTTTTTTTTTTTC-gCCCCTxxxTxxxTxxCCCkkkTkTkTkkkCCCCCCCCCCCCTCCCCCCCCCCCTCCCTCCCTCCCCCC
|
|
@ -48,7 +48,7 @@ ChiefLetter2:
|
||||||
ld a, $1 ; Load Mom's NPC ID
|
ld a, $1 ; Load Mom's NPC ID
|
||||||
ldh [hSpriteIndex], a ; Slap it in the index
|
ldh [hSpriteIndex], a ; Slap it in the index
|
||||||
ld a, SPRITE_FACING_RIGHT ; Get this ready
|
ld a, SPRITE_FACING_RIGHT ; Get this ready
|
||||||
ldh [hSpriteFacingDirection], a ; Now she'll face right, simulatiung talking to her.
|
ldh [hSpriteFacingDirection], a ; Now she'll face right, simulating talking to her.
|
||||||
call SetSpriteFacingDirectionAndDelay ; Get this all out.
|
call SetSpriteFacingDirectionAndDelay ; Get this all out.
|
||||||
call DisplayTextID ; Display her text ID, using the same thing from before.
|
call DisplayTextID ; Display her text ID, using the same thing from before.
|
||||||
; We did a little tomfoolery with her base text to make this work. Look below if you dare.
|
; We did a little tomfoolery with her base text to make this work. Look below if you dare.
|
||||||
|
|
|
@ -56,6 +56,13 @@ VermilionCityScript0:
|
||||||
CheckEvent EVENT_SS_ANNE_LEFT
|
CheckEvent EVENT_SS_ANNE_LEFT
|
||||||
jr nz, .shipHasDeparted
|
jr nz, .shipHasDeparted
|
||||||
.default
|
.default
|
||||||
|
ld hl, OldSeaMapCheckCoords
|
||||||
|
call ArePlayerCoordsInArray
|
||||||
|
jp c, MovePlayerVermilion
|
||||||
|
ld hl, CitrineCityCheckCoords
|
||||||
|
call ArePlayerCoordsInArray
|
||||||
|
jp c, MovePlayerVermilion
|
||||||
|
|
||||||
ld b, S_S_TICKET
|
ld b, S_S_TICKET
|
||||||
predef GetQuantityOfItemInBag
|
predef GetQuantityOfItemInBag
|
||||||
ld a, b
|
ld a, b
|
||||||
|
@ -71,10 +78,22 @@ VermilionCityScript0:
|
||||||
ld [wVermilionCityCurScript], a
|
ld [wVermilionCityCurScript], a
|
||||||
ret
|
ret
|
||||||
|
|
||||||
SSAnneTicketCheckCoords:
|
SSAnneTicketCheckCoords: ; Mother coords - use to universally trigger the same event
|
||||||
dbmapcoord 18, 30
|
dbmapcoord 18, 30 ; S. S. Anne
|
||||||
|
dbmapcoord 10, 30 ; Faraway Island
|
||||||
|
dbmapcoord 26, 30 ; Citrine City
|
||||||
db -1 ; end
|
db -1 ; end
|
||||||
|
|
||||||
|
; I know it looks awful but I use the individual ones to launch off the new ticket script.
|
||||||
|
; We don't need an S.S. Anne one, as I'm using a process of elimination check system.
|
||||||
|
OldSeaMapCheckCoords:
|
||||||
|
dbmapcoord 10, 30
|
||||||
|
db -1
|
||||||
|
|
||||||
|
CitrineCityCheckCoords:
|
||||||
|
dbmapcoord 26, 30
|
||||||
|
db -1
|
||||||
|
|
||||||
VermilionCityScript4:
|
VermilionCityScript4:
|
||||||
ld hl, SSAnneTicketCheckCoords
|
ld hl, SSAnneTicketCheckCoords
|
||||||
call ArePlayerCoordsInArray
|
call ArePlayerCoordsInArray
|
||||||
|
@ -117,145 +136,186 @@ VermilionCityScript1:
|
||||||
ld [wVermilionCityCurScript], a
|
ld [wVermilionCityCurScript], a
|
||||||
ret
|
ret
|
||||||
|
|
||||||
; New Pass script begins here
|
; We call these four commands to stop text from autoskipping 4 times, may as well just make this.
|
||||||
VermillionCityScript_GetPassesInBag:
|
TheAutoskipStopinator:
|
||||||
|
ld a, [wSimulatedJoypadStatesEnd] ; ensuring that the text doesn't autoskip.
|
||||||
|
and a ; yep, here too.
|
||||||
|
call z, WaitForTextScrollButtonPress ; and here.
|
||||||
|
call EnableAutoTextBoxDrawing ; and here.
|
||||||
|
ret
|
||||||
|
|
||||||
|
; So get this: If you check multiple tickets, there's a really janky crash.
|
||||||
|
; I can't be fucked fixing it, so let's force the player through the warp instead.
|
||||||
|
; Yes, I'm serious.
|
||||||
|
MovePlayerVermilion:
|
||||||
|
ld a, PLAYER_DIR_DOWN
|
||||||
|
ld [wPlayerMovingDirection], a
|
||||||
|
call UpdateSprites
|
||||||
|
ld a, $ff ; Firstly...
|
||||||
|
ld [wJoyIgnore], a ; No joypad inputs. No funny business. RLE is weird as fuck without it.
|
||||||
|
ld hl, wSimulatedJoypadStatesEnd
|
||||||
|
ld de, WalkIntoWarp_RLEMovement
|
||||||
|
call DecodeRLEList
|
||||||
|
dec a
|
||||||
|
ld [wSimulatedJoypadStatesIndex], a
|
||||||
|
call StartSimulatingJoypadStates ; By this point, we're auto-moving.
|
||||||
|
ld a, $0
|
||||||
|
ld [wVermilionCityCurScript], a ; safety
|
||||||
|
ret
|
||||||
|
|
||||||
|
WalkIntoWarp_RLEMovement:
|
||||||
|
db D_DOWN, 2
|
||||||
|
db -1 ; end
|
||||||
|
|
||||||
|
; ================================================================
|
||||||
|
; THIS IS NO LONGER USED, KEPT IN CASE A BETTER WARP SYSTEM COMES UP.
|
||||||
|
; Alright, so I'll explain the issue.
|
||||||
|
; For some reason, all the warp methods that exist do not seem to like this system.
|
||||||
|
; Faraway Island would load but have botched collision and break when you leave.
|
||||||
|
; Citrine City would outright crash.
|
||||||
|
; Bank movements and stuff were tried but nothing seemed to work as desired.
|
||||||
|
; Instead, we use a triple-harbour method, which makes the city look more lively anyway.
|
||||||
|
|
||||||
|
;VermillionCityScript_GetPassesInBag:
|
||||||
; Gets a list of Passes in the player's bag.
|
; Gets a list of Passes in the player's bag.
|
||||||
; Ripped and modified from the fossil guy
|
; Ripped and modified from the fossil guy
|
||||||
xor a
|
; xor a
|
||||||
ld [wFilteredBagItemsCount], a
|
; ld [wFilteredBagItemsCount], a
|
||||||
ld de, wFilteredBagItems
|
; ld de, wFilteredBagItems
|
||||||
ld hl, PassList
|
; ld hl, PassList
|
||||||
.loop
|
;.loop
|
||||||
ld a, [hli]
|
; ld a, [hli]
|
||||||
and a
|
; and a
|
||||||
jr z, .done
|
; jr z, .done
|
||||||
push hl
|
; push hl
|
||||||
push de
|
; push de
|
||||||
ld [wd11e], a
|
; ld [wd11e], a
|
||||||
ld b, a
|
; ld b, a
|
||||||
predef GetQuantityOfItemInBag
|
; predef GetQuantityOfItemInBag
|
||||||
pop de
|
; pop de
|
||||||
pop hl
|
; pop hl
|
||||||
ld a, b
|
; ld a, b
|
||||||
and a
|
; and a
|
||||||
jr z, .loop
|
; jr z, .loop
|
||||||
|
|
||||||
; A Pass is in the bag
|
; ; A Pass is in the bag
|
||||||
ld a, [wd11e]
|
; ld a, [wd11e]
|
||||||
ld [de], a
|
; ld [de], a
|
||||||
inc de
|
; inc de
|
||||||
push hl
|
; push hl
|
||||||
ld hl, wFilteredBagItemsCount
|
; ld hl, wFilteredBagItemsCount
|
||||||
inc [hl]
|
; inc [hl]
|
||||||
pop hl
|
; pop hl
|
||||||
jr .loop
|
; jr .loop
|
||||||
.done
|
;.done
|
||||||
ld a, $ff
|
; ld a, $ff
|
||||||
ld [de], a
|
; ld [de], a
|
||||||
ret
|
; ret
|
||||||
|
|
||||||
PassList:
|
;PassList:
|
||||||
db S_S_TICKET
|
; db S_S_TICKET
|
||||||
db OLD_SEA_MAP
|
; db OLD_SEA_MAP
|
||||||
db CITRINE_PASS
|
; db CITRINE_PASS
|
||||||
;db RAINBOW_PASS maybe someday
|
; ;db RAINBOW_PASS I planned this for a while, but the space wasn't there, and the scope was strange.
|
||||||
db 0 ; end
|
; db 0 ; end
|
||||||
|
|
||||||
PrintPassesInBag:
|
;PrintPassesInBag:
|
||||||
; Prints each pass in the player's bag on a separate line in the menu.
|
; Prints each pass in the player's bag on a separate line in the menu.
|
||||||
ld hl, wFilteredBagItems
|
; ld hl, wFilteredBagItems
|
||||||
xor a
|
; xor a
|
||||||
ldh [hItemCounter], a
|
; ldh [hItemCounter], a
|
||||||
.loop
|
;.loop
|
||||||
ld a, [hli]
|
; ld a, [hli]
|
||||||
cp $ff
|
; cp $ff
|
||||||
ret z
|
; ret z
|
||||||
push hl
|
; push hl
|
||||||
ld [wd11e], a
|
; ld [wd11e], a
|
||||||
call GetItemName
|
; call GetItemName
|
||||||
hlcoord 2, 2
|
; hlcoord 2, 2
|
||||||
ldh a, [hItemCounter]
|
; ldh a, [hItemCounter]
|
||||||
ld bc, SCREEN_WIDTH * 2
|
; ld bc, SCREEN_WIDTH * 2
|
||||||
call AddNTimes
|
; call AddNTimes
|
||||||
ld de, wcd6d
|
; ld de, wcd6d
|
||||||
call PlaceString
|
; call PlaceString
|
||||||
ld hl, hItemCounter
|
; ld hl, hItemCounter
|
||||||
inc [hl]
|
; inc [hl]
|
||||||
pop hl
|
; pop hl
|
||||||
jr .loop
|
; jr .loop
|
||||||
|
|
||||||
PassListings:
|
;PassListings:
|
||||||
ld hl, VermillionCityPassSelectionText
|
; ld hl, VermillionCityPassSelectionText
|
||||||
call PrintText
|
; call PrintText
|
||||||
call VermillionCityScript_GetPassesInBag
|
; call VermillionCityScript_GetPassesInBag
|
||||||
ld hl, wd730
|
; ld hl, wd730
|
||||||
set 6, [hl]
|
; set 6, [hl]
|
||||||
xor a
|
; xor a
|
||||||
ld [wCurrentMenuItem], a
|
; ld [wCurrentMenuItem], a
|
||||||
ld a, A_BUTTON | B_BUTTON
|
; ld a, A_BUTTON | B_BUTTON
|
||||||
ld [wMenuWatchedKeys], a
|
; ld [wMenuWatchedKeys], a
|
||||||
ld a, [wFilteredBagItemsCount]
|
; ld a, [wFilteredBagItemsCount]
|
||||||
dec a
|
; dec a
|
||||||
ld [wMaxMenuItem], a
|
; ld [wMaxMenuItem], a
|
||||||
ld a, 2
|
; ld a, 2
|
||||||
ld [wTopMenuItemY], a
|
; ld [wTopMenuItemY], a
|
||||||
ld a, 1
|
; ld a, 1
|
||||||
ld [wTopMenuItemX], a
|
; ld [wTopMenuItemX], a
|
||||||
ld a, [wFilteredBagItemsCount]
|
; ld a, [wFilteredBagItemsCount]
|
||||||
dec a
|
; dec a
|
||||||
ld bc, 2
|
; ld bc, 2
|
||||||
ld hl, 3
|
; ld hl, 3
|
||||||
call AddNTimes
|
; call AddNTimes
|
||||||
dec l
|
; dec l
|
||||||
ld b, l
|
; ld b, l
|
||||||
ld c, $d
|
; ld c, $d
|
||||||
hlcoord 0, 0
|
; hlcoord 0, 0
|
||||||
call TextBoxBorder
|
; call TextBoxBorder
|
||||||
call UpdateSprites
|
; call UpdateSprites
|
||||||
call PrintPassesInBag
|
; call PrintPassesInBag
|
||||||
ld hl, wd730
|
; ld hl, wd730
|
||||||
res 6, [hl]
|
; res 6, [hl]
|
||||||
call HandleMenuInput
|
; call HandleMenuInput
|
||||||
bit BIT_B_BUTTON, a
|
; bit BIT_B_BUTTON, a
|
||||||
jr nz, .cancelledPass
|
; jr nz, .cancelledPass
|
||||||
ld hl, wFilteredBagItems
|
; ld hl, wFilteredBagItems
|
||||||
ld a, [wCurrentMenuItem]
|
; ld a, [wCurrentMenuItem]
|
||||||
ld d, 0
|
; ld d, 0
|
||||||
ld e, a
|
; ld e, a
|
||||||
add hl, de
|
; add hl, de
|
||||||
ld a, [hl]
|
; ld a, [hl]
|
||||||
ldh [hItemToRemoveID], a
|
; ldh [hItemToRemoveID], a
|
||||||
cp S_S_TICKET
|
; cp S_S_TICKET
|
||||||
jp z, VermilionCityText3.playerHasTicket ; Saves time and less risk of bugs
|
; jp z, VermilionCityText3.playerHasTicket ; Saves time and less risk of bugs
|
||||||
cp OLD_SEA_MAP
|
; cp OLD_SEA_MAP
|
||||||
jr z, .choseFaraway
|
; jr z, .choseFaraway
|
||||||
cp CITRINE_PASS
|
; cp CITRINE_PASS
|
||||||
jr z, .choseCitrine
|
; jr z, .choseCitrine
|
||||||
; god bless the safari game and pokemon tower 7f for being the few times a forcewarp exists
|
; god bless the safari game and pokemon tower 7f for being the few times a forcewarp exists
|
||||||
; For some reason, these aren't working properly...
|
; For some reason, these aren't working properly...
|
||||||
.choseFaraway
|
;.choseFaraway
|
||||||
ld hl, EventVermillionCityOldSeaMap
|
; ld hl, EventVermillionCityOldSeaMap
|
||||||
call PrintText
|
; call PrintText
|
||||||
ld a, FARAWAY_ISLAND_OUTSIDE
|
; ld a, FARAWAY_ISLAND_OUTSIDE
|
||||||
ld [wDestinationMap], a
|
; ld [wDestinationMap], a
|
||||||
ld hl, wd732
|
; ld hl, wd732
|
||||||
set 2, [hl] ; fly warp or dungeon warp
|
; set 2, [hl] ; fly warp or dungeon warp
|
||||||
call SpecialWarpIn
|
; call SpecialWarpIn
|
||||||
jp SpecialEnterMap
|
; jp SpecialEnterMap
|
||||||
.choseCitrine
|
;.choseCitrine
|
||||||
ld hl, EventVermillionCityCitrinePass
|
; ld hl, EventVermillionCityCitrinePass
|
||||||
call PrintText
|
; call PrintText
|
||||||
ld a, CITRINE_CITY
|
; ld a, CITRINE_CITY
|
||||||
ldh [hWarpDestinationMap], a
|
; ldh [hWarpDestinationMap], a
|
||||||
ld a, $6
|
; ld a, $6
|
||||||
ld [wDestinationWarpID], a
|
; ld [wDestinationWarpID], a
|
||||||
call WarpFound2
|
; call WarpFound2
|
||||||
jr .done
|
; jr .done
|
||||||
.cancelledPass
|
;.cancelledPass
|
||||||
ld hl, PassRefuse
|
; ld hl, PassRefuse
|
||||||
call PrintText
|
; call PrintText
|
||||||
.done
|
;.done
|
||||||
ret
|
; ret
|
||||||
|
;
|
||||||
|
; ================================================================
|
||||||
|
|
||||||
VermilionCity_TextPointers:
|
VermilionCity_TextPointers:
|
||||||
dw VermilionCityText1
|
dw VermilionCityText1
|
||||||
|
@ -266,6 +326,8 @@ VermilionCity_TextPointers:
|
||||||
dw VermilionCityText6
|
dw VermilionCityText6
|
||||||
dw OfficerJennySquirtle
|
dw OfficerJennySquirtle
|
||||||
dw VermilionBeauty
|
dw VermilionBeauty
|
||||||
|
dw EventVermillionCityOldSeaMapGreeting
|
||||||
|
dw EventVermillionCityCitrinePassGreeting
|
||||||
dw VermilionCityText7
|
dw VermilionCityText7
|
||||||
dw VermilionCityText8
|
dw VermilionCityText8
|
||||||
dw MartSignText
|
dw MartSignText
|
||||||
|
@ -302,25 +364,36 @@ VermilionCityTextSSAnneDeparted:
|
||||||
VermilionCityText3:
|
VermilionCityText3:
|
||||||
text_asm
|
text_asm
|
||||||
|
|
||||||
; If you have either of these, go to Pass List.
|
; Checking the location that the script flagged earlier.
|
||||||
; You only access these in the post-game, really, so it works out.
|
; Instead of using an item checker, this is more effective and easy on memory.
|
||||||
ld b, OLD_SEA_MAP
|
; Also, it doesn't get cross-threaded if you have multiples of the same thing. I had issues working around that one - I ain't a programmer by trade, unfortunately, I'm a TEFL student.
|
||||||
predef GetQuantityOfItemInBag
|
; Anyway, the code kicks you to different versions of the same script; I've had them isolated to call text in a way that's easier architecturally. Otherwise, we're checking the item found every time, and I'm 90% sure that nicks a WRAM entry.
|
||||||
ld a, b
|
; All in all: Yes, this is suboptimal, but I've been doing this for months. Sue me.
|
||||||
and a
|
ld hl, OldSeaMapCheckCoords
|
||||||
jp nz, PassListings
|
call ArePlayerCoordsInArray
|
||||||
ld b, CITRINE_PASS
|
jr c, HasOldSeaMap
|
||||||
predef GetQuantityOfItemInBag
|
ld hl, CitrineCityCheckCoords
|
||||||
ld a, b
|
call ArePlayerCoordsInArray
|
||||||
and a
|
jp c, HasCitrinePass
|
||||||
jp nz, PassListings
|
|
||||||
|
; If you have neither, this will continue as normal, see?
|
||||||
|
; This is why we needed the child coords.
|
||||||
|
|
||||||
|
; Before the coord system, we used this with the unused pass listing code.
|
||||||
|
; See where the issues arose? Possibly a neat exercise!
|
||||||
|
;ld b, OLD_SEA_MAP
|
||||||
|
;predef GetQuantityOfItemInBag
|
||||||
|
;ld a, b
|
||||||
|
;and a
|
||||||
|
;jp nz, PassListings
|
||||||
|
;ld b, CITRINE_PASS
|
||||||
|
;predef GetQuantityOfItemInBag
|
||||||
|
;ld a, b
|
||||||
|
;and a
|
||||||
|
;jp nz, PassListings
|
||||||
|
|
||||||
ld a, [wObtainedBadges]
|
|
||||||
bit 5, a ; after obtaining marsh badge the ship returns
|
|
||||||
jr nz, .default
|
|
||||||
CheckEvent EVENT_SS_ANNE_LEFT
|
CheckEvent EVENT_SS_ANNE_LEFT
|
||||||
jr nz, .shipHasDeparted
|
jr nz, .shipHasDeparted
|
||||||
.default
|
|
||||||
ld a, [wSpritePlayerStateData1FacingDirection]
|
ld a, [wSpritePlayerStateData1FacingDirection]
|
||||||
cp SPRITE_FACING_RIGHT
|
cp SPRITE_FACING_RIGHT
|
||||||
jr z, .greetPlayer
|
jr z, .greetPlayer
|
||||||
|
@ -334,6 +407,7 @@ VermilionCityText3:
|
||||||
.greetPlayerAndCheckTicket
|
.greetPlayerAndCheckTicket
|
||||||
ld hl, SSAnneWelcomeText9
|
ld hl, SSAnneWelcomeText9
|
||||||
call PrintText
|
call PrintText
|
||||||
|
call TheAutoskipStopinator ; this actually fixes a bug from vanilla...
|
||||||
ld b, S_S_TICKET
|
ld b, S_S_TICKET
|
||||||
predef GetQuantityOfItemInBag
|
predef GetQuantityOfItemInBag
|
||||||
ld a, b
|
ld a, b
|
||||||
|
@ -354,9 +428,13 @@ VermilionCityText3:
|
||||||
.end
|
.end
|
||||||
jp TextScriptEnd
|
jp TextScriptEnd
|
||||||
|
|
||||||
.inFrontOfOrBehindGuardCoords
|
.inFrontOfOrBehindGuardCoords ; This can be all at once don't worry.
|
||||||
dbmapcoord 19, 29 ; in front of guard
|
dbmapcoord 19, 29 ; in front of guard - S. S. Anne
|
||||||
dbmapcoord 19, 31 ; behind guard
|
dbmapcoord 19, 31 ; behind guard - S. S. Anne
|
||||||
|
dbmapcoord 11, 29 ; Faraway Island
|
||||||
|
dbmapcoord 11, 31 ; Faraway Island
|
||||||
|
dbmapcoord 27, 29 ; Citrine City
|
||||||
|
dbmapcoord 27, 31 ; Citrine City
|
||||||
db -1 ; end
|
db -1 ; end
|
||||||
|
|
||||||
SSAnneWelcomeText4:
|
SSAnneWelcomeText4:
|
||||||
|
@ -379,6 +457,93 @@ SSAnneNotHereText:
|
||||||
text_far _SSAnneNotHereText
|
text_far _SSAnneNotHereText
|
||||||
text_end
|
text_end
|
||||||
|
|
||||||
|
HasOldSeaMap:
|
||||||
|
text_asm
|
||||||
|
ld a, [wSpritePlayerStateData1FacingDirection]
|
||||||
|
cp SPRITE_FACING_RIGHT
|
||||||
|
jr z, .greetPlayer
|
||||||
|
ld hl, VermilionCityText3.inFrontOfOrBehindGuardCoords
|
||||||
|
call ArePlayerCoordsInArray
|
||||||
|
jr nc, .greetPlayerAndCheckTicket
|
||||||
|
.greetPlayer
|
||||||
|
ld hl, EventVermillionCityOldSeaMapGreeting
|
||||||
|
call PrintText
|
||||||
|
jr .end
|
||||||
|
.greetPlayerAndCheckTicket
|
||||||
|
ld hl, EventVermillionCityOldSeaMapGreeting
|
||||||
|
call PrintText
|
||||||
|
call TheAutoskipStopinator
|
||||||
|
ld b, OLD_SEA_MAP
|
||||||
|
predef GetQuantityOfItemInBag
|
||||||
|
ld a, b
|
||||||
|
and a
|
||||||
|
jr nz, .playerHasTicket
|
||||||
|
ld hl, EventVermillionCityOldSeaMapGreetCheck
|
||||||
|
call PrintText
|
||||||
|
jr .end
|
||||||
|
.playerHasTicket
|
||||||
|
ld hl, EventVermillionCityOldSeaMap
|
||||||
|
call PrintText
|
||||||
|
ld a, $4
|
||||||
|
ld [wVermilionCityCurScript], a
|
||||||
|
.end
|
||||||
|
jp TextScriptEnd
|
||||||
|
|
||||||
|
EventVermillionCityOldSeaMapGreeting:
|
||||||
|
text "I am looking for"
|
||||||
|
line "a certain map..."
|
||||||
|
done
|
||||||
|
text_end
|
||||||
|
|
||||||
|
EventVermillionCityOldSeaMapGreetCheck:
|
||||||
|
text "Do you have it?"
|
||||||
|
done
|
||||||
|
text_end
|
||||||
|
|
||||||
|
HasCitrinePass:
|
||||||
|
text_asm
|
||||||
|
ld a, [wSpritePlayerStateData1FacingDirection]
|
||||||
|
cp SPRITE_FACING_RIGHT
|
||||||
|
jr z, .greetPlayer
|
||||||
|
ld hl, VermilionCityText3.inFrontOfOrBehindGuardCoords
|
||||||
|
call ArePlayerCoordsInArray
|
||||||
|
jr nc, .greetPlayerAndCheckTicket
|
||||||
|
.greetPlayer
|
||||||
|
ld hl, EventVermillionCityCitrinePassGreeting
|
||||||
|
call PrintText
|
||||||
|
jr .end
|
||||||
|
.greetPlayerAndCheckTicket
|
||||||
|
ld hl, EventVermillionCityCitrinePassGreeting
|
||||||
|
call PrintText
|
||||||
|
call TheAutoskipStopinator
|
||||||
|
ld b, CITRINE_PASS
|
||||||
|
predef GetQuantityOfItemInBag
|
||||||
|
ld a, b
|
||||||
|
and a
|
||||||
|
jr nz, .playerHasTicket
|
||||||
|
ld hl, EventVermillionCityCitrinePassGreetCheck
|
||||||
|
call PrintText
|
||||||
|
jr .end
|
||||||
|
.playerHasTicket
|
||||||
|
ld hl, EventVermillionCityCitrinePass
|
||||||
|
call PrintText
|
||||||
|
ld a, $4
|
||||||
|
ld [wVermilionCityCurScript], a
|
||||||
|
.end
|
||||||
|
jp TextScriptEnd
|
||||||
|
|
||||||
|
EventVermillionCityCitrinePassGreeting:
|
||||||
|
text "Hah! I only serve"
|
||||||
|
line "strong TRAINERs!"
|
||||||
|
done
|
||||||
|
text_end
|
||||||
|
|
||||||
|
EventVermillionCityCitrinePassGreetCheck:
|
||||||
|
text "Gonna need to see"
|
||||||
|
line "proof, shrimp!"
|
||||||
|
done
|
||||||
|
text_end
|
||||||
|
|
||||||
VermilionCityText4:
|
VermilionCityText4:
|
||||||
text_far _VermilionCityText4
|
text_far _VermilionCityText4
|
||||||
text_end
|
text_end
|
||||||
|
@ -581,10 +746,7 @@ VermilionBeauty:
|
||||||
ld hl, BeautyFinish2
|
ld hl, BeautyFinish2
|
||||||
.skip2
|
.skip2
|
||||||
call PrintText
|
call PrintText
|
||||||
ld a, [wSimulatedJoypadStatesEnd] ; ensuring that the text doesn't autoskip.
|
call TheAutoskipStopinator
|
||||||
and a ; yep, here too.
|
|
||||||
call z, WaitForTextScrollButtonPress ; and here.
|
|
||||||
call EnableAutoTextBoxDrawing ; and here. GivePokemon is very hasty.
|
|
||||||
lb bc, PERSIAN, 16 ; because we're elitists, let's see if they chose cats first.
|
lb bc, PERSIAN, 16 ; because we're elitists, let's see if they chose cats first.
|
||||||
ld a, [wBeautyChoice] ; *sigh*, but if they're dog lovers, let's make sure they actually want Persian.
|
ld a, [wBeautyChoice] ; *sigh*, but if they're dog lovers, let's make sure they actually want Persian.
|
||||||
cp GROWLITHE ; Do they? If yes, skip.
|
cp GROWLITHE ; Do they? If yes, skip.
|
||||||
|
@ -622,7 +784,7 @@ CatsDogsChoice:
|
||||||
jr DisplayCatsDogsChoice
|
jr DisplayCatsDogsChoice
|
||||||
|
|
||||||
InitCatsDogsTextBoxParameters:
|
InitCatsDogsTextBoxParameters:
|
||||||
ld a, $2 ; loads the value for the unused SOUTH/EAST choice, that was changed to say CATS/DOGS
|
ld a, $2 ; loads the value for the unused SOUTH/EAST choice, which was changed to say CATS/DOGS
|
||||||
ld [wTwoOptionMenuID], a
|
ld [wTwoOptionMenuID], a
|
||||||
hlcoord 12, 8
|
hlcoord 12, 8
|
||||||
lb bc, 10, 13
|
lb bc, 10, 13
|
||||||
|
|
|
@ -163,12 +163,11 @@ _VermillionCityCitrinePass::
|
||||||
text "<PLAYER> flashed"
|
text "<PLAYER> flashed"
|
||||||
line "the CITRINE PASS!"
|
line "the CITRINE PASS!"
|
||||||
|
|
||||||
para "Ah! You must be"
|
para "Crikey!"
|
||||||
line "pretty strong to"
|
|
||||||
cont "have this PASS!"
|
|
||||||
|
|
||||||
para "Come on, come"
|
para "Right this way!"
|
||||||
line "on!"
|
line "I can't believe"
|
||||||
|
cont "it..."
|
||||||
done
|
done
|
||||||
|
|
||||||
_VermillionCityHarborRefuse::
|
_VermillionCityHarborRefuse::
|
||||||
|
|
Loading…
Reference in a new issue