diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-03-21 15:33:52 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-03-21 15:33:52 +0300 |
commit | 68857593b01b73d33fa1a12011cf9cb402db8a73 (patch) | |
tree | 9b8a7a2b1349ddc2e88d307b91246e2e7a21e460 | |
parent | 8581934ba2f8ae80073cfabd08834df39a9c16bd (diff) | |
download | manaverse-68857593b01b73d33fa1a12011cf9cb402db8a73.tar.gz manaverse-68857593b01b73d33fa1a12011cf9cb402db8a73.tar.bz2 manaverse-68857593b01b73d33fa1a12011cf9cb402db8a73.tar.xz manaverse-68857593b01b73d33fa1a12011cf9cb402db8a73.zip |
Remove support for stun effects from status-effects.xml
-rw-r--r-- | src/statuseffect.cpp | 18 | ||||
-rw-r--r-- | src/statuseffect.h | 11 |
2 files changed, 0 insertions, 29 deletions
diff --git a/src/statuseffect.cpp b/src/statuseffect.cpp index 97ce131ab..591b70815 100644 --- a/src/statuseffect.cpp +++ b/src/statuseffect.cpp @@ -111,7 +111,6 @@ std::string StatusEffect::getAction() const typedef std::map<int, StatusEffect *> status_effect_map[2]; static status_effect_map statusEffects; -static status_effect_map stunEffects; static std::map<int, int> blockEffectIndexMap; int StatusEffect::blockEffectIndexToEffectIndex(const int blockIndex) @@ -138,17 +137,6 @@ StatusEffect *StatusEffect::getStatusEffect(const int index, return nullptr; } -StatusEffect *StatusEffect::getStunEffect(const int index, - const Enable enabling) -{ - std::map<int, StatusEffect *> &effects - = stunEffects[enabling == Enable_true]; - const std::map<int, StatusEffect *>::iterator it = effects.find(index); - if (it != effects.end()) - return (*it).second; - return nullptr; -} - void StatusEffect::load() { if (mLoaded) @@ -195,10 +183,6 @@ void StatusEffect::loadXmlFile(const std::string &fileName) if (index >= 0 && block_index >= 0) blockEffectIndexMap[block_index] = index; } - else if (xmlNameEqual(node, "stun-effect")) - { - the_map = &stunEffects; - } if (the_map) { @@ -268,8 +252,6 @@ void StatusEffect::unload() unloadMap(statusEffects[0]); unloadMap(statusEffects[1]); - unloadMap(stunEffects[0]); - unloadMap(stunEffects[1]); mLoaded = false; } diff --git a/src/statuseffect.h b/src/statuseffect.h index 9539e4224..698a33bd0 100644 --- a/src/statuseffect.h +++ b/src/statuseffect.h @@ -106,17 +106,6 @@ class StatusEffect final A_WARN_UNUSED; /** - * Retrieves a stun effect. - * - * \param index Index of the stun effect. - * \param enabling Whether to retrieve the activating effect (true) or - * the deactivating effect (false). - */ - static StatusEffect *getStunEffect(const int index, - const Enable enabling) - A_WARN_UNUSED; - - /** * Maps a block effect index to its corresponding effect index. Block * effect indices are used for opt2/opt3/status.option blocks; their * mapping to regular effect indices is handled in the config file. |