From 15424641cca695650f4b56c37711c12c81cf2c32 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 14 Nov 2015 17:25:37 +0300 Subject: Add cast action to beings. --- src/net/eathena/beingrecv.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/net') diff --git a/src/net/eathena/beingrecv.cpp b/src/net/eathena/beingrecv.cpp index f80b16c54..836fdfc37 100644 --- a/src/net/eathena/beingrecv.cpp +++ b/src/net/eathena/beingrecv.cpp @@ -758,8 +758,6 @@ void BeingRecv::processMapType(Net::MessageIn &msg) void BeingRecv::processSkillCasting(Net::MessageIn &msg) { - // +++ need use other parameters - const BeingId srcId = msg.readBeingId("src id"); const BeingId dstId = msg.readBeingId("dst id"); const int dstX = msg.readInt16("dst x"); @@ -781,11 +779,16 @@ void BeingRecv::processSkillCasting(Net::MessageIn &msg) { // being to being Being *const srcBeing = actorManager->findBeing(srcId); Being *const dstBeing = actorManager->findBeing(dstId); + if (srcBeing) + srcBeing->setAction(BeingAction::CAST, skillId); skillDialog->playCastingSrcEffect(skillId, srcBeing); skillDialog->playCastingDstEffect(skillId, dstBeing); } else if (dstX != 0 || dstY != 0) { // being to position + Being *const srcBeing = actorManager->findBeing(srcId); + if (srcBeing) + srcBeing->setAction(BeingAction::CAST, skillId); skillDialog->playCastingDstTileEffect(skillId, dstX, dstY, castTime); -- cgit v1.2.3-70-g09d2