summaryrefslogtreecommitdiff
path: root/src/mapgen_v5.cpp
diff options
context:
space:
mode:
authorkwolekr <kwolekr@minetest.net>2015-01-05 01:18:53 -0500
committerkwolekr <kwolekr@minetest.net>2015-01-05 01:20:36 -0500
commit7289d61e99625b46eb2c4d6b90a2a5de42f207e6 (patch)
tree1a383f05cda6a085e07734c308efed80c2d3b2e8 /src/mapgen_v5.cpp
parent00bca11f5988cfe7ce019c15c056ae258c254023 (diff)
downloadminetest-7289d61e99625b46eb2c4d6b90a2a5de42f207e6.tar.gz
minetest-7289d61e99625b46eb2c4d6b90a2a5de42f207e6.tar.bz2
minetest-7289d61e99625b46eb2c4d6b90a2a5de42f207e6.zip
Optionally specify propagateSunlight area in calcLighting
This fixes the Mapgen V5 calcLighting segfault
Diffstat (limited to 'src/mapgen_v5.cpp')
-rw-r--r--src/mapgen_v5.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mapgen_v5.cpp b/src/mapgen_v5.cpp
index 16fe4be5d..e220455bf 100644
--- a/src/mapgen_v5.cpp
+++ b/src/mapgen_v5.cpp
@@ -289,8 +289,10 @@ void MapgenV5::makeChunk(BlockMakeData *data)
updateLiquid(&data->transforming_liquid, full_node_min, full_node_max);
// Calculate lighting
- if (flags & MG_LIGHT)
- calcLighting(node_min - v3s16(0, 1, 0), node_max + v3s16(0, 1, 0));
+ if (flags & MG_LIGHT) {
+ calcLighting(node_min - v3s16(0, 1, 0), node_max + v3s16(0, 1, 0),
+ full_node_min, full_node_max);
+ }
this->generating = false;
}