From 91075015ad4b5bd576c1a5668a11ea0227dd6bd1 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 23 Jul 2013 23:19:30 +0300 Subject: add support for attacksky and attackwater actions. --- src/resources/beinginfo.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src/resources/beinginfo.cpp') diff --git a/src/resources/beinginfo.cpp b/src/resources/beinginfo.cpp index 1d316df5e..48e8b8493 100644 --- a/src/resources/beinginfo.cpp +++ b/src/resources/beinginfo.cpp @@ -32,6 +32,7 @@ BeingInfo *BeingInfo::unknown = nullptr; Attack *BeingInfo::empty = new Attack(SpriteAction::ATTACK, + SpriteAction::ATTACKSKY, SpriteAction::ATTACKWATER, -1, -1, -1, -1, std::string()); BeingInfo::BeingInfo() : @@ -128,14 +129,16 @@ const Attack *BeingInfo::getAttack(const int id) const return (i == mAttacks.end()) ? empty : (*i).second; } -void BeingInfo::addAttack(const int id, std::string action, const int effectId, - const int hitEffectId, const int criticalHitEffectId, +void BeingInfo::addAttack(const int id, std::string action, + std::string skyAction, std::string waterAction, + const int effectId, const int hitEffectId, + const int criticalHitEffectId, const int missEffectId, const std::string &missileParticle) { delete mAttacks[id]; - mAttacks[id] = new Attack(action, effectId, hitEffectId, - criticalHitEffectId, missEffectId, missileParticle); + mAttacks[id] = new Attack(action, skyAction, waterAction, effectId, + hitEffectId, criticalHitEffectId, missEffectId, missileParticle); } void BeingInfo::clear() -- cgit v1.2.3-60-g2f50