d4ff8e731d
Added Charged Quartz Spawn Chance. All GUI's Parts/Tiles support Custom Localization. ( Fixes #0190 ) Added Crafting Recipe for copying Press Plates. Fixed Bug: #0189 - Particles don't turn off when set to minimal Fixed Bug: #0176 - Weird Colorization While Mining Parts. Fixed Bug: #0152 - TPane drops parts as items and does not insert into system. Fixed Bug: #0140 - Spatial pylon facade renders oddly (Clear)
54 lines
1.6 KiB
Java
54 lines
1.6 KiB
Java
package appeng.client.render.blocks;
|
|
|
|
import net.minecraft.client.renderer.RenderBlocks;
|
|
import net.minecraft.client.renderer.Tessellator;
|
|
import net.minecraft.item.ItemStack;
|
|
import net.minecraft.world.IBlockAccess;
|
|
import net.minecraftforge.client.IItemRenderer.ItemRenderType;
|
|
import appeng.block.AEBaseBlock;
|
|
import appeng.client.render.BaseBlockRender;
|
|
import appeng.client.render.BusRenderer;
|
|
import appeng.tile.AEBaseTile;
|
|
import appeng.tile.networking.TileCableBus;
|
|
|
|
public class RendererCableBus extends BaseBlockRender
|
|
{
|
|
|
|
public RendererCableBus() {
|
|
super( true, 30 );
|
|
}
|
|
|
|
@Override
|
|
public void renderInventory(AEBaseBlock blk, ItemStack is, RenderBlocks renderer, ItemRenderType type, Object[] obj)
|
|
{
|
|
// nothin.
|
|
}
|
|
|
|
@Override
|
|
public boolean renderInWorld(AEBaseBlock block, IBlockAccess world, int x, int y, int z, RenderBlocks renderer)
|
|
{
|
|
AEBaseTile t = block.getTileEntity( world, x, y, z );
|
|
|
|
if ( t instanceof TileCableBus )
|
|
{
|
|
BusRenderer.instance.renderer.renderAllFaces = true;
|
|
BusRenderer.instance.renderer.blockAccess = renderer.blockAccess;
|
|
BusRenderer.instance.renderer.overrideBlockTexture = renderer.overrideBlockTexture;
|
|
((TileCableBus) t).cb.renderStatic( x, y, z );
|
|
BusRenderer.instance.renderer.renderAllFaces = false;
|
|
}
|
|
|
|
return true;
|
|
}
|
|
|
|
@Override
|
|
public void renderTile(AEBaseBlock block, AEBaseTile t, Tessellator tess, double x, double y, double z, float f, RenderBlocks renderer)
|
|
{
|
|
if ( t instanceof TileCableBus )
|
|
{
|
|
BusRenderer.instance.renderer.overrideBlockTexture = null;
|
|
((TileCableBus) t).cb.renderDynamic( x, y, z );
|
|
}
|
|
}
|
|
|
|
}
|