Fix item and block localization. This is a world breaking change!

This commit is contained in:
CovertJaguar committed 2014-08-18 05:20:29 -07:00
1 parent 5fcc76a2fa
commit 83789ae8f7
78 files changed
+1119 -1120

No files matched your search

@@ -18,10 +18,10 @@ import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import forestry.core.gadgets.IStructureBlockItem;
import forestry.core.utils.StringUtil;
import forestry.farming.gadgets.TileFarm.EnumFarmBlock;
public class ItemFarmBlock extends ItemBlock implements IStructureBlockItem {
public ItemFarmBlock(Block block) {
super(block);
setHasSubtypes(true);
@@ -32,7 +32,7 @@ public class ItemFarmBlock extends ItemBlock implements IStructureBlockItem {
return i;
}
@SuppressWarnings({ "rawtypes", "unchecked" })
@SuppressWarnings({"rawtypes", "unchecked"})
@Override
public void addInformation(ItemStack itemstack, EntityPlayer player, List info, boolean par4) {
if (!itemstack.hasTagCompound())
@@ -41,13 +41,8 @@ public class ItemFarmBlock extends ItemBlock implements IStructureBlockItem {
info.add(EnumFarmBlock.getFromCompound(itemstack.getTagCompound()).getName());
}
@Override
public String getItemStackDisplayName(ItemStack itemstack) {
return StringUtil.localize(getUnlocalizedName(itemstack));
}
@Override
public String getUnlocalizedName(ItemStack itemstack) {
return "tile.ffarm." + itemstack.getItemDamage();
return super.getUnlocalizedName(itemstack) + "." + itemstack.getItemDamage();
}
}