diff options
-rw-r--r-- | common/advancedDetector.cpp | 6 | ||||
-rw-r--r-- | common/advancedDetector.h | 4 |
2 files changed, 8 insertions, 2 deletions
diff --git a/common/advancedDetector.cpp b/common/advancedDetector.cpp index 210d6169ad..79289072df 100644 --- a/common/advancedDetector.cpp +++ b/common/advancedDetector.cpp @@ -161,11 +161,15 @@ static String generatePreferredTarget(const String &id, const ADGameDescription res = res + "-demo"; } + if (desc->flags & ADGF_CD) { + res = res + "-cd"; + } + if (desc->platform != kPlatformPC && desc->platform != kPlatformUnknown) { res = res + "-" + getPlatformAbbrev(desc->platform); } - if (desc->language != EN_ANY && desc->language != UNK_LANG) { + if (desc->language != EN_ANY && desc->language != UNK_LANG && !(desc->flags & ADGF_DROPLANGUAGE)) { res = res + "-" + getLanguageCode(desc->language); } diff --git a/common/advancedDetector.h b/common/advancedDetector.h index 9794ddabf5..2dc4b44b5f 100644 --- a/common/advancedDetector.h +++ b/common/advancedDetector.h @@ -46,7 +46,9 @@ struct ADGameFileDescription { enum ADGameFlags { ADGF_NO_FLAGS = 0, - ADGF_DEMO = (1 << 30) + ADGF_DROPLANGUAGE = (1 << 28), // don't add language to gameid + ADGF_CD = (1 << 29), // add "-cd" to gameid + ADGF_DEMO = (1 << 30) // add "-demo" to gameid }; struct ADGameDescription { |