Skeetendo

’Cause all games were better on the GBC

You are not logged in.

#1 2017-06-25 19:24:16

Jirachii.
New member
Registered: 2017-06-25
Post 1/2

pokecrystal shininess

Hey

I was wondering if there's a way to determine shininess in a different way, for example complete random instead of DV.

I found these codes:

BattleCheckEnemyShininess: ; 3da79
    call GetEnemyMonDVs

BattleCheckShininess: ; 3da7c
    ld b, h
    ld c, l
    callab CheckShininess
    ret
; 3da85
CheckShininess:
; Check if a mon is shiny by DVs at bc.
; Return carry if shiny.

    ld l, c
    ld h, b

; Attack
    ld a, [hl]
    and 1 << SHINY_ATK_BIT
    jr z, .NotShiny

; Defense
    ld a, [hli]
    and $f
    cp  SHINY_DEF_VAL
    jr nz, .NotShiny

; Speed
    ld a, [hl]
    and $f0
    cp  SHINY_SPD_VAL << 4
    jr nz, .NotShiny

; Special
    ld a, [hl]
    and $f
    cp  SHINY_SPC_VAL
    jr nz, .NotShiny

.Shiny:
    scf
    ret

.NotShiny:
    and a
    ret

So is it possible to get it to work like it's just 10/20% chance of being shiny, regardless of the Ds?

Offline

Board footer

Powered by FluxBB