Implement LCERenewed Changes

This commit is contained in:
piebot
2026-03-26 14:14:42 +03:00
parent 0e56730255
commit cf0472117c
15 changed files with 96 additions and 33 deletions
+13
View File
@@ -17,6 +17,19 @@ bool HalfTransparentTile::isSolidRender(bool isServerLevel)
bool HalfTransparentTile::shouldRenderFace(LevelSource *level, int x, int y, int z, int face)
{
int id = level->getTile(x, y, z);
if (this->id == 95) // Tile::stained_glass
{
bool isBlocking = level->isTopSolidBlocking(x, y, z);
if (face == 0 && level->isSolidBlockingTile(x, y + 1, z) != isBlocking) return true; // Facing::DOWN
else if (face == 1 && level->isTopSolidBlocking(x, y - 1, z) != isBlocking) return true; // Facing::UP
else if (face == 2 && level->isSolidBlockingTile(x, y, z + 1) != isBlocking) return true; // Facing::NORTH
else if (face == 3 && level->isSolidBlockingTile(x, y, z - 1) != isBlocking) return true; // Facing::SOUTH
else if (face == 4 && level->isSolidBlockingTile(x + 1, y, z) != isBlocking) return true; // Facing::WEST
else if (face == 5 && level->isSolidBlockingTile(x - 1, y, z) != isBlocking) return true; // Facing::EAST
else if (face == 6 && level->isSolidBlockingTile(x, y, z) != isBlocking) return true; // not really a direction? is this supposed to be here?
}
if (!allowSame && id == this->id) return false;
return Tile::shouldRenderFace(level, x, y, z, face);
}