summaryrefslogtreecommitdiff
path: root/src/resources/db/badgesdb.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/resources/db/badgesdb.cpp')
-rw-r--r--src/resources/db/badgesdb.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/resources/db/badgesdb.cpp b/src/resources/db/badgesdb.cpp
index aff03fc4f..4a9ded0d8 100644
--- a/src/resources/db/badgesdb.cpp
+++ b/src/resources/db/badgesdb.cpp
@@ -35,6 +35,7 @@ namespace
BadgesInfos mGuilds;
BadgesInfos mNames;
BadgesInfos mParties;
+ BadgesInfos mClans;
bool mLoaded = false;
} // namespace
@@ -78,12 +79,14 @@ void BadgesDB::load()
loadDB("guild", mGuilds);
loadDB("name", mNames);
loadDB("party", mParties);
+ loadDB("clan", mClans);
}
void BadgesDB::unload()
{
logger->log1("Unloading Badges database...");
mParties.clear();
+ mClans.clear();
mGuilds.clear();
mNames.clear();
mLoaded = false;
@@ -112,3 +115,11 @@ const std::string BadgesDB::getGuildBadge(const std::string &name)
return std::string();
return (*it).second;
}
+
+const std::string BadgesDB::getClanBadge(const std::string &name)
+{
+ const BadgesInfosIter it = mClans.find(name);
+ if (it == mClans.end())
+ return std::string();
+ return (*it).second;
+}