Java Code Examples for net.minecraft.client.renderer.RenderBlocks#clearOverrideBlockTexture()
The following examples show how to use
net.minecraft.client.renderer.RenderBlocks#clearOverrideBlockTexture() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: BlockExtendedNodeJarRenderer.java From Gadomancy with GNU Lesser General Public License v3.0 | 6 votes |
@Override public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) { int bb = setBrightness(world, x, y, z, block); int metadata = world.getBlockMetadata(x, y, z); block.setBlockBounds(W3, 0.0F, W3, W13, W12, W13); renderer.setRenderBoundsFromBlock(block); renderer.renderStandardBlock(block, x, y, z); block.setBlockBounds(W5, W12, W5, W11, W14, W11); renderer.setRenderBoundsFromBlock(block); renderer.renderStandardBlock(block, x, y, z); renderer.clearOverrideBlockTexture(); block.setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F); renderer.setRenderBoundsFromBlock(block); return true; }
Example 2
Source File: RenderCarvableBeacon.java From Chisel-2 with GNU General Public License v2.0 | 6 votes |
@Override public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) { float f = 0.1875F; renderer.setOverrideBlockTexture(renderer.getBlockIcon(Blocks.glass)); renderer.renderStandardBlockWithAmbientOcclusion(block, x, y, z, 1, 1, 1); renderer.renderAllFaces = true; renderer.setOverrideBlockTexture(renderer.getBlockIcon(Blocks.obsidian)); renderer.setRenderBounds(0.125D, 0.00625D, 0.125D, 0.875D, (double)f, 0.875D); renderer.renderStandardBlockWithAmbientOcclusion(block, x, y, z, 1, 1, 1); renderer.setOverrideBlockTexture(renderer.getBlockIcon(Blocks.beacon)); renderer.setRenderBounds(0.1875D, (double)f, 0.1875D, 0.8125D, 0.875D, 0.8125D); renderer.renderStandardBlockWithAmbientOcclusion(block, x, y, z, 1, 1, 1); renderer.renderAllFaces = false; renderer.clearOverrideBlockTexture(); return true; }
Example 3
Source File: RendererSimpleLayered.java From Chisel-2 with GNU General Public License v2.0 | 5 votes |
@Override public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) { renderer.setOverrideBlockTexture(((BlockCarvableLayered) block).getBaseTex()); renderer.renderStandardBlock(block, x, y, z); renderer.clearOverrideBlockTexture(); renderer.renderStandardBlock(block, x, y, z); return true; }
Example 4
Source File: BlockPIMRenderer.java From OpenPeripheral-Addons with MIT License | 5 votes |
@Override public void renderInventoryBlock(BlockPIM block, int metadata, int modelID, RenderBlocks renderer) { RenderUtils.renderInventoryBlock(renderer, block, 0); renderer.setOverrideBlockTexture(BlockPIM.Icons.black); setTopPartBounds(renderer, false); RenderUtils.renderInventoryBlockNoBounds(renderer, block, 0); renderer.clearOverrideBlockTexture(); }
Example 5
Source File: BlockPIMRenderer.java From OpenPeripheral-Addons with MIT License | 5 votes |
@Override public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, BlockPIM block, int modelId, RenderBlocks renderer) { renderer.setRenderBoundsFromBlock(block); renderer.renderStandardBlock(block, x, y, z); final boolean isBreaking = renderer.hasOverrideBlockTexture(); if (!isBreaking) renderer.setOverrideBlockTexture(BlockPIM.Icons.black); final boolean hasPlayer = hasPlayer(world, x, y, z); setTopPartBounds(renderer, hasPlayer); renderer.renderStandardBlock(block, x, y, z); if (!isBreaking) renderer.clearOverrideBlockTexture(); return true; }