Rename files to be more consistent. Add missing headers, tidy up Utils

This commit is contained in:
mezz committed 2015-09-25 15:09:54 -07:00
1 parent 37dd0efee2
commit 1e89bab556
576 files changed
+3811 -3923

No files matched your search

@@ -0,0 +1,49 @@
/*******************************************************************************
* Copyright (c) 2011-2014 SirSengir.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the GNU Lesser Public License v3
* which accompanies this distribution, and is available at
* http://www.gnu.org/licenses/lgpl-3.0.txt
*
* Various Contributors including, but not limited to:
* SirSengir (original work), CovertJaguar, Player, Binnie, MysteriousAges
******************************************************************************/
package forestry.farming.items;
import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import forestry.core.items.IStructureBlockItem;
import forestry.farming.render.EnumFarmBlockTexture;
public class ItemBlockFarm extends ItemBlock implements IStructureBlockItem {
public ItemBlockFarm(Block block) {
super(block);
setHasSubtypes(true);
}
@Override
public int getMetadata(int i) {
return i;
}
@SuppressWarnings({"rawtypes", "unchecked"})
@Override
public void addInformation(ItemStack itemstack, EntityPlayer player, List info, boolean par4) {
if (!itemstack.hasTagCompound()) {
return;
}
info.add(EnumFarmBlockTexture.getFromCompound(itemstack.getTagCompound()).getName());
}
@Override
public String getUnlocalizedName(ItemStack itemstack) {
return super.getUnlocalizedName(itemstack) + "." + itemstack.getItemDamage();
}
}