From 9fe21fcd8883b37bdc30224822e6e42afb35b8f0 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 7 Feb 2016 16:18:13 +0300 Subject: Replace most static_cast to shorter versions from defines. --- src/net/tmwa/partyhandler.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/net/tmwa/partyhandler.cpp') diff --git a/src/net/tmwa/partyhandler.cpp b/src/net/tmwa/partyhandler.cpp index 8c477e9ec..94471e4c3 100644 --- a/src/net/tmwa/partyhandler.cpp +++ b/src/net/tmwa/partyhandler.cpp @@ -117,8 +117,8 @@ void PartyHandler::kick(const std::string &name) const void PartyHandler::chat(const std::string &text) const { createOutPacket(CMSG_PARTY_MESSAGE); - outMsg.writeInt16(static_cast(text.length() + 4), "len"); - outMsg.writeString(text, static_cast(text.length()), "text"); + outMsg.writeInt16(CAST_S16(text.length() + 4), "len"); + outMsg.writeString(text, CAST_S32(text.length()), "text"); } void PartyHandler::setShareExperience(const PartyShareT share) const @@ -127,8 +127,8 @@ void PartyHandler::setShareExperience(const PartyShareT share) const return; createOutPacket(CMSG_PARTY_SETTINGS); - outMsg.writeInt16(static_cast(share), "share exp"); - outMsg.writeInt16(static_cast(Ea::PartyRecv::mShareItems), + outMsg.writeInt16(CAST_S16(share), "share exp"); + outMsg.writeInt16(CAST_S16(Ea::PartyRecv::mShareItems), "share items"); } @@ -138,9 +138,9 @@ void PartyHandler::setShareItems(const PartyShareT share) const return; createOutPacket(CMSG_PARTY_SETTINGS); - outMsg.writeInt16(static_cast(Ea::PartyRecv::mShareExp), + outMsg.writeInt16(CAST_S16(Ea::PartyRecv::mShareExp), "share exp"); - outMsg.writeInt16(static_cast(share), "share items"); + outMsg.writeInt16(CAST_S16(share), "share items"); } void PartyHandler::changeLeader(const std::string &name A_UNUSED) const -- cgit v1.2.3-60-g2f50