mirror of
https://github.com/izzy2lost/2ship2harkinian-Android.git
synced 2026-06-19 01:20:08 -07:00
Match another 2 functions
This commit is contained in:
+2
-2
@@ -1919,11 +1919,11 @@ u8 Item_CheckObtainability(u8 arg0);
|
||||
void Inventory_DeleteItem(s16 arg0, s16 arg1);
|
||||
// void Inventory_UnequipItem(void);
|
||||
// void Inventory_ReplaceItem(void);
|
||||
// void func_80114CA0(void);
|
||||
// void Inventory_UpdateDeitySwordEquip(void);
|
||||
s32 Inventory_HasEmptyBottle(void);
|
||||
s32 Inventory_HasItemInBottle(u8 itemId);
|
||||
// void func_80114FD0(void);
|
||||
// void func_80115130(void);
|
||||
// void Inventory_ConsumeFairy(void);
|
||||
// void Inventory_UpdateItem(void);
|
||||
// void func_801153C8(void);
|
||||
// void Interface_LoadActionLabel(void);
|
||||
|
||||
+49
-2
@@ -2071,7 +2071,32 @@ s32 Inventory_ReplaceItem(GlobalContext* globalCtx, u8 oldItem, u8 newItem) {
|
||||
return false;
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/code/z_parameter/func_80114CA0.s")
|
||||
void Inventory_UpdateDeitySwordEquip(GlobalContext* globalCtx) {
|
||||
InterfaceContext* interfaceCtx = &globalCtx->interfaceCtx;
|
||||
u8 btn;
|
||||
|
||||
if (CUR_FORM == 0) {
|
||||
interfaceCtx->unk_21C = 0;
|
||||
interfaceCtx->unk_21E = 0;
|
||||
if ((((gSaveContext.save.playerForm > 0) && (gSaveContext.save.playerForm < 4)) ? 1 : gSaveContext.save.playerForm >> 1) == 0) {
|
||||
BUTTON_ITEM_EQUIP(CUR_FORM, EQUIP_SLOT_B) = ITEM_SWORD_DEITY;
|
||||
} else {
|
||||
if (BUTTON_ITEM_EQUIP(CUR_FORM, EQUIP_SLOT_B) == ITEM_SWORD_DEITY) {
|
||||
if (GET_CUR_EQUIP_VALUE(EQUIP_SWORD) == 0) {
|
||||
BUTTON_ITEM_EQUIP(CUR_FORM, EQUIP_SLOT_B) = ITEM_NONE;
|
||||
} else {
|
||||
BUTTON_ITEM_EQUIP(CUR_FORM, EQUIP_SLOT_B) = GET_CUR_EQUIP_VALUE(EQUIP_SWORD) + ITEM_SWORD_KOKIRI - 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
for (btn = 0; btn < 1; btn++) {
|
||||
if ((GET_CUR_FORM_BTN_ITEM(btn) != ITEM_NONE) && (GET_CUR_FORM_BTN_ITEM(btn) != ITEM_UNK_FD)) {
|
||||
Interface_LoadItemIconImpl(globalCtx, btn);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
s32 Inventory_HasEmptyBottle(void) {
|
||||
s32 slot;
|
||||
@@ -2109,7 +2134,29 @@ void Inventory_UpdateBottleItem(GlobalContext* globalCtx, u8 item, u8 btn) {
|
||||
}
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/code/z_parameter/func_80115130.s")
|
||||
s32 Inventory_ConsumeFairy(GlobalContext* globalCtx) {
|
||||
u8 bottleSlot = SLOT(ITEM_FAIRY);
|
||||
u8 btn;
|
||||
u8 i;
|
||||
|
||||
for (i = 0; i < 6; i++) {
|
||||
if (gSaveContext.save.inventory.items[bottleSlot + i] == ITEM_FAIRY) {
|
||||
for (btn = 1; btn < 4; btn++) {
|
||||
if (GET_CUR_FORM_BTN_ITEM(btn) == ITEM_FAIRY) {
|
||||
SET_CUR_FORM_BTN_ITEM(btn, ITEM_BOTTLE);
|
||||
Interface_LoadItemIconImpl(globalCtx, btn);
|
||||
bottleSlot = GET_CUR_FORM_BTN_SLOT(btn);
|
||||
i = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
gSaveContext.save.inventory.items[bottleSlot + i] = ITEM_BOTTLE;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Only used to equip spring water when hot sprint water timer runs out
|
||||
|
||||
@@ -2118,11 +2118,11 @@
|
||||
0x801149A0:("Inventory_DeleteItem",),
|
||||
0x80114A9C:("Inventory_UnequipItem",),
|
||||
0x80114B84:("Inventory_ReplaceItem",),
|
||||
0x80114CA0:("func_80114CA0",),
|
||||
0x80114CA0:("Inventory_UpdateDeitySwordEquip",),
|
||||
0x80114E90:("Inventory_HasEmptyBottle",),
|
||||
0x80114F2C:("Inventory_HasItemInBottle",),
|
||||
0x80114FD0:("Inventory_UpdateBottleItem",),
|
||||
0x80115130:("func_80115130",),
|
||||
0x80115130:("Inventory_ConsumeFairy",),
|
||||
0x801152B8:("Inventory_UpdateItem",),
|
||||
0x801153C8:("func_801153C8",),
|
||||
0x80115428:("Interface_LoadActionLabel",),
|
||||
|
||||
@@ -1632,11 +1632,11 @@ asm/non_matchings/code/z_parameter/Item_CheckObtainability.s,Item_CheckObtainabi
|
||||
asm/non_matchings/code/z_parameter/Inventory_DeleteItem.s,Inventory_DeleteItem,0x801149A0,0x3F
|
||||
asm/non_matchings/code/z_parameter/Inventory_UnequipItem.s,Inventory_UnequipItem,0x80114A9C,0x3A
|
||||
asm/non_matchings/code/z_parameter/Inventory_ReplaceItem.s,Inventory_ReplaceItem,0x80114B84,0x47
|
||||
asm/non_matchings/code/z_parameter/func_80114CA0.s,func_80114CA0,0x80114CA0,0x7C
|
||||
asm/non_matchings/code/z_parameter/Inventory_UpdateDeitySwordEquip.s,Inventory_UpdateDeitySwordEquip,0x80114CA0,0x7C
|
||||
asm/non_matchings/code/z_parameter/Inventory_HasEmptyBottle.s,Inventory_HasEmptyBottle,0x80114E90,0x27
|
||||
asm/non_matchings/code/z_parameter/Inventory_HasItemInBottle.s,Inventory_HasItemInBottle,0x80114F2C,0x29
|
||||
asm/non_matchings/code/z_parameter/Inventory_UpdateBottleItem.s,Inventory_UpdateBottleItem,0x80114FD0,0x58
|
||||
asm/non_matchings/code/z_parameter/func_80115130.s,func_80115130,0x80115130,0x62
|
||||
asm/non_matchings/code/z_parameter/Inventory_ConsumeFairy.s,Inventory_ConsumeFairy,0x80115130,0x62
|
||||
asm/non_matchings/code/z_parameter/Inventory_UpdateItem.s,Inventory_UpdateItem,0x801152B8,0x44
|
||||
asm/non_matchings/code/z_parameter/func_801153C8.s,func_801153C8,0x801153C8,0x18
|
||||
asm/non_matchings/code/z_parameter/Interface_LoadActionLabel.s,Interface_LoadActionLabel,0x80115428,0x41
|
||||
|
||||
|
Reference in New Issue
Block a user