summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/particle/particle.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/particle/particle.cpp b/src/particle/particle.cpp
index 94d5acd17..425be6c91 100644
--- a/src/particle/particle.cpp
+++ b/src/particle/particle.cpp
@@ -311,10 +311,8 @@ bool Particle::update() restrict2
for (ParticleIterator p = mChildMoveParticles.begin(),
fp2 = mChildMoveParticles.end(); p != fp2; )
{
- Particle *restrict const particle = *p;
// move particle with its parent if desired
- if (particle->mFollow)
- particle->moveBy(change);
+ (*p)->moveBy(change);
}
// Update child particles
@@ -349,9 +347,7 @@ void Particle::moveBy(const Vector &restrict change) restrict2
mPos += change;
FOR_EACH (ParticleConstIterator, p, mChildMoveParticles)
{
- Particle *restrict const particle = *p;
- if (particle->mFollow)
- particle->moveBy(change);
+ (*p)->moveBy(change);
}
}