diff options
author | Jared Adams <jaxad0127@gmail.com> | 2010-02-24 06:50:35 -0700 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2010-02-24 07:55:20 -0700 |
commit | f6d50d0cbe12f8799e6fec844816defc8711df37 (patch) | |
tree | 344f28132bd3aa54ce058e92b4696d00f3a7bc0c /src/net/ea/beinghandler.cpp | |
parent | 3adb0710b9b0262b7d7a03aa687e78c232f04d06 (diff) | |
download | mana-client-f6d50d0cbe12f8799e6fec844816defc8711df37.tar.gz mana-client-f6d50d0cbe12f8799e6fec844816defc8711df37.tar.bz2 mana-client-f6d50d0cbe12f8799e6fec844816defc8711df37.tar.xz mana-client-f6d50d0cbe12f8799e6fec844816defc8711df37.zip |
Add more to eAthena guild support
It's not complete yet, but it is closer. Also fix up handling of guild/party members.
Reviewed-by: Chuck Miller
Diffstat (limited to 'src/net/ea/beinghandler.cpp')
-rw-r--r-- | src/net/ea/beinghandler.cpp | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/src/net/ea/beinghandler.cpp b/src/net/ea/beinghandler.cpp index 8803fafb..dbfc0f3b 100644 --- a/src/net/ea/beinghandler.cpp +++ b/src/net/ea/beinghandler.cpp @@ -25,6 +25,7 @@ #include "beingmanager.h" #include "client.h" #include "effectmanager.h" +#include "guild.h" #include "localplayer.h" #include "log.h" #include "npc.h" @@ -106,7 +107,7 @@ void BeingHandler::handleMessage(Net::MessageIn &msg) int param1; int stunMode; Uint32 statusEffects; - int type; + int type, guild; Uint16 status; Being *srcBeing, *dstBeing; Player *player; @@ -179,9 +180,19 @@ void BeingHandler::handleMessage(Net::MessageIn &msg) hairColor = msg.readInt16(); shoes = msg.readInt16(); // clothes color - "abused" as shoes gloves = msg.readInt16(); // head dir - "abused" as gloves - msg.readInt16(); // guild - msg.readInt16(); // unknown - msg.readInt16(); // unknown + guild = msg.readInt32(); // guild + if (player) + { + if (guild == 0) + { + player->clearGuilds(); + } + else + { + player->addGuild(Guild::getGuild(guild)); + } + } + msg.readInt16(); // guild emblem msg.readInt16(); // manner dstBeing->setStatusEffectBlock(32, msg.readInt16()); // opt3 msg.readInt8(); // karma |