fix extra lights-related work in world.set_chunk_data
This commit is contained in:
@@ -148,12 +148,12 @@ static void integrate_chunk_client(Chunk& chunk) {
|
||||
int x = chunk.x;
|
||||
int z = chunk.z;
|
||||
auto chunksController = controller->getChunksController();
|
||||
|
||||
Lighting& lighting = *chunksController->lighting;
|
||||
chunk.flags.loadedLights = false;
|
||||
chunk.flags.lighted = false;
|
||||
|
||||
chunk.lightmap.clear();
|
||||
Lighting::prebuildSkyLight(chunk, *indices);
|
||||
lighting.onChunkLoaded(x, z, true);
|
||||
|
||||
for (int lz = -1; lz <= 1; lz++) {
|
||||
for (int lx = -1; lx <= 1; lx++) {
|
||||
@@ -162,7 +162,6 @@ static void integrate_chunk_client(Chunk& chunk) {
|
||||
}
|
||||
if (auto other = level->chunks->getChunk(x + lx, z + lz)) {
|
||||
other->flags.modified = true;
|
||||
lighting.onChunkLoaded(x - 1, z, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user