diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-05-25 19:14:07 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-05-25 19:14:07 +0300 |
commit | bb8be1acea37f09c134d7d4042869a679cf8a12b (patch) | |
tree | 683667f9633605d9bdfd29a292063c81216e23a0 /src/particle | |
parent | e2f03241a1ba9d6b536b0b7a6f995e4e8d894408 (diff) | |
download | mv-bb8be1acea37f09c134d7d4042869a679cf8a12b.tar.gz mv-bb8be1acea37f09c134d7d4042869a679cf8a12b.tar.bz2 mv-bb8be1acea37f09c134d7d4042869a679cf8a12b.tar.xz mv-bb8be1acea37f09c134d7d4042869a679cf8a12b.zip |
Move sub images load function from resourcemanager into separate file.
Diffstat (limited to 'src/particle')
-rw-r--r-- | src/particle/particleemitter.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/particle/particleemitter.cpp b/src/particle/particleemitter.cpp index fa0f45fc7..eaebc16fd 100644 --- a/src/particle/particleemitter.cpp +++ b/src/particle/particleemitter.cpp @@ -35,6 +35,7 @@ #include "resources/dye/dye.h" #include "resources/loaders/imageloader.h" +#include "resources/loaders/subimageloader.h" #include "resources/resourcemanager/resourcemanager.h" @@ -136,7 +137,7 @@ ParticleEmitter::ParticleEmitter(const XmlNodePtrConst emitterNode, Image *img = ImageLoader::getImage(image); if (img) { - mParticleImage = resourceManager->getSubImage(img, + mParticleImage = Loader::getSubImage(img, XML::getProperty(propertyNode, "x", 0), XML::getProperty(propertyNode, "y", 0), XML::getProperty(propertyNode, "width", 0), @@ -377,7 +378,7 @@ ImageSet *ParticleEmitter::getImageSet(XmlNodePtrConst node) if (!img) return nullptr; - Image *const img2 = resourceManager->getSubImage(img, subX, + Image *const img2 = Loader::getSubImage(img, subX, XML::getProperty(node, "subY", 0), XML::getProperty(node, "subWidth", 0), XML::getProperty(node, "subHeight", 0)); |