Skip to content

Commit

Permalink
GROOVIE: Detect if external music exists for the Music Enhancement Pr…
Browse files Browse the repository at this point in the history
…oject.

T7G's music framework uses either all external or all XMIDI, so assume if one
external song is present, the entire music pack is.
  • Loading branch information
scott-t committed Mar 24, 2012
1 parent 783b917 commit 19d3633
Showing 1 changed file with 19 additions and 13 deletions.
32 changes: 19 additions & 13 deletions engines/groovie/groovie.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -152,20 +152,26 @@ Common::Error GroovieEngine::run() {
break;
}

// Create the music player
switch (getPlatform()) {
case Common::kPlatformMacintosh:
// TODO: The 11th Hour Mac uses QuickTime MIDI files
// Right now, since the XMIDI are present and it is still detected as
// the DOS version, we don't have to do anything here.
_musicPlayer = new MusicPlayerMac(this);
break;
case Common::kPlatformIOS:
// Detect ScummVM Music Enhancement Project presence (T7G only)
if (Common::File::exists("gu16.ogg") && _gameDescription->version == kGroovieT7G) {
// Load player for external files
_musicPlayer = new MusicPlayerIOS(this);
break;
default:
_musicPlayer = new MusicPlayerXMI(this, _gameDescription->version == kGroovieT7G ? "fat" : "sample");
break;
} else {
// Create the music player
switch (getPlatform()) {
case Common::kPlatformMacintosh:
// TODO: The 11th Hour Mac uses QuickTime MIDI files
// Right now, since the XMIDI are present and it is still detected as
// the DOS version, we don't have to do anything here.
_musicPlayer = new MusicPlayerMac(this);
break;
case Common::kPlatformIOS:
_musicPlayer = new MusicPlayerIOS(this);
break;
default:
_musicPlayer = new MusicPlayerXMI(this, _gameDescription->version == kGroovieT7G ? "fat" : "sample");
break;
}
}

// Load volume levels
Expand Down

0 comments on commit 19d3633

Please sign in to comment.