From be29b7d452581ebe9d359ec4ff716f76bddc384b Mon Sep 17 00:00:00 2001 From: Progwml6 Date: Thu, 27 Feb 2014 15:15:37 -0500 Subject: [PATCH] add textureDomain code to mantle's inventory block instead of hardcoding to tinker --- src/mantle/blocks/abstracts/InventoryBlock.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/mantle/blocks/abstracts/InventoryBlock.java b/src/mantle/blocks/abstracts/InventoryBlock.java index a682821..1a967c9 100644 --- a/src/mantle/blocks/abstracts/InventoryBlock.java +++ b/src/mantle/blocks/abstracts/InventoryBlock.java @@ -182,6 +182,8 @@ public abstract class InventoryBlock extends BlockContainer public abstract String[] getTextureNames (); + public abstract String getTextureDomain (int textureNameIndex); + @Override public void registerBlockIcons (IIconRegister iconRegister) { @@ -190,15 +192,16 @@ public abstract class InventoryBlock extends BlockContainer for (int i = 0; i < this.icons.length; ++i) { - this.icons[i] = iconRegister.registerIcon("tinker:" + textureNames[i]); + this.icons[i] = iconRegister.registerIcon(getTextureDomain(i) + ":" + textureNames[i]); } } - + /* IDebuggable */ @Override public void onBlockClicked (World world, int x, int y, int z, EntityPlayer player) { - if (FMLCommonHandler.instance().getEffectiveSide() == Side.SERVER && player.getHeldItem().getItem() == Items.stick); + if (FMLCommonHandler.instance().getEffectiveSide() == Side.SERVER && player.getHeldItem().getItem() == Items.stick) + ; { TileEntity te = world.getTileEntity(x, y, z); if (te instanceof IDebuggable)