summaryrefslogtreecommitdiffstats
path: root/src/Entities
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-02-03 07:02:25 +0100
committerMattes D <github@xoft.cz>2014-02-03 07:02:25 +0100
commitb090547c17e919509a85c5810ba7795062987dae (patch)
tree4f73807d49f697e087b98ffb46ba1453345129a0 /src/Entities
parentFixed multiple invalid permission nodes (diff)
parentAdded IsBlockWaterOrIce() (diff)
downloadcuberite-b090547c17e919509a85c5810ba7795062987dae.tar
cuberite-b090547c17e919509a85c5810ba7795062987dae.tar.gz
cuberite-b090547c17e919509a85c5810ba7795062987dae.tar.bz2
cuberite-b090547c17e919509a85c5810ba7795062987dae.tar.lz
cuberite-b090547c17e919509a85c5810ba7795062987dae.tar.xz
cuberite-b090547c17e919509a85c5810ba7795062987dae.tar.zst
cuberite-b090547c17e919509a85c5810ba7795062987dae.zip
Diffstat (limited to 'src/Entities')
-rw-r--r--src/Entities/Entity.cpp3
-rw-r--r--src/Entities/Player.cpp4
2 files changed, 4 insertions, 3 deletions
diff --git a/src/Entities/Entity.cpp b/src/Entities/Entity.cpp
index e22f689d9..08780ca8b 100644
--- a/src/Entities/Entity.cpp
+++ b/src/Entities/Entity.cpp
@@ -397,6 +397,7 @@ int cEntity::GetArmorCoverAgainst(const cEntity * a_Attacker, eDamageType a_Dama
case dtPotionOfHarming:
case dtFalling:
case dtLightning:
+ case dtPlugin:
{
return 0;
}
@@ -473,7 +474,7 @@ void cEntity::KilledBy(cEntity * a_Killer)
return;
}
- // Drop loot:
+ // Drop loot:
cItems Drops;
GetDrops(Drops, a_Killer);
m_World->SpawnItemPickups(Drops, GetPosX(), GetPosY(), GetPosZ());
diff --git a/src/Entities/Player.cpp b/src/Entities/Player.cpp
index 8c37fdc8d..bde623f1b 100644
--- a/src/Entities/Player.cpp
+++ b/src/Entities/Player.cpp
@@ -786,11 +786,11 @@ void cPlayer::SetFlying(bool a_IsFlying)
void cPlayer::DoTakeDamage(TakeDamageInfo & a_TDI)
{
- if (a_TDI.DamageType != dtInVoid)
+ if ((a_TDI.DamageType != dtInVoid) && (a_TDI.DamageType != dtPlugin))
{
if (IsGameModeCreative())
{
- // No damage / health in creative mode if not void damage
+ // No damage / health in creative mode if not void or plugin damage
return;
}
}