2015-10-11 16:15:03 +00:00
Special_BankOfMom: ; 16218
2015-10-16 17:35:43 +00:00
ld a , [ hInMenu ]
2015-10-11 16:15:03 +00:00
push af
ld a , $ 1
2015-10-16 17:35:43 +00:00
ld [ hInMenu ], a
2015-10-11 16:15:03 +00:00
xor a
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-12-19 01:07:09 +00:00
.loop
2015-10-24 23:49:19 +00:00
ld a , [ wJumptableIndex ]
2015-10-11 16:15:03 +00:00
bit 7 , a
2015-12-19 01:07:09 +00:00
jr nz , .done
call .RunJumptable
jr .loop
2015-10-11 16:15:03 +00:00
2015-12-19 01:07:09 +00:00
.done
2015-10-11 16:15:03 +00:00
pop af
2015-10-16 17:35:43 +00:00
ld [ hInMenu ], a
2015-10-11 16:15:03 +00:00
ret
; 16233
2015-12-19 01:07:09 +00:00
.RunJumptable: ; 16233
2015-10-24 23:49:19 +00:00
ld a , [ wJumptableIndex ]
2015-10-11 16:15:03 +00:00
ld e , a
ld d , 0
2015-12-27 02:59:03 +00:00
ld hl , .dw
2015-10-11 16:15:03 +00:00
add hl , de
2016-05-04 15:46:23 +00:00
add hl , de
2015-10-11 16:15:03 +00:00
ld a , [ hli ]
ld h , [ hl ]
ld l , a
2017-06-09 21:01:10 +00:00
jp hl
2015-10-11 16:15:03 +00:00
; 16242
2016-04-10 19:01:49 +00:00
.dw ; 16242
2016-04-10 18:42:14 +00:00
2015-12-27 02:59:03 +00:00
dw .CheckIfBankInitialized
dw .InitializeBank
dw .IsThisAboutYourMoney
dw .AccessBankOfMom
dw .StoreMoney
dw .TakeMoney
dw .StopOrStartSavingMoney
dw .AskDST
dw .JustDoWhatYouCan
2015-10-11 16:15:03 +00:00
; 16254
2015-10-19 20:49:29 +00:00
.CheckIfBankInitialized: ; 16254
2015-11-13 05:49:27 +00:00
ld a , [ wMomSavingMoney ]
2015-10-11 16:15:03 +00:00
bit 7 , a
2015-10-19 20:49:29 +00:00
jr nz , .savingmoneyalready
2015-10-11 16:15:03 +00:00
set 7 , a
2015-11-13 05:49:27 +00:00
ld [ wMomSavingMoney ], a
2015-10-11 16:15:03 +00:00
ld a , $ 1
2015-10-19 20:49:29 +00:00
jr .done_0
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.savingmoneyalready
2015-10-11 16:15:03 +00:00
ld a , $ 2
2015-10-19 20:49:29 +00:00
.done_0
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
; 1626a
2015-10-19 20:49:29 +00:00
.InitializeBank: ; 1626a
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16649
call PrintText
call YesNoBox
2015-10-19 20:49:29 +00:00
jr c , .DontSaveMoney
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x1664e
call PrintText
2015-10-19 20:49:29 +00:00
ld a , % 10000001
jr .done_1
2015-10-11 16:15:03 +00:00
2016-04-10 18:42:14 +00:00
.DontSaveMoney:
2015-10-19 20:49:29 +00:00
ld a , % 10000000
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.done_1
2015-11-13 05:49:27 +00:00
ld [ wMomSavingMoney ], a
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16653
call PrintText
ld a , $ 8
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
; 16290
2015-10-19 20:49:29 +00:00
.IsThisAboutYourMoney: ; 16290
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16658
call PrintText
call YesNoBox
2015-10-19 20:49:29 +00:00
jr c , .nope
2015-10-11 16:15:03 +00:00
ld a , $ 3
2015-10-19 20:49:29 +00:00
jr .done_2
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.nope
2015-10-11 16:15:03 +00:00
call DS TChecks
ld a , $ 7
2015-10-19 20:49:29 +00:00
.done_2
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
; 162a8
2015-10-19 20:49:29 +00:00
.AccessBankOfMom: ; 162a8
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x1665d
call PrintText
2015-11-11 21:11:08 +00:00
call LoadStandardMenuDataHeader
2015-10-11 16:15:03 +00:00
ld hl , MenuDataHeader_0x166b5
call CopyMenuDataHeader
2015-12-15 23:59:49 +00:00
call VerticalMenu
2015-12-25 03:58:42 +00:00
call Cl oseWindow
2015-10-19 20:49:29 +00:00
jr c , .cancel
2015-12-15 23:59:49 +00:00
ld a , [ wMenuCursorY ]
2015-10-11 16:15:03 +00:00
cp $ 1
2015-10-19 20:49:29 +00:00
jr z , .withdraw
2015-10-11 16:15:03 +00:00
cp $ 2
2015-10-19 20:49:29 +00:00
jr z , .deposit
2015-10-11 16:15:03 +00:00
cp $ 3
2015-10-19 20:49:29 +00:00
jr z , .stopsaving
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.cancel
2015-10-11 16:15:03 +00:00
ld a , $ 7
2015-10-19 20:49:29 +00:00
jr .done_3
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.withdraw
2015-10-11 16:15:03 +00:00
ld a , $ 5
2015-10-19 20:49:29 +00:00
jr .done_3
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.deposit
2015-10-11 16:15:03 +00:00
ld a , $ 4
2015-10-19 20:49:29 +00:00
jr .done_3
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.stopsaving
2015-10-11 16:15:03 +00:00
ld a , $ 6
2015-10-19 20:49:29 +00:00
.done_3
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
; 162e0
2015-10-19 20:49:29 +00:00
.StoreMoney: ; 162e0
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16662
call PrintText
xor a
ld hl , StringBuffer2
ld [ hli ], a
2016-05-04 15:46:23 +00:00
ld [ hli ], a
2015-10-11 16:15:03 +00:00
ld [ hl ], a
ld a , $ 5
ld [ wcf64 ], a
2015-11-11 21:11:08 +00:00
call LoadStandardMenuDataHeader
2016-05-10 16:59:34 +00:00
call Mom_SetUpDepositMenu
call Mom_Wait10Frames
call Mom_WithdrawDepositMenuJoypad
2015-12-25 03:58:42 +00:00
call Cl oseWindow
2015-10-19 20:49:29 +00:00
jr c , .CancelDeposit
2015-10-11 16:15:03 +00:00
ld hl , StringBuffer2
ld a , [ hli ]
or [ hl ]
inc hl
or [ hl ]
2015-10-19 20:49:29 +00:00
jr z , .CancelDeposit
2015-10-11 16:15:03 +00:00
ld de , Money
ld bc , StringBuffer2
2015-10-30 03:32:11 +00:00
callba CompareMoney
2015-10-19 20:49:29 +00:00
jr c , .DontHaveThatMuchToDeposit
2015-10-11 16:15:03 +00:00
ld hl , StringBuffer2
ld de , StringBuffer2 + 3
2015-10-19 20:49:29 +00:00
ld bc , 3
2015-10-11 16:15:03 +00:00
call CopyBytes
2015-11-13 05:49:27 +00:00
ld bc , wMomsMoney
2015-10-11 16:15:03 +00:00
ld de , StringBuffer2
callba GiveMoney
2015-10-19 20:49:29 +00:00
jr c , .CantDepositThatMuch
2015-10-11 16:15:03 +00:00
ld bc , StringBuffer2 + 3
ld de , Money
callba TakeMoney
ld hl , StringBuffer2
2015-11-13 05:49:27 +00:00
ld de , wMomsMoney
2015-10-19 20:49:29 +00:00
ld bc , 3
2015-10-11 16:15:03 +00:00
call CopyBytes
ld de , SFX_TRANSACTION
call PlaySFX
call WaitSFX
ld hl , UnknownText_0x1668a
call PrintText
ld a , $ 8
2015-10-19 20:49:29 +00:00
jr .done_4
2015-10-11 16:15:03 +00:00
2016-04-10 18:42:14 +00:00
.DontHaveThatMuchToDeposit:
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x1667b
call PrintText
ret
2016-04-10 18:42:14 +00:00
.CantDepositThatMuch:
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16680
call PrintText
ret
2016-04-10 18:42:14 +00:00
.CancelDeposit:
2015-10-11 16:15:03 +00:00
ld a , $ 7
2015-10-19 20:49:29 +00:00
.done_4
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
; 16373
2015-10-19 20:49:29 +00:00
.TakeMoney: ; 16373
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16667
call PrintText
xor a
ld hl , StringBuffer2
ld [ hli ], a
2016-05-04 15:46:23 +00:00
ld [ hli ], a
2015-10-11 16:15:03 +00:00
ld [ hl ], a
ld a , $ 5
ld [ wcf64 ], a
2015-11-11 21:11:08 +00:00
call LoadStandardMenuDataHeader
2016-05-10 16:59:34 +00:00
call Mom_SetUpWithdrawMenu
call Mom_Wait10Frames
call Mom_WithdrawDepositMenuJoypad
2015-12-25 03:58:42 +00:00
call Cl oseWindow
2015-10-19 20:49:29 +00:00
jr c , .CancelWithdraw
2015-10-11 16:15:03 +00:00
ld hl , StringBuffer2
ld a , [ hli ]
or [ hl ]
inc hl
or [ hl ]
2015-10-19 20:49:29 +00:00
jr z , .CancelWithdraw
2015-10-11 16:15:03 +00:00
ld hl , StringBuffer2
ld de , StringBuffer2 + 3
ld bc , 3
call CopyBytes
2015-11-13 05:49:27 +00:00
ld de , wMomsMoney
2015-10-11 16:15:03 +00:00
ld bc , StringBuffer2
2015-10-30 03:32:11 +00:00
callba CompareMoney
2015-10-19 20:49:29 +00:00
jr c , .InsufficientFundsInBank
2015-10-11 16:15:03 +00:00
ld bc , Money
ld de , StringBuffer2
callba GiveMoney
2015-10-19 20:49:29 +00:00
jr c , .NotEnoughRoomInWallet
2015-10-11 16:15:03 +00:00
ld bc , StringBuffer2 + 3
2015-11-13 05:49:27 +00:00
ld de , wMomsMoney
2015-10-11 16:15:03 +00:00
callba TakeMoney
ld hl , StringBuffer2
ld de , Money
ld bc , 3
call CopyBytes
ld de , SFX_TRANSACTION
call PlaySFX
call WaitSFX
ld hl , UnknownText_0x1668f
call PrintText
ld a , $ 8
2015-10-19 20:49:29 +00:00
jr .done_5
2015-10-11 16:15:03 +00:00
2016-04-10 18:42:14 +00:00
.InsufficientFundsInBank:
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16671
call PrintText
ret
2016-04-10 18:42:14 +00:00
.NotEnoughRoomInWallet:
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16676
call PrintText
ret
2016-04-10 18:42:14 +00:00
.CancelWithdraw:
2015-10-19 20:49:29 +00:00
ld a , $ 7
2015-10-11 16:15:03 +00:00
2015-10-19 20:49:29 +00:00
.done_5
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
; 16406
2015-10-19 20:49:29 +00:00
.StopOrStartSavingMoney: ; 16406
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x1666c
call PrintText
call YesNoBox
2015-10-19 20:49:29 +00:00
jr c , .StopSavingMoney
2015-10-11 16:15:03 +00:00
ld a , $ 81
2015-11-13 05:49:27 +00:00
ld [ wMomSavingMoney ], a
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16685
call PrintText
ld a , $ 8
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
2016-04-10 18:42:14 +00:00
.StopSavingMoney:
2015-10-11 16:15:03 +00:00
ld a , $ 80
2015-11-13 05:49:27 +00:00
ld [ wMomSavingMoney ], a
2015-10-11 16:15:03 +00:00
ld a , $ 7
2015-10-24 23:49:19 +00:00
ld [ wJumptableIndex ], a
2015-10-11 16:15:03 +00:00
ret
; 1642d
2015-10-19 20:49:29 +00:00
.AskDST: ; 1642d
2015-10-11 16:15:03 +00:00
ld hl , UnknownText_0x16694
call PrintText
2015-10-19 20:49:29 +00:00
.JustDoWhatYouCan: ; 16433
2015-10-24 23:49:19 +00:00
ld hl , wJumptableIndex
2015-10-11 16:15:03 +00:00
set 7 , [ hl ]
ret
; 16439
DSTChecks: ; 16439
; check the time; avoid changing DST if doing so would change the current day
ld a , [ wDST ]
bit 7 , a
ld a , [ hHours ]
2015-12-19 01:07:09 +00:00
jr z , .NotDST
2015-10-11 16:15:03 +00:00
and a ; within one hour of 00:00?
jr z , .LostBooklet
jr .loop
2016-04-10 18:42:14 +00:00
.NotDST:
2015-10-11 16:15:03 +00:00
cp 23 ; within one hour of 23:00?
jr nz , .loop
; fallthrough
2016-04-10 18:42:14 +00:00
.LostBooklet:
2015-12-19 01:07:09 +00:00
call .ClearBox
2015-10-11 16:15:03 +00:00
bccoord 1 , 14
2015-12-19 01:07:09 +00:00
ld hl , .Text_AdjustClock
2016-05-08 18:11:24 +00:00
call PlaceHLTextAtBC
2015-10-11 16:15:03 +00:00
call YesNoBox
ret c
2015-12-19 01:07:09 +00:00
call .ClearBox
2015-10-11 16:15:03 +00:00
bccoord 1 , 14
2015-12-19 01:07:09 +00:00
ld hl , .Text_LostInstructionBooklet
2016-05-08 18:11:24 +00:00
call PlaceHLTextAtBC
2015-10-11 16:15:03 +00:00
ret
.loop
2015-12-19 01:07:09 +00:00
call .ClearBox
2015-10-11 16:15:03 +00:00
bccoord 1 , 14
ld a , [ wDST ]
bit 7 , a
2015-12-19 01:07:09 +00:00
jr z , .SetDST
ld hl , .Text_IsDSTOver
2016-05-08 18:11:24 +00:00
call PlaceHLTextAtBC
2015-10-11 16:15:03 +00:00
call YesNoBox
ret c
ld a , [ wDST ]
res 7 , a
ld [ wDST ], a
2015-12-19 01:07:09 +00:00
call .SetClockBack
call .ClearBox
2015-10-11 16:15:03 +00:00
bccoord 1 , 14
2015-12-19 01:07:09 +00:00
ld hl , .Text_SetClockBack
2016-05-08 18:11:24 +00:00
call PlaceHLTextAtBC
2015-10-11 16:15:03 +00:00
ret
2016-04-10 18:42:14 +00:00
.SetDST:
2015-12-19 01:07:09 +00:00
ld hl , .Text_SwitchToDST
2016-05-08 18:11:24 +00:00
call PlaceHLTextAtBC
2015-10-11 16:15:03 +00:00
call YesNoBox
ret c
ld a , [ wDST ]
set 7 , a
ld [ wDST ], a
2015-12-19 01:07:09 +00:00
call .SetClockForward
call .ClearBox
2015-10-11 16:15:03 +00:00
bccoord 1 , 14
2015-12-19 01:07:09 +00:00
ld hl , .Text_SetClockForward
2016-05-08 18:11:24 +00:00
call PlaceHLTextAtBC
2015-10-11 16:15:03 +00:00
ret
; 164b9
2015-12-19 01:07:09 +00:00
.SetClockForward: ; 164b9
2015-10-11 16:15:03 +00:00
ld a , [ StartHour ]
add 1
sub 24
2015-12-19 01:07:09 +00:00
jr nc , .DontLoopHourForward
2015-10-11 16:15:03 +00:00
add 24
2016-04-10 18:42:14 +00:00
.DontLoopHourForward:
2015-10-11 16:15:03 +00:00
ld [ StartHour ], a
ccf
ld a , [ StartDay ]
adc 0
ld [ StartDay ], a
ret
; 164d1
2015-12-19 01:07:09 +00:00
.SetClockBack: ; 164d1
2015-10-11 16:15:03 +00:00
ld a , [ StartHour ]
sub 1
2015-12-19 01:07:09 +00:00
jr nc , .DontLoopHourBack
2015-10-11 16:15:03 +00:00
add 24
2016-04-10 18:42:14 +00:00
.DontLoopHourBack:
2015-10-11 16:15:03 +00:00
ld [ StartHour ], a
ld a , [ StartDay ]
sbc 0
2015-12-19 01:07:09 +00:00
jr nc , .DontLoopDayBack
2015-10-11 16:15:03 +00:00
add 7
2016-04-10 18:42:14 +00:00
.DontLoopDayBack:
2015-10-11 16:15:03 +00:00
ld [ StartDay ], a
ret
; 164ea
2015-12-19 01:07:09 +00:00
.ClearBox: ; 164ea
2015-10-11 16:15:03 +00:00
hlcoord 1 , 14
2015-11-01 14:38:48 +00:00
lb bc , 3 , 18
2015-10-11 16:15:03 +00:00
call Cl earBox
ret
; 164f4
2015-12-19 01:07:09 +00:00
.Text_AdjustClock: ; 0x164f4
2015-10-11 16:15:03 +00:00
; Do you want to adjust your clock for Daylight Saving Time?
text_jump UnknownText_0x1c6095
db "@"
; 0x164f9
2015-12-19 01:07:09 +00:00
.Text_LostInstructionBooklet: ; 0x164f9
2015-10-11 16:15:03 +00:00
; I lost the instruction booklet for the POKéGEAR.
; Come back again in a while.
text_jump UnknownText_0x1c60d1
db "@"
; 0x164fe
2015-12-19 01:07:09 +00:00
.Text_SwitchToDST: ; 0x164fe
2015-10-11 16:15:03 +00:00
; Do you want to switch to Daylight Saving Time?
text_jump UnknownText_0x1c6000
db "@"
; 0x16503
2015-12-19 01:07:09 +00:00
.Text_SetClockForward: ; 0x16503
2015-10-11 16:15:03 +00:00
; I set the clock forward by one hour.
text_jump UnknownText_0x1c6030
db "@"
; 0x16508
2015-12-19 01:07:09 +00:00
.Text_IsDSTOver: ; 0x16508
2015-10-11 16:15:03 +00:00
; Is Daylight Saving Time over?
text_jump UnknownText_0x1c6056
db "@"
; 0x1650d
2015-12-19 01:07:09 +00:00
.Text_SetClockBack: ; 0x1650d
2015-10-11 16:15:03 +00:00
; I put the clock back one hour.
text_jump UnknownText_0x1c6075
db "@"
; 0x16512
2016-05-10 16:59:34 +00:00
Mom_SetUpWithdrawMenu: ; 16512
ld de , Mon_WithdrawString
jr Mom_ContinueMenuSetup
2015-10-11 16:15:03 +00:00
2016-05-10 16:59:34 +00:00
Mom_SetUpDepositMenu: ; 16517
ld de , Mom_DepositString
Mom_ContinueMenuSetup: ; 1651a
2015-10-11 16:15:03 +00:00
push de
xor a
ld [ hBGMapMode ], a
hlcoord 0 , 0
lb bc , 6 , 18
call TextBox
hlcoord 1 , 2
2016-05-10 16:59:34 +00:00
ld de , Mom_SavedString
2015-10-11 16:15:03 +00:00
call PlaceString
hlcoord 12 , 2
2015-11-13 05:49:27 +00:00
ld de , wMomsMoney
2015-10-11 16:15:03 +00:00
lb bc , PRINTNUM_MONEY | 3 , 6
call PrintNum
hlcoord 1 , 4
2016-05-10 16:59:34 +00:00
ld de , Mom_HeldString
2015-10-11 16:15:03 +00:00
call PlaceString
hlcoord 12 , 4
ld de , Money
lb bc , PRINTNUM_MONEY | 3 , 6
call PrintNum
hlcoord 1 , 6
pop de
call PlaceString
hlcoord 12 , 6
ld de , StringBuffer2
lb bc , PRINTNUM_MONEY | PRINTNUM_LEADINGZEROS | 3 , 6
call PrintNum
call UpdateSprites
2016-03-02 03:31:21 +00:00
call CGBOnly_LoadEDTile
2015-10-11 16:15:03 +00:00
ret
; 1656b
2016-05-10 16:59:34 +00:00
Mom_Wait10Frames: ; 1656b
2015-10-11 16:15:03 +00:00
ld c , 10
call DelayFrames
ret
; 16571
2016-05-10 16:59:34 +00:00
Mom_WithdrawDepositMenuJoypad: ; 16571
2015-10-11 16:15:03 +00:00
.loop
2015-10-17 16:58:26 +00:00
call JoyTextDelay
2015-10-11 16:15:03 +00:00
ld hl , hJoyPressed
ld a , [ hl ]
and B_BUTTON
jr nz , .pressedB
ld a , [ hl ]
and A_BUTTON
jr nz , .pressedA
call .dpadaction
xor a
ld [ hBGMapMode ], a
hlcoord 12 , 6
ld bc , 7
ld a , " "
call Byte Fill
hlcoord 12 , 6
ld de , StringBuffer2
lb bc , PRINTNUM_MONEY | PRINTNUM_LEADINGZEROS | 3 , 6
call PrintNum
2015-11-10 04:01:45 +00:00
ld a , [ hVBlankCounter ]
2015-10-11 16:15:03 +00:00
and $ 10
jr nz , .skip
hlcoord 13 , 6
ld a , [ wMomBankDigitCursorPosition ]
ld c , a
ld b , 0
add hl , bc
ld [ hl ], " "
.skip
call WaitBGMap
jr .loop
.pressedB
scf
ret
.pressedA
and a
ret
2016-05-10 16:59:34 +00:00
.dpadaction
2015-10-11 16:15:03 +00:00
ld hl , hJoyLast
ld a , [ hl ]
and D_UP
jr nz , .incrementdigit
ld a , [ hl ]
and D_DOWN
jr nz , .decrementdigit
ld a , [ hl ]
and D_LEFT
jr nz , .movecursorleft
ld a , [ hl ]
and D_RIGHT
jr nz , .movecursorright
and a
ret
.movecursorleft
ld hl , wMomBankDigitCursorPosition
ld a , [ hl ]
and a
ret z
dec [ hl ]
ret
.movecursorright
ld hl , wMomBankDigitCursorPosition
ld a , [ hl ]
cp 5
ret nc
inc [ hl ]
ret
.incrementdigit
ld hl , .DigitQuantities
call .getdigitquantity
ld c , l
ld b , h
ld de , StringBuffer2
callba GiveMoney
ret
.decrementdigit
ld hl , .DigitQuantities
call .getdigitquantity
ld c , l
ld b , h
ld de , StringBuffer2
callba TakeMoney
ret
2016-05-10 16:59:34 +00:00
.getdigitquantity
2015-10-11 16:15:03 +00:00
ld a , [ wMomBankDigitCursorPosition ]
push de
ld e , a
ld d , 0
add hl , de
2016-05-10 16:31:49 +00:00
add hl , de
add hl , de
2015-10-11 16:15:03 +00:00
pop de
ret
; 16613
.DigitQuantities: ; 16613
dt 100000
dt 10000
dt 1000
dt 100
dt 10
dt 1
dt 100000
dt 10000
dt 1000
dt 100
dt 10
dt 1
dt 900000
dt 90000
dt 9000
dt 900
dt 90
dt 9
; 16649
UnknownText_0x16649: ; 0x16649
; Wow, that's a cute #MON. Where did you get it? … So, you're leaving on an adventure… OK! I'll help too. But what can I do for you? I know! I'll save money for you. On a long journey, money's important. Do you want me to save your money?
text_jump UnknownText_0x1bd77f
db "@"
; 0x1664e
UnknownText_0x1664e: ; 0x1664e
; OK, I'll take care of your money.
text_jump UnknownText_0x1bd868
db "@"
; 0x16653
UnknownText_0x16653: ; 0x16653
; Be careful. #MON are your friends. You need to work as a team. Now, go on!
text_jump UnknownText_0x1bd88e
db "@"
; 0x16658
UnknownText_0x16658: ; 0x16658
; Hi! Welcome home! You're trying very hard, I see. I've kept your room tidy. Or is this about your money?
text_jump UnknownText_0x1bd8da
db "@"
; 0x1665d
UnknownText_0x1665d: ; 0x1665d
; What do you want to do?
text_jump UnknownText_0x1bd942
db "@"
; 0x16662
UnknownText_0x16662: ; 0x16662
; How much do you want to save?
text_jump UnknownText_0x1bd95b
db "@"
; 0x16667
UnknownText_0x16667: ; 0x16667
; How much do you want to take?
text_jump UnknownText_0x1bd97a
db "@"
; 0x1666c
UnknownText_0x1666c: ; 0x1666c
; Do you want to save some money?
text_jump UnknownText_0x1bd999
db "@"
; 0x16671
UnknownText_0x16671: ; 0x16671
; You haven't saved that much.
text_jump UnknownText_0x1bd9ba
db "@"
; 0x16676
UnknownText_0x16676: ; 0x16676
; You can't take that much.
text_jump UnknownText_0x1bd9d7
db "@"
; 0x1667b
UnknownText_0x1667b: ; 0x1667b
; You don't have that much.
text_jump UnknownText_0x1bd9f1
db "@"
; 0x16680
UnknownText_0x16680: ; 0x16680
; You can't save that much.
text_jump UnknownText_0x1bda0b
db "@"
; 0x16685
UnknownText_0x16685: ; 0x16685
; OK, I'll save your money. Trust me! , stick with it!
text_jump UnknownText_0x1bda25
db "@"
; 0x1668a
UnknownText_0x1668a: ; 0x1668a
; Your money's safe here! Get going!
text_jump UnknownText_0x1bda5b
db "@"
; 0x1668f
UnknownText_0x1668f: ; 0x1668f
; , don't give up!
text_jump UnknownText_0x1bda7e
db "@"
; 0x16694
UnknownText_0x16694: ; 0x16694
; Just do what you can.
text_jump UnknownText_0x1bda90
db "@"
; 0x16699
2016-05-10 16:59:34 +00:00
Mom_SavedString: ; 16699
2015-10-11 16:15:03 +00:00
db "SAVED@"
; 1669f
2016-05-10 16:59:34 +00:00
Mon_WithdrawString: ; 1669f
2015-10-11 16:15:03 +00:00
db "WITHDRAW@"
; 166a8
2016-05-10 16:59:34 +00:00
Mom_DepositString: ; 166a8
2015-10-11 16:15:03 +00:00
db "DEPOSIT@"
; 166b0
2016-05-10 16:59:34 +00:00
Mom_HeldString: ; 166b0
2015-10-11 16:15:03 +00:00
db "HELD@"
; 166b5
MenuDataHeader_0x166b5: ; 0x166b5
db $ 40 ; flags
db 00 , 00 ; start coords
db 10 , 10 ; end coords
dw MenuData2_0x166bd
db 1 ; default option
; 0x166bd
MenuData2_0x166bd: ; 0x166bd
db $ 80 ; flags
db 4 ; items
db "GET@"
db "SAVE@"
db "CHANGE@"
db "CANCEL@"
; 0x166d6