[Scummvm-cvs-logs] SF.net SVN: scummvm: [31908] scummvm/trunk/engines/gob/draw_v2.cpp
drmccoy at users.sourceforge.net
drmccoy at users.sourceforge.net
Tue May 6 23:56:16 CEST 2008
Revision: 31908
http://scummvm.svn.sourceforge.net/scummvm/?rev=31908&view=rev
Author: drmccoy
Date: 2008-05-06 14:56:16 -0700 (Tue, 06 May 2008)
Log Message:
-----------
Fixed text positioning in Woodruff, enabling "Use FOO on BAR" texts.
Modified Paths:
--------------
scummvm/trunk/engines/gob/draw_v2.cpp
Modified: scummvm/trunk/engines/gob/draw_v2.cpp
===================================================================
--- scummvm/trunk/engines/gob/draw_v2.cpp 2008-05-06 20:55:33 UTC (rev 31907)
+++ scummvm/trunk/engines/gob/draw_v2.cpp 2008-05-06 21:56:16 UTC (rev 31908)
@@ -246,22 +246,25 @@
}
if (_renderFlags & RENDERFLAG_FROMSPLIT) {
- destY = _vm->_video->_splitStart;
+ destY = _vm->_video->_splitHeight1;
spriteBottom = READ_LE_UINT16(ptr + 6) - READ_LE_UINT16(ptr + 2);
+
if (_renderFlags & RENDERFLAG_DOUBLECOORDS)
spriteBottom *= 3;
- spriteBottom += _vm->_video->_splitStart;
+
+ spriteBottom += _vm->_video->_splitHeight1;
+
if (_renderFlags & RENDERFLAG_DOUBLECOORDS) {
- spriteBottom += _backDeltaX;
- destY += _backDeltaX;
+ spriteBottom += _backDeltaY;
+ destY += _backDeltaY;
}
} else {
+ destY = READ_LE_UINT16(ptr + 2);
+ spriteBottom = READ_LE_UINT16(ptr + 6);
+
if (_renderFlags & RENDERFLAG_DOUBLECOORDS) {
- destY = READ_LE_UINT16(ptr + 2) * 2;
- spriteBottom = READ_LE_UINT16(ptr + 6) * 2;
- } else {
- destY = READ_LE_UINT16(ptr + 2);
- spriteBottom = READ_LE_UINT16(ptr + 6);
+ destY *= 2;
+ spriteBottom *= 2;
}
}
@@ -629,8 +632,7 @@
_destSpriteX += _backDeltaX;
_destSpriteY += _backDeltaY;
if ((operation == DRAW_DRAWLINE) ||
- ((operation >= DRAW_DRAWBAR) &&
- (operation <= DRAW_FILLRECTABS))) {
+ ((operation >= DRAW_DRAWBAR) && (operation <= DRAW_FILLRECTABS))) {
_spriteRight += _backDeltaX;
_spriteBottom += _backDeltaY;
}
@@ -646,6 +648,20 @@
int16 destSurface = _destSurface;
int16 sourceSurface = _sourceSurface;
+ if ((_destSpriteY >= _vm->_video->_splitHeight1) &&
+ ((_destSurface == 20) || (_destSurface == 21))) {
+
+ _destSpriteY = (_destSpriteY - _vm->_video->_splitHeight1) + _vm->_video->_splitStart;
+ if ((operation == DRAW_DRAWLINE) ||
+ ((operation >= DRAW_DRAWBAR) && (operation <= DRAW_FILLRECTABS)))
+ _spriteBottom = (_spriteBottom - _vm->_video->_splitHeight1) + _vm->_video->_splitStart;
+
+ }
+
+ if ((_spriteTop >= _vm->_video->_splitHeight1) && (operation == DRAW_BLITSURF) &&
+ ((_destSurface == 20) || (_destSurface == 21)))
+ _spriteTop = (_spriteTop - _vm->_video->_splitHeight1) + _vm->_video->_splitStart;
+
adjustCoords(0, &_destSpriteX, &_destSpriteY);
if ((operation != DRAW_LOADSPRITE) && (_needAdjust != 2)) {
adjustCoords(0, &_spriteRight, &_spriteBottom);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list