diff options
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/object.cpp | 6 | ||||
-rw-r--r-- | scumm/script_v90he.cpp | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/scumm/object.cpp b/scumm/object.cpp index c44e9a112a..631e10a3d6 100644 --- a/scumm/object.cpp +++ b/scumm/object.cpp @@ -178,7 +178,11 @@ int ScummEngine::getObjectImageCount(int object) { ptr = getOBIMFromObject(_objs[objnum]); imhd = (const ImageHeader *)findResourceData(MKID('IMHD'), ptr); - return (READ_LE_UINT32(&imhd->v8.image_count)); + + if (_version == 8) + return (READ_LE_UINT32(&imhd->v8.image_count)); + else + return (READ_LE_UINT16(&imhd->old.image_count)); } int ScummEngine::whereIsObject(int object) const { diff --git a/scumm/script_v90he.cpp b/scumm/script_v90he.cpp index d5bb7f7ef9..48d3e8211b 100644 --- a/scumm/script_v90he.cpp +++ b/scumm/script_v90he.cpp @@ -1921,7 +1921,7 @@ void ScummEngine_v90he::o90_getObjectData() { push(_objs[_heObjectNum].height); break; case 4: - push(0); + push(getObjectImageCount(_heObject)); break; case 6: if (_heObjectNum == -1) |