2018-11-10 12:21:23 -08:00
|
|
|
/* 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.
|
|
|
|
*
|
2021-12-26 18:47:58 +01:00
|
|
|
* 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.
|
2018-11-10 12:21:23 -08:00
|
|
|
*
|
|
|
|
* 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
|
2021-12-26 18:47:58 +01:00
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
2018-11-10 12:21:23 -08:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2020-06-22 20:06:26 -07:00
|
|
|
#ifndef GLK_ZCODE_DETECTION
|
|
|
|
#define GLK_ZCODE_DETECTION
|
2018-11-10 12:21:23 -08:00
|
|
|
|
|
|
|
#include "common/fs.h"
|
2018-12-14 18:25:20 -08:00
|
|
|
#include "common/hash-str.h"
|
2018-11-10 12:21:23 -08:00
|
|
|
#include "engines/game.h"
|
2018-11-25 22:07:10 -08:00
|
|
|
#include "glk/streams.h"
|
2018-12-31 19:47:14 -08:00
|
|
|
#include "glk/detection.h"
|
2018-11-10 12:21:23 -08:00
|
|
|
|
2018-11-13 20:05:59 -08:00
|
|
|
namespace Glk {
|
2020-06-22 20:06:26 -07:00
|
|
|
namespace ZCode {
|
2018-11-10 12:21:23 -08:00
|
|
|
|
2018-12-31 22:32:07 -08:00
|
|
|
/**
|
|
|
|
* Game descriptor detection options
|
|
|
|
*/
|
|
|
|
enum DetectionOption {
|
|
|
|
OPTION_INFOCOM = 1
|
|
|
|
};
|
|
|
|
|
2020-06-22 20:06:26 -07:00
|
|
|
class ZCodeMetaEngine {
|
2018-11-10 12:21:23 -08:00
|
|
|
public:
|
2018-11-14 18:01:42 -08:00
|
|
|
/**
|
|
|
|
* Get a list of supported games
|
|
|
|
*/
|
|
|
|
static void getSupportedGames(PlainGameList &games);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns a game description for the given game Id, if it's supported
|
|
|
|
*/
|
2018-12-31 19:47:14 -08:00
|
|
|
static GameDescriptor findGame(const char *gameId);
|
2018-11-14 18:01:42 -08:00
|
|
|
|
2018-11-10 12:21:23 -08:00
|
|
|
/**
|
|
|
|
* Detect supported games
|
|
|
|
*/
|
|
|
|
static bool detectGames(const Common::FSList &fslist, DetectedGames &gameList);
|
2018-11-25 22:07:10 -08:00
|
|
|
|
2018-12-14 18:25:20 -08:00
|
|
|
/**
|
|
|
|
* Check for game Id clashes with other sub-engines
|
|
|
|
*/
|
|
|
|
static void detectClashes(Common::StringMap &map);
|
2018-11-10 12:21:23 -08:00
|
|
|
};
|
|
|
|
|
2020-06-22 20:06:26 -07:00
|
|
|
} // End of namespace ZCode
|
2018-11-13 20:05:59 -08:00
|
|
|
} // End of namespace Glk
|
2018-11-10 12:21:23 -08:00
|
|
|
|
|
|
|
#endif
|