Battle Tower trainer text

This commit is contained in:
PikalaxALT 2015-11-03 22:35:36 -05:00
parent c5527a02ae
commit 91ea4a2f9b
9 changed files with 7812 additions and 7808 deletions

View File

@ -2469,32 +2469,32 @@ WinTrainerBattle: ; 3cfa4
call StdBattleTextBox call StdBattleTextBox
call IsMobileBattle call IsMobileBattle
jr z, .asm_3cff5 jr z, .mobile
ld a, [wLinkMode] ld a, [wLinkMode]
and a and a
ret nz ret nz
ld a, [InBattleTowerBattle] ld a, [InBattleTowerBattle]
bit 0, a bit 0, a
jr nz, .asm_3d006 jr nz, .battle_tower
call Function3ebd8 call Function3ebd8
ld c, $28 ld c, $28
call DelayFrames call DelayFrames
ld a, [BattleType] ld a, [BattleType]
cp BATTLETYPE_CANLOSE cp BATTLETYPE_CANLOSE
jr nz, .asm_3cfe8 jr nz, .skip_heal
predef HealParty predef HealParty
.asm_3cfe8 .skip_heal
ld a, [wc2cc] ld a, [wc2cc]
bit 0, a bit 0, a
jr nz, .asm_3cff2 jr nz, .skip_whatever_this_is
call Function3718 call Function3718
.asm_3cff2 .skip_whatever_this_is
jp Function3d02b jp Function3d02b
.asm_3cff5 .mobile
call Function3ebd8 call Function3ebd8
ld c, $28 ld c, $28
call DelayFrames call DelayFrames
@ -2502,13 +2502,13 @@ WinTrainerBattle: ; 3cfa4
callba Function4ea0a callba Function4ea0a
ret ret
.asm_3d006 .battle_tower
call Function3ebd8 call Function3ebd8
ld c, $28 ld c, $28
call DelayFrames call DelayFrames
call EmptyBattleTextBox call EmptyBattleTextBox
ld c, $3 ld c, $3
callba StoreText callba BattleTowerText
call Functiona80 call Functiona80
ld hl, wPayDayMoney ld hl, wPayDayMoney
ld a, [hli] ld a, [hli]
@ -3087,11 +3087,11 @@ LostBattle: ; 3d38e
ld a, [InBattleTowerBattle] ld a, [InBattleTowerBattle]
bit 0, a bit 0, a
jr nz, .asm_3d3bd jr nz, .battle_tower
ld a, [BattleType] ld a, [BattleType]
cp BATTLETYPE_CANLOSE cp BATTLETYPE_CANLOSE
jr nz, .asm_3d3e3 jr nz, .not_canlose
; Remove the enemy from the screen. ; Remove the enemy from the screen.
hlcoord 0, 0 hlcoord 0, 0
@ -3104,12 +3104,12 @@ LostBattle: ; 3d38e
ld a, [wc2cc] ld a, [wc2cc]
bit 0, a bit 0, a
jr nz, .asm_3d3bc jr nz, .skip
call Function3718 call Function3718
.asm_3d3bc .skip
ret ret
.asm_3d3bd .battle_tower
; Remove the enemy from the screen. ; Remove the enemy from the screen.
hlcoord 0, 0 hlcoord 0, 0
lb bc, 8, 21 lb bc, 8, 21
@ -3121,13 +3121,13 @@ LostBattle: ; 3d38e
call EmptyBattleTextBox call EmptyBattleTextBox
ld c, 2 ld c, 2
callba StoreText callba BattleTowerText
call Functiona80 call Functiona80
call ClearTileMap call ClearTileMap
call WhiteBGMap call WhiteBGMap
ret ret
.asm_3d3e3 .not_canlose
ld a, [wLinkMode] ld a, [wLinkMode]
and a and a
jr nz, .LostLinkBattle jr nz, .LostLinkBattle
@ -3141,7 +3141,7 @@ LostBattle: ; 3d38e
.LostLinkBattle .LostLinkBattle
call UpdateEnemyMonInParty call UpdateEnemyMonInParty
call CheckEnemyTrainerDefeated call CheckEnemyTrainerDefeated
jr nz, .asm_3d40a jr nz, .not_tied
ld hl, TiedAgainstText ld hl, TiedAgainstText
ld a, [wBattleResult] ld a, [wBattleResult]
and $c0 and $c0
@ -3149,10 +3149,10 @@ LostBattle: ; 3d38e
ld [wBattleResult], a ld [wBattleResult], a
jr .text jr .text
.asm_3d40a .not_tied
ld hl, LostAgainstText ld hl, LostAgainstText
call IsMobileBattle call IsMobileBattle
jr z, .asm_3d417 jr z, .mobile
.text .text
call StdBattleTextBox call StdBattleTextBox
@ -3161,7 +3161,7 @@ LostBattle: ; 3d38e
scf scf
ret ret
.asm_3d417 .mobile
; Remove the enemy from the screen. ; Remove the enemy from the screen.
hlcoord 0, 0 hlcoord 0, 0
lb bc, 8, 21 lb bc, 8, 21

View File

@ -236,7 +236,7 @@ ENDC
dw Script_halloffame dw Script_halloffame
dw Script_credits dw Script_credits
dw Script_warpfacing dw Script_warpfacing
dw Script_storetext dw Script_battletowertext
dw Script_displaylocation dw Script_displaylocation
dw Script_trainerclassname dw Script_trainerclassname
dw Script_name dw Script_name
@ -537,7 +537,7 @@ Script_interpretmenu: ; 0x96f41
ret ret
; 0x96f52 ; 0x96f52
Script_storetext: ; 0x96f52 Script_battletowertext: ; 0x96f52
; script command 0xa4 ; script command 0xa4
; parameters: ; parameters:
; pointer (PointerLabelBeforeBank) ; pointer (PointerLabelBeforeBank)
@ -546,7 +546,7 @@ Script_storetext: ; 0x96f52
call SetUpTextBox call SetUpTextBox
call GetScriptByte call GetScriptByte
ld c, a ld c, a
callba StoreText callba BattleTowerText
ret ret
; 0x96f60 ; 0x96f60
@ -2370,8 +2370,8 @@ Script_takeitem: ; 0x977f0
ld [CurItem], a ld [CurItem], a
call GetScriptByte call GetScriptByte
ld [wItemQuantityChangeBuffer], a ld [wItemQuantityChangeBuffer], a
ld a, $ff ld a, -1
ld [wd107], a ld [ItemCountBuffer], a
ld hl, NumItems ld hl, NumItems
call TossItem call TossItem
ret nc ret nc

View File

@ -25,7 +25,7 @@ FarCall_hl:: ; 2d63
push af push af
ld a, [hBuffer] ld a, [hBuffer]
rst Bankswitch rst Bankswitch
call Function2d82 call FarJump_hl
; 2d6e ; 2d6e
ReturnFarCall:: ; 2d6e ReturnFarCall:: ; 2d6e
@ -33,22 +33,22 @@ ReturnFarCall:: ; 2d6e
; To do this, we can pop to bc instead of af. ; To do this, we can pop to bc instead of af.
ld a, b ld a, b
ld [PredefAddress + 2], a ld [wFarCallBCBuffer], a
ld a, c ld a, c
ld [PredefAddress + 3], a ld [wFarCallBCBuffer + 1], a
; Restore the working bank. ; Restore the working bank.
pop bc pop bc
ld a, b ld a, b
rst Bankswitch rst Bankswitch
ld a, [PredefAddress + 2] ld a, [wFarCallBCBuffer]
ld b, a ld b, a
ld a, [PredefAddress + 3] ld a, [wFarCallBCBuffer + 1]
ld c, a ld c, a
ret ret
; 2d82 ; 2d82
Function2d82:: ; 2d82 FarJump_hl:: ; 2d82
jp [hl] jp [hl]
; 2d83 ; 2d83

View File

@ -1022,9 +1022,9 @@ warpfacing: macro
db \4 ; y db \4 ; y
endm endm
enum storetext_command enum battletowertext_command
storetext: macro battletowertext: macro
db storetext_command db battletowertext_command
db \1 ; memory db \1 ; memory
endm endm

View File

@ -27,7 +27,7 @@ Script_BattleRoomLoop: ; 0x9f425
waitbutton waitbutton
applymovement $2, MovementData_0x9e592 applymovement $2, MovementData_0x9e592
loadfont loadfont
storetext 1 battletowertext 1
keeptextopen keeptextopen
loadmovesprites loadmovesprites
special BattleTowerBattle ; calls predef startbattle special BattleTowerBattle ; calls predef startbattle

File diff suppressed because it is too large Load Diff

7773
misc/battle_tower_47.asm Executable file

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1279,7 +1279,7 @@ PredefTemp:: ; cfb5
ds 2 ds 2
PredefAddress:: ; cfb7 PredefAddress:: ; cfb7
ds 2 ds 2
wFarCallBCBuffer:: ; cfb9
ds 2 ds 2
wcfbb:: ds 1 wcfbb:: ds 1
@ -2658,10 +2658,10 @@ BT_OTPkmn3:: party_struct BT_OTPkmn3
BT_OTPkmn3Name:: ds PKMN_NAME_LENGTH BT_OTPkmn3Name:: ds PKMN_NAME_LENGTH
BT_OTrainerData:: ds $24 BT_OTrainerData:: ds $24
BT_OTrainerEnd:: ; we_d1e0 BT_OTrainerEnd:: ; w3_d1e0
ds $20 ds $20
BT_TrainerTextIndex::
ds $600 ds $600
wBTChoiceOfLvlGroup:: wBTChoiceOfLvlGroup::