summaryrefslogtreecommitdiffstats
path: root/src/Entities/Pawn.cpp
diff options
context:
space:
mode:
authorLogicParrot <LogicParrot@users.noreply.github.com>2016-02-19 09:58:35 +0100
committerLogicParrot <LogicParrot@users.noreply.github.com>2016-02-19 09:58:35 +0100
commita776337e5ecc4ba9fe54a46069f3423fbad56ec4 (patch)
tree637e5302c5c5affc5f3c52d4c195cba5607aac30 /src/Entities/Pawn.cpp
parentMerge pull request #3020 from cuberite/ice_block (diff)
parentProper entity destruction in non-ticking chunks (diff)
downloadcuberite-a776337e5ecc4ba9fe54a46069f3423fbad56ec4.tar
cuberite-a776337e5ecc4ba9fe54a46069f3423fbad56ec4.tar.gz
cuberite-a776337e5ecc4ba9fe54a46069f3423fbad56ec4.tar.bz2
cuberite-a776337e5ecc4ba9fe54a46069f3423fbad56ec4.tar.lz
cuberite-a776337e5ecc4ba9fe54a46069f3423fbad56ec4.tar.xz
cuberite-a776337e5ecc4ba9fe54a46069f3423fbad56ec4.tar.zst
cuberite-a776337e5ecc4ba9fe54a46069f3423fbad56ec4.zip
Diffstat (limited to '')
-rw-r--r--src/Entities/Pawn.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Entities/Pawn.cpp b/src/Entities/Pawn.cpp
index c8780c326..3dea74851 100644
--- a/src/Entities/Pawn.cpp
+++ b/src/Entities/Pawn.cpp
@@ -221,7 +221,7 @@ void cPawn::ClearEntityEffects()
void cPawn::NoLongerTargetingMe(cMonster * a_Monster)
{
- ASSERT(!IsDestroyed()); // Our destroy override is supposed to clear all targets before we're destroyed.
+ ASSERT(IsTicking()); // Our destroy override is supposed to clear all targets before we're destroyed.
for (auto i = m_TargetingMe.begin(); i != m_TargetingMe.end(); ++i)
{
cMonster * Monster = *i;
@@ -241,7 +241,7 @@ void cPawn::NoLongerTargetingMe(cMonster * a_Monster)
void cPawn::TargetingMe(cMonster * a_Monster)
{
- ASSERT(!IsDestroyed());
+ ASSERT(IsTicking());
ASSERT(m_TargetingMe.size() < 10000);
ASSERT(a_Monster->GetTarget() == this);
m_TargetingMe.push_back(a_Monster);