summaryrefslogtreecommitdiff
path: root/home.asm
diff options
context:
space:
mode:
authordannye <corrnondacqb@yahoo.com>2015-08-10 11:09:16 -0500
committerdannye <corrnondacqb@yahoo.com>2015-08-10 11:09:16 -0500
commitdfc152d667e3695f83eb0fbabb839b0fad275ceb (patch)
tree37255b78ab19c520a651ec68ca10a9f43ebe07d7 /home.asm
parent31d267d4ad87042dbdd30be645ad4b43e4e3ceb1 (diff)
No more $C8
Use OPP_ constants separate from trainer constants since valid opponents can be all Pokemon and trainers
Diffstat (limited to 'home.asm')
-rw-r--r--home.asm10
1 files changed, 5 insertions, 5 deletions
diff --git a/home.asm b/home.asm
index 41d25238..2d64833f 100644
--- a/home.asm
+++ b/home.asm
@@ -2396,7 +2396,7 @@ EndTrainerBattle:: ; 3275 (0:3275)
ld b, FLAG_SET
call TrainerFlagAction ; flag trainer as fought
ld a, [W_ENEMYMONORTRAINERCLASS]
- cp $c8
+ cp 200
jr nc, .skipRemoveSprite ; test if trainer was fought (in that case skip removing the corresponding sprite)
ld hl, W_MISSABLEOBJECTLIST
ld de, $2
@@ -2430,7 +2430,7 @@ InitBattleEnemyParameters:: ; 32d7 (0:32d7)
ld a, [wEngagedTrainerClass]
ld [W_CUROPPONENT], a
ld [W_ENEMYMONORTRAINERCLASS], a
- cp $c8
+ cp 200
ld a, [wEngagedTrainerSet]
jr c, .noTrainer
ld [W_TRAINERNO], a
@@ -2594,11 +2594,11 @@ CheckIfAlreadyEngaged:: ; 33dd (0:33dd)
PlayTrainerMusic:: ; 33e8 (0:33e8)
ld a, [wEngagedTrainerClass]
- cp $c8 + SONY1
+ cp OPP_SONY1
ret z
- cp $c8 + SONY2
+ cp OPP_SONY2
ret z
- cp $c8 + SONY3
+ cp OPP_SONY3
ret z
ld a, [W_GYMLEADERNO]
and a