Skip to content

Commit

Permalink
[TD] Fix loading of zounds.mix.
Browse files Browse the repository at this point in the history
Loading was previously gated behind a check for Special.IsJuvenile which isn't set until later in the init process.
  • Loading branch information
OmniBlade authored and giulianobelinassi committed Jun 25, 2024
1 parent 69c2455 commit d07e8da
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions tiberiandawn/init.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -511,10 +511,6 @@ bool Init_Game(int, char*[])
MFCD::Cache("CONQUER.MIX");
if (SampleType != 0 && !Debug_Quiet) {
MFCD::Cache("SOUNDS.MIX");
if (Special.IsJuvenile) {
new MFCD("ZOUNDS.MIX"); // Cached.
MFCD::Cache("ZOUNDS.MIX");
}
}
}
Call_Back();
Expand Down Expand Up @@ -618,6 +614,14 @@ bool Init_Game(int, char*[])
*/
Options.Load_Settings();

/*
** Now that conquer.ini has been read, we can check if we need zounds.mix.
*/
if (!Is_Demo() && SampleType != 0 && !Debug_Quiet && Special.IsJuvenile) {
new MFCD("ZOUNDS.MIX");
MFCD::Cache("ZOUNDS.MIX");
}

/*
** Dump a default copy of rules.ini.
*/
Expand Down

0 comments on commit d07e8da

Please sign in to comment.