Added Oil Burn config
This commit is contained in:
parent
7b818ec45c
commit
77b92a8ce9
3 changed files with 8 additions and 6 deletions
|
@ -84,6 +84,7 @@ public class BuildCraftEnergy {
|
|||
public static Item fuel;
|
||||
public static LiquidStack oilLiquid;
|
||||
public static LiquidStack fuelLiquid;
|
||||
public static boolean canOilBurn;
|
||||
public static TreeMap<BlockIndex, Integer> saturationStored = new TreeMap<BlockIndex, Integer>();
|
||||
public static BCTrigger triggerBlueEngineHeat = new TriggerEngineHeat(DefaultProps.TRIGGER_BLUE_ENGINE_HEAT, EnergyStage.Blue);
|
||||
public static BCTrigger triggerGreenEngineHeat = new TriggerEngineHeat(DefaultProps.TRIGGER_GREEN_ENGINE_HEAT, EnergyStage.Green);
|
||||
|
@ -102,6 +103,7 @@ public class BuildCraftEnergy {
|
|||
Property itemFuelId = BuildCraftCore.mainConfiguration.get(Configuration.CATEGORY_ITEM, "fuel.id", DefaultProps.FUEL_ID);
|
||||
Property oilDesertBiomeId = BuildCraftCore.mainConfiguration.get("biomes", "oilDesert", 160);
|
||||
Property oilOceanBiomeId = BuildCraftCore.mainConfiguration.get("biomes", "oilOcean", 161);
|
||||
canOilBurn = BuildCraftCore.mainConfiguration.get(Configuration.CATEGORY_GENERAL, "burnOil", true, "Can oil burn?").getBoolean(true);
|
||||
BuildCraftCore.mainConfiguration.save();
|
||||
|
||||
class BiomeIdException extends RuntimeException {
|
||||
|
|
|
@ -304,7 +304,7 @@ public class BlockOilFlowing extends BlockFlowing implements ILiquid {
|
|||
|
||||
@Override
|
||||
public int getFireSpreadSpeed(World world, int x, int y, int z, int metadata, ForgeDirection face) {
|
||||
return 300;
|
||||
return BuildCraftEnergy.canOilBurn ? 300 : 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -314,11 +314,11 @@ public class BlockOilFlowing extends BlockFlowing implements ILiquid {
|
|||
|
||||
@Override
|
||||
public boolean isFlammable(IBlockAccess world, int x, int y, int z, int metadata, ForgeDirection face) {
|
||||
return true;
|
||||
return BuildCraftEnergy.canOilBurn;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isFireSource(World world, int x, int y, int z, int metadata, ForgeDirection side) {
|
||||
return true;
|
||||
return BuildCraftEnergy.canOilBurn;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -62,7 +62,7 @@ public class BlockOilStill extends BlockStationary implements ILiquid {
|
|||
|
||||
@Override
|
||||
public int getFireSpreadSpeed(World world, int x, int y, int z, int metadata, ForgeDirection face) {
|
||||
return 300;
|
||||
return BuildCraftEnergy.canOilBurn ? 300 : 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -72,11 +72,11 @@ public class BlockOilStill extends BlockStationary implements ILiquid {
|
|||
|
||||
@Override
|
||||
public boolean isFlammable(IBlockAccess world, int x, int y, int z, int metadata, ForgeDirection face) {
|
||||
return true;
|
||||
return BuildCraftEnergy.canOilBurn;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isFireSource(World world, int x, int y, int z, int metadata, ForgeDirection side) {
|
||||
return true;
|
||||
return BuildCraftEnergy.canOilBurn;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue