summaryrefslogtreecommitdiffstats
path: root/src/Entities/Entity.cpp
diff options
context:
space:
mode:
authorworktycho <work.tycho@gmail.com>2014-09-23 09:15:22 +0200
committerworktycho <work.tycho@gmail.com>2014-09-23 09:15:22 +0200
commite3e7bc21f7c17e2905fd9dbec09a3c02371e51f8 (patch)
treed77d1df4b459af2363ebf2d3044981d15b78eb81 /src/Entities/Entity.cpp
parentUpdated README.md (diff)
parentA few compiler warning fixes (diff)
downloadcuberite-e3e7bc21f7c17e2905fd9dbec09a3c02371e51f8.tar
cuberite-e3e7bc21f7c17e2905fd9dbec09a3c02371e51f8.tar.gz
cuberite-e3e7bc21f7c17e2905fd9dbec09a3c02371e51f8.tar.bz2
cuberite-e3e7bc21f7c17e2905fd9dbec09a3c02371e51f8.tar.lz
cuberite-e3e7bc21f7c17e2905fd9dbec09a3c02371e51f8.tar.xz
cuberite-e3e7bc21f7c17e2905fd9dbec09a3c02371e51f8.tar.zst
cuberite-e3e7bc21f7c17e2905fd9dbec09a3c02371e51f8.zip
Diffstat (limited to 'src/Entities/Entity.cpp')
-rw-r--r--src/Entities/Entity.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Entities/Entity.cpp b/src/Entities/Entity.cpp
index c8ebc4314..8ef24828e 100644
--- a/src/Entities/Entity.cpp
+++ b/src/Entities/Entity.cpp
@@ -342,6 +342,7 @@ bool cEntity::DoTakeDamage(TakeDamageInfo & a_TDI)
a_TDI.FinalDamage += (int)ceil(2.5 * SmiteLevel);
break;
}
+ default: break;
}
}
}
@@ -1015,7 +1016,7 @@ void cEntity::HandlePhysics(float a_Dt, cChunk & a_Chunk)
if (Tracer.HitNormal.y != 0.f) NextSpeed.y = 0.f;
if (Tracer.HitNormal.z != 0.f) NextSpeed.z = 0.f;
- if (Tracer.HitNormal.y == 1) // Hit BLOCK_FACE_YP, we are on the ground
+ if (Tracer.HitNormal.y == 1.f) // Hit BLOCK_FACE_YP, we are on the ground
{
m_bOnGround = true;
}
@@ -1960,7 +1961,7 @@ void cEntity::SteerVehicle(float a_Forward, float a_Sideways)
{
return;
}
- if ((a_Forward != 0) || (a_Sideways != 0))
+ if ((a_Forward != 0.f) || (a_Sideways != 0.f))
{
m_AttachedTo->HandleSpeedFromAttachee(a_Forward, a_Sideways);
}