summaryrefslogtreecommitdiffstats
path: root/src/World.cpp
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-12-10 22:35:16 +0100
committerMattes D <github@xoft.cz>2014-12-10 22:35:16 +0100
commitfcd3d1bfedbfbe535f406e3db933486bad913ab4 (patch)
tree24ad1b9b30473e686ded1e2a89a02ce04fb2cc91 /src/World.cpp
parentLighting thread: skip chunks that are already lit. (diff)
downloadcuberite-fcd3d1bfedbfbe535f406e3db933486bad913ab4.tar
cuberite-fcd3d1bfedbfbe535f406e3db933486bad913ab4.tar.gz
cuberite-fcd3d1bfedbfbe535f406e3db933486bad913ab4.tar.bz2
cuberite-fcd3d1bfedbfbe535f406e3db933486bad913ab4.tar.lz
cuberite-fcd3d1bfedbfbe535f406e3db933486bad913ab4.tar.xz
cuberite-fcd3d1bfedbfbe535f406e3db933486bad913ab4.tar.zst
cuberite-fcd3d1bfedbfbe535f406e3db933486bad913ab4.zip
Diffstat (limited to '')
-rw-r--r--src/World.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/World.cpp b/src/World.cpp
index e73dcb915..ff5a2cf35 100644
--- a/src/World.cpp
+++ b/src/World.cpp
@@ -115,7 +115,7 @@ public:
{
int chunkX, chunkZ;
DecodeChunkCoords(i, chunkX, chunkZ);
- m_World.GetLightingThread().QueueChunk(chunkX, chunkZ, this);
+ m_World.PrepareChunk(chunkX, chunkZ, this);
} // for i
// Wait for the lighting thread to prepare everything. Event is set in the Call() callback:
@@ -2907,6 +2907,15 @@ void cWorld::TouchChunk(int a_ChunkX, int a_ChunkZ)
+void cWorld::PrepareChunk(int a_ChunkX, int a_ChunkZ, cChunkCoordCallback * a_CallAfter)
+{
+ m_ChunkMap->PrepareChunk(a_ChunkX, a_ChunkZ, a_CallAfter);
+}
+
+
+
+
+
void cWorld::ChunkLoadFailed(int a_ChunkX, int a_ChunkZ)
{
m_ChunkMap->ChunkLoadFailed(a_ChunkX, a_ChunkZ);
@@ -3017,7 +3026,7 @@ void cWorld::RegenerateChunk(int a_ChunkX, int a_ChunkZ)
void cWorld::GenerateChunk(int a_ChunkX, int a_ChunkZ)
{
- m_ChunkMap->TouchChunk(a_ChunkX, a_ChunkZ);
+ m_ChunkMap->GenerateChunk(a_ChunkX, a_ChunkZ);
}