ref: 34ceaac71d32baace82f1e6de8fd4b252fb92a84
parent: 9f2c2627f5f19da37f7b73f2389151d8348ed914
author: mid-kid <esteve.varela@gmail.com>
date: Thu Feb 13 13:18:15 EST 2020
Call_LoadTempTileMapToTileMap → SafeLoadTempTileMapToTileMap Stupid name is stupid smh tbh fam.
--- a/engine/battle/core.asm
+++ b/engine/battle/core.asm
@@ -51,7 +51,7 @@
ld a, d
and a
jp z, LostBattle
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
ld a, [wBattleType]
cp BATTLETYPE_DEBUG
jp z, .tutorial_debug
@@ -116,7 +116,7 @@
jp BattleMenu
WildFled_EnemyFled_LinkBattleCanceled:
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
ld a, [wBattleResult]
and BATTLERESULT_BITMASK
add DRAW
@@ -624,7 +624,7 @@
ld [wFXAnimID], a
call MoveSelectionScreen
push af
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
call UpdateBattleHuds
ld a, [wCurPlayerMove]
cp STRUGGLE
@@ -2303,7 +2303,7 @@
cp BATTLEACTION_FORFEIT
ret z
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
.not_linked
ld hl, wBattleMonHP
@@ -3726,7 +3726,7 @@
ldh [hEnemyMonSpeed + 0], a
ld a, [de]
ldh [hEnemyMonSpeed + 1], a
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
ld de, hMultiplicand + 1
ld hl, hEnemyMonSpeed
ld c, 2
@@ -3808,7 +3808,7 @@
xor a
ld [wCurPlayerMove], a
call LinkBattleSendReceiveAction
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
call CheckMobileBattleError
jr c, .mobile
@@ -4907,7 +4907,7 @@
BattleMenu_Fight:
xor a
ld [wNumFleeAttempts], a
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
and a
ret
@@ -5283,7 +5283,7 @@
jp SpikesDamage
BattleMenu_Run:
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
ld a, $3
ld [wMenuCursorY], a
ld hl, wBattleMonSpeed
@@ -5508,7 +5508,7 @@
.place_textbox_start_over
call StdBattleTextbox
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
jp MoveSelectionScreen
.string_3e61c
@@ -5775,7 +5775,7 @@
ld a, [wBattlePlayerAction]
and a ; BATTLEPLAYERACTION_USEMOVE?
call z, LinkBattleSendReceiveAction
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
ld a, [wBattleAction]
cp BATTLEACTION_STRUGGLE
jp z, .struggle
@@ -7302,7 +7302,7 @@
ld c, 30
call DelayFrames
call WaitPressAorB_BlinkCursor
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
xor a ; PARTYMON
ld [wMonType], a
ld a, [wCurSpecies]
@@ -7799,7 +7799,7 @@
.finish
push hl
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
pop hl
jp StdBattleTextbox
--- a/engine/link/link.asm
+++ b/engine/link/link.asm
@@ -1369,7 +1369,7 @@
.b_button
pop af
ld [wMenuCursorY], a
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
jp LinkTrade_PlayerPartyMenu
.d_right
@@ -1407,7 +1407,7 @@
ld [wInitListType], a
callfar InitList
farcall LinkMonStatsScreen
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
hlcoord 6, 1
lb bc, 6, 1
ld a, " "
--- a/engine/pokemon/learn.asm
+++ b/engine/pokemon/learn.asm
@@ -166,7 +166,7 @@
ld [w2DMenuCursorOffsets], a
call StaticMenuJoypad
push af
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
pop af
pop hl
bit 1, a
--- a/engine/printer/printer.asm
+++ b/engine/printer/printer.asm
@@ -231,7 +231,7 @@
farcall PlaceUnownPrinterFrontpic
ln a, 0, 0 ; to be loaded to wPrinterMargins
call Printer_PrepareTileMapForPrint
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
call Printer_ResetJoypadRegisters
ld a, 18 / 2
ld [wPrinterQueueLength], a
@@ -259,7 +259,7 @@
pop af
ldh [hVBlank], a
call Printer_CleanUpAfterSend
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
xor a
ldh [rIF], a
pop af
@@ -418,7 +418,7 @@
ln a, 0, 3 ; to be loaded to wPrinterMargins
call Printer_PrepareTileMapForPrint
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
call Printer_ResetJoypadRegisters
ld a, 18 / 2
--- a/home/copy_tilemap.asm
+++ b/home/copy_tilemap.asm
@@ -12,7 +12,7 @@
ldh [rSVBK], a
ret
-Call_LoadTempTileMapToTileMap::
+SafeLoadTempTileMapToTileMap::
xor a
ldh [hBGMapMode], a
call LoadTempTileMapToTileMap
--- a/home/serial.asm
+++ b/home/serial.asm
@@ -276,7 +276,7 @@
call LoadTileMapToTempTileMap
callfar PlaceWaitingText
call WaitLinkTransfer
- jp Call_LoadTempTileMapToTileMap
+ jp SafeLoadTempTileMapToTileMap
Serial_SyncAndExchangeNybble::
call LoadTileMapToTempTileMap
--- a/mobile/mobile_40.asm
+++ b/mobile/mobile_40.asm
@@ -1857,7 +1857,7 @@
.print_text
call StdBattleTextbox
- call Call_LoadTempTileMapToTileMap
+ call SafeLoadTempTileMapToTileMap
jp .GetMoveSelection
Function100c74: