summaryrefslogtreecommitdiff
path: root/src/net/tmwa/adminhandler.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-09-19 17:33:16 +0300
committerAndrei Karas <akaras@inbox.ru>2014-09-19 17:33:16 +0300
commitb7addc0a9a519cf9dcc3e804d9918ce4934a3e83 (patch)
treeeed5cd349f7e9db512fd1e940ed7b070df1c6a35 /src/net/tmwa/adminhandler.cpp
parent403792db7d005066273bcbe138afcd1a98b3144c (diff)
downloadManaVerse-b7addc0a9a519cf9dcc3e804d9918ce4934a3e83.tar.gz
ManaVerse-b7addc0a9a519cf9dcc3e804d9918ce4934a3e83.tar.bz2
ManaVerse-b7addc0a9a519cf9dcc3e804d9918ce4934a3e83.tar.xz
ManaVerse-b7addc0a9a519cf9dcc3e804d9918ce4934a3e83.zip
Add comments for all output packets header.
Diffstat (limited to 'src/net/tmwa/adminhandler.cpp')
-rw-r--r--src/net/tmwa/adminhandler.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/net/tmwa/adminhandler.cpp b/src/net/tmwa/adminhandler.cpp
index 44b6f9038..5a35ed3c4 100644
--- a/src/net/tmwa/adminhandler.cpp
+++ b/src/net/tmwa/adminhandler.cpp
@@ -76,27 +76,27 @@ void AdminHandler::handleMessage(Net::MessageIn &msg)
void AdminHandler::announce(const std::string &text) const
{
- MessageOut outMsg(CMSG_ADMIN_ANNOUNCE);
+ createOutPacket(CMSG_ADMIN_ANNOUNCE);
outMsg.writeInt16(static_cast<int16_t>(text.length() + 4), "len");
outMsg.writeString(text, static_cast<int>(text.length()), "message");
}
void AdminHandler::localAnnounce(const std::string &text) const
{
- MessageOut outMsg(CMSG_ADMIN_LOCAL_ANNOUNCE);
+ createOutPacket(CMSG_ADMIN_LOCAL_ANNOUNCE);
outMsg.writeInt16(static_cast<int16_t>(text.length() + 4), "len");
outMsg.writeString(text, static_cast<int>(text.length()), "message");
}
void AdminHandler::hide(const bool h A_UNUSED) const
{
- MessageOut outMsg(CMSG_ADMIN_HIDE);
+ createOutPacket(CMSG_ADMIN_HIDE);
outMsg.writeInt32(0, "unused");
}
void AdminHandler::kick(const int playerId) const
{
- MessageOut outMsg(CMSG_ADMIN_KICK);
+ createOutPacket(CMSG_ADMIN_KICK);
outMsg.writeInt32(playerId, "account id");
}