ScummVM API documentation
debug.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 SKY_DEBUG_H
23 #define SKY_DEBUG_H
24 
25 
26 #include "common/scummsys.h"
27 #include "gui/debugger.h"
28 
29 namespace Sky {
30 
31 class Logic;
32 class Mouse;
33 class Screen;
34 class SkyCompact;
35 
36 class Debugger : public GUI::Debugger {
37 public:
38  Debugger(Logic *logic, Mouse *mouse, Screen *screen, SkyCompact *skyCompact);
39  bool showGrid() { return _showGrid; }
40 
41 private:
42  void preEnter() override;
43  void postEnter() override;
44 
45 private:
46  bool Cmd_ShowGrid(int argc, const char **argv);
47  bool Cmd_ReloadGrid(int argc, const char **argv);
48  bool Cmd_ShowCompact(int argc, const char **argv);
49  bool Cmd_LogicCommand(int argc, const char **argv);
50  bool Cmd_Info(int argc, const char **argv);
51  bool Cmd_ScriptVar(int argc, const char **argv);
52  bool Cmd_Section(int argc, const char **argv);
53  bool Cmd_LogicList(int argc, const char **argv);
54 
55  void dumpCompact(uint16 cptId);
56 
57  Logic *_logic;
58  Mouse *_mouse;
59  Screen *_screen;
60  SkyCompact *_skyCompact;
61 
62  bool _showGrid;
63 };
64 
65 
66 class Debug {
67 public:
68  static void logic(uint32 logic);
69  static void script(uint32 command, uint16 *scriptData);
70  static void mcode(uint32 mcode, uint32 a, uint32 b, uint32 c);
71 };
72 
73 } // End of namespace Sky
74 
75 #endif
Definition: logic.h:133
Definition: debugger.h:41
Definition: default_display_client.h:78
Definition: debug.h:36
Definition: debug.h:66
Definition: screen.h:56
Definition: mouse.h:36
Definition: compact.h:58
Definition: autoroute.h:28