summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog6
-rw-r--r--src/net/chatserver/chatserver.cpp9
-rw-r--r--src/net/chatserver/chatserver.h2
-rw-r--r--src/net/protocol.h19
4 files changed, 13 insertions, 23 deletions
diff --git a/ChangeLog b/ChangeLog
index 9d66f3c0..3b939bf4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2008-06-10 Roderic Morris <roderic@ccs.neu.edu>
+
+ * src/net/protocol.h src/net/chatserver/chatserver.h,
+ src/net/chatserver/chatserver.cpp: Update chat packet
+ definitions, get rid of old unused functions.
+
2008-06-09 Roderic Morris <roderic@ccs.neu.edu>
* src/commandhandler.cpp, src/commandhandler.h,
diff --git a/src/net/chatserver/chatserver.cpp b/src/net/chatserver/chatserver.cpp
index 9f2c871a..fbf7355f 100644
--- a/src/net/chatserver/chatserver.cpp
+++ b/src/net/chatserver/chatserver.cpp
@@ -91,15 +91,6 @@ void Net::ChatServer::registerChannel(const std::string &name,
connection->send(msg);
}
-void Net::ChatServer::unregisterChannel(short channel)
-{
- MessageOut msg(PCMSG_UNREGISTER_CHANNEL);
-
- msg.writeInt16(channel);
-
- connection->send(msg);
-}
-
void Net::ChatServer::enterChannel(const std::string &channel, const std::string &password)
{
MessageOut msg(PCMSG_ENTER_CHANNEL);
diff --git a/src/net/chatserver/chatserver.h b/src/net/chatserver/chatserver.h
index 1a34f442..411d5e7b 100644
--- a/src/net/chatserver/chatserver.h
+++ b/src/net/chatserver/chatserver.h
@@ -45,8 +45,6 @@ namespace Net
void registerChannel(const std::string &name,
const std::string &announcement, const std::string &password);
- void unregisterChannel(short channel);
-
void enterChannel(const std::string &channel, const std::string &password);
void quitChannel(short channel);
diff --git a/src/net/protocol.h b/src/net/protocol.h
index 87577942..3d3f47cf 100644
--- a/src/net/protocol.h
+++ b/src/net/protocol.h
@@ -163,20 +163,15 @@ enum {
PCMSG_ANNOUNCE = 0x0411, // S text
PCMSG_PRIVMSG = 0x0412, // S user, S text
// -- Channeling
- PCMSG_REGISTER_CHANNEL = 0x0420, // B pub/priv, S name, S announcement, S password
- CPMSG_REGISTER_CHANNEL_RESPONSE = 0x0421, // B error, W channel, S channel
- PCMSG_UNREGISTER_CHANNEL = 0x0422, // W channel
- CPMSG_UNREGISTER_CHANNEL_RESPONSE = 0x0423, // B error
+ PCMSG_REGISTER_CHANNEL = 0x0420, // S name, S announcement, S password
+ CPMSG_REGISTER_CHANNEL_RESPONSE = 0x0421, // B error, W id, S name, S announcement
CPMSG_CHANNEL_EVENT = 0x0430, // W channel, B event, S user
- PCMSG_ENTER_CHANNEL = 0x0440, // W channel, S password
- CPMSG_ENTER_CHANNEL_RESPONSE = 0x0441, // B error, W channel, S channel
- CPMSG_JOINED_CHANNEL = 0x0442, // S channel, W channel id
- PCMSG_QUIT_CHANNEL = 0x0443, // W channel
- CPMSG_QUIT_CHANNEL_RESPONSE = 0x0444, // B error
+ PCMSG_ENTER_CHANNEL = 0x0440, // S channel, S password
+ CPMSG_ENTER_CHANNEL_RESPONSE = 0x0441, // B error, W id, S name, S announcement, S userlist
+ PCMSG_QUIT_CHANNEL = 0x0443, // W channel id
+ CPMSG_QUIT_CHANNEL_RESPONSE = 0x0444, // B error, W channel id
PCMSG_LIST_CHANNELS = 0x0445, // -
- CPMSG_LIST_CHANNELS_RESPONSE = 0x0446, // W number of channels, S channels
- CPMSG_USERJOINED = 0x0450, // W channel, S name
- CPMSG_USERLEFT = 0x0451, // W channel, S name
+ CPMSG_LIST_CHANNELS_RESPONSE = 0x0446, // S names, W number of users
PCMSG_LIST_CHANNELUSERS = 0x0460, // S channel
CPMSG_LIST_CHANNELUSERS_RESPONSE = 0x0461, // S channel, S users