mirror of
https://github.com/zeldaret/tmc
synced 2026-09-07 11:21:35 -04:00
Match GenerateAreaHint
This commit is contained in:
+3
-3
@@ -374,7 +374,7 @@ static void GameMain_ChangeRoom(void) {
|
||||
SetPlayerControl(0);
|
||||
gPauseMenuOptions.disabled = 0;
|
||||
#if defined(USA) || defined(DEMO_USA)
|
||||
if (gArea.inventoryGfxIdx != 0xff) {
|
||||
if (gArea.unk28.inventoryGfxIdx != 0xff) {
|
||||
sub_0801855C();
|
||||
}
|
||||
CreateManagerF();
|
||||
@@ -384,13 +384,13 @@ static void GameMain_ChangeRoom(void) {
|
||||
sub_0801855C();
|
||||
#elif defined(JP)
|
||||
CheckAreaDiscovery();
|
||||
if (gArea.inventoryGfxIdx != 0xff) {
|
||||
if (gArea.unk28.inventoryGfxIdx != 0xff) {
|
||||
sub_0801855C();
|
||||
}
|
||||
#elif defined(DEMO_JP)
|
||||
if (gRoomTransition.field_0x2c[4])
|
||||
CheckAreaDiscovery();
|
||||
if (gArea.inventoryGfxIdx != 0xff) {
|
||||
if (gArea.unk28.inventoryGfxIdx != 0xff) {
|
||||
sub_0801855C();
|
||||
}
|
||||
CreateManagerF();
|
||||
|
||||
+33
-3
@@ -28,6 +28,36 @@ void sub_08018B50(int);
|
||||
void sub_080189EC(int);
|
||||
void sub_0801876C(int, int);
|
||||
void sub_08018738(u32, int);
|
||||
void sub_08018690(int param_1, u16* param_2);
|
||||
|
||||
void GenerateAreaHint(void) {
|
||||
u16 uVar1;
|
||||
struct_area_28* ptr;
|
||||
|
||||
gPlayerState.queued_action = 0x16;
|
||||
#if defined(EU) || defined(JP)
|
||||
// TODO what fields of the room transition are switched in these variants?
|
||||
gRoomTransition.field_0x2c[7] = 0;
|
||||
#else
|
||||
gRoomTransition.hint_height = 0;
|
||||
#endif
|
||||
ptr = &gArea.unk28;
|
||||
if (ptr->inventoryGfxIdx == 0xff) {
|
||||
gRoomTransition.hint_idx = ptr->unk2C[0];
|
||||
} else {
|
||||
gRoomTransition.hint_idx = ptr->unk2C[ptr->unk2a];
|
||||
ptr->unk2a++;
|
||||
if (ptr->unk2a > 7) {
|
||||
ptr->unk2a = 0;
|
||||
sub_08018690(8, ptr->unk2C);
|
||||
if (ptr->unk2C[0] == gRoomTransition.hint_idx) {
|
||||
uVar1 = ptr->unk2C[0];
|
||||
ptr->unk2C[0] = ptr->unk3E;
|
||||
ptr->unk3E = uVar1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void sub_08018690(int param_1, u16* param_2) {
|
||||
u32 uVar1;
|
||||
@@ -54,12 +84,12 @@ void sub_08018690(int param_1, u16* param_2) {
|
||||
}
|
||||
|
||||
void sub_080186C0(u32 param_1) {
|
||||
gArea.inventoryGfxIdx = 0xff;
|
||||
gArea.unk2C = param_1;
|
||||
gArea.unk28.inventoryGfxIdx = 0xff;
|
||||
gArea.unk28.unk2C[0] = param_1;
|
||||
}
|
||||
|
||||
void sub_080186D4(void) {
|
||||
if (gArea.inventoryGfxIdx == 0xff) {
|
||||
if (gArea.unk28.inventoryGfxIdx == 0xff) {
|
||||
sub_0801855C();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -147,7 +147,7 @@ static void sub_08058514(ManagerA* this) {
|
||||
}
|
||||
|
||||
static void sub_080585B0(ManagerA* this) {
|
||||
if (gArea.inventoryGfxIdx != 0xFF) {
|
||||
if (gArea.unk28.inventoryGfxIdx != 0xFF) {
|
||||
DeleteThisEntity();
|
||||
}
|
||||
if (CheckFlags(this->flag1)) {
|
||||
|
||||
@@ -414,10 +414,10 @@ void sub_080594DC(ManagerF* this) {
|
||||
break;
|
||||
case 2:
|
||||
default:
|
||||
if (gArea.inventoryGfxIdx != 0xFF) {
|
||||
if (gArea.unk28.inventoryGfxIdx != 0xFF) {
|
||||
DeleteThisEntity();
|
||||
}
|
||||
if (CheckLocalFlagByBank(0x8c0, 0x85)) {
|
||||
if (CheckLocalFlagByBank(FLAG_BANK_10, 0x85)) {
|
||||
sub_0801855C();
|
||||
DeleteThisEntity();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user