summaryrefslogtreecommitdiffstats
path: root/src/Entities/Pawn.cpp
diff options
context:
space:
mode:
authorarchshift <admin@archshift.com>2014-06-08 01:32:37 +0200
committerarchshift <admin@archshift.com>2014-06-17 20:39:20 +0200
commit2185c72c2ca2d66b238d7d3234c173bd820d32ac (patch)
tree134bcd0c391bac1624a9adab5e8f9d6425fb9942 /src/Entities/Pawn.cpp
parentImplemented milk, added documentation to Pawn.h (diff)
downloadcuberite-2185c72c2ca2d66b238d7d3234c173bd820d32ac.tar
cuberite-2185c72c2ca2d66b238d7d3234c173bd820d32ac.tar.gz
cuberite-2185c72c2ca2d66b238d7d3234c173bd820d32ac.tar.bz2
cuberite-2185c72c2ca2d66b238d7d3234c173bd820d32ac.tar.lz
cuberite-2185c72c2ca2d66b238d7d3234c173bd820d32ac.tar.xz
cuberite-2185c72c2ca2d66b238d7d3234c173bd820d32ac.tar.zst
cuberite-2185c72c2ca2d66b238d7d3234c173bd820d32ac.zip
Diffstat (limited to 'src/Entities/Pawn.cpp')
-rw-r--r--src/Entities/Pawn.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/Entities/Pawn.cpp b/src/Entities/Pawn.cpp
index 4c840e6e1..5cf270006 100644
--- a/src/Entities/Pawn.cpp
+++ b/src/Entities/Pawn.cpp
@@ -52,8 +52,22 @@ void cPawn::Tick(float a_Dt, cChunk & a_Chunk)
+void cPawn::KilledBy(cEntity *a_Killer)
+{
+ ClearEntityEffects();
+}
+
+
+
+
+
void cPawn::AddEntityEffect(cEntityEffect::eType a_EffectType, cEntityEffect a_Effect)
{
+ if (a_EffectType == cEntityEffect::efNoEffect)
+ {
+ return;
+ }
+
m_EntityEffects[a_EffectType] = a_Effect;
m_World->BroadcastEntityEffect(*this, a_EffectType, a_Effect.GetIntensity(), a_Effect.m_Ticks);
}