diff options
author | Paweł Kołodziejski | 2003-06-19 15:52:17 +0000 |
---|---|---|
committer | Paweł Kołodziejski | 2003-06-19 15:52:17 +0000 |
commit | 1cca50b7436d246217fc9a5b39e1f5b2204fe9dc (patch) | |
tree | 42c9ac8aa5d783f463f855172e2202f358854f5c /scumm | |
parent | 8b567ddaf884de9e850ce6f21a286e8c2e00e4b6 (diff) | |
download | scummvm-rg350-1cca50b7436d246217fc9a5b39e1f5b2204fe9dc.tar.gz scummvm-rg350-1cca50b7436d246217fc9a5b39e1f5b2204fe9dc.tar.bz2 scummvm-rg350-1cca50b7436d246217fc9a5b39e1f5b2204fe9dc.zip |
fixed costume header for v1
svn-id: r8558
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/costume.cpp | 32 |
1 files changed, 20 insertions, 12 deletions
diff --git a/scumm/costume.cpp b/scumm/costume.cpp index 86418be76d..7b2ed8a77f 100644 --- a/scumm/costume.cpp +++ b/scumm/costume.cpp @@ -509,19 +509,27 @@ byte CostumeRenderer::drawLimb(const CostumeData &cost, int limb) { const CostumeInfo *costumeInfo; int xmoveCur, ymoveCur; - // FIXME: those are here just in case... you never now... - assert(_srcptr[1] == 0); - assert(_srcptr[3] == 0); - - costumeInfo = (const CostumeInfo *)_srcptr; - _width = READ_LE_UINT16(&costumeInfo->width); - _height = READ_LE_UINT16(&costumeInfo->height); - xmoveCur = _xmove + (int16)READ_LE_UINT16(&costumeInfo->rel_x); - ymoveCur = _ymove + (int16)READ_LE_UINT16(&costumeInfo->rel_y); - _xmove += (int16)READ_LE_UINT16(&costumeInfo->move_x); - _ymove -= (int16)READ_LE_UINT16(&costumeInfo->move_y); - _srcptr += 12; + if (_vm->_version == 1) { + _width = _srcptr[0]; + _height = _srcptr[1]; + xmoveCur = _xmove + _srcptr[2]; + ymoveCur = _ymove + _srcptr[3]; + _xmove += _srcptr[4]; + _ymove -= _srcptr[5]; + } else { + // FIXME: those are here just in case... you never now... + assert(_srcptr[1] == 0); + assert(_srcptr[3] == 0); + costumeInfo = (const CostumeInfo *)_srcptr; + _width = READ_LE_UINT16(&costumeInfo->width); + _height = READ_LE_UINT16(&costumeInfo->height); + xmoveCur = _xmove + (int16)READ_LE_UINT16(&costumeInfo->rel_x); + ymoveCur = _ymove + (int16)READ_LE_UINT16(&costumeInfo->rel_y); + _xmove += (int16)READ_LE_UINT16(&costumeInfo->move_x); + _ymove -= (int16)READ_LE_UINT16(&costumeInfo->move_y); + _srcptr += 12; + } return mainRoutine(xmoveCur, ymoveCur); } } |