summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/net/eathena/npchandler.cpp2
-rw-r--r--src/progs/manaplus/actions/actions.cpp6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/net/eathena/npchandler.cpp b/src/net/eathena/npchandler.cpp
index c7783f363..7ec80433a 100644
--- a/src/net/eathena/npchandler.cpp
+++ b/src/net/eathena/npchandler.cpp
@@ -370,7 +370,7 @@ void NpcHandler::requestAirship(const std::string &mapName,
return;
createOutPacket(CMSG_PRIVATE_AIRSHIP_REQUEST);
outMsg.writeString(mapName, 16, "map name");
- outMsg.writeInt16(itemId, "item");
+ outMsg.writeInt16(CAST_S16(itemId), "item");
}
} // namespace EAthena
diff --git a/src/progs/manaplus/actions/actions.cpp b/src/progs/manaplus/actions/actions.cpp
index 83068a61c..28c901ab7 100644
--- a/src/progs/manaplus/actions/actions.cpp
+++ b/src/progs/manaplus/actions/actions.cpp
@@ -1695,7 +1695,7 @@ impHandler(useItem)
StringVect pars;
if (!splitParameters(pars, event.args, " ,", '\"'))
return false;
- const int sz = pars.size();
+ const int sz = CAST_S32(pars.size());
if (sz < 1)
return false;
@@ -1711,13 +1711,13 @@ impHandler(useItem)
StringVect pars2;
if (!splitParameters(pars2, pars[0], " ,", '\"'))
return false;
- const int sz2 = pars2.size();
+ const int sz2 = CAST_S32(pars2.size());
if (sz2 < 1)
return false;
if (sz2 >= 2)
color = fromInt(atoi(pars2[1].c_str()), ItemColor);
if (sz >= 2)
- useType = atoi(pars[1].c_str());
+ useType = CAST_S16(atoi(pars[1].c_str()));
const Item *const item = inv->findItem(itemId,
color);
logger->log("test: %d,%d, %d", itemId, CAST_S32(color), CAST_S32(useType));