From 4ec7db55c227d3c38f2358fa74ff2649d6583391 Mon Sep 17 00:00:00 2001 From: Philipp Sehmisch Date: Mon, 23 Jun 2008 14:44:20 +0000 Subject: Implemented "alpha" particle property. --- src/particle.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/particle.h') diff --git a/src/particle.h b/src/particle.h index 045ab9b9..5ba2668b 100644 --- a/src/particle.h +++ b/src/particle.h @@ -183,6 +183,13 @@ class Particle : public Sprite setFadeIn(int fadeIn) { mFadeIn = fadeIn; } + /** + * Sets the alpha value of the particle + */ + void + setAlpha(float alpha) + { mAlpha = alpha; } + /** * Sets the sprite iterator of the particle on the current map to make * it easier to remove the particle from the map when it is destroyed. @@ -265,6 +272,7 @@ class Particle : public Sprite int mLifetimePast; /**< Age of the particle in game ticks*/ int mFadeOut; /**< Lifetime in game ticks left where fading out begins*/ int mFadeIn; /**< Age in game ticks where fading in is finished*/ + float mAlpha; /**< Opacity of the graphical representation of the particle */ private: // generic properties -- cgit v1.2.3-60-g2f50