aboutsummaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorMax Horn2004-02-07 16:01:00 +0000
committerMax Horn2004-02-07 16:01:00 +0000
commitd06316244e46f23948f809158b3051fb1411ebbd (patch)
tree98fe41e2ea80b444a5859b9edb112e9d41dce7a7 /common
parenta3f7753e9a0a147100ce23c07ebfb0c7451c95ea (diff)
downloadscummvm-rg350-d06316244e46f23948f809158b3051fb1411ebbd.tar.gz
scummvm-rg350-d06316244e46f23948f809158b3051fb1411ebbd.tar.bz2
scummvm-rg350-d06316244e46f23948f809158b3051fb1411ebbd.zip
Added FM-TOWNS to platforms list
svn-id: r12763
Diffstat (limited to 'common')
-rw-r--r--common/util.cpp25
-rw-r--r--common/util.h4
2 files changed, 18 insertions, 11 deletions
diff --git a/common/util.cpp b/common/util.cpp
index 4c4a293a2f..50d989528b 100644
--- a/common/util.cpp
+++ b/common/util.cpp
@@ -184,16 +184,23 @@ const char *getLanguageDescription(Language id) {
struct PlatformDescription {
const char *code;
+ const char *code2;
const char *description;
Common::Platform id;
};
static const PlatformDescription g_platforms[] = {
- {"pc", "PC", kPlatformPC},
- {"amiga", "Amiga", kPlatformAmiga},
- {"atari", "Atari ST", kPlatformAtariST},
- {"macintosh", "Macintosh", kPlatformMacintosh},
- {0, "Default", kPlatformUnknown}
+ {"pc", "dos", "PC", kPlatformPC},
+ {"amiga", "ami", "Amiga", kPlatformAmiga},
+ {"atari", "atari-st", "Atari ST", kPlatformAtariST},
+ {"macintosh", "mac", "Macintosh", kPlatformMacintosh},
+
+ // The 'official' spelling seems to be "FM-TOWNS" (e.g. in the Indy4 demo).
+ // However, on the net many variations can be seen, like "FMTOWNS",
+ // "FM TOWNS", "FmTowns", etc.
+ {"fmtowns", "towns", "FM-TOWNS", kPlatformFMTowns},
+
+ {0, 0, "Default", kPlatformUnknown}
};
Platform parsePlatform(const String &str) {
@@ -204,16 +211,16 @@ Platform parsePlatform(const String &str) {
// Handle some special case separately, for compatibility with old config
// files.
- if (!scumm_stricmp(s, "amiga") || !scumm_stricmp(s, "1"))
+ if (!strcmp(s, "1"))
return kPlatformAmiga;
- else if (!scumm_stricmp(s, "atari-st") || !scumm_stricmp(s, "2"))
+ else if (!strcmp(s, "2"))
return kPlatformAtariST;
- else if (!scumm_stricmp(s, "mac") || !scumm_stricmp(s, "3"))
+ else if (!strcmp(s, "3"))
return kPlatformMacintosh;
const PlatformDescription *l = g_platforms;
for (; l->code; ++l) {
- if (!scumm_stricmp(l->code, s))
+ if (!scumm_stricmp(l->code, s) || !scumm_stricmp(l->code2, s))
return l->id;
}
diff --git a/common/util.h b/common/util.h
index 9e103f1229..65c7b1cb5d 100644
--- a/common/util.h
+++ b/common/util.h
@@ -137,11 +137,11 @@ enum Platform {
kPlatformPC = 0,
kPlatformAmiga = 1,
kPlatformAtariST = 2,
- kPlatformMacintosh = 3
+ kPlatformMacintosh = 3,
+ kPlatformFMTowns = 4
/*
kPlatformNES,
kPlatformSEGA,
- kPlatformFMTowns,
kPlatformPCEngine
*/
};