50 std::map<int, StatusEffect *> &effects
52 const std::map<int, StatusEffect *>::iterator it = effects.find(index);
53 if (it != effects.end())
65 logger->
log1(
"Initializing status effect database...");
79 XmlNodeConstPtrConst rootNode = doc.
rootNode();
81 if ((rootNode ==
nullptr) || !xmlNameEqual(rootNode,
"status-effects"))
89 if (xmlNameEqual(node,
"include"))
96 else if (!xmlNameEqual(node,
"status-effect"))
132 if (startEffect ==
nullptr)
134 if (endEffect ==
nullptr)
137 startEffect->
mName = name2;
149 node,
"start-message",
"");
151 node,
"start-audio",
"");
153 node,
"start-particle",
"");
155 node,
"particle",
"");
160 node,
"persistent-particle-effect",
"no")) !=
"no";
171 node,
"end-particle",
"");
178 static void unloadMap(std::map<int, StatusEffect *> &map)
180 for (std::map<int, StatusEffect *>::iterator it = map.begin();
181 it != map.end(); ++it)
194 logger->
log1(
"Unloading status effect database...");
static void loadXmlFile(const std::string &file, const std::string &name, BadgesInfos &arr, const SkipError skipError)
#define loadXmlDir(name, function)
#define reportAlways(...)
std::string getStringValue(const std::string &key) const
void log(const char *const log_text,...)
void log1(const char *const log_text)
std::string mStartParticleEffect
std::string mParticleEffect
#define for_each_xml_child_node(var, parent)
const OptionsMap & getOpt3Map()
const OptionsMap & getOpt2Map()
StatusEffect * getStatusEffect(const int index, const Enable enabling)
const OptionsMap & getOpt1Map()
void loadXmlFile(const std::string &fileName, const SkipError skipError)
const OptionsMap & getOptionMap()
std::string langProperty(const xmlNodePtr node, const char *const name, const std::string &def)
int getProperty(const xmlNodePtr node, const char *const name, int def)
IdToEffectMap statusEffects
std::map< int, StatusEffect * > IdToEffectMap[2]
const bool SkipError_false
const bool SkipError_true
static void unloadMap(std::map< int, StatusEffect * > &map)
std::map< uint32_t, uint32_t > OptionsMap
const bool UseVirtFs_true