aboutsummaryrefslogtreecommitdiff
path: root/src/mapblock_mesh.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mapblock_mesh.cpp')
-rw-r--r--src/mapblock_mesh.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/mapblock_mesh.cpp b/src/mapblock_mesh.cpp
index 7ee49986f..5a29fbe94 100644
--- a/src/mapblock_mesh.cpp
+++ b/src/mapblock_mesh.cpp
@@ -427,7 +427,8 @@ void getTileInfo(
// This is hackish
content_t content0 = getNodeContent(p, n0, temp_mods);
content_t content1 = getNodeContent(p + face_dir, n1, temp_mods);
- u8 mf = face_contents(content0, content1);
+ bool equivalent = false;
+ u8 mf = face_contents(content0, content1, &equivalent);
if(mf == 0)
{
@@ -450,6 +451,10 @@ void getTileInfo(
face_dir_corrected = -face_dir;
}
+ // eg. water and glass
+ if(equivalent)
+ tile.material_flags |= MATERIAL_FLAG_BACKFACE_CULLING;
+
if(smooth_lighting == false)
{
lights[0] = lights[1] = lights[2] = lights[3] =