diff options
author | Draknyte1 <Draknyte1@hotmail.com> | 2016-12-27 15:06:11 +1000 |
---|---|---|
committer | Draknyte1 <Draknyte1@hotmail.com> | 2016-12-27 15:06:11 +1000 |
commit | 90d9503359ee81deb789bc359fa0c6dc0df14d2a (patch) | |
tree | 92a66bb114a63d73414bdcd4b2ea52e3d6d55ab8 /src/Java/gtPlusPlus/core/material | |
parent | 687a884bbe3e47a5d50403b018605688d6bcef23 (diff) | |
download | GT5-Unofficial-90d9503359ee81deb789bc359fa0c6dc0df14d2a.tar.gz GT5-Unofficial-90d9503359ee81deb789bc359fa0c6dc0df14d2a.tar.bz2 GT5-Unofficial-90d9503359ee81deb789bc359fa0c6dc0df14d2a.zip |
% Moved the Nuclear composites to their own Classes. NUCLIDES & FLUORIDES
+ Moved most Nuclear components to the new classes, for readability and ease of use.
- Removed old instances of Nuclear Fuel components, not generated by my MaterialGenerator.java.
% Tweaked recipes to reflect new materials generated.
+ Enabled material generation for Nuclear materials, producing a very strict item output set.
+ Added U235/U238/Pu241/Pu244 to ELEMENT.java
% Changed all LFTR recipes to now output Uranium Hexafluoride, instead of straight U233.
Diffstat (limited to 'src/Java/gtPlusPlus/core/material')
-rw-r--r-- | src/Java/gtPlusPlus/core/material/ALLOY.java | 73 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/material/ELEMENT.java | 14 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/material/Material.java | 2 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/material/MaterialGenerator.java | 30 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/material/nuclear/FLUORIDES.java | 113 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/material/nuclear/NUCLIDE.java | 55 |
6 files changed, 208 insertions, 79 deletions
diff --git a/src/Java/gtPlusPlus/core/material/ALLOY.java b/src/Java/gtPlusPlus/core/material/ALLOY.java index a3d4946744..5e29a75725 100644 --- a/src/Java/gtPlusPlus/core/material/ALLOY.java +++ b/src/Java/gtPlusPlus/core/material/ALLOY.java @@ -1,6 +1,5 @@ package gtPlusPlus.core.material; -import gregtech.api.enums.Materials; public final class ALLOY { @@ -39,13 +38,13 @@ public final class ALLOY { "Staballoy", //Material Name new short[]{68, 75, 66, 0}, //Material Colour 3450, //Melting Point in C - ((ELEMENT.getInstance().URANIUM.getBoilingPointC()*9)+(ELEMENT.getInstance().TITANIUM.getBoilingPointC()*1))/10, //Boiling Point in C - ((ELEMENT.getInstance().URANIUM.getProtons()*9)+ELEMENT.getInstance().TITANIUM.getProtons())/10, //Protons - ((ELEMENT.getInstance().URANIUM.getNeutrons()*9)+ELEMENT.getInstance().TITANIUM.getNeutrons())/10, //Neutrons + ((ELEMENT.getInstance().URANIUM238.getBoilingPointC()*9)+(ELEMENT.getInstance().TITANIUM.getBoilingPointC()*1))/10, //Boiling Point in C + ((ELEMENT.getInstance().URANIUM238.getProtons()*9)+ELEMENT.getInstance().TITANIUM.getProtons())/10, //Protons + ((ELEMENT.getInstance().URANIUM238.getNeutrons()*9)+ELEMENT.getInstance().TITANIUM.getNeutrons())/10, //Neutrons true, //Uses Blast furnace? //Material Stacks with Percentage of required elements. new MaterialStack[]{ - new MaterialStack(ELEMENT.getInstance().URANIUM, 9), + new MaterialStack(ELEMENT.getInstance().URANIUM238, 9), new MaterialStack(ELEMENT.getInstance().TITANIUM, 1) }); @@ -501,70 +500,6 @@ public final class ALLOY { new MaterialStack(ELEMENT.getInstance().OXYGEN, 10) }); - public static final Material THORIUM_HEXAFLUORIDE = new Material( - "Thorium Hexafluoride", //Material Name - new short[]{10, 50, 10, 0}, //Material Colour - Materials.Thorium.mMeltingPoint, //Melting Point in C - Materials.Thorium.mBlastFurnaceTemp, //Boiling Point in C - ((ELEMENT.getInstance().THORIUM232.getProtons()+ELEMENT.getInstance().THORIUM232.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*6))/8), //Protons - ((ELEMENT.getInstance().THORIUM232.getNeutrons()+ELEMENT.getInstance().THORIUM232.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*6))/8), //Neutrons - false, //Uses Blast furnace? - //Material Stacks with Percentage of required elements. - new MaterialStack[]{ - new MaterialStack(ELEMENT.getInstance().THORIUM232, 1), - new MaterialStack(ELEMENT.getInstance().THORIUM, 1), - new MaterialStack(ELEMENT.getInstance().FLUORINE, 12) - }); - - public static final Material THORIUM_TETRAFLUORIDE = new Material( - "Thorium Tetrafluoride", //Material Name - new short[]{25, 70, 25, 0}, //Material Colour - Materials.Thorium.mMeltingPoint, //Melting Point in C - Materials.Thorium.mBlastFurnaceTemp, //Boiling Point in C - ((ELEMENT.getInstance().THORIUM232.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*4))/5), //Protons - ((ELEMENT.getInstance().THORIUM232.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*4))/5), //Neutrons - false, //Uses Blast furnace? - //Material Stacks with Percentage of required elements. - new MaterialStack[]{ - new MaterialStack(ELEMENT.getInstance().THORIUM232, 1), - new MaterialStack(ELEMENT.getInstance().FLUORINE, 4) - }); - - public static final Material LiFBeF2ZrF4U235 = new Material( - "Reactor Salt LiFBeF2ZrF4U235", //Material Name - new short[]{50, 70, 15, 0}, //Material Colour - 590, //Melting Point in C - 890, //Boiling Point in C - 150, //Protons - 150, //Neutrons - true, //Uses Blast furnace? - //Material Stacks with Percentage of required elements. - new MaterialStack[]{ - new MaterialStack(ELEMENT.getInstance().LITHIUM7, 1), - new MaterialStack(ELEMENT.getInstance().BERYLLIUM, 1), - new MaterialStack(ELEMENT.getInstance().ZIRCONIUM, 1), - new MaterialStack(ELEMENT.getInstance().URANIUM, 1), - new MaterialStack(ELEMENT.getInstance().FLUORINE, 6) - }); - - public static final Material LiFBeF2ThF4UF4 = new Material( - "Reactor Salt LiFBeF2ThF4UF4", //Material Name - new short[]{40, 90, 25, 0}, //Material Colour - 566, //Melting Point in C - 870, //Boiling Point in C - 150, //Protons - 150, //Neutrons - true, //Uses Blast furnace? - //Material Stacks with Percentage of required elements. - new MaterialStack[]{ - new MaterialStack(ELEMENT.getInstance().LITHIUM7, 1), - new MaterialStack(ELEMENT.getInstance().BERYLLIUM, 1), - new MaterialStack(ALLOY.THORIUM_TETRAFLUORIDE, 1), - new MaterialStack(ELEMENT.getInstance().URANIUM233, 1), - new MaterialStack(ELEMENT.getInstance().FLUORINE, 6) - }); - - public static final Material LEAGRISIUM = new Material( "Grisium", //Material Name new short[]{53, 93, 106, 0}, //Material Colour diff --git a/src/Java/gtPlusPlus/core/material/ELEMENT.java b/src/Java/gtPlusPlus/core/material/ELEMENT.java index 8933055668..19b17fa333 100644 --- a/src/Java/gtPlusPlus/core/material/ELEMENT.java +++ b/src/Java/gtPlusPlus/core/material/ELEMENT.java @@ -87,17 +87,13 @@ public final class ELEMENT { public final Material RADON = MaterialUtils.generateMaterialFromGtENUM(Materials.Radon); public final Material THORIUM = new Material("Thorium", Materials.Thorium.mRGBa, Materials.Thorium.mMeltingPoint, Materials.Thorium.mBlastFurnaceTemp, 90, 142, false, MaterialUtils.superscript("Th"), 1); /*MaterialUtils.generateMaterialFromGtENUM(Materials.Thorium);*/ - public final Material URANIUM = MaterialUtils.generateMaterialFromGtENUM(Materials.Uranium); - public final Material PLUTONIUM = MaterialUtils.generateMaterialFromGtENUM(Materials.Plutonium); + public final Material URANIUM238 = MaterialUtils.generateMaterialFromGtENUM(Materials.Uranium); + public final Material URANIUM235 = MaterialUtils.generateMaterialFromGtENUM(Materials.Uranium235); + public final Material PLUTONIUM244 = MaterialUtils.generateMaterialFromGtENUM(Materials.Plutonium); + public final Material PLUTONIUM241 = MaterialUtils.generateMaterialFromGtENUM(Materials.Plutonium241); + - //Custom Isotopes - public final Material LITHIUM7 = new Material("Lithium 7", Materials.Lithium.mRGBa, Materials.Lithium.mMeltingPoint, Materials.Lithium.mBlastFurnaceTemp, Materials.Lithium.getProtons(), Materials.Lithium.getNeutrons(), Materials.Lithium.mBlastFurnaceRequired, MaterialUtils.superscript("7Li"), 0);//Not a GT Inherited Material - public final Material URANIUM232 = new Material("Uranium 232", new short[]{88, 220, 103, 0}, 1132, 4131, 92, 140, false, MaterialUtils.superscript("232U"), 4);//Not a GT Inherited Material - public final Material URANIUM233 = new Material("Uranium 233", new short[]{73, 220, 83, 0}, 1132, 4131, 92, 141, false, MaterialUtils.superscript("233U"), 2);//Not a GT Inherited Material - - public final Material THORIUM232 = new Material("Thorium 232", new short[]{15, 60, 15, 0}, Materials.Thorium.mMeltingPoint, Materials.Thorium.mBlastFurnaceTemp, 90, 142, false, MaterialUtils.superscript("232Th"), 1);//Not a GT Inherited Material - //public final Material THORIUMTETRAFLUORIDE = new Material("Thorium Tetrafluoride", Materials.Thorium.mRGBa, Materials.Thorium.mMeltingPoint, Materials.Thorium.mBlastFurnaceTemp, Materials.Thorium.getProtons(), Materials.Thorium.getNeutrons(), false, MaterialUtils.superscript("Th"), 1);//Not a GT Inherited Material //Misc diff --git a/src/Java/gtPlusPlus/core/material/Material.java b/src/Java/gtPlusPlus/core/material/Material.java index 0ff2037c99..b590b8b1c0 100644 --- a/src/Java/gtPlusPlus/core/material/Material.java +++ b/src/Java/gtPlusPlus/core/material/Material.java @@ -238,7 +238,7 @@ public class Material { final public ItemStack getBlock(int stacksize){ return ItemUtils.getItemStackOfAmountFromOreDictNoBroken("block"+unlocalizedName, stacksize); } - + final public ItemStack getDust(int stacksize){ return ItemUtils.getItemStackOfAmountFromOreDictNoBroken("dust"+unlocalizedName, stacksize); } diff --git a/src/Java/gtPlusPlus/core/material/MaterialGenerator.java b/src/Java/gtPlusPlus/core/material/MaterialGenerator.java index 17640e7eb2..eb70191d78 100644 --- a/src/Java/gtPlusPlus/core/material/MaterialGenerator.java +++ b/src/Java/gtPlusPlus/core/material/MaterialGenerator.java @@ -107,4 +107,34 @@ public class MaterialGenerator { } + public static void generateNuclearMaterial(final Material matInfo){ + String unlocalizedName = matInfo.getUnlocalizedName(); + String materialName = matInfo.getLocalizedName(); + short[] C = matInfo.getRGBA(); + int Colour = Utils.rgbtoHexValue(C[0], C[1], C[2]); + + int sRadiation = 0; + if (matInfo.vRadioationLevel != 0){ + sRadiation = matInfo.vRadioationLevel; + } + + Item temp; + Block tempBlock; + + tempBlock = new BlockBaseModular(unlocalizedName, materialName,BlockTypes.STANDARD, Colour); + temp = new BaseItemIngot("itemIngot"+unlocalizedName, materialName, Colour, sRadiation); + temp = new BaseItemDust("itemDust"+unlocalizedName, materialName, matInfo, Colour, "Dust", 3, sRadiation); + temp = new BaseItemDust("itemDustTiny"+unlocalizedName, materialName, matInfo, Colour, "Tiny", 2, sRadiation); + temp = new BaseItemDust("itemDustSmall"+unlocalizedName, materialName, matInfo, Colour, "Small", 1, sRadiation); + temp = new BaseItemNugget(matInfo); + temp = new BaseItemPlate(matInfo); + temp = new BaseItemPlateDouble(matInfo); + + RecipeGen_Plates.generateRecipes(matInfo); + RecipeGen_Extruder.generateRecipes(matInfo); + RecipeGen_ShapedCrafting.generateRecipes(matInfo); + RecipeGen_DustGeneration.generateRecipes(matInfo, true); + } + + } diff --git a/src/Java/gtPlusPlus/core/material/nuclear/FLUORIDES.java b/src/Java/gtPlusPlus/core/material/nuclear/FLUORIDES.java new file mode 100644 index 0000000000..15e5578d48 --- /dev/null +++ b/src/Java/gtPlusPlus/core/material/nuclear/FLUORIDES.java @@ -0,0 +1,113 @@ +package gtPlusPlus.core.material.nuclear; + +import gregtech.api.enums.Materials; +import gtPlusPlus.core.material.*; + +public class FLUORIDES { + + private static final FLUORIDES thisClass = new FLUORIDES(); + public FLUORIDES(){} + public static FLUORIDES getInstance(){return thisClass;} + + public static final Material THORIUM_TETRAFLUORIDE = new Material( + "Thorium Tetrafluoride", //Material Name + new short[]{25, 70, 25, 0}, //Material Colour + Materials.Thorium.mMeltingPoint, //Melting Point in C + Materials.Thorium.mBlastFurnaceTemp, //Boiling Point in C + ((NUCLIDE.getInstance().THORIUM232.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*4))/5), //Protons + ((NUCLIDE.getInstance().THORIUM232.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*4))/5), //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(NUCLIDE.getInstance().THORIUM232, 1), + new MaterialStack(ELEMENT.getInstance().FLUORINE, 4) + }); + + public static final Material THORIUM_HEXAFLUORIDE = new Material( + "Thorium Hexafluoride", //Material Name + new short[]{10, 50, 10, 0}, //Material Colour + Materials.Thorium.mMeltingPoint, //Melting Point in C + Materials.Thorium.mBlastFurnaceTemp, //Boiling Point in C + ((NUCLIDE.getInstance().THORIUM232.getProtons()+NUCLIDE.getInstance().THORIUM232.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*6))/8), //Protons + ((NUCLIDE.getInstance().THORIUM232.getNeutrons()+NUCLIDE.getInstance().THORIUM232.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*6))/8), //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(NUCLIDE.getInstance().THORIUM232, 1), + new MaterialStack(ELEMENT.getInstance().THORIUM, 1), + new MaterialStack(ELEMENT.getInstance().FLUORINE, 12) + }); + + public static final Material URANIUM_TETRAFLUORIDE = new Material( + "Uranium Tetrafluoride", //Material Name + new short[]{50, 240, 50, 0}, //Material Colour + Materials.Uranium235.mMeltingPoint, //Melting Point in C + Materials.Uranium235.mBlastFurnaceTemp, //Boiling Point in C + ((NUCLIDE.getInstance().URANIUM233.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*4))/5), //Protons + ((NUCLIDE.getInstance().URANIUM233.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*4))/5), //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(NUCLIDE.getInstance().URANIUM233, 1), + new MaterialStack(ELEMENT.getInstance().FLUORINE, 4) + }); + + public static final Material URANIUM_HEXAFLUORIDE = new Material( + "Uranium Hexafluoride", //Material Name + new short[]{70, 250, 70, 0}, //Material Colour + Materials.Uranium235.mMeltingPoint, //Melting Point in C + Materials.Uranium235.mBlastFurnaceTemp, //Boiling Point in C + ((FLUORIDES.URANIUM_TETRAFLUORIDE.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*2))/3), //Protons + ((FLUORIDES.URANIUM_TETRAFLUORIDE.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*2))/3), //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(FLUORIDES.URANIUM_TETRAFLUORIDE, 1), + new MaterialStack(ELEMENT.getInstance().FLUORINE, 2) + }); + + // + + public static final Material ZIRCONIUM_TETRAFLUORIDE = new Material( + "Zirconium Tetrafluoride", //Material Name + ELEMENT.getInstance().ZIRCONIUM.getRGBA(), //Material Colour + ELEMENT.getInstance().ZIRCONIUM.getMeltingPointC(), //Melting Point in C + ELEMENT.getInstance().ZIRCONIUM.getBoilingPointC(), //Boiling Point in C + ((ELEMENT.getInstance().ZIRCONIUM.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*4))/5), //Protons + ((ELEMENT.getInstance().ZIRCONIUM.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*4))/5), //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(ELEMENT.getInstance().ZIRCONIUM, 1), + new MaterialStack(ELEMENT.getInstance().FLUORINE, 4) + }); + + public static final Material BERYLLIUM_FLUORIDE = new Material( + "Beryllium Tetrafluoride", //Material Name + new short[]{120, 180, 120, 0}, //Material Colour + Materials.Beryllium.mMeltingPoint, //Melting Point in C + Materials.Beryllium.mBlastFurnaceTemp, //Boiling Point in C + ((ELEMENT.getInstance().BERYLLIUM.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()*2))/3), //Protons + ((ELEMENT.getInstance().BERYLLIUM.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()*2))/3), //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(ELEMENT.getInstance().BERYLLIUM, 1), + new MaterialStack(ELEMENT.getInstance().FLUORINE, 2) + }); + + public static final Material LITHIUM_FLUORIDE = new Material( + "Lithium Tetrafluoride", //Material Name + new short[]{225, 220, 255, 0}, //Material Colour + Materials.Lithium.mMeltingPoint, //Melting Point in C + Materials.Lithium.mBlastFurnaceTemp, //Boiling Point in C + ((NUCLIDE.getInstance().LITHIUM7.getProtons()+(ELEMENT.getInstance().FLUORINE.getProtons()))/2), //Protons + ((NUCLIDE.getInstance().LITHIUM7.getNeutrons()+(ELEMENT.getInstance().FLUORINE.getNeutrons()))/2), //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(NUCLIDE.getInstance().LITHIUM7, 1), + new MaterialStack(ELEMENT.getInstance().FLUORINE, 1) + }); + +} diff --git a/src/Java/gtPlusPlus/core/material/nuclear/NUCLIDE.java b/src/Java/gtPlusPlus/core/material/nuclear/NUCLIDE.java new file mode 100644 index 0000000000..fa48446c1c --- /dev/null +++ b/src/Java/gtPlusPlus/core/material/nuclear/NUCLIDE.java @@ -0,0 +1,55 @@ +package gtPlusPlus.core.material.nuclear; + +import gregtech.api.enums.Materials; +import gtPlusPlus.core.material.*; +import gtPlusPlus.core.util.materials.MaterialUtils; + + +public final class NUCLIDE { + + private static final NUCLIDE thisClass = new NUCLIDE(); + public NUCLIDE(){} + public static NUCLIDE getInstance(){return thisClass;} + + //Custom Isotopes + public final Material LITHIUM7 = new Material("Lithium 7", Materials.Lithium.mRGBa, Materials.Lithium.mMeltingPoint, Materials.Lithium.mBlastFurnaceTemp, Materials.Lithium.getProtons(), Materials.Lithium.getNeutrons(), Materials.Lithium.mBlastFurnaceRequired, MaterialUtils.superscript("7Li"), 0);//Not a GT Inherited Material + public final Material URANIUM232 = new Material("Uranium 232", new short[]{88, 220, 103, 0}, 1132, 4131, 92, 140, false, MaterialUtils.superscript("232U"), 4);//Not a GT Inherited Material + public final Material URANIUM233 = new Material("Uranium 233", new short[]{73, 220, 83, 0}, 1132, 4131, 92, 141, false, MaterialUtils.superscript("233U"), 2);//Not a GT Inherited Material + public final Material THORIUM232 = new Material("Thorium 232", new short[]{15, 60, 15, 0}, Materials.Thorium.mMeltingPoint, Materials.Thorium.mBlastFurnaceTemp, 90, 142, false, MaterialUtils.superscript("232Th"), 1);//Not a GT Inherited Material + + + + public static final Material LiFBeF2ThF4UF4 = new Material( + "Reactor Salt LiFBeF2ThF4UF4", //Material Name + new short[]{40, 90, 25, 0}, //Material Colour + 566, //Melting Point in C + 870, //Boiling Point in C + 150, //Protons + 150, //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(FLUORIDES.LITHIUM_FLUORIDE, 65), + new MaterialStack(FLUORIDES.BERYLLIUM_FLUORIDE, 28), + new MaterialStack(FLUORIDES.THORIUM_TETRAFLUORIDE, 1), + new MaterialStack(FLUORIDES.URANIUM_TETRAFLUORIDE, 1) + }); + + public static final Material LiFBeF2ZrF4U235 = new Material( + "Reactor Salt LiFBeF2ZrF4U235", //Material Name + new short[]{50, 70, 15, 0}, //Material Colour + 590, //Melting Point in C + 890, //Boiling Point in C + 150, //Protons + 150, //Neutrons + false, //Uses Blast furnace? + //Material Stacks with Percentage of required elements. + new MaterialStack[]{ + new MaterialStack(FLUORIDES.LITHIUM_FLUORIDE, 55), + new MaterialStack(FLUORIDES.BERYLLIUM_FLUORIDE, 25), + new MaterialStack(FLUORIDES.ZIRCONIUM_TETRAFLUORIDE, 6), + new MaterialStack(ELEMENT.getInstance().URANIUM235, 14) + }); + + +} |