Merge pull request #196 from CovertJaguar/patch-11
Updated Pipe TESR render dist check
This commit is contained in:
commit
7af23a7af3
2 changed files with 5 additions and 5 deletions
|
@ -615,4 +615,9 @@ public class TileGenericPipe extends TileEntity implements IPowerReceptor, ITank
|
||||||
}
|
}
|
||||||
worldObj.markBlockAsNeedsUpdate(xCoord, yCoord, zCoord);
|
worldObj.markBlockAsNeedsUpdate(xCoord, yCoord, zCoord);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public double getRenderDistance() {
|
||||||
|
return 24;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,8 +53,6 @@ public class RenderPipe extends TileEntitySpecialRenderer {
|
||||||
|
|
||||||
final static private int displayLiquidStages = 40;
|
final static private int displayLiquidStages = 40;
|
||||||
|
|
||||||
final static private int renderDistanceSq = 24 * 24;
|
|
||||||
|
|
||||||
final static private int numItemsToRender = 10;
|
final static private int numItemsToRender = 10;
|
||||||
|
|
||||||
private final static EntityItem dummyEntityItem = new EntityItem(null);
|
private final static EntityItem dummyEntityItem = new EntityItem(null);
|
||||||
|
@ -234,9 +232,6 @@ public class RenderPipe extends TileEntitySpecialRenderer {
|
||||||
if (BuildCraftCore.render == RenderMode.NoDynamic)
|
if (BuildCraftCore.render == RenderMode.NoDynamic)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if(tileentity.getDistanceFrom(tileEntityRenderer.playerX, tileEntityRenderer.playerY, tileEntityRenderer.playerZ) >= renderDistanceSq)
|
|
||||||
return;
|
|
||||||
|
|
||||||
initializeDisplayPowerList(tileentity.worldObj);
|
initializeDisplayPowerList(tileentity.worldObj);
|
||||||
|
|
||||||
TileGenericPipe pipe = ((TileGenericPipe) tileentity);
|
TileGenericPipe pipe = ((TileGenericPipe) tileentity);
|
||||||
|
|
Loading…
Reference in a new issue