aboutsummaryrefslogtreecommitdiff
path: root/scumm
diff options
context:
space:
mode:
authorMax Horn2003-06-20 11:14:18 +0000
committerMax Horn2003-06-20 11:14:18 +0000
commitfc8e12444a74381fd3c67e49f266a689196691f5 (patch)
tree13867d6452d609948038d0347f08bb8f584ccc23 /scumm
parentcafe61b76852d1b5e4869d7698c47da9f0dde8e3 (diff)
downloadscummvm-rg350-fc8e12444a74381fd3c67e49f266a689196691f5.tar.gz
scummvm-rg350-fc8e12444a74381fd3c67e49f266a689196691f5.tar.bz2
scummvm-rg350-fc8e12444a74381fd3c67e49f266a689196691f5.zip
seems monkeyega & monkeyvga have byte values for the object name offset, too
svn-id: r8571
Diffstat (limited to 'scumm')
-rw-r--r--scumm/object.cpp7
-rw-r--r--scumm/script_v5.cpp7
2 files changed, 4 insertions, 10 deletions
diff --git a/scumm/object.cpp b/scumm/object.cpp
index cb23185a69..f8f4c8fa39 100644
--- a/scumm/object.cpp
+++ b/scumm/object.cpp
@@ -926,17 +926,14 @@ const byte *Scumm::getObjOrActorName(int obj) {
return NULL;
if (_features & GF_SMALL_HEADER) {
- int offset = 0;
+ byte offset = 0;
if (_version <= 2)
offset = *(objptr + 14);
else if (_features & GF_OLD_BUNDLE)
offset = *(objptr + 16);
- else if (_version == 3)
- offset = *(objptr + 18);
else
- // FIXME: is this really correct?
- offset = READ_LE_UINT16(objptr + 18);
+ offset = *(objptr + 18);
return (objptr + offset);
}
diff --git a/scumm/script_v5.cpp b/scumm/script_v5.cpp
index 3407ab890b..bfb803d223 100644
--- a/scumm/script_v5.cpp
+++ b/scumm/script_v5.cpp
@@ -1917,15 +1917,12 @@ void Scumm_v5::o5_setObjectName() {
}
if (_features & GF_SMALL_HEADER) {
- int offset = 0;
+ byte offset = 0;
if (_features & GF_OLD_BUNDLE)
offset = *(objptr + 16);
- else if (_version == 3)
- offset = *(objptr + 18);
else
- // FIXME: is this really correct?
- offset = READ_LE_UINT16(objptr + 18);
+ offset = *(objptr + 18);
size = READ_LE_UINT16(objptr) - offset;
name = objptr + offset;