From 9df3c85184b10a71be27209313efbc23974d1225 Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Thu, 21 Nov 2019 06:47:49 -0800 Subject: GLK: MAGNETIC: Making functions all class methods, statics into class fields --- engines/glk/magnetic/detection.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'engines/glk/magnetic/detection.cpp') diff --git a/engines/glk/magnetic/detection.cpp b/engines/glk/magnetic/detection.cpp index cc1714eaf1..54a0e7b928 100644 --- a/engines/glk/magnetic/detection.cpp +++ b/engines/glk/magnetic/detection.cpp @@ -75,7 +75,7 @@ bool MagneticMetaEngine::detectGames(const Common::FSList &fslist, DetectedGames gameFile.close(); // Check for known games - const MagneticGameDescription *p = MAGNETIC_GAMES; + const GlkDetectionEntry *p = MAGNETIC_GAMES; while (p->_gameId && (md5 != p->_md5 || filesize != p->_filesize)) ++p; @@ -99,5 +99,16 @@ void MagneticMetaEngine::detectClashes(Common::StringMap &map) { } } +const gms_game_table_t *gms_gameid_lookup_game(uint32 undo_size, uint32 undo_pc) { + const gms_game_table_t *game; + + for (game = GMS_GAME_TABLE; game->name; game++) { + if (game->undo_size == undo_size && game->undo_pc == undo_pc) + break; + } + + return game->name ? game : nullptr; +} + } // End of namespace Magnetic } // End of namespace Glk -- cgit v1.2.3