diff options
author | Alkalus <draknyte1@hotmail.com> | 2017-09-03 18:38:44 +1000 |
---|---|---|
committer | Alkalus <draknyte1@hotmail.com> | 2017-09-03 18:38:44 +1000 |
commit | d37252418e361dc154fa33156755ec35dfc0c331 (patch) | |
tree | 88569f17ac4f0f8d8d9d35e5de54975fddc30a04 /src/Java/gtPlusPlus/core | |
parent | fc5766c06673ed0cfec511f23fd259f511fabdac (diff) | |
download | GT5-Unofficial-d37252418e361dc154fa33156755ec35dfc0c331.tar.gz GT5-Unofficial-d37252418e361dc154fa33156755ec35dfc0c331.tar.bz2 GT5-Unofficial-d37252418e361dc154fa33156755ec35dfc0c331.zip |
+ Made all Multiblocks handle their recipes different.
> They now have hard coded 20% speed bonuses over their single block counterparts and hard coded output chance bonuses.
> Multiblocks no longer require cells as input or output.
Diffstat (limited to 'src/Java/gtPlusPlus/core')
-rw-r--r-- | src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java | 5 | ||||
-rw-r--r-- | src/Java/gtPlusPlus/core/util/math/MathUtils.java | 4 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java b/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java index d6f2472fd0..3fad9c5ffb 100644 --- a/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java +++ b/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java @@ -16,6 +16,7 @@ import gtPlusPlus.core.recipe.*; import gtPlusPlus.core.util.Utils; import gtPlusPlus.core.util.item.ItemUtils; import gtPlusPlus.core.util.recipe.RecipeUtils; +import gtPlusPlus.xmod.gregtech.recipes.MultiblockRecipeMapHandler; import gtPlusPlus.xmod.gregtech.registration.gregtech.*; import net.minecraft.item.ItemStack; @@ -41,6 +42,10 @@ public class COMPAT_HANDLER { public static void registerGregtechMachines() { if (Gregtech) { + + //Register some custom recipe maps for any enabled multiblocks. + MultiblockRecipeMapHandler.run(); + new RECIPES_LaserEngraver(); GregtechEnergyBuffer.run(); GregtechLFTR.run(); diff --git a/src/Java/gtPlusPlus/core/util/math/MathUtils.java b/src/Java/gtPlusPlus/core/util/math/MathUtils.java index b61af67566..72969550e8 100644 --- a/src/Java/gtPlusPlus/core/util/math/MathUtils.java +++ b/src/Java/gtPlusPlus/core/util/math/MathUtils.java @@ -143,6 +143,10 @@ public class MathUtils { final double roundOff = Math.round(c * 100.00) / 100.00; return roundOff; } + + public static int findPercentageOfInt(int input, int percentage){ + return (int)(input*(percentage/100.0f)); + } //Smooth Rounding Function |