aboutsummaryrefslogtreecommitdiff
path: root/engines/avalanche
diff options
context:
space:
mode:
authoruruk2014-02-21 16:22:37 +0100
committeruruk2014-02-21 16:22:37 +0100
commitd23ced0aed643b2d6e3b6a70518f9412652dd817 (patch)
tree165b3bdd982524bd7117c3a692369e86dfd6ed82 /engines/avalanche
parent5580c0b95e11d4035626ddd6efef600385044f76 (diff)
downloadscummvm-rg350-d23ced0aed643b2d6e3b6a70518f9412652dd817.tar.gz
scummvm-rg350-d23ced0aed643b2d6e3b6a70518f9412652dd817.tar.bz2
scummvm-rg350-d23ced0aed643b2d6e3b6a70518f9412652dd817.zip
AVALANCHE: Repair ShootEmUp::plotThem().
Diffstat (limited to 'engines/avalanche')
-rw-r--r--engines/avalanche/graphics.cpp8
-rw-r--r--engines/avalanche/graphics.h2
-rw-r--r--engines/avalanche/shootemup.cpp2
3 files changed, 11 insertions, 1 deletions
diff --git a/engines/avalanche/graphics.cpp b/engines/avalanche/graphics.cpp
index 3b4413ab76..603e294fd8 100644
--- a/engines/avalanche/graphics.cpp
+++ b/engines/avalanche/graphics.cpp
@@ -779,6 +779,14 @@ void GraphicManager::seuDrawCameo(int destX, int destY, byte w1, byte w2) {
drawPicture(_surface, _seuPictures[w1], destX, destY);
}
+uint16 GraphicManager::seuGetPicWidth(int which) {
+ return _seuPictures[which].w;
+}
+
+uint16 GraphicManager::seuGetPicHeight(int which) {
+ return _seuPictures[which].h;
+}
+
/**
* This function is for skipping the difference between a stored 'size' value associated with a picture
* and the actual size of the pictures when reading them from files for Ghostroom and Shoot em' up.
diff --git a/engines/avalanche/graphics.h b/engines/avalanche/graphics.h
index 553f993188..86244e9b3c 100644
--- a/engines/avalanche/graphics.h
+++ b/engines/avalanche/graphics.h
@@ -116,6 +116,8 @@ public:
void seuFree();
void seuDrawPicture(int x, int y, byte which);
void seuDrawCameo(int destX, int destY, byte w1, byte w2);
+ uint16 seuGetPicWidth(int which);
+ uint16 seuGetPicHeight(int which);
void clearAlso();
void clearTextBar();
diff --git a/engines/avalanche/shootemup.cpp b/engines/avalanche/shootemup.cpp
index 783c1f9e20..1b48aa9433 100644
--- a/engines/avalanche/shootemup.cpp
+++ b/engines/avalanche/shootemup.cpp
@@ -195,7 +195,7 @@ void ShootEmUp::plotThem() {
_vm->_graphics->seuDrawPicture(_sprites[i]._x, _sprites[i]._y, _sprites[i]._p);
if (_sprites[i]._wipe)
- blank(Common::Rect(_sprites[i]._x, _sprites[i]._y, _sprites[i]._x + _rectangles[i].width(), _sprites[i]._y + _rectangles[i].height()));
+ blank(Common::Rect(_sprites[i]._x, _sprites[i]._y, _sprites[i]._x + _vm->_graphics->seuGetPicWidth(_sprites[i]._p), _sprites[i]._y + _vm->_graphics->seuGetPicHeight(_sprites[i]._p)));
if (_sprites[i]._timeout > 0) {
_sprites[i]._timeout--;