SCI: Fix negative window origin alignment.

SSCI does a shr 1; shl 1 here in SetOrigin.
This fixes a crash in the ending scene of SQ3 (#3194199).
This commit is contained in:
Willem Jan Palenstijn 2011-02-27 18:17:22 +01:00
parent 332abb91f3
commit d17a889400

View File

@ -311,7 +311,7 @@ Window *GfxPorts::addWindow(const Common::Rect &dims, const Common::Rect *restor
// bit of the left dimension in their interpreter. It seems Sierra did it
// for EGA byte alignment (EGA uses 1 byte for 2 pixels) and left it in
// their interpreter even in the newer VGA games.
r.left = r.left & 0x7FFE;
r.left = r.left & 0xFFFE;
if (r.width() > _screen->getWidth()) {
// We get invalid dimensions at least at the end of sq3 (script bug!).