aboutsummaryrefslogtreecommitdiff
path: root/engines/hdb/hdb.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/hdb/hdb.cpp')
-rw-r--r--engines/hdb/hdb.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/engines/hdb/hdb.cpp b/engines/hdb/hdb.cpp
index 11b3bc2634..649c4a9d3a 100644
--- a/engines/hdb/hdb.cpp
+++ b/engines/hdb/hdb.cpp
@@ -127,6 +127,26 @@ bool HDBGame::init() {
return true;
}
+void HDBGame::save(Common::OutSaveFile *out) {
+ out->write(_currentMapname, 64);
+ out->write(_lastMapname, 64);
+ out->write(_currentLuaName, 64);
+ out->writeSint32LE(_actionMode);
+ out->writeByte(_changeLevel);
+ out->write(_changeMapname, 64);
+ out->write(_inMapName, 32);
+}
+
+void HDBGame::load(Common::InSaveFile *in) {
+ in->read(_currentMapname, 64);
+ in->read(_lastMapname, 64);
+ in->read(_currentLuaName, 64);
+ _actionMode = in->readSint32LE();
+ _changeLevel = in->readByte();
+ in->read(_changeMapname, 64);
+ in->read(_inMapName, 32);
+}
+
/*
Changes the current GameState to the next one.
Game State Transitions are deterministic: each state can