aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/AgathasRoom.asm4
-rw-r--r--scripts/BrunosRoom.asm4
-rw-r--r--scripts/CeladonGym.asm4
-rw-r--r--scripts/CeladonMartElevator.asm8
-rw-r--r--scripts/CeruleanGym.asm4
-rw-r--r--scripts/CinnabarGym.asm10
-rw-r--r--scripts/CinnabarIsland.asm2
-rw-r--r--scripts/FuchsiaGym.asm4
-rw-r--r--scripts/GameCorner.asm12
-rw-r--r--scripts/IndigoPlateauLobby.asm4
-rw-r--r--scripts/LancesRoom.asm6
-rw-r--r--scripts/LoreleisRoom.asm4
-rw-r--r--scripts/PewterGym.asm4
-rw-r--r--scripts/PokemonMansion1F.asm6
-rw-r--r--scripts/PokemonMansion2F.asm6
-rw-r--r--scripts/PokemonMansion3F.asm4
-rw-r--r--scripts/PokemonMansionB1F.asm4
-rw-r--r--scripts/RocketHideoutB1F.asm4
-rw-r--r--scripts/RocketHideoutB4F.asm6
-rw-r--r--scripts/RocketHideoutElevator.asm8
-rw-r--r--scripts/Route23.asm4
-rw-r--r--scripts/Route25.asm4
-rw-r--r--scripts/SaffronGym.asm4
-rw-r--r--scripts/SilphCo10F.asm4
-rw-r--r--scripts/SilphCo11F.asm4
-rw-r--r--scripts/SilphCo2F.asm4
-rw-r--r--scripts/SilphCo3F.asm4
-rw-r--r--scripts/SilphCo4F.asm4
-rw-r--r--scripts/SilphCo5F.asm4
-rw-r--r--scripts/SilphCo6F.asm4
-rw-r--r--scripts/SilphCo7F.asm4
-rw-r--r--scripts/SilphCo8F.asm4
-rw-r--r--scripts/SilphCo9F.asm4
-rw-r--r--scripts/SilphCoElevator.asm8
-rw-r--r--scripts/VermilionCity.asm8
-rw-r--r--scripts/VermilionGym.asm8
-rw-r--r--scripts/VictoryRoad1F.asm6
-rw-r--r--scripts/VictoryRoad2F.asm10
-rw-r--r--scripts/VictoryRoad3F.asm6
39 files changed, 103 insertions, 103 deletions
diff --git a/scripts/AgathasRoom.asm b/scripts/AgathasRoom.asm
index 0f3acc18..2d0dca08 100644
--- a/scripts/AgathasRoom.asm
+++ b/scripts/AgathasRoom.asm
@@ -11,8 +11,8 @@ AgathasRoom_Script:
AgathaShowOrHideExitBlock:
; Blocks or clears the exit to the next room.
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_BEAT_AGATHAS_ROOM_TRAINER_0
jr z, .blockExitToNextRoom
diff --git a/scripts/BrunosRoom.asm b/scripts/BrunosRoom.asm
index 94ec7d17..6d7fde6e 100644
--- a/scripts/BrunosRoom.asm
+++ b/scripts/BrunosRoom.asm
@@ -11,8 +11,8 @@ BrunosRoom_Script:
BrunoShowOrHideExitBlock:
; Blocks or clears the exit to the next room.
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_BEAT_BRUNOS_ROOM_TRAINER_0
jr z, .blockExitToNextRoom
diff --git a/scripts/CeladonGym.asm b/scripts/CeladonGym.asm
index ca7da4e5..f95d129a 100644
--- a/scripts/CeladonGym.asm
+++ b/scripts/CeladonGym.asm
@@ -1,7 +1,7 @@
CeladonGym_Script:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
call nz, .LoadNames
call EnableAutoTextBoxDrawing
ld hl, CeladonGymTrainerHeaders
diff --git a/scripts/CeladonMartElevator.asm b/scripts/CeladonMartElevator.asm
index 9a2842f3..69686fa8 100644
--- a/scripts/CeladonMartElevator.asm
+++ b/scripts/CeladonMartElevator.asm
@@ -1,12 +1,12 @@
CeladonMartElevator_Script:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
push hl
call nz, CeladonMartElevatorStoreWarpEntriesScript
pop hl
- bit 7, [hl]
- res 7, [hl]
+ bit BIT_CUR_MAP_USED_ELEVATOR, [hl]
+ res BIT_CUR_MAP_USED_ELEVATOR, [hl]
call nz, CeladonMartElevatorShakeScript
xor a
ld [wAutoTextBoxDrawingControl], a
diff --git a/scripts/CeruleanGym.asm b/scripts/CeruleanGym.asm
index 37d5e405..e924907a 100644
--- a/scripts/CeruleanGym.asm
+++ b/scripts/CeruleanGym.asm
@@ -1,7 +1,7 @@
CeruleanGym_Script:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
call nz, .LoadNames
call EnableAutoTextBoxDrawing
ld hl, CeruleanGymTrainerHeaders
diff --git a/scripts/CinnabarGym.asm b/scripts/CinnabarGym.asm
index b7c9e1ba..efda64a5 100644
--- a/scripts/CinnabarGym.asm
+++ b/scripts/CinnabarGym.asm
@@ -7,13 +7,13 @@ CinnabarGym_Script:
CinnabarGymSetMapAndTiles:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
push hl
call nz, .LoadNames
pop hl
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
call nz, UpdateCinnabarGymGateTileBlocks
ResetEvent EVENT_2A7
ret
@@ -170,7 +170,7 @@ CinnabarGymReceiveTM38:
SetEventRange EVENT_BEAT_CINNABAR_GYM_TRAINER_0, EVENT_BEAT_CINNABAR_GYM_TRAINER_6
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
jp CinnabarGymResetScripts
diff --git a/scripts/CinnabarIsland.asm b/scripts/CinnabarIsland.asm
index ed38f690..f2a36afb 100644
--- a/scripts/CinnabarIsland.asm
+++ b/scripts/CinnabarIsland.asm
@@ -1,7 +1,7 @@
CinnabarIsland_Script:
call EnableAutoTextBoxDrawing
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
ResetEvent EVENT_MANSION_SWITCH_ON
ResetEvent EVENT_LAB_STILL_REVIVING_FOSSIL
ld hl, CinnabarIsland_ScriptPointers
diff --git a/scripts/FuchsiaGym.asm b/scripts/FuchsiaGym.asm
index 8ccebe40..c983c896 100644
--- a/scripts/FuchsiaGym.asm
+++ b/scripts/FuchsiaGym.asm
@@ -10,8 +10,8 @@ FuchsiaGym_Script:
.LoadNames:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
ret z
ld hl, .CityName
ld de, .LeaderName
diff --git a/scripts/GameCorner.asm b/scripts/GameCorner.asm
index 5d5236c5..cac3170c 100644
--- a/scripts/GameCorner.asm
+++ b/scripts/GameCorner.asm
@@ -8,8 +8,8 @@ GameCorner_Script:
GameCornerSelectLuckySlotMachine:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
ret z
call Random
ldh a, [hRandomAdd]
@@ -25,8 +25,8 @@ GameCornerSelectLuckySlotMachine:
GameCornerSetRocketHideoutDoorTile:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_FOUND_ROCKET_HIDEOUT
ret nz
@@ -111,8 +111,8 @@ GameCornerRocketExitScript:
ld [wMissableObjectIndex], a
predef HideObject
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
- set 6, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
+ set BIT_CUR_MAP_LOADED_2, [hl]
ld a, SCRIPT_GAMECORNER_DEFAULT
ld [wGameCornerCurScript], a
ret
diff --git a/scripts/IndigoPlateauLobby.asm b/scripts/IndigoPlateauLobby.asm
index fd8ecf3c..8ac87030 100644
--- a/scripts/IndigoPlateauLobby.asm
+++ b/scripts/IndigoPlateauLobby.asm
@@ -2,8 +2,8 @@ IndigoPlateauLobby_Script:
call Serial_TryEstablishingExternallyClockedConnection
call EnableAutoTextBoxDrawing
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
ret z
ResetEvent EVENT_VICTORY_ROAD_1_BOULDER_ON_SWITCH
; Reset Elite Four events if the player started challenging them before
diff --git a/scripts/LancesRoom.asm b/scripts/LancesRoom.asm
index 31b0f240..235deac1 100644
--- a/scripts/LancesRoom.asm
+++ b/scripts/LancesRoom.asm
@@ -10,8 +10,8 @@ LancesRoom_Script:
LanceShowOrHideEntranceBlocks:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_LANCES_ROOM_LOCK_DOOR
jr nz, .closeEntrance
@@ -71,7 +71,7 @@ LancesRoomDefaultScript:
CheckAndSetEvent EVENT_LANCES_ROOM_LOCK_DOOR
ret nz
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
ld a, SFX_GO_INSIDE
call PlaySound
jp LanceShowOrHideEntranceBlocks
diff --git a/scripts/LoreleisRoom.asm b/scripts/LoreleisRoom.asm
index ec88f73e..455561b8 100644
--- a/scripts/LoreleisRoom.asm
+++ b/scripts/LoreleisRoom.asm
@@ -11,8 +11,8 @@ LoreleisRoom_Script:
LoreleiShowOrHideExitBlock:
; Blocks or clears the exit to the next room.
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, wElite4Flags
set BIT_STARTED_ELITE_4, [hl]
diff --git a/scripts/PewterGym.asm b/scripts/PewterGym.asm
index 0029be19..6c4c9443 100644
--- a/scripts/PewterGym.asm
+++ b/scripts/PewterGym.asm
@@ -1,7 +1,7 @@
PewterGym_Script:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
call nz, .LoadNames
call EnableAutoTextBoxDrawing
ld hl, PewterGymTrainerHeaders
diff --git a/scripts/PokemonMansion1F.asm b/scripts/PokemonMansion1F.asm
index a93bd33b..d06a234a 100644
--- a/scripts/PokemonMansion1F.asm
+++ b/scripts/PokemonMansion1F.asm
@@ -10,8 +10,8 @@ PokemonMansion1F_Script:
Mansion1CheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_MANSION_SWITCH_ON
jr nz, .switchTurnedOn
@@ -103,7 +103,7 @@ PokemonMansion1FSwitchText:
ld a, $1
ld [wDoNotWaitForButtonPressAfterDisplayingText], a
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
ld hl, .PressedText
call PrintText
ld a, SFX_GO_INSIDE
diff --git a/scripts/PokemonMansion2F.asm b/scripts/PokemonMansion2F.asm
index df424a19..7da9e50f 100644
--- a/scripts/PokemonMansion2F.asm
+++ b/scripts/PokemonMansion2F.asm
@@ -10,8 +10,8 @@ PokemonMansion2F_Script:
Mansion2CheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_MANSION_SWITCH_ON
jr nz, .switchTurnedOn
@@ -108,7 +108,7 @@ PokemonMansion2FSwitchText:
ld a, $1
ld [wDoNotWaitForButtonPressAfterDisplayingText], a
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
ld hl, .PressedText
call PrintText
ld a, SFX_GO_INSIDE
diff --git a/scripts/PokemonMansion3F.asm b/scripts/PokemonMansion3F.asm
index f5347446..de8bd1dd 100644
--- a/scripts/PokemonMansion3F.asm
+++ b/scripts/PokemonMansion3F.asm
@@ -10,8 +10,8 @@ PokemonMansion3F_Script:
Mansion3CheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_MANSION_SWITCH_ON
jr nz, .switchTurnedOn
diff --git a/scripts/PokemonMansionB1F.asm b/scripts/PokemonMansionB1F.asm
index e359621d..e31bbd3e 100644
--- a/scripts/PokemonMansionB1F.asm
+++ b/scripts/PokemonMansionB1F.asm
@@ -10,8 +10,8 @@ PokemonMansionB1F_Script:
MansionB1FCheckReplaceSwitchDoorBlocks:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_MANSION_SWITCH_ON
jr nz, .switchTurnedOn
diff --git a/scripts/RocketHideoutB1F.asm b/scripts/RocketHideoutB1F.asm
index f6c64bda..9354a0c7 100644
--- a/scripts/RocketHideoutB1F.asm
+++ b/scripts/RocketHideoutB1F.asm
@@ -10,8 +10,8 @@ RocketHideoutB1F_Script:
RocketHideoutB1FDoorCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_677
jr nz, .door_open
diff --git a/scripts/RocketHideoutB4F.asm b/scripts/RocketHideoutB4F.asm
index 920aa089..2c630067 100644
--- a/scripts/RocketHideoutB4F.asm
+++ b/scripts/RocketHideoutB4F.asm
@@ -10,8 +10,8 @@ RocketHideoutB4F_Script:
RocketHideoutB4FDoorCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEvent EVENT_ROCKET_HIDEOUT_4_DOOR_UNLOCKED
jr nz, .door_already_unlocked
@@ -67,7 +67,7 @@ RocketHideoutB4FBeatGiovanniScript:
xor a
ld [wJoyIgnore], a
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
ld a, SCRIPT_ROCKETHIDEOUTB4F_DEFAULT
ld [wRocketHideoutB4FCurScript], a
ld [wCurMapScript], a
diff --git a/scripts/RocketHideoutElevator.asm b/scripts/RocketHideoutElevator.asm
index 71ff0758..bd6fb498 100644
--- a/scripts/RocketHideoutElevator.asm
+++ b/scripts/RocketHideoutElevator.asm
@@ -1,12 +1,12 @@
RocketHideoutElevator_Script:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
push hl
call nz, RocketHideoutElevatorStoreWarpEntriesScript
pop hl
- bit 7, [hl]
- res 7, [hl]
+ bit BIT_CUR_MAP_USED_ELEVATOR, [hl]
+ res BIT_CUR_MAP_USED_ELEVATOR, [hl]
call nz, RocketHideoutElevatorShakeScript
xor a
ld [wAutoTextBoxDrawingControl], a
diff --git a/scripts/Route23.asm b/scripts/Route23.asm
index ffd968df..ac4853d8 100644
--- a/scripts/Route23.asm
+++ b/scripts/Route23.asm
@@ -7,8 +7,8 @@ Route23_Script:
Route23SetVictoryRoadBoulders:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
ret z
ResetEvents EVENT_VICTORY_ROAD_2_BOULDER_ON_SWITCH1, EVENT_VICTORY_ROAD_2_BOULDER_ON_SWITCH2
ResetEvents EVENT_VICTORY_ROAD_3_BOULDER_ON_SWITCH1, EVENT_VICTORY_ROAD_3_BOULDER_ON_SWITCH2
diff --git a/scripts/Route25.asm b/scripts/Route25.asm
index ef0e8fd2..a85144a8 100644
--- a/scripts/Route25.asm
+++ b/scripts/Route25.asm
@@ -10,8 +10,8 @@ Route25_Script:
Route25ShowHideBillScript:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
ret z
CheckEventHL EVENT_LEFT_BILLS_HOUSE_AFTER_HELPING
ret nz
diff --git a/scripts/SaffronGym.asm b/scripts/SaffronGym.asm
index 556cd4c5..4bfb7b2c 100644
--- a/scripts/SaffronGym.asm
+++ b/scripts/SaffronGym.asm
@@ -1,7 +1,7 @@
SaffronGym_Script:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
call nz, .LoadNames
call EnableAutoTextBoxDrawing
ld hl, SaffronGymTrainerHeaders
diff --git a/scripts/SilphCo10F.asm b/scripts/SilphCo10F.asm
index 7cc2c58e..d9650bc8 100644
--- a/scripts/SilphCo10F.asm
+++ b/scripts/SilphCo10F.asm
@@ -10,8 +10,8 @@ SilphCo10F_Script:
SilphCo10FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo2F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo11F.asm b/scripts/SilphCo11F.asm
index d5e4cb08..6953d37c 100644
--- a/scripts/SilphCo11F.asm
+++ b/scripts/SilphCo11F.asm
@@ -10,8 +10,8 @@ SilphCo11F_Script:
SilphCo11FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, SilphCo11GateCoords
call SilphCo11F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo2F.asm b/scripts/SilphCo2F.asm
index 52241b95..7ca57c45 100644
--- a/scripts/SilphCo2F.asm
+++ b/scripts/SilphCo2F.asm
@@ -10,8 +10,8 @@ SilphCo2F_Script:
SilphCo2FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo2F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo3F.asm b/scripts/SilphCo3F.asm
index df9df9e8..146cbb07 100644
--- a/scripts/SilphCo3F.asm
+++ b/scripts/SilphCo3F.asm
@@ -10,8 +10,8 @@ SilphCo3F_Script:
SilphCo3FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo2F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo4F.asm b/scripts/SilphCo4F.asm
index 91453d65..f84ef995 100644
--- a/scripts/SilphCo4F.asm
+++ b/scripts/SilphCo4F.asm
@@ -10,8 +10,8 @@ SilphCo4F_Script:
SilphCo4FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo4F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo5F.asm b/scripts/SilphCo5F.asm
index 1834bfa8..599c1743 100644
--- a/scripts/SilphCo5F.asm
+++ b/scripts/SilphCo5F.asm
@@ -10,8 +10,8 @@ SilphCo5F_Script:
SilphCo5FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo4F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo6F.asm b/scripts/SilphCo6F.asm
index 0626ffdb..ad8e83f4 100644
--- a/scripts/SilphCo6F.asm
+++ b/scripts/SilphCo6F.asm
@@ -10,8 +10,8 @@ SilphCo6F_Script:
SilphCo6F_GateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo4F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo7F.asm b/scripts/SilphCo7F.asm
index 381eff7a..bf517d29 100644
--- a/scripts/SilphCo7F.asm
+++ b/scripts/SilphCo7F.asm
@@ -10,8 +10,8 @@ SilphCo7F_Script:
SilphCo7F_GateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo7F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo8F.asm b/scripts/SilphCo8F.asm
index cdd7f486..dcba85c0 100644
--- a/scripts/SilphCo8F.asm
+++ b/scripts/SilphCo8F.asm
@@ -10,8 +10,8 @@ SilphCo8F_Script:
SilphCo8FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo8F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCo9F.asm b/scripts/SilphCo9F.asm
index fe7f3da2..aec4dbf8 100644
--- a/scripts/SilphCo9F.asm
+++ b/scripts/SilphCo9F.asm
@@ -10,8 +10,8 @@ SilphCo9F_Script:
SilphCo9FGateCallbackScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
ld hl, .GateCoordinates
call SilphCo9F_SetCardKeyDoorYScript
diff --git a/scripts/SilphCoElevator.asm b/scripts/SilphCoElevator.asm
index a2ed009e..ffdf101e 100644
--- a/scripts/SilphCoElevator.asm
+++ b/scripts/SilphCoElevator.asm
@@ -1,12 +1,12 @@
SilphCoElevator_Script:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
push hl
call nz, SilphCoElevatorStoreWarpEntriesScript
pop hl
- bit 7, [hl]
- res 7, [hl]
+ bit BIT_CUR_MAP_USED_ELEVATOR, [hl]
+ res BIT_CUR_MAP_USED_ELEVATOR, [hl]
call nz, SilphCoElevatorShakeScript
xor a
ld [wAutoTextBoxDrawingControl], a
diff --git a/scripts/VermilionCity.asm b/scripts/VermilionCity.asm
index fd5905df..40a08dbc 100644
--- a/scripts/VermilionCity.asm
+++ b/scripts/VermilionCity.asm
@@ -1,13 +1,13 @@
VermilionCity_Script:
call EnableAutoTextBoxDrawing
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
push hl
call nz, VermilionCityLeftSSAnneCallbackScript
pop hl
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
call nz, .setFirstLockTrashCanIndex
ld hl, VermilionCity_ScriptPointers
ld a, [wVermilionCityCurScript]
diff --git a/scripts/VermilionGym.asm b/scripts/VermilionGym.asm
index d7828e42..8d3a33b6 100644
--- a/scripts/VermilionGym.asm
+++ b/scripts/VermilionGym.asm
@@ -1,12 +1,12 @@
VermilionGym_Script:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
push hl
call nz, .LoadNames
pop hl
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
call nz, VermilionGymSetDoorTile
call EnableAutoTextBoxDrawing
ld hl, VermilionGymTrainerHeaders
diff --git a/scripts/VictoryRoad1F.asm b/scripts/VictoryRoad1F.asm
index e80e17d5..554ae39f 100644
--- a/scripts/VictoryRoad1F.asm
+++ b/scripts/VictoryRoad1F.asm
@@ -1,7 +1,7 @@
VictoryRoad1F_Script:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
call nz, .next
call EnableAutoTextBoxDrawing
ld hl, VictoryRoad1TrainerHeaders
@@ -31,7 +31,7 @@ VictoryRoad1FDefaultScript:
call CheckBoulderCoords
jp nc, CheckFightingMapTrainers
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
SetEvent EVENT_VICTORY_ROAD_1_BOULDER_ON_SWITCH
ret
diff --git a/scripts/VictoryRoad2F.asm b/scripts/VictoryRoad2F.asm
index 5e31da7a..85356247 100644
--- a/scripts/VictoryRoad2F.asm
+++ b/scripts/VictoryRoad2F.asm
@@ -1,11 +1,11 @@
VictoryRoad2F_Script:
ld hl, wCurrentMapScriptFlags
- bit 6, [hl]
- res 6, [hl]
+ bit BIT_CUR_MAP_LOADED_2, [hl]
+ res BIT_CUR_MAP_LOADED_2, [hl]
call nz, VictoryRoad2FResetBoulderEventScript
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
call nz, VictoryRoad2FCheckBoulderEventScript
call EnableAutoTextBoxDrawing
ld hl, VictoryRoad2TrainerHeaders
@@ -60,7 +60,7 @@ VictoryRoad2FDefaultScript:
ret nz
.set_script_flag
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
ret
.SwitchCoords:
diff --git a/scripts/VictoryRoad3F.asm b/scripts/VictoryRoad3F.asm
index e9295a15..2b1b11c0 100644
--- a/scripts/VictoryRoad3F.asm
+++ b/scripts/VictoryRoad3F.asm
@@ -10,8 +10,8 @@ VictoryRoad3F_Script:
VictoryRoad3FCheckBoulderEventScript:
ld hl, wCurrentMapScriptFlags
- bit 5, [hl]
- res 5, [hl]
+ bit BIT_CUR_MAP_LOADED_1, [hl]
+ res BIT_CUR_MAP_LOADED_1, [hl]
ret z
CheckEventHL EVENT_VICTORY_ROAD_3_BOULDER_ON_SWITCH1
ret z
@@ -38,7 +38,7 @@ VictoryRoad3FDefaultScript:
cp $1
jr nz, .handle_hole
ld hl, wCurrentMapScriptFlags
- set 5, [hl]
+ set BIT_CUR_MAP_LOADED_1, [hl]
SetEvent EVENT_VICTORY_ROAD_3_BOULDER_ON_SWITCH1
ret
.handle_hole