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 TWP_DETECTION_H
23 #define TWP_DETECTION_H
24 
25 #include "engines/advancedDetector.h"
26 
27 namespace Twp {
28 
29 enum TwpDebugChannels {
30  kDebugText = 1,
31  kDebugGGPack,
32  kDebugRes,
33  kDebugDialog,
34  kDebugGenScript,
35  kDebugObjScript,
36  kDebugSysScript,
37  kDebugRoomScript,
38  kDebugActScript,
39  kDebugSndScript,
40  kDebugGame,
41  kDebugConsole,
42  kDebugSave
43 };
44 
45 enum GameXorKey {
46  GAME_XORKEY_56AD,
47  GAME_XORKEY_566D,
48  GAME_XORKEY_5B6D,
49  GAME_XORKEY_5BAD,
50 };
51 
52 enum LanguageSupported {
53  LS_WITH_RUSSIAN,
54  LS_WITHOUT_RUSSIAN
55 };
56 
57 extern const PlainGameDescriptor twpGames[];
59  AD_GAME_DESCRIPTION_HELPERS(desc);
60 
61  ADGameDescription desc;
62  GameXorKey xorKey;
63  LanguageSupported languageSupported;
64 };
65 
66 extern const TwpGameDescription gameDescriptions[];
67 
68 } // End of namespace Twp
69 
70 class TwpMetaEngineDetection : public AdvancedMetaEngineDetection<Twp::TwpGameDescription> {
71  static const DebugChannelDef debugFlagList[];
72 
73 public:
75  ~TwpMetaEngineDetection() override = default;
76 
77  const char *getName() const override {
78  return "twp";
79  }
80 
81  const char *getEngineName() const override {
82  return "Thimbleweed Park";
83  }
84 
85  const char *getOriginalCopyright() const override {
86  return "Thimbleweed Park (C) Terrible Toybox";
87  }
88 
89  const DebugChannelDef *getDebugChannels() const override {
90  return debugFlagList;
91  }
92 
94  DetectedGame toDetectedGame(const ADDetectedGame &adGame, ADDetectedGameExtraInfo *extraInfo) const override;
95 };
96 
97 #endif // TWP_DETECTION_H
Definition: advancedDetector.h:299
const char * getEngineName() const override
Definition: detection.h:81
Definition: game.h:147
Definition: advancedDetector.h:604
Definition: advancedDetector.h:163
const DebugChannelDef * getDebugChannels() const override
Definition: detection.h:89
Definition: game.h:49
Definition: debug-channels.h:36
Definition: detection.h:70
const char * getOriginalCopyright() const override
Definition: detection.h:85
Definition: advancedDetector.h:307
Definition: detection.h:58
const char * getName() const override
Definition: detection.h:77
Definition: achievements_tables.h:27