summaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
authorRoderic Morris <roderic@ccs.neu.edu>2008-06-10 12:58:51 +0000
committerRoderic Morris <roderic@ccs.neu.edu>2008-06-10 12:58:51 +0000
commita83cc00d5e0169500d17a9e14b393bab2306ff0a (patch)
tree447c548ba5fe1503997e45a98ba2ce3012884b31 /src/net
parentf6f031fa4db6fa0ccd6e0b433f61479e9fd85477 (diff)
downloadmana-client-a83cc00d5e0169500d17a9e14b393bab2306ff0a.tar.gz
mana-client-a83cc00d5e0169500d17a9e14b393bab2306ff0a.tar.bz2
mana-client-a83cc00d5e0169500d17a9e14b393bab2306ff0a.tar.xz
mana-client-a83cc00d5e0169500d17a9e14b393bab2306ff0a.zip
update chat packet defs, get rid of unused functions
Diffstat (limited to 'src/net')
-rw-r--r--src/net/chatserver/chatserver.cpp9
-rw-r--r--src/net/chatserver/chatserver.h2
-rw-r--r--src/net/protocol.h19
3 files changed, 7 insertions, 23 deletions
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