summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2013-12-08 18:07:49 +0100
committerMattes D <github@xoft.cz>2013-12-08 18:07:49 +0100
commitac6b4cda7c4fafa47a7711317b22ead8f96c1f61 (patch)
tree189d19a7e83307f0bcf2fa54037cb2c9eb01094c /src
parentMerge pull request #404 from mc-server/fixesnfeatures (diff)
parentNow spawn points will not be in deep oceans or rivers etc. (diff)
downloadcuberite-ac6b4cda7c4fafa47a7711317b22ead8f96c1f61.tar
cuberite-ac6b4cda7c4fafa47a7711317b22ead8f96c1f61.tar.gz
cuberite-ac6b4cda7c4fafa47a7711317b22ead8f96c1f61.tar.bz2
cuberite-ac6b4cda7c4fafa47a7711317b22ead8f96c1f61.tar.lz
cuberite-ac6b4cda7c4fafa47a7711317b22ead8f96c1f61.tar.xz
cuberite-ac6b4cda7c4fafa47a7711317b22ead8f96c1f61.tar.zst
cuberite-ac6b4cda7c4fafa47a7711317b22ead8f96c1f61.zip
Diffstat (limited to '')
-rw-r--r--src/World.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/World.cpp b/src/World.cpp
index f6957f4cd..eecd02027 100644
--- a/src/World.cpp
+++ b/src/World.cpp
@@ -608,7 +608,7 @@ void cWorld::GenerateRandomSpawn(void)
{
LOGD("Generating random spawnpoint...");
- while (GetBiomeAt((int)m_SpawnX, (int)m_SpawnZ) == biOcean) // Anything but ocean is fine
+ while (IsBlockWater(GetBlock((int)m_SpawnX, GetHeight((int)m_SpawnX, (int)m_SpawnZ), (int)m_SpawnZ)))
{
if ((GetTickRandomNumber(4) % 2) == 0) // Randomise whether to increment X or Z coords
{