summaryrefslogtreecommitdiffstats
path: root/src/MobProximityCounter.cpp
diff options
context:
space:
mode:
authorSamuel Barney <samjbarney@gmail.com>2015-07-29 17:04:03 +0200
committerSamuel Barney <samjbarney@gmail.com>2015-07-29 17:49:30 +0200
commit804805d35a87c2acc9425d1762ad26b1ba2ec9ac (patch)
tree13b603c8bbf8177da92ce87f5413fb646d204f3f /src/MobProximityCounter.cpp
parentMerge pull request #2376 from mjhanninen/fix-freebsd-build (diff)
downloadcuberite-804805d35a87c2acc9425d1762ad26b1ba2ec9ac.tar
cuberite-804805d35a87c2acc9425d1762ad26b1ba2ec9ac.tar.gz
cuberite-804805d35a87c2acc9425d1762ad26b1ba2ec9ac.tar.bz2
cuberite-804805d35a87c2acc9425d1762ad26b1ba2ec9ac.tar.lz
cuberite-804805d35a87c2acc9425d1762ad26b1ba2ec9ac.tar.xz
cuberite-804805d35a87c2acc9425d1762ad26b1ba2ec9ac.tar.zst
cuberite-804805d35a87c2acc9425d1762ad26b1ba2ec9ac.zip
Diffstat (limited to '')
-rw-r--r--src/MobProximityCounter.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/MobProximityCounter.cpp b/src/MobProximityCounter.cpp
index 1bdac2f88..47d585954 100644
--- a/src/MobProximityCounter.cpp
+++ b/src/MobProximityCounter.cpp
@@ -63,7 +63,7 @@ cMobProximityCounter::sIterablePair cMobProximityCounter::getMobWithinThosesDist
{
if (toReturn.m_Begin == m_DistanceToMonster.end())
{
- if ((a_DistanceMin == 1) || (itr->first > a_DistanceMin))
+ if ((a_DistanceMin == 1.0) || (itr->first > a_DistanceMin))
{
toReturn.m_Begin = itr; // This is the first one with distance > a_DistanceMin;
}
@@ -71,7 +71,7 @@ cMobProximityCounter::sIterablePair cMobProximityCounter::getMobWithinThosesDist
if (toReturn.m_Begin != m_DistanceToMonster.end())
{
- if ((a_DistanceMax != 1) && (itr->first > a_DistanceMax))
+ if ((a_DistanceMax != 1.0) && (itr->first > a_DistanceMax))
{
toReturn.m_End = itr; // This is just after the last one with distance < a_DistanceMax
// Note : if we are not going through this, it's ok, toReturn.m_End will be end();