Move configs to one class
This commit is contained in:
parent
9db1978410
commit
77eee6f5b4
76 changed files with 731 additions and 5583 deletions
|
@ -26,22 +26,19 @@ package techreborn;
|
||||||
|
|
||||||
import net.fabricmc.api.ModInitializer;
|
import net.fabricmc.api.ModInitializer;
|
||||||
import net.fabricmc.fabric.api.client.itemgroup.FabricItemGroupBuilder;
|
import net.fabricmc.fabric.api.client.itemgroup.FabricItemGroupBuilder;
|
||||||
import net.fabricmc.fabric.api.registry.CommandRegistry;
|
|
||||||
import net.minecraft.block.DispenserBlock;
|
import net.minecraft.block.DispenserBlock;
|
||||||
import net.minecraft.item.ItemGroup;
|
import net.minecraft.item.ItemGroup;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.server.command.CommandManager;
|
|
||||||
import net.minecraft.util.Identifier;
|
import net.minecraft.util.Identifier;
|
||||||
import org.apache.logging.log4j.LogManager;
|
import org.apache.logging.log4j.LogManager;
|
||||||
import org.apache.logging.log4j.Logger;
|
import org.apache.logging.log4j.Logger;
|
||||||
|
import reborncore.common.config.Configuration;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RegistrationManager;
|
|
||||||
import reborncore.common.util.Torus;
|
import reborncore.common.util.Torus;
|
||||||
import techreborn.blockentity.fusionReactor.FusionControlComputerBlockEntity;
|
|
||||||
import techreborn.client.GuiHandler;
|
import techreborn.client.GuiHandler;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.events.ModRegistry;
|
import techreborn.events.ModRegistry;
|
||||||
import techreborn.init.*;
|
import techreborn.init.*;
|
||||||
import techreborn.init.FluidGeneratorRecipes;
|
|
||||||
import techreborn.packets.ClientboundPackets;
|
import techreborn.packets.ClientboundPackets;
|
||||||
import techreborn.packets.ServerboundPackets;
|
import techreborn.packets.ServerboundPackets;
|
||||||
import techreborn.utils.BehaviorDispenseScrapbox;
|
import techreborn.utils.BehaviorDispenseScrapbox;
|
||||||
|
@ -60,8 +57,8 @@ public class TechReborn implements ModInitializer {
|
||||||
@Override
|
@Override
|
||||||
public void onInitialize() {
|
public void onInitialize() {
|
||||||
INSTANCE = this;
|
INSTANCE = this;
|
||||||
@SuppressWarnings("unused")
|
new Configuration(TechRebornConfig.class, "techreborn");
|
||||||
RegistrationManager registrationManager = new RegistrationManager("techreborn", getClass());
|
|
||||||
|
|
||||||
// Done to force the class to load
|
// Done to force the class to load
|
||||||
ModRecipes.GRINDER.getName();
|
ModRecipes.GRINDER.getName();
|
||||||
|
@ -80,11 +77,11 @@ public class TechReborn implements ModInitializer {
|
||||||
|
|
||||||
|
|
||||||
// Scrapbox
|
// Scrapbox
|
||||||
if (BehaviorDispenseScrapbox.dispenseScrapboxes) {
|
if (TechRebornConfig.dispenseScrapboxes) {
|
||||||
DispenserBlock.registerBehavior(TRContent.SCRAP_BOX, new BehaviorDispenseScrapbox());
|
DispenserBlock.registerBehavior(TRContent.SCRAP_BOX, new BehaviorDispenseScrapbox());
|
||||||
}
|
}
|
||||||
|
|
||||||
Torus.genSizeMap(FusionControlComputerBlockEntity.maxCoilSize);
|
Torus.genSizeMap(TechRebornConfig.fusionControlComputerMaxCoilSize);
|
||||||
|
|
||||||
LOGGER.info("TechReborn setup done!");
|
LOGGER.info("TechReborn setup done!");
|
||||||
|
|
||||||
|
|
|
@ -34,24 +34,14 @@ import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ChargeOMatBlockEntity extends PowerAcceptorBlockEntity
|
public class ChargeOMatBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "charge_bench", key = "ChargeBenchMaxOutput", comment = "Charge Bench Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 512;
|
|
||||||
@ConfigRegistry(config = "machines", category = "charge_bench", key = "ChargeBenchMaxInput", comment = "Charge Bench Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 512;
|
|
||||||
@ConfigRegistry(config = "machines", category = "charge_bench", key = "ChargeBenchMaxEnergy", comment = "Charge Bench Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 100_000_000;
|
|
||||||
|
|
||||||
public RebornInventory<ChargeOMatBlockEntity> inventory = new RebornInventory<>(6, "ChargeOMatBlockEntity", 64, this);
|
public RebornInventory<ChargeOMatBlockEntity> inventory = new RebornInventory<>(6, "ChargeOMatBlockEntity", 64, this);
|
||||||
|
|
||||||
public ChargeOMatBlockEntity() {
|
public ChargeOMatBlockEntity() {
|
||||||
|
@ -77,7 +67,7 @@ public class ChargeOMatBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.chargeOMatBMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -92,12 +82,12 @@ public class ChargeOMatBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.chargeOMatBMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.chargeOMatBMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TileMachineBase
|
// TileMachineBase
|
||||||
|
|
|
@ -28,19 +28,13 @@ import net.minecraft.entity.player.PlayerEntity;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import techreborn.config.TechRebornConfig;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class DigitalChestBlockEntity extends TechStorageBaseBlockEntity implements IContainerProvider {
|
public class DigitalChestBlockEntity extends TechStorageBaseBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "digital_chest", key = "DigitalChestMaxStorage", comment = "Maximum amount of items a Digital Chest can store")
|
|
||||||
public static int maxStorage = 32768;
|
|
||||||
|
|
||||||
public DigitalChestBlockEntity() {
|
public DigitalChestBlockEntity() {
|
||||||
super(TRBlockEntities.DIGITAL_CHEST, "DigitalChestBlockEntity", maxStorage);
|
super(TRBlockEntities.DIGITAL_CHEST, "DigitalChestBlockEntity", TechRebornConfig.digitalChestMaxStorage);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -32,11 +32,9 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
@ -44,16 +42,10 @@ import techreborn.items.ItemDynamicCell;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class IndustrialCentrifugeBlockEntity extends GenericMachineBlockEntity implements IContainerProvider, IListInfoProvider {
|
public class IndustrialCentrifugeBlockEntity extends GenericMachineBlockEntity implements IContainerProvider, IListInfoProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "centrifuge", key = "CentrifugeMaxInput", comment = "Centrifuge Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "centrifuge", key = "CentrifugeMaxEnergy", comment = "Centrifuge Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public IndustrialCentrifugeBlockEntity() {
|
public IndustrialCentrifugeBlockEntity() {
|
||||||
super(TRBlockEntities.INDUSTRIAL_CENTRIFUGE, "IndustrialCentrifuge", maxInput, maxEnergy, TRContent.Machine.INDUSTRIAL_CENTRIFUGE.block, 6);
|
super(TRBlockEntities.INDUSTRIAL_CENTRIFUGE, "IndustrialCentrifuge", TechRebornConfig.industrialCentrifugeMaxInput, TechRebornConfig.industrialCentrifugeMaxEnergy, TRContent.Machine.INDUSTRIAL_CENTRIFUGE.block, 6);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2, 3, 4, 5 };
|
final int[] outputs = new int[] { 2, 3, 4, 5 };
|
||||||
this.inventory = new RebornInventory<>(7, "IndustrialCentrifugeBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(7, "IndustrialCentrifugeBlockEntity", 64, this);
|
||||||
|
|
|
@ -38,13 +38,11 @@ import reborncore.common.crafting.RebornRecipe;
|
||||||
import reborncore.common.crafting.ingredient.RebornIngredient;
|
import reborncore.common.crafting.ingredient.RebornIngredient;
|
||||||
import reborncore.common.crafting.ingredient.StackIngredient;
|
import reborncore.common.crafting.ingredient.StackIngredient;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.Torus;
|
import reborncore.common.util.Torus;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.api.recipe.recipes.FusionReactorRecipe;
|
import techreborn.api.recipe.recipes.FusionReactorRecipe;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
@ -52,19 +50,9 @@ import techreborn.init.TRContent;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.concurrent.atomic.AtomicInteger;
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class FusionControlComputerBlockEntity extends PowerAcceptorBlockEntity
|
public class FusionControlComputerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxInput", comment = "Fusion Reactor Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 8192;
|
|
||||||
@ConfigRegistry(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxOutput", comment = "Fusion Reactor Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 1_000_000;
|
|
||||||
@ConfigRegistry(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxEnergy", comment = "Fusion Reactor Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 100_000_000;
|
|
||||||
@ConfigRegistry(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxCoilSize", comment = "Fusion Reactor Max Coil size (Radius)")
|
|
||||||
public static int maxCoilSize = 50;
|
|
||||||
|
|
||||||
public RebornInventory<FusionControlComputerBlockEntity> inventory;
|
public RebornInventory<FusionControlComputerBlockEntity> inventory;
|
||||||
|
|
||||||
public int coilCount = 0;
|
public int coilCount = 0;
|
||||||
|
@ -320,7 +308,7 @@ public class FusionControlComputerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return Math.min(maxEnergy * getPowerMultiplier(), Integer.MAX_VALUE);
|
return Math.min(TechRebornConfig.fusionControlComputerMaxEnergy * getPowerMultiplier(), Integer.MAX_VALUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -346,7 +334,7 @@ public class FusionControlComputerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
if (hasStartedCrafting) {
|
if (hasStartedCrafting) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
return maxInput;
|
return TechRebornConfig.fusionControlComputerMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -366,7 +354,7 @@ public class FusionControlComputerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
if(tagCompound.containsKey("size")){
|
if(tagCompound.containsKey("size")){
|
||||||
this.size = tagCompound.getInt("size");
|
this.size = tagCompound.getInt("size");
|
||||||
}
|
}
|
||||||
this.size = Math.min(size, maxCoilSize);//Done here to force the samller size, will be useful if people lag out on a large one.
|
this.size = Math.min(size, TechRebornConfig.fusionControlComputerMaxCoilSize);//Done here to force the samller size, will be useful if people lag out on a large one.
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -460,7 +448,7 @@ public class FusionControlComputerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
public void changeSize(int sizeDelta){
|
public void changeSize(int sizeDelta){
|
||||||
int newSize = size + sizeDelta;
|
int newSize = size + sizeDelta;
|
||||||
this.size = Math.max(6, Math.min(maxCoilSize, newSize));
|
this.size = Math.max(6, Math.min(TechRebornConfig.fusionControlComputerMaxCoilSize, newSize));
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getState(){
|
public int getState(){
|
||||||
|
|
|
@ -35,23 +35,12 @@ import net.minecraft.world.Heightmap;
|
||||||
import reborncore.api.IToolDrop;
|
import reborncore.api.IToolDrop;
|
||||||
import reborncore.common.blocks.BlockMachineBase;
|
import reborncore.common.blocks.BlockMachineBase;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import techreborn.config.TechRebornConfig;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class LightningRodBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
public class LightningRodBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "lightning_rod", key = "LightningRodMaxOutput", comment = "Lightning Rod Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 2048;
|
|
||||||
@ConfigRegistry(config = "generators", category = "lightning_rod", key = "LightningRodMaxEnergy", comment = "Lightning Rod Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 100_000_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "lightning_rod", key = "LightningRodChanceOfStrike", comment = "Chance of lightning striking a rod (Range: 0-70)")
|
|
||||||
public static int chanceOfStrike = 24;
|
|
||||||
@ConfigRegistry(config = "generators", category = "lightning_rod", key = "LightningRodBaseStrikeEnergy", comment = "Base amount of energy per strike (Value in EU)")
|
|
||||||
public static int baseEnergyStrike = 262_144;
|
|
||||||
|
|
||||||
private int onStatusHoldTicks = -1;
|
private int onStatusHoldTicks = -1;
|
||||||
|
|
||||||
|
@ -80,7 +69,7 @@ public class LightningRodBlockEntity extends PowerAcceptorBlockEntity implements
|
||||||
final float weatherStrength = world.getThunderGradient(1.0F);
|
final float weatherStrength = world.getThunderGradient(1.0F);
|
||||||
if (weatherStrength > 0.2F) {
|
if (weatherStrength > 0.2F) {
|
||||||
//lightStrikeChance = (MAX - (CHANCE * WEATHER_STRENGTH)
|
//lightStrikeChance = (MAX - (CHANCE * WEATHER_STRENGTH)
|
||||||
final float lightStrikeChance = (100F - chanceOfStrike) * 20F;
|
final float lightStrikeChance = (100F - TechRebornConfig.lightningRodChanceOfStrike) * 20F;
|
||||||
final float totalChance = lightStrikeChance * getLightningStrikeMultiplier() * (1.1F - weatherStrength);
|
final float totalChance = lightStrikeChance * getLightningStrikeMultiplier() * (1.1F - weatherStrength);
|
||||||
if (world.random.nextInt((int) Math.floor(totalChance)) == 0) {
|
if (world.random.nextInt((int) Math.floor(totalChance)) == 0) {
|
||||||
if (!isValidIronFence(pos.up().getY())) {
|
if (!isValidIronFence(pos.up().getY())) {
|
||||||
|
@ -94,7 +83,7 @@ public class LightningRodBlockEntity extends PowerAcceptorBlockEntity implements
|
||||||
if (!world.isClient) {
|
if (!world.isClient) {
|
||||||
((ServerWorld) world).addLightning(lightningBolt);
|
((ServerWorld) world).addLightning(lightningBolt);
|
||||||
}
|
}
|
||||||
addEnergy(baseEnergyStrike * (0.3F + weatherStrength));
|
addEnergy(TechRebornConfig.lightningRodBaseEnergyStrike * (0.3F + weatherStrength));
|
||||||
machineBaseBlock.setActive(true, world, pos);
|
machineBaseBlock.setActive(true, world, pos);
|
||||||
onStatusHoldTicks = 400;
|
onStatusHoldTicks = 400;
|
||||||
}
|
}
|
||||||
|
@ -127,7 +116,7 @@ public class LightningRodBlockEntity extends PowerAcceptorBlockEntity implements
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.lightningRodMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -142,7 +131,7 @@ public class LightningRodBlockEntity extends PowerAcceptorBlockEntity implements
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.lightningRodMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -29,27 +29,15 @@ import net.minecraft.item.ItemStack;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.api.generator.EFluidGenerator;
|
import techreborn.api.generator.EFluidGenerator;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class PlasmaGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
public class PlasmaGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorMaxOutput", comment = "Plasma Generator Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 2048;
|
|
||||||
@ConfigRegistry(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorMaxEnergy", comment = "Plasma Generator Max Energy (Value in EU)")
|
|
||||||
public static double maxEnergy = 500_000_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorTankCapacity", comment = "Plasma Generator Tank Capacity")
|
|
||||||
public static int tankCapacity = 10_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorEnergyPerTick", comment = "Plasma Generator Energy Per Tick (Value in EU)")
|
|
||||||
public static int energyPerTick = 400;
|
|
||||||
|
|
||||||
public PlasmaGeneratorBlockEntity() {
|
public PlasmaGeneratorBlockEntity() {
|
||||||
super(TRBlockEntities.PLASMA_GENERATOR, EFluidGenerator.PLASMA, "PlasmaGeneratorBlockEntity", tankCapacity, energyPerTick);
|
super(TRBlockEntities.PLASMA_GENERATOR, EFluidGenerator.PLASMA, "PlasmaGeneratorBlockEntity", TechRebornConfig.plasmaGeneratorTankCapacity, TechRebornConfig.plasmaGeneratorEnergyPerTick);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -59,12 +47,12 @@ public class PlasmaGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity im
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.plasmaGeneratorMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.plasmaGeneratorMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -29,28 +29,16 @@ import net.minecraft.item.ItemStack;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.api.generator.EFluidGenerator;
|
import techreborn.api.generator.EFluidGenerator;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class DieselGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
public class DieselGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "diesel_generator", key = "DieselGeneratorMaxOutput", comment = "Diesel Generator Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 128;
|
|
||||||
@ConfigRegistry(config = "generators", category = "diesel_generator", key = "DieselGeneratorMaxEnergy", comment = "Diesel Generator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1_000_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "diesel_generator", key = "DieselGeneratorTankCapacity", comment = "Diesel Generator Tank Capacity")
|
|
||||||
public static int tankCapacity = 10_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "diesel_generator", key = "DieselGeneratorEnergyPerTick", comment = "Diesel Generator Energy Per Tick (Value in EU)")
|
|
||||||
public static int energyPerTick = 20;
|
|
||||||
|
|
||||||
public DieselGeneratorBlockEntity() {
|
public DieselGeneratorBlockEntity() {
|
||||||
super(TRBlockEntities.DIESEL_GENERATOR, EFluidGenerator.DIESEL, "DieselGeneratorBlockEntity", tankCapacity, energyPerTick);
|
super(TRBlockEntities.DIESEL_GENERATOR, EFluidGenerator.DIESEL, "DieselGeneratorBlockEntity", TechRebornConfig.dieselGeneratorTankCapacity, TechRebornConfig.dieselGeneratorEnergyPerTick);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -60,12 +48,12 @@ public class DieselGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity im
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.dieselGeneratorMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.dieselGeneratorMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -33,24 +33,14 @@ import reborncore.api.IToolDrop;
|
||||||
import reborncore.api.blockentity.InventoryProvider;
|
import reborncore.api.blockentity.InventoryProvider;
|
||||||
import reborncore.common.blocks.BlockMachineBase;
|
import reborncore.common.blocks.BlockMachineBase;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class DragonEggSyphonBlockEntity extends PowerAcceptorBlockEntity
|
public class DragonEggSyphonBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider {
|
implements IToolDrop, InventoryProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "dragon_egg_siphoner", key = "DragonEggSiphonerMaxOutput", comment = "Dragon Egg Siphoner Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 128;
|
|
||||||
@ConfigRegistry(config = "generators", category = "dragon_egg_siphoner", key = "DragonEggSiphonerMaxEnergy", comment = "Dragon Egg Siphoner Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "dragon_egg_siphoner", key = "DragonEggSiphonerEnergyPerTick", comment = "Dragon Egg Siphoner Energy Per Tick (Value in EU)")
|
|
||||||
public static int energyPerTick = 4;
|
|
||||||
|
|
||||||
public RebornInventory<DragonEggSyphonBlockEntity> inventory = new RebornInventory<>(3, "DragonEggSyphonBlockEntity", 64, this);
|
public RebornInventory<DragonEggSyphonBlockEntity> inventory = new RebornInventory<>(3, "DragonEggSyphonBlockEntity", 64, this);
|
||||||
private long lastOutput = 0;
|
private long lastOutput = 0;
|
||||||
|
|
||||||
|
@ -77,7 +67,7 @@ public class DragonEggSyphonBlockEntity extends PowerAcceptorBlockEntity
|
||||||
if (!world.isClient) {
|
if (!world.isClient) {
|
||||||
if (world.getBlockState(new BlockPos(pos.getX(), pos.getY() + 1, pos.getZ()))
|
if (world.getBlockState(new BlockPos(pos.getX(), pos.getY() + 1, pos.getZ()))
|
||||||
.getBlock() == Blocks.DRAGON_EGG) {
|
.getBlock() == Blocks.DRAGON_EGG) {
|
||||||
if (tryAddingEnergy(energyPerTick))
|
if (tryAddingEnergy(TechRebornConfig.dragonEggSyphonEnergyPerTick))
|
||||||
lastOutput = world.getTime();
|
lastOutput = world.getTime();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -91,7 +81,7 @@ public class DragonEggSyphonBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.dragonEggSyphonMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -106,7 +96,7 @@ public class DragonEggSyphonBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.dragonEggSyphonMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -29,28 +29,16 @@ import net.minecraft.item.ItemStack;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.api.generator.EFluidGenerator;
|
import techreborn.api.generator.EFluidGenerator;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class GasTurbineBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
public class GasTurbineBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "gas_generator", key = "GasGeneratorMaxOutput", comment = "Gas Generator Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 128;
|
|
||||||
@ConfigRegistry(config = "generators", category = "gas_generator", key = "GasGeneratorMaxEnergy", comment = "Gas Generator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1000000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "gas_generator", key = "GasGeneratorTankCapacity", comment = "Gas Generator Tank Capacity")
|
|
||||||
public static int tankCapacity = 10000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "gas_generator", key = "GasGeneratorEnergyPerTick", comment = "Gas Generator Energy Per Tick (Value in EU)")
|
|
||||||
public static int energyPerTick = 16;
|
|
||||||
|
|
||||||
public GasTurbineBlockEntity() {
|
public GasTurbineBlockEntity() {
|
||||||
super(TRBlockEntities.GAS_TURBINE, EFluidGenerator.GAS, "GasTurbineBlockEntity", tankCapacity, energyPerTick);
|
super(TRBlockEntities.GAS_TURBINE, EFluidGenerator.GAS, "GasTurbineBlockEntity", TechRebornConfig.gasTurbineTankCapacity, TechRebornConfig.gasTurbineEnergyPerTick);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -60,12 +48,12 @@ public class GasTurbineBlockEntity extends BaseFluidGeneratorBlockEntity impleme
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.gasTurbineMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.gasTurbineMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -29,28 +29,16 @@ import net.minecraft.item.ItemStack;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.api.generator.EFluidGenerator;
|
import techreborn.api.generator.EFluidGenerator;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class SemiFluidGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
public class SemiFluidGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorMaxOutput", comment = "Semifluid Generator Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 128;
|
|
||||||
@ConfigRegistry(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorMaxEnergy", comment = "Semifluid Generator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1000000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorTankCapacity", comment = "Semifluid Generator Tank Capacity")
|
|
||||||
public static int tankCapacity = 10000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorEnergyPerTick", comment = "Semifluid Generator Energy Per Tick (Value in EU)")
|
|
||||||
public static int energyPerTick = 8;
|
|
||||||
|
|
||||||
public SemiFluidGeneratorBlockEntity() {
|
public SemiFluidGeneratorBlockEntity() {
|
||||||
super(TRBlockEntities.SEMI_FLUID_GENERATOR, EFluidGenerator.SEMIFLUID, "SemiFluidGeneratorBlockEntity", tankCapacity, energyPerTick);
|
super(TRBlockEntities.SEMI_FLUID_GENERATOR, EFluidGenerator.SEMIFLUID, "SemiFluidGeneratorBlockEntity", TechRebornConfig.semiFluidGeneratorTankCapacity, TechRebornConfig.semiFluidGeneratorEnergyPerTick);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -60,12 +48,12 @@ public class SemiFluidGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.semiFluidGeneratorMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.semiFluidGeneratorMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -29,28 +29,16 @@ import net.minecraft.item.ItemStack;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.api.generator.EFluidGenerator;
|
import techreborn.api.generator.EFluidGenerator;
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
import techreborn.blockentity.generator.BaseFluidGeneratorBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ThermalGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
public class ThermalGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "thermal_generator", key = "ThermalGeneratorMaxOutput", comment = "Thermal Generator Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 128;
|
|
||||||
@ConfigRegistry(config = "generators", category = "thermal_generator", key = "ThermalGeneratorMaxEnergy", comment = "Thermal Generator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1_000_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "thermal_generator", key = "ThermalGeneratorTankCapacity", comment = "Thermal Generator Tank Capacity")
|
|
||||||
public static int tankCapacity = 10_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "thermal_generator", key = "ThermalGeneratorEnergyPerTick", comment = "Thermal Generator Energy Per Tick (Value in EU)")
|
|
||||||
public static int energyPerTick = 16;
|
|
||||||
|
|
||||||
public ThermalGeneratorBlockEntity() {
|
public ThermalGeneratorBlockEntity() {
|
||||||
super(TRBlockEntities.THERMAL_GEN, EFluidGenerator.THERMAL, "ThermalGeneratorBlockEntity", tankCapacity, energyPerTick);
|
super(TRBlockEntities.THERMAL_GEN, EFluidGenerator.THERMAL, "ThermalGeneratorBlockEntity", TechRebornConfig.thermalGeneratorTankCapacity, TechRebornConfig.thermalGeneratorEnergyPerTick);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -60,12 +48,12 @@ public class ThermalGeneratorBlockEntity extends BaseFluidGeneratorBlockEntity i
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.thermalGeneratorMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.thermalGeneratorMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -40,25 +40,15 @@ import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.blocks.BlockMachineBase;
|
import reborncore.common.blocks.BlockMachineBase;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class SolidFuelGeneratorBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop, InventoryProvider, IContainerProvider {
|
public class SolidFuelGeneratorBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "generator", key = "GeneratorMaxOutput", comment = "Solid Fuel Generator Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 32;
|
|
||||||
@ConfigRegistry(config = "generators", category = "generator", key = "GeneratorMaxEnergy", comment = "Solid Fuel Generator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "generator", key = "GeneratorEnergyOutput", comment = "Solid Fuel Generator Energy Output Amount (Value in EU)")
|
|
||||||
public static int outputAmount = 10;
|
|
||||||
|
|
||||||
public RebornInventory<SolidFuelGeneratorBlockEntity> inventory = new RebornInventory<>(2, "SolidFuelGeneratorBlockEntity", 64, this);
|
public RebornInventory<SolidFuelGeneratorBlockEntity> inventory = new RebornInventory<>(2, "SolidFuelGeneratorBlockEntity", 64, this);
|
||||||
public int fuelSlot = 0;
|
public int fuelSlot = 0;
|
||||||
public int burnTime;
|
public int burnTime;
|
||||||
|
@ -90,7 +80,7 @@ public class SolidFuelGeneratorBlockEntity extends PowerAcceptorBlockEntity impl
|
||||||
if (getEnergy() < getMaxPower()) {
|
if (getEnergy() < getMaxPower()) {
|
||||||
if (burnTime > 0) {
|
if (burnTime > 0) {
|
||||||
burnTime--;
|
burnTime--;
|
||||||
addEnergy(SolidFuelGeneratorBlockEntity.outputAmount);
|
addEnergy(TechRebornConfig.solidFuelGeneratorOutputAmount);
|
||||||
isBurning = true;
|
isBurning = true;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
@ -131,7 +121,7 @@ public class SolidFuelGeneratorBlockEntity extends PowerAcceptorBlockEntity impl
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.solidFuelGeneratorMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -146,7 +136,7 @@ public class SolidFuelGeneratorBlockEntity extends PowerAcceptorBlockEntity impl
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.solidFuelGeneratorMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -31,26 +31,16 @@ import net.minecraft.util.math.Direction;
|
||||||
import reborncore.api.IToolDrop;
|
import reborncore.api.IToolDrop;
|
||||||
import reborncore.common.blocks.BlockMachineBase;
|
import reborncore.common.blocks.BlockMachineBase;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by modmuss50 on 25/02/2016.
|
* Created by modmuss50 on 25/02/2016.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class WaterMillBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
public class WaterMillBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "water_mill", key = "WaterMillMaxOutput", comment = "Water Mill Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 32;
|
|
||||||
@ConfigRegistry(config = "generators", category = "water_mill", key = "WaterMillMaxEnergy", comment = "Water Mill Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "water_mill", key = "WaterMillEnergyPerTick", comment = "Water Mill Energy Multiplier")
|
|
||||||
public static double energyMultiplier = 0.1;
|
|
||||||
|
|
||||||
int waterblocks = 0;
|
int waterblocks = 0;
|
||||||
|
|
||||||
public WaterMillBlockEntity() {
|
public WaterMillBlockEntity() {
|
||||||
|
@ -64,7 +54,7 @@ public class WaterMillBlockEntity extends PowerAcceptorBlockEntity implements IT
|
||||||
checkForWater();
|
checkForWater();
|
||||||
}
|
}
|
||||||
if (waterblocks > 0) {
|
if (waterblocks > 0) {
|
||||||
addEnergy(waterblocks * energyMultiplier);
|
addEnergy(waterblocks * TechRebornConfig.waterMillEnergyMultiplier);
|
||||||
world.setBlockState(pos, world.getBlockState(pos).with(BlockMachineBase.ACTIVE, true));
|
world.setBlockState(pos, world.getBlockState(pos).with(BlockMachineBase.ACTIVE, true));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -83,7 +73,7 @@ public class WaterMillBlockEntity extends PowerAcceptorBlockEntity implements IT
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.waterMillMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -98,7 +88,7 @@ public class WaterMillBlockEntity extends PowerAcceptorBlockEntity implements IT
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.waterMillMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -29,9 +29,7 @@ import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import reborncore.api.IToolDrop;
|
import reborncore.api.IToolDrop;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import techreborn.config.TechRebornConfig;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
|
@ -39,18 +37,8 @@ import techreborn.init.TRBlockEntities;
|
||||||
* Created by modmuss50 on 25/02/2016.
|
* Created by modmuss50 on 25/02/2016.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class WindMillBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
public class WindMillBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "wind_mill", key = "WindMillMaxOutput", comment = "Wind Mill Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 128;
|
|
||||||
@ConfigRegistry(config = "generators", category = "wind_mill", key = "WindMillMaxEnergy", comment = "Wind Mill Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
@ConfigRegistry(config = "generators", category = "wind_mill", key = "WindMillEnergyPerTick", comment = "Wind Mill Energy Per Tick (Value in EU)")
|
|
||||||
public static int baseEnergy = 2;
|
|
||||||
@ConfigRegistry(config = "generators", category = "wind_mill", key = "WindMillThunderMultiplier", comment = "Wind Mill Thunder Multiplier")
|
|
||||||
public static double thunderMultiplier = 1.25;
|
|
||||||
|
|
||||||
public WindMillBlockEntity() {
|
public WindMillBlockEntity() {
|
||||||
super(TRBlockEntities.WIND_MILL);
|
super(TRBlockEntities.WIND_MILL);
|
||||||
}
|
}
|
||||||
|
@ -59,9 +47,9 @@ public class WindMillBlockEntity extends PowerAcceptorBlockEntity implements ITo
|
||||||
public void tick() {
|
public void tick() {
|
||||||
super.tick();
|
super.tick();
|
||||||
if (pos.getY() > 64) {
|
if (pos.getY() > 64) {
|
||||||
int actualPower = baseEnergy;
|
int actualPower = TechRebornConfig.windMillBaseEnergy;
|
||||||
if (world.isThundering()) {
|
if (world.isThundering()) {
|
||||||
actualPower *= thunderMultiplier;
|
actualPower *= TechRebornConfig.windMillThunderMultiplier;
|
||||||
}
|
}
|
||||||
addEnergy(actualPower); // Value taken from
|
addEnergy(actualPower); // Value taken from
|
||||||
// http://wiki.industrial-craft.net/?title=Wind_Mill
|
// http://wiki.industrial-craft.net/?title=Wind_Mill
|
||||||
|
@ -71,7 +59,7 @@ public class WindMillBlockEntity extends PowerAcceptorBlockEntity implements ITo
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.windMillMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -86,7 +74,7 @@ public class WindMillBlockEntity extends PowerAcceptorBlockEntity implements ITo
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxOutput() {
|
public double getBaseMaxOutput() {
|
||||||
return maxOutput;
|
return TechRebornConfig.windMillMaxOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -36,7 +36,6 @@ import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.crafting.ingredient.RebornIngredient;
|
import reborncore.common.crafting.ingredient.RebornIngredient;
|
||||||
import reborncore.common.crafting.RebornRecipe;
|
import reborncore.common.crafting.RebornRecipe;
|
||||||
import reborncore.common.crafting.ingredient.StackIngredient;
|
import reborncore.common.crafting.ingredient.StackIngredient;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.blockentity.MachineBaseBlockEntity;
|
import reborncore.common.blockentity.MachineBaseBlockEntity;
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
|
@ -46,7 +45,6 @@ import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
import java.util.concurrent.atomic.AtomicInteger;
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class IronAlloyFurnaceBlockEntity extends MachineBaseBlockEntity
|
public class IronAlloyFurnaceBlockEntity extends MachineBaseBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
|
|
|
@ -31,27 +31,21 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.ModRecipes;
|
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.ModRecipes;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class DistillationTowerBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class DistillationTowerBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "Distillation_tower", key = "DistillationTowerMaxInput", comment = "Distillation Tower Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 128;
|
|
||||||
@ConfigRegistry(config = "machines", category = "Distillation_tower", key = "DistillationTowerMaxEnergy", comment = "Distillation Tower Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public MultiblockChecker multiblockChecker;
|
public MultiblockChecker multiblockChecker;
|
||||||
|
|
||||||
public DistillationTowerBlockEntity() {
|
public DistillationTowerBlockEntity() {
|
||||||
super(TRBlockEntities.DISTILLATION_TOWER, "DistillationTower", maxInput, maxEnergy, TRContent.Machine.DISTILLATION_TOWER.block, 6);
|
super(TRBlockEntities.DISTILLATION_TOWER, "DistillationTower", TechRebornConfig.distillationTowerMaxInput, TechRebornConfig.distillationTowerMaxEnergy, TRContent.Machine.DISTILLATION_TOWER.block, 6);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2, 3, 4, 5 };
|
final int[] outputs = new int[] { 2, 3, 4, 5 };
|
||||||
this.inventory = new RebornInventory<>(7, "DistillationTowerBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(7, "DistillationTowerBlockEntity", 64, this);
|
||||||
|
|
|
@ -31,12 +31,10 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.IInventoryAccess;
|
import reborncore.common.util.IInventoryAccess;
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.Tank;
|
import reborncore.common.util.Tank;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
@ -49,22 +47,15 @@ import javax.annotation.Nullable;
|
||||||
* @author drcrazy
|
* @author drcrazy
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class FluidReplicatorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class FluidReplicatorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "fluidreplicator", key = "FluidReplicatorMaxInput", comment = "Fluid Replicator Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 256;
|
|
||||||
@ConfigRegistry(config = "machines", category = "fluidreplicator", key = "FluidReplicatorMaxEnergy", comment = "Fluid Replicator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 400_000;
|
|
||||||
|
|
||||||
public MultiblockChecker multiblockChecker;
|
public MultiblockChecker multiblockChecker;
|
||||||
public static final int TANK_CAPACITY = 16_000;
|
public static final int TANK_CAPACITY = 16_000;
|
||||||
public Tank tank;
|
public Tank tank;
|
||||||
int ticksSinceLastChange;
|
int ticksSinceLastChange;
|
||||||
|
|
||||||
public FluidReplicatorBlockEntity() {
|
public FluidReplicatorBlockEntity() {
|
||||||
super(TRBlockEntities.FLUID_REPLICATOR, "FluidReplicator", maxInput, maxEnergy, TRContent.Machine.FLUID_REPLICATOR.block, 3);
|
super(TRBlockEntities.FLUID_REPLICATOR, "FluidReplicator", TechRebornConfig.fluidReplicatorMaxInput, TechRebornConfig.fluidReplicatorMaxEnergy, TRContent.Machine.FLUID_REPLICATOR.block, 3);
|
||||||
this.inventory = new RebornInventory<>(4, "FluidReplicatorBlockEntity", 64, this, getInventoryAccess());
|
this.inventory = new RebornInventory<>(4, "FluidReplicatorBlockEntity", 64, this, getInventoryAccess());
|
||||||
this.crafter = new RecipeCrafter(ModRecipes.FLUID_REPLICATOR, this, 1, 0, this.inventory, new int[] {0}, null);
|
this.crafter = new RecipeCrafter(ModRecipes.FLUID_REPLICATOR, this, 1, 0, this.inventory, new int[] {0}, null);
|
||||||
this.tank = new Tank("FluidReplicatorBlockEntity", FluidReplicatorBlockEntity.TANK_CAPACITY, this);
|
this.tank = new Tank("FluidReplicatorBlockEntity", FluidReplicatorBlockEntity.TANK_CAPACITY, this);
|
||||||
|
|
|
@ -30,27 +30,19 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ImplosionCompressorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class ImplosionCompressorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "implosion_compressor", key = "ImplosionCompressorMaxInput", comment = "Implosion Compressor Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 64;
|
|
||||||
@ConfigRegistry(config = "machines", category = "implosion_compressor", key = "ImplosionCompressorMaxEnergy", comment = "Implosion Compressor Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 64_000;
|
|
||||||
|
|
||||||
public MultiblockChecker multiblockChecker;
|
public MultiblockChecker multiblockChecker;
|
||||||
|
|
||||||
public ImplosionCompressorBlockEntity() {
|
public ImplosionCompressorBlockEntity() {
|
||||||
super(TRBlockEntities.IMPLOSION_COMPRESSOR, "ImplosionCompressor", maxInput, maxEnergy, TRContent.Machine.IMPLOSION_COMPRESSOR.block, 4);
|
super(TRBlockEntities.IMPLOSION_COMPRESSOR, "ImplosionCompressor", TechRebornConfig.implosionCompressorMaxInput, TechRebornConfig.implosionCompressorMaxEnergy, TRContent.Machine.IMPLOSION_COMPRESSOR.block, 4);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2, 3 };
|
final int[] outputs = new int[] { 2, 3 };
|
||||||
this.inventory = new RebornInventory<>(5, "ImplosionCompressorBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(5, "ImplosionCompressorBlockEntity", 64, this);
|
||||||
|
|
|
@ -34,11 +34,9 @@ import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.multiblock.IMultiblockPart;
|
import reborncore.common.multiblock.IMultiblockPart;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.blocks.BlockMachineCasing;
|
import techreborn.blocks.BlockMachineCasing;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
@ -46,19 +44,13 @@ import techreborn.multiblocks.MultiBlockCasing;
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
import techreborn.blockentity.MachineCasingBlockEntity;
|
import techreborn.blockentity.MachineCasingBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class IndustrialBlastFurnaceBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class IndustrialBlastFurnaceBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_furnace", key = "IndustrialFurnaceMaxInput", comment = "Industrial Blast Furnace Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 128;
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_furnace", key = "IndustrialFurnaceMaxEnergy", comment = "Industrial Blast Furnace Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 40_000;
|
|
||||||
|
|
||||||
public MultiblockChecker multiblockChecker;
|
public MultiblockChecker multiblockChecker;
|
||||||
private int cachedHeat;
|
private int cachedHeat;
|
||||||
|
|
||||||
public IndustrialBlastFurnaceBlockEntity() {
|
public IndustrialBlastFurnaceBlockEntity() {
|
||||||
super(TRBlockEntities.INDUSTRIAL_BLAST_FURNACE, "IndustrialBlastFurnace", maxInput, maxEnergy, TRContent.Machine.INDUSTRIAL_BLAST_FURNACE.block, 4);
|
super(TRBlockEntities.INDUSTRIAL_BLAST_FURNACE, "IndustrialBlastFurnace", TechRebornConfig.industrialBlastFurnaceMaxInput, TechRebornConfig.industrialBlastFurnaceMaxEnergy, TRContent.Machine.INDUSTRIAL_BLAST_FURNACE.block, 4);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2, 3 };
|
final int[] outputs = new int[] { 2, 3 };
|
||||||
this.inventory = new RebornInventory<>(5, "IndustrialBlastFurnaceBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(5, "IndustrialBlastFurnaceBlockEntity", 64, this);
|
||||||
|
|
|
@ -34,12 +34,10 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.IInventoryAccess;
|
import reborncore.common.util.IInventoryAccess;
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.Tank;
|
import reborncore.common.util.Tank;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
@ -48,21 +46,15 @@ import techreborn.utils.FluidUtils;
|
||||||
|
|
||||||
import javax.annotation.Nullable;
|
import javax.annotation.Nullable;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class IndustrialGrinderBlockEntity extends GenericMachineBlockEntity implements IContainerProvider{
|
public class IndustrialGrinderBlockEntity extends GenericMachineBlockEntity implements IContainerProvider{
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_grinder", key = "IndustrialGrinderMaxInput", comment = "Industrial Grinder Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 128;
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_grinder", key = "IndustrialGrinderMaxEnergy", comment = "Industrial Grinder Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public static final int TANK_CAPACITY = 16_000;
|
public static final int TANK_CAPACITY = 16_000;
|
||||||
public Tank tank;
|
public Tank tank;
|
||||||
public MultiblockChecker multiblockChecker;
|
public MultiblockChecker multiblockChecker;
|
||||||
int ticksSinceLastChange;
|
int ticksSinceLastChange;
|
||||||
|
|
||||||
public IndustrialGrinderBlockEntity() {
|
public IndustrialGrinderBlockEntity() {
|
||||||
super(TRBlockEntities.INDUSTRIAL_GRINDER, "IndustrialGrinder", maxInput, maxEnergy, TRContent.Machine.INDUSTRIAL_GRINDER.block, 7);
|
super(TRBlockEntities.INDUSTRIAL_GRINDER, "IndustrialGrinder", TechRebornConfig.industrialGrinderMaxInput, TechRebornConfig.industrialGrinderMaxEnergy, TRContent.Machine.INDUSTRIAL_GRINDER.block, 7);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] {2, 3, 4, 5};
|
final int[] outputs = new int[] {2, 3, 4, 5};
|
||||||
this.inventory = new RebornInventory<>(8, "IndustrialGrinderBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(8, "IndustrialGrinderBlockEntity", 64, this);
|
||||||
|
|
|
@ -34,12 +34,10 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.IInventoryAccess;
|
import reborncore.common.util.IInventoryAccess;
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.Tank;
|
import reborncore.common.util.Tank;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
@ -48,21 +46,15 @@ import techreborn.utils.FluidUtils;
|
||||||
|
|
||||||
import javax.annotation.Nullable;
|
import javax.annotation.Nullable;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class IndustrialSawmillBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class IndustrialSawmillBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_sawmill", key = "IndustrialSawmillMaxInput", comment = "Industrial Sawmill Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 128;
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_sawmill", key = "IndustrialSawmillMaxEnergy", comment = "Industrial Sawmill Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public static final int TANK_CAPACITY = 16_000;
|
public static final int TANK_CAPACITY = 16_000;
|
||||||
public Tank tank;
|
public Tank tank;
|
||||||
public MultiblockChecker multiblockChecker;
|
public MultiblockChecker multiblockChecker;
|
||||||
int ticksSinceLastChange;
|
int ticksSinceLastChange;
|
||||||
|
|
||||||
public IndustrialSawmillBlockEntity() {
|
public IndustrialSawmillBlockEntity() {
|
||||||
super(TRBlockEntities.INDUSTRIAL_SAWMILL, "IndustrialSawmill", maxInput, maxEnergy, TRContent.Machine.INDUSTRIAL_SAWMILL.block, 6);
|
super(TRBlockEntities.INDUSTRIAL_SAWMILL, "IndustrialSawmill", TechRebornConfig.industrialSawmillMaxInput, TechRebornConfig.industrialSawmillMaxEnergy, TRContent.Machine.INDUSTRIAL_SAWMILL.block, 6);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2, 3, 4 };
|
final int[] outputs = new int[] { 2, 3, 4 };
|
||||||
this.inventory = new RebornInventory<>(7, "SawmillBlockEntity", 64, this, getInventoryAccess());
|
this.inventory = new RebornInventory<>(7, "SawmillBlockEntity", 64, this, getInventoryAccess());
|
||||||
|
|
|
@ -30,27 +30,19 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class VacuumFreezerBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class VacuumFreezerBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "vacuumfreezer", key = "VacuumFreezerInput", comment = "Vacuum Freezer Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 64;
|
|
||||||
@ConfigRegistry(config = "machines", category = "vacuumfreezer", key = "VacuumFreezerMaxEnergy", comment = "Vacuum Freezer Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 64_000;
|
|
||||||
|
|
||||||
public MultiblockChecker multiblockChecker;
|
public MultiblockChecker multiblockChecker;
|
||||||
|
|
||||||
public VacuumFreezerBlockEntity() {
|
public VacuumFreezerBlockEntity() {
|
||||||
super(TRBlockEntities.VACUUM_FREEZER, "VacuumFreezer", maxInput, maxEnergy, TRContent.Machine.VACUUM_FREEZER.block, 2);
|
super(TRBlockEntities.VACUUM_FREEZER, "VacuumFreezer", TechRebornConfig.vacuumFreezerMaxInput, TechRebornConfig.vacuumFreezerMaxEnergy, TRContent.Machine.VACUUM_FREEZER.block, 2);
|
||||||
final int[] inputs = new int[] { 0 };
|
final int[] inputs = new int[] { 0 };
|
||||||
final int[] outputs = new int[] { 1 };
|
final int[] outputs = new int[] { 1 };
|
||||||
this.inventory = new RebornInventory<>(3, "VacuumFreezerBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(3, "VacuumFreezerBlockEntity", 64, this);
|
||||||
|
|
|
@ -29,25 +29,17 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.ModRecipes;
|
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.ModRecipes;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class AlloySmelterBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class AlloySmelterBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "alloy_smelter", key = "AlloySmelterMaxInput", comment = "Alloy Smelter Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "alloy_smelter", key = "AlloySmelterMaxEnergy", comment = "Alloy Smelter Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1_000;
|
|
||||||
|
|
||||||
public AlloySmelterBlockEntity() {
|
public AlloySmelterBlockEntity() {
|
||||||
super(TRBlockEntities.ALLOY_SMELTER, "AlloySmelter", maxInput, maxEnergy, TRContent.Machine.ALLOY_SMELTER.block, 3);
|
super(TRBlockEntities.ALLOY_SMELTER, "AlloySmelter", TechRebornConfig.alloySmelterMaxInput, TechRebornConfig.alloySmelterMaxEnergy, TRContent.Machine.ALLOY_SMELTER.block, 3);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2 };
|
final int[] outputs = new int[] { 2 };
|
||||||
this.inventory = new RebornInventory<>(4, "AlloySmelterBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(4, "AlloySmelterBlockEntity", 64, this);
|
||||||
|
|
|
@ -29,25 +29,17 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.ModRecipes;
|
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.ModRecipes;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class AssemblingMachineBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class AssemblingMachineBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "assembling_machine", key = "AssemblingMachineMaxInput", comment = "Assembling Machine Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 128;
|
|
||||||
@ConfigRegistry(config = "machines", category = "assembling_machine", key = "AssemblingMachineMaxEnergy", comment = "Assembling Machine Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public AssemblingMachineBlockEntity() {
|
public AssemblingMachineBlockEntity() {
|
||||||
super(TRBlockEntities.ASSEMBLY_MACHINE, "AssemblingMachine", maxInput, maxEnergy, TRContent.Machine.ASSEMBLY_MACHINE.block, 3);
|
super(TRBlockEntities.ASSEMBLY_MACHINE, "AssemblingMachine", TechRebornConfig.assemblingMachineMaxInput, TechRebornConfig.assemblingMachineMaxEnergy, TRContent.Machine.ASSEMBLY_MACHINE.block, 3);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2 };
|
final int[] outputs = new int[] { 2 };
|
||||||
this.inventory = new RebornInventory<>(4, "AssemblingMachineBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(4, "AssemblingMachineBlockEntity", 64, this);
|
||||||
|
|
|
@ -42,12 +42,10 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.IInventoryAccess;
|
import reborncore.common.util.IInventoryAccess;
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModSounds;
|
import techreborn.init.ModSounds;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.utils.RecipeUtils;
|
import techreborn.utils.RecipeUtils;
|
||||||
|
@ -60,15 +58,9 @@ import java.util.List;
|
||||||
/**
|
/**
|
||||||
* Created by modmuss50 on 20/06/2017.
|
* Created by modmuss50 on 20/06/2017.
|
||||||
*/
|
*/
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class AutoCraftingTableBlockEntity extends PowerAcceptorBlockEntity
|
public class AutoCraftingTableBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "autocrafter", key = "AutoCrafterInput", comment = "AutoCrafting Table Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "autocrafter", key = "AutoCrafterMaxEnergy", comment = "AutoCrafting Table Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public RebornInventory<AutoCraftingTableBlockEntity> inventory = new RebornInventory<>(11, "AutoCraftingTableBlockEntity", 64, this, getInventoryAccess());
|
public RebornInventory<AutoCraftingTableBlockEntity> inventory = new RebornInventory<>(11, "AutoCraftingTableBlockEntity", 64, this, getInventoryAccess());
|
||||||
public int progress;
|
public int progress;
|
||||||
public int maxProgress = 120;
|
public int maxProgress = 120;
|
||||||
|
@ -359,7 +351,7 @@ public class AutoCraftingTableBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.autoCraftingTableMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -369,7 +361,7 @@ public class AutoCraftingTableBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.autoCraftingTableMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -29,25 +29,17 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ChemicalReactorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class ChemicalReactorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "chemical_reactor", key = "ChemicalReactorMaxInput", comment = "Chemical Reactor Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 128;
|
|
||||||
@ConfigRegistry(config = "machines", category = "chemical_reactor", key = "ChemicalReactorMaxEnergy", comment = "Chemical Reactor Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public ChemicalReactorBlockEntity() {
|
public ChemicalReactorBlockEntity() {
|
||||||
super(TRBlockEntities.CHEMICAL_REACTOR, "ChemicalReactor", maxInput, maxEnergy, TRContent.Machine.CHEMICAL_REACTOR.block, 3);
|
super(TRBlockEntities.CHEMICAL_REACTOR, "ChemicalReactor", TechRebornConfig.chemicalReactorMaxInput, TechRebornConfig.chemicalReactorMaxEnergy, TRContent.Machine.CHEMICAL_REACTOR.block, 3);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2 };
|
final int[] outputs = new int[] { 2 };
|
||||||
this.inventory = new RebornInventory<>(4, "ChemicalReactorBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(4, "ChemicalReactorBlockEntity", 64, this);
|
||||||
|
|
|
@ -29,25 +29,17 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.ModRecipes;
|
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.ModRecipes;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class CompressorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class CompressorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "compressor", key = "CompressorInput", comment = "Compressor Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "compressor", key = "CompressorMaxEnergy", comment = "Compressor Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1000;
|
|
||||||
|
|
||||||
public CompressorBlockEntity() {
|
public CompressorBlockEntity() {
|
||||||
super(TRBlockEntities.COMPRESSOR, "Compressor", maxInput, maxEnergy, TRContent.Machine.COMPRESSOR.block, 2);
|
super(TRBlockEntities.COMPRESSOR, "Compressor", TechRebornConfig.compressorMaxInput, TechRebornConfig.compressorMaxEnergy, TRContent.Machine.COMPRESSOR.block, 2);
|
||||||
final int[] inputs = new int[] { 0 };
|
final int[] inputs = new int[] { 0 };
|
||||||
final int[] outputs = new int[] { 1 };
|
final int[] outputs = new int[] { 1 };
|
||||||
this.inventory = new RebornInventory<>(3, "CompressorBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(3, "CompressorBlockEntity", 64, this);
|
||||||
|
|
|
@ -36,23 +36,15 @@ import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.blocks.BlockMachineBase;
|
import reborncore.common.blocks.BlockMachineBase;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.utils.RecipeUtils;
|
import techreborn.utils.RecipeUtils;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ElectricFurnaceBlockEntity extends PowerAcceptorBlockEntity
|
public class ElectricFurnaceBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "electric_furnace", key = "ElectricFurnaceInput", comment = "Electric Furnace Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "electric_furnace", key = "ElectricFurnaceMaxEnergy", comment = "Electric Furnace Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1000;
|
|
||||||
|
|
||||||
public RebornInventory<ElectricFurnaceBlockEntity> inventory = new RebornInventory<>(3, "ElectricFurnaceBlockEntity", 64, this);
|
public RebornInventory<ElectricFurnaceBlockEntity> inventory = new RebornInventory<>(3, "ElectricFurnaceBlockEntity", 64, this);
|
||||||
public int progress;
|
public int progress;
|
||||||
public int fuelScale = 100;
|
public int fuelScale = 100;
|
||||||
|
@ -179,7 +171,7 @@ public class ElectricFurnaceBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.electricFurnaceMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -199,7 +191,7 @@ public class ElectricFurnaceBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.electricFurnaceMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
// IToolDrop
|
// IToolDrop
|
||||||
|
|
|
@ -29,25 +29,17 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.ModRecipes;
|
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.ModRecipes;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ExtractorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class ExtractorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "extractor", key = "ExtractorInput", comment = "Extractor Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "extractor", key = "ExtractorMaxEnergy", comment = "Extractor Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1_000;
|
|
||||||
|
|
||||||
public ExtractorBlockEntity() {
|
public ExtractorBlockEntity() {
|
||||||
super(TRBlockEntities.EXTRACTOR, "Extractor", maxInput, maxEnergy, TRContent.Machine.EXTRACTOR.block, 2);
|
super(TRBlockEntities.EXTRACTOR, "Extractor", TechRebornConfig.extractorMaxInput, TechRebornConfig.extractorMaxEnergy, TRContent.Machine.EXTRACTOR.block, 2);
|
||||||
final int[] inputs = new int[] { 0 };
|
final int[] inputs = new int[] { 0 };
|
||||||
final int[] outputs = new int[] { 1 };
|
final int[] outputs = new int[] { 1 };
|
||||||
this.inventory = new RebornInventory<>(3, "ExtractorBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(3, "ExtractorBlockEntity", 64, this);
|
||||||
|
|
|
@ -29,25 +29,17 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.ModRecipes;
|
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.ModRecipes;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class GrinderBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class GrinderBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "grinder", key = "GrinderInput", comment = "Grinder Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "grinder", key = "GrinderMaxEnergy", comment = "Grinder Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1_000;
|
|
||||||
|
|
||||||
public GrinderBlockEntity() {
|
public GrinderBlockEntity() {
|
||||||
super(TRBlockEntities.GRINDER, "Grinder", maxInput, maxEnergy, TRContent.Machine.GRINDER.block, 2);
|
super(TRBlockEntities.GRINDER, "Grinder", TechRebornConfig.grinderMaxInput, TechRebornConfig.grinderMaxEnergy, TRContent.Machine.GRINDER.block, 2);
|
||||||
final int[] inputs = new int[] { 0 };
|
final int[] inputs = new int[] { 0 };
|
||||||
final int[] outputs = new int[] { 1 };
|
final int[] outputs = new int[] { 1 };
|
||||||
this.inventory = new RebornInventory<>(3, "GrinderBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(3, "GrinderBlockEntity", 64, this);
|
||||||
|
|
|
@ -29,27 +29,19 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.recipes.RecipeCrafter;
|
import reborncore.common.recipes.RecipeCrafter;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.items.ItemDynamicCell;
|
import techreborn.items.ItemDynamicCell;
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class IndustrialElectrolyzerBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class IndustrialElectrolyzerBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_electrolyzer", key = "IndustrialElectrolyzerMaxInput", comment = "Industrial Electrolyzer Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 128;
|
|
||||||
@ConfigRegistry(config = "machines", category = "industrial_electrolyzer", key = "IndustrialElectrolyzerMaxEnergy", comment = "Industrial Electrolyzer Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
|
|
||||||
public IndustrialElectrolyzerBlockEntity() {
|
public IndustrialElectrolyzerBlockEntity() {
|
||||||
super(TRBlockEntities.INDUSTRIAL_ELECTROLYZER, "IndustrialElectrolyzer", maxInput, maxEnergy, TRContent.Machine.INDUSTRIAL_ELECTROLYZER.block, 6);
|
super(TRBlockEntities.INDUSTRIAL_ELECTROLYZER, "IndustrialElectrolyzer", TechRebornConfig.industrialElectrolyzerMaxInput, TechRebornConfig.industrialElectrolyzerMaxEnergy, TRContent.Machine.INDUSTRIAL_ELECTROLYZER.block, 6);
|
||||||
final int[] inputs = new int[] { 0, 1 };
|
final int[] inputs = new int[] { 0, 1 };
|
||||||
final int[] outputs = new int[] { 2, 3, 4, 5 };
|
final int[] outputs = new int[] { 2, 3, 4, 5 };
|
||||||
this.inventory = new RebornInventory<>(7, "IndustrialElectrolyzerBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(7, "IndustrialElectrolyzerBlockEntity", 64, this);
|
||||||
|
|
|
@ -30,24 +30,17 @@ import net.minecraft.nbt.CompoundTag;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import reborncore.api.IToolDrop;
|
import reborncore.api.IToolDrop;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import reborncore.common.config.Config;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.WorldUtils;
|
import reborncore.common.util.WorldUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.blocks.tier1.BlockPlayerDetector;
|
import techreborn.blocks.tier1.BlockPlayerDetector;
|
||||||
import techreborn.blocks.tier1.BlockPlayerDetector.PlayerDetectorType;
|
import techreborn.blocks.tier1.BlockPlayerDetector.PlayerDetectorType;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class PlayerDectectorBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
public class PlayerDectectorBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "player_detector", key = "PlayerDetectorMaxInput", comment = "Player Detector Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "player_detector", key = "PlayerDetectorMaxEnergy", comment = "Player Detector Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10000;
|
|
||||||
@ConfigRegistry(config = "machines", category = "player_detector", key = "PlayerDetectorEUPerSecond", comment = "Player Detector Energy Consumption per second (Value in EU)")
|
|
||||||
public static int euPerTick = 10;
|
|
||||||
|
|
||||||
public String owenerUdid = "";
|
public String owenerUdid = "";
|
||||||
boolean redstone = false;
|
boolean redstone = false;
|
||||||
|
@ -67,7 +60,7 @@ public class PlayerDectectorBlockEntity extends PowerAcceptorBlockEntity impleme
|
||||||
if (!world.isClient && world.getTime() % 20 == 0) {
|
if (!world.isClient && world.getTime() % 20 == 0) {
|
||||||
boolean lastRedstone = redstone;
|
boolean lastRedstone = redstone;
|
||||||
redstone = false;
|
redstone = false;
|
||||||
if (canUseEnergy(euPerTick)) {
|
if (canUseEnergy(TechRebornConfig.playerDetectorEuPerTick)) {
|
||||||
for(PlayerEntity player : world.getPlayers()){
|
for(PlayerEntity player : world.getPlayers()){
|
||||||
if (player.distanceTo(player) <= 256.0D) {
|
if (player.distanceTo(player) <= 256.0D) {
|
||||||
PlayerDetectorType type = world.getBlockState(pos).get(BlockPlayerDetector.TYPE);
|
PlayerDetectorType type = world.getBlockState(pos).get(BlockPlayerDetector.TYPE);
|
||||||
|
@ -84,7 +77,7 @@ public class PlayerDectectorBlockEntity extends PowerAcceptorBlockEntity impleme
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
useEnergy(euPerTick);
|
useEnergy(TechRebornConfig.playerDetectorEuPerTick);
|
||||||
}
|
}
|
||||||
if (lastRedstone != redstone) {
|
if (lastRedstone != redstone) {
|
||||||
WorldUtils.updateBlock(world, pos);
|
WorldUtils.updateBlock(world, pos);
|
||||||
|
@ -95,7 +88,7 @@ public class PlayerDectectorBlockEntity extends PowerAcceptorBlockEntity impleme
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.playerDetectorMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -115,7 +108,7 @@ public class PlayerDectectorBlockEntity extends PowerAcceptorBlockEntity impleme
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.playerDetectorMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -36,24 +36,14 @@ import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.blocks.BlockMachineBase;
|
import reborncore.common.blocks.BlockMachineBase;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class RecyclerBlockEntity extends PowerAcceptorBlockEntity
|
public class RecyclerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "recycler", key = "RecyclerInput", comment = "Recycler Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "recycler", key = "RecyclerMaxEnergy", comment = "Recycler Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1000;
|
|
||||||
@ConfigRegistry(config = "machines", category = "recycler", key = "produceIC2Scrap", comment = "When enabled and when ic2 is installed the recycler will make ic2 scrap")
|
|
||||||
public static boolean produceIC2Scrap = false;
|
|
||||||
|
|
||||||
private final RebornInventory<RecyclerBlockEntity> inventory = new RebornInventory<>(3, "RecyclerBlockEntity", 64, this);
|
private final RebornInventory<RecyclerBlockEntity> inventory = new RebornInventory<>(3, "RecyclerBlockEntity", 64, this);
|
||||||
private final int cost = 2;
|
private final int cost = 2;
|
||||||
private final int time = 15;
|
private final int time = 15;
|
||||||
|
@ -159,7 +149,7 @@ public class RecyclerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.recyclerMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -179,7 +169,7 @@ public class RecyclerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.recyclerMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TileMachineBase
|
// TileMachineBase
|
||||||
|
|
|
@ -40,17 +40,14 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.blocks.BlockMachineBase;
|
import reborncore.common.blocks.BlockMachineBase;
|
||||||
import reborncore.common.crafting.RecipeManager;
|
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.api.recipe.recipes.RollingMachineRecipe;
|
import techreborn.api.recipe.recipes.RollingMachineRecipe;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
import javax.annotation.Nonnull;
|
import javax.annotation.Nonnull;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
@ -61,19 +58,9 @@ import java.util.stream.Collectors;
|
||||||
|
|
||||||
//TODO add tick and power bars.
|
//TODO add tick and power bars.
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "rolling_machine", key = "RollingMachineMaxInput", comment = "Rolling Machine Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "rolling_machine", key = "RollingMachineEnergyPerTick", comment = "Rolling Machine Energy Per Tick (Value in EU)")
|
|
||||||
public static int energyPerTick = 5;
|
|
||||||
@ConfigRegistry(config = "machines", category = "rolling_machine", key = "RollingMachineEnergyRunTime", comment = "Rolling Machine Run Time")
|
|
||||||
public static int runTime = 250;
|
|
||||||
@ConfigRegistry(config = "machines", category = "rolling_machine", key = "RollingMachineMaxEnergy", comment = "Rolling Machine Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10000;
|
|
||||||
|
|
||||||
public int[] craftingSlots = new int[] { 0, 1, 2, 3, 4, 5, 6, 7, 8 };
|
public int[] craftingSlots = new int[] { 0, 1, 2, 3, 4, 5, 6, 7, 8 };
|
||||||
private CraftingInventory craftCache;
|
private CraftingInventory craftCache;
|
||||||
public RebornInventory<RollingMachineBlockEntity> inventory = new RebornInventory<>(12, "RollingMachineBlockEntity", 64, this);
|
public RebornInventory<RollingMachineBlockEntity> inventory = new RebornInventory<>(12, "RollingMachineBlockEntity", 64, this);
|
||||||
|
@ -93,7 +80,7 @@ public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.rollingMachineMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -113,7 +100,7 @@ public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.rollingMachineMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -140,7 +127,7 @@ public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!currentRecipeOutput.isEmpty() && canMake(craftMatrix)) {
|
if (!currentRecipeOutput.isEmpty() && canMake(craftMatrix)) {
|
||||||
if (tickTime >= Math.max((int) (runTime * (1.0 - getSpeedMultiplier())), 1)) {
|
if (tickTime >= Math.max((int) (TechRebornConfig.rollingMachineRunTime * (1.0 - getSpeedMultiplier())), 1)) {
|
||||||
currentRecipeOutput = findMatchingRecipeOutput(craftMatrix, world);
|
currentRecipeOutput = findMatchingRecipeOutput(craftMatrix, world);
|
||||||
if (!currentRecipeOutput.isEmpty()) {
|
if (!currentRecipeOutput.isEmpty()) {
|
||||||
boolean hasCrafted = false;
|
boolean hasCrafted = false;
|
||||||
|
@ -173,10 +160,10 @@ public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
||||||
tickTime = 0;
|
tickTime = 0;
|
||||||
}
|
}
|
||||||
if (!currentRecipeOutput.isEmpty()) {
|
if (!currentRecipeOutput.isEmpty()) {
|
||||||
if (canUseEnergy(getEuPerTick(energyPerTick))
|
if (canUseEnergy(getEuPerTick(TechRebornConfig.rollingMachineEnergyPerTick))
|
||||||
&& tickTime < Math.max((int) (runTime * (1.0 - getSpeedMultiplier())), 1)
|
&& tickTime < Math.max((int) (TechRebornConfig.rollingMachineRunTime * (1.0 - getSpeedMultiplier())), 1)
|
||||||
&& canMake(craftMatrix)) {
|
&& canMake(craftMatrix)) {
|
||||||
useEnergy(getEuPerTick(energyPerTick));
|
useEnergy(getEuPerTick(TechRebornConfig.rollingMachineEnergyPerTick));
|
||||||
tickTime++;
|
tickTime++;
|
||||||
} else {
|
} else {
|
||||||
setIsActive(false);
|
setIsActive(false);
|
||||||
|
@ -392,10 +379,10 @@ public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getBurnTimeRemainingScaled(final int scale) {
|
public int getBurnTimeRemainingScaled(final int scale) {
|
||||||
if (tickTime == 0 || Math.max((int) (runTime* (1.0 - getSpeedMultiplier())), 1) == 0) {
|
if (tickTime == 0 || Math.max((int) (TechRebornConfig.rollingMachineRunTime* (1.0 - getSpeedMultiplier())), 1) == 0) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
return tickTime * scale / Math.max((int) (runTime* (1.0 - getSpeedMultiplier())), 1);
|
return tickTime * scale / Math.max((int) (TechRebornConfig.rollingMachineRunTime* (1.0 - getSpeedMultiplier())), 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -422,8 +409,8 @@ public class RollingMachineBlockEntity extends PowerAcceptorBlockEntity
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getProgressScaled(final int scale) {
|
public int getProgressScaled(final int scale) {
|
||||||
if (tickTime != 0 && Math.max((int) (runTime* (1.0 - getSpeedMultiplier())), 1) != 0) {
|
if (tickTime != 0 && Math.max((int) (TechRebornConfig.rollingMachineRunTime* (1.0 - getSpeedMultiplier())), 1) != 0) {
|
||||||
return tickTime * scale / Math.max((int) (runTime* (1.0 - getSpeedMultiplier())), 1);
|
return tickTime * scale / Math.max((int) (TechRebornConfig.rollingMachineRunTime* (1.0 - getSpeedMultiplier())), 1);
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,25 +28,17 @@ import net.minecraft.entity.player.PlayerEntity;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.api.recipe.ScrapboxRecipeCrafter;
|
import techreborn.api.recipe.ScrapboxRecipeCrafter;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.GenericMachineBlockEntity;
|
import techreborn.blockentity.GenericMachineBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ScrapboxinatorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
public class ScrapboxinatorBlockEntity extends GenericMachineBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "scrapboxinator", key = "ScrapboxinatorMaxInput", comment = "Scrapboxinator Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "scrapboxinator", key = "ScrapboxinatorMaxEnergy", comment = "Scrapboxinator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 1_000;
|
|
||||||
|
|
||||||
public ScrapboxinatorBlockEntity() {
|
public ScrapboxinatorBlockEntity() {
|
||||||
super(TRBlockEntities.SCRAPBOXINATOR, "Scrapboxinator", maxInput, maxEnergy, TRContent.Machine.SCRAPBOXINATOR.block, 2);
|
super(TRBlockEntities.SCRAPBOXINATOR, "Scrapboxinator", TechRebornConfig.scrapboxinatorMaxInput, TechRebornConfig.scrapboxinatorMaxEnergy, TRContent.Machine.SCRAPBOXINATOR.block, 2);
|
||||||
final int[] inputs = new int[] { 0 };
|
final int[] inputs = new int[] { 0 };
|
||||||
final int[] outputs = new int[] { 1 };
|
final int[] outputs = new int[] { 1 };
|
||||||
this.inventory = new RebornInventory<>(3, "ScrapboxinatorBlockEntity", 64, this);
|
this.inventory = new RebornInventory<>(3, "ScrapboxinatorBlockEntity", 64, this);
|
||||||
|
|
|
@ -33,28 +33,15 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ChunkLoaderBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop, InventoryProvider, IContainerProvider {
|
public class ChunkLoaderBlockEntity extends PowerAcceptorBlockEntity implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "chunk_loader", key = "ChunkLoaderMaxInput", comment = "Chunk Loader Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 32;
|
|
||||||
@ConfigRegistry(config = "machines", category = "chunk_loader", key = "ChunkLoaderMaxEnergy", comment = "Chunk Loader Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000;
|
|
||||||
// @ConfigRegistry(config = "machines", category = "chunk_loader", key = "ChunkLoaderWrenchDropRate", comment = "Chunk Loader Wrench Drop Rate")
|
|
||||||
public static float wrenchDropRate = 1.0F;
|
|
||||||
|
|
||||||
public RebornInventory<ChunkLoaderBlockEntity> inventory = new RebornInventory<>(1, "ChunkLoaderBlockEntity", 64, this);
|
public RebornInventory<ChunkLoaderBlockEntity> inventory = new RebornInventory<>(1, "ChunkLoaderBlockEntity", 64, this);
|
||||||
|
|
||||||
public boolean isRunning;
|
|
||||||
public int tickTime;
|
|
||||||
|
|
||||||
public ChunkLoaderBlockEntity() {
|
public ChunkLoaderBlockEntity() {
|
||||||
super(TRBlockEntities.CHUNK_LOADER );
|
super(TRBlockEntities.CHUNK_LOADER );
|
||||||
}
|
}
|
||||||
|
@ -64,13 +51,9 @@ public class ChunkLoaderBlockEntity extends PowerAcceptorBlockEntity implements
|
||||||
return TRContent.Machine.CHUNK_LOADER.getStack();
|
return TRContent.Machine.CHUNK_LOADER.getStack();
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isComplete() {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.chunkLoaderMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -90,7 +73,7 @@ public class ChunkLoaderBlockEntity extends PowerAcceptorBlockEntity implements
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.chunkLoaderMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -33,27 +33,17 @@ import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import reborncore.common.config.Config;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class MatterFabricatorBlockEntity extends PowerAcceptorBlockEntity
|
public class MatterFabricatorBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, InventoryProvider, IContainerProvider {
|
implements IToolDrop, InventoryProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "matter_fabricator", key = "MatterFabricatorMaxInput", comment = "Matter Fabricator Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 8192;
|
|
||||||
@ConfigRegistry(config = "machines", category = "matter_fabricator", key = "MatterFabricatorMaxEnergy", comment = "Matter Fabricator Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 10_000_000;
|
|
||||||
@ConfigRegistry(config = "machines", category = "matter_fabricator", key = "MatterFabricatorFabricationRate", comment = "Matter Fabricator Fabrication Rate, amount of amplifier units per UUM")
|
|
||||||
public static int fabricationRate = 6_000;
|
|
||||||
@ConfigRegistry(config = "machines", category = "matter_fabricator", key = "MatterFabricatorEnergyPerAmp", comment = "Matter Fabricator EU per amplifier unit, multiply this with the rate for total EU")
|
|
||||||
public static int energyPerAmp = 5;
|
|
||||||
|
|
||||||
public RebornInventory<MatterFabricatorBlockEntity> inventory = new RebornInventory<>(12, "MatterFabricatorBlockEntity", 64, this);
|
public RebornInventory<MatterFabricatorBlockEntity> inventory = new RebornInventory<>(12, "MatterFabricatorBlockEntity", 64, this);
|
||||||
private int amplifier = 0;
|
private int amplifier = 0;
|
||||||
|
|
||||||
|
@ -127,7 +117,7 @@ public class MatterFabricatorBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
public int getProgressScaled(int scale) {
|
public int getProgressScaled(int scale) {
|
||||||
if (amplifier != 0) {
|
if (amplifier != 0) {
|
||||||
return Math.min(amplifier * scale / fabricationRate, 100);
|
return Math.min(amplifier * scale / TechRebornConfig.matterFabricatorFabricationRate, 100);
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -146,7 +136,7 @@ public class MatterFabricatorBlockEntity extends PowerAcceptorBlockEntity
|
||||||
final ItemStack stack = inventory.getInvStack(i);
|
final ItemStack stack = inventory.getInvStack(i);
|
||||||
if (!stack.isEmpty() && spaceForOutput()) {
|
if (!stack.isEmpty() && spaceForOutput()) {
|
||||||
final int amp = getValue(stack);
|
final int amp = getValue(stack);
|
||||||
final int euNeeded = amp * energyPerAmp;
|
final int euNeeded = amp * TechRebornConfig.matterFabricatorEnergyPerAmp;
|
||||||
if (amp != 0 && this.canUseEnergy(euNeeded)) {
|
if (amp != 0 && this.canUseEnergy(euNeeded)) {
|
||||||
useEnergy(euNeeded);
|
useEnergy(euNeeded);
|
||||||
amplifier += amp;
|
amplifier += amp;
|
||||||
|
@ -155,17 +145,17 @@ public class MatterFabricatorBlockEntity extends PowerAcceptorBlockEntity
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (amplifier >= fabricationRate) {
|
if (amplifier >= TechRebornConfig.matterFabricatorFabricationRate) {
|
||||||
if (spaceForOutput()) {
|
if (spaceForOutput()) {
|
||||||
addOutputProducts();
|
addOutputProducts();
|
||||||
amplifier -= fabricationRate;
|
amplifier -= TechRebornConfig.matterFabricatorFabricationRate;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxPower() {
|
public double getBaseMaxPower() {
|
||||||
return maxEnergy;
|
return TechRebornConfig.matterFabricatorMaxEnergy;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -185,7 +175,7 @@ public class MatterFabricatorBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public double getBaseMaxInput() {
|
public double getBaseMaxInput() {
|
||||||
return maxInput;
|
return TechRebornConfig.matterFabricatorMaxInput;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TileMachineBase
|
// TileMachineBase
|
||||||
|
|
|
@ -29,24 +29,18 @@ import net.minecraft.entity.player.PlayerEntity;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.TRBlockEntities;
|
|
||||||
import techreborn.blockentity.TechStorageBaseBlockEntity;
|
import techreborn.blockentity.TechStorageBaseBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class QuantumChestBlockEntity extends TechStorageBaseBlockEntity implements IContainerProvider {
|
public class QuantumChestBlockEntity extends TechStorageBaseBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "quantum_chest", key = "QuantumChestMaxStorage", comment = "Maximum amount of items a Quantum Chest can store")
|
|
||||||
public static int maxStorage = Integer.MAX_VALUE;
|
|
||||||
|
|
||||||
public QuantumChestBlockEntity() {
|
public QuantumChestBlockEntity() {
|
||||||
this(TRBlockEntities.QUANTUM_CHEST);
|
this(TRBlockEntities.QUANTUM_CHEST);
|
||||||
}
|
}
|
||||||
|
|
||||||
public QuantumChestBlockEntity(BlockEntityType<?> blockEntityType) {
|
public QuantumChestBlockEntity(BlockEntityType<?> blockEntityType) {
|
||||||
super(blockEntityType, "QuantumChestBlockEntity", maxStorage);
|
super(blockEntityType, "QuantumChestBlockEntity", TechRebornConfig.quantumChestMaxStorage);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -36,12 +36,10 @@ import reborncore.api.blockentity.InventoryProvider;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.blockentity.MachineBaseBlockEntity;
|
import reborncore.common.blockentity.MachineBaseBlockEntity;
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import reborncore.common.util.Tank;
|
import reborncore.common.util.Tank;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.utils.FluidUtils;
|
import techreborn.utils.FluidUtils;
|
||||||
|
@ -49,14 +47,10 @@ import techreborn.utils.FluidUtils;
|
||||||
import javax.annotation.Nullable;
|
import javax.annotation.Nullable;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class QuantumTankBlockEntity extends MachineBaseBlockEntity
|
public class QuantumTankBlockEntity extends MachineBaseBlockEntity
|
||||||
implements InventoryProvider, IToolDrop, IListInfoProvider, IContainerProvider {
|
implements InventoryProvider, IToolDrop, IListInfoProvider, IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "quantum_tank", key = "QuantumTankMaxStorage", comment = "Maximum amount of millibuckets a Quantum Tank can store")
|
public Tank tank = new Tank("QuantumTankBlockEntity", TechRebornConfig.quantumTankMaxStorage, this);
|
||||||
public static int maxStorage = Integer.MAX_VALUE;
|
|
||||||
|
|
||||||
public Tank tank = new Tank("QuantumTankBlockEntity", maxStorage, this);
|
|
||||||
public RebornInventory<QuantumTankBlockEntity> inventory = new RebornInventory<>(3, "QuantumTankBlockEntity", 64, this);
|
public RebornInventory<QuantumTankBlockEntity> inventory = new RebornInventory<>(3, "QuantumTankBlockEntity", 64, this);
|
||||||
|
|
||||||
public QuantumTankBlockEntity(){
|
public QuantumTankBlockEntity(){
|
||||||
|
|
|
@ -32,33 +32,21 @@ import reborncore.api.blockentity.IUpgrade;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.RebornInventory;
|
import reborncore.common.util.RebornInventory;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class AdjustableSUBlockEntity extends EnergyStorageBlockEntity implements IContainerProvider {
|
public class AdjustableSUBlockEntity extends EnergyStorageBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "aesu", key = "AesuMaxInput", comment = "AESU Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 16192;
|
|
||||||
@ConfigRegistry(config = "machines", category = "aesu", key = "AesuMaxOutput", comment = "AESU Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 16192;
|
|
||||||
@ConfigRegistry(config = "machines", category = "aesu", key = "AesuMaxEnergy", comment = "AESU Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 100_000_000;
|
|
||||||
|
|
||||||
public RebornInventory<AdjustableSUBlockEntity> inventory = new RebornInventory<>(4, "AdjustableSUBlockEntity", 64, this);
|
public RebornInventory<AdjustableSUBlockEntity> inventory = new RebornInventory<>(4, "AdjustableSUBlockEntity", 64, this);
|
||||||
private int OUTPUT = 64; // The current output
|
private int OUTPUT = 64; // The current output
|
||||||
public int superconductors = 0;
|
public int superconductors = 0;
|
||||||
|
|
||||||
public AdjustableSUBlockEntity() {
|
public AdjustableSUBlockEntity() {
|
||||||
super(TRBlockEntities.ADJUSTABLE_SU, "ADJUSTABLE_SU", 4, TRContent.Machine.ADJUSTABLE_SU.block, EnumPowerTier.INSANE, maxInput, maxOutput, maxEnergy);
|
super(TRBlockEntities.ADJUSTABLE_SU, "ADJUSTABLE_SU", 4, TRContent.Machine.ADJUSTABLE_SU.block, EnumPowerTier.INSANE, TechRebornConfig.aesuMaxInput, TechRebornConfig.aesuMaxOutput, TechRebornConfig.aesuMaxEnergy);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void tick() {
|
public void tick() {
|
||||||
super.tick();
|
super.tick();
|
||||||
|
|
|
@ -31,27 +31,17 @@ import reborncore.api.power.EnumPowerTier;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import techreborn.config.TechRebornConfig;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.blockentity.storage.EnergyStorageBlockEntity;
|
import techreborn.blockentity.storage.EnergyStorageBlockEntity;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class InterdimensionalSUBlockEntity extends EnergyStorageBlockEntity implements IContainerProvider {
|
public class InterdimensionalSUBlockEntity extends EnergyStorageBlockEntity implements IContainerProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "machines", category = "idsu", key = "IdsuMaxInput", comment = "IDSU Max Input (Value in EU)")
|
|
||||||
public static int maxInput = 8192;
|
|
||||||
@ConfigRegistry(config = "machines", category = "idsu", key = "IdsuMaxOutput", comment = "IDSU Max Output (Value in EU)")
|
|
||||||
public static int maxOutput = 8192;
|
|
||||||
@ConfigRegistry(config = "machines", category = "idsu", key = "IdsuMaxEnergy", comment = "IDSU Max Energy (Value in EU)")
|
|
||||||
public static int maxEnergy = 100_000_000;
|
|
||||||
|
|
||||||
public String ownerUdid;
|
public String ownerUdid;
|
||||||
|
|
||||||
public InterdimensionalSUBlockEntity() {
|
public InterdimensionalSUBlockEntity() {
|
||||||
super(TRBlockEntities.INTERDIMENSIONAL_SU, "IDSU", 2, TRContent.Machine.INTERDIMENSIONAL_SU.block, EnumPowerTier.EXTREME, maxInput, maxOutput, maxEnergy);
|
super(TRBlockEntities.INTERDIMENSIONAL_SU, "IDSU", 2, TRContent.Machine.INTERDIMENSIONAL_SU.block, EnumPowerTier.EXTREME, TechRebornConfig.idsuMaxInput, TechRebornConfig.idsuMaxOutput, TechRebornConfig.idsuMaxEnergy);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -33,33 +33,21 @@ import reborncore.api.power.EnumPowerTier;
|
||||||
import reborncore.client.containerBuilder.IContainerProvider;
|
import reborncore.client.containerBuilder.IContainerProvider;
|
||||||
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
import reborncore.client.containerBuilder.builder.BuiltContainer;
|
||||||
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
import reborncore.client.containerBuilder.builder.ContainerBuilder;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.blockentity.storage.EnergyStorageBlockEntity;
|
import techreborn.blockentity.storage.EnergyStorageBlockEntity;
|
||||||
import techreborn.blocks.storage.BlockLapotronicSU;
|
import techreborn.blocks.storage.BlockLapotronicSU;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRBlockEntities;
|
import techreborn.init.TRBlockEntities;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class LapotronicSUBlockEntity extends EnergyStorageBlockEntity implements IContainerProvider{
|
public class LapotronicSUBlockEntity extends EnergyStorageBlockEntity implements IContainerProvider{
|
||||||
|
|
||||||
// @ConfigRegistry(config = "machines", category = "lesu", key = "LesuMaxInput", comment = "LESU Max Input (Value in EU)")
|
|
||||||
// public static int maxInput = 8192;
|
|
||||||
@ConfigRegistry(config = "machines", category = "lesu", key = "LesuMaxOutput", comment = "LESU Base Output (Value in EU)")
|
|
||||||
public static int baseOutput = 16;
|
|
||||||
@ConfigRegistry(config = "machines", category = "lesu", key = "LesuMaxEnergyPerBlock", comment = "LESU Max Energy Per Block (Value in EU)")
|
|
||||||
public static int storagePerBlock = 1_000_000;
|
|
||||||
@ConfigRegistry(config = "machines", category = "lesu", key = "LesuExtraIO", comment = "LESU Extra I/O Multiplier")
|
|
||||||
public static int extraIOPerBlock = 8;
|
|
||||||
|
|
||||||
public int connectedBlocks = 0;
|
public int connectedBlocks = 0;
|
||||||
private ArrayList<LesuNetwork> countedNetworks = new ArrayList<>();
|
private ArrayList<LesuNetwork> countedNetworks = new ArrayList<>();
|
||||||
|
|
||||||
public LapotronicSUBlockEntity() {
|
public LapotronicSUBlockEntity() {
|
||||||
super(TRBlockEntities.LAPOTRONIC_SU, "LESU", 2, TRContent.Machine.LAPOTRONIC_SU.block, EnumPowerTier.INSANE, 8192, baseOutput, 1_000_000);
|
super(TRBlockEntities.LAPOTRONIC_SU, "LESU", 2, TRContent.Machine.LAPOTRONIC_SU.block, EnumPowerTier.INSANE, 8192, TechRebornConfig.lesuBaseOutput, 1_000_000);
|
||||||
checkOverfill = false;
|
checkOverfill = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -93,7 +81,7 @@ public class LapotronicSUBlockEntity extends EnergyStorageBlockEntity implements
|
||||||
|
|
||||||
}
|
}
|
||||||
setMaxStorage();
|
setMaxStorage();
|
||||||
maxOutput = (connectedBlocks * extraIOPerBlock) + baseOutput;
|
maxOutput = (connectedBlocks * TechRebornConfig.lesuExtraIOPerBlock) + TechRebornConfig.lesuBaseOutput;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -125,7 +113,7 @@ public class LapotronicSUBlockEntity extends EnergyStorageBlockEntity implements
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setMaxStorage(){
|
public void setMaxStorage(){
|
||||||
maxStorage = (connectedBlocks + 1) * storagePerBlock;
|
maxStorage = (connectedBlocks + 1) * TechRebornConfig.lesuStoragePerBlock;
|
||||||
if (maxStorage < 0 || maxStorage > Integer.MAX_VALUE) {
|
if (maxStorage < 0 || maxStorage > Integer.MAX_VALUE) {
|
||||||
maxStorage = Integer.MAX_VALUE;
|
maxStorage = Integer.MAX_VALUE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,23 +37,20 @@ import reborncore.api.IToolDrop;
|
||||||
import reborncore.api.power.EnumPowerTier;
|
import reborncore.api.power.EnumPowerTier;
|
||||||
import reborncore.common.powerSystem.PowerSystem;
|
import reborncore.common.powerSystem.PowerSystem;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import reborncore.common.config.Config;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.StringUtils;
|
import reborncore.common.util.StringUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.blocks.transformers.BlockTransformer;
|
import techreborn.blocks.transformers.BlockTransformer;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by Rushmead
|
* Created by Rushmead
|
||||||
*/
|
*/
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class TransformerBlockEntity extends PowerAcceptorBlockEntity
|
public class TransformerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
implements IToolDrop, IListInfoProvider {
|
implements IToolDrop, IListInfoProvider {
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "general", key = "IC2TransformersStyle", comment = "Input from dots side, output from other sides, like in IC2.")
|
|
||||||
public static boolean IC2TransformersStyle = true;
|
|
||||||
|
|
||||||
public String name;
|
public String name;
|
||||||
public Block wrenchDrop;
|
public Block wrenchDrop;
|
||||||
|
@ -89,7 +86,7 @@ public class TransformerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canAcceptEnergy(Direction direction) {
|
public boolean canAcceptEnergy(Direction direction) {
|
||||||
if (IC2TransformersStyle){
|
if (TechRebornConfig.IC2TransformersStyle){
|
||||||
return getFacingEnum() == direction;
|
return getFacingEnum() == direction;
|
||||||
}
|
}
|
||||||
return getFacingEnum() != direction;
|
return getFacingEnum() != direction;
|
||||||
|
@ -97,7 +94,7 @@ public class TransformerBlockEntity extends PowerAcceptorBlockEntity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canProvideEnergy(Direction direction) {
|
public boolean canProvideEnergy(Direction direction) {
|
||||||
if (IC2TransformersStyle){
|
if (TechRebornConfig.IC2TransformersStyle){
|
||||||
return getFacingEnum() != direction;
|
return getFacingEnum() != direction;
|
||||||
}
|
}
|
||||||
return getFacing() == direction;
|
return getFacing() == direction;
|
||||||
|
|
|
@ -48,10 +48,8 @@ import net.minecraft.world.World;
|
||||||
import reborncore.api.ToolManager;
|
import reborncore.api.ToolManager;
|
||||||
import reborncore.api.power.EnergyBlockEntity;
|
import reborncore.api.power.EnergyBlockEntity;
|
||||||
import reborncore.common.blocks.BlockWrenchEventHandler;
|
import reborncore.common.blocks.BlockWrenchEventHandler;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import reborncore.common.util.WrenchUtils;
|
import reborncore.common.util.WrenchUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModSounds;
|
import techreborn.init.ModSounds;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.blockentity.cable.CableBlockEntity;
|
import techreborn.blockentity.cable.CableBlockEntity;
|
||||||
|
@ -62,7 +60,6 @@ import javax.annotation.Nullable;
|
||||||
/**
|
/**
|
||||||
* Created by modmuss50 on 19/05/2017.
|
* Created by modmuss50 on 19/05/2017.
|
||||||
*/
|
*/
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class BlockCable extends BlockWithEntity {
|
public class BlockCable extends BlockWithEntity {
|
||||||
|
|
||||||
public static final BooleanProperty EAST = BooleanProperty.of("east");
|
public static final BooleanProperty EAST = BooleanProperty.of("east");
|
||||||
|
@ -72,15 +69,6 @@ public class BlockCable extends BlockWithEntity {
|
||||||
public static final BooleanProperty UP = BooleanProperty.of("up");
|
public static final BooleanProperty UP = BooleanProperty.of("up");
|
||||||
public static final BooleanProperty DOWN = BooleanProperty.of("down");
|
public static final BooleanProperty DOWN = BooleanProperty.of("down");
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "cable", key = "uninsulatedElectrocutionDamage", comment = "When true an uninsulated cable will cause damage to entities")
|
|
||||||
public static boolean uninsulatedElectrocutionDamage = true;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "cable", key = "uninsulatedElectrocutionSound", comment = "When true an uninsulated cable will create a spark sound when an entity touches it")
|
|
||||||
public static boolean uninsulatedElectrocutionSound = true;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "cable", key = "uninsulatedElectrocutionParticles", comment = "When true an uninsulated cable will create a spark when an entity touches it")
|
|
||||||
public static boolean uninsulatedElectrocutionParticles = true;
|
|
||||||
|
|
||||||
public final TRContent.Cables type;
|
public final TRContent.Cables type;
|
||||||
|
|
||||||
public BlockCable(TRContent.Cables type) {
|
public BlockCable(TRContent.Cables type) {
|
||||||
|
@ -216,17 +204,17 @@ public class BlockCable extends BlockWithEntity {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (uninsulatedElectrocutionDamage) {
|
if (TechRebornConfig.uninsulatedElectrocutionDamage) {
|
||||||
if (type == TRContent.Cables.HV) {
|
if (type == TRContent.Cables.HV) {
|
||||||
entityIn.setOnFireFor(1);
|
entityIn.setOnFireFor(1);
|
||||||
}
|
}
|
||||||
entityIn.damage(new ElectrialShockSource(), 1F);
|
entityIn.damage(new ElectrialShockSource(), 1F);
|
||||||
}
|
}
|
||||||
if (uninsulatedElectrocutionSound) {
|
if (TechRebornConfig.uninsulatedElectrocutionSound) {
|
||||||
worldIn.playSound(null, entityIn.x, entityIn.y, entityIn.z, ModSounds.CABLE_SHOCK, SoundCategory.BLOCKS,
|
worldIn.playSound(null, entityIn.x, entityIn.y, entityIn.z, ModSounds.CABLE_SHOCK, SoundCategory.BLOCKS,
|
||||||
0.6F, 1F);
|
0.6F, 1F);
|
||||||
}
|
}
|
||||||
if (uninsulatedElectrocutionParticles) {
|
if (TechRebornConfig.uninsulatedElectrocutionParticles) {
|
||||||
worldIn.addParticle(ParticleTypes.CRIT, entityIn.x, entityIn.y, entityIn.z, 0, 0, 0);
|
worldIn.addParticle(ParticleTypes.CRIT, entityIn.x, entityIn.y, entityIn.z, 0, 0, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,7 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.explosion.Explosion;
|
import net.minecraft.world.explosion.Explosion;
|
||||||
import reborncore.common.BaseBlock;
|
import reborncore.common.BaseBlock;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.entities.EntityNukePrimed;
|
import techreborn.entities.EntityNukePrimed;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -68,7 +69,7 @@ public class BlockNuke extends BaseBlock {
|
||||||
if (!worldIn.isClient) {
|
if (!worldIn.isClient) {
|
||||||
EntityNukePrimed entitynukeprimed = new EntityNukePrimed(worldIn, (double) ((float) pos.getX() + 0.5F),
|
EntityNukePrimed entitynukeprimed = new EntityNukePrimed(worldIn, (double) ((float) pos.getX() + 0.5F),
|
||||||
(double) pos.getY(), (double) ((float) pos.getZ() + 0.5F), explosionIn.getCausingEntity());
|
(double) pos.getY(), (double) ((float) pos.getZ() + 0.5F), explosionIn.getCausingEntity());
|
||||||
entitynukeprimed.setFuse(worldIn.random.nextInt(EntityNukePrimed.fuseTime / 4) + EntityNukePrimed.fuseTime / 8);
|
entitynukeprimed.setFuse(worldIn.random.nextInt(TechRebornConfig.nukeFuseTime / 4) + TechRebornConfig.nukeFuseTime / 8);
|
||||||
worldIn.spawnEntity(entitynukeprimed);
|
worldIn.spawnEntity(entitynukeprimed);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,6 +33,7 @@ import net.minecraft.util.Identifier;
|
||||||
import net.minecraft.util.SystemUtil;
|
import net.minecraft.util.SystemUtil;
|
||||||
import reborncore.client.gui.builder.widget.GuiButtonExtended;
|
import reborncore.client.gui.builder.widget.GuiButtonExtended;
|
||||||
import reborncore.common.network.NetworkManager;
|
import reborncore.common.network.NetworkManager;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.items.ItemManual;
|
import techreborn.items.ItemManual;
|
||||||
import techreborn.packets.ServerboundPackets;
|
import techreborn.packets.ServerboundPackets;
|
||||||
|
|
||||||
|
@ -68,7 +69,7 @@ public class GuiManual extends Screen {
|
||||||
this.minecraft.openScreen(this);
|
this.minecraft.openScreen(this);
|
||||||
}
|
}
|
||||||
}, "https://discord.gg/teamreborn", false))));
|
}, "https://discord.gg/teamreborn", false))));
|
||||||
if(ItemManual.allowRefund){
|
if(TechRebornConfig.allowManualRefund){
|
||||||
addButton(new GuiButtonExtended((width / 2 - 30), y + 110, 60, 20, I18n.translate("techreborn.manual.refundbtn"), var1 -> {
|
addButton(new GuiButtonExtended((width / 2 - 30), y + 110, 60, 20, I18n.translate("techreborn.manual.refundbtn"), var1 -> {
|
||||||
NetworkManager.sendToServer(ServerboundPackets.createRefundPacket());
|
NetworkManager.sendToServer(ServerboundPackets.createRefundPacket());
|
||||||
this.minecraft.openScreen(null);
|
this.minecraft.openScreen(null);
|
||||||
|
@ -86,7 +87,7 @@ public class GuiManual extends Screen {
|
||||||
int y = height / 4;
|
int y = height / 4;
|
||||||
font.draw(text1, ((width / 2) - font.getStringWidth(text1) / 2), height / 2 - (guiHeight / 4), 4210752);
|
font.draw(text1, ((width / 2) - font.getStringWidth(text1) / 2), height / 2 - (guiHeight / 4), 4210752);
|
||||||
font.draw(text2, ((width / 2) - font.getStringWidth(text2) / 2), height / 2 + 5, 4210752);
|
font.draw(text2, ((width / 2) - font.getStringWidth(text2) / 2), height / 2 + 5, 4210752);
|
||||||
if (ItemManual.allowRefund) {
|
if (TechRebornConfig.allowManualRefund) {
|
||||||
font.draw(text3, ((width / 2) - font.getStringWidth(text3) / 2), y + 100, 4210752);
|
font.draw(text3, ((width / 2) - font.getStringWidth(text3) / 2), y + 100, 4210752);
|
||||||
}
|
}
|
||||||
super.render(mouseX, mouseY, partialTicks);
|
super.render(mouseX, mouseY, partialTicks);
|
||||||
|
|
|
@ -1,133 +0,0 @@
|
||||||
/*
|
|
||||||
* This file is part of TechReborn, licensed under the MIT License (MIT).
|
|
||||||
*
|
|
||||||
* Copyright (c) 2018 TechReborn
|
|
||||||
*
|
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
||||||
* of this software and associated documentation files (the "Software"), to deal
|
|
||||||
* in the Software without restriction, including without limitation the rights
|
|
||||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
* copies of the Software, and to permit persons to whom the Software is
|
|
||||||
* furnished to do so, subject to the following conditions:
|
|
||||||
*
|
|
||||||
* The above copyright notice and this permission notice shall be included in all
|
|
||||||
* copies or substantial portions of the Software.
|
|
||||||
*
|
|
||||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
||||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
||||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
||||||
* SOFTWARE.
|
|
||||||
*/
|
|
||||||
|
|
||||||
package techreborn.config;
|
|
||||||
|
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ConfigTechReborn {
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "general", key = "enableGemTools", comment = "Enable Gem armor and tools")
|
|
||||||
public static boolean enableGemArmorAndTools = true;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "nanoSaberCharge", comment = "Energy Capacity for Nano Saber (FE)")
|
|
||||||
public static int nanoSaberCharge = 4_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "basicDrillCharge", comment = "Energy Capacity for Basic Drill (FE)")
|
|
||||||
public static int BasicDrillCharge = 40_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "advancedDrillCharge", comment = "Energy Capacity for Advanced Drill (FE)")
|
|
||||||
public static int AdvancedDrillCharge = 400_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "industrialDrillCharge", comment = "Energy Capacity for Industrial Drill (FE)")
|
|
||||||
public static int IndustrialDrillCharge = 4_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "basicChainsawCharge", comment = "Energy Capacity for Basic Chainsaw (FE)")
|
|
||||||
public static int BasicChainsawCharge = 40_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "advancedChainsawCharge", comment = "Energy Capacity for Advanced Chainsaw (FE)")
|
|
||||||
public static int AdvancedChainsawCharge = 400_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "industrialChainsawCharge", comment = "Energy Capacity for Industrial Chainsaw (FE)")
|
|
||||||
public static int IndustrialChainsawCharge = 4_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "basicJackhammerCharge", comment = "Energy Capacity for Basic Jackhammer (FE)")
|
|
||||||
public static int BasicJackhammerCharge = 40_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "advancedJackhammerCharge", comment = "Energy Capacity for Advanced Jackhammer (FE)")
|
|
||||||
public static int AdvancedJackhammerCharge = 400_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "industrialJackhammerCharge", comment = "Energy Capacity for Industrial Jachammer (FE)")
|
|
||||||
public static int IndustrialJackhammerCharge = 4_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "omniToolCharge", comment = "Energy Capacity for Omni Tool (FE)")
|
|
||||||
public static int OmniToolCharge = 4_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "rockCutterCharge", comment = "Energy Capacity for Rock Cutter (FE)")
|
|
||||||
public static int RockCutterCharge = 400_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "lapotronPackCharge", comment = "Energy Capacity for Lapotron Pack (FE)")
|
|
||||||
public static int LapotronPackCharge = 400_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "LithiumBatpackCharge", comment = "Energy Capacity for Lithium Batpack (FE)")
|
|
||||||
public static int LithiumBatpackCharge = 8_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "energyCrystalMaxCharge", comment = "Energy Capacity for Energy Crystal (FE)")
|
|
||||||
public static int EnergyCrystalMaxCharge = 4_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "lapotronCrystalMaxCharge", comment = "Energy Capacity for Lapotron Crystal (FE)")
|
|
||||||
public static int LapotronCrystalMaxCharge = 40_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "lapotronicOrbMaxCharge", comment = "Energy Capacity for Lapotronic Orb (FE)")
|
|
||||||
public static int LapotronicOrbMaxCharge = 400_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "cloakingDeviceCharge", comment = "Energy Capacity for Clocking Device (FE)")
|
|
||||||
public static int CloakingDeviceCharge = 40_000_000;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "power", key = "clockingDeviceEnergyUsage", comment = "Cloacking device energy usesage (FE)")
|
|
||||||
public static int CloackingDeviceUsage = 10;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelBasic", key = "basicDayRate", comment = "Generation rate during day for Basic Solar Panel (Value in FE)")
|
|
||||||
public static int basicGenerationRateD = 1;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelBasic", key = "basicNightRate", comment = "Generation rate during night for Basic Solar Panel (Value in FE)")
|
|
||||||
public static int basicGenerationRateN = 0;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelAdvanced", key = "advancedDayRate", comment = "Generation rate during day for Advanced Solar Panel (Value in FE)")
|
|
||||||
public static int advancedGenerationRateD = 16;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelAdvanced", key = "advancedNightRate", comment = "Generation rate during night for Advanced Solar Panel (Value in FE)")
|
|
||||||
public static int advancedGenerationRateN = 0;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelIndustrial", key = "industrialDayRate", comment = "Generation rate during day for Industrial Solar Panel (Value in FE)")
|
|
||||||
public static int industrialGenerationRateD = 64;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelIndustrial", key = "industrialNightRate", comment = "Generation rate during night for Industrial Solar Panel (Value in FE)")
|
|
||||||
public static int industrialGenerationRateN = 2;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelUltimate", key = "ultimateDayRate", comment = "Generation rate during day for Ultimate Solar Panel (Value in FE)")
|
|
||||||
public static int ultimateGenerationRateD = 256;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelUltimate", key = "ultimateNightRate", comment = "Generation rate during night for Ultimate Solar Panel (Value in FE)")
|
|
||||||
public static int ultimateGenerationRateN = 16;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelQuantum", key = "quantumDayRate", comment = "Generation rate during day for Quantum Solar Panel (Value in FE)")
|
|
||||||
public static int quantumGenerationRateD = 1024;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "generators", category = "solarPanelQuantum", key = "quantumNightRate", comment = "Generation rate during night for Quantum Solar Panel (Value in FE)")
|
|
||||||
public static int quantumGenerationRateN = 64;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "world", category = "loot", key = "enableOverworldLoot", comment = "When true TechReborn will add ingots, machine frames and circuits to OverWorld loot chests.")
|
|
||||||
public static boolean enableOverworldLoot = true;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "world", category = "loot", key = "enableNetherLoot", comment = "When true TechReborn will add ingots, machine frames and circuits to Nether loot chests.")
|
|
||||||
public static boolean enableNetherLoot = true;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "world", category = "loot", key = "enableEndLoot", comment = "When true TechReborn will add ingots, machine frames and circuits to The End loot chests.")
|
|
||||||
public static boolean enableEndLoot = true;
|
|
||||||
|
|
||||||
}
|
|
487
src/main/java/techreborn/config/TechRebornConfig.java
Normal file
487
src/main/java/techreborn/config/TechRebornConfig.java
Normal file
|
@ -0,0 +1,487 @@
|
||||||
|
/*
|
||||||
|
* This file is part of TechReborn, licensed under the MIT License (MIT).
|
||||||
|
*
|
||||||
|
* Copyright (c) 2018 TechReborn
|
||||||
|
*
|
||||||
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
* of this software and associated documentation files (the "Software"), to deal
|
||||||
|
* in the Software without restriction, including without limitation the rights
|
||||||
|
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
* copies of the Software, and to permit persons to whom the Software is
|
||||||
|
* furnished to do so, subject to the following conditions:
|
||||||
|
*
|
||||||
|
* The above copyright notice and this permission notice shall be included in all
|
||||||
|
* copies or substantial portions of the Software.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
* SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
package techreborn.config;
|
||||||
|
|
||||||
|
import reborncore.common.config.Config;
|
||||||
|
|
||||||
|
//All moved into one class as its a lot easier to find the annotations when you know where they all are
|
||||||
|
public class TechRebornConfig {
|
||||||
|
|
||||||
|
@Config(config = "items", category = "general", key = "enableGemTools", comment = "Enable Gem armor and tools")
|
||||||
|
public static boolean enableGemArmorAndTools = true;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "nanoSaberCharge", comment = "Energy Capacity for Nano Saber (FE)")
|
||||||
|
public static int nanoSaberCharge = 4_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "basicDrillCharge", comment = "Energy Capacity for Basic Drill (FE)")
|
||||||
|
public static int BasicDrillCharge = 40_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "advancedDrillCharge", comment = "Energy Capacity for Advanced Drill (FE)")
|
||||||
|
public static int AdvancedDrillCharge = 400_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "industrialDrillCharge", comment = "Energy Capacity for Industrial Drill (FE)")
|
||||||
|
public static int IndustrialDrillCharge = 4_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "basicChainsawCharge", comment = "Energy Capacity for Basic Chainsaw (FE)")
|
||||||
|
public static int BasicChainsawCharge = 40_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "advancedChainsawCharge", comment = "Energy Capacity for Advanced Chainsaw (FE)")
|
||||||
|
public static int AdvancedChainsawCharge = 400_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "industrialChainsawCharge", comment = "Energy Capacity for Industrial Chainsaw (FE)")
|
||||||
|
public static int IndustrialChainsawCharge = 4_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "basicJackhammerCharge", comment = "Energy Capacity for Basic Jackhammer (FE)")
|
||||||
|
public static int BasicJackhammerCharge = 40_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "advancedJackhammerCharge", comment = "Energy Capacity for Advanced Jackhammer (FE)")
|
||||||
|
public static int AdvancedJackhammerCharge = 400_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "industrialJackhammerCharge", comment = "Energy Capacity for Industrial Jachammer (FE)")
|
||||||
|
public static int IndustrialJackhammerCharge = 4_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "omniToolCharge", comment = "Energy Capacity for Omni Tool (FE)")
|
||||||
|
public static int OmniToolCharge = 4_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "rockCutterCharge", comment = "Energy Capacity for Rock Cutter (FE)")
|
||||||
|
public static int RockCutterCharge = 400_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "lapotronPackCharge", comment = "Energy Capacity for Lapotron Pack (FE)")
|
||||||
|
public static int LapotronPackCharge = 400_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "LithiumBatpackCharge", comment = "Energy Capacity for Lithium Batpack (FE)")
|
||||||
|
public static int LithiumBatpackCharge = 8_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "energyCrystalMaxCharge", comment = "Energy Capacity for Energy Crystal (FE)")
|
||||||
|
public static int EnergyCrystalMaxCharge = 4_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "lapotronCrystalMaxCharge", comment = "Energy Capacity for Lapotron Crystal (FE)")
|
||||||
|
public static int LapotronCrystalMaxCharge = 40_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "lapotronicOrbMaxCharge", comment = "Energy Capacity for Lapotronic Orb (FE)")
|
||||||
|
public static int LapotronicOrbMaxCharge = 400_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "cloakingDeviceCharge", comment = "Energy Capacity for Clocking Device (FE)")
|
||||||
|
public static int CloakingDeviceCharge = 40_000_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "power", key = "clockingDeviceEnergyUsage", comment = "Cloacking device energy usesage (FE)")
|
||||||
|
public static int CloackingDeviceUsage = 10;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelBasic", key = "basicDayRate", comment = "Generation rate during day for Basic Solar Panel (Value in FE)")
|
||||||
|
public static int basicGenerationRateD = 1;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelBasic", key = "basicNightRate", comment = "Generation rate during night for Basic Solar Panel (Value in FE)")
|
||||||
|
public static int basicGenerationRateN = 0;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelAdvanced", key = "advancedDayRate", comment = "Generation rate during day for Advanced Solar Panel (Value in FE)")
|
||||||
|
public static int advancedGenerationRateD = 16;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelAdvanced", key = "advancedNightRate", comment = "Generation rate during night for Advanced Solar Panel (Value in FE)")
|
||||||
|
public static int advancedGenerationRateN = 0;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelIndustrial", key = "industrialDayRate", comment = "Generation rate during day for Industrial Solar Panel (Value in FE)")
|
||||||
|
public static int industrialGenerationRateD = 64;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelIndustrial", key = "industrialNightRate", comment = "Generation rate during night for Industrial Solar Panel (Value in FE)")
|
||||||
|
public static int industrialGenerationRateN = 2;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelUltimate", key = "ultimateDayRate", comment = "Generation rate during day for Ultimate Solar Panel (Value in FE)")
|
||||||
|
public static int ultimateGenerationRateD = 256;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelUltimate", key = "ultimateNightRate", comment = "Generation rate during night for Ultimate Solar Panel (Value in FE)")
|
||||||
|
public static int ultimateGenerationRateN = 16;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelQuantum", key = "quantumDayRate", comment = "Generation rate during day for Quantum Solar Panel (Value in FE)")
|
||||||
|
public static int quantumGenerationRateD = 1024;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "solarPanelQuantum", key = "quantumNightRate", comment = "Generation rate during night for Quantum Solar Panel (Value in FE)")
|
||||||
|
public static int quantumGenerationRateN = 64;
|
||||||
|
|
||||||
|
@Config(config = "world", category = "loot", key = "enableOverworldLoot", comment = "When true TechReborn will add ingots, machine frames and circuits to OverWorld loot chests.")
|
||||||
|
public static boolean enableOverworldLoot = true;
|
||||||
|
|
||||||
|
@Config(config = "world", category = "loot", key = "enableNetherLoot", comment = "When true TechReborn will add ingots, machine frames and circuits to Nether loot chests.")
|
||||||
|
public static boolean enableNetherLoot = true;
|
||||||
|
|
||||||
|
@Config(config = "world", category = "loot", key = "enableEndLoot", comment = "When true TechReborn will add ingots, machine frames and circuits to The End loot chests.")
|
||||||
|
public static boolean enableEndLoot = true;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "lightning_rod", key = "LightningRodMaxOutput", comment = "Lightning Rod Max Output (Value in EU)")
|
||||||
|
public static int lightningRodMaxOutput = 2048;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "lightning_rod", key = "LightningRodMaxEnergy", comment = "Lightning Rod Max Energy (Value in EU)")
|
||||||
|
public static int lightningRodMaxEnergy = 100_000_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "lightning_rod", key = "LightningRodChanceOfStrike", comment = "Chance of lightning striking a rod (Range: 0-70)")
|
||||||
|
public static int lightningRodChanceOfStrike = 24;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "lightning_rod", key = "LightningRodBaseStrikeEnergy", comment = "Base amount of energy per strike (Value in EU)")
|
||||||
|
public static int lightningRodBaseEnergyStrike = 262_144;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "grinder", key = "GrinderInput", comment = "Grinder Max Input (Value in EU)")
|
||||||
|
public static int grinderMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "grinder", key = "GrinderMaxEnergy", comment = "Grinder Max Energy (Value in EU)")
|
||||||
|
public static int grinderMaxEnergy = 1_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "thermal_generator", key = "ThermalGeneratorMaxOutput", comment = "Thermal Generator Max Output (Value in EU)")
|
||||||
|
public static int thermalGeneratorMaxOutput = 128;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "thermal_generator", key = "ThermalGeneratorMaxEnergy", comment = "Thermal Generator Max Energy (Value in EU)")
|
||||||
|
public static int thermalGeneratorMaxEnergy = 1_000_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "thermal_generator", key = "ThermalGeneratorTankCapacity", comment = "Thermal Generator Tank Capacity")
|
||||||
|
public static int thermalGeneratorTankCapacity = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "thermal_generator", key = "ThermalGeneratorEnergyPerTick", comment = "Thermal Generator Energy Per Tick (Value in EU)")
|
||||||
|
public static int thermalGeneratorEnergyPerTick = 16;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "lesu", key = "LesuMaxOutput", comment = "LESU Base Output (Value in EU)")
|
||||||
|
public static int lesuBaseOutput = 16;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "lesu", key = "LesuMaxEnergyPerBlock", comment = "LESU Max Energy Per Block (Value in EU)")
|
||||||
|
public static int lesuStoragePerBlock = 1_000_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "lesu", key = "LesuExtraIO", comment = "LESU Extra I/O Multiplier")
|
||||||
|
public static int lesuExtraIOPerBlock = 8;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "general", key = "IC2TransformersStyle", comment = "Input from dots side, output from other sides, like in IC2.")
|
||||||
|
public static boolean IC2TransformersStyle = true;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "aesu", key = "AesuMaxInput", comment = "AESU Max Input (Value in EU)")
|
||||||
|
public static int aesuMaxInput = 16192;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "aesu", key = "AesuMaxOutput", comment = "AESU Max Output (Value in EU)")
|
||||||
|
public static int aesuMaxOutput = 16192;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "aesu", key = "AesuMaxEnergy", comment = "AESU Max Energy (Value in EU)")
|
||||||
|
public static int aesuMaxEnergy = 100_000_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "player_detector", key = "PlayerDetectorMaxInput", comment = "Player Detector Max Input (Value in EU)")
|
||||||
|
public static int playerDetectorMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "player_detector", key = "PlayerDetectorMaxEnergy", comment = "Player Detector Max Energy (Value in EU)")
|
||||||
|
public static int playerDetectorMaxEnergy = 10000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "player_detector", key = "PlayerDetectorEUPerSecond", comment = "Player Detector Energy Consumption per second (Value in EU)")
|
||||||
|
public static int playerDetectorEuPerTick = 10;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "quantum_chest", key = "QuantumChestMaxStorage", comment = "Maximum amount of items a Quantum Chest can store")
|
||||||
|
public static int quantumChestMaxStorage = Integer.MAX_VALUE;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "Distillation_tower", key = "DistillationTowerMaxInput", comment = "Distillation Tower Max Input (Value in EU)")
|
||||||
|
public static int distillationTowerMaxInput = 128;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "Distillation_tower", key = "DistillationTowerMaxEnergy", comment = "Distillation Tower Max Energy (Value in EU)")
|
||||||
|
public static int distillationTowerMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "extractor", key = "ExtractorInput", comment = "Extractor Max Input (Value in EU)")
|
||||||
|
public static int extractorMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "extractor", key = "ExtractorMaxEnergy", comment = "Extractor Max Energy (Value in EU)")
|
||||||
|
public static int extractorMaxEnergy = 1_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorMaxOutput", comment = "Semifluid Generator Max Output (Value in EU)")
|
||||||
|
public static int semiFluidGeneratorMaxOutput = 128;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorMaxEnergy", comment = "Semifluid Generator Max Energy (Value in EU)")
|
||||||
|
public static int semiFluidGeneratorMaxEnergy = 1000000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorTankCapacity", comment = "Semifluid Generator Tank Capacity")
|
||||||
|
public static int semiFluidGeneratorTankCapacity = 10000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "semifluid_generator", key = "SemifluidGeneratorEnergyPerTick", comment = "Semifluid Generator Energy Per Tick (Value in EU)")
|
||||||
|
public static int semiFluidGeneratorEnergyPerTick = 8;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "compressor", key = "CompressorInput", comment = "Compressor Max Input (Value in EU)")
|
||||||
|
public static int compressorMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "compressor", key = "CompressorMaxEnergy", comment = "Compressor Max Energy (Value in EU)")
|
||||||
|
public static int compressorMaxEnergy = 1000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "alloy_smelter", key = "AlloySmelterMaxInput", comment = "Alloy Smelter Max Input (Value in EU)")
|
||||||
|
public static int alloySmelterMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "alloy_smelter", key = "AlloySmelterMaxEnergy", comment = "Alloy Smelter Max Energy (Value in EU)")
|
||||||
|
public static int alloySmelterMaxEnergy = 1_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "rolling_machine", key = "RollingMachineMaxInput", comment = "Rolling Machine Max Input (Value in EU)")
|
||||||
|
public static int rollingMachineMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "rolling_machine", key = "RollingMachineEnergyPerTick", comment = "Rolling Machine Energy Per Tick (Value in EU)")
|
||||||
|
public static int rollingMachineEnergyPerTick = 5;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "rolling_machine", key = "RollingMachineEnergyRunTime", comment = "Rolling Machine Run Time")
|
||||||
|
public static int rollingMachineRunTime = 250;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "rolling_machine", key = "RollingMachineMaxEnergy", comment = "Rolling Machine Max Energy (Value in EU)")
|
||||||
|
public static int rollingMachineMaxEnergy = 10000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "chunk_loader", key = "ChunkLoaderMaxInput", comment = "Chunk Loader Max Input (Value in EU)")
|
||||||
|
public static int chunkLoaderMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "chunk_loader", key = "ChunkLoaderMaxEnergy", comment = "Chunk Loader Max Energy (Value in EU)")
|
||||||
|
public static int chunkLoaderMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "water_mill", key = "WaterMillMaxOutput", comment = "Water Mill Max Output (Value in EU)")
|
||||||
|
public static int waterMillMaxOutput = 32;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "water_mill", key = "WaterMillMaxEnergy", comment = "Water Mill Max Energy (Value in EU)")
|
||||||
|
public static int waterMillMaxEnergy = 1000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "water_mill", key = "WaterMillEnergyPerTick", comment = "Water Mill Energy Multiplier")
|
||||||
|
public static double waterMillEnergyMultiplier = 0.1;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "assembling_machine", key = "AssemblingMachineMaxInput", comment = "Assembling Machine Max Input (Value in EU)")
|
||||||
|
public static int assemblingMachineMaxInput = 128;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "assembling_machine", key = "AssemblingMachineMaxEnergy", comment = "Assembling Machine Max Energy (Value in EU)")
|
||||||
|
public static int assemblingMachineMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "nuke", key = "fusetime", comment = "Nuke fuse time (ticks)")
|
||||||
|
public static int nukeFuseTime = 400;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "nuke", key = "radius", comment = "Nuke explision radius")
|
||||||
|
public static int nukeRadius = 40;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "nuke", key = "enabled", comment = "Should the nuke explode, set to false to prevent block damage")
|
||||||
|
public static boolean nukeEnabled = true;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "matter_fabricator", key = "MatterFabricatorMaxInput", comment = "Matter Fabricator Max Input (Value in EU)")
|
||||||
|
public static int matterFabricatorMaxInput = 8192;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "matter_fabricator", key = "MatterFabricatorMaxEnergy", comment = "Matter Fabricator Max Energy (Value in EU)")
|
||||||
|
public static int matterFabricatorMaxEnergy = 10_000_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "matter_fabricator", key = "MatterFabricatorFabricationRate", comment = "Matter Fabricator Fabrication Rate, amount of amplifier units per UUM")
|
||||||
|
public static int matterFabricatorFabricationRate = 6_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "matter_fabricator", key = "MatterFabricatorEnergyPerAmp", comment = "Matter Fabricator EU per amplifier unit, multiply this with the rate for total EU")
|
||||||
|
public static int matterFabricatorEnergyPerAmp = 5;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_grinder", key = "IndustrialGrinderMaxInput", comment = "Industrial Grinder Max Input (Value in EU)")
|
||||||
|
public static int industrialGrinderMaxInput = 128;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_grinder", key = "IndustrialGrinderMaxEnergy", comment = "Industrial Grinder Max Energy (Value in EU)")
|
||||||
|
public static int industrialGrinderMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "vacuumfreezer", key = "VacuumFreezerInput", comment = "Vacuum Freezer Max Input (Value in EU)")
|
||||||
|
public static int vacuumFreezerMaxInput = 64;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "vacuumfreezer", key = "VacuumFreezerMaxEnergy", comment = "Vacuum Freezer Max Energy (Value in EU)")
|
||||||
|
public static int vacuumFreezerMaxEnergy = 64_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "implosion_compressor", key = "ImplosionCompressorMaxInput", comment = "Implosion Compressor Max Input (Value in EU)")
|
||||||
|
public static int implosionCompressorMaxInput = 64;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "implosion_compressor", key = "ImplosionCompressorMaxEnergy", comment = "Implosion Compressor Max Energy (Value in EU)")
|
||||||
|
public static int implosionCompressorMaxEnergy = 64_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_furnace", key = "IndustrialFurnaceMaxInput", comment = "Industrial Blast Furnace Max Input (Value in EU)")
|
||||||
|
public static int industrialBlastFurnaceMaxInput = 128;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_furnace", key = "IndustrialFurnaceMaxEnergy", comment = "Industrial Blast Furnace Max Energy (Value in EU)")
|
||||||
|
public static int industrialBlastFurnaceMaxEnergy = 40_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "diesel_generator", key = "DieselGeneratorMaxOutput", comment = "Diesel Generator Max Output (Value in EU)")
|
||||||
|
public static int dieselGeneratorMaxOutput = 128;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "diesel_generator", key = "DieselGeneratorMaxEnergy", comment = "Diesel Generator Max Energy (Value in EU)")
|
||||||
|
public static int dieselGeneratorMaxEnergy = 1_000_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "diesel_generator", key = "DieselGeneratorTankCapacity", comment = "Diesel Generator Tank Capacity")
|
||||||
|
public static int dieselGeneratorTankCapacity = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "diesel_generator", key = "DieselGeneratorEnergyPerTick", comment = "Diesel Generator Energy Per Tick (Value in EU)")
|
||||||
|
public static int dieselGeneratorEnergyPerTick = 20;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_sawmill", key = "IndustrialSawmillMaxInput", comment = "Industrial Sawmill Max Input (Value in EU)")
|
||||||
|
public static int industrialSawmillMaxInput = 128;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_sawmill", key = "IndustrialSawmillMaxEnergy", comment = "Industrial Sawmill Max Energy (Value in EU)")
|
||||||
|
public static int industrialSawmillMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "dragon_egg_siphoner", key = "DragonEggSiphonerMaxOutput", comment = "Dragon Egg Siphoner Max Output (Value in EU)")
|
||||||
|
public static int dragonEggSyphonMaxOutput = 128;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "dragon_egg_siphoner", key = "DragonEggSiphonerMaxEnergy", comment = "Dragon Egg Siphoner Max Energy (Value in EU)")
|
||||||
|
public static int dragonEggSyphonMaxEnergy = 1000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "dragon_egg_siphoner", key = "DragonEggSiphonerEnergyPerTick", comment = "Dragon Egg Siphoner Energy Per Tick (Value in EU)")
|
||||||
|
public static int dragonEggSyphonEnergyPerTick = 4;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "autocrafter", key = "AutoCrafterInput", comment = "AutoCrafting Table Max Input (Value in EU)")
|
||||||
|
public static int autoCraftingTableMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "autocrafter", key = "AutoCrafterMaxEnergy", comment = "AutoCrafting Table Max Energy (Value in EU)")
|
||||||
|
public static int autoCraftingTableMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "fluidreplicator", key = "FluidReplicatorMaxInput", comment = "Fluid Replicator Max Input (Value in EU)")
|
||||||
|
public static int fluidReplicatorMaxInput = 256;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "fluidreplicator", key = "FluidReplicatorMaxEnergy", comment = "Fluid Replicator Max Energy (Value in EU)")
|
||||||
|
public static int fluidReplicatorMaxEnergy = 400_000;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "general", key = "DispenserScrapbox", comment = "Dispensers will open scrapboxes")
|
||||||
|
public static boolean dispenseScrapboxes = true;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "electric_furnace", key = "ElectricFurnaceInput", comment = "Electric Furnace Max Input (Value in EU)")
|
||||||
|
public static int electricFurnaceMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "electric_furnace", key = "ElectricFurnaceMaxEnergy", comment = "Electric Furnace Max Energy (Value in EU)")
|
||||||
|
public static int electricFurnaceMaxEnergy = 1000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "generator", key = "GeneratorMaxOutput", comment = "Solid Fuel Generator Max Output (Value in EU)")
|
||||||
|
public static int solidFuelGeneratorMaxOutput = 32;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "generator", key = "GeneratorMaxEnergy", comment = "Solid Fuel Generator Max Energy (Value in EU)")
|
||||||
|
public static int solidFuelGeneratorMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "generator", key = "GeneratorEnergyOutput", comment = "Solid Fuel Generator Energy Output Amount (Value in EU)")
|
||||||
|
public static int solidFuelGeneratorOutputAmount = 10;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "quantum_tank", key = "QuantumTankMaxStorage", comment = "Maximum amount of millibuckets a Quantum Tank can store")
|
||||||
|
public static int quantumTankMaxStorage = Integer.MAX_VALUE;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "digital_chest", key = "DigitalChestMaxStorage", comment = "Maximum amount of items a Digital Chest can store")
|
||||||
|
public static int digitalChestMaxStorage = 32768;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "charge_bench", key = "ChargeBenchMaxOutput", comment = "Charge Bench Max Output (Value in EU)")
|
||||||
|
public static int chargeOMatBMaxOutput = 512;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "charge_bench", key = "ChargeBenchMaxInput", comment = "Charge Bench Max Input (Value in EU)")
|
||||||
|
public static int chargeOMatBMaxInput = 512;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "charge_bench", key = "ChargeBenchMaxEnergy", comment = "Charge Bench Max Energy (Value in EU)")
|
||||||
|
public static int chargeOMatBMaxEnergy = 100_000_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_electrolyzer", key = "IndustrialElectrolyzerMaxInput", comment = "Industrial Electrolyzer Max Input (Value in EU)")
|
||||||
|
public static int industrialElectrolyzerMaxInput = 128;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "industrial_electrolyzer", key = "IndustrialElectrolyzerMaxEnergy", comment = "Industrial Electrolyzer Max Energy (Value in EU)")
|
||||||
|
public static int industrialElectrolyzerMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "cable", key = "uninsulatedElectrocutionDamage", comment = "When true an uninsulated cable will cause damage to entities")
|
||||||
|
public static boolean uninsulatedElectrocutionDamage = true;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "cable", key = "uninsulatedElectrocutionSound", comment = "When true an uninsulated cable will create a spark sound when an entity touches it")
|
||||||
|
public static boolean uninsulatedElectrocutionSound = true;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "cable", key = "uninsulatedElectrocutionParticles", comment = "When true an uninsulated cable will create a spark when an entity touches it")
|
||||||
|
public static boolean uninsulatedElectrocutionParticles = true;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "centrifuge", key = "CentrifugeMaxInput", comment = "Centrifuge Max Input (Value in EU)")
|
||||||
|
public static int industrialCentrifugeMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "centrifuge", key = "CentrifugeMaxEnergy", comment = "Centrifuge Max Energy (Value in EU)")
|
||||||
|
public static int industrialCentrifugeMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "gas_generator", key = "GasGeneratorMaxOutput", comment = "Gas Generator Max Output (Value in EU)")
|
||||||
|
public static int gasTurbineMaxOutput = 128;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "gas_generator", key = "GasGeneratorMaxEnergy", comment = "Gas Generator Max Energy (Value in EU)")
|
||||||
|
public static int gasTurbineMaxEnergy = 1000000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "gas_generator", key = "GasGeneratorTankCapacity", comment = "Gas Generator Tank Capacity")
|
||||||
|
public static int gasTurbineTankCapacity = 10000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "gas_generator", key = "GasGeneratorEnergyPerTick", comment = "Gas Generator Energy Per Tick (Value in EU)")
|
||||||
|
public static int gasTurbineEnergyPerTick = 16;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "chemical_reactor", key = "ChemicalReactorMaxInput", comment = "Chemical Reactor Max Input (Value in EU)")
|
||||||
|
public static int chemicalReactorMaxInput = 128;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "chemical_reactor", key = "ChemicalReactorMaxEnergy", comment = "Chemical Reactor Max Energy (Value in EU)")
|
||||||
|
public static int chemicalReactorMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "idsu", key = "IdsuMaxInput", comment = "IDSU Max Input (Value in EU)")
|
||||||
|
public static int idsuMaxInput = 8192;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "idsu", key = "IdsuMaxOutput", comment = "IDSU Max Output (Value in EU)")
|
||||||
|
public static int idsuMaxOutput = 8192;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "idsu", key = "IdsuMaxEnergy", comment = "IDSU Max Energy (Value in EU)")
|
||||||
|
public static int idsuMaxEnergy = 100_000_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxInput", comment = "Fusion Reactor Max Input (Value in EU)")
|
||||||
|
public static int fusionControlComputerMaxInput = 8192;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxOutput", comment = "Fusion Reactor Max Output (Value in EU)")
|
||||||
|
public static int fusionControlComputerMaxOutput = 1_000_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxEnergy", comment = "Fusion Reactor Max Energy (Value in EU)")
|
||||||
|
public static int fusionControlComputerMaxEnergy = 100_000_000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "fusion_reactor", key = "FusionReactorMaxCoilSize", comment = "Fusion Reactor Max Coil size (Radius)")
|
||||||
|
public static int fusionControlComputerMaxCoilSize = 50;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorMaxOutput", comment = "Plasma Generator Max Output (Value in EU)")
|
||||||
|
public static int plasmaGeneratorMaxOutput = 2048;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorMaxEnergy", comment = "Plasma Generator Max Energy (Value in EU)")
|
||||||
|
public static double plasmaGeneratorMaxEnergy = 500_000_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorTankCapacity", comment = "Plasma Generator Tank Capacity")
|
||||||
|
public static int plasmaGeneratorTankCapacity = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "plasma_generator", key = "PlasmaGeneratorEnergyPerTick", comment = "Plasma Generator Energy Per Tick (Value in EU)")
|
||||||
|
public static int plasmaGeneratorEnergyPerTick = 400;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "wind_mill", key = "WindMillMaxOutput", comment = "Wind Mill Max Output (Value in EU)")
|
||||||
|
public static int windMillMaxOutput = 128;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "wind_mill", key = "WindMillMaxEnergy", comment = "Wind Mill Max Energy (Value in EU)")
|
||||||
|
public static int windMillMaxEnergy = 10_000;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "wind_mill", key = "WindMillEnergyPerTick", comment = "Wind Mill Energy Per Tick (Value in EU)")
|
||||||
|
public static int windMillBaseEnergy = 2;
|
||||||
|
|
||||||
|
@Config(config = "generators", category = "wind_mill", key = "WindMillThunderMultiplier", comment = "Wind Mill Thunder Multiplier")
|
||||||
|
public static double windMillThunderMultiplier = 1.25;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "recycler", key = "RecyclerInput", comment = "Recycler Max Input (Value in EU)")
|
||||||
|
public static int recyclerMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "recycler", key = "RecyclerMaxEnergy", comment = "Recycler Max Energy (Value in EU)")
|
||||||
|
public static int recyclerMaxEnergy = 1000;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "scrapboxinator", key = "ScrapboxinatorMaxInput", comment = "Scrapboxinator Max Input (Value in EU)")
|
||||||
|
public static int scrapboxinatorMaxInput = 32;
|
||||||
|
|
||||||
|
@Config(config = "machines", category = "scrapboxinator", key = "ScrapboxinatorMaxEnergy", comment = "Scrapboxinator Max Energy (Value in EU)")
|
||||||
|
public static int scrapboxinatorMaxEnergy = 1_000;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "upgrades", key = "overclcoker_speed", comment = "Overclocker behavior speed multipiler")
|
||||||
|
public static double overclockerSpeed = 0.25;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "upgrades", key = "overclcoker_power", comment = "Overclocker behavior power multipiler")
|
||||||
|
public static double overclockerPower = 0.75;
|
||||||
|
|
||||||
|
@Config(config = "items", category = "upgrades", key = "energy_storage", comment = "Energy storage behavior extra power")
|
||||||
|
public static double energyStoragePower = 40_000;
|
||||||
|
|
||||||
|
@Config(config = "misc", category = "general", key = "manualRefund", comment = "Allow refunding items used to craft the manual")
|
||||||
|
public static boolean allowManualRefund = true;
|
||||||
|
}
|
|
@ -33,33 +33,21 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Vec3d;
|
import net.minecraft.util.math.Vec3d;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import reborncore.common.explosion.RebornExplosion;
|
import reborncore.common.explosion.RebornExplosion;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import techreborn.config.TechRebornConfig;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by Mark on 13/03/2016.
|
* Created by Mark on 13/03/2016.
|
||||||
*/
|
*/
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class EntityNukePrimed extends TntEntity {
|
public class EntityNukePrimed extends TntEntity {
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "nuke", key = "fusetime", comment = "Nuke fuse time (ticks)")
|
|
||||||
public static int fuseTime = 400;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "nuke", key = "radius", comment = "Nuke explision radius")
|
|
||||||
public static int radius = 40;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "nuke", key = "enabled", comment = "Should the nuke explode, set to false to prevent block damage")
|
|
||||||
public static boolean enabled = true;
|
|
||||||
|
|
||||||
public EntityNukePrimed(EntityType<EntityNukePrimed> entityType, World world) {
|
public EntityNukePrimed(EntityType<EntityNukePrimed> entityType, World world) {
|
||||||
super(entityType, world);
|
super(entityType, world);
|
||||||
setFuse(EntityNukePrimed.fuseTime);
|
setFuse(TechRebornConfig.nukeFuseTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
public EntityNukePrimed(World world, double x, double y, double z, LivingEntity tntPlacedBy) {
|
public EntityNukePrimed(World world, double x, double y, double z, LivingEntity tntPlacedBy) {
|
||||||
super(world, x, y, z, tntPlacedBy);
|
super(world, x, y, z, tntPlacedBy);
|
||||||
setFuse(EntityNukePrimed.fuseTime);
|
setFuse(TechRebornConfig.nukeFuseTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -99,10 +87,10 @@ public class EntityNukePrimed extends TntEntity {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void explodeNuke() {
|
public void explodeNuke() {
|
||||||
if (!enabled) {
|
if (!TechRebornConfig.nukeEnabled) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
RebornExplosion nukeExplosion = new RebornExplosion(new BlockPos(x, y, z), world, radius);
|
RebornExplosion nukeExplosion = new RebornExplosion(new BlockPos(x, y, z), world, TechRebornConfig.nukeRadius);
|
||||||
nukeExplosion.setLivingBase(getCausingEntity());
|
nukeExplosion.setLivingBase(getCausingEntity());
|
||||||
nukeExplosion.explode();
|
nukeExplosion.explode();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,55 +0,0 @@
|
||||||
/*
|
|
||||||
* This file is part of TechReborn, licensed under the MIT License (MIT).
|
|
||||||
*
|
|
||||||
* Copyright (c) 2018 TechReborn
|
|
||||||
*
|
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
||||||
* of this software and associated documentation files (the "Software"), to deal
|
|
||||||
* in the Software without restriction, including without limitation the rights
|
|
||||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
* copies of the Software, and to permit persons to whom the Software is
|
|
||||||
* furnished to do so, subject to the following conditions:
|
|
||||||
*
|
|
||||||
* The above copyright notice and this permission notice shall be included in all
|
|
||||||
* copies or substantial portions of the Software.
|
|
||||||
*
|
|
||||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
||||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
||||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
||||||
* SOFTWARE.
|
|
||||||
*/
|
|
||||||
|
|
||||||
package techreborn.events;
|
|
||||||
|
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class BlockBreakHandler {
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//TODO 1.14
|
|
||||||
|
|
||||||
//
|
|
||||||
// @SubscribeEvent
|
|
||||||
// public void getBreakSpeedEvent(PlayerEvent.BreakSpeed event){
|
|
||||||
// if(event.getEntityPlayer().getHeldItem(Hand.MAIN_HAND).getItem() == TRContent.INDUSTRIAL_CHAINSAW && event.getOriginalSpeed() > 1.0f){
|
|
||||||
// BlockPos pos = event.getPos();
|
|
||||||
// World worldIn = event.getEntityPlayer().world;
|
|
||||||
// float speed = 20F;
|
|
||||||
// int blocks = 0;
|
|
||||||
// for (int i = 1; i < 10; i++) {
|
|
||||||
// BlockPos nextPos = pos.up(i);
|
|
||||||
// BlockState nextState = worldIn.getBlockState(nextPos);
|
|
||||||
// if(nextState.getBlock().matches(BlockTags.LOGS)){
|
|
||||||
// blocks ++;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// event.setNewSpeed(speed / blocks);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
}
|
|
|
@ -39,7 +39,7 @@ import techreborn.blocks.misc.BlockRubberPlank;
|
||||||
import techreborn.blocks.misc.BlockRubberPlankSlab;
|
import techreborn.blocks.misc.BlockRubberPlankSlab;
|
||||||
import techreborn.blocks.misc.BlockRubberPlankStair;
|
import techreborn.blocks.misc.BlockRubberPlankStair;
|
||||||
import techreborn.blocks.misc.BlockRubberSapling;
|
import techreborn.blocks.misc.BlockRubberSapling;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.ModFluids;
|
import techreborn.init.ModFluids;
|
||||||
import techreborn.init.ModSounds;
|
import techreborn.init.ModSounds;
|
||||||
import techreborn.init.TRArmorMaterial;
|
import techreborn.init.TRArmorMaterial;
|
||||||
|
@ -124,7 +124,7 @@ public class ModRegistry {
|
||||||
Arrays.stream(Upgrades.values()).forEach(value -> RebornRegistry.registerItem(value.item));
|
Arrays.stream(Upgrades.values()).forEach(value -> RebornRegistry.registerItem(value.item));
|
||||||
|
|
||||||
// Gem armor & tools
|
// Gem armor & tools
|
||||||
if (ConfigTechReborn.enableGemArmorAndTools) {
|
if (TechRebornConfig.enableGemArmorAndTools) {
|
||||||
//Todo: repair with tags
|
//Todo: repair with tags
|
||||||
RebornRegistry.registerItem(TRContent.BRONZE_SWORD = InitUtils.setup(new ItemTRSword(TRToolTier.BRONZE), "bronze_sword"));
|
RebornRegistry.registerItem(TRContent.BRONZE_SWORD = InitUtils.setup(new ItemTRSword(TRToolTier.BRONZE), "bronze_sword"));
|
||||||
RebornRegistry.registerItem(TRContent.BRONZE_PICKAXE = InitUtils.setup(new ItemTRPickaxe(TRToolTier.BRONZE), "bronze_pickaxe"));
|
RebornRegistry.registerItem(TRContent.BRONZE_PICKAXE = InitUtils.setup(new ItemTRPickaxe(TRToolTier.BRONZE), "bronze_pickaxe"));
|
||||||
|
|
|
@ -32,7 +32,7 @@ import net.minecraft.world.loot.UniformLootTableRange;
|
||||||
import net.minecraft.world.loot.entry.ItemEntry;
|
import net.minecraft.world.loot.entry.ItemEntry;
|
||||||
import net.minecraft.world.loot.entry.LootEntry;
|
import net.minecraft.world.loot.entry.LootEntry;
|
||||||
import net.minecraft.world.loot.function.SetCountLootFunction;
|
import net.minecraft.world.loot.function.SetCountLootFunction;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent.Ingots;
|
import techreborn.init.TRContent.Ingots;
|
||||||
import techreborn.init.TRContent.Parts;
|
import techreborn.init.TRContent.Parts;
|
||||||
|
|
||||||
|
@ -92,7 +92,7 @@ public class ModLoot {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ConfigTechReborn.enableOverworldLoot) {
|
if (TechRebornConfig.enableOverworldLoot) {
|
||||||
switch (stringId) {
|
switch (stringId) {
|
||||||
case "minecraft:chests/abandoned_mineshaft":
|
case "minecraft:chests/abandoned_mineshaft":
|
||||||
case "minecraft:chests/desert_pyramid":
|
case "minecraft:chests/desert_pyramid":
|
||||||
|
@ -115,13 +115,13 @@ public class ModLoot {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ConfigTechReborn.enableNetherLoot) {
|
if (TechRebornConfig.enableNetherLoot) {
|
||||||
if (stringId.equals("minecraft:chests/nether_bridge")) {
|
if (stringId.equals("minecraft:chests/nether_bridge")) {
|
||||||
supplier.withPool(poolAdvanced);
|
supplier.withPool(poolAdvanced);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ConfigTechReborn.enableEndLoot) {
|
if (TechRebornConfig.enableEndLoot) {
|
||||||
if (stringId.equals("minecraft:chests/end_city_treasure")) {
|
if (stringId.equals("minecraft:chests/end_city_treasure")) {
|
||||||
supplier.withPool(poolIndustrial);
|
supplier.withPool(poolIndustrial);
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,8 +34,6 @@ import net.minecraft.item.ItemStack;
|
||||||
import reborncore.api.power.EnumPowerTier;
|
import reborncore.api.power.EnumPowerTier;
|
||||||
import reborncore.api.blockentity.IUpgrade;
|
import reborncore.api.blockentity.IUpgrade;
|
||||||
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
import reborncore.common.powerSystem.PowerAcceptorBlockEntity;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.blocks.*;
|
import techreborn.blocks.*;
|
||||||
import techreborn.blocks.cable.BlockCable;
|
import techreborn.blocks.cable.BlockCable;
|
||||||
|
@ -50,7 +48,7 @@ import techreborn.blocks.transformers.BlockHVTransformer;
|
||||||
import techreborn.blocks.transformers.BlockLVTransformer;
|
import techreborn.blocks.transformers.BlockLVTransformer;
|
||||||
import techreborn.blocks.transformers.BlockMVTransformer;
|
import techreborn.blocks.transformers.BlockMVTransformer;
|
||||||
import techreborn.client.EGui;
|
import techreborn.client.EGui;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.entities.EntityNukePrimed;
|
import techreborn.entities.EntityNukePrimed;
|
||||||
import techreborn.items.ItemDynamicCell;
|
import techreborn.items.ItemDynamicCell;
|
||||||
import techreborn.items.ItemUpgrade;
|
import techreborn.items.ItemUpgrade;
|
||||||
|
@ -87,7 +85,6 @@ import javax.annotation.Nullable;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.function.Function;
|
import java.util.function.Function;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class TRContent {
|
public class TRContent {
|
||||||
|
|
||||||
// Misc Blocks
|
// Misc Blocks
|
||||||
|
@ -217,11 +214,11 @@ public class TRContent {
|
||||||
public static Item PERIDOT_BOOTS;
|
public static Item PERIDOT_BOOTS;
|
||||||
|
|
||||||
public enum SolarPanels implements ItemConvertible {
|
public enum SolarPanels implements ItemConvertible {
|
||||||
BASIC(EnumPowerTier.MICRO, ConfigTechReborn.basicGenerationRateD, ConfigTechReborn.basicGenerationRateN),
|
BASIC(EnumPowerTier.MICRO, TechRebornConfig.basicGenerationRateD, TechRebornConfig.basicGenerationRateN),
|
||||||
ADVANCED(EnumPowerTier.LOW, ConfigTechReborn.advancedGenerationRateD, ConfigTechReborn.advancedGenerationRateN),
|
ADVANCED(EnumPowerTier.LOW, TechRebornConfig.advancedGenerationRateD, TechRebornConfig.advancedGenerationRateN),
|
||||||
INDUSTRIAL(EnumPowerTier.MEDIUM, ConfigTechReborn.industrialGenerationRateD, ConfigTechReborn.industrialGenerationRateN),
|
INDUSTRIAL(EnumPowerTier.MEDIUM, TechRebornConfig.industrialGenerationRateD, TechRebornConfig.industrialGenerationRateN),
|
||||||
ULTIMATE(EnumPowerTier.HIGH, ConfigTechReborn.ultimateGenerationRateD, ConfigTechReborn.ultimateGenerationRateN),
|
ULTIMATE(EnumPowerTier.HIGH, TechRebornConfig.ultimateGenerationRateD, TechRebornConfig.ultimateGenerationRateN),
|
||||||
QUANTUM(EnumPowerTier.EXTREME, ConfigTechReborn.quantumGenerationRateD, ConfigTechReborn.quantumGenerationRateN),
|
QUANTUM(EnumPowerTier.EXTREME, TechRebornConfig.quantumGenerationRateD, TechRebornConfig.quantumGenerationRateN),
|
||||||
CREATIVE(EnumPowerTier.INFINITE, Integer.MAX_VALUE / 100, Integer.MAX_VALUE / 100);
|
CREATIVE(EnumPowerTier.INFINITE, Integer.MAX_VALUE / 100, Integer.MAX_VALUE / 100);
|
||||||
|
|
||||||
public final String name;
|
public final String name;
|
||||||
|
@ -713,23 +710,14 @@ public class TRContent {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "upgrades", key = "overclcoker_speed", comment = "Overclocker behavior speed multipiler")
|
|
||||||
public static double overclockerSpeed = 0.25;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "upgrades", key = "overclcoker_power", comment = "Overclocker behavior power multipiler")
|
|
||||||
public static double overclockerPower = 0.75;
|
|
||||||
|
|
||||||
@ConfigRegistry(config = "items", category = "upgrades", key = "energy_storage", comment = "Energy storage behavior extra power")
|
|
||||||
public static double energyStoragePower = 40_000;
|
|
||||||
|
|
||||||
public enum Upgrades implements ItemConvertible {
|
public enum Upgrades implements ItemConvertible {
|
||||||
OVERCLOCKER((blockEntity, handler, stack) -> {
|
OVERCLOCKER((blockEntity, handler, stack) -> {
|
||||||
PowerAcceptorBlockEntity powerAcceptor = null;
|
PowerAcceptorBlockEntity powerAcceptor = null;
|
||||||
if (blockEntity instanceof PowerAcceptorBlockEntity) {
|
if (blockEntity instanceof PowerAcceptorBlockEntity) {
|
||||||
powerAcceptor = (PowerAcceptorBlockEntity) blockEntity;
|
powerAcceptor = (PowerAcceptorBlockEntity) blockEntity;
|
||||||
}
|
}
|
||||||
handler.addSpeedMulti(overclockerSpeed);
|
handler.addSpeedMulti(TechRebornConfig.overclockerSpeed);
|
||||||
handler.addPowerMulti(overclockerPower);
|
handler.addPowerMulti(TechRebornConfig.overclockerPower);
|
||||||
if (powerAcceptor != null) {
|
if (powerAcceptor != null) {
|
||||||
powerAcceptor.extraPowerInput += powerAcceptor.getMaxInput();
|
powerAcceptor.extraPowerInput += powerAcceptor.getMaxInput();
|
||||||
powerAcceptor.extraPowerStorage += powerAcceptor.getBaseMaxPower();
|
powerAcceptor.extraPowerStorage += powerAcceptor.getBaseMaxPower();
|
||||||
|
@ -750,7 +738,7 @@ public class TRContent {
|
||||||
powerAcceptor = (PowerAcceptorBlockEntity) blockEntity;
|
powerAcceptor = (PowerAcceptorBlockEntity) blockEntity;
|
||||||
}
|
}
|
||||||
if (powerAcceptor != null) {
|
if (powerAcceptor != null) {
|
||||||
powerAcceptor.extraPowerStorage += energyStoragePower;
|
powerAcceptor.extraPowerStorage += TechRebornConfig.energyStoragePower;
|
||||||
}
|
}
|
||||||
}),
|
}),
|
||||||
SUPERCONDUCTOR((blockEntity, handler, stack) -> {
|
SUPERCONDUCTOR((blockEntity, handler, stack) -> {
|
||||||
|
|
|
@ -34,15 +34,12 @@ import net.minecraft.util.ActionResult;
|
||||||
import net.minecraft.util.Hand;
|
import net.minecraft.util.Hand;
|
||||||
import net.minecraft.util.TypedActionResult;
|
import net.minecraft.util.TypedActionResult;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
import reborncore.common.config.Config;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.client.gui.GuiManual;
|
import techreborn.client.gui.GuiManual;
|
||||||
|
|
||||||
public class ItemManual extends Item {
|
public class ItemManual extends Item {
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "general", key = "manualRefund", comment = "Allow refunding items used to craft the manual")
|
|
||||||
public static boolean allowRefund = true;
|
|
||||||
|
|
||||||
public ItemManual() {
|
public ItemManual() {
|
||||||
super(new Item.Settings().group(TechReborn.ITEMGROUP).maxCount(1));
|
super(new Item.Settings().group(TechReborn.ITEMGROUP).maxCount(1));
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,18 +37,15 @@ import net.minecraft.world.World;
|
||||||
import reborncore.api.power.IEnergyItemInfo;
|
import reborncore.api.power.IEnergyItemInfo;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import reborncore.common.powerSystem.PowerSystem;
|
import reborncore.common.powerSystem.PowerSystem;
|
||||||
import reborncore.common.registration.RebornRegister;
|
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.config.ConfigTechReborn;
|
|
||||||
import techreborn.init.TRArmorMaterial;
|
import techreborn.init.TRArmorMaterial;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class ItemCloakingDevice extends ItemTRArmour implements IEnergyItemInfo {
|
public class ItemCloakingDevice extends ItemTRArmour implements IEnergyItemInfo {
|
||||||
|
|
||||||
public static int maxCharge = ConfigTechReborn.CloakingDeviceCharge;
|
public static int maxCharge = TechRebornConfig.CloakingDeviceCharge;
|
||||||
public static int usage = ConfigTechReborn.CloackingDeviceUsage;
|
public static int usage = TechRebornConfig.CloackingDeviceUsage;
|
||||||
public static int transferLimit = 10_000;
|
public static int transferLimit = 10_000;
|
||||||
public static boolean isActive;
|
public static boolean isActive;
|
||||||
|
|
||||||
|
|
|
@ -36,13 +36,13 @@ import reborncore.common.powerSystem.PowerSystem;
|
||||||
import reborncore.common.util.ItemDurabilityExtensions;
|
import reborncore.common.util.ItemDurabilityExtensions;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
public class ItemLapotronicOrbpack extends ArmorItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
public class ItemLapotronicOrbpack extends ArmorItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
||||||
|
|
||||||
// 400M FE maxCharge and 100k FE\t charge rate. Fully charged in 3 mins.
|
// 400M FE maxCharge and 100k FE\t charge rate. Fully charged in 3 mins.
|
||||||
public static final int maxCharge = ConfigTechReborn.LapotronPackCharge;
|
public static final int maxCharge = TechRebornConfig.LapotronPackCharge;
|
||||||
public int transferLimit = 100_000;
|
public int transferLimit = 100_000;
|
||||||
|
|
||||||
public ItemLapotronicOrbpack() {
|
public ItemLapotronicOrbpack() {
|
||||||
|
|
|
@ -38,13 +38,13 @@ import reborncore.common.powerSystem.PowerSystem;
|
||||||
import reborncore.common.util.ItemDurabilityExtensions;
|
import reborncore.common.util.ItemDurabilityExtensions;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
public class ItemLithiumIonBatpack extends ArmorItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
public class ItemLithiumIonBatpack extends ArmorItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
||||||
|
|
||||||
// 8M FE maxCharge and 2k FE\t charge rate. Fully charged in 3 mins.
|
// 8M FE maxCharge and 2k FE\t charge rate. Fully charged in 3 mins.
|
||||||
public static final int maxCharge = ConfigTechReborn.LithiumBatpackCharge;
|
public static final int maxCharge = TechRebornConfig.LithiumBatpackCharge;
|
||||||
public int transferLimit = 2_000;
|
public int transferLimit = 2_000;
|
||||||
|
|
||||||
public ItemLithiumIonBatpack() {
|
public ItemLithiumIonBatpack() {
|
||||||
|
|
|
@ -30,14 +30,14 @@ import net.minecraft.item.ItemGroup;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
public class ItemEnergyCrystal extends ItemBattery {
|
public class ItemEnergyCrystal extends ItemBattery {
|
||||||
|
|
||||||
// 4M FE storage with 1k charge rate
|
// 4M FE storage with 1k charge rate
|
||||||
public ItemEnergyCrystal() {
|
public ItemEnergyCrystal() {
|
||||||
super(ConfigTechReborn.EnergyCrystalMaxCharge, 1_000);
|
super(TechRebornConfig.EnergyCrystalMaxCharge, 1_000);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Environment(EnvType.CLIENT)
|
@Environment(EnvType.CLIENT)
|
||||||
|
|
|
@ -30,14 +30,14 @@ import net.minecraft.item.ItemGroup;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
public class ItemLapotronCrystal extends ItemBattery {
|
public class ItemLapotronCrystal extends ItemBattery {
|
||||||
|
|
||||||
// 40M FE capacity with 10k FE\t charge rate
|
// 40M FE capacity with 10k FE\t charge rate
|
||||||
public ItemLapotronCrystal() {
|
public ItemLapotronCrystal() {
|
||||||
super(ConfigTechReborn.LapotronCrystalMaxCharge, 10_000);
|
super(TechRebornConfig.LapotronCrystalMaxCharge, 10_000);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Environment(EnvType.CLIENT)
|
@Environment(EnvType.CLIENT)
|
||||||
|
|
|
@ -30,14 +30,14 @@ import net.minecraft.item.ItemGroup;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
public class ItemLapotronicOrb extends ItemBattery {
|
public class ItemLapotronicOrb extends ItemBattery {
|
||||||
|
|
||||||
// 400M capacity with 100k FE\t charge rate
|
// 400M capacity with 100k FE\t charge rate
|
||||||
public ItemLapotronicOrb() {
|
public ItemLapotronicOrb() {
|
||||||
super(ConfigTechReborn.LapotronicOrbMaxCharge, 100_000);
|
super(TechRebornConfig.LapotronicOrbMaxCharge, 100_000);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Environment(EnvType.CLIENT)
|
@Environment(EnvType.CLIENT)
|
||||||
|
|
|
@ -33,7 +33,7 @@ import net.minecraft.item.Items;
|
||||||
import net.minecraft.item.ToolMaterials;
|
import net.minecraft.item.ToolMaterials;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemChainsaw;
|
import techreborn.items.tool.ItemChainsaw;
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ public class ItemAdvancedChainsaw extends ItemChainsaw {
|
||||||
|
|
||||||
// 400k max charge with 1k charge rate
|
// 400k max charge with 1k charge rate
|
||||||
public ItemAdvancedChainsaw() {
|
public ItemAdvancedChainsaw() {
|
||||||
super(ToolMaterials.DIAMOND, ConfigTechReborn.AdvancedChainsawCharge, 1.0F);
|
super(ToolMaterials.DIAMOND, TechRebornConfig.AdvancedChainsawCharge, 1.0F);
|
||||||
this.cost = 250;
|
this.cost = 250;
|
||||||
this.transferLimit = 1000;
|
this.transferLimit = 1000;
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,7 +33,7 @@ import net.minecraft.item.Items;
|
||||||
import net.minecraft.item.ToolMaterials;
|
import net.minecraft.item.ToolMaterials;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemDrill;
|
import techreborn.items.tool.ItemDrill;
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ public class ItemAdvancedDrill extends ItemDrill {
|
||||||
|
|
||||||
// 400k max charge with 1k charge rate
|
// 400k max charge with 1k charge rate
|
||||||
public ItemAdvancedDrill() {
|
public ItemAdvancedDrill() {
|
||||||
super(ToolMaterials.DIAMOND, ConfigTechReborn.AdvancedDrillCharge, 0.5F, 15F);
|
super(ToolMaterials.DIAMOND, TechRebornConfig.AdvancedDrillCharge, 0.5F, 15F);
|
||||||
this.cost = 250;
|
this.cost = 250;
|
||||||
this.transferLimit = 1000;
|
this.transferLimit = 1000;
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,7 @@ import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.item.ToolMaterials;
|
import net.minecraft.item.ToolMaterials;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemJackhammer;
|
import techreborn.items.tool.ItemJackhammer;
|
||||||
|
|
||||||
|
@ -39,7 +39,7 @@ public class ItemAdvancedJackhammer extends ItemJackhammer {
|
||||||
|
|
||||||
// 400k max charge with 1k charge rate
|
// 400k max charge with 1k charge rate
|
||||||
public ItemAdvancedJackhammer() {
|
public ItemAdvancedJackhammer() {
|
||||||
super(ToolMaterials.DIAMOND, ConfigTechReborn.AdvancedJackhammerCharge);
|
super(ToolMaterials.DIAMOND, TechRebornConfig.AdvancedJackhammerCharge);
|
||||||
this.cost = 100;
|
this.cost = 100;
|
||||||
this.transferLimit = 1000;
|
this.transferLimit = 1000;
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,14 +42,14 @@ import reborncore.common.powerSystem.PowerSystem;
|
||||||
import reborncore.common.util.ItemDurabilityExtensions;
|
import reborncore.common.util.ItemDurabilityExtensions;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
public class ItemRockCutter extends PickaxeItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
public class ItemRockCutter extends PickaxeItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
||||||
|
|
||||||
public static final int maxCharge = ConfigTechReborn.RockCutterCharge;
|
public static final int maxCharge = TechRebornConfig.RockCutterCharge;
|
||||||
public int transferLimit = 1_000;
|
public int transferLimit = 1_000;
|
||||||
public int cost = 500;
|
public int cost = 500;
|
||||||
|
|
||||||
|
|
|
@ -33,14 +33,14 @@ import net.minecraft.item.Items;
|
||||||
import net.minecraft.item.ToolMaterials;
|
import net.minecraft.item.ToolMaterials;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemChainsaw;
|
import techreborn.items.tool.ItemChainsaw;
|
||||||
|
|
||||||
public class ItemBasicChainsaw extends ItemChainsaw {
|
public class ItemBasicChainsaw extends ItemChainsaw {
|
||||||
|
|
||||||
public ItemBasicChainsaw() {
|
public ItemBasicChainsaw() {
|
||||||
super(ToolMaterials.IRON, ConfigTechReborn.BasicChainsawCharge, 0.5F);
|
super(ToolMaterials.IRON, TechRebornConfig.BasicChainsawCharge, 0.5F);
|
||||||
this.cost = 50;
|
this.cost = 50;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -33,14 +33,14 @@ import net.minecraft.item.Items;
|
||||||
import net.minecraft.item.ToolMaterials;
|
import net.minecraft.item.ToolMaterials;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemDrill;
|
import techreborn.items.tool.ItemDrill;
|
||||||
|
|
||||||
public class ItemBasicDrill extends ItemDrill {
|
public class ItemBasicDrill extends ItemDrill {
|
||||||
|
|
||||||
public ItemBasicDrill() {
|
public ItemBasicDrill() {
|
||||||
super(ToolMaterials.IRON, ConfigTechReborn.BasicDrillCharge, 0.5F, 10F);
|
super(ToolMaterials.IRON, TechRebornConfig.BasicDrillCharge, 0.5F, 10F);
|
||||||
this.cost = 50;
|
this.cost = 50;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -31,14 +31,14 @@ import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.item.ToolMaterials;
|
import net.minecraft.item.ToolMaterials;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemJackhammer;
|
import techreborn.items.tool.ItemJackhammer;
|
||||||
|
|
||||||
public class ItemBasicJackhammer extends ItemJackhammer {
|
public class ItemBasicJackhammer extends ItemJackhammer {
|
||||||
|
|
||||||
public ItemBasicJackhammer() {
|
public ItemBasicJackhammer() {
|
||||||
super(ToolMaterials.DIAMOND, ConfigTechReborn.BasicJackhammerCharge);
|
super(ToolMaterials.DIAMOND, TechRebornConfig.BasicJackhammerCharge);
|
||||||
this.cost = 50;
|
this.cost = 50;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,7 @@ import reborncore.api.power.ItemPowerManager;
|
||||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||||
import reborncore.common.util.ChatUtils;
|
import reborncore.common.util.ChatUtils;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemChainsaw;
|
import techreborn.items.tool.ItemChainsaw;
|
||||||
import techreborn.utils.MessageIDs;
|
import techreborn.utils.MessageIDs;
|
||||||
|
@ -65,7 +65,7 @@ public class ItemIndustrialChainsaw extends ItemChainsaw {
|
||||||
|
|
||||||
// 4M FE max charge with 1k charge rate
|
// 4M FE max charge with 1k charge rate
|
||||||
public ItemIndustrialChainsaw() {
|
public ItemIndustrialChainsaw() {
|
||||||
super(ToolMaterials.DIAMOND, ConfigTechReborn.IndustrialChainsawCharge, 1.0F);
|
super(ToolMaterials.DIAMOND, TechRebornConfig.IndustrialChainsawCharge, 1.0F);
|
||||||
this.cost = 250;
|
this.cost = 250;
|
||||||
this.transferLimit = 1000;
|
this.transferLimit = 1000;
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,7 +51,7 @@ import reborncore.api.power.ItemPowerManager;
|
||||||
import reborncore.common.powerSystem.ExternalPowerSystems;
|
import reborncore.common.powerSystem.ExternalPowerSystems;
|
||||||
import reborncore.common.util.ChatUtils;
|
import reborncore.common.util.ChatUtils;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemDrill;
|
import techreborn.items.tool.ItemDrill;
|
||||||
import techreborn.utils.MessageIDs;
|
import techreborn.utils.MessageIDs;
|
||||||
|
@ -66,7 +66,7 @@ public class ItemIndustrialDrill extends ItemDrill {
|
||||||
|
|
||||||
// 4M FE max charge with 1k charge rate
|
// 4M FE max charge with 1k charge rate
|
||||||
public ItemIndustrialDrill() {
|
public ItemIndustrialDrill() {
|
||||||
super(ToolMaterials.DIAMOND, ConfigTechReborn.IndustrialDrillCharge, 2.0F, 10F);
|
super(ToolMaterials.DIAMOND, TechRebornConfig.IndustrialDrillCharge, 2.0F, 10F);
|
||||||
this.cost = 250;
|
this.cost = 250;
|
||||||
this.transferLimit = 1000;
|
this.transferLimit = 1000;
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,7 @@ import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.item.ToolMaterials;
|
import net.minecraft.item.ToolMaterials;
|
||||||
import net.minecraft.util.DefaultedList;
|
import net.minecraft.util.DefaultedList;
|
||||||
import reborncore.api.power.ItemPowerManager;
|
import reborncore.api.power.ItemPowerManager;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.tool.ItemJackhammer;
|
import techreborn.items.tool.ItemJackhammer;
|
||||||
|
|
||||||
|
@ -39,7 +39,7 @@ public class ItemIndustrialJackhammer extends ItemJackhammer {
|
||||||
|
|
||||||
// 4M FE max charge with 1k charge rate
|
// 4M FE max charge with 1k charge rate
|
||||||
public ItemIndustrialJackhammer() {
|
public ItemIndustrialJackhammer() {
|
||||||
super(ToolMaterials.IRON, ConfigTechReborn.IndustrialJackhammerCharge);
|
super(ToolMaterials.IRON, TechRebornConfig.IndustrialJackhammerCharge);
|
||||||
this.cost = 250;
|
this.cost = 250;
|
||||||
this.transferLimit = 1000;
|
this.transferLimit = 1000;
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,7 +46,7 @@ import reborncore.common.util.ChatUtils;
|
||||||
import reborncore.common.util.ItemDurabilityExtensions;
|
import reborncore.common.util.ItemDurabilityExtensions;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.utils.MessageIDs;
|
import techreborn.utils.MessageIDs;
|
||||||
|
|
||||||
|
@ -54,7 +54,7 @@ import javax.annotation.Nullable;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
public class ItemNanosaber extends SwordItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
public class ItemNanosaber extends SwordItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
||||||
public static final int maxCharge = ConfigTechReborn.nanoSaberCharge;
|
public static final int maxCharge = TechRebornConfig.nanoSaberCharge;
|
||||||
public int transferLimit = 1_000;
|
public int transferLimit = 1_000;
|
||||||
public int cost = 250;
|
public int cost = 250;
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ import reborncore.common.util.ItemDurabilityExtensions;
|
||||||
import reborncore.common.util.ItemUtils;
|
import reborncore.common.util.ItemUtils;
|
||||||
import reborncore.common.util.TorchHelper;
|
import reborncore.common.util.TorchHelper;
|
||||||
import techreborn.TechReborn;
|
import techreborn.TechReborn;
|
||||||
import techreborn.config.ConfigTechReborn;
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
|
|
||||||
import javax.annotation.Nullable;
|
import javax.annotation.Nullable;
|
||||||
|
@ -55,7 +55,7 @@ import java.util.List;
|
||||||
|
|
||||||
public class ItemOmniTool extends PickaxeItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
public class ItemOmniTool extends PickaxeItem implements IEnergyItemInfo, ItemDurabilityExtensions {
|
||||||
|
|
||||||
public static final int maxCharge = ConfigTechReborn.OmniToolCharge;
|
public static final int maxCharge = TechRebornConfig.OmniToolCharge;
|
||||||
public int transferLimit = 1_000;
|
public int transferLimit = 1_000;
|
||||||
public int cost = 100;
|
public int cost = 100;
|
||||||
public int hitCost = 125;
|
public int hitCost = 125;
|
||||||
|
|
|
@ -40,8 +40,8 @@ import techreborn.blockentity.machine.tier1.AutoCraftingTableBlockEntity;
|
||||||
import techreborn.blockentity.machine.tier1.RollingMachineBlockEntity;
|
import techreborn.blockentity.machine.tier1.RollingMachineBlockEntity;
|
||||||
import techreborn.blockentity.storage.AdjustableSUBlockEntity;
|
import techreborn.blockentity.storage.AdjustableSUBlockEntity;
|
||||||
import techreborn.blockentity.storage.idsu.InterdimensionalSUBlockEntity;
|
import techreborn.blockentity.storage.idsu.InterdimensionalSUBlockEntity;
|
||||||
|
import techreborn.config.TechRebornConfig;
|
||||||
import techreborn.init.TRContent;
|
import techreborn.init.TRContent;
|
||||||
import techreborn.items.ItemManual;
|
|
||||||
|
|
||||||
import java.util.function.BiConsumer;
|
import java.util.function.BiConsumer;
|
||||||
|
|
||||||
|
@ -116,7 +116,7 @@ public class ServerboundPackets {
|
||||||
});
|
});
|
||||||
|
|
||||||
registerPacketHandler(REFUND, (extendedPacketBuffer, context) -> {
|
registerPacketHandler(REFUND, (extendedPacketBuffer, context) -> {
|
||||||
if(!ItemManual.allowRefund){
|
if(!TechRebornConfig.allowManualRefund){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
context.getTaskQueue().execute(() -> {
|
context.getTaskQueue().execute(() -> {
|
||||||
|
|
|
@ -33,23 +33,17 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.util.math.Position;
|
import net.minecraft.util.math.Position;
|
||||||
import reborncore.common.crafting.RebornRecipe;
|
import reborncore.common.crafting.RebornRecipe;
|
||||||
import reborncore.common.registration.RebornRegister;
|
import techreborn.config.TechRebornConfig;
|
||||||
import reborncore.common.registration.config.ConfigRegistry;
|
|
||||||
import techreborn.TechReborn;
|
|
||||||
import techreborn.init.ModRecipes;
|
import techreborn.init.ModRecipes;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
@RebornRegister(TechReborn.MOD_ID)
|
|
||||||
public class BehaviorDispenseScrapbox extends ItemDispenserBehavior {
|
public class BehaviorDispenseScrapbox extends ItemDispenserBehavior {
|
||||||
|
|
||||||
@ConfigRegistry(config = "misc", category = "general", key = "DispenserScrapbox", comment = "Dispensers will open scrapboxes")
|
|
||||||
public static boolean dispenseScrapboxes = true;
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected ItemStack dispenseSilently(BlockPointer source, ItemStack stack) {
|
protected ItemStack dispenseSilently(BlockPointer source, ItemStack stack) {
|
||||||
if (dispenseScrapboxes) {
|
if (TechRebornConfig.dispenseScrapboxes) {
|
||||||
List<RebornRecipe> scrapboxRecipeList = ModRecipes.SCRAPBOX.getRecipes(source.getWorld());
|
List<RebornRecipe> scrapboxRecipeList = ModRecipes.SCRAPBOX.getRecipes(source.getWorld());
|
||||||
int random = new Random().nextInt(scrapboxRecipeList.size());
|
int random = new Random().nextInt(scrapboxRecipeList.size());
|
||||||
ItemStack out = scrapboxRecipeList.get(random).getOutputs().get(0);
|
ItemStack out = scrapboxRecipeList.get(random).getOutputs().get(0);
|
||||||
|
|
File diff suppressed because it is too large
Load diff
Loading…
Add table
Reference in a new issue