Fixed the addition of the "creative control circuit"
This commit is contained in:
parent
d9bb5845cd
commit
dde9b53447
2 changed files with 13 additions and 2 deletions
|
@ -27,6 +27,11 @@ public final class Tier
|
|||
return name;
|
||||
}
|
||||
|
||||
public boolean isObtainable()
|
||||
{
|
||||
return this != CREATIVE;
|
||||
}
|
||||
|
||||
private String name;
|
||||
|
||||
private BaseTier(String s)
|
||||
|
|
|
@ -25,10 +25,13 @@ public class ItemControlCircuit extends ItemMekanism
|
|||
public void registerIcons(IIconRegister register)
|
||||
{
|
||||
for(BaseTier tier : BaseTier.values())
|
||||
{
|
||||
if(tier.isObtainable())
|
||||
{
|
||||
icons[tier.ordinal()] = register.registerIcon("mekanism:" + tier.getName() + "ControlCircuit");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public IIcon getIconFromDamage(int meta)
|
||||
|
@ -40,10 +43,13 @@ public class ItemControlCircuit extends ItemMekanism
|
|||
public void getSubItems(Item item, CreativeTabs tabs, List itemList)
|
||||
{
|
||||
for(BaseTier tier : BaseTier.values())
|
||||
{
|
||||
if(tier.isObtainable())
|
||||
{
|
||||
itemList.add(new ItemStack(item, 1, tier.ordinal()));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getUnlocalizedName(ItemStack item)
|
||||
|
|
Loading…
Reference in a new issue