ScummVM API documentation
game_page.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 PINK_GAME_PAGE_H
23#define PINK_GAME_PAGE_H
24
25#include "common/memstream.h"
26
27#include "pink/objects/pages/page.h"
28
29namespace Pink {
30
31class CursorMgr;
32class HandlerSequences;
33
34class GamePage : public Page {
35public:
36 GamePage();
37 ~GamePage() override;
38 void toConsole() const override;
39 void deserialize(Archive &archive) override;
40
41 void loadState(Archive &archive);
42 void saveState(Archive &archive);
43
44 void load(Archive &archive) override;
45 void unload();
46 void loadManagers();
47 void init(bool isLoadingSave);
48
49 Sequencer *getSequencer() override { return _sequencer; }
50 WalkMgr *getWalkMgr() override { return _walkMgr; }
51 Module *getModule() override { return _module; }
52 const Module *getModule() const override { return _module; }
53
54 bool checkValueOfVariable(const Common::String &variable, const Common::String &value) const override;
55 void setVariable(Common::String &variable, Common::String &value) override;
56
57 void clear() override;
58
59 friend class Console;
60
61private:
62 bool initHandler();
63
64 void loadStateFromMem();
65 void saveStateToMem();
66
67 bool _isLoaded;
69 Module *_module;
70 CursorMgr *_cursorMgr;
71 WalkMgr *_walkMgr;
72 Sequencer *_sequencer;
74 StringMap _variables;
75};
76
77}
78
79#endif
Definition: memstream.h:283
Definition: str.h:59
Definition: archive.h:39
Definition: utils.h:30
Definition: console.h:31
Definition: cursor_mgr.h:35
Definition: game_page.h:34
Definition: module.h:43
Definition: page.h:36
Definition: sequencer.h:36
Definition: utils.h:52
Definition: walk_mgr.h:42