aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorx2048 <codeforsmile@gmail.com>2022-09-04 22:17:04 +0200
committerSmallJoker <SmallJoker@users.noreply.github.com>2022-10-30 16:53:45 +0100
commit3e7ee499d6e68c39d499ae0f494fffe17cfa87af (patch)
treeb8b6fecf0139eb4fcdd31328cc3774b06971981a
parenta075d837524ab66cb3bd0cd1603ab00e29e205f6 (diff)
downloadminetest-3e7ee499d6e68c39d499ae0f494fffe17cfa87af.tar.xz
Always add increment when getting node interior light
-rw-r--r--src/client/mapblock_mesh.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/client/mapblock_mesh.cpp b/src/client/mapblock_mesh.cpp
index 519932cd4..9e141e290 100644
--- a/src/client/mapblock_mesh.cpp
+++ b/src/client/mapblock_mesh.cpp
@@ -103,8 +103,7 @@ static u8 getInteriorLight(enum LightBank bank, MapNode n, s32 increment,
const NodeDefManager *ndef)
{
u8 light = n.getLight(bank, ndef->getLightingFlags(n));
- if (light > 0)
- light = rangelim(light + increment, 0, LIGHT_SUN);
+ light = rangelim(light + increment, 0, LIGHT_SUN);
return decode_light(light);
}