Skip to content
Snippets Groups Projects
Commit bfaba2c1 authored by sapier's avatar sapier
Browse files

Fix regression in light calculation

parent 9afeb97f
No related branches found
No related tags found
No related merge requests found
......@@ -258,8 +258,8 @@ static u8 getSmoothLight(enum LightBank bank, v3s16 p, MeshMakeData *data)
{
MapNode n = data->m_vmanip.getNodeNoEx(p - dirs8[i]);
// if it's CONTENT_IGNORE we can't do any light calculations
if (n.getContent() == CONTENT_IGNORE) {
ambient_occlusion++;
continue;
}
......@@ -273,6 +273,9 @@ static u8 getSmoothLight(enum LightBank bank, v3s16 p, MeshMakeData *data)
light += decode_light(n.getLight(bank, ndef));
light_count++;
}
else {
ambient_occlusion++;
}
}
if(light_count == 0)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment