summaryrefslogtreecommitdiff
path: root/src/particle/particle.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-03-16 21:12:23 +0300
committerAndrei Karas <akaras@inbox.ru>2016-03-16 21:12:23 +0300
commitb08de2d689c845c740fd25294bf93adf226fdb97 (patch)
tree3cc6b33808e3e707dfd2830f39e1767eff4f6f6f /src/particle/particle.cpp
parent558ef7174653df9d435e818bf16130443b0dd5be (diff)
downloadmv-b08de2d689c845c740fd25294bf93adf226fdb97.tar.gz
mv-b08de2d689c845c740fd25294bf93adf226fdb97.tar.bz2
mv-b08de2d689c845c740fd25294bf93adf226fdb97.tar.xz
mv-b08de2d689c845c740fd25294bf93adf226fdb97.zip
Move animation field from child particles classes into Particle.
Diffstat (limited to 'src/particle/particle.cpp')
-rw-r--r--src/particle/particle.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/particle/particle.cpp b/src/particle/particle.cpp
index 48edee676..0805aed8c 100644
--- a/src/particle/particle.cpp
+++ b/src/particle/particle.cpp
@@ -34,8 +34,11 @@
#include "resources/resourcemanager.h"
+#include "resources/animation/simpleanimation.h"
+
#include "resources/dye/dye.h"
+#include "utils/delete2.h"
#include "utils/dtor.h"
#include "utils/mathutils.h"
@@ -56,6 +59,7 @@ Particle::Particle() :
mVelocity(),
mAlive(AliveStatus::ALIVE),
mType(ParticleType::Normal),
+ mAnimation(nullptr),
mChildEmitters(),
mChildParticles(),
mDeathEffect(),
@@ -78,6 +82,7 @@ Particle::~Particle()
{
// Delete child emitters and child particles
clear();
+ delete2(mAnimation);
ParticleEngine::particleCount--;
}