Merge pull request #620 from Henny022p/savefile

SaveFile cleanup
This commit is contained in:
notyourav
2023-08-06 18:52:38 -07:00
committed by GitHub
35 changed files with 233 additions and 192 deletions
+1 -1
View File
@@ -440,7 +440,7 @@ void sub_0806D5D4(void) {
}
void sub_0806D600(Entity* this, ScriptExecutionContext* context) {
context->condition = gSave.timers[2] == 0;
context->condition = gSave.biggoron_timer == 0;
}
void sub_0806D620(void) {
+2 -2
View File
@@ -723,13 +723,13 @@ void sub_08060318(void) {
}
void sub_08060340(void) {
gSave.timers[1] = gSave.unk50;
gSave.drug_kill_count = gSave.enemies_killed;
}
u32 sub_08060354(void) {
s32 iVar2;
iVar2 = gSave.unk50 - gSave.timers[1];
iVar2 = gSave.enemies_killed - gSave.drug_kill_count;
if (CheckGlobalFlag(DRUG_1) == 0) {
if (4 < iVar2) {
return 0x8444;
+1 -1
View File
@@ -197,7 +197,7 @@ void sub_0806387C(Entity* this) {
if (CheckLocalFlag(SHOP05_OPEN) == 0) {
r5 = 0;
for (r4 = 1; r4 <= 0x82; r4++) {
if (ReadBit(&gSave.stats.filler4[4], r4)) {
if (ReadBit(gSave.figurines, r4)) {
r5++;
}
}
+3 -3
View File
@@ -264,11 +264,11 @@ void sub_08065370(Entity* this, ScriptExecutionContext* context) {
if (localFlag) {
SetLocalFlag(localFlag);
}
if (gSave.unk5C <= ~1u) {
gSave.unk5C++;
if (gSave.items_bought <= ~1u) {
gSave.items_bought++;
}
if (gSave.unk5C >= 10) {
if (gSave.items_bought >= 10) {
context->intVariable = TEXT_INDEX(TEXT_STOCKWELL, 0x11);
} else {
if (itemPrice >= 100) {