mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2025-07-15 01:22:59 -07:00
DPad items
This commit is contained in:
parent
57fb04accc
commit
fd06827e2b
17 changed files with 582 additions and 407 deletions
|
@ -25,8 +25,9 @@ void func_801109B0(GlobalContext* globalCtx) {
|
|||
interfaceCtx->minimapAlpha = 0;
|
||||
interfaceCtx->unk_260 = 0;
|
||||
interfaceCtx->unk_244 = interfaceCtx->aAlpha = interfaceCtx->bAlpha = interfaceCtx->cLeftAlpha =
|
||||
interfaceCtx->cDownAlpha = interfaceCtx->cRightAlpha = interfaceCtx->healthAlpha = interfaceCtx->startAlpha =
|
||||
interfaceCtx->magicAlpha = 0;
|
||||
interfaceCtx->cDownAlpha = interfaceCtx->cRightAlpha = interfaceCtx->dpadUpAlpha = interfaceCtx->dpadDownAlpha =
|
||||
interfaceCtx->dpadLeftAlpha = interfaceCtx->dpadRightAlpha = interfaceCtx->healthAlpha =
|
||||
interfaceCtx->startAlpha = interfaceCtx->magicAlpha = 0;
|
||||
|
||||
parameterSize = (uintptr_t)_parameter_staticSegmentRomEnd - (uintptr_t)_parameter_staticSegmentRomStart;
|
||||
|
||||
|
@ -73,7 +74,8 @@ void func_801109B0(GlobalContext* globalCtx) {
|
|||
//DmaMgr_SendRequest1(interfaceCtx->doActionSegment + 0x300, (uintptr_t)_do_action_staticSegmentRomStart + doActionOffset,
|
||||
//0x180, "../z_construct.c", 178);
|
||||
|
||||
interfaceCtx->iconItemSegment = GameState_Alloc(&globalCtx->state, 0x4000, "../z_construct.c", 190);
|
||||
interfaceCtx->iconItemSegment = GameState_Alloc(
|
||||
&globalCtx->state, 0x1000 * ARRAY_COUNT(gSaveContext.equips.buttonItems), "../z_construct.c", 190);
|
||||
|
||||
// "Icon Item Texture Initialization = %x"
|
||||
osSyncPrintf("アイコンアイテム テクスチャ初期=%x\n", 0x4000);
|
||||
|
@ -85,32 +87,18 @@ void func_801109B0(GlobalContext* globalCtx) {
|
|||
gSaveContext.equips.buttonItems[1], gSaveContext.equips.buttonItems[2],
|
||||
gSaveContext.equips.buttonItems[3]);
|
||||
|
||||
if (gSaveContext.equips.buttonItems[0] < 0xF0) {
|
||||
DmaMgr_SendRequest1(interfaceCtx->iconItemSegment,
|
||||
_icon_item_staticSegmentRomStart + gSaveContext.equips.buttonItems[0] * 0x1000, 0x1000,
|
||||
"../z_construct.c", 198);
|
||||
} else if (gSaveContext.equips.buttonItems[0] != 0xFF) {
|
||||
DmaMgr_SendRequest1(interfaceCtx->iconItemSegment,
|
||||
_icon_item_staticSegmentRomStart + gSaveContext.equips.buttonItems[0] * 0x1000, 0x1000,
|
||||
"../z_construct.c", 203);
|
||||
}
|
||||
|
||||
if (gSaveContext.equips.buttonItems[1] < 0xF0) {
|
||||
DmaMgr_SendRequest1(interfaceCtx->iconItemSegment + 0x1000,
|
||||
_icon_item_staticSegmentRomStart + gSaveContext.equips.buttonItems[1] * 0x1000, 0x1000,
|
||||
"../z_construct.c", 209);
|
||||
}
|
||||
|
||||
if (gSaveContext.equips.buttonItems[2] < 0xF0) {
|
||||
DmaMgr_SendRequest1(interfaceCtx->iconItemSegment + 0x2000,
|
||||
_icon_item_staticSegmentRomStart + gSaveContext.equips.buttonItems[2] * 0x1000, 0x1000,
|
||||
"../z_construct.c", 214);
|
||||
}
|
||||
|
||||
if (gSaveContext.equips.buttonItems[3] < 0xF0) {
|
||||
DmaMgr_SendRequest1(interfaceCtx->iconItemSegment + 0x3000,
|
||||
_icon_item_staticSegmentRomStart + gSaveContext.equips.buttonItems[3] * 0x1000, 0x1000,
|
||||
"../z_construct.c", 219);
|
||||
for (int buttonIndex = 0; buttonIndex < ARRAY_COUNT(gSaveContext.equips.buttonItems); buttonIndex++) {
|
||||
if (gSaveContext.equips.buttonItems[buttonIndex] < 0xF0) {
|
||||
DmaMgr_SendRequest1(interfaceCtx->iconItemSegment + 0x1000 * buttonIndex,
|
||||
_icon_item_staticSegmentRomStart +
|
||||
gSaveContext.equips.buttonItems[buttonIndex] * 0x1000,
|
||||
0x1000, "../z_construct.c", 198);
|
||||
} else if (buttonIndex == 0 && gSaveContext.equips.buttonItems[buttonIndex] != 0xFF) {
|
||||
DmaMgr_SendRequest1(interfaceCtx->iconItemSegment + 0x1000 * buttonIndex,
|
||||
_icon_item_staticSegmentRomStart +
|
||||
gSaveContext.equips.buttonItems[buttonIndex] * 0x1000,
|
||||
0x1000, "../z_construct.c", 203);
|
||||
}
|
||||
}
|
||||
|
||||
osSyncPrintf("EVENT=%d\n", ((void)0, gSaveContext.timer1State));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue