mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-16 14:50:17 +00:00
SCI: fixing kBaseSetter on scaled views
adding check, if view is scaleable also just copying nsRect now instead of recalculating - fixes lb2 regression at the docks (calling taxi hangs the game, bug #3982289) - i noticed this difference before but copying nsRect didnt work back then (i guess because of other bugs), that's why i recalculated it should get backported, but only after some more testing - maybe someone should play through lb2 again svn-id: r53045
This commit is contained in:
parent
8e523d9d2f
commit
5ba3475f93
@ -237,20 +237,24 @@ void GfxCompare::kernelBaseSetter(reg_t object) {
|
||||
Common::Rect celRect;
|
||||
|
||||
GfxView *tmpView = _cache->getView(viewId);
|
||||
if (tmpView->isSci2Hires())
|
||||
_screen->adjustToUpscaledCoordinates(y, x);
|
||||
if (!tmpView->isScaleable())
|
||||
scaleSignal = 0;
|
||||
|
||||
if (scaleSignal & kScaleSignalDoScaling) {
|
||||
int16 scaleX = readSelectorValue(_segMan, object, SELECTOR(scaleX));
|
||||
int16 scaleY = readSelectorValue(_segMan, object, SELECTOR(scaleY));
|
||||
tmpView->getCelScaledRect(loopNo, celNo, x, y, z, scaleX, scaleY, celRect);
|
||||
celRect.left = readSelectorValue(_segMan, object, SELECTOR(nsLeft));
|
||||
celRect.right = readSelectorValue(_segMan, object, SELECTOR(nsRight));
|
||||
celRect.top = readSelectorValue(_segMan, object, SELECTOR(nsTop));
|
||||
celRect.bottom = readSelectorValue(_segMan, object, SELECTOR(nsBottom));
|
||||
} else {
|
||||
tmpView->getCelRect(loopNo, celNo, x, y, z, celRect);
|
||||
}
|
||||
if (tmpView->isSci2Hires())
|
||||
_screen->adjustToUpscaledCoordinates(y, x);
|
||||
|
||||
if (tmpView->isSci2Hires()) {
|
||||
_screen->adjustBackUpscaledCoordinates(celRect.top, celRect.left);
|
||||
_screen->adjustBackUpscaledCoordinates(celRect.bottom, celRect.right);
|
||||
tmpView->getCelRect(loopNo, celNo, x, y, z, celRect);
|
||||
|
||||
if (tmpView->isSci2Hires()) {
|
||||
_screen->adjustBackUpscaledCoordinates(celRect.top, celRect.left);
|
||||
_screen->adjustBackUpscaledCoordinates(celRect.bottom, celRect.right);
|
||||
}
|
||||
}
|
||||
|
||||
celRect.bottom = y + 1;
|
||||
|
Loading…
Reference in New Issue
Block a user