summaryrefslogtreecommitdiff
path: root/src/resources/mapreader.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/resources/mapreader.cpp')
-rw-r--r--src/resources/mapreader.cpp17
1 files changed, 13 insertions, 4 deletions
diff --git a/src/resources/mapreader.cpp b/src/resources/mapreader.cpp
index cd5a1feb7..e6e0dc912 100644
--- a/src/resources/mapreader.cpp
+++ b/src/resources/mapreader.cpp
@@ -415,6 +415,7 @@ Map *MapReader::readMap(XmlNodePtrConst node, const std::string &path)
const int tileOffsetY = XML::getProperty(childNode, "y", 0);
const int offsetX = tileOffsetX * tilew;
const int offsetY = tileOffsetY * tileh;
+ const bool showParticles = config.getBoolValue("mapparticleeffects");
for_each_xml_child_node(objectNode, childNode)
{
@@ -454,10 +455,18 @@ Map *MapReader::readMap(XmlNodePtrConst node, const std::string &path)
continue;
}
- map->addParticleEffect(objName,
- objX + offsetX,
- objY + offsetY,
- objW, objH);
+ if (showParticles)
+ {
+ map->addParticleEffect(objName,
+ objX + offsetX,
+ objY + offsetY,
+ objW,
+ objH);
+ }
+ else
+ {
+ logger->log("Ignore particle effect: " + objName);
+ }
}
else if (objType == "WARP")
{