aboutsummaryrefslogtreecommitdiffstats
path: root/engine/events/hidden_objects
diff options
context:
space:
mode:
authorRangi <35663410+Rangi42@users.noreply.github.com>2020-07-07 19:48:22 -0400
committerGitHub <noreply@github.com>2020-07-07 19:48:22 -0400
commit9571c550b6a0dcb3a4f54513c881661a87271024 (patch)
treed73507228a57e4f3cece2fb93fe7df3a9439553f /engine/events/hidden_objects
parentMerge pull request #262 from Rangi42/master (diff)
parentMove all code out of home.asm into home/ (diff)
downloadpokeyellow-9571c550b6a0dcb3a4f54513c881661a87271024.tar.gz
pokeyellow-9571c550b6a0dcb3a4f54513c881661a87271024.tar.xz
pokeyellow-9571c550b6a0dcb3a4f54513c881661a87271024.zip
Merge pull request #263 from Rangi42/master
Syncing style with pokecrystal
Diffstat (limited to 'engine/events/hidden_objects')
-rw-r--r--engine/events/hidden_objects/bills_house_pc.asm4
-rw-r--r--engine/events/hidden_objects/book_or_sculpture.asm2
-rw-r--r--engine/events/hidden_objects/bookshelves.asm8
-rw-r--r--engine/events/hidden_objects/cinnabar_gym_quiz.asm28
-rw-r--r--engine/events/hidden_objects/gym_statues.asm2
-rw-r--r--engine/events/hidden_objects/museum_fossils.asm12
-rw-r--r--engine/events/hidden_objects/safari_game.asm4
-rw-r--r--engine/events/hidden_objects/school_blackboard.asm10
-rw-r--r--engine/events/hidden_objects/town_map.asm8
-rw-r--r--engine/events/hidden_objects/vermilion_gym_trash.asm4
10 files changed, 41 insertions, 41 deletions
diff --git a/engine/events/hidden_objects/bills_house_pc.asm b/engine/events/hidden_objects/bills_house_pc.asm
index 92679d66..a73596b4 100644
--- a/engine/events/hidden_objects/bills_house_pc.asm
+++ b/engine/events/hidden_objects/bills_house_pc.asm
@@ -84,11 +84,11 @@ BillsHousePokemonList::
.billsPokemonLoop
ld hl, wd730
set 6, [hl]
- coord hl, 0, 0
+ hlcoord 0, 0
ld b, 10
ld c, 9
call TextBoxBorder
- coord hl, 2, 2
+ hlcoord 2, 2
ld de, BillsMonListText
call PlaceString
ld hl, BillsHousePokemonListText2
diff --git a/engine/events/hidden_objects/book_or_sculpture.asm b/engine/events/hidden_objects/book_or_sculpture.asm
index 2f3334b8..e04f4047 100644
--- a/engine/events/hidden_objects/book_or_sculpture.asm
+++ b/engine/events/hidden_objects/book_or_sculpture.asm
@@ -4,7 +4,7 @@ BookOrSculptureText::
ld a, [wCurMapTileset]
cp MANSION ; Celadon Mansion tileset
jr nz, .ok
- aCoord 8, 6
+ lda_coord 8, 6
cp $38
jr nz, .ok
ld hl, DiglettSculptureText
diff --git a/engine/events/hidden_objects/bookshelves.asm b/engine/events/hidden_objects/bookshelves.asm
index 9cdd037a..b58444af 100644
--- a/engine/events/hidden_objects/bookshelves.asm
+++ b/engine/events/hidden_objects/bookshelves.asm
@@ -6,7 +6,7 @@ PrintBookshelfText::
; facing up
ld a, [wCurMapTileset]
ld b, a
- aCoord 8, 7
+ lda_coord 8, 7
ld c, a
ld hl, BookshelfTileIDs
.loop
@@ -24,7 +24,7 @@ PrintBookshelfText::
pop af
call PrintPredefTextID
xor a
- ld [hFFDB], a
+ ldh [hFFDB], a
ret
.nextBookshelfEntry1
inc hl
@@ -33,7 +33,7 @@ PrintBookshelfText::
jr .loop
.noMatch
ld a, $ff
- ld [hFFDB], a
- jpba PrintCardKeyText
+ ldh [hFFDB], a
+ farjp PrintCardKeyText
INCLUDE "data/tilesets/bookshelf_tile_ids.asm"
diff --git a/engine/events/hidden_objects/cinnabar_gym_quiz.asm b/engine/events/hidden_objects/cinnabar_gym_quiz.asm
index da309f87..2e4f48f3 100644
--- a/engine/events/hidden_objects/cinnabar_gym_quiz.asm
+++ b/engine/events/hidden_objects/cinnabar_gym_quiz.asm
@@ -12,14 +12,14 @@ CinnabarGymQuiz::
ld a, [wHiddenObjectFunctionArgument]
push af
and $f
- ld [hGymGateIndex], a
+ ldh [hGymGateIndex], a
pop af
and $f0
swap a
- ld [hGymGateAnswer], a
+ ldh [hGymGateAnswer], a
ld hl, CinnabarGymQuizIntroText
call PrintText
- ld a, [hGymGateIndex]
+ ldh a, [hGymGateIndex]
dec a
add a
ld d, 0
@@ -77,18 +77,18 @@ CinnabarGymGateFlagAction:
CinnabarGymQuiz_1ea92:
call YesNoChoice
- ld a, [hGymGateAnswer]
+ ldh a, [hGymGateAnswer]
ld c, a
ld a, [wCurrentMenuItem]
cp c
jr nz, .wrongAnswer
ld hl, wCurrentMapScriptFlags
set 5, [hl]
- ld a, [hGymGateIndex]
- ld [hBackupGymGateIndex], a
+ ldh a, [hGymGateIndex]
+ ldh [hBackupGymGateIndex], a
ld hl, CinnabarGymQuizCorrectText
call PrintText
- ld a, [hBackupGymGateIndex]
+ ldh a, [hBackupGymGateIndex]
AdjustEventBit EVENT_CINNABAR_GYM_GATE0_UNLOCKED, 0
ld c, a
ld b, FLAG_SET
@@ -101,7 +101,7 @@ CinnabarGymQuiz_1ea92:
call WaitForSoundToFinish
ld hl, CinnabarGymQuizIncorrectText
call PrintText
- ld a, [hGymGateIndex]
+ ldh a, [hGymGateIndex]
add $2
AdjustEventBit EVENT_BEAT_CINNABAR_GYM_TRAINER_0, 2
ld c, a
@@ -111,7 +111,7 @@ CinnabarGymQuiz_1ea92:
ld a, c
and a
ret nz
- ld a, [hGymGateIndex]
+ ldh a, [hGymGateIndex]
add $2
ld [wOpponentAfterWrongAnswer], a
ret
@@ -122,7 +122,7 @@ CinnabarGymQuizCorrectText:
text_promptbutton
text_asm
- ld a, [hBackupGymGateIndex]
+ ldh a, [hBackupGymGateIndex]
AdjustEventBit EVENT_CINNABAR_GYM_GATE0_UNLOCKED, 0
ld c, a
ld b, FLAG_TEST
@@ -144,9 +144,9 @@ UpdateCinnabarGymGateTileBlocks_::
; Update the overworld map with open floor blocks or locked gate blocks
; depending on event flags.
ld a, 6
- ld [hGymGateIndex], a
+ ldh [hGymGateIndex], a
.loop
- ld a, [hGymGateIndex]
+ ldh a, [hGymGateIndex]
dec a
add a
add a
@@ -161,8 +161,8 @@ UpdateCinnabarGymGateTileBlocks_::
ld a, [hl]
ld [wGymGateTileBlock], a
push bc
- ld a, [hGymGateIndex]
- ld [hBackupGymGateIndex], a
+ ldh a, [hGymGateIndex]
+ ldh [hBackupGymGateIndex], a
AdjustEventBit EVENT_CINNABAR_GYM_GATE0_UNLOCKED, 0
ld c, a
ld b, FLAG_TEST
diff --git a/engine/events/hidden_objects/gym_statues.asm b/engine/events/hidden_objects/gym_statues.asm
index 1f592f2f..97b01a3a 100644
--- a/engine/events/hidden_objects/gym_statues.asm
+++ b/engine/events/hidden_objects/gym_statues.asm
@@ -1,6 +1,6 @@
GymStatues:
; if in a gym and have the corresponding badge, a = GymStatueText2_id and jp PrintPredefTextID
-; if in a gym and don’t have the corresponding badge, a = GymStatueText1_id and jp PrintPredefTextID
+; if in a gym and don't have the corresponding badge, a = GymStatueText1_id and jp PrintPredefTextID
; else ret
call EnableAutoTextBoxDrawing
ld a, [wSpritePlayerStateData1FacingDirection]
diff --git a/engine/events/hidden_objects/museum_fossils.asm b/engine/events/hidden_objects/museum_fossils.asm
index 36fb2556..27714981 100644
--- a/engine/events/hidden_objects/museum_fossils.asm
+++ b/engine/events/hidden_objects/museum_fossils.asm
@@ -26,10 +26,10 @@ DisplayMonFrontSpriteInBox:
; Displays a pokemon's front sprite in a pop-up window.
; [wcf91] = pokemon internal id number
ld a, 1
- ld [hAutoBGTransferEnabled], a
+ ldh [hAutoBGTransferEnabled], a
call Delay3
xor a
- ld [hWY], a
+ ldh [hWY], a
call SaveScreenTilesToBuffer1
ld a, MON_SPRITE_POPUP
ld [wTextBoxID], a
@@ -38,15 +38,15 @@ DisplayMonFrontSpriteInBox:
ld a, [wcf91]
ld [wd0b5], a
call GetMonHeader
- ld de, vChars1 + $310
+ ld de, vChars1 tile $31
call LoadMonFrontSprite
ld a, $80
- ld [hStartTileID], a
- coord hl, 10, 11
+ ldh [hStartTileID], a
+ hlcoord 10, 11
predef AnimateSendingOutMon
call WaitForTextScrollButtonPress
call LoadScreenTilesFromBuffer1
call Delay3
ld a, $90
- ld [hWY], a
+ ldh [hWY], a
ret
diff --git a/engine/events/hidden_objects/safari_game.asm b/engine/events/hidden_objects/safari_game.asm
index 656e872a..5996fc6f 100644
--- a/engine/events/hidden_objects/safari_game.asm
+++ b/engine/events/hidden_objects/safari_game.asm
@@ -37,12 +37,12 @@ SafariZoneGameOver:
cp SFX_SAFARI_ZONE_PA
jr nz, .waitForMusicToPlay
ld a, TEXT_SAFARI_GAME_OVER
- ld [hSpriteIndexOrTextID], a
+ ldh [hSpriteIndexOrTextID], a
call DisplayTextID
xor a
ld [wPlayerMovingDirection], a
ld a, SAFARI_ZONE_GATE
- ld [hWarpDestinationMap], a
+ ldh [hWarpDestinationMap], a
ld a, $3
ld [wDestinationWarpID], a
ld a, $5
diff --git a/engine/events/hidden_objects/school_blackboard.asm b/engine/events/hidden_objects/school_blackboard.asm
index 48b97d73..de4700d4 100644
--- a/engine/events/hidden_objects/school_blackboard.asm
+++ b/engine/events/hidden_objects/school_blackboard.asm
@@ -26,11 +26,11 @@ LinkCableHelp::
.linkHelpLoop
ld hl, wd730
set 6, [hl]
- coord hl, 0, 0
+ hlcoord 0, 0
ld b, 8
ld c, 13
call TextBoxBorder
- coord hl, 2, 2
+ hlcoord 2, 2
ld de, HowToLinkText
call PlaceString
ld hl, LinkCableHelpText2
@@ -110,13 +110,13 @@ ViridianSchoolBlackboard::
.blackboardLoop
ld hl, wd730
set 6, [hl]
- coord hl, 0, 0
+ hlcoord 0, 0
lb bc, 6, 10
call TextBoxBorder
- coord hl, 1, 2
+ hlcoord 1, 2
ld de, StatusAilmentText1
call PlaceString
- coord hl, 6, 2
+ hlcoord 6, 2
ld de, StatusAilmentText2
call PlaceString
ld hl, ViridianSchoolBlackboardText2
diff --git a/engine/events/hidden_objects/town_map.asm b/engine/events/hidden_objects/town_map.asm
index 9481b902..4284214f 100644
--- a/engine/events/hidden_objects/town_map.asm
+++ b/engine/events/hidden_objects/town_map.asm
@@ -8,15 +8,15 @@ TownMapText::
set 6, [hl]
call GBPalWhiteOutWithDelay3
xor a
- ld [hWY], a
+ ldh [hWY], a
inc a
- ld [hAutoBGTransferEnabled], a
+ ldh [hAutoBGTransferEnabled], a
call LoadFontTilePatterns
- callba DisplayTownMap
+ farcall DisplayTownMap
ld hl, wd730
res 6, [hl]
ld de, TextScriptEnd
push de
- ld a, [hLoadedROMBank]
+ ldh a, [hLoadedROMBank]
push af
jp CloseTextDisplay
diff --git a/engine/events/hidden_objects/vermilion_gym_trash.asm b/engine/events/hidden_objects/vermilion_gym_trash.asm
index f46b53c2..c2bfed06 100644
--- a/engine/events/hidden_objects/vermilion_gym_trash.asm
+++ b/engine/events/hidden_objects/vermilion_gym_trash.asm
@@ -56,12 +56,12 @@ GymTrashScript:
; first lock was in trash can 1 or 3. However, due to this bug, trash can 0 can
; have the second lock regardless of which trash can had the first lock.
- ld [hGymTrashCanRandNumMask], a
+ ldh [hGymTrashCanRandNumMask], a
push hl
call Random
swap a
ld b, a
- ld a, [hGymTrashCanRandNumMask]
+ ldh a, [hGymTrashCanRandNumMask]
and b
dec a
pop hl