summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-08-27 22:28:05 +0300
committerAndrei Karas <akaras@inbox.ru>2011-08-27 22:28:05 +0300
commit064a2aea075b9d519912e7fdb98c5e06eb4ab9f0 (patch)
treecd33b1f790f20ddf8b64840015d13c6bd6cc13a2 /src
parenteb8269b40570333ce6a2787dd55f5081c73c14a7 (diff)
downloadplus-064a2aea075b9d519912e7fdb98c5e06eb4ab9f0.tar.gz
plus-064a2aea075b9d519912e7fdb98c5e06eb4ab9f0.tar.bz2
plus-064a2aea075b9d519912e7fdb98c5e06eb4ab9f0.tar.xz
plus-064a2aea075b9d519912e7fdb98c5e06eb4ab9f0.zip
Add guild name to beings cache.
Diffstat (limited to 'src')
-rw-r--r--src/being.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/being.cpp b/src/being.cpp
index eeb366b5d..36aa00689 100644
--- a/src/being.cpp
+++ b/src/being.cpp
@@ -97,6 +97,7 @@ class BeingCacheEntry
mId(id),
mName(""),
mPartyName(""),
+ mGuildName(""),
mLevel(0),
mPvpRank(0),
mTime(0),
@@ -129,9 +130,15 @@ class BeingCacheEntry
void setPartyName(const std::string &name)
{ mPartyName = name; }
+ void setGuildName(const std::string &name)
+ { mGuildName = name; }
+
const std::string &getPartyName() const
{ return mPartyName; }
+ const std::string &getGuildName() const
+ { return mGuildName; }
+
void setLevel(int n)
{ mLevel = n; }
@@ -172,6 +179,7 @@ class BeingCacheEntry
int mId; /**< Unique sprite id */
std::string mName; /**< Name of character */
std::string mPartyName;
+ std::string mGuildName;
int mLevel;
unsigned int mPvpRank;
int mTime;
@@ -1773,6 +1781,7 @@ bool Being::updateFromCache()
if (!entry->getName().empty())
setName(entry->getName());
setPartyName(entry->getPartyName());
+ setGuildName(entry->getGuildName());
setLevel(entry->getLevel());
setPvpRank(entry->getPvpRank());
setIp(entry->getIp());
@@ -1824,6 +1833,7 @@ void Being::addToCache()
entry->setName(getName());
entry->setLevel(getLevel());
entry->setPartyName(getPartyName());
+ entry->setGuildName(getGuildName());
entry->setTime(cur_time);
entry->setPvpRank(getPvpRank());
entry->setIp(getIp());