diff options
author | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2010-11-01 20:04:43 +0100 |
---|---|---|
committer | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2010-11-01 20:04:43 +0100 |
commit | 38f7cd9a9a49dc91b1c2e69b48308bd16d4b5aad (patch) | |
tree | 81d0e898790264114683cca9cfd3355bea114415 /src/map.cpp | |
parent | c5e341f7b5f5e4efcabd09e00e177bb873db8097 (diff) | |
parent | 1f69108501c4bf51f3adac9ffbf7a7631fb12b9a (diff) | |
download | mana-client-38f7cd9a9a49dc91b1c2e69b48308bd16d4b5aad.tar.gz mana-client-38f7cd9a9a49dc91b1c2e69b48308bd16d4b5aad.tar.bz2 mana-client-38f7cd9a9a49dc91b1c2e69b48308bd16d4b5aad.tar.xz mana-client-38f7cd9a9a49dc91b1c2e69b48308bd16d4b5aad.zip |
Merge branch '0.5' of gitorious.org:mana/mana
Conflicts:
src/being.cpp
src/client.cpp
src/commandhandler.cpp
src/gui/setup_video.cpp
src/gui/socialwindow.cpp
src/gui/viewport.cpp
src/gui/widgets/browserbox.cpp
src/gui/widgets/itemcontainer.cpp
src/imageparticle.cpp
src/localplayer.cpp
src/localplayer.h
src/map.cpp
src/net/tmwa/beinghandler.cpp
src/particle.cpp
src/particle.h
src/player.cpp
src/player.h
Diffstat (limited to 'src/map.cpp')
-rw-r--r-- | src/map.cpp | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/src/map.cpp b/src/map.cpp index 367083b6..ea5cc976 100644 --- a/src/map.cpp +++ b/src/map.cpp @@ -390,22 +390,26 @@ void Map::draw(Graphics *graphics, int scrollX, int scrollY) } } - // Draws beings with a lower opacity to make them visible - // even when covered by a wall or some other elements... - Actors::const_iterator ai = mActors.begin(); - while (ai != mActors.end()) + // If the transparency hasn't been disabled, + if (Image::useOpenGL() || !Image::SDLisTransparencyDisabled()) { - if (Actor *actor = *ai) + // We draw beings with a lower opacity to make them visible + // even when covered by a wall or some other elements... + Actors::const_iterator ai = mActors.begin(); + while (ai != mActors.end()) { - // For now, just draw actors with only one layer. - if (actor->getNumberOfLayers() == 1) + if (Actor *actor = *ai) { - actor->setAlpha(0.3f); - actor->draw(graphics, -scrollX, -scrollY); - actor->setAlpha(1.0f); + // For now, just draw actors with only one layer. + if (actor->getNumberOfLayers() == 1) + { + actor->setAlpha(0.3f); + actor->draw(graphics, -scrollX, -scrollY); + actor->setAlpha(1.0f); + } } + ai++; } - ai++; } drawAmbientLayers(graphics, FOREGROUND_LAYERS, scrollX, scrollY, |