diff --git a/engines/freescape/POTFILES b/engines/freescape/POTFILES index 69559eb9fe8..c594a893e04 100644 --- a/engines/freescape/POTFILES +++ b/engines/freescape/POTFILES @@ -1 +1 @@ -engines/freescape/detection.cpp +engines/freescape/metaengine.cpp diff --git a/engines/freescape/detection.cpp b/engines/freescape/detection.cpp index f1cf0883d80..22ebd9d293d 100644 --- a/engines/freescape/detection.cpp +++ b/engines/freescape/detection.cpp @@ -19,11 +19,8 @@ * */ -#include "common/translation.h" - #include "freescape/freescape.h" - -#define GAMEOPTION_PRERECORDED_SOUNDS GUIO_GAMEOPTIONS1 +#include "freescape/detection.h" namespace Freescape { @@ -252,24 +249,9 @@ static const DebugChannelDef debugFlagList[] = { DEBUG_CHANNEL_END }; -static const ADExtraGuiOptionsMap optionsList[] = { - { - GAMEOPTION_PRERECORDED_SOUNDS, - { - _s("Prerecorded sounds"), - _s("Use high-quality pre-recorded sounds instead of pc speaker emulation"), - "prerecorded_sounds", - true, - 0, - 0 - } - }, - AD_EXTRA_GUI_OPTIONS_TERMINATOR -}; - class FreescapeMetaEngineDetection : public AdvancedMetaEngineDetection { public: - FreescapeMetaEngineDetection() : AdvancedMetaEngineDetection(Freescape::gameDescriptions, sizeof(ADGameDescription), Freescape::freescapeGames, optionsList) { + FreescapeMetaEngineDetection() : AdvancedMetaEngineDetection(Freescape::gameDescriptions, sizeof(ADGameDescription), Freescape::freescapeGames) { _guiOptions = GUIO2(GUIO_NOMIDI, GAMEOPTION_PRERECORDED_SOUNDS); } diff --git a/engines/freescape/detection.h b/engines/freescape/detection.h new file mode 100644 index 00000000000..f48383ff3c1 --- /dev/null +++ b/engines/freescape/detection.h @@ -0,0 +1,27 @@ +/* ScummVM - Graphic Adventure Engine + * + * ScummVM is the legal property of its developers, whose names + * are too numerous to list here. Please refer to the COPYRIGHT + * file distributed with this source distribution. + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + */ + +#ifndef FREESCAPE_DETECTION_H +#define FREESCAPE_DETECTION_H + +#define GAMEOPTION_PRERECORDED_SOUNDS GUIO_GAMEOPTIONS1 + +#endif diff --git a/engines/freescape/metaengine.cpp b/engines/freescape/metaengine.cpp index 6b96ee7658b..2b521de313a 100644 --- a/engines/freescape/metaengine.cpp +++ b/engines/freescape/metaengine.cpp @@ -19,7 +19,25 @@ * */ +#include "common/translation.h" + #include "freescape/freescape.h" +#include "freescape/detection.h" + +static const ADExtraGuiOptionsMap optionsList[] = { + { + GAMEOPTION_PRERECORDED_SOUNDS, + { + _s("Prerecorded sounds"), + _s("Use high-quality pre-recorded sounds instead of pc speaker emulation"), + "prerecorded_sounds", + true, + 0, + 0 + } + }, + AD_EXTRA_GUI_OPTIONS_TERMINATOR +}; class FreescapeMetaEngine : public AdvancedMetaEngine { public: @@ -27,6 +45,10 @@ public: return "freescape"; } + const ADExtraGuiOptionsMap *getAdvancedExtraGuiOptions() const override { + return optionsList; + } + Common::Error createInstance(OSystem *syst, Engine **engine, const ADGameDescription *gd) const override; };