mirror of
https://github.com/zeldaret/ss
synced 2026-06-09 04:29:58 -04:00
d_lyt_deposit WIP
This commit is contained in:
@@ -1026,7 +1026,7 @@ d/lyt/d_lyt_deposit_stock.cpp:
|
||||
.sdata2 start:0x8057A058 end:0x8057A060
|
||||
.bss start:0x805B1430 end:0x805B1470
|
||||
|
||||
d/lyt/d_lyt_deposit_box.cpp:
|
||||
d/lyt/d_lyt_deposit_box_cursor.cpp:
|
||||
.text start:0x801578B0 end:0x80158288 align:16
|
||||
.rodata start:0x804E8218 end:0x804E8228
|
||||
.data start:0x80524BC8 end:0x80524CD0
|
||||
|
||||
+128
-119
@@ -8646,65 +8646,65 @@ __dt__33sFStateID_c<18dLytSkyGaugeMain_c>Fv = .text:0x80155AF0; // type:function
|
||||
__dt__29sFStateID_c<14dLytSkyGauge_c>Fv = .text:0x80155B50; // type:function size:0x58 scope:weak
|
||||
isSameName__29sFStateID_c<14dLytSkyGauge_c>CFPCc = .text:0x80155BB0; // type:function size:0x88 scope:weak
|
||||
isSameName__33sFStateID_c<18dLytSkyGaugeMain_c>CFPCc = .text:0x80155C40; // type:function size:0x88 scope:weak
|
||||
fn_80155CD0 = .text:0x80155CD0; // type:function size:0x4
|
||||
fn_80155CE0 = .text:0x80155CE0; // type:function size:0xC
|
||||
fn_80155CF0 = .text:0x80155CF0; // type:function size:0x4
|
||||
fn_80155D00 = .text:0x80155D00; // type:function size:0x1EC
|
||||
fn_80155EF0 = .text:0x80155EF0; // type:function size:0x10
|
||||
fn_80155F00 = .text:0x80155F00; // type:function size:0x114
|
||||
fn_80156020 = .text:0x80156020; // type:function size:0x10
|
||||
fn_80156030 = .text:0x80156030; // type:function size:0xE4
|
||||
fn_80156120 = .text:0x80156120; // type:function size:0x164
|
||||
fn_80156290 = .text:0x80156290; // type:function size:0x15C
|
||||
fn_801563F0 = .text:0x801563F0; // type:function size:0xE0
|
||||
fn_801564D0 = .text:0x801564D0; // type:function size:0x28
|
||||
fn_80156500 = .text:0x80156500; // type:function size:0x28
|
||||
fn_80156530 = .text:0x80156530; // type:function size:0xE0
|
||||
fn_80156610 = .text:0x80156610; // type:function size:0x3D4
|
||||
fn_801569F0 = .text:0x801569F0; // type:function size:0x88
|
||||
fn_80156A80 = .text:0x80156A80; // type:function size:0x1E0
|
||||
fn_80156C60 = .text:0x80156C60; // type:function size:0x14
|
||||
fn_80156C80 = .text:0x80156C80; // type:function size:0x58
|
||||
fn_80156CE0 = .text:0x80156CE0; // type:function size:0xD8
|
||||
fn_80156DC0 = .text:0x80156DC0; // type:function size:0xDC
|
||||
fn_80156EA0 = .text:0x80156EA0; // type:function size:0x1D4
|
||||
fn_80157080 = .text:0x80157080; // type:function size:0x14
|
||||
fn_801570A0 = .text:0x801570A0; // type:function size:0x54
|
||||
fn_80157100 = .text:0x80157100; // type:function size:0x54
|
||||
fn_80157160 = .text:0x80157160; // type:function size:0x58
|
||||
fn_801571C0 = .text:0x801571C0; // type:function size:0xC
|
||||
fn_801571D0 = .text:0x801571D0; // type:function size:0x18
|
||||
fn_801571F0 = .text:0x801571F0; // type:function size:0x48
|
||||
fn_80157240 = .text:0x80157240; // type:function size:0xC
|
||||
fn_80157250 = .text:0x80157250; // type:function size:0x48
|
||||
fn_801572A0 = .text:0x801572A0; // type:function size:0x10
|
||||
fn_801572B0 = .text:0x801572B0; // type:function size:0x8
|
||||
fn_801572C0 = .text:0x801572C0; // type:function size:0x8
|
||||
fn_801572D0 = .text:0x801572D0; // type:function size:0x8
|
||||
fn_801572E0 = .text:0x801572E0; // type:function size:0x11C
|
||||
fn_80157400 = .text:0x80157400; // type:function size:0xA4
|
||||
fn_801574B0 = .text:0x801574B0; // type:function size:0xA0
|
||||
fn_80157550 = .text:0x80157550; // type:function size:0x6C
|
||||
fn_801575C0 = .text:0x801575C0; // type:function size:0x58
|
||||
fn_80157620 = .text:0x80157620; // type:function size:0x30
|
||||
fn_80157650 = .text:0x80157650; // type:function size:0x30
|
||||
fn_80157680 = .text:0x80157680; // type:function size:0x30
|
||||
LytDepositStock__initStates = .text:0x801576B0; // type:function size:0x10C
|
||||
LytDepositStock__state_dtor = .text:0x801577C0; // type:function size:0x58
|
||||
fn_80157820 = .text:0x80157820; // type:function size:0x88
|
||||
fn_801578B0 = .text:0x801578B0; // type:function size:0x124
|
||||
fn_801579E0 = .text:0x801579E0; // type:function size:0x74
|
||||
fn_80157A60 = .text:0x80157A60; // type:function size:0x34
|
||||
fn_80157AA0 = .text:0x80157AA0; // type:function size:0xCC
|
||||
fn_80157B70 = .text:0x80157B70; // type:function size:0x14C
|
||||
fn_80157CC0 = .text:0x80157CC0; // type:function size:0x210
|
||||
fn_80157ED0 = .text:0x80157ED0; // type:function size:0x17C
|
||||
fn_80158050 = .text:0x80158050; // type:function size:0x44
|
||||
fn_801580A0 = .text:0x801580A0; // type:function size:0xC
|
||||
fn_801580B0 = .text:0x801580B0; // type:function size:0x1A8
|
||||
fn_80158260 = .text:0x80158260; // type:function size:0x8
|
||||
fn_80158270 = .text:0x80158270; // type:function size:0x8
|
||||
fn_80158280 = .text:0x80158280; // type:function size:0x8
|
||||
initializeState_None__18dLytDepositStock_cFv = .text:0x80155CD0; // type:function size:0x4
|
||||
executeState_None__18dLytDepositStock_cFv = .text:0x80155CE0; // type:function size:0xC
|
||||
finalizeState_None__18dLytDepositStock_cFv = .text:0x80155CF0; // type:function size:0x4
|
||||
build__18dLytDepositStock_cFPQ23d2d10ResAccIf_c = .text:0x80155D00; // type:function size:0x1EC
|
||||
changeState__87sStateMgr_c<18dLytDepositStock_c,20sStateMethodUsr_FI_c,12sFStateFct_c,13sStateIDChk_c>FRC12sStateIDIf_c = .text:0x80155EF0; // type:function size:0x10 scope:weak
|
||||
execute__18dLytDepositStock_cFv = .text:0x80155F00; // type:function size:0x114
|
||||
executeState__87sStateMgr_c<18dLytDepositStock_c,20sStateMethodUsr_FI_c,12sFStateFct_c,13sStateIDChk_c>Fv = .text:0x80156020; // type:function size:0x10 scope:weak
|
||||
remove__18dLytDepositStock_cFv = .text:0x80156030; // type:function size:0xE4
|
||||
initIcons__18dLytDepositStock_cFv = .text:0x80156120; // type:function size:0x164
|
||||
loadItems__18dLytDepositStock_cFl = .text:0x80156290; // type:function size:0x15C
|
||||
loadIcon__18dLytDepositStock_cFl = .text:0x801563F0; // type:function size:0xE0
|
||||
nextPage__18dLytDepositStock_cFb = .text:0x801564D0; // type:function size:0x28
|
||||
prevPage__18dLytDepositStock_cFb = .text:0x80156500; // type:function size:0x28
|
||||
fn_80156530__18dLytDepositStock_cFb = .text:0x80156530; // type:function size:0xE0
|
||||
handleNavOrPoint__18dLytDepositStock_cFv = .text:0x80156610; // type:function size:0x3D4
|
||||
navigateOffIcon__18dLytDepositStock_cFv = .text:0x801569F0; // type:function size:0x88
|
||||
checkNav__18dLytDepositStock_cFv = .text:0x80156A80; // type:function size:0x1E0
|
||||
getCurrentSlot__18dLytDepositStock_cCFv = .text:0x80156C60; // type:function size:0x14
|
||||
setItem__18dLytDepositStock_cFll = .text:0x80156C80; // type:function size:0x58
|
||||
realizeItem__18dLytDepositStock_cFl = .text:0x80156CE0; // type:function size:0xD8
|
||||
selectNavTarget__18dLytDepositStock_cFl = .text:0x80156DC0; // type:function size:0xDC
|
||||
pickUpItem__18dLytDepositStock_cFlb = .text:0x80156EA0; // type:function size:0x1D4
|
||||
navigateToPouch__18dLytDepositStock_cFv = .text:0x80157080; // type:function size:0x14
|
||||
navigateToSell__18dLytDepositStock_cFv = .text:0x801570A0; // type:function size:0x54
|
||||
navigateToSort__18dLytDepositStock_cFv = .text:0x80157100; // type:function size:0x54
|
||||
navigateToFinish__18dLytDepositStock_cFv = .text:0x80157160; // type:function size:0x58
|
||||
saveArrowDirection__18dLytDepositStock_cFv = .text:0x801571C0; // type:function size:0xC
|
||||
navigateToArrow__18dLytDepositStock_cFl = .text:0x801571D0; // type:function size:0x18
|
||||
restoreArrowDirection__18dLytDepositStock_cFv = .text:0x801571F0; // type:function size:0x48
|
||||
navigateToItem__18dLytDepositStock_cFv = .text:0x80157240; // type:function size:0xC
|
||||
handleSpecialNavMode__18dLytDepositStock_cFv = .text:0x80157250; // type:function size:0x48
|
||||
isNavModeItem__18dLytDepositStock_cCFv = .text:0x801572A0; // type:function size:0x10
|
||||
getName__18dLytDepositStock_cCFv = .text:0x801572B0; // type:function size:0x8 scope:weak
|
||||
getLyt__18dLytDepositStock_cFv = .text:0x801572C0; // type:function size:0x8 scope:weak
|
||||
getPane__18dLytDepositStock_cFv = .text:0x801572D0; // type:function size:0x8 scope:weak
|
||||
__dt__18dLytDepositStock_cFv = .text:0x801572E0; // type:function size:0x11C scope:weak
|
||||
__dt__57sFStateMgr_c<18dLytDepositStock_c,20sStateMethodUsr_FI_c>Fv = .text:0x80157400; // type:function size:0xA4 scope:weak
|
||||
__dt__87sStateMgr_c<18dLytDepositStock_c,20sStateMethodUsr_FI_c,12sFStateFct_c,13sStateIDChk_c>Fv = .text:0x801574B0; // type:function size:0xA0 scope:weak
|
||||
__dt__34sFStateFct_c<18dLytDepositStock_c>Fv = .text:0x80157550; // type:function size:0x6C scope:weak
|
||||
__dt__31sFState_c<18dLytDepositStock_c>Fv = .text:0x801575C0; // type:function size:0x58 scope:weak
|
||||
finalizeState__33sFStateID_c<18dLytDepositStock_c>CFR18dLytDepositStock_c = .text:0x80157620; // type:function size:0x30 scope:weak
|
||||
executeState__33sFStateID_c<18dLytDepositStock_c>CFR18dLytDepositStock_c = .text:0x80157650; // type:function size:0x30 scope:weak
|
||||
initializeState__33sFStateID_c<18dLytDepositStock_c>CFR18dLytDepositStock_c = .text:0x80157680; // type:function size:0x30 scope:weak
|
||||
__sinit_\d_lyt_deposit_stock_cpp = .text:0x801576B0; // type:function size:0x10C scope:local
|
||||
__dt__33sFStateID_c<18dLytDepositStock_c>Fv = .text:0x801577C0; // type:function size:0x58 scope:weak
|
||||
isSameName__33sFStateID_c<18dLytDepositStock_c>CFPCc = .text:0x80157820; // type:function size:0x88 scope:weak
|
||||
build__22dLytDepositBoxCursor_cFPQ23d2d10ResAccIf_c = .text:0x801578B0; // type:function size:0x124
|
||||
execute__22dLytDepositBoxCursor_cFv = .text:0x801579E0; // type:function size:0x74
|
||||
draw__22dLytDepositBoxCursor_cFv = .text:0x80157A60; // type:function size:0x34
|
||||
remove__22dLytDepositBoxCursor_cFv = .text:0x80157AA0; // type:function size:0xCC
|
||||
initIcon__22dLytDepositBoxCursor_cFv = .text:0x80157B70; // type:function size:0x14C
|
||||
realizeNav__22dLytDepositBoxCursor_cFv = .text:0x80157CC0; // type:function size:0x210
|
||||
init__22dLytDepositBoxCursor_cFlllb = .text:0x80157ED0; // type:function size:0x17C
|
||||
updateSlot__22dLytDepositBoxCursor_cFlllb = .text:0x80158050; // type:function size:0x44
|
||||
fn_801580A0__22dLytDepositBoxCursor_cFv = .text:0x801580A0; // type:function size:0xC
|
||||
__dt__22dLytDepositBoxCursor_cFv = .text:0x801580B0; // type:function size:0x1A8 scope:weak
|
||||
getName__22dLytDepositBoxCursor_cCFv = .text:0x80158260; // type:function size:0x8 scope:weak
|
||||
getLyt__22dLytDepositBoxCursor_cFv = .text:0x80158270; // type:function size:0x8 scope:weak
|
||||
getPane__22dLytDepositBoxCursor_cFv = .text:0x80158280; // type:function size:0x8 scope:weak
|
||||
fn_80158290 = .text:0x80158290; // type:function size:0x4
|
||||
fn_801582A0 = .text:0x801582A0; // type:function size:0x134
|
||||
fn_801583E0 = .text:0x801583E0; // type:function size:0x4
|
||||
@@ -9131,13 +9131,13 @@ fn_80166C50 = .text:0x80166C50; // type:function size:0x48
|
||||
fn_80166CA0 = .text:0x80166CA0; // type:function size:0x48
|
||||
getPouchItemNumberColor__Flb = .text:0x80166CF0; // type:function size:0x84
|
||||
isPouchBocoburinLocked__Fv = .text:0x80166D80; // type:function size:0x34
|
||||
getShieldDurability__Flb = .text:0x80166DC0; // type:function size:0xC8
|
||||
fn_80166E90 = .text:0x80166E90; // type:function size:0x3C
|
||||
fn_80166ED0 = .text:0x80166ED0; // type:function size:0x68
|
||||
fn_80166F40 = .text:0x80166F40; // type:function size:0x7C
|
||||
getPouchShieldDurability__Flb = .text:0x80166DC0; // type:function size:0xC8
|
||||
getDepositItemForSlot__Fl = .text:0x80166E90; // type:function size:0x3C
|
||||
getDepositItemAmount__Fl = .text:0x80166ED0; // type:function size:0x68
|
||||
getDepositItemNumberColor__Fl = .text:0x80166F40; // type:function size:0x7C
|
||||
fn_80166FC0 = .text:0x80166FC0; // type:function size:0x50
|
||||
fn_80167010 = .text:0x80167010; // type:function size:0x54
|
||||
fn_80167070 = .text:0x80167070; // type:function size:0xD4
|
||||
getDepositShieldDurability__Fl = .text:0x80167070; // type:function size:0xD4
|
||||
fn_80167150 = .text:0x80167150; // type:function size:0xF0
|
||||
getBWheelItemIdForIndex__Fl = .text:0x80167240; // type:function size:0x24
|
||||
fn_80167270 = .text:0x80167270; // type:function size:0x24
|
||||
@@ -28313,8 +28313,8 @@ lbl_804E7FF8 = .rodata:0x804E7FF8; // type:object size:0xD0 data:4byte
|
||||
lbl_804E80C8 = .rodata:0x804E80C8; // type:object size:0x30
|
||||
brlanMap = .rodata:0x804E80F8; // type:object size:0x40 scope:local data:4byte
|
||||
brlanMap = .rodata:0x804E8138; // type:object size:0x18 scope:local data:4byte
|
||||
lbl_804E8150 = .rodata:0x804E8150; // type:object size:0xC8 data:4byte
|
||||
lbl_804E8218 = .rodata:0x804E8218; // type:object size:0x10 data:4byte
|
||||
brlanMap = .rodata:0x804E8150; // type:object size:0xC8 scope:local data:4byte
|
||||
brlanMap = .rodata:0x804E8218; // type:object size:0x10 scope:local data:4byte
|
||||
lbl_804E8228 = .rodata:0x804E8228; // type:object size:0x20 data:4byte
|
||||
brlanMap = .rodata:0x804E8248; // type:object size:0x10 scope:local data:4byte
|
||||
sNavTable1 = .rodata:0x804E8258; // type:object size:0x128 scope:local
|
||||
@@ -34444,47 +34444,56 @@ __vt__31sFState_c<18dLytSkyGaugeMain_c> = .data:0x80524640; // type:object size:
|
||||
@7568 = .data:0x805248A0; // type:object size:0x1C scope:local data:string
|
||||
__vt__29sFStateID_c<14dLytSkyGauge_c> = .data:0x805248BC; // type:object size:0x34 scope:weak
|
||||
__vt__33sFStateID_c<18dLytSkyGaugeMain_c> = .data:0x805248F0; // type:object size:0x34 scope:weak
|
||||
lbl_80524928 = .data:0x80524928; // type:object size:0x1C data:string
|
||||
lbl_80524944 = .data:0x80524944; // type:object size:0xB data:string
|
||||
lbl_80524950 = .data:0x80524950; // type:object size:0xB data:string
|
||||
lbl_8052495C = .data:0x8052495C; // type:object size:0xB data:string
|
||||
lbl_80524968 = .data:0x80524968; // type:object size:0xB data:string
|
||||
lbl_80524974 = .data:0x80524974; // type:object size:0xB data:string
|
||||
lbl_80524980 = .data:0x80524980; // type:object size:0xB data:string
|
||||
lbl_8052498C = .data:0x8052498C; // type:object size:0xB data:string
|
||||
lbl_80524998 = .data:0x80524998; // type:object size:0xB data:string
|
||||
lbl_805249A4 = .data:0x805249A4; // type:object size:0xB data:string
|
||||
lbl_805249B0 = .data:0x805249B0; // type:object size:0xB data:string
|
||||
lbl_805249BC = .data:0x805249BC; // type:object size:0xB data:string
|
||||
lbl_805249C8 = .data:0x805249C8; // type:object size:0xB data:string
|
||||
lbl_805249D4 = .data:0x805249D4; // type:object size:0x1B data:string
|
||||
lbl_805249F0 = .data:0x805249F0; // type:object size:0xA data:string
|
||||
lbl_805249FC = .data:0x805249FC; // type:object size:0x1E data:string
|
||||
lbl_80524A1C = .data:0x80524A1C; // type:object size:0xB data:string
|
||||
lbl_80524A28 = .data:0x80524A28; // type:object size:0xB data:string
|
||||
lbl_80524A34 = .data:0x80524A34; // type:object size:0xB data:string
|
||||
lbl_80524A40 = .data:0x80524A40; // type:object size:0xB data:string
|
||||
lbl_80524A4C = .data:0x80524A4C; // type:object size:0xB data:string
|
||||
lbl_80524A58 = .data:0x80524A58; // type:object size:0xB data:string
|
||||
lbl_80524A64 = .data:0x80524A64; // type:object size:0xB data:string
|
||||
lbl_80524A70 = .data:0x80524A70; // type:object size:0xB data:string
|
||||
lbl_80524A7C = .data:0x80524A7C; // type:object size:0xB data:string
|
||||
lbl_80524A88 = .data:0x80524A88; // type:object size:0xB data:string
|
||||
lbl_80524A94 = .data:0x80524A94; // type:object size:0xB data:string
|
||||
lbl_80524AA0 = .data:0x80524AA0; // type:object size:0xB data:string
|
||||
lbl_80524AAC = .data:0x80524AAC; // type:object size:0x16 data:string
|
||||
lbl_80524AC4 = .data:0x80524AC4; // type:object size:0x9 data:string
|
||||
lbl_80524AD0 = .data:0x80524AD0; // type:object size:0x9 data:string
|
||||
jumptable_80524ADC = .data:0x80524ADC; // type:object size:0x24 scope:local
|
||||
lbl_80524B00 = .data:0x80524B00; // type:object size:0x90
|
||||
lbl_80524B90 = .data:0x80524B90; // type:object size:0x38
|
||||
lbl_80524BC8 = .data:0x80524BC8; // type:object size:0x1F data:string
|
||||
lbl_80524BE8 = .data:0x80524BE8; // type:object size:0xA data:string
|
||||
lbl_80524BF4 = .data:0x80524BF4; // type:object size:0x26 data:string
|
||||
lbl_80524C1C = .data:0x80524C1C; // type:object size:0x54
|
||||
lbl_80524C70 = .data:0x80524C70; // type:object size:0x9 data:string
|
||||
lbl_80524C7C = .data:0x80524C7C; // type:object size:0x9 data:string
|
||||
lbl_80524C88 = .data:0x80524C88; // type:object size:0x48
|
||||
@20839 = .data:0x80524928; // type:object size:0x1C scope:local data:string
|
||||
...data.0 = .data:0x80524928; // type:label scope:local
|
||||
@20840 = .data:0x80524944; // type:object size:0xB scope:local data:string
|
||||
@20841 = .data:0x80524950; // type:object size:0xB scope:local data:string
|
||||
@20842 = .data:0x8052495C; // type:object size:0xB scope:local data:string
|
||||
@20843 = .data:0x80524968; // type:object size:0xB scope:local data:string
|
||||
@20844 = .data:0x80524974; // type:object size:0xB scope:local data:string
|
||||
@20845 = .data:0x80524980; // type:object size:0xB scope:local data:string
|
||||
@20846 = .data:0x8052498C; // type:object size:0xB scope:local data:string
|
||||
@20847 = .data:0x80524998; // type:object size:0xB scope:local data:string
|
||||
@20848 = .data:0x805249A4; // type:object size:0xB scope:local data:string
|
||||
@20849 = .data:0x805249B0; // type:object size:0xB scope:local data:string
|
||||
@20850 = .data:0x805249BC; // type:object size:0xB scope:local data:string
|
||||
@20851 = .data:0x805249C8; // type:object size:0xB scope:local data:string
|
||||
@20852 = .data:0x805249D4; // type:object size:0x1B scope:local data:string
|
||||
@20853 = .data:0x805249F0; // type:object size:0xA scope:local data:string
|
||||
@20854 = .data:0x805249FC; // type:object size:0x1E scope:local data:string
|
||||
@20855 = .data:0x80524A1C; // type:object size:0xB scope:local data:string
|
||||
@20856 = .data:0x80524A28; // type:object size:0xB scope:local data:string
|
||||
@20857 = .data:0x80524A34; // type:object size:0xB scope:local data:string
|
||||
@20858 = .data:0x80524A40; // type:object size:0xB scope:local data:string
|
||||
@20859 = .data:0x80524A4C; // type:object size:0xB scope:local data:string
|
||||
@20860 = .data:0x80524A58; // type:object size:0xB scope:local data:string
|
||||
@20861 = .data:0x80524A64; // type:object size:0xB scope:local data:string
|
||||
@20862 = .data:0x80524A70; // type:object size:0xB scope:local data:string
|
||||
@20863 = .data:0x80524A7C; // type:object size:0xB scope:local data:string
|
||||
@20864 = .data:0x80524A88; // type:object size:0xB scope:local data:string
|
||||
@20865 = .data:0x80524A94; // type:object size:0xB scope:local data:string
|
||||
@20866 = .data:0x80524AA0; // type:object size:0xB scope:local data:string
|
||||
@22440 = .data:0x80524AAC; // type:object size:0x16 scope:local data:string
|
||||
@21015 = .data:0x80524AC4; // type:object size:0x9 scope:local data:string
|
||||
@22588 = .data:0x80524AD0; // type:object size:0x9 scope:local data:string
|
||||
@22727 = .data:0x80524ADC; // type:object size:0x24 scope:local
|
||||
__vt__18dLytDepositStock_c = .data:0x80524B00; // type:object size:0x34
|
||||
@22972 = .data:0x80524B48; // type:object size:0xC scope:local
|
||||
@22973 = .data:0x80524B54; // type:object size:0xC scope:local
|
||||
@22974 = .data:0x80524B60; // type:object size:0xC scope:local
|
||||
@22976 = .data:0x80524B6C; // type:object size:0x21 scope:local data:string
|
||||
__vt__33sFStateID_c<18dLytDepositStock_c> = .data:0x80524B90; // type:object size:0x34 scope:weak
|
||||
@12893 = .data:0x80524BC8; // type:object size:0x1F scope:local data:string
|
||||
...data.0 = .data:0x80524BC8; // type:label scope:local
|
||||
@12894 = .data:0x80524BE8; // type:object size:0xA scope:local data:string
|
||||
@12895 = .data:0x80524BF4; // type:object size:0x26 scope:local data:string
|
||||
@12896 = .data:0x80524C1C; // type:object size:0x11 scope:local data:string
|
||||
@13676 = .data:0x80524C30; // type:object size:0x1A scope:local data:string
|
||||
@13678 = .data:0x80524C4C; // type:object size:0x11 scope:local data:string
|
||||
@13679 = .data:0x80524C60; // type:object size:0xD scope:local data:string
|
||||
@13007 = .data:0x80524C70; // type:object size:0x9 scope:local data:string
|
||||
@13789 = .data:0x80524C7C; // type:object size:0x9 scope:local data:string
|
||||
__vt__22dLytDepositBoxCursor_c = .data:0x80524C88; // type:object size:0x34
|
||||
lbl_80524CD0 = .data:0x80524CD0; // type:object size:0xF data:string
|
||||
lbl_80524CE0 = .data:0x80524CE0; // type:object size:0x16 data:string
|
||||
lbl_80524CF8 = .data:0x80524CF8; // type:object size:0xB data:string
|
||||
@@ -40405,10 +40414,10 @@ lbl_8057285C = .sdata:0x8057285C; // type:object size:0x7 data:string
|
||||
lbl_80572978 = .sdata:0x80572978; // type:object size:0x8 data:4byte
|
||||
lbl_80572980 = .sdata:0x80572980; // type:object size:0x4 data:4byte
|
||||
lbl_80572984 = .sdata:0x80572984; // type:object size:0x4
|
||||
lbl_80572988 = .sdata:0x80572988; // type:object size:0x4 data:4byte
|
||||
lbl_8057298C = .sdata:0x8057298C; // type:object size:0x4
|
||||
lbl_80572990 = .sdata:0x80572990; // type:object size:0x4 data:4byte
|
||||
lbl_80572994 = .sdata:0x80572994; // type:object size:0x4
|
||||
sGroupName = .sdata:0x80572988; // type:object size:0x4 scope:local data:4byte
|
||||
@22589 = .sdata:0x8057298C; // type:object size:0x1 scope:local
|
||||
sGroupName = .sdata:0x80572990; // type:object size:0x4 scope:local data:4byte
|
||||
@13790 = .sdata:0x80572994; // type:object size:0x1 scope:local
|
||||
lbl_80572998 = .sdata:0x80572998; // type:object size:0x8
|
||||
lbl_805729A0 = .sdata:0x805729A0; // type:object size:0x8 data:4byte
|
||||
lbl_805729A8 = .sdata:0x805729A8; // type:object size:0x8 data:wstring
|
||||
@@ -45639,12 +45648,12 @@ lbl_8057A030 = .sdata2:0x8057A030; // type:object size:0x4 align:4 data:float
|
||||
@7352 = .sdata2:0x8057A048; // type:object size:0x4 scope:local align:4 data:float
|
||||
@7353 = .sdata2:0x8057A04C; // type:object size:0x4 scope:local align:4 data:float
|
||||
@7357 = .sdata2:0x8057A050; // type:object size:0x8 scope:local align:8 data:double
|
||||
lbl_8057A058 = .sdata2:0x8057A058; // type:object size:0x4 align:4 data:float
|
||||
lbl_8057A05C = .sdata2:0x8057A05C; // type:object size:0x4 align:4 data:float
|
||||
lbl_8057A060 = .sdata2:0x8057A060; // type:object size:0x4 align:4 data:float
|
||||
lbl_8057A064 = .sdata2:0x8057A064; // type:object size:0x4 align:4 data:float
|
||||
lbl_8057A068 = .sdata2:0x8057A068; // type:object size:0x4 align:4 data:float
|
||||
lbl_8057A070 = .sdata2:0x8057A070; // type:object size:0x8 align:8 data:double
|
||||
@22441 = .sdata2:0x8057A058; // type:object size:0x4 scope:local align:4 data:float
|
||||
@22442 = .sdata2:0x8057A05C; // type:object size:0x4 scope:local align:4 data:float
|
||||
@13677 = .sdata2:0x8057A060; // type:object size:0x4 scope:local align:4 data:float
|
||||
@13878 = .sdata2:0x8057A064; // type:object size:0x4 scope:local align:4 data:float
|
||||
@13879 = .sdata2:0x8057A068; // type:object size:0x4 scope:local align:4 data:float
|
||||
@13882 = .sdata2:0x8057A070; // type:object size:0x8 scope:local align:8 data:double
|
||||
lbl_8057A078 = .sdata2:0x8057A078; // type:object size:0x4 align:4 data:float
|
||||
lbl_8057A07C = .sdata2:0x8057A07C; // type:object size:0x4 align:4 data:float
|
||||
lbl_8057A080 = .sdata2:0x8057A080; // type:object size:0x4 align:4 data:float
|
||||
@@ -51970,8 +51979,8 @@ StateID_In__14dLytSkyGauge_c = .bss:0x805B1380; // type:object size:0x30 data:4b
|
||||
StateID_Move__14dLytSkyGauge_c = .bss:0x805B13C0; // type:object size:0x30 data:4byte
|
||||
@6397 = .bss:0x805B13F0; // type:object size:0xC scope:local
|
||||
StateID_Out__14dLytSkyGauge_c = .bss:0x805B1400; // type:object size:0x30 data:4byte
|
||||
lbl_805B1430 = .bss:0x805B1430; // type:object size:0x10
|
||||
LytDepositStock__STATE_NONE = .bss:0x805B1440; // type:object size:0x30 data:4byte
|
||||
@20826 = .bss:0x805B1430; // type:object size:0xC scope:local
|
||||
StateID_None__18dLytDepositStock_c = .bss:0x805B1440; // type:object size:0x30 data:4byte
|
||||
lbl_805B1470 = .bss:0x805B1470; // type:object size:0x10
|
||||
LytBossGauge__STATE_NONE = .bss:0x805B1480; // type:object size:0x40 data:4byte
|
||||
LytBossGauge__STATE_IN = .bss:0x805B14C0; // type:object size:0x40 data:4byte
|
||||
|
||||
+2
-2
@@ -562,8 +562,8 @@ config.libs = [
|
||||
Object(NonMatching, "d/lyt/d_lyt_system_window.cpp"),
|
||||
Object(Matching, "d/lyt/d_lyt_bird_gauge.cpp"),
|
||||
Object(Matching, "d/lyt/d_lyt_sky_gauge.cpp"),
|
||||
Object(NonMatching, "d/lyt/d_lyt_deposit_stock.cpp"),
|
||||
Object(NonMatching, "d/lyt/d_lyt_deposit_box.cpp"),
|
||||
Object(Matching, "d/lyt/d_lyt_deposit_stock.cpp"),
|
||||
Object(Matching, "d/lyt/d_lyt_deposit_box_cursor.cpp"),
|
||||
Object(NonMatching, "d/lyt/d_lyt_boss_gauge.cpp"),
|
||||
Object(Matching, "d/lyt/d_lyt_pause_back.cpp"),
|
||||
Object(NonMatching, "d/lyt/d_lyt_pause_disp_00.cpp"),
|
||||
|
||||
@@ -52,10 +52,18 @@ public:
|
||||
mCursorStick.setShouldBeOn(visible);
|
||||
}
|
||||
|
||||
bool isCursorStickVisible() const {
|
||||
return mCursorStick.getShouldBeOn();
|
||||
}
|
||||
|
||||
void setCursorStickTargetPane(const nw4r::lyt::Pane *target) {
|
||||
mCursorStick.setTargetPane(target);
|
||||
}
|
||||
|
||||
const nw4r::lyt::Pane *getCursorStickAllPane() const {
|
||||
return mCursorStick.getAllPane();
|
||||
}
|
||||
|
||||
private:
|
||||
static dCsBase_c *sInstance;
|
||||
void setCurrentLyt(int lyt);
|
||||
|
||||
@@ -29,10 +29,18 @@ public:
|
||||
mShouldBeOn = value;
|
||||
}
|
||||
|
||||
bool getShouldBeOn() const {
|
||||
return mShouldBeOn;
|
||||
}
|
||||
|
||||
static dLytCursorStick_c *GetInstance() {
|
||||
return sInstance;
|
||||
}
|
||||
|
||||
const nw4r::lyt::Pane *getAllPane() const {
|
||||
return mpPanes[0];
|
||||
}
|
||||
|
||||
private:
|
||||
bool build_();
|
||||
bool remove_();
|
||||
|
||||
@@ -0,0 +1,55 @@
|
||||
#ifndef D_LYT_DEPOSIT_BOX_CURSOR_H
|
||||
#define D_LYT_DEPOSIT_BOX_CURSOR_H
|
||||
|
||||
#include "d/lyt/d2d.h"
|
||||
#include "d/lyt/d_lyt_common_icon_item.h"
|
||||
#include "nw4r/lyt/lyt_pane.h"
|
||||
|
||||
class dLytDepositBoxCursor_c : public d2d::dSubPane {
|
||||
public:
|
||||
enum ItemLocation_e {
|
||||
LOC_POUCH,
|
||||
LOC_DEPOSIT,
|
||||
};
|
||||
|
||||
public:
|
||||
/* vt 0x0C */ virtual bool build(d2d::ResAccIf_c *resAcc) override;
|
||||
/* vt 0x10 */ virtual bool remove() override;
|
||||
/* vt 0x14 */ virtual bool execute() override;
|
||||
/* vt 0x18 */ virtual nw4r::lyt::Pane *getPane() override {
|
||||
return mLyt.getLayout()->GetRootPane();
|
||||
}
|
||||
/* vt 0x1C */ virtual d2d::LytBase_c *getLyt() override {
|
||||
return &mLyt;
|
||||
}
|
||||
/* vt 0x20 */ virtual const char *getName() const override {
|
||||
return mLyt.getName();
|
||||
}
|
||||
|
||||
/* vt 0x08 */ virtual ~dLytDepositBoxCursor_c() {}
|
||||
|
||||
bool draw();
|
||||
|
||||
void init(s32 location, s32 slot, s32 item, bool unk);
|
||||
void updateSlot(s32 location, s32 slot, s32 unk, bool unk2);
|
||||
void fn_801580A0();
|
||||
|
||||
private:
|
||||
void initIcon();
|
||||
void realizeNav();
|
||||
|
||||
/* 0x008 */ d2d::dLytSub mLyt;
|
||||
/* 0x09C */ d2d::AnmGroup_c mAnm[2];
|
||||
/* 0x11C */ nw4r::lyt::Pane *mpStickCursorPane;
|
||||
/* 0x120 */ nw4r::lyt::Pane *mpGetIconPane;
|
||||
/* 0x124 */ dLytCommonIconItem_c mIcon;
|
||||
/* 0x930 */ d2d::SubPaneList mSubpaneList;
|
||||
/* 0x938 */ d2d::SubPaneListNode mNode;
|
||||
/* 0x948 */ bool mIsVisible;
|
||||
/* 0x948 */ bool field_0x949;
|
||||
/* 0x94C */ s32 mSlot;
|
||||
/* 0x950 */ s32 field_0x950;
|
||||
/* 0x954 */ s32 mItemLocation;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,113 @@
|
||||
#ifndef D_LYT_DEPOSIT_STOCK_H
|
||||
#define D_LYT_DEPOSIT_STOCK_H
|
||||
|
||||
#include "d/lyt/d2d.h"
|
||||
#include "d/lyt/d_lyt_common_icon_item.h"
|
||||
#include "nw4r/lyt/lyt_pane.h"
|
||||
#include "s/s_State.hpp"
|
||||
|
||||
class dLytDepositStock_c : public d2d::dSubPane {
|
||||
public:
|
||||
enum ArrowDirection_e {
|
||||
ARROW_LEFT,
|
||||
ARROW_RIGHT,
|
||||
|
||||
ARROW_NONE,
|
||||
};
|
||||
|
||||
enum NavMode_e {
|
||||
NAV_ITEM,
|
||||
NAV_SELL,
|
||||
NAV_SORT,
|
||||
NAV_FINISH,
|
||||
NAV_ARROW,
|
||||
};
|
||||
|
||||
public:
|
||||
dLytDepositStock_c() : mStateMgr(*this) {}
|
||||
virtual ~dLytDepositStock_c() {}
|
||||
|
||||
/* vt 0x0C */ virtual bool build(d2d::ResAccIf_c *resAcc) override;
|
||||
/* vt 0x10 */ virtual bool remove() override;
|
||||
/* vt 0x14 */ virtual bool execute() override;
|
||||
/* vt 0x18 */ virtual nw4r::lyt::Pane *getPane() override {
|
||||
return mLyt.getLayout()->GetRootPane();
|
||||
}
|
||||
/* vt 0x1C */ virtual d2d::LytBase_c *getLyt() override {
|
||||
return &mLyt;
|
||||
}
|
||||
/* vt 0x20 */ virtual const char *getName() const override {
|
||||
return mLyt.getName();
|
||||
}
|
||||
|
||||
void nextPage(bool unk);
|
||||
void prevPage(bool unk);
|
||||
void fn_80156530(bool unk);
|
||||
|
||||
void navigateToSell();
|
||||
void navigateToSort();
|
||||
void navigateToFinish();
|
||||
void saveArrowDirection();
|
||||
void navigateToArrow(s32 arrowDirection);
|
||||
s32 restoreArrowDirection();
|
||||
void handleSpecialNavMode();
|
||||
bool isNavModeItem() const;
|
||||
void navigateOffIcon();
|
||||
void handleNavOrPoint();
|
||||
|
||||
void pickUpItem(s32 slot, bool unk);
|
||||
void selectNavTarget(s32 idx);
|
||||
void setItem(s32 idx, s32 item);
|
||||
s32 getCurrentSlot() const;
|
||||
|
||||
STATE_MGR_DEFINE_UTIL_EXECUTESTATE(dLytDepositStock_c);
|
||||
|
||||
private:
|
||||
static const s32 NUM_ICONS_PER_PAGE = 12;
|
||||
static const s32 NUM_PAGES = 5;
|
||||
|
||||
void initIcons();
|
||||
void navigateToItem();
|
||||
void loadItems(s32 hiddenSlot);
|
||||
void loadIcon(s32 idx);
|
||||
void navigateToPouch();
|
||||
void realizeItem(s32 idx);
|
||||
|
||||
/**
|
||||
* Check if the FS stick is pushed in a direction. Diagonal movements
|
||||
* are adjusted to horizontal and vertical navigations if necessary.
|
||||
* @returns FS stick direction
|
||||
*/
|
||||
s32 checkNav();
|
||||
|
||||
STATE_FUNC_DECLARE(dLytDepositStock_c, None);
|
||||
|
||||
/* 0x0008 */ UI_STATE_MGR_DECLARE(dLytDepositStock_c);
|
||||
/* 0x0044 */ d2d::dLytSub mLyt;
|
||||
/* 0x00D8 */ d2d::AnmGroup_c mAnm[25];
|
||||
/* 0x0718 */ dLytCommonIconItem_c mIcons[NUM_ICONS_PER_PAGE];
|
||||
/* 0x6778 */ d2d::SubPaneList mSubpaneList;
|
||||
/* 0x6784 */ d2d::SubPaneListNode mNodes[NUM_ICONS_PER_PAGE];
|
||||
/* 0x6844 */ bool field_0x6844;
|
||||
/* 0x6845 */ bool field_0x6845;
|
||||
/* 0x6846 */ bool field_0x6846;
|
||||
/* 0x6847 */ bool field_0x6847;
|
||||
/* 0x6848 */ bool field_0x6848;
|
||||
/* 0x6849 */ bool field_0x6849;
|
||||
/* 0x684A */ bool field_0x684A;
|
||||
/* 0x684B */ bool field_0x684B;
|
||||
/* 0x684C */ bool field_0x684C;
|
||||
/* 0x684D */ bool field_0x684D;
|
||||
/* 0x684E */ bool field_0x684E;
|
||||
/* 0x6850 */ s32 mCurrentNavTarget;
|
||||
/* 0x6854 */ UNKWORD field_0x6854;
|
||||
/* 0x6858 */ s32 mSelectedItemId;
|
||||
/* 0x685C */ UNKWORD field_0x685C;
|
||||
/* 0x6860 */ s32 mArrowDirection;
|
||||
/* 0x6864 */ s32 mSavedArrowDirection;
|
||||
/* 0x6868 */ s32 mNavMode;
|
||||
/* 0x686C */ u8 mItemIds[NUM_ICONS_PER_PAGE];
|
||||
/* 0x6878 */ u8 mItemPage;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -74,9 +74,14 @@ u8 getPouchItemForSlot(s32 slot, bool unk);
|
||||
bool hasPouchSlot(s32 slot, bool unk);
|
||||
s32 getPouchItemAmount(s32 slot, bool unk);
|
||||
u8 getPouchItemNumberColor(s32 slot, bool unk);
|
||||
f32 getShieldDurability(s32 slot, bool unk);
|
||||
f32 getPouchShieldDurability(s32 slot, bool unk);
|
||||
u32 getPouchItemIdForIndex(s32 slot, bool unk);
|
||||
|
||||
u8 getDepositItemForSlot(s32 slot);
|
||||
s32 getDepositItemAmount(s32 slot);
|
||||
u8 getDepositItemNumberColor(s32 slot);
|
||||
f32 getDepositShieldDurability(s32 slot);
|
||||
|
||||
// TODO - rename and make sense of these
|
||||
DowsingTarget::DowsingSlot dowsingSlotForIndex(s32 index);
|
||||
u8 getLytIndexForDowsingIndex(s32 index);
|
||||
|
||||
@@ -0,0 +1,203 @@
|
||||
#include "d/lyt/d_lyt_deposit_box_cursor.h"
|
||||
|
||||
#include "common.h"
|
||||
#include "d/d_cs_base.h"
|
||||
#include "d/d_pad_nav.h"
|
||||
#include "d/lyt/d2d.h"
|
||||
#include "d/lyt/d_lyt_common_icon_item.h"
|
||||
#include "d/lyt/d_lyt_util_items.h"
|
||||
#include "m/m_vec.h"
|
||||
#include "nw4r/lyt/lyt_group.h"
|
||||
#include "nw4r/lyt/lyt_pane.h"
|
||||
#include "nw4r/math/math_types.h"
|
||||
#include "toBeSorted/arc_managers/layout_arc_manager.h"
|
||||
|
||||
static const d2d::LytBrlanMapping brlanMap[] = {
|
||||
{ "depositBoxCursor_00_loop.brlan", "G_loop_00"},
|
||||
{"depositBoxCursor_00_stickCursor.brlan", "G_stickCursor_00"},
|
||||
};
|
||||
|
||||
#define DEPOSIT_BOX_CURSOR_ANIM_LOOP 0
|
||||
#define DEPOSIT_BOX_CURSOR_ANIM_STICK_CURSOR 1
|
||||
|
||||
#define DEPOSIT_BOX_CURSOR_NUM_ANIMS 2
|
||||
|
||||
bool dLytDepositBoxCursor_c::build(d2d::ResAccIf_c *resAcc) {
|
||||
mLyt.setResAcc(resAcc);
|
||||
mLyt.build("depositBoxCursor_00.brlyt", nullptr);
|
||||
mLyt.setPriority(0x88);
|
||||
|
||||
for (int i = 0; i < DEPOSIT_BOX_CURSOR_NUM_ANIMS; i++) {
|
||||
mAnm[i].init(brlanMap[i].mFile, resAcc, mLyt.getLayout(), brlanMap[i].mName);
|
||||
mAnm[i].bind(false);
|
||||
mAnm[i].setAnimEnable(false);
|
||||
}
|
||||
|
||||
mAnm[DEPOSIT_BOX_CURSOR_ANIM_LOOP].setAnimEnable(true);
|
||||
mAnm[DEPOSIT_BOX_CURSOR_ANIM_LOOP].setFrame(0.0f);
|
||||
mLyt.calc();
|
||||
|
||||
mpStickCursorPane = mLyt.findPane("N_stickCursor_00");
|
||||
mpGetIconPane = mLyt.findPane("N_getIcon_00");
|
||||
initIcon();
|
||||
mIsVisible = false;
|
||||
field_0x949 = false;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool dLytDepositBoxCursor_c::execute() {
|
||||
realizeNav();
|
||||
mAnm[DEPOSIT_BOX_CURSOR_ANIM_LOOP].play();
|
||||
if (mIsVisible) {
|
||||
mNode.mpLytPane->execute();
|
||||
}
|
||||
mLyt.calc();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool dLytDepositBoxCursor_c::draw() {
|
||||
if (mIsVisible) {
|
||||
mLyt.addToDrawList();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool dLytDepositBoxCursor_c::remove() {
|
||||
for (d2d::SubPaneList::Iterator it = mSubpaneList.GetBeginIter(); it != mSubpaneList.GetEndIter(); ++it) {
|
||||
d2d::dSubPane *subPane = it->mpLytPane;
|
||||
if (subPane != nullptr) {
|
||||
nw4r::lyt::Pane *parent = subPane->getPane()->GetParent();
|
||||
parent->RemoveChild(subPane->getPane());
|
||||
}
|
||||
}
|
||||
|
||||
mNode.mpLytPane->remove();
|
||||
|
||||
mLyt.unbindAnims();
|
||||
|
||||
for (int i = 0; i < DEPOSIT_BOX_CURSOR_NUM_ANIMS; i++) {
|
||||
mAnm[i].remove();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
static const char *sGroupName = "G_ref_00";
|
||||
|
||||
void dLytDepositBoxCursor_c::initIcon() {
|
||||
void *data = LayoutArcManager::GetInstance()->getLoadedData("DoButton");
|
||||
d2d::ResAccIf_c resAcc;
|
||||
resAcc.attach(data, "");
|
||||
|
||||
mNode.mpLytPane = &mIcon;
|
||||
mIcon.build(&resAcc, dLytCommonIconItem_c::POUCH);
|
||||
mSubpaneList.PushBack(&mNode);
|
||||
|
||||
if (mLyt.getLayout()->GetGroupContainer() != nullptr) {
|
||||
nw4r::lyt::Group *g = mLyt.getLayout()->GetGroupContainer()->FindGroupByName(sGroupName);
|
||||
if (g != nullptr) {
|
||||
d2d::dSubPane::linkMeters(g, &mSubpaneList);
|
||||
}
|
||||
}
|
||||
|
||||
mIcon.setUnk(false);
|
||||
mIcon.setHasNumber(false);
|
||||
mIcon.setNumber(0);
|
||||
mIcon.setVisible(false);
|
||||
|
||||
mNode.mpPane->SetVisible(false);
|
||||
}
|
||||
|
||||
void dLytDepositBoxCursor_c::realizeNav() {
|
||||
s32 s;
|
||||
if (mSlot < 0) {
|
||||
s = mAnm[DEPOSIT_BOX_CURSOR_ANIM_STICK_CURSOR].getLastFrame();
|
||||
} else if (dPadNav::isPointerVisible()) {
|
||||
s = 4;
|
||||
} else if (field_0x950 == 50) {
|
||||
s = 5;
|
||||
} else if (field_0x949) {
|
||||
s = 6;
|
||||
} else if (mItemLocation == LOC_POUCH) {
|
||||
s = mSlot == 0 ? 1 : 0;
|
||||
if (field_0x950 == 12) {
|
||||
s += 2;
|
||||
}
|
||||
} else if (field_0x950 == 12) {
|
||||
s = 2;
|
||||
} else {
|
||||
s = 0;
|
||||
}
|
||||
|
||||
mVec3_c v;
|
||||
if (dPadNav::isPointerVisible()) {
|
||||
mVec2_c pos = dCsBase_c::GetInstance()->getCursorIf()->getCursorPos();
|
||||
v.set(pos.x, pos.y + 15.0f, 0.0f);
|
||||
} else {
|
||||
nw4r::math::MTX34 mtx = dCsBase_c::GetInstance()->getCursorStickAllPane()->GetGlobalMtx();
|
||||
v.set(mtx._03, mtx._13, 0.0f);
|
||||
}
|
||||
|
||||
mpStickCursorPane->SetTranslate(v);
|
||||
|
||||
mAnm[DEPOSIT_BOX_CURSOR_ANIM_STICK_CURSOR].setAnimEnable(true);
|
||||
mAnm[DEPOSIT_BOX_CURSOR_ANIM_STICK_CURSOR].setFrame(s);
|
||||
mLyt.calc();
|
||||
mAnm[DEPOSIT_BOX_CURSOR_ANIM_STICK_CURSOR].setAnimEnable(false);
|
||||
}
|
||||
|
||||
void dLytDepositBoxCursor_c::init(s32 location, s32 slot, s32 item, bool unk) {
|
||||
mItemLocation = location;
|
||||
field_0x949 = unk;
|
||||
|
||||
s32 number;
|
||||
f32 durability;
|
||||
u8 color;
|
||||
if (mItemLocation == LOC_POUCH) {
|
||||
number = getPouchItemAmount(slot, false);
|
||||
durability = getPouchShieldDurability(slot, false);
|
||||
color = getPouchItemNumberColor(slot, false);
|
||||
mSlot = slot;
|
||||
} else {
|
||||
number = getDepositItemAmount(slot);
|
||||
durability = getDepositShieldDurability(slot);
|
||||
color = getDepositItemNumberColor(slot);
|
||||
mSlot = slot % 12;
|
||||
}
|
||||
|
||||
if (number < 0) {
|
||||
mIcon.setHasNumber(false);
|
||||
} else {
|
||||
mIcon.setHasNumber(true);
|
||||
mIcon.setNumber(number);
|
||||
}
|
||||
mIcon.setUnk(false);
|
||||
mIcon.setItem(item);
|
||||
if (color != 3) {
|
||||
mIcon.setNumberColor(color);
|
||||
}
|
||||
if (durability >= 0.0f) {
|
||||
mIcon.setShieldDurability(durability);
|
||||
}
|
||||
|
||||
mNode.mpPane->SetVisible(true);
|
||||
field_0x950 = 12;
|
||||
realizeNav();
|
||||
mIsVisible = true;
|
||||
}
|
||||
|
||||
void dLytDepositBoxCursor_c::updateSlot(s32 location, s32 slot, s32 unk, bool unk2) {
|
||||
field_0x950 = unk;
|
||||
mItemLocation = location;
|
||||
field_0x949 = unk2;
|
||||
if (mItemLocation == LOC_POUCH) {
|
||||
mSlot = slot;
|
||||
} else {
|
||||
mSlot = slot % 12;
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositBoxCursor_c::fn_801580A0() {
|
||||
field_0x949 = true;
|
||||
realizeNav();
|
||||
}
|
||||
@@ -0,0 +1,682 @@
|
||||
#include "d/lyt/d_lyt_deposit_stock.h"
|
||||
|
||||
#include "d/d_cs_base.h"
|
||||
#include "d/d_pad_nav.h"
|
||||
#include "d/d_rumble.h"
|
||||
#include "d/lyt/d2d.h"
|
||||
#include "d/lyt/d_lyt_common_icon_item.h"
|
||||
#include "d/lyt/d_lyt_common_icon_item_maps.h"
|
||||
#include "d/lyt/d_lyt_util_items.h"
|
||||
#include "d/snd/d_snd_small_effect_mgr.h"
|
||||
#include "d/snd/d_snd_wzsound.h"
|
||||
#include "nw4r/lyt/lyt_group.h"
|
||||
#include "toBeSorted/arc_managers/layout_arc_manager.h"
|
||||
#include "toBeSorted/file_manager.h"
|
||||
|
||||
STATE_DEFINE(dLytDepositStock_c, None);
|
||||
|
||||
void dLytDepositStock_c::initializeState_None() {}
|
||||
void dLytDepositStock_c::executeState_None() {
|
||||
field_0x6844 = true;
|
||||
}
|
||||
void dLytDepositStock_c::finalizeState_None() {}
|
||||
|
||||
static const d2d::LytBrlanMapping brlanMap[] = {
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_00"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_01"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_02"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_03"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_04"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_05"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_06"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_07"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_08"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_09"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_10"},
|
||||
{ "depositBoxBg_00_flash.brlan", "G_flash_11"},
|
||||
{ "depositBoxBg_00_loop.brlan", "G_loop_00"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_00"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_01"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_02"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_03"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_04"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_05"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_06"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_07"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_08"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_09"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_10"},
|
||||
{"depositBoxBg_00_haveBox.brlan", "G_poach_11"},
|
||||
};
|
||||
|
||||
#define DEPOSIT_STOCK_ANIM_FLASH_OFFSET 0
|
||||
#define DEPOSIT_STOCK_ANIM_LOOP 12
|
||||
#define DEPOSIT_STOCK_ANIM_HAVE_BOX_OFFSET 13
|
||||
|
||||
#define DEPOSIT_STOCK_NUM_ANIMS 25
|
||||
|
||||
bool dLytDepositStock_c::build(d2d::ResAccIf_c *resAcc) {
|
||||
mLyt.setResAcc(resAcc);
|
||||
mLyt.build("depositBoxBg_00.brlyt", nullptr);
|
||||
|
||||
for (int i = 0; i < DEPOSIT_STOCK_NUM_ANIMS; i++) {
|
||||
mAnm[i].init(brlanMap[i].mFile, resAcc, mLyt.getLayout(), brlanMap[i].mName);
|
||||
mAnm[i].bind(false);
|
||||
mAnm[i].setAnimEnable(false);
|
||||
}
|
||||
|
||||
int i;
|
||||
|
||||
for (i = 0; i < DEPOSIT_STOCK_NUM_ANIMS; i++) {
|
||||
if (i < DEPOSIT_STOCK_ANIM_FLASH_OFFSET + NUM_ICONS_PER_PAGE) {
|
||||
mAnm[i].setAnimEnable(true);
|
||||
mAnm[i].setToEnd();
|
||||
} else {
|
||||
mAnm[i].setAnimEnable(true);
|
||||
mAnm[i].setFrame(0.0f);
|
||||
}
|
||||
}
|
||||
|
||||
mLyt.calc();
|
||||
|
||||
for (i = 0; i < DEPOSIT_STOCK_NUM_ANIMS; i++) {
|
||||
if (i != DEPOSIT_STOCK_ANIM_LOOP) {
|
||||
mAnm[i].setAnimEnable(false);
|
||||
}
|
||||
}
|
||||
|
||||
initIcons();
|
||||
|
||||
mStateMgr.changeState(StateID_None);
|
||||
|
||||
mCurrentNavTarget = -12;
|
||||
mSelectedItemId = -1;
|
||||
field_0x685C = -1;
|
||||
|
||||
field_0x6849 = false;
|
||||
field_0x684A = false;
|
||||
field_0x684B = false;
|
||||
field_0x684C = true;
|
||||
field_0x684E = false;
|
||||
|
||||
mArrowDirection = ARROW_NONE;
|
||||
|
||||
field_0x6845 = false;
|
||||
field_0x6846 = false;
|
||||
field_0x6847 = false;
|
||||
field_0x6848 = false;
|
||||
|
||||
mSavedArrowDirection = ARROW_NONE;
|
||||
|
||||
navigateToItem();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool dLytDepositStock_c::execute() {
|
||||
for (int i = 0; i < field_0x6854; i++) {
|
||||
mNodes[i].mpLytPane->execute();
|
||||
}
|
||||
|
||||
if (field_0x684D) {
|
||||
mStateMgr.executeState();
|
||||
}
|
||||
|
||||
for (int i = 0; i < DEPOSIT_STOCK_ANIM_LOOP + 1; i++) {
|
||||
if (mAnm[i].isEnabled()) {
|
||||
if (i < NUM_ICONS_PER_PAGE && mAnm[i].isStop()) {
|
||||
mAnm[i].setAnimEnable(false);
|
||||
}
|
||||
|
||||
mAnm[i].play();
|
||||
}
|
||||
}
|
||||
|
||||
mLyt.calc();
|
||||
|
||||
field_0x684C = dPadNav::isPointerVisible();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool dLytDepositStock_c::remove() {
|
||||
for (d2d::SubPaneList::Iterator it = mSubpaneList.GetBeginIter(); it != mSubpaneList.GetEndIter(); ++it) {
|
||||
d2d::dSubPane *subPane = it->mpLytPane;
|
||||
if (subPane != nullptr) {
|
||||
nw4r::lyt::Pane *parent = subPane->getPane()->GetParent();
|
||||
parent->RemoveChild(subPane->getPane());
|
||||
}
|
||||
}
|
||||
|
||||
for (int i = 0; i < NUM_ICONS_PER_PAGE; i++) {
|
||||
mNodes[i].mpLytPane->remove();
|
||||
}
|
||||
|
||||
mLyt.unbindAnims();
|
||||
|
||||
for (int i = 0; i < DEPOSIT_STOCK_NUM_ANIMS; i++) {
|
||||
mAnm[i].remove();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
static const char *sGroupName = "G_ref_00";
|
||||
|
||||
void dLytDepositStock_c::initIcons() {
|
||||
void *data = LayoutArcManager::GetInstance()->getLoadedData("DoButton");
|
||||
d2d::ResAccIf_c resAcc;
|
||||
resAcc.attach(data, "");
|
||||
|
||||
for (int i = 0; i < NUM_ICONS_PER_PAGE; i++) {
|
||||
mNodes[i].mpLytPane = &mIcons[i];
|
||||
mIcons[i].build(&resAcc, dLytCommonIconItem_c::POUCH);
|
||||
mSubpaneList.PushBack(&mNodes[i]);
|
||||
}
|
||||
|
||||
if (mLyt.getLayout()->GetGroupContainer() != nullptr) {
|
||||
nw4r::lyt::Group *g = mLyt.getLayout()->GetGroupContainer()->FindGroupByName(sGroupName);
|
||||
if (g != nullptr) {
|
||||
d2d::dSubPane::linkMeters(g, &mSubpaneList);
|
||||
}
|
||||
}
|
||||
|
||||
for (int i = 0; i < field_0x6854; i++) {
|
||||
mNodes[i].mpPane->SetVisible(false);
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::loadItems(s32 hiddenSlot) {
|
||||
s32 slot = mItemPage * NUM_ICONS_PER_PAGE;
|
||||
|
||||
field_0x6854 = 0;
|
||||
field_0x684E = false;
|
||||
|
||||
for (int i = 0; i < NUM_ICONS_PER_PAGE; i++) {
|
||||
mIcons[i].reset();
|
||||
mItemIds[i] = getDepositItemForSlot(slot);
|
||||
|
||||
f32 f = 0.0f;
|
||||
if (mItemIds[i] != LYT_CMN_PouchBlank4 && slot != hiddenSlot) {
|
||||
f = 1.0f;
|
||||
}
|
||||
loadIcon(i);
|
||||
mIcons[i].setVisible(false);
|
||||
if (slot == hiddenSlot) {
|
||||
mNodes[i].mpPane->SetVisible(false);
|
||||
} else {
|
||||
mNodes[i].mpPane->SetVisible(true);
|
||||
}
|
||||
|
||||
mAnm[i + DEPOSIT_STOCK_ANIM_HAVE_BOX_OFFSET].setAnimEnable(true);
|
||||
mAnm[i + DEPOSIT_STOCK_ANIM_HAVE_BOX_OFFSET].setFrame(f);
|
||||
mLyt.calc();
|
||||
mAnm[i + DEPOSIT_STOCK_ANIM_HAVE_BOX_OFFSET].setAnimEnable(false);
|
||||
|
||||
slot++;
|
||||
field_0x6854++;
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::loadIcon(s32 idx) {
|
||||
s32 slot = idx + mItemPage * NUM_ICONS_PER_PAGE;
|
||||
s32 number = getDepositItemAmount(slot);
|
||||
|
||||
mIcons[idx].setUnk(false);
|
||||
|
||||
if (number < 0) {
|
||||
mIcons[idx].setHasNumber(false);
|
||||
} else {
|
||||
mIcons[idx].setHasNumber(true);
|
||||
mIcons[idx].setNumber(number);
|
||||
}
|
||||
mIcons[idx].setItem(mItemIds[idx]);
|
||||
u8 color = getDepositItemNumberColor(slot);
|
||||
if (color != 3) {
|
||||
mIcons[idx].setNumberColor(color);
|
||||
}
|
||||
f32 durability = getDepositShieldDurability(slot);
|
||||
if (durability >= 0.0f) {
|
||||
mIcons[idx].setShieldDurability(durability);
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::nextPage(bool unk) {
|
||||
mItemPage++;
|
||||
if (mItemPage >= NUM_PAGES) {
|
||||
mItemPage = 0;
|
||||
}
|
||||
field_0x684B = unk;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::prevPage(bool unk) {
|
||||
if (mItemPage != 0) {
|
||||
mItemPage--;
|
||||
} else {
|
||||
mItemPage = NUM_PAGES - 1;
|
||||
}
|
||||
field_0x684B = unk;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::fn_80156530(bool unk) {
|
||||
for (int i = 0; i < NUM_ICONS_PER_PAGE; i++) {
|
||||
mIcons[i].setVisible(unk);
|
||||
}
|
||||
|
||||
if (!field_0x684B) {
|
||||
if (mCurrentNavTarget >= 0) {
|
||||
mAnm[mCurrentNavTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET].setAnimEnable(true);
|
||||
mSelectedItemId = -1;
|
||||
}
|
||||
mCurrentNavTarget = -10;
|
||||
}
|
||||
|
||||
field_0x684B = false;
|
||||
field_0x6845 = false;
|
||||
field_0x6846 = false;
|
||||
if (!field_0x6847) {
|
||||
// okay
|
||||
field_0x6847 = false;
|
||||
}
|
||||
field_0x6848 = false;
|
||||
if (mArrowDirection >= ARROW_NONE) {
|
||||
handleSpecialNavMode();
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::handleNavOrPoint() {
|
||||
bool selectIcon = false;
|
||||
s32 nextTarget = 0;
|
||||
if (dPadNav::isPointerVisible()) {
|
||||
for (nextTarget = 0; nextTarget < NUM_ICONS_PER_PAGE; nextTarget++) {
|
||||
if (mIcons[nextTarget].isCursorOver()) {
|
||||
selectIcon = true;
|
||||
saveArrowDirection();
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
s32 dir = checkNav();
|
||||
if (!isNavModeItem()) {
|
||||
handleSpecialNavMode();
|
||||
} else if (!field_0x6845 && !field_0x6846 && !field_0x6847 && !field_0x6848 && mSavedArrowDirection >= 2) {
|
||||
s32 target = mCurrentNavTarget;
|
||||
if (target < 0 || field_0x684C) {
|
||||
if (dir != dPadNav::FS_STICK_NONE || dCsBase_c::GetInstance()->isCursorStickVisible()) {
|
||||
if (target < 0) {
|
||||
target += NUM_ICONS_PER_PAGE;
|
||||
}
|
||||
selectIcon = true;
|
||||
nextTarget = target;
|
||||
}
|
||||
} else {
|
||||
switch (dir) {
|
||||
case dPadNav::FS_STICK_UP:
|
||||
if (target < 6) {
|
||||
navigateToPouch();
|
||||
} else {
|
||||
nextTarget = target - 6;
|
||||
selectIcon = true;
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_UP_RIGHT:
|
||||
nextTarget = target - 5;
|
||||
selectIcon = true;
|
||||
break;
|
||||
case dPadNav::FS_STICK_RIGHT:
|
||||
if (target % 6 == 5) {
|
||||
navigateToArrow(ARROW_RIGHT);
|
||||
saveArrowDirection();
|
||||
dRumble_c::start(dRumble_c::sRumblePreset1, dRumble_c::FLAG_SLOT0);
|
||||
} else {
|
||||
nextTarget = target + 1;
|
||||
selectIcon = true;
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_DOWN_RIGHT:
|
||||
nextTarget = target + 7;
|
||||
selectIcon = true;
|
||||
break;
|
||||
case dPadNav::FS_STICK_DOWN:
|
||||
if (target >= 10) {
|
||||
navigateToSort();
|
||||
} else if (target >= 6 && target <= 7) {
|
||||
navigateToSell();
|
||||
} else {
|
||||
nextTarget = target + 6;
|
||||
selectIcon = true;
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_DOWN_LEFT:
|
||||
nextTarget = target + 5;
|
||||
selectIcon = true;
|
||||
break;
|
||||
case dPadNav::FS_STICK_LEFT:
|
||||
if (target % 6 == 0) {
|
||||
navigateToArrow(ARROW_LEFT);
|
||||
saveArrowDirection();
|
||||
dRumble_c::start(dRumble_c::sRumblePreset1, dRumble_c::FLAG_SLOT0);
|
||||
} else {
|
||||
nextTarget = target - 1;
|
||||
selectIcon = true;
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_UP_LEFT:
|
||||
nextTarget = target - 7;
|
||||
selectIcon = true;
|
||||
break;
|
||||
default:
|
||||
nextTarget = target;
|
||||
selectIcon = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (selectIcon) {
|
||||
mSavedArrowDirection = ARROW_NONE;
|
||||
if (mCurrentNavTarget != nextTarget) {
|
||||
if (mCurrentNavTarget >= 0) {
|
||||
mIcons[mCurrentNavTarget].setOff();
|
||||
mAnm[mCurrentNavTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET].setAnimEnable(true);
|
||||
}
|
||||
if (mItemIds[nextTarget] != LYT_CMN_PouchBlank4 &&
|
||||
mItemIds[nextTarget] != LYT_CMN_PouchPotionHealthPlusPlusHalf) {
|
||||
mIcons[nextTarget].setOn();
|
||||
mSelectedItemId = FileManager::sInstance->getItemCheckItem(nextTarget + mItemPage * NUM_ICONS_PER_PAGE);
|
||||
dSndSmallEffectMgr_c::GetInstance()->playSound(SE_S_SHOP_STK_STOCK_POINT_ITEM);
|
||||
} else {
|
||||
mSelectedItemId = -1;
|
||||
dSndSmallEffectMgr_c::GetInstance()->playSound(SE_S_SHOP_STK_STOCK_POINT_EMPTY);
|
||||
}
|
||||
|
||||
s32 anmIdx = nextTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET;
|
||||
mAnm[anmIdx].setAnimEnable(true);
|
||||
mAnm[anmIdx].setFrame(0.0f);
|
||||
mLyt.calc();
|
||||
mAnm[anmIdx].setAnimEnable(false);
|
||||
dRumble_c::start(dRumble_c::sRumblePreset1, dRumble_c::FLAG_SLOT0);
|
||||
mCurrentNavTarget = nextTarget;
|
||||
field_0x6846 = false;
|
||||
field_0x6847 = false;
|
||||
field_0x6848 = false;
|
||||
navigateToItem();
|
||||
}
|
||||
mNavMode = 0;
|
||||
} else {
|
||||
navigateOffIcon();
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::navigateOffIcon() {
|
||||
if (mCurrentNavTarget >= 0) {
|
||||
// TODO why LYT_CMN_PouchPotionHealthPlusPlusHalf
|
||||
if (mItemIds[mCurrentNavTarget] != LYT_CMN_PouchBlank4 &&
|
||||
mItemIds[mCurrentNavTarget] != LYT_CMN_PouchPotionHealthPlusPlusHalf) {
|
||||
mIcons[mCurrentNavTarget].setOff();
|
||||
mSelectedItemId = -1;
|
||||
}
|
||||
mAnm[mCurrentNavTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET].setAnimEnable(true);
|
||||
mCurrentNavTarget -= NUM_ICONS_PER_PAGE;
|
||||
}
|
||||
}
|
||||
|
||||
s32 dLytDepositStock_c::checkNav() {
|
||||
// Note: Navigating UP when in the first row means switching from stock to pouch
|
||||
|
||||
s32 target = mCurrentNavTarget;
|
||||
s32 direction = dPadNav::getFSStickNavDirection();
|
||||
if (target >= 0) {
|
||||
switch (direction) {
|
||||
case dPadNav::FS_STICK_UP_RIGHT:
|
||||
if (target == 11) {
|
||||
direction = dPadNav::FS_STICK_UP;
|
||||
} else if (target < 6) {
|
||||
if (target < 4) {
|
||||
direction = dPadNav::FS_STICK_UP;
|
||||
} else if (target == 5) {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_RIGHT;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_DOWN_RIGHT:
|
||||
if (target == 5) {
|
||||
direction = dPadNav::FS_STICK_DOWN;
|
||||
} else if (target >= 6) {
|
||||
if (target >= 10) {
|
||||
if (field_0x684A) {
|
||||
if (target == 11) {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_RIGHT;
|
||||
}
|
||||
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_DOWN;
|
||||
}
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_RIGHT;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_DOWN:
|
||||
if (target >= 6) {
|
||||
if (target < 8) {
|
||||
if (field_0x6849) {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
}
|
||||
} else if (target >= 10) {
|
||||
if (field_0x684A) {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
}
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_DOWN_LEFT:
|
||||
if (target == 0 || target == 11) {
|
||||
if (target == 11 && field_0x684A) {
|
||||
direction = dPadNav::FS_STICK_LEFT;
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_DOWN;
|
||||
}
|
||||
} else if (target >= 6) {
|
||||
if (target <= 7) {
|
||||
if (field_0x6849) {
|
||||
if (target == 6) {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_LEFT;
|
||||
}
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_DOWN;
|
||||
}
|
||||
} else if (target == 11) {
|
||||
if (field_0x684A) {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_DOWN;
|
||||
}
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_LEFT;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case dPadNav::FS_STICK_UP_LEFT:
|
||||
if (target == 6) {
|
||||
direction = dPadNav::FS_STICK_UP;
|
||||
} else if (target < 6) {
|
||||
if (target == 0) {
|
||||
direction = dPadNav::FS_STICK_NONE;
|
||||
} else if (target == 1) {
|
||||
direction = dPadNav::FS_STICK_LEFT;
|
||||
} else {
|
||||
direction = dPadNav::FS_STICK_UP;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return direction;
|
||||
}
|
||||
|
||||
s32 dLytDepositStock_c::getCurrentSlot() const {
|
||||
return mCurrentNavTarget + mItemPage * NUM_ICONS_PER_PAGE;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::setItem(s32 idx, s32 item) {
|
||||
mItemIds[idx] = item;
|
||||
realizeItem(idx);
|
||||
mIcons[idx].setOn();
|
||||
field_0x684E = false;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::realizeItem(s32 idx) {
|
||||
f32 frame = 0.0f;
|
||||
if (mItemIds[idx] != LYT_CMN_PouchBlank4) {
|
||||
frame = 1.0f;
|
||||
}
|
||||
loadIcon(idx);
|
||||
mIcons[idx].setVisible(true);
|
||||
s32 anmIdx = idx + DEPOSIT_STOCK_ANIM_HAVE_BOX_OFFSET;
|
||||
mAnm[anmIdx].setAnimEnable(true);
|
||||
mAnm[anmIdx].setFrame(frame);
|
||||
mLyt.calc();
|
||||
mAnm[anmIdx].setAnimEnable(false);
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::selectNavTarget(s32 idx) {
|
||||
if (idx < NUM_ICONS_PER_PAGE) {
|
||||
if (mCurrentNavTarget >= 0) {
|
||||
mAnm[mCurrentNavTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET].setAnimEnable(true);
|
||||
}
|
||||
mCurrentNavTarget = idx;
|
||||
|
||||
if (mCurrentNavTarget >= 0) {
|
||||
mAnm[mCurrentNavTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET].setAnimEnable(true);
|
||||
mAnm[mCurrentNavTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET].setFrame(0.0f);
|
||||
mLyt.calc();
|
||||
mAnm[mCurrentNavTarget + DEPOSIT_STOCK_ANIM_FLASH_OFFSET].setAnimEnable(false);
|
||||
dRumble_c::start(dRumble_c::sRumblePreset1, dRumble_c::FLAG_SLOT0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::pickUpItem(s32 slot, bool unk) {
|
||||
s32 page = slot / NUM_ICONS_PER_PAGE;
|
||||
s32 idx = slot % NUM_ICONS_PER_PAGE;
|
||||
if (unk) {
|
||||
mNodes[idx].mpPane->SetVisible(unk);
|
||||
}
|
||||
|
||||
if (mItemPage != page) {
|
||||
if (unk) {
|
||||
field_0x684E = false;
|
||||
}
|
||||
} else {
|
||||
s32 item = mItemIds[idx];
|
||||
f32 frame;
|
||||
if (unk) {
|
||||
// TODO why LYT_CMN_PouchPotionHealthPlusPlusHalf
|
||||
if (item != LYT_CMN_PouchPotionHealthPlusPlusHalf && item != LYT_CMN_PouchBlank4) {
|
||||
frame = 1.0f;
|
||||
if (field_0x684E) {
|
||||
s32 otherIdx = field_0x685C % NUM_ICONS_PER_PAGE;
|
||||
mIcons[idx].setItem(mItemIds[otherIdx]);
|
||||
field_0x684E = false;
|
||||
}
|
||||
} else {
|
||||
frame = 0.0f;
|
||||
}
|
||||
field_0x685C = -1;
|
||||
} else {
|
||||
field_0x685C = slot;
|
||||
frame = 0.0f;
|
||||
field_0x684E = true;
|
||||
mIcons[idx].setOff();
|
||||
mIcons[idx].setHasNumber(false);
|
||||
mIcons[idx].setItem(LYT_CMN_PouchBlank4);
|
||||
}
|
||||
|
||||
s32 anmIdx = idx + DEPOSIT_STOCK_ANIM_HAVE_BOX_OFFSET;
|
||||
mAnm[anmIdx].setAnimEnable(true);
|
||||
mAnm[anmIdx].setFrame(frame);
|
||||
mLyt.calc();
|
||||
mAnm[anmIdx].setAnimEnable(false);
|
||||
}
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::navigateToPouch() {
|
||||
field_0x6845 = true;
|
||||
mSavedArrowDirection = ARROW_NONE;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::navigateToSell() {
|
||||
if (!field_0x6846) {
|
||||
dSndSmallEffectMgr_c::GetInstance()->playSound(SE_S_SHOP_STK_POINT_SELL);
|
||||
}
|
||||
field_0x6846 = true;
|
||||
mNavMode = NAV_SELL;
|
||||
mSavedArrowDirection = ARROW_NONE;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::navigateToSort() {
|
||||
if (!field_0x6847) {
|
||||
dSndSmallEffectMgr_c::GetInstance()->playSound(SE_S_SHOP_STK_STOCK_POINT_TRIM);
|
||||
}
|
||||
field_0x6847 = true;
|
||||
mNavMode = NAV_SORT;
|
||||
mSavedArrowDirection = ARROW_NONE;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::navigateToFinish() {
|
||||
if (!field_0x6848) {
|
||||
dSndSmallEffectMgr_c::GetInstance()->playSound(SE_S_SHOP_STK_POINT_DECIDE);
|
||||
}
|
||||
field_0x6848 = true;
|
||||
mNavMode = NAV_FINISH;
|
||||
mSavedArrowDirection = ARROW_NONE;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::saveArrowDirection() {
|
||||
mSavedArrowDirection = mArrowDirection;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::navigateToArrow(s32 arrowDirection) {
|
||||
mArrowDirection = arrowDirection;
|
||||
if (mArrowDirection < ARROW_NONE) {
|
||||
mNavMode = NAV_ARROW;
|
||||
}
|
||||
}
|
||||
|
||||
s32 dLytDepositStock_c::restoreArrowDirection() {
|
||||
if (mSavedArrowDirection < ARROW_NONE && mArrowDirection >= ARROW_NONE) {
|
||||
navigateToArrow(mSavedArrowDirection);
|
||||
}
|
||||
return mArrowDirection;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::navigateToItem() {
|
||||
mNavMode = NAV_ITEM;
|
||||
}
|
||||
|
||||
void dLytDepositStock_c::handleSpecialNavMode() {
|
||||
switch (mNavMode) {
|
||||
case NAV_SELL: navigateToSell(); break;
|
||||
case NAV_SORT: navigateToSort(); break;
|
||||
case NAV_FINISH: navigateToFinish(); break;
|
||||
case NAV_ARROW:
|
||||
if (mArrowDirection < ARROW_NONE) {
|
||||
saveArrowDirection();
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
bool dLytDepositStock_c::isNavModeItem() const {
|
||||
return mNavMode == NAV_ITEM;
|
||||
}
|
||||
@@ -1252,6 +1252,7 @@ void dLytPauseDisp00_c::setupInventoryWheel() {
|
||||
}
|
||||
|
||||
u32 item = getPouchItemForSlot(i, true);
|
||||
// TODO why LYT_CMN_PouchPotionHealthPlusPlusHalf
|
||||
if (item != LYT_CMN_PouchPotionHealthPlusPlusHalf) {
|
||||
if (isPouchBocoburinLocked()) {
|
||||
icon->setBocoburinLocked(true);
|
||||
@@ -1259,7 +1260,7 @@ void dLytPauseDisp00_c::setupInventoryWheel() {
|
||||
}
|
||||
haveFrame = 1.0f;
|
||||
icon->setItem(item);
|
||||
f32 durability = getShieldDurability(i, true);
|
||||
f32 durability = getPouchShieldDurability(i, true);
|
||||
if (durability >= 0.0f) {
|
||||
icon->setShieldDurability(durability);
|
||||
}
|
||||
@@ -1575,6 +1576,7 @@ void dLytPauseDisp00_c::setupRingIcons(s32 tab) {
|
||||
s32 offset = PAUSE_DISP_00_BOUNDING_RING_OFFSET;
|
||||
for (int i = 0; i < PAUSE_DISP_00_ICONS_NUM_ITEMS_ON_WHEEL; i++) {
|
||||
bool visible = false;
|
||||
// TODO why LYT_CMN_PouchPotionHealthPlusPlusHalf
|
||||
if (getPouchItemForSlot(i, true) != LYT_CMN_PouchPotionHealthPlusPlusHalf) {
|
||||
visible = true;
|
||||
}
|
||||
|
||||
@@ -339,8 +339,8 @@ void dLytMeterMinusBtn_c::initializeState_MenuSelectingIn() {
|
||||
mItemIcons[i].setItem(field_0x4E98[i]);
|
||||
}
|
||||
|
||||
if (getShieldDurability(i, true) >= 0.0f) {
|
||||
mItemIcons[i].setShieldDurability(getShieldDurability(i, true));
|
||||
if (getPouchShieldDurability(i, true) >= 0.0f) {
|
||||
mItemIcons[i].setShieldDurability(getPouchShieldDurability(i, true));
|
||||
if (i == convertFilePouchSlot(FileManager::GetInstance()->getShieldPouchSlot())) {
|
||||
mItemIcons[i].setShieldOnOff(false);
|
||||
} else {
|
||||
@@ -574,8 +574,8 @@ void dLytMeterMinusBtn_c::initializeState_DemoMove() {
|
||||
mItemIcons[i].setItem(field_0x4E98[i]);
|
||||
}
|
||||
|
||||
if (getShieldDurability(i, true) >= 0.0f) {
|
||||
mItemIcons[i].setShieldDurability(getShieldDurability(i, true));
|
||||
if (getPouchShieldDurability(i, true) >= 0.0f) {
|
||||
mItemIcons[i].setShieldDurability(getPouchShieldDurability(i, true));
|
||||
if (i == convertFilePouchSlot(FileManager::GetInstance()->getShieldPouchSlot())) {
|
||||
mItemIcons[i].setShieldOnOff(false);
|
||||
} else {
|
||||
@@ -1086,7 +1086,7 @@ void dLytMeterMinusBtn_c::setItemText(s32 item) {
|
||||
void dLytMeterMinusBtn_c::realizeShieldDurability() {
|
||||
for (int i = 0; i < MINUS_BTN_NUM_ITEMS; i++) {
|
||||
if (field_0x4EBB[i] != 0) {
|
||||
mItemIcons[i].setShieldDurability(getShieldDurability(i, true));
|
||||
mItemIcons[i].setShieldDurability(getPouchShieldDurability(i, true));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user