2014-05-16 21:58:49 +02: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.
|
2014-05-16 21:58:49 +02: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/>.
|
2014-05-16 21:58:49 +02:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
#include "bladerunner/bladerunner.h"
|
2020-08-25 13:52:43 +05:30
|
|
|
#include "bladerunner/detection_tables.h"
|
2018-11-21 23:16:15 +01:00
|
|
|
#include "bladerunner/savefile.h"
|
|
|
|
|
|
|
|
#include "common/config-manager.h"
|
|
|
|
#include "common/system.h"
|
|
|
|
#include "common/savefile.h"
|
|
|
|
#include "common/serializer.h"
|
2019-02-10 19:45:50 +01:00
|
|
|
#include "common/translation.h"
|
2018-11-21 23:16:15 +01:00
|
|
|
|
|
|
|
#include "engines/advancedDetector.h"
|
2014-05-16 21:58:49 +02:00
|
|
|
|
2021-05-15 20:22:17 +08:00
|
|
|
static const DebugChannelDef debugFlagList[] = {
|
|
|
|
{BladeRunner::kDebugScript, "Script", "Debug the scripts"},
|
|
|
|
DEBUG_CHANNEL_END
|
|
|
|
};
|
|
|
|
|
2014-05-16 21:58:49 +02:00
|
|
|
namespace BladeRunner {
|
|
|
|
|
|
|
|
static const PlainGameDescriptor bladeRunnerGames[] = {
|
|
|
|
{"bladerunner", "Blade Runner"},
|
2019-05-18 20:13:21 +02:00
|
|
|
{"bladerunner-final", "Blade Runner with restored content"},
|
2022-06-25 00:38:53 +02:00
|
|
|
{"bladerunner-ee", "Blade Runner: Enhanced Edition"},
|
2021-11-13 23:40:17 +02:00
|
|
|
{nullptr, nullptr}
|
2014-05-16 21:58:49 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
} // End of namespace BladeRunner
|
|
|
|
|
2020-10-11 23:14:39 +02:00
|
|
|
class BladeRunnerMetaEngineDetection : public AdvancedMetaEngineDetection {
|
2014-05-16 21:58:49 +02:00
|
|
|
public:
|
2020-10-11 23:14:39 +02:00
|
|
|
BladeRunnerMetaEngineDetection();
|
2014-05-16 21:58:49 +02:00
|
|
|
|
2018-11-21 23:16:15 +01:00
|
|
|
const char *getName() const override;
|
2022-01-13 20:34:25 +00:00
|
|
|
const char *getEngineName() const override;
|
2018-11-21 23:16:15 +01:00
|
|
|
const char *getOriginalCopyright() const override;
|
2021-05-15 20:22:17 +08:00
|
|
|
const DebugChannelDef *getDebugChannels() const override;
|
2018-11-21 23:16:15 +01:00
|
|
|
};
|
2014-05-16 21:58:49 +02:00
|
|
|
|
2020-10-11 23:14:39 +02:00
|
|
|
BladeRunnerMetaEngineDetection::BladeRunnerMetaEngineDetection()
|
|
|
|
: AdvancedMetaEngineDetection(
|
2018-11-21 23:16:15 +01:00
|
|
|
BladeRunner::gameDescriptions,
|
|
|
|
sizeof(BladeRunner::gameDescriptions[0]),
|
2022-11-03 18:46:40 +00:00
|
|
|
BladeRunner::bladeRunnerGames) {
|
2022-05-11 23:42:43 +03:00
|
|
|
// Setting this, allows the demo files to be copied in the BladeRunner
|
|
|
|
// game data folder and be detected and subsequently launched without
|
|
|
|
// any issues (eg. like ScummVM launching Blade Runner instead of the demo).
|
|
|
|
// Although the demo files are not part of the original game's installation
|
|
|
|
// or CD content, it's nice to support the use case whereby the user
|
|
|
|
// manually copies the demo files in the Blade Runner game data folder
|
|
|
|
// and expects ScummVM to detect both, offer a choice on which to add,
|
|
|
|
// and finally launch the proper one depending on which was added.
|
|
|
|
_flags = kADFlagUseExtraAsHint;
|
|
|
|
}
|
2014-05-16 21:58:49 +02:00
|
|
|
|
2022-01-13 20:34:25 +00:00
|
|
|
const char *BladeRunnerMetaEngineDetection::getName() const {
|
2016-09-15 18:23:35 +02:00
|
|
|
return "bladerunner";
|
|
|
|
}
|
2018-11-21 23:16:15 +01:00
|
|
|
|
2022-01-13 20:34:25 +00:00
|
|
|
const char *BladeRunnerMetaEngineDetection::getEngineName() const {
|
2016-09-15 20:04:14 +02:00
|
|
|
return "Blade Runner";
|
2018-11-21 23:16:15 +01:00
|
|
|
}
|
|
|
|
|
2020-10-11 23:14:39 +02:00
|
|
|
const char *BladeRunnerMetaEngineDetection::getOriginalCopyright() const {
|
2018-11-21 23:16:15 +01:00
|
|
|
return "Blade Runner (C) 1997 Westwood Studios";
|
|
|
|
}
|
2014-05-16 21:58:49 +02:00
|
|
|
|
2021-05-15 20:22:17 +08:00
|
|
|
const DebugChannelDef *BladeRunnerMetaEngineDetection::getDebugChannels() const {
|
|
|
|
return debugFlagList;
|
|
|
|
}
|
|
|
|
|
2020-10-11 23:14:39 +02:00
|
|
|
REGISTER_PLUGIN_STATIC(BLADERUNNER_DETECTION, PLUGIN_TYPE_ENGINE_DETECTION, BladeRunnerMetaEngineDetection);
|