mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-27 20:28:27 +00:00
Correct classId.
svn-id: r16896
This commit is contained in:
parent
4f01f5e6e9
commit
40771358a6
@ -55,14 +55,17 @@ int ScummEngine_v90he::spriteInfoGet_classFlags(int spriteId, int classId) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int ScummEngine_v90he::spriteInfoGet_classFlagsAnd(int spriteId, int num, int *args) {
|
int ScummEngine_v90he::spriteInfoGet_classFlagsAnd(int spriteId, int num, int *args) {
|
||||||
|
int classId;
|
||||||
|
|
||||||
checkRange(_varNumSprites, 1, spriteId, "Invalid sprite %d");
|
checkRange(_varNumSprites, 1, spriteId, "Invalid sprite %d");
|
||||||
|
|
||||||
if (!num)
|
if (!num)
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
for (int i = 0; i < num; i++) {
|
for (int i = 0; i < num; i++) {
|
||||||
checkRange(32, 1, args[i], "class %d out of range in statement");
|
classId = args[i] & 0x7F;
|
||||||
if (!(_spriteTable[spriteId].class_flags & (1 << args[i])))
|
checkRange(32, 1, classId, "class %d out of range in statement");
|
||||||
|
if (!(_spriteTable[spriteId].class_flags & (1 << classId)))
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user