ScummVM API documentation
detection.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef AGS_DETECTION_H
23 #define AGS_DETECTION_H
24 
25 #include "engines/advancedDetector.h"
26 
27 namespace AGS {
28 
29 enum AGSDebugChannels {
30  kDebugGraphics = 1 << 0,
31  kDebugPath = 1 << 1,
32  kDebugScan = 1 << 2,
33  kDebugFilePath = 1 << 3,
34  kDebugScript = 1 << 4
35 };
36 
37 enum GameFlag {
38  GAMEFLAG_PLUGINS_MASK = 0xff,
39  GAMEFLAG_PLUGINS_NONE = 0,
40  GAMEFLAG_PLUGINS_AGSTEAM_WADJETEYE = 1,
41  GAMEFLAG_PLUGINS_AGS_FLASHLIGHT = 2,
42  GAMEFLAG_PLUGINS_AGSSPRITEFONT_CLIFFTOP = 3,
43 
44  GAMEFLAG_FORCE_AA = 1 << 8,
45 };
46 
48  AD_GAME_DESCRIPTION_HELPERS(desc);
49 
50  ADGameDescription desc;
51 
52  uint32 features;
53 };
54 
55 extern const PlainGameDescriptor GAME_NAMES[];
56 
57 extern const AGSGameDescription GAME_DESCRIPTIONS[];
58 
59 #define GAMEOPTION_NO_SAVE_THUMBNAIL GUIO_GAMEOPTIONS1
60 #define GAMEOPTION_NO_AUTOSAVE GUIO_GAMEOPTIONS2
61 #define GAMEOPTION_NO_SAVELOAD GUIO_GAMEOPTIONS3
62 
63 } // namespace AGS
64 
65 
66 class AGSMetaEngineDetection : public AdvancedMetaEngineDetection<AGS::AGSGameDescription> {
67  mutable Common::String _gameid;
68  mutable Common::String _extra;
69  mutable Common::String _filenameStr;
70  mutable Common::String _md5;
71 
72  static const DebugChannelDef debugFlagList[];
73 
74 public:
76  ~AGSMetaEngineDetection() override {}
77 
78  const char *getName() const override {
79  return "ags";
80  }
81 
82  const char *getEngineName() const override {
83  return "Adventure Game Studio";
84  }
85 
86  const char *getOriginalCopyright() const override {
87  return "AGS Engine (C) Chris Jones";
88  }
89 
90  const DebugChannelDef *getDebugChannels() const override {
91  return debugFlagList;
92  }
93 
94  DetectedGames detectGames(const Common::FSList &fslist, uint32 skipADFlags, bool skipIncomplete) override;
95 
96  ADDetectedGame fallbackDetect(const FileMap &allFiles, const Common::FSList &fslist, ADDetectedGameExtraInfo **extra = nullptr) const override;
97 };
98 
99 #endif
Definition: advancedDetector.h:299
const DebugChannelDef * getDebugChannels() const override
Definition: detection.h:90
Definition: achievements_tables.h:27
Definition: str.h:59
const char * getName() const override
Definition: detection.h:78
const char * getOriginalCopyright() const override
Definition: detection.h:86
Definition: detection.h:47
Definition: advancedDetector.h:604
Definition: advancedDetector.h:163
Definition: game.h:49
Definition: detection.h:66
Definition: hashmap.h:85
Definition: debug-channels.h:36
Definition: fs.h:57
Definition: advancedDetector.h:307
const char * getEngineName() const override
Definition: detection.h:82