aboutsummaryrefslogtreecommitdiff
path: root/engines/gob
diff options
context:
space:
mode:
authorSven Hesse2009-07-05 11:27:26 +0000
committerSven Hesse2009-07-05 11:27:26 +0000
commit835dea71ceba85fb5c0fcdba7162cb9d92f77874 (patch)
tree96a96fcde6e4d0dc18cc83d56839bbaf0a02a7be /engines/gob
parente861fab808897b8ec10a03930d94a079f1c7f1bb (diff)
downloadscummvm-rg350-835dea71ceba85fb5c0fcdba7162cb9d92f77874.tar.gz
scummvm-rg350-835dea71ceba85fb5c0fcdba7162cb9d92f77874.tar.bz2
scummvm-rg350-835dea71ceba85fb5c0fcdba7162cb9d92f77874.zip
Added a skipBlock() method
svn-id: r42122
Diffstat (limited to 'engines/gob')
-rw-r--r--engines/gob/script.cpp4
-rw-r--r--engines/gob/script.h1
2 files changed, 5 insertions, 0 deletions
diff --git a/engines/gob/script.cpp b/engines/gob/script.cpp
index 6162e943bf..38b1f8fa40 100644
--- a/engines/gob/script.cpp
+++ b/engines/gob/script.cpp
@@ -127,6 +127,10 @@ bool Script::skip(int32 offset) {
return seek(offset, SEEK_CUR);
}
+bool Script::skipBlock() {
+ return seek(peekUint16(2) + 2, SEEK_CUR);
+}
+
int32 Script::getOffset(byte *ptr) const {
if (!_totData)
return -1;
diff --git a/engines/gob/script.h b/engines/gob/script.h
index 64a04503b1..84daeaf1af 100644
--- a/engines/gob/script.h
+++ b/engines/gob/script.h
@@ -53,6 +53,7 @@ public:
// Stream seeking
bool seek(int32 offset, int whence = SEEK_SET);
bool skip(int32 offset);
+ bool skipBlock();
// Reading data
byte readByte ();