ScummVM API documentation
emi.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 EMI_ENGINE_H
23#define EMI_ENGINE_H
24
25#include "engines/grim/grim.h"
26#include "engines/grim/emi/layer.h"
27
28namespace Grim {
29
30class TextObject;
31class Actor;
32
33class EMIEngine : public GrimEngine {
34public:
35 EMIEngine(OSystem *syst, uint32 gameFlags, GrimGameType gameType, Common::Platform platform, Common::Language language);
36 virtual ~EMIEngine();
37
38 const char *getUpdateFilename() override;
39
40 void pushText();
41 void popText();
42 void purgeText();
43
45 void invalidateTextObjectsSortOrder() override;
46 void invalidateSortOrder();
47 void sortActiveActorsList();
48 void temporaryStoreSaveGameImage();
49 void storeSaveGameImage(SaveGame *state) override;
50
51private:
52 LuaBase *createLua() override;
53 void drawNormalMode() override;
54 void updateDrawMode() override;
55 static bool compareTextLayer(const TextObject *x, const TextObject *y);
56 void drawTextObjects() override;
57 static bool compareActor(const Actor *x, const Actor *y);
58 void sortTextObjects();
59 static bool compareLayer(const Layer *x, const Layer *y);
60 void sortLayers();
61
62 Common::List<TextObject *> _textObjects;
64
65 bool _textObjectsSortOrderInvalidated;
66 bool _sortOrderInvalidated;
67};
68
69extern EMIEngine *g_emi;
70
71} // end of namespace Grim
72
73#endif
Definition: list.h:44
Actor represents a 3D character on screen.
Definition: actor.h:72
Definition: emi.h:33
void invalidateActiveActorsList() override
Definition: grim.h:58
Definition: layer.h:33
Definition: lua.h:107
Definition: savegame.h:33
Definition: textobject.h:84
Definition: system.h:166
Language
Definition: language.h:45
Platform
Definition: platform.h:93