diff options
author | David Corrales | 2007-08-05 19:34:20 +0000 |
---|---|---|
committer | David Corrales | 2007-08-05 19:34:20 +0000 |
commit | 6856535010bd2fa4449bcfde1c88dc06cd46e26f (patch) | |
tree | b81a2234c2beff0312c93e039d6cafda4babeca6 /engines/parallaction/detection.cpp | |
parent | 1400d28bfb37fc94f3c44dec0a4d0cef65fb8fb7 (diff) | |
parent | ec1803f838d5efc7decf75c05a1fb4a9633751e5 (diff) | |
download | scummvm-rg350-6856535010bd2fa4449bcfde1c88dc06cd46e26f.tar.gz scummvm-rg350-6856535010bd2fa4449bcfde1c88dc06cd46e26f.tar.bz2 scummvm-rg350-6856535010bd2fa4449bcfde1c88dc06cd46e26f.zip |
Merged fsnode with trunk: r27971:28460
svn-id: r28462
Diffstat (limited to 'engines/parallaction/detection.cpp')
-rw-r--r-- | engines/parallaction/detection.cpp | 50 |
1 files changed, 47 insertions, 3 deletions
diff --git a/engines/parallaction/detection.cpp b/engines/parallaction/detection.cpp index 8e069c5f08..84c45584a4 100644 --- a/engines/parallaction/detection.cpp +++ b/engines/parallaction/detection.cpp @@ -27,6 +27,7 @@ #include "base/plugins.h" +#include "common/config-manager.h" #include "common/advancedDetector.h" #include "parallaction/parallaction.h" @@ -47,8 +48,8 @@ Common::Platform Parallaction::getPlatform() const { return _gameDescription->de } static const PlainGameDescriptor parallactionGames[] = { - {"parallaction", "Parallaction engine game"}, {"nippon", "Nippon Safes Inc."}, + {"bra", "The Big Red Adventure"}, {0, 0} }; @@ -140,6 +141,24 @@ static const PARALLACTIONGameDescription gameDescriptions[] = { GF_LANG_IT, }, + { + { + "bra", + "Multi-lingual", + { + {"tbra.bmp", 0, "3174c095a0e1a4eaf05c403445711e9b", 80972 }, + {"russia.fnt", 0, "57f85ff62aeca6334fdcaf718e313b49", 18344 }, + {NULL, 0, NULL, 0 } + }, + Common::UNK_LANG, + Common::kPlatformPC, + Common::ADGF_NO_FLAGS + }, + GType_BRA, + GF_LANG_EN | GF_LANG_FR | GF_LANG_DE | GF_LANG_IT | GF_LANG_MULT + }, + + { AD_TABLE_END_MARKER, 0, 0 } }; @@ -157,7 +176,7 @@ static const Common::ADParams detectionParams = { // Structure for autoupgrading obsolete targets 0, // Name of single gameid (optional) - "parallaction", + 0, // List of files for file-based fallback detection (optional) 0, // Fallback callback @@ -166,7 +185,32 @@ static const Common::ADParams detectionParams = { Common::kADFlagAugmentPreferredTarget }; -ADVANCED_DETECTOR_DEFINE_PLUGIN(PARALLACTION, Parallaction::Parallaction, detectionParams); +GameList Engine_PARALLACTION_gameIDList() { + return GameList(parallactionGames); +} + +GameDescriptor Engine_PARALLACTION_findGameID(const char *gameid) { + return Common::AdvancedDetector::findGameID(gameid, parallactionGames); +} + +GameList Engine_PARALLACTION_detectGames(const FSList &fslist) { + return Common::AdvancedDetector::detectAllGames(fslist, detectionParams); +} + +PluginError Engine_PARALLACTION_create(OSystem *syst, Engine **engine) { + assert(engine); + const char *gameid = ConfMan.get("gameid").c_str(); + + if (!scumm_stricmp("nippon", gameid)) { + *engine = new Parallaction::Parallaction_ns(syst); + } else + if (!scumm_stricmp("bra", gameid)) { + *engine = new Parallaction::Parallaction_br(syst); + } else + error("Parallaction engine created with invalid gameid ('%s')", gameid); + + return kNoError; +} REGISTER_PLUGIN(PARALLACTION, "Parallaction engine", "Nippon Safes Inc. (C) Dynabyte"); |