summaryrefslogtreecommitdiff
path: root/src/net/ea/beingrecv.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-03-22 18:59:41 +0300
committerAndrei Karas <akaras@inbox.ru>2016-03-22 18:59:41 +0300
commit1cf6cb343c6c8df8a998c617fd6f8d40f5affbea (patch)
treed5e090e99c02a0ce70d00c4dc527d777881cd83c /src/net/ea/beingrecv.cpp
parentf20c99d2bffe798806790e1f1ae838bba494d93c (diff)
downloadplus-1cf6cb343c6c8df8a998c617fd6f8d40f5affbea.tar.gz
plus-1cf6cb343c6c8df8a998c617fd6f8d40f5affbea.tar.bz2
plus-1cf6cb343c6c8df8a998c617fd6f8d40f5affbea.tar.xz
plus-1cf6cb343c6c8df8a998c617fd6f8d40f5affbea.zip
Add support for packet version in servers list xml and in editor.
Diffstat (limited to 'src/net/ea/beingrecv.cpp')
-rw-r--r--src/net/ea/beingrecv.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/net/ea/beingrecv.cpp b/src/net/ea/beingrecv.cpp
index 2a0351ef2..9796af9ce 100644
--- a/src/net/ea/beingrecv.cpp
+++ b/src/net/ea/beingrecv.cpp
@@ -286,14 +286,12 @@ void BeingRecv::processBeingEmotion(Net::MessageIn &msg)
return;
}
- if (player_relations.hasPermission(dstBeing, PlayerRelation::EMOTE))
+ const uint8_t emote = msg.readUInt8("emote");
+ if (emote &&
+ player_relations.hasPermission(dstBeing, PlayerRelation::EMOTE))
{
- const uint8_t emote = msg.readUInt8("emote");
- if (emote)
- {
- dstBeing->setEmote(emote, 0);
- localPlayer->imitateEmote(dstBeing, emote);
- }
+ dstBeing->setEmote(emote, 0);
+ localPlayer->imitateEmote(dstBeing, emote);
}
if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();