From f6d50d0cbe12f8799e6fec844816defc8711df37 Mon Sep 17 00:00:00 2001 From: Jared Adams Date: Wed, 24 Feb 2010 06:50:35 -0700 Subject: 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 --- src/net/manaserv/guildhandler.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'src/net/manaserv/guildhandler.cpp') diff --git a/src/net/manaserv/guildhandler.cpp b/src/net/manaserv/guildhandler.cpp index 0dfe8cde..253efb01 100644 --- a/src/net/manaserv/guildhandler.cpp +++ b/src/net/manaserv/guildhandler.cpp @@ -131,9 +131,8 @@ void GuildHandler::handleMessage(Net::MessageIn &msg) online = msg.readInt8(); if (name != "") { - member = new GuildMember(guildId, name); + member = guild->addMember(name); member->setOnline(online); - guild->addMember(member); } } } @@ -153,9 +152,8 @@ void GuildHandler::handleMessage(Net::MessageIn &msg) switch(eventId) { case GUILD_EVENT_NEW_PLAYER: - member = new GuildMember(guildId, name); + member = guild->addMember(name); member->setOnline(true); - guild->addMember(member); break; case GUILD_EVENT_LEAVING_PLAYER: @@ -296,7 +294,7 @@ void GuildHandler::leave(int guildId) chatServerConnection->send(msg); } -void GuildHandler::kick(GuildMember member) +void GuildHandler::kick(GuildMember *member, std::string reason) { // TODO } @@ -313,7 +311,7 @@ void GuildHandler::memberList(int guildId) chatServerConnection->send(msg); } -void GuildHandler::changeMemberPostion(GuildMember member, int level) +void GuildHandler::changeMemberPostion(GuildMember *member, int level) { /*MessageOut msg(PCMSG_GUILD_PROMOTE_MEMBER); msg.writeInt16(guildId); -- cgit v1.2.3-70-g09d2