22 #ifndef NUVIE_CORE_GAME_H 23 #define NUVIE_CORE_GAME_H 25 #include "common/str.h" 26 #include "ultima/nuvie/core/nuvie_defs.h" 65 PAUSE_UNPAUSED = 0x00,
74 nuvie_game_t game_type;
118 GamePauseState pause_flags;
121 uint16 game_x_offset;
122 uint16 game_y_offset;
123 uint16 pause_user_count;
124 uint16 converse_gump_width;
125 uint16 min_converse_gump_width;
126 uint8 ignore_event_delay;
127 bool is_using_hackmove;
128 bool dragging_enabled;
130 bool unlimited_casting;
131 bool god_mode_enabled;
134 bool using_text_gumps;
135 bool open_containers;
136 ConverseGumpType converse_gump_type;
138 bool free_balloon_movement;
139 bool force_solid_converse_bg;
148 void init_game_style();
150 void update_once(
bool process_gui_input);
152 void update_once_display();
153 void update_until_converse_finished();
155 bool isLoaded()
const {
156 return script !=
nullptr;
158 GamePauseState get_pause_flags()
const {
161 void set_pause_flags(GamePauseState state);
164 void unpause_anims();
165 void unpause_world();
171 bool paused()
const {
174 bool all_paused()
const {
175 return (pause_flags & PAUSE_ALL);
177 bool user_paused()
const {
178 return (pause_flags & PAUSE_USER);
180 bool anims_paused()
const {
181 return (pause_flags & PAUSE_ANIMS);
183 bool world_paused()
const{
184 return (pause_flags & PAUSE_WORLD);
191 bool shouldQuit()
const;
193 bool set_mouse_pointer(uint8 ptr_num);
194 void dont_wait_for_interval();
195 void wait_for_interval();
197 void stats_changed();
199 void init_new_command_bar();
200 void delete_new_command_bar();
201 nuvie_game_t get_game_type()
const {
204 uint8 get_game_style()
const {
207 bool is_original_plus()
const {
208 return (game_style == NUVIE_STYLE_ORIG_PLUS_CUTOFF_MAP || game_style == NUVIE_STYLE_ORIG_PLUS_FULL_MAP);
210 bool is_original_plus_cutoff_map()
const {
211 return (game_style == NUVIE_STYLE_ORIG_PLUS_CUTOFF_MAP);
213 bool is_original_plus_full_map()
const {
214 return (game_style == NUVIE_STYLE_ORIG_PLUS_FULL_MAP);
216 bool is_new_style()
const {
217 return (game_style == NUVIE_STYLE_NEW);
219 bool is_orig_style()
const {
220 return (game_style == NUVIE_STYLE_ORIG);
222 bool doubleclick_opens_containers();
223 void set_doubleclick_opens_containers(
bool val) {
224 open_containers = val;
226 void set_using_text_gumps(
bool val) {
227 using_text_gumps = val;
229 bool is_using_text_gumps()
const {
230 return (using_text_gumps || is_new_style());
232 bool is_roof_mode()
const {
235 void set_roof_mode(
bool val) {
238 bool using_hackmove();
239 void set_hackmove(
bool hackmove);
240 uint8 is_dragging_enabled() {
241 return dragging_enabled;
243 void set_dragging_enabled(
bool drag) {
244 dragging_enabled = drag;
246 bool is_god_mode_enabled()
const {
247 return (god_mode_enabled && cheats_enabled);
249 bool toggle_god_mode() {
250 return (god_mode_enabled = !god_mode_enabled);
252 bool are_cheats_enabled()
const {
253 return cheats_enabled;
255 void set_cheats_enabled(
bool cheat) {
256 cheats_enabled = cheat;
258 bool has_unlimited_casting()
const {
259 return (unlimited_casting && cheats_enabled);
261 void set_unlimited_casting(
bool unlimited) {
262 unlimited_casting = unlimited;
264 bool is_armageddon()
const {
267 void set_armageddon(
bool val) {
270 bool is_ethereal()
const {
273 void set_ethereal(
bool val) {
276 ConverseGumpType get_converse_gump_type()
const {
277 return converse_gump_type;
279 void set_converse_gump_type(ConverseGumpType new_type);
280 bool using_new_converse_gump();
281 void set_free_balloon_movement(
bool val) {
282 free_balloon_movement = val;
284 bool has_free_balloon_movement()
const {
285 return free_balloon_movement;
287 bool is_forcing_solid_converse_bg()
const {
288 return force_solid_converse_bg;
290 uint16 get_converse_gump_width()
const {
291 return converse_gump_width;
293 uint16 get_min_converse_gump_width()
const {
294 return min_converse_gump_width;
296 uint16 get_game_width()
const {
299 uint16 get_game_height()
const {
302 uint16 get_game_x_offset()
const {
303 return game_x_offset;
305 uint16 get_game_y_offset()
const {
306 return game_y_offset;
311 static Game *get_game() {
342 return actor_manager;
350 Map *get_game_map() {
390 return sound_manager;
397 return effect_manager;
403 return new_command_bar;
416 void init_converse();
417 void init_converse_gump_settings();
420 void update_once(
bool process_gui_input,
bool run_converse);
423 extern uint getRandom(uint maxVal);
Definition: map_window.h:70
Definition: egg_manager.h:45
Definition: portrait.h:40
Definition: background.h:33
Definition: configuration.h:60
Definition: usecode.h:151
Definition: effect_manager.h:34
Definition: game_clock.h:45
Definition: font_manager.h:36
Definition: atari-screen.h:58
Definition: printman.h:30
Definition: tile_manager.h:145
Definition: actor_manager.h:42
Definition: converse_gump.h:38
Definition: detection.h:27
Definition: atari-cursor.h:35
Definition: sound_manager.h:62
Definition: obj_manager.h:74
Definition: game_palette.h:32
Definition: command_bar.h:49
Definition: view_manager.h:55
Definition: converse.h:78