mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Fix water-glass and water-lava surfaces
This commit is contained in:
parent
fea55a9b87
commit
045e32b6ec
5 changed files with 91 additions and 45 deletions
|
@ -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] =
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue