ScummVM API documentation
debugger.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 TITANIC_DEBUGGER_H
23 #define TITANIC_DEBUGGER_H
24 
25 #include "gui/debugger.h"
26 #include "common/scummsys.h"
27 
28 namespace Titanic {
29 
30 #define DEBUG_BASIC 1
31 #define DEBUG_INTERMEDIATE 2
32 #define DEBUG_DETAILED 3
33 
34 class CNodeItem;
35 class CRoomItem;
36 class CViewItem;
37 class TitanicEngine;
38 
39 enum TitanicDebugChannels {
40  kDebugCore = 1 << 0,
41  kDebugScripts = 1 << 1,
42  kDebugGraphics = 1 << 2,
43  kDebugStarfield = 1 << 3
44 };
45 
46 class Debugger : public GUI::Debugger {
47 private:
51  int strToInt(const char *s);
52 
56  CRoomItem *findRoom(const char *name);
57 
61  CNodeItem *findNode(CRoomItem *room, const char *name);
62 
66  CViewItem *findView(CNodeItem *node, const char *name);
67 
71  void listRooms();
72 
76  void listRoom(CRoomItem *room);
77 
81  void listNode(CNodeItem *node);
82 
86  bool cmdDump(int argc, const char **argv);
87 
91  bool cmdRoom(int argc, const char **argv);
92 
96  bool cmdPET(int argc, const char **argv);
97 
101  bool cmdItem(int argc, const char **argv);
102 
106  bool cmdMovie(int argc, const char **argv);
107 
111  bool cmdSound(int argc, const char **argv);
112 
116  bool cmdCheat(int argc, const char **argv);
117 
121  bool cmdFrame(int argc, const char **argv);
122 protected:
123  TitanicEngine *_vm;
124 public:
125  Debugger(TitanicEngine *vm);
126  ~Debugger() override {}
127 };
128 
129 } // End of namespace Titanic
130 
131 #endif /* TITANIC_DEBUGGER_H */
Definition: debugger.h:41
Definition: debugger.h:46
Definition: room_item.h:33
Definition: node_item.h:29
Definition: titanic.h:81
Definition: arm.h:30
Definition: view_item.h:32