diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-07-28 21:24:08 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-07-28 21:24:08 +0300 |
commit | d0fe17c1b5ac0ee20fba8bdb50db1696291415f0 (patch) | |
tree | e064666be590177b0f46cff7931f7715286e8e71 /src | |
parent | 769e7987eb1ef269b0973923f335f3838f592a8c (diff) | |
download | manaplus-d0fe17c1b5ac0ee20fba8bdb50db1696291415f0.tar.gz manaplus-d0fe17c1b5ac0ee20fba8bdb50db1696291415f0.tar.bz2 manaplus-d0fe17c1b5ac0ee20fba8bdb50db1696291415f0.tar.xz manaplus-d0fe17c1b5ac0ee20fba8bdb50db1696291415f0.zip |
move bools in particle.
Diffstat (limited to 'src')
-rw-r--r-- | src/particle.cpp | 14 | ||||
-rw-r--r-- | src/particle.h | 41 |
2 files changed, 26 insertions, 29 deletions
diff --git a/src/particle.cpp b/src/particle.cpp index b93fe376d..dcd9422a1 100644 --- a/src/particle.cpp +++ b/src/particle.cpp @@ -66,20 +66,20 @@ Particle::Particle(Map *const map) : mFadeIn(0), mVelocity(), mAlive(ALIVE), - mAutoDelete(true), mChildEmitters(), mChildParticles(), - mAllowSizeAdjust(false), mDeathEffect(), - mDeathEffectConditions(0x00), mGravity(0.0f), - mRandomness(0), mBounce(0.0f), - mFollow(false), - mTarget(nullptr), mAcceleration(0.0f), mInvDieDistance(-1.0f), - mMomentum(1.0f) + mMomentum(1.0f), + mTarget(nullptr), + mRandomness(0), + mDeathEffectConditions(0x00), + mAutoDelete(true), + mAllowSizeAdjust(false), + mFollow(false) { setMap(map); Particle::particleCount++; diff --git a/src/particle.h b/src/particle.h index 05d22454e..61e231d20 100644 --- a/src/particle.h +++ b/src/particle.h @@ -315,44 +315,22 @@ class Particle : public Actor // Is the particle supposed to be drawn and updated? AliveStatus mAlive; private: - // generic properties - // May the particle request its deletion by the parent particle? - bool mAutoDelete; - // List of child emitters. Emitters mChildEmitters; // List of particles controlled by this particle Particles mChildParticles; - // Can the effect size be adjusted by the object props in the map file? - bool mAllowSizeAdjust; - // Particle effect file to be spawned when the particle dies std::string mDeathEffect; - // Bitfield of death conditions which trigger spawning - // of the death particle - signed char mDeathEffectConditions; - // dynamic particle // Downward acceleration in pixels per game-tick. float mGravity; - // Ammount of random vector change - int mRandomness; - // How much the particle bounces off when hitting the ground float mBounce; - // is this particle moved when its parent particle moves? - bool mFollow; - - // follow-point particles - - // The particle that attracts this particle - Particle *mTarget; - // Acceleration towards the target particle in pixels per game-tick float mAcceleration; @@ -362,6 +340,25 @@ class Particle : public Actor // How much speed the particle retains after each game tick float mMomentum; + + // The particle that attracts this particle + Particle *mTarget; + + // Ammount of random vector change + int mRandomness; + + // Bitfield of death conditions which trigger spawning + // of the death particle + signed char mDeathEffectConditions; + + // May the particle request its deletion by the parent particle? + bool mAutoDelete; + + // Can the effect size be adjusted by the object props in the map file? + bool mAllowSizeAdjust; + + // is this particle moved when its parent particle moves? + bool mFollow; }; extern Particle *particleEngine; |