diff options
author | Travis Howell | 2006-04-20 10:45:51 +0000 |
---|---|---|
committer | Travis Howell | 2006-04-20 10:45:51 +0000 |
commit | c07f314b1f99390c27ee2f1d99e4b77fda8cd89b (patch) | |
tree | 85ee2cc3cb786218eee92dbb3fc31ebeba5daea9 /engines/simon/items.cpp | |
parent | 948301faaf5ec5d7b1863539531af90b57fa55d7 (diff) | |
download | scummvm-rg350-c07f314b1f99390c27ee2f1d99e4b77fda8cd89b.tar.gz scummvm-rg350-c07f314b1f99390c27ee2f1d99e4b77fda8cd89b.tar.bz2 scummvm-rg350-c07f314b1f99390c27ee2f1d99e4b77fda8cd89b.zip |
getPathPosn script opcode needs to use int16 to get correct position, fixes entering teleporter in village in FF
svn-id: r22055
Diffstat (limited to 'engines/simon/items.cpp')
-rw-r--r-- | engines/simon/items.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/simon/items.cpp b/engines/simon/items.cpp index 2a612b059b..a76f367ada 100644 --- a/engines/simon/items.cpp +++ b/engines/simon/items.cpp @@ -1457,8 +1457,8 @@ void SimonEngine::o_getPathPosn() { if (!p) continue; for (j = 0; readUint16Wrapper(&p[0]) != end; j++, p += 2) { - x_diff = abs((int)(readUint16Wrapper(&p[0]) - x)); - y_diff = abs((int)(readUint16Wrapper(&p[1]) - 12 - y)); + x_diff = abs((int16)(readUint16Wrapper(&p[0]) - x)); + y_diff = abs((int16)(readUint16Wrapper(&p[1]) - 12 - y)); if (x_diff < y_diff) { x_diff /= 4; |