Correct subOp, used in freddicove

svn-id: r16877
This commit is contained in:
Travis Howell 2005-02-23 09:55:34 +00:00
parent 861e418e70
commit 2c10795b48
3 changed files with 20 additions and 7 deletions

View File

@ -900,6 +900,7 @@ protected:
int spriteInfoGet_field_78(int spriteId);
int spriteInfoGet_field_7C(int spriteId);
int spriteInfoGet_field_80(int spriteId);
int spriteInfoGet_field_88(int spriteId, int type);
void getSpriteImageDim(int spriteId, int32 &w, int32 &h);
void spriteInfoGet_tx_ty(int spriteId, int32 &tx, int32 &ty);
void spriteInfoGet_dx_dy(int spriteId, int32 &dx, int32 &dy);
@ -938,7 +939,7 @@ protected:
void spriteInfoSet_field_78_64(int spriteId, int value);
void spriteInfoSet_setClassFlags(int spriteId, int value1, int value2);
void spriteInfoSet_resetClassFlags(int spriteId);
void spriteInfoSet_field_88(int spriteId, int value1, int value2);
void spriteInfoSet_field_88(int spriteId, int type, int value);
void redrawSpriteGroup(int spriteGroupId);
void spriteGroupSet_case0_0(int spriteGroupId, int value1, int value2);

View File

@ -926,9 +926,12 @@ void ScummEngine_v90he::o90_getSpriteInfo() {
}
break;
case 109:
// dummy case
pop();
push(0);
spriteId = pop();
flags = pop();
if (spriteId)
push(spriteInfoGet_field_88(spriteId, flags));
else
push(0);
break;
case 110:
spriteId = pop();

View File

@ -199,6 +199,15 @@ int ScummEngine_v90he::spriteInfoGet_field_80(int spriteId) {
return _spriteTable[spriteId].field_80;
}
int ScummEngine_v90he::spriteInfoGet_field_88(int spriteId, int type) {
checkRange(_varNumSprites, 1, spriteId, "Invalid sprite %d");
if (type == 0x7B)
return _spriteTable[spriteId].field_88;
else
return 0;
}
void ScummEngine_v90he::getSpriteImageDim(int spriteId, int32 &w, int32 &h) {
checkRange(_varNumSprites, 1, spriteId, "Invalid sprite %d");
@ -525,11 +534,11 @@ void ScummEngine_v90he::spriteInfoSet_resetClassFlags(int spriteId) {
_spriteTable[spriteId].class_flags = 0;
}
void ScummEngine_v90he::spriteInfoSet_field_88(int spriteId, int value1, int value2) {
void ScummEngine_v90he::spriteInfoSet_field_88(int spriteId, int type, int value) {
checkRange(_varNumSprites, 1, spriteId, "Invalid sprite %d");
if (value1 == 0x7B) {
_spriteTable[spriteId].field_88 = value2;
if (type == 0x7B) {
_spriteTable[spriteId].field_88 = value;
_spriteTable[spriteId].flags |= kSF01 | kSFNeedRedraw;
}
}