Don't register our own blocks, ...

...let FML do that.
This commit is contained in:
CovertJaguar 2013-04-17 03:38:14 -07:00
parent df09099ca6
commit c64809a300
3 changed files with 3 additions and 8 deletions

View file

@ -6,11 +6,8 @@ import buildcraft.core.utils.StringUtil;
public class ItemBlockBuildCraft extends ItemBlock {
protected String name;
public ItemBlockBuildCraft(int id, String name) {
public ItemBlockBuildCraft(int id) {
super(id);
this.name = name;
}
@Override
@ -22,5 +19,4 @@ public class ItemBlockBuildCraft extends ItemBlock {
public String getItemDisplayName(ItemStack itemstack) {
return StringUtil.localize(getUnlocalizedName(itemstack));
}
}

View file

@ -100,8 +100,7 @@ public class CoreProxy {
/* REGISTRATION */
public void registerBlock(Block block) {
Item.itemsList[block.blockID] = null;
Item.itemsList[block.blockID] = new ItemBlockBuildCraft(block.blockID - 256, block.getUnlocalizedName());
GameRegistry.registerBlock(block, ItemBlockBuildCraft.class, block.getUnlocalizedName());
}
@SuppressWarnings({ "rawtypes", "unchecked" })

View file

@ -15,7 +15,7 @@ import buildcraft.core.ItemBlockBuildCraft;
public class ItemEngine extends ItemBlockBuildCraft {
public ItemEngine(int i) {
super(i, "engine");
super(i);
setMaxDamage(0);
setHasSubtypes(true);
}