Added lithiumbatpack
This commit is contained in:
parent
da6e88c254
commit
a46645ff42
6 changed files with 87 additions and 3 deletions
|
@ -5,11 +5,13 @@ import org.apache.logging.log4j.message.MapMessage.MapFormat;
|
|||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.Item.ToolMaterial;
|
||||
import net.minecraft.item.ItemArmor.ArmorMaterial;
|
||||
import net.minecraftforge.oredict.OreDictionary;
|
||||
import techreborn.items.ItemDusts;
|
||||
import techreborn.items.ItemGems;
|
||||
import techreborn.items.ItemIngots;
|
||||
import techreborn.items.ItemParts;
|
||||
import techreborn.items.tools.ItemLithiumBatpack;
|
||||
import techreborn.items.tools.ItemRockCutter;
|
||||
import techreborn.util.LogHelper;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
|
@ -21,6 +23,7 @@ public class ModItems {
|
|||
public static Item gems;
|
||||
public static Item parts;
|
||||
public static Item rockCutter;
|
||||
public static Item lithiumBatpack;
|
||||
|
||||
public static void init()
|
||||
{
|
||||
|
@ -34,6 +37,8 @@ public class ModItems {
|
|||
GameRegistry.registerItem(parts, "part");
|
||||
rockCutter = new ItemRockCutter(ToolMaterial.EMERALD);
|
||||
GameRegistry.registerItem(rockCutter, "rockCutter");
|
||||
lithiumBatpack = new ItemLithiumBatpack(ArmorMaterial.DIAMOND, 7, 1);
|
||||
GameRegistry.registerItem(lithiumBatpack, "lithiumBatpack");
|
||||
LogHelper.info("TechReborns Items Loaded");
|
||||
|
||||
registerOreDict();
|
||||
|
|
78
src/main/java/techreborn/items/tools/ItemLithiumBatpack.java
Normal file
78
src/main/java/techreborn/items/tools/ItemLithiumBatpack.java
Normal file
|
@ -0,0 +1,78 @@
|
|||
package techreborn.items.tools;
|
||||
|
||||
import ic2.api.item.IElectricItem;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemArmor;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import techreborn.client.TechRebornCreativeTab;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class ItemLithiumBatpack extends ItemArmor implements IElectricItem{
|
||||
|
||||
public int maxCharge = 60000000;
|
||||
public int tier = 3;
|
||||
public double transferLimit = 10000;
|
||||
public int energyPerDamage = 100;
|
||||
|
||||
public ItemLithiumBatpack(ArmorMaterial armorMaterial, int par3, int par4)
|
||||
{
|
||||
super(armorMaterial, par3, par4);
|
||||
setMaxStackSize(1);
|
||||
setUnlocalizedName("techreborn.lithiumbatpack");
|
||||
setCreativeTab(TechRebornCreativeTab.instance);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public void registerIcons(IIconRegister iconRegister)
|
||||
{
|
||||
this.itemIcon = iconRegister.registerIcon("techreborn:" + "lithiumbatpack");
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type)
|
||||
{
|
||||
return "techreborn:" + "textures/models/lithiumbatpack.png";
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canProvideEnergy(ItemStack itemStack)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Item getChargedItem(ItemStack itemStack)
|
||||
{
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Item getEmptyItem(ItemStack itemStack)
|
||||
{
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public double getMaxCharge(ItemStack itemStack)
|
||||
{
|
||||
return maxCharge;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getTier(ItemStack itemStack)
|
||||
{
|
||||
return tier;
|
||||
}
|
||||
|
||||
@Override
|
||||
public double getTransferLimit(ItemStack itemStack)
|
||||
{
|
||||
return transferLimit;
|
||||
}
|
||||
|
||||
}
|
|
@ -16,9 +16,8 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
|
||||
public class ItemRockCutter extends ItemPickaxe implements IElectricItem{
|
||||
|
||||
public int maxCharge = 40000;
|
||||
public int cost = 200;
|
||||
public int hitCost = 300;
|
||||
public int maxCharge = 10000;
|
||||
public int cost = 500;
|
||||
public int tier = 2;
|
||||
|
||||
public ItemRockCutter(ToolMaterial toolMaterial)
|
||||
|
|
|
@ -147,4 +147,6 @@ item.techreborn.part.BrassMachineHull.name=Brass Machine Hull
|
|||
|
||||
#Tools
|
||||
item.techreborn.rockcutter.name=Rockcutter
|
||||
item.techreborn.lithiumbatpack.name=lithium Batpack
|
||||
|
||||
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 2.9 KiB |
Binary file not shown.
After Width: | Height: | Size: 525 B |
Loading…
Reference in a new issue