mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-26 23:13:09 +00:00
Global safety checks for blockstates while chunks are unloading
This commit is contained in:
1 parent
84204db587
commit
f3cce3d24e
54 files changed
+163
-114
No files matched your search
@@ -52,6 +52,10 @@ public class RenderTilePool extends TileEntitySpecialRenderer<TilePool> {
|
||||
|
||||
@Override
|
||||
public void renderTileEntityAt(TilePool pool, double d0, double d1, double d2, float f, int digProgress) {
|
||||
if (pool != null && pool.getWorld() != null && !pool.getWorld().isBlockLoaded(pool.getPos(), false)) {
|
||||
return;
|
||||
}
|
||||
|
||||
GlStateManager.pushMatrix();
|
||||
GlStateManager.enableBlend();
|
||||
GlStateManager.blendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
|
||||
@@ -92,6 +96,8 @@ public class RenderTilePool extends TileEntitySpecialRenderer<TilePool> {
|
||||
|
||||
tess.draw();
|
||||
|
||||
GlStateManager.enableLighting();
|
||||
|
||||
GlStateManager.translate(0.5F, 1.5F, 0.5F);
|
||||
GlStateManager.color(1, 1, 1, a);
|
||||
GlStateManager.enableRescaleNormal();
|
||||
|
||||
Reference in new issue
Block a user