Blind wram labels part 3.

This commit is contained in:
yenatch 2015-02-10 15:14:21 -08:00
parent 80b0d8cd2d
commit 62b473d6c6
8 changed files with 340 additions and 294 deletions

View File

@ -685,7 +685,7 @@ BattleAnimCmd_D5: ; cc485 (33:4485)
ld a, [BattleAnimByte] ld a, [BattleAnimByte]
and $f and $f
ld c, a ld c, a
ld hl, wd300 ld hl, w5_d300
xor a xor a
ld [BattleAnimTemps], a ld [BattleAnimTemps], a
.asm_cc492 .asm_cc492
@ -792,7 +792,7 @@ BattleAnimCmd_D7: ; cc506 (33:4506)
BattleAnimCmd_D9: ; cc52c (33:452c) BattleAnimCmd_D9: ; cc52c (33:452c)
ld hl, wd300 ld hl, w5_d300
.asm_cc52f .asm_cc52f
ld a, [hl] ld a, [hl]
and a and a
@ -847,7 +847,7 @@ Functioncc561: ; cc561 (33:4561)
BattleAnimCmd_DA: ; cc57e (33:457e) BattleAnimCmd_DA: ; cc57e (33:457e)
ld hl, wd300 ld hl, w5_d300
.asm_cc581 .asm_cc581
ld a, [hl] ld a, [hl]
and a and a
@ -1470,7 +1470,7 @@ Functioncc94b: ; cc94b
Functioncc96e: ; cc96e Functioncc96e: ; cc96e
ld a, $0 ld a, $0
ld [wd418], a ld [w5_d418], a
ld hl, OTPartyMon3HP ld hl, OTPartyMon3HP
ld e, $a ld e, $a
.asm_cc978 .asm_cc978
@ -1492,7 +1492,7 @@ Functioncc96e: ; cc96e
add hl, bc add hl, bc
dec e dec e
jr nz, .asm_cc978 jr nz, .asm_cc978
ld a, [wd418] ld a, [w5_d418]
ld l, a ld l, a
ld h, $c4 ld h, $c4
.asm_cc997 .asm_cc997

View File

@ -17,7 +17,7 @@ Functioncc9a1: ; cc9a1 (33:49a1)
.asm_cc9b3 .asm_cc9b3
ld c, l ld c, l
ld b, h ld b, h
ld hl, wd40e ld hl, w5_d40e
inc [hl] inc [hl]
call Functioncc9c4 call Functioncc9c4
ret ret
@ -46,7 +46,7 @@ Functioncc9c4: ; cc9c4 (33:49c4)
ld d, h ld d, h
ld hl, $0 ld hl, $0
add hl, bc add hl, bc
ld a, [wd40e] ld a, [w5_d40e]
ld [hli], a ld [hli], a
ld a, [de] ld a, [de]
inc de inc de
@ -111,7 +111,7 @@ Functioncca09: ; cca09
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
ld a, [wd418] ld a, [w5_d418]
ld e, a ld e, a
ld d, $c4 ld d, $c4
.asm_cca3c .asm_cca3c
@ -178,7 +178,7 @@ Functioncca09: ; cca09
inc hl inc hl
inc de inc de
ld a, e ld a, e
ld [wd418], a ld [w5_d418], a
cp $a0 cp $a0
jr nc, .asm_ccaa7 jr nc, .asm_ccaa7
dec c dec c
@ -287,7 +287,7 @@ Functionccaaa: ; ccaaa
Functionccb31: ; ccb31 (33:4b31) Functionccb31: ; ccb31 (33:4b31)
push hl push hl
push bc push bc
ld hl, wd300 ld hl, w5_d300
ld b, a ld b, a
ld c, $5 ld c, $5
.asm_ccb39 .asm_ccb39

View File

@ -399,7 +399,7 @@ Jumptable_c8217: ; c8217 (32:4217)
Functionc8223: ; c8223 (32:4223) Functionc8223: ; c8223 (32:4223)
call Functionc9042 call Functionc9042
jr z, .asm_c8230 jr z, .asm_c8230
ld hl, wd40e ld hl, w5_d40e
inc [hl] inc [hl]
call EndBattleBGEffect call EndBattleBGEffect
ret ret
@ -465,7 +465,7 @@ Jumptable_c8284: ; c8284 (32:4284)
Functionc8290: ; c8290 (32:4290) Functionc8290: ; c8290 (32:4290)
call Functionc9042 call Functionc9042
jr z, .asm_c829d jr z, .asm_c829d
ld hl, wd40e ld hl, w5_d40e
inc [hl] inc [hl]
call EndBattleBGEffect call EndBattleBGEffect
ret ret
@ -912,8 +912,8 @@ Functionc8561: ; c8561 (32:4561)
ret ret
Functionc8565: ; c8565 (32:4565) Functionc8565: ; c8565 (32:4565)
ld hl, wd422 ld hl, w5_d422
ld de, wd422 + 1 ld de, w5_d422 + 1
ld c, $3f ld c, $3f
ld a, [hl] ld a, [hl]
push af push af
@ -926,7 +926,7 @@ Functionc8565: ; c8565 (32:4565)
pop af pop af
ld [hl], a ld [hl], a
ld de, LYOverridesBackup ld de, LYOverridesBackup
ld hl, wd422 ld hl, w5_d422
ld bc, $0 ld bc, $0
.asm_c8580 .asm_c8580
ld a, [$ffc7] ld a, [$ffc7]
@ -2749,7 +2749,7 @@ Functionc8f69: ; c8f69 (32:4f69)
ld [BattleAnimTemps + 2], a ld [BattleAnimTemps + 2], a
ld a, $40 ld a, $40
ld [BattleAnimTemps + 3], a ld [BattleAnimTemps + 3], a
ld bc, wd422 ld bc, w5_d422
.asm_c8f7e .asm_c8f7e
ld a, [BattleAnimTemps + 2] ld a, [BattleAnimTemps + 2]
ld d, a ld d, a

View File

@ -3118,7 +3118,7 @@ UnknownScript_0xbe675:: ; 0xbe675
playrammusic playrammusic
showemote $0, $fe, 30 showemote $0, $fe, 30
callasm Function831e callasm Function831e
applymovement2 $d007 applymovement2 MovementBuffer
writepersonxy $fe writepersonxy $fe
faceperson $0, $fe faceperson $0, $fe
jump UnknownScript_0xbe68a jump UnknownScript_0xbe68a
@ -3133,7 +3133,7 @@ UnknownScript_0xbe68a: ; 0xbe68a
startbattle startbattle
returnafterbattle returnafterbattle
trainerstatus $1 trainerstatus $1
loadvar $d04d, $ff loadvar wd04d, $ff
UnknownScript_0xbe698: UnknownScript_0xbe698:
scripttalkafter scripttalkafter

View File

@ -316,11 +316,11 @@ Script_jumptextfaceplayer: ; 0x96e45
; text_pointer (RawTextPointerLabelParam) ; text_pointer (RawTextPointerLabelParam)
ld a, [ScriptBank] ld a, [ScriptBank]
ld [$d44e], a ld [wd44e], a
call GetScriptByte call GetScriptByte
ld [$d44f], a ld [wd44f], a
call GetScriptByte call GetScriptByte
ld [$d450], a ld [wd450], a
ld b, BANK(JumpTextFacePlayerScript) ld b, BANK(JumpTextFacePlayerScript)
ld hl, JumpTextFacePlayerScript ld hl, JumpTextFacePlayerScript
jp ScriptJump jp ScriptJump
@ -332,11 +332,11 @@ Script_jumptext: ; 0x96e5f
; text_pointer (RawTextPointerLabelParam) ; text_pointer (RawTextPointerLabelParam)
ld a, [ScriptBank] ld a, [ScriptBank]
ld [$d44e], a ld [wd44e], a
call GetScriptByte call GetScriptByte
ld [$d44f], a ld [wd44f], a
call GetScriptByte call GetScriptByte
ld [$d450], a ld [wd450], a
ld b, BANK(JumpTextScript) ld b, BANK(JumpTextScript)
ld hl, JumpTextScript ld hl, JumpTextScript
jp ScriptJump jp ScriptJump
@ -361,11 +361,11 @@ Script_3jumptext: ; 0x96e81
; text_pointer (PointerLabelBeforeBank) ; text_pointer (PointerLabelBeforeBank)
call GetScriptByte call GetScriptByte
ld [$d44e], a ld [wd44e], a
call GetScriptByte call GetScriptByte
ld [$d44f], a ld [wd44f], a
call GetScriptByte call GetScriptByte
ld [$d450], a ld [wd450], a
ld b, BANK(JumpTextScript) ld b, BANK(JumpTextScript)
ld hl, JumpTextScript ld hl, JumpTextScript
jp ScriptJump jp ScriptJump
@ -419,7 +419,7 @@ Script_repeattext: ; 0x96ebb
ld a, l ld a, l
cp $ff cp $ff
jr nz, .asm_96ed8 ; 0x96eca $c jr nz, .asm_96ed8 ; 0x96eca $c
ld hl, $d44e ld hl, wd44e
ld a, [hli] ld a, [hli]
ld b, a ld b, a
ld a, [hli] ld a, [hli]
@ -515,7 +515,7 @@ Script_interpretmenu2: ; 0x96f30
ld a, [ScriptBank] ld a, [ScriptBank]
ld hl, Function1d81 ld hl, Function1d81
rst FarCall rst FarCall
ld a, [$cfa9] ld a, [wcfa9]
jr nc, .ok jr nc, .ok
xor a xor a
.ok .ok
@ -529,7 +529,7 @@ Script_interpretmenu: ; 0x96f41
ld a, [ScriptBank] ld a, [ScriptBank]
ld hl, Function202a ld hl, Function202a
rst FarCall rst FarCall
ld a, [$cf88] ld a, [wcf88]
jr nc, .ok jr nc, .ok
xor a xor a
.ok .ok
@ -608,7 +608,7 @@ Script_verbosegiveitem2: ; 0x96f8e
call GetScriptByte call GetScriptByte
call Function9769e call Function9769e
ld a, [de] ld a, [de]
ld [$d10c], a ld [wd10c], a
ld hl, NumItems ld hl, NumItems
call ReceiveItem call ReceiveItem
ld a, $1 ld a, $1
@ -651,7 +651,7 @@ Script_specialsound: ; 0x96fe4
; script command 0x88 ; script command 0x88
callba CheckItemPocket callba CheckItemPocket
ld a, [$d142] ld a, [wd142]
cp TM_HM cp TM_HM
ld de, SFX_GET_TM ld de, SFX_GET_TM
jr z, .play jr z, .play
@ -665,7 +665,7 @@ Script_specialsound: ; 0x96fe4
GetPocketName: ; 96ffe GetPocketName: ; 96ffe
callba CheckItemPocket callba CheckItemPocket
ld a, [$d142] ld a, [wd142]
dec a dec a
ld hl, .Pockets ld hl, .Pockets
and 3 and 3
@ -698,7 +698,7 @@ GetPocketName: ; 96ffe
CurItemName: ; 97051 CurItemName: ; 97051
ld a, [CurItem] ld a, [CurItem]
ld [$d265], a ld [wd265], a
call GetItemName call GetItemName
ret ret
; 9705b ; 9705b
@ -860,13 +860,13 @@ Script_trainertext: ; 0x9710f
call GetScriptByte call GetScriptByte
ld c, a ld c, a
ld b, $0 ld b, $0
ld hl, $d045 ld hl, WalkingX
add hl, bc add hl, bc
add hl, bc add hl, bc
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
ld a, [$d03e] ld a, [EngineBuffer1]
ld b, a ld b, a
call Function269a call Function269a
ret ret
@ -875,11 +875,11 @@ Script_trainertext: ; 0x9710f
Script_scripttalkafter: ; 0x97125 Script_scripttalkafter: ; 0x97125
; script command 0x65 ; script command 0x65
ld hl, $d04b ld hl, wd04b
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
ld a, [$d03e] ld a, [EngineBuffer1]
ld b, a ld b, a
jp ScriptJump jp ScriptJump
; 0x97132 ; 0x97132
@ -891,7 +891,7 @@ Script_trainerstatus: ; 0x97132
xor a xor a
ld [ScriptVar], a ld [ScriptVar], a
ld hl, $d041 ld hl, wd041
ld e, [hl] ld e, [hl]
inc hl inc hl
ld d, [hl] ld d, [hl]
@ -912,12 +912,12 @@ Script_winlosstext: ; 0x9714c
; win_text_pointer (TextPointerLabelParam) ; win_text_pointer (TextPointerLabelParam)
; loss_text_pointer (TextPointerLabelParam) ; loss_text_pointer (TextPointerLabelParam)
ld hl, $d047 ld hl, WalkingTile
call GetScriptByte call GetScriptByte
ld [hli], a ld [hli], a
call GetScriptByte call GetScriptByte
ld [hli], a ld [hli], a
ld hl, $d049 ld hl, wd048 + 1
call GetScriptByte call GetScriptByte
ld [hli], a ld [hli], a
call GetScriptByte call GetScriptByte
@ -928,7 +928,7 @@ Script_winlosstext: ; 0x9714c
Script_talkaftercancel: ; 0x97163 Script_talkaftercancel: ; 0x97163
; script command 0x66 ; script command 0x66
ld a, [$d04d] ld a, [wd04d]
and a and a
ret z ret z
jp Script_end jp Script_end
@ -939,7 +939,7 @@ Script_talkaftercheck: ; 0x9716b
ld a, $1 ld a, $1
ld [ScriptVar], a ld [ScriptVar], a
ld a, [$d04d] ld a, [wd04d]
and a and a
ret nz ret nz
xor a xor a
@ -950,7 +950,7 @@ Script_talkaftercheck: ; 0x9716b
Script_playrammusic: ; 0x9717a Script_playrammusic: ; 0x9717a
; script command 0x80 ; script command 0x80
ld a, [$d22f] ld a, [OtherTrainerClass]
ld e, a ld e, a
callba PlayTrainerEncounterMusic callba PlayTrainerEncounterMusic
ret ret
@ -971,7 +971,7 @@ Script_playmusic: ; 0x97189
ld de, MUSIC_NONE ld de, MUSIC_NONE
call PlayMusic call PlayMusic
xor a xor a
ld [$c2a7], a ld [MusicFade], a
call MaxVolume call MaxVolume
call GetScriptByte call GetScriptByte
ld e, a ld e, a
@ -993,7 +993,7 @@ Script_musicfadeout: ; 0x971a2
ld [MusicFadeID + 1], a ld [MusicFadeID + 1], a
call GetScriptByte call GetScriptByte
and $7f and $7f
ld [$c2a7], a ld [MusicFade], a
ret ret
; 0x971b7 ; 0x971b7
@ -1203,7 +1203,7 @@ Function9728b: ; 0x9728b
pop de pop de
ld a, e ld a, e
call Function1af8 call Function1af8
ld hl, $d0ed ld hl, VramState
bit 6, [hl] bit 6, [hl]
jr nz, .asm_972b5 ; 0x972b0 $3 jr nz, .asm_972b5 ; 0x972b0 $3
call Function972bc call Function972bc
@ -1239,7 +1239,7 @@ Script_variablesprite: ; 0x972ce
call GetScriptByte call GetScriptByte
ld e, a ld e, a
ld d, $0 ld d, $0
ld hl, $d82e ld hl, VariableSprites
add hl, de add hl, de
call GetScriptByte call GetScriptByte
ld [hl], a ld [hl], a
@ -1437,20 +1437,20 @@ Script_earthquake: ; 0x973c7
; param (DecimalParam) ; param (DecimalParam)
ld hl, EarthquakeMovement ld hl, EarthquakeMovement
ld de, $d002 ld de, wd002
ld bc, EarthquakeMovementEnd - EarthquakeMovement ld bc, EarthquakeMovementEnd - EarthquakeMovement
call CopyBytes call CopyBytes
call GetScriptByte call GetScriptByte
ld [$d003], a ld [wd003], a
and $3f and $3f
ld [$d005], a ld [wd005], a
ld b, BANK(UnknownScript_0x973e6) ld b, BANK(UnknownScript_0x973e6)
ld de, UnknownScript_0x973e6 ld de, UnknownScript_0x973e6
jp ScriptCall jp ScriptCall
; 0x973e6 ; 0x973e6
UnknownScript_0x973e6: ; 973e6 UnknownScript_0x973e6: ; 973e6
applymovement $0, $d002 applymovement $0, wd002
end end
; 973eb ; 973eb
@ -1466,7 +1466,7 @@ Script_loadpikachudata: ; 0x973f0
; script command 0x5a ; script command 0x5a
ld a, $19 ld a, $19
ld [$d22e], a ld [wd22e], a
ld a, $5 ld a, $5
ld [CurPartyLevel], a ld [CurPartyLevel], a
ret ret
@ -1476,7 +1476,7 @@ Script_battlecheck: ; 0x973fb
; script command 0x5b ; script command 0x5b
xor a xor a
ld [$d459], a ld [wd459], a
ret ret
; 0x97400 ; 0x97400
@ -1484,11 +1484,11 @@ Script_loadtrainerdata: ; 0x97400
; script command 0x5c ; script command 0x5c
ld a, $81 ld a, $81
ld [$d459], a ld [wd459], a
ld a, [$d043] ld a, [WalkingDirection]
ld [$d22f], a ld [OtherTrainerClass], a
ld a, [$d044] ld a, [FacingDirection]
ld [$d231], a ld [OtherTrainerID], a
ret ret
; 0x97412 ; 0x97412
@ -1499,9 +1499,9 @@ Script_loadpokedata: ; 0x97412
; level (DecimalParam) ; level (DecimalParam)
ld a, $80 ld a, $80
ld [$d459], a ld [wd459], a
call GetScriptByte call GetScriptByte
ld [$d22e], a ld [wd22e], a
call GetScriptByte call GetScriptByte
ld [CurPartyLevel], a ld [CurPartyLevel], a
ret ret
@ -1514,11 +1514,11 @@ Script_loadtrainer: ; 0x97424
; trainer_id (TrainerIdParam) ; trainer_id (TrainerIdParam)
ld a, $81 ld a, $81
ld [$d459], a ld [wd459], a
call GetScriptByte call GetScriptByte
ld [$d22f], a ld [OtherTrainerClass], a
call GetScriptByte call GetScriptByte
ld [$d231], a ld [OtherTrainerID], a
ret ret
; 0x97436 ; 0x97436
@ -1527,7 +1527,7 @@ Script_startbattle: ; 0x97436
call Function2879 call Function2879
predef StartBattle predef StartBattle
ld a, [$d0ee] ld a, [wd0ee]
and $3f and $3f
ld [ScriptVar], a ld [ScriptVar], a
ret ret
@ -1548,10 +1548,10 @@ Script_catchtutorial: ; 0x97447
Script_returnafterbattle: ; 0x97459 Script_returnafterbattle: ; 0x97459
; script command 0x60 ; script command 0x60
ld hl, $d459 ld hl, wd459
ld d, [hl] ld d, [hl]
ld [hl], $0 ld [hl], $0
ld a, [$d0ee] ld a, [wd0ee]
and $3f and $3f
cp $1 cp $1
jr nz, .asm_97470 ; 0x97466 $8 jr nz, .asm_97470 ; 0x97466 $8
@ -1564,7 +1564,7 @@ Script_returnafterbattle: ; 0x97459
callba Functionfcfec callba Functionfcfec
jr .asm_9748e ; 0x9747a $12 jr .asm_9748e ; 0x9747a $12
.asm_9747c .asm_9747c
ld a, [$d0ee] ld a, [wd0ee]
bit 7, a bit 7, a
jr z, .asm_9748e ; 0x97481 $b jr z, .asm_9748e ; 0x97481 $b
ld b, BANK(UnknownScript_0x90255) ld b, BANK(UnknownScript_0x90255)
@ -1578,7 +1578,7 @@ Script_reloadmap: ; 0x97491
; script command 0x7b ; script command 0x7b
xor a xor a
ld [$d459], a ld [wd459], a
ld a, $f3 ld a, $f3
ld [$ff9f], a ld [$ff9f], a
ld a, $1 ld a, $1
@ -1633,11 +1633,11 @@ Script_2ptcall: ; 0x974be
ScriptCall: ; 0x974cb ScriptCall: ; 0x974cb
push de push de
ld hl, $d43c ld hl, wd43c
ld e, [hl] ld e, [hl]
inc [hl] inc [hl]
ld d, $0 ld d, $0
ld hl, $d43d ld hl, wd43d
add hl, de add hl, de
add hl, de add hl, de
add hl, de add hl, de
@ -1845,11 +1845,11 @@ Script_priorityjump: ; 0x975aa
; pointer (ScriptPointerLabelParam) ; pointer (ScriptPointerLabelParam)
ld a, [ScriptBank] ld a, [ScriptBank]
ld [$d44e], a ld [wd44e], a
call GetScriptByte call GetScriptByte
ld [$d44f], a ld [wd44f], a
call GetScriptByte call GetScriptByte
ld [$d450], a ld [wd450], a
ld hl, ScriptFlags ld hl, ScriptFlags
set 3, [hl] set 3, [hl]
ret ret
@ -1896,9 +1896,9 @@ Script_dotrigger: ; 0x975eb
; parameters: ; parameters:
; trigger_id (SingleByteParam) ; trigger_id (SingleByteParam)
ld a, [$dcb5] ld a, [MapGroup]
ld b, a ld b, a
ld a, [$dcb6] ld a, [MapNumber]
ld c, a ld c, a
jr Unknown_975fd ; 0x975f3 $8 jr Unknown_975fd ; 0x975f3 $8
; 0x975f5 ; 0x975f5
@ -2111,7 +2111,7 @@ Script_pokenamemem: ; 0x976ae
jr nz, .asm_976b7 ; 0x976b2 $3 jr nz, .asm_976b7 ; 0x976b2 $3
ld a, [ScriptVar] ld a, [ScriptVar]
.asm_976b7 .asm_976b7
ld [$d265], a ld [wd265], a
call GetPokemonName call GetPokemonName
ld de, StringBuffer1 ld de, StringBuffer1
@ -2141,7 +2141,7 @@ Script_itemtotext: ; 0x976d5
jr nz, .asm_976de ; 0x976d9 $3 jr nz, .asm_976de ; 0x976d9 $3
ld a, [ScriptVar] ld a, [ScriptVar]
.asm_976de .asm_976de
ld [$d265], a ld [wd265], a
call GetItemName call GetItemName
ld de, StringBuffer1 ld de, StringBuffer1
jr Unknown_976c0 ; 0x976e7 $d7 jr Unknown_976c0 ; 0x976e7 $d7
@ -2152,9 +2152,9 @@ Script_mapnametotext: ; 0x976e9
; parameters: ; parameters:
; memory (SingleByteParam) ; memory (SingleByteParam)
ld a, [$dcb5] ld a, [MapGroup]
ld b, a ld b, a
ld a, [$dcb6] ld a, [MapNumber]
ld c, a ld c, a
call GetWorldMapLocation call GetWorldMapLocation
@ -2198,11 +2198,11 @@ Script_name: ; 0x97716
; memory (SingleByteParam) ; memory (SingleByteParam)
call GetScriptByte call GetScriptByte
ld [$cf61], a ld [wcf61], a
Unknown_9771c: ; 0x9771c Unknown_9771c: ; 0x9771c
call GetScriptByte call GetScriptByte
ld [$cf60], a ld [CurSpecies], a
call GetName call GetName
ld de, StringBuffer1 ld de, StringBuffer1
jp Unknown_976c0 jp Unknown_976c0
@ -2215,7 +2215,7 @@ Script_trainerclassname: ; 0x9772b
; memory (SingleByteParam) ; memory (SingleByteParam)
ld a, $7 ld a, $7
ld [$cf61], a ld [wcf61], a
jr Unknown_9771c ; 0x97730 $ea jr Unknown_9771c ; 0x97730 $ea
; 0x97732 ; 0x97732
@ -2302,7 +2302,7 @@ Script_givepokeitem: ; 0x97792
push bc push bc
inc hl inc hl
ld bc, $0020 ld bc, $0020
ld de, $d002 ld de, wd002
ld a, [ScriptBank] ld a, [ScriptBank]
call FarCopyBytes call FarCopyBytes
pop bc pop bc
@ -2338,7 +2338,7 @@ Script_giveitem: ; 0x977ca
.asm_977d4 .asm_977d4
ld [CurItem], a ld [CurItem], a
call GetScriptByte call GetScriptByte
ld [$d10c], a ld [wd10c], a
ld hl, NumItems ld hl, NumItems
call ReceiveItem call ReceiveItem
jr nc, .asm_977eb ; 0x977e3 $6 jr nc, .asm_977eb ; 0x977e3 $6
@ -2362,9 +2362,9 @@ Script_takeitem: ; 0x977f0
call GetScriptByte call GetScriptByte
ld [CurItem], a ld [CurItem], a
call GetScriptByte call GetScriptByte
ld [$d10c], a ld [wd10c], a
ld a, $ff ld a, $ff
ld [$d107], a ld [wd107], a
ld hl, NumItems ld hl, NumItems
call TossItem call TossItem
ret nc ret nc
@ -2443,9 +2443,9 @@ Unknown_9784f: ; 0x9784f
Function97861: ; 0x97861 Function97861: ; 0x97861
call GetScriptByte call GetScriptByte
and a and a
ld de, $d84e ld de, Money
ret z ret z
ld de, $d851 ld de, wMomsMoney
ret ret
; 0x9786d ; 0x9786d
@ -2590,16 +2590,16 @@ Script_specialphonecall: ; 0x97919
; call_id (MultiByteParam) ; call_id (MultiByteParam)
call GetScriptByte call GetScriptByte
ld [$dc31], a ld [wdc31], a
call GetScriptByte call GetScriptByte
ld [$dc32], a ld [wdc31 + 1], a
ret ret
; 0x97926 ; 0x97926
Script_checkphonecall: ; 0x97926 Script_checkphonecall: ; 0x97926
; script command 0x9d ; script command 0x9d
ld a, [$dc31] ld a, [wdc31]
and a and a
jr z, .ok jr z, .ok
ld a, 1 ld a, 1
@ -2651,7 +2651,7 @@ Script_giveegg: ; 0x97968
xor a xor a
ld [ScriptVar], a ld [ScriptVar], a
ld [$cf5f], a ld [MonType], a
call GetScriptByte call GetScriptByte
ld [CurPartySpecies], a ld [CurPartySpecies], a
call GetScriptByte call GetScriptByte
@ -2786,9 +2786,9 @@ Script_xycompare: ; 0x97a01
; pointer (MultiByteParam) ; pointer (MultiByteParam)
call GetScriptByte call GetScriptByte
ld [$d453], a ld [wd453], a
call GetScriptByte call GetScriptByte
ld [$d454], a ld [wd454], a
ret ret
; 0x97a0e ; 0x97a0e
@ -2804,10 +2804,10 @@ Script_warpfacing: ; 0x97a0e
call GetScriptByte call GetScriptByte
and $3 and $3
ld c, a ld c, a
ld a, [$d45b] ld a, [wd45b]
set 5, a set 5, a
or c or c
ld [$d45b], a ld [wd45b], a
; 0x97a1d ; 0x97a1d
Script_warp: ; 0x97a1d Script_warp: ; 0x97a1d
@ -2821,15 +2821,15 @@ Script_warp: ; 0x97a1d
call GetScriptByte call GetScriptByte
and a and a
jr z, .asm_97a4a ; 0x97a21 $27 jr z, .asm_97a4a ; 0x97a21 $27
ld [$dcb5], a ld [MapGroup], a
call GetScriptByte call GetScriptByte
ld [$dcb6], a ld [MapNumber], a
call GetScriptByte call GetScriptByte
ld [$dcb8], a ld [XCoord], a
call GetScriptByte call GetScriptByte
ld [$dcb7], a ld [YCoord], a
ld a, $ff ld a, $ff
ld [$d001], a ld [wd001], a
ld a, $f1 ld a, $f1
ld [$ff9f], a ld [$ff9f], a
ld a, $1 ld a, $1
@ -2841,7 +2841,7 @@ Script_warp: ; 0x97a1d
call GetScriptByte call GetScriptByte
call GetScriptByte call GetScriptByte
ld a, $ff ld a, $ff
ld [$d001], a ld [wd001], a
ld a, $fb ld a, $fb
ld [$ff9f], a ld [$ff9f], a
ld a, $1 ld a, $1
@ -2858,11 +2858,11 @@ Script_warpmod: ; 0x97a65
; map_id (MapIdParam) ; map_id (MapIdParam)
call GetScriptByte call GetScriptByte
ld [$dcac], a ld [wdcac], a
call GetScriptByte call GetScriptByte
ld [$dcad], a ld [BackupMapGroup], a
call GetScriptByte call GetScriptByte
ld [$dcae], a ld [BackupMapNumber], a
ret ret
; 0x97a78 ; 0x97a78
@ -2873,9 +2873,9 @@ Script_blackoutmod: ; 0x97a78
; map_id (MapIdParam) ; map_id (MapIdParam)
call GetScriptByte call GetScriptByte
ld [$dcb2], a ld [wdcb2], a
call GetScriptByte call GetScriptByte
ld [$dcb3], a ld [wdcb3], a
ret ret
; 0x97a85 ; 0x97a85
@ -2883,7 +2883,7 @@ Script_reloadmapmusic: ; 0x97a85
; script command 0x83 ; script command 0x83
ld a, $1 ld a, $1
ld [$c2c1], a ld [wc2c1], a
ret ret
; 0x97a8b ; 0x97a8b
@ -2924,11 +2924,11 @@ Script_changemap: ; 0x97ab3
; map_data_pointer (MapDataPointerParam) ; map_data_pointer (MapDataPointerParam)
call GetScriptByte call GetScriptByte
ld [$d1a0], a ld [MapBlockDataBank], a
call GetScriptByte call GetScriptByte
ld [$d1a1], a ld [MapBlockDataPointer], a
call GetScriptByte call GetScriptByte
ld [$d1a2], a ld [MapBlockDataPointer + 1], a
call Function24e4 call Function24e4
call Function2879 call Function2879
ret ret
@ -3023,7 +3023,7 @@ Script_loadbytec1ce: ; 0x97b27
; byte (SingleByteParam) ; byte (SingleByteParam)
call GetScriptByte call GetScriptByte
ld [$c2cf], a ld [wc2cf], a
ret ret
; 0x97b2e ; 0x97b2e
@ -3132,14 +3132,14 @@ Script_return: ; 0x97b8c
ExitScriptSubroutine: ; 0x97b9a ExitScriptSubroutine: ; 0x97b9a
; Return carry if there's no parent to return to. ; Return carry if there's no parent to return to.
ld hl, $d43c ld hl, wd43c
ld a, [hl] ld a, [hl]
and a and a
jr z, .asm_97bbe ; 0x97b9f $1d jr z, .asm_97bbe ; 0x97b9f $1d
dec [hl] dec [hl]
ld e, [hl] ld e, [hl]
ld d, $0 ld d, $0
ld hl, $d43d ld hl, wd43d
add hl, de add hl, de
add hl, de add hl, de
add hl, de add hl, de
@ -3164,7 +3164,7 @@ Script_resetfuncs: ; 0x97bc0
; script command 0x93 ; script command 0x93
xor a xor a
ld [$d43c], a ld [wd43c], a
ld [ScriptRunning], a ld [ScriptRunning], a
ld a, SCRIPT_OFF ld a, SCRIPT_OFF
ld [ScriptMode], a ld [ScriptMode], a
@ -3177,12 +3177,12 @@ Script_resetfuncs: ; 0x97bc0
Script_halloffame: ; 0x97bd5 Script_halloffame: ; 0x97bd5
; script command 0xa1 ; script command 0xa1
ld hl, $cfbc ld hl, GameTimerPause
res 0, [hl] res 0, [hl]
callba Mobile_HallOfFame callba Mobile_HallOfFame
callba Mobile_HallOfFame2 callba Mobile_HallOfFame2
callba HallOfFame callba HallOfFame
ld hl, $cfbc ld hl, GameTimerPause
set 0, [hl] set 0, [hl]
jr DisplayCredits jr DisplayCredits
; 0x97bf3 ; 0x97bf3

View File

@ -44,7 +44,7 @@ SpecialPokeSeer: ; 4f0bc
SeerAction: ; 4f0ee SeerAction: ; 4f0ee
ld a, [$d002] ld a, [wd002]
ld hl, SeerActions ld hl, SeerActions
rst JumpTable rst JumpTable
ret ret
@ -100,14 +100,14 @@ ReadCaughtData: ; 4f134
ld a, PartyMon1CaughtData - PartyMon1 ld a, PartyMon1CaughtData - PartyMon1
call GetPartyParamLocation call GetPartyParamLocation
ld a, [hli] ld a, [hli]
ld [$d03b], a ld [wd03b], a
ld a, [hld] ld a, [hld]
ld [$d03c], a ld [wd03b + 1], a
or [hl] or [hl]
jr z, .asm_4f170 jr z, .asm_4f170
ld a, 1 ld a, 1
ld [$d002], a ld [wd002], a
ld a, PartyMon1ID - PartyMon1 ld a, PartyMon1ID - PartyMon1
call GetPartyParamLocation call GetPartyParamLocation
@ -120,7 +120,7 @@ ReadCaughtData: ; 4f134
jr nz, .asm_4f15f jr nz, .asm_4f15f
ld a, 0 ld a, 0
ld [$d002], a ld [wd002], a
.asm_4f15f .asm_4f15f
call GetCaughtLevel call GetCaughtLevel
@ -133,7 +133,7 @@ ReadCaughtData: ; 4f134
.asm_4f170 .asm_4f170
ld a, 2 ld a, 2
ld [$d002], a ld [wd002], a
ret ret
; 4f176 ; 4f176
@ -142,7 +142,7 @@ GetCaughtName: ; 4f176
ld hl, PartyMonNicknames ld hl, PartyMonNicknames
ld bc, PKMN_NAME_LENGTH ld bc, PKMN_NAME_LENGTH
call AddNTimes call AddNTimes
ld de, $d003 ld de, wd003
ld bc, PKMN_NAME_LENGTH ld bc, PKMN_NAME_LENGTH
call CopyBytes call CopyBytes
ret ret
@ -150,12 +150,12 @@ GetCaughtName: ; 4f176
GetCaughtLevel: ; 4f18c GetCaughtLevel: ; 4f18c
ld a, "@" ld a, "@"
ld hl, $d036 ld hl, wd036
ld bc, 4 ld bc, 4
call ByteFill call ByteFill
; caught level ; caught level
ld a, [$d03b] ld a, [wd03b]
and $3f and $3f
jr z, .unknown jr z, .unknown
cp 1 ; hatched from an egg cp 1 ; hatched from an egg
@ -163,15 +163,15 @@ GetCaughtLevel: ; 4f18c
ld a, 5 ; egg hatch level ld a, 5 ; egg hatch level
.print .print
ld [$d03a], a ld [wd038 + 2], a
ld hl, $d036 ld hl, wd036
ld de, $d03a ld de, wd038 + 2
ld bc, $4103 ld bc, $4103
call PrintNum call PrintNum
ret ret
.unknown .unknown
ld de, $d036 ld de, wd036
ld hl, .unknown_level ld hl, .unknown_level
ld bc, 4 ld bc, 4
call CopyBytes call CopyBytes
@ -183,7 +183,7 @@ GetCaughtLevel: ; 4f18c
; 4f1c5 ; 4f1c5
GetCaughtTime: ; 4f1c5 GetCaughtTime: ; 4f1c5
ld a, [$d03b] ld a, [wd03b]
and $c0 and $c0
jr z, .none jr z, .none
@ -194,13 +194,13 @@ GetCaughtTime: ; 4f1c5
call GetNthString call GetNthString
ld d, h ld d, h
ld e, l ld e, l
ld hl, $d01f ld hl, wd01f
call CopyName2 call CopyName2
and a and a
ret ret
.none .none
ld de, $d01f ld de, wd01f
call UnknownCaughtData call UnknownCaughtData
ret ret
; 4f1e6 ; 4f1e6
@ -223,7 +223,7 @@ UnknownCaughtData: ; 4f1f8
; 4f20a ; 4f20a
GetCaughtLocation: ; 4f20a GetCaughtLocation: ; 4f20a
ld a, [$d03c] ld a, [wd03b + 1]
and $7f and $7f
jr z, .asm_4f22e jr z, .asm_4f22e
cp $7f cp $7f
@ -233,25 +233,25 @@ GetCaughtLocation: ; 4f20a
ld e, a ld e, a
callba GetLandmarkName callba GetLandmarkName
ld hl, StringBuffer1 ld hl, StringBuffer1
ld de, $d00e ld de, wd00e
ld bc, $0011 ld bc, $0011
call CopyBytes call CopyBytes
and a and a
ret ret
.asm_4f22e .asm_4f22e
ld de, $d00e ld de, wd00e
jp UnknownCaughtData jp UnknownCaughtData
.asm_4f234 .asm_4f234
ld a, $4 ld a, $4
ld [$d002], a ld [wd002], a
scf scf
ret ret
.asm_4f23b .asm_4f23b
ld a, $3 ld a, $3
ld [$d002], a ld [wd002], a
scf scf
ret ret
; 4f242 ; 4f242
@ -261,17 +261,17 @@ GetCaughtOT: ; 4f242
ld hl, PartyMonOT ld hl, PartyMonOT
ld bc, NAME_LENGTH ld bc, NAME_LENGTH
call AddNTimes call AddNTimes
ld de, $d02a ld de, wd02a
ld bc, $000b ld bc, $000b
call CopyBytes call CopyBytes
ld hl, .male ld hl, .male
ld a, [$d03c] ld a, [wd03b + 1]
bit 7, a bit 7, a
jr z, .asm_4f264 jr z, .asm_4f264
ld hl, .female ld hl, .female
.asm_4f264 .asm_4f264
ld de, $d035 ld de, wd034 + 1
ld a, "@" ld a, "@"
ld [de], a ld [de], a
ret ret
@ -359,7 +359,7 @@ SeerCancelText: ; 0x4f2af
SeerAdvice: ; 4f2b4 SeerAdvice: ; 4f2b4
ld a, PartyMon1Level - PartyMon1 ld a, PartyMon1Level - PartyMon1
call GetPartyParamLocation call GetPartyParamLocation
ld a, [$d03a] ld a, [wd038 + 2]
ld c, a ld c, a
ld a, [hl] ld a, [hl]
sub c sub c

View File

@ -109,10 +109,10 @@ Functiond00b4: ; d00b4
push af push af
ld a, $2 ld a, $2
ld [rSVBK], a ld [rSVBK], a
ld a, [$d168] ld a, [w2_d168]
ld c, a ld c, a
ld b, 0 ld b, 0
ld hl, $d169 ld hl, w2_d169
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
@ -120,7 +120,7 @@ Functiond00b4: ; d00b4
ld a, [hl] ld a, [hl]
ld hl, Jumptable_d00da ld hl, Jumptable_d00da
rst JumpTable rst JumpTable
ld a, [$d168] ld a, [w2_d168]
ld c, a ld c, a
pop af pop af
ld [rSVBK], a ld [rSVBK], a
@ -148,18 +148,18 @@ Jumptable_d00da: ; d00da
Functiond00f2: ; d00f2 Functiond00f2: ; d00f2
ld a, $12 ld a, $12
ld [$d181], a ld [w2_d181], a
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
Functiond00fe: ; d00fe Functiond00fe: ; d00fe
ld hl, $d181 ld hl, w2_d181
dec [hl] dec [hl]
ret nz ret nz
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d010b ; d010b
@ -168,9 +168,9 @@ Functiond010b: ; d010b
ld b, $0 ld b, $0
call Functiond0228 call Functiond0228
call Functiond0504 call Functiond0504
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d011d ; d011d
@ -179,9 +179,9 @@ Functiond011d: ; d011d
ld b, $4 ld b, $4
call Functiond0228 call Functiond0228
call Functiond0504 call Functiond0504
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d012f ; d012f
@ -190,76 +190,76 @@ Functiond012f: ; d012f
ld b, $0 ld b, $0
call Functiond0228 call Functiond0228
call Functiond0504 call Functiond0504
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d0141 ; d0141
Functiond0141: ; d0141 Functiond0141: ; d0141
call Functiond0250 call Functiond0250
ld a, [$d17e] ld a, [w2_d17e]
bit 7, a bit 7, a
ret z ret z
call Functiond04bd call Functiond04bd
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d0155 ; d0155
Functiond0155: ; d0155 Functiond0155: ; d0155
call Functiond0250 call Functiond0250
ld a, [$d17e] ld a, [w2_d17e]
bit 7, a bit 7, a
ret z ret z
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d0166 ; d0166
Functiond0166: ; d0166 Functiond0166: ; d0166
call Functiond01a9 call Functiond01a9
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d0171 ; d0171
Functiond0171: ; d0171 Functiond0171: ; d0171
call Functiond01a9 call Functiond01a9
ld hl, $d168 ld hl, w2_d168
set 7, [hl] set 7, [hl]
ret ret
; d017a ; d017a
Functiond017a: ; d017a Functiond017a: ; d017a
ld a, [$d16b] ld a, [w2_d16b]
call _PlayCry call _PlayCry
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d0188 ; d0188
Functiond0188: ; d0188 Functiond0188: ; d0188
ld a, [$d16b] ld a, [w2_d16b]
call PlayCry2 call PlayCry2
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d0196 ; d0196
Functiond0196: ; d0196 Functiond0196: ; d0196
ld a, $f ld a, $f
ld [CryTracks], a ld [CryTracks], a
ld a, [$d16b] ld a, [w2_d16b]
call PlayStereoCry2 call PlayStereoCry2
ld a, [$d168] ld a, [w2_d168]
inc a inc a
ld [$d168], a ld [w2_d168], a
ret ret
; d01a9 ; d01a9
@ -299,7 +299,7 @@ Functiond01d6: ; d01d6
push bc push bc
push de push de
push hl push hl
ld hl, $d168 ld hl, w2_d168
ld bc, $0029 ld bc, $0029
xor a xor a
call ByteFill call ByteFill
@ -307,28 +307,28 @@ Functiond01d6: ; d01d6
pop de pop de
pop bc pop bc
ld a, c ld a, c
ld [$d169], a ld [w2_d169], a
ld a, b ld a, b
ld [$d16a], a ld [w2_d16a], a
ld a, l ld a, l
ld [$d16f], a ld [w2_d16f], a
ld a, h ld a, h
ld [$d170], a ld [w2_d170], a
ld a, d ld a, d
ld [$d16e], a ld [w2_d16e], a
ld a, $1 ld a, $1
ld hl, CurPartySpecies ld hl, CurPartySpecies
call GetFarWRAMByte call GetFarWRAMByte
ld [$d16b], a ld [w2_d16b], a
ld a, $1 ld a, $1
ld hl, UnownLetter ld hl, UnownLetter
call GetFarWRAMByte call GetFarWRAMByte
ld [$d16c], a ld [w2_d16c], a
call Functiond065c call Functiond065c
ld [$d16d], a ld [w2_d16d], a
call Functiond05b4 call Functiond05b4
ld a, c ld a, c
ld [$d171], a ld [w2_d171], a
pop af pop af
ld [rSVBK], a ld [rSVBK], a
ret ret
@ -340,15 +340,15 @@ Functiond0228: ; d0228
ld a, $2 ld a, $2
ld [rSVBK], a ld [rSVBK], a
push bc push bc
ld hl, $d172 ld hl, w2_d172
ld bc, $001f ld bc, $001f
xor a xor a
call ByteFill call ByteFill
pop bc pop bc
ld a, b ld a, b
ld [$d173], a ld [w2_d172 + 1], a
ld a, c ld a, c
ld [$d172], a ld [w2_d172], a
call Functiond055c call Functiond055c
call Functiond05ce call Functiond05ce
call Functiond061b call Functiond061b
@ -362,7 +362,7 @@ Functiond0250: ; d0250
ld [hBGMapMode], a ld [hBGMapMode], a
Functiond0253: ; d0253 Functiond0253: ; d0253
ld a, [$d17e] ld a, [w2_d17e]
and $7f and $7f
ld hl, Tabled025d ld hl, Tabled025d
rst JumpTable rst JumpTable
@ -376,7 +376,7 @@ Tabled025d: ; d025d
Functiond0261: ; d0261 Functiond0261: ; d0261
call Functiond02f8 call Functiond02f8
ld a, [$d182] ld a, [w2_d182]
cp $ff cp $ff
jr z, Functiond02a8 jr z, Functiond02a8
cp $fe cp $fe
@ -384,40 +384,40 @@ Functiond0261: ; d0261
cp $fd cp $fd
jr z, Functiond0296 jr z, Functiond0296
call Functiond02c8 call Functiond02c8
ld a, [$d183] ld a, [w2_d183]
call Functiond02ae call Functiond02ae
ld [$d181], a ld [w2_d181], a
call Functiond02dc call Functiond02dc
Functiond0282: ; d0282 Functiond0282: ; d0282
ld a, [$d181] ld a, [w2_d181]
dec a dec a
ld [$d181], a ld [w2_d181], a
ret nz ret nz
call Functiond02e4 call Functiond02e4
ret ret
; d028e ; d028e
Functiond028e: ; d028e Functiond028e: ; d028e
ld a, [$d183] ld a, [w2_d183]
ld [$d17f], a ld [w2_d17f], a
jr Functiond0253 jr Functiond0253
; d0296 ; d0296
Functiond0296: ; d0296 Functiond0296: ; d0296
ld a, [$d17f] ld a, [w2_d17f]
and a and a
ret z ret z
dec a dec a
ld [$d17f], a ld [w2_d17f], a
ret z ret z
ld a, [$d183] ld a, [w2_d183]
ld [$d17d], a ld [w2_d17d], a
jr Functiond0253 jr Functiond0253
; d02a8 ; d02a8
Functiond02a8: ; d02a8 Functiond02a8: ; d02a8
ld hl, $d17e ld hl, w2_d17e
set 7, [hl] set 7, [hl]
ret ret
; d02ae ; d02ae
@ -426,7 +426,7 @@ Functiond02ae: ; d02ae
ld c, a ld c, a
ld b, $0 ld b, $0
ld hl, $0000 ld hl, $0000
ld a, [$d173] ld a, [w2_d173]
call AddNTimes call AddNTimes
ld a, h ld a, h
swap a swap a
@ -442,7 +442,7 @@ Functiond02ae: ; d02ae
Functiond02c8: ; d02c8 Functiond02c8: ; d02c8
call Functiond04bd call Functiond04bd
ld a, [$d182] ld a, [w2_d182]
and a and a
ret z ret z
call Functiond031b call Functiond031b
@ -454,70 +454,70 @@ Functiond02c8: ; d02c8
; d02dc ; d02dc
Functiond02dc: ; d02dc Functiond02dc: ; d02dc
ld a, [$d17e] ld a, [w2_d17e]
inc a inc a
ld [$d17e], a ld [w2_d17e], a
ret ret
; d02e4 ; d02e4
Functiond02e4: ; d02e4 Functiond02e4: ; d02e4
ld a, [$d17e] ld a, [w2_d17e]
dec a dec a
ld [$d17e], a ld [w2_d17e], a
ret ret
; d02ec ; d02ec
Functiond02ec: ; d02ec Functiond02ec: ; d02ec
ld a, [$d16b] ld a, [w2_d16b]
cp UNOWN cp UNOWN
ret ret
; d02f2 ; d02f2
Functiond02f2: ; d02f2 Functiond02f2: ; d02f2
ld a, [$d16b] ld a, [w2_d16b]
cp EGG cp EGG
ret ret
; d02f8 ; d02f8
Functiond02f8: ; d02f8 Functiond02f8: ; d02f8
push hl push hl
ld a, [$d17d] ld a, [w2_d17d]
ld e, a ld e, a
ld d, $0 ld d, $0
ld hl, $d175 ld hl, w2_d175
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
add hl, de add hl, de
add hl, de add hl, de
ld a, [$d174] ld a, [w2_d174]
call GetFarHalfword call GetFarHalfword
ld a, l ld a, l
ld [$d182], a ld [w2_d182], a
ld a, h ld a, h
ld [$d183], a ld [w2_d183], a
ld hl, $d17d ld hl, w2_d17d
inc [hl] inc [hl]
pop hl pop hl
ret ret
; d031b ; d031b
Functiond031b: ; d031b Functiond031b: ; d031b
ld a, [$d182] ld a, [w2_d182]
dec a dec a
ld c, a ld c, a
ld b, $0 ld b, $0
ld hl, $d178 ld hl, w2_d178
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
add hl, bc add hl, bc
add hl, bc add hl, bc
ld a, [$d177] ld a, [w2_d177]
call GetFarHalfword call GetFarHalfword
ld a, [$d177] ld a, [w2_d177]
call GetFarByte call GetFarByte
ld [$d180], a ld [w2_d180], a
inc hl inc hl
ret ret
; d033b ; d033b
@ -525,22 +525,22 @@ Functiond031b: ; d031b
Functiond033b: ; d033b Functiond033b: ; d033b
call Functiond0356 call Functiond0356
push bc push bc
ld hl, $d17b ld hl, w2_d17b
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
ld a, [$d180] ld a, [w2_d180]
call AddNTimes call AddNTimes
pop bc pop bc
ld de, $d188 ld de, w2_d188
ld a, [$d17a] ld a, [w2_d17a]
call FarCopyBytes call FarCopyBytes
ret ret
; d0356 ; d0356
Functiond0356: ; d0356 Functiond0356: ; d0356
push hl push hl
ld a, [$d171] ld a, [w2_d171]
sub 5 sub 5
ld c, a ld c, a
ld b, 0 ld b, 0
@ -556,9 +556,9 @@ Unknown_d0368: db 4, 5, 7
Functiond036b: ; d036b Functiond036b: ; d036b
xor a xor a
ld [$d187], a ld [w2_d187], a
ld [$d186], a ld [w2_d186], a
ld [$d185], a ld [w2_d185], a
.asm_d0375 .asm_d0375
push hl push hl
call Functiond0392 call Functiond0392
@ -567,7 +567,7 @@ Functiond036b: ; d036b
and a and a
jr z, .asm_d038a jr z, .asm_d038a
ld a, [$d177] ld a, [w2_d177]
call GetFarByte call GetFarByte
inc hl inc hl
push hl push hl
@ -583,17 +583,17 @@ Functiond036b: ; d036b
; d0392 ; d0392
Functiond0392: ; d0392 Functiond0392: ; d0392
ld a, [$d187] ld a, [w2_d187]
and $f8 and $f8
rrca rrca
rrca rrca
rrca rrca
ld e, a ld e, a
ld d, 0 ld d, 0
ld hl, $d188 ld hl, w2_d188
add hl, de add hl, de
ld b, [hl] ld b, [hl]
ld a, [$d187] ld a, [w2_d187]
and 7 and 7
jr z, .asm_d03b0 jr z, .asm_d03b0
@ -613,7 +613,7 @@ Functiond0392: ; d0392
.asm_d03b7 .asm_d03b7
ld b, a ld b, a
ld hl, $d187 ld hl, w2_d187
inc [hl] inc [hl]
ret ret
; d03bd ; d03bd
@ -624,7 +624,7 @@ Functiond03bd: ; d03bd
pop af pop af
push hl push hl
call Functiond03f7 call Functiond03f7
ld hl, $d16e ld hl, w2_d16e
add [hl] add [hl]
pop hl pop hl
ld [hl], a ld [hl], a
@ -633,20 +633,20 @@ Functiond03bd: ; d03bd
Functiond03cd: ; d03cd Functiond03cd: ; d03cd
call Functiond046c call Functiond046c
ld a, [$d186] ld a, [w2_d186]
ld bc, $0014 ld bc, $0014
call AddNTimes call AddNTimes
ld a, [$c2c6] ld a, [wc2c6]
and a and a
jr nz, .asm_d03e8 jr nz, .asm_d03e8
ld a, [$d185] ld a, [w2_d185]
ld e, a ld e, a
ld d, 0 ld d, 0
add hl, de add hl, de
jr .asm_d03f3 jr .asm_d03f3
.asm_d03e8 .asm_d03e8
ld a, [$d185] ld a, [w2_d185]
ld e, a ld e, a
ld a, l ld a, l
sub e sub e
@ -663,7 +663,7 @@ Unknown_d03f4: db 6, 5, 4
Functiond03f7: ; d03f7 Functiond03f7: ; d03f7
push af push af
ld a, [$d171] ld a, [w2_d171]
cp 5 cp 5
jr z, .asm_d0405 jr z, .asm_d0405
cp 6 cp 6
@ -727,12 +727,12 @@ Unknown_d0448:
Functiond046c: ; d046c Functiond046c: ; d046c
ld hl, $d16f ld hl, w2_d16f
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
ld a, [$d171] ld a, [w2_d171]
ld de, 0 ld de, 0
ld bc, 6 ld bc, 6
cp 7 cp 7
@ -745,7 +745,7 @@ Functiond046c: ; d046c
ld bc, 45 ld bc, 45
.asm_d048f .asm_d048f
ld a, [$c2c6] ld a, [wc2c6]
and a and a
jr nz, .asm_d0497 jr nz, .asm_d0497
add hl, de add hl, de
@ -757,20 +757,20 @@ Functiond046c: ; d046c
; d0499 ; d0499
Functiond0499: ; d0499 Functiond0499: ; d0499
ld a, [$d186] ld a, [w2_d186]
inc a inc a
ld [$d186], a ld [w2_d186], a
ld c, a ld c, a
ld a, [$d171] ld a, [w2_d171]
cp c cp c
jr nz, .asm_d04bb jr nz, .asm_d04bb
xor a xor a
ld [$d186], a ld [w2_d186], a
ld a, [$d185] ld a, [w2_d185]
inc a inc a
ld [$d185], a ld [w2_d185], a
ld c, a ld c, a
ld a, [$d171] ld a, [w2_d171]
cp c cp c
jr nz, .asm_d04bb jr nz, .asm_d04bb
scf scf
@ -783,7 +783,7 @@ Functiond0499: ; d0499
Functiond04bd: ; d04bd Functiond04bd: ; d04bd
call Functiond04f6 call Functiond04f6
ld a, [$c2c6] ld a, [wc2c6]
and a and a
jr nz, .asm_d04ce jr nz, .asm_d04ce
ld de, 1 ld de, 1
@ -795,14 +795,14 @@ Functiond04bd: ; d04bd
ld bc, 6 ld bc, 6
.asm_d04d4 .asm_d04d4
ld hl, $d16f ld hl, w2_d16f
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
add hl, bc add hl, bc
ld c, 7 ld c, 7
ld b, 7 ld b, 7
ld a, [$d16e] ld a, [w2_d16e]
.asm_d04e2 .asm_d04e2
push bc push bc
push hl push hl
@ -824,7 +824,7 @@ Functiond04bd: ; d04bd
; d04f6 ; d04f6
Functiond04f6: ; d04f6 Functiond04f6: ; d04f6
ld hl, $d16f ld hl, w2_d16f
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
@ -895,7 +895,7 @@ Functiond0536: ; d0536
; d0551 ; d0551
Functiond0551: ; d0551 Functiond0551: ; d0551
ld hl, $d16f ld hl, w2_d16f
ld a, [hli] ld a, [hli]
ld h, [hl] ld h, [hl]
ld l, a ld l, a
@ -918,32 +918,32 @@ Functiond055c: ; d055c
ld de, AnimationExtraPointers ld de, AnimationExtraPointers
.asm_d0576 .asm_d0576
ld a, [$d172] ld a, [w2_d172]
and a and a
jr z, .asm_d057e jr z, .asm_d057e
ld h, d ld h, d
ld l, e ld l, e
.asm_d057e .asm_d057e
ld a, [$d16d] ld a, [w2_d16d]
dec a dec a
ld e, a ld e, a
ld d, 0 ld d, 0
add hl, de add hl, de
add hl, de add hl, de
ld a, c ld a, c
ld [$d174], a ld [w2_d174], a
call GetFarHalfword call GetFarHalfword
ld a, l ld a, l
ld [$d175], a ld [w2_d175], a
ld a, h ld a, h
ld [$d176], a ld [w2_d176], a
ret ret
.egg .egg
ld hl, EggAnimation ld hl, EggAnimation
ld c, BANK(EggAnimation) ld c, BANK(EggAnimation)
ld a, [$d172] ld a, [w2_d172]
and a and a
jr z, .asm_d05a7 jr z, .asm_d05a7
ld hl, EggAnimationExtra ld hl, EggAnimationExtra
@ -951,11 +951,11 @@ Functiond055c: ; d055c
.asm_d05a7 .asm_d05a7
ld a, c ld a, c
ld [$d174], a ld [w2_d174], a
ld a, l ld a, l
ld [$d175], a ld [w2_d175], a
ld a, h ld a, h
ld [$d176], a ld [w2_d176], a
ret ret
; d05b4 ; d05b4
@ -984,7 +984,7 @@ Functiond05ce: ; d05ce
ld c, BANK(UnownsFrames) ld c, BANK(UnownsFrames)
ld hl, UnownFramesPointers ld hl, UnownFramesPointers
jr z, .asm_d05ef jr z, .asm_d05ef
ld a, [$d16b] ld a, [w2_d16b]
cp 151 + 1 cp 151 + 1
ld b, BANK(FramesPointers) ld b, BANK(FramesPointers)
ld c, BANK(KantoFrames) ld c, BANK(KantoFrames)
@ -993,9 +993,9 @@ Functiond05ce: ; d05ce
ld c, BANK(JohtoFrames) ld c, BANK(JohtoFrames)
.asm_d05ef .asm_d05ef
ld a, c ld a, c
ld [$d177], a ld [w2_d177], a
ld a, [$d16d] ld a, [w2_d16d]
dec a dec a
ld e, a ld e, a
ld d, 0 ld d, 0
@ -1004,20 +1004,20 @@ Functiond05ce: ; d05ce
ld a, b ld a, b
call GetFarHalfword call GetFarHalfword
ld a, l ld a, l
ld [$d178], a ld [w2_d178], a
ld a, h ld a, h
ld [$d179], a ld [w2_d179], a
ret ret
.egg .egg
ld hl, EggFrames ld hl, EggFrames
ld c, BANK(EggFrames) ld c, BANK(EggFrames)
ld a, c ld a, c
ld [$d177], a ld [w2_d177], a
ld a, l ld a, l
ld [$d178], a ld [w2_d178], a
ld a, h ld a, h
ld [$d179], a ld [w2_d179], a
ret ret
; d061b ; d061b
@ -1032,48 +1032,48 @@ Functiond061b: ; d061b
ld a, BANK(BitmasksPointers) ld a, BANK(BitmasksPointers)
ld hl, BitmasksPointers ld hl, BitmasksPointers
.asm_d062f .asm_d062f
ld [$d17a], a ld [w2_d17a], a
ld a, [$d16d] ld a, [w2_d16d]
dec a dec a
ld e, a ld e, a
ld d, 0 ld d, 0
add hl, de add hl, de
add hl, de add hl, de
ld a, [$d17a] ld a, [w2_d17a]
call GetFarHalfword call GetFarHalfword
ld a, l ld a, l
ld [$d17b], a ld [w2_d17b], a
ld a, h ld a, h
ld [$d17c], a ld [w2_d17c], a
ret ret
.egg .egg
ld c, BANK(EggBitmasks) ld c, BANK(EggBitmasks)
ld hl, EggBitmasks ld hl, EggBitmasks
ld a, c ld a, c
ld [$d17a], a ld [w2_d17a], a
ld a, l ld a, l
ld [$d17b], a ld [w2_d17b], a
ld a, h ld a, h
ld [$d17c], a ld [w2_d17c], a
ret ret
; d065c ; d065c
Functiond065c: ; d065c Functiond065c: ; d065c
call Functiond02ec call Functiond02ec
jr z, .asm_d0665 jr z, .asm_d0665
ld a, [$d16b] ld a, [w2_d16b]
ret ret
.asm_d0665 .asm_d0665
ld a, [$d16c] ld a, [w2_d16c]
ret ret
; d0669 ; d0669
Functiond0669: ; d0669 Functiond0669: ; d0669
ld a, $1 ld a, $1
ld [$c2c6], a ld [wc2c6], a
Functiond066e: ; d066e Functiond066e: ; d066e
call Functiond01c6 call Functiond01c6
@ -1090,12 +1090,12 @@ Functiond066e: ; d066e
ld e, c ld e, c
call Functiond008e call Functiond008e
xor a xor a
ld [$c2c6], a ld [wc2c6], a
ret ret
.asm_d068c .asm_d068c
xor a xor a
ld [$c2c6], a ld [wc2c6], a
inc a inc a
ld [CurPartySpecies], a ld [CurPartySpecies], a
ret ret

View File

@ -281,7 +281,8 @@ AutoInputLength:: ; c2cb
wc2cc:: ds 1 wc2cc:: ds 1
wc2cd:: ds 1 wc2cd:: ds 1
wc2ce:: ds 2 wc2ce:: ds 1
wc2cf:: ds 1
wc2d0:: ds 4 wc2d0:: ds 4
wc2d4:: ds 1 wc2d4:: ds 1
wc2d5:: ds 1 wc2d5:: ds 1
@ -1357,7 +1358,8 @@ wd032:: ds 1
wd033:: ds 1 wd033:: ds 1
wd034:: ds 2 wd034:: ds 2
wd036:: ds 2 wd036:: ds 2
wd038:: ds 6 wd038:: ds 3
wd03b:: ds 3
MenuItemsList:: MenuItemsList::
CurFruitTree:: CurFruitTree::
@ -1389,7 +1391,9 @@ WalkingY:: ; d046
WalkingTile:: ; d047 WalkingTile:: ; d047
ds 1 ds 1
wd048:: ds 6 wd048:: ds 3
wd04b:: ds 2
wd04d:: ds 1
wd04e:: ds 2 wd04e:: ds 2
wd050:: ds 10 wd050:: ds 10
wd05a:: ds 12 wd05a:: ds 12
@ -1853,12 +1857,16 @@ ScriptBank:: ; d439
ScriptPos:: ; d43a ScriptPos:: ; d43a
ds 2 ds 2
ds 17 wd43c:: ds 1
wd43d:: ds 16
ScriptDelay:: ; d44d ScriptDelay:: ; d44d
ds 1 ds 1
ds 4 wd44e:: ds 1
wd44f:: ds 1
wd450:: ds 1
wd451:: ds 1
wd452:: ds 1 wd452:: ds 1
wd453:: ds 1 wd453:: ds 1
wd454:: ds 1 wd454:: ds 1
@ -2479,6 +2487,44 @@ wdfec:: ds 1
wdff5:: wdff5::
SECTION "Pic Animations", WRAMX, BANK [2]
w2_d000:: ds $168
w2_d168:: ds 1
w2_d169:: ds 1
w2_d16a:: ds 1
w2_d16b:: ds 1
w2_d16c:: ds 1
w2_d16d:: ds 1
w2_d16e:: ds 1
w2_d16f:: ds 1
w2_d170:: ds 1
w2_d171:: ds 1
w2_d172:: ds 1
w2_d173:: ds 1
w2_d174:: ds 1
w2_d175:: ds 1
w2_d176:: ds 1
w2_d177:: ds 1
w2_d178:: ds 1
w2_d179:: ds 1
w2_d17a:: ds 1
w2_d17b:: ds 1
w2_d17c:: ds 1
w2_d17d:: ds 1
w2_d17e:: ds 1
w2_d17f:: ds 1
w2_d180:: ds 1
w2_d181:: ds 1
w2_d182:: ds 1
w2_d183:: ds 1
w2_d184:: ds 1
w2_d185:: ds 1
w2_d186:: ds 1
w2_d187:: ds 1
w2_d188:: ds 1
SECTION "GBC Video", WRAMX, BANK [5] SECTION "GBC Video", WRAMX, BANK [5]
@ -2503,7 +2549,7 @@ LYOverridesBackupEnd::
SECTION "Battle Animations", WRAMX, BANK [5] SECTION "Battle Animations", WRAMX, BANK [5]
wd300:: ds 10 w5_d300:: ds 10
ActiveAnimObjects:: ; d30a ActiveAnimObjects:: ; d30a
ds 4 * 40 ds 4 * 40
@ -2513,7 +2559,7 @@ ActiveAnimObjects:: ; d30a
ActiveBGEffects:: ; d3fa ActiveBGEffects:: ; d3fa
ds 4 * 5 ds 4 * 5
wd40e:: ds 1 w5_d40e:: ds 1
BattleAnimFlags:: ; d40f BattleAnimFlags:: ; d40f
ds 1 ds 1
@ -2529,11 +2575,11 @@ BattleAnimVar:: ; d416
ds 1 ds 1
BattleAnimByte:: ; d417 BattleAnimByte:: ; d417
ds 1 ds 1
wd418:: ds 1 w5_d418:: ds 1
BattleAnimTemps:: ; d419 BattleAnimTemps:: ; d419
ds 8 ds 8
ds 1 ds 1
wd422:: ds $40 w5_d422:: ds $40
SECTION "Scratch", SRAM, BANK [0] SECTION "Scratch", SRAM, BANK [0]