diff options
author | Chuck Miller <shadowmil@gmail.com> | 2010-07-18 23:02:25 -0400 |
---|---|---|
committer | Chuck Miller <shadowmil@gmail.com> | 2010-07-18 23:10:02 -0400 |
commit | 41a23cb4511e9ba3985990e2703fb3d680a23d14 (patch) | |
tree | 2bf03217e3c3b0f28aed5649e2e43cf2b965bd1d /src/net/manaserv/partyhandler.cpp | |
parent | 782158dfd719fb6d196f79075f275fb8599d393c (diff) | |
download | mana-client-41a23cb4511e9ba3985990e2703fb3d680a23d14.tar.gz mana-client-41a23cb4511e9ba3985990e2703fb3d680a23d14.tar.bz2 mana-client-41a23cb4511e9ba3985990e2703fb3d680a23d14.tar.xz mana-client-41a23cb4511e9ba3985990e2703fb3d680a23d14.zip |
Move the majority of the netcode's server messages to the event system
There is still a good way to go, but this should get us
started
Reviewed-by: Jared Adams
Diffstat (limited to 'src/net/manaserv/partyhandler.cpp')
-rw-r--r-- | src/net/manaserv/partyhandler.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/net/manaserv/partyhandler.cpp b/src/net/manaserv/partyhandler.cpp index 2fd48f57..a9145269 100644 --- a/src/net/manaserv/partyhandler.cpp +++ b/src/net/manaserv/partyhandler.cpp @@ -21,13 +21,13 @@ #include "net/manaserv/partyhandler.h" +#include "event.h" +#include "eventmanager.h" #include "log.h" #include "localplayer.h" #include "gui/socialwindow.h" -#include "gui/widgets/chattab.h" - #include "net/manaserv/connection.h" #include "net/manaserv/messagein.h" #include "net/manaserv/messageout.h" @@ -85,7 +85,7 @@ void PartyHandler::handleMessage(Net::MessageIn &msg) if (msg.readInt8() == ERRMSG_OK) { // - localChatTab->chatLog(_("Joined party.")); + SERVER_NOTICE(_("Joined party.")); } } @@ -103,7 +103,7 @@ void PartyHandler::handleMessage(Net::MessageIn &msg) int id = msg.readInt16(); // being id std::string name = msg.readString(); - localChatTab->chatLog(strprintf(_("%s joined the party."), + SERVER_NOTICE(strprintf(_("%s joined the party."), name.c_str())); if (id == player_node->getId()) @@ -120,8 +120,8 @@ void PartyHandler::handleMessage(Net::MessageIn &msg) case CPMSG_PARTY_REJECTED: { std::string name = msg.readString(); - localChatTab->chatLog(strprintf(_("%s rejected your invite."), - name.c_str())); + SERVER_NOTICE(strprintf( + _("%s rejected your invite."), name.c_str())); } break; } } |