summaryrefslogtreecommitdiff
path: root/src/resources/beingcommon.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-08-07 20:44:16 +0300
committerAndrei Karas <akaras@inbox.ru>2017-08-07 20:44:16 +0300
commit04716c42ec49bfbb42296dd8980d6f8dd1c09e59 (patch)
treea2cf6e57036d96609a653cf68f2adc9255fec5ba /src/resources/beingcommon.cpp
parent8ec4e8575001e50ac2917b0a1599d2a6223aa337 (diff)
downloadmanaverse-04716c42ec49bfbb42296dd8980d6f8dd1c09e59.tar.gz
manaverse-04716c42ec49bfbb42296dd8980d6f8dd1c09e59.tar.bz2
manaverse-04716c42ec49bfbb42296dd8980d6f8dd1c09e59.tar.xz
manaverse-04716c42ec49bfbb42296dd8980d6f8dd1c09e59.zip
Add additional attributes to missile particle in attacks.
Diffstat (limited to 'src/resources/beingcommon.cpp')
-rw-r--r--src/resources/beingcommon.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/resources/beingcommon.cpp b/src/resources/beingcommon.cpp
index 6d244960f..7e5fb9481 100644
--- a/src/resources/beingcommon.cpp
+++ b/src/resources/beingcommon.cpp
@@ -231,6 +231,15 @@ bool BeingCommon::readObjectNodes(XmlNodePtrConst &spriteNode,
const std::string missileParticle = XML::getProperty(spriteNode,
"missile-particle", "");
+ const float missileZ = static_cast<float>(XML::getFloatProperty(
+ spriteNode, "missile-z", 32.0f));
+ const int missileLifeTime = static_cast<float>(XML::getProperty(
+ spriteNode, "missile-lifetime", 3000));
+ const float missileSpeed = static_cast<float>(XML::getFloatProperty(
+ spriteNode, "missile-speed", 7.0f));
+ const float missileDieDistance = static_cast<float>(
+ XML::getFloatProperty(spriteNode, "missile-diedistance", 8.0f));
+
currentInfo->addAttack(attackId,
spriteAction,
skySpriteAction,
@@ -240,7 +249,11 @@ bool BeingCommon::readObjectNodes(XmlNodePtrConst &spriteNode,
hitEffectId,
criticalHitEffectId,
missEffectId,
- missileParticle);
+ missileParticle,
+ missileZ,
+ missileSpeed,
+ missileDieDistance,
+ missileLifeTime);
return true;
}
else if (xmlNameEqual(spriteNode, "particlefx"))