Not Enough Config
This commit is contained in:
parent
be710bfa06
commit
ef419cc574
14 changed files with 38 additions and 15 deletions
|
@ -20,6 +20,7 @@ package com.teammoeg.steampowered.content.boiler;
|
|||
|
||||
import com.simibubi.create.content.contraptions.goggles.IHaveGoggleInformation;
|
||||
import com.teammoeg.steampowered.FluidRegistry;
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
import com.teammoeg.steampowered.content.burner.IHeatReceiver;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.fluid.Fluids;
|
||||
|
@ -157,9 +158,11 @@ public abstract class BoilerTileEntity extends TileEntity implements IHeatReceiv
|
|||
if (this.level != null && !this.level.isClientSide) {
|
||||
int consume = Math.min(getHUPerTick(), heatreceived);
|
||||
heatreceived = 0;
|
||||
consume = Math.min(this.input.drain(consume / 120, FluidAction.EXECUTE).getAmount() * 120, consume);
|
||||
int waterconsume=(int) (SPConfig.COMMON.steamPerWater.get()*10);
|
||||
consume = Math.min(this.input.drain((int) Math.ceil(consume / waterconsume), FluidAction.EXECUTE).getAmount() * waterconsume, consume);
|
||||
this.output.fill(new FluidStack(FluidRegistry.steam.get().getFluid(), consume / 10), FluidAction.EXECUTE);
|
||||
this.level.sendBlockUpdated(this.getBlockPos(), this.level.getBlockState(this.getBlockPos()), this.level.getBlockState(this.getBlockPos()), 3);
|
||||
|
||||
this.level.sendBlockUpdated(this.getBlockPos(),this.getBlockState(),this.getBlockState(), 3);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.boiler;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
import com.teammoeg.steampowered.registrate.SPTiles;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
@ -35,6 +36,6 @@ public class BronzeBoilerBlock extends BoilerBlock {
|
|||
|
||||
@Override
|
||||
public int getHuConsume() {
|
||||
return 120;
|
||||
return SPConfig.COMMON.bronzeBoilerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.boiler;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
|
||||
public class BronzeBoilerTileEntity extends BoilerTileEntity {
|
||||
|
@ -27,7 +29,7 @@ public class BronzeBoilerTileEntity extends BoilerTileEntity {
|
|||
}
|
||||
|
||||
protected int getHUPerTick() {
|
||||
return 120;
|
||||
return SPConfig.COMMON.bronzeBoilerHU.get();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.boiler;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
import com.teammoeg.steampowered.registrate.SPTiles;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
@ -35,6 +36,6 @@ public class CastIronBoilerBlock extends BoilerBlock {
|
|||
|
||||
@Override
|
||||
public int getHuConsume() {
|
||||
return 240;
|
||||
return SPConfig.COMMON.castIronBoilerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.boiler;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
|
||||
public class CastIronBoilerTileEntity extends BoilerTileEntity {
|
||||
|
@ -27,7 +29,7 @@ public class CastIronBoilerTileEntity extends BoilerTileEntity {
|
|||
}
|
||||
|
||||
protected int getHUPerTick() {
|
||||
return 240;
|
||||
return SPConfig.COMMON.castIronBoilerHU.get();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.boiler;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
import com.teammoeg.steampowered.registrate.SPTiles;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
@ -35,6 +36,6 @@ public class SteelBoilerBlock extends BoilerBlock {
|
|||
|
||||
@Override
|
||||
public int getHuConsume() {
|
||||
return 480;
|
||||
return SPConfig.COMMON.steelBoilerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.boiler;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
|
||||
public class SteelBoilerTileEntity extends BoilerTileEntity {
|
||||
|
@ -27,7 +29,7 @@ public class SteelBoilerTileEntity extends BoilerTileEntity {
|
|||
}
|
||||
|
||||
protected int getHUPerTick() {
|
||||
return 480;
|
||||
return SPConfig.COMMON.steelBoilerHU.get();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.burner;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
import com.teammoeg.steampowered.registrate.SPTiles;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
@ -35,6 +36,6 @@ public class BronzeBurnerBlock extends BurnerBlock {
|
|||
|
||||
@Override
|
||||
public int getHuProduce() {
|
||||
return 120;
|
||||
return SPConfig.COMMON.bronzeBurnerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.burner;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
|
||||
public class BronzeBurnerTileEntity extends BurnerTileEntity {
|
||||
|
@ -28,6 +30,6 @@ public class BronzeBurnerTileEntity extends BurnerTileEntity {
|
|||
|
||||
@Override
|
||||
protected int getHuPerTick() {
|
||||
return 120;
|
||||
return SPConfig.COMMON.bronzeBurnerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,6 +19,8 @@
|
|||
package com.teammoeg.steampowered.content.burner;
|
||||
|
||||
import com.simibubi.create.content.contraptions.goggles.IHaveGoggleInformation;
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.crafting.IRecipeType;
|
||||
|
@ -168,7 +170,7 @@ public abstract class BurnerTileEntity extends TileEntity implements ITickableTi
|
|||
int time = ForgeHooks.getBurnTime(inv.getStackInSlot(0), IRecipeType.SMELTING);
|
||||
if (time <= 0) return false;
|
||||
inv.getStackInSlot(0).shrink(1);
|
||||
HURemain += time * 24;//2.4HU/t
|
||||
HURemain += time * SPConfig.COMMON.HUPerFuelTick.get();//2.4HU/t
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.burner;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
import com.teammoeg.steampowered.registrate.SPTiles;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
@ -35,6 +36,6 @@ public class CastIronBurnerBlock extends BurnerBlock {
|
|||
|
||||
@Override
|
||||
public int getHuProduce() {
|
||||
return 240;
|
||||
return SPConfig.COMMON.castIronBurnerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.burner;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
|
||||
public class CastIronBurnerTileEntity extends BurnerTileEntity {
|
||||
|
@ -28,6 +30,6 @@ public class CastIronBurnerTileEntity extends BurnerTileEntity {
|
|||
|
||||
@Override
|
||||
protected int getHuPerTick() {
|
||||
return 240;
|
||||
return SPConfig.COMMON.castIronBurnerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.burner;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
import com.teammoeg.steampowered.registrate.SPTiles;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
@ -35,6 +36,6 @@ public class SteelBurnerBlock extends BurnerBlock {
|
|||
|
||||
@Override
|
||||
public int getHuProduce() {
|
||||
return 480;
|
||||
return SPConfig.COMMON.steelBurnerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
|
||||
package com.teammoeg.steampowered.content.burner;
|
||||
|
||||
import com.teammoeg.steampowered.SPConfig;
|
||||
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
|
||||
public class SteelBurnerTileEntity extends BurnerTileEntity {
|
||||
|
@ -28,6 +30,6 @@ public class SteelBurnerTileEntity extends BurnerTileEntity {
|
|||
|
||||
@Override
|
||||
protected int getHuPerTick() {
|
||||
return 480;
|
||||
return SPConfig.COMMON.steelBurnerHU.get();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue