Crash fix

This commit is contained in:
Aidan C. Brady 2015-04-10 08:34:02 -04:00
parent 174509444b
commit 5fec517a6d
2 changed files with 7 additions and 4 deletions

View file

@ -529,10 +529,12 @@ public class BlockMachine extends BlockContainer implements ISpecialBounds, IPer
for(Fluid f : FluidRegistry.getRegisteredFluids().values())
{
ItemStack filled = new ItemStack(item, 1, type.meta);
itemMachine.setFluidStack(new FluidStack(f, itemMachine.getCapacity(filled)), filled);
itemMachine.setPrevScale(filled, 1);
list.add(filled);
try { //Prevent bad IDs
ItemStack filled = new ItemStack(item, 1, type.meta);
itemMachine.setFluidStack(new FluidStack(f, itemMachine.getCapacity(filled)), filled);
itemMachine.setPrevScale(filled, 1);
list.add(filled);
} catch(Exception e) {}
}
}

View file

@ -204,6 +204,7 @@ public abstract class TileEntityAdvancedElectricMachine<RECIPE extends AdvancedM
}
prevEnergy = getEnergy();
if(!(gasTank.getGasType() == null || gasTank.getStored() == 0))
{
prevGas = gasTank.getGasType();