aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Schickel2006-03-16 17:37:34 +0000
committerJohannes Schickel2006-03-16 17:37:34 +0000
commitfa38b770afbe5b9bb7af732d2adadb8f37a203f4 (patch)
tree87b82d2991355772fb42574e96add59d5c1fb388
parentf040ea1e827bf40a862f2f960cc857ad1eff80cb (diff)
downloadscummvm-rg350-fa38b770afbe5b9bb7af732d2adadb8f37a203f4.tar.gz
scummvm-rg350-fa38b770afbe5b9bb7af732d2adadb8f37a203f4.tar.bz2
scummvm-rg350-fa38b770afbe5b9bb7af732d2adadb8f37a203f4.zip
Oops. removes some unneeded shifts and fixes now the feather bug.
svn-id: r21334
-rw-r--r--engines/kyra/animator.cpp15
1 files changed, 6 insertions, 9 deletions
diff --git a/engines/kyra/animator.cpp b/engines/kyra/animator.cpp
index 92b06a14a8..099ba9ef5c 100644
--- a/engines/kyra/animator.cpp
+++ b/engines/kyra/animator.cpp
@@ -178,10 +178,10 @@ void ScreenAnimator::preserveOrRestoreBackground(AnimObject *obj, bool restore)
int x = 0, y = 0, width = obj->width << 3, height = obj->height;
if (restore) {
- x = obj->x2 >> 3;
+ x = obj->x2;
y = obj->y2;
} else {
- x = obj->x1 >> 3;
+ x = obj->x1;
y = obj->y1;
}
@@ -202,9 +202,9 @@ void ScreenAnimator::preserveOrRestoreBackground(AnimObject *obj, bool restore)
}
if (restore) {
- _screen->copyBlockToPage(_screen->_curPage, x << 3, y, width, height, obj->background);
+ _screen->copyBlockToPage(_screen->_curPage, x, y, width, height, obj->background);
} else {
- _screen->copyRegionToBuffer(_screen->_curPage, x << 3, y, width, height, obj->background);
+ _screen->copyRegionToBuffer(_screen->_curPage, x, y, width, height, obj->background);
}
}
@@ -373,14 +373,11 @@ void ScreenAnimator::copyChangedObjectsForward(int refreshFlag) {
if (curObject->active) {
if (curObject->refreshFlag || refreshFlag) {
int xpos = 0, ypos = 0, width = 0, height = 0;
- xpos = (curObject->x1>>3) - (curObject->width2>>3) - 1;
+ xpos = curObject->x1 - curObject->width2 - 8;
ypos = curObject->y1 - curObject->height2;
- width = curObject->width + (curObject->width2>>3) + 2;
+ width = (curObject->width<<3) + curObject->width2 + 16;
height = curObject->height + curObject->height2*2;
- xpos <<= 3;
- width <<= 3;
-
if (xpos < 8) {
xpos = 8;
} else if (xpos + width > 312) {