diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipe.java | 15 | ||||
-rw-r--r-- | src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipeStorage.java | 30 |
2 files changed, 27 insertions, 18 deletions
diff --git a/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipe.java b/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipe.java index 3c3220928a..ae85d9dbf1 100644 --- a/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipe.java +++ b/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipe.java @@ -103,8 +103,8 @@ public class EyeOfHarmonyRecipe { this.recipeTriggerItem = new ItemStack(block); this.outputItems = validDustGenerator(materialList); - this.outputItems.sort(Comparator.comparingLong(ItemStackLong::getStackSize)); - Collections.reverse(this.outputItems); + // this.outputItems.sort(Comparator.comparingLong(ItemStackLong::getStackSize)); + // Collections.reverse(this.outputItems); this.sumOfItems = this.outputItems.stream().map(ItemStackLong::getStackSize).reduce(0L, Long::sum); @@ -142,18 +142,17 @@ public class EyeOfHarmonyRecipe { // Tier 9 - 2304 Universium if (rocketTierOfRecipe <= 3) { - fluidStackArrayList.add(Materials.WhiteDwarfMatter.getMolten(576L * pow(4, (int) rocketTierOfRecipe - 1))); + fluidStackArrayList.add(Materials.WhiteDwarfMatter.getMolten(576L * pow(4, (int) rocketTierOfRecipe))); } - if ((4 <= rocketTierOfRecipe) && (rocketTierOfRecipe <= 7)) { - fluidStackArrayList.add(Materials.BlackDwarfMatter.getMolten(576L * pow(4, (int) rocketTierOfRecipe))); + if ((4 <= rocketTierOfRecipe) && (rocketTierOfRecipe <= 7)) { + fluidStackArrayList.add(Materials.BlackDwarfMatter.getMolten(576L * pow(4, (int) rocketTierOfRecipe - 4))); } - if (rocketTierOfRecipe >= 8) { + if (rocketTierOfRecipe >= 8) { fluidStackArrayList.add(Materials.Universium.getMolten(576L * pow(4, (int) (rocketTierOfRecipe - 8)))); } - outputFluids = fluidStackArrayList; // End fluid processing. @@ -254,7 +253,7 @@ public class EyeOfHarmonyRecipe { private static final double QUATERNARY_MULTIPLIER = (0.7); // Mercury/chem bath processing chance. private static final double[] ORE_MULTIPLIER = { - PRIMARY_MULTIPLIER, SECONDARY_MULTIPLIER, TERTIARY_MULTIPLIER, QUATERNARY_MULTIPLIER + PRIMARY_MULTIPLIER, SECONDARY_MULTIPLIER, TERTIARY_MULTIPLIER, QUATERNARY_MULTIPLIER }; public static class HashMapHelper extends HashMap<Materials, Double> { diff --git a/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipeStorage.java b/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipeStorage.java index 091ec4f7f5..f9c5cfeed5 100644 --- a/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipeStorage.java +++ b/src/main/java/com/github/technus/tectech/recipe/EyeOfHarmonyRecipeStorage.java @@ -38,15 +38,27 @@ public class EyeOfHarmonyRecipeStorage { BlockDimensionDisplay blockDimensionDisplay = (BlockDimensionDisplay) ModBlocks.blocks.get(dimAbbreviation); - try { - if (dimAbbreviation.equals("DD")) { - specialDeepDarkRecipe(this, blockDimensionDisplay); - } else { + if (dimAbbreviation.equals("DD")) { + specialDeepDarkRecipe(this, blockDimensionDisplay); + } else { + + GT5OreLayerHelper.NormalOreDimensionWrapper normalOre = + GT5OreLayerHelper.dimToOreWrapper.getOrDefault(dimAbbreviation, null); + GT5OreSmallHelper.SmallOreDimensionWrapper smallOre = + GT5OreSmallHelper.dimToSmallOreWrapper.getOrDefault(dimAbbreviation, null); + + if ((normalOre == null) || (smallOre == null)) { + System.out.println(dimAbbreviation + + " dimension not found in dimToOreWrapper. Report error to GTNH team."); + continue; + } + + try { put( dimAbbreviation, new EyeOfHarmonyRecipe( - GT5OreLayerHelper.dimToOreWrapper.get(dimAbbreviation), - GT5OreSmallHelper.dimToSmallOreWrapper.get(dimAbbreviation), + normalOre, + smallOre, blockDimensionDisplay, 0.6 + blockDimensionDisplay.getDimensionRocketTier() / 10.0, BILLION * (blockDimensionDisplay.getDimensionRocketTier() + 1), @@ -54,11 +66,9 @@ public class EyeOfHarmonyRecipeStorage { timeCalculator(blockDimensionDisplay.getDimensionRocketTier()), blockDimensionDisplay.getDimensionRocketTier(), 1.0 - blockDimensionDisplay.getDimensionRocketTier() / 10.0)); + } catch (Exception e) { + e.printStackTrace(); } - } catch (Exception e) { - e.printStackTrace(); - System.out.println( - dimAbbreviation + " dimension not found in dimToOreWrapper. Report error to GTNH team."); } } } |