summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--soh/soh/Enhancements/GameplayStats/BossDefeatTimestamps.cpp5
-rw-r--r--soh/soh/Enhancements/gameplaystats.h8
-rw-r--r--soh/soh/Enhancements/randomizer/hook_handlers.cpp2
3 files changed, 9 insertions, 6 deletions
diff --git a/soh/soh/Enhancements/GameplayStats/BossDefeatTimestamps.cpp b/soh/soh/Enhancements/GameplayStats/BossDefeatTimestamps.cpp
index 7c57ed7dc..f8ca31b56 100644
--- a/soh/soh/Enhancements/GameplayStats/BossDefeatTimestamps.cpp
+++ b/soh/soh/Enhancements/GameplayStats/BossDefeatTimestamps.cpp
@@ -1,5 +1,6 @@
#include "soh/Enhancements/game-interactor/GameInteractor.h"
#include "soh/ShipInit.hpp"
+#include "soh/Enhancements/randomizer/SeedContext.h"
extern "C" {
#include "z64save.h"
@@ -23,7 +24,9 @@ static void RegisterBossDefeatTimestamps() {
BOSS_DEFEAT_TIMESTAMP(ACTOR_BOSS_GANON, TIMESTAMP_DEFEAT_GANONDORF);
COND_ID_HOOK(OnBossDefeat, ACTOR_BOSS_GANON2, true, [](void* refActor) {
gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_DEFEAT_GANON] = static_cast<u32>(GAMEPLAYSTAT_TOTAL_TIME);
- gSaveContext.ship.stats.gameComplete = true;
+ if (!IS_RANDO || RAND_GET_OPTION(RSK_WINCON).Is(RO_WINCON_DEFEAT_GANON)) {
+ gSaveContext.ship.stats.gameComplete = true;
+ }
});
}
diff --git a/soh/soh/Enhancements/gameplaystats.h b/soh/soh/Enhancements/gameplaystats.h
index bf9d651a6..e9121bfc4 100644
--- a/soh/soh/Enhancements/gameplaystats.h
+++ b/soh/soh/Enhancements/gameplaystats.h
@@ -25,10 +25,10 @@ char* GameplayStats_GetCurrentTime();
? (!gSaveContext.ship.stats.firstInput \
? 0 \
: ((GetUnixTimestamp() - gSaveContext.ship.stats.firstInput) / 100)) \
- : (gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_DEFEAT_GANON] \
- ? gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_DEFEAT_GANON] \
- : (gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_TRIFORCE_COMPLETED] \
- ? gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_TRIFORCE_COMPLETED] \
+ : (gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_TRIFORCE_COMPLETED] \
+ ? gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_TRIFORCE_COMPLETED] \
+ : (gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_DEFEAT_GANON] \
+ ? gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_DEFEAT_GANON] \
: gSaveContext.ship.stats.itemTimestamp[TIMESTAMP_TIMESPLITS_COMPLETED]))) \
: (gSaveContext.ship.stats.playTimer / 2 + gSaveContext.ship.stats.pauseTimer / 3))
#define CURRENT_MODE_TIMER \
diff --git a/soh/soh/Enhancements/randomizer/hook_handlers.cpp b/soh/soh/Enhancements/randomizer/hook_handlers.cpp
index 6d329f823..d501c8e5a 100644
--- a/soh/soh/Enhancements/randomizer/hook_handlers.cpp
+++ b/soh/soh/Enhancements/randomizer/hook_handlers.cpp
@@ -1872,7 +1872,7 @@ void RandomizerOnVanillaBehaviorHandler(GIVanillaBehavior id, bool* should, va_l
Flags_SetRandomizerInf(RAND_INF_DUNGEONS_DONE_GANONS_TOWER);
randomizerQueuedChecks.push(RC_GANON);
CheckTriggers();
- gPlayState->nextEntranceIndex = ENTR_OUTSIDE_GANONS_CASTLE_1_2;
+ gPlayState->nextEntranceIndex = Entrance_OverrideNextIndex(ENTR_OUTSIDE_GANONS_CASTLE_1_2);
gPlayState->transitionTrigger = TRANS_TRIGGER_START;
gPlayState->transitionType = TRANS_TYPE_FADE_WHITE;
gSaveContext.nextTransitionType = TRANS_TYPE_FADE_WHITE_SLOW;