diff options
author | Denis Kasak | 2009-07-08 06:14:17 +0000 |
---|---|---|
committer | Denis Kasak | 2009-07-08 06:14:17 +0000 |
commit | 6b2991f488c4634f5663eb0734e543d311b82f84 (patch) | |
tree | 59d0ce4038b45c247bbd647724f81ec6abbd897a /engines/draci/script.cpp | |
parent | 0ec737db69cd838a9522aea7cdebe6d5bd9a1b60 (diff) | |
download | scummvm-rg350-6b2991f488c4634f5663eb0734e543d311b82f84.tar.gz scummvm-rg350-6b2991f488c4634f5663eb0734e543d311b82f84.tar.bz2 scummvm-rg350-6b2991f488c4634f5663eb0734e543d311b82f84.zip |
Made Script::run() seek in SEEK_CUR mode when jumping instead of the default SEEK_SET. It also now checks whether there is a non-zero jump value set before doing the jump.
svn-id: r42254
Diffstat (limited to 'engines/draci/script.cpp')
-rw-r--r-- | engines/draci/script.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/draci/script.cpp b/engines/draci/script.cpp index c676ef9d46..c63c9faea6 100644 --- a/engines/draci/script.cpp +++ b/engines/draci/script.cpp @@ -450,7 +450,8 @@ int Script::run(GPL2Program program, uint16 offset) { reader.pos(), _jump, reader.pos() + _jump); // Account for GPL jump that some commands set - reader.seek(reader.pos() + _jump); + if (_jump != 0) + reader.seek(_jump, SEEK_CUR); // Reset jump _jump = 0; |