diff options
author | Jared Adams <jaxad0127@gmail.com> | 2009-10-15 07:22:29 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-10-15 07:22:29 -0600 |
commit | 59657fcbfa88a8f7a15bf4350f8addf399e20bda (patch) | |
tree | e5a9a856dc80bd55427380383a5953b75c874b4a /src/flooritem.cpp | |
parent | 2f55dd130c886376a45c9d0054dbd987cc055155 (diff) | |
download | mana-59657fcbfa88a8f7a15bf4350f8addf399e20bda.tar.gz mana-59657fcbfa88a8f7a15bf4350f8addf399e20bda.tar.bz2 mana-59657fcbfa88a8f7a15bf4350f8addf399e20bda.tar.xz mana-59657fcbfa88a8f7a15bf4350f8addf399e20bda.zip |
Make sure item icons in the invy are full opacity
Diffstat (limited to 'src/flooritem.cpp')
-rw-r--r-- | src/flooritem.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/flooritem.cpp b/src/flooritem.cpp index b2f6376b..9420afb4 100644 --- a/src/flooritem.cpp +++ b/src/flooritem.cpp @@ -67,11 +67,11 @@ void FloorItem::draw(Graphics *graphics, int offsetX, int offsetY) const { if (mItem) { - if (mAlpha != mItem->getImage()->getAlpha()) - mItem->getImage()->setAlpha(mAlpha); + Image *image = mItem->getDrawImage(); - graphics->drawImage(mItem->getImage(), - mX * 32 + offsetX, - mY * 32 + offsetY); + if (image && mAlpha != image->getAlpha()) + image->setAlpha(mAlpha); + + graphics->drawImage(image, mX * 32 + offsetX, mY * 32 + offsetY); } } |