mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-27 23:33:08 +00:00
More gas changes
This commit is contained in:
1 parent
3d86b75da4
commit
acde30dee3
10 files changed
+41
-40
No files matched your search
@@ -4,11 +4,11 @@ import java.util.Map;
|
||||
|
||||
import mekanism.api.MekanismConfig.usage;
|
||||
import mekanism.api.gas.Gas;
|
||||
import mekanism.api.gas.GasRegistry;
|
||||
import mekanism.api.gas.GasStack;
|
||||
import mekanism.api.gas.GasTransmission;
|
||||
import mekanism.api.gas.IGasItem;
|
||||
import mekanism.common.MekanismBlocks;
|
||||
import mekanism.common.MekanismFluids;
|
||||
import mekanism.common.block.states.BlockStateMachine;
|
||||
import mekanism.common.recipe.RecipeHandler.Recipe;
|
||||
import mekanism.common.recipe.machines.PurificationRecipe;
|
||||
@@ -33,9 +33,9 @@ public class TileEntityPurificationChamber extends TileEntityAdvancedElectricMac
|
||||
@Override
|
||||
public GasStack getItemGas(ItemStack itemstack)
|
||||
{
|
||||
if(itemstack.isItemEqual(new ItemStack(Items.FLINT))) return new GasStack(GasRegistry.getGas("oxygen"), 10);
|
||||
if(itemstack.isItemEqual(new ItemStack(Items.FLINT))) return new GasStack(MekanismFluids.Oxygen, 10);
|
||||
if(Block.getBlockFromItem(itemstack.getItem()) == MekanismBlocks.GasTank && ((IGasItem)itemstack.getItem()).getGas(itemstack) != null &&
|
||||
((IGasItem)itemstack.getItem()).getGas(itemstack).getGas() == GasRegistry.getGas("oxygen")) return new GasStack(GasRegistry.getGas("oxygen"), 1);
|
||||
((IGasItem)itemstack.getItem()).getGas(itemstack).getGas() == MekanismFluids.Oxygen) return new GasStack(MekanismFluids.Oxygen, 1);
|
||||
|
||||
return null;
|
||||
}
|
||||
@@ -43,7 +43,7 @@ public class TileEntityPurificationChamber extends TileEntityAdvancedElectricMac
|
||||
@Override
|
||||
public int receiveGas(EnumFacing side, GasStack stack, boolean doTransfer)
|
||||
{
|
||||
if(stack.getGas() == GasRegistry.getGas("oxygen"))
|
||||
if(stack.getGas() == MekanismFluids.Oxygen)
|
||||
{
|
||||
return gasTank.receive(stack, doTransfer);
|
||||
}
|
||||
@@ -54,7 +54,7 @@ public class TileEntityPurificationChamber extends TileEntityAdvancedElectricMac
|
||||
@Override
|
||||
public boolean canReceiveGas(EnumFacing side, Gas type)
|
||||
{
|
||||
return type == GasRegistry.getGas("oxygen");
|
||||
return type == MekanismFluids.Oxygen;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -62,7 +62,7 @@ public class TileEntityPurificationChamber extends TileEntityAdvancedElectricMac
|
||||
{
|
||||
if(!inventory.get(1).isEmpty() && gasTank.getNeeded() > 0 && inventory.get(1).getItem() instanceof IGasItem)
|
||||
{
|
||||
GasStack removed = GasTransmission.removeGas(inventory.get(1), GasRegistry.getGas("oxygen"), gasTank.getNeeded());
|
||||
GasStack removed = GasTransmission.removeGas(inventory.get(1), MekanismFluids.Oxygen, gasTank.getNeeded());
|
||||
gasTank.receive(removed, true);
|
||||
return;
|
||||
}
|
||||
@@ -79,7 +79,7 @@ public class TileEntityPurificationChamber extends TileEntityAdvancedElectricMac
|
||||
@Override
|
||||
public boolean isValidGas(Gas gas)
|
||||
{
|
||||
return gas == GasRegistry.getGas("oxygen");
|
||||
return gas == MekanismFluids.Oxygen;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in new issue
Block a user