mirror of
https://github.com/thornAvery/kep-hack.git
synced 2025-09-17 02:40:50 +12:00
fixed names
This commit is contained in:
parent
f658aff538
commit
40c1ecb437
|
@ -92,9 +92,9 @@ InitList: ; 39bd5 (e:5bd5)
|
||||||
ld a, h
|
ld a, h
|
||||||
ld [wListPointer + 1], a
|
ld [wListPointer + 1], a
|
||||||
ld a, e
|
ld a, e
|
||||||
ld [wcf8d], a
|
ld [wUnusedCF8D], a
|
||||||
ld a, d
|
ld a, d
|
||||||
ld [wcf8e], a
|
ld [wUnusedCF8D + 1], a
|
||||||
ld bc, ItemPrices
|
ld bc, ItemPrices
|
||||||
ld a, c
|
ld a, c
|
||||||
ld [wItemPrices], a
|
ld [wItemPrices], a
|
||||||
|
|
|
@ -191,7 +191,7 @@ AIMoveChoiceModification2: ; 397e7 (e:57e7)
|
||||||
AIMoveChoiceModification3: ; 39817 (e:5817)
|
AIMoveChoiceModification3: ; 39817 (e:5817)
|
||||||
ld hl, wBuffer - 1 ; temp move selection array (-1 byte offset)
|
ld hl, wBuffer - 1 ; temp move selection array (-1 byte offset)
|
||||||
ld de, wEnemyMonMoves ; enemy moves
|
ld de, wEnemyMonMoves ; enemy moves
|
||||||
ld b, $5
|
ld b, NUM_MOVES + 1
|
||||||
.nextMove
|
.nextMove
|
||||||
dec b
|
dec b
|
||||||
ret z ; processed all 4 moves
|
ret z ; processed all 4 moves
|
||||||
|
@ -208,7 +208,7 @@ AIMoveChoiceModification3: ; 39817 (e:5817)
|
||||||
pop de
|
pop de
|
||||||
pop bc
|
pop bc
|
||||||
pop hl
|
pop hl
|
||||||
ld a, [wd11e]
|
ld a, [wTypeEffectiveness]
|
||||||
cp $10
|
cp $10
|
||||||
jr z, .nextMove
|
jr z, .nextMove
|
||||||
jr c, .notEffectiveMove
|
jr c, .notEffectiveMove
|
||||||
|
|
|
@ -256,9 +256,9 @@ CableClub_DoBattleOrTradeAgain: ; 5345
|
||||||
dec c
|
dec c
|
||||||
jr nz, .unpatchEnemyMonsLoop
|
jr nz, .unpatchEnemyMonsLoop
|
||||||
ld a, wEnemyMonOT % $100
|
ld a, wEnemyMonOT % $100
|
||||||
ld [wcf8d], a
|
ld [wUnusedCF8D], a
|
||||||
ld a, wEnemyMonOT / $100
|
ld a, wEnemyMonOT / $100
|
||||||
ld [wcf8e], a
|
ld [wUnusedCF8D + 1], a
|
||||||
xor a
|
xor a
|
||||||
ld [wTradeCenterPointerTableIndex], a
|
ld [wTradeCenterPointerTableIndex], a
|
||||||
ld a, $ff
|
ld a, $ff
|
||||||
|
|
|
@ -166,7 +166,7 @@ Evolution_PartyMonLoop: ; loop over party mons
|
||||||
ld de, W_MONHEADER
|
ld de, W_MONHEADER
|
||||||
call CopyData
|
call CopyData
|
||||||
ld a, [wd0b5]
|
ld a, [wd0b5]
|
||||||
ld [W_MONHDEXNUM], a
|
ld [W_MONHINDEX], a
|
||||||
pop af
|
pop af
|
||||||
ld [wd11e], a
|
ld [wd11e], a
|
||||||
ld hl, wLoadedMonHPExp - 1
|
ld hl, wLoadedMonHPExp - 1
|
||||||
|
@ -257,12 +257,12 @@ Evolution_PartyMonLoop: ; loop over party mons
|
||||||
call nz, PlayDefaultMusic
|
call nz, PlayDefaultMusic
|
||||||
ret
|
ret
|
||||||
|
|
||||||
; checks if the evolved mon's name is different from the standard name (i.e. it has a nickname)
|
|
||||||
; if so, rename it to is evolved form's standard name
|
|
||||||
RenameEvolvedMon: ; 3aef7 (e:6ef7)
|
RenameEvolvedMon: ; 3aef7 (e:6ef7)
|
||||||
|
; Renames the mon to its new, evolved form's standard name unless it had a
|
||||||
|
; nickname, in which case the nickname is kept.
|
||||||
ld a, [wd0b5]
|
ld a, [wd0b5]
|
||||||
push af
|
push af
|
||||||
ld a, [W_MONHDEXNUM]
|
ld a, [W_MONHINDEX]
|
||||||
ld [wd0b5], a
|
ld [wd0b5], a
|
||||||
call GetName
|
call GetName
|
||||||
pop af
|
pop af
|
||||||
|
@ -275,7 +275,7 @@ RenameEvolvedMon: ; 3aef7 (e:6ef7)
|
||||||
cp [hl]
|
cp [hl]
|
||||||
inc hl
|
inc hl
|
||||||
ret nz
|
ret nz
|
||||||
cp $50
|
cp "@"
|
||||||
jr nz, .compareNamesLoop
|
jr nz, .compareNamesLoop
|
||||||
ld a, [wWhichPokemon]
|
ld a, [wWhichPokemon]
|
||||||
ld bc, 11
|
ld bc, 11
|
||||||
|
|
|
@ -2,7 +2,7 @@ PrintNotebookText: ; 52996 (14:6996)
|
||||||
call EnableAutoTextBoxDrawing
|
call EnableAutoTextBoxDrawing
|
||||||
ld a, $1
|
ld a, $1
|
||||||
ld [wDoNotWaitForButtonPressAfterDisplayingText], a
|
ld [wDoNotWaitForButtonPressAfterDisplayingText], a
|
||||||
ld a, [wTrainerSpriteOffset]
|
ld a, [wHiddenObjectFunctionArgument]
|
||||||
jp PrintPredefTextID
|
jp PrintPredefTextID
|
||||||
|
|
||||||
TMNotebook: ; 529a4 (14:69a4)
|
TMNotebook: ; 529a4 (14:69a4)
|
||||||
|
|
|
@ -138,7 +138,7 @@ StatusScreen: ; 12953 (4:6953)
|
||||||
call PlaceString ; "STATUS/"
|
call PlaceString ; "STATUS/"
|
||||||
coord hl, 14, 2
|
coord hl, 14, 2
|
||||||
call PrintLevel ; Pokémon level
|
call PrintLevel ; Pokémon level
|
||||||
ld a, [W_MONHDEXNUM]
|
ld a, [W_MONHINDEX]
|
||||||
ld [wd11e], a
|
ld [wd11e], a
|
||||||
ld [wd0b5], a
|
ld [wd0b5], a
|
||||||
predef IndexToPokedex
|
predef IndexToPokedex
|
||||||
|
@ -416,7 +416,7 @@ StatusScreen2: ; 12b57 (4:6b57)
|
||||||
call StatusScreen_ClearName
|
call StatusScreen_ClearName
|
||||||
coord hl, 9, 1
|
coord hl, 9, 1
|
||||||
call StatusScreen_ClearName
|
call StatusScreen_ClearName
|
||||||
ld a, [W_MONHDEXNUM]
|
ld a, [W_MONHINDEX]
|
||||||
ld [wd11e], a
|
ld [wd11e], a
|
||||||
call GetMonName
|
call GetMonName
|
||||||
coord hl, 9, 1
|
coord hl, 9, 1
|
||||||
|
|
12
home.asm
12
home.asm
|
@ -240,7 +240,7 @@ DrawHPBar:: ; 1336 (0:1336)
|
||||||
|
|
||||||
|
|
||||||
; loads pokemon data from one of multiple sources to wLoadedMon
|
; loads pokemon data from one of multiple sources to wLoadedMon
|
||||||
; loads base stats to W_MONHDEXNUM
|
; loads base stats to W_MONHEADER
|
||||||
; INPUT:
|
; INPUT:
|
||||||
; [wWhichPokemon] = index of pokemon within party/box
|
; [wWhichPokemon] = index of pokemon within party/box
|
||||||
; [wMonDataLocation] = source
|
; [wMonDataLocation] = source
|
||||||
|
@ -251,7 +251,7 @@ DrawHPBar:: ; 1336 (0:1336)
|
||||||
; OUTPUT:
|
; OUTPUT:
|
||||||
; [wcf91] = pokemon ID
|
; [wcf91] = pokemon ID
|
||||||
; wLoadedMon = base address of pokemon data
|
; wLoadedMon = base address of pokemon data
|
||||||
; W_MONHDEXNUM = base address of base stats
|
; W_MONHEADER = base address of base stats
|
||||||
LoadMonData:: ; 1372 (0:1372)
|
LoadMonData:: ; 1372 (0:1372)
|
||||||
jpab LoadMonData_
|
jpab LoadMonData_
|
||||||
|
|
||||||
|
@ -551,7 +551,7 @@ GetwMoves:: ; 152e (0:152e)
|
||||||
ld a,[hl]
|
ld a,[hl]
|
||||||
ret
|
ret
|
||||||
|
|
||||||
; copies the base stat data of a pokemon to W_MONHDEXNUM (W_MONHEADER)
|
; copies the base stat data of a pokemon to W_MONHEADER
|
||||||
; INPUT:
|
; INPUT:
|
||||||
; [wd0b5] = pokemon ID
|
; [wd0b5] = pokemon ID
|
||||||
GetMonHeader:: ; 1537 (0:1537)
|
GetMonHeader:: ; 1537 (0:1537)
|
||||||
|
@ -606,7 +606,7 @@ GetMonHeader:: ; 1537 (0:1537)
|
||||||
call FarCopyData
|
call FarCopyData
|
||||||
.done
|
.done
|
||||||
ld a,[wd0b5]
|
ld a,[wd0b5]
|
||||||
ld [W_MONHDEXNUM],a
|
ld [W_MONHINDEX],a
|
||||||
pop af
|
pop af
|
||||||
ld [wd11e],a
|
ld [wd11e],a
|
||||||
pop hl
|
pop hl
|
||||||
|
@ -3313,9 +3313,9 @@ GetName:: ; 376b (0:376b)
|
||||||
call CopyData
|
call CopyData
|
||||||
.gotPtr
|
.gotPtr
|
||||||
ld a,e
|
ld a,e
|
||||||
ld [wcf8d],a
|
ld [wUnusedCF8D],a
|
||||||
ld a,d
|
ld a,d
|
||||||
ld [wcf8e],a
|
ld [wUnusedCF8D + 1],a
|
||||||
pop de
|
pop de
|
||||||
pop bc
|
pop bc
|
||||||
pop hl
|
pop hl
|
||||||
|
|
4
main.asm
4
main.asm
|
@ -86,7 +86,7 @@ LoadMonData_:
|
||||||
; 2: boxmon
|
; 2: boxmon
|
||||||
; 3: daycaremon
|
; 3: daycaremon
|
||||||
; Return monster id at wcf91 and its data at wLoadedMon.
|
; Return monster id at wcf91 and its data at wLoadedMon.
|
||||||
; Also load base stats at W_MONHDEXNUM for convenience.
|
; Also load base stats at W_MONHEADER for convenience.
|
||||||
|
|
||||||
ld a, [wDayCareMonSpecies]
|
ld a, [wDayCareMonSpecies]
|
||||||
ld [wcf91], a
|
ld [wcf91], a
|
||||||
|
@ -284,7 +284,7 @@ DetectCollisionBetweenSprites:
|
||||||
ld [hld], a ; zero [$c1ic] (directions in which collisions occurred)
|
ld [hld], a ; zero [$c1ic] (directions in which collisions occurred)
|
||||||
|
|
||||||
ld a, [$ff91]
|
ld a, [$ff91]
|
||||||
ld [hld], a ; [$c1ib] = adjusted X coordiate
|
ld [hld], a ; [$c1ib] = adjusted X coordinate
|
||||||
ld a, [$ff90]
|
ld a, [$ff90]
|
||||||
ld [hl], a ; [$c1ia] = adjusted Y coordinate
|
ld [hl], a ; [$c1ia] = adjusted Y coordinate
|
||||||
|
|
||||||
|
|
11
wram.asm
11
wram.asm
|
@ -1226,8 +1226,10 @@ wItemList:: ; cf7b
|
||||||
wListPointer:: ; cf8b
|
wListPointer:: ; cf8b
|
||||||
ds 2
|
ds 2
|
||||||
|
|
||||||
wcf8d:: ds 1 ; used in GetMonName
|
wUnusedCF8D:: ; cf8d
|
||||||
wcf8e:: ds 1 ; also used in GetMonName (probably as a pointer)
|
; 2 bytes
|
||||||
|
; used to store pointers, but never read
|
||||||
|
ds 2
|
||||||
|
|
||||||
wItemPrices:: ; cf8f
|
wItemPrices:: ; cf8f
|
||||||
ds 2
|
ds 2
|
||||||
|
@ -1789,7 +1791,10 @@ wPredefBank:: ; d0b7
|
||||||
ds 1
|
ds 1
|
||||||
|
|
||||||
W_MONHEADER:: ; d0b8
|
W_MONHEADER:: ; d0b8
|
||||||
W_MONHDEXNUM:: ; d0b8
|
|
||||||
|
W_MONHINDEX:: ; d0b8
|
||||||
|
; In the ROM base stats data stucture, this is the dex number, but it is
|
||||||
|
; overwritten with the internal index number after the header is copied to WRAM.
|
||||||
ds 1
|
ds 1
|
||||||
|
|
||||||
W_MONHBASESTATS:: ; d0b9
|
W_MONHBASESTATS:: ; d0b9
|
||||||
|
|
Loading…
Reference in a new issue