diff --git a/src/main/java/techreborn/compat/recipes/RecipesIC2.java b/src/main/java/techreborn/compat/recipes/RecipesIC2.java index c4a5e8bb2..7a3d03bbe 100644 --- a/src/main/java/techreborn/compat/recipes/RecipesIC2.java +++ b/src/main/java/techreborn/compat/recipes/RecipesIC2.java @@ -117,13 +117,20 @@ public class RecipesIC2 implements ICompatModule { 'I', "plateInvar", 'H', IC2Items.getItem("reinforcedGlass"), 'C', "circuitBasic", - 'G', IC2Items.getItem("geothermalGenerator")); + 'G', new ItemStack(ModBlocks.heatGenerator)); CraftingHelper.addShapedOreRecipe(new ItemStack(ModBlocks.thermalGenerator), "AAA", "AHA", "CGC", 'A', "plateAluminum", 'H', IC2Items.getItem("reinforcedGlass"), 'C', "circuitBasic", + 'G', new ItemStack(ModBlocks.heatGenerator)); + + CraftingHelper.addShapedOreRecipe(new ItemStack(ModBlocks.heatGenerator), + "III", "IHI", "CGC", + 'I', "plateIron", + 'H', new ItemStack(Blocks.iron_bars), + 'C', "circuitBasic", 'G', IC2Items.getItem("geothermalGenerator")); CraftingHelper.addShapedOreRecipe(new ItemStack(ModBlocks.Gasturbine), diff --git a/src/main/java/techreborn/tiles/TileThermalGenerator.java b/src/main/java/techreborn/tiles/TileThermalGenerator.java index 76033c146..6e6f7216c 100644 --- a/src/main/java/techreborn/tiles/TileThermalGenerator.java +++ b/src/main/java/techreborn/tiles/TileThermalGenerator.java @@ -3,6 +3,7 @@ package techreborn.tiles; import ic2.api.energy.tile.IEnergyTile; import ic2.api.tile.IWrenchable; import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.init.Blocks; import net.minecraft.inventory.IInventory; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; @@ -136,8 +137,15 @@ public class TileThermalGenerator extends TilePowerAcceptor implements IWrenchab @Override public void updateEntity() { super.updateEntity(); - if (!worldObj.isRemote) + if (!worldObj.isRemote){ FluidUtils.drainContainers(this, inventory, 0, 1); + for(ForgeDirection direction : ForgeDirection.VALID_DIRECTIONS){ + if (worldObj.getBlock(xCoord + direction.offsetX, yCoord + direction.offsetY, zCoord + direction.offsetZ) == Blocks.lava) { + addEnergy(euTick); + } + } + } + if (tank.getFluidAmount() > 0 && getMaxPower() - getEnergy() >= euTick) { tank.drain(1, true);