From a87db81b6b7551a248e31e2850577aefda092538 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 5 May 2015 20:58:21 +0300 Subject: Replace most bools usage in playerinfo to strong typed bools. --- src/net/eathena/mercenaryhandler.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/net/eathena/mercenaryhandler.cpp') diff --git a/src/net/eathena/mercenaryhandler.cpp b/src/net/eathena/mercenaryhandler.cpp index e93edcc0b..1bc35a72f 100644 --- a/src/net/eathena/mercenaryhandler.cpp +++ b/src/net/eathena/mercenaryhandler.cpp @@ -207,7 +207,7 @@ void MercenaryHandler::move(const int x, const int y) const 0U, "position"); } -void MercenaryHandler::attack(const int targetId, const bool keep) const +void MercenaryHandler::attack(const int targetId, const Keep keep) const { const int id = PlayerInfo::getMercenaryId(); if (!id) @@ -215,7 +215,7 @@ void MercenaryHandler::attack(const int targetId, const bool keep) const createOutPacket(CMSG_HOMMERC_ATTACK); outMsg.writeInt32(id, "mercenary id"); outMsg.writeInt32(targetId, "target id"); - outMsg.writeInt8(static_cast(keep ? 1 : 0), "keep"); + outMsg.writeInt8(static_cast(keep == Keep_true ? 1 : 0), "keep"); } void MercenaryHandler::talk(const std::string &restrict text) const -- cgit v1.2.3-70-g09d2