Merge remote-tracking branch 'origin/1.12' into 1.12

This commit is contained in:
modmuss50 2018-07-26 18:28:58 +01:00
commit 88e116d095
No known key found for this signature in database
GPG key ID: 773D17BE8BF49C82
3 changed files with 24 additions and 26 deletions

View file

@ -131,22 +131,22 @@ public class TechRebornJeiPlugin implements IModPlugin {
MinecraftForge.EVENT_BUS.register(TechRebornJeiPlugin.class);
}
private static void addDebugRecipes(final IModRegistry registry) {
final ItemStack diamondBlock = new ItemStack(Blocks.DIAMOND_BLOCK);
final ItemStack dirtBlock = new ItemStack(Blocks.DIRT);
final List<Object> debugRecipes = new ArrayList<>();
private static void addDebugRecipes(IModRegistry registry) {
ItemStack diamondBlock = new ItemStack(Blocks.DIAMOND_BLOCK);
ItemStack dirtBlock = new ItemStack(Blocks.DIRT);
List<Object> debugRecipes = new ArrayList<>();
for (int i = 0; i < 10; i++) {
final int time = (int) Math.round(200 + Math.random() * 100);
final AssemblingMachineRecipe assemblingMachineRecipe = new AssemblingMachineRecipe(diamondBlock, diamondBlock,
dirtBlock, time, 120);
int time = (int) Math.round(200 + Math.random() * 100);
AssemblingMachineRecipe assemblingMachineRecipe = new AssemblingMachineRecipe(diamondBlock, diamondBlock,
dirtBlock, time, 120);
debugRecipes.add(assemblingMachineRecipe);
}
registry.addRecipes(debugRecipes, RecipeCategoryUids.ASSEMBLING_MACHINE);
debugRecipes.clear();
for (int i = 0; i < 10; i++) {
final int time = (int) Math.round(200 + Math.random() * 100);
final ImplosionCompressorRecipe recipe = new ImplosionCompressorRecipe(diamondBlock, diamondBlock, dirtBlock,
dirtBlock, time, 120);
int time = (int) Math.round(200 + Math.random() * 100);
ImplosionCompressorRecipe recipe = new ImplosionCompressorRecipe(diamondBlock, diamondBlock, dirtBlock,
dirtBlock, time, 120);
debugRecipes.add(recipe);
}
registry.addRecipes(debugRecipes, RecipeCategoryUids.IMPLOSION_COMPRESSOR);
@ -173,7 +173,7 @@ public class TechRebornJeiPlugin implements IModPlugin {
registry.addRecipeCategories(new VacuumFreezerRecipeCategory(guiHelper));
registry.addRecipeCategories(new FluidReplicatorRecipeCategory(guiHelper));
for (final EFluidGenerator type : EFluidGenerator.values())
for (EFluidGenerator type : EFluidGenerator.values())
registry.addRecipeCategories(new FluidGeneratorRecipeCategory(type, guiHelper));
if (CompatConfigs.showScrapbox) {
@ -188,7 +188,7 @@ public class TechRebornJeiPlugin implements IModPlugin {
@SuppressWarnings("deprecation")
@Override
public void register(@Nonnull final IModRegistry registry) {
public void register(@Nonnull IModRegistry registry) {
final IJeiHelpers jeiHelpers = registry.getJeiHelpers();
jeiHelpers.getIngredientBlacklist().addIngredientToBlacklist(new ItemStack(ModFluids.BLOCK_BERYLLIUM));
@ -233,7 +233,7 @@ public class TechRebornJeiPlugin implements IModPlugin {
}
if (IC2Duplicates.deduplicate()) {
for (final IC2Duplicates duplicate : IC2Duplicates.values()) {
for (IC2Duplicates duplicate : IC2Duplicates.values()) {
if (duplicate.hasIC2Stack()) {
jeiHelpers.getIngredientBlacklist().addIngredientToBlacklist(duplicate.getTrStack());
}
@ -275,7 +275,7 @@ public class TechRebornJeiPlugin implements IModPlugin {
registry.handleRecipes(ShapedOreRecipe.class, recipe -> new RollingMachineRecipeWrapper((IRecipeWrapper) recipe), RecipeCategoryUids.ROLLING_MACHINE);
registry.handleRecipes(ShapelessOreRecipe.class, recipe -> new RollingMachineRecipeWrapper((IRecipeWrapper) recipe), RecipeCategoryUids.ROLLING_MACHINE);
for (final EFluidGenerator type : EFluidGenerator.values()) {
for (EFluidGenerator type : EFluidGenerator.values()) {
registry.handleRecipes(FluidGeneratorRecipe.class, recipe -> new FluidGeneratorRecipeWrapper(jeiHelpers, recipe), type.getRecipeID());
}

View file

@ -24,9 +24,8 @@
package techreborn.tiles.multiblock;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.util.math.BlockPos;
import reborncore.common.recipes.RecipeCrafter;
import reborncore.common.registration.RebornRegistry;
@ -66,10 +65,10 @@ public class TileDistillationTower extends TileGenericMachine implements IContai
final boolean layer1 = multiblockChecker.checkRingY(1, 1, MultiblockChecker.ADVANCED_CASING, new BlockPos(0, 1, 0));
final boolean layer2 = multiblockChecker.checkRingY(1, 1, MultiblockChecker.STANDARD_CASING, new BlockPos(0, 2, 0));
final boolean layer3 = multiblockChecker.checkRectY(1, 1, MultiblockChecker.ADVANCED_CASING, new BlockPos(0, 3, 0));
final Block centerBlock1 = multiblockChecker.getBlock(0, 1, 0).getBlock();
final Block centerBlock2 = multiblockChecker.getBlock(0, 2, 0).getBlock();
final boolean center1 = (centerBlock1 == Blocks.AIR);
final boolean center2 = (centerBlock2 == Blocks.AIR);
final Material centerBlock1 = multiblockChecker.getBlock(0, 1, 0).getMaterial();
final Material centerBlock2 = multiblockChecker.getBlock(0, 2, 0).getMaterial();
final boolean center1 = (centerBlock1 == Material.AIR);
final boolean center2 = (centerBlock2 == Material.AIR);
return layer0 && layer1 && layer2 && layer3 && center1 && center2;
}

View file

@ -24,9 +24,8 @@
package techreborn.tiles.multiblock;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.network.NetworkManager;
import net.minecraft.network.play.server.SPacketUpdateTileEntity;
import net.minecraft.tileentity.TileEntity;
@ -112,10 +111,10 @@ public class TileIndustrialBlastFurnace extends TileGenericMachine implements IC
final boolean layer1 = multiblockChecker.checkRingY(1, 1, MultiblockChecker.CASING_ANY, new BlockPos(0, 1, 0));
final boolean layer2 = multiblockChecker.checkRingY(1, 1, MultiblockChecker.CASING_ANY, new BlockPos(0, 2, 0));
final boolean layer3 = multiblockChecker.checkRectY(1, 1, MultiblockChecker.CASING_ANY, new BlockPos(0, 3, 0));
final Block centerBlock1 = multiblockChecker.getBlock(0, 1, 0).getBlock();
final Block centerBlock2 = multiblockChecker.getBlock(0, 2, 0).getBlock();
final boolean center1 = (centerBlock1 == Blocks.AIR || centerBlock1 == Blocks.LAVA);
final boolean center2 = (centerBlock2 == Blocks.AIR || centerBlock2 == Blocks.LAVA);
final Material centerBlock1 = multiblockChecker.getBlock(0, 1, 0).getMaterial();
final Material centerBlock2 = multiblockChecker.getBlock(0, 2, 0).getMaterial();
final boolean center1 = (centerBlock1 == Material.AIR || centerBlock1 == Material.LAVA);
final boolean center2 = (centerBlock2 == Material.AIR || centerBlock2 == Material.LAVA);
return layer0 && layer1 && layer2 && layer3 && center1 && center2;
}