summaryrefslogtreecommitdiff
path: root/src/resources/emotedb.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-01-10 21:06:33 +0300
committerAndrei Karas <akaras@inbox.ru>2012-01-10 21:06:33 +0300
commit5edddb1313ed0dc275e6ae70b8a1780ded3a590d (patch)
treefffa478013e8f3622c4e7f85eeb71609cb352322 /src/resources/emotedb.cpp
parenta057817a0983b3a3190f6773101f788f2c6278ba (diff)
downloadmanaverse-5edddb1313ed0dc275e6ae70b8a1780ded3a590d.tar.gz
manaverse-5edddb1313ed0dc275e6ae70b8a1780ded3a590d.tar.bz2
manaverse-5edddb1313ed0dc275e6ae70b8a1780ded3a590d.tar.xz
manaverse-5edddb1313ed0dc275e6ae70b8a1780ded3a590d.zip
Replace xmlStrEqual to xmlNameEqual.
Diffstat (limited to 'src/resources/emotedb.cpp')
-rw-r--r--src/resources/emotedb.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/resources/emotedb.cpp b/src/resources/emotedb.cpp
index 163d8b879..c6126a57b 100644
--- a/src/resources/emotedb.cpp
+++ b/src/resources/emotedb.cpp
@@ -54,7 +54,7 @@ void EmoteDB::load()
XML::Document doc("emotes.xml");
XmlNodePtr rootNode = doc.rootNode();
- if (!rootNode || !xmlStrEqual(rootNode->name, BAD_CAST "emotes"))
+ if (!rootNode || !xmlNameEqual(rootNode, "emotes"))
{
logger->log1("Emote Database: Error while loading emotes.xml!");
return;
@@ -63,7 +63,7 @@ void EmoteDB::load()
//iterate <emote>s
for_each_xml_child_node(emoteNode, rootNode)
{
- if (!xmlStrEqual(emoteNode->name, BAD_CAST "emote"))
+ if (!xmlNameEqual(emoteNode, "emote"))
continue;
int id = XML::getProperty(emoteNode, "id", -1);
@@ -81,7 +81,7 @@ void EmoteDB::load()
if (!spriteNode->xmlChildrenNode)
continue;
- if (xmlStrEqual(spriteNode->name, BAD_CAST "sprite"))
+ if (xmlNameEqual(spriteNode, "sprite"))
{
EmoteSprite *currentSprite = new EmoteSprite;
std::string file = paths.getStringValue("sprites")
@@ -92,7 +92,7 @@ void EmoteDB::load()
currentSprite->name = XML::getProperty(spriteNode, "name", "");
currentInfo->sprites.push_back(currentSprite);
}
- else if (xmlStrEqual(spriteNode->name, BAD_CAST "particlefx"))
+ else if (xmlNameEqual(spriteNode, "particlefx"))
{
std::string particlefx = reinterpret_cast<const char*>(
spriteNode->xmlChildrenNode->content);
@@ -108,7 +108,7 @@ void EmoteDB::load()
XML::Document doc2("graphics/sprites/manaplus_emotes.xml");
rootNode = doc2.rootNode();
- if (!rootNode || !xmlStrEqual(rootNode->name, BAD_CAST "emotes"))
+ if (!rootNode || !xmlNameEqual(rootNode, "emotes"))
{
logger->log1("Emote Database: Error while loading"
" manaplus_emotes.xml!");
@@ -118,7 +118,7 @@ void EmoteDB::load()
//iterate <emote>s
for_each_xml_child_node(emoteNode, rootNode)
{
- if (!xmlStrEqual(emoteNode->name, BAD_CAST "emote"))
+ if (!xmlNameEqual(emoteNode, "emote"))
continue;
int id = XML::getProperty(emoteNode, "id", -1);
@@ -136,7 +136,7 @@ void EmoteDB::load()
if (!spriteNode->xmlChildrenNode)
continue;
- if (xmlStrEqual(spriteNode->name, BAD_CAST "sprite"))
+ if (xmlNameEqual(spriteNode, "sprite"))
{
EmoteSprite *currentSprite = new EmoteSprite;
std::string file = paths.getStringValue("sprites")
@@ -147,7 +147,7 @@ void EmoteDB::load()
currentSprite->name = XML::getProperty(spriteNode, "name", "");
currentInfo->sprites.push_back(currentSprite);
}
- else if (xmlStrEqual(spriteNode->name, BAD_CAST "particlefx"))
+ else if (xmlNameEqual(spriteNode, "particlefx"))
{
std::string particlefx = reinterpret_cast<const char*>(
spriteNode->xmlChildrenNode->content);