Fix Gas Generator item gas tank restoration.

This commit is contained in:
Ben Spiers 2014-08-28 20:00:56 +01:00
parent e16a39912e
commit e3fc694532
2 changed files with 2 additions and 2 deletions

View file

@ -84,7 +84,7 @@ public class GasStack
GasStack stack = new GasStack();
stack.read(nbtTags);
if(stack.getGas() == null)
if(stack.getGas() == null || stack.amount <= 0)
{
return null;
}

View file

@ -290,6 +290,6 @@ public class TileEntityGasGenerator extends TileEntityGenerator implements IGasH
@Override
public void readSustainedData(ItemStack itemStack)
{
fuelTank.setGas(GasStack.readFromNBT(itemStack.stackTagCompound.getCompoundTag("fuelTank")));
fuelTank.read(itemStack.stackTagCompound.getCompoundTag("fuelTank"));
}
}