aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTravis Howell2009-03-20 11:34:40 +0000
committerTravis Howell2009-03-20 11:34:40 +0000
commit1365b22359eb610752ea571595a0ae808f2c8843 (patch)
treee3dd01bbff34df5ad26de3676d6345afefab3fc4
parenta4a8249a9ca76685a216a1c7ae6ddc127e8bee1c (diff)
downloadscummvm-rg350-1365b22359eb610752ea571595a0ae808f2c8843.tar.gz
scummvm-rg350-1365b22359eb610752ea571595a0ae808f2c8843.tar.bz2
scummvm-rg350-1365b22359eb610752ea571595a0ae808f2c8843.zip
Add missing code difference in getUserFlag().
svn-id: r39565
-rw-r--r--engines/agos/items.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/agos/items.cpp b/engines/agos/items.cpp
index 85ae92bee8..c439be3555 100644
--- a/engines/agos/items.cpp
+++ b/engines/agos/items.cpp
@@ -130,7 +130,8 @@ int AGOSEngine::getUserFlag(Item *item, int a) {
if (subUserFlag == NULL)
return 0;
- if (a < 0 || a > 7)
+ int max = (getGameType() == GType_ELVIRA1) ? 7 : 3;
+ if (a < 0 || a > max)
return 0;
return subUserFlag->userFlags[a];