aboutsummaryrefslogtreecommitdiff
path: root/gameDetector.cpp
diff options
context:
space:
mode:
authorMax Horn2002-04-28 00:31:31 +0000
committerMax Horn2002-04-28 00:31:31 +0000
commit6b8638cd0540ec16927ff67c9b6b7f55382c9de7 (patch)
tree7170b9fc03c3d316facc36159368f374b8691c2f /gameDetector.cpp
parent28778e07f78d68bcd7e7976a94ba5345795684d2 (diff)
downloadscummvm-rg350-6b8638cd0540ec16927ff67c9b6b7f55382c9de7.tar.gz
scummvm-rg350-6b8638cd0540ec16927ff67c9b6b7f55382c9de7.tar.bz2
scummvm-rg350-6b8638cd0540ec16927ff67c9b6b7f55382c9de7.zip
spaces to tabs; don't hard code midi driver ID on MacOS
svn-id: r4119
Diffstat (limited to 'gameDetector.cpp')
-rw-r--r--gameDetector.cpp84
1 files changed, 42 insertions, 42 deletions
diff --git a/gameDetector.cpp b/gameDetector.cpp
index 7e85131a56..805b1bcfe1 100644
--- a/gameDetector.cpp
+++ b/gameDetector.cpp
@@ -61,37 +61,37 @@ static const char USAGE_STRING[] =
void GameDetector::updateconfig()
{
- const char * val;
+ const char * val;
- if ((val = scummcfg->get("amiga")))
- if (!scumm_stricmp(val, "true"))
- _amiga = true;
- else
- _amiga = false;
+ if ((val = scummcfg->get("amiga")))
+ if (!scumm_stricmp(val, "true"))
+ _amiga = true;
+ else
+ _amiga = false;
- if ((val = scummcfg->get("fullscreen", "scummvm")))
- if (!scumm_stricmp(val, "true"))
- _fullScreen = true;
- else
- _fullScreen = false;
+ if ((val = scummcfg->get("fullscreen", "scummvm")))
+ if (!scumm_stricmp(val, "true"))
+ _fullScreen = true;
+ else
+ _fullScreen = false;
- if ((val = scummcfg->get("path")))
- _gameDataPath = Scumm::Strdup(val);
+ if ((val = scummcfg->get("path")))
+ _gameDataPath = Scumm::Strdup(val);
- if ((val = scummcfg->get("tempo")))
- _gameTempo = strtol(val, 0, 0);
+ if ((val = scummcfg->get("tempo")))
+ _gameTempo = strtol(val, 0, 0);
- if ((val = scummcfg->get("music_volume")))
- _music_volume = atoi(val);
+ if ((val = scummcfg->get("music_volume")))
+ _music_volume = atoi(val);
- if ((val = scummcfg->get("sfx_volume")))
- _sfx_volume = atoi(val);
+ if ((val = scummcfg->get("sfx_volume")))
+ _sfx_volume = atoi(val);
- if ((val = scummcfg->get("mt32emulate")))
- if (!scumm_stricmp(val, "true"))
- _mt32emulate = true;
- else
- _mt32emulate = false;
+ if ((val = scummcfg->get("mt32emulate")))
+ if (!scumm_stricmp(val, "true"))
+ _mt32emulate = true;
+ else
+ _mt32emulate = false;
if ((val = scummcfg->get("nosubtitles")))
if (!scumm_stricmp(val, "true"))
@@ -99,22 +99,22 @@ void GameDetector::updateconfig()
else
_noSubtitles = false;
- if ((val = scummcfg->get("music_driver")))
- if (!parseMusicDriver(val)) {
- printf("Error in the config file: invalid music_driver.\n");
- printf(USAGE_STRING);
- exit(-1);
- }
-
- if ((val = scummcfg->get("gfx_mode")))
- if ((_gfx_mode = parseGraphicsMode(val)) == -1) {
- printf("Error in the config file: invalid gfx_mode.\n");
- printf(USAGE_STRING);
- exit(-1);
- }
-
- if ((val = scummcfg->get("cdrom")))
- _cdrom = atoi(val);
+ if ((val = scummcfg->get("music_driver")))
+ if (!parseMusicDriver(val)) {
+ printf("Error in the config file: invalid music_driver.\n");
+ printf(USAGE_STRING);
+ exit(-1);
+ }
+
+ if ((val = scummcfg->get("gfx_mode")))
+ if ((_gfx_mode = parseGraphicsMode(val)) == -1) {
+ printf("Error in the config file: invalid gfx_mode.\n");
+ printf(USAGE_STRING);
+ exit(-1);
+ }
+
+ if ((val = scummcfg->get("cdrom")))
+ _cdrom = atoi(val);
}
void GameDetector::parseCommandLine(int argc, char **argv)
@@ -206,7 +206,7 @@ void GameDetector::parseCommandLine(int argc, char **argv)
goto ShowHelpAndExit;
_gameDataPath = s;
scummcfg->set("path", _gameDataPath);
- goto NextArg;
+ goto NextArg;
case 'r':
_mt32emulate = true;
scummcfg->set("mt32emulate", "true");
@@ -260,7 +260,7 @@ void GameDetector::parseCommandLine(int argc, char **argv)
if (_saveconfig)
scummcfg->flush();
#else
- _midi_driver = 4; /* FIXME: don't use numerics */
+ _midi_driver = MD_QTMUSIC;
_exe_name = *argv;
_gameDataPath = (char *)malloc(strlen(_exe_name) + 3);
sprintf(_gameDataPath, ":%s:", _exe_name);