Skip to content

Commit

Permalink
DIRECTOR: Fix sprite draw rects issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Dmitry Iskrich authored and sev- committed Aug 3, 2016
1 parent 511c0d9 commit d90a860
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions engines/director/score.cpp
Expand Up @@ -940,14 +940,6 @@ void Frame::renderSprites(Archive &_movie, Graphics::ManagedSurface &surface, Co
int y = _sprites[i]->_startPoint.y - regY + rectTop;
int height = _sprites[i]->_height;
int width = _sprites[i]->_width;
if (x < 0) {
width += x;
x = 0;
}
if (y < 0) {
height += y;
y = 0;
}
Common::Rect drawRect = Common::Rect(x, y, x + width, y + height);
_drawRects.push_back(drawRect);

Expand All @@ -971,7 +963,7 @@ void Frame::renderSprites(Archive &_movie, Graphics::ManagedSurface &surface, Co
}

void Frame::drawBackgndTransSprite(Graphics::ManagedSurface &target, const Graphics::Surface &sprite, Common::Rect &drawRect) {
uint8 skipColor = *(byte *)target.getBasePtr(0, 0); //FIXME is it always white (last entry in pallette) ?
uint8 skipColor = 15; //FIXME is it always white (last entry in pallette) ?
for (int ii = 0; ii < sprite.h; ii++) {
const byte *src = (const byte *)sprite.getBasePtr(0, ii);
byte *dst = (byte *)target.getBasePtr(drawRect.left, drawRect.top + ii);
Expand Down

0 comments on commit d90a860

Please sign in to comment.