diff options
| author | OnyxDarkKnight <sor1n.iliutza16@gmail.com> | 2013-12-16 16:34:17 +0200 |
|---|---|---|
| committer | OnyxDarkKnight <sor1n.iliutza16@gmail.com> | 2013-12-16 16:34:17 +0200 |
| commit | 26d28c9b93133a6cfc5d2544c662e9d77955b6f5 (patch) | |
| tree | ba4a4cb9829a14db82e67af26e2e21fc59571ead /common/darkknight/jewelrycraft/item/ItemMolds.java | |
| parent | 1f718427162fa59a22c08a32e68e133fb411aa37 (diff) | |
Rings and molder
Diffstat (limited to 'common/darkknight/jewelrycraft/item/ItemMolds.java')
| -rw-r--r-- | common/darkknight/jewelrycraft/item/ItemMolds.java | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/common/darkknight/jewelrycraft/item/ItemMolds.java b/common/darkknight/jewelrycraft/item/ItemMolds.java index 9beb03a..090d53a 100644 --- a/common/darkknight/jewelrycraft/item/ItemMolds.java +++ b/common/darkknight/jewelrycraft/item/ItemMolds.java @@ -14,7 +14,7 @@ import net.minecraft.util.MathHelper; public class ItemMolds extends Item { /** List of molds color names */ - public static final String[] moldsItemNames = new String[] {"ingot", "ring", "necklace"}; + public static final String[] moldsItemNames = new String[] {"ingot", "ring"}; @SideOnly(Side.CLIENT) private Icon[] moldsIcons; @@ -24,7 +24,6 @@ public class ItemMolds extends Item this.setHasSubtypes(true); this.setMaxDamage(0); this.setMaxStackSize(1); - this.setCreativeTab(CreativeTabs.tabMaterials); } @SideOnly(Side.CLIENT) @@ -34,7 +33,7 @@ public class ItemMolds extends Item */ public Icon getIconFromDamage(int par1) { - int j = MathHelper.clamp_int(par1, 0, 2); + int j = MathHelper.clamp_int(par1, 0, moldsItemNames.length - 1); return this.moldsIcons[j]; } @@ -44,7 +43,7 @@ public class ItemMolds extends Item */ public String getUnlocalizedName(ItemStack par1ItemStack) { - int i = MathHelper.clamp_int(par1ItemStack.getItemDamage(), 0, 2); + int i = MathHelper.clamp_int(par1ItemStack.getItemDamage(), 0, moldsItemNames.length - 1); return super.getUnlocalizedName() + "." + moldsItemNames[i]; } @@ -56,7 +55,7 @@ public class ItemMolds extends Item */ public void getSubItems(int par1, CreativeTabs par2CreativeTabs, List par3List) { - for (int j = 0; j < 3; ++j) + for (int j = 0; j < moldsItemNames.length; ++j) { par3List.add(new ItemStack(par1, 1, j)); } |
