summaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
Diffstat (limited to 'engine')
-rwxr-xr-xengine/battle/animations.asm8
-rwxr-xr-xengine/battle/core.asm26
-rw-r--r--engine/battle/decrement_pp.asm2
-rw-r--r--engine/battle/effects.asm35
-rw-r--r--engine/battle/ghost_marowak_anim.asm2
-rw-r--r--engine/battle/move_effects/heal.asm6
-rw-r--r--engine/battle/move_effects/reflect_light_screen.asm6
-rw-r--r--engine/battle/move_effects/transform.asm2
-rwxr-xr-xengine/battle/read_trainer_party.asm4
-rwxr-xr-xengine/battle/safari_zone.asm10
-rw-r--r--engine/battle/scale_sprites.asm6
-rw-r--r--engine/battle/trainer_ai.asm2
-rwxr-xr-xengine/gfx/palettes.asm8
-rwxr-xr-xengine/gfx/screen_effects.asm2
-rw-r--r--engine/items/inventory.asm6
-rw-r--r--engine/link/print_waiting_text.asm13
-rw-r--r--engine/math/bcd.asm14
-rwxr-xr-xengine/movie/intro.asm4
-rw-r--r--engine/pokemon/add_mon.asm2
19 files changed, 82 insertions, 76 deletions
diff --git a/engine/battle/animations.asm b/engine/battle/animations.asm
index e10b5e0d..0673b518 100755
--- a/engine/battle/animations.asm
+++ b/engine/battle/animations.asm
@@ -133,7 +133,7 @@ DrawFrameBlock:
.afterDrawingTiles
ld a, [wFBMode]
cp FRAMEBLOCKMODE_02
- jr z, .advanceFrameBlockDestAddr; skip delay and don't clean OAM buffer
+ jr z, .advanceFrameBlockDestAddr ; skip delay and don't clean OAM buffer
ld a, [wSubAnimFrameDelay]
ld c, a
call DelayFrames
@@ -2410,7 +2410,7 @@ FallingObjects_InitXCoords:
ret
FallingObjects_InitialXCoords:
- db $38,$40,$50,$60,$70,$88,$90,$56,$67,$4A,$77,$84,$98,$32,$22,$5C,$6C,$7D,$8E,$99
+ db $38, $40, $50, $60, $70, $88, $90, $56, $67, $4A, $77, $84, $98, $32, $22, $5C, $6C, $7D, $8E, $99
FallingObjects_InitMovementData:
ld hl, wFallingObjectsMovementData
@@ -2426,7 +2426,7 @@ FallingObjects_InitMovementData:
ret
FallingObjects_InitialMovementData:
- db $00,$84,$06,$81,$02,$88,$01,$83,$05,$89,$09,$80,$07,$87,$03,$82,$04,$85,$08,$86
+ db $00, $84, $06, $81, $02, $88, $01, $83, $05, $89, $09, $80, $07, $87, $03, $82, $04, $85, $08, $86
AnimationShakeEnemyHUD:
; Shakes the enemy HUD.
@@ -2583,7 +2583,7 @@ TossBallAnimation:
.PokeBallAnimations:
; sequence of animations that make up the Poké Ball toss
- db POOF_ANIM,HIDEPIC_ANIM,SHAKE_ANIM,POOF_ANIM,SHOWPIC_ANIM
+ db POOF_ANIM, HIDEPIC_ANIM, SHAKE_ANIM, POOF_ANIM, SHOWPIC_ANIM
.BlockBall
ld a, TOSS_ANIM
diff --git a/engine/battle/core.asm b/engine/battle/core.asm
index 4628e86a..30ff68bc 100755
--- a/engine/battle/core.asm
+++ b/engine/battle/core.asm
@@ -1098,7 +1098,7 @@ ChooseNextMon:
ld a, [wLinkState]
cp LINK_STATE_BATTLING
jr nz, .notLinkBattle
- inc a
+ inc a ; 1
ld [wActionResultOrTookBattleTurn], a
call LinkBattleExchangeData
.notLinkBattle
@@ -1724,7 +1724,7 @@ SendOutMon:
ld hl, wEnemyMonHP
ld a, [hli]
or [hl] ; is enemy mon HP zero?
- jp z, .skipDrawingEnemyHUDAndHPBar; if HP is zero, skip drawing the HUD and HP bar
+ jp z, .skipDrawingEnemyHUDAndHPBar ; if HP is zero, skip drawing the HUD and HP bar
call DrawEnemyHUDAndHPBar
.skipDrawingEnemyHUDAndHPBar
call DrawPlayerHUDAndHPBar
@@ -2017,14 +2017,16 @@ DisplayBattleMenu::
dec a
jp nz, .handleBattleMenuInput ; handle menu input if it's not the old man tutorial
; the following happens for the old man tutorial
+ ; Temporarily save the player name in wGrassRate,
+ ; which is supposed to get overwritten when entering a
+ ; map with wild Pokémon.
+ ; Due to an oversight, the data may not get
+ ; overwritten (on Cinnabar and Route 21) and the infamous
+ ; Missingno. glitch can show up.
ld hl, wPlayerName
ld de, wGrassRate
ld bc, NAME_LENGTH
- call CopyData ; temporarily save the player name in unused space,
- ; which is supposed to get overwritten when entering a
- ; map with wild Pokémon. Due to an oversight, the data
- ; may not get overwritten (cinnabar) and the infamous
- ; Missingno. glitch can show up.
+ call CopyData
ld hl, .oldManName
ld de, wPlayerName
ld bc, NAME_LENGTH
@@ -2206,7 +2208,7 @@ BagWasSelected:
OldManItemList:
db 1 ; # items
db POKE_BALL, 50
- db -1
+ db -1 ; end
DisplayPlayerBag:
; get the pointer to player's bag when in a normal battle
@@ -4101,7 +4103,7 @@ CheckForDisobedience:
call GetCurrentMove
.canUseMove
ld a, $1
- and a; clear Z flag
+ and a ; clear Z flag
ret
.cannotUseMove
xor a ; set Z flag
@@ -4485,7 +4487,7 @@ CalculateDamage:
ld b, 4
call Divide
-; Update wCurDamage.
+; Update wCurDamage.
; Capped at MAX_NEUTRAL_DAMAGE - MIN_NEUTRAL_DAMAGE: 999 - 2 = 997.
ld hl, wDamage
ld b, [hl]
@@ -4574,7 +4576,7 @@ JumpToOHKOMoveEffect:
INCLUDE "data/battle/unused_critical_hit_moves.asm"
; determines if attack is a critical hit
-; azure heights claims "the fastest pokémon (who are,not coincidentally,
+; Azure Heights claims "the fastest pokémon (who are, not coincidentally,
; among the most popular) tend to CH about 20 to 25% of the time."
CriticalHitTest:
xor a
@@ -6302,7 +6304,7 @@ LoadPlayerBackPic:
dec a ; is it the old man tutorial?
ld de, RedPicBack
jr nz, .next
- ld de, OldManPic
+ ld de, OldManPicBack
.next
ld a, BANK(RedPicBack)
call UncompressSpriteFromDE
diff --git a/engine/battle/decrement_pp.asm b/engine/battle/decrement_pp.asm
index b7c428f7..441bbb81 100644
--- a/engine/battle/decrement_pp.asm
+++ b/engine/battle/decrement_pp.asm
@@ -37,7 +37,7 @@ DecrementPP:
ld a, [wPlayerMoveListIndex] ; which move (0, 1, 2, 3) did we use?
ld c, a
ld b, 0
- add hl ,bc ; calculate the address in memory of the PP we need to decrement
+ add hl, bc ; calculate the address in memory of the PP we need to decrement
; based on the move chosen.
dec [hl] ; Decrement PP
ret
diff --git a/engine/battle/effects.asm b/engine/battle/effects.asm
index 441d6c1c..f455a407 100644
--- a/engine/battle/effects.asm
+++ b/engine/battle/effects.asm
@@ -198,7 +198,7 @@ FreezeBurnParalyzeEffect:
ret nz ; return if they have a substitute, can't effect them
ldh a, [hWhoseTurn]
and a
- jp nz, opponentAttacker
+ jp nz, .opponentAttacker
ld a, [wEnemyMonStatus]
and a
jp nz, CheckDefrost ; can't inflict status if opponent is already statused
@@ -224,17 +224,17 @@ FreezeBurnParalyzeEffect:
ret nc ; do nothing if random value is >= 1A or 4D [no status applied]
ld a, b ; what type of effect is this?
cp BURN_SIDE_EFFECT1
- jr z, .burn
+ jr z, .burn1
cp FREEZE_SIDE_EFFECT
- jr z, .freeze
-; .paralyze
+ jr z, .freeze1
+; .paralyze1
ld a, 1 << PAR
ld [wEnemyMonStatus], a
call QuarterSpeedDueToParalysis ; quarter speed of affected mon
ld a, ANIM_A9
call PlayBattleAnimation
jp PrintMayNotAttackText ; print paralysis text
-.burn
+.burn1
ld a, 1 << BRN
ld [wEnemyMonStatus], a
call HalveAttackDueToBurn ; halve attack of affected mon
@@ -242,7 +242,7 @@ FreezeBurnParalyzeEffect:
call PlayBattleAnimation
ld hl, BurnedText
jp PrintText
-.freeze
+.freeze1
call ClearHyperBeam ; resets hyper beam (recharge) condition from target
ld a, 1 << FRZ
ld [wEnemyMonStatus], a
@@ -250,7 +250,7 @@ FreezeBurnParalyzeEffect:
call PlayBattleAnimation
ld hl, FrozenText
jp PrintText
-opponentAttacker:
+.opponentAttacker
ld a, [wBattleMonStatus] ; mostly same as above with addresses swapped for opponent
and a
jp nz, CheckDefrost
@@ -265,10 +265,10 @@ opponentAttacker:
ld a, [wEnemyMoveEffect]
cp PARALYZE_SIDE_EFFECT1 + 1
ld b, $1a
- jr c, .next1
+ jr c, .next2
ld b, $4d
sub $1e
-.next1
+.next2
push af
call BattleRandom
cp b
@@ -276,20 +276,21 @@ opponentAttacker:
ret nc
ld a, b
cp BURN_SIDE_EFFECT1
- jr z, .burn
+ jr z, .burn2
cp FREEZE_SIDE_EFFECT
- jr z, .freeze
+ jr z, .freeze2
+; .paralyze2
ld a, 1 << PAR
ld [wBattleMonStatus], a
call QuarterSpeedDueToParalysis
jp PrintMayNotAttackText
-.burn
+.burn2
ld a, 1 << BRN
ld [wBattleMonStatus], a
call HalveAttackDueToBurn
ld hl, BurnedText
jp PrintText
-.freeze
+.freeze2
; hyper beam bits aren't reseted for opponent's side
ld a, 1 << FRZ
ld [wBattleMonStatus], a
@@ -458,14 +459,14 @@ UpdateStatDone:
ld bc, wPlayerMonMinimized
ldh a, [hWhoseTurn]
and a
- jr z, .asm_3f4e6
+ jr z, .playerTurn
ld hl, wEnemyBattleStatus2
ld de, wEnemyMoveNum
ld bc, wEnemyMonMinimized
-.asm_3f4e6
+.playerTurn
ld a, [de]
cp MINIMIZE
- jr nz, .asm_3f4f9
+ jr nz, .notMinimize
; if a substitute is up, slide off the substitute and show the mon pic before
; playing the minimize animation
bit HAS_SUBSTITUTE_UP, [hl]
@@ -476,7 +477,7 @@ UpdateStatDone:
push de
call nz, Bankswitch
pop de
-.asm_3f4f9
+.notMinimize
call PlayCurrentMoveAnimation
ld a, [de]
cp MINIMIZE
diff --git a/engine/battle/ghost_marowak_anim.asm b/engine/battle/ghost_marowak_anim.asm
index 6760c3d5..9c1ad96f 100644
--- a/engine/battle/ghost_marowak_anim.asm
+++ b/engine/battle/ghost_marowak_anim.asm
@@ -74,7 +74,7 @@ CopyMonPicFromBGToSpriteVRAM:
ld [hli], a
ld a, d
ld [hli], a
- ld a, $10 ; use OBP1
+ ld a, OAM_OBP1
ld [hli], a
inc d
dec c
diff --git a/engine/battle/move_effects/heal.asm b/engine/battle/move_effects/heal.asm
index e9fb62a7..c3ffda65 100644
--- a/engine/battle/move_effects/heal.asm
+++ b/engine/battle/move_effects/heal.asm
@@ -86,7 +86,7 @@ HealEffect_:
ld [wHPBarNewHP], a
.playAnim
ld hl, PlayCurrentMoveAnimation
- call BankswitchEtoF
+ call EffectCallBattleCore
ldh a, [hWhoseTurn]
and a
hlcoord 10, 9
@@ -98,14 +98,14 @@ HealEffect_:
ld [wHPBarType], a
predef UpdateHPBar2
ld hl, DrawHUDsAndHPBars
- call BankswitchEtoF
+ call EffectCallBattleCore
ld hl, RegainedHealthText
jp PrintText
.failed
ld c, 50
call DelayFrames
ld hl, PrintButItFailedText_
- jp BankswitchEtoF
+ jp EffectCallBattleCore
StartedSleepingEffect:
text_far _StartedSleepingEffect
diff --git a/engine/battle/move_effects/reflect_light_screen.asm b/engine/battle/move_effects/reflect_light_screen.asm
index 7bdc7be7..46c299e9 100644
--- a/engine/battle/move_effects/reflect_light_screen.asm
+++ b/engine/battle/move_effects/reflect_light_screen.asm
@@ -23,14 +23,14 @@ ReflectLightScreenEffect_:
.playAnim
push hl
ld hl, PlayCurrentMoveAnimation
- call BankswitchEtoF
+ call EffectCallBattleCore
pop hl
jp PrintText
.moveFailed
ld c, 50
call DelayFrames
ld hl, PrintButItFailedText_
- jp BankswitchEtoF
+ jp EffectCallBattleCore
LightScreenProtectedText:
text_far _LightScreenProtectedText
@@ -40,6 +40,6 @@ ReflectGainedArmorText:
text_far _ReflectGainedArmorText
text_end
-BankswitchEtoF:
+EffectCallBattleCore:
ld b, BANK(BattleCore)
jp Bankswitch
diff --git a/engine/battle/move_effects/transform.asm b/engine/battle/move_effects/transform.asm
index 46cea51c..56dda7f4 100644
--- a/engine/battle/move_effects/transform.asm
+++ b/engine/battle/move_effects/transform.asm
@@ -141,7 +141,7 @@ TransformEffect_:
.failed
ld hl, PrintButItFailedText_
- jp BankswitchEtoF
+ jp EffectCallBattleCore
TransformedText:
text_far _TransformedText
diff --git a/engine/battle/read_trainer_party.asm b/engine/battle/read_trainer_party.asm
index 7e5c1249..a0132a4f 100755
--- a/engine/battle/read_trainer_party.asm
+++ b/engine/battle/read_trainer_party.asm
@@ -16,7 +16,7 @@ ReadTrainer:
; get the pointer to trainer data for this class
ld a, [wCurOpponent]
- sub $C9 ; convert value from pokemon to trainer
+ sub OPP_ID_OFFSET + 1 ; convert value from pokemon to trainer
add a
ld hl, TrainerDataPointers
ld c, a
@@ -79,7 +79,7 @@ ReadTrainer:
pop hl
jr .SpecialTrainer
.AddLoneMove
-; does the trainer have a single monster with a different move
+; does the trainer have a single monster with a different move?
ld a, [wLoneAttackNo] ; Brock is 01, Misty is 02, Erika is 04, etc
and a
jr z, .AddTeamMove
diff --git a/engine/battle/safari_zone.asm b/engine/battle/safari_zone.asm
index 4f01c2f4..a61f402f 100755
--- a/engine/battle/safari_zone.asm
+++ b/engine/battle/safari_zone.asm
@@ -2,18 +2,18 @@ PrintSafariZoneBattleText:
ld hl, wSafariBaitFactor
ld a, [hl]
and a
- jr z, .asm_4284
+ jr z, .no_bait
dec [hl]
ld hl, SafariZoneEatingText
- jr .asm_429f
-.asm_4284
+ jr .done
+.no_bait
dec hl
ld a, [hl]
and a
ret z
dec [hl]
ld hl, SafariZoneAngryText
- jr nz, .asm_429f
+ jr nz, .done
push hl
ld a, [wEnemyMonSpecies]
ld [wd0b5], a
@@ -21,7 +21,7 @@ PrintSafariZoneBattleText:
ld a, [wMonHCatchRate]
ld [wEnemyMonActualCatchRate], a
pop hl
-.asm_429f
+.done
push hl
call LoadScreenTilesFromBuffer1
pop hl
diff --git a/engine/battle/scale_sprites.asm b/engine/battle/scale_sprites.asm
index 87b4398d..8b8942e6 100644
--- a/engine/battle/scale_sprites.asm
+++ b/engine/battle/scale_sprites.asm
@@ -4,11 +4,11 @@
ScaleSpriteByTwo:
ld de, sSpriteBuffer1 + (4*4*8) - 5 ; last byte of input data, last 4 rows already skipped
ld hl, sSpriteBuffer0 + SPRITEBUFFERSIZE - 1 ; end of destination buffer
- call ScaleLastSpriteColumnByTwo ; last tile column is special case
- call ScaleFirstThreeSpriteColumnsByTwo ; scale first 3 tile columns
+ call ScaleLastSpriteColumnByTwo ; last tile column is special case
+ call ScaleFirstThreeSpriteColumnsByTwo ; scale first 3 tile columns
ld de, sSpriteBuffer2 + (4*4*8) - 5 ; last byte of input data, last 4 rows already skipped
ld hl, sSpriteBuffer1 + SPRITEBUFFERSIZE - 1 ; end of destination buffer
- call ScaleLastSpriteColumnByTwo ; last tile column is special case
+ call ScaleLastSpriteColumnByTwo ; last tile column is special case
ScaleFirstThreeSpriteColumnsByTwo:
ld b, $3 ; 3 tile columns
diff --git a/engine/battle/trainer_ai.asm b/engine/battle/trainer_ai.asm
index 2225dca1..0de67f42 100644
--- a/engine/battle/trainer_ai.asm
+++ b/engine/battle/trainer_ai.asm
@@ -294,7 +294,7 @@ TrainerAI:
ret z ; if not a trainer, we're done here
ld a, [wLinkState]
cp LINK_STATE_BATTLING
- ret z
+ ret z ; if in a link battle, we're done as well
ld a, [wTrainerClass] ; what trainer class is this?
dec a
ld c, a
diff --git a/engine/gfx/palettes.asm b/engine/gfx/palettes.asm
index f25ff215..a43c66ba 100755
--- a/engine/gfx/palettes.asm
+++ b/engine/gfx/palettes.asm
@@ -353,10 +353,10 @@ SendSGBPacket:
ld d, a
.nextBit0
bit 0, d
-; if 0th bit is not zero set P14=HIGH,P15=LOW (send bit 1)
+; if 0th bit is not zero set P14=HIGH, P15=LOW (send bit 1)
ld a, $10
jr nz, .next0
-; else (if 0th bit is zero) set P14=LOW,P15=HIGH (send bit 0)
+; else (if 0th bit is zero) set P14=LOW, P15=HIGH (send bit 0)
ld a, $20
.next0
ldh [rJOYP], a
@@ -364,7 +364,7 @@ SendSGBPacket:
ld a, $30
ldh [rJOYP], a
; rotation will put next bit in 0th position (so we can always use command
-; "bit 0,d" to fetch the bit that has to be sent)
+; "bit 0, d" to fetch the bit that has to be sent)
rr d
; decrease bit counter so we know when we have sent all 8 bits of current byte
dec e
@@ -608,9 +608,7 @@ CopySGBBorderTiles:
; This function converts 2BPP planar data into this format by mapping
; 2BPP colors 0-3 to 4BPP colors 0-3. 4BPP colors 4-15 are not used.
ld b, 128
-
.tileLoop
-
; Copy bit planes 1 and 2 of the tile data.
ld c, 16
.copyLoop
diff --git a/engine/gfx/screen_effects.asm b/engine/gfx/screen_effects.asm
index e8648901..c7a68734 100755
--- a/engine/gfx/screen_effects.asm
+++ b/engine/gfx/screen_effects.asm
@@ -1,4 +1,4 @@
-; b = new colour for BG colour 0 (usually white) for 4 frames
+; b = new color for BG color 0 (usually white) for 4 frames
ChangeBGPalColor0_4Frames:
call GetPredefRegisters
ldh a, [rBGP]
diff --git a/engine/items/inventory.asm b/engine/items/inventory.asm
index bf433175..ec1cfd0f 100644
--- a/engine/items/inventory.asm
+++ b/engine/items/inventory.asm
@@ -27,7 +27,7 @@ AddItemToInventory_::
ld a, [hli]
and a
jr z, .addNewItem
-.loop
+.notAtEndOfInventory
ld a, [hli]
ld b, a ; b = ID of current item in table
ld a, [wcf91] ; a = ID of item being added
@@ -36,7 +36,7 @@ AddItemToInventory_::
inc hl
ld a, [hl]
cp $ff ; is it the end of the table?
- jr nz, .loop
+ jr nz, .notAtEndOfInventory
.addNewItem ; add an item not yet in the inventory
pop hl
ld a, d
@@ -73,7 +73,7 @@ AddItemToInventory_::
; if so, store 99 in the current slot and store the rest in a new slot
ld a, 99
ld [hli], a
- jp .loop
+ jp .notAtEndOfInventory
.increaseItemQuantityFailed
pop hl
and a
diff --git a/engine/link/print_waiting_text.asm b/engine/link/print_waiting_text.asm
index d74d635f..1a16e2f2 100644
--- a/engine/link/print_waiting_text.asm
+++ b/engine/link/print_waiting_text.asm
@@ -1,15 +1,16 @@
PrintWaitingText::
hlcoord 3, 10
- ld b, $1
- ld c, $b
+ ld b, 1
+ ld c, 11
ld a, [wIsInBattle]
and a
- jr z, .asm_4c17
+ jr z, .trade
+; battle
call TextBoxBorder
- jr .asm_4c1a
-.asm_4c17
+ jr .border_done
+.trade
call CableClub_TextBoxBorder
-.asm_4c1a
+.border_done
hlcoord 4, 11
ld de, WaitingText
call PlaceString
diff --git a/engine/math/bcd.asm b/engine/math/bcd.asm
index 1e5aedc9..5747a684 100644
--- a/engine/math/bcd.asm
+++ b/engine/math/bcd.asm
@@ -1,6 +1,9 @@
+; divide hMoney by hDivideBCDDivisor
+; return output in hDivideBCDQuotient (same as hDivideBCDDivisor)
+; used only to halve player money upon losing a fight
DivideBCDPredef::
DivideBCDPredef2::
-DivideBCDPredef3::
+DivideBCDPredef3:: ; only used function
DivideBCDPredef4::
call GetPredefRegisters
@@ -10,7 +13,7 @@ DivideBCD::
ldh [hDivideBCDBuffer+1], a
ldh [hDivideBCDBuffer+2], a
ld d, $1
-.mulBy10Loop
+.mulBy10Loop
; multiply the divisor by 10 until the leading digit is nonzero
; to set up the standard long division algorithm
ldh a, [hDivideBCDDivisor]
@@ -40,6 +43,7 @@ DivideBCD::
and $f0
ldh [hDivideBCDDivisor+2], a
jr .mulBy10Loop
+
.next
push de
push de
@@ -104,7 +108,7 @@ DivideBCD::
ldh a, [hDivideBCDBuffer+2]
ldh [hDivideBCDQuotient+2], a
pop de
- ld a, $6
+ ld a, $6
sub d
and a
ret z
@@ -151,8 +155,8 @@ DivideBCD_getNextDigit:
pop bc
ret c
inc b
- ld de, hMoney+2 ; since SubBCD works starting from the least significant digit
- ld hl, hDivideBCDDivisor+2
+ ld de, hMoney + 2 ; since SubBCD works starting from the least significant digit
+ ld hl, hDivideBCDDivisor + 2
push bc
call SubBCD
pop bc
diff --git a/engine/movie/intro.asm b/engine/movie/intro.asm
index 040d643d..9813d67c 100755
--- a/engine/movie/intro.asm
+++ b/engine/movie/intro.asm
@@ -23,7 +23,7 @@ PlayIntro:
PlayIntroScene:
ld b, SET_PAL_NIDORINO_INTRO
call RunPaletteCommand
- ldPal a, BLACK, DARK_GRAY, LIGHT_GRAY, WHITE
+ ldpal a, SHADE_BLACK, SHADE_DARK, SHADE_LIGHT, SHADE_WHITE
ldh [rBGP], a
ldh [rOBP0], a
ldh [rOBP1], a
@@ -307,7 +307,7 @@ PlayShootingStar:
ld b, SET_PAL_GAME_FREAK_INTRO
call RunPaletteCommand
farcall LoadCopyrightAndTextBoxTiles
- ldPal a, BLACK, DARK_GRAY, LIGHT_GRAY, WHITE
+ ldpal a, SHADE_BLACK, SHADE_DARK, SHADE_LIGHT, SHADE_WHITE
ldh [rBGP], a
ld c, 180
call DelayFrames
diff --git a/engine/pokemon/add_mon.asm b/engine/pokemon/add_mon.asm
index d7e7eab1..c49a0a77 100644
--- a/engine/pokemon/add_mon.asm
+++ b/engine/pokemon/add_mon.asm
@@ -430,7 +430,7 @@ _MoveMon::
cp PARTY_TO_DAYCARE
ld de, wDayCareMonOT
jr z, .findOTsrc
- dec a
+ dec a
ld hl, wPartyMonOT
ld a, [wPartyCount]
jr nz, .addOToffset