diff options
Diffstat (limited to 'engines/wintermute/detection.cpp')
-rw-r--r-- | engines/wintermute/detection.cpp | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/engines/wintermute/detection.cpp b/engines/wintermute/detection.cpp index 1bf2c76a50..aca682ae99 100644 --- a/engines/wintermute/detection.cpp +++ b/engines/wintermute/detection.cpp @@ -8,12 +8,12 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * 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, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. @@ -68,12 +68,13 @@ static char s_fallbackGameIdBuf[256]; static const char *directoryGlobs[] = { "language", // To detect the various languages + "languages", // To detect the various languages 0 }; class WintermuteMetaEngine : public AdvancedMetaEngine { public: - WintermuteMetaEngine() : AdvancedMetaEngine(Wintermute::gameDescriptions, sizeof(ADGameDescription), Wintermute::wintermuteGames, gameGuiOptions) { + WintermuteMetaEngine() : AdvancedMetaEngine(Wintermute::gameDescriptions, sizeof(WMEGameDescription), Wintermute::wintermuteGames, gameGuiOptions) { _singleid = "wintermute"; _guioptions = GUIO2(GUIO_NOMIDI, GAMEOPTION_SHOW_FPS); _maxScanDepth = 2; @@ -106,11 +107,11 @@ public: } } // Prefix to avoid collisions with actually known games - name = "wmefan-" + name; + name = "wmeunk-" + name; Common::strlcpy(s_fallbackGameIdBuf, name.c_str(), sizeof(s_fallbackGameIdBuf) - 1); s_fallbackDesc.gameid = s_fallbackGameIdBuf; if (caption != name) { - caption += " (fangame) "; + caption += " (unknown version) "; char *offset = s_fallbackGameIdBuf + name.size() + 1; uint32 remainingLength = (sizeof(s_fallbackGameIdBuf) - 1) - (name.size() + 1); Common::strlcpy(offset, caption.c_str(), remainingLength); @@ -126,8 +127,8 @@ public: virtual bool createInstance(OSystem *syst, Engine **engine, const ADGameDescription *desc) const { assert(syst); assert(engine); - - *engine = new Wintermute::WintermuteEngine(syst, desc); + const WMEGameDescription *gd = (const WMEGameDescription *)desc; + *engine = new Wintermute::WintermuteEngine(syst, gd); return true; } @@ -181,10 +182,10 @@ public: } }; -} // end of namespace Wintermute +} // End of namespace Wintermute #if PLUGIN_ENABLED_DYNAMIC(WINTERMUTE) -REGISTER_PLUGIN_DYNAMIC(WINTERMUTE, PLUGIN_TYPE_ENGINE, Wintermute::WintermuteMetaEngine); + REGISTER_PLUGIN_DYNAMIC(WINTERMUTE, PLUGIN_TYPE_ENGINE, Wintermute::WintermuteMetaEngine); #else -REGISTER_PLUGIN_STATIC(WINTERMUTE, PLUGIN_TYPE_ENGINE, Wintermute::WintermuteMetaEngine); + REGISTER_PLUGIN_STATIC(WINTERMUTE, PLUGIN_TYPE_ENGINE, Wintermute::WintermuteMetaEngine); #endif |