summaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-11-24 00:13:24 +0300
committerAndrei Karas <akaras@inbox.ru>2015-11-24 00:13:24 +0300
commita6c1e29279d28b18012e1a87d23ff114302bd610 (patch)
tree5d2767a184b26017b43f55de9144a77e9f26edab /src/net
parent59607172a197cbe622dabc4619100f69067403dd (diff)
downloadManaVerse-a6c1e29279d28b18012e1a87d23ff114302bd610.tar.gz
ManaVerse-a6c1e29279d28b18012e1a87d23ff114302bd610.tar.bz2
ManaVerse-a6c1e29279d28b18012e1a87d23ff114302bd610.tar.xz
ManaVerse-a6c1e29279d28b18012e1a87d23ff114302bd610.zip
Impliment packet SMSG_SPIRIT_BALLS.
Diffstat (limited to 'src/net')
-rw-r--r--src/net/eathena/beingrecv.cpp17
-rw-r--r--src/net/eathena/beingrecv.h1
-rw-r--r--src/net/eathena/packetsin.inc2
3 files changed, 6 insertions, 14 deletions
diff --git a/src/net/eathena/beingrecv.cpp b/src/net/eathena/beingrecv.cpp
index 56fc0fbf2..f536f1c15 100644
--- a/src/net/eathena/beingrecv.cpp
+++ b/src/net/eathena/beingrecv.cpp
@@ -1436,18 +1436,11 @@ void BeingRecv::processClassChange(Net::MessageIn &msg)
void BeingRecv::processSpiritBalls(Net::MessageIn &msg)
{
- UNIMPLIMENTEDPACKET;
-
- msg.readBeingId("being id");
- msg.readInt16("spirits amount");
-}
-
-void BeingRecv::processSpiritBallSingle(Net::MessageIn &msg)
-{
- UNIMPLIMENTEDPACKET;
-
- msg.readBeingId("being id");
- msg.readInt16("spirits amount");
+ Being *const dstBeing = actorManager->findBeing(
+ msg.readBeingId("being id"));
+ const int balls = msg.readInt16("spirits amount");
+ if (dstBeing)
+ dstBeing->setSpiritBalls(balls);
}
void BeingRecv::processBladeStop(Net::MessageIn &msg)
diff --git a/src/net/eathena/beingrecv.h b/src/net/eathena/beingrecv.h
index 0714f2114..08e2e4f40 100644
--- a/src/net/eathena/beingrecv.h
+++ b/src/net/eathena/beingrecv.h
@@ -91,7 +91,6 @@ namespace EAthena
void processMonsterInfo(Net::MessageIn &msg);
void processClassChange(Net::MessageIn &msg);
void processSpiritBalls(Net::MessageIn &msg);
- void processSpiritBallSingle(Net::MessageIn &msg);
void processBladeStop(Net::MessageIn &msg);
void processComboDelay(Net::MessageIn &msg);
void processWddingEffect(Net::MessageIn &msg);
diff --git a/src/net/eathena/packetsin.inc b/src/net/eathena/packetsin.inc
index 1e36f156b..b7618b3ae 100644
--- a/src/net/eathena/packetsin.inc
+++ b/src/net/eathena/packetsin.inc
@@ -404,7 +404,7 @@ packet(SMSG_SKILL_UNIT_UPDATE, 0x01ac, 6, &SkillRecv::processSkill
packet(SMSG_SKILL_WARP_POINT, 0x011c, 68, &SkillRecv::processSkillWarpPoint);
packet(SMSG_SOLVE_CHAR_NAME, 0x0194, 30, &BeingRecv::processSolveCharName);
packet(SMSG_SPIRIT_BALLS, 0x01d0, 8, &BeingRecv::processSpiritBalls);
-packet(SMSG_SPIRIT_BALL_SINGLE, 0x01e1, 8, &BeingRecv::processSpiritBallSingle);
+packet(SMSG_SPIRIT_BALL_SINGLE, 0x01e1, 8, &BeingRecv::processSpiritBalls);
packet(SMSG_STARS_KILL, 0x020e, 32, &BeingRecv::processStarsKill);
packet(SMSG_TAEKWON_RANKS_LIST, 0x0226, 282, &BeingRecv::processTaekwonRanksList);
packet(SMSG_TRADE_CANCEL, 0x00ee, 2, &Ea::TradeRecv::processTradeCancel);