aboutsummaryrefslogtreecommitdiff
path: root/simon/simon.cpp
diff options
context:
space:
mode:
authorMax Horn2002-10-31 01:27:05 +0000
committerMax Horn2002-10-31 01:27:05 +0000
commitb43410e6f6d855f1a42b6ce783d0c76df8f6632b (patch)
tree97c7428b173db8abdd5ff361e4a1251b23143055 /simon/simon.cpp
parent8d760a44ec72facbfc9c8f4b0740d3e905ee49ea (diff)
downloadscummvm-rg350-b43410e6f6d855f1a42b6ce783d0c76df8f6632b.tar.gz
scummvm-rg350-b43410e6f6d855f1a42b6ce783d0c76df8f6632b.tar.bz2
scummvm-rg350-b43410e6f6d855f1a42b6ce783d0c76df8f6632b.zip
some more cleanup
svn-id: r5360
Diffstat (limited to 'simon/simon.cpp')
-rw-r--r--simon/simon.cpp40
1 files changed, 15 insertions, 25 deletions
diff --git a/simon/simon.cpp b/simon/simon.cpp
index a3ef4a535b..529e5a2c2a 100644
--- a/simon/simon.cpp
+++ b/simon/simon.cpp
@@ -4936,42 +4936,32 @@ void SimonState::playMusic(uint music)
if (_game & GAME_WIN) {
_game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET);
- File *f = _game_file;
- midi.read_all_songs(f);
+ midi.read_all_songs(_game_file);
}
midi.initialize();
midi.play();
} else {
- if (_game == GAME_SIMON1DOS) {
-
midi.shutdown();
- char buf[50];
- File *f = new File();
- sprintf(buf, "MOD%d.MUS", music);
- f->open(buf, _gameDataPath);
- if (f->isOpen() == false) {
- warning("Cannot load music from '%s'", buf);
- return;
- }
- midi.read_all_songs_old(f);
- delete f;
-
- midi.initialize();
- midi.play();
+ if (_game == GAME_SIMON1DOS) {
+ char buf[50];
+ File *f = new File();
+ sprintf(buf, "MOD%d.MUS", music);
+ f->open(buf, _gameDataPath);
+ if (f->isOpen() == false) {
+ warning("Cannot load music from '%s'", buf);
+ return;
+ }
+ midi.read_all_songs_old(f);
+ delete f;
+ } else if (_game == GAME_SIMON1WIN) {
+ _game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET);
+ midi.read_all_songs_old(_game_file);
}
- if (_game == GAME_SIMON1WIN) {
-
- midi.shutdown();
-
- _game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET);
- File *f = _game_file;
- midi.read_all_songs_old(f);
midi.initialize();
midi.play();
- }
}
}