summaryrefslogtreecommitdiff
path: root/src/net/chathandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/chathandler.cpp')
-rw-r--r--src/net/chathandler.cpp34
1 files changed, 0 insertions, 34 deletions
diff --git a/src/net/chathandler.cpp b/src/net/chathandler.cpp
index ce4a91da..43ca5a71 100644
--- a/src/net/chathandler.cpp
+++ b/src/net/chathandler.cpp
@@ -47,7 +47,6 @@ ChatHandler::ChatHandler()
{
static const Uint16 _messages[] = {
GPMSG_SAY,
- CPMSG_REGISTER_CHANNEL_RESPONSE,
CPMSG_ENTER_CHANNEL_RESPONSE,
CPMSG_LIST_CHANNELS_RESPONSE,
CPMSG_PUBMSG,
@@ -69,10 +68,6 @@ void ChatHandler::handleMessage(MessageIn &msg)
handleGameChatMessage(msg);
break;
- case CPMSG_REGISTER_CHANNEL_RESPONSE:
- handleRegisterChannelResponse(msg);
- break;
-
case CPMSG_ENTER_CHANNEL_RESPONSE:
handleEnterChannelResponse(msg);
break;
@@ -131,35 +126,6 @@ void ChatHandler::handleGameChatMessage(MessageIn &msg)
}
}
-void ChatHandler::handleRegisterChannelResponse(MessageIn &msg)
-{
- char error = msg.readInt8();
- if(error == ERRMSG_OK)
- {
- short channelId = msg.readInt16();
- std::string channelName = msg.readString();
- std::string channelAnnouncement = msg.readString();
- chatWindow->chatLog("Registered Channel " + channelName);
- channelManager->addChannel(new Channel(channelId,
- channelName,
- channelAnnouncement));
- chatWindow->createNewChannelTab(channelName);
- chatWindow->chatLog("Topic: " + channelAnnouncement, BY_CHANNEL, channelName);
-
- }
- else
- {
- if (error == ERRMSG_INVALID_ARGUMENT)
- {
- chatWindow->chatLog("Error registering channel - Invalid Channel Name given", BY_SERVER);
- }
- else
- {
- chatWindow->chatLog("Error registering channel", BY_SERVER);
- }
- }
-}
-
void ChatHandler::handleEnterChannelResponse(MessageIn &msg)
{
if(msg.readInt8() == ERRMSG_OK)