summaryrefslogtreecommitdiff
path: root/soh/src
diff options
context:
space:
mode:
Diffstat (limited to 'soh/src')
-rw-r--r--soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c
index 1795e7db7..190442a17 100644
--- a/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c
+++ b/soh/src/overlays/gamestates/ovl_file_choose/z_file_choose.c
@@ -389,11 +389,11 @@ int retries = 0;
bool fileSelectSpoilerFileLoaded = false;
void FileChoose_UpdateRandomizer() {
- if (CVarGetInteger(CVAR_GENERAL("RandoGenerating"), 0) != 0 && generating == 0) {
+ if (Randomizer_IsGenerating() && generating == 0) {
generating = 1;
Audio_PlaySequenceWithSeqPlayerIO(SEQ_PLAYER_BGM_MAIN, NA_BGM_HORSE, 0, 7, 1);
return;
- } else if (CVarGetInteger(CVAR_GENERAL("RandoGenerating"), 0) == 0 && generating) {
+ } else if (!Randomizer_IsGenerating() && generating) {
if (Randomizer_IsSeedGenerated()) {
Audio_PlayFanfare(NA_BGM_HORSE_GOAL);
retries = 0;
@@ -463,6 +463,9 @@ void FileChoose_UpdateMainMenu(GameState* thisx) {
u8 isDefaultNameOptionSet;
FileChoose_UpdateRandomizer();
+ if (generating) {
+ return;
+ }
if (CHECK_BTN_ALL(input->press.button, BTN_START) || CHECK_BTN_ALL(input->press.button, BTN_A)) {
if (this->buttonIndex <= FS_BTN_MAIN_FILE_3) {
@@ -2544,6 +2547,7 @@ void FileChoose_LoadGame(GameState* thisx) {
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
gSaveContext.fileNum = this->buttonIndex;
gSaveContext.gameMode = GAMEMODE_NORMAL;
+ Randomizer_WaitForGeneration();
if ((this->buttonIndex == FS_BTN_SELECT_FILE_1 && CVarGetInteger(CVAR_DEVELOPER_TOOLS("DebugEnabled"), 0)) ||
this->buttonIndex == 0xFF) {