From cc775f2b71bd055d32c2a03e9aa42edc1842a503 Mon Sep 17 00:00:00 2001 From: OnyxDarkKnight Date: Mon, 16 Dec 2013 16:48:38 +0200 Subject: trying to make the rings work --- common/darkknight/jewelrycraft/block/BlockMolder.java | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'common') diff --git a/common/darkknight/jewelrycraft/block/BlockMolder.java b/common/darkknight/jewelrycraft/block/BlockMolder.java index f948e39..f694d10 100644 --- a/common/darkknight/jewelrycraft/block/BlockMolder.java +++ b/common/darkknight/jewelrycraft/block/BlockMolder.java @@ -2,6 +2,7 @@ package darkknight.jewelrycraft.block; import java.util.Random; +import darkknight.jewelrycraft.config.ConfigHandler; import darkknight.jewelrycraft.item.ItemList; import darkknight.jewelrycraft.item.ItemRing; import darkknight.jewelrycraft.tileentity.TileEntityMolder; @@ -103,6 +104,11 @@ public class BlockMolder extends BlockContainer { onBlockDestroyedByPlayer(world, i, j, k, 0); } + + public void giveJewelToPlayer(TileEntityMolder md, EntityPlayer player, ItemStack item, ItemStack metal) + { + player.inventory.addItemStackToInventory(item); + } public void onBlockClicked(World world, int i, int j, int k, EntityPlayer player) { @@ -114,15 +120,6 @@ public class BlockMolder extends BlockContainer me.hasJewelBase = false; } } - - public void giveJewelToPlayer(TileEntityMolder md, EntityPlayer player, ItemStack item, ItemStack metal) - { - if(item.getItem() == ItemList.ring){ - ItemRing ring = new ItemRing(item.itemID, metal); - player.inventory.addItemStackToInventory(new ItemStack(ring)); - } - else player.inventory.addItemStackToInventory(item); - } public boolean shouldSideBeRendered(IBlockAccess iblockaccess, int i, int j, int k, int l) { -- cgit v1.2.3