From 5cb4c6e24033cf337812390d99a6817d24d21eab Mon Sep 17 00:00:00 2001 From: Foghrye4 Date: Sun, 12 Feb 2017 20:43:03 +0300 Subject: Removed explosion radius limitations. Explosion calculation optimized (reduced memory usage). One more detonator and explosive pack recipe. GT6 recipes for both chemical reactors and cryogenic distiller. Max stack size of muffle furnace is limited to 32. A lot of old features are removed. --- ihl/recipes/RecipeInputWire.java | 113 +++++++++++++++++---------------------- 1 file changed, 49 insertions(+), 64 deletions(-) (limited to 'ihl/recipes/RecipeInputWire.java') diff --git a/ihl/recipes/RecipeInputWire.java b/ihl/recipes/RecipeInputWire.java index 0bf2855..a7d5310 100644 --- a/ihl/recipes/RecipeInputWire.java +++ b/ihl/recipes/RecipeInputWire.java @@ -9,79 +9,64 @@ import ihl.items_blocks.FlexibleCableItem; import ihl.utils.IHLUtils; import net.minecraft.item.ItemStack; -public class RecipeInputWire implements IRecipeInput -{ - public final ItemStack input; - public final int amount; +public class RecipeInputWire implements IRecipeInput { + public final ItemStack input; + public final int amount; - public RecipeInputWire(final ItemStack aInput) - { - this(aInput, IHLUtils.getWireLength(aInput)); - } + public RecipeInputWire(final ItemStack aInput) { + this(aInput, IHLUtils.getWireLength(aInput)); + } - public RecipeInputWire(final ItemStack aInput, int aAmount) - { - if (aInput.getItem() == null || !(aInput.getItem() instanceof IWire)) - { - throw new IllegalArgumentException("Invalid item stack specfied"); - } - else - { - this.input = aInput; - this.amount = aAmount; - } - } + public RecipeInputWire(final ItemStack aInput, int aAmount) { + if (aInput.getItem() == null || !(aInput.getItem() instanceof IWire)) { + throw new IllegalArgumentException("Invalid item stack specfied"); + } else { + this.input = aInput; + this.amount = aAmount; + } + } - public RecipeInputWire(String string, int i) - { - this(IHLUtils.getThisModWireItemStackWithLength(string, i),i); + public RecipeInputWire(String string, int i) { + this(IHLUtils.getThisModWireItemStackWithLength(string, i), i); } - - public RecipeInputWire(String material, int length, int transverseSection) - { - this(IHLUtils.getUninsulatedWire(material, length, transverseSection),length); + + public RecipeInputWire(String material, int length, int transverseSection) { + this(IHLUtils.getUninsulatedWire(material, length, transverseSection), length); } - - public RecipeInputWire(String material, int length, int transverseSection, String insulationMaterial, int insulationThickness, int insulationBreakdownVoltage) - { - this(IHLUtils.getInsulatedWire(material, length, transverseSection, insulationMaterial, insulationThickness),length); + + public RecipeInputWire(String material, int length, int transverseSection, String insulationMaterial, + int insulationThickness, int insulationBreakdownVoltage) { + this(IHLUtils.getInsulatedWire(material, length, transverseSection, insulationMaterial, insulationThickness), + length); } @Override - public boolean matches(ItemStack subject) - { - if(subject.getItem() == this.input.getItem() && (subject.getItemDamage() == this.input.getItemDamage() || this.input.getItemDamage() == 32767)) - { - if(subject.getItem() instanceof FlexibleCableItem) - { - FlexibleCableItem item = (FlexibleCableItem) subject.getItem(); - return item.isSameWire(this.input, subject); - } - else - { - return true; - } - } - return false; - } + public boolean matches(ItemStack subject) { + if (subject.getItem() == this.input.getItem() + && (subject.getItemDamage() == this.input.getItemDamage() || this.input.getItemDamage() == 32767)) { + if (subject.getItem() instanceof FlexibleCableItem) { + FlexibleCableItem item = (FlexibleCableItem) subject.getItem(); + return item.isSameWire(this.input, subject); + } else { + return true; + } + } + return false; + } - @Override - public int getAmount() - { - return this.amount; - } + @Override + public int getAmount() { + return this.amount; + } - @Override - public List getInputs() - { - return Arrays.asList(new ItemStack[] {this.input}); - } + @Override + public List getInputs() { + return Arrays.asList(new ItemStack[] { this.input }); + } - @Override - public String toString() - { - ItemStack stack = this.input.copy(); - return "RInputWireItemStack<" + stack + ">"; - } + @Override + public String toString() { + ItemStack stack = this.input.copy(); + return "RInputWireItemStack<" + stack + ">"; + } } - -- cgit v1.2.3