fix missing textures errors
This commit is contained in:
parent
d8224f5edb
commit
29a3340aa2
5 changed files with 34 additions and 2 deletions
Binary file not shown.
After Width: | Height: | Size: 251 B |
Binary file not shown.
After Width: | Height: | Size: 1.8 KiB |
|
@ -10,6 +10,7 @@ package buildcraft.core;
|
|||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.util.IIcon;
|
||||
|
||||
import buildcraft.BuildCraftCore;
|
||||
|
@ -19,6 +20,10 @@ public class BlockBuildTool extends Block {
|
|||
super(Material.iron);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerBlockIcons(IIconRegister itemRegister) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public IIcon getIcon(int i, int j) {
|
||||
return BuildCraftCore.redLaserTexture;
|
||||
|
|
|
@ -10,6 +10,7 @@ package buildcraft.core.lib.engines;
|
|||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.IIcon;
|
||||
|
||||
import buildcraft.core.BCCreativeTab;
|
||||
import buildcraft.core.lib.items.ItemBlockBuildCraft;
|
||||
|
@ -34,4 +35,9 @@ public class ItemEngine extends ItemBlockBuildCraft {
|
|||
public String getUnlocalizedName(ItemStack itemstack) {
|
||||
return engineBlock.getUnlocalizedName(itemstack.getItemDamage());
|
||||
}
|
||||
|
||||
@Override
|
||||
public IIcon getIconIndex(ItemStack stack) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -33,7 +33,6 @@ public class RenderLaserTable implements ISimpleBlockRenderingHandler {
|
|||
renderAssemblyTable(renderer, true, 0, 0, 0, bcBlock);
|
||||
break;
|
||||
case 1:
|
||||
case 5:
|
||||
renderAdvancedCraftingTable(renderer, true, 0, 0, 0, bcBlock);
|
||||
break;
|
||||
case 2:
|
||||
|
@ -45,6 +44,9 @@ public class RenderLaserTable implements ISimpleBlockRenderingHandler {
|
|||
case 4:
|
||||
renderProgrammingTable(renderer, true, 0, 0, 0, bcBlock);
|
||||
break;
|
||||
case 5:
|
||||
renderStampingTable(renderer, true, 0, 0, 0, bcBlock);
|
||||
break;
|
||||
}
|
||||
GL11.glTranslatef(0.5F, 0.5F, 0.5F);
|
||||
}
|
||||
|
@ -57,7 +59,6 @@ public class RenderLaserTable implements ISimpleBlockRenderingHandler {
|
|||
renderAssemblyTable(renderer, false, x, y, z, bcBlock);
|
||||
break;
|
||||
case 1:
|
||||
case 5:
|
||||
renderAdvancedCraftingTable(renderer, false, x, y, z, bcBlock);
|
||||
break;
|
||||
case 2:
|
||||
|
@ -69,6 +70,9 @@ public class RenderLaserTable implements ISimpleBlockRenderingHandler {
|
|||
case 4:
|
||||
renderProgrammingTable(renderer, false, x, y, z, bcBlock);
|
||||
break;
|
||||
case 5:
|
||||
renderStampingTable(renderer, false, x, y, z, bcBlock);
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
@ -193,6 +197,23 @@ public class RenderLaserTable implements ISimpleBlockRenderingHandler {
|
|||
renderCube(renderer, isInv, x, y, z, 0, 0.1875F, 0, 16, 5, 16, 16, 0, base, 0x3f); // top
|
||||
}
|
||||
|
||||
private void renderStampingTable(RenderBlocks renderer, boolean isInv, int x, int y, int z, BlockBuildCraft block) {
|
||||
if (!isInv && block.getCurrentRenderPass() != 0) {
|
||||
workaround17(x, y, z);
|
||||
return;
|
||||
}
|
||||
IIcon base = block.getIcon(0, 5);
|
||||
renderCube(renderer, isInv, x, y, z, 0.125F, 0, 0.125F, 12, 3, 12, 12, 21, base, 0x3d); // bottom (no top)
|
||||
|
||||
// sides (no top)
|
||||
renderCube(renderer, isInv, x, y, z, 0, 0, 0, 3, 3, 3, 3, 0, base, 0x3d);
|
||||
renderCube(renderer, isInv, x, y, z, 0, 0, 0.8125F, 3, 3, 3, 3, 0, base, 0x3d);
|
||||
renderCube(renderer, isInv, x, y, z, 0.8125F, 0, 0, 3, 3, 3, 3, 0, base, 0x3d);
|
||||
renderCube(renderer, isInv, x, y, z, 0.8125F, 0, 0.8125F, 3, 3, 3, 3, 0, base, 0x3d);
|
||||
|
||||
renderCube(renderer, isInv, x, y, z, 0, 0.1875F, 0, 16, 5, 16, 16, 0, base, 0x3f); // top
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean shouldRender3DInInventory(int modelId) {
|
||||
return true;
|
||||
|
|
Loading…
Reference in a new issue