summaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
authorSamuel Barney <samjbarney@gmail.com>2013-10-26 11:50:34 +0200
committerSamuel Barney <samjbarney@gmail.com>2013-10-26 11:50:34 +0200
commit0b853dca93fdeca797825d4a0959cb3f3127dc04 (patch)
treec5fed6049a20062aa194bee1254091a551de3852 /source
parentChecked Endermen; they work; adding them back in. (diff)
downloadcuberite-0b853dca93fdeca797825d4a0959cb3f3127dc04.tar
cuberite-0b853dca93fdeca797825d4a0959cb3f3127dc04.tar.gz
cuberite-0b853dca93fdeca797825d4a0959cb3f3127dc04.tar.bz2
cuberite-0b853dca93fdeca797825d4a0959cb3f3127dc04.tar.lz
cuberite-0b853dca93fdeca797825d4a0959cb3f3127dc04.tar.xz
cuberite-0b853dca93fdeca797825d4a0959cb3f3127dc04.tar.zst
cuberite-0b853dca93fdeca797825d4a0959cb3f3127dc04.zip
Diffstat (limited to 'source')
-rw-r--r--source/Chunk.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/Chunk.cpp b/source/Chunk.cpp
index 35da4c266..0892020e2 100644
--- a/source/Chunk.cpp
+++ b/source/Chunk.cpp
@@ -549,7 +549,9 @@ void cChunk::SpawnMobs(cMobSpawner& a_MobSpawner)
{
int WorldX, WorldY, WorldZ;
PositionToWorldPosition(Try_X, Try_Y, Try_Z, WorldX, WorldY, WorldZ);
- newMob->SetPosition(WorldX, WorldY, WorldZ);
+ double ActualX = WorldX + 0.5;
+ double ActualZ = WorldZ + 0.5;
+ newMob->SetPosition(ActualX, WorldY, ActualZ);
LOGD("Spawning %s #%i at %d,%d,%d",newMob->GetClass(),newMob->GetUniqueID(),WorldX, WorldY, WorldZ);
NumberOfSuccess++;
}