mirror of
https://github.com/Jozufozu/Flywheel.git
synced 2025-01-05 20:06:19 +01:00
Fix liquid tank contents not being rendered (#588)
This commit is contained in:
parent
13cc4324ca
commit
0cc6fe1de7
2 changed files with 15 additions and 1 deletions
|
@ -68,4 +68,9 @@ public class FluidTankRenderer extends SafeTileEntityRenderer<FluidTankTileEntit
|
||||||
ms.pop();
|
ms.pop();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isGlobalRenderer(FluidTankTileEntity te) {
|
||||||
|
return te.isController();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -284,7 +284,16 @@ public class FluidTankTileEntity extends SmartTileEntity {
|
||||||
@Override
|
@Override
|
||||||
@OnlyIn(Dist.CLIENT)
|
@OnlyIn(Dist.CLIENT)
|
||||||
public AxisAlignedBB getRenderBoundingBox() {
|
public AxisAlignedBB getRenderBoundingBox() {
|
||||||
return super.getRenderBoundingBox().expand(width - 1, height - 1, width - 1);
|
if (isController())
|
||||||
|
return super.getRenderBoundingBox().expand(width - 1, height - 1, width - 1);
|
||||||
|
return super.getRenderBoundingBox();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@OnlyIn(Dist.CLIENT)
|
||||||
|
public double getMaxRenderDistanceSquared() {
|
||||||
|
int dist = 64 + getMaxHeight() * 2;
|
||||||
|
return dist * dist;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
|
|
Loading…
Reference in a new issue