ScummVM API documentation
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
game_dragonsphere.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 #ifdef ENABLE_MADSV2
23 
24 #ifndef MADS_GAME_DRAGONSPHERE_H
25 #define MADS_GAME_DRAGONSPHERE_H
26 
27 #include "mads/game.h"
28 #include "mads/globals.h"
29 #include "mads/dragonsphere/globals_dragonsphere.h"
30 
31 namespace MADS {
32 
33 namespace Dragonsphere {
34 
35 // TODO: Adapt for Dragonsphere's difficulty setting
36 enum StoryMode { STORYMODE_NAUGHTY = 1, STORYMODE_NICE = 2 };
37 
38 enum InventoryObject {
39  OBJ_NONE = -1,
40  OBJ_SIGNET_RING = 0,
41  OBJ_BIRD_FIGURINE = 1,
42  OBJ_BIRDCALL = 2,
43  OBJ_SHIELDSTONE = 3,
44  OBJ_SWORD = 4,
45  OBJ_GOBLET = 5,
46  OBJ_BONE = 6,
47  OBJ_FRUIT = 7,
48  OBJ_DOLL = 8,
49  OBJ_POLYSTONE = 9,
50  OBJ_RED_STONE = 10,
51  OBJ_YELLOW_STONE = 11,
52  OBJ_BLUE_STONE = 12,
53  OBJ_KEY_CROWN = 13,
54  OBJ_DATES = 14,
55  OBJ_STATUE = 15,
56  OBJ_FLIES = 16,
57  OBJ_SOUL_EGG = 17,
58  OBJ_MAGIC_BELT = 18,
59  OBJ_AMULET = 19,
60  OBJ_MUD = 20,
61  OBJ_FEATHERS = 21,
62  OBJ_TORCH = 22,
63  OBJ_FLASK = 23,
64  OBJ_FLASK_OF_ACID = 24,
65  OBJ_ROPE = 25,
66  OBJ_VORTEX_STONE = 26,
67  OBJ_DEAD_RAT = 27,
68  OBJ_MAP = 28,
69  OBJ_CRYSTAL_BALL = 29,
70  OBJ_BLACK_SPHERE = 30,
71  OBJ_SOPORIFIC = 31,
72  OBJ_SHIFTER_RING = 32,
73  OBJ_SPIRIT_BUNDLE = 33,
74  OBJ_PARTIAL_BUNDLE = 34,
75  OBJ_RATSICLE = 35,
76  OBJ_TENTACLE_PARTS = 36,
77  OBJ_TELEPORT_DOOR = 37,
78  OBJ_RARE_COIN = 38,
79  OBJ_CRYSTAL_FLOWER = 39,
80  OBJ_DIAMOND_DUST = 40,
81  OBJ_RUBY_RING = 41,
82  OBJ_GOLD_NUGGET = 42,
83  OBJ_MAGIC_MUSIC_BOX = 43,
84  OBJ_EMERALD = 44,
85  OBJ_PARCHMENT = 45,
86  OBJ_GAME = 46,
87  OBJ_GAME2 = 47,
88  OBJ_NEW_BUNDLE = 48
89 };
90 
91 class GameDragonsphere : public Game {
92  friend class Game;
93 protected:
94  GameDragonsphere(MADSEngine *vm);
95 
96  void startGame() override;
97 
98  void initializeGlobals() override;
99 
100  void setSectionHandler() override;
101 
102  void checkShowDialog() override;
103 public:
104  DragonsphereGlobals _globals;
105  StoryMode _storyMode;
106 
107  Globals &globals() override { return _globals; }
108 
109  void doObjectAction() override;
110 
111  void unhandledAction() override;
112 
113  void step() override;
114 
115  void synchronize(Common::Serializer &s, bool phase1) override;
116 };
117 
118 
119 class Section1Handler : public SectionHandler {
120 public:
121  Section1Handler(MADSEngine *vm) : SectionHandler(vm) {}
122 
123  // TODO: Properly implement handler methods
124  void preLoadSection() override {}
125  void sectionPtr2() override {}
126  void postLoadSection() override {}
127 };
128 
129 // TODO: Properly implement handler classes
130 typedef Section1Handler Section2Handler;
131 typedef Section1Handler Section3Handler;
132 typedef Section1Handler Section4Handler;
133 typedef Section1Handler Section5Handler;
134 typedef Section1Handler Section6Handler;
135 typedef Section1Handler Section7Handler;
136 typedef Section1Handler Section8Handler;
137 
138 } // End of namespace Dragonsphere
139 
140 } // End of namespace MADS
141 
142 #endif /* MADS_GAME_DRAGONSPHERE_H */
143 
144 #endif
Definition: serializer.h:79
Definition: action.h:28