From 3730cc48a543a5af1b4f91668d3395d594120c79 Mon Sep 17 00:00:00 2001 From: Richard Harrison Date: Sun, 20 Jan 2019 18:07:57 +0100 Subject: [PATCH] Fix particles active even when disabled during load. Possibly this could be fixed better by using the plugin string data - but there is nothing that currently set this; and it seems easier to use the particle callback enabled flag. --- simgear/scene/model/SGReaderWriterXML.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simgear/scene/model/SGReaderWriterXML.cxx b/simgear/scene/model/SGReaderWriterXML.cxx index f195f2c0..9d6b08c6 100644 --- a/simgear/scene/model/SGReaderWriterXML.cxx +++ b/simgear/scene/model/SGReaderWriterXML.cxx @@ -481,7 +481,7 @@ sgLoad3DModel_internal(const SGPath& path, } } - if (dbOptions->getPluginStringData("SimGear::PARTICLESYSTEM") != "OFF") { + if (GlobalParticleCallback::getEnabled()){//dbOptions->getPluginStringData("SimGear::PARTICLESYSTEM") != "OFF") { std::vector particle_nodes; particle_nodes = props->getChildren("particlesystem"); for (unsigned i = 0; i < particle_nodes.size(); ++i) {