Comply with Boilerplate generalisation work
parent
71c85b2d3e
commit
87b215c8b8
|
@ -28,7 +28,6 @@ import net.minecraftforge.common.MinecraftForge;
|
|||
|
||||
import boilerplate.client.GuiHandler;
|
||||
import boilerplate.common.IBoilerplateMod;
|
||||
import boilerplate.common.IModInfo;
|
||||
import boilerplate.common.compathandler.FMPCompatHandler;
|
||||
import boilerplate.common.utils.handlers.BucketHandler;
|
||||
import steamcraft.common.compat.CompatabilityLayer;
|
||||
|
@ -57,10 +56,6 @@ import steamcraft.common.worldgen.structure.MapGenCustomScatteredFeature;
|
|||
import steamcraft.common.worldgen.structure.StructureUndercityPieces;
|
||||
import steamcraft.common.worldgen.structure.StructureUndercityStart;
|
||||
|
||||
/**
|
||||
* @author Surseance
|
||||
* @commentary by Arnold
|
||||
*/
|
||||
@Mod(modid = ModInfo.ID, name = ModInfo.NAME, version = ModInfo.VERSION, guiFactory = ModInfo.CONFIG_GUI, dependencies = "required-after:boilerplate;after:Thaumcraft;after:BrassUtils")
|
||||
public class Steamcraft implements IBoilerplateMod
|
||||
{
|
||||
|
@ -84,7 +79,6 @@ public class Steamcraft implements IBoilerplateMod
|
|||
|
||||
InitBlocks.init();
|
||||
InitItems.init();
|
||||
// InitTinkersSupport.init();
|
||||
|
||||
MinecraftForge.EVENT_BUS.register(new BucketHandler());
|
||||
|
||||
|
@ -207,12 +201,6 @@ public class Steamcraft implements IBoilerplateMod
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public IModInfo getModInfo()
|
||||
{
|
||||
return new ModInfo();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object getInstance()
|
||||
{
|
||||
|
@ -224,4 +212,40 @@ public class Steamcraft implements IBoilerplateMod
|
|||
{
|
||||
return Steamcraft.tabSC2;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getID()
|
||||
{
|
||||
return ModInfo.ID;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getName()
|
||||
{
|
||||
return ModInfo.NAME;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getVersion()
|
||||
{
|
||||
return ModInfo.VERSION;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getPrefix()
|
||||
{
|
||||
return ModInfo.PREFIX;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getClientProxyPath()
|
||||
{
|
||||
return ModInfo.CLIENT_PROXY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getCommonProxyPath()
|
||||
{
|
||||
return ModInfo.COMMON_PROXY;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -9,7 +9,6 @@ import net.minecraft.init.Blocks;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.entities.EntityFallingBoulder;
|
||||
|
||||
public class BlockBoulder extends BaseBlock
|
||||
|
@ -18,7 +17,7 @@ public class BlockBoulder extends BaseBlock
|
|||
|
||||
public BlockBoulder()
|
||||
{
|
||||
super(Material.rock, Steamcraft.instance);
|
||||
super(Material.rock);
|
||||
this.setHarvestLevel("pickaxe", 2);
|
||||
this.setHardness(2F);
|
||||
this.setResistance(20F);
|
||||
|
|
|
@ -8,14 +8,13 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitItems;
|
||||
|
||||
public class BlockBrassLeaves extends BaseBlock
|
||||
{
|
||||
public BlockBrassLeaves(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
this.setHarvestLevel("pickaxe", 2);
|
||||
}
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ public class BlockCastIronFence extends BlockCustomFence
|
|||
{
|
||||
public BlockCastIronFence()
|
||||
{
|
||||
super("metal/blockCastIron", Material.iron, Steamcraft.instance);
|
||||
super("metal/blockCastIron", Material.iron);
|
||||
this.setHardness(4.5F);
|
||||
this.setResistance(20.0F);
|
||||
this.setStepSound(Block.soundTypeMetal);
|
||||
|
|
|
@ -22,7 +22,6 @@ import net.minecraftforge.common.util.ForgeDirection;
|
|||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.client.lib.RenderIDs;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
/**
|
||||
|
@ -33,7 +32,7 @@ public class BlockCastIronRailing extends BaseBlock
|
|||
{
|
||||
public BlockCastIronRailing(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -7,14 +7,13 @@ import net.minecraft.util.AxisAlignedBB;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public class BlockCongealedSlime extends BaseBlock
|
||||
{
|
||||
|
||||
public BlockCongealedSlime(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -20,7 +20,6 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
public class BlockDynamite extends BaseBlock
|
||||
|
@ -30,7 +29,7 @@ public class BlockDynamite extends BaseBlock
|
|||
|
||||
public BlockDynamite()
|
||||
{
|
||||
super(Material.tnt, Steamcraft.instance);
|
||||
super(Material.tnt);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -9,7 +9,6 @@ import net.minecraft.world.World;
|
|||
import net.minecraft.world.WorldType;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.config.ConfigGeneral;
|
||||
import steamcraft.common.worldgen.dimension.util.TeleporterDeeps;
|
||||
|
||||
|
@ -17,7 +16,7 @@ public class BlockFissurePortal extends BaseBlock
|
|||
{
|
||||
public BlockFissurePortal(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
this.setBlockUnbreakable();
|
||||
this.setLightLevel(1F);
|
||||
}
|
||||
|
|
|
@ -10,14 +10,13 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.entities.living.EntityGrub;
|
||||
|
||||
public class BlockInfestedDirt extends BaseBlock
|
||||
{
|
||||
public BlockInfestedDirt(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -15,13 +15,12 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public class BlockLeafPile extends BaseBlock
|
||||
{
|
||||
public BlockLeafPile()
|
||||
{
|
||||
super(Material.leaves, Steamcraft.instance);
|
||||
super(Material.leaves);
|
||||
this.setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.125F, 1.0F);
|
||||
this.setTickRandomly(true);
|
||||
this.func_150154_b(0);
|
||||
|
|
|
@ -7,14 +7,13 @@ import net.minecraft.util.AxisAlignedBB;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public class BlockMud extends BaseBlock
|
||||
{
|
||||
|
||||
public BlockMud(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,7 +11,6 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.client.lib.RenderIDs;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.entities.living.EntityGhostSpider;
|
||||
import steamcraft.common.entities.living.EntityGiantSpider;
|
||||
|
||||
|
@ -20,7 +19,7 @@ public class BlockSpiderEgg extends BaseBlock
|
|||
|
||||
public BlockSpiderEgg(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
// TODO Auto-generated constructor stub
|
||||
}
|
||||
|
||||
|
|
|
@ -12,13 +12,12 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public class BlockThin extends BaseBlock
|
||||
{
|
||||
public BlockThin(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
this.setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.0625F, 1.0F);
|
||||
// this.setLightOpacity(255);
|
||||
}
|
||||
|
|
|
@ -10,13 +10,12 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public class BlockTintedRock extends BaseBlock
|
||||
{
|
||||
public BlockTintedRock(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
this.setHarvestLevel("pickaxe", 0);
|
||||
}
|
||||
|
||||
|
|
|
@ -17,7 +17,6 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
import boilerplate.client.utils.EffectUtils;
|
||||
import boilerplate.common.baseclasses.blocks.BaseBlock;
|
||||
import brassutils.api.IEngravable;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitBlocks;
|
||||
|
||||
/**
|
||||
|
@ -29,7 +28,7 @@ public class BlockUranium extends BaseBlock implements IEngravable
|
|||
{
|
||||
public BlockUranium(Material mat)
|
||||
{
|
||||
super(mat, Steamcraft.instance);
|
||||
super(mat);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -34,7 +34,7 @@ public class ItemSteamChisel extends BaseSteamItem implements IChiselItem
|
|||
|
||||
public ItemSteamChisel()
|
||||
{
|
||||
super(32000, Steamcraft.instance);
|
||||
super(32000);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
this.setUnlocalizedName("itemChiselSteam");
|
||||
this.setFull3D();
|
||||
|
|
|
@ -270,9 +270,9 @@ public class InitBlocks
|
|||
|
||||
blockStonebrickWall = new BlockStonebrickWall().setBlockName("blockStonebrickWall");
|
||||
registerBlock(blockStonebrickWall, BaseMetadataItemBlock.class, "BlockStonebrickWall", 0);
|
||||
blockStoneslabWall = new BlockCustomWall(Blocks.stone_slab, 0, Steamcraft.instance).setBlockName("blockStoneslabWall");
|
||||
blockStoneslabWall = new BlockCustomWall(Blocks.stone_slab, 0).setBlockName("blockStoneslabWall");
|
||||
registerBlock(blockStoneslabWall, "BlockStoneslabWall");
|
||||
blockBrickWall = new BlockCustomWall(Blocks.brick_block, 0, Steamcraft.instance).setBlockName("blockBrickWall");
|
||||
blockBrickWall = new BlockCustomWall(Blocks.brick_block, 0).setBlockName("blockBrickWall");
|
||||
registerBlock(blockBrickWall, "BlockBrickWall");
|
||||
}
|
||||
|
||||
|
@ -381,45 +381,42 @@ public class InitBlocks
|
|||
blockSlate = new BlockSlate().setBlockName("blockSlate");
|
||||
blockLightSlate = new BlockLightSlate().setBlockName("blockLightSlate");
|
||||
|
||||
blockRawBlueSlateStairs = new BlockCustomStairs(blockSlate, 0, Steamcraft.instance).setBlockName("blockRawBlueSlateStairs");
|
||||
blockRawBlueSlateStairs = new BlockCustomStairs(blockSlate, 0).setBlockName("blockRawBlueSlateStairs");
|
||||
registerBlock(blockRawBlueSlateStairs, "BlockRawBlueSlateStairs");
|
||||
blockRawBlackSlateStairs = new BlockCustomStairs(blockSlate, 1, Steamcraft.instance).setBlockName("blockRawBlackSlateStairs");
|
||||
blockRawBlackSlateStairs = new BlockCustomStairs(blockSlate, 1).setBlockName("blockRawBlackSlateStairs");
|
||||
registerBlock(blockRawBlackSlateStairs, "BlockRawBlackSlateStairs");
|
||||
blockRawRedSlateStairs = new BlockCustomStairs(blockSlate, 2, Steamcraft.instance).setBlockName("blockRawRedSlateStairs");
|
||||
blockRawRedSlateStairs = new BlockCustomStairs(blockSlate, 2).setBlockName("blockRawRedSlateStairs");
|
||||
registerBlock(blockRawRedSlateStairs, "BlockRawRedSlateStairs");
|
||||
blockCobbleBlueSlateStairs = new BlockCustomStairs(blockSlate, 3, Steamcraft.instance).setBlockName("blockCobbleBlueSlateStairs");
|
||||
blockCobbleBlueSlateStairs = new BlockCustomStairs(blockSlate, 3).setBlockName("blockCobbleBlueSlateStairs");
|
||||
registerBlock(blockCobbleBlueSlateStairs, "BlockCobbleBlueSlateStairs");
|
||||
blockCobbleBlackSlateStairs = new BlockCustomStairs(blockSlate, 4, Steamcraft.instance).setBlockName("blockCobbleBlackSlateStairs");
|
||||
blockCobbleBlackSlateStairs = new BlockCustomStairs(blockSlate, 4).setBlockName("blockCobbleBlackSlateStairs");
|
||||
registerBlock(blockCobbleBlackSlateStairs, "BlockCobbleBlackSlateStairs");
|
||||
blockCobbleRedSlateStairs = new BlockCustomStairs(blockSlate, 5, Steamcraft.instance).setBlockName("blockCobbleRedSlateStairs");
|
||||
blockCobbleRedSlateStairs = new BlockCustomStairs(blockSlate, 5).setBlockName("blockCobbleRedSlateStairs");
|
||||
registerBlock(blockCobbleRedSlateStairs, "BlockCobbleRedSlateStairs");
|
||||
blockBrickBlueSlateStairs = new BlockCustomStairs(blockSlate, 6, Steamcraft.instance).setBlockName("blockBrickBlueSlateStairs");
|
||||
blockBrickBlueSlateStairs = new BlockCustomStairs(blockSlate, 6).setBlockName("blockBrickBlueSlateStairs");
|
||||
registerBlock(blockBrickBlueSlateStairs, "BlockBrickBlueSlateStairs");
|
||||
blockBrickBlackSlateStairs = new BlockCustomStairs(blockSlate, 7, Steamcraft.instance).setBlockName("blockBrickBlackSlateStairs");
|
||||
blockBrickBlackSlateStairs = new BlockCustomStairs(blockSlate, 7).setBlockName("blockBrickBlackSlateStairs");
|
||||
registerBlock(blockBrickBlackSlateStairs, "BlockBrickBlackSlateStairs");
|
||||
blockBrickRedSlateStairs = new BlockCustomStairs(blockSlate, 8, Steamcraft.instance).setBlockName("blockBrickRedSlateStairs");
|
||||
blockBrickRedSlateStairs = new BlockCustomStairs(blockSlate, 8).setBlockName("blockBrickRedSlateStairs");
|
||||
registerBlock(blockBrickRedSlateStairs, "BlockBrickRedSlateStairs");
|
||||
|
||||
blockRawLightBlueSlateStairs = new BlockCustomStairs(blockLightSlate, 0, Steamcraft.instance).setBlockName("blockRawLightBlueSlateStairs");
|
||||
blockRawLightBlueSlateStairs = new BlockCustomStairs(blockLightSlate, 0).setBlockName("blockRawLightBlueSlateStairs");
|
||||
registerBlock(blockRawLightBlueSlateStairs, "BlockRawLightBlueSlateStairs");
|
||||
blockRawGreySlateStairs = new BlockCustomStairs(blockLightSlate, 1, Steamcraft.instance).setBlockName("blockRawGreySlateStairs");
|
||||
blockRawGreySlateStairs = new BlockCustomStairs(blockLightSlate, 1).setBlockName("blockRawGreySlateStairs");
|
||||
registerBlock(blockRawGreySlateStairs, "BlockRawGreySlateStairs");
|
||||
blockRawLightRedSlateStairs = new BlockCustomStairs(blockLightSlate, 2, Steamcraft.instance).setBlockName("blockRawLightRedSlateStairs");
|
||||
blockRawLightRedSlateStairs = new BlockCustomStairs(blockLightSlate, 2).setBlockName("blockRawLightRedSlateStairs");
|
||||
registerBlock(blockRawLightRedSlateStairs, "BlockRawLightRedSlateStairs");
|
||||
blockCobbleLightBlueSlateStairs = new BlockCustomStairs(blockLightSlate, 3, Steamcraft.instance)
|
||||
.setBlockName("blockCobbleLightBlueSlateStairs");
|
||||
blockCobbleLightBlueSlateStairs = new BlockCustomStairs(blockLightSlate, 3).setBlockName("blockCobbleLightBlueSlateStairs");
|
||||
registerBlock(blockCobbleLightBlueSlateStairs, "BlockCobbleLightBlueSlateStairs");
|
||||
blockCobbleGreySlateStairs = new BlockCustomStairs(blockLightSlate, 4, Steamcraft.instance).setBlockName("blockCobbleGreySlateStairs");
|
||||
blockCobbleGreySlateStairs = new BlockCustomStairs(blockLightSlate, 4).setBlockName("blockCobbleGreySlateStairs");
|
||||
registerBlock(blockCobbleGreySlateStairs, "BlockCobbleGreySlateStairs");
|
||||
blockCobbleLightRedSlateStairs = new BlockCustomStairs(blockLightSlate, 5, Steamcraft.instance)
|
||||
.setBlockName("blockCobbleLightRedSlateStairs");
|
||||
blockCobbleLightRedSlateStairs = new BlockCustomStairs(blockLightSlate, 5).setBlockName("blockCobbleLightRedSlateStairs");
|
||||
registerBlock(blockCobbleLightRedSlateStairs, "BlockCobbleLightRedSlateStairs");
|
||||
blockBrickLightBlueSlateStairs = new BlockCustomStairs(blockLightSlate, 6, Steamcraft.instance)
|
||||
.setBlockName("blockBrickLightBlueSlateStairs");
|
||||
blockBrickLightBlueSlateStairs = new BlockCustomStairs(blockLightSlate, 6).setBlockName("blockBrickLightBlueSlateStairs");
|
||||
registerBlock(blockBrickLightBlueSlateStairs, "BlockBrickLightBlueSlateStairs");
|
||||
blockBrickGreySlateStairs = new BlockCustomStairs(blockLightSlate, 7, Steamcraft.instance).setBlockName("blockBrickGreySlateStairs");
|
||||
blockBrickGreySlateStairs = new BlockCustomStairs(blockLightSlate, 7).setBlockName("blockBrickGreySlateStairs");
|
||||
registerBlock(blockBrickGreySlateStairs, "BlockBrickGreySlateStairs");
|
||||
blockBrickLightRedSlateStairs = new BlockCustomStairs(blockLightSlate, 8, Steamcraft.instance).setBlockName("blockBrickLightRedSlateStairs");
|
||||
blockBrickLightRedSlateStairs = new BlockCustomStairs(blockLightSlate, 8).setBlockName("blockBrickLightRedSlateStairs");
|
||||
registerBlock(blockBrickLightRedSlateStairs, "BlockBrickLightRedSlateStairs");
|
||||
|
||||
registerBlock(blockCustomOre, BaseMetadataItemBlock.class, "BlockSteamcraftOre", 7);
|
||||
|
@ -475,7 +472,7 @@ public class InitBlocks
|
|||
blockHatch = new BlockHatch().setBlockName("blockHatch");
|
||||
RegistryHelper.registerContainerBlock(blockHatch, TileHatch.class, "BlockHatch");
|
||||
|
||||
blockFlesh = new BaseBlock(Material.gourd, Steamcraft.instance).setBlockName("blockFlesh").setCreativeTab(Steamcraft.tabSC2);
|
||||
blockFlesh = new BaseBlock(Material.gourd).setBlockName("blockFlesh").setCreativeTab(Steamcraft.tabSC2);
|
||||
registerBlock(blockFlesh, "BlockFlesh");
|
||||
|
||||
blockCongealedSlime = new BlockCongealedSlime(Material.gourd).setBlockName("blockCongealedSlime").setCreativeTab(Steamcraft.tabSC2);
|
||||
|
@ -523,8 +520,7 @@ public class InitBlocks
|
|||
blockFissurePortal = new BlockFissurePortal(Material.rock).setBlockName("blockFissurePortal");
|
||||
registerBlock(blockFissurePortal, "BlockFissurePortal");
|
||||
|
||||
blockCompressedStone = new BaseBlock(Material.rock, Steamcraft.instance).setBlockName("blockCompressedStone").setHardness(2.2F)
|
||||
.setResistance(15.0F);
|
||||
blockCompressedStone = new BaseBlock(Material.rock).setBlockName("blockCompressedStone").setHardness(2.2F).setResistance(15.0F);
|
||||
registerBlock(blockCompressedStone, "BlockCompressedStone");
|
||||
|
||||
blockInfestedGrass = new BlockInfestedGrass(Material.grass).setBlockName("blockInfestedGrass");
|
||||
|
@ -545,96 +541,92 @@ public class InitBlocks
|
|||
blockPolishedPlanks = new BlockPolishedPlanks().setBlockName("blockPolishedPlanks");
|
||||
registerBlock(blockPolishedPlanks, BaseMetadataItemBlock.class, "BlockPolishedPlanks", 3);
|
||||
|
||||
blockRedwoodLog = new BlockCustomLog("Redwood", Steamcraft.instance).setBlockName("blockRedwoodLog");
|
||||
blockRedwoodLog = new BlockCustomLog("Redwood").setBlockName("blockRedwoodLog");
|
||||
registerBlock(blockRedwoodLog, "BlockRedwoodLog");
|
||||
|
||||
blockRedwoodLeaves = new BlockCustomLeaves("Redwood", Steamcraft.instance).setBlockName("blockRedwoodLeaves");
|
||||
blockRedwoodLeaves = new BlockCustomLeaves("Redwood").setBlockName("blockRedwoodLeaves");
|
||||
registerBlock(blockRedwoodLeaves, "BlockRedwoodLeaves");
|
||||
|
||||
blockRedwoodPlanks = new BaseBlock(Material.wood, Steamcraft.instance).setBlockName("blockRedwoodPlanks");
|
||||
blockRedwoodPlanks = new BaseBlock(Material.wood).setBlockName("blockRedwoodPlanks");
|
||||
registerBlock(blockRedwoodPlanks, "BlockRedwoodPlanks");
|
||||
|
||||
blockMangroveLog = new BlockCustomLog("Mangrove", Steamcraft.instance).setBlockName("blockMangroveLog");
|
||||
blockMangroveLog = new BlockCustomLog("Mangrove").setBlockName("blockMangroveLog");
|
||||
registerBlock(blockMangroveLog, "BlockMangroveLog");
|
||||
|
||||
blockMangroveLeaves = new BlockCustomLeaves("Mangrove", Steamcraft.instance).setBlockName("blockMangroveLeaves");
|
||||
blockMangroveLeaves = new BlockCustomLeaves("Mangrove").setBlockName("blockMangroveLeaves");
|
||||
registerBlock(blockMangroveLeaves, "BlockMangroveLeaves");
|
||||
|
||||
blockMangrovePlanks = new BaseBlock(Material.wood, Steamcraft.instance).setBlockName("blockMangrovePlanks");
|
||||
blockMangrovePlanks = new BaseBlock(Material.wood).setBlockName("blockMangrovePlanks");
|
||||
registerBlock(blockMangrovePlanks, "BlockMangrovePlanks");
|
||||
|
||||
blockWillowLog = new BlockCustomLog("Willow", Steamcraft.instance).setBlockName("blockWillowLog");
|
||||
blockWillowLog = new BlockCustomLog("Willow").setBlockName("blockWillowLog");
|
||||
registerBlock(blockWillowLog, "BlockWillowLog");
|
||||
|
||||
blockWillowLeaves = new BlockCustomLeaves("Willow", Steamcraft.instance).setBlockName("blockWillowLeaves");
|
||||
blockWillowLeaves = new BlockCustomLeaves("Willow").setBlockName("blockWillowLeaves");
|
||||
registerBlock(blockWillowLeaves, "BlockWillowLeaves");
|
||||
|
||||
blockWillowPlanks = new BaseBlock(Material.wood, Steamcraft.instance).setBlockName("blockWillowPlanks");
|
||||
blockWillowPlanks = new BaseBlock(Material.wood).setBlockName("blockWillowPlanks");
|
||||
registerBlock(blockWillowPlanks, "BlockWillowPlanks");
|
||||
|
||||
blockPetrifiedLog = new BlockCustomLog("Petrified", Steamcraft.instance).setBlockName("blockPetrifiedLog");
|
||||
blockPetrifiedLog = new BlockCustomLog("Petrified").setBlockName("blockPetrifiedLog");
|
||||
registerBlock(blockPetrifiedLog, "BlockPetrifiedLog");
|
||||
|
||||
blockDeadLeaves = new BlockCustomLeaves("Dead", Steamcraft.instance).setBlockName("blockDeadLeaves");
|
||||
blockDeadLeaves = new BlockCustomLeaves("Dead").setBlockName("blockDeadLeaves");
|
||||
registerBlock(blockDeadLeaves, "BlockDeadLeaves");
|
||||
|
||||
blockPetrifiedPlanks = new BaseBlock(Material.wood, Steamcraft.instance).setBlockName("blockPetrifiedPlanks");
|
||||
blockPetrifiedPlanks = new BaseBlock(Material.wood).setBlockName("blockPetrifiedPlanks");
|
||||
registerBlock(blockPetrifiedPlanks, "BlockPetrifiedPlanks");
|
||||
|
||||
blockRedwoodFence = new BlockCustomFence("blockRedwoodPlanks", Material.wood, Steamcraft.instance).setBlockName("blockRedwoodFence");
|
||||
blockRedwoodFence = new BlockCustomFence("blockRedwoodPlanks", Material.wood).setBlockName("blockRedwoodFence");
|
||||
registerBlock(blockRedwoodFence, "BlockRedwoodFence");
|
||||
|
||||
blockMangroveFence = new BlockCustomFence("blockMangrovePlanks", Material.wood, Steamcraft.instance).setBlockName("blockMangroveFence");
|
||||
blockMangroveFence = new BlockCustomFence("blockMangrovePlanks", Material.wood).setBlockName("blockMangroveFence");
|
||||
registerBlock(blockMangroveFence, "blockMangroveFence");
|
||||
|
||||
blockWillowFence = new BlockCustomFence("blockWillowPlanks", Material.wood, Steamcraft.instance).setBlockName("blockWillowFence");
|
||||
blockWillowFence = new BlockCustomFence("blockWillowPlanks", Material.wood).setBlockName("blockWillowFence");
|
||||
registerBlock(blockWillowFence, "blockWillowFence");
|
||||
|
||||
blockPetrifiedFence = new BlockCustomFence("blockPetrifiedPlanks", Material.wood, Steamcraft.instance).setBlockName("blockPetrifiedFence");
|
||||
blockPetrifiedFence = new BlockCustomFence("blockPetrifiedPlanks", Material.wood).setBlockName("blockPetrifiedFence");
|
||||
registerBlock(blockPetrifiedFence, "blockPetrifiedFence");
|
||||
|
||||
blockRedwoodStairs = new BlockCustomStairs(blockRedwoodPlanks, Steamcraft.instance).setBlockName("blockRedwoodStairs");
|
||||
blockRedwoodStairs = new BlockCustomStairs(blockRedwoodPlanks).setBlockName("blockRedwoodStairs");
|
||||
registerBlock(blockRedwoodStairs, "BlockRedwoodStairs");
|
||||
|
||||
blockMangroveStairs = new BlockCustomStairs(blockMangrovePlanks, Steamcraft.instance).setBlockName("blockMangroveStairs");
|
||||
blockMangroveStairs = new BlockCustomStairs(blockMangrovePlanks).setBlockName("blockMangroveStairs");
|
||||
registerBlock(blockMangroveStairs, "blockMangroveStairs");
|
||||
|
||||
blockWillowStairs = new BlockCustomStairs(blockWillowPlanks, Steamcraft.instance).setBlockName("blockWillowStairs");
|
||||
blockWillowStairs = new BlockCustomStairs(blockWillowPlanks).setBlockName("blockWillowStairs");
|
||||
registerBlock(blockWillowStairs, "blockWillowStairs");
|
||||
|
||||
blockPetrifiedStairs = new BlockCustomStairs(blockPetrifiedPlanks, Steamcraft.instance).setBlockName("blockPetrifiedStairs");
|
||||
blockPetrifiedStairs = new BlockCustomStairs(blockPetrifiedPlanks).setBlockName("blockPetrifiedStairs");
|
||||
registerBlock(blockPetrifiedStairs, "blockPetrifiedStairs");
|
||||
|
||||
blockRedwoodSlab = new BlockCustomSlab("blockRedwoodPlanks", blockRedwoodPlanks, Material.wood, Steamcraft.instance)
|
||||
.setBlockName("blockRedwoodSlab");
|
||||
blockRedwoodSlab = new BlockCustomSlab("blockRedwoodPlanks", blockRedwoodPlanks, Material.wood).setBlockName("blockRedwoodSlab");
|
||||
registerBlock(blockRedwoodSlab, "BlockRedwoodSlab");
|
||||
|
||||
blockMangroveSlab = new BlockCustomSlab("blockMangrovePlanks", blockMangrovePlanks, Material.wood, Steamcraft.instance)
|
||||
.setBlockName("blockMangroveSlab");
|
||||
blockMangroveSlab = new BlockCustomSlab("blockMangrovePlanks", blockMangrovePlanks, Material.wood).setBlockName("blockMangroveSlab");
|
||||
registerBlock(blockMangroveSlab, "blockMangroveSlab");
|
||||
|
||||
blockWillowSlab = new BlockCustomSlab("blockWillowPlanks", blockWillowPlanks, Material.wood, Steamcraft.instance)
|
||||
.setBlockName("blockWillowSlab");
|
||||
blockWillowSlab = new BlockCustomSlab("blockWillowPlanks", blockWillowPlanks, Material.wood).setBlockName("blockWillowSlab");
|
||||
registerBlock(blockWillowSlab, "blockWillowSlab");
|
||||
|
||||
blockPetrifiedSlab = new BlockCustomSlab("blockPetrifiedPlanks", blockPetrifiedPlanks, Material.wood, Steamcraft.instance)
|
||||
.setBlockName("blockPetrifiedSlab");
|
||||
blockPetrifiedSlab = new BlockCustomSlab("blockPetrifiedPlanks", blockPetrifiedPlanks, Material.wood).setBlockName("blockPetrifiedSlab");
|
||||
registerBlock(blockPetrifiedSlab, "blockPetrifiedSlab");
|
||||
|
||||
blockRedwoodDoubleSlab = new BlockCustomDoubleSlab("blockRedwoodPlanks", blockRedwoodPlanks, Material.wood, blockRedwoodSlab,
|
||||
Steamcraft.instance).setBlockName("blockRedwoodDoubleSlab");
|
||||
blockRedwoodDoubleSlab = new BlockCustomDoubleSlab("blockRedwoodPlanks", blockRedwoodPlanks, Material.wood, blockRedwoodSlab)
|
||||
.setBlockName("blockRedwoodDoubleSlab");
|
||||
// registerBlock(blockRedwoodDoubleSlab, "BlockRedwoodDoubleSlab");
|
||||
|
||||
blockMangroveDoubleSlab = new BlockCustomDoubleSlab("blockMangrovePlanks", blockMangrovePlanks, Material.wood, blockMangroveSlab,
|
||||
Steamcraft.instance).setBlockName("blockMangroveDoubleSlab");
|
||||
blockMangroveDoubleSlab = new BlockCustomDoubleSlab("blockMangrovePlanks", blockMangrovePlanks, Material.wood, blockMangroveSlab)
|
||||
.setBlockName("blockMangroveDoubleSlab");
|
||||
// registerBlock(blockMangroveDoubleSlab, "blockMangroveDoubleSlab");
|
||||
|
||||
blockWillowDoubleSlab = new BlockCustomDoubleSlab("blockWillowPlanks", blockWillowPlanks, Material.wood, blockWillowSlab, Steamcraft.instance)
|
||||
blockWillowDoubleSlab = new BlockCustomDoubleSlab("blockWillowPlanks", blockWillowPlanks, Material.wood, blockWillowSlab)
|
||||
.setBlockName("blockWillowDoubleSlab");
|
||||
// registerBlock(blockWillowDoubleSlab, "blockWillowDoubleSlab");
|
||||
|
||||
blockPetrifiedDoubleSlab = new BlockCustomDoubleSlab("blockPetrifiedPlanks", blockPetrifiedPlanks, Material.wood, blockPetrifiedSlab,
|
||||
Steamcraft.instance).setBlockName("blockPetrifiedDoubleSlab");
|
||||
blockPetrifiedDoubleSlab = new BlockCustomDoubleSlab("blockPetrifiedPlanks", blockPetrifiedPlanks, Material.wood, blockPetrifiedSlab)
|
||||
.setBlockName("blockPetrifiedDoubleSlab");
|
||||
// registerBlock(blockPetrifiedDoubleSlab, "blockPetrifiedDoubleSlab");
|
||||
|
||||
blockMud = new BlockMud(Material.ground).setBlockName("blockMud");
|
||||
|
|
|
@ -16,6 +16,7 @@ import net.minecraftforge.fluids.FluidStack;
|
|||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import boilerplate.common.baseclasses.items.BaseMetadataItem;
|
||||
import boilerplate.common.baseclasses.items.electric.BaseElectricStorageItem;
|
||||
import boilerplate.common.utils.handlers.BucketHandler;
|
||||
import boilerplate.common.utils.helpers.RegistryHelper;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
@ -29,7 +30,6 @@ import steamcraft.common.items.ItemHandbook;
|
|||
import steamcraft.common.items.ItemLoreBook;
|
||||
import steamcraft.common.items.ItemMatch;
|
||||
import steamcraft.common.items.ItemMonsterSpawner;
|
||||
import steamcraft.common.items.ItemNuggetIron;
|
||||
import steamcraft.common.items.ItemRocketLauncher;
|
||||
import steamcraft.common.items.ItemSpanner;
|
||||
import steamcraft.common.items.ItemSplashLightningBottle;
|
||||
|
@ -47,7 +47,6 @@ import steamcraft.common.items.armor.ItemMonocle;
|
|||
import steamcraft.common.items.armor.ItemNormalArmor;
|
||||
import steamcraft.common.items.armor.ItemSteamJetpack;
|
||||
import steamcraft.common.items.compat.ItemThaumicMonocle;
|
||||
import steamcraft.common.items.electric.ElectricItem;
|
||||
import steamcraft.common.items.electric.ItemRayGun;
|
||||
import steamcraft.common.items.electric.ItemShrinkray;
|
||||
import steamcraft.common.items.modules.ItemAqualung;
|
||||
|
@ -227,9 +226,9 @@ public class InitItems
|
|||
private static void initializeGuns()
|
||||
{
|
||||
// Ammo
|
||||
itemMusketBall = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemMusketBall");
|
||||
itemRifleBullet = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemRifleBullet");
|
||||
itemPercussionCap = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemPercussionCap");
|
||||
itemMusketBall = new BaseItem().setUnlocalizedName("itemMusketBall");
|
||||
itemRifleBullet = new BaseItem().setUnlocalizedName("itemRifleBullet");
|
||||
itemPercussionCap = new BaseItem().setUnlocalizedName("itemPercussionCap");
|
||||
|
||||
registerItem(itemMusketBall, "ItemMusketBall");
|
||||
registerItem(itemRifleBullet, "ItemRifleBullet");
|
||||
|
@ -271,7 +270,7 @@ public class InitItems
|
|||
registerItem(itemRayGun, "ItemRayGun");
|
||||
registerItem(itemShrinkray, "ItemShrinkray");
|
||||
|
||||
itemRocket = new BaseMetadataItem(Steamcraft.instance, new String[] { "HE", "HEAT", "AP" }).setUnlocalizedName("itemClockworkRocket")
|
||||
itemRocket = new BaseMetadataItem(new String[] { "HE", "HEAT", "AP" }).setUnlocalizedName("itemClockworkRocket")
|
||||
.setCreativeTab(Steamcraft.tabSC2);
|
||||
itemClockworkRocketLauncher = new ItemRocketLauncher(50, itemRocket, "steamcraft:rocket", "steamcraft:reload");
|
||||
|
||||
|
@ -281,13 +280,13 @@ public class InitItems
|
|||
|
||||
private static void initializeMetals()
|
||||
{
|
||||
itemIngot = new BaseMetadataItem(Steamcraft.instance, "metals/", "Ingot", LibInfo.metals).setUnlocalizedName("itemIngot");
|
||||
itemNugget = new BaseMetadataItem(Steamcraft.instance, "metals/", "Nugget", LibInfo.metals).setUnlocalizedName("itemNugget");
|
||||
itemNuggetIron = new ItemNuggetIron().setUnlocalizedName("itemNuggetIron");
|
||||
itemSheet = new BaseMetadataItem(Steamcraft.instance, "metals/", "Sheet", LibInfo.metals).setUnlocalizedName("itemSheet");
|
||||
itemPowder = new BaseMetadataItem(Steamcraft.instance, "metals/", "Ingot", LibInfo.metals).setUnlocalizedName("itemPowder");
|
||||
itemVanillaPowder = new BaseMetadataItem(Steamcraft.instance, "metals/", "Powder", LibInfo.metalsV).setUnlocalizedName("itemVanillaPowder");
|
||||
itemVanillaSheet = new BaseMetadataItem(Steamcraft.instance, "metals/", "Sheet", LibInfo.metalsV).setUnlocalizedName("itemVanillaSheet");
|
||||
itemIngot = new BaseMetadataItem("metals/", "Ingot", LibInfo.metals).setUnlocalizedName("itemIngot");
|
||||
itemNugget = new BaseMetadataItem("metals/", "Nugget", LibInfo.metals).setUnlocalizedName("itemNugget");
|
||||
itemNuggetIron = new BaseItem("/metals").setUnlocalizedName("itemNuggetIron");
|
||||
itemSheet = new BaseMetadataItem("metals/", "Sheet", LibInfo.metals).setUnlocalizedName("itemSheet");
|
||||
itemPowder = new BaseMetadataItem("metals/", "Ingot", LibInfo.metals).setUnlocalizedName("itemPowder");
|
||||
itemVanillaPowder = new BaseMetadataItem("metals/", "Powder", LibInfo.metalsV).setUnlocalizedName("itemVanillaPowder");
|
||||
itemVanillaSheet = new BaseMetadataItem("metals/", "Sheet", LibInfo.metalsV).setUnlocalizedName("itemVanillaSheet");
|
||||
|
||||
registerItem(itemIngot, "ItemIngot");
|
||||
registerItem(itemNugget, "ItemMetalNugget");
|
||||
|
@ -297,13 +296,12 @@ public class InitItems
|
|||
registerItem(itemVanillaPowder, "ItemVanillaMetalPowder");
|
||||
registerItem(itemVanillaSheet, "ItemVanillaMetalSheet");
|
||||
|
||||
itemMachinePart = new BaseMetadataItem(Steamcraft.instance, new String[] { "CastIronRod", "ClockworkMechanism", "Grating", "Magnet",
|
||||
"Generator", "Fan", "WireCoil", "Speaker", "InsulatedSheet", "Capacitor" }).setUnlocalizedName("itemMachinePart");
|
||||
itemGunPart = new BaseMetadataItem(Steamcraft.instance, new String[] { "Stock", "MusketBarrel", "RifleBarrel", "Lock", "BrassGunFrame",
|
||||
"CastIronGunFrame", "GreenFocus", "BlueFocus", "PowerCore", "OverchargedPowerCore", "PistolBarrel", "ShortStock" })
|
||||
.setUnlocalizedName("itemGunPart");
|
||||
itemIronParts = new BaseMetadataItem(Steamcraft.instance, "parts/", "Iron", LibInfo.parts).setUnlocalizedName("itemPartsIron");
|
||||
itemSteelParts = new BaseMetadataItem(Steamcraft.instance, "parts/", "Steel", LibInfo.parts).setUnlocalizedName("itemPartsSteel");
|
||||
itemMachinePart = new BaseMetadataItem(new String[] { "CastIronRod", "ClockworkMechanism", "Grating", "Magnet", "Generator", "Fan",
|
||||
"WireCoil", "Speaker", "InsulatedSheet", "Capacitor" }).setUnlocalizedName("itemMachinePart");
|
||||
itemGunPart = new BaseMetadataItem(new String[] { "Stock", "MusketBarrel", "RifleBarrel", "Lock", "BrassGunFrame", "CastIronGunFrame",
|
||||
"GreenFocus", "BlueFocus", "PowerCore", "OverchargedPowerCore", "PistolBarrel", "ShortStock" }).setUnlocalizedName("itemGunPart");
|
||||
itemIronParts = new BaseMetadataItem("parts/", "Iron", LibInfo.parts).setUnlocalizedName("itemPartsIron");
|
||||
itemSteelParts = new BaseMetadataItem("parts/", "Steel", LibInfo.parts).setUnlocalizedName("itemPartsSteel");
|
||||
|
||||
registerItem(itemMachinePart, "ItemMachinePart");
|
||||
registerItem(itemGunPart, "ItemGunPart");
|
||||
|
@ -316,8 +314,7 @@ public class InitItems
|
|||
/**
|
||||
* Registration of these are handled in @link={CompatibilityLayer.class}
|
||||
*/
|
||||
itemSteamcraftCluster = new BaseMetadataItem(Steamcraft.instance, "Cluster", new String[] { "Zinc", "Aluminum" })
|
||||
.setUnlocalizedName("itemSteamcraftCluster");
|
||||
itemSteamcraftCluster = new BaseMetadataItem("Cluster", new String[] { "Zinc", "Aluminum" }).setUnlocalizedName("itemSteamcraftCluster");
|
||||
|
||||
itemThaumicMonocle = new ItemThaumicMonocle().setUnlocalizedName("itemThaumicMonocle");
|
||||
}
|
||||
|
@ -335,10 +332,10 @@ public class InitItems
|
|||
FluidContainerRegistry.registerFluidContainer(new FluidStack(FluidRegistry.getFluid("steam"), 20000),
|
||||
((ItemCanister) itemReinforcedCanisterSteam).getFilledCanister(), new ItemStack(itemReinforcedCanisterSteam));
|
||||
|
||||
itemElectricJarSmall = new ElectricItem(80, 80, 40).setUnlocalizedName("itemElectricJarSmall");
|
||||
itemElectricJarMedium = new ElectricItem(400, 400, 125).setUnlocalizedName("itemElectricJarMedium");
|
||||
itemElectricJarLarge = new ElectricItem(1000, 2000, 750).setUnlocalizedName("itemElectricJarLarge");
|
||||
itemElectricJarHuge = new ElectricItem(4000, 10000, 3000).setUnlocalizedName("itemElectricJarHuge");
|
||||
itemElectricJarSmall = new BaseElectricStorageItem(80, 80, 40).setUnlocalizedName("itemElectricJarSmall");
|
||||
itemElectricJarMedium = new BaseElectricStorageItem(400, 400, 125).setUnlocalizedName("itemElectricJarMedium");
|
||||
itemElectricJarLarge = new BaseElectricStorageItem(1000, 2000, 750).setUnlocalizedName("itemElectricJarLarge");
|
||||
itemElectricJarHuge = new BaseElectricStorageItem(4000, 10000, 3000).setUnlocalizedName("itemElectricJarHuge");
|
||||
|
||||
registerItem(itemElectricJarSmall, "ItemElectricJarSmall");
|
||||
registerItem(itemElectricJarMedium, "ItemElectricJarMedium");
|
||||
|
@ -346,7 +343,7 @@ public class InitItems
|
|||
registerItem(itemElectricJarHuge, "ItemElectricJarHuge");
|
||||
|
||||
// Others
|
||||
itemResource = new BaseMetadataItem(Steamcraft.instance, new String[] { "Sulphur", "Phosphorus", "SulphuricAcid", "Uranium", "Pellet" })
|
||||
itemResource = new BaseMetadataItem(new String[] { "Sulphur", "Phosphorus", "SulphuricAcid", "Uranium", "Pellet" })
|
||||
.setUnlocalizedName("itemResource");
|
||||
registerItem(itemResource, "ItemResource");
|
||||
|
||||
|
@ -438,10 +435,10 @@ public class InitItems
|
|||
itemAutofeeder = new ItemAutofeeder().setUnlocalizedName("itemAutofeeder");
|
||||
registerItem(itemAutofeeder, "ItemAutofeeder");
|
||||
|
||||
itemTeaLeaf = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemTeaLeaves");
|
||||
itemTeaLeaf = new BaseItem().setUnlocalizedName("itemTeaLeaves");
|
||||
registerItem(itemTeaLeaf, "ItemTeaLeaf");
|
||||
|
||||
itemSlimeRubber = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemSlimeRubber");
|
||||
itemSlimeRubber = new BaseItem().setUnlocalizedName("itemSlimeRubber");
|
||||
registerItem(itemSlimeRubber, "ItemSlimeRubber");
|
||||
|
||||
itemTeapot = new ItemTeapot().setUnlocalizedName("itemTeapot");
|
||||
|
@ -457,7 +454,7 @@ public class InitItems
|
|||
itemHandbook = new ItemHandbook().setUnlocalizedName("itemHandbook");
|
||||
registerItem(itemHandbook, "ItemHandbook");
|
||||
|
||||
itemSpyglass = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemSpyglass").setFull3D();
|
||||
itemSpyglass = new BaseItem().setUnlocalizedName("itemSpyglass").setFull3D();
|
||||
registerItem(itemSpyglass, "ItemSpyglass");
|
||||
|
||||
// TODO Add a version system to allow updates. Check version on right
|
||||
|
@ -507,7 +504,7 @@ public class InitItems
|
|||
BucketHandler.getInstance().bucketMap.put(InitBlocks.blockMoltenBrass, itemMoltenBrassBucket);
|
||||
MinecraftForge.EVENT_BUS.register(BucketHandler.getInstance());
|
||||
|
||||
itemWhalebone = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemWhalebone");
|
||||
itemWhalebone = new BaseItem().setUnlocalizedName("itemWhalebone");
|
||||
registerItem(itemWhalebone, "ItemWhalebone");
|
||||
|
||||
itemWhaleMeat = new ItemCustomFood(3, 0.4F, false).setUnlocalizedName("itemWhaleMeat");
|
||||
|
@ -516,31 +513,31 @@ public class InitItems
|
|||
itemCookedWhaleMeat = new ItemCustomFood(6, 0.8F, true).setUnlocalizedName("itemCookedWhaleMeat");
|
||||
registerItem(itemCookedWhaleMeat, "ItemCookedWhaleMeat");
|
||||
|
||||
itemWhaleBlubber = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemWhaleBlubber");
|
||||
itemWhaleBlubber = new BaseItem().setUnlocalizedName("itemWhaleBlubber");
|
||||
registerItem(itemWhaleBlubber, "ItemWhaleBlubber");
|
||||
|
||||
itemCoin = new BaseMetadataItem(Steamcraft.instance, "Coin", new String[] { "Farthing", "Halfpenny", "Penny", "Tuppence", "Groat",
|
||||
"Thripenny", "Sixpence", "Shilling", "Florin", "HalfCrown", "Crown", "HalfSovereign", "Sovereign" }).setUnlocalizedName("itemCoin");
|
||||
itemCoin = new BaseMetadataItem("Coin", new String[] { "Farthing", "Halfpenny", "Penny", "Tuppence", "Groat", "Thripenny", "Sixpence",
|
||||
"Shilling", "Florin", "HalfCrown", "Crown", "HalfSovereign", "Sovereign" }).setUnlocalizedName("itemCoin");
|
||||
registerItem(itemCoin, "ItemCoin");
|
||||
|
||||
itemDimPocket = new ItemDimensionalPocket().setUnlocalizedName("itemDimPocket");
|
||||
// TODO registerItem(itemDimPocket, "ItemDimPocket");
|
||||
|
||||
itemRedwoodStick = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemRedwoodStick");
|
||||
itemRedwoodStick = new BaseItem().setUnlocalizedName("itemRedwoodStick");
|
||||
registerItem(itemRedwoodStick, "ItemRedwoodStick");
|
||||
itemMangroveStick = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemMangroveStick");
|
||||
itemMangroveStick = new BaseItem().setUnlocalizedName("itemMangroveStick");
|
||||
registerItem(itemMangroveStick, "ItemMangroveStick");
|
||||
itemWillowStick = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemWillowStick");
|
||||
itemWillowStick = new BaseItem().setUnlocalizedName("itemWillowStick");
|
||||
registerItem(itemWillowStick, "ItemWillowStick");
|
||||
itemPetrifiedStick = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemPetrifiedStick");
|
||||
itemPetrifiedStick = new BaseItem().setUnlocalizedName("itemPetrifiedStick");
|
||||
registerItem(itemPetrifiedStick, "ItemPetrifiedStick");
|
||||
}
|
||||
|
||||
private static void initializeTools()
|
||||
{
|
||||
// Drills
|
||||
drillCore = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemDrillCore");
|
||||
drillBase = new BaseItem(Steamcraft.instance).setUnlocalizedName("itemDrillBase");
|
||||
drillCore = new BaseItem().setUnlocalizedName("itemDrillCore");
|
||||
drillBase = new BaseItem().setUnlocalizedName("itemDrillBase");
|
||||
|
||||
drillWood = new ItemElectricDrill(InitMaterials.DRILL_WOOD, 40, 80).setUnlocalizedName("itemDrillWood");
|
||||
drillStone = new ItemElectricDrill(InitMaterials.DRILL_STONE, 80, 80).setUnlocalizedName("itemDrillStone");
|
||||
|
|
|
@ -19,7 +19,6 @@ import net.minecraftforge.fluids.FluidStack;
|
|||
import net.minecraftforge.fluids.IFluidContainerItem;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitItems;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
|
@ -36,7 +35,7 @@ public class ItemCanister extends BaseItem implements IFluidContainerItem
|
|||
|
||||
public ItemCanister(int maxSteam, int maxSteamRate)
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.maxSteam = maxSteam;
|
||||
this.maxSteamRate = maxSteamRate;
|
||||
this.setMaxStackSize(1);
|
||||
|
|
|
@ -38,7 +38,7 @@ public class ItemCustomFood extends BaseItem
|
|||
|
||||
public ItemCustomFood(int healAmount, float satModifier, boolean wolfMeat)
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.itemUseDuration = 32;
|
||||
this.healAmount = healAmount;
|
||||
this.isWolfsFavoriteMeat = wolfMeat;
|
||||
|
|
|
@ -16,7 +16,7 @@ public class ItemDimensionalPocket extends BaseItem implements IOpenableGUI
|
|||
{
|
||||
public ItemDimensionalPocket()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(1);
|
||||
}
|
||||
|
||||
|
|
|
@ -6,14 +6,13 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.entities.projectile.EntityFieldManipulator;
|
||||
|
||||
public class ItemFieldManipulator extends BaseItem
|
||||
{
|
||||
public ItemFieldManipulator()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -26,7 +26,7 @@ public class ItemFirearm extends BaseFirearm
|
|||
{
|
||||
public ItemFirearm(int damage, int reloadTime, Item ammo, Item ammo2, String fireSound, String reloadSound)
|
||||
{
|
||||
super(damage, reloadTime, ammo, ammo2, fireSound, reloadSound, Steamcraft.instance);
|
||||
super(damage, reloadTime, ammo, ammo2, fireSound, reloadSound);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ public class ItemHandbook extends BaseItem implements IOpenableGUI
|
|||
|
||||
public ItemHandbook()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(1);
|
||||
}
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@ public class ItemLoreBook extends BaseItem implements IOpenableGUI
|
|||
|
||||
public ItemLoreBook(String author, String title, String[] pages)
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(1);
|
||||
this.author = author;
|
||||
this.title = title;
|
||||
|
|
|
@ -7,7 +7,6 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
/**
|
||||
* @author warlordjones
|
||||
|
@ -17,7 +16,7 @@ public class ItemMatch extends BaseItem
|
|||
{
|
||||
public ItemMatch()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -8,7 +8,6 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseMetadataItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.entities.living.EntityAbandonedGolem;
|
||||
import steamcraft.common.entities.living.EntityBoar;
|
||||
import steamcraft.common.entities.living.EntityGhostSpider;
|
||||
|
@ -25,7 +24,7 @@ public class ItemMonsterSpawner extends BaseMetadataItem
|
|||
{
|
||||
public ItemMonsterSpawner()
|
||||
{
|
||||
super(Steamcraft.instance, "MonsterSpawner", new String[13]);
|
||||
super("MonsterSpawner", new String[13]);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -1,30 +0,0 @@
|
|||
|
||||
package steamcraft.common.items;
|
||||
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
/**
|
||||
* @author warlordjones
|
||||
*
|
||||
*/
|
||||
public class ItemNuggetIron extends BaseItem
|
||||
{
|
||||
public ItemNuggetIron()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public void registerIcons(IIconRegister par1IconRegister)
|
||||
{
|
||||
this.itemIcon = par1IconRegister.registerIcon(ModInfo.PREFIX + "metals/itemNuggetIron");
|
||||
}
|
||||
}
|
|
@ -25,7 +25,7 @@ public class ItemRocketLauncher extends BaseFirearm
|
|||
{
|
||||
public ItemRocketLauncher(int reloadTime, Item ammo, String fireSound, String reloadSound)
|
||||
{
|
||||
super(0, reloadTime, ammo, null, fireSound, reloadSound, Steamcraft.instance);
|
||||
super(0, reloadTime, ammo, null, fireSound, reloadSound);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
this.setUnlocalizedName("itemClockworkRocketLauncher");
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@ public class ItemSpanner extends BaseItem implements IUniversalWrench
|
|||
{
|
||||
public ItemSpanner()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
||||
|
|
|
@ -6,14 +6,13 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.entities.projectile.EntitySplashLightningBottle;
|
||||
|
||||
public class ItemSplashLightningBottle extends BaseItem
|
||||
{
|
||||
public ItemSplashLightningBottle()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(3);
|
||||
}
|
||||
|
||||
|
|
|
@ -12,7 +12,6 @@ import net.minecraftforge.common.IPlantable;
|
|||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitBlocks;
|
||||
|
||||
/**
|
||||
|
@ -23,7 +22,7 @@ public class ItemTeaSeed extends BaseItem implements IPlantable
|
|||
{
|
||||
public ItemTeaSeed()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(64);
|
||||
this.setUnlocalizedName("itemTeaSeed");
|
||||
}
|
||||
|
|
|
@ -17,7 +17,6 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseMetadataItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitAchievements;
|
||||
import steamcraft.common.init.InitItems;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
@ -26,7 +25,7 @@ public class ItemTeacup extends BaseMetadataItem
|
|||
{
|
||||
public ItemTeacup()
|
||||
{
|
||||
super(Steamcraft.instance, new String[] { "", "" });
|
||||
super(new String[] { "", "" });
|
||||
this.setMaxStackSize(1);
|
||||
this.setNoRepair();
|
||||
this.setFull3D();
|
||||
|
|
|
@ -16,7 +16,6 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
|
||||
import boilerplate.common.baseclasses.items.BaseMetadataItem;
|
||||
import boilerplate.common.utils.ItemStackUtils;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitItems;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
|
@ -24,7 +23,7 @@ public class ItemTeapot extends BaseMetadataItem
|
|||
{
|
||||
public ItemTeapot()
|
||||
{
|
||||
super(Steamcraft.instance, new String[] { "" });
|
||||
super(new String[] { "" });
|
||||
this.setMaxStackSize(1);
|
||||
this.setNoRepair();
|
||||
this.setFull3D();
|
||||
|
|
|
@ -15,7 +15,6 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
|
||||
import boilerplate.client.ClientHelper;
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
/**
|
||||
|
@ -28,7 +27,7 @@ public class ItemTimeClock extends BaseItem
|
|||
|
||||
public ItemTimeClock()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(1);
|
||||
}
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@ public class ItemWatch extends BaseItem
|
|||
{
|
||||
public ItemWatch()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(1);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
|
|
@ -13,7 +13,6 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitItems;
|
||||
import steamcraft.common.lib.LibInfo;
|
||||
|
||||
|
@ -27,7 +26,7 @@ public class ItemWithCraftingDurability extends BaseItem
|
|||
|
||||
public ItemWithCraftingDurability()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
this.setMaxStackSize(1);
|
||||
this.setMaxDamage(ToolMaterial.IRON.getMaxUses());
|
||||
this.setNoRepair();
|
||||
|
|
|
@ -45,7 +45,7 @@ public class ItemBrassArmor extends BaseArmor implements ISpecialArmor, IGoggles
|
|||
|
||||
public ItemBrassArmor(ItemArmor.ArmorMaterial armorMat, int renderIndex, int armorType)
|
||||
{
|
||||
super(armorMat, armorType, "brass", ModInfo.PREFIX);
|
||||
super(armorMat, armorType, "brass");
|
||||
this.setMaxStackSize(1);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
|
|
@ -28,7 +28,7 @@ public class ItemBrassGoggles extends BaseArmor
|
|||
|
||||
public ItemBrassGoggles(ArmorMaterial mat, int renderIndex, int type)
|
||||
{
|
||||
super(mat, type, "", ModInfo.PREFIX);
|
||||
super(mat, type, "");
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ public class ItemClockworkWings extends BaseArmor
|
|||
|
||||
public ItemClockworkWings(ArmorMaterial mat, int renderIndex, int type)
|
||||
{
|
||||
super(mat, type, "", ModInfo.PREFIX);
|
||||
super(mat, type, "");
|
||||
this.setMaxDamage(0);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@ public class ItemDivingHelmet extends BaseArmor
|
|||
|
||||
public ItemDivingHelmet(ArmorMaterial mat, int renderIndex, int type)
|
||||
{
|
||||
super(mat, type, "", ModInfo.PREFIX);
|
||||
super(mat, type, "");
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ public class ItemMonocle extends BaseArmor
|
|||
{
|
||||
public ItemMonocle(final ItemArmor.ArmorMaterial armorMat, final int armorType, final int renderIndex)
|
||||
{
|
||||
super(armorMat, armorType, "", ModInfo.PREFIX);
|
||||
super(armorMat, armorType, "");
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
||||
|
|
|
@ -3,7 +3,6 @@ package steamcraft.common.items.armor;
|
|||
|
||||
import boilerplate.common.baseclasses.items.BaseArmor;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
/**
|
||||
* @author Decebaldecebal
|
||||
|
@ -13,7 +12,7 @@ public class ItemNormalArmor extends BaseArmor
|
|||
{
|
||||
public ItemNormalArmor(ArmorMaterial mat, int type, String textureName)
|
||||
{
|
||||
super(mat, type, textureName, ModInfo.PREFIX);
|
||||
super(mat, type, textureName);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -31,7 +31,7 @@ public class ItemSteamJetpack extends BaseArmor
|
|||
|
||||
public ItemSteamJetpack(ArmorMaterial mat, int renderIndex, int armorType, byte steam)
|
||||
{
|
||||
super(mat, armorType, "", ModInfo.PREFIX);
|
||||
super(mat, armorType, "");
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
this.setMaxDamage(0);
|
||||
this.steamPerTick = steam;
|
||||
|
|
|
@ -1,109 +0,0 @@
|
|||
|
||||
package steamcraft.common.items.electric;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.api.IEnergyItem;
|
||||
import boilerplate.client.utils.GuiColors;
|
||||
import boilerplate.common.baseclasses.items.BaseElectricItem;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
/**
|
||||
* @author warlordjones
|
||||
*
|
||||
*/
|
||||
public class ElectricItem extends BaseElectricItem
|
||||
{
|
||||
public ElectricItem(int maxEnergy, int maxReceive, int maxSend)
|
||||
{
|
||||
super(maxEnergy, maxReceive, maxSend, Steamcraft.instance);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@Override
|
||||
public void registerIcons(IIconRegister par1IconRegister)
|
||||
{
|
||||
this.itemIcon = par1IconRegister.registerIcon(ModInfo.PREFIX + this.getUnlocalizedName().substring(5));
|
||||
}
|
||||
|
||||
@SuppressWarnings({ "rawtypes", "unchecked" })
|
||||
@Override
|
||||
public void addInformation(ItemStack stack, EntityPlayer entityplayer, List list, boolean flag)
|
||||
{
|
||||
super.addInformation(stack, entityplayer, list, flag);
|
||||
if (this.maxSend > 0)
|
||||
{
|
||||
if ((stack.getTagCompound() != null) && stack.getTagCompound().getBoolean("canCharge"))
|
||||
{
|
||||
list.add(GuiColors.GREEN + "Charging items in inventory...");
|
||||
list.add(GuiColors.GREEN + "Sneak + Right Click to turn off.");
|
||||
}
|
||||
else
|
||||
list.add("Sneak + Right Click to charge items in your inventory.");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player)
|
||||
{
|
||||
if (player.isSneaking() && (this.maxSend > 0))
|
||||
{
|
||||
NBTTagCompound tag = stack.getTagCompound();
|
||||
|
||||
if (tag == null)
|
||||
tag = new NBTTagCompound();
|
||||
|
||||
tag.setBoolean("canCharge", !tag.getBoolean("canCharge"));
|
||||
|
||||
stack.setTagCompound(tag);
|
||||
}
|
||||
return stack;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5)
|
||||
{
|
||||
if (entity instanceof EntityPlayer)
|
||||
{
|
||||
NBTTagCompound tag = stack.getTagCompound();
|
||||
|
||||
if ((tag != null) && tag.getBoolean("canCharge"))
|
||||
{
|
||||
EntityPlayer player = (EntityPlayer) entity;
|
||||
if (this.maxSend > 0)
|
||||
{
|
||||
int energy = Math.min(this.maxSend, this.getEnergyStored(stack));
|
||||
int maxEnergy = energy;
|
||||
|
||||
ItemStack[] mainInv = player.inventory.mainInventory;
|
||||
|
||||
for (ItemStack element : mainInv)
|
||||
if ((element != null) && (element != stack) && (element.getItem() instanceof IEnergyItem))
|
||||
{
|
||||
IEnergyItem container = (IEnergyItem) element.getItem();
|
||||
|
||||
energy -= container.receiveEnergy(element, energy, false);
|
||||
|
||||
if (energy == 0)
|
||||
break;
|
||||
}
|
||||
|
||||
if ((maxEnergy - energy) > 0)
|
||||
this.extractEnergy(stack, maxEnergy - energy, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,170 +0,0 @@
|
|||
|
||||
package steamcraft.common.items.electric;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.api.IEnergyItem;
|
||||
import boilerplate.common.baseclasses.items.tools.BaseTool;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public class ItemElectricTool extends BaseTool implements IEnergyItem
|
||||
{
|
||||
protected int maxEnergy = 0;
|
||||
protected short maxReceive = 0;
|
||||
protected int energyPerBlock = 0;
|
||||
|
||||
protected ItemElectricTool(float damage, ToolMaterial toolMat, int maxEnergy, int maxReceive)
|
||||
{
|
||||
super(damage, toolMat, Steamcraft.instance);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
this.maxEnergy = maxEnergy * 1000;
|
||||
this.maxReceive = (short) maxReceive;
|
||||
this.setMaxStackSize(1);
|
||||
this.setNoRepair();
|
||||
}
|
||||
|
||||
@SuppressWarnings("all")
|
||||
@Override
|
||||
public void getSubItems(Item item, CreativeTabs tab, List list)
|
||||
{
|
||||
list.add(this.getUnchargedItem(item));
|
||||
list.add(this.getChargedItem(item));
|
||||
}
|
||||
|
||||
public ItemStack getUnchargedItem(Item item)
|
||||
{
|
||||
ItemStack uncharged = new ItemStack(item);
|
||||
|
||||
if (!uncharged.hasTagCompound())
|
||||
{
|
||||
uncharged.setTagCompound(new NBTTagCompound());
|
||||
}
|
||||
uncharged.getTagCompound().setInteger("energy", 0);
|
||||
|
||||
return uncharged.copy();
|
||||
}
|
||||
|
||||
public ItemStack getChargedItem(Item item)
|
||||
{
|
||||
ItemStack charged = new ItemStack(item);
|
||||
|
||||
if (!charged.hasTagCompound())
|
||||
{
|
||||
charged.setTagCompound(new NBTTagCompound());
|
||||
}
|
||||
charged.getTagCompound().setInteger("energy", this.maxEnergy);
|
||||
|
||||
return charged.copy();
|
||||
}
|
||||
|
||||
@SuppressWarnings("all")
|
||||
@Override
|
||||
public void addInformation(ItemStack stack, EntityPlayer entityplayer, List list, boolean flag)
|
||||
{
|
||||
list.add("Energy: " + (this.getEnergyStored(stack) / 1000) + "k / " + (this.maxEnergy / 1000) + "k");
|
||||
list.add("Transfer(in): " + this.maxReceive);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCreated(ItemStack stack, World par2World, EntityPlayer par3EntityPlayer)
|
||||
{
|
||||
this.setEnergy(stack, 0);
|
||||
}
|
||||
|
||||
public void setEnergy(ItemStack stack, int energy)
|
||||
{
|
||||
if (!stack.hasTagCompound())
|
||||
{
|
||||
stack.setTagCompound(new NBTTagCompound());
|
||||
}
|
||||
NBTTagCompound tag = stack.getTagCompound();
|
||||
|
||||
if (energy < 0)
|
||||
energy = 0;
|
||||
|
||||
if (energy > this.maxEnergy)
|
||||
energy = this.maxEnergy;
|
||||
|
||||
tag.setInteger("energy", energy);
|
||||
|
||||
stack.setTagCompound(tag);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int receiveEnergy(ItemStack itemStack, int maxReceive, boolean simulate)
|
||||
{
|
||||
int received = Math.min(this.maxEnergy - this.getEnergyStored(itemStack), maxReceive);
|
||||
received = Math.min(received, this.maxReceive);
|
||||
|
||||
if (!simulate)
|
||||
this.setEnergy(itemStack, this.getEnergyStored(itemStack) + received);
|
||||
|
||||
return received;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int extractEnergy(ItemStack itemStack, int maxExtract, boolean simulate)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getEnergyStored(ItemStack stack)
|
||||
{
|
||||
return getOrCreateTagCompound(stack).getInteger("energy");
|
||||
}
|
||||
|
||||
public static NBTTagCompound getOrCreateTagCompound(ItemStack is)
|
||||
{
|
||||
if (!is.hasTagCompound())
|
||||
{
|
||||
is.setTagCompound(new NBTTagCompound());
|
||||
is.getTagCompound().setInteger("energy", 0);
|
||||
}
|
||||
|
||||
return is.getTagCompound();
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMaxEnergyStored(ItemStack container)
|
||||
{
|
||||
return this.maxEnergy;
|
||||
}
|
||||
|
||||
@Override
|
||||
public short getMaxSend()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public double getDurabilityForDisplay(ItemStack stack)
|
||||
{
|
||||
return 1.0D - ((double) this.getEnergyStored(stack) / this.getMaxEnergyStored(stack));
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean showDurabilityBar(ItemStack stack)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemEnchantability()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isBookEnchantable(ItemStack itemstack1, ItemStack itemstack2)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
|
@ -16,6 +16,7 @@ import net.minecraft.util.MovingObjectPosition;
|
|||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.items.electric.BaseElectricStorageItem;
|
||||
import boilerplate.common.utils.PlayerUtils;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
@ -25,7 +26,7 @@ import steamcraft.common.lib.ModInfo;
|
|||
*
|
||||
*/
|
||||
|
||||
public class ItemRayGun extends ElectricItem
|
||||
public class ItemRayGun extends BaseElectricStorageItem
|
||||
{
|
||||
public static short energyPerUse = 100;
|
||||
|
||||
|
|
|
@ -12,6 +12,7 @@ import net.minecraft.util.MovingObjectPosition;
|
|||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import boilerplate.common.baseclasses.items.electric.BaseElectricStorageItem;
|
||||
import boilerplate.common.entity.EntityMinedBlock;
|
||||
import boilerplate.common.utils.PlayerUtils;
|
||||
import boilerplate.common.utils.Utils;
|
||||
|
@ -22,7 +23,7 @@ import steamcraft.common.lib.ModInfo;
|
|||
* @author Surseance
|
||||
*
|
||||
*/
|
||||
public class ItemShrinkray extends ElectricItem
|
||||
public class ItemShrinkray extends BaseElectricStorageItem
|
||||
{
|
||||
public static short energyPerUse = 1000;
|
||||
|
||||
|
|
|
@ -15,13 +15,12 @@ import boilerplate.client.ClientHelper;
|
|||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.api.item.IArmorModule;
|
||||
import steamcraft.api.item.ModuleRegistry;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public abstract class BaseArmorModule extends BaseItem implements IArmorModule
|
||||
{
|
||||
public BaseArmorModule()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
ModuleRegistry.setModuleIncompatibilities(this);
|
||||
this.setMaxStackSize(1);
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
package steamcraft.common.items.armor;
|
||||
package steamcraft.common.items.modules;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
@ -14,13 +14,12 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
import boilerplate.client.ClientHelper;
|
||||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.api.item.IDefensiveArmorModule;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public abstract class BaseDefensiveModule extends BaseItem implements IDefensiveArmorModule
|
||||
{
|
||||
public BaseDefensiveModule()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
}
|
||||
|
||||
@SuppressWarnings("all")
|
|
@ -14,13 +14,12 @@ import boilerplate.client.ClientHelper;
|
|||
import boilerplate.common.baseclasses.items.BaseItem;
|
||||
import steamcraft.api.item.IFistModule;
|
||||
import steamcraft.api.item.ModuleRegistry;
|
||||
import steamcraft.common.Steamcraft;
|
||||
|
||||
public abstract class BaseFistModule extends BaseItem implements IFistModule
|
||||
{
|
||||
public BaseFistModule()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
ModuleRegistry.setModuleIncompatibilities(this);
|
||||
}
|
||||
|
||||
|
|
|
@ -11,7 +11,6 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
|
||||
import steamcraft.api.item.ModuleRegistry;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.items.armor.BaseDefensiveModule;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,10 +11,10 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import boilerplate.client.ClientHelper;
|
||||
import boilerplate.common.baseclasses.items.electric.BaseElectricStorageItem;
|
||||
import steamcraft.api.item.IPoweredModuleHelper;
|
||||
import steamcraft.common.init.InitItems;
|
||||
import steamcraft.common.items.ItemCanister;
|
||||
import steamcraft.common.items.electric.ElectricItem;
|
||||
|
||||
public abstract class PoweredArmorModule extends BaseArmorModule implements IPoweredModuleHelper
|
||||
{
|
||||
|
@ -112,9 +112,9 @@ public abstract class PoweredArmorModule extends BaseArmorModule implements IPow
|
|||
ItemStack[] mainInv = player.inventory.mainInventory;
|
||||
|
||||
for (ItemStack element : mainInv)
|
||||
if ((element != null) && (element.getItem() instanceof ElectricItem))
|
||||
if ((element != null) && (element.getItem() instanceof BaseElectricStorageItem))
|
||||
{
|
||||
ElectricItem jar = (ElectricItem) element.getItem();
|
||||
BaseElectricStorageItem jar = (BaseElectricStorageItem) element.getItem();
|
||||
|
||||
if (jar.getEnergyStored(element) >= rfToDrain)
|
||||
{
|
||||
|
@ -129,9 +129,9 @@ public abstract class PoweredArmorModule extends BaseArmorModule implements IPow
|
|||
|
||||
for (ItemStack element : mainInv)
|
||||
{
|
||||
if ((element != null) && (element.getItem() instanceof ElectricItem))
|
||||
if ((element != null) && (element.getItem() instanceof BaseElectricStorageItem))
|
||||
{
|
||||
ElectricItem jar = (ElectricItem) element.getItem();
|
||||
BaseElectricStorageItem jar = (BaseElectricStorageItem) element.getItem();
|
||||
|
||||
return jar.getEnergyStored(element) >= rfToDrain;
|
||||
}
|
||||
|
|
|
@ -7,19 +7,19 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
||||
import boilerplate.common.baseclasses.items.electric.BaseElectricStorageItem;
|
||||
import boilerplate.common.baseclasses.items.tools.BaseTool;
|
||||
import steamcraft.api.item.IFistModule;
|
||||
import steamcraft.api.item.ModuleRegistry;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.init.InitItems;
|
||||
import steamcraft.common.items.ItemCanister;
|
||||
import steamcraft.common.items.electric.ElectricItem;
|
||||
|
||||
public class ItemBrassFist extends BaseTool
|
||||
{
|
||||
public ItemBrassFist(ToolMaterial mat)
|
||||
{
|
||||
super(mat.getDamageVsEntity(), mat, Steamcraft.instance);
|
||||
super(mat.getDamageVsEntity(), mat);
|
||||
this.setMaxStackSize(1);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
@ -94,9 +94,9 @@ public class ItemBrassFist extends BaseTool
|
|||
ItemStack[] mainInv = player.inventory.mainInventory;
|
||||
|
||||
for (ItemStack element : mainInv)
|
||||
if ((element != null) && (element.getItem() instanceof ElectricItem))
|
||||
if ((element != null) && (element.getItem() instanceof BaseElectricStorageItem))
|
||||
{
|
||||
ElectricItem jar = (ElectricItem) element.getItem();
|
||||
BaseElectricStorageItem jar = (BaseElectricStorageItem) element.getItem();
|
||||
|
||||
if (jar.getEnergyStored(element) >= rfToDrain)
|
||||
{
|
||||
|
@ -111,9 +111,9 @@ public class ItemBrassFist extends BaseTool
|
|||
|
||||
for (ItemStack element : mainInv)
|
||||
{
|
||||
if ((element != null) && (element.getItem() instanceof ElectricItem))
|
||||
if ((element != null) && (element.getItem() instanceof BaseElectricStorageItem))
|
||||
{
|
||||
ElectricItem jar = (ElectricItem) element.getItem();
|
||||
BaseElectricStorageItem jar = (BaseElectricStorageItem) element.getItem();
|
||||
|
||||
return jar.getEnergyStored(element) >= rfToDrain;
|
||||
}
|
||||
|
|
|
@ -14,7 +14,7 @@ import net.minecraft.world.World;
|
|||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import steamcraft.common.items.electric.ItemElectricTool;
|
||||
import boilerplate.common.baseclasses.items.electric.ItemElectricTool;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
public class ItemElectricDrill extends ItemElectricTool
|
||||
|
|
|
@ -9,7 +9,7 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
import steamcraft.common.items.electric.ItemElectricTool;
|
||||
import boilerplate.common.baseclasses.items.electric.ItemElectricTool;
|
||||
|
||||
/**
|
||||
* @author Surseance
|
||||
|
|
|
@ -26,7 +26,7 @@ public class ItemSteamTool extends BaseTool
|
|||
{
|
||||
public ItemSteamTool(float damage)
|
||||
{
|
||||
super(damage, InitMaterials.TOOL_STEAM, Steamcraft.instance);
|
||||
super(damage, InitMaterials.TOOL_STEAM);
|
||||
this.setCreativeTab(Steamcraft.tabSC2);
|
||||
}
|
||||
|
||||
|
|
|
@ -11,7 +11,6 @@ import boilerplate.common.baseclasses.items.BaseItem;
|
|||
import steamcraft.api.vanity.EnumVanityType;
|
||||
import steamcraft.api.vanity.IVanityItem;
|
||||
import steamcraft.client.renderers.models.ModelTopHat;
|
||||
import steamcraft.common.Steamcraft;
|
||||
import steamcraft.common.lib.ModInfo;
|
||||
|
||||
/**
|
||||
|
@ -22,7 +21,7 @@ public class ItemTopHat extends BaseItem implements IVanityItem
|
|||
{
|
||||
public ItemTopHat()
|
||||
{
|
||||
super(Steamcraft.instance);
|
||||
super();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -1,53 +1,15 @@
|
|||
|
||||
package steamcraft.common.lib;
|
||||
|
||||
import boilerplate.common.IModInfo;
|
||||
|
||||
public class ModInfo implements IModInfo
|
||||
public class ModInfo
|
||||
{
|
||||
public static final String ID = "steamcraft2";
|
||||
public static final String PREFIX = "steamcraft:";
|
||||
public static final String NAME = "Steamcraft 2";
|
||||
public static final String VERSION = "B5.0.1";
|
||||
|
||||
public static final String CLIENT_PROXY = "steamcraft.client.ClientProxy";
|
||||
public static final String COMMON_PROXY = "steamcraft.common.CommonProxy";
|
||||
|
||||
public static final String CONFIG_GUI = "steamcraft.client.gui.GuiFactorySteamcraft";
|
||||
|
||||
public static final String PREFIX = "steamcraft:";
|
||||
|
||||
@Override
|
||||
public String getID()
|
||||
{
|
||||
return ID;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getName()
|
||||
{
|
||||
return NAME;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getVersion()
|
||||
{
|
||||
return VERSION;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getPrefix()
|
||||
{
|
||||
return PREFIX;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getClientProxyPath()
|
||||
{
|
||||
return CLIENT_PROXY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getCommonProxyPath()
|
||||
{
|
||||
return COMMON_PROXY;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue