ScummVM API documentation
game.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 ULTIMA_ULTIMA1_GAME_H
23#define ULTIMA_ULTIMA1_GAME_H
24
25#include "ultima/shared/early/game.h"
26#include "ultima/shared/gfx/visual_container.h"
27#include "ultima/ultima1/core/quests.h"
28
29namespace Ultima {
30namespace Ultima1 {
31
32enum VideoMode {
33 VIDEOMODE_EGA = 0, VIDEOMODE_VGA = 1
34};
35
36enum CharacterClass {
37 CLASS_FIGHTER = 0, CLASS_CLERIC = 1, CLASS_WIZARD = 2, CLASS_THIEF = 3
38};
39
40class GameResources;
41
42class Ultima1Game : public Shared::Game {
43 DECLARE_MESSAGE_MAP;
44public:
45 GameResources *_res;
46 Shared::Gfx::VisualItem *_gameView;
47 Shared::Gfx::VisualItem *_titleView;
48 Shared::Gfx::VisualItem *_charGenView;
49 uint _gems[4];
50 Quests _quests;
51public:
52 CLASSDEF;
54 ~Ultima1Game() override;
55
60
64 bool isVGA() const override { return _videoMode == VIDEOMODE_VGA; }
65
69 void starting(bool isLoading) override;
70
74 bool canSaveGameStateCurrently(Common::U32String *msg = nullptr) override;
75
79 void giveTreasure(int coins, int v2);
80};
81
82} // End of namespace Ultima1
83} // End of namespace Ultima
84
85#endif
Definition: serializer.h:80
Definition: ustr.h:57
Definition: game.h:42
Definition: visual_item.h:39
Definition: resources.h:32
Definition: quests.h:87
Definition: game.h:42
bool canSaveGameStateCurrently(Common::U32String *msg=nullptr) override
bool isVGA() const override
Definition: game.h:64
void giveTreasure(int coins, int v2)
void starting(bool isLoading) override
void synchronize(Common::Serializer &s) override