From e2357924e81c3239e5ca2af0afda2a770acb8288 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 24 Oct 2014 00:53:04 +0300 Subject: Add packet fields comments in mercenaryhandler. --- src/net/eathena/mercenaryhandler.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src') diff --git a/src/net/eathena/mercenaryhandler.cpp b/src/net/eathena/mercenaryhandler.cpp index aa6152035..89e274252 100644 --- a/src/net/eathena/mercenaryhandler.cpp +++ b/src/net/eathena/mercenaryhandler.cpp @@ -189,7 +189,7 @@ void MercenaryHandler::moveToMaster() const if (!id) return; createOutPacket(CMSG_HOMMERC_MOVE_TO_MASTER); - outMsg.writeInt32(id); + outMsg.writeInt32(id, "mercenary id"); } void MercenaryHandler::move(const int x, const int y) const @@ -198,21 +198,21 @@ void MercenaryHandler::move(const int x, const int y) const if (!id) return; createOutPacket(CMSG_HOMMERC_MOVE_TO); - outMsg.writeInt32(id); + outMsg.writeInt32(id, "mercenary id"); outMsg.writeCoordinates(static_cast(x), static_cast(y), - 0U); + 0U, "position"); } void MercenaryHandler::attack(const int targetId, const bool keep) const { - const int id = PlayerInfo::getHomunculusId(); + const int id = PlayerInfo::getMercenaryId(); if (!id) return; createOutPacket(CMSG_HOMMERC_ATTACK); - outMsg.writeInt32(id); - outMsg.writeInt32(targetId); - outMsg.writeInt8(static_cast(keep ? 1 : 0)); + outMsg.writeInt32(id, "mercenary id"); + outMsg.writeInt32(targetId, "target id"); + outMsg.writeInt8(static_cast(keep ? 1 : 0), "keep"); } } // namespace EAthena -- cgit v1.2.3-60-g2f50