mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2024-11-16 11:27:33 -08:00
Restore point
This commit is contained in:
parent
2e74d969f7
commit
ebfa8e2639
92
main.asm
92
main.asm
@ -25284,11 +25284,11 @@ Function24d19: ; 24d19
|
|||||||
ld hl, MenuDataHeader_0x24d3f
|
ld hl, MenuDataHeader_0x24d3f
|
||||||
call LoadMenuDataHeader
|
call LoadMenuDataHeader
|
||||||
call Function24d47
|
call Function24d47
|
||||||
call Function24d91
|
call PopulateMonMenu
|
||||||
|
|
||||||
ld a, 1
|
ld a, 1
|
||||||
ld [hBGMapMode], a
|
ld [hBGMapMode], a
|
||||||
call Function24d59
|
call MonMenuLoop
|
||||||
ld [MenuSelection], a
|
ld [MenuSelection], a
|
||||||
|
|
||||||
call ExitMenu
|
call ExitMenu
|
||||||
@ -25316,8 +25316,8 @@ Function24d47: ; 24d47
|
|||||||
ret
|
ret
|
||||||
; 24d59
|
; 24d59
|
||||||
|
|
||||||
Function24d59: ; 24d59
|
MonMenuLoop: ; 24d59
|
||||||
.asm_24d59
|
.loop
|
||||||
ld a, $a0
|
ld a, $a0
|
||||||
ld [wcf91], a
|
ld [wcf91], a
|
||||||
ld a, [Buffer1]
|
ld a, [Buffer1]
|
||||||
@ -25330,16 +25330,16 @@ Function24d59: ; 24d59
|
|||||||
call PlaySFX
|
call PlaySFX
|
||||||
ld a, [hJoyPressed]
|
ld a, [hJoyPressed]
|
||||||
bit 0, a ; A
|
bit 0, a ; A
|
||||||
jr nz, .asm_24d84
|
jr nz, .select
|
||||||
bit 1, a ; B
|
bit 1, a ; B
|
||||||
jr nz, .asm_24d81
|
jr nz, .cancel
|
||||||
jr .asm_24d59
|
jr .loop
|
||||||
|
|
||||||
.asm_24d81
|
.cancel
|
||||||
ld a, 18 ; CANCEL
|
ld a, 18 ; CANCEL
|
||||||
ret
|
ret
|
||||||
|
|
||||||
.asm_24d84
|
.select
|
||||||
ld a, [wcfa9]
|
ld a, [wcfa9]
|
||||||
dec a
|
dec a
|
||||||
ld c, a
|
ld c, a
|
||||||
@ -25350,42 +25350,42 @@ Function24d59: ; 24d59
|
|||||||
ret
|
ret
|
||||||
; 24d91
|
; 24d91
|
||||||
|
|
||||||
Function24d91: ; 24d91
|
PopulateMonMenu: ; 24d91
|
||||||
call Function1cfd
|
call Function1cfd
|
||||||
ld bc, $002a
|
ld bc, $002a ; 42
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld de, Buffer2
|
ld de, Buffer2
|
||||||
.asm_24d9b
|
.loop
|
||||||
ld a, [de]
|
ld a, [de]
|
||||||
inc de
|
inc de
|
||||||
cp $ff
|
cp -1
|
||||||
ret z
|
ret z
|
||||||
push de
|
push de
|
||||||
push hl
|
push hl
|
||||||
call Function24db0
|
call GetMonMenuString
|
||||||
pop hl
|
pop hl
|
||||||
call PlaceString
|
call PlaceString
|
||||||
ld bc, $0028
|
ld bc, $0028 ; 40
|
||||||
add hl, bc
|
add hl, bc
|
||||||
pop de
|
pop de
|
||||||
jr .asm_24d9b
|
jr .loop
|
||||||
; 24db0
|
; 24db0
|
||||||
|
|
||||||
Function24db0: ; 24db0
|
GetMonMenuString: ; 24db0
|
||||||
ld hl, MonMenuOptions + 1
|
ld hl, MonMenuOptions + 1
|
||||||
ld de, $0003
|
ld de, 3
|
||||||
call IsInArray
|
call IsInArray
|
||||||
dec hl
|
dec hl
|
||||||
ld a, [hli]
|
ld a, [hli]
|
||||||
cp $1
|
cp 1
|
||||||
jr z, .asm_24dc8
|
jr z, .NotMove
|
||||||
inc hl
|
inc hl
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
ld [wd265], a
|
ld [wd265], a
|
||||||
call GetMoveName
|
call GetMoveName
|
||||||
ret
|
ret
|
||||||
|
|
||||||
.asm_24dc8
|
.NotMove
|
||||||
inc hl
|
inc hl
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
dec a
|
dec a
|
||||||
@ -25400,35 +25400,35 @@ Function24dd4: ; 24dd4
|
|||||||
call Function24e68
|
call Function24e68
|
||||||
ld a, [CurPartySpecies]
|
ld a, [CurPartySpecies]
|
||||||
cp EGG
|
cp EGG
|
||||||
jr z, .asm_24e3f
|
jr z, .egg
|
||||||
ld a, [InLinkBattle]
|
ld a, [InLinkBattle]
|
||||||
and a
|
and a
|
||||||
jr nz, .asm_24e03
|
jr nz, .skip
|
||||||
ld a, PartyMon1Moves - PartyMon1
|
ld a, PartyMon1Moves - PartyMon1
|
||||||
call GetPartyParamLocation
|
call GetPartyParamLocation
|
||||||
ld d, h
|
ld d, h
|
||||||
ld e, l
|
ld e, l
|
||||||
ld c, NUM_MOVES
|
ld c, NUM_MOVES
|
||||||
.asm_24ded
|
.loop
|
||||||
push bc
|
push bc
|
||||||
push de
|
push de
|
||||||
ld a, [de]
|
ld a, [de]
|
||||||
and a
|
and a
|
||||||
jr z, .asm_24dfd
|
jr z, .next
|
||||||
push hl
|
push hl
|
||||||
call Function24e52
|
call Function24e52
|
||||||
pop hl
|
pop hl
|
||||||
jr nc, .asm_24dfd
|
jr nc, .next
|
||||||
call Function24e83
|
call Function24e83
|
||||||
|
|
||||||
.asm_24dfd
|
.next
|
||||||
pop de
|
pop de
|
||||||
inc de
|
inc de
|
||||||
pop bc
|
pop bc
|
||||||
dec c
|
dec c
|
||||||
jr nz, .asm_24ded
|
jr nz, .loop
|
||||||
|
|
||||||
.asm_24e03
|
.skip
|
||||||
ld a, $f
|
ld a, $f
|
||||||
call Function24e83
|
call Function24e83
|
||||||
ld a, $10
|
ld a, $10
|
||||||
@ -25437,7 +25437,7 @@ Function24dd4: ; 24dd4
|
|||||||
call Function24e83
|
call Function24e83
|
||||||
ld a, [InLinkBattle]
|
ld a, [InLinkBattle]
|
||||||
and a
|
and a
|
||||||
jr nz, .asm_24e2f
|
jr nz, .skip2
|
||||||
push hl
|
push hl
|
||||||
ld a, PartyMon1Item - PartyMon1
|
ld a, PartyMon1Item - PartyMon1
|
||||||
call GetPartyParamLocation
|
call GetPartyParamLocation
|
||||||
@ -25445,24 +25445,24 @@ Function24dd4: ; 24dd4
|
|||||||
callba ItemIsMail
|
callba ItemIsMail
|
||||||
pop hl
|
pop hl
|
||||||
ld a, $14
|
ld a, $14
|
||||||
jr c, .asm_24e2c
|
jr c, .ok
|
||||||
ld a, $11
|
ld a, $11
|
||||||
|
|
||||||
.asm_24e2c
|
.ok
|
||||||
call Function24e83
|
call Function24e83
|
||||||
|
|
||||||
.asm_24e2f
|
.skip2
|
||||||
ld a, [Buffer1]
|
ld a, [Buffer1]
|
||||||
cp $8
|
cp $8
|
||||||
jr z, .asm_24e3b
|
jr z, .ok2
|
||||||
ld a, $12
|
ld a, $12
|
||||||
call Function24e83
|
call Function24e83
|
||||||
|
|
||||||
.asm_24e3b
|
.ok2
|
||||||
call Function24e76
|
call Function24e76
|
||||||
ret
|
ret
|
||||||
|
|
||||||
.asm_24e3f
|
.egg
|
||||||
ld a, $f
|
ld a, $f
|
||||||
call Function24e83
|
call Function24e83
|
||||||
ld a, $10
|
ld a, $10
|
||||||
@ -48260,7 +48260,7 @@ UnknownScript_0x506c8: ; 0x506c8
|
|||||||
callasm GetPartyNick
|
callasm GetPartyNick
|
||||||
writetext UnknownText_0x50726
|
writetext UnknownText_0x50726
|
||||||
closetext
|
closetext
|
||||||
callasm Function506ef
|
callasm SweetScentEncounter
|
||||||
iffalse UnknownScript_0x506e9
|
iffalse UnknownScript_0x506e9
|
||||||
checkflag ENGINE_BUG_CONTEST_TIMER
|
checkflag ENGINE_BUG_CONTEST_TIMER
|
||||||
iftrue UnknownScript_0x506e5
|
iftrue UnknownScript_0x506e5
|
||||||
@ -48281,29 +48281,29 @@ UnknownScript_0x506e9: ; 0x506e9
|
|||||||
end
|
end
|
||||||
; 0x506ef
|
; 0x506ef
|
||||||
|
|
||||||
Function506ef: ; 506ef
|
SweetScentEncounter: ; 506ef
|
||||||
callba Function97cfd
|
callba Function97cfd
|
||||||
jr nc, .asm_5071e
|
jr nc, .no_battle
|
||||||
ld hl, StatusFlags2
|
ld hl, StatusFlags2
|
||||||
bit 2, [hl]
|
bit 2, [hl]
|
||||||
jr nz, .asm_50712
|
jr nz, .not_in_bug_contest
|
||||||
callba GetMapEncounterRate
|
callba GetMapEncounterRate
|
||||||
ld a, b
|
ld a, b
|
||||||
and a
|
and a
|
||||||
jr z, .asm_5071e
|
jr z, .no_battle
|
||||||
callba ChooseWildEncounter
|
callba ChooseWildEncounter
|
||||||
jr nz, .asm_5071e
|
jr nz, .no_battle
|
||||||
jr .asm_50718
|
jr .start_battle
|
||||||
|
|
||||||
.asm_50712
|
.not_in_bug_contest
|
||||||
callba Function97d31
|
callba Function97d31
|
||||||
|
|
||||||
.asm_50718
|
.start_battle
|
||||||
ld a, $1
|
ld a, $1
|
||||||
ld [ScriptVar], a
|
ld [ScriptVar], a
|
||||||
ret
|
ret
|
||||||
|
|
||||||
.asm_5071e
|
.no_battle
|
||||||
xor a
|
xor a
|
||||||
ld [ScriptVar], a
|
ld [ScriptVar], a
|
||||||
ld [BattleType], a
|
ld [BattleType], a
|
||||||
|
Loading…
Reference in New Issue
Block a user