summaryrefslogtreecommitdiff
path: root/src/textparticle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/textparticle.cpp')
-rw-r--r--src/textparticle.cpp10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/textparticle.cpp b/src/textparticle.cpp
index e8d99dca..0753cc38 100644
--- a/src/textparticle.cpp
+++ b/src/textparticle.cpp
@@ -44,16 +44,8 @@ bool TextParticle::draw(Graphics *graphics, int offsetX, int offsetY) const
int screenX = (int) mPos.x + offsetX;
int screenY = (int) mPos.y - (int) mPos.z + offsetY;
- float alpha = mAlpha * 255.0f;
-
- if (mLifetimeLeft > -1 && mLifetimeLeft < mFadeOut)
- alpha = alpha * mLifetimeLeft / mFadeOut;
-
- if (mLifetimePast < mFadeIn)
- alpha = alpha * mLifetimePast / mFadeIn;
-
gcn::Color color = *mColor;
- color.a = (int)alpha;
+ color.a = getCurrentAlpha() * 255;
TextRenderer::renderText(graphics, mText,
screenX, screenY, gcn::Graphics::CENTER,