/**
* Copyright (c) Lambda Innovation Team, 2013
* 版权许可:LambdaCraft 制作小组, 2013.
* http://lambdacraft.cn/
*
* The mod is open-source. It is distributed under the terms of the
* Lambda Innovation Open Source License. It grants rights to read, modify, compile
* or run the code. It does *NOT* grant the right to redistribute this software
* or its modifications in any form, binary or source, except if expressively
* granted by the copyright holder.
*
* 本Mod是完全开源的,你允许参考、使用、引用其中的任何代码段,但不允许将其用于商业用途,在引用的时候,必须注明原作者。
*/
package cn.dawn47.core.item;
import java.util.List;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.util.StatCollector;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
/**
* @author WeAthFolD
*
*/
public class DWAmmo extends DWGenericItem {
/**
* @param par1
*/
public DWAmmo() {
super();
}
@Override
@SideOnly(Side.CLIENT)
/**
* allows items to add custom lines of information to the mouseover description
*/
public void addInformation(ItemStack par1ItemStack,
EntityPlayer par2EntityPlayer, List par3List, boolean par4) {
if(this.getMaxDamage() > 1)
par3List.add(StatCollector.translateToLocal("dw.ammocap.name")
+ " : "
+ (par1ItemStack.getMaxDamage() - 1 - par1ItemStack
.getItemDamage()) + "/"
+ (par1ItemStack.getMaxDamage() - 1));
}
}