diff options
Diffstat (limited to 'src/Java/gtPlusPlus/core/item')
-rw-r--r-- | src/Java/gtPlusPlus/core/item/ModItems.java | 6 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/item/base/cell/BaseItemCell.java | 18 |
2 files changed, 21 insertions, 3 deletions
diff --git a/src/Java/gtPlusPlus/core/item/ModItems.java b/src/Java/gtPlusPlus/core/item/ModItems.java index 7527a5d149..e134c789d6 100644 --- a/src/Java/gtPlusPlus/core/item/ModItems.java +++ b/src/Java/gtPlusPlus/core/item/ModItems.java @@ -444,10 +444,10 @@ public final class ModItems { //Leagrisium MaterialGenerator.generate(ALLOY.LEAGRISIUM); - + //Super Conductor MaterialGenerator.generate(ALLOY.HG1223, false, false); - + //Must be the final Alloy to Generate MaterialGenerator.generate(ALLOY.QUANTUM); @@ -619,7 +619,7 @@ public final class ModItems { //Vanadium if (ItemUtils.getItemStackOfAmountFromOreDictNoBroken("plateVanadium", 1) == null){ itemPlateVanadium = new BaseItemPlate(MaterialUtils.generateMaterialFromGtENUM(Materials.Vanadium)); - } + } //EnderIO Resources if ((LoadedMods.EnderIO || LOAD_ALL_CONTENT) && !CORE.GTNH){ diff --git a/src/Java/gtPlusPlus/core/item/base/cell/BaseItemCell.java b/src/Java/gtPlusPlus/core/item/base/cell/BaseItemCell.java index c9340badda..f5fff65882 100644 --- a/src/Java/gtPlusPlus/core/item/base/cell/BaseItemCell.java +++ b/src/Java/gtPlusPlus/core/item/base/cell/BaseItemCell.java @@ -6,9 +6,14 @@ import gtPlusPlus.core.item.base.BaseItemComponent; import gtPlusPlus.core.lib.CORE; import gtPlusPlus.core.material.Material; import gtPlusPlus.core.util.Utils; +import gtPlusPlus.core.util.fluid.FluidUtils; +import gtPlusPlus.core.util.item.ItemUtils; +import ic2.core.Ic2Items; import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.item.ItemStack; import net.minecraft.util.IIcon; +import net.minecraftforge.fluids.Fluid; +import net.minecraftforge.fluids.FluidContainerRegistry; public class BaseItemCell extends BaseItemComponent{ @@ -19,6 +24,19 @@ public class BaseItemCell extends BaseItemComponent{ public BaseItemCell(final Material material) { super(material, BaseItemComponent.ComponentTypes.CELL); this.fluidColour = (short[]) ((material == null) ? this.extraData : material.getRGBA()); + //FluidContainerRegistry.registerFluidContainer(material.getFluid(1000), ItemUtils.getSimpleStack(this), Ic2Items.cell.copy()); + } + + public BaseItemCell(final String unlocalName, final String localName, final short[] RGBa) { + super(unlocalName, localName, RGBa); + this.fluidColour = RGBa; + FluidContainerRegistry.registerFluidContainer(FluidUtils.getFluidStack(unlocalName.toLowerCase(), 0), ItemUtils.getSimpleStack(this), Ic2Items.cell.copy()); + } + + public BaseItemCell(final String unlocalName, final String localName, final short[] RGBa, final Fluid cellFluid) { + super(unlocalName, localName, RGBa); + this.fluidColour = RGBa; + FluidContainerRegistry.registerFluidContainer(FluidUtils.getFluidStack(cellFluid, 1000), ItemUtils.getSimpleStack(this), Ic2Items.cell.copy()); } @Override |