diff --git a/engines/kyra/detection.cpp b/engines/kyra/detection.cpp index 95573e83656..1bacaadc1a3 100644 --- a/engines/kyra/detection.cpp +++ b/engines/kyra/detection.cpp @@ -50,130 +50,11 @@ const char *const directoryGlobs[] = { nullptr }; -const ADExtraGuiOptionsMap gameGuiOptions[] = { - // Kyrandia 3 options - - { - GAMEOPTION_KYRA3_AUDIENCE, - { - // I18N: Studio audience adds an applause and cheering sounds whenever - // Malcolm makes a joke. - _s("Studio audience"), - _s("Enable studio audience"), - "studio_audience", - true, - 0, - 0 - } - }, - - { - GAMEOPTION_KYRA3_SKIP, - { - // I18N: This option allows the user to skip text and cutscenes. - _s("Skip support"), - _s("Allow text and cutscenes to be skipped"), - "skip_support", - true, - 0, - 0 - } - }, - - { - GAMEOPTION_KYRA3_HELIUM, - { - // I18N: Helium mode makes people sound like they've inhaled Helium. - _s("Helium mode"), - _s("Enable helium mode"), - "helium_mode", - false, - 0, - 0 - } - }, - - // LoL options - - { - GAMEOPTION_LOL_SCROLLING, - { - // I18N: When enabled, this option makes scrolling smoother when - // changing from one screen to another. - _s("Smooth scrolling"), - _s("Enable smooth scrolling when walking"), - "smooth_scrolling", - true, - 0, - 0 - } - }, - - { - GAMEOPTION_LOL_CURSORS, - { - // I18N: When enabled, this option changes the cursor when it floats to the - // edge of the screen to a directional arrow. The player can then click to - // walk towards that direction. - _s("Floating cursors"), - _s("Enable floating cursors"), - "floating_cursors", - false, - 0, - 0 - } - }, - - { - GAMEOPTION_LOL_SAVENAMES, - { - // I18N: When enabled, this option will fill in an autogenerated savegame - // description into the input prompt where. - _s("Suggest save names"), - _s("Autogenerated naming suggestions for savegames"), - "auto_savenames", - false, - 0, - 0 - } - }, - - // EoB options - - { - GAMEOPTION_EOB_HPGRAPHS, - { - // I18N: HP stands for Hit Points - _s("HP bar graphs"), - _s("Enable hit point bar graphs"), - "hpbargraphs", - true, - 0, - 0 - } - }, - - { - GAMEOPTION_EOB_MOUSESWAP, - { - // I18N: L/R stands for Left/Right - _s("Fight Button L/R Swap"), - _s("Left button to attack, right button to pick up items"), - "mousebtswap", - false, - 0, - 0 - } - }, - - AD_EXTRA_GUI_OPTIONS_TERMINATOR -}; - } // End of anonymous namespace class KyraMetaEngineDetection : public AdvancedMetaEngineDetection { public: - KyraMetaEngineDetection() : AdvancedMetaEngineDetection(adGameDescs, sizeof(KYRAGameDescription), gameList, gameGuiOptions) { + KyraMetaEngineDetection() : AdvancedMetaEngineDetection(adGameDescs, sizeof(KYRAGameDescription), gameList) { _md5Bytes = 1024 * 1024; _maxScanDepth = 2; _directoryGlobs = directoryGlobs; diff --git a/engines/kyra/detection.h b/engines/kyra/detection.h index 88b6d738365..add17e93ae6 100644 --- a/engines/kyra/detection.h +++ b/engines/kyra/detection.h @@ -70,6 +70,17 @@ struct KYRAGameDescription { Kyra::GameFlags flags; }; +#define GAMEOPTION_KYRA3_AUDIENCE GUIO_GAMEOPTIONS1 +#define GAMEOPTION_KYRA3_SKIP GUIO_GAMEOPTIONS2 +#define GAMEOPTION_KYRA3_HELIUM GUIO_GAMEOPTIONS3 + +#define GAMEOPTION_LOL_SCROLLING GUIO_GAMEOPTIONS4 +#define GAMEOPTION_LOL_CURSORS GUIO_GAMEOPTIONS5 +#define GAMEOPTION_LOL_SAVENAMES GUIO_GAMEOPTIONS8 + +#define GAMEOPTION_EOB_HPGRAPHS GUIO_GAMEOPTIONS6 +#define GAMEOPTION_EOB_MOUSESWAP GUIO_GAMEOPTIONS7 + } // End of anonymous namespace #endif // KYRA_DETECTION_H diff --git a/engines/kyra/detection_tables.h b/engines/kyra/detection_tables.h index 2bd824e1acc..41972c8851f 100644 --- a/engines/kyra/detection_tables.h +++ b/engines/kyra/detection_tables.h @@ -67,17 +67,6 @@ namespace { #define EOB2_FLAGS FLAGS(false, false, false, false, false, false, false, false, false, Kyra::GI_EOB2) #define EOB2_FMTOWNS_FLAGS FLAGS(false, false, false, false, true, false, true, false, false, Kyra::GI_EOB2) -#define GAMEOPTION_KYRA3_AUDIENCE GUIO_GAMEOPTIONS1 -#define GAMEOPTION_KYRA3_SKIP GUIO_GAMEOPTIONS2 -#define GAMEOPTION_KYRA3_HELIUM GUIO_GAMEOPTIONS3 - -#define GAMEOPTION_LOL_SCROLLING GUIO_GAMEOPTIONS4 -#define GAMEOPTION_LOL_CURSORS GUIO_GAMEOPTIONS5 -#define GAMEOPTION_LOL_SAVENAMES GUIO_GAMEOPTIONS8 - -#define GAMEOPTION_EOB_HPGRAPHS GUIO_GAMEOPTIONS6 -#define GAMEOPTION_EOB_MOUSESWAP GUIO_GAMEOPTIONS7 - static const char msg_missingLangResources[] = _s("Missing language specific game code and/or resources."); static const char msg_fanTrans_missingLangResources[] = _s("Missing language specific game code and/or resources for this fan translation."); static const char msg_fanTrans_unsupportiveTranslator[] = _s("The fan translator does not wish his translation to be incorporated into ScummVM."); diff --git a/engines/kyra/metaengine.cpp b/engines/kyra/metaengine.cpp index 7e92d0a1568..a1ed1ad7063 100644 --- a/engines/kyra/metaengine.cpp +++ b/engines/kyra/metaengine.cpp @@ -37,12 +37,135 @@ #include "kyra/detection.h" +const ADExtraGuiOptionsMap gameGuiOptions[] = { + // Kyrandia 3 options + + { + GAMEOPTION_KYRA3_AUDIENCE, + { + // I18N: Studio audience adds an applause and cheering sounds whenever + // Malcolm makes a joke. + _s("Studio audience"), + _s("Enable studio audience"), + "studio_audience", + true, + 0, + 0 + } + }, + + { + GAMEOPTION_KYRA3_SKIP, + { + // I18N: This option allows the user to skip text and cutscenes. + _s("Skip support"), + _s("Allow text and cutscenes to be skipped"), + "skip_support", + true, + 0, + 0 + } + }, + + { + GAMEOPTION_KYRA3_HELIUM, + { + // I18N: Helium mode makes people sound like they've inhaled Helium. + _s("Helium mode"), + _s("Enable helium mode"), + "helium_mode", + false, + 0, + 0 + } + }, + + // LoL options + + { + GAMEOPTION_LOL_SCROLLING, + { + // I18N: When enabled, this option makes scrolling smoother when + // changing from one screen to another. + _s("Smooth scrolling"), + _s("Enable smooth scrolling when walking"), + "smooth_scrolling", + true, + 0, + 0 + } + }, + + { + GAMEOPTION_LOL_CURSORS, + { + // I18N: When enabled, this option changes the cursor when it floats to the + // edge of the screen to a directional arrow. The player can then click to + // walk towards that direction. + _s("Floating cursors"), + _s("Enable floating cursors"), + "floating_cursors", + false, + 0, + 0 + } + }, + + { + GAMEOPTION_LOL_SAVENAMES, + { + // I18N: When enabled, this option will fill in an autogenerated savegame + // description into the input prompt where. + _s("Suggest save names"), + _s("Autogenerated naming suggestions for savegames"), + "auto_savenames", + false, + 0, + 0 + } + }, + + // EoB options + + { + GAMEOPTION_EOB_HPGRAPHS, + { + // I18N: HP stands for Hit Points + _s("HP bar graphs"), + _s("Enable hit point bar graphs"), + "hpbargraphs", + true, + 0, + 0 + } + }, + + { + GAMEOPTION_EOB_MOUSESWAP, + { + // I18N: L/R stands for Left/Right + _s("Fight Button L/R Swap"), + _s("Left button to attack, right button to pick up items"), + "mousebtswap", + false, + 0, + 0 + } + }, + + AD_EXTRA_GUI_OPTIONS_TERMINATOR +}; + class KyraMetaEngine : public AdvancedMetaEngine { public: const char *getName() const override { return "kyra"; } + const ADExtraGuiOptionsMap *getAdvancedExtraGuiOptions() const override { + return gameGuiOptions; + } + bool hasFeature(MetaEngineFeature f) const override; Common::Error createInstance(OSystem *syst, Engine **engine, const ADGameDescription *desc) const override;