30 #ifndef MACVENTURE_MACVENTURE_H 31 #define MACVENTURE_MACVENTURE_H 33 #include "engines/engine.h" 34 #include "common/scummsys.h" 35 #include "common/system.h" 36 #include "common/debug.h" 37 #include "common/random.h" 39 #include "common/compression/huffman.h" 40 #include "common/savefile.h" 42 #include "gui/debugger.h" 44 #include "macventure/debug.h" 45 #include "macventure/gui.h" 46 #include "macventure/world.h" 47 #include "macventure/hufflists.h" 48 #include "macventure/stringtable.h" 49 #include "macventure/script.h" 50 #include "macventure/controls.h" 51 #include "macventure/windows.h" 52 #include "macventure/sound.h" 58 class SaveFileManager;
74 kGlobalSettingsID = 0x80,
75 kDiplomaGeometryID = 0x81,
76 kTextHuffmanTableID = 0x83,
77 kDialogBoxTextID = 0x84,
78 kDialogBoxDiplomaID = 0x87
82 kSaveGameStrID = 0x82,
83 kDiplomaFilenameID = 0x83,
84 kClickToContinueTextID = 0x84,
85 kStartGameFilenameID = 0x85
99 const uint kMaxConsoleTextLength = 200000;
114 uint16 _numAttributes;
145 kSetToPlayerParent = 12,
146 kHightlightExits = 13,
179 kSoundPlayAndWait = 2,
195 void append(
Item item) {
196 _items.push_back(item);
197 _width += 8 + item.bounds.
width();
200 Item remove(uint index) {
201 Item out = _items.remove_at(index);
202 _width -= 8 + out.bounds.
width();
206 Item at(uint index) {
207 return _items[index];
210 inline uint size()
const {
return _items.size(); }
211 inline int width()
const {
return _width; }
230 bool scummVMSaveLoadDialog(
bool isSave);
236 void setInitialFlags(GameState gameState = kGameStateInit);
237 void setNewGameState();
240 void resetInternals();
242 void refreshScreen();
245 void loadDataBundle();
249 void requestUnpause();
250 void selectControl(ControlAction action);
252 void preparedToRun();
256 void clickToContinue();
258 void updateState(
bool pause);
261 void enqueueObject(ObjectQueueID type, ObjID objID, ObjID target = 0);
262 void enqueueText(TextQueueID type, ObjID target, ObjID source, ObjID text);
263 void enqueueSound(SoundQueueID type, ObjID target);
267 void playSounds(
bool pause);
270 void cleanUp(WindowReference reference);
271 void messUp(WindowReference reference);
275 void selectObject(ObjID objID);
276 void handleObjectSelect(ObjID objID, WindowReference win,
bool shiftPressed,
bool isDoubleClick);
277 void handleObjectDrop(ObjID objID,
Common::Point delta, ObjID newParent);
279 void focusObjectWindow(ObjID objID);
280 void updateWindow(WindowReference winID);
282 bool showTextEntry(ObjID text, ObjID srcObj, ObjID destObj);
290 bool needsClickToContinue();
294 bool isOldText()
const;
296 uint32 randBetween(uint32 min, uint32 max);
297 uint32 getInvolvedObjects();
299 uint getPrefixNdx(ObjID obj);
302 ScriptEngine *getScriptEngine()
const {
return _scriptEngine; }
304 GameState getGameState()
const {
return _gameState; }
311 bool isObjVisible(ObjID objID);
312 bool isObjClickable(ObjID objID);
313 bool isObjSelected(ObjID objID);
314 bool isObjExit(ObjID objID);
315 bool isHiddenExit(ObjID objID);
317 ObjID getParent(ObjID objID);
320 ControlAction referenceToAction(ControlType
id);
324 uint getOverlapPercent(ObjID one, ObjID other);
326 WindowReference getObjWindow(ObjID objID);
327 WindowReference findParentWindow(ObjID objID);
330 ObjID getDestObject();
331 ControlAction getSelectedControl();
334 void processEvents();
336 bool runScriptEngine();
338 void updateControls();
341 void unselectObject(ObjID objID);
342 void highlightExit(ObjID objID);
343 void selectPrimaryObject(ObjID objID);
347 void openObject(ObjID objID);
348 void closeObject(ObjID objID);
350 void reflectSwap(ObjID fromID, ObjID toID);
352 void zoomObject(ObjID objID);
354 bool isObjEnqueued(ObjID obj);
356 bool isGameRunning();
359 bool loadGlobalSettings();
360 bool loadTextHuffman();
362 const char *getGameFileName()
const;
389 GameState _gameState;
392 bool _oldTextEncoding;
393 bool _paused, _halted, _cmdReady, _prepared;
394 bool _haltedAtEnd, _haltedInSelection;
396 bool _clickToContinue;
406 ControlAction _selectedControl;
Definition: macresman.h:126
Definition: macventure.h:416
EngineFeature
Definition: engine.h:260
Definition: macventure.h:183
Definition: advancedDetector.h:164
Definition: debugger.h:41
Definition: macventure.h:101
Definition: macventure.h:150
T width() const
Definition: rect.h:217
Definition: macventure.h:193
Definition: archive.h:141
Definition: hufflists.h:36
Definition: macventure.h:218
Definition: macventure.h:188
Definition: container.h:38
Definition: stringtable.h:48
Definition: macventure.h:170