mirror of
https://github.com/thornAvery/jep-hack.git
synced 2026-02-07 08:35:23 +13:00
First Commit
Upload literally everything from the pokecrystal16 expand-move-ID branch
This commit is contained in:
commit
2f8a41f833
4618 changed files with 480386 additions and 0 deletions
20
engine/pokemon/level_up_happiness.asm
Normal file
20
engine/pokemon/level_up_happiness.asm
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
LevelUpHappinessMod:
|
||||
ld a, [wCurPartyMon]
|
||||
ld hl, wPartyMon1CaughtLocation
|
||||
call GetPartyLocation
|
||||
ld a, [hl]
|
||||
and CAUGHT_LOCATION_MASK
|
||||
ld d, a
|
||||
ld a, [wMapGroup]
|
||||
ld b, a
|
||||
ld a, [wMapNumber]
|
||||
ld c, a
|
||||
call GetWorldMapLocation
|
||||
cp d
|
||||
ld c, HAPPINESS_GAINLEVEL
|
||||
jr nz, .ok
|
||||
ld c, HAPPINESS_GAINLEVELATHOME
|
||||
|
||||
.ok
|
||||
callfar ChangeHappiness
|
||||
ret
|
||||
Loading…
Add table
Add a link
Reference in a new issue