2007-05-30 21:56:52 +00:00
|
|
|
/* ScummVM - Graphic Adventure Engine
|
|
|
|
*
|
|
|
|
* ScummVM is the legal property of its developers, whose names
|
|
|
|
* are too numerous to list here. Please refer to the COPYRIGHT
|
|
|
|
* file distributed with this source distribution.
|
2004-04-09 12:36:06 +00:00
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
2005-01-09 16:06:29 +00:00
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
2004-04-09 12:36:06 +00:00
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
2005-10-18 01:30:26 +00:00
|
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
2004-04-09 12:36:06 +00:00
|
|
|
*
|
2006-02-09 12:19:53 +00:00
|
|
|
* $URL$
|
|
|
|
* $Id$
|
2004-04-09 12:36:06 +00:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2008-05-11 23:16:50 +00:00
|
|
|
#ifndef KYRA_KYRA_V1_H
|
|
|
|
#define KYRA_KYRA_V1_H
|
2004-04-09 12:36:06 +00:00
|
|
|
|
2006-09-23 00:42:35 +00:00
|
|
|
#include "engines/engine.h"
|
2008-04-20 15:47:11 +00:00
|
|
|
|
2007-05-05 12:18:02 +00:00
|
|
|
#include "common/array.h"
|
2007-06-22 23:03:12 +00:00
|
|
|
#include "common/events.h"
|
2008-12-25 20:40:00 +00:00
|
|
|
#include "common/system.h"
|
2005-10-12 19:15:32 +00:00
|
|
|
|
2009-05-24 01:29:09 +00:00
|
|
|
#include "sound/mixer.h"
|
|
|
|
|
2008-04-20 15:47:11 +00:00
|
|
|
#include "kyra/script.h"
|
2005-08-19 22:12:09 +00:00
|
|
|
|
2008-03-17 18:10:52 +00:00
|
|
|
namespace Common {
|
2008-08-04 11:38:25 +00:00
|
|
|
class SeekableReadStream;
|
|
|
|
class WriteStream;
|
2009-10-04 21:26:33 +00:00
|
|
|
} // End of namespace Common
|
2008-03-17 18:10:52 +00:00
|
|
|
|
2008-03-27 18:03:00 +00:00
|
|
|
class KyraMetaEngine;
|
|
|
|
|
2009-11-24 22:10:14 +00:00
|
|
|
/**
|
|
|
|
* This is the namespace of the Kyra engine.
|
|
|
|
*
|
|
|
|
* Status of this engine: ???
|
|
|
|
*
|
|
|
|
* Supported games:
|
|
|
|
* - ???
|
|
|
|
*/
|
2007-07-29 16:33:11 +00:00
|
|
|
namespace Kyra {
|
2006-01-22 09:34:12 +00:00
|
|
|
|
2006-09-17 20:21:40 +00:00
|
|
|
struct GameFlags {
|
|
|
|
Common::Language lang;
|
2008-06-30 23:39:56 +00:00
|
|
|
|
|
|
|
// language overwrites of fan translations (only needed for multilingual games)
|
|
|
|
Common::Language fanLang;
|
|
|
|
Common::Language replacedLang;
|
|
|
|
|
2006-09-17 20:21:40 +00:00
|
|
|
Common::Platform platform;
|
2008-04-29 14:22:04 +00:00
|
|
|
|
2009-10-04 17:54:08 +00:00
|
|
|
bool isDemo : 1;
|
|
|
|
bool useAltShapeHeader : 1; // alternative shape header (uses 2 bytes more, those are unused though)
|
|
|
|
bool isTalkie : 1;
|
|
|
|
bool useHiResOverlay : 1;
|
|
|
|
bool use16ColorMode : 1;
|
|
|
|
bool useDigSound : 1;
|
|
|
|
bool useInstallerPackage : 1;
|
2008-04-29 14:22:04 +00:00
|
|
|
|
2006-09-17 20:21:40 +00:00
|
|
|
byte gameID;
|
2004-11-11 13:37:35 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
enum {
|
2006-05-01 00:25:41 +00:00
|
|
|
GI_KYRA1 = 0,
|
2006-05-12 23:57:53 +00:00
|
|
|
GI_KYRA2 = 1,
|
2008-07-31 10:47:15 +00:00
|
|
|
GI_KYRA3 = 2,
|
|
|
|
GI_LOL = 4
|
2004-10-15 06:06:47 +00:00
|
|
|
};
|
|
|
|
|
2008-01-03 14:42:49 +00:00
|
|
|
struct AudioDataStruct {
|
2009-04-25 13:15:05 +00:00
|
|
|
const char *const *fileList;
|
|
|
|
int fileListLen;
|
|
|
|
const void *cdaTracks;
|
|
|
|
int cdaNumTracks;
|
|
|
|
int extraOffset;
|
2008-01-03 14:42:49 +00:00
|
|
|
};
|
|
|
|
|
2006-02-14 01:19:30 +00:00
|
|
|
// TODO: this is just the start of makeing the debug output of the kyra engine a bit more useable
|
|
|
|
// in the future we maybe merge some flags and/or create new ones
|
2009-10-04 17:54:08 +00:00
|
|
|
enum DebugLevels {
|
|
|
|
kDebugLevelScriptFuncs = 1 << 0, ///< debug level for o#_* functions
|
|
|
|
kDebugLevelScript = 1 << 1, ///< debug level for "EMCInterpreter" functions
|
|
|
|
kDebugLevelSprites = 1 << 2, ///< debug level for "Sprites" functions
|
|
|
|
kDebugLevelScreen = 1 << 3, ///< debug level for "Screen" functions
|
|
|
|
kDebugLevelSound = 1 << 4, ///< debug level for "Sound" functions
|
|
|
|
kDebugLevelAnimator = 1 << 5, ///< debug level for "ScreenAnimator" functions
|
|
|
|
kDebugLevelMain = 1 << 6, ///< debug level for common "KyraEngine(_v#)" functions && "TextDisplayer" functions
|
|
|
|
kDebugLevelGUI = 1 << 7, ///< debug level for "KyraEngine*" gui functions
|
|
|
|
kDebugLevelSequence = 1 << 8, ///< debug level for "SeqPlayer" functions
|
|
|
|
kDebugLevelMovie = 1 << 9, ///< debug level for movie specific funtions
|
|
|
|
kDebugLevelTimer = 1 << 10 ///< debug level for "TimerManager" functions
|
2006-02-14 01:19:30 +00:00
|
|
|
};
|
|
|
|
|
2009-10-04 17:54:08 +00:00
|
|
|
enum MusicDataID {
|
2008-03-21 16:18:27 +00:00
|
|
|
kMusicIntro = 0,
|
|
|
|
kMusicIngame,
|
|
|
|
kMusicFinale
|
|
|
|
};
|
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
class Screen;
|
|
|
|
class Resource;
|
|
|
|
class Sound;
|
|
|
|
class Movie;
|
|
|
|
class TextDisplayer;
|
|
|
|
class StaticResource;
|
2007-07-29 16:33:11 +00:00
|
|
|
class TimerManager;
|
2008-05-06 20:50:27 +00:00
|
|
|
class Debugger;
|
2008-12-16 17:40:34 +00:00
|
|
|
class GUI;
|
|
|
|
|
|
|
|
struct Button;
|
2006-01-22 09:34:12 +00:00
|
|
|
|
2008-05-11 23:16:50 +00:00
|
|
|
class KyraEngine_v1 : public Engine {
|
2008-03-27 16:12:48 +00:00
|
|
|
friend class Debugger;
|
2008-03-27 18:03:00 +00:00
|
|
|
friend class ::KyraMetaEngine;
|
2008-04-04 06:24:49 +00:00
|
|
|
friend class GUI;
|
2009-10-04 17:54:08 +00:00
|
|
|
friend class SoundMidiPC; // For _eventMan
|
2004-10-15 06:06:47 +00:00
|
|
|
public:
|
2008-05-11 23:16:50 +00:00
|
|
|
KyraEngine_v1(OSystem *system, const GameFlags &flags);
|
|
|
|
virtual ~KyraEngine_v1();
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
uint8 game() const { return _flags.gameID; }
|
|
|
|
const GameFlags &gameFlags() const { return _flags; }
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
// access to Kyra specific functionallity
|
2005-08-19 22:12:09 +00:00
|
|
|
Resource *resource() { return _res; }
|
2007-07-29 16:31:29 +00:00
|
|
|
virtual Screen *screen() = 0;
|
2008-03-30 18:27:46 +00:00
|
|
|
virtual TextDisplayer *text() { return _text; }
|
2008-12-16 17:40:34 +00:00
|
|
|
virtual GUI *gui() const { return 0; }
|
2006-01-13 23:06:04 +00:00
|
|
|
Sound *sound() { return _sound; }
|
2006-03-18 14:43:18 +00:00
|
|
|
StaticResource *staticres() { return _staticres; }
|
2007-07-29 16:33:11 +00:00
|
|
|
TimerManager *timer() { return _timer; }
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2006-01-03 19:03:09 +00:00
|
|
|
uint32 tickLength() const { return _tickLength; }
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
Common::RandomSource _rnd;
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2008-04-12 23:17:21 +00:00
|
|
|
// input
|
2008-04-16 20:28:27 +00:00
|
|
|
void setMousePos(int x, int y);
|
2008-04-12 23:17:21 +00:00
|
|
|
Common::Point getMousePos() const;
|
|
|
|
|
2008-03-23 20:55:42 +00:00
|
|
|
// config specific
|
|
|
|
bool speechEnabled();
|
|
|
|
bool textEnabled();
|
|
|
|
|
2008-04-04 18:02:50 +00:00
|
|
|
enum kVolumeEntry {
|
|
|
|
kVolumeMusic = 0,
|
|
|
|
kVolumeSfx = 1,
|
|
|
|
kVolumeSpeech = 2
|
|
|
|
};
|
|
|
|
|
2009-06-21 19:00:50 +00:00
|
|
|
// volume reaches per default from 2 to 97
|
2008-04-04 18:02:50 +00:00
|
|
|
void setVolume(kVolumeEntry vol, uint8 value);
|
|
|
|
uint8 getVolume(kVolumeEntry vol);
|
|
|
|
|
2008-11-09 12:07:20 +00:00
|
|
|
virtual void syncSoundSettings();
|
|
|
|
|
2008-01-27 19:47:41 +00:00
|
|
|
// game flag handling
|
2007-01-31 23:48:12 +00:00
|
|
|
int setGameFlag(int flag);
|
2007-07-29 16:31:29 +00:00
|
|
|
int queryGameFlag(int flag) const;
|
2007-01-31 23:48:12 +00:00
|
|
|
int resetGameFlag(int flag);
|
2007-10-10 09:06:15 +00:00
|
|
|
|
|
|
|
// sound
|
2008-04-10 15:41:06 +00:00
|
|
|
virtual void snd_playTheme(int file, int track);
|
2008-04-29 14:08:08 +00:00
|
|
|
virtual void snd_playSoundEffect(int id, int volume=0xFF);
|
2007-10-10 09:06:15 +00:00
|
|
|
virtual void snd_playWanderScoreViaMap(int command, int restart);
|
2007-10-13 06:57:47 +00:00
|
|
|
virtual void snd_playVoiceFile(int id) = 0;
|
|
|
|
virtual bool snd_voiceIsPlaying();
|
|
|
|
virtual void snd_stopVoice();
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
// delay functionallity
|
|
|
|
virtual void delayUntil(uint32 timestamp, bool updateGameTimers = false, bool update = false, bool isMainLoop = false);
|
|
|
|
virtual void delay(uint32 millis, bool update = false, bool isMainLoop = false);
|
|
|
|
virtual void delayWithTicks(int ticks);
|
2006-03-08 13:15:13 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
protected:
|
2008-11-04 16:11:40 +00:00
|
|
|
// Engine APIs
|
2008-11-06 17:05:54 +00:00
|
|
|
virtual Common::Error init();
|
2009-03-01 04:30:55 +00:00
|
|
|
virtual Common::Error go() = 0;
|
2009-06-25 01:29:55 +00:00
|
|
|
|
2009-03-01 04:30:55 +00:00
|
|
|
virtual Common::Error run() {
|
|
|
|
Common::Error err;
|
2009-06-25 01:29:55 +00:00
|
|
|
registerDefaultSettings();
|
2009-03-01 04:30:55 +00:00
|
|
|
err = init();
|
|
|
|
if (err != Common::kNoError)
|
|
|
|
return err;
|
|
|
|
return go();
|
|
|
|
}
|
2009-06-25 01:29:55 +00:00
|
|
|
|
2008-11-04 16:11:40 +00:00
|
|
|
virtual ::GUI::Debugger *getDebugger();
|
|
|
|
virtual bool hasFeature(EngineFeature f) const;
|
|
|
|
virtual void pauseEngineIntern(bool pause);
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
// intern
|
2005-08-19 22:12:09 +00:00
|
|
|
Resource *_res;
|
2006-01-13 23:06:04 +00:00
|
|
|
Sound *_sound;
|
2006-01-02 22:58:59 +00:00
|
|
|
TextDisplayer *_text;
|
2006-03-18 14:43:18 +00:00
|
|
|
StaticResource *_staticres;
|
2007-07-29 16:33:11 +00:00
|
|
|
TimerManager *_timer;
|
2008-04-29 15:12:09 +00:00
|
|
|
EMCInterpreter *_emc;
|
2008-05-06 20:50:27 +00:00
|
|
|
Debugger *_debugger;
|
2008-01-27 15:30:53 +00:00
|
|
|
|
2008-12-16 17:40:34 +00:00
|
|
|
// input
|
2009-10-03 20:42:26 +00:00
|
|
|
void setupKeyMap();
|
2008-12-16 17:40:34 +00:00
|
|
|
void updateInput();
|
2009-05-24 14:33:41 +00:00
|
|
|
int checkInput(Button *buttonList, bool mainLoop = false, int eventFlag = 0x8000);
|
2008-12-16 17:40:34 +00:00
|
|
|
void removeInputTop();
|
|
|
|
|
|
|
|
int _mouseX, _mouseY;
|
|
|
|
|
|
|
|
struct Event {
|
|
|
|
Common::Event event;
|
|
|
|
bool causedSkip;
|
|
|
|
|
|
|
|
Event() : event(), causedSkip(false) {}
|
|
|
|
Event(Common::Event e) : event(e), causedSkip(false) {}
|
|
|
|
Event(Common::Event e, bool skip) : event(e), causedSkip(skip) {}
|
|
|
|
|
|
|
|
operator Common::Event() const { return event; }
|
|
|
|
};
|
|
|
|
Common::List<Event> _eventList;
|
2009-11-07 15:06:25 +00:00
|
|
|
typedef Common::HashMap<int, int16> KeyMap;
|
|
|
|
KeyMap _keyMap;
|
2008-12-16 17:40:34 +00:00
|
|
|
|
2008-01-27 15:30:53 +00:00
|
|
|
// config specific
|
|
|
|
virtual void registerDefaultSettings();
|
|
|
|
virtual void readSettings();
|
|
|
|
virtual void writeSettings();
|
|
|
|
|
|
|
|
uint8 _configWalkspeed;
|
|
|
|
|
|
|
|
int _configMusic;
|
|
|
|
bool _configSounds;
|
|
|
|
uint8 _configVoice;
|
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
// game speed
|
2008-12-16 17:40:34 +00:00
|
|
|
virtual bool skipFlag() const;
|
|
|
|
virtual void resetSkipFlag(bool removeEvent = true);
|
2008-03-16 14:32:49 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
uint16 _tickLength;
|
2007-07-29 16:33:11 +00:00
|
|
|
uint16 _gameSpeed;
|
2008-01-27 15:30:53 +00:00
|
|
|
|
2008-05-12 12:57:42 +00:00
|
|
|
// run
|
|
|
|
int8 _deathHandler;
|
|
|
|
|
2008-01-27 15:30:53 +00:00
|
|
|
// timer
|
2008-01-27 15:56:56 +00:00
|
|
|
virtual void setupTimers() = 0;
|
|
|
|
|
2008-01-27 15:30:53 +00:00
|
|
|
virtual void setWalkspeed(uint8 speed) = 0;
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
// detection
|
|
|
|
GameFlags _flags;
|
2007-01-29 18:15:14 +00:00
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
// opcode
|
|
|
|
virtual void setupOpcodeTable() = 0;
|
|
|
|
Common::Array<const Opcode*> _opcodes;
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2008-05-12 12:42:10 +00:00
|
|
|
int o1_queryGameFlag(EMCState *script);
|
|
|
|
int o1_setGameFlag(EMCState *script);
|
|
|
|
int o1_resetGameFlag(EMCState *script);
|
|
|
|
int o1_getRand(EMCState *script);
|
|
|
|
int o1_hideMouse(EMCState *script);
|
|
|
|
int o1_showMouse(EMCState *script);
|
|
|
|
int o1_setMousePos(EMCState *script);
|
|
|
|
int o1_setHandItem(EMCState *script);
|
|
|
|
int o1_removeHandItem(EMCState *script);
|
|
|
|
int o1_getMouseState(EMCState *script);
|
2008-05-12 12:57:42 +00:00
|
|
|
int o1_setDeathHandler(EMCState *script);
|
|
|
|
int o1_playWanderScoreViaMap(EMCState *script);
|
2008-05-18 13:22:06 +00:00
|
|
|
int o1_fillRect(EMCState *script);
|
2008-05-12 13:11:42 +00:00
|
|
|
int o1_blockInWalkableRegion(EMCState *script);
|
|
|
|
int o1_blockOutWalkableRegion(EMCState *script);
|
|
|
|
int o1_playSoundEffect(EMCState *script);
|
2008-05-12 12:42:10 +00:00
|
|
|
|
|
|
|
// items
|
|
|
|
int _mouseState;
|
|
|
|
|
|
|
|
virtual void setHandItem(uint16 item) = 0;
|
|
|
|
virtual void removeHandItem() = 0;
|
|
|
|
|
2007-07-29 16:31:29 +00:00
|
|
|
// game flags
|
2009-10-04 17:54:08 +00:00
|
|
|
uint8 _flagsTable[100]; // TODO: check this value
|
2007-10-10 09:06:15 +00:00
|
|
|
|
|
|
|
// sound
|
2009-05-24 01:29:09 +00:00
|
|
|
Audio::SoundHandle _speechHandle;
|
2008-03-21 16:18:27 +00:00
|
|
|
|
2007-10-10 09:06:15 +00:00
|
|
|
int _curMusicTheme;
|
|
|
|
int _curSfxFile;
|
|
|
|
int16 _lastMusicCommand;
|
|
|
|
|
|
|
|
const int8 *_trackMap;
|
|
|
|
int _trackMapSize;
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2009-06-21 20:10:45 +00:00
|
|
|
virtual int convertVolumeToMixer(int value);
|
|
|
|
virtual int convertVolumeFromMixer(int value);
|
2009-06-21 19:00:50 +00:00
|
|
|
|
2007-07-29 16:33:11 +00:00
|
|
|
// pathfinder
|
|
|
|
virtual int findWay(int x, int y, int toX, int toY, int *moveTable, int moveTableSize);
|
|
|
|
int findSubPath(int x, int y, int toX, int toY, int *moveTable, int start, int end);
|
|
|
|
int getFacingFromPointToPoint(int x, int y, int toX, int toY);
|
|
|
|
int getOppositeFacingDirection(int dir);
|
|
|
|
void changePosTowardsFacing(int &x, int &y, int facing);
|
|
|
|
int getMoveTableSize(int *moveTable);
|
|
|
|
virtual bool lineIsPassable(int x, int y) = 0;
|
2008-01-27 19:47:41 +00:00
|
|
|
|
2007-07-29 16:33:11 +00:00
|
|
|
static const int8 _addXPosTable[];
|
|
|
|
static const int8 _addYPosTable[];
|
2008-03-17 18:10:52 +00:00
|
|
|
|
2008-05-18 21:11:19 +00:00
|
|
|
// Character
|
2009-01-01 15:06:43 +00:00
|
|
|
|
2008-05-18 21:11:19 +00:00
|
|
|
static const int8 _charAddXPosTable[];
|
|
|
|
static const int8 _charAddYPosTable[];
|
|
|
|
|
2008-03-17 18:10:52 +00:00
|
|
|
// save/load
|
2008-03-28 00:53:54 +00:00
|
|
|
int _gameToLoad;
|
|
|
|
|
2008-09-14 19:48:40 +00:00
|
|
|
uint32 _lastAutosave;
|
|
|
|
void checkAutosave();
|
|
|
|
|
2008-11-03 19:51:34 +00:00
|
|
|
bool _isSaveAllowed;
|
|
|
|
|
|
|
|
bool canLoadGameStateCurrently() { return _isSaveAllowed; }
|
|
|
|
bool canSaveGameStateCurrently() { return _isSaveAllowed; }
|
|
|
|
|
2008-03-17 18:10:52 +00:00
|
|
|
const char *getSavegameFilename(int num);
|
2008-09-14 21:41:27 +00:00
|
|
|
static Common::String getSavegameFilename(const Common::String &target, int num);
|
2008-03-28 00:53:54 +00:00
|
|
|
bool saveFileLoadable(int slot);
|
2008-03-27 18:03:00 +00:00
|
|
|
|
|
|
|
struct SaveHeader {
|
|
|
|
Common::String description;
|
|
|
|
uint32 version;
|
|
|
|
byte gameID;
|
|
|
|
uint32 flags;
|
|
|
|
|
2009-10-04 17:54:08 +00:00
|
|
|
bool originalSave; // savegame from original interpreter
|
|
|
|
bool oldHeader; // old scummvm save header
|
2008-08-20 14:03:34 +00:00
|
|
|
|
|
|
|
Graphics::Surface *thumbnail;
|
2008-03-27 18:03:00 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
enum kReadSaveHeaderError {
|
|
|
|
kRSHENoError = 0,
|
|
|
|
kRSHEInvalidType = 1,
|
|
|
|
kRSHEInvalidVersion = 2,
|
|
|
|
kRSHEIoError = 3
|
|
|
|
};
|
2008-03-28 00:53:54 +00:00
|
|
|
|
2008-08-20 14:03:34 +00:00
|
|
|
static kReadSaveHeaderError readSaveHeader(Common::SeekableReadStream *file, bool loadThumbnail, SaveHeader &header);
|
2008-03-27 18:03:00 +00:00
|
|
|
|
2008-11-09 13:12:38 +00:00
|
|
|
void loadGameStateCheck(int slot);
|
2008-11-09 13:00:40 +00:00
|
|
|
virtual Common::Error loadGameState(int slot) = 0;
|
|
|
|
Common::Error saveGameState(int slot, const char *saveName) { return saveGameState(slot, saveName, 0); }
|
|
|
|
virtual Common::Error saveGameState(int slot, const char *saveName, const Graphics::Surface *thumbnail) = 0;
|
2008-09-14 19:48:40 +00:00
|
|
|
|
2008-08-04 11:38:25 +00:00
|
|
|
Common::SeekableReadStream *openSaveForReading(const char *filename, SaveHeader &header);
|
2008-08-20 14:03:34 +00:00
|
|
|
Common::WriteStream *openSaveForWriting(const char *filename, const char *saveName, const Graphics::Surface *thumbnail) const;
|
2009-10-04 17:38:15 +00:00
|
|
|
|
|
|
|
// TODO: Consider moving this to Screen
|
|
|
|
virtual Graphics::Surface *generateSaveThumbnail() const { return 0; }
|
2004-04-09 12:36:06 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
} // End of namespace Kyra
|
|
|
|
|
|
|
|
#endif
|
2007-04-15 16:41:20 +00:00
|
|
|
|