summaryrefslogtreecommitdiff
path: root/src/net/eathena/beingrecv.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-02-20 21:19:59 +0300
committerAndrei Karas <akaras@inbox.ru>2016-02-20 21:19:59 +0300
commita9f6959a96395edc64ff57bf5ba1d75cca8e86c3 (patch)
treef6975bea7e87380ee7d063ccfb2efbc835341c91 /src/net/eathena/beingrecv.cpp
parent3e8fecc9a62afff0054fa0fa23af86c8ef15a1c9 (diff)
downloadManaVerse-a9f6959a96395edc64ff57bf5ba1d75cca8e86c3.tar.gz
ManaVerse-a9f6959a96395edc64ff57bf5ba1d75cca8e86c3.tar.bz2
ManaVerse-a9f6959a96395edc64ff57bf5ba1d75cca8e86c3.tar.xz
ManaVerse-a9f6959a96395edc64ff57bf5ba1d75cca8e86c3.zip
Add missing const in net directory.
Diffstat (limited to 'src/net/eathena/beingrecv.cpp')
-rw-r--r--src/net/eathena/beingrecv.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/net/eathena/beingrecv.cpp b/src/net/eathena/beingrecv.cpp
index 88db63c8f..c744fae34 100644
--- a/src/net/eathena/beingrecv.cpp
+++ b/src/net/eathena/beingrecv.cpp
@@ -107,7 +107,7 @@ void BeingRecv::processBeingChangeLookCards(Net::MessageIn &msg)
FOR_EACH (Net::Characters::iterator, it, chars)
{
- Net::Character *character = *it;
+ const Net::Character *const character = *it;
if (character->dummy && character->dummy->getId() == id)
{
dstBeing = character->dummy;
@@ -137,12 +137,12 @@ void BeingRecv::processBeingChangeLookCards(Net::MessageIn &msg)
processBeingChangeLookContinue(msg, dstBeing, type, id, id2, &cards[0]);
}
-void BeingRecv::processBeingChangeLookContinue(Net::MessageIn &msg,
+void BeingRecv::processBeingChangeLookContinue(const Net::MessageIn &msg,
Being *const dstBeing,
const uint8_t type,
const int id,
const int id2,
- const int *cards)
+ const int *const cards)
{
if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();
@@ -342,7 +342,7 @@ void BeingRecv::processBeingVisible(Net::MessageIn &msg)
dstBeing->setStatusEffectBlock(32, CAST_U16(
msg.readInt32("opt3")));
dstBeing->setKarma(msg.readUInt8("karma"));
- uint8_t gender = CAST_U8(msg.readUInt8("gender") & 3);
+ const uint8_t gender = CAST_U8(msg.readUInt8("gender") & 3);
if (dstBeing->getType() == ActorType::Player)
{
@@ -508,7 +508,7 @@ void BeingRecv::processBeingMove(Net::MessageIn &msg)
dstBeing->setStatusEffectBlock(32, CAST_U16(
msg.readInt32("opt3")));
dstBeing->setKarma(msg.readUInt8("karma"));
- uint8_t gender = CAST_U8(msg.readUInt8("gender") & 3);
+ const uint8_t gender = CAST_U8(msg.readUInt8("gender") & 3);
if (dstBeing->getType() == ActorType::Player)
{
@@ -679,7 +679,7 @@ void BeingRecv::processBeingSpawn(Net::MessageIn &msg)
dstBeing->setStatusEffectBlock(32, CAST_U16(
msg.readInt32("opt3")));
dstBeing->setKarma(msg.readUInt8("karma"));
- uint8_t gender = CAST_U8(msg.readUInt8("gender") & 3);
+ const uint8_t gender = CAST_U8(msg.readUInt8("gender") & 3);
if (dstBeing->getType() == ActorType::Player)
{
@@ -756,7 +756,7 @@ void BeingRecv::processMapTypeProperty(Net::MessageIn &msg)
// +++ need get other flags from here
MapTypeProperty2 props;
props.data = CAST_U32(flags);
- Game *const game = Game::instance();
+ const Game *const game = Game::instance();
if (!game)
return;
Map *const map = game->getCurrentMap();
@@ -1230,7 +1230,7 @@ void BeingRecv::processPlaterStatusChange2(Net::MessageIn &msg)
if (!dstBeing)
return;
- uint32_t statusEffects = msg.readInt32("status effect");
+ const uint32_t statusEffects = msg.readInt32("status effect");
dstBeing->setLevel(msg.readInt32("level"));
msg.readInt32("showEFST");
@@ -1715,7 +1715,7 @@ Being *BeingRecv::createBeing2(Net::MessageIn &msg,
id, type, fromInt(job, BeingTypeId));
if (beingType == BeingType::MERSOL)
{
- MercenaryInfo *const info = PlayerInfo::getMercenary();
+ const MercenaryInfo *const info = PlayerInfo::getMercenary();
if (info && info->id == id)
PlayerInfo::setMercenaryBeing(being);
}