From 106180f42f536f4b898a72f36af1b2be28d1a8ed Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 28 Aug 2011 00:18:58 +0300 Subject: Fix guild name reset on players from time. --- src/being.cpp | 1 - src/net/ea/beinghandler.cpp | 4 +++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/being.cpp b/src/being.cpp index 36aa00689..2d9194c6e 100644 --- a/src/being.cpp +++ b/src/being.cpp @@ -760,7 +760,6 @@ void Being::setGuildName(const std::string &name) mGuildName = name; } - void Being::setGuildPos(const std::string &pos A_UNUSED) { // logger->log("Got guild position \"%s\" for being %s(%i)", pos.c_str(), mName.c_str(), mId); diff --git a/src/net/ea/beinghandler.cpp b/src/net/ea/beinghandler.cpp index 06e86f8a4..2714f94ce 100644 --- a/src/net/ea/beinghandler.cpp +++ b/src/net/ea/beinghandler.cpp @@ -29,6 +29,7 @@ #include "client.h" #include "effectmanager.h" #include "guild.h" +#include "guildmanager.h" #include "keyboardconfig.h" #include "localplayer.h" #include "logger.h" @@ -661,7 +662,8 @@ void BeingHandler::processPlayerGuilPartyInfo(Net::MessageIn &msg) if ((dstBeing = actorSpriteManager->findBeing(msg.readInt32()))) { dstBeing->setPartyName(msg.readString(24)); - dstBeing->setGuildName(msg.readString(24)); + if (!guildManager || !guildManager->getEnableGuildBot()) + dstBeing->setGuildName(msg.readString(24)); dstBeing->setGuildPos(msg.readString(24)); dstBeing->addToCache(); msg.readString(24); // Discard this -- cgit v1.2.3-70-g09d2