From 8a6d46f3d9ba4fb6939eb9ea9949f47aa8608d4a Mon Sep 17 00:00:00 2001 From: dannye Date: Sun, 9 Aug 2015 23:56:20 -0500 Subject: Replace some hardcoded data sizes --- engine/battle/battle_transitions.asm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'engine/battle/battle_transitions.asm') diff --git a/engine/battle/battle_transitions.asm b/engine/battle/battle_transitions.asm index e9e247f9..8f57777c 100644 --- a/engine/battle/battle_transitions.asm +++ b/engine/battle/battle_transitions.asm @@ -184,11 +184,12 @@ DungeonMaps2: ; 70a44 (1c:4a44) LoadBattleTransitionTile: ; 70a4d (1c:4a4d) ld hl, vChars1 + $7f0 ld de, BattleTransitionTile - lb bc, BANK(BattleTransitionTile), $01 + lb bc, BANK(BattleTransitionTile), (BattleTransitionTileEnd - BattleTransitionTile) / $10 jp CopyVideoData BattleTransitionTile: ; 70a59 (1c:4a59) INCBIN "gfx/battle_transition.2bpp" +BattleTransitionTileEnd: BattleTransition_BlackScreen: ; 70a69 (1c:4a69) ld a, $ff -- cgit v1.2.3 From dfc152d667e3695f83eb0fbabb839b0fad275ceb Mon Sep 17 00:00:00 2001 From: dannye Date: Mon, 10 Aug 2015 11:09:16 -0500 Subject: No more $C8 Use OPP_ constants separate from trainer constants since valid opponents can be all Pokemon and trainers --- engine/battle/battle_transitions.asm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'engine/battle/battle_transitions.asm') diff --git a/engine/battle/battle_transitions.asm b/engine/battle/battle_transitions.asm index 8f57777c..9a5f62b1 100644 --- a/engine/battle/battle_transitions.asm +++ b/engine/battle/battle_transitions.asm @@ -82,7 +82,7 @@ BattleTransitions: ; 709d2 (1c:49d2) GetBattleTransitionID_WildOrTrainer: ; 709e2 (1c:49e2) ld a, [W_CUROPPONENT] - cp $c8 + cp 200 jr nc, .trainer res 0, c ret -- cgit v1.2.3 From 38065a744de1065cc021a4cafe22476f8425448d Mon Sep 17 00:00:00 2001 From: dannye Date: Sun, 30 Aug 2015 21:38:41 -0500 Subject: No more W_ --- engine/battle/battle_transitions.asm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'engine/battle/battle_transitions.asm') diff --git a/engine/battle/battle_transitions.asm b/engine/battle/battle_transitions.asm index 9a5f62b1..545273ee 100644 --- a/engine/battle/battle_transitions.asm +++ b/engine/battle/battle_transitions.asm @@ -81,7 +81,7 @@ BattleTransitions: ; 709d2 (1c:49d2) dw BattleTransition_Split ; %111 GetBattleTransitionID_WildOrTrainer: ; 709e2 (1c:49e2) - ld a, [W_CUROPPONENT] + ld a, [wCurOpponent] cp 200 jr nc, .trainer res 0, c @@ -105,7 +105,7 @@ GetBattleTransitionID_CompareLevels: ; 709ef (1c:49ef) ld a, [hl] add $3 ld e, a - ld a, [W_CURENEMYLVL] + ld a, [wCurEnemyLVL] sub e jr nc, .highLevelEnemy res 1, c @@ -122,7 +122,7 @@ GetBattleTransitionID_CompareLevels: ; 709ef (1c:49ef) ; MANSION_1, SEAFOAM_ISLANDS_[2-5], POWER_PLANT, DIGLETTS_CAVE ; and SILPH_CO_[9-11]F as dungeon maps GetBattleTransitionID_IsDungeonMap: ; 70a19 (1c:4a19) - ld a, [W_CURMAP] + ld a, [wCurMap] ld e, a ld hl, DungeonMaps1 .loop1 @@ -151,7 +151,7 @@ GetBattleTransitionID_IsDungeonMap: ; 70a19 (1c:4a19) res 2, c ret -; GetBattleTransitionID_IsDungeonMap checks if W_CURMAP +; GetBattleTransitionID_IsDungeonMap checks if wCurMap ; is equal to one of these maps DungeonMaps1: ; 70a3f (1c:4a3f) db VIRIDIAN_FOREST @@ -160,7 +160,7 @@ DungeonMaps1: ; 70a3f (1c:4a3f) db ROCK_TUNNEL_2 db $FF -; GetBattleTransitionID_IsDungeonMap checks if W_CURMAP +; GetBattleTransitionID_IsDungeonMap checks if wCurMap ; is in between or equal to each pair of maps DungeonMaps2: ; 70a44 (1c:4a44) ; all MT_MOON maps -- cgit v1.2.3