summaryrefslogtreecommitdiff
path: root/src/particle/animationparticle.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/animationparticle.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/animationparticle.cpp')
-rw-r--r--src/particle/animationparticle.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/particle/animationparticle.cpp b/src/particle/animationparticle.cpp
index 43623aee9..006c7942f 100644
--- a/src/particle/animationparticle.cpp
+++ b/src/particle/animationparticle.cpp
@@ -24,28 +24,25 @@
#include "resources/animation/simpleanimation.h"
-#include "utils/delete2.h"
-
#include "debug.h"
AnimationParticle::AnimationParticle(Animation *restrict const animation) :
- ImageParticle(nullptr),
- mAnimation(new SimpleAnimation(animation))
+ ImageParticle(nullptr)
{
mType = ParticleType::Animation;
+ mAnimation = new SimpleAnimation(animation);
}
AnimationParticle::AnimationParticle(XmlNodePtrConst animationNode,
const std::string &restrict dyePalettes) :
- ImageParticle(nullptr),
- mAnimation(new SimpleAnimation(animationNode, dyePalettes))
+ ImageParticle(nullptr)
{
mType = ParticleType::Animation;
+ mAnimation = new SimpleAnimation(animationNode, dyePalettes);
}
AnimationParticle::~AnimationParticle()
{
- delete2(mAnimation);
mImage = nullptr;
}