aboutsummaryrefslogtreecommitdiff
path: root/saga
diff options
context:
space:
mode:
authorAndrew Kurushin2005-03-25 17:48:17 +0000
committerAndrew Kurushin2005-03-25 17:48:17 +0000
commitca28c47c10ba2a70d94e4af5482d71c115a2be78 (patch)
treeed3264f9fb3bd6681945d6a710b9a0942890db13 /saga
parent0089900e5ac16b71b1e76554ed8366b3960810e2 (diff)
downloadscummvm-rg350-ca28c47c10ba2a70d94e4af5482d71c115a2be78.tar.gz
scummvm-rg350-ca28c47c10ba2a70d94e4af5482d71c115a2be78.tar.bz2
scummvm-rg350-ca28c47c10ba2a70d94e4af5482d71c115a2be78.zip
fix wrong multitile offset calculation
svn-id: r17230
Diffstat (limited to 'saga')
-rw-r--r--saga/isomap.cpp9
-rw-r--r--saga/script.h1
2 files changed, 6 insertions, 4 deletions
diff --git a/saga/isomap.cpp b/saga/isomap.cpp
index 439cce965d..5baedd3fbf 100644
--- a/saga/isomap.cpp
+++ b/saga/isomap.cpp
@@ -218,6 +218,7 @@ void IsoMap::loadMetaTiles(const byte * resourcePointer, size_t resourceLength)
void IsoMap::loadMulti(const byte * resourcePointer, size_t resourceLength) {
MultiTileEntryData *multiTileEntryData;
uint16 i;
+ int16 offsetDiff;
if (resourceLength < 2) {
error("IsoMap::loadMetaTiles wrong resourceLength");
@@ -243,8 +244,11 @@ void IsoMap::loadMulti(const byte * resourcePointer, size_t resourceLength) {
multiTileEntryData->currentState = readS.readByte();
readS.readByte();//skip
}
+
+ offsetDiff = (readS.pos() - 2);
+
for (i = 0; i < _multiCount; i++) {
- _multiTable[i].offset -= readS.pos();
+ _multiTable[i].offset -= offsetDiff;
}
_multiDataCount = (readS.size() - readS.pos()) / 2;
@@ -367,8 +371,7 @@ int16 IsoMap::findMulti(int16 tileIndex, int16 absU, int16 absV, int16 absH) {
return tileIndex;
}
}
-
- warning("something terrible happened");
+
return 1;
}
diff --git a/saga/script.h b/saga/script.h
index 90090e55b5..10be3ce886 100644
--- a/saga/script.h
+++ b/saga/script.h
@@ -61,7 +61,6 @@ enum AddressTypes {
};
enum VerbTypes {
-//todo: LUT for drawing
kVerbNone = 0,
kVerbPickUp = 1,
kVerbLookAt = 2,