summaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
Diffstat (limited to 'engine')
-rw-r--r--engine/events.asm24
-rw-r--r--engine/events/checkforhiddenitems.asm10
-rwxr-xr-xengine/events/mom_phone.asm2
-rw-r--r--engine/events/unown_walls.asm18
-rw-r--r--engine/events_2.asm2
-rwxr-xr-xengine/intro_menu.asm4
-rw-r--r--engine/phone/phone.asm4
-rw-r--r--engine/player_gfx.asm4
-rwxr-xr-xengine/pokegear.asm4
-rw-r--r--engine/save.asm24
-rw-r--r--engine/scripting.asm6
-rwxr-xr-xengine/unown_puzzle.asm4
-rwxr-xr-xengine/warp_connection.asm2
13 files changed, 54 insertions, 54 deletions
diff --git a/engine/events.asm b/engine/events.asm
index f95e9ab12..96108730a 100644
--- a/engine/events.asm
+++ b/engine/events.asm
@@ -396,7 +396,7 @@ CheckTileEvent: ; 96874
ld a, [hli]
ld h, [hl]
ld l, a
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call CallScript
ret
; 968c7
@@ -450,7 +450,7 @@ RunSceneScript: ; 968ec
ld e, a
ld d, 0
- ld hl, wCurrMapSceneScriptHeaderPointer
+ ld hl, wCurrMapSceneScriptsPointer
ld a, [hli]
ld h, [hl]
ld l, a
@@ -458,9 +458,9 @@ rept 4
add hl, de
endr
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call GetFarHalfword
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call CallScript
ld hl, ScriptFlags
@@ -635,7 +635,7 @@ TryObjectEvent: ; 969b5
ld a, [hli]
ld h, [hl]
ld l, a
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call CallScript
ret
; 96a12
@@ -646,7 +646,7 @@ TryObjectEvent: ; 969b5
ld a, [hli]
ld h, [hl]
ld l, a
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
ld de, EngineBuffer1
ld bc, 2
call FarCopyBytes
@@ -731,7 +731,7 @@ TryBGEvent: ; 96a38
ld a, [hli]
ld h, [hl]
ld l, a
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call CallScript
scf
ret
@@ -740,7 +740,7 @@ TryBGEvent: ; 96a38
call CheckBGEventFlag
jp nz, .dontread
call PlayTalkObject
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
ld de, EngineBuffer1
ld bc, 3
call FarCopyBytes
@@ -753,7 +753,7 @@ TryBGEvent: ; 96a38
.copy
call CheckBGEventFlag
jr nz, .dontread
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
ld de, EngineBuffer1
ld bc, 3
call FarCopyBytes
@@ -774,9 +774,9 @@ TryBGEvent: ; 96a38
pop hl
inc hl
inc hl
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call GetFarHalfword
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call CallScript
scf
ret
@@ -792,7 +792,7 @@ CheckBGEventFlag: ; 96ad8
ld h, [hl]
ld l, a
push hl
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
call GetFarHalfword
ld e, l
ld d, h
diff --git a/engine/events/checkforhiddenitems.asm b/engine/events/checkforhiddenitems.asm
index 3c13412d8..3cad2b821 100644
--- a/engine/events/checkforhiddenitems.asm
+++ b/engine/events/checkforhiddenitems.asm
@@ -1,6 +1,6 @@
CheckForHiddenItems: ; b8172
; Checks to see if there are hidden items on the screen that have not yet been found. If it finds one, returns carry.
- call GetMapScriptHeaderBank
+ call GetMapScriptsBank
ld [Buffer1], a
; Get the coordinate of the bottom right corner of the screen, and load it in Buffer3/Buffer4.
ld a, [XCoord]
@@ -9,8 +9,8 @@ CheckForHiddenItems: ; b8172
ld a, [YCoord]
add SCREEN_HEIGHT / 4
ld [Buffer3], a
-; Get the pointer for the first BG event header in the map...
- ld hl, wCurrMapBGEventHeaderPointer
+; Get the pointer for the first bg_event in the map...
+ ld hl, wCurrMapBGEventsPointer
ld a, [hli]
ld h, [hl]
ld l, a
@@ -20,7 +20,7 @@ CheckForHiddenItems: ; b8172
jr z, .nobgeventitems
; For i = 1:wCurrMapBGEventCount...
.loop
-; Store the counter in Buffer2, and store the BG event header pointer in the stack.
+; Store the counter in Buffer2, and store the bg_event pointer in the stack.
ld [Buffer2], a
push hl
; Get the Y coordinate of the BG event.
@@ -58,7 +58,7 @@ CheckForHiddenItems: ; b8172
jr z, .itemnearby
.next
-; Restore the BG event header pointer and increment it by the length of a BG event header.
+; Restore the bg_event pointer and increment it by the length of a bg_event.
pop hl
ld bc, 5
add hl, bc
diff --git a/engine/events/mom_phone.asm b/engine/events/mom_phone.asm
index 50496e663..d12bf0155 100755
--- a/engine/events/mom_phone.asm
+++ b/engine/events/mom_phone.asm
@@ -9,7 +9,7 @@ MomTriesToBuySomething:: ; fcfec
ld a, [wMapReentryScriptQueueFlag]
and a
ret nz
- call GetMapHeaderPhoneServiceNybble
+ call GetMapPhoneService
and a
ret nz
xor a
diff --git a/engine/events/unown_walls.asm b/engine/events/unown_walls.asm
index af7e80bf0..4d59a2f7a 100644
--- a/engine/events/unown_walls.asm
+++ b/engine/events/unown_walls.asm
@@ -3,7 +3,7 @@ Special_HoOhChamber: ; 0x8addb
ld a, [hl]
cp HO_OH ; is Ho-oh the first Pokémon in the party?
jr nz, .done ; if not, we're done
- call GetSecondaryMapHeaderPointer
+ call GetMapDataPointer ; pointless?
ld de, EVENT_WALL_OPENED_IN_HO_OH_CHAMBER
ld b, SET_FLAG
call EventFlagAction
@@ -12,7 +12,7 @@ Special_HoOhChamber: ; 0x8addb
; 0x8adef
Special_OmanyteChamber: ; 8adef
- call GetSecondaryMapHeaderPointer
+ call GetMapDataPointer ; pointless?
ld de, EVENT_WALL_OPENED_IN_OMANYTE_CHAMBER
ld b, CHECK_FLAG
call EventFlagAction
@@ -44,7 +44,7 @@ Special_OmanyteChamber: ; 8adef
jr nz, .loop
.open
- call GetSecondaryMapHeaderPointer
+ call GetMapDataPointer ; pointless?
ld de, EVENT_WALL_OPENED_IN_OMANYTE_CHAMBER
ld b, SET_FLAG
call EventFlagAction
@@ -57,12 +57,12 @@ SpecialAerodactylChamber: ; 8ae30
push de
push bc
- call GetSecondaryMapHeaderPointer
+ call GetMapDataPointer
ld a, h
- cp HIGH(RuinsOfAlphAerodactylChamber_SecondMapHeader)
+ cp HIGH(RuinsOfAlphAerodactylChamber_MapData)
jr nz, .nope
ld a, l
- cp LOW(RuinsOfAlphAerodactylChamber_SecondMapHeader)
+ cp LOW(RuinsOfAlphAerodactylChamber_MapData)
jr nz, .nope
ld de, EVENT_WALL_OPENED_IN_AERODACTYL_CHAMBER
@@ -85,12 +85,12 @@ SpecialKabutoChamber: ; 8ae4e
push hl
push de
- call GetSecondaryMapHeaderPointer
+ call GetMapDataPointer
ld a, h
- cp HIGH(RuinsOfAlphKabutoChamber_SecondMapHeader)
+ cp HIGH(RuinsOfAlphKabutoChamber_MapData)
jr nz, .done
ld a, l
- cp LOW(RuinsOfAlphKabutoChamber_SecondMapHeader)
+ cp LOW(RuinsOfAlphKabutoChamber_MapData)
jr nz, .done
ld de, EVENT_WALL_OPENED_IN_KABUTO_CHAMBER
diff --git a/engine/events_2.asm b/engine/events_2.asm
index e4458d9aa..1149c2431 100644
--- a/engine/events_2.asm
+++ b/engine/events_2.asm
@@ -274,7 +274,7 @@ DoBikeStep:: ; 97db3
; If we're not in an area of phone service, we don't
; have to be here.
- call GetMapHeaderPhoneServiceNybble
+ call GetMapPhoneService
and a
jr nz, .NoCall
diff --git a/engine/intro_menu.asm b/engine/intro_menu.asm
index 57d6eb6ce..15c2a4cbb 100755
--- a/engine/intro_menu.asm
+++ b/engine/intro_menu.asm
@@ -542,10 +542,10 @@ Continue_LoadMenuHeader: ; 5ebf
ld hl, .MenuDataHeader_Dex
ld a, [wStatusFlags]
bit 0, a ; pokedex
- jr nz, .pokedex_header
+ jr nz, .show_menu
ld hl, .MenuDataHeader_NoDex
-.pokedex_header
+.show_menu
call _OffsetMenuDataHeader
call MenuBox
call PlaceVerticalMenuItems
diff --git a/engine/phone/phone.asm b/engine/phone/phone.asm
index a4dd42faf..6a9644872 100644
--- a/engine/phone/phone.asm
+++ b/engine/phone/phone.asm
@@ -131,7 +131,7 @@ CheckPhoneCall:: ; 90074 (24:4074)
cp b
jr nz, .no_call
- call GetMapHeaderPhoneServiceNybble
+ call GetMapPhoneService
and a
jr nz, .no_call
@@ -328,7 +328,7 @@ Function90199: ; 90199 (24:4199)
and a
jr nz, .OutOfArea
; If you're in an area without phone service, don't do the call
- call GetMapHeaderPhoneServiceNybble
+ call GetMapPhoneService
and a
jr nz, .OutOfArea
; If the person can't take a call at that time, don't do the call
diff --git a/engine/player_gfx.asm b/engine/player_gfx.asm
index ac63b050f..21929e32c 100644
--- a/engine/player_gfx.asm
+++ b/engine/player_gfx.asm
@@ -56,11 +56,11 @@ MovePlayerPic: ; 88266
jr .loop
ShowPlayerNamingChoices: ; 88297
- ld hl, ChrisNameMenuHeader
+ ld hl, ChrisNameMenuDataHeader
ld a, [wPlayerGender]
bit 0, a
jr z, .GotGender
- ld hl, KrisNameMenuHeader
+ ld hl, KrisNameMenuDataHeader
.GotGender:
call LoadMenuDataHeader
call VerticalMenu
diff --git a/engine/pokegear.asm b/engine/pokegear.asm
index 37640311e..5bb63b897 100755
--- a/engine/pokegear.asm
+++ b/engine/pokegear.asm
@@ -393,7 +393,7 @@ InitPokegearTilemap: ; 90da8 (24:4da8)
hlcoord 17, 2
inc a
ld [hli], a
- call GetMapHeaderPhoneServiceNybble
+ call GetMapPhoneService
and a
ret nz
hlcoord 18, 2
@@ -926,7 +926,7 @@ PokegearPhone_Joypad: ; 91171 (24:5171)
ret
PokegearPhone_MakePhoneCall: ; 911eb (24:51eb)
- call GetMapHeaderPhoneServiceNybble
+ call GetMapPhoneService
and a
jr nz, .no_service
ld hl, Options
diff --git a/engine/save.asm b/engine/save.asm
index d9f48d62c..8c2ac7413 100644
--- a/engine/save.asm
+++ b/engine/save.asm
@@ -525,9 +525,9 @@ SavePlayerData: ; 14dd7
ld de, sPlayerData
ld bc, wPlayerDataEnd - wPlayerData
call CopyBytes
- ld hl, wMapData
- ld de, sMapData
- ld bc, wMapDataEnd - wMapData
+ ld hl, wCurrMapData
+ ld de, sCurrMapData
+ ld bc, wCurrMapDataEnd - wCurrMapData
call CopyBytes
jp CloseSRAM
; 14df7
@@ -592,9 +592,9 @@ SaveBackupPlayerData: ; 14e55
ld de, sBackupPlayerData
ld bc, wPlayerDataEnd - wPlayerData
call CopyBytes
- ld hl, wMapData
- ld de, sBackupMapData
- ld bc, wMapDataEnd - wMapData
+ ld hl, wCurrMapData
+ ld de, sBackupCurrMapData
+ ld bc, wCurrMapDataEnd - wCurrMapData
call CopyBytes
call CloseSRAM
ret
@@ -777,9 +777,9 @@ LoadPlayerData: ; 14fd7 (5:4fd7)
ld de, wPlayerData
ld bc, wPlayerDataEnd - wPlayerData
call CopyBytes
- ld hl, sMapData
- ld de, wMapData
- ld bc, wMapDataEnd - wMapData
+ ld hl, sCurrMapData
+ ld de, wCurrMapData
+ ld bc, wCurrMapDataEnd - wCurrMapData
call CopyBytes
call CloseSRAM
ld a, BANK(sBattleTowerChallengeState)
@@ -833,9 +833,9 @@ LoadBackupPlayerData: ; 15046 (5:5046)
ld de, wPlayerData
ld bc, wPlayerDataEnd - wPlayerData
call CopyBytes
- ld hl, sBackupMapData
- ld de, wMapData
- ld bc, wMapDataEnd - wMapData
+ ld hl, sBackupCurrMapData
+ ld de, wCurrMapData
+ ld bc, wCurrMapDataEnd - wCurrMapData
call CopyBytes
call CloseSRAM
ret
diff --git a/engine/scripting.asm b/engine/scripting.asm
index 87415135d..769a8311c 100644
--- a/engine/scripting.asm
+++ b/engine/scripting.asm
@@ -2580,11 +2580,11 @@ Script_changemap:
; parameters: map_data_pointer
call GetScriptByte
- ld [MapBlockDataBank], a
+ ld [MapBlocksBank], a
call GetScriptByte
- ld [MapBlockDataPointer], a
+ ld [MapBlocksPointer], a
call GetScriptByte
- ld [MapBlockDataPointer + 1], a
+ ld [MapBlocksPointer + 1], a
call ChangeMap
call BufferScreen
ret
diff --git a/engine/unown_puzzle.asm b/engine/unown_puzzle.asm
index 8a032db42..36f6dacd2 100755
--- a/engine/unown_puzzle.asm
+++ b/engine/unown_puzzle.asm
@@ -763,7 +763,7 @@ endr
; e16c7
UnownPuzzle_AddPuzzlePieceBorders: ; e16c7
- ld hl, GFXHeaders
+ ld hl, PuzzlePieceBorderData
ld a, 8
.loop
push af
@@ -819,7 +819,7 @@ endr
ret
; e1703
-GFXHeaders: ; e1703
+PuzzlePieceBorderData: ; e1703
dw .TileBordersGFX + 0 tiles, vTiles0 tile $00
dw .TileBordersGFX + 1 tiles, vTiles0 tile $01
dw .TileBordersGFX + 2 tiles, vTiles0 tile $02
diff --git a/engine/warp_connection.asm b/engine/warp_connection.asm
index 28908e793..c2cb6ed10 100755
--- a/engine/warp_connection.asm
+++ b/engine/warp_connection.asm
@@ -11,7 +11,7 @@ InitCommandQueue: ; 1045c4
farcall ClearCmdQueue
ld a, MAPCALLBACK_CMDQUEUE
call RunMapCallback
- call GetMapHeaderTimeOfDayNybble
+ call GetMapTimeOfDay
ld [wMapTimeOfDay], a
ret