mirror of
https://github.com/izzy2lost/2ship2harkinian-Android.git
synced 2026-06-19 01:20:08 -07:00
Match another 4 functions
This commit is contained in:
+2
-2
@@ -1977,9 +1977,9 @@ s32 Inventory_HasItemInBottle(u8 itemId);
|
||||
// void Interface_LoadActionLabel(void);
|
||||
void Interface_SetDoAction(GlobalContext* globalCtx, u16 arg1);
|
||||
// void func_801155B4(void);
|
||||
// void func_80115764(void);
|
||||
// void Interface_SetNaviCall(void);
|
||||
void func_80115844(GlobalContext* globalCtx, s16 param_2);
|
||||
s32 func_80115908(GlobalContext* globalCtx, u8 param_2);
|
||||
s32 Health_ChangeBy(GlobalContext* globalCtx, s16 param_2);
|
||||
void Health_GiveHearts(s16 hearts);
|
||||
void Rupees_ChangeBy(s16 arg0);
|
||||
void Inventory_ChangeAmmo(s16 arg0, s16 arg1);
|
||||
|
||||
@@ -215,7 +215,7 @@ void EnItem00_Init(Actor* thisx, GlobalContext* globalCtx) {
|
||||
break;
|
||||
case ITEM00_FLEXIBLE:
|
||||
case ITEM00_BIG_FAIRY:
|
||||
func_80115908(globalCtx, 0x70);
|
||||
Health_ChangeBy(globalCtx, 0x70);
|
||||
break;
|
||||
case ITEM00_BOMBS_A:
|
||||
case ITEM00_BOMBS_B:
|
||||
@@ -528,7 +528,7 @@ void EnItem00_Update(Actor* thisx, GlobalContext* globalCtx) {
|
||||
break;
|
||||
case ITEM00_FLEXIBLE:
|
||||
case ITEM00_BIG_FAIRY:
|
||||
func_80115908(globalCtx, 0x70);
|
||||
Health_ChangeBy(globalCtx, 0x70);
|
||||
break;
|
||||
case ITEM00_BOMBS_A:
|
||||
case ITEM00_BOMBS_B:
|
||||
|
||||
+83
-8
@@ -171,9 +171,8 @@ s16 sHBAScoreTier = 0;
|
||||
|
||||
u16 sMinigameScoreDigits[] = { 0, 0, 0, 0 };
|
||||
|
||||
s32 D_801BF898 = 0;
|
||||
|
||||
s32 D_801BF89C = 0;
|
||||
s16 D_801BF898 = 0;
|
||||
s16 D_801BF89C = 0;
|
||||
|
||||
s16 sMagicBarOutlinePrimRed = 255;
|
||||
s16 sMagicBarOutlinePrimGreen = 255;
|
||||
@@ -1750,7 +1749,7 @@ u8 Item_Give(GlobalContext* globalCtx, u8 item) {
|
||||
return ITEM_NONE;
|
||||
|
||||
} else if (item == ITEM_HEART) {
|
||||
func_80115908(globalCtx, 0x10);
|
||||
Health_ChangeBy(globalCtx, 0x10);
|
||||
return item;
|
||||
|
||||
} else if (item == ITEM_MAGIC_SMALL) {
|
||||
@@ -2047,13 +2046,89 @@ void Interface_SetDoAction(GlobalContext* globalCtx, u16 action) {
|
||||
}
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/code/z_parameter/func_801155B4.s")
|
||||
void func_801155B4(GlobalContext* globalCtx, s16 arg1) {
|
||||
InterfaceContext* interfaceCtx = &globalCtx->interfaceCtx;
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/code/z_parameter/func_80115764.s")
|
||||
if (((gSaveContext.save.equips.buttonItems[CUR_FORM][0] >= ITEM_SWORD_KOKIRI) &&
|
||||
(gSaveContext.save.equips.buttonItems[CUR_FORM][0] <= ITEM_SWORD_GILDED)) ||
|
||||
(gSaveContext.save.equips.buttonItems[CUR_FORM][0] == ITEM_NONE) ||
|
||||
(gSaveContext.save.equips.buttonItems[CUR_FORM][0] == ITEM_NUT)) {
|
||||
if ((CUR_FORM == PLAYER_FORM_DEKU) && (gSaveContext.save.playerData.magicAcquired == 0)) {
|
||||
interfaceCtx->unk_21E = 0xFD;
|
||||
} else {
|
||||
interfaceCtx->unk_21E = arg1;
|
||||
if (interfaceCtx->unk_21E != 0xA) {
|
||||
osCreateMesgQueue(&interfaceCtx->loadQueue, &interfaceCtx->loadMsg, 1);
|
||||
DmaMgr_SendRequestImpl(&interfaceCtx->dmaRequest_184, interfaceCtx->doActionSegment + 0x600,
|
||||
(arg1 * 0x180) + SEGMENT_ROM_START(do_action_static), 0x180, 0,
|
||||
&interfaceCtx->loadQueue, NULL);
|
||||
osRecvMesg(&interfaceCtx->loadQueue, NULL, OS_MESG_BLOCK);
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/code/z_parameter/func_80115844.s")
|
||||
interfaceCtx->unk_21C = 1;
|
||||
}
|
||||
} else {
|
||||
interfaceCtx->unk_21C = 0;
|
||||
interfaceCtx->unk_21E = 0;
|
||||
}
|
||||
}
|
||||
|
||||
void Interface_SetNaviCall(GlobalContext* globalCtx, u16 naviCallState) {
|
||||
InterfaceContext* interfaceCtx = &globalCtx->interfaceCtx;
|
||||
|
||||
if (((naviCallState == 0x2A) || (naviCallState == 0x2B)) && (interfaceCtx->unk_220 == 0) &&
|
||||
(globalCtx->csCtx.state == 0)) {
|
||||
if (naviCallState == 0x2B) {
|
||||
play_sound(NA_SE_VO_NAVY_CALL);
|
||||
}
|
||||
if (naviCallState == 0x2A) {
|
||||
func_8019FDC8(&D_801DB4A4, NA_SE_VO_NA_HELLO_2, 0x20);
|
||||
}
|
||||
interfaceCtx->unk_220 = 1;
|
||||
D_801BF898 = 0;
|
||||
D_801BF89C = 10;
|
||||
} else if (naviCallState == 0x2C) {
|
||||
if (interfaceCtx->unk_220 != 0) {
|
||||
interfaceCtx->unk_220 = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Interface_LoadActionLabelB?
|
||||
void func_80115844(GlobalContext* globalCtx, s16 arg1) {
|
||||
InterfaceContext* interfaceCtx = &globalCtx->interfaceCtx;
|
||||
|
||||
interfaceCtx->unk_224 = arg1;
|
||||
|
||||
osCreateMesgQueue(&globalCtx->interfaceCtx.loadQueue, &globalCtx->interfaceCtx.loadMsg, 1);
|
||||
DmaMgr_SendRequestImpl(&interfaceCtx->dmaRequest_184, interfaceCtx->doActionSegment + 0x480, (arg1 * 0x180) + SEGMENT_ROM_START(do_action_static), 0x180, 0, &interfaceCtx->loadQueue, NULL);
|
||||
osRecvMesg(&interfaceCtx->loadQueue, NULL, OS_MESG_BLOCK);
|
||||
|
||||
interfaceCtx->unk_222 = 1;
|
||||
}
|
||||
|
||||
s32 Health_ChangeBy(GlobalContext* globalCtx, s16 healthChange) {
|
||||
|
||||
if (healthChange > 0) {
|
||||
play_sound(NA_SE_SY_HP_RECOVER);
|
||||
} else if ((gSaveContext.save.playerData.doubleDefense != 0) && (healthChange < 0)) {
|
||||
healthChange >>= 1;
|
||||
}
|
||||
|
||||
gSaveContext.save.playerData.health += healthChange;
|
||||
|
||||
if (((void)0, gSaveContext.save.playerData.health) > ((void)0, gSaveContext.save.playerData.healthCapacity)) {
|
||||
gSaveContext.save.playerData.health = gSaveContext.save.playerData.healthCapacity;
|
||||
}
|
||||
|
||||
if (gSaveContext.save.playerData.health <= 0) {
|
||||
gSaveContext.save.playerData.health = 0;
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/code/z_parameter/func_80115908.s")
|
||||
|
||||
void Health_GiveHearts(s16 hearts) {
|
||||
gSaveContext.save.playerData.healthCapacity += hearts * 0x10;
|
||||
|
||||
@@ -673,7 +673,7 @@ void func_8088DD34(EnElf* this, GlobalContext* globalCtx) {
|
||||
|
||||
if ((this->fairyFlags & 0x1000) && (heightDiff > 0.0f) && (heightDiff < 60.0f) &&
|
||||
!func_8088C804(&this->actor.world.pos, &refActor->actor.world.pos, 10.0f)) {
|
||||
func_80115908(globalCtx, 0x80);
|
||||
Health_ChangeBy(globalCtx, 0x80);
|
||||
if (this->fairyFlags & 0x200) {
|
||||
Interface_AddMagic(globalCtx, ((void)0, gSaveContext.unk_3F30) +
|
||||
(gSaveContext.save.playerData.doubleMagic * 0x30) + 0x30);
|
||||
|
||||
@@ -440,7 +440,7 @@ void EnElforg_FreeFloating(EnElforg* this, GlobalContext* globalCtx) {
|
||||
if (!Player_InCsMode(&globalCtx->state)) {
|
||||
if ((this->actor.xzDistToPlayer < 30.0f) && (scaledYDistance < 12.0f) && (scaledYDistance > -68.0f)) {
|
||||
EnElforg_SetupFairyCollected(this, globalCtx);
|
||||
func_80115908(globalCtx, 48);
|
||||
Health_ChangeBy(globalCtx, 48);
|
||||
switch (STRAY_FAIRY_TYPE(&this->actor)) {
|
||||
case STRAY_FAIRY_TYPE_COLLECTIBLE:
|
||||
Flags_SetCollectible(globalCtx, STRAY_FAIRY_FLAG(&this->actor));
|
||||
|
||||
@@ -2128,9 +2128,9 @@
|
||||
0x80115428:("Interface_LoadActionLabel",),
|
||||
0x8011552C:("Interface_SetDoAction",),
|
||||
0x801155B4:("func_801155B4",),
|
||||
0x80115764:("func_80115764",),
|
||||
0x80115764:("Interface_SetNaviCall",),
|
||||
0x80115844:("func_80115844",),
|
||||
0x80115908:("func_80115908",),
|
||||
0x80115908:("Health_ChangeBy",),
|
||||
0x801159C0:("Health_GiveHearts",),
|
||||
0x801159EC:("Rupees_ChangeBy",),
|
||||
0x80115A14:("Inventory_ChangeAmmo",),
|
||||
|
||||
@@ -1642,9 +1642,9 @@ 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
|
||||
asm/non_matchings/code/z_parameter/Interface_SetDoAction.s,Interface_SetDoAction,0x8011552C,0x22
|
||||
asm/non_matchings/code/z_parameter/func_801155B4.s,func_801155B4,0x801155B4,0x6C
|
||||
asm/non_matchings/code/z_parameter/func_80115764.s,func_80115764,0x80115764,0x38
|
||||
asm/non_matchings/code/z_parameter/Interface_SetNaviCall.s,Interface_SetNaviCall,0x80115764,0x38
|
||||
asm/non_matchings/code/z_parameter/func_80115844.s,func_80115844,0x80115844,0x31
|
||||
asm/non_matchings/code/z_parameter/func_80115908.s,func_80115908,0x80115908,0x2E
|
||||
asm/non_matchings/code/z_parameter/Health_ChangeBy.s,Health_ChangeBy,0x80115908,0x2E
|
||||
asm/non_matchings/code/z_parameter/Health_GiveHearts.s,Health_GiveHearts,0x801159C0,0xB
|
||||
asm/non_matchings/code/z_parameter/Rupees_ChangeBy.s,Rupees_ChangeBy,0x801159EC,0xA
|
||||
asm/non_matchings/code/z_parameter/Inventory_ChangeAmmo.s,Inventory_ChangeAmmo,0x80115A14,0xC0
|
||||
|
||||
|
Reference in New Issue
Block a user