summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/being/actorsprite.cpp2
-rw-r--r--src/being/actorsprite.h2
-rw-r--r--src/being/being.cpp4
-rw-r--r--src/being/being.h4
-rw-r--r--src/net/eathena/skillrecv.cpp2
5 files changed, 8 insertions, 6 deletions
diff --git a/src/being/actorsprite.cpp b/src/being/actorsprite.cpp
index 63f224c3d..b9ab7a8d9 100644
--- a/src/being/actorsprite.cpp
+++ b/src/being/actorsprite.cpp
@@ -250,7 +250,7 @@ void ActorSprite::updateStatusEffect(const int index, const Enable newStatus)
else if (effect->isTrickDead())
setTrickDead(newStatus == Enable_true);
else if (effect->isPostDelay())
- setPostDelay(newStatus == Enable_true);
+ stopCast(newStatus == Enable_true);
#endif
handleStatusEffect(effect, index);
}
diff --git a/src/being/actorsprite.h b/src/being/actorsprite.h
index e648e6b66..836403c52 100644
--- a/src/being/actorsprite.h
+++ b/src/being/actorsprite.h
@@ -188,7 +188,7 @@ class ActorSprite notfinal : public CompoundSprite, public Actor
const std::set<int> &getStatusEffects() const A_WARN_UNUSED
{ return mStatusEffects; }
- virtual void setPostDelay(const bool b A_UNUSED)
+ virtual void stopCast(const bool b A_UNUSED)
{ }
protected:
diff --git a/src/being/being.cpp b/src/being/being.cpp
index 29c28c463..6aedf790e 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -2432,7 +2432,7 @@ void Being::updateColors()
void Being::updateSprite(const unsigned int slot,
const int id,
- std::string color,
+ const std::string &restrict color,
const ItemColor colorId,
const bool isWeapon,
const bool isTempSprite) restrict2
@@ -4349,7 +4349,7 @@ void Being::removeSpiritBalls(const unsigned int balls) restrict2
}
}
-void Being::setPostDelay(const bool b)
+void Being::stopCast(const bool b)
{
if (b && mAction == BeingAction::CAST)
setAction(BeingAction::STAND, 0);
diff --git a/src/being/being.h b/src/being/being.h
index 48e8b8c5e..6c1e09fa8 100644
--- a/src/being/being.h
+++ b/src/being/being.h
@@ -315,7 +315,7 @@ class Being notfinal : public ActorSprite,
void updateSprite(const unsigned int slot,
const int id,
- std::string color = "",
+ const std::string &restrict color = "",
const ItemColor colorId = ItemColor_one,
const bool isWeapon = false,
const bool isTempSprite = false) restrict2;
@@ -939,7 +939,7 @@ class Being notfinal : public ActorSprite,
unsigned int getSpiritBalls() const restrict2 noexcept A_WARN_UNUSED
{ return mSpiritBalls; }
- void setPostDelay(const bool b) override final;
+ void stopCast(const bool b) override final;
#endif
void setKarma(const int karma) restrict2 noexcept
diff --git a/src/net/eathena/skillrecv.cpp b/src/net/eathena/skillrecv.cpp
index d67620e4c..3301543cd 100644
--- a/src/net/eathena/skillrecv.cpp
+++ b/src/net/eathena/skillrecv.cpp
@@ -209,6 +209,8 @@ void SkillRecv::processSkillFailed(Net::MessageIn &msg)
logger->log("Action: %d/%d", bskill, success);
}
+ if (localPlayer)
+ localPlayer->stopCast(true);
std::string txt;
if (success == CAST_S32(SKILL_FAILED) && bskill != 0)
{