diff --git a/src/main/java/com/gtnewhorizons/gtnhintergalactic/tile/multi/TileEntityDysonSwarm.java b/src/main/java/com/gtnewhorizons/gtnhintergalactic/tile/multi/TileEntityDysonSwarm.java index 8d43a1f..27c8eb0 100644 --- a/src/main/java/com/gtnewhorizons/gtnhintergalactic/tile/multi/TileEntityDysonSwarm.java +++ b/src/main/java/com/gtnewhorizons/gtnhintergalactic/tile/multi/TileEntityDysonSwarm.java @@ -1,9 +1,18 @@ package com.gtnewhorizons.gtnhintergalactic.tile.multi; +import static com.gtnewhorizon.structurelib.structure.StructureUtility.ofBlock; +import static gregtech.api.enums.HatchElement.Dynamo; +import static gregtech.api.enums.HatchElement.InputBus; +import static gregtech.api.enums.HatchElement.InputHatch; +import static gregtech.api.enums.HatchElement.Maintenance; +import static gregtech.api.util.GTStructureUtility.buildHatchAdder; +import static gregtech.api.util.GTStructureUtility.ofFrame; import static gregtech.api.util.GTUtility.filterValidMTEs; import static net.minecraft.util.EnumChatFormatting.*; import static net.minecraft.util.StatCollector.translateToLocal; import static net.minecraft.util.StatCollector.translateToLocalFormatted; +import static tectech.thing.metaTileEntity.multi.base.TTMultiblockBase.HatchElement.DynamoMulti; +import static tectech.thing.metaTileEntity.multi.base.TTMultiblockBase.HatchElement.InputData; import java.math.RoundingMode; import java.text.DecimalFormat; @@ -39,7 +48,6 @@ import gregtech.api.metatileentity.implementations.MTEHatchDynamo; import gregtech.api.metatileentity.implementations.MTEHatchInputBus; import gregtech.api.render.TextureFactory; -import gregtech.api.util.GTStructureUtility; import gregtech.api.util.GTUtility; import gregtech.api.util.MultiblockTooltipBuilder; import gregtech.common.items.IDMetaTool01; @@ -141,41 +149,48 @@ public class TileEntityDysonSwarm extends TTMultiblockBase implements ISurvivalC "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbnbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb", "bbbbbbbbbbbbbbbb" } })) - .addElement('b', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 9)) // Dyson Swarm Ground Unit Ultra High Strength Concrete Floor - .addElement('c', StructureUtility.ofBlock(GregTechAPI.sBlockCasings5, 8)) // Awakened Draconium Coil Block - .addElement('d', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 1)) // Dyson Swarm Energy Receiver Dish Block + .addElement('b', ofBlock(IGBlocks.DysonSwarmCasing, 9)) // Dyson Swarm Ground Unit Ultra High Strength Concrete Floor + .addElement('c', ofBlock(GregTechAPI.sBlockCasings5, 8)) // Awakened Draconium Coil Block + .addElement('d', ofBlock(IGBlocks.DysonSwarmCasing, 1)) // Dyson Swarm Energy Receiver Dish Block .addElement( 'e', - StructureUtility.ofChain( - GTStructureUtility.ofHatchAdder(TileEntityDysonSwarm::addDynamoToMachineList, IGTextures.CASING_INDEX_RECEIVER, 1), - StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 0))) // Dyson Swarm Energy Receiver Base Casing - .addElement('f', GTStructureUtility.ofFrame(Materials.HSSS)) - .addElement('g', GTStructureUtility.ofFrame(Materials.Titanium)) - .addElement('h', StructureUtility.ofBlock(GregTechAPI.sBlockCasings6, 10)) // Hermetic Casing X + buildHatchAdder(TileEntityDysonSwarm.class).atLeast(Dynamo, DynamoMulti) + .casingIndex(IGTextures.CASING_INDEX_RECEIVER) + .dot(1) + .buildAndChain(ofBlock(IGBlocks.DysonSwarmCasing, 0))) // Dyson Swarm Energy Receiver Base Casing + .addElement('f', ofFrame(Materials.HSSS)) + .addElement('g', ofFrame(Materials.Titanium)) + .addElement('h', ofBlock(GregTechAPI.sBlockCasings6, 10)) // Hermetic Casing X .addElement( 'i', - StructureUtility.ofChain( - GTStructureUtility.ofHatchAdder(TileEntityDysonSwarm::addInputToMachineList, IGTextures.CASING_INDEX_LAUNCH, 2), - StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 2))) // Dyson Swarm Module Deployment Unit Base Casing - .addElement('j', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 3)) // Dyson Swarm Module Deployment Unit Core - .addElement('k', GTStructureUtility.ofFrame(Materials.Longasssuperconductornameforuhvwire)) - .addElement('m', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 4)) // Dyson Swarm Module Deployment Unit Superconducting Magnet + buildHatchAdder(TileEntityDysonSwarm.class) + .atLeast(InputBus, InputHatch) + .casingIndex(IGTextures.CASING_INDEX_LAUNCH) + .dot(2) + .buildAndChain(ofBlock(IGBlocks.DysonSwarmCasing, 2))) // Dyson Swarm Module Deployment Unit Base Casing + .addElement('j', ofBlock(IGBlocks.DysonSwarmCasing, 3)) // Dyson Swarm Module Deployment Unit Core + .addElement('k', ofFrame(Materials.Longasssuperconductornameforuhvwire)) + .addElement('m', ofBlock(IGBlocks.DysonSwarmCasing, 4)) // Dyson Swarm Module Deployment Unit Superconducting Magnet .addElement( 'n', - StructureUtility.ofChain( - GTStructureUtility.ofHatchAdder(TileEntityDysonSwarm::addClassicMaintenanceToMachineList, IGTextures.CASING_INDEX_FLOOR, 3), - StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 9))) // Dyson Swarm Ground Unit Ultra High Strength Concrete Floor + buildHatchAdder(TileEntityDysonSwarm.class) + .anyOf(Maintenance) + .casingIndex(IGTextures.CASING_INDEX_FLOOR) + .dot(3) + .build()) // Dyson Swarm Ground Unit Ultra High Strength Concrete Floor .addElement( 'o', - StructureUtility.ofChain( - GTStructureUtility.ofHatchAdder(TileEntityDysonSwarm::addDataInputToMachineList, IGTextures.CASING_INDEX_COMMAND, 4), - StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 5))) // Dyson Swarm Command Center Base Casing - .addElement('p', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 6)) // Dyson Swarm Command Center Primary Windings - .addElement('s', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 7)) // Dyson Swarm Command Center Secondary Windings - .addElement('t', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 8)) // Dyson Swarm Command Center Toroid Casing - .addElement('x', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 0)) // Dyson Swarm Energy Receiver Base Casing - .addElement('y', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 5)) // Dyson Swarm Command Center Base Casing - .addElement('z', StructureUtility.ofBlock(IGBlocks.DysonSwarmCasing, 2)) // Dyson Swarm Module Deployment Unit Base Casing + buildHatchAdder(TileEntityDysonSwarm.class) + .atLeast(InputData) + .casingIndex(IGTextures.CASING_INDEX_COMMAND) + .dot(4) + .buildAndChain(ofBlock(IGBlocks.DysonSwarmCasing, 5))) // Dyson Swarm Command Center Base Casing + .addElement('p', ofBlock(IGBlocks.DysonSwarmCasing, 6)) // Dyson Swarm Command Center Primary Windings + .addElement('s', ofBlock(IGBlocks.DysonSwarmCasing, 7)) // Dyson Swarm Command Center Secondary Windings + .addElement('t', ofBlock(IGBlocks.DysonSwarmCasing, 8)) // Dyson Swarm Command Center Toroid Casing + .addElement('x', ofBlock(IGBlocks.DysonSwarmCasing, 0)) // Dyson Swarm Energy Receiver Base Casing + .addElement('y', ofBlock(IGBlocks.DysonSwarmCasing, 5)) // Dyson Swarm Command Center Base Casing + .addElement('z', ofBlock(IGBlocks.DysonSwarmCasing, 2)) // Dyson Swarm Module Deployment Unit Base Casing .build(); // spotless:on