ScummVM API documentation
qd_empty_minigame_interface.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 QDENGINE_MINIGAMES_QD_EMPTY_INTERFACE_H
23#define QDENGINE_MINIGAMES_QD_EMPTY_INTERFACE_H
24
25#include "common/debug.h"
26
27#include "qdengine/qd_fwd.h"
28#include "qdengine/qdcore/qd_minigame_interface.h"
29
30namespace QDEngine {
31
32
34public:
35 typedef qdEmptyMiniGameInterface *(*interface_open_proc)(const char *game_name);
36 typedef bool (*interface_close_proc)(qdEmptyMiniGameInterface *p);
37
39
40 bool init(const qdEngineInterface *engine_interface) {
41 debugC(1, kDebugMinigames, "qdEmptyMinigameInterface: This is a placeholder class");
42 return true;
43 }
44
45 bool quant(float dt) {
46 debugC(3, kDebugMinigames, "qdEmptyMiniGameInterface::quant()");
47 return true;
48 }
49
50 bool finit() {
51 debugC(1, kDebugMinigames, "qdEmptyMiniGameInterface::finit()");
52 return true;
53 }
54
55 bool new_game(const qdEngineInterface *engine_interface) {
56 debugC(1, kDebugMinigames, "qdEmptyMiniGameInterface::new_game()");
57 return true;
58 }
59
60 int save_game(const qdEngineInterface *engine_interface, const qdMinigameSceneInterface *scene_interface, char *buffer, int buffer_size) {
61 debugC(1, kDebugMinigames, "qdEmptyMiniGameInterface::save_game()");
62 return 0;
63 }
64
65 int load_game(const qdEngineInterface *engine_interface, const qdMinigameSceneInterface *scene_interface, const char *buffer, int buffer_size) {
66 debugC(1, kDebugMinigames, "qdEmptyMiniGameInterface::load_game()");
67 return 0;
68 }
69
70 enum { INTERFACE_VERSION = 112 };
71 int version() const {
72 return INTERFACE_VERSION;
73 }
74};
75
76} // namespace QDEngine
77
78#endif // QDENGINE_MINIGAMES_QD_EMPTY_INTERFACE_H
Definition: qd_empty_minigame_interface.h:33
bool finit()
Деинициализация игры.
Definition: qd_empty_minigame_interface.h:50
bool new_game(const qdEngineInterface *engine_interface)
Инициализация миниигры, вызывается при старте и перезапуске игры.
Definition: qd_empty_minigame_interface.h:55
bool quant(float dt)
Обсчёт логики игры, параметр - время, которое должно пройти в игре (в секундах).
Definition: qd_empty_minigame_interface.h:45
int load_game(const qdEngineInterface *engine_interface, const qdMinigameSceneInterface *scene_interface, const char *buffer, int buffer_size)
Загрузка данных, вызывается при загрузке сцены, на которую повешена миниигра.
Definition: qd_empty_minigame_interface.h:65
int save_game(const qdEngineInterface *engine_interface, const qdMinigameSceneInterface *scene_interface, char *buffer, int buffer_size)
Сохранение данных, вызывается при сохранении сцены, на которую повешена миниигра.
Definition: qd_empty_minigame_interface.h:60
bool init(const qdEngineInterface *engine_interface)
Инициализация игры.
Definition: qd_empty_minigame_interface.h:40
Definition: qd_minigame_interface.h:365
Definition: qd_minigame_interface.h:78
Интерфейс к сцене.
Definition: qd_minigame_interface.h:315
void void void void void debugC(int level, uint32 debugChannel, MSVC_PRINTF const char *s,...) GCC_PRINTF(3
Базовый класс для игровых ресурсов.
Definition: console.h:28