Skip to content

Commit

Permalink
fix subsong parameter ignored when using output
Browse files Browse the repository at this point in the history
  • Loading branch information
tildearrow committed Oct 18, 2023
1 parent 148e06a commit f31bb1b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -630,6 +630,11 @@ int main(int argc, char** argv) {
displayEngineFailError=true;
}
}

if (subsong!=-1) {
e.changeSongP(subsong);
}

if (benchMode) {
logI("starting benchmark!");
if (benchMode==2) {
Expand All @@ -640,6 +645,7 @@ int main(int argc, char** argv) {
finishLogFile();
return 0;
}

if (outName!="" || vgmOutName!="" || cmdOutName!="") {
if (cmdOutName!="") {
SafeWriter* w=e.saveCommand(cmdOutBinary);
Expand Down Expand Up @@ -682,10 +688,6 @@ int main(int argc, char** argv) {
return 0;
}

if (subsong!=-1) {
e.changeSongP(subsong);
}

if (consoleMode) {
bool cliSuccess=false;
cli.bindEngine(&e);
Expand Down

0 comments on commit f31bb1b

Please sign in to comment.