diff options
| author | Unknown <tudurap.com@gmail.com> | 2019-07-18 10:42:08 +0200 |
|---|---|---|
| committer | Unknown <tudurap.com@gmail.com> | 2019-07-18 10:42:08 +0200 |
| commit | f40aa558f8206923439042b145164be89be33de2 (patch) | |
| tree | 622777e10756c041e89504309b0cb7cd01e3b571 /src/main/java | |
| parent | 2583abae0e13087ac467bb465eddd4062820a09f (diff) | |
| parent | 624c89d41ee8bca639bd69e22f997e181d1e24de (diff) | |
| download | GT5-Unofficial-f40aa558f8206923439042b145164be89be33de2.tar.gz GT5-Unofficial-f40aa558f8206923439042b145164be89be33de2.tar.bz2 GT5-Unofficial-f40aa558f8206923439042b145164be89be33de2.zip | |
Merge remote-tracking branch 'origin/ActuallyBetterParametrizers' into BassAddons
Diffstat (limited to 'src/main/java')
26 files changed, 113 insertions, 114 deletions
diff --git a/src/main/java/com/github/technus/tectech/compatibility/thaumcraft/elementalMatter/definitions/ePrimalAspectDefinition.java b/src/main/java/com/github/technus/tectech/compatibility/thaumcraft/elementalMatter/definitions/ePrimalAspectDefinition.java index 5f3f01d4cb..7ca125cd5e 100644 --- a/src/main/java/com/github/technus/tectech/compatibility/thaumcraft/elementalMatter/definitions/ePrimalAspectDefinition.java +++ b/src/main/java/com/github/technus/tectech/compatibility/thaumcraft/elementalMatter/definitions/ePrimalAspectDefinition.java @@ -9,15 +9,15 @@ import static com.github.technus.tectech.mechanics.elementalMatter.core.cElement */ public final class ePrimalAspectDefinition extends cElementalPrimitive implements iElementalAspect { public static final ePrimalAspectDefinition - magic_air = new ePrimalAspectDefinition("Air", "a`", 0, 1e1F, 0, -1, 35), - magic_earth = new ePrimalAspectDefinition("Earth", "e`", 0, 1e9F, 0, -1, 34), - magic_fire = new ePrimalAspectDefinition("Fire", "f`", 0, 1e3F, 0, -1, 33), - magic_water = new ePrimalAspectDefinition("Water", "w`", 0, 1e7F, 0, -1, 32), - magic_order = new ePrimalAspectDefinition("Order", "o`", 0, 1e5F, 0, -1, 30), - magic_entropy = new ePrimalAspectDefinition("Entropy", "e`", 0, 1e5F, 0, -1, 31); - - private ePrimalAspectDefinition(String name, String symbol, int type, float mass, int charge, int color, int ID) { - super(name, symbol, type, mass, charge, color, ID); + magic_air = new ePrimalAspectDefinition("Air", "a`", 1e1F, 35), + magic_earth = new ePrimalAspectDefinition("Earth", "e`", 1e9F, 34), + magic_fire = new ePrimalAspectDefinition("Fire", "f`", 1e3F, 33), + magic_water = new ePrimalAspectDefinition("Water", "w`", 1e7F, 32), + magic_order = new ePrimalAspectDefinition("Order", "o`", 1e5F, 30), + magic_entropy = new ePrimalAspectDefinition("Entropy", "e`", 1e5F, 31); + + private ePrimalAspectDefinition(String name, String symbol, float mass, int ID) { + super(name, symbol, 0, mass, 0, -1, ID); } public static void run() { diff --git a/src/main/java/com/github/technus/tectech/loader/gui/ModGuiHandler.java b/src/main/java/com/github/technus/tectech/loader/gui/ModGuiHandler.java index e3314fccd9..44585d1b91 100644 --- a/src/main/java/com/github/technus/tectech/loader/gui/ModGuiHandler.java +++ b/src/main/java/com/github/technus/tectech/loader/gui/ModGuiHandler.java @@ -18,10 +18,9 @@ public class ModGuiHandler implements IGuiHandler { @Override public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) { - switch (ID){ - case SCAN_DISPLAY_SCREEN_ID: - return new ScanDisplayScreen(player); - default: return null; + if (ID == SCAN_DISPLAY_SCREEN_ID) { + return new ScanDisplayScreen(player); } + return null; } } diff --git a/src/main/java/com/github/technus/tectech/mechanics/dataTransport/InventoryDataPacket.java b/src/main/java/com/github/technus/tectech/mechanics/dataTransport/InventoryDataPacket.java index 9fb2fed082..4eb5356ae7 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/dataTransport/InventoryDataPacket.java +++ b/src/main/java/com/github/technus/tectech/mechanics/dataTransport/InventoryDataPacket.java @@ -5,6 +5,8 @@ import net.minecraft.nbt.NBTTagCompound; import java.util.ArrayList; +import static com.github.technus.tectech.recipe.TT_recipeAdder.nullItem; + public class InventoryDataPacket extends DataPacket<ItemStack[]> { public InventoryDataPacket(ItemStack[] content){ super(content); @@ -25,7 +27,7 @@ public class InventoryDataPacket extends DataPacket<ItemStack[]> { stacks.add(stack); } } - return stacks.size()>0?stacks.toArray(new ItemStack[0]):null; + return stacks.size()>0?stacks.toArray(nullItem):null; } return null; } diff --git a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/core/commands/GiveEM.java b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/core/commands/GiveEM.java index 333359949f..de1934fed7 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/core/commands/GiveEM.java +++ b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/core/commands/GiveEM.java @@ -49,19 +49,21 @@ public class GiveEM implements ICommand { String energy=list.remove(0); cElementalDefinitionStack def= getDefinitionStack(list); - cElementalInstanceStack instanceStack=new cElementalInstanceStack(def,1,0,Long.parseLong(energy)); + if(def!=null) { + cElementalInstanceStack instanceStack = new cElementalInstanceStack(def, 1, 0, Long.parseLong(energy)); - sender.addChatMessage(new ChatComponentText(instanceStack.definition.getSymbol()+" - "+instanceStack.definition.getName())); + sender.addChatMessage(new ChatComponentText(instanceStack.definition.getSymbol() + " - " + instanceStack.definition.getName())); - cElementalInstanceStackMap instanceMap=new cElementalInstanceStackMap(instanceStack); + cElementalInstanceStackMap instanceMap = new cElementalInstanceStackMap(instanceStack); - ItemStack itemStack=new ItemStack(DebugElementalInstanceContainer_EM.INSTANCE); - NBTTagCompound contents=new NBTTagCompound(); - contents.setTag("info", instanceMap.getInfoNBT()); - contents.setTag("content", instanceMap.toNBT()); - itemStack.setTagCompound(contents); + ItemStack itemStack = new ItemStack(DebugElementalInstanceContainer_EM.INSTANCE); + NBTTagCompound contents = new NBTTagCompound(); + contents.setTag("info", instanceMap.getInfoNBT()); + contents.setTag("content", instanceMap.toNBT()); + itemStack.setTagCompound(contents); - ((EntityPlayerMP) sender).inventory.addItemStackToInventory(itemStack); + ((EntityPlayerMP) sender).inventory.addItemStackToInventory(itemStack); + } } } } diff --git a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/complex/dAtomDefinition.java b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/complex/dAtomDefinition.java index e6dc5bcd75..ea8f6bc201 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/complex/dAtomDefinition.java +++ b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/complex/dAtomDefinition.java @@ -417,35 +417,35 @@ public final class dAtomDefinition extends cElementalDefinition { switch (decayMode) { case -2: if(TecTech.RANDOM.nextBoolean() && ElectronCapture(decaysList)) { - return decaysList.toArray(new cElementalDecay[0]); + return decaysList.toArray(cElementalDecay.noProduct); } else if(PbetaDecay(decaysList)) { - return decaysList.toArray(new cElementalDecay[0]); + return decaysList.toArray(cElementalDecay.noProduct); } break; case -1: if(Emmision(decaysList, dHadronDefinition.hadron_p1)) { - return decaysList.toArray(new cElementalDecay[0]); + return decaysList.toArray(cElementalDecay.noProduct); } break; case 0: if(alphaDecay(decaysList)) { - return decaysList.toArray(new cElementalDecay[0]); + return decaysList.toArray(cElementalDecay.noProduct); } break; case 1: if(Emmision(decaysList, dHadronDefinition.hadron_n1)) { - return decaysList.toArray(new cElementalDecay[0]); + return decaysList.toArray(cElementalDecay.noProduct); } break; case 2: if(MbetaDecay(decaysList)) { - return decaysList.toArray(new cElementalDecay[0]); + return decaysList.toArray(cElementalDecay.noProduct); } break; default: if(decayMode>8){ if(iaeaDecay(decaysList,0)) { - return decaysList.toArray(new cElementalDecay[0]); + return decaysList.toArray(cElementalDecay.noProduct); } return getDecayArray(decaysList,decayMode- BYTE_OFFSET,false); } @@ -1188,7 +1188,7 @@ public final class dAtomDefinition extends cElementalDefinition { if (iaeaDefinitionExistsAndHasEnergyLevels) { ArrayList<cElementalDecay> decays=new ArrayList<>(4); if(iaeaDecay(decays,energyLevel)){ - return decays.toArray(new cElementalDecay[0]); + return decays.toArray(cElementalDecay.noProduct); } } if(energyLevel< Math.abs(charge)/3+neutralCount) { diff --git a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/cPrimitiveDefinition.java b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/cPrimitiveDefinition.java index 6b23c232c7..a09fc60835 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/cPrimitiveDefinition.java +++ b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/cPrimitiveDefinition.java @@ -9,14 +9,14 @@ import static com.github.technus.tectech.mechanics.elementalMatter.core.cElement */ public final class cPrimitiveDefinition extends cElementalPrimitive { public static final cPrimitiveDefinition - nbtE__ = new cPrimitiveDefinition("NBT ERROR", "!", 0, 0f, 0, Integer.MIN_VALUE, Integer.MIN_VALUE+10_000), - null__ = new cPrimitiveDefinition("NULL POINTER", ".", 0, 0F, 0, -3, Integer.MAX_VALUE-10_000), - space__ = new cPrimitiveDefinition("Space", "_", 0, 0F, 0, -4, 0), - magic = new cPrimitiveDefinition("Magic", "Ma", 4, 1e5F, 0, 0, 1), - magic_ = new cPrimitiveDefinition("Antimagic", "~Ma", -4, 1e5F, 0, 0, 2); + nbtE__ = new cPrimitiveDefinition("NBT ERROR", "!", 0, 0f, Integer.MIN_VALUE, Integer.MIN_VALUE+10_000), + null__ = new cPrimitiveDefinition("NULL POINTER", ".", 0, 0F, -3, Integer.MAX_VALUE-10_000), + space__ = new cPrimitiveDefinition("Space", "_", 0, 0F, -4, 0), + magic = new cPrimitiveDefinition("Magic", "Ma", 4, 1e5F, 0, 1), + magic_ = new cPrimitiveDefinition("Antimagic", "~Ma", -4, 1e5F, 0, 2); - private cPrimitiveDefinition(String name, String symbol, int type, float mass, int charge, int color, int ID) { - super(name, symbol, type, mass, charge, color, ID); + private cPrimitiveDefinition(String name, String symbol, int type, float mass, int color, int ID) { + super(name, symbol, type, mass, 0, color, ID); } public static void run() { diff --git a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eBosonDefinition.java b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eBosonDefinition.java index dada9b9c10..3f314151f3 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eBosonDefinition.java +++ b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eBosonDefinition.java @@ -9,15 +9,15 @@ import com.github.technus.tectech.mechanics.elementalMatter.core.templates.cElem */ public final class eBosonDefinition extends cElementalPrimitive { public static final eBosonDefinition - boson_Y__ = new eBosonDefinition("Photon", "\u03b3", 0, 1e-18F, 0, -1, 27), - boson_H__ = new eBosonDefinition("Higgs", "\u0397", 0, 126.09e9F, 0, -2, 28); + boson_Y__ = new eBosonDefinition("Photon", "\u03b3", 1e-18F, -1, 27), + boson_H__ = new eBosonDefinition("Higgs", "\u0397", 126.09e9F, -2, 28); //deadEnd public static final cElementalDecay deadEnd = new cElementalDecay(boson_Y__, boson_Y__); public static final cElementalDecay deadEndHalf = new cElementalDecay(boson_Y__); public static final cElementalDefinitionStack boson_Y__1=new cElementalDefinitionStack(boson_Y__,1); - private eBosonDefinition(String name, String symbol, int type, float mass, int charge, int color, int ID) { - super(name, symbol, type, mass, charge, color, ID); + private eBosonDefinition(String name, String symbol, float mass, int color, int ID) { + super(name, symbol, 0, mass, 0, color, ID); } public static void run() { diff --git a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eLeptonDefinition.java b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eLeptonDefinition.java index 412fcfcd4e..20132e2095 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eLeptonDefinition.java +++ b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eLeptonDefinition.java @@ -9,20 +9,20 @@ import com.github.technus.tectech.mechanics.elementalMatter.core.templates.cElem */ public final class eLeptonDefinition extends cElementalPrimitive { public static final eLeptonDefinition - lepton_e = new eLeptonDefinition("Electron", "\u03b2-", 1, 0.511e6F, -3, -1, 15), - lepton_m = new eLeptonDefinition("Muon", "\u03bc-", 2, 105.658e6F, -3, -1, 17), - lepton_t = new eLeptonDefinition("Tauon", "\u03c4-", 3, 1776.83e6F, -3, -1, 19), - lepton_e_ = new eLeptonDefinition("Positron", "\u03b2+", -1, 0.511e6F, 3, -1, 16), - lepton_m_ = new eLeptonDefinition("Antimuon", "\u03bc+", -2, 105.658e6F, 3, -1, 18), - lepton_t_ = new eLeptonDefinition("Antitauon", "\u03c4+", -3, 1776.83e6F, 3, -1, 20); + lepton_e = new eLeptonDefinition("Electron", "\u03b2-", 1, 0.511e6F, -3, 15), + lepton_m = new eLeptonDefinition("Muon", "\u03bc-", 2, 105.658e6F, -3, 17), + lepton_t = new eLeptonDefinition("Tauon", "\u03c4-", 3, 1776.83e6F, -3, 19), + lepton_e_ = new eLeptonDefinition("Positron", "\u03b2+", -1, 0.511e6F, 3, 16), + lepton_m_ = new eLeptonDefinition("Antimuon", "\u03bc+", -2, 105.658e6F, 3, 18), + lepton_t_ = new eLeptonDefinition("Antitauon", "\u03c4+", -3, 1776.83e6F, 3, 20); public static final cElementalDefinitionStack lepton_e1 = new cElementalDefinitionStack(lepton_e, 1); public static final cElementalDefinitionStack lepton_e2 = new cElementalDefinitionStack(lepton_e, 2); public static final cElementalDefinitionStack lepton_e_1 = new cElementalDefinitionStack(lepton_e_, 1); public static final cElementalDefinitionStack lepton_e_2 = new cElementalDefinitionStack(lepton_e_, 2); - private eLeptonDefinition(String name, String symbol, int type, float mass, int charge, int color, int ID) { - super(name, symbol, type, mass, charge, color, ID); + private eLeptonDefinition(String name, String symbol, int type, float mass, int charge, int ID) { + super(name, symbol, type, mass, charge, -1, ID); //this.itemThing=null; //this.fluidThing=null; } diff --git a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eNeutrinoDefinition.java b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eNeutrinoDefinition.java index 9f20908575..5f6a4a7b5e 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eNeutrinoDefinition.java +++ b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eNeutrinoDefinition.java @@ -9,20 +9,20 @@ import com.github.technus.tectech.mechanics.elementalMatter.core.templates.cElem */ public final class eNeutrinoDefinition extends cElementalPrimitive { public static final eNeutrinoDefinition - lepton_Ve = new eNeutrinoDefinition("Electron neutrino", "\u03bd\u03b2", 1, 2e0F, 0, -1, 21), - lepton_Vm = new eNeutrinoDefinition("Muon neutrino", "\u03bd\u03bc", 2, 0.15e6F, 0, -1, 23), - lepton_Vt = new eNeutrinoDefinition("Tauon neutrino", "\u03bd\u03c4", 3, 15e6F, 0, -1, 25), - lepton_Ve_ = new eNeutrinoDefinition("Positron neutrino", "~\u03bd\u03b2", -1, 2e0F, 0, -1, 22), - lepton_Vm_ = new eNeutrinoDefinition("Antimuon neutrino", "~\u03bd\u03bc", -2, 0.15e6F, 0, -1, 24), - lepton_Vt_ = new eNeutrinoDefinition("Antitauon neutrino", "~\u03bd\u03c4", -3, 15e6F, 0, -1, 26); + lepton_Ve = new eNeutrinoDefinition("Electron neutrino", "\u03bd\u03b2", 1, 2e0F, 21), + lepton_Vm = new eNeutrinoDefinition("Muon neutrino", "\u03bd\u03bc", 2, 0.15e6F, 23), + lepton_Vt = new eNeutrinoDefinition("Tauon neutrino", "\u03bd\u03c4", 3, 15e6F, 25), + lepton_Ve_ = new eNeutrinoDefinition("Positron neutrino", "~\u03bd\u03b2", -1, 2e0F, 22), + lepton_Vm_ = new eNeutrinoDefinition("Antimuon neutrino", "~\u03bd\u03bc", -2, 0.15e6F, 24), + lepton_Vt_ = new eNeutrinoDefinition("Antitauon neutrino", "~\u03bd\u03c4", -3, 15e6F, 26); public static final cElementalDefinitionStack lepton_Ve1 = new cElementalDefinitionStack(lepton_Ve, 1); public static final cElementalDefinitionStack lepton_Ve2 = new cElementalDefinitionStack(lepton_Ve, 2); public static final cElementalDefinitionStack lepton_Ve_1 = new cElementalDefinitionStack(lepton_Ve_, 1); public static final cElementalDefinitionStack lepton_Ve_2 = new cElementalDefinitionStack(lepton_Ve_, 2); - private eNeutrinoDefinition(String name, String symbol, int type, float mass, int charge, int color, int ID) { - super(name, symbol, type, mass, charge, color, ID); + private eNeutrinoDefinition(String name, String symbol, int type, float mass, int ID) { + super(name, symbol, type, mass, 0, -1, ID); } public static void run() { diff --git a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eQuarkDefinition.java b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eQuarkDefinition.java index 9a7dd6753a..be6879d435 100644 --- a/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eQuarkDefinition.java +++ b/src/main/java/com/github/technus/tectech/mechanics/elementalMatter/definitions/primitive/eQuarkDefinition.java @@ -8,21 +8,21 @@ import com.github.technus.tectech.mechanics.elementalMatter.core.templates.cElem */ public final class eQuarkDefinition extends cElementalPrimitive { public static final eQuarkDefinition - quark_u = new eQuarkDefinition("Up", "u", 1, 2.3e6F, 2, 0, 3), - quark_c = new eQuarkDefinition("Charm", "c", 2, 1.29e9F, 2, 0, 9), - quark_t = new eQuarkDefinition("Top", "t", 3, 172.44e9F, 2, 0, 13), - quark_d = new eQuarkDefinition("Down", "d", 1, 4.8e6F, -1, 0, 5), - quark_s = new eQuarkDefinition("Strange", "s", 2, 95e6F, -1, 0, 7), - quark_b = new eQuarkDefinition("Bottom", "b", 3, 4.65e9F, -1, 0, 11), - quark_u_ = new eQuarkDefinition("AntiUp", "~u", -1, 2.3e6F, -2, 0, 4), - quark_c_ = new eQuarkDefinition("AntiCharm", "~c", -2, 1.29e9F, -2, 0, 10), - quark_t_ = new eQuarkDefinition("AntiTop", "~t", -3, 172.44e9F, -2, 0, 14), - quark_d_ = new eQuarkDefinition("AntiDown", "~d", -1, 4.8e6F, 1, 0, 6), - quark_s_ = new eQuarkDefinition("AntiStrange", "~s", -2, 95e6F, 1, 0, 8), - quark_b_ = new eQuarkDefinition("AntiBottom", "~b", -3, 4.65e9F, 1, 0, 12); + quark_u = new eQuarkDefinition("Up", "u", 1, 2.3e6F, 2, 3), + quark_c = new eQuarkDefinition("Charm", "c", 2, 1.29e9F, 2, 9), + quark_t = new eQuarkDefinition("Top", "t", 3, 172.44e9F, 2, 13), + quark_d = new eQuarkDefinition("Down", "d", 1, 4.8e6F, -1, 5), + quark_s = new eQuarkDefinition("Strange", "s", 2, 95e6F, -1, 7), + quark_b = new eQuarkDefinition("Bottom", "b", 3, 4.65e9F, -1, 11), + quark_u_ = new eQuarkDefinition("AntiUp", "~u", -1, 2.3e6F, -2, 4), + quark_c_ = new eQuarkDefinition("AntiCharm", "~c", -2, 1.29e9F, -2, 10), + quark_t_ = new eQuarkDefinition("AntiTop", "~t", -3, 172.44e9F, -2, 14), + quark_d_ = new eQuarkDefinition("AntiDown", "~d", -1, 4.8e6F, 1, 6), + quark_s_ = new eQuarkDefinition("AntiStrange", "~s", -2, 95e6F, 1, 8), + quark_b_ = new eQuarkDefinition("AntiBottom", "~b", -3, 4.65e9F, 1, 12); - private eQuarkDefinition(String name, String symbol, int type, float mass, int charge, int color, int ID) { - super(name, symbol, type, mass, charge, color, ID); + private eQuarkDefinition(String name, String symbol, int type, float mass, int charge, int ID) { + super(name, symbol, type, mass, charge, 0, ID); } public static void run() { diff --git a/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java b/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java index 1c75dceec7..74911fe67e 100644 --- a/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java +++ b/src/main/java/com/github/technus/tectech/nei/TT_NEI_ResearchHandler.java @@ -33,6 +33,7 @@ import java.util.Collections; import java.util.Iterator; import java.util.List; +import static com.github.technus.tectech.recipe.TT_recipeAdder.nullItem; import static gregtech.api.enums.ItemList.Display_Fluid; public class TT_NEI_ResearchHandler extends TemplateRecipeHandler { @@ -365,7 +366,7 @@ public class TT_NEI_ResearchHandler extends TemplateRecipeHandler { } } } - items = tDisplayStacks.toArray(new ItemStack[0]); + items = tDisplayStacks.toArray(nullItem); if (items.length == 0) { items = new ItemStack[]{new ItemStack(Blocks.fire)}; } diff --git a/src/main/java/com/github/technus/tectech/nei/TT_NEI_ScannerHandler.java b/src/main/java/com/github/technus/tectech/nei/TT_NEI_ScannerHandler.java index e9624f1b33..4ab8d46f5c 100644 --- a/src/main/java/com/github/technus/tectech/nei/TT_NEI_ScannerHandler.java +++ b/src/main/java/com/github/technus/tectech/nei/TT_NEI_ScannerHandler.java @@ -33,6 +33,7 @@ import java.util.Collections; import java.util.Iterator; import java.util.List; +import static com.github.technus.tectech.recipe.TT_recipeAdder.nullItem; import static gregtech.api.enums.ItemList.Display_Fluid; public class TT_NEI_ScannerHandler extends TemplateRecipeHandler { @@ -365,7 +366,7 @@ public class TT_NEI_ScannerHandler extends TemplateRecipeHandler { } } } - items = tDisplayStacks.toArray(new ItemStack[0]); + items = tDisplayStacks.toArray(nullItem); if (items.length == 0) { items = new ItemStack[]{new ItemStack(Blocks.fire)}; } diff --git a/src/main/java/com/github/technus/tectech/recipe/TT_recipeAdder.java b/src/main/java/com/github/technus/tectech/recipe/TT_recipeAdder.java index 6fd4d7edaa..88e57fc3ab 100644 --- a/src/main/java/com/github/technus/tectech/recipe/TT_recipeAdder.java +++ b/src/main/java/com/github/technus/tectech/recipe/TT_recipeAdder.java @@ -95,7 +95,7 @@ public class TT_recipeAdder extends GT_RecipeAdder { if (tInputs[i] == null) tInputs[i] = uStack; } } - tAlts[i] = uList.toArray(new ItemStack[0]); + tAlts[i] = uList.toArray(nullItem); continue; } catch (Exception t) { TecTech.LOGGER.error("addAssemblingLineRecipe "+aResearchItem.getDisplayName()+" --> there is some ... in that recipe"); diff --git a/src/main/java/com/github/technus/tectech/thing/item/DebugElementalInstanceContainer_EM.java b/src/main/java/com/github/technus/tectech/thing/item/DebugElementalInstanceContainer_EM.java index ab6f06497e..3eb71abca1 100644 --- a/src/main/java/com/github/technus/tectech/thing/item/DebugElementalInstanceContainer_EM.java +++ b/src/main/java/com/github/technus/tectech/thing/item/DebugElementalInstanceContainer_EM.java @@ -84,7 +84,8 @@ public final class DebugElementalInstanceContainer_EM extends Item implements IE public ItemStack setContent(ItemStack aStack,cElementalInstanceStackMap content){ NBTTagCompound tNBT = aStack.getTagCompound(); if(tNBT==null){ - aStack.setTagCompound(new NBTTagCompound()); + tNBT=new NBTTagCompound(); + aStack.setTagCompound(tNBT); } if (tNBT.hasKey("content")) { try { diff --git a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_InputDataItems.java b/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_InputDataItems.java index 80498ed8df..df7f5e07d6 100644 --- a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_InputDataItems.java +++ b/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_InputDataItems.java @@ -19,6 +19,7 @@ import net.minecraft.util.EnumChatFormatting; import java.util.ArrayList; import static com.github.technus.tectech.CommonValues.MOVE_AT; +import static com.github.technus.tectech.recipe.TT_recipeAdder.nullItem; import static com.github.technus.tectech.thing.metaTileEntity.hatch.GT_MetaTileEntity_Hatch_DataConnector.*; import static gregtech.api.enums.Dyes.MACHINE_METAL; @@ -168,7 +169,7 @@ public class GT_MetaTileEntity_Hatch_InputDataItems extends GT_MetaTileEntity_Ha } } if(stacks.size()>0) { - this.stacks = stacks.toArray(new ItemStack[0]); + this.stacks = stacks.toArray(nullItem); } } } diff --git a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_Rack.java b/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_Rack.java index 37cb66d97a..24b47ec90f 100644 --- a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_Rack.java +++ b/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/GT_MetaTileEntity_Hatch_Rack.java @@ -222,10 +222,10 @@ public class GT_MetaTileEntity_Hatch_Rack extends GT_MetaTileEntity_Hatch { heat -= Math.min(heat / 1000, -1); } - if (heat > 9000) { - aBaseMetaTileEntity.setOnFire(); - } else if (heat > 10000) { + if (heat > 10000) { aBaseMetaTileEntity.setToFire(); + } else if (heat > 9000) { + aBaseMetaTileEntity.setOnFire(); } else if (heat < -10000) { heat = -10000; } diff --git a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/gui/GT_Container_Rack.java b/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/gui/GT_Container_Rack.java index 1ce14585bc..16b38e254f 100644 --- a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/hatch/gui/GT_Container_Rack.j |
