ScummVM API documentation
alg.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 ALG_H
23 #define ALG_H
24 
25 #include "engines/advancedDetector.h"
26 #include "gui/debugger.h"
27 
28 #include "alg/detection.h"
29 
30 namespace Alg {
31 
32 class Game;
33 class GameBountyHunter;
34 class GameCrimePatrol;
35 class GameDrugWars;
36 class GameJohnnyRock;
37 class GameMaddog;
38 class GameMaddog2;
39 class GameSpacePirates;
40 
41 enum {
42  kAlgDebugGeneral = 1,
43  kAlgDebugGraphics
44 };
45 
46 class AlgEngine : public Engine {
47 public:
48  AlgEngine(OSystem *syst, const AlgGameDescription *desc);
49  ~AlgEngine();
50  Common::Error run() override;
51  bool hasFeature(EngineFeature f) const override;
52  Common::Platform getPlatform() const;
53  bool isDemo() const;
54  bool useSingleSpeedVideos() const { return _useSingleSpeedVideos; };
55  Common::Error loadGameState(int slot) override;
56  bool canLoadGameStateCurrently(Common::U32String *msg = nullptr) override;
57  Common::Error saveGameState(int slot, const Common::String &desc, bool isAutosave = false) override;
58  bool canSaveGameStateCurrently(Common::U32String *msg = nullptr) override;
59 
60 private:
61  const AlgGameDescription *_gameDescription;
62  Game *_game = nullptr;
63  GUI::Debugger *_debugger = nullptr;
64  bool _useSingleSpeedVideos = false;
65 };
66 
67 } // End of namespace Alg
68 
69 #endif
Definition: str.h:59
EngineFeature
Definition: engine.h:258
Definition: error.h:81
bool canSaveGameStateCurrently(Common::U32String *msg=nullptr) override
Definition: debugger.h:41
bool hasFeature(EngineFeature f) const override
Common::Error saveGameState(int slot, const Common::String &desc, bool isAutosave=false) override
Definition: ustr.h:57
Definition: alg.h:30
Common::Error loadGameState(int slot) override
Definition: game.h:36
Definition: system.h:164
Definition: alg.h:46
Common::Error run() override
Definition: engine.h:144
bool canLoadGameStateCurrently(Common::U32String *msg=nullptr) override
Platform
Definition: platform.h:93
Definition: detection.h:39