fixed shiny palette on pokedex new entry + gamecorner

This commit is contained in:
Thorn Avery 2025-09-04 14:31:02 +10:00
parent 7a8d406605
commit bc42af64c5
7 changed files with 46 additions and 13 deletions

View file

@ -236,17 +236,26 @@ SetPlayerPalette:
ret
GameCornerPrizeMonCheckDex:
xor a
ld [wPokedexShinyToggle], a
ld [wWasMonCaught], a
ld a, [wScriptVar]
call CheckCaughtMon
ret nz
ld a, [wScriptVar]
call SetSeenAndCaughtMon
ld a, 1
ld [wWasMonCaught], a
ret
GameCornerPrizeMonShowDex:
ld a, [wWasMonCaught]
cp 0
ret z
call FadeToMenu
ld a, [wScriptVar]
ld [wNamedObjectIndex], a
farcall NewPokedexEntry
call ExitAllMenus
ret
ret
UnusedSetSeenMon:
ld a, [wScriptVar]

View file

@ -532,6 +532,15 @@ PokeBallEffect:
ld a, [wEnemyMonSpecies]
ld [wTempSpecies], a
farcall BattleCheckEnemyShininess
jp c, .shiny
xor a
jp .shinycont
.shiny
xor a
inc a
.shinycont
ld [wPokedexShinyToggle], a
predef NewPokedexEntry
.skip_pokedex

View file

@ -1,13 +1,4 @@
NewPokedexEntry:
farcall BattleCheckEnemyShininess
jp c, .shiny
xor a
jp .cont
.shiny
xor a
inc a
.cont
ld [wPokedexShinyToggle], a
ldh a, [hMapAnims]
push af
xor a

View file

@ -210,8 +210,24 @@ endr
inc de
ld a, c
ld [de], a
inc de
; Set Shininess for New Dex Entry
dec de
ld b, d
ld c, e
farcall CheckShininess
jp c, .shiny
xor a
jp .shinycont
.shiny
xor a
inc a
.shinycont
ld [wPokedexShinyToggle], a
; Unclobber de
inc de
inc de
; Initialize PP.
push hl
push de