AGOS: move debug channels to metaEngineDetection

This commit is contained in:
ysj1173886760 2021-05-15 19:30:02 +08:00 committed by Eugene Sandulenko
parent ff8d7f442a
commit 7dcf259006
2 changed files with 13 additions and 4 deletions

View File

@ -163,10 +163,6 @@ Common::Error AGOSEngine_Elvira1::init() {
AGOSEngine::AGOSEngine(OSystem *system, const AGOSGameDescription *gd)
: Engine(system), _rnd("agos"), _gameDescription(gd) {
DebugMan.addDebugChannel(kDebugOpcode, "opcode", "Opcode debug level");
DebugMan.addDebugChannel(kDebugVGAOpcode, "vga_opcode", "VGA Opcode debug level");
DebugMan.addDebugChannel(kDebugSubroutine, "subroutine", "Subroutine debug level");
DebugMan.addDebugChannel(kDebugVGAScript, "vga_script", "VGA Script debug level");
//Image dumping command disabled as it doesn't work well
#if 0
DebugMan.addDebugChannel(kDebugImageDump, "image_dump", "Enable dumping of images to files");

View File

@ -32,6 +32,7 @@
#include "agos/detection.h"
#include "agos/intern_detection.h"
#include "agos/obsolete.h" // Obsolete ID table.
#include "agos/agos.h"
/**
* Conversion table mapping old obsolete target names to the
@ -39,6 +40,14 @@
*
*/
static const DebugChannelDef debugFlagList[] = {
{AGOS::kDebugOpcode, "opcode", "Opcode debug level"},
{AGOS::kDebugVGAOpcode, "vga_opcode", "VGA Opcode debug level"},
{AGOS::kDebugSubroutine, "subroutine", "Subroutine debug level"},
{AGOS::kDebugVGAScript, "vga_script", "VGA Script debug level"},
DEBUG_CHANNEL_END
};
static const PlainGameDescriptor agosGames[] = {
{"pn", "Personal Nightmare"},
{"elvira1", "Elvira - Mistress of the Dark"},
@ -86,6 +95,10 @@ public:
const char *getOriginalCopyright() const override {
return "AGOS (C) Adventure Soft";
}
const DebugChannelDef *getDebugChannels() const override {
return debugFlagList;
}
};
REGISTER_PLUGIN_STATIC(AGOS_DETECTION, PLUGIN_TYPE_ENGINE_DETECTION, AgosMetaEngineDetection);