From 50b27db1d671ab6ad1d887b0680aacf962ce0088 Mon Sep 17 00:00:00 2001 From: titiger Date: Tue, 25 Nov 2014 22:35:07 +0100 Subject: [PATCH] delete the projectile type if not needed --- source/glest_game/types/skill_type.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/glest_game/types/skill_type.cpp b/source/glest_game/types/skill_type.cpp index e6b3480e..77ee5b24 100644 --- a/source/glest_game/types/skill_type.cpp +++ b/source/glest_game/types/skill_type.cpp @@ -964,6 +964,9 @@ void AttackSkillType::load(const XmlNode *sn, const XmlNode *attackBoostsNode, loadedFileList[currentPath + path].push_back(make_pair(parentLoader,particleNode->getAttribute("path")->getRestrictedValue())); projectileType->setProjectileParticleSystemType(projectileParticleSystemType); } + else { + delete projectileType; + } } //proj sounds const XmlNode *soundNode= projectileNode->getChild("sound");