Small midi cleanup

svn-id: r7929
This commit is contained in:
Travis Howell 2003-05-25 03:31:01 +00:00
parent 64e66a4500
commit 3e6cf17744

View File

@ -5299,20 +5299,6 @@ void SimonState::loadMusic (uint music) {
}
// TODO Add Protracker support for simon1amiga/cd32
warning("playMusic - Load %dtune attempt", music);
} else if (_game & GF_DEMO) {
midi.stop();
midi.setLoop (true);
char buf[50];
File *f = new File();
sprintf(buf, "MOD%d.MUS", music);
f->open(buf, _gameDataPath);
if (f->isOpen() == false) {
warning("Can't load music from '%s'", buf);
return;
}
midi.loadS1D (f);
delete f;
midi.startTrack (0);
} else {
midi.stop();
midi.setLoop (true); // Must do this BEFORE loading music. (GMF may have its own override.)
@ -5340,7 +5326,10 @@ void SimonState::loadMusic (uint music) {
warning("Can't load music from '%s'", buf);
return;
}
midi.loadSMF (f, music);
if (_game & GF_DEMO)
midi.loadS1D (f);
else
midi.loadSMF (f, music);
delete f;
}