Updated Calclavia Core

This commit is contained in:
Calclavia 2014-02-03 13:09:29 +08:00
parent c643397864
commit 6219747cb2
3 changed files with 18 additions and 3 deletions

View file

@ -178,9 +178,7 @@ public class TileFirebox extends TileElectricalInventory implements IPacketRecei
*/
public long getRequiredBoilWaterEnergy()
{
int temperatureChange = 373 - ThermalPhysics.getTemperatureForCoordinate(worldObj, xCoord, zCoord);
int mass = ThermalPhysics.getMass(1000, 1);
return ThermalPhysics.getEnergyForTemperatureChange(mass, 4200, temperatureChange) + ThermalPhysics.getEnergyForStateChange(mass, 2257000);
return ThermalPhysics.getRequiredBoilWaterEnergy(worldObj, xCoord, zCoord);
}
public long getMeltIronEnergy(float volume)

View file

@ -3,9 +3,14 @@ package resonantinduction.core.prefab.part;
import java.util.ArrayList;
import java.util.List;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.item.ItemStack;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.World;
import codechicken.lib.render.CCRenderState;
import codechicken.lib.render.IconTransformation;
import codechicken.lib.render.RenderUtils;
import codechicken.lib.vec.Translation;
import codechicken.multipart.IRedstonePart;
import codechicken.multipart.TMultiPart;

View file

@ -1,5 +1,6 @@
package resonantinduction.mechanical.fluid.pipe;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
@ -18,6 +19,10 @@ import resonantinduction.core.prefab.part.PartFramedConnection;
import resonantinduction.mechanical.Mechanical;
import resonantinduction.mechanical.fluid.network.PipeNetwork;
import calclavia.lib.prefab.block.BlockAdvanced;
import codechicken.lib.render.CCRenderState;
import codechicken.lib.render.IconTransformation;
import codechicken.lib.render.RenderUtils;
import codechicken.lib.vec.Translation;
import codechicken.microblock.IHollowConnect;
import codechicken.multipart.JIconHitEffects;
import codechicken.multipart.JNormalOcclusion;
@ -213,6 +218,13 @@ public class PartPipe extends PartFramedConnection<EnumPipeMaterial, IFluidPipe,
return FluidContainerRegistry.BUCKET_VOLUME;
}
@Override
public void drawBreaking(RenderBlocks renderBlocks)
{
CCRenderState.reset();
RenderUtils.renderBlock(sides[6], 0, new Translation(x(), y(), z()), new IconTransformation(renderBlocks.overrideBlockTexture), null);
}
@Override
public void save(NBTTagCompound nbt)
{