1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-06 17:41:04 +00:00

Allow allfaces drawtypes to have 6 textures (#15175)

This commit is contained in:
DragonWrangler1 2024-09-26 08:34:16 -07:00 committed by GitHub
parent d08d34d803
commit 65ec371b78
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 30 additions and 8 deletions

View file

@ -1016,13 +1016,6 @@ void MapblockMeshGenerator::drawGlasslikeFramedNode()
}
}
void MapblockMeshGenerator::drawAllfacesNode()
{
static const aabb3f box(-BS / 2, -BS / 2, -BS / 2, BS / 2, BS / 2, BS / 2);
useTile(0, 0, 0);
drawAutoLightedCuboid(box);
}
void MapblockMeshGenerator::drawTorchlikeNode()
{
u8 wall = cur_node.n.getWallMounted(nodedef);
@ -1545,6 +1538,17 @@ namespace {
};
}
void MapblockMeshGenerator::drawAllfacesNode()
{
static const aabb3f box(-BS / 2, -BS / 2, -BS / 2, BS / 2, BS / 2, BS / 2);
TileSpec tiles[6];
for (int face = 0; face < 6; face++)
getTile(nodebox_tile_dirs[face], &tiles[face]);
if (data->m_smooth_lighting)
getSmoothLightFrame();
drawAutoLightedCuboid(box, nullptr, tiles, 6);
}
void MapblockMeshGenerator::drawNodeboxNode()
{
TileSpec tiles[6];